commit 523d939ef98fd712632d93a5a2b588e477a7565e Author: Linus Torvalds Date: Sun Jul 24 12:23:50 2016 -0700 Linux 4.7 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 68093c43f352e4ad36cf1324bbdbd7c723a24dbc Merge: 107df03 930c532 Author: Linus Torvalds Date: Sun Jul 24 10:00:31 2016 +0900 Merge tag 'ceph-for-4.7-rc8' of git://github.com/ceph/ceph-client Pull ceph fix from Ilya Dryomov: "A fix for a long-standing bug in the incremental osdmap handling code that caused misdirected requests, tagged for stable" The tag is signed with a brand new key - Sage is on vacation and I didn't anticipate this" * tag 'ceph-for-4.7-rc8' of git://github.com/ceph/ceph-client: libceph: apply new_state before new_up_client on incrementals commit 107df03203bb66de56e2caec3bde6d22b55480c5 Merge: 88083e9 f8e7718 Author: Linus Torvalds Date: Sat Jul 23 15:44:31 2016 +0900 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes from David Miller: 1) Fix memory leak in nftables, from Liping Zhang. 2) Need to check result of vlan_insert_tag() in batman-adv otherwise we risk NULL skb derefs, from Sven Eckelmann. 3) Check for dev_alloc_skb() failures in cfg80211, from Gregory Greenman. 4) Handle properly when we have ppp_unregister_channel() happening in parallel with ppp_connect_channel(), from WANG Cong. 5) Fix DCCP deadlock, from Eric Dumazet. 6) Bail out properly in UDP if sk_filter() truncates the packet to be smaller than even the space that the protocol headers need. From Michal Kubecek. 7) Similarly for rose, dccp, and sctp, from Willem de Bruijn. 8) Make TCP challenge ACKs less predictable, from Eric Dumazet. 9) Fix infinite loop in bgmac_dma_tx_add() from Florian Fainelli. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (65 commits) packet: propagate sock_cmsg_send() error net/mlx5e: Fix del vxlan port command buffer memset packet: fix second argument of sock_tx_timestamp() net: switchdev: change ageing_time type to clock_t Update maintainer for EHEA driver. net/mlx4_en: Add resilience in low memory systems net/mlx4_en: Move filters cleanup to a proper location sctp: load transport header after sk_filter net/sched/sch_htb: clamp xstats tokens to fit into 32-bit int net: cavium: liquidio: Avoid dma_unmap_single on uninitialized ndata net: nb8800: Fix SKB leak in nb8800_receive() et131x: Fix logical vs bitwise check in et131x_tx_timeout() vlan: use a valid default mtu value for vlan over macsec net: bgmac: Fix infinite loop in bgmac_dma_tx_add() mlxsw: spectrum: Prevent invalid ingress buffer mapping mlxsw: spectrum: Prevent overwrite of DCB capability fields mlxsw: spectrum: Don't emit errors when PFC is disabled mlxsw: spectrum: Indicate support for autonegotiation mlxsw: spectrum: Force link training according to admin state r8152: add MODULE_VERSION ... commit 88083e9845612826dfd44a5215647b4f6567317c Merge: b1386ce cfc9fde Author: Linus Torvalds Date: Sat Jul 23 14:25:02 2016 +0900 Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs Pull overlayfs fixes from Miklos Szeredi: "This contains a fix for a potential crash/corruption issue and another where the suid/sgid bits weren't cleared on write" * 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs: ovl: verify upper dentry in ovl_remove_and_whiteout() ovl: Copy up underlying inode's ->i_mode to overlay inode ovl: handle ATTR_KILL* commit b1386cedda177b10fac009ca8d3681034f15b5b3 Merge: d15ae81 368301f Author: Linus Torvalds Date: Sat Jul 23 12:54:20 2016 +0900 Merge branch 'akpm' (patches from Andrew) Merge misc fixes from Andrew Morton: "Five fixes" * emailed patches from Andrew Morton : pps: do not crash when failed to register tools/vm/slabinfo: fix an unintentional printf testing/radix-tree: fix a macro expansion bug radix-tree: fix radix_tree_iter_retry() for tagged iterators. mm: memcontrol: fix cgroup creation failure after many small jobs commit d15ae814ccb0df179e93d64c4642e7f58ee8398b Merge: 3f2625d cad7d8d Author: Linus Torvalds Date: Sat Jul 23 12:51:52 2016 +0900 Merge tag 'drm-fixes-for-v4.7-rc8-intel-kbl' of git://people.freedesktop.org/~airlied/linux Pull intel kabylake drm fixes from Dave Airlie: "As mentioned Intel has gathered all the Kabylake fixes from -next, which we've enabled in 4.7 for the first time, these are pretty much limited in scope to only affects kabylake, which is hw that isn't shipping yet. So I'm mostly okay with it going in now. If we don't land this, it might be a good idea to disable kabylake support in 4.7 before we ship" * tag 'drm-fixes-for-v4.7-rc8-intel-kbl' of git://people.freedesktop.org/~airlied/linux: (28 commits) drm/i915/kbl: Introduce the first official DMC for Kabylake. drm/i915: Introduce Kabypoint PCH for Kabylake H/DT. drm/i915/gen9: implement WaConextSwitchWithConcurrentTLBInvalidate drm/i915/gen9: Add WaFbcHighMemBwCorruptionAvoidance drm/i195/fbc: Add WaFbcNukeOnHostModify drm/i915/gen9: Add WaFbcWakeMemOn drm/i915/gen9: Add WaFbcTurnOffFbcWatermark drm/i915/kbl: Add WaClearSlmSpaceAtContextSwitch drm/i915/gen9: Add WaEnableChickenDCPR drm/i915/kbl: Add WaDisableSbeCacheDispatchPortSharing drm/i915/kbl: Add WaDisableGafsUnitClkGating drm/i915/kbl: Add WaForGAMHang drm/i915: Add WaInsertDummyPushConstP for bxt and kbl drm/i915/kbl: Add WaDisableDynamicCreditSharing drm/i915/kbl: Add WaDisableGamClockGating drm/i915/gen9: Enable must set chicken bits in config0 reg drm/i915/kbl: Add WaDisableLSQCROPERFforOCL drm/i915/kbl: Add WaDisableSDEUnitClockGating drm/i915/kbl: Add WaDisableFenceDestinationToSLM for A0 drm/i915/kbl: Add WaEnableGapsTsvCreditFix ... commit 3f2625d7055c31e64471270c2eb79d77f988845a Merge: 2321884 84ade45 Author: Linus Torvalds Date: Sat Jul 23 12:46:42 2016 +0900 Merge tag 'drm-fixes-for-v4.7-rc8-intel' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "Two i915 regression fixes. Intel have submitted some Kabylake fixes I'll send separately, since this is the first kernel with kabylake support and they don't go much outside that area I think they should be fine" * tag 'drm-fixes-for-v4.7-rc8-intel' of git://people.freedesktop.org/~airlied/linux: drm/i915: add missing condition for committing planes on crtc drm/i915: Treat eDP as always connected, again commit 23218843d92b77c99375609eb43e6e6b3d7f68c3 Merge: 7825e0c 6bd80f3 Author: Linus Torvalds Date: Sat Jul 23 12:39:08 2016 +0900 Merge tag 'm68k-for-v4.8-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k Pull m68k upddates from Geert Uytterhoeven: - assorted spelling fixes - defconfig updates * tag 'm68k-for-v4.8-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k: m68k/defconfig: Update defconfigs for v4.7-rc2 m68k: Assorted spelling fixes commit 7825e0c42943e16535ece82f3787b6b94a6c1652 Merge: 48d4ca5 5eb4953 Author: Linus Torvalds Date: Sat Jul 23 12:32:50 2016 +0900 Merge tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC fixes from Olof Johansson: "A handful of fixes before final release: Marvell Armada: - One to fix a typo in the devicetree specifying memory ranges for the crypto engine - Two to deal with marking PCI and device-memory as strongly ordered to avoid hardware deadlocks, in particular when enabling above crypto driver. - Compile fix for PM Allwinner: - DT clock fixes to deal with u-boot-enabled framebuffer (simplefb). - Make R8 (C.H.I.P. SoC) inherit system compatibility from A13 to make clocks register proper. Tegra: - Fix SD card voltage setting on the Tegra3 Beaver dev board Misc: - Two maintainers updates for STM32 and STi platforms" * tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: ARM: tegra: beaver: Allow SD card voltage to be changed MAINTAINERS: update STi maintainer list MAINTAINERS: update STM32 maintainers list ARM: mvebu: compile pm code conditionally ARM: dts: sun7i: Fix pll3x2 and pll7x2 not having a parent clock ARM: dts: sunxi: Add pll3 to simplefb nodes clocks lists ARM: dts: armada-38x: fix MBUS_ID for crypto SRAM on Armada 385 Linksys ARM: mvebu: map PCI I/O regions strongly ordered ARM: mvebu: fix HW I/O coherency related deadlocks ARM: sunxi/dt: make the CHIP inherit from allwinner,sun5i-a13 commit 48d4ca5639507b8c37e3bd5711e70aedb05dee2c Merge: 897473f 87dcdeb Author: Linus Torvalds Date: Sat Jul 23 12:20:55 2016 +0900 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto fixes from Herbert Xu: "This fixes a sporadic build failure in the qat driver as well as a memory corruption bug in rsa-pkcs1pad" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: rsa-pkcs1pad - fix rsa-pkcs1pad request struct crypto: qat - make qat_asym_algs.o depend on asn1 headers commit 897473fc040fd69e9a4a6da2ac62a4724a4a8619 Merge: 3aa536d acddc72 Author: Linus Torvalds Date: Sat Jul 23 12:15:48 2016 +0900 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull key handling fixes from James Morris: "Quoting David Howells: Here are three miscellaneous fixes: (1) Fix a panic in some debugging code in PKCS#7. This can only happen by explicitly inserting a #define DEBUG into the code. (2) Fix the calculation of the digest length in the PE file parser. This causes a failure where there should be a success. (3) Fix the case where an X.509 cert can be added as an asymmetric key to a trusted keyring with no trust restriction if no AKID is supplied. Bugs (1) and (2) aren't particularly problematic, but (3) allows a security check to be bypassed. Happily, this is a recent regression and never made it into a released kernel" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: KEYS: Fix for erroneous trust of incorrectly signed X.509 certs pefile: Fix the failure of calculation for digest PKCS#7: Fix panic when referring to the empty AKID when DEBUG defined commit 3aa536d9aafc2806dd3439114e25b253086312a9 Merge: f1894d8 e9003c9 Author: Linus Torvalds Date: Sat Jul 23 12:10:48 2016 +0900 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull input fixes from Dmitry Torokhov: "A few more fixes for the input subsystem: - restore naming for tsc2005 touchscreens as some userspace match on it - fix out of bound access in legacy keyboard driver - fixup in RMI4 driver Everything is tagged for stable as well" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: tsc200x - report proper input_dev name tty/vt/keyboard: fix OOB access in do_compute_shiftstate() Input: synaptics-rmi4 - fix maximum size check for F12 control register 8 commit f1894d838f4bce37297f04b7ed7aac1e6ed7717a Merge: ee62f09 a722559 Author: Linus Torvalds Date: Sat Jul 23 12:07:37 2016 +0900 Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm Pull libnvdimm fix from Dan Williams: "This contains a regression fix for a problem that was introduced in v4.7-rc6. In 4.7-rc1 we introduced auto-probing for the ACPI DSM (device- specific-method) format that the platform firmware implements for nvdimm devices. We initially fixed a regression in probing the QEMU DSM implementation by making acpi_check_dsm() tolerant of the way QEMU reports the "0 DSMs supported" condition. However, that broke HPE platforms since that tolerance caused the driver to mistakenly match the 1-zero-byte response those platforms give to "unknown" commands. Instead, we simply make the driver tolerant of not finding any supported DSMs. This has been tested to work with both QEMU and HPE platforms. This commit has appeared in a -next release with no reported issues" * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: nfit: make DIMM DSMs optional commit ee62f09bda631151a55e2b2543acba5a38eef186 Merge: 62cd69d 0bfb85c Author: Linus Torvalds Date: Sat Jul 23 12:03:21 2016 +0900 Merge tag 'gpio-v4.7-6' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fix from Linus Walleij: "Compile problem fix for Tegra, Sorry to send this in the last minute but Ingo says this build failure is very prominent so I'm not going to wait for v4.7 before sending it. It is a case of COMPILE_TEST causing more problems than it solves and I'm already swearing about me shooting myself in the foot with that gun :(" * tag 'gpio-v4.7-6' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: gpio: tegra: don't auto-enable for COMPILE_TEST commit 62cd69d5b0cde8aaea2d2a8f828be65196bf1ada Merge: a933f80 f96423f4 Author: Linus Torvalds Date: Sat Jul 23 11:55:20 2016 +0900 Merge tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk fixes from Michael Turquette: "Fix a bug in the at91 clk driver, two compile time warnings in sunxi clk drivers, and one bug in a sunxi clk driver introduced in the 4.7 merge window" * tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: clk: at91: fix clk_programmable_set_parent() clk: sunxi: remove unused variable clk: sunxi: display: Add per-clock flags clk: sunxi: tcon-ch1: Do not return a negative error in get_parent commit a933f80d948e85aa2ac2724a6167d509339fc6b9 Merge: ea4b3cf 1488a1e Author: Linus Torvalds Date: Sat Jul 23 11:46:59 2016 +0900 Merge branch 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata Pull libata fix from Tejun Heo: "Another fallout from max_sectors bump a couple years ago. The lite-on optical drive times out on large requests" * 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata: libata: LITE-ON CX1-JB256-HP needs lower max_sectors commit ea4b3cfa6a328ee87286ea3d4c18929898f76a95 Merge: b6cbeca b3802db Author: Linus Torvalds Date: Sat Jul 23 11:43:17 2016 +0900 Merge tag 'mmc-v4.7-rc7' of git://git.linaro.org/people/ulf.hansson/mmc Pull MMC fixes from Ulf Hansson: "Here are a few late mmc fixes intended for v4.7 final. MMC core: - Fix eMMC packed command header endianness - Fix free of uninitialized buffer for mmc ioctl MMC host: - pxamci: Fix potential oops in ->probe()" * tag 'mmc-v4.7-rc7' of git://git.linaro.org/people/ulf.hansson/mmc: mmc: pxamci: fix potential oops mmc: block: fix packed command header endianness mmc: block: fix free of uninitialized 'idata->buf' commit b6cbecaebd45374f6ecf7de574d0f027d1690836 Merge: ff8d6fa 76df529 Author: Linus Torvalds Date: Sat Jul 23 11:28:06 2016 +0900 Merge tag 'sound-4.7-fix2' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "No surprise, just a few small fixes: a couple of changes are seen in the core part, and both of them are rather for unusual error paths. The rest are the regular HD-audio fixes and one USB-audio regression fix" * tag 'sound-4.7-fix2' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: usb-audio: Fix quirks code is not called ALSA: hda: add AMD Stoney PCI ID with proper driver caps ALSA: hda - fix use-after-free after module unload ALSA: pcm: Free chmap at PCM free callback, too ALSA: ctl: Stop notification after disconnection ALSA: hda/realtek - add new pin definition in alc225 pin quirk table commit ff8d6facda455c129357e891e31dd0aa21a96ed0 Merge: 47ef4ad 32f0c4a Author: Linus Torvalds Date: Sat Jul 23 11:22:37 2016 +0900 Merge branch 'for-linus' of git://git.kernel.dk/linux-block Pull NVMe fix from Jens Axboe: "Late addition here, it's basically a revert of a patch that was added in this merge window, but has proven to cause problems. This is swapping out the RCU based namespace protection with a good old mutex instead" * 'for-linus' of git://git.kernel.dk/linux-block: nvme: Remove RCU namespace protection commit 368301f2fe4b07e5fb71dba3cc566bc59eb6705f Author: Jiri Slaby Date: Wed Jul 20 15:45:08 2016 -0700 pps: do not crash when failed to register With this command sequence: modprobe plip modprobe pps_parport rmmod pps_parport the partport_pps modules causes this crash: BUG: unable to handle kernel NULL pointer dereference at (null) IP: parport_detach+0x1d/0x60 [pps_parport] Oops: 0000 [#1] SMP ... Call Trace: parport_unregister_driver+0x65/0xc0 [parport] SyS_delete_module+0x187/0x210 The sequence that builds up to this is: 1) plip is loaded and takes the parport device for exclusive use: plip0: Parallel port at 0x378, using IRQ 7. 2) pps_parport then fails to grab the device: pps_parport: parallel port PPS client parport0: cannot grant exclusive access for device pps_parport pps_parport: couldn't register with parport0 3) rmmod of pps_parport is then killed because it tries to access pardev->name, but pardev (taken from port->cad) is NULL. So add a check for NULL in the test there too. Link: http://lkml.kernel.org/r/20160714115245.12651-1-jslaby@suse.cz Signed-off-by: Jiri Slaby Acked-by: Rodolfo Giometti Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds drivers/pps/clients/pps_parport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d6a4d64812bb12dda53704943b61a7496d02098 Author: Dan Carpenter Date: Wed Jul 20 15:45:05 2016 -0700 tools/vm/slabinfo: fix an unintentional printf The curly braces are missing here so we print stuff unintentionally. Fixes: 9da4714a2d44 ('slub: slabinfo update for cmpxchg handling') Link: http://lkml.kernel.org/r/20160715211243.GE19522@mwanda Signed-off-by: Dan Carpenter Acked-by: Christoph Lameter Cc: Sergey Senozhatsky Cc: Colin Ian King Cc: Laura Abbott Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds tools/vm/slabinfo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b301aac5ad67079710a1a7c7b15bf62cddd63295 Author: Dan Carpenter Date: Wed Jul 20 15:45:03 2016 -0700 testing/radix-tree: fix a macro expansion bug There are no parentheses around this macro and it causes a problem when we do: index = rand() % THRASH_SIZE; Link: http://lkml.kernel.org/r/20160715210953.GC19522@mwanda Signed-off-by: Dan Carpenter Acked-by: Ross Zwisler Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds tools/testing/radix-tree/tag_check.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3cb9185c67304b2a7ea9be73e7d13df6fb2793a1 Author: Andrey Ryabinin Date: Wed Jul 20 15:45:00 2016 -0700 radix-tree: fix radix_tree_iter_retry() for tagged iterators. radix_tree_iter_retry() resets slot to NULL, but it doesn't reset tags. Then NULL slot and non-zero iter.tags passed to radix_tree_next_slot() leading to crash: RIP: radix_tree_next_slot include/linux/radix-tree.h:473 find_get_pages_tag+0x334/0x930 mm/filemap.c:1452 .... Call Trace: pagevec_lookup_tag+0x3a/0x80 mm/swap.c:960 mpage_prepare_extent_to_map+0x321/0xa90 fs/ext4/inode.c:2516 ext4_writepages+0x10be/0x2b20 fs/ext4/inode.c:2736 do_writepages+0x97/0x100 mm/page-writeback.c:2364 __filemap_fdatawrite_range+0x248/0x2e0 mm/filemap.c:300 filemap_write_and_wait_range+0x121/0x1b0 mm/filemap.c:490 ext4_sync_file+0x34d/0xdb0 fs/ext4/fsync.c:115 vfs_fsync_range+0x10a/0x250 fs/sync.c:195 vfs_fsync fs/sync.c:209 do_fsync+0x42/0x70 fs/sync.c:219 SYSC_fdatasync fs/sync.c:232 SyS_fdatasync+0x19/0x20 fs/sync.c:230 entry_SYSCALL_64_fastpath+0x23/0xc1 arch/x86/entry/entry_64.S:207 We must reset iterator's tags to bail out from radix_tree_next_slot() and go to the slow-path in radix_tree_next_chunk(). Fixes: 46437f9a554f ("radix-tree: fix race in gang lookup") Link: http://lkml.kernel.org/r/1468495196-10604-1-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin Reported-by: Dmitry Vyukov Acked-by: Konstantin Khlebnikov Cc: Matthew Wilcox Cc: Hugh Dickins Cc: Ross Zwisler Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/radix-tree.h | 1 + 1 file changed, 1 insertion(+) commit 73f576c04b9410ed19660f74f97521bee6e1c546 Author: Johannes Weiner Date: Wed Jul 20 15:44:57 2016 -0700 mm: memcontrol: fix cgroup creation failure after many small jobs The memory controller has quite a bit of state that usually outlives the cgroup and pins its CSS until said state disappears. At the same time it imposes a 16-bit limit on the CSS ID space to economically store IDs in the wild. Consequently, when we use cgroups to contain frequent but small and short-lived jobs that leave behind some page cache, we quickly run into the 64k limitations of outstanding CSSs. Creating a new cgroup fails with -ENOSPC while there are only a few, or even no user-visible cgroups in existence. Although pinning CSSs past cgroup removal is common, there are only two instances that actually need an ID after a cgroup is deleted: cache shadow entries and swapout records. Cache shadow entries reference the ID weakly and can deal with the CSS having disappeared when it's looked up later. They pose no hurdle. Swap-out records do need to pin the css to hierarchically attribute swapins after the cgroup has been deleted; though the only pages that remain swapped out after offlining are tmpfs/shmem pages. And those references are under the user's control, so they are manageable. This patch introduces a private 16-bit memcg ID and switches swap and cache shadow entries over to using that. This ID can then be recycled after offlining when the CSS remains pinned only by objects that don't specifically need it. This script demonstrates the problem by faulting one cache page in a new cgroup and deleting it again: set -e mkdir -p pages for x in `seq 128000`; do [ $((x % 1000)) -eq 0 ] && echo $x mkdir /cgroup/foo echo $$ >/cgroup/foo/cgroup.procs echo trex >pages/$x echo $$ >/cgroup/cgroup.procs rmdir /cgroup/foo done When run on an unpatched kernel, we eventually run out of possible IDs even though there are no visible cgroups: [root@ham ~]# ./cssidstress.sh [...] 65000 mkdir: cannot create directory '/cgroup/foo': No space left on device After this patch, the IDs get released upon cgroup destruction and the cache and css objects get released once memory reclaim kicks in. [hannes@cmpxchg.org: init the IDR] Link: http://lkml.kernel.org/r/20160621154601.GA22431@cmpxchg.org Fixes: b2052564e66d ("mm: memcontrol: continue cache reclaim from offlined groups") Link: http://lkml.kernel.org/r/20160617162516.GD19084@cmpxchg.org Signed-off-by: Johannes Weiner Reported-by: John Garcia Reviewed-by: Vladimir Davydov Acked-by: Tejun Heo Cc: Nikolay Borisov Cc: [3.19+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/memcontrol.h | 25 ++++++-------- mm/memcontrol.c | 82 ++++++++++++++++++++++++++++++++++++++++++---- mm/slab_common.c | 4 +-- 3 files changed, 87 insertions(+), 24 deletions(-) commit 0bfb85c6ba620c39c0e5124851a1bea0f5a56e05 Author: Arnd Bergmann Date: Wed Jul 6 14:54:03 2016 +0200 gpio: tegra: don't auto-enable for COMPILE_TEST I stumbled over a build error with COMPILE_TEST and CONFIG_OF disabled: drivers/gpio/gpio-tegra.c: In function 'tegra_gpio_probe': drivers/gpio/gpio-tegra.c:603:9: error: 'struct gpio_chip' has no member named 'of_node' The problem is that the newly added GPIO_TEGRA Kconfig symbol does not have a dependency on CONFIG_OF. However, there is another problem here as the driver gets enabled unconditionally whenever COMPILE_TEST is set. This fixes both problems, by making the symbol user-visible when COMPILE_TEST is set and default-enabled for ARCH_TEGRA=y. As a side-effect, it is now possible to compile-test a Tegra kernel with GPIO support disabled, which is harmless. Signed-off-by: Arnd Bergmann Fixes: 4dd4dd1d2120 ("gpio: tegra: Allow compile test") Signed-off-by: Linus Walleij drivers/gpio/Kconfig | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 930c532869774ebf8af9efe9484c597f896a7d46 Author: Ilya Dryomov Date: Tue Jul 19 03:50:28 2016 +0200 libceph: apply new_state before new_up_client on incrementals Currently, osd_weight and osd_state fields are updated in the encoding order. This is wrong, because an incremental map may look like e.g. new_up_client: { osd=6, addr=... } # set osd_state and addr new_state: { osd=6, xorstate=EXISTS } # clear osd_state Suppose osd6's current osd_state is EXISTS (i.e. osd6 is down). After applying new_up_client, osd_state is changed to EXISTS | UP. Carrying on with the new_state update, we flip EXISTS and leave osd6 in a weird "!EXISTS but UP" state. A non-existent OSD is considered down by the mapping code 2087 for (i = 0; i < pg->pg_temp.len; i++) { 2088 if (ceph_osd_is_down(osdmap, pg->pg_temp.osds[i])) { 2089 if (ceph_can_shift_osds(pi)) 2090 continue; 2091 2092 temp->osds[temp->size++] = CRUSH_ITEM_NONE; and so requests get directed to the second OSD in the set instead of the first, resulting in OSD-side errors like: [WRN] : client.4239 192.168.122.21:0/2444980242 misdirected client.4239.1:2827 pg 2.5df899f2 to osd.4 not [1,4,6] in e680/680 and hung rbds on the client: [ 493.566367] rbd: rbd0: write 400000 at 11cc00000 (0) [ 493.566805] rbd: rbd0: result -6 xferred 400000 [ 493.567011] blk_update_request: I/O error, dev rbd0, sector 9330688 The fix is to decouple application from the decoding and: - apply new_weight first - apply new_state before new_up_client - twiddle osd_state flags if marking in - clear out some of the state if osd is destroyed Fixes: http://tracker.ceph.com/issues/14901 Cc: stable@vger.kernel.org # 3.15+: 6dd74e44dc1d: libceph: set 'exists' flag for newly up osd Cc: stable@vger.kernel.org # 3.15+ Signed-off-by: Ilya Dryomov Reviewed-by: Josh Durgin net/ceph/osdmap.c | 156 +++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 113 insertions(+), 43 deletions(-) commit 87dcdebd6beb54f183ae874664ba47bf071ebf95 Author: Herbert Xu Date: Fri Jul 22 17:58:21 2016 +0800 crypto: rsa-pkcs1pad - fix rsa-pkcs1pad request struct To allow for child request context the struct akcipher_request child_req needs to be at the end of the structure. Cc: stable@vger.kernel.org Signed-off-by: Tadeusz Struk Signed-off-by: Herbert Xu crypto/rsa-pkcs1pad.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cfc9fde0b07c3b44b570057c5f93dda59dca1c94 Author: Maxim Patlasov Date: Thu Jul 21 18:24:26 2016 -0700 ovl: verify upper dentry in ovl_remove_and_whiteout() The upper dentry may become stale before we call ovl_lock_rename_workdir. For example, someone could (mistakenly or maliciously) manually unlink(2) it directly from upperdir. To ensure it is not stale, let's lookup it after ovl_lock_rename_workdir and and check if it matches the upper dentry. Essentially, it is the same problem and similar solution as in commit 11f3710417d0 ("ovl: verify upper dentry before unlink and rename"). Signed-off-by: Maxim Patlasov Signed-off-by: Miklos Szeredi Cc: fs/overlayfs/dir.c | 54 ++++++++++++++++++++++++------------------------------ 1 file changed, 24 insertions(+), 30 deletions(-) commit f8e7718cc0445587fe8530fc2d240d9aac2c9072 Author: Soheil Hassas Yeganeh Date: Wed Jul 20 18:01:18 2016 -0400 packet: propagate sock_cmsg_send() error sock_cmsg_send() can return different error codes and not only -EINVAL, and we should properly propagate them. Fixes: c14ac9451c34 ("sock: enable timestamping using control messages") Signed-off-by: Soheil Hassas Yeganeh Cc: Willem de Bruijn Signed-off-by: David S. Miller net/packet/af_packet.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 81dc0365cfa7bc7c08a0e44d9ee04964df782e19 Author: Jan Stancek Date: Thu Jun 30 12:23:51 2016 +0200 crypto: qat - make qat_asym_algs.o depend on asn1 headers Parallel build can sporadically fail because asn1 headers may not be built yet by the time qat_asym_algs.o is compiled: drivers/crypto/qat/qat_common/qat_asym_algs.c:55:32: fatal error: qat_rsapubkey-asn1.h: No such file or directory #include "qat_rsapubkey-asn1.h" Cc: stable@vger.kernel.org Signed-off-by: Jan Stancek Signed-off-by: Herbert Xu drivers/crypto/qat/qat_common/Makefile | 1 + 1 file changed, 1 insertion(+) commit e9003c9cfaa17d26991688268b04244adb67ee2b Author: Michael Welling Date: Wed Jul 20 10:02:07 2016 -0700 Input: tsc200x - report proper input_dev name Passes input_id struct to the common probe function for the tsc200x drivers instead of just the bustype. This allows for the use of the product variable to set the input_dev->name variable according to the type of touchscreen used. Note that when we introduced support for TSC2004 we started calling everything TSC200X, so let's keep this quirk. Signed-off-by: Michael Welling Cc: stable@vger.kernel.org Acked-by: Pavel Machek Acked-by: Pali Rohár Signed-off-by: Dmitry Torokhov drivers/input/touchscreen/tsc2004.c | 7 ++++++- drivers/input/touchscreen/tsc2005.c | 7 ++++++- drivers/input/touchscreen/tsc200x-core.c | 15 ++++++++++++--- drivers/input/touchscreen/tsc200x-core.h | 2 +- 4 files changed, 25 insertions(+), 6 deletions(-) commit 510cccb5b0c8868a2b302a0ab524da7912da648b Author: Dmitry Torokhov Date: Mon Jun 27 14:12:34 2016 -0700 tty/vt/keyboard: fix OOB access in do_compute_shiftstate() The size of individual keymap in drivers/tty/vt/keyboard.c is NR_KEYS, which is currently 256, whereas number of keys/buttons in input device (and therefor in key_down) is much larger - KEY_CNT - 768, and that can cause out-of-bound access when we do sym = U(key_maps[0][k]); with large 'k'. To fix it we should not attempt iterating beyond smaller of NR_KEYS and KEY_CNT. Also while at it let's switch to for_each_set_bit() instead of open-coding it. Reported-by: Sasha Levin Reviewed-by: Guenter Roeck Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/tty/vt/keyboard.c | 30 +++++++++--------------------- 1 file changed, 9 insertions(+), 21 deletions(-) commit 882b0f2fba83374149f0a5869d95aa8b44dad31e Author: Saeed Mahameed Date: Thu Jul 21 00:39:53 2016 +0300 net/mlx5e: Fix del vxlan port command buffer memset memset the command buffers rather than the pointers to them. Fixes: b3f63c3d5e2c ("net/mlx5e: Add netdev support for VXLAN tunneling") Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/vxlan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit edbe77462302ec0b11a90244de13f9012118c538 Author: Yoshihiro Shimoda Date: Tue Jul 19 14:40:51 2016 +0900 packet: fix second argument of sock_tx_timestamp() This patch fixes an issue that a syscall (e.g. sendto syscall) cannot work correctly. Since the sendto syscall doesn't have msg_control buffer, the sock_tx_timestamp() in packet_snd() cannot work correctly because the socks.tsflags is set to 0. So, this patch sets the socks.tsflags to sk->sk_tsflags as default. Fixes: c14ac9451c34 ("sock: enable timestamping using control messages") Reported-by: Kazuya Mizuguchi Reported-by: Keita Kobayashi Signed-off-by: Yoshihiro Shimoda Acked-by: Soheil Hassas Yeganeh Acked-by: Willem de Bruijn Signed-off-by: David S. Miller net/packet/af_packet.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e4add7b6beaff4061693d0632bc1dcb306edba10 Author: Andrew Duggan Date: Tue Jul 19 17:53:59 2016 -0700 Input: synaptics-rmi4 - fix maximum size check for F12 control register 8 According to the RMI4 spec the maximum size of F12 control register 8 is 15 bytes. The current code incorrectly reports an error if control 8 is greater then 14. Making sensors with a control register 8 with 15 bytes unusable. Signed-off-by: Andrew Duggan Reported-by: Chris Healy Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/rmi4/rmi_f12.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit eabfdda93477f6ee5e153f560560e9cb1c617fd7 Author: Vivien Didelot Date: Mon Jul 18 15:02:06 2016 -0400 net: switchdev: change ageing_time type to clock_t The switchdev value for the SWITCHDEV_ATTR_ID_BRIDGE_AGEING_TIME attribute is a clock_t and requires to use helpers such as clock_t_to_jiffies() to convert to milliseconds. Change ageing_time type from u32 to clock_t to make it explicit. Fixes: f55ac58ae64c ("switchdev: add bridge ageing_time attribute") Signed-off-by: Vivien Didelot Signed-off-by: David S. Miller include/net/switchdev.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97b041971e1c70da077fcfa7a50b362e22cd241e Author: Douglas Miller Date: Mon Jul 18 12:28:45 2016 -0500 Update maintainer for EHEA driver. Since Thadeu left IBM, EHEA has gone mostly unmaintained, since his email address doesn't work anymore. I'm stepping up to help maintain this driver upstream. I'm adding Thadeu's personal e-mail address in Cc, hoping that we can get his ack. CC: Thadeu Lima de Souza Cascardo Signed-off-by: Douglas Miller Acked-by: Thadeu Lima de Souza Cascardo Signed-off-by: David S. Miller MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5ec6df777b5e76398e8f1fbbe7cd21e78890c71a Merge: c74bfbd ec25bc0 Author: David S. Miller Date: Tue Jul 19 16:44:12 2016 -0700 Merge branch 'mlx4-fixes' Tariq Toukan says: ==================== Safe flow for mlx4_en configuration change This patchset improves the mlx4_en driver resiliency, especially on systems with low memory. Upon a configuration change that requires the allocation of new resources, we first try to allocate, prior to destroying the current ones. Once it is successfully done, we release the old resources and attach the new ones. Otherwise, we stay with a functioning interface having the same old configuration. This improvement became of greater significance after removing the use of vmap. ==================== Signed-off-by: David S. Miller commit ec25bc04ed8e12947738468cbe2191f1529f9e39 Author: Eugenia Emantayev Date: Mon Jul 18 18:35:12 2016 +0300 net/mlx4_en: Add resilience in low memory systems This patch fixes the lost of Ethernet port on low memory system, when driver frees its resources and fails to allocate new resources. Issue could happen while changing number of channels, rings size or changing the timestamp configuration. This fix is necessary because of removing vmap use in the code. When vmap was in use driver could allocate non-contiguous memory and make it contiguous with vmap. Now it could fail to allocate a large chunk of contiguous memory and lose the port. Current code tries to allocate new resources and then upon success frees the old resources. Fixes: 73898db04301 ('net/mlx4: Avoid wrong virtual mappings') Signed-off-by: Eugenia Emantayev Signed-off-by: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/en_ethtool.c | 54 +++++++----- drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 106 +++++++++++++++++++++--- drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 9 +- 3 files changed, 132 insertions(+), 37 deletions(-) commit 30f56e3ced0f4966e8a84ece1acceccbbb73d365 Author: Eugenia Emantayev Date: Mon Jul 18 18:35:11 2016 +0300 net/mlx4_en: Move filters cleanup to a proper location Filters cleanup should be done once before destroying net device, since filters list is contained in the private data. Fixes: 1eb8c695bda9 ('net/mlx4_en: Add accelerated RFS support') Signed-off-by: Eugenia Emantayev Signed-off-by: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 4 ++++ drivers/net/ethernet/mellanox/mlx4/en_rx.c | 3 --- 2 files changed, 4 insertions(+), 3 deletions(-) commit a72255983f12f31f0c8d8275fb1a781546cfacb7 Author: Dan Williams Date: Tue Jul 19 12:32:39 2016 -0700 nfit: make DIMM DSMs optional Commit 4995734e973a "acpi, nfit: fix acpi_check_dsm() vs zero functions implemented" attempted to fix a QEMU regression by supporting its usage of a zero-mask as a valid response to a DSM-family probe request. However, this behavior breaks HP platforms that return a zero-mask by default causing the probe to misidentify the DSM-family. Instead, the QEMU regression can be fixed by simply not requiring the DSM family to be identified. This effectively reverts commit 4995734e973a, and removes the DSM requirement from the init path. Cc: "Rafael J. Wysocki" Cc: Xiao Guangrong Cc: Linda Knippers Fixes: 4995734e973a ("acpi, nfit: fix acpi_check_dsm() vs zero functions implemented") Reported-by: Jerry Hoemann Tested-by: Jerry Hoemann Signed-off-by: Dan Williams drivers/acpi/nfit.c | 11 ++++++----- drivers/acpi/utils.c | 6 +++--- 2 files changed, 9 insertions(+), 8 deletions(-) commit cad7d8d9041c00142f91585b2bf0b2673cb152ef Merge: 84ade45 a4a027a Author: Dave Airlie Date: Tue Jul 19 18:00:15 2016 +1000 Merge tag 'topic/kbl-4.7-fixes-2016-07-18' of git://anongit.freedesktop.org/drm-intel into drm-fixes As promised here's the pile of kbl cherry-picks assembled by Mika&Rodrigo. It's a bit much, but all well-contained to kbl code and been tested for a while in drm-intel-next. Still separate in case too much, but in that case I think we'd need to disable kbl by default again (which would be annoying too) in 4.7. * tag 'topic/kbl-4.7-fixes-2016-07-18' of git://anongit.freedesktop.org/drm-intel: (28 commits) drm/i915/kbl: Introduce the first official DMC for Kabylake. drm/i915: Introduce Kabypoint PCH for Kabylake H/DT. drm/i915/gen9: implement WaConextSwitchWithConcurrentTLBInvalidate drm/i915/gen9: Add WaFbcHighMemBwCorruptionAvoidance drm/i195/fbc: Add WaFbcNukeOnHostModify drm/i915/gen9: Add WaFbcWakeMemOn drm/i915/gen9: Add WaFbcTurnOffFbcWatermark drm/i915/kbl: Add WaClearSlmSpaceAtContextSwitch drm/i915/gen9: Add WaEnableChickenDCPR drm/i915/kbl: Add WaDisableSbeCacheDispatchPortSharing drm/i915/kbl: Add WaDisableGafsUnitClkGating drm/i915/kbl: Add WaForGAMHang drm/i915: Add WaInsertDummyPushConstP for bxt and kbl drm/i915/kbl: Add WaDisableDynamicCreditSharing drm/i915/kbl: Add WaDisableGamClockGating drm/i915/gen9: Enable must set chicken bits in config0 reg drm/i915/kbl: Add WaDisableLSQCROPERFforOCL drm/i915/kbl: Add WaDisableSDEUnitClockGating drm/i915/kbl: Add WaDisableFenceDestinationToSLM for A0 drm/i915/kbl: Add WaEnableGapsTsvCreditFix ... commit 6bd80f372371a7b3f5ff13e4e8a560066299c001 Author: Geert Uytterhoeven Date: Mon Jun 6 09:43:00 2016 +0200 m68k/defconfig: Update defconfigs for v4.7-rc2 Signed-off-by: Geert Uytterhoeven arch/m68k/configs/amiga_defconfig | 4 ++++ arch/m68k/configs/apollo_defconfig | 4 ++++ arch/m68k/configs/atari_defconfig | 4 ++++ arch/m68k/configs/bvme6000_defconfig | 4 ++++ arch/m68k/configs/hp300_defconfig | 4 ++++ arch/m68k/configs/mac_defconfig | 4 ++++ arch/m68k/configs/multi_defconfig | 4 ++++ arch/m68k/configs/mvme147_defconfig | 4 ++++ arch/m68k/configs/mvme16x_defconfig | 4 ++++ arch/m68k/configs/q40_defconfig | 4 ++++ arch/m68k/configs/sun3_defconfig | 4 ++++ arch/m68k/configs/sun3x_defconfig | 4 ++++ 12 files changed, 48 insertions(+) commit 84ade45e056f2e292f07c54446c176d0112d9574 Merge: 47ef4ad ed2eebb Author: Dave Airlie Date: Tue Jul 19 16:09:20 2016 +1000 Merge tag 'drm-intel-fixes-2016-07-18' of git://anongit.freedesktop.org/drm-intel into drm-fixes Two more regression fixes for 4.7. * tag 'drm-intel-fixes-2016-07-18' of git://anongit.freedesktop.org/drm-intel: drm/i915: add missing condition for committing planes on crtc drm/i915: Treat eDP as always connected, again commit c74bfbdba0e8d056e4ba579a666b5cdb8ec3cd35 Author: Willem de Bruijn Date: Sat Jul 16 17:33:15 2016 -0400 sctp: load transport header after sk_filter Do not cache pointers into the skb linear segment across sk_filter. The function call can trigger pskb_expand_head. Signed-off-by: Willem de Bruijn Acked-by: Daniel Borkmann Acked-by: Marcelo Ricardo Leitner Signed-off-by: David S. Miller net/sctp/input.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 0564bf0afae443deeb16f36e2c39fefff89d05f2 Author: Konstantin Khlebnikov Date: Sat Jul 16 17:08:56 2016 +0300 net/sched/sch_htb: clamp xstats tokens to fit into 32-bit int In kernel HTB keeps tokens in signed 64-bit in nanoseconds. In netlink protocol these values are converted into pshed ticks (64ns for now) and truncated to 32-bit. In struct tc_htb_xstats fields "tokens" and "ctokens" are declared as unsigned 32-bit but they could be negative thus tool 'tc' prints them as signed. Big values loose higher bits and/or become negative. This patch clamps tokens in xstat into range from INT_MIN to INT_MAX. In this way it's easier to understand what's going on here. Signed-off-by: Konstantin Khlebnikov Signed-off-by: David S. Miller net/sched/sch_htb.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit f96423f483b1a7854270335b319e8d1cdd6f3585 Author: Boris Brezillon Date: Mon Jul 18 09:49:12 2016 +0200 clk: at91: fix clk_programmable_set_parent() Since commit 1bdf02326b71e ("clk: at91: make use of syscon/regmap internally"), clk_programmable_set_parent() is always selecting the first parent (AKA slow_clk), no matter what's passed in the 'index' parameter. Fix that by initializing the pckr variable to the index value. Signed-off-by: Boris Brezillon Reported-by: Hans Verkuil Fixes: 1bdf02326b71e ("clk: at91: make use of syscon/regmap internally") Cc: Signed-off-by: Michael Turquette Link: lkml.kernel.org/r/1468828152-18389-1-git-send-email-boris.brezillon@free-electrons.com drivers/clk/at91/clk-programmable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1488a1e3828d60d74c9b802a05e24c0487babe4e Author: Tejun Heo Date: Mon Jul 18 18:40:00 2016 -0400 libata: LITE-ON CX1-JB256-HP needs lower max_sectors Since 34b48db66e08 ("block: remove artifical max_hw_sectors cap"), max_sectors is no longer limited to BLK_DEF_MAX_SECTORS and LITE-ON CX1-JB256-HP keeps timing out with higher max_sectors. Revert it to the previous value. Signed-off-by: Tejun Heo Reported-by: dgerasimov@gmail.com Link: https://bugzilla.kernel.org/show_bug.cgi?id=121671 Cc: stable@vger.kernel.org # v3.19+ Fixes: 34b48db66e08 ("block: remove artifical max_hw_sectors cap") Signed-off-by: Tejun Heo drivers/ata/libata-core.c | 6 ++++++ 1 file changed, 6 insertions(+) commit a4a027a860ff58df8df0796d730397a3b30dbc9a Author: Rodrigo Vivi Date: Tue Apr 26 14:59:51 2016 -0700 drm/i915/kbl: Introduce the first official DMC for Kabylake. Version 1.01. This firmware is made for Kabylake platform so it doesn't need the stepping workaround that we had before. v2: Rebased on top of latest nightly with min version required change. v3: With right CSR_VERSION (Patrik). Cc: Christophe Prigent Cc: Patrik Jakobsson Reviewed-by: Ben Widawsky (v1) Signed-off-by: Rodrigo Vivi Reviewed-by: Patrik Jakobsson Link: http://patchwork.freedesktop.org/patch/msgid/1461707991-15336-1-git-send-email-rodrigo.vivi@intel.com (cherry picked from commit 4922d4919596219864686be1e70dcd92c685ec9f) Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/intel_csr.c | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) commit ed2eebbd61af8d378ca39ad7aef7017f29eed6f3 Author: Lionel Landwerlin Date: Wed May 25 14:30:41 2016 +0100 drm/i915: add missing condition for committing planes on crtc The i915 driver checks for color management properties changes as part of a plane update. Therefore a color management update must imply a plane update, otherwise we never update the transformation matrixes and degamma/gamma LUTs. v2: add comment about moving the commit of color management registers to an async worker v3: Commit color management register right after vblank v4: Move back color management commit condition together with planes commit v5: Trigger color management commit through the planes commit (Daniel) v6: Make plane change update more readable Fixes: 20a34e78f0d7 (drm/i915: Update color management during vblank evasion.) Cc: Maarten Lankhorst Cc: Ville Syrjälä Cc: Daniel Vetter Cc: drm-intel-fixes@lists.freedesktop.org Signed-off-by: Lionel Landwerlin References: https://lkml.org/lkml/2016/7/14/614 Reviewed-and-tested-by: Mario Kleiner Link: http://patchwork.freedesktop.org/patch/msgid/1464183041-8478-1-git-send-email-lionel.g.landwerlin@intel.com (cherry picked from commit e7852a4b3a4fb6f6c18fdaff934580aa8521599a) Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/intel_display.c | 6 ++++++ 1 file changed, 6 insertions(+) commit c71d4d58981bed3366769ef5cf1f20e588fe16d0 Author: Ville Syrjälä Date: Mon Jul 18 13:15:14 2016 +0300 drm/i915: Treat eDP as always connected, again eDP should be treated as connected even if doesn't have an EDID. In that case we'll use the timings from the VBT. That used to be the case until commit f21a21983ef1 ("drm/i915: Splitting intel_dp_detect") broke things by considering even eDP disconnected if we fail to get an EDID for it. Fix things up again by treating eDP as always connected. Cc: Shubhangi Shrivastava Cc: Nathan D Ciobanu Cc: Sivakumar Thulasimani Cc: Ander Conselvan de Oliveira Cc: Larry Finger Reported-by: Larry Finger Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96675 Cc: drm-intel-fixes@lists.freedesktop.org Fixes: f21a21983ef1 ("drm/i915: Splitting intel_dp_detect") Signed-off-by: Ville Syrjälä Tested-by: Larry Finger Link: http://patchwork.freedesktop.org/patch/msgid/1468836914-16537-1-git-send-email-ville.syrjala@linux.intel.com (cherry picked from commit 1b7f2c8b0773d5ccbef43ef38a13ad33136c9679) Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 76df52969711ae3725a98f26fbbc6a349803dcbf Author: Kazuki Oikawa Date: Mon Jul 18 01:16:15 2016 +0900 ALSA: usb-audio: Fix quirks code is not called snd_usb_{set_interface,ctl_msg}_quirk checks chip->usb_id to need calling a quirks code. But existed code path that not calling dev_set_drvdata in usb_audio_probe. Fixes: 79289e24194a ("ALSA: usb-audio: Refer to chip->usb_id for quirks and MIDI creation") Signed-off-by: Kazuki Oikawa Cc: # v4.6+ Reviewed-by: Takashi Sakamoto Tested-by: Takashi Sakamoto Signed-off-by: Takashi Iwai sound/usb/card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3802db5eb72d2a96f4aa4ff0abb937033df2acf Author: Robert Jarzmik Date: Thu Jul 14 17:05:50 2016 +0200 mmc: pxamci: fix potential oops As reported by Dan in his report in [1], there is a potential NULL pointer derefence if these conditions are met : - there is no platform_data provided, ie. host->pdata = NULL Fix this by only using the platform data ro_invert when a gpio for read-only is provided by the platform data. This doesn't appear yet as every pxa board provides a platform_data, and calls pxa_set_mci_info() with a non NULL pointer. [1] [bug report] mmc: pxamci: fix card detect with slot-gpio API. The commit fd546ee6a7dc ("mmc: pxamci: fix card detect with slot-gpio API") from Sep 26, 2015, leads to the following static checker warning: drivers/mmc/host/pxamci.c:809 pxamci_probe() warn: variable dereferenced before check 'host->pdata' (see line 798) Fixes: fd546ee6a7dc ("mmc: pxamci: fix card detect with slot-gpio API") Reported-by: Dan Carpenter Signed-off-by: Robert Jarzmik Signed-off-by: Ulf Hansson drivers/mmc/host/pxamci.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit f68381a70bb2b26c31b13fdaf67c778f92fd32b4 Author: Taras Kondratiuk Date: Wed Jul 13 22:05:38 2016 +0000 mmc: block: fix packed command header endianness The code that fills packed command header assumes that CPU runs in little-endian mode. Hence the header is malformed in big-endian mode and causes MMC data transfer errors: [ 563.200828] mmcblk0: error -110 transferring data, sector 2048, nr 8, cmd response 0x900, card status 0xc40 [ 563.219647] mmcblk0: packed cmd failed, nr 2, sectors 16, failure index: -1 Convert header data to LE. Signed-off-by: Taras Kondratiuk Fixes: ce39f9d17c14 ("mmc: support packed write command for eMMC4.5 devices") Cc: Signed-off-by: Ulf Hansson drivers/mmc/card/block.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit bfe5b1b1e013f7b1c0fd2ac3b3c8c380114b3fb9 Author: Ville Viinikka Date: Fri Jul 8 18:27:02 2016 +0300 mmc: block: fix free of uninitialized 'idata->buf' Set 'idata->buf' to NULL so that it never gets returned without initialization. This fixes a bug where mmc_blk_ioctl_cmd() would free both 'idata' and 'idata->buf' but 'idata->buf' was returned uninitialized. Fixes: 1ff8950c0433 ("mmc: block: change to use kmalloc when copy data from userspace") Signed-off-by: Ville Viinikka Cc: Signed-off-by: Ulf Hansson drivers/mmc/card/block.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit acddc72015e5bc8f640b02d38b36afd7841c9c14 Author: Mat Martineau Date: Mon Jul 18 00:10:55 2016 +0100 KEYS: Fix for erroneous trust of incorrectly signed X.509 certs Arbitrary X.509 certificates without authority key identifiers (AKIs) can be added to "trusted" keyrings, including IMA or EVM certs loaded from the filesystem. Signature verification is currently bypassed for certs without AKIs. Trusted keys were recently refactored, and this bug is not present in 4.6. restrict_link_by_signature should return -ENOKEY (no matching parent certificate found) if the certificate being evaluated has no AKIs, instead of bypassing signature checks and returning 0 (new certificate accepted). Reported-by: Petko Manolov Signed-off-by: Mat Martineau Signed-off-by: David Howells Signed-off-by: James Morris crypto/asymmetric_keys/restrict.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d128471a14775cd11abd81c09b2a086997ab3150 Author: Lans Zhang Date: Mon Jul 18 00:10:47 2016 +0100 pefile: Fix the failure of calculation for digest Commit e68503bd68 forgot to set digest_len and thus cause the following error reported by kexec when launching a crash kernel: kexec_file_load failed: Bad message Fixes: e68503bd68 (KEYS: Generalise system_verify_data() to provide access to internal content) Signed-off-by: Lans Zhang Tested-by: Dave Young Signed-off-by: David Howells Cc: Baoquan He Cc: Vivek Goyal cc: kexec@lists.infradead.org cc: linux-crypto@vger.kernel.org Signed-off-by: James Morris crypto/asymmetric_keys/mscode_parser.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit a46e667887448da10e26e46442bda01d1f311aaf Author: Lans Zhang Date: Mon Jul 18 00:10:39 2016 +0100 PKCS#7: Fix panic when referring to the empty AKID when DEBUG defined This fix resolves the following kernel panic if an empty or missing AuthorityKeyIdentifier is encountered and DEBUG is defined in pkcs7_verify.c. [ 459.041989] PKEY: <==public_key_verify_signature() = 0 [ 459.041993] PKCS7: Verified signature 1 [ 459.041995] PKCS7: ==> pkcs7_verify_sig_chain() [ 459.041999] PKCS7: verify Sample DB Certificate for SCP: 01 [ 459.042002] PKCS7: - issuer Sample KEK Certificate for SCP [ 459.042014] BUG: unable to handle kernel NULL pointer dereference at (null) [ 459.042135] IP: [] pkcs7_verify+0x72c/0x7f0 [ 459.042217] PGD 739e6067 PUD 77719067 PMD 0 [ 459.042286] Oops: 0000 [#1] PREEMPT SMP [ 459.042328] Modules linked in: [ 459.042368] CPU: 0 PID: 474 Comm: kexec Not tainted 4.7.0-rc7-WR8.0.0.0_standard+ #18 [ 459.042462] Hardware name: To be filled by O.E.M. To be filled by O.E.M./Aptio CRB, BIOS 5.6.5 10/09/2014 [ 459.042586] task: ffff880073a50000 ti: ffff8800738e8000 task.ti: ffff8800738e8000 [ 459.042675] RIP: 0010:[] [] pkcs7_verify+0x72c/0x7f0 [ 459.042784] RSP: 0018:ffff8800738ebd58 EFLAGS: 00010246 [ 459.042845] RAX: 0000000000000000 RBX: ffff880076b7da80 RCX: 0000000000000006 [ 459.042929] RDX: 0000000000000001 RSI: ffffffff81c85001 RDI: ffffffff81ca00a9 [ 459.043014] RBP: ffff8800738ebd98 R08: 0000000000000400 R09: ffff8800788a304c [ 459.043098] R10: 0000000000000000 R11: 00000000000060ca R12: ffff8800769a2bc0 [ 459.043182] R13: ffff880077358300 R14: 0000000000000000 R15: ffff8800769a2dc0 [ 459.043268] FS: 00007f24cc741700(0000) GS:ffff880074e00000(0000) knlGS:0000000000000000 [ 459.043365] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 459.043431] CR2: 0000000000000000 CR3: 0000000073a36000 CR4: 00000000001006f0 [ 459.043514] Stack: [ 459.043530] 0000000000000000 ffffffbf00000020 31ffffff813e68b0 0000000000000002 [ 459.043644] ffff8800769a2bc0 0000000000000000 00000000007197b8 0000000000000002 [ 459.043756] ffff8800738ebdd8 ffffffff81153fb1 0000000000000000 0000000000000000 [ 459.043869] Call Trace: [ 459.043898] [] verify_pkcs7_signature+0x61/0x140 [ 459.043974] [] verify_pefile_signature+0x2cb/0x830 [ 459.044052] [] ? verify_pefile_signature+0x830/0x830 [ 459.044134] [] bzImage64_verify_sig+0x15/0x20 [ 459.046332] [] arch_kexec_kernel_verify_sig+0x29/0x40 [ 459.048552] [] SyS_kexec_file_load+0x1f4/0x6c0 [ 459.050768] [] ? __do_page_fault+0x1b6/0x550 [ 459.052996] [] entry_SYSCALL_64_fastpath+0x17/0x93 [ 459.055242] Code: e8 0a d6 ff ff 85 c0 0f 88 7a fb ff ff 4d 39 fd 4d 89 7d 08 74 45 4d 89 fd e9 14 fe ff ff 4d 8b 76 08 31 c0 48 c7 c7 a9 00 ca 81 <41> 0f b7 36 49 8d 56 02 e8 d0 91 d6 ff 4d 8b 3c 24 4d 85 ff 0f [ 459.060535] RIP [] pkcs7_verify+0x72c/0x7f0 [ 459.063040] RSP [ 459.065456] CR2: 0000000000000000 [ 459.075998] ---[ end trace c15f0e897cda28dc ]--- Signed-off-by: Lans Zhang Signed-off-by: David Howells Cc: Dave Young Cc: Baoquan He Cc: Vivek Goyal cc: linux-crypto@vger.kernel.org cc: kexec@lists.infradead.org Signed-off-by: James Morris crypto/asymmetric_keys/pkcs7_verify.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8e6ce7ebeb34f0992f56de078c3744fb383657fa Author: Florian Fainelli Date: Fri Jul 15 16:42:16 2016 -0700 net: cavium: liquidio: Avoid dma_unmap_single on uninitialized ndata The label lio_xmit_failed is used 3 times through liquidio_xmit() but it always makes a call to dma_unmap_single() using potentially uninitialized variables from "ndata" variable. Out of the 3 gotos, 2 run after ndata has been initialized, and had a prior dma_map_single() call. Fix this by adding a new error label: lio_xmit_dma_failed which does this dma_unmap_single() and then processed with the lio_xmit_failed fallthrough. Fixes: f21fb3ed364bb ("Add support of Cavium Liquidio ethernet adapters") Reported-by: coverity (CID 1309740) Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/cavium/liquidio/lio_main.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit ea6ff112b095dce2060c304195904d859c3e2625 Author: Florian Fainelli Date: Fri Jul 15 16:41:16 2016 -0700 net: nb8800: Fix SKB leak in nb8800_receive() In case nb8800_receive() fails to allocate a fragment, we would leak the SKB freshly allocated and just return, instead, free it. Reported-by: coverity (CID 1341750) Signed-off-by: Florian Fainelli Acked-by: Mans Rullgard Signed-off-by: David S. Miller drivers/net/ethernet/aurora/nb8800.c | 1 + 1 file changed, 1 insertion(+) commit de702da7a823ab0c4a1e53ed79a2695f0d453855 Author: Florian Fainelli Date: Fri Jul 15 16:40:22 2016 -0700 et131x: Fix logical vs bitwise check in et131x_tx_timeout() We should be using a logical check here instead of a bitwise operation to check if the device is closed already in et131x_tx_timeout(). Reported-by: coverity (CID 146498) Fixes: 38df6492eb511 ("et131x: Add PCIe gigabit ethernet driver et131x to drivers/net") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/agere/et131x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 18d3df3eab23796d7f852f9c6bb60962b8372ced Author: Paolo Abeni Date: Thu Jul 14 18:00:10 2016 +0200 vlan: use a valid default mtu value for vlan over macsec macsec can't cope with mtu frames which need vlan tag insertion, and vlan device set the default mtu equal to the underlying dev's one. By default vlan over macsec devices use invalid mtu, dropping all the large packets. This patch adds a netif helper to check if an upper vlan device needs mtu reduction. The helper is used during vlan devices initialization to set a valid default and during mtu updating to forbid invalid, too bit, mtu values. The helper currently only check if the lower dev is a macsec device, if we get more users, we need to update only the helper (possibly reserving an additional IFF bit). Signed-off-by: Paolo Abeni Signed-off-by: David S. Miller include/linux/netdevice.h | 7 +++++++ net/8021q/vlan_dev.c | 10 ++++++---- net/8021q/vlan_netlink.c | 7 +++++-- 3 files changed, 18 insertions(+), 6 deletions(-) commit 47ef4ad2684d380dd6d596140fb79395115c3950 Merge: 6315170 7ce9ea7 Author: Linus Torvalds Date: Sat Jul 16 09:53:34 2016 +0900 Merge tag 'for-linus-20160715' of git://git.infradead.org/linux-mtd Pull MTD fix from Brian Norris: "Late MTD fix for v4.7: One regression in the Device Tree handling for OMAP NAND handling of the ELM node. TI migrated to using the property name "ti,elm-id", but forgot to keep compatibility with the old "elm_id" property. Also, might as well send out this MAINTAINERS fixup now" * tag 'for-linus-20160715' of git://git.infradead.org/linux-mtd: mtd: nand: omap2: Add check for old elm binding MAINTAINERS: Add file patterns for mtd device tree bindings commit e86663c475d384ab5f46cb5637e9b7ad08c5c505 Author: Florian Fainelli Date: Fri Jul 15 15:42:52 2016 -0700 net: bgmac: Fix infinite loop in bgmac_dma_tx_add() Nothing is decrementing the index "i" while we are cleaning up the fragments we could not successful transmit. Fixes: 9cde94506eacf ("bgmac: implement scatter/gather support") Reported-by: coverity (CID 1352048) Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bgmac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 631517032f261f6fd35d11321cd2ba695573f2ed Merge: 8dcf5a8 6a5029e Author: Linus Torvalds Date: Sat Jul 16 07:04:12 2016 +0900 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull input fixes from Dmitry Torokhov: "A few last-minute updates for the input subsystem" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: ts4800-ts - add missing of_node_put after calling of_parse_phandle Input: synaptics-rmi4 - use of_get_child_by_name() to fix refcount Revert "Input: wacom_w8001 - drop use of ABS_MT_TOOL_TYPE" Input: xpad - validate USB endpoint count during probe Input: add SW_PEN_INSERTED define commit f57ec1889f5e830e93723d1262fd9c73703d531d Merge: dd79cf7 11719a5 Author: David S. Miller Date: Fri Jul 15 14:49:51 2016 -0700 Merge branch 'mlxsw-fixes' Jiri Pirko says: ==================== mlxsw: Couple of fixes Couple of fixes for mlxsw driver from Ido. ==================== Signed-off-by: David S. Miller commit 11719a58bdf7724c463db54ea2abcec54a87b69c Author: Ido Schimmel Date: Fri Jul 15 11:15:02 2016 +0200 mlxsw: spectrum: Prevent invalid ingress buffer mapping Packets entering the switch are mapped to a Switch Priority (SP) according to their PCP value (untagged frames are mapped to SP 0). The packets are classified to a priority group (PG) buffer in the port's headroom according to their SP. The switch maintains another mapping (SP to IEEE priority), which is used to generate PFC frames for lossless PGs. This mapping is initialized to IEEE = SP % 8. Therefore, when mapping SP 'x' to PG 'y' we create a situation in which an IEEE priority is mapped to two different PGs: IEEE 'x' ---> SP 'x' ---> PG 'y' IEEE 'x' ---> SP 'x + 8' ---> PG '0' (default) Which is invalid, as a flow can use only one PG buffer. Fix this by mapping both SP 'x' and 'x + 8' to the same PG buffer. Fixes: 8e8dfe9fdf06 ("mlxsw: spectrum: Add IEEE 802.1Qaz ETS support") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/reg.h | 17 ++++++++++++++++- drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 2 +- drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 3 ++- 3 files changed, 19 insertions(+), 3 deletions(-) commit 28f5275e4aab97680c8243ec26e202e44c99e5bf Author: Ido Schimmel Date: Fri Jul 15 11:15:01 2016 +0200 mlxsw: spectrum: Prevent overwrite of DCB capability fields The number of supported traffic classes that can have ETS and PFC simultaneously enabled is not subject to user configuration, so make sure we always initialize them to the correct values following a set operation. Fixes: 8e8dfe9fdf06 ("mlxsw: spectrum: Add IEEE 802.1Qaz ETS support") Fixes: d81a6bdb87ce ("mlxsw: spectrum: Add IEEE 802.1Qbb PFC support") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 2 ++ 1 file changed, 2 insertions(+) commit 7347180dcaed9c5582732f9372ac940b9b1a907d Author: Ido Schimmel Date: Fri Jul 15 11:15:00 2016 +0200 mlxsw: spectrum: Don't emit errors when PFC is disabled We can't have PAUSE frames and PFC both enabled on the same port, but the fact that ieee_setpfc() was called doesn't necessarily mean PFC is enabled. Only emit errors when PAUSE frames and PFC are enabled simultaneously. Fixes: d81a6bdb87ce ("mlxsw: spectrum: Add IEEE 802.1Qbb PFC support") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c3f1576810affced47684e04a08c1ffa845144c9 Author: Ido Schimmel Date: Fri Jul 15 11:14:59 2016 +0200 mlxsw: spectrum: Indicate support for autonegotiation The device supports link autonegotiation, so let the user know about it by indicating support via ethtool ops. Fixes: 56ade8fe3fe1 ("mlxsw: spectrum: Add initial support for Spectrum ASIC") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6277d46b10a0b35c83656f085cf8e32ded6fdd60 Author: Ido Schimmel Date: Fri Jul 15 11:14:58 2016 +0200 mlxsw: spectrum: Force link training according to admin state When setting a new speed we need to disable and enable the port for the changes to take effect. We currently only do that if the operational state of the port is up. However, setting a new speed following link training failure will require us to explicitly set the port down and then up. Instead, disable and enable the port based on its administrative state. Fixes: 56ade8fe3fe1 ("mlxsw: spectrum: Add initial support for Spectrum ASIC") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 25 +------------------------ 1 file changed, 1 insertion(+), 24 deletions(-) commit 8dcf5a80dd186ae1a19357e5a32f198bee107723 Merge: 3e0a396 d945b5e Author: Linus Torvalds Date: Sat Jul 16 06:36:55 2016 +0900 Merge branch 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq Pull workqueue fix from Tejun Heo: "The optimization for setting unbound worker affinity masks collided with recent scheduler changes triggering warning messages. This late pull request fixes the bug by removing the optimization" * 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq: workqueue: Fix setting affinity of unbound worker threads commit 3e0a396546450536679ae4d3bd70290ce0b0c79c Author: Jann Horn Date: Fri Sep 11 21:39:33 2015 +0200 xfs: fix type confusion in xfs_ioc_swapext Without this check, the following XFS_I invocations would return bad pointers when used on non-XFS inodes (perhaps pointers into preceding allocator chunks). This could be used by an attacker to trick xfs_swap_extents into performing locking operations on attacker-chosen structures in kernel memory, potentially leading to code execution in the kernel. (I have not investigated how likely this is to be usable for an attack in practice.) Signed-off-by: Jann Horn Cc: Andy Lutomirski Cc: Dave Chinner Signed-off-by: Linus Torvalds fs/xfs/xfs_ioctl.c | 6 ++++++ 1 file changed, 6 insertions(+) commit dd79cf7dd10028d00f99d332d5a0d04734908282 Merge: c961e87 7f6c553 Author: David S. Miller Date: Fri Jul 15 14:27:44 2016 -0700 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/net-queue Jeff Kirsher says: ==================== Intel Wired LAN Driver Updates 2016-07-14 This series contains fixes to i40e and ixgbe. Alex fixes issues found in i40e_rx_checksum() which was broken, where the checksum was being returned valid when it was not. Kiran fixes a bug which was found when we abruptly remove a cable which caused a panic. Set the VSI broadcast promiscuous mode during VSI add sequence and prevents adding MAC filter if specified MAC address is broadcast. Paolo Abeni fixes a bug by returning the actual work done, capped to weight - 1, since the core doesn't allow to return the full budget when the driver modifies the NAPI status. Guilherme Piccoli fixes an issue where the q_vector initialization routine sets the affinity _mask of a q_vector based on v_idx value. This means a loop iterates on v_idx, which is an incremental value, and the cpumask is created based on this value. This is a problem in systems with multiple logical CPUs per core (like in SMT scenarios). Changed the way q_vector's affinity_mask is created to resolve the issue. ==================== Signed-off-by: David S. Miller commit c961e877cff4b669788900a7e12386f67efbe2d3 Author: Grant Grundler Date: Thu Jul 14 11:27:16 2016 -0700 r8152: add MODULE_VERSION ethtool -i provides a driver version that is hard coded. Export the same value via "modinfo". Signed-off-by: Grant Grundler Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 1 + 1 file changed, 1 insertion(+) commit 083ae308280d13d187512b9babe3454342a7987e Author: Jason Baron Date: Thu Jul 14 11:38:40 2016 -0400 tcp: enable per-socket rate limiting of all 'challenge acks' The per-socket rate limit for 'challenge acks' was introduced in the context of limiting ack loops: commit f2b2c582e824 ("tcp: mitigate ACK loops for connections as tcp_sock") And I think it can be extended to rate limit all 'challenge acks' on a per-socket basis. Since we have the global tcp_challenge_ack_limit, this patch allows for tcp_challenge_ack_limit to be set to a large value and effectively rely on the per-socket limit, or set tcp_challenge_ack_limit to a lower value and still prevents a single connections from consuming the entire challenge ack quota. It further moves in the direction of eliminating the global limit at some point, as Eric Dumazet has suggested. This a follow-up to: Subject: tcp: make challenge acks less predictable Cc: Eric Dumazet Cc: David S. Miller Cc: Neal Cardwell Cc: Yuchung Cheng Cc: Yue Cao Signed-off-by: Jason Baron Signed-off-by: David S. Miller net/ipv4/tcp_input.c | 39 ++++++++++++++++++++++----------------- 1 file changed, 22 insertions(+), 17 deletions(-) commit aa93d1fee85c890a34f2510a310e55ee76a27848 Author: James Patrick-Evans Date: Fri Jul 15 16:40:45 2016 +0100 media: fix airspy usb probe error path Fix a memory leak on probe error of the airspy usb device driver. The problem is triggered when more than 64 usb devices register with v4l2 of type VFL_TYPE_SDR or VFL_TYPE_SUBDEV. The memory leak is caused by the probe function of the airspy driver mishandeling errors and not freeing the corresponding control structures when an error occours registering the device to v4l2 core. A badusb device can emulate 64 of these devices, and then through continual emulated connect/disconnect of the 65th device, cause the kernel to run out of RAM and crash the kernel, thus causing a local DOS vulnerability. Fixes CVE-2016-5400 Signed-off-by: James Patrick-Evans Reviewed-by: Kees Cook Cc: stable@vger.kernel.org # 3.17+ Signed-off-by: Linus Torvalds drivers/media/usb/airspy/airspy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 0ba169ac3600ae4032ee14b4192e6bf5d67723f5 Author: Tony Luck Date: Thu Jul 14 15:38:43 2016 -0700 EDAC, sb_edac: Fix Knights Landing In commit 2c1ea4c700af ("EDAC, sb_edac: Use cpu family/model in driver detection") I broke Knights Landing because I failed to notice that it called a wrapper macro "sbridge_get_all_devices_knl" instead of "sbridge_get_all_devices" like all the other types. Now that we include the processor type in the pci_id_table structure we can skip the wrappers and just have the sbridge_get_all_devices() check the type to decide whether to allow duplicate devices and controllers to have registers spread across buses. Fixes: 2c1ea4c700af ("EDAC, sb_edac: Use cpu family/model in driver detection") Tested-by: Lukasz Odzioba Acked-by: Aristeu Rozanski Signed-off-by: Tony Luck Signed-off-by: Linus Torvalds drivers/edac/sb_edac.c | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) commit 6a5029e66404462a3322dba8e35615bd09332081 Author: Peter Chen Date: Fri Jul 15 09:32:54 2016 -0700 Input: ts4800-ts - add missing of_node_put after calling of_parse_phandle of_node_put needs to be called when the device node which is got from of_parse_phandle has finished using. Signed-off-by: Peter Chen Signed-off-by: Dmitry Torokhov drivers/input/touchscreen/ts4800-ts.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit bc7135b9a430520448590ffeb1ff54c0b4dfd8d5 Author: Rodrigo Vivi Date: Fri Jul 1 17:07:12 2016 -0700 drm/i915: Introduce Kabypoint PCH for Kabylake H/DT. Some Kabylake SKUs are going to use Kabypoint PCH. It is mainly for Halo and DT ones. >From our specs it doesn't seem that KBP brings any change on the display south engine. So let's consider this as a continuation of SunrisePoint, i.e., SPT+. Since it is easy to get confused by a letter change: KBL = Kabylake - CPU/GPU codename. KBP = Kabypoint - PCH codename. Signed-off-by: Rodrigo Vivi Reviewed-by: Ander Conselvan de Oliveira Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96826 Link: http://patchwork.freedesktop.org/patch/msgid/1467418032-15167-1-git-send-email-rodrigo.vivi@intel.com Signed-off-by: Rodrigo Vivi (cherry picked from commit 22dea0be50b2eb0bafd3c82e1fb080113e0c889e) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_drv.c | 4 ++++ drivers/gpu/drm/i915/i915_drv.h | 3 +++ drivers/gpu/drm/i915/i915_irq.c | 4 ++-- drivers/gpu/drm/i915/intel_panel.c | 3 ++- 4 files changed, 11 insertions(+), 3 deletions(-) commit 12be73a0f13ad5a044346d564804b4058426d4c2 Author: Tim Gore Date: Mon Jun 13 12:15:01 2016 +0100 drm/i915/gen9: implement WaConextSwitchWithConcurrentTLBInvalidate This patch enables a workaround for a mid thread preemption issue where a hardware timing problem can prevent the context restore from happening, leading to a hang. v2: move to gen9_init_workarounds (Arun) v3: move to start of gen9_init_workarounds (Arun) Signed-off-by: Tim Gore Reviewed-by: Arun Siluvery Signed-off-by: Tvrtko Ursulin Link: http://patchwork.freedesktop.org/patch/msgid/1465816501-25557-1-git-send-email-tim.gore@intel.com (cherry picked from commit a8ab5ed5e1bf856eceaab5579236de6f92822b9f) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 4 ++++ drivers/gpu/drm/i915/intel_ringbuffer.c | 3 +++ 2 files changed, 7 insertions(+) commit a89bd7beb1791ad5ed634989b14c764114a68e53 Author: Mika Kuoppala Date: Tue Jun 7 17:19:19 2016 +0300 drm/i915/gen9: Add WaFbcHighMemBwCorruptionAvoidance Add this fbc related workaround for all gen9 Cc: Ville Syrjälä Signed-off-by: Mika Kuoppala Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-28-git-send-email-mika.kuoppala@intel.com (cherry picked from commit d1b4eefdea6d63aa15321f539feec298d8aefdc1) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 4 ++++ 2 files changed, 5 insertions(+) commit c584e2d38fb84513944feeb25072dd8b17a6d3b6 Author: Mika Kuoppala Date: Tue Jun 7 17:19:18 2016 +0300 drm/i195/fbc: Add WaFbcNukeOnHostModify Bspec states that we need to set nuke on modify all to prevent screen corruption with fbc on skl and kbl. v2: proper workaround name References: HSD#2227109, HSDES#1404569388 Cc: Ville Syrjälä Signed-off-by: Mika Kuoppala Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-27-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 031cd8c85aefad31e7af91eba7bc4735a6dfcc79) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 10 ++++++++++ 2 files changed, 11 insertions(+) commit 5b889896be07cb12f0401dc2cfdec6eb6413c774 Author: Mika Kuoppala Date: Tue Jun 7 17:19:17 2016 +0300 drm/i915/gen9: Add WaFbcWakeMemOn Set bit 8 in 0x43224 to prevent screen corruption and system hangs on high memory bandwidth conditions. The same wa also suggest setting bit 31 on ARB_CTL. According to another workaround we gain better idle power savings when FBC is enabled. v2: use correct workaround name v3: split out overlapping wa for corruption avoidance (Ville) References: HSD#2137218, HSD#2227171, HSD#2136579, BSID#883 Cc: Paulo Zanoni Cc: Ville Syrjälä Signed-off-by: Mika Kuoppala Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-26-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 303d4ea522e8672a1b62d968a5b6764929adc292) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) commit f20b1ba04e917be9cadd3171a99568a1badb8b1b Author: Mika Kuoppala Date: Tue Jun 7 17:19:16 2016 +0300 drm/i915/gen9: Add WaFbcTurnOffFbcWatermark According to bspec this prevents screen corruption when fbc is used. v2: This workaround has a name, use it (Ville) v3: remove bogus gen check on ilk/vlv wm path (Ville) References: HSD#2135555, HSD#2137270, BSID#562 Cc: Paulo Zanoni Cc: Ville Syrjälä Signed-off-by: Mika Kuoppala Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-25-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 0f78dee6f06a9399d4bdf79575094cc761b872ac) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_pm.c | 4 ++++ 1 file changed, 4 insertions(+) commit 703d1282d513617d9561760309e9acd902c723a7 Author: Mika Kuoppala Date: Tue Jun 7 17:19:15 2016 +0300 drm/i915/kbl: Add WaClearSlmSpaceAtContextSwitch This workaround for bdw and chv, is also needed for kbl A0. References: HSD#1911519, BSID#569 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-24-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 066d462888514af727008a450f4078b1a23d5cbe) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_lrc.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 0e51c0bdc0e6503c9c1cf2c41b2f1ae4e9cf9a8b Author: Mika Kuoppala Date: Tue Jun 7 17:19:13 2016 +0300 drm/i915/gen9: Add WaEnableChickenDCPR Workaround for display underrun issues with Y & Yf Tiling. Set this on all gen9 as stated by bspec. v2: proper workaround name References: HSD#2136383, BSID#857 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-22-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 590e8ff04bc0182dce97228e5e352d6413d80456) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 3 +++ drivers/gpu/drm/i915/intel_pm.c | 4 ++++ 2 files changed, 7 insertions(+) commit 0a3e3f047b13c04cd69bdb5a242330566259fa48 Author: Mika Kuoppala Date: Tue Jun 7 17:19:12 2016 +0300 drm/i915/kbl: Add WaDisableSbeCacheDispatchPortSharing This is needed for all kbl revision. v2: Don't add revid checks to generic gen9 init (Arun) References: HSD#2135593 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-21-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 954337aa96a31f6d4baf1e40ac219fbb1b1d92f4) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++++ 1 file changed, 5 insertions(+) commit 3af5f1137c8b5981c754e47d2c233bc3013d2d00 Author: Mika Kuoppala Date: Tue Jun 7 17:19:11 2016 +0300 drm/i915/kbl: Add WaDisableGafsUnitClkGating We need to disable clock gating in this unit to work around hardware issue causing possible corruption/hang. v2: name the bit (Ville) v3: leave the fix enabled for 2227050 and set correct bit (Matthew) v4: Split out the skl part in separate commit for easier backport References: HSD#2227156, HSD#2227050 Cc: Ville Syrjälä Cc: Matthew Auld Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-20-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 4de5d7ccbccc88d2f7b1bcdc2180196ded7db8b8) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 3 +++ 1 file changed, 3 insertions(+) commit a725e1dc4e16a34e3de79b0a6db2ef608fecae4c Author: Mika Kuoppala Date: Tue Jun 7 17:19:10 2016 +0300 drm/i915/kbl: Add WaForGAMHang Add this workaround for A0 and B0 revisions References: HSD#2226935 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-19-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 0b2d0934edceff9905b1202d0e7e91f1b6228485) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_lrc.c | 36 ++++++++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) commit 7b9005cd45f34f5c87fd2e28f4e56b348af4ddc5 Author: Mika Kuoppala Date: Tue Jun 7 17:19:07 2016 +0300 drm/i915: Add WaInsertDummyPushConstP for bxt and kbl Add this workaround for both bxt and kbl up to until rev B0. References: HSD#2136703 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-16-git-send-email-mika.kuoppala@intel.com (cherry picked from commit ad2bdb44b19529ba992bd0b7667e91b14fe9a9ee) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.c | 10 ++++++++++ 2 files changed, 11 insertions(+) commit b90420467232529a4448364d8bd860fc0176d3b6 Author: Mika Kuoppala Date: Tue Jun 7 17:19:06 2016 +0300 drm/i915/kbl: Add WaDisableDynamicCreditSharing Bspec states that we need to turn off dynamic credit sharing on kbl revid a0 and b0. This happens by writing bit 28 on 0x4ab8. References: HSD#2225601, HSD#2226938, HSD#2225763 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-15-git-send-email-mika.kuoppala@intel.com (cherry picked from commit c0b730d572ea00d427f6112b17982c6b9d5e97bb) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 3 +++ drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++++ 2 files changed, 8 insertions(+) commit 4ac4199434ac1d847e02c61a6e9d1cb35bb91b0e Author: Mika Kuoppala Date: Tue Jun 7 17:19:05 2016 +0300 drm/i915/kbl: Add WaDisableGamClockGating According to bspec we need to disable gam unit clock gating on on kbl revids A0 and B0. References: HSD#2226858, HSD#1944358 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-14-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 8aeb7f624fbf8a68a9c67f831d4158a0f80ea920) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 5 +++++ 2 files changed, 6 insertions(+) commit 11b283412e165abf1ad19c1ba4bdde399944b600 Author: Mika Kuoppala Date: Tue Jun 7 17:19:04 2016 +0300 drm/i915/gen9: Enable must set chicken bits in config0 reg The bspec states that these must be set in CONFIG0 for all gen9. v2: rebase v3: fix spacing (Matthew) References: HSD#2134995 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-13-git-send-email-mika.kuoppala@intel.com (cherry picked from commit b033bb6d5d3a0e51d56b3ba929a8db4e18da0892) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 3 +++ drivers/gpu/drm/i915/intel_pm.c | 24 ++++++++++++++---------- 2 files changed, 17 insertions(+), 10 deletions(-) commit 738fa1b3123f9a3b4374b4156ad54a2b64273f51 Author: Mika Kuoppala Date: Tue Jun 7 17:19:03 2016 +0300 drm/i915/kbl: Add WaDisableLSQCROPERFforOCL Extend the scope of this workaround, already used in skl, to also take effect in kbl. v2: Fix KBL_REVID_E0 (Matthew) References: HSD#2132677 Cc: Matthew Auld Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-12-git-send-email-mika.kuoppala@intel.com (cherry picked from commit fe90581987cd5fadd2942f59f8511bcb39fdec34) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_drv.h | 3 +++ drivers/gpu/drm/i915/intel_lrc.c | 6 ++++-- drivers/gpu/drm/i915/intel_ringbuffer.c | 13 +++++++++++++ 3 files changed, 20 insertions(+), 2 deletions(-) commit 9146f308d5916e20c53afe3ee0bd4dbd562a0ef9 Author: Mika Kuoppala Date: Tue Jun 7 17:19:01 2016 +0300 drm/i915/kbl: Add WaDisableSDEUnitClockGating Add this workaround until upto kbl revid B0. References: HSD#1802092 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-10-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 9498dba7b4ffe40a1e2b23d7718b77e49841248f) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_pm.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit 3d042d4633d7b180e08abead7bd7de0bb194b256 Author: Mika Kuoppala Date: Tue Jun 7 17:19:00 2016 +0300 drm/i915/kbl: Add WaDisableFenceDestinationToSLM for A0 Add this workaround for kbl revid A0 only. v2: rebase v3: carve out a non related workaround (Chris) References: HSD#1911714 Cc: Chris Wilson Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-9-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 8401d42fd5adf709281e1700194805f393b49573) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++++ 1 file changed, 5 insertions(+) commit 791645098219ad3fd505db89d953a16275a8c89b Author: Mika Kuoppala Date: Tue Jun 7 17:18:59 2016 +0300 drm/i915/kbl: Add WaEnableGapsTsvCreditFix We need this crucial workaround from skl also to all kbl revisions. Lack of it was causing system hangs on skl enabling so this is a must have. v2: Don't add revid checks to gen9 init workarounds (Arun) References: HSD#2126660 Cc: Arun Siluvery Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-8-git-send-email-mika.kuoppala@intel.com (cherry picked from commit e587f6cb0af140f3c0ea794d8616eb9a29969983) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++++ 1 file changed, 5 insertions(+) commit 60f452e6147bcbe7d38cd2368cf5c7c1c27a4d38 Author: Mika Kuoppala Date: Tue Jun 7 17:18:58 2016 +0300 drm/i915: Mimic skl with WaForceEnableNonCoherent Past evidence with system hangs and hsds tie WaForceEnableNonCoherent and WaDisableHDCInvalidation to WaForceContextSaveRestoreNonCoherent. Documentation states that WaForceContextSaveRestoreNonCoherent would not be needed on skl past E0 but evidence proved otherwise. See commit <510650e8b2ab> ("drm/i915/skl: Fix spurious gpu hang with gt3/gt4 revs"). In this scope consider kbl to be skl with a bigger revision than E0 so play it safe and bind these two workarounds to the WaForceContextSaveRestoreNonCoherent, and apply to all gen9. v2: fix comment (Matthew) References: HSD#2134449, HSD#2131413 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-7-git-send-email-mika.kuoppala@intel.com (cherry picked from commit bbaefe72a00c93c6ec12e029019681e3f7d7de7a) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 37 +++++++++++++++++++-------------- 1 file changed, 21 insertions(+), 16 deletions(-) commit 6fd72492b382cb59beee97c7d5767f6e260620bd Author: Mika Kuoppala Date: Tue Jun 7 17:18:57 2016 +0300 drm/i915/gen9: Always apply WaForceContextSaveRestoreNonCoherent The revision id range for this workaround has changed. So apply it to all revids on all gen9. References: HSD#2134449 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-6-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 5b0e3659296cc4a1484e60640ef10780194a195b) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit 89b54515d35789297611b9deca904da49a377800 Author: Mika Kuoppala Date: Tue Jun 7 17:18:56 2016 +0300 drm/i915/kbl: Add WaSkipStolenMemoryFirstPage for A0 We need this for kbl a0 boards. Note that this should be also for bxt A0 but we omit that on purpose as bxt A0's are out of fashion already. References: HSD#1912158, HSD#4393097 Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-5-git-send-email-mika.kuoppala@intel.com (cherry picked from commit 6e4f10c33a8bd0df4412bc31c0f11930e0228123) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_gem_stolen.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit a1d97ca5b2998d137da4f4673edae472d23742e5 Author: Mika Kuoppala Date: Tue Jun 7 17:18:55 2016 +0300 drm/i915/kbl: Add REVID macro Add REVID macro for kbl to limit wa applicability to particular revision range. Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-4-git-send-email-mika.kuoppala@intel.com (cherry picked from commit c033a37cd42c1b5492d95bfbc8c0891088e04b57) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_drv.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 68370e0ab1636efce7b7e8254430c1ec321564bc Author: Mika Kuoppala Date: Tue Jun 7 17:18:54 2016 +0300 drm/i915/kbl: Init gen9 workarounds Kabylake is part of gen9 family so init the generic gen9 workarounds for it. v2: rebase Signed-off-by: Mika Kuoppala Reviewed-by: Matthew Auld Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-3-git-send-email-mika.kuoppala@intel.com (cherry picked from commit e5f81d65ac5a04020d790caf63b2324730ba0277) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/intel_ringbuffer.c | 48 ++++++++++++++++++++++----------- 1 file changed, 32 insertions(+), 16 deletions(-) commit c000456c8c642c6474cd7b94344ff1c39e91c575 Author: Mika Kuoppala Date: Tue Jun 7 17:18:53 2016 +0300 drm/i915/skl: Add WaDisableGafsUnitClkGating We need to disable clock gating in this unit to work around hardware issue causing possible corruption/hang. v2: name the bit (Ville) v3: leave the fix enabled for 2227050 and set correct bit (Matthew) References: HSD#2227156, HSD#2227050 Cc: Ville Syrjälä Cc: Matthew Auld Reviewed-by: Matthew Auld Signed-off-by: Mika Kuoppala Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-2-git-send-email-mika.kuoppala@intel.com (cherry picked from commit eee8efb02a0f9284d85e6b3688f944ca765d7ad3) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.c | 3 +++ 2 files changed, 4 insertions(+) commit f98edb2b6f6baffe0d2be66ebe761b51486c6a40 Author: arun.siluvery@linux.intel.com Date: Mon Jun 6 09:52:49 2016 +0100 drm/i915/gen9: Add WaVFEStateAfterPipeControlwithMediaStateClear Kernel only need to add a register to HW whitelist, required for a preemption related issue. Reference: HSD#2131039 Reviewed-by: Jeff McGee Signed-off-by: Arun Siluvery Signed-off-by: Tvrtko Ursulin Link: http://patchwork.freedesktop.org/patch/msgid/1465203169-16591-1-git-send-email-arun.siluvery@linux.intel.com (cherry picked from commit 6bb6285582e0cf9b3a8440e0e714aae5f66d9ce2) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++++ 2 files changed, 6 insertions(+) commit da0a0acaf8881c4fb960064d6cf6e7df2fd0f8b5 Author: Daniel Vetter Date: Thu May 19 09:14:20 2016 +0200 drm/i915/psr: Implement PSR2 w/a for gen9 Found this while browsing Bspec. Looks like it applies to both skl and kbl. v2: Also for bxt (Art). Cc: Rodrigo Vivi Cc: Sonika Jindal Cc: Durgadoss R Cc: "Pandiyan, Dhinakaran" Cc: "Runyan, Arthur J" Reviewed-by: Sonika Jindal Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/1463642060-30728-1-git-send-email-daniel.vetter@ffwll.ch (cherry picked from commit dc00b6a07c2206e7b7dbcbeff856049264c40faa) Signed-off-by: Mika Kuoppala drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 17 +++++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) commit fa3a9f5744a92c0d7856d4e326c8d920d1d31116 Merge: 0a9cb48 9babed6 Author: Linus Torvalds Date: Fri Jul 15 16:00:18 2016 +0900 Merge branch 'akpm' (patches from Andrew) Merge misc fixes from Andrew Morton: "20 fixes" * emailed patches from Andrew Morton : m32r: fix build warning about putc mm: workingset: printk missing log level, use pr_info() mm: thp: refix false positive BUG in page_move_anon_rmap() mm: rmap: call page_check_address() with sync enabled to avoid racy check mm: thp: move pmd check inside ptl for freeze_page() vmlinux.lds: account for destructor sections gcov: add support for gcc version >= 6 mm, meminit: ensure node is online before checking whether pages are uninitialised mm, meminit: always return a valid node from early_pfn_to_nid kasan/quarantine: fix bugs on qlist_move_cache() uapi: export lirc.h header madvise_free, thp: fix madvise_free_huge_pmd return value after splitting Revert "scripts/gdb: add documentation example for radix tree" Revert "scripts/gdb: add a Radix Tree Parser" scripts/gdb: Perform path expansion to lx-symbol's arguments scripts/gdb: add constants.py to .gitignore scripts/gdb: rebuild constants.py on dependancy change scripts/gdb: silence 'nothing to do' message kasan: add newline to messages mm, compaction: prevent VM_BUG_ON when terminating freeing scanner commit 0a9cb4815b91378bc7e8a7cda781ee50325bdd54 Merge: 1a86f94 8e0e7ae Author: Linus Torvalds Date: Fri Jul 15 15:42:22 2016 +0900 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma Pull rdma fixes from Doug Ledford: "Round three of 4.7 rc fixes: - two fixes for hfi1 - two fixes for i40iw - one omission correction in the port table counter arrays" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: i40iw: Enable remote access rights for stag allocation i40iw: do not print unitialized variables in error message IB core: Add port_xmit_wait counter IB/hfi1: Fix sleep inside atomic issue in init_asic_data IB/hfi1: Correct issues with sc5 computation commit 7f6c553902bfa1c4e3f6cfa955c5ea036c7fe8e4 Author: Guilherme G. Piccoli Date: Mon Jun 27 12:16:43 2016 -0300 i40e: use valid online CPU on q_vector initialization Currently, the q_vector initialization routine sets the affinity_mask of a q_vector based on v_idx value. Meaning a loop iterates on v_idx, which is an incremental value, and the cpumask is created based on this value. This is a problem in systems with multiple logical CPUs per core (like in SMT scenarios). If we disable some logical CPUs, by turning SMT off for example, we will end up with a sparse cpu_online_mask, i.e., only the first CPU in a core is online, and incremental filling in q_vector cpumask might lead to multiple offline CPUs being assigned to q_vectors. Example: if we have a system with 8 cores each one containing 8 logical CPUs (SMT == 8 in this case), we have 64 CPUs in total. But if SMT is disabled, only the 1st CPU in each core remains online, so the cpu_online_mask in this case would have only 8 bits set, in a sparse way. In general case, when SMT is off the cpu_online_mask has only C bits set: 0, 1*N, 2*N, ..., C*(N-1) where C == # of cores; N == # of logical CPUs per core. In our example, only bits 0, 8, 16, 24, 32, 40, 48, 56 would be set. This patch changes the way q_vector's affinity_mask is created: it iterates on v_idx, but consumes the CPU index from the cpu_online_mask instead of just using the v_idx incremental value. No functional changes were introduced. Signed-off-by: Guilherme G Piccoli Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/i40e/i40e_main.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) commit 1a86f944c7f2b22a81f9a1e6a890be0db5d2444a Merge: 1f027f6 22ebf00 Author: Linus Torvalds Date: Fri Jul 15 15:39:03 2016 +0900 Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux Pull i2c fixes from Wolfram Sang: "Four driver bugfixes for the I2C subsystem" * 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux: i2c: mux: reg: wrong condition checked for of_address_to_resource return value i2c: tegra: Correct error path in probe i2c: remove __init from i2c_register_board_info() i2c: qup: Fix wrong value of index variable commit 4b732cd4bb6006ad7fd4d5cdba27fcb751cdf4b7 Author: Paolo Abeni Date: Wed Jun 15 15:37:59 2016 +0200 ixgbe: napi_poll must return the work done Currently the function ixgbe_poll() returns 0 when it clean completely the rx rings, but this foul budget accounting in core code. Fix this returning the actual work done, capped to weight - 1, since the core doesn't allow to return the full budget when the driver modifies the napi status Signed-off-by: Paolo Abeni Reviewed-by: Venkatesh Srinivas Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6bd09625ba66446821d55c61891bea9e2cdc5b3 Author: Kiran Patil Date: Mon Jun 20 09:10:34 2016 -0700 i40e: enable VSI broadcast promiscuous mode instead of adding broadcast filter This patch sets VSI broadcast promiscuous mode during VSI add sequence and prevents adding MAC filter if specified MAC address is broadcast. Change-ID: Ia62251fca095bc449d0497fc44bec3a5a0136773 Signed-off-by: Kiran Patil Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/i40e/i40e_main.c | 32 ++++++++++++++++++----------- 1 file changed, 20 insertions(+), 12 deletions(-) commit 858296c8784bf98450765cbc6b1bc2e44175cc01 Author: Alexander Duyck Date: Tue Jun 14 15:45:42 2016 -0700 i40e/i40evf: Fix i40e_rx_checksum There are a couple of issues I found in i40e_rx_checksum while doing some recent testing. As a result I have found the Rx checksum logic is pretty much broken and returning that the checksum is valid for tunnels in cases where it is not. First the inner types are not the correct values to use to test for if a tunnel is present or not. In addition the inner protocol types are not a bitmask as such performing an OR of the values doesn't make sense. I have instead changed the code so that the inner protocol types are used to determine if we report CHECKSUM_UNNECESSARY or not. For anything that does not end in UDP, TCP, or SCTP it doesn't make much sense to report a checksum offload since it won't contain a checksum anyway. This leaves us with the need to set the csum_level based on some value. For that purpose I am using the tunnel_type field. If the tunnel type is GRENAT or greater then this means we have a GRE or UDP tunnel with an inner header. In the case of GRE or UDP we will have a possible checksum present so for this reason it should be safe to set the csum_level to 1 to indicate that we are reporting the state of the inner header. Signed-off-by: Alexander Duyck Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/i40e/i40e_txrx.c | 30 +++++++++++++++------------ drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 30 +++++++++++++++------------ 2 files changed, 34 insertions(+), 26 deletions(-) commit 1f027f691ebae1ac79e50938d151e549e9f284f1 Merge: 24ee9a8 d2e1204 Author: Linus Torvalds Date: Fri Jul 15 15:16:13 2016 +0900 Merge tag 'drm-fixes-for-v4.7-rc8-vmware' of git://people.freedesktop.org/~airlied/linux Pull drm vmware fixes from Dave Airlie: "These are some fixes for the vmware graphics driver, that fix some black screen issues on at least Ubuntu 16.04, I think VMware would like to get these in so stable can pick them up ASAP" * tag 'drm-fixes-for-v4.7-rc8-vmware' of git://people.freedesktop.org/~airlied/linux: drm/vmwgfx: Fix error paths when mapping framebuffer drm/vmwgfx: Fix corner case screen target management drm/vmwgfx: Delay pinning fbdev framebuffer until after mode set drm/vmwgfx: Check pin count before attempting to move a buffer drm/ttm: Make ttm_bo_mem_compat available drm/vmwgfx: Add an option to change assumed FB bpp drm/vmwgfx: Work around mode set failure in 2D VMs drm/vmwgfx: Add a check to handle host message failure commit 24ee9a8326e37ae149f7d8160af3f162d65f05dc Merge: d83a4c1 71404e8 Author: Linus Torvalds Date: Fri Jul 15 15:13:06 2016 +0900 Merge tag 'drm-fixes-for-v4.7-rc8' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "These are just some i915 and amdgpu fixes that shows up, the amdgpu ones are polaris fixes, and the i915 one is a major regression fix" * tag 'drm-fixes-for-v4.7-rc8' of git://people.freedesktop.org/~airlied/linux: drm/amdgpu: fix power distribution issue for Polaris10 XT drm/amdgpu: Add a missing register to Polaris golden setting drm/i915: Ignore panel type from OpRegion on SKL drm/i915: Update ifdeffery for mutex->owner commit d83a4c116c4e723840bf9efc47c33ea40c70691b Merge: f97d104 d60585c Author: Linus Torvalds Date: Fri Jul 15 15:02:49 2016 +0900 Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fix from Ingo Molnar: "Fix a CPU hotplug related corruption of the load average that got introduced in this merge window" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/core: Correct off by one bug in load migration calculation commit 9babed6a66b5577628d9e76e5a6cb6104d7ddd4c Author: Sudip Mukherjee Date: Thu Jul 14 12:07:43 2016 -0700 m32r: fix build warning about putc We were getting build warning: arch/m32r/boot/compressed/m32r_sio.c:11:13: warning: conflicting types for built-in function 'putc' Here putc is used as a static function so lets just rename it to avoid the conflict with the builtin putc. Link: http://lkml.kernel.org/r/1466977046-24724-1-git-send-email-sudipm.mukherjee@gmail.com Signed-off-by: Sudip Mukherjee Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/m32r/boot/compressed/m32r_sio.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit d3d36c4b5c5fbdd68542be73ffd53eb210fbf7cf Author: Anton Blanchard Date: Thu Jul 14 12:07:41 2016 -0700 mm: workingset: printk missing log level, use pr_info() Commit 612e44939c3c ("mm: workingset: eviction buckets for bigmem/lowbit machines") added a printk without a log level. Quieten it by using pr_info(). Link: http://lkml.kernel.org/r/1466982072-29836-2-git-send-email-anton@ozlabs.org Signed-off-by: Anton Blanchard Acked-by: Johannes Weiner Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/workingset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5a49973d7143ebbabd76e1dcd69ee42e349bb7b9 Author: Hugh Dickins Date: Thu Jul 14 12:07:38 2016 -0700 mm: thp: refix false positive BUG in page_move_anon_rmap() The VM_BUG_ON_PAGE in page_move_anon_rmap() is more trouble than it's worth: the syzkaller fuzzer hit it again. It's still wrong for some THP cases, because linear_page_index() was never intended to apply to addresses before the start of a vma. That's easily fixed with a signed long cast inside linear_page_index(); and Dmitry has tested such a patch, to verify the false positive. But why extend linear_page_index() just for this case? when the avoidance in page_move_anon_rmap() has already grown ugly, and there's no reason for the check at all (nothing else there is using address or index). Remove address arg from page_move_anon_rmap(), remove VM_BUG_ON_PAGE, remove CONFIG_DEBUG_VM PageTransHuge adjustment. And one more thing: should the compound_head(page) be done inside or outside page_move_anon_rmap()? It's usually pushed down to the lowest level nowadays (and mm/memory.c shows no other explicit use of it), so I think it's better done in page_move_anon_rmap() than by caller. Fixes: 0798d3c022dc ("mm: thp: avoid false positive VM_BUG_ON_PAGE in page_move_anon_rmap()") Link: http://lkml.kernel.org/r/alpine.LSU.2.11.1607120444540.12528@eggly.anvils Signed-off-by: Hugh Dickins Reported-by: Dmitry Vyukov Acked-by: Kirill A. Shutemov Cc: Mika Westerberg Cc: Andrea Arcangeli Cc: Rik van Riel Cc: [4.5+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/rmap.h | 2 +- mm/hugetlb.c | 2 +- mm/memory.c | 3 +-- mm/rmap.c | 9 +++------ 4 files changed, 6 insertions(+), 10 deletions(-) commit 55bda43bb26d2c11eeedac742eff87a8ac34c106 Author: Naoya Horiguchi Date: Thu Jul 14 12:07:35 2016 -0700 mm: rmap: call page_check_address() with sync enabled to avoid racy check The previous patch addresses the race between split_huge_pmd_address() and someone changing the pmd. The fix is only for splitting of normal thp (i.e. pmd-mapped thp,) and for splitting of pte-mapped thp there still is the similar race. For splitting pte-mapped thp, the pte's conversion is done by try_to_unmap_one(TTU_MIGRATION). This function checks page_check_address() to get the target pte, but it can return NULL under some race, leading to VM_BUG_ON() in freeze_page(). Fortunately, page_check_address() already has an argument to decide whether we do a quick/racy check or not, so let's flip it when called from freeze_page(). Link: http://lkml.kernel.org/r/1466990929-7452-2-git-send-email-n-horiguchi@ah.jp.nec.com Signed-off-by: Naoya Horiguchi Cc: Kirill A. Shutemov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/rmap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 33f4751e99601b7bfd1d66aedabd3ee9140922de Author: Naoya Horiguchi Date: Thu Jul 14 12:07:32 2016 -0700 mm: thp: move pmd check inside ptl for freeze_page() I found a race condition triggering VM_BUG_ON() in freeze_page(), when running a testcase with 3 processes: - process 1: keep writing thp, - process 2: keep clearing soft-dirty bits from virtual address of process 1 - process 3: call migratepages for process 1, The kernel message is like this: kernel BUG at /src/linux-dev/mm/huge_memory.c:3096! invalid opcode: 0000 [#1] SMP Modules linked in: cfg80211 rfkill crc32c_intel ppdev serio_raw pcspkr virtio_balloon virtio_console parport_pc parport pvpanic acpi_cpufreq tpm_tis tpm i2c_piix4 virtio_blk virtio_net ata_generic pata_acpi floppy virtio_pci virtio_ring virtio CPU: 0 PID: 28863 Comm: migratepages Not tainted 4.6.0-v4.6-160602-0827-+ #2 Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 task: ffff880037320000 ti: ffff88007cdd0000 task.ti: ffff88007cdd0000 RIP: 0010:[] [] split_huge_page_to_list+0x496/0x590 RSP: 0018:ffff88007cdd3b70 EFLAGS: 00010202 RAX: 0000000000000001 RBX: ffff88007c7b88c0 RCX: 0000000000000000 RDX: 0000000000000000 RSI: 0000000700000200 RDI: ffffea0003188000 RBP: ffff88007cdd3bb8 R08: 0000000000000001 R09: 00003ffffffff000 R10: ffff880000000000 R11: ffffc000001fffff R12: ffffea0003188000 R13: ffffea0003188000 R14: 0000000000000000 R15: 0400000000000080 FS: 00007f8ec241d740(0000) GS:ffff88007dc00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f8ec1f3ed20 CR3: 000000003707b000 CR4: 00000000000006f0 Call Trace: ? list_del+0xd/0x30 queue_pages_pte_range+0x4d1/0x590 __walk_page_range+0x204/0x4e0 walk_page_range+0x71/0xf0 queue_pages_range+0x75/0x90 ? queue_pages_hugetlb+0x190/0x190 ? new_node_page+0xc0/0xc0 ? change_prot_numa+0x40/0x40 migrate_to_node+0x71/0xd0 do_migrate_pages+0x1c3/0x210 SyS_migrate_pages+0x261/0x290 entry_SYSCALL_64_fastpath+0x1a/0xa4 Code: e8 b0 87 fb ff 0f 0b 48 c7 c6 30 32 9f 81 e8 a2 87 fb ff 0f 0b 48 c7 c6 b8 46 9f 81 e8 94 87 fb ff 0f 0b 85 c0 0f 84 3e fd ff ff <0f> 0b 85 c0 0f 85 a6 00 00 00 48 8b 75 c0 4c 89 f7 41 be f0 ff RIP split_huge_page_to_list+0x496/0x590 I'm not sure of the full scenario of the reproduction, but my debug showed that split_huge_pmd_address(freeze=true) returned without running main code of pmd splitting because pmd_present(*pmd) in precheck somehow returned 0. If this happens, the subsequent try_to_unmap() fails and returns non-zero (because page_mapcount() still > 0), and finally VM_BUG_ON() fires. This patch tries to fix it by prechecking pmd state inside ptl. Link: http://lkml.kernel.org/r/1466990929-7452-1-git-send-email-n-horiguchi@ah.jp.nec.com Signed-off-by: Naoya Horiguchi Signed-off-by: Kirill A. Shutemov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/huge_mm.h | 4 ++-- mm/huge_memory.c | 31 ++++++++++++------------------- 2 files changed, 14 insertions(+), 21 deletions(-) commit e41f501d391265ff568f3e49d6128cc30856a36f Author: Dmitry Vyukov Date: Thu Jul 14 12:07:29 2016 -0700 vmlinux.lds: account for destructor sections If CONFIG_KASAN is enabled and gcc is configured with --disable-initfini-array and/or gold linker is used, gcc emits .ctors/.dtors and .text.startup/.text.exit sections instead of .init_array/.fini_array. .dtors section is not explicitly accounted in the linker script and messes vvar/percpu layout. We want: ffffffff822bfd80 D _edata ffffffff822c0000 D __vvar_beginning_hack ffffffff822c0000 A __vvar_page ffffffff822c0080 0000000000000098 D vsyscall_gtod_data ffffffff822c1000 A __init_begin ffffffff822c1000 D init_per_cpu__irq_stack_union ffffffff822c1000 A __per_cpu_load ffffffff822d3000 D init_per_cpu__gdt_page We got: ffffffff8279a600 D _edata ffffffff8279b000 A __vvar_page ffffffff8279c000 A __init_begin ffffffff8279c000 D init_per_cpu__irq_stack_union ffffffff8279c000 A __per_cpu_load ffffffff8279e000 D __vvar_beginning_hack ffffffff8279e080 0000000000000098 D vsyscall_gtod_data ffffffff827ae000 D init_per_cpu__gdt_page This happens because __vvar_page and .vvar get different addresses in arch/x86/kernel/vmlinux.lds.S: . = ALIGN(PAGE_SIZE); __vvar_page = .; .vvar : AT(ADDR(.vvar) - LOAD_OFFSET) { /* work around gold bug 13023 */ __vvar_beginning_hack = .; Discard .dtors/.fini_array/.text.exit, since we don't call dtors. Merge .text.startup into init text. Link: http://lkml.kernel.org/r/1467386363-120030-1-git-send-email-dvyukov@google.com Signed-off-by: Dmitry Vyukov Reviewed-by: Andrey Ryabinin Cc: [4.0+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/asm-generic/vmlinux.lds.h | 4 ++++ 1 file changed, 4 insertions(+) commit d02038f972538b93011d78c068f44514fbde0a8c Author: Florian Meier Date: Thu Jul 14 12:07:26 2016 -0700 gcov: add support for gcc version >= 6 Link: http://lkml.kernel.org/r/20160701130914.GA23225@styxhp Signed-off-by: Florian Meier Reviewed-by: Peter Oberparleiter Tested-by: Peter Oberparleiter Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds kernel/gcov/gcc_4_7.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ef70b6f41cda6270165a6f27b2548ed31cfa3cb2 Author: Mel Gorman Date: Thu Jul 14 12:07:23 2016 -0700 mm, meminit: ensure node is online before checking whether pages are uninitialised early_page_uninitialised looks up an arbitrary PFN. While a machine without node 0 will boot with "mm, page_alloc: Always return a valid node from early_pfn_to_nid", it works because it assumes that nodes are always in PFN order. This is not guaranteed so this patch adds robustness by always checking if the node being checked is online. Link: http://lkml.kernel.org/r/1468008031-3848-4-git-send-email-mgorman@techsingularity.net Signed-off-by: Mel Gorman Acked-by: David Rientjes Cc: [4.2+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_alloc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e4568d3803852d00effd41dcdd489e726b998879 Author: Mel Gorman Date: Thu Jul 14 12:07:20 2016 -0700 mm, meminit: always return a valid node from early_pfn_to_nid early_pfn_to_nid can return node 0 if a PFN is invalid on machines that has no node 0. A machine with only node 1 was observed to crash with the following message: BUG: unable to handle kernel paging request at 000000000002a3c8 PGD 0 Modules linked in: Hardware name: Supermicro H8DSP-8/H8DSP-8, BIOS 080011 06/30/2006 task: ffffffff81c0d500 ti: ffffffff81c00000 task.ti: ffffffff81c00000 RIP: reserve_bootmem_region+0x6a/0xef CR2: 000000000002a3c8 CR3: 0000000001c06000 CR4: 00000000000006b0 Call Trace: free_all_bootmem+0x4b/0x12a mem_init+0x70/0xa3 start_kernel+0x25b/0x49b The problem is that early_page_uninitialised uses the early_pfn_to_nid helper which returns node 0 for invalid PFNs. No caller of early_pfn_to_nid cares except early_page_uninitialised. This patch has early_pfn_to_nid always return a valid node. Link: http://lkml.kernel.org/r/1468008031-3848-3-git-send-email-mgorman@techsingularity.net Signed-off-by: Mel Gorman Acked-by: David Rientjes Cc: [4.2+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0ab686d8c8303069e80300663b3be6201a8697fb Author: Joonsoo Kim Date: Thu Jul 14 12:07:17 2016 -0700 kasan/quarantine: fix bugs on qlist_move_cache() There are two bugs on qlist_move_cache(). One is that qlist's tail isn't set properly. curr->next can be NULL since it is singly linked list and NULL value on tail is invalid if there is one item on qlist. Another one is that if cache is matched, qlist_put() is called and it will set curr->next to NULL. It would cause to stop the loop prematurely. These problems come from complicated implementation so I'd like to re-implement it completely. Implementation in this patch is really simple. Iterate all qlist_nodes and put them to appropriate list. Unfortunately, I got this bug sometime ago and lose oops message. But, the bug looks trivial and no need to attach oops. Fixes: 55834c59098d ("mm: kasan: initial memory quarantine implementation") Link: http://lkml.kernel.org/r/1467766348-22419-1-git-send-email-iamjoonsoo.kim@lge.com Signed-off-by: Joonsoo Kim Reviewed-by: Dmitry Vyukov Acked-by: Andrey Ryabinin Acked-by: Alexander Potapenko Cc: Kuthonuzo Luruo Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/kasan/quarantine.c | 29 +++++++++++------------------ 1 file changed, 11 insertions(+), 18 deletions(-) commit 12cb22bb8ae9aff9d72a9c0a234f26d641b20eb6 Author: Mauro Carvalho Chehab Date: Thu Jul 14 12:07:15 2016 -0700 uapi: export lirc.h header This header contains the userspace API for lirc. This is a fixup for commit b7be755733dc ("[media] bz#75751: Move internal header file lirc.h to uapi/"). It moved the header to the right place, but it forgot to add it at Kbuild. So, despite being at uapi, it is not copied to the right place. Fixes: b7be755733dc44c72 ("[media] bz#75751: Move internal header file lirc.h to uapi/") Link: http://lkml.kernel.org/r/320c765d32bfc82c582e336d52ffe1026c73c644.1468439021.git.mchehab@s-opensource.com Signed-off-by: Mauro Carvalho Chehab Cc: Alec Leamas Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/uapi/linux/Kbuild | 1 + 1 file changed, 1 insertion(+) commit 9818b8cde6221fe7a52aad816425f67d4439b14e Author: Huang Ying Date: Thu Jul 14 12:07:12 2016 -0700 madvise_free, thp: fix madvise_free_huge_pmd return value after splitting madvise_free_huge_pmd should return 0 if the fallback PTE operations are required. In madvise_free_huge_pmd, if part pages of THP are discarded, the THP will be split and fallback PTE operations should be used if splitting succeeds. But the original code will make fallback PTE operations skipped, after splitting succeeds. Fix that via make madvise_free_huge_pmd return 0 after splitting successfully, so that the fallback PTE operations will be done. Link: http://lkml.kernel.org/r/1467135452-16688-1-git-send-email-ying.huang@intel.com Signed-off-by: "Huang, Ying" Acked-by: Minchan Kim Cc: "Kirill A. Shutemov" Cc: Vlastimil Babka Cc: Jerome Marchand Cc: Andrea Arcangeli Cc: Ebru Akagunduz Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/huge_memory.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit ef722fd4a7592ddbfa42bcb3ad8a5caa598589b3 Author: Kieran Bingham Date: Thu Jul 14 12:07:09 2016 -0700 Revert "scripts/gdb: add documentation example for radix tree" This reverts commit 9b5580359a84 ("scripts/gdb: add documentation example for radix tree") The python implementation of radix tree was merged at the same time as a refactoring of the radix tree implementation and doesn't work. The feature is being reverted, thus we revert the documentation as well. Link: http://lkml.kernel.org/r/1467127337-11135-7-git-send-email-kieran@bingham.xyz Signed-off-by: Kieran Bingham Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Documentation/gdb-kernel-debugging.txt | 21 --------------------- 1 file changed, 21 deletions(-) commit b447e02548a3304c47b78b5e2d75a4312a8f17e1 Author: Kieran Bingham Date: Thu Jul 14 12:07:06 2016 -0700 Revert "scripts/gdb: add a Radix Tree Parser" This reverts commit e127a73d41ac ("scripts/gdb: add a Radix Tree Parser") The python implementation of radix-tree was merged at the same time as the radix-tree system was heavily reworked from commit e9256efcc8e3 ("radix-tree: introduce radix_tree_empty") to 3bcadd6fa6c4 ("radix-tree: free up the bottom bit of exceptional entries for reuse") and no longer functions, but also prevents other gdb scripts from loading. This functionality has not yet hit a release, so simply remove it for now Link: http://lkml.kernel.org/r/1467127337-11135-6-git-send-email-kieran@bingham.xyz Signed-off-by: Kieran Bingham Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds scripts/gdb/linux/constants.py.in | 7 --- scripts/gdb/linux/radixtree.py | 97 --------------------------------------- scripts/gdb/vmlinux-gdb.py | 1 - 3 files changed, 105 deletions(-) commit 552ab2a3eaa4338fa5b33aa4c07ea2c542ddcea5 Author: Nikolay Borisov Date: Thu Jul 14 12:07:04 2016 -0700 scripts/gdb: Perform path expansion to lx-symbol's arguments Python doesn't do automatic expansion of paths. In case one passes path of the from ~/foo/bar the gdb scripts won't automatically expand that and as a result the symbols files won't be loaded. Fix this by explicitly expanding all paths which begin with "~" Link: http://lkml.kernel.org/r/1467127337-11135-5-git-send-email-kieran@bingham.xyz Signed-off-by: Nikolay Borisov Signed-off-by: Kieran Bingham Reviewed-by: Jan Kiszka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds scripts/gdb/linux/symbols.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e2aa2f8face230e284f6d344c6a4ee6f53e60207 Author: Omar Sandoval Date: Thu Jul 14 12:07:01 2016 -0700 scripts/gdb: add constants.py to .gitignore Since scripts/gdb/linux/constants.py is autogenerated, this should have been added to .gitignore when it was introduced. Fixes: f197d75fcad1 ("scripts/gdb: provide linux constants") Link: http://lkml.kernel.org/r/1467127337-11135-4-git-send-email-kieran@bingham.xyz Signed-off-by: Omar Sandoval Signed-off-by: Kieran Bingham Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds scripts/gdb/linux/.gitignore | 1 + 1 file changed, 1 insertion(+) commit 834a35296ab0a850e22cda1059e4c05b091c4ad9 Author: Kieran Bingham Date: Thu Jul 14 12:06:58 2016 -0700 scripts/gdb: rebuild constants.py on dependancy change The autogenerated constants.py file was only being built on the initial call, and if the constants.py.in file changed. As we are utilising the CPP hooks, we can successfully use the call if_changed_dep rules to determine when to rebuild the file based on it's inclusions. Link: http://lkml.kernel.org/r/1467127337-11135-3-git-send-email-kieran@bingham.xyz Signed-off-by: Kieran Bingham Reported-by: Jan Kiszka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds scripts/gdb/linux/Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit abb035b48270b226356552486c6de2b1652bdb90 Author: Kieran Bingham Date: Thu Jul 14 12:06:55 2016 -0700 scripts/gdb: silence 'nothing to do' message The constants.py generation, involves a rule to link into the main makefile. This rule has no command and generates a spurious warning message in the build logs when CONFIG_SCRIPTS_GDB is enabled. Fix simply by giving a no-op action Link: http://lkml.kernel.org/r/1467127337-11135-2-git-send-email-kieran@bingham.xyz Signed-off-by: Kieran Bingham Reported-by: Jan Kiszka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds scripts/gdb/linux/Makefile | 1 + 1 file changed, 1 insertion(+) commit 2ba78056acfe8d63a29565f91dae4678ed6b81ca Author: Dmitry Vyukov Date: Thu Jul 14 12:06:53 2016 -0700 kasan: add newline to messages Currently GPF messages with KASAN look as follows: kasan: GPF could be caused by NULL-ptr deref or user memory accessgeneral protection fault: 0000 [#1] SMP DEBUG_PAGEALLOC KASAN Add newlines. Link: http://lkml.kernel.org/r/1467294357-98002-1-git-send-email-dvyukov@google.com Signed-off-by: Dmitry Vyukov Acked-by: Andrey Ryabinin Cc: Alexander Potapenko Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/x86/mm/kasan_init_64.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a46cbf3bc53b6a93fb84a5ffb288c354fa807954 Author: David Rientjes Date: Thu Jul 14 12:06:50 2016 -0700 mm, compaction: prevent VM_BUG_ON when terminating freeing scanner It's possible to isolate some freepages in a pageblock and then fail split_free_page() due to the low watermark check. In this case, we hit VM_BUG_ON() because the freeing scanner terminated early without a contended lock or enough freepages. This should never have been a VM_BUG_ON() since it's not a fatal condition. It should have been a VM_WARN_ON() at best, or even handled gracefully. Regardless, we need to terminate anytime the full pageblock scan was not done. The logic belongs in isolate_freepages_block(), so handle its state gracefully by terminating the pageblock loop and making a note to restart at the same pageblock next time since it was not possible to complete the scan this time. [rientjes@google.com: don't rescan pages in a pageblock] Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1607111244150.83138@chino.kir.corp.google.com Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1606291436300.145590@chino.kir.corp.google.com Signed-off-by: David Rientjes Reported-by: Minchan Kim Tested-by: Minchan Kim Cc: Joonsoo Kim Cc: Hugh Dickins Cc: Mel Gorman Cc: Vlastimil Babka Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/compaction.c | 36 ++++++++++++++---------------------- 1 file changed, 14 insertions(+), 22 deletions(-) commit d2e1204f896b17bda1922f6320d3b442367302fc Merge: 71404e8 58541f7 Author: Dave Airlie Date: Fri Jul 15 13:51:55 2016 +1000 Merge branch 'drm-vmwgfx-fixes' of git://people.freedesktop.org/~syeh/repos_linux into drm-fixes A bunch of vmwgfx fixes that fix a black screen issue on latest distros/hw combos. * 'drm-vmwgfx-fixes' of git://people.freedesktop.org/~syeh/repos_linux: drm/vmwgfx: Fix error paths when mapping framebuffer drm/vmwgfx: Fix corner case screen target management drm/vmwgfx: Delay pinning fbdev framebuffer until after mode set drm/vmwgfx: Check pin count before attempting to move a buffer drm/ttm: Make ttm_bo_mem_compat available drm/vmwgfx: Add an option to change assumed FB bpp drm/vmwgfx: Work around mode set failure in 2D VMs drm/vmwgfx: Add a check to handle host message failure commit 71404e8a88fa4a94b3833ccc853c322fd33336d7 Merge: da03189 aeddda0 Author: Dave Airlie Date: Fri Jul 15 09:19:14 2016 +1000 Merge tag 'drm-intel-fixes-2016-07-14' of git://anongit.freedesktop.org/drm-intel into drm-fixes I've also realized that a pile of hang fixes for kbl landed in next, and no one thought of backporting it to 4.7 - kbl has lost prelim_hw_support tagging in 4.7-rc1 already. Mika is prepping a topic branch for those, will send you a separate pull request since it's quite a bit (but should be all well restricted to kbl code, so similar to polaris in amdgpu). * tag 'drm-intel-fixes-2016-07-14' of git://anongit.freedesktop.org/drm-intel: drm/i915: Ignore panel type from OpRegion on SKL drm/i915: Update ifdeffery for mutex->owner commit 005db31d5f5f7c31cfdc43505d77eb3ca5cf8ec6 Author: Beniamino Galvani Date: Wed Jul 13 18:25:08 2016 +0200 bonding: set carrier off for devices created through netlink Commit e826eafa65c6 ("bonding: Call netif_carrier_off after register_netdevice") moved netif_carrier_off() from bond_init() to bond_create(), but the latter is called only for initial default devices and ones created through sysfs: $ modprobe bonding $ echo +bond1 > /sys/class/net/bonding_masters $ ip link add bond2 type bond $ grep "MII Status" /proc/net/bonding/* /proc/net/bonding/bond0:MII Status: down /proc/net/bonding/bond1:MII Status: down /proc/net/bonding/bond2:MII Status: up Ensure that carrier is initially off also for devices created through netlink. Signed-off-by: Beniamino Galvani Signed-off-by: David S. Miller drivers/net/bonding/bond_netlink.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit da031899f54ad5313e0c3f56967bfde026a512b2 Merge: f97d104 eeade25 Author: Dave Airlie Date: Fri Jul 15 09:17:39 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes Two more polaris fixes. * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: drm/amdgpu: fix power distribution issue for Polaris10 XT drm/amdgpu: Add a missing register to Polaris golden setting commit eeade25ad029cb1f31f27f8e0ddc9bb9c22b5537 Author: Ken Wang Date: Mon Jul 11 13:33:40 2016 +0800 drm/amdgpu: fix power distribution issue for Polaris10 XT Signed-off-by: Ken Wang Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/atombios_i2c.c | 15 +++++++++++++++ drivers/gpu/drm/amd/amdgpu/atombios_i2c.h | 2 ++ drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 5 +++++ 3 files changed, 22 insertions(+) commit 795c2109c287123dfc3bc987d20daef32d77e4d1 Author: Ken Wang Date: Thu Jul 7 09:56:53 2016 +0800 drm/amdgpu: Add a missing register to Polaris golden setting Signed-off-by: Ken Wang Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 2 ++ 1 file changed, 2 insertions(+) commit 9624516db0f3ffcbd1ba1007775d068f54049773 Author: Andrew Duggan Date: Thu Jul 14 09:35:44 2016 -0700 Input: synaptics-rmi4 - use of_get_child_by_name() to fix refcount Calling of_find_node_by_name() assumes that the caller has incremented the refcount of the of_node being passed in. Currently, the caller is not incrementing the refcount of the of_node which results in the node being prematurely freed when of_find_node_by_name() calls of_node_put() on it. Instead use of_get_child_by_name() which does not call put on the of_node. Signed-off-by: Andrew Duggan Signed-off-by: Dmitry Torokhov drivers/input/rmi4/rmi_bus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3e9161bfe0482f26efeaf584d5fd69398c69313c Author: Dmitry Torokhov Date: Thu Jul 14 09:33:41 2016 -0700 Revert "Input: wacom_w8001 - drop use of ABS_MT_TOOL_TYPE" This reverts commit 5f7e5445a2de848c66d2d80ba5479197e8287c33 because removal of input_mt_report_slot_state() means we no longer generate tracking IDs for the reported contacts. Cc: stable@vger.kernel.org Acked-by: Peter Hutterer Acked-by: Ping Cheng drivers/input/touchscreen/wacom_w8001.c | 3 +++ 1 file changed, 3 insertions(+) commit 7ce9ea7e6b35a652034486133174d4e17055cef5 Author: Teresa Remmet Date: Tue Jul 5 11:32:30 2016 +0200 mtd: nand: omap2: Add check for old elm binding commit c9711ec5250b ("mtd: nand: omap: Clean up device tree support") removes the check for the old elm phandle binding. Add it again to keep backward compatibility. Fixes: commit c9711ec5250b ("mtd: nand: omap: Clean up device tree support") Signed-off-by: Teresa Remmet Signed-off-by: Brian Norris drivers/mtd/nand/omap2.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 32f0c4afb4363e31dad49202f1554ba591d649f2 Author: Keith Busch Date: Wed Jul 13 11:45:02 2016 -0600 nvme: Remove RCU namespace protection We can't sleep with RCU read lock held, but we need to do potentially blocking stuff to namespace queues when iterating the list. This patch removes the RCU locking and holds a mutex instead. To prevent deadlocks, this patch removes holding the mutex during namespace scanning and removal. The unlocked namespace scanning is made safe by holding a reference to the namespace being scanned. List iteration that does IO has to be unlocked to allow error recovery. The caller must ensure the list can not be manipulated during such an event, so this patch adds a comment explaining this requirement to the only function that iterates an unlocked list. All callers currently meet this requirement, so no further changes required. List iterations that do not do IO can safely use the lock since it couldn't block recovery from missing forced IO completions. Reported-by: Ming Lin [fixes 0bf77e9 nvme: switch to RCU freeing the namespace] Signed-off-by: Keith Busch Signed-off-by: Jens Axboe drivers/nvme/host/core.c | 74 +++++++++++++++++++++++++----------------------- 1 file changed, 39 insertions(+), 35 deletions(-) commit aeddda06c1a704bb97c8a7bfe7a472120193bd56 Author: Ville Syrjälä Date: Tue Jul 12 15:00:37 2016 +0300 drm/i915: Ignore panel type from OpRegion on SKL Dell XPS 13 9350 apparently doesn't like it when we use the panel type from OpRegion. The OpRegion panel type (0) tells us to use use low vswing for eDP, whereas the VBT panel type (2) tells us to use normal vswing. The problem is that low vswing results in some display flickers. Since no one seems to know how this stuff is supposed to be handled, let's just ignore the OpRegion panel type on SKL for now. v2: Print the panel type correctly in the debug output Reported-by: James Bottomley Cc: James Bottomley Cc: drm-intel-fixes@lists.freedesktop.org References: https://lists.freedesktop.org/archives/intel-gfx/2016-June/098826.html Fixes: a05628195a0d ("drm/i915: Get panel_type from OpRegion panel details") Signed-off-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1468324837-29237-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter Tested-by: James Bottomley Signed-off-by: Ville Syrjälä (cherry picked from commit bb10d4ec3be4b069bfb61c60ca4f708f58f440f1) [danvet: Fix up cherry-pick conflict with an s/dev_priv/dev/.] Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/intel_opregion.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit b19240062722c39fa92c99f04cbfd93034625123 Author: Chris Wilson Date: Mon Jul 11 14:46:17 2016 +0100 drm/i915: Update ifdeffery for mutex->owner In commit 7608a43d8f2e ("locking/mutexes: Use MUTEX_SPIN_ON_OWNER when appropriate") the owner field in the mutex was updated from being dependent upon CONFIG_SMP to using optimistic spin. Update our peek function to suite. Fixes:7608a43d8f2e ("locking/mutexes: Use MUTEX_SPIN_ON_OWNER...") Reported-by: Hong Liu Signed-off-by: Chris Wilson Link: http://patchwork.freedesktop.org/patch/msgid/1468244777-4888-1-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Matthew Auld (cherry picked from commit 4f074a5393431a7d2cc0de7fcfe2f61d24854628) Cc: stable@vger.kernel.org Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/i915_gem_shrinker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f97d10454e4da2aceb44dfa7c59bb43ba9f50199 Merge: a7bf89a eb01950 2c13ce8 Author: Linus Torvalds Date: Thu Jul 14 05:44:47 2016 +0900 Merge branches 'perf-urgent-for-linus' and 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf and timer fixes from Ingo Molnar: "A fix for a posix CPU timers bug, and a perf printk message fix" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf/x86: Fix bogus kernel printk, again * 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: posix_cpu_timer: Exit early when process has been reaped commit a7bf89a1b14c6ebae233275e704587146fbaa5c1 Merge: 2cc499b abb2baf Author: Linus Torvalds Date: Thu Jul 14 05:33:38 2016 +0900 Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Ingo Molnar: "This contains three commits to fix memory corruption bugs with certain Apple AirPort cards, plus a fix for a X86_BUG() ID definitions collision bug in asm/cpufeatures.h" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/quirks: Add early quirk to reset Apple AirPort card x86/quirks: Reintroduce scanning of secondary buses x86/quirks: Apply nvidia_bugs quirk only on root bus x86/cpu: Fix duplicated X86_BUG(9) macro commit 2cc499b398c7bbcbf415017cd9588e699e04cd64 Merge: cf875cc a7c73414 Author: Linus Torvalds Date: Thu Jul 14 05:10:28 2016 +0900 Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull core fixes from Ingo Molnar: "Fix an objtool false positive plus an UP kernel memory corruption bug on certain configs" * 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: cpu/hotplug: Keep enough storage space if SMP=n to avoid array out of bounds scribble objtool: Fix STACK_FRAME_NON_STANDARD macro checking for function symbols commit 790e5ef59fead625858919da20b3db0242db0d8d Merge: 22cb99f 4f0c40d9 Author: David S. Miller Date: Wed Jul 13 11:53:41 2016 -0700 Merge branch 'sk_filter-trim-limit' Willem de Bruijn says: ==================== limit sk_filter trim to payload Sockets can apply a filter to incoming packets to drop or trim them. Fix two codepaths that call skb_pull/__skb_pull after sk_filter without checking for packet length. Reading beyond skb->tail after trimming happens in more codepaths, but safety of reading in the linear segment is based on minimum allocation size (MAX_HEADER, GRO_MAX_HEAD, ..). ==================== Signed-off-by: David S. Miller commit 4f0c40d94461cfd23893a17335b2ab78ecb333c8 Author: Willem de Bruijn Date: Tue Jul 12 18:18:57 2016 -0400 dccp: limit sk_filter trim to payload Dccp verifies packet integrity, including length, at initial rcv in dccp_invalid_packet, later pulls headers in dccp_enqueue_skb. A call to sk_filter in-between can cause __skb_pull to wrap skb->len. skb_copy_datagram_msg interprets this as a negative value, so (correctly) fails with EFAULT. The negative length is reported in ioctl SIOCINQ or possibly in a DCCP_WARN in dccp_close. Introduce an sk_receive_skb variant that caps how small a filter program can trim packets, and call this in dccp with the header length. Excessively trimmed packets are now processed normally and queued for reception as 0B payloads. Fixes: 7c657876b63c ("[DCCP]: Initial implementation") Signed-off-by: Willem de Bruijn Acked-by: Daniel Borkmann Signed-off-by: David S. Miller include/net/sock.h | 8 +++++++- net/core/sock.c | 7 ++++--- net/dccp/ipv4.c | 2 +- net/dccp/ipv6.c | 2 +- 4 files changed, 13 insertions(+), 6 deletions(-) commit f4979fcea7fd36d8e2f556abef86f80e0d5af1ba Author: Willem de Bruijn Date: Tue Jul 12 18:18:56 2016 -0400 rose: limit sk_filter trim to payload Sockets can have a filter program attached that drops or trims incoming packets based on the filter program return value. Rose requires data packets to have at least ROSE_MIN_LEN bytes. It verifies this on arrival in rose_route_frame and unconditionally pulls the bytes in rose_recvmsg. The filter can trim packets to below this value in-between, causing pull to fail, leaving the partial header at the time of skb_copy_datagram_msg. Place a lower bound on the size to which sk_filter may trim packets by introducing sk_filter_trim_cap and call this for rose packets. Signed-off-by: Willem de Bruijn Acked-by: Daniel Borkmann Signed-off-by: David S. Miller include/linux/filter.h | 6 +++++- net/core/filter.c | 10 +++++----- net/rose/rose_in.c | 3 ++- 3 files changed, 12 insertions(+), 7 deletions(-) commit 22cb99fb76fb56b38f59770fbf22be03bb796d8d Merge: ea43f86 c3b7c5c Author: David S. Miller Date: Wed Jul 13 11:38:17 2016 -0700 Merge branch 'mlx5-fixes' Saeed Mahameed says: ==================== mlx5 tx timeout watchdog fixes This patch set provides two trivial fixes for the tx timeout series lately applied into net 4.7. From Daniel, detect stuck queues due to BQL From Mohamad, fix tx timeout watchdog false alarm Hopefully those two fixes will make it to -stable, assuming 3947ca185999 ('net/mlx5e: Implement ndo_tx_timeout callback') was also backported to -stable. ==================== Signed-off-by: David S. Miller commit c3b7c5c9504348e0c22fa47629c419d82c963bc2 Author: Mohamad Haj Yahia Date: Wed Jul 13 00:07:00 2016 +0300 net/mlx5e: start/stop all tx queues upon open/close netdev Start all tx queues (including inactive ones) when opening the netdev. Stop all tx queues (including inactive ones) when closing the netdev. This is a workaround for the tx timeout watchdog false alarm issue in which the netdev watchdog is polling all the tx queues which may include inactive queues and thus once lowering the real tx queues number (ethtool -L) it will generate tx timeout watchdog false alarms. Fixes: 3947ca185999 ('net/mlx5e: Implement ndo_tx_timeout callback') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 2c1ccc993707ecb0830ef0aebb7c8061f7704aa3 Author: Daniel Jurgens Date: Wed Jul 13 00:06:59 2016 +0300 net/mlx5e: Fix TX Timeout to detect queues stuck on BQL Change netif_tx_queue_stopped to netif_xmit_stopped. This will show when queues are stopped due to byte queue limits. Fixes: 3947ca185999 ('net/mlx5e: Implement ndo_tx_timeout callback') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d60585c5766e9620d5d83e2b25dc042c7bdada2c Author: Thomas Gleixner Date: Tue Jul 12 18:33:56 2016 +0200 sched/core: Correct off by one bug in load migration calculation The move of calc_load_migrate() from CPU_DEAD to CPU_DYING did not take into account that the function is now called from a thread running on the outgoing CPU. As a result a cpu unplug leakes a load of 1 into the global load accounting mechanism. Fix it by adjusting for the currently running thread which calls calc_load_migrate(). Reported-by: Anton Blanchard Signed-off-by: Thomas Gleixner Acked-by: Peter Zijlstra Cc: Linus Torvalds Cc: Michael Ellerman Cc: Vaidyanathan Srinivasan Cc: rt@linutronix.de Cc: shreyas@linux.vnet.ibm.com Fixes: e9cd8fa4fcfd: ("sched/migration: Move calc_load_migrate() into CPU_DYING") Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1607121744350.4083@nanos Signed-off-by: Ingo Molnar kernel/sched/core.c | 6 ++++-- kernel/sched/loadavg.c | 8 ++++---- kernel/sched/sched.h | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) commit cf875cc1dc6cb43cec754e92092579a51d2ad095 Merge: f1b5e4f 6519c3d Author: Linus Torvalds Date: Wed Jul 13 19:51:49 2016 +0900 Merge tag 'media/v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media Pull media fixes from Mauro Carvalho Chehab: "Two regression fixes: - a regression when handling VIDIOC_CROPCAP at the media core; - a regression at adv7604 that was ignoring pad number in subdev ops" * tag 'media/v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: [media] adv7604: Don't ignore pad number in subdev DV timings pad operations [media] v4l2-ioctl: fix stupid mistake in cropcap condition commit a7c734140aa36413944eef0f8c660e0e2256357d Author: Thomas Gleixner Date: Tue Jul 12 21:59:23 2016 +0200 cpu/hotplug: Keep enough storage space if SMP=n to avoid array out of bounds scribble Xiaolong Ye reported lock debug warnings triggered by the following commit: 8de4a0066106 ("perf/x86: Convert the core to the hotplug state machine") The bug is the following: the cpuhp_bp_states[] array is cut short when CONFIG_SMP=n, but the dynamically registered callbacks are stored nevertheless and happily scribble outside of the array bounds... We need to store them in case that the state is unregistered so we can invoke the teardown function. That's independent of CONFIG_SMP. Make sure the array is large enough. Reported-by: kernel test robot Signed-off-by: Thomas Gleixner Cc: Adam Borowski Cc: Alexander Shishkin Cc: Anna-Maria Gleixner Cc: Arnaldo Carvalho de Melo Cc: Arnaldo Carvalho de Melo Cc: Borislav Petkov Cc: Jiri Olsa Cc: Kan Liang Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Sebastian Andrzej Siewior Cc: Stephane Eranian Cc: Vince Weaver Cc: lkp@01.org Cc: stable@vger.kernel.org Cc: tipbuild@zytor.com Fixes: cff7d378d3fd "cpu/hotplug: Convert to a state machine for the control processor" Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1607122144560.4083@nanos Signed-off-by: Ingo Molnar kernel/cpu.c | 2 ++ 1 file changed, 2 insertions(+) commit ea43f860d984b00c3e3fa02049412ce94ce9ed5e Merge: 136ab0d ee6c21b Author: David S. Miller Date: Tue Jul 12 23:13:01 2016 -0700 Merge branch 'ethoc-fixes' Florian Fainelli says: ==================== net: ethoc: Error path and transmit fixes This patch series contains two patches for the ethoc driver while testing on a TS-7300 board where ethoc is provided by an on-board FPGA. First patch was cooked after chasing crashes with invalid resources passed to the driver. Second patch was cooked after seeing that an interface configured with IP 192.168.2.2 was sending ARP packets for 192.168.0.0, no wonder why it could not work. I don't have access to any other platform using an ethoc interface so it could be good to some testing on Xtensa for instance. Changes in v3: - corrected the error path if skb_put_padto() fails, thanks to Max for spotting this! Changes in v2: - fixed the first commit message ==================== Signed-off-by: David S. Miller commit ee6c21b9c11ad96318160f9a504a3fac2114ddca Author: Florian Fainelli Date: Tue Jul 12 16:04:36 2016 -0700 net: ethoc: Correctly pad short packets Even though the hardware can be doing zero padding, we want the SKB to be going out on the wire with the appropriate size. This fixes packet truncations observed with e.g: ARP packets. Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/ethoc.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 386512d18b268c6182903239f9f3390f03ce4c7b Author: Florian Fainelli Date: Tue Jul 12 16:04:35 2016 -0700 net: ethoc: Fix early error paths In case any operation fails before we can successfully go the point where we would register a MDIO bus, we would be going to an error label which involves unregistering then freeing this yet to be created MDIO bus. Update all error paths to go to label free which is the only one valid until either the clock is enabled, or the MDIO bus is allocated and registered. This fixes kernel oops observed while trying to dereference the MDIO bus structure which is not yet allocated. Fixes: a1702857724f ("net: Add support for the OpenCores 10/100 Mbps Ethernet MAC.") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/ethoc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit f1b5e4fac164ff43b189d996e4f05f95cc57b984 Merge: 63bab22 d0420d2 Author: Linus Torvalds Date: Wed Jul 13 06:37:03 2016 +0900 Merge tag 'acpi-urgent-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fixes from Rafael Wysocki: "One ACPI EC driver regression fix (code ordering) and three reverts of ACPICA commits, one that introduced a problem and two unsuccessful attempted fixes on top of it. Specifics: - Fix a recent regression in the ACPI EC driver introduced by a fix of another problem that uncovered a latent code ordering issue in the driver (Lv Zheng). - Revert a recent ACPICA commit that attempted to address a lock ordering issue introduced by a previous fix, but caused Dell Precision 5510 to fail to boot, revert that previous fix too and finally revert the commit that caused the original problem (a deadlock in the ACPICA code) to happen (Rafael Wysocki)" * tag 'acpi-urgent-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: Revert "ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis" Revert "ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading" Revert "ACPICA: Namespace: Fix namespace/interpreter lock ordering" ACPI / EC: Fix code ordering issue in ec_remove_handlers() commit 136ab0d0e10f29bdac3ee04bd0e9661073e15c80 Author: Noam Camus Date: Tue Jul 12 16:01:11 2016 +0300 net: nps_enet: Fix PCS reset During commit b54b8c2d6e3c ("net: ezchip: adapt driver to little endian architecture") adapting to little endian architecture, zeroing of controller was left out. Signed-off-by: Elad Kanfi Signed-off-by: David S. Miller drivers/net/ethernet/ezchip/nps_enet.c | 1 + 1 file changed, 1 insertion(+) commit d0420d20bacd1eef9f75a769ad48befd383ad190 Merge: 00c611d fa5b4a5 Author: Rafael J. Wysocki Date: Tue Jul 12 22:03:14 2016 +0200 Merge branches 'acpica-fixes' and 'acpi-ec-fixes' * acpica-fixes: Revert "ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis" Revert "ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading" Revert "ACPICA: Namespace: Fix namespace/interpreter lock ordering" * acpi-ec-fixes: ACPI / EC: Fix code ordering issue in ec_remove_handlers() commit 63bab2203d54529ff1a7181b0575b58a9f3575cd Merge: 08d27eb 43160ff Author: Linus Torvalds Date: Wed Jul 13 04:22:16 2016 +0900 Merge tag 'qcom-smd-list-voltage' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fix from Mark Brown: "Fix qcom-smd list voltage issues for msm8974 This commit looks like a cleanup but in fact by causing the core to go down some simplified code paths for noop regulators it avoids a boot time crash for msm8974 platforms which was introduced in v4.7. It has been in -next for a while, the issues in mainline for these platforms weren't flagged up to me until yesterday (I think it took some time to figure out what was going wrong)" * tag 'qcom-smd-list-voltage' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: qcom_smd: Remove list_voltage callback for rpm_smps_ldo_ops_fixed commit 92a03eb01277d710a97bcc07602aea083ba3fffd Merge: ce9a4f3 590b52e Author: David S. Miller Date: Tue Jul 12 10:21:27 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf Pablo Neira Ayuso says: ==================== Netfilter/IPVS fixes for net The following patchset contains Netfilter/IPVS fixes for your net tree. they are: 1) Fix leak in the error path of nft_expr_init(), from Liping Zhang. 2) Tracing from nf_tables cannot be disabled, also from Zhang. 3) Fix an integer overflow on 32bit archs when setting the number of hashtable buckets, from Florian Westphal. 4) Fix configuration of ipvs sync in backup mode with IPv6 address, from Quentin Armitage via Simon Horman. 5) Fix incorrect timeout calculation in nft_ct NFT_CT_EXPIRATION, from Florian Westphal. 6) Skip clash resolution in conntrack insertion races if NAT is in place. ==================== Signed-off-by: David S. Miller commit 8e0e7aedadb877d91a6e66611464165c969bc0a9 Author: Shiraz Saleem Date: Mon Jun 27 16:52:14 2016 -0500 i40iw: Enable remote access rights for stag allocation Fix to enable remote access rights when allocating stag. Fixes: b7aee855d3b9 ("RDMA/i40iw: Add base memory management extensions") Signed-off-by: Shiraz Saleem Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw_verbs.c | 1 + 1 file changed, 1 insertion(+) commit b0548cff99ba927730d4f0c306b98cb6b6aa7cf7 Author: Nicolas Iooss Date: Sat Jun 25 17:55:07 2016 +0200 i40iw: do not print unitialized variables in error message i40iw_create_cqp() printed the contents of variables maj_err and min_err in an error message before they could be initialized (by calling dev->cqp_ops->cqp_create). Signed-off-by: Nicolas Iooss Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw_main.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit c5a81d11d756bfa2b7215463b5908006871bd4fa Author: Christoph Lameter Date: Fri Jul 8 10:27:42 2016 -0500 IB core: Add port_xmit_wait counter Add the missing port_xmit_wait counter. This counter is displayed through some tools like perfquery but is not available via sysfs. For the PORT_PMA_ATTR macro the _counter field is set to zero allowing us to specify the offset directly like with PORT_PMA_ATTR_EXT See also the earlier work in 2008 by Vladimir Skolovsky https://www.mail-archive.com/general@lists.openfabrics.org/msg20313.html Signed-off-by: Vladimir Sokolvsky Signed-off-by: Christoph Lameter Signed-off-by: Doug Ledford drivers/infiniband/core/sysfs.c | 4 ++++ 1 file changed, 4 insertions(+) commit 98f179a5eaf77eaac49df3d0c217c6eaaba8c0db Author: Tadeusz Struk Date: Wed Jul 6 17:14:47 2016 -0400 IB/hfi1: Fix sleep inside atomic issue in init_asic_data The critical section should protect only the list traversal and dd->asic_data modification, not the memory allocation. The fix pulls the allocation out of the critical section. Reviewed-by: Dennis Dalessandro Reviewed-by: Sebastian Sanchez Reviewed-by: Dean Luick Signed-off-by: Tadeusz Struk Signed-off-by: Dennis Dalessandro Signed-off-by: Mike Marciniszyn Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/chip.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 896ce45da2c2f4abc508d443fdecde7de0b3fa7e Author: Mike Marciniszyn Date: Fri Jul 1 15:57:02 2016 -0700 IB/hfi1: Correct issues with sc5 computation There are several computatations of the sc in the ud receive routine. Besides the code duplication, all are wrong when the sc is greater than 15. In that case the code incorrectly or's a 1 into the computed sc instead of 1 shifted left by 4. Fix precomputed sc5 by using an already implemented routine hdr2sc() and deleting flawed duplicated code. Cc: Stable # 4.6+ Reviewed-by: Dennis Dalessandro Signed-off-by: Mike Marciniszyn Signed-off-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/ud.c | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) commit 590b52e10d410e1439ae86be9fe19d75fdab628b Author: Pablo Neira Ayuso Date: Mon Jul 11 17:28:54 2016 +0200 netfilter: conntrack: skip clash resolution if nat is in place The clash resolution is not easy to apply if the NAT table is registered. Even if no NAT rules are installed, the nul-binding ensures that a unique tuple is used, thus, the packet that loses race gets a different source port number, as described by: http://marc.info/?l=netfilter-devel&m=146818011604484&w=2 Clash resolution with NAT is also problematic if addresses/port range ports are used since the conntrack that wins race may describe a different mangling that we may have earlier applied to the packet via nf_nat_setup_info(). Fixes: 71d8c47fc653 ("netfilter: conntrack: introduce clash resolution on insertion race") Signed-off-by: Pablo Neira Ayuso Tested-by: Marc Dionne net/netfilter/nf_conntrack_core.c | 1 + 1 file changed, 1 insertion(+) commit d716fb03f76411fc7e138692e33b749cada5c094 Author: Awais Belal Date: Tue Jul 12 15:21:28 2016 +0500 ALSA: hda: add AMD Stoney PCI ID with proper driver caps This allows the device to correctly show up as ATI HDMI rather than a generic one and allows the driver to use the available caps. Signed-off-by: Awais Belal Cc: Signed-off-by: Takashi Iwai sound/pci/hda/hda_intel.c | 2 ++ 1 file changed, 2 insertions(+) commit 08d27eb2066622cd659b91d877d0406ebd651225 Merge: 92d21ac 6d4e56c Author: Linus Torvalds Date: Tue Jul 12 16:49:01 2016 +0900 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs fixes from Al Viro. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: posix_acl: de-union a_refcount and a_rcu nfs_atomic_open(): prevent parallel nfs_lookup() on a negative hashed Use the right predicate in ->atomic_open() instances commit ce9a4f316d1240158063c54ddea1628926cb4553 Merge: 34ee32c 1fc07f3 Author: David S. Miller Date: Mon Jul 11 22:42:13 2016 -0700 Merge branch 'tipc-fixes' Jon Maloy says: ==================== tipc: three small fixes Fixes for some broadcast link problems that may occur in large systems. ==================== Signed-off-by: David S. Miller commit 1fc07f3e1541cc49cc159beb3fdefc5013570eda Author: Jon Paul Maloy Date: Mon Jul 11 16:08:37 2016 -0400 tipc: reset all unicast links when broadcast send link fails In test situations with many nodes and a heavily stressed system we have observed that the transmission broadcast link may fail due to an excessive number of retransmissions of the same packet. In such situations we need to reset all unicast links to all peers, in order to reset and re-synchronize the broadcast link. In this commit, we add a new function tipc_bearer_reset_all() to be used in such situations. The function scans across all bearers and resets all their pertaining links. Acked-by: Ying Xue Signed-off-by: Jon Maloy Signed-off-by: David S. Miller net/tipc/bearer.c | 15 +++++++++++++++ net/tipc/bearer.h | 1 + net/tipc/node.c | 15 +++++++++++---- 3 files changed, 27 insertions(+), 4 deletions(-) commit a71eb720355c28eaeb2de0c4d960247c69bb2c6f Author: Jon Paul Maloy Date: Mon Jul 11 16:08:36 2016 -0400 tipc: ensure correct broadcast send buffer release when peer is lost After a new receiver peer has been added to the broadcast transmission link, we allow immediate transmission of new broadcast packets, trusting that the new peer will not accept the packets until it has received the previously sent unicast broadcast initialiation message. In the same way, the sender must not accept any acknowledges until it has itself received the broadcast initialization from the peer, as well as confirmation of the reception of its own initialization message. Furthermore, when a receiver peer goes down, the sender has to produce the missing acknowledges from the lost peer locally, in order ensure correct release of the buffers that were expected to be acknowledged by the said peer. In a highly stressed system we have observed that contact with a peer may come up and be lost before the above mentioned broadcast initial- ization and confirmation have been received. This leads to the locally produced acknowledges being rejected, and the non-acknowledged buffers to linger in the broadcast link transmission queue until it fills up and the link goes into permanent congestion. In this commit, we remedy this by temporarily setting the corresponding broadcast receive link state to ESTABLISHED and the 'bc_peer_is_up' state to true before we issue the local acknowledges. This ensures that those acknowledges will always be accepted. The mentioned state values are restored immediately afterwards when the link is reset. Acked-by: Ying Xue Signed-off-by: Jon Maloy Signed-off-by: David S. Miller net/tipc/link.c | 2 ++ 1 file changed, 2 insertions(+) commit 2d18ac4ba7454a4260473e68be7e485ae71e7948 Author: Jon Paul Maloy Date: Mon Jul 11 16:08:35 2016 -0400 tipc: extend broadcast link initialization criteria At first contact between two nodes, an endpoint might sometimes have time to send out a LINK_PROTOCOL/STATE packet before it has received the broadcast initialization packet from the peer, i.e., before it has received a valid broadcast packet number to add to the 'bc_ack' field of the protocol message. This means that the peer endpoint will receive a protocol packet with an invalid broadcast acknowledge value of 0. Under unlucky circumstances this may lead to the original, already received acknowledge value being overwritten, so that the whole broadcast link goes stale after a while. We fix this by delaying the setting of the link field 'bc_peer_is_up' until we know that the peer really has received our own broadcast initialization message. The latter is always sent out as the first unicast message on a link, and always with seqeunce number 1. Because of this, we only need to look for a non-zero unicast acknowledge value in the arriving STATE messages, and once that is confirmed we know we are safe and can set the mentioned field. Before this moment, we must ignore all broadcast acknowledges from the peer. Acked-by: Ying Xue Signed-off-by: Jon Maloy Signed-off-by: David S. Miller net/tipc/link.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 34ee32c9a5696247be405bb0c21f3d1fc6cb5729 Author: Mario Limonciello Date: Mon Jul 11 19:58:04 2016 -0500 r8152: Add support for setting pass through MAC address on RTL8153-AD The RTL8153-AD supports a persistent system specific MAC address. This means a device plugged into two different systems with host side support will show different (but persistent) MAC addresses. This information for the system's persistent MAC address is burned in when the system HW is built and available under \_SB.AMAC in the DSDT at runtime. This technology is currently implemented in the Dell TB15 and WD15 Type-C docks. More information is available here: http://www.dell.com/support/article/us/en/04/SLN301147 Signed-off-by: Mario Limonciello Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 76 +++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 74 insertions(+), 2 deletions(-) commit 779f1edec664a7b32b71f7b4702e085a08d60592 Author: Soheil Hassas Yeganeh Date: Mon Jul 11 16:51:26 2016 -0400 sock: ignore SCM_RIGHTS and SCM_CREDENTIALS in __sock_cmsg_send Sergei Trofimovich reported that pulse audio sends SCM_CREDENTIALS as a control message to TCP. Since __sock_cmsg_send does not support SCM_RIGHTS and SCM_CREDENTIALS, it returns an error and hence breaks pulse audio over TCP. SCM_RIGHTS and SCM_CREDENTIALS are sent on the SOL_SOCKET layer but they semantically belong to SOL_UNIX. Since all cmsg-processing functions including sock_cmsg_send ignore control messages of other layers, it is best to ignore SCM_RIGHTS and SCM_CREDENTIALS for consistency (and also for fixing pulse audio over TCP). Fixes: c14ac9451c34 ("sock: enable timestamping using control messages") Signed-off-by: Soheil Hassas Yeganeh Reported-by: Sergei Trofimovich Tested-by: Sergei Trofimovich Cc: Eric Dumazet Cc: Willem de Bruijn Signed-off-by: David S. Miller net/core/sock.c | 4 ++++ 1 file changed, 4 insertions(+) commit 80610229ef7b26615dbb6cb6e873709a60bacc9f Author: Julian Anastasov Date: Sun Jul 10 21:11:55 2016 +0300 ipv4: reject RTNH_F_DEAD and RTNH_F_LINKDOWN from user space Vegard Nossum is reporting for a crash in fib_dump_info when nh_dev = NULL and fib_nhs == 1: Pid: 50, comm: netlink.exe Not tainted 4.7.0-rc5+ RIP: 0033:[<00000000602b3d18>] RSP: 0000000062623890 EFLAGS: 00010202 RAX: 0000000000000000 RBX: 000000006261b800 RCX: 0000000000000000 RDX: 0000000000000000 RSI: 0000000000000024 RDI: 000000006245ba00 RBP: 00000000626238f0 R08: 000000000000029c R09: 0000000000000000 R10: 0000000062468038 R11: 000000006245ba00 R12: 000000006245ba00 R13: 00000000625f96c0 R14: 00000000601e16f0 R15: 0000000000000000 Kernel panic - not syncing: Kernel mode fault at addr 0x2e0, ip 0x602b3d18 CPU: 0 PID: 50 Comm: netlink.exe Not tainted 4.7.0-rc5+ #581 Stack: 626238f0 960226a02 00000400 000000fe 62623910 600afca7 62623970 62623a48 62468038 00000018 00000000 00000000 Call Trace: [<602b3e93>] rtmsg_fib+0xd3/0x190 [<602b6680>] fib_table_insert+0x260/0x500 [<602b0e5d>] inet_rtm_newroute+0x4d/0x60 [<60250def>] rtnetlink_rcv_msg+0x8f/0x270 [<60267079>] netlink_rcv_skb+0xc9/0xe0 [<60250d4b>] rtnetlink_rcv+0x3b/0x50 [<60265400>] netlink_unicast+0x1a0/0x2c0 [<60265e47>] netlink_sendmsg+0x3f7/0x470 [<6021dc9a>] sock_sendmsg+0x3a/0x90 [<6021e0d0>] ___sys_sendmsg+0x300/0x360 [<6021fa64>] __sys_sendmsg+0x54/0xa0 [<6021fac0>] SyS_sendmsg+0x10/0x20 [<6001ea68>] handle_syscall+0x88/0x90 [<600295fd>] userspace+0x3fd/0x500 [<6001ac55>] fork_handler+0x85/0x90 $ addr2line -e vmlinux -i 0x602b3d18 include/linux/inetdevice.h:222 net/ipv4/fib_semantics.c:1264 Problem happens when RTNH_F_LINKDOWN is provided from user space when creating routes that do not use the flag, catched with netlink fuzzer. Currently, the kernel allows user space to set both flags to nh_flags and fib_flags but this is not intentional, the assumption was that they are not set. Fix this by rejecting both flags with EINVAL. Reported-by: Vegard Nossum Fixes: 0eeb075fad73 ("net: ipv4 sysctl option to ignore routes when nexthop link is down") Signed-off-by: Julian Anastasov Cc: Andy Gospodarek Cc: Dinesh Dutt Cc: Scott Feldman Reviewed-by: Andy Gospodarek Signed-off-by: David S. Miller net/ipv4/fib_semantics.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 75ff39ccc1bd5d3c455b6822ab09e533c551f758 Author: Eric Dumazet Date: Sun Jul 10 10:04:02 2016 +0200 tcp: make challenge acks less predictable Yue Cao claims that current host rate limiting of challenge ACKS (RFC 5961) could leak enough information to allow a patient attacker to hijack TCP sessions. He will soon provide details in an academic paper. This patch increases the default limit from 100 to 1000, and adds some randomization so that the attacker can no longer hijack sessions without spending a considerable amount of probes. Based on initial analysis and patch from Linus. Note that we also have per socket rate limiting, so it is tempting to remove the host limit in the future. v2: randomize the count of challenge acks per second, not the period. Fixes: 282f23c6ee34 ("tcp: implement RFC 5961 3.2") Reported-by: Yue Cao Signed-off-by: Eric Dumazet Suggested-by: Linus Torvalds Cc: Yuchung Cheng Cc: Neal Cardwell Acked-by: Neal Cardwell Acked-by: Yuchung Cheng Signed-off-by: David S. Miller net/ipv4/tcp_input.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit a612769774a30e4fc143c4cb6395c12573415660 Author: Michal Kubeček Date: Fri Jul 8 17:52:33 2016 +0200 udp: prevent bugcheck if filter truncates packet too much If socket filter truncates an udp packet below the length of UDP header in udpv6_queue_rcv_skb() or udp_queue_rcv_skb(), it will trigger a BUG_ON in skb_pull_rcsum(). This BUG_ON (and therefore a system crash if kernel is configured that way) can be easily enforced by an unprivileged user which was reported as CVE-2016-6162. For a reproducer, see http://seclists.org/oss-sec/2016/q3/8 Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Reported-by: Marco Grassi Signed-off-by: Michal Kubecek Acked-by: Eric Dumazet Acked-by: Willem de Bruijn Signed-off-by: David S. Miller net/ipv4/udp.c | 2 ++ net/ipv6/udp.c | 2 ++ 2 files changed, 4 insertions(+) commit f3ea3119ad75dde0ba3e8da4653dbd5a189688e5 Author: Colin Ian King Date: Fri Jul 8 16:42:48 2016 +0100 bnxt_en: initialize rc to zero to avoid returning garbage rc is not initialized so it can contain garbage if it is not set by the call to bnxt_read_sfp_module_eeprom_info. Ensure garbage is not returned by initializing rc to 0. Signed-off-by: Colin Ian King Acked-by: Michael Chan Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d32eb8781a0eccf8ab7bf33877014c7637ad271 Merge: 95556a8 d1fe176 Author: David S. Miller Date: Mon Jul 11 12:28:44 2016 -0700 Merge tag 'batadv-net-for-davem-20160708' of git://git.open-mesh.org/linux-merge Simon Wunderlich says: ==================== Here are a couple batman-adv bugfix patches, all by Sven Eckelmann: - Fix possible NULL pointer dereference for vlan_insert_tag (two patches) - Fix reference handling in some features, which may lead to reference leaks or invalid memory access (four patches) - Fix speedy join: DHCP packets handled by the gateway feature should be sent with 4-address unicast instead of 3-address unicast to make speedy join work. This fixes/speeds up DHCP assignment for clients which join a mesh for the first time. (one patch) ==================== Signed-off-by: David S. Miller commit ab58d8cc870ef3f0771c197700441936898d1f1d Author: Peter Wu Date: Mon Jul 11 19:51:06 2016 +0200 ALSA: hda - fix use-after-free after module unload register_vga_switcheroo() sets the PM ops from the hda structure which is freed later in azx_free. Make sure that these ops are cleared. Caught by KASAN, initially noticed due to a general protection fault. Fixes: 246efa4a072f ("snd/hda: add runtime suspend/resume on optimus support (v4)") Signed-off-by: Peter Wu Cc: Signed-off-by: Takashi Iwai sound/pci/hda/hda_intel.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6d4e56ce977864b0fcd28c61555060e6010aa89b Author: Jeff Layton Date: Mon Jul 11 09:10:06 2016 -0400 posix_acl: de-union a_refcount and a_rcu Currently the two are unioned together, but I don't think that's safe. It looks like get_cached_acl could race with the last put in posix_acl_release. get_cached_acl calls atomic_inc_not_zero on a_refcount, but that field could have already been clobbered by call_rcu, and may no longer be zero. Fix this by de-unioning the two fields. Fixes: b8a7a3a66747 (posix_acl: Inode acl caching fixes) Signed-off-by: Jeff Layton Signed-off-by: Al Viro include/linux/posix_acl.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 2c13ce8f6b2f6fd9ba2f9261b1939fc0f62d1307 Author: Alexey Dobriyan Date: Fri Jul 8 01:39:11 2016 +0300 posix_cpu_timer: Exit early when process has been reaped Variable "now" seems to be genuinely used unintialized if branch if (CPUCLOCK_PERTHREAD(timer->it_clock)) { is not taken and branch if (unlikely(sighand == NULL)) { is taken. In this case the process has been reaped and the timer is marked as disarmed anyway. So none of the postprocessing of the sample is required. Return right away. Signed-off-by: Alexey Dobriyan Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/20160707223911.GA26483@p183.telecom.by Signed-off-by: Thomas Gleixner kernel/time/posix-cpu-timers.c | 1 + 1 file changed, 1 insertion(+) commit 00c611def8748a0a1cf1d31842e49b42dfdb3de1 Author: Rafael J. Wysocki Date: Mon Jul 11 16:21:08 2016 +0200 Revert "ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis" Revert commit 3d4b7ae96d81 (ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis) that enabled the execution of module-level AML after loading each table (rather than after all AML tables have been loaded), but overlooked locking issues resulting from that change. Fixes: 3d4b7ae96d81 (ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis) Reported-by: Mika Westerberg Signed-off-by: Rafael J. Wysocki include/acpi/acpixf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ffd8d61845c90cea87bc3efa58ddff1b14dea8f2 Author: Rafael J. Wysocki Date: Mon Jul 11 16:18:18 2016 +0200 Revert "ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading" Revert commit 2f38b1b16d92 (ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading) that attempted to fix a deadlock issue introduced by a previous commit, but it led to a lock ordering inconsistency that caused further problems to appear. Fixes: 2f38b1b16d92 (ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading) Signed-off-by: Rafael J. Wysocki drivers/acpi/acpica/exconfig.c | 2 -- drivers/acpi/acpica/nsparse.c | 9 ++------- 2 files changed, 2 insertions(+), 9 deletions(-) commit e8807e4470e6b4230b24c537d7179a945f0f7c40 Author: Rafael J. Wysocki Date: Sun Jul 10 23:34:01 2016 +0200 Revert "ACPICA: Namespace: Fix namespace/interpreter lock ordering" Revert commit 45209046c47b (ACPICA: Namespace: Fix namespace/interpreter lock ordering) that renders Dell Precision 5510 with the latest (1.2.10) BIOS applied unable to boot. Fixes: 45209046c47b (ACPICA: Namespace: Fix namespace/interpreter lock ordering) Link: https://bugzilla.kernel.org/show_bug.cgi?id=121701 Reported-by: Greg White Signed-off-by: Rafael J. Wysocki drivers/acpi/acpica/nsload.c | 7 +------ drivers/acpi/acpica/nsparse.c | 9 +++++++-- 2 files changed, 8 insertions(+), 8 deletions(-) commit 4edfa9d0bf9ee9c34ee58b80ea1f146677497de9 Merge: c8607e0 3777ed6 Author: Pablo Neira Ayuso Date: Mon Jul 11 11:55:16 2016 +0200 Merge tag 'ipvs-fixes2-for-v4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs Simon Horman says: ==================== Second Round of IPVS Fixes for v4.7 The fix from Quentin Armitage allows the backup sync daemon to be bound to a link-local mcast IPv6 address as is already the case for IPv4. ==================== Signed-off-by: Pablo Neira Ayuso commit 92d21ac74a9e3c09b0b01c764e530657e4c85c49 Author: Linus Torvalds Date: Sun Jul 10 20:24:59 2016 -0700 Linux 4.7-rc7 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7f556567036cb7f89aabe2f0954b08566b4efb53 Author: Hugh Dickins Date: Sun Jul 10 16:46:32 2016 -0700 tmpfs: fix regression hang in fallocate undo The well-spotted fallocate undo fix is good in most cases, but not when fallocate failed on the very first page. index 0 then passes lend -1 to shmem_undo_range(), and that has two bad effects: (a) that it will undo every fallocation throughout the file, unrestricted by the current range; but more importantly (b) it can cause the undo to hang, because lend -1 is treated as truncation, which makes it keep on retrying until every page has gone, but those already fully instantiated will never go away. Big thank you to xfstests generic/269 which demonstrates this. Fixes: b9b4bb26af01 ("tmpfs: don't undo fallocate past its last page") Cc: stable@vger.kernel.org Signed-off-by: Hugh Dickins Signed-off-by: Linus Torvalds mm/shmem.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit abb2bafd295fe962bbadc329dbfb2146457283ac Author: Lukas Wunner Date: Sun Jun 12 12:31:53 2016 +0200 x86/quirks: Add early quirk to reset Apple AirPort card The EFI firmware on Macs contains a full-fledged network stack for downloading OS X images from osrecovery.apple.com. Unfortunately on Macs introduced 2011 and 2012, EFI brings up the Broadcom 4331 wireless card on every boot and leaves it enabled even after ExitBootServices has been called. The card continues to assert its IRQ line, causing spurious interrupts if the IRQ is shared. It also corrupts memory by DMAing received packets, allowing for remote code execution over the air. This only stops when a driver is loaded for the wireless card, which may be never if the driver is not installed or blacklisted. The issue seems to be constrained to the Broadcom 4331. Chris Milsted has verified that the newer Broadcom 4360 built into the MacBookPro11,3 (2013/2014) does not exhibit this behaviour. The chances that Apple will ever supply a firmware fix for the older machines appear to be zero. The solution is to reset the card on boot by writing to a reset bit in its mmio space. This must be done as an early quirk and not as a plain vanilla PCI quirk to successfully combat memory corruption by DMAed packets: Matthew Garrett found out in 2012 that the packets are written to EfiBootServicesData memory (http://mjg59.dreamwidth.org/11235.html). This type of memory is made available to the page allocator by efi_free_boot_services(). Plain vanilla PCI quirks run much later, in subsys initcall level. In-between a time window would be open for memory corruption. Random crashes occurring in this time window and attributed to DMAed packets have indeed been observed in the wild by Chris Bainbridge. When Matthew Garrett analyzed the memory corruption issue in 2012, he sought to fix it with a grub quirk which transitions the card to D3hot: http://git.savannah.gnu.org/cgit/grub.git/commit/?id=9d34bb85da56 This approach does not help users with other bootloaders and while it may prevent DMAed packets, it does not cure the spurious interrupts emanating from the card. Unfortunately the card's mmio space is inaccessible in D3hot, so to reset it, we have to undo the effect of Matthew's grub patch and transition the card back to D0. Note that the quirk takes a few shortcuts to reduce the amount of code: The size of BAR 0 and the location of the PM capability is identical on all affected machines and therefore hardcoded. Only the address of BAR 0 differs between models. Also, it is assumed that the BCMA core currently mapped is the 802.11 core. The EFI driver seems to always take care of this. Michael Büsch, Bjorn Helgaas and Matt Fleming contributed feedback towards finding the best solution to this problem. The following should be a comprehensive list of affected models: iMac13,1 2012 21.5" [Root Port 00:1c.3 = 8086:1e16] iMac13,2 2012 27" [Root Port 00:1c.3 = 8086:1e16] Macmini5,1 2011 i5 2.3 GHz [Root Port 00:1c.1 = 8086:1c12] Macmini5,2 2011 i5 2.5 GHz [Root Port 00:1c.1 = 8086:1c12] Macmini5,3 2011 i7 2.0 GHz [Root Port 00:1c.1 = 8086:1c12] Macmini6,1 2012 i5 2.5 GHz [Root Port 00:1c.1 = 8086:1e12] Macmini6,2 2012 i7 2.3 GHz [Root Port 00:1c.1 = 8086:1e12] MacBookPro8,1 2011 13" [Root Port 00:1c.1 = 8086:1c12] MacBookPro8,2 2011 15" [Root Port 00:1c.1 = 8086:1c12] MacBookPro8,3 2011 17" [Root Port 00:1c.1 = 8086:1c12] MacBookPro9,1 2012 15" [Root Port 00:1c.1 = 8086:1e12] MacBookPro9,2 2012 13" [Root Port 00:1c.1 = 8086:1e12] MacBookPro10,1 2012 15" [Root Port 00:1c.1 = 8086:1e12] MacBookPro10,2 2012 13" [Root Port 00:1c.1 = 8086:1e12] For posterity, spurious interrupts caused by the Broadcom 4331 wireless card resulted in splats like this (stacktrace omitted): irq 17: nobody cared (try booting with the "irqpoll" option) handlers: [] pcie_isr [] sdhci_irq [sdhci] threaded [] sdhci_thread_irq [sdhci] [] azx_interrupt [snd_hda_codec] Disabling IRQ #17 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=79301 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=111781 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=728916 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=895951#c16 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1009819 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1098621 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1149632#c5 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1279130 Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1332732 Tested-by: Konstantin Simanov # [MacBookPro8,1] Tested-by: Lukas Wunner # [MacBookPro9,1] Tested-by: Bryan Paradis # [MacBookPro9,2] Tested-by: Andrew Worsley # [MacBookPro10,1] Tested-by: Chris Bainbridge # [MacBookPro10,2] Signed-off-by: Lukas Wunner Acked-by: Rafał Miłecki Acked-by: Matt Fleming Cc: Andy Lutomirski Cc: Bjorn Helgaas Cc: Borislav Petkov Cc: Brian Gerst Cc: Chris Milsted Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Josh Poimboeuf Cc: Linus Torvalds Cc: Matthew Garrett Cc: Michael Buesch Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Yinghai Lu Cc: b43-dev@lists.infradead.org Cc: linux-pci@vger.kernel.org Cc: linux-wireless@vger.kernel.org Cc: stable@vger.kernel.org Cc: stable@vger.kernel.org # 123456789abc: x86/quirks: Apply nvidia_bugs quirk only on root bus Cc: stable@vger.kernel.org # 123456789abc: x86/quirks: Reintroduce scanning of secondary buses Link: http://lkml.kernel.org/r/48d0972ac82a53d460e5fce77a07b2560db95203.1465690253.git.lukas@wunner.de [ Did minor readability edits. ] Signed-off-by: Ingo Molnar arch/x86/kernel/early-quirks.c | 64 ++++++++++++++++++++++++++++++++++++++++++ drivers/bcma/bcma_private.h | 2 -- include/linux/bcma/bcma.h | 1 + 3 files changed, 65 insertions(+), 2 deletions(-) commit 850c321027c2e31d0afc71588974719a4b565550 Author: Lukas Wunner Date: Sun Jun 12 12:31:53 2016 +0200 x86/quirks: Reintroduce scanning of secondary buses We used to scan secondary buses until the following commit that was applied in 2009: 8659c406ade3 ("x86: only scan the root bus in early PCI quirks") which commit constrained early quirks to the root bus only. Its motivation was to prevent application of the nvidia_bugs quirk on secondary buses. We're about to add a quirk to reset the Broadcom 4331 wireless card on 2011/2012 Macs, which is located on a secondary bus behind a PCIe root port. To facilitate that, reintroduce scanning of secondary buses. The commit message of 8659c406ade3 notes that scanning only the root bus "saves quite some unnecessary scanning work". The algorithm used prior to 8659c406ade3 was particularly time consuming because it scanned buses 0 to 31 brute force. To avoid lengthening boot time, employ a recursive strategy which only scans buses that are actually reachable from the root bus. Yinghai Lu pointed out that the secondary bus number read from a bridge's config space may be invalid, in particular a value of 0 would cause an infinite loop. The PCI core goes beyond that and recurses to a child bus only if its bus number is greater than the parent bus number (see pci_scan_bridge()). Since the root bus is numbered 0, this implies that secondary buses may not be 0. Do the same on early scanning. If this algorithm is found to significantly impact boot time or cause infinite loops on broken hardware, it would be possible to limit its recursion depth: The Broadcom 4331 quirk applies at depth 1, all others at depth 0, so the bus need not be scanned deeper than that for now. An alternative approach would be to revert to scanning only the root bus, and apply the Broadcom 4331 quirk to the root ports 8086:1c12, 8086:1e12 and 8086:1e16. Apple always positioned the card behind either of these three ports. The quirk would then check presence of the card in slot 0 below the root port and do its deed. Signed-off-by: Lukas Wunner Cc: Andy Lutomirski Cc: Bjorn Helgaas Cc: Borislav Petkov Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Josh Poimboeuf Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Yinghai Lu Cc: linux-pci@vger.kernel.org Link: http://lkml.kernel.org/r/f0daa70dac1a9b2483abdb31887173eb6ab77bdf.1465690253.git.lukas@wunner.de Signed-off-by: Ingo Molnar arch/x86/kernel/early-quirks.c | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) commit 447d29d1d3aed839e74c2401ef63387780ac51ed Author: Lukas Wunner Date: Sun Jun 12 12:31:53 2016 +0200 x86/quirks: Apply nvidia_bugs quirk only on root bus Since the following commit: 8659c406ade3 ("x86: only scan the root bus in early PCI quirks") ... early quirks are only applied to devices on the root bus. The motivation was to prevent application of the nvidia_bugs quirk on secondary buses. We're about to reintroduce scanning of secondary buses for a quirk to reset the Broadcom 4331 wireless card on 2011/2012 Macs. To prevent regressions, open code the requirement to apply nvidia_bugs only on the root bus. Signed-off-by: Lukas Wunner Cc: Andy Lutomirski Cc: Bjorn Helgaas Cc: Borislav Petkov Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Josh Poimboeuf Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Yinghai Lu Link: http://lkml.kernel.org/r/4d5477c1d76b2f0387a780f2142bbcdd9fee869b.1465690253.git.lukas@wunner.de Signed-off-by: Ingo Molnar arch/x86/kernel/early-quirks.c | 7 +++++++ 1 file changed, 7 insertions(+) commit eb019503569c8c701f1e9c70e848d99c6680839b Author: Vegard Nossum Date: Sun Jul 10 19:14:01 2016 +0200 perf/x86: Fix bogus kernel printk, again This showed up as "6Failed to access..." here. Signed-off-by: Vegard Nossum Cc: Alexander Shishkin Cc: Arnaldo Carvalho de Melo Cc: Chen Yucong Cc: Jiri Olsa Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Fixes: 1b74dde7c47c ("x86/cpu: Convert printk(KERN_ ...) to pr_(...)") Link: http://lkml.kernel.org/r/1468170841-17045-1-git-send-email-vegard.nossum@oracle.com Signed-off-by: Ingo Molnar arch/x86/events/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 617a8d6bc19edd075e8111c6770f79cae75be51f Merge: ee40fb2 88d02a2 Author: Linus Torvalds Date: Sun Jul 10 09:13:02 2016 -0700 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus Pull MIPS fix from Ralf Baechle: "Another week with just a single 4.7 fix. This fixes a possible 'loss' of the huge page bit from pmd on permission change" * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: MIPS: Fix page table corruption on THP permission changes. commit 0ea5ad869c85ac604f3e022bf2c5bef54838433b Author: Josh Poimboeuf Date: Wed Jun 15 15:45:58 2016 -0500 objtool: Fix STACK_FRAME_NON_STANDARD macro checking for function symbols Mathieu Desnoyers reported that the STACK_FRAME_NON_STANDARD macro wasn't working with the lttng_filter_interpret_bytecode() function in the lttng-modules code. Usually the relocation created by STACK_FRAME_NON_STANDARD creates a reference to a section symbol like this: Offset Type Value Addend Name 000000000000000000 X86_64_64 000000000000000000 +3136 .text But in this case it created a reference to a function symbol: Offset Type Value Addend Name 000000000000000000 X86_64_64 0x00000000000003a0 +0 lttng_filter_interpret_bytecode To be honest I have no idea what causes gcc to decide to do one over the other. But both are valid ELF, so add support for the function symbol. Reported-by: Mathieu Desnoyers Signed-off-by: Josh Poimboeuf Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: lttng-dev@lists.lttng.org Link: http://lkml.kernel.org/r/9cee42843bc6d94e990a152e4e0319cfdf6756ef.1466023450.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar tools/objtool/builtin-check.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 95556a883834122c616bbeb942654d745ceb9712 Author: Eric Dumazet Date: Fri Jul 8 11:03:57 2016 +0200 dccp: avoid deadlock in dccp_v4_ctl_send_reset In the prep work I did before enabling BH while handling socket backlog, I missed two points in DCCP : 1) dccp_v4_ctl_send_reset() uses bh_lock_sock(), assuming BH were blocked. It is not anymore always true. 2) dccp_v4_route_skb() was using __IP_INC_STATS() instead of IP_INC_STATS() A similar fix was done for TCP, in commit 47dcc20a39d0 ("ipv4: tcp: ip_send_unicast_reply() is not BH safe") Fixes: 7309f8821fd6 ("dccp: do not assume DCCP code is non preemptible") Fixes: 5413d1babe8f ("net: do not block BH while processing socket backlog") Signed-off-by: Eric Dumazet Reported-by: Dmitry Vyukov Signed-off-by: David S. Miller net/dccp/ipv4.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 03addc2bcebd953e74c52f0664629032fd9767e9 Merge: 5b58d83 65dc689 Author: David S. Miller Date: Sat Jul 9 17:42:18 2016 -0400 Merge branch 'ibmvnic-fixes' Thomas Falcon says: ==================== ibmvnic driver bugfixes and improvements Miscellaneous fixes and improvements on the ibmvnic driver. ==================== Signed-off-by: David S. Miller commit 65dc689182ec5117896d876cc03405ac51427314 Author: Thomas Falcon Date: Wed Jul 6 15:35:18 2016 -0500 ibmvnic: Fix passive VNIC server login process In some cases, if there is no VNIC server available during the driver probe, the driver should wait until it receives an initialization request from the VNIC Server to start the login process. Recent testing has show that this is incorrectly handled in the current driver. The proposed solution handles this initialization request by scheduling a task in the shared workqueue that completes the login process and registers the net device. Signed-off-by: Thomas Falcon Signed-off-by: David S. Miller drivers/net/ethernet/ibm/ibmvnic.c | 61 ++++++++++++++++++++++++++++++++++++-- drivers/net/ethernet/ibm/ibmvnic.h | 2 ++ 2 files changed, 61 insertions(+), 2 deletions(-) commit ea22d51a7831b062978fcf07c3c5ac7ecbb6cbeb Author: Thomas Falcon Date: Wed Jul 6 15:35:17 2016 -0500 ibmvnic: simplify and improve driver probe function This patch creates a function that handles sub-CRQ IRQ creation separately from sub-CRQ initialization. Another function is then needed to release sub-CRQ resources prior to sub-CRQ IRQ creation. These additions allow the driver probe function to be simplified, specifically during the VNIC Server login process. A timeout is also included while waiting for completion of the login process in case the VNIC Server is not available or some other error occurs. Signed-off-by: Thomas Falcon Signed-off-by: David S. Miller drivers/net/ethernet/ibm/ibmvnic.c | 159 ++++++++++++++++++++++++------------- 1 file changed, 103 insertions(+), 56 deletions(-) commit 88eb98a0178219e1d6e9037b71d293f19b89eef2 Author: Thomas Falcon Date: Wed Jul 6 15:35:16 2016 -0500 ibmvnic: dispose irq mappings IRQ mappings were not being properly disposed when releasing sub-CRQ's. Signed-off-by: Thomas Falcon Signed-off-by: David S. Miller drivers/net/ethernet/ibm/ibmvnic.c | 2 ++ 1 file changed, 2 insertions(+) commit b8efb894e672bd0080126c68a076ddcacfcbc0ef Author: Thomas Falcon Date: Wed Jul 6 15:35:15 2016 -0500 ibmvnic: properly start and stop tx queues Since ibmvnic uses multiple tx queues, start and stop all queues when opening and closing devices. Signed-off-by: Thomas Falcon Signed-off-by: David S. Miller drivers/net/ethernet/ibm/ibmvnic.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 8709ed4d4b0eab04561c1ec9e6ea50fd1e3897ff Author: Dave Hansen Date: Fri Jun 17 17:15:03 2016 -0700 x86/cpu: Fix duplicated X86_BUG(9) macro cpufeatures.h currently defines X86_BUG(9) twice on 32-bit: #define X86_BUG_NULL_SEG X86_BUG(9) /* Nulling a selector preserves the base */ ... #ifdef CONFIG_X86_32 #define X86_BUG_ESPFIX X86_BUG(9) /* "" IRET to 16-bit SS corrupts ESP/RSP high bits */ #endif I think what happened was that this added the X86_BUG_ESPFIX, but in an #ifdef below most of the bugs: 58a5aac53313 x86/entry/32: Introduce and use X86_BUG_ESPFIX instead of paravirt_enabled Then this came along and added X86_BUG_NULL_SEG, but collided with the earlier one that did the bug below the main block defining all the X86_BUG()s. 7a5d67048745 x86/cpu: Probe the behavior of nulling out a segment at boot time Signed-off-by: Dave Hansen Acked-by: Andy Lutomirski Cc: Andy Lutomirski Cc: Borislav Petkov Cc: Brian Gerst Cc: Dave Hansen Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Josh Poimboeuf Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/20160618001503.CEE1B141@viggo.jf.intel.com Signed-off-by: Ingo Molnar arch/x86/include/asm/cpufeatures.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 5b58d8361764fc627e19aef1319f5ac7a0d7bf6f Merge: 92f7d07 16a910a Author: David S. Miller Date: Fri Jul 8 23:53:41 2016 -0400 Merge tag 'mac80211-for-davem-2016-07-06' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211 Johannes Berg says: ==================== Two more fixes: * handle allocation failures in new(ish) A-MSDU decapsulation * don't leak memory on nl80211 ACL parse errors ==================== Signed-off-by: David S. Miller commit 92f7d07d68c1dfcbb80b3259f29dad8efe890803 Author: hayeswang Date: Wed Jul 6 17:35:59 2016 +0800 r8152: remove the setting of LAN_WAKE_EN The LAN_WAKE_EN is not used to determine if the device could support WOL. It is used to signal a GPIO pin when a WOL event occurs. The WOL still works even though it is disabled. Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 205e1e255c479f3fd77446415706463b282f94e4 Author: WANG Cong Date: Tue Jul 5 22:12:36 2016 -0700 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 Cc: Paul Mackerras Cc: linux-ppp@vger.kernel.org Cc: Guillaume Nault Cc: Cyrill Gorcunov Signed-off-by: Cong Wang Reviewed-by: Cyrill Gorcunov Signed-off-by: David S. Miller drivers/net/ppp/ppp_generic.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 06708f81528725148473c0869d6af5f809c6824b Author: Dmitri Epshtein Date: Wed Jul 6 04:18:58 2016 +0200 net: mvneta: set real interrupt per packet for tx_done Commit aebea2ba0f74 ("net: mvneta: fix Tx interrupt delay") intended to set coalescing threshold to a value guaranteeing interrupt generation per each sent packet, so that buffers can be released with no delay. In fact setting threshold to '1' was wrong, because it causes interrupt every two packets. According to the documentation a reason behind it is following - interrupt occurs once sent buffers counter reaches a value, which is higher than one specified in MVNETA_TXQ_SIZE_REG(q). This behavior was confirmed during tests. Also when testing the SoC working as a NAS device, better performance was observed with int-per-packet, as it strongly depends on the fact that all transmitted packets are released immediately. This commit enables NETA controller work in interrupt per sent packet mode by setting coalescing threshold to 0. Signed-off-by: Dmitri Epshtein Signed-off-by: Marcin Wojtas Cc: # v3.10+ Fixes aebea2ba0f74 ("net: mvneta: fix Tx interrupt delay") Acked-by: Willy Tarreau Signed-off-by: David S. Miller drivers/net/ethernet/marvell/mvneta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ee40fb2948fc99096836995d4f3ddcc0efbac790 Merge: b987c75 ea1a25c Author: Linus Torvalds Date: Fri Jul 8 18:59:46 2016 -0700 Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "Three fixes. One is the qla24xx MSI regression, one is a theoretical problem over blacklist matching, which would bite USB badly if it ever triggered and one is a system hang with a particular type of IPR device" * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: qla2xxx: Fix NULL pointer deref in QLA interrupt SCSI: fix new bug in scsi_dev_info_list string matching ipr: Clear interrupt on croc/crocodile when running with LSI commit fa5b4a509d7bbba5d45c8ea177bddfd0b618876a Author: Lv Zheng Date: Fri Jul 8 09:25:05 2016 +0800 ACPI / EC: Fix code ordering issue in ec_remove_handlers() There is an order issue in ec_remove_handlers() that acpi_ec_stop() is called before removing the operation region handler. That is incorrect, because the operation region handler removal triggers _REG(DISCONNECT) which may result in new EC transactions to carry out. That existing issue has been triggered by the following commit: Commit: dcf15cbded656a12335bc4151f3f75f10080a375 Subject: ACPI / EC: Fix a boot EC regresion by restoring boot EC which changed the driver to call ec_remove_handlers() after invoking _REG(CONNECT), so the issue has become visible. Fixes: dcf15cbded65 (ACPI / EC: Fix a boot EC regresion by restoring boot EC) Link: https://bugzilla.kernel.org/show_bug.cgi?id=102421 Reported-and-tested-by: Wolfram Sang Reported-by: Nicholas Signed-off-by: Lv Zheng [ rjw: Changelog ] Signed-off-by: Rafael J. Wysocki drivers/acpi/ec.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit b987c759d21a1c7551357e3bc74e7f8026e696a2 Merge: b89c44b f0fe970 Author: Linus Torvalds Date: Fri Jul 8 09:48:28 2016 -0700 Merge tag 'ecryptfs-4.7-rc7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs Pull eCryptfs fixes from Tyler Hicks: "Provide a more concise fix for CVE-2016-1583: - Additionally fixes linux-stable regressions caused by the cherry-picking of the original fix Some very minor changes that have queued up: - Fix typos in code comments - Remove unnecessary check for NULL before destroying kmem_cache" * tag 'ecryptfs-4.7-rc7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs: ecryptfs: don't allow mmap when the lower fs doesn't support it Revert "ecryptfs: forbid opening files without mmap handler" ecryptfs: fix spelling mistakes eCryptfs: fix typos in comment ecryptfs: drop null test before destroy functions commit b89c44bb233b51c3f03eaff22802a70036edf7cd Merge: cfae7e3 522e5cb7 Author: Linus Torvalds Date: Fri Jul 8 09:35:23 2016 -0700 Merge tag 'iommu-fixes-v4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu Pull IOMMU fixes from Joerg Roedel: "Two Fixes: - Intel VT-d fix for a suspend/resume issue, introduced with the scalability improvements in this cycle. - AMD IOMMU fix for systems that have unity mappings defined. There was a race where translation got enabled before the unity mappings were in place. This issue was seen on some HP servers" * tag 'iommu-fixes-v4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu: iommu/amd: Fix unity mapping initialization race iommu/vt-d: Fix infinite loop in free_all_cpu_cached_iovas commit cfae7e3eb1334ff8035bb66f307f3d4010e65646 Merge: 267ba96 6f2d9d9 Author: Linus Torvalds Date: Fri Jul 8 09:12:41 2016 -0700 Merge tag 'for-linus-4.7b-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip Pull xen bug fixes from David Vrabel: - Fix two bugs in the handling of xenbus transactions. - Make the xen acpi driver compatible with Xen 4.7. * tag 'for-linus-4.7b-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen/acpi: allow xen-acpi-processor driver to load on Xen 4.7 xenbus: simplify xenbus_dev_request_and_reply() xenbus: don't bail early from xenbus_dev_request_and_reply() xenbus: don't BUG() on user mode induced condition commit 267ba96492c897970471cbe64f748e3f46ae71cf Merge: a017f58 47c459b Author: Linus Torvalds Date: Fri Jul 8 09:08:27 2016 -0700 Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 fixes from Will Deacon: "A couple of late fixes here, but one that we've been sitting on for a few weeks while the details were worked out. Specifically, we now enforce USER_DS on taking exceptions whilst in the kernel, which avoids leaking kernel data to userspace through things like perf. The other patch is an update to a workaround for a hardware erratum on some Cavium SoCs. Summary: - Enforce USER_DS on exception entry from EL1 - Apply workaround for Cavium errata #27456 on Thunderx-81xx parts" * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: Enable workaround for Cavium erratum 27456 on thunderx-81xx arm64: kernel: Save and restore UAO and addr_limit on exception entry commit a017f583ec87d40b06eee6a6beeabe879c8113dd Merge: 369da7f c76a093 Author: Linus Torvalds Date: Fri Jul 8 09:06:52 2016 -0700 Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Ingo Molnar: "Three fixes: - A boot crash fix with certain configs - a MAINTAINERS entry update - Documentation typo fixes" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/Documentation: Fix various typos in Documentation/x86/ files x86/amd_nb: Fix boot crash on non-AMD systems MAINTAINERS: Update the Calgary IOMMU entry commit 369da7fc6d627aca19baec09ebe4486c69aef5f2 Merge: 612807f ea1dc6f Author: Linus Torvalds Date: Fri Jul 8 09:04:34 2016 -0700 Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Ingo Molnar: "Two load-balancing fixes for cgroups-intense workloads" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/fair: Fix calc_cfs_shares() fixed point arithmetics width confusion sched/fair: Fix effective_load() to consistently use smoothed load commit 612807fe28abb0a04a627684fb5d4d23108edb1b Merge: 977dcf0 2c81a64 Author: Linus Torvalds Date: Fri Jul 8 09:02:16 2016 -0700 Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf fixes from Ingo Molnar: "Various fixes: - 32-bit callgraph bug fix - suboptimal event group scheduling bug fix - event constraint fixes for Broadwell/Skylake - RAPL module name collision fix" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf/core: Fix pmu::filter_match for SW-led groups x86/perf/intel/rapl: Fix module name collision with powercap intel-rapl perf/x86: Fix 32-bit perf user callgraph collection perf/x86/intel: Update event constraints when HT is off commit 977dcf0c475eaefa334f6bf6b63d27742d0eade5 Merge: 18b1667 547aefc Author: Linus Torvalds Date: Fri Jul 8 08:59:33 2016 -0700 Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull irq fixes from Ingo Molnar: "Two MIPS-GIC irqchip driver fixes to unbreak certain MIPS boards" * 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: irqchip/mips-gic: Match IPI IRQ domain by bus token only irqchip/mips-gic: Map to VPs using HW VPNum commit 18b16676c36ae6e438ddb543bbb45accbbc4f901 Merge: 1d110cf 92c74bc Author: Linus Torvalds Date: Fri Jul 8 08:57:03 2016 -0700 Merge tag 'gpio-v4.7-5' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fixes from Linus Walleij: "I don't like to toss in last minute patches, but these are all for things that are broken, and have bitten people for real. Two of them go into stable. Maybe all of them if the compile test problem is a pain in the ass also for stable folks. Final (hopefully) GPIO fixes for v4.7: - Fix an oops on the Asus Eee PC 1201 - Revert a patch trying to split GPIO parsing and GPIO configuration - Revert a too liberal compile testing thing" * tag 'gpio-v4.7-5' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: Revert "gpio: gpiolib-of: Allow compile testing" Revert "gpiolib: Split GPIO flags parsing and GPIO configuration" gpio: sch: Fix Oops on module load on Asus Eee PC 1201 commit 1d110cf5d307bd52e826a2ceaa7daab83be61b7a Merge: cc23c61 39c8859 Author: Linus Torvalds Date: Fri Jul 8 08:55:27 2016 -0700 Merge tag 'drm-fixes-for-v4.7-rc7' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "One nouveau fix, and a few AMD Polaris fixes and some Allwinner fixes. I've got some vmware fixes that I might send separate over the weekend, they fix some black screens, but I'm still debating them" * tag 'drm-fixes-for-v4.7-rc7' of git://people.freedesktop.org/~airlied/linux: drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation. drm/amd/powerplay: fix bug that get wrong polaris evv voltage. drm/amd/powerplay: incorrectly use of the function return value drm/amd/powerplay: fix incorrect voltage table value for tonga drm/amd/powerplay: fix incorrect voltage table value for polaris10 drm/nouveau/disp/sor/gf119: select correct sor when poking training pattern gpu: drm: sun4i_drv: add missing of_node_put after calling of_parse_phandle drm/sun4i: Send vblank event when the CRTC is disabled drm/sun4i: Report proper vblank commit f0fe970df3838c202ef6c07a4c2b36838ef0a88b Author: Jeff Mahoney Date: Tue Jul 5 17:32:30 2016 -0400 ecryptfs: don't allow mmap when the lower fs doesn't support it There are legitimate reasons to disallow mmap on certain files, notably in sysfs or procfs. We shouldn't emulate mmap support on file systems that don't offer support natively. CVE-2016-1583 Signed-off-by: Jeff Mahoney Cc: stable@vger.kernel.org [tyhicks: clean up f_op check by using ecryptfs_file_to_lower()] Signed-off-by: Tyler Hicks fs/ecryptfs/file.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit 58541f7a6458e17ab417321b284f0090f530aa91 Author: Sinclair Yeh Date: Thu Jul 7 11:01:30 2016 -0700 drm/vmwgfx: Fix error paths when mapping framebuffer Rather than returning immediately, make sure to unlock the mutexes first. Signed-off-by: Sinclair Yeh Reviewed-by: Charmaine Lee Reported-by: Emil Velikov Cc: drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6f2d9d99213514360034c6d52d2c3919290b3504 Author: Jan Beulich Date: Fri Jul 8 06:15:07 2016 -0600 xen/acpi: allow xen-acpi-processor driver to load on Xen 4.7 As of Xen 4.7 PV CPUID doesn't expose either of CPUID[1].ECX[7] and CPUID[0x80000007].EDX[7] anymore, causing the driver to fail to load on both Intel and AMD systems. Doing any kind of hardware capability checks in the driver as a prerequisite was wrong anyway: With the hypervisor being in charge, all such checking should be done by it. If ACPI data gets uploaded despite some missing capability, the hypervisor is free to ignore part or all of that data. Ditch the entire check_prereq() function, and do the only valid check (xen_initial_domain()) in the caller in its place. Signed-off-by: Jan Beulich Cc: Signed-off-by: David Vrabel drivers/xen/xen-acpi-processor.c | 35 +++-------------------------------- 1 file changed, 3 insertions(+), 32 deletions(-) commit c8607e020014cf11a61601a0005270bad81cabdf Author: Florian Westphal Date: Wed Jul 6 14:53:06 2016 +0200 netfilter: nft_ct: fix expiration getter We need to compute timeout.expires - jiffies, not the other way around. Add a helper, another patch can then later change more places in conntrack code where we currently open-code this. Will allow us to only change one place later when we remove per-ct timer. Signed-off-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso include/net/netfilter/nf_conntrack.h | 8 ++++++++ net/netfilter/nft_ct.c | 6 +----- 2 files changed, 9 insertions(+), 5 deletions(-) commit e5a79475a7ae171fef82608c6e11f51bb85a6745 Author: Jan Beulich Date: Thu Jul 7 01:32:35 2016 -0600 xenbus: simplify xenbus_dev_request_and_reply() No need to retain a local copy of the full request message, only the type is really needed. Signed-off-by: Jan Beulich Signed-off-by: David Vrabel drivers/xen/xenbus/xenbus_xs.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 7469be95a487319514adce2304ad2af3553d2fc9 Author: Jan Beulich Date: Thu Jul 7 01:32:04 2016 -0600 xenbus: don't bail early from xenbus_dev_request_and_reply() xenbus_dev_request_and_reply() needs to track whether a transaction is open. For XS_TRANSACTION_START messages it calls transaction_start() and for XS_TRANSACTION_END messages it calls transaction_end(). If sending an XS_TRANSACTION_START message fails or responds with an an error, the transaction is not open and transaction_end() must be called. If sending an XS_TRANSACTION_END message fails, the transaction is still open, but if an error response is returned the transaction is closed. Commit 027bd7e89906 ("xen/xenbus: Avoid synchronous wait on XenBus stalling shutdown/restart") introduced a regression where failed XS_TRANSACTION_START messages were leaving the transaction open. This can cause problems with suspend (and migration) as all transactions must be closed before suspending. It appears that the problematic change was added accidentally, so just remove it. Signed-off-by: Jan Beulich Cc: Konrad Rzeszutek Wilk Cc: Signed-off-by: David Vrabel drivers/xen/xenbus/xenbus_xs.c | 3 --- 1 file changed, 3 deletions(-) commit a8ff48cb70835f48de5703052760312019afea55 Author: Takashi Iwai Date: Fri Jul 8 08:23:43 2016 +0200 ALSA: pcm: Free chmap at PCM free callback, too The chmap ctls assigned to PCM streams are freed in the PCM disconnect callback. However, since the disconnect callback isn't called when the card gets freed before registering, the chmap ctls may still be left assigned. They are eventually freed together with other ctls, but it may cause an Oops at pcm_chmap_ctl_private_free(), as the function refers to the assigned PCM stream, while the PCM objects have been already freed beforehand. The fix is to free the chmap ctls also at PCM free callback, not only at PCM disconnect. Reported-by: Laxminath Kasam Cc: Signed-off-by: Takashi Iwai sound/core/pcm.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) commit f388cdcdd160687c6650833f286b9c89c50960ff Author: Takashi Iwai Date: Fri Jul 8 08:05:19 2016 +0200 ALSA: ctl: Stop notification after disconnection snd_ctl_remove() has a notification for the removal event. It's superfluous when done during the device got disconnected. Although the notification itself is mostly harmless, it may potentially be harmful, and should be suppressed. Actually some components PCM may free ctl elements during the disconnect or free callbacks, thus it's no theoretical issue. This patch adds the check of card->shutdown flag for avoiding unnecessary notifications after (or during) the disconnect. Cc: Signed-off-by: Takashi Iwai sound/core/control.c | 2 ++ 1 file changed, 2 insertions(+) commit 8a132099f080d7384bb6ab4cc168f76cb4b47d08 Author: Hui Wang Date: Fri Jul 8 14:26:57 2016 +0800 ALSA: hda/realtek - add new pin definition in alc225 pin quirk table We have some Dell laptops which can't detect headset mic, the machines use the codec ALC225, they have some new pin configuration values, after adding them in the alc225 pin quirk table, they work well. Cc: Signed-off-by: Hui Wang Signed-off-by: Takashi Iwai sound/pci/hda/patch_realtek.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit cc23c619f8da3ccbe6a856c79fb5a3d245b68daf Merge: 7ed18e2 30a46a4 Author: Linus Torvalds Date: Thu Jul 7 20:56:09 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull apparmor fix from James Morris. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: apparmor: fix oops, validate buffer size in apparmor_setprocattr() commit 7ed18e2d1b6782989eb399ef79a8cc1a1b583b3c Merge: c09230f b6d9015 Author: Linus Torvalds Date: Thu Jul 7 20:49:41 2016 -0700 Merge tag 'acpi-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fixes from Rafael Wysocki: "All of these fix recent regressions in ACPICA, in the ACPI PCI IRQ management code and in the ACPI AML debugger. Specifics: - Fix a lock ordering issue in ACPICA introduced by a recent commit that attempted to fix a deadlock in the dynamic table loading code which in turn appeared after changes related to the handling of module-level AML also made in this cycle (Lv Zheng). - Fix a recent regression in the ACPI IRQ management code that may cause PCI drivers to be unable to register an IRQ if that IRQ happens to be shared with a device on the ISA bus, like the parallel port, by reverting one commit entirely and restoring the previous behavior in two other places (Sinan Kaya). - Fix a recent regression in the ACPI AML debugger introduced by the commit that removed incorrect usage of IS_ERR_VALUE() from multiple places (Lv Zheng)" * tag 'acpi-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / debugger: Fix regression introduced by IS_ERR_VALUE() removal ACPICA: Namespace: Fix namespace/interpreter lock ordering ACPI,PCI,IRQ: separate ISA penalty calculation Revert "ACPI, PCI, IRQ: remove redundant code in acpi_irq_penalty_init()" ACPI,PCI,IRQ: factor in PCI possible commit c09230f30876589e246c83a4b4649e60534638cf Merge: ac904ae 7fe39a2 Author: Linus Torvalds Date: Thu Jul 7 20:46:48 2016 -0700 Merge tag 'pm-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "One fix for a recent cpuidle core change that, against all odds, introduced a functional regression on Power systems and the fix for the crash during resume from hibernation on x86-64 that has been in the works for the last few weeks (it actually was ready last week, but I wanted to allow the reporters to test if for some more time). Specifics: - Fix a recent performance regression on Power systems (powernv and pseries) introduced by a core cpuidle commit that decreased the precision of the last_residency conversion from nano- to microseconds, which should not matter in theory, but turned out to play not-so-well with the special "snooze" idle state on Power (Shreyas B Prabhu). - Fix a crash during resume from hibernation on x86-64 caused by possible corruption of the kernel text part of page tables in the last phase of image restoration exposed by a security-related change during the 4.3 development cycle (Rafael Wysocki)" * tag 'pm-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: cpuidle: Fix last_residency division x86/power/64: Fix kernel text mapping corruption during image restoration commit 39c8859418d5d2d29482fcd7d58daba6e299fac5 Merge: 27c0b74 3b8e64f Author: Dave Airlie Date: Fri Jul 8 13:29:11 2016 +1000 Merge tag 'sunxi-drm-fixes-for-4.7-2' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into drm-fixes Allwinner DRM driver fixes for 4.7, take 2 A new set of fixes for the sun4i driver, mostly related to vblank handling, and a minor fix to release a reference on the device tree nodes we're parsing in the probe logic. * tag 'sunxi-drm-fixes-for-4.7-2' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: gpu: drm: sun4i_drv: add missing of_node_put after calling of_parse_phandle drm/sun4i: Send vblank event when the CRTC is disabled drm/sun4i: Report proper vblank commit 30a46a4647fd1df9cf52e43bf467f0d9265096ca Author: Vegard Nossum Date: Thu Jul 7 13:41:11 2016 -0700 apparmor: fix oops, validate buffer size in apparmor_setprocattr() When proc_pid_attr_write() was changed to use memdup_user apparmor's (interface violating) assumption that the setprocattr buffer was always a single page was violated. The size test is not strictly speaking needed as proc_pid_attr_write() will reject anything larger, but for the sake of robustness we can keep it in. SMACK and SELinux look safe to me, but somebody else should probably have a look just in case. Based on original patch from Vegard Nossum modified for the case that apparmor provides null termination. Fixes: bb646cdb12e75d82258c2f2e7746d5952d3e321a Reported-by: Vegard Nossum Cc: Al Viro Cc: John Johansen Cc: Paul Moore Cc: Stephen Smalley Cc: Eric Paris Cc: Casey Schaufler Cc: stable@kernel.org Signed-off-by: John Johansen Reviewed-by: Tyler Hicks Signed-off-by: James Morris security/apparmor/lsm.c | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) commit 78c4e172412de5d0456dc00d2b34050aa0b683b5 Author: Jeff Mahoney Date: Tue Jul 5 17:32:29 2016 -0400 Revert "ecryptfs: forbid opening files without mmap handler" This reverts commit 2f36db71009304b3f0b95afacd8eba1f9f046b87. It fixed a local root exploit but also introduced a dependency on the lower file system implementing an mmap operation just to open a file, which is a bit of a heavy hammer. The right fix is to have mmap depend on the existence of the mmap handler instead. Signed-off-by: Jeff Mahoney Cc: stable@vger.kernel.org Signed-off-by: Tyler Hicks fs/ecryptfs/kthread.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit ac904ae6e6f0a56be7b9a1cf66fbd50dd025fb06 Merge: 4c2a849 8ba8682 Author: Linus Torvalds Date: Thu Jul 7 15:34:09 2016 -0700 Merge branch 'for-linus' of git://git.kernel.dk/linux-block Pull block IO fixes from Jens Axboe: "Three small fixes that have been queued up and tested for this series: - A bug fix for xen-blkfront from Bob Liu, fixing an issue with incomplete requests during migration. - A fix for an ancient issue in retrieving the IO priority of a different PID than self, preventing that task from going away while we access it. From Omar. - A writeback fix from Tahsin, fixing a case where we'd call ihold() with a zero ref count inode" * 'for-linus' of git://git.kernel.dk/linux-block: block: fix use-after-free in sys_ioprio_get() writeback: inode cgroup wb switch should not call ihold() xen-blkfront: save uncompleted reqs in blkfront_resume() commit 4c2a8499a450b6582eb5637a8f0d472168355ddd Merge: 076501f f860898 Author: Linus Torvalds Date: Thu Jul 7 15:32:17 2016 -0700 Merge tag 'configfs-for-4.7' of git://git.infradead.org/users/hch/configfs Pull configfs fix from Christoph Hellwig: "A fix from Marek for ppos handling in configfs_write_bin_file, which was introduced in Linux 4.5, but didn't have any users until recently" * tag 'configfs-for-4.7' of git://git.infradead.org/users/hch/configfs: configfs: Remove ppos increment in configfs_write_bin_file commit b6d90158c935d4a22e56f41647b479ab5ea449d4 Merge: 4520904 f7eca37 7e3fd81 Author: Rafael J. Wysocki Date: Thu Jul 7 23:37:37 2016 +0200 Merge branches 'acpica-fixes', 'acpi-pci-fixes' and 'acpi-debug-fixes' * acpica-fixes: ACPICA: Namespace: Fix namespace/interpreter lock ordering * acpi-pci-fixes: ACPI,PCI,IRQ: separate ISA penalty calculation Revert "ACPI, PCI, IRQ: remove redundant code in acpi_irq_penalty_init()" ACPI,PCI,IRQ: factor in PCI possible * acpi-debug-fixes: ACPI / debugger: Fix regression introduced by IS_ERR_VALUE() removal commit 7fe39a21557b251e101671f2c3f79558a756afef Merge: a99cde4 dbd1b8e 65c0554 Author: Rafael J. Wysocki Date: Thu Jul 7 23:17:20 2016 +0200 Merge branches 'pm-cpuidle-fixes' and 'pm-sleep-fixes' * pm-cpuidle-fixes: cpuidle: Fix last_residency division * pm-sleep-fixes: x86/power/64: Fix kernel text mapping corruption during image restoration commit 3777ed688fba82d0bd43f9fc1ebbc6abe788576d Author: Quentin Armitage Date: Thu Jun 16 08:00:14 2016 +0100 ipvs: fix bind to link-local mcast IPv6 address in backup When using HEAD from https://git.kernel.org/cgit/utils/kernel/ipvsadm/ipvsadm.git/, the command: ipvsadm --start-daemon backup --mcast-interface eth0.60 \ --mcast-group ff02::1:81 fails with the error message: Argument list too long whereas both: ipvsadm --start-daemon master --mcast-interface eth0.60 \ --mcast-group ff02::1:81 and: ipvsadm --start-daemon backup --mcast-interface eth0.60 \ --mcast-group 224.0.0.81 are successful. The error message "Argument list too long" isn't helpful. The error occurs because an IPv6 address is given in backup mode. The error is in make_receive_sock() in net/netfilter/ipvs/ip_vs_sync.c, since it fails to set the interface on the address or the socket before calling inet6_bind() (via sock->ops->bind), where the test 'if (!sk->sk_bound_dev_if)' failed. Setting sock->sk->sk_bound_dev_if on the socket before calling inet6_bind() resolves the issue. Fixes: d33288172e72 ("ipvs: add more mcast parameters for the sync daemon") Signed-off-by: Quentin Armitage Acked-by: Julian Anastasov Signed-off-by: Simon Horman net/netfilter/ipvs/ip_vs_sync.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 47c459beabe969c6751e2ea8d1f85c5fa1652d6c Author: Ganapatrao Kulkarni Date: Thu Jul 7 10:18:17 2016 +0530 arm64: Enable workaround for Cavium erratum 27456 on thunderx-81xx Cavium erratum 27456 commit 104a0c02e8b1 ("arm64: Add workaround for Cavium erratum 27456") is applicable for thunderx-81xx pass1.0 SoC as well. Adding code to enable to 81xx. Signed-off-by: Ganapatrao Kulkarni Reviewed-by: Andrew Pinski Signed-off-by: Will Deacon arch/arm64/include/asm/cputype.h | 2 ++ arch/arm64/kernel/cpu_errata.c | 6 ++++++ 2 files changed, 8 insertions(+) commit e19a6ee2460bdd0d0055a6029383422773f9999a Author: James Morse Date: Mon Jun 20 18:28:01 2016 +0100 arm64: kernel: Save and restore UAO and addr_limit on exception entry If we take an exception while at EL1, the exception handler inherits the original context's addr_limit and PSTATE.UAO values. To be consistent always reset addr_limit and PSTATE.UAO on (re-)entry to EL1. This prevents accidental re-use of the original context's addr_limit. Based on a similar patch for arm from Russell King. Cc: # 4.6- Acked-by: Will Deacon Reviewed-by: Mark Rutland Signed-off-by: James Morse Signed-off-by: Will Deacon arch/arm64/include/asm/ptrace.h | 2 ++ arch/arm64/kernel/asm-offsets.c | 1 + arch/arm64/kernel/entry.S | 19 +++++++++++++++++-- arch/arm64/mm/fault.c | 3 ++- 4 files changed, 22 insertions(+), 3 deletions(-) commit 0beef634b86a1350c31da5fcc2992f0d7c8a622b Author: Jan Beulich Date: Thu Jul 7 01:23:57 2016 -0600 xenbus: don't BUG() on user mode induced condition Inability to locate a user mode specified transaction ID should not lead to a kernel crash. For other than XS_TRANSACTION_START also don't issue anything to xenbus if the specified ID doesn't match that of any active transaction. Signed-off-by: Jan Beulich Cc: Signed-off-by: David Vrabel drivers/xen/xenbus/xenbus_dev_frontend.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit 2c81a6477081966fe80b8c6daa68459bca896774 Author: Mark Rutland Date: Tue Jun 14 16:10:41 2016 +0100 perf/core: Fix pmu::filter_match for SW-led groups The following commit: 66eb579e66ec ("perf: allow for PMU-specific event filtering") added the pmu::filter_match() callback. This was intended to avoid HW constraints on events from resulting in extremely pessimistic scheduling. However, pmu::filter_match() is only called for the leader of each event group. When the leader is a SW event, we do not filter the groups, and may fail at pmu::add() time, and when this happens we'll give up on scheduling any event groups later in the list until they are rotated ahead of the failing group. This can result in extremely sub-optimal event scheduling behaviour, e.g. if running the following on a big.LITTLE platform: $ taskset -c 0 ./perf stat \ -e 'a57{context-switches,armv8_cortex_a57/config=0x11/}' \ -e 'a53{context-switches,armv8_cortex_a53/config=0x11/}' \ ls context-switches (0.00%) armv8_cortex_a57/config=0x11/ (0.00%) 24 context-switches (37.36%) 57589154 armv8_cortex_a53/config=0x11/ (37.36%) Here the 'a53' event group was always eligible to be scheduled, but the 'a57' group never eligible to be scheduled, as the task was always affine to a Cortex-A53 CPU. The SW (group leader) event in the 'a57' group was eligible, but the HW event failed at pmu::add() time, resulting in ctx_flexible_sched_in giving up on scheduling further groups with HW events. One way of avoiding this is to check pmu::filter_match() on siblings as well as the group leader. If any of these fail their pmu::filter_match() call, we must skip the entire group before attempting to add any events. Signed-off-by: Mark Rutland Signed-off-by: Peter Zijlstra (Intel) Cc: Alexander Shishkin Cc: Arnaldo Carvalho de Melo Cc: Arnaldo Carvalho de Melo Cc: Jiri Olsa Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Will Deacon Fixes: 66eb579e66ec ("perf: allow for PMU-specific event filtering") Link: http://lkml.kernel.org/r/1465917041-15339-1-git-send-email-mark.rutland@arm.com [ Small readability edits. ] Signed-off-by: Ingo Molnar kernel/events/core.c | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) commit 5eb495349f5ec3b134f7341a2450392fc86d99d0 Author: Lucas Stach Date: Thu Jun 30 17:32:08 2016 +0200 ARM: tegra: beaver: Allow SD card voltage to be changed This allows to switch the card signal voltage level to 1.8 V, which is needed for any ultra high speed modes to work. Signed-off-by: Lucas Stach Acked-by: Jon Hunter Signed-off-by: Thierry Reding Signed-off-by: Olof Johansson arch/arm/boot/dts/tegra30-beaver.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 27c0b7419c3a9249b72a67f2c575e22aedd67a67 Merge: fd508702 2172150 Author: Dave Airlie Date: Thu Jul 7 12:40:12 2016 +1000 Merge branch 'linux-4.7' of git://github.com/skeggsb/linux into drm-fixes Just one fix for a stupid thinko in a DP training pattern commit. * 'linux-4.7' of git://github.com/skeggsb/linux: drm/nouveau/disp/sor/gf119: select correct sor when poking training pattern commit fd50870296d6e73ff277d9f1a518d68c95d17f63 Merge: a99cde4 ab6bad0 Author: Dave Airlie Date: Thu Jul 7 12:37:42 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes Just a couple of fixes for amdgpu for 4.7: - 2 small tonga powerplay fixes - Additional Polaris fixes * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation. drm/amd/powerplay: fix bug that get wrong polaris evv voltage. drm/amd/powerplay: incorrectly use of the function return value drm/amd/powerplay: fix incorrect voltage table value for tonga drm/amd/powerplay: fix incorrect voltage table value for polaris10 commit 076501ff6ba265a473689c112eda9f1f34f620b5 Author: Randy Dunlap Date: Wed Jul 6 16:06:53 2016 -0700 init/Kconfig: keep Expert users menu together The "expert" menu was broken (split) such that all entries in it after KALLSYMS were displayed in the "General setup" area instead of in the "Expert users" area. Fix this by adding one kconfig dependency. Yes, the Expert users menu is fragile. Problems like this have happened several times in the past. I will attempt to isolate the Expert users menu if there is interest in that. Fixes: 4d5d5664c900 ("x86: kallsyms: disable absolute percpu symbols on !SMP") Signed-off-by: Randy Dunlap Cc: Ard Biesheuvel Cc: stable@vger.kernel.org # 4.6 Signed-off-by: Linus Torvalds init/Kconfig | 1 + 1 file changed, 1 insertion(+) commit ab6bad05c886cf0ef0c86bd1f665cdbe8e5e75e7 Author: Rex Zhu Date: Tue Jun 28 16:55:52 2016 -0400 drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation. As get the right evv voltage, update them to latest coefficients to align with BB. agd: squash in Slava's 32 bit build fix Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 23 ++++++++++------------ 1 file changed, 10 insertions(+), 13 deletions(-) commit e5eb37170b3cbbf948c6aeaccece818a59e76a6c Author: Rex Zhu Date: Wed Jun 29 16:37:35 2016 +0800 drm/amd/powerplay: fix bug that get wrong polaris evv voltage. value is 32 bits for polaris, not 16. Signed-off-by: Rex Zhu Reviewed-by: Ken Wang Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 7 ++++--- drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.c | 4 ++-- drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.h | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) commit 4b2427605e5325eafb5cfc2698f517db68e41075 Author: Rex Zhu Date: Tue Jul 5 13:11:47 2016 +0800 drm/amd/powerplay: incorrectly use of the function return value '0' means true. Signed-off-by: Rex Zhu Reviewed-by: Michel Dänzer Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/powerplay/hwmgr/tonga_processpptables.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1dfefee8939b07dd65a35bb78f6a06df85578301 Author: Huang Rui Date: Wed Jul 6 09:32:24 2016 +0800 drm/amd/powerplay: fix incorrect voltage table value for tonga Signed-off-by: Huang Rui Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 095d28c62f9a05edc186e1b2b02bc44585402bdd Author: Huang Rui Date: Wed Jul 6 09:31:35 2016 +0800 drm/amd/powerplay: fix incorrect voltage table value for polaris10 Signed-off-by: Huang Rui Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc86765181aa26cc9afcb0a6f9f253cbb1186f26 Merge: 4cdbbbd 903ce4a Author: Linus Torvalds Date: Wed Jul 6 09:42:43 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes from David Miller: 1) All users of AF_PACKET's fanout feature want a symmetric packet header hash for load balancing purposes, so give it to them. 2) Fix vlan state synchronization in e1000e, from Jarod Wilson. 3) Use correct socket pointer in ip_skb_dst_mtu(), from Shmulik Ladkani. 4) mlx5 bug fixes from Mohamad Haj Yahia, Daniel Jurgens, Matthew Finlay, Rana Shahout, and Shaker Daibes. Mostly to do with operation timeouts and PCI error handling. 5) Fix checksum handling in mirred packet action, from WANG Cong. 6) Set skb->dev correctly when transmitting in !protect_frames case of macsec driver, from Daniel Borkmann. 7) Fix MTU calculation in geneve driver, from Haishuang Yan. 8) Missing netif_napi_del() in unregister path of qeth driver, from Ursula Braun. 9) Handle malformed route netlink messages in decnet properly, from Vergard Nossum. 10) Memory leak of percpu data in ipv6 routing code, from Martin KaFai Lau. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (41 commits) ipv6: Fix mem leak in rt6i_pcpu net: fix decnet rtnexthop parsing cxgb4: update latest firmware version supported net/mlx5: Avoid setting unused var when modifying vport node GUID bonding: fix enslavement slave link notifications r8152: fix runtime function for RTL8152 qeth: delete napi struct when removing a qeth device Revert "fsl/fman: fix error handling" fsl/fman: fix error handling cdc_ncm: workaround for EM7455 "silent" data interface RDS: fix rds_tcp_init() error path geneve: fix max_mtu setting net: phy: dp83867: Fix initialization of PHYCR register enc28j60: Fix race condition in enc28j60 driver net: stmmac: Fix null-function call in ISR on stmmac1000 tipc: fix nl compat regression for link statistics net: bcmsysport: Device stats are unsigned long macsec: set actual real device for xmit when !protect_frames net_sched: fix mirrored packets checksum packet: Use symmetric hash for PACKET_FANOUT_HASH. ... commit 4cdbbbd11f53c32f2359722148033b5e13dd33b5 Merge: 4d0a279 9cd2574 Author: Linus Torvalds Date: Wed Jul 6 09:12:43 2016 -0700 Merge tag 'sound-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "Here are a collection of small fixes: at this time, we've got a slightly high amount, but all small and trivial fixes, and nothing scary can be seen there" * tag 'sound-4.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (21 commits) ALSA: hda/realtek: Add Lenovo L460 to docking unit fixup ALSA: timer: Fix negative queue usage by racy accesses ASoC: rt5645: fix reg-2f default value. ASoC: fsl_ssi: Fix number of words per frame for I2S-slave mode ALSA: au88x0: Fix calculation in vortex_wtdma_bufshift() ALSA: hda - Add PCI ID for Kabylake-H ALSA: echoaudio: Fix memory allocation ASoC: Intel: atom: fix missing breaks that would cause the wrong operation to execute ALSA: hda - fix read before array start ASoC: cx20442: set tty->receiver_room in v253_open ASoC: ak4613: Enable cache usage to fix crashes on resume ASoC: wm8940: Enable cache usage to fix crashes on resume ASoC: Intel: Skylake: Initialize module list for Broxton ASoC: wm5102: Correct supported channels on trace compressed DAI ASoC: wm5110: Add missing route from OUT3R to SYSCLK ASoC: rt5670: fix HP Playback Volume control ASoC: hdmi-codec: select CONFIG_HDMI ASoC: davinci-mcasp: Fix dra7 DMA offset when using CFG port ASoC: hdac_hdmi: Fix potential NULL dereference ASoC: ak4613: Remove owner assignment from platform_driver ... commit 4d0a279c7c9965d080c029f85b9e7fa4a8e1973e Merge: a99cde4 096cdc6 Author: Linus Torvalds Date: Wed Jul 6 09:07:23 2016 -0700 Merge tag 'chrome-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/olof/chrome-platform Pull chrome platform fix from Olof Johansson: "A single fix this time, closing a window where ioctl args are fetched twice" * tag 'chrome-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/olof/chrome-platform: platform/chrome: cros_ec_dev - double fetch bug in ioctl commit 522e5cb76d0663c88f96b6a8301451c8efa37207 Author: Joerg Roedel Date: Fri Jul 1 16:42:55 2016 +0200 iommu/amd: Fix unity mapping initialization race There is a race condition in the AMD IOMMU init code that causes requested unity mappings to be blocked by the IOMMU for a short period of time. This results on boot failures and IO_PAGE_FAULTs on some machines. Fix this by making sure the unity mappings are installed before all other DMA is blocked. Fixes: aafd8ba0ca74 ('iommu/amd: Implement add_device and remove_device') Cc: stable@vger.kernel.org # v4.2+ Signed-off-by: Joerg Roedel drivers/iommu/amd_iommu_init.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit ea1a25c3348abc33d7d94db28501766adf3d1c7d Merge: 5e7ff2c 262e2bf Author: James Bottomley Date: Wed Jul 6 07:25:55 2016 -0700 Merge branch 'jejb-fixes' into fixes commit d1fe176ca51fa3cb35f70c1d876d9a090e9befce Author: Sven Eckelmann Date: Sun Jun 12 10:43:19 2016 +0200 batman-adv: Fix speedy join in gateway client mode Speedy join only works when the received packet is either broadcast or an 4addr unicast packet. Thus packets converted from broadcast to unicast via the gateway handling code have to be converted to 4addr packets to allow the receiving gateway server to add the sender address as temporary entry to the translation table. Not doing it will make the batman-adv gateway server drop the DHCP response in many situations because it doesn't yet have the TT entry for the destination of the DHCP response. Fixes: 371351731e9c ("batman-adv: change interface_rx to get orig node") Signed-off-by: Sven Eckelmann Acked-by: Antonio Quartulli Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/send.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 88d02a2ba6c52350f9a73ff1b01a5be839c3ca17 Author: David Daney Date: Thu Jun 16 15:50:31 2016 -0700 MIPS: Fix page table corruption on THP permission changes. When the core THP code is modifying the permissions of a huge page it calls pmd_modify(), which unfortunately was clearing the _PAGE_HUGE bit of the page table entry. The result can be kernel messages like: mm/memory.c:397: bad pmd 000000040080004d. mm/memory.c:397: bad pmd 00000003ff00004d. mm/memory.c:397: bad pmd 000000040100004d. or: ------------[ cut here ]------------ WARNING: at mm/mmap.c:3200 exit_mmap+0x150/0x158() Modules linked in: ipv6 at24 octeon3_ethernet octeon_srio_nexus m25p80 CPU: 12 PID: 1295 Comm: pmderr Not tainted 3.10.87-rt80-Cavium-Octeon #4 Stack : 0000000040808000 0000000014009ce1 0000000000400004 ffffffff81076ba0 0000000000000000 0000000000000000 ffffffff85110000 0000000000000119 0000000000000004 0000000000000000 0000000000000119 43617669756d2d4f 0000000000000000 ffffffff850fda40 ffffffff85110000 0000000000000000 0000000000000000 0000000000000009 ffffffff809207a0 0000000000000c80 ffffffff80f1bf20 0000000000000001 000000ffeca36828 0000000000000001 0000000000000000 0000000000000001 000000ffeca7e700 ffffffff80886924 80000003fd7a0000 80000003fd7a39b0 80000003fdea8000 ffffffff80885780 80000003fdea8000 ffffffff80f12218 000000000000000c 000000000000050f 0000000000000000 ffffffff80865c4c 0000000000000000 0000000000000000 ... Call Trace: [] show_stack+0x6c/0xf8 [] warn_slowpath_common+0x78/0xa8 [] exit_mmap+0x150/0x158 [] mmput+0x5c/0x110 [] do_exit+0x230/0xa68 [] do_group_exit+0x54/0x1d0 [] __wake_up_parent+0x0/0x18 ---[ end trace c7b38293191c57dc ]--- BUG: Bad rss-counter state mm:80000003fa168000 idx:1 val:1536 Fix by not clearing _PAGE_HUGE bit. Signed-off-by: David Daney Tested-by: Aaro Koskinen Cc: stable@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13687/ Signed-off-by: Ralf Baechle arch/mips/include/asm/pgtable.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 16a910a6722b7a8680409e634c7c0dac073c01e4 Author: Gregory Greenman Date: Tue Jul 5 15:23:10 2016 +0300 cfg80211: handle failed skb allocation Handle the case when dev_alloc_skb returns NULL. Cc: stable@vger.kernel.org Fixes: 2b67f944f88c2 ("cfg80211: reuse existing page fragments in A-MSDU rx") Signed-off-by: Gregory Greenman Signed-off-by: Luca Coelho Signed-off-by: Johannes Berg net/wireless/util.c | 2 ++ 1 file changed, 2 insertions(+) commit 6e8ef842223b90a33efd570128bb566a9ae6f5ad Author: Purushottam Kushwaha Date: Tue Jul 5 13:44:51 2016 +0530 nl80211: Move ACL parsing later to avoid a possible memory leak No support for pbss results in a memory leak for the acl_data (if parse_acl_data succeeds). Fix this by moving the ACL parsing later. Cc: stable@vger.kernel.org Fixes: 34d505193bd10 ("cfg80211: basic support for PBSS network type") Signed-off-by: Purushottam Kushwaha Signed-off-by: Johannes Berg net/wireless/nl80211.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 175a20c16fdb7700fcac63f1eeb2caa7e1dddd2d Author: Ville Syrjälä Date: Thu Jun 23 18:06:49 2016 +0300 x86/perf/intel/rapl: Fix module name collision with powercap intel-rapl Since commit 4b6e2571bf00 the rapl perf module calls itself intel-rapl. That name was already in use by the rapl powercap driver, which now fails to load if the perf module is loaded. Fix the problem by renaming the perf module to intel-rapl-perf, so that both modules can coexist. Fixes: 4b6e2571bf00 ("x86/perf/intel/rapl: Make the Intel RAPL PMU driver modular") Signed-off-by: Ville Syrjälä Cc: Vince Weaver Cc: Alexander Shishkin Cc: Kan Liang Cc: Stephane Eranian Cc: Arnaldo Carvalho de Melo Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Jiri Olsa Link: http://lkml.kernel.org/r/1466694409-3620-1-git-send-email-ville.syrjala@linux.intel.com Signed-off-by: Thomas Gleixner arch/x86/events/intel/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9d6928639134cff896a92f8ff7fad14370e88d3c Merge: 0863477 9ca91a6 Author: Michael Turquette Date: Tue Jul 5 17:16:08 2016 -0700 Merge tag 'sunxi-clk-fixes-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into clk-fixes Allwinner clock fixes for 4.7 A bunch of changes for the display clocks merged in 4.7 commit 903ce4abdf374e3365d93bcb3df56c62008835ba Author: Martin KaFai Lau Date: Tue Jul 5 12:10:23 2016 -0700 ipv6: Fix mem leak in rt6i_pcpu It was first reported and reproduced by Petr (thanks!) in https://bugzilla.kernel.org/show_bug.cgi?id=119581 free_percpu(rt->rt6i_pcpu) used to always happen in ip6_dst_destroy(). However, after fixing a deadlock bug in commit 9c7370a166b4 ("ipv6: Fix a potential deadlock when creating pcpu rt"), free_percpu() is not called before setting non_pcpu_rt->rt6i_pcpu to NULL. It is worth to note that rt6i_pcpu is protected by table->tb6_lock. kmemleak somehow did not report it. We nailed it down by observing the pcpu entries in /proc/vmallocinfo (first suggested by Hannes, thanks!). Signed-off-by: Martin KaFai Lau Fixes: 9c7370a166b4 ("ipv6: Fix a potential deadlock when creating pcpu rt") Reported-by: Petr Novopashenniy Tested-by: Petr Novopashenniy Acked-by: Hannes Frederic Sowa Cc: Hannes Frederic Sowa Cc: Petr Novopashenniy Signed-off-by: David S. Miller net/ipv6/ip6_fib.c | 1 + 1 file changed, 1 insertion(+) commit ab58298cf459fcd4f588a401d36abf0bd2215b51 Author: Vegard Nossum Date: Tue Jul 5 21:12:53 2016 +0200 net: fix decnet rtnexthop parsing dn_fib_count_nhs() could enter an infinite loop if nhp->rtnh_len == 0 (i.e. if userspace passes a malformed netlink message). Let's use the helpers from net/nexthop.h which take care of all this stuff. We can do exactly the same as e.g. fib_count_nexthops() and fib_get_nhs() from net/ipv4/fib_semantics.c. This fixes the softlockup for me. Cc: Thomas Graf Signed-off-by: Vegard Nossum Signed-off-by: David S. Miller net/decnet/dn_fib.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) commit 7e3fd813717693597daaa95dee875f4cb2d911ef Author: Lv Zheng Date: Tue Jul 5 19:18:07 2016 +0800 ACPI / debugger: Fix regression introduced by IS_ERR_VALUE() removal The FIFO unlocking mechanism in acpi_dbg has been broken by the following commit: Commit: 287980e49ffc0f6d911601e7e352a812ed27768e Subject: remove lots of IS_ERR_VALUE abuses It converted !IS_ERR_VALUE(ret) into !ret which was not entirely correct. Fix the regression by taking ret > 0 into account too as appropriate. Fixes: 287980e49ffc (remove lots of IS_ERR_VALUE abuses) Signed-off-by: Lv Zheng [ rjw: Simplifications, changelog & subject massage ] Signed-off-by: Rafael J. Wysocki drivers/acpi/acpi_dbg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 096cdc6f52225835ff503f987a0d68ef770bb78e Author: Dan Carpenter Date: Tue Jun 21 16:58:46 2016 +0300 platform/chrome: cros_ec_dev - double fetch bug in ioctl We verify "u_cmd.outsize" and "u_cmd.insize" but we need to make sure that those values have not changed between the two copy_from_user() calls. Otherwise it could lead to a buffer overflow. Additionally, cros_ec_cmd_xfer() can set s_cmd->insize to a lower value. We should use the new smaller value so we don't copy too much data to the user. Reported-by: Pengfei Wang Fixes: a841178445bb ('mfd: cros_ec: Use a zero-length array for command data') Signed-off-by: Dan Carpenter Reviewed-by: Kees Cook Tested-by: Gwendal Grignou Cc: # v4.2+ Signed-off-by: Olof Johansson drivers/platform/chrome/cros_ec_dev.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 217215041b9285af2193a755b56a8f3ed408bfe2 Author: Ben Skeggs Date: Wed Jul 6 06:50:36 2016 +1000 drm/nouveau/disp/sor/gf119: select correct sor when poking training pattern Fixes a regression caused by a stupid thinko from "disp/sor/gf119: both links use the same training register". Signed-off-by: Ben Skeggs Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/engine/disp/sorgf119.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 45209046c47b93fadf26dc59a9da724f387b9cf2 Author: Lv Zheng Date: Tue Jul 5 13:53:12 2016 +0800 ACPICA: Namespace: Fix namespace/interpreter lock ordering There is a lock order issue in acpi_load_tables(). The namespace lock is held before holding the interpreter lock. With ACPI_MUTEX_DEBUG enabled in the kernel, this is printed to the log during boot: [ 0.885699] ACPI Error: Invalid acquire order: Thread 405884224 owns [ACPI_MTX_Namespace], wants [ACPI_MTX_Interpreter] (20160422/utmutex-263) [ 0.885881] ACPI Error: Could not acquire AML Interpreter mutex (20160422/exutils-95) [ 0.893846] ACPI Error: Mutex [0x0] is not acquired, cannot release (20160422/utmutex-326) [ 0.894019] ACPI Error: Could not release AML Interpreter mutex (20160422/exutils-133) The issue has been introduced by the following commit: Commit: 2f38b1b16d9280689e5cfa47a4c50956bf437f0d ACPICA Commit: bfe03ffcde8ed56a7eae38ea0b188aeb12f9c52e Subject: ACPICA: Namespace: Fix a regression that MLC support triggers dead lock in dynamic table loading Which fixed a deadlock issue for acpi_ns_load_table() in acpi_ex_add_table() but didn't take care of the lock order in acpi_ns_load_table() correctly. Originally (before the above commit), ACPICA used the namespace/interpreter locks in the following 2 key code paths: 1. Table loading: acpi_ns_load_table L(Namespace) acpi_ns_parse_table acpi_ns_one_complete_parse U(Namespace) 2. Object evaluation: acpi_ns_evaluate L(Interpreter) acpi_ps_execute_method U(Interpreter) acpi_ns_load_table L(Namespace) U(Namespace) acpi_ev_initialize_region L(Namespace) U(Namespace) address_space.setup L(Namespace) U(Namespace) address_space.handler L(Namespace) U(Namespace) acpi_os_wait_semaphore acpi_os_acquire_mutex acpi_os_sleep L(Interpreter) U(Interpreter) During runtime, while acpi_ns_evaluate is called, the lock order is always Interpreter -> Namespace. In turn, the problematic commit acquires the locks in the following order: 3. Table loading: acpi_ns_load_table L(Namespace) acpi_ns_parse_table L(Interpreter) acpi_ns_one_complete_parse U(Interpreter) U(Namespace) To fix the lock order issue, move the interpreter lock to acpi_ns_load_table() to ensure the lock order correctness: 4. Table loading: acpi_ns_load_table L(Interpreter) L(Namespace) acpi_ns_parse_table acpi_ns_one_complete_parse U(Namespace) U(Interpreter) However, this doesn't fix the current design issues related to the namespace lock. For example, we can notice that in acpi_ns_evaluate(), outside of acpi_ns_load_table(), the namespace objects may be created by the named object creation control methods. And the creation of the method-owned namespace objects are not locked by the namespace lock. This patch doesn't try to fix such kind of existing issues. Fixes: 2f38b1b16d92 (ACPICA: Namespace: Fix a regression that MLC support triggers dead lock in dynamic table loading) Signed-off-by: Lv Zheng Signed-off-by: Rafael J. Wysocki drivers/acpi/acpica/nsload.c | 7 ++++++- drivers/acpi/acpica/nsparse.c | 9 ++------- 2 files changed, 8 insertions(+), 8 deletions(-) commit c94c09535c4debcc439f55b5b6d9ebe57bd4665a Author: Al Viro Date: Tue Jul 5 09:49:21 2016 -0400 nfs_atomic_open(): prevent parallel nfs_lookup() on a negative hashed Signed-off-by: Al Viro fs/nfs/dir.c | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) commit 00699ad8571afd7fb8bc2c61f67c86c2428680ab Author: Al Viro Date: Tue Jul 5 09:44:53 2016 -0400 Use the right predicate in ->atomic_open() instances ->atomic_open() can be given an in-lookup dentry *or* a negative one found in dcache. Use d_in_lookup() to tell one from another, rather than d_unhashed(). Signed-off-by: Al Viro fs/9p/vfs_inode.c | 2 +- fs/9p/vfs_inode_dotl.c | 2 +- fs/ceph/file.c | 2 +- fs/cifs/dir.c | 2 +- fs/fuse/dir.c | 2 +- fs/gfs2/inode.c | 2 +- fs/nfs/dir.c | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) commit 262e2bfd7d1e1f1ee48b870e5dfabb87c06b975e Author: Bruno Prémont Date: Thu Jun 30 17:00:32 2016 +0200 qla2xxx: Fix NULL pointer deref in QLA interrupt In qla24xx_process_response_queue() rsp->msix->cpuid may trigger NULL pointer dereference when rsp->msix is NULL: [ 5.622457] NULL pointer dereference at 0000000000000050 [ 5.622457] IP: [] qla24xx_process_response_queue+0x44/0x4b0 [ 5.622457] PGD 0 [ 5.622457] Oops: 0000 [#1] SMP [ 5.622457] Modules linked in: [ 5.622457] CPU: 2 PID: 0 Comm: swapper/2 Not tainted 4.6.3-x86_64 #1 [ 5.622457] Hardware name: HP ProLiant DL360 G5, BIOS P58 05/02/2011 [ 5.622457] task: ffff8801a88f3740 ti: ffff8801a8954000 task.ti: ffff8801a8954000 [ 5.622457] RIP: 0010:[] [] qla24xx_process_response_queue+0x44/0x4b0 [ 5.622457] RSP: 0000:ffff8801afb03de8 EFLAGS: 00010002 [ 5.622457] RAX: 0000000000000000 RBX: 0000000000000032 RCX: 00000000ffffffff [ 5.622457] RDX: 0000000000000002 RSI: ffff8801a79bf8c8 RDI: ffff8800c8f7e7c0 [ 5.622457] RBP: ffff8801afb03e68 R08: 0000000000000000 R09: 0000000000000000 [ 5.622457] R10: 00000000ffff8c47 R11: 0000000000000002 R12: ffff8801a79bf8c8 [ 5.622457] R13: ffff8800c8f7e7c0 R14: ffff8800c8f60000 R15: 0000000000018013 [ 5.622457] FS: 0000000000000000(0000) GS:ffff8801afb00000(0000) knlGS:0000000000000000 [ 5.622457] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 5.622457] CR2: 0000000000000050 CR3: 0000000001e07000 CR4: 00000000000006e0 [ 5.622457] Stack: [ 5.622457] ffff8801afb03e30 ffffffff810c0f2d 0000000000000086 0000000000000002 [ 5.622457] ffff8801afb03e28 ffffffff816570e1 ffff8800c8994628 0000000000000002 [ 5.622457] ffff8801afb03e60 ffffffff816772d4 b47c472ad6955e68 0000000000000032 [ 5.622457] Call Trace: [ 5.622457] [ 5.622457] [] ? __wake_up_common+0x4d/0x80 [ 5.622457] [] ? usb_hcd_resume_root_hub+0x51/0x60 [ 5.622457] [] ? uhci_hub_status_data+0x64/0x240 [ 5.622457] [] qla24xx_intr_handler+0xf0/0x2e0 [ 5.622457] [] ? get_next_timer_interrupt+0xce/0x200 [ 5.622457] [] handle_irq_event_percpu+0x64/0x100 [ 5.622457] [] handle_irq_event+0x27/0x50 [ 5.622457] [] handle_edge_irq+0x65/0x140 [ 5.622457] [] handle_irq+0x18/0x30 [ 5.622457] [] do_IRQ+0x46/0xd0 [ 5.622457] [] common_interrupt+0x7f/0x7f [ 5.622457] [ 5.622457] [] ? mwait_idle+0x68/0x80 [ 5.622457] [] arch_cpu_idle+0xa/0x10 [ 5.622457] [] default_idle_call+0x27/0x30 [ 5.622457] [] cpu_startup_entry+0x19b/0x230 [ 5.622457] [] start_secondary+0x136/0x140 [ 5.622457] Code: 00 00 65 48 8b 04 25 28 00 00 00 48 89 45 d0 31 c0 48 8b 47 58 a8 02 0f 84 c5 00 00 00 48 8b 46 50 49 89 f4 65 8b 15 34 bb aa 7e <39> 50 50 74 11 89 50 50 48 8b 46 50 8b 40 50 41 89 86 60 8b 00 [ 5.622457] RIP [] qla24xx_process_response_queue+0x44/0x4b0 [ 5.622457] RSP [ 5.622457] CR2: 0000000000000050 [ 5.622457] ---[ end trace fa2b19c25106d42b ]--- [ 5.622457] Kernel panic - not syncing: Fatal exception in interrupt The affected code was introduced by commit cdb898c52d1dfad4b4800b83a58b3fe5d352edde (qla2xxx: Add irq affinity notification). Only dereference rsp->msix when it has been set so the machine can boot fine. Possibly rsp->msix is unset because: [ 3.479679] qla2xxx [0000:00:00.0]-0005: : QLogic Fibre Channel HBA Driver: 8.07.00.33-k. [ 3.481839] qla2xxx [0000:13:00.0]-001d: : Found an ISP2432 irq 17 iobase 0xffffc90000038000. [ 3.484081] qla2xxx [0000:13:00.0]-0035:0: MSI-X; Unsupported ISP2432 (0x2, 0x3). [ 3.485804] qla2xxx [0000:13:00.0]-0037:0: Falling back-to MSI mode -258. [ 3.890145] scsi host0: qla2xxx [ 3.891956] qla2xxx [0000:13:00.0]-00fb:0: QLogic QLE2460 - PCI-Express Single Channel 4Gb Fibre Channel HBA. [ 3.894207] qla2xxx [0000:13:00.0]-00fc:0: ISP2432: PCIe (2.5GT/s x4) @ 0000:13:00.0 hdma+ host#=0 fw=7.03.00 (9496). [ 5.714774] qla2xxx [0000:13:00.0]-500a:0: LOOP UP detected (4 Gbps). Signed-off-by: Bruno Prémont Acked-by: Quinn Tran CC: # 4.5+ Fixes: cdb898c52d1dfad4b4800b83a58b3fe5d352edde Signed-off-by: James Bottomley drivers/scsi/qla2xxx/qla_isr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f5d6516120ee5c777fb7b1ba9d39031881ad511b Author: Ganesh Goudar Date: Tue Jul 5 18:07:24 2016 +0530 cxgb4: update latest firmware version supported Change t4fw_version.h to update latest firmware version number Signed-off-by: Ganesh Goudar Signed-off-by: David S. Miller drivers/net/ethernet/chelsio/cxgb4/t4fw_version.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit eae033c1b86721ec54511607fc26bfb94a0e004b Author: Or Gerlitz Date: Tue Jul 5 12:17:12 2016 +0300 net/mlx5: Avoid setting unused var when modifying vport node GUID GCC complains on unused-but-set-variable, clean this up. Fixes: 23898c763f4a ('net/mlx5: E-Switch, Modify node guid on vf set MAC') Signed-off-by: Or Gerlitz Acked-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/vport.c | 3 --- 1 file changed, 3 deletions(-) commit a30b016808e214c6864ad579ef867b3fe0a314f8 Author: Aviv Heller Date: Tue Jul 5 12:09:47 2016 +0300 bonding: fix enslavement slave link notifications Currently, link notifications are not sent by bond_set_slave_link_state() upon enslavement if the slave is enslaved when up. This happens because slave->link default init value is 0, which is the same as BOND_LINK_UP, resulting in bond_set_slave_link_state() ignoring this transition. This patch sets the default value of slave->link to BOND_LINK_NOCHANGE, assuring it will count as a state transition and thus trigger notification logic. Signed-off-by: Aviv Heller Reviewed-by: Jiri Pirko Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/bonding/bond_main.c | 1 + 1 file changed, 1 insertion(+) commit 2609af19362d03332b55fc7836e7023bcd6d90bf Author: hayeswang Date: Tue Jul 5 16:11:46 2016 +0800 r8152: fix runtime function for RTL8152 The RTL8152 doesn't have U1U2 and U2P3 features, so use different runtime functions for RTL812 and RTL8153 by adding autosuspend_en() to rtl_ops. Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) commit 92c74bceb0dd4b74a6c0b56c2f9a5c93a0860808 Author: Linus Walleij Date: Tue Jul 5 08:46:43 2016 +0200 Revert "gpio: gpiolib-of: Allow compile testing" This reverts commit 1e4a80640338924b9f9fd7a121ac31d08134410a. This creates more problems than it solves right now. Compile testing needs to go in with patches fixing the problems it uncovers. Signed-off-by: Linus Walleij drivers/gpio/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 22ebf00eb56fe77922de8138aa9af9996582c2b3 Author: Lukasz Gemborowski Date: Mon Jun 27 12:57:47 2016 +0200 i2c: mux: reg: wrong condition checked for of_address_to_resource return value of_address_to_resource return 0 on successful call but devm_ioremap_resource is called only if it returns non-zero value Signed-off-by: Lukasz Gemborowski Reviewed-by: Alexander Sverdlin Signed-off-by: Wolfram Sang Cc: stable@kernel.org drivers/i2c/muxes/i2c-mux-reg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eab09988e47f2b4322faa5ee1430d05714e59000 Author: Jon Hunter Date: Tue Jun 14 21:26:46 2016 +0100 i2c: tegra: Correct error path in probe Commit 497fbe24987b ("i2c: tegra: enable multi master mode for tegra210") enables the Tegra I2C 'div_clk' for adapters using the multi-master mode during the device probe. Although the probe error path was updated to disable the clock on probe failure, there is one place after calling tegra_i2c_init() where the clock will not be disabled on failure. Correct the error path so that the 'div_clk' is disabled if calling tegra_i2c_init() fails. Fixes: 497fbe24987b ("i2c: tegra: enable multi master mode for tegra210") Signed-off-by: Jon Hunter Acked-by: Laxman Dewangan Signed-off-by: Wolfram Sang drivers/i2c/busses/i2c-tegra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 547aefc4db877e65245c3d95fcce703701bf3a0c Author: Paul Burton Date: Tue Jul 5 14:26:00 2016 +0100 irqchip/mips-gic: Match IPI IRQ domain by bus token only Commit fbde2d7d8290 ("MIPS: Add generic SMP IPI support") introduced code which calls irq_find_matching_host with a NULL node parameter in order to discover IPI IRQ domains which are not associated with the DT root node's interrupt parent. This suggests that implementations of IPI IRQ domains should effectively ignore the node parameter if it is NULL and search purely based upon the bus token. Commit 2af70a962070 ("irqchip/mips-gic: Add a IPI hierarchy domain") did not do this when implementing the GIC IPI IRQ domain, and on MIPS Boston boards this leads to no IPI domain being discovered and a NULL pointer dereference when attempting to send an IPI: CPU 0 Unable to handle kernel paging request at virtual address 0000000000000040, epc == ffffffff8016e70c, ra == ffffffff8010ff5c Oops[#1]: CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.7.0-rc6-00223-gad0d1b6 #945 task: a8000000ff066fc0 ti: a8000000ff068000 task.ti: a8000000ff068000 $ 0 : 0000000000000000 0000000000000001 ffffffff80730000 0000000000000003 $ 4 : 0000000000000000 ffffffff8057e5b0 a800000001e3ee00 0000000000000000 $ 8 : 0000000000000000 0000000000000023 0000000000000001 0000000000000001 $12 : 0000000000000000 ffffffff803323d0 0000000000000000 0000000000000000 $16 : 0000000000000000 0000000000000000 0000000000000001 ffffffff801108fc $20 : 0000000000000000 ffffffff8057e5b0 0000000000000001 0000000000000000 $24 : 0000000000000000 ffffffff8012de28 $28 : a8000000ff068000 a8000000ff06fbc0 0000000000000000 ffffffff8010ff5c Hi : ffffffff8014c174 Lo : a800000001e1e140 epc : ffffffff8016e70c __ipi_send_mask+0x24/0x11c ra : ffffffff8010ff5c mips_smp_send_ipi_mask+0x68/0x178 Status: 140084e2 KX SX UX KERNEL EXL Cause : 00800008 (ExcCode 02) BadVA : 0000000000000040 PrId : 0001a920 (MIPS I6400) Process swapper/0 (pid: 1, threadinfo=a8000000ff068000, task=a8000000ff066fc0, tls=0000000000000000) Stack : 0000000000000000 0000000000000000 0000000000000001 ffffffff801108fc 0000000000000000 ffffffff8057e5b0 0000000000000001 ffffffff8010ff5c 0000000000000001 0000000000000020 0000000000000000 0000000000000000 0000000000000000 ffffffff801108fc 0000000000000000 0000000000000001 0000000000000001 0000000000000000 0000000000000000 ffffffff801865e8 a8000000ff0c7500 a8000000ff06fc90 0000000000000001 0000000000000002 ffffffff801108fc ffffffff801868b8 0000000000000000 ffffffff801108fc 0000000000000000 0000000000000003 ffffffff8068c700 0000000000000001 ffffffff80730000 0000000000000001 a8000000ff00a290 ffffffff80110c50 0000000000000003 a800000001e48308 0000000000000003 0000000000000008 ... Call Trace: [] __ipi_send_mask+0x24/0x11c [] mips_smp_send_ipi_mask+0x68/0x178 [] generic_exec_single+0x150/0x170 [] smp_call_function_single+0x108/0x160 [] cps_boot_secondary+0x328/0x394 [] __cpu_up+0x38/0x90 [] bringup_cpu+0x24/0xac [] cpuhp_up_callbacks+0x58/0xdc [] cpu_up+0x118/0x18c [] smp_init+0xbc/0xe8 [] kernel_init_freeable+0xa0/0x228 [] kernel_init+0x10/0xf0 [] ret_from_kernel_thread+0x14/0x1c Fix this by allowing the GIC IPI IRQ domain to match purely based upon the bus token if the node provided is NULL. Fixes: 2af70a962070 ("irqchip/mips-gic: Add a IPI hierarchy domain") Signed-off-by: Paul Burton Cc: linux-mips@linux-mips.org Cc: Jason Cooper Cc: Qais Yousef Cc: Ralf Baechle Cc: Marc Zyngier Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/20160705132600.27730-2-paul.burton@imgtec.com Signed-off-by: Thomas Gleixner drivers/irqchip/irq-mips-gic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 99ec8a3608330d202448085185cf28389b789b7b Author: Paul Burton Date: Tue Jul 5 14:25:59 2016 +0100 irqchip/mips-gic: Map to VPs using HW VPNum When mapping an interrupt to a VP(E) we must use the identifier for the VP that the hardware expects, and this does not always match up with the Linux CPU number. Commit d46812bb0bef ("irqchip: mips-gic: Use HW IDs for VPE_OTHER_ADDR") corrected this for the cases that existed at the time it was written, but commit 2af70a962070 ("irqchip/mips-gic: Add a IPI hierarchy domain") added another case before the former patch was merged. This leads to incorrectly using Linux CPU numbers when mapping interrupts to VPs, which breaks on certain systems such as those with multi-core I6400 CPUs. Fix by adding the appropriate call to mips_cm_vp_id() to retrieve the expected VP identifier. Fixes: d46812bb0bef ("irqchip: mips-gic: Use HW IDs for VPE_OTHER_ADDR") Fixes: 2af70a962070 ("irqchip/mips-gic: Add a IPI hierarchy domain") Signed-off-by: Paul Burton Cc: linux-mips@linux-mips.org Cc: Jason Cooper Cc: Qais Yousef Cc: Ralf Baechle Cc: Marc Zyngier Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/20160705132600.27730-1-paul.burton@imgtec.com Signed-off-by: Thomas Gleixner drivers/irqchip/irq-mips-gic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3867b228d6aed0e916d8d36119b465cb1946bb32 Author: Maxime Coquelin Date: Fri Jul 1 15:19:56 2016 +0200 MAINTAINERS: update STi maintainer list Remove myself as STi maintainer as I will no longer have access to STi platforms, and remove Srini too, who now works on other platforms. Patrice will manage the pull requests. Signed-off-by: Maxime Coquelin Cc: Patrice Chotard Cc: Srinivas Kandagatla Cc: Arnd Bergmann Acked-by: Patrice Chotard Acked-by: Srinivas Kandagatla Signed-off-by: Arnd Bergmann MAINTAINERS | 2 -- 1 file changed, 2 deletions(-) commit 8ca2cf2c8e0d172824ac305391fb4273dd1e3e5a Author: Maxime Coquelin Date: Wed Jun 22 15:56:58 2016 +0200 MAINTAINERS: update STM32 maintainers list I will have less time to work on STM32 platform, so I propose Alexandre as co-maintainer. Alex is working in the STMicroelectronics division in charge of STM32 family, so he will have access to all technical information and hardware. Signed-off-by: Maxime Coquelin Cc: Alexandre Torgue Signed-off-by: Arnd Bergmann MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 86545b94376f445a3646227f0d433bec5e00499b Merge: 600da64 b44439e Author: Arnd Bergmann Date: Tue Jul 5 15:56:33 2016 +0200 Merge tag 'mvebu-fixes-4.7-2' of git://git.infradead.org/linux-mvebu into fixes Pull "mvebu fixes for 4.7 (part 2)" from Gregory CLEMENT: Fix a regression introduced by a cleanup on kirkwood_pm_init * tag 'mvebu-fixes-4.7-2' of git://git.infradead.org/linux-mvebu: ARM: mvebu: compile pm code conditionally commit 600da64b771af45e40018500cd510b0c570130aa Merge: ed749a5 eee25ab Author: Arnd Bergmann Date: Tue Jul 5 15:55:12 2016 +0200 Merge tag 'sunxi-fixes-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into fixes Pull "Allwinner Fixes for 4.7" from Maxime Ripard: Two patches fixing simplefb on the SoCs that had their display clocks enabled, and one fix for the CHIP that will enable its sched clock. * tag 'sunxi-fixes-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: ARM: dts: sun7i: Fix pll3x2 and pll7x2 not having a parent clock ARM: dts: sunxi: Add pll3 to simplefb nodes clocks lists ARM: sunxi/dt: make the CHIP inherit from allwinner,sun5i-a13 commit cbef1e102003edb236c6b2319ab269ccef963731 Author: Sven Eckelmann Date: Thu Jun 30 21:41:13 2016 +0200 batman-adv: Free last_bonding_candidate on release of orig_node The orig_ifinfo reference counter for last_bonding_candidate in batadv_orig_node has to be reduced when an originator node is released. Otherwise the orig_ifinfo is leaked and the reference counter the netdevice is not reduced correctly. Fixes: f3b3d9018975 ("batman-adv: add bonding again") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/originator.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 15c2ed753cd9e3e746472deab8151337a5b6da56 Author: Sven Eckelmann Date: Thu Jun 30 20:11:34 2016 +0200 batman-adv: Fix reference leak in batadv_find_router The replacement of last_bonding_candidate in batadv_orig_node has to be an atomic operation. Otherwise it is possible that the reference counter of a batadv_orig_ifinfo is reduced which was no longer the last_bonding_candidate when the new candidate is added. This can either lead to an invalid memory access or to reference leaks which make it impossible to an interface which was added to batman-adv. Fixes: f3b3d9018975 ("batman-adv: add bonding again") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/routing.c | 52 ++++++++++++++++++++++++++++++++++++------------ net/batman-adv/types.h | 4 +++- 2 files changed, 42 insertions(+), 14 deletions(-) commit 3db0decf1185357d6ab2256d0dede1ca9efda03d Author: Sven Eckelmann Date: Fri Jul 1 15:49:43 2016 +0200 batman-adv: Fix non-atomic bla_claim::backbone_gw access The pointer batadv_bla_claim::backbone_gw can be changed at any time. Therefore, access to it must be protected to ensure that two function accessing the same backbone_gw are actually accessing the same. This is especially important when the crc_lock is used or when the backbone_gw of a claim is exchanged. Not doing so leads to invalid memory access and/or reference leaks. Fixes: 23721387c409 ("batman-adv: add basic bridge loop avoidance code") Fixes: 5a1dd8a4773d ("batman-adv: lock crc access in bridge loop avoidance") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/bridge_loop_avoidance.c | 111 ++++++++++++++++++++++++++------- net/batman-adv/types.h | 2 + 2 files changed, 90 insertions(+), 23 deletions(-) commit 33fbb1f3db87ce53da925b3e034b4dd446d483f8 Author: Sven Eckelmann Date: Thu Jun 30 20:10:46 2016 +0200 batman-adv: Fix orig_node_vlan leak on orig_node_release batadv_orig_node_new uses batadv_orig_node_vlan_new to allocate a new batadv_orig_node_vlan and add it to batadv_orig_node::vlan_list. References to this list have also to be cleaned when the batadv_orig_node is removed. Fixes: 7ea7b4a14275 ("batman-adv: make the TT CRC logic VLAN specific") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/originator.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 60154a1e0495ffb8343a95cefe1e874634572fa8 Author: Sven Eckelmann Date: Sat Jul 2 09:52:14 2016 +0200 batman-adv: Avoid nullptr dereference in dat after vlan_insert_tag vlan_insert_tag can return NULL on errors. The distributed arp table code therefore has to check the return value of vlan_insert_tag for NULL before it can safely operate on this pointer. Fixes: be1db4f6615b ("batman-adv: make the Distributed ARP Table vlan aware") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/distributed-arp-table.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 10c78f5854d361ded4736c1831948e0a5f67b932 Author: Sven Eckelmann Date: Sat Jul 2 09:52:13 2016 +0200 batman-adv: Avoid nullptr dereference in bla after vlan_insert_tag vlan_insert_tag can return NULL on errors. The bridge loop avoidance code therefore has to check the return value of vlan_insert_tag for NULL before it can safely operate on this pointer. Fixes: 23721387c409 ("batman-adv: add basic bridge loop avoidance code") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: Simon Wunderlich net/batman-adv/bridge_loop_avoidance.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 9cd25743765cfe851aed8d655a62d60156aed293 Author: Torsten Hilbrich Date: Tue Jul 5 10:40:22 2016 +0200 ALSA: hda/realtek: Add Lenovo L460 to docking unit fixup This solves the issue that a headphone is not working on the docking unit. Signed-off-by: Torsten Hilbrich Cc: Signed-off-by: Takashi Iwai sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+) commit 3b8e64f6f8e2d437b15572f445b1932a45f9be6a Author: Peter Chen Date: Tue Jul 5 10:04:53 2016 +0800 gpu: drm: sun4i_drv: add missing of_node_put after calling of_parse_phandle of_node_put needs to be called when the device node which is got from of_parse_phandle has finished using. Cc: Maxime Ripard Cc: Chen-Yu Tsai Signed-off-by: Peter Chen Signed-off-by: Maxime Ripard drivers/gpu/drm/sun4i/sun4i_drv.c | 1 + 1 file changed, 1 insertion(+) commit 7831b4ff0d926e0deeaabef9db8800ed069a2757 Author: Ursula Braun Date: Mon Jul 4 14:07:16 2016 +0200 qeth: delete napi struct when removing a qeth device A qeth_card contains a napi_struct linked to the net_device during device probing. This struct must be deleted when removing the qeth device, otherwise Panic on oops can occur when qeth devices are repeatedly removed and added. Fixes: a1c3ed4c9ca ("qeth: NAPI support for l2 and l3 discipline") Cc: stable@vger.kernel.org # v2.6.37+ Signed-off-by: Ursula Braun Tested-by: Alexander Klein Signed-off-by: David S. Miller drivers/s390/net/qeth_l2_main.c | 1 + drivers/s390/net/qeth_l3_main.c | 1 + 2 files changed, 2 insertions(+) commit c8e2ca30fdba613c088ab2fd5ac7b9c69b402559 Author: David S. Miller Date: Mon Jul 4 17:16:41 2016 -0700 Revert "fsl/fman: fix error handling" This reverts commit a788a4a040e003574b8ad17115706ab1601ec572. This patch is wrong, the type returned doesn't fit what the error pointer macros expect. Signed-off-by: David S. Miller drivers/net/ethernet/freescale/fman/fman.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a788a4a040e003574b8ad17115706ab1601ec572 Author: Christophe Jaillet Date: Mon Jul 4 07:46:42 2016 +0200 fsl/fman: fix error handling This is likely that checking 'fman->fifo_offset' instead of 'fman->cam_offset' is expected here. Signed-off-by: Christophe JAILLET Signed-off-by: David S. Miller drivers/net/ethernet/freescale/fman/fman.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c086e7096170390594c425114d98172bc9aceb8a Author: Bjørn Mork Date: Sun Jul 3 22:24:50 2016 +0200 cdc_ncm: workaround for EM7455 "silent" data interface Several Lenovo users have reported problems with their Sierra Wireless EM7455 modem. The driver has loaded successfully and the MBIM management channel has appeared to work, including establishing a connection to the mobile network. But no frames have been received over the data interface. The problem affects all EM7455 and MC7455, and is assumed to affect other modems based on the same Qualcomm chipset and baseband firmware. Testing narrowed the problem down to what seems to be a firmware timing bug during initialization. Adding a short sleep while probing is sufficient to make the problem disappear. Experiments have shown that 1-2 ms is too little to have any effect, while 10-20 ms is enough to reliably succeed. Reported-by: Stefan Armbruster Reported-by: Ralph Plawetzki Reported-by: Andreas Fett Reported-by: Rasmus Lerdorf Reported-by: Samo Ratnik Reported-and-tested-by: Aleksander Morgado Signed-off-by: Bjørn Mork Signed-off-by: David S. Miller drivers/net/usb/cdc_ncm.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 3dad5424adfb346c871847d467f97dcdca64ea97 Author: Vegard Nossum Date: Sun Jul 3 10:54:54 2016 +0200 RDS: fix rds_tcp_init() error path If register_pernet_subsys() fails, we shouldn't try to call unregister_pernet_subsys(). Fixes: 467fa15356 ("RDS-TCP: Support multiple RDS-TCP listen endpoints, one per netns.") Cc: stable@vger.kernel.org Cc: Sowmini Varadhan Cc: David S. Miller Signed-off-by: Vegard Nossum Acked-by: Sowmini Varadhan Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/tcp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit d5d5e8d55732c7c35c354e45e3b0af2795978a57 Author: Haishuang Yan Date: Sat Jul 2 15:02:48 2016 +0800 geneve: fix max_mtu setting For ipv6+udp+geneve encapsulation data, the max_mtu should subtract sizeof(ipv6hdr), instead of sizeof(iphdr). Signed-off-by: Haishuang Yan Signed-off-by: David S. Miller drivers/net/geneve.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 85b03b3033fd4eba82665b3b9902c095a08cc52f Author: Johan Hovold Date: Sun Jul 3 18:32:05 2016 +0200 Revert "gpiolib: Split GPIO flags parsing and GPIO configuration" This reverts commit 923b93e451db876d1479d3e4458fce14fec31d1c. Make sure consumers do not overwrite gpio flags for pins that have already been claimed. While adding support for gpio drivers to refuse a request using unsupported flags, the order of when the requested flag was checked and the new flags were applied was reversed to that consumers could overwrite flags for already requested gpios. This not only affects device-tree setups where two drivers could request the same gpio using conflicting configurations, but also allowed user space to clear gpio flags for already claimed pins simply by attempting to export them through the sysfs interface. By for example clearing the FLAG_ACTIVE_LOW flag this way, user space could effectively change the polarity of a signal. Reverting this change obviously prevents gpio drivers from doing sanity checks on the flags in their request callbacks. Fortunately only one recently added driver (gpio-tps65218 in v4.6) appears to do this, and a follow up patch could restore this functionality through a different interface. Cc: stable # 4.4 Signed-off-by: Johan Hovold Signed-off-by: Linus Walleij drivers/gpio/gpiolib-legacy.c | 8 +++---- drivers/gpio/gpiolib.c | 52 +++++++++++++------------------------------ 2 files changed, 20 insertions(+), 40 deletions(-) commit 87041a58d3b19455d39baed2a5e5bb43b58fb915 Author: Colin Pitrat Date: Sat Jun 18 19:05:04 2016 +0100 gpio: sch: Fix Oops on module load on Asus Eee PC 1201 This fixes the issue descirbe in bug 117531 (https://bugzilla.kernel.org/show_bug.cgi?id=117531). It's a regression introduced in linux 4.5 that causes a Oops at load of gpio_sch and prevents powering off the computer. The issue is that sch_gpio_reg_set is called in sch_gpio_probe before gpio_chip data is initialized with the pointer to the sch_gpio struct. As sch_gpio_reg_set calls gpiochip_get_data, it returns NULL which causes the Oops. The patch follows Mika's advice (https://lkml.org/lkml/2016/5/9/61) and consists in modifying sch_gpio_reg_get and sch_gpio_reg_set to take a sch_gpio struct directly instead of a gpio_chip, which avoids the call to gpiochip_get_data. Thanks Mika for your patience with me :-) Cc: stable@vger.kernel.org Signed-off-by: Colin Pitrat Acked-by: Alexandre Courbot Acked-by: Mika Westerberg Signed-off-by: Linus Walleij drivers/gpio/gpio-sch.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit 07a2daab49c549a37b5b744cbebb6e3f445f12bc Author: Vivek Goyal Date: Fri Jul 1 16:34:25 2016 -0400 ovl: Copy up underlying inode's ->i_mode to overlay inode Right now when a new overlay inode is created, we initialize overlay inode's ->i_mode from underlying inode ->i_mode but we retain only file type bits (S_IFMT) and discard permission bits. This patch changes it and retains permission bits too. This should allow overlay to do permission checks on overlay inode itself in task context. [SzM] It also fixes clearing suid/sgid bits on write. Signed-off-by: Vivek Goyal Reported-by: Eryu Guan Signed-off-by: Miklos Szeredi Fixes: 4bacc9c9234c ("overlayfs: Make f_path always point to the overlay and f_inode to the underlay") Cc: fs/overlayfs/inode.c | 3 +-- fs/overlayfs/overlayfs.h | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) commit b99c2d913810e56682a538c9f2394d76fca808f8 Author: Miklos Szeredi Date: Mon Jul 4 16:49:48 2016 +0200 ovl: handle ATTR_KILL* Before 4bacc9c9234c ("overlayfs: Make f_path...") file->f_path pointed to the underlying file, hence suid/sgid removal on write worked fine. After that patch file->f_path pointed to the overlay file, and the file mode bits weren't copied to overlay_inode->i_mode. So the suid/sgid removal simply stopped working. The fix is to copy the mode bits, but then ovl_setattr() needs to clear ATTR_MODE to avoid the BUG() in notify_change(). So do this first, then in the next patch copy the mode. Reported-by: Eryu Guan Signed-off-by: Miklos Szeredi Fixes: 4bacc9c9234c ("overlayfs: Make f_path always point to the overlay and f_inode to the underlay") Cc: fs/overlayfs/inode.c | 3 +++ 1 file changed, 3 insertions(+) commit dbd1b8ea43b17e2ed4acda72f83ea17f69408682 Author: Shreyas B. Prabhu Date: Fri Jul 1 09:24:14 2016 -0500 cpuidle: Fix last_residency division Snooze is a poll idle state in powernv and pseries platforms. Snooze has a timeout so that if a CPU stays in snooze for more than target residency of the next available idle state, then it would exit thereby giving chance to the cpuidle governor to re-evaluate and promote the CPU to a deeper idle state. Therefore whenever snooze exits due to this timeout, its last_residency will be target_residency of the next deeper state. Commit e93e59ce5b85 "cpuidle: Replace ktime_get() with local_clock()" changed the math around last_residency calculation. Specifically, while converting last_residency value from nano- to microseconds, it carries out right shift by 10. Because of that, in snooze timeout exit scenarios last_residency calculated is roughly 2.3% less than target_residency of the next available state. This pattern is picked up by get_typical_interval() in the menu governor and therefore expected_interval in menu_select() is frequently less than the target_residency of any state other than snooze. Due to this we are entering snooze at a higher rate, thereby affecting the single thread performance. Fix this by using more precise division via ktime_us_delta(). Fixes: e93e59ce5b85 "cpuidle: Replace ktime_get() with local_clock()" Reported-by: Anton Blanchard Bisected-by: Shilpasri G Bhat Signed-off-by: Shreyas B. Prabhu Acked-by: Daniel Lezcano Acked-by: Balbir Singh Signed-off-by: Rafael J. Wysocki drivers/cpuidle/cpuidle.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 3fa6993fef634e05d200d141a85df0b044572364 Author: Takashi Iwai Date: Mon Jul 4 14:02:15 2016 +0200 ALSA: timer: Fix negative queue usage by racy accesses The user timer tu->qused counter may go to a negative value when multiple concurrent reads are performed since both the check and the decrement of tu->qused are done in two individual locked contexts. This results in bogus read outs, and the endless loop in the user-space side. The fix is to move the decrement of the tu->qused counter into the same spinlock context as the zero-check of the counter. Cc: Signed-off-by: Takashi Iwai sound/core/timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0caa7616a6aca449dd68b58cb29bd491d296c2d5 Author: Aaron Campbell Date: Sat Jul 2 21:23:24 2016 -0300 iommu/vt-d: Fix infinite loop in free_all_cpu_cached_iovas Per VT-d spec Section 10.4.2 ("Capability Register"), the maximum number of possible domains is 64K; indeed this is the maximum value that the cap_ndoms() macro will expand to. Since the value 65536 will not fix in a u16, the 'did' variable must be promoted to an int, otherwise the test for < 65536 will always be true and the loop will never end. The symptom, in my case, was a hung machine during suspend. Fixes: 3bd4f9112f87 ("iommu/vt-d: Fix overflow of iommu->domains array") Signed-off-by: Aaron Campbell Signed-off-by: Joerg Roedel drivers/iommu/intel-iommu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a99cde438de0c4c0cecc1d1af1a55a75b10bfdef Author: Linus Torvalds Date: Sun Jul 3 23:01:00 2016 -0700 Linux 4.7-rc6 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0b295dd5b8eb755bc7b57220d93705994090e954 Merge: 236bfd8 5c672ab Author: Linus Torvalds Date: Sun Jul 3 12:02:00 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse Pull fuse fix from Miklos Szeredi: "This makes sure userspace filesystems are not broken by the parallel lookups and readdir feature" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: fuse: serialize dirops by default commit 236bfd8ed868edfc42a656682487683ade3fede4 Merge: 4f30292 e7c0b59 Author: Linus Torvalds Date: Sun Jul 3 11:57:09 2016 -0700 Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs Pull overlayfs fixes from Miklos Szeredi: "This contains fixes for a dentry leak, a regression in 4.6 noticed by Docker users and missing write access checking in truncate" * 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs: ovl: warn instead of error if d_type is not supported ovl: get_write_access() in truncate ovl: fix dentry leak for default_permissions commit 86a8280a7fe007d61b05fa8a352edc0595283dad Author: Andrea Gelmini Date: Sat May 21 13:57:20 2016 +0200 m68k: Assorted spelling fixes - s/acccess/access/ - s/accoding/according/ - s/addad/added/ - s/addreess/address/ - s/allocatiom/allocation/ - s/Assember/Assembler/ - s/compactnes/compactness/ - s/conneced/connected/ - s/decending/descending/ - s/diectly/directly/ - s/diplacement/displacement/ Signed-off-by: Andrea Gelmini [geert: Squashed, fix arch/m68k/ifpsp060/src/pfpsp.S] Signed-off-by: Geert Uytterhoeven arch/m68k/coldfire/head.S | 2 +- arch/m68k/coldfire/m5272.c | 2 +- arch/m68k/coldfire/pci.c | 2 +- arch/m68k/ifpsp060/src/fpsp.S | 8 ++++---- arch/m68k/ifpsp060/src/pfpsp.S | 4 ++-- arch/m68k/include/asm/dma.h | 2 +- arch/m68k/include/asm/m525xsim.h | 4 ++-- arch/m68k/include/asm/mcfmmu.h | 2 +- arch/m68k/include/asm/q40_master.h | 2 +- arch/m68k/mac/iop.c | 2 +- arch/m68k/math-emu/fp_decode.h | 2 +- 11 files changed, 16 insertions(+), 16 deletions(-) commit fc18822510721fe694d273c5211c71ea52796d76 Author: Josh Poimboeuf Date: Fri Jul 1 23:02:05 2016 -0500 perf/x86: Fix 32-bit perf user callgraph collection A basic perf callgraph record operation causes an immediate panic on a 32-bit kernel compiled with CONFIG_CC_STACKPROTECTOR=y: $ perf record -g ls Kernel panic - not syncing: stack-protector: Kernel stack is corrupted in: c0404fbd CPU: 0 PID: 998 Comm: ls Not tainted 4.7.0-rc5+ #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.1-1.fc24 04/01/2014 c0dd5967 ff7afe1c 00000086 f41dbc2c c07445a0 464c457f f41dbca8 f41dbc44 c05646f4 f41dbca8 464c457f f41dbca8 464c457f f41dbc54 c04625be c0ce56fc c0404fbd f41dbc88 c0404fbd b74668f0 f41dc000 00000000 c0000000 00000000 Call Trace: [] dump_stack+0x58/0x78 [] panic+0x8e/0x1c6 [] __stack_chk_fail+0x1e/0x30 [] ? perf_callchain_user+0x22d/0x230 [] perf_callchain_user+0x22d/0x230 [] get_perf_callchain+0x1ff/0x270 [] perf_callchain+0x78/0x90 [] perf_prepare_sample+0x24b/0x370 [] perf_event_output_forward+0x24/0x70 [] __perf_event_overflow+0xa0/0x210 [] ? cpu_clock_event_read+0x43/0x50 [] perf_swevent_hrtimer+0x101/0x180 [] ? kmap_atomic_prot+0x35/0x140 [] ? get_page_from_freelist+0x279/0x950 [] ? vma_interval_tree_remove+0x158/0x230 [] ? wp_page_copy.isra.82+0x2f4/0x630 [] ? page_add_file_rmap+0x1d/0x50 [] ? unlock_page+0x61/0x80 [] ? filemap_map_pages+0x305/0x320 [] ? handle_mm_fault+0xb7f/0x1560 [] ? timerqueue_del+0x1b/0x70 [] ? __remove_hrtimer+0x2e/0x60 [] __hrtimer_run_queues+0xcb/0x2a0 [] ? __perf_event_overflow+0x210/0x210 [] hrtimer_interrupt+0x8a/0x180 [] local_apic_timer_interrupt+0x32/0x60 [] smp_apic_timer_interrupt+0x33/0x50 [] apic_timer_interrupt+0x34/0x3c Kernel Offset: disabled ---[ end Kernel panic - not syncing: stack-protector: Kernel stack is corrupted in: c0404fbd The panic is caused by the fact that perf_callchain_user() mistakenly assumes it's 64-bit only and ends up corrupting the stack. Signed-off-by: Josh Poimboeuf Cc: Alexander Shishkin Cc: Arnaldo Carvalho de Melo Cc: Arnaldo Carvalho de Melo Cc: Jiri Olsa Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Stephane Eranian Cc: Thomas Gleixner Cc: Vince Weaver Cc: stable@vger.kernel.org # v4.5+ Fixes: 75925e1ad7f5 ("perf/x86: Optimize stack walk user accesses") Link: http://lkml.kernel.org/r/1a547f5077ec30f75f9b57074837c3c80df86e5e.1467432113.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar arch/x86/events/core.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 9010ae4a8dee29e5886e86682799dde0eee7f447 Author: Stephane Eranian Date: Fri Jul 1 15:22:22 2016 -0700 perf/x86/intel: Update event constraints when HT is off This patch updates the event constraints for non-PEBS mode for Intel Broadwell and Skylake processors. When HT is off, each CPU gets 8 generic counters. However, not all events can be programmed on any of the 8 counters. This patch adds the constraints for the MEM_* events which can only be measured on the bottom 4 counters. The constraints are also valid when HT is off because, then, there are only 4 generic counters and they are the bottom counters. Signed-off-by: Stephane Eranian Cc: Alexander Shishkin Cc: Arnaldo Carvalho de Melo Cc: Jiri Olsa Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Vince Weaver Cc: kan.liang@intel.com Link: http://lkml.kernel.org/r/1467411742-13245-1-git-send-email-eranian@google.com Signed-off-by: Ingo Molnar arch/x86/events/intel/core.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit e7c0b5991dd1be7b6f6dc2b54a15a0f47b64b007 Author: Vivek Goyal Date: Fri Jul 1 10:02:44 2016 -0400 ovl: warn instead of error if d_type is not supported overlay needs underlying fs to support d_type. Recently I put in a patch in to detect this condition and started failing mount if underlying fs did not support d_type. But this breaks existing configurations over kernel upgrade. Those who are running docker (partially broken configuration) with xfs not supporting d_type, are surprised that after kernel upgrade docker does not run anymore. https://github.com/docker/docker/issues/22937#issuecomment-229881315 So instead of erroring out, detect broken configuration and warn about it. This should allow existing docker setups to continue working after kernel upgrade. Signed-off-by: Vivek Goyal Signed-off-by: Miklos Szeredi Fixes: 45aebeaf4f67 ("ovl: Ensure upper filesystem supports d_type") Cc: 4.6 fs/overlayfs/super.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 4f302921c1458d790ae21147f7043f4e6b6a1085 Merge: 70bd68d 6d037de Author: Linus Torvalds Date: Sat Jul 2 19:10:21 2016 -0700 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus Pull MIPS fix from Ralf Baechle: "Only a single fix for 4.7 pending at this point. It fixes an issue that may lead to corruption of the cache mode bits in the page table" * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: MIPS: Fix possible corruption of cache mode by mprotect. commit 70bd68d7f725b801d62566774d4770601998d03a Merge: 99b0f54 bfa3708 Author: Linus Torvalds Date: Sat Jul 2 17:47:54 2016 -0700 Merge tag 'powerpc-4.7-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from Michael Ellerman: - tm: Always reclaim in start_thread() for exec() class syscalls from Cyril Bur - tm: Avoid SLB faults in treclaim/trecheckpoint when RI=0 from Michael Neuling - eeh: Fix wrong argument passed to eeh_rmv_device() from Gavin Shan - Initialise pci_io_base as early as possible from Darren Stevens * tag 'powerpc-4.7-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc: Initialise pci_io_base as early as possible powerpc/tm: Avoid SLB faults in treclaim/trecheckpoint when RI=0 powerpc/eeh: Fix wrong argument passed to eeh_rmv_device() powerpc/tm: Always reclaim in start_thread() for exec() class syscalls commit b291c418172f2cfbe009d81cd9a92f7a2de7c579 Author: Stefan Hauser Date: Fri Jul 1 22:35:03 2016 +0200 net: phy: dp83867: Fix initialization of PHYCR register When initializing the PHY control register, the FIFO depth bits are written without reading the previous register value, i.e. all other bits are overwritten with zero. This disables automatic MDI-X configuration, which is enabled by default. Fix initialization by doing a read/modify/write operation. Signed-off-by: Stefan Hauser Reviewed-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/phy/dp83867.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) commit 373819ec391de0d11f63b10b2fb69ef2854236ca Author: Sergio Valverde Date: Fri Jul 1 11:44:30 2016 -0600 enc28j60: Fix race condition in enc28j60 driver The interrupt worker code for the enc28j60 relies only on the TXIF flag to determinate if the packet transmission was completed. However the datasheet specifies in section 12.1.3 that TXERIF will clear the TXRTS after a transmit abort. Also in section 12.1.4 that TXIF will be set when TXRTS transitions from '1' to '0'. Therefore the TXIF flag is enabled during transmission errors. This causes a race condition, since the worker code will invoke enc28j60_tx_clear() -> netif_wake_queue(), potentially invoking the ndo_start_xmit function to send a new packet. The enc28j60_send_packet function uses a workqueue that invokes enc28j60_hw_tx(). In between this function is called, the worker from the interrupt handler will enter the path for error handler because of the TXERIF flag, causing to invoke enc28j60_tx_clear() again and releasing the packet scheduled for transmission, causing a kernel crash with due a NULL pointer. These crashes due a NULL pointer were observed under stress conditions of the device. A BUG_ON() sequence was used to validate the issue was fixed, and has been running without problems for 2 years now. Signed-off-by: Diego Dompe Acked-by: Sergio Valverde Signed-off-by: David S. Miller drivers/net/ethernet/microchip/enc28j60.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit a8b7d7709dc6db7d6d8a9a04aa9d49b029a27203 Author: Matt Corallo Date: Thu Jun 30 19:46:16 2016 +0000 net: stmmac: Fix null-function call in ISR on stmmac1000 (resent due to overhelpful mail client corrupting patch) At least on Meson GXBB, the CORE_IRQ_MTL_RX_OVERFLOW interrupt is thrown with the stmmac1000 driver, which does not support set_rx_tail_ptr. With this patch and the clock fixes, 1G ethernet works on ODROID-C2. Signed-off-by: Matt Corallo Signed-off-by: David S. Miller drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 99b0f54e6a3a4012aacfaada5644a8e520447d80 Merge: 467ce76 88c0871 Author: Linus Torvalds Date: Sat Jul 2 09:41:28 2016 -0700 Merge tag 'drm-fixes-for-v4.7-rc6' of git://people.freedesktop.org/~airlied/linux Pull drm fixes frlm Dave Airlie: "Just some AMD and Intel fixes, the AMD ones are further production Polaris fixes, and the Intel ones fix some early timeouts, some PCI ID changes and a couple of other fixes. Still a bit Internet challenged here, hopefully end of next week will solve it" * tag 'drm-fixes-for-v4.7-rc6' of git://people.freedesktop.org/~airlied/linux: drm/i915: Fix missing unlock on error in i915_ppgtt_info() drm/amd/powerplay: workaround for UVD clock issue drm/amdgpu: add ACLK_CNTL setting for polaris10 drm/amd/powerplay: fix issue uvd dpm can't enabled on Polaris11. drm/amd/powerplay: Workaround for Memory EDC Error on Polaris10. drm/i915: Removing PCI IDs that are no longer listed as Kabylake. drm/i915: Add more Kabylake PCI IDs. drm/i915: Avoid early timeout during AUX transfers drm/i915/hsw: Avoid early timeout during LCPLL disable/restore drm/i915/lpt: Avoid early timeout during FDI PHY reset drm/i915/bxt: Avoid early timeout during PLL enable drm/i915: Refresh cached DP port register value on resume drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation drm/amd/powerplay: disable FFC. drm/amd/powerplay: add some definition for FFC feature on polaris. commit 467ce7693f5111c11daeb75e02eba2ab9ee6f334 Merge: a2b0db5 2a9b27b Author: Linus Torvalds Date: Sat Jul 2 09:40:11 2016 -0700 Merge tag 'spi-fix-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi Pull spi fixes from Mark Brown: "A few small driver-specific fixes for SPI, all in the normal important if you hit them category especially the rockchip driver fix which addresses a race which has been exposed more frequently with some recent performance improvements" * tag 'spi-fix-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: spi: sunxi: fix transfer timeout spi: sun4i: fix FIFO limit spi: rockchip: Signal unfinished DMA transfers spi: spi-ti-qspi: Suspend the queue before removing the device commit a2b0db5b55d5d70d6cdc380af287145418cb9c15 Merge: 4438512 a29a36f Author: Linus Torvalds Date: Sat Jul 2 09:39:03 2016 -0700 Merge tag 'regulator-fix-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fixes from Mark Brown: "Two small fixes for the regulator subsystem - one fixing a crash with one of the devices supported by the max77620 driver, another fixing startup for the anatop regulator when it starts up with the regulator in bypass mode" * tag 'regulator-fix-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: max77620: check for valid regulator info regulator: anatop: allow regulator to be in bypass mode commit 443851200542932414ee63ad774750633a880b4f Merge: dbdc3bb 0863477 Author: Linus Torvalds Date: Sat Jul 2 09:36:49 2016 -0700 Merge tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk fixes from Stephen Boyd: "A small fix for the newly added oxnas clk driver and a handful of rockchip clk driver fixes for newly added rk3399 support" * tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: clk: Fix return value check in oxnas_stdclk_probe() clk: rockchip: release io resource when failing to init clk on rk3399 clk: rockchip: fix cpuclk registration error handling clk: rockchip: Revert "clk: rockchip: reset init state before mmc card initialization" clk: rockchip: fix incorrect parent for rk3399's {c,g}pll_aclk_perihp_src clk: rockchip: mark rk3399 GIC clocks as critical clk: rockchip: initialize flags of clk_init_data in mmc-phase clock commit 046e9ceefab985a137fbd15b946497a88e5a6513 Merge: 62db715 7c5eec4 Author: Takashi Iwai Date: Sat Jul 2 10:50:45 2016 +0200 Merge tag 'asoc-fix-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Fixes for v4.7 A small clutch of hardware specific fixes for various ASoC devices, all small individually and important if you have that device but not otherwise. commit 88c087109b5fedaf9b61839d08543fdaf9d5ec39 Merge: 40793e8 cab1032 Author: Dave Airlie Date: Sat Jul 2 15:50:41 2016 +1000 Merge tag 'drm-intel-fixes-2016-06-30' of git://anongit.freedesktop.org/drm-intel into drm-fixes here's a batch of i915 fixes for 4.7. * tag 'drm-intel-fixes-2016-06-30' of git://anongit.freedesktop.org/drm-intel: drm/i915: Fix missing unlock on error in i915_ppgtt_info() drm/i915: Removing PCI IDs that are no longer listed as Kabylake. drm/i915: Add more Kabylake PCI IDs. drm/i915: Avoid early timeout during AUX transfers drm/i915/hsw: Avoid early timeout during LCPLL disable/restore drm/i915/lpt: Avoid early timeout during FDI PHY reset drm/i915/bxt: Avoid early timeout during PLL enable drm/i915: Refresh cached DP port register value on resume commit 40793e85d2f1088e1067f1ddeb63f4dd2336f198 Merge: dbdc3bb a7f14a1 Author: Dave Airlie Date: Sat Jul 2 15:48:33 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes Just a few more late fixes for Polaris cards. * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: drm/amd/powerplay: workaround for UVD clock issue drm/amdgpu: add ACLK_CNTL setting for polaris10 drm/amd/powerplay: fix issue uvd dpm can't enabled on Polaris11. drm/amd/powerplay: Workaround for Memory EDC Error on Polaris10. drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation drm/amd/powerplay: disable FFC. drm/amd/powerplay: add some definition for FFC feature on polaris. commit 6d037de90a1fd7b4879b48d4dd5c4839b271be98 Author: Ralf Baechle Date: Fri Jul 1 15:01:01 2016 +0200 MIPS: Fix possible corruption of cache mode by mprotect. The following testcase may result in a page table entries with a invalid CCA field being generated: static void *bindstack; static int sysrqfd; static void protect_low(int protect) { mprotect(bindstack, BINDSTACK_SIZE, protect); } static void sigbus_handler(int signal, siginfo_t * info, void *context) { void *addr = info->si_addr; write(sysrqfd, "x", 1); printf("sigbus, fault address %p (should not happen, but might)\n", addr); abort(); } static void run_bind_test(void) { unsigned int *p = bindstack; p[0] = 0xf001f001; write(sysrqfd, "x", 1); /* Set trap on access to p[0] */ protect_low(PROT_NONE); write(sysrqfd, "x", 1); /* Clear trap on access to p[0] */ protect_low(PROT_READ | PROT_WRITE | PROT_EXEC); write(sysrqfd, "x", 1); /* Check the contents of p[0] */ if (p[0] != 0xf001f001) { write(sysrqfd, "x", 1); /* Reached, but shouldn't be */ printf("badness, shouldn't happen but does\n"); abort(); } } int main(void) { struct sigaction sa; sysrqfd = open("/proc/sysrq-trigger", O_WRONLY); if (sigprocmask(SIG_BLOCK, NULL, &sa.sa_mask)) { perror("sigprocmask"); return 0; } sa.sa_sigaction = sigbus_handler; sa.sa_flags = SA_SIGINFO | SA_NODEFER | SA_RESTART; if (sigaction(SIGBUS, &sa, NULL)) { perror("sigaction"); return 0; } bindstack = mmap(NULL, BINDSTACK_SIZE, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); if (bindstack == MAP_FAILED) { perror("mmap bindstack"); return 0; } printf("bindstack: %p\n", bindstack); run_bind_test(); printf("done\n"); return 0; } There are multiple ingredients for this: 1) PAGE_NONE is defined to _CACHE_CACHABLE_NONCOHERENT, which is CCA 3 on all platforms except SB1 where it's CCA 5. 2) _page_cachable_default must have bits set which are not set _CACHE_CACHABLE_NONCOHERENT. 3) Either the defective version of pte_modify for XPA or the standard version must be in used. However pte_modify for the 36 bit address space support is no affected. In that case additional bits in the final CCA mode may generate an invalid value for the CCA field. On the R10000 system where this was tracked down for example a CCA 7 has been observed, which is Uncached Accelerated. Fixed by: 1) Using the proper CCA mode for PAGE_NONE just like for all the other PAGE_* pte/pmd bits. 2) Fix the two affected variants of pte_modify. Further code inspection also shows the same issue to exist in pmd_modify which would affect huge page systems. Issue in pte_modify tracked down by Alastair Bridgewater, PAGE_NONE and pmd_modify issue found by me. The history of this goes back beyond Linus' git history. Chris Dearman's commit 351336929ccf222ae38ff0cb7a8dd5fd5c6236a0 ("[MIPS] Allow setting of the cache attribute at run time.") missed the opportunity to fix this but it was originally introduced in lmo commit d523832cf12007b3242e50bb77d0c9e63e0b6518 ("Missing from last commit.") and 32cc38229ac7538f2346918a09e75413e8861f87 ("New configuration option CONFIG_MIPS_UNCACHED.") Signed-off-by: Ralf Baechle Reported-by: Alastair Bridgewater arch/mips/include/asm/pgtable.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit f7eca374f000bd8bd6aacc2619475fdba0b7ecca Author: Sinan Kaya Date: Wed Jun 29 04:27:37 2016 -0400 ACPI,PCI,IRQ: separate ISA penalty calculation Since commit 103544d86976 (ACPI,PCI,IRQ: reduce resource requirements) the penalty values are calculated on the fly rather than at boot time. This works fine for PCI interrupts but not so well for ISA interrupts. The information on whether or not an ISA interrupt is in use is not available to the pci_link.c code directly. That information is obtained from the outside via acpi_penalize_isa_irq(). [If its "active" argument is true, then the IRQ is in use by ISA.] Since the current code relies on PCI Link objects for determination of penalties, we are factoring in the PCI penalty twice after acpi_penalize_isa_irq() function is called. To avoid that, limit the newly added functionality to just PCI interrupts so that old behavior is still maintained. Fixes: 103544d86976 (ACPI,PCI,IRQ: reduce resource requirements) Signed-off-by: Sinan Kaya Tested-by: Wim Osterholt Signed-off-by: Rafael J. Wysocki drivers/acpi/pci_link.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 487cf917ed0d12afaf403d9d77684bf44b8c13be Author: Sinan Kaya Date: Wed Jun 29 04:27:36 2016 -0400 Revert "ACPI, PCI, IRQ: remove redundant code in acpi_irq_penalty_init()" Trying to make the ISA and PCI init functionality common turned out to be a bad idea, because the ISA path depends on external functionality. Restore the previous behavior and limit the refactoring to PCI interrupts only. Fixes: 1fcb6a813c4f "ACPI,PCI,IRQ: remove redundant code in acpi_irq_penalty_init()" Signed-off-by: Sinan Kaya Tested-by: Wim Osterholt Signed-off-by: Rafael J. Wysocki arch/x86/pci/acpi.c | 1 + drivers/acpi/pci_link.c | 36 ++++++++++++++++++++++++++++++++++++ include/acpi/acpi_drivers.h | 1 + 3 files changed, 38 insertions(+) commit 4a6e68bf96c1fa293717d2f00a68a68c92fa4150 Author: Sinan Kaya Date: Wed Jun 29 04:27:35 2016 -0400 ACPI,PCI,IRQ: factor in PCI possible The change introduced in commit 103544d86976 (ACPI,PCI,IRQ: reduce resource requirements) omitted the initially applied PCI_POSSIBLE penalty when the IRQ is active. Incorrect calculation of the penalty leads the ACPI code to assigning a wrong interrupt number to a PCI INTx interrupt. This would not be as bad as it sounds in theory. It would just cause the interrupts to be shared and result in performance penalty. However, some drivers (like the parallel port driver) don't like interrupt sharing and in the above case they will causes all of the PCI drivers wanting to share the interrupt to be unable to request it. The issue has not been caught in testing because the behavior is platform-specific and depends on the peripherals ending up sharing the IRQ and their drivers. Before the above commit the code would add the PCI_POSSIBLE value divided by the number of possible IRQ users to the IRQ penalty during initialization. Later in that code path, if the IRQ is chosen as the active IRQ or if it is used by ISA; additional penalties are added. Fixes: 103544d86976 (ACPI,PCI,IRQ: reduce resource requirements) Signed-off-by: Sinan Kaya Tested-by: Wim Osterholt [ rjw: Changelog ] Signed-off-by: Rafael J. Wysocki drivers/acpi/pci_link.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) commit dbdc3bb74faeec5fd92e28c15c945045d5aab426 Merge: 81dbd6f 5479458 Author: Linus Torvalds Date: Fri Jul 1 15:31:48 2016 -0700 Merge tag 'acpi-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fix from Rafael Wysocki: "Fix an expression in the ACPI PCI IRQ management code added by a recent commit that overlooked missing parens in it, so the result of the computation is incorrect in some cases (Sinan Kaya)" * tag 'acpi-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI,PCI,IRQ: correct operator precedence commit 81dbd6f59d91afdba16ec2edb58f6f048feed838 Merge: 48c4565 742c87b Author: Linus Torvalds Date: Fri Jul 1 15:28:22 2016 -0700 Merge tag 'pm-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "Three cpufreq fixes, one in the core (stable-candidate) and two in drivers (intel_pstate and cpufreq-dt). Specifics: - Fix a recent intel_pstate regression that caused the number of wakeups to increase significantly on an idle system in some cases due to excessive synchronize_sched() invocations (Rafael Wysocki). - Fix unnecessary invocations of WARN_ON() in the cpufreq core after cpufreq has been suspended introduced during the 4.6 cycla (Rafael Wysocki). - Fix an error code path in the cpufreq-dt-platdev driver that forgets to drop a reference to a DT node (Masahiro Yamada)" * tag 'pm-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: cpufreq: Avoid false-positive WARN_ON()s in cpufreq_update_policy() cpufreq: dt: call of_node_put() before error out intel_pstate: Do not clear utilization update hooks on policy changes commit 48c4565ed66ee7d045ac8d3c442ca7e588b32bc8 Merge: 2728c57 e06b933 Author: Linus Torvalds Date: Fri Jul 1 15:20:11 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs fixes from Al Viro: "Tmpfs readdir throughput regression fix (this cycle) + some -stable fodder all over the place. One missing bit is Miklos' tonight locks.c fix - NFS folks had already grabbed that one by the time I woke up ;-)" [ The locks.c fix came through the nfsd tree just moments ago ] * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: namespace: update event counter when umounting a deleted dentry 9p: use file_dentry() ceph: fix d_obtain_alias() misuses lockless next_positive() libfs.c: new helper - next_positive() dcache_{readdir,dir_lseek}(): don't bother with nested ->d_lock commit 2728c57fda2c10cb290f1516cab5b170ea2e3f22 Merge: 0d064a7 6343a21 Author: Linus Torvalds Date: Fri Jul 1 15:18:49 2016 -0700 Merge tag 'nfsd-4.7-3' of git://linux-nfs.org/~bfields/linux Pull lockd/locks fixes from Bruce Fields: "One fix for lockd soft lookups in an error path, and one fix for file leases on overlayfs" * tag 'nfsd-4.7-3' of git://linux-nfs.org/~bfields/linux: locks: use file_inode() lockd: unregister notifier blocks if the service fails to come up completely commit 0d064a7b9c43e79c97cb2372850e12971de23b22 Merge: f3683cc 5baaf3b Author: Linus Torvalds Date: Fri Jul 1 15:17:16 2016 -0700 Merge tag 'mfd-fixes-4.7.1' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd Pull more MFD fixes from Lee Jones: "Apologies for missing these from the first pull request. Final patches fixing Reset API change" * tag 'mfd-fixes-4.7.1' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: usb: dwc3: st: Use explicit reset_control_get_exclusive() API phy: phy-stih407-usb: Use explicit reset_control_get_exclusive() API phy: miphy28lp: Inform the reset framework that our reset line may be shared commit f3683ccd12ac625cee12650ca8595c7b9cb16d77 Merge: 6e5c4f1 1bcbf42 Author: Linus Torvalds Date: Fri Jul 1 15:15:03 2016 -0700 Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm Pull libnvdimm fixes from Dan Williams: "1/ Two regression fixes since v4.6: one for the byte order of a sysfs attribute (bz121161) and another for QEMU 2.6's NVDIMM _DSM (ACPI Device Specific Method) implementation that gets tripped up by new auto-probing behavior in the NFIT driver. 2/ A fix tagged for -stable that stops the kernel from clobbering/ignoring changes to the configuration of a 'pfn' instance ("struct page" driver). For example changing the alignment from 2M to 1G may silently revert to 2M if that value is currently stored on media. 3/ A fix from Eric for an xfstests failure in dax. It is not currently tagged for -stable since it requires an 8-exabyte file system to trigger, and there appear to be no user visible side effects" * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: nfit: fix format interface code byte order dax: fix offset overflow in dax_io acpi, nfit: fix acpi_check_dsm() vs zero functions implemented libnvdimm, pfn, dax: fix initialization vs autodetect for mode + alignment commit 55e77a3e8297581c919b45adcc4d0815b69afa84 Author: Richard Alpe Date: Fri Jul 1 11:11:21 2016 +0200 tipc: fix nl compat regression for link statistics Fix incorrect use of nla_strlcpy() where the first NLA_HDRLEN bytes of the link name where left out. Making the output of tipc-config -ls look something like: Link statistics: dcast-link 1:data0-1.1.2:data0 1:data0-1.1.3:data0 Also, for the record, the patch that introduce this regression claims "Sending the whole object out can cause a leak". Which isn't very likely as this is a compat layer, where the data we are parsing is generated by us and we know the string to be NULL terminated. But you can of course never be to secure. Fixes: 5d2be1422e02 (tipc: fix an infoleak in tipc_nl_compat_link_dump) Signed-off-by: Richard Alpe Signed-off-by: David S. Miller net/tipc/netlink_compat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 016eb55157166132b094e53434748cae35e18455 Author: Florian Fainelli Date: Thu Jun 30 13:27:20 2016 -0700 net: bcmsysport: Device stats are unsigned long On 64bits kernels, device stats are 64bits wide, not 32bits. Fixes: 80105befdb4b ("net: systemport: add Broadcom SYSTEMPORT Ethernet MAC driver") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bcmsysport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 79c62220d74a4a3f961a2cb7320da09eebf5daf7 Author: Daniel Borkmann Date: Fri Jul 1 00:00:54 2016 +0200 macsec: set actual real device for xmit when !protect_frames Avoid recursions of dev_queue_xmit() to the wrong net device when frames are unprotected, since at that time skb->dev still points to our own macsec dev and unlike macsec_encrypt_finish() dev pointer doesn't get updated to real underlying device. Fixes: c09440f7dcb3 ("macsec: introduce IEEE 802.1AE driver") Signed-off-by: Daniel Borkmann Acked-by: Sabrina Dubroca Acked-by: Hannes Frederic Sowa Signed-off-by: David S. Miller drivers/net/macsec.c | 1 + 1 file changed, 1 insertion(+) commit 82a31b9231f02d9c1b7b290a46999d517b0d312a Author: WANG Cong Date: Thu Jun 30 10:15:22 2016 -0700 net_sched: fix mirrored packets checksum Similar to commit 9b368814b336 ("net: fix bridge multicast packet checksum validation") we need to fixup the checksum for CHECKSUM_COMPLETE when pushing skb on RX path. Otherwise we get similar splats. Cc: Jamal Hadi Salim Cc: Tom Herbert Signed-off-by: Cong Wang Acked-by: Jamal Hadi Salim Signed-off-by: David S. Miller include/linux/skbuff.h | 19 +++++++++++++++++++ net/core/skbuff.c | 18 ------------------ net/sched/act_mirred.c | 2 +- 3 files changed, 20 insertions(+), 19 deletions(-) commit eb70db8756717b90c01ccc765fdefc4dd969fc74 Author: David S. Miller Date: Fri Jul 1 16:07:50 2016 -0400 packet: Use symmetric hash for PACKET_FANOUT_HASH. People who use PACKET_FANOUT_HASH want a symmetric hash, meaning that they want packets going in both directions on a flow to hash to the same bucket. The core kernel SKB hash became non-symmetric when the ipv6 flow label and other entities were incorporated into the standard flow hash order to increase entropy. But there are no users of PACKET_FANOUT_HASH who want an assymetric hash, they all want a symmetric one. Therefore, use the flow dissector to compute a flat symmetric hash over only the protocol, addresses and ports. This hash does not get installed into and override the normal skb hash, so this change has no effect whatsoever on the rest of the stack. Reported-by: Eric Leblond Tested-by: Eric Leblond Signed-off-by: David S. Miller include/linux/skbuff.h | 1 + net/core/flow_dissector.c | 43 +++++++++++++++++++++++++++++++++++++++++++ net/packet/af_packet.c | 2 +- 3 files changed, 45 insertions(+), 1 deletion(-) commit beca4cf55323147ca9c8a98de1871be6e4fe8f34 Author: Thomas Hellstrom Date: Wed Jun 29 13:37:35 2016 -0700 drm/vmwgfx: Fix corner case screen target management When the surface backing a framebuffer doesn't match the framebuffer's dimensions, the screen target code would test the framebuffer dimensions rather than the surface dimensions when deciding whether to bind the surface as a screen target directly. This causes a screen target - surface dimension mismatch and a subsequent device error. Fix this by testing against the surface dimension. v2: Fix review comments by Sinclair Yeh. Signed-off-by: Thomas Hellstrom Reviewed-by: Sinclair Yeh Cc: drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit d5f1a291e32309324a8c481ed84b5c118d1360ea Author: Sinclair Yeh Date: Wed Jun 29 13:23:18 2016 -0700 drm/vmwgfx: Delay pinning fbdev framebuffer until after mode set For the Screen Object display unit, we need to reserve a guest-invisible region equal to the size of the framebuffer for the host. This region can only be reserved in VRAM, whereas the guest-visible framebuffer can be reserved in either VRAM or GMR. As such priority should be given to the guest-invisible region otherwise in a limited VRAM situation, we can fail to allocate this region. This patch makes it so that vmw_sou_backing_alloc() is called before the framebuffer is pinned. Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: --- This is the last patch of a 3-patch series to fix console black screen issue on Ubuntu 16.04 server drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 47 ++++++++++++++++++++------------------ 1 file changed, 25 insertions(+), 22 deletions(-) commit 4ed7e2242b637bc4af0416e4aa9f945db30fb44a Author: Sinclair Yeh Date: Wed Jun 29 13:20:26 2016 -0700 drm/vmwgfx: Check pin count before attempting to move a buffer In certain scenarios, e.g. when fbdev is enabled, we can get into a situation where a vmw_framebuffer_pin() is called on a buffer that is already pinned. When this happens, ttm_bo_validate() will unintentially remove the TTM_PL_FLAG_NO_EVICT flag, thus unpinning it, and leaving no way to actually pin the buffer again. To prevent this, if a buffer is already pinned, then instead of calling ttm_bo_validate(), just make sure the proposed placement is compatible with the existing placement. Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: --- This is the 2nd patch in a 3-patch series to fix a console black screen issue on Ubuntu 16.04 server. This fixes a BUG_ON() condition where a pinned buffer gets accidentally put onto the LRU list. drivers/gpu/drm/vmwgfx/vmwgfx_dmabuf.c | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) commit 94477bff390aa4612d2332c8abafaae0a13d6923 Author: Sinclair Yeh Date: Wed Jun 29 12:58:49 2016 -0700 drm/ttm: Make ttm_bo_mem_compat available There are cases where it is desired to see if a proposed placement is compatible with a buffer object before calling ttm_bo_validate(). Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: --- This is the first of a 3-patch series to fix a black screen issue observed on Ubuntu 16.04 server. drivers/gpu/drm/ttm/ttm_bo.c | 7 ++++--- include/drm/ttm/ttm_bo_api.h | 14 ++++++++++++++ 2 files changed, 18 insertions(+), 3 deletions(-) commit 04319d89fbec72dfd60738003c3813b97c1d5f5a Author: Sinclair Yeh Date: Wed Jun 29 12:15:48 2016 -0700 drm/vmwgfx: Add an option to change assumed FB bpp Offer an option for advanced users who want larger modes at 16bpp. This becomes necessary after the fix: "Work around mode set failure in 2D VMs." Without this patch, there would be no way for existing advanced users to get to a high res mode, and the regression is they will likely get a black screen after a software update on their current VM. Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 5 +++++ drivers/gpu/drm/vmwgfx/vmwgfx_drv.h | 1 + drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 3 +++ 3 files changed, 9 insertions(+) commit 7c20d213dd3cd6295bf9162730e7a368af957854 Author: Sinclair Yeh Date: Wed Jun 29 11:29:47 2016 -0700 drm/vmwgfx: Work around mode set failure in 2D VMs In a low-memory 2D VM, fbdev can take up a large percentage of available memory, making them unavailable for other DRM clients. Since we do not take fbdev into account when filtering modes, we end up claiming to support more modes than we actually do. As a result, users get a black screen when setting a mode too large for current available memory. In a low-memory VM configuration, users can get a black screen for a mode as low as 1024x768. The current mode filtering mechanism keys off of SVGA_REG_SUGGESTED_GBOBJECT_MEM_SIZE_KB, i.e. the maximum amount of surface memory we have. Since this value is a performance suggestion, not a hard limit, and since there should not be much of a performance impact for a 2D VM, rather than filtering out more modes, we will just allow ourselves to exceed the SVGA's performance suggestion. Also changed assumed bpp to 32 from 16 to make sure we can actually support all the modes listed. Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 7 +++++++ drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 9 +-------- 2 files changed, 8 insertions(+), 8 deletions(-) commit a9cd9c044aa90ba2b31d1bf3e3432f38fb1d25fe Author: Sinclair Yeh Date: Wed Jun 29 16:31:01 2016 -0700 drm/vmwgfx: Add a check to handle host message failure Discovered by static code analysis tool. If for some reason communication with the host fails more than preset number of retries, return an error instead of return garbage. Signed-off-by: Sinclair Yeh Reviewed-by: Charmaine Lee Reported-by: Dan Carpenter drivers/gpu/drm/vmwgfx/vmwgfx_msg.c | 3 +++ 1 file changed, 3 insertions(+) commit 6e5c4f13a53d8b126f5636cb29b1c80d10d6838e Merge: 756c0ae d839722 Author: Linus Torvalds Date: Fri Jul 1 09:21:34 2016 -0700 Merge tag 'staging-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging and IIO fixes from Greg KH: "Here are a few small staging and iio driver fixes for 4.7-rc6. Nothing major here, just a number of small fixes, all have been in linux-next for a while, and the full details are in the shortlog" * tag 'staging-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: iio:ad7266: Fix probe deferral for vref iio:ad7266: Fix support for optional regulators iio:ad7266: Fix broken regulator error handling iio: accel: kxsd9: fix the usage of spi_w8r8() staging: iio: accel: fix error check staging: iio: ad5933: fix order of cycle conditions staging: iio: fix ad7606_spi regression iio: inv_mpu6050: Fix use-after-free in ACPI code commit 756c0aeca3c2deeadf331394b7ae4a3b2cb4d401 Merge: 0232b23 5353ed8 Author: Linus Torvalds Date: Fri Jul 1 09:20:12 2016 -0700 Merge tag 'tty-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty Pull tty fixes from Greg KH: "Here are two tty fixes for some reported issues. One resolves a crash in devpts, and the other resolves a problem with the fbcon cursor blink causing lockups. Both have been in linux-next with no reported problems" * tag 'tty-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: devpts: fix null pointer dereference on failed memory allocation tty: vt: Fix soft lockup in fbcon cursor blink timer. commit 0232b23d084bd075cee0812242323bbd1f4d0763 Merge: aa7a6c8 ab2a4bf Author: Linus Torvalds Date: Fri Jul 1 09:18:17 2016 -0700 Merge tag 'usb-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Pull USB and PHY fixes from Greg KH: "Here are a number of small USB and PHY driver fixes for 4.7-rc6. Nothing major here, all are described in the shortlog below. All have been in linux-next with no reported issues" * tag 'usb-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: USB: don't free bandwidth_mutex too early USB: EHCI: declare hostpc register as zero-length array phy-sun4i-usb: Fix irq free conditions to match request conditions phy: bcm-ns-usb2: checking the wrong variable phy-sun4i-usb: fix missing __iomem * phy: phy-sun4i-usb: Fix optional gpios failing probe phy: rockchip-dp: fix return value check in rockchip_dp_phy_probe() phy: rcar-gen3-usb2: fix unexpected repeat interrupts of VBUS change usb: common: otg-fsm: add license to usb-otg-fsm commit aa7a6c8e5252ba28f36a8f87b9acd6a726aa3ae5 Merge: 1a0a02d 6082ee7 Author: Linus Torvalds Date: Fri Jul 1 09:13:31 2016 -0700 Merge tag 'iommu-fixes-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu Pull IOMMU fixes from Joerg Roedel: "Three fixes: - Fix use of smp_processor_id() in preemptible code in the IOVA allocation code. This got introduced with the scalability improvements in this release cycle. - A VT-d fix for out-of-bounds access of the iommu->domains array. The bug showed during suspend/resume. - AMD IOMMU fix to print the correct device id in the ACPI parsing code" * tag 'iommu-fixes-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu: iommu/amd: Initialize devid variable before using it iommu/vt-d: Fix overflow of iommu->domains array iommu/iova: Disable preemption around use of this_cpu_ptr() commit a29a36f2650dbaa54c8aed8cc9af909113c19ad3 Merge: 4c2e07c 8a092e6 91ff811 Author: Mark Brown Date: Fri Jul 1 18:06:48 2016 +0200 Merge remote-tracking branches 'regulator/fix/anatop' and 'regulator/fix/max77620' into regulator-linus commit 7c5eec4edf4693aa61f3ee78bf28621dfe33d9f0 Merge: af5fb67 4f35325 572f1f6 50c7a0e Author: Mark Brown Date: Fri Jul 1 18:05:34 2016 +0200 Merge remote-tracking branches 'asoc/fix/rcar', 'asoc/fix/rt5670' and 'asoc/fix/wm8940' into asoc-linus commit af5fb67877a52561c614e5fda6d163acef4c4c69 Merge: 9d3146c dcd2d1f 19edeb3 86c0ae7 8e1cc0e 4f14f5c 6de7df8 Author: Mark Brown Date: Fri Jul 1 18:05:31 2016 +0200 Merge remote-tracking branches 'asoc/fix/ak4613', 'asoc/fix/arizona', 'asoc/fix/cx20442', 'asoc/fix/davinci', 'asoc/fix/fsl-ssi' and 'asoc/fix/hdmi' into asoc-linus commit 9d3146c401b0a09552bb2b5f4cedcbccd5dfb3fa Merge: de07bb5 fdfe3b3 Author: Mark Brown Date: Fri Jul 1 18:05:30 2016 +0200 Merge remote-tracking branch 'asoc/fix/rt5645' into asoc-linus commit de07bb5b11350082494b96cc2ec63714556cf213 Merge: 4c2e07c 18f5839 Author: Mark Brown Date: Fri Jul 1 18:05:30 2016 +0200 Merge remote-tracking branch 'asoc/fix/intel' into asoc-linus commit 8ba8682107ee2ca3347354e018865d8e1967c5f4 Author: Omar Sandoval Date: Fri Jul 1 00:39:35 2016 -0700 block: fix use-after-free in sys_ioprio_get() get_task_ioprio() accesses the task->io_context without holding the task lock and thus can race with exit_io_context(), leading to a use-after-free. The reproducer below hits this within a few seconds on my 4-core QEMU VM: #define _GNU_SOURCE #include #include #include #include int main(int argc, char **argv) { pid_t pid, child; long nproc, i; /* ioprio_set(IOPRIO_WHO_PROCESS, 0, IOPRIO_PRIO_VALUE(IOPRIO_CLASS_IDLE, 0)); */ syscall(SYS_ioprio_set, 1, 0, 0x6000); nproc = sysconf(_SC_NPROCESSORS_ONLN); for (i = 0; i < nproc; i++) { pid = fork(); assert(pid != -1); if (pid == 0) { for (;;) { pid = fork(); assert(pid != -1); if (pid == 0) { _exit(0); } else { child = wait(NULL); assert(child == pid); } } } pid = fork(); assert(pid != -1); if (pid == 0) { for (;;) { /* ioprio_get(IOPRIO_WHO_PGRP, 0); */ syscall(SYS_ioprio_get, 2, 0); } } } for (;;) { /* ioprio_get(IOPRIO_WHO_PGRP, 0); */ syscall(SYS_ioprio_get, 2, 0); } return 0; } This gets us KASAN dumps like this: [ 35.526914] ================================================================== [ 35.530009] BUG: KASAN: out-of-bounds in get_task_ioprio+0x7b/0x90 at addr ffff880066f34e6c [ 35.530009] Read of size 2 by task ioprio-gpf/363 [ 35.530009] ============================================================================= [ 35.530009] BUG blkdev_ioc (Not tainted): kasan: bad access detected [ 35.530009] ----------------------------------------------------------------------------- [ 35.530009] Disabling lock debugging due to kernel taint [ 35.530009] INFO: Allocated in create_task_io_context+0x2b/0x370 age=0 cpu=0 pid=360 [ 35.530009] ___slab_alloc+0x55d/0x5a0 [ 35.530009] __slab_alloc.isra.20+0x2b/0x40 [ 35.530009] kmem_cache_alloc_node+0x84/0x200 [ 35.530009] create_task_io_context+0x2b/0x370 [ 35.530009] get_task_io_context+0x92/0xb0 [ 35.530009] copy_process.part.8+0x5029/0x5660 [ 35.530009] _do_fork+0x155/0x7e0 [ 35.530009] SyS_clone+0x19/0x20 [ 35.530009] do_syscall_64+0x195/0x3a0 [ 35.530009] return_from_SYSCALL_64+0x0/0x6a [ 35.530009] INFO: Freed in put_io_context+0xe7/0x120 age=0 cpu=0 pid=1060 [ 35.530009] __slab_free+0x27b/0x3d0 [ 35.530009] kmem_cache_free+0x1fb/0x220 [ 35.530009] put_io_context+0xe7/0x120 [ 35.530009] put_io_context_active+0x238/0x380 [ 35.530009] exit_io_context+0x66/0x80 [ 35.530009] do_exit+0x158e/0x2b90 [ 35.530009] do_group_exit+0xe5/0x2b0 [ 35.530009] SyS_exit_group+0x1d/0x20 [ 35.530009] entry_SYSCALL_64_fastpath+0x1a/0xa4 [ 35.530009] INFO: Slab 0xffffea00019bcd00 objects=20 used=4 fp=0xffff880066f34ff0 flags=0x1fffe0000004080 [ 35.530009] INFO: Object 0xffff880066f34e58 @offset=3672 fp=0x0000000000000001 [ 35.530009] ================================================================== Fix it by grabbing the task lock while we poke at the io_context. Cc: stable@vger.kernel.org Reported-by: Dmitry Vyukov Signed-off-by: Omar Sandoval Signed-off-by: Jens Axboe block/ioprio.c | 2 ++ 1 file changed, 2 insertions(+) commit 6343a2120862f7023006c8091ad95c1f16a32077 Author: Miklos Szeredi Date: Fri Jul 1 14:56:07 2016 +0200 locks: use file_inode() (Another one for the f_path debacle.) ltp fcntl33 testcase caused an Oops in selinux_file_send_sigiotask. The reason is that generic_add_lease() used filp->f_path.dentry->inode while all the others use file_inode(). This makes a difference for files opened on overlayfs since the former will point to the overlay inode the latter to the underlying inode. So generic_add_lease() added the lease to the overlay inode and generic_delete_lease() removed it from the underlying inode. When the file was released the lease remained on the overlay inode's lock list, resulting in use after free. Reported-by: Eryu Guan Fixes: 4bacc9c9234c ("overlayfs: Make f_path always point to the overlay and f_inode to the underlay") Cc: Signed-off-by: Miklos Szeredi Reviewed-by: Jeff Layton Signed-off-by: J. Bruce Fields fs/locks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9cc1c73ad66610bffc80b691136ffc1e9a3b1a58 Author: Florian Westphal Date: Sun Apr 24 01:18:21 2016 +0200 netfilter: conntrack: avoid integer overflow when resizing Can overflow so we might allocate very small table when bucket count is high on a 32bit platform. Note: resize is only possible from init_netns. Signed-off-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_conntrack_core.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 08df7bc5001e7fc8bdb0a74e04ad2db5f797ed3d Merge: f87fda0 87424ad Author: David S. Miller Date: Fri Jul 1 06:12:12 2016 -0400 Merge branch 'mlx5-fixes' Saeed Mahameed says: ==================== Mellanox 100G mlx5 resiliency and xmit path fixes This series provides two set of fixes to the mlx5 driver: - Resiliency fixes for reset flow and internal pci errors - xmit path fixes Please consider queuing those patches for -stable (4.6). Reset flow fixes for core driver: - Add more commands to the list of error simulated commands when pci errors occur - Avoid calling sleeping function by the health poll thread - Fix incorrect page count when in internal error - Fix timeout in wait vital for VFs - Deadlock fix and Timeout handling in commands interface Reset flow and resiliency fixes for mlx5e netdev driver: - Handle RQ flush in error cases - Implement ndo_tx_timeout callback - Timeout if SQ doesn't flush during close - Log link state changes - Validate BW weight values of ETS xmit path fixes: - Fix wrong fallback assumption in select queue callback - Account for all L2 headers when copying headers into inline segment ==================== Signed-off-by: David S. Miller commit 87424ad52d76535234f217637fcaadcd2ef2334d Author: Shaker Daibes Date: Thu Jun 30 17:34:50 2016 +0300 net/mlx5e: Log link state changes Add Link UP/Down prints to kernel log when link state changes Signed-off-by: Shaker Daibes Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit cdcf11212b22ff8e3de88ced1a6eda5bb950e120 Author: Rana Shahout Date: Thu Jun 30 17:34:49 2016 +0300 net/mlx5e: Validate BW weight values of ETS Valid weight assigned to ETS TClass values are 1-100 Fixes: 08fb1dacdd76 ('net/mlx5e: Support DCBNL IEEE ETS') Signed-off-by: Rana Shahout Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en.h | 1 - drivers/net/ethernet/mellanox/mlx5/core/en_dcbnl.c | 8 ++++++-- 2 files changed, 6 insertions(+), 3 deletions(-) commit 7ccdd0841b305323e10e779c476d3fbae2165756 Author: Rana Shahout Date: Thu Jun 30 17:34:48 2016 +0300 net/mlx5e: Fix select queue callback The default fallback function used by mlx5e select queue can return any TX queues in range [0..dev->num_real_tx_queues). The current implementation assumes that the fallback function returns a number in the range [0.. number of channels). Actually dev->num_real_tx_queues = (number of channels) * dev->num_tc; which is more than the expected range if num_tc is configured and could lead to crashes. To fix this we test if num_tc is not configured we can safely return the fallback suggestion, if not we will reciprocal_scale the fallback result and normalize it to the desired range. Fixes: 08fb1dacdd76 ('net/mlx5e: Support DCBNL IEEE ETS') Signed-off-by: Rana Shahout Signed-off-by: Saeed Mahameed Reported-by: Doug Ledford Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 5 ++++- drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 16 ++++++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) commit e3a19b53cbb0e6738b7a547f262179065b72e3fa Author: Matthew Finlay Date: Thu Jun 30 17:34:47 2016 +0300 net/mlx5e: Copy all L2 headers into inline segment ConnectX4-Lx uses an inline wqe mode that currently defaults to requiring the entire L2 header be included in the wqe. This patch fixes mlx5e_get_inline_hdr_size() to account for all L2 headers (VLAN, QinQ, etc) using skb_network_offset(skb). Fixes: e586b3b0baee ("net/mlx5: Ethernet Datapath files") Signed-off-by: Matthew Finlay Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6cd392a082deca8accec5c50b5b3fc1a9de5bfa2 Author: Daniel Jurgens Date: Thu Jun 30 17:34:46 2016 +0300 net/mlx5e: Handle RQ flush in error cases Add a timeout to avoid an infinite loop waiting for RQ's to flush. This occurs during AER/EEH and will also happen if the device stops posting completions due to internal error or reset, or if moving the RQ to the error state fails. Also cleanup posted receive resources when closing the RQ. Fixes: f62b8bb8f2d3 ('net/mlx5: Extend mlx5_core to support ConnectX-4 Ethernet functionality') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en.h | 7 ++++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 16 +++++++-- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 41 +++++++++++++++++++++++ 3 files changed, 61 insertions(+), 3 deletions(-) commit 3947ca1859999ac00698c0da0d233813a93d288a Author: Daniel Jurgens Date: Thu Jun 30 17:34:45 2016 +0300 net/mlx5e: Implement ndo_tx_timeout callback Add callback to handle TX timeouts. Fixes: f62b8bb8f2d3 ('net/mlx5: Extend mlx5_core to support ConnectX-4 Ethernet functionality') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en.h | 1 + drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 46 +++++++++++++++++++++++ 2 files changed, 47 insertions(+) commit 29429f3300a378f7c29583b4c2c2ef29e2190a69 Author: Daniel Jurgens Date: Thu Jun 30 17:34:44 2016 +0300 net/mlx5e: Timeout if SQ doesn't flush during close Avoid an infinite loop by timing out waiting for the SQ to flush. Also clean up the TX descriptors if that happens. Fixes: f62b8bb8f2d3 ('net/mlx5: Extend mlx5_core to support ConnectX-4 Ethernet functionality') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en.h | 2 ++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 25 +++++++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 32 +++++++++++++++++++++++ 3 files changed, 56 insertions(+), 3 deletions(-) commit 65ee67084589c1783a74b4a4a5db38d7264ec8b5 Author: Mohamad Haj Yahia Date: Thu Jun 30 17:34:43 2016 +0300 net/mlx5: Add timeout handle to commands with callback The current implementation does not handle timeout in case of command with callback request, and this can lead to deadlock if the command doesn't get fw response. Add delayed callback timeout work before posting the command to fw. In case of real fw command completion we will cancel the delayed work. In case of fw command timeout the callback timeout handler will be called and it will simulate fw completion with timeout error. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB adapters') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 38 ++++++++++++++++++++++----- include/linux/mlx5/driver.h | 1 + 2 files changed, 32 insertions(+), 7 deletions(-) commit 9cba4ebcf374c3772f6eb61f2d065294b2451b49 Author: Mohamad Haj Yahia Date: Thu Jun 30 17:34:42 2016 +0300 net/mlx5: Fix potential deadlock in command mode change Call command completion handler in case of timeout when working in interrupts mode. Avoid flushing the commands workqueue after acquiring the semaphores to prevent a potential deadlock. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB adapters') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 79 +++++++++++---------------- 1 file changed, 33 insertions(+), 46 deletions(-) commit d57847dc4177c6fd8d950cb533f5edf0eab45b11 Author: Daniel Jurgens Date: Thu Jun 30 17:34:41 2016 +0300 net/mlx5: Fix wait_vital for VFs and remove fixed sleep The device ID for VFs is in a different location than PFs. This results in the poll always timing out for VFs. There's no good way to read the VF device ID without using the PF's configuration space. Switch to waiting for the health poll to start incrementing. Also remove the 1s sleep at the beginning. fixes: 89d44f0a6c73 ('net/mlx5_core: Add pci error handlers to mlx5_core driver') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/main.c | 41 ++++++++++---------------- 1 file changed, 15 insertions(+), 26 deletions(-) commit 5adff6a0886273eb426360400f120443833760a3 Author: Daniel Jurgens Date: Thu Jun 30 17:34:40 2016 +0300 net/mlx5: Fix incorrect page count when in internal error Change page cleanup flow when in internal error to properly decrement the page counts when reclaiming pages. The prevents timing out waiting for extra pages that were actually cleaned up previously. fixes: 89d44f0a6c73 ('net/mlx5_core: Add pci error handlers to mlx5_core driver') Signed-off-by: Daniel Jurgens Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller .../net/ethernet/mellanox/mlx5/core/pagealloc.c | 63 +++++++++++++++------- 1 file changed, 44 insertions(+), 19 deletions(-) commit c1d4d2e92ad670168a17a57dfa182a5a5baa72d4 Author: Mohamad Haj Yahia Date: Thu Jun 30 17:34:39 2016 +0300 net/mlx5: Avoid calling sleeping function by the health poll thread In internal error state the health poll thread will eventually call synchronize_irq() (to safely trigger command completions) which might sleep, so we are calling sleeping function from atomic context which is invalid. Here we move trigger_cmd_completions(dev) to enter error state which is the earliest stage in error state handling. This way we won't need to wait for next health poll to trigger command completions and will solve the scheduling while atomic issue. mlx5_enter_error_state can be called from two contexts, protect it with dev->intf_state_lock Fixes: 89d44f0a6c73 ('net/mlx5_core: Add pci error handlers to mlx5_core driver') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/health.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 0d834442cc247c7b3f3bd6019512ae03e96dd99a Author: Mohamad Haj Yahia Date: Thu Jun 30 17:34:38 2016 +0300 net/mlx5: Fix teardown errors that happen in pci error handler In case of internal error state we will simulate the commands status through the return value translation function, but we need to simulate all the teardown fw commands as successful so we will not have fw command failure prints. This also fix memory leaks that happen because we skip teardown stages due to failed fw commands. Fixes: 89d44f0a6c73 ('net/mlx5_core: Add pci error handlers to mlx5_core driver') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit f87fda00b6ed232a817c655b8d179b48bde8fdbe Author: Eric Dumazet Date: Thu Jun 30 16:13:41 2016 +0200 bonding: prevent out of bound accesses ether_addr_equal_64bits() requires some care about its arguments, namely that 8 bytes might be read, even if last 2 byte values are not used. KASan detected a violation with null_mac_addr and lacpdu_mcast_addr in bond_3ad.c Same problem with mac_bcast[] and mac_v6_allmcast[] in bond_alb.c : Although the 8-byte alignment was there, KASan would detect out of bound accesses. Fixes: 815117adaf5b ("bonding: use ether_addr_equal_unaligned for bond addr compare") Fixes: bb54e58929f3 ("bonding: Verify RX LACPDU has proper dest mac-addr") Fixes: 885a136c52a8 ("bonding: use compare_ether_addr_64bits() in ALB") Signed-off-by: Eric Dumazet Reported-by: Dmitry Vyukov Acked-by: Dmitry Vyukov Acked-by: Nikolay Aleksandrov Acked-by: Ding Tianhong Signed-off-by: David S. Miller drivers/net/bonding/bond_3ad.c | 11 +++++++---- drivers/net/bonding/bond_alb.c | 7 ++----- include/net/bonding.h | 7 ++++++- 3 files changed, 15 insertions(+), 10 deletions(-) commit fdfe3b32db70aa49d1d60a1ddd2280099174bddb Author: Bard Liao Date: Fri Jul 1 09:49:05 2016 +0800 ASoC: rt5645: fix reg-2f default value. The default value of reg-2f in codec rt5650 is 0x5002, not 0x1002. Signed-off-by: Bard Liao Signed-off-by: Mark Brown sound/soc/codecs/rt5645.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3d8c4530e50dc030efcec575aa69483439fc6fda Author: Russell King - ARM Linux Date: Thu Jun 30 10:36:15 2016 +0100 net: mvneta: fix open() error cleanup If mvneta_mdio_probe() fails, a kernel warning is triggered due to missing cleanup in the error path. Add the necessary cleanup. ------------[ cut here ]------------ WARNING: CPU: 1 PID: 281 at kernel/irq/manage.c:1814 __free_percpu_irq+0xfc/0x130 percpu IRQ 38 still enabled on CPU0! Modules linked in: bnep bluetooth xhci_plat_hcd xhci_hcd marvell_cesa armada_thermal des_generic ehci_orion mcp3021 spi_orion sfp mdio_i2c evbug fuse CPU: 1 PID: 281 Comm: connmand Not tainted 4.7.0-rc2+ #53 Hardware name: Marvell Armada 380/385 (Device Tree) Backtrace: [] (dump_backtrace) from [] (show_stack+0x18/0x1c) r6:60010093 r5:ffffffff r4:00000000 r3:dc8ba500 [] (show_stack) from [] (dump_stack+0xa4/0xdc) [] (dump_stack) from [] (__warn+0xd8/0x104) r6:c081e6a0 r5:00000000 r4:edfe5d50 r3:dc8ba500 [] (__warn) from [] (warn_slowpath_fmt+0x40/0x48) r10:a0010013 r8:c09356f8 r7:00000026 r6:ef11a260 r5:edd7b980 r4:ef11a200 [] (warn_slowpath_fmt) from [] (__free_percpu_irq+0xfc/0x130) r3:00000026 r2:c081e7ac [] (__free_percpu_irq) from [] (free_percpu_irq+0x48/0x74) r10:00008914 r8:00000000 r7:ffffffed r6:c09356f8 r5:00000026 r4:ef11a200 [] (free_percpu_irq) from [] (mvneta_open+0x118/0x134) r6:ffffffed r5:ef01e640 r4:ef01e000 r3:ef01e000 [] (mvneta_open) from [] (__dev_open+0xa4/0x108) r7:ef01e030 r6:c06ff3d8 r5:ffff9003 r4:ef01e000 [] (__dev_open) from [] (__dev_change_flags+0x94/0x150) r7:00001002 r6:00000001 r5:ffff9003 r4:ef01e000 [] (__dev_change_flags) from [] (dev_change_flags+0x20/0x50) r8:00000000 r7:c09334c8 r6:00001002 r5:00000148 r4:ef01e000 r3:00008914 [] (dev_change_flags) from [] (devinet_ioctl+0x6f4/0x7e0) r8:00000000 r7:c09334c8 r6:00000000 r5:ee87200c r4:00000000 r3:00008914 [] (devinet_ioctl) from [] (inet_ioctl+0x1b8/0x1c8) r10:beb4499c r9:edfe4000 r8:ecf13280 r7:c096cf00 r6:beb4499c r5:eef7c240 r4:00008914 [] (inet_ioctl) from [] (sock_ioctl+0x78/0x300) [] (sock_ioctl) from [] (do_vfs_ioctl+0x98/0xa60) r7:00000011 r6:00008914 r5:00000011 r4:c01568d0 [] (do_vfs_ioctl) from [] (SyS_ioctl+0x3c/0x60) r10:00000000 r9:edfe4000 r8:beb4499c r7:00000011 r6:00008914 r5:ecf13280 r4:ecf13280 [] (SyS_ioctl) from [] (ret_fast_syscall+0x0/0x1c) r8:c0010004 r7:00000036 r6:00000011 r5:000a2978 r4:00000000 r3:00009003 ---[ end trace 711f625d5b04b3a7 ]--- Signed-off-by: Russell King Tested-by: Jon Nettleton Signed-off-by: David S. Miller drivers/net/ethernet/marvell/mvneta.c | 2 ++ 1 file changed, 2 insertions(+) commit f95ae8a0edba1cb85110df4f1c96786419a0472f Author: hayeswang Date: Thu Jun 30 15:33:35 2016 +0800 r8152: clear LINK_OFF_WAKE_EN after autoresume LINK_OFF_WAKE_EN should be cleared after autoresume, otherwise after system suspend, the system would wake up when linking off occurs. Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 5baaf3b9efe127d239038de9219d381f4d882b26 Author: Lee Jones Date: Tue Jun 28 09:24:40 2016 +0100 usb: dwc3: st: Use explicit reset_control_get_exclusive() API We're making all reset line users specify whether their lines are shared with other IP or they operate them exclusively. In this case the line is exclusively used only by this IP, so use the *_exclusive() API accordingly. Acked-by: Felipe Balbi Signed-off-by: Lee Jones drivers/usb/dwc3/dwc3-st.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit f5f35830fb84364a24794fe6c7101f85318481d2 Author: Lee Jones Date: Tue Jun 28 09:33:55 2016 +0100 phy: phy-stih407-usb: Use explicit reset_control_get_exclusive() API We're making all reset line users specify whether their lines are shared with other IP or they operate them exclusively. In this case the line is exclusively used only by this IP, so use the *_exclusive() API accordingly. Acked-by: Kishon Vijay Abraham I Signed-off-by: Lee Jones drivers/phy/phy-stih407-usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8293c8a3bb068bd2d2dfe00b6b0000a8fc5c860a Author: Lee Jones Date: Fri Jun 3 11:44:28 2016 +0100 phy: miphy28lp: Inform the reset framework that our reset line may be shared On the STiH410 B2120 development board the MiPHY28lp shares its reset line with the Synopsys DWC3 SuperSpeed (SS) USB 3.0 Dual-Role-Device (DRD). New functionality in the reset subsystems forces consumers to be explicit when requesting shared/exclusive reset lines. Acked-by: Kishon Vijay Abraham I Signed-off-by: Lee Jones drivers/phy/phy-miphy28lp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9216a97a12b069c62f0e927a9f54be4883648a0f Author: Sony Chacko Date: Wed Jun 29 17:51:34 2016 -0400 qlcnic: add wmb() call in transmit data path. Call wmb() to ensure writes are complete before hardware fetches updated Tx descriptors. Signed-off-by: Sony Chacko Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c | 2 ++ 1 file changed, 2 insertions(+) commit c76a093dc1415d364020b8b33f1e194ef4d26fd0 Author: Masanari Iida Date: Fri Jul 1 12:46:01 2016 +0900 x86/Documentation: Fix various typos in Documentation/x86/ files Signed-off-by: Masanari Iida Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: corbet@lwn.net Cc: linux-doc@vger.kernel.org Link: http://lkml.kernel.org/r/20160701034601.30308-1-standby24x7@gmail.com Signed-off-by: Ingo Molnar Documentation/x86/intel_mpx.txt | 6 +++--- Documentation/x86/tlb.txt | 4 ++-- Documentation/x86/x86_64/machinecheck | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) commit 1ead852dd88779eda12cb09cc894a03d9abfe1ec Author: Borislav Petkov Date: Thu Jun 16 19:13:49 2016 +0200 x86/amd_nb: Fix boot crash on non-AMD systems Fix boot crash that triggers if this driver is built into a kernel and run on non-AMD systems. AMD northbridges users call amd_cache_northbridges() and it returns a negative value to signal that we weren't able to cache/detect any northbridges on the system. At least, it should do so as all its callers expect it to do so. But it does return a negative value only when kmalloc() fails. Fix it to return -ENODEV if there are no NBs cached as otherwise, amd_nb users like amd64_edac, for example, which relies on it to know whether it should load or not, gets loaded on systems like Intel Xeons where it shouldn't. Reported-and-tested-by: Tony Battersby Signed-off-by: Borislav Petkov Cc: Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/1466097230-5333-2-git-send-email-bp@alien8.de Link: https://lkml.kernel.org/r/5761BEB0.9000807@cybernetics.com Signed-off-by: Ingo Molnar arch/x86/kernel/amd_nb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e06b933e6ded42384164d28a2060b7f89243b895 Author: Andrey Ulanov Date: Fri Apr 15 14:24:41 2016 -0700 namespace: update event counter when umounting a deleted dentry - m_start() in fs/namespace.c expects that ns->event is incremented each time a mount added or removed from ns->list. - umount_tree() removes items from the list but does not increment event counter, expecting that it's done before the function is called. - There are some codepaths that call umount_tree() without updating "event" counter. e.g. from __detach_mounts(). - When this happens m_start may reuse a cached mount structure that no longer belongs to ns->list (i.e. use after free which usually leads to infinite loop). This change fixes the above problem by incrementing global event counter before invoking umount_tree(). Change-Id: I622c8e84dcb9fb63542372c5dbf0178ee86bb589 Cc: stable@vger.kernel.org Signed-off-by: Andrey Ulanov Signed-off-by: Al Viro fs/namespace.c | 1 + 1 file changed, 1 insertion(+) commit b403f0e37a11f84f7ceaf40b0075499e5bcfd220 Author: Miklos Szeredi Date: Wed Jun 29 10:54:23 2016 +0200 9p: use file_dentry() v9fs may be used as lower layer of overlayfs and accessing f_path.dentry can lead to a crash. In this case it's a NULL pointer dereference in p9_fid_create(). Fix by replacing direct access of file->f_path.dentry with the file_dentry() accessor, which will always return a native object. Reported-by: Alessio Igor Bogani Signed-off-by: Miklos Szeredi Tested-by: Alessio Igor Bogani Fixes: 4bacc9c9234c ("overlayfs: Make f_path always point to the overlay and f_inode to the underlay") Cc: Signed-off-by: Al Viro fs/9p/vfs_file.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 65c0554b73c920023cc8998802e508b798113b46 Author: Rafael J. Wysocki Date: Thu Jun 30 18:11:41 2016 +0200 x86/power/64: Fix kernel text mapping corruption during image restoration Logan Gunthorpe reports that hibernation stopped working reliably for him after commit ab76f7b4ab23 (x86/mm: Set NX on gap between __ex_table and rodata). That turns out to be a consequence of a long-standing issue with the 64-bit image restoration code on x86, which is that the temporary page tables set up by it to avoid page tables corruption when the last bits of the image kernel's memory contents are copied into their original page frames re-use the boot kernel's text mapping, but that mapping may very well get corrupted just like any other part of the page tables. Of course, if that happens, the final jump to the image kernel's entry point will go to nowhere. The exact reason why commit ab76f7b4ab23 matters here is that it sometimes causes a PMD of a large page to be split into PTEs that are allocated dynamically and get corrupted during image restoration as described above. To fix that issue note that the code copying the last bits of the image kernel's memory contents to the page frames occupied by them previoulsy doesn't use the kernel text mapping, because it runs from a special page covered by the identity mapping set up for that code from scratch. Hence, the kernel text mapping is only needed before that code starts to run and then it will only be used just for the final jump to the image kernel's entry point. Accordingly, the temporary page tables set up in swsusp_arch_resume() on x86-64 need to contain the kernel text mapping too. That mapping is only going to be used for the final jump to the image kernel, so it only needs to cover the image kernel's entry point, because the first thing the image kernel does after getting control back is to switch over to its own original page tables. Moreover, the virtual address of the image kernel's entry point in that mapping has to be the same as the one mapped by the image kernel's page tables. With that in mind, modify the x86-64's arch_hibernation_header_save() and arch_hibernation_header_restore() routines to pass the physical address of the image kernel's entry point (in addition to its virtual address) to the boot kernel (a small piece of assembly code involved in passing the entry point's virtual address to the image kernel is not necessary any more after that, so drop it). Update RESTORE_MAGIC too to reflect the image header format change. Next, in set_up_temporary_mappings(), use the physical and virtual addresses of the image kernel's entry point passed in the image header to set up a minimum kernel text mapping (using memory pages that won't be overwritten by the image kernel's memory contents) that will map those addresses to each other as appropriate. This makes the concern about the possible corruption of the original boot kernel text mapping go away and if the the minimum kernel text mapping used for the final jump marks the image kernel's entry point memory as executable, the jump to it is guaraneed to succeed. Fixes: ab76f7b4ab23 (x86/mm: Set NX on gap between __ex_table and rodata) Link: http://marc.info/?l=linux-pm&m=146372852823760&w=2 Reported-by: Logan Gunthorpe Reported-and-tested-by: Borislav Petkov Tested-by: Kees Cook Signed-off-by: Rafael J. Wysocki arch/x86/power/hibernate_64.c | 97 ++++++++++++++++++++++++++++++++++----- arch/x86/power/hibernate_asm_64.S | 55 ++++++++++------------ 2 files changed, 109 insertions(+), 43 deletions(-) commit cb7d224f82e41d82518e7f9ea271d215d4d08e6e Author: Scott Mayhew Date: Thu Jun 30 10:39:32 2016 -0400 lockd: unregister notifier blocks if the service fails to come up completely If the lockd service fails to start up then we need to be sure that the notifier blocks are not registered, otherwise a subsequent start of the service could cause the same notifier to be registered twice, leading to soft lockups. Signed-off-by: Scott Mayhew Cc: stable@vger.kernel.org Fixes: 0751ddf77b6a "lockd: Register callbacks on the inetaddr_chain..." Signed-off-by: J. Bruce Fields fs/lockd/svc.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 74524955556096a0b2a821a49b4d0abebad3ee16 Author: Tahsin Erdogan Date: Thu Jun 16 05:15:33 2016 -0700 writeback: inode cgroup wb switch should not call ihold() Asynchronous wb switching of inodes takes an additional ref count on an inode to make sure inode remains valid until switchover is completed. However, anyone calling ihold() must already have a ref count on inode, but in this case inode->i_count may already be zero: ------------[ cut here ]------------ WARNING: CPU: 1 PID: 917 at fs/inode.c:397 ihold+0x2b/0x30 CPU: 1 PID: 917 Comm: kworker/u4:5 Not tainted 4.7.0-rc2+ #49 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 Workqueue: writeback wb_workfn (flush-8:16) 0000000000000000 ffff88007ca0fb58 ffffffff805990af 0000000000000000 0000000000000000 ffff88007ca0fb98 ffffffff80268702 0000018d000004e2 ffff88007cef40e8 ffff88007c9b89a8 ffff880079e3a740 0000000000000003 Call Trace: [] dump_stack+0x4d/0x6e [] __warn+0xc2/0xe0 [] warn_slowpath_null+0x18/0x20 [] ihold+0x2b/0x30 [] inode_switch_wbs+0x11c/0x180 [] wbc_detach_inode+0x170/0x1a0 [] writeback_sb_inodes+0x21c/0x530 [] wb_writeback+0xee/0x1e0 [] wb_workfn+0xd7/0x280 [] ? try_to_wake_up+0x1b1/0x2b0 [] process_one_work+0x129/0x300 [] worker_thread+0x126/0x480 [] ? __schedule+0x1c7/0x561 [] ? process_one_work+0x300/0x300 [] kthread+0xc4/0xe0 [] ? kfree+0xc8/0x100 [] ret_from_fork+0x1f/0x40 [] ? __kthread_parkme+0x70/0x70 ---[ end trace aaefd2fd9f306bc4 ]--- Signed-off-by: Tahsin Erdogan Acked-by: Tejun Heo Reviewed-by: Jan Kara Signed-off-by: Jens Axboe fs/fs-writeback.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2cd368300aa5bcec40c079ee5096287847506504 Author: Maxime Ripard Date: Mon Jun 20 12:20:59 2016 +0200 drm/sun4i: Send vblank event when the CRTC is disabled So far, we were missing to send the vblank event when disabling the CRTC, making us never report the last vblank event. This was causing a time out on the page flip, which should be solved now. Signed-off-by: Maxime Ripard drivers/gpu/drm/sun4i/sun4i_crtc.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 0b340405fca980b12a2ddafdd4536ad6fb624755 Author: Maxime Ripard Date: Mon Jun 20 12:20:58 2016 +0200 drm/sun4i: Report proper vblank The sun4i display engine doesn't have any vblank counter. Use the proper helper for that. Signed-off-by: Maxime Ripard drivers/gpu/drm/sun4i/sun4i_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1a0a02d1efa066001fd315c1b4df583d939fa2c4 Merge: 284341d f5c5c22 Author: Linus Torvalds Date: Thu Jun 30 09:57:52 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm Pull KVM fixes from Paolo Bonzini: "ARM and x86 fixes" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: KVM: nVMX: VMX instructions: fix segment checks when L1 is in long mode. KVM: LAPIC: cap __delay at lapic_timer_advance_ns KVM: x86: move nsec_to_cycles from x86.c to x86.h pvclock: Get rid of __pvclock_read_cycles in function pvclock_read_flags pvclock: Cleanup to remove function pvclock_get_nsec_offset pvclock: Add CPU barriers to get correct version value KVM: arm/arm64: Stop leaking vcpu pid references arm64: KVM: fix build with CONFIG_ARM_PMU disabled commit 284341d2605da0ab231bc7486ff032c4f1563819 Merge: 20bfdca 9bd5451 Author: Linus Torvalds Date: Thu Jun 30 09:53:43 2016 -0700 Merge tag 'arc-4.7-rc6-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc Pull ARC fix from Vineet Gupta: "Reinstate dwarf unwinder/loadable-modules with new gnu tools" * tag 'arc-4.7-rc6-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc: arc: unwind: warn only once if DW2_UNWIND is disabled ARC: unwind: ensure that .debug_frame is generated (vs. .eh_frame) commit 20bfdca19976994e5537aa786c39375bbd103b53 Merge: 4aa34ce 33cdcee Author: Linus Torvalds Date: Thu Jun 30 09:49:26 2016 -0700 Merge tag 'pwm/for-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm Pull pwm fixes from Thierry Reding: "One more fix for some fallout observed after the introduction of the atomic API" * tag 'pwm/for-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm: pwm: Fix pwm_apply_args() commit 4aa34ce3c1ee86ee6abbe9adc310e5f8bcca2800 Merge: e7bdea7 ba4a1c2 Author: Linus Torvalds Date: Thu Jun 30 09:44:34 2016 -0700 Merge tag 'mfd-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd Pull MFD fixes from Lee Jones: "Contained are some standard fixes and unusually an extension to the Reset API. Some of those changes are required to fix a bug introduced in -rc1, which introduces extra 'reset line checks' i.e. whether the line is shared or not. If a line is shared and the new *_shared() API is not used, the request fails with an error. This breaks USB in v4.7 for ST's platforms. Admittedly, there are some patches contained in our (MFD/Reset) immutable branch which are not true -fixes, but there isn't anything I can do about that. Rest assured though, there aren't any API 'changes'. Everything is the same from the consumer's perspective. - Use new reset_*_get_shared() variant to prevent reset line obtainment failure (Fixes commit 0b52297f2288: "reset: Add support for shared reset controls") - Fix unintentional switch() fall-through into error path - Fix uninitialised variable compiler warning" * tag 'mfd-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: mfd: da9053: Fix compiler warning message for uninitialised variable mfd: max77620: Fix FPS switch statements phy: phy-stih407-usb: Inform the reset framework that our reset line may be shared usb: dwc3: st: Inform the reset framework that our reset line may be shared usb: host: ehci-st: Inform the reset framework that our reset line may be shared usb: host: ohci-st: Inform the reset framework that our reset line may be shared reset: TRIVIAL: Add line break at same place for similar APIs reset: Supply *_shared variant calls when using *_optional APIs reset: Supply *_shared variant calls when using of_* API reset: Ensure drivers are explicit when requesting reset lines reset: Reorder inline reset_control_get*() wrappers commit f5c5c225fce4cb98fe4451d4c4d654e3f18b9f82 Merge: ff30ef4 591d215 Author: Paolo Bonzini Date: Thu Jun 30 17:11:20 2016 +0200 Merge tag 'kvm-arm-for-v4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into kvm-master KVM/ARM Fixes for v4.7-rc6: Fixes a build issue without CONFIG_ARM_PMU and plugs pid leak on arm/arm64. commit 54794580f5949253520265e46c903878ab222d84 Author: Sinan Kaya Date: Wed Jun 29 04:27:38 2016 -0400 ACPI,PCI,IRQ: correct operator precedence The omitted parenthesis prevents the addition operation when acpi_penalize_isa_irq function is called. Fixes: 103544d86976 (ACPI,PCI,IRQ: reduce resource requirements) Signed-off-by: Sinan Kaya Signed-off-by: Rafael J. Wysocki drivers/acpi/pci_link.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 43daa96b166c3cf5ff30dfac0c5efa2620e4beab Author: Soohoon Lee Date: Wed Jun 29 15:07:21 2016 -0400 usbnet: Stop RX Q on MTU change When MTU is changed unlink_urbs() flushes RX Q but mean while usbnet_bh() can fill up the Q at the same time. Depends on which HCD is down there unlink takes long time then the flush never ends. Signed-off-by: Soohoon Lee Reviewed-by: Kimball Murray Signed-off-by: David S. Miller drivers/net/usb/usbnet.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit fedbb6b4ff341c1e2120f4ffbf367fd78ac3e8f3 Author: Shmulik Ladkani Date: Wed Jun 29 21:47:03 2016 +0300 ipv4: Fix ip_skb_dst_mtu to use the sk passed by ip_finish_output ip_skb_dst_mtu uses skb->sk, assuming it is an AF_INET socket (e.g. it calls ip_sk_use_pmtu which casts sk as an inet_sk). However, in the case of UDP tunneling, the skb->sk is not necessarily an inet socket (could be AF_PACKET socket, or AF_UNSPEC if arriving from tun/tap). OTOH, the sk passed as an argument throughout IP stack's output path is the one which is of PMTU interest: - In case of local sockets, sk is same as skb->sk; - In case of a udp tunnel, sk is the tunneling socket. Fix, by passing ip_finish_output's sk to ip_skb_dst_mtu. This augments 7026b1ddb6 'netfilter: Pass socket pointer down through okfn().' Signed-off-by: Shmulik Ladkani Reviewed-by: Hannes Frederic Sowa Signed-off-by: David S. Miller include/net/ip.h | 5 ++--- net/bridge/br_netfilter_hooks.c | 2 +- net/ipv4/ip_output.c | 4 ++-- 3 files changed, 5 insertions(+), 6 deletions(-) commit 5ab0d6a016b19d8cbd503eafd0ef701cfd854402 Merge: e7bdea7 b3a3c51 Author: David S. Miller Date: Thu Jun 30 08:57:24 2016 -0400 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/net-queue Jeff Kirsher says: ==================== Intel Wired LAN Driver Updates 2016-06-29 This series contains fixes to e1000e and ixgbevf. Jarod Wilson's fix for e1000e was a follow-on patch to his previous fix to keep the hardware VLAN CTAG's for receive and transmit in sync, which in turn resolves the original issue, so revert a portion of the original fix. Xin Long noticed that the ret_val needed to be initialized to IXGBE_ERR_MBX, instead of -IXGBE_ERR_MBX. ==================== Signed-off-by: David S. Miller commit 2a9b27b326d67dcd1bca066bc35c709da972833c Merge: 4c2e07c bea8205 4dc0dd8 719bd65 3ac066e Author: Mark Brown Date: Thu Jun 30 13:17:29 2016 +0100 Merge remote-tracking branches 'spi/fix/ep93xx', 'spi/fix/rockchip', 'spi/fix/sunxi' and 'spi/fix/ti-qspi' into spi-linus commit b44439e42912b9dcc510a0ff891809ea2cadc46b Author: Arnd Bergmann Date: Mon Jun 20 18:08:22 2016 +0200 ARM: mvebu: compile pm code conditionally A cleanup to include the headers correctly caused another build problem: arch/arm/mach-mvebu/kirkwood-pm.c:70:13: error: redefinition of 'kirkwood_pm_init' arch/arm/mach-mvebu/kirkwood-pm.h:23:20: note: previous definition of 'kirkwood_pm_init' was here The underlying issue is that kirkwood-pm.o is not actually meant to be used when CONFIG_PM is disabled, so we should also leave it out of the Makefile. The same seems to be true for the PM code in MACH_MVEBU_V7, and I'm treating it the same way here. Signed-off-by: Arnd Bergmann Fixes: d705c1a66e15 ("ARM: Kirkwood: fix kirkwood_pm_init() declaration/type") Signed-off-by: Gregory CLEMENT arch/arm/mach-mvebu/Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 5c672ab3f0ee0f78f7acad183f34db0f8781a200 Author: Miklos Szeredi Date: Thu Jun 30 13:10:49 2016 +0200 fuse: serialize dirops by default Negotiate with userspace filesystems whether they support parallel readdir and lookup. Disable parallelism by default for fear of breaking fuse filesystems. Signed-off-by: Miklos Szeredi Fixes: 9902af79c01a ("parallel lookups: actual switch to rwsem") Fixes: d9b3dbdcfd62 ("fuse: switch to ->iterate_shared()") fs/fuse/dir.c | 4 ++++ fs/fuse/fuse_i.h | 9 +++++++++ fs/fuse/inode.c | 19 ++++++++++++++++++- include/uapi/linux/fuse.h | 7 ++++++- 4 files changed, 37 insertions(+), 2 deletions(-) commit cab103274352721b77fc5923a631fc63350bef8e Author: Wei Yongjun Date: Mon Jun 13 23:42:00 2016 +0000 drm/i915: Fix missing unlock on error in i915_ppgtt_info() Add the missing unlock before return from function i915_ppgtt_info() in the error handling case. Fixes: 1d2ac403ae3b(drm: Protect dev->filelist with its own mutex) Signed-off-by: Wei Yongjun Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/1465861320-26221-1-git-send-email-weiyj_lk@163.com (cherry picked from commit b0212486909de4f239ca9f20d032de1b1f2dc52e) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f8608985f851c917b3884b692d8e326b0210d34e Author: Marek Vasut Date: Wed May 18 16:16:51 2016 +0200 configfs: Remove ppos increment in configfs_write_bin_file The simple_write_to_buffer() already increments the @ppos on success, see fs/libfs.c simple_write_to_buffer() comment: " On success, the number of bytes written is returned and the offset @ppos advanced by this number, or negative value is returned on error. " If the configfs_write_bin_file() is invoked with @count smaller than the total length of the written binary file, it will be invoked multiple times. Since configfs_write_bin_file() increments @ppos on success, after calling simple_write_to_buffer(), the @ppos is incremented twice. Subsequent invocation of configfs_write_bin_file() will result in the next piece of data being written to the offset twice as long as the length of the previous write, thus creating buffer with "holes" in it. The simple testcase using DTO follows: $ mkdir /sys/kernel/config/device-tree/overlays/1 $ dd bs=1 if=foo.dtbo of=/sys/kernel/config/device-tree/overlays/1/dtbo Without this patch, the testcase will result in twice as big buffer in the kernel, which is then passed to the cfs_overlay_item_dtbo_write() . Signed-off-by: Marek Vasut Cc: Geert Uytterhoeven Cc: Christoph Hellwig Cc: Pantelis Antoniou fs/configfs/file.c | 2 -- 1 file changed, 2 deletions(-) commit bfa37087aa04e45f56c41142dfceecb79b8e6ef9 Author: Darren Stevens Date: Wed Jun 29 21:06:28 2016 +0100 powerpc: Initialise pci_io_base as early as possible Commit d6a9996e84ac ("powerpc/mm: vmalloc abstraction in preparation for radix") turned kernel memory and IO addresses from #defined constants to variables initialised at runtime. On PA6T (pasemi) systems the setup_arch() machine call initialises the onboard PCI-e root-ports, and uses pci_io_base to do this, which is now before its value has been set, resulting in a panic early in boot before console IO is initialised. Move the pci_io_base initialisation to the same place as vmalloc ranges are set (hash__early_init_mmu()/radix__early_init_mmu()) - this is the earliest possible place we can initialise it. Fixes: d6a9996e84ac ("powerpc/mm: vmalloc abstraction in preparation for radix") Reported-by: Christian Zigotzky Signed-off-by: Darren Stevens Reviewed-by: Aneesh Kumar K.V [mpe: Add #ifdef CONFIG_PCI, massage change log slightly] Signed-off-by: Michael Ellerman arch/powerpc/include/asm/book3s/64/pgtable.h | 1 + arch/powerpc/kernel/pci_64.c | 1 - arch/powerpc/mm/hash_utils_64.c | 4 ++++ arch/powerpc/mm/pgtable-radix.c | 5 +++++ 4 files changed, 10 insertions(+), 1 deletion(-) commit ba4a1c28a92df55b9263e838068b92eaa80c7850 Author: Steve Twiss Date: Mon Jun 27 16:06:36 2016 +0100 mfd: da9053: Fix compiler warning message for uninitialised variable Fix compiler warning caused by an uninitialised variable inside da9052_group_write() function. Defaulting the value to zero covers the trivial case. Signed-off-by: Steve Twiss Reported-by: Geert Uytterhoeven Signed-off-by: Lee Jones include/linux/mfd/da9052/da9052.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 82d8eb40bab10082050be945c8e7096df8e9f989 Author: Rhyland Klein Date: Thu May 12 13:45:04 2016 -0400 mfd: max77620: Fix FPS switch statements When configuring FPS during probe, assuming a DT node is present for FPS, the code can run into a problem with the switch statements in max77620_config_fps() and max77620_get_fps_period_reg_value(). Namely, in the case of chip->chip_id == MAX77620, it will set fps_[mix|max]_period but then fall through to the default switch case and return -EINVAL. Returning this from max77620_config_fps() will cause probe to fail. Signed-off-by: Rhyland Klein Reviewed-by: Laxman Dewangan Reviewed-by: Thierry Reding Tested-by: Thierry Reding Tested-by: Alexandre Courbot Signed-off-by: Lee Jones drivers/mfd/max77620.c | 2 ++ 1 file changed, 2 insertions(+) commit 9278e707f4e187df2b4d9eeb2bc78a1724fbe4ac Author: Lee Jones Date: Tue Jun 28 09:32:12 2016 +0100 phy: phy-stih407-usb: Inform the reset framework that our reset line may be shared On the STiH410 B2120 development board the ports on the Generic PHY share their reset lines with each other. New functionality in the reset subsystems forces consumers to be explicit when requesting shared/exclusive reset lines. Signed-off-by: Lee Jones drivers/phy/phy-stih407-usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 002f17bc54ff4005260d8e6e6700de97f5b25679 Author: Lee Jones Date: Tue Jun 28 09:23:58 2016 +0100 usb: dwc3: st: Inform the reset framework that our reset line may be shared On the STiH410 B2120 development board the MiPHY28lp shares its reset line with the Synopsys DWC3 SuperSpeed (SS) USB 3.0 Dual-Role-Device (DRD). New functionality in the reset subsystems forces consumers to be explicit when requesting shared/exclusive reset lines. Acked-by: Felipe Balbi Signed-off-by: Lee Jones drivers/usb/dwc3/dwc3-st.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 19599304625b74c95bff318c735928eec668b1ca Author: Lee Jones Date: Mon Jun 6 18:08:53 2016 +0100 usb: host: ehci-st: Inform the reset framework that our reset line may be shared On the STiH410 B2120 development board the ST EHCI IP shares its reset line with the OHCI IP. New functionality in the reset subsystems forces consumers to be explicit when requesting shared/exclusive reset lines. Acked-by: Peter Griffin Acked-by: Alan Stern Signed-off-by: Lee Jones drivers/usb/host/ehci-st.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit f5ee3f2b5ad6881a8194b9f684ce11640d1062f7 Author: Lee Jones Date: Mon Jun 6 18:08:54 2016 +0100 usb: host: ohci-st: Inform the reset framework that our reset line may be shared On the STiH410 B2120 development board the ST EHCI IP shares its reset line with the OHCI IP. New functionality in the reset subsystems forces consumers to be explicit when requesting shared/exclusive reset lines. Acked-by: Alan Stern Signed-off-by: Lee Jones drivers/usb/host/ohci-st.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit e7bdea7750eb2a64aea4a08fa5c0a31719c8155d Merge: 89a82a9 e547f26 Author: Linus Torvalds Date: Wed Jun 29 15:30:26 2016 -0700 Merge tag 'nfs-for-4.7-2' of git://git.linux-nfs.org/projects/anna/linux-nfs Pull NFS client bugfixes from Anna Schumaker: "Stable bugfixes: - Fix _cancel_empty_pagelist - Fix a double page unlock - Make nfs_atomic_open() call d_drop() on all ->open_context() errors. - Fix another OPEN_DOWNGRADE bug Other bugfixes: - Ensure we handle delegation errors in nfs4_proc_layoutget() - Layout stateids start out as being invalid - Add sparse lock annotations for pnfs_find_alloc_layout - Handle bad delegation stateids in nfs4_layoutget_handle_exception - Fix up O_DIRECT results - Fix potential use after free of state in nfs4_do_reclaim. - Mark the layout stateid invalid when all segments are removed - Don't let readdirplus revalidate an inode that was marked as stale - Fix potential race in nfs_fhget() - Fix an unused variable warning" * tag 'nfs-for-4.7-2' of git://git.linux-nfs.org/projects/anna/linux-nfs: NFS: Fix another OPEN_DOWNGRADE bug make nfs_atomic_open() call d_drop() on all ->open_context() errors. NFS: Fix an unused variable warning NFS: Fix potential race in nfs_fhget() NFS: Don't let readdirplus revalidate an inode that was marked as stale NFSv4.1/pnfs: Mark the layout stateid invalid when all segments are removed NFS: Fix a double page unlock pnfs_nfs: fix _cancel_empty_pagelist nfs4: Fix potential use after free of state in nfs4_do_reclaim. NFS: Fix up O_DIRECT results NFS/pnfs: handle bad delegation stateids in nfs4_layoutget_handle_exception NFSv4.1/pnfs: Add sparse lock annotations for pnfs_find_alloc_layout NFSv4.1/pnfs: Layout stateids start out as being invalid NFSv4.1/pnfs: Ensure we handle delegation errors in nfs4_proc_layoutget() commit 89a82a9218fabd753979847f494565f1fa91d7a8 Merge: 32826ac 3f5be2d Author: Linus Torvalds Date: Wed Jun 29 15:18:47 2016 -0700 Merge branch 'stable-4.7' of git://git.infradead.org/users/pcmoore/audit Pull audit fixes from Paul Moore: "Two small patches to fix audit problems in 4.7-rcX: the first fixes a potential kref leak, the second removes some header file noise. The first is an important bug fix that really should go in before 4.7 is released, the second is not critical, but falls into the very-nice- to-have category so I'm including in the pull request. Both patches are straightforward, self-contained, and pass our testsuite without problem" * 'stable-4.7' of git://git.infradead.org/users/pcmoore/audit: audit: move audit_get_tty to reduce scope and kabi changes audit: move calcs after alloc and check when logging set loginuid commit d839722131307eff1f3fe1636a5af839c90fbf96 Merge: df01321 68b356e Author: Greg Kroah-Hartman Date: Wed Jun 29 13:53:31 2016 -0700 Merge tag 'iio-fixes-for-4.7c' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus Jonathan writes: Third set of fixes for IIO in the 4.7 cycle. A couple of really old bugs and the results of Mark taking a close look at some nasty regulator handling. * ad7266 - Fix broken regulator handling that won't play well with dummy regulators. - Correctly handle and optional regulator. - Fix probe deferral for the vref regulator. * kxsd9 - Fix a wrong error check that leads to an inability to write or read the scale. * sca3000 - Fix a wrong error check that leads to an inability to read back the sampling frequency. commit 0bcc0eab363aa80f79769324bf3f2ab7781840f2 Author: Lee Jones Date: Mon Jun 6 16:56:53 2016 +0100 reset: TRIVIAL: Add line break at same place for similar APIs Standardise the way inline functions: devm_reset_control_get_shared_by_index devm_reset_control_get_exclusive_by_index ... are formatted. Signed-off-by: Lee Jones Signed-off-by: Philipp Zabel include/linux/reset.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c33d61a0c400c50f378ef03a386e646abca292ca Author: Lee Jones Date: Mon Jun 6 16:56:52 2016 +0100 reset: Supply *_shared variant calls when using *_optional APIs Consumers need to be able to specify whether they are requesting an 'exclusive' or 'shared' reset line no matter which API (of_*, devm_*, etc) they are using. This change allows users of the optional_* API in particular to specify that their request is for a 'shared' line. Signed-off-by: Lee Jones Signed-off-by: Philipp Zabel include/linux/reset.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 40faee8ee471ae526344cd5c62ff520d356de841 Author: Lee Jones Date: Mon Jun 6 16:56:51 2016 +0100 reset: Supply *_shared variant calls when using of_* API Consumers need to be able to specify whether they are requesting an 'exclusive' or 'shared' reset line no matter which API (of_*, devm_*, etc) they are using. This change allows users of the of_* API in particular to specify that their request is for a 'shared' line. Signed-off-by: Lee Jones Signed-off-by: Philipp Zabel include/linux/reset.h | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) commit a53e35db70d1638002e40d495d096181dbb0fe16 Author: Lee Jones Date: Mon Jun 6 16:56:50 2016 +0100 reset: Ensure drivers are explicit when requesting reset lines Phasing out generic reset line requests enables us to make some better decisions on when and how to (de)assert said lines. If an 'exclusive' line is requested, we know a device *requires* a reset and that it's preferable to act upon a request right away. However, if a 'shared' reset line is requested, we can reasonably assume sure that placing a device into reset isn't a hard requirement, but probably a measure to save power and is thus able to cope with not being asserted if another device is still in use. In order allow gentle adoption and not to forcing all consumers to move to the API immediately, causing administration headache between subsystems, this patch adds some temporary stand-in shim-calls. This will ease the burden at merge time and allow subsystems to migrate over to the new API in a more realistic time-frame. Signed-off-by: Lee Jones Signed-off-by: Philipp Zabel include/linux/reset.h | 106 ++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 82 insertions(+), 24 deletions(-) commit 3c35f6edc09b239a60de87a5aeb78563fc372704 Author: Lee Jones Date: Mon Jun 6 16:56:49 2016 +0100 reset: Reorder inline reset_control_get*() wrappers We're about to split the current API into two, where consumers will be forced to be explicit when requesting reset lines. The choice will be to either the call the *_exclusive or *_shared variant depending on whether they can actually tolorate not being asserted when that request is made. The new API will look like this once reorded and complete: reset_control_get_exclusive() reset_control_get_shared() reset_control_get_optional_exclusive() reset_control_get_optional_shared() of_reset_control_get_exclusive() of_reset_control_get_shared() of_reset_control_get_exclusive_by_index() of_reset_control_get_shared_by_index() devm_reset_control_get_exclusive() devm_reset_control_get_shared() devm_reset_control_get_optional_exclusive() devm_reset_control_get_optional_shared() devm_reset_control_get_exclusive_by_index() devm_reset_control_get_shared_by_index() Signed-off-by: Lee Jones Signed-off-by: Philipp Zabel include/linux/reset.h | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) commit df253e8454de6f85636aa4d9d99555fbcad6f580 Merge: edb50a5 7b427a5 Author: Jens Axboe Date: Wed Jun 29 13:15:19 2016 -0600 Merge branch 'stable/for-jens-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen into for-linus commit 32826ac41f2170df0d9a2e8df5a9b570c7858ccf Merge: 653c574 751ad81 Author: Linus Torvalds Date: Wed Jun 29 11:50:42 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes from David Miller: "I've been traveling so this accumulates more than week or so of bug fixing. It perhaps looks a little worse than it really is. 1) Fix deadlock in ath10k driver, from Ben Greear. 2) Increase scan timeout in iwlwifi, from Luca Coelho. 3) Unbreak STP by properly reinjecting STP packets back into the stack. Regression fix from Ido Schimmel. 4) Mediatek driver fixes (missing malloc failure checks, leaking of scratch memory, wrong indexing when mapping TX buffers, etc.) from John Crispin. 5) Fix endianness bug in icmpv6_err() handler, from Hannes Frederic Sowa. 6) Fix hashing of flows in UDP in the ruseport case, from Xuemin Su. 7) Fix netlink notifications in ovs for tunnels, delete link messages are never emitted because of how the device registry state is handled. From Nicolas Dichtel. 8) Conntrack module leaks kmemcache on unload, from Florian Westphal. 9) Prevent endless jump loops in nft rules, from Liping Zhang and Pablo Neira Ayuso. 10) Not early enough spinlock initialization in mlx4, from Eric Dumazet. 11) Bind refcount leak in act_ipt, from Cong WANG. 12) Missing RCU locking in HTB scheduler, from Florian Westphal. 13) Several small MACSEC bug fixes from Sabrina Dubroca (missing RCU barrier, using heap for SG and IV, and erroneous use of async flag when allocating AEAD conext.) 14) RCU handling fix in TIPC, from Ying Xue. 15) Pass correct protocol down into ipv4_{update_pmtu,redirect}() in SIT driver, from Simon Horman. 16) Socket timer deadlock fix in TIPC from Jon Paul Maloy. 17) Fix potential deadlock in team enslave, from Ido Schimmel. 18) Memory leak in KCM procfs handling, from Jiri Slaby. 19) ESN generation fix in ipv4 ESP, from Herbert Xu. 20) Fix GFP_KERNEL allocations with locks held in act_ife, from Cong WANG. 21) Use after free in netem, from Eric Dumazet. 22) Uninitialized last assert time in multicast router code, from Tom Goff. 23) Skip raw sockets in sock_diag destruction broadcast, from Willem de Bruijn. 24) Fix link status reporting in thunderx, from Sunil Goutham. 25) Limit resegmentation of retransmit queue so that we do not retransmit too large GSO frames. From Eric Dumazet. 26) Delay bpf program release after grace period, from Daniel Borkmann" * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (141 commits) openvswitch: fix conntrack netlink event delivery qed: Protect the doorbell BAR with the write barriers. neigh: Explicitly declare RCU-bh read side critical section in neigh_xmit() e1000e: keep VLAN interfaces functional after rxvlan off cfg80211: fix proto in ieee80211_data_to_8023 for frames without LLC header qlcnic: use the correct ring in qlcnic_83xx_process_rcv_ring_diag() bpf, perf: delay release of BPF prog after grace period net: bridge: fix vlan stats continue counter tcp: do not send too big packets at retransmit time ibmvnic: fix to use list_for_each_safe() when delete items net: thunderx: Fix TL4 configuration for secondary Qsets net: thunderx: Fix link status reporting net/mlx5e: Reorganize ethtool statistics net/mlx5e: Fix number of PFC counters reported to ethtool net/mlx5e: Prevent adding the same vxlan port net/mlx5e: Check for BlueFlame capability before allocating SQ uar net/mlx5e: Change enum to better reflect usage net/mlx5: Add ConnectX-5 PCIe 4.0 to list of supported devices net/mlx5: Update command strings net: marvell: Add separate config ANEG function for Marvell 88E1111 ... commit 653c574a7df4760442162272169834d63c33f298 Merge: 00bf377 bcf4dd5 Author: Linus Torvalds Date: Wed Jun 29 11:48:05 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux Pull s390 fixes from Martin Schwidefsky: "Another two bug fixes for 4.7: - The revert of patch which removed boot information for systems using an intermediate boot kernel, e.g. the SLES12 grub setup. - A fix for an incorrect inline assembly constraint that causes broken code to be generated with gcc 4.8.5" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: s390: fix test_fp_ctl inline assembly contraints Revert "s390/kdump: Clear subchannel ID to signal non-CCW/SCSI IPL" commit 4f14f5c11db161ab89b02f7196496ca32ca5dbf8 Author: Alexander Shiyan Date: Sat Jun 25 07:59:22 2016 +0300 ASoC: fsl_ssi: Fix number of words per frame for I2S-slave mode The i.MX51 datasheet says: Chapter 56.1.2.4 I2S Mode ... When I2S modes are entered (I2S master (01) or I2S slave (10)), the following settings are recommended: ... - TX Frame Rate should be 2 i.e. (STCCR[12:8] = 1) - RX Frame Rate should be 2 i.e. (SRCCR[12:8] = 1) Chapter 56.3.3.12 SSI Transmit and Receive Clock Control Registers (STCCR & SRCCR) ... Bits 12-8 DC4-DC0 Frame Rate Divider Control. These bits are used to control the divide ratio for the programmable frame rate dividers. The divide ratio works on the word clock. In Normal mode, this ratio determines the word transfer rate. In Network mode, this ratio sets the number of words per frame. The divide ratio ranges from 1 to 32 in Normal mode and from 2 to 32 in Network mode. In Normal mode, a divide ratio of 1 (DC=00000) provides continuous periodic data word transfer. A bit-length frame sync must be used in this case. Function fsl_ssi_hw_params() setup Normal mode for MONO output, so with DC=0, SSI enters to continuous periodic data word transfer. To fix this, setup DC for any I2S mode. Patch has tested on custom board based on Digi CCMX-51 module (i.MX51). Signed-off-by: Alexander Shiyan Signed-off-by: Mark Brown sound/soc/fsl/fsl_ssi.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 1bcbf42d2732b3fdaa8559b0dfc91567769e23c8 Author: Dan Williams Date: Wed Jun 29 11:19:32 2016 -0700 nfit: fix format interface code byte order Per JEDEC Annex L Release 3 the SPD data is: Bits 9~5 00 000 = Function Undefined 00 001 = Byte addressable energy backed 00 010 = Block addressed 00 011 = Byte addressable, no energy backed All other codes reserved Bits 4~0 0 0000 = Proprietary interface 0 0001 = Standard interface 1 All other codes reserved; see Definitions of Functions ...and per the ACPI 6.1 spec: byte0: Bits 4~0 (0 or 1) byte1: Bits 9~5 (1, 2, or 3) ...so a format interface code displayed as 0x301 should be stored in the nfit as (0x1, 0x3), little-endian. Cc: Toshi Kani Cc: Rafael J. Wysocki Cc: Robert Moore Cc: Robert Elliott Link: https://bugzilla.kernel.org/show_bug.cgi?id=121161 Fixes: 30ec5fd464d5 ("nfit: fix format interface code byte order per ACPI6.1") Fixes: 5ad9a7fde07a ("acpi/nfit: Update nfit driver to comply with ACPI 6.1") Reported-by: Kristin Jacque Signed-off-by: Dan Williams drivers/acpi/nfit.c | 6 +++--- drivers/acpi/nfit.h | 10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) commit 91ff811f32763ea3135e832f7c1aeafc85ae1c98 Author: Venkat Reddy Talla Date: Wed Jun 29 15:31:27 2016 +0530 regulator: max77620: check for valid regulator info SD4 regulator is not registered with regulator core framework in probe as there is no support in MAX77620 PMIC, removing SD4 entry from MAX77620 regulator information list and checking for valid regulator information data before configuring FPS source and FPS power up/down period to avoid NULL pointer exception if regulator not registered with core. Signed-off-by: Venkat Reddy Talla Signed-off-by: Mark Brown drivers/regulator/max77620-regulator.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit caca925fca4fb30c67be88cacbe908eec6721e43 Author: Cameron Gutman Date: Wed Jun 29 09:51:35 2016 -0700 Input: xpad - validate USB endpoint count during probe This prevents a malicious USB device from causing an oops. Signed-off-by: Cameron Gutman Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/joystick/xpad.c | 3 +++ 1 file changed, 3 insertions(+) commit 00bf377d19ad3d80cbc7a036521279a86e397bfb Merge: 52827f3 b41aa4f Author: Linus Torvalds Date: Wed Jun 29 10:05:44 2016 -0700 Merge tag 'pinctrl-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Pull pin control fixes from Linus Walleij: "Here are a bunch of fixes for pin control. Just drivers and a MAINTAINERS fixup: - Driver fixes for i.MX, single register, Tegra and BayTrail. - MAINTAINERS entry for the documentation" * tag 'pinctrl-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: pinctrl: baytrail: Fix mingled clock pins MAINTAINERS: belong Documentation/pinctrl.txt properly pinctrl: tegra: Fix build dependency gpio: tegra: Make lockdep class file-scoped pinctrl: single: Fix missing flush of posted write for a wakeirq pinctrl: imx: Do not treat a PIN without MUX register as an error commit 52827f389b32f6d04a1bcb4428b5499815c36a24 Merge: de4921c 82d6489 Author: Linus Torvalds Date: Wed Jun 29 10:04:42 2016 -0700 Merge branch 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup Pull cgroup fixes from Tejun Heo: "Three fix patches. Two are for cgroup / css init failure path. The last one makes css_set_lock irq-safe as the deadline scheduler ends up calling put_css_set() from irq context" * 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup: cgroup: Disable IRQs while holding css_set_lock cgroup: set css->id to -1 during init cgroup: remove redundant cleanup in css_create commit 9a9b6aa6a8759c83024627d681eff982d6ee03b7 Author: Douglas Anderson Date: Tue Jun 28 10:32:00 2016 -0700 Input: add SW_PEN_INSERTED define Some devices with a pen may have a switch that can be used to detect when the pen is inserted or removed to a slot on the device. Let's add a define to the input event codes so that everyone can be on the same page for what event we should generate when the pen is inserted or removed. In general the pen switch could be used by the software on the device to kick off any number of actions when the pen is inserted or removed. Signed-off-by: Douglas Anderson Signed-off-by: Dmitry Torokhov include/uapi/linux/input-event-codes.h | 1 + 1 file changed, 1 insertion(+) commit 7b427a59538a98161321aa46c13f4ea81b43f4eb Author: Bob Liu Date: Mon Jun 27 16:33:24 2016 +0800 xen-blkfront: save uncompleted reqs in blkfront_resume() Uncompleted reqs used to be 'saved and resubmitted' in blkfront_recover() during migration, but that's too late after multi-queue was introduced. After a migrate to another host (which may not have multiqueue support), the number of rings (block hardware queues) may be changed and the ring and shadow structure will also be reallocated. The blkfront_recover() then can't 'save and resubmit' the real uncompleted reqs because shadow structure have been reallocated. This patch fixes this issue by moving the 'save' logic out of blkfront_recover() to earlier place in blkfront_resume(). The 'resubmit' is not changed and still in blkfront_recover(). Signed-off-by: Bob Liu Signed-off-by: Konrad Rzeszutek Wilk Cc: stable@vger.kernel.org drivers/block/xen-blkfront.c | 91 +++++++++++++++++++------------------------- 1 file changed, 40 insertions(+), 51 deletions(-) commit b3a3c5176c146ec7de653a3062237620464175fb Author: Xin Long Date: Fri May 13 01:51:55 2016 +0800 ixgbevf: ixgbevf_write/read_posted_mbx should use IXGBE_ERR_MBX to initialize ret_val Now ixgbevf_write/read_posted_mbx use -IXGBE_ERR_MBX as the initiative return value, but it's incorrect, cause in ixgbevf_vlan_rx_add_vid(), it use err == IXGBE_ERR_MBX, the err returned from mac.ops.set_vfta, and in ixgbevf_set_vfta_vf, it return from write/read_posted. so we should initialize err with IXGBE_ERR_MBX, instead of -IXGBE_ERR_MBX. With this fix, the other functions that called it also can work well, cause they only care about if err is 0 or not. Signed-off-by: Xin Long Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/ixgbevf/mbx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a7f14a184e0e8e94becfc3f9608f6b0f9c339572 Author: Rex Zhu Date: Tue Jun 28 16:22:07 2016 +0800 drm/amd/powerplay: workaround for UVD clock issue workaround issue that when uvd dpm disabled, uvd clock remain high on polaris10. Manually turn off the clocks. Signed-off-by: Rex Zhu Reviewed-by: Ken Wang Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 4 ++++ 1 file changed, 4 insertions(+) commit d9d533c1483c4daf76e7e720c35896a430563ff8 Author: Ken Wang Date: Tue Jun 28 13:28:50 2016 +0800 drm/amdgpu: add ACLK_CNTL setting for polaris10 This is a temporary workaround for early boards. Signed-off-by: Ken Wang Reviewed-by: Rex Zhu Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 3 +++ 1 file changed, 3 insertions(+) commit 838086414b3cda5c592591f2b82256996306dab6 Author: Jarod Wilson Date: Thu Jun 9 19:50:13 2016 -0400 e1000e: keep Rx/Tx HW_VLAN_CTAG in sync The bit in the e1000 driver that mentions explicitly that the hardware has no support for separate RX/TX VLAN accel toggling rings true for e1000e as well, and thus both NETIF_F_HW_VLAN_CTAG_RX and NETIF_F_HW_VLAN_CTAG_TX need to be kept in sync. Revert a portion of commit 889ad456660461 ("e1000e: keep VLAN interfaces functional after rxvlan off") since keeping the bits in sync resolves the original issue. Signed-off-by: Jarod Wilson Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher drivers/net/ethernet/intel/e1000e/netdev.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) commit 0636e0d666e0238fa22348172c20a49f42a94395 Author: Rex Zhu Date: Mon Jun 27 17:30:24 2016 +0800 drm/amd/powerplay: fix issue uvd dpm can't enabled on Polaris11. 1. Populate correct value of VDDCI voltage for SMC SAMU, VCE, and UVD levels depending on whether VDDCi control is SVI2 or GPIO. 2. Populate SMC ACPI minimum voltage using VBIOS boot SCLK and MCLK When static voltage is configured as VDDCI, driver still tries to program a voltage for MM minVoltage using VDDC-VDDCI delta requirement. minVoltage should be set as boot up voltage. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 101 ++++++++++++--------- 1 file changed, 60 insertions(+), 41 deletions(-) commit 3a8bd717ee3e0508fc0dd517b97e950989e15f8c Author: Rex Zhu Date: Mon Jun 27 14:46:47 2016 +0800 drm/amd/powerplay: Workaround for Memory EDC Error on Polaris10. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 03bea60409328de54e4ff7ec41672e12a9cb0908 Author: Miklos Szeredi Date: Wed Jun 29 16:03:55 2016 +0200 ovl: get_write_access() in truncate When truncating a file we should check write access on the underlying inode. And we should do so on the lower file as well (before copy-up) for consistency. Original patch and test case by Aihua Zhang. - - >o >o - - test.c - - >o >o - - #include #include #include int main(int argc, char *argv[]) { int ret; ret = truncate(argv[0], 4096); if (ret != -1) { fprintf(stderr, "truncate(argv[0]) should have failed\n"); return 1; } if (errno != ETXTBSY) { perror("truncate(argv[0])"); return 1; } return 0; } - - >o >o - - >o >o - - >o >o - - Reported-by: Aihua Zhang Signed-off-by: Miklos Szeredi Cc: fs/overlayfs/inode.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit 62db7152c924e4c060e42b34a69cd39658e8a0dc Author: Takashi Iwai Date: Wed Jun 29 15:23:08 2016 +0200 ALSA: au88x0: Fix calculation in vortex_wtdma_bufshift() vortex_wtdma_bufshift() function does calculate the page index wrongly, first masking then shift, which always results in zero. The proper computation is to first shift, then mask. Reported-by: Dan Carpenter Cc: Signed-off-by: Takashi Iwai sound/pci/au88x0/au88x0_core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 751ad819b0bf443ad8963eb7bfbd533e6a463973 Merge: d913d3a c041778 Author: David S. Miller Date: Wed Jun 29 08:33:46 2016 -0400 Merge tag 'mac80211-for-davem-2016-06-29-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211 Johannes Berg says: ==================== Just two small fixes * fix mesh peer link counter, decrement wasn't always done at all * fix ethertype (length) for packets without RFC 1042 or bridge tunnel header ==================== Signed-off-by: David S. Miller commit d913d3a763a6f66a862a6eafcf6da89a7905832a Author: Samuel Gauthier Date: Tue Jun 28 17:22:26 2016 +0200 openvswitch: fix conntrack netlink event delivery Only the first and last netlink message for a particular conntrack are actually sent. The first message is sent through nf_conntrack_confirm when the conntrack is committed. The last one is sent when the conntrack is destroyed on timeout. The other conntrack state change messages are not advertised. When the conntrack subsystem is used from netfilter, nf_conntrack_confirm is called for each packet, from the postrouting hook, which in turn calls nf_ct_deliver_cached_events to send the state change netlink messages. This commit fixes the problem by calling nf_ct_deliver_cached_events in the non-commit case as well. Fixes: 7f8a436eaa2c ("openvswitch: Add conntrack action") CC: Joe Stringer CC: Justin Pettit CC: Andy Zhou CC: Thomas Graf Signed-off-by: Samuel Gauthier Acked-by: Joe Stringer Signed-off-by: David S. Miller net/openvswitch/conntrack.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 34c7bb4705a0a2d344b0c82eaf3d3bfa2bc9da45 Author: Sudarsana Reddy Kalluru Date: Tue Jun 28 07:46:03 2016 -0400 qed: Protect the doorbell BAR with the write barriers. SPQ doorbell is currently protected with the compilation barrier. Under the stress scenarios, we may get into a state where (due to the weak ordering) several ramrod doorbells were written to the BAR with an out-of-order producer values. Need to change the barrier type to a write barrier to make sure that the write buffer is flushed after each doorbell. Signed-off-by: Sudarsana Reddy Kalluru Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_spq.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit b560f03ddfb072bca65e9440ff0dc4f9b1d1f056 Author: David Barroso Date: Tue Jun 28 11:16:43 2016 +0300 neigh: Explicitly declare RCU-bh read side critical section in neigh_xmit() neigh_xmit() expects to be called inside an RCU-bh read side critical section, and while one of its two current callers gets this right, the other one doesn't. More specifically, neigh_xmit() has two callers, mpls_forward() and mpls_output(), and while both callers call neigh_xmit() under rcu_read_lock(), this provides sufficient protection for neigh_xmit() only in the case of mpls_forward(), as that is always called from softirq context and therefore doesn't need explicit BH protection, while mpls_output() can be called from process context with softirqs enabled. When mpls_output() is called from process context, with softirqs enabled, we can be preempted by a softirq at any time, and RCU-bh considers the completion of a softirq as signaling the end of any pending read-side critical sections, so if we do get a softirq while we are in the part of neigh_xmit() that expects to be run inside an RCU-bh read side critical section, we can end up with an unexpected RCU grace period running right in the middle of that critical section, making things go boom. This patch fixes this impedance mismatch in the callee, by making neigh_xmit() always take rcu_read_{,un}lock_bh() around the code that expects to be treated as an RCU-bh read side critical section, as this seems a safer option than fixing it in the callers. Fixes: 4fd3d7d9e868f ("neigh: Add helper function neigh_xmit") Signed-off-by: David Barroso Signed-off-by: Lennert Buytenhek Acked-by: David Ahern Acked-by: Robert Shearman Signed-off-by: David S. Miller net/core/neighbour.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 889ad4566604610804df984e1a3dd5e2c66256e5 Author: Jarod Wilson Date: Tue Jun 28 20:41:31 2016 -0700 e1000e: keep VLAN interfaces functional after rxvlan off I've got a bug report about an e1000e interface, where a VLAN interface is set up on top of it: $ ip link add link ens1f0 name ens1f0.99 type vlan id 99 $ ip link set ens1f0 up $ ip link set ens1f0.99 up $ ip addr add 192.168.99.92 dev ens1f0.99 At this point, I can ping another host on vlan 99, ip 192.168.99.91. However, if I do the following: $ ethtool -K ens1f0 rxvlan off Then no traffic passes on ens1f0.99. It comes back if I toggle rxvlan on again. I'm not sure if this is actually intended behavior, or if there's a lack of software VLAN stripping fallback, or what, but things continue to work if I simply don't call e1000e_vlan_strip_disable() if there are active VLANs (plagiarizing a function from the e1000 driver here) on the interface. Also slipped a related-ish fix to the kerneldoc text for e1000e_vlan_strip_disable here... Signed-off-by: Jarod Wilson Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher Signed-off-by: David S. Miller drivers/net/ethernet/intel/e1000e/netdev.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit c041778c966c92c964033f1cdfee60a9f2b5e465 Author: Felix Fietkau Date: Wed Jun 29 10:36:39 2016 +0200 cfg80211: fix proto in ieee80211_data_to_8023 for frames without LLC header The PDU length of incoming LLC frames is set to the total skb payload size in __ieee80211_data_to_8023() of net/wireless/util.c which incorrectly includes the length of the IEEE 802.11 header. The resulting LLC frame header has a too large PDU length, causing the llc_fixup_skb() function of net/llc/llc_input.c to reject the incoming skb, effectively breaking STP. Solve the problem by properly substracting the IEEE 802.11 frame header size from the PDU length, allowing the LLC processor to pick up the incoming control messages. Special thanks to Gerry Rozema for tracking down the regression and proposing a suitable patch. Fixes: 2d1c304cb2d5 ("cfg80211: add function for 802.3 conversion with separate output buffer") Cc: stable@vger.kernel.org Reported-by: Gerry Rozema Signed-off-by: Felix Fietkau Signed-off-by: Johannes Berg net/wireless/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6858107e78b4ecb9f244db814ffbdba1b5ce759b Author: Vinod Koul Date: Wed Jun 29 10:27:52 2016 +0530 ALSA: hda - Add PCI ID for Kabylake-H Kabylake-H shows up as PCI ID 0xa2f0. We missed adding this earlier with other KBL IDs. Signed-off-by: Vinod Koul Cc: Signed-off-by: Takashi Iwai sound/pci/hda/hda_intel.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 5b4d10f5e0369ed79434593b7cd8e85eebbe473f Author: Dan Carpenter Date: Mon Jun 27 23:50:29 2016 +0300 qlcnic: use the correct ring in qlcnic_83xx_process_rcv_ring_diag() There is a static checker warning here "warn: mask and shift to zero" and the code sets "ring" to zero every time. From looking at how QLCNIC_FETCH_RING_ID() is used in qlcnic_83xx_process_rcv_ring() the qlcnic_83xx_hndl() should be removed. Fixes: 4be41e92f7c6 ('qlcnic: 83xx data path routines') Signed-off-by: Dan Carpenter Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qlcnic/qlcnic_io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ceb56070359b7329b5678b5d95a376fcb24767be Author: Daniel Borkmann Date: Mon Jun 27 21:38:11 2016 +0200 bpf, perf: delay release of BPF prog after grace period Commit dead9f29ddcc ("perf: Fix race in BPF program unregister") moved destruction of BPF program from free_event_rcu() callback to __free_event(), which is problematic if used with tail calls: if prog A is attached as trace event directly, but at the same time present in a tail call map used by another trace event program elsewhere, then we need to delay destruction via RCU grace period since it can still be in use by the program doing the tail call (the prog first needs to be dropped from the tail call map, then trace event with prog A attached destroyed, so we get immediate destruction). Fixes: dead9f29ddcc ("perf: Fix race in BPF program unregister") Signed-off-by: Daniel Borkmann Acked-by: Alexei Starovoitov Cc: Jann Horn Signed-off-by: David S. Miller include/linux/bpf.h | 4 ++++ kernel/events/core.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) commit 565ce8f32ac4a233b474f401e1d3e7e1de0a31fd Author: Nikolay Aleksandrov Date: Mon Jun 27 18:34:42 2016 +0200 net: bridge: fix vlan stats continue counter I made a dumb off-by-one mistake when I added the vlan stats counter dumping code. The increment should happen before the check, not after otherwise we miss one entry when we continue dumping. Fixes: a60c090361ea ("bridge: netlink: export per-vlan stats") Signed-off-by: Nikolay Aleksandrov Signed-off-by: David S. Miller net/bridge/br_netlink.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a3d2e9f8eb1487f4191ff08ce2d3d63702c65a90 Author: Eric Dumazet Date: Mon Jun 27 17:38:50 2016 +0200 tcp: do not send too big packets at retransmit time Arjun reported a bug in TCP stack and bisected it to a recent commit. In case where we process SACK, we can coalesce multiple skbs into fat ones (tcp_shift_skb_data()), to lower write queue overhead, because we do not expect to retransmit these packets. However, SACK reneging can happen, forcing the sender to retransmit all these packets. If skb->len is above 64KB, we then send buggy IP packets that could hang TSO engine on cxgb4. Neal suggested to use tcp_tso_autosize() instead of tp->gso_segs so that we cook packets of optimal size vs TCP/pacing. Thanks to Arjun for reporting the bug and running the tests ! Fixes: 10d3be569243 ("tcp-tso: do not split TSO packets at retransmit time") Signed-off-by: Eric Dumazet Reported-by: Arjun V Tested-by: Arjun V Acked-by: Neal Cardwell Signed-off-by: David S. Miller net/ipv4/tcp_output.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 96183182ad05d1ce31b9048921c12bf4ad621eaf Author: Wei Yongjun Date: Mon Jun 27 20:48:53 2016 +0800 ibmvnic: fix to use list_for_each_safe() when delete items Since we will remove items off the list using list_del() we need to use a safe version of the list_for_each() macro aptly named list_for_each_safe(). Signed-off-by: Wei Yongjun Signed-off-by: David S. Miller drivers/net/ethernet/ibm/ibmvnic.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 6b9dc6a474fd4e025c615ed4582735360005727c Author: Rodrigo Vivi Date: Thu Jun 23 14:50:36 2016 -0700 drm/i915: Removing PCI IDs that are no longer listed as Kabylake. This is unusual. Usually IDs listed on early stages of platform definition are kept there as reserved for later use. However these IDs here are not listed anymore in any of steppings and devices IDs tables for Kabylake on configurations overview section of BSpec. So it is better removing them before they become used in any other future platform. Signed-off-by: Rodrigo Vivi Reviewed-by: Dhinakaran Pandiyan Link: http://patchwork.freedesktop.org/patch/msgid/1466718636-19675-2-git-send-email-rodrigo.vivi@intel.com (cherry picked from commit a922eb8d4581c883c37ce6e12dca9ff2cb1ea723) Signed-off-by: Jani Nikula include/drm/i915_pciids.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit 42482b4546336ecd93acdd95e435bafd7a4c581c Author: Rodrigo Vivi Date: Thu Jun 23 14:50:35 2016 -0700 drm/i915: Add more Kabylake PCI IDs. The spec has been updated adding new PCI IDs. Signed-off-by: Rodrigo Vivi Reviewed-by: Dhinakaran Pandiyan Link: http://patchwork.freedesktop.org/patch/msgid/1466718636-19675-1-git-send-email-rodrigo.vivi@intel.com (cherry picked from commit 33d9391d3020e069dca98fa87a604c037beb2b9e) Signed-off-by: Jani Nikula include/drm/i915_pciids.h | 3 +++ 1 file changed, 3 insertions(+) commit b2c1b30e3e6dea37d5a7176bd09cf5967fb43665 Merge: f5074d0 3e29adb Author: David S. Miller Date: Wed Jun 29 05:14:19 2016 -0400 Merge branch 'thunderx-fixes' Sunil Goutham says: ==================== net: thunderx: Miscellaneous fixes This 2 patch series fixes issues w.r.t physical link status reporting and transmit datapath configuration for secondary qsets. Changes from v1: Fixed lmac disable sequence for interfaces of type SGMII. ==================== Signed-off-by: David S. Miller commit 3e29adba567306504e99b8363edf2d47c19dbe1b Author: Sunil Goutham Date: Mon Jun 27 15:30:03 2016 +0530 net: thunderx: Fix TL4 configuration for secondary Qsets TL4 calculation for a given SQ of secondary Qsets is incorrect and goes out of bounds and also for some SQ's TL4 chosen will transmit data via a different BGX interface and not same as primary Qset's interface. This patch fixes this issue. Signed-off-by: Sunil Goutham Signed-off-by: David S. Miller drivers/net/ethernet/cavium/thunder/nic_main.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 3f4c68cfde30caa1f6d8368fd19590671411ade2 Author: Sunil Goutham Date: Mon Jun 27 15:30:02 2016 +0530 net: thunderx: Fix link status reporting Check for SMU RX local/remote faults along with SPU LINK status. Otherwise at times link is UP at our end but DOWN at link partner's side. Also due to an issue in BGX it's rarely seen that initialization doesn't happen properly and SMU RX reports faults with everything fine at SPU. This patch tries to reinitialize LMAC to fix it. Also fixed LMAC disable sequence to properly bring down link. Signed-off-by: Sunil Goutham Signed-off-by: Tao Wang Signed-off-by: David S. Miller drivers/net/ethernet/cavium/thunder/thunder_bgx.c | 91 +++++++++++++++-------- drivers/net/ethernet/cavium/thunder/thunder_bgx.h | 2 + 2 files changed, 62 insertions(+), 31 deletions(-) commit f5074d0ce2f8b45b3d5998a280edd2066c0cfcda Merge: 3ec0a0f bfe6d8d Author: David S. Miller Date: Wed Jun 29 04:28:59 2016 -0400 Merge branch 'mlx5-100G-fixes' Saeed Mahameed says: ==================== Mellanox 100G mlx5 fixes#2 for 4.7-rc The following series provides one-liners fixes for mlx5 driver plus one medium patch to reorganize ethtool counters reporting. Highlights: - Added MODIFY_FLOW_TABLE to command strings table - Add ConnectX-5 PCIe 4.0 to list of supported devices - Rename ASYNC_EVENTS enum - Enable BlueFlame only when supported by device - Avoid adding same vxlan port twice - Report the correct number of PFC counters - Reorganize ethtool reported counters and remove duplications ==================== Signed-off-by: David S. Miller commit bfe6d8d1d433cbd5513a93132695e6dbdd79e6f2 Author: Gal Pressman Date: Mon Jun 27 12:08:38 2016 +0300 net/mlx5e: Reorganize ethtool statistics Categorize and reorganize ethtool statistics counters by renaming to "rx_*" and "tx_*" and removing redundant and duplicated counters, this way they are easier to grasp and more user friendly. Signed-off-by: Gal Pressman Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 30 ++- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 27 ++- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 4 +- drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 228 +++++++++------------ drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 4 +- 5 files changed, 130 insertions(+), 163 deletions(-) commit ed80ec4c179d1f44cc1b36c7a102353ae6103793 Author: Gal Pressman Date: Mon Jun 27 12:08:37 2016 +0300 net/mlx5e: Fix number of PFC counters reported to ethtool Number of PFC counters used to count only number of priorities with PFC enabled, but each priority has more than one counter, hence the need to multiply it by the number of PFC counters per priority. Fixes: cf678570d5a1 ('net/mlx5e: Add per priority group to PPort counters') Signed-off-by: Gal Pressman Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 9ceec359e4ebdbbfd35375203c5bd06d602225f7 Author: Matthew Finlay Date: Mon Jun 27 12:08:36 2016 +0300 net/mlx5e: Prevent adding the same vxlan port Do not allow the same vxlan udp port to be added to the device more than once. Fixes: b3f63c3d5e2c ("net/mlx5e: Add netdev support for VXLAN tunneling") Signed-off-by: Matthew Finlay Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/vxlan.c | 3 +++ 1 file changed, 3 insertions(+) commit fd4782c21359cfd52af4c3180a2bb6bad55c1eba Author: Gal Pressman Date: Mon Jun 27 12:08:35 2016 +0300 net/mlx5e: Check for BlueFlame capability before allocating SQ uar Previous to this patch mapping was always set to write combining without checking whether BlueFlame is supported in the device. Fixes: 0ba422410bbf ('net/mlx5: Fix global UAR mapping') Signed-off-by: Gal Pressman Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e0f46eb9f64ca2e97d242b6e02b8ae2c7fe6dc56 Author: Eli Cohen Date: Mon Jun 27 12:08:34 2016 +0300 net/mlx5e: Change enum to better reflect usage Change MLX5E_STATE_ASYNC_EVENTS_ENABLE to MLX5E_STATE_ASYNC_EVENTS_ENABLED since it represent a state and not an operation. Fixes: acff797cd1874 ('net/mlx5: Extend mlx5_core to support ConnectX-4 Ethernet functionality') Signed-off-by: Eli Cohen Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en.h | 2 +- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7092fe866907f4f243122ab388cbf0e77305afaa Author: Majd Dibbiny Date: Mon Jun 27 12:08:33 2016 +0300 net/mlx5: Add ConnectX-5 PCIe 4.0 to list of supported devices Add the upcoming ConnectX-5 PCIe 4.0 device to the list of supported devices by the mlx5 driver. Signed-off-by: Majd Dibbiny Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5be1ea899da4f11de92897d2ea706e0820609b9e Author: Eli Cohen Date: Mon Jun 27 12:08:32 2016 +0300 net/mlx5: Update command strings Add command string for MODIFY_FLOW_TABLE which is used by the driver. Signed-off-by: Eli Cohen Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 1 + 1 file changed, 1 insertion(+) commit ba34a65324259082dc6d2924cb82d562db1c6a6b Author: Imre Deak Date: Tue Jun 28 13:37:33 2016 +0300 drm/i915: Avoid early timeout during AUX transfers Since wait_for_atomic doesn't re-check the wait-for condition after expiry of the timeout it can fail when called from non-atomic context even if the condition is set correctly before the expiry. Fix this by using the non-atomic wait_for instead. Due to the relatively long 10ms timeout, probably this didn't cause any real problems, but fix it in any case for consistency. Fixes: 0351b93992aa ("drm/i915: Do not lie about atomic timeout granularity") CC: Chris Wilson CC: Tvrtko Ursulin Signed-off-by: Imre Deak Reviewed-by: Tvrtko Ursulin CC: drm-intel-fixes@lists.freedesktop.org Link: http://patchwork.freedesktop.org/patch/msgid/1467110253-16046-5-git-send-email-imre.deak@intel.com (cherry picked from commit 713a6b668932213247b394559bc229cd0fec2777) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fa7c13e5b1e2076b0ec716ed584ab76f9e65b7a6 Author: Imre Deak Date: Tue Jun 28 13:37:32 2016 +0300 drm/i915/hsw: Avoid early timeout during LCPLL disable/restore Since wait_for_atomic doesn't re-check the wait-for condition after expiry of the timeout it can fail when called from non-atomic context even if the condition is set correctly before the expiry. Fix this by using the non-atomic wait_for instead. Fixes: 0351b93992aa ("drm/i915: Do not lie about atomic timeout granularity") CC: Chris Wilson CC: Tvrtko Ursulin Signed-off-by: Imre Deak Reviewed-by: Tvrtko Ursulin CC: drm-intel-fixes@lists.freedesktop.org Link: http://patchwork.freedesktop.org/patch/msgid/1467110253-16046-4-git-send-email-imre.deak@intel.com (cherry picked from commit f53dd63f1119a98a16d1a5a7cb3277a2f1ff483d) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_display.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 11f6145791775ce41b8993fd29e19eb53ef0ff14 Author: Imre Deak Date: Tue Jun 28 13:37:31 2016 +0300 drm/i915/lpt: Avoid early timeout during FDI PHY reset Since wait_for_atomic doesn't re-check the wait-for condition after expiry of the timeout it can fail when called from non-atomic context even if the condition is set correctly before the expiry. Fix this by using the non-atomic wait_for instead. Fixes: 0351b93992aa ("drm/i915: Do not lie about atomic timeout granularity") CC: Chris Wilson CC: Tvrtko Ursulin Signed-off-by: Imre Deak Reviewed-by: Tvrtko Ursulin CC: drm-intel-fixes@lists.freedesktop.org Link: http://patchwork.freedesktop.org/patch/msgid/1467110253-16046-3-git-send-email-imre.deak@intel.com (cherry picked from commit cf3598c23cd09d5f063fa8c12fe9ddd5a352d3d5) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_display.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit ea12e2a0cad62f6d634da62e7bf50ffe077de13b Author: Imre Deak Date: Tue Jun 28 13:37:30 2016 +0300 drm/i915/bxt: Avoid early timeout during PLL enable Since wait_for_atomic doesn't re-check the wait-for condition after expiry of the timeout it can fail when called from non-atomic context even if the condition is set correctly before the expiry. Fix this by using the non-atomic wait_for instead. I noticed this via the PLL locking timing out incorrectly, with this fix I couldn't reproduce the problem. Fixes: 0351b93992aa ("drm/i915: Do not lie about atomic timeout granularity") CC: Chris Wilson CC: Tvrtko Ursulin Signed-off-by: Imre Deak Reviewed-by: Tvrtko Ursulin CC: drm-intel-fixes@lists.freedesktop.org Link: http://patchwork.freedesktop.org/patch/msgid/1467110253-16046-2-git-send-email-imre.deak@intel.com (cherry picked from commit 0b786e41c73956126f6297764459021deef8aba7) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_dpll_mgr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 664a84d2c77cbff2945ed7f96d08afbba42b6293 Author: Ville Syrjälä Date: Fri May 13 20:53:56 2016 +0300 drm/i915: Refresh cached DP port register value on resume During hibernation the cached DP port register value will be left with whatever value we have there when we create the hibernation image. Currently that means the port (and eDP PLL) will be off in the cached value. However when we resume there is no guarantee that the value in the actual register will match the cached value. If i915 isn't loaded in the kernel that loads the hibernation image, the port may well be on (eg. left on by the BIOS). The encoder state readout does the right thing in this case and updates our encoder state to reflect the actual hardware state. However the post-resume modeset will then use the stale cached port register value in intel_dp_link_down() and potentially confuse the hardware. This was caught by the following assert WARNING: CPU: 3 PID: 5288 at ../drivers/gpu/drm/i915/intel_dp.c:2184 assert_edp_pll+0x99/0xa0 [i915] eDP PLL state assertion failure (expected on, current off) on account of the eDP PLL getting prematurely turned off when shutting down the port, since the DP_PLL_ENABLE bit wasn't set in the cached register value. Presumably I introduced this problem in commit 6fec76628333 ("drm/i915: Use intel_dp->DP in eDP PLL setup") as before that we didn't update the cached value after shuttting the port down. That's assuming the port got enabled at least once prior to hibernating. If that didn't happen then the cached value would still have been totally out of sync with reality (eg. first boot w/o eDP on, then hibernate, and then resume with eDP on). So, let's fix this properly and refresh the cached register value from the hardware register during resume. DDI platforms shouldn't use the cached value during port disable at least, so shouldn't have this particular issue. They might still have issues if we skip the initial modeset and then try to retrain the link or something. But untangling this DP vs. DDI mess is a bigger topic, so let's jut punt on DDI for now. Cc: Jani Nikula Cc: stable@vger.kernel.org Fixes: 6fec76628333 ("drm/i915: Use intel_dp->DP in eDP PLL setup") Signed-off-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1463162036-27931-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak (cherry picked from commit 64989ca4b27acb026b6496ec21e43bee66f86a5b) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_dp.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 3ec0a0f10ceb77c78f540ded1d13bf0cf7f89a07 Author: Harini Katakam Date: Mon Jun 27 13:09:59 2016 +0530 net: marvell: Add separate config ANEG function for Marvell 88E1111 Marvell 88E1111 currently uses the generic marvell config ANEG function. This function has a sequence accessing Page 5 and Register 31, both of which are not defined or reserved for this PHY. Hence this patch adds a new config ANEG function for Marvell 88E1111 without these erroneous accesses. Signed-off-by: Harini Katakam Signed-off-by: David S. Miller drivers/net/phy/marvell.c | 44 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) commit d10f0b312adc21b9b78e36cf695e6157989ce041 Merge: 69fc58a 420cb1b Author: David S. Miller Date: Wed Jun 29 04:01:53 2016 -0400 Merge branch 'batman-adv-fixes' Sven Eckelmann says: ==================== batman-adv: Fixes for Linux 4.7 Antonio currently seems to be occupied. This is currently rather unfortunate because there are patches waiting in the batman-adv development repository maint(enance) branch [1] since up to 6 weeks. I am now getting asked when these patches will hit the distribution kernels and therefore decided to submit these patches directly to netdev. The patch from Simon works around the problem that warnings could be triggered in the translation table code via packets using a VLAN not configured on the target host. This warning was replaced with a rate limited info message. Ben Hutchings found an superfluous batadv_softif_vlan_put in the error handling code of the translation table while he backported the "batman-adv: Fix reference counting of vlan object for tt_local_entry" patch to the stable kernels. He noticed correctly that this batadv_softif_vlan_put should also have been removed by the said patch. The most requested fix at the moment is related to a double free in the translation table code. It is a race condition which mostly happens on systems with multiple cores and multiple network interface attached to batman-adv. Two Freifunk communities which were haunted by weird crashes (with backtraces reporting problems in other parts of the kernel) were kind enough to test this patch. They reported that there systems are now running stable after applying this patch. An invalid memory access was detected in the batadv_icmp_packet_rr handling code when receiving a skbuff with fragments. The last patch is fixing a memory leak when the interface is removed via .dellink. The code to fix it was copied from the code handling the legacy sysfs interface to remove netdevices from a batman-adv netdevice. There are still 28 patches in the development tree for v4.8 but I will leave them to Antonio because these are cleanups and features and therefore for net- next. ==================== Signed-off-by: David S. Miller commit 420cb1b764f9169c5d2601b4af90e4a1702345ee Author: Sven Eckelmann Date: Sun Jun 26 11:16:13 2016 +0200 batman-adv: Clean up untagged vlan when destroying via rtnl-link The untagged vlan object is only destroyed when the interface is removed via the legacy sysfs interface. But it also has to be destroyed when the standard rtnl-link interface is used. Fixes: 5d2c05b21337 ("batman-adv: add per VLAN interface attribute framework") Signed-off-by: Sven Eckelmann Acked-by: Antonio Quartulli Signed-off-by: Marek Lindner Signed-off-by: David S. Miller net/batman-adv/soft-interface.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 3b55e4422087f9f7b241031d758a0c65584e4297 Author: Sven Eckelmann Date: Sun Jun 26 11:16:12 2016 +0200 batman-adv: Fix ICMP RR ethernet access after skb_linearize The skb_linearize may reallocate the skb. This makes the calculated pointer for ethhdr invalid. But it the pointer is used later to fill in the RR field of the batadv_icmp_packet_rr packet. Instead re-evaluate eth_hdr after the skb_linearize+skb_cow to fix the pointer and avoid the invalid read. Fixes: da6b8c20a5b8 ("batman-adv: generalize batman-adv icmp packet handling") Signed-off-by: Sven Eckelmann Signed-off-by: Marek Lindner Signed-off-by: David S. Miller net/batman-adv/routing.c | 1 + 1 file changed, 1 insertion(+) commit baceced93274ff2f846eae991664f9094425ffa8 Author: Ben Hutchings Date: Sun Jun 26 11:16:11 2016 +0200 batman-adv: Fix double-put of vlan object Each batadv_tt_local_entry hold a single reference to a batadv_softif_vlan. In case a new entry cannot be added to the hash table, the error path puts the reference, but the reference will also now be dropped by batadv_tt_local_entry_release(). Fixes: a33d970d0b54 ("batman-adv: Fix reference counting of vlan object for tt_local_entry") Signed-off-by: Ben Hutchings Signed-off-by: Marek Lindner Signed-off-by: Sven Eckelmann Signed-off-by: David S. Miller net/batman-adv/translation-table.c | 1 - 1 file changed, 1 deletion(-) commit 9c4604a298e0a9807eaf2cd912d1ebf24d98fbeb Author: Sven Eckelmann Date: Sun Jun 26 11:16:10 2016 +0200 batman-adv: Fix use-after-free/double-free of tt_req_node The tt_req_node is added and removed from a list inside a spinlock. But the locking is sometimes removed even when the object is still referenced and will be used later via this reference. For example batadv_send_tt_request can create a new tt_req_node (including add to a list) and later re-acquires the lock to remove it from the list and to free it. But at this time another context could have already removed this tt_req_node from the list and freed it. CPU#0 batadv_batman_skb_recv from net_device 0 -> batadv_iv_ogm_receive -> batadv_iv_ogm_process -> batadv_iv_ogm_process_per_outif -> batadv_tvlv_ogm_receive -> batadv_tvlv_ogm_receive -> batadv_tvlv_containers_process -> batadv_tvlv_call_handler -> batadv_tt_tvlv_ogm_handler_v1 -> batadv_tt_update_orig -> batadv_send_tt_request -> batadv_tt_req_node_new spin_lock(...) allocates new tt_req_node and adds it to list spin_unlock(...) return tt_req_node CPU#1 batadv_batman_skb_recv from net_device 1 -> batadv_recv_unicast_tvlv -> batadv_tvlv_containers_process -> batadv_tvlv_call_handler -> batadv_tt_tvlv_unicast_handler_v1 -> batadv_handle_tt_response spin_lock(...) tt_req_node gets removed from list and is freed spin_unlock(...) CPU#0 <- returned to batadv_send_tt_request spin_lock(...) tt_req_node gets removed from list and is freed MEMORY CORRUPTION/SEGFAULT/... spin_unlock(...) This can only be solved via reference counting to allow multiple contexts to handle the list manipulation while making sure that only the last context holding a reference will free the object. Fixes: a73105b8d4c7 ("batman-adv: improved client announcement mechanism") Signed-off-by: Sven Eckelmann Tested-by: Martin Weinelt Tested-by: Amadeus Alfa Signed-off-by: Marek Lindner Signed-off-by: David S. Miller net/batman-adv/translation-table.c | 43 ++++++++++++++++++++++++++++++++------ net/batman-adv/types.h | 2 ++ 2 files changed, 39 insertions(+), 6 deletions(-) commit 0b3dd7dfb81ad8af53791ea2bb64b83bac1b7d32 Author: Simon Wunderlich Date: Sun Jun 26 11:16:09 2016 +0200 batman-adv: replace WARN with rate limited output on non-existing VLAN If a VLAN tagged frame is received and the corresponding VLAN is not configured on the soft interface, it will splat a WARN on every packet received. This is a quite annoying behaviour for some scenarios, e.g. if bat0 is bridged with eth0, and there are arbitrary VLAN tagged frames from Ethernet coming in without having any VLAN configuration on bat0. The code should probably create vlan objects on the fly and transparently transport these VLAN-tagged Ethernet frames, but until this is done, at least the WARN splat should be replaced by a rate limited output. Fixes: 354136bcc3c4 ("batman-adv: fix kernel crash due to missing NULL checks") Signed-off-by: Simon Wunderlich Signed-off-by: Marek Lindner Signed-off-by: Sven Eckelmann Signed-off-by: David S. Miller net/batman-adv/translation-table.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 69fc58a57e56bf5e39b48809aefffdaa1b04c945 Author: Florian Fainelli Date: Fri Jun 24 16:25:24 2016 -0700 net: phy: Manage fixed PHY address space using IDA If we have a system which uses fixed PHY devices and calls fixed_phy_register() then fixed_phy_unregister() we can exhaust the number of fixed PHYs available after a while, since we keep incrementing the variable phy_fixed_addr, but we never decrement it. This patch fixes that by converting the fixed PHY allocation to using IDA, which takes care of the allocation/dealloaction of the PHY addresses for us. Fixes: a75951217472 ("net: phy: extend fixed driver with fixed_phy_register()") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/phy/fixed_phy.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit eee25ab19de632af1ab4d2ac50bfc5006802e664 Author: Hans de Goede Date: Tue Jun 28 22:11:14 2016 +0200 ARM: dts: sun7i: Fix pll3x2 and pll7x2 not having a parent clock Fix pll3x2 and pll7x2 not having a parent clock, specifically this fixes the kernel turning of pll3 while simplefb is using it when uboot has configured things to use pll3x2 as lcd ch clk parent. Signed-off-by: Hans de Goede Signed-off-by: Maxime Ripard arch/arm/boot/dts/sun7i-a20.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit a4859d75944a726533ab86d24bb5ffd1b2b7d6cc Author: Miklos Szeredi Date: Wed Jun 29 08:26:59 2016 +0200 ovl: fix dentry leak for default_permissions When using the 'default_permissions' mount option, ovl_permission() on non-directories was missing a dput(alias), resulting in "BUG Dentry still in use". Signed-off-by: Miklos Szeredi Fixes: 8d3095f4ad47 ("ovl: default permissions") Cc: # v4.5+ fs/overlayfs/inode.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 190ce8693c23eae09ba5f303a83bf2fbeb6478b1 Author: Michael Neuling Date: Tue Jun 28 13:01:04 2016 +1000 powerpc/tm: Avoid SLB faults in treclaim/trecheckpoint when RI=0 Currently we have 2 segments that are bolted for the kernel linear mapping (ie 0xc000... addresses). This is 0 to 1TB and also the kernel stacks. Anything accessed outside of these regions may need to be faulted in. (In practice machines with TM always have 1T segments) If a machine has < 2TB of memory we never fault on the kernel linear mapping as these two segments cover all physical memory. If a machine has > 2TB of memory, there may be structures outside of these two segments that need to be faulted in. This faulting can occur when running as a guest as the hypervisor may remove any SLB that's not bolted. When we treclaim and trecheckpoint we have a window where we need to run with the userspace GPRs. This means that we no longer have a valid stack pointer in r1. For this window we therefore clear MSR RI to indicate that any exceptions taken at this point won't be able to be handled. This means that we can't take segment misses in this RI=0 window. In this RI=0 region, we currently access the thread_struct for the process being context switched to or from. This thread_struct access may cause a segment fault since it's not guaranteed to be covered by the two bolted segment entries described above. We've seen this with a crash when running as a guest with > 2TB of memory on PowerVM: Unrecoverable exception 4100 at c00000000004f138 Oops: Unrecoverable exception, sig: 6 [#1] SMP NR_CPUS=2048 NUMA pSeries CPU: 1280 PID: 7755 Comm: kworker/1280:1 Tainted: G X 4.4.13-46-default #1 task: c000189001df4210 ti: c000189001d5c000 task.ti: c000189001d5c000 NIP: c00000000004f138 LR: 0000000010003a24 CTR: 0000000010001b20 REGS: c000189001d5f730 TRAP: 4100 Tainted: G X (4.4.13-46-default) MSR: 8000000100001031 CR: 24000048 XER: 00000000 CFAR: c00000000004ed18 SOFTE: 0 GPR00: ffffffffc58d7b60 c000189001d5f9b0 00000000100d7d00 000000003a738288 GPR04: 0000000000002781 0000000000000006 0000000000000000 c0000d1f4d889620 GPR08: 000000000000c350 00000000000008ab 00000000000008ab 00000000100d7af0 GPR12: 00000000100d7ae8 00003ffe787e67a0 0000000000000000 0000000000000211 GPR16: 0000000010001b20 0000000000000000 0000000000800000 00003ffe787df110 GPR20: 0000000000000001 00000000100d1e10 0000000000000000 00003ffe787df050 GPR24: 0000000000000003 0000000000010000 0000000000000000 00003fffe79e2e30 GPR28: 00003fffe79e2e68 00000000003d0f00 00003ffe787e67a0 00003ffe787de680 NIP [c00000000004f138] restore_gprs+0xd0/0x16c LR [0000000010003a24] 0x10003a24 Call Trace: [c000189001d5f9b0] [c000189001d5f9f0] 0xc000189001d5f9f0 (unreliable) [c000189001d5fb90] [c00000000001583c] tm_recheckpoint+0x6c/0xa0 [c000189001d5fbd0] [c000000000015c40] __switch_to+0x2c0/0x350 [c000189001d5fc30] [c0000000007e647c] __schedule+0x32c/0x9c0 [c000189001d5fcb0] [c0000000007e6b58] schedule+0x48/0xc0 [c000189001d5fce0] [c0000000000deabc] worker_thread+0x22c/0x5b0 [c000189001d5fd80] [c0000000000e7000] kthread+0x110/0x130 [c000189001d5fe30] [c000000000009538] ret_from_kernel_thread+0x5c/0xa4 Instruction dump: 7cb103a6 7cc0e3a6 7ca222a6 78a58402 38c00800 7cc62838 08860000 7cc000a6 38a00006 78c60022 7cc62838 0b060000 7ccff120 e8270078 e8a70098 ---[ end trace 602126d0a1dedd54 ]--- This fixes this by copying the required data from the thread_struct to the stack before we clear MSR RI. Then once we clear RI, we only access the stack, guaranteeing there's no segment miss. We also tighten the region over which we set RI=0 on the treclaim() path. This may have a slight performance impact since we're adding an mtmsr instruction. Fixes: 090b9284d725 ("powerpc/tm: Clear MSR RI in non-recoverable TM code") Signed-off-by: Michael Neuling Reviewed-by: Cyril Bur Signed-off-by: Michael Ellerman arch/powerpc/kernel/tm.S | 61 ++++++++++++++++++++++++++++++++++-------------- 1 file changed, 44 insertions(+), 17 deletions(-) commit 5e7ff2ca7f2da55fe777167849d0c93403bd0dc8 Author: Alan Stern Date: Thu Jun 23 15:05:26 2016 -0400 SCSI: fix new bug in scsi_dev_info_list string matching Commit b704f70ce200 ("SCSI: fix bug in scsi_dev_info_list matching") changed the way vendor- and model-string matching was carried out in the routine that looks up entries in a SCSI devinfo list. The new matching code failed to take into account the case of a maximum-length string; in such cases it could end up testing for a terminating '\0' byte beyond the end of the memory allocated to the string. This out-of-bounds bug was detected by UBSAN. I don't know if anybody has actually encountered this bug. The symptom would be that a device entry in the blacklist might not be matched properly if it contained an 8-character vendor name or a 16-character model name. Such entries certainly exist in scsi_static_device_list. This patch fixes the problem by adding a check for a maximum-length string before the '\0' test. Signed-off-by: Alan Stern Fixes: b704f70ce200 ("SCSI: fix bug in scsi_dev_info_list matching") Tested-by: Wilfried Klaebe CC: # v4.4+ Signed-off-by: Martin K. Petersen drivers/scsi/scsi_devinfo.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 54e430bbd490e18ab116afa4cd90dcc45787b3df Author: Brian King Date: Mon Jun 27 09:09:40 2016 -0500 ipr: Clear interrupt on croc/crocodile when running with LSI If we fall back to using LSI on the Croc or Crocodile chip we need to clear the interrupt so we don't hang the system. Cc: Tested-by: Benjamin Herrenschmidt Signed-off-by: Brian King Signed-off-by: Martin K. Petersen drivers/scsi/ipr.c | 1 + 1 file changed, 1 insertion(+) commit e547f2628327fec6afd2e03b46f113f614cca05b Author: Trond Myklebust Date: Sat Jun 25 19:19:28 2016 -0400 NFS: Fix another OPEN_DOWNGRADE bug Olga Kornievskaia reports that the following test fails to trigger an OPEN_DOWNGRADE on the wire, and only triggers the final CLOSE. fd0 = open(foo, RDRW) -- should be open on the wire for "both" fd1 = open(foo, RDONLY) -- should be open on the wire for "read" close(fd0) -- should trigger an open_downgrade read(fd1) close(fd1) The issue is that we're missing a check for whether or not the current state transitioned from an O_RDWR state as opposed to having transitioned from a combination of O_RDONLY and O_WRONLY. Reported-by: Olga Kornievskaia Fixes: cd9288ffaea4 ("NFSv4: Fix another bug in the close/open_downgrade code") Cc: stable@vger.kernel.org # 2.6.33+ Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/nfs4proc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 3f5be2da8565c1cce5655bb0948fcc957c6eb6c6 Author: Richard Guy Briggs Date: Tue Jun 28 12:07:50 2016 -0400 audit: move audit_get_tty to reduce scope and kabi changes The only users of audit_get_tty and audit_put_tty are internal to audit, so move it out of include/linux/audit.h to kernel.h and create a proper function rather than inlining it. This also reduces kABI changes. Suggested-by: Paul Moore Signed-off-by: Richard Guy Briggs [PM: line wrapped description] Signed-off-by: Paul Moore include/linux/audit.h | 24 ------------------------ kernel/audit.c | 17 +++++++++++++++++ kernel/audit.h | 4 ++++ kernel/auditsc.c | 1 - 4 files changed, 21 insertions(+), 25 deletions(-) commit 76a658c20efd541a62838d9ff68ce94170d7a549 Author: Richard Guy Briggs Date: Tue Jun 28 12:06:58 2016 -0400 audit: move calcs after alloc and check when logging set loginuid Move the calculations of values after the allocation in case the allocation fails. This avoids wasting effort in the rare case that it fails, but more importantly saves us extra logic to release the tty ref. Signed-off-by: Richard Guy Briggs Signed-off-by: Paul Moore kernel/auditsc.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit de4921ce9b3bc68aa530249df8d85cde8edc0968 Merge: 595d9e3 76bf344 Author: Linus Torvalds Date: Tue Jun 28 12:11:31 2016 -0700 Merge branch 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata Pull libata fixes from Tejun Heo: "Two trivial fixes - one for a bug in the allocation failure path and the other a compiler warning fix" * 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata: ata: sata_mv: fix mis-conversion in mv_write_cached_reg() ata: fix return value check in ahci_seattle_get_port_info() commit 595d9e34eedc4b8d0631260ce93bbeb08e5b3bd7 Merge: 02184c6 6dd2e27 Author: Linus Torvalds Date: Tue Jun 28 12:01:14 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid Pull HID fix from Jiri Kosina: "Regression fix for multitouch palm rejection from Allen Hung" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid: HID: multitouch: enable palm rejection for Windows Precision Touchpad Revert "HID: multitouch: enable palm rejection if device implements confidence usage" commit 9a0fee2b552b1235fb1706ae1fc664ae74573be8 Author: Willem de Bruijn Date: Fri Jun 24 16:02:35 2016 -0400 sock_diag: do not broadcast raw socket destruction Diag intends to broadcast tcp_sk and udp_sk socket destruction. Testing sk->sk_protocol for IPPROTO_TCP/IPPROTO_UDP alone is not sufficient for this. Raw sockets can have the same type. Add a test for sk->sk_type. Fixes: eb4cb008529c ("sock_diag: define destruction multicast groups") Signed-off-by: Willem de Bruijn Signed-off-by: David S. Miller include/linux/sock_diag.h | 6 ++++++ 1 file changed, 6 insertions(+) commit ab8ed951080e8f59b1da4ea10ac7c05ba24a3cbd Author: Aaron Campbell Date: Fri Jun 24 10:05:32 2016 -0300 connector: fix out-of-order cn_proc netlink message delivery The proc connector messages include a sequence number, allowing userspace programs to detect lost messages. However, performing this detection is currently more difficult than necessary, since netlink messages can be delivered to the application out-of-order. To fix this, leave pre-emption disabled during cn_netlink_send(), and use GFP_NOWAIT. The following was written as a test case. Building the kernel w/ make -j32 proved a reliable way to generate out-of-order cn_proc messages. int main(int argc, char *argv[]) { static uint32_t last_seq[CPU_SETSIZE], seq; int cpu, fd; struct sockaddr_nl sa; struct __attribute__((aligned(NLMSG_ALIGNTO))) { struct nlmsghdr nl_hdr; struct __attribute__((__packed__)) { struct cn_msg cn_msg; struct proc_event cn_proc; }; } rmsg; struct __attribute__((aligned(NLMSG_ALIGNTO))) { struct nlmsghdr nl_hdr; struct __attribute__((__packed__)) { struct cn_msg cn_msg; enum proc_cn_mcast_op cn_mcast; }; } smsg; fd = socket(PF_NETLINK, SOCK_DGRAM, NETLINK_CONNECTOR); if (fd < 0) { perror("socket"); } sa.nl_family = AF_NETLINK; sa.nl_groups = CN_IDX_PROC; sa.nl_pid = getpid(); if (bind(fd, (struct sockaddr *)&sa, sizeof(sa)) < 0) { perror("bind"); } memset(&smsg, 0, sizeof(smsg)); smsg.nl_hdr.nlmsg_len = sizeof(smsg); smsg.nl_hdr.nlmsg_pid = getpid(); smsg.nl_hdr.nlmsg_type = NLMSG_DONE; smsg.cn_msg.id.idx = CN_IDX_PROC; smsg.cn_msg.id.val = CN_VAL_PROC; smsg.cn_msg.len = sizeof(enum proc_cn_mcast_op); smsg.cn_mcast = PROC_CN_MCAST_LISTEN; if (send(fd, &smsg, sizeof(smsg), 0) != sizeof(smsg)) { perror("send"); } while (recv(fd, &rmsg, sizeof(rmsg), 0) == sizeof(rmsg)) { cpu = rmsg.cn_proc.cpu; if (cpu < 0) { continue; } seq = rmsg.cn_msg.seq; if ((last_seq[cpu] != 0) && (seq != last_seq[cpu] + 1)) { printf("out-of-order seq=%d on cpu=%d\n", seq, cpu); } last_seq[cpu] = seq; } /* NOTREACHED */ perror("recv"); return -1; } Signed-off-by: Aaron Campbell Signed-off-by: David S. Miller drivers/connector/cn_proc.c | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) commit 0888d5f3c0f183ea6177355752ada433d370ac89 Author: daniel Date: Fri Jun 24 12:35:18 2016 +0200 Bridge: Fix ipv6 mc snooping if bridge has no ipv6 address The bridge is falsly dropping ipv6 mulitcast packets if there is: 1. No ipv6 address assigned on the brigde. 2. No external mld querier present. 3. The internal querier enabled. When the bridge fails to build mld queries, because it has no ipv6 address, it slilently returns, but keeps the local querier enabled. This specific case causes confusing packet loss. Ipv6 multicast snooping can only work if: a) An external querier is present OR b) The bridge has an ipv6 address an is capable of sending own queries Otherwise it has to forward/flood the ipv6 multicast traffic, because snooping cannot work. This patch fixes the issue by adding a flag to the bridge struct that indicates that there is currently no ipv6 address assinged to the bridge and returns a false state for the local querier in __br_multicast_querier_exists(). Special thanks to Linus Lüssing. Fixes: d1d81d4c3dd8 ("bridge: check return value of ipv6_dev_get_saddr()") Signed-off-by: Daniel Danzberger Acked-by: Linus Lüssing Signed-off-by: David S. Miller net/bridge/br_multicast.c | 4 ++++ net/bridge/br_private.h | 23 +++++++++++++++++++---- 2 files changed, 23 insertions(+), 4 deletions(-) commit 6dd2e27a103d716921cc4a1a96a9adc0a8e3ab57 Author: Allen Hung Date: Thu Jun 23 16:31:30 2016 +0800 HID: multitouch: enable palm rejection for Windows Precision Touchpad The usage Confidence is mandary to Windows Precision Touchpad devices. If it is examined in input_mapping on a WIndows Precision Touchpad, a new add quirk MT_QUIRK_CONFIDENCE desgned for such devices will be applied to the device. A touch with the confidence bit is not set is determined as invalid. Tested on Dell XPS13 9343 Cc: stable@vger.kernel.org # v4.5+ Reviewed-by: Benjamin Tissoires Tested-by: Andy Lutomirski # XPS 13 9350, BIOS 1.4.3 Signed-off-by: Allen Hung Signed-off-by: Jiri Kosina drivers/hid/hid-multitouch.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) commit 62630ea768869beeb1e514b0bf5607a0c9b93d12 Author: Allen Hung Date: Thu Jun 23 16:31:29 2016 +0800 Revert "HID: multitouch: enable palm rejection if device implements confidence usage" This reverts commit 25a84db15b3f ("HID: multitouch: enable palm rejection if device implements confidence usage") The commit enables palm rejection for Win8 Precision Touchpad devices but the quirk MT_QUIRK_VALID_IS_CONFIDENCE it is using is not working very properly. This quirk is originally designed for some WIn7 touchscreens. Use of this for a Win8 Precision Touchpad will cause unexpected pointer jumping problem. Cc: stable@vger.kernel.org # v4.5+ Reviewed-by: Benjamin Tissoires Tested-by: Andy Lutomirski # XPS 13 9350, BIOS 1.4.3 Signed-off-by: Allen Hung Signed-off-by: Jiri Kosina drivers/hid/hid-multitouch.c | 5 ----- 1 file changed, 5 deletions(-) commit cca0e542e02e48cce541a49c4046ec094ec27c1e Author: Gavin Shan Date: Fri Jun 24 14:49:02 2016 +1000 powerpc/eeh: Fix wrong argument passed to eeh_rmv_device() When calling eeh_rmv_device() in eeh_reset_device() for partial hotplug case, @rmv_data instead of its address is the proper argument. Otherwise, the stack frame is corrupted when writing to @rmv_data (actually its address) in eeh_rmv_device(). It results in kernel crash as observed. This fixes the issue by passing @rmv_data, not its address to eeh_rmv_device() in eeh_reset_device(). Fixes: 67086e32b564 ("powerpc/eeh: powerpc/eeh: Support error recovery for VF PE") Reported-by: Pridhiviraj Paidipeddi Signed-off-by: Gavin Shan Signed-off-by: Michael Ellerman arch/powerpc/kernel/eeh_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 126e7557328a1cd576be4fca95b133a2695283ff Author: Jouni Malinen Date: Sun Jun 19 23:51:02 2016 +0300 mac80211: Fix mesh estab_plinks counting in STA removal case If a user space program (e.g., wpa_supplicant) deletes a STA entry that is currently in NL80211_PLINK_ESTAB state, the number of established plinks counter was not decremented and this could result in rejecting new plink establishment before really hitting the real maximum plink limit. For !user_mpm case, this decrementation is handled by mesh_plink_deactive(). Fix this by decrementing estab_plinks on STA deletion (mesh_sta_cleanup() gets called from there) so that the counter has a correct value and the Beacon frame advertisement in Mesh Configuration element shows the proper value for capability to accept additional peers. Cc: stable@vger.kernel.org Signed-off-by: Jouni Malinen Signed-off-by: Johannes Berg net/mac80211/mesh.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit f299a02d5f13c4deb52c1a7ddf2b42630fe6294a Author: Wang Sheng-Hui Date: Fri Jun 24 08:52:11 2016 +0800 net/mlx5: use mlx5_buf_alloc_node instead of mlx5_buf_alloc in mlx5_wq_ll_create Commit 311c7c71c9bb ("net/mlx5e: Allocate DMA coherent memory on reader NUMA node") introduced mlx5_*_alloc_node() but missed changing some calling and warn messages. This patch introduces 2 changes: * Use mlx5_buf_alloc_node() instead of mlx5_buf_alloc() in mlx5_wq_ll_create() * Update the failure warn messages with _node postfix for mlx5_*_alloc function names Fixes: 311c7c71c9bb ("net/mlx5e: Allocate DMA coherent memory on reader NUMA node") Signed-off-by: Wang Sheng-Hui Acked-By: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/wq.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit d1b5a8da298bc15f67e16f18aa0812c35fe639a2 Merge: 0622cab 3894396 Author: David S. Miller Date: Tue Jun 28 04:22:25 2016 -0400 Merge branch 'bgmac-fixes' Florian Fainelli says: ==================== net: bgmac: Random fixes This patch series fixes a few issues spotted by code inspection and actual testing. ==================== Signed-off-by: David S. Miller commit 3894396e64994f31c3ef5c7e6f63dded0593e567 Author: Florian Fainelli Date: Thu Jun 23 14:25:33 2016 -0700 net: bgmac: Remove superflous netif_carrier_on() bgmac_open() calls phy_start() to initialize the PHY state machine, which will set the interface's carrier state accordingly, no need to force that as this could be conflicting with the PHY state determined by PHYLIB. Fixes: dd4544f05469 ("bgmac: driver for GBit MAC core on BCMA bus") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bgmac.c | 2 -- 1 file changed, 2 deletions(-) commit c3897f2a69e54dd113fc9abd2daf872e5b495798 Author: Florian Fainelli Date: Thu Jun 23 14:25:32 2016 -0700 net: bgmac: Start transmit queue in bgmac_open The driver does not start the transmit queue in bgmac_open(). If the queue was stopped prior to closing then re-opening the interface, we would never be able to wake-up again. Fixes: dd4544f05469 ("bgmac: driver for GBit MAC core on BCMA bus") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bgmac.c | 3 +++ 1 file changed, 3 insertions(+) commit d2b13233879ca1268a1c027d4573109e5a777811 Author: Florian Fainelli Date: Thu Jun 23 14:23:12 2016 -0700 net: bgmac: Fix SOF bit checking We are checking for the Start of Frame bit in the ctl1 word, while this bit is set in the ctl0 word instead. Read the ctl0 word and update the check to verify that. Fixes: 9cde94506eac ("bgmac: implement scatter/gather support") Signed-off-by: Florian Fainelli Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bgmac.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 0622cab0341cac6b30da177b0faa39fae0680e71 Author: Jay Vosburgh Date: Thu Jun 23 14:20:51 2016 -0700 bonding: fix 802.3ad aggregator reselection Since commit 7bb11dc9f59d ("bonding: unify all places where actor-oper key needs to be updated."), the logic in bonding to handle selection between multiple aggregators has not functioned. This affects only configurations wherein the bonding slaves connect to two discrete aggregators (e.g., two independent switches, each with LACP enabled), thus creating two separate aggregation groups within a single bond. The cause is a change in 7bb11dc9f59d to no longer set AD_PORT_BEGIN on a port after a link state change, which would cause the port to be reselected for attachment to an aggregator as if were newly added to the bond. We cannot restore the prior behavior, as it contradicts IEEE 802.1AX 5.4.12, which requires ports that "become inoperable" (lose carrier, setting port_enabled=false as per 802.1AX 5.4.7) to remain selected (i.e., assigned to the aggregator). As the port now remains selected, the aggregator selection logic is not invoked. A side effect of this change is that aggregators in bonding will now contain ports that are link down. The aggregator selection logic does not currently handle this situation correctly, causing incorrect aggregator selection. This patch makes two changes to repair the aggregator selection logic in bonding to function as documented and within the confines of the standard: First, the aggregator selection and related logic now utilizes the number of active ports per aggregator, not the number of selected ports (as some selected ports may be down). The ad_select "bandwidth" and "count" options only consider ports that are link up. Second, on any carrier state change of any slave, the aggregator selection logic is explicitly called to insure the correct aggregator is active. Reported-by: Veli-Matti Lintu Fixes: 7bb11dc9f59d ("bonding: unify all places where actor-oper key needs to be updated.") Signed-off-by: Jay Vosburgh Signed-off-by: David S. Miller drivers/net/bonding/bond_3ad.c | 64 +++++++++++++++++++++++++++++------------- 1 file changed, 45 insertions(+), 19 deletions(-) commit 70a0dec45174c976c64b4c8c1d0898581f759948 Author: Tom Goff Date: Thu Jun 23 16:11:57 2016 -0400 ipmr/ip6mr: Initialize the last assert time of mfc entries. This fixes wrong-interface signaling on 32-bit platforms for entries created when jiffies > 2^31 + MFC_ASSERT_THRESH. Signed-off-by: Tom Goff Signed-off-by: David S. Miller net/ipv4/ipmr.c | 4 +++- net/ipv6/ip6mr.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) commit bcf4dd5f9ee096bd1510f838dd4750c35df4e38b Author: Martin Schwidefsky Date: Mon Jun 27 17:06:45 2016 +0200 s390: fix test_fp_ctl inline assembly contraints The test_fp_ctl function is used to test if a given value is a valid floating-point control. The inline assembly in test_fp_ctl uses an incorrect constraint for the 'orig_fpc' variable. If the compiler chooses the same register for 'fpc' and 'orig_fpc' the test_fp_ctl() function always returns true. This allows user space to trigger kernel oopses with invalid floating-point control values on the signal stack. This problem has been introduced with git commit 4725c86055f5bbdcdf "s390: fix save and restore of the floating-point-control register" Cc: stable@vger.kernel.org # v3.13+ Reviewed-by: Heiko Carstens Signed-off-by: Martin Schwidefsky arch/s390/include/asm/fpu/api.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5419447e2142d6ed68c9f5c1a28630b3a290a845 Author: Michael Holzheu Date: Mon Jun 13 17:03:48 2016 +0200 Revert "s390/kdump: Clear subchannel ID to signal non-CCW/SCSI IPL" This reverts commit 852ffd0f4e23248b47531058e531066a988434b5. There are use cases where an intermediate boot kernel (1) uses kexec to boot the final production kernel (2). For this scenario we should provide the original boot information to the production kernel (2). Therefore clearing the boot information during kexec() should not be done. Cc: stable@vger.kernel.org # v3.17+ Reported-by: Steffen Maier Signed-off-by: Michael Holzheu Reviewed-by: Heiko Carstens Signed-off-by: Martin Schwidefsky arch/s390/kernel/ipl.c | 7 ------- 1 file changed, 7 deletions(-) commit 9bd54517ee86cb164c734f72ea95aeba4804f10b Author: Alexey Brodkin Date: Thu Jun 23 11:00:39 2016 +0300 arc: unwind: warn only once if DW2_UNWIND is disabled If CONFIG_ARC_DW2_UNWIND is disabled every time arc_unwind_core() gets called following message gets printed in debug console: ----------------->8--------------- CONFIG_ARC_DW2_UNWIND needs to be enabled ----------------->8--------------- That message makes sense if user indeed wants to see a backtrace or get nice function call-graphs in perf but what if user disabled unwinder for the purpose? Why pollute his debug console? So instead we'll warn user about possibly missing feature once and let him decide if that was what he or she really wanted. Signed-off-by: Alexey Brodkin Cc: stable@vger.kernel.org Signed-off-by: Vineet Gupta arch/arc/kernel/stacktrace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f52e126cc7476196f44f3c313b7d9f0699a881fc Author: Vineet Gupta Date: Tue Jun 28 09:42:25 2016 +0530 ARC: unwind: ensure that .debug_frame is generated (vs. .eh_frame) With recent binutils update to support dwarf CFI pseudo-ops in gas, we now get .eh_frame vs. .debug_frame. Although the call frame info is exactly the same in both, the CIE differs, which the current kernel unwinder can't cope with. This broke both the kernel unwinder as well as loadable modules (latter because of a new unhandled relo R_ARC_32_PCREL from .rela.eh_frame in the module loader) The ideal solution would be to switch unwinder to .eh_frame. For now however we can make do by just ensureing .debug_frame is generated by removing -fasynchronous-unwind-tables .eh_frame generated with -gdwarf-2 -fasynchronous-unwind-tables .debug_frame generated with -gdwarf-2 Fixes STAR 9001058196 Cc: stable@vger.kernel.org Signed-off-by: Vineet Gupta arch/arc/Makefile | 2 -- 1 file changed, 2 deletions(-) commit 02184c60eba8491ea574cd17b8ba766c86d468f2 Merge: 18751e2 3627612 Author: Linus Torvalds Date: Mon Jun 27 20:43:00 2016 -0700 Merge tag 'for-v4.7-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply Pull power supply fixes from Sebastian Reichel. * tag 'for-v4.7-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply: power_supply: tps65217-charger: Fix NULL deref during property export power_supply: power_supply_read_temp only if use_cnt > 0 commit 18751e2eb51261059e51e1a7cf5aec2fd5429608 Merge: 3992a27 60842ef Author: Linus Torvalds Date: Mon Jun 27 20:34:43 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull input fixes from Dmitry Torokhov. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: vmmouse - remove port reservation Input: elantech - add more IC body types to the list Input: wacom_w8001 - ignore invalid pen data packets Input: wacom_w8001 - w8001_MAX_LENGTH should be 13 Input: xpad - fix oops when attaching an unknown Xbox One gamepad MAINTAINERS: add Pali Rohár as reviewer of ALPS PS/2 touchpad driver Input: add HDMI CEC specific keycodes Input: add BUS_CEC type Input: xpad - fix rumble on Xbox One controllers with 2015 firmware commit 742c87bf27d3b715820da6f8a81d6357adbf18f8 Author: Rafael J. Wysocki Date: Tue Jun 28 03:29:29 2016 +0200 cpufreq: Avoid false-positive WARN_ON()s in cpufreq_update_policy() CPU notifications from the firmware coming in when cpufreq is suspended cause cpufreq_update_current_freq() to return 0 which triggers the WARN_ON() in cpufreq_update_policy() for no reason. Avoid that by checking cpufreq_suspended before calling cpufreq_update_current_freq(). Fixes: c9d9c929e674 (cpufreq: Abort cpufreq_update_current_freq() for cpufreq_suspended set) Signed-off-by: Rafael J. Wysocki Acked-by: Viresh Kumar Cc: 4.6+ # 4.6+ drivers/cpufreq/cpufreq.c | 4 ++++ 1 file changed, 4 insertions(+) commit ca5eda5d3db6026080cff267459625c87c43e9ab Author: Masahiro Yamada Date: Mon Jun 27 14:50:13 2016 +0900 cpufreq: dt: call of_node_put() before error out If of_match_node() fails, this init function bails out without calling of_node_put(). Also change of_node_put(of_root) to of_node_put(np); both of them hold the same pointer, but it seems better to call of_node_put() against the node returned by of_find_node_by_path(). Signed-off-by: Masahiro Yamada Acked-by: Viresh Kumar Signed-off-by: Rafael J. Wysocki drivers/cpufreq/cpufreq-dt-platdev.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 5ab666e09541e64ce2fd73411c3b5b9e4ad334b1 Author: Rafael J. Wysocki Date: Mon Jun 27 23:47:15 2016 +0200 intel_pstate: Do not clear utilization update hooks on policy changes intel_pstate_set_policy() is invoked by the cpufreq core during driver initialization, on changes of policy attributes (minimim and maximum frequency, for example) via sysfs and via CPU notifications from the platform firmware. On some platforms the latter may occur relatively often. Commit bb6ab52f2bef (intel_pstate: Do not set utilization update hook too early) made intel_pstate_set_policy() clear the CPU's utilization update hook before updating the policy attributes for it (and set the hook again after doind that), but that involves invoking synchronize_sched() and adds overhead to the CPU notifications mentioned above and to the sched-RCU handling in general. That extra overhead is arguably not necessary, because updating policy attributes when the CPU's utilization update hook is active should not lead to any adverse effects, so drop the clearing of the hook from intel_pstate_set_policy() and make it check if the hook has been set already when attempting to set it. Fixes: bb6ab52f2bef (intel_pstate: Do not set utilization update hook too early) Reported-by: Jisheng Zhang Tested-by: Jisheng Zhang Tested-by: Doug Smythies Signed-off-by: Rafael J. Wysocki drivers/cpufreq/intel_pstate.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 3992a272a72c7a258236cf035f74396ec4f89941 Merge: fbe601f b36fad6 Author: Linus Torvalds Date: Mon Jun 27 13:38:58 2016 -0700 Merge branch 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild Pull kbuild regression fix from Michal Marek: "The problem is that commit 9c8fa9bc08f6 ("kbuild: fix if_change and friends to consider argument order") fixed a potential missed rebuild, but this results in unnnecessary rebuilds with the packaging targets. Which is still more correct than the previous logic, but also very annoying" * 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: kbuild: Initialize exported variables commit 9c6795a9b3cbb56a9fbfaf43909c5c22999ba317 Author: Christophe JAILLET Date: Mon Jun 27 21:06:51 2016 +0200 ALSA: echoaudio: Fix memory allocation 'commpage_bak' is allocated with 'sizeof(struct echoaudio)' bytes. We then copy 'sizeof(struct comm_page)' bytes in it. On my system, smatch complains because one is 2960 and the other is 3072. This would result in memory corruption or a oops. Signed-off-by: Christophe JAILLET Cc: Signed-off-by: Takashi Iwai sound/pci/echoaudio/echoaudio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 023954351fae0e34ba247cff4d798c98290b20a4 Author: Eric Sandeen Date: Thu Jun 23 16:54:46 2016 -0500 dax: fix offset overflow in dax_io This isn't functionally apparent for some reason, but when we test io at extreme offsets at the end of the loff_t rang, such as in fstests xfs/071, the calculation of "max" in dax_io() can be wrong due to pos + size overflowing. For example, # xfs_io -c "pwrite 9223372036854771712 512" /mnt/test/file enters dax_io with: start 0x7ffffffffffff000 end 0x7ffffffffffff200 and the rounded up "size" variable is 0x1000. This yields: pos + size 0x8000000000000000 (overflows loff_t) end 0x7ffffffffffff200 Due to the overflow, the min() function picks the wrong value for the "max" variable, and when we send (max - pos) into i.e. copy_from_iter_pmem() it is also the wrong value. This somehow(tm) gets magically absorbed without incident, probably because iter->count is correct. But it seems best to fix it up properly by comparing the two values as unsigned. Signed-off-by: Eric Sandeen Signed-off-by: Dan Williams fs/dax.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit fbe601f7a34b395deb85a63ae5cddd0c084c8db1 Merge: 5b7452c 45e8a25 Author: Linus Torvalds Date: Mon Jun 27 11:23:44 2016 -0700 Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 Pull cifs fixes from Steve French: "Various small cifs/smb3 fixes, include some for stable, and some from the recent SMB3 test event" * 'for-next' of git://git.samba.org/sfrench/cifs-2.6: File names with trailing period or space need special case conversion Fix reconnect to not defer smb3 session reconnect long after socket reconnect cifs: check hash calculating succeeded cifs: dynamic allocation of ntlmssp blob cifs: use CIFS_MAX_DOMAINNAME_LEN when converting the domain name cifs: stuff the fl_owner into "pid" field in the lock request commit 5b7452c840ad085e5ca1bb5b5a23a18e6d5b0c33 Merge: 4c2e07c 055ddaa Author: Linus Torvalds Date: Mon Jun 27 10:59:53 2016 -0700 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto fixes from Herbert Xu: "This fixes the following issues: - Missing length check for user-space GETALG request - Bogus memmove length in ux500 driver - Incorrect priority setting for vmx driver - Incorrect ABI selection for vmx driver" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: user - re-add size check for CRYPTO_MSG_GETALG crypto: ux500 - memmove the right size crypto: vmx - Increase priority of aes-cbc cipher crypto: vmx - Fix ABI detection commit ab2a4bf83902c170d29ba130a8abb5f9d90559e1 Author: Alan Stern Date: Mon Jun 27 10:23:10 2016 -0400 USB: don't free bandwidth_mutex too early The USB core contains a bug that can show up when a USB-3 host controller is removed. If the primary (USB-2) hcd structure is released before the shared (USB-3) hcd, the core will try to do a double-free of the common bandwidth_mutex. The problem was described in graphical form by Chung-Geol Kim, who first reported it: ================================================= At *remove USB(3.0) Storage sequence <1> --> <5> ((Problem Case)) ================================================= VOLD ------------------------------------|------------ (uevent) ________|_________ |<1> | |dwc3_otg_sm_work | |usb_put_hcd | |peer_hcd(kref=2)| |__________________| ________|_________ |<2> | |New USB BUS #2 | | | |peer_hcd(kref=1) | | | --(Link)-bandXX_mutex| | |__________________| | ___________________ | |<3> | | |dwc3_otg_sm_work | | |usb_put_hcd | | |primary_hcd(kref=1)| | |___________________| | _________|_________ | |<4> | | |New USB BUS #1 | | |hcd_release | | |primary_hcd(kref=0)| | | | | |bandXX_mutex(free) |<- |___________________| (( VOLD )) ______|___________ |<5> | | SCSI | |usb_put_hcd | |peer_hcd(kref=0) | |*hcd_release | |bandXX_mutex(free*)|<- double free |__________________| ================================================= This happens because hcd_release() frees the bandwidth_mutex whenever it sees a primary hcd being released (which is not a very good idea in any case), but in the course of releasing the primary hcd, it changes the pointers in the shared hcd in such a way that the shared hcd will appear to be primary when it gets released. This patch fixes the problem by changing hcd_release() so that it deallocates the bandwidth_mutex only when the _last_ hcd structure referencing it is released. The patch also removes an unnecessary test, so that when an hcd is released, both the shared_hcd and primary_hcd pointers in the hcd's peer will be cleared. Signed-off-by: Alan Stern Reported-by: Chung-Geol Kim Tested-by: Chung-Geol Kim CC: Signed-off-by: Greg Kroah-Hartman drivers/usb/core/hcd.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) commit 4192f672fae559f32d82de72a677701853cc98a7 Author: Stefan Hajnoczi Date: Thu Jun 23 16:28:58 2016 +0100 vsock: make listener child lock ordering explicit There are several places where the listener and pending or accept queue child sockets are accessed at the same time. Lockdep is unhappy that two locks from the same class are held. Tell lockdep that it is safe and document the lock ordering. Originally Claudio Imbrenda sent a similar patch asking whether this is safe. I have audited the code and also covered the vsock_pending_work() function. Suggested-by: Claudio Imbrenda Signed-off-by: Stefan Hajnoczi Signed-off-by: David S. Miller net/vmw_vsock/af_vsock.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 48f1dcb55a7d29aeb8965c567660c14d0dfd1a42 Author: Paolo Abeni Date: Thu Jun 23 15:25:09 2016 +0200 ipv6: enforce egress device match in per table nexthop lookups with the commit 8c14586fc320 ("net: ipv6: Use passed in table for nexthop lookups"), net hop lookup is first performed on route creation in the passed-in table. However device match is not enforced in table lookup, so the found route can be later discarded due to egress device mismatch and no global lookup will be performed. This cause the following to fail: ip link add dummy1 type dummy ip link add dummy2 type dummy ip link set dummy1 up ip link set dummy2 up ip route add 2001:db8:8086::/48 dev dummy1 metric 20 ip route add 2001:db8:d34d::/64 via 2001:db8:8086::2 dev dummy1 metric 20 ip route add 2001:db8:8086::/48 dev dummy2 metric 21 ip route add 2001:db8:d34d::/64 via 2001:db8:8086::2 dev dummy2 metric 21 RTNETLINK answers: No route to host This change fixes the issue enforcing device lookup in ip6_nh_lookup_table() v1->v2: updated commit message title Fixes: 8c14586fc320 ("net: ipv6: Use passed in table for nexthop lookups") Reported-and-tested-by: Beniamino Galvani Signed-off-by: Paolo Abeni Acked-by: David Ahern Signed-off-by: David S. Miller net/ipv6/route.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5aa3e24928bb95ddb159c5949f1c09493e9e8505 Merge: a37503b 71873a9 Author: David S. Miller Date: Mon Jun 27 10:05:55 2016 -0400 Merge tag 'linux-can-fixes-for-4.7-20160623' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can Marc Kleine-Budde says: ==================== pull-request: can 2016-06-23 this is a pull request of 3 patches for the upcoming linux-4.7 release. The first two patches are by Oliver Hartkopp fixing oopes in the generic CAN device netlink handling. Jimmy Assarsson's patch for the kvaser_usb driver adds support for more devices by adding their USB product ids. ==================== Signed-off-by: David S. Miller commit ff30ef40deca4658e27b0c596e7baf39115e858f Author: Quentin Casasnovas Date: Sat Jun 18 11:01:05 2016 +0200 KVM: nVMX: VMX instructions: fix segment checks when L1 is in long mode. I couldn't get Xen to boot a L2 HVM when it was nested under KVM - it was getting a GP(0) on a rather unspecial vmread from Xen: (XEN) ----[ Xen-4.7.0-rc x86_64 debug=n Not tainted ]---- (XEN) CPU: 1 (XEN) RIP: e008:[] vmx_get_segment_register+0x14e/0x450 (XEN) RFLAGS: 0000000000010202 CONTEXT: hypervisor (d1v0) (XEN) rax: ffff82d0801e6288 rbx: ffff83003ffbfb7c rcx: fffffffffffab928 (XEN) rdx: 0000000000000000 rsi: 0000000000000000 rdi: ffff83000bdd0000 (XEN) rbp: ffff83000bdd0000 rsp: ffff83003ffbfab0 r8: ffff830038813910 (XEN) r9: ffff83003faf3958 r10: 0000000a3b9f7640 r11: ffff83003f82d418 (XEN) r12: 0000000000000000 r13: ffff83003ffbffff r14: 0000000000004802 (XEN) r15: 0000000000000008 cr0: 0000000080050033 cr4: 00000000001526e0 (XEN) cr3: 000000003fc79000 cr2: 0000000000000000 (XEN) ds: 0000 es: 0000 fs: 0000 gs: 0000 ss: 0000 cs: e008 (XEN) Xen code around (vmx_get_segment_register+0x14e/0x450): (XEN) 00 00 41 be 02 48 00 00 <44> 0f 78 74 24 08 0f 86 38 56 00 00 b8 08 68 00 (XEN) Xen stack trace from rsp=ffff83003ffbfab0: ... (XEN) Xen call trace: (XEN) [] vmx_get_segment_register+0x14e/0x450 (XEN) [] get_page_from_gfn_p2m+0x165/0x300 (XEN) [] hvmemul_get_seg_reg+0x52/0x60 (XEN) [] hvm_emulate_prepare+0x53/0x70 (XEN) [] handle_mmio+0x2b/0xd0 (XEN) [] emulate.c#_hvm_emulate_one+0x111/0x2c0 (XEN) [] handle_hvm_io_completion+0x274/0x2a0 (XEN) [] __get_gfn_type_access+0xfa/0x270 (XEN) [] timer.c#add_entry+0x4b/0xb0 (XEN) [] timer.c#remove_entry+0x7c/0x90 (XEN) [] hvm_do_resume+0x23/0x140 (XEN) [] vmx_do_resume+0xa7/0x140 (XEN) [] context_switch+0x13b/0xe40 (XEN) [] schedule.c#schedule+0x22e/0x570 (XEN) [] softirq.c#__do_softirq+0x5c/0x90 (XEN) [] domain.c#idle_loop+0x25/0x50 (XEN) (XEN) (XEN) **************************************** (XEN) Panic on CPU 1: (XEN) GENERAL PROTECTION FAULT (XEN) [error_code=0000] (XEN) **************************************** Tracing my host KVM showed it was the one injecting the GP(0) when emulating the VMREAD and checking the destination segment permissions in get_vmx_mem_address(): 3) | vmx_handle_exit() { 3) | handle_vmread() { 3) | nested_vmx_check_permission() { 3) | vmx_get_segment() { 3) 0.074 us | vmx_read_guest_seg_base(); 3) 0.065 us | vmx_read_guest_seg_selector(); 3) 0.066 us | vmx_read_guest_seg_ar(); 3) 1.636 us | } 3) 0.058 us | vmx_get_rflags(); 3) 0.062 us | vmx_read_guest_seg_ar(); 3) 3.469 us | } 3) | vmx_get_cs_db_l_bits() { 3) 0.058 us | vmx_read_guest_seg_ar(); 3) 0.662 us | } 3) | get_vmx_mem_address() { 3) 0.068 us | vmx_cache_reg(); 3) | vmx_get_segment() { 3) 0.074 us | vmx_read_guest_seg_base(); 3) 0.068 us | vmx_read_guest_seg_selector(); 3) 0.071 us | vmx_read_guest_seg_ar(); 3) 1.756 us | } 3) | kvm_queue_exception_e() { 3) 0.066 us | kvm_multiple_exception(); 3) 0.684 us | } 3) 4.085 us | } 3) 9.833 us | } 3) + 10.366 us | } Cross-checking the KVM/VMX VMREAD emulation code with the Intel Software Developper Manual Volume 3C - "VMREAD - Read Field from Virtual-Machine Control Structure", I found that we're enforcing that the destination operand is NOT located in a read-only data segment or any code segment when the L1 is in long mode - BUT that check should only happen when it is in protected mode. Shuffling the code a bit to make our emulation follow the specification allows me to boot a Xen dom0 in a nested KVM and start HVM L2 guests without problems. Fixes: f9eb4af67c9d ("KVM: nVMX: VMX instructions: add checks for #GP/#SS exceptions") Signed-off-by: Quentin Casasnovas Cc: Eugene Korenevsky Cc: Paolo Bonzini Cc: Radim Krčmář Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Cc: linux-stable Signed-off-by: Paolo Bonzini arch/x86/kvm/vmx.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) commit b606f189c7d5bf9b875bba168162fe05287880fe Author: Marcelo Tosatti Date: Mon Jun 20 22:33:48 2016 -0300 KVM: LAPIC: cap __delay at lapic_timer_advance_ns The host timer which emulates the guest LAPIC TSC deadline timer has its expiration diminished by lapic_timer_advance_ns nanoseconds. Therefore if, at wait_lapic_expire, a difference larger than lapic_timer_advance_ns is encountered, delay at most lapic_timer_advance_ns. This fixes a problem where the guest can cause the host to delay for large amounts of time. Reported-by: Alan Jenkins Signed-off-by: Marcelo Tosatti Signed-off-by: Paolo Bonzini arch/x86/kvm/lapic.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8d93c874ac899bfdf0ad3787baef684a0c878c2c Author: Marcelo Tosatti Date: Mon Jun 20 22:28:02 2016 -0300 KVM: x86: move nsec_to_cycles from x86.c to x86.h Move the inline function nsec_to_cycles from x86.c to x86.h, as the next patch uses it from lapic.c. Signed-off-by: Marcelo Tosatti Signed-off-by: Paolo Bonzini arch/x86/kvm/x86.c | 6 ------ arch/x86/kvm/x86.h | 7 +++++++ 2 files changed, 7 insertions(+), 6 deletions(-) commit ed911b43adb889c37a37fa57a995f0b460c633b6 Author: Minfei Huang Date: Sat May 28 20:27:43 2016 +0800 pvclock: Get rid of __pvclock_read_cycles in function pvclock_read_flags There is a generic function __pvclock_read_cycles to be used to get both flags and cycles. For function pvclock_read_flags, it's useless to get cycles value. To make this function be more effective, get this variable flags directly in function. Signed-off-by: Minfei Huang Signed-off-by: Paolo Bonzini arch/x86/kernel/pvclock.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit f7550d076d55c1b5f02f95012e3a5a84d264c47d Author: Minfei Huang Date: Fri May 27 14:17:11 2016 +0800 pvclock: Cleanup to remove function pvclock_get_nsec_offset Function __pvclock_read_cycles is short enough, so there is no need to have another function pvclock_get_nsec_offset to calculate tsc delta. It's better to combine it into function __pvclock_read_cycles. Remove useless variables in function __pvclock_read_cycles. Signed-off-by: Minfei Huang Signed-off-by: Paolo Bonzini arch/x86/include/asm/pvclock.h | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) commit 749d088b8e7f4b9826ede02b9a043e417fa84aa1 Author: Minfei Huang Date: Fri May 27 14:17:10 2016 +0800 pvclock: Add CPU barriers to get correct version value Protocol for the "version" fields is: hypervisor raises it (making it uneven) before it starts updating the fields and raises it again (making it even) when it is done. Thus the guest can make sure the time values it got are consistent by checking the version before and after reading them. Add CPU barries after getting version value just like what function vread_pvclock does, because all of callees in this function is inline. Fixes: 502dfeff239e8313bfbe906ca0a1a6827ac8481b Cc: stable@vger.kernel.org Signed-off-by: Minfei Huang Signed-off-by: Paolo Bonzini arch/x86/include/asm/pvclock.h | 2 ++ arch/x86/kernel/pvclock.c | 4 ++++ 2 files changed, 6 insertions(+) commit d20cb71dbf3487f24549ede1a8e2d67579b4632e Author: Al Viro Date: Mon Jun 20 13:14:36 2016 -0400 make nfs_atomic_open() call d_drop() on all ->open_context() errors. In "NFSv4: Move dentry instantiation into the NFSv4-specific atomic open code" unconditional d_drop() after the ->open_context() had been removed. It had been correct for success cases (there ->open_context() itself had been doing dcache manipulations), but not for error ones. Only one of those (ENOENT) got a compensatory d_drop() added in that commit, but in fact it should've been done for all errors. As it is, the case of O_CREAT non-exclusive open on a hashed negative dentry racing with e.g. symlink creation from another client ended up with ->open_context() getting an error and proceeding to call nfs_lookup(). On a hashed dentry, which would've instantly triggered BUG_ON() in d_materialise_unique() (or, these days, its equivalent in d_splice_alias()). Cc: stable@vger.kernel.org # v3.10+ Tested-by: Oleg Drokin Signed-off-by: Al Viro Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6082ee72e9d89e80a664418be06f47d728243e85 Author: Nicolas Iooss Date: Sun Jun 26 10:33:29 2016 +0200 iommu/amd: Initialize devid variable before using it Commit 2a0cb4e2d423 ("iommu/amd: Add new map for storing IVHD dev entry type HID") added a call to DUMP_printk in init_iommu_from_acpi() which used the value of devid before this variable was initialized. Fixes: 2a0cb4e2d423 ('iommu/amd: Add new map for storing IVHD dev entry type HID') Signed-off-by: Nicolas Iooss Signed-off-by: Joerg Roedel drivers/iommu/amd_iommu_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3bd4f9112f87a9c65fe6e817272806167f0bc9ed Author: Jan Niehusmann Date: Mon Jun 6 14:20:11 2016 +0200 iommu/vt-d: Fix overflow of iommu->domains array The valid range of 'did' in get_iommu_domain(*iommu, did) is 0..cap_ndoms(iommu->cap), so don't exceed that range in free_all_cpu_cached_iovas(). The user-visible impact of the out-of-bounds access is the machine hanging on suspend-to-ram. It is, in fact, a kernel panic, but due to already suspended devices, that's often not visible to the user. Fixes: 22e2f9fa63b0 ("iommu/vt-d: Use per-cpu IOVA caching") Signed-off-by: Jan Niehusmann Tested-By: Marius Vlad Signed-off-by: Joerg Roedel drivers/iommu/intel-iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 591d215afcc2f94e8e2c69a63c924c044677eb31 Author: James Morse Date: Wed Jun 8 17:24:45 2016 +0100 KVM: arm/arm64: Stop leaking vcpu pid references kvm provides kvm_vcpu_uninit(), which amongst other things, releases the last reference to the struct pid of the task that was last running the vcpu. On arm64 built with CONFIG_DEBUG_KMEMLEAK, starting a guest with kvmtool, then killing it with SIGKILL results (after some considerable time) in: > cat /sys/kernel/debug/kmemleak > unreferenced object 0xffff80007d5ea080 (size 128): > comm "lkvm", pid 2025, jiffies 4294942645 (age 1107.776s) > hex dump (first 32 bytes): > 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ > 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ > backtrace: > [] create_object+0xfc/0x278 > [] kmemleak_alloc+0x34/0x70 > [] kmem_cache_alloc+0x16c/0x1d8 > [] alloc_pid+0x34/0x4d0 > [] copy_process.isra.6+0x79c/0x1338 > [] _do_fork+0x74/0x320 > [] SyS_clone+0x18/0x20 > [] el0_svc_naked+0x24/0x28 > [] 0xffffffffffffffff On x86 kvm_vcpu_uninit() is called on the path from kvm_arch_destroy_vm(), on arm no equivalent call is made. Add the call to kvm_arch_vcpu_free(). Signed-off-by: James Morse Fixes: 749cf76c5a36 ("KVM: ARM: Initial skeleton to compile KVM support") Cc: # 3.10+ Acked-by: Marc Zyngier Signed-off-by: Christoffer Dall arch/arm/kvm/arm.c | 1 + 1 file changed, 1 insertion(+) commit 583248e6620a4726093295e2d6785fcbc2e86428 Author: Chris Wilson Date: Wed Jun 1 12:10:08 2016 +0100 iommu/iova: Disable preemption around use of this_cpu_ptr() Between acquiring the this_cpu_ptr() and using it, ideally we don't want to be preempted and work on another CPU's private data. this_cpu_ptr() checks whether or not preemption is disable, and get_cpu_ptr() provides a convenient wrapper for operating on the cpu ptr inside a preemption disabled critical section (which currently is provided by the spinlock). [ 167.997877] BUG: using smp_processor_id() in preemptible [00000000] code: usb-storage/216 [ 167.997940] caller is debug_smp_processor_id+0x17/0x20 [ 167.997945] CPU: 7 PID: 216 Comm: usb-storage Tainted: G U 4.7.0-rc1-gfxbench-RO_Patchwork_1057+ #1 [ 167.997948] Hardware name: Hewlett-Packard HP Pro 3500 Series/2ABF, BIOS 8.11 10/24/2012 [ 167.997951] 0000000000000000 ffff880118b7f9c8 ffffffff8140dca5 0000000000000007 [ 167.997958] ffffffff81a3a7e9 ffff880118b7f9f8 ffffffff8142a927 0000000000000000 [ 167.997965] ffff8800d499ed58 0000000000000001 00000000000fffff ffff880118b7fa08 [ 167.997971] Call Trace: [ 167.997977] [] dump_stack+0x67/0x92 [ 167.997981] [] check_preemption_disabled+0xd7/0xe0 [ 167.997985] [] debug_smp_processor_id+0x17/0x20 [ 167.997990] [] alloc_iova_fast+0xb7/0x210 [ 167.997994] [] intel_alloc_iova+0x7f/0xd0 [ 167.997998] [] intel_map_sg+0xbd/0x240 [ 167.998002] [] ? debug_lockdep_rcu_enabled+0x1d/0x20 [ 167.998009] [] usb_hcd_map_urb_for_dma+0x4b9/0x5a0 [ 167.998013] [] usb_hcd_submit_urb+0xe9/0xaa0 [ 167.998017] [] ? mark_held_locks+0x6f/0xa0 [ 167.998022] [] ? __raw_spin_lock_init+0x1c/0x50 [ 167.998025] [] ? debug_lockdep_rcu_enabled+0x1d/0x20 [ 167.998028] [] usb_submit_urb+0x3f3/0x5a0 [ 167.998032] [] ? trace_hardirqs_on_caller+0x122/0x1b0 [ 167.998035] [] usb_sg_wait+0x67/0x150 [ 167.998039] [] usb_stor_bulk_transfer_sglist.part.3+0x82/0xd0 [ 167.998042] [] usb_stor_bulk_srb+0x4c/0x60 [ 167.998045] [] usb_stor_Bulk_transport+0x17e/0x420 [ 167.998049] [] usb_stor_invoke_transport+0x242/0x540 [ 167.998052] [] ? debug_lockdep_rcu_enabled+0x1d/0x20 [ 167.998058] [] usb_stor_transparent_scsi_command+0x9/0x10 [ 167.998061] [] usb_stor_control_thread+0x158/0x260 [ 167.998064] [] ? fill_inquiry_response+0x20/0x20 [ 167.998067] [] ? fill_inquiry_response+0x20/0x20 [ 167.998071] [] kthread+0xea/0x100 [ 167.998078] [] ret_from_fork+0x1f/0x40 [ 167.998081] [] ? kthread_create_on_node+0x1f0/0x1f0 Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96293 Signed-off-by: Chris Wilson Cc: Joonas Lahtinen Cc: Joerg Roedel Cc: iommu@lists.linux-foundation.org Cc: linux-kernel@vger.kernel.org Fixes: 9257b4a206fc ('iommu/iova: introduce per-cpu caching to iova allocation') Signed-off-by: Joerg Roedel drivers/iommu/iova.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 0efce9da1255f13d910842b62cb14371044a3c50 Author: Sudeep Holla Date: Wed Jun 8 11:38:55 2016 +0100 arm64: KVM: fix build with CONFIG_ARM_PMU disabled When CONFIG_ARM_PMU is disabled, we get the following build error: arch/arm64/kvm/sys_regs.c: In function 'pmu_counter_idx_valid': arch/arm64/kvm/sys_regs.c:564:27: error: 'ARMV8_PMU_CYCLE_IDX' undeclared (first use in this function) if (idx >= val && idx != ARMV8_PMU_CYCLE_IDX) ^ arch/arm64/kvm/sys_regs.c:564:27: note: each undeclared identifier is reported only once for each function it appears in arch/arm64/kvm/sys_regs.c: In function 'access_pmu_evcntr': arch/arm64/kvm/sys_regs.c:592:10: error: 'ARMV8_PMU_CYCLE_IDX' undeclared (first use in this function) idx = ARMV8_PMU_CYCLE_IDX; ^ arch/arm64/kvm/sys_regs.c: In function 'access_pmu_evtyper': arch/arm64/kvm/sys_regs.c:638:14: error: 'ARMV8_PMU_CYCLE_IDX' undeclared (first use in this function) if (idx == ARMV8_PMU_CYCLE_IDX) ^ arch/arm64/kvm/hyp/switch.c:86:15: error: 'ARMV8_PMU_USERENR_MASK' undeclared (first use in this function) write_sysreg(ARMV8_PMU_USERENR_MASK, pmuserenr_el0); This patch fixes the build with CONFIG_ARM_PMU disabled. Cc: Christoffer Dall Cc: Marc Zyngier Signed-off-by: Sudeep Holla Signed-off-by: Christoffer Dall include/kvm/arm_pmu.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8e96a87c5431c256feb65bcfc5aec92d9f7839b6 Author: Cyril Bur Date: Fri Jun 17 14:58:34 2016 +1000 powerpc/tm: Always reclaim in start_thread() for exec() class syscalls Userspace can quite legitimately perform an exec() syscall with a suspended transaction. exec() does not return to the old process, rather it load a new one and starts that, the expectation therefore is that the new process starts not in a transaction. Currently exec() is not treated any differently to any other syscall which creates problems. Firstly it could allow a new process to start with a suspended transaction for a binary that no longer exists. This means that the checkpointed state won't be valid and if the suspended transaction were ever to be resumed and subsequently aborted (a possibility which is exceedingly likely as exec()ing will likely doom the transaction) the new process will jump to invalid state. Secondly the incorrect attempt to keep the transactional state while still zeroing state for the new process creates at least two TM Bad Things. The first triggers on the rfid to return to userspace as start_thread() has given the new process a 'clean' MSR but the suspend will still be set in the hardware MSR. The second TM Bad Thing triggers in __switch_to() as the processor is still transactionally suspended but __switch_to() wants to zero the TM sprs for the new process. This is an example of the outcome of calling exec() with a suspended transaction. Note the first 700 is likely the first TM bad thing decsribed earlier only the kernel can't report it as we've loaded userspace registers. c000000000009980 is the rfid in fast_exception_return() Bad kernel stack pointer 3fffcfa1a370 at c000000000009980 Oops: Bad kernel stack pointer, sig: 6 [#1] CPU: 0 PID: 2006 Comm: tm-execed Not tainted NIP: c000000000009980 LR: 0000000000000000 CTR: 0000000000000000 REGS: c00000003ffefd40 TRAP: 0700 Not tainted MSR: 8000000300201031 CR: 00000000 XER: 00000000 CFAR: c0000000000098b4 SOFTE: 0 PACATMSCRATCH: b00000010000d033 GPR00: 0000000000000000 00003fffcfa1a370 0000000000000000 0000000000000000 GPR04: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 GPR08: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 GPR12: 00003fff966611c0 0000000000000000 0000000000000000 0000000000000000 NIP [c000000000009980] fast_exception_return+0xb0/0xb8 LR [0000000000000000] (null) Call Trace: Instruction dump: f84d0278 e9a100d8 7c7b03a6 e84101a0 7c4ff120 e8410170 7c5a03a6 e8010070 e8410080 e8610088 e8810090 e8210078 <4c000024> 48000000 e8610178 88ed023b Kernel BUG at c000000000043e80 [verbose debug info unavailable] Unexpected TM Bad Thing exception at c000000000043e80 (msr 0x201033) Oops: Unrecoverable exception, sig: 6 [#2] CPU: 0 PID: 2006 Comm: tm-execed Tainted: G D task: c0000000fbea6d80 ti: c00000003ffec000 task.ti: c0000000fb7ec000 NIP: c000000000043e80 LR: c000000000015a24 CTR: 0000000000000000 REGS: c00000003ffef7e0 TRAP: 0700 Tainted: G D MSR: 8000000300201033 CR: 28002828 XER: 00000000 CFAR: c000000000015a20 SOFTE: 0 PACATMSCRATCH: b00000010000d033 GPR00: 0000000000000000 c00000003ffefa60 c000000000db5500 c0000000fbead000 GPR04: 8000000300001033 2222222222222222 2222222222222222 00000000ff160000 GPR08: 0000000000000000 800000010000d033 c0000000fb7e3ea0 c00000000fe00004 GPR12: 0000000000002200 c00000000fe00000 0000000000000000 0000000000000000 GPR16: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 GPR20: 0000000000000000 0000000000000000 c0000000fbea7410 00000000ff160000 GPR24: c0000000ffe1f600 c0000000fbea8700 c0000000fbea8700 c0000000fbead000 GPR28: c000000000e20198 c0000000fbea6d80 c0000000fbeab680 c0000000fbea6d80 NIP [c000000000043e80] tm_restore_sprs+0xc/0x1c LR [c000000000015a24] __switch_to+0x1f4/0x420 Call Trace: Instruction dump: 7c800164 4e800020 7c0022a6 f80304a8 7c0222a6 f80304b0 7c0122a6 f80304b8 4e800020 e80304a8 7c0023a6 e80304b0 <7c0223a6> e80304b8 7c0123a6 4e800020 This fixes CVE-2016-5828. Fixes: bc2a9408fa65 ("powerpc: Hook in new transactional memory code") Cc: stable@vger.kernel.org # v3.9+ Signed-off-by: Cyril Bur Signed-off-by: Michael Ellerman arch/powerpc/kernel/process.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit ea1dc6fc6242f991656e35e2ed3d90ec1cd13418 Author: Peter Zijlstra Date: Fri Jun 24 16:11:02 2016 +0200 sched/fair: Fix calc_cfs_shares() fixed point arithmetics width confusion Commit: fde7d22e01aa ("sched/fair: Fix overly small weight for interactive group entities") did something non-obvious but also did it buggy yet latent. The problem was exposed for real by a later commit in the v4.7 merge window: 2159197d6677 ("sched/core: Enable increased load resolution on 64-bit kernels") ... after which tg->load_avg and cfs_rq->load.weight had different units (10 bit fixed point and 20 bit fixed point resp.). Add a comment to explain the use of cfs_rq->load.weight over the 'natural' cfs_rq->avg.load_avg and add scale_load_down() to correct for the difference in unit. Since this is (now, as per a previous commit) the only user of calc_tg_weight(), collapse it. The effects of this bug should be randomly inconsistent SMP-balancing of cgroups workloads. Reported-by: Jirka Hladky Signed-off-by: Peter Zijlstra (Intel) Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Fixes: 2159197d6677 ("sched/core: Enable increased load resolution on 64-bit kernels") Fixes: fde7d22e01aa ("sched/fair: Fix overly small weight for interactive group entities") Signed-off-by: Ingo Molnar kernel/sched/fair.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) commit 7dd4912594daf769a46744848b05bd5bc6d62469 Author: Peter Zijlstra Date: Fri Jun 24 15:53:54 2016 +0200 sched/fair: Fix effective_load() to consistently use smoothed load Starting with the following commit: fde7d22e01aa ("sched/fair: Fix overly small weight for interactive group entities") calc_tg_weight() doesn't compute the right value as expected by effective_load(). The difference is in the 'correction' term. In order to ensure \Sum rw_j >= rw_i we cannot use tg->load_avg directly, since that might be lagging a correction on the current cfs_rq->avg.load_avg value. Therefore we use tg->load_avg - cfs_rq->tg_load_avg_contrib + cfs_rq->avg.load_avg. Now, per the referenced commit, calc_tg_weight() doesn't use cfs_rq->avg.load_avg, as is later used in @w, but uses cfs_rq->load.weight instead. So stop using calc_tg_weight() and do it explicitly. The effects of this bug are wake_affine() making randomly poor choices in cgroup-intense workloads. Signed-off-by: Peter Zijlstra (Intel) Cc: # v4.3+ Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Fixes: fde7d22e01aa ("sched/fair: Fix overly small weight for interactive group entities") Signed-off-by: Ingo Molnar kernel/sched/fair.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit a37503bc387ce2434106d4bf4870bd73081c7355 Author: Jeremy Linton Date: Wed Jun 22 12:40:50 2016 -0500 net: smsc911x: Fix bug where PHY interrupts are overwritten by 0 By default, mdiobus_alloc() sets the PHYs to polling mode, but a pointer size memcpy means that a couple IRQs end up being overwritten with a value of 0. This means that PHY_POLL is disabled and results in unpredictable behavior depending on the PHY's location on the MDIO bus. Remove that memcpy and the now unused phy_irq member to force the SMSC911x PHYs into polling mode 100% of the time. Fixes: e7f4dc3536a4 ("mdio: Move allocation of interrupts into core") Signed-off-by: Jeremy Linton Reviewed-by: Andrew Lunn Acked-by: Sergei Shtylyov Signed-off-by: David S. Miller drivers/net/ethernet/smsc/smsc911x.c | 2 -- 1 file changed, 2 deletions(-) commit 4c2e07c6a29e0129e975727b9f57eede813eea85 Author: Linus Torvalds Date: Sun Jun 26 17:52:03 2016 -0700 Linux 4.7-rc5 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5353ed8deedee9e5acb9f896e9032158f5d998de Author: Colin Ian King Date: Mon Jun 20 15:40:27 2016 +0100 devpts: fix null pointer dereference on failed memory allocation An ENOMEM when creating a pair tty in tty_ldisc_setup causes a null pointer dereference in devpts_kill_index because tty->link->driver_data is NULL. The oops was triggered with the pty stressor in stress-ng when in a low memory condition. tty_init_dev tries to clean up a tty_ldisc_setup ENOMEM error by calling release_tty, however, this ultimately tries to clean up the NULL pair'd tty in pty_unix98_remove, triggering the Oops. Add check to pty_unix98_remove to only clean up fsi if it is not NULL. Ooops: [ 23.020961] Oops: 0000 [#1] SMP [ 23.020976] Modules linked in: ppdev snd_hda_codec_generic snd_hda_intel snd_hda_codec parport_pc snd_hda_core snd_hwdep parport snd_pcm input_leds joydev snd_timer serio_raw snd soundcore i2c_piix4 mac_hid ib_iser rdma_cm iw_cm ib_cm ib_core configfs iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi autofs4 btrfs raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid1 raid0 multipath linear crct10dif_pclmul crc32_pclmul ghash_clmulni_intel aesni_intel qxl aes_x86_64 ttm lrw gf128mul glue_helper ablk_helper drm_kms_helper cryptd syscopyarea sysfillrect psmouse sysimgblt floppy fb_sys_fops drm pata_acpi jitterentropy_rng drbg ansi_cprng [ 23.020978] CPU: 0 PID: 1452 Comm: stress-ng-pty Not tainted 4.7.0-rc4+ #2 [ 23.020978] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Ubuntu-1.8.2-1ubuntu1 04/01/2014 [ 23.020979] task: ffff88007ba30000 ti: ffff880078ea8000 task.ti: ffff880078ea8000 [ 23.020981] RIP: 0010:[] [] ida_remove+0x1f/0x120 [ 23.020981] RSP: 0018:ffff880078eabb60 EFLAGS: 00010a03 [ 23.020982] RAX: 4444444444444567 RBX: 0000000000000000 RCX: 000000000000001f [ 23.020982] RDX: 000000000000014c RSI: 000000000000026f RDI: 0000000000000000 [ 23.020982] RBP: ffff880078eabb70 R08: 0000000000000004 R09: 0000000000000036 [ 23.020983] R10: 000000000000026f R11: 0000000000000000 R12: 000000000000026f [ 23.020983] R13: 000000000000026f R14: ffff88007c944b40 R15: 000000000000026f [ 23.020984] FS: 00007f9a2f3cc700(0000) GS:ffff88007fc00000(0000) knlGS:0000000000000000 [ 23.020984] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 23.020985] CR2: 0000000000000010 CR3: 000000006c81b000 CR4: 00000000001406f0 [ 23.020988] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 23.020988] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 23.020988] Stack: [ 23.020989] 0000000000000000 000000000000026f ffff880078eabb90 ffffffff812a5a99 [ 23.020990] 0000000000000000 00000000fffffff4 ffff880078eabba8 ffffffff814f9cbe [ 23.020991] ffff88007965c800 ffff880078eabbc8 ffffffff814eef43 fffffffffffffff4 [ 23.020991] Call Trace: [ 23.021000] [] devpts_kill_index+0x29/0x50 [ 23.021002] [] pty_unix98_remove+0x2e/0x50 [ 23.021006] [] release_tty+0xb3/0x1b0 [ 23.021007] [] tty_init_dev+0xd4/0x1c0 [ 23.021011] [] ptmx_open+0xae/0x190 [ 23.021013] [] chrdev_open+0xbf/0x1b0 [ 23.021015] [] do_dentry_open+0x203/0x310 [ 23.021016] [] ? cdev_put+0x30/0x30 [ 23.021017] [] vfs_open+0x54/0x80 [ 23.021018] [] ? may_open+0x8c/0x100 [ 23.021019] [] path_openat+0x2eb/0x1440 [ 23.021020] [] ? putname+0x54/0x60 [ 23.021022] [] ? n_tty_ioctl_helper+0x27/0x100 [ 23.021023] [] do_filp_open+0x91/0x100 [ 23.021024] [] ? getname_flags+0x56/0x1f0 [ 23.021026] [] ? __alloc_fd+0x46/0x190 [ 23.021027] [] do_sys_open+0x124/0x210 [ 23.021028] [] SyS_open+0x1e/0x20 [ 23.021035] [] entry_SYSCALL_64_fastpath+0x1e/0xa8 [ 23.021044] Code: 63 28 45 31 e4 eb dd 0f 1f 44 00 00 55 4c 63 d6 48 ba 89 88 88 88 88 88 88 88 4c 89 d0 b9 1f 00 00 00 48 f7 e2 48 89 e5 41 54 53 <8b> 47 10 48 89 fb 8d 3c c5 00 00 00 00 48 c1 ea 09 b8 01 00 00 [ 23.021045] RIP [] ida_remove+0x1f/0x120 [ 23.021045] RSP [ 23.021046] CR2: 0000000000000010 Signed-off-by: Colin Ian King Cc: stable Signed-off-by: Greg Kroah-Hartman drivers/tty/pty.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 2ac9b9735b4d1924d7484e497c930ea013a29ac1 Merge: da2f6ab 951d77f Author: Linus Torvalds Date: Sun Jun 26 10:08:49 2016 -0700 Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "Two straightforward fixes. One is a concurrency issue only affecting SAS connected SATA drives, but which could hang the storage subsystem if it triggers (because the outstanding command count on error never goes back to zero) and the other is a NO_TAG fallout from the switch to hostwide tags which causes the system to crash on module insertion (we've checked carefully and only the 53c700 family of drivers is vulnerable to this issue)" * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: 53c700: fix BUG on untagged commands scsi: fix race between simultaneous decrements of ->host_failed commit 68b356eb3d9f5e38910fb62e22a78e2a18d544ae Author: Mark Brown Date: Mon Jun 20 13:53:34 2016 +0100 iio:ad7266: Fix probe deferral for vref Currently the ad7266 driver treats any failure to get vref as though the regulator were not present but this means that if probe deferral is triggered the driver will act as though the regulator were not present. Instead only use the internal reference if we explicitly got -ENODEV which is what is returned for absent regulators. Signed-off-by: Mark Brown Cc: Signed-off-by: Jonathan Cameron drivers/iio/adc/ad7266.c | 3 +++ 1 file changed, 3 insertions(+) commit e5511c816e5ac4909bdd38e85ac344e2b9b8e984 Author: Mark Brown Date: Mon Jun 20 13:53:33 2016 +0100 iio:ad7266: Fix support for optional regulators The ad7266 driver attempts to support deciding between the use of internal and external power supplies by checking to see if an error is returned when requesting the regulator. This doesn't work with the current code since the driver uses a normal regulator_get() which is for non-optional supplies and so assumes that if a regulator is not provided by the platform then this is a bug in the platform integration and so substitutes a dummy regulator. Use regulator_get_optional() instead which indicates to the framework that the regulator may be absent and provides a dummy regulator instead. Signed-off-by: Mark Brown Cc: Signed-off-by: Jonathan Cameron drivers/iio/adc/ad7266.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6b7f4e25f3309f106a5c7ff42c8231494cf285d3 Author: Mark Brown Date: Mon Jun 20 13:53:32 2016 +0100 iio:ad7266: Fix broken regulator error handling All regulator_get() variants return either a pointer to a regulator or an ERR_PTR() so testing for NULL makes no sense and may lead to bugs if we use NULL as a valid regulator. Fix this by using IS_ERR() as expected. Signed-off-by: Mark Brown Cc: Signed-off-by: Jonathan Cameron drivers/iio/adc/ad7266.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0c1f91b98552da49d9d8eed32b3132a58d2f4598 Author: Linus Walleij Date: Fri Jun 17 15:22:24 2016 +0200 iio: accel: kxsd9: fix the usage of spi_w8r8() These two spi_w8r8() calls return a value with is used by the code following the error check. The dubious use was caused by a cleanup patch. Fixes: d34dbee8ac8e ("staging:iio:accel:kxsd9 cleanup and conversion to iio_chan_spec.") Signed-off-by: Linus Walleij Cc: Signed-off-by: Jonathan Cameron drivers/iio/accel/kxsd9.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ef3149eb3ddb7f9125e11c90f8330e371b55cffd Author: Luis de Bethencourt Date: Wed Jun 22 20:43:30 2016 +0100 staging: iio: accel: fix error check sca3000_read_ctrl_reg() returns a negative number on failure, check for this instead of zero. Signed-off-by: Luis de Bethencourt Cc: Signed-off-by: Jonathan Cameron drivers/staging/iio/accel/sca3000_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 18f5839932e5c8c019f394d433dc5efcd6ae737a Author: Alan Cox Date: Thu Jun 23 22:07:03 2016 +0530 ASoC: Intel: atom: fix missing breaks that would cause the wrong operation to execute Now we correctly error an attempt to execute an unsupported operation. Signed-off-by: Alan Cox Signed-off-by: Vinod Koul Signed-off-by: Mark Brown sound/soc/intel/atom/sst-mfld-platform-compress.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 81e43960dce1c8e58e682fb3ec26c1d8f83a9afc Author: Bob Copeland Date: Sat Jun 25 07:58:45 2016 -0400 ALSA: hda - fix read before array start UBSAN reports the following warning from accessing path->path[-1] in set_path_power(): [ 16.078040] ================================================================================ [ 16.078124] UBSAN: Undefined behaviour in sound/pci/hda/hda_generic.c:3981:17 [ 16.078198] index -1 is out of range for type 'hda_nid_t [10]' [ 16.078270] CPU: 2 PID: 1738 Comm: modprobe Not tainted 4.7.0-rc1-wt+ #47 [ 16.078274] Hardware name: LENOVO 3443CTO/3443CTO, BIOS G6ET23WW (1.02 ) 08/14/2012 [ 16.078278] ffff8800cb246000 ffff8800cb3638b8 ffffffff815c4fe3 0000000000000032 [ 16.078286] ffff8800cb3638e0 ffffffffffffffff ffff8800cb3638d0 ffffffff8162443d [ 16.078294] ffffffffa0894200 ffff8800cb363920 ffffffff81624af7 0000000000000292 [ 16.078302] Call Trace: [ 16.078311] [] dump_stack+0x86/0xd3 [ 16.078317] [] ubsan_epilogue+0xd/0x40 [ 16.078324] [] __ubsan_handle_out_of_bounds+0x67/0x70 [ 16.078335] [] set_path_power+0x1bf/0x230 [snd_hda_codec_generic] [ 16.078344] [] add_pin_power_ctls+0x8d/0xc0 [snd_hda_codec_generic] [ 16.078352] [] ? pin_power_down_callback+0x20/0x20 [snd_hda_codec_generic] [ 16.078360] [] add_all_pin_power_ctls+0x107/0x150 [snd_hda_codec_generic] [ 16.078370] [] snd_hda_gen_parse_auto_config+0x2d73/0x49e0 [snd_hda_codec_generic] [ 16.078376] [] ? trace_hardirqs_on_caller+0x1b0/0x2c0 [ 16.078390] [] alc_parse_auto_config+0x147/0x310 [snd_hda_codec_realtek] [ 16.078402] [] patch_alc269+0x23a/0x560 [snd_hda_codec_realtek] [ 16.078417] [] hda_codec_driver_probe+0xa4/0x1a0 [snd_hda_codec] [ 16.078424] [] driver_probe_device+0x101/0x380 [ 16.078430] [] __driver_attach+0xb9/0x100 [ 16.078438] [] ? driver_probe_device+0x380/0x380 [ 16.078444] [] bus_for_each_dev+0x70/0xc0 [ 16.078449] [] driver_attach+0x27/0x50 [ 16.078454] [] bus_add_driver+0x166/0x2c0 [ 16.078460] [] ? 0xffffffffa0369000 [ 16.078465] [] driver_register+0x7d/0x130 [ 16.078477] [] __hda_codec_driver_register+0x6f/0x90 [snd_hda_codec] [ 16.078488] [] realtek_driver_init+0x1e/0x1000 [snd_hda_codec_realtek] [ 16.078493] [] do_one_initcall+0x4e/0x1d0 [ 16.078499] [] ? rcu_read_lock_sched_held+0x6d/0x80 [ 16.078504] [] ? kmem_cache_alloc_trace+0x391/0x560 [ 16.078510] [] ? do_init_module+0x28/0x273 [ 16.078515] [] do_init_module+0x9b/0x273 [ 16.078522] [] load_module+0x20b2/0x3410 [ 16.078527] [] ? m_show+0x210/0x210 [ 16.078533] [] ? kernel_read+0x66/0xe0 [ 16.078541] [] SYSC_finit_module+0xba/0xc0 [ 16.078547] [] SyS_finit_module+0xe/0x10 [ 16.078552] [] entry_SYSCALL_64_fastpath+0x1f/0xbd [ 16.078556] ================================================================================ Fix by checking path->depth before use. Signed-off-by: Bob Copeland Cc: Signed-off-by: Takashi Iwai sound/pci/hda/hda_generic.c | 2 ++ 1 file changed, 2 insertions(+) commit ed749a53b2d7b9287ee57c17dc29385c89104744 Merge: 33688ab 929e604e Author: Olof Johansson Date: Sat Jun 25 21:19:37 2016 -0700 Merge tag 'mvebu-fixes-4.7-1' of git://git.infradead.org/linux-mvebu into fixes mvebu fixes for 4.7 (part 1) Various I/O memory fix for Cortex A9 based SoCs * tag 'mvebu-fixes-4.7-1' of git://git.infradead.org/linux-mvebu: ARM: dts: armada-38x: fix MBUS_ID for crypto SRAM on Armada 385 Linksys ARM: mvebu: map PCI I/O regions strongly ordered ARM: mvebu: fix HW I/O coherency related deadlocks Signed-off-by: Olof Johansson commit 1b45996d2ebf9680ccd0db875fc668aa025f40fd Author: David Daney Date: Tue May 17 11:41:04 2016 -0700 tty: vt: Fix soft lockup in fbcon cursor blink timer. We are getting somewhat random soft lockups with this signature: [ 86.992215] [] el1_irq+0xa0/0x10c [ 86.997082] [] cursor_timer_handler+0x30/0x54 [ 87.002991] [] call_timer_fn+0x54/0x1a8 [ 87.008378] [] run_timer_softirq+0x1c4/0x2bc [ 87.014200] [] __do_softirq+0x114/0x344 [ 87.019590] [] irq_exit+0x74/0x98 [ 87.024458] [] __handle_domain_irq+0x98/0xfc [ 87.030278] [] gic_handle_irq+0x94/0x190 This is caused by the vt visual_init() function calling into fbcon_init() with a vc_cur_blink_ms value of zero. This is a transient condition, as it is later set to a non-zero value. But, if the timer happens to expire while the blink rate is zero, it goes into an endless loop, and we get soft lockup. The fix is to initialize vc_cur_blink_ms before calling the con_init() function. Signed-off-by: David Daney Cc: stable@vger.kernel.org Acked-by: Pavel Machek Tested-by: Ming Lei Acked-by: Scot Doyle Tested-by: Henrique de Moraes Holschuh Signed-off-by: Greg Kroah-Hartman drivers/tty/vt/vt.c | 1 + 1 file changed, 1 insertion(+) commit da2f6aba4a21f8da3331e5251a117c52764da579 Merge: b971712a 02dbfc9 Author: Linus Torvalds Date: Sat Jun 25 08:53:38 2016 -0700 Merge branch 'for-linus-4.7-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs fixes part 2 from Chris Mason: "This has one patch from Omar to bring iterate_shared back to btrfs. We have a tree of work we queue up for directory items and it doesn't lend itself well to shared access. While we're cleaning it up, Omar has changed things to use an exclusive lock when there are delayed items" * 'for-linus-4.7-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: fix ->iterate_shared() by upgrading i_rwsem for delayed nodes commit b971712afc8dd0de38e943ea9d904fe8c8aff956 Merge: ca83a55 b7f6705 Author: Linus Torvalds Date: Sat Jun 25 08:42:31 2016 -0700 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs fixes from Chris Mason: "I have a two part pull this time because one of the patches Dave Sterba collected needed to be against v4.7-rc2 or higher (we used rc4). I try to make my for-linus-xx branch testable on top of the last major so we can hand fixes to people on the list more easily, so I've split this pull in two. This first part has some fixes and two performance improvements that we've been testing for some time. Josef's two performance fixes are most notable. The transid tracking patch makes a big improvement on pretty much every workload" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: Force stripesize to the value of sectorsize btrfs: fix disk_i_size update bug when fallocate() fails Btrfs: fix error handling in map_private_extent_buffer Btrfs: fix error return code in btrfs_init_test_fs() Btrfs: don't do nocow check unless we have to btrfs: fix deadlock in delayed_ref_async_start Btrfs: track transid for delayed ref flushing commit ca83a55c9fe20b45a26101853a772e08aff90dcb Merge: 9a949a9 d5dbbe6 Author: Linus Torvalds Date: Sat Jun 25 06:55:48 2016 -0700 Merge tag 'sound-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "Again pretty calm weeks: we've had only a few trivial / stable HD-audio fixes in addition to a possible race fix for snd-dummy driver spotted by syzkaller" * tag 'sound-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: dummy: Fix a use-after-free at closing ALSA: hda / realtek - add two more Thinkpad IDs (5050,5053) for tpt460 fixup ALSA: hda - Fix the headset mic jack detection on Dell machine ALSA: hda/tegra: iomem fixups for sparse warnings ALSA: hdac_regmap - fix the register access for runtime PM commit 9a949a98596c45763299158b9018f3491e3cbf99 Merge: 57801c1 dcfc472 Author: Linus Torvalds Date: Sat Jun 25 06:49:32 2016 -0700 Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 kprobe fix from Thomas Gleixner: "A single fix clearing the TF bit when a fault is single stepped" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: kprobes/x86: Clear TF bit in fault on single-stepping commit 57801c1b817128cbb3a4dc45e6a1e0e31a227a19 Merge: e3b22bc feb245e Author: Linus Torvalds Date: Sat Jun 25 06:38:42 2016 -0700 Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Thomas Gleixner: "A couple of scheduler fixes: - force watchdog reset while processing sysrq-w - fix a deadlock when enabling trace events in the scheduler - fixes to the throttled next buddy logic - fixes for the average accounting (missing serialization and underflow handling) - allow kernel threads for fallback to online but not active cpus" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/core: Allow kthreads to fall back to online && !active cpus sched/fair: Do not announce throttled next buddy in dequeue_task_fair() sched/fair: Initialize throttle_count for new task-groups lazily sched/fair: Fix cfs_rq avg tracking underflow kernel/sysrq, watchdog, sched/core: Reset watchdog on all CPUs while processing sysrq-w sched/debug: Fix deadlock when enabling sched events sched/fair: Fix post_init_entity_util_avg() serialization commit 02dbfc99b424dde3cf0a492ed3bec4f222441754 Author: Omar Sandoval Date: Fri May 20 13:50:33 2016 -0700 Btrfs: fix ->iterate_shared() by upgrading i_rwsem for delayed nodes Commit fe742fd4f90f ("Revert "btrfs: switch to ->iterate_shared()"") backed out the conversion to ->iterate_shared() for Btrfs because the delayed inode handling in btrfs_real_readdir() is racy. However, we can still do readdir in parallel if there are no delayed nodes. This is a temporary fix which upgrades the shared inode lock to an exclusive lock only when we have delayed items until we come up with a more complete solution. While we're here, rename the btrfs_{get,put}_delayed_items functions to make it very clear that they're just for readdir. Tested with xfstests and by doing a parallel kernel build: while make tinyconfig && make -j4 && git clean dqfx; do : done along with a bunch of parallel finds in another shell: while true; do for ((i=0; i<4; i++)); do find . >/dev/null & done wait done Signed-off-by: Omar Sandoval Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/delayed-inode.c | 27 ++++++++++++++++++++++----- fs/btrfs/delayed-inode.h | 10 ++++++---- fs/btrfs/inode.c | 10 ++++++---- 3 files changed, 34 insertions(+), 13 deletions(-) commit e3b22bc3d705b4a265247a9e2a1dea9ecf01a0cd Merge: 2de2307 4c5ea0a Author: Linus Torvalds Date: Sat Jun 25 06:14:44 2016 -0700 Merge branch 'locking-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull locking fix from Thomas Gleixner: "A single fix to address a race in the static key logic" * 'locking-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: locking/static_key: Fix concurrent static_key_slow_inc() commit 2de23071f5f7eb80a6cccf45438b271da81246af Merge: 2f6e974 4b2312b Author: Linus Torvalds Date: Sat Jun 25 06:09:59 2016 -0700 Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull irq fix from Thomas Gleixner: "A single fix for the fallout from the conversion of MIPS GIC to irq domains" * 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: irqchip/mips-gic: Fix IRQs in gic_dev_domain commit 2f6e97477bb44f8d1b36e6ead62b4934052d884d Merge: 9521d39 844e3be Author: Linus Torvalds Date: Sat Jun 25 06:01:48 2016 -0700 Merge tag 'powerpc-4.7-4' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from Michael Ellerman: "mm/radix (Aneesh Kumar K.V): - Update to tlb functions ric argument - Flush page walk cache when freeing page table - Update Radix tree size as per ISA 3.0 mm/hash (Aneesh Kumar K.V): - Use the correct PPP mask when updating HPTE - Don't add memory coherence if cache inhibited is set eeh (Gavin Shan): - Fix invalid cached PE primary bus bpf/jit (Naveen N. Rao): - Disable classic BPF JIT on ppc64le .. and fix faults caused by radix patching of SLB miss handler (Michael Ellerman)" * tag 'powerpc-4.7-4' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc/bpf/jit: Disable classic BPF JIT on ppc64le powerpc: Fix faults caused by radix patching of SLB miss handler powerpc/eeh: Fix invalid cached PE primary bus powerpc/mm/radix: Update Radix tree size as per ISA 3.0 powerpc/mm/hash: Don't add memory coherence if cache inhibited is set powerpc/mm/hash: Use the correct PPP mask when updating HPTE powerpc/mm/radix: Flush page walk cache when freeing page table powerpc/mm/radix: Update to tlb functions ric argument commit 9521d39976db20f8ef9b56af66661482a17d5364 Author: Michael Ellerman Date: Sat Jun 25 21:53:30 2016 +1000 Fix build break in fork.c when THREAD_SIZE < PAGE_SIZE Commit b235beea9e99 ("Clarify naming of thread info/stack allocators") breaks the build on some powerpc configs, where THREAD_SIZE < PAGE_SIZE: kernel/fork.c:235:2: error: implicit declaration of function 'free_thread_stack' kernel/fork.c:355:8: error: assignment from incompatible pointer type stack = alloc_thread_stack_node(tsk, node); ^ Fix it by renaming free_stack() to free_thread_stack(), and updating the return type of alloc_thread_stack_node(). Fixes: b235beea9e99 ("Clarify naming of thread info/stack allocators") Signed-off-by: Michael Ellerman Signed-off-by: Linus Torvalds kernel/fork.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b42b90d177d0c7f46f9c888c10c7900578ae7e09 Author: Al Viro Date: Fri Jun 24 23:49:03 2016 -0400 ceph: fix d_obtain_alias() misuses on failure d_obtain_alias() will have done iput() Signed-off-by: Al Viro fs/ceph/export.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 086e3eb65e3b04d7186f5e527aa6fc375dd5495c Merge: aebe9bb 0fd5ed8 Author: Linus Torvalds Date: Fri Jun 24 19:08:33 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge misc fixes from Andrew Morton: "Two weeks worth of fixes here" * emailed patches from Andrew Morton : (41 commits) init/main.c: fix initcall_blacklisted on ia64, ppc64 and parisc64 autofs: don't get stuck in a loop if vfs_write() returns an error mm/page_owner: avoid null pointer dereference tools/vm/slabinfo: fix spelling mistake: "Ocurrences" -> "Occurrences" fs/nilfs2: fix potential underflow in call to crc32_le oom, suspend: fix oom_reaper vs. oom_killer_disable race ocfs2: disable BUG assertions in reading blocks mm, compaction: abort free scanner if split fails mm: prevent KASAN false positives in kmemleak mm/hugetlb: clear compound_mapcount when freeing gigantic pages mm/swap.c: flush lru pvecs on compound page arrival memcg: css_alloc should return an ERR_PTR value on error memcg: mem_cgroup_migrate() may be called with irq disabled hugetlb: fix nr_pmds accounting with shared page tables Revert "mm: disable fault around on emulated access bit architecture" Revert "mm: make faultaround produce old ptes" mailmap: add Boris Brezillon's email mailmap: add Antoine Tenart's email mm, sl[au]b: add __GFP_ATOMIC to the GFP reclaim mask mm: mempool: kasan: don't poot mempool objects in quarantine ... commit aebe9bb85e6358dc85f81533b14f5c2dfe14c8b4 Merge: 3fb5e59 9903fd1 Author: Linus Torvalds Date: Fri Jun 24 18:52:31 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma Pull rdma fixes from Doug Ledford: "This is the second batch of queued up rdma patches for this rc cycle. There isn't anything really major in here. It's passed 0day, linux-next, and local testing across a wide variety of hardware. There are still a few known issues to be tracked down, but this should amount to the vast majority of the rdma RC fixes. Round two of 4.7 rc fixes: - A couple minor fixes to the rdma core - Multiple minor fixes to hfi1 - Multiple minor fixes to mlx4/mlx4 - A few minor fixes to i40iw" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: (31 commits) IB/srpt: Reduce QP buffer size i40iw: Enable level-1 PBL for fast memory registration i40iw: Return correct max_fast_reg_page_list_len i40iw: Correct status check on i40iw_get_pble i40iw: Correct CQ arming IB/rdmavt: Correct qp_priv_alloc() return value test IB/hfi1: Don't zero out qp->s_ack_queue in rvt_reset_qp IB/hfi1: Fix deadlock with txreq allocation slow path IB/mlx4: Prevent cross page boundary allocation IB/mlx4: Fix memory leak if QP creation failed IB/mlx4: Verify port number in flow steering create flow IB/mlx4: Fix error flow when sending mads under SRIOV IB/mlx4: Fix the SQ size of an RC QP IB/mlx5: Fix wrong naming of port_rcv_data counter IB/mlx5: Fix post send fence logic IB/uverbs: Initialize ib_qp_init_attr with zeros IB/core: Fix false search of the IB_SA_WELL_KNOWN_GUID IB/core: Fix RoCE v1 multicast join logic issue IB/core: Fix no default GIDs when netdevice reregisters IB/hfi1: Send a pkey change event on driver pkey update ... commit 3fb5e59c888759407f2130e6c6213d1244de465c Merge: 260eaba 93a2001 Author: Linus Torvalds Date: Fri Jun 24 18:43:58 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid Pull HID fix from Jiri Kosina: "hiddev ioctl() validation fix from Scott Bauer" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid: HID: hiddev: validate num_values for HIDIOCGUSAGES, HIDIOCSUSAGES commands commit 260eaba4eaf0daec2e21735de30de14b1d6a4d08 Merge: ed13fbb 5ce9171 Author: Linus Torvalds Date: Fri Jun 24 18:36:15 2016 -0700 Merge tag 'hwmon-for-linus-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging Pull hwmon fix from Guenter Roeck: "Improve fan type detection for dell-smm to prevent kernel hang" * tag 'hwmon-for-linus-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: hwmon: (dell-smm) Cache fan_type() calls and change fan detection commit ed13fbbf871cf0198b283c563b6394b02b31646c Merge: 3522b35 2605b98 Author: Linus Torvalds Date: Fri Jun 24 18:29:55 2016 -0700 Merge tag 'acpi-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fix from Rafael Wysocki: "Stable-candidate fix for a deadlock in ACPICA introduced during the 4.5 development cycle by a commit attempting to improve the handling of AML code that doesn't belong to any namespace objects in a given definition block (Lv Zheng)" * tag 'acpi-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading commit 3522b35cb2e2e24e03edf112e6466f3a626918a9 Merge: 032fd3e e753f30 Author: Linus Torvalds Date: Fri Jun 24 18:03:22 2016 -0700 Merge tag 'pm-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "Fix for a latent cpufreq driver bug uncovered by a recent ACPICA change and several fixes for the devfreq framework, including one fix for an issue introduced recently. Specifics: - Fix a latent initialization issue in the pcc-cpufreq driver (incorrect initial value of a structure field) that has been uncovered by a recent ACPICA commit (Mike Galbraith). - Add a missing notification in an update_devfreq() error code path forgotten by a recent devfreq commit (Chanwoo Choi). - Fix devfreq device frequency initialization (Lukasz Luba). - Fix an incorrect IS_ERR() check in the devfreq framework discovered by the Smatch checker (Dan Carpenter). - Drop two excessive put_device() calls from the devfreq framework (MyungJoo Ham, Cai Zhiyong). - Fix a possible memory leak in the devfreq framework and drop an unnecessary kfree() invocation from it (MyungJoo Ham)" * tag 'pm-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PM / devfreq: Send the DEVFREQ_POSTCHANGE notification when target() is failed cpufreq: pcc-cpufreq: Fix doorbell.access_width PM / devfreq: fix initialization of current frequency in last status PM / devfreq: exynos-nocp: Remove incorrect IS_ERR() check PM / devfreq: remove double put_device PM / devfreq: fix double call put_device PM / devfreq: fix duplicated kfree on devfreq pointer PM / devfreq: devm_kzalloc to have dev pointer more precisely commit 032fd3e58c428c98538cc69113dd11b2801bf35a Merge: d05be0d d2bd05d Author: Linus Torvalds Date: Fri Jun 24 17:57:37 2016 -0700 Merge tag 'for-linus-4.7b-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip Pull xen bug fixes from David Vrabel: - fix x86 PV dom0 crash during early boot on some hardware - fix two pciback bugs affects certain devices - fix potential overflow when clearing page tables in x86 PV * tag 'for-linus-4.7b-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen-pciback: return proper values during BAR sizing x86/xen: avoid m2p lookup when setting early page table entries xen/pciback: Fix conf_space read/write overlap check. x86/xen: fix upper bound of pmd loop in xen_cleanhighmap() xen/balloon: Fix declared-but-not-defined warning commit d05be0d7e87b7808525e6bc000a87e095cc80040 Merge: 9c46a6d d74b4e4 Author: Linus Torvalds Date: Fri Jun 24 17:51:14 2016 -0700 Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 fixes from Will Deacon: "Here are a few more arm64 fixes, but things do finally appear to be slowing down. The main fix is avoiding hibernation in a previously unanticipated situation where we have CPUs parked in the kernel, but it's all good stuff. - Fix icache/dcache sync for anonymous pages under migration - Correct the ASID limit check - Fix parallel builds of Image and Image.gz - Refuse to hibernate when we have CPUs that we can't offline" * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: hibernate: Don't hibernate on systems with stuck CPUs arm64: smp: Add function to determine if cpus are stuck in the kernel arm64: mm: remove page_mapping check in __sync_icache_dcache arm64: fix boot image dependencies to not generate invalid images arm64: update ASID limit commit 0fd5ed8d897cffdc74903931bd7fcc9d8d154460 Author: Rasmus Villemoes Date: Fri Jun 24 14:50:30 2016 -0700 init/main.c: fix initcall_blacklisted on ia64, ppc64 and parisc64 When I replaced kasprintf("%pf") with a direct call to sprint_symbol_no_offset I must have broken the initcall blacklisting feature on the arches where dereference_function_descriptor() is non-trivial. Fixes: c8cdd2be213f (init/main.c: simplify initcall_blacklisted()) Link: http://lkml.kernel.org/r/1466027283-4065-1-git-send-email-linux@rasmusvillemoes.dk Signed-off-by: Rasmus Villemoes Cc: Yang Shi Cc: Prarit Bhargava Cc: Petr Mladek Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds init/main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 5a9294e5c535deab69831076af15cd35e1c95f8b Author: Andrey Vagin Date: Fri Jun 24 14:50:27 2016 -0700 autofs: don't get stuck in a loop if vfs_write() returns an error __vfs_write() returns a negative value in a error case. Link: http://lkml.kernel.org/r/20160616083108.6278.65815.stgit@pluto.themaw.net Signed-off-by: Andrey Vagin Signed-off-by: Ian Kent Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds fs/autofs4/waitq.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 8285027fc479949a7a166bc1b26ce57e894878a7 Author: Sudip Mukherjee Date: Fri Jun 24 14:50:24 2016 -0700 mm/page_owner: avoid null pointer dereference We have dereferenced page_ext before checking it. Lets check it first and then used it. Fixes: f86e4271978b ("mm: check the return value of lookup_page_ext for all call sites") Link: http://lkml.kernel.org/r/1465249059-7883-1-git-send-email-sudipm.mukherjee@gmail.com Signed-off-by: Sudip Mukherjee Acked-by: Vlastimil Babka Cc: Joonsoo Kim Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_owner.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 7c5b7239465932400ee0825bcc90624717c1af19 Author: Colin Ian King Date: Fri Jun 24 14:50:21 2016 -0700 tools/vm/slabinfo: fix spelling mistake: "Ocurrences" -> "Occurrences" trivial fix to spelling mistake Link: http://lkml.kernel.org/r/1466672144-831-1-git-send-email-colin.king@canonical.com Signed-off-by: Colin Ian King Acked-by: Christoph Lameter Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds tools/vm/slabinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 63d2f95d63396059200c391ca87161897b99e74a Author: Torsten Hilbrich Date: Fri Jun 24 14:50:18 2016 -0700 fs/nilfs2: fix potential underflow in call to crc32_le The value `bytes' comes from the filesystem which is about to be mounted. We cannot trust that the value is always in the range we expect it to be. Check its value before using it to calculate the length for the crc32_le call. It value must be larger (or equal) sumoff + 4. This fixes a kernel bug when accidentially mounting an image file which had the nilfs2 magic value 0x3434 at the right offset 0x406 by chance. The bytes 0x01 0x00 were stored at 0x408 and were interpreted as a s_bytes value of 1. This caused an underflow when substracting sumoff + 4 (20) in the call to crc32_le. BUG: unable to handle kernel paging request at ffff88021e600000 IP: crc32_le+0x36/0x100 ... Call Trace: nilfs_valid_sb.part.5+0x52/0x60 [nilfs2] nilfs_load_super_block+0x142/0x300 [nilfs2] init_nilfs+0x60/0x390 [nilfs2] nilfs_mount+0x302/0x520 [nilfs2] mount_fs+0x38/0x160 vfs_kern_mount+0x67/0x110 do_mount+0x269/0xe00 SyS_mount+0x9f/0x100 entry_SYSCALL_64_fastpath+0x16/0x71 Link: http://lkml.kernel.org/r/1466778587-5184-2-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Torsten Hilbrich Tested-by: Torsten Hilbrich Signed-off-by: Ryusuke Konishi Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds fs/nilfs2/the_nilfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 74070542099c66d87aebeacd7b54dc0e8b6a73f9 Author: Michal Hocko Date: Fri Jun 24 14:50:16 2016 -0700 oom, suspend: fix oom_reaper vs. oom_killer_disable race Tetsuo has reported the following potential oom_killer_disable vs. oom_reaper race: (1) freeze_processes() starts freezing user space threads. (2) Somebody (maybe a kenrel thread) calls out_of_memory(). (3) The OOM killer calls mark_oom_victim() on a user space thread P1 which is already in __refrigerator(). (4) oom_killer_disable() sets oom_killer_disabled = true. (5) P1 leaves __refrigerator() and enters do_exit(). (6) The OOM reaper calls exit_oom_victim(P1) before P1 can call exit_oom_victim(P1). (7) oom_killer_disable() returns while P1 not yet finished (8) P1 perform IO/interfere with the freezer. This situation is unfortunate. We cannot move oom_killer_disable after all the freezable kernel threads are frozen because the oom victim might depend on some of those kthreads to make a forward progress to exit so we could deadlock. It is also far from trivial to teach the oom_reaper to not call exit_oom_victim() because then we would lose a guarantee of the OOM killer and oom_killer_disable forward progress because exit_mm->mmput might block and never call exit_oom_victim. It seems the easiest way forward is to workaround this race by calling try_to_freeze_tasks again after oom_killer_disable. This will make sure that all the tasks are frozen or it bails out. Fixes: 449d777d7ad6 ("mm, oom_reaper: clear TIF_MEMDIE for all tasks queued for oom_reaper") Link: http://lkml.kernel.org/r/1466597634-16199-1-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Reported-by: Tetsuo Handa Cc: "Rafael J. Wysocki" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds kernel/power/process.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 7186ee06b66313dae0d34ec5241fda7c4a537cb9 Author: Gang He Date: Fri Jun 24 14:50:13 2016 -0700 ocfs2: disable BUG assertions in reading blocks According to some high-load testing, these two BUG assertions were encountered, this led system panic. Actually, there were some discussions about removing these two BUG() assertions, it would not bring any side effect. Then, I did the the following changes, 1) use the existing macro CATCH_BH_JBD_RACES to wrap BUG() in the ocfs2_read_blocks_sync function like before. 2) disable the macro CATCH_BH_JBD_RACES in Makefile by default. Link: http://lkml.kernel.org/r/1466574294-26863-1-git-send-email-ghe@suse.com Signed-off-by: Gang He Cc: Mark Fasheh Cc: Joel Becker Cc: Junxiao Bi Cc: Joseph Qi Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds fs/ocfs2/Makefile | 2 -- fs/ocfs2/buffer_head_io.c | 5 +++++ 2 files changed, 5 insertions(+), 2 deletions(-) commit a4f04f2c6955aff5e2c08dcb40aca247ff4d7370 Author: David Rientjes Date: Fri Jun 24 14:50:10 2016 -0700 mm, compaction: abort free scanner if split fails If the memory compaction free scanner cannot successfully split a free page (only possible due to per-zone low watermark), terminate the free scanner rather than continuing to scan memory needlessly. If the watermark is insufficient for a free page of order <= cc->order, then terminate the scanner since all future splits will also likely fail. This prevents the compaction freeing scanner from scanning all memory on very large zones (very noticeable for zones > 128GB, for instance) when all splits will likely fail while holding zone->lock. compaction_alloc() iterating a 128GB zone has been benchmarked to take over 400ms on some systems whereas any free page isolated and ready to be split ends up failing in split_free_page() because of the low watermark check and thus the iteration continues. The next time compaction occurs, the freeing scanner will likely start at the end of the zone again since no success was made previously and we get the same lengthy iteration until the zone is brought above the low watermark. All thp page faults can take >400ms in such a state without this fix. Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1606211820350.97086@chino.kir.corp.google.com Signed-off-by: David Rientjes Acked-by: Vlastimil Babka Cc: Minchan Kim Cc: Joonsoo Kim Cc: Mel Gorman Cc: Hugh Dickins Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/compaction.c | 39 +++++++++++++++++++++------------------ 1 file changed, 21 insertions(+), 18 deletions(-) commit 5c335fe020ea287b2b49cc4dfca9f6756b88bb71 Author: Dmitry Vyukov Date: Fri Jun 24 14:50:07 2016 -0700 mm: prevent KASAN false positives in kmemleak When kmemleak dumps contents of leaked objects it reads whole objects regardless of user-requested size. This upsets KASAN. Disable KASAN checks around object dump. Link: http://lkml.kernel.org/r/1466617631-68387-1-git-send-email-dvyukov@google.com Signed-off-by: Dmitry Vyukov Acked-by: Catalin Marinas Cc: Andrey Ryabinin Cc: Alexander Potapenko Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/kmemleak.c | 2 ++ 1 file changed, 2 insertions(+) commit c8cc708a340cc7c5445565079fd4d1c28898d7a2 Author: Gerald Schaefer Date: Fri Jun 24 14:50:04 2016 -0700 mm/hugetlb: clear compound_mapcount when freeing gigantic pages While working on s390 support for gigantic hugepages I ran into the following "Bad page state" warning when freeing gigantic pages: BUG: Bad page state in process bash pfn:580001 page:000003d116000040 count:0 mapcount:0 mapping:ffffffff00000000 index:0x0 flags: 0x7fffc0000000000() page dumped because: non-NULL mapping This is because page->compound_mapcount, which is part of a union with page->mapping, is initialized with -1 in prep_compound_gigantic_page(), and not cleared again during destroy_compound_gigantic_page(). Fix this by clearing the compound_mapcount in destroy_compound_gigantic_page() before clearing compound_head. Interestingly enough, the warning will not show up on x86_64, although this should not be architecture specific. Apparently there is an endianness issue, combined with the fact that the union contains both a 64 bit ->mapping pointer and a 32 bit atomic_t ->compound_mapcount as members. The resulting bogus page->mapping on x86_64 therefore contains 00000000ffffffff instead of ffffffff00000000 on s390, which will falsely trigger the PageAnon() check in free_pages_prepare() because page->mapping & PAGE_MAPPING_ANON is true on little-endian architectures like x86_64 in this case (the page is not compound anymore, ->compound_head was already cleared before). As a result, page->mapping will be cleared before doing the checks in free_pages_check(). Not sure if the bogus "PageAnon() returning true" on x86_64 for the first tail page of a gigantic page (at this stage) has other theoretical implications, but they would also be fixed with this patch. Link: http://lkml.kernel.org/r/1466612719-5642-1-git-send-email-gerald.schaefer@de.ibm.com Signed-off-by: Gerald Schaefer Reviewed-by: Mike Kravetz Cc: Luiz Capitulino Cc: Naoya Horiguchi Cc: Hillf Danton Cc: "Kirill A . Shutemov" Cc: Dave Hansen Cc: Paul Gortmaker Cc: "Aneesh Kumar K . V" Cc: Martin Schwidefsky Cc: Heiko Carstens Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/hugetlb.c | 1 + 1 file changed, 1 insertion(+) commit 8f182270dfec432e93fae14f9208a6b9af01009f Author: Lukasz Odzioba Date: Fri Jun 24 14:50:01 2016 -0700 mm/swap.c: flush lru pvecs on compound page arrival Currently we can have compound pages held on per cpu pagevecs, which leads to a lot of memory unavailable for reclaim when needed. In the systems with hundreads of processors it can be GBs of memory. On of the way of reproducing the problem is to not call munmap explicitly on all mapped regions (i.e. after receiving SIGTERM). After that some pages (with THP enabled also huge pages) may end up on lru_add_pvec, example below. void main() { #pragma omp parallel { size_t size = 55 * 1000 * 1000; // smaller than MEM/CPUS void *p = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS , -1, 0); if (p != MAP_FAILED) memset(p, 0, size); //munmap(p, size); // uncomment to make the problem go away } } When we run it with THP enabled it will leave significant amount of memory on lru_add_pvec. This memory will be not reclaimed if we hit OOM, so when we run above program in a loop: for i in `seq 100`; do ./a.out; done many processes (95% in my case) will be killed by OOM. The primary point of the LRU add cache is to save the zone lru_lock contention with a hope that more pages will belong to the same zone and so their addition can be batched. The huge page is already a form of batched addition (it will add 512 worth of memory in one go) so skipping the batching seems like a safer option when compared to a potential excess in the caching which can be quite large and much harder to fix because lru_add_drain_all is way to expensive and it is not really clear what would be a good moment to call it. Similarly we can reproduce the problem on lru_deactivate_pvec by adding: madvise(p, size, MADV_FREE); after memset. This patch flushes lru pvecs on compound page arrival making the problem less severe - after applying it kill rate of above example drops to 0%, due to reducing maximum amount of memory held on pvec from 28MB (with THP) to 56kB per CPU. Suggested-by: Michal Hocko Link: http://lkml.kernel.org/r/1466180198-18854-1-git-send-email-lukasz.odzioba@intel.com Signed-off-by: Lukasz Odzioba Acked-by: Michal Hocko Cc: Kirill Shutemov Cc: Andrea Arcangeli Cc: Vladimir Davydov Cc: Ming Li Cc: Minchan Kim Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/swap.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit ea3a9645866e12d2b198434f03df3c3e96fb86ce Author: Tejun Heo Date: Fri Jun 24 14:49:58 2016 -0700 memcg: css_alloc should return an ERR_PTR value on error mem_cgroup_css_alloc() was returning NULL on failure while cgroup core expected it to return an ERR_PTR value leading to the following NULL deref after a css allocation failure. Fix it by return ERR_PTR(-ENOMEM) instead. I'll also update cgroup core so that it can handle NULL returns. mkdir: page allocation failure: order:6, mode:0x240c0c0(GFP_KERNEL|__GFP_COMP|__GFP_ZERO) CPU: 0 PID: 8738 Comm: mkdir Not tainted 4.7.0-rc3+ #123 ... Call Trace: dump_stack+0x68/0xa1 warn_alloc_failed+0xd6/0x130 __alloc_pages_nodemask+0x4c6/0xf20 alloc_pages_current+0x66/0xe0 alloc_kmem_pages+0x14/0x80 kmalloc_order_trace+0x2a/0x1a0 __kmalloc+0x291/0x310 memcg_update_all_caches+0x6c/0x130 mem_cgroup_css_alloc+0x590/0x610 cgroup_apply_control_enable+0x18b/0x370 cgroup_mkdir+0x1de/0x2e0 kernfs_iop_mkdir+0x55/0x80 vfs_mkdir+0xb9/0x150 SyS_mkdir+0x66/0xd0 do_syscall_64+0x53/0x120 entry_SYSCALL64_slow_path+0x25/0x25 ... BUG: unable to handle kernel NULL pointer dereference at 00000000000000d0 IP: init_and_link_css+0x37/0x220 PGD 34b1e067 PUD 3a109067 PMD 0 Oops: 0002 [#1] SMP Modules linked in: CPU: 0 PID: 8738 Comm: mkdir Not tainted 4.7.0-rc3+ #123 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.2-20160422_131301-anatol 04/01/2014 task: ffff88007cbc5200 ti: ffff8800666d4000 task.ti: ffff8800666d4000 RIP: 0010:[] [] init_and_link_css+0x37/0x220 RSP: 0018:ffff8800666d7d90 EFLAGS: 00010246 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000 RDX: ffffffff810f2499 RSI: 0000000000000000 RDI: 0000000000000008 RBP: ffff8800666d7db8 R08: 0000000000000003 R09: 0000000000000000 R10: 0000000000000001 R11: 0000000000000000 R12: ffff88005a5fb400 R13: ffffffff81f0f8a0 R14: ffff88005a5fb400 R15: 0000000000000010 FS: 00007fc944689700(0000) GS:ffff88007fc00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f3aed0d2b80 CR3: 000000003a1e8000 CR4: 00000000000006f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: cgroup_apply_control_enable+0x1ac/0x370 cgroup_mkdir+0x1de/0x2e0 kernfs_iop_mkdir+0x55/0x80 vfs_mkdir+0xb9/0x150 SyS_mkdir+0x66/0xd0 do_syscall_64+0x53/0x120 entry_SYSCALL64_slow_path+0x25/0x25 Code: 89 f5 48 89 fb 49 89 d4 48 83 ec 08 8b 05 72 3b d8 00 85 c0 0f 85 60 01 00 00 4c 89 e7 e8 72 f7 ff ff 48 8d 7b 08 48 89 d9 31 c0 <48> c7 83 d0 00 00 00 00 00 00 00 48 83 e7 f8 48 29 f9 81 c1 d8 RIP init_and_link_css+0x37/0x220 RSP CR2: 00000000000000d0 ---[ end trace a2d8836ae1e852d1 ]--- Link: http://lkml.kernel.org/r/20160621165740.GJ3262@mtj.duckdns.org Signed-off-by: Tejun Heo Reported-by: Johannes Weiner Reviewed-by: Vladimir Davydov Acked-by: Johannes Weiner Acked-by: Michal Hocko Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/memcontrol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d93c4130a7d049b234b5d5a15808eaf5406f2789 Author: Tejun Heo Date: Fri Jun 24 14:49:54 2016 -0700 memcg: mem_cgroup_migrate() may be called with irq disabled mem_cgroup_migrate() uses local_irq_disable/enable() but can be called with irq disabled from migrate_page_copy(). This ends up enabling irq while holding a irq context lock triggering the following lockdep warning. Fix it by using irq_save/restore instead. ================================= [ INFO: inconsistent lock state ] 4.7.0-rc1+ #52 Tainted: G W --------------------------------- inconsistent {IN-SOFTIRQ-W} -> {SOFTIRQ-ON-W} usage. kcompactd0/151 [HC0[0]:SC0[0]:HE1:SE1] takes: (&(&ctx->completion_lock)->rlock){+.?.-.}, at: [<000000000038fd96>] aio_migratepage+0x156/0x1e8 {IN-SOFTIRQ-W} state was registered at: __lock_acquire+0x5b6/0x1930 lock_acquire+0xee/0x270 _raw_spin_lock_irqsave+0x66/0xb0 aio_complete+0x98/0x328 dio_complete+0xe4/0x1e0 blk_update_request+0xd4/0x450 scsi_end_request+0x48/0x1c8 scsi_io_completion+0x272/0x698 blk_done_softirq+0xca/0xe8 __do_softirq+0xc8/0x518 irq_exit+0xee/0x110 do_IRQ+0x6a/0x88 io_int_handler+0x11a/0x25c __mutex_unlock_slowpath+0x144/0x1d8 __mutex_unlock_slowpath+0x140/0x1d8 kernfs_iop_permission+0x64/0x80 __inode_permission+0x9e/0xf0 link_path_walk+0x6e/0x510 path_lookupat+0xc4/0x1a8 filename_lookup+0x9c/0x160 user_path_at_empty+0x5c/0x70 SyS_readlinkat+0x68/0x140 system_call+0xd6/0x270 irq event stamp: 971410 hardirqs last enabled at (971409): migrate_page_move_mapping+0x3ea/0x588 hardirqs last disabled at (971410): _raw_spin_lock_irqsave+0x3c/0xb0 softirqs last enabled at (970526): __do_softirq+0x460/0x518 softirqs last disabled at (970519): irq_exit+0xee/0x110 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&(&ctx->completion_lock)->rlock); lock(&(&ctx->completion_lock)->rlock); *** DEADLOCK *** 3 locks held by kcompactd0/151: #0: (&(&mapping->private_lock)->rlock){+.+.-.}, at: aio_migratepage+0x42/0x1e8 #1: (&ctx->ring_lock){+.+.+.}, at: aio_migratepage+0x5a/0x1e8 #2: (&(&ctx->completion_lock)->rlock){+.?.-.}, at: aio_migratepage+0x156/0x1e8 stack backtrace: CPU: 20 PID: 151 Comm: kcompactd0 Tainted: G W 4.7.0-rc1+ #52 Call Trace: show_trace+0xea/0xf0 show_stack+0x72/0xf0 dump_stack+0x9a/0xd8 print_usage_bug.part.27+0x2d4/0x2e8 mark_lock+0x17e/0x758 mark_held_locks+0xa2/0xd0 trace_hardirqs_on_caller+0x140/0x1c0 mem_cgroup_migrate+0x266/0x370 aio_migratepage+0x16a/0x1e8 move_to_new_page+0xb0/0x260 migrate_pages+0x8f4/0x9f0 compact_zone+0x4dc/0xdc8 kcompactd_do_work+0x1aa/0x358 kcompactd+0xba/0x2c8 kthread+0x10a/0x110 kernel_thread_starter+0x6/0xc kernel_thread_starter+0x0/0xc INFO: lockdep is turned off. Link: http://lkml.kernel.org/r/20160620184158.GO3262@mtj.duckdns.org Link: http://lkml.kernel.org/g/5767CFE5.7080904@de.ibm.com Fixes: 74485cf2bc85 ("mm: migrate: consolidate mem_cgroup_migrate() calls") Signed-off-by: Tejun Heo Reported-by: Christian Borntraeger Acked-by: Johannes Weiner Acked-by: Michal Hocko Reviewed-by: Vladimir Davydov Cc: [4.5+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/memcontrol.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit c17b1f42594eb71b8d3eb5a6dfc907a7eb88a51d Author: Kirill A. Shutemov Date: Fri Jun 24 14:49:51 2016 -0700 hugetlb: fix nr_pmds accounting with shared page tables We account HugeTLB's shared page table to all processes who share it. The accounting happens during huge_pmd_share(). If somebody populates pud entry under us, we should decrease pagetable's refcount and decrease nr_pmds of the process. By mistake, I increase nr_pmds again in this case. :-/ It will lead to "BUG: non-zero nr_pmds on freeing mm: 2" on process' exit. Let's fix this by increasing nr_pmds only when we're sure that the page table will be used. Link: http://lkml.kernel.org/r/20160617122506.GC6534@node.shutemov.name Fixes: dc6c9a35b66b ("mm: account pmd page tables to the process") Signed-off-by: Kirill A. Shutemov Reported-by: zhongjiang Reviewed-by: Mike Kravetz Acked-by: Michal Hocko Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/hugetlb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 06d8fbc7cfd655d202cfac9870bd79c18c2db698 Author: Kirill A. Shutemov Date: Fri Jun 24 14:49:48 2016 -0700 Revert "mm: disable fault around on emulated access bit architecture" This reverts commit d0834a6c2c5b0c76cfb806bd7dba6556d8b4edbb. After revert of 5c0a85fad949 ("mm: make faultaround produce old ptes") faultaround doesn't have dependencies on hardware accessed bit, so let's revert this one too. Link: http://lkml.kernel.org/r/1465893750-44080-3-git-send-email-kirill.shutemov@linux.intel.com Signed-off-by: Kirill A. Shutemov Reported-by: "Huang, Ying" Cc: Linus Torvalds Cc: Rik van Riel Cc: Mel Gorman Cc: Michal Hocko Cc: Minchan Kim Cc: Vinayak Menon Cc: Dave Hansen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/memory.c | 8 -------- 1 file changed, 8 deletions(-) commit 315d09bf30c2b436a1fdac86d31c24380cd56c4f Author: Kirill A. Shutemov Date: Fri Jun 24 14:49:45 2016 -0700 Revert "mm: make faultaround produce old ptes" This reverts commit 5c0a85fad949212b3e059692deecdeed74ae7ec7. The commit causes ~6% regression in unixbench. Let's revert it for now and consider other solution for reclaim problem later. Link: http://lkml.kernel.org/r/1465893750-44080-2-git-send-email-kirill.shutemov@linux.intel.com Signed-off-by: Kirill A. Shutemov Reported-by: "Huang, Ying" Cc: Linus Torvalds Cc: Rik van Riel Cc: Mel Gorman Cc: Michal Hocko Cc: Minchan Kim Cc: Vinayak Menon Cc: Dave Hansen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/mm.h | 2 +- mm/filemap.c | 2 +- mm/memory.c | 23 +++++------------------ 3 files changed, 7 insertions(+), 20 deletions(-) commit 1f08fe266560fc2d1383fd9c8c08fdd432ea302b Author: Antoine Tenart Date: Fri Jun 24 14:49:42 2016 -0700 mailmap: add Boris Brezillon's email There are different versions of Boris' name and email in the log, and one typo. Add his emails in mailmap to have all of his contributions under the same name/email tuple. Link: http://lkml.kernel.org/r/20160609130323.27706-2-antoine.tenart@free-electrons.com Signed-off-by: Antoine Tenart Acked-by: Boris Brezillon Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds .mailmap | 3 +++ 1 file changed, 3 insertions(+) commit a8a47ff53462c3043778c04b3ba7230a39c476bf Author: Antoine Tenart Date: Fri Jun 24 14:49:39 2016 -0700 mailmap: add Antoine Tenart's email I used "Antoine Ténart" at first but then moved to a name without accent as this cause some issues from time to time... Add my email in the mailmap file to have a consistent shortlog output. Link: http://lkml.kernel.org/r/20160609130323.27706-1-antoine.tenart@free-electrons.com Signed-off-by: Antoine Tenart Cc: Antoine Tenart Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds .mailmap | 1 + 1 file changed, 1 insertion(+) commit e838a45f9392a5bd2be1cd3ab0b16ae85857461c Author: Mel Gorman Date: Fri Jun 24 14:49:37 2016 -0700 mm, sl[au]b: add __GFP_ATOMIC to the GFP reclaim mask Commit d0164adc89f6 ("mm, page_alloc: distinguish between being unable to sleep, unwilling to sleep and avoiding waking kswapd") modified __GFP_WAIT to explicitly identify the difference between atomic callers and those that were unwilling to sleep. Later the definition was removed entirely. The GFP_RECLAIM_MASK is the set of flags that affect watermark checking and reclaim behaviour but __GFP_ATOMIC was never added. Without it, atomic users of the slab allocator strip the __GFP_ATOMIC flag and cannot access the page allocator atomic reserves. This patch addresses the problem. The user-visible impact depends on the workload but potentially atomic allocations unnecessarily fail without this path. Link: http://lkml.kernel.org/r/20160610093832.GK2527@techsingularity.net Signed-off-by: Mel Gorman Reported-by: Marcin Wojtas Acked-by: Vlastimil Babka Acked-by: Michal Hocko Cc: [4.4+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/internal.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9b75a867cc9ddbafcaf35029358ac500f2635ff3 Author: Andrey Ryabinin Date: Fri Jun 24 14:49:34 2016 -0700 mm: mempool: kasan: don't poot mempool objects in quarantine Currently we may put reserved by mempool elements into quarantine via kasan_kfree(). This is totally wrong since quarantine may really free these objects. So when mempool will try to use such element, use-after-free will happen. Or mempool may decide that it no longer need that element and double-free it. So don't put object into quarantine in kasan_kfree(), just poison it. Rename kasan_kfree() to kasan_poison_kfree() to respect that. Also, we shouldn't use kasan_slab_alloc()/kasan_krealloc() in kasan_unpoison_element() because those functions may update allocation stacktrace. This would be wrong for the most of the remove_element call sites. (The only call site where we may want to update alloc stacktrace is in mempool_alloc(). Kmemleak solves this by calling kmemleak_update_trace(), so we could make something like that too. But this is out of scope of this patch). Fixes: 55834c59098d ("mm: kasan: initial memory quarantine implementation") Link: http://lkml.kernel.org/r/575977C3.1010905@virtuozzo.com Signed-off-by: Andrey Ryabinin Reported-by: Kuthonuzo Luruo Acked-by: Alexander Potapenko Cc: Dmitriy Vyukov Cc: Kostya Serebryany Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds include/linux/kasan.h | 11 +++++++---- mm/kasan/kasan.c | 6 +++--- mm/mempool.c | 12 ++++-------- 3 files changed, 14 insertions(+), 15 deletions(-) commit a6921c2974a09bfe8d039980c0b14a305644930b Author: Jon Mason Date: Fri Jun 24 14:49:31 2016 -0700 MAINTAINERS: update Calgary IOMMU Update the contact info for Muli, clean-up my name, and update the mailing list to the IOMMU mailing list. Link: http://lkml.kernel.org/r/1465493059-11840-2-git-send-email-jdmason@kudzu.us Signed-off-by: Jon Mason Cc: Muli Ben-Yehuda Cc: Greg Kroah-Hartman Cc: Krzysztof Kozlowski Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Bartlomiej Zolnierkiewicz Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds MAINTAINERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit f2db19719a4e789a58ac024b43f12eeb9e458074 Author: Michal Hocko Date: Fri Jun 24 14:49:28 2016 -0700 jbd2: get rid of superfluous __GFP_REPEAT jbd2_alloc is explicit about its allocation preferences wrt. the allocation size. Sub page allocations go to the slab allocator and larger are using either the page allocator or vmalloc. This is all good but the logic is unnecessarily complex. 1) as per Ted, the vmalloc fallback is a left-over: : jbd2_alloc is only passed in the bh->b_size, which can't be PAGE_SIZE, so : the code path that calls vmalloc() should never get called. When we : conveted jbd2_alloc() to suppor sub-page size allocations in commit : d2eecb039368, there was an assumption that it could be called with a size : greater than PAGE_SIZE, but that's certaily not true today. Moreover vmalloc allocation might even lead to a deadlock because the callers expect GFP_NOFS context while vmalloc is GFP_KERNEL. 2) __GFP_REPEAT for requests <= PAGE_ALLOC_COSTLY_ORDER is ignored since the flag was introduced. Let's simplify the code flow and use the slab allocator for sub-page requests and the page allocator for others. Even though order > 0 is not currently used as per above leave that option open. Link: http://lkml.kernel.org/r/1464599699-30131-18-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Reviewed-by: Jan Kara Cc: "Theodore Ts'o" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds fs/jbd2/journal.c | 32 +++++++------------------------- 1 file changed, 7 insertions(+), 25 deletions(-) commit a830627b01b26452a13abb7e7b37d39365be4b05 Author: Michal Hocko Date: Fri Jun 24 14:49:25 2016 -0700 unicore32: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. PGALLOC_GFP uses __GFP_REPEAT but it is only used in pte_alloc_one, pte_alloc_one_kernel which does order-0 request. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-17-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Guan Xuetao Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/unicore32/include/asm/pgalloc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f45eebc25e78991ef6a6d784ab54151d3003cfdf Author: Michal Hocko Date: Fri Jun 24 14:49:22 2016 -0700 tile: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pgtable_alloc_one uses __GFP_REPEAT flag for L2_USER_PGTABLE_ORDER but the order is either 0 or 3 if L2_KERNEL_PGTABLE_SHIFT for HPAGE_SHIFT. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-16-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: Chris Metcalf [for tile] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/tile/mm/pgtable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 884ed4cb8aa19ccff32f5c5586257c56e56f91a4 Author: Michal Hocko Date: Fri Jun 24 14:49:20 2016 -0700 sh: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. PGALLOC_GFP uses __GFP_REPEAT but {pgd,pmd}_alloc allocate from {pgd,pmd}_cache but both caches are allocating up to PAGE_SIZE objects. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-15-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Yoshinori Sato Cc: Rich Felker Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/sh/mm/pgtable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 10d58bf297e2cba0cfa2cd143d4f0df26e129040 Author: Michal Hocko Date: Fri Jun 24 14:49:17 2016 -0700 s390: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. page_table_alloc then uses the flag for a single page allocation. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-14-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: Heiko Carstens Cc: Martin Schwidefsky Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/s390/mm/pgalloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 45eeff260d40ff02af3d5b8e2919033ee59f9ff6 Author: Michal Hocko Date: Fri Jun 24 14:49:14 2016 -0700 sparc: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. {pud,pmd}_alloc_one is using __GFP_REPEAT but it always allocates from pgtable_cache which is initialzed to PAGE_SIZE objects. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-13-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: David S. Miller Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/sparc/include/asm/pgalloc_64.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 2379a23e34b58520dfc8f4909f116a08393138e4 Author: Michal Hocko Date: Fri Jun 24 14:49:12 2016 -0700 powerpc: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. {pud,pmd}_alloc_one are allocating from {PGT,PUD}_CACHE initialized in pgtable_cache_init which doesn't have larger than sizeof(void *) << 12 size and that fits into !costly allocation request size. PGALLOC_GFP is used only in radix__pgd_alloc which uses either order-0 or order-4 requests. The first one doesn't need the flag while the second does. Drop __GFP_REPEAT from PGALLOC_GFP and add it for the order-4 one. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-12-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Benjamin Herrenschmidt Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/powerpc/include/asm/book3s/64/pgalloc.h | 10 ++++------ arch/powerpc/include/asm/nohash/64/pgalloc.h | 6 ++---- arch/powerpc/mm/hugetlbpage.c | 2 +- 3 files changed, 7 insertions(+), 11 deletions(-) commit a4135b93898fe38ea4136c6b03b29b746e08c83a Author: Michal Hocko Date: Fri Jun 24 14:49:09 2016 -0700 score: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pte_alloc_one{_kernel} allocate PTE_ORDER which is 0. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-11-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Chen Liqin Cc: Lennox Wu Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/score/include/asm/pgalloc.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit aade311a50b0be5d5ee93bac7ebc2da9a16556d7 Author: Michal Hocko Date: Fri Jun 24 14:49:06 2016 -0700 parisc: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pmd_alloc_one allocate PMD_ORDER which is 1. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-10-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: "James E.J. Bottomley" Cc: Helge Deller Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/parisc/include/asm/pgalloc.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 565299d03363c71d5bcf7edabb41b2b36a9ea36e Author: Michal Hocko Date: Fri Jun 24 14:49:04 2016 -0700 nios2: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pte_alloc_one{_kernel} allocate PTE_ORDER which is 0. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-9-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Ley Foon Tan Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/nios2/include/asm/pgalloc.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 65f84656ff7c24177c43652bc88cc2a06f9a48b1 Author: Michal Hocko Date: Fri Jun 24 14:49:01 2016 -0700 mips: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pte_alloc_one{_kernel}, pmd_alloc_one allocate PTE_ORDER resp. PMD_ORDER but both are not larger than 1. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-8-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: John Crispin Cc: Ralf Baechle Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/mips/include/asm/pgalloc.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 54d87d600adbe9889bccaff38420cec02250993b Author: Michal Hocko Date: Fri Jun 24 14:48:58 2016 -0700 arc: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. pte_alloc_one_kernel uses __get_order_pte but this is obviously always zero because BITS_FOR_PTE is not larger than 9 yet the page size is always larger than 4K. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-7-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: Vineet Gupta Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/arc/include/asm/pgalloc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f3610a6aff7dd70b788364255c0cbc128488ef72 Author: Michal Hocko Date: Fri Jun 24 14:48:56 2016 -0700 arm64: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. {pte,pmd,pud}_alloc_one{_kernel}, late_pgtable_alloc use PGALLOC_GFP for __get_free_page (aka order-0). pgd_alloc is slightly more complex because it allocates from pgd_cache if PGD_SIZE != PAGE_SIZE and PGD_SIZE depends on the configuration (CONFIG_ARM64_VA_BITS, PAGE_SHIFT and CONFIG_PGTABLE_LEVELS). As per config PGTABLE_LEVELS int default 2 if ARM64_16K_PAGES && ARM64_VA_BITS_36 default 2 if ARM64_64K_PAGES && ARM64_VA_BITS_42 default 3 if ARM64_64K_PAGES && ARM64_VA_BITS_48 default 3 if ARM64_4K_PAGES && ARM64_VA_BITS_39 default 3 if ARM64_16K_PAGES && ARM64_VA_BITS_47 default 4 if !ARM64_64K_PAGES && ARM64_VA_BITS_48 we should have the following options CONFIG_ARM64_VA_BITS:48 CONFIG_PGTABLE_LEVELS:4 PAGE_SIZE:4k size:4096 pages:1 CONFIG_ARM64_VA_BITS:48 CONFIG_PGTABLE_LEVELS:4 PAGE_SIZE:16k size:16 pages:1 CONFIG_ARM64_VA_BITS:48 CONFIG_PGTABLE_LEVELS:3 PAGE_SIZE:64k size:512 pages:1 CONFIG_ARM64_VA_BITS:47 CONFIG_PGTABLE_LEVELS:3 PAGE_SIZE:16k size:16384 pages:1 CONFIG_ARM64_VA_BITS:42 CONFIG_PGTABLE_LEVELS:2 PAGE_SIZE:64k size:65536 pages:1 CONFIG_ARM64_VA_BITS:39 CONFIG_PGTABLE_LEVELS:3 PAGE_SIZE:4k size:4096 pages:1 CONFIG_ARM64_VA_BITS:36 CONFIG_PGTABLE_LEVELS:2 PAGE_SIZE:16k size:16384 pages:1 All of them fit into a single page (aka order-0). This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-6-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: Will Deacon Cc: Catalin Marinas Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/arm64/include/asm/pgalloc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f58f230a832ba8220a64f44aaafcce4b7358d826 Author: Michal Hocko Date: Fri Jun 24 14:48:53 2016 -0700 x86/efi: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. efi_alloc_page_tables uses __GFP_REPEAT but it allocates an order-0 page. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-4-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Acked-by: Matt Fleming Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/x86/platform/efi/efi_64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a3a9a59d206779dc0c4ca5a6de6a2ff40382732b Author: Michal Hocko Date: Fri Jun 24 14:48:50 2016 -0700 x86: get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. PGALLOC_GFP uses __GFP_REPEAT but none of the allocation which uses this flag is for more than order-0. This means that this flag has never been actually useful here because it has always been used only for PAGE_ALLOC_COSTLY requests. Link: http://lkml.kernel.org/r/1464599699-30131-3-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Andy Lutomirski Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/x86/kernel/espfix_64.c | 2 +- arch/x86/mm/pgtable.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 32d6bd9059f265f617f6502c68dfbcae7e515add Author: Michal Hocko Date: Fri Jun 24 14:48:47 2016 -0700 tree wide: get rid of __GFP_REPEAT for order-0 allocations part I This is the third version of the patchset previously sent [1]. I have basically only rebased it on top of 4.7-rc1 tree and dropped "dm: get rid of superfluous gfp flags" which went through dm tree. I am sending it now because it is tree wide and chances for conflicts are reduced considerably when we want to target rc2. I plan to send the next step and rename the flag and move to a better semantic later during this release cycle so we will have a new semantic ready for 4.8 merge window hopefully. Motivation: While working on something unrelated I've checked the current usage of __GFP_REPEAT in the tree. It seems that a majority of the usage is and always has been bogus because __GFP_REPEAT has always been about costly high order allocations while we are using it for order-0 or very small orders very often. It seems that a big pile of them is just a copy&paste when a code has been adopted from one arch to another. I think it makes some sense to get rid of them because they are just making the semantic more unclear. Please note that GFP_REPEAT is documented as * __GFP_REPEAT: Try hard to allocate the memory, but the allocation attempt * _might_ fail. This depends upon the particular VM implementation. while !costly requests have basically nofail semantic. So one could reasonably expect that order-0 request with __GFP_REPEAT will not loop for ever. This is not implemented right now though. I would like to move on with __GFP_REPEAT and define a better semantic for it. $ git grep __GFP_REPEAT origin/master | wc -l 111 $ git grep __GFP_REPEAT | wc -l 36 So we are down to the third after this patch series. The remaining places really seem to be relying on __GFP_REPEAT due to large allocation requests. This still needs some double checking which I will do later after all the simple ones are sorted out. I am touching a lot of arch specific code here and I hope I got it right but as a matter of fact I even didn't compile test for some archs as I do not have cross compiler for them. Patches should be quite trivial to review for stupid compile mistakes though. The tricky parts are usually hidden by macro definitions and thats where I would appreciate help from arch maintainers. [1] http://lkml.kernel.org/r/1461849846-27209-1-git-send-email-mhocko@kernel.org This patch (of 19): __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. Yet we have the full kernel tree with its usage for apparently order-0 allocations. This is really confusing because __GFP_REPEAT is explicitly documented to allow allocation failures which is a weaker semantic than the current order-0 has (basically nofail). Let's simply drop __GFP_REPEAT from those places. This would allow to identify place which really need allocator to retry harder and formulate a more specific semantic for what the flag is supposed to do actually. Link: http://lkml.kernel.org/r/1464599699-30131-2-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: "David S. Miller" Cc: "H. Peter Anvin" Cc: "James E.J. Bottomley" Cc: "Theodore Ts'o" Cc: Andy Lutomirski Cc: Benjamin Herrenschmidt Cc: Catalin Marinas Cc: Chen Liqin Cc: Chris Metcalf [for tile] Cc: Guan Xuetao Cc: Heiko Carstens Cc: Helge Deller Cc: Ingo Molnar Cc: Jan Kara Cc: John Crispin Cc: Lennox Wu Cc: Ley Foon Tan Cc: Martin Schwidefsky Cc: Matt Fleming Cc: Ralf Baechle Cc: Rich Felker Cc: Russell King Cc: Thomas Gleixner Cc: Vineet Gupta Cc: Will Deacon Cc: Yoshinori Sato Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds arch/alpha/include/asm/pgalloc.h | 4 ++-- arch/arm/include/asm/pgalloc.h | 2 +- arch/avr32/include/asm/pgalloc.h | 6 +++--- arch/cris/include/asm/pgalloc.h | 4 ++-- arch/frv/mm/pgalloc.c | 6 +++--- arch/hexagon/include/asm/pgalloc.h | 4 ++-- arch/m68k/include/asm/mcf_pgalloc.h | 4 ++-- arch/m68k/include/asm/motorola_pgalloc.h | 4 ++-- arch/m68k/include/asm/sun3_pgalloc.h | 4 ++-- arch/metag/include/asm/pgalloc.h | 5 ++--- arch/microblaze/include/asm/pgalloc.h | 4 ++-- arch/microblaze/mm/pgtable.c | 3 +-- arch/mn10300/mm/pgtable.c | 6 +++--- arch/openrisc/include/asm/pgalloc.h | 2 +- arch/openrisc/mm/ioremap.c | 2 +- arch/parisc/include/asm/pgalloc.h | 4 ++-- arch/powerpc/include/asm/book3s/64/pgalloc.h | 2 +- arch/powerpc/include/asm/nohash/64/pgalloc.h | 2 +- arch/powerpc/mm/pgtable_32.c | 4 ++-- arch/powerpc/mm/pgtable_64.c | 3 +-- arch/sh/include/asm/pgalloc.h | 4 ++-- arch/sparc/mm/init_64.c | 6 ++---- arch/um/kernel/mem.c | 4 ++-- arch/x86/include/asm/pgalloc.h | 4 ++-- arch/x86/xen/p2m.c | 2 +- arch/xtensa/include/asm/pgalloc.h | 2 +- drivers/block/aoe/aoecmd.c | 2 +- 27 files changed, 47 insertions(+), 52 deletions(-) commit b9b4bb26af017dbe930cd4df7f9b2fc3a0497bfe Author: Anthony Romano Date: Fri Jun 24 14:48:43 2016 -0700 tmpfs: don't undo fallocate past its last page When fallocate is interrupted it will undo a range that extends one byte past its range of allocated pages. This can corrupt an in-use page by zeroing out its first byte. Instead, undo using the inclusive byte range. Fixes: 1635f6a74152f1d ("tmpfs: undo fallocation on failure") Link: http://lkml.kernel.org/r/1462713387-16724-1-git-send-email-anthony.romano@coreos.com Signed-off-by: Anthony Romano Cc: Vlastimil Babka Cc: Hugh Dickins Cc: Brandon Philips Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/shmem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a7b50abc90afb2e3c27e1bd212643cc53eaf0b60 Author: Mike Kravetz Date: Fri Jun 24 14:48:40 2016 -0700 selftests/vm/compaction_test: fix write to restore nr_hugepages The write at the end of the test to restore nr_hugepages to its previous value is failing. This is because it is trying to write the number of bytes in the char array as opposed to the number of bytes in the string. Link: http://lkml.kernel.org/r/1465331205-3284-1-git-send-email-mike.kravetz@oracle.com Signed-off-by: Mike Kravetz Cc: Shuah Khan Cc: Sri Jayaramappa Cc: Eric B Munson Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds tools/testing/selftests/vm/compaction_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9df10fb7b80bc2f540956ba01b5e7ee1012001a5 Author: Tetsuo Handa Date: Fri Jun 24 14:48:38 2016 -0700 oom_reaper: avoid pointless atomic_inc_not_zero usage. Since commit 36324a990cf5 ("oom: clear TIF_MEMDIE after oom_reaper managed to unmap the address space") changed to use find_lock_task_mm() for finding a mm_struct to reap, it is guaranteed that mm->mm_users > 0 because find_lock_task_mm() returns a task_struct with ->mm != NULL. Therefore, we can safely use atomic_inc(). Link: http://lkml.kernel.org/r/1465024759-8074-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp Signed-off-by: Tetsuo Handa Acked-by: Michal Hocko Cc: Arnd Bergmann Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/oom_kill.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 491a1c65ae498dea0e39b24a46e528a78a8532ed Author: Tetsuo Handa Date: Fri Jun 24 14:48:35 2016 -0700 mm,oom_reaper: don't call mmput_async() without atomic_inc_not_zero() Commit e2fe14564d33 ("oom_reaper: close race with exiting task") reduced frequency of needlessly selecting next OOM victim, but was calling mmput_async() when atomic_inc_not_zero() failed. Link: http://lkml.kernel.org/r/1464423365-5555-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp Signed-off-by: Tetsuo Handa Acked-by: Michal Hocko Cc: Arnd Bergmann Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/oom_kill.c | 1 + 1 file changed, 1 insertion(+) commit 9c46a6df3ba770162deb7abc95427fa1ddf28763 Merge: 7f1a00b 9996537 Author: Linus Torvalds Date: Fri Jun 24 17:22:27 2016 -0700 Merge tag 'nfsd-4.7-2' of git://linux-nfs.org/~bfields/linux Pull nfsd bugfixes from Bruce Fields: "Fix missing server-side permission checks on setting NFS ACLs" * tag 'nfsd-4.7-2' of git://linux-nfs.org/~bfields/linux: nfsd: check permissions when setting ACLs posix_acl: Add set_posix_acl commit 7f1a00b6fcd0e3c19beba2e92d157dc0c2cf3494 Author: Linus Torvalds Date: Fri Jun 24 17:07:33 2016 -0700 fix up initial thread stack pointer vs thread_info confusion The INIT_TASK() initializer was similarly confused about the stack vs thread_info allocation that the allocators had, and that were fixed in commit b235beea9e99 ("Clarify naming of thread info/stack allocators"). The task ->stack pointer only incidentally ends up having the same value as the thread_info, and in fact that will change. So fix the initial task struct initializer to point to 'init_stack' instead of 'init_thread_info', and make sure the ia64 definition for that exists. This actually makes the ia64 tsk->stack pointer be sensible for the initial task, but not for any other task. As mentioned in commit b235beea9e99, that whole pointer isn't actually used on ia64, since task_stack_page() there just points to the (single) allocation. All the other architectures seem to have copied the 'init_stack' definition, even if it tended to be generally unusued. Signed-off-by: Linus Torvalds arch/ia64/kernel/init_task.c | 1 + include/linux/init_task.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) commit 7e8b3dfef16375dbfeb1f36a83eb9f27117c51fd Author: Alan Stern Date: Thu Jun 23 14:54:37 2016 -0400 USB: EHCI: declare hostpc register as zero-length array The HOSTPC extension registers found in some EHCI implementations form a variable-length array, with one element for each port. Therefore the hostpc field in struct ehci_regs should be declared as a zero-length array, not a single-element array. This fixes a problem reported by UBSAN. Signed-off-by: Alan Stern Reported-by: Wilfried Klaebe Tested-by: Wilfried Klaebe CC: Signed-off-by: Greg Kroah-Hartman include/linux/usb/ehci_def.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1a34c4d0ae888b229b8ffd99835be254b0024f88 Merge: 3641fde 04e59a0 Author: Greg Kroah-Hartman Date: Fri Jun 24 17:01:43 2016 -0700 Merge tag 'phy-for-4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy into usb-linus Kishon writes: phy: for 4.7-rc5 *) Fix in sun4i-usb phy driver to properly handle the return value of gpiod_to_irq *) Fix a sparse warning in sun4i-usb phy driver *) Fix bcm-ns-usb2 phy driver to check the correct variable *) Fix spurious interrupts during VBUS change in rcar-gen3-usb2 phy driver Signed-off-by: Kishon Vijay Abraham I commit 3641fdeb17a84a170b2259a5a38d9bfd106c5a6e Merge: 33688ab ea1d39a Author: Greg Kroah-Hartman Date: Fri Jun 24 17:00:49 2016 -0700 Merge tag 'usb-ci-v4.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/peter.chen/usb into usb-linus Peter writes: One fix for module support in OTG FSM commit aca9c293d098292579e345b2b39b394778d41526 Author: Linus Torvalds Date: Fri Jun 24 16:55:53 2016 -0700 x86: fix up a few misc stack pointer vs thread_info confusions As the actual pointer value is the same for the thread stack allocation and the thread_info, code that confused the two worked fine, but will break when the thread info is moved away from the stack allocation. It also looks very confusing. For example, the kprobe code wanted to know the current top of stack. To do that, it used this: (unsigned long)current_thread_info() + THREAD_SIZE which did indeed give the correct value. But it's not only a fairly nonsensical expression, it's also rather complex, especially since we actually have this: static inline unsigned long current_top_of_stack(void) which not only gives us the value we are interested in, but happens to be how "current_thread_info()" is currently defined as: (struct thread_info *)(current_top_of_stack() - THREAD_SIZE); so using current_thread_info() to figure out the top of the stack really is a very round-about thing to do. The other cases are just simpler confusion about task_thread_info() vs task_stack_page(), which currently return the same pointer - but if you want the stack page, you really should be using the latter one. And there was one entirely unused assignment of the current stack to a thread_info pointer. All cleaned up to make more sense today, and make it easier to move the thread_info away from the stack in the future. No semantic changes. Signed-off-by: Linus Torvalds arch/x86/include/asm/kprobes.h | 11 +++++------ arch/x86/kernel/dumpstack.c | 2 +- arch/x86/kernel/irq_32.c | 2 -- 3 files changed, 6 insertions(+), 9 deletions(-) commit b235beea9e996a4d36fed6cfef4801a3e7d7a9a5 Author: Linus Torvalds Date: Fri Jun 24 15:09:37 2016 -0700 Clarify naming of thread info/stack allocators We've had the thread info allocated together with the thread stack for most architectures for a long time (since the thread_info was split off from the task struct), but that is about to change. But the patches that move the thread info to be off-stack (and a part of the task struct instead) made it clear how confused the allocator and freeing functions are. Because the common case was that we share an allocation with the thread stack and the thread_info, the two pointers were identical. That identity then meant that we would have things like ti = alloc_thread_info_node(tsk, node); ... tsk->stack = ti; which certainly _worked_ (since stack and thread_info have the same value), but is rather confusing: why are we assigning a thread_info to the stack? And if we move the thread_info away, the "confusing" code just gets to be entirely bogus. So remove all this confusion, and make it clear that we are doing the stack allocation by renaming and clarifying the function names to be about the stack. The fact that the thread_info then shares the allocation is an implementation detail, and not really about the allocation itself. This is a pure renaming and type fix: we pass in the same pointer, it's just that we clarify what the pointer means. The ia64 code that actually only has one single allocation (for all of task_struct, thread_info and kernel thread stack) now looks a bit odd, but since "tsk->stack" is actually not even used there, that oddity doesn't matter. It would be a separate thing to clean that up, I intentionally left the ia64 changes as a pure brute-force renaming and type change. Acked-by: Andy Lutomirski Signed-off-by: Linus Torvalds arch/Kconfig | 4 +-- arch/ia64/Kconfig | 2 +- arch/ia64/include/asm/thread_info.h | 8 +++--- arch/mn10300/include/asm/thread_info.h | 2 +- arch/mn10300/kernel/kgdb.c | 3 +- arch/tile/include/asm/thread_info.h | 2 +- arch/tile/kernel/process.c | 3 +- include/linux/sched.h | 2 +- init/main.c | 4 +-- kernel/fork.c | 50 +++++++++++++++++----------------- 10 files changed, 41 insertions(+), 39 deletions(-) commit e753f3050935ff5a52069fef802bee72ab19c098 Merge: 0d37189 3c67a82 Author: Rafael J. Wysocki Date: Fri Jun 24 23:37:23 2016 +0200 Merge branches 'pm-devfreq-fixes' and 'pm-cpufreq-fixes' * pm-devfreq-fixes: PM / devfreq: Send the DEVFREQ_POSTCHANGE notification when target() is failed PM / devfreq: fix initialization of current frequency in last status PM / devfreq: exynos-nocp: Remove incorrect IS_ERR() check PM / devfreq: remove double put_device PM / devfreq: fix double call put_device PM / devfreq: fix duplicated kfree on devfreq pointer PM / devfreq: devm_kzalloc to have dev pointer more precisely * pm-cpufreq-fixes: cpufreq: pcc-cpufreq: Fix doorbell.access_width commit 2605b98109100f70398115a473ea190ce93fda5e Merge: 33688ab 2f38b1b Author: Rafael J. Wysocki Date: Fri Jun 24 23:36:20 2016 +0200 Merge branch 'acpica-fixes' * acpica-fixes: ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading commit 45e8a2583d97ca758a55c608f78c4cef562644d1 Author: Steve French Date: Wed Jun 22 21:07:32 2016 -0500 File names with trailing period or space need special case conversion POSIX allows files with trailing spaces or a trailing period but SMB3 does not, so convert these using the normal Services For Mac mapping as we do for other reserved characters such as : < > | ? * This is similar to what Macs do for the same problem over SMB3. CC: Stable Signed-off-by: Steve French Acked-by: Pavel Shilovsky fs/cifs/cifs_unicode.c | 33 +++++++++++++++++++++++++++++---- fs/cifs/cifs_unicode.h | 2 ++ 2 files changed, 31 insertions(+), 4 deletions(-) commit 4fcd1813e6404dd4420c7d12fb483f9320f0bf93 Author: Steve French Date: Wed Jun 22 20:12:05 2016 -0500 Fix reconnect to not defer smb3 session reconnect long after socket reconnect Azure server blocks clients that open a socket and don't do anything on it. In our reconnect scenarios, we can reconnect the tcp session and detect the socket is available but we defer the negprot and SMB3 session setup and tree connect reconnection until the next i/o is requested, but this looks suspicous to some servers who expect SMB3 negprog and session setup soon after a socket is created. In the echo thread, reconnect SMB3 sessions and tree connections that are disconnected. A later patch will replay persistent (and resilient) handle opens. CC: Stable Signed-off-by: Steve French Acked-by: Pavel Shilovsky fs/cifs/connect.c | 4 +++- fs/cifs/smb2pdu.c | 27 +++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) commit 999653786df6954a31044528ac3f7a5dadca08f4 Author: Ben Hutchings Date: Wed Jun 22 19:43:35 2016 +0100 nfsd: check permissions when setting ACLs Use set_posix_acl, which includes proper permission checks, instead of calling ->set_acl directly. Without this anyone may be able to grant themselves permissions to a file by setting the ACL. Lock the inode to make the new checks atomic with respect to set_acl. (Also, nfsd was the only caller of set_acl not locking the inode, so I suspect this may fix other races.) This also simplifies the code, and ensures our ACLs are checked by posix_acl_valid. The permission checks and the inode locking were lost with commit 4ac7249e, which changed nfsd to use the set_acl inode operation directly instead of going through xattr handlers. Reported-by: David Sinquin [agreunba@redhat.com: use set_posix_acl] Fixes: 4ac7249e Cc: Christoph Hellwig Cc: Al Viro Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields fs/nfsd/nfs2acl.c | 20 ++++++++++---------- fs/nfsd/nfs3acl.c | 16 +++++++--------- fs/nfsd/nfs4acl.c | 16 ++++++++-------- 3 files changed, 25 insertions(+), 27 deletions(-) commit 485e71e8fb6356c08c7fc6bcce4bf02c9a9a663f Author: Andreas Gruenbacher Date: Wed Jun 22 23:57:25 2016 +0200 posix_acl: Add set_posix_acl Factor out part of posix_acl_xattr_set into a common function that takes a posix_acl, which nfsd can also call. The prototype already exists in include/linux/posix_acl.h. Signed-off-by: Andreas Gruenbacher Cc: stable@vger.kernel.org Cc: Christoph Hellwig Cc: Al Viro Signed-off-by: J. Bruce Fields fs/posix_acl.c | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) commit 4995734e973a2c2e9c6f6413cbad9913fc4df0dc Author: Dan Williams Date: Fri Jun 24 09:07:39 2016 -0700 acpi, nfit: fix acpi_check_dsm() vs zero functions implemented QEMU 2.6 implements nascent support for nvdimm DSMs. Depending on configuration it may only implement the function0 dsm to indicate that no other DSMs are available. Commit 31eca76ba2fc "nfit, libnvdimm: limited/whitelisted dimm command marshaling mechanism" breaks QEMU, but QEMU is spec compliant. Per the spec the way to indicate that no functions are supported is: If Function Index is zero, the return is a buffer containing one bit for each function index, starting with zero. Bit 0 indicates whether there is support for any functions other than function 0 for the specified UUID and Revision ID. If set to zero, no functions are supported (other than function zero) for the specified UUID and Revision ID. Update the nfit driver to determine the family (interface UUID) without requiring the implementation to define any other functions, i.e. short-circuit acpi_check_dsm() to succeed per the spec. The nfit driver appears to be the only user passing funcs==0 to acpi_check_dsm(), so this behavior change of the common routine should be limited to the probing done by the nfit driver. Cc: Len Brown Cc: Jerry Hoemann Acked-by: "Rafael J. Wysocki" Fixes: 31eca76ba2fc ("nfit, libnvdimm: limited/whitelisted dimm command marshaling mechanism") Reported-by: Xiao Guangrong Tested-by: Xiao Guangrong Signed-off-by: Dan Williams drivers/acpi/nfit.c | 6 +++--- drivers/acpi/utils.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) commit 1b982ea2ca398bdaeab6cf2aba459a9ca808f1f3 Author: Trond Myklebust Date: Fri Jun 17 16:48:29 2016 -0400 NFS: Fix an unused variable warning Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/dir.c | 2 -- 1 file changed, 2 deletions(-) commit 916ec34d0bafe95b977908acd8b3153c9df6f9d6 Author: Trond Myklebust Date: Fri Jun 17 16:48:28 2016 -0400 NFS: Fix potential race in nfs_fhget() If we don't set the mode correctly in nfs_init_locked(), then there is potential for a race with a second call to nfs_fhget that will cause inode aliasing. Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/inode.c | 1 + 1 file changed, 1 insertion(+) commit d8fdb47fae5febc02e62da121f85625244b98b2e Author: Trond Myklebust Date: Fri Jun 17 16:48:27 2016 -0400 NFS: Don't let readdirplus revalidate an inode that was marked as stale Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/dir.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 2d148c7e84962429a79092a56d3736a8d984f595 Author: Trond Myklebust Date: Fri Jun 17 16:48:26 2016 -0400 NFSv4.1/pnfs: Mark the layout stateid invalid when all segments are removed According to RFC5661, section 12.5.3. the layout stateid is no longer valid once the client no longer holds any layout segments. Ensure that we mark it invalid. Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/pnfs.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit cbebaf897e5c4862567eb799dc84acc5d7ee2678 Author: Trond Myklebust Date: Fri Jun 17 16:48:25 2016 -0400 NFS: Fix a double page unlock Since commit 0bcbf039f6b2, nfs_readpage_release() has been used to unlock the page in the read code. Fixes: 0bcbf039f6b2 ("nfs: handle request add failure properly") Cc: stable@vger.kernel.org # v4.5+ Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/read.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5e3a98883e7ebdd1440f829a9e9dd5c3d2c5903b Author: Weston Andros Adamson Date: Fri Jun 17 16:48:24 2016 -0400 pnfs_nfs: fix _cancel_empty_pagelist pnfs_generic_commit_cancel_empty_pagelist calls nfs_commitdata_release, but that is wrong: nfs_commitdata_release puts the open context, something that isn't valid until nfs_init_commit is called, which is never the case when pnfs_generic_commit_cancel_empty_pagelist is called. This was introduced in "nfs: avoid race that crashes nfs_init_commit". Signed-off-by: Weston Andros Adamson Cc: stable@vger.kernel.org Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/pnfs_nfs.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit cea7f829d3ea6e87a67220bc417260b858e278ff Author: Oleg Drokin Date: Fri Jun 17 16:48:23 2016 -0400 nfs4: Fix potential use after free of state in nfs4_do_reclaim. Commit e8d975e73e5f ("fixing infinite OPEN loop in 4.0 stateid recovery") introduced access to state after it was just potentially freed by nfs4_put_open_state leading to a random data corruption somewhere. BUG: unable to handle kernel paging request at ffff88004941ee40 IP: [] nfs4_do_reclaim+0x461/0x740 PGD 3501067 PUD 3504067 PMD 6ff37067 PTE 800000004941e060 Oops: 0002 [#1] SMP DEBUG_PAGEALLOC Modules linked in: loop rpcsec_gss_krb5 acpi_cpufreq tpm_tis joydev i2c_piix4 pcspkr tpm virtio_console nfsd ttm drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops floppy serio_raw virtio_blk drm CPU: 6 PID: 2161 Comm: 192.168.10.253- Not tainted 4.7.0-rc1-vm-nfs+ #112 Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 task: ffff8800463dcd00 ti: ffff88003ff48000 task.ti: ffff88003ff48000 RIP: 0010:[] [] nfs4_do_reclaim+0x461/0x740 RSP: 0018:ffff88003ff4bd68 EFLAGS: 00010246 RAX: 0000000000000000 RBX: ffffffff81a49900 RCX: 00000000000000e8 RDX: 00000000000000e8 RSI: ffff8800418b9930 RDI: ffff880040c96c88 RBP: ffff88003ff4bdf8 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff880040c96c98 R13: ffff88004941ee20 R14: ffff88004941ee40 R15: ffff88004941ee00 FS: 0000000000000000(0000) GS:ffff88006d000000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: ffff88004941ee40 CR3: 0000000060b0b000 CR4: 00000000000006e0 Stack: ffffffff813baad5 ffff8800463dcd00 ffff880000000001 ffffffff810e6b68 ffff880043ddbc88 ffff8800418b9800 ffff8800418b98c8 ffff88004941ee48 ffff880040c96c90 ffff880040c96c00 ffff880040c96c20 ffff880040c96c40 Call Trace: [] ? nfs4_do_reclaim+0x35/0x740 [] ? trace_hardirqs_on_caller+0x128/0x1b0 [] nfs4_run_state_manager+0x5ed/0xa40 [] ? nfs4_do_reclaim+0x740/0x740 [] ? nfs4_do_reclaim+0x740/0x740 [] kthread+0x101/0x120 [] ? trace_hardirqs_on_caller+0x128/0x1b0 [] ret_from_fork+0x1f/0x40 [] ? kthread_create_on_node+0x250/0x250 Code: 65 80 4c 8b b5 78 ff ff ff e8 fc 88 4c 00 48 8b 7d 88 e8 13 67 d2 ff 49 8b 47 40 a8 02 0f 84 d3 01 00 00 4c 89 ff e8 7f f9 ff ff 41 80 26 7f 48 8b 7d c8 e8 b1 84 4c 00 e9 39 fd ff ff 3d e6 RIP [] nfs4_do_reclaim+0x461/0x740 RSP CR2: ffff88004941ee40 Signed-off-by: Oleg Drokin Signed-off-by: Trond Myklebust Signed-off-by: Anna Schumaker fs/nfs/nfs4state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d2a7de0b34cd255f23d4b7a7f065677f4b1c15f2 Author: Trond Myklebust Date: Fri Jun 17 16:48:22 2016 -0400 NFS: Fix up O_DIRECT results if we read or wrote something, we must report it Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/direct.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit dd1beb3d16f6a10683b84b89a4644065c43910f3 Author: Trond Myklebust Date: Fri Jun 17 16:48:21 2016 -0400 NFS/pnfs: handle bad delegation stateids in nfs4_layoutget_handle_exception We must call nfs4_handle_exception() on BAD_STATEID errors. The only exception is if the stateid argument turns out to be a layout stateid that is declared invalid. Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/nfs4proc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e5241e43883058b61a955b4bbd677fe4ffd3ae4e Author: Trond Myklebust Date: Fri Jun 17 16:48:20 2016 -0400 NFSv4.1/pnfs: Add sparse lock annotations for pnfs_find_alloc_layout Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/pnfs.c | 2 ++ 1 file changed, 2 insertions(+) commit 67a3b721462c9b3bdc36ad6a583f41706402b3ea Author: Trond Myklebust Date: Fri Jun 17 16:48:19 2016 -0400 NFSv4.1/pnfs: Layout stateids start out as being invalid Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/pnfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit bc23676caf54c9b6e2521ef065dfddf6c50211de Author: Trond Myklebust Date: Fri Jun 17 16:48:18 2016 -0400 NFSv4.1/pnfs: Ensure we handle delegation errors in nfs4_proc_layoutget() nfs4_handle_exception() relies on the caller setting the 'inode' field in the struct nfs4_exception argument when the error applies to a delegation. Signed-off-by: Trond Myklebust Reviewed-by: Jeff Layton Signed-off-by: Anna Schumaker fs/nfs/nfs4proc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit d5dbbe6569481bf12dcbe3e12cff72c5f78d272c Author: Takashi Iwai Date: Fri Jun 24 15:15:26 2016 +0200 ALSA: dummy: Fix a use-after-free at closing syzkaller fuzzer spotted a potential use-after-free case in snd-dummy driver when hrtimer is used as backend: > ================================================================== > BUG: KASAN: use-after-free in rb_erase+0x1b17/0x2010 at addr ffff88005e5b6f68 > Read of size 8 by task syz-executor/8984 > ============================================================================= > BUG kmalloc-192 (Not tainted): kasan: bad access detected > ----------------------------------------------------------------------------- > > Disabling lock debugging due to kernel taint > INFO: Allocated in 0xbbbbbbbbbbbbbbbb age=18446705582212484632 > .... > [< none >] dummy_hrtimer_create+0x49/0x1a0 sound/drivers/dummy.c:464 > .... > INFO: Freed in 0xfffd8e09 age=18446705496313138713 cpu=2164287125 pid=-1 > [< none >] dummy_hrtimer_free+0x68/0x80 sound/drivers/dummy.c:481 > .... > Call Trace: > [] __asan_report_load8_noabort+0x3e/0x40 mm/kasan/report.c:333 > [< inline >] rb_set_parent include/linux/rbtree_augmented.h:111 > [< inline >] __rb_erase_augmented include/linux/rbtree_augmented.h:218 > [] rb_erase+0x1b17/0x2010 lib/rbtree.c:427 > [] timerqueue_del+0x78/0x170 lib/timerqueue.c:86 > [] __remove_hrtimer+0x90/0x220 kernel/time/hrtimer.c:903 > [< inline >] remove_hrtimer kernel/time/hrtimer.c:945 > [] hrtimer_try_to_cancel+0x22a/0x570 kernel/time/hrtimer.c:1046 > [] hrtimer_cancel+0x22/0x40 kernel/time/hrtimer.c:1066 > [] dummy_hrtimer_stop+0x91/0xb0 sound/drivers/dummy.c:417 > [] dummy_pcm_trigger+0x17f/0x1e0 sound/drivers/dummy.c:507 > [] snd_pcm_do_stop+0x160/0x1b0 sound/core/pcm_native.c:1106 > [] snd_pcm_action_single+0x76/0x120 sound/core/pcm_native.c:956 > [] snd_pcm_action+0x231/0x290 sound/core/pcm_native.c:974 > [< inline >] snd_pcm_stop sound/core/pcm_native.c:1139 > [] snd_pcm_drop+0x12d/0x1d0 sound/core/pcm_native.c:1784 > [] snd_pcm_common_ioctl1+0xfae/0x2150 sound/core/pcm_native.c:2805 > [] snd_pcm_capture_ioctl1+0x2a1/0x5e0 sound/core/pcm_native.c:2976 > [] snd_pcm_kernel_ioctl+0x11c/0x160 sound/core/pcm_native.c:3020 > [] snd_pcm_oss_sync+0x3a4/0xa30 sound/core/oss/pcm_oss.c:1693 > [] snd_pcm_oss_release+0x1ad/0x280 sound/core/oss/pcm_oss.c:2483 > ..... A workaround is to call hrtimer_cancel() in dummy_hrtimer_sync() which is called certainly before other blocking ops. Reported-by: Dmitry Vyukov Tested-by: Dmitry Vyukov Cc: Signed-off-by: Takashi Iwai sound/drivers/dummy.c | 1 + 1 file changed, 1 insertion(+) commit 0f087ee3f3b86a4507db4ff1d2d5a3880e4cfd16 Author: Jaroslav Kysela Date: Fri Jun 24 15:13:16 2016 +0200 ALSA: hda / realtek - add two more Thinkpad IDs (5050,5053) for tpt460 fixup See: https://bugzilla.redhat.com/show_bug.cgi?id=1349539 See: https://bugzilla.kernel.org/show_bug.cgi?id=120961 Signed-off-by: Jaroslav Kysela Cc: Signed-off-by: Takashi Iwai sound/pci/hda/patch_realtek.c | 2 ++ 1 file changed, 2 insertions(+) commit d2bd05d88d245c13b64c3bf9c8927a1c56453d8c Author: Jan Beulich Date: Fri Jun 24 03:13:34 2016 -0600 xen-pciback: return proper values during BAR sizing Reads following writes with all address bits set to 1 should return all changeable address bits as one, not the BAR size (nor, as was the case for the upper half of 64-bit BARs, the high half of the region's end address). Presumably this didn't cause any problems so far because consumers use the value to calculate the size (usually via val & -val), and do nothing else with it. But also consider the exception here: Unimplemented BARs should always return all zeroes. And finally, the check for whether to return the sizing address on read for the ROM BAR should ignore all non-address bits, not just the ROM Enable one. Signed-off-by: Jan Beulich Reviewed-by: Boris Ostrovsky Signed-off-by: David Vrabel drivers/xen/xen-pciback/conf_space_header.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) commit f83c32925d45926cd0e0f18bf28e6039116c4486 Author: Woodrow Shen Date: Fri Jun 24 15:58:34 2016 +0800 ALSA: hda - Fix the headset mic jack detection on Dell machine The new Dell laptop with codec 3246 can't detect headset mic when headset was inserted on the machine. So adding pin configurations into quirk table makes headset mic work correctly. Codec: Realtek ALC3246 Vendor Id: 0x10ec0256 Subsystem Id: 0x10280781 Signed-off-by: Woodrow Shen Cc: Signed-off-by: Takashi Iwai sound/pci/hda/patch_realtek.c | 4 ++++ 1 file changed, 4 insertions(+) commit 93a2001bdfd5376c3dc2158653034c20392d15c5 Author: Scott Bauer Date: Thu Jun 23 08:59:47 2016 -0600 HID: hiddev: validate num_values for HIDIOCGUSAGES, HIDIOCSUSAGES commands This patch validates the num_values parameter from userland during the HIDIOCGUSAGES and HIDIOCSUSAGES commands. Previously, if the report id was set to HID_REPORT_ID_UNKNOWN, we would fail to validate the num_values parameter leading to a heap overflow. Cc: stable@vger.kernel.org Signed-off-by: Scott Bauer Signed-off-by: Jiri Kosina drivers/hid/usbhid/hiddev.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit feb245e304f343cf5e4f9123db36354144dce8a4 Author: Tejun Heo Date: Thu Jun 16 15:35:04 2016 -0400 sched/core: Allow kthreads to fall back to online && !active cpus During CPU hotplug, CPU_ONLINE callbacks are run while the CPU is online but not active. A CPU_ONLINE callback may create or bind a kthread so that its cpus_allowed mask only allows the CPU which is being brought online. The kthread may start executing before the CPU is made active and can end up in select_fallback_rq(). In such cases, the expected behavior is selecting the CPU which is coming online; however, because select_fallback_rq() only chooses from active CPUs, it determines that the task doesn't have any viable CPU in its allowed mask and ends up overriding it to cpu_possible_mask. CPU_ONLINE callbacks should be able to put kthreads on the CPU which is coming online. Update select_fallback_rq() so that it follows cpu_online() rather than cpu_active() for kthreads. Reported-by: Gautham R Shenoy Tested-by: Gautham R. Shenoy Signed-off-by: Tejun Heo Signed-off-by: Peter Zijlstra (Intel) Cc: Abdul Haleem Cc: Aneesh Kumar Cc: Linus Torvalds Cc: Michael Ellerman Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: kernel-team@fb.com Cc: linuxppc-dev@lists.ozlabs.org Link: http://lkml.kernel.org/r/20160616193504.GB3262@mtj.duckdns.org Signed-off-by: Ingo Molnar kernel/sched/core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 754bd598be9bbc953bc709a9e8ed7f3188bfb9d7 Author: Konstantin Khlebnikov Date: Thu Jun 16 15:57:15 2016 +0300 sched/fair: Do not announce throttled next buddy in dequeue_task_fair() Hierarchy could be already throttled at this point. Throttled next buddy could trigger a NULL pointer dereference in pick_next_task_fair(). Signed-off-by: Konstantin Khlebnikov Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Ben Segall Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/146608183552.21905.15924473394414832071.stgit@buzz Signed-off-by: Ingo Molnar kernel/sched/fair.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 094f469172e00d6ab0a3130b0e01c83b3cf3a98d Author: Konstantin Khlebnikov Date: Thu Jun 16 15:57:01 2016 +0300 sched/fair: Initialize throttle_count for new task-groups lazily Cgroup created inside throttled group must inherit current throttle_count. Broken throttle_count allows to nominate throttled entries as a next buddy, later this leads to null pointer dereference in pick_next_task_fair(). This patch initialize cfs_rq->throttle_count at first enqueue: laziness allows to skip locking all rq at group creation. Lazy approach also allows to skip full sub-tree scan at throttling hierarchy (not in this patch). Signed-off-by: Konstantin Khlebnikov Signed-off-by: Peter Zijlstra (Intel) Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: bsegall@google.com Link: http://lkml.kernel.org/r/146608182119.21870.8439834428248129633.stgit@buzz Signed-off-by: Ingo Molnar kernel/sched/fair.c | 20 ++++++++++++++++++++ kernel/sched/sched.h | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) commit 4c5ea0a9cd02d6aa8adc86e100b2a4cff8d614ff Author: Paolo Bonzini Date: Tue Jun 21 18:52:17 2016 +0200 locking/static_key: Fix concurrent static_key_slow_inc() The following scenario is possible: CPU 1 CPU 2 static_key_slow_inc() atomic_inc_not_zero() -> key.enabled == 0, no increment jump_label_lock() atomic_inc_return() -> key.enabled == 1 now static_key_slow_inc() atomic_inc_not_zero() -> key.enabled == 1, inc to 2 return ** static key is wrong! jump_label_update() jump_label_unlock() Testing the static key at the point marked by (**) will follow the wrong path for jumps that have not been patched yet. This can actually happen when creating many KVM virtual machines with userspace LAPIC emulation; just run several copies of the following program: #include #include #include #include int main(void) { for (;;) { int kvmfd = open("/dev/kvm", O_RDONLY); int vmfd = ioctl(kvmfd, KVM_CREATE_VM, 0); close(ioctl(vmfd, KVM_CREATE_VCPU, 1)); close(vmfd); close(kvmfd); } return 0; } Every KVM_CREATE_VCPU ioctl will attempt a static_key_slow_inc() call. The static key's purpose is to skip NULL pointer checks and indeed one of the processes eventually dereferences NULL. As explained in the commit that introduced the bug: 706249c222f6 ("locking/static_keys: Rework update logic") jump_label_update() needs key.enabled to be true. The solution adopted here is to temporarily make key.enabled == -1, and use go down the slow path when key.enabled <= 0. Reported-by: Dmitry Vyukov Signed-off-by: Paolo Bonzini Signed-off-by: Peter Zijlstra (Intel) Cc: # v4.3+ Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Fixes: 706249c222f6 ("locking/static_keys: Rework update logic") Link: http://lkml.kernel.org/r/1466527937-69798-1-git-send-email-pbonzini@redhat.com [ Small stylistic edits to the changelog and the code. ] Signed-off-by: Ingo Molnar include/linux/jump_label.h | 16 +++++++++++++--- kernel/jump_label.c | 36 +++++++++++++++++++++++++++++++++--- 2 files changed, 46 insertions(+), 6 deletions(-) commit 63c04ee7d3b7c8d8e2726cb7c5f8a5f6fcc1e3b2 Merge: 0bf0ea4 4ac1c17 Author: Linus Torvalds Date: Thu Jun 23 22:48:48 2016 -0700 Merge tag 'upstream-4.7-rc5' of git://git.infradead.org/linux-ubifs Pull UBI/UBIFS fixes from Richard Weinberger: "This contains fixes for two critical bugs in UBI and UBIFS: - fix the possibility of losing data upon a power cut when UBI tries to recover from a write error - fix page migration on UBIFS. It turned out that the default page migration function is not suitable for UBIFS" * tag 'upstream-4.7-rc5' of git://git.infradead.org/linux-ubifs: UBIFS: Implement ->migratepage() mm: Export migrate_page_move_mapping and migrate_page_copy ubi: Make recover_peb power cut aware gpio: make library immune to error pointers gpio: make sure gpiod_to_irq() returns negative on NULL desc gpio: 104-idi-48: Fix missing spin_lock_init for ack_lock commit a6b6befbb2806697461962edb044e3376a771ebb Author: Luis de Bethencourt Date: Wed Jun 8 17:02:32 2016 +0100 cifs: check hash calculating succeeded calc_lanman_hash() could return -ENOMEM or other errors, we should check that everything went fine before using the calculated key. Signed-off-by: Luis de Bethencourt Signed-off-by: Steve French fs/cifs/sess.c | 2 ++ 1 file changed, 2 insertions(+) commit b8da344b74c822e966c6d19d6b2321efe82c5d97 Author: Jerome Marchand Date: Thu May 26 11:52:25 2016 +0200 cifs: dynamic allocation of ntlmssp blob In sess_auth_rawntlmssp_authenticate(), the ntlmssp blob is allocated statically and its size is an "empirical" 5*sizeof(struct _AUTHENTICATE_MESSAGE) (320B on x86_64). I don't know where this value comes from or if it was ever appropriate, but it is currently insufficient: the user and domain name in UTF16 could take 1kB by themselves. Because of that, build_ntlmssp_auth_blob() might corrupt memory (out-of-bounds write). The size of ntlmssp_blob in SMB2_sess_setup() is too small too (sizeof(struct _NEGOTIATE_MESSAGE) + 500). This patch allocates the blob dynamically in build_ntlmssp_auth_blob(). Signed-off-by: Jerome Marchand Signed-off-by: Steve French CC: Stable fs/cifs/ntlmssp.h | 2 +- fs/cifs/sess.c | 76 ++++++++++++++++++++++++++++++------------------------- fs/cifs/smb2pdu.c | 10 ++------ 3 files changed, 45 insertions(+), 43 deletions(-) commit 202d772ba02b1deb8835a631cd8255943d1906a0 Author: Jerome Marchand Date: Thu May 26 11:52:24 2016 +0200 cifs: use CIFS_MAX_DOMAINNAME_LEN when converting the domain name Currently in build_ntlmssp_auth_blob(), when converting the domain name to UTF16, CIFS_MAX_USERNAME_LEN limit is used. It should be CIFS_MAX_DOMAINNAME_LEN. This patch fixes this. Signed-off-by: Jerome Marchand Signed-off-by: Steve French fs/cifs/sess.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3d22462ae915743f3be5bf1ab3d4a6b72c2bb6c9 Author: Jeff Layton Date: Tue May 24 06:27:44 2016 -0400 cifs: stuff the fl_owner into "pid" field in the lock request Right now, we send the tgid cross the wire. What we really want to send though is a hashed fl_owner_t since samba treats this field as a generic lockowner. It turns out that because we enforce and release locks locally before they are ever sent to the server, this patch makes no difference in behavior. Still, setting OFD locks on the server using the process pid seems wrong, so I think this patch still makes sense. Signed-off-by: Jeff Layton Signed-off-by: Steve French Acked-by: Pavel Shilovsky Acked-by: Sachin Prabhu fs/cifs/cifsfs.c | 3 +++ fs/cifs/cifsglob.h | 1 + fs/cifs/file.c | 14 +++++++++++--- 3 files changed, 15 insertions(+), 3 deletions(-) commit 0bf0ea431f84bcf34facc5b1f792d000f5957565 Merge: 75befb3 81e257e Author: Linus Torvalds Date: Thu Jun 23 21:35:12 2016 -0700 Merge tag 'drm-fixes-for-v4.7-rc5' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "This is the drm fixes tree for 4.7-rc5. It's a bit larger than normal, due to fixes for production AMD Polaris GPUs. We only merged support for these in 4.7-rc1 so it would be good if we got all the fixes into final. The changes don't hit any other hardware. Other than the amdgpu Polaris changes: - A single fix for atomic modesetting WARN - Nouveau fix for when fbdev is disabled - i915 fixes for FBC on Haswell and displayport regression - Exynos fix for a display panel regression and some other minor changes - Atmel fixes for scaling and OF graph interaction - Allwiinner build, warning and probing fixes - AMD GPU non-polaris fix for num_rbs and some minor fixes Also I've just moved house, and my new place is Internet challenged due to incompetent incumbent ISPs, hopefully sorted out in a couple of weeks, so I might not be too responsive over the next while. It also helps Daniel is on holidays for those couple of weeks as well" * tag 'drm-fixes-for-v4.7-rc5' of git://people.freedesktop.org/~airlied/linux: (38 commits) drm/atomic: Make drm_atomic_legacy_backoff reset crtc->acquire_ctx drm/nouveau: fix for disabled fbdev emulation drm/i915/fbc: Disable on HSW by default for now drm/i915: Revert DisplayPort fast link training feature drm/amd/powerplay: enable clock stretch feature for polaris drm/amdgpu/gfx8: update golden setting for polaris10 drm/amd/powerplay: enable avfs feature for polaris drm/amdgpu/atombios: add avfs struct for Polaris10/11 drm/amd/powerplay: add avfs related define for polaris drm/amd/powrplay: enable stutter_mode for polaris. drm/amd/powerplay: disable UVD SMU handshake for MCLK. drm/amd/powerplay: initialize variables which were missed. drm/amd/powerplay: enable PowerContainment feature for polaris10/11. drm/amd/powerplay: need to notify system bios pcie device ready drm/amd/powerplay: fix bug that function parameter was incorect. drm/amd/powerplay: fix logic error. drm: atmel-hlcdc: Fix OF graph parsing drm: atmel-hlcdc: actually disable scaling when no scaling is required drm/amdgpu: initialize amdgpu_cgs_acpi_eval_object result value drm/amdgpu: precedence bug in amdgpu_device_init() ... commit 75befb31ec3cfc74bc502b034b67cc07e1eac6f7 Merge: da01e18 ef0dab4 Author: Linus Torvalds Date: Thu Jun 23 20:59:14 2016 -0700 Merge tag 'pci-v4.7-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci Pull PCI fix from Bjorn Helgaas: "Here's a small fix for v4.7. This problem was actually introduced in v4.6 when we unified Kconfig, making PCIe support available everywhere including sparc, where config reads into unaligned buffers cause warnings. This fix is from Dave Miller. As a reminder, any future PCI fixes for v4.7 will probably come from Alex Williamson, since I'll be on vacation for most of the rest of this cycle. I should be back about the time the merge window opens" * tag 'pci-v4.7-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: PCI: Fix unaligned accesses in VC code commit 81e257e964268d050f8e9188becd44d50f241d72 Author: Maarten Lankhorst Date: Thu Jun 23 13:45:06 2016 +0200 drm/atomic: Make drm_atomic_legacy_backoff reset crtc->acquire_ctx Atomic updates may acquire more state than initially locked through drm_modeset_lock_crtc, running with heavy stress can cause a WARN_ON(crtc->acquire_ctx) in drm_modeset_lock_crtc: [ 601.491296] ------------[ cut here ]------------ [ 601.491366] WARNING: CPU: 0 PID: 2411 at drivers/gpu/drm/drm_modeset_lock.c:191 drm_modeset_lock_crtc+0xeb/0xf0 [drm] [ 601.491369] Modules linked in: drm i915 drm_kms_helper [ 601.491414] CPU: 0 PID: 2411 Comm: kms_cursor_lega Tainted: G U 4.7.0-rc4-patser+ #4798 [ 601.491417] Hardware name: Intel Corporation Skylake Client [ 601.491420] 0000000000000000 ffff88044d153c98 ffffffff812ead28 0000000000000000 [ 601.491425] 0000000000000000 ffff88044d153cd8 ffffffff810868e6 000000bf58058030 [ 601.491431] ffff880088b415e8 ffff880458058030 ffff88008a271548 ffff88008a271568 [ 601.491436] Call Trace: [ 601.491443] [] dump_stack+0x4d/0x65 [ 601.491447] [] __warn+0xc6/0xe0 [ 601.491452] [] warn_slowpath_null+0x18/0x20 [ 601.491472] [] drm_modeset_lock_crtc+0xeb/0xf0 [drm] [ 601.491491] [] drm_mode_cursor_common+0x66/0x180 [drm] [ 601.491509] [] drm_mode_cursor_ioctl+0x3c/0x40 [drm] [ 601.491524] [] drm_ioctl+0x14d/0x530 [drm] [ 601.491540] [] ? drm_mode_setcrtc+0x520/0x520 [drm] [ 601.491545] [] ? handle_mm_fault+0x106b/0x1430 [ 601.491550] [] ? stop_one_cpu+0x61/0x70 [ 601.491556] [] do_vfs_ioctl+0x8d/0x570 [ 601.491560] [] ? security_file_ioctl+0x3e/0x60 [ 601.491565] [] SyS_ioctl+0x74/0x80 [ 601.491571] [] ? posix_get_monotonic_raw+0xc/0x10 [ 601.491576] [] entry_SYSCALL_64_fastpath+0x13/0x8f [ 601.491581] ---[ end trace 56f3d3d85f000d00 ]--- For good measure, test mode_config.acquire_ctx too, although this should never happen. Testcase: kms_cursor_legacy Signed-off-by: Maarten Lankhorst Reviewed-by: Daniel Vetter Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie drivers/gpu/drm/drm_atomic.c | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) commit f939a5f432981872f89d4dfe506e959f49cc161a Merge: c65c3de 270d013 Author: Dave Airlie Date: Fri Jun 24 10:51:12 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes A bit bigger than I would normally like, but most of the large changes are for polaris support and since polaris went upstream in 4.7, I'd like to get the fixes in so it's in good shape when the hw becomes available. The major changes only touch the polaris code so there is little chance for regressions on other asics. The rest are just the usual collection of bug fixes. * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: drm/amd/powerplay: enable clock stretch feature for polaris drm/amdgpu/gfx8: update golden setting for polaris10 drm/amd/powerplay: enable avfs feature for polaris drm/amdgpu/atombios: add avfs struct for Polaris10/11 drm/amd/powerplay: add avfs related define for polaris drm/amd/powrplay: enable stutter_mode for polaris. drm/amd/powerplay: disable UVD SMU handshake for MCLK. drm/amd/powerplay: initialize variables which were missed. drm/amd/powerplay: enable PowerContainment feature for polaris10/11. drm/amd/powerplay: need to notify system bios pcie device ready drm/amd/powerplay: fix bug that function parameter was incorect. drm/amd/powerplay: fix logic error. drm/amdgpu: initialize amdgpu_cgs_acpi_eval_object result value drm/amdgpu: precedence bug in amdgpu_device_init() drm/amdgpu: fix num_rbs exposed to userspace (v2) drm/amdgpu: missing bounds check in amdgpu_set_pp_force_state() commit 1ee6667cd8d183b2fed12f97285f184431d2caf9 Author: Dan Williams Date: Thu Jun 23 17:50:39 2016 -0700 libnvdimm, pfn, dax: fix initialization vs autodetect for mode + alignment The updated ndctl unit tests discovered that if a pfn configuration with a 4K alignment is read from the namespace, that alignment will be ignored in favor of the default 2M alignment. The result is that the configuration will fail initialization with a message like: dax6.1: bad offset: 0x22000 dax disabled align: 0x200000 Fix this by allowing the alignment read from the info block to override the default which is 2M not 0 in the autodetect path. This also fixes a similar problem with the mode and alignment settings silently being overwritten by the kernel when userspace has changed it. We now will either overwrite the info block if userspace changes the uuid or fail and warn if a live setting disagrees with the info block. Cc: Cc: Micah Parrish Cc: Toshi Kani Signed-off-by: Dan Williams drivers/nvdimm/pfn_devs.c | 51 +++++++++++++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 11 deletions(-) commit 60842ef8128e7bf58c024814cd0dc14319232b6c Author: Sinclair Yeh Date: Thu Jun 23 17:37:34 2016 -0700 Input: vmmouse - remove port reservation The VMWare EFI BIOS will expose port 0x5658 as an ACPI resource. This causes the port to be reserved by the APCI module as the system comes up, making it unavailable to be reserved again by other drivers, thus preserving this VMWare port for special use in a VMWare guest. This port is designed to be shared among multiple VMWare services, such as the VMMOUSE. Because of this, VMMOUSE should not try to reserve this port on its own. The VMWare non-EFI BIOS does not do this to preserve compatibility with existing/legacy VMs. It is known that there is small chance a VM may be configured such that these ports get reserved by other non-VMWare devices, and if this ever happens, the result is undefined. Signed-off-by: Sinclair Yeh Reviewed-by: Thomas Hellstrom Cc: # 4.1- Signed-off-by: Dmitry Torokhov drivers/input/mouse/vmmouse.c | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) commit c65c3de673785c58c33e9d3f8d1203ba30efb595 Merge: 59b0b70 41abbf5 Author: Dave Airlie Date: Fri Jun 24 10:35:03 2016 +1000 Merge branch 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-fixes Since HW trigger mode was suppoted we have faced with a issue that Display panel didn't work correctly when trigger mode was changed in booting time. For this, we keep trigger mode with SW trigger mode in default mode like we did before. However, we will need to consider PSR(Panel Self Reflash) mode to resolve this issue fundamentally later. * 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: drm/exynos: use logical AND in exynos_drm_plane_check_size() drm/exynos: remove superfluous inclusions of fbdev header drm/exynos: g2d: drop the _REG postfix from the stride defines drm/exynos: don't use HW trigger for Exynos5420/5422/5800 drm/exynos: fimd: don't set .has_hw_trigger in s3c6400 driver data drm/exynos: dp: Fix NULL pointer dereference due uninitialized connector commit 59b0b70f51c1d7f22cdc4f8905cad15f19ed60ff Merge: f762bfd 0b1e1eb Author: Dave Airlie Date: Fri Jun 24 10:34:49 2016 +1000 Merge tag 'drm-atmel-hlcdc-fixes/for-4.7-rc5' of github.com:bbrezillon/linux-at91 into drm-fixes Two bug fixes for the atmel-hlcdc driver. * tag 'drm-atmel-hlcdc-fixes/for-4.7-rc5' of github.com:bbrezillon/linux-at91: drm: atmel-hlcdc: Fix OF graph parsing drm: atmel-hlcdc: actually disable scaling when no scaling is required commit f762bfda2b81db4c3397a31e92f819818cf04efb Merge: c38e801 13fef09 Author: Dave Airlie Date: Fri Jun 24 10:34:35 2016 +1000 Merge tag 'sunxi-drm-fixes-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into drm-fixes Allwinner sun4i DRM driver fixes A bunch of fixes that address: - Compilation errors in various corner cases - Move to helpers - Fix the pixel clock computation - Fix our panel probe * tag 'sunxi-drm-fixes-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: drm: sun4i: do cleanup if RGB output init fails drm/sun4i: Convert to connector register helpers drm/sun4i: remove simplefb at probe drm/sun4i: rgb: panel is an error pointer drm/sun4i: defer only if we didn't find our panel drm/sun4i: rgb: Validate the clock rate drm/sun4i: request exact rates to our parents drm: sun4i: fix probe error handling drm: sun4i: print DMA address correctly drm/sun4i: add COMMON_CLK dependency commit c38e80169befdea4a9438cc6c513794d7c50e88f Merge: 718cc66 1e3fa0a Author: Dave Airlie Date: Fri Jun 24 10:32:30 2016 +1000 Merge tag 'drm-intel-fixes-2016-06-22' of git://anongit.freedesktop.org/drm-intel into drm-fixes Hi Dave, just a couple of display fixes, both stable stuff. Maybe we'll be able to enable fbc by default one day. * tag 'drm-intel-fixes-2016-06-22' of git://anongit.freedesktop.org/drm-intel: drm/i915/fbc: Disable on HSW by default for now drm/i915: Revert DisplayPort fast link training feature commit 718cc664792c4ce436f221fe0e0a26a605308d4b Merge: 33688ab 52dfcc5 Author: Dave Airlie Date: Fri Jun 24 10:16:37 2016 +1000 Merge branch 'linux-4.7' of git://github.com/skeggsb/linux into drm-fixes * 'linux-4.7' of git://github.com/skeggsb/linux: drm/nouveau: fix for disabled fbdev emulation commit 52dfcc5ccfbb6697ac3cac7f7ff1e712760e1216 Author: Dmitrii Tcvetkov Date: Mon Jun 20 13:52:14 2016 +0300 drm/nouveau: fix for disabled fbdev emulation Hello, after this commit: commit f045f459d925138fe7d6193a8c86406bda7e49da Author: Ben Skeggs Date: Thu Jun 2 12:23:31 2016 +1000 drm/nouveau/fbcon: fix out-of-bounds memory accesses kernel started to oops when loading nouveau module when using GTX 780 Ti video adapter. This patch fixes the problem. Bug report: https://bugzilla.kernel.org/show_bug.cgi?id=120591 Signed-off-by: Dmitrii Tcvetkov Suggested-by: Ilia Mirkin Fixes: f045f459d925 ("nouveau_fbcon_init()") Signed-off-by: Ben Skeggs Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nouveau_fbcon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 82d6489d0fed2ec8a8c48c19e8d8a04ac8e5bb26 Author: Daniel Bristot de Oliveira Date: Wed Jun 22 17:28:41 2016 -0300 cgroup: Disable IRQs while holding css_set_lock While testing the deadline scheduler + cgroup setup I hit this warning. [ 132.612935] ------------[ cut here ]------------ [ 132.612951] WARNING: CPU: 5 PID: 0 at kernel/softirq.c:150 __local_bh_enable_ip+0x6b/0x80 [ 132.612952] Modules linked in: (a ton of modules...) [ 132.612981] CPU: 5 PID: 0 Comm: swapper/5 Not tainted 4.7.0-rc2 #2 [ 132.612981] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.8.2-20150714_191134- 04/01/2014 [ 132.612982] 0000000000000086 45c8bb5effdd088b ffff88013fd43da0 ffffffff813d229e [ 132.612984] 0000000000000000 0000000000000000 ffff88013fd43de0 ffffffff810a652b [ 132.612985] 00000096811387b5 0000000000000200 ffff8800bab29d80 ffff880034c54c00 [ 132.612986] Call Trace: [ 132.612987] [] dump_stack+0x63/0x85 [ 132.612994] [] __warn+0xcb/0xf0 [ 132.612997] [] ? push_dl_task.part.32+0x170/0x170 [ 132.612999] [] warn_slowpath_null+0x1d/0x20 [ 132.613000] [] __local_bh_enable_ip+0x6b/0x80 [ 132.613008] [] _raw_write_unlock_bh+0x1a/0x20 [ 132.613010] [] _raw_spin_unlock_bh+0xe/0x10 [ 132.613015] [] put_css_set+0x5c/0x60 [ 132.613016] [] cgroup_free+0x7f/0xa0 [ 132.613017] [] __put_task_struct+0x42/0x140 [ 132.613018] [] dl_task_timer+0xca/0x250 [ 132.613027] [] ? push_dl_task.part.32+0x170/0x170 [ 132.613030] [] __hrtimer_run_queues+0xee/0x270 [ 132.613031] [] hrtimer_interrupt+0xa8/0x190 [ 132.613034] [] local_apic_timer_interrupt+0x38/0x60 [ 132.613035] [] smp_apic_timer_interrupt+0x3d/0x50 [ 132.613037] [] apic_timer_interrupt+0x8c/0xa0 [ 132.613038] [] ? native_safe_halt+0x6/0x10 [ 132.613043] [] default_idle+0x1e/0xd0 [ 132.613044] [] arch_cpu_idle+0xf/0x20 [ 132.613046] [] default_idle_call+0x2a/0x40 [ 132.613047] [] cpu_startup_entry+0x2e7/0x340 [ 132.613048] [] start_secondary+0x155/0x190 [ 132.613049] ---[ end trace f91934d162ce9977 ]--- The warn is the spin_(lock|unlock)_bh(&css_set_lock) in the interrupt context. Converting the spin_lock_bh to spin_lock_irq(save) to avoid this problem - and other problems of sharing a spinlock with an interrupt. Cc: Tejun Heo Cc: Li Zefan Cc: Johannes Weiner Cc: Juri Lelli Cc: Steven Rostedt Cc: cgroups@vger.kernel.org Cc: stable@vger.kernel.org # 4.5+ Cc: linux-kernel@vger.kernel.org Reviewed-by: Rik van Riel Reviewed-by: "Luis Claudio R. Goncalves" Signed-off-by: Daniel Bristot de Oliveira Acked-by: Zefan Li Signed-off-by: Tejun Heo kernel/cgroup.c | 142 +++++++++++++++++++++++++++++--------------------------- 1 file changed, 74 insertions(+), 68 deletions(-) commit 0d37189e80163c653771916afe28fae1a8d14daa Author: Chanwoo Choi Date: Thu Jun 23 11:18:43 2016 +0900 PM / devfreq: Send the DEVFREQ_POSTCHANGE notification when target() is failed This patch sends the DEVFREQ_POSTCHANGE notification when devfreq->profile->targer() is failed. The PRECHANGE/POSTCHANGE should be paired. Fixes: 0fe3a66410a3 (PM / devfreq: Add new DEVFREQ_TRANSITION_NOTIFIER notifier) Reported-by: Lin Huang Signed-off-by: Chanwoo Choi Signed-off-by: Rafael J. Wysocki drivers/devfreq/devfreq.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 3c67a829bd45f99b5c03580bb898c99fcc023356 Author: Mike Galbraith Date: Thu Jun 23 08:45:42 2016 +0200 cpufreq: pcc-cpufreq: Fix doorbell.access_width Commit 920de6ebfab8 (ACPICA: Hardware: Enhance acpi_hw_validate_register() with access_width/bit_offset awareness) apparently exposed a latent bug, doorbell.access_width is initialized to 64, but per Lv Zheng, it should be 4, and indeed, making that change does bring pcc-cpufreq back to life. Fixes: 920de6ebfab8 (ACPICA: Hardware: Enhance acpi_hw_validate_register() with access_width/bit_offset awareness) Suggested-by: Lv Zheng Signed-off-by: Mike Galbraith Signed-off-by: Rafael J. Wysocki drivers/cpufreq/pcc-cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 226ba707744a51acb4244724e09caacb1d96aed9 Author: Dmitry Torokhov Date: Tue Jun 21 16:09:00 2016 -0700 Input: elantech - add more IC body types to the list The touchpad in HP Pavilion 14-ab057ca reports it's version as 12 and according to Elan both 11 and 12 are valid IC types and should be identified as hw_version 4. Reported-by: Patrick Lessard Tested-by: Patrick Lessard Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/mouse/elantech.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 9e72ac7492149a229ce9039c680849cb682d7092 Author: Ping Cheng Date: Thu Jun 23 10:55:11 2016 -0700 Input: wacom_w8001 - ignore invalid pen data packets ThinkPad X60 Tablet PC (pen only device) sometime posts packets that are larger than W8001_PKTLEN_TPCPEN. Reported-by: Chris J Arges Tested-by: Chris J Arges Signed-off-by: Ping Cheng Reviewed-by: Peter Hutterer Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/touchscreen/wacom_w8001.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit c40e4096bf0a12a76c349cbc4d1b2aa40a3d68cd Author: Or Gerlitz Date: Tue Jun 21 16:36:06 2016 +0300 MAINTAINERS: Update Mellanox's mlx4 Eth NIC driver entry Tariq Toukan is replacing Eugenia (Jenny) Emantayev as the mlx4 Ethernet driver maintainer, thanks to Jenny and good luck to him. Signed-off-by: Or Gerlitz Signed-off-by: David S. Miller MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 00e8cb00bc72f5279fde9d014b47f36dc4805dd8 Merge: efeb226 034fdd4 Author: David S. Miller Date: Thu Jun 23 15:22:31 2016 -0400 Merge tag 'wireless-drivers-for-davem-2016-06-21' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers Kalle Valo says: ==================== wireless-drivers fixes for 4.7 iwlwifi * fix the scan timeout for long scans * fix an RCU splat caused when updating the TKIP key * fix a potential NULL-derefence introduced recently * fix a IGTK key bug that has existed since the MVM driver was introduced * fix some fw capabilities checks that got accidentally inverted rtl8xxxu * fix typo on variable name ath10k * fix deadlock when peer cannot be created * fix crash related to printing features * fix deadlock while processing rx_in_ord_ind ath9k * fix GPIO mask regression for AR9462 and AR9565 ==================== Signed-off-by: David S. Miller commit da01e18a37a57f360222d3a123b8f6994aa1ad14 Author: Linus Torvalds Date: Thu Jun 23 12:20:01 2016 -0700 x86: avoid avoid passing around 'thread_info' in stack dumping code None of the code actually wants a thread_info, it all wants a task_struct, and it's just converting to a thread_info pointer much too early. No semantic change. Signed-off-by: Linus Torvalds arch/x86/include/asm/stacktrace.h | 6 +++--- arch/x86/kernel/dumpstack.c | 22 ++++++++++------------ arch/x86/kernel/dumpstack_32.c | 4 +--- arch/x86/kernel/dumpstack_64.c | 8 +++----- 4 files changed, 17 insertions(+), 23 deletions(-) commit efeb2267bba8aa893afdadfc9bae4790777c600c Author: Haishuang Yan Date: Tue Jun 21 16:26:49 2016 +0800 geneve: fix tx_errors statistics Tx errors present summation of errors encountered while transmitting packets. Signed-off-by: Haishuang Yan Signed-off-by: David S. Miller drivers/net/geneve.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 52fe705b493d40b472b9e7220a71bdca8537c6b2 Author: Chris Packham Date: Tue Jun 21 15:39:43 2016 +1200 net: vrf: replace hard tab with space in assignment The assignment of rth->dst.output in vrf_rt6_create() and vrf_rtable_create() used a hard tab before the '='. The neighboring assignments did not. Make the assignment of rth->dst.output consistent with the surrounding code. Signed-off-by: Chris Packham Acked-by: David Ahern Signed-off-by: David S. Miller drivers/net/vrf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6720a305df74ca30bcc10fc316881641b6ff0c80 Author: Linus Torvalds Date: Thu Jun 23 12:11:17 2016 -0700 locking: avoid passing around 'thread_info' in mutex debugging code None of the code actually wants a thread_info, it all wants a task_struct, and it's just converting back and forth between the two ("ti->task" to get the task_struct from the thread_info, and "task_thread_info(task)" to go the other way). No semantic change. Acked-by: Peter Zijlstra Signed-off-by: Linus Torvalds kernel/locking/mutex-debug.c | 12 ++++++------ kernel/locking/mutex-debug.h | 4 ++-- kernel/locking/mutex.c | 6 +++--- kernel/locking/mutex.h | 2 +- 4 files changed, 12 insertions(+), 12 deletions(-) commit 21de12ee5568fd1aec47890c72967abf791ac80a Author: Eric Dumazet Date: Mon Jun 20 15:00:43 2016 -0700 netem: fix a use after free If the packet was dropped by lower qdisc, then we must not access it later. Save qdisc_pkt_len(skb) in a temp variable. Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Signed-off-by: Eric Dumazet Cc: WANG Cong Cc: Jamal Hadi Salim Cc: Stephen Hemminger Signed-off-by: David S. Miller net/sched/sch_netem.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 12afb34400eb2b301f06b2aa3535497d14faee59 Author: Ping Cheng Date: Thu Jun 23 10:54:17 2016 -0700 Input: wacom_w8001 - w8001_MAX_LENGTH should be 13 Somehow the patch that added two-finger touch support forgot to update W8001_MAX_LENGTH from 11 to 13. Signed-off-by: Ping Cheng Reviewed-by: Peter Hutterer Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/touchscreen/wacom_w8001.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0812a945fbb814e7946fbe6ddcc81d054c8b6c91 Author: Rex Zhu Date: Wed Jun 22 21:00:09 2016 +0800 drm/amd/powerplay: Update CKS on/ CKS off voltage offset calculation CKS on/off voltage offset calculation algorithm takes in a few coefficients. We need to update them for polaris to latest coefficients to align with BB. Signed-off-by: Rex Zhu Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 26 ++++++++++++++-------- 1 file changed, 17 insertions(+), 9 deletions(-) commit 83a7af6dcfd2d84066c6d19bf2bd837f7be4a5ca Author: Rex Zhu Date: Thu Jun 23 11:05:00 2016 +0800 drm/amd/powerplay: disable FFC. SMC need use VBI signal for MCLK switching Send 2 x frame time as vbi timeout Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 26 +++++++++++++++++----- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.h | 1 + drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 2 ++ 3 files changed, 24 insertions(+), 5 deletions(-) commit 02bae045f3b3bc5681f075be0a8b1313147d1df2 Author: Rex Zhu Date: Thu Jun 23 10:58:26 2016 +0800 drm/amd/powerplay: add some definition for FFC feature on polaris. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/inc/polaris10_ppsmc.h | 2 ++ drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) commit b7f67055d2df9b8f68f02e49d256ee3973999bd2 Author: Chandan Rajendra Date: Thu Jun 23 15:16:44 2016 +0530 Btrfs: Force stripesize to the value of sectorsize Btrfs code currently assumes stripesize to be same as sectorsize. However Btrfs-progs (until commit df05c7ed455f519e6e15e46196392e4757257305) has been setting btrfs_super_block->stripesize to a value of 4096. This commit makes sure that the value of btrfs_super_block->stripesize is a power of 2. Later, it unconditionally sets btrfs_root->stripesize to sectorsize. Signed-off-by: Chandan Rajendra Reviewed-by: David Sterba Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/disk-io.c | 6 ++---- fs/btrfs/volumes.c | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) commit c0d2f6104e8ab2eb75e58e72494ad4b69c5227f8 Author: Wang Xiaoguang Date: Wed Jun 22 09:57:01 2016 +0800 btrfs: fix disk_i_size update bug when fallocate() fails When doing truncate operation, btrfs_setsize() will first call truncate_setsize() to set new inode->i_size, but if later btrfs_truncate() fails, btrfs_setsize() will call "i_size_write(inode, BTRFS_I(inode)->disk_i_size)" to reset the inmemory inode size, now bug occurs. It's because for truncate case btrfs_ordered_update_i_size() directly uses inode->i_size to update BTRFS_I(inode)->disk_i_size, indeed we should use the "offset" argument to update disk_i_size. Here is the call graph: ==>btrfs_truncate() ====>btrfs_truncate_inode_items() ======>btrfs_ordered_update_i_size(inode, last_size, NULL); Here btrfs_ordered_update_i_size()'s offset argument is last_size. And below test case can reveal this bug: dd if=/dev/zero of=fs.img bs=$((1024*1024)) count=100 dev=$(losetup --show -f fs.img) mkdir -p /mnt/mntpoint mkfs.btrfs -f $dev mount $dev /mnt/mntpoint cd /mnt/mntpoint echo "workdir is: /mnt/mntpoint" blocksize=$((128 * 1024)) dd if=/dev/zero of=testfile bs=$blocksize count=1 sync count=$((17*1024*1024*1024/blocksize)) echo "file size is:" $((count*blocksize)) for ((i = 1; i <= $count; i++)); do i=$((i + 1)) dst_offset=$((blocksize * i)) xfs_io -f -c "reflink testfile 0 $dst_offset $blocksize"\ testfile > /dev/null done sync truncate --size 0 testfile ls -l testfile du -sh testfile exit In this case, truncate operation will fail for enospc reason and "du -sh testfile" returns value greater than 0, but testfile's size is 0, we need to reflect correct inode->i_size. Signed-off-by: Wang Xiaoguang Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/ordered-data.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 415b35a55b57a701afe7391d32a6bb0193b7d3da Author: Liu Bo Date: Fri Jun 17 19:16:21 2016 -0700 Btrfs: fix error handling in map_private_extent_buffer map_private_extent_buffer() can return -EINVAL in two different cases, 1. when the requested contents span two pages if nodesize is larger than pagesize, 2. when it detects something insane. The 2nd one used to be only a WARN_ON(1), and we decided to return a error to callers, but we didn't fix up all its callers, which will be addressed by this patch. Without this, btrfs may end up with 'general protection', ie. reading invalid memory. Reported-by: Vegard Nossum Signed-off-by: Liu Bo Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/ctree.c | 6 +++++- fs/btrfs/extent_io.c | 7 ++++++- 2 files changed, 11 insertions(+), 2 deletions(-) commit 04e1b65af2085d4102b2b5d2fd1e050f8ee63092 Author: Wei Yongjun Date: Fri Jun 17 17:20:40 2016 +0000 Btrfs: fix error return code in btrfs_init_test_fs() Fix to return a negative error code from the kern_mount() error handling case instead of 0(ret is set to 0 by register_filesystem), as done elsewhere in this function. Signed-off-by: Wei Yongjun Reviewed-by: Omar Sandoval Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/tests/btrfs-tests.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c7f1429389ec1aa25e042bb13451385fbb596f8c Author: Cameron Gutman Date: Thu Jun 23 10:24:42 2016 -0700 Input: xpad - fix oops when attaching an unknown Xbox One gamepad Xbox One controllers have multiple interfaces which all have the same class, subclass, and protocol. One of the these interfaces has only a single endpoint. When Xpad attempts to bind to this interface, it causes an oops when trying initialize the output URB by trying to access the second endpoint's descriptor. This situation was avoided for known Xbox One devices by checking the XTYPE constant associated with the VID and PID tuple. However, this breaks when new or previously unknown Xbox One controllers are attached to the system. This change addresses the problem by deriving the XTYPE for Xbox One controllers based on the interface protocol before checking the interface number. Fixes: 1a48ff81b391 ("Input: xpad - add support for Xbox One controllers") Signed-off-by: Cameron Gutman Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov drivers/input/joystick/xpad.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) commit 33cdcee04be3b4482be97393167e7561b2584e1e Author: Boris Brezillon Date: Wed Jun 22 09:25:14 2016 +0200 pwm: Fix pwm_apply_args() Commit 5ec803edcb70 ("pwm: Add core infrastructure to allow atomic updates"), implemented pwm_disable() as a wrapper around pwm_apply_state(), and then, commit ef2bf4997f7d ("pwm: Improve args checking in pwm_apply_state()") added missing checks on the ->period value in pwm_apply_state() to ensure we were not passing inappropriate values to the ->config() or ->apply() methods. The conjunction of these 2 commits led to a case where pwm_disable() was no longer succeeding, thus preventing the polarity setting done in pwm_apply_args(). Set a valid period in pwm_apply_args() to ensure polarity setting won't be rejected. Signed-off-by: Boris Brezillon Reported-by: Geert Uytterhoeven Suggested-by: Brian Norris Fixes: 5ec803edcb70 ("pwm: Add core infrastructure to allow atomic updates") Tested-by: Geert Uytterhoeven Reviewed-by: Brian Norris Signed-off-by: Thierry Reding include/linux/pwm.h | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit 9903fd1374e913f5086b58af09d4e3fd6e9e86fe Merge: c0cf451 c755f4a 7748e49 cbc9355 Author: Doug Ledford Date: Thu Jun 23 12:22:33 2016 -0400 Merge branches '4.7-rc-misc', 'hfi1-fixes', 'i40iw-rc-fixes' and 'mellanox-rc-fixes' into k.o/for-4.7-rc commit c0cf4512a31eb3cec70b066bc36ed55f7d05b8c0 Author: Bart Van Assche Date: Thu Jun 23 09:35:48 2016 +0200 IB/srpt: Reduce QP buffer size The memory needed for the send and receive queues associated with a QP is proportional to the max_sge parameter. The current value of that parameter is such that with an mlx4 HCA the QP buffer size is 8 MB. Since DMA is used for communication between HCA and CPU that buffer either has to be allocated coherently or map_single() must succeed for that buffer. Since large contiguous allocations are fragile and since the maximum segment size for e.g. swiotlb is 256 KB, reduce the max_sge parameter. This patch avoids that the following text appears on the console after SRP logout and relogin on a system equipped with multiple IB HCAs: mlx4_core 0000:05:00.0: swiotlb buffer is full (sz: 8388608 bytes) swiotlb: coherent allocation failed for device 0000:05:00.0 size=8388608 CPU: 11 PID: 148 Comm: kworker/11:1 Not tainted 4.7.0-rc4-dbg+ #1 Call Trace: [] dump_stack+0x67/0x92 [] swiotlb_alloc_coherent+0x141/0x150 [] x86_swiotlb_alloc_coherent+0x3e/0x50 [] mlx4_buf_direct_alloc.isra.5+0x9a/0x120 [mlx4_core] [] mlx4_buf_alloc+0x165/0x1a0 [mlx4_core] [] create_qp_common.isra.29+0x57d/0xff0 [mlx4_ib] [] mlx4_ib_create_qp+0x12a/0x3f0 [mlx4_ib] [] ib_create_qp+0x3a/0x250 [ib_core] [] srpt_cm_handler+0x4bb/0xcad [ib_srpt] [] cm_process_work+0x20/0xf0 [ib_cm] [] cm_work_handler+0x1ac0/0x2059 [ib_cm] [] process_one_work+0x19d/0x490 [] worker_thread+0x49/0x490 [] kthread+0xea/0x100 [] ret_from_fork+0x1f/0x40 Fixes: b99f8e4d7bcd ("IB/srpt: convert to the generic RDMA READ/WRITE API") Signed-off-by: Bart Van Assche Cc: Laurence Oberman Cc: Christoph Hellwig Cc: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/ulp/srpt/ib_srpt.c | 3 +-- drivers/infiniband/ulp/srpt/ib_srpt.h | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) commit 817e9f2c5c262b2716f5d77020d118ad53315f3e Author: WANG Cong Date: Mon Jun 20 13:37:19 2016 -0700 act_ife: acquire ife_mod_lock before reading ifeoplist Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Acked-by: Jamal Hadi Salim Signed-off-by: David S. Miller net/sched/act_ife.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit 067a7cd06f7bf860f2e3415394b065b9a0983802 Author: WANG Cong Date: Mon Jun 20 13:37:18 2016 -0700 act_ife: only acquire tcf_lock for existing actions Alexey reported that we have GFP_KERNEL allocation when holding the spinlock tcf_lock. Actually we don't have to take that spinlock for all the cases, especially for the new one we just create. To modify the existing actions, we still need this spinlock to make sure the whole update is atomic. For net-next, we can get rid of this spinlock because we already hold the RTNL lock on slow path, and on fast path we can use RCU to protect the metalist. Joint work with Jamal. Reported-by: Alexey Khoroshilov Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Acked-by: Jamal Hadi Salim Signed-off-by: David S. Miller include/net/tc_act/tc_ife.h | 6 ++--- net/sched/act_ife.c | 55 +++++++++++++++++++++++++-------------------- 2 files changed, 34 insertions(+), 27 deletions(-) commit 962fcef33b03395051367181a0549d29d109d9a4 Author: Herbert Xu Date: Sat Jun 18 13:03:36 2016 +0800 esp: Fix ESN generation under UDP encapsulation Blair Steven noticed that ESN in conjunction with UDP encapsulation is broken because we set the temporary ESP header to the wrong spot. This patch fixes this by first of all using the right spot, i.e., 4 bytes off the real ESP header, and then saving this information so that after encryption we can restore it properly. Fixes: 7021b2e1cddd ("esp4: Switch to new AEAD interface") Reported-by: Blair Steven Signed-off-by: Herbert Xu Acked-by: Steffen Klassert Signed-off-by: David S. Miller net/ipv4/esp4.c | 52 ++++++++++++++++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 20 deletions(-) commit 7748e4990de42ea796543c0ffd34118c3a5e6a98 Author: Shiraz Saleem Date: Tue Jun 14 16:54:19 2016 -0500 i40iw: Enable level-1 PBL for fast memory registration Set the chunk_size to enable level-1 PBL support when the fast memory page count is more than one. Signed-off-by: Shiraz Saleem Signed-off-by: Faisal Latif Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw.h | 1 + drivers/infiniband/hw/i40iw/i40iw_verbs.c | 5 +++++ 2 files changed, 6 insertions(+) commit 0477e18145c565f9ca74c6df4112f818f673fcaa Author: Faisal Latif Date: Tue Jun 14 16:54:18 2016 -0500 i40iw: Return correct max_fast_reg_page_list_len Return correct value for max_fast_reg_page_list_len from i40iw_query_device(). Signed-off-by: Faisal Latif Signed-off-by: Shiraz Saleem Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw.h | 1 + drivers/infiniband/hw/i40iw/i40iw_verbs.c | 1 + 2 files changed, 2 insertions(+) commit ee23abd75c5076e51061c275e8f659d754a63c9d Author: Faisal Latif Date: Tue Jun 14 16:54:17 2016 -0500 i40iw: Correct status check on i40iw_get_pble i40iw_get_pble returns 0 on success. Correct the check on return code. Signed-off-by: Faisal Latif Signed-off-by: Shiraz Saleem Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 747f1c6d9be749a29612fc78c321b97099906008 Author: Shiraz Saleem Date: Tue Jun 14 16:54:16 2016 -0500 i40iw: Correct CQ arming CQ is armed for solicited events only, ignoring other notification flags. Correct this by arming for next and arming for solicited event if IB_CQ_SOLICITED is set. Also protect CQ shadow area update with spinlock. Signed-off-by: Shiraz Saleem Signed-off-by: Doug Ledford drivers/infiniband/hw/i40iw/i40iw_verbs.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit c755f4afa66ad3ed98870bd3254f37c47fb2c800 Author: Mike Marciniszyn Date: Wed Jun 22 13:29:33 2016 -0700 IB/rdmavt: Correct qp_priv_alloc() return value test The current drivers return errors from this calldown wrapped in an ERR_PTR(). The rdmavt code incorrectly tests for NULL. The code is fixed to use IS_ERR() and change ret according to the driver return value. Cc: Stable # 4.6+ Reviewed-by: Dennis Dalessandro Signed-off-by: Mike Marciniszyn Signed-off-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/sw/rdmavt/qp.c | 4 +++- include/rdma/rdma_vt.h | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) commit 8ae84f7c56044ee17ef6b700cb34d11ad9428a2e Author: Ashutosh Dixit Date: Fri Jun 17 19:17:54 2016 -0700 IB/hfi1: Don't zero out qp->s_ack_queue in rvt_reset_qp Since rvt_reset_qp already zero's out qp->s_ack_queue head and tail pointers, there is no need to zero out qp->s_ack_queue itself. Reviewed-by: Dennis Dalessandro Reviewed-by: Mike Marciniszyn Signed-off-by: Ashutosh Dixit Signed-off-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/sw/rdmavt/qp.c | 6 ------ 1 file changed, 6 deletions(-) commit 2aee309d3e01447c55fdf89cef05a0e2be372655 Author: Mike Marciniszyn Date: Fri Jun 17 19:17:49 2016 -0700 IB/hfi1: Fix deadlock with txreq allocation slow path A failure in the get_txreq() inline will result in a slow path retry using __get_txreq(). __get_txreq() attempts to procure the qp s_lock, which is already held in all callers. Fix by deleting the s_lock maintenance in __get_txreq() and add sparse syntax hooks to future proof the code. Cc: Stable # 4.6+ Reviewed-by: Dennis Dalessandro Signed-off-by: Mike Marciniszyn Signed-off-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/verbs_txreq.c | 4 +--- drivers/infiniband/hw/hfi1/verbs_txreq.h | 1 + 2 files changed, 2 insertions(+), 3 deletions(-) commit cbc9355a939b90263c58beb855f8151b56634c42 Author: Chuck Lever Date: Wed Jun 22 17:27:32 2016 +0300 IB/mlx4: Prevent cross page boundary allocation Prevent cross page boundary allocation by allocating new page, this is required to be aligned with ConnectX-3 HW requirements. Not doing that might cause to "RDMA read local protection" error. Fixes: 1b2cd0fc673c ('IB/mlx4: Support the new memory registration API') Suggested-by: Christoph Hellwig Signed-off-by: Chuck Lever Reviewed-by: Sagi Grimberg Signed-off-by: Yishai Hadas Signed-off-by: Leon Romanovsky Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/mlx4_ib.h | 2 +- drivers/infiniband/hw/mlx4/mr.c | 34 +++++++++++++++++----------------- 2 files changed, 18 insertions(+), 18 deletions(-) commit 5b420d9cf7382c6e1512e96e02d18842d272049c Author: Dotan Barak Date: Wed Jun 22 17:27:31 2016 +0300 IB/mlx4: Fix memory leak if QP creation failed When RC, UC, or RAW QPs are created, a qp object is allocated (kzalloc). If at a later point (in procedure create_qp_common) the qp creation fails, this qp object must be freed. Fixes: 1ffeb2eb8be99 ("IB/mlx4: SR-IOV IB context objects and proxy/tunnel SQP support") Signed-off-by: Dotan Barak Signed-off-by: Jack Morgenstein Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/qp.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 5533c18ab02b17a7f2ac11908e2d97d4b421617d Author: Yishai Hadas Date: Wed Jun 22 17:27:30 2016 +0300 IB/mlx4: Verify port number in flow steering create flow In procedure mlx4_ib_create_flow, passing an invalid port number will cause an out-of-bounds array access. Data passed to this procedure can come from user-space. Therefore, need to validate port number before proceeding onwards. Note that we check against the number of physical ports declared at the verbs (ib core) level; When bonding is active, the verbs level sees one physical port, even though the low-level driver sees two ports. Fixes: f77c0162a339 ("IB/mlx4: Add receive flow steering support") Signed-off-by: Yishai Hadas Reviewed-by: Jack Morgenstein Reviewed-by: Moni Shoua Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/main.c | 3 +++ 1 file changed, 3 insertions(+) commit a6100603a4a87fc436199362bdb81cb849faaf6e Author: Yishai Hadas Date: Wed Jun 22 17:27:29 2016 +0300 IB/mlx4: Fix error flow when sending mads under SRIOV Fix mad send error flow to prevent double freeing address handles, and leaking tx_ring entries when SRIOV is active. If ib_mad_post_send fails, the address handle pointer in the tx_ring entry must be set to NULL (or there will be a double-free) and tx_tail must be incremented (or there will be a leak of tx_ring entries). The tx_ring is handled the same way in the send-completion handler. Fixes: 37bfc7c1e83f ("IB/mlx4: SR-IOV multiplex and demultiplex MADs") Signed-off-by: Yishai Hadas Reviewed-by: Jack Morgenstein Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/mad.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) commit f2940e2c76bb554a7fbdd28ca5b90904117a9e96 Author: Yishai Hadas Date: Wed Jun 22 17:27:28 2016 +0300 IB/mlx4: Fix the SQ size of an RC QP When calculating the required size of an RC QP send queue, leave enough space for masked atomic operations, which require more space than "regular" atomic operation. Fixes: 6fa8f719844b ("IB/mlx4: Add support for masked atomic operations") Signed-off-by: Yishai Hadas Reviewed-by: Jack Morgenstein Reviewed-by: Eran Ben Elisha Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 00bf534fce23048aa0e6fd8dbceedf097ee65508 Author: Talat Batheesh Date: Wed Jun 22 17:27:27 2016 +0300 IB/mlx5: Fix wrong naming of port_rcv_data counter port_xmit_data is written instead of port_rcv_data. Fixes: 3efd9a11212d ('IB/mlx5: Modify MAD reading counters method to use counter registers') Signed-off-by: Talat Batheesh Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/mad.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c9b254955b9f8814966f5dabd34c39d0e0a2b437 Author: Eli Cohen Date: Wed Jun 22 17:27:26 2016 +0300 IB/mlx5: Fix post send fence logic If the caller specified IB_SEND_FENCE in the send flags of the work request and no previous work request stated that the successive one should be fenced, the work request would be executed without a fence. This could result in RDMA read or atomic operations failure due to a MR being invalidated. Fix this by adding the mlx5 enumeration for fencing RDMA/atomic operations and fix the logic to apply this. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB adapters') Signed-off-by: Eli Cohen Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/qp.c | 7 ++++--- include/linux/mlx5/qp.h | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) commit b57141c1abe41e26c09b1b1b7ece463464ba6de2 Author: Maor Gottlieb Date: Wed Jun 22 17:27:25 2016 +0300 IB/uverbs: Initialize ib_qp_init_attr with zeros Initialize ib_qp_init_attr with zeros in order to avoid from garbage in fields that won't be set with user values. Fixes: a060b5629ab06 ('IB/core: generic RDMA READ/WRITE API') Signed-off-by: Maor Gottlieb Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/uverbs_cmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3556005c5f319285610e3eae88b4078e1a4d3bc Author: Eli Cohen Date: Wed Jun 22 17:27:24 2016 +0300 IB/core: Fix false search of the IB_SA_WELL_KNOWN_GUID When virtualziation is supported, VFs may send SA MADs to a GID formed by the concatenation of the subnet prefix with the IB_SA_WELL_KNOWN_GUID. When a response is required, the current code will search the local HCA's port for the received GID to figure out the GID index of the entry containing this GID. However, since this is not a real GID it will not be found and error will be printed. We change the logic to check if the destination GID is this special GID and avoid lookup in this case and use GID index 0. Fixes: a0c1b2a35087 ('IB/core: Support accessing SA in virtualized environment') Signed-off-by: Eli Cohen Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/verbs.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit c65f6c5a3650876a69d1041a9d3c90986e9ca233 Author: Alex Vesker Date: Wed Jun 22 17:27:23 2016 +0300 IB/core: Fix RoCE v1 multicast join logic issue During multicast join of RoCEv1, IGMP join state and max hop limit were updated incorrectly. IGMP join should be sent and marked as joined only on RoCEv2 after a successful join. Max hops should be updated to the hop limit on RoCEv2 regardless of the join state. Fixes: bee3c3c91865 ('IB/cma: Join and leave multicast groups...') Signed-off-by: Alex Vesker Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/cma.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit f336ae03149725bb5844166c7b04f7f65f17eec9 Author: Talat Batheesh Date: Wed Jun 22 17:27:22 2016 +0300 IB/core: Fix no default GIDs when netdevice reregisters Currently, when the netdevice returned by get_netdev is unregistered, we delete all GIDs (including the default GIDs) and reset their attributes. Therefore, when we re-register it, no default GIDs will be assigned (as their "default GID") attribute will be reset. Fixing this by keeping "default GID" attribute. Fixes: 03db3a2d81e6 ('IB/core: Add RoCE GID table management') Signed-off-by: Talat Batheesh Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/cache.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit d6b186c1e2d852a92c43f090d0d8fad4704d51ef Author: David Vrabel Date: Tue May 17 15:54:50 2016 +0100 x86/xen: avoid m2p lookup when setting early page table entries When page tables entries are set using xen_set_pte_init() during early boot there is no page fault handler that could handle a fault when performing an M2P lookup. In 64 bit guests (usually dom0) early_ioremap() would fault in xen_set_pte_init() because an M2P lookup faults because the MFN is in MMIO space and not mapped in the M2P. This lookup is done to see if the PFN in in the range used for the initial page table pages, so that the PTE may be set as read-only. The M2P lookup can be avoided by moving the check (and clear of RW) earlier when the PFN is still available. Reported-by: Kevin Moraga Signed-off-by: David Vrabel Reviewed-by: Boris Ostrovsky Reviewed-by: Juergen Gross arch/x86/xen/mmu.c | 72 +++++++++++++++++++++++------------------------------- 1 file changed, 31 insertions(+), 41 deletions(-) commit 5ce91714b0d8c0a3ff9b858966721f508351cf4c Author: Pali Rohár Date: Sat Jun 18 00:54:47 2016 +0200 hwmon: (dell-smm) Cache fan_type() calls and change fan detection On more Dell machines (e.g. Dell Precision M3800) fan_type() call is too expensive (CPU is too long in SMM mode) and cause kernel to hang. This is bug in Dell SMM or BIOS. This patch caches type for each fan (as it should not change) and changes the way how fan presense is detected. First it try function fan_status() as was before commit f989e55452c7 ("i8k: Add support for fan labels"). And if that fails fallback to fan_type(). *_status() functions can fail in case fan is not currently accessible (e.g. present on GPU which is currently turned off). Reported-by: Tolga Cakir Signed-off-by: Pali Rohár Link: https://bugzilla.kernel.org/show_bug.cgi?id=112021 Cc: stable@vger.kernel.org # v4.0+, will need backport Tested-by: Tolga Cakir Signed-off-by: Guenter Roeck drivers/hwmon/dell-smm-hwmon.c | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) commit 492a19ef8bbfe03b03ca82635555ea1e2803ff91 Merge: 33688ab 8d39fc0 Author: Rafael J. Wysocki Date: Thu Jun 23 14:48:41 2016 +0200 Merge branch 'fixes' of https://git.kernel.org/pub/scm/linux/kernel/git/mzx/devfreq into pm-devfreq Pull devfreq fixes for v4.7 from MyungJoo Ham. * 'fixes' of https://git.kernel.org/pub/scm/linux/kernel/git/mzx/devfreq: PM / devfreq: fix initialization of current frequency in last status PM / devfreq: exynos-nocp: Remove incorrect IS_ERR() check PM / devfreq: remove double put_device PM / devfreq: fix double call put_device PM / devfreq: fix duplicated kfree on devfreq pointer PM / devfreq: devm_kzalloc to have dev pointer more precisely commit 62131e5d735226074cba53095545d76b491e5003 Author: Liping Zhang Date: Wed Jun 8 20:20:10 2016 +0800 netfilter: nft_meta: set skb->nf_trace appropriately When user add a nft rule to set nftrace to zero, for example: # nft add rule ip filter input nftrace set 0 We should set nf_trace to zero also. Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso net/netfilter/nft_meta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6cafaf4764a32597c2195aa5411b87728e1fde8a Author: Liping Zhang Date: Mon Jun 20 21:11:45 2016 +0800 netfilter: nf_tables: fix memory leak if expr init fails If expr init fails then we need to free it. So when the user add a nft rule as follows: # nft add rule filter input tcp dport 22 flow table ssh \ { ip saddr limit rate 0/second } memory leak will happen. Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_tables_api.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 02ef871ecac290919ea0c783d05da7eedeffc10e Author: Andrey Grodzovsky Date: Tue Jun 21 14:26:36 2016 -0400 xen/pciback: Fix conf_space read/write overlap check. Current overlap check is evaluating to false a case where a filter field is fully contained (proper subset) of a r/w request. This change applies classical overlap check instead to include all the scenarios. More specifically, for (Hilscher GmbH CIFX 50E-DP(M/S)) device driver the logic is such that the entire confspace is read and written in 4 byte chunks. In this case as an example, CACHE_LINE_SIZE, LATENCY_TIMER and PCI_BIST are arriving together in one call to xen_pcibk_config_write() with offset == 0xc and size == 4. With the exsisting overlap check the LATENCY_TIMER field (offset == 0xd, length == 1) is fully contained in the write request and hence is excluded from write, which is incorrect. Signed-off-by: Andrey Grodzovsky Reviewed-by: Boris Ostrovsky Reviewed-by: Jan Beulich Cc: Signed-off-by: David Vrabel drivers/xen/xen-pciback/conf_space.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 1cf38741308c64d08553602b3374fb39224eeb5a Author: Juergen Gross Date: Thu Jun 23 07:12:27 2016 +0200 x86/xen: fix upper bound of pmd loop in xen_cleanhighmap() xen_cleanhighmap() is operating on level2_kernel_pgt only. The upper bound of the loop setting non-kernel-image entries to zero should not exceed the size of level2_kernel_pgt. Reported-by: Linus Torvalds Signed-off-by: Juergen Gross Signed-off-by: David Vrabel arch/x86/xen/mmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 842775f1509054ea969f1787f38d6a0ec2ccfaba Author: Ross Lagerwall Date: Tue May 10 10:27:54 2016 +0100 xen/balloon: Fix declared-but-not-defined warning Fix a declared-but-not-defined warning when building with XEN_BALLOON_MEMORY_HOTPLUG=n. This fixes a regression introduced by commit dfd74a1edfab ("xen/balloon: Fix crash when ballooning on x86 32 bit PAE"). Signed-off-by: Ross Lagerwall Acked-by: Juergen Gross Signed-off-by: David Vrabel drivers/xen/balloon.c | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) commit 055ddaace03580455a7b7dbea8e93d62acee61fc Author: Mathias Krause Date: Wed Jun 22 20:29:37 2016 +0200 crypto: user - re-add size check for CRYPTO_MSG_GETALG Commit 9aa867e46565 ("crypto: user - Add CRYPTO_MSG_DELRNG") accidentally removed the minimum size check for CRYPTO_MSG_GETALG netlink messages. This allows userland to send a truncated CRYPTO_MSG_GETALG message as short as a netlink header only making crypto_report() operate on uninitialized memory by accessing data beyond the end of the netlink message. Fix this be re-adding the minimum required size of CRYPTO_MSG_GETALG messages to the crypto_msg_min[] array. Fixes: 9aa867e46565 ("crypto: user - Add CRYPTO_MSG_DELRNG") Cc: stable@vger.kernel.org # v4.2 Signed-off-by: Mathias Krause Cc: Steffen Klassert Signed-off-by: Herbert Xu crypto/crypto_user.c | 1 + 1 file changed, 1 insertion(+) commit 71873a9b38d1cc6c93e2962149a7bb7272a7cb66 Author: Jimmy Assarsson Date: Thu Jun 23 07:57:21 2016 +0200 can: kvaser_usb: Add support for more Kvaser Leaf v2 devices This patch adds support for Kvaser Leaf Light HS v2 OEM, Mini PCI Express 2xHS and USBcan Light 2xHS. Signed-off-by: Jimmy Assarsson Signed-off-by: Marc Kleine-Budde drivers/net/can/usb/Kconfig | 2 ++ drivers/net/can/usb/kvaser_usb.c | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) commit b41aa4f8476545e2b663b1549759a8c3a66f47b0 Author: Cristina Ciocan Date: Wed Jun 22 14:17:19 2016 +0300 pinctrl: baytrail: Fix mingled clock pins Fix plt clock 3, 4 and 5 pins, which were not in the proper order. Signed-off-by: Cristina Ciocan Acked-by: Mika Westerberg Signed-off-by: Linus Walleij drivers/pinctrl/intel/pinctrl-baytrail.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 25e1ed6e64f52a692ba3191c4fde650aab3ecc07 Author: Oliver Hartkopp Date: Tue Jun 21 15:45:47 2016 +0200 can: fix oops caused by wrong rtnl dellink usage For 'real' hardware CAN devices the netlink interface is used to set CAN specific communication parameters. Real CAN hardware can not be created nor removed with the ip tool ... This patch adds a private dellink function for the CAN device driver interface that does just nothing. It's a follow up to commit 993e6f2fd ("can: fix oops caused by wrong rtnl newlink usage") but for dellink. Reported-by: ajneu Signed-off-by: Oliver Hartkopp Cc: Signed-off-by: Marc Kleine-Budde drivers/net/can/dev.c | 6 ++++++ 1 file changed, 6 insertions(+) commit bce271f255dae8335dc4d2ee2c4531e09cc67f5a Author: Oliver Hartkopp Date: Tue Jun 21 12:14:07 2016 +0200 can: fix handling of unmodifiable configuration options fix With upstream commit bb208f144cf3f59 (can: fix handling of unmodifiable configuration options) a new can_validate() function was introduced. When invoking 'ip link set can0 type can' without any configuration data can_validate() tries to validate the content without taking into account that there's totally no content. This patch adds a check for missing content. Reported-by: ajneu Signed-off-by: Oliver Hartkopp Cc: Signed-off-by: Marc Kleine-Budde drivers/net/can/dev.c | 3 +++ 1 file changed, 3 insertions(+) commit fefb62455f6becc87d2d8f25ba2df961add5d06c Author: Andy Shevchenko Date: Tue Jun 21 01:52:36 2016 +0300 MAINTAINERS: belong Documentation/pinctrl.txt properly I'm pretty sure that Documentation/pinctrl.txt would be better maintained by pinctrl subsystem. Signed-off-by: Andy Shevchenko Signed-off-by: Linus Walleij MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit c6887cd11149d7325328749f06719071e6c725c6 Author: Josef Bacik Date: Fri Mar 25 13:26:00 2016 -0400 Btrfs: don't do nocow check unless we have to Before we write into prealloc/nocow space we have to make sure that there are no references to the extents we are writing into, which means checking the extent tree and csum tree in the case of nocow. So we don't want to do the nocow dance unless we can't reserve data space, since it's a serious drag on performance. With the following sequence fallocate -l10737418240 /mnt/btrfs-test/file cp --reflink /mnt/btrfs-test/file /mnt/btrfs-test/link fio --name=randwrite --rw=randwrite --bs=4k --filename=/mnt/btrfs-test/file \ --end_fsync=1 we get the worst case scenario where we have to fall back on to doing the check anyway. Without this patch lat (usec): min=5, max=111598, avg=27.65, stdev=124.51 write: io=10240MB, bw=126876KB/s, iops=31718, runt= 82646msec With this patch lat (usec): min=3, max=91210, avg=14.09, stdev=110.62 write: io=10240MB, bw=212753KB/s, iops=53188, runt= 49286msec We get twice the throughput, half of the runtime, and half of the average latency. Thanks, Signed-off-by: Josef Bacik [ PAGE_CACHE_ removal related fixups ] Signed-off-by: David Sterba Signed-off-by: Chris Mason fs/btrfs/file.c | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) commit 0f873eca82a0bee45f38862e0ea2ac7b1c2a31bd Author: Chris Mason Date: Wed Apr 27 09:59:38 2016 -0400 btrfs: fix deadlock in delayed_ref_async_start "Btrfs: track transid for delayed ref flushing" was deadlocking on btrfs_attach_transaction because its not safe to call from the async delayed ref start code. This commit brings back btrfs_join_transaction instead and checks for a blocked commit. Signed-off-by: Josef Bacik Signed-off-by: Chris Mason fs/btrfs/extent-tree.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit 31b9655f439a26856edca0f3f8daa368a61f16d5 Author: Josef Bacik Date: Mon Apr 11 17:37:40 2016 -0400 Btrfs: track transid for delayed ref flushing Using the offwakecputime bpf script I noticed most of our time was spent waiting on the delayed ref throttling. This is what is supposed to happen, but sometimes the transaction can commit and then we're waiting for throttling that doesn't matter anymore. So change this stuff to be a little smarter by tracking the transid we were in when we initiated the throttling. If the transaction we get is different then we can just bail out. This resulted in a 50% speedup in my fs_mark test, and reduced the amount of time spent throttling by 60 seconds over the entire run (which is about 30 minutes). Thanks, Signed-off-by: Josef Bacik Signed-off-by: Chris Mason fs/btrfs/ctree.h | 2 +- fs/btrfs/extent-tree.c | 15 ++++++++++++--- fs/btrfs/inode.c | 1 + fs/btrfs/transaction.c | 3 ++- 4 files changed, 16 insertions(+), 5 deletions(-) commit 844e3be47693f92a108cb1fb3b0606bf25e9c7a6 Author: Naveen N. Rao Date: Wed Jun 22 21:55:01 2016 +0530 powerpc/bpf/jit: Disable classic BPF JIT on ppc64le Classic BPF JIT was never ported completely to work on little endian powerpc. However, it can be enabled and will crash the system when used. As such, disable use of BPF JIT on ppc64le. Fixes: 7c105b63bd98 ("powerpc: Add CONFIG_CPU_LITTLE_ENDIAN kernel config option.") Reported-by: Thadeu Lima de Souza Cascardo Signed-off-by: Naveen N. Rao Acked-by: Thadeu Lima de Souza Cascardo Signed-off-by: Michael Ellerman arch/powerpc/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6e914ee629c411d9c6d160399ce7d3472d2c0ec7 Author: Michael Ellerman Date: Mon Jun 20 19:23:43 2016 +1000 powerpc: Fix faults caused by radix patching of SLB miss handler As part of the Radix MMU support we added some feature sections in the SLB miss handler. These are intended to catch the case that we incorrectly take an SLB miss when Radix is enabled, and instead of crashing weirdly they bail out to a well defined exit path and trigger an oops. However the way they were written meant the bailout case was enabled by default until we did CPU feature patching. On powermacs the early debug prints in setup_system() can cause an SLB miss, which happens before code patching, and so the SLB miss handler would incorrectly bailout and crash during boot. Fix it by inverting the sense of the feature section, so that the code which is in place at boot is correct for the hash case. Once we determine we are using Radix - which will never happen on a powermac - only then do we patch in the bailout case which unconditionally jumps. Fixes: caca285e5ab4 ("powerpc/mm/radix: Use STD_MMU_64 to properly isolate hash related code") Reported-by: Denis Kirjanov Tested-by: Denis Kirjanov Reviewed-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/kernel/exceptions-64s.S | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 4ac1c17b2044a1b4b2fbed74451947e905fc2992 Author: Kirill A. Shutemov Date: Thu Jun 16 23:26:15 2016 +0200 UBIFS: Implement ->migratepage() During page migrations UBIFS might get confused and the following assert triggers: [ 213.480000] UBIFS assert failed in ubifs_set_page_dirty at 1451 (pid 436) [ 213.490000] CPU: 0 PID: 436 Comm: drm-stress-test Not tainted 4.4.4-00176-geaa802524636-dirty #1008 [ 213.490000] Hardware name: Allwinner sun4i/sun5i Families [ 213.490000] [] (unwind_backtrace) from [] (show_stack+0x10/0x14) [ 213.490000] [] (show_stack) from [] (dump_stack+0x8c/0xa0) [ 213.490000] [] (dump_stack) from [] (ubifs_set_page_dirty+0x44/0x50) [ 213.490000] [] (ubifs_set_page_dirty) from [] (try_to_unmap_one+0x10c/0x3a8) [ 213.490000] [] (try_to_unmap_one) from [] (rmap_walk+0xb4/0x290) [ 213.490000] [] (rmap_walk) from [] (try_to_unmap+0x64/0x80) [ 213.490000] [] (try_to_unmap) from [] (migrate_pages+0x328/0x7a0) [ 213.490000] [] (migrate_pages) from [] (alloc_contig_range+0x168/0x2f4) [ 213.490000] [] (alloc_contig_range) from [] (cma_alloc+0x170/0x2c0) [ 213.490000] [] (cma_alloc) from [] (__alloc_from_contiguous+0x38/0xd8) [ 213.490000] [] (__alloc_from_contiguous) from [] (__dma_alloc+0x23c/0x274) [ 213.490000] [] (__dma_alloc) from [] (arm_dma_alloc+0x54/0x5c) [ 213.490000] [] (arm_dma_alloc) from [] (drm_gem_cma_create+0xb8/0xf0) [ 213.490000] [] (drm_gem_cma_create) from [] (drm_gem_cma_create_with_handle+0x1c/0xe8) [ 213.490000] [] (drm_gem_cma_create_with_handle) from [] (drm_gem_cma_dumb_create+0x3c/0x48) [ 213.490000] [] (drm_gem_cma_dumb_create) from [] (drm_ioctl+0x12c/0x444) [ 213.490000] [] (drm_ioctl) from [] (do_vfs_ioctl+0x3f4/0x614) [ 213.490000] [] (do_vfs_ioctl) from [] (SyS_ioctl+0x34/0x5c) [ 213.490000] [] (SyS_ioctl) from [] (ret_fast_syscall+0x0/0x34) UBIFS is using PagePrivate() which can have different meanings across filesystems. Therefore the generic page migration code cannot handle this case correctly. We have to implement our own migration function which basically does a plain copy but also duplicates the page private flag. UBIFS is not a block device filesystem and cannot use buffer_migrate_page(). Cc: stable@vger.kernel.org Signed-off-by: Kirill A. Shutemov [rw: Massaged changelog, build fixes, etc...] Signed-off-by: Richard Weinberger Acked-by: Christoph Hellwig fs/ubifs/file.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 1118dce773d84f39ebd51a9fe7261f9169cb056e Author: Richard Weinberger Date: Thu Jun 16 23:26:14 2016 +0200 mm: Export migrate_page_move_mapping and migrate_page_copy Export these symbols such that UBIFS can implement ->migratepage. Cc: stable@vger.kernel.org Signed-off-by: Richard Weinberger Acked-by: Christoph Hellwig mm/migrate.c | 2 ++ 1 file changed, 2 insertions(+) commit 972228d87445dc46c0a01f5f3de673ac017626f7 Author: Richard Weinberger Date: Tue Jun 21 00:31:50 2016 +0200 ubi: Make recover_peb power cut aware recover_peb() was never power cut aware, if a power cut happened right after writing the VID header upon next attach UBI would blindly use the new partial written PEB and all data from the old PEB is lost. In order to make recover_peb() power cut aware, write the new VID with a proper crc and copy_flag set such that the UBI attach process will detect whether the new PEB is completely written or not. We cannot directly use ubi_eba_atomic_leb_change() since we'd have to unlock the LEB which is facing a write error. Cc: stable@vger.kernel.org Reported-by: Jörg Pfähler Reviewed-by: Jörg Pfähler Signed-off-by: Richard Weinberger drivers/mtd/ubi/eba.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit c0a1ecb9f4e208f4b75d88fa9669748e3fd705ab Author: Linus Walleij Date: Thu Jun 16 11:55:55 2016 +0200 gpio: make library immune to error pointers Most functions that take a GPIO descriptor in need to check the descriptor for IS_ERR(). We do this mostly in the VALIDATE_DESC() macro except for the gpiod_to_irq() function which needs special handling. Cc: stable@vger.kernel.org Reported-by: Grygorii Strashko Reviewed-by: Grygorii Strashko Acked-by: Alexandre Courbot Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 39243ee771666e02201ba89c1d76fdc28e9cf681 Author: Linus Walleij Date: Wed Jun 15 22:57:38 2016 +0200 gpio: make sure gpiod_to_irq() returns negative on NULL desc commit 54d77198fdfbc4f0fe11b4252c1d9c97d51a3264 ("gpio: bail out silently on NULL descriptors") doesn't work for gpiod_to_irq(): drivers assume that NULL descriptors will give negative IRQ numbers in return. It has been pointed out that returning 0 is NO_IRQ and that drivers should be amended to treat this as an error, but that is for the longer term: now let us repair the semantics. Cc: Maxime Ripard Reported-by: Hans de Goede Tested-by: Hans de Goede Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 0b305ccc1b545d3389068ddc3548cbc877513b97 Author: Axel Lin Date: Mon Jun 13 13:48:53 2016 +0800 gpio: 104-idi-48: Fix missing spin_lock_init for ack_lock Fixes: 9ae482104cb9 ("gpio: 104-idi-48: Clear pending interrupt once in IRQ handler") Signed-off-by: Axel Lin Acked-by: William Breathitt Gray Signed-off-by: Linus Walleij drivers/gpio/gpio-104-idi-48.c | 1 + 1 file changed, 1 insertion(+) commit f9020d17416ae62f1b1c6459d61e65abb4af79b5 Merge: 144b5ae 695e9df Author: Linus Torvalds Date: Wed Jun 22 14:11:24 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace Pull userns fix from Eric Biederman: "This contains just a single small patch that fixes a tiny hole in the logic of allowing unprivileged mounting of proc and sysfs. In practice I don't think anyone is affected because having MNT_RDONLY clear in mnt->mnt_flags but MS_RDONLY set in sb->s_flags is very weird for a filesystem, and weirder for proc and sysfs. However if it happens let's handle it correctly and then no one has to to worry about this crazy case" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: mnt: Account for MS_RDONLY in fs_fully_visible commit acd43fe85b2d1dbad55ce211b8817e6d6687246f Merge: 27777da 9d76931 Author: David S. Miller Date: Wed Jun 22 16:38:17 2016 -0400 Merge branch 'mlx4-fixes' Tariq Toukan says: ==================== mlx4_en fixes for 4.7-rc This small patchset includes two small fixes for mlx4_en driver. One allows a clean shutdown even when clients do not release their netdev reference. The other adds error return values to the VLAN VID add/kill functions. ==================== Signed-off-by: David S. Miller commit 9d76931180557270796f9631e2c79b9c7bb3c9fb Author: Eran Ben Elisha Date: Tue Jun 21 14:20:03 2016 +0300 net/mlx4_en: Avoid unregister_netdev at shutdown flow This allows a clean shutdown, even if some netdev clients do not release their reference from this netdev. It is enough to release the HW resources only as the kernel is shutting down. Fixes: 2ba5fbd62b25 ('net/mlx4_core: Handle AER flow properly') Signed-off-by: Eran Ben Elisha Signed-off-by: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 17 +++++++++++++++-- drivers/net/ethernet/mellanox/mlx4/main.c | 5 ++++- include/linux/mlx4/device.h | 1 + 3 files changed, 20 insertions(+), 3 deletions(-) commit 93c098af09455ea7bdc6f0f6b08f6ac14fa06cf4 Author: Kamal Heib Date: Tue Jun 21 14:20:02 2016 +0300 net/mlx4_en: Fix the return value of a failure in VLAN VID add/kill Modify mlx4_en_vlan_rx_[add/kill]_vid to return error value in case of failure. Fixes: 8e586137e6b6 ('net: make vlan ndo_vlan_rx_[add/kill]_vid return error value') Signed-off-by: Kamal Heib Signed-off-by: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) commit 27777daa8b6df0c19aaf591d1536a586b3eb5e36 Author: Jon Paul Maloy Date: Mon Jun 20 09:20:46 2016 -0400 tipc: unclone unbundled buffers before forwarding When extracting an individual message from a received "bundle" buffer, we just create a clone of the base buffer, and adjust it to point into the right position of the linearized data area of the latter. This works well for regular message reception, but during periods of extremely high load it may happen that an extracted buffer, e.g, a connection probe, is reversed and forwarded through an external interface while the preceding extracted message is still unhandled. When this happens, the header or data area of the preceding message will be partially overwritten by a MAC header, leading to unpredicatable consequences, such as a link reset. We now fix this by ensuring that the msg_reverse() function never returns a cloned buffer, and that the returned buffer always contains sufficient valid head and tail room to be forwarded. Reported-by: Erik Hugne Acked-by: Ying Xue Signed-off-by: Jon Maloy Signed-off-by: David S. Miller net/tipc/msg.c | 6 ++++++ net/tipc/msg.h | 11 ----------- 2 files changed, 6 insertions(+), 11 deletions(-) commit d19af0a76444fde629667ecb823c0ee28f9f67d8 Author: Jiri Slaby Date: Mon Jun 20 11:36:28 2016 +0200 kcm: fix /proc memory leak Every open of /proc/net/kcm leaks 16 bytes of memory as is reported by kmemleak: unreferenced object 0xffff88059c0e3458 (size 192): comm "cat", pid 1401, jiffies 4294935742 (age 310.720s) hex dump (first 32 bytes): 28 45 71 96 05 88 ff ff 00 10 00 00 00 00 00 00 (Eq............. 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ backtrace: [] kmem_cache_alloc_trace+0x16e/0x230 [] seq_open+0x79/0x1d0 [] kcm_seq_open+0x0/0x30 [kcm] [] seq_open+0x79/0x1d0 [] __seq_open_private+0x2f/0xa0 [] seq_open_net+0x38/0xa0 ... It is caused by a missing free in the ->release path. So fix it by providing seq_release_net as the ->release method. Signed-off-by: Jiri Slaby Fixes: cd6e111bf5 (kcm: Add statistics and proc interfaces) Cc: "David S. Miller" Cc: Tom Herbert Cc: netdev@vger.kernel.org Signed-off-by: David S. Miller net/kcm/kcmproc.c | 1 + 1 file changed, 1 insertion(+) commit 942f64c4c2be19a1b4a0c4295182b42d153899bf Author: Ido Schimmel Date: Mon Jun 20 11:53:20 2016 +0300 team: Fix possible deadlock during team enslave Both dev_uc_sync_multiple() and dev_mc_sync_multiple() require the source device to be locked by netif_addr_lock_bh(), but this is missing in team's enslave function, so add it. This fixes the following lockdep warning: Possible interrupt unsafe locking scenario: CPU0 CPU1 ---- ---- lock(_xmit_ETHER/1); local_irq_disable(); lock(&(&mc->mca_lock)->rlock); lock(&team_netdev_addr_lock_key); lock(&(&mc->mca_lock)->rlock); *** DEADLOCK *** Fixes: cb41c997d444 ("team: team should sync the port's uc/mc addrs when add a port") Signed-off-by: Jiri Pirko Signed-off-by: Ido Schimmel Signed-off-by: David S. Miller drivers/net/team/team.c | 2 ++ 1 file changed, 2 insertions(+) commit 6b65ca06e1af38ea90074a47fcb5748ee9309b94 Merge: ab522fd f155d9c Author: David S. Miller Date: Wed Jun 22 16:29:17 2016 -0400 Merge tag 'linux-can-fixes-for-4.7-20160620' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can Marc Kleine-Budde says: ==================== pull-request: can 2016-06-20 this is a pull request of 3 patches for the upcoming linux-4.7 release. The first patch is by Thor Thayer for the c_can/d_can driver. It fixes the registar access on Altera Cyclone devices, which caused CAN frames to have 0x0 in the first two bytes incorrectly. Wolfgang Grandegger's patch for the at91 driver fixes a hanging driver under high bus load situations. A patch for the gs_usb driver by Maximilian Schneider adds support for the bytewerk.org candleLight interface. ==================== Signed-off-by: David S. Miller commit 144b5ae3e343f193a6a7edef8f30aab4fad2d12b Merge: 67016f6 bfbbe44 Author: Linus Torvalds Date: Wed Jun 22 10:13:25 2016 -0700 Merge tag 'gpio-v4.7-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fixes from Linus Walleij: "More GPIO fixes. Most prominent the gpiod_to_irq() fix brought to my attention by Hans de Goede. The hardening patch is a consequence of the reasoning around that bug. - It was discovered that too many parts of the kernel does not respect gpiod_to_irq() returning zero for an invalid IRQ. While this gets fixed, we need to make it return negative errorcodes again. - Harden the library a bit when passed error pointers. It is a bug to use these, but let's be helpful and warn the users. - Fix an uninitialized spinlock in the 104-idi-48 driver" * tag 'gpio-v4.7-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: gpio: make library immune to error pointers gpio: make sure gpiod_to_irq() returns negative on NULL desc gpio: 104-idi-48: Fix missing spin_lock_init for ack_lock commit df013212a1b6557f071609983cab0612f71fd99b Merge: 33688ab f4070a1 Author: Greg Kroah-Hartman Date: Wed Jun 22 09:57:28 2016 -0700 Merge tag 'iio-fixes-for-4.7b' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus Jonathan writes: Second set of IIO fixes for the 4.7 cycle. This includes one tracked regression (Arnd's patch for the ad7606). The other two have I think always been broken. * inv_mpu6050 - Fix a use after free in the ACPI code. * ad5933 - The code for setting the cycles had a bug that meant it was simply wrong. * ad7606_spi - Fix a regression that got introduced in a buggy cleanup of a sparse warning. commit 19b5a91764fddcc51b2f8e54a81d4ef231980181 Author: Axel Lin Date: Sat Jun 4 14:35:56 2016 +0800 pinctrl: tegra: Fix build dependency I got below build error: ERROR: "tegra_xusb_padctl_legacy_probe" [drivers/phy/tegra/phy-tegra-xusb.ko] undefined! with below build configuration: CONFIG_ARCH_TEGRA=y CONFIG_PINCTRL_TEGRA_XUSB=y CONFIG_PHY_TEGRA_XUSB=y The problem is below line in drivers/pinctrl/Makefile obj-$(CONFIG_PINCTRL_TEGRA) += tegra/ So even CONFIG_PINCTRL_TEGRA_XUSB=y is set, kbuild still does not compile the code in drivers/pinctrl/tegra folder if !CONFIG_PINCTRL_TEGRA. phy-tegra-xusb.c does not use any symbol from pinctrl-tegra.c, so build pinctrl-tegra.c only when CONFIG_PINCTRL_TEGRA is set. Signed-off-by: Axel Lin Acked-by: Jon Hunter Signed-off-by: Linus Walleij drivers/pinctrl/Makefile | 2 +- drivers/pinctrl/tegra/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 9ee8ff4867d07a6429991a0b748fa9c1586a7764 Author: Thierry Reding Date: Mon Jun 6 18:56:27 2016 +0200 gpio: tegra: Make lockdep class file-scoped Commit b546be0db955 ("gpio: tegra: Get rid of all file scoped global variables") moved all file scoped variables into the driver-private structure to allow potentially multiple instances of the driver. The change also included turning the lockdep class into a driver-private field, which doesn't work and produces error messages such as this: [ 0.142310] BUG: key ffff8000fb3f7ab0 not in .data! Make the lockdep class file-scoped again to fix this issue. Signed-off-by: Thierry Reding Signed-off-by: Linus Walleij drivers/gpio/gpio-tegra.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 0ac3c0a4025f41748a083bdd4970cb3ede802b15 Author: Tony Lindgren Date: Tue May 31 14:17:06 2016 -0700 pinctrl: single: Fix missing flush of posted write for a wakeirq With many repeated suspend resume cycles, the pin specific wakeirq may not always work on omaps. This is because the write to enable the pin interrupt may not have reached the device over the interconnect before suspend happens. Let's fix the issue with a flush of posted write with a readback. Cc: stable@vger.kernel.org Reported-by: Nishanth Menon Signed-off-by: Tony Lindgren Signed-off-by: Linus Walleij drivers/pinctrl/pinctrl-single.c | 3 +++ 1 file changed, 3 insertions(+) commit ba562d5e54fd3136bfea0457add3675850247774 Author: Alexander Shiyan Date: Wed Jun 1 22:21:53 2016 +0300 pinctrl: imx: Do not treat a PIN without MUX register as an error Some PINs do not have a MUX register, it is not an error. It is necessary to allow the continuation of the PINs configuration, otherwise the whole PIN-group will be configured incorrectly. Cc: stable@vger.kernel.org Signed-off-by: Alexander Shiyan Signed-off-by: Linus Walleij drivers/pinctrl/freescale/pinctrl-imx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d74b4e4f1a6dbe27acce723e071c86a6ed154bf2 Author: James Morse Date: Wed Jun 22 10:06:13 2016 +0100 arm64: hibernate: Don't hibernate on systems with stuck CPUs Hibernate relies on cpu hotplug to prevent secondary cores executing the kernel text while it is being restored. Add a call to cpus_are_stuck_in_kernel() to determine if there are CPUs not counted by 'num_online_cpus()', and prevent hibernate in this case. Fixes: 82869ac57b5 ("arm64: kernel: Add support for hibernate/suspend-to-disk") Acked-by: Mark Rutland Signed-off-by: James Morse Signed-off-by: Will Deacon arch/arm64/kernel/hibernate.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 5c492c3f5255bd34f7ff8867515ecf98dcba2a2e Author: James Morse Date: Wed Jun 22 10:06:12 2016 +0100 arm64: smp: Add function to determine if cpus are stuck in the kernel kernel/smp.c has a fancy counter that keeps track of the number of CPUs it marked as not-present and left in cpu_park_loop(). If there are any CPUs spinning in here, features like kexec or hibernate may release them by overwriting this memory. This problem also occurs on machines using spin-tables to release secondary cores. After commit 44dbcc93ab67 ("arm64: Fix behavior of maxcpus=N") we bring all known cpus into the secondary holding pen, meaning this memory can't be re-used by kexec or hibernate. Add a function cpus_are_stuck_in_kernel() to determine if either of these cases have occurred. Signed-off-by: James Morse Acked-by: Mark Rutland Reviewed-by: Suzuki K Poulose Signed-off-by: Will Deacon arch/arm64/include/asm/smp.h | 12 ++++++++++++ arch/arm64/kernel/smp.c | 18 ++++++++++++++++++ 2 files changed, 30 insertions(+) commit c9058d43d99404986133112393be1d1a4daf1b69 Author: Ben Dooks Date: Tue Jun 21 19:18:32 2016 +0100 ALSA: hda/tegra: iomem fixups for sparse warnings The readl/writel are not being passed __iomem annotated variables, so fix the following sparse warnings by adding __iomem in: sound/pci/hda/hda_tegra.c:120:9: warning: incorrect type in argument 2 (different address spaces) sound/pci/hda/hda_tegra.c:120:9: expected void volatile [noderef] *addr sound/pci/hda/hda_tegra.c:120:9: got unsigned int [usertype] *addr sound/pci/hda/hda_tegra.c:125:16: warning: incorrect type in argument 1 (different address spaces) sound/pci/hda/hda_tegra.c:125:16: expected void const volatile [noderef] *addr sound/pci/hda/hda_tegra.c:125:16: got unsigned int [usertype] *addr sound/pci/hda/hda_tegra.c:134:13: warning: incorrect type in argument 1 (different address spaces) sound/pci/hda/hda_tegra.c:134:13: expected void const volatile [noderef] *addr sound/pci/hda/hda_tegra.c:134:13: got void *dword_addr sound/pci/hda/hda_tegra.c:137:9: warning: incorrect type in argument 2 (different address spaces) sound/pci/hda/hda_tegra.c:137:9: expected void volatile [noderef] *addr sound/pci/hda/hda_tegra.c:137:9: got void *dword_addr sound/pci/hda/hda_tegra.c:146:13: warning: incorrect type in argument 1 (different address spaces) sound/pci/hda/hda_tegra.c:146:13: expected void const volatile [noderef] *addr sound/pci/hda/hda_tegra.c:146:13: got void *dword_addr sound/pci/hda/hda_tegra.c:156:13: warning: incorrect type in argument 1 (different address spaces) sound/pci/hda/hda_tegra.c:156:13: expected void const volatile [noderef] *addr sound/pci/hda/hda_tegra.c:156:13: got void *dword_addr sound/pci/hda/hda_tegra.c:159:9: warning: incorrect type in argument 2 (different address spaces) sound/pci/hda/hda_tegra.c:159:9: expected void volatile [noderef] *addr sound/pci/hda/hda_tegra.c:159:9: got void *dword_addr sound/pci/hda/hda_tegra.c:168:13: warning: incorrect type in argument 1 (different address spaces) sound/pci/hda/hda_tegra.c:168:13: expected void const volatile [noderef] *addr sound/pci/hda/hda_tegra.c:168:13: got void *dword_addr sound/pci/hda/hda_tegra.c:173:23: warning: incorrect type in initializer (incompatible argument 2 (different address spaces)) sound/pci/hda/hda_tegra.c:173:23: expected void ( *reg_writel )( ... ) sound/pci/hda/hda_tegra.c:173:23: got void ( static [toplevel] * )( ... ) sound/pci/hda/hda_tegra.c:174:22: warning: incorrect type in initializer (incompatible argument 1 (different address spaces)) sound/pci/hda/hda_tegra.c:174:22: expected unsigned int ( *reg_readl )( ... ) sound/pci/hda/hda_tegra.c:174:22: got unsigned int ( static [toplevel] * )( ... ) sound/pci/hda/hda_tegra.c:175:23: warning: incorrect type in initializer (incompatible argument 2 (different address spaces)) sound/pci/hda/hda_tegra.c:175:23: expected void ( *reg_writew )( ... ) sound/pci/hda/hda_tegra.c:175:23: got void ( static [toplevel] * )( ... ) sound/pci/hda/hda_tegra.c:176:22: warning: incorrect type in initializer (incompatible argument 1 (different address spaces)) sound/pci/hda/hda_tegra.c:176:22: expected unsigned short ( *reg_readw )( ... ) sound/pci/hda/hda_tegra.c:176:22: got unsigned short ( static [toplevel] * )( ... ) sound/pci/hda/hda_tegra.c:177:23: warning: incorrect type in initializer (incompatible argument 2 (different address spaces)) sound/pci/hda/hda_tegra.c:177:23: expected void ( *reg_writeb )( ... ) sound/pci/hda/hda_tegra.c:177:23: got void ( static [toplevel] * )( ... ) sound/pci/hda/hda_tegra.c:178:22: warning: incorrect type in initializer (incompatible argument 1 (different address spaces)) sound/pci/hda/hda_tegra.c:178:22: expected unsigned char ( *reg_readb )( ... ) sound/pci/hda/hda_tegra.c:178:22: got unsigned char ( static [toplevel] * )( ... ) Signed-off-by: Ben Dooks Acked-by: Thierry Reding Signed-off-by: Takashi Iwai sound/pci/hda/hda_tegra.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit b3b630b26ae87a54e2f396b459aab0cd2286fc77 Author: Hans de Goede Date: Mon Jun 20 22:57:22 2016 +0200 ARM: dts: sunxi: Add pll3 to simplefb nodes clocks lists Now that we've a clock node describing pll3 we must add it to the simplefb nodes clocks lists to avoid it getting turned off when simplefb is used. This fixes the screen going black when using simplefb. Signed-off-by: Hans de Goede Signed-off-by: Maxime Ripard arch/arm/boot/dts/sun4i-a10.dtsi | 21 ++++++++++++--------- arch/arm/boot/dts/sun5i-a10s.dtsi | 11 ++++++----- arch/arm/boot/dts/sun7i-a20.dtsi | 11 ++++++----- 3 files changed, 24 insertions(+), 19 deletions(-) commit 04e59a0211ff012ba60c00baca673482570784e9 Author: Hans de Goede Date: Sat Jun 18 11:31:33 2016 +0200 phy-sun4i-usb: Fix irq free conditions to match request conditions commit 5cf700ac9d50 ("phy: phy-sun4i-usb: Fix optional gpios failing probe") changed the condition under which irqs are requested, but omitted matching changes to sun4i_usb_phy_remove(). This commit fixes this. Fixes: 5cf700ac9d50 ("phy: phy-sun4i-usb: Fix optional gpios failing probe") Signed-off-by: Hans de Goede Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-sun4i-usb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8d39fc085d268a56486066a3deca94745f804f2d Author: Lukasz Luba Date: Tue May 31 11:25:09 2016 +0100 PM / devfreq: fix initialization of current frequency in last status Some systems need current frequency from last_status for calculation but it is zeroed during initialization. When the device starts there is no history, but we can assume that the last frequency was the same as the initial frequency (which is also used in 'previous_freq'). The log shows the result of this misinterpreted value. [ 2.042847] ... Failed to get voltage for frequency 0: -34 Signed-off-by: Lukasz Luba Reviewed-by: Javi Merino Signed-off-by: MyungJoo Ham drivers/devfreq/devfreq.c | 1 + 1 file changed, 1 insertion(+) commit 674789dd2c4b53ed368dc81ae22d72ac4fdb92ec Author: Dan Carpenter Date: Thu May 26 09:45:42 2016 +0300 PM / devfreq: exynos-nocp: Remove incorrect IS_ERR() check Smatch complains because platform_get_resource() returns NULL on error and not an error pointer so the check is wrong. Julia Lawall pointed out that normally we don't check these, because devm_ioremap_resource() has a check for NULL. Signed-off-by: Dan Carpenter Reviewed-by: Julia Lawall Signed-off-by: MyungJoo Ham drivers/devfreq/event/exynos-nocp.c | 3 --- 1 file changed, 3 deletions(-) commit 67ffdb529b4ec9833f73947dec01eaa78dd53c3d Author: MyungJoo Ham Date: Mon May 16 11:41:57 2016 +0900 PM / devfreq: remove double put_device When device_register() returns with error, it has already done put_device() on the input device pointer. Signed-off-by: MyungJoo Ham drivers/devfreq/devfreq.c | 1 - 1 file changed, 1 deletion(-) commit a5e9b937fa91b3f404618b5281c3239bd1f09c7b Author: Cai Zhiyong Date: Sat May 14 14:13:30 2016 +0800 PM / devfreq: fix double call put_device 1295 */ 1296 void device_unregister(struct device *dev) 1297 { 1298 pr_debug("device: '%s': %s\n", dev_name(dev), __func__); 1299 device_del(dev); 1300 put_device(dev); 1301 } 1302 EXPORT_SYMBOL_GPL(device_unregister); 1303 device_unregister is called put_device, there is no need to call put_device(&devfreq->dev) again. Signed-off-by: Cai Zhiyong Reviewed-by: Chanwoo Choi Signed-off-by: MyungJoo Ham drivers/devfreq/devfreq.c | 1 - 1 file changed, 1 deletion(-) commit ac4b281176a54d17dd3f91b7fb4a4656471d8730 Author: MyungJoo Ham Date: Fri Oct 2 12:48:54 2015 +0900 PM / devfreq: fix duplicated kfree on devfreq pointer device_unregister() calls kfree already. Signed-off-by: MyungJoo Ham drivers/devfreq/devfreq.c | 1 - 1 file changed, 1 deletion(-) commit 3e1d7fb0d279fea19eb4e36cc9bddf89264ba03f Author: MyungJoo Ham Date: Fri Oct 2 12:39:23 2015 +0900 PM / devfreq: devm_kzalloc to have dev pointer more precisely devm_kzalloc of devfreq's statistics data structure has been using its parent device as the dev allocated for. If a device's devfreq is disabled in run-time, such allocated memory won't be freed. Desginating more precisely with the devfreq device pointer fixes the issue. Signed-off-by: MyungJoo Ham drivers/devfreq/devfreq.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 2f38b1b16d9280689e5cfa47a4c50956bf437f0d Author: Lv Zheng Date: Tue Jun 21 12:34:15 2016 +0800 ACPICA: Namespace: Fix deadlock triggered by MLC support in dynamic table loading The new module-level code (MLC) approach invokes MLC on the per-table basis, but the dynamic loading support of this is incorrect because of the lock order: acpi_ns_evaluate acpi_ex_enter_intperter acpi_ns_load_table (triggered by Load opcode) acpi_ns_exec_module_code_list acpi_ex_enter_intperter The regression is introduced by the following commit: Commit: 2785ce8d0da1cac9d8f78615e116cf929e9a9123 ACPICA Commit: 071eff738c59eda1792ac24b3b688b61691d7e7c Subject: ACPICA: Add per-table execution of module-level code This patch fixes this regression by unlocking the interpreter lock before invoking MLC. However, the unlocking is done to the acpi_ns_load_table(), in which the interpreter lock should be locked by acpi_ns_parse_table() but it wasn't. Fixes: 2785ce8d0da1 (ACPICA: Add per-table execution of module-level code) Reported-by: Mika Westerberg Tested-by: Mika Westerberg Signed-off-by: Lv Zheng Cc: 4.5+ # 4.5+ [ rjw : Subject ] Signed-off-by: Rafael J. Wysocki drivers/acpi/acpica/exconfig.c | 2 ++ drivers/acpi/acpica/nsparse.c | 9 +++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) commit 20c27a4270c775d7ed661491af8ac03264d60fc6 Author: Shaokun Zhang Date: Tue Jun 21 15:32:57 2016 +0800 arm64: mm: remove page_mapping check in __sync_icache_dcache __sync_icache_dcache unconditionally skips the cache maintenance for anonymous pages, under the assumption that flushing is only required in the presence of D-side aliases [see 7249b79f6b4cc ("arm64: Do not flush the D-cache for anonymous pages")]. Unfortunately, this breaks migration of anonymous pages holding self-modifying code, where userspace cannot be reasonably expected to reissue maintenance instructions in response to a migration. This patch fixes the problem by removing the broken page_mapping(page) check from the cache syncing code, otherwise we may end up fetching and executing stale instructions from the PoU. Cc: Catalin Marinas Cc: Will Deacon Cc: Mark Rutland Cc: Reviewed-by: Catalin Marinas Signed-off-by: Shaokun Zhang Signed-off-by: Will Deacon arch/arm64/mm/flush.c | 4 ---- 1 file changed, 4 deletions(-) commit 9ca4e58c20d5cb2a5bc378238188c71317aceac5 Author: Masahiro Yamada Date: Tue Jun 21 10:44:00 2016 +0900 arm64: fix boot image dependencies to not generate invalid images I fixed boot image dependencies for arch/arm in commit 3939f3345050 ("ARM: 8418/1: add boot image dependencies to not generate invalid images"). I see a similar problem for arch/arm64; "make -jN Image Image.gz" would sometimes end up generating bad images where N > 1. Fix the dependency in arch/arm64/Makefile to avoid the race between "make Image" and "make Image.*". Acked-by: Catalin Marinas Signed-off-by: Masahiro Yamada Signed-off-by: Will Deacon arch/arm64/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f7e0efc9b50266f5317b50732efff98d40fc879a Author: Jean-Philippe Brucker Date: Fri Jun 17 18:33:00 2016 +0100 arm64: update ASID limit During a rollover, we mark the active ASID on each CPU as reserved, before allocating a new ID for the task that caused the rollover. This means that with N CPUs, we can only guarantee the new task to obtain a valid ASID if we have at least N+1 ASIDs. Update this limit in the initcall check. Note that this restriction was introduced by commit 8e648066 on the arch/arm side, which disallow re-using the previously active ASID on the local CPU, as it would introduce a TLB race. In addition, we only dispose of NUM_USER_ASIDS-1, since ASID 0 is reserved. Add this restriction as well. Signed-off-by: Jean-Philippe Brucker Signed-off-by: Will Deacon arch/arm64/mm/context.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 1e3fa0acfec677e915d7de5ac6e1f18cfa4f805b Author: Lyude Date: Thu Jun 9 11:58:15 2016 -0400 drm/i915/fbc: Disable on HSW by default for now >From https://bugs.freedesktop.org/show_bug.cgi?id=96461 : This was kind of a difficult bug to track down. If you're using a Haswell system running GNOME and you have fbc completely enabled and working, playing videos can result in video artifacts. Steps to reproduce: - Run GNOME - Ensure FBC is enabled and active - Download a movie, I used the ogg version of Big Buck Bunny for this - Run `gst-launch-1.0 filesrc location='some_movie.ogg' ! decodebin ! glimagesink` in a terminal - Watch for about over a minute, you'll see small horizontal lines go down the screen. For the time being, disable FBC for Haswell by default. Stefan Richter reported kernel freezes (no video artifacts) when fbc is on. (E3-1245 v3 with HD P4600; openbox and some KDE and LXDE applications, thread begins at https://lkml.org/lkml/2016/4/26/813). We also got reports from Steven Honeyman on openbox+roxterm. v2 (From Paulo): - Add extra information to the commit message - Add Fixes tag - Rebase Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96461 Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96464 Fixes: a98ee79317b4 ("drm/i915/fbc: enable FBC by default on HSW and BDW") Cc: stable@vger.kernel.org Reviewed-by: Paulo Zanoni Signed-off-by: Lyude Signed-off-by: Paulo Zanoni Link: http://patchwork.freedesktop.org/patch/msgid/1465487895-7401-1-git-send-email-cpaul@redhat.com (cherry picked from commit c7f7e2feffb0294302041507dfd5fc15f01afccc) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_fbc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 34511dce4b35685d3988d5c8b100d11a068db5bd Author: Mika Kahola Date: Mon Jun 20 11:10:26 2016 +0300 drm/i915: Revert DisplayPort fast link training feature It has been found out that in some HW combination the DisplayPort fast link training feature caused screen flickering. Let's revert this feature for now until we can ensure that the feature works for all platforms. This is a manual revert of commits 5fa836a9d859 ("drm/i915: DP link training optimization") and 4e96c97742f4 ("drm/i915: eDP link training optimization"). Fixes: 5fa836a9d859 ("drm/i915: DP link training optimization") Fixes: 4e96c97742f4 ("drm/i915: eDP link training optimization") Cc: # v4.2+ Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91393 Reviewed-by: Jani Nikula Signed-off-by: Mika Kahola Signed-off-by: Jani Nikula Link: http://patchwork.freedesktop.org/patch/msgid/1466410226-19543-1-git-send-email-mika.kahola@intel.com (cherry picked from commit 91df09d92ad82c8778ca218097bf827f154292ca) drivers/gpu/drm/i915/intel_dp.c | 3 --- drivers/gpu/drm/i915/intel_dp_link_training.c | 26 ++------------------------ drivers/gpu/drm/i915/intel_drv.h | 2 -- 3 files changed, 2 insertions(+), 29 deletions(-) commit 270d013659ddab52a6fd0eacae452c422d08aa39 Author: Rex Zhu Date: Tue Jun 7 18:39:06 2016 +0800 drm/amd/powerplay: enable clock stretch feature for polaris Power saving feature which reduces the amount of voltage needed for specific engine clocks. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 120 ++++----------------- 1 file changed, 23 insertions(+), 97 deletions(-) commit 92d1576859577b94eafaea9b64f78ab99fe20a78 Author: Rex Zhu Date: Tue Jun 7 14:09:56 2016 +0800 drm/amdgpu/gfx8: update golden setting for polaris10 Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 432c3a3ca794bd2301425cb58bf097fc26690c17 Author: Rex Zhu Date: Wed Jun 8 19:39:42 2016 +0800 drm/amd/powerplay: enable avfs feature for polaris avfs feature is for voltage control based on gpu system clock on polaris10 Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 90 +++++++++++++++++++++- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.h | 3 + .../drm/amd/powerplay/hwmgr/polaris10_thermal.c | 6 +- drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.c | 43 +++++++++++ drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.h | 32 ++++++++ .../gpu/drm/amd/powerplay/inc/polaris10_ppsmc.h | 1 + .../drm/amd/powerplay/smumgr/polaris10_smumgr.c | 50 ++++++++---- 7 files changed, 208 insertions(+), 17 deletions(-) commit c11cb70483c33404d1c0cf9aa48e7627eecbe14d Author: Rex Zhu Date: Wed Jun 8 19:17:31 2016 +0800 drm/amdgpu/atombios: add avfs struct for Polaris10/11 Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/include/atombios.h | 72 ++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) commit 31b21243776e1f41813f40ce16c465bf03acd9ba Author: Rex Zhu Date: Tue Jun 7 18:38:39 2016 +0800 drm/amd/powerplay: add avfs related define for polaris Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/inc/smu74.h | 75 +++++++++++++++++++--- drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 42 ++++++++---- 2 files changed, 98 insertions(+), 19 deletions(-) commit 9a3c1b342be28a14006f644528dd9baad43db443 Author: Rex Zhu Date: Wed Jun 8 19:42:48 2016 +0800 drm/amd/powrplay: enable stutter_mode for polaris. To minimize the dram power expenditure during static -screen Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 40787ef21c2889fc3d96a11775fa412e715d7d48 Author: Rex Zhu Date: Wed Jun 8 19:41:00 2016 +0800 drm/amd/powerplay: disable UVD SMU handshake for MCLK. sync up with internal programming recommendations. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit a2fb4934e960b11e4430dccc08d606c99910b447 Author: Rex Zhu Date: Mon Jun 13 17:46:31 2016 +0800 drm/amd/powerplay: initialize variables which were missed. Missing pcie dpm settings. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Reviewed-by: Ken Wang Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 2 ++ drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 1 + drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 1 + 3 files changed, 4 insertions(+) commit 919e334dec283294acd99951d016e59ad725c9a7 Author: Rex Zhu Date: Wed May 11 17:04:07 2016 +0800 drm/amd/powerplay: enable PowerContainment feature for polaris10/11. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 4 ++++ 1 file changed, 4 insertions(+) commit 0a4fef559b69ae2e682c98f31d53a225fbda78bd Author: Rex Zhu Date: Tue Jun 14 18:36:36 2016 +0800 drm/amd/powerplay: need to notify system bios pcie device ready before request performance state. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Reviewed-by: Ken Wang Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/powerplay/hwmgr/pp_acpi.c | 16 +++++++++++++++- drivers/gpu/drm/amd/powerplay/inc/pp_acpi.h | 1 + 2 files changed, 16 insertions(+), 1 deletion(-) commit 576b4401b1971fe40be4cfd379430a61cd8426b2 Author: Rex Zhu Date: Mon Jun 13 17:39:19 2016 +0800 drm/amd/powerplay: fix bug that function parameter was incorect. Wrong value passed to acpi_pcie_perf_request. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Reviewed-by: Ken Wang Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/powerplay/hwmgr/pp_acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d7b84d12af8312b52316029f1fa0fa4eac3c9e4 Author: Rex Zhu Date: Fri Jun 17 18:21:01 2016 +0800 drm/amd/powerplay: fix logic error. the error lead powerplay can't get display info in DGPU case. store_cc6_data just implement in APU. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 0b1e1eb76220afa043b2733dfe61f5927cf0e458 Author: Boris Brezillon Date: Fri Jun 3 09:17:36 2016 +0200 drm: atmel-hlcdc: Fix OF graph parsing atmel_hlcdc_create_outputs() iterates over OF graph nodes and releases the node (using of_node_put()) after each iteration, which is wrong since for_each_endpoint_of_node() is already taking care of that. Move the of_node_put() call in the error path. Signed-off-by: Boris Brezillon Reviewed-by: Nicolas Ferre Fixes: 17a8e03e7e97 ("drm: atmel-hlcdc: rework the output code to support drm bridges") drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 1b7e38b92b0bbd363369f5160f13f4d26140972d Author: Boris Brezillon Date: Fri May 27 16:09:25 2016 +0200 drm: atmel-hlcdc: actually disable scaling when no scaling is required The driver is only enabling scaling, but never disabling it, thus, if you enable the scaling feature once it stays enabled forever. Signed-off-by: Boris Brezillon Reported-by: Alex Vazquez Reviewed-by: Nicolas Ferre Fixes: 1a396789f65a ("drm: add Atmel HLCDC Display Controller support") Cc: drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 2 ++ 1 file changed, 2 insertions(+) commit 086347705be7530feabb6274a3ad81dd545e7914 Merge: a5e9b85 62d0e71d Author: Stephen Boyd Date: Mon Jun 20 17:01:45 2016 -0700 Merge tag 'v4.7-rockchip-clk-fixes1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-fixes A bunch of fixes. Some for the newly added rk3399 clock tree, some concerning error handling and initialization and a revert of the mmc-phase clock initialization, as this could conflict with the bootloader setting of this clock and a real solution to initing the phase correctly from dw_mmc went in as fix for 4.7 through the mmc tree. * tag 'v4.7-rockchip-clk-fixes1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: release io resource when failing to init clk on rk3399 clk: rockchip: fix cpuclk registration error handling clk: rockchip: Revert "clk: rockchip: reset init state before mmc card initialization" clk: rockchip: fix incorrect parent for rk3399's {c,g}pll_aclk_perihp_src clk: rockchip: mark rk3399 GIC clocks as critical clk: rockchip: initialize flags of clk_init_data in mmc-phase clock commit a5e9b85a6540df6c4074d3a56674f6fb6c5fc830 Author: Wei Yongjun Date: Fri Jun 17 17:24:23 2016 +0000 clk: Fix return value check in oxnas_stdclk_probe() In case of error, the function syscon_node_to_regmap() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Signed-off-by: Wei Yongjun Acked-by: Neil Armstrong Fixes: 0bbd72b4c64f ("clk: Add Oxford Semiconductor OXNAS Standard Clocks") Signed-off-by: Stephen Boyd drivers/clk/clk-oxnas.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ebaaa80e8f20ff2cbbccd6823f73a99565487502 Author: Al Viro Date: Mon Jun 6 20:55:34 2016 -0400 lockless next_positive() Signed-off-by: Al Viro fs/libfs.c | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) commit 4f42c1b5b9c27b6228e6b9c57eee4beb3118b6b0 Author: Al Viro Date: Mon Jun 6 19:37:13 2016 -0400 libfs.c: new helper - next_positive() Return nth positive child after given or NULL if there's less than n left. dcache_readdir() and dcache_dir_lseek() switched to it. Signed-off-by: Al Viro fs/libfs.c | 77 ++++++++++++++++++++++++++++++++++++++------------------------ 1 file changed, 47 insertions(+), 30 deletions(-) commit 274f5b041d3c9c0974a7dd1f66b67c33bb5b0f42 Author: Al Viro Date: Mon Jun 6 18:55:57 2016 -0400 dcache_{readdir,dir_lseek}(): don't bother with nested ->d_lock Make sure that directory is locked shared in dcache_dir_lseek(); for dcache_readdir() it's already tru, and that's enough to make simple_positive() stable. Signed-off-by: Al Viro fs/libfs.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) commit 29b9c528b8c295911e8b1e515273e89a2b7fa2d8 Author: Nicolas Iooss Date: Sat Jun 18 22:55:00 2016 +0200 drm/amdgpu: initialize amdgpu_cgs_acpi_eval_object result value amdgpu_cgs_acpi_eval_object() returned the value of variable "result" without initializing it first. This bug has been found by compiling the kernel with clang. The compiler complained: drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c:972:14: error: variable 'result' is used uninitialized whenever 'for' loop exits because its condition is false [-Werror,-Wsometimes-uninitialized] for (i = 0; i < count; i++) { ^~~~~~~~~ drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c:1011:9: note: uninitialized use occurs here return result; ^~~~~~ drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c:972:14: note: remove the condition if it is always true for (i = 0; i < count; i++) { ^~~~~~~~~ drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c:864:12: note: initialize the variable 'result' to silence this warning int result; ^ = 0 Fixes: 3f1d35a03b3c ("drm/amdgpu: implement new cgs interface for acpi function") Signed-off-by: Nicolas Iooss Cc: stable@vger.kernel.org Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 48a70e1ca85e3b484791e100bb403c05ef9d37c8 Author: Dan Carpenter Date: Sat Jun 18 11:38:44 2016 +0300 drm/amdgpu: precedence bug in amdgpu_device_init() ! has higher precedence than bitwise & so we need to add parenthesis for this to work as intended. Fixes: 048765ad5af7 ('amdgpu: fix asic initialization for virtualized environments (v2)') Signed-off-by: Dan Carpenter Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ef0dab4aae14e25efddf1577736f8450132800c5 Author: David Miller Date: Sat Jun 18 23:52:25 2016 -0700 PCI: Fix unaligned accesses in VC code The save/restore buffers for VC state is first composed of a 2-byte control register, then a bunch of 4-byte words. This causes unaligned accesses which trap on platform such as sparc. This is easy to fix by simply moving the buffer pointer forward by 4 bytes instead of 2 after dealing with the control register. The length adjustment needs to be changed likewise as well. Fixes: 5f8fc43217a0 ("PCI: Include pci/pcie/Kconfig directly from pci/Kconfig") Reported-by: Meelis Roos Reported-by: Anatoly Pugachev Signed-off-by: David S. Miller Signed-off-by: Bjorn Helgaas CC: stable@vger.kernel.org # v4.6+ drivers/pci/vc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 67016f6cdfd079e632bbc49e33178b2d558c120a Merge: f780f00 e7d6ef9 Author: Linus Torvalds Date: Mon Jun 20 10:41:51 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs fixes from Al Viro: "A couple more of d_walk()/d_subdirs reordering fixes (stable fodder; ought to solve that crap for good) and a fix for a brown paperbag bug in d_alloc_parallel() (this cycle)" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: fix idiotic braino in d_alloc_parallel() autofs races much milder d_walk() race commit f780f00d723d991353b2a97a8a844ffefbc40505 Merge: 97f78c7 0ded517 Author: Linus Torvalds Date: Mon Jun 20 10:35:48 2016 -0700 Merge tag 'trace-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing fixes from Steven Rostedt: "Two fixes for the tracing system: - When trace_printk() is used with a non constant format descriptor, it adds a NULL pointer into the trace format section, and the code isn't prepared to deal with it. This bug appeared by a change that was added in v3.5. - The ftracetest (selftests section) can't handle testing histograms when histograms are not configured. Currently it shows that they fail the test, when they should state that they are unsupported. This bug was added in the 4.7 merge window with the addition of the historgram code" * tag 'trace-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: ftracetest: Fix hist unsupported result in hist selftests tracing: Handle NULL formats in hold_module_trace_bprintk_format() commit 97f78c7de8ae38c007fec406d40df99ae62b36de Merge: 4e183d7 9254e70 Author: Linus Torvalds Date: Mon Jun 20 10:18:58 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux Pull s390 fixes from Martin Schwidefsky: "Two more bugs fixes for 4.7: - a KVM regression introduced with the pgtable.c code split - a perf issue with two hardware PMUs using a shared event context" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: s390/cpum_cf: use perf software context for hardware counters KVM: s390/mm: Fix CMMA reset during reboot commit 4e183d7add15e8bdd131aa14976e26ca3d71a889 Merge: 33688ab 2744d2f Author: Linus Torvalds Date: Mon Jun 20 10:04:12 2016 -0700 Merge tag 'hwmon-for-linus-v4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging Pull hwmon fixes from Guenter Roeck: "Two stability fixes plus a security fix for the dell-smm driver" * tag 'hwmon-for-linus-v4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: hwmon: (dell-smm) Disallow fan_type() calls on broken machines hwmon: (dell-smm) Restrict fan control and serial number to CAP_SYS_ADMIN by default hwmon: (dell-smm) Fail in ioctl I8K_BIOS_VERSION when bios version is not a number commit 40f0fd372a623e8d32bae0b9361d2a7453ae7a2e Author: Chris J Arges Date: Thu Jun 9 15:31:29 2016 -0500 ecryptfs: fix spelling mistakes Noticed some minor spelling errors when looking through the code. Signed-off-by: Chris J Arges Signed-off-by: Tyler Hicks fs/ecryptfs/crypto.c | 4 ++-- fs/ecryptfs/file.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 5f9f2c2abd16fcea6cf7cf87791a24687e2fc345 Author: Wei Yuan Date: Wed Feb 17 14:50:10 2016 +0800 eCryptfs: fix typos in comment Signed-off-by: Weiyuan Signed-off-by: Tyler Hicks fs/ecryptfs/crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c39341cf0d08357f448f4c2fffe2ebcc9495fd01 Author: Julia Lawall Date: Sun Sep 13 14:15:21 2015 +0200 ecryptfs: drop null test before destroy functions Remove unneeded NULL test. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ expression x; @@ -if (x != NULL) \(kmem_cache_destroy\|mempool_destroy\|dma_pool_destroy\)(x); // Signed-off-by: Julia Lawall Signed-off-by: Tyler Hicks fs/ecryptfs/main.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit e7d6ef9790bc281f5c29d0132b68031248523fe8 Author: Al Viro Date: Mon Jun 20 01:35:59 2016 -0400 fix idiotic braino in d_alloc_parallel() Check for d_unhashed() while searching in in-lookup hash was absolutely wrong. Worse, it masked a deadlock on dget() done under bitlock that nests inside ->d_lock. Thanks to J. R. Okajima for spotting it. Spotted-by: "J. R. Okajima" Wearing-brown-paperbag: Al Viro Signed-off-by: Al Viro fs/dcache.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit 0ded5174e976e2b2a354fe38abf1ebf4492c6dc3 Author: Steven Rostedt (Red Hat) Date: Mon May 23 15:06:30 2016 -0400 ftracetest: Fix hist unsupported result in hist selftests When histograms are not configured in the kernel, the ftracetest histogram selftests should return "unsupported" and not "Failed". To detect this, the test scripts have: FEATURE=`grep hist events/sched/sched_process_fork/trigger` if [ -z "$FEATURE" ]; then echo "hist trigger is not supported" exit_unsupported fi The problem is that '-e' is in effect and any error will cause the program to terminate. The grep for 'hist' fails, because it is not compiled it (thus unsupported), but because grep has an error code for failing to find the string, it causes the program to terminate, and is marked as a failed test. Namhyung Kim recommended to test for the "hist" file located in events/sched/sched_process_fork/hist instead, as it is more inline with the other checks. As the hist file is only created if the histogram feature is enabled, that is a valid check. Link: http://lkml.kernel.org/r/20160523151538.4ea9ce0c@gandalf.local.home Suggested-by: Namhyung Kim Acked-by: Namhyung Kim Acked-by: Masami Hiramatsu Fixes: 76929ab51f0ee ("kselftests/ftrace: Add hist trigger testcases") Signed-off-by: Steven Rostedt .../testing/selftests/ftrace/test.d/trigger/trigger-hist-mod.tc | 9 ++++----- tools/testing/selftests/ftrace/test.d/trigger/trigger-hist.tc | 9 ++++----- .../testing/selftests/ftrace/test.d/trigger/trigger-multihist.tc | 9 ++++----- 3 files changed, 12 insertions(+), 15 deletions(-) commit 70c8217acd4383e069fe1898bbad36ea4fcdbdcc Author: Steven Rostedt (Red Hat) Date: Fri Jun 17 16:10:42 2016 -0400 tracing: Handle NULL formats in hold_module_trace_bprintk_format() If a task uses a non constant string for the format parameter in trace_printk(), then the trace_printk_fmt variable is set to NULL. This variable is then saved in the __trace_printk_fmt section. The function hold_module_trace_bprintk_format() checks to see if duplicate formats are used by modules, and reuses them if so (saves them to the list if it is new). But this function calls lookup_format() that does a strcmp() to the value (which is now NULL) and can cause a kernel oops. This wasn't an issue till 3debb0a9ddb ("tracing: Fix trace_printk() to print when not using bprintk()") which added "__used" to the trace_printk_fmt variable, and before that, the kernel simply optimized it out (no NULL value was saved). The fix is simply to handle the NULL pointer in lookup_format() and have the caller ignore the value if it was NULL. Link: http://lkml.kernel.org/r/1464769870-18344-1-git-send-email-zhengjun.xing@intel.com Reported-by: xingzhen Acked-by: Namhyung Kim Fixes: 3debb0a9ddb ("tracing: Fix trace_printk() to print when not using bprintk()") Cc: stable@vger.kernel.org # v3.5+ Signed-off-by: Steven Rostedt kernel/trace/trace_printk.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 8974189222159154c55f24ddad33e3613960521a Author: Peter Zijlstra Date: Thu Jun 16 10:50:40 2016 +0200 sched/fair: Fix cfs_rq avg tracking underflow As per commit: b7fa30c9cc48 ("sched/fair: Fix post_init_entity_util_avg() serialization") > the code generated from update_cfs_rq_load_avg(): > > if (atomic_long_read(&cfs_rq->removed_load_avg)) { > s64 r = atomic_long_xchg(&cfs_rq->removed_load_avg, 0); > sa->load_avg = max_t(long, sa->load_avg - r, 0); > sa->load_sum = max_t(s64, sa->load_sum - r * LOAD_AVG_MAX, 0); > removed_load = 1; > } > > turns into: > > ffffffff81087064: 49 8b 85 98 00 00 00 mov 0x98(%r13),%rax > ffffffff8108706b: 48 85 c0 test %rax,%rax > ffffffff8108706e: 74 40 je ffffffff810870b0 > ffffffff81087070: 4c 89 f8 mov %r15,%rax > ffffffff81087073: 49 87 85 98 00 00 00 xchg %rax,0x98(%r13) > ffffffff8108707a: 49 29 45 70 sub %rax,0x70(%r13) > ffffffff8108707e: 4c 89 f9 mov %r15,%rcx > ffffffff81087081: bb 01 00 00 00 mov $0x1,%ebx > ffffffff81087086: 49 83 7d 70 00 cmpq $0x0,0x70(%r13) > ffffffff8108708b: 49 0f 49 4d 70 cmovns 0x70(%r13),%rcx > > Which you'll note ends up with sa->load_avg -= r in memory at > ffffffff8108707a. So I _should_ have looked at other unserialized users of ->load_avg, but alas. Luckily nikbor reported a similar /0 from task_h_load() which instantly triggered recollection of this here problem. Aside from the intermediate value hitting memory and causing problems, there's another problem: the underflow detection relies on the signed bit. This reduces the effective width of the variables, IOW its effectively the same as having these variables be of signed type. This patch changes to a different means of unsigned underflow detection to not rely on the signed bit. This allows the variables to use the 'full' unsigned range. And it does so with explicit LOAD - STORE to ensure any intermediate value will never be visible in memory, allowing these unserialized loads. Note: GCC generates crap code for this, might warrant a look later. Note2: I say 'full' above, if we end up at U*_MAX we'll still explode; maybe we should do clamping on add too. Signed-off-by: Peter Zijlstra (Intel) Cc: Andrey Ryabinin Cc: Chris Wilson Cc: Linus Torvalds Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Yuyang Du Cc: bsegall@google.com Cc: kernel@kyup.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: steve.muckle@linaro.org Fixes: 9d89c257dfb9 ("sched/fair: Rewrite runnable load and utilization average tracking") Link: http://lkml.kernel.org/r/20160617091948.GJ30927@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar kernel/sched/fair.c | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) commit f155d9c0a138463c3c9380d35e54e433c1477336 Author: Maximilian Schneider Date: Wed Jun 8 18:00:26 2016 +0000 can: gs_usb: Add Basic support for the bytewerk.org candleLight interface This patchs adds basic support for the bytewerk.org candleLight interface, a open hardware (CERN OHL) USB CAN adapter. Signed-off-by: Hubert Denkmair Signed-off-by: Maximilian Schneider Signed-off-by: Marc Kleine-Budde drivers/net/can/usb/Kconfig | 3 ++- drivers/net/can/usb/gs_usb.c | 14 +++++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) commit 43200a4480cbbe660309621817f54cbb93907108 Author: Wolfgang Grandegger Date: Mon Jun 13 15:44:19 2016 +0200 can: at91_can: RX queue could get stuck at high bus load At high bus load it could happen that "at91_poll()" enters with all RX message boxes filled up. If then at the end the "quota" is exceeded as well, "rx_next" will not be reset to the first RX mailbox and hence the interrupts remain disabled. Signed-off-by: Wolfgang Grandegger Tested-by: Amr Bekhit Cc: Signed-off-by: Marc Kleine-Budde drivers/net/can/at91_can.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 427460c83cdf55069eee49799a0caef7dde8df69 Author: Thor Thayer Date: Thu Jun 16 11:10:19 2016 -0500 can: c_can: Update D_CAN TX and RX functions to 32 bit - fix Altera Cyclone access When testing CAN write floods on Altera's CycloneV, the first 2 bytes are sometimes 0x00, 0x00 or corrupted instead of the values sent. Also observed bytes 4 & 5 were corrupted in some cases. The D_CAN Data registers are 32 bits and changing from 16 bit writes to 32 bit writes fixes the problem. Testing performed on Altera CycloneV (D_CAN). Requesting tests on other C_CAN & D_CAN platforms. Reported-by: Richard Andrysek Signed-off-by: Thor Thayer Cc: Signed-off-by: Marc Kleine-Budde drivers/net/can/c_can/c_can.c | 38 +++++++++++++++++++++++++++++++------- 1 file changed, 31 insertions(+), 7 deletions(-) commit 33688abb2802ff3a230bd2441f765477b94cc89e Author: Linus Torvalds Date: Sun Jun 19 21:30:02 2016 -0700 Linux 4.7-rc4 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ab522fd68bc78f3f81f6c553f785dae3462859fa Merge: 5c3da57 b639f19 Author: David S. Miller Date: Sun Jun 19 10:47:33 2016 -0700 Merge branch 'qed-fixes' Yuval Mintz says: ==================== qed*: Fixes series This series contains several small fixes to driver behavior [4th patch is the only one containing a 'fatal' fix, but the error is only theoretical for qede; if would require another protocol driver yet unsubmitted to reach it]. ==================== Signed-off-by: David S. Miller commit b639f197210d37905a6018ae4297659eb3f48f8f Author: Yuval Mintz Date: Sun Jun 19 15:18:15 2016 +0300 qed: Add missing port-mode The 'MODULE_FIBER' value replaced several other FIBER values in newer management firmware images, so existing code would fail to properly reflect its mode. Signed-off-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_hsi.h | 1 + drivers/net/ethernet/qlogic/qed/qed_main.c | 1 + 2 files changed, 2 insertions(+) commit db511c37d4eb2b4e7312791eb8f9b34ed867445e Author: Yuval Mintz Date: Sun Jun 19 15:18:14 2016 +0300 qed: Fix returning unlimited SPQ entries Driver has 2 sets of entries for handling ramrod configurations toward firmware - a regular pre-allocated set of entires and a possible 'unlimited' list of additional pending entries. In most scenarios the 'unlimited' list would not be used, but when it does the handling of the ramrod completion doesn't properly handle the release of the entry. Signed-off-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_spq.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) commit a0d26d5a4fc8e13993279f788deeb08069e73b69 Author: Yuval Mintz Date: Sun Jun 19 15:18:13 2016 +0300 qed*: Don't reset statistics on inner reload Several user APIs can cause driver to perform an inner-reload. Currently, doing this would cause the HW/FW statistics of the adapter to reset, which isn't the expected behavior [statistics should only reset on explicit unloads]. Signed-off-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_l2.c | 3 ++- drivers/net/ethernet/qlogic/qede/qede_main.c | 7 ++++--- include/linux/qed/qed_eth_if.h | 1 + 3 files changed, 7 insertions(+), 4 deletions(-) commit 326439883e17fca029f4ed05307480bdb6369877 Author: Yuval Mintz Date: Sun Jun 19 15:18:12 2016 +0300 qed: Prevent VF from Tx-switching 'promisc' Internal loopback in driver is based on two things - first is the willingness of transmitter to use it [in case of VFs, this can be forced based on VEPA/VEB] and secondly on another vport classification configuration which should match the packet's destination. Current code allows non-linux VFs to configure a 'promisc' mode on Tx, meaning all traffic sent by VF would be loopbacked internally by firmware; This isn't considered a valid mode and as such should be prevented by PF. Signed-off-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_l2.c | 4 ---- 1 file changed, 4 deletions(-) commit e6bd89232b4a4c9282da1ac8bdd798c2a30d9a46 Author: Yuval Mintz Date: Sun Jun 19 15:18:11 2016 +0300 qed: Correct default vlan behavior When no vlan filter is configured, firmware has a configurable default on whether to pass only untagged packets or all packets regardless of their tagging. Driver currently doesn't set this field in the necessary ramrod, causing the default to always be 'receive all'. Signed-off-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/qlogic/qed/qed_l2.c | 1 + 1 file changed, 1 insertion(+) commit c3695331f3a326a468bd6a5b6f05b481b399726b Merge: 9af1f5d b9d8905 Author: Linus Torvalds Date: Sun Jun 19 07:05:14 2016 -1000 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs Pull UDF fixes and a reiserfs fix from Jan Kara: "A couple of udf fixes (most notably a bug in parsing UDF partitions which led to inability to mount recent Windows installation media) and a reiserfs fix for handling kstrdup failure" * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs: reiserfs: check kstrdup failure udf: Use correct partition reference number for metadata udf: Use IS_ERR when loading metadata mirror file entry udf: Don't BUG on missing metadata partition descriptor commit 9af1f5d8f20f97884da55817ab80a6fcd170f296 Merge: 049a40c 5156463 Author: Linus Torvalds Date: Sun Jun 19 06:52:20 2016 -1000 Merge tag 'dmaengine-fix-4.7-rc4' of git://git.infradead.org/users/vkoul/slave-dma Pull dmaengine fixes from Vinod Koul: "Some fixes has piled up, so time to send them upstream. These fixes include: - at_xdmac fixes for residue and other stuff - update MAINTAINERS for dma dt bindings - mv_xor fix for incorrect offset" * tag 'dmaengine-fix-4.7-rc4' of git://git.infradead.org/users/vkoul/slave-dma: dmaengine: mv_xor: Fix incorrect offset in dma_map_page() dmaengine: at_xdmac: double FIFO flush needed to compute residue dmaengine: at_xdmac: fix residue corruption dmaengine: at_xdmac: align descriptors on 64 bits MAINTAINERS: Add file patterns for dma device tree bindings commit 5abe9b26847c65a698f38744a52635b287514294 Author: Luis R. Rodriguez Date: Tue Jun 7 16:52:27 2016 -0700 i2c: remove __init from i2c_register_board_info() As of next-20160607 with allyesconfig we get this linker failure: MODPOST vmlinux.o WARNING: vmlinux.o(.text+0x21bc0d): Section mismatch in reference from the function intel_scu_devices_create() to the function .init.text:i2c_register_board_info() This is caused by the fact that intel_scu_devices_create() calls i2c_register_board_info() and intel_scu_devices_create() is not annotated with __init. This typically involves manual code inspection and if one is certain this is correct we would just peg intel_scu_devices_create() with a __ref annotation. In this case this would be wrong though as the intel_scu_devices_create() call is exported, and used in the ipc_probe() on drivers/platform/x86/intel_scu_ipc.c. The issue is that even though builtin_pci_driver(ipc_driver) is used this just exposes the probe routine, which can occur at any point in time if this bus supports hotplug. A race can happen between kernel_init_freeable() that calls the init calls (in this case registeres the intel_scu_ipc.c driver, and later free_initmem(), which would free the i2c_register_board_info(). If a probe happens later in boot i2c_register_board_info() would not be present and we should get a page fault. Signed-off-by: Luis R. Rodriguez [wsa: made function declaration a one-liner] Signed-off-by: Wolfram Sang drivers/i2c/i2c-boardinfo.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 049a40c0a2d4b458583161ec1b9ce109408cb1aa Merge: c141afd 8fd0976 Author: Linus Torvalds Date: Sat Jun 18 20:36:17 2016 -1000 Merge tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC fixes from Olof Johansson: "Another batch of fixes for ARM SoC platforms. Most are smaller fixes. Two areas that are worth pointing out are: - OMAP had a handful of changes to voltage specs that caused a bit of churn, most of volume of change in this branch is due to this. - There are a couple of _rcuidle fixes from Paul that touch common code and came in through the OMAP tree since they were the ones who saw the problems. The rest is smaller changes across a handful of platforms" * tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (36 commits) ARM: dts: STi: stih407-family: Disable reserved-memory co-processor nodes ARM: dts: am437x-sk-evm: Reduce i2c0 bus speed for tps65218 ARM: OMAP2+: timer: add probe for clocksources ARM: OMAP1: fix ams-delta FIQ handler to work with sparse IRQ memory: omap-gpmc: Fix omap gpmc EXTRADELAY timing arm: Use _rcuidle for smp_cross_call() tracepoints MAINTAINERS: Add myself as reviewer of ARM FSL/NXP ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_mem_ret ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_logic_ret ARM: OMAP: DRA7: powerdomain data: Set L3init and L4per to ON ARM: imx6ul: Fix Micrel PHY mask ARM: OMAP2+: Select OMAP_INTERCONNECT for SOC_AM43XX ARM: dts: DRA74x: fix DSS PLL2 addresses ARM: OMAP2: Enable Errata 430973 for OMAP3 ARM: dts: socfpga: Add missing PHY phandle ARM: dts: exynos: Fix port nodes names for Exynos5420 Peach Pit board ARM: dts: exynos: Fix port nodes names for Exynos5250 Snow board ARM: dts: sun6i: yones-toptech-bs1078-v2: Drop constraints on dc1sw regulator ARM: dts: sun6i: primo81: Drop constraints on dc1sw regulator ARM: dts: sunxi: Add OLinuXino Lime2 eMMC to the Makefile ... commit 8fd0976702f05042c776848819e5fd2a835f23c9 Merge: 58935f2 8f50b8e Author: Olof Johansson Date: Sat Jun 18 22:59:07 2016 -0700 Merge tag 'gpmc-omap-fixes-for-v4.7' of https://github.com/rogerq/linux into fixes OMAP-GPMC: Fixes for for v4.7-rc cycle: - Fix omap gpmc EXTRADELAY timing. The DT provided timings were wrongly used causing devices requiring extra delay timing to fail. * tag 'gpmc-omap-fixes-for-v4.7' of https://github.com/rogerq/linux: memory: omap-gpmc: Fix omap gpmc EXTRADELAY timing + Linux 4.7-rc3 Signed-off-by: Olof Johansson commit 58935f24a996cb55595c29dd5303bd9b778c8b00 Merge: 9503427 6b41d44 Author: Olof Johansson Date: Sat Jun 18 22:57:48 2016 -0700 Merge tag 'omap-for-v4.7/fixes-powedomain' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes Fixes for omaps for v4.7-rc cycle: - Fix dra7 for hardware issues limiting L4Per and L3init power domains to on state. Without this the devices may not work correctly after some time of use because of asymmetric aging. And related to this, let's also remove the unusable states. - Always select omap interconnect for am43x as otherwise the am43x only configurations will not boot properly. This can happen easily for any product kernels that leave out other SoCs to save memory. - Fix DSS PLL2 addresses that have gone unused for now - Select erratum 430973 for omap3, this is now safe to do and can save quite a bit of debugging time for people who may have left it out. * tag 'omap-for-v4.7/fixes-powedomain' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_mem_ret ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_logic_ret ARM: OMAP: DRA7: powerdomain data: Set L3init and L4per to ON ARM: OMAP2+: Select OMAP_INTERCONNECT for SOC_AM43XX ARM: dts: DRA74x: fix DSS PLL2 addresses ARM: OMAP2: Enable Errata 430973 for OMAP3 + Linux 4.7-rc2 Signed-off-by: Olof Johansson commit 41abbf5afa51136bcb2aeefc80bf5c3a005d0aa3 Author: Tobias Jakobi Date: Wed May 25 14:30:07 2016 +0200 drm/exynos: use logical AND in exynos_drm_plane_check_size() The current bitwise AND should result in the same assembler but this is what the code is actually supposed to do. Signed-off-by: Tobias Jakobi Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos_drm_plane.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f0fcf43f285cdbc1bbc372919d68aea0cf4483d6 Author: Tobias Jakobi Date: Wed May 25 14:35:41 2016 +0200 drm/exynos: remove superfluous inclusions of fbdev header Neither of these files issue any fbdev related calls. Signed-off-by: Tobias Jakobi Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos7_drm_decon.c | 1 - drivers/gpu/drm/exynos/exynos_drm_core.c | 1 - drivers/gpu/drm/exynos/exynos_drm_fimd.c | 1 - 3 files changed, 3 deletions(-) commit ed4dc2718d3510f0fa5e6794f47b98549848f656 Author: Tobias Jakobi Date: Wed May 25 14:42:56 2016 +0200 drm/exynos: g2d: drop the _REG postfix from the stride defines This makes the defines consistent with the rest. Signed-off-by: Tobias Jakobi Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos_drm_g2d.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit e0d7461ceb5bb9b50e534262eb23e92deaaae6f1 Author: Javier Martinez Canillas Date: Thu Jun 2 10:20:10 2016 -0400 drm/exynos: don't use HW trigger for Exynos5420/5422/5800 Commit a6f75aa161c5 ("drm/exynos: fimd: add HW trigger support") added hardware trigger support to the FIMD controller driver. But this broke the display in at least the Exynos5800 Peach Pi Chromebook. So until the issue is fixed, avoid using HW trigger for the Exynos5420 based boards and use SW trigger as it was before the mentioned commit. Signed-off-by: Javier Martinez Canillas Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos_drm_fimd.c | 3 --- 1 file changed, 3 deletions(-) commit 5e0b37634cbb6bae69b7b15e1ea5f054dfaaa413 Author: Javier Martinez Canillas Date: Mon May 30 20:20:22 2016 -0400 drm/exynos: fimd: don't set .has_hw_trigger in s3c6400 driver data The field value is only checked in fimd_setup_trigger() if .trg_type is I80_HW_TRG so there's no point in setting this field for the s3c6400 if is never going to be used since .trg_type is not set. Signed-off-by: Javier Martinez Canillas Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos_drm_fimd.c | 1 - 1 file changed, 1 deletion(-) commit d90efc9ee0df3f13f248aaf47086b1e0ed6035ae Author: Yakir Yang Date: Wed Jun 8 10:13:27 2016 -0400 drm/exynos: dp: Fix NULL pointer dereference due uninitialized connector Commit 3424e3a4f844 ("drm: bridge: analogix/dp: split exynos dp driver to bridge directory") split the Exynos DP core driver into a core driver and a bridge driver for the Analogix chip since that is also used by Rockchip. But the change introduced a regression causing a NULL pointer dereference when trying to access an uninitialized connector in the driver .get_modes: Fix this by instead of having a connector struct for both the Exynos and Analogix drivers, just use the connector initialized in the bridge driver. Fixes: 3424e3a4f844 ("drm: bridge: analogix/dp: split exynos dp driver to bridge directory") Reported-by: Marc Zyngier Signed-off-by: Yakir Yang Tested-by: Marc Zyngier Signed-off-by: Inki Dae drivers/gpu/drm/exynos/exynos_dp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 9503427e916aea7ec2cc429504f82d7200ab4bcd Merge: 0e289e5 d279f7a Author: Olof Johansson Date: Sat Jun 18 22:21:52 2016 -0700 Merge tag 'fixes-rcu-fiq-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes Fixes for omaps for v4.7-rc cycle: - Two boot warning fixes from the RCU tree that should have gotten merged several weeks ago already but did not because of issues with who merges them. Paul has now split the RCU warning fixes into sets for various maintainers. - Fix ams-delta FIQ regression caused by omap1 sparse IRQ changes - Fix PM for omap3 boards using timer12 and gptimer, like the original beagleboard - Fix hangs on am437x-sk-evm by lowering the I2C bus speed * tag 'fixes-rcu-fiq-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: dts: am437x-sk-evm: Reduce i2c0 bus speed for tps65218 ARM: OMAP2+: timer: add probe for clocksources ARM: OMAP1: fix ams-delta FIQ handler to work with sparse IRQ arm: Use _rcuidle for smp_cross_call() tracepoints arm: Use _rcuidle tracepoint to allow use from idle Signed-off-by: Olof Johansson commit 0e289e534af1b20417a1940c8eba549588671cd8 Author: Lee Jones Date: Fri Jun 17 13:44:18 2016 +0200 ARM: dts: STi: stih407-family: Disable reserved-memory co-processor nodes This patch fixes a non-booting issue in Mainline. When booting with a compressed kernel, we need to be careful how we populate memory close to DDR start. AUTO_ZRELADDR is enabled by default in multi-arch enabled configurations, which place some restrictions on where the kernel is placed and where it will be uncompressed to on boot. AUTO_ZRELADDR takes the decompressor code's start address and masks out the bottom 28 bits to obtain an address to uncompress the kernel to (thus a load address of 0x42000000 means that the kernel will be uncompressed to 0x40000000 i.e. DDR START on this platform). Even changing the load address to after the co-processor's shared memory won't render a booting platform, since the AUTO_ZRELADDR algorithm still ensures the kernel is uncompressed into memory shared with the first co-processor (0x40000000). Another option would be to move loading to 0x4A000000, since this will mean the decompressor will decompress the kernel to 0x48000000. However, this would mean a large chunk (0x44000000 => 0x48000000 (64MB)) of memory would essentially be wasted for no good reason. Until we can work with ST to find a suitable memory location to relocate co-processor shared memory, let's disable the shared memory nodes. This will ensure a working platform in the mean time. NB: The more observant of you will notice that we're leaving the DMU shared memory node enabled; this is because a) it is the only one in active use at the time of this writing and b) it is not affected by the current default behaviour which is causing issues. Fixes: fe135c6 (ARM: dts: STiH407: Move over to using the 'reserved-memory' API for obtaining DMA memory) Signed-off-by: Lee Jones Reviewed-by Peter Griffin Signed-off-by: Maxime Coquelin Signed-off-by: Olof Johansson arch/arm/boot/dts/stih407-family.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit 7752b0d5dcfdb6dcaffb8c83b1ba2af2ef81a81d Merge: a011064 20c1522 Author: Olof Johansson Date: Sat Jun 18 22:18:45 2016 -0700 Merge tag 'imx-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into fixes The i.MX fixes for 4.7: - Correct Micrel PHY mask to fix the issue that i.MX6UL ethernet works in U-Boot but not in kernel. * tag 'imx-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: imx6ul: Fix Micrel PHY mask Signed-off-by: Olof Johansson commit 5c3da57d70f1ef1d9b60900b84a74d77a9cf0774 Author: Joshua Houghton Date: Sat Jun 18 15:46:31 2016 +0000 net: rds: fix coding style issues Fix coding style issues in the following files: ib_cm.c: add space loop.c: convert spaces to tabs sysctl.c: add space tcp.h: convert spaces to tabs tcp_connect.c:remove extra indentation in switch statement tcp_recv.c: convert spaces to tabs tcp_send.c: convert spaces to tabs transport.c: move brace up one line on for statement Signed-off-by: Joshua Houghton Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/ib_cm.c | 2 +- net/rds/loop.c | 5 +++-- net/rds/sysctl.c | 3 ++- net/rds/tcp.h | 2 +- net/rds/tcp_connect.c | 26 +++++++++++++------------- net/rds/tcp_recv.c | 2 +- net/rds/tcp_send.c | 14 +++++++------- net/rds/transport.c | 3 +-- 8 files changed, 29 insertions(+), 28 deletions(-) commit 4a7d99ea1b27734558feb6833f180cd38a159940 Author: Basil Gunn Date: Thu Jun 16 09:42:30 2016 -0700 AX.25: Close socket connection on session completion A socket connection made in ax.25 is not closed when session is completed. The heartbeat timer is stopped prematurely and this is where the socket gets closed. Allow heatbeat timer to run to close socket. Symptom occurs in kernels >= 4.2.0 Originally sent 6/15/2016. Resend with distribution list matching scripts/maintainer.pl output. Signed-off-by: Basil Gunn Signed-off-by: David S. Miller net/ax25/af_ax25.c | 3 ++- net/ax25/ax25_ds_timer.c | 5 ++++- net/ax25/ax25_std_timer.c | 5 ++++- net/ax25/ax25_subr.c | 3 ++- 4 files changed, 12 insertions(+), 4 deletions(-) commit 30172936eefb70c27fade1bc912a25fc90827b76 Author: Pali Rohár Date: Sat Jun 18 17:47:38 2016 -0700 MAINTAINERS: add Pali Rohár as reviewer of ALPS PS/2 touchpad driver Signed-off-by: Pali Rohár Signed-off-by: Dmitry Torokhov MAINTAINERS | 4 ++++ 1 file changed, 4 insertions(+) commit c141afd1a28793c08c88325aa64b773be6f79ccf Merge: e80dac1 56530f5 Author: Linus Torvalds Date: Sat Jun 18 15:20:15 2016 -1000 Merge branch 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm Pull ARM fixes from Russell King: "A couple of fixes for pmd_mknotpresent()/pmd_present() for LPAE systems" * 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm: ARM: 8579/1: mm: Fix definition of pmd_mknotpresent ARM: 8578/1: mm: ensure pmd_present only checks the valid bit commit 6ea24cf79e055f0a62a64baa8587e2254a493c7b Merge: 540c260 4883269 Author: Dmitry Torokhov Date: Sat Jun 18 17:25:08 2016 -0700 Merge branch 'cec-defines' into for-linus Let's bring in HDMI CEC defines to ease merging CEC support in the next merge window. commit 2744d2fde00dc8bcc3679eb72c81a63058e90faa Author: Pali Rohár Date: Sat Jun 18 00:54:46 2016 +0200 hwmon: (dell-smm) Disallow fan_type() calls on broken machines Some Dell machines have especially broken SMM or BIOS which cause that once fan_type() is called then CPU fan speed going randomly up and down. And for fixing this behaviour reboot is required. So this patch creates fan_type blacklist of affected Dell machines and disallow fan_type() call on them to prevent that erratic behaviour. Old blacklist which disabled loading driver on some machines added in commits a4b45b25f18d ("hwmon: (dell-smm) Blacklist Dell Studio XPS 8100") and 6220f4ebd7b4 ("hwmon: (dell-smm) Blacklist Dell Studio XPS 8000") were moved to FAN_TYPE blacklist. Reported-by: Jan C Peters Signed-off-by: Pali Rohár Link: https://bugzilla.kernel.org/show_bug.cgi?id=100121 Cc: stable@vger.kernel.org # v4.0+, will need backport Signed-off-by: Guenter Roeck drivers/hwmon/dell-smm-hwmon.c | 36 +++++++++++++++++++++++++----------- 1 file changed, 25 insertions(+), 11 deletions(-) commit 7613663cc186f8f3c50279390ddc60286758001c Author: Pali Rohár Date: Sat Jun 18 00:54:45 2016 +0200 hwmon: (dell-smm) Restrict fan control and serial number to CAP_SYS_ADMIN by default For security reasons ordinary user must not be able to control fan speed via /proc/i8k by default. Some malicious software running under "nobody" user could be able to turn fan off and cause HW problems. So this patch changes default value of "restricted" parameter to 1. Also restrict reading of DMI_PRODUCT_SERIAL from /proc/i8k via "restricted" parameter. It is because non root user cannot read DMI_PRODUCT_SERIAL from sysfs file /sys/class/dmi/id/product_serial. Old non secure behaviour of file /proc/i8k can be achieved by loading this module with "restricted" parameter set to 0. Note that this patch has effects only for kernels compiled with CONFIG_I8K and only for file /proc/i8k. Hwmon interface provided by this driver was not changed and root access for setting fan speed was needed also before. Reported-by: Mario Limonciello Signed-off-by: Pali Rohár Cc: stable@vger.kernel.org # will need backport Signed-off-by: Guenter Roeck drivers/hwmon/dell-smm-hwmon.c | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) commit 053ea640818812313892ec4f370f5cfac42fd355 Author: Pali Rohár Date: Sat Jun 18 00:54:44 2016 +0200 hwmon: (dell-smm) Fail in ioctl I8K_BIOS_VERSION when bios version is not a number ABI of I8K_BIOS_VERSION ioctl can return only number. But new BIOS versions contain also other characters, which does not fit into that ABI. So in case of non digit values return -EINVAL. Reported-by: Mario Limonciello Signed-off-by: Pali Rohár Signed-off-by: Guenter Roeck drivers/hwmon/dell-smm-hwmon.c | 5 +++++ 1 file changed, 5 insertions(+) commit 951d77fd5a541d68eeb7372e72cd4757e3058517 Merge: 27ea13e 8beb330 Author: James Bottomley Date: Sat Jun 18 11:59:01 2016 -0700 Merge remote-tracking branch 'mkp-scsi/4.7/scsi-fixes' into fixes commit 488326947cd1f038da8d2c9068a0d07b913b7983 Author: Kamil Debski Date: Sat Jun 18 10:10:56 2016 -0700 Input: add HDMI CEC specific keycodes Add HDMI CEC specific keycodes to the keycodes definition. Signed-off-by: Kamil Debski Signed-off-by: Hans Verkuil Signed-off-by: Dmitry Torokhov include/uapi/linux/input-event-codes.h | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 3720b69bafe9ccb989b9a8604f3e3f89b3610685 Author: Hans Verkuil Date: Sat Jun 18 10:10:26 2016 -0700 Input: add BUS_CEC type Inputs can come in over the HDMI CEC bus, so add a new type for this. Signed-off-by: Hans Verkuil Signed-off-by: Dmitry Torokhov include/uapi/linux/input.h | 1 + 1 file changed, 1 insertion(+) commit d4f56c7773483b8829e89cfc739b7a5a071f6da0 Author: Sricharan R Date: Fri Jun 10 23:38:20 2016 +0530 i2c: qup: Fix wrong value of index variable index gets incremented during check to determine if the messages can be transferred with dma. But not reset after that, resulting in wrong start value in subsequent loop, causing failure. Fix it. Signed-off-by: Sricharan R Signed-off-by: Wolfram Sang Cc: stable@kernel.org drivers/i2c/busses/i2c-qup.c | 2 ++ 1 file changed, 2 insertions(+) commit e80dac114c63dd54398c3c785a6431622c320e87 Merge: a50094a 083d5ad Author: Linus Torvalds Date: Sat Jun 18 06:06:49 2016 -1000 Merge tag 'usb-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Pull USB fixes from Greg KH: "Here are a bunch (65) of USB fixes for 4.7-rc4. Sorry about the quantity, I've been slow in getting these out. The majority are the "normal" gadget, musb, and xhci fixes, that we all are used to. There are also a few other tiny fixes resolving a number of reported issues that showed up in 4.7-rc1. All of these have been in linux-next" * tag 'usb-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (65 commits) usbip: rate limit get_frame_number message usb: musb: sunxi: Remove bogus "Frees glue" comment usb: musb: sunxi: Fix NULL ptr deref when gadget is registered before musb usb: echi-hcd: Add ehci_setup check before echi_shutdown usb: host: ehci-msm: Conditionally call ehci suspend/resume MAINTAINERS: Add file patterns for usb device tree bindings usb: host: ehci-tegra: Avoid getting the same reset twice usb: host: ehci-tegra: Grab the correct UTMI pads reset USB: mos7720: delete parport USB: OHCI: Don't mark EDs as ED_OPER if scheduling fails phy: ti-pipe3: Program the DPLL even if it was already locked usb: musb: Stop bulk endpoint while queue is rotated usb: musb: Ensure rx reinit occurs for shared_fifo endpoints usb: musb: host: correct cppi dma channel for isoch transfer usb: musb: only restore devctl when session was set in backup usb: phy: Check initial state for twl6030 usb: musb: Use normal module_init for 2430 glue usb: musb: Remove pm_runtime_set_irq_safe usb: musb: Remove extra PM runtime calls from 2430 glue layer usb: musb: Return error value from musb_mailbox ... commit a50094a4813443a7ca605f86019061905ba697c4 Merge: 607117a bc8201e Author: Linus Torvalds Date: Sat Jun 18 06:05:28 2016 -1000 Merge tag 'staging-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull IIO and staging fixes from Greg KH: "Here are a number of IIO and staging bugfixes for 4.7-rc4. Nothing huge, the normal amount of iio driver fixes, and some small staging driver bugfixes for some reported problems (2 are reverts of patches that went into 4.7-rc1). All have been in linux-next with no reported issues" * tag 'staging-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (24 commits) Revert "Staging: rtl8188eu: rtw_efuse: Use sizeof type *pointer instead of sizeof type." Revert "Staging: drivers: rtl8188eu: use sizeof(*ptr) instead of sizeof(struct)" staging: lustre: lnet: Don't access NULL NI on failure path iio: hudmidity: hdc100x: fix incorrect shifting and scaling iio: light apds9960: Add the missing dev.parent iio: Fix error handling in iio_trigger_attach_poll_func iio: st_sensors: Disable DRDY at init time iio: st_sensors: Init trigger before irq request iio: st_sensors: switch to a threaded interrupt iio: light: bh1780: assign a static name iio: bh1780: dereference the client properly iio: humidity: hdc100x: fix IIO_TEMP channel reporting iio:st_pressure: fix sampling gains (bring inline with ABI) iio: proximity: as3935: fix buffer stack trashing iio: proximity: as3935: remove triggered buffer processing iio: proximity: as3935: correct IIO_CHAN_INFO_RAW output max44000: Remove scale from proximity iio: humidity: am2315: Remove a stray unlock iio: humidity: hdc100x: correct humidity integration time mask iio: pressure: bmp280: fix error message for wrong chip id ... commit 607117a1533d8ef41b34aa170363ae4415b3d524 Merge: 07b5ca2 5e25db8 Author: Linus Torvalds Date: Sat Jun 18 06:04:01 2016 -1000 Merge tag 'driver-core-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core Pull driver core fixes from Greg KH: "Here are a small number of debugfs, ISA, and one driver core fix for 4.7-rc4. All of these resolve reported issues. The ISA ones have spent the least amount of time in linux-next, sorry about that, I didn't realize they were regressions that needed to get in now (thanks to Thorsten for the prodding!) but they do all pass the 0-day bot tests. The others have been in linux-next for a while now. Full details about them are in the shortlog below" * tag 'driver-core-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: isa: Dummy isa_register_driver should return error code isa: Call isa_bus_init before dependent ISA bus drivers register watchdog: ebc-c384_wdt: Allow build for X86_64 iio: stx104: Allow build for X86_64 gpio: Allow PC/104 devices on X86_64 isa: Allow ISA-style drivers on modern systems base: make module_create_drivers_dir race-free debugfs: open_proxy_open(): avoid double fops release debugfs: full_proxy_open(): free proxy on ->open() failure kernel/kcov: unproxify debugfs file's fops commit 07b5ca22a1e6268c5193f9606ad5b746853ace40 Merge: 4c6459f 5014e90 Author: Linus Torvalds Date: Sat Jun 18 06:02:37 2016 -1000 Merge tag 'char-misc-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc Pull char/misc driver fixes from Greg KH: "Here are a small number of char and misc driver fixes for 4.7-rc4. They resolve some minor issues that have been reported, and have all been in linux-next" * tag 'char-misc-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: coresight: Handle build path error coresight: Fix erroneous memset in tmc_read_unprepare_etr coresight: Fix tmc_read_unprepare_etr coresight: Fix NULL pointer dereference in _coresight_build_path extcon: palmas: Fix boot up state of VBUS when using GPIO detection mcb: Acquire reference to carrier module in core mcb: Acquire reference to device in probe mei: don't use wake_up_interruptible for wr_ctrl commit 4c6459f945c7c64123c4aec0667d196090213d53 Merge: d9e6614 de18c16 Author: Linus Torvalds Date: Sat Jun 18 05:57:59 2016 -1000 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs fixes from Chris Mason: "The most user visible change here is a fix for our recent superblock validation checks that were causing problems on non-4k pagesized systems" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: btrfs_check_super_valid: Allow 4096 as stripesize btrfs: remove build fixup for qgroup_account_snapshot btrfs: use new error message helper in qgroup_account_snapshot btrfs: avoid blocking open_ctree from cleaner_kthread Btrfs: don't BUG_ON() in btrfs_orphan_add btrfs: account for non-CoW'd blocks in btrfs_abort_transaction Btrfs: check if extent buffer is aligned to sectorsize btrfs: Use correct format specifier commit d9e66146c1da8e771378b078b958057024d8f604 Merge: 057868e 46577e6 Author: Linus Torvalds Date: Fri Jun 17 20:22:37 2016 -1000 Merge tag 'acpi-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fix from Rafael Wysocki: "Revert a recent ACPICA commit that introduced a suspend-to-RAM regression on one system due to incorrect information in its ACPI tables that had not been taken into consideration at all before (and everything worked), but the commit in question started to use it" * tag 'acpi-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: Revert "ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write()" commit 057868ea15bf93912925c4843c65dbaf305c60ed Merge: 6be28d3 9d066a2 Author: Linus Torvalds Date: Fri Jun 17 20:08:00 2016 -1000 Merge tag 'pm-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "Fixes for two recent regressions that may lead to degraded performance (operating performance points framework, intel_pstate). Specifics: - Fix a recent regression in the intel_pstate driver that may lead to degraded performance on some systems due to missing turbo state entry in the table returned by the ACPI _PSS object (Srinivas Pandruvada). - Fix a recent regression in the OPP (operating performance points) framework that may lead to degraded performance on some systems where the OPP table is created too early (Viresh Kumar)" * tag 'pm-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PM / OPP: Add 'UNKNOWN' status for shared_opp in struct opp_table cpufreq: intel_pstate: Adjust _PSS[0] freqeuency if needed commit 3bb549ae4c51028c1930528ae9fcd6eca0474724 Author: Sowmini Varadhan Date: Fri Jun 17 16:12:12 2016 -0400 RDS: TCP: rds_tcp_accept_one() should transition socket from RESETTING to UP The state of the rds_connection after rds_tcp_reset_callbacks() would be RDS_CONN_RESETTING and this is the value that should be passed by rds_tcp_accept_one() to rds_connect_path_complete() to transition the socket to RDS_CONN_UP. Fixes: b5c21c0947c1 ("RDS: TCP: fix race windows in send-path quiescence by rds_tcp_accept_one()") Signed-off-by: Sowmini Varadhan Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/tcp_listen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a9836cbb5fc885d3b8f3b91b2d47525f7269dec1 Author: Arnd Bergmann Date: Fri Jun 17 18:15:30 2016 +0200 net: tilegx: use correct timespec64 type The conversion to the 64-bit time based ptp methods left two instances of 'struct timespec' in place. This is harmless because 64-bit architectures define timespec64 as timespec, and this driver is not used on 32-bit machines. However, using 'struct timespec64' directly is obviously the right thing to do, and will help us remove 'struct timespec' in the future. Signed-off-by: Arnd Bergmann Fixes: b9acf24f779c ("ptp: tilegx: convert to the 64 bit get/set time methods.") Acked-by: Richard Cochran Signed-off-by: David S. Miller drivers/net/ethernet/tile/tilegx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6be28d33874998e1523df818173dacfed180b792 Merge: 9cbbef4 a80e803 Author: Linus Torvalds Date: Fri Jun 17 19:27:12 2016 -1000 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid Pull HID subsystem fixes from Jiri Kosina: - kernel panic fix in hid-elo from Oliver Neukum - Surface Pro 3 device quirk from Benjamin Tissoires * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid: HID: multitouch: Add MT_QUIRK_NOT_SEEN_MEANS_UP to Surface Pro 3 HID: elo: kill not flush the work commit b47ac27a1dbebc559156f92a0807dc957bb12731 Merge: f1d048f 4e239fa Author: David S. Miller Date: Fri Jun 17 21:57:54 2016 -0700 Merge branch 'mlxsw-fixes' Jiri Pirko says: ==================== mlxsw: couple of fixes Couple of slowpath tx stats fixes for Spectrum and SwitchX-2. ==================== Signed-off-by: David S. Miller commit 4e239fac7c6b9d703e83c81b52ec9fec00c50129 Author: Nogah Frankel Date: Fri Jun 17 15:09:06 2016 +0200 mlxsw: switchx2: Don't count internal TX header bytes to stats Stop the SW TX counter from counting the TX header bytes since they are not being sent out. Fixes: e577516b9db3 ("mlxsw: Fix use-after-free bug in mlxsw_sx_port_xmit") Signed-off-by: Nogah Frankel Reviewed-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/switchx2.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 63dcdd35c1552ca0c911e98ba3389a0729a457f4 Author: Nogah Frankel Date: Fri Jun 17 15:09:05 2016 +0200 mlxsw: spectrum: Don't count internal TX header bytes to stats Stop the SW TX counter from counting the TX header bytes since they are not being sent out. Fixes: 56ade8fe3fe1 ("mlxsw: spectrum: Add initial support for Spectrum ASIC") Reviewed-by: Ido Schimmel Signed-off-by: Nogah Frankel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit f1d048f24e66ba85d3dabf3d076cefa5f2b546b0 Author: Jon Paul Maloy Date: Fri Jun 17 06:35:57 2016 -0400 tipc: fix socket timer deadlock We sometimes observe a 'deadly embrace' type deadlock occurring between mutually connected sockets on the same node. This happens when the one-hour peer supervision timers happen to expire simultaneously in both sockets. The scenario is as follows: CPU 1: CPU 2: -------- -------- tipc_sk_timeout(sk1) tipc_sk_timeout(sk2) lock(sk1.slock) lock(sk2.slock) msg_create(probe) msg_create(probe) unlock(sk1.slock) unlock(sk2.slock) tipc_node_xmit_skb() tipc_node_xmit_skb() tipc_node_xmit() tipc_node_xmit() tipc_sk_rcv(sk2) tipc_sk_rcv(sk1) lock(sk2.slock) lock((sk1.slock) filter_rcv() filter_rcv() tipc_sk_proto_rcv() tipc_sk_proto_rcv() msg_create(probe_rsp) msg_create(probe_rsp) tipc_sk_respond() tipc_sk_respond() tipc_node_xmit_skb() tipc_node_xmit_skb() tipc_node_xmit() tipc_node_xmit() tipc_sk_rcv(sk1) tipc_sk_rcv(sk2) lock((sk1.slock) lock((sk2.slock) ===> DEADLOCK ===> DEADLOCK Further analysis reveals that there are three different locations in the socket code where tipc_sk_respond() is called within the context of the socket lock, with ensuing risk of similar deadlocks. We now solve this by passing a buffer queue along with all upcalls where sk_lock.slock may potentially be held. Response or rejected message buffers are accumulated into this queue instead of being sent out directly, and only sent once we know we are safely outside the slock context. Reported-by: GUNA Acked-by: Ying Xue Signed-off-by: Jon Maloy Signed-off-by: David S. Miller net/tipc/socket.c | 54 ++++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 42 insertions(+), 12 deletions(-) commit 5e25db870ec983be138b343a3d04c79a5c1f1703 Author: William Breathitt Gray Date: Mon May 9 09:39:50 2016 -0400 isa: Dummy isa_register_driver should return error code The inline isa_register_driver stub simply allows compilation on systems with CONFIG_ISA disabled; the dummy isa_register_driver does not register an isa_driver at all. The inline isa_register_driver should return -ENODEV to indicate lack of support when attempting to register an isa_driver on such a system with CONFIG_ISA disabled. Cc: Matthew Wilcox Reported-by: Sasha Levin Tested-by: Ye Xiaolong Signed-off-by: William Breathitt Gray Signed-off-by: Greg Kroah-Hartman include/linux/isa.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 32a5a0c047343b11f581f663a2309cf43d13466f Author: William Breathitt Gray Date: Wed May 11 17:01:40 2016 -0400 isa: Call isa_bus_init before dependent ISA bus drivers register The isa_bus_init function must be called before drivers which utilize the ISA bus driver are registered. A race condition for initilization exists if device_initcall is used (the isa_bus_init callback is placed in the same initcall level as dependent drivers which use module_init). This patch ensures that isa_bus_init is called first by utilizing postcore_initcall in favor of device_initcall. Fixes: a5117ba7da37 ("[PATCH] Driver model: add ISA bus") Cc: Rene Herman Signed-off-by: William Breathitt Gray Signed-off-by: Greg Kroah-Hartman drivers/base/isa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b87b8ff760d51b33b4e23d7f3a42ded55a668735 Author: William Breathitt Gray Date: Fri May 27 18:09:27 2016 -0400 watchdog: ebc-c384_wdt: Allow build for X86_64 With the introduction of the ISA_BUS_API Kconfig option, ISA-style drivers may be built for X86_64 architectures. This patch changes the ISA Kconfig option dependency of the WinSystems EBC-C384 watchdog timer driver to ISA_BUS_API, thus allowing it to build for X86_64 as it is expected to. Cc: Wim Van Sebroeck Reviewed-by: Guenter Roeck Signed-off-by: William Breathitt Gray Signed-off-by: Greg Kroah-Hartman drivers/watchdog/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 75897b7c5ee9f9a23ec7863d4f8758bc041ba656 Author: William Breathitt Gray Date: Fri May 27 18:09:08 2016 -0400 iio: stx104: Allow build for X86_64 With the introduction of the ISA_BUS_API Kconfig option, ISA-style drivers may be built for X86_64 architectures. This patch changes the ISA Kconfig option dependency of the Apex Embedded Systems STX104 DAC driver to ISA_BUS_API, thus allowing it to build for X86_64 as it is expected to. Cc: Hartmut Knaack Cc: Lars-Peter Clausen Cc: Peter Meerwald-Stadler Reviewed-by: Guenter Roeck Signed-off-by: William Breathitt Gray Acked-by: Jonathan Cameron Signed-off-by: Greg Kroah-Hartman drivers/iio/dac/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f4ae916912b4969916ebb275995c745b01cb432c Author: William Breathitt Gray Date: Fri May 27 18:08:56 2016 -0400 gpio: Allow PC/104 devices on X86_64 With the introduction of the ISA_BUS_API Kconfig option, ISA-style drivers may be built for X86_64 architectures. This patch changes the ISA Kconfig option dependency of the PC/104 drivers to ISA_BUS_API, thus allowing them to build for X86_64 as they are expected to. Cc: Alexandre Courbot Reviewed-by: Guenter Roeck Signed-off-by: William Breathitt Gray Acked-by: Linus Walleij Signed-off-by: Greg Kroah-Hartman drivers/gpio/Kconfig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3a4955111ad46a022f05b51f91306d864f989625 Author: William Breathitt Gray Date: Fri May 27 18:08:27 2016 -0400 isa: Allow ISA-style drivers on modern systems Several modern devices, such as PC/104 cards, are expected to run on modern systems via an ISA bus interface. Since ISA is a legacy interface for most modern architectures, ISA support should remain disabled in general. Support for ISA-style drivers should be enabled on a per driver basis. To allow ISA-style drivers on modern systems, this patch introduces the ISA_BUS_API and ISA_BUS Kconfig options. The ISA bus driver will now build conditionally on the ISA_BUS_API Kconfig option, which defaults to the legacy ISA Kconfig option. The ISA_BUS Kconfig option allows the ISA_BUS_API Kconfig option to be selected on architectures which do not enable ISA (e.g. X86_64). The ISA_BUS Kconfig option is currently only implemented for X86 architectures. Other architectures may have their own ISA_BUS Kconfig options added as required. Reviewed-by: Guenter Roeck Signed-off-by: William Breathitt Gray Acked-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman arch/Kconfig | 3 +++ arch/x86/Kconfig | 9 +++++++++ drivers/base/Makefile | 2 +- include/linux/isa.h | 2 +- 4 files changed, 14 insertions(+), 2 deletions(-) commit 695ef16cd0510f3bc963967fd73a360989fe4ebf Merge: ce449ba 1463847 Author: David S. Miller Date: Fri Jun 17 19:50:04 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf Pablo Neira Ayuso says: ==================== Netfilter fixes for net The following patchset contains Netfilter fixes for your net tree, they are rather small patches but fixing several outstanding bugs in nf_conntrack and nf_tables, as well as minor problems with missing SYNPROXY header uapi installation: 1) Oneliner not to leak conntrack kmemcache on module removal, this problem was introduced in the previous merge window, patch from Florian Westphal. 2) Two fixes for insufficient ruleset loop validation, one due to incorrect flag check in nf_tables_bind_set() and another related to silly wrong generation mask logic from the walk path, from Liping Zhang. 3) Fix double-free of anonymous sets on error, this fix simplifies the code to let the abort path take care of releasing the set object, also from Liping Zhang. 4) The introduction of helper function for transactions broke the skip inactive rules logic from the nft_do_chain(), again from Liping Zhang. 5) Two patches to install uapi xt_SYNPROXY.h header and calm down kbuild robot due to missing #include . ==================== Signed-off-by: David S. Miller commit 083d5ad1a924e79ecf92be37cce9f1efa5c1d240 Author: Greg Kroah-Hartman Date: Tue Jun 14 13:41:07 2016 -0700 usbip: rate limit get_frame_number message It's annoying to constantly see the same "Not yet implemented" message over and over with nothing able to be done about it, so rate limit it for now to keep user's logs "clean". Reported-by: Lars Täuber Tested-by: Lars Täuber Signed-off-by: Greg Kroah-Hartman drivers/usb/usbip/vhci_hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 34d351f8ddf6dee24d739c4b00a4404e48089a04 Author: Sebastian Sanchez Date: Thu Jun 9 07:52:03 2016 -0700 IB/hfi1: Send a pkey change event on driver pkey update Swapping a cable from a "Mgmt Allowed=No" switch port to a "Mgmt Allowed=Yes" switch port doesn't send a pkey change notification. Therefore, the link doesn't become active as the oib_utils layer uses an old pkey table cache. Fix by ensuring the pkey change notification is sent when the table is changed both explicitly by the FM and implicitly by the driver via a cable swap. Reviewed-by: Mike Marciniszyn Signed-off-by: Sebastian Sanchez Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/chip.c | 2 ++ drivers/infiniband/hw/hfi1/mad.c | 19 ++++++++++++------- drivers/infiniband/hw/hfi1/mad.h | 2 ++ 3 files changed, 16 insertions(+), 7 deletions(-) commit 3ec5fa28c9ea54fb172859d2612a0be6526e4dc1 Author: Sebastian Sanchez Date: Thu Jun 9 07:51:57 2016 -0700 IB/hfi1: Remove FULL_MGMT_P_KEY from pkey table at link up FULL_MGMT_P_KEY doesn't get cleared from the pkey table at link bounce because the link down and link bounce code paths are different when moving a QSFP cable on a switch. This causes an HFI unit connected to a switch to try to be initialized to an FM node when the QSFP cable is moved from a MgmtAllowed=NO port to a MgmtAllowed=YES port and back to a MgmtAllowed=NO port. Remove FULL_MGMT_P_KEY from pkey table at link up. Reviewed-by: Dean Luick Signed-off-by: Sebastian Sanchez Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/chip.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) commit c078f0dd01b73c70b92a660cb1ce3dfc3cbf2903 Author: Tadeusz Struk Date: Thu Jun 9 07:51:51 2016 -0700 IB/hfi1: Fix potential buffer overflow This fixes potential buffer overflow because the sprintf function doesn't check buffer boundaries. Use snprintf instead. Reviewed-by: Dennis Dalessandro Signed-off-by: Tadeusz Struk Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/qsfp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 93dd0a097859a174817ea94ec55bfc29c5706454 Author: Tadeusz Struk Date: Thu Jun 9 07:51:45 2016 -0700 IB/hfi1: Fix potential NULL ptr dereference This fixes potential NULL ptr dereference because IS_ERR(dd) doesn't handle NULL. Fix the issue by initializing the pointer with a not NULL error code. Reviewed-by: Dennis Dalessandro Signed-off-by: Tadeusz Struk Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5e9ef24619486213223053678eb9175630ef6bf9 Author: Ira Weiny Date: Thu Jun 9 07:51:39 2016 -0700 IB/qib: Prevent context loss If a context has already been assigned to an FD, prevent another assignment. Reviewed-by: Dennis Dalessandro Signed-off-by: Ira Weiny Signed-off-by: Doug Ledford drivers/infiniband/hw/qib/qib_file_ops.c | 5 +++++ 1 file changed, 5 insertions(+) commit ca2f30a0a6786e6b08eeb8abb2bbb8df58709d6e Author: Ira Weiny Date: Thu Jun 9 07:51:33 2016 -0700 IB/hfi1: Prevent context loss If a context has already been assigned to an FD, prevent another assignment. Reviewed-by: Dennis Dalessandro Signed-off-by: Ira Weiny Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/file_ops.c | 3 +++ 1 file changed, 3 insertions(+) commit c3c64a951cbdb6096d02dcc339a9c807ce1e976a Author: Jubin John Date: Thu Jun 9 07:51:27 2016 -0700 IB/hfi1: Increase packet egress timeout The current value of 500us for the packet egress timeout is too small which causes the host to declare failure on draining packets too early and unnecessarily bounces the link. Increase this to 50ms taking into account the switch packet discard timer default and the worst case per-VL package drainage rate. Reviewed-by: Dean Luick Signed-off-by: Jubin John Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/pio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 501edc42446e89fa67fb6ef2c9afb50792c310c0 Author: Brian Welty Date: Thu Jun 9 07:51:20 2016 -0700 IB/rdmavt: Correct warning during QPN allocation Correct calculation of the low order bits which should be unset based on use of qos_shift parameter when assigning QPN. Reviewed-by: Dennis Dalessandro Signed-off-by: Brian Welty Signed-off-by: Doug Ledford drivers/infiniband/sw/rdmavt/qp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 96605672a4172f6e31f31ce29ee27fef68011de0 Author: Brian Welty Date: Thu Jun 9 07:51:14 2016 -0700 IB/rdmavt: Correct required callback functions for MODIFY_QP Functions required for MODIFY_PORT were incorrectly being required for MODIFY_QP. Reviewed-by: Dennis Dalessandro Signed-off-by: Brian Welty Signed-off-by: Doug Ledford drivers/infiniband/sw/rdmavt/vt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit b4ba6633ea153266429f16614029ab1578815390 Author: Jubin John Date: Thu Jun 9 07:51:08 2016 -0700 IB/hfi1: Fix credit return threshold adjustment The credit return threshold adjustment on mtu change algorithm does not take into account all the kernel send contexts that are assigned per VL. Use the pio send context map to adjust the credit return thresholds for all the allocated and assigned kernel send contexts based on the MTU adjustment per VL. The pio send context map can be changed dynamically based on the actual number of operational vls which is set by the fabric manager. When this happens update the credit return threshold values for all the remapped kernel send contexts. Reviewed-by: Dennis Dalessandro Reviewed-by: Mike Marciniszyn Reviewed-by: Jianxin Xiong Signed-off-by: Jubin John Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/chip.c | 7 +++++-- drivers/infiniband/hw/hfi1/pio.c | 24 ++++++++++++++++++++++-- 2 files changed, 27 insertions(+), 4 deletions(-) commit 37e07cdafc111dfb7ce27e70e73d900d7cf2920c Author: Bart Van Assche Date: Fri Jun 10 11:08:25 2016 -0700 IB/cma: Make the code easier to verify Static source code analysis tools like smatch cannot handle functions that lock or not lock a mutex depending on the value of the arguments. Hence inline the function cma_disable_callback(). Additionally, this patch realizes a small performance optimization by reducing the number of mutex_lock() and mutex_unlock() calls in the modified functions. With this patch applied smatch no longer complains about source file cma.c. Without this patch smatch reports the following for this source file: drivers/infiniband/core/cma.c:1959: cma_req_handler() warn: inconsistent returns 'mutex:&listen_id->handler_mutex'. Locked on: line 1880 line 1959 Unlocked on: line 1941 drivers/infiniband/core/cma.c:2112: iw_conn_req_handler() warn: inconsistent returns 'mutex:&listen_id->handler_mutex'. Locked on: line 2048 Unlocked on: line 2112 Signed-off-by: Bart Van Assche Cc: Sean Hefty Cc: Steve Wise Cc: Leon Romanovsky Acked-by: Sean Hefty Reviewed-by: Steve Wise Reviewed-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/cma.c | 54 +++++++++++++++++++++---------------------- 1 file changed, 26 insertions(+), 28 deletions(-) commit 46577e6a052ff5add7577ac748fb8628b3c3c7c9 Merge: 5edb564 da4e792 Author: Rafael J. Wysocki Date: Sat Jun 18 01:55:55 2016 +0200 Merge branch 'acpica-fixes' * acpica-fixes: Revert "ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write()" commit 9d066a252786e1a18484a6283f82614d42a9f4ac Merge: 79ee2e8 b00345d Author: Rafael J. Wysocki Date: Sat Jun 18 01:55:13 2016 +0200 Merge branches 'pm-opp' and 'pm-cpufreq-fixes' * pm-opp: PM / OPP: Add 'UNKNOWN' status for shared_opp in struct opp_table * pm-cpufreq-fixes: cpufreq: intel_pstate: Adjust _PSS[0] freqeuency if needed commit 8c5122e45a10a9262f872b53f151a592e870f905 Author: Jason Gunthorpe Date: Wed Jun 8 17:28:29 2016 -0600 IB/mlx4: Properly initialize GRH TClass and FlowLabel in AHs When this code was reworked for IBoE support the order of assignments for the sl_tclass_flowlabel got flipped around resulting in TClass & FlowLabel being permanently set to 0 in the packet headers. This breaks IB routers that rely on these headers, but only affects kernel users - libmlx4 does this properly for user space. Cc: stable@vger.kernel.org Fixes: fa417f7b520e ("IB/mlx4: Add support for IBoE") Signed-off-by: Jason Gunthorpe Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/ah.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0b10029d826ed8c18a5f9d2f4abfa415d15cd1d3 Author: Alex Deucher Date: Fri Jun 17 10:17:17 2016 -0400 drm/amdgpu: fix num_rbs exposed to userspace (v2) This was accidently broken for harvest cards when the code was refactored for Polaris support. v2: multiply by shader engines. Noticed by Nicolai. Reviewed-by: Nicolai Hähnle Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit bc8201e3e1885614a5cd3a5f70a79d08f99152fd Author: Hans de Goede Date: Sun Jun 5 21:01:19 2016 +0200 Revert "Staging: rtl8188eu: rtw_efuse: Use sizeof type *pointer instead of sizeof type." This reverts commit b5e12ec38331 ("Staging: rtl8188eu: rtw_efuse: Use sizeof type *pointer instead of sizeof type."). This commit is wrong, the rtw_malloc2d helper function takes the size of the array elements as its 3th argument, whereas sizeof(*eFuseWord) gives the size of a pointer instead of the size of a u16. Since sizeof(void *) > sizeof(u16) this has no adverse effects, but it is still wrong. Cc: Sandhya Bankar Signed-off-by: Hans de Goede Signed-off-by: Greg Kroah-Hartman drivers/staging/rtl8188eu/core/rtw_efuse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6982f867e058f0c6c8d3eeb4ef305efd7d7f4c8c Author: Hans de Goede Date: Sun Jun 5 21:01:18 2016 +0200 Revert "Staging: drivers: rtl8188eu: use sizeof(*ptr) instead of sizeof(struct)" This reverts commit 99aded71b52c ("Staging: drivers: rtl8188eu: use sizeof(*ptr) instead of sizeof(struct)"). This commit is wrong, as adapt->HalData has a type of "void *", so now we are allocating a much to small struct, which causes the driver to overwrite random memory which leads to a non working driver and various system crashes. Cc: Jacky Boen Signed-off-by: Hans de Goede Signed-off-by: Greg Kroah-Hartman drivers/staging/rtl8188eu/hal/usb_halinit.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 041bf0225552044b85ce7ee7981e790d987d6ceb Author: Dan Carpenter Date: Thu Jun 16 11:30:23 2016 +0300 drm/amdgpu: missing bounds check in amdgpu_set_pp_force_state() There is no limit on high "idx" can go. It should be less than ARRAY_SIZE(data.states) which is 16. The "data" variable wasn't declared in that scope so I shifted the code around a bit to make it work. Also I made "idx" unsigned. Fixes: f3898ea12fc1 ('drm/amd/powerplay: add some sysfs interfaces for powerplay.') Acked-by: Christian König Signed-off-by: Dan Carpenter Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) commit 9cbbef4efb7cfb6962da57c9e17f5ce4280c14ca Merge: 8c25615 0d15ef6 Author: Linus Torvalds Date: Fri Jun 17 07:19:13 2016 -1000 Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 fixes from Will Deacon: "The main things are getting kgdb up and running with upstream GDB after a protocol change was reverted and fixing our spin_unlock_wait and spin_is_locked implementations after doing some similar work with PeterZ on the qspinlock code last week. Whilst we haven't seen any failures in practice, it's still worth getting this fixed. Summary: - Plug the ongoing spin_unlock_wait/spin_is_locked mess - KGDB protocol fix to sync w/ GDB - Fix MIDR-based PMU probing for old 32-bit SMP systems (OMAP4/Realview) - Minor tweaks to the fault handling path" * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: kgdb: Match pstate size with gdbserver protocol arm64: spinlock: Ensure forward-progress in spin_unlock_wait arm64: spinlock: fix spin_unlock_wait for LSE atomics arm64: spinlock: order spin_{is_locked,unlock_wait} against local locks arm: pmu: Fix non-devicetree probing arm64: mm: mark fault_info table const arm64: fix dump_instr when PAN and UAO are in use commit 8c2561557415a298965f50d4de2ca99c7d1f1b2c Merge: 7af9a17 a4c34ff Author: Linus Torvalds Date: Fri Jun 17 07:15:43 2016 -1000 Merge tag 'iommu-fixes-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu Pull IOMMU fixes from Joerg Roedel: "Three patches queued up: - Fix for ARM-SMMU to add a missing iommu-ops callback which is required by common iommu code - Fix for the rockchip iommu where the wrong MMUs got the commands - A regression fix for the Intel VT-d driver. The regression only showed up on X58 chipsets with more than one iommu. These chipsets seem to require that QI is enabled on all IOMMUs before it can be used" * tag 'iommu-fixes-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu: iommu/vt-d: Enable QI on all IOMMUs before setting root entry iommu/rockchip: Fix zap cache during device attach iommu/arm-smmu: Wire up map_sg for arm-smmu-v3 commit 7af9a17034ffc13117834d60b4a6f2c757e3c0b4 Merge: bb96727 5ab92a7 Author: Linus Torvalds Date: Fri Jun 17 07:06:57 2016 -1000 Merge tag 'for-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds Pull LED fixes from Jacek Anaszewski: - Fix brightness setting upon hardware blinking enabled - Handle suspend/resume in heartbeat trigger * tag 'for-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds: leds: handle suspend/resume in heartbeat trigger leds: core: Fix brightness setting upon hardware blinking enabled commit de18c165509edb36bde42ca6ff930854f85e21ea Merge: 719da39 dd5c931 Author: Chris Mason Date: Fri Jun 17 10:04:57 2016 -0700 Merge branch 'for-chris' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux into for-linus-4.7 commit dd5c93111dc9d26e038ac437f7a403d617e82c62 Author: Chandan Rajendra Date: Thu Jun 16 22:07:58 2016 +0530 Btrfs: btrfs_check_super_valid: Allow 4096 as stripesize Older btrfs-progs/mkfs.btrfs sets 4096 as the stripesize. Hence restricting stripesize to be equal to sectorsize would cause super block validation to return an error on architectures where PAGE_SIZE is not equal to 4096. Hence as a workaround, this commit allows stripesize to be set to 4096 bytes. Signed-off-by: Chandan Rajendra Signed-off-by: David Sterba fs/btrfs/disk-io.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 89c5a5441d703ba068699524ae59f7806e9b173d Author: David Sterba Date: Thu Jun 16 17:34:28 2016 +0200 btrfs: remove build fixup for qgroup_account_snapshot Introduced in 2c1984f244838477aab ("btrfs: build fixup for qgroup_account_snapshot") as temporary bisectability build fixup. Signed-off-by: David Sterba fs/btrfs/transaction.c | 5 ----- 1 file changed, 5 deletions(-) commit f7af3934c2bccba261972261ac8ebcbf92a346b2 Author: David Sterba Date: Fri Jun 17 18:15:25 2016 +0200 btrfs: use new error message helper in qgroup_account_snapshot We've renamed btrfs_std_error, this one is left from last merge. Signed-off-by: David Sterba fs/btrfs/transaction.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 90c711ab380d633bf85249bd5d819edb601feda7 Author: Zygo Blaxell Date: Sun Jun 12 23:39:58 2016 -0400 btrfs: avoid blocking open_ctree from cleaner_kthread This fixes a problem introduced in commit 2f3165ecf103599f82bf0ea254039db335fb5005 "btrfs: don't force mounts to wait for cleaner_kthread to delete one or more subvolumes". open_ctree eventually calls btrfs_replay_log which in turn calls btrfs_commit_super which tries to lock the cleaner_mutex, causing a recursive mutex deadlock during mount. Instead of playing whack-a-mole trying to keep up with all the functions that may want to lock cleaner_mutex, put all the cleaner_mutex lockers back where they were, and attack the problem more directly: keep cleaner_kthread asleep until the filesystem is mounted. When filesystems are mounted read-only and later remounted read-write, open_ctree did not set fs_info->open and neither does anything else. Set this flag in btrfs_remount so that neither btrfs_delete_unused_bgs nor cleaner_kthread get confused by the common case of "/" filesystem read-only mount followed by read-write remount. Signed-off-by: Zygo Blaxell Reviewed-by: David Sterba Signed-off-by: David Sterba fs/btrfs/disk-io.c | 25 ++++++++++--------------- fs/btrfs/super.c | 2 ++ 2 files changed, 12 insertions(+), 15 deletions(-) commit 3b6571c180da85e43550c608e954ab7b2a31d954 Author: Josef Bacik Date: Fri May 27 13:03:04 2016 -0400 Btrfs: don't BUG_ON() in btrfs_orphan_add This is just a screwup for developers, so change it to an ASSERT() so developers notice when things go wrong and deal with the error appropriately if ASSERT() isn't enabled. Thanks, Signed-off-by: Josef Bacik Reviewed-by: Mark Fasheh Signed-off-by: David Sterba fs/btrfs/inode.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 64c12921e11b3a0c10d088606e328c58e29274d8 Author: Jeff Mahoney Date: Wed Jun 8 00:36:38 2016 -0400 btrfs: account for non-CoW'd blocks in btrfs_abort_transaction The test for !trans->blocks_used in btrfs_abort_transaction is insufficient to determine whether it's safe to drop the transaction handle on the floor. btrfs_cow_block, informed by should_cow_block, can return blocks that have already been CoW'd in the current transaction. trans->blocks_used is only incremented for new block allocations. If an operation overlaps the blocks in the current transaction entirely and must abort the transaction, we'll happily let it clean up the trans handle even though it may have modified the blocks and will commit an incomplete operation. In the long-term, I'd like to do closer tracking of when the fs is actually modified so we can still recover as gracefully as possible, but that approach will need some discussion. In the short term, since this is the only code using trans->blocks_used, let's just switch it to a bool indicating whether any blocks were used and set it when should_cow_block returns false. Cc: stable@vger.kernel.org # 3.4+ Signed-off-by: Jeff Mahoney Reviewed-by: Filipe Manana Signed-off-by: David Sterba fs/btrfs/ctree.c | 5 ++++- fs/btrfs/extent-tree.c | 2 +- fs/btrfs/super.c | 2 +- fs/btrfs/transaction.h | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) commit c871b0f2fd27e7f9097d507f47de5270f88003b9 Author: Liu Bo Date: Mon Jun 6 12:01:23 2016 -0700 Btrfs: check if extent buffer is aligned to sectorsize Thanks to fuzz testing, we can pass an invalid bytenr to extent buffer via alloc_extent_buffer(). An unaligned eb can have more pages than it should have, which ends up extent buffer's leak or some corrupted content in extent buffer. This adds a warning to let us quickly know what was happening. Now that alloc_extent_buffer() no more returns NULL, this changes its caller and callers of its caller to match with the new error handling. Signed-off-by: Liu Bo Reviewed-by: David Sterba Signed-off-by: David Sterba fs/btrfs/ctree.c | 2 ++ fs/btrfs/disk-io.c | 8 ++++---- fs/btrfs/extent-tree.c | 10 ++++++---- fs/btrfs/extent_io.c | 15 ++++++++++++--- fs/btrfs/tree-log.c | 4 ++-- fs/btrfs/volumes.c | 4 ++-- 6 files changed, 28 insertions(+), 15 deletions(-) commit 16ff4b454f1b56e8d89a9075feed0dd6ac510c3d Author: Heinrich Schuchardt Date: Sat Jun 11 18:11:10 2016 +0200 btrfs: Use correct format specifier Component mirror_num of struct btrfsic_block is defined as unsigned int. Use %u as format specifier. Signed-off-by: Heinrich Schuchardt Reviewed-by: David Sterba Signed-off-by: David Sterba fs/btrfs/check-integrity.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 76bf3441ad6584ddc3aea1501927f21b21ba3a3a Author: Ben Dooks Date: Tue Jun 7 17:49:09 2016 +0100 ata: sata_mv: fix mis-conversion in mv_write_cached_reg() Fix the signed issue in mv_write_cached_reg() where the laddr is assigned from a (long)addr instead of (unsigned long)addr. Fixes the following warnings: drivers/ata/sata_mv.c:989:26: warning: cast removes address space of expression drivers/ata/sata_mv.c:989:26: warning: cast removes address space of expression drivers/ata/sata_mv.c:989:26: warning: cast removes address space of expression drivers/ata/sata_mv.c:989:26: warning: cast removes address space of expression Signed-off-by: Ben Dooks Signed-off-by: Tejun Heo drivers/ata/sata_mv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bfbbe44daf64d0ccf2de123179817f3557fb9237 Author: Linus Walleij Date: Thu Jun 16 11:55:55 2016 +0200 gpio: make library immune to error pointers Most functions that take a GPIO descriptor in need to check the descriptor for IS_ERR(). We do this mostly in the VALIDATE_DESC() macro except for the gpiod_to_irq() function which needs special handling. Cc: stable@vger.kernel.org Reported-by: Grygorii Strashko Reviewed-by: Grygorii Strashko Acked-by: Alexandre Courbot Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 79bb71bd1d93197ce227fa167b450b633f30a52b Author: Linus Walleij Date: Wed Jun 15 22:57:38 2016 +0200 gpio: make sure gpiod_to_irq() returns negative on NULL desc commit 54d77198fdfbc4f0fe11b4252c1d9c97d51a3264 ("gpio: bail out silently on NULL descriptors") doesn't work for gpiod_to_irq(): drivers assume that NULL descriptors will give negative IRQ numbers in return. It has been pointed out that returning 0 is NO_IRQ and that drivers should be amended to treat this as an error, but that is for the longer term: now let us repair the semantics. Cc: Maxime Ripard Reported-by: Hans de Goede Tested-by: Hans de Goede Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 6c081ff6fd5abd621797570be43d5e3c6acfcd58 Author: Dan Carpenter Date: Tue May 10 11:01:33 2016 +0300 phy: bcm-ns-usb2: checking the wrong variable We intended to test "usb2->phy" here instead of "dev". Fixes: d3feb4067335 ('phy: bcm-ns-usb2: new driver for USB 2.0 PHY on Northstar') Signed-off-by: Dan Carpenter Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-bcm-ns-usb2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d99cb37828a2fe344ecc95d1fad570bbe447cc06 Author: Ben Dooks Date: Tue Jun 7 18:14:56 2016 +0100 phy-sun4i-usb: fix missing __iomem * Fix the missing __iomem attribute in sun4i_usb_phy_write() function. This fixes the following sparse warnings: drivers/phy/phy-sun4i-usb.c:178:39: warning: incorrect type in initializer (different address spaces) drivers/phy/phy-sun4i-usb.c:178:39: expected void *phyctl drivers/phy/phy-sun4i-usb.c:178:39: got void [noderef] * drivers/phy/phy-sun4i-usb.c:185:17: warning: incorrect type in argument 2 (different address spaces) drivers/phy/phy-sun4i-usb.c:185:17: expected void volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:185:17: got void *phyctl drivers/phy/phy-sun4i-usb.c:189:24: warning: incorrect type in argument 1 (different address spaces) drivers/phy/phy-sun4i-usb.c:189:24: expected void const volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:189:24: got void *phyctl drivers/phy/phy-sun4i-usb.c:196:17: warning: incorrect type in argument 2 (different address spaces) drivers/phy/phy-sun4i-usb.c:196:17: expected void volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:196:17: got void *phyctl drivers/phy/phy-sun4i-usb.c:199:24: warning: incorrect type in argument 1 (different address spaces) drivers/phy/phy-sun4i-usb.c:199:24: expected void const volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:199:24: got void *phyctl drivers/phy/phy-sun4i-usb.c:205:17: warning: incorrect type in argument 2 (different address spaces) drivers/phy/phy-sun4i-usb.c:205:17: expected void volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:205:17: got void *phyctl drivers/phy/phy-sun4i-usb.c:208:24: warning: incorrect type in argument 1 (different address spaces) drivers/phy/phy-sun4i-usb.c:208:24: expected void const volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:208:24: got void *phyctl drivers/phy/phy-sun4i-usb.c:210:17: warning: incorrect type in argument 2 (different address spaces) drivers/phy/phy-sun4i-usb.c:210:17: expected void volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:210:17: got void *phyctl drivers/phy/phy-sun4i-usb.c:212:24: warning: incorrect type in argument 1 (different address spaces) drivers/phy/phy-sun4i-usb.c:212:24: expected void const volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:212:24: got void *phyctl drivers/phy/phy-sun4i-usb.c:214:17: warning: incorrect type in argument 2 (different address spaces) drivers/phy/phy-sun4i-usb.c:214:17: expected void volatile [noderef] *addr drivers/phy/phy-sun4i-usb.c:214:17: got void *phyctl Signed-off-by: Ben Dooks Acked-by: Hans de Goede Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-sun4i-usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5cf700ac9d50353dc5b8194a57c6f40bf1fc4424 Author: Quentin Schulz Date: Mon Jun 13 13:45:48 2016 +0200 phy: phy-sun4i-usb: Fix optional gpios failing probe The interrupt 0 is not a valid interrupt number. In the event where the retrieval of the vbus-det gpio would return null, the gpiod_to_irq callback would return 0, while the current code makes the assumption that it is a valid interrupt, and would go on calling request_irq. Obviously, this would fail, preventing the driver from probing properly, while the vbus and id gpios are optional. Signed-off-by: Quentin Schulz Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-sun4i-usb.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 075adb8046532d9642f411a92b4f385d04ced24d Author: Wei Yongjun Date: Mon Jun 13 23:31:47 2016 +0000 phy: rockchip-dp: fix return value check in rockchip_dp_phy_probe() In case of error, the function devm_kzalloc() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Signed-off-by: Wei Yongjun Reviewed-by: Heiko Stuebner Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-rockchip-dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6762925df4642aec5629f7971ba477d6930f53f7 Author: Yoshihiro Shimoda Date: Tue May 31 21:47:17 2016 +0900 phy: rcar-gen3-usb2: fix unexpected repeat interrupts of VBUS change This patch fixes an issue that the driver is possible to cause unexpected repeat interrupts if a board condition is wrong (e.g. even if the ID pin is as function, a board supplies the VBUS.) The reason why unexpected repeat interrupts happen is: 1) The driver changed the mode to function if it detected the ID pin is high and the VBUS is high. 2) After the driver changed function mode, it disabled the "VBUS control" feature. Then, the VBUS signal will be low. 3) Since the VBUS change interruption happened, the driver checked the ID pin and VBUS. 4) Since VBUS was low, the driver changed the mode to host and enabled the "VBUS control" feature. Then the VBUS signal will be high. 5) Since the VBUS change interruption happened, the driver did 1) above. So, this patch modified the condition in rcar_gen3_device_recognition() to check the ID pin only. Fixes: 1114e2d (phy: rcar-gen3-usb2: change the mode to OTG on the combined channel) Cc: # v4.5+ Reported-by: Simon Horman Signed-off-by: Yoshihiro Shimoda Signed-off-by: Kishon Vijay Abraham I drivers/phy/phy-rcar-gen3-usb2.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) commit 8198868f0a283eb23e264951632ce61ec2f82228 Author: Jaroslav Kysela Date: Fri Jun 17 13:35:56 2016 +0200 ALSA: hdac_regmap - fix the register access for runtime PM Call path: 1) snd_hdac_power_up_pm() 2) snd_hdac_power_up() 3) pm_runtime_get_sync() 4) __pm_runtime_resume() 5) rpm_resume() The rpm_resume() returns 1 when the device is already active. Because the return value is unmodified, the hdac regmap read/write functions should allow this value for the retry I/O operation, too. Signed-off-by: Jaroslav Kysela Cc: Signed-off-by: Takashi Iwai sound/hda/hdac_regmap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1463847e93fe693e89c52b03ab4ede6800d717c1 Author: Pablo Neira Ayuso Date: Fri Jun 17 12:54:18 2016 +0200 netfilter: xt_SYNPROXY: include missing ./usr/include/linux/netfilter/xt_SYNPROXY.h:11: found __[us]{8,16,32,64} type without #include Reported-by: kbuild test robot Signed-off-by: Pablo Neira Ayuso include/uapi/linux/netfilter/xt_SYNPROXY.h | 2 ++ 1 file changed, 2 insertions(+) commit 8f45927c3cae4db85887700e5415286f766cbaf9 Author: Pablo Neira Ayuso Date: Fri Jun 17 12:54:18 2016 +0200 netfilter: xt_SYNPROXY: add missing header to Kbuild Matt Whitlock says: Without this line, the file xt_SYNPROXY.h does not get installed in /usr/include/linux/netfilter/, and thus user-space programs cannot make use of it. Reported-by: Matt Whitlock Signed-off-by: Pablo Neira Ayuso include/uapi/linux/netfilter/Kbuild | 1 + 1 file changed, 1 insertion(+) commit 86c0ae7cde7a8699116b365a5e3016753f0cd92a Author: Janusz Krzysztofik Date: Thu Jun 16 22:04:35 2016 +0200 ASoC: cx20442: set tty->receiver_room in v253_open Commit 79901317ce80 ("n_tty: Don't flush buffer when closing ldisc"), introduced in v3.10, revealed a bug in the cx20442 codec driver which has never been setting tty->receive_room on line discipline open as it should from the beginning. Fix it. Created and tested on Amstrad Delta against Linux-4.7-rc3 Signed-off-by: Janusz Krzysztofik Signed-off-by: Mark Brown sound/soc/codecs/cx20442.c | 1 + 1 file changed, 1 insertion(+) commit dcd2d1f78664fdc75eadaaf65257834e24383d01 Author: Geert Uytterhoeven Date: Thu Jun 16 14:34:30 2016 +0200 ASoC: ak4613: Enable cache usage to fix crashes on resume During system resume: kernel BUG at drivers/base/regmap/regcache.c:347! ... PC is at regcache_sync+0x1c/0x128 LR is at ak4613_resume+0x28/0x34 The ak4613 driver is using a regmap cache sync to restore the configuration of the chip on resume but does not actually define a register cache which means that the resume is never going to work and we trigger asserts in regmap. Fix this by enabling caching. Based on commit d3030d11961a8c10 ("ASoC: ak4642: Enable cache usage to fix crashes on resume") by Mark Brown . Signed-off-by: Geert Uytterhoeven Signed-off-by: Mark Brown sound/soc/codecs/ak4613.c | 1 + 1 file changed, 1 insertion(+) commit 50c7a0ef2d97e56c7ce2f1ea5fe1d8e25aadc1bb Author: Geert Uytterhoeven Date: Thu Jun 16 14:34:32 2016 +0200 ASoC: wm8940: Enable cache usage to fix crashes on resume The wm8940 driver is using a regmap cache sync to restore the configuration of the chip when switching from OFF to STANDBY, but does not actually define a register cache which means that the restore is never going to work and we trigger asserts in regmap. Fix this by enabling caching. Based on commit d3030d11961a8c10 ("ASoC: ak4642: Enable cache usage to fix crashes on resume") by Mark Brown . Signed-off-by: Geert Uytterhoeven Acked-by: Charles Keepax Signed-off-by: Mark Brown sound/soc/codecs/wm8940.c | 1 + 1 file changed, 1 insertion(+) commit 8a092e682f20f193f2070dba2ea1904e95814126 Author: Mika Båtsman Date: Fri Jun 17 13:31:37 2016 +0300 regulator: anatop: allow regulator to be in bypass mode Bypass support was added in commit d38018f2019c ("regulator: anatop: Add bypass support to digital LDOs"). A check for valid voltage selectors was added in commit da0607c8df5c ("regulator: anatop: Fail on invalid voltage selector") but it also discards all regulators that are in bypass mode. Add check for the bypass setting. Errors below were seen on a Variscite mx6 board. anatop_regulator 20c8000.anatop:regulator-vddcore@140: Failed to read a valid default voltage selector. anatop_regulator: probe of 20c8000.anatop:regulator-vddcore@140 failed with error -22 anatop_regulator 20c8000.anatop:regulator-vddsoc@140: Failed to read a valid default voltage selector. anatop_regulator: probe of 20c8000.anatop:regulator-vddsoc@140 failed with error -22 Fixes: da0607c8df5c ("regulator: anatop: Fail on invalid voltage selector") Signed-off-by: Mika Båtsman Signed-off-by: Mark Brown drivers/regulator/anatop-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d279f7a7e95af6bb4b5eaea3527d1f85a28c5cf6 Author: Dave Gerlach Date: Wed Jun 15 11:45:28 2016 +0530 ARM: dts: am437x-sk-evm: Reduce i2c0 bus speed for tps65218 Based on the latest timing specifications for the TPS65218 from the data sheet, http://www.ti.com/lit/ds/symlink/tps65218.pdf, document SLDS206 from November 2014, we must change the i2c bus speed to better fit within the minimum high SCL time required for proper i2c transfer. When running at 400khz, measurements show that SCL spends 0.8125 uS/1.666 uS high/low which violates the requirement for minimum high period of SCL provided in datasheet Table 7.6 which is 1 uS. Switching to 100khz gives us 5 uS/5 uS high/low which both fall above the minimum given values for 100 khz, 4.0 uS/4.7 uS high/low. Without this patch occasionally a voltage set operation from the kernel will appear to have worked but the actual voltage reflected on the PMIC will not have updated, causing problems especially with cpufreq that may update to a higher OPP without actually raising the voltage on DCDC2, leading to a hang. Signed-off-by: Dave Gerlach Signed-off-by: Nishanth Menon Signed-off-by: Franklin S Cooper Jr Signed-off-by: Aparna Balasubramanian Signed-off-by: Keerthy Signed-off-by: Tony Lindgren arch/arm/boot/dts/am437x-sk-evm.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a3aa256b7258b3d19f8b44557cc64525a993b941 Author: Gavin Shan Date: Fri Jun 17 13:05:11 2016 +1000 powerpc/eeh: Fix invalid cached PE primary bus The PE primary bus cannot be got from its child devices when having full hotplug in error recovery. The PE primary bus is cached, which is done in commit <05ba75f84864> ("powerpc/eeh: Fix stale cached primary bus"). In eeh_reset_device(), the flag (EEH_PE_PRI_BUS) is cleared before the PCI hot remove. eeh_pe_bus_get() then returns NULL as the PE primary bus in pnv_eeh_reset() and it crashes the kernel eventually. This fixes the issue by clearing the flag (EEH_PE_PRI_BUS) before the PCI hot add. With it, the PowerNV EEH reset backend (pnv_eeh_reset()) can get valid PE primary bus through eeh_pe_bus_get(). Fixes: 67086e32b564 ("powerpc/eeh: powerpc/eeh: Support error recovery for VF PE") Reported-by: Pridhiviraj Paidipeddi Signed-off-by: Gavin Shan Signed-off-by: Michael Ellerman arch/powerpc/kernel/eeh_driver.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit b23d9c5b9c83c05e013aa52460f12a8365062cf4 Author: Aneesh Kumar K.V Date: Fri Jun 17 11:40:36 2016 +0530 powerpc/mm/radix: Update Radix tree size as per ISA 3.0 ISA 3.0 updated it to be encoded as Radix tree size = 2^(RTS + 31). We have it encoded as 2^(RTS + 28). Add a helper with the correct encoding and use it instead of opencoding. Fixes: 2bfd65e45e87 ("powerpc/mm/radix: Add radix callbacks for early init routines") Reviewed-by: Balbir Singh Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/include/asm/book3s/64/radix.h | 15 +++++++++++++++ arch/powerpc/mm/mmu_context_book3s64.c | 2 +- arch/powerpc/mm/pgtable-radix.c | 9 +++------ 3 files changed, 19 insertions(+), 7 deletions(-) commit e568006b9d828403397668864d9797dc4bfefd28 Author: Aneesh Kumar K.V Date: Fri Jun 17 11:32:00 2016 +0530 powerpc/mm/hash: Don't add memory coherence if cache inhibited is set H_ENTER hcall handling in qemu had assumptions that a cache inhibited hpte entry won't have memory conference set. Also older kernel mentioned that some version of pHyp required this (the code removed by the below commit says: /* Make pHyp happy */ if ((rflags & _PAGE_NO_CACHE) && !(rflags & _PAGE_WRITETHRU)) hpte_r &= ~HPTE_R_M; But with older kernel we had some inconsistent memory conherence mapping. We always enabled memory conherence in the page fault path and removed memory conherence is _PAGE_NO_CACHE was set when we mapped the page via htab_bolt_mapping. The commit mentioned below tried to consolidate that by always enabling memory conherence. But as mentioned above that breaks Qemu H_ENTER handling. This patch update this such that we enable memory conherence only if cache inhibited is not set and bring fault handling, lpar and bolt mapping in sync. Fixes: commit 30bda41aba4e("powerpc/mm: Drop WIMG in favour of new constant") Reported-by: Darrick J. Wong Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/mm/hash_utils_64.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit 970f9091d25df14e9540ec7ff48a2f709e284cd1 Author: Tero Kristo Date: Thu Jun 16 15:25:18 2016 +0300 ARM: OMAP2+: timer: add probe for clocksources A few platforms are currently missing clocksource_probe() completely in their time_init functionality. On OMAP3430 for example, this is causing cpuidle to be pretty much dead, as the counter32k is not going to be registered and instead a gptimer is used as a clocksource. This will tick in periodic mode, preventing any deeper idle states. While here, also drop one unnecessary check for populated DT before existing clocksource_probe() call. Signed-off-by: Tero Kristo Signed-off-by: Tony Lindgren arch/arm/mach-omap2/timer.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit ef5bdccf6d4363fd934035e0b1ca8445975e1d89 Author: Janusz Krzysztofik Date: Thu Jun 16 21:56:30 2016 +0200 ARM: OMAP1: fix ams-delta FIQ handler to work with sparse IRQ After OMAP1 IRQ definitions have been changed by commit 685e2d08c54b ("ARM: OMAP1: Change interrupt numbering for sparse IRQ") introduced in v4.2, ams-delta FIQ handler which depends on them no longer works as expected. Fix it. Created and tested on Amstrad Delta against Linux-4.7-rc3 Signed-off-by: Janusz Krzysztofik Signed-off-by: Tony Lindgren arch/arm/mach-omap1/ams-delta-fiq-handler.S | 6 +++--- arch/arm/mach-omap1/ams-delta-fiq.c | 5 +++-- arch/arm/mach-omap1/include/mach/ams-delta-fiq.h | 2 ++ 3 files changed, 8 insertions(+), 5 deletions(-) commit a4c34ff1c029e90e7d5f8dd8d29b0a93b31c3cb2 Author: Joerg Roedel Date: Fri Jun 17 11:29:48 2016 +0200 iommu/vt-d: Enable QI on all IOMMUs before setting root entry This seems to be required on some X58 chipsets on systems with more than one IOMMU. QI does not work until it is enabled on all IOMMUs in the system. Reported-by: Dheeraj CVR Tested-by: Dheeraj CVR Fixes: 5f0a7f7614a9 ('iommu/vt-d: Make root entry visible for hardware right after allocation') Cc: stable@vger.kernel.org Signed-off-by: Joerg Roedel drivers/iommu/intel-iommu.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit ce449ba77a2271dce9771fb1f3eb37e4be6a8b81 Author: Jakub Kicinski Date: Thu Jun 16 14:42:50 2016 +0100 nfp: use correct index to mask link state irq We were using an incorrect define to get the irq vector number. NFP_NET_CFG_LSC is a control BAR offset, LSC interrupt vector index is called NFP_NET_IRQ_LSC_IDX. For machines with less than 30 CPUs this meant that we were disabling/enabling IRQ 0. For bigger hosts we were just playing with the 31st RX/TX interrupt. Fixes: 0ba40af963f0 ("nfp: move link state interrupt request/free calls") Signed-off-by: Jakub Kicinski Signed-off-by: David S. Miller drivers/net/ethernet/netronome/nfp/nfp_net_common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit bb967271c0317de8eed56b20aae978d31507b033 Merge: 2668bc7 cc51846 Author: Linus Torvalds Date: Thu Jun 16 17:33:51 2016 -1000 Merge tag 'pwm/for-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm Pull pwm fixes from Thierry Reding: "These changes fix a bit of fallout from the introduction of the atomic API" * tag 'pwm/for-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm: pwm: atmel-hlcdc: Fix default PWM polarity pwm: sysfs: Get return value from pwm_apply_state() pwm: Improve args checking in pwm_apply_state() commit 2668bc77a102866549784f87693c24e693b195df Merge: 41ef721 a005219 Author: Linus Torvalds Date: Thu Jun 16 17:29:53 2016 -1000 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm Pull KVM fixes from Paolo Bonzini: - miscellaneous fixes for MIPS and s390 - one new kvm_stat for s390 - correctly disable VT-d posted interrupts with the rest of posted interrupts - "make randconfig" fix for x86 AMD - off-by-one in irq route check (the "good" kind that errors out a bit too early!) * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: kvm: vmx: check apicv is active before using VT-d posted interrupt kvm: Fix irq route entries exceeding KVM_MAX_IRQ_ROUTES kvm: svm: Do not support AVIC if not CONFIG_X86_LOCAL_APIC kvm: svm: Fix implicit declaration for __default_cpu_present_to_apicid() MIPS: KVM: Fix CACHE triggered exception emulation MIPS: KVM: Don't unwind PC when emulating CACHE MIPS: KVM: Include bit 31 in segment matches MIPS: KVM: Fix modular KVM under QEMU KVM: s390: Add stats for PEI events KVM: s390: ignore IBC if zero commit 41ef72181a9fde78f13d0966e3019fb37f6058e4 Merge: 9c514bed 8c7245a Author: Linus Torvalds Date: Thu Jun 16 17:25:52 2016 -1000 Merge tag 'nfsd-4.7-1' of git://linux-nfs.org/~bfields/linux Pull nfsd bugfixes from Bruce Fields: "Oleg Drokin found and fixed races in the nfsd4 state code that go back to the big nfs4_lock_state removal around 3.17 (but that were also probably hard to reproduce before client changes in 3.20 allowed the client to perform parallel opens). Also fix a 4.1 backchannel crash due to rpc multipath changes in 4.6. Trond acked the client-side rpc fixes going through my tree" * tag 'nfsd-4.7-1' of git://linux-nfs.org/~bfields/linux: nfsd: Make init_open_stateid() a bit more whole nfsd: Extend the mutex holding region around in nfsd4_process_open2() nfsd: Always lock state exclusively. rpc: share one xps between all backchannels nfsd4/rpc: move backchannel create logic into rpc code SUNRPC: fix xprt leak on xps allocation failure nfsd: Fix NFSD_MDS_PR_KEY on 32-bit by adding ULL postfix commit 9c514bedbe6948f31d29c53aceb9234c1484ae69 Merge: 3832742 d0e13f5 Author: Linus Torvalds Date: Thu Jun 16 17:16:56 2016 -1000 Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs Pull overlayfs fixes from Miklos Szeredi: "This contains two regression fixes: one for the xattr API update and one for using the mounter's creds in file creation in overlayfs. There's also a fix for a bug in handling hard linked AF_UNIX sockets that's been there from day one. This fix is overlayfs only despite the fact that it touches code outside the overlay filesystem: d_real() is an identity function for all except overlay dentries" * 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs: ovl: fix uid/gid when creating over whiteout ovl: xattr filter fix af_unix: fix hard linked sockets on overlay vfs: add d_real_inode() helper commit 38327424b40bcebe2de92d07312c89360ac9229a Author: Dan Carpenter Date: Thu Jun 16 15:48:57 2016 +0100 KEYS: potential uninitialized variable If __key_link_begin() failed then "edit" would be uninitialized. I've added a check to fix that. This allows a random user to crash the kernel, though it's quite difficult to achieve. There are three ways it can be done as the user would have to cause an error to occur in __key_link(): (1) Cause the kernel to run out of memory. In practice, this is difficult to achieve without ENOMEM cropping up elsewhere and aborting the attempt. (2) Revoke the destination keyring between the keyring ID being looked up and it being tested for revocation. In practice, this is difficult to time correctly because the KEYCTL_REJECT function can only be used from the request-key upcall process. Further, users can only make use of what's in /sbin/request-key.conf, though this does including a rejection debugging test - which means that the destination keyring has to be the caller's session keyring in practice. (3) Have just enough key quota available to create a key, a new session keyring for the upcall and a link in the session keyring, but not then sufficient quota to create a link in the nominated destination keyring so that it fails with EDQUOT. The bug can be triggered using option (3) above using something like the following: echo 80 >/proc/sys/kernel/keys/root_maxbytes keyctl request2 user debug:fred negate @t The above sets the quota to something much lower (80) to make the bug easier to trigger, but this is dependent on the system. Note also that the name of the keyring created contains a random number that may be between 1 and 10 characters in size, so may throw the test off by changing the amount of quota used. Assuming the failure occurs, something like the following will be seen: kfree_debugcheck: out of range ptr 6b6b6b6b6b6b6b68h ------------[ cut here ]------------ kernel BUG at ../mm/slab.c:2821! ... RIP: 0010:[] kfree_debugcheck+0x20/0x25 RSP: 0018:ffff8804014a7de8 EFLAGS: 00010092 RAX: 0000000000000034 RBX: 6b6b6b6b6b6b6b68 RCX: 0000000000000000 RDX: 0000000000040001 RSI: 00000000000000f6 RDI: 0000000000000300 RBP: ffff8804014a7df0 R08: 0000000000000001 R09: 0000000000000000 R10: ffff8804014a7e68 R11: 0000000000000054 R12: 0000000000000202 R13: ffffffff81318a66 R14: 0000000000000000 R15: 0000000000000001 ... Call Trace: kfree+0xde/0x1bc assoc_array_cancel_edit+0x1f/0x36 __key_link_end+0x55/0x63 key_reject_and_link+0x124/0x155 keyctl_reject_key+0xb6/0xe0 keyctl_negate_key+0x10/0x12 SyS_keyctl+0x9f/0xe7 do_syscall_64+0x63/0x13a entry_SYSCALL64_slow_path+0x25/0x25 Fixes: f70e2e06196a ('KEYS: Do preallocation for __key_link()') Signed-off-by: Dan Carpenter Signed-off-by: David Howells cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds security/keys/key.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d5d8760b78d0cfafe292f965f599988138b06a70 Author: Simon Horman Date: Thu Jun 16 17:06:19 2016 +0900 sit: correct IP protocol used in ipip6_err Since 32b8a8e59c9c ("sit: add IPv4 over IPv4 support") ipip6_err() may be called for packets whose IP protocol is IPPROTO_IPIP as well as those whose IP protocol is IPPROTO_IPV6. In the case of IPPROTO_IPIP packets the correct protocol value is not passed to ipv4_update_pmtu() or ipv4_redirect(). This patch resolves this problem by using the IP protocol of the packet rather than a hard-coded value. This appears to be consistent with the usage of the protocol of a packet by icmp_socket_deliver() the caller of ipip6_err(). I was able to exercise the redirect case by using a setup where an ICMP redirect was received for the destination of the encapsulated packet. However, it appears that although incorrect the protocol field is not used in this case and thus no problem manifests. On inspection it does not appear that a problem will manifest in the fragmentation needed/update pmtu case either. In short I believe this is a cosmetic fix. None the less, the use of IPPROTO_IPV6 seems wrong and confusing. Reviewed-by: Dinan Gunawardena Signed-off-by: Simon Horman Acked-by: YOSHIFUJI Hideaki Signed-off-by: David S. Miller net/ipv6/sit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8fa3b8d689a54d6d04ff7803c724fb7aca6ce98e Author: Tejun Heo Date: Thu May 26 15:42:13 2016 -0400 cgroup: set css->id to -1 during init If percpu_ref initialization fails during css_create(), the free path can end up trying to free css->id of zero. As ID 0 is unused, it doesn't cause a critical breakage but it does trigger a warning message. Fix it by setting css->id to -1 from init_and_link_css(). Signed-off-by: Tejun Heo Cc: Wenwei Tao Fixes: 01e586598b22 ("cgroup: release css->id after css_free") Cc: stable@vger.kernel.org # v4.0+ Signed-off-by: Tejun Heo kernel/cgroup.c | 1 + 1 file changed, 1 insertion(+) commit a547224dceed4645139f7eff72ff51adb9938bcb Author: Alexander Duyck Date: Wed Jun 15 14:42:11 2016 -0700 mlx4e: Do not attempt to offload VXLAN ports that are unrecognized The mlx4e driver does not support more than one port for VXLAN offload. As such expecting the hardware to offload other ports is invalid since it appears the parsing logic is used to perform Tx checksum and segmentation offloads. Use the vxlan_port number to determine in which cases we can apply the offload and in which cases we can not. Signed-off-by: Alexander Duyck Reviewed-by: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 17471c7ba5115ed724d624577b21c166d2194272 Author: Arnd Bergmann Date: Wed Jun 15 22:31:10 2016 +0200 net: sfc: avoid -Wtype-limits warning When building with -Wextra, we get a harmless warning from the EFX_EXTRACT_OWORD32 macro: ethernet/sfc/farch.c: In function 'efx_farch_test_registers': ethernet/sfc/farch.c:119:30: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits] ethernet/sfc/farch.c:124:144: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits] ethernet/sfc/farch.c:124:392: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits] ethernet/sfc/farch.c:124:731: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits] The macro and the caller are both correct, but we can avoid the warning by changing the index variable to a signed type. Signed-off-by: Arnd Bergmann Acked-by: Bert Kenward Signed-off-by: David S. Miller drivers/net/ethernet/sfc/farch.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit d945b5e9f0e35cb56a3783d849b5f0f37da0a7f1 Author: Peter Zijlstra Date: Thu Jun 16 14:38:42 2016 +0200 workqueue: Fix setting affinity of unbound worker threads With commit e9d867a67fd03ccc ("sched: Allow per-cpu kernel threads to run on online && !active"), __set_cpus_allowed_ptr() expects that only strict per-cpu kernel threads can have affinity to an online CPU which is not yet active. This assumption is currently broken in the CPU_ONLINE notification handler for the workqueues where restore_unbound_workers_cpumask() calls set_cpus_allowed_ptr() when the first cpu in the unbound worker's pool->attr->cpumask comes online. Since set_cpus_allowed_ptr() is called with pool->attr->cpumask in which only one CPU is online which is not yet active, we get the following WARN_ON during an CPU online operation. ------------[ cut here ]------------ WARNING: CPU: 40 PID: 248 at kernel/sched/core.c:1166 __set_cpus_allowed_ptr+0x228/0x2e0 Modules linked in: CPU: 40 PID: 248 Comm: cpuhp/40 Not tainted 4.6.0-autotest+ #4 <..snip..> Call Trace: [c000000f273ff920] [c00000000010493c] __set_cpus_allowed_ptr+0x2cc/0x2e0 (unreliable) [c000000f273ffac0] [c0000000000ed4b0] workqueue_cpu_up_callback+0x2c0/0x470 [c000000f273ffb70] [c0000000000f5c58] notifier_call_chain+0x98/0x100 [c000000f273ffbc0] [c0000000000c5ed0] __cpu_notify+0x70/0xe0 [c000000f273ffc00] [c0000000000c6028] notify_online+0x38/0x50 [c000000f273ffc30] [c0000000000c5214] cpuhp_invoke_callback+0x84/0x250 [c000000f273ffc90] [c0000000000c562c] cpuhp_up_callbacks+0x5c/0x120 [c000000f273ffce0] [c0000000000c64d4] cpuhp_thread_fun+0x184/0x1c0 [c000000f273ffd20] [c0000000000fa050] smpboot_thread_fn+0x290/0x2a0 [c000000f273ffd80] [c0000000000f45b0] kthread+0x110/0x130 [c000000f273ffe30] [c000000000009570] ret_from_kernel_thread+0x5c/0x6c ---[ end trace 00f1456578b2a3b2 ]--- This patch fixes this by limiting the mask to the intersection of the pool affinity and online CPUs. Changelog-cribbed-from: Gautham R. Shenoy Reported-by: Abdul Haleem Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Tejun Heo kernel/workqueue.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 0d15ef677839dab8313fbb86c007c3175b638d03 Author: Daniel Thompson Date: Thu Jun 16 16:51:52 2016 +0100 arm64: kgdb: Match pstate size with gdbserver protocol Current versions of gdb do not interoperate cleanly with kgdb on arm64 systems because gdb and kgdb do not use the same register description. This patch modifies kgdb to work with recent releases of gdb (>= 7.8.1). Compatibility with gdb (after the patch is applied) is as follows: gdb-7.6 and earlier Ok gdb-7.7 series Works if user provides custom target description gdb-7.8(.0) Works if user provides custom target description gdb-7.8.1 and later Ok When commit 44679a4f142b ("arm64: KGDB: Add step debugging support") was introduced it was paired with a gdb patch that made an incompatible change to the gdbserver protocol. This patch was eventually merged into the gdb sources: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=a4d9ba85ec5597a6a556afe26b712e878374b9dd The change to the protocol was mostly made to simplify big-endian support inside the kernel gdb stub. Unfortunately the gdb project released gdb-7.7.x and gdb-7.8.0 before the protocol incompatibility was identified and reversed: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=bdc144174bcb11e808b4e73089b850cf9620a7ee This leaves us in a position where kgdb still uses the no-longer-used protocol; gdb-7.8.1, which restored the original behaviour, was released on 2014-10-29. I don't believe it is possible to detect/correct the protocol incompatiblity which means the kernel must take a view about which version of the gdb remote protocol is "correct". This patch takes the view that the original/current version of the protocol is correct and that version found in gdb-7.7.x and gdb-7.8.0 is anomalous. Signed-off-by: Daniel Thompson Signed-off-by: Will Deacon arch/arm64/include/asm/kgdb.h | 45 +++++++++++++++++++++++++++++++++++-------- arch/arm64/kernel/kgdb.c | 14 +++++++++++++- 2 files changed, 50 insertions(+), 9 deletions(-) commit 929e604efa3dc0522214e0dc18984be23993e9f0 Author: Thomas Petazzoni Date: Thu Jun 16 15:42:27 2016 +0200 ARM: dts: armada-38x: fix MBUS_ID for crypto SRAM on Armada 385 Linksys When the support for the Marvell crypto engine was added in the Device Tree of the various Armada 385 Device Tree files in commit d716f2e837ac6 ("ARM: mvebu: define crypto SRAM ranges for all armada-38x boards"), a typo was made in the MBus window attributes for the Armada 385 Linksys board: 0x09/0x05 are used instead of 0x19/0x15. This commit fixes this typo, which makes the CESA engines operational on Armada 385 Linksys boards. Reported-by: Terry Stockert Cc: Terry Stockert Cc: Imre Kaloz Cc: Boris Brezillon Cc: Fixes: d716f2e837ac6 ("ARM: mvebu: define crypto SRAM ranges for all armada-38x boards") Signed-off-by: Thomas Petazzoni Signed-off-by: Gregory CLEMENT arch/arm/boot/dts/armada-385-linksys.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6a02734d420fca778554878d03017017537d92e1 Author: Thomas Petazzoni Date: Thu Jun 16 15:42:26 2016 +0200 ARM: mvebu: map PCI I/O regions strongly ordered In order for HW I/O coherency to work on Cortex-A9 based Marvell SoCs, all MMIO registers must be mapped strongly ordered. In commit 1c8c3cf0b5239 ("ARM: 8060/1: mm: allow sub-architectures to override PCI I/O memory type") we implemented a new function, pci_ioremap_set_mem_type(), that allow sub-architecture code to override the memory type used to map PCI I/O regions. In the discussion around this patch series [1], Arnd Bergmann made the comment that maybe all PCI I/O regions should be mapped strongly-ordered, which would have made our proposal to add pci_ioremap_set_mem_type() irrelevant. So, we submitted a patch [2] that did what Arnd suggested. However, Russell in the end merged our initial proposal to add pci_ioremap_set_mem_type(), but it was never used anywhere. Further discussion with Arnd and other folks on IRC lead to the conclusion that in fact using strongly-ordered for all platforms was maybe not desirable, and therefore, using pci_ioremap_set_mem_type() was the most appropriate solution. As a consequence, this commit finally adds the pci_ioremap_set_mem_type() call in the mach-mvebu platform code, which was originally part of our initial patch series [3] and is necessary for the whole mechanism to work. [1] http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/256565.html [2] http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/256755.html [3] http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/256563.html Signed-off-by: Thomas Petazzoni Signed-off-by: Gregory CLEMENT arch/arm/mach-mvebu/coherency.c | 1 + 1 file changed, 1 insertion(+) commit 034fdd4a17ff089c2428ece18efa65c5396810d2 Merge: c70410c e024111 Author: Kalle Valo Date: Thu Jun 16 17:55:19 2016 +0300 Merge ath-current from ath.git ath.git fixes for 4.7. Major changes: ath9k * fix GPIO mask regression with AR9462 and AR9565 ath10k * fix deadlock while processing rx_in_ord_ind * fix crash related to printing firmware features in debug mode * fix deadlock when peer cannot be created commit c70410cb91de70707a507ee7beef7021a5a89f0d Author: Colin Ian King Date: Thu Jun 9 14:38:50 2016 -0400 rtl8xxxu: fix typo on variable name, compare against correct variable path_b_ok is being assigned but immediately after path_a_ok is being compared to the value 0x03. This appears to be a typo on the variable name, compare path_b_ok instead. Signed-off-by: Colin Ian King Signed-off-by: Jes Sorensen Signed-off-by: Kalle Valo drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192e.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c5379ba8fccd99d5f99632c789f0393d84a57805 Author: Thomas Petazzoni Date: Thu Jun 16 15:42:25 2016 +0200 ARM: mvebu: fix HW I/O coherency related deadlocks Until now, our understanding for HW I/O coherency to work on the Cortex-A9 based Marvell SoC was that only the PCIe regions should be mapped strongly-ordered. However, we were still encountering some deadlocks, especially when testing the CESA crypto engine. After checking with the HW designers, it was concluded that all the MMIO registers should be mapped as strongly ordered for the HW I/O coherency mechanism to work properly. This fixes some easy to reproduce deadlocks with the CESA crypto engine driver (dmcrypt on a sufficiently large disk partition). Tested-by: Terry Stockert Tested-by: Romain Perier Cc: Terry Stockert Cc: Romain Perier Cc: Signed-off-by: Thomas Petazzoni Signed-off-by: Gregory CLEMENT arch/arm/mach-mvebu/coherency.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit 362761299eea7dfc3a4870551de36e08758b9254 Author: Marcin Niestroj Date: Tue Jun 14 15:29:24 2016 +0200 power_supply: tps65217-charger: Fix NULL deref during property export This bug leads to: [ 1.906411] Unable to handle kernel NULL pointer dereference at virtual address 0000000c [ 1.914878] pgd = c0004000 [ 1.917786] [0000000c] *pgd=00000000 [ 1.921536] Internal error: Oops: 5 [#1] SMP ARM [ 1.926357] Modules linked in: [ 1.929556] CPU: 0 PID: 14 Comm: kworker/0:1 Not tainted 4.4.5 #18 [ 1.936006] Hardware name: Generic AM33XX (Flattened Device Tree) [ 1.942383] Workqueue: events power_supply_changed_work [ 1.947842] task: de2c41c0 ti: de2c8000 task.ti: de2c8000 [ 1.953483] PC is at tps65217_ac_get_property+0x14/0x28 [ 1.958937] LR is at tps65217_ac_get_property+0x10/0x28 Driver was trying to use drv_data in property get handler. However drv_data was not set, so it caused NULL pointer dereference. This patch properly sets drv_data during probe by power_supply_config parameter, so the property get handler works as desired. Signed-off-by: Marcin Niestroj Fixes: 3636859b280c ("power_supply: Add support for tps65217-charger") Signed-off-by: Sebastian Reichel drivers/power/tps65217_charger.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 79ee2e8f730411a30b271d5f9cdeae189fa66174 Author: Viresh Kumar Date: Thu Jun 16 19:03:11 2016 +0530 PM / OPP: Add 'UNKNOWN' status for shared_opp in struct opp_table dev_pm_opp_get_sharing_cpus() returns 0 even in the case when the OPP core doesn't know whether or not the table is shared. It works on the majority of platforms, where the OPP table is never created before invoking the function and then -ENODEV is returned by it. But in the case of one platform (Jetson TK1) at least, the situation is a bit different. The OPP table has been created (somehow) before dev_pm_opp_get_sharing_cpus() is called and it returns 0. Its caller treats that as 'the CPUs don't share OPPs' and that leads to degraded performance. Fix this by converting 'shared_opp' in struct opp_table to an enum and making dev_pm_opp_get_sharing_cpus() return -EINVAL in case when the value of that field is "access unknown", so that the caller can handle it accordingly (cpufreq-dt considers that as 'all CPUs share the table', for example). Fixes: 6f707daa3833 "PM / OPP: Add dev_pm_opp_get_sharing_cpus()" Reported-and-tested-by: Alexandre Courbot Signed-off-by: Viresh Kumar [ rjw : Subject & changelog ] Signed-off-by: Rafael J. Wysocki drivers/base/power/opp/cpu.c | 12 +++++++++--- drivers/base/power/opp/of.c | 10 ++++++++-- drivers/base/power/opp/opp.h | 8 +++++++- 3 files changed, 24 insertions(+), 6 deletions(-) commit 9254e70c4ef1fee2e5c43feded4433d19cbb6177 Author: Hendrik Brueckner Date: Thu Jun 9 12:28:13 2016 +0200 s390/cpum_cf: use perf software context for hardware counters On s390, there are two different hardware PMUs for counting and sampling. Previously, both PMUs have shared the perf_hw_context which is not correct and, recently, results in this warning: ------------[ cut here ]------------ WARNING: CPU: 5 PID: 1 at kernel/events/core.c:8485 perf_pmu_register+0x420/0x428 Modules linked in: CPU: 5 PID: 1 Comm: swapper/0 Not tainted 4.7.0-rc1+ #2 task: 00000009c5240000 ti: 00000009c5234000 task.ti: 00000009c5234000 Krnl PSW : 0704c00180000000 0000000000220c50 (perf_pmu_register+0x420/0x428) R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 RI:0 EA:3 Krnl GPRS: ffffffffffffffff 0000000000b15ac6 0000000000000000 00000009cb440000 000000000022087a 0000000000000000 0000000000b78fa0 0000000000000000 0000000000a9aa90 0000000000000084 0000000000000005 000000000088a97a 0000000000000004 0000000000749dd0 000000000022087a 00000009c5237cc0 Krnl Code: 0000000000220c44: a7f4ff54 brc 15,220aec 0000000000220c48: 92011000 mvi 0(%r1),1 #0000000000220c4c: a7f40001 brc 15,220c4e >0000000000220c50: a7f4ff12 brc 15,220a74 0000000000220c54: 0707 bcr 0,%r7 0000000000220c56: 0707 bcr 0,%r7 0000000000220c58: ebdff0800024 stmg %r13,%r15,128(%r15) 0000000000220c5e: a7f13fe0 tmll %r15,16352 Call Trace: ([<000000000022087a>] perf_pmu_register+0x4a/0x428) ([<0000000000b2c25c>] init_cpum_sampling_pmu+0x14c/0x1f8) ([<0000000000100248>] do_one_initcall+0x48/0x140) ([<0000000000b25d26>] kernel_init_freeable+0x1e6/0x2a0) ([<000000000072bda4>] kernel_init+0x24/0x138) ([<000000000073495e>] kernel_thread_starter+0x6/0xc) ([<0000000000734958>] kernel_thread_starter+0x0/0xc) Last Breaking-Event-Address: [<0000000000220c4c>] perf_pmu_register+0x41c/0x428 ---[ end trace 0c6ef9f5b771ad97 ]--- Using the perf_sw_context is an option because the cpum_cf PMU does not use interrupts. To make this more clear, initialize the capabilities in the PMU structure. Signed-off-by: Hendrik Brueckner Suggested-by: Peter Zijlstra Acked-by: Heiko Carstens Signed-off-by: Martin Schwidefsky arch/s390/kernel/perf_cpum_cf.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 8f50b8e57442d28e41bb736c173d8a2490549a82 Author: Ocquidant, Sebastien Date: Wed Jun 15 13:47:35 2016 +0200 memory: omap-gpmc: Fix omap gpmc EXTRADELAY timing In the omap gpmc driver it can be noticed that GPMC_CONFIG4_OEEXTRADELAY is overwritten by the WEEXTRADELAY value from the device tree and GPMC_CONFIG4_WEEXTRADELAY is not updated by the value from the device tree. As a consequence, the memory accesses cannot be configured properly when the extra delay are needed for OE and WE. Fix the update of GPMC_CONFIG4_WEEXTRADELAY with the value from the device tree file and prevents GPMC_CONFIG4_OEXTRADELAY being overwritten by the WEXTRADELAY value from the device tree. Cc: stable@vger.kernel.org Signed-off-by: Ocquidant, Sebastien Signed-off-by: Roger Quadros drivers/memory/omap-gpmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5fc39d347267bd029fcc9099c70e2fe2d53130e9 Author: Boris Brezillon Date: Wed Jun 15 13:20:19 2016 +0200 ARM: sunxi/dt: make the CHIP inherit from allwinner,sun5i-a13 The sun4i-timer driver registers its sched_clock only if the machine is compatible with "allwinner,sun5i-a13", "allwinner,sun5i-a10s" or "allwinner,sun4i-a10". Add the missing "allwinner,sun5i-a13" string to the machine compatible. Signed-off-by: Boris Brezillon Fixes: 465a225fb2af ("ARM: sun5i: Add C.H.I.P DTS") Cc: Signed-off-by: Maxime Ripard arch/arm/boot/dts/sun5i-r8-chip.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a0052191624e9bf8a8f9dc41b92ab5f252566c3c Author: Yang Zhang Date: Mon Jun 13 09:56:56 2016 +0800 kvm: vmx: check apicv is active before using VT-d posted interrupt VT-d posted interrupt is relying on the CPU side's posted interrupt. Need to check whether VCPU's APICv is active before enabing VT-d posted interrupt. Fixes: d62caabb41f33d96333f9ef15e09cd26e1c12760 Cc: stable@vger.kernel.org Signed-off-by: Yang Zhang Signed-off-by: Shengge Ding Signed-off-by: Paolo Bonzini arch/x86/kvm/vmx.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit caf1ff26e1aa178133df68ac3d40815fed2187d9 Author: Xiubo Li Date: Wed Jun 15 18:00:33 2016 +0800 kvm: Fix irq route entries exceeding KVM_MAX_IRQ_ROUTES These days, we experienced one guest crash with 8 cores and 3 disks, with qemu error logs as bellow: qemu-system-x86_64: /build/qemu-2.0.0/kvm-all.c:984: kvm_irqchip_commit_routes: Assertion `ret == 0' failed. And then we found one patch(bdf026317d) in qemu tree, which said could fix this bug. Execute the following script will reproduce the BUG quickly: irq_affinity.sh ======================================================================== vda_irq_num=25 vdb_irq_num=27 while [ 1 ] do for irq in {1,2,4,8,10,20,40,80} do echo $irq > /proc/irq/$vda_irq_num/smp_affinity echo $irq > /proc/irq/$vdb_irq_num/smp_affinity dd if=/dev/vda of=/dev/zero bs=4K count=100 iflag=direct dd if=/dev/vdb of=/dev/zero bs=4K count=100 iflag=direct done done ======================================================================== The following qemu log is added in the qemu code and is displayed when this bug reproduced: kvm_irqchip_commit_routes: max gsi: 1008, nr_allocated_irq_routes: 1024, irq_routes->nr: 1024, gsi_count: 1024. That's to say when irq_routes->nr == 1024, there are 1024 routing entries, but in the kernel code when routes->nr >= 1024, will just return -EINVAL; The nr is the number of the routing entries which is in of [1 ~ KVM_MAX_IRQ_ROUTES], not the index in [0 ~ KVM_MAX_IRQ_ROUTES - 1]. This patch fix the BUG above. Cc: stable@vger.kernel.org Signed-off-by: Xiubo Li Signed-off-by: Wei Tang Signed-off-by: Zhang Zhuoyu Signed-off-by: Paolo Bonzini virt/kvm/kvm_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9ca91a65583c73e4be6e9f53323a7ae04e6803ef Author: Arnd Bergmann Date: Wed Jun 15 17:55:23 2016 +0200 clk: sunxi: remove unused variable The only use of the local num_parents variable was remove, so we now get a warning: drivers/clk/sunxi/clk-sun4i-tcon-ch1.c: In function 'tcon_ch1_get_parent': drivers/clk/sunxi/clk-sun4i-tcon-ch1.c:82:6: error: unused variable 'num_parents' [-Werror=unused-variable] This removes the variable. Signed-off-by: Arnd Bergmann Fixes: 4de2d58bc973 ("clk: sunxi: tcon-ch1: Do not return a negative error in get_parent") Signed-off-by: Maxime Ripard drivers/clk/sunxi/clk-sun4i-tcon-ch1.c | 1 - 1 file changed, 1 deletion(-) commit 5014e904681ddbdf663bb20f134eb053ddccb181 Author: Suzuki K Poulose Date: Fri May 6 15:35:50 2016 +0100 coresight: Handle build path error Enabling a component via sysfs (echo 1 > enable_source), would trigger building a path from the enabled sources to the sink. If there is an error in the process (e.g, sink not enabled or the device (CPU corresponding to ETM) is not online), we never report failure, except for leaving a message in the dmesg. Do proper error checking for the build path and return the error. Before: $ echo 0 > /sys/devices/system/cpu/cpu2/online $ echo 1 > /sys/devices/cs_etm/cpu2/enable_source $ echo $? 0 After: $ echo 0 > /sys/devices/system/cpu/cpu2/online $ echo 1 > /sys/devices/cs_etm/cpu2/enable_source -bash: echo: write error: No such device or address Signed-off-by: Suzuki K Poulose Acked-by: Mathieu Poirier Signed-off-by: Greg Kroah-Hartman drivers/hwtracing/coresight/coresight.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit f3b8172fe15fbed0d0d33d99780e122213e00684 Author: Suzuki K Poulose Date: Tue Jun 14 11:17:14 2016 -0600 coresight: Fix erroneous memset in tmc_read_unprepare_etr At the end of a trace collection, we try to clear the entire buffer and enable the ETR back if it was already enabled. But, we would have adjusted the drvdata->buf to point to the beginning of the trace data in the trace buffer @drvdata->vaddr. So, the following code which clears the buffer is dangerous and can cause crashes, like below : memset(drvdata->buf, 0, drvdata->size); Unable to handle kernel paging request at virtual address ffffff800a145000 pgd = ffffffc974726000 *pgd=00000009f3e91003, *pud=00000009f3e91003, *pmd=0000000000000000 PREEMPT SMP Modules linked in: CPU: 4 PID: 1692 Comm: dd Not tainted 4.7.0-rc2+ #1721 Hardware name: ARM Juno development board (r0) (DT) task: ffffffc9734a0080 ti: ffffffc974460000 task.ti: ffffffc974460000 PC is at __memset+0x1ac/0x200 LR is at tmc_read_unprepare_etr+0x144/0x1bc pc : [] lr : [] pstate: 200001c5 ... [] __memset+0x1ac/0x200 [] tmc_release+0x90/0x94 [] __fput+0xa8/0x1ec [] ____fput+0xc/0x14 [] task_work_run+0xb0/0xe4 [] do_notify_resume+0x64/0x6c [] work_pending+0x10/0x14 Code: 91010108 54ffff4a 8b040108 cb050042 (d50b7428) Since we clear the buffer anyway in the following call to tmc_etr_enable_hw(), remove the erroneous memset(). Fixes: commit de5461970b3e9e1 ("coresight: tmc: allocating memory when needed") Cc: Mathieu Poirier Signed-off-by: Suzuki K Poulose Signed-off-by: Mathieu Poirier Signed-off-by: Greg Kroah-Hartman drivers/hwtracing/coresight/coresight-tmc-etr.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 8e215298a15d5b93c6fa22895c406da538769bca Author: Suzuki K Poulose Date: Tue Jun 14 11:17:13 2016 -0600 coresight: Fix tmc_read_unprepare_etr At the end of the trace capture, we free the allocated memory, resetting the drvdata->buf to NULL, to indicate that trace data was collected and the next trace session should allocate the memory in tmc_enable_etr_sink_sysfs. The tmc_enable_etr_sink_sysfs, we only allocate memory if drvdata->vaddr is not NULL (which is not performed at the end of previous session). This can cause, drvdata->vaddr getting assigned NULL and later we do memset() which causes a crash as below : Unable to handle kernel NULL pointer dereference at virtual address 00000000 pgd = ffffffc9747f0000 [00000000] *pgd=00000009f402e003, *pud=00000009f402e003, *pmd=0000000000000000 Internal error: Oops: 96000046 [#1] PREEMPT SMP Modules linked in: CPU: 0 PID: 1592 Comm: bash Not tainted 4.7.0-rc1+ #1712 Hardware name: ARM Juno development board (r0) (DT) task: ffffffc078fe0080 ti: ffffffc974178000 task.ti: ffffffc974178000 PC is at __memset+0x1ac/0x200 LR is at tmc_enable_etr_sink+0xf8/0x304 pc : [] lr : [] pstate: 400001c5 sp : ffffffc97417bc00 x29: ffffffc97417bc00 x28: ffffffc974178000 Call trace: Exception stack(0xffffffc97417ba40 to 0xffffffc97417bb60) ba40: 0000000000000001 ffffffc974a5d098 ffffffc97417bc00 ffffff80083a002c ba60: ffffffc974a5d118 0000000000000000 0000000000000000 0000000000000000 ba80: 0000000000000001 0000000000000000 ffffff800859bdec 0000000000000040 baa0: ffffff8008b45b58 00000000000001c0 ffffffc97417baf0 ffffff80080eddb4 bac0: 0000000000000003 ffffffc078fe0080 ffffffc078fe0960 ffffffc078fe0940 bae0: 0000000000000000 0000000000000000 00000000007fffc0 0000000000000004 bb00: 0000000000000000 0000000000000040 000000000000003f 0000000000000000 bb20: 0000000000000000 0000000000000000 0000000000000000 0000000000000001 bb40: ffffffc078fe0960 0000000000000018 ffffffffffffffff 0008669628000000 [] __memset+0x1ac/0x200 [] coresight_enable_path+0xa8/0x1dc [] coresight_enable+0x88/0x1b8 [] enable_source_store+0x3c/0x6c [] dev_attr_store+0x18/0x28 [] sysfs_kf_write+0x54/0x64 [] kernfs_fop_write+0x148/0x1d8 [] __vfs_write+0x28/0x110 [] vfs_write+0xa0/0x198 [] SyS_write+0x44/0xa0 [] el0_svc_naked+0x24/0x28 Code: 91010108 54ffff4a 8b040108 cb050042 (d50b7428) This patch fixes the issue by clearing the drvdata->vaddr while we free the allocated buffer at the end of a session, so that we allocate the memory again. Cc: mathieu.poirier@linaro.org Signed-off-by: Suzuki K Poulose Signed-off-by: Mathieu Poirier Signed-off-by: Greg Kroah-Hartman drivers/hwtracing/coresight/coresight-tmc-etr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ec48a1d981fe90ecb5bcfaaf1ae2c69d842cbbbc Author: Suzuki K Poulose Date: Tue Jun 14 11:17:12 2016 -0600 coresight: Fix NULL pointer dereference in _coresight_build_path _coresight_build_path assumes that all the connections of a csdev has the child_dev initialised. This may not be true if the particular component is not supported by the kernel config(e.g TPIU) but is present in the DT. In which case, building a path can cause a crash like this : Unable to handle kernel NULL pointer dereference at virtual address 00000010 pgd = ffffffc9750dd000 [00000010] *pgd=00000009f5e90003, *pud=00000009f5e90003, *pmd=0000000000000000 Internal error: Oops: 96000006 [#1] PREEMPT SMP Modules linked in: CPU: 4 PID: 1348 Comm: bash Not tainted 4.6.0-next-20160517 #1646 Hardware name: ARM Juno development board (r0) (DT) task: ffffffc97517a280 ti: ffffffc9762c4000 task.ti: ffffffc9762c4000 PC is at _coresight_build_path+0x18/0xe4 LR is at _coresight_build_path+0xc0/0xe4 pc : [] lr : [] pstate: 20000145 sp : ffffffc9762c7ba0 [] _coresight_build_path+0x18/0xe4 [] _coresight_build_path+0xc0/0xe4 [] _coresight_build_path+0xc0/0xe4 [] _coresight_build_path+0xc0/0xe4 [] _coresight_build_path+0xc0/0xe4 [] _coresight_build_path+0xc0/0xe4 [] coresight_build_path+0x40/0x68 [] coresight_enable+0x74/0x1bc [] enable_source_store+0x3c/0x6c [] dev_attr_store+0x18/0x28 [] sysfs_kf_write+0x40/0x50 [] kernfs_fop_write+0x140/0x1cc [] __vfs_write+0x28/0x110 [] vfs_write+0xa0/0x174 [] SyS_write+0x44/0xa0 [] el0_svc_naked+0x24/0x28 Cc: Mathieu Poirier Signed-off-by: Suzuki K Poulose Signed-off-by: Mathieu Poirier Signed-off-by: Greg Kroah-Hartman drivers/hwtracing/coresight/coresight.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d74ef24841a972a9abe3742a7eff51cdac73db3a Merge: 4d2ec85 62e6d1e Author: Greg Kroah-Hartman Date: Thu Jun 16 00:10:27 2016 -0700 Merge tag 'extcon-fixes-for-4.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/chanwoo/extcon into char-misc-linus Chanwoo writes: Update extcon for v4.7-rc4 This patch fixes the following issue: - In the extcon-palmas.c, fix the state of VBUS when using GPIO detection. If probe funticon don't check the state during probe, the extcon client driver cannot get the state of VBUS gpio until the user detach the connector and attach the connector again. commit 13eab83f9b3566ab425a43bb65b2ba22cb0abbba Merge: 8c08c732 a59e6d8 Author: David S. Miller Date: Wed Jun 15 23:39:18 2016 -0700 Merge branch 'r8152-fixes' Hayes Wang says: ==================== r8152: fix known issues These patches fix some known issues. ==================== Signed-off-by: David S. Miller commit a59e6d815226b70780427648e359da9bbee07171 Author: hayeswang Date: Thu Jun 16 10:55:19 2016 +0800 r8152: correct the rx early size The rx early size should be (agg_buf_sz - packet size) / 8 Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 93fe9b1838404fcc3bea320b704bfa461d8e57a6 Author: hayeswang Date: Thu Jun 16 10:55:18 2016 +0800 r8152: reset the bmu Reset the BMU to clear the rx/tx fifo. This avoids that the unexpected data remains in the hw. Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 4e384ac19b5be6ad084b215d298b82b3a91ad24b Author: hayeswang Date: Thu Jun 16 10:55:17 2016 +0800 r8152: disable MAC clock speed down Disable MAC clock speed down. It may casue the first control transfer to contain the wrong data, when the power state change from U1 to U0. Signed-off-by: Hayes Wang Signed-off-by: David S. Miller drivers/net/usb/r8152.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit 8c08c7325ec36c9d338cedebc4570b567fa9a740 Merge: e582615 ad572d1 Author: David S. Miller Date: Wed Jun 15 23:37:55 2016 -0700 Merge branch 'bpf-fixes' Alexei Starovoitov says: ==================== bpf fixes Fixes for two bpf bugs: 1st bug reported by Sasha Goldshtein here: https://github.com/iovisor/bcc/issues/570 2nd discovered by Daniel Borkmann by manual code analysis. See patches for details. ==================== Signed-off-by: David S. Miller commit ad572d174787daa59e24b8b5c83028c09cdb5ddb Author: Alexei Starovoitov Date: Wed Jun 15 18:25:39 2016 -0700 bpf, trace: check event type in bpf_perf_event_read similar to bpf_perf_event_output() the bpf_perf_event_read() helper needs to check the type of the perf_event before reading the counter. Fixes: a43eec304259 ("bpf: introduce bpf_perf_event_output() helper") Reported-by: Daniel Borkmann Signed-off-by: Alexei Starovoitov Acked-by: Daniel Borkmann Signed-off-by: David S. Miller kernel/trace/bpf_trace.c | 4 ++++ 1 file changed, 4 insertions(+) commit 19de99f70b87fcc3338da52a89c439b088cbff71 Author: Alexei Starovoitov Date: Wed Jun 15 18:25:38 2016 -0700 bpf: fix matching of data/data_end in verifier The ctx structure passed into bpf programs is different depending on bpf program type. The verifier incorrectly marked ctx->data and ctx->data_end access based on ctx offset only. That caused loads in tracing programs int bpf_prog(struct pt_regs *ctx) { .. ctx->ax .. } to be incorrectly marked as PTR_TO_PACKET which later caused verifier to reject the program that was actually valid in tracing context. Fix this by doing program type specific matching of ctx offsets. Fixes: 969bf05eb3ce ("bpf: direct packet access") Reported-by: Sasha Goldshtein Signed-off-by: Alexei Starovoitov Acked-by: Daniel Borkmann Signed-off-by: David S. Miller include/linux/bpf.h | 28 +++++++++++++++++++++++++++- kernel/bpf/verifier.c | 41 +++++++---------------------------------- kernel/trace/bpf_trace.c | 6 ++++-- net/core/filter.c | 16 ++++++++++++++-- 4 files changed, 52 insertions(+), 39 deletions(-) commit d325ea859490511322d1f151dc38577ee9a7c6da Merge: e05d2ba 0ab15bd Author: Linus Torvalds Date: Wed Jun 15 19:54:52 2016 -1000 Merge tag 'drm-fixes-for-v4.7-rc4' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "The main drm fixes pull for rc4: one regression fix in the connector refcounting, and an MST fix. There rest is nouveau, amdkfd, i915, etnaviv, and radeon/amdgpu fixes, mostly regression or black screen fixes" * tag 'drm-fixes-for-v4.7-rc4' of git://people.freedesktop.org/~airlied/linux: (23 commits) drm/etnaviv: initialize iommu domain page size drm/nouveau/iccsense: fix memory leak drm/nouveau/Revert "drm/nouveau/device/pci: set as non-CPU-coherent on ARM64" drm/amd/powerplay: select samu dpm 0 as boot level on polaris. drm/amd/powerplay: update powerplay table parsing drm/dp/mst: Always clear proposed vcpi table for port. drm/crtc: only store the necessary data for set_config rollback drm/crtc: fix connector reference counting mismatch in drm_crtc_helper_set_config drm/i915/ilk: Don't disable SSC source if it's in use Revert "drm/amdgpu: add pipeline sync while vmid switch in same ctx" drm/amdgpu/gfx7: fix broken condition check drm/radeon: fix asic initialization for virtualized environments amdgpu: fix asic initialization for virtualized environments (v2) drm/radeon: don't use fractional dividers on RS[78]80 if SS is enabled drm/radeon: do not hard reset GPU while freezing on r600/r700 family drm/i915: Extract physical display dimensions from VBT drm/i915: Check VBT for port presence in addition to the strap on VLV/CHV drm/i915: Only ignore eDP ports that are connected drm/i915: Silence "unexpected child device config size" for VBT on 845g drm/i915: Fix NULL pointer deference when out of PLLs in IVB ... commit e05d2ba145fc43479bc52eb6dabef69721da39a5 Merge: abd3830 25789f9 Author: Linus Torvalds Date: Wed Jun 15 19:42:19 2016 -1000 Merge tag 'platform-drivers-x86-v4.7-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86 Pull x86 platform driver fixes from Darren Hart: "Minor kconfig dependency cleanup, trivial mic mute hotkey for ideapad, and a needed improvement in adaptive keyboard detection for thinkpad: platform/x86: - Drop duplicate dependencies on X86 thinkpad_acpi: - Add support for HKEY version 0x200 ideapad_laptop: - Add an event for mic mute hotkey" * tag 'platform-drivers-x86-v4.7-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86: platform/x86: Drop duplicate dependencies on X86 thinkpad_acpi: Add support for HKEY version 0x200 ideapad_laptop: Add an event for mic mute hotkey commit e582615ad33dbd39623084a02e95567b116e1eea Author: Eric Dumazet Date: Wed Jun 15 06:24:00 2016 -0700 gre: fix error handler 1) gre_parse_header() can be called from gre_err() At this point transport header points to ICMP header, not the inner header. 2) We can not really change transport header as ipgre_err() will later assume transport header still points to ICMP header (using icmp_hdr()) 3) pskb_may_pull() logic in gre_parse_header() really works if we are interested at zone pointed by skb->data 4) As Jiri explained in commit b7f8fe251e46 ("gre: do not pull header in ICMP error processing") we should not pull headers in error handler. So this fix : A) changes gre_parse_header() to use skb->data instead of skb_transport_header() B) Adds a nhs parameter to gre_parse_header() so that we can skip the not pulled IP header from error path. This offset is 0 for normal receive path. C) remove obsolete IPV6 includes Signed-off-by: Eric Dumazet Cc: Tom Herbert Cc: Maciej Żenczykowski Cc: Jiri Benc Signed-off-by: David S. Miller include/net/gre.h | 2 +- net/ipv4/gre_demux.c | 10 +++++----- net/ipv4/ip_gre.c | 12 ++++-------- net/ipv6/ip6_gre.c | 2 +- 4 files changed, 11 insertions(+), 15 deletions(-) commit daddef76c3deaaa7922f9d7b18edbf0a061215c3 Author: Jason A. Donenfeld Date: Wed Jun 15 11:14:53 2016 +0200 net: Don't forget pr_fmt on net_dbg_ratelimited for CONFIG_DYNAMIC_DEBUG The implementation of net_dbg_ratelimited in the CONFIG_DYNAMIC_DEBUG case was added with 2c94b5373 ("net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case"). The implementation strategy was to take the usual definition of the dynamic_pr_debug macro, but alter it by adding a call to "net_ratelimit()" in the if statement. This is, in fact, the correct approach. However, while doing this, the author of the commit forgot to surround fmt by pr_fmt, resulting in unprefixed log messages appearing in the console. So, this commit adds back the pr_fmt(fmt) invocation, making net_dbg_ratelimited properly consistent across DEBUG, no DEBUG, and DYNAMIC_DEBUG cases, and bringing parity with the behavior of dynamic_pr_debug as well. Fixes: 2c94b5373 ("net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case") Signed-off-by: Jason A. Donenfeld Cc: Tim Bingham Signed-off-by: David S. Miller include/linux/net.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 4a1836701fd59476ee1331379e00a9ab51ba4f61 Author: Arnd Bergmann Date: Wed Jun 15 17:45:51 2016 +0200 net: skfb: remove obsolete -I cflag The skfp driver has been moved to drivers/net/fddi/skfp a long time ago, but we still attempt to include headers from the old location, which causes a warning when building with W=1: cc1: error: /git/arm-soc/drivers/net/skfp: No such file or directory [-Werror=missing-include-dirs] cc1: error: drivers/net/skfp: No such file or directory [-Werror=missing-include-dirs] Clearly this include directive is not needed any more, so we can just remove it now. Signed-off-by: Arnd Bergmann Signed-off-by: David S. Miller drivers/net/fddi/skfp/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c91522f860bb9dd4178c8280bbebd4f4321b7199 Author: Ying Xue Date: Wed Jun 15 14:11:31 2016 +0800 tipc: eliminate uninitialized variable warning net/tipc/link.c: In function ‘tipc_link_timeout’: net/tipc/link.c:744:28: warning: ‘mtyp’ may be used uninitialized in this function [-Wuninitialized] Fixes: 42b18f605fea ("tipc: refactor function tipc_link_timeout()") Acked-by: Jon Maloy Signed-off-by: Ying Xue Signed-off-by: David S. Miller net/tipc/link.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 66d95b6705a6347f7b2645e042874ec0bb03b726 Author: Ying Xue Date: Wed Jun 15 14:10:57 2016 +0800 tipc: fix suspicious RCU usage When run tipcTS&tipcTC test suite, the following complaint appears: [ 56.926168] =============================== [ 56.926169] [ INFO: suspicious RCU usage. ] [ 56.926171] 4.7.0-rc1+ #160 Not tainted [ 56.926173] ------------------------------- [ 56.926174] net/tipc/bearer.c:408 suspicious rcu_dereference_protected() usage! [ 56.926175] [ 56.926175] other info that might help us debug this: [ 56.926175] [ 56.926177] [ 56.926177] rcu_scheduler_active = 1, debug_locks = 1 [ 56.926179] 3 locks held by swapper/4/0: [ 56.926180] #0: (((&req->timer))){+.-...}, at: [] call_timer_fn+0x5/0x340 [ 56.926203] #1: (&(&req->lock)->rlock){+.-...}, at: [] disc_timeout+0x1b/0xd0 [tipc] [ 56.926212] #2: (rcu_read_lock){......}, at: [] tipc_bearer_xmit_skb+0xb0/0x2e0 [tipc] [ 56.926218] [ 56.926218] stack backtrace: [ 56.926221] CPU: 4 PID: 0 Comm: swapper/4 Not tainted 4.7.0-rc1+ #160 [ 56.926222] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2007 [ 56.926224] 0000000000000000 ffff880016803d28 ffffffff813c4423 ffff8800154252c0 [ 56.926227] 0000000000000001 ffff880016803d58 ffffffff810b7512 ffff8800124d8120 [ 56.926230] ffff880013f8a160 ffff8800132b5ccc ffff8800124d8120 ffff880016803d88 [ 56.926234] Call Trace: [ 56.926235] [] dump_stack+0x67/0x94 [ 56.926250] [] lockdep_rcu_suspicious+0xe2/0x120 [ 56.926256] [] tipc_l2_send_msg+0x131/0x1c0 [tipc] [ 56.926261] [] tipc_bearer_xmit_skb+0x14c/0x2e0 [tipc] [ 56.926266] [] ? tipc_bearer_xmit_skb+0xb0/0x2e0 [tipc] [ 56.926273] [] ? tipc_disc_init_msg+0x1f0/0x1f0 [tipc] [ 56.926278] [] ? tipc_disc_init_msg+0x1f0/0x1f0 [tipc] [ 56.926283] [] disc_timeout+0x56/0xd0 [tipc] [ 56.926288] [] call_timer_fn+0xb8/0x340 [ 56.926291] [] ? call_timer_fn+0x5/0x340 [ 56.926296] [] ? tipc_disc_init_msg+0x1f0/0x1f0 [tipc] [ 56.926300] [] run_timer_softirq+0x23a/0x390 [ 56.926306] [] ? clockevents_program_event+0x7f/0x130 [ 56.926316] [] __do_softirq+0xc3/0x4a2 [ 56.926323] [] irq_exit+0x8a/0xb0 [ 56.926327] [] smp_apic_timer_interrupt+0x46/0x60 [ 56.926331] [] apic_timer_interrupt+0x89/0x90 [ 56.926333] [] ? default_idle+0x2a/0x1a0 [ 56.926340] [] ? default_idle+0x28/0x1a0 [ 56.926342] [] arch_cpu_idle+0xf/0x20 [ 56.926345] [] default_idle_call+0x2f/0x50 [ 56.926347] [] cpu_startup_entry+0x215/0x3e0 [ 56.926353] [] start_secondary+0xf9/0x100 The warning appears as rtnl_dereference() is wrongly used in tipc_l2_send_msg() under RCU read lock protection. Instead the proper usage should be that rcu_dereference_rtnl() is called here. Fixes: 5b7066c3dd24 ("tipc: stricter filtering of packets in bearer layer") Acked-by: Jon Maloy Signed-off-by: Ying Xue Signed-off-by: David S. Miller net/tipc/bearer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit abd38301639f4fa2e63dae75346c1f0d847d0dfa Merge: f66c6e6 61edc3f Author: Linus Torvalds Date: Wed Jun 15 16:23:38 2016 -1000 Merge tag 'upstream-4.7-rc4' of git://git.infradead.org/linux-ubifs Pull UBI fixes from Richard Weinberger: "This contains fixes for a regression introduced in rc1" * tag 'upstream-4.7-rc4' of git://git.infradead.org/linux-ubifs: ubi: Don't bypass ->getattr() Revert "mtd: switch open_mtd_by_chdev() to use of vfs_stat()" Revert "mtd: switch ubi_open_volume_path() to vfs_stat()" commit 7e1b1fc4dabd6ec8e28baa0708866e13fa93c9b3 Author: Jiri Slaby Date: Fri Jun 10 10:54:32 2016 +0200 base: make module_create_drivers_dir race-free Modules which register drivers via standard path (driver_register) in parallel can cause a warning: WARNING: CPU: 2 PID: 3492 at ../fs/sysfs/dir.c:31 sysfs_warn_dup+0x62/0x80 sysfs: cannot create duplicate filename '/module/saa7146/drivers' Modules linked in: hexium_gemini(+) mxb(+) ... ... Call Trace: ... [] sysfs_warn_dup+0x62/0x80 [] sysfs_create_dir_ns+0x77/0x90 [] kobject_add_internal+0xb4/0x340 [] kobject_add+0x68/0xb0 [] kobject_create_and_add+0x31/0x70 [] module_add_driver+0xc3/0xd0 [] bus_add_driver+0x154/0x280 [] driver_register+0x60/0xe0 [] __pci_register_driver+0x60/0x70 [] saa7146_register_extension+0x64/0x90 [saa7146] [] hexium_init_module+0x11/0x1000 [hexium_gemini] ... As can be (mostly) seen, driver_register causes this call sequence: -> bus_add_driver -> module_add_driver -> module_create_drivers_dir The last one creates "drivers" directory in /sys/module/<...>. When this is done in parallel, the directory is attempted to be created twice at the same time. This can be easily reproduced by loading mxb and hexium_gemini in parallel: while :; do modprobe mxb & modprobe hexium_gemini wait rmmod mxb hexium_gemini saa7146_vv saa7146 done saa7146 calls pci_register_driver for both mxb and hexium_gemini, which means /sys/module/saa7146/drivers is to be created for both of them. Fix this by a new mutex in module_create_drivers_dir which makes the test-and-create "drivers" dir atomic. I inverted the condition and removed 'return' to avoid multiple unlocks or a goto. Signed-off-by: Jiri Slaby Fixes: fe480a2675ed (Modules: only add drivers/ direcory if needed) Cc: v2.6.21+ Signed-off-by: Greg Kroah-Hartman drivers/base/module.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit f66c6e6a840f94ad175c76fd51dc1af2f2d63cf3 Merge: 78ae255 ae4ea9a Author: Linus Torvalds Date: Wed Jun 15 16:08:31 2016 -1000 Merge tag 'for-linus-4.7-2' of git://git.code.sf.net/p/openipmi/linux-ipmi Pull ipmi bugfix from Corey Minyard: "Fix a fairly significant ipmi list bug This bug could cause lists to be corrupted" * tag 'for-linus-4.7-2' of git://git.code.sf.net/p/openipmi/linux-ipmi: ipmi: Remove smi_msg from waiting_rcv_msgs list before handle_one_recv_msg() commit 8c7245abda877d4689b3371db8ae2a4400d7d9ce Author: Oleg Drokin Date: Tue Jun 14 23:28:06 2016 -0400 nfsd: Make init_open_stateid() a bit more whole Move the state selection logic inside from the caller, always making it return correct stp to use. Signed-off-by: J . Bruce Fields Signed-off-by: Oleg Drokin Signed-off-by: J. Bruce Fields fs/nfsd/nfs4state.c | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) commit 5cc1fb2a093e254b656c64ff24b0b76bed1d34d9 Author: Oleg Drokin Date: Tue Jun 14 23:28:05 2016 -0400 nfsd: Extend the mutex holding region around in nfsd4_process_open2() To avoid racing entry into nfs4_get_vfs_file(). Make init_open_stateid() return with locked stateid to be unlocked by the caller. Signed-off-by: Oleg Drokin Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields fs/nfsd/nfs4state.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit feb9dad5209280085d5b0c094fa67e7a8d75c81a Author: Oleg Drokin Date: Tue Jun 14 23:28:04 2016 -0400 nfsd: Always lock state exclusively. It used to be the case that state had an rwlock that was locked for write by downgrades, but for read for upgrades (opens). Well, the problem is if there are two competing opens for the same state, they step on each other toes potentially leading to leaking file descriptors from the state structure, since access mode is a bitmap only set once. Signed-off-by: Oleg Drokin Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields fs/nfsd/nfs4state.c | 40 ++++++++++++++++++++-------------------- fs/nfsd/state.h | 2 +- 2 files changed, 21 insertions(+), 21 deletions(-) commit 78ae255f7891d41fe4ed492f270fe663f4b261af Merge: 90effdc 139ab4d Author: Linus Torvalds Date: Wed Jun 15 15:55:49 2016 -1000 Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost Pull virtio docs and tests from Michael Tsirkin: "This merely has some documentation and a new test, seems safe to merge" * tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost: tools/virtio: add noring tool tools/virtio/ringtest: fix run-on-all.sh to work without /dev/cpu tools/virtio/ringtest: add usage example to README MAINTAINERS: Add file patterns for virtio device tree bindings commit 90effdcd2b8a39927aace655c72088a62911e8e1 Author: Shuah Khan Date: Tue Jun 14 16:30:27 2016 -0600 Update email addresses in MAINTAINERS and .mailmap Updating email addresses in MAINTAINERS and .mailmap files. Cc: stable@vger.kernel.org Signed-off-by: Shuah Khan Signed-off-by: Linus Torvalds .mailmap | 1 + MAINTAINERS | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) commit 5dc8a864be0820677e7fce85d2832d4387c7bb88 Author: Mauro Carvalho Chehab Date: Tue Jun 14 15:17:40 2016 -0300 Update my main e-mails at the Kernel tree For the third time in three years, I'm changing my e-mail at Samsung. That's bad, as it may stop communications with me for a while. So, this time, I'll also add the mchehab@kernel.org e-mail, as it remains stable since ever. Cc: stable@vger.kernel.org Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Linus Torvalds .mailmap | 1 + CREDITS | 1 + MAINTAINERS | 51 ++++++++++++++++++++++++++------------- drivers/media/v4l2-core/v4l2-mc.c | 2 +- include/media/v4l2-mc.h | 2 +- 5 files changed, 38 insertions(+), 19 deletions(-) commit 0ab15bdeb2943bd6491a35ec4eeb53a9a4436525 Merge: d9724d3 871fd84 Author: Dave Airlie Date: Thu Jun 16 10:24:13 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes radeon and amdgpu fixes for 4.7. Highlights: - fixes for GPU VM passthrough - fixes for powerplay on Polaris GPUs - pll fixes for rs780/880 * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: drm/amd/powerplay: select samu dpm 0 as boot level on polaris. drm/amd/powerplay: update powerplay table parsing Revert "drm/amdgpu: add pipeline sync while vmid switch in same ctx" drm/amdgpu/gfx7: fix broken condition check drm/radeon: fix asic initialization for virtualized environments amdgpu: fix asic initialization for virtualized environments (v2) drm/radeon: don't use fractional dividers on RS[78]80 if SS is enabled drm/radeon: do not hard reset GPU while freezing on r600/r700 family commit 5b8abf1f33ccd9f1cbc4248ade3cd507d9319c48 Author: Suravee Suthikulpanit Date: Wed Jun 15 17:24:36 2016 -0500 kvm: svm: Do not support AVIC if not CONFIG_X86_LOCAL_APIC Add logic to disable AVIC #ifndef CONFIG_X86_LOCAL_APIC. Suggested-by: Paolo Bonzini Signed-off-by: Suravee Suthikulpanit Signed-off-by: Paolo Bonzini arch/x86/kvm/svm.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 7d669f50847481c52faf0656aea7b4be63113210 Author: Suravee Suthikulpanit Date: Wed Jun 15 17:23:45 2016 -0500 kvm: svm: Fix implicit declaration for __default_cpu_present_to_apicid() The commit 8221c1370056 ("svm: Manage vcpu load/unload when enable AVIC") introduces a build error due to implicit function declaration when #ifdef CONFIG_X86_32 and #ifndef CONFIG_X86_LOCAL_APIC (as reported by Kbuild test robot i386-randconfig-x0-06121009). So, this patch introduces kvm_cpu_get_apicid() wrapper around __default_cpu_present_to_apicid() with additional handling if CONFIG_X86_LOCAL_APIC is not defined. Reported-by: kbuild test robot Fixes: commit 8221c1370056 ("svm: Manage vcpu load/unload when enable AVIC") Signed-off-by: Suravee Suthikulpanit Signed-off-by: Paolo Bonzini arch/x86/include/asm/kvm_host.h | 11 +++++++++++ arch/x86/kvm/svm.c | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) commit e4587ea1d748953e17ddee8f30994899ae73b677 Merge: 0ee1362 6052f7f Author: David S. Miller Date: Wed Jun 15 14:47:46 2016 -0700 Merge branch 'macsec-fixes' Sabrina Dubroca says: ==================== macsec fixes Patch 1 adds rcu_barrier() during module unload to prevent possible panics. Patch 2 allocates memory for scattergather lists and the IV on the heap, since they can escape the current function's context during crypto callbacks. Patch 3 fixes a failure to create secure associations. ==================== Signed-off-by: David S. Miller commit 6052f7fbce857e327218a9d8a040e210ea7cc718 Author: Sabrina Dubroca Date: Tue Jun 14 15:25:16 2016 +0200 macsec: fix SA initialization The ASYNC flag prevents initialization on some physical machines. Fixes: c09440f7dcb3 ("macsec: introduce IEEE 802.1AE driver") Signed-off-by: Sabrina Dubroca Signed-off-by: David S. Miller drivers/net/macsec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5d9649b3a524df9ccd15ac25ad6591089260fdbd Author: Sabrina Dubroca Date: Tue Jun 14 15:25:15 2016 +0200 macsec: allocate sg and iv on the heap For the crypto callbacks to work properly, we cannot have sg and iv on the stack. Use kmalloc instead, with a single allocation for aead_request + scatterlist + iv. Fixes: c09440f7dcb3 ("macsec: introduce IEEE 802.1AE driver") Signed-off-by: Sabrina Dubroca Acked-by: Hannes Frederic Sowa Signed-off-by: David S. Miller drivers/net/macsec.c | 46 +++++++++++++++++++++++++++++++++++++--------- 1 file changed, 37 insertions(+), 9 deletions(-) commit b196c22af5c3ff784c472c80f6fb4e5fad67b2ac Author: Sabrina Dubroca Date: Tue Jun 14 15:25:14 2016 +0200 macsec: add rcu_barrier() on module exit Without this, the various uses of call_rcu could cause a kernel panic. Fixes: c09440f7dcb3 ("macsec: introduce IEEE 802.1AE driver") Signed-off-by: Sabrina Dubroca Acked-by: Hannes Frederic Sowa Signed-off-by: David S. Miller drivers/net/macsec.c | 1 + 1 file changed, 1 insertion(+) commit 0ee13627f963f9c5c9544ed19d82854836d5e676 Author: Florian Westphal Date: Tue Jun 14 06:16:27 2016 +0200 htb: call qdisc_root with rcu read lock held saw a debug splat: net/include/net/sch_generic.h:287 suspicious rcu_dereference_check() usage! other info that might help us debug this: rcu_scheduler_active = 1, debug_locks = 0 2 locks held by kworker/2:1/710: #0: ("events"){.+.+.+}, at: [] #1: ((&q->work)){+.+...}, at: [] process_one_work+0x14d/0x690 Workqueue: events htb_work_func Call Trace: [] dump_stack+0x85/0xc2 [] lockdep_rcu_suspicious+0xe7/0x120 [] htb_work_func+0x67/0x70 Signed-off-by: Florian Westphal Acked-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_htb.c | 2 ++ 1 file changed, 2 insertions(+) commit ebecaa6662b0a9c3590bd644a4cec6f9d96818b7 Author: Jamal Hadi Salim Date: Mon Jun 13 18:08:42 2016 -0400 net sched actions: bug fix dumping actions directly didnt produce NLMSG_DONE This refers to commands to direct action access as follows: sudo tc actions add action drop index 12 sudo tc actions add action pipe index 10 And then dumping them like so: sudo tc actions ls action gact iproute2 worked because it depended on absence of TCA_ACT_TAB TLV as end of message. This fix has been tested with iproute2 and is backward compatible. Signed-off-by: Jamal Hadi Salim Acked-by: Cong Wang Signed-off-by: David S. Miller net/sched/act_api.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d9724d3b1d007fa042c768a2eec708f33d70539d Merge: e43fc94 13c34fe Author: Dave Airlie Date: Thu Jun 16 06:27:05 2016 +1000 Merge branch 'drm-etnaviv-fixes' of git://git.pengutronix.de/git/lst/linux into drm-fixes just a single fix for a regression introduced by IOMMU API changes in v4.7. * 'drm-etnaviv-fixes' of git://git.pengutronix.de/git/lst/linux: drm/etnaviv: initialize iommu domain page size commit d15eccea69b96a5116169688dcc9baf6d1ce2751 Author: WANG Cong Date: Mon Jun 13 13:44:14 2016 -0700 act_ipt: fix a bind refcnt leak And avoid calling tcf_hash_check() twice. Fixes: a57f19d30b2d ("net sched: ipt action fix late binding") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Acked-by: Jamal Hadi Salim Signed-off-by: David S. Miller net/sched/act_ipt.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 3d7c8257d999bdf8fa77ffd9be775c7b58cc7b69 Author: Eric Dumazet Date: Mon Jun 13 11:33:32 2016 -0700 net_sched: prio: insure proper transactional behavior Now prio_init() can return -ENOMEM, it also has to make sure any allocated qdiscs are freed, since the caller (qdisc_create()) wont call ->destroy() handler for us. More generally, we want a transactional behavior for "tc qdisc change ...", so prio_tune() should not make modifications if any error is returned. It means that we must validate parameters and allocate missing qdisc(s) before taking root qdisc lock exactly once, to not leave the prio qdisc in an intermediate state. Fixes: cbdf45116478 ("net_sched: prio: properly report out of memory errors") Signed-off-by: Eric Dumazet Reported-by: Cong Wang Acked-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_prio.c | 57 +++++++++++++++++++++------------------------------- 1 file changed, 23 insertions(+), 34 deletions(-) commit 0c5ddb51e8f7be7170600f95a4ea92e5a32afad8 Author: Eric Dumazet Date: Mon Jun 13 07:50:25 2016 -0700 net/mlx4_en: initialize cmd.context_lock spinlock earlier Maciej Żenczykowski reported lockdep warning a spinlock was not registered before being held in mlx4_cmd_wake_completions() cmd.context_lock initialization is not at the right place. 1) mlx4_cmd_use_events() can be called multiple times. Calling spin_lock_init() on a live spinlock can lead to hangs. 2) mlx4_cmd_wake_completions() can be called while lock has not been initialized. Lockdep complains, and current logic is not race prone. It seems better to move the initialization earlier in mlx4_load_one() Signed-off-by: Eric Dumazet Reported-by: Maciej Żenczykowski Cc: Eugenia Emantayev Cc: Tariq Toukan Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx4/cmd.c | 1 - drivers/net/ethernet/mellanox/mlx4/main.c | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) commit f52a4c74efbb61195490535e9d65d964c4ebfee3 Author: Wei Yongjun Date: Tue Jun 14 00:26:49 2016 +0000 ata: fix return value check in ahci_seattle_get_port_info() In case of error, the function devm_kzalloc() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Signed-off-by: Wei Yongjun Acked-by: Brijesh Singh Signed-off-by: Tejun Heo drivers/ata/ahci_seattle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 39a9beab5acb83176e8b9a4f0778749a09341f1f Author: J. Bruce Fields Date: Tue May 17 12:38:21 2016 -0400 rpc: share one xps between all backchannels The spec allows backchannels for multiple clients to share the same tcp connection. When that happens, we need to use the same xprt for all of them. Similarly, we need the same xps. This fixes list corruption introduced by the multipath code. Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields Acked-by: Trond Myklebust include/linux/sunrpc/svc_xprt.h | 1 + include/linux/sunrpc/xprt.h | 1 + net/sunrpc/clnt.c | 18 ++++++++++++++---- net/sunrpc/svc_xprt.c | 2 ++ net/sunrpc/xprtsock.c | 1 + 5 files changed, 19 insertions(+), 4 deletions(-) commit d50039ea5ee63c589b0434baa5ecf6e5075bb6f9 Author: J. Bruce Fields Date: Mon May 16 17:03:42 2016 -0400 nfsd4/rpc: move backchannel create logic into rpc code Also simplify the logic a bit. Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields Acked-by: Trond Myklebust fs/nfsd/nfs4callback.c | 18 +----------------- include/linux/sunrpc/clnt.h | 2 -- net/sunrpc/clnt.c | 12 ++++++++++-- 3 files changed, 11 insertions(+), 21 deletions(-) commit 1208fd569c07ab84aa5d024abd863267c2953b4a Author: J. Bruce Fields Date: Fri May 20 17:07:17 2016 -0400 SUNRPC: fix xprt leak on xps allocation failure Callers of rpc_create_xprt expect it to put the xprt on success and failure. Cc: stable@vger.kernel.org Signed-off-by: J. Bruce Fields Acked-by: Trond Myklebust net/sunrpc/clnt.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit d0e13f5bbe4be7c8f27736fc40503dcec04b7de0 Author: Miklos Szeredi Date: Wed Jun 15 14:18:59 2016 +0200 ovl: fix uid/gid when creating over whiteout Fix a regression when creating a file over a whiteout. The new file/directory needs to use the current fsuid/fsgid, not the ones from the mounter's credentials. The refcounting is a bit tricky: prepare_creds() sets an original refcount, override_creds() gets one more, which revert_cred() drops. So 1) we need to expicitly put the mounter's credentials when overriding with the updated one 2) we need to put the original ref to the updated creds (and this can safely be done before revert_creds(), since we'll still have the ref from override_creds()). Reported-by: Stephen Smalley Fixes: 3fe6e52f0626 ("ovl: override creds with the ones from the superblock mounter") Signed-off-by: Miklos Szeredi fs/overlayfs/dir.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 75f0b68b75dabb3ff551440163fd67b3fc62901a Author: Nicolai Stange Date: Tue May 24 13:08:54 2016 +0200 debugfs: open_proxy_open(): avoid double fops release Debugfs' open_proxy_open(), the ->open() installed at all inodes created through debugfs_create_file_unsafe(), - grabs a reference to the original file_operations instance passed to debugfs_create_file_unsafe() via fops_get(), - installs it at the file's ->f_op by means of replace_fops() - and calls fops_put() on it. Since the semantics of replace_fops() are such that the reference's ownership is transferred, the subsequent fops_put() will result in a double release when the file is eventually closed. Currently, this is not an issue since fops_put() basically does a module_put() on the file_operations' ->owner only and there don't exist any modules calling debugfs_create_file_unsafe() yet. This is expected to change in the future though, c.f. commit c64688081490 ("debugfs: add support for self-protecting attribute file fops"). Remove the call to fops_put() from open_proxy_open(). Fixes: 9fd4dcece43a ("debugfs: prevent access to possibly dead file_operations at file open") Signed-off-by: Nicolai Stange Signed-off-by: Greg Kroah-Hartman fs/debugfs/file.c | 1 - 1 file changed, 1 deletion(-) commit b10e3e90485e32e4cea9e35d2295ee7bffaeff73 Author: Nicolai Stange Date: Tue May 24 13:08:53 2016 +0200 debugfs: full_proxy_open(): free proxy on ->open() failure Debugfs' full_proxy_open(), the ->open() installed at all inodes created through debugfs_create_file(), - grabs a reference to the original struct file_operations instance passed to debugfs_create_file(), - dynamically allocates a proxy struct file_operations instance wrapping the original - and installs this at the file's ->f_op. Afterwards, it calls the original ->open() and passes its return value back to the VFS layer. Now, if that return value indicates failure, the VFS layer won't ever call ->release() and thus, neither the reference to the original file_operations nor the memory for the proxy file_operations will get released, i.e. both are leaked. Upon failure of the original fops' ->open(), undo the proxy installation. That is: - Set the struct file ->f_op to what it had been when full_proxy_open() was entered. - Drop the reference to the original file_operations. - Free the memory holding the proxy file_operations. Fixes: 49d200deaa68 ("debugfs: prevent access to removed files' private data") Signed-off-by: Nicolai Stange Signed-off-by: Greg Kroah-Hartman fs/debugfs/file.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit df4565f9ebdc4d6dc50edc6e8fed08004e328332 Author: Nicolai Stange Date: Tue May 24 14:05:05 2016 +0200 kernel/kcov: unproxify debugfs file's fops Since commit 49d200deaa68 ("debugfs: prevent access to removed files' private data"), a debugfs file's file_operations methods get proxied through lifetime aware wrappers. However, only a certain subset of the file_operations members is supported by debugfs and ->mmap isn't among them -- it appears to be NULL from the VFS layer's perspective. This behaviour breaks the /sys/kernel/debug/kcov file introduced concurrently with commit 5c9a8750a640 ("kernel: add kcov code coverage"). Since that file never gets removed, there is no file removal race and thus, a lifetime checking proxy isn't needed. Avoid the proxying for /sys/kernel/debug/kcov by creating it via debugfs_create_file_unsafe() rather than debugfs_create_file(). Fixes: 49d200deaa68 ("debugfs: prevent access to removed files' private data") Fixes: 5c9a8750a640 ("kernel: add kcov code coverage") Reported-by: Sasha Levin Signed-off-by: Nicolai Stange Signed-off-by: Greg Kroah-Hartman kernel/kcov.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 695e9df010e40f407f4830dc11d53dce957710ba Author: Eric W. Biederman Date: Fri Jun 10 12:21:40 2016 -0500 mnt: Account for MS_RDONLY in fs_fully_visible In rare cases it is possible for s_flags & MS_RDONLY to be set but MNT_READONLY to be clear. This starting combination can cause fs_fully_visible to fail to ensure that the new mount is readonly. Therefore force MNT_LOCK_READONLY in the new mount if MS_RDONLY is set on the source filesystem of the mount. In general both MS_RDONLY and MNT_READONLY are set at the same for mounts so I don't expect any programs to care. Nor do I expect MS_RDONLY to be set on proc or sysfs in the initial user namespace, which further decreases the likelyhood of problems. Which means this change should only affect system configurations by paranoid sysadmins who should welcome the additional protection as it keeps people from wriggling out of their policies. Cc: stable@vger.kernel.org Fixes: 8c6cf9cc829f ("mnt: Modify fs_fully_visible to deal with locked ro nodev and atime") Signed-off-by: "Eric W. Biederman" fs/namespace.c | 4 ++++ 1 file changed, 4 insertions(+) commit c56bdcac153e60d96a619a59c7981f2a78cba598 Author: Will Deacon Date: Thu Jun 2 18:40:07 2016 +0100 arm64: spinlock: Ensure forward-progress in spin_unlock_wait Rather than wait until we observe the lock being free (which might never happen), we can also return from spin_unlock_wait if we observe that the lock is now held by somebody else, which implies that it was unlocked but we just missed seeing it in that state. Furthermore, in such a scenario there is no longer a need to write back the value that we loaded, since we know that there has been a lock hand-off, which is sufficient to publish any stores prior to the unlock_wait because the ARm architecture ensures that a Store-Release instruction is multi-copy atomic when observed by a Load-Acquire instruction. The litmus test is something like: AArch64 { 0:X1=x; 0:X3=y; 1:X1=y; 2:X1=y; 2:X3=x; } P0 | P1 | P2 ; MOV W0,#1 | MOV W0,#1 | LDAR W0,[X1] ; STR W0,[X1] | STLR W0,[X1] | LDR W2,[X3] ; DMB SY | | ; LDR W2,[X3] | | ; exists (0:X2=0 /\ 2:X0=1 /\ 2:X2=0) where P0 is doing spin_unlock_wait, P1 is doing spin_unlock and P2 is doing spin_lock. Signed-off-by: Will Deacon arch/arm64/include/asm/spinlock.h | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) commit 8fff1722f705ce5023a0d6d77a31a9d013be2a34 Author: Liping Zhang Date: Tue Jun 14 20:13:04 2016 +0800 netfilter: nf_tables: fix a wrong check to skip the inactive rules nft_genmask_cur has already done left-shift operator on the gencursor, so there's no need to do left-shift operator on it again. Fixes: ea4bd995b0f2 ("netfilter: nf_tables: add transaction helper functions") Cc: Patrick McHardy Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_tables_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a02f424863610a0a7abd80c468839e59cfa4d0d8 Author: Liping Zhang Date: Sat Jun 11 12:20:28 2016 +0800 netfilter: nf_tables: fix wrong destroy anonymous sets if binding fails When we add a nft rule like follows: # nft add rule filter test tcp dport vmap {1: jump test} -ELOOP error will be returned, and the anonymous set will be destroyed. But after that, nf_tables_abort will also try to remove the element and destroy the set, which was already destroyed and freed. If we add a nft wrong rule, nft_tables_abort will do the cleanup work rightly, so nf_tables_set_destroy call here is redundant and wrong, remove it. Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_tables_api.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 8588ac097b49ce8802f11541d9cd6f6667badb34 Author: Pablo Neira Ayuso Date: Sat Jun 11 12:20:27 2016 +0800 netfilter: nf_tables: reject loops from set element jump to chain Liping Zhang says: "Users may add such a wrong nft rules successfully, which will cause an endless jump loop: # nft add rule filter test tcp dport vmap {1: jump test} This is because before we commit, the element in the current anonymous set is inactive, so osp->walk will skip this element and miss the validate check." To resolve this problem, this patch passes the generation mask to the walk function through the iter container structure depending on the code path: 1) If we're dumping the elements, then we have to check if the element is active in the current generation. Thus, we check for the current bit in the genmask. 2) If we're checking for loops, then we have to check if the element is active in the next generation, as we're in the middle of a transaction. Thus, we check for the next bit in the genmask. Based on original patch from Liping Zhang. Reported-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso Tested-by: Liping Zhang include/net/netfilter/nf_tables.h | 1 + net/netfilter/nf_tables_api.c | 15 +++++++++------ net/netfilter/nft_hash.c | 3 +-- net/netfilter/nft_rbtree.c | 3 +-- 4 files changed, 12 insertions(+), 10 deletions(-) commit a46844021f6182cca7b575295ba33a4734b1b9d9 Author: Liping Zhang Date: Sat Jun 11 12:20:26 2016 +0800 netfilter: nf_tables: fix wrong check of NFT_SET_MAP in nf_tables_bind_set We should check "i" is used as a dictionary or not, "binding" is already checked before. Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_tables_api.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 775711497202fe376368c25b0c7296ed8803e0ba Author: Florian Westphal Date: Fri Jun 10 17:25:19 2016 +0200 netfilter: conntrack: destroy kmemcache on module removal I forgot to move the kmem_cache_destroy into the exit path. Fixes: 0c5366b3a8c7 ("netfilter: conntrack: use single slab cache) Signed-off-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso net/netfilter/nf_conntrack_core.c | 2 ++ 1 file changed, 2 insertions(+) commit ae8a7910fb0568531033bd6ebe65590f7a4fa6e2 Author: John Keeping Date: Wed Jun 1 16:46:10 2016 +0100 iommu/rockchip: Fix zap cache during device attach rk_iommu_command() takes a struct rk_iommu and iterates over the slave MMUs, so this is doubly wrong in that we're passing in the wrong pointer and talking to MMUs that we shouldn't be. Fixes: cd6438c5f844 ("iommu/rockchip: Reconstruct to support multi slaves") Cc: stable@vger.kernel.org Signed-off-by: John Keeping Tested-by: Heiko Stuebner Reviewed-by: Heiko Stuebner Signed-off-by: Joerg Roedel drivers/iommu/rockchip-iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 43160ffd12c8d1d331362362eea3c70e04b6f9c4 Author: Axel Lin Date: Wed Jun 15 10:21:34 2016 +0800 regulator: qcom_smd: Remove list_voltage callback for rpm_smps_ldo_ops_fixed Use regulator_list_voltage_linear_range in rpm_smps_ldo_ops_fixed is wrong because it is used for fixed regulator without any linear range. The rpm_smps_ldo_ops_fixed is used for pm8941_lnldo which has fixed_uV set and n_voltages = 1. In this case, regulator_list_voltage() can return rdev->desc->fixed_uV without .list_voltage implementation. Fixes: 3bfbb4d1a480 ("regulator: qcom_smd: add list_voltage callback") Signed-off-by: Axel Lin Signed-off-by: Mark Brown drivers/regulator/qcom_smd-regulator.c | 1 - 1 file changed, 1 deletion(-) commit 13c34fe518624e27589827aa49f68f5f38c95f11 Author: Lucas Stach Date: Mon Jun 13 18:28:42 2016 +0200 drm/etnaviv: initialize iommu domain page size Since d16e0faab91 (iommu: Allow selecting page sizes per domain) the iommu core demands the page size to be set per domain, otherwise any mapping attempts will be dropped. Make sure to set a valid page size for the etnaviv iommu. Signed-off-by: Lucas Stach drivers/gpu/drm/etnaviv/etnaviv_iommu.c | 1 + 1 file changed, 1 insertion(+) commit 3a5facd09da848193f5bcb0dea098a298bc1a29d Author: Will Deacon Date: Wed Jun 8 15:10:57 2016 +0100 arm64: spinlock: fix spin_unlock_wait for LSE atomics Commit d86b8da04dfa ("arm64: spinlock: serialise spin_unlock_wait against concurrent lockers") fixed spin_unlock_wait for LL/SC-based atomics under the premise that the LSE atomics (in particular, the LDADDA instruction) are indivisible. Unfortunately, these instructions are only indivisible when used with the -AL (full ordering) suffix and, consequently, the same issue can theoretically be observed with LSE atomics, where a later (in program order) load can be speculated before the write portion of the atomic operation. This patch fixes the issue by performing a CAS of the lock once we've established that it's unlocked, in much the same way as the LL/SC code. Fixes: d86b8da04dfa ("arm64: spinlock: serialise spin_unlock_wait against concurrent lockers") Signed-off-by: Will Deacon arch/arm64/include/asm/spinlock.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 38b850a73034f075c4088e7511b36ebbef9dce00 Author: Will Deacon Date: Thu Jun 2 15:27:04 2016 +0100 arm64: spinlock: order spin_{is_locked,unlock_wait} against local locks spin_is_locked has grown two very different use-cases: (1) [The sane case] API functions may require a certain lock to be held by the caller and can therefore use spin_is_locked as part of an assert statement in order to verify that the lock is indeed held. For example, usage of assert_spin_locked. (2) [The insane case] There are two locks, where a CPU takes one of the locks and then checks whether or not the other one is held before accessing some shared state. For example, the "optimized locking" in ipc/sem.c. In the latter case, the sequence looks like: spin_lock(&sem->lock); if (!spin_is_locked(&sma->sem_perm.lock)) /* Access shared state */ and requires that the spin_is_locked check is ordered after taking the sem->lock. Unfortunately, since our spinlocks are implemented using a LDAXR/STXR sequence, the read of &sma->sem_perm.lock can be speculated before the STXR and consequently return a stale value. Whilst this hasn't been seen to cause issues in practice, PowerPC fixed the same issue in 51d7d5205d33 ("powerpc: Add smp_mb() to arch_spin_is_locked()") and, although we did something similar for spin_unlock_wait in d86b8da04dfa ("arm64: spinlock: serialise spin_unlock_wait against concurrent lockers") that doesn't actually take care of ordering against local acquisition of a different lock. This patch adds an smp_mb() to the start of our arch_spin_is_locked and arch_spin_unlock_wait routines to ensure that the lock value is always loaded after any other locks have been taken by the current CPU. Reported-by: Peter Zijlstra Signed-off-by: Will Deacon arch/arm64/include/asm/spinlock.h | 7 +++++++ 1 file changed, 7 insertions(+) commit f7a6c1492a2cb596952260a7d5bb0d61ca815173 Author: Mark Salter Date: Tue Jun 7 11:32:21 2016 -0500 arm: pmu: Fix non-devicetree probing There is a problem in the non-devicetree PMU probing where some probe functions may get the number of supported events through smp_call_function_any() using the arm_pmu supported_cpus mask. But at the time the probe function is called, the supported_cpus mask is empty so the call fails. This patch makes sure the mask is set before calling the init function rather than after. Signed-off-by: Mark Salter Signed-off-by: Jeremy Linton Signed-off-by: Will Deacon drivers/perf/arm_pmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 62e6d1e59c77316768a663d1328390b4cd33801f Author: Roger Quadros Date: Wed Jun 15 11:12:05 2016 +0300 extcon: palmas: Fix boot up state of VBUS when using GPIO detection If USB cable is connected prior to boot, we don't get any interrupts so we must manually check the VBUS state and report it during probe. If we don't do it then USB controller will never know that peripheral cable was connected till the user unplugs and replugs the cable. Fixes: b7aad8e2685b ("extcon: palmas: Add the support for VBUS detection by using GPIO") Cc: stable@vger.kernel.org Signed-off-by: Roger Quadros Signed-off-by: Chanwoo Choi drivers/extcon/extcon-palmas.c | 2 ++ 1 file changed, 2 insertions(+) commit e43fc9467e96bbaf1b65bb975e6820e0db993469 Merge: fd2d2ba 6aa85f1 Author: Dave Airlie Date: Wed Jun 15 16:58:32 2016 +1000 Merge branch 'linux-4.7' of git://github.com/skeggsb/linux into drm-fixes * 'linux-4.7' of git://github.com/skeggsb/linux: drm/nouveau/iccsense: fix memory leak drm/nouveau/Revert "drm/nouveau/device/pci: set as non-CPU-coherent on ARM64" commit 6aa85f1129b32b5cd19ec262e7cfc2ddc08263c3 Author: Ben Skeggs Date: Thu May 26 17:04:52 2016 +1000 drm/nouveau/iccsense: fix memory leak Signed-off-by: Ben Skeggs drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 539aae6e3af97c7ec1602ff23e805f2852c2611c Author: Robin Murphy Date: Mon Jun 6 16:11:52 2016 +0900 drm/nouveau/Revert "drm/nouveau/device/pci: set as non-CPU-coherent on ARM64" This reverts commit 1733a2ad36741b1812cf8b3f3037c28d0af53f50. There is apparently something amiss with the way the TTM code handles DMA buffers, which the above commit was attempting to work around for arm64 systems with non-coherent PCI. Unfortunately, this completely breaks systems *with* coherent PCI (which appear to be the majority). Booting a plain arm64 defconfig + CONFIG_DRM + CONFIG_DRM_NOUVEAU on a machine with a PCI GPU having coherent dma_map_ops (in this case a 7600GT card plugged into an ARM Juno board) results in a fatal crash: [ 2.803438] nouveau 0000:06:00.0: DRM: allocated 1024x768 fb: 0x9000, bo ffffffc976141c00 [ 2.897662] Unable to handle kernel NULL pointer dereference at virtual address 000001ac [ 2.897666] pgd = ffffff8008e00000 [ 2.897675] [000001ac] *pgd=00000009ffffe003, *pud=00000009ffffe003, *pmd=0000000000000000 [ 2.897680] Internal error: Oops: 96000045 [#1] PREEMPT SMP [ 2.897685] Modules linked in: [ 2.897692] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.6.0-rc5+ #543 [ 2.897694] Hardware name: ARM Juno development board (r1) (DT) [ 2.897699] task: ffffffc9768a0000 ti: ffffffc9768a8000 task.ti: ffffffc9768a8000 [ 2.897711] PC is at __memcpy+0x7c/0x180 [ 2.897719] LR is at OUT_RINGp+0x34/0x70 [ 2.897724] pc : [] lr : [] pstate: 80000045 [ 2.897726] sp : ffffffc9768ab360 [ 2.897732] x29: ffffffc9768ab360 x28: 0000000000000001 [ 2.897738] x27: ffffffc97624c000 x26: 0000000000000000 [ 2.897744] x25: 0000000000000080 x24: 0000000000006c00 [ 2.897749] x23: 0000000000000005 x22: ffffffc97624c010 [ 2.897755] x21: 0000000000000004 x20: 0000000000000004 [ 2.897761] x19: ffffffc9763da000 x18: ffffffc976b2491c [ 2.897766] x17: 0000000000000007 x16: 0000000000000006 [ 2.897771] x15: 0000000000000001 x14: 0000000000000001 [ 2.897777] x13: 0000000000e31b70 x12: ffffffc9768a0080 [ 2.897783] x11: 0000000000000000 x10: fffffffffffffb00 [ 2.897788] x9 : 0000000000000000 x8 : 0000000000000000 [ 2.897793] x7 : 0000000000000000 x6 : 00000000000001ac [ 2.897799] x5 : 00000000ffffffff x4 : 0000000000000000 [ 2.897804] x3 : 0000000000000010 x2 : 0000000000000010 [ 2.897810] x1 : ffffffc97624c010 x0 : 00000000000001ac ... [ 2.898494] Call trace: [ 2.898499] Exception stack(0xffffffc9768ab1a0 to 0xffffffc9768ab2c0) [ 2.898506] b1a0: ffffffc9763da000 0000000000000004 ffffffc9768ab360 ffffff80083465fc [ 2.898513] b1c0: ffffffc976801e00 ffffffc9762b8000 ffffffc9768ab1f0 ffffff80080ec158 [ 2.898520] b1e0: ffffffc9768ab230 ffffff8008496d04 ffffffc975ce6d80 ffffffc9768ab36e [ 2.898527] b200: ffffffc9768ab36f ffffffc9768ab29d ffffffc9768ab29e ffffffc9768a0000 [ 2.898533] b220: ffffffc9768ab250 ffffff80080e70c0 ffffffc9768ab270 ffffff8008496e44 [ 2.898540] b240: 00000000000001ac ffffffc97624c010 0000000000000010 0000000000000010 [ 2.898546] b260: 0000000000000000 00000000ffffffff 00000000000001ac 0000000000000000 [ 2.898552] b280: 0000000000000000 0000000000000000 fffffffffffffb00 0000000000000000 [ 2.898558] b2a0: ffffffc9768a0080 0000000000e31b70 0000000000000001 0000000000000001 [ 2.898566] [] __memcpy+0x7c/0x180 [ 2.898574] [] nv04_fbcon_imageblit+0x1d4/0x2e8 [ 2.898582] [] nouveau_fbcon_imageblit+0xd8/0xe0 [ 2.898591] [] soft_cursor+0x154/0x1d8 [ 2.898598] [] bit_cursor+0x4fc/0x538 [ 2.898605] [] fbcon_cursor+0x134/0x1a8 [ 2.898613] [] hide_cursor+0x38/0xa0 [ 2.898620] [] redraw_screen+0x120/0x228 [ 2.898628] [] fbcon_prepare_logo+0x370/0x3f8 [ 2.898635] [] fbcon_init+0x350/0x560 [ 2.898641] [] visual_init+0xac/0x108 [ 2.898648] [] do_bind_con_driver+0x1c4/0x3a8 [ 2.898655] [] do_take_over_console+0x174/0x1e8 [ 2.898662] [] do_fbcon_takeover+0x74/0x100 [ 2.898669] [] fbcon_event_notify+0x8cc/0x920 [ 2.898680] [] notifier_call_chain+0x50/0x90 [ 2.898685] [] __blocking_notifier_call_chain+0x4c/0x90 [ 2.898691] [] blocking_notifier_call_chain+0x14/0x20 [ 2.898696] [] fb_notifier_call_chain+0x1c/0x28 [ 2.898703] [] register_framebuffer+0x1cc/0x2e0 [ 2.898712] [] drm_fb_helper_initial_config+0x288/0x3e8 [ 2.898719] [] nouveau_fbcon_init+0xe0/0x118 [ 2.898727] [] nouveau_drm_load+0x268/0x890 [ 2.898734] [] drm_dev_register+0xbc/0xc8 [ 2.898740] [] drm_get_pci_dev+0xa0/0x180 [ 2.898747] [] nouveau_drm_probe+0x1a0/0x1e0 [ 2.898755] [] pci_device_probe+0x98/0x110 [ 2.898763] [] driver_probe_device+0x204/0x2b0 [ 2.898770] [] __driver_attach+0xac/0xb0 [ 2.898777] [] bus_for_each_dev+0x60/0xa0 [ 2.898783] [] driver_attach+0x20/0x28 [ 2.898789] [] bus_add_driver+0x1d0/0x238 [ 2.898796] [] driver_register+0x60/0xf8 [ 2.898802] [] __pci_register_driver+0x3c/0x48 [ 2.898809] [] drm_pci_init+0xf4/0x120 [ 2.898818] [] nouveau_drm_init+0x21c/0x230 [ 2.898825] [] do_one_initcall+0x8c/0x190 [ 2.898832] [] kernel_init_freeable+0x14c/0x1f0 [ 2.898839] [] kernel_init+0x10/0x100 [ 2.898845] [] ret_from_fork+0x10/0x40 [ 2.898853] Code: a88120c7 a8c12027 a88120c7 a8c12027 (a88120c7) [ 2.898871] ---[ end trace d5713dcad023ee04 ]--- [ 2.898888] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b In a toss-up between the GPU seeing stale data artefacts on some systems vs. catastrophic kernel crashes on other systems, the latter would seem to take precedence, so revert this change until the real underlying problem can be fixed. Signed-off-by: Robin Murphy Acked-by: Alexandre Courbot [acourbot@nvidia.com: port to Nouveau tree, remove bits in lib/] Signed-off-by: Alexandre Courbot Signed-off-by: Ben Skeggs Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 871fd8403de10b9ba9c284105475ab52b96be248 Author: Rex Zhu Date: Sun Jun 12 11:18:01 2016 +0800 drm/amd/powerplay: select samu dpm 0 as boot level on polaris. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 3ff211270a986f19c7983378ee9c4db2497eaeaf Author: Rex Zhu Date: Wed Jun 8 19:04:35 2016 +0800 drm/amd/powerplay: update powerplay table parsing to handle pptable format change on Polaris boards Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr_ppt.h | 1 + .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 23 ++++-- .../gpu/drm/amd/powerplay/hwmgr/tonga_pptable.h | 16 ++++ .../amd/powerplay/hwmgr/tonga_processpptables.c | 91 +++++++++++++++------- 4 files changed, 97 insertions(+), 34 deletions(-) commit 61e0979a497b07f5a82f3050e37ecc7093e2971d Merge: d1e3728 4100948 Author: David S. Miller Date: Tue Jun 14 22:21:45 2016 -0700 Merge branch 'ovs-notifications' Nicolas Dichtel says: ==================== ovs: fix rtnl notifications on interface deletion There was no rtnl notifications for interfaces (gre, vxlan, geneve) created by ovs. This problem is fixed by adjusting the creation path. v1 -> v2: - add patch #1 and #4 - rework error handling in patch #2 ==================== Acked-by: Pravin B Shelar Signed-off-by: David S. Miller commit 41009481b690493c169ce85f591b9d32c6fd9422 Author: Nicolas Dichtel Date: Mon Jun 13 10:31:07 2016 +0200 ovs/geneve: fix rtnl notifications on iface deletion The function geneve_dev_create_fb() (only used by ovs) never calls rtnl_configure_link(). The consequence is that dev->rtnl_link_state is never set to RTNL_LINK_INITIALIZED. During the deletion phase, the function rollback_registered_many() sends a RTM_DELLINK only if dev->rtnl_link_state is set to RTNL_LINK_INITIALIZED. Fixes: e305ac6cf5a1 ("geneve: Add support to collect tunnel metadata.") CC: Pravin B Shelar CC: Jesse Gross CC: Thomas Graf Signed-off-by: Nicolas Dichtel Signed-off-by: David S. Miller drivers/net/geneve.c | 4 ++++ 1 file changed, 4 insertions(+) commit da6f1da819d4b9c081a477dec74dc468a0b44290 Author: Nicolas Dichtel Date: Mon Jun 13 10:31:06 2016 +0200 ovs/gre: fix rtnl notifications on iface deletion The function gretap_fb_dev_create() (only used by ovs) never calls rtnl_configure_link(). The consequence is that dev->rtnl_link_state is never set to RTNL_LINK_INITIALIZED. During the deletion phase, the function rollback_registered_many() sends a RTM_DELLINK only if dev->rtnl_link_state is set to RTNL_LINK_INITIALIZED. Fixes: b2acd1dc3949 ("openvswitch: Use regular GRE net_device instead of vport") CC: Thomas Graf CC: Pravin B Shelar Signed-off-by: Nicolas Dichtel Signed-off-by: David S. Miller net/ipv4/ip_gre.c | 4 ++++ 1 file changed, 4 insertions(+) commit cf5da330bbdd0c06b05c525a3d1d58ccd82c87a6 Author: Nicolas Dichtel Date: Mon Jun 13 10:31:05 2016 +0200 ovs/vxlan: fix rtnl notifications on iface deletion The function vxlan_dev_create() (only used by ovs) never calls rtnl_configure_link(). The consequence is that dev->rtnl_link_state is never set to RTNL_LINK_INITIALIZED. During the deletion phase, the function rollback_registered_many() sends a RTM_DELLINK only if dev->rtnl_link_state is set to RTNL_LINK_INITIALIZED. Note that the function vxlan_dev_create() is moved after the rtnl stuff so that vxlan_dellink() can be called in this function. Fixes: dcc38c033b32 ("openvswitch: Re-add CONFIG_OPENVSWITCH_VXLAN") CC: Thomas Graf CC: Pravin B Shelar Signed-off-by: Nicolas Dichtel Signed-off-by: David S. Miller drivers/net/vxlan.c | 58 +++++++++++++++++++++++++++++++---------------------- 1 file changed, 34 insertions(+), 24 deletions(-) commit 106da663ff495e0aea3ac15b8317aa410754fcac Author: Nicolas Dichtel Date: Mon Jun 13 10:31:04 2016 +0200 ovs/gre,geneve: fix error path when creating an iface After ipgre_newlink()/geneve_configure() call, the netdev is registered. Fixes: 7e059158d57b ("vxlan, gre, geneve: Set a large MTU on ovs-created tunnel devices") CC: David Wragg Signed-off-by: Nicolas Dichtel Signed-off-by: David S. Miller drivers/net/geneve.c | 10 +++++++--- net/ipv4/ip_gre.c | 10 +++++++--- 2 files changed, 14 insertions(+), 6 deletions(-) commit 8beb330044d0d1878c7b92290e91c0b889e92633 Author: James Bottomley Date: Mon Jun 13 22:00:07 2016 -0700 53c700: fix BUG on untagged commands The untagged command case in the 53c700 driver has been broken since host wide tags were enabled because the replaced scsi_find_tag() function had a special case for the tag value SCSI_NO_TAG to retrieve sdev->current_cmnd. The replacement function scsi_host_find_tag() has no such special case and returns NULL causing untagged commands to trigger a BUG() in the driver. Inspection shows that the 53c700 is the only driver using this SCSI_NO_TAG case, so a local fix in the driver suffices to fix this problem globally. Fixes: 64d513ac31b - "scsi: use host wide tags by default" Cc: stable@vger.kernel.org # 4.4+ Reported-by: Helge Deller Tested-by: Helge Deller Signed-off-by: James Bottomley Reviewed-by: Johannes Thumshirn Reviewed-by: Ewan D. Milne Acked-by: Christoph Hellwig Signed-off-by: Martin K. Petersen drivers/scsi/53c700.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fd2d2bac6e79b0be91ab86a6075a0c46ffda658a Author: Andrey Grodzovsky Date: Wed May 25 16:45:43 2016 -0400 drm/dp/mst: Always clear proposed vcpi table for port. Not clearing mst manager's proposed vcpis table for destroyed connectors when the manager is stopped leaves it pointing to unrefernced memory, this causes pagefault when the manager is restarted when plugging back a branch. Fixes: 91a25e463130 ("drm/dp/mst: deallocate payload on port destruction") Signed-off-by: Andrey Grodzovsky Reviewed-by: Lyude Cc: stable@vger.kernel.org Cc: Mykola Lysenko Cc: Alex Deucher drivers/gpu/drm/drm_dp_mst_topology.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 93f55972bc0fef0e394bbed3d46dc06b9afd3d17 Author: Philipp Zabel Date: Thu Jun 2 19:27:52 2016 +0200 drm/crtc: only store the necessary data for set_config rollback drm_crtc_helper_set_config only potentially touches connector->encoder and encoder->crtc, so we only have to store those for all connectors and encoders, respectively. Suggested-by: Daniel Vetter Signed-off-by: Philipp Zabel Reviewed-by: Daniel Vetter Signed-off-by: Dave Airlie drivers/gpu/drm/drm_crtc_helper.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) commit fffc5f59f2c68ca859c3f92b224393ed3adbe1ca Author: Philipp Zabel Date: Thu Jun 2 19:27:51 2016 +0200 drm/crtc: fix connector reference counting mismatch in drm_crtc_helper_set_config Since commit 0955c1250e96 ("drm/crtc: take references to connectors used in a modeset. (v2)"), the reference counts of all connectors in the drm_mode_set given to drm_crtc_helper_set_config are incremented, and then the reference counts of all connectors are decremented on success, but in a temporary copy of the connector structure. This leads to the following error after the first modeset on imx-drm: Unable to handle kernel NULL pointer dereference at virtual address 00000004 pgd = ad8c4000 [00000004] *pgd=3d9c5831, *pte=00000000, *ppte=00000000 Internal error: Oops: 817 [#1] PREEMPT SMP ARM Modules linked in: CPU: 1 PID: 190 Comm: kmsfb-manage Not tainted 4.7.0-rc1+ #657 Hardware name: Freescale i.MX6 Quad/DualLit: [<80506098>] lr : [<80252e94>] psr: 200c0013 sp : adca7ca8 ip : adca7b90 fp : adca7cd4 r10: 00000000 r9 : 00000100 r8 : 00000200 r7 : af3c9800 r6 : aded7848 r5 : aded7800 r4 : 00000000 r3 : af3ca058 r2 : 00000200 r1 : af3ca058 r0 : 00000000 Flags: nzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none Control: 10c5387d Table: 3d8c404a DAC: 00000051 Process kmsfb-manage (pid: 190, stack limit = 0xadca6210) Stack: (0xadca7ca8 to 0xadca8000) 7ca0: 805190e0 aded7800 aded7820 80501a88 8155a290 af3c9c6c 7cc0: adca7ddc 0000000f adca7cec adca7cd8 80519104 80506044 805190e0 aded7800 7ce0: adca7d04 adca7cf0 80501ac0 805190ec aded7820 aded7814 adca7d24 adca7d08 7d00: 804fdb80 80501a94 aded7800 af3ca010 aded7afc af3c9c60 adca7d94 adca7d28 7d20: 804e3518 804fdb20 00000000 af3c9b1c adca7d50 81506f44 00000000 8093c500 7d40: af3c9c6c ae4f2ca8 ae4f2c18 00000000 00000000 ae637f00 00000000 aded7800 7d60: 00000001 af3c9800 af23c300 ae77fcc0 ae4f2c18 00000001 af3c9800 8155a290 7d80: af1af700 adca6000 adca7db4 adca7d98 804fea6c 804e2de4 adca7e50 adb3d940 7da0: 00000001 af3c9800 adca7e24 adca7db8 8050440c 804fea0c ae77fcc0 00000003 7dc0: adca7e24 adb3d940 af1af700 ae77fcc0 ae77fccc ae4f2c18 8083d44c ae77fcc0 7de0: ae4002 80d03040 adca7e64 adca7e40 adca7e50 80503f08 7e40: 7ebd5630 adca7e50 00000068 c06864a2 7ebd5be8 00000000 00000001 00000018 7e60: 00000026 00000000 00000000 00000000 00000001 000115bc 05010500 05a0059f 7e80: 03200000 03360321 00000337 0000003c 00000000 00000040 30383231 30303878 7ea0: 00000000 00000000 00000000 00000000 00000000 00000000 80173058 80172e30 7ec0: 80d77d32 00004000 adf7d900 00000003 00000000 7ebd5630 af342bb0 adfe3b80 7ee0: 80272f50 00000003 adca6000 00000000 adca7f7c adca7f00 802725ec 804f52cc 7f00: 802809cc 80178450 00000000 00000000 80280880 80145904 adb3d8c0 adf7d990 7f20: ffffffff 00000003 00004000 01614c10 c06864a2 00000003 adca6000 00000000 7f40: adca7f6c adca7f50 80280b04 8028088c 000115bc adfe3b81 7ebd5630 adfe3b80 7f60: c06864a2 00000003 adca6000 00000000 adca7fa4 adca7f80 80272f50 80272548 7f80: 000115bc 00017050 00000001 01614c10 00000036 801089e4 00000000 adca7fa8 7fa0: 80108840 80272f18 00017050 00000001 00000003 c06864a2 7ebd5630 000115bc 7fc0: 00017050 00000001 01614c10 00000036 00000003 00000000 00000026 00000018 7fe0: 00016f38 7ebd562c 0000b5e9 76ef31e6 400c0030 00000003 ff5f37db bfe7dd4d Backtrace: [<80506038>] (drm_connector_cleanup) from [<80519104>] (dw_hdmi_connector_destroy+0x24/0x28) r10:0000000f r9:adca7ddc r8:af3c9c6c r7:8155a290 r6:80501a88 r5:aded7820 r4:aded7800 r3:805190e0 [<805190e0>] (dw_hdmi_connector_destroy) from [<80501ac0>] (drm_connector_free+0x38/0x3c) r4:aded7800 nreference) from [<804e3518>] (drm_crtc_helper_set_config+0x740/0xbf4) r6:af3c9c60 r5:aded7afc r4:af3ca010 r3:aded7800 [<804e2dd8>] (drm_crtc_helper_set_config) from [<804fea6c>] (drm_mode_set_config_internal+0x6c/0xf4) r10:adca6000 r9:af1af700 r8:8155a290 r7:af3c9800 r6:00000001 r5:ae4f2c18 r4:ae77fcc0 [<804fea00>] (drm_mode_set_config_internal) from [<8050440c>] (drm_mode_setcrtc+0x504/0x57c) r7:af3c9800 r6:00000001 r5:adb3d940 r4:adca7e50 [<80503f08>] (drm_mode_setcrtc) from [<804f5404>] (drm_ioctl+0x144/0x4dc) r10:ada2e000 r9:000000a2 r8:af3c9800 r7:8155a290 r6:809320b4 r5:00000051 r4:adca7e50 [<804f52c0>] (drm_ioctl) from [<802725ec>] (do_vfs_ioctl+0xb0/0x9d0) r10:00000000 r9:adca6000 r8:00000003 r7:80272f50 r6:adfe3b80 r5:af342bb0 r4:7ebd5630 [<8027253c>] (do_vfs_ioctl) from [<80272f50>] (SyS_ioctl+0x44/0x6c) r10:00000000 r9:adca6000 r8:00000003 r7:c06864a2 r6:adfe3b80 r5:7ebd5630 r4:adfe3b81 [<80272f0c>] (SyS_ioctl) from [<80108840>] (ret_fast_syscall+0x0/0x1c) r8:801089e4 r7:00000036 r6:01614c10 r5:00000001 r4:00017050 r3:000115bc Code: 0a00000c e5932004 e1a01003 e1a0a004 (e5842004) ---[ end trace 9a7257572ccacb16 ]--- Only the reference count of connectors that weren't previously bound to an encoder should be incremented after a call to drm_crtc_helper_set_config. And only the reference count of connectors that were previously bound to an encoder and are unbound afterwards should ever be decremented. The reference counts of the temporary copies in the save_connectors should not be touched at all. This patch fixes the above error by only incrementing the reference count of those connectors in the set that are initially not bound to any encoder, and also by restoring the reference count of only those connectors in the set in the failure case. "Note that this can only be hit when fbdev emulation is disabled, since then the refcount drops from 1 to 0 and we call the connector destroy functions on the backup copy, which eventually results in tears. With fbdev emulation the refcount only goes down from 2 to 1 ever. And since we unconditionally increment the refcount on the real object, the refcount of that will slowly increase. The backup connector's refcount doesn't matter, since we kfree() that either way in the end of drm_crtc_helper_set_config()." Fixes: 0955c1250e96 ("drm/crtc: take references to connectors used in a modeset. (v2)") Signed-off-by: Philipp Zabel Reviewed-by: Daniel Vetter Signed-off-by: Dave Airlie drivers/gpu/drm/drm_crtc_helper.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 902daaacc0e8b4cea979f837873e1f63254f201d Merge: 27bf60d 476490a Author: Dave Airlie Date: Wed Jun 15 10:30:23 2016 +1000 Merge tag 'drm-intel-fixes-2016-06-14' of git://anongit.freedesktop.org/drm-intel into drm-fixes "Pretty much all regression fixes, or black screens." * tag 'drm-intel-fixes-2016-06-14' of git://anongit.freedesktop.org/drm-intel: drm/i915/ilk: Don't disable SSC source if it's in use drm/i915: Extract physical display dimensions from VBT drm/i915: Check VBT for port presence in addition to the strap on VLV/CHV drm/i915: Only ignore eDP ports that are connected drm/i915: Silence "unexpected child device config size" for VBT on 845g drm/i915: Fix NULL pointer deference when out of PLLs in IVB commit da4e792550a856e2f66aa8183d408553f7513a86 Author: Rafael J. Wysocki Date: Wed Jun 15 02:16:13 2016 +0200 Revert "ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write()" Revert commit 66b1ed5aa8dd "ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write()" that is reported to break suspend-to-RAM (ACPI S3) on one system. The root cause of the failure is a wrong access width value for one of the involved registers provided by the ACPI tables, but before commit 66b1ed5aa8dd that value was not taken into account at all and things worked. Fixes: 66b1ed5aa8dd "ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write()" Reported-by: Andrey Skvortsov Signed-off-by: Rafael J. Wysocki drivers/acpi/acpica/hwregs.c | 146 +++---------------------------------------- 1 file changed, 9 insertions(+), 137 deletions(-) commit b00345d1994d588fa2687e1238fcd542f0320cba Author: Srinivas Pandruvada Date: Tue Jun 14 23:12:59 2016 -0700 cpufreq: intel_pstate: Adjust _PSS[0] freqeuency if needed The maximum turbo P-State used by the intel_pstate driver may be limited by ACPI _PSS table entry 0. After commit 9522a2ff9cde (cpufreq: intel_pstate: Enforce _PPC limits), the maximum performance on servers will be capped by the _PSS table entry 0 by default. Even though that is formally correct, it may lead to preformance regressions in some cases. Namely, if the _PSS table entry 0 is not the maximum turbo P-State, performance measured after commit 9522a2ff9cde will not match the performance measured before that commit on the same system. For this reason, modify the code to always use the maximum turbo frequency as the one that corresponds to _PSS table entry 0 if turbo is enabled in the BIOS. This way, the performance levels from before commit 9522a2ff9cde will be restored on the affected systems. Fixes: 9522a2ff9cde (cpufreq: intel_pstate: Enforce _PPC limits) Suggested-by: Rafael J. Wysocki Signed-off-by: Srinivas Pandruvada [ rjw : Changelog ] Signed-off-by: Rafael J. Wysocki drivers/cpufreq/intel_pstate.c | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) commit 7c64cc0531fa0d9720f9e15a0a0d97bcad1d1cd1 Author: Paul E. McKenney Date: Tue Apr 26 10:42:25 2016 -0700 arm: Use _rcuidle for smp_cross_call() tracepoints Further testing with false negatives suppressed by commit 293e2421fe25 ("rcu: Remove superfluous versions of rcu_read_lock_sched_held()") identified another unprotected use of RCU from the idle loop. Because RCU actively ignores idle-loop code (for energy-efficiency reasons, among other things), using RCU from the idle loop can result in too-short grace periods, in turn resulting in arbitrary misbehavior. The resulting lockdep-RCU splat is as follows: ------------------------------------------------------------------------ =============================== [ INFO: suspicious RCU usage. ] 4.6.0-rc5-next-20160426+ #1112 Not tainted ------------------------------- include/trace/events/ipi.h:35 suspicious rcu_dereference_check() usage! other info that might help us debug this: RCU used illegally from idle CPU! rcu_scheduler_active = 1, debug_locks = 0 RCU used illegally from extended quiescent state! no locks held by swapper/0/0. stack backtrace: CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.6.0-rc5-next-20160426+ #1112 Hardware name: Generic OMAP4 (Flattened Device Tree) [] (unwind_backtrace) from [] (show_stack+0x10/0x14) [] (show_stack) from [] (dump_stack+0xb0/0xe4) [] (dump_stack) from [] (smp_cross_call+0xbc/0x188) [] (smp_cross_call) from [] (generic_exec_single+0x9c/0x15c) [] (generic_exec_single) from [] (smp_call_function_single_async+0 x38/0x9c) [] (smp_call_function_single_async) from [] (cpuidle_coupled_poke_others+0x8c/0xa8) [] (cpuidle_coupled_poke_others) from [] (cpuidle_enter_state_coupled+0x26c/0x390) [] (cpuidle_enter_state_coupled) from [] (cpu_startup_entry+0x198/0x3a0) [] (cpu_startup_entry) from [] (start_kernel+0x354/0x3c8) [] (start_kernel) from [<8000807c>] (0x8000807c) ------------------------------------------------------------------------ Reported-by: Tony Lindgren Signed-off-by: Paul E. McKenney Tested-by: Tony Lindgren Tested-by: Guenter Roeck Cc: Russell King Cc: Steven Rostedt Cc: Cc: arch/arm/kernel/smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d1e37288c9146dccff830e3253e403af8705b51f Author: Su, Xuemin Date: Mon Jun 13 11:02:50 2016 +0800 udp reuseport: fix packet of same flow hashed to different socket There is a corner case in which udp packets belonging to a same flow are hashed to different socket when hslot->count changes from 10 to 11: 1) When hslot->count <= 10, __udp_lib_lookup() searches udp_table->hash, and always passes 'daddr' to udp_ehashfn(). 2) When hslot->count > 10, __udp_lib_lookup() searches udp_table->hash2, but may pass 'INADDR_ANY' to udp_ehashfn() if the sockets are bound to INADDR_ANY instead of some specific addr. That means when hslot->count changes from 10 to 11, the hash calculated by udp_ehashfn() is also changed, and the udp packets belonging to a same flow will be hashed to different socket. This is easily reproduced: 1) Create 10 udp sockets and bind all of them to 0.0.0.0:40000. 2) From the same host send udp packets to 127.0.0.1:40000, record the socket index which receives the packets. 3) Create 1 more udp socket and bind it to 0.0.0.0:44096. The number 44096 is 40000 + UDP_HASH_SIZE(4096), this makes the new socket put into the same hslot as the aformentioned 10 sockets, and makes the hslot->count change from 10 to 11. 4) From the same host send udp packets to 127.0.0.1:40000, and the socket index which receives the packets will be different from the one received in step 2. This should not happen as the socket bound to 0.0.0.0:44096 should not change the behavior of the sockets bound to 0.0.0.0:40000. It's the same case for IPv6, and this patch also fixes that. Signed-off-by: Su, Xuemin Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller net/ipv4/udp.c | 73 +++++++++++++--------------------------------------------- net/ipv6/udp.c | 71 +++++++++++++------------------------------------------- 2 files changed, 32 insertions(+), 112 deletions(-) commit 476490a945e1f0f6bd58e303058d2d8ca93a974c Author: Lyude Date: Tue Jun 14 11:04:09 2016 -0400 drm/i915/ilk: Don't disable SSC source if it's in use Thanks to Ville Syrjälä for pointing me towards the cause of this issue. Unfortunately one of the sideaffects of having the refclk for a DPLL set to SSC is that as long as it's set to SSC, the GPU will prevent us from powering down any of the pipes or transcoders using it. A couple of BIOSes enable SSC in both PCH_DREF_CONTROL and in the DPLL configurations. This causes issues on the first modeset, since we don't expect SSC to be left on and as a result, can't successfully power down the pipes or the transcoders using it. Here's an example from this Dell OptiPlex 990: [drm:intel_modeset_init] SSC enabled by BIOS, overriding VBT which says disabled [drm:intel_modeset_init] 2 display pipes available. [drm:intel_update_cdclk] Current CD clock rate: 400000 kHz [drm:intel_update_max_cdclk] Max CD clock rate: 400000 kHz [drm:intel_update_max_cdclk] Max dotclock rate: 360000 kHz vgaarb: device changed decodes: PCI:0000:00:02.0,olddecodes=io+mem,decodes=io+mem:owns=io+mem [drm:intel_crt_reset] crt adpa set to 0xf40000 [drm:intel_dp_init_connector] Adding DP connector on port C [drm:intel_dp_aux_init] registering DPDDC-C bus for card0-DP-1 [drm:ironlake_init_pch_refclk] has_panel 0 has_lvds 0 has_ck505 0 [drm:ironlake_init_pch_refclk] Disabling SSC entirely … later we try committing the first modeset … [drm:intel_dump_pipe_config] [CRTC:26][modeset] config ffff88041b02e800 for pipe A [drm:intel_dump_pipe_config] cpu_transcoder: A … [drm:intel_dump_pipe_config] dpll_hw_state: dpll: 0xc4016001, dpll_md: 0x0, fp0: 0x20e08, fp1: 0x30d07 [drm:intel_dump_pipe_config] planes on this crtc [drm:intel_dump_pipe_config] STANDARD PLANE:23 plane: 0.0 idx: 0 enabled [drm:intel_dump_pipe_config] FB:42, fb = 800x600 format = 0x34325258 [drm:intel_dump_pipe_config] scaler:0 src (0, 0) 800x600 dst (0, 0) 800x600 [drm:intel_dump_pipe_config] CURSOR PLANE:25 plane: 0.1 idx: 1 disabled, scaler_id = 0 [drm:intel_dump_pipe_config] STANDARD PLANE:27 plane: 0.1 idx: 2 disabled, scaler_id = 0 [drm:intel_get_shared_dpll] CRTC:26 allocated PCH DPLL A [drm:intel_get_shared_dpll] using PCH DPLL A for pipe A [drm:ilk_audio_codec_disable] Disable audio codec on port C, pipe A [drm:intel_disable_pipe] disabling pipe A ------------[ cut here ]------------ WARNING: CPU: 1 PID: 130 at drivers/gpu/drm/i915/intel_display.c:1146 intel_disable_pipe+0x297/0x2d0 [i915] pipe_off wait timed out … ---[ end trace 94fc8aa03ae139e8 ]--- [drm:intel_dp_link_down] [drm:ironlake_crtc_disable [i915]] *ERROR* failed to disable transcoder A Later modesets succeed since they reset the DPLL's configuration anyway, but this is enough to get stuck with a big fat warning in dmesg. A better solution would be to add refcounts for the SSC source, but for now leaving the source clock on should suffice. Changes since v4: - Fix calculation of final for systems with LVDS panels (fixes BUG() on CI test suite) Changes since v3: - Move temp variable into loop - Move checks for using_ssc_source to after we've figured out has_ck505 - Add using_ssc_source to debug output Changes since v2: - Fix debug output for when we disable the CPU source Changes since v1: - Leave the SSC source clock on instead of just shutting it off on all of the DPLL configurations. Cc: stable@vger.kernel.org Reviewed-by: Ville Syrjälä Signed-off-by: Lyude Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/1465916649-10228-1-git-send-email-cpaul@redhat.com Signed-off-by: Daniel Vetter drivers/gpu/drm/i915/intel_display.c | 48 +++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 14 deletions(-) commit 6c0d54f1897d229748d4f41ef919078db6db2123 Author: Eric Dumazet Date: Sun Jun 12 20:01:25 2016 -0700 net_sched: fix pfifo_head_drop behavior vs backlog When the qdisc is full, we drop a packet at the head of the queue, queue the current skb and return NET_XMIT_CN Now we track backlog on upper qdiscs, we need to call qdisc_tree_reduce_backlog(), even if the qlen did not change. Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Signed-off-by: Eric Dumazet Cc: WANG Cong Cc: Jamal Hadi Salim Acked-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_fifo.c | 4 ++++ 1 file changed, 4 insertions(+) commit 1c4bf5ac6a16d9321b51e91acef481b090e5486b Author: Hans de Goede Date: Tue Jun 14 15:13:06 2016 -0500 usb: musb: sunxi: Remove bogus "Frees glue" comment The comment is wrong, glue is devm_kzalloc-ed mem attached to the "allwinner,sun4i-a10-musb" compatible platform-dev. Where as glue->musb_pdev is a newly created "musb-hdrc" platform-dev. Signed-off-by: Hans de Goede [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu Signed-off-by: Greg Kroah-Hartman drivers/usb/musb/sunxi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 969a132723434f3723cc0606373785d19c1d2f05 Author: Hans de Goede Date: Tue Jun 14 15:13:05 2016 -0500 usb: musb: sunxi: Fix NULL ptr deref when gadget is registered before musb Stop using the return value of platform_device_register_full() to get to the struct musb in sunxi_musb_work(). If a gadget has been registered (insmod-ed) before the musb driver, then musb_start will get called from the musb_core probe function and sunxi_musb_work() may run before platform_device_register_full() has returned. Instead store a pointer to struct musb in struct sunxi_glue when sunxi_musb_enable gets called. Note that sunxi_musb_enable always gets called before sunxi_musb_work() can run. Signed-off-by: Hans de Goede [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu Signed-off-by: Greg Kroah-Hartman drivers/usb/musb/sunxi.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 881d0327db37ad917a367c77aff1afa1ee41e0a9 Author: Feng Tang Date: Sun Jun 12 17:36:37 2016 +0800 net: alx: Work around the DMA RX overflow issue Commit 26c5f03 uses a new skb allocator to avoid the RFD overflow issue. But from debugging without datasheet, we found the error always happen when the DMA RX address is set to 0x....fc0, which is very likely to be a HW/silicon problem. So one idea is instead of adding a new allocator, why not just hitting the right target by avaiding the error-prone DMA address? This patch will actually * Remove the commit 26c5f03 * Apply rx skb with 64 bytes longer space, and if the allocated skb has a 0x...fc0 address, it will use skb_resever(skb, 64) to advance the address, so that the RX overflow can be avoided. In theory this method should also apply to atl1c driver, which I can't find anyone who can help to test on real devices. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=70761 Signed-off-by: Feng Tang Suggested-by: Eric Dumazet Tested-by: Ole Lukoie Acked-by: Eric Dumazet Signed-off-by: David S. Miller drivers/net/ethernet/atheros/alx/alx.h | 4 --- drivers/net/ethernet/atheros/alx/main.c | 61 ++++++++------------------------- 2 files changed, 14 insertions(+), 51 deletions(-) commit b46d9f625b07f843c706c2c7d0210a90ccdf143b Author: Hannes Frederic Sowa Date: Sun Jun 12 12:02:46 2016 +0200 ipv4: fix checksum annotation in udp4_csum_init Reported-by: Cong Wang Cc: Cong Wang Cc: Tom Herbert Fixes: 4068579e1e098fa ("net: Implmement RFC 6936 (zero RX csums for UDP/IPv6") Signed-off-by: Hannes Frederic Sowa Signed-off-by: David S. Miller net/ipv4/udp.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit c148d16369ff0095eca950d17968ba1d56a47b53 Author: Hannes Frederic Sowa Date: Sat Jun 11 21:15:37 2016 +0200 ipv6: fix checksum annotation in udp6_csum_init Cc: Tom Herbert Fixes: 4068579e1e098fa ("net: Implmement RFC 6936 (zero RX csums for UDP/IPv6") Signed-off-by: Hannes Frederic Sowa Signed-off-by: David S. Miller net/ipv6/ip6_checksum.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 5119bd16815d3f0364390a1369392dcc036790e7 Author: Hannes Frederic Sowa Date: Sat Jun 11 20:41:38 2016 +0200 ipv6: tcp: fix endianness annotation in tcp_v6_send_response Cc: Florent Fourcot Fixes: 1d13a96c74fc ("ipv6: tcp: fix flowlabel value in ACK messages send from TIME_WAIT") Signed-off-by: Hannes Frederic Sowa Signed-off-by: David S. Miller net/ipv6/tcp_ipv6.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit dcb94b88c09ce82a80e188d49bcffdc83ba215a6 Author: Hannes Frederic Sowa Date: Sat Jun 11 20:32:06 2016 +0200 ipv6: fix endianness error in icmpv6_err IPv6 ping socket error handler doesn't correctly convert the new 32 bit mtu to host endianness before using. Cc: Lorenzo Colitti Fixes: 6d0bfe22611602f ("net: ipv6: Add IPv6 support to the ping socket.") Signed-off-by: Hannes Frederic Sowa Acked-by: Lorenzo Colitti Signed-off-by: David S. Miller net/ipv6/icmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fdecf36fcefa9f48c2f2de21c8176f1a8ce2c960 Author: Clemens Gruber Date: Sat Jun 11 17:21:26 2016 +0200 phy: marvell: fix LED configuration via marvell,reg-init Configuring the PHY LED registers for the Marvell 88E1510 and others is not possible, because regardless of the values in marvell,reg-init, it is later overridden in m88e1121_config_aneg with a non-standard default. This patch moves that default configuration to .config_init to allow setting the LED configuration through marvell,reg-init in the device tree, which should override said default if it exists. Signed-off-by: Clemens Gruber Reviewed-by: Andrew Lunn Signed-off-by: David S. Miller drivers/net/phy/marvell.c | 38 ++++++++++++++++++++++++++------------ 1 file changed, 26 insertions(+), 12 deletions(-) commit 5bc28b93a36e3cb3acc2870fb75cb6ffb182fece Author: Rhyland Klein Date: Thu Jun 9 17:28:39 2016 -0400 power_supply: power_supply_read_temp only if use_cnt > 0 Change power_supply_read_temp() to use power_supply_get_property() so that it will check the use_cnt and ensure it is > 0. The use_cnt will be incremented at the end of __power_supply_register, so this will block to case where get_property can be called before the supply is fully registered. This fixes the issue show in the stack below: [ 1.452598] power_supply_read_temp+0x78/0x80 [ 1.458680] thermal_zone_get_temp+0x5c/0x11c [ 1.464765] thermal_zone_device_update+0x34/0xb4 [ 1.471195] thermal_zone_device_register+0x87c/0x8cc [ 1.477974] __power_supply_register+0x364/0x424 [ 1.484317] power_supply_register_no_ws+0x10/0x18 [ 1.490833] bq27xxx_battery_setup+0x10c/0x164 [ 1.497003] bq27xxx_battery_i2c_probe+0xd0/0x1b0 [ 1.503435] i2c_device_probe+0x174/0x240 [ 1.509172] driver_probe_device+0x1fc/0x29c [ 1.515167] __driver_attach+0xa4/0xa8 [ 1.520643] bus_for_each_dev+0x58/0x98 [ 1.526204] driver_attach+0x20/0x28 [ 1.531505] bus_add_driver+0x1c8/0x22c [ 1.537067] driver_register+0x68/0x108 [ 1.542630] i2c_register_driver+0x38/0x7c [ 1.548457] bq27xxx_battery_i2c_driver_init+0x18/0x20 [ 1.555321] do_one_initcall+0x38/0x12c [ 1.560886] kernel_init_freeable+0x148/0x1ec [ 1.566972] kernel_init+0x10/0xfc [ 1.572101] ret_from_fork+0x10/0x40 Also make the same change to ps_get_max_charge_cntl_limit() and ps_get_cur_chrage_cntl_limit() to be safe. Lastly, change the return value of power_supply_get_property() to -EAGAIN from -ENODEV if use_cnt <= 0. Fixes: 297d716f6260 ("power_supply: Change ownership from driver to core") Cc: stable@vger.kernel.org Signed-off-by: Rhyland Klein Reviewed-by: Krzysztof Kozlowski Signed-off-by: Sebastian Reichel drivers/power/power_supply_core.c | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) commit b914bb55f2abd66937c23fa0b89becaf9bcceb37 Author: Vinod Koul Date: Tue Jun 14 21:33:44 2016 +0530 ASoC: Intel: Skylake: Initialize module list for Broxton The module list was not initialized for Broxton DSP code, so initialize it. Signed-off-by: Vinod Koul Signed-off-by: Mark Brown sound/soc/intel/skylake/bxt-sst.c | 1 + 1 file changed, 1 insertion(+) commit eee930163c6a2507aa3b41edf8f7e3b7a2049769 Author: Geert Uytterhoeven Date: Fri Mar 25 11:47:11 2016 +0100 nfsd: Fix NFSD_MDS_PR_KEY on 32-bit by adding ULL postfix On 32-bit: fs/nfsd/blocklayout.c: In function ‘nfsd4_block_get_device_info_scsi’: fs/nfsd/blocklayout.c:337: warning: integer constant is too large for ‘long’ type fs/nfsd/blocklayout.c:344: warning: integer constant is too large for ‘long’ type fs/nfsd/blocklayout.c: In function ‘nfsd4_scsi_fence_client’: fs/nfsd/blocklayout.c:385: warning: integer constant is too large for ‘long’ type Add the missing "ULL" postfix to 64-bit constant NFSD_MDS_PR_KEY to fix this. Fixes: f99d4fbdae6765d0 ("nfsd: add SCSI layout support") Signed-off-by: Geert Uytterhoeven Reviewed-by: Christoph Hellwig Signed-off-by: J. Bruce Fields fs/nfsd/blocklayout.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bba42c7877d3efce86ca331ad1a7e37046627c72 Merge: 182fd9e 280a3ef Author: Kalle Valo Date: Tue Jun 14 17:07:38 2016 +0300 Merge tag 'iwlwifi-for-kalle-2016-06-10' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes * fix the scan timeout for long scans * fix an RCU splat caused when updating the TKIP key * fix a potential NULL-derefence introduced recently * fix a IGTK key bug that has existed since the MVM driver was introduced * fix some fw capabilities checks that got accidentally inverted commit bbb1681ee3653bdcfc6a4ba31902738118311fd4 Author: Mark Rutland Date: Mon Jun 13 17:57:02 2016 +0100 arm64: mm: mark fault_info table const Unlike the debug_fault_info table, we never intentionally alter the fault_info table at runtime, and all derived pointers are treated as const currently. Make the table const so that it can be placed in .rodata and protected from unintentional writes, as we do for the syscall tables. Signed-off-by: Mark Rutland Cc: Catalin Marinas Cc: Will Deacon Signed-off-by: Will Deacon arch/arm64/mm/fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c5cea06be060f38e5400d796e61cfc8c36e52924 Author: Mark Rutland Date: Mon Jun 13 11:15:14 2016 +0100 arm64: fix dump_instr when PAN and UAO are in use If the kernel is set to show unhandled signals, and a user task does not handle a SIGILL as a result of an instruction abort, we will attempt to log the offending instruction with dump_instr before killing the task. We use dump_instr to log the encoding of the offending userspace instruction. However, dump_instr is also used to dump instructions from kernel space, and internally always switches to KERNEL_DS before dumping the instruction with get_user. When both PAN and UAO are in use, reading a user instruction via get_user while in KERNEL_DS will result in a permission fault, which leads to an Oops. As we have regs corresponding to the context of the original instruction abort, we can inspect this and only flip to KERNEL_DS if the original abort was taken from the kernel, avoiding this issue. At the same time, remove the redundant (and incorrect) comments regarding the order dump_mem and dump_instr are called in. Cc: Catalin Marinas Cc: James Morse Cc: Robin Murphy Cc: #4.6+ Signed-off-by: Mark Rutland Reported-by: Vladimir Murzin Tested-by: Vladimir Murzin Fixes: 57f4959bad0a154a ("arm64: kernel: Add support for User Access Override") Signed-off-by: Will Deacon arch/arm64/kernel/traps.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit e024111f6946f45cf1559a8c6fd48d2d0f696d07 Author: Miaoqing Pan Date: Tue Jun 7 15:47:07 2016 +0300 ath9k: fix GPIO mask for AR9462 and AR9565 The incorrect GPIO mask cause kernel warning, when AR9462 access GPIO11. Also fix the mask for AR9565. WARNING: CPU: 1 PID: 199 at ../drivers/net/wireless/ath/ath9k/hw.c:2778 ath9k_hw_gpio_get+0x1a9/0x1b0 [ath9k_hw] CPU: 1 PID: 199 Comm: kworker/u16:9 Not tainted 4.7.0-rc1-next-20160530+ #5 Hardware name: Acer TravelMate P243/BA40_HC, BIOS V1.01 04/20/2012 Workqueue: events_power_efficient rfkill_poll 0000000000000000 ffff88002cf73d28 ffffffff813b8ddc 0000000000000000 0000000000000000 ffff88002cf73d68 ffffffff8107a331 00000ada00000086 ffff880148d9c018 000000000000000b ffff880147e68720 0000000000000200 Call Trace: [] dump_stack+0x63/0x87 [] __warn+0xd1/0xf0 [] warn_slowpath_null+0x1d/0x20 [] ath9k_hw_gpio_get+0x1a9/0x1b0 [ath9k_hw] [] ath9k_rfkill_poll_state+0x34/0x60 [ath9k] [] ieee80211_rfkill_poll+0x33/0x40 [mac80211] [] cfg80211_rfkill_poll+0x2a/0xc0 [cfg80211] [] rfkill_poll+0x24/0x50 [] process_one_work+0x153/0x3f0 [] worker_thread+0x12b/0x4b0 [] ? rescuer_thread+0x340/0x340 [] kthread+0xc9/0xe0 [] ret_from_fork+0x1f/0x40 [] ? kthread_park+0x60/0x60 Fixes: a01ab81b09c5 ("ath9k: define correct GPIO numbers and bits mask") Reported-by: Sudip Mukherjee Tested-by: Sudip Mukherjee Signed-off-by: Miaoqing Pan Signed-off-by: Kalle Valo drivers/net/wireless/ath/ath9k/reg.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e50525bef593c3dd0564df676c567d77f7c20322 Author: Rajkumar Manoharan Date: Thu Jun 9 11:33:55 2016 +0530 ath10k: fix deadlock while processing rx_in_ord_ind commit 5c86d97bcc1d ("ath10k: combine txrx and replenish task") introduced deadlock while processing rx in order indication message for qca6174 based devices. While merging replenish and txrx tasklets, replenish task should be called out of htt rx ring locking since it is also try to acquire the same lock. Unfortunately this issue is not exposed by other solutions (qca988x, qca99x0 & qca4019), as rx_in_ord_ind message is specific to qca6174 based devices. This patch fixes ============================================= [ INFO: possible recursive locking detected ] 4.7.0-rc2-wt-ath+ #1353 Tainted: G E --------------------------------------------- swapper/3/0 is trying to acquire lock: (&(&htt->rx_ring.lock)->rlock){+.-...}, at: [] ath10k_htt_rx_msdu_buff_replenish+0x29/0x90 [ath10k_core] but task is already holding lock: (&(&htt->rx_ring.lock)->rlock){+.-...}, at: [] ath10k_htt_txrx_compl_task+0x21b/0x250 [ath10k_core] other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&(&htt->rx_ring.lock)->rlock); lock(&(&htt->rx_ring.lock)->rlock); *** DEADLOCK *** May be due to missing lock nesting notation 1 lock held by swapper/3/0: #0: (&(&htt->rx_ring.lock)->rlock){+.-...}, at: [] ath10k_htt_txrx_compl_task+0x21b/0x250 [ath10k_core] Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=119151 Fixes: 5c86d97bcc1d ("ath10k: combine txrx and replenish task") Reported-by: Mike Lothian Signed-off-by: Rajkumar Manoharan Signed-off-by: Kalle Valo drivers/net/wireless/ath/ath10k/htt_rx.c | 1 - 1 file changed, 1 deletion(-) commit 57675cb976eff977aefb428e68e4e0236d48a9ff Author: Andrey Ryabinin Date: Thu Jun 9 15:20:05 2016 +0300 kernel/sysrq, watchdog, sched/core: Reset watchdog on all CPUs while processing sysrq-w Lengthy output of sysrq-w may take a lot of time on slow serial console. Currently we reset NMI-watchdog on the current CPU to avoid spurious lockup messages. Sometimes this doesn't work since softlockup watchdog might trigger on another CPU which is waiting for an IPI to proceed. We reset softlockup watchdogs on all CPUs, but we do this only after listing all tasks, and this may be too late on a busy system. So, reset watchdogs CPUs earlier, in for_each_process_thread() loop. Signed-off-by: Andrey Ryabinin Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Link: http://lkml.kernel.org/r/1465474805-14641-1-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Ingo Molnar kernel/sched/core.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit eda8dca519269c92a0771668b3d5678792de7b78 Author: Josh Poimboeuf Date: Mon Jun 13 02:32:09 2016 -0500 sched/debug: Fix deadlock when enabling sched events I see a hang when enabling sched events: echo 1 > /sys/kernel/debug/tracing/events/sched/enable The printk buffer shows: BUG: spinlock recursion on CPU#1, swapper/1/0 lock: 0xffff88007d5d8c00, .magic: dead4ead, .owner: swapper/1/0, .owner_cpu: 1 CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.7.0-rc2+ #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.8.1-20150318_183358- 04/01/2014 ... Call Trace: [] dump_stack+0x85/0xc2 [] spin_dump+0x78/0xc0 [] do_raw_spin_lock+0x11a/0x150 [] _raw_spin_lock+0x61/0x80 [] ? try_to_wake_up+0x256/0x4e0 [] try_to_wake_up+0x256/0x4e0 [] ? _raw_spin_unlock_irqrestore+0x4a/0x80 [] wake_up_process+0x15/0x20 [] insert_work+0x84/0xc0 [] __queue_work+0x18f/0x660 [] queue_work_on+0x46/0x90 [] drm_fb_helper_dirty.isra.11+0xcb/0xe0 [drm_kms_helper] [] drm_fb_helper_sys_imageblit+0x30/0x40 [drm_kms_helper] [] soft_cursor+0x1ad/0x230 [] bit_cursor+0x649/0x680 [] ? update_attr.isra.2+0x90/0x90 [] fbcon_cursor+0x14a/0x1c0 [] hide_cursor+0x28/0x90 [] vt_console_print+0x3bf/0x3f0 [] call_console_drivers.constprop.24+0x183/0x200 [] console_unlock+0x3d4/0x610 [] vprintk_emit+0x3c5/0x610 [] vprintk_default+0x29/0x40 [] printk+0x57/0x73 [] enqueue_entity+0xc2e/0xc70 [] enqueue_task_fair+0x59/0xab0 [] ? kvm_sched_clock_read+0x9/0x20 [] ? sched_clock+0x9/0x10 [] activate_task+0x5c/0xa0 [] ttwu_do_activate+0x54/0xb0 [] sched_ttwu_pending+0x7a/0xb0 [] scheduler_ipi+0x61/0x170 [] smp_trace_reschedule_interrupt+0x4f/0x2a0 [] trace_reschedule_interrupt+0x96/0xa0 [] ? native_safe_halt+0x6/0x10 [] ? trace_hardirqs_on+0xd/0x10 [] default_idle+0x20/0x1a0 [] arch_cpu_idle+0xf/0x20 [] default_idle_call+0x2f/0x50 [] cpu_startup_entry+0x37e/0x450 [] start_secondary+0x160/0x1a0 Note the hang only occurs when echoing the above from a physical serial console, not from an ssh session. The bug is caused by a deadlock where the task is trying to grab the rq lock twice because printk()'s aren't safe in sched code. Signed-off-by: Josh Poimboeuf Cc: Linus Torvalds Cc: Matt Fleming Cc: Mel Gorman Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Srikar Dronamraju Cc: Thomas Gleixner Cc: stable@vger.kernel.org Fixes: cb2517653fcc ("sched/debug: Make schedstats a runtime tunable that is disabled by default") Link: http://lkml.kernel.org/r/20160613073209.gdvdybiruljbkn3p@treble Signed-off-by: Ingo Molnar kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8d950d2fb23b696d393020486ab6a350bcb2c582 Author: Jon Mason Date: Thu Jun 9 13:24:19 2016 -0400 MAINTAINERS: Update the Calgary IOMMU entry Update the contact info for Muli, clean-up my name, and update the mailing list to the IOMMU mailing list. Signed-off-by: Jon Mason Cc: Andrew Morton Cc: Bartlomiej Zolnierkiewicz Cc: Greg Kroah-Hartman Cc: Krzysztof Kozlowski Cc: Linus Torvalds Cc: Muli Ben-Yehuda Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/1465493059-11840-2-git-send-email-jdmason@kudzu.us Signed-off-by: Ingo Molnar MAINTAINERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit dcfc47248d3f7d28df6f531e6426b933de94370d Author: Masami Hiramatsu Date: Sat Jun 11 23:06:53 2016 +0900 kprobes/x86: Clear TF bit in fault on single-stepping Fix kprobe_fault_handler() to clear the TF (trap flag) bit of the flags register in the case of a fault fixup on single-stepping. If we put a kprobe on the instruction which caused a page fault (e.g. actual mov instructions in copy_user_*), that fault happens on the single-stepping buffer. In this case, kprobes resets running instance so that the CPU can retry execution on the original ip address. However, current code forgets to reset the TF bit. Since this fault happens with TF bit set for enabling single-stepping, when it retries, it causes a debug exception and kprobes can not handle it because it already reset itself. On the most of x86-64 platform, it can be easily reproduced by using kprobe tracer. E.g. # cd /sys/kernel/debug/tracing # echo p copy_user_enhanced_fast_string+5 > kprobe_events # echo 1 > events/kprobes/enable And you'll see a kernel panic on do_debug(), since the debug trap is not handled by kprobes. To fix this problem, we just need to clear the TF bit when resetting running kprobe. Signed-off-by: Masami Hiramatsu Reviewed-by: Ananth N Mavinakayanahalli Acked-by: Steven Rostedt Cc: Alexander Shishkin Cc: Andy Lutomirski Cc: Arnaldo Carvalho de Melo Cc: Borislav Petkov Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Jiri Olsa Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Stephane Eranian Cc: Thomas Gleixner Cc: Vince Weaver Cc: systemtap@sourceware.org Cc: stable@vger.kernel.org # All the way back to ancient kernels Link: http://lkml.kernel.org/r/20160611140648.25885.37482.stgit@devbox [ Updated the comments. ] Signed-off-by: Ingo Molnar arch/x86/kernel/kprobes/core.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 4b2312bd0592708c85ed94368c874819e7013309 Author: Harvey Hunt Date: Mon May 23 12:05:52 2016 +0100 irqchip/mips-gic: Fix IRQs in gic_dev_domain When allocating a new device IRQ, gic_dev_domain_alloc() correctly calls irq_domain_set_hwirq_and_chip(), but gic_irq_domain_alloc() does not. This means that gic_irq_domain believes all IRQs from the dev domain have an hwirq of 0 and creates incorrect mappings in the linear_revmap. As gic_irq_domain is a parent of the gic_dev_domain, this leads to an inability to boot on devices with a GIC. Excerpt of the error: [ 2.297649] irq 0: nobody cared (try booting with the "irqpoll" option) ... [ 2.436963] handlers: [ 2.439492] Disabling IRQ #0 Fix this by calling irq_domain_set_hwirq_and_chip() for both the dev and irq domain. Now that we are modifying the parent domain, be sure to clear it up in case of an allocation error. Fixes: c98c1822ee13 ("irqchip/mips-gic: Add device hierarchy domain") Fixes: 2af70a962070 ("irqchip/mips-gic: Add a IPI hierarchy domain") Signed-off-by: Harvey Hunt Tested-by: Govindraj Raja # On Pistachio SoC Reviewed-by: Matt Redfearn Cc: linux-mips@linux-mips.org Cc: Qais Yousef Cc: jason@lakedaemon.net Cc: marc.zyngier@arm.com Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/1464001552-31174-1-git-send-email-harvey.hunt@imgtec.com Signed-off-by: Thomas Gleixner drivers/irqchip/irq-mips-gic.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 719bd6542044efd9b338a53dba1bef45f40ca169 Author: Michal Suchanek Date: Mon Jun 13 17:46:49 2016 +0000 spi: sunxi: fix transfer timeout The trasfer timeout is fixed at 1000 ms. Reading a 4Mbyte flash over 1MHz SPI bus takes way longer than that. Calculate the timeout from the actual time the transfer is supposed to take and multiply by 2 for good measure. Signed-off-by: Michal Suchanek Acked-by: Maxime Ripard Signed-off-by: Mark Brown Cc: stable@vger.kernel.org drivers/spi/spi-sun4i.c | 10 +++++++++- drivers/spi/spi-sun6i.c | 10 +++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) commit 6d9fe44bd73d567d04d3a68a2d2fa521ab9532f2 Author: Michal Suchanek Date: Mon Jun 13 17:46:49 2016 +0000 spi: sun4i: fix FIFO limit When testing SPI without DMA I noticed that filling the FIFO on the spi controller causes timeout. Always leave room for one byte in the FIFO. Signed-off-by: Michal Suchanek Acked-by: Maxime Ripard Signed-off-by: Mark Brown Cc: stable@vger.kernel.org drivers/spi/spi-sun4i.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 0699fdb380a847dcd4b74bbca6078bdb20033366 Merge: c1b8bfb 6df82a7 Author: Paolo Bonzini Date: Tue Jun 14 11:00:16 2016 +0200 Merge branch 'kvm-mips-fixes' into HEAD Merge MIPS patches destined to both 4.7 and kvm/next, to avoid unnecessary conflicts. Signed-off-by: Paolo Bonzini commit 6df82a7b88dc9b0b519765562b005ef9196d812a Author: James Hogan Date: Thu Jun 9 10:50:46 2016 +0100 MIPS: KVM: Fix CACHE triggered exception emulation When emulating TLB miss / invalid exceptions during CACHE instruction emulation, be sure to set up the correct PC and host_cp0_badvaddr state for the kvm_mips_emlulate_tlb*_ld() function to pick up for guest EPC and BadVAddr. PC needs to be rewound otherwise the guest EPC will end up pointing at the next instruction after the faulting CACHE instruction. host_cp0_badvaddr must be set because guest CACHE instructions trap with a Coprocessor Unusable exception, which doesn't update the host BadVAddr as a TLB exception would. This doesn't tend to get hit when dynamic translation of emulated instructions is enabled, since only the first execution of each CACHE instruction actually goes through this code path, with subsequent executions hitting the SYNCI instruction that it gets replaced with. Signed-off-by: James Hogan Cc: Paolo Bonzini Cc: Radim Krčmář Cc: Ralf Baechle Cc: kvm@vger.kernel.org Cc: linux-mips@linux-mips.org Signed-off-by: Paolo Bonzini arch/mips/kvm/emulate.c | 3 +++ 1 file changed, 3 insertions(+) commit cc81e9486202345d6ca56495cf8b5f3d03fbc563 Author: James Hogan Date: Thu Jun 9 10:50:45 2016 +0100 MIPS: KVM: Don't unwind PC when emulating CACHE When a CACHE instruction is emulated by kvm_mips_emulate_cache(), the PC is first updated to point to the next instruction, and afterwards it falls through the "dont_update_pc" label, which rewinds the PC back to its original address. This works when dynamic translation of emulated instructions is enabled, since the CACHE instruction is replaced with a SYNCI which works without trapping, however when dynamic translation is disabled the guest hangs on CACHE instructions as they always trap and are never stepped over. Roughly swap the meanings of the "done" and "dont_update_pc" to match kvm_mips_emulate_CP0(), so that "done" will roll back the PC on failure, and "dont_update_pc" won't change PC at all (for the sake of exceptions that have already modified the PC). Signed-off-by: James Hogan Cc: Paolo Bonzini Cc: Radim Krčmář Cc: Ralf Baechle Cc: kvm@vger.kernel.org Cc: linux-mips@linux-mips.org Signed-off-by: Paolo Bonzini arch/mips/kvm/emulate.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit 7f5a1ddc792901249c2060e165bcb3ca779cde35 Author: James Hogan Date: Thu Jun 9 10:50:44 2016 +0100 MIPS: KVM: Include bit 31 in segment matches When faulting guest addresses are matched against guest segments with the KVM_GUEST_KSEGX() macro, change the mask to 0xe0000000 so as to include bit 31. This is mainly for safety's sake, as it prevents a rogue BadVAddr in the host kseg2/kseg3 segments (e.g. 0xC*******) after a TLB exception from matching the guest kseg0 segment (e.g. 0x4*******), triggering an internal KVM error instead of allowing the corresponding guest kseg0 page to be mapped into the host vmalloc space. Such a rogue BadVAddr was observed to happen with the host MIPS kernel running under QEMU with KVM built as a module, due to a not entirely transparent optimisation in the QEMU TLB handling. This has already been worked around properly in a previous commit. Signed-off-by: James Hogan Cc: Paolo Bonzini Cc: Radim Krčmář Cc: Ralf Baechle Cc: kvm@vger.kernel.org Cc: linux-mips@linux-mips.org Signed-off-by: Paolo Bonzini arch/mips/include/asm/kvm_host.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 797179bc4fe06c89e47a9f36f886f68640b423f8 Author: James Hogan Date: Thu Jun 9 10:50:43 2016 +0100 MIPS: KVM: Fix modular KVM under QEMU Copy __kvm_mips_vcpu_run() into unmapped memory, so that we can never get a TLB refill exception in it when KVM is built as a module. This was observed to happen with the host MIPS kernel running under QEMU, due to a not entirely transparent optimisation in the QEMU TLB handling where TLB entries replaced with TLBWR are copied to a separate part of the TLB array. Code in those pages continue to be executable, but those mappings persist only until the next ASID switch, even if they are marked global. An ASID switch happens in __kvm_mips_vcpu_run() at exception level after switching to the guest exception base. Subsequent TLB mapped kernel instructions just prior to switching to the guest trigger a TLB refill exception, which enters the guest exception handlers without updating EPC. This appears as a guest triggered TLB refill on a host kernel mapped (host KSeg2) address, which is not handled correctly as user (guest) mode accesses to kernel (host) segments always generate address error exceptions. Signed-off-by: James Hogan Cc: Paolo Bonzini Cc: Radim Krčmář Cc: Ralf Baechle Cc: kvm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: # 3.10.x- Signed-off-by: Paolo Bonzini arch/mips/include/asm/kvm_host.h | 1 + arch/mips/kvm/interrupt.h | 1 + arch/mips/kvm/locore.S | 1 + arch/mips/kvm/mips.c | 11 ++++++++++- 4 files changed, 13 insertions(+), 1 deletion(-) commit b7fa30c9cc48c4f55663420472505d3b4f6e1705 Author: Peter Zijlstra Date: Thu Jun 9 15:07:50 2016 +0200 sched/fair: Fix post_init_entity_util_avg() serialization Chris Wilson reported a divide by 0 at: post_init_entity_util_avg(): > 725 if (cfs_rq->avg.util_avg != 0) { > 726 sa->util_avg = cfs_rq->avg.util_avg * se->load.weight; > -> 727 sa->util_avg /= (cfs_rq->avg.load_avg + 1); > 728 > 729 if (sa->util_avg > cap) > 730 sa->util_avg = cap; > 731 } else { Which given the lack of serialization, and the code generated from update_cfs_rq_load_avg() is entirely possible: if (atomic_long_read(&cfs_rq->removed_load_avg)) { s64 r = atomic_long_xchg(&cfs_rq->removed_load_avg, 0); sa->load_avg = max_t(long, sa->load_avg - r, 0); sa->load_sum = max_t(s64, sa->load_sum - r * LOAD_AVG_MAX, 0); removed_load = 1; } turns into: ffffffff81087064: 49 8b 85 98 00 00 00 mov 0x98(%r13),%rax ffffffff8108706b: 48 85 c0 test %rax,%rax ffffffff8108706e: 74 40 je ffffffff810870b0 ffffffff81087070: 4c 89 f8 mov %r15,%rax ffffffff81087073: 49 87 85 98 00 00 00 xchg %rax,0x98(%r13) ffffffff8108707a: 49 29 45 70 sub %rax,0x70(%r13) ffffffff8108707e: 4c 89 f9 mov %r15,%rcx ffffffff81087081: bb 01 00 00 00 mov $0x1,%ebx ffffffff81087086: 49 83 7d 70 00 cmpq $0x0,0x70(%r13) ffffffff8108708b: 49 0f 49 4d 70 cmovns 0x70(%r13),%rcx Which you'll note ends up with 'sa->load_avg - r' in memory at ffffffff8108707a. By calling post_init_entity_util_avg() under rq->lock we're sure to be fully serialized against PELT updates and cannot observe intermediate state like this. Reported-by: Chris Wilson Signed-off-by: Peter Zijlstra (Intel) Cc: Andrey Ryabinin Cc: Linus Torvalds Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Yuyang Du Cc: bsegall@google.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: steve.muckle@linaro.org Fixes: 2b8c41daba32 ("sched/fair: Initiate a new task's util avg to a bounded value") Link: http://lkml.kernel.org/r/20160609130750.GQ30909@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar kernel/sched/core.c | 3 +-- kernel/sched/fair.c | 8 +++++++- 2 files changed, 8 insertions(+), 3 deletions(-) commit cc51846ba81ca179a3be20f6313e3b72531888c1 Author: Boris Brezillon Date: Tue May 17 11:12:32 2016 +0200 pwm: atmel-hlcdc: Fix default PWM polarity The PWM device exposed by the HLCDC IP is configured with an inverted polarity by default. Registering the PWM chip with the normal polarity was not a problem before commit 42e8992c58d4 ("pwm: Add core infrastructure to allow atomic updates") because the ->set_polarity() hook was called no matter the current polarity state, but this is no longer the case. Signed-off-by: Boris Brezillon Signed-off-by: Thierry Reding drivers/pwm/pwm-atmel-hlcdc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 61edc3f3b51d2d3948029197cfff6fef7d94e939 Author: Richard Weinberger Date: Mon Jun 13 00:49:04 2016 +0200 ubi: Don't bypass ->getattr() Directly accessing inode fields bypasses ->getattr() and can cause problems when the underlying filesystem does not have the default ->getattr() implementation. So instead of obtaining the backing inode via d_backing_inode() use vfs_getattr() and obtain what we need from the kstat struct. Cc: Al Viro Reported-by: Al Viro Signed-off-by: Richard Weinberger drivers/mtd/ubi/build.c | 16 ++++++++++------ drivers/mtd/ubi/kapi.c | 17 ++++++++++------- 2 files changed, 20 insertions(+), 13 deletions(-) commit 1a498ec45eeabcb246c3c3f5822ed9ac1b4f70d8 Author: Richard Weinberger Date: Mon Jun 13 00:49:03 2016 +0200 Revert "mtd: switch open_mtd_by_chdev() to use of vfs_stat()" This reverts commit 87f15d4add758fb7fc76655721af94be57a4c17d. vfs_stat() can only be used on user supplied buffers. Cc: Al Viro Signed-off-by: Richard Weinberger drivers/mtd/ubi/build.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit ad022c87187b50f50937bd9bcd1ef312442a89af Author: Richard Weinberger Date: Sun Jun 12 23:37:53 2016 +0200 Revert "mtd: switch ubi_open_volume_path() to vfs_stat()" This reverts commit 322ea0bbf3003df17b6253f76e572c37d79a6810. vfs_stat() can only be used on user supplied buffers. UBI's kapi.c is the API to the kernel and therefore vfs_stat() is inappropriate. This solves the problem that mounting any UBIFS will immediately fail with -EINVAL. Cc: Al Viro Signed-off-by: Richard Weinberger drivers/mtd/ubi/kapi.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit ea1d39a31d3b1b6060b6e83e5a29c069a124c68a Author: Oscar Date: Tue Jun 14 14:14:35 2016 +0800 usb: common: otg-fsm: add license to usb-otg-fsm Fix warning about tainted kernel because usb-otg-fsm has no license. WARNING: with this patch usb-otg-fsm module can be loaded but then the kernel will hang. Tested with a udoo quad board. Cc: #v4.1+ Signed-off-by: Oscar Signed-off-by: Peter Chen drivers/usb/common/usb-otg-fsm.c | 2 ++ 1 file changed, 2 insertions(+) commit db06d759d6cf903aeda8c107fd3abd366dd80200 Merge: 35398ee 6710e59 Author: Linus Torvalds Date: Mon Jun 13 19:54:46 2016 -1000 Merge branch 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu Pull percpu fixes from Tejun Heo: "While adding GFP_ATOMIC support to the percpu allocator, the synchronization for the fast-path which doesn't require external allocations was separated into pcpu_lock. Unfortunately, it incorrectly decoupled async paths and percpu chunks could get destroyed while still being operated on. This contains two patches to fix the bug" * 'for-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu: percpu: fix synchronization between synchronous map extension and chunk destruction percpu: fix synchronization between chunk->map_extend_work and chunk destruction commit 35398ee3f00a4363faa1bd0fe7bb6a90f8a6b7e4 Merge: 5edb564 0d2a8ef4 Author: Linus Torvalds Date: Mon Jun 13 19:52:31 2016 -1000 Merge tag 'regulator-fix-v4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fixes from Mark Brown: "Some driver specific fixes for the regulator subsystem: - Some of the changes to the core that were merged in the last merge window exposed the fact that the qcom-smd driver hadn't implemented the voltage enumeration interfaces like it should. Since it's a simple driver specific fix to implement them do that. - Fix the ramp delay configuration for tps51632" * tag 'regulator-fix-v4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: qcom_smd: add list_voltage callback regulator: qcom_smd: add regulator ops for pm8941 lnldo regulator: qcom_smd: add list_voltage callback regulator: tps51632: Fix setting ramp delay commit 8550e2fa34f077c8a87cf1ba2453102bbbc9ade9 Author: Aneesh Kumar K.V Date: Wed Jun 8 19:55:55 2016 +0530 powerpc/mm/hash: Use the correct PPP mask when updating HPTE With commit e58e87adc8bf9 "powerpc/mm: Update _PAGE_KERNEL_RO" we now use all the three PPP bits. The top bit is now used to have a PPP value of 0b110 which will be mapped to kernel read only. When updating the hpte entry use right mask such that we update the 63rd bit (top 'P' bit) too. Prior to e58e87adc8bf we didn't support KERNEL_RO at all (it was == KERNEL_RW), so this isn't a regression as such. Fixes: e58e87adc8bf ("powerpc/mm: Update _PAGE_KERNEL_RO") Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/include/asm/book3s/64/mmu-hash.h | 1 + arch/powerpc/mm/hash_native_64.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) commit 4d2ec8575357d4afc965564e2e910a72fe608d39 Author: Johannes Thumshirn Date: Tue May 10 12:39:45 2016 +0200 mcb: Acquire reference to carrier module in core Acquire a reference to the carrier's kernel module in bus code, so it can't be removed from the kernel while it still has a bus and thus possibly devices attached to it. Signed-off-by: Johannes Thumshirn Reported-by: Andreas Werner Tested-by: Andreas Werner Signed-off-by: Greg Kroah-Hartman drivers/mcb/mcb-core.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) commit 7bc364097a89a0a9a5e5e4989d6b3e6fb2027a9e Author: Johannes Thumshirn Date: Tue May 10 12:39:44 2016 +0200 mcb: Acquire reference to device in probe mcb_probe() does not aqcuire a reference to the probed device but drops one when removing the device. As it is actually using the device, it should grab a reference via get_device(). This could lead to a panic found with a rmmod/modprobe stress test Signed-off-by: Johannes Thumshirn Reported-by: Andreas Werner Tested-by: Andreas Werner Signed-off-by: Greg Kroah-Hartman drivers/mcb/mcb-core.c | 1 + 1 file changed, 1 insertion(+) commit 7c4021d403ca72ce52d39c17d8154974521a82be Author: Alex Deucher Date: Mon Jun 13 18:59:17 2016 -0400 Revert "drm/amdgpu: add pipeline sync while vmid switch in same ctx" This reverts commit 2ba272d7bde27e1db2cf1c6cee49b01b7ea08989. The issue fixed by this patch is specific to compute rings and the previous patch was enough. Additionally, this patch as been traced to strange behavior on some CZ systems so we might as well drop it. drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 +--- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 9 ++------- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 6 +++--- 3 files changed, 6 insertions(+), 13 deletions(-) commit a0110642e6efc49cc214a67b9749a791b0ca045d Merge: b046302 a7d7865 Author: Olof Johansson Date: Mon Jun 13 15:53:29 2016 -0700 Merge tag 'samsung-fixes-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into fixes Fixes for Exynos-based Snow and Peach Pit boards for regressions introduced in 4.7-rc1 because OF graph logic expects specific names of child nodes. * tag 'samsung-fixes-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: exynos: Fix port nodes names for Exynos5420 Peach Pit board ARM: dts: exynos: Fix port nodes names for Exynos5250 Snow board Signed-off-by: Olof Johansson commit b046302a1dbbc49102da50000a22f4c69b1d700e Author: Fabio Estevam Date: Mon Jun 6 10:51:40 2016 -0300 MAINTAINERS: Add myself as reviewer of ARM FSL/NXP I would like to help reviewing FSL/NXP ARM architecture patches. Signed-off-by: Fabio Estevam Acked-by: Shawn Guo Signed-off-by: Olof Johansson MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit ecb0693d3e26470a49fbeb1b1f7fe197bb234725 Merge: b223d62 c106c21 Author: Olof Johansson Date: Mon Jun 13 15:48:51 2016 -0700 Merge tag 'socfpga_fix_for_v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux into fixes SoCFPGA fix for v4.7 - Add missing PHY phandle for SoCFPGA VINING board * tag 'socfpga_fix_for_v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux: ARM: dts: socfpga: Add missing PHY phandle Signed-off-by: Olof Johansson commit 8b18300c13a1e08e152f6b6a430faac84f986231 Author: Alex Deucher Date: Mon Jun 13 18:26:24 2016 -0400 drm/amdgpu/gfx7: fix broken condition check Wrong operator. Reported-by: David Binderman Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 05082b8bbd1a0ffc74235449c4b8930a8c240f85 Author: Alex Deucher Date: Mon Jun 13 15:37:34 2016 -0400 drm/radeon: fix asic initialization for virtualized environments When executing in a PCI passthrough based virtuzliation environment, the hypervisor will usually attempt to send a PCIe bus reset signal to the ASIC when the VM reboots. In this scenario, the card is not correctly initialized, but we still consider it to be posted. Therefore, in a passthrough based environemnt we should always post the card to guarantee it is in a good state for driver initialization. Ported from amdgpu commit: amdgpu: fix asic initialization for virtualized environments Cc: Andres Rodriguez Cc: Alex Williamson Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org drivers/gpu/drm/radeon/radeon_device.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit 048765ad5af7c8939603b4c6cb96293ffa05e00d Author: Andres Rodriguez Date: Sat Jun 11 02:51:32 2016 -0400 amdgpu: fix asic initialization for virtualized environments (v2) When executing in a PCI passthrough based virtuzliation environemnt, the hypervisor will usually attempt to send a PCIe bus reset signal to the ASIC when the VM reboots. In this scenario, the card is not correctly initialized, but we still consider it to be posted. Therefore, in a passthrough based environemnt we should always post the card to guarantee it is in a good state for driver initialization. However, if we are operating in SR-IOV mode it is up to the GIM driver to manage the asic state, therefore we should not post the card (and shouldn't be able to do it either). v2: add missing semi-colon Reviewed-by: Christian König Signed-off-by: Andres Rodriguez Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu.h | 7 +++++++ drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 17 ++++++++++++++++- drivers/gpu/drm/amd/amdgpu/cik.c | 7 +++++++ drivers/gpu/drm/amd/amdgpu/vi.c | 15 +++++++++++++++ 4 files changed, 45 insertions(+), 1 deletion(-) commit 9ef8537e68941d858924a3eacee5a1945767cbab Author: Christian König Date: Mon Jun 13 16:09:53 2016 +0200 drm/radeon: don't use fractional dividers on RS[78]80 if SS is enabled Seems to cause problems for some older hardware. Kudos to Thom Kouwenhoven for working a lot with the PLLs and figuring this out. Reviewed-by: Alex Deucher Signed-off-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/radeon/atombios_crtc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit ccaa2c12fba72f3e547d18e66820e2e6c5883113 Author: Jérôme Glisse Date: Tue Jun 7 17:43:04 2016 -0400 drm/radeon: do not hard reset GPU while freezing on r600/r700 family Seems r600/r700 does not like hard reset while freezing for hibernation (regression due to 274ad65c9d02bdcbee9bae045517864c3521d530 which itself is a fix for hibernation on some GPU families). Until i can debug further issue with r600, let just disable this for r600/r700 as they are very similar family and bug affecting one likely affect the other. Reviewed-by: Christian König Signed-off-by: Jérôme Glisse Signed-off-by: Alex Deucher drivers/gpu/drm/radeon/radeon_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0d2a8ef4395e84aa9623ac1e282417c75a73490c Merge: 5edb564 3bfbb4d c714a58 Author: Mark Brown Date: Mon Jun 13 16:51:57 2016 +0100 Merge remote-tracking branches 'regulator/fix/qcom-smd' and 'regulator/fix/tps51632' into regulator-linus commit 19edeb30c55079c9bba4573d700bbcafed03303c Author: Charles Keepax Date: Mon Jun 13 13:35:16 2016 +0100 ASoC: wm5102: Correct supported channels on trace compressed DAI The audio trace firmware on wm5102 only supports 4 channels correct the DAI driver structure to reflect this. Signed-off-by: Charles Keepax Signed-off-by: Mark Brown sound/soc/codecs/wm5102.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d72fea6214f3fee2355d8cb6c51348059d98768b Author: Ajit Pandey Date: Mon Jun 13 13:35:15 2016 +0100 ASoC: wm5110: Add missing route from OUT3R to SYSCLK Output 3 is stereo on wm5110 and all inputs/outputs should have a connection to SYSCLK. This patch adds the missing DAPM route. Signed-off-by: Ajit Pandey Signed-off-by: Charles Keepax Signed-off-by: Mark Brown sound/soc/codecs/wm5110.c | 1 + 1 file changed, 1 insertion(+) commit 1c343f7b0e177e8ca7f4d4a5dd1fa790f85abbcc Author: Christian Borntraeger Date: Mon Jun 13 13:14:56 2016 +0200 KVM: s390/mm: Fix CMMA reset during reboot commit 1e133ab296f ("s390/mm: split arch/s390/mm/pgtable.c") factored out the page table handling code from __gmap_zap and __s390_reset_cmma into ptep_zap_unused and added a simple flag that tells which one of the function (reset or not) is to be made. This also changed the behaviour, as it also zaps unused page table entries on reset. Turns out that this is wrong as s390_reset_cmma uses the page walker, which DOES NOT take the ptl lock. The most simple fix is to not do the zapping part on reset (which uses the walker) Signed-off-by: Christian Borntraeger Fixes: 1e133ab296f ("s390/mm: split arch/s390/mm/pgtable.c") Cc: stable@vger.kernel.org # 4.6+ Signed-off-by: Martin Schwidefsky arch/s390/mm/pgtable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ae4ea9a2460c7fee2ae8feeb4dfe96f5f6c3e562 Author: Junichi Nomura Date: Fri Jun 10 04:31:52 2016 +0000 ipmi: Remove smi_msg from waiting_rcv_msgs list before handle_one_recv_msg() Commit 7ea0ed2b5be8 ("ipmi: Make the message handler easier to use for SMI interfaces") changed handle_new_recv_msgs() to call handle_one_recv_msg() for a smi_msg while the smi_msg is still connected to waiting_rcv_msgs list. That could lead to following list corruption problems: 1) low-level function treats smi_msg as not connected to list handle_one_recv_msg() could end up calling smi_send(), which assumes the msg is not connected to list. For example, the following sequence could corrupt list by doing list_add_tail() for the entry still connected to other list. handle_new_recv_msgs() msg = list_entry(waiting_rcv_msgs) handle_one_recv_msg(msg) handle_ipmb_get_msg_cmd(msg) smi_send(msg) spin_lock(xmit_msgs_lock) list_add_tail(msg) spin_unlock(xmit_msgs_lock) 2) race between multiple handle_new_recv_msgs() instances handle_new_recv_msgs() once releases waiting_rcv_msgs_lock before calling handle_one_recv_msg() then retakes the lock and list_del() it. If others call handle_new_recv_msgs() during the window shown below list_del() will be done twice for the same smi_msg. handle_new_recv_msgs() spin_lock(waiting_rcv_msgs_lock) msg = list_entry(waiting_rcv_msgs) spin_unlock(waiting_rcv_msgs_lock) | | handle_one_recv_msg(msg) | spin_lock(waiting_rcv_msgs_lock) list_del(msg) spin_unlock(waiting_rcv_msgs_lock) Fixes: 7ea0ed2b5be8 ("ipmi: Make the message handler easier to use for SMI interfaces") Signed-off-by: Jun'ichi Nomura [Added a comment to describe why this works.] Signed-off-by: Corey Minyard Cc: stable@vger.kernel.org # 3.19 Tested-by: Ye Feng drivers/char/ipmi/ipmi_msghandler.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 053ae6499a5634c0dc5fa18437e1af3d2f2ec98e Author: Axel Lin Date: Mon Jun 13 13:48:53 2016 +0800 gpio: 104-idi-48: Fix missing spin_lock_init for ack_lock Fixes: 9ae482104cb9 ("gpio: 104-idi-48: Clear pending interrupt once in IRQ handler") Signed-off-by: Axel Lin Acked-by: William Breathitt Gray Signed-off-by: Linus Walleij drivers/gpio/gpio-104-idi-48.c | 1 + 1 file changed, 1 insertion(+) commit c1b8bfb08f25d1cb9ef2bc93229107113a41ad8c Merge: af8c34c 9ec6de1 Author: Paolo Bonzini Date: Mon Jun 13 13:44:50 2016 +0200 Merge tag 'kvm-s390-master-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD KVM: s390: fixup and missing stat 1. A fixup for a bug that was introduced in 4.7-rc1 if userspace uses the cpu model ioctls 2. Add the missing kvm stat for pei events commit 19ced623db2fe91604d69f7d86b03144c5107739 Author: Linus Walleij Date: Wed Jun 8 14:56:39 2016 +0200 crypto: ux500 - memmove the right size The hash buffer is really HASH_BLOCK_SIZE bytes, someone must have thought that memmove takes n*u32 words by mistake. Tests work as good/bad as before after this patch. Cc: Joakim Bech Cc: stable@vger.kernel.org Reported-by: David Binderman Signed-off-by: Linus Walleij Signed-off-by: Herbert Xu drivers/crypto/ux500/hash/hash_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 12d3f49e1ffbbf8cbbb60acae5a21103c5c841ac Author: Anton Blanchard Date: Fri Jun 10 16:47:03 2016 +1000 crypto: vmx - Increase priority of aes-cbc cipher All of the VMX AES ciphers (AES, AES-CBC and AES-CTR) are set at priority 1000. Unfortunately this means we never use AES-CBC and AES-CTR, because the base AES-CBC cipher that is implemented on top of AES inherits its priority. To fix this, AES-CBC and AES-CTR have to be a higher priority. Set them to 2000. Testing on a POWER8 with: cryptsetup benchmark --cipher aes --key-size 256 Shows decryption speed increase from 402.4 MB/s to 3069.2 MB/s, over 7x faster. Thanks to Mike Strosaker for helping me debug this issue. Fixes: 8c755ace357c ("crypto: vmx - Adding CBC routines for VMX module") Cc: stable@vger.kernel.org Signed-off-by: Anton Blanchard Signed-off-by: Herbert Xu drivers/crypto/vmx/aes_cbc.c | 2 +- drivers/crypto/vmx/aes_ctr.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 975f57fdff1d0eb9816806cabd27162a8a1a4038 Author: Anton Blanchard Date: Fri Jun 10 16:47:02 2016 +1000 crypto: vmx - Fix ABI detection When calling ppc-xlate.pl, we pass it either linux-ppc64 or linux-ppc64le. The script however was expecting linux64le, a result of its OpenSSL origins. This means we aren't obeying the ppc64le ABIv2 rules. Fix this by checking for linux-ppc64le. Fixes: 5ca55738201c ("crypto: vmx - comply with ABIs that specify vrsave as reserved.") Cc: stable@vger.kernel.org Signed-off-by: Anton Blanchard Signed-off-by: Herbert Xu drivers/crypto/vmx/ppc-xlate.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9aeb26cfc2abc96be42b9df2d0f2dc5d805084ff Author: Jean-Philippe Brucker Date: Fri Jun 3 11:50:30 2016 +0100 iommu/arm-smmu: Wire up map_sg for arm-smmu-v3 The map_sg callback is missing from arm_smmu_ops, but is required by iommu.h. Similarly to most other IOMMU drivers, connect it to default_iommu_map_sg. Cc: Signed-off-by: Jean-Philippe Brucker Signed-off-by: Will Deacon Signed-off-by: Joerg Roedel drivers/iommu/arm-smmu-v3.c | 1 + 1 file changed, 1 insertion(+) commit 3bfbb4d1a480cc17f6ccfce13b76eb6c0dbeaf8c Author: Srinivas Kandagatla Date: Thu Jun 2 11:23:15 2016 +0100 regulator: qcom_smd: add list_voltage callback This patch adds support to list_voltage callback, so that consumers like mmc core, can get information of supported voltage range. Without this patch there is no way for mmc core to know this voltage range. Signed-off-by: Srinivas Kandagatla Signed-off-by: Mark Brown drivers/regulator/qcom_smd-regulator.c | 1 + 1 file changed, 1 insertion(+) commit 6b41d44862e8f3a4b95102c6ff6cad3fccc7994b Author: Nishanth Menon Date: Tue May 24 08:35:40 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_mem_ret As per the latest revision F of public TRM for DRA7/AM57xx SoCs SPRUHZ6F[1] (April 2016), with the exception of MPU power domain, all other power domains do not have memories capable of retention since they all operate in either "ON" or "OFF" mode. For these power states, the retention state for memories are basically ignored by PRCM and does not require to be programmed. [1] http://www.ti.com/lit/pdf/spruhz6 Signed-off-by: Nishanth Menon Signed-off-by: Tony Lindgren arch/arm/mach-omap2/powerdomains7xx_data.c | 65 ------------------------------ 1 file changed, 65 deletions(-) commit 9ffb668f268c79f2f58b56bbd63208440b31260f Author: Nishanth Menon Date: Tue May 24 08:35:39 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Remove unused pwrsts_logic_ret As per the latest revision F of public TRM for DRA7/AM57xx SoCs SPRUHZ6F[1] (April 2016), with the exception of MPU power domain (and CPUx sub power domains), all other power domains can either operate in "ON" mode OR in some cases, "OFF" mode. For these power states, the logic retention state is basically ignored by PRCM and does not require to be programmed. [1] http://www.ti.com/lit/pdf/spruhz6 Signed-off-by: Nishanth Menon Signed-off-by: Tony Lindgren arch/arm/mach-omap2/powerdomains7xx_data.c | 7 ------- 1 file changed, 7 deletions(-) commit d16c0d722d09496a03222dc27ee3071b7b1051e5 Author: Nishanth Menon Date: Tue May 24 08:35:38 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Set L3init and L4per to ON As per the latest revision F of public TRM for DRA7/AM57xx SoCs SPRUHZ6F[1] (April 2016), L4Per and L3init power domains now operate in always "ON" mode due to asymmetric aging limitations. Update the same [1] http://www.ti.com/lit/pdf/spruhz6 Signed-off-by: Nishanth Menon Signed-off-by: Tony Lindgren arch/arm/mach-omap2/powerdomains7xx_data.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d941ebe88a411aa281cc80477a93feb931a1b50b Author: Ivan Khoronzhuk Date: Sat Jun 11 01:11:54 2016 +0300 net: ethernet: ti: cpsw: use destroy ctlr to destroy channels There is no reason to destroy channels that are destroyed while cpdma_ctlr destroy. In this case no need to remember how much channels where created and destroy them by one, as cpdma_ctlr destroys all of them. Signed-off-by: Ivan Khoronzhuk Signed-off-by: David S. Miller drivers/net/ethernet/ti/cpsw.c | 4 ---- 1 file changed, 4 deletions(-) commit cbdf451164785c9cf5acd5d2983c1e7c778df4c1 Author: Eric Dumazet Date: Sun Jun 12 16:21:47 2016 -0700 net_sched: prio: properly report out of memory errors At Qdisc creation or change time, prio_tune() creates missing pfifo qdiscs but does not return an error code if one qdisc could not be allocated. Leaving a qdisc in non operational state without telling user anything about this problem is not good. Also, testing if we replace something different than noop_qdisc a second time makes no sense so I removed useless code. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller net/sched/sch_prio.c | 32 ++++++++++++-------------------- 1 file changed, 12 insertions(+), 20 deletions(-) commit ea01a18494b3d7a91b2f1f2a6a5aaef4741bc294 Author: Al Viro Date: Sun Jun 12 11:24:46 2016 -0400 autofs races * make autofs4_expire_indirect() skip the dentries being in process of expiry * do *not* mess with list_move(); making sure that dentry with AUTOFS_INF_EXPIRING are not picked for expiry is enough. * do not remove NO_RCU when we set EXPIRING, don't bother with smp_mb() there. Clear it at the same time we clear EXPIRING. Makes a bunch of tests simpler. * rename NO_RCU to WANT_EXPIRE, which is what it really is. Signed-off-by: Al Viro fs/autofs4/autofs_i.h | 8 ++++++-- fs/autofs4/expire.c | 27 ++++++++------------------- fs/autofs4/root.c | 2 +- 3 files changed, 15 insertions(+), 22 deletions(-) commit 5edb56491d4812c42175980759da53388e5d86f5 Author: Linus Torvalds Date: Sun Jun 12 07:20:35 2016 -0700 Linux 4.7-rc3 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 57120fac12321f636c83af447a081d680c0de2e2 Merge: 8714f8f 5a5e78c Author: Linus Torvalds Date: Sun Jun 12 06:30:39 2016 -0700 Merge branch 'for-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux Pull thermal management fixes from Zhang Rui: - fix an ordering issue in cpu cooling that cooling device is registered before it's ready (freq_table being populated). (Lukasz Luba) - fix a missing comment update (Caesar Wang) * 'for-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux: thermal: add the note for set_trip_temp thermal: cpu_cooling: fix improper order during initialization commit 30402c8949934fbaca07d9c20074d0d7a5a8385f Merge: b581755 eb0a4a4 Author: Miklos Szeredi Date: Sun Jun 12 12:05:21 2016 +0200 Merge branch 'overlayfs-af_unix-fix' into overlayfs-linus commit 86ef7f9cbfd564377028098cf20cc1c3ec2c776d Author: David S. Miller Date: Sat Jun 11 20:40:24 2016 -0700 ipconfig: Protect ic_addrservaddr with IPCONFIG_DYNAMIC. >> net/ipv4/ipconfig.c:130:15: warning: 'ic_addrservaddr' defined but not used [-Wunused-variable] static __be32 ic_addrservaddr = NONE; /* IP Address of the IP addresses'server */ Reported-by: kbuild test robot Signed-off-by: David S. Miller net/ipv4/ipconfig.c | 2 ++ 1 file changed, 2 insertions(+) commit 8714f8f5fe396ca513ccaaac2304497439c181fb Merge: 3a7c114 edb50a5 Author: Linus Torvalds Date: Sat Jun 11 18:42:59 2016 -0700 Merge branch 'for-linus' of git://git.kernel.dk/linux-block Pull block layer fixes from Jens Axboe: "A small collection of fixes for the current series. This contains: - Two fixes for xen-blkfront, from Bob Liu. - A bug fix for NVMe, releasing only the specific resources we requested. - Fix for a debugfs flags entry for nbd, from Josef. - Plug fix from Omar, fixing up a case of code being switched between two functions. - A missing bio_put() for the new discard callers of submit_bio_wait(), fixing a regression causing a leak of the bio. From Shaun. - Improve dirty limit calculation precision in the writeback code, fixing a case where setting a limit lower than 1% of memory would end up being zero. From Tejun" * 'for-linus' of git://git.kernel.dk/linux-block: NVMe: Only release requested regions xen-blkfront: fix resume issues after a migration xen-blkfront: don't call talk_to_blkback when already connected to blkback nbd: pass the nbd pointer for flags debugfs block: missing bio_put following submit_bio_wait blk-mq: really fix plug list flushing for nomerge queues writeback: use higher precision calculation in domain_dirty_limits() commit 3a7c114d358dbe1c5cba70e7d4c3cb39b3c8ecaa Merge: 45b00c9 b66b2a0 Author: Linus Torvalds Date: Sat Jun 11 18:03:39 2016 -0700 Merge tag 'gpio-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fixes from Linus Walleij: "A new bunch of GPIO fixes for v4.7. This time I am very grateful that Ricardo Ribalda Delgado went in and fixed my stupid refcounting mistakes in the removal path for GPIO chips. I had a feeling something was wrong here and so it was. It exploded on OMAP and it fixes their problem. Now it should be (more) solid. The rest i compilation, Kconfig and driver fixes. Some tagged for stable. Summary: - Fix a NULL pointer dereference when we are searching the GPIO device list but one of the devices have been removed (struct gpio_chip pointer is NULL). - Fix unaligned reference counters: we were ending on +3 after all said and done. It should be 0. Remove an extraneous get_device(), and call cdev_del() followed by device_del() in gpiochip_remove() instead and the count goes to zero and calls the release() function properly. - Fix a compile warning due to a missing #include in the OF/device tree portions. - Select ANON_INODES for GPIOLIB, we're using that for our character device. Some randconfig tests disclosed the problem. - Make sure the Zynq driver clock runs also without CONFIG_PM enabled - Fix an off-by-one error in the 104-DIO-48E driver - Fix warnings in bcm_kona_gpio_reset()" * tag 'gpio-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: gpio: bcm-kona: fix bcm_kona_gpio_reset() warnings gpio: select ANON_INODES gpio: include in gpiolib-of gpiolib: Fix unaligned used of reference counters gpiolib: Fix NULL pointer deference gpio: zynq: initialize clock even without CONFIG_PM gpio: 104-dio-48e: Fix control port offset computation off-by-one error commit 45b00c94be33db5d00595046663163ce55cbbfb9 Merge: 5d1f702 27ea13e Author: Linus Torvalds Date: Sat Jun 11 11:42:08 2016 -0700 Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "Two current fixes: - one affects Qemu CD ROM emulation, which stopped working after the updates in SCSI to require VPD pages from all conformant devices. Fix temporarily by blacklisting Qemu (we can relax later when they come into compliance). - The other is a fix to the optimal transfer size. We set up a minefield for ourselves by being confused about whether the limits are in bytes or sectors (SCSI optimal is in blocks and the queue parameter is in bytes). This tries to fix the problem (wrong setting for queue limits max_sectors) and make the problem more obvious by introducing a wrapper function" * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: sd: Fix rw_max for devices that report an optimal xfer size scsi: Add QEMU CD-ROM to VPD Inquiry Blacklist commit 5d1f7023fb2233d454ac3ac2fb7cc96fb94e9cac Merge: 90735c9 9f05e62 Author: Linus Torvalds Date: Sat Jun 11 11:24:54 2016 -0700 Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux Pull i2c fixes from Wolfram Sang: - a bigger fix for i801 to finally be able to be loaded on some machines again - smaller driver fixes - documentation update because of a renamed file * 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux: i2c: mux: reg: Provide of_match_table i2c: mux: refer to i2c-mux.txt i2c: octeon: Avoid printk after too long SMBUS message i2c: octeon: Missing AAK flag in case of I2C_M_RECV_LEN i2c: i801: Allow ACPI SystemIO OpRegion to conflict with PCI BAR commit 90735c99edfa1968a3e8da26a0b471a59fbc0f57 Merge: f1c32afd 06dfeef Author: Linus Torvalds Date: Sat Jun 11 11:08:57 2016 -0700 Merge tag 'devicetree-fixes-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux Pull DeviceTree fixes from Rob Herring: - fix unflatten_dt_nodes when dad parameter is set. - add vendor prefixes for TechNexion and UniWest - documentation fix for Marvell BT - OF IRQ kerneldoc fixes - restrict CMA alignment adjustments to non dma-coherent - a couple of warning fixes in reserved-memory code - DT maintainers updates * tag 'devicetree-fixes-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: drivers: of: add definition of early_init_dt_alloc_reserved_memory_arch drivers/of: Fix depth for sub-tree blob in unflatten_dt_nodes() drivers: of: Fix of_pci.h header guard dt-bindings: Add vendor prefix for TechNexion of: add vendor prefix for UniWest dt: bindings: fix documentation for MARVELL's bt-sd8xxx wireless device of: add missing const for of_parse_phandle_with_args() in !CONFIG_OF of: silence warnings due to max() usage drivers: of: of_reserved_mem: fixup the CMA alignment not to affect dma-coherent of: irq: fix of_irq_get[_byname]() kernel-doc MAINTAINERS: DeviceTree maintainer updates commit f1c32afdb83eb8fa1d130049f4bf8e14fdab7cc4 Merge: 3d0f0b6 f89dec7 Author: Linus Torvalds Date: Sat Jun 11 10:55:30 2016 -0700 Merge tag '20160610_uvc_compat_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/luto/linux Pull uvc compat XU ioctl fixes from Andy Lutomirski: "uvc's compat XU ioctls go through tons of potentially buggy indirection. The first patch removes the indirection. The second one cleans up the code. Compile-tested only. I have the hardware, but I have absolutely no idea what XU does, how to use it, what software to recompile as 32-bit, or what to test in that software" * tag '20160610_uvc_compat_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/luto/linux: uvc_v4l2: Simplify compat ioctl implementation uvc: Forward compat ioctls to their handlers directly commit f4070a19142d5ee06f0da0cef56a0e78995f172c Author: Luis de Bethencourt Date: Wed Jun 1 20:25:54 2016 +0100 staging: iio: ad5933: fix order of cycle conditions Correctly handle the settling time cycles value. The else branch is an impossible condition, > 1022 in the else branch of > 511. Flipping the order. Based on the Table 13 at the bottom of Page 25 of the Data Sheet: http://www.analog.com/media/en/technical-documentation/data-sheets/AD5933.pdf Signed-off-by: Luis de Bethencourt Reviewed-by: Lars-Peter Clausen Signed-off-by: Jonathan Cameron drivers/staging/iio/impedance-analyzer/ad5933.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7e982555d89cc84b1fa23b5d54c7ffd9f7753908 Author: Arnd Bergmann Date: Mon May 30 15:50:24 2016 +0200 staging: iio: fix ad7606_spi regression As pointed out by Geert Uytterhoeven, the patch was incorrect and breaks the driver, which was fortunately pointed out by this gcc warning: drivers/staging/iio/adc/ad7606_spi.c: In function ‘ad7606_spi_read_block’: drivers/staging/iio/adc/ad7606_spi.c:34: warning: ‘data’ is used uninitialized in this function The effect of the patch is that the data is copied into a random memory location (from the uninitialized pointer) instead of being byteswapped in place. This adds the initialization for the 'data' variable back to restore the original behavior. Cc: Ksenija Stanojevic Fixes: 87787e5ef727 ("Staging: iio: Fix sparse endian warning") Signed-off-by: Arnd Bergmann Acked-by: Geert Uytterhoeven Signed-off-by: Jonathan Cameron drivers/staging/iio/adc/ad7606_spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6e85dbe4b461e59fa3cad6f6235cb47fa4c6a629 Author: Crestez Dan Leonard Date: Fri Jun 3 21:30:24 2016 +0300 iio: inv_mpu6050: Fix use-after-free in ACPI code In some cases this can result in incorrectly returning a negative value from asus_acpi_get_sensor_info and the AK8963 magnetometer failing to show up. Note cpm is an alias for buffer.pointer which isn't apparent in this patch on it's own. Cc: Srinivas Pandruvada Signed-off-by: Crestez Dan Leonard Acked-by: Daniel Baluta Signed-off-by: Jonathan Cameron drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 92ca8241533009e4e05a9f3999a75389678af094 Author: Manuel Lauss Date: Sat Jun 11 00:13:04 2016 +0200 net: au1000_eth: fix PHY detection Commit 7f854420fbfe9d49afe2ffb1df052cfe8e215541 ("phy: Add API for {un}registering an mdio device to a bus.") broke PHY detection on this driver with a copy-paste bug: The code is looking 32 times for a PHY at address 0. Fixes ethernet on AMD DB1100/DB1500/DB1550 boards which have their (autodetected) PHYs at address 31. Cc: Andrew Lunn Signed-off-by: Manuel Lauss Signed-off-by: David S. Miller drivers/net/ethernet/amd/au1000_eth.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 86c5fe4c932a8ef2d32f8b3d32cc9f0476fc54f3 Author: David S. Miller Date: Fri Jun 10 23:34:24 2016 -0700 Revert "net: au1000_eth: fix PHY detection" This reverts commit a2f27217e4e60e663b5b971b0ccb287a9548b04e. I applied the wrong version of this. Signed-off-by: David S. Miller drivers/net/ethernet/amd/au1000_eth.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit a2f27217e4e60e663b5b971b0ccb287a9548b04e Author: Manuel Lauss Date: Fri Jun 10 16:53:05 2016 +0200 net: au1000_eth: fix PHY detection Commit 7f854420fbfe9d49afe2ffb1df052cfe8e215541 ("phy: Add API for {un}registering an mdio device to a bus.") broke PHY detection on this driver with a copy-paste bug: The code is looking 32 times for a PHY at address 0. Fixes ethernet on AMD DB1100/DB1500/DB1550 boards which have their (autodetected) PHYs at address 31. Cc: Andrew Lunn Signed-off-by: Manuel Lauss Signed-off-by: David S. Miller drivers/net/ethernet/amd/au1000_eth.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit a4b42ab3205a28b24eb0d480935cf9fd1051a7f2 Merge: 0b392be 82c6544 Author: David S. Miller Date: Fri Jun 10 23:29:30 2016 -0700 Merge branch 'mediatek-fixes' John Crispin says: ==================== net: mediatek: various small fixes This series contains various small fixes that we stumbled across while doing thorough testing and code level reviewing of the driver. Changes in V2: * drop the DQL patch from the list until a better solution is found ==================== Signed-off-by: David S. Miller commit 82c6544dddc6c4bd940917af2f987dee6be0fc17 Author: John Crispin Date: Fri Jun 10 13:28:08 2016 +0200 net: mediatek: remove superfluous queue wake up call The code checks if the queue should be stopped because we are below the threshold of free descriptors only to check if it should be started again. If we do end up in a state where we are at the threshold limit, it makes more sense to just stop the queue and wait for the next IRQ to trigger the TX housekeeping again. There is no rush in enqueuing the next packet, it needs to wait for all the others in the queue to be dispatched first anyway. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit ad3cba989e8b1bbefe078eece29f0e8d8aaea1d6 Author: John Crispin Date: Fri Jun 10 13:28:07 2016 +0200 net: mediatek: only wake the queue if it is stopped The current code unconditionally wakes up the queue at the end of each tx_poll action. Change the code to only wake up the queues if any of them have actually been stopped before. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) commit 12c97c13ea7174db5b5dc4a1ef91d4e9245bb569 Author: John Crispin Date: Fri Jun 10 13:28:06 2016 +0200 net: mediatek: fix off by one in the TX ring allocation The TX ring setup has an off by one error causing it to not utilise all descriptors. This has the side effect that we need to reset the next pointer at runtime to make it work. Fix the off by one and remove the code fixing the ring at runtime. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit eaadf9fd3f6390f6ecbd0dfbd5997a0486fc9d5e Author: John Crispin Date: Fri Jun 10 13:28:05 2016 +0200 net: mediatek: increase watchdog_timeo During stress testing, after reducing the threshold value, we have seen TX timeouts that were caused by the watchdog_timeo value being too low. Increase the value to 5 * HZ which is a value commonly used by many other drivers. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 04698cccb1de54d5d97fda2e4a1c6ca365da0f70 Author: John Crispin Date: Fri Jun 10 13:28:04 2016 +0200 net: mediatek: fix threshold value The logic to calculate the threshold value for stopping the TX queue is bad. Currently it will always use 1/2 of the rings size, which is way too much. Set the threshold to MAX_SKB_FRAGS. This makes sure that the queue is stopped when there is not enough room to accept an additional segment.  Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 2ff0bb61646f286fa97db2904491974302a14f1f Author: John Crispin Date: Fri Jun 10 13:28:03 2016 +0200 net: mediatek: disable all interrupts during probe The current code only disables those IRQs that we will later use. To ensure that we have a predefined state, we really want to disable all IRQs. Change the code to disable all IRQs to achieve this. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6675086d04e7c0748cd5884f7c8611b5f0836250 Author: John Crispin Date: Fri Jun 10 13:28:02 2016 +0200 net: mediatek: add next data pointer coherency protection The QDMA engine can fail to update the register pointing to the next TX descriptor if this bit does not get set in the QDMA configuration register. Not setting this bit can result in invalid values inside the TX rings registers which will causes TX stalls. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 +- drivers/net/ethernet/mediatek/mtk_eth_soc.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) commit 94321a9fc9f5b6c6e949cc7c69741538f556ab74 Author: John Crispin Date: Fri Jun 10 13:28:01 2016 +0200 net: mediatek: dropped rx packets are not being counted properly There are two places inside mtk_poll_rx where rx_dropped is not being incremented properly. Fix this by adding the missing code to increment the counter. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 ++ 1 file changed, 2 insertions(+) commit 2fae723cefb8bfe712371978288aa0a70b54802e Author: John Crispin Date: Fri Jun 10 13:28:00 2016 +0200 net: mediatek: invalid buffer lookup in mtk_tx_map() The lookup of the tx_buffer in the error path inside mtk_tx_map() uses the wrong descriptor pointer. This looks like a copy & paste error. Change the code to use the correct pointer. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 605e4fe476956c67ced8518247e6c9601a31b868 Author: John Crispin Date: Fri Jun 10 13:27:59 2016 +0200 net: mediatek: fix missing free of scratch memory Scratch memory gets allocated in mtk_init_fq_dma() but the corresponding code to free it is missing inside mtk_dma_free() causing a memory leak. With this patch applied, we can run ifconfig up/down several thousand times without any problems. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 18 +++++++++++++----- drivers/net/ethernet/mediatek/mtk_eth_soc.h | 2 ++ 2 files changed, 15 insertions(+), 5 deletions(-) commit 562c5a70400c75f50d99de631666ac7cc2f03958 Author: John Crispin Date: Fri Jun 10 13:27:58 2016 +0200 net: mediatek: add missing return code check The code fails to check if the scratch memory was properly allocated. Add this check and return with an error if the allocation failed. Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +++ 1 file changed, 3 insertions(+) commit 0b392be9a86560dae3af2e7528f226ff465ab549 Author: Ben Dooks Date: Fri Jun 10 12:11:06 2016 +0100 net: ipconfig: avoid warning by making ic_addrservaddr static The symbol ic_addrservaddr is not static, but has no declaration to match so make it static to fix the following warning: net/ipv4/ipconfig.c:130:8: warning: symbol 'ic_addrservaddr' was not declared. Should it be static? Signed-off-by: Ben Dooks Signed-off-by: David S. Miller net/ipv4/ipconfig.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c3ec5e5ce9cea1f369a5a8ad69d6471680796bc6 Author: Ben Dooks Date: Thu Jun 9 18:05:09 2016 +0100 net: diag: add missing declarations The functions inet_diag_msg_common_fill and inet_diag_msg_attrs_fill seem to have been missed from the include/linux/inet_diag.h header file. Add them to fix the following warnings: net/ipv4/inet_diag.c:69:6: warning: symbol 'inet_diag_msg_common_fill' was not declared. Should it be static? net/ipv4/inet_diag.c:108:5: warning: symbol 'inet_diag_msg_attrs_fill' was not declared. Should it be static? Signed-off-by: Ben Dooks Signed-off-by: David S. Miller include/linux/inet_diag.h | 6 ++++++ net/sctp/sctp_diag.c | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) commit e4600d56323ed119469fdcb21564f7544e1e6b3c Merge: 11c011a 31b2a32 Author: Greg Kroah-Hartman Date: Fri Jun 10 23:06:21 2016 -0700 Merge tag 'phy-for-4.7-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy into usb-linus Kishon writes: phy: for 4.7-rc *) Fix compiler warning in exynos-mipi-video *) Fix in ti-pipe3 PHY to program the DPLL even if it was already locked Signed-off-by: Kishon Vijay Abraham I commit 56fae404fb2c306db0a35dad0d16fa24c65678f3 Author: Ido Schimmel Date: Tue Jun 7 12:06:58 2016 +0300 bridge: Fix incorrect re-injection of STP packets Commit 8626c56c8279 ("bridge: fix potential use-after-free when hook returns QUEUE or STOLEN verdict") fixed incorrect usage of NF_HOOK's return value by consuming packets in okfn via br_pass_frame_up(). However, this function re-injects packets to the Rx path with skb->dev set to the bridge device, which breaks kernel's STP, as all STP packets appear to originate from the bridge device itself. Instead, if STP is enabled and bridge isn't a 802.1ad bridge, then learn packet's SMAC and inject it back to the Rx path for further processing by the packet handlers. The patch also makes netfilter's behavior consistent with regards to packets destined to the Bridge Group Address, as no hook registered at LOCAL_IN will ever be called, regardless if STP is enabled or not. Cc: Florian Westphal Cc: Shmulik Ladkani Cc: Toshiaki Makita Fixes: 8626c56c8279 ("bridge: fix potential use-after-free when hook returns QUEUE or STOLEN verdict") Signed-off-by: Jiri Pirko Signed-off-by: Ido Schimmel Signed-off-by: David S. Miller net/bridge/br_input.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit fc0f7e3317c5f406e6d5520209b4689a4ffecfdf Author: Manfred Schlaegl Date: Mon Jun 6 10:47:47 2016 +0200 net: phy: smsc: reintroduced unconditional soft reset We detected some problems using the smsc lan8720a in combination with i.MX28 and tracked this down to commit 21009686662f ("net: phy: smsc: move smsc_phy_config_init reset part in a soft_reset function") With 2100968666 the generic soft reset is replaced by a specific function which handles power down state correctly. But additionally the soft reset itself got conditional and is therefore also only performed if the phy is in power down state. This patch keeps the conditional wake up from power down, but re-introduces the unconditional soft reset using the generic soft reset function. It was tested on linux-4.1.25 and linux-4.7.0-rc2. Signed-off-by: Manfred Schlaegl Signed-off-by: David S. Miller drivers/net/phy/smsc.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) commit 69f1804a9ab602701217a8c23d371f8f36f8b57a Author: Alexander Usyskin Date: Mon May 9 00:07:46 2016 -0400 mei: don't use wake_up_interruptible for wr_ctrl wr_ctrl waiters are none interruptible, so should be waken up with call to wake_up and not to wake_up_interruptible. This fixes commit: 7ff4bdd ("mei: fix waiting for wr_ctrl for corner cases.") Signed-off-by: Alexander Usyskin Signed-off-by: Tomas Winkler Signed-off-by: Greg Kroah-Hartman drivers/misc/mei/client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 27bf60db2485c09eba3b473ce5ffbaa4bba0c24e Merge: 7ff6977 0fbbbf8 Author: Dave Airlie Date: Sat Jun 11 09:34:20 2016 +1000 Merge tag 'drm-amdkfd-fixes-2016-06-03' of git://people.freedesktop.org/~gabbayo/linux into drm-fixes * tag 'drm-amdkfd-fixes-2016-06-03' of git://people.freedesktop.org/~gabbayo/linux: drm/amdkfd: print once about mem_banks truncation drm/amdkfd: destroy dbgmgr in notifier release drm/amdkfd: unbind only existing processes commit f89dec72e98b34b3be66bb1ef1be62974c0f8483 Author: Andy Lutomirski Date: Wed May 11 17:41:27 2016 -0700 uvc_v4l2: Simplify compat ioctl implementation The uvc compat ioctl implementation seems to have copied user data for no good reason. Remove a bunch of copies. Signed-off-by: Andy Lutomirski drivers/media/usb/uvc/uvc_v4l2.c | 58 ++-------------------------------------- 1 file changed, 2 insertions(+), 56 deletions(-) commit a44323e2a8f342848bb77e8e04fcd85fcb91b3b4 Author: Andy Lutomirski Date: Tue May 24 15:13:02 2016 -0700 uvc: Forward compat ioctls to their handlers directly The current code goes through a lot of indirection just to call a known handler. Simplify it: just call the handlers directly. Cc: stable@vger.kernel.org Signed-off-by: Andy Lutomirski drivers/media/usb/uvc/uvc_v4l2.c | 39 ++++++++++++++++++--------------------- 1 file changed, 18 insertions(+), 21 deletions(-) commit 3d0f0b6a5520878305589411b8d434fe088e4f21 Merge: ccf55f7 719da39 Author: Linus Torvalds Date: Fri Jun 10 14:13:27 2016 -0700 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs fixes from Chris Mason: "Has some fixes and some new self tests for btrfs. The self tests are usually disabled in the .config file (unless you're doing btrfs dev work), and this bunch is meant to find problems with the 64K page size patches. Jeff has a patch to help people see if they are using the hardware assist crc32c module, which really helps us nail down problems when people ask why crcs are using so much CPU. Otherwise, it's small fixes" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: self-tests: Fix extent buffer bitmap test fail on BE system Btrfs: self-tests: Fix test_bitmaps fail on 64k sectorsize Btrfs: self-tests: Use macros instead of constants and add missing newline Btrfs: self-tests: Support testing all possible sectorsizes and nodesizes Btrfs: self-tests: Execute page straddling test only when nodesize < PAGE_SIZE btrfs: advertise which crc32c implementation is being used at module load Btrfs: add validadtion checks for chunk loading Btrfs: add more validation checks for superblock Btrfs: clear uptodate flags of pages in sys_array eb Btrfs: self-tests: Support non-4k page size Btrfs: Fix integer overflow when calculating bytes_per_bitmap Btrfs: test_check_exists: Fix infinite loop when searching for free space entries Btrfs: end transaction if we abort when creating uuid root btrfs: Use __u64 in exported linux/btrfs.h. commit ccf55f73a607dba0cec470e677e3fad754304220 Merge: c8f17d6 8017ea3 Author: Linus Torvalds Date: Fri Jun 10 12:23:49 2016 -0700 Merge tag 'powerpc-4.7-3Michael Ellerman:' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from - ptrace: Fix out of bounds array access warning from Khem Raj - pseries: Fix PCI config address for DDW from Gavin Shan - pseries: Fix IBM_ARCH_VEC_NRCORES_OFFSET since POWER8NVL was added from Michael Ellerman - of: fix autoloading due to broken modalias with no 'compatible' from Wolfram Sang - radix: Fix always false comparison against MMU_NO_CONTEXT from Aneesh Kumar K.V - hash: Compute the segment size correctly for ISA 3.0 from Aneesh Kumar K.V - nohash: Fix build break with 64K pages from Michael Ellerman * tag 'powerpc-4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc/nohash: Fix build break with 64K pages powerpc/mm/hash: Compute the segment size correctly for ISA 3.0 powerpc/mm/radix: Fix always false comparison against MMU_NO_CONTEXT of: fix autoloading due to broken modalias with no 'compatible' powerpc/pseries: Fix IBM_ARCH_VEC_NRCORES_OFFSET since POWER8NVL was added powerpc/pseries: Fix PCI config address for DDW powerpc/ptrace: Fix out of bounds array access warning commit c8f17d60645cc38cbe5f6e2b2f93370483b28895 Merge: f5364c1 38bab98 Author: Linus Torvalds Date: Fri Jun 10 12:18:34 2016 -0700 Merge tag 'hwmon-for-linus-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging Pull hwmon fixes from Guenter Roeck: - fix regression in fam15h_power driver - minor variable type fix in lm90 driver - document compatible statement for ina2xx driver * tag 'hwmon-for-linus-v4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: hwmon: (lm90) use proper type for update_interval hwmon: (ina2xx) Document compatible for INA231 hwmon: (fam15h_power) Disable preemption when reading registers commit f5364c150aa645b3d7daa21b5c0b9feaa1c9cd6d Merge: 33fc259 29d6455 Author: Linus Torvalds Date: Fri Jun 10 12:10:02 2016 -0700 Merge branch 'stacking-fixes' (vfs stacking fixes from Jann) Merge filesystem stacking fixes from Jann Horn. * emailed patches from Jann Horn : sched: panic on corrupted stack end ecryptfs: forbid opening files without mmap handler proc: prevent stacking filesystems on top commit 29d6455178a09e1dc340380c582b13356227e8df Author: Jann Horn Date: Wed Jun 1 11:55:07 2016 +0200 sched: panic on corrupted stack end Until now, hitting this BUG_ON caused a recursive oops (because oops handling involves do_exit(), which calls into the scheduler, which in turn raises an oops), which caused stuff below the stack to be overwritten until a panic happened (e.g. via an oops in interrupt context, caused by the overwritten CPU index in the thread_info). Just panic directly. Signed-off-by: Jann Horn Signed-off-by: Linus Torvalds kernel/sched/core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 2f36db71009304b3f0b95afacd8eba1f9f046b87 Author: Jann Horn Date: Wed Jun 1 11:55:06 2016 +0200 ecryptfs: forbid opening files without mmap handler This prevents users from triggering a stack overflow through a recursive invocation of pagefault handling that involves mapping procfs files into virtual memory. Signed-off-by: Jann Horn Acked-by: Tyler Hicks Cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds fs/ecryptfs/kthread.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit e54ad7f1ee263ffa5a2de9c609d58dfa27b21cd9 Author: Jann Horn Date: Wed Jun 1 11:55:05 2016 +0200 proc: prevent stacking filesystems on top This prevents stacking filesystems (ecryptfs and overlayfs) from using procfs as lower filesystem. There is too much magic going on inside procfs, and there is no good reason to stack stuff on top of procfs. (For example, procfs does access checks in VFS open handlers, and ecryptfs by design calls open handlers from a kernel thread that doesn't drop privileges or so.) Signed-off-by: Jann Horn Cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds fs/proc/root.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 33fc259a2053f89d6ea0f07f534079b58899d128 Merge: 75d089d 0106d45 Author: Linus Torvalds Date: Fri Jun 10 11:57:17 2016 -0700 Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 fix from Will Deacon: "A fix for an issue that Alex saw whilst swapping with hardware access/dirty bit support enabled in the kernel: Fix a failure to fault in old pages on a write when CONFIG_ARM64_HW_AFDBM is enabled" * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: mm: always take dirty state from new pte in ptep_set_access_flags commit 75d089d12a66a8662d888ff60a9eaea230fed53e Merge: 60e3830 9d98bce Author: Linus Torvalds Date: Fri Jun 10 11:36:04 2016 -0700 Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Ingo Molnar: "Misc fixes from all around the map, plus a commit that introduces a new header of Intel model name symbols (unused) that will make the next merge window easier" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/ioapic: Fix incorrect pointers in ioapic_setup_resources() x86/entry/traps: Don't force in_interrupt() to return true in IST handlers x86/cpu/AMD: Extend X86_FEATURE_TOPOEXT workaround to newer models x86/cpu/intel: Introduce macros for Intel family numbers x86, build: copy ldlinux.c32 to image.iso x86/msr: Use the proper trace point conditional for writes commit 60e383037ba192d86fc0110b5b5a9a2013d83b13 Merge: 7fcbc23 4698f88 Author: Linus Torvalds Date: Fri Jun 10 11:24:39 2016 -0700 Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Ingo Molnar: "Two scheduler debugging fixes" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/debug: Fix 'schedstats=enable' cmdline option sched/debug: Fix /proc/sched_debug regression commit 7fcbc230c6f0ee96d397e30d061ef4995879b835 Merge: 02b07bd 62a92c8 Author: Linus Torvalds Date: Fri Jun 10 11:15:41 2016 -0700 Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf fixes from Ingo Molnar: "A handful of tooling fixes, two PMU driver fixes and a cleanup of redundant code that addresses a security analyzer false positive" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf/core: Remove a redundant check perf/x86/intel/uncore: Remove SBOX support for Broadwell server perf ctf: Convert invalid chars in a string before set value perf record: Fix crash when kptr is restricted perf symbols: Check kptr_restrict for root perf/x86/intel/rapl: Fix pmus free during cleanup commit 02b07bde619e179bf7ac0e073d28e2e038dfab77 Merge: 606c17f 077fa7a Author: Linus Torvalds Date: Fri Jun 10 10:53:46 2016 -0700 Merge branch 'locking-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull locking fixes from Ingo Molnar: "Misc fixes: - a file-based futex fix - one more spin_unlock_wait() fix - a ww-mutex deadlock detection improvement/fix - and a raw_read_seqcount_latch() barrier fix" * 'locking-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: futex: Calculate the futex key based on a tail page for file-based futexes locking/qspinlock: Fix spin_unlock_wait() some more locking/ww_mutex: Report recursive ww_mutex locking early locking/seqcount: Re-fix raw_read_seqcount_latch() commit 606c17f4e9b788ed9ce9d7849619498cc67b9072 Merge: 94fcad6 c753439 Author: Linus Torvalds Date: Fri Jun 10 10:47:22 2016 -0700 Merge branch 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull EFI fixes from Ingo Molnar: "Two fixes: a regression/crash fix, and a message output fix" * 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: efi/arm: Fix the format of EFI debug messages efi: Fix for_each_efi_memory_desc_in_map() for empty memmaps commit 94fcad6932e5eec50b3e5d82c5ce53bca11a2fa2 Merge: 698ea54 0b0d81e Author: Linus Torvalds Date: Fri Jun 10 10:37:01 2016 -0700 Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull objtool fix from Ingo Molnar: "Addresses a false positive warning in the GPU/DRM code" [ Technically it's not a "false positive", but it's the virtual GPU interface that needs the frame pointer for its own internal purposes ] * 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: objtool, drm/vmwgfx: Fix "duplicate frame pointer save" warning commit ba65dc5ef16f82fba77869cecf7a7d515f61446b Author: Al Viro Date: Fri Jun 10 11:32:47 2016 -0400 much milder d_walk() race d_walk() relies upon the tree not getting rearranged under it without rename_lock being touched. And we do grab rename_lock around the places that change the tree topology. Unfortunately, branch reordering is just as bad from d_walk() POV and we have two places that do it without touching rename_lock - one in handling of cursors (for ramfs-style directories) and another in autofs. autofs one is a separate story; this commit deals with the cursors. * mark cursor dentries explicitly at allocation time * make __dentry_kill() leave ->d_child.next pointing to the next non-cursor sibling, making sure that it won't be moved around unnoticed before the parent is relocked on ascend-to-parent path in d_walk(). * make d_walk() skip cursors explicitly; strictly speaking it's not necessary (all callbacks we pass to d_walk() are no-ops on cursors), but it makes analysis easier. Signed-off-by: Al Viro fs/dcache.c | 58 ++++++++++++++++++++++++++++++++++++++++++++------ fs/internal.h | 1 + fs/libfs.c | 4 +--- include/linux/dcache.h | 1 + 4 files changed, 55 insertions(+), 9 deletions(-) commit 698ea54dde6768d4a96080d0fb796cb3a4eadaf8 Merge: 729d378 5021953 Author: Linus Torvalds Date: Fri Jun 10 08:32:24 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes from David Miller: 1) nfnetlink timestamp taken from wrong skb, fix from Florian Westphal. 2) Revert some msleep conversions in rtlwifi as these spots are in atomic context, from Larry Finger. 3) Validate that NFTA_SET_TABLE attribute is actually specified when we call nf_tables_getset(). From Phil Turnbull. 4) Don't do mdio_reset in stmmac driver with spinlock held as that can sleep, from Vincent Palatin. 5) sk_filter() does things other than run a BPF filter, so we should not elide it's call just because sk->sk_filter is NULL. Fix from Eric Dumazet. 6) Fix missing backlog updates in several packet schedulers, from Cong Wang. 7) bnx2x driver should allow VLAN add/remove while the interface is down, from Michal Schmidt. 8) Several RDS/TCP race fixes from Sowmini Varadhan. 9) fq_codel scheduler doesn't return correct queue length in dumps, from Eric Dumazet. 10) Fix TCP stats for tail loss probe and early retransmit in ipv6, from Yuchung Cheng. 11) Properly initialize udp_tunnel_socket_cfg in l2tp_tunnel_create(), from Guillaume Nault. 12) qfq scheduler leaks SKBs if a kzalloc fails, fix from Florian Westphal. 13) sock_fprog passed into PACKET_FANOUT_DATA needs compat handling, from Willem de Bruijn. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (85 commits) vmxnet3: segCnt can be 1 for LRO packets packet: compat support for sock_fprog stmmac: fix parameter to dwmac4_set_umac_addr() net/mlx5e: Fix blue flame quota logic net/mlx5e: Use ndo_stop explicitly at shutdown flow net/mlx5: E-Switch, always set mc_promisc for allmulti vports net/mlx5: E-Switch, Modify node guid on vf set MAC net/mlx5: E-Switch, Fix vport enable flow net/mlx5: E-Switch, Use the correct error check on returned pointers net/mlx5: E-Switch, Use the correct free() function net/mlx5: Fix E-Switch flow steering capabilities check net/mlx5: Fix flow steering NIC capabilities check net/mlx5: Fix root flow table update net/mlx5: Fix MLX5_CMD_OP_MAX to be defined correctly net/mlx5: Fix masking of reserved bits in XRCD number net/mlx5: Fix the size of modify QP mailbox mlxsw: spectrum: Don't sleep during ndo_get_phys_port_name() mlxsw: spectrum: Make split flow match firmware requirements wext: Fix 32 bit iwpriv compatibility issue with 64 bit Kernel cfg80211: remove get/set antenna and tx power warnings ... commit 729d378479ddb7aeafe762f59a5fc1eb79c61d7a Merge: 00da900 35639a0e Author: Linus Torvalds Date: Fri Jun 10 08:27:30 2016 -0700 Merge tag 'sound-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "We have only few, mainly HD-audio device-specific fixes. Realtek codec driver got a slightly more LOC, but they are all for the new codec chip, and won't affect others at all" * tag 'sound-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: hda - Add PCI ID for Kabylake ALSA: hda/realtek: Add T560 docking unit fixup ALSA: hda - Fix headset mic detection problem for Dell machine ALSA: uapi: Add three missing header files to Kbuild file ALSA: hda/realtek - Add support for new codecs ALC700/ALC701/ALC703 ALSA: hda/realtek - ALC256 speaker noise issue commit 00da90085e84f4cee316c196041d76ce5fba677f Merge: f758bbd 7ff6977 Author: Linus Torvalds Date: Fri Jun 10 08:21:06 2016 -0700 Merge tag 'drm-fixes-for-v4.7-rc3' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "This weeks instalment of fixes: amdgpu: Lots of memory leak and firmware leak fixes nouveau: Collection of display fixes, KASAN fixes vc4: vblank/pageflipping fixes fsl-dcu: Regmap cache fix omap: Unused variable warning fix. Nothing too surprising so far" * tag 'drm-fixes-for-v4.7-rc3' of git://people.freedesktop.org/~airlied/linux: (46 commits) drm/amdgpu: fix warning with powerplay disabled. drm/amd/powerplay: delete useless code as pptable changed in vbios. drm/amd/powerplay: fix bug visit array out of bounds drm/amdgpu: fix smu ucode memleak (v2) drm/amdgpu: add release firmware for cgs drm/amdgpu: fix tonga smu_fini mem leak drm/amdgpu: fix fiji smu fini mem leak drm/amdgpu: fix cik sdma ucode memleak drm/amdgpu: fix sdma24 ucode mem leak drm/amdgpu: fix sdma3 ucode mem leak drm/amdgpu: fix uvd fini mem leak drm/amdgpu: fix gfx 7 ucode mem leak drm/amdgpu: fix gfx8 ucode mem leak drm/amdgpu: fix missing free wb for cond_exec drm/amdgpu: fix memleak in pptable_init drm/amdgpu: fix mem leak in atombios drm/amdgpu: fix mem leak in pplib/hwmgr drm/amdgpu: fix mem leak in smumgr drm/amdgpu: add pipeline sync while vmid switch in same ctx drm/amdgpu: vBIOS post only call when mem_size zero ... commit f758bbd470723b306a01bc3655ef77f888aa3c99 Merge: 524a3f2 bd6ac2a Author: Linus Torvalds Date: Fri Jun 10 08:15:37 2016 -0700 Merge tag 'acpi-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fix from Rafael Wysocki: "A recently introduced boot regression related to the ACPI EC initialization is addressed by restoring the previous behavior (Lv Zheng)" * tag 'acpi-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / EC: Fix a boot EC regresion by restoring boot EC support for the DSDT EC commit 524a3f2ca284831262fcf5e4ca145ef32f4b282d Merge: 9557c3c 3681196 Author: Linus Torvalds Date: Fri Jun 10 08:09:12 2016 -0700 Merge tag 'pm-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "Stable-candidate fixes for the intel_pstate driver and the cpuidle core. Specifics: - Fix two intel_pstate initialization issues, one of which was introduced during the 4.4 cycle (Srinivas Pandruvada) - Fix kernel build with CONFIG_UBSAN set and CONFIG_CPU_IDLE unset (Catalin Marinas)" * tag 'pm-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: cpufreq: intel_pstate: Fix ->set_policy() interface for no_turbo cpufreq: intel_pstate: Fix code ordering in intel_pstate_set_policy() cpuidle: Do not access cpuidle_devices when !CONFIG_CPU_IDLE commit 9557c3cfdaa792c7db04b86f47b5dd1e6dc5ec4f Merge: 147d9e7 18aba41 Author: Linus Torvalds Date: Fri Jun 10 08:00:47 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge misc fixes from Andrew Morton: "7 fixes" * emailed patches from Andrew Morton : mm/fadvise.c: do not discard partial pages with POSIX_FADV_DONTNEED mm: introduce dedicated WQ_MEM_RECLAIM workqueue to do lru_add_drain_all kernel/relay.c: fix potential memory leak mm: thp: broken page count after commit aa88b68c3b1d revert "mm: memcontrol: fix possible css ref leak on oom" kasan: change memory hot-add error messages to info messages mm/hugetlb: fix huge page reserve accounting for private mappings commit 9d98bcec731756b8688b59ec998707924d716d7b Author: Rui Wang Date: Wed Jun 8 14:59:52 2016 +0800 x86/ioapic: Fix incorrect pointers in ioapic_setup_resources() On a 4-socket Brickland system, hot-removing one ioapic is fine. Hot-removing the 2nd one causes panic in mp_unregister_ioapic() while calling release_resource(). It is because the iomem_res pointer has already been released when removing the first ioapic. To explain the use of &res[num] here: res is assigned to ioapic_resources, and later in ioapic_insert_resources() we do: struct resource *r = ioapic_resources; for_each_ioapic(i) { insert_resource(&iomem_resource, r); r++; } Here 'r' is treated as an arry of 'struct resource', and the r++ ensures that each element of the array is inserted separately. Thus we should call release_resouce() on each element at &res[num]. Fix it by assigning the correct pointers to ioapics[i].iomem_res in ioapic_setup_resources(). Signed-off-by: Rui Wang Signed-off-by: Thomas Gleixner Cc: tony.luck@intel.com Cc: linux-pci@vger.kernel.org Cc: rjw@rjwysocki.net Cc: linux-acpi@vger.kernel.org Cc: bhelgaas@google.com Link: http://lkml.kernel.org/r/1465369193-4816-3-git-send-email-rui.y.wang@intel.com Signed-off-by: Ingo Molnar arch/x86/kernel/apic/io_apic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe5aa34d6eb9c4d34071845f70f3714b41c8a77d Author: Ryo Kodama Date: Wed Jun 8 10:58:23 2016 +0900 pwm: sysfs: Get return value from pwm_apply_state() This patch adds to check the return value from pwm_apply_state() used in enable_store(). The error of enable_store() doesn't work if the return value doesn't received. Signed-off-by: Ryo Kodama Signed-off-by: Yoshihiro Shimoda Fixes: 39100ceea79f ("pwm: Switch to the atomic API") Signed-off-by: Thierry Reding drivers/pwm/sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ef2bf4997f7da6efa8540d9cf726c44bf2b863af Author: Brian Norris Date: Fri May 27 09:45:49 2016 -0700 pwm: Improve args checking in pwm_apply_state() It seems like in the process of refactoring pwm_config() to utilize the newly-introduced pwm_apply_state() API, some args/bounds checking was dropped. In particular, I noted that we are now allowing invalid period selections, e.g.: # echo 1 > /sys/class/pwm/pwmchip0/export # cat /sys/class/pwm/pwmchip0/pwm1/period 100 # echo 101 > /sys/class/pwm/pwmchip0/pwm1/duty_cycle [... driver may or may not reject the value, or trigger some logic bug ...] It's better to see: # echo 1 > /sys/class/pwm/pwmchip0/export # cat /sys/class/pwm/pwmchip0/pwm1/period 100 # echo 101 > /sys/class/pwm/pwmchip0/pwm1/duty_cycle -bash: echo: write error: Invalid argument This patch reintroduces some bounds checks in both pwm_config() (for its signed parameters; we don't want to convert negative values into large unsigned values) and in pwm_apply_state() (which fix the above described behavior, as well as other potential API misuses). Fixes: 5ec803edcb70 ("pwm: Add core infrastructure to allow atomic updates") Signed-off-by: Brian Norris Acked-by: Boris Brezillon Signed-off-by: Thierry Reding drivers/pwm/core.c | 3 ++- include/linux/pwm.h | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) commit aaee8c3c5cce2d9107310dd9f3026b4f901d441c Author: Andy Lutomirski Date: Tue May 24 15:54:04 2016 -0700 x86/entry/traps: Don't force in_interrupt() to return true in IST handlers Forcing in_interrupt() to return true if we're not in a bona fide interrupt confuses the softirq code. This fixes warnings like: NOHZ: local_softirq_pending 282 ... which can happen when running things like selftests/x86. This will change perf's static percpu buffer usage in IST context. I think this is okay, and it's changing the behavior to match historical (pre-4.0) behavior. Signed-off-by: Andy Lutomirski Cc: Andy Lutomirski Cc: Borislav Petkov Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Linus Torvalds Cc: Oleg Nesterov Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: stable@vger.kernel.org Fixes: 959274753857 ("x86, traps: Track entry into and exit from IST context") Link: http://lkml.kernel.org/r/cdc215f94d118d691d73df35275022331156fb45.1464130360.git.luto@kernel.org Signed-off-by: Ingo Molnar arch/x86/kernel/traps.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 280a3efa82fccc9532c968a77e5162cb9f0af497 Author: Johannes Berg Date: Tue Jun 7 14:46:37 2016 +0200 iwlwifi: mvm: fix a few firmware capability checks My cleanup in "iwlwifi: prepare for higher API/CAPA bits" accidentally inverted a few tests - fix them. Fixes: 859d914c8f5c ("iwlwifi: prepare for higher API/CAPA bits") Reported-by: Sara Sharon Signed-off-by: Johannes Berg Signed-off-by: Luca Coelho drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit aa950524d501afa28869b7f56e539fd9e744dd9f Author: Ayala Beker Date: Wed Jun 1 00:28:09 2016 +0300 iwlwifi: mvm: set the encryption type of an IGTK key The FW expect the driver to set the encryption algorithm type when installing the IGTK key in the HW. Currently when installing CMAC IGTK key we don't set the algorithm type and as a result the FW fails to calculate the MIC of multicast management frames. Fix it. Signed-off-by: Ayala Beker Signed-off-by: Luca Coelho drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 1f9788f335d7c3145bcb59bd570c5b9ef7203ef4 Author: Luca Coelho Date: Mon May 16 14:34:20 2016 +0300 iwlwifi: mvm: fix potential NULL-dereference in iwl_mvm_reorder() We try to access sta before we check for IS_ERR_OR_NULL(), so we may end up accessing a NULL pointer. To prevent that, move the conversion from sta to mvm_sta below the check. Fixes: b915c10174fb ("iwlwifi: mvm: add reorder buffer per queue") Reported-by: Dan Carpenter Signed-off-by: Luca Coelho drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 7d6a1ab6a2db180122dee8db6c201f2dcf677813 Author: Emmanuel Grumbach Date: Sun May 15 10:20:29 2016 +0300 iwlwifi: mvm: fix RCU splat in TKIP's update_key The commit below mistakenly changed an rcu_dereference_check to a rcu_dereference_protected which introduced the following RCU warning: [ INFO: suspicious RCU usage. ] 4.6.0-rc7-next-20160513-dbg-00004-g8de8b92-dirty #655 Not tainted ------------------------------- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h:1069 suspicious rcu_dereference_protected() usage! Call Trace: [] lockdep_rcu_suspicious+0xf7/0x100 [] iwl_mvm_get_key_sta.part.0+0x5d/0x80 [iwlmvm] [] iwl_mvm_update_tkip_key+0xd3/0x162 [iwlmvm] [] iwl_mvm_mac_update_tkip_key+0x17/0x19 [iwlmvm] [] ieee80211_tkip_decrypt_data+0x22c/0x24b [mac80211] [] ieee80211_crypto_tkip_decrypt+0xc5/0x110 [mac80211] [] ieee80211_rx_handlers+0x9bb/0x1fe1 [mac80211] Fixes: 13303c0fb148 ("iwlwifi: mvm: use helpers to get iwl_mvm_sta") Reported-by: Sergey Senozhatsky Signed-off-by: Emmanuel Grumbach Signed-off-by: Luca Coelho drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 06a84db74c3572cde79eb1b04f301399eafb8226 Author: Luca Coelho Date: Mon May 2 15:27:34 2016 +0300 iwlwifi: mvm: increase scan timeout to 20 seconds The 16 seconds timeout we were using turned out to be too short. Recalculations by system show that the total time in both bands should be < 18.5 seconds, even in the slowest cases (e.g. DCM P2P with DTIM=2). Rounding it up to 20 seconds for a bit more safety. Fixes: 728e825f81b1 ("iwlwifi: mvm: add a scan timeout for regular scans") Signed-off-by: Luca Coelho drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 07ea0b4d9a0abde8d252738079a8a811c5132a94 Author: Maxime Ripard Date: Sat Apr 2 12:28:31 2016 +0200 clk: sunxi: display: Add per-clock flags The TCON channel 0 clock that is the parent clock of our pixel clock is expected to change its rate depending on the resolution we want to output in our display engine. However, since it's only a mux, the only way it can do that is by changing its parents rate. Allow to give flags in our display clocks description, and add the CLK_SET_RATE_PARENT flag for the TCON channel 0 flag. Fixes: a3b4956ee6d9 ("clk: sunxi: display: Add per-clock flags") Acked-by: Chen-Yu Tsai Signed-off-by: Maxime Ripard drivers/clk/sunxi/clk-sun4i-display.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 4de2d58bc973caa8988b44ddd11787e57051c843 Author: Maxime Ripard Date: Wed May 11 20:57:44 2016 +0200 clk: sunxi: tcon-ch1: Do not return a negative error in get_parent get_parent is supposed to return an unsigned 8 bit integer, so returning -EINVAL is a bad idea. Remove it. Reported-by: Dan Carpenter Acked-by: Chen-Yu Tsai Signed-off-by: Maxime Ripard drivers/clk/sunxi/clk-sun4i-tcon-ch1.c | 3 --- 1 file changed, 3 deletions(-) commit 9ec6de19235889ab0118e970ee732cb33c9efc06 Author: Alexander Yarygin Date: Fri May 6 16:33:06 2016 +0300 KVM: s390: Add stats for PEI events Add partial execution intercepted events in kvm_stats_debugfs. Signed-off-by: Alexander Yarygin Acked-by: Cornelia Huck Reviewed-by: David Hildenbrand Signed-off-by: Christian Borntraeger arch/s390/include/asm/kvm_host.h | 1 + arch/s390/kvm/intercept.c | 2 ++ arch/s390/kvm/kvm-s390.c | 1 + 3 files changed, 4 insertions(+) commit 0487c44d1e1070b636ba3f3a12494ec456c2d005 Author: David Hildenbrand Date: Fri Jun 10 09:22:31 2016 +0200 KVM: s390: ignore IBC if zero Looks like we forgot about the special IBC value of 0 meaning "no IBC". Let's fix that, otherwise it gets rounded up and suddenly an IBC is active with the lowest possible machine. Signed-off-by: David Hildenbrand Reviewed-by: Cornelia Huck Fixes: commit 053dd2308d81 ("KVM: s390: force ibc into valid range") Signed-off-by: Christian Borntraeger arch/s390/kvm/kvm-s390.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 356d27bbfe332de0f2f78e55636e581960c9774e Author: Ville Syrjälä Date: Tue May 31 12:08:34 2016 +0300 drm/i915: Extract physical display dimensions from VBT The VBT has these mysterious H/V image sizes as part of the display timings. Looking at some dumps those appear to be the physical dimensions in mm. Which makes sense since the timing descriptor matches the format used by EDID detailed timing descriptor, which defines these as "H/V Addressable Video Image Size in mm". So let's use that information from the panel fixed mode to get the physical dimensions for LVDS/eDP/DSI displays. And with that we can fill out the display_info so that userspace can get at it via GetConnector. v2: Use (hi<<8)|lo instead of broken (hi<<4)+lo Handle LVDS and eDP too Cc: Stephen Just Tested-by: Stephen Just Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96255 Signed-off-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1464685714-30507-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Mika Kahola (cherry picked from commit df457245b5b7515cf97763ebd8975229e34d4cf3) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_bios.c | 5 +++++ drivers/gpu/drm/i915/intel_dp.c | 5 ++++- drivers/gpu/drm/i915/intel_dsi.c | 3 +++ drivers/gpu/drm/i915/intel_lvds.c | 2 ++ drivers/gpu/drm/i915/intel_vbt_defs.h | 7 ++++--- 5 files changed, 18 insertions(+), 4 deletions(-) commit a5aac5ab876ad95b7f5e8d862afb07248ee9cae2 Author: Ville Syrjälä Date: Fri Jun 3 12:17:43 2016 +0300 drm/i915: Check VBT for port presence in addition to the strap on VLV/CHV Apparently some CHV boards failed to hook up the port presence straps for HDMI ports as well (earlier we assumed this problem only affected eDP ports). So let's check the VBT in addition to the strap, and if either one claims that the port is present go ahead and register the relevant connector. While at it, change port D to register DP before HDMI as we do for ports B and C since commit 457c52d87e5d ("drm/i915: Only ignore eDP ports that are connected") Also print a debug message when we register a HDMI connector to aid in diagnosing missing/incorrect ports. We already had such a print for DP/eDP. v2: Improve the comment in the code a bit, note the port D change in the commit message Cc: Radoslav Duda Tested-by: Radoslav Duda Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96321 Signed-off-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1464945463-14364-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson (cherry picked from commit 22f35042593c2b369861f0b9740efb8065a42db0) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 39 ++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_display.c | 30 ++++++++++++++++++--------- drivers/gpu/drm/i915/intel_hdmi.c | 3 +++ 4 files changed, 64 insertions(+), 9 deletions(-) commit fff7660d1e4f47dc6372ce2bd31a7b8cba0da340 Author: Chris Wilson Date: Wed Jun 1 08:27:50 2016 +0100 drm/i915: Only ignore eDP ports that are connected If the VBT says that a certain port should be eDP (and hence fused off from HDMI), but in reality it isn't, we need to try and acquire the HDMI connection instead. So only trust the VBT edp setting if we can connect to an eDP device on that port. Fixes: d2182a6608 (drm/i915: Don't register HDMI connectors for eDP ports on VLV/CHV) References: https://bugs.freedesktop.org/show_bug.cgi?id=96288 Signed-off-by: Chris Wilson Tested-by: Phidias Chiang Cc: Ville Syrjälä Cc: Jani Nikula Cc: Daniel Vetter Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1464766070-31623-1-git-send-email-chris@chris-wilson.co.uk (cherry picked from commit 457c52d87e5dac9a4cf1a6a287e60ea7645067d4) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_display.c | 20 ++++++++++---------- drivers/gpu/drm/i915/intel_dp.c | 13 ++++++------- drivers/gpu/drm/i915/intel_drv.h | 2 +- 3 files changed, 17 insertions(+), 18 deletions(-) commit 36a5fc5c439c7a95cb9b64414fad4067da6ae3ce Author: Chris Wilson Date: Wed Jun 1 18:08:43 2016 +0100 drm/i915: Silence "unexpected child device config size" for VBT on 845g My old 845g complains that the child_device_size inside its VBT, version 110, is incorrect. Let's fiddle with the version matching such that it works with this VBT (i.e. treat BIOS v110 as having the same size as v108). Fixes [drm:intel_bios_init] *ERROR* Unexpected child device config size 27 (expected 33 for VBT version 110) Whether this is correct, no one knows - but it works for this particular machine. Signed-off-by: Chris Wilson Acked-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1464800923-6054-1-git-send-email-chris@chris-wilson.co.uk (cherry picked from commit fa05178c5dc3d1a3ad370f101cad01cf9dd3bbf9) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_bios.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 50219538ffc0493a2b451a3aa0191138ef8bfe9d Author: Shrikrishna Khare Date: Wed Jun 8 07:40:53 2016 -0700 vmxnet3: segCnt can be 1 for LRO packets The device emulation may send segCnt of 1 for LRO packets. Signed-off-by: Shrikrishna Khare Signed-off-by: Jin Heo Signed-off-by: David S. Miller drivers/net/vmxnet3/vmxnet3_drv.c | 2 +- drivers/net/vmxnet3/vmxnet3_int.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 719c44d340beeecd22cbda91b00ef55585b3c1a0 Author: Willem de Bruijn Date: Tue Jun 7 12:06:34 2016 -0400 packet: compat support for sock_fprog Socket option PACKET_FANOUT_DATA takes a struct sock_fprog as argument if PACKET_FANOUT has mode PACKET_FANOUT_CBPF. This structure contains a pointer into user memory. If userland is 32-bit and kernel is 64-bit the two disagree about the layout of struct sock_fprog. Add compat setsockopt support to convert a 32-bit compat_sock_fprog to a 64-bit sock_fprog. This is analogous to compat_sock_fprog support for SO_REUSEPORT added in commit 1957598840f4 ("soreuseport: add compat case for setsockopt SO_ATTACH_REUSEPORT_CBPF"). Reported-by: Daniel Borkmann Signed-off-by: Willem de Bruijn Acked-by: Daniel Borkmann Signed-off-by: David S. Miller include/net/compat.h | 1 + net/compat.c | 17 +++++++++++++++-- net/packet/af_packet.c | 25 +++++++++++++++++++++++++ 3 files changed, 41 insertions(+), 2 deletions(-) commit ca8bdaf13abbdcbb12ff12164aa2d5b522ec524d Author: Ben Dooks Date: Wed Jun 8 19:21:17 2016 +0100 stmmac: fix parameter to dwmac4_set_umac_addr() The dwmac4_set_umac_addr() takes a struct mac_device_info as the first parameter, but is being passed a ioaddr instead from dwmac4_set_filter(). Fix the warning/bug by changing the first parameter. drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c:159:46: warning: incorrect type in argument 1 (different address spaces) drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c:159:46: expected struct mac_device_info *hw drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c:159:46: got void [noderef] *ioaddr Note, only compile tested this as do not have any hardware with it in. Signed-off-by: Ben Dooks Acked-by: Giuseppe Cavallaro Signed-off-by: David S. Miller drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 143aaef8aae2b53a5ab2d0e9d48c4ff368e82b16 Author: Ander Conselvan de Oliveira Date: Fri May 20 15:47:06 2016 +0300 drm/i915: Fix NULL pointer deference when out of PLLs in IVB In commit f9476a6c6d0c ("drm/i915: Refactor platform specifics out of intel_get_shared_dpll()"), the ibx_get_dpll() function lacked an error check, that can lead to a NULL pointer dereference when trying to enable three pipes. BUG: unable to handle kernel NULL pointer dereference at 0000000000000068 IP: [] intel_reference_shared_dpll+0x15/0x100 [i915] PGD cec87067 PUD d30ce067 PMD 0 Oops: 0000 [#1] PREEMPT SMP Modules linked in: snd_hda_intel i915 drm_kms_helper drm intel_gtt sch_fq_codel cfg80211 binfmt_misc i2c_algo_bit cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops cfbcopyarea intel_rapl iosf_mbi x86_pkg_temp_thermal coretemp agpgart kvm_intel snd_hda_codec_hdmi kvm iTCO_wdt snd_hda_codec_realtek snd_hda_codec_generic irqbypass aesni_intel aes_x86_64 glue_helper lrw gf128mul ablk_helper cryptd psmouse pcspkr snd_hda_codec i2c_i801 snd_hwdep snd_hda_core snd_pcm snd_timer lpc_ich mfd_core snd soundcore wmi evdev tpm_tis tpm [last unloaded: drm] CPU: 3 PID: 5810 Comm: kms_flip Tainted: G U W 4.6.0-test+ #3 Hardware name: /DZ77BH-55K, BIOS BHZ7710H.86A.0100.2013.0517.0942 05/17/2013 task: ffff8800d3908040 ti: ffff8801166c8000 task.ti: ffff8801166c8000 RIP: 0010:[] [] intel_reference_shared_dpll+0x15/0x100 [i915] RSP: 0018:ffff8801166cba60 EFLAGS: 00010246 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000002 RDX: 0000000000000001 RSI: ffff8800d07f1bf8 RDI: 0000000000000000 RBP: ffff8801166cba88 R08: 0000000000000002 R09: ffff8800d32e5698 R10: 0000000000000001 R11: ffff8800cc89ac88 R12: ffff8800d07f1bf8 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 FS: 00007f4c3fc8d8c0(0000) GS:ffff88011bcc0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000068 CR3: 00000000d3b4c000 CR4: 00000000001406e0 Stack: 0000000000000000 ffff8800d07f1bf8 0000000000000000 ffff8800d04c0000 0000000000000000 ffff8801166cbaa8 ffffffffa04823a7 ffff8800d07f1bf8 ffff8800d32e5698 ffff8801166cbab8 ffffffffa04840cf ffff8801166cbaf0 Call Trace: [] ibx_get_dpll+0x47/0xa0 [i915] [] intel_get_shared_dpll+0x1f/0x50 [i915] [] ironlake_crtc_compute_clock+0x280/0x430 [i915] [] intel_crtc_atomic_check+0x240/0x320 [i915] [] drm_atomic_helper_check_planes+0x14e/0x1d0 [drm_kms_helper] [] intel_atomic_check+0x5dc/0x1110 [i915] [] drm_atomic_check_only+0x14a/0x660 [drm] [] ? drm_atomic_set_crtc_for_connector+0x96/0x100 [drm] [] drm_atomic_commit+0x17/0x60 [drm] [] restore_fbdev_mode+0x237/0x260 [drm_kms_helper] [] ? drm_modeset_lock_all_ctx+0x9a/0xb0 [drm] [] drm_fb_helper_restore_fbdev_mode_unlocked+0x33/0x80 [drm_kms_helper] [] drm_fb_helper_set_par+0x2d/0x50 [drm_kms_helper] [] drm_fb_helper_hotplug_event+0xaa/0xf0 [drm_kms_helper] [] drm_fb_helper_restore_fbdev_mode_unlocked+0x56/0x80 [drm_kms_helper] [] intel_fbdev_restore_mode+0x22/0x80 [i915] [] i915_driver_lastclose+0xe/0x20 [i915] [] drm_lastclose+0x2e/0x130 [drm] [] drm_release+0x2ac/0x4b0 [drm] [] __fput+0xed/0x1f0 [] ____fput+0xe/0x10 [] task_work_run+0x76/0xb0 [] do_exit+0x3ab/0xc60 [] ? trace_hardirqs_on_caller+0x12f/0x1c0 [] do_group_exit+0x4e/0xc0 [] SyS_exit_group+0x14/0x20 [] entry_SYSCALL_64_fastpath+0x18/0xa8 Code: 14 80 48 8d 34 90 b8 01 00 00 00 d3 e0 09 04 b3 5b 41 5c 5d c3 90 0f 1f 44 00 00 55 48 89 e5 41 57 41 56 49 89 fe 41 55 41 54 53 <44> 8b 67 68 48 89 f3 48 8b be 08 02 00 00 4c 8b 2e e8 15 9d fd RIP [] intel_reference_shared_dpll+0x15/0x100 [i915] RSP CR2: 0000000000000068 Cc: Ville Syrjälä Cc: drm-intel-fixes@lists.freedesktop.org Reported-by: Ville Syrjälä Fixes: f9476a6c6d0c ("drm/i915: Refactor platform specifics out of intel_get_shared_dpll()") Signed-off-by: Ander Conselvan de Oliveira Reviewed-by: Ville Syrjälä Tested-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1463748426-5956-1-git-send-email-ander.conselvan.de.oliveira@intel.com (cherry picked from commit bb143165510661feda06fd99298b8b3a94af3046) Signed-off-by: Jani Nikula drivers/gpu/drm/i915/intel_dpll_mgr.c | 3 +++ 1 file changed, 3 insertions(+) commit a145abf12c9f7d30d8c330c9d8a97428cbf0589b Author: Aneesh Kumar K.V Date: Wed Jun 8 19:55:51 2016 +0530 powerpc/mm/radix: Flush page walk cache when freeing page table Even though a tlb_flush() does a flush with invalidate all cache, we can end up doing an RCU page table free before calling tlb_flush(). That means we can have page walk cache entries even after we free the page table pages. This can result in us doing wrong page table walk. Avoid this by doing pwc flush on every page table free. We can't batch the pwc flush, because the rcu call back function where we free the page table pages doesn't have information of the mmu gather. Thus we have to do a pwc on every page table page freed. Note: I also removed the dummy tlb_flush_pgtable call functions for hash 32. Fixes: 1a472c9dba6b ("powerpc/mm/radix: Add tlbflush routines") Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/include/asm/book3s/32/pgalloc.h | 1 - arch/powerpc/include/asm/book3s/64/pgalloc.h | 16 ++++++++- .../powerpc/include/asm/book3s/64/tlbflush-radix.h | 3 ++ arch/powerpc/include/asm/book3s/64/tlbflush.h | 14 ++++++++ arch/powerpc/include/asm/book3s/pgalloc.h | 5 --- arch/powerpc/mm/tlb-radix.c | 41 ++++++++++++++++++++++ 6 files changed, 73 insertions(+), 7 deletions(-) commit 36194812a4063dd2a72070aec3ee7890d135a587 Author: Aneesh Kumar K.V Date: Wed Jun 8 19:55:50 2016 +0530 powerpc/mm/radix: Update to tlb functions ric argument Radix invalidate control (RIC) is used to control which cache to flush using tlb instructions. When doing a PID flush, we currently flush everything including page walk cache. For address range flush, we flush only the TLB. In the next patch, we add support for flushing only the page walk cache. Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/mm/tlb-radix.c | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) commit 8618e6e79d10863a643101a5d1008d1536ce14b7 Merge: e71ba91 0ca00fc Author: David S. Miller Date: Thu Jun 9 22:06:27 2016 -0700 Merge branch 'mlx5-fixes' Saeed Mahameed says: ==================== Mellanox 100G mlx5 fixes for 4.7-rc The following series provides some small fixes for mlx5 driver. Two small fixes for the mlx5e netdev, the 1st is for the blue flame quota accounting and the 2nd is a small refactoring in shutdown flow. Five trivial fixes for mlx5 E-Switch. - Allmulti mc_promisc flag was not set in a specific flow. - Modify VF node guid when admin mac is changed. - Race in vport enable flow. - Misc code fixes (kvfree when needed and error pointers checking). Three in mlx5 steering area. Correct capabilities checking and root flow table update. Three misc fixes in mlx5 commands enum and layouts. ==================== Signed-off-by: David S. Miller commit 0ca00fc1f808602137dc6d51f17747b3bb0fc34d Author: Eli Cohen Date: Fri Jun 10 00:07:40 2016 +0300 net/mlx5e: Fix blue flame quota logic Blue flame is a latency enhancement feature that allows the driver to write the packet data directly to the NIC's registers thus making the read of the packet data from host memory redundant. We maintain a quota for the blue flame which is reloaded whenever we identify that the hardware is processing send requests and processes them fast enough so by the time we post the next send request it was able to process all the pending ones. This indicates that the hardware is capable of processing more blue flame requests efficiently. The blue flame quota is decremented whenever we send using blue flame. The current code erroneously clears the budget if we did not use blue flame for the current post send operation and we fix it here. Fixes: 88a85f99e51f ('net/mlx5e: TX latency optimization to save DMA reads') Signed-off-by: Eli Cohen Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 811afeaa3797bdf4eabed286100811b33005c9e0 Author: Eran Ben Elisha Date: Fri Jun 10 00:07:39 2016 +0300 net/mlx5e: Use ndo_stop explicitly at shutdown flow The current implementation copies the flow of ndo_stop instead of calling it explicitly, Fixed it. Fixes: 5fc7197d3a25 ("net/mlx5: Add pci shutdown callback") Signed-off-by: Eran Ben Elisha Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 62e3c24ac4f0ee307c41a3652636f88a3f8d165c Author: Mohamad Haj Yahia Date: Fri Jun 10 00:07:38 2016 +0300 net/mlx5: E-Switch, always set mc_promisc for allmulti vports Set the mc_promisc flag also in the case of adding new mc address to existing allmulti vport. Fixes: a35f71f27a61 ('net/mlx5: E-Switch, Implement promiscuous rx modes vf request handling') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 1 + 1 file changed, 1 insertion(+) commit 23898c763f4af6f5c80b0230b1ea788a0ce3cf73 Author: Noa Osherovich Date: Fri Jun 10 00:07:37 2016 +0300 net/mlx5: E-Switch, Modify node guid on vf set MAC In RoCE, the RDMA-CM needs the node guid to establish connection between nodes. Today, the node guid exposed to mlx5 Ethernet VFs is zero, therefore RDMA-CM on the VF is broken. Whenever the administrator sets a MAC for a VF, derive the node guid from it and set it as well in the following way: MAC: e4:1d:2d:b3:f4:01 -> node_guid: e4:1d:2d:ff:fe:b3:f4:01 Fixes: 77256579c6b43 ('net/mlx5: E-Switch, Introduce Vport...') Signed-off-by: Noa Osherovich Signed-off-by: Majd Dibbiny Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 23 ++++++++++++-- drivers/net/ethernet/mellanox/mlx5/core/vport.c | 38 +++++++++++++++++++++++ include/linux/mlx5/mlx5_ifc.h | 9 ++++-- include/linux/mlx5/vport.h | 2 ++ 4 files changed, 68 insertions(+), 4 deletions(-) commit 25fff58cb24c8880090d8b8ef7746001a135e876 Author: Mohamad Haj Yahia Date: Fri Jun 10 00:07:36 2016 +0300 net/mlx5: E-Switch, Fix vport enable flow Reorder vport enable flow to mark the vport as enabled before calling the vport change handler which was modified to handle the case for when vport is not enabled. This fixes the case for when the PF netdev is open before sriov is enabled, once sriov is enabled at esw_enable_vport, esw_vport_change_handle_locked didn't read the PF context since it thought the PF vport was not enabled. When we enable the vport, arming for events is not required anymore, since it's done on the vport change handle Fixes: 586cfa7f1d58 ('net/mlx5: E-Switch, Use vport event handler for vport cleanup') Signed-off-by: Mohamad Haj Yahia Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 3f42ac6648723e906c1c10edc0c523aff29963cc Author: Or Gerlitz Date: Fri Jun 10 00:07:35 2016 +0300 net/mlx5: E-Switch, Use the correct error check on returned pointers The mlx5 flow-steering API (mlx5_create_flow_table/group/rule) never returns null pointer on error. Even if it was doing that, checking for IS_ERR_OR_NULL(p) and then returning PTR_ERR(p) would have cause bugs, since PTR_ERR(NULL) --> success, crash. To make things more robust and protect against related future bugs, convert all IS_ERR_OR_NULL checks on returned values to IS_ERR. Fixes: 5742df0f7dbe ('net/mlx5: E-Switch, Introduce VST vport ingress/egress ACLs') Fixes: 86d722ad2c3b ('net/mlx5: Use flow steering infrastructure for mlx5_en') Signed-off-by: Or Gerlitz Reported-by: Ilya Lesokhin Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 34 +++++++++++------------ 1 file changed, 17 insertions(+), 17 deletions(-) commit 3fe3d819d5015d56d0d7289ae16db5e612640c5b Author: Or Gerlitz Date: Fri Jun 10 00:07:34 2016 +0300 net/mlx5: E-Switch, Use the correct free() function We must use kvfree() for something that could have been allocated with vzalloc(), do that. Fixes: 5742df0f7dbe ('net/mlx5: E-Switch, Introduce VST vport ingress/egress ACLs') Fixes: 86d722ad2c3b ('net/mlx5: Use flow steering infrastructure for mlx5_en') Signed-off-by: Or Gerlitz Reported-by: Ilya Lesokhin Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit bd02ef8eec0b98abe6d5efe280c87903b2eb9874 Author: Maor Gottlieb Date: Fri Jun 10 00:07:33 2016 +0300 net/mlx5: Fix E-Switch flow steering capabilities check Add missing capabilities check for E-Switch FDB and ACLs flow tables before creating their namespace in flow steering. Fixes: efdc810ba39d ('net/mlx5: Flow steering, Add vport ACL support') Signed-off-by: Maor Gottlieb Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 28 ++++++++++++----------- 1 file changed, 15 insertions(+), 13 deletions(-) commit 876d634d19e41603aab91455f2c52a78a28372d5 Author: Maor Gottlieb Date: Fri Jun 10 00:07:32 2016 +0300 net/mlx5: Fix flow steering NIC capabilities check Flow steering infrastructure is currently used only on link layer ethernet, therefore the driver should initialize the flow steering when the device link layer is ethernet. In addition, add missing capability check before initializing the namespace of NIC RX flow tables. Fixes: 2530236303d9 ('net/mlx5_core: Flow steering tree initialization') Signed-off-by: Maor Gottlieb Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 10 +++++++++- include/linux/mlx5/device.h | 6 ++++++ 2 files changed, 15 insertions(+), 1 deletion(-) commit 2fee37a47cebc26d58eec5dafc8ba787a6ee5350 Author: Maor Gottlieb Date: Fri Jun 10 00:07:31 2016 +0300 net/mlx5: Fix root flow table update When we destroy the last flow table we need to update the root_ft to NULL. It fixes an issue for when the last flow table is destroyed and recreated again, root_ft pointer will not be updated, as a result traffic will be dropped. Fixes: 2cc43b494a6c ('net/mlx5_core: Managing root flow table') Signed-off-by: Maor Gottlieb Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 86d56a1a6b7352542661d8a9463758c7f285fce3 Author: Shahar Klein Date: Fri Jun 10 00:07:30 2016 +0300 net/mlx5: Fix MLX5_CMD_OP_MAX to be defined correctly Having MLX5_CMD_OP_MAX on another file causes us to repeatedly miss accounting new commands added to the driver and hence there're no entries for them in debugfs. To solve that, we integrate it into the commands enum as the last entry. Fixes: 34a40e689393 ('net/mlx5_core: Introduce modify flow table command') Signed-off-by: Shahar Klein Signed-off-by: Or Gerlitz Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller include/linux/mlx5/device.h | 2 -- include/linux/mlx5/mlx5_ifc.h | 3 ++- 2 files changed, 2 insertions(+), 3 deletions(-) commit 9cd3411c42c5d5ba55d6e745edfe7df53c1ffa41 Author: Majd Dibbiny Date: Fri Jun 10 00:07:29 2016 +0300 net/mlx5: Fix masking of reserved bits in XRCD number Mask the reserved bits when reading the number of newly created XRCD. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB adapters') Signed-off-by: Majd Dibbiny Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlx5/core/qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 418f8399a8bedf376ec13eb01088f04a76ebdd6f Author: Majd Dibbiny Date: Fri Jun 10 00:07:28 2016 +0300 net/mlx5: Fix the size of modify QP mailbox Add 16 reserved bytes at the end of mlx5_modify_qp_mbox_in to match the hardware spec definition. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB adapters') Signed-off-by: Majd Dibbiny Signed-off-by: Saeed Mahameed Signed-off-by: David S. Miller include/linux/mlx5/qp.h | 1 + 1 file changed, 1 insertion(+) commit 8017ea35d33f9e0950d369773ab48bcb1efb9ba0 Author: Michael Ellerman Date: Wed Jun 8 21:50:50 2016 +1000 powerpc/nohash: Fix build break with 64K pages Commit 74701d5947a6 "powerpc/mm: Rename function to indicate we are allocating fragments" renamed page_table_free() to pte_fragment_free(). One occurrence was mistyped as pte_fragment_fre(). This only breaks the nohash 64K page build, which is not the default or enabled in any defconfig. Fixes: 74701d5947a6 ("powerpc/mm: Rename function to indicate we are allocating fragments") Signed-off-by: Michael Ellerman arch/powerpc/include/asm/nohash/64/pgalloc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7ff6977be8e3c7e6f5ae1ee56bc1535c5ca653b1 Merge: 29ccf75 ce492b3 Author: Dave Airlie Date: Fri Jun 10 12:17:46 2016 +1000 Merge branch 'fixes-for-v4.7-rc3' of http://git.agner.ch/git/linux-drm-fsl-dcu into drm-fixes * 'fixes-for-v4.7-rc3' of http://git.agner.ch/git/linux-drm-fsl-dcu: drm/fsl-dcu: use flat regmap cache commit 29ccf7590ec49647b3442b6b2c64c4406a931c80 Author: Dave Airlie Date: Fri Jun 10 11:40:49 2016 +1000 drm/amdgpu: fix warning with powerplay disabled. This just fixes a warning when you disable powerplay. Signed-off-by: Dave Airlie drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a9cc4006155a68dd0940728f4f222dd035180904 Author: Doug Oucharek Date: Thu Jun 9 18:45:45 2016 -0400 staging: lustre: lnet: Don't access NULL NI on failure path In kiblnd_passive_connect(), if we are failing the connection attempt because we cannot find a valid NI (we have a NULL NI), we were coring after the "goto fail" because the failure path was assuming non-NULL NI. This patch ensures we don't dereference a NULL NI on that failure path. Signed-off-by: Doug Oucharek Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-8022 Reviewed-on: http://review.whamcloud.com/19614 Reviewed-by: Dmitry Eremin Reviewed-by: James Simmons Reviewed-by: Matt Ezell Reviewed-by: Oleg Drokin Signed-off-by: Greg Kroah-Hartman drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit fa6bcad781c165b8f3ec70f481dac48f1267da71 Merge: 166108a 5f96ddb Author: Dave Airlie Date: Fri Jun 10 09:46:59 2016 +1000 Merge branch 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-fixes Mostly memory leak and firmware leak fixes for amdgpu. A bit bigger than usual since this is several weeks worth of fixes. * 'drm-fixes-4.7' of git://people.freedesktop.org/~agd5f/linux: (28 commits) drm/amd/powerplay: delete useless code as pptable changed in vbios. drm/amd/powerplay: fix bug visit array out of bounds drm/amdgpu: fix smu ucode memleak (v2) drm/amdgpu: add release firmware for cgs drm/amdgpu: fix tonga smu_fini mem leak drm/amdgpu: fix fiji smu fini mem leak drm/amdgpu: fix cik sdma ucode memleak drm/amdgpu: fix sdma24 ucode mem leak drm/amdgpu: fix sdma3 ucode mem leak drm/amdgpu: fix uvd fini mem leak drm/amdgpu: fix gfx 7 ucode mem leak drm/amdgpu: fix gfx8 ucode mem leak drm/amdgpu: fix missing free wb for cond_exec drm/amdgpu: fix memleak in pptable_init drm/amdgpu: fix mem leak in atombios drm/amdgpu: fix mem leak in pplib/hwmgr drm/amdgpu: fix mem leak in smumgr drm/amdgpu: add pipeline sync while vmid switch in same ctx drm/amdgpu: vBIOS post only call when mem_size zero drm/amdgpu: modify sdma start sequence ... commit 166108aa263013d3b9965793dcdc97f374ed73ac Merge: 170fba3 a9e26ca Author: Dave Airlie Date: Fri Jun 10 09:45:42 2016 +1000 Merge branch 'msm-fixes-4.7-rc3' of git://people.freedesktop.org/~robclark/linux into drm-fixes * 'msm-fixes-4.7-rc3' of git://people.freedesktop.org/~robclark/linux: drm/msm: fix potential submit error path issue drm/msm: fix some crashes in submit fail path drm/msm: deal with exhausted vmap space better commit 3681196ae568f97d534537c1c1102f4707ca11f9 Merge: af8c34c 983e600 9bd616e Author: Rafael J. Wysocki Date: Thu Jun 9 23:49:16 2016 +0200 Merge branches 'pm-cpufreq-fixes' and 'pm-cpuidle' * pm-cpufreq-fixes: cpufreq: intel_pstate: Fix ->set_policy() interface for no_turbo cpufreq: intel_pstate: Fix code ordering in intel_pstate_set_policy() * pm-cpuidle: cpuidle: Do not access cpuidle_devices when !CONFIG_CPU_IDLE commit bd6ac2abc9937eb7613aa194195fd98fe9312b38 Merge: af8c34c dcf15cb Author: Rafael J. Wysocki Date: Thu Jun 9 23:48:54 2016 +0200 Merge branch 'acpi-ec' * acpi-ec: ACPI / EC: Fix a boot EC regresion by restoring boot EC support for the DSDT EC commit 147d9e7bcad3b8d5465f6eea6292731e7f35dee8 Merge: 52e7d46 61c78eea Author: Linus Torvalds Date: Thu Jun 9 14:36:12 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma Pull rdma fixes from Doug Ledford: "This is the first -rc pull for the RDMA subsystem. The patch count is high, but they are all smallish patches fixing simple things for the most part, and the overall line count of changes here is smaller than the patch count would lead a person to believe. Code is up and running in my labs, including direct testing of cxgb4, mlx4, mlx5, ocrdma, and qib. Summary: - Multiple minor fixes to the rdma core - Multiple minor fixes to hfi1 - Multiple minor fixes to mlx5 - A very few other minor fixes (SRP, IPoIB, usNIC, mlx4)" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: (35 commits) IB/IPoIB: Don't update neigh validity for unresolved entries IB/mlx5: Fix alternate path code IB/mlx5: Fix pkey_index length in the QP path record IB/mlx5: Fix entries check in mlx5_ib_resize_cq IB/mlx5: Fix entries checks in mlx5_ib_create_cq IB/mlx5: Check BlueFlame HCA support IB/mlx5: Fix returned values of query QP IB/mlx5: Limit query HCA clock IB/mlx5: Fix FW version diaplay in sysfs IB/mlx5: Return PORT_ERR in Active to Initializing tranisition IB/mlx5: Set flow steering capability bit IB/core: Make all casts in ib_device_cap_flags enum consistent IB/core: Fix bit curruption in ib_device_cap_flags structure IB/core: Initialize sysfs attributes before sysfs create group IB/IPoIB: Disable bottom half when dealing with device address IB/core: Fix removal of default GID cache entry IB/IPoIB: Fix race between ipoib_remove_one to sysfs functions IB/core: Fix query port failure in RoCE IB/core: fix error unwind in sysfs hw counters code IB/core: Fix array length allocation ... commit 52e7d46c642ae7762b44cc3203a816ebaa4b6b8b Merge: c8ae067 ed6aefe Author: Linus Torvalds Date: Thu Jun 9 14:28:39 2016 -0700 Merge tag 'arc-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc Pull ARC fixes from Vineet Gupta: - Revert of ll-sc backoff retry workaround in atomics/spinlocks as hardware is now proven to work just fine - Typo fixes (Thanks Andrea Gelmini) - Removal of obsolete DT property (Alexey) - Other minor fixes * tag 'arc-4.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc: Revert "ARCv2: spinlock/rwlock/atomics: Delayed retry of failed SCOND with exponential backoff" Revert "ARCv2: spinlock/rwlock: Reset retry delay when starting a new spin-wait cycle" Revert "ARCv2: spinlock/rwlock/atomics: reduce 1 instruction in exponential backoff" ARC: don't enable DISCONTIGMEM unconditionally ARC: [intc-compact] simplify code for 2 priority levels arc: Get rid of root core-frequency property Fix typos commit 18aba41cbfbcd138e9f6d8d446427d8b7691c194 Author: Oleg Drokin Date: Wed Jun 8 15:33:59 2016 -0700 mm/fadvise.c: do not discard partial pages with POSIX_FADV_DONTNEED I noticed that the logic in the fadvise64_64 syscall is incorrect for partial pages. While first page of the region is correctly skipped if it is partial, the last page of the region is mistakenly discarded. This leads to problems for applications that read data in non-page-aligned chunks discarding already processed data between the reads. A somewhat misguided application that does something like write(XX bytes (non-page-alligned)); drop the data it just wrote; repeat gets a significant penalty in performance as a result. Link: http://lkml.kernel.org/r/1464917140-1506698-1-git-send-email-green@linuxhacker.ru Signed-off-by: Oleg Drokin Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/fadvise.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit f3a932baa7f65072434f1c04c02c8a4d2746fcfc Author: Wang Sheng-Hui Date: Wed Jun 8 15:33:56 2016 -0700 mm: introduce dedicated WQ_MEM_RECLAIM workqueue to do lru_add_drain_all This patch is based on https://patchwork.ozlabs.org/patch/574623/. Tejun submitted commit 23d11a58a9a6 ("workqueue: skip flush dependency checks for legacy workqueues") for the legacy create*_workqueue() interface. But some workq created by alloc_workqueue still reports warning on memory reclaim, e.g nvme_workq with flag WQ_MEM_RECLAIM set: workqueue: WQ_MEM_RECLAIM nvme:nvme_reset_work is flushing !WQ_MEM_RECLAIM events:lru_add_drain_per_cpu ------------[ cut here ]------------ WARNING: CPU: 0 PID: 6 at SoC/linux/kernel/workqueue.c:2448 check_flush_dependency+0xb4/0x10c ... check_flush_dependency+0xb4/0x10c flush_work+0x54/0x140 lru_add_drain_all+0x138/0x188 migrate_prep+0xc/0x18 alloc_contig_range+0xf4/0x350 cma_alloc+0xec/0x1e4 dma_alloc_from_contiguous+0x38/0x40 __dma_alloc+0x74/0x25c nvme_alloc_queue+0xcc/0x36c nvme_reset_work+0x5c4/0xda8 process_one_work+0x128/0x2ec worker_thread+0x58/0x434 kthread+0xd4/0xe8 ret_from_fork+0x10/0x50 That's because lru_add_drain_all() will schedule the drain work on system_wq, whose flag is set to 0, !WQ_MEM_RECLAIM. Introduce a dedicated WQ_MEM_RECLAIM workqueue to do lru_add_drain_all(), aiding in getting memory freed. Link: http://lkml.kernel.org/r/1464917521-9775-1-git-send-email-shhuiw@foxmail.com Signed-off-by: Wang Sheng-Hui Acked-by: Tejun Heo Cc: Keith Busch Cc: Peter Zijlstra Cc: Thierry Reding Cc: Ingo Molnar Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/swap.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit ba62bafe942b159a6109cbec780d36496e06b6c5 Author: Zhouyi Zhou Date: Wed Jun 8 15:33:53 2016 -0700 kernel/relay.c: fix potential memory leak When relay_open_buf() fails in relay_open(), code will goto free_bufs, but chan is nowhere freed. Link: http://lkml.kernel.org/r/1464777927-19675-1-git-send-email-yizhouzhou@ict.ac.cn Signed-off-by: Zhouyi Zhou Cc: Jens Axboe Cc: Al Viro Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds kernel/relay.c | 1 + 1 file changed, 1 insertion(+) commit 770a5370226cb207461bbad902543381c1fad521 Author: Gerald Schaefer Date: Wed Jun 8 15:33:50 2016 -0700 mm: thp: broken page count after commit aa88b68c3b1d Christian Borntraeger reported a kernel panic after corrupt page counts, and it turned out to be a regression introduced with commit aa88b68c3b1d ("thp: keep huge zero page pinned until tlb flush"), at least on s390. put_huge_zero_page() was moved over from zap_huge_pmd() to release_pages(), and it was replaced by tlb_remove_page(). However, release_pages() might not always be triggered by (the arch-specific) tlb_remove_page(). On s390 we call free_page_and_swap_cache() from tlb_remove_page(), and not tlb_flush_mmu() -> free_pages_and_swap_cache() like the generic version, because we don't use the MMU-gather logic. Although both functions have very similar names, they are doing very unsimilar things, in particular free_page_xxx is just doing a put_page(), while free_pages_xxx calls release_pages(). This of course results in very harmful put_page()s on the huge zero page, on architectures where tlb_remove_page() is implemented in this way. It seems to affect only s390 and sh, but sh doesn't have THP support, so the problem (currently) probably only exists on s390. The following quick hack fixed the issue: Link: http://lkml.kernel.org/r/20160602172141.75c006a9@thinkpad Signed-off-by: Gerald Schaefer Reported-by: Christian Borntraeger Tested-by: Christian Borntraeger Cc: "Kirill A. Shutemov" Cc: Andrea Arcangeli Cc: "Aneesh Kumar K.V" Cc: Mel Gorman Cc: Hugh Dickins Cc: Johannes Weiner Cc: Dave Hansen Cc: Vlastimil Babka Cc: Martin Schwidefsky Cc: Heiko Carstens Cc: [4.6.x] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/swap_state.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit d0db7afa1b767d95e3e14632718da5a9794129bc Author: Andrew Morton Date: Wed Jun 8 15:33:47 2016 -0700 revert "mm: memcontrol: fix possible css ref leak on oom" Revert commit 1383399d7be0 ("mm: memcontrol: fix possible css ref leak on oom"). Johannes points out "There is a task_in_memcg_oom() check before calling mem_cgroup_oom()". Acked-by: Michal Hocko Cc: Johannes Weiner Cc: Vladimir Davydov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/memcontrol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 91a4c272145652d798035c17e1c02c91001d3f51 Author: Shuah Khan Date: Wed Jun 8 15:33:45 2016 -0700 kasan: change memory hot-add error messages to info messages Change the following memory hot-add error messages to info messages. There is no need for these to be errors. kasan: WARNING: KASAN doesn't support memory hot-add kasan: Memory hot-add will be disabled Link: http://lkml.kernel.org/r/1464794430-5486-1-git-send-email-shuahkh@osg.samsung.com Signed-off-by: Shuah Khan Acked-by: Andrey Ryabinin Cc: Alexander Potapenko Cc: Dmitry Vyukov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/kasan/kasan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 67961f9db8c477026ea20ce05761bde6f8bf85b0 Author: Mike Kravetz Date: Wed Jun 8 15:33:42 2016 -0700 mm/hugetlb: fix huge page reserve accounting for private mappings When creating a private mapping of a hugetlbfs file, it is possible to unmap pages via ftruncate or fallocate hole punch. If subsequent faults repopulate these mappings, the reserve counts will go negative. This is because the code currently assumes all faults to private mappings will consume reserves. The problem can be recreated as follows: - mmap(MAP_PRIVATE) a file in hugetlbfs filesystem - write fault in pages in the mapping - fallocate(FALLOC_FL_PUNCH_HOLE) some pages in the mapping - write fault in pages in the hole This will result in negative huge page reserve counts and negative subpool usage counts for the hugetlbfs. Note that this can also be recreated with ftruncate, but fallocate is more straight forward. This patch modifies the routines vma_needs_reserves and vma_has_reserves to examine the reserve map associated with private mappings similar to that for shared mappings. However, the reserve map semantics for private and shared mappings are very different. This results in subtly different code that is explained in the comments. Link: http://lkml.kernel.org/r/1464720957-15698-1-git-send-email-mike.kravetz@oracle.com Signed-off-by: Mike Kravetz Acked-by: Hillf Danton Cc: Dave Hansen Cc: Kirill Shutemov Cc: Michal Hocko Cc: Naoya Horiguchi Cc: Aneesh Kumar Cc: Joonsoo Kim Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/hugetlb.c | 42 ++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 40 insertions(+), 2 deletions(-) commit 9f05e6219023116b59f6495e8c4d4ba352dd5fea Author: Lukasz Gemborowski Date: Mon Jun 6 15:51:50 2016 +0200 i2c: mux: reg: Provide of_match_table of_match_table was not filled which prevents device to be instantiated from device tree node. Signed-off-by: Lukasz Gemborowski Reviewed-by: Alexander Sverdlin Signed-off-by: Wolfram Sang drivers/i2c/muxes/i2c-mux-reg.c | 1 + 1 file changed, 1 insertion(+) commit 2e9328493f89a5a06ea0ecb0b7763d61930a682a Author: Simon Horman Date: Wed Jun 8 15:21:39 2016 +0900 i2c: mux: refer to i2c-mux.txt Correct references to i2c-mux.txt which was previously mux.txt. Also correct the spelling of relevant. Signed-off-by: Simon Horman Acked-by: Peter Rosin Signed-off-by: Wolfram Sang Documentation/devicetree/bindings/i2c/i2c-arb-gpio-challenge.txt | 4 ++-- Documentation/devicetree/bindings/i2c/i2c-demux-pinctrl.txt | 3 ++- Documentation/devicetree/bindings/i2c/i2c-mux-gpio.txt | 6 +++--- Documentation/devicetree/bindings/i2c/i2c-mux-pinctrl.txt | 4 ++-- Documentation/devicetree/bindings/i2c/i2c-mux-reg.txt | 6 +++--- 5 files changed, 12 insertions(+), 11 deletions(-) commit edb50a5403d2e2d2b2b63a8365c4378c9c300ed6 Author: Johannes Thumshirn Date: Tue May 10 15:14:28 2016 +0200 NVMe: Only release requested regions The NVMe driver only requests the PCIe device's memory regions but releases all possible regions (including eventual I/O regions). This leads to a stale warning entry in dmesg about freeing non existent resources. Signed-off-by: Johannes Thumshirn Signed-off-by: Jens Axboe drivers/nvme/host/pci.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 8913f8d2930368f30998e60851259606eeed2c49 Author: Jan Glauber Date: Wed Jun 8 08:51:19 2016 +0200 i2c: octeon: Avoid printk after too long SMBUS message Remove the warning about a too long SMBUS message because the ipmi_ssif driver triggers this warning too frequently so it spams the message log. Signed-off-by: Jan Glauber Signed-off-by: Wolfram Sang drivers/i2c/busses/i2c-octeon.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 908cf12bbca0f18a23085a5a35301509e034f0a9 Author: Jan Glauber Date: Wed Jun 8 08:51:17 2016 +0200 i2c: octeon: Missing AAK flag in case of I2C_M_RECV_LEN During receive the controller requires the AAK flag for all bytes but the final one. This was wrong in case of I2C_M_RECV_LEN, where the decision if the final byte is to be transmitted happened before adding the additional received length byte. Set the AAK flag if additional bytes are to be received. Signed-off-by: Jan Glauber Signed-off-by: Wolfram Sang drivers/i2c/busses/i2c-octeon.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit a7ae81952cdab56a1277bd2f9ed7284c0f575120 Author: Mika Westerberg Date: Thu Jun 9 16:56:28 2016 +0300 i2c: i801: Allow ACPI SystemIO OpRegion to conflict with PCI BAR Many Intel systems the BIOS declares a SystemIO OpRegion below the SMBus PCI device as can be seen in ACPI DSDT table from Lenovo Yoga 900: Device (SBUS) { OperationRegion (SMBI, SystemIO, (SBAR << 0x05), 0x10) Field (SMBI, ByteAcc, NoLock, Preserve) { HSTS, 8, Offset (0x02), HCON, 8, HCOM, 8, TXSA, 8, DAT0, 8, DAT1, 8, HBDR, 8, PECR, 8, RXSA, 8, SDAT, 16 } There are also bunch of AML methods that that the BIOS can use to access these fields. Most of the systems in question AML methods accessing the SMBI OpRegion are never used. Now, because of this SMBI OpRegion many systems fail to load the SMBus driver with an error looking like one below: ACPI Warning: SystemIO range 0x0000000000003040-0x000000000000305F conflicts with OpRegion 0x0000000000003040-0x000000000000304F (\_SB.PCI0.SBUS.SMBI) (20160108/utaddress-255) ACPI: If an ACPI driver is available for this device, you should use it instead of the native driver The reason is that this SMBI OpRegion conflicts with the PCI BAR used by the SMBus driver. It turns out that we can install a custom SystemIO address space handler for the SMBus device to intercept all accesses through that OpRegion. This allows us to share the PCI BAR with the AML code if it for some reason is using it. We do not expect that this OpRegion handler will ever be called but if it is we print a warning and prevent all access from the SMBus driver itself. Link: https://bugzilla.kernel.org/show_bug.cgi?id=110041 Reported-by: Andy Lutomirski Reported-by: Pali Rohár Suggested-by: Rafael J. Wysocki Signed-off-by: Mika Westerberg Acked-by: Rafael J. Wysocki Reviewed-by: Jean Delvare Reviewed-by: Benjamin Tissoires Tested-by: Pali Rohár Tested-by: Jean Delvare Signed-off-by: Wolfram Sang Cc: stable@vger.kernel.org drivers/i2c/busses/i2c-i801.c | 99 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 96 insertions(+), 3 deletions(-) commit 06dfeef88573cf032e5c27e37f80ff5237b3318a Author: Ben Dooks Date: Thu Jun 9 11:38:34 2016 +0100 drivers: of: add definition of early_init_dt_alloc_reserved_memory_arch The function early_init_dt_alloc_reserved_memory_arch is defined in drivers/of/of_reserved_mem.c but is not declared in any of the header files. Add the declaration of this to avoid the warning: drivers/of/of_reserved_mem.c:31:19: warning: symbol 'early_init_dt_alloc_reserved_memory_arch' was not declared. Should it be static? Signed-off-by: Ben Dooks [robh: drop extern from declaration] Signed-off-by: Rob Herring include/linux/of_reserved_mem.h | 7 +++++++ 1 file changed, 7 insertions(+) commit 8c237cd0ccb570d13158758af02e11359a4a5b1c Author: Gavin Shan Date: Thu Jun 9 15:50:49 2016 +1000 drivers/of: Fix depth for sub-tree blob in unflatten_dt_nodes() The function is unflattening device sub-tree blob if @dad passed to the function is valid. Currently, this functionality is used by PPC PowerNV PCI hotplug driver only. There are possibly multiple nodes in the first level of depth, fdt_next_node() bails immediately when @depth becomes negative before the second device node can be probed successfully. It leads to the device nodes except the first one won't be unflattened successfully. This fixes the issue by setting the initial depth (@inital_depth) to 1 when this function is called to unflatten device sub-tree blob. No logic changes when this function is used to unflatten non-sub-tree blob. Cc: Rhyland Klein Fixes: 78c44d910 ("drivers/of: Fix depth when unflattening devicetree") Signed-off-by: Gavin Shan Tested-by: Rhyland Klein Tested-by: Andrew Donnellan Signed-off-by: Rob Herring drivers/of/fdt.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit e71ba91e4839976ea0ada12f2d30c12d41825939 Merge: 60d6f36 3d5fdff Author: David S. Miller Date: Thu Jun 9 11:52:47 2016 -0700 Merge tag 'mac80211-for-davem-2016-06-09' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211 Johannes Berg says: ==================== Two more fixes for now: * a fix for a long-standing iwpriv 32/64 compat issue * two fairly recently introduced (4.6) warning asking for symmetric operations are erroneous and I remove them ==================== Signed-off-by: David S. Miller commit 60d6f36f5c9768f16b45dac7ecb483cce3e250a4 Merge: 9b15350 d664b41 Author: David S. Miller Date: Thu Jun 9 11:20:05 2016 -0700 Merge branch 'mlxsw-fixes' Jiri Pirko says: ==================== mlxsw: couple of fixes Couple of fixes from Ido. ==================== Signed-off-by: David S. Miller commit d664b41e2adf5851e4d0d39f450b2f3f808b65d6 Author: Ido Schimmel Date: Thu Jun 9 09:51:40 2016 +0200 mlxsw: spectrum: Don't sleep during ndo_get_phys_port_name() When rtnl_fill_ifinfo() is called for a certain netdevice it queries its various parameters such as switch id and physical port name. The function might get called in an atomic context, which means the underlying driver must not sleep during the query operation. Don't query the device and sleep during ndo_get_phys_port_name(), but instead store the needed parameters in port creation time. Fixes: 2bf9a58675c5 ("mlxsw: spectrum: Add support for physical port names") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 64 +++++++++----------------- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 5 ++ 2 files changed, 26 insertions(+), 43 deletions(-) commit be94535f95313a013b844b563ef15ddd8fb43da8 Author: Ido Schimmel Date: Thu Jun 9 09:51:39 2016 +0200 mlxsw: spectrum: Make split flow match firmware requirements When a port is created following a split / unsplit we need to map it to the correct module and lane, enable it and then continue to initialize its various parameters such as MTU and VLAN filters. Under certain conditions, such as trying to split ports at the bottom row of the front panel by four, we get firmware errors. After evaluating this with the firmware team it was decided to alter the split / unsplit flow, so that first all the affected ports are mapped, then enabled and finally each is initialized separately. Fix the split / unsplit flow by first mapping and enabling all the affected ports. Newer firmware versions will support both flows. Fixes: 18f1e70c4137 ("mlxsw: spectrum: Introduce port splitting") Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 147 ++++++++++++++++--------- 1 file changed, 95 insertions(+), 52 deletions(-) commit 56530f5d2ddc9b9fade7ef8db9cb886e9dc689b5 Author: Steve Capper Date: Tue Jun 7 17:58:06 2016 +0100 ARM: 8579/1: mm: Fix definition of pmd_mknotpresent Currently pmd_mknotpresent will use a zero entry to respresent an invalidated pmd. Unfortunately this definition clashes with pmd_none, thus it is possible for a race condition to occur if zap_pmd_range sees pmd_none whilst __split_huge_pmd_locked is running too with pmdp_invalidate just called. This patch fixes the race condition by modifying pmd_mknotpresent to create non-zero faulting entries (as is done in other architectures), removing the ambiguity with pmd_none. [catalin.marinas@arm.com: using L_PMD_SECT_VALID instead of PMD_TYPE_SECT] Fixes: 8d9625070073 ("ARM: mm: Transparent huge page support for LPAE systems.") Cc: # 3.11+ Reported-by: Kirill A. Shutemov Acked-by: Will Deacon Cc: Russell King Signed-off-by: Steve Capper Signed-off-by: Catalin Marinas Signed-off-by: Russell King arch/arm/include/asm/pgtable-3level.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 624531886987f0f1b5d01fb598034d039198e090 Author: Will Deacon Date: Tue Jun 7 17:57:54 2016 +0100 ARM: 8578/1: mm: ensure pmd_present only checks the valid bit In a subsequent patch, pmd_mknotpresent will clear the valid bit of the pmd entry, resulting in a not-present entry from the hardware's perspective. Unfortunately, pmd_present simply checks for a non-zero pmd value and will therefore continue to return true even after a pmd_mknotpresent operation. Since pmd_mknotpresent is only used for managing huge entries, this is only an issue for the 3-level case. This patch fixes the 3-level pmd_present implementation to take into account the valid bit. For bisectability, the change is made before the fix to pmd_mknotpresent. [catalin.marinas@arm.com: comment update regarding pmd_mknotpresent patch] Fixes: 8d9625070073 ("ARM: mm: Transparent huge page support for LPAE systems.") Cc: # 3.11+ Cc: Russell King Cc: Steve Capper Signed-off-by: Will Deacon Signed-off-by: Catalin Marinas Signed-off-by: Russell King arch/arm/include/asm/pgtable-2level.h | 1 + arch/arm/include/asm/pgtable-3level.h | 1 + arch/arm/include/asm/pgtable.h | 1 - 3 files changed, 2 insertions(+), 1 deletion(-) commit 1decabc1a70b97ef7412224df3dcb59d1227e3af Merge: d366a0f 2a6f71a Author: Jens Axboe Date: Thu Jun 9 09:49:55 2016 -0600 Merge branch 'stable/for-jens-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen into for-linus Konrad writes: Thishas two fixes for a guest migrating from host that has multi-queue to one without it (and vice-versa). commit 5f96ddb4607382528ef2eb23b49ce1856fdb316d Author: Rex Zhu Date: Fri Jun 3 19:12:42 2016 +0800 drm/amd/powerplay: delete useless code as pptable changed in vbios. The vbios table changed so this code is useless now. Signed-off-by: Rex Zhu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 21 --------------------- 1 file changed, 21 deletions(-) commit d2e312183b62cde0c44af35664f3b104b247dd9c Author: Rex Zhu Date: Thu Jun 2 19:11:01 2016 +0800 drm/amd/powerplay: fix bug visit array out of bounds Signed-off-by: Rex Zhu Acked-by: Christian König Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 5bbc16cc7be89dbe6dd824570456c3340b6d2ef7 Author: Monk Liu Date: Tue May 31 13:44:48 2016 +0800 drm/amdgpu: fix smu ucode memleak (v2) Properly release the smu ucode in powerplay. v2: agd: add polaris as well Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/smumgr/fiji_smumgr.c | 2 ++ drivers/gpu/drm/amd/powerplay/smumgr/polaris10_smumgr.c | 1 + drivers/gpu/drm/amd/powerplay/smumgr/tonga_smumgr.c | 2 ++ 3 files changed, 5 insertions(+) commit a392746a8c38de494a1a2d00c5cfd34a05449e35 Author: Monk Liu Date: Tue May 31 13:44:30 2016 +0800 drm/amdgpu: add release firmware for cgs Powerplay uses cgs to load the firmware so add a function to release it as well to avoid leaking it on driver unload. Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 12 ++++++++++++ drivers/gpu/drm/amd/include/cgs_common.h | 6 ++++++ 2 files changed, 18 insertions(+) commit 86e4cdd675f489e0b3deaa3d6b75cddadd16e71c Author: Monk Liu Date: Mon May 30 15:16:26 2016 +0800 drm/amdgpu: fix tonga smu_fini mem leak Signed-off-by: Monk Liu Acked-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/smumgr/tonga_smumgr.c | 5 +++++ 1 file changed, 5 insertions(+) commit e6232effab9091472689b1c5604a7e59d320a8e0 Author: Monk Liu Date: Mon May 30 15:16:04 2016 +0800 drm/amdgpu: fix fiji smu fini mem leak Signed-off-by: Monk Liu Acked-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/smumgr/fiji_smumgr.c | 4 ++++ 1 file changed, 4 insertions(+) commit d1ff53b7c2aa6e8c9dbd37ea7d858eeaba1ecb4a Author: Monk Liu Date: Mon May 30 16:07:40 2016 +0800 drm/amdgpu: fix cik sdma ucode memleak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 9c55c5204445689c1d6b7b60e89de7f8fcf8a77f Author: Monk Liu Date: Mon May 30 16:05:58 2016 +0800 drm/amdgpu: fix sdma24 ucode mem leak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 14d83e78c578a6c45163fb399ee760fe0d314bad Author: Monk Liu Date: Mon May 30 15:15:32 2016 +0800 drm/amdgpu: fix sdma3 ucode mem leak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 05f19eb5bd1d46aeeeb86a2a8538f35d7d55eb34 Author: Monk Liu Date: Mon May 30 15:13:59 2016 +0800 drm/amdgpu: fix uvd fini mem leak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit e517cd77ee76a26f3542d51a1b4f4d7c452f85cf Author: Monk Liu Date: Mon May 30 16:01:48 2016 +0800 drm/amdgpu: fix gfx 7 ucode mem leak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 13331ac384e8211a0bf3158a895ac8b22005a622 Author: Monk Liu Date: Mon May 30 14:18:57 2016 +0800 drm/amdgpu: fix gfx8 ucode mem leak Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) commit 67a6a504af90e58c478b2e7fa6c0af8ed64c995b Author: Monk Liu Date: Mon May 30 14:17:42 2016 +0800 drm/amdgpu: fix missing free wb for cond_exec Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 1 + 1 file changed, 1 insertion(+) commit 9d8f086cd05954e03f10db1a9a52a240d086dc8c Author: Monk Liu Date: Mon May 30 13:43:45 2016 +0800 drm/amdgpu: fix memleak in pptable_init Signed-off-by: Monk Liu Acked-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 8 +++- .../amd/powerplay/hwmgr/tonga_processpptables.c | 54 ++++++++++------------ 2 files changed, 32 insertions(+), 30 deletions(-) commit 89e0ec9f5e27a8c5b5954290bef703dc6aac44f3 Author: Monk Liu Date: Fri May 27 19:34:11 2016 +0800 drm/amdgpu: fix mem leak in atombios Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 61da601b95cd5565d047e42e73f984f5bdfbba70 Author: Monk Liu Date: Fri May 27 19:09:06 2016 +0800 drm/amdgpu: fix mem leak in pplib/hwmgr Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 3a3e88804d44e41ef2182d2a6577a6803fdd9ee0 Author: Monk Liu Date: Fri May 27 17:52:58 2016 +0800 drm/amdgpu: fix mem leak in smumgr Signed-off-by: Monk Liu Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/smumgr/smumgr.c | 1 + 1 file changed, 1 insertion(+) commit 2ba272d7bde27e1db2cf1c6cee49b01b7ea08989 Author: Chunming Zhou Date: Wed Apr 27 18:07:41 2016 +0800 drm/amdgpu: add pipeline sync while vmid switch in same ctx Since vmid-mgr supports vmid sharing in one vm, the same ctx could get different vmids for two emits without vm flush, vm_flush could be done in another ring. Signed-off-by: Chunming Zhou Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 +++- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 9 +++++++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 6 +++--- 3 files changed, 13 insertions(+), 6 deletions(-) commit fdff8cfa72b3e42d4d0c70684fa18b1dfee46d97 Author: Monk Liu Date: Tue May 24 13:23:46 2016 +0800 drm/amdgpu: vBIOS post only call when mem_size zero Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 505dfe76cd3203bb2dcf13d862f46b7f0e95869a Author: Monk Liu Date: Wed May 25 16:57:14 2016 +0800 drm/amdgpu: modify sdma start sequence should fist halt engine, and then doing the register programing, and later unhalt engine, and finally run ring_test. this help fix reloading driver hang issue of SDMA ring original sequence is wrong for it programing engine after unhalt, which will lead to fault behavior when doing driver reloading after unloaded. Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 9 +++++++-- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 8 ++++++-- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 15 +++++++++++---- 3 files changed, 24 insertions(+), 8 deletions(-) commit d72f7c0685870aa7efda0a06f8ca160a94905031 Author: Monk Liu Date: Wed May 25 16:55:50 2016 +0800 drm/amdgpu: init more register for sdma This help fix reloading driver hang issue of SDMA ring Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 ++ drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 ++ drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 ++ 3 files changed, 6 insertions(+) commit 9a005bef5b5b5ceb78ff1138e6d6baf4bbeb8061 Author: Monk Liu Date: Wed May 25 16:55:07 2016 +0800 drm/amdgpu: clear SA bo when created This help fix reloading driver hang issue of SDMA ring Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_sa.c | 1 + 1 file changed, 1 insertion(+) commit 768c95e70c4bd33b3da32a15dd33486246f4ca79 Author: Alex Deucher Date: Wed Jun 1 11:09:01 2016 -0400 drm/amdgpu: fix fw leak in non-powerplay dpm code We need to release the firmware on driver tear down. Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 3 +++ drivers/gpu/drm/amd/amdgpu/fiji_dpm.c | 5 +++++ drivers/gpu/drm/amd/amdgpu/iceland_dpm.c | 5 +++++ drivers/gpu/drm/amd/amdgpu/tonga_dpm.c | 5 +++++ 4 files changed, 18 insertions(+) commit a6dcfd9cc55432e4dcbe058d6ae9f07fb3452992 Author: Monk Liu Date: Thu May 19 14:36:34 2016 +0800 drm/amdgpu: fix pplib finish bug 1,should use late_fini to kfree all resource otherwise the released pointer maybe accessed in IRQ ip fini routine. 2,hwmgr should not be kfree by pem_fini which is invoked by hw fini path. Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 5 +++++ drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 7 ------- drivers/gpu/drm/amd/powerplay/eventmgr/eventmgr.c | 3 --- 3 files changed, 5 insertions(+), 10 deletions(-) commit 482587e3145ef4100b52946660ae52b457d09194 Author: Monk Liu Date: Thu May 19 14:36:01 2016 +0800 drm/amdgpu: impl late_fini for amdgpu_pp_ip This implements late_init support for powerplay. Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 212cb3b6d79bb9f525da5593133d93b107184b27 Author: Monk Liu Date: Thu May 19 14:35:17 2016 +0800 drm/amdgpu: add late_fini for ip_funcs This give IP modules an optional late cleanup function. This is needed to handle tricky inter-module dependencies during tear down. Signed-off-by: Monk Liu Reviewed-by: Alex Deucher Reviewed-by: Christian König Signed-off-by: Alex Deucher drivers/gpu/drm/amd/include/amd_shared.h | 1 + 1 file changed, 1 insertion(+) commit 8b4af8a8e3e6ad82e0d32d1665d9a755c05c4c12 Author: Rex Zhu Date: Mon May 23 18:24:41 2016 +0800 drm/admgpu/powerplay/polaris: fix powertune table upload Exclude AVFS related fields when update powertune table to hw. The driver shouldn't set them directly. Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_powertune.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d1a7f7aadc866eff61c422da0ecbe1f8e383e0f5 Author: Ken Wang Date: Tue May 24 09:26:27 2016 +0800 drm/amdgpu/iceland: Set SC_PA_RASTER_CONFIG according to different RB enabled fix the raster config setting for different iceland configs. Signed-off-by: Ken Wang Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 20c15226d1c73150c4d9107301cac5dda0b7f995 Author: Fabio Estevam Date: Wed May 11 16:39:30 2016 -0300 ARM: imx6ul: Fix Micrel PHY mask The value used for Micrel PHY mask is not correct. Use the MICREL_PHY_ID_MASK definition instead. Thanks to Jiri Luznicky for proposing the fix at https://community.freescale.com/thread/387739 Cc: Fixes: 709bc0657fe6f9f55 ("ARM: imx6ul: add fec MAC refrence clock and phy fixup init") Signed-off-by: Fabio Estevam Reviewed-by: Andrew Lunn Signed-off-by: Shawn Guo arch/arm/mach-imx/mach-imx6ul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3d5fdff46c4b2b9534fa2f9fc78e90a48e0ff724 Author: Prasun Maiti Date: Mon Jun 6 20:04:19 2016 +0530 wext: Fix 32 bit iwpriv compatibility issue with 64 bit Kernel iwpriv app uses iw_point structure to send data to Kernel. The iw_point structure holds a pointer. For compatibility Kernel converts the pointer as required for WEXT IOCTLs (SIOCIWFIRST to SIOCIWLAST). Some drivers may use iw_handler_def.private_args to populate iwpriv commands instead of iw_handler_def.private. For those case, the IOCTLs from SIOCIWFIRSTPRIV to SIOCIWLASTPRIV will follow the path ndo_do_ioctl(). Accordingly when the filled up iw_point structure comes from 32 bit iwpriv to 64 bit Kernel, Kernel will not convert the pointer and sends it to driver. So, the driver may get the invalid data. The pointer conversion for the IOCTLs (SIOCIWFIRSTPRIV to SIOCIWLASTPRIV), which follow the path ndo_do_ioctl(), is mandatory. This patch adds pointer conversion from 32 bit to 64 bit and vice versa, if the ioctl comes from 32 bit iwpriv to 64 bit Kernel. Cc: stable@vger.kernel.org Signed-off-by: Prasun Maiti Signed-off-by: Ujjal Roy Tested-by: Dibyajyoti Ghosh Signed-off-by: Johannes Berg net/wireless/wext-core.c | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) commit 6cbf6236d54c24b9a29e6892549c25b6902b44ce Author: Johannes Berg Date: Thu Jun 9 09:40:55 2016 +0200 cfg80211: remove get/set antenna and tx power warnings Since set_tx_power and set_antenna are frequently implemented without the matching get_tx_power/get_antenna, we shouldn't have added warnings for those. Remove them. The remaining ones are correct and need to be implemented symmetrically for correct operation. Cc: stable@vger.kernel.org Fixes: de3bb771f471 ("cfg80211: add more warnings for inconsistent ops") Signed-off-by: Johannes Berg net/wireless/core.c | 2 -- 1 file changed, 2 deletions(-) commit 8d29bdba7291f9f939bc17ac088ab650d106d451 Author: Dave Gerlach Date: Tue May 24 11:12:29 2016 -0500 ARM: OMAP2+: Select OMAP_INTERCONNECT for SOC_AM43XX AM43XX SoCs make use of the omap_l3_noc driver so explicitly select OMAP_INTERCONNECT in the Kconfig for SOC_AM43XX to ensure it always gets enabled for AM43XX only builds. Signed-off-by: Dave Gerlach Signed-off-by: Tony Lindgren arch/arm/mach-omap2/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 4c88c1c72f86dab63d8219c0aa9e9a398f2efaa9 Author: Tomi Valkeinen Date: Fri May 20 13:13:33 2016 +0300 ARM: dts: DRA74x: fix DSS PLL2 addresses DSS's 'pll2_clkctrl' and 'pll2' have wrong addresses in the dra74x.dtsi file. Video PLL2 has not been used so wrong addresses went unnoticed. Signed-off-by: Tomi Valkeinen Signed-off-by: Tony Lindgren arch/arm/boot/dts/dra74x.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2e4094bdaa3ef295abbebb31b978e3344ee64257 Author: Nishanth Menon Date: Thu May 19 18:20:17 2016 -0500 ARM: OMAP2: Enable Errata 430973 for OMAP3 Enable Erratum 430973 similar to commit 5c86c5339c56 ("ARM: omap2plus_defconfig: Enable ARM erratum 430973 for omap3") - Since multiple defconfigs can exist from various points of view (multi_v7, omap2plus etc.. it is always better to enable the erratum from the Kconfig selection point of view so that downstream kernels dont have to rediscover this all over again. Reported-by: Grygorii Strashko Signed-off-by: Nishanth Menon Signed-off-by: Tony Lindgren arch/arm/mach-omap2/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 35639a0e98391036a4c7f23253c321d6621a8897 Author: Vinod Koul Date: Thu Jun 9 11:32:14 2016 +0530 ALSA: hda - Add PCI ID for Kabylake Kabylake shows up as PCI ID 0xa171. And Kabylake-LP as 0x9d71. Since these are similar to Skylake add these to SKL_PLUS macro Signed-off-by: Vinod Koul Cc: Signed-off-by: Takashi Iwai sound/pci/hda/hda_intel.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 9b15350f0d5c401c02eca15c4e6ca0603cff1a41 Author: Florian Westphal Date: Wed Jun 8 23:23:01 2016 +0200 qfq: don't leak skb if kzalloc fails When we need to create a new aggregate to enqueue the skb we call kzalloc. If that fails we returned ENOBUFS without freeing the skb. Spotted during code review. Signed-off-by: Florian Westphal Signed-off-by: David S. Miller net/sched/sch_qfq.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 0a46baaf634663d28038fc137239b71bf5385e5a Author: Shweta Choudaha Date: Wed Jun 8 20:15:43 2016 +0100 ip6gre: Allow live link address change The ip6 GRE tap device should not be forced to down state to change the mac address and should allow live address change for tap device similar to ipv4 gre. Signed-off-by: Shweta Choudaha Signed-off-by: David S. Miller net/ipv6/ip6_gre.c | 3 +++ 1 file changed, 3 insertions(+) commit a436d20df948f62a79ee0547d223936e5b2b9d54 Merge: 3497ed8 201c44b Author: David S. Miller Date: Wed Jun 8 21:43:15 2016 -0700 Merge branch 'cls_u32-hwoffload-fixes' Jakub Kicinski says: ==================== incremental cls_u32 hardware offload fixes These are incremental changes from v1 of cls_u32 fixes. First patch is reposted in its entirety, patch 2 is an incremental change from patch 2 of the original series. ==================== Signed-off-by: David S. Miller commit 201c44bd8ffa899f07b7b322a73e19baf0ada1e5 Author: Jakub Kicinski Date: Wed Jun 8 20:11:04 2016 +0100 net: cls_u32: be more strict about skip-sw flag for knodes Return an error if user requested skip-sw and the underlaying hardware cannot handle tc offloads (or offloads are disabled). This patch fixes the knode handling. Signed-off-by: Jakub Kicinski Signed-off-by: David S. Miller net/sched/cls_u32.c | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) commit 6eef3801e719e4ea9c15c01b1d77706f47331166 Author: Jakub Kicinski Date: Wed Jun 8 20:11:03 2016 +0100 net: cls_u32: catch all hardware offload errors Errors reported by u32_replace_hw_hnode() were not propagated. Signed-off-by: Jakub Kicinski Acked-by: Sridhar Samudrala Signed-off-by: David S. Miller net/sched/cls_u32.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 72d8c36ec364c82bf1bf0c64dfa1041cfaf139f7 Author: Wei Fang Date: Tue Jun 7 14:53:56 2016 +0800 scsi: fix race between simultaneous decrements of ->host_failed sas_ata_strategy_handler() adds the works of the ata error handler to system_unbound_wq. This workqueue asynchronously runs work items, so the ata error handler will be performed concurrently on different CPUs. In this case, ->host_failed will be decreased simultaneously in scsi_eh_finish_cmd() on different CPUs, and become abnormal. It will lead to permanently inequality between ->host_failed and ->host_busy, and scsi error handler thread won't start running. IO errors after that won't be handled. Since all scmds must have been handled in the strategy handler, just remove the decrement in scsi_eh_finish_cmd() and zero ->host_busy after the strategy handler to fix this race. Fixes: 50824d6c5657 ("[SCSI] libsas: async ata-eh") Cc: stable@vger.kernel.org Signed-off-by: Wei Fang Reviewed-by: James Bottomley Signed-off-by: Martin K. Petersen Documentation/scsi/scsi_eh.txt | 8 ++++++-- drivers/ata/libata-eh.c | 2 +- drivers/scsi/scsi_error.c | 4 +++- 3 files changed, 10 insertions(+), 4 deletions(-) commit 170fba306af798bc1249b6ba925cf9031f3b3806 Merge: 8533273 56d1fe0 Author: Dave Airlie Date: Thu Jun 9 12:32:09 2016 +1000 Merge tag 'drm-vc4-fixes-2016-06-06' of github.com:anholt/linux into drm-fixes This pull request brings in vblank/pageflip fixes I had hoped to see merged before 4.7rc1, plus two new fixes that have come in since then. * tag 'drm-vc4-fixes-2016-06-06' of github.com:anholt/linux: drm/vc4: Make pageflip completion handling more robust. drm/vc4: Fix ioctl permissions for render nodes. drm/vc4: Return -EBUSY if there's already a pending flip event. drm/vc4: Fix drm_vblank_put/get imbalance in page flip path. drm/vc4: Fix get_vblank_counter with proper no-op for Linux 4.4+ commit 85332739628fe4beafecdb713438c7cb1454c2f5 Author: Tomi Valkeinen Date: Fri Jun 3 14:27:03 2016 +0300 drm/omap: fix unused variable warning in dsi & hdmi Signed-off-by: Tomi Valkeinen Signed-off-by: Dave Airlie drivers/gpu/drm/omapdrm/dss/dsi.c | 1 - drivers/gpu/drm/omapdrm/dss/hdmi5.c | 1 - 2 files changed, 2 deletions(-) commit 9920779c9054ee442f38e7e9c8d606c77d11b8d8 Merge: af8c34c 4691409 Author: Dave Airlie Date: Thu Jun 9 12:30:29 2016 +1000 Merge branch 'linux-4.7' of git://github.com/skeggsb/linux into drm-fixes Fixes for two issues reported by KASAN, a display engine hang due to incorrect BIOS table parsing, and incorrect LTC interrupt handling on Maxwell which could lead to a never-ending interrupt storm. * 'linux-4.7' of git://github.com/skeggsb/linux: drm/nouveau/disp/sor/gm107: training pattern registers are like gm200 drm/nouveau/disp/sor/gf119: both links use the same training register drm/nouveau/core: swap the order of imem/fb drm/nouveau/fbcon: fix out-of-bounds memory accesses drm/nouveau/gr/gf100-: update sm error decoding from gk20a nvgpu headers drm/nouveau/ltc/gm107-: fix typo in the address of NV_PLTCG_LTC0_LTS0_INTR drm/nouveau/bios/disp: fix handling of "match any protocol" entries commit ce492b3b8f99cf9d2f807ec22d8805c996a09503 Author: Stefan Agner Date: Fri Jun 3 14:21:34 2016 -0700 drm/fsl-dcu: use flat regmap cache Using flat regmap cache instead of RB-tree to avoid the following lockdep warning on driver load: WARNING: CPU: 0 PID: 1 at kernel/locking/lockdep.c:2755 lockdep_trace_alloc+0x15c/0x160() DEBUG_LOCKS_WARN_ON(irqs_disabled_flags(flags)) The RB-tree regmap cache needs to allocate new space on first writes. However, allocations in an atomic context (e.g. when a spinlock is held) are not allowed. The function regmap_write calls map->lock, which acquires a spinlock in the fast_io case. Since the FSL DCU driver uses MMIO, the regmap bus of type regmap_mmio is being used which has fast_io set to true. Use flat regmap cache and specify max register to be large enouth to cover all registers available in LS1021a and Vybrids register space. Signed-off-by: Stefan Agner Cc: Mark Brown Cc: stable@vger.kernel.org drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 719da39a61173c849f70656ed1a302e4b6deaa5b Merge: 4c52990 5f9e105 Author: Chris Mason Date: Wed Jun 8 14:36:12 2016 -0700 Merge branch 'misc-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux into for-linus-4.7 commit 4c52990080e37925039a4d546937e9df2a8da944 Merge: 8dff9c8 34b3e6c Author: Chris Mason Date: Wed Jun 8 14:35:11 2016 -0700 Merge branch 'for-chris' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux into for-linus-4.7 commit 25789f95a8834d154e5c1f0c9df9a7faedeae98e Author: Jean Delvare Date: Thu May 26 11:43:23 2016 +0200 platform/x86: Drop duplicate dependencies on X86 The whole menu depends on X86 so there is no point in repeating this dependency on individual driver entries. Signed-off-by: Jean Delvare Signed-off-by: Darren Hart drivers/platform/x86/Kconfig | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 0118c2d3eac0545d4095877e5a015b5dc763b3c2 Author: Dennis Wassenberg Date: Wed Jun 8 10:54:25 2016 -0400 thinkpad_acpi: Add support for HKEY version 0x200 Lenovo Thinkpad devices T460, T460s, T460p, T560, X260 use HKEY version 0x200 without adaptive keyboard. HKEY version 0x200 has method MHKA with one parameter value. Passing parameter value 1 will get hotkey_all_mask (the same like HKEY version 0x100 without parameter). Passing parameter value 2 to MHKA method will retrieve hotkey_all_adaptive_mask. If 0 is returned in that case there is no adaptive keyboard available. Signed-off-by: Dennis Wassenberg Signed-off-by: Lyude Tested-by: Lyude Tested-by: Marco Trevisan Acked-by: Henrique de Moraes Holschuh [dvhart: Keep MHKA error string on one line in new and existing pr_err calls] Signed-off-by: Darren Hart drivers/platform/x86/thinkpad_acpi.c | 87 ++++++++++++++++++++++++++---------- 1 file changed, 63 insertions(+), 24 deletions(-) commit 48f67d62194952617dcade08194abc7f5cb3f50c Author: Alex Hung Date: Mon Jun 6 09:46:11 2016 +0800 ideapad_laptop: Add an event for mic mute hotkey Newer ideapads support a new mic hotkey implemented via an ACPI interface. This patch converts the mic mute event to a keycode KEY_MICMUTE. Signed-off-by: Alex Hung Acked-by: Ike Panhc Signed-off-by: Darren Hart drivers/platform/x86/ideapad-laptop.c | 2 ++ 1 file changed, 2 insertions(+) commit c106c21ce02e366f3dc887bff7c48f3f140c45c9 Author: Marek Vasut Date: Wed May 25 22:40:42 2016 +0000 ARM: dts: socfpga: Add missing PHY phandle Add missing PHY phandle into the DT, otherwise the stmmac code won't detect the PHY correctly anymore. Signed-off-by: Marek Vasut Cc: Dinh Nguyen Signed-off-by: Dinh Nguyen arch/arm/boot/dts/socfpga_cyclone5_vining_fpga.dts | 1 + 1 file changed, 1 insertion(+) commit 3497ed8c852a5a3d48957ca91baaa443d9bfcd4d Author: Bert Kenward Date: Mon Jun 6 17:29:30 2016 +0100 sfc: report supported link speeds on SFP connections 7000-series SFC NICs connected with an SFP+ module currently fail to report any supported link speeds. Reported-by: Jarod Wilson Signed-off-by: Bert Kenward Reviewed-by: Jarod Wilson Tested-by: Jarod Wilson Signed-off-by: David S. Miller drivers/net/ethernet/sfc/mcdi_port.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit e0d194adfa9f5f473068cc546bee60fb84ab77ba Author: Eric Dumazet Date: Wed Jun 8 06:19:45 2016 -0700 net_sched: add missing paddattr description "make htmldocs" complains otherwise: .//net/core/gen_stats.c:65: warning: No description found for parameter 'padattr' .//net/core/gen_stats.c:101: warning: No description found for parameter 'padattr' Fixes: 9854518ea04d ("sched: align nlattr properly when needed") Signed-off-by: Eric Dumazet Reported-by: kbuild test robot Acked-by: Nicolas Dichtel Signed-off-by: David S. Miller net/core/gen_stats.c | 2 ++ 1 file changed, 2 insertions(+) commit 00bc0ef5880dc7b82f9c320dead4afaad48e47be Author: Jakub Sitnicki Date: Wed Jun 8 15:13:34 2016 +0200 ipv6: Skip XFRM lookup if dst_entry in socket cache is valid At present we perform an xfrm_lookup() for each UDPv6 message we send. The lookup involves querying the flow cache (flow_cache_lookup) and, in case of a cache miss, creating an XFRM bundle. If we miss the flow cache, we can end up creating a new bundle and deriving the path MTU (xfrm_init_pmtu) from on an already transformed dst_entry, which we pass from the socket cache (sk->sk_dst_cache) down to xfrm_lookup(). This can happen only if we're caching the dst_entry in the socket, that is when we're using a connected UDP socket. To put it another way, the path MTU shrinks each time we miss the flow cache, which later on leads to incorrectly fragmented payload. It can be observed with ESPv6 in transport mode: 1) Set up a transformation and lower the MTU to trigger fragmentation # ip xfrm policy add dir out src ::1 dst ::1 \ tmpl src ::1 dst ::1 proto esp spi 1 # ip xfrm state add src ::1 dst ::1 \ proto esp spi 1 enc 'aes' 0x0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b # ip link set dev lo mtu 1500 2) Monitor the packet flow and set up an UDP sink # tcpdump -ni lo -ttt & # socat udp6-listen:12345,fork /dev/null & 3) Send a datagram that needs fragmentation with a connected socket # perl -e 'print "@" x 1470 | socat - udp6:[::1]:12345 2016/06/07 18:52:52 socat[724] E read(3, 0x555bb3d5ba00, 8192): Protocol error 00:00:00.000000 IP6 ::1 > ::1: frag (0|1448) ESP(spi=0x00000001,seq=0x2), length 1448 00:00:00.000014 IP6 ::1 > ::1: frag (1448|32) 00:00:00.000050 IP6 ::1 > ::1: ESP(spi=0x00000001,seq=0x3), length 1272 (^ ICMPv6 Parameter Problem) 00:00:00.000022 IP6 ::1 > ::1: ESP(spi=0x00000001,seq=0x5), length 136 4) Compare it to a non-connected socket # perl -e 'print "@" x 1500' | socat - udp6-sendto:[::1]:12345 00:00:40.535488 IP6 ::1 > ::1: frag (0|1448) ESP(spi=0x00000001,seq=0x6), length 1448 00:00:00.000010 IP6 ::1 > ::1: frag (1448|64) What happens in step (3) is: 1) when connecting the socket in __ip6_datagram_connect(), we perform an XFRM lookup, miss the flow cache, create an XFRM bundle, and cache the destination, 2) afterwards, when sending the datagram, we perform an XFRM lookup, again, miss the flow cache (due to mismatch of flowi6_iif and flowi6_oif, which is an issue of its own), and recreate an XFRM bundle based on the cached (and already transformed) destination. To prevent the recreation of an XFRM bundle, avoid an XFRM lookup altogether whenever we already have a destination entry cached in the socket. This prevents the path MTU shrinkage and brings us on par with UDPv4. The fix also benefits connected PINGv6 sockets, another user of ip6_sk_dst_lookup_flow(), who also suffer messages being transformed twice. Joint work with Hannes Frederic Sowa. Reported-by: Jan Tluka Signed-off-by: Jakub Sitnicki Acked-by: Hannes Frederic Sowa Signed-off-by: David S. Miller net/ipv6/ip6_output.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) commit a5c5e2da8551eb69e5d5d09d51d526140b5db9fb Author: Guillaume Nault Date: Wed Jun 8 12:59:17 2016 +0200 l2tp: fix configuration passed to setup_udp_tunnel_sock() Unused fields of udp_cfg must be all zeros. Otherwise setup_udp_tunnel_sock() fills ->gro_receive and ->gro_complete callbacks with garbage, eventually resulting in panic when used by udp_gro_receive(). [ 72.694123] BUG: unable to handle kernel paging request at ffff880033f87d78 [ 72.695518] IP: [] 0xffff880033f87d78 [ 72.696530] PGD 26e2067 PUD 26e3067 PMD 342ed063 PTE 8000000033f87163 [ 72.696530] Oops: 0011 [#1] SMP KASAN [ 72.696530] Modules linked in: l2tp_ppp l2tp_netlink l2tp_core ip6_udp_tunnel udp_tunnel pptp gre pppox ppp_generic slhc crc32c_intel ghash_clmulni_intel jitterentropy_rng sha256_generic hmac drbg ansi_cprng aesni_intel evdev aes_x86_64 ablk_helper cryptd lrw gf128mul glue_helper serio_raw acpi_cpufreq button proc\ essor ext4 crc16 jbd2 mbcache virtio_blk virtio_net virtio_pci virtio_ring virtio [ 72.696530] CPU: 3 PID: 0 Comm: swapper/3 Not tainted 4.7.0-rc1 #1 [ 72.696530] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Debian-1.8.2-1 04/01/2014 [ 72.696530] task: ffff880035b59700 ti: ffff880035b70000 task.ti: ffff880035b70000 [ 72.696530] RIP: 0010:[] [] 0xffff880033f87d78 [ 72.696530] RSP: 0018:ffff880035f87bc0 EFLAGS: 00010246 [ 72.696530] RAX: ffffed000698f996 RBX: ffff88003326b840 RCX: ffffffff814cc823 [ 72.696530] RDX: ffff88003326b840 RSI: ffff880033e48038 RDI: ffff880034c7c780 [ 72.696530] RBP: ffff880035f87c18 R08: 000000000000a506 R09: 0000000000000000 [ 72.696530] R10: ffff880035f87b38 R11: ffff880034b9344d R12: 00000000ebfea715 [ 72.696530] R13: 0000000000000000 R14: ffff880034c7c780 R15: 0000000000000000 [ 72.696530] FS: 0000000000000000(0000) GS:ffff880035f80000(0000) knlGS:0000000000000000 [ 72.696530] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 72.696530] CR2: ffff880033f87d78 CR3: 0000000033c98000 CR4: 00000000000406a0 [ 72.696530] Stack: [ 72.696530] ffffffff814cc834 ffff880034b93468 0000001481416818 ffff88003326b874 [ 72.696530] ffff880034c7ccb0 ffff880033e48038 ffff88003326b840 ffff880034b93462 [ 72.696530] ffff88003326b88a ffff88003326b88c ffff880034b93468 ffff880035f87c70 [ 72.696530] Call Trace: [ 72.696530] [ 72.696530] [] ? udp_gro_receive+0x1c6/0x1f9 [ 72.696530] [] udp4_gro_receive+0x2b5/0x310 [ 72.696530] [] inet_gro_receive+0x4a3/0x4cd [ 72.696530] [] dev_gro_receive+0x584/0x7a3 [ 72.696530] [] ? __lock_is_held+0x29/0x64 [ 72.696530] [] napi_gro_receive+0x124/0x21d [ 72.696530] [] virtnet_receive+0x8df/0x8f6 [virtio_net] [ 72.696530] [] virtnet_poll+0x1d/0x8d [virtio_net] [ 72.696530] [] net_rx_action+0x15b/0x3b9 [ 72.696530] [] __do_softirq+0x216/0x546 [ 72.696530] [] irq_exit+0x49/0xb6 [ 72.696530] [] do_IRQ+0xe2/0xfa [ 72.696530] [] common_interrupt+0x89/0x89 [ 72.696530] [ 72.696530] [] ? trace_hardirqs_on_caller+0x229/0x270 [ 72.696530] [] ? default_idle+0x1c/0x2d [ 72.696530] [] ? default_idle+0x1a/0x2d [ 72.696530] [] arch_cpu_idle+0xa/0xc [ 72.696530] [] default_idle_call+0x1a/0x1c [ 72.696530] [] cpu_startup_entry+0x15b/0x20f [ 72.696530] [] start_secondary+0x12c/0x133 [ 72.696530] Code: ff ff ff ff ff ff ff ff ff ff 7f ff ff ff ff ff ff ff 7f 00 7e f8 33 00 88 ff ff 6d 61 58 81 ff ff ff ff 5e de 0a 81 ff ff ff ff <00> 5c e2 34 00 88 ff ff 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 72.696530] RIP [] 0xffff880033f87d78 [ 72.696530] RSP [ 72.696530] CR2: ffff880033f87d78 [ 72.696530] ---[ end trace ad7758b9a1dccf99 ]--- [ 72.696530] Kernel panic - not syncing: Fatal exception in interrupt [ 72.696530] Kernel Offset: disabled [ 72.696530] ---[ end Kernel panic - not syncing: Fatal exception in interrupt v2: use empty initialiser instead of "{ NULL }" to avoid relying on first field's type. Fixes: 38fd2af24fcf ("udp: Add socket based GRO and config") Signed-off-by: Guillaume Nault Signed-off-by: David S. Miller net/l2tp/l2tp_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2a6f71ad99cabe436e70c3f5fcf58072cb3bc07f Author: Bob Liu Date: Tue May 31 16:59:17 2016 +0800 xen-blkfront: fix resume issues after a migration After a migrate to another host (which may not have multiqueue support), the number of rings (block hardware queues) may be changed and the ring info structure will also be reallocated. This patch fixes two related bugs: * call blk_mq_update_nr_hw_queues() to make blk-core know the number of hardware queues have been changed. * Don't store rinfo pointer to hctx->driver_data, because rinfo may be reallocated so use hctx->queue_num to get the rinfo structure instead. Signed-off-by: Bob Liu Signed-off-by: Konrad Rzeszutek Wilk drivers/block/xen-blkfront.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) commit efd1535270c1deb0487527bf0c3c827301a69c93 Author: Bob Liu Date: Tue Jun 7 10:43:15 2016 -0400 xen-blkfront: don't call talk_to_blkback when already connected to blkback Sometimes blkfront may twice receive blkback_changed() notification (XenbusStateConnected) after migration, which will cause talk_to_blkback() to be called twice too and confuse xen-blkback. The flow is as follow: blkfront blkback blkfront_resume() > talk_to_blkback() > Set blkfront to XenbusStateInitialised front changed() > Connect() > Set blkback to XenbusStateConnected blkback_changed() > Skip talk_to_blkback() because frontstate == XenbusStateInitialised > blkfront_connect() > Set blkfront to XenbusStateConnected ----- And here we get another XenbusStateConnected notification leading to: ----- blkback_changed() > because now frontstate != XenbusStateInitialised talk_to_blkback() is also called again > blkfront state changed from XenbusStateConnected to XenbusStateInitialised (Which is not correct!) front_changed(): > Do nothing because blkback already in XenbusStateConnected Now blkback is in XenbusStateConnected but blkfront is still in XenbusStateInitialised - leading to no disks. Poking of the XenbusStateConnected state is allowed (to deal with block disk change) and has to be dealt with. The most likely cause of this bug are custom udev scripts hooking up the disks and then validating the size. Signed-off-by: Bob Liu Signed-off-by: Konrad Rzeszutek Wilk drivers/block/xen-blkfront.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit 077fa7aed17de5022e44bf07dbaf732078b7b5b2 Author: Mel Gorman Date: Wed Jun 8 14:25:22 2016 +0100 futex: Calculate the futex key based on a tail page for file-based futexes Mike Galbraith reported that the LTP test case futex_wake04 was broken by commit 65d8fc777f6d ("futex: Remove requirement for lock_page() in get_futex_key()"). This test case uses futexes backed by hugetlbfs pages and so there is an associated inode with a futex stored on such pages. The problem is that the key is being calculated based on the head page index of the hugetlbfs page and not the tail page. Prior to the optimisation, the page lock was used to stabilise mappings and pin the inode is file-backed which is overkill. If the page was a compound page, the head page was automatically looked up as part of the page lock operation but the tail page index was used to calculate the futex key. After the optimisation, the compound head is looked up early and the page lock is only relied upon to identify truncated pages, special pages or a shmem page moving to swapcache. The head page is looked up because without the page lock, special care has to be taken to pin the inode correctly. However, the tail page is still required to calculate the futex key so this patch records the tail page. On vanilla 4.6, the output of the test case is; futex_wake04 0 TINFO : Hugepagesize 2097152 futex_wake04 1 TFAIL : futex_wake04.c:126: Bug: wait_thread2 did not wake after 30 secs. With the patch applied futex_wake04 0 TINFO : Hugepagesize 2097152 futex_wake04 1 TPASS : Hi hydra, thread2 awake! Fixes: 65d8fc777f6d "futex: Remove requirement for lock_page() in get_futex_key()" Reported-and-tested-by: Mike Galbraith Signed-off-by: Mel Gorman Acked-by: Peter Zijlstra (Intel) Reviewed-by: Davidlohr Bueso Cc: Sebastian Andrzej Siewior Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/20160608132522.GM2469@suse.de Signed-off-by: Thomas Gleixner kernel/futex.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit c0530dd3ef1d3997d885e1345e34a284db2b9cfa Author: Hariprasad Shenai Date: Wed Jun 8 14:57:28 2016 +0530 cxgb4: Add device id of T540-BT adapter Signed-off-by: Hariprasad Shenai Signed-off-by: David S. Miller drivers/net/ethernet/chelsio/cxgb4/t4_pci_id_tbl.h | 1 + 1 file changed, 1 insertion(+) commit d366a0ff1cf73f93796f2377e7b0361a94c41c35 Author: Josef Bacik Date: Wed Jun 8 10:32:10 2016 -0400 nbd: pass the nbd pointer for flags debugfs We were passing in &nbd for the private data in debugfs_create_file() for the flags entry. We expect it to just be nbd, fix this so we get proper output from this debugfs entry. Signed-off-by: Josef Bacik Signed-off-by: Jens Axboe drivers/block/nbd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0b0d81e3b7334897da9b2e3ffee860c2046f7bc0 Author: Josh Poimboeuf Date: Thu May 26 13:43:43 2016 -0500 objtool, drm/vmwgfx: Fix "duplicate frame pointer save" warning objtool reports the following warnings: drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_send_msg()+0x107: duplicate frame pointer save drivers/gpu/drm/vmwgfx/vmwgfx_msg.o: warning: objtool: vmw_host_get_guestinfo()+0x252: duplicate frame pointer save To quote Linus: "The reason is that VMW_PORT_HB_OUT() uses a magic instruction sequence (a "rep outsb") to communicate with the hypervisor (it's a virtual GPU driver for vmware), and %rbp is part of the communication. So the inline asm does a save-and-restore of the frame pointer around the instruction sequence. I actually find the objtool warning to be quite reasonable, so it's not exactly a false positive, since in this case it actually does point out that the frame pointer won't be reliable over that instruction sequence. But in this particular case it just ends up being the wrong thing - the code is what it is, and %rbp just can't have the frame information due to annoying magic calling conventions." Silence the warnings by telling objtool to ignore the two functions which use the VMW_PORT_HB_{IN,OUT} macros. Reported-by: Linus Torvalds Signed-off-by: Josh Poimboeuf Acked-by: Linus Torvalds Cc: DRI Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/20160526184343.fdtjjjg67smmeekt@treble Signed-off-by: Ingo Molnar drivers/gpu/drm/vmwgfx/vmwgfx_msg.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 5c1d3310d84309330264e2a06e5000eb289a44ad Author: Robin Murphy Date: Tue Jun 7 18:44:48 2016 +0100 drivers: of: Fix of_pci.h header guard The compilation of of_pci.c is governed by CONFIG_OF_PCI, but the corresponding declarations in of_pci.h are inconsistently guarded by CONFIG_OF, with the result that if CONFIG_PCI is disabled for an OF platform, the dangling external declarations are still active and the inline stub definitions not. So far this has managed to go unnoticed since it happens that the only references to these functions are from code which itself depends on CONFIG_PCI or CONFIG_OF_PCI. Fix this with the appropriate config guard so that any new callers outside PCI-specific code don't start unexpectedly breaking under certain configs. Signed-off-by: Robin Murphy Signed-off-by: Rob Herring include/linux/of_pci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3eefa7e8cc8516d737a6a961914e20501eb2a952 Author: Fabio Estevam Date: Thu Jun 2 21:30:48 2016 -0300 dt-bindings: Add vendor prefix for TechNexion TechNexion designs and manufactures embedded computing systems: http://www.technexion.com/ Signed-off-by: Fabio Estevam Signed-off-by: Rob Herring Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 4698f88c06b893f2acc0b443004a53bf490fde7c Author: Josh Poimboeuf Date: Tue Jun 7 14:43:16 2016 -0500 sched/debug: Fix 'schedstats=enable' cmdline option The 'schedstats=enable' option doesn't work, and also produces the following warning during boot: WARNING: CPU: 0 PID: 0 at /home/jpoimboe/git/linux/kernel/jump_label.c:61 static_key_slow_inc+0x8c/0xa0 static_key_slow_inc used before call to jump_label_init Modules linked in: CPU: 0 PID: 0 Comm: swapper Not tainted 4.7.0-rc1+ #25 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.8.1-20150318_183358- 04/01/2014 0000000000000086 3ae3475a4bea95d4 ffffffff81e03da8 ffffffff8143fc83 ffffffff81e03df8 0000000000000000 ffffffff81e03de8 ffffffff810b1ffb 0000003d00000096 ffffffff823514d0 ffff88007ff197c8 0000000000000000 Call Trace: [] dump_stack+0x85/0xc2 [] __warn+0xcb/0xf0 [] warn_slowpath_fmt+0x5f/0x80 [] static_key_slow_inc+0x8c/0xa0 [] static_key_enable+0x16/0x40 [] setup_schedstats+0x29/0x94 [] unknown_bootoption+0x89/0x191 [] parse_args+0x297/0x4b0 [] start_kernel+0x1d8/0x4a9 [] ? set_init_arg+0x55/0x55 [] ? early_idt_handler_array+0x120/0x120 [] x86_64_start_reservations+0x2f/0x31 [] x86_64_start_kernel+0x14a/0x16d The problem is that it tries to update the 'sched_schedstats' static key before jump labels have been initialized. Changing jump_label_init() to be called earlier before parse_early_param() wouldn't fix it: it would still fail trying to poke_text() because mm isn't yet initialized. Instead, just create a temporary '__sched_schedstats' variable which can be copied to the static key later during sched_init() after jump labels have been initialized. Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Cc: Linus Torvalds Cc: Matt Fleming Cc: Mel Gorman Cc: Peter Zijlstra Cc: Srikar Dronamraju Cc: Thomas Gleixner Fixes: cb2517653fcc ("sched/debug: Make schedstats a runtime tunable that is disabled by default") Link: http://lkml.kernel.org/r/453775fe3433bed65731a583e228ccea806d18cd.1465322027.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar kernel/sched/core.c | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) commit 9c57259117b9c25472a3fa6d5a14d6bb3b647e87 Author: Josh Poimboeuf Date: Fri Jun 3 17:58:40 2016 -0500 sched/debug: Fix /proc/sched_debug regression Commit: cb2517653fcc ("sched/debug: Make schedstats a runtime tunable that is disabled by default") ... introduced a bug when CONFIG_SCHEDSTATS is enabled and the runtime tunable is disabled (which is the default). The wait-time, sum-exec, and sum-sleep fields are missing from the /proc/sched_debug file in the runnable_tasks section. Fix it with a new schedstat_val() macro which returns the field value when schedstats is enabled and zero otherwise. The macro works with both SCHEDSTATS and !SCHEDSTATS. I put the macro in stats.h since it might end up being useful in other places. Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Acked-by: Mel Gorman Cc: Linus Torvalds Cc: Matt Fleming Cc: Peter Zijlstra Cc: Srikar Dronamraju Cc: Thomas Gleixner Fixes: cb2517653fcc ("sched/debug: Make schedstats a runtime tunable that is disabled by default") Link: http://lkml.kernel.org/r/bcda7c2790cf2ccbe586a28c02dd7b6fe7749a2b.1464994423.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar kernel/sched/debug.c | 15 ++++----------- kernel/sched/stats.h | 3 +++ 2 files changed, 7 insertions(+), 11 deletions(-) commit 62a92c8f553e49270a0ee391b8733da71ab0aebc Author: Alexander Shishkin Date: Tue Jun 7 15:44:15 2016 +0300 perf/core: Remove a redundant check There is no way to end up in _free_event() with event::pmu being NULL. The latter is initialized in event allocation path and remains set forever. In case of allocation failure, the error path doesn't use _free_event(). Having the check, however, suggests that it is possible to have a event::pmu==NULL situation in _free_event() and confuses the robots. This patch gets rid of the check. Reported-by: Dan Carpenter Signed-off-by: Alexander Shishkin Signed-off-by: Peter Zijlstra (Intel) Cc: Arnaldo Carvalho de Melo Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: eranian@google.com Cc: vince@deater.net Link: http://lkml.kernel.org/r/1465303455-26032-1-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar kernel/events/core.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 2c610022711675ee908b903d242f0b90e1db661f Author: Peter Zijlstra Date: Wed Jun 8 10:19:51 2016 +0200 locking/qspinlock: Fix spin_unlock_wait() some more While this prior commit: 54cf809b9512 ("locking,qspinlock: Fix spin_is_locked() and spin_unlock_wait()") ... fixes spin_is_locked() and spin_unlock_wait() for the usage in ipc/sem and netfilter, it does not in fact work right for the usage in task_work and futex. So while the 2 locks crossed problem: spin_lock(A) spin_lock(B) if (!spin_is_locked(B)) spin_unlock_wait(A) foo() foo(); ... works with the smp_mb() injected by both spin_is_locked() and spin_unlock_wait(), this is not sufficient for: flag = 1; smp_mb(); spin_lock() spin_unlock_wait() if (!flag) // add to lockless list // iterate lockless list ... because in this scenario, the store from spin_lock() can be delayed past the load of flag, uncrossing the variables and loosing the guarantee. This patch reworks spin_is_locked() and spin_unlock_wait() to work in both cases by exploiting the observation that while the lock byte store can be delayed, the contender must have registered itself visibly in other state contained in the word. It also allows for architectures to override both functions, as PPC and ARM64 have an additional issue for which we currently have no generic solution. Signed-off-by: Peter Zijlstra (Intel) Cc: Andrew Morton Cc: Boqun Feng Cc: Davidlohr Bueso Cc: Giovanni Gherdovich Cc: Linus Torvalds Cc: Pan Xinhui Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Waiman Long Cc: Will Deacon Cc: stable@vger.kernel.org # v4.2 and later Fixes: 54cf809b9512 ("locking,qspinlock: Fix spin_is_locked() and spin_unlock_wait()") Signed-off-by: Ingo Molnar include/asm-generic/qspinlock.h | 53 ++++++++++++------------------------ kernel/locking/qspinlock.c | 60 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 77 insertions(+), 36 deletions(-) commit b66b2a0adf0e48973b582e055758b9907a7eee7c Author: Ben Dooks Date: Tue Jun 7 17:22:17 2016 +0100 gpio: bcm-kona: fix bcm_kona_gpio_reset() warnings The bcm_kona_gpio_reset() calls bcm_kona_gpio_write_lock_regs() with what looks like the wrong parameter. The write_lock_regs function takes a pointer to the registers, not the bcm_kona_gpio structure. Fix the warning, and probably bug by changing the function to pass reg_base instead of kona_gpio, fixing the following warning: drivers/gpio/gpio-bcm-kona.c:550:47: warning: incorrect type in argument 1 (different address spaces) expected void [noderef] *reg_base got struct bcm_kona_gpio *kona_gpio warning: incorrect type in argument 1 (different address spaces) expected void [noderef] *reg_base got struct bcm_kona_gpio *kona_gpio Cc: stable@vger.kernel.org Signed-off-by: Ben Dooks Acked-by: Ray Jui Reviewed-by: Markus Mayer Signed-off-by: Linus Walleij drivers/gpio/gpio-bcm-kona.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 96685a55a82c383cbba7ef1d4a636acf708cf17f Author: Borislav Petkov Date: Wed Jun 1 12:04:28 2016 +0200 x86/cpu/AMD: Extend X86_FEATURE_TOPOEXT workaround to newer models We need to reenable the topology extensions CPUID leafs on newer models too, if BIOS has disabled them, as we rely on them to get proper compute unit topology. Make the printk a once thing, while at it. Signed-off-by: Borislav Petkov Cc: Andy Lutomirski Cc: Borislav Petkov Cc: Brian Gerst Cc: Denys Vlasenko Cc: H. Peter Anvin Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Rui Huang Cc: Sherry Hurwitz Cc: Thomas Gleixner Cc: linux-hwmon@vger.kernel.org Link: http://lkml.kernel.org/r/1464775468-23355-1-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar arch/x86/kernel/cpu/amd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 60a5eaba46919f3a4c63a0c93bb7015ad5e56a82 Author: Linus Walleij Date: Wed Jun 8 13:45:08 2016 +0200 gpio: select ANON_INODES The build servers found that gpiolib is using ANON_INODES but has forgotten to select it. Fix this. Reported-by: kbuild test robot Fixes: 521a2ad6f862 ("gpio: add userspace ABI for GPIO line information") Signed-off-by: Linus Walleij drivers/gpio/Kconfig | 1 + 1 file changed, 1 insertion(+) commit d1e44b6b2823f1751ffe7e7589f545f05cfe2095 Author: Srinivas Kandagatla Date: Fri Jun 3 12:23:09 2016 +0100 regulator: qcom_smd: add regulator ops for pm8941 lnldo After "regulator: qcom_smd: add list_voltage callback" patch adding pm8941 lnldo regulators would bug on list_voltages as it is a fixed regulator without any linear range. This patch fixes that issue by adding dedicated ops for pm8941 lnldo without list_voltages callback. Signed-off-by: Srinivas Kandagatla Signed-off-by: Mark Brown Cc: stable@vger.kernel.org # v4.6 drivers/regulator/qcom_smd-regulator.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) commit a8a47540ebe32f1733eebc3e5699af580ceaa3f5 Author: Srinivas Kandagatla Date: Thu Jun 2 11:23:15 2016 +0100 regulator: qcom_smd: add list_voltage callback This patch adds support to list_voltage callback, so that consumers like mmc core, can get information of supported voltage range. Without this patch there is no way for mmc core to know this voltage range. Signed-off-by: Srinivas Kandagatla Signed-off-by: Mark Brown Cc: stable@vger.kernel.org # v4.6 drivers/regulator/qcom_smd-regulator.c | 1 + 1 file changed, 1 insertion(+) commit 4dc0dd83603f05dc3ae152af33ecb15104c313f3 Author: Tomeu Vizoso Date: Wed Jun 8 09:32:51 2016 +0200 spi: rockchip: Signal unfinished DMA transfers When using DMA, the transfer_one callback should return 1 because the transfer hasn't finished yet. A previous commit changed the function to return 0 when the DMA channels were correctly prepared. This manifested in Veyron boards with this message: [ 1.983605] cros-ec-spi spi0.0: EC failed to respond in time Fixes: ea9849113343 ("spi: rockchip: check return value of dmaengine_prep_slave_sg") Signed-off-by: Tomeu Vizoso Signed-off-by: Mark Brown Cc: stable@vger.kernel.org drivers/spi/spi-rockchip.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 970442c599b22ccd644ebfe94d1d303bf6f87c05 Author: Dave Hansen Date: Thu Jun 2 17:19:27 2016 -0700 x86/cpu/intel: Introduce macros for Intel family numbers Problem: We have a boatload of open-coded family-6 model numbers. Half of them have these model numbers in hex and the other half in decimal. This makes grepping for them tons of fun, if you were to try. Solution: Consolidate all the magic numbers. Put all the definitions in one header. The names here are closely derived from the comments describing the models from arch/x86/events/intel/core.c. We could easily make them shorter by doing things like s/SANDYBRIDGE/SNB/, but they seemed fine even with the longer versions to me. Do not take any of these names too literally, like "DESKTOP" or "MOBILE". These are all colloquial names and not precise descriptions of everywhere a given model will show up. Signed-off-by: Dave Hansen Cc: Adrian Hunter Cc: Andy Lutomirski Cc: Andy Lutomirski Cc: Borislav Petkov Cc: Brian Gerst Cc: Darren Hart Cc: Dave Hansen Cc: Denys Vlasenko Cc: Doug Thompson Cc: Eduardo Valentin Cc: H. Peter Anvin Cc: Jacob Pan Cc: Kan Liang Cc: Len Brown Cc: Linus Torvalds Cc: Mauro Carvalho Chehab Cc: Peter Zijlstra Cc: Rafael J. Wysocki Cc: Rajneesh Bhardwaj Cc: Souvik Kumar Chakravarty Cc: Srinivas Pandruvada Cc: Stephane Eranian Cc: Thomas Gleixner Cc: Tony Luck Cc: Ulf Hansson Cc: Viresh Kumar Cc: Vishwanath Somayaji Cc: Zhang Rui Cc: jacob.jun.pan@intel.com Cc: linux-acpi@vger.kernel.org Cc: linux-edac@vger.kernel.org Cc: linux-mmc@vger.kernel.org Cc: linux-pm@vger.kernel.org Cc: platform-driver-x86@vger.kernel.org Link: http://lkml.kernel.org/r/20160603001927.F2A7D828@viggo.jf.intel.com Signed-off-by: Ingo Molnar arch/x86/include/asm/intel-family.h | 68 +++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) commit 5ab92a7cb82c66bf30685583a38a18538e3807db Author: Linus Walleij Date: Wed Jun 8 10:29:48 2016 +0200 leds: handle suspend/resume in heartbeat trigger The following phenomena was observed: when suspending the system, sometimes the heartbeat LED was left on, glowing and wasting power while the rest of the system is asleep, also disturbing power dissapation measures on the odd suspend cycle when it's left on. Clearly this is not how we want the heartbeat trigger to work: it should turn off and leave the LED off during system suspend. This removes the heartbeat trigger when preparing suspend and restores it during resume. The trigger code will make sure all LEDs are left in OFF state after removing the trigger, and will re-enable the trigger on all LEDs after resuming. Cc: linux-pm@vger.kernel.org Signed-off-by: Linus Walleij Reviewed-by: Ulf Hansson Signed-off-by: Jacek Anaszewski drivers/leds/trigger/ledtrig-heartbeat.c | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 7cfe749fad5158247282f2fee30773fd454029ab Author: Tony Makkiel Date: Wed May 18 17:22:45 2016 +0100 leds: core: Fix brightness setting upon hardware blinking enabled Commit 76931edd54f8 ("leds: fix brightness changing when software blinking is active") changed the semantics of led_set_brightness() which according to the documentation should disable blinking upon any brightness setting. Moreover it made it different for soft blink case, where it was possible to change blink brightness, and for hardware blink case, where setting any brightness greater than 0 was ignored. While the change itself is against the documentation claims, it was driven also by the fact that timer trigger remained active after turning blinking off. Fixing that would have required major refactoring in the led-core, led-class, and led-triggers because of cyclic dependencies. Finally, it has been decided that allowing for brightness change during blinking is beneficial as it can be accomplished without disturbing blink rhythm. The change in brightness setting semantics will not affect existing LED class drivers that implement blink_set op thanks to the LED_BLINK_SW flag introduced by this patch. The flag state will be from now on checked in led_set_brightness() which will allow to distinguish between software and hardware blink mode. In the latter case the control will be passed directly to the drivers which apply their semantics on brightness set, which is disable the blinking in case of most such drivers. New drivers will apply new semantics and just change the brightness while hardware blinking is on, if possible. The issue was smuggled by subsequent LED core improvements, which modified the code that originally introduced the problem. Fixes: f1e80c07416a ("leds: core: Add two new LED_BLINK_ flags") Signed-off-by: Tony Makkiel Signed-off-by: Jacek Anaszewski Documentation/leds/leds-class.txt | 4 ++-- drivers/leds/led-core.c | 9 ++++++--- include/linux/leds.h | 23 ++++++++++++----------- 3 files changed, 20 insertions(+), 16 deletions(-) commit 0106d456c4cb1770253fefc0ab23c9ca760b43f7 Author: Will Deacon Date: Tue Jun 7 17:55:15 2016 +0100 arm64: mm: always take dirty state from new pte in ptep_set_access_flags Commit 66dbd6e61a52 ("arm64: Implement ptep_set_access_flags() for hardware AF/DBM") ensured that pte flags are updated atomically in the face of potential concurrent, hardware-assisted updates. However, Alex reports that: | This patch breaks swapping for me. | In the broken case, you'll see either systemd cpu time spike (because | it's stuck in a page fault loop) or the system hang (because the | application owning the screen is stuck in a page fault loop). It turns out that this is because the 'dirty' argument to ptep_set_access_flags is always 0 for read faults, and so we can't use it to set PTE_RDONLY. The failing sequence is: 1. We put down a PTE_WRITE | PTE_DIRTY | PTE_AF pte 2. Memory pressure -> pte_mkold(pte) -> clear PTE_AF 3. A read faults due to the missing access flag 4. ptep_set_access_flags is called with dirty = 0, due to the read fault 5. pte is then made PTE_WRITE | PTE_DIRTY | PTE_AF | PTE_RDONLY (!) 6. A write faults, but pte_write is true so we get stuck The solution is to check the new page table entry (as would be done by the generic, non-atomic definition of ptep_set_access_flags that just calls set_pte_at) to establish the dirty state. Cc: # 4.3+ Fixes: 66dbd6e61a52 ("arm64: Implement ptep_set_access_flags() for hardware AF/DBM") Reviewed-by: Catalin Marinas Reported-by: Alexander Graf Tested-by: Alexander Graf Signed-off-by: Will Deacon arch/arm64/mm/fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d4defe21c682c934a19fce1ba8b54b7bde61b08 Author: Linus Walleij Date: Wed Jun 8 10:58:20 2016 +0200 gpio: include in gpiolib-of When enabling the gpiolib for all archs a build robot came up with this: All errors (new ones prefixed by >>): drivers/gpio/gpiolib-of.c: In function 'of_mm_gpiochip_add_data': >> drivers/gpio/gpiolib-of.c:317:2: error: implicit declaration of function 'iounmap' [-Werror=implicit-function-declaration] iounmap(mm_gc->regs); ^~~~~~~ cc1: some warnings being treated as errors Fix this by including explicitly. Fixes: 296ad4acb8ef ("gpio: remove deps on ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB") Reported-by: kbuild test robot Signed-off-by: Linus Walleij drivers/gpio/gpiolib-of.c | 1 + 1 file changed, 1 insertion(+) commit f4833b8cc7edab57d3f3033e549111a546c2e02b Author: Ricardo Ribalda Delgado Date: Fri Jun 3 19:10:02 2016 +0200 gpiolib: Fix unaligned used of reference counters gpiolib relies on the reference counters to clean up the gpio_device structure. Although the number of get/put is properly aligned on gpiolib.c itself, it does not take into consideration how the referece counters are affected by other external functions such as cdev_add and device_add. Because of this, after the last call to put_device, the reference counter has a value of +3, therefore never calling gpiodevice_release. Due to the fact that some of the device has already been cleaned on gpiochip_remove, the library will end up OOPsing the kernel (e.g. a call to of_gpiochip_find_and_xlate). Cc: stable@vger.kernel.org Signed-off-by: Ricardo Ribalda Delgado Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 11f33a6d15bfa397867ac0d7f3481b6dd683286f Author: Ricardo Ribalda Delgado Date: Fri Jun 3 19:10:01 2016 +0200 gpiolib: Fix NULL pointer deference Under some circumstances, a gpiochip might be half cleaned from the gpio_device list. This patch makes sure that the chip pointer is still valid, before calling the match function. [ 104.088296] BUG: unable to handle kernel NULL pointer dereference at 0000000000000090 [ 104.089772] IP: [] of_gpiochip_find_and_xlate+0x15/0x80 [ 104.128273] Call Trace: [ 104.129802] [] ? of_parse_own_gpio+0x1f0/0x1f0 [ 104.131353] [] gpiochip_find+0x60/0x90 [ 104.132868] [] of_get_named_gpiod_flags+0x9a/0x120 ... [ 104.141586] [] gpio_led_probe+0x11b/0x360 Cc: stable@vger.kernel.org Signed-off-by: Ricardo Ribalda Delgado Signed-off-by: Linus Walleij drivers/gpio/gpiolib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0f84f29ff30bdb1bca23017b118b4ea3999cac32 Author: Helmut Grohne Date: Fri Jun 3 14:15:32 2016 +0200 gpio: zynq: initialize clock even without CONFIG_PM When the PM initialization was moved in the commit referenced below, the code enabling the clock was removed from the probe function. On CONFIG_PM=y kernels, this is not a problem as the pm resume hook enables the clock, but when power management is disabled, all those pm_* functions are noops and the clock is never enabled resulting in a dysfunctional gpio controller. Put the clock initialization back to support CONFIG_PM=n. Cc: stable@vger.kernel.org Signed-off-by: Helmut Grohne Fixes: 3773c195d387 ("gpio: zynq: Do PM initialization earlier to support gpio hogs") Signed-off-by: Linus Walleij drivers/gpio/gpio-zynq.c | 7 +++++++ 1 file changed, 7 insertions(+) commit d15d6cf91695674fbabac3b1d2c8a269d9bab5c6 Author: William Breathitt Gray Date: Thu Jun 2 16:00:09 2016 -0400 gpio: 104-dio-48e: Fix control port offset computation off-by-one error There are only two control ports, each controlling three distinct I/O ports. To compute the control port address offset for a respective I/O port, the I/O port address offset should be divided by 3; dividing by 2 may result in not only the wrong address offset but possibly also an out-of-bounds array memory access for a non-existent third control port. Fixes: 1b06d64f7374 ("gpio: Add GPIO support for the ACCES 104-DIO-48E") Signed-off-by: William Breathitt Gray Signed-off-by: Linus Walleij drivers/gpio/gpio-104-dio-48e.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 88832a22d6bb50e3b5f9d5ecc6cf26707c35f322 Author: Ben Dooks Date: Tue Jun 7 19:27:51 2016 +0100 net-sysfs: fix missing The of_find_net_device_by_node() function is defined in but not included in the .c file that implements it. Fix the following warning by including the header: net/core/net-sysfs.c:1494:19: warning: symbol 'of_find_net_device_by_node' was not declared. Should it be static? Signed-off-by: Ben Dooks Signed-off-by: David S. Miller net/core/net-sysfs.c | 1 + 1 file changed, 1 insertion(+) commit 0b148def403153a4d1565f1640356cb78ce5109f Author: Toshiaki Makita Date: Tue Jun 7 19:14:17 2016 +0900 bridge: Don't insert unnecessary local fdb entry on changing mac address The missing br_vlan_should_use() test caused creation of an unneeded local fdb entry on changing mac address of a bridge device when there is a vlan which is configured on a bridge port but not on the bridge device. Fixes: 2594e9064a57 ("bridge: vlan: add per-vlan struct and move to rhashtables") Signed-off-by: Toshiaki Makita Acked-by: Nikolay Aleksandrov Signed-off-by: David S. Miller net/bridge/br_fdb.c | 2 ++ 1 file changed, 2 insertions(+) commit 03cce00b4b0d70885c7a63ef17713b8cc2b1c8bd Merge: af8c34c 94bef00 Author: Greg Kroah-Hartman Date: Tue Jun 7 22:26:20 2016 -0700 Merge tag 'iio-fixes-for-4.7a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus Jonathan writes: First round of iio fixes for the 4.7 cycle. A slightly bumper set due to travel delaying the pull request and a fair few issues with the recent merge window patches. Patches all over the place. The st-sensors one is probably the most involved, but definitly solves the issues seen. Note there are some other issues around that handler (and the fact that a lot of boards tie a level interrupt chip to an edge interrupt only irq chip). These are not regressions however, so will turn up the slow route. * core - iio_trigger_attach_pollfunc had some really badly wrong error handling. Another nasty triggered whilst chasing down issues with the st sensors rework below. * ad5592r - fix an off by one error when allocating channels. * am2315 - a stray mutex unlock before we ever take the lock. * apds9960 - missing a parent in the driver model (which should be the i2c device). Result is it doesn't turn up under /sys/bus/i2c/devices which some userspace code uses for repeatable device identification. * as3935 - ABI usage bug which meant a processed value was reported as raw. Now reporting scale as well to ensure userspace has the info it needs. - Don't return processed value via the buffer - it doesn't conform to the ABI and will overflow in some cases. - Fix a wrongly sized buffer which would overflow trashing part of the stack. Also move it onto the heap as part of the fix. * bh1780 - a missing return after write in debugfs lead to an incorrect read and a null pointer dereference. - dereferencing the wrong pointer in suspend and resume leading to unpredictable results. - assign a static name to avoid accidentally ending up with no name if loaded via device tree. * bmi160 - output data rate for the accelerometer was incorrectly reported. Fix it. - writing the output data rate was also wrong due to reverse parameters. * bmp280 - error message for wrong chip ID gave the wrong expected value. * hdc100x - mask for writing the integration time was wrong allowin g us to get 'stuck' in a particular value with no way back. - temperature reported in celsius rather than millicelsius as per the ABI. - Get rid of some incorrect data shifting which lead to readings being rather incorrect. * max44000 - drop scale attribute for proximity as it is an unscaled value (depends on what is in range rather than anything knowable at the detector). * st-pressure - ABI compliance fixes - units were wrong. * st-sensors - We introduced some nasty issues with the recent switch over to a a somewhat threaded handler in that we broke using a software trigger with these devices. Now do it properly. It's a larger patch than ideal for a fix, but the logic is straight forward. - Make sure the trigger is initialized before requesting the interrupt. This matters now the interrupt can be shared. Before it was ugly and wrong but short of flakey hardware could not be triggered. - Hammer down the dataready pin at boot - otherwise with really unlucky timing things could get interestingly wedged requiring a hard power down of the chip. commit 11c011a5e777c83819078a18672543f04482b3ec Author: Srinivas Kandagatla Date: Thu May 19 11:12:56 2016 +0100 usb: echi-hcd: Add ehci_setup check before echi_shutdown This patch protects system from crashing at shutdown in cases where usb host is not added yet from OTG controller driver. As ehci_setup() not done yet, so stop accessing registers or variables initialized as part of ehci_setup(). The use case is simple, for boards like DB410c where the usb host or device functionality is decided based on the micro-usb cable presence. If the board boots up with micro-usb connected, the OTG driver like echi-msm would not add the usb host by default. However a system shutdown would go and access registers and uninitialized variables, resulting in below crash. Unable to handle kernel NULL pointer dereference at virtual address 00000008 pgd = ffffffc034581000 [00000008] *pgd=0000000000000000, *pud=0000000000000000 CPU: 2 PID: 1957 Comm: reboot Not tainted 4.6.0+ #99 task: ffffffc034bc0000 ti: ffffffc0345cc000 task.ti: ffffffc0345cc000 PC is at ehci_halt+0x54/0x108 LR is at ehci_halt+0x38/0x108 pc : [] lr : [] pstate: a00001c5 sp : ffffffc0345cfc60 x29: ffffffc0345cfc60 x28: ffffffc0345cc000 x27: ffffff8008a4d000 x26: 000000000000008e x25: ffffff8008d86cb0 x24: ffffff800908b040 x23: ffffffc036068870 x22: ffffff8009d0a000 x21: ffffffc03512a410 x20: ffffffc03512a410 x19: ffffffc03512a338 x18: 00000000000065ba x17: ffffff8009b16b80 x16: 0000000000000003 x15: 00000000000065b9 x14: 00000000000065b6 x13: 0000000000000000 x12: 0000000000000000 x11: 000000000000003d x10: ffffffc0345cf9e0 x9 : 0000000000000001 x8 : ffffffc0345cc000 x7 : ffffff8008698360 x6 : 0000000000000000 x5 : 0000000000000080 x4 : 0000000000000001 x3 : 0000000000000000 x2 : 0000000000000000 x1 : 0000000000000008 x0 : ffffffc034bc0000 Process reboot (pid: 1957, stack limit = 0xffffffc0345cc020) Stack: (0xffffffc0345cfc60 to 0xffffffc0345d0000) fc60: ffffffc0345cfc90 ffffff8008698448 ffffffc03512a338 ffffffc03512a338 fc80: ffffffc03512a410 ffffff8008a3bbfc ffffffc0345cfcc0 ffffff8008698548 fca0: ffffffc03512a338 ffffffc03512a000 ffffffc03512a410 ffffff8009d0a000 fcc0: ffffffc0345cfcf0 ffffff800865d2bc ffffffc036068828 ffffffc036068810 fce0: ffffffc036003810 ffffff800853f43c ffffffc0345cfd00 ffffff800854338c fd00: ffffffc0345cfd10 ffffff800853f45c ffffffc0345cfd60 ffffff80080e0f48 fd20: 0000000000000000 0000000001234567 ffffff8008f8c000 ffffff8008f8c060 fd40: 0000000000000000 0000000000000015 0000000000000120 ffffff80080e0f30 fd60: ffffffc0345cfd70 ffffff80080e1020 ffffffc0345cfd90 ffffff80080e12fc fd80: 0000000000000000 0000000001234567 0000000000000000 ffffff8008085e70 fda0: 0000000000000000 0000005592905000 ffffffffffffffff 0000007f79daf1cc fdc0: 0000000000000000 0000000000000000 0000007ffcbb1198 000000000000000a fde0: 00000055928d3f58 0000000000000001 ffffffc034900000 00000000fffffffe fe00: ffffffc034900000 0000007f79da902c ffffffc0345cfe40 ffffff800820af38 fe20: 0000000000000000 0000007ffcbb1078 ffffffffffffffff ffffff80081e9b38 fe40: ffffffc0345cfe60 ffffff80081eb410 ffffffc0345cfe60 ffffff80081eb444 fe60: ffffffc0345cfec0 ffffff80081ec4f4 0000000000000000 0000007ffcbb1078 fe80: ffffffffffffffff 0000000000000015 ffffffc0345cfec0 0000007ffcbb1078 fea0: 0000000000000002 000000000000000a ffffffffffffffff 0000000000000000 fec0: 0000000000000000 ffffff8008085e70 fffffffffee1dead 0000000028121969 fee0: 0000000001234567 0000000000000000 ffffffffffffffff 8080800000800000 ff00: 0000800000808080 0000007ffcbb10f0 000000000000008e fefeff54918cb8c7 ff20: 7f7f7f7fffffffff 0101010101010101 0000000000000010 0000000000000000 ff40: 0000000000000000 0000007f79e33588 0000005592905eb8 0000007f79daf1b0 ff60: 0000007ffcbb1340 0000005592906000 0000005592905000 0000005592906000 ff80: 0000005592907000 0000000000000002 0000007ffcbb1d98 0000005592906000 ffa0: 00000055928d2000 0000000000000000 0000000000000000 0000007ffcbb1aa0 ffc0: 00000055928b819c 0000007ffcbb1aa0 0000007f79daf1cc 0000000000000000 ffe0: fffffffffee1dead 000000000000008e 05ef555057155555 d555544d55d775d3 Call trace: Exception stack(0xffffffc0345cfaa0 to 0xffffffc0345cfbc0) Set corner to 6 faa0: ffffffc03512a338 ffffffc03512a410 ffffffc0345cfc60 ffffff800869837c fac0: ffffff8008114210 0000000100000001 ffffff8009ce1b20 ffffff8009ce5f20 fae0: ffffffc0345cfb80 ffffff80081145a8 ffffffc0345cfc10 ffffff800810b924 fb00: ffffffc0345cc000 00000000000001c0 ffffffc03512a410 ffffff8009d0a000 fb20: ffffffc036068870 ffffff800908b040 ffffff8008d86cb0 000000000000008e fb40: ffffffc034bc0000 0000000000000008 0000000000000000 0000000000000000 fb60: 0000000000000001 0000000000000080 0000000000000000 ffffff8008698360 fb80: ffffffc0345cc000 0000000000000001 ffffffc0345cf9e0 000000000000003d fba0: 0000000000000000 0000000000000000 00000000000065b6 00000000000065b9 [] ehci_halt+0x54/0x108 [] ehci_silence_controller+0x18/0xcc [] ehci_shutdown+0x4c/0x64 [] usb_hcd_platform_shutdown+0x1c/0x24 [] platform_drv_shutdown+0x20/0x28 [] device_shutdown+0xf4/0x1b0 [] kernel_restart_prepare+0x34/0x3c [] kernel_restart+0x14/0x74 [] SyS_reboot+0x110/0x21c [] el0_svc_naked+0x24/0x28 Code: 53001c42 350000a2 d5033e9f 91002021 (b9000022) Fixes 4bb3cad7125b ("usb: host: ehci-msm: Register usb shutdown function") Signed-off-by: Srinivas Kandagatla Tested-by: Pramod Gurav Tested-by: Andy Gross Acked-by: Alan Stern Signed-off-by: Greg Kroah-Hartman drivers/usb/host/ehci-hcd.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 815c9d6a3caeb803ae36d09788c8969b85ce7e4c Author: Andy Gross Date: Fri May 20 16:35:07 2016 -0500 usb: host: ehci-msm: Conditionally call ehci suspend/resume This patch fixes a suspend/resume issue where the driver is blindly calling ehci_suspend/resume functions when the ehci hasn't been setup. This results in a crash during suspend/resume operations. Signed-off-by: Andy Gross Tested-by: Pramod Gurav Acked-by: Alan Stern Signed-off-by: Greg Kroah-Hartman drivers/usb/host/ehci-msm.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 1700bd9872dcd06a284c38c1ce33bba0f239dbd3 Author: Geert Uytterhoeven Date: Sun May 22 11:06:26 2016 +0200 MAINTAINERS: Add file patterns for usb device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven Cc: Greg Kroah-Hartman Cc: linux-usb@vger.kernel.org Signed-off-by: Greg Kroah-Hartman MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 7cc9ca5a994c90fa771135e50b7a9cb99a65aa1d Author: Thierry Reding Date: Thu May 26 17:23:30 2016 +0200 usb: host: ehci-tegra: Avoid getting the same reset twice Starting with commit 0b52297f2288 ("reset: Add support for shared reset controls") there is a reference count for reset control assertions. The goal is to allow resets to be shared by multiple devices and an assert will take effect only when all instances have asserted the reset. In order to preserve backwards-compatibility, all reset controls become exclusive by default. This is to ensure that reset_control_assert() can immediately assert in hardware. However, this new behaviour triggers the following warning in the EHCI driver for Tegra: [ 3.365019] ------------[ cut here ]------------ [ 3.369639] WARNING: CPU: 0 PID: 1 at drivers/reset/core.c:187 __of_reset_control_get+0x16c/0x23c [ 3.382151] Modules linked in: [ 3.385214] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.6.0-rc6-next-20160503 #140 [ 3.392769] Hardware name: NVIDIA Tegra SoC (Flattened Device Tree) [ 3.399046] [] (unwind_backtrace) from [] (show_stack+0x10/0x14) [ 3.406787] [] (show_stack) from [] (dump_stack+0x90/0xa4) [ 3.414007] [] (dump_stack) from [] (__warn+0xe8/0x100) [ 3.420964] [] (__warn) from [] (warn_slowpath_null+0x20/0x28) [ 3.428525] [] (warn_slowpath_null) from [] (__of_reset_control_get+0x16c/0x23c) [ 3.437648] [] (__of_reset_control_get) from [] (tegra_ehci_probe+0x394/0x518) [ 3.446600] [] (tegra_ehci_probe) from [] (platform_drv_probe+0x4c/0xb0) [ 3.455029] [] (platform_drv_probe) from [] (driver_probe_device+0x1ec/0x330) [ 3.463892] [] (driver_probe_device) from [] (__driver_attach+0xb8/0xbc) [ 3.472320] [] (__driver_attach) from [] (bus_for_each_dev+0x68/0x9c) [ 3.480489] [] (bus_for_each_dev) from [] (bus_add_driver+0x1a0/0x218) [ 3.488743] [] (bus_add_driver) from [] (driver_register+0x78/0xf8) [ 3.496738] [] (driver_register) from [] (do_one_initcall+0x40/0x170) [ 3.504909] [] (do_one_initcall) from [] (kernel_init_freeable+0x158/0x1f8) [ 3.513600] [] (kernel_init_freeable) from [] (kernel_init+0x8/0x114) [ 3.521770] [] (kernel_init) from [] (ret_from_fork+0x14/0x3c) [ 3.529361] ---[ end trace 4bda87dbe4ecef8a ]--- The reason is that Tegra SoCs have three EHCI controllers, each with a separate reset line. However the first controller contains UTMI pads configuration registers that are shared with its siblings and that are reset as part of the first controller's reset. There is special code in the driver to assert and deassert this shared reset at probe time, and it does so irrespective of which controller is probed first to ensure that these shared registers are reset before any of the controllers are initialized. Unfortunately this means that if the first controller gets probed first, it will request its own reset line and will subsequently request the same reset line again (temporarily) to perform the reset. This used to work fine before the above-mentioned commit, but now triggers the new WARN. Work around this by making sure we reuse the controller's reset if the controller happens to be the first controller. Cc: Philipp Zabel Cc: Hans de Goede Reviewed-by: Philipp Zabel Signed-off-by: Thierry Reding Signed-off-by: Greg Kroah-Hartman drivers/usb/host/ehci-tegra.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit f8a15a9650694feaa0dabf197b0c94d37cd3fb42 Author: Thierry Reding Date: Thu May 26 17:23:29 2016 +0200 usb: host: ehci-tegra: Grab the correct UTMI pads reset There are three EHCI controllers on Tegra SoCs, each with its own reset line. However, the first controller contains a set of UTMI configuration registers that are shared with its siblings. These registers will only be reset as part of the first controller's reset. For proper operation it must be ensured that the UTMI configuration registers are reset before any of the EHCI controllers are enabled, irrespective of the probe order. Commit a47cc24cd1e5 ("USB: EHCI: tegra: Fix probe order issue leading to broken USB") introduced code that ensures the first controller is always reset before setting up any of the controllers, and is never again reset afterwards. This code, however, grabs the wrong reset. Each EHCI controller has two reset controls attached: 1) the USB controller reset and 2) the UTMI pads reset (really the first controller's reset). In order to reset the UTMI pads registers the code must grab the second reset, but instead it grabbing the first. Fixes: a47cc24cd1e5 ("USB: EHCI: tegra: Fix probe order issue leading to broken USB") Acked-by: Jon Hunter Cc: stable@vger.kernel.org Signed-off-by: Thierry Reding Signed-off-by: Greg Kroah-Hartman drivers/usb/host/ehci-tegra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dcb21ad4385731b7fc3ef39d255685f2f63c8c5d Author: Sudip Mukherjee Date: Mon May 30 19:16:33 2016 +0530 USB: mos7720: delete parport parport subsystem has introduced parport_del_port() to delete a port when it is going away. Without parport_del_port() the registered port will not be unregistered. To reproduce and verify the error: Command to be used is : ls /sys/bus/parport/devices 1) without the device attached there is no output as there is no registered parport. 2) Attach the device, and the command will show "parport0". 3) Remove the device and the command still shows "parport0". 4) Attach the device again and we get "parport1". With the patch applied: 1) without the device attached there is no output as there is no registered parport. 2) Attach the device, and the command will show "parport0". 3) Remove the device and there is no output as "parport0" is now removed. 4) Attach device again to get "parport0" again. Cc: # 4.2+ Signed-off-by: Sudip Mukherjee Signed-off-by: Greg Kroah-Hartman drivers/usb/serial/mos7720.c | 1 + 1 file changed, 1 insertion(+) commit c66f59ee5050447b3da92d36f5385a847990a894 Author: Michał Pecio Date: Tue Jun 7 12:34:45 2016 +0200 USB: OHCI: Don't mark EDs as ED_OPER if scheduling fails Since ed_schedule begins with marking the ED as "operational", the ED may be left in such state even if scheduling actually fails. This allows future submission attempts to smuggle this ED to the hardware behind the scheduler's back and without linking it to the ohci->eds_in_use list. The former causes bandwidth saturation and data loss on isoc endpoints, the latter crashes the kernel when attempt is made to unlink such ED from this list. Fix ed_schedule to update ED state only on successful return. Signed-off-by: Michal Pecio Acked-by: Alan Stern Signed-off-by: Greg Kroah-Hartman drivers/usb/host/ohci-q.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 3b6d1eb7ea65f4aa64115cf9ba02c190e5c9f6de Author: Aneesh Kumar K.V Date: Thu May 19 13:24:30 2016 +0530 powerpc/mm/hash: Compute the segment size correctly for ISA 3.0 PowerISA 3.0 encodes the segment size in the second half of hash page table entry. Update hpte_decode() accordingly. Fixes: 50de596de8be ("powerpc/mm/hash: Add support for Power9 Hash") Signed-off-by: Aneesh Kumar K.V Signed-off-by: Michael Ellerman arch/powerpc/mm/hash_native_64.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 9690c15742688e9cb5ee4aa0b08e458551ceea13 Author: Aneesh Kumar K.V Date: Thu Jun 2 15:14:48 2016 +0530 powerpc/mm/radix: Fix always false comparison against MMU_NO_CONTEXT In some of the radix TLB flush routines, we use a local to store the mm->context.id, AKA the PID. Currently we use an int, but the PID is unsigned long, so large values of PID will be truncated. In particular MMU_NO_CONTEXT is -1, which means all our comparisons against that value can never be true. This means we'll issue TLB flushes when we shouldn't on radix enabled machines. Fix it by using an unsigned long for the local. Discovered by Coverity. Fixes: 1a472c9dba6b ("powerpc/mm/radix: Add tlbflush routines") Signed-off-by: Aneesh Kumar K.V Reviewed-by: Balbir Singh [mpe: Write change log] Signed-off-by: Michael Ellerman arch/powerpc/mm/tlb-radix.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c8ae067f2635be0f8c7e5db1bb74b757d623e05b Merge: 2051877 1607f09 Author: Linus Torvalds Date: Tue Jun 7 20:41:36 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs fixes from Al Viro: "Fixes for crap of assorted ages: EOPENSTALE one is 4.2+, autofs one is 4.6, d_walk - 3.2+. The atomic_open() and coredump ones are regressions from this window" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: coredump: fix dumping through pipes fix a regression in atomic_open() fix d_walk()/non-delayed __d_free() race autofs braino fix for do_last() fix EOPENSTALE bug in do_last() commit 38bab98a8da4a2ff5c3f55b045b0c8bf6901362f Author: Wolfram Sang Date: Sun Jun 5 09:35:43 2016 +0200 hwmon: (lm90) use proper type for update_interval The code handles this variable always as unsigned, so adapt the type. Signed-off-by: Wolfram Sang Signed-off-by: Guenter Roeck drivers/hwmon/lm90.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1069ad8f65a474bb30a487a001511b25f3575f5e Author: Krzysztof Kozlowski Date: Wed Jun 1 11:43:12 2016 +0200 hwmon: (ina2xx) Document compatible for INA231 Document the compatible for INA231 sensor. Signed-off-by: Krzysztof Kozlowski Acked-by: Rob Herring Signed-off-by: Guenter Roeck Documentation/devicetree/bindings/hwmon/ina2xx.txt | 1 + 1 file changed, 1 insertion(+) commit 7be4881846cfa67f968eaf5b7b50d9623a652afb Author: Borislav Petkov Date: Wed Jun 1 11:36:13 2016 +0200 hwmon: (fam15h_power) Disable preemption when reading registers We need to read a bunch of registers on each compute unit and possibly on the current CPU too. Disable preemption around it. Otherwise, you get: BUG: using smp_processor_id() in preemptible [00000000] code: systemd-udevd/327 caller is read_registers+0x6a/0x110 [fam15h_power] CPU: 3 PID: 327 Comm: systemd-udevd Not tainted 4.7.0-rc1+ #4 Hardware name: HP HP EliteBook 745 G3/807E, BIOS N73 Ver. 01.08 01/28/2016 ... Suggested-by: Thomas Gleixner Signed-off-by: Borislav Petkov Cc: Rui Huang Cc: Sherry Hurwitz Cc: Guenter Roeck Acked-by: Huang Rui Tested-by: Huang Rui Fixes: fa7943449943 ("hwmon: (fam15h_power) Add compute unit accumulated power") Signed-off-by: Guenter Roeck drivers/hwmon/fam15h_power.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 1607f09c226d1378439c411baaaa020042750338 Author: Mateusz Guzik Date: Sun Jun 5 23:14:14 2016 +0200 coredump: fix dumping through pipes The offset in the core file used to be tracked with ->written field of the coredump_params structure. The field was retired in favour of file->f_pos. However, ->f_pos is not maintained for pipes which leads to breakage. Restore explicit tracking of the offset in coredump_params. Introduce ->pos field for this purpose since ->written was already reused. Fixes: a00839395103 ("get rid of coredump_params->written"). Reported-by: Zbigniew Jędrzejewski-Szmek Signed-off-by: Mateusz Guzik Reviewed-by: Omar Sandoval Signed-off-by: Al Viro arch/powerpc/platforms/cell/spufs/coredump.c | 2 +- fs/binfmt_elf.c | 2 +- fs/binfmt_elf_fdpic.c | 2 +- fs/coredump.c | 4 +++- include/linux/binfmts.h | 1 + 5 files changed, 7 insertions(+), 4 deletions(-) commit a01e718f7241c53f564402f7acff373eed5bd166 Author: Al Viro Date: Tue Jun 7 21:53:51 2016 -0400 fix a regression in atomic_open() open("/foo/no_such_file", O_RDONLY | O_CREAT) on should fail with EACCES when /foo is not writable; failing with ENOENT is obviously wrong. That got broken by a braino introduced when moving the creat_error logics from atomic_open() to lookup_open(). Easy to fix, fortunately. Spotted-by: "Yan, Zheng" Tested-by: "Yan, Zheng" Signed-off-by: Al Viro fs/namei.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 3d56c25e3bb0726a5c5e16fc2d9e38f8ed763085 Author: Al Viro Date: Tue Jun 7 21:26:55 2016 -0400 fix d_walk()/non-delayed __d_free() race Ascend-to-parent logics in d_walk() depends on all encountered child dentries not getting freed without an RCU delay. Unfortunately, in quite a few cases it is not true, with hard-to-hit oopsable race as the result. Fortunately, the fix is simiple; right now the rule is "if it ever been hashed, freeing must be delayed" and changing it to "if it ever had a parent, freeing must be delayed" closes that hole and covers all cases the old rule used to cover. Moreover, pipes and sockets remain _not_ covered, so we do not introduce RCU delay in the cases which are the reason for having that delay conditional in the first place. Cc: stable@vger.kernel.org # v3.2+ (and watch out for __d_materialise_dentry()) Signed-off-by: Al Viro fs/dcache.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 983e600e88835f0321d1a0ea06f52d48b7b5a544 Author: Srinivas Pandruvada Date: Tue Jun 7 17:38:53 2016 -0700 cpufreq: intel_pstate: Fix ->set_policy() interface for no_turbo When turbo is disabled, the ->set_policy() interface is broken. For example, when turbo is disabled and cpuinfo.max = 2900000 (full max turbo frequency), setting the limits results in frequency less than the requested one: Set 1000000 KHz results in 0700000 KHz Set 1500000 KHz results in 1100000 KHz Set 2000000 KHz results in 1500000 KHz This is because the limits->max_perf fraction is calculated using the max turbo frequency as the reference, but when the max P-State is capped in intel_pstate_get_min_max(), the reference is not the max turbo P-State. This results in reducing max P-State. One option is to always use max turbo as reference for calculating limits. But this will not be correct. By definition the intel_pstate sysfs limits, shows percentage of available performance. So when BIOS has disabled turbo, the available performance is max non turbo. So the max_perf_pct should still show 100%. Signed-off-by: Srinivas Pandruvada [ rjw : Subject & changelog, rewrite in fewer lines of code ] Cc: All applicable Signed-off-by: Rafael J. Wysocki drivers/cpufreq/intel_pstate.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 2c2c1af4497514da1be2b571066859701dd79231 Author: Srinivas Pandruvada Date: Tue Jun 7 17:38:52 2016 -0700 cpufreq: intel_pstate: Fix code ordering in intel_pstate_set_policy() The limits->max_perf is rounded_up but immediately overwritten by another assignment to limits->max_perf. Move that operation to the correct location. While here also added a pr_debug() call in ->set_policy to aid in debugging. Fixes: 785ee2788141 (cpufreq: intel_pstate: Fix limits->max_perf rounding error) Signed-off-by: Srinivas Pandruvada [ rjw : Subject & changelog ] Cc: 4.4+ # 4.4+ Signed-off-by: Rafael J. Wysocki drivers/cpufreq/intel_pstate.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit b3c0a4dab7e35a9b6d69c0415641d2280fdefb2b Author: Wolfram Sang Date: Mon Jun 6 18:48:38 2016 +0200 of: fix autoloading due to broken modalias with no 'compatible' Because of an improper dereference, a stray 'C' character was output to the modalias when no 'compatible' was specified. This is the case for some old PowerMac drivers which only set the 'name' property. Fix it to let them match again. Reported-by: Mathieu Malaterre Signed-off-by: Wolfram Sang Tested-by: Mathieu Malaterre Cc: Philipp Zabel Cc: Andreas Schwab Fixes: 6543becf26fff6 ("mod/file2alias: make modalias generation safe for cross compiling") Cc: stable@vger.kernel.org # v3.9+ Signed-off-by: Michael Ellerman scripts/mod/file2alias.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2c2a63e301fd19ccae673e79de59b30a232ff7f9 Author: Michael Ellerman Date: Wed Jun 8 10:01:23 2016 +1000 powerpc/pseries: Fix IBM_ARCH_VEC_NRCORES_OFFSET since POWER8NVL was added The recent commit 7cc851039d64 ("powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call") added a new PVR mask & value to the start of the ibm_architecture_vec[] array. However it missed the fact that further down in the array, we hard code the offset of one of the fields, and then at boot use that value to patch the value in the array. This means every update to the array must also update the #define, ugh. This means that on pseries machines we will misreport to firmware the number of cores we support, by a factor of threads_per_core. Fix it for now by updating the #define. Fixes: 7cc851039d64 ("powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call") Cc: stable@vger.kernel.org # v4.0+ Signed-off-by: Michael Ellerman arch/powerpc/kernel/prom_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 32565644580de57e67b700f7ddbf658e0fc43a35 Merge: ce3cf4e 3ec10d3 Author: David S. Miller Date: Tue Jun 7 17:14:10 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf Pablo Neira Ayuso says: ==================== Netfilter/IPVS fixes for net The following patchset contains two Netfilter/IPVS fixes for your net tree, they are: 1) Fix missing alignment in next offset calculation for standard targets, introduced in the previous merge window, patch from Florian Westphal. 2) Fix to correct the handling of outgoing connections which use the SIP-pe such that the binding of a real-server is updated when needed. This was an omission from changes introduced by Marco Angaroni in the previous merge window too, to allow handling of outgoing connections by the SIP-pe. Patch and report came via Simon Horman. ==================== Signed-off-by: David S. Miller commit ce3cf4ec0305919fc69a972f6c2b2efd35d36abc Author: Yuchung Cheng Date: Mon Jun 6 15:07:18 2016 -0700 tcp: record TLP and ER timer stats in v6 stats The v6 tcp stats scan do not provide TLP and ER timer information correctly like the v4 version . This patch fixes that. Fixes: 6ba8a3b19e76 ("tcp: Tail loss probe (TLP)") Fixes: eed530b6c676 ("tcp: early retransmit") Signed-off-by: Yuchung Cheng Signed-off-by: Neal Cardwell Signed-off-by: David S. Miller net/ipv6/tcp_ipv6.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 92c075dbdeed02bdf293cb0f513bad70aa714b8d Author: Daniel Borkmann Date: Mon Jun 6 22:50:39 2016 +0200 net: sched: fix tc_should_offload for specific clsact classes When offloading classifiers such as u32 or flower to hardware, and the qdisc is clsact (TC_H_CLSACT), then we need to differentiate its classes, since not all of them handle ingress, therefore we must leave those in software path. Add a .tcf_cl_offload() callback, so we can generically handle them, tested on ixgbe. Fixes: 10cbc6843446 ("net/sched: cls_flower: Hardware offloaded filters statistics support") Fixes: 5b33f48842fa ("net/flower: Introduce hardware offload support") Fixes: a1b7c5fd7fe9 ("net: sched: add cls_u32 offload hooks for netdevs") Signed-off-by: Daniel Borkmann Acked-by: John Fastabend Signed-off-by: David S. Miller include/net/pkt_cls.h | 10 +++++++--- include/net/sch_generic.h | 1 + net/sched/cls_flower.c | 6 +++--- net/sched/cls_u32.c | 8 ++++---- net/sched/sch_ingress.c | 12 ++++++++++++ 5 files changed, 27 insertions(+), 10 deletions(-) commit a03e6fe569713fb3ff0714f8fd7c8785c0ca9e22 Author: WANG Cong Date: Mon Jun 6 09:54:30 2016 -0700 act_police: fix a crash during removal The police action is using its own code to initialize tcf hash info, which makes us to forgot to initialize a->hinfo correctly. Fix this by calling the helper function tcf_hash_create() directly. This patch fixed the following crash: BUG: unable to handle kernel NULL pointer dereference at 0000000000000028 IP: [] __lock_acquire+0xd3/0xf91 PGD d3c34067 PUD d3e18067 PMD 0 Oops: 0000 [#1] SMP CPU: 2 PID: 853 Comm: tc Not tainted 4.6.0+ #87 Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 task: ffff8800d3e28040 ti: ffff8800d3f6c000 task.ti: ffff8800d3f6c000 RIP: 0010:[] [] __lock_acquire+0xd3/0xf91 RSP: 0000:ffff88011b203c80 EFLAGS: 00010002 RAX: 0000000000000046 RBX: 0000000000000000 RCX: 0000000000000000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000028 RBP: ffff88011b203d40 R08: 0000000000000001 R09: 0000000000000000 R10: ffff88011b203d58 R11: ffff88011b208000 R12: 0000000000000001 R13: ffff8800d3e28040 R14: 0000000000000028 R15: 0000000000000000 FS: 0000000000000000(0000) GS:ffff88011b200000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000028 CR3: 00000000d4be1000 CR4: 00000000000006e0 Stack: ffff8800d3e289c0 0000000000000046 000000001b203d60 ffffffff00000000 0000000000000000 ffff880000000000 0000000000000000 ffffffff00000000 ffffffff8187142c ffff88011b203ce8 ffff88011b203ce8 ffffffff8101dbfc Call Trace: [] ? __tcf_hash_release+0x77/0xd1 [] ? native_sched_clock+0x1a/0x35 [] ? native_sched_clock+0x1a/0x35 [] ? sched_clock_local+0x11/0x78 [] ? mark_lock+0x24/0x201 [] lock_acquire+0x120/0x1b4 [] ? lock_acquire+0x120/0x1b4 [] ? __tcf_hash_release+0x77/0xd1 [] _raw_spin_lock_bh+0x3c/0x72 [] ? __tcf_hash_release+0x77/0xd1 [] __tcf_hash_release+0x77/0xd1 [] tcf_action_destroy+0x49/0x7c [] tcf_exts_destroy+0x20/0x2d [] u32_destroy_key+0x1b/0x4d [] u32_delete_key_freepf_rcu+0x1b/0x1d [] rcu_process_callbacks+0x610/0x82e [] ? u32_destroy_key+0x4d/0x4d [] __do_softirq+0x191/0x3f4 Fixes: ddf97ccdd7cb ("net_sched: add network namespace support for tc actions") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/act_police.c | 33 +++++++++++---------------------- 1 file changed, 11 insertions(+), 22 deletions(-) commit aafddbf0cffeb790f919436285328c762279b5d4 Author: Eric Dumazet Date: Mon Jun 6 09:12:39 2016 -0700 fq_codel: return non zero qlen in class dumps We properly scan the flow list to count number of packets, but John passed 0 to gnet_stats_copy_queue() so we report a zero value to user space instead of the result. Fixes: 640158536632 ("net: sched: restrict use of qstats qlen") Signed-off-by: Eric Dumazet Cc: John Fastabend Acked-by: John Fastabend Signed-off-by: David S. Miller net/sched/sch_fq_codel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 064d5e6f8eedb071b81b72186f986fa390f7b164 Merge: 7b01b8e d47a0f3 Author: David S. Miller Date: Tue Jun 7 16:27:15 2016 -0700 Merge branch 'u32-hwoffload-fixes' Jakub Kicinski says: ==================== cls_u32 hardware offload fixes This set fixes two small issues with error codes I noticed in cls_u32. Second patch could be viewed as user space API change but that portion of API is not part of any release, yet. Compile tested only. ==================== Signed-off-by: David S. Miller commit d47a0f387fe907bdb0430a398850c1cb80eb7def Author: Jakub Kicinski Date: Mon Jun 6 16:16:48 2016 +0100 net: cls_u32: be more strict about skip-sw flag Return an error if user requested skip-sw and the underlaying hardware cannot handle tc offloads (or offloads are disabled). Signed-off-by: Jakub Kicinski Signed-off-by: David S. Miller net/sched/cls_u32.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit 1a0f7d2984f3864e64a43714b4a0999b5a27cff5 Author: Jakub Kicinski Date: Mon Jun 6 16:16:47 2016 +0100 net: cls_u32: fix error code for invalid flags 'err' variable is not set in this test, we would return whatever previous test set 'err' to. Signed-off-by: Jakub Kicinski Acked-by: Sridhar Samudrala Acked-by: John Fastabend Signed-off-by: David S. Miller net/sched/cls_u32.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7b01b8e847d00cf9cf0c2c3aa8fdfc4126dca024 Author: Colin Ian King Date: Mon Jun 6 16:08:41 2016 +0100 gtp: #define _UAPI_LINUX_GTP_H_ and not _UAPI_LINUX_GTP_H__ Fix clang build warning: ./include/uapi/linux/gtp.h:1:9: warning: '_UAPI_LINUX_GTP_H_' is used as a header guard here, followed by #define of a different macro [-Wheader-guard] fix by defining _UAPI_LINUX_GTP_H_ and not _UAPI_LINUX_GTP_H__ Signed-off-by: Colin Ian King Acked-by: Pablo Neira Ayuso Signed-off-by: David S. Miller include/uapi/linux/gtp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2051877c4c8526abc0a1d514e76f95610b4ab8f3 Merge: 43c082e 72ad679 Author: Linus Torvalds Date: Tue Jun 7 16:24:44 2016 -0700 Merge tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk fixes from Stephen Boyd: "This finally removes the CLK_IS_ROOT flag by picking up the last few stragglers that didn't get merged by anyone this time around. Better to do it now than wait for another one to pop up. There's also a minor maintainers update and a Kconfig fix" * tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: clk: nxp: Select MFD_SYSCON for creg driver MAINTAINERS: Add file patterns for clock device tree bindings clk: Remove CLK_IS_ROOT flag clk: microchip: Remove CLK_IS_ROOT powerpc/512x: clk: Remove CLK_IS_ROOT vexpress/spc: Remove CLK_IS_ROOT commit 9f647a6de9926f4844feb8c5e21c78d4e61c55ab Author: Colin Ian King Date: Mon Jun 6 09:21:44 2016 +0100 net: fec: fix spelling mistakes and add missing newline trivial fix to spelling mistakes and add missing newline in pr_err messages Signed-off-by: Colin Ian King Acked-by: Fugang Duan Signed-off-by: David S. Miller drivers/net/ethernet/freescale/fec_main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 71743ffa15b1822d10dc6320fbc2272a086a99c2 Merge: fa54cc7 8852ddb Author: David S. Miller Date: Tue Jun 7 16:02:04 2016 -0700 Merge branch 'bnxt_en-fixes' Michael Chan says: ==================== bnxt_en: Bug fixes. Fix a race condition and VLAN rx acceleration logic. ==================== Signed-off-by: David S. Miller commit 8852ddb4dcdfe6f877a02f79bf2bca9ae63c039a Author: Michael Chan Date: Mon Jun 6 02:37:16 2016 -0400 bnxt_en: Simplify VLAN receive logic. Since both CTAG and STAG rx acceleration must be enabled together, we only need to check one feature flag (NETIF_F_HW_VLAN_CTAG_RX) before calling __vlan_hwaccel_put_tag(). Signed-off-by: Michael Chan Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bnxt/bnxt.c | 29 +++++++++-------------------- 1 file changed, 9 insertions(+), 20 deletions(-) commit 5a9f6b238e59bc05afb4cdeaf3672990bf2a5309 Author: Michael Chan Date: Mon Jun 6 02:37:15 2016 -0400 bnxt_en: Enable and disable RX CTAG and RX STAG VLAN acceleration together. The hardware can only be set to strip or not strip both the VLAN CTAG and STAG. It cannot strip one and not strip the other. Add logic to bnxt_fix_features() to toggle both feature flags when the user is toggling one of them. Signed-off-by: Michael Chan Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bnxt/bnxt.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit b9a8460a08a1e0150073cda3e7a0dd23cb888052 Author: Michael Chan Date: Mon Jun 6 02:37:14 2016 -0400 bnxt_en: Fix tx push race condition. Set the is_push flag in the software BD before the tx data is pushed to the chip. It is possible to get the tx interrupt as soon as the tx data is pushed. The tx handler will not handle the event properly if the is_push flag is not set and it will crash. Signed-off-by: Michael Chan Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9c77679cadb118c0aa99e6f88533d91765a131ba Author: H. Peter Anvin Date: Tue Apr 5 17:01:33 2016 -0700 x86, build: copy ldlinux.c32 to image.iso For newer versions of Syslinux, we need ldlinux.c32 in addition to isolinux.bin to reside on the boot disk, so if the latter is found, copy it, too, to the isoimage tree. Signed-off-by: H. Peter Anvin Cc: Linux Stable Tree arch/x86/boot/Makefile | 3 +++ 1 file changed, 3 insertions(+) commit fa54cc70ed2eddd96773ffdf4d96d23ea7483e56 Author: Wu Fengguang Date: Sun Jun 5 07:17:19 2016 +0800 rxrpc: fix ptr_ret.cocci warnings net/rxrpc/rxkad.c:1165:1-3: WARNING: PTR_ERR_OR_ZERO can be used Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR Generated by: scripts/coccinelle/api/ptr_ret.cocci CC: David Howells Signed-off-by: Fengguang Wu Signed-off-by: David S. Miller net/rxrpc/rxkad.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 29a36611e9f10f629b4d7920418fcb8f5e50ae75 Merge: 80e509d 9c79440 Author: David S. Miller Date: Tue Jun 7 15:10:16 2016 -0700 Merge branch 'rds-packet-assembly-fixes' Sowmini Varadhan says: ==================== RDS: TCP: socket locking RDS packet assembly fixes This three part patchset fixes bugs in synchronization between rds_tcp_accept_one() and the rds-tcp send/recv path. Patch 1 ensures that the lock_sock() is taken appropriately and the RDS datagram reassembly state is reset to synchronize with the receive path. Patch 2 ensures that partially sent RDS datagrams will get retransmitted after rds_tcp_accept_one() switches sockets. Patch 3 fixes a race window which would prematurely re-enable rds_send_xmit() before the rds_tcp_connection setup has been completed in rds_tcp_accept_one(). ==================== Signed-off-by: David S. Miller commit 9c79440e2c5e2518879f1599270f64c3ddda3baf Author: Sowmini Varadhan Date: Sat Jun 4 14:00:00 2016 -0700 RDS: TCP: fix race windows in send-path quiescence by rds_tcp_accept_one() The send path needs to be quiesced before resetting callbacks from rds_tcp_accept_one(), and commit eb192840266f ("RDS:TCP: Synchronize rds_tcp_accept_one with rds_send_xmit when resetting t_sock") achieves this using the c_state and RDS_IN_XMIT bit following the pattern used by rds_conn_shutdown(). However this leaves the possibility of a race window as shown in the sequence below take t_conn_lock in rds_tcp_conn_connect send outgoing syn to peer drop t_conn_lock in rds_tcp_conn_connect incoming from peer triggers rds_tcp_accept_one, conn is marked CONNECTING wait for RDS_IN_XMIT to quiesce any rds_send_xmit threads call rds_tcp_reset_callbacks [.. race-window where incoming syn-ack can cause the conn to be marked UP from rds_tcp_state_change ..] lock_sock called from rds_tcp_reset_callbacks, and we set t_sock to null As soon as the conn is marked UP in the race-window above, rds_send_xmit() threads will proceed to rds_tcp_xmit and may encounter a null-pointer deref on the t_sock. Given that rds_tcp_state_change() is invoked in softirq context, whereas rds_tcp_reset_callbacks() is in workq context, and testing for RDS_IN_XMIT after lock_sock could result in a deadlock with tcp_sendmsg, this commit fixes the race by using a new c_state, RDS_TCP_RESETTING, which will prevent a transition to RDS_CONN_UP from rds_tcp_state_change(). Signed-off-by: Sowmini Varadhan Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/rds.h | 2 ++ net/rds/tcp.c | 14 +++++++++++++- net/rds/tcp_connect.c | 2 +- net/rds/tcp_listen.c | 7 +++---- net/rds/threads.c | 10 ++++++++-- 5 files changed, 27 insertions(+), 8 deletions(-) commit 0b6f760cff04a7cdfafc3ec6915e91fed0533d8d Author: Sowmini Varadhan Date: Sat Jun 4 13:59:59 2016 -0700 RDS: TCP: Retransmit half-sent datagrams when switching sockets in rds_tcp_reset_callbacks When we switch a connection's sockets in rds_tcp_rest_callbacks, any partially sent datagram must be retransmitted on the new socket so that the receiver can correctly reassmble the RDS datagram. Use rds_send_reset() which is designed for this purpose. Signed-off-by: Sowmini Varadhan Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/send.c | 1 + net/rds/tcp.c | 1 + 2 files changed, 2 insertions(+) commit 335b48d980f631fbc5b233cbb3625ac0c86d67cb Author: Sowmini Varadhan Date: Sat Jun 4 13:59:58 2016 -0700 RDS: TCP: Add/use rds_tcp_reset_callbacks to reset tcp socket safely When rds_tcp_accept_one() has to replace the existing tcp socket with a newer tcp socket (duelling-syn resolution), it must lock_sock() to suppress the rds_tcp_data_recv() path while callbacks are being changed. Also, existing RDS datagram reassembly state must be reset, so that the next datagram on the new socket does not have corrupted state. Similarly when resetting the newly accepted socket, appropriate locks and synchronization is needed. This commit ensures correct synchronization by invoking kernel_sock_shutdown to reset a newly accepted sock, and by taking appropriate lock_sock()s (for old and new sockets) when resetting existing callbacks. Signed-off-by: Sowmini Varadhan Acked-by: Santosh Shilimkar Signed-off-by: David S. Miller net/rds/tcp.c | 65 +++++++++++++++++++++++++++++++++++++++++++++++++--- net/rds/tcp.h | 1 + net/rds/tcp_listen.c | 13 ++++------- 3 files changed, 67 insertions(+), 12 deletions(-) commit 80e509db54c81247b32fcb75bb1730fc789b893d Author: Eric Dumazet Date: Sat Jun 4 12:55:13 2016 -0700 fq_codel: fix NET_XMIT_CN behavior My prior attempt to fix the backlogs of parents failed. If we return NET_XMIT_CN, our parents wont increase their backlog, so our qdisc_tree_reduce_backlog() should take this into account. v2: Florian Westphal pointed out that we could drop the packet, so we need to save qdisc_pkt_len(skb) in a temp variable before calling fq_codel_drop() Fixes: 9d18562a2278 ("fq_codel: add batch ability to fq_codel_drop()") Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Reported-by: Stas Nichiporovich Signed-off-by: Eric Dumazet Cc: WANG Cong Cc: Jamal Hadi Salim Acked-by: Jamal Hadi Salim Acked-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_fq_codel.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) commit 5b6c1b4d46b0dae4edea636a776d09f2064f4cd7 Author: Daniel Borkmann Date: Sat Jun 4 20:50:59 2016 +0200 bpf, trace: use READ_ONCE for retrieving file ptr In bpf_perf_event_read() and bpf_perf_event_output(), we must use READ_ONCE() for fetching the struct file pointer, which could get updated concurrently, so we must prevent the compiler from potential refetching. We already do this with tail calls for fetching the related bpf_prog, but not so on stored perf events. Semantics for both are the same with regards to updates. Fixes: a43eec304259 ("bpf: introduce bpf_perf_event_output() helper") Fixes: 35578d798400 ("bpf: Implement function bpf_perf_event_read() that get the selected hardware PMU conuter") Signed-off-by: Daniel Borkmann Acked-by: Alexei Starovoitov Signed-off-by: David S. Miller kernel/trace/bpf_trace.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b36fad65d61fffe4b662d4bfb1ed673c455a36a2 Author: Michal Marek Date: Tue Jun 7 11:57:02 2016 +0200 kbuild: Initialize exported variables The NOSTDINC_FLAGS variable is exported, so it needs to be cleared to avoid duplicating its content when running make from within make (e.g. in the packaging targets). This became an issue after commit 9c8fa9bc08f6 ("kbuild: fix if_change and friends to consider argument order"), which no longer ignores the duplicate options. As Paulo Zanoni points out, the LDFLAGS_vmlinux variable has the same problem. Reported-by: "Zanoni, Paulo R" Fixes: 9c8fa9bc08f6 ("kbuild: fix if_change and friends to consider argument order") Signed-off-by: Michal Marek Makefile | 2 ++ 1 file changed, 2 insertions(+) commit 6519c3d7b8621c9f4333c98ed4b703029b51ba79 Author: Laurent Pinchart Date: Tue May 24 09:09:33 2016 -0300 [media] adv7604: Don't ignore pad number in subdev DV timings pad operations The dv_timings_cap() and enum_dv_timings() pad operations take a pad number as an input argument and return the DV timings capabilities and list of supported DV timings for that pad. Commit bd3e275f3ec0 ("[media] media: i2c: adv7604: Use v4l2-dv-timings helpers") broke this as it started ignoring the pad number, always returning the information associated with the currently selected input. Fix it. Fixes: bd3e275f3ec0 ("[media] media: i2c: adv7604: Use v4l2-dv-timings helpers") Signed-off-by: Laurent Pinchart Signed-off-by: Hans Verkuil Cc: # for v4.6 Signed-off-by: Mauro Carvalho Chehab drivers/media/i2c/adv7604.c | 46 ++++++++++++++++++++++++++++++++++----------- 1 file changed, 35 insertions(+), 11 deletions(-) commit 1ca830b110cd9d067327571f1136fdbf1ef2b4d3 Author: Hans Verkuil Date: Mon May 23 08:45:44 2016 -0300 [media] v4l2-ioctl: fix stupid mistake in cropcap condition Fix duplicate tests in condition. The second test for vidioc_cropcap should have tested for vidioc_g_selection instead. Signed-off-by: Hans Verkuil Reported-by: David Binderman Acked-by: Sakari Ailus Signed-off-by: Mauro Carvalho Chehab drivers/media/v4l2-core/v4l2-ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 43c082e72745555952126848a40db3a06fc8a7a9 Merge: 3613a62 d71ed6c Author: Linus Torvalds Date: Tue Jun 7 10:04:35 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace Pull userns fixes from Eric Biederman: "This contains two small but significant fixes to fs/namespace.c. The first adds a filesystem refcount drop on error. The second corrects a test in fs_fully_visible which could be abused to allow mounting of proc or sysfs, when that should not be allowed. To keep myself honest I have tested to ensure the incorrect test in fs_fully_visible actually allows improper mounting of proc before the fix and that when fixed the improper mounting is not allowed" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: mnt: fs_fully_visible test the proper mount for MNT_LOCKED mnt: If fs_fully_visible fails call put_filesystem. commit 05bd92dddc595d74ea645e793c1f3bd4b1fc251a Author: Shaun Tancheff Date: Tue Jun 7 11:32:13 2016 -0500 block: missing bio_put following submit_bio_wait submit_bio_wait() gives the caller an opportunity to examine struct bio and so expects the caller to issue the put_bio() This fixes a memory leak reported by a few people in 4.7-rc2 kmemleak report after 9082e87bfbf8 ("block: remove struct bio_batch") Signed-off-by: Shaun Tancheff Tested-by: Catalin Marinas Tested-by: Larry Finger@lwfinger.net Tested-by: David Drysdale Reviewed-by: Christoph Hellwig Signed-off-by: Jens Axboe block/blk-lib.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit c853f18b640f3e58ba14ffb25e551be8af218209 Merge: aff093d af8c34c Author: Mauro Carvalho Chehab Date: Tue Jun 7 13:04:56 2016 -0300 Merge tag 'v4.7-rc2' into v4l_for_linus Linux 4.7-rc2 * tag 'v4.7-rc2': (10914 commits) Linux 4.7-rc2 devpts: Make each mount of devpts an independent filesystem. parisc: Move die_if_kernel() prototype into traps.h header parisc: Fix pagefault crash in unaligned __get_user() call parisc: Fix printk time during boot parisc: Fix backtrace on PA-RISC mm, page_alloc: recalculate the preferred zoneref if the context can ignore memory policies mm, page_alloc: reset zonelist iterator after resetting fair zone allocation policy mm, oom_reaper: do not use siglock in try_oom_reaper() mm, page_alloc: prevent infinite loop in buffered_rmqueue() checkpatch: reduce git commit description style false positives mm/z3fold.c: avoid modifying HEADLESS page and minor cleanup memcg: add RCU locking around css_for_each_descendant_pre() in memcg_offline_kmem() mm: check the return value of lookup_page_ext for all call sites kdump: fix dmesg gdbmacro to work with record based printk mm: fix overflow in vm_map_ram() Btrfs: deal with duplciates during extent_map insertion in btrfs_get_extent arm64: fix alignment when RANDOMIZE_TEXT_OFFSET is enabled arm64: move {PAGE,CONT}_SHIFT into Kconfig arm64: mm: dump: log span level ... commit 61c78eea9516a921799c17b4c20558e2aa780fd3 Author: Erez Shitrit Date: Sat Jun 4 15:15:19 2016 +0300 IB/IPoIB: Don't update neigh validity for unresolved entries ipoib_neigh_get unconditionally updates the "alive" variable member on any packet send. This prevents the neighbor garbage collection from cleaning out a dead neighbor entry if we are still queueing packets for it. If the queue for this neighbor is full, then don't update the alive timestamp. That way the neighbor can time out even if packets are still being queued as long as none of them are being sent. Fixes: b63b70d87741 ("IPoIB: Use a private hash table for path lookup in xmit path") Signed-off-by: Erez Shitrit Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit f879ee8d900fc78b5bc5d840edd9ecb57d02ab7e Author: Achiad Shochat Date: Sat Jun 4 15:15:37 2016 +0300 IB/mlx5: Fix alternate path code Userspace flag IBV_QP_ALT_PATH is supposed to set the alternate path including fields alt_pkey_index and alt_timeout. Added IB_QP_PKEY_INDEX and IB_QP_TIMEOUT to the attribute mask when calling mlx5_set_path for the alternate path to force setting the alt_pkey_index and alt_timeout values. Fixes: bf24481a3a7c4 ('IB/mlx5: Consider alternate path in pkey ...') Signed-off-by: Achiad Shochat Signed-off-by: Noa Osherovich Reviewed-by: Jack Morgenstein Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/qp.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit d3ae2bdeba9bad8cb95301451aeaf03ce31e82f0 Author: Noa Osherovich Date: Sat Jun 4 15:15:36 2016 +0300 IB/mlx5: Fix pkey_index length in the QP path record Pkey index fields in the QP context path record are extended to 16 bits, as required by IB spec (version 1.3). This change affects all QP commands which include path records. To enable this change, moved the free adaptive routing flag bit (free_ar) to the most significant byte of the QP path record. Fixes: e126ba97dba9e ('mlx5: Add driver for Mellanox Connect-IB ...') Signed-off-by: Noa Osherovich Reviewed-by: Jack Morgenstein Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/qp.c | 15 ++++++++------- include/linux/mlx5/qp.h | 5 ++--- 2 files changed, 10 insertions(+), 10 deletions(-) commit 3c4c37746c919c983e439ac6a7328cd2d48c10ed Author: Noa Osherovich Date: Sat Jun 4 15:15:35 2016 +0300 IB/mlx5: Fix entries check in mlx5_ib_resize_cq Verify that number of entries is less than device capability. Add an appropriate warning message for error flow. Fixes: bde51583f49b ('IB/mlx5: Add support for resize CQ') Signed-off-by: Majd Dibbiny Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/cq.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 9ea578528656e191c1097798a771ff08bab6f323 Author: Noa Osherovich Date: Sat Jun 4 15:15:34 2016 +0300 IB/mlx5: Fix entries checks in mlx5_ib_create_cq Number of entries shouldn't be greater than the device's max capability. This should be checked before rounding the entries number to power of two. Fixes: 51ee86a4af639 ('IB/mlx5: Fix check of number of entries...') Signed-off-by: Majd Dibbiny Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Reviewed-by: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/cq.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 2cc6ad5f2130733e561f97dba7a2052f8ea024aa Author: Noa Osherovich Date: Sat Jun 4 15:15:33 2016 +0300 IB/mlx5: Check BlueFlame HCA support BlueFlame support is reported only for PFs when the HCA capability is on. Fixes: 938fe83c8dcbb ('net/mlx5_core: New device capabilities...') Signed-off-by: Majd Dibbiny Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Reviewed-by: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 0540d8148d419bf769e5aa99c77027febd8922f0 Author: Noa Osherovich Date: Sat Jun 4 15:15:32 2016 +0300 IB/mlx5: Fix returned values of query QP Some variables were not initialized properly: max_recv_wr, max_recv_sge, max_send_wr, qp_context and max_inline_data. Fixes: e126ba97dba9 ('mlx5: Add driver for Mellanox Connect-IB...') Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Reviewed-by: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/qp.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit bc5c6eed0510f19b033ce7a7d3976e695e96785b Author: Noa Osherovich Date: Sat Jun 4 15:15:31 2016 +0300 IB/mlx5: Limit query HCA clock When PAGE_SIZE is larger than 4K, the user shouldn't be able to query the HCA core clock. This counter is within 4KB boundary and the user-space shall not read information that's after this boundary. Fixes: b368d7cb8ceb7 ('IB/mlx5: Add hca_core_clock_offset to...') Signed-off-by: Majd Dibbiny Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/main.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit c0fcebf55289c48148992eee002a7caf853a5358 Author: Eran Ben Elisha Date: Sat Jun 4 15:15:30 2016 +0300 IB/mlx5: Fix FW version diaplay in sysfs Add a 4-digit padding to show FW version in proper format. Fixes: 9603b61de1eee ('mlx5: Move pci device handling from...') Signed-off-by: Eran Ben Elisha Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2788cf3bd90af3791c3195c52391bcf34fa67b40 Author: Noa Osherovich Date: Sat Jun 4 15:15:29 2016 +0300 IB/mlx5: Return PORT_ERR in Active to Initializing tranisition FW port-change events are fired on Active <-> non Active port state transitions only. When the port state changes from Active to Initializing (Active -> Down -> Initializing), a single event is fired. The HCA transitions from Down to Initializing unless prevented from doing so, hence the driver should also propagate events when the port state is Initializing to consumers so they'll be aware that the port is no longer Active and act accordingly. Fixes: e126ba97dba9e ('mlx5: Add driver for Mellanox Connect-IB...') Signed-off-by: Noa Osherovich Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/main.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit da6d6ba3c6f085abf82723612efd746a97f8e414 Author: Maor Gottlieb Date: Sat Jun 4 15:15:28 2016 +0300 IB/mlx5: Set flow steering capability bit Flow steering is supported by mlx5 device when the following features are supported by firmware: 1. NIC RX flow table. 2. Device has enough flow steering levels. 3. Atomic modification of flow table entry. 4. Flow tables chaining. To check if flow steering is supported it's enough to check if the driver opened the mlx5 bypass namespace. Signed-off-by: Maor Gottlieb Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx5/main.c | 3 +++ 1 file changed, 3 insertions(+) commit c7e162a417488f3c79eb09f3c4f1d36f1e042463 Author: Max Gurtovoy Date: Mon Jun 6 19:34:40 2016 +0300 IB/core: Make all casts in ib_device_cap_flags enum consistent Replace the few u64 casts with ULL to match the rest of the casts. Signed-off-by: Max Gurtovoy Signed-off-by: Doug Ledford include/rdma/ib_verbs.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 47355b3cd7d3c9c5226bff7c449b9d269fb17fa6 Author: Max Gurtovoy Date: Mon Jun 6 19:34:39 2016 +0300 IB/core: Fix bit curruption in ib_device_cap_flags structure ib_device_cap_flags 64-bit expansion caused caps overlapping and made consumers read wrong device capabilities. For example IB_DEVICE_SG_GAPS_REG was falsely read by the iser driver causing it to use a non-existing capability. This happened because signed int becomes sign extended when converted it to u64. Fix this by casting IB_DEVICE_ON_DEMAND_PAGING enumeration to ULL. Fixes: f5aa9159a418 ('IB/core: Add arbitrary sg_list support') Reported-by: Robert LeBlanc Cc: Stable #[v4.6+] Acked-by: Sagi Grimberg Signed-off-by: Max Gurtovoy Signed-off-by: Matan Barak Reviewed-by: Christoph Hellwig Signed-off-by: Doug Ledford include/rdma/ib_verbs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8aec013afe6d9665eb478396026ebd4384dbe934 Author: Mark Bloch Date: Sat Jun 4 15:15:24 2016 +0300 IB/core: Initialize sysfs attributes before sysfs create group For dynamically allocated sysfs attributes there is a need to call sysfs_attr_init in order to comply with lockdep, not calling it will result in error complaining key is not in .data section. Fixes: b40f4757daa1 ("IB/core: Make device counter infrastructure dynamic") Signed-off-by: Mark Bloch Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/sysfs.c | 3 +++ 1 file changed, 3 insertions(+) commit 9b29953bf8ca23944c5e00dcc15ad7bd9fecdd4e Author: Mark Bloch Date: Sat Jun 4 15:15:22 2016 +0300 IB/IPoIB: Disable bottom half when dealing with device address Align locking usage when touching device address with rest of the kernel. Lock the bottom half when doing so using netif_addr_lock_bh. This also solves the following case as reported by lockdep: CPU0 CPU1 ---- ---- lock(_xmit_INFINIBAND); local_irq_disable(); lock(&(&mc->mca_lock)->rlock); lock(_xmit_INFINIBAND); lock(&(&mc->mca_lock)->rlock); *** DEADLOCK *** Fixes: 492a7e67ff83 ("IB/IPoIB: Allow setting the device address") Signed-off-by: Mark Bloch Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/ulp/ipoib/ipoib_ib.c | 8 ++++---- drivers/infiniband/ulp/ipoib/ipoib_main.c | 8 ++++---- drivers/infiniband/ulp/ipoib/ipoib_multicast.c | 6 +++--- 3 files changed, 11 insertions(+), 11 deletions(-) commit 8e787646fbce895c20c4433973e90af90e1c6a28 Author: Aviv Heller Date: Sat Jun 4 15:15:21 2016 +0300 IB/core: Fix removal of default GID cache entry When deleting a default GID from the cache, its gid_type field is set to 0. This could set the gid_type to RoCE v1 for a RoCE v2 default GID, essentially making it inaccessible to future modifications, since it is no longer found by find_gid(). This fix preserves the gid_type value for default gids during cache operations. Fixes: b39ffa1df505 ('IB/core: Add gid_type to gid attribute') Signed-off-by: Aviv Heller Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/core/cache.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 198b12f77084244d310888dd5d643083cb5c2aa1 Author: Erez Shitrit Date: Sat Jun 4 15:15:20 2016 +0300 IB/IPoIB: Fix race between ipoib_remove_one to sysfs functions In ipoib_remove_one the driver holds the rtnl_lock and tries to do some operation like dev_change_flags or unregister_netdev, while sysfs callback like ipoib_vlan_delete holds sysfs mutex and tries to hold the rtnl_lock via rtnl_trylock() and restart_syscall() if the lock is not free, meanwhile ipoib_remove_one tries to get the sysfs lock in order to free its sysfs directory, and we will get a->b, b->a deadlock. Trace like the following: schedule+0x37/0x80 schedule_preempt_disabled+0xe/0x10 __mutex_lock_slowpath+0xb5/0x120 mutex_lock+0x23/0x40 rtnl_lock+0x15/0x20 netdev_run_todo+0x17c/0x320 rtnl_unlock+0xe/0x10 ipoib_vlan_delete+0x11b/0x1b0 [ib_ipoib] delete_child+0x54/0x80 [ib_ipoib] dev_attr_store+0x18/0x30 sysfs_kf_write+0x37/0x40 mutex_lock+0x16/0x40 SyS_write+0x55/0xc0 entry_SYSCALL_64_fastpath+0x16/0x75 And schedule+0x37/0x80 __kernfs_remove+0x1a8/0x260 ? wake_atomic_t_function+0x60/0x60 kernfs_remove+0x25/0x40 sysfs_remove_dir+0x50/0x80 kobject_del+0x18/0x50 device_del+0x19f/0x260 netdev_unregister_kobject+0x6a/0x80 rollback_registered_many+0x1fd/0x340 rollback_registered+0x3c/0x70 unregister_netdevice_queue+0x55/0xc0 unregister_netdev+0x20/0x30 ipoib_remove_one+0x114/0x1b0 [ib_ipoib] ib_unregister_client+0x4a/0x170 [ib_core] ? find_module_all+0x71/0xa0 ipoib_cleanup_module+0x10/0x94 [ib_ipoib] SyS_delete_module+0x1b5/0x210 entry_SYSCALL_64_fastpath+0x16/0x75 The fix is by checking the flag IPOIB_FLAG_INTF_ON_DESTROY in order to get out from the sysfs function. Fixes: 862096a8bbf8 ("IB/ipoib: Add more rtnl_link_ops callbacks") Fixes: 9baa0b036410 ("IB/ipoib: Add rtnl_link_ops support") Signed-off-by: Erez Shitrit Signed-off-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/ulp/ipoib/ipoib.h | 1 + drivers/infiniband/ulp/ipoib/ipoib_cm.c | 4 ++++ drivers/infiniband/ulp/ipoib/ipoib_main.c | 3 +++ drivers/infiniband/ulp/ipoib/ipoib_vlan.c | 6 ++++++ 4 files changed, 14 insertions(+) commit d7012467a95b767b4d3beb2e027aa24a83f12f0f Author: Eli Cohen Date: Sat Jun 4 15:15:18 2016 +0300 IB/core: Fix query port failure in RoCE Currently ib_query_port always attempts to to read the subnet prefix by calling ib_query_gid(). For RoCE/iWARP there is no subnet manager and no subnet prefix. Fix this by querying GID[0] only for IB networks. Fixes: fad61ad4e755 ('IB/core: Add subnet prefix to port info') Signed-off-by: Eli Cohen Signed-off-by: Leon Romanovsky Reviewed-by: Steve Wise Signed-off-by: Doug Ledford drivers/infiniband/core/device.c | 3 +++ 1 file changed, 3 insertions(+) commit 495fbae6e2c115099921ba33b1e1bea1190b5280 Author: Doug Ledford Date: Tue Jun 7 07:43:46 2016 -0400 IB/core: fix error unwind in sysfs hw counters code Between the initial and final versions of the function setup_hw_stats, the order of variable initialization was changed. However, the unwind flow on error did not properly keep up with the flow changes. Make the unwind flow match a proper unwind of the allocation flow, then remove no longer needed variable initializations. Fixes: b40f4757daa1 (IB/core: Make device counter infrastructure dynamic) Signed-off-by: Doug Ledford drivers/infiniband/core/sysfs.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 41aaa99fab6ceaa4b533c2b6ad4913987ddb3ddc Author: Doug Ledford Date: Mon Jun 6 19:52:55 2016 -0400 IB/core: Fix array length allocation The new sysfs hw_counters code had an off by one in its array allocation length. Fix that and the comment along with it. Reported-by: Mark Bloch Fixes: b40f4757daa1 (IB/core: Make device counter infrastructure dynamic) Signed-off-by: Doug Ledford drivers/infiniband/core/sysfs.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit dab38e43b298501a4e8807b56117c029e2e98383 Author: Torsten Hilbrich Date: Tue Jun 7 13:14:21 2016 +0200 ALSA: hda/realtek: Add T560 docking unit fixup Tested with Lenovo Ultradock. Fixes the non-working headphone jack on the docking unit. Signed-off-by: Torsten Hilbrich Tested-by: Torsten Hilbrich Cc: Signed-off-by: Takashi Iwai sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+) commit 8d0a0710ea0d22881fdb40eb79d346a98cc64ae6 Author: Ben Greear Date: Thu Jun 2 17:59:54 2016 +0300 ath10k: fix crash related to printing features This looks like a regression from commit c4cdf753ed42 ("ath10k: move fw_features to struct ath10k_fw_file"), we were printing the features from a wrong struct. Fixes: c4cdf753ed42 ("ath10k: move fw_features to struct ath10k_fw_file") Signed-off-by: Ben Greear [kvalo@qca.qualcomm.com: improve commit log] Signed-off-by: Kalle Valo drivers/net/wireless/ath/ath10k/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 572f1f613a109e03b52e72b62df2d2c0e595d3bd Author: Bard Liao Date: Tue Jun 7 11:03:08 2016 +0800 ASoC: rt5670: fix HP Playback Volume control The register setting for HP Playback Volume is inverted. So, set the invert flag in SOC_DOUBLE_TLV. Signed-off-by: Bard Liao Signed-off-by: Mark Brown sound/soc/codecs/rt5670.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a7d7865fecd83adb98b20eca5eddef7efc94831d Author: Javier Martinez Canillas Date: Mon Jun 6 16:24:44 2016 -0400 ARM: dts: exynos: Fix port nodes names for Exynos5420 Peach Pit board Commit bea7eef6949c ("ARM: dts: exynos: Fix DTC unit name warnings in Peach Pit") fixed the DTC warnings about mismatches between unit names and reg properties in the Exynos5420 Peach Pit DTS. But unfortunately it also added a regression on the Peach Pit when changing the port node names since the OF graph logic expects the port nodes to be always named 'port'. The Documentation/devicetree/bindings/graph.txt binding document says that when there is more than one port, '#address-cells', '#size-cells' and 'reg' properties should be used to number the port nodes. Fixes: bea7eef6949c ("ARM: dts: exynos: Fix DTC unit name warnings in Peach Pit") Reported-by: Marc Zyngier Signed-off-by: Javier Martinez Canillas Signed-off-by: Krzysztof Kozlowski arch/arm/boot/dts/exynos5420-peach-pit.dts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 2969c03763b40e946b46aee57ef083527711c69f Author: Javier Martinez Canillas Date: Mon Jun 6 16:24:43 2016 -0400 ARM: dts: exynos: Fix port nodes names for Exynos5250 Snow board Commit 5c9cbade0629 ("ARM: dts: exynos: Fix DTC unit name warnings in Exynos5250") fixed all the DTC warnings about mismatchs between unit names and reg properties in Exynos5250 boards DTS. But unfortunately it also added a regression on the Exynos5250 Snow Chromebook when changing the port node names since the OF graph logic expects the port nodes to be always named 'port'. The Documentation/devicetree/bindings/graph.txt binding document says that when there is more than one port, '#address-cells', '#size-cells' and 'reg' properties should be used to number the port nodes. Fixes: 5c9cbade0629 ("ARM: dts: exynos: Fix DTC unit name warnings in Exynos5250") Reported-by: Marc Zyngier Signed-off-by: Javier Martinez Canillas Tested-by: Marc Zyngier Signed-off-by: Krzysztof Kozlowski arch/arm/boot/dts/exynos5250-snow-common.dtsi | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 5156463588c3999b630d9ffc6061a54962f3c2d9 Author: Stefan Roese Date: Wed Jun 1 12:43:32 2016 +0200 dmaengine: mv_xor: Fix incorrect offset in dma_map_page() Upon booting, I occasionally spotted some BUGs triggered by the internal DMA test routine executed upon driver probing. This was detected by SLUB_DEBUG ("Freechain corrupt" or "Redzone overwritten"). Tracking this down located a problem in passing 0 as offset in dma_map_page(). As kmalloc, especially when used with SLUB_DEBUG, may return a non page aligned address. This patch fixes this issue by passing the correct offset in dma_map_page(). Tested on a custom Armada XP board. Signed-off-by: Stefan Roese Cc: Thomas Petazzoni Cc: Gregory CLEMENT Cc: Marcin Wojtas Signed-off-by: Vinod Koul drivers/dma/mv_xor.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit d71ed6c930ac7d8f88f3cef6624a7e826392d61f Author: Eric W. Biederman Date: Fri May 27 14:50:05 2016 -0500 mnt: fs_fully_visible test the proper mount for MNT_LOCKED MNT_LOCKED implies on a child mount implies the child is locked to the parent. So while looping through the children the children should be tested (not their parent). Typically an unshare of a mount namespace locks all mounts together making both the parent and the slave as locked but there are a few corner cases where other things work. Cc: stable@vger.kernel.org Fixes: ceeb0e5d39fc ("vfs: Ignore unlocked mounts in fs_fully_visible") Reported-by: Seth Forshee Signed-off-by: "Eric W. Biederman" fs/namespace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97c1df3e54e811aed484a036a798b4b25d002ecf Author: Eric W. Biederman Date: Mon Jun 6 15:36:07 2016 -0500 mnt: If fs_fully_visible fails call put_filesystem. Add this trivial missing error handling. Cc: stable@vger.kernel.org Fixes: 1b852bceb0d1 ("mnt: Refactor the logic for mounting sysfs and proc in a user namespace") Signed-off-by: "Eric W. Biederman" fs/namespace.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit a27758ffaf96f89002129eedb2cc172d254099f8 Author: WANG Cong Date: Fri Jun 3 15:05:57 2016 -0700 net_sched: keep backlog updated with qlen For gso_skb we only update qlen, backlog should be updated too. Note, it is correct to just update these stats at one layer, because the gso_skb is cached there. Reported-by: Stas Nichiporovich Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller include/net/sch_generic.h | 5 ++++- net/sched/sch_generic.c | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) commit dcf15cbded656a12335bc4151f3f75f10080a375 Author: Lv Zheng Date: Fri Jun 3 10:26:12 2016 +0800 ACPI / EC: Fix a boot EC regresion by restoring boot EC support for the DSDT EC According to the Windows probing result, during the table loading, the EC device described in the ECDT should be used. And the ECDT EC is also effective during the period the namespace objects are initialized (we can see a separate process executing _STA/_INI on Windows before executing other device specific control methods, for example, EC._REG). During the device enumration, the EC device described in the DSDT should be used. But there are differences between Linux and Windows around the device probing order. Thus in Linux, we should enable the DSDT EC as early as possible before enumerating devices in order not to trigger issues related to the device enumeration order differences. This patch thus converts acpi_boot_ec_enable() into acpi_ec_dsdt_probe() to fix the gap. This also fixes a user reported regression triggered after we switched the "table loading"/"ECDT support" to be ACPI spec 2.0 compliant. Fixes: 59f0aa9480cf (ACPI 2.0 / ECDT: Remove early namespace reference from EC) Link: https://bugzilla.kernel.org/show_bug.cgi?id=119261 Reported-and-tested-by: Gabriele Mazzotta Signed-off-by: Lv Zheng Signed-off-by: Rafael J. Wysocki drivers/acpi/bus.c | 2 +- drivers/acpi/ec.c | 29 ++++++++++++++++++++++------- drivers/acpi/internal.h | 2 +- 3 files changed, 24 insertions(+), 9 deletions(-) commit 55c40648d31d0d97608f266955b8afae74e2b686 Author: Bart Van Assche Date: Fri Jun 3 12:11:16 2016 -0700 IB/hfi1: Suppress sparse warnings Avoid that sparse reports the following warnings for the hfi1 driver: trace.c:217:13: warning: no previous prototype for ‘print_u64_array’ [-Wmissing-prototypes] user_sdma.c:1361:17: warning: dubious: !x & y Signed-off-by: Bart Van Assche Cc: Mike Marciniszyn Cc: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/trace.c | 13 ------------- drivers/infiniband/hw/hfi1/user_sdma.c | 4 ++-- 2 files changed, 2 insertions(+), 15 deletions(-) commit d55215c50e4eaa4b906a42ef45884d8fcbadc777 Author: Bart Van Assche Date: Fri Jun 3 12:10:37 2016 -0700 IB/hfi1: Use bit 0 instead of bit 1 The first argument of test_bit() and clear_bit() is a bit number and not a bitmask. Hence change that first argument from (1 << 0) into 0. This patch avoids that smatch reports the following warnings: user_sdma.c:1059: sdma_cache_evict() warn: test_bit() takes a bit number user_sdma.c:1590: sdma_rb_remove() warn: test_bit() takes a bit number Signed-off-by: Bart Van Assche Cc: Mike Marciniszyn Cc: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/user_sdma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 48a0cc139fb89590fd66eea11b626b9b9f6b8e9d Author: Bart Van Assche Date: Fri Jun 3 12:09:56 2016 -0700 IB/hfi1: Fix indentation Make the indentation of the source code consistent. Detected by smatch. Signed-off-by: Bart Van Assche Cc: Mike Marciniszyn Cc: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/chip.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c0a67f6ba356521a8266694ffffa4998264d0cb0 Author: Bart Van Assche Date: Fri Jun 3 12:09:16 2016 -0700 IB/rdmavt: Annotate rvt_reset_qp() This patch avoids that sparse reports the following warning: rdmavt/qp.c:507:17: warning: context imbalance in 'rvt_reset_qp' - unexpected unlock Signed-off-by: Bart Van Assche Cc: Mike Marciniszyn Cc: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/sw/rdmavt/qp.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 2190d10de58101448b0ac360facc0d5166e3d30d Author: Bart Van Assche Date: Fri Jun 3 12:08:44 2016 -0700 IB/mad: Fix indentation Make indentation consistent. Detected by smatch. Signed-off-by: Bart Van Assche Cc: Hal Rosenstock Cc: Ira Weiny Reviewed-By: Ira Weiny Reviewed-by: Hal Rosenstock Reviewed-by: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/core/mad.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 0270be78da8d27cc5588d2472694aa7ad2c680b3 Author: Bart Van Assche Date: Fri Jun 3 12:08:00 2016 -0700 RDMA/core: Fix indentation Make indentation consistent. Detected by smatch. Signed-off-by: Bart Van Assche Cc: Tatyana Nikolova Cc: Steve Wise Reviewed-by: Steve Wise Reviewed-by: Sagi Grimberg Signed-off-by: Doug Ledford drivers/infiniband/core/iwpm_msg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9edba790fc52322051fd7b6589421021f0726483 Author: Bart Van Assche Date: Fri Jun 3 11:40:24 2016 -0700 IB/srp: Fix srp_map_sg_dma() Because patch "IB/srp: Move common code into the caller" was applied partially srp_map_sg_dma() doesn't work properly. Fix this by applying the remainder of that patch. See also http://thread.gmane.org/gmane.linux.drivers.rdma/35803/focus=35811. Fixes: 3849e44d1c4b ("IB/srp: Move common code into the caller") Signed-off-by: Bart Van Assche Cc: Mike Marciniszyn Cc: Sagi Grimberg Cc: Christoph Hellwig Cc: Laurence Oberman Reviewed-by: Sagi Grimberg Reviewed-by: Christoph Hellwig Signed-off-by: Doug Ledford drivers/infiniband/ulp/srp/ib_srp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 249f06561fc333581e48e6d388a56e3d100d23b6 Author: Bart Van Assche Date: Fri Jun 3 11:39:35 2016 -0700 IB/srp: Always initialize use_fast_reg and use_fmr Avoid that mapping fails due to use_fast_reg != 0 or use_fmr != 0 if both member variables should be zero (if never_register == 1 or if neither FMR nor FR is supported). Remove an initialization that became superfluous due to changing a kmalloc() into a kzalloc() call. Fixes: 509c5f33f4f6 ("IB/srp: Prevent mapping failures") Cc: Sagi Grimberg Cc: Christoph Hellwig Cc: Laurence Oberman Signed-off-by: Bart Van Assche Reviewed-by: Leon Romanovsky Reviewed-by: Sagi Grimberg Reviewed-by: Christoph Hellwig Signed-off-by: Doug Ledford drivers/infiniband/ulp/srp/ib_srp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit ca920f5b67f1b798a1f86c675ea441b295bf8464 Author: Bart Van Assche Date: Fri Jun 3 07:58:32 2016 -0700 IB/mlx4: Fix device managed flow steering support test Perform the test for device managed flow steering support even if memory windows are not supported. I noticed this because smatch reported inconsistent indentation for the device managed flow steering support test. Signed-off-by: Bart Van Assche Reviewed-by: Sagi Grimberg Cc: Yishai Hadas Reviewed-by: Leon Romanovsky Signed-off-by: Doug Ledford drivers/infiniband/hw/mlx4/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ce67fef68de552b14ae417511a323013b478f78e Author: Krzysztof Kozlowski Date: Thu Jun 2 11:45:01 2016 +0200 IB/usnic: Remove unused DMA attributes The DMA attributes are set but never used. Signed-off-by: Krzysztof Kozlowski Signed-off-by: Doug Ledford drivers/infiniband/hw/usnic/usnic_uiom.c | 5 ----- 1 file changed, 5 deletions(-) commit 0147ebcf8927f09e1923114092f6b14c1de75a95 Author: Colin Ian King Date: Wed Jun 1 19:06:36 2016 +0100 IB/core: fix null pointer deref and mem leak in error handling The current error handling in setup_hw_stats has a couple of issues. It is possible to generate a null pointer deference on the kfree of hsag->attrs[i] because two of the early error exit paths jump to the kfree when hsags NULL and not allocated. Fix this by moving the kfree on stats and jumping to that, avoiding the hsag freeing. Secondly, there is a memory leak of stats if the hsag allocation fails; instead of returning, jump to the kfree on stats. Signed-off-by: Colin Ian King Signed-off-by: Doug Ledford drivers/infiniband/core/sysfs.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit da1f857be62ca0472024da37eab068b3b8ce0a15 Author: Dan Carpenter Date: Tue May 31 19:05:56 2016 +0300 IB/core: fix an error code in ib_core_init() We should return the error code if ib_add_ibnl_clients() fails. The current code returns success. Fixes: 735c631ae99d ('IB/core: Register SA ibnl client during ib_core initialization') Signed-off-by: Dan Carpenter Reviewed-by: Mark Bloch Signed-off-by: Doug Ledford drivers/infiniband/core/device.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit f242d93ae92032f78840471e5c2bfc2d04ae324c Author: Leon Romanovsky Date: Tue May 31 10:54:36 2016 +0300 IB/hfi1: Avoid large frame size warning When CONFIG_FRAME_WARN is set to 1024 bytes, which is useful to find stack consumers, we get a warning in hfi1 driver. drivers/infiniband/hw/hfi1/affinity.c: In function ‘hfi1_get_proc_affinity’: drivers/infiniband/hw/hfi1/affinity.c:415:1: warning: the frame size of 1056 bytes is larger than 1024 bytes [-Wframe-larger-than=] This change removes unneeded buf[1024] declaration and usage. Fixes: f48ad614c100 ("IB/hfi1: Move driver out of staging") Signed-off-by: Leon Romanovsky Acked-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/affinity.c | 31 ++++++++++++++----------------- 1 file changed, 14 insertions(+), 17 deletions(-) commit a8b7da58ec81e74a3a6982e2dba24f899b56c915 Author: Dan Carpenter Date: Sat May 28 08:01:20 2016 +0300 IB/hfi1: fix some indenting That extra tabs are misleading. Signed-off-by: Dan Carpenter Reviewed-by: Bart Van Assche Acked-by: Dennis Dalessandro Signed-off-by: Doug Ledford drivers/infiniband/hw/hfi1/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 943f44d94aa26bfdcaafc40d3701e24eeb58edce Author: Bart Van Assche Date: Fri Mar 25 08:33:16 2016 -0700 IB/cm: Fix a recently introduced locking bug ib_cm_notify() can be called from interrupt context. Hence do not reenable interrupts unconditionally in cm_establish(). This patch avoids that lockdep reports the following warning: WARNING: CPU: 0 PID: 23317 at kernel/locking/lockdep.c:2624 trace _hardirqs_on_caller+0x112/0x1b0 DEBUG_LOCKS_WARN_ON(current->hardirq_context) Call Trace: [] dump_stack+0x67/0x92 [] __warn+0xc1/0xe0 [] warn_slowpath_fmt+0x4a/0x50 [] trace_hardirqs_on_caller+0x112/0x1b0 [] trace_hardirqs_on+0xd/0x10 [] _raw_spin_unlock_irq+0x27/0x40 [] ib_cm_notify+0x25c/0x290 [ib_cm] [] srpt_qp_event+0xa1/0xf0 [ib_srpt] [] mlx4_ib_qp_event+0x67/0xd0 [mlx4_ib] [] mlx4_qp_event+0x5a/0xc0 [mlx4_core] [] mlx4_eq_int+0x3d8/0xcf0 [mlx4_core] [] mlx4_msi_x_interrupt+0xc/0x20 [mlx4_core] [] handle_irq_event_percpu+0x64/0x100 [] handle_irq_event+0x34/0x60 [] handle_edge_irq+0x6a/0x150 [] handle_irq+0x15/0x20 [] do_IRQ+0x5c/0x110 [] common_interrupt+0x89/0x89 [] blk_run_queue_async+0x37/0x40 [] rq_completed+0x43/0x70 [dm_mod] [] dm_softirq_done+0x176/0x280 [dm_mod] [] blk_done_softirq+0x52/0x90 [] __do_softirq+0x10f/0x230 [] irq_exit+0xa8/0xb0 [] smp_trace_call_function_single_interrupt+0x2e/0x30 [] smp_call_function_single_interrupt+0x9/0x10 [] call_function_single_interrupt+0x89/0x90 Fixes: commit be4b499323bf (IB/cm: Do not queue work to a device that's going away) Signed-off-by: Bart Van Assche Cc: Erez Shitrit Cc: Sean Hefty Cc: Nikolay Borisov Cc: stable # v4.2+ Acked-by: Erez Shitrit Signed-off-by: Doug Ledford drivers/infiniband/core/cm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1957598840f47d42bb0b7f8a871717a780708686 Author: Helge Deller Date: Fri Jun 3 23:49:17 2016 +0200 soreuseport: add compat case for setsockopt SO_ATTACH_REUSEPORT_CBPF Commit 538950a1b752 ("soreuseport: setsockopt SO_ATTACH_REUSEPORT_[CE]BPF") missed to add the compat case for the SO_ATTACH_REUSEPORT_CBPF option. Signed-off-by: Helge Deller Acked-by: Daniel Borkmann Signed-off-by: David S. Miller net/compat.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit fc100a7f89da85da8edd9c2e6f6e8b2490d74ae1 Author: Helge Deller Date: Fri Jun 3 19:19:20 2016 +0200 soreuseport: Fix reuseport_bpf testcase on 32bit architectures This fixes the following compiler warnings when compiling the reuseport_bpf testcase on a 32 bit platform: reuseport_bpf.c: In function ‘attach_ebpf’: reuseport_bpf.c:114:15: warning: cast from pointer to integer of ifferent size [-Wpointer-to-int-cast] Signed-off-by: Helge Deller Signed-off-by: David S. Miller tools/testing/selftests/net/reuseport_bpf.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 4691409b3e2250ed66aa8dcefa23fe765daf7add Author: Ben Skeggs Date: Fri Jun 3 15:05:52 2016 +1000 drm/nouveau/disp/sor/gm107: training pattern registers are like gm200 Signed-off-by: Ben Skeggs Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/engine/disp/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/engine/disp/gm107.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/disp/outpdp.h | 9 +++- .../gpu/drm/nouveau/nvkm/engine/disp/sorgf119.c | 2 +- .../gpu/drm/nouveau/nvkm/engine/disp/sorgm107.c | 53 ++++++++++++++++++++++ .../gpu/drm/nouveau/nvkm/engine/disp/sorgm200.c | 15 +----- 6 files changed, 64 insertions(+), 18 deletions(-) commit a8953c52b95167b5d21a66f0859751570271d834 Author: Ben Skeggs Date: Fri Jun 3 14:37:40 2016 +1000 drm/nouveau/disp/sor/gf119: both links use the same training register It appears that, for whatever reason, both link A and B use the same register to control the training pattern. It's a little odd, as the GPUs before this (Tesla/Fermi1) have per-link registers, as do newer GPUs (Maxwell). Fixes the third DP output on NVS 510 (GK107). Signed-off-by: Ben Skeggs Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/engine/disp/sorgf119.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 56d1fe0979dc9b73c1c12ee07722ac380d42a0c4 Author: Mario Kleiner Date: Wed May 18 14:02:46 2016 +0200 drm/vc4: Make pageflip completion handling more robust. Protect both the setup of the pageflip event and the latching of the new requested displaylist head pointer by the event lock, so we can't get into a situation where vc4_atomic_flush latches the new display list via HVS_WRITE, then immediately gets preempted before queueing the pageflip event, then the page-flip completes in hw and the vc4_crtc_handle_page_flip() runs and no-ops due to lack of a pending pageflip event, then vc4_atomic_flush continues and only then queues the pageflip event - after the page flip handling already no-oped. This would cause flip completion handling only at the next vblank - one frame too late. In vc4_crtc_handle_page_flip() check the actual DL head pointer in SCALER_DISPLACTX against the requested pointer for page flip to make sure that the flip actually really completed in the current vblank and doesn't get deferred to the next one because the DL head pointer was written a bit too late into SCALER_DISPLISTX, after start of vblank, and missed the boat. This avoids handling a pageflip completion too early - one frame too early. According to Eric, DL head pointer updates which were written into the HVS DISPLISTX reg get committed to hardware at the last pixel of active scanout. Our vblank interrupt handler, as triggered by PV_INT_VFP_START irq, gets to run earliest at the first pixel of HBLANK at the end of the last scanline of active scanout, ie. vblank irq handling runs at least 1 pixel duration after a potential pageflip completion happened in hardware. This ordering of events in the hardware, together with the lock protection and SCALER_DISPLACTX sampling of this patch, guarantees that pageflip completion handling only runs at exactly the vblank irq of actual pageflip completion in all cases. Background info from Eric about the relative timing of HVS, PV's and trigger points for interrupts, DL updates: https://lists.freedesktop.org/archives/dri-devel/2016-May/107510.html Tested on RPi 2B with hardware timing measurement equipment and shown to no longer complete flips too early or too late. Signed-off-by: Mario Kleiner Reviewed-by: Eric Anholt drivers/gpu/drm/vc4/vc4_crtc.c | 28 ++++++++++++++++++---------- drivers/gpu/drm/vc4/vc4_regs.h | 4 ++++ 2 files changed, 22 insertions(+), 10 deletions(-) commit b10c22e5f9902a329450c2027e9291b71e9f1602 Author: Herve Jourdain Date: Wed Jun 1 02:24:46 2016 +0800 drm/vc4: Fix ioctl permissions for render nodes. Contrary to other flags to DRM_IOCTL_DEF_DRV(), which restrict usage, the flag for render node is an enabler (the IOCTL can't be used from render node if it's not present). So DRM_RENDER_ALLOW needs to be added to all the flags that were previously 0. Signed-off-by: Herve Jourdain Reviewed-by: Eric Anholt Fixes: 0cd3e2747662 ("drm/vc4: Add missing render node support") drivers/gpu/drm/vc4/vc4_drv.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit fee48cf8374569a3888fd8c8536283e6067f0cfb Author: Ben Greear Date: Fri Apr 1 14:12:12 2016 -0700 ath10k: fix deadlock when peer cannot be created We must not attempt to send WMI packets while holding the data-lock, as it may deadlock: BUG: sleeping function called from invalid context at drivers/net/wireless/ath/ath10k/wmi.c:1824 in_atomic(): 1, irqs_disabled(): 0, pid: 2878, name: wpa_supplicant ============================================= [ INFO: possible recursive locking detected ] 4.4.6+ #21 Tainted: G W O --------------------------------------------- wpa_supplicant/2878 is trying to acquire lock: (&(&ar->data_lock)->rlock){+.-...}, at: [] ath10k_wmi_tx_beacons_iter+0x26/0x11a [ath10k_core] but task is already holding lock: (&(&ar->data_lock)->rlock){+.-...}, at: [] ath10k_peer_create+0x122/0x1ae [ath10k_core] other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&(&ar->data_lock)->rlock); lock(&(&ar->data_lock)->rlock); *** DEADLOCK *** May be due to missing lock nesting notation 4 locks held by wpa_supplicant/2878: #0: (rtnl_mutex){+.+.+.}, at: [] rtnl_lock+0x12/0x14 #1: (&ar->conf_mutex){+.+.+.}, at: [] ath10k_add_interface+0x3b/0xbda [ath10k_core] #2: (&(&ar->data_lock)->rlock){+.-...}, at: [] ath10k_peer_create+0x122/0x1ae [ath10k_core] #3: (rcu_read_lock){......}, at: [] rcu_read_lock+0x0/0x66 [mac80211] stack backtrace: CPU: 3 PID: 2878 Comm: wpa_supplicant Tainted: G W O 4.4.6+ #21 Hardware name: To be filled by O.E.M. To be filled by O.E.M./ChiefRiver, BIOS 4.6.5 06/07/2013 0000000000000000 ffff8801fcadf8f0 ffffffff8137086d ffffffff82681720 ffffffff82681720 ffff8801fcadf9b0 ffffffff8112e3be ffff8801fcadf920 0000000100000000 ffffffff82681720 ffffffffa0721500 ffff8801fcb8d348 Call Trace: [] dump_stack+0x81/0xb6 [] __lock_acquire+0xc5b/0xde7 [] ? ath10k_wmi_tx_beacons_iter+0x15/0x11a [ath10k_core] [] ? mark_lock+0x24/0x201 [] lock_acquire+0x132/0x1cb [] ? lock_acquire+0x132/0x1cb [] ? ath10k_wmi_tx_beacons_iter+0x26/0x11a [ath10k_core] [] ? ath10k_wmi_cmd_send_nowait+0x1ce/0x1ce [ath10k_core] [] _raw_spin_lock_bh+0x31/0x40 [] ? ath10k_wmi_tx_beacons_iter+0x26/0x11a [ath10k_core] [] ath10k_wmi_tx_beacons_iter+0x26/0x11a [ath10k_core] [] ? ath10k_wmi_cmd_send_nowait+0x1ce/0x1ce [ath10k_core] [] __iterate_interfaces+0x9d/0x13d [mac80211] [] ieee80211_iterate_active_interfaces_atomic+0x32/0x3e [mac80211] [] ? ath10k_wmi_cmd_send_nowait+0x1ce/0x1ce [ath10k_core] [] ath10k_wmi_tx_beacons_nowait.isra.13+0x14/0x16 [ath10k_core] [] ath10k_wmi_cmd_send+0x71/0x242 [ath10k_core] [] ath10k_wmi_peer_delete+0x3f/0x42 [ath10k_core] [] ath10k_peer_create+0x15e/0x1ae [ath10k_core] [] ath10k_add_interface+0x70d/0xbda [ath10k_core] [] drv_add_interface+0x123/0x1a5 [mac80211] [] ieee80211_do_open+0x351/0x667 [mac80211] [] ieee80211_open+0x49/0x4c [mac80211] [] __dev_open+0x88/0xde [] __dev_change_flags+0xa4/0x13a [] dev_change_flags+0x1f/0x54 [] devinet_ioctl+0x2b9/0x5c9 [] ? copy_to_user+0x32/0x38 [] inet_ioctl+0x81/0x9d [] ? inet_ioctl+0x81/0x9d [] sock_do_ioctl+0x20/0x3d [] sock_ioctl+0x222/0x22e [] do_vfs_ioctl+0x453/0x4d7 [] ? __sys_recvmsg+0x4c/0x5b [] ? __fget_light+0x48/0x6c [] SyS_ioctl+0x52/0x74 [] entry_SYSCALL_64_fastpath+0x16/0x7a Signed-off-by: Ben Greear Signed-off-by: Kalle Valo drivers/net/wireless/ath/ath10k/mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3613a6245b9fb5091724961e502fd1228de40f32 Merge: af8c34c 665f05e0 Author: Linus Torvalds Date: Mon Jun 6 09:55:31 2016 -0700 Merge tag 'edac_fixes_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp Pull EDAC fixes from Borislav Petkov: "EDAC fixes to recent fallout from workqueue cleanup and Broadwell enablement: - sb_edac fallout fixes from recent Broadwell enablement (Tony Luck) - EDAC workqueue poll period resetting fix (Nicholas Krause)" * tag 'edac_fixes_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp: EDAC, sb_edac: Readd accidentally dropped Broadwell-D support EDAC: Fix workqueues poll period resetting EDAC, sb_edac: Fix rank lookup on Broadwell commit 34b3e6c92af1fa3f7067e4fa05ffa9d8bd41c96c Author: Feifei Xu Date: Wed Jun 1 19:18:30 2016 +0800 Btrfs: self-tests: Fix extent buffer bitmap test fail on BE system In __test_eb_bitmaps(), we write random data to a bitmap. Then copy the bitmap to another bitmap that resides inside an extent buffer. Later we verify the values of corresponding bits in the bitmap and the bitmap inside the extent buffer. However, extent_buffer_test_bit() reads in byte granularity while test_bit() reads in unsigned long granularity. Hence we end up comparing wrong bits on big-endian systems such as ppc64. This commit fixes the issue by reading the bitmap in byte granularity. Reviewed-by: Josef Bacik Reviewed-by: Chandan Rajendra Signed-off-by: Feifei Xu Signed-off-by: David Sterba fs/btrfs/tests/extent-io-tests.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 36b3dc05b4650e81eca7d60d548a92b014595eb1 Author: Feifei Xu Date: Wed Jun 1 19:18:29 2016 +0800 Btrfs: self-tests: Fix test_bitmaps fail on 64k sectorsize With 64K sectorsize, 1G sized block group cannot span across bitmaps. To execute test_bitmaps() function, this commit allocates "BITS_PER_BITMAP * sectorsize + PAGE_SIZE" sized block group. Reviewed-by: Josef Bacik Reviewed-by: Chandan Rajendra Signed-off-by: Feifei Xu Signed-off-by: David Sterba fs/btrfs/tests/free-space-tests.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit ef9f2db365c31433e52b0c5863793273bb632666 Author: Feifei Xu Date: Wed Jun 1 19:18:28 2016 +0800 Btrfs: self-tests: Use macros instead of constants and add missing newline This commit replaces numerical constants with appropriate preprocessor macros. Reviewed-by: Josef Bacik Signed-off-by: Chandan Rajendra Signed-off-by: Feifei Xu Signed-off-by: David Sterba fs/btrfs/disk-io.c | 3 ++- fs/btrfs/tests/extent-buffer-tests.c | 2 +- fs/btrfs/tests/qgroup-tests.c | 44 +++++++++++++++++++++++------------- 3 files changed, 31 insertions(+), 18 deletions(-) commit d94f43b4c6b88b9393422868d8dfde14c5923858 Author: Feifei Xu Date: Wed Jun 1 19:18:27 2016 +0800 Btrfs: self-tests: Support testing all possible sectorsizes and nodesizes To test all possible sectorsizes, this commit adds a sectorsize array. This commit executes the tests for all possible sectorsizes and nodesizes. Reviewed-by: Josef Bacik Signed-off-by: Chandan Rajendra Signed-off-by: Feifei Xu Signed-off-by: David Sterba fs/btrfs/super.c | 54 ++++++++++++++++++++++++++++++++---------------------- 1 file changed, 32 insertions(+), 22 deletions(-) commit ed9e4afdb0551e3ef4ee8433fe664433a20ef73a Author: Feifei Xu Date: Wed Jun 1 19:18:26 2016 +0800 Btrfs: self-tests: Execute page straddling test only when nodesize < PAGE_SIZE On ppc64, PAGE_SIZE is 64k which is same as BTRFS_MAX_METADATA_BLOCKSIZE. In such a scenario, we will never be able to have an extent buffer containing more than one page. Hence in such cases this commit does not execute the page straddling tests. Reviewed-by: Josef Bacik Signed-off-by: Feifei Xu Signed-off-by: Chandan Rajendra Signed-off-by: David Sterba fs/btrfs/tests/extent-io-tests.c | 49 ++++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 19 deletions(-) commit b581755b1c565391c72d03b157ba2dd0b18e9d15 Author: Miklos Szeredi Date: Mon Jun 6 16:21:37 2016 +0200 ovl: xattr filter fix a) ovl_need_xattr_filter() is wrong, we can have multiple lower layers overlaid, all of which (except the lowest one) honouring the "trusted.overlay.opaque" xattr. So need to filter everything except the bottom and the pure-upper layer. b) we no longer can assume that inode is attached to dentry in get/setxattr. This patch unconditionally filters private xattrs to fix both of the above. Performance impact for get/removexattrs is likely in the noise. For listxattrs it might be measurable in pathological cases, but I very much hope nobody cares. If they do, we'll fix it then. Reported-by: Vivek Goyal Signed-off-by: Miklos Szeredi Fixes: b96809173e94 ("security_d_instantiate(): move to the point prior to attaching dentry to inode") fs/overlayfs/inode.c | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) commit 08dd8cd06ed95625b9e2fac43c78fcb45b7eaf94 Author: Dr. David Alan Gilbert Date: Fri Jun 3 19:00:59 2016 +0100 x86/msr: Use the proper trace point conditional for writes The msr tracing for writes is incorrectly conditional on the read trace. Fixes: 7f47d8cc039f "x86, tracing, perf: Add trace point for MSR accesses" Signed-off-by: Dr. David Alan Gilbert Cc: stable@vger.kernel.org Cc: ak@linux.intel.com Link: http://lkml.kernel.org/r/1464976859-21850-1-git-send-email-dgilbert@redhat.com Signed-off-by: Thomas Gleixner arch/x86/include/asm/msr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5f9e1059d9347191b271bf7d13bd83db57594d2a Author: Jeff Mahoney Date: Wed Sep 16 15:34:53 2015 +0200 btrfs: advertise which crc32c implementation is being used at module load Since several architectures support hardware-accelerated crc32c calculation, it would be nice to confirm that btrfs is actually using it. We can see an elevated use count for the module, but it doesn't actually show who the users are. This patch simply prints the name of the driver after successfully initializing the shash. Signed-off-by: Jeff Mahoney [ added a helper and used in module load-time message ] Signed-off-by: David Sterba fs/btrfs/hash.c | 5 +++++ fs/btrfs/hash.h | 1 + fs/btrfs/super.c | 5 +++-- 3 files changed, 9 insertions(+), 2 deletions(-) commit 139ab4d4e68b8cf2a611b06c006a2195dc6bedf1 Author: Michael S. Tsirkin Date: Tue May 24 15:21:05 2016 +0300 tools/virtio: add noring tool Useful to measure testing framework overhead. Signed-off-by: Michael S. Tsirkin tools/virtio/ringtest/Makefile | 4 ++- tools/virtio/ringtest/noring.c | 69 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 72 insertions(+), 1 deletion(-) commit ef1b144d23dbd745fd655b7d0a70212fcc8d0121 Author: Mike Rapoport Date: Wed May 4 13:15:50 2016 +0300 tools/virtio/ringtest: fix run-on-all.sh to work without /dev/cpu /dev/cpu is only available on x86 with certain modules (e.g. msr) enabled. Using lscpu to get processors count is more portable. Signed-off-by: Mike Rapoport Signed-off-by: Michael S. Tsirkin tools/virtio/ringtest/run-on-all.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3b220cf867ce6881c7f671b27564c4cc13d8c4b8 Author: Mike Rapoport Date: Wed May 4 09:12:55 2016 +0300 tools/virtio/ringtest: add usage example to README Having typical usage example in the README file is more convinient than in the git history... Signed-off-by: Mike Rapoport Signed-off-by: Michael S. Tsirkin tools/virtio/ringtest/README | 4 ++++ 1 file changed, 4 insertions(+) commit 0e4191fe6f2f1a6ac360bcca0066c536f1ff9a6e Author: Geert Uytterhoeven Date: Sun May 22 11:06:27 2016 +0200 MAINTAINERS: Add file patterns for virtio device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven Cc: Michael S. Tsirkin Cc: virtualization@lists.linux-foundation.org Signed-off-by: Michael S. Tsirkin MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit e06cd3dd7cea50e87663a88acdfdb7ac1c53a5ca Author: Liu Bo Date: Fri Jun 3 12:05:15 2016 -0700 Btrfs: add validadtion checks for chunk loading To prevent fuzzed filesystem images from panic the whole system, we need various validation checks to refuse to mount such an image if btrfs finds any invalid value during loading chunks, including both sys_array and regular chunks. Note that these checks may not be sufficient to cover all corner cases, feel free to add more checks. Reported-by: Vegard Nossum Reported-by: Quentin Casasnovas Reviewed-by: David Sterba Signed-off-by: Liu Bo Signed-off-by: David Sterba fs/btrfs/volumes.c | 82 ++++++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 67 insertions(+), 15 deletions(-) commit 99e3ecfcb9f4ca35192d20a5bea158b81f600062 Author: Liu Bo Date: Fri Jun 3 12:05:14 2016 -0700 Btrfs: add more validation checks for superblock This adds validation checks for super_total_bytes, super_bytes_used and super_stripesize, super_num_devices. Reported-by: Vegard Nossum Reported-by: Quentin Casasnovas Reviewed-by: David Sterba Signed-off-by: Liu Bo Signed-off-by: David Sterba fs/btrfs/disk-io.c | 11 +++++++++++ fs/btrfs/volumes.c | 24 ++++++++++++++++++++++++ 2 files changed, 35 insertions(+) commit d865177a5e749827f248f6363f5100d3a2f66b0f Author: Liu Bo Date: Fri Jun 3 17:41:42 2016 -0700 Btrfs: clear uptodate flags of pages in sys_array eb We set uptodate flag to pages in the temporary sys_array eb, but do not clear the flag after free eb. As the special btree inode may still hold a reference on those pages, the uptodate flag can remain alive in them. If btrfs_super_chunk_root has been intentionally changed to the offset of this sys_array eb, reading chunk_root will read content of sys_array and it will skip our beautiful checks in btree_readpage_end_io_hook() because of "pages of eb are uptodate => eb is uptodate" This adds the 'clear uptodate' part to force it to read from disk. Reviewed-by: Josef Bacik Signed-off-by: Liu Bo Signed-off-by: David Sterba fs/btrfs/volumes.c | 2 ++ 1 file changed, 2 insertions(+) commit a02cc9d3cc9f98905df214d4a57e5918473260ea Author: Michal Schmidt Date: Fri Jun 3 15:32:18 2016 +0200 bnx2x: allow adding VLANs while interface is down Since implementing VLAN filtering in commit 05cc5a39ddb74 ("bnx2x: add vlan filtering offload") bnx2x refuses to add a VLAN while the interface is down: # ip link add link enp3s0f0 enp3s0f0_10 type vlan id 10 RTNETLINK answers: Bad address and in dmesg (with bnx2x.debug=0x20): bnx2x: [bnx2x_vlan_rx_add_vid:12941(enp3s0f0)]Ignoring VLAN configuration the interface is down Other drivers have no problem with this. Fix this peculiar behavior in the following way: - Accept requests to add/kill VID regardless of the device state. Maintain the requested list of VIDs in the bp->vlan_reg list. - If the device is up, try to configure the VID list into the hardware. If we run out of VLAN credits or encounter a failure configuring an entry, fall back to accepting all VLANs. If we successfully configure all entries from the list, turn the fallback off. - Use the same code for reconfiguring VLANs during NIC load. Signed-off-by: Michal Schmidt Acked-by: Yuval Mintz Signed-off-by: David S. Miller drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c | 151 ++++++++++------------- 1 file changed, 62 insertions(+), 89 deletions(-) commit 8a934efe94347eee843aeea65bdec8077a79e259 Author: Gavin Shan Date: Thu May 26 09:56:07 2016 +1000 powerpc/pseries: Fix PCI config address for DDW In commit 8445a87f7092 "powerpc/iommu: Remove the dependency on EEH struct in DDW mechanism", the PE address was replaced with the PCI config address in order to remove dependency on EEH. According to PAPR spec, firmware (pHyp or QEMU) should accept "xxBBSSxx" format PCI config address, not "xxxxBBSS" provided by the patch. Note that "BB" is PCI bus number and "SS" is the combination of slot and function number. This fixes the PCI address passed to DDW RTAS calls. Fixes: 8445a87f7092 ("powerpc/iommu: Remove the dependency on EEH struct in DDW mechanism") Cc: stable@vger.kernel.org # v3.4+ Reported-by: Guilherme G. Piccoli Signed-off-by: Gavin Shan Tested-by: Guilherme G. Piccoli Signed-off-by: Michael Ellerman arch/powerpc/platforms/pseries/iommu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1e407ee3b21f981140491d5b8a36422979ca246f Author: Khem Raj Date: Mon Apr 25 09:19:17 2016 -0700 powerpc/ptrace: Fix out of bounds array access warning gcc-6 correctly warns about a out of bounds access arch/powerpc/kernel/ptrace.c:407:24: warning: index 32 denotes an offset greater than size of 'u64[32][1] {aka long long unsigned int[32][1]}' [-Warray-bounds] offsetof(struct thread_fp_state, fpr[32][0])); ^ check the end of array instead of beginning of next element to fix this Signed-off-by: Khem Raj Cc: Kees Cook Cc: Michael Ellerman Cc: Segher Boessenkool Tested-by: Aaro Koskinen Acked-by: Olof Johansson Signed-off-by: Michael Ellerman arch/powerpc/kernel/ptrace.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3ec10d3a2ba591c87da94219c1e46b02ae97757a Author: Marco Angaroni Date: Mon May 16 19:18:09 2016 +0200 ipvs: update real-server binding of outgoing connections in SIP-pe Previous patch that introduced handling of outgoing packets in SIP persistent-engine did not call ip_vs_check_template() in case packet was matching a connection template. Assumption was that real-server was healthy, since it was sending a packet just in that moment. There are however real-server fault conditions requiring that association between call-id and real-server (represented by connection template) gets updated. Here is an example of the sequence of events: 1) RS1 is a back2back user agent that handled call-id1 and call-id2 2) RS1 is down and was marked as unavailable 3) new message from outside comes to IPVS with call-id1 4) IPVS reschedules the message to RS2, which becomes new call handler 5) RS2 forwards the message outside, translating call-id1 to call-id2 6) inside pe->conn_out() IPVS matches call-id2 with existing template 7) IPVS does not change association call-id2 <-> RS1 8) new message comes from client with call-id2 9) IPVS reschedules the message to a real-server potentially different from RS2, which is now the correct destination This patch introduces ip_vs_check_template() call in the handling of outgoing packets for SIP-pe. And also introduces a second optional argument for ip_vs_check_template() that allows to check if dest associated to a connection template is the same dest that was identified as the source of the packet. This is to change the real-server bound to a particular call-id independently from its availability status: the idea is that it's more reliable, for in->out direction (where internal network can be considered trusted), to always associate a call-id with the last real-server that used it in one of its messages. Think about above sequence of events where, just after step 5, RS1 returns instead to be available. Comparison of dests is done by simply comparing pointers to struct ip_vs_dest; there should be no cases where struct ip_vs_dest keeps its memory address, but represent a different real-server in terms of ip-address / port. Fixes: 39b972231536 ("ipvs: handle connections started by real-servers") Signed-off-by: Marco Angaroni Acked-by: Julian Anastasov Signed-off-by: Simon Horman include/net/ip_vs.h | 2 +- net/netfilter/ipvs/ip_vs_conn.c | 5 +++-- net/netfilter/ipvs/ip_vs_core.c | 5 +++-- 3 files changed, 7 insertions(+), 5 deletions(-) commit af8c34ce6ae32addda3788d54a7e340cad22516b Author: Linus Torvalds Date: Sun Jun 5 14:31:26 2016 -0700 Linux 4.7-rc2 Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5975b2c0c10adbc7894a54ab7b30db4fbcdd8c41 Merge: d834502 58f1c65 Author: Linus Torvalds Date: Sun Jun 5 11:15:33 2016 -0700 Merge branch 'parisc-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux Pull parisc fixes from Helge Deller: - Fix printk time stamps on SMP systems which got wrong due to a patch which was added during the merge window - Fix two bugs in the stack backtrace code: Races in module unloading and possible invalid accesses to memory due to wrong instruction decoding (Mikulas Patocka) - Fix userspace crash when syscalls access invalid unaligned userspace addresses. Those syscalls will now return EFAULT as expected. (tagged for stable kernel series) * 'parisc-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux: parisc: Move die_if_kernel() prototype into traps.h header parisc: Fix pagefault crash in unaligned __get_user() call parisc: Fix printk time during boot parisc: Fix backtrace on PA-RISC commit d834502e2fca9380a1579fecd134ef94c063b662 Merge: eedf265 4693fc7 Author: Linus Torvalds Date: Sun Jun 5 11:02:00 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull key handling update from James Morris: "This alters a new keyctl function added in the current merge window to allow for a future extension planned for the next merge window" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: KEYS: Add placeholder for KDF usage with DH commit eedf265aa003b4781de24cfed40a655a664457e6 Author: Eric W. Biederman Date: Thu Jun 2 10:29:47 2016 -0500 devpts: Make each mount of devpts an independent filesystem. The /dev/ptmx device node is changed to lookup the directory entry "pts" in the same directory as the /dev/ptmx device node was opened in. If there is a "pts" entry and that entry is a devpts filesystem /dev/ptmx uses that filesystem. Otherwise the open of /dev/ptmx fails. The DEVPTS_MULTIPLE_INSTANCES configuration option is removed, so that userspace can now safely depend on each mount of devpts creating a new instance of the filesystem. Each mount of devpts is now a separate and equal filesystem. Reserved ttys are now available to all instances of devpts where the mounter is in the initial mount namespace. A new vfs helper path_pts is introduced that finds a directory entry named "pts" in the directory of the passed in path, and changes the passed in path to point to it. The helper path_pts uses a function path_parent_directory that was factored out of follow_dotdot. In the implementation of devpts: - devpts_mnt is killed as it is no longer meaningful if all mounts of devpts are equal. - pts_sb_from_inode is replaced by just inode->i_sb as all cached inodes in the tty layer are now from the devpts filesystem. - devpts_add_ref is rolled into the new function devpts_ptmx. And the unnecessary inode hold is removed. - devpts_del_ref is renamed devpts_release and reduced to just a deacrivate_super. - The newinstance mount option continues to be accepted but is now ignored. In devpts_fs.h definitions for when !CONFIG_UNIX98_PTYS are removed as they are never used. Documentation/filesystems/devices.txt is updated to describe the current situation. This has been verified to work properly on openwrt-15.05, centos5, centos6, centos7, debian-6.0.2, debian-7.9, debian-8.2, ubuntu-14.04.3, ubuntu-15.10, fedora23, magia-5, mint-17.3, opensuse-42.1, slackware-14.1, gentoo-20151225 (13.0?), archlinux-2015-12-01. With the caveat that on centos6 and on slackware-14.1 that there wind up being two instances of the devpts filesystem mounted on /dev/pts, the lower copy does not end up getting used. Signed-off-by: "Eric W. Biederman" Cc: Greg KH Cc: Peter Hurley Cc: Peter Anvin Cc: Andy Lutomirski Cc: Al Viro Cc: Serge Hallyn Cc: Willy Tarreau Cc: Aurelien Jarno Cc: One Thousand Gnomes Cc: Jann Horn Cc: Jiri Slaby Cc: Florian Weimer Cc: Konstantin Khlebnikov Signed-off-by: Linus Torvalds Documentation/filesystems/devpts.txt | 145 +++----------------------- drivers/tty/Kconfig | 11 -- drivers/tty/pty.c | 15 +-- fs/devpts/inode.c | 191 ++++++++++------------------------- fs/namei.c | 49 +++++++-- include/linux/devpts_fs.h | 9 +- include/linux/namei.h | 2 + 7 files changed, 126 insertions(+), 296 deletions(-) commit 58f1c654d13a42575d507ea61f6de0332a761e75 Author: Helge Deller Date: Sat Jun 4 17:38:09 2016 +0200 parisc: Move die_if_kernel() prototype into traps.h header Signed-off-by: Helge Deller arch/parisc/include/asm/traps.h | 2 ++ arch/parisc/kernel/unaligned.c | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) commit 8b78f260887df532da529f225c49195d18fef36b Author: Helge Deller Date: Sat Jun 4 17:21:33 2016 +0200 parisc: Fix pagefault crash in unaligned __get_user() call One of the debian buildd servers had this crash in the syslog without any other information: Unaligned handler failed, ret = -2 clock_adjtime (pid 22578): Unaligned data reference (code 28) CPU: 1 PID: 22578 Comm: clock_adjtime Tainted: G E 4.5.0-2-parisc64-smp #1 Debian 4.5.4-1 task: 000000007d9960f8 ti: 00000001bde7c000 task.ti: 00000001bde7c000 YZrvWESTHLNXBCVMcbcbcbcbOGFRQPDI PSW: 00001000000001001111100000001111 Tainted: G E r00-03 000000ff0804f80f 00000001bde7c2b0 00000000402d2be8 00000001bde7c2b0 r04-07 00000000409e1fd0 00000000fa6f7fff 00000001bde7c148 00000000fa6f7fff r08-11 0000000000000000 00000000ffffffff 00000000fac9bb7b 000000000002b4d4 r12-15 000000000015241c 000000000015242c 000000000000002d 00000000fac9bb7b r16-19 0000000000028800 0000000000000001 0000000000000070 00000001bde7c218 r20-23 0000000000000000 00000001bde7c210 0000000000000002 0000000000000000 r24-27 0000000000000000 0000000000000000 00000001bde7c148 00000000409e1fd0 r28-31 0000000000000001 00000001bde7c320 00000001bde7c350 00000001bde7c218 sr00-03 0000000001200000 0000000001200000 0000000000000000 0000000001200000 sr04-07 0000000000000000 0000000000000000 0000000000000000 0000000000000000 IASQ: 0000000000000000 0000000000000000 IAOQ: 00000000402d2e84 00000000402d2e88 IIR: 0ca0d089 ISR: 0000000001200000 IOR: 00000000fa6f7fff CPU: 1 CR30: 00000001bde7c000 CR31: ffffffffffffffff ORIG_R28: 00000002369fe628 IAOQ[0]: compat_get_timex+0x2dc/0x3c0 IAOQ[1]: compat_get_timex+0x2e0/0x3c0 RP(r2): compat_get_timex+0x40/0x3c0 Backtrace: [<00000000402d4608>] compat_SyS_clock_adjtime+0x40/0xc0 [<0000000040205024>] syscall_exit+0x0/0x14 This means the userspace program clock_adjtime called the clock_adjtime() syscall and then crashed inside the compat_get_timex() function. Syscalls should never crash programs, but instead return EFAULT. The IIR register contains the executed instruction, which disassebles into "ldw 0(sr3,r5),r9". This load-word instruction is part of __get_user() which tried to read the word at %r5/IOR (0xfa6f7fff). This means the unaligned handler jumped in. The unaligned handler is able to emulate all ldw instructions, but it fails if it fails to read the source e.g. because of page fault. The following program reproduces the problem: #define _GNU_SOURCE #include #include #include int main(void) { /* allocate 8k */ char *ptr = mmap(NULL, 2*4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0); /* free second half (upper 4k) and make it invalid. */ munmap(ptr+4096, 4096); /* syscall where first int is unaligned and clobbers into invalid memory region */ /* syscall should return EFAULT */ return syscall(__NR_clock_adjtime, 0, ptr+4095); } To fix this issue we simply need to check if the faulting instruction address is in the exception fixup table when the unaligned handler failed. If it is, call the fixup routine instead of crashing. While looking at the unaligned handler I found another issue as well: The target register should not be modified if the handler was unsuccessful. Signed-off-by: Helge Deller Cc: stable@vger.kernel.org arch/parisc/kernel/unaligned.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 0032c08833ab7c7861d12eb35da26dce85f3e229 Author: Helge Deller Date: Fri Jun 3 19:22:31 2016 +0200 parisc: Fix printk time during boot Avoid showing invalid printk time stamps during boot. Signed-off-by: Helge Deller Reviewed-by: Aaro Koskinen arch/parisc/kernel/processor.c | 5 +++-- arch/parisc/kernel/time.c | 5 ----- 2 files changed, 3 insertions(+), 7 deletions(-) commit e6ec03a25f12b312b7e0c037fe4a6471c4ee5665 Author: Al Viro Date: Sun Jun 5 00:23:09 2016 -0400 autofs braino fix for do_last() It's an analogue of commit 7500c38a (fix the braino in "namei: massage lookup_slow() to be usable by lookup_one_len_unlocked()"). The same problem (->lookup()-returned unhashed negative dentry just might be an autofs one with ->d_manage() that would wait until the daemon makes it positive) applies in do_last() - we need to do follow_managed() first. Fortunately, remaining callers of follow_managed() are OK - only autofs has that weirdness (negative dentry that does not mean an instant -ENOENT)) and autofs never has its negative dentries hashed, so we can't pick one from a dcache lookup. ->d_manage() is a bloody mess ;-/ Cc: stable@vger.kernel.org # v4.6 Spotted-by: Ian Kent Signed-off-by: Al Viro fs/namei.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4ef36e156670c2d835ccb4000a561ece4e598fd9 Merge: e7eacc9 182fd9e Author: David S. Miller Date: Sat Jun 4 22:14:53 2016 -0400 Merge tag 'wireless-drivers-for-davem-2016-06-04' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers Kalle Valo says: ==================== wireless-drivers fixes for 4.7 brcmfmac * add fallback RSSI report for devices that do not report per-chain values * fix a null pointer derefence regression on PCIe full dongle devices rtlwifi * fix scheduling while atomic regression from commit 49f86ec21c01 MAINTAINERS * add file patterns for wireless device tree bindings ==================== Signed-off-by: David S. Miller commit be24a89700eef61bedaba40f3b05ef07f5806e38 Author: Mikulas Patocka Date: Wed Jun 29 00:48:19 2011 +0200 parisc: Fix backtrace on PA-RISC This patch fixes backtrace on PA-RISC There were several problems: 1) The code that decodes instructions handles instructions that subtract from the stack pointer incorrectly. If the instruction subtracts the number X from the stack pointer the code increases the frame size by (0x100000000-X). This results in invalid accesses to memory and recursive page faults. 2) Because gcc reorders blocks, handling instructions that subtract from the frame pointer is incorrect. For example, this function int f(int a) { if (__builtin_expect(a, 1)) return a; g(); return a; } is compiled in such a way, that the code that decreases the stack pointer for the first "return a" is placed before the code for "g" call. If we recognize this decrement, we mistakenly believe that the frame size for the "g" call is zero. To fix problems 1) and 2), the patch doesn't recognize instructions that decrease the stack pointer at all. To further safeguard the unwind code against nonsense values, we don't allow frame size larger than Total_frame_size. 3) The backtrace is not locked. If stack dump races with module unload, invalid table can be accessed. This patch adds a spinlock when processing module tables. Note, that for correct backtrace, you need recent binutils. Binutils 2.18 from Debian 5 produce garbage unwind tables. Binutils 2.21 work better (it sometimes forgets function frames, but at least it doesn't generate garbage). Signed-off-by: Mikulas Patocka Signed-off-by: Helge Deller arch/parisc/kernel/unwind.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit 049ec1b5a76d34a6980cccdb7c0baeb4eed7a993 Merge: f2c6b9e ab3ab68 Author: Linus Torvalds Date: Sat Jun 4 12:30:36 2016 -0700 Merge tag 'drm-fixes-for-v4.7-rc2' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: "A bunch of ARM drivers got into the fixes vibe this time around, so this contains a bunch of fixes for imx, atmel hlcdc, arm hdlcd (only so many combos of hlcd), mediatek and omap drm. Other than that there is one mgag200 fix and a few core drm regression fixes" * tag 'drm-fixes-for-v4.7-rc2' of git://people.freedesktop.org/~airlied/linux: (34 commits) drm/omap: fix unused variable warning. drm: hdlcd: Add information about the underlying framebuffers in debugfs drm: hdlcd: Cleanup the atomic plane operations drm/hdlcd: Fix up crtc_state->event handling drm: hdlcd: Revamp runtime power management drm/mediatek: mtk_dsi: Remove spurious drm_connector_unregister drm/mediatek: mtk_dpi: remove invalid error message drm: atmel-hlcdc: fix a NULL check drm: atmel-hlcdc: fix atmel_hlcdc_crtc_reset() implementation drm/mgag200: Black screen fix for G200e rev 4 drm: Wrap direct calls to driver->gem_free_object from CMA drm: fix fb refcount issue with atomic modesetting drm: make drm_atomic_set_mode_prop_for_crtc() more reliable drm/sti: remove extra mode fixup drm: add missing drm_mode_set_crtcinfo call drm/omap: include gpio/consumer.h where needed drm/omap: include linux/seq_file.h where needed Revert "drm/omap: no need to select OMAP2_DSS" drm/omap: Remove regulator API abuse OMAPDSS: HDMI5: Change DDC timings ... commit f2c6b9e4b2708ae50e3ab8c91dcad1564974f2a4 Merge: 95b46ae ce7585f Author: Linus Torvalds Date: Sat Jun 4 12:25:36 2016 -0700 Merge tag 'vfio-v4.7-rc2' of git://github.com/awilliam/linux-vfio Pull VFIO fixes from Alex Williamson: "Fix irqfd shutdown ordering, build warning, and VPD short read" * tag 'vfio-v4.7-rc2' of git://github.com/awilliam/linux-vfio: vfio/pci: Allow VPD short read vfio/type1: Fix build warning vfio/pci: Fix ordering of eventfd vs virqfd shutdown commit 95b46aeb05c53726236a2a468ad16119afd42b2c Merge: b2d5ad8 afefc10 Author: Linus Torvalds Date: Sat Jun 4 12:20:26 2016 -0700 Merge tag 'mmc-v4.7-rc1-2' of git://git.linaro.org/people/ulf.hansson/mmc Pull MMC fixes from Ulf Hansson: "MMC core: - Fix/restore behaviour when selecting bus width for (e)MMC MMC host: - sunxi: Fix eMMC HS-DDR modes on Allwinner A80" * tag 'mmc-v4.7-rc1-2' of git://git.linaro.org/people/ulf.hansson/mmc: mmc: sunxi: Re-enable eMMC HS-DDR modes on Allwinner A80 mmc: sunxi: Fix DDR MMC timings for A80 mmc: fix mmc mode selection for HS-DDR and higher commit b2d5ad822322cfb5dd33e90484ed7df4ee6e68ee Merge: a3021a5 8dff9c8 Author: Linus Torvalds Date: Sat Jun 4 11:56:28 2016 -0700 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs fixes from Chris Mason: "The important part of this pull is Filipe's set of fixes for btrfs device replacement. Filipe fixed a few issues seen on the list and a number he found on his own" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: deal with duplciates during extent_map insertion in btrfs_get_extent Btrfs: fix race between device replace and read repair Btrfs: fix race between device replace and discard Btrfs: fix race between device replace and chunk allocation Btrfs: fix race setting block group back to RW mode during device replace Btrfs: fix unprotected assignment of the left cursor for device replace Btrfs: fix race setting block group readonly during device replace Btrfs: fix race between device replace and block group removal Btrfs: fix race between readahead and device replace/removal commit a9e26cab40ecfd4a0d718f22fa30db4dd1edbf60 Author: Rob Clark Date: Wed Jun 1 14:02:51 2016 -0400 drm/msm: fix potential submit error path issue Signed-off-by: Rob Clark drivers/gpu/drm/msm/msm_gem_submit.c | 5 +++++ 1 file changed, 5 insertions(+) commit ba344afd667a6f1c6bf7c53e08fc16bd84fa4df7 Author: Rob Clark Date: Tue May 24 18:43:26 2016 -0400 drm/msm: fix some crashes in submit fail path If submit fails, before fence is created or before submit is added to submit-list, then unitialized fields cause problems in the clean-up path. Signed-off-by: Rob Clark drivers/gpu/drm/msm/msm_gem_submit.c | 2 ++ 1 file changed, 2 insertions(+) commit 69a834c28fb514403eb91a4f0120da214a52e056 Author: Rob Clark Date: Tue May 24 18:29:38 2016 -0400 drm/msm: deal with exhausted vmap space better Some, but not all, callers of obj->vmap() would check if return IS_ERR(). So let's actually return an error if vmap() fails. And fixup the call-sites that were not handling this properly. Signed-off-by: Rob Clark drivers/gpu/drm/msm/adreno/adreno_gpu.c | 2 +- drivers/gpu/drm/msm/msm_fbdev.c | 4 ++++ drivers/gpu/drm/msm/msm_gem.c | 2 ++ drivers/gpu/drm/msm/msm_rd.c | 3 +++ drivers/gpu/drm/msm/msm_ringbuffer.c | 4 ++++ 5 files changed, 14 insertions(+), 1 deletion(-) commit a3021a59cac40681b2c131c84cdd4b471793d524 Merge: eb10a7b f6973c0 Author: Linus Torvalds Date: Sat Jun 4 11:37:53 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client Pull Ceph fixes from Sage Weil: "We have a few follow-up fixes for the libceph refactor from Ilya, and then some cephfs + fscache fixes from Zheng. The first two FS-Cache patches are acked by David Howells and deemed trivial enough to go through our tree. The rest fix some issues with the ceph fscache handling (disable cache for inodes opened for write, and simplify the revalidation logic accordingly, dropping the now-unnecessary work queue)" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: ceph: use i_version to check validity of fscache ceph: improve fscache revalidation ceph: disable fscache when inode is opened for write ceph: avoid unnecessary fscache invalidation/revlidation ceph: call __fscache_uncache_page() if readpages fails FS-Cache: make check_consistency callback return int FS-Cache: wake write waiter after invalidating writes libceph: use %s instead of %pE in dout()s libceph: put request only if it's done in handle_reply() libceph: change ceph_osdmap_flag() to take osdc commit eb10a7b7befd07d4c28903029b238dc66f5dd570 Merge: 5016320 60c07f8 Author: Linus Torvalds Date: Sat Jun 4 11:26:49 2016 -0700 Merge tag 'acpi-4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fixes from Rafael Wysocki: "Two fixes for problems introduced recently (ACPICA and the ACPI backlight driver) and one fix for an older issue that prevents at least one system from booting. Specifics: - Fix an incorrect check introduced by recent ACPICA changes which causes problems with booting KVM guests to happen, among other things (Lv Zheng). - Fix a backlight issue introduced by recent changes to the ACPI video driver (Aaron Lu). - Fix the ACPI processor initialization which attempts to register an IO region without checking if that really is necessary and sometimes prevents drivers loaded subsequently from registering their resources which leads to boot issues (Rafael Wysocki)" * tag 'acpi-4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / processor: Avoid reserving IO regions too early ACPICA / Hardware: Fix old register check in acpi_hw_get_access_bit_width() ACPI / Thermal / video: fix max_level incorrect value commit 50163203e31c292a8ab00bce077077f996c74276 Merge: d46d025 8cd8cbd Author: Linus Torvalds Date: Sat Jun 4 11:07:57 2016 -0700 Merge tag 'pm-4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: "Two fixes for problems introduced recently in the cpufreq core and the intel_pstate driver. Specifics: - Fix a silly mistake related to the clamp_val() usage in a function added by a recent commit (Rafael Wysocki). - Reduce the log level of an annoying message added to intel_pstate during the recent merge window (Srinivas Pandruvada)" * tag 'pm-4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: cpufreq: Fix clamp_val() usage in cpufreq_driver_fast_switch() cpufreq: intel_pstate: Downgrade print level for _PPC commit d46d0256cd030f196185078a4a8863563425b624 Merge: 8c52b6d e46e7b7 Author: Linus Torvalds Date: Sat Jun 4 10:51:29 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge various fixes from Andrew Morton: "10 fixes" * emailed patches from Andrew Morton : mm, page_alloc: recalculate the preferred zoneref if the context can ignore memory policies mm, page_alloc: reset zonelist iterator after resetting fair zone allocation policy mm, oom_reaper: do not use siglock in try_oom_reaper() mm, page_alloc: prevent infinite loop in buffered_rmqueue() checkpatch: reduce git commit description style false positives mm/z3fold.c: avoid modifying HEADLESS page and minor cleanup memcg: add RCU locking around css_for_each_descendant_pre() in memcg_offline_kmem() mm: check the return value of lookup_page_ext for all call sites kdump: fix dmesg gdbmacro to work with record based printk mm: fix overflow in vm_map_ram() commit fac7d1917dfddfa53e98524f0abfbe60252740fe Author: Al Viro Date: Sat Jun 4 11:41:49 2016 -0400 fix EOPENSTALE bug in do_last() EOPENSTALE occuring at the last component of a trailing symlink ends up with do_last() retrying its lookup. After the symlink body has been discarded. The thing is, all this retry_lookup logics in there is not needed at all - the upper layers will do the right thing if we simply return that -EOPENSTALE as we would with any other error. Trying to microoptimize in do_last() is a lot of headache for no good reason. Cc: stable@vger.kernel.org # v4.2+ Tested-by: Oleg Drokin Reviewed-and-Tested-by: Jeff Layton Signed-off-by: Al Viro fs/namei.c | 43 ++++--------------------------------------- 1 file changed, 4 insertions(+), 39 deletions(-) commit 182fd9eecb287e696c82b30d06c6150d80a49c5b Author: Geert Uytterhoeven Date: Sun May 22 11:06:10 2016 +0200 MAINTAINERS: Add file patterns for wireless device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven Cc: Kalle Valo Cc: linux-wireless@vger.kernel.org Signed-off-by: Kalle Valo MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 27ea13e6186c1a5bd0fa2b0d6f854d60ca4ca4c9 Merge: b02b1fb 6b7e9cd Author: James Bottomley Date: Sat Jun 4 09:53:29 2016 -0400 Merge remote-tracking branch 'mkp-scsi/4.7/scsi-fixes' into fixes commit e7eacc9e0bc5338e5b347750c305d99f93279404 Merge: 8478b6c 37920fc Author: David S. Miller Date: Fri Jun 3 19:54:23 2016 -0400 Merge branch 'mediatek-fixes' John Crispin says: ==================== net-next: mediatek: improve phy support The current driver did not handle the RGMII delay modes and asymmetric flow control properly. The mii_bus is not freed properly. Also add support for fixed-phy allowing the driver to work on SoCs that have an internal gigabit switch. ==================== Signed-off-by: David S. Miller commit 37920fce0fc10264410eb880d411968b7934b61d Author: John Crispin Date: Fri Jun 3 10:17:09 2016 +0200 net-next: mediatek: properly handle RGMII modes If an external Gigabit PHY is connected to either of the MACs we need to be able to tell the PHY to use a delay. Not doing so will result in heavy packet loss and/or data corruption when using PHYs such as the IC+ IP1001. We tell the PHY which MII delay mode to use via the devictree. The ethernet driver needs to be adapted to handle all 3 rgmii-*id modes in the same way as normal rgmii when setting up the MAC. Reviewed-by: Andrew Lunn Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +++ 1 file changed, 3 insertions(+) commit 0c72c50f6f93b0c3daa9ea35d89ab3a933c7b5a0 Author: John Crispin Date: Fri Jun 3 10:17:08 2016 +0200 net-next: mediatek: add fixed-phy support The MT7623 SoC has a builtin gigabit switch. If we want to use it, GMAC1 needs to be configured using a fixed link speed and flow control settings. The easiest way to do this is to used the fixed-phy driver, allowing us to reuse the existing mdio polling code to setup the MAC. Reviewed-by: Andrew Lunn Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +++ 1 file changed, 3 insertions(+) commit 08ef55c6f257acf3bdc6940813f80e8f0f5d90ec Author: John Crispin Date: Fri Jun 3 10:17:07 2016 +0200 net-next: mediatek: fix gigabit and flow control advertisement The current code will not setup the PHYs advertisement features correctly. Fix this and properly advertise Gigabit features and properly handle asymmetric pause frames. Signed-off-by: Sean Wang Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 30 +++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) commit 207bdf1844286d2ba94523d30528f82aaf33d52b Author: John Crispin Date: Fri Jun 3 10:17:06 2016 +0200 net-next: mediatek: use mdiobus_free() in favour of kfree() The driver currently uses kfree() to clear the mii_bus. This is not the correct way to clear the memory and mdiobus_free() should be used instead. This patch fixes the two instances where this happens in the driver. Reviewed-by: Andrew Lunn Signed-off-by: John Crispin Signed-off-by: David S. Miller drivers/net/ethernet/mediatek/mtk_eth_soc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8478b6cdc10e8a7735deeb9d9e46ad5b157c84d0 Author: Ivan Khoronzhuk Date: Thu Jun 2 16:14:52 2016 +0300 net: ethernet: ti: cpsw: fix rx-usecs interrupt pacing consistency The rx-usecs shouldn't be changed while interface down/up. Currently, for instance, if it's set to 100us, after interface down/up it's 500us. It's a hidden bug that can lead to lavish interrupt pacing time increasing while "down/up" up to max value. Steps to reproduce: - set rx-usecs to be 100us - down/up interface - read new unexpected rx-usecs Signed-off-by: Ivan Khoronzhuk Reviewed-by: Grygorii Strashko Signed-off-by: David S. Miller drivers/net/ethernet/ti/cpsw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9c8b0778e48e4bbdb77121c6c1b7dd48e5182e67 Author: Yangbo Lu Date: Thu Jun 2 17:36:28 2016 +0800 gianfar: fix the last transmit buffer descriptor When the transmit hardware timestamping is enabled, an additional TxBD would be added and would be set as the last TxBD with TXBD_LAST and TXBD_INTERRUPT. However this has been broken by a patch recently. This made the software couldn't get transmit hardware timestamps and resulted in call trace. So, this patch is to fix this issue. Fixes: 48963b4492e9 ("gianfar: Remove redundant ops for do_tstamp from xmit()") Signed-off-by: Yangbo Lu Reviewed-by: Claudiu Manoil Signed-off-by: David S. Miller drivers/net/ethernet/freescale/gianfar.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8d5958f424b62060a8696b12c17dad198d5d386f Author: WANG Cong Date: Wed Jun 1 16:15:19 2016 -0700 sch_tbf: update backlog as well Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_tbf.c | 4 ++++ 1 file changed, 4 insertions(+) commit d7f4f332f082c4d4ba53582f902ed6b44fd6f45e Author: WANG Cong Date: Wed Jun 1 16:15:18 2016 -0700 sch_red: update backlog as well Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_red.c | 4 ++++ 1 file changed, 4 insertions(+) commit 6a73b571b63075ef408c83f07c2565b5652f93cc Author: WANG Cong Date: Wed Jun 1 16:15:17 2016 -0700 sch_drr: update backlog as well Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_drr.c | 4 ++++ 1 file changed, 4 insertions(+) commit 6529d75ad9228f4d8a8f6c5c5244ceb945ac9bc2 Author: WANG Cong Date: Wed Jun 1 16:15:16 2016 -0700 sch_prio: update backlog as well We need to update backlog too when we update qlen. Joint work with Stas. Reported-by: Stas Nichiporovich Tested-by: Stas Nichiporovich Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_prio.c | 4 ++++ 1 file changed, 4 insertions(+) commit 357cc9b4a8a7a0cd0e662537b76e6fa4670b6798 Author: WANG Cong Date: Wed Jun 1 16:15:15 2016 -0700 sch_hfsc: always keep backlog updated hfsc updates backlog lazily, that is only when we dump the stats. This is problematic after we begin to update backlog in qdisc_tree_reduce_backlog(). Reported-by: Stas Nichiporovich Tested-by: Stas Nichiporovich Fixes: 2ccccf5fb43f ("net_sched: update hierarchical backlog too") Cc: Jamal Hadi Salim Signed-off-by: Cong Wang Signed-off-by: David S. Miller net/sched/sch_hfsc.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 8c52b6dcdd1994ad0d2672e43c8d975d5c8195c3 Merge: 2c22132 2eec370 Author: Linus Torvalds Date: Fri Jun 3 16:12:35 2016 -0700 Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull irq fixes from Thomas Gleixner: - a few simple fixes for fallout from the recent gic-v3 changes - a workaround for a Cavium thunderX erratum - a bugfix for the pic32 irqchip to make external interrupts work proper - a missing return value in the generic IPI management code * 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: irqchip/irq-pic32-evic: Fix bug with external interrupts. irqchip/gicv3-its: numa: Enable workaround for Cavium thunderx erratum 23144 irqchip/gic-v3: Fix quiescence check in gic_enable_redist irqchip/gic-v3: Fix copy+paste mistakes in defines irqchip/gic-v3: Fix ICC_SGI1R_EL1.INTID decoding mask genirq: Fix missing return value in irq_destroy_ipi() commit e46e7b77c9096eb2f4d6bcb9ca0b64c9338465ee Author: Mel Gorman Date: Fri Jun 3 14:56:01 2016 -0700 mm, page_alloc: recalculate the preferred zoneref if the context can ignore memory policies The optimistic fast path may use cpuset_current_mems_allowed instead of of a NULL nodemask supplied by the caller for cpuset allocations. The preferred zone is calculated on this basis for statistic purposes and as a starting point in the zonelist iterator. However, if the context can ignore memory policies due to being atomic or being able to ignore watermarks then the starting point in the zonelist iterator is no longer correct. This patch resets the zonelist iterator in the allocator slowpath if the context can ignore memory policies. This will alter the zone used for statistics but only after it is known that it makes sense for that context. Resetting it before entering the slowpath would potentially allow an ALLOC_CPUSET allocation to be accounted for against the wrong zone. Note that while nodemask is not explicitly set to the original nodemask, it would only have been overwritten if cpuset_enabled() and it was reset before the slowpath was entered. Link: http://lkml.kernel.org/r/20160602103936.GU2527@techsingularity.net Fixes: c33d6c06f60f710 ("mm, page_alloc: avoid looking up the first zone in a zonelist twice") Signed-off-by: Mel Gorman Reported-by: Geert Uytterhoeven Tested-by: Geert Uytterhoeven Acked-by: Vlastimil Babka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_alloc.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) commit 0d0bd89435d19faa3f2fd73f7ee11c64ac9304f4 Author: Mel Gorman Date: Fri Jun 3 14:55:58 2016 -0700 mm, page_alloc: reset zonelist iterator after resetting fair zone allocation policy Geert Uytterhoeven reported the following problem that bisected to commit c33d6c06f60f ("mm, page_alloc: avoid looking up the first zone in a zonelist twice") on m68k/ARAnyM BUG: scheduling while atomic: cron/668/0x10c9a0c0 Modules linked in: CPU: 0 PID: 668 Comm: cron Not tainted 4.6.0-atari-05133-gc33d6c06f60f710f #364 Call Trace: [<0003d7d0>] __schedule_bug+0x40/0x54 __schedule+0x312/0x388 __schedule+0x0/0x388 prepare_to_wait+0x0/0x52 schedule+0x64/0x82 schedule_timeout+0xda/0x104 set_next_entity+0x18/0x40 pick_next_task_fair+0x78/0xda io_schedule_timeout+0x36/0x4a bit_wait_io+0x0/0x40 bit_wait_io+0x12/0x40 __wait_on_bit+0x46/0x76 wait_on_page_bit_killable+0x64/0x6c bit_wait_io+0x0/0x40 wake_bit_function+0x0/0x4e __lock_page_or_retry+0xde/0x124 do_scan_async+0x114/0x17c lookup_swap_cache+0x24/0x4e handle_mm_fault+0x626/0x7de find_vma+0x0/0x66 down_read+0x0/0xe wait_on_page_bit_killable_timeout+0x77/0x7c find_vma+0x16/0x66 do_page_fault+0xe6/0x23a res_func+0xa3c/0x141a buserr_c+0x190/0x6d4 res_func+0xa3c/0x141a buserr+0x20/0x28 res_func+0xa3c/0x141a buserr+0x20/0x28 The relationship is not obvious but it's due to a failure to rescan the full zonelist after the fair zone allocation policy exhausts the batch count. While this is a functional problem, it's also a performance issue. A page allocator microbenchmark showed the following 4.7.0-rc1 4.7.0-rc1 vanilla reset-v1r2 Min alloc-odr0-1 327.00 ( 0.00%) 326.00 ( 0.31%) Min alloc-odr0-2 235.00 ( 0.00%) 235.00 ( 0.00%) Min alloc-odr0-4 198.00 ( 0.00%) 198.00 ( 0.00%) Min alloc-odr0-8 170.00 ( 0.00%) 170.00 ( 0.00%) Min alloc-odr0-16 156.00 ( 0.00%) 156.00 ( 0.00%) Min alloc-odr0-32 150.00 ( 0.00%) 150.00 ( 0.00%) Min alloc-odr0-64 146.00 ( 0.00%) 146.00 ( 0.00%) Min alloc-odr0-128 145.00 ( 0.00%) 145.00 ( 0.00%) Min alloc-odr0-256 155.00 ( 0.00%) 155.00 ( 0.00%) Min alloc-odr0-512 168.00 ( 0.00%) 165.00 ( 1.79%) Min alloc-odr0-1024 175.00 ( 0.00%) 174.00 ( 0.57%) Min alloc-odr0-2048 180.00 ( 0.00%) 180.00 ( 0.00%) Min alloc-odr0-4096 187.00 ( 0.00%) 186.00 ( 0.53%) Min alloc-odr0-8192 190.00 ( 0.00%) 190.00 ( 0.00%) Min alloc-odr0-16384 191.00 ( 0.00%) 191.00 ( 0.00%) Min alloc-odr1-1 736.00 ( 0.00%) 445.00 ( 39.54%) Min alloc-odr1-2 343.00 ( 0.00%) 335.00 ( 2.33%) Min alloc-odr1-4 277.00 ( 0.00%) 270.00 ( 2.53%) Min alloc-odr1-8 238.00 ( 0.00%) 233.00 ( 2.10%) Min alloc-odr1-16 224.00 ( 0.00%) 218.00 ( 2.68%) Min alloc-odr1-32 210.00 ( 0.00%) 208.00 ( 0.95%) Min alloc-odr1-64 207.00 ( 0.00%) 203.00 ( 1.93%) Min alloc-odr1-128 276.00 ( 0.00%) 202.00 ( 26.81%) Min alloc-odr1-256 206.00 ( 0.00%) 202.00 ( 1.94%) Min alloc-odr1-512 207.00 ( 0.00%) 202.00 ( 2.42%) Min alloc-odr1-1024 208.00 ( 0.00%) 205.00 ( 1.44%) Min alloc-odr1-2048 213.00 ( 0.00%) 212.00 ( 0.47%) Min alloc-odr1-4096 218.00 ( 0.00%) 216.00 ( 0.92%) Min alloc-odr1-8192 341.00 ( 0.00%) 219.00 ( 35.78%) Note that order-0 allocations are unaffected but higher orders get a small boost from this patch and a large reduction in system CPU usage overall as can be seen here: 4.7.0-rc1 4.7.0-rc1 vanilla reset-v1r2 User 85.32 86.31 System 2221.39 2053.36 Elapsed 2368.89 2202.47 Fixes: c33d6c06f60f ("mm, page_alloc: avoid looking up the first zone in a zonelist twice") Link: http://lkml.kernel.org/r/20160531100848.GR2527@techsingularity.net Signed-off-by: Mel Gorman Reported-by: Geert Uytterhoeven Tested-by: Geert Uytterhoeven Tested-by: Mikulas Patocka Cc: Vlastimil Babka Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_alloc.c | 1 + 1 file changed, 1 insertion(+) commit cbdcf7f78900625de35173961b9b95cde22bce45 Author: Michal Hocko Date: Fri Jun 3 14:55:55 2016 -0700 mm, oom_reaper: do not use siglock in try_oom_reaper() Oleg has noted that siglock usage in try_oom_reaper is both pointless and dangerous. signal_group_exit can be checked lockless. The problem is that sighand becomes NULL in __exit_signal so we can crash. Fixes: 3ef22dfff239 ("oom, oom_reaper: try to reap tasks which skip regular OOM killer path") Link: http://lkml.kernel.org/r/1464679423-30218-1-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko Suggested-by: Oleg Nesterov Cc: Tetsuo Handa Cc: David Rientjes Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/oom_kill.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 83b9355bf6f449c7d1231206c300ea89d3313a9d Author: Vlastimil Babka Date: Fri Jun 3 14:55:52 2016 -0700 mm, page_alloc: prevent infinite loop in buffered_rmqueue() In DEBUG_VM kernel, we can hit infinite loop for order == 0 in buffered_rmqueue() when check_new_pcp() returns 1, because the bad page is never removed from the pcp list. Fix this by removing the page before retrying. Also we don't need to check if page is non-NULL, because we simply grab it from the list which was just tested for being non-empty. Fixes: 479f854a207c ("mm, page_alloc: defer debugging checks of pages allocated from the PCP") Link: http://lkml.kernel.org/r/20160530090154.GM2527@techsingularity.net Signed-off-by: Vlastimil Babka Signed-off-by: Mel Gorman Reported-by: Naoya Horiguchi Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds mm/page_alloc.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 879be4f378cb412af3a3fe107d35835c99099add Author: Joe Perches Date: Fri Jun 3 14:55:49 2016 -0700 checkpatch: reduce git commit description style false positives Some lines in a commit log appear to be commit SHA1 ids like: ERROR: Please use git commit description style 'commit <12+ chars of sha1> ("")' - ie: 'commit 0123456789ab ("commit description")' Link: http://lkml.kernel.org/r/40e03fd7aaf1f55c75d787128d6d17c5a71226c2.1464358556.git.vdavydov@virtuozzo.com Reduce the false positives. Link: http://lkml.kernel.org/r/eda977eaa8328fef42bb3c87935d97e10ea8ff67.1464384023.git.joe@perches.com Signed-off-by: Joe Perches <joe@perches.com> Reported-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 1 + 1 file changed, 1 insertion(+) commit 43afc19417ca92cf237095947f597f21d86fd2a7 Author: Vitaly Wool <vitalywool@gmail.com> Date: Fri Jun 3 14:55:47 2016 -0700 mm/z3fold.c: avoid modifying HEADLESS page and minor cleanup Fix erroneous z3fold header access in a HEADLESS page in reclaim function, and change one remaining direct handle-to-buddy conversion to use the appropriate helper. Link: http://lkml.kernel.org/r/5748706F.9020208@gmail.com Signed-off-by: Vitaly Wool <vitalywool@gmail.com> Reviewed-by: Dan Streetman <ddstreet@ieee.org> Cc: Seth Jennings <sjenning@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/z3fold.c | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) commit 3a06bb78ceeceacc86a1e31133a7944013f9775b Author: Tejun Heo <tj@kernel.org> Date: Fri Jun 3 14:55:44 2016 -0700 memcg: add RCU locking around css_for_each_descendant_pre() in memcg_offline_kmem() memcg_offline_kmem() may be called from memcg_free_kmem() after a css init failure. memcg_free_kmem() is a ->css_free callback which is called without cgroup_mutex and memcg_offline_kmem() ends up using css_for_each_descendant_pre() without any locking. Fix it by adding rcu read locking around it. mkdir: cannot create directory `65530': No space left on device =============================== [ INFO: suspicious RCU usage. ] 4.6.0-work+ #321 Not tainted ------------------------------- kernel/cgroup.c:4008 cgroup_mutex or RCU read lock required! [ 527.243970] other info that might help us debug this: [ 527.244715] rcu_scheduler_active = 1, debug_locks = 0 2 locks held by kworker/0:5/1664: #0: ("cgroup_destroy"){.+.+..}, at: [<ffffffff81060ab5>] process_one_work+0x165/0x4a0 #1: ((&css->destroy_work)#3){+.+...}, at: [<ffffffff81060ab5>] process_one_work+0x165/0x4a0 [ 527.248098] stack backtrace: CPU: 0 PID: 1664 Comm: kworker/0:5 Not tainted 4.6.0-work+ #321 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.1-1.fc24 04/01/2014 Workqueue: cgroup_destroy css_free_work_fn Call Trace: dump_stack+0x68/0xa1 lockdep_rcu_suspicious+0xd7/0x110 css_next_descendant_pre+0x7d/0xb0 memcg_offline_kmem.part.44+0x4a/0xc0 mem_cgroup_css_free+0x1ec/0x200 css_free_work_fn+0x49/0x5e0 process_one_work+0x1c5/0x4a0 worker_thread+0x49/0x490 kthread+0xea/0x100 ret_from_fork+0x1f/0x40 Link: http://lkml.kernel.org/r/20160526203018.GG23194@mtj.duckdns.org Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Vladimir Davydov <vdavydov@virtuozzo.com> Acked-by: Johannes Weiner <hannes@cmpxchg.org> Cc: Michal Hocko <mhocko@kernel.org> Cc: <stable@vger.kernel.org> [4.5+] Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memcontrol.c | 3 +++ 1 file changed, 3 insertions(+) commit 2c221325635ed09a6eea10a362d8514d5943ad7d Merge: e603330 dfc2507 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri Jun 3 15:37:27 2016 -0700 Merge branch 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull timer bugfix from Thomas Gleixner: "A single bugfix for the error check wreckage we introduced in the merge window" * 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: time: Make settimeofday error checking work again commit f86e4271978bd93db466d6a95dad4b0fdcdb04f6 Author: Yang Shi <yang.shi@linaro.org> Date: Fri Jun 3 14:55:38 2016 -0700 mm: check the return value of lookup_page_ext for all call sites Per the discussion with Joonsoo Kim [1], we need check the return value of lookup_page_ext() for all call sites since it might return NULL in some cases, although it is unlikely, i.e. memory hotplug. Tested with ltp with "page_owner=0". [1] http://lkml.kernel.org/r/20160519002809.GA10245@js1304-P5Q-DELUXE [akpm@linux-foundation.org: fix build-breaking typos] [arnd@arndb.de: fix build problems from lookup_page_ext] Link: http://lkml.kernel.org/r/6285269.2CksypHdYp@wuerfel [akpm@linux-foundation.org: coding-style fixes] Link: http://lkml.kernel.org/r/1464023768-31025-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/page_idle.h | 43 ++++++++++++++++++++++++++++++++++++------- mm/page_alloc.c | 6 ++++++ mm/page_owner.c | 26 ++++++++++++++++++++++++++ mm/page_poison.c | 8 +++++++- mm/vmstat.c | 2 ++ 5 files changed, 77 insertions(+), 8 deletions(-) commit d8bae33dddc03dc652e1d8cfceebf4f753939de7 Author: Corey Minyard <cminyard@mvista.com> Date: Fri Jun 3 14:55:36 2016 -0700 kdump: fix dmesg gdbmacro to work with record based printk Commit 7ff9554bb578 ("printk: convert byte-buffer to variable-length record buffer") introduced a record based printk buffer. Modify gdbmacros.txt to parse this new structure so dmesg will work properly. Link: http://lkml.kernel.org/r/1463515794-1599-1-git-send-email-minyard@acm.org Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: Dave Young <dyoung@redhat.com> Cc: Baoquan He <bhe@redhat.com> Cc: Vivek Goyal <vgoyal@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/kdump/gdbmacros.txt | 93 ++++++++++++++++++++++++++++++++++----- 1 file changed, 82 insertions(+), 11 deletions(-) commit 65ee03c4b9f89e1b088defd97273be6da169d798 Author: Guillermo Julián Moreno <guillermo.julian@naudit.es> Date: Fri Jun 3 14:55:33 2016 -0700 mm: fix overflow in vm_map_ram() When remapping pages accounting for 4G or more memory space, the operation 'count << PAGE_SHIFT' overflows as it is performed on an integer. Solution: cast before doing the bitshift. [akpm@linux-foundation.org: fix vm_unmap_ram() also] [akpm@linux-foundation.org: fix vmap() as well, per Guillermo] Link: http://lkml.kernel.org/r/etPan.57175fb3.7a271c6b.2bd@naudit.es Signed-off-by: Guillermo Julián Moreno <guillermo.julian@naudit.es> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmalloc.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit e603330c867fea506ea861892bd28d963c07c978 Merge: d29e472 e2dfb4b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri Jun 3 14:39:29 2016 -0700 Merge branch 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm Pull ARM fix from Russell King: "Just one fix to the ptrace code, spotted by Simon Marchi, where if a thread migrates to a different CPU and the VFP registers are changed through ptrace, the application doesn't see the updated VFP registers" * 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm: ARM: fix PTRACE_SETVFPREGS on SMP systems commit d29e4723017b50a3f10395439f19f8d169515c01 Merge: 5306d76 aed7eb8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri Jun 3 14:29:47 2016 -0700 Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 fixes from Will Deacon: "The main thing here is reviving hugetlb support using contiguous ptes, which we ended up reverting at the last minute in 4.5 pending a fix which went into the core mm/ code during the recent merge window. - Revert a previous revert and get hugetlb going with contiguous hints - Wire up missing compat syscalls - Enable CONFIG_SET_MODULE_RONX by default - Add missing line to our compat /proc/cpuinfo output - Clarify levels in our page table dumps - Fix booting with RANDOMIZE_TEXT_OFFSET enabled - Misc fixes to the ARM CPU PMU driver (refcounting, probe failure) - Remove some dead code and update a comment" * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: fix alignment when RANDOMIZE_TEXT_OFFSET is enabled arm64: move {PAGE,CONT}_SHIFT into Kconfig arm64: mm: dump: log span level arm64: update stale PAGE_OFFSET comment drivers/perf: arm_pmu: Avoid leaking pmu->irq_affinity on error drivers/perf: arm_pmu: Defer the setting of __oprofile_cpu_pmu drivers/perf: arm_pmu: Fix reference count of a device_node in of_pmu_irq_cfg arm64: report CPU number in bad_mode arm64: unistd32.h: wire up missing syscalls for compat tasks arm64: Provide "model name" in /proc/cpuinfo for PER_LINUX32 tasks arm64: enable CONFIG_SET_MODULE_RONX by default arm64: Remove orphaned __addr_ok() definition Revert "arm64: hugetlb: partial revert of 66b3923a1a0f" commit 5306d766f15e72bc79c61d88f77e5a6b1fcc0e68 Merge: 4340fa5 7cc8510 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri Jun 3 14:20:22 2016 -0700 Merge tag 'powerpc-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from Michael Ellerman: - Handle RTAS delay requests in configure_bridge from Russell Currey - Refactor the configure_bridge RTAS tokens from Russell Currey - Fix definition of SIAR and SDAR registers from Thomas Huth - Use privileged SPR number for MMCR2 from Thomas Huth - Update LPCR only if it is powernv from Aneesh Kumar K.V - Fix the reference bit update when handling hash fault from Aneesh Kumar K.V - Add missing tlb flush from Aneesh Kumar K.V - Add POWER8NVL support to ibm,client-architecture-support call from Thomas Huth * tag 'powerpc-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call powerpc/mm/radix: Add missing tlb flush powerpc/mm/hash: Fix the reference bit update when handling hash fault powerpc/mm/radix: Update LPCR only if it is powernv powerpc: Use privileged SPR number for MMCR2 powerpc: Fix definition of SIAR and SDAR registers powerpc/pseries/eeh: Refactor the configure_bridge RTAS tokens powerpc/pseries/eeh: Handle RTAS delay requests in configure_bridge commit 60c07f80b04698f6c054b675cb67ec5e7ee8db27 Merge: 7f9bef9 9f9cd7e 8631475 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri Jun 3 22:35:05 2016 +0200 Merge branches 'acpica-fixes', 'acpi-video' and 'acpi-processor' * acpica-fixes: ACPICA / Hardware: Fix old register check in acpi_hw_get_access_bit_width() * acpi-video: ACPI / Thermal / video: fix max_level incorrect value * acpi-processor: ACPI / processor: Avoid reserving IO regions too early commit 8cd8cbd4906126951f1bd6ab8a28ee57f0dc1efc Merge: 1a695a9 b9af694 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri Jun 3 22:34:18 2016 +0200 Merge branch 'pm-cpufreq-fixes' * pm-cpufreq-fixes: cpufreq: Fix clamp_val() usage in cpufreq_driver_fast_switch() cpufreq: intel_pstate: Downgrade print level for _PPC commit 8dff9c85341032767d7b519217a79ea04cd676b0 Author: Chris Mason <clm@fb.com> Date: Sat Sep 19 11:28:25 2015 -0700 Btrfs: deal with duplciates during extent_map insertion in btrfs_get_extent When dealing with inline extents, btrfs_get_extent will incorrectly try to insert a duplicate extent_map. The dup hits -EEXIST from add_extent_map, but then we try to merge with the existing one and end up trying to insert a zero length extent_map. This actually works most of the time, except when there are extent maps past the end of the inline extent. rocksdb will trigger this sometimes because it preallocates an extent and then truncates down. Josef made a script to trigger with xfs_io: #!/bin/bash xfs_io -f -c "pwrite 0 1000" inline xfs_io -c "falloc -k 4k 1M" inline xfs_io -c "pread 0 1000" -c "fadvise -d 0 1000" -c "pread 0 1000" inline xfs_io -c "fadvise -d 0 1000" inline cat inline You'll get EIOs trying to read inline after this because add_extent_map is returning EEXIST Signed-off-by: Chris Mason <clm@fb.com> fs/btrfs/inode.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) commit b223d6242c372a81cca3bb81998f53d3b3e3fb70 Author: Chen-Yu Tsai <wens@csie.org> Date: Wed May 11 13:23:14 2016 +0800 ARM: dts: sun6i: yones-toptech-bs1078-v2: Drop constraints on dc1sw regulator This is the same issue fixed in commit dcf5341f0150 ("ARM: dts: sun8i-q8-common: Do not set constraints on dc1sw regulator"). Commit message copied: dc1sw is an on/off only regulator and as such it cannot have constraints. This is a limitation of the kernel regulator implementation which resolves supplies on the first regulator_get(), which is done after applying constraints, and applying the constrains will fail because it calls _regulator_get_voltage() and _regulator_do_set_voltage() both of which will fail on a switch regulator when there is no supply (yet). This causes registering of all axp22x regulators to fail with the following errors: [ 1.395249] vcc-lcd: failed to get the current voltage(-22) [ 1.405131] axp20x-regulator axp20x-regulator: Failed to register dc1sw [ 1.412436] axp20x-regulator: probe of axp20x-regulator failed with error -22 This commit removes the constrains on dc1sw / vcc-lcd fixing this problem. Note that dcdc1 itself is contrained to the exact same values, so this does not change anything. Cc: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Chen-Yu Tsai <wens@csie.org> Cc: <stable@vger.kernel.org> # 4.6 Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm/boot/dts/sun6i-a31s-yones-toptech-bs1078-v2.dts | 2 -- 1 file changed, 2 deletions(-) commit cb84f6c0a25eb76b1f838eb63e212705c0c06b5f Author: Chen-Yu Tsai <wens@csie.org> Date: Wed May 11 13:23:13 2016 +0800 ARM: dts: sun6i: primo81: Drop constraints on dc1sw regulator This is the same issue fixed in commit dcf5341f0150 ("ARM: dts: sun8i-q8-common: Do not set constraints on dc1sw regulator"). Commit message copied: dc1sw is an on/off only regulator and as such it cannot have constraints. This is a limitation of the kernel regulator implementation which resolves supplies on the first regulator_get(), which is done after applying constraints, and applying the constrains will fail because it calls _regulator_get_voltage() and _regulator_do_set_voltage() both of which will fail on a switch regulator when there is no supply (yet). This causes registering of all axp22x regulators to fail with the following errors: [ 1.395249] vcc-lcd: failed to get the current voltage(-22) [ 1.405131] axp20x-regulator axp20x-regulator: Failed to register dc1sw [ 1.412436] axp20x-regulator: probe of axp20x-regulator failed with error -22 This commit removes the constrains on dc1sw / vcc-lcd fixing this problem. Note that dcdc1 itself is contrained to the exact same values, so this does not change anything. Cc: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Chen-Yu Tsai <wens@csie.org> Cc: <stable@vger.kernel.org> # 4.6 Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm/boot/dts/sun6i-a31s-primo81.dts | 2 -- 1 file changed, 2 deletions(-) commit 80084632e2abf9968f0a582ef044889c686e2954 Merge: c2b8d92 a1f6ad1 Author: Olof Johansson <olof@lixom.net> Date: Fri Jun 3 12:28:10 2016 -0700 Merge tag 'omap-for-v4.7-dts-fixes1' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes DTS fixes for omaps for v4.7 merge window for issues noted with patches in Linux next: - Fix omap5 and am57xx-idk input voltages to fix micro-sd probing at least for some omap5-uevm configurations - Fix unhandled fault for igepv5 audio - Fix UART wakeirqs for omap5 by removing WAKUP_EN flags, those are managed by the wakeirq and can currently confuse the wakeirqs as there is no handler necessarily registered - Fix LDO7 source for igepv5 Also included are few minor changes not strictly fixes are good to have merged: - Fix HP T410 boot time warnings for eMMC and disable the unused MMC interfaces while at it - Add dra7 gpmc dma channel - Add igep00x0 SD card detect and write protect GPIOs * tag 'omap-for-v4.7-dts-fixes1' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: dts: igep0020: Add SD card write-protect pin. ARM: dts: igep00x0: Add SD card-detect. ARM: dts: am57xx-idk-common: Fix input supply names ARM: dts: dra7: Add gpmc dma channel ARM: dts: disable mmc by default and enable when needed for dm814x ARM: dts: Add non-removable to hsmmc on hp-t410 ARM: dts: Fix ldo7 source for HDMI on igepv5 ARM: dts: Fix uart wakeirq on omap5 by removing WAKEUP_EN for omaps ARM: dts: Fix igepv5 audiopwon-gpio ARM: dts: omap5-board-common: Describe the voltage supply mapping accurately Signed-off-by: Olof Johansson <olof@lixom.net> commit c2b8d9200fc61298cd74b258a453b526ffa74d17 Merge: 5fdb884 65db875 Author: Olof Johansson <olof@lixom.net> Date: Fri Jun 3 12:27:08 2016 -0700 Merge tag 'omap-for-v4.7/fixes-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes Two fixes for omaps for v4.7 merge window, one to enable ARM errata for am437x, and the other to add ARM errtum workaround for dra7. AFAIK these both can wait for v4.7, we can then request them for stable kernels as needed. * tag 'omap-for-v4.7/fixes-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP2+: AM43XX: Enable fixes for Cortex-A9 errata ARM: OMAP5 / DRA7: Introduce workaround for 801819 Signed-off-by: Olof Johansson <olof@lixom.net> commit 5fdb884267890b26fdfd5ff5ddaf596745b9ab43 Author: Olliver Schinagl <oliver@schinagl.nl> Date: Fri May 13 21:57:16 2016 +0200 ARM: dts: sunxi: Add OLinuXino Lime2 eMMC to the Makefile commit 27dd9af6bc000ab21fd ("ARM: dts: sunxi: Add a olinuxino-lime2-emmc") added the new emmc equipped lime2 but forgot its Makefile. This patch adds an entry to the Makefile. Signed-off-by: Olliver Schinagl <oliver@schinagl.nl> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm/boot/dts/Makefile | 1 + 1 file changed, 1 insertion(+) commit c3d66602e0bb93c8070a02a901cc80963b5482b9 Merge: 15b7cc7 8a6f71c Author: Olof Johansson <olof@lixom.net> Date: Fri Jun 3 12:15:00 2016 -0700 Merge tag 'samsung-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into fixes Two fixes for v4.7 cycle for build issues: 1. Fix samsung-keypad build error if INPUT is selected as module. The error though depends on some uncommon build settings so it is not as easy to trigger. 2. Get rid of 'samsung_device_dma_mask' defined but not used warning. * tag 'samsung-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: exynos: don't select keyboard driver ARM: samsung: improve static dma_mask definition Signed-off-by: Olof Johansson <olof@lixom.net> commit 15b7cc78f0951e418c940d8b3b6a7a3b962b7748 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Mon May 30 11:12:33 2016 +0900 arm64: dts: drop "arm,amba-bus" in favor of "simple-bus" part 2 Tree-wide replacement was done by commit 2ef7d5f342c1 (ARM, ARM64: dts: drop "arm,amba-bus" in favor of "simple-bus"), but we have some new users of "arm,amba-bus" at Linux 4.7-rc1. Eliminate them now. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Chanho Min <chanho.min@lge.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm64/boot/dts/lg/lg1312.dtsi | 2 +- arch/arm64/boot/dts/rockchip/rk3399.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 665f05e0b836d46b22f0b712eb76d8b7f69a5ea0 Author: Tony Luck <tony.luck@intel.com> Date: Thu Jun 2 10:58:08 2016 -0700 EDAC, sb_edac: Readd accidentally dropped Broadwell-D support In commit 2c1ea4c700af ("EDAC, sb_edac: Use cpu family/model in driver detection") we switched from using PCI ids to determine which platform we are running on to using CPU model instead. I forgot that Broadwell-DE has its own distinct model number different from Broadwell-EP or -EX. Fixing this isn't just adding a line to the array of cpuids - the exising code assumed a 1:1 mapping between entries in that array and the "enum type" values. Added the type to pci_id_table structure to remove this dependency and allows two Broadwell cpu models. Signed-off-by: Tony Luck <tony.luck@intel.com> Cc: Aristeu Rozanski <arozansk@redhat.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Fixes: 2c1ea4c700af ("EDAC, sb_edac: Use cpu family/model in driver detection") Link: http://lkml.kernel.org/r/b3cffe40dec6dfe0235a5d52a504f0ba86a07ce7.1464902605.git.tony.luck@intel.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/sb_edac.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit 62d0e71df063101e4551327bd9fa9aaa3535c86b Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Fri Jun 3 08:54:18 2016 +0800 clk: rockchip: release io resource when failing to init clk on rk3399 We should call iounmap to relase reg_base since it's not going to be used any more if failing to init clk. This was missing on the newly added rk3399 clock tree. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 2 ++ 1 file changed, 2 insertions(+) commit 2eec3707a33fbf1c2e0a88ffc9fc0e465c2a59fd Merge: 59fa586 0de6b99 Author: Thomas Gleixner <tglx@linutronix.de> Date: Fri Jun 3 15:05:51 2016 +0200 Merge tag 'irqchip-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms into irq/urgent Merge irqchip updates from Marc Zyngier: - A number of embarassing buglets (GICv3, PIC32) - A more substential errata workaround for Cavium's GICv3 ITS (kept for post-rc1 due to its dependency on NUMA) commit f83803305b008ca3d75b00092b6493bc19eda60b Author: Joshua Clayton <stillcompiling@gmail.com> Date: Wed Jun 1 08:55:00 2016 -0700 of: add vendor prefix for UniWest United Western Technologies Corp, known primarily as UniWest, is a manufacturer of eddy current and ultrasonic testing equipment. Signed-off-by: Joshua Clayton <stillcompiling@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 53e1941ce8a25543eef2016b8de69d155f5151a5 Author: Wei-Ning Huang <wnhuang@chromium.org> Date: Wed Jun 1 11:09:24 2016 +0800 dt: bindings: fix documentation for MARVELL's bt-sd8xxx wireless device The property marvell,wakeup-pin and marvell,wakeup-gap-ms are read as u16 in the driver. Fix documentation and example accordingly. Signed-off-by: Wei-Ning Huang <wnhuang@chromium.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/net/marvell-bt-sd8xxx.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e93aeeae0bf8cba43e05484ae4ad17213ac6c3a7 Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Wed May 25 01:15:04 2016 +0000 of: add missing const for of_parse_phandle_with_args() in !CONFIG_OF commit 93c667ca2598bd84f1bd3f2fa176af69707699fe ("of: *node argument to of_parse_phandle_with_args should be const") changed to const for struct device node *np, but it cares CONFIG_OF case only, !CONFIG_OF case need it too. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Rob Herring <robh@kernel.org> include/linux/of.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aaaab56dba9af4fe75461e0ee13231c1a6ea174d Author: Stephen Rothwell <sfr@canb.auug.org.au> Date: Tue May 31 09:38:56 2016 +1000 of: silence warnings due to max() usage pageblock_order can be (at least) an unsigned int or an unsigned long depending on the kernel config and architecture, so use max_t(unsigned long ...) when comparing it. fixes these warnings: In file included from include/linux/list.h:8:0, from include/linux/kobject.h:20, from include/linux/of.h:21, from drivers/of/of_reserved_mem.c:17: drivers/of/of_reserved_mem.c: In function ‘__reserved_mem_alloc_size’: include/linux/kernel.h:748:17: warning: comparison of distinct pointer types lacks a cast (void) (&_max1 == &_max2); \ ^ include/linux/kernel.h:747:9: note: in definition of macro ‘max’ typeof(y) _max2 = (y); \ ^ drivers/of/of_reserved_mem.c:131:48: note: in expansion of macro ‘max’ align = max(align, (phys_addr_t)PAGE_SIZE << max(MAX_ORDER - 1, pageblock_ord ^ include/linux/kernel.h:748:17: warning: comparison of distinct pointer types lacks a cast (void) (&_max1 == &_max2); \ ^ include/linux/kernel.h:747:21: note: in definition of macro ‘max’ typeof(y) _max2 = (y); \ ^ drivers/of/of_reserved_mem.c:131:48: note: in expansion of macro ‘max’ align = max(align, (phys_addr_t)PAGE_SIZE << max(MAX_ORDER - 1, pageblock_ord ^ Fixes: 1cc8e3458b51 ("drivers: of: of_reserved_mem: fixup the alignment with CMA setup") Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/of_reserved_mem.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 94bef000f1d4aa111f4ddda1482cf3b30ad069ce Author: Matt Ranostay <mranostay@gmail.com> Date: Sun May 29 19:52:02 2016 -0700 iio: hudmidity: hdc100x: fix incorrect shifting and scaling Shifting sensor data to the right 2 bits was incorrect and caused the scaling values + offsets to be invalid. Reported-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Matt Ranostay <mranostay@gmail.com> Tested-by: Alison Schofield <amsfield22@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/hdc100x.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 7d482813bb3518cbfeae1b987a5afd76a88c7eb3 Author: Jaewon <jaewon31.kim@samsung.com> Date: Wed May 25 13:29:50 2016 +0900 drivers: of: of_reserved_mem: fixup the CMA alignment not to affect dma-coherent There was an alignment mismatch issue for CMA and it was fixed by commit 1cc8e3458b51 ("drivers: of: of_reserved_mem: fixup the alignment with CMA setup"). However the way of the commit considers not only dma-contiguous(CMA) but also dma-coherent which has no that requirement. This patch checks more to distinguish dma-contiguous(CMA) from dma-coherent. Signed-off-by: Jaewon Kim <jaewon31.kim@samsung.com> Acked-by: Jason Liu <r64343@freescale.com> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com> [robh: remove erroneous opening bracket] Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/of_reserved_mem.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 3993546646baf1dab5f5c4f7d9bb58f2046fd1c1 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sat May 28 23:02:50 2016 +0300 of: irq: fix of_irq_get[_byname]() kernel-doc The kernel-doc for the of_irq_get[_byname]() is clearly inadequate in describing the return values -- of_irq_get_byname() is documented better than of_irq_get() but it still doesn't mention that 0 is returned iff irq_create_of_mapping() fails (it doesn't return an error code in this case). Document all possible return value variants, making the writing of the word "IRQ" consistent, while at it... Fixes: 9ec36cafe43b ("of/irq: do irq resolution in platform_get_irq") Fixes: ad69674e73a1 ("of/irq: do irq resolution in platform_get_irq_byname()") Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> CC: stable@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/irq.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit 590b92a30242dd3f73de3d9a51d9924f1ab33e93 Author: Yong Li <sdliyong@gmail.com> Date: Thu May 5 16:10:49 2016 +0800 iio: light apds9960: Add the missing dev.parent Without this, the iio:deviceX is missing in the /sys/bus/i2c/devices/0-0039 Some userspace tools use this path to identify a specific instance of the device. Signed-off-by: Yong Li <sdliyong@gmail.com> Reviewed-By: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/apds9960.c | 1 + 1 file changed, 1 insertion(+) commit 99543823357966ac938d9a310947e731b67338e6 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Tue May 3 15:27:09 2016 +0300 iio: Fix error handling in iio_trigger_attach_poll_func When attaching a pollfunc iio_trigger_attach_poll_func will allocate a virtual irq and call the driver's set_trigger_state function. Fix error handling to undo previous steps if any fails. In particular this fixes handling errors from a driver's set_trigger_state function. When using triggered buffers a failure to enable the trigger used to make the buffer unusable. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/industrialio-trigger.c | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) commit aed7eb8367939244ba19445292ffdfc398e0d66a Author: Mark Rutland <mark.rutland@arm.com> Date: Tue May 31 15:58:00 2016 +0100 arm64: fix alignment when RANDOMIZE_TEXT_OFFSET is enabled With ARM64_64K_PAGES and RANDOMIZE_TEXT_OFFSET enabled, we hit the following issue on the boot: kernel BUG at arch/arm64/mm/mmu.c:480! Internal error: Oops - BUG: 0 [#1] PREEMPT SMP Modules linked in: CPU: 0 PID: 0 Comm: swapper Not tainted 4.6.0 #310 Hardware name: ARM Juno development board (r2) (DT) task: ffff000008d58a80 ti: ffff000008d30000 task.ti: ffff000008d30000 PC is at map_kernel_segment+0x44/0xb0 LR is at paging_init+0x84/0x5b0 pc : [<ffff000008c450b4>] lr : [<ffff000008c451a4>] pstate: 600002c5 Call trace: [<ffff000008c450b4>] map_kernel_segment+0x44/0xb0 [<ffff000008c451a4>] paging_init+0x84/0x5b0 [<ffff000008c42728>] setup_arch+0x198/0x534 [<ffff000008c40848>] start_kernel+0x70/0x388 [<ffff000008c401bc>] __primary_switched+0x30/0x74 Commit 7eb90f2ff7e3 ("arm64: cover the .head.text section in the .text segment mapping") removed the alignment between the .head.text and .text sections, and used the _text rather than the _stext interval for mapping the .text segment. Prior to this commit _stext was always section aligned and didn't cause any issue even when RANDOMIZE_TEXT_OFFSET was enabled. Since that alignment has been removed and _text is used to map the .text segment, we need ensure _text is always page aligned when RANDOMIZE_TEXT_OFFSET is enabled. This patch adds logic to TEXT_OFFSET fuzzing to ensure that the offset is always aligned to the kernel page size. To ensure this, we rely on the PAGE_SHIFT being available via Kconfig. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Reported-by: Sudeep Holla <sudeep.holla@arm.com> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will.deacon@arm.com> Fixes: 7eb90f2ff7e3 ("arm64: cover the .head.text section in the .text segment mapping") Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 030c4d24447cbf2bd612baea5695952e5f62c042 Author: Mark Rutland <mark.rutland@arm.com> Date: Tue May 31 15:57:59 2016 +0100 arm64: move {PAGE,CONT}_SHIFT into Kconfig In some cases (e.g. the awk for CONFIG_RANDOMIZE_TEXT_OFFSET) we would like to make use of PAGE_SHIFT outside of code that can include the usual header files. Add a new CONFIG_ARM64_PAGE_SHIFT for this, likewise with ARM64_CONT_SHIFT for consistency. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Sudeep Holla <sudeep.holla@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 12 ++++++++++++ arch/arm64/include/asm/page.h | 12 ++---------- 2 files changed, 14 insertions(+), 10 deletions(-) commit 48dd73c55d45d60037ea8d73eab60f2033d90721 Author: Mark Rutland <mark.rutland@arm.com> Date: Tue May 31 14:49:02 2016 +0100 arm64: mm: dump: log span level The page table dump code logs spans of entries at the same level (pgd/pud/pmd/pte) which have the same attributes. While we log the (decoded) attributes, we don't log the level, which leaves the output ambiguous and/or confusing in some cases. For example: 0xffff800800000000-0xffff800980000000 6G RW NX SHD AF BLK UXN MEM/NORMAL If using 4K pages, this may describe a span of 6 1G block entries at the PGD/PUD level, or 3072 2M block entries at the PMD level. This patch adds the page table level to each output line, removing this ambiguity. For the example above, this will produce: 0xffffffc800000000-0xffffffc980000000 6G PUD RW NX SHD AF BLK UXN MEM/NORMAL When 3 level tables are in use, and we use the asm-generic/nopud.h definitions, the dump code treats each entry in the PGD as a 1 element table at the PUD level, and logs spans as being PUDs, which can be confusing. To counteract this, the "PUD" mnemonic is replaced with "PGD" when CONFIG_PGTABLE_LEVELS <= 3. Likewise for "PMD" when CONFIG_PGTABLE_LEVELS <= 2. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Huang Shijie <shijie.huang@arm.com> Cc: Laura Abbott <labbott@fedoraproject.org> Cc: Steve Capper <steve.capper@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/dump.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit a13e3a5b54e59ffdeba738ea6cb57a7856425206 Author: Mark Rutland <mark.rutland@arm.com> Date: Wed Jun 1 12:07:17 2016 +0100 arm64: update stale PAGE_OFFSET comment Commit ab893fb9f1b17f02 ("arm64: introduce KIMAGE_VADDR as the virtual base of the kernel region") logically split KIMAGE_VADDR from PAGE_OFFSET, and since commit f9040773b7bbbd9e ("arm64: move kernel image to base of vmalloc area") the two have been distinct values. Unfortunately, neither commit updated the comment above these definitions, which now erroneously states that PAGE_OFFSET is the start of the kernel image rather than the start of the linear mapping. This patch fixes said comment, and introduces an explanation of KIMAGE_VADDR. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/memory.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5988a363edb9eb9f31486ceb2cd10e8b45f05dda Author: Julien Grall <julien.grall@arm.com> Date: Tue May 31 12:41:23 2016 +0100 drivers/perf: arm_pmu: Avoid leaking pmu->irq_affinity on error pmu->irq_affinity will not be freed if an error occurred within arm_pmu_device_probe after of_pmu_irq_cfg has been called. Note that in the case of_pmu_irq_cfg is returning an error, pmu->irq_affinity will not be set, but it should be NULL as pmu was kzalloc'd. Therefore the result kfree(NULL) is benign. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/perf/arm_pmu.c | 1 + 1 file changed, 1 insertion(+) commit 0f254c7671e851243412bce6c2e618732831d0f8 Author: Julien Grall <julien.grall@arm.com> Date: Tue May 31 12:41:22 2016 +0100 drivers/perf: arm_pmu: Defer the setting of __oprofile_cpu_pmu The global variable __oprofile_cpu_pmu is set before the PMU is fully initialized. If an error occurs before the end of the initialization, the PMU will be freed and the variable will contain an invalid pointer. This will result in a kernel crash when perf will be used. Fix it by moving the setting of __oprofile_cpu_pmu when the PMU is fully initialized (i.e when it is no longer possible to fail). Cc: <stable@vger.kernel.org> Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/perf/arm_pmu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 121323ae668e456d0ed328f5b77c22bf5dd8e4de Author: Julien Grall <julien.grall@arm.com> Date: Tue May 31 12:41:21 2016 +0100 drivers/perf: arm_pmu: Fix reference count of a device_node in of_pmu_irq_cfg The only function called by of_pmu_irq_cfg that will increment the reference count on dn is of_parse_phandle. Each time we successfully parse a possible CPU from an interrupt-affinity property, we increment the refcount of that CPU node once via of_parse_handle. After validating the CPU is possible, we decrement the refcount once. Subsequently, we decrement the refcount again, either as part of an early break if we don't have a matching SPI, or as part of the end of the loop body. This will lead to decrementing twice the refcounnt. Remove the second pairs of call to of_node_put as nobody is using dn between the first and second call to of_node_put. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/perf/arm_pmu.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 8051f4d16ef1d037e7b12abab79c3e0b960f4d36 Author: Mark Rutland <mark.rutland@arm.com> Date: Tue May 31 12:07:47 2016 +0100 arm64: report CPU number in bad_mode If we take an exception we don't expect (e.g. SError), we report this in the bad_mode handler with pr_crit. Depending on the configured log level, we may or may not log additional information in functions called subsequently. Notably, the messages in dump_stack (including the CPU number) are printed with KERN_DEFAULT and may not appear. Some exceptions have an IMPLEMENTATION DEFINED ESR_ELx.ISS encoding, and knowing the CPU number is crucial to correctly decode them. To ensure that this is always possible, we should log the CPU number along with the ESR_ELx value, so we are not reliant on subsequent logs or additional printk configuration options. This patch logs the CPU number in bad_mode such that it is possible for a developer to decode these exceptions, provided access to sufficient documentation. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Reported-by: Al Grant <Al.Grant@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Dave Martin <dave.martin@arm.com> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/traps.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit fbedcaf43fba35677c01a4ae51e6f79edf4049ba Author: Nicholas Krause <xerofoify@gmail.com> Date: Thu May 19 18:45:58 2016 -0400 EDAC: Fix workqueues poll period resetting After the workqueue cleanup, we're registering workqueues based on the presence of an ->edac_check function. When that is the case, we're setting OP_RUNNING_POLL. But we forgot to check that in edac_mc_reset_delay_period(), leading to: BUG: unable to handle kernel paging request at 0000000000015d10 IP: [ .. ] queued_spin_lock_slowpath PGD 3ffcc8067 PUD 3ffc56067 PMD 0 Oops: 0002 [#1] SMP Modules linked in: ... CPU: 1 PID: 2792 Comm: edactest Not tainted 4.6.0-dirty #1 Hardware name: HP ProLiant MicroServer, BIOS O41 10/01/2013 Stack: Call Trace: ? _raw_spin_lock_irqsave ? lock_timer_base.isra.34 ? del_timer ? try_to_grab_pending ? mod_delayed_work_on ? edac_mc_reset_delay_period ? edac_set_poll_msec ? param_attr_store ? module_attr_store ? kernfs_fop_write ? __vfs_write ? __vfs_read ? __alloc_fd ? vfs_write ? SyS_write ? entry_SYSCALL_64_fastpath Code: RIP [ .. ] queued_spin_lock_slowpath RSP <> CR2: 0000000000015d10 ---[ end trace 3f286bc71cca15d1 ]--- Kernel panic - not syncing: Fatal exception Fix it. Signed-off-by: Nicholas Krause <xerofoify@gmail.com> Cc: <stable@vger.kernel.org> # 4.5 Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1463697958-13406-1-git-send-email-xerofoify@gmail.com [ Rewrite commit message. ] Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/edac_mc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 31143e2933d1675c4c1ba6ce125cdd95870edd85 Author: Franky Lin <franky.lin@broadcom.com> Date: Thu Jun 2 02:00:27 2016 -0700 brcmfmac: add eth_type_trans back for PCIe full dongle A regression was introduced in commit 9c349892ccc9 ("brcmfmac: revise handling events in receive path") which moves eth_type_trans() call to brcmf_rx_frame(). Msgbuf layer doesn't use brcmf_rx_frame() but invokes brcmf_netif_rx() directly. In such case the Ethernet header was not stripped out resulting in null pointer dereference in the networking stack. BUG: unable to handle kernel NULL pointer dereference at 0000000000000048 IP: [<ffffffff814c3ce6>] enqueue_to_backlog+0x56/0x260 PGD 0 Oops: 0000 [#1] PREEMPT SMP Modules linked in: fuse ipt_MASQUERADE nf_nat_masquerade_ipv4 iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 xt_addrtype [...] rtsx_pci scsi_mod usbcore usb_common i8042 serio nvme nvme_core CPU: 7 PID: 1340 Comm: irq/136-brcmf_p Not tainted 4.7.0-rc1-mainline #1 Hardware name: Dell Inc. XPS 15 9550/0N7TVV, BIOS 01.02.00 04/07/2016 task: ffff8804a0c5bd00 ti: ffff88049e124000 task.ti: ffff88049e124000 RIP: 0010:[<ffffffff814c3ce6>] [<ffffffff814c3ce6>] enqueue_to_backlog+0x56/0x260 RSP: 0018:ffff88049e127ca0 EFLAGS: 00010046 RAX: 0000000000000000 RBX: ffff8804bddd7c40 RCX: 000000000000002f RDX: 0000000000000000 RSI: 0000000000000007 RDI: ffff8804bddd7d4c RBP: ffff88049e127ce8 R08: 0000000000000000 R09: 0000000000000000 R10: ffff8804bddd12c0 R11: 000000000000149e R12: 0000000000017c40 R13: ffff88049e127d08 R14: ffff8804a9bd6d00 R15: ffff8804bddd7d4c FS: 0000000000000000(0000) GS:ffff8804bddc0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000048 CR3: 0000000001806000 CR4: 00000000003406e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Stack: ffff8804bdddad00 ffff8804ad089e00 0000000000000000 0000000000000282 0000000000000000 ffff8804a9bd6d00 ffff8804a1b27e00 ffff8804a9bd6d00 ffff88002ee88000 ffff88049e127d28 ffffffff814c3f3b ffffffff81311fc3 Call Trace: [<ffffffff814c3f3b>] netif_rx_internal+0x4b/0x170 [<ffffffff81311fc3>] ? swiotlb_tbl_unmap_single+0xf3/0x120 [<ffffffff814c5467>] netif_rx_ni+0x27/0xc0 [<ffffffffa08519e9>] brcmf_netif_rx+0x49/0x70 [brcmfmac] [<ffffffffa08564d4>] brcmf_msgbuf_process_rx+0x2b4/0x570 [brcmfmac] [<ffffffff81020017>] ? __xen_set_pgd_hyper+0x57/0xd0 [<ffffffff810d60b0>] ? irq_forced_thread_fn+0x70/0x70 [<ffffffffa0857381>] brcmf_proto_msgbuf_rx_trigger+0x31/0xe0 [brcmfmac] [<ffffffffa0861e8f>] brcmf_pcie_isr_thread+0x7f/0x110 [brcmfmac] [<ffffffff810d60d0>] irq_thread_fn+0x20/0x50 [<ffffffff810d63ad>] irq_thread+0x12d/0x1c0 [<ffffffff815d07d5>] ? __schedule+0x2f5/0x7a0 [<ffffffff810d61d0>] ? wake_threads_waitq+0x30/0x30 [<ffffffff810d6280>] ? irq_thread_dtor+0xb0/0xb0 [<ffffffff81098ea8>] kthread+0xd8/0xf0 [<ffffffff815d4b7f>] ret_from_fork+0x1f/0x40 [<ffffffff81098dd0>] ? kthread_worker_fn+0x170/0x170 Code: 1c f5 60 9a 8e 81 9c 58 0f 1f 44 00 00 48 89 45 d0 fa 66 0f 1f 44 00 00 4c 8d bb 0c 01 00 00 4c 89 ff e8 5e 08 11 00 49 8b 56 20 <48> 8b 52 48 83 e2 01 74 10 8b 8b 08 01 00 00 8b 15 59 c5 42 00 RIP [<ffffffff814c3ce6>] enqueue_to_backlog+0x56/0x260 RSP <ffff88049e127ca0> CR2: 0000000000000048 Fixes: 9c349892ccc9 ("brcmfmac: revise handling events in receive path") Reported-by: Rafal Milecki <zajec5@gmail.com> Reported-by: Grey Christoforo <grey@christoforo.net> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by: Arend Van Spriel <arend@broadcom.com> Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Signed-off-by: Franky Lin <franky.lin@broadcom.com> [arend@broadcom.com: rephrased the commit message] Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 2 ++ 1 file changed, 2 insertions(+) commit c7103f650a11328f28b9fa1c95027db331b7774b Author: Tony Luck <tony.luck@intel.com> Date: Tue May 31 11:50:28 2016 -0700 EDAC, sb_edac: Fix rank lookup on Broadwell Broadwell made a small change to the rank target register moving the target rank ID field up from bits 16:19 to bits 20:23. Also found that the offset field grew by one bit in the IVY_BRIDGE to HASWELL transition, so fix the RIR_OFFSET() macro too. Signed-off-by: Tony Luck <tony.luck@intel.com> Cc: stable@vger.kernel.org # v3.19+ Cc: Aristeu Rozanski <arozansk@redhat.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/2943fb819b1f7e396681165db9c12bb3df0e0b16.1464735623.git.tony.luck@intel.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/sb_edac.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit c75343972b79ef5bd44c498a63b326e37470bbfc Author: Dennis Chen <dennis.chen@arm.com> Date: Tue May 31 11:23:44 2016 +0100 efi/arm: Fix the format of EFI debug messages When both EFI and memblock debugging is enabled on the kernel command line: 'efi=debug memblock=debug' .. the debug messages for early_con look the following way: [ 0.000000] efi: 0x0000e1050000-0x0000e105ffff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x0000e1300000-0x0000e1300fff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x0000e8200000-0x0000e827ffff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x008000000000-0x008001e7ffff [Runtime Data |RUN| | | | | | | |WB|WT|WC|UC] [ 0.000000] memblock_add: [0x00008000000000-0x00008001e7ffff] flags 0x0 early_init_dt_add_memory_arch+0x54/0x5c [ 0.000000] * ... Note the misplaced '*' line, which happened because the memblock debug message was printed while the EFI debug message was still being constructed.. This patch fixes the output to be the expected: [ 0.000000] efi: 0x0000e1050000-0x0000e105ffff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x0000e1300000-0x0000e1300fff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x0000e8200000-0x0000e827ffff [Memory Mapped I/O |RUN| | | | | | | | | | |UC] [ 0.000000] efi: 0x008000000000-0x008001e7ffff [Runtime Data |RUN| | | | | | | |WB|WT|WC|UC]* [ 0.000000] memblock_add: [0x00008000000000-0x00008001e7ffff] flags 0x0 early_init_dt_add_memory_arch+0x54/0x5c ... Note how the '*' is now in the proper EFI debug message line. Signed-off-by: Dennis Chen <dennis.chen@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Mark Rutland <mark.rutland@arm.com> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mark Salter <msalter@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steve Capper <steve.capper@arm.com> Cc: Steve McIntyre <steve@einval.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1464690224-4503-3-git-send-email-matt@codeblueprint.co.uk [ Made the changelog more readable. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/arm-init.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit 55f1ea15216a5a14c96738bd5284100a00ffa9dc Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Tue May 31 11:23:43 2016 +0100 efi: Fix for_each_efi_memory_desc_in_map() for empty memmaps Commit: 78ce248faa3c ("efi: Iterate over efi.memmap in for_each_efi_memory_desc()") introduced a regression for systems booted with the 'noefi' kernel option. In particular, I observed an early kernel hang in efi_find_mirror()'s for_each_efi_memory_desc() call. As we don't have efi memmap on this system we enter this iterator with the following parameters: efi.memmap.map = 0, efi.memmap.map_end = 0, efi.memmap.desc_size = 28 ... then for_each_efi_memory_desc_in_map() does the following comparison: (md) <= (efi_memory_desc_t *)((m)->map_end - (m)->desc_size); ... where md = 0, (m)->map_end = 0 and (m)->desc_size = 28 but when we subtract something from a NULL pointer wrap around happens and we end up returning invalid pointer and crash. Fix it by using the correct pointer arithmetics. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: K. Y. Srinivasan <kys@microsoft.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mark Salter <msalter@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Fixes: 78ce248faa3c ("efi: Iterate over efi.memmap in for_each_efi_memory_desc()") Link: http://lkml.kernel.org/r/1464690224-4503-2-git-send-email-matt@codeblueprint.co.uk [ Made the changelog more readable. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/efi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f90d83b301701026b2e4c437a3613f377f63290e Author: AceLan Kao <acelan.kao@canonical.com> Date: Fri Jun 3 14:45:25 2016 +0800 ALSA: hda - Fix headset mic detection problem for Dell machine Add the pin configuration value of this machine into the pin_quirk table to make DELL1_MIC_NO_PRESENCE apply to this machine. Signed-off-by: AceLan Kao <acelan.kao@canonical.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 4 ++++ 1 file changed, 4 insertions(+) commit 3b94a891667c30fb4624221497d77fc65d950345 Author: Kan Liang <kan.liang@intel.com> Date: Fri May 27 04:12:20 2016 -0700 perf/x86/intel/uncore: Remove SBOX support for Broadwell server There was a report that on certain Broadwell-EP systems writing any bit of the SBOX PMU initialization MSR would #GP at boot. This did not happen on all systems. My test systems booted fine. Considering both DE and EP may have such issues, this patch removes SBOX support for all Broadwell platforms for now. Reported-and-tested-by: Mark van Dijk <mark@voidzero.net> Signed-off-by: Kan Liang <kan.liang@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1464347540-5763-1-git-send-email-kan.liang@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/uncore_snbep.c | 21 --------------------- 1 file changed, 21 deletions(-) commit 0422e83d84ae24b933e4b0d4c1e0f0b4ae8a0a3b Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu May 26 21:08:17 2016 +0100 locking/ww_mutex: Report recursive ww_mutex locking early Recursive locking for ww_mutexes was originally conceived as an exception. However, it is heavily used by the DRM atomic modesetting code. Currently, the recursive deadlock is checked after we have queued up for a busy-spin and as we never release the lock, we spin until kicked, whereupon the deadlock is discovered and reported. A simple solution for the now common problem is to move the recursive deadlock discovery to the first action when taking the ww_mutex. Suggested-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/1464293297-19777-1-git-send-email-chris@chris-wilson.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/mutex.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 55eed755c6e30a89be3a791a6b0ad208aadd9bdc Author: Peter Zijlstra <peterz@infradead.org> Date: Fri May 27 13:11:17 2016 +0200 locking/seqcount: Re-fix raw_read_seqcount_latch() Commit 50755bc1c305 ("seqlock: fix raw_read_seqcount_latch()") broke raw_read_seqcount_latch(). If you look at the comment that was modified; the thing that changes is the seq count, not the latch pointer. * void latch_modify(struct latch_struct *latch, ...) * { * smp_wmb(); <- Ensure that the last data[1] update is visible * latch->seq++; * smp_wmb(); <- Ensure that the seqcount update is visible * * modify(latch->data[0], ...); * * smp_wmb(); <- Ensure that the data[0] update is visible * latch->seq++; * smp_wmb(); <- Ensure that the seqcount update is visible * * modify(latch->data[1], ...); * } * * The query will have a form like: * * struct entry *latch_query(struct latch_struct *latch, ...) * { * struct entry *entry; * unsigned seq, idx; * * do { * seq = lockless_dereference(latch->seq); So here we have: seq = READ_ONCE(latch->seq); smp_read_barrier_depends(); Which is exactly what we want; the new code: seq = ({ p = READ_ONCE(latch); smp_read_barrier_depends(); p })->seq; is just wrong; because it looses the volatile read on seq, which can now be torn or worse 'optimized'. And the read_depend barrier is also placed wrong, we want it after the load of seq, to match the above data[] up-to-date wmb()s. Such that when we dereference latch->data[] below, we're guaranteed to observe the right data. * * idx = seq & 0x01; * entry = data_query(latch->data[idx], ...); * * smp_rmb(); * } while (seq != latch->seq); * * return entry; * } So yes, not passing a pointer is not pretty, but the code was correct, and isn't anymore now. Change to explicit READ_ONCE()+smp_read_barrier_depends() to avoid confusion and allow strict lockless_dereference() checking. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexey Dobriyan <adobriyan@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Paul McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: 50755bc1c305 ("seqlock: fix raw_read_seqcount_latch()") Link: http://lkml.kernel.org/r/20160527111117.GL3192@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/seqlock.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 31b2a32f708bb33b3f35b03ce3d2cb31f7d1e684 Author: Roger Quadros <rogerq@ti.com> Date: Wed May 18 15:28:06 2016 +0300 phy: ti-pipe3: Program the DPLL even if it was already locked If bootloader has set a wrong DPLL then we must trash those values and re-program it anyways. This fixes USB3 devices not being enumerated on beagle-x15 if usb was started in u-boot. We don't re-program SATA DPLL if it is locked as it was causing SATA failures if device was hotpluged after boot. Reported-by: Robert Nelson <robertcnelson@gmail.com> Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-ti-pipe3.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit 4693fc734d675c5518ea9bd4c9623db45bc37402 Author: Stephan Mueller <smueller@chronox.de> Date: Thu May 26 23:38:12 2016 +0200 KEYS: Add placeholder for KDF usage with DH The values computed during Diffie-Hellman key exchange are often used in combination with key derivation functions to create cryptographic keys. Add a placeholder for a later implementation to configure a key derivation function that will transform the Diffie-Hellman result returned by the KEYCTL_DH_COMPUTE command. [This patch was stripped down from a patch produced by Mat Martineau that had a bug in the compat code - so for the moment Stephan's patch simply requires that the placeholder argument must be NULL] Original-signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: Stephan Mueller <smueller@chronox.de> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: James Morris <james.l.morris@oracle.com> Documentation/security/keys.txt | 5 ++++- security/keys/compat.c | 2 +- security/keys/dh.c | 8 +++++++- security/keys/internal.h | 5 +++-- security/keys/keyctl.c | 4 ++-- 5 files changed, 17 insertions(+), 7 deletions(-) commit 0fbbbf8b599ff840ff1a3c0cc00dd67ba8a52c9c Author: Oded Gabbay <oded.gabbay@gmail.com> Date: Sun May 29 08:21:53 2016 +0300 drm/amdkfd: print once about mem_banks truncation This print can really spam the kernel log in case we are truncating mem_banks, so just print this info once. It should also not be classified as warning. Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc4755a4bd1845ef6e88ac8c62f12e05bb530256 Author: Oded Gabbay <oded.gabbay@gmail.com> Date: Thu May 26 08:41:48 2016 +0300 drm/amdkfd: destroy dbgmgr in notifier release amdkfd need to destroy the debug manager in case amdkfd's notifier function is called before the unbind function, because in that case, the unbind function will exit without destroying debug manager. Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> CC: Stable <stable@vger.kernel.org> drivers/gpu/drm/amd/amdkfd/kfd_process.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 121b78e679ee3ffab780115e260b2775d0cc1f73 Author: Oded Gabbay <oded.gabbay@gmail.com> Date: Thu May 26 08:41:08 2016 +0300 drm/amdkfd: unbind only existing processes When unbinding a process from a device (initiated by amd_iommu_v2), the driver needs to make sure that process still exists in the process table. There is a possibility that amdkfd's own notifier handler - kfd_process_notifier_release() - was called before the unbind function and it already removed the process from the process table. v2: Because there can be only one process with the specified pasid, and because *p can't be NULL inside the hash_for_each_rcu macro, it is more reasonable to just put the whole code inside the if statement that compares the pasid value. That way, when we exit hash_for_each_rcu, we simply exit the function as well. Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> CC: Stable <stable@vger.kernel.org> drivers/gpu/drm/amd/amdkfd/kfd_process.c | 60 +++++++++++++++++++------------- 1 file changed, 35 insertions(+), 25 deletions(-) commit ab3ab68493aaac6fea4ad1bb597def9f48f41c71 Author: Dave Airlie <airlied@redhat.com> Date: Fri Jun 3 14:39:41 2016 +1000 drm/omap: fix unused variable warning. Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/omapdrm/dss/hdmi4.c | 1 - 1 file changed, 1 deletion(-) commit f1777aaf8468c674e2ef962fca6ef0e716755e00 Merge: b160245 d0196c8 Author: Dave Airlie <airlied@redhat.com> Date: Fri Jun 3 14:35:00 2016 +1000 Merge tag 'omapdrm-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux into drm-fixes omapdrm fixes for 4.7 * multiple compile break fixes for missing includes, bad kconfig dependencies. * remove regulator API misuse causing deprecation warnings * OMAP5 HDMI fixes for DDC and AVI infoframe * OMAP4 HDMI fix for CEC * tag 'omapdrm-4.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux: drm/omap: include gpio/consumer.h where needed drm/omap: include linux/seq_file.h where needed Revert "drm/omap: no need to select OMAP2_DSS" drm/omap: Remove regulator API abuse OMAPDSS: HDMI5: Change DDC timings OMAPDSS: HDMI5: Fix AVI infoframe drm/omap: fix OMAP4 hdmi_core_powerdown_disable() drm/omap: Fix missing includes drm/omapdrm: include pinctrl/consumer.h where needed commit 4116def2337991b39919f3b448326e21c40e0dbb Author: Kangjie Lu <kangjielu@gmail.com> Date: Thu Jun 2 04:11:20 2016 -0400 rds: fix an infoleak in rds_inc_info_copy The last field "flags" of object "minfo" is not initialized. Copying this object out may leak kernel stack data. Assign 0 to it to avoid leak. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rds/recv.c | 2 ++ 1 file changed, 2 insertions(+) commit 5d2be1422e02ccd697ccfcd45c85b4a26e6178e2 Author: Kangjie Lu <kangjielu@gmail.com> Date: Thu Jun 2 04:04:56 2016 -0400 tipc: fix an infoleak in tipc_nl_compat_link_dump link_info.str is a char array of size 60. Memory after the NULL byte is not initialized. Sending the whole object out can cause a leak. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/netlink_compat.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b1602452cb80239b121addc598803b6fc1223872 Merge: 35962ea 151787b Author: Dave Airlie <airlied@redhat.com> Date: Fri Jun 3 14:11:49 2016 +1000 Merge tag 'imx-drm-next-2016-06-01' of git://git.pengutronix.de/git/pza/linux into drm-fixes imx-drm updates - add support for reading LVDS panel EDID over DDC - enable UYVY/VYUY support - add support for pixel clock polarity configuration - honor the native-mode DT property for LVDS - various fixes and cleanups * tag 'imx-drm-next-2016-06-01' of git://git.pengutronix.de/git/pza/linux: drm/imx: plane: Don't set plane->crtc in ipu_plane_update() drm/imx: ipuv3-plane: Constify ipu_plane_funcs drm/imx: imx-ldb: honor 'native-mode' property when selecting video mode from DT drm/imx: parallel-display: remove dead code drm/imx: use bus_flags for pixel clock polarity drm/imx: ipuv3-plane: enable UYVY and VYUY formats drm/imx: parallel-display: use of_graph_get_endpoint_by_regs helper drm/imx: imx-ldb: use of_graph_get_endpoint_by_regs helper dt-bindings: imx: ldb: Add ddc-i2c-bus property drm/imx: imx-ldb: Add DDC support commit 35962eaef44166fd8d4fff7cb4e9c64a2da536ee Merge: 6572c8c 58a2ab3 Author: Dave Airlie <airlied@redhat.com> Date: Fri Jun 3 14:08:20 2016 +1000 Merge tag 'drm-atmel-hlcdc-fixes/for-4.7-rc2' of github.com:bbrezillon/linux-at91 into drm-fixes Two trivial bugfixes for the atmel-hlcdc driver. The first one is making use of __drm_atomic_helper_crtc_destroy_state() instead of duplicating its logic in atmel_hlcdc_crtc_reset() and risking memory leaks if other objects are added to the common CRTC state. The second one is fixing a possible NULL pointer dereference. * tag 'drm-atmel-hlcdc-fixes/for-4.7-rc2' of github.com:bbrezillon/linux-at91: drm: atmel-hlcdc: fix a NULL check drm: atmel-hlcdc: fix atmel_hlcdc_crtc_reset() implementation commit 6572c8c637278d64dfd355e84a6dcb64b9d6cf28 Merge: a9bf7d6 f6c68b4 Author: Dave Airlie <airlied@redhat.com> Date: Fri Jun 3 14:07:42 2016 +1000 Merge branch 'for-upstream/hdlcd' of git://linux-arm.org/linux-ld into drm-fixes "I have accumulated some cleanup patches for HDLCD, partly triggered by Daniel Vetter's work on non-blocking atomic operations, that I would like to integrate into v4.7. My first patch is important for the newly enabled hibernate option for AArch64 on Juno, the others are fixing behaviour in HDLCD and adding a debugfs entry to help track the underlying framebuffer usage. I'm also taking one of Daniel's patches from his non-blocking series to help with the integration of his patches later." * 'for-upstream/hdlcd' of git://linux-arm.org/linux-ld: drm: hdlcd: Add information about the underlying framebuffers in debugfs drm: hdlcd: Cleanup the atomic plane operations drm/hdlcd: Fix up crtc_state->event handling drm: hdlcd: Revamp runtime power management commit ce25d66ad5f8d921bac5fe2d32d62fa30c0f9a70 Author: Eric Dumazet <edumazet@google.com> Date: Thu Jun 2 14:52:43 2016 -0700 Possible problem with e6afc8ac ("udp: remove headers from UDP packets before queueing") Paul Moore tracked a regression caused by a recent commit, which mistakenly assumed that sk_filter() could be avoided if socket had no current BPF filter. The intent was to avoid udp_lib_checksum_complete() overhead. But sk_filter() also checks skb_pfmemalloc() and security_sock_rcv_skb(), so better call it. Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Paul Moore <paul@paul-moore.com> Tested-by: Paul Moore <paul@paul-moore.com> Tested-by: Stephen Smalley <sds@tycho.nsa.gov> Cc: samanthakumar <samanthakumar@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/udp.c | 10 +++++----- net/ipv6/udp.c | 12 ++++++------ 2 files changed, 11 insertions(+), 11 deletions(-) commit fcdec35e54dc8a7659f59482e23aad1fe9c3ef5a Author: Rob Herring <robh@kernel.org> Date: Thu Mar 24 15:40:25 2016 -0500 MAINTAINERS: DeviceTree maintainer updates Grant stepped down as kernel DT maintainer and his linaro.org email will be bouncing soon, so remove him now. Pawel, Ian and Kumar either said they don't want to remain maintainers or didn't reply, so removing them as binding maintainers. Update the DT git tree to mine. Grant's has not been active for a while now. I'm actively using patchwork for binding review tracking, so add its URL. Cc: Grant Likely <grant.likely@secretlab.ca> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Frank Rowand <frowand.list@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> MAINTAINERS | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 4340fa55298d17049e71c7a34e04647379c269f3 Merge: 719af93 d14bdb5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu Jun 2 15:08:06 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm Pull KVM fixes from Radim Krčmář: "ARM: - two fixes for 4.6 vgic [Christoffer] (cc stable) - six fixes for 4.7 vgic [Marc] x86: - six fixes from syzkaller reports [Paolo] (two of them cc stable) - allow OS X to boot [Dmitry] - don't trust compilers [Nadav]" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: KVM: x86: fix OOPS after invalid KVM_SET_DEBUGREGS KVM: x86: avoid vmalloc(0) in the KVM_SET_CPUID KVM: irqfd: fix NULL pointer dereference in kvm_irq_map_gsi KVM: fail KVM_SET_VCPU_EVENTS with invalid exception number KVM: x86: avoid vmalloc(0) in the KVM_SET_CPUID kvm: x86: avoid warning on repeated KVM_SET_TSS_ADDR KVM: Handle MSR_IA32_PERF_CTL KVM: x86: avoid write-tearing of TDP KVM: arm/arm64: vgic-new: Removel harmful BUG_ON arm64: KVM: vgic-v3: Relax synchronization when SRE==1 arm64: KVM: vgic-v3: Prevent the guest from messing with ICC_SRE_EL1 arm64: KVM: Make ICC_SRE_EL1 access return the configured SRE value KVM: arm/arm64: vgic-v3: Always resample level interrupts KVM: arm/arm64: vgic-v2: Always resample level interrupts KVM: arm/arm64: vgic-v3: Clear all dirty LRs KVM: arm/arm64: vgic-v2: Clear all dirty LRs commit 9bd616e3dbedfc103f158197c8ad93678849b1ed Author: Catalin Marinas <catalin.marinas@arm.com> Date: Wed Jun 1 18:52:16 2016 +0100 cpuidle: Do not access cpuidle_devices when !CONFIG_CPU_IDLE The cpuidle_devices per-CPU variable is only defined when CPU_IDLE is enabled. Commit c8cc7d4de7a4 ("sched/idle: Reorganize the idle loop") removed the #ifdef CONFIG_CPU_IDLE around cpuidle_idle_call() with the compiler optimising away __this_cpu_read(cpuidle_devices). However, with CONFIG_UBSAN && !CONFIG_CPU_IDLE, this optimisation no longer happens and the kernel fails to link since cpuidle_devices is not defined. This patch introduces an accessor function for the current CPU cpuidle device (returning NULL when !CONFIG_CPU_IDLE) and uses it in cpuidle_idle_call(). Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Cc: 4.5+ <stable@vger.kernel.org> # 4.5+ Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/linux/cpuidle.h | 3 +++ kernel/sched/idle.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) commit f55d84b07c4e7340473a25dc82b462607578402c Author: Vincent Palatin <vpalatin@chromium.org> Date: Wed Jun 1 08:53:48 2016 -0700 stmmac: do not sleep in atomic context for mdio_reset stmmac_mdio_reset() has been updated to use msleep rather udelay (as some PHY requires a one second delay there). It called from stmmac_resume() within the spin_lock_irqsave block atomic context triggering 'scheduling while atomic'. The stmmac_priv lock usage is not fully documented, but it seems to protect the access to the MAC registers / DMA structures rather than the MDIO bus or the PHY (which have separate locking), so we can push the spin_lock after the stmmac_mdio_reset call. Signed-off-by: Vincent Palatin <vpalatin@chromium.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 87c279e613f848c691111b29d49de8df3f4f56da Author: Omar Sandoval <osandov@fb.com> Date: Wed Jun 1 22:18:48 2016 -0700 blk-mq: really fix plug list flushing for nomerge queues Commit 0809e3ac6231 ("block: fix plug list flushing for nomerge queues") updated blk_mq_make_request() to set request_count even when blk_queue_nomerges() returns true. However, blk_mq_make_request() only does limited plugging and doesn't use request_count; blk_sq_make_request() is the one that should have been fixed. Do that and get rid of the unnecessary work in the mq version. Fixes: 0809e3ac6231 ("block: fix plug list flushing for nomerge queues") Signed-off-by: Omar Sandoval <osandov@fb.com> Reviewed-by: Ming Lei <tom.leiming@gmail.com> Reviewed-by: Jeff Moyer <jmoyer@redhat.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit b9ef22dedde08ab1b4ccd5f53344984c4dcb89f4 Author: Feifei Xu <xufeifei@linux.vnet.ibm.com> Date: Wed Jun 1 19:18:25 2016 +0800 Btrfs: self-tests: Support non-4k page size self-tests code assumes 4k as the sectorsize and nodesize. This commit fix hardcoded 4K. Enables the self-tests code to be executed on non-4k page sized systems (e.g. ppc64). Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: Feifei Xu <xufeifei@linux.vnet.ibm.com> Signed-off-by: Chandan Rajendra <chandan@linux.vnet.ibm.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.c | 6 +- fs/btrfs/disk-io.c | 8 +- fs/btrfs/disk-io.h | 2 +- fs/btrfs/extent_io.c | 10 +- fs/btrfs/extent_io.h | 4 +- fs/btrfs/free-space-cache.c | 2 +- fs/btrfs/super.c | 16 +- fs/btrfs/tests/btrfs-tests.c | 6 +- fs/btrfs/tests/btrfs-tests.h | 27 +-- fs/btrfs/tests/extent-buffer-tests.c | 11 +- fs/btrfs/tests/extent-io-tests.c | 27 +-- fs/btrfs/tests/free-space-tests.c | 68 ++++--- fs/btrfs/tests/free-space-tree-tests.c | 30 +-- fs/btrfs/tests/inode-tests.c | 344 ++++++++++++++++++--------------- fs/btrfs/tests/qgroup-tests.c | 85 ++++---- 15 files changed, 355 insertions(+), 291 deletions(-) commit 0ef6447a3d2f014e49069c4da33f905ed803aa2a Author: Feifei Xu <xufeifei@linux.vnet.ibm.com> Date: Wed Jun 1 19:18:24 2016 +0800 Btrfs: Fix integer overflow when calculating bytes_per_bitmap On ppc64, bytes_per_bitmap will be (65536*8*65536). Hence append UL to fix integer overflow. Reviewed-by: Josef Bacik <jbacik@fb.com> Reviewed-by: Chandan Rajendra <chandan@linux.vnet.ibm.com> Signed-off-by: Feifei Xu <xufeifei@linux.vnet.ibm.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/free-space-cache.c | 12 ++++++------ fs/btrfs/tests/free-space-tests.c | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) commit 5473e0c426ffaeaa19734987b153c2a7f33b8706 Author: Feifei Xu <xufeifei@linux.vnet.ibm.com> Date: Wed Jun 1 19:18:23 2016 +0800 Btrfs: test_check_exists: Fix infinite loop when searching for free space entries On a ppc64 machine using 64K as the block size, assume that the RB tree at btrfs_free_space_ctl->free_space_offset contains following two entries: 1. A bitmap entry having an offset value of 0 and having the bits corresponding to the address range [128M+512K, 128M+768K] set. 2. An extent entry corresponding to the address range [128M-256K, 128M-128K] In such a scenario, test_check_exists() invoked for checking the existence of address range [128M+768K, 256M] can lead to an infinite loop as explained below: - Checking for the extent entry fails. - Checking for a bitmap entry results in the free space info in range [128M+512K, 128M+768K] beng returned. - rb_prev(info) returns NULL because the bitmap entry starting from offset 0 comes first in the RB tree. - current_node = bitmap node. - while (current_node) tmp = rb_next(bitmap_node);/*tmp is extent based free space entry*/ Since extent based free space entry's last address is smaller than the address being searched for (i.e. 128M+768K) we incorrectly again obtain the extent node as the "next right node" of the RB tree and thus end up looping infinitely. This patch fixes the issue by checking the "tmp" variable which point to the most recently searched free space node. Reviewed-by: Josef Bacik <jbacik@fb.com> Reviewed-by: Chandan Rajendra <chandan@linux.vnet.ibm.com> Signed-off-by: Feifei Xu <xufeifei@linux.vnet.ibm.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/free-space-cache.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0de6b9979e2e10c79e5702d2d902cd7284d17689 Author: Joshua Henderson <digitalpeer@digitalpeer.com> Date: Tue May 17 10:35:53 2016 +0530 irqchip/irq-pic32-evic: Fix bug with external interrupts. The wrong external interrupt bits are being set, offset by 1. Signed-off-by: Joshua Henderson <digitalpeer@digitalpeer.com> Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-pic32-evic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fbf8f40e1658cb2f17452dbd3c708e329c5d27e0 Author: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Date: Wed May 25 15:29:20 2016 +0200 irqchip/gicv3-its: numa: Enable workaround for Cavium thunderx erratum 23144 The erratum fixes the hang of ITS SYNC command by avoiding inter node io and collections/cpu mapping on thunderx dual-socket platform. This fix is only applicable for Cavium's ThunderX dual-socket platform. Reviewed-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Signed-off-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Documentation/arm64/silicon-errata.txt | 1 + arch/arm64/Kconfig | 9 +++++++ drivers/irqchip/irq-gic-v3-its.c | 49 ++++++++++++++++++++++++++++++++-- 3 files changed, 57 insertions(+), 2 deletions(-) commit cf1d9d11e25053a264c0001aa86be7680bb1ecc1 Author: Andrew Jones <drjones@redhat.com> Date: Wed May 11 21:23:17 2016 +0200 irqchip/gic-v3: Fix quiescence check in gic_enable_redist Make sure the two sides of the bitwise operation are bool. Signed-off-by: Andrew Jones <drjones@redhat.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-v3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fab0cdc30d81694d2d5524b24e42c43414971719 Author: Andrew Jones <drjones@redhat.com> Date: Thu May 12 10:46:34 2016 +0200 irqchip/gic-v3: Fix copy+paste mistakes in defines ICC_SGI1R_AFFINITY_{2,3}_MASK are unused, which is good because they were defined with the wrong shifts. Signed-off-by: Andrew Jones <drjones@redhat.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> include/linux/irqchip/arm-gic-v3.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit dd5f1b049dc139876801db3cdd0f20d21fd428cc Author: Marc Zyngier <marc.zyngier@arm.com> Date: Thu Jun 2 09:00:28 2016 +0100 irqchip/gic-v3: Fix ICC_SGI1R_EL1.INTID decoding mask The INTID mask is wrong, and is made a signed value, which has nteresting effects in the KVM emulation. Let's sanitize it. Cc: stable@vger.kernel.org Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> include/linux/irqchip/arm-gic-v3.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6c68b4bd4a98033d1e79479212bbd376e145728 Author: Liviu Dudau <Liviu.Dudau@arm.com> Date: Wed Jun 1 15:07:02 2016 +0100 drm: hdlcd: Add information about the underlying framebuffers in debugfs drm_fb_cma code has a nice helper function to display in the debugfs information about the underlying framebuffers used by HDLCD: $ cat /sys/kernel/debug/dri/0/fb fb: 1920x1200@XR24 0: offset=0 pitch=7680, obj: 0 ( 2) 001011ba 0x00000000fc300000 ffffff800a27c000 9338880 fb: 1920x1200@XR24 0: offset=0 pitch=7680, obj: 0 ( 2) 001008ca 0x00000000fba00000 ffffff8009987000 9338880 fb: 1920x1200@XR24 0: offset=0 pitch=7680, obj: 0 ( 1) 00100000 0x00000000fb100000 ffffff8008fdc000 9216000 Add the entry in HDLCD's debugfs node. Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com> drivers/gpu/drm/arm/hdlcd_drv.c | 1 + 1 file changed, 1 insertion(+) commit 96ebb1f3ed4dca25c6f5d1868b0de61f9366612a Author: Liviu Dudau <Liviu.Dudau@arm.com> Date: Wed Jun 1 15:00:15 2016 +0100 drm: hdlcd: Cleanup the atomic plane operations Harden the plane_check() code to drop attempts at scaling because that is not supported. Make hdlcd_plane_atomic_update() set the pitch and line length registers that correctly reflect the plane's values. And make hdlcd_crtc_mode_set_nofb() a helper function for hdlcd_crtc_enable() rather than an exposed hook. Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com> drivers/gpu/drm/arm/hdlcd_crtc.c | 45 ++++++++++++++++++++++++++-------------- drivers/gpu/drm/arm/hdlcd_drv.h | 1 - 2 files changed, 29 insertions(+), 17 deletions(-) commit 38c8c22c12e99b70fc59ea7ef4d0bb24c11e5ddd Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue May 31 18:21:13 2016 +0200 drm/hdlcd: Fix up crtc_state->event handling event_list just reimplemented what drm_crtc_arm_vblank_event does. And we also need to send out drm events when shutting down a pipe. With this it's possible to use the new nonblocking commit support in the helpers. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Liviu Dudau <Liviu.Dudau@arm.com> drivers/gpu/drm/arm/hdlcd_crtc.c | 18 ++++++++---------- drivers/gpu/drm/arm/hdlcd_drv.c | 19 +------------------ drivers/gpu/drm/arm/hdlcd_drv.h | 1 - 3 files changed, 9 insertions(+), 29 deletions(-) commit a95acec16d932ac78c2f70dc95a83bd162595d6c Author: Liviu Dudau <Liviu.Dudau@arm.com> Date: Tue May 17 10:06:54 2016 +0100 drm: hdlcd: Revamp runtime power management Because the HDLCD driver acts as a component master it can end up enabling the runtime PM functionality before the encoders are initialised. This can cause crashes if the component slave never probes (missing module) or if the PM operations kick in before the probe finishes. Move the enabling of the runtime PM after the component master has finished collecting the slave components and use the DRM atomic helpers to suspend and resume the device. Tested-by: Robin Murphy <Robin.Murphy@arm.com> Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com> drivers/gpu/drm/arm/hdlcd_crtc.c | 23 +++++++++---------- drivers/gpu/drm/arm/hdlcd_drv.c | 48 ++++++++++++++++++++++------------------ drivers/gpu/drm/arm/hdlcd_drv.h | 3 +-- 3 files changed, 39 insertions(+), 35 deletions(-) commit d14bdb553f9196169f003058ae1cdabe514470e6 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:23 2016 +0200 KVM: x86: fix OOPS after invalid KVM_SET_DEBUGREGS MOV to DR6 or DR7 causes a #GP if an attempt is made to write a 1 to any of bits 63:32. However, this is not detected at KVM_SET_DEBUGREGS time, and the next KVM_RUN oopses: general protection fault: 0000 [#1] SMP CPU: 2 PID: 14987 Comm: a.out Not tainted 4.4.9-300.fc23.x86_64 #1 Hardware name: LENOVO 2325F51/2325F51, BIOS G2ET32WW (1.12 ) 05/30/2012 [...] Call Trace: [<ffffffffa072c93d>] kvm_arch_vcpu_ioctl_run+0x141d/0x14e0 [kvm] [<ffffffffa071405d>] kvm_vcpu_ioctl+0x33d/0x620 [kvm] [<ffffffff81241648>] do_vfs_ioctl+0x298/0x480 [<ffffffff812418a9>] SyS_ioctl+0x79/0x90 [<ffffffff817a0f2e>] entry_SYSCALL_64_fastpath+0x12/0x71 Code: 55 83 ff 07 48 89 e5 77 27 89 ff ff 24 fd 90 87 80 81 0f 23 fe 5d c3 0f 23 c6 5d c3 0f 23 ce 5d c3 0f 23 d6 5d c3 0f 23 de 5d c3 <0f> 23 f6 5d c3 0f 0b 66 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 RIP [<ffffffff810639eb>] native_set_debugreg+0x2b/0x40 RSP <ffff88005836bd50> Testcase (beautified/reduced from syzkaller output): #include <unistd.h> #include <sys/syscall.h> #include <string.h> #include <stdint.h> #include <linux/kvm.h> #include <fcntl.h> #include <sys/ioctl.h> long r[8]; int main() { struct kvm_debugregs dr = { 0 }; r[2] = open("/dev/kvm", O_RDONLY); r[3] = ioctl(r[2], KVM_CREATE_VM, 0); r[4] = ioctl(r[3], KVM_CREATE_VCPU, 7); memcpy(&dr, "\x5d\x6a\x6b\xe8\x57\x3b\x4b\x7e\xcf\x0d\xa1\x72" "\xa3\x4a\x29\x0c\xfc\x6d\x44\x00\xa7\x52\xc7\xd8" "\x00\xdb\x89\x9d\x78\xb5\x54\x6b\x6b\x13\x1c\xe9" "\x5e\xd3\x0e\x40\x6f\xb4\x66\xf7\x5b\xe3\x36\xcb", 48); r[7] = ioctl(r[4], KVM_SET_DEBUGREGS, &dr); r[6] = ioctl(r[4], KVM_RUN, 0); } Reported-by: Dmitry Vyukov <dvyukov@google.com> Cc: stable@vger.kernel.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/x86.c | 5 +++++ 1 file changed, 5 insertions(+) commit f8c1b85b2523da59c8c03ea94e9d0fac04155943 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:22 2016 +0200 KVM: x86: avoid vmalloc(0) in the KVM_SET_CPUID This causes an ugly dmesg splat. Beautified syzkaller testcase: #include <unistd.h> #include <sys/syscall.h> #include <sys/ioctl.h> #include <fcntl.h> #include <linux/kvm.h> long r[8]; int main() { struct kvm_irq_routing ir = { 0 }; r[2] = open("/dev/kvm", O_RDWR); r[3] = ioctl(r[2], KVM_CREATE_VM, 0); r[4] = ioctl(r[3], KVM_SET_GSI_ROUTING, &ir); return 0; } Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> virt/kvm/kvm_main.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) commit c622a3c21ede892e370b56e1ceb9eb28f8bbda6b Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:21 2016 +0200 KVM: irqfd: fix NULL pointer dereference in kvm_irq_map_gsi Found by syzkaller: BUG: unable to handle kernel NULL pointer dereference at 0000000000000120 IP: [<ffffffffa0797202>] kvm_irq_map_gsi+0x12/0x90 [kvm] PGD 6f80b067 PUD b6535067 PMD 0 Oops: 0000 [#1] SMP CPU: 3 PID: 4988 Comm: a.out Not tainted 4.4.9-300.fc23.x86_64 #1 [...] Call Trace: [<ffffffffa0795f62>] irqfd_update+0x32/0xc0 [kvm] [<ffffffffa0796c7c>] kvm_irqfd+0x3dc/0x5b0 [kvm] [<ffffffffa07943f4>] kvm_vm_ioctl+0x164/0x6f0 [kvm] [<ffffffff81241648>] do_vfs_ioctl+0x298/0x480 [<ffffffff812418a9>] SyS_ioctl+0x79/0x90 [<ffffffff817a1062>] tracesys_phase2+0x84/0x89 Code: b5 71 a7 e0 5b 41 5c 41 5d 5d f3 c3 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 55 48 8b 8f 10 2e 00 00 31 c0 48 89 e5 <39> 91 20 01 00 00 76 6a 48 63 d2 48 8b 94 d1 28 01 00 00 48 85 RIP [<ffffffffa0797202>] kvm_irq_map_gsi+0x12/0x90 [kvm] RSP <ffff8800926cbca8> CR2: 0000000000000120 Testcase: #include <unistd.h> #include <sys/syscall.h> #include <string.h> #include <stdint.h> #include <linux/kvm.h> #include <fcntl.h> #include <sys/ioctl.h> long r[26]; int main() { memset(r, -1, sizeof(r)); r[2] = open("/dev/kvm", 0); r[3] = ioctl(r[2], KVM_CREATE_VM, 0); struct kvm_irqfd ifd; ifd.fd = syscall(SYS_eventfd2, 5, 0); ifd.gsi = 3; ifd.flags = 2; ifd.resamplefd = ifd.fd; r[25] = ioctl(r[3], KVM_IRQFD, &ifd); return 0; } Reported-by: Dmitry Vyukov <dvyukov@google.com> Cc: stable@vger.kernel.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> virt/kvm/irqchip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 78e546c824fa8f96d323b7edd6f5cad5b74af057 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:20 2016 +0200 KVM: fail KVM_SET_VCPU_EVENTS with invalid exception number This cannot be returned by KVM_GET_VCPU_EVENTS, so it is okay to return EINVAL. It causes a WARN from exception_type: WARNING: CPU: 3 PID: 16732 at arch/x86/kvm/x86.c:345 exception_type+0x49/0x50 [kvm]() CPU: 3 PID: 16732 Comm: a.out Tainted: G W 4.4.6-300.fc23.x86_64 #1 Hardware name: LENOVO 2325F51/2325F51, BIOS G2ET32WW (1.12 ) 05/30/2012 0000000000000286 000000006308a48b ffff8800bec7fcf8 ffffffff813b542e 0000000000000000 ffffffffa0966496 ffff8800bec7fd30 ffffffff810a40f2 ffff8800552a8000 0000000000000000 00000000002c267c 0000000000000001 Call Trace: [<ffffffff813b542e>] dump_stack+0x63/0x85 [<ffffffff810a40f2>] warn_slowpath_common+0x82/0xc0 [<ffffffff810a423a>] warn_slowpath_null+0x1a/0x20 [<ffffffffa0924809>] exception_type+0x49/0x50 [kvm] [<ffffffffa0934622>] kvm_arch_vcpu_ioctl_run+0x10a2/0x14e0 [kvm] [<ffffffffa091c04d>] kvm_vcpu_ioctl+0x33d/0x620 [kvm] [<ffffffff81241248>] do_vfs_ioctl+0x298/0x480 [<ffffffff812414a9>] SyS_ioctl+0x79/0x90 [<ffffffff817a04ee>] entry_SYSCALL_64_fastpath+0x12/0x71 ---[ end trace b1a0391266848f50 ]--- Testcase (beautified/reduced from syzkaller output): #include <unistd.h> #include <sys/syscall.h> #include <string.h> #include <stdint.h> #include <fcntl.h> #include <sys/ioctl.h> #include <linux/kvm.h> long r[31]; int main() { memset(r, -1, sizeof(r)); r[2] = open("/dev/kvm", O_RDONLY); r[3] = ioctl(r[2], KVM_CREATE_VM, 0); r[7] = ioctl(r[3], KVM_CREATE_VCPU, 0); struct kvm_vcpu_events ve = { .exception.injected = 1, .exception.nr = 0xd4 }; r[27] = ioctl(r[7], KVM_SET_VCPU_EVENTS, &ve); r[30] = ioctl(r[7], KVM_RUN, 0); return 0; } Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/x86.c | 4 ++++ 1 file changed, 4 insertions(+) commit 83676e923895adf2af392cfd36a05709950aaeef Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:19 2016 +0200 KVM: x86: avoid vmalloc(0) in the KVM_SET_CPUID This causes an ugly dmesg splat. Beautified syzkaller testcase: #include <unistd.h> #include <sys/syscall.h> #include <sys/ioctl.h> #include <fcntl.h> #include <linux/kvm.h> long r[8]; int main() { struct kvm_cpuid2 c = { 0 }; r[2] = open("/dev/kvm", O_RDWR); r[3] = ioctl(r[2], KVM_CREATE_VM, 0); r[4] = ioctl(r[3], KVM_CREATE_VCPU, 0x8); r[7] = ioctl(r[4], KVM_SET_CPUID, &c); return 0; } Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/cpuid.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) commit b21629da120dd6145d14dbd6d028e1bba680a92b Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed Jun 1 14:09:18 2016 +0200 kvm: x86: avoid warning on repeated KVM_SET_TSS_ADDR Found by syzkaller: WARNING: CPU: 3 PID: 15175 at arch/x86/kvm/x86.c:7705 __x86_set_memory_region+0x1dc/0x1f0 [kvm]() CPU: 3 PID: 15175 Comm: a.out Tainted: G W 4.4.6-300.fc23.x86_64 #1 Hardware name: LENOVO 2325F51/2325F51, BIOS G2ET32WW (1.12 ) 05/30/2012 0000000000000286 00000000950899a7 ffff88011ab3fbf0 ffffffff813b542e 0000000000000000 ffffffffa0966496 ffff88011ab3fc28 ffffffff810a40f2 00000000000001fd 0000000000003000 ffff88014fc50000 0000000000000000 Call Trace: [<ffffffff813b542e>] dump_stack+0x63/0x85 [<ffffffff810a40f2>] warn_slowpath_common+0x82/0xc0 [<ffffffff810a423a>] warn_slowpath_null+0x1a/0x20 [<ffffffffa09251cc>] __x86_set_memory_region+0x1dc/0x1f0 [kvm] [<ffffffffa092521b>] x86_set_memory_region+0x3b/0x60 [kvm] [<ffffffffa09bb61c>] vmx_set_tss_addr+0x3c/0x150 [kvm_intel] [<ffffffffa092f4d4>] kvm_arch_vm_ioctl+0x654/0xbc0 [kvm] [<ffffffffa091d31a>] kvm_vm_ioctl+0x9a/0x6f0 [kvm] [<ffffffff81241248>] do_vfs_ioctl+0x298/0x480 [<ffffffff812414a9>] SyS_ioctl+0x79/0x90 [<ffffffff817a04ee>] entry_SYSCALL_64_fastpath+0x12/0x71 Testcase: #include <unistd.h> #include <sys/ioctl.h> #include <fcntl.h> #include <string.h> #include <linux/kvm.h> long r[8]; int main() { memset(r, -1, sizeof(r)); r[2] = open("/dev/kvm", O_RDONLY|O_TRUNC); r[3] = ioctl(r[2], KVM_CREATE_VM, 0x0ul); r[5] = ioctl(r[3], KVM_SET_TSS_ADDR, 0x20000000ul); r[7] = ioctl(r[3], KVM_SET_TSS_ADDR, 0x20000000ul); return 0; } Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/x86.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0c2df2a1affd183ba9c114915f42a2d464b4f58f Author: Dmitry Bilunov <kmeaw@yandex-team.ru> Date: Tue May 31 17:38:24 2016 +0300 KVM: Handle MSR_IA32_PERF_CTL Intel CPUs having Turbo Boost feature implement an MSR to provide a control interface via rdmsr/wrmsr instructions. One could detect the presence of this feature by issuing one of these instructions and handling the #GP exception which is generated in case the referenced MSR is not implemented by the CPU. KVM's vCPU model behaves exactly as a real CPU in this case by injecting a fault when MSR_IA32_PERF_CTL is called (which KVM does not support). However, some operating systems use this register during an early boot stage in which their kernel is not capable of handling #GP correctly, causing #DP and finally a triple fault effectively resetting the vCPU. This patch implements a dummy handler for MSR_IA32_PERF_CTL to avoid the crashes. Signed-off-by: Dmitry Bilunov <kmeaw@yandex-team.ru> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/x86.c | 1 + 1 file changed, 1 insertion(+) commit b19ee2ff3b287fea48a2896a381e31319394fe58 Author: Nadav Amit <nadav.amit@gmail.com> Date: Wed May 11 08:04:29 2016 -0700 KVM: x86: avoid write-tearing of TDP In theory, nothing prevents the compiler from write-tearing PTEs, or split PTE writes. These partially-modified PTEs can be fetched by other cores and cause mayhem. I have not really encountered such case in real-life, but it does seem possible. For example, the compiler may try to do something creative for kvm_set_pte_rmapp() and perform multiple writes to the PTE. Signed-off-by: Nadav Amit <nadav.amit@gmail.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/mmu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 13e98fd1efc7f65cab1bba6cfab7859840f9aa66 Merge: e28e909 05fb05a Author: Radim Krčmář <rkrcmar@redhat.com> Date: Thu Jun 2 17:28:04 2016 +0200 Merge tag 'kvm-arm-for-v4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm KVM/ARM Fixes for v4.7-rc2 Fixes for the vgic, 2 of the patches address a bug introduced in v4.6 while the rest are for the new vgic. commit e2dfb4b880146bfd4b6aa8e138c0205407cebbaf Author: Russell King <rmk+kernel@armlinux.org.uk> Date: Mon May 30 23:14:56 2016 +0100 ARM: fix PTRACE_SETVFPREGS on SMP systems PTRACE_SETVFPREGS fails to properly mark the VFP register set to be reloaded, because it undoes one of the effects of vfp_flush_hwstate(). Specifically vfp_flush_hwstate() sets thread->vfpstate.hard.cpu to an invalid CPU number, but vfp_set() overwrites this with the original CPU number, thereby rendering the hardware state as apparently "valid", even though the software state is more recent. Fix this by reverting the previous change. Cc: <stable@vger.kernel.org> Fixes: 8130b9d7b9d8 ("ARM: 7308/1: vfp: flush thread hwstate before copying ptrace registers") Acked-by: Will Deacon <will.deacon@arm.com> Tested-by: Simon Marchi <simon.marchi@ericsson.com> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk> arch/arm/kernel/ptrace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7b7eba0f3515fca3296b8881d583f7c1042f5226 Author: Florian Westphal <fw@strlen.de> Date: Wed Jun 1 02:04:44 2016 +0200 netfilter: x_tables: don't reject valid target size on some architectures Quoting John Stultz: In updating a 32bit arm device from 4.6 to Linus' current HEAD, I noticed I was having some trouble with networking, and realized that /proc/net/ip_tables_names was suddenly empty. Digging through the registration process, it seems we're catching on the: if (strcmp(t->u.user.name, XT_STANDARD_TARGET) == 0 && target_offset + sizeof(struct xt_standard_target) != next_offset) return -EINVAL; Where next_offset seems to be 4 bytes larger then the offset + standard_target struct size. next_offset needs to be aligned via XT_ALIGN (so we can access all members of ip(6)t_entry struct). This problem didn't show up on i686 as it only needs 4-byte alignment for u64, but iptables userspace on other 32bit arches does insert extra padding. Reported-by: John Stultz <john.stultz@linaro.org> Tested-by: John Stultz <john.stultz@linaro.org> Fixes: 7ed2abddd20cf ("netfilter: x_tables: check standard target size too") Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/x_tables.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6de7df8d1b1a45a07d6ecc6b4f94179e1e68f5ec Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 31 23:12:00 2016 +0200 ASoC: hdmi-codec: select CONFIG_HDMI SND_SOC_HDMI_CODEC can be enabled without HDMI support, leading to a link error: In function `hdmi_codec_hw_params': sound/soc/codecs/hdmi-codec.c:188: undefined reference to `hdmi_audio_infoframe_init' sound/built-in.o:(.debug_addr+0x1a5c0): undefined reference to `hdmi_audio_infoframe_init' This changes the Kconfig file to select HDMI, as the other codec using hdmi_audio_infoframe_init already does. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Jyri Sarha <jsarha@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 8e1cc0e4bab7b44a55ea59d26683b618b34950bc Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Thu Jun 2 12:55:05 2016 +0300 ASoC: davinci-mcasp: Fix dra7 DMA offset when using CFG port The TX and RX offset is different for each serializers when using the CFG port for DMA access. When using the CFG port only one serializer can be used per direction so print error message and only configure the first serializer's offset. Reported-by: Misael Lopez Cruz <misael.lopez@ti.com> Suggested-by: Misael Lopez Cruz <misael.lopez@ti.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 56 ++++++++++++++++++++++++++++++++++++--- sound/soc/davinci/davinci-mcasp.h | 4 +-- 2 files changed, 54 insertions(+), 6 deletions(-) commit 05fb05a6ca25e02ad8c31bc440b3c4996864f379 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Thu Jun 2 09:24:06 2016 +0100 KVM: arm/arm64: vgic-new: Removel harmful BUG_ON When changing the active bit from an MMIO trap, we decide to explode if the intid is that of a private interrupt. This flawed logic comes from the fact that we were assuming that kvm_vcpu_kick() as called by kvm_arm_halt_vcpu() would not return before the called vcpu responded, but this is not the case, so we need to perform this wait even for private interrupts. Dropping the BUG_ON seems like the right thing to do. [ Commit message tweaked by Christoffer ] Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit afefc102df1bf5b75d7106771ecbe0ef546edc96 Author: Chen-Yu Tsai <wens@csie.org> Date: Sun May 29 15:04:44 2016 +0800 mmc: sunxi: Re-enable eMMC HS-DDR modes on Allwinner A80 Now the the HS-DDR mode clock timings have been corrected, we can re-enable these modes on the A80. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sunxi-mmc.c | 5 ----- 1 file changed, 5 deletions(-) commit 0175249efa9310eed79650209600a75ace656bc9 Author: Chen-Yu Tsai <wens@csie.org> Date: Sun May 29 15:04:43 2016 +0800 mmc: sunxi: Fix DDR MMC timings for A80 The MMC clock timings were incorrectly calculated, when the conversion from delay value to delay phase was done. The 50M DDR and 50M DDR 8bit timings are off, and make eMMC DDR unusable. Unfortunately it seems different controllers on the same SoC have different timings. The new settings are taken from mmc2, which is commonly used with eMMC. The settings for the slower timing modes seem to work despite being wrong, so leave them be. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sunxi-mmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f741494363c6c90e6744117d2771bbdf0fb3c455 Author: Chen-Yu Tsai <wens@csie.org> Date: Sun May 29 15:04:42 2016 +0800 mmc: fix mmc mode selection for HS-DDR and higher When IS_ERR_VALUE was removed from the mmc core code, it was replaced with a simple not-zero check. This does not work, as the value checked is the return value for mmc_select_bus_width, which returns the set bit width on success. This made eMMC modes higher than HS-DDR unusable. Fix this by checking for a positive return value instead. Fixes: 287980e49ffc ("remove lots of IS_ERR_VALUE abuses") Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Jaehoon Chung <jh80.chung@samsung.com> Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com> Tested-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Tested-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ed6aefed726a305bd36344e230d2a9e9301226fc Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue May 31 16:35:09 2016 +0530 Revert "ARCv2: spinlock/rwlock/atomics: Delayed retry of failed SCOND with exponential backoff" This reverts commit e78fdfef84be13a5c2b8276e12203cdf24778596. The issue was fixed in hardware in HS2.1C release and there are no known external users of affected RTL so revert the whole delayed retry series ! Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 5 - arch/arc/include/asm/atomic.h | 46 +------ arch/arc/include/asm/spinlock.h | 293 ---------------------------------------- 3 files changed, 4 insertions(+), 340 deletions(-) commit 819f3602dcbd6b021cd50e18f5d05da30bca5b07 Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue May 31 16:33:29 2016 +0530 Revert "ARCv2: spinlock/rwlock: Reset retry delay when starting a new spin-wait cycle" This reverts commit b89aa12c177477e34caa722818536fb5d0bffd76. The issue was fixed in hardware in HS2.1C release and there are no known external users of affected RTL so revert the whole delayed retry series ! Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/spinlock.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 42316a201a60be38b07db1ebc3a1633107ed7209 Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue May 31 16:31:33 2016 +0530 Revert "ARCv2: spinlock/rwlock/atomics: reduce 1 instruction in exponential backoff" This reverts commit 10971638701dedadb58c88ce4d31c9375b224ed6. The issue was fixed in hardware in HS2.1C release and there are no known external users of affected RTL - so revert thw whole delayed retry series ! Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/atomic.h | 3 ++- arch/arc/include/asm/spinlock.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 14b84e8654c89ed59f433654e6bb64c886d095cd Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Jun 1 15:29:13 2016 +0200 qed: fix qed_fill_link() error handling gcc warns about qed_fill_link possibly accessing uninitialized data: drivers/net/ethernet/qlogic/qed/qed_main.c: In function 'qed_fill_link': drivers/net/ethernet/qlogic/qed/qed_main.c:1170:35: error: 'link_caps' may be used uninitialized in this function [-Werror=maybe-uninitialized] While this warning is only about the specific case of CONFIG_QED_SRIOV being disabled but the function getting called for a VF (which should never happen), another possibility is that qed_mcp_get_*() fails without returning data. This rearranges the code so we bail out in either of the two cases and print a warning instead of accessing the uninitialized data. The qed_link_output structure remains untouched in this case, but all callers first call memset() on it, so at least we are not leaking stack data then. As discussed, we also use a compile-time check to ensure we never use any of the VF code if CONFIG_QED_SRIOV is disabled, and the PCI device table is updated to no longer bind to virtual functions in that configuration. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 45 ++++++++++++++++++++++------ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 4 ++- drivers/net/ethernet/qlogic/qede/qede_main.c | 2 ++ 3 files changed, 41 insertions(+), 10 deletions(-) commit bfa49cfc526201119623de6593d284c96563bede Author: Colin Ian King <colin.king@canonical.com> Date: Wed Jun 1 14:16:50 2016 +0100 net/ethoc: fix null dereference on error exit path priv is assigned to NULL however some of the early error exit paths to label 'free' dereference priv, causing a null pointer dereference. Move the label 'free' to just the free_netdev statement, and add a new exit path 'free2' for the error cases were clk_disable_unprepare needs calling before the final free. Fixes issue found by CoverityScan, CID#113260 Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ethoc.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 77154fd969df749f5bf83f639af19fca199de033 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Jun 2 12:42:32 2016 +1000 drm/nouveau/core: swap the order of imem/fb Fixes a use-after-free reported by valgrind and KASAN. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/core/device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f045f459d925138fe7d6193a8c86406bda7e49da Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Jun 2 12:23:31 2016 +1000 drm/nouveau/fbcon: fix out-of-bounds memory accesses Reported by KASAN. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nouveau_fbcon.c | 1 + drivers/gpu/drm/nouveau/nv04_fbcon.c | 7 ++----- drivers/gpu/drm/nouveau/nv50_fbcon.c | 6 ++---- drivers/gpu/drm/nouveau/nvc0_fbcon.c | 6 ++---- 4 files changed, 7 insertions(+), 13 deletions(-) commit 383d0a419f8e63e3d65e706c3c515fa9505ce364 Author: Ben Skeggs <bskeggs@redhat.com> Date: Wed Jun 1 16:20:10 2016 +1000 drm/nouveau/gr/gf100-: update sm error decoding from gk20a nvgpu headers Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 37 +++++++++++++++++++------- 1 file changed, 28 insertions(+), 9 deletions(-) commit 9057c8d75018f05bbc769d7b4602de3b8b20f8aa Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri May 27 12:01:27 2016 +1000 drm/nouveau/ltc/gm107-: fix typo in the address of NV_PLTCG_LTC0_LTS0_INTR Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/nvkm/subdev/ltc/gm107.c | 6 +++--- drivers/gpu/drm/nouveau/nvkm/subdev/ltc/gm200.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit bc9139d23f6b038e32bcd2dffdee70a8d76b3976 Author: Ben Skeggs <bskeggs@redhat.com> Date: Wed May 25 10:56:24 2016 +1000 drm/nouveau/bios/disp: fix handling of "match any protocol" entries As it turns out, a value of 0xff means "any protocol" and not "VGA". Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Cc: stable@vger.kernel.org drivers/gpu/drm/nouveau/include/nvkm/subdev/bios/disp.h | 5 +++-- drivers/gpu/drm/nouveau/nvkm/engine/disp/gf119.c | 13 +++++-------- drivers/gpu/drm/nouveau/nvkm/engine/disp/nv50.c | 12 ++++-------- drivers/gpu/drm/nouveau/nvkm/subdev/bios/disp.c | 8 +++++--- 4 files changed, 17 insertions(+), 21 deletions(-) commit 6b7e9cde49691e04314342b7dce90c67ad567fcc Author: Martin K. Petersen <martin.petersen@oracle.com> Date: Thu May 12 22:17:34 2016 -0400 sd: Fix rw_max for devices that report an optimal xfer size For historic reasons, io_opt is in bytes and max_sectors in block layer sectors. This interface inconsistency is error prone and should be fixed. But for 4.4--4.7 let's make the unit difference explicit via a wrapper function. Fixes: d0eb20a863ba ("sd: Optimal I/O size is in bytes, not sectors") Cc: stable@vger.kernel.org # 4.4+ Reported-by: Fam Zheng <famz@redhat.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Tested-by: Andrew Patterson <andrew.patterson@hpe.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/sd.c | 8 ++++---- drivers/scsi/sd.h | 5 +++++ 2 files changed, 9 insertions(+), 4 deletions(-) commit fc14963f249f9aca1ac84c9c8659b4f35e0a315e Merge: 31843af 893e093 Author: David S. Miller <davem@davemloft.net> Date: Wed Jun 1 17:54:19 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf Pablo Neira Ayuso says: ==================== Netfilter fixes for net The following patchset contains Netfilter fixes for your net tree, they are: 1) Fix incorrect timestamp in nfnetlink_queue introduced when addressing y2038 safe timestamp, from Florian Westphal. 2) Get rid of leftover conntrack definition from the previous merge window, oneliner from Florian. 3) Make nf_queue handler pernet to resolve race on dereferencing the hook state structure with netns removal, from Eric Biederman. 4) Ensure clean exit on unregistered helper ports, from Taehee Yoo. 5) Restore FLOWI_FLAG_KNOWN_NH in nf_dup_ipv6. This got lost while generalizing xt_TEE to add packet duplication support in nf_tables, from Paolo Abeni. 6) Insufficient netlink NFTA_SET_TABLE attribute check in nf_tables_getset(), from Phil Turnbull. 7) Reject helper registration on duplicated ports via modparams. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 31843af4dc6acb71c4bd287afe7921c81b0b6fcb Merge: 6b15d66 6fe0412 Author: David S. Miller <davem@davemloft.net> Date: Wed Jun 1 17:53:19 2016 -0700 Merge tag 'mac80211-for-davem-2016-06-01' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211 Johannes Berg says: ==================== Three small fixes for the current cycle: * missing netlink attribute check in hwsim wmediumd (Martin) * fast xmit structure alignment fix (Felix) * mesh path flush/synchronisation fix (Bob) ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f881dd29bf31fb9e8072a3a47c834fa804f7d249 Merge: 56244ef b5de8d0 Author: Chris Mason <clm@fb.com> Date: Wed Jun 1 17:03:50 2016 -0700 Merge branch 'dev-replace-fixes-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/fdmanana/linux into for-linus-4.7 commit 86314751c7945fa0c67f459beeda2e7c610ca429 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Jun 2 01:57:50 2016 +0200 ACPI / processor: Avoid reserving IO regions too early Roland Dreier reports that one of his systems cannot boot because of the changes made by commit ac212b6980d8 (ACPI / processor: Use common hotplug infrastructure). The problematic part of it is the request_region() call in acpi_processor_get_info() that used to run at module init time before the above commit and now it runs much earlier. Unfortunately, the region(s) reserved by it fall into a range the PCI subsystem attempts to reserve for AHCI IO BARs. As a result, the PCI reservation fails and AHCI doesn't work, while previously the PCI reservation would be made before acpi_processor_get_info() and it would succeed. That request_region() call, however, was overlooked by commit ac212b6980d8, as it is not necessary for the enumeration of the processors. It only is needed when the ACPI processor driver actually attempts to handle them which doesn't happen before loading the ACPI processor driver module. Therefore that call should have been moved from acpi_processor_get_info() into that module. Address the problem by moving the request_region() call in question out of acpi_processor_get_info() and use the observation that the region reserved by it is only needed if the FADT-based CPU throttling method is going to be used, which means that it should be sufficient to invoke it from acpi_processor_get_throttling_fadt(). Fixes: ac212b6980d8 (ACPI / processor: Use common hotplug infrastructure) Reported-by: Roland Dreier <roland@purestorage.com> Tested-by: Roland Dreier <roland@purestorage.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpi_processor.c | 9 --------- drivers/acpi/processor_throttling.c | 9 +++++++++ 2 files changed, 9 insertions(+), 9 deletions(-) commit 72ad679aa7182d23d269cbe4d655f7e129d3b057 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Mon May 16 12:45:36 2016 -0300 clk: nxp: Select MFD_SYSCON for creg driver Commit 378523d15003 ("clk: add lpc18xx creg clk driver") added a new clock driver but missed the proper MFD_SYSCON select. Fix it. Fixes: 378523d15003 ("clk: add lpc18xx creg clk driver") Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/Kconfig | 1 + 1 file changed, 1 insertion(+) commit ae4185cd13a3017259d30149e606f8c83857acf2 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:05:48 2016 +0200 MAINTAINERS: Add file patterns for clock device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: linux-clk@vger.kernel.org Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 7b2c17f829545df27a910e8d82e133c21c9a8c9c Author: Andrew Goodbody <andrew.goodbody@cambrionix.com> Date: Tue May 31 10:05:27 2016 -0500 usb: musb: Stop bulk endpoint while queue is rotated Ensure that the endpoint is stopped by clearing REQPKT before clearing DATAERR_NAKTIMEOUT before rotating the queue on the dedicated bulk endpoint. This addresses an issue where a race could result in the endpoint receiving data before it was reprogrammed resulting in a warning about such data from musb_rx_reinit before it was thrown away. The data thrown away was a valid packet that had been correctly ACKed which meant the host and device got out of sync. Signed-off-by: Andrew Goodbody <andrew.goodbody@cambrionix.com> Cc: stable@vger.kernel.org Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit f3eec0cf784e0d6c47822ca6b66df3d5812af7e6 Author: Andrew Goodbody <andrew.goodbody@cambrionix.com> Date: Tue May 31 10:05:26 2016 -0500 usb: musb: Ensure rx reinit occurs for shared_fifo endpoints shared_fifo endpoints would only get a previous tx state cleared out, the rx state was only cleared for non shared_fifo endpoints Change this so that the rx state is cleared for all endpoints. This addresses an issue that resulted in rx packets being dropped silently. Signed-off-by: Andrew Goodbody <andrew.goodbody@cambrionix.com> Cc: stable@vger.kernel.org Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit 04471eb8c3158c0ad9df4b24da845a63b2e8f23a Author: Bin Liu <b-liu@ti.com> Date: Tue May 31 10:05:25 2016 -0500 usb: musb: host: correct cppi dma channel for isoch transfer Incorrect cppi dma channel is referenced in musb_rx_dma_iso_cppi41(), which causes kernel NULL pointer reference oops later when calling cppi41_dma_channel_program(). Fixes: 069a3fd (usb: musb: Remove ifdefs for musb_host_rx in musb_host.c part1) Cc: <stable@vger.kernel.org> # v4.2+ Reported-by: Matwey V. Kornilov <matwey@sai.msu.ru> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 84ac5d1140f716a616522f952734e850448d2556 Author: Bin Liu <b-liu@ti.com> Date: Tue May 31 10:05:24 2016 -0500 usb: musb: only restore devctl when session was set in backup If the session bit was not set in the backup of devctl register, restoring devctl would clear the session bit. Therefor, only restore devctl register when the session bit was set in the backup. This solves the device enumeration failure in otg mode exposed by commit 56f487c (PM / Runtime: Update last_busy in rpm_resume). Cc: <stable@vger.kernel.org> # v4.2+ Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b6a619a883c38e3f01749afe13dd23395c94a058 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:23 2016 -0500 usb: phy: Check initial state for twl6030 We need to check the state for the PHY with delayed_work as otherwise MUSB will get confused and idles immediately. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/phy/phy-twl6030-usb.c | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) commit aec373c1e5d87d791525a675fe726c11d64b84a8 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:22 2016 -0500 usb: musb: Use normal module_init for 2430 glue There's no longer any need for custom initcall level for musb. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) commit 1c4d0b4e18068b49e0eb9bf5125ff25c6d1452cd Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:21 2016 -0500 usb: musb: Remove pm_runtime_set_irq_safe With the pull up being handled with delayed work, we can now finally remove pm_runtime_set_irq_safe that blocks the MUSB glue from idling. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 6 ------ 1 file changed, 6 deletions(-) commit 87326e858448c40e32f142c0b8dcc59d7b27c641 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:20 2016 -0500 usb: musb: Remove extra PM runtime calls from 2430 glue layer With PM runtime behaving, these are all now unnecessary. Doing pm_runtime_get(musb->controller) will keep the parent glue layer also active. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 28 ++++------------------------ 1 file changed, 4 insertions(+), 24 deletions(-) commit 12b7db2bf8b88938798c60416172b53225207b1f Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:19 2016 -0500 usb: musb: Return error value from musb_mailbox At least on n900 we have phy-twl4030-usb only generating cable interrupts, and then have a separate USB PHY. In order for musb to know the real cable status, we need to clear any cached state until musb is ready. Otherwise the cable status interrupts will get just ignored if the status does not change from the initial state. To do this, let's add a return value to musb_mailbox(), and reset cached linkstat to MUSB_UNKNOWN on error. Sorry to cause a bit of churn here, I should have added that already last time patching musb_mailbox(). Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/phy/phy-twl4030-usb.c | 14 ++++++++++---- drivers/usb/musb/musb_core.c | 7 ++++--- drivers/usb/musb/musb_core.h | 2 +- drivers/usb/musb/omap2430.c | 8 +++++--- drivers/usb/phy/phy-twl6030-usb.c | 12 +++++++++--- include/linux/usb/musb.h | 5 +++-- 6 files changed, 32 insertions(+), 16 deletions(-) commit a118df07f5b19e4879fd67e98a69f4644136877f Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:18 2016 -0500 usb: musb: Don't set d+ high before enable for 2430 glue layer At least 2430 glue layer pulls d+ high on start up even if there are no gadgets configured. This is bad at least for anything using a separate battery charger chip as it can confuse the charger detection. Let's fix the issue by removing the bogus glue layer code tinkering with the SESSION bit. As pointed out Bin Liu <b-liu@ti.com> and Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>, the SESSION bit just starts host mode if ID pin is grounded, and starts the srp is ID pin is floating. So without the ID pin changing, it's unable to force musb mode to anything. And just for starting a host mode, things work fine without this code. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 11 ----------- 1 file changed, 11 deletions(-) commit 4dc2fe7a94d07c6148eea5722e23d4c1dbecc9e3 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:17 2016 -0500 usb: musb: Remove try_idle for 2430 glue layer This is no longer needed with PM runtime at least for 2430 glue. We can now rely only on PM runtime and cable detection. The other glue layers can probably remove try_idle too, but that needs to be tested for each platform before doing it. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 91 --------------------------------------------- 1 file changed, 91 deletions(-) commit a83e17d0f73b2c53ffd40773c227bf4b901365d8 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:16 2016 -0500 usb: musb: Improve PM runtime and phy handling for 2430 glue layer This simplifies things and allows idling both MUSB and PHY when nothing is configured. Let's just return early from PM runtime if musb is not yet initialized. Let's also warn if PHY is not configured. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) commit 21f77beece2b6f479648192a87ededd2fb8f1716 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:15 2016 -0500 usb: musb: Handle cable status better for 2430 glue layer We may have drivers loaded but no configured gadgets and MUSB may be in host mode. If gadgets are configured during host mode, PM runtime will get confused. Disable PM runtime from gadget state, and do it based on the cable and last state. Note that we may get multiple cable events, so we need to keep track of the power state. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/omap2430.c | 68 +++++++++++++++++++++++++++++++++++++++------ 1 file changed, 60 insertions(+), 8 deletions(-) commit 517bafffcaf8f882299a74e310082e7b6b2288ad Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:14 2016 -0500 usb: musb: Use delayed for musb_gadget_pullup We have MUSB setting pm_runtime_irq_safe with the following commits: 30a70b026b4c ("usb: musb: fix obex in g_nokia.ko causing kernel panic") 3e43a0725637 ("usb: musb: core: add pm_runtime_irq_safe()") Let's fix things to use delayed work so we can remove the pm_runtime_irq_safe. Note that we may want to set this up in a generic way in the gadget framework eventually. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.h | 1 + drivers/usb/musb/musb_gadget.c | 24 ++++++++++++++++++------ 2 files changed, 19 insertions(+), 6 deletions(-) commit 30647217909ea8ce4d8f4905b15fa1bb09d80859 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:13 2016 -0500 usb: musb: Remove conditional PM runtime calls for musb_gadget The conditional use of PM runtime does not work properly for musb gadget. On cable disconnect we may not get any USB_EVENT_NONE leaving the PM runtime call unpaired. Let's fix the issue by making sure the PM runtime calls are paired within the functions. The glue layer will take care of the rest. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_gadget.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit f730f205cc5116b6edfedf568fdfbb4935248e8e Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:12 2016 -0500 usb: musb: Split PM runtime between wrapper IP and musb core Let's not tinker with the PM runtime of musb core from the omap2430 wrapper. This allows us to initialize PM runtime for musb core later on instead of doing it in stages. And omap2430 wrapper has no need to for accessing musb core at this point. Note that this does not remove all the PM runtime calls from the glue layer, those will get removed in a later patch. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 39 +++++++++++++++++---------------------- drivers/usb/musb/omap2430.c | 10 ---------- 2 files changed, 17 insertions(+), 32 deletions(-) commit 7099dbc5b3eb9f52efdb78406826f7463f07d71c Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:11 2016 -0500 usb: musb: Update to use PM runtime autosuspend Let's make the PM runtime use the standard autosuspend calls. Commit 5de85b9d57ab ("PM / runtime: Re-init runtime PM states at probe error and driver unbind") means we must pair use_autosuspend with dont_use_autosuspend and then use put_sync to properly idle the device. Note that we'll be removing the PM runtime calls from the glue layer to the MUSB core in the next patch. And we can also remove the pointless FIXME comment now. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 9 ++++++--- drivers/usb/musb/musb_gadget.c | 3 ++- drivers/usb/musb/omap2430.c | 5 +++-- 3 files changed, 11 insertions(+), 6 deletions(-) commit 302f6802395f58dceb225b1c9e603de72f09b8b0 Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:10 2016 -0500 usb: musb: Remove unnecessary shutdown function We have remove() already calling shutdown(), so let's drop it and move the code to remove(). No code changes, we'll drop the the FIXME in the following patch with more clean-up. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 39 ++++++++++++++------------------------- 1 file changed, 14 insertions(+), 25 deletions(-) commit 7e1704dcf6b0a895f99e386ccc9ca631117e6d5b Author: Tony Lindgren <tony@atomide.com> Date: Tue May 31 10:05:09 2016 -0500 usb: musb: Fix idling after host mode by increasing autosuspend delay Looks like at least 2430 glue won't idle reliably with the 200 ms autosuspend delay. This causes deeper idle states being blocked for the whole SoC when disconnecting OTG A cable. Increasing the delay to 500 ms seems to idle both MUSB and the PHY reliably. This is probably because of time needed by the hardware based negotiation between MUSB and the PHY. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_core.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit a60d541a2d402c8645d5bb2ec8dabe474b66e018 Author: Hans de Goede <hdegoede@redhat.com> Date: Tue May 31 10:05:08 2016 -0500 usb: musb: sunxi: Set state to A_WAIT_VRISE when enabling Vbus When the board is powering attached usb devices via the otg port sometimes / on some devices it takes slightly too long for the Vbus detection code in phy-sun4i-usb.c to signal that Vbus is high after enabling Vbus and the musb hardware signals a MUSB_INTR_VBUSERROR interrupt. This commit sets the otg state to A_WAIT_VRISE upon enabling Vbus making musb_stage0_irq() ignore the first VBUSERR_RETRY_COUNT VBUSERROR interrupts, fixing connection issues in these cases. Signed-off-by: Hans de Goede <hdegoede@redhat.com> [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/sunxi.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 37f30d887a41775066b78f8c0fa9a4929638db07 Author: Hans de Goede <hdegoede@redhat.com> Date: Tue May 31 10:05:07 2016 -0500 usb: musb: sunxi: Add set_mode platform function Move the mode handling to the platform_set_mode callback. Signed-off-by: Hans de Goede <hdegoede@redhat.com> [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/sunxi.c | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) commit b6a6631dc322b1ca187752a77bc5f74155017ecb Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Tue May 31 10:05:06 2016 -0500 usb: musb: host: make musb_tx_dma_set_mode_*() *void* Now that the DMA engine check was moved to musb_tx_dma_porgram(), both musb_tx_dma_set_mode_cppi_tusb() and musb_tx_dma_set_mode_mentor() always return 0, so we can make both these functions *void*. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 31 ++++++++++++------------------- 1 file changed, 12 insertions(+), 19 deletions(-) commit 858b9be7fda1d4232e8f06d70e4793bc21583ffc Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Tue May 31 10:05:05 2016 -0500 usb: musb: host: move DMA engine check from musb_tx_dma_set_mode_cppi_tusb() to its caller Commit 754fe4a92c07 ("usb: musb: Remove ifdefs for TX DMA for musb_host.c") looks incomplete: the DMA engine checks are done outside the Mentor/UX500 handler but inside the CPPI/TUSB handler. Move the checks out of the CPPI/ TUSB handler into its caller, musb_tx_dma_program(). Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> [b-liu@ti.com: revise subject prefix] Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit dbac5d07d13e330e6706813c9fde477140fb5d80 Author: Bin Liu <b-liu@ti.com> Date: Tue May 31 10:05:04 2016 -0500 usb: musb: host: don't start next rx urb if current one failed urb->status is set when endpoint csr RXSTALL, H_ERROR, DATAERROR or INCOMPRX bit is set. Those bits mean a broken pipe, so don't start next urb when any of these bits is set by checking urb->status. To minimize the risk of regression, only do so for RX, until we have a test case to understand the behavior of TX. The patch fixes system freeze issue caused by repeatedly invoking RX ISR while removing a usb uart device connected to a hub, in which case the hub has no chance to report the disconnect event due to the kernel is busy in processing the RX interrupt flooding. Fix checkpatch complaint (qh != NULL) as while. Reported-by: Max Uvarov <muvarov@gmail.com> Tested-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit b5801212229f6ca5c418c68cd1e0548f4b53f624 Author: Bin Liu <b-liu@ti.com> Date: Tue May 31 10:05:03 2016 -0500 usb: musb: host: clear rxcsr error bit if set The MUSB Programming Guide states that the driver should clear RXCSR bit2 when the controller sets the bit. Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/musb/musb_host.c | 3 +++ 1 file changed, 3 insertions(+) commit d95815ba6a0f287213118c136e64d8c56daeaeab Author: Hans de Goede <hdegoede@redhat.com> Date: Wed Jun 1 21:01:29 2016 +0200 USB: xhci: Add broken streams quirk for Frescologic device id 1009 I got one of these cards for testing uas with, it seems that with streams it dma-s all over the place, corrupting memory. On my first tests it managed to dma over the BIOS of the motherboard somehow and completely bricked it. Tests on another motherboard show that it does work with streams disabled. Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-pci.c | 5 +++++ 1 file changed, 5 insertions(+) commit b9610e74586fd183b2d1c7fe5316bce8b6cc534f Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed Jun 1 14:56:57 2016 -0700 clk: Remove CLK_IS_ROOT flag Now that we've gotten rid of all the users of this flag we can retire the number, leaving a slot open for a future flag user. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> include/linux/clk-provider.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 85e3990bea49a50cb389015fea564b58899ab7c1 Author: Alan Stern <stern@rowland.harvard.edu> Date: Thu May 19 16:29:50 2016 -0400 USB: EHCI: avoid undefined pointer arithmetic and placate UBSAN Several people have reported that UBSAN doesn't like the pointer arithmetic in ehci_hub_control(): u32 __iomem *status_reg = &ehci->regs->port_status[ (wIndex & 0xff) - 1]; u32 __iomem *hostpc_reg = &ehci->regs->hostpc[(wIndex & 0xff) - 1]; If wIndex is 0 (and it often is), these calculations underflow and UBSAN complains. According to the C standard, pointer computations leading to locations outside the bounds of an array object (other than 1 position past the end) are undefined. In this case, the compiler would be justified in concluding the wIndex can never be 0 and then optimizing away the tests for !wIndex that occur later in the subroutine. (Although, since ehci->regs->port_status and ehci->regs->hostpc are both 0-length arrays and are thus GCC extensions to the C standard, it's not clear what the compiler is really allowed to do.) At any rate, we can avoid all these difficulties, at the cost of making the code slightly longer, by not decrementing the index when it is equal to 0. The runtime effect is minimal, and anyway ehci_hub_control() is not on a hot path. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Reported-by: Valdis Kletnieks <Valdis.Kletnieks@vt.edu> Reported-by: Meelis Roos <mroos@linux.ee> Reported-by: Martin_MOKREJÅ <mmokrejs@gmail.com> Reported-by: "Navin P.S" <navinp1912@gmail.com> CC: Andrey Ryabinin <ryabinin.a.a@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/ehci-hub.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 593224ea77b1ca842f45cf76f4deeef44dfbacd1 Author: Hans de Goede <hdegoede@redhat.com> Date: Tue May 31 09:18:03 2016 +0200 USB: uas: Fix slave queue_depth not being set Commit 198de51dbc34 ("USB: uas: Limit qdepth at the scsi-host level") removed the scsi_change_queue_depth() call from uas_slave_configure() assuming that the slave would inherit the host's queue_depth, which that commit sets to the same value. This is incorrect, without the scsi_change_queue_depth() call the slave's queue_depth defaults to 1, introducing a performance regression. This commit restores the call, fixing the performance regression. Cc: stable@vger.kernel.org Fixes: 198de51dbc34 ("USB: uas: Limit qdepth at the scsi-host level") Reported-by: Tom Yan <tom.ty89@gmail.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/storage/uas.c | 1 + 1 file changed, 1 insertion(+) commit 5fc363232ae76805d7f570dbb61758095a540591 Author: Tom Yan <tom.ty89@gmail.com> Date: Tue May 24 03:28:44 2016 +0800 uas: remove can_queue set in host template Commit 198de51dbc34 ("USB: uas: Limit qdepth at the scsi-host level") made qdepth limit set in host template (`.can_queue = MAX_CMNDS`) redundant. Removing it to avoid confusion. Signed-off-by: Tom Yan <tom.ty89@gmail.com> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/storage/uas.c | 1 - 1 file changed, 1 deletion(-) commit 32cb0b37098f4beeff5ad9e325f11b42a6ede56c Author: Hans de Goede <hdegoede@redhat.com> Date: Thu May 19 17:12:20 2016 +0200 usb: quirks: Add no-lpm quirk for Acer C120 LED Projector The Acer C120 LED Projector is a USB-3 connected pico projector which takes both its power and video data from USB-3. In combination with some hubs this device does not play well with lpm, so disable lpm for it. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/quirks.c | 3 +++ 1 file changed, 3 insertions(+) commit 81099f97bd31e25ff2719a435b1860fc3876122f Author: Hans de Goede <hdegoede@redhat.com> Date: Thu May 19 17:12:19 2016 +0200 usb: quirks: Fix sorting Properly sort all the entries by vendor id. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/quirks.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 757de492f2d5711d4f5b386eb9bdd5cdc99eb30e Author: Mathias Nyman <mathias.nyman@linux.intel.com> Date: Wed Jun 1 18:09:10 2016 +0300 xhci: fix platform quirks overwrite regression in 4.7-rc1 commit b1c127ae990b ("usb: host: xhci: plat: make use of new methods in xhci_plat_priv") sets xhci->quirks before calling xhci_gen_setup(), which will overwrite them. Don't overwite the quirks, just add the new ones Fixes: b1c127ae990b ("usb: host: xhci: plat: make use of new methods in xhci_plat_priv") Reported-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Cc: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de95c40d5beaa47f6dc8fe9ac4159b4672b51523 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Wed Jun 1 18:09:09 2016 +0300 usb: xhci-plat: properly handle probe deferral for devm_clk_get() On some platforms, the clocks might be registered by a platform driver. When this is the case, the clock platform driver may very well be probed after xhci-plat, in which case the first probe() invocation of xhci-plat will receive -EPROBE_DEFER as the return value of devm_clk_get(). The current code handles that as a normal error, and simply assumes that this means that the system doesn't have a clock for the XHCI controller, and continues probing without calling clk_prepare_enable(). Unfortunately, this doesn't work on systems where the XHCI controller does have a clock, but that clock is provided by another platform driver. In order to fix this situation, we handle the -EPROBE_DEFER error condition specially, and abort the XHCI controller probe(). It will be retried later automatically, the clock will be available, devm_clk_get() will succeed, and the probe() will continue with the clock prepared and enabled as expected. In practice, such issue is seen on the ARM64 Marvell 7K/8K platform, where the clocks are registered by a platform driver. Cc: <stable@vger.kernel.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-plat.c | 3 +++ 1 file changed, 3 insertions(+) commit 3425aa03f484d45dc21e0e791c2f6c74ea656421 Author: Mathias Nyman <mathias.nyman@linux.intel.com> Date: Wed Jun 1 18:09:08 2016 +0300 xhci: Fix handling timeouted commands on hosts in weird states. If commands timeout we mark them for abortion, then stop the command ring, and turn the commands to no-ops and finally restart the command ring. If the host is working properly the no-op commands will finish and pending completions are called. If we notice the host is failing, driver clears the command ring and completes, deletes and frees all pending commands. There are two separate cases reported where host is believed to work properly but is not. In the first case we successfully stop the ring but no abort or stop command ring event is ever sent and host locks up. The second case is if a host is removed, command times out and driver believes the ring is stopped, and assumes it will be restarted, but actually ends up timing out on the same command forever. If one of the pending commands has the xhci->mutex held it will block xhci_stop() in the remove codepath which otherwise would cleanup pending commands. Add a check that clears all pending commands in case host is removed, or we are stuck timing out on the same command. Also restart the command timeout timer when stopping the command ring to ensure we recive an ring stop/abort event. Cc: stable <stable@vger.kernel.org> Tested-by: Joe Lawrence <joe.lawrence@stratus.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) commit 27a41a83ec54d0edfcaf079310244e7f013a7701 Author: Gabriel Krisman Bertazi <krisman@linux.vnet.ibm.com> Date: Wed Jun 1 18:09:07 2016 +0300 xhci: Cleanup only when releasing primary hcd Under stress occasions some TI devices might not return early when reading the status register during the quirk invocation of xhci_irq made by usb_hcd_pci_remove. This means that instead of returning, we end up handling this interruption in the middle of a shutdown. Since xhci->event_ring has already been freed in xhci_mem_cleanup, we end up accessing freed memory, causing the Oops below. commit 8c24d6d7b09d ("usb: xhci: stop everything on the first call to xhci_stop") is the one that changed the instant in which we clean up the event queue when stopping a device. Before, we didn't call xhci_mem_cleanup at the first time xhci_stop is executed (for the shared HCD), instead, we only did it after the invocation for the primary HCD, much later at the removal path. The code flow for this oops looks like this: xhci_pci_remove() usb_remove_hcd(xhci->shared) xhci_stop(xhci->shared) xhci_halt() xhci_mem_cleanup(xhci); // Free the event_queue usb_hcd_pci_remove(primary) xhci_irq() // Access the event_queue if STS_EINT is set. Crash. xhci_stop() xhci_halt() // return early The fix modifies xhci_stop to only cleanup the xhci data when releasing the primary HCD. This way, we still have the event_queue configured when invoking xhci_irq. We still halt the device on the first call to xhci_stop, though. I could reproduce this issue several times on the mainline kernel by doing a bind-unbind stress test with a specific storage gadget attached. I also ran the same test over-night with my patch applied and didn't observe the issue anymore. [ 113.334124] Unable to handle kernel paging request for data at address 0x00000028 [ 113.335514] Faulting instruction address: 0xd00000000d4f767c [ 113.336839] Oops: Kernel access of bad area, sig: 11 [#1] [ 113.338214] SMP NR_CPUS=1024 NUMA PowerNV [c000000efe47ba90] c000000000720850 usb_hcd_irq+0x50/0x80 [c000000efe47bac0] c00000000073d328 usb_hcd_pci_remove+0x68/0x1f0 [c000000efe47bb00] d00000000daf0128 xhci_pci_remove+0x78/0xb0 [xhci_pci] [c000000efe47bb30] c00000000055cf70 pci_device_remove+0x70/0x110 [c000000efe47bb70] c00000000061c6bc __device_release_driver+0xbc/0x190 [c000000efe47bba0] c00000000061c7d0 device_release_driver+0x40/0x70 [c000000efe47bbd0] c000000000619510 unbind_store+0x120/0x150 [c000000efe47bc20] c0000000006183c4 drv_attr_store+0x64/0xa0 [c000000efe47bc60] c00000000039f1d0 sysfs_kf_write+0x80/0xb0 [c000000efe47bca0] c00000000039e14c kernfs_fop_write+0x18c/0x1f0 [c000000efe47bcf0] c0000000002e962c __vfs_write+0x6c/0x190 [c000000efe47bd90] c0000000002eab40 vfs_write+0xc0/0x200 [c000000efe47bde0] c0000000002ec85c SyS_write+0x6c/0x110 [c000000efe47be30] c000000000009260 system_call+0x38/0x108 Signed-off-by: Gabriel Krisman Bertazi <krisman@linux.vnet.ibm.com> Cc: Roger Quadros <rogerq@ti.com> Cc: joel@jms.id.au Cc: stable@vger.kernel.org Reviewed-by: Roger Quadros <rogerq@ti.com> Cc: <stable@vger.kernel.org> #v4.3+ Tested-by: Joel Stanley <joel@jms.id.au> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 3 ++- drivers/usb/host/xhci.c | 27 +++++++++++++++------------ 2 files changed, 17 insertions(+), 13 deletions(-) commit 3c7f4f54578b983c964eb992229a7dd153ce5ee0 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed Jun 1 14:52:54 2016 -0700 clk: microchip: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Purna Chandra Mandal <purna.mandal@microchip.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: <linux-mips@linux-mips.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/microchip/clk-pic32mzda.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 3fb9c41286e594d52d23ca58404c69a7e2c39c41 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:31:12 2016 -0700 powerpc/512x: clk: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Gerhard Sittig <gsi@denx.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> arch/powerpc/platforms/512x/clock-commonclk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6399232feb64816b28e2a01ee874ace1a6975c99 Merge: 1a695a9 50c763f Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Wed Jun 1 14:49:12 2016 -0700 Merge tag 'fixes-for-v4.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-linus Felipe writes: Here's the first set of fixes for v4.7-rc cycle. Nothing extra fancy this time around. Patches range from MS OS Descriptor usage fixes, to Clear Stall EP command fix on dwc3, to some f_fs fixes and out of bounds accesses on renesas driver. commit b52fc2183f40170489692852fd66d8750cbaa324 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:36:55 2016 -0700 vexpress/spc: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Acked-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> arch/arm/mach-vexpress/spc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 540c26087bfbad6ea72758b76b16ae6282a73fea Author: Cameron Gutman <aicommander@gmail.com> Date: Wed Jun 1 11:32:51 2016 -0700 Input: xpad - fix rumble on Xbox One controllers with 2015 firmware Xbox One controllers that shipped with or were upgraded to the 2015 firmware discard the current rumble packets we send. This patch changes the Xbox One rumble packet to a form that both the newer and older firmware will accept. It is based on changes made to support newer Xbox One controllers in the SteamOS brewmaster-4.1 kernel branch. Signed-off-by: Cameron Gutman <aicommander@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/joystick/xpad.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit a9bf7d60c273763d3f0f4f991bd96fbc411bfd73 Merge: d3922b6 2ea9f31 Author: Dave Airlie <airlied@redhat.com> Date: Thu Jun 2 06:57:20 2016 +1000 Merge tag 'mediatek-drm-fixes-2016-06-01' of git://git.pengutronix.de/git/pza/linux into drm-fixes mediatek-drm fixes - remove an invalid, unreachable error message and NULL pointer dereference - remove a spurious drm_connector_unregister call from the DSI driver * tag 'mediatek-drm-fixes-2016-06-01' of git://git.pengutronix.de/git/pza/linux: drm/mediatek: mtk_dsi: Remove spurious drm_connector_unregister drm/mediatek: mtk_dpi: remove invalid error message commit 7f9bef9debafcb767d00efb177d0f2edd4940eab Author: Lv Zheng <lv.zheng@intel.com> Date: Wed Jun 1 11:03:20 2016 +0800 ACPICA / Hardware: Fix old register check in acpi_hw_get_access_bit_width() The address check in acpi_hw_get_access_bit_width() should be byte width based, not bit width based. This patch fixes this mistake. For those who want to review acpi_hw_access_bit_width(), here is the concerns and the design details of the function: It is supposed that the GAS Address field should be aligned to the byte width indicated by the GAS AccessSize field. Similarly, for the old non GAS register, it is supposed that its Address should be aligned to its Length. For the "AccessSize = 0 (meaning ANY)" case, we try to return the maximum instruction width (64 for MMIO or 32 for PIO) or the user expected access bit width (64 for acpi_read()/acpi_write() or 32 for acpi_hw_read()/ acpi_hw_write()) and it is supposed that the GAS Address field should always be aligned to the maximum expected access bit width (otherwise it can't be accessed using ANY access bit width). The problem is in acpi_tb_init_generic_address(), where the non GAS register's Length is converted into the GAS BitWidth field, its Address is converted into the GAS Address field, and the GAS AccessSize field is left 0 but most of the registers actually cannot be accessed using "ANY" accesses. As a conclusion, when AccessSize = 0 (ANY), the Address should either be aligned to the BitWidth (wrong conversion) or aligned to 32 for PIO or 64 for MMIO (real GAS). Since currently, max_bit_width is 32, then: 1. BitWidth for the wrong conversion is 8,16,32; and 2. The Address of the real GAS should always be aligned to 8,16,32. The address alignment check to exclude false matched real GAS is not necessary. Thus this patch fixes the issue by removing the address alignment check. On the other hand, we in fact could use a simpler check of "reg->bit_width < max_bit_width" to exclude the "BitWidth=64 PIO" case that may be issued from acpi_read()/acpi_write() in the future. Fixes: b314a172ee96 (ACPICA: Hardware: Add optimized access bit width support) Reported-and-tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Acked-by: Mike Marshall <hubcap@omnibond.com> Suggested-by: Jan Beulich <jbeulich@suse.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/hwregs.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) commit b9af694802b40d50852f1949ec94d4dcc43d7355 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed Jun 1 22:36:26 2016 +0200 cpufreq: Fix clamp_val() usage in cpufreq_driver_fast_switch() The return value of clamp_val() has to be stored actually. Fixes: b7898fda5bc7 (cpufreq: Support for fast frequency switching) Reported-by: Steve Muckle <steve.muckle@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 719af93ab78eaaccdb2fa727268da6b477804bfb Merge: ebb8cb2 5edf673 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed Jun 1 12:38:50 2016 -0700 Merge tag 'pinctrl-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Pull pin control fixes from Linus Walleij: "Here are three pin control fixes for v4.7. Not much, and just driver fixes: - add device tree matches to MAINTAINERS - inversion bug in the Nomadik driver - dual edge handling bug in the mediatek driver" * tag 'pinctrl-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: pinctrl: mediatek: fix dual-edge code defect MAINTAINERS: Add file patterns for pinctrl device tree bindings pinctrl: nomadik: fix inversion of gpio direction commit ebb8cb2bae0344ef45cc173cdf5402ec91198abd Merge: 6b15d66 b02da6f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed Jun 1 12:32:25 2016 -0700 Merge tag 'dma-buf-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sumits/dma-buf Pull dma-buf updates from Sumit Semwal: - use of vma_pages instead of explicit computation - DocBook and headerdoc updates for dma-buf * tag 'dma-buf-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sumits/dma-buf: dma-buf: use vma_pages() fence: add missing descriptions for fence doc: update/fixup dma-buf related DocBook reservation: add headerdoc comments dma-buf: headerdoc fixes commit dfc2507b26af22b0bbc85251b8545b36d8bc5d72 Author: John Stultz <john.stultz@linaro.org> Date: Wed Jun 1 11:53:26 2016 -0700 time: Make settimeofday error checking work again In commit 86d3473224b0 some of the checking for a valid timeval was subtley changed which caused -EINVAL to be returned whenever the timeval was null. However, it is possible to set the timezone data while specifying a NULL timeval, which is usually done to handle systems where the RTC keeps local time instead of UTC. Thus the patch causes such systems to have the time incorrectly set. This patch addresses the issue by handling the error conditionals in the same way as was done previously. Fixes: 86d3473224b0 "time: Introduce do_sys_settimeofday64()" Reported-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Baolin Wang <baolin.wang@linaro.org> Cc: Richard Cochran <richardcochran@gmail.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Link: http://lkml.kernel.org/r/1464807207-16530-2-git-send-email-john.stultz@linaro.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/timekeeping.h | 3 +++ 1 file changed, 3 insertions(+) commit 10fdf8513f776c8b2588bb7b924fb243ae2462d6 Author: Will Deacon <will.deacon@arm.com> Date: Wed Jun 1 18:48:20 2016 +0100 arm64: unistd32.h: wire up missing syscalls for compat tasks We're missing entries for mlock2, copy_file_range, preadv2 and pwritev2 in our compat syscall table, so hook them up. Only the last two need compat wrappers. Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/unistd.h | 2 +- arch/arm64/include/asm/unistd32.h | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) commit 5a5e78cd706ce0577ed6356634a34552c866cc10 Author: Caesar Wang <wxt@rock-chips.com> Date: Wed May 18 23:01:39 2016 +0800 thermal: add the note for set_trip_temp Fixes commit 60f9ce3ada53 ("thermal: of-thermal: allow setting trip_temp on hardware") Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: linux-pm@vger.kernel.org Signed-off-by: Zhang Rui <rui.zhang@intel.com> include/linux/thermal.h | 2 ++ 1 file changed, 2 insertions(+) commit f840ab18bdf2e415dac21d09fbbbd2873111bd48 Author: Lukasz Luba <lukasz.luba@arm.com> Date: Tue May 31 11:32:02 2016 +0100 thermal: cpu_cooling: fix improper order during initialization The freq_table array is not populated before calling thermal_of_cooling_register. The code which populates the freq table was introduced in commit f6859014. This should be done before registering new thermal cooling device. The log shows effects of this wrong decision. [ 2.172614] cpu cpu1: Failed to get voltage for frequency 1984518656000: -34 [ 2.220863] cpu cpu0: Failed to get voltage for frequency 1984524416000: -34 Cc: <stable@vger.kernel.org> # 3.19+ Fixes: f6859014c7e7 ("thermal: cpu_cooling: Store frequencies in descending order") Signed-off-by: Lukasz Luba <lukasz.luba@arm.com> Acked-by: Javi Merino <javi.merino@arm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Zhang Rui <rui.zhang@intel.com> drivers/thermal/cpu_cooling.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 2ea9f31799adce35d8c9a0bb3bc1d2b515702c6f Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Thu May 26 16:08:18 2016 +0200 drm/mediatek: mtk_dsi: Remove spurious drm_connector_unregister Connectors are unregistered by mtk_drm_drv via drm_connector_unregister_all(). Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/mediatek/mtk_dsi.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 515ba6a59cbab44c989f25b2518b82491deb832e Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Thu May 26 17:19:39 2016 +0200 drm/mediatek: mtk_dpi: remove invalid error message Do not try to dereference dpi if it is NULL. Since dpi can never be NULL when mtk_dpi_set_display_mode() is called, remove the message. Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/mediatek/mtk_dpi.c | 5 ----- 1 file changed, 5 deletions(-) commit a80e803a2ae4efa5efbcfa97dcbbc48d15226cf9 Author: Benjamin Tissoires <benjamin.tissoires@redhat.com> Date: Tue May 31 17:31:15 2016 +0200 HID: multitouch: Add MT_QUIRK_NOT_SEEN_MEANS_UP to Surface Pro 3 The firmware found in the touch screen of an SP3 is buggy and may miss to send lift off reports for contacts. Try to work around that issue by using MT_QUIRK_NOT_SEEN_MEANS_UP. based on a patch from: Daniel Martin <consume.noise@gmail.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-multitouch.c | 5 +++++ 1 file changed, 5 insertions(+) commit 58a2ab3af722550b2e4e8155eb08660e16c20ee6 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Apr 25 12:04:54 2016 +0300 drm: atmel-hlcdc: fix a NULL check If kmalloc() returned NULL we would end up dereferencing "state" a couple lines later. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit c2e4c99444f418b3c3b13b58dad4d951aa2f7f1b Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 22 21:28:32 2016 +0200 drm: atmel-hlcdc: fix atmel_hlcdc_crtc_reset() implementation Reset crtc->state to NULL after freeing the state object and call __drm_atomic_helper_crtc_destroy_state() helper instead of manually calling drm_property_unreference_blob(). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit ed596a4a88bd161f868ccba078557ee7ede8a6ef Author: Oliver Neukum <oneukum@suse.com> Date: Tue May 31 14:48:15 2016 +0200 HID: elo: kill not flush the work Flushing a work that reschedules itself is not a sensible operation. It needs to be killed. Failure to do so leads to a kernel panic in the timer code. CC: stable@vger.kernel.org Signed-off-by: Oliver Neukum <ONeukum@suse.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-elo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6973c09490c919398fc87d9c6bec9c0b670c4c4 Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 20 16:57:29 2016 +0800 ceph: use i_version to check validity of fscache Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/cache.c | 3 +++ 1 file changed, 3 insertions(+) commit f7f7e7a0635dedd5064fba255cb3facfa87b06d6 Author: Yan, Zheng <zyan@redhat.com> Date: Wed May 18 20:31:55 2016 +0800 ceph: improve fscache revalidation There are several issues in fscache revalidation code. - In ceph_revalidate_work(), fscache_invalidate() is called when fscache_check_consistency() return 0. This is complete wrong because 0 means cache is valid. - Handle_cap_grant() calls ceph_queue_revalidate() if client already has CAP_FILE_CACHE. This code is confusing. Client should revalidate the cache each time it got CAP_FILE_CACHE anew. - In Handle_cap_grant(), fscache_invalidate() is called if MDS revokes CAP_FILE_CACHE. This is inconsistency with the case that inode get evicted. In the later case, the cache is not discarded. Client may use the cache when inode is reloaded. This patch moves the fscache revalidation into ceph_get_caps(). Client revalidates the cache after it gets CAP_FILE_CACHE. i_rdcache_gen should keep constance while CAP_FILE_CACHE is used. If i_fscache_gen is not equal to i_rdcache_gen, client needs to check cache's consistency. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/cache.c | 84 ++++++++++++--------------------------------------------- fs/ceph/cache.h | 20 +++++++++++--- fs/ceph/caps.c | 16 +++++------ fs/ceph/super.h | 4 +-- 4 files changed, 41 insertions(+), 83 deletions(-) commit 46b59b2be05a71d80d76883d2f495f182d768f47 Author: Yan, Zheng <zyan@redhat.com> Date: Wed May 18 15:25:03 2016 +0800 ceph: disable fscache when inode is opened for write All other filesystems do not add dirty pages to fscache. They all disable fscache when inode is opened for write. Only ceph adds dirty pages to fscache, but the code is buggy. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 2 -- fs/ceph/cache.c | 54 ++++++++++++++++++++++++++++++++++++++---------------- fs/ceph/cache.h | 30 ++++++++++++------------------ fs/ceph/file.c | 19 ++----------------- 4 files changed, 52 insertions(+), 53 deletions(-) commit 1464975816c79a7cd28dc314384f060a122a9d55 Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 20 15:41:20 2016 +0800 ceph: avoid unnecessary fscache invalidation/revlidation ceph_fill_file_size() has already called ceph_fscache_invalidate() if it return true. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/caps.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 368e35857dfab264f512d040c4486c9b13297988 Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 17 11:58:02 2016 +0800 ceph: call __fscache_uncache_page() if readpages fails If readpages fails, fscache needs to cleanup its internal state. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 480ce08a70e4179f34808a3bdbfe6627f624cf54 Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 20 18:32:31 2016 +0800 FS-Cache: make check_consistency callback return int __fscache_check_consistency() calls check_consistency() callback and return the callback's return value. But the return type of check_consistency() is bool. So __fscache_check_consistency() return 1 if the cache is inconsistent. This is inconsistent with the document. Signed-off-by: Yan, Zheng <zyan@redhat.com> Acked-by: David Howells <dhowells@redhat.com> fs/cachefiles/interface.c | 2 +- include/linux/fscache-cache.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit d2138455286f9db8fbff9b50b53b51766f6c1f92 Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 17 11:52:48 2016 +0800 FS-Cache: wake write waiter after invalidating writes Signed-off-by: Yan, Zheng <zyan@redhat.com> Acked-by: David Howells <dhowells@redhat.com> fs/fscache/page.c | 2 ++ 1 file changed, 2 insertions(+) commit 50c763f8c1bac0dc00f7788a75f227276c0efd54 Author: John Youn <johnyoun@synopsys.com> Date: Tue May 31 17:49:56 2016 -0700 usb: dwc3: Set the ClearPendIN bit on Clear Stall EP command As of core revision 2.60a the recommended programming model is to set the ClearPendIN bit when issuing a Clear Stall EP command for IN endpoints. This is to prevent an issue where some (non-compliant) hosts may not send ACK TPs for pending IN transfers due to a mishandled error condition. Synopsys STAR 9000614252. Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 1 + drivers/usb/dwc3/gadget.c | 30 ++++++++++++++++++++++++------ 2 files changed, 25 insertions(+), 6 deletions(-) commit 6b15d6650c5301ce023d8df0cc3a60b1a76d377e Merge: 58c1f99 faf8dcc Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 31 22:28:28 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes from David Miller: 1) Fix negative error code usage in ATM layer, from Stefan Hajnoczi. 2) If CONFIG_SYSCTL is disabled, the default TTL is not initialized properly. From Ezequiel Garcia. 3) Missing spinlock init in mvneta driver, from Gregory CLEMENT. 4) Missing unlocks in hwmb error paths, also from Gregory CLEMENT. 5) Fix deadlock on team->lock when propagating features, from Ivan Vecera. 6) Work around buffer offset hw bug in alx chips, from Feng Tang. 7) Fix double listing of SCTP entries in sctp_diag dumps, from Xin Long. 8) Various statistics bug fixes in mlx4 from Eric Dumazet. 9) Fix some randconfig build errors wrt fou ipv6 from Arnd Bergmann. 10) All of l2tp was namespace aware, but the ipv6 support code was not doing so. From Shmulik Ladkani. 11) Handle on-stack hrtimers properly in pktgen, from Guenter Roeck. 12) Propagate MAC changes properly through VLAN devices, from Mike Manning. 13) Fix memory leak in bnx2x_init_one(), from Vitaly Kuznetsov. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (62 commits) sfc: Track RPS flow IDs per channel instead of per function usbnet: smsc95xx: fix link detection for disabled autonegotiation virtio_net: fix virtnet_open and virtnet_probe competing for try_fill_recv bnx2x: avoid leaking memory on bnx2x_init_one() failures fou: fix IPv6 Kconfig options openvswitch: update checksum in {push,pop}_mpls sctp: sctp_diag should dump sctp socket type net: fec: update dirty_tx even if no skb vlan: Propagate MAC address to VLANs atm: iphase: off by one in rx_pkt() atm: firestream: add more reserved strings vxlan: Accept user specified MTU value when create new vxlan link net: pktgen: Call destroy_hrtimer_on_stack() timer: Export destroy_hrtimer_on_stack() net: l2tp: Make l2tp_ip6 namespace aware Documentation: ip-sysctl.txt: clarify secure_redirects sfc: use flow dissector helpers for aRFS ieee802154: fix logic error in ieee802154_llsec_parse_dev_addr net: nps_enet: Disable interrupts before napi reschedule net/lapb: tuse %*ph to dump buffers ... commit d3922b69617b62bb2509936b68301f837229d9f0 Author: Mathieu Larouche <mathieu.larouche@matrox.com> Date: Fri May 27 15:12:50 2016 -0400 drm/mgag200: Black screen fix for G200e rev 4 - Fixed black screen for some resolutions of G200e rev4 - Fixed testm & testn which had predetermined value. Reported-by: Jan Beulich <jbeulich@suse.com> Signed-off-by: Mathieu Larouche <mathieu.larouche@matrox.com> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/mgag200/mgag200_mode.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 58c1f9950ffc6acbb907051b0a4e56aaf4baa9ce Merge: 367d3fd 7cafc0b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 31 22:20:56 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc Pull sparc fixes from David Miller: "sparc64 mmu context allocation and trap return bug fixes" * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc: sparc64: Fix return from trap window fill crashes. sparc: Harden signal return frame checks. sparc64: Take ctx_alloc_lock properly in hugetlb_setup(). commit afe705be38f1e65b173868486944377186b9f206 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue May 31 22:25:52 2016 +0100 drm: Wrap direct calls to driver->gem_free_object from CMA Since the introduction of (struct_mutex) lockless GEM bo freeing, there are a pair of driver vfuncs for freeing the GEM bo, of which the driver may choose to only implement driver->gem_object_free_unlocked (and so avoid taking the struct_mutex along the free path). However, the CMA GEM helpers were still calling driver->gem_free_object directly, now NULL, and promptly dying on the fancy new lockless drivers. Oops. Robert Foss bisected this to b82caafcf2303 (drm/vc4: Use lockless gem BO free callback) on his vc4 device, but that just serves as an enabler for 9f0ba539d13ae (drm/gem: support BO freeing without dev->struct_mutex). Reported-by: Robert Foss <robert.foss@collabora.com> Fixes: 9f0ba539d13ae (drm/gem: support BO freeing without dev->struct_mutex) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Robert Foss <robert.foss@collabora.com> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Eric Anholt <eric@anholt.net> Cc: Alex Deucher <alexdeucher@gmail.com> Cc: Lucas Stach <l.stach@pengutronix.de> Cc: stable@vger.kernel.org Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Tested-by: Robert Foss <robert.foss@collabora.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_fb_cma_helper.c | 2 +- drivers/gpu/drm/drm_gem_cma_helper.c | 12 +++--------- 2 files changed, 4 insertions(+), 10 deletions(-) commit 1e8985a835fdffc99f823c25ace54833656c505a Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Tue May 31 15:03:18 2016 +0300 drm: fix fb refcount issue with atomic modesetting After commit 027b3f8ba9277410c3191d72d1ed2c6146d8a668 ("drm/modes: stop handling framebuffer special") extra fb refs are left around when doing atomic modesetting. The problem is that the new drm_property_change_valid_get() does not return anything in the '**ref' parameter, which causes drm_property_change_valid_put() to do nothing. For some reason this doesn't cause problems with legacy API. Also, previously the code only set the 'ref' variable for fbs, with this patch the 'ref' is set for all objects. Fixes: 027b3f8ba927 ("drm/modes: stop handling framebuffer special") Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6709887c448d1cff51b52d09763c7b834ea5f0be Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Tue May 31 15:03:17 2016 +0300 drm: make drm_atomic_set_mode_prop_for_crtc() more reliable drm_atomic_set_mode_prop_for_crtc() does not clear the state->mode, so old data may be left there when a new mode is set, possibly causing odd issues. This patch improves the situation by always clearing the state->mode first. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: stable@vger.kernel.org Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_atomic.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 84e5a795228980adc6bd737765964d7afba7017e Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Tue May 31 15:03:16 2016 +0300 drm/sti: remove extra mode fixup Commit 652353e6e561c2aeeac62df183f721f6f9b5b45f ("drm/sti: set CRTC modesetting parameters") added a hack to avoid warnings related to setting mode with atomic API. With the previous patch, the hack should no longer be necessary. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org> Cc: Vincent Abriou <vincent.abriou@st.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/sti/sti_crtc.c | 10 ---------- 1 file changed, 10 deletions(-) commit b201e743f42d143f4bcdcb14587caf7cb1d99229 Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Tue May 31 15:03:15 2016 +0300 drm: add missing drm_mode_set_crtcinfo call When setting mode via MODE_ID property, drm_atomic_set_mode_prop_for_crtc() does not call drm_mode_set_crtcinfo() which possibly causes: "[drm:drm_calc_timestamping_constants [drm]] *ERROR* crtc 32: Can't calculate constants, dotclock = 0!" Whether the error is seen depends on the previous data in state->mode, as state->mode is not cleared when setting new mode. This patch adds drm_mode_set_crtcinfo() call to drm_mode_convert_umode(), which is called in both legacy and atomic paths. This should be fine as there's no reason to call drm_mode_convert_umode() without also setting the crtc related fields. drm_mode_set_crtcinfo() is removed from the legacy drm_mode_setcrtc() as that is no longer needed. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 2 -- drivers/gpu/drm/drm_modes.c | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) commit 7cc851039d643a2ee7df4d18177150f2c3a484f5 Author: Thomas Huth <thuth@redhat.com> Date: Tue May 31 07:51:17 2016 +0200 powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call If we do not provide the PVR for POWER8NVL, a guest on this system currently ends up in PowerISA 2.06 compatibility mode on KVM, since QEMU does not provide a generic PowerISA 2.07 mode yet. So some new instructions from POWER8 (like "mtvsrd") get disabled for the guest, resulting in crashes when using code compiled explicitly for POWER8 (e.g. with the "-mcpu=power8" option of GCC). Fixes: ddee09c099c3 ("powerpc: Add PVR for POWER8NVL processor") Cc: stable@vger.kernel.org # v4.0+ Signed-off-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/prom_init.c | 1 + 1 file changed, 1 insertion(+) commit 157d4d0620879b7d89ca1e3cd7bf0be1e29be198 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Tue May 31 11:56:31 2016 +0530 powerpc/mm/radix: Add missing tlb flush This should not have any impact on hash, because hash does tlb invalidate with every pte update and we don't implement flush_tlb_* functions for hash. With radix we should make an explicit call to flush tlb outside pte update. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/pgtable-book3s64.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit dc47c0c1f8099fccb2c1e2f3775855066a9e4484 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Tue May 31 11:56:30 2016 +0530 powerpc/mm/hash: Fix the reference bit update when handling hash fault When we converted the asm routines to C functions, we missed updating HPTE_R_R based on _PAGE_ACCESSED. ASM code used to copy over the lower bits from pte via. andi. r3,r30,0x1fe /* Get basic set of flags */ We also update the code such that we won't update the Change bit ('C' bit) always. This was added by commit c5cf0e30bf3d8 ("powerpc: Fix buglet with MMU hash management"). With hash64, we need to make sure that hardware doesn't do a pte update directly. This is because we do end up with entries in TLB with no hash page table entry. This happens because when we find a hash bucket full, we "evict" a more/less random entry from it. When we do that we don't invalidate the TLB (hpte_remove) because we assume the old translation is still technically "valid". For more info look at commit 0608d692463("powerpc/mm: Always invalidate tlb on hpte invalidate and update"). Thus it's critical that valid hash PTEs always have reference bit set and writeable ones have change bit set. We do this by hashing a non-dirty linux PTE as read-only and always setting _PAGE_ACCESSED (and thus R) when hashing anything else in. Any attempt by Linux at clearing those bits also removes the corresponding hash entry. Commit 5cf0e30bf3d8 did that for 'C' bit by enabling 'C' bit always. We don't really need to do that because we never map a RW pte entry without setting 'C' bit. On READ fault on a RW pte entry, we still map it READ only, hence a store update in the page will still cause a hash pte fault. This patch reverts the part of commit c5cf0e30bf3d8 ("[PATCH] powerpc: Fix buglet with MMU hash management") and retain the updatepp part. - If we hit the updatepp path on native, the old code without that commit, would fail to set C bcause native_hpte_updatepp() was implemented to filter the same bits as H_PROTECT and not let C through thus we would "upgrade" a RO HPTE to RW without setting C thus causing the bug. So the real fix in that commit was the change to native_hpte_updatepp Fixes: 89ff725051d1 ("powerpc/mm: Convert __hash_page_64K to C") Cc: stable@vger.kernel.org # v4.5+ Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hash_utils_64.c | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) commit d6c886006c948141f24e84acebfb757d3200f20c Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Tue May 31 11:56:29 2016 +0530 powerpc/mm/radix: Update LPCR only if it is powernv LPCR cannot be updated when running in guest mode. Fixes: 2bfd65e45e87 ("powerpc/mm/radix: Add radix callbacks for early init routines") Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/pgtable-radix.c | 23 ++++++++++------------- 1 file changed, 10 insertions(+), 13 deletions(-) commit faf8dcc12c2780bfec61eb95e5ad74af2ff4f82f Author: Jon Cooper <jcooper@solarflare.com> Date: Tue May 31 19:12:32 2016 +0100 sfc: Track RPS flow IDs per channel instead of per function Otherwise we get confused when two flows on different channels get the same flow ID. Signed-off-by: Edward Cree <ecree@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/sfc/efx.c | 32 +++++++++++++++++++++++++++----- drivers/net/ethernet/sfc/net_driver.h | 12 ++++++++---- drivers/net/ethernet/sfc/rx.c | 29 +++++++++++++++++++++-------- 3 files changed, 56 insertions(+), 17 deletions(-) commit ce7585f3c4d76bca1dff4b66ae1ea32552954f9e Author: Alex Williamson <alex.williamson@redhat.com> Date: Tue May 31 21:25:52 2016 -0600 vfio/pci: Allow VPD short read The size of the VPD area is not necessarily 4-byte aligned, so a pci_vpd_read() might return less than 4 bytes. Zero our buffer and accept anything other than an error. Intel X710 NICs exercise this. Fixes: 4e1a635552d3 ("vfio/pci: Use kernel VPD access functions") Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/pci/vfio_pci_config.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit fbd83006e3e536fcb103228d2422ea63129ccb03 Author: Ewan D. Milne <emilne@redhat.com> Date: Tue May 31 09:42:29 2016 -0400 scsi: Add QEMU CD-ROM to VPD Inquiry Blacklist Linux fails to boot as a guest with a QEMU CD-ROM: [ 4.439488] ata2.00: ATAPI: QEMU CD-ROM, 0.8.2, max UDMA/100 [ 4.443649] ata2.00: configured for MWDMA2 [ 4.450267] scsi 1:0:0:0: CD-ROM QEMU QEMU CD-ROM 0.8. PQ: 0 ANSI: 5 [ 4.464317] ata2.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen [ 4.464319] ata2.00: BMDMA stat 0x5 [ 4.464339] ata2.00: cmd a0/01:00:00:00:01/00:00:00:00:00/a0 tag 0 dma 16640 in [ 4.464339] Inquiry 12 01 00 00 ff 00res 48/20:02:00:24:00/00:00:00:00:00/a0 Emask 0x2 (HSM violation) [ 4.464341] ata2.00: status: { DRDY DRQ } [ 4.465864] ata2: soft resetting link [ 4.625971] ata2.00: configured for MWDMA2 [ 4.628290] ata2: EH complete [ 4.646670] ata2.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen [ 4.646671] ata2.00: BMDMA stat 0x5 [ 4.646683] ata2.00: cmd a0/01:00:00:00:01/00:00:00:00:00/a0 tag 0 dma 16640 in [ 4.646683] Inquiry 12 01 00 00 ff 00res 48/20:02:00:24:00/00:00:00:00:00/a0 Emask 0x2 (HSM violation) [ 4.646685] ata2.00: status: { DRDY DRQ } [ 4.648193] ata2: soft resetting link ... Fix this by suppressing VPD inquiry for this device. Signed-off-by: Ewan D. Milne <emilne@redhat.com> Reported-by: Jan Stancek <jstancek@redhat.com> Tested-by: Jan Stancek <jstancek@redhat.com> Cc: <stable@vger.kernel.org> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_devinfo.c | 1 + 1 file changed, 1 insertion(+) commit 65d4f4c151a5fa7b2dacaaf70def3f95001766d7 Author: Josef Bacik <jbacik@fb.com> Date: Wed Sep 23 15:00:37 2015 -0400 Btrfs: end transaction if we abort when creating uuid root We still need to call btrfs_end_transaction if we call btrfs_abort_transaction, otherwise we hang and make me super grumpy. Thanks, Signed-off-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 1 + 1 file changed, 1 insertion(+) commit e7c31f6f25b84fed961dc0dce6248878527693ae Author: Robert Foss <robert.foss@collabora.com> Date: Tue May 3 13:48:20 2016 -0400 drm/vc4: Return -EBUSY if there's already a pending flip event. As per the documentation in drm_crtc.h, atomic_commit should return -EBUSY if an asynchronous update is requested and there is an earlier update pending. v2: Rebase on the s/async/nonblock/ change. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/gpu/drm/vc4/vc4_kms.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit ee7c10e10b632e2319ed1d2d49d63df51a611e62 Author: Mario Kleiner <mario.kleiner.de@gmail.com> Date: Fri May 6 19:26:06 2016 +0200 drm/vc4: Fix drm_vblank_put/get imbalance in page flip path. The async page flip path was missing drm_crtc_vblank_get/put completely. The sync flip path was missing a vblank put, so async flips only reported proper pageflip completion events by chance, and vblank irq's never turned off after a first vsync'ed page flip until system reboot. Tested against Raspian kernel 4.4.8 tree on RPi 2B. Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net> Fixes: b501bacc6060 ("drm/vc4: Add support for async pageflips.") drivers/gpu/drm/vc4/vc4_crtc.c | 4 ++++ 1 file changed, 4 insertions(+) commit 792293cfd516a173bbd687b4b26da0f97f97abd2 Author: Mario Kleiner <mario.kleiner.de@gmail.com> Date: Fri May 6 19:26:05 2016 +0200 drm/vc4: Fix get_vblank_counter with proper no-op for Linux 4.4+ get_vblank_counter hooked up to drm_vblank_count() which alway was non-sensical but didn't hurt in the past. Since Linux 4.4 it triggers a WARN_ON_ONCE in drm_update_vblank_count on first vblank irq disable, so fix it by hooking to drm_vblank_no_hw_counter(). Tested against Raspian kernel 4.4.8 tree on RPi 2B. Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net> Fixes: c8b75bca92cb ("drm/vc4: Add KMS support for Raspberry Pi.") drivers/gpu/drm/vc4/vc4_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d69d169493463e6b1da9a1965d35126e479aa27f Author: Christoph Fritz <chf.fritz@googlemail.com> Date: Thu May 26 04:06:47 2016 +0200 usbnet: smsc95xx: fix link detection for disabled autonegotiation To detect link status up/down for connections where autonegotiation is explicitly disabled, we don't get an irq but need to poll the status register for link up/down detection. This patch adds a workqueue to poll for link status. Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/smsc95xx.c | 51 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) commit f00e35e259948b995aa1f3ee7fddb05f34a50157 Author: wangyunjian <wangyunjian@huawei.com> Date: Tue May 31 11:52:43 2016 +0800 virtio_net: fix virtnet_open and virtnet_probe competing for try_fill_recv In function virtnet_open() and virtnet_probe(), func try_fill_recv() may be executed at the same time. VQ in virtqueue_add() has not been protected well and BUG_ON will be triggered when virito_net.ko being removed. Signed-off-by: Yunjian Wang <wangyunjian@huawei.com> Acked-by: Jason Wang <jasowang@redhat.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/virtio_net.c | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) commit bae5499cc55d2329ea0fbf09cb22298f4ca2f9bd Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Mon May 30 15:00:54 2016 +0200 bnx2x: avoid leaking memory on bnx2x_init_one() failures bnx2x_init_bp() allocates memory with bnx2x_alloc_mem_bp() so if we fail later in bnx2x_init_one() we need to free this memory with bnx2x_free_mem_bp() to avoid leakages. E.g. I'm observing memory leaks reported by kmemleak when a failure (unrelated) happens in bnx2x_vfpf_acquire(). Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 95e4daa82086e2bd7b7163f33a4f455bf8ecdf48 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 31 22:42:11 2016 +0200 fou: fix IPv6 Kconfig options The Kconfig options I added to work around broken compilation ended up screwing up things more, as I used the wrong symbol to control compilation of the file, resulting in IPv6 fou support to never be built into the kernel. Changing CONFIG_NET_FOU_IPV6_TUNNELS to CONFIG_IPV6_FOU fixes that problem, I had renamed the symbol in one location but not the other, and as the file is never being used by other kernel code, this did not lead to a build failure that I would have caught. After that fix, another issue with the same patch becomes obvious, as we 'select INET6_TUNNEL', which is related to IPV6_TUNNEL, but not the same, and this can still cause the original build failure when IPV6_TUNNEL is not built-in but IPV6_FOU is. The fix is equally trivial, we just need to select the right symbol. I have successfully build 350 randconfig kernels with this patch and verified that the driver is now being built. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reported-by: Valentin Rothberg <valentinrothberg@gmail.com> Fixes: fabb13db448e ("fou: add Kconfig options for IPv6 support") Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/Kconfig | 2 +- net/ipv6/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit bc7cc5999fd392cc799630d7e375b2f4e29cc398 Author: Simon Horman <simon.horman@netronome.com> Date: Mon May 30 14:04:25 2016 +0900 openvswitch: update checksum in {push,pop}_mpls In the case of CHECKSUM_COMPLETE the skb checksum should be updated in {push,pop}_mpls() as they the type in the ethernet header. As suggested by Pravin Shelar. Cc: Pravin Shelar <pshelar@nicira.com> Fixes: 25cd9ba0abc0 ("openvswitch: Add basic MPLS support to kernel") Signed-off-by: Simon Horman <simon.horman@netronome.com> Acked-by: Pravin B Shelar <pshelar@ovn.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/openvswitch/actions.c | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) commit becc7ae544c61395b5eba7b9913e14aa567ca07a Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:06:06 2016 +0200 MAINTAINERS: Add file patterns for mtd device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: David Woodhouse <dwmw2@infradead.org> Cc: linux-mtd@lists.infradead.org Signed-off-by: Brian Norris <computersforpeace@gmail.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 40eb90e9ccc3f96f937ea1db79d0f9cb61553ed5 Author: Xin Long <lucien.xin@gmail.com> Date: Sun May 29 17:42:13 2016 +0800 sctp: sctp_diag should dump sctp socket type Now we cannot distinguish that one sk is a udp or sctp style when we use ss to dump sctp_info. it's necessary to dump it as well. For sctp_diag, ss support is not officially available, thus there are no official users of this yet, so we can add this field in the middle of sctp_info without breaking user API. v1->v2: - move 'sctpi_s_type' field to the end of struct sctp_info, so that it won't cause incompatibility with applications already built. - add __reserved3 in sctp_info to make sure sctp_info is 8-byte alignment. Signed-off-by: Xin Long <lucien.xin@gmail.com> Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Acked-by: Neil Horman <nhorman@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/sctp.h | 2 ++ net/sctp/socket.c | 1 + 2 files changed, 3 insertions(+) commit 7fafe803749a0c238feb5d38cb4ddee53eca5aa0 Author: Troy Kisky <troy.kisky@boundarydevices.com> Date: Fri May 27 13:30:40 2016 -0700 net: fec: update dirty_tx even if no skb If dirty_tx isn't updated, then dma_unmap_single can be called twice. This fixes a [ 58.420980] ------------[ cut here ]------------ [ 58.425667] WARNING: CPU: 0 PID: 377 at /home/schurig/d/mkarm/linux-4.5/lib/dma-debug.c:1096 check_unmap+0x9d0/0xab8() [ 58.436405] fec 2188000.ethernet: DMA-API: device driver tries to free DMA memory it has not allocated [device address=0x0000000000000000] [size=66 bytes] encountered by Holger Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Tested-by: <holgerschurig@gmail.com> Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_main.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 308453aa9156a3b8ee382c0949befb507a32b0c1 Author: Mike Manning <mmanning@brocade.com> Date: Fri May 27 17:45:07 2016 +0100 vlan: Propagate MAC address to VLANs The MAC address of the physical interface is only copied to the VLAN when it is first created, resulting in an inconsistency after MAC address changes of only newly created VLANs having an up-to-date MAC. The VLANs should continue inheriting the MAC address of the physical interface until the VLAN MAC address is explicitly set to any value. This allows IPv6 EUI64 addresses for the VLAN to reflect any changes to the MAC of the physical interface and thus for DAD to behave as expected. Signed-off-by: Mike Manning <mmanning@brocade.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/8021q/vlan.c | 5 +++++ net/8021q/vlan.h | 2 ++ net/8021q/vlan_dev.c | 20 +++++++++++++++++--- 3 files changed, 24 insertions(+), 3 deletions(-) commit f2633d2eaaab773ea8b29cea3785cf0f8a8872a5 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri May 27 13:34:35 2016 +0300 atm: iphase: off by one in rx_pkt() The iadev->rx_open[] array holds "iadev->num_vc" pointers (this code assumes that pointers are 32 bits). So the > here should be >= or else we could end up reading a garbage pointer from one element beyond the end of the array. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/atm/iphase.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 86f04396ff6d36146ec335d429191a7c8e2209af Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri May 27 13:33:50 2016 +0300 atm: firestream: add more reserved strings This bug was there when the driver was first added in back in year 2000. It causes a Smatch warning: drivers/atm/firestream.c:849 process_incoming() error: buffer overflow 'res_strings' 60 <= 63 There are supposed to be 64 entries in this array and the missing strings are clearly in the 30 40 range. I added them as reserved 37 to reserved 40. It's possible that strings are really supposed to be added in the middle instead of at the end, but this approach is safe, in that it fixes the bug and doesn't break anything that wasn't already broken. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/atm/firestream.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit ce577668a426c6a9e2470a09dcd07fbd6e45272a Author: Chen Haiquan <oc@yunify.com> Date: Fri May 27 10:49:11 2016 +0800 vxlan: Accept user specified MTU value when create new vxlan link When create a new vxlan link, example: ip link add vtap mtu 1440 type vxlan vni 1 dev eth0 The argument "mtu" has no effect, because it is not set to conf->mtu. The default value is used in vxlan_dev_configure function. This problem was introduced by commit 0dfbdf4102b9 (vxlan: Factor out device configuration). Fixes: 0dfbdf4102b9 (vxlan: Factor out device configuration) Signed-off-by: Chen Haiquan <oc@yunify.com> Acked-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 3 +++ 1 file changed, 3 insertions(+) commit bcf91bdb44d2e6d84ffc5b7ab0400d5ff1c27645 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu May 26 17:21:06 2016 -0700 net: pktgen: Call destroy_hrtimer_on_stack() If CONFIG_DEBUG_OBJECTS_TIMERS=y, hrtimer_init_on_stack() requires a matching call to destroy_hrtimer_on_stack() to clean up timer debug objects. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/pktgen.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c08376ac97cb202ec65320f3d90d5c4c5e2adb0b Author: Guenter Roeck <linux@roeck-us.net> Date: Thu May 26 17:21:05 2016 -0700 timer: Export destroy_hrtimer_on_stack() hrtimer_init_on_stack() needs a matching call to destroy_hrtimer_on_stack(), so both need to be exported. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/time/hrtimer.c | 1 + 1 file changed, 1 insertion(+) commit 3ac066e2227cb272c097f34475247fa0a6cdd2ff Author: Jean-Jacques Hiblot <jjhiblot@ti.com> Date: Tue May 31 17:56:23 2016 +0200 spi: spi-ti-qspi: Suspend the queue before removing the device Before disabling the pm_runtime, we must ensure that there is no transfer in progress nor will a new one be started. Otherwise the message pump will fail and in the end, the process requesting the transfer will be stuck. This behavior has been observed when transferring data from a SPI flash with dd while removing the module on a DRA7x-evm. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-ti-qspi.c | 7 +++++++ 1 file changed, 7 insertions(+) commit e47b020a323d1b2a7b1e9aac86e99eae19463630 Author: Catalin Marinas <catalin.marinas@arm.com> Date: Tue May 31 15:55:03 2016 +0100 arm64: Provide "model name" in /proc/cpuinfo for PER_LINUX32 tasks This patch brings the PER_LINUX32 /proc/cpuinfo format more in line with the 32-bit ARM one by providing an additional line: model name : ARMv8 Processor rev X (v8l) Cc: <stable@vger.kernel.org> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/elf.h | 4 ++-- arch/arm64/kernel/cpuinfo.c | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) commit b02da6f8236148009c22167cd7013d5ce04a2d37 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Mon May 23 17:08:42 2016 +0530 dma-buf: use vma_pages() Replace explicit computation of vma page count by a call to vma_pages(). Also, include <linux/mm.h> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org> drivers/dma-buf/dma-buf.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 4320c2a22df12f954edd4997f71ca3a4216312b2 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Mon Apr 11 12:48:55 2016 +0100 fence: add missing descriptions for fence The members child_list and active_list were added to the fence struct without descriptions for the Documentation. Adding these. Fixes: b55b54b5db33 ("staging/android: remove struct sync_pt") Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org> include/linux/fence.h | 2 ++ 1 file changed, 2 insertions(+) commit eae1760fc838d5f569a80939f72483f02ac049c5 Author: Rob Clark <robdclark@gmail.com> Date: Thu Mar 31 16:26:52 2016 -0400 doc: update/fixup dma-buf related DocBook Split out dma-buf related parts into their own section, add missing files, and write a bit of overview about how it all fits together. Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org> Documentation/DocBook/device-drivers.tmpl | 36 +++++++++++++++++++++++++++---- 1 file changed, 32 insertions(+), 4 deletions(-) commit 367d3fd50566a313946fa9c5b2116a81bf3807e4 Merge: 5eca831 cf0d44d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 31 09:43:24 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux Pull s390 fixes from Martin Schwidefsky: "Three bugs fixes and an update for the default configuration" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: s390: fix info leak in do_sigsegv s390/config: update default configuration s390/bpf: fix recache skb->data/hlen for skb_vlan_push/pop s390/bpf: reduce maximum program size to 64 KB commit dad6c3945fd25384c2b92306a90ba033e1130428 Author: Rob Clark <robdclark@gmail.com> Date: Thu Mar 31 16:26:51 2016 -0400 reservation: add headerdoc comments Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org> drivers/dma-buf/reservation.c | 72 ++++++++++++++++++++++++++++++++++++++++--- include/linux/reservation.h | 53 +++++++++++++++++++++++++++++++ 2 files changed, 121 insertions(+), 4 deletions(-) commit e2082e3ab801b989d8d5337b2ecbfc61d09781cb Author: Rob Clark <robdclark@gmail.com> Date: Thu Mar 31 16:26:50 2016 -0400 dma-buf: headerdoc fixes Apparently nobody noticed that dma-buf.h wasn't actually pulled into docbook build. And as a result the headerdoc comments bitrot a bit. Add missing params/fields. Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org> include/linux/dma-buf.h | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 5eca83174264a8eacf854685c59e08b7e1d628a3 Merge: 852f42a 545ebd9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 31 09:27:00 2016 -0700 Merge tag 'gpio-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fixes from Linus Walleij: "A bunch of GPIO fixes for the v4.7 series: - Drop the lock before reading out the GPIO direction setting in drivers supporting the .get_direction() callback: some of them may be slowpath. - Flush GPIO direction setting before locking a GPIO as an IRQ: some electronics or other poking around in the registers behind our back may have happened, so flush the direction status before trying to lock the line for use by IRQs. - Bail out silently when asked to perform operations on NULL GPIO descriptors. That is what all the get_*_optional() is about: we get optional GPIO handles, if they are not there, we get NULL. - Handle compatible ioctl() correctly: we need to convert the ioctl() pointer using compat_ptr() here like everyone else. - Disable the broken .to_irq() on the LPC32xx platform. The whole irqchip infrastructure was replaced in the last merge window, and a new implementation will be needed" * tag 'gpio-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: gpio: drop lock before reading GPIO direction gpio: bail out silently on NULL descriptors gpio: handle compatible ioctl() pointers gpio: flush direction status in gpiochip_lock_as_irq() gpio: lpc32xx: disable broken to_irq support commit c714a588fc39dc8c8f70014f5691217717983fb3 Author: Axel Lin <axel.lin@ingics.com> Date: Tue May 31 17:26:00 2016 +0800 regulator: tps51632: Fix setting ramp delay According to the datasheet: SLEW Register(Address = 07h) b7 b6 b5 b4 b3 b2 b1 b0 48mV/us 42mV/us 36mV/us 30mV/us 24mV/us 18mV/us 12mV/us 6mV/us Current code does not set correct slew rate in some cases: e.g. Assume ramp_delay is 10000, current code sets slew register to 6mV/us. Fix the logic to set slew register. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/tps51632-regulator.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 0358ccc8ffd8d9b76992b8deab58fb9a721fb18a Author: Robert P. J. Day <rpjday@crashcourse.ca> Date: Tue May 31 09:12:04 2016 -0400 ALSA: uapi: Add three missing header files to Kbuild file include/uapi/sound/Kbuild was missing the inclusion of three header files in that directory. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Takashi Iwai <tiwai@suse.de> include/uapi/sound/Kbuild | 3 +++ 1 file changed, 3 insertions(+) commit c58513284029229842844929ddeaca44d013c128 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 25 15:26:39 2016 +0100 arm64: KVM: vgic-v3: Relax synchronization when SRE==1 The GICv3 backend of the vgic is quite barrier heavy, in order to ensure synchronization of the system registers and the memory mapped view for a potential GICv2 guest. But when the guest is using a GICv3 model, there is absolutely no need to execute all these heavy barriers, and it is actually beneficial to avoid them altogether. This patch makes the synchonization conditional, and ensures that we do not change the EL1 SRE settings if we do not need to. Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm64/kvm/hyp/vgic-v3-sr.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) commit a057001e9e446f2195c34bc55c57e5cf353c99d6 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 25 15:26:38 2016 +0100 arm64: KVM: vgic-v3: Prevent the guest from messing with ICC_SRE_EL1 Both our GIC emulations are "strict", in the sense that we either emulate a GICv2 or a GICv3, and not a GICv3 with GICv2 legacy support. But when running on a GICv3 host, we still allow the guest to tinker with the ICC_SRE_EL1 register during its time slice: it can switch SRE off, observe that it is off, and yet on the next world switch, find the SRE bit to be set again. Not very nice. An obvious solution is to always trap accesses to ICC_SRE_EL1 (by clearing ICC_SRE_EL2.Enable), and to let the handler return the programmed value on a read, or ignore the write. That way, the guest can always observe that our GICv3 is SRE==1 only. Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm64/kvm/hyp/vgic-v3-sr.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit b34f2bcbf59fe2d27c37d6553c33611754677103 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 25 15:26:37 2016 +0100 arm64: KVM: Make ICC_SRE_EL1 access return the configured SRE value When we trap ICC_SRE_EL1, we handle it as RAZ/WI. It would be more correct to actual make it RO, and return the configured value when read. Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm64/kvm/sys_regs.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) commit 637d122baac7ff386c8e96df38ac88cee1551db9 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 25 15:26:36 2016 +0100 KVM: arm/arm64: vgic-v3: Always resample level interrupts When reading back from the list registers, we need to perform two actions for level interrupts: 1) clear the soft-pending bit if the interrupt is not pending anymore *in the list register* 2) resample the line level and propagate it to the pending state But these two actions shouldn't be linked, and we should *always* resample the line level, no matter what state is in the list register. Otherwise, we may end-up injecting spurious interrupts that have been already retired. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-v3.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit df7942d17e1623d7358fe895377293637de5521b Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 25 15:26:35 2016 +0100 KVM: arm/arm64: vgic-v2: Always resample level interrupts When reading back from the list registers, we need to perform two actions for level interrupts: 1) clear the soft-pending bit if the interrupt is not pending anymore *in the list register* 2) resample the line level and propagate it to the pending state But these two actions shouldn't be linked, and we should *always* resample the line level, no matter what state is in the list register. Otherwise, we may end-up injecting spurious interrupts that have been already retired. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-v2.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit fa89c77e891917b5913f9be080f9131a9457bb3e Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed May 25 15:26:34 2016 +0100 KVM: arm/arm64: vgic-v3: Clear all dirty LRs When saving the state of the list registers, it is critical to reset them zero, as we could otherwise leave unexpected EOI interrupts pending for virtual level interrupts. Cc: stable@vger.kernel.org # v4.6+ Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> arch/arm64/kvm/hyp/vgic-v3-sr.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 4d3afc9bad2b67b118a0cc204dc94703f7a44e74 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed May 25 15:26:33 2016 +0100 KVM: arm/arm64: vgic-v2: Clear all dirty LRs When saving the state of the list registers, it is critical to reset them zero, as we could otherwise leave unexpected EOI interrupts pending for virtual level interrupts. Cc: stable@vger.kernel.org # v4.6+ Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> virt/kvm/arm/hyp/vgic-v2-sr.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 500e06b9a3f50d3db992eb3b8dc309f695d33f63 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 31 19:09:55 2016 +0530 ASoC: hdac_hdmi: Fix potential NULL dereference Static checker warns: Pointer 'hlink' returned from call to function 'snd_hdac_ext_bus_get_link' at line may be NULL and will be dereferenced" So we should always check the return of snd_hdac_ext_bus_get_link() before referencing the link pointer Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 604c8e676e609da9f17a2abb36f2b2067bb86561 Author: Mark Rutland <mark.rutland@arm.com> Date: Fri May 13 12:20:36 2016 +0100 arm64: enable CONFIG_SET_MODULE_RONX by default The SET_MODULE_RONX protections are effectively the same as the DEBUG_RODATA protections we enabled by default back in commit 57efac2f7108e325 ("arm64: enable CONFIG_DEBUG_RODATA by default"). It seems unusual to have one but not the other. As evidenced by the help text, the rationale appears to be that SET_MODULE_RONX interacts poorly with tracing and patching, but both of these make use of the insn framework, which takes SET_MODULE_RONX into account. Any remaining issues are bugs which should be fixed regardless of the default state of the option. This patch enables DEBUG_SET_MODULE_RONX by default, and replaces the help text with a new wording derived from the DEBUG_RODATA help text, which better describes the functionality. Previously, the DEBUG_RODATA entry was inconsistently indented with spaces, which are replaced with tabs as with the other Kconfig entries. Additionally, the wording of recommended defaults is made consistent for all options. These are placed in a new paragraph, unquoted, as a full sentence (with a period/full stop) as this appears to be the most common form per $(git grep 'in doubt'). Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Laura Abbott <labbott@fedoraproject.org> Acked-by: Kees Cook <keescook@chromium.org> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig.debug | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) commit db413b51c0d023b336634ffbf5eb29128245df8d Author: Robin Murphy <robin.murphy@arm.com> Date: Tue May 24 18:55:40 2016 +0100 arm64: Remove orphaned __addr_ok() definition Since commit 12a0ef7b0ac3 ("arm64: use generic strnlen_user and strncpy_from_user functions"), the definition of __addr_ok() has been languishing unused; eradicate the sucker. CC: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/uaccess.h | 13 ------------- 1 file changed, 13 deletions(-) commit 6fe04128f158c5ad27e7504bfdf1b12e63331bc9 Author: Felix Fietkau <nbd@nbd.name> Date: Thu May 19 17:34:38 2016 +0200 mac80211: fix fast_tx header alignment The header field is defined as u8[] but also accessed as struct ieee80211_hdr. Enforce an alignment of 2 to prevent unnecessary unaligned accesses, which can be very harmful for performance on many platforms. Fixes: e495c24731a2 ("mac80211: extend fast-xmit for more ciphers") Cc: stable@vger.kernel.org Signed-off-by: Felix Fietkau <nbd@nbd.name> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/sta_info.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe7a7c57629e8dcbc0e297363a9b2366d67a6dc5 Author: Bob Copeland <me@bobcopeland.com> Date: Sun May 15 13:19:16 2016 -0400 mac80211: mesh: flush mesh paths unconditionally Currently, the mesh paths associated with a nexthop station are cleaned up in the following code path: __sta_info_destroy_part1 synchronize_net() __sta_info_destroy_part2 -> cleanup_single_sta -> mesh_sta_cleanup -> mesh_plink_deactivate -> mesh_path_flush_by_nexthop However, there are a couple of problems here: 1) the paths aren't flushed at all if the MPM is running in userspace (e.g. when using wpa_supplicant or authsae) 2) there is no synchronize_rcu between removing the path and readers accessing the nexthop, which means the following race is possible: CPU0 CPU1 ~~~~ ~~~~ sta_info_destroy_part1() synchronize_net() rcu_read_lock() mesh_nexthop_resolve() mpath = mesh_path_lookup() [...] -> mesh_path_flush_by_nexthop() sta = rcu_dereference( mpath->next_hop) kfree(sta) access sta <-- CRASH Fix both of these by unconditionally flushing paths before destroying the sta, and by adding a synchronize_net() after path flush to ensure no active readers can still dereference the sta. Fixes this crash: [ 348.529295] BUG: unable to handle kernel paging request at 00020040 [ 348.530014] IP: [<f929245d>] ieee80211_mps_set_frame_flags+0x40/0xaa [mac80211] [ 348.530014] *pde = 00000000 [ 348.530014] Oops: 0000 [#1] PREEMPT [ 348.530014] Modules linked in: drbg ansi_cprng ctr ccm ppp_generic slhc ipt_MASQUERADE nf_nat_masquerade_ipv4 8021q ] [ 348.530014] CPU: 0 PID: 20597 Comm: wget Tainted: G O 4.6.0-rc5-wt=V1 #1 [ 348.530014] Hardware name: To Be Filled By O.E.M./To be filled by O.E.M., BIOS 080016 11/07/2014 [ 348.530014] task: f64fa280 ti: f4f9c000 task.ti: f4f9c000 [ 348.530014] EIP: 0060:[<f929245d>] EFLAGS: 00010246 CPU: 0 [ 348.530014] EIP is at ieee80211_mps_set_frame_flags+0x40/0xaa [mac80211] [ 348.530014] EAX: f4ce63e0 EBX: 00000088 ECX: f3788416 EDX: 00020008 [ 348.530014] ESI: 00000000 EDI: 00000088 EBP: f6409a4c ESP: f6409a40 [ 348.530014] DS: 007b ES: 007b FS: 0000 GS: 0033 SS: 0068 [ 348.530014] CR0: 80050033 CR2: 00020040 CR3: 33190000 CR4: 00000690 [ 348.530014] Stack: [ 348.530014] 00000000 f4ce63e0 f5f9bd80 f6409a64 f9291d80 0000ce67 f5d51e00 f4ce63e0 [ 348.530014] f3788416 f6409a80 f9291dc1 f4ce8320 f4ce63e0 f5d51e00 f4ce63e0 f4ce8320 [ 348.530014] f6409a98 f9277f6f 00000000 00000000 0000007c 00000000 f6409b2c f9278dd1 [ 348.530014] Call Trace: [ 348.530014] [<f9291d80>] mesh_nexthop_lookup+0xbb/0xc8 [mac80211] [ 348.530014] [<f9291dc1>] mesh_nexthop_resolve+0x34/0xd8 [mac80211] [ 348.530014] [<f9277f6f>] ieee80211_xmit+0x92/0xc1 [mac80211] [ 348.530014] [<f9278dd1>] __ieee80211_subif_start_xmit+0x807/0x83c [mac80211] [ 348.530014] [<c04df012>] ? sch_direct_xmit+0xd7/0x1b3 [ 348.530014] [<c022a8c6>] ? __local_bh_enable_ip+0x5d/0x7b [ 348.530014] [<f956870c>] ? nf_nat_ipv4_out+0x4c/0xd0 [nf_nat_ipv4] [ 348.530014] [<f957e036>] ? iptable_nat_ipv4_fn+0xf/0xf [iptable_nat] [ 348.530014] [<c04c6f45>] ? netif_skb_features+0x14d/0x30a [ 348.530014] [<f9278e10>] ieee80211_subif_start_xmit+0xa/0xe [mac80211] [ 348.530014] [<c04c769c>] dev_hard_start_xmit+0x1f8/0x267 [ 348.530014] [<c04c7261>] ? validate_xmit_skb.isra.120.part.121+0x10/0x253 [ 348.530014] [<c04defc6>] sch_direct_xmit+0x8b/0x1b3 [ 348.530014] [<c04c7a9c>] __dev_queue_xmit+0x2c8/0x513 [ 348.530014] [<c04c7cfb>] dev_queue_xmit+0xa/0xc [ 348.530014] [<f91bfc7a>] batadv_send_skb_packet+0xd6/0xec [batman_adv] [ 348.530014] [<f91bfdc4>] batadv_send_unicast_skb+0x15/0x4a [batman_adv] [ 348.530014] [<f91b5938>] batadv_dat_send_data+0x27e/0x310 [batman_adv] [ 348.530014] [<f91c30b5>] ? batadv_tt_global_hash_find.isra.11+0x8/0xa [batman_adv] [ 348.530014] [<f91b63f3>] batadv_dat_snoop_outgoing_arp_request+0x208/0x23d [batman_adv] [ 348.530014] [<f91c0cd9>] batadv_interface_tx+0x206/0x385 [batman_adv] [ 348.530014] [<c04c769c>] dev_hard_start_xmit+0x1f8/0x267 [ 348.530014] [<c04c7261>] ? validate_xmit_skb.isra.120.part.121+0x10/0x253 [ 348.530014] [<c04defc6>] sch_direct_xmit+0x8b/0x1b3 [ 348.530014] [<c04c7a9c>] __dev_queue_xmit+0x2c8/0x513 [ 348.530014] [<f80cbd2a>] ? igb_xmit_frame+0x57/0x72 [igb] [ 348.530014] [<c04c7cfb>] dev_queue_xmit+0xa/0xc [ 348.530014] [<f843a326>] br_dev_queue_push_xmit+0xeb/0xfb [bridge] [ 348.530014] [<f843a35f>] br_forward_finish+0x29/0x74 [bridge] [ 348.530014] [<f843a23b>] ? deliver_clone+0x3b/0x3b [bridge] [ 348.530014] [<f843a714>] __br_forward+0x89/0xe7 [bridge] [ 348.530014] [<f843a336>] ? br_dev_queue_push_xmit+0xfb/0xfb [bridge] [ 348.530014] [<f843a234>] deliver_clone+0x34/0x3b [bridge] [ 348.530014] [<f843a68b>] ? br_flood+0x95/0x95 [bridge] [ 348.530014] [<f843a66d>] br_flood+0x77/0x95 [bridge] [ 348.530014] [<f843a809>] br_flood_forward+0x13/0x1a [bridge] [ 348.530014] [<f843a68b>] ? br_flood+0x95/0x95 [bridge] [ 348.530014] [<f843b877>] br_handle_frame_finish+0x392/0x3db [bridge] [ 348.530014] [<c04e9b2b>] ? nf_iterate+0x2b/0x6b [ 348.530014] [<f843baa6>] br_handle_frame+0x1e6/0x240 [bridge] [ 348.530014] [<f843b4e5>] ? br_handle_local_finish+0x6a/0x6a [bridge] [ 348.530014] [<c04c4ba0>] __netif_receive_skb_core+0x43a/0x66b [ 348.530014] [<f843b8c0>] ? br_handle_frame_finish+0x3db/0x3db [bridge] [ 348.530014] [<c023cea4>] ? resched_curr+0x19/0x37 [ 348.530014] [<c0240707>] ? check_preempt_wakeup+0xbf/0xfe [ 348.530014] [<c0255dec>] ? ktime_get_with_offset+0x5c/0xfc [ 348.530014] [<c04c4fc1>] __netif_receive_skb+0x47/0x55 [ 348.530014] [<c04c57ba>] netif_receive_skb_internal+0x40/0x5a [ 348.530014] [<c04c61ef>] napi_gro_receive+0x3a/0x94 [ 348.530014] [<f80ce8d5>] igb_poll+0x6fd/0x9ad [igb] [ 348.530014] [<c0242bd8>] ? swake_up_locked+0x14/0x26 [ 348.530014] [<c04c5d29>] net_rx_action+0xde/0x250 [ 348.530014] [<c022a743>] __do_softirq+0x8a/0x163 [ 348.530014] [<c022a6b9>] ? __hrtimer_tasklet_trampoline+0x19/0x19 [ 348.530014] [<c021100f>] do_softirq_own_stack+0x26/0x2c [ 348.530014] <IRQ> [ 348.530014] [<c022a957>] irq_exit+0x31/0x6f [ 348.530014] [<c0210eb2>] do_IRQ+0x8d/0xa0 [ 348.530014] [<c058152c>] common_interrupt+0x2c/0x40 [ 348.530014] Code: e7 8c 00 66 81 ff 88 00 75 12 85 d2 75 0e b2 c3 b8 83 e9 29 f9 e8 a7 5f f9 c6 eb 74 66 81 e3 8c 005 [ 348.530014] EIP: [<f929245d>] ieee80211_mps_set_frame_flags+0x40/0xaa [mac80211] SS:ESP 0068:f6409a40 [ 348.530014] CR2: 0000000000020040 [ 348.530014] ---[ end trace 48556ac26779732e ]--- [ 348.530014] Kernel panic - not syncing: Fatal exception in interrupt [ 348.530014] Kernel Offset: disabled Cc: stable@vger.kernel.org Reported-by: Fred Veldini <fred.veldini@gmail.com> Tested-by: Fred Veldini <fred.veldini@gmail.com> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.c | 4 ++++ 1 file changed, 4 insertions(+) commit 62397da50bb20a6b812c949ef465d7e69fe54bb6 Author: Martin Willi <martin@strongswan.org> Date: Fri May 13 12:41:48 2016 +0200 mac80211_hwsim: Add missing check for HWSIM_ATTR_SIGNAL A wmediumd that does not send this attribute causes a NULL pointer dereference, as the attribute is accessed even if it does not exist. The attribute was required but never checked ever since userspace frame forwarding has been introduced. The issue gets more problematic once we allow wmediumd registration from user namespaces. Cc: stable@vger.kernel.org Fixes: 7882513bacb1 ("mac80211_hwsim driver support userspace frame tx/rx") Signed-off-by: Martin Willi <martin@strongswan.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> drivers/net/wireless/mac80211_hwsim.c | 1 + 1 file changed, 1 insertion(+) commit 8dd75ccb571f3c92c48014b3dabd3d51a115ab41 Author: Thomas Huth <thuth@redhat.com> Date: Thu May 12 13:29:11 2016 +0200 powerpc: Use privileged SPR number for MMCR2 We are already using the privileged versions of MMCR0, MMCR1 and MMCRA in the kernel, so for MMCR2, we should better use the privileged versions, too, to be consistent. Fixes: 240686c13687 ("powerpc: Initialise PMU related regs on Power8") Cc: stable@vger.kernel.org # v3.10+ Suggested-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Thomas Huth <thuth@redhat.com> Acked-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/reg.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d23fac2b27d94aeb7b65536a50d32bfdc21fe01e Author: Thomas Huth <thuth@redhat.com> Date: Thu May 12 13:26:44 2016 +0200 powerpc: Fix definition of SIAR and SDAR registers The SIAR and SDAR registers are available twice, one time as SPRs 780 / 781 (unprivileged, but read-only), and one time as the SPRs 796 / 797 (privileged, but read and write). The Linux kernel code currently uses the unprivileged SPRs - while this is OK for reading, writing to that register of course does not work. Since the KVM code tries to write to this register, too (see the mtspr in book3s_hv_rmhandlers.S), the contents of this register sometimes get lost for the guests, e.g. during migration of a VM. To fix this issue, simply switch to the privileged SPR numbers instead. Cc: stable@vger.kernel.org Signed-off-by: Thomas Huth <thuth@redhat.com> Acked-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/reg.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ab2e1b89230fa80328262c91d2d0a539a2790d6f Author: Will Deacon <will.deacon@arm.com> Date: Tue May 31 11:00:09 2016 +0100 Revert "arm64: hugetlb: partial revert of 66b3923a1a0f" This reverts commit ff7925848b50050732ac0401e0acf27e8b241d7b. Now that the contiguous-hint hugetlb regression has been debugged and fixed upstream by 66ee95d16a7f ("mm: exclude HugeTLB pages from THP page_mapped() logic"), we can revert the previous partial revert of this feature. Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/hugetlbpage.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 893e093c786c4256d52809eed697e9d70a6f6643 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue May 24 11:23:51 2016 +0200 netfilter: nf_ct_helper: bail out on duplicated helpers Don't allow registration of helpers using the same tuple: { l3proto, l4proto, src-port } We lookup for the helper from the packet path using this tuple through __nf_ct_helper_find(). Therefore, we have to avoid having two helpers with the same tuple to ensure predictible behaviour. Don't compare the helper string names anymore since it is valid to register two helpers with the same name, but using different tuples. This is also implicitly fixing up duplicated helper registration via ports= modparam since the name comparison was defeating the tuple duplication validation. Reported-by: Feng Gao <gfree.wind@gmail.com> Reported-by: Taehee Yoo <ap420073@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_helper.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 27a0faafdca53bda21ed340ca8f8960696dda049 Author: Peter Griffin <peter.griffin@linaro.org> Date: Wed May 11 17:33:11 2016 +0100 usb: dwc3: st: Fix USB_DR_MODE_PERIPHERAL configuration. Set USB3_FORCE_VBUSVALID when configured for USB_DR_MODE_PERIPHERAL mode, as it is required to have a working setup. This worked on the internal driver by relying on the reset value of the syscfg register as the bits aren't explicity cleared and set like the upstream driver. Also add a comment about what setting this bit means. Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-st.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 7e14f47a55ed67c9d8a8acea6023412f92bac936 Author: William Wu <william.wu@rock-chips.com> Date: Fri May 13 18:30:42 2016 +0800 usb: gadget: composite: don't queue OS desc req if length is invalid In OS descriptors handling, if ctrl->bRequestType is USB_RECIP_DEVICE and w_index != 0x4 or (w_value >> 8) is true, it will not assign a valid value to req->length, but use the default value(-EOPNOTSUPP), and queue an OS desc request with the invalid req->length. It always happens on the platforms which use os_desc (for example: rk3366, rk3399), and cause kernel panic as follows (use dwc3 driver): Unable to handle kernel paging request at virtual address ffffffc0f7e00000 Internal error: Oops: 96000146 [#1] PREEMPT SMP PC is at __dma_clean_range+0x18/0x30 LR is at __swiotlb_map_page+0x50/0x64 Call trace: [<ffffffc0000930f8>] __dma_clean_range+0x18/0x30 [<ffffffc00062214c>] usb_gadget_map_request+0x134/0x1b0 [<ffffffc0005c289c>] __dwc3_ep0_do_control_data+0x110/0x14c [<ffffffc0005c2d38>] __dwc3_gadget_ep0_queue+0x198/0x1b8 [<ffffffc0005c2e18>] dwc3_gadget_ep0_queue+0xc0/0xe8 [<ffffffc00061cfec>] composite_ep0_queue.constprop.14+0x34/0x98 [<ffffffc00061dfb0>] composite_setup+0xf60/0x100c [<ffffffc0006204dc>] android_setup+0xd8/0x138 [<ffffffc0005c29a4>] dwc3_ep0_delegate_req+0x34/0x50 [<ffffffc0005c3534>] dwc3_ep0_interrupt+0x5dc/0xb58 [<ffffffc0005c0c3c>] dwc3_thread_interrupt+0x15c/0xa24 With this patch, the gadget driver will not queue a request and return immediately if req->length is invalid. And the usb controller driver can handle the unsupport request correctly. Signed-off-by: William Wu <william.wu@rock-chips.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/composite.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit c6010c8b4d2c6e75853ca63c602c9af56fcbead5 Author: Jim Lin <jilin@nvidia.com> Date: Fri May 13 20:32:16 2016 +0800 usb: gadget: f_fs: Fix kernel panic if use_os_string not set If c->cdev->use_os_string flag is not set, don't need to invoke ffs_do_os_descs() in _ffs_func_bind. So uninitialized ext_compat_id pointer won't be accessed by __ffs_func_bind_do_os_desc to cause kernel panic. Signed-off-by: Jim Lin <jilin@nvidia.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_fs.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit e877b729c649c2850f61f2ae37296ae701f9ad63 Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Sun May 8 22:50:12 2016 +0200 usb: gadget: f_tcm: out of bound access in usbg_drop_tpg Commit dc8c46a5ae77 ("usb: gadget: f_tcm: convert to new function interface with backward compatibility") introduced a possible out of bounds memory access: If tpg is not found in function usbg_drop_tpg, tpg_instances[TPG_INSTANCES] is accessed. Fixes: dc8c46a5ae77 ("usb: gadget: f_tcm: convert to new function interface with backward compatibility") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_tcm.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit ffeee83aa0461992e8a99a59db2df31933e60362 Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Sun May 8 23:20:59 2016 +0200 usb: gadget: avoid exposing kernel stack Function in_rq_cur copies random bytes from the stack. Zero the memory instead. Fixes: 132fcb460839 ("usb: gadget: Add Audio Class 2.0 Driver") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_uac2.c | 1 + 1 file changed, 1 insertion(+) commit 23e3439296a55affce3ef0ab78f1c2e03aec8767 Author: Arnd Bergmann <arnd@arndb.de> Date: Fri May 13 15:52:27 2016 +0200 usb: dwc2: fix regression on big-endian PowerPC/ARM systems A patch that went into Linux-4.4 to fix big-endian mode on a Lantiq MIPS system unfortunately broke big-endian operation on PowerPC APM82181 as reported by Christian Lamparter, and likely other systems. It actually introduced multiple issues: - it broke big-endian ARM kernels: any machine that was working correctly with a little-endian kernel is no longer using byteswaps on big-endian kernels, which clearly breaks them. - On PowerPC the same thing must be true: if it was working before, using big-endian kernels is now broken. Unlike ARM, 32-bit PowerPC usually uses big-endian kernels, so they are likely all broken. - The barrier for dwc2_writel is on the wrong side of the __raw_writel(), so the MMIO no longer synchronizes with DMA operations. - On architectures that require specific CPU instructions for MMIO access, using the __raw_ variant may turn this into a pointer dereference that does not have the same effect as the readl/writel. This patch is a simple revert for all architectures other than MIPS, in the hope that we can more easily backport it to fix the regression on PowerPC and ARM systems without breaking the Lantiq system again. We should follow this up with a more elaborate change to add runtime detection of endianness, to make sure it also works on all other combinations of architectures and implementations of the usb-dwc2 device. That patch however will be fairly large and not appropriate for backports to stable kernels. Felipe suggested a different approach, using an endianness switching register to always put the device into LE mode, but unfortunately the dwc2 hardware does not provide a generic way to do that. Also, I see no practical way of addressing the problem more generally by patching architecture specific code on MIPS. Fixes: 95c8bc360944 ("usb: dwc2: Use platform endianness when accessing registers") Acked-by: John Youn <johnyoun@synopsys.com> Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/core.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit 5edf673d07fdcb6498be24914f3f38f8d8843199 Author: hongkun.cao <hongkun.cao@mediatek.com> Date: Sat May 21 15:23:39 2016 +0800 pinctrl: mediatek: fix dual-edge code defect When a dual-edge irq is triggered, an incorrect irq will be reported on condition that the external signal is not stable and this incorrect irq has been registered. Correct the register offset. Cc: stable@vger.kernel.org Signed-off-by: Hongkun Cao <hongkun.cao@mediatek.com> Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 53642399aa71b7c3b15d0305dc54738c4222bb1e Author: Jim Lin <jilin@nvidia.com> Date: Fri May 20 18:13:19 2016 +0800 usb: gadget: f_fs: Fix wrong check on reserved1 of OS_DESC_EXT_COMPAT Current __ffs_data_do_os_desc() of f_fs.c will check reserved1 field of OS_DESC_EXT_COMPAT and return -EINVAL if it's 1. But MS OS 1.0 Descriptors http://msdn.microsoft.com/en-us/library/windows/hardware/gg463179.aspx defines that field to be 1. Signed-off-by: Jim Lin <jilin@nvidia.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cc50dc28da9109d585416595fc23ebb2171f3b2f Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Sun May 22 11:08:15 2016 +0200 usb: gadget: storage-common: Fix old comment about qualifier descriptor Device qualifier descriptor is now generated by composite.c code. So let's fix this old comment by removing parts which are no longer valid. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Krzysztof Opasiak <kopasiak90@gmail.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/storage_common.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit d4529f9be1d72919f75f76f31773c4e98d03ce6b Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Sun May 22 11:08:14 2016 +0200 usb: gadget: uac2: Drop unused device qualifier descriptor This descriptor is never used. Currently device qualifier descriptor is generated by compossite code so no need to keep it in function file. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Krzysztof Opasiak <kopasiak90@gmail.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_uac2.c | 12 ------------ 1 file changed, 12 deletions(-) commit e5a89162161d498170e7e39e6cfd2f71458c2b00 Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Sun May 22 11:08:13 2016 +0200 usb: gadget: printer: Drop unused device qualifier descriptor This descriptor is never used. Currently device qualifier descriptor is generated by compossite code, so no need to keep it in function file. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Krzysztof Opasiak <kopasiak90@gmail.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_printer.c | 8 -------- 1 file changed, 8 deletions(-) commit 375f62e7dd38440f9b7b31d99a36cc4286f47004 Author: Alexandre Belloni <alexandre.belloni@free-electrons.com> Date: Sun May 22 15:35:13 2016 +0200 Documentation: configfs-usb-gadget-uvc: fix kernel version v3.20 doesn't exist, it is actually v4.0. Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Documentation/ABI/testing/configfs-usb-gadget-uvc | 58 +++++++++++------------ 1 file changed, 29 insertions(+), 29 deletions(-) commit 15186f1011b088432a10f435aa6e2df5ab177503 Author: Vahram Aharonyan <vahrama@synopsys.com> Date: Mon May 23 22:41:59 2016 -0700 usb: dwc2: gadget: Do not halt isochronous endpoints Add a check in dwc2_hsotg_ep_sethalt() so that it does not halt isochronous endpoints. Signed-off-by: Vahram Aharonyan <vahrama@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/gadget.c | 5 +++++ 1 file changed, 5 insertions(+) commit 51da43b555ba19e0230ff5a5acc58eb0fffb6026 Author: Vahram Aharonyan <vahrama@synopsys.com> Date: Mon May 23 22:41:57 2016 -0700 usb: dwc2: gadget: Do not halt endpoint if active The gadget API function usb_ep_set_halt() expects the gadget to return -EAGAIN if the ep is active. Add support for this behavior. Otherwise this may break mass storage protocol if a STALL is attempted on the endpoint. Signed-off-by: Vahram Aharonyan <vahrama@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/gadget.c | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) commit d246dcb2331c5783743720e6510892eb1d2801d9 Author: Bin Liu <b-liu@ti.com> Date: Thu May 26 11:43:45 2016 -0500 usb: gadget: fix spinlock dead lock in gadgetfs [ 40.467381] ============================================= [ 40.473013] [ INFO: possible recursive locking detected ] [ 40.478651] 4.6.0-08691-g7f3db9a #37 Not tainted [ 40.483466] --------------------------------------------- [ 40.489098] usb/733 is trying to acquire lock: [ 40.493734] (&(&dev->lock)->rlock){-.....}, at: [<bf129288>] ep0_complete+0x18/0xdc [gadgetfs] [ 40.502882] [ 40.502882] but task is already holding lock: [ 40.508967] (&(&dev->lock)->rlock){-.....}, at: [<bf12a420>] ep0_read+0x20/0x5e0 [gadgetfs] [ 40.517811] [ 40.517811] other info that might help us debug this: [ 40.524623] Possible unsafe locking scenario: [ 40.524623] [ 40.530798] CPU0 [ 40.533346] ---- [ 40.535894] lock(&(&dev->lock)->rlock); [ 40.540088] lock(&(&dev->lock)->rlock); [ 40.544284] [ 40.544284] *** DEADLOCK *** [ 40.544284] [ 40.550461] May be due to missing lock nesting notation [ 40.550461] [ 40.557544] 2 locks held by usb/733: [ 40.561271] #0: (&f->f_pos_lock){+.+.+.}, at: [<c02a6114>] __fdget_pos+0x40/0x48 [ 40.569219] #1: (&(&dev->lock)->rlock){-.....}, at: [<bf12a420>] ep0_read+0x20/0x5e0 [gadgetfs] [ 40.578523] [ 40.578523] stack backtrace: [ 40.583075] CPU: 0 PID: 733 Comm: usb Not tainted 4.6.0-08691-g7f3db9a #37 [ 40.590246] Hardware name: Generic AM33XX (Flattened Device Tree) [ 40.596625] [<c010ffbc>] (unwind_backtrace) from [<c010c1bc>] (show_stack+0x10/0x14) [ 40.604718] [<c010c1bc>] (show_stack) from [<c04207fc>] (dump_stack+0xb0/0xe4) [ 40.612267] [<c04207fc>] (dump_stack) from [<c01886ec>] (__lock_acquire+0xf68/0x1994) [ 40.620440] [<c01886ec>] (__lock_acquire) from [<c0189528>] (lock_acquire+0xd8/0x238) [ 40.628621] [<c0189528>] (lock_acquire) from [<c06ad6b4>] (_raw_spin_lock_irqsave+0x38/0x4c) [ 40.637440] [<c06ad6b4>] (_raw_spin_lock_irqsave) from [<bf129288>] (ep0_complete+0x18/0xdc [gadgetfs]) [ 40.647339] [<bf129288>] (ep0_complete [gadgetfs]) from [<bf10a728>] (musb_g_giveback+0x118/0x1b0 [musb_hdrc]) [ 40.657842] [<bf10a728>] (musb_g_giveback [musb_hdrc]) from [<bf108768>] (musb_g_ep0_queue+0x16c/0x188 [musb_hdrc]) [ 40.668772] [<bf108768>] (musb_g_ep0_queue [musb_hdrc]) from [<bf12a944>] (ep0_read+0x544/0x5e0 [gadgetfs]) [ 40.678963] [<bf12a944>] (ep0_read [gadgetfs]) from [<c0284470>] (__vfs_read+0x20/0x110) [ 40.687414] [<c0284470>] (__vfs_read) from [<c0285324>] (vfs_read+0x88/0x114) [ 40.694864] [<c0285324>] (vfs_read) from [<c0286150>] (SyS_read+0x44/0x9c) [ 40.702051] [<c0286150>] (SyS_read) from [<c0107820>] (ret_fast_syscall+0x0/0x1c) This is caused by the spinlock bug in ep0_read(). Fix the two other deadlock sources in gadgetfs_setup() too. Cc: <stable@vger.kernel.org> # v3.16+ Signed-off-by: Bin Liu <b-liu@ti.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/legacy/inode.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit 0015f9156092d07b3ec06d37d014328419d5832e Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Sat May 28 07:48:10 2016 +0300 usb: f_fs: off by one bug in _ffs_func_bind() This loop is supposed to set all the .num[] values to -1 but it's off by one so it skips the first element and sets one element past the end of the array. I've cleaned up the loop a little as well. Fixes: ddf8abd25994 ('USB: f_fs: the FunctionFS driver') Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_fs.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 4879efb34f7d49235fac334d76d9c6a77a021413 Author: Steinar H. Gunderson <sesse@google.com> Date: Tue May 24 20:13:15 2016 +0200 usb: dwc3: exynos: Fix deferred probing storm. dwc3-exynos has two problems during init if the regulators are slow to come up (for instance if the I2C bus driver is not on the initramfs) and return probe deferral. First, every time this happens, the driver leaks the USB phys created; they need to be deallocated on error. Second, since the phy devices are created before the regulators fail, this means that there's a new device to re-trigger deferred probing, which causes it to essentially go into a busy loop of re-probing the device until the regulators come up. Move the phy creation to after the regulators have succeeded, and also fix cleanup on failure. On my ODROID XU4 system (with Debian's initramfs which doesn't contain the I2C driver), this reduces the number of probe attempts (for each of the two controllers) from more than 2000 to eight. Signed-off-by: Steinar H. Gunderson <sesse@google.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Vivek Gautam <gautam.vivek@samsung.com> Fixes: d720f057fda4 ("usb: dwc3: exynos: add nop transceiver support") Cc: <stable@vger.kernel.org> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-exynos.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit f1bddbb3de60872acc2446eee97dbeb0a6d57acb Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Thu May 5 10:46:05 2016 +0200 usb: gadget: Fix binding to UDC via configfs interface By default user could store only valid UDC name in configfs UDC attr by doing: echo $UDC_NAME > UDC Commit (855ed04 "usb: gadget: udc-core: independent registration of gadgets and gadget drivers") broke this behavior and allowed to store any arbitrary string in UDC file and udc core was waiting for such controller to appear. echo "any arbitrary string here" > UDC This commit fix this by adding a flag which prevents configfs gadget from being added to list of pending drivers if UDC with given name has not been found. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/configfs.c | 1 + drivers/usb/gadget/udc/udc-core.c | 12 ++++++++---- include/linux/usb/gadget.h | 3 +++ 3 files changed, 12 insertions(+), 4 deletions(-) commit d140b9bfcad9e53f1da67ad09dd5092b44d55c7b Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue May 31 11:46:47 2016 +0530 ARC: don't enable DISCONTIGMEM unconditionally Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d0196c8d5d3057c5c21a82f3d0113ca8e501033b Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 18:05:39 2016 +0200 drm/omap: include gpio/consumer.h where needed A lot of the display drivers for OMAP use the gpio descriptor functions that are only available in linux/gpio.h if GPIOLIB is enabled and otherwise produce a build error: drivers/gpu/drm/omapdrm/displays/encoder-opa362.c: In function 'opa362_enable': drivers/gpu/drm/omapdrm/displays/encoder-opa362.c:101:3: error: implicit declaration of function 'gpiod_set_value_cansleep' [-Werror=implicit-function-declaration] drivers/gpu/drm/omapdrm/displays/panel-dpi.c: In function 'panel_dpi_probe_pdata': drivers/gpu/drm/omapdrm/displays/panel-dpi.c:189:23: error: implicit declaration of function 'gpio_to_desc' [-Werror=implicit-function-declaration] drivers/gpu/drm/omapdrm/displays/panel-sharp-ls037v7dw01.c: In function 'sharp_ls_enable': drivers/gpu/drm/omapdrm/displays/panel-sharp-ls037v7dw01.c:120:3: error: implicit declaration of function 'gpiod_set_value_cansleep' [-Werror=implicit-function-declaration] This replaces the existing linux/gpio.h with linux/gpio/consumer.h where needed. In case of panel-lgphilips-lb035q02.c however, we also have to include linux/gpio.h to get the definition of gpio_is_valid and gpio_set_value_cansleep that are used for the non-DT case. Signed-off-by: Arnd Bergmann <arnd@arndb.de> [tomi.valkeinen@ti.com: resolved conflicts] Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/displays/connector-hdmi.c | 1 + drivers/gpu/drm/omapdrm/displays/encoder-opa362.c | 1 - drivers/gpu/drm/omapdrm/displays/encoder-tfp410.c | 2 +- drivers/gpu/drm/omapdrm/displays/panel-dpi.c | 1 - drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c | 2 +- drivers/gpu/drm/omapdrm/displays/panel-nec-nl8048hl11.c | 2 +- drivers/gpu/drm/omapdrm/displays/panel-sharp-ls037v7dw01.c | 1 - drivers/gpu/drm/omapdrm/displays/panel-sony-acx565akm.c | 2 +- drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c | 2 +- 9 files changed, 6 insertions(+), 8 deletions(-) commit 2d8024534a9ae8426ed249f317106b3404594c2d Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 18:01:45 2016 +0200 drm/omap: include linux/seq_file.h where needed The omapdrm driver relies on this header to be included implicitly, but this does not always work, and I get this error in randconfig builds: gpu/drm/omapdrm/dss/hdmi_phy.c: In function 'hdmi_phy_dump': gpu/drm/omapdrm/dss/hdmi_phy.c:34:2: error: implicit declaration of function 'seq_printf' [-Werror=implicit-function-declaration] gpu/drm/omapdrm/dss/hdmi_wp.c: In function 'hdmi_wp_dump': gpu/drm/omapdrm/dss/hdmi_wp.c:26:2: error: implicit declaration of function 'seq_printf' [-Werror=implicit-function-declaration] gpu/drm/omapdrm/dss/hdmi_pll.c: In function 'hdmi_pll_dump': gpu/drm/omapdrm/dss/hdmi_pll.c:30:2: error: implicit declaration of function 'seq_printf' [-Werror=implicit-function-declaration] This adds the #include statements in all files that have a seq_printf statement. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/dss/hdmi_phy.c | 1 + drivers/gpu/drm/omapdrm/dss/hdmi_pll.c | 1 + drivers/gpu/drm/omapdrm/dss/hdmi_wp.c | 1 + drivers/gpu/drm/omapdrm/omap_debugfs.c | 2 ++ drivers/gpu/drm/omapdrm/omap_dmm_tiler.c | 1 + drivers/gpu/drm/omapdrm/omap_fb.c | 2 ++ drivers/gpu/drm/omapdrm/omap_gem.c | 1 + 7 files changed, 9 insertions(+) commit 62cb0751c87cb2d0af0629d68cfb12d67f39badf Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Thu Apr 28 15:42:49 2016 +0300 Revert "drm/omap: no need to select OMAP2_DSS" This reverts commit 1c278e5e3718d15475ec08ee2135f37a6b13361c. If DRM_OMAP does not select OMAP2_DSS it is possible to build a kernel with DRM_OMAP only and not selecting OMAP2_DSS. Since omapdrm depends on OMAP2_DSS this will result on broken kernel build. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 973999aa0140481e590e791c320009d25a88d377 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Thu Apr 28 15:42:18 2016 +0300 drm/omap: Remove regulator API abuse regulator_can_change_voltage() is deprecated and it's use is not necessary as commit: 6a0028b3dd67b regulator: Deprecate regulator_can_change_voltage() describers it clearly. Also, regulator_set_voltage() is misused in the driver, as it is supposed to be used only in cases where the regulator voltage needs to be changed dynamically at runtime. In DSS's case, we always want a fixed voltage, set in the .dts files. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/dss/dsi.c | 9 --------- drivers/gpu/drm/omapdrm/dss/hdmi4.c | 9 --------- drivers/gpu/drm/omapdrm/dss/hdmi5.c | 9 --------- 3 files changed, 27 deletions(-) commit 4bafcbc77fb0b26b0052dbd577ccc888a63e6404 Author: Jim Lodes <jim.lodes@garmin.com> Date: Thu Apr 21 12:27:49 2016 -0500 OMAPDSS: HDMI5: Change DDC timings The DDC scl high and low times were set to the minimum values from the i2c specification, but the i2c specification takes into account the rise time and fall time to calculate the frequency. To pass HDMI certification DDC can not exceed 100kHz therefore in a system where the rise times and fall times are negligible the high and low times for scl need to be 10us. Signed-off-by: Jim Lodes <jim.lodes@garmin.com> Signed-off-by: J.D. Schroeder <jay.schroeder@garmin.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/dss/hdmi5_core.c | 4 ++-- drivers/video/fbdev/omap2/omapfb/dss/hdmi5_core.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 08f707ac3eb1fa86c43c705f9f78c1e40c49aba1 Author: Jim Lodes <jim.lodes@garmin.com> Date: Thu Apr 21 12:49:00 2016 -0500 OMAPDSS: HDMI5: Fix AVI infoframe The AVI infoframe R0-R3 in the 2nd data byte represents the Active Format Aspect Ratio. It is four bits long not two bits. This fixes that mask used to extract the bits before writing the bits to the hardware registers. Signed-off-by: Jim Lodes <jim.lodes@garmin.com> Signed-off-by: J.D. Schroeder <jay.schroeder@garmin.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/dss/hdmi5_core.c | 2 +- drivers/video/fbdev/omap2/omapfb/dss/hdmi5_core.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 91cd220aadc88dff6650127e7b19a85569ef8b7c Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Fri Apr 1 10:29:29 2016 +0300 drm/omap: fix OMAP4 hdmi_core_powerdown_disable() hdmi_core_powerdown_disable() is supposed to disable HDMI core's power-down mode. However, the function sets the power-down bit to 0, which means "enable power-down". This hasn't caused any issues as the PD seems to affect only interrupts from HDMI core, and none of those interrupts are used at the moment. CEC functionality requires core interrupts, and the PD mode needs to be fixed. This patch fixes hdmi_core_powerdown_disable() to actually disable the PD mode. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reported-by: Hans Verkuil <hverkuil@xs4all.nl> drivers/gpu/drm/omapdrm/dss/hdmi4_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d9e32ecda41bb6b6301fd2a0945003bb8f4e2ba1 Author: Tomi Valkeinen <tomi.valkeinen@ti.com> Date: Fri Mar 18 09:02:18 2016 +0200 drm/omap: Fix missing includes With certain kernel config options many omapdrm files fail to compile due to missing include of linux/gpio/consumer.h and linux/of.h. This patch adds those includes. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reported-by: Dan Murphy <dmurphy@ti.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> drivers/gpu/drm/omapdrm/displays/encoder-opa362.c | 1 + drivers/gpu/drm/omapdrm/displays/panel-dpi.c | 1 + drivers/gpu/drm/omapdrm/displays/panel-lgphilips-lb035q02.c | 1 + drivers/gpu/drm/omapdrm/displays/panel-sharp-ls037v7dw01.c | 1 + drivers/gpu/drm/omapdrm/dss/hdmi4.c | 1 + drivers/gpu/drm/omapdrm/dss/hdmi5.c | 1 + 6 files changed, 6 insertions(+) commit 2639d6b9be19e029869158a6b8cbc5d253cd7bbc Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 23:51:27 2016 +0200 drm/omapdrm: include pinctrl/consumer.h where needed In some configurations, we can build the OMAP dss driver without implictly including the pinctrl consumer definitions, causing a build error: gpu/drm/omapdrm/dss/dss.c: In function 'dss_runtime_suspend': gpu/drm/omapdrm/dss/dss.c:1268:2: error: implicit declaration of function 'pinctrl_pm_select_sleep_state' [-Werror=implicit-function-declaration] This adds an explicit #include. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/gpu/drm/omapdrm/dss/dss.c | 1 + 1 file changed, 1 insertion(+) commit b5de8d0df80fa87f1f97fbcc4bbc8cad0a018802 Author: Filipe Manana <fdmanana@suse.com> Date: Fri May 27 22:21:27 2016 +0100 Btrfs: fix race between device replace and read repair While we are finishing a device replace operation we can have a concurrent task trying to do a read repair operation, in which case it will call btrfs_map_block() to get a struct btrfs_bio which can have a stripe that points to the source device of the device replace operation. This allows for the read repair task to dereference the stripe's device pointer after the device replace operation has freed the source device, resulting in an invalid memory access. This is similar to the problem solved by my previous patch in the same series and named "Btrfs: fix race between device replace and discard". So fix this by surrounding the call to btrfs_map_block() and the code that uses the returned struct btrfs_bio with calls to btrfs_bio_counter_inc_blocked() and btrfs_bio_counter_dec(), giving the proper serialization with the finishing phase of the device replace operation. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/extent_io.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 2999241daa8d77947f108dfbde35c268cd7bd709 Author: Filipe Manana <fdmanana@suse.com> Date: Fri May 27 17:42:05 2016 +0100 Btrfs: fix race between device replace and discard While we are finishing a device replace operation, we can make a discard operation (fs mounted with -o discard) do an invalid memory access like the one reported by the following trace: [ 3206.384654] general protection fault: 0000 [#1] PREEMPT SMP [ 3206.387520] Modules linked in: dm_mod btrfs crc32c_generic xor raid6_pq acpi_cpufreq tpm_tis psmouse tpm ppdev sg parport_pc evdev i2c_piix4 parport processor serio_raw i2c_core pcspkr button loop autofs4 ext4 crc16 jbd2 mbcache sr_mod cdrom ata_generic sd_mod virtio_scsi ata_piix libata virtio_pci virtio_ring scsi_mod e1000 virtio floppy [last unloaded: btrfs] [ 3206.388595] CPU: 14 PID: 29194 Comm: fsstress Not tainted 4.6.0-rc7-btrfs-next-29+ #1 [ 3206.388595] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS by qemu-project.org 04/01/2014 [ 3206.388595] task: ffff88017ace0100 ti: ffff880171b98000 task.ti: ffff880171b98000 [ 3206.388595] RIP: 0010:[<ffffffff8124d233>] [<ffffffff8124d233>] blkdev_issue_discard+0x5c/0x2a7 [ 3206.388595] RSP: 0018:ffff880171b9bb80 EFLAGS: 00010246 [ 3206.388595] RAX: ffff880171b9bc28 RBX: 000000000090d000 RCX: 0000000000000000 [ 3206.388595] RDX: ffffffff82fa1b48 RSI: ffffffff8179f46c RDI: ffffffff82fa1b48 [ 3206.388595] RBP: ffff880171b9bcc0 R08: 0000000000000000 R09: 0000000000000001 [ 3206.388595] R10: ffff880171b9bce0 R11: 000000000090f000 R12: ffff880171b9bbe8 [ 3206.388595] R13: 0000000000000010 R14: 0000000000004868 R15: 6b6b6b6b6b6b6b6b [ 3206.388595] FS: 00007f6182e4e700(0000) GS:ffff88023fdc0000(0000) knlGS:0000000000000000 [ 3206.388595] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 3206.388595] CR2: 00007f617c2bbb18 CR3: 000000017ad9c000 CR4: 00000000000006e0 [ 3206.388595] Stack: [ 3206.388595] 0000000000004878 0000000000000000 0000000002400040 0000000000000000 [ 3206.388595] 0000000000000000 ffff880171b9bbe8 ffff880171b9bbb0 ffff880171b9bbb0 [ 3206.388595] ffff880171b9bbc0 ffff880171b9bbc0 ffff880171b9bbd0 ffff880171b9bbd0 [ 3206.388595] Call Trace: [ 3206.388595] [<ffffffffa042899e>] btrfs_issue_discard+0x12f/0x143 [btrfs] [ 3206.388595] [<ffffffffa042899e>] ? btrfs_issue_discard+0x12f/0x143 [btrfs] [ 3206.388595] [<ffffffffa042e862>] btrfs_discard_extent+0x87/0xde [btrfs] [ 3206.388595] [<ffffffffa04303b5>] btrfs_finish_extent_commit+0xb2/0x1df [btrfs] [ 3206.388595] [<ffffffff8149c246>] ? __mutex_unlock_slowpath+0x150/0x15b [ 3206.388595] [<ffffffffa04464c4>] btrfs_commit_transaction+0x7fc/0x980 [btrfs] [ 3206.388595] [<ffffffff8149c246>] ? __mutex_unlock_slowpath+0x150/0x15b [ 3206.388595] [<ffffffffa0459af6>] btrfs_sync_file+0x38f/0x428 [btrfs] [ 3206.388595] [<ffffffff811a8292>] vfs_fsync_range+0x8c/0x9e [ 3206.388595] [<ffffffff811a82c0>] vfs_fsync+0x1c/0x1e [ 3206.388595] [<ffffffff811a8417>] do_fsync+0x31/0x4a [ 3206.388595] [<ffffffff811a8637>] SyS_fsync+0x10/0x14 [ 3206.388595] [<ffffffff8149e025>] entry_SYSCALL_64_fastpath+0x18/0xa8 [ 3206.388595] [<ffffffff81100c6b>] ? time_hardirqs_off+0x9/0x14 [ 3206.388595] [<ffffffff8108e87d>] ? trace_hardirqs_off_caller+0x1f/0xaa This happens because when we call btrfs_map_block() from btrfs_discard_extent() to get a btrfs_bio structure, the device replace operation has not finished yet, but before we use the device of one of the stripes from the returned btrfs_bio structure, the device object is freed. This is illustrated by the following diagram. CPU 1 CPU 2 btrfs_dev_replace_start() (...) btrfs_dev_replace_finishing() btrfs_start_transaction() btrfs_commit_transaction() (...) btrfs_sync_file() btrfs_start_transaction() (...) btrfs_commit_transaction() btrfs_finish_extent_commit() btrfs_discard_extent() btrfs_map_block() --> returns a struct btrfs_bio with a stripe that has a device field pointing to source device of the replace operation (the device that is being replaced) mutex_lock(&uuid_mutex) mutex_lock(&fs_info->fs_devices->device_list_mutex) mutex_lock(&fs_info->chunk_mutex) btrfs_dev_replace_update_device_in_mapping_tree() --> iterates the mapping tree and for each extent map that has a stripe pointing to the source device, it updates the stripe to point to the target device instead btrfs_rm_dev_replace_blocked() --> waits for fs_info->bio_counter to go down to 0 btrfs_rm_dev_replace_remove_srcdev() --> removes source device from the list of devices mutex_unlock(&fs_info->chunk_mutex) mutex_unlock(&fs_info->fs_devices->device_list_mutex) mutex_unlock(&uuid_mutex) btrfs_rm_dev_replace_free_srcdev() --> frees the source device --> iterates over all stripes of the returned struct btrfs_bio --> for each stripe it dereferences its device pointer --> it ends up finding a pointer to the device used as the source device for the replace operation and that was already freed So fix this by surrounding the call to btrfs_map_block(), and the code that uses the returned struct btrfs_bio, with calls to btrfs_bio_counter_inc_blocked() and btrfs_bio_counter_dec(), so that the finishing phase of the device replace operation blocks until the the bio counter decreases to zero before it frees the source device. This is the same approach we do at btrfs_map_bio() for example. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/extent-tree.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 852f42a69b93dc71507adedeed876d57b8c2c2fa Merge: 4469854 bc9dc9d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 30 15:27:07 2016 -0700 Merge branch 'uuid' (lib/uuid fixes from Andy) Merge lib/uuid fixes from Andy Shevchenko. * emailed patches from Andy Shevchenko <andriy.shevchenko@linux.intel.com>: lib/uuid.c: use correct offset in uuid parser lib/uuid: add a test module commit bc9dc9d5eec908806f1b15c9ec2253d44dcf7835 Author: Bjørn Mork <bjorn@mork.no> Date: Mon May 30 17:40:42 2016 +0300 lib/uuid.c: use correct offset in uuid parser Use '+ 0' and '+ 1' as offsets, like they were intended, instead of adding to the result. Fixes: 2b1b0d66704a ("lib/uuid.c: introduce a few more generic helpers") Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/uuid.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cfaff0e515b544fa0a9cdc58a975cc629ff3bc17 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon May 30 17:40:41 2016 +0300 lib/uuid: add a test module It appears that somehow I missed a test of the latest UUID rework which landed in the kernel. Present a small test module to avoid such cases in the future. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/Kconfig.debug | 3 ++ lib/Makefile | 1 + lib/test_uuid.c | 133 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 137 insertions(+) commit 446985428d2cd10efd5d139c33de16c50ee771ba Merge: b02b1fb ab6a11a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 30 15:20:18 2016 -0700 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto fixes from Herbert Xu: "This fixes the following issues: - missing selection in public_key that may result in a build failure - Potential crash in error path in omap-sham - ccp AES XTS bug that affects requests larger than 4096" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: ccp - Fix AES XTS error for request sizes above 4096 crypto: public_key: select CRYPTO_AKCIPHER crypto: omap-sham - potential Oops on error in probe commit 4a3262b17c96b6ff332134c9e57f193a20226eb2 Author: Ilya Dryomov <idryomov@gmail.com> Date: Mon May 30 18:33:32 2016 +0200 libceph: use %s instead of %pE in dout()s Commit d30291b985d1 ("libceph: variable-sized ceph_object_id") changed dout()s in what is now encode_request() and ceph_object_locator_to_pg() to use %pE, mostly to document that, although all rbd and cephfs object names are NULL-terminated strings, ceph_object_id will handle any RADOS object name, including the one containing NULs, just fine. However, it turns out that vbin_printf() can't handle anything but ints and %s - all %p suffixes are ignored. The buffer %p** points to isn't recorded, resulting in trash in the messages if the buffer had been reused by the time bstr_printf() got to it. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 6 +++--- net/ceph/osdmap.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) commit dc045a9168c83b2dc590930a0565e066346de382 Author: Ilya Dryomov <idryomov@gmail.com> Date: Fri May 27 15:18:34 2016 +0200 libceph: put request only if it's done in handle_reply() handle_reply() may be called twice on the same request: on ack and then on commit. This occurs on btrfs-formatted OSDs or if cephfs sync write path is triggered - CEPH_OSD_FLAG_ACK | CEPH_OSD_FLAG_ONDISK. handle_reply() handles this with the help of done_request(). Fixes: 5aea3dcd5021 ("libceph: a major OSD client update") Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b7ec35b304b64af2830027350cc99d31e6e537c2 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:25 2016 +0200 libceph: change ceph_osdmap_flag() to take osdc For the benefit of every single caller, take osdc instead of map. Also, now that osdc->osdmap can't ever be NULL, drop the check. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/file.c | 8 ++++---- include/linux/ceph/osd_client.h | 5 +++++ include/linux/ceph/osdmap.h | 5 ----- net/ceph/osd_client.c | 39 +++++++++++++++++++-------------------- 4 files changed, 28 insertions(+), 29 deletions(-) commit 60f2b4b8af548150cc56bf6fd213e47897964794 Author: Vineet Gupta <vgupta@synopsys.com> Date: Mon May 30 19:21:22 2016 +0530 ARC: [intc-compact] simplify code for 2 priority levels ARC700 support for 2 interrupt priorities historically allowed even slow perpherals such as emac and uart to setup high priority interrupts which was wrong from the beginning as they could possibly delay the more critical timer interrupt. The hardware support for 2 level interrupts in ARCompact is less than ideal anyways (judging from the "hacks" in low level entry code and thus is not used in productions systems I know of. So reduce the scope of this to timer only, thereby reducing a bunch of complexity. Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 22 ++-------------------- arch/arc/kernel/entry-compact.S | 18 ++---------------- arch/arc/kernel/intc-compact.c | 6 ++---- 3 files changed, 6 insertions(+), 40 deletions(-) commit 99cf4b267e4863b95c7d33f59371b6ccdfd4a4ce Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed May 25 10:49:52 2016 -0300 ASoC: ak4613: Remove owner assignment from platform_driver This platform_driver does not need to set an owner as it will be populated by the driver core. Generated by scripts/coccinelle/api/platform_no_drv_owner.cocci. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/ak4613.c | 1 - 1 file changed, 1 deletion(-) commit 545ebd9a9be6bcbcf3e8dc24b874bfd634131946 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 30 17:11:59 2016 +0200 gpio: drop lock before reading GPIO direction When adding the gpiochip, the GPIO HW drivers' callback get_direction() could get called in atomic context. Some of the GPIO HW drivers may sleep when accessing the register. Move the lock before initializing the descriptors. Reported-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 54d77198fdfbc4f0fe11b4252c1d9c97d51a3264 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 30 16:48:39 2016 +0200 gpio: bail out silently on NULL descriptors In fdeb8e1547cb9dd39d5d7223b33f3565cf86c28e ("gpio: reflect base and ngpio into gpio_device") assumed that GPIO descriptors are either valid or error pointers, but gpiod_get_[index_]optional() actually return NULL descriptors and then all subsequent calls should just bail out. Cc: stable@vger.kernel.org Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: Andrew Lunn <andrew@lunn.ch> Fixes: fdeb8e1547cb ("gpio: reflect base and ngpio into gpio_device") Reported-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 62a584fe05eef1f80ed49a286a29328f1a224fb9 Author: Tejun Heo <tj@kernel.org> Date: Fri May 27 14:34:46 2016 -0400 writeback: use higher precision calculation in domain_dirty_limits() As vm.dirty_[background_]bytes can't be applied verbatim to multiple cgroup writeback domains, they get converted to percentages in domain_dirty_limits() and applied the same way as vm.dirty_[background]ratio. However, if the specified bytes is lower than 1% of available memory, the calculated ratios become zero and the writeback domain gets throttled constantly. Fix it by using per-PAGE_SIZE instead of percentage for ratio calculations. Also, the updated DIV_ROUND_UP() usages now should yield 1/4096 (0.0244%) as the minimum ratio as long as the specified bytes are above zero. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-by: Miao Xie <miaoxie@huawei.com> Link: http://lkml.kernel.org/g/57333E75.3080309@huawei.com Cc: stable@vger.kernel.org # v4.2+ Fixes: 9fc3a43e1757 ("writeback: separate out domain_dirty_limits()") Reviewed-by: Jan Kara <jack@suse.cz> Adjusted comment based on Jan's suggestion. Signed-off-by: Jens Axboe <axboe@fb.com> mm/page-writeback.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) commit 8b92e17efe029cc19f435f9fcbdfb1e7b9beb0ef Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri May 27 14:24:04 2016 +0200 gpio: handle compatible ioctl() pointers If we're using the compatible ioctl() we need to handle the argument pointer in a special way or there will be trouble. Fixes: 3c702e9987e2 ("gpio: add a userspace chardev ABI for GPIOs") Reported-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit 089f1c6b2daeab750fd92a28529928bc13c95d97 Author: Alex Williamson <alex.williamson@redhat.com> Date: Mon May 30 07:58:10 2016 -0600 vfio/type1: Fix build warning This function cannot actually be called with npage = 0, so in practice this doesn't return an uninitialized value. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/vfio_iommu_type1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 956b56a984ddf10aa69b25318dc04430101beed6 Author: Alex Williamson <alex.williamson@redhat.com> Date: Mon May 30 07:50:10 2016 -0600 vfio/pci: Fix ordering of eventfd vs virqfd shutdown Both the INTx and MSI/X disable paths do an eventfd_ctx_put() for the trigger eventfd before calling vfio_virqfd_disable() any potential mask and unmask eventfds. This opens a use-after-free race where an inopportune irqfd can reference the freed signalling eventfd. Reorder to avoid this possibility. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/pci/vfio_pci_intrs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6cacd115a8aafdc3f0f47c30af9d3a55a18074db Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Sun May 29 23:31:23 2016 -0700 cpufreq: intel_pstate: Downgrade print level for _PPC Downgrade pr_info to pr_debug for the "_PPC limits will be enforced" message. In server systems with many cores this message is annoying. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> [ rjw: Changelog ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 06061dc63bff8d609bc8d64f5d3ef59d0a673b25 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 14:49:53 2016 +0200 phy: exynos-mipi-video: avoid uninitialized variable use A rework of the exynos-mipi-video driver caused a warning about the new __set_phy_state function potentially accessing a variable before its initialization: drivers/phy/phy-exynos-mipi-video.c: In function '__set_phy_state': drivers/phy/phy-exynos-mipi-video.c:238:13: error: 'val' may be used uninitialized in this function [-Werror=maybe-uninitialized] return val & data->resetn_val; ~~~~^~~~~~~~~~~~~~~~~~ drivers/phy/phy-exynos-mipi-video.c:235:6: note: 'val' was declared here u32 val; The failure scenario here is the offset passed into a the stub regmap_read() function that does not modify its output, however regmap_read() can also fail for other reasons, so adding error handling (in this case, returning zero from is_running) seems the best solution. Note that this warning showed up with the ARM s5pv210_defconfig, indicating that we most likely want to either enable CONFIG_REGMAP in that defconfig as well, or disable the phy-exynos-mipi-video driver. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Fixes: 97a3042f7616 ("phy: exynos-mipi-video: Rewrite handling of phy registers") Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-exynos-mipi-video.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 6fbae35a3170c3e2b1b9d7b9cc943cbe48771362 Author: Kailang Yang <kailang@realtek.com> Date: Mon May 30 16:44:20 2016 +0800 ALSA: hda/realtek - Add support for new codecs ALC700/ALC701/ALC703 Support new codecs for ALC700/ALC701/ALC703. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit e69e7e03ed225abf3e1c43545aa3bcb68dc81d5f Author: Kailang Yang <kailang@realtek.com> Date: Mon May 30 15:58:28 2016 +0800 ALSA: hda/realtek - ALC256 speaker noise issue That is some different register for ALC255 and ALC256. ALC256 can't fit with some ALC255 register. This issue is cause from LDO output voltage control. This patch is updated the right LDO register value. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 52 ++++++++++++++++++++++++++++++++++++++----- 1 file changed, 47 insertions(+), 5 deletions(-) commit 22ab04e814f4fe2ce72a13d291491f98ef6ac757 Author: Filipe Manana <fdmanana@suse.com> Date: Wed May 18 20:29:44 2016 +0100 Btrfs: fix race between device replace and chunk allocation While iterating and copying extents from the source device, the device replace code keeps adjusting a left cursor that is used to make sure that once we finish processing a device extent, any future writes to extents from the corresponding block group will get into both the source and target devices. This left cursor is also used for resuming the device replace operation at mount time. However using this left cursor to decide whether writes go into both devices or only the source device is not enough to guarantee we don't miss copying extents into the target device. There are two cases where the current approach fails. The first one is related to when there are holes in the device and they get allocated for new block groups while the device replace operation is iterating the device extents (more on this explained below). The second one is that when that loop over the device extents finishes, we start dellaloc, wait for all ordered extents and then commit the current transaction, we might have got new block groups allocated that are now using a device extent that has an offset greater then or equals to the value of the left cursor, in which case writes to extents belonging to these new block groups will get issued only to the source device. For the first case where the current approach of using a left cursor fails, consider the source device currently has the following layout: [ extent bg A ] [ hole, unallocated space ] [extent bg B ] 3Gb 4Gb 5Gb While we are iterating the device extents from the source device using the commit root of the device tree, the following happens: CPU 1 CPU 2 <we are at transaction N> scrub_enumerate_chunks() --> searches the device tree for extents belonging to the source device using the device tree's commit root --> 1st iteration finds extent belonging to block group A --> sets block group A to RO mode (btrfs_inc_block_group_ro) --> sets cursor left to found_key.offset which is 3Gb --> scrub_chunk() starts copies all allocated extents from block group's A stripe at source device into target device btrfs_alloc_chunk() --> allocates device extent in the range [4Gb, 5Gb[ from the source device for a new block group C extent allocated from block group C for a direct IO, buffered write or btree node/leaf extent is written to, perhaps in response to a writepages() call from the VM or directly through direct IO the write is made only against the source device and not against the target device because the extent's offset is in the interval [4Gb, 5Gb[ which is larger then the value of cursor_left (3Gb) --> scrub_chunks() finishes --> updates left cursor from 3Gb to 4Gb --> btrfs_dec_block_group_ro() sets block group A back to RW mode <we are still at transaction N> --> 2nd iteration finds extent belonging to block group B - it did not find the new extent in the range [4Gb, 5Gb[ for block group C because we are using the device tree's commit root or even because the block group's items are not all yet inserted in the respective btrees, that is, the block group is still attached to some transaction handle's new_bgs list and btrfs_create_pending_block_groups() was not called yet against that transaction handle, so the device extent items were not yet inserted into the devices tree <we are still at transaction N> --> so we end not copying anything from the newly allocated device extent from the source device to the target device So fix this by making __btrfs_map_block() always redirect writes to the target device as well, independently of the left cursor's value. With this change the left cursor is now used only for the purpose of tracking progress and allow a mount operation to resume a device replace. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/volumes.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) commit 1a1a8b732c7e958e6eba0680439e814efde2362d Author: Filipe Manana <fdmanana@suse.com> Date: Sat May 14 19:44:40 2016 +0100 Btrfs: fix race setting block group back to RW mode during device replace After it finishes processing a device extent, the device replace code sets back the block group to RW mode and then after that it sets the left cursor to match the logical end address of the block group, so that future writes into extents belonging to the block group go both the source (old) and target (new) devices. However from the moment we turn the block group back to RW mode we have a short time window, that lasts until we update the left cursor's value, where extents can be allocated from the block group and written to, in which case they will not be copied/written to the target (new) device. Fix this by updating the left cursor's value before turning the block group back to RW mode. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/scrub.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 81e87a736c5581e83f52dc054b368993ec7f16d7 Author: Filipe Manana <fdmanana@suse.com> Date: Sat May 14 16:32:35 2016 +0100 Btrfs: fix unprotected assignment of the left cursor for device replace We were assigning new values to fields of the device replace object without holding the respective lock after processing each device extent. This is important for the left cursor field which can be accessed by a concurrent task running __btrfs_map_block (which, correctly, takes the device replace lock). So change these fields while holding the device replace lock. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/scrub.c | 4 ++++ 1 file changed, 4 insertions(+) commit f0e9b7d6401959816599191d1d9db90b6fd750db Author: Filipe Manana <fdmanana@suse.com> Date: Sat May 14 09:12:53 2016 +0100 Btrfs: fix race setting block group readonly during device replace When we do a device replace, for each device extent we find from the source device, we set the corresponding block group to readonly mode to prevent writes into it from happening while we are copying the device extent from the source to the target device. However just before we set the block group to readonly mode some concurrent task might have already allocated an extent from it or decided it could perform a nocow write into one of its extents, which can make the device replace process to miss copying an extent since it uses the extent tree's commit root to search for extents and only once it finishes searching for all extents belonging to the block group it does set the left cursor to the logical end address of the block group - this is a problem if the respective ordered extents finish while we are searching for extents using the extent tree's commit root and no transaction commit happens while we are iterating the tree, since it's the delayed references created by the ordered extents (when they complete) that insert the extent items into the extent tree (using the non-commit root of course). Example: CPU 1 CPU 2 btrfs_dev_replace_start() btrfs_scrub_dev() scrub_enumerate_chunks() --> finds device extent belonging to block group X <transaction N starts> starts buffered write against some inode writepages is run against that inode forcing dellaloc to run btrfs_writepages() extent_writepages() extent_write_cache_pages() __extent_writepage() writepage_delalloc() run_delalloc_range() cow_file_range() btrfs_reserve_extent() --> allocates an extent from block group X (which is not yet in RO mode) btrfs_add_ordered_extent() --> creates ordered extent Y flush_epd_write_bio() --> bio against the extent from block group X is submitted btrfs_inc_block_group_ro(bg X) --> sets block group X to readonly scrub_chunk(bg X) scrub_stripe(device extent from srcdev) --> keeps searching for extent items belonging to the block group using the extent tree's commit root --> it never blocks due to fs_info->scrub_pause_req as no one tries to commit transaction N --> copies all extents found from the source device into the target device --> finishes search loop bio completes ordered extent Y completes and creates delayed data reference which will add an extent item to the extent tree when run (typically at transaction commit time) --> so the task doing the scrub/device replace at CPU 1 misses this and does not copy this extent into the new/target device btrfs_dec_block_group_ro(bg X) --> turns block group X back to RW mode dev_replace->cursor_left is set to the logical end offset of block group X So fix this by waiting for all cow and nocow writes after setting a block group to readonly mode. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/ordered-data.c | 6 +++++- fs/btrfs/ordered-data.h | 2 +- fs/btrfs/scrub.c | 40 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 46 insertions(+), 2 deletions(-) commit 57ba4cb85bffc0c7c6567c89d23713721fea9655 Author: Filipe Manana <fdmanana@suse.com> Date: Fri May 20 04:34:23 2016 +0100 Btrfs: fix race between device replace and block group removal When it's finishing, the device replace code iterates all extent maps representing block group and for each one that has a stripe that refers to the source device, it replaces its device with the target device. However when it replaces the source device with the target device it, the target device still has an ID of 0ULL (BTRFS_DEV_REPLACE_DEVID), only after its ID is changed to match the one from the source device. This leads to races with the chunk removal code that can temporarly see a device with an ID of 0ULL and then attempt to use that ID to remove items from the device tree and fail, causing a transaction abort: [ 9238.594364] BTRFS info (device sdf): dev_replace from /dev/sdf (devid 3) to /dev/sde finished [ 9238.594377] ------------[ cut here ]------------ [ 9238.594402] WARNING: CPU: 14 PID: 21566 at fs/btrfs/volumes.c:2771 btrfs_remove_chunk+0x2e5/0x793 [btrfs] [ 9238.594403] BTRFS: Transaction aborted (error 1) [ 9238.594416] Modules linked in: btrfs crc32c_generic acpi_cpufreq xor tpm_tis tpm raid6_pq ppdev parport_pc processor psmouse parport i2c_piix4 evdev sg i2c_core se rio_raw pcspkr button loop autofs4 ext4 crc16 jbd2 mbcache sr_mod cdrom sd_mod ata_generic virtio_scsi ata_piix virtio_pci libata virtio_ring virtio e1000 scsi_mod fl oppy [last unloaded: btrfs] [ 9238.594418] CPU: 14 PID: 21566 Comm: btrfs-cleaner Not tainted 4.6.0-rc7-btrfs-next-29+ #1 [ 9238.594419] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS by qemu-project.org 04/01/2014 [ 9238.594421] 0000000000000000 ffff88017f1dbc60 ffffffff8126b42c ffff88017f1dbcb0 [ 9238.594422] 0000000000000000 ffff88017f1dbca0 ffffffff81052b14 00000ad37f1dbd18 [ 9238.594423] 0000000000000001 ffff88018068a558 ffff88005c4b9c00 ffff880233f60db0 [ 9238.594424] Call Trace: [ 9238.594428] [<ffffffff8126b42c>] dump_stack+0x67/0x90 [ 9238.594430] [<ffffffff81052b14>] __warn+0xc2/0xdd [ 9238.594432] [<ffffffff81052b7a>] warn_slowpath_fmt+0x4b/0x53 [ 9238.594434] [<ffffffff8116c311>] ? kmem_cache_free+0x128/0x188 [ 9238.594450] [<ffffffffa04d43f5>] btrfs_remove_chunk+0x2e5/0x793 [btrfs] [ 9238.594452] [<ffffffff8108e456>] ? arch_local_irq_save+0x9/0xc [ 9238.594464] [<ffffffffa04a26fa>] btrfs_delete_unused_bgs+0x317/0x382 [btrfs] [ 9238.594476] [<ffffffffa04a961d>] cleaner_kthread+0x1ad/0x1c7 [btrfs] [ 9238.594489] [<ffffffffa04a9470>] ? btree_invalidatepage+0x8e/0x8e [btrfs] [ 9238.594490] [<ffffffff8106f403>] kthread+0xd4/0xdc [ 9238.594494] [<ffffffff8149e242>] ret_from_fork+0x22/0x40 [ 9238.594495] [<ffffffff8106f32f>] ? kthread_stop+0x286/0x286 [ 9238.594496] ---[ end trace 183efbe50275f059 ]--- The sequence of steps leading to this is like the following: CPU 1 CPU 2 btrfs_dev_replace_finishing() at this point dev_replace->tgtdev->devid == BTRFS_DEV_REPLACE_DEVID (0ULL) ... btrfs_start_transaction() btrfs_commit_transaction() btrfs_delete_unused_bgs() btrfs_remove_chunk() looks up for the extent map corresponding to the chunk lock_chunks() (chunk_mutex) check_system_chunk() unlock_chunks() (chunk_mutex) locks fs_info->chunk_mutex btrfs_dev_replace_update_device_in_mapping_tree() --> iterates fs_info->mapping_tree and replaces the device in every extent map's map->stripes[] with dev_replace->tgtdev, which still has an id of 0ULL (BTRFS_DEV_REPLACE_DEVID) iterates over all stripes from the extent map --> calls btrfs_free_dev_extent() passing it the target device that still has an ID of 0ULL --> btrfs_free_dev_extent() fails --> aborts current transaction finishes setting up the target device, namely it sets tgtdev->devid to the value of srcdev->devid (which is necessarily > 0) frees the srcdev unlocks fs_info->chunk_mutex So fix this by taking the device list mutex while processing the stripes for the chunk's extent map. This is similar to the race between device replace and block group creation that was fixed by commit 50460e37186a ("Btrfs: fix race when finishing dev replace leading to transaction abort"). Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/volumes.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit ce7791ffee1e1ee9f97193b817c7dd1fa6746aad Author: Filipe Manana <fdmanana@suse.com> Date: Fri May 20 01:57:20 2016 +0100 Btrfs: fix race between readahead and device replace/removal The list of devices is protected by the device_list_mutex and the device replace code, in its finishing phase correctly takes that mutex before removing the source device from that list. However the readahead code was iterating that list without acquiring the respective mutex leading to crashes later on due to invalid memory accesses: [125671.831036] general protection fault: 0000 [#1] PREEMPT SMP [125671.832129] Modules linked in: btrfs dm_flakey dm_mod crc32c_generic xor raid6_pq acpi_cpufreq tpm_tis tpm ppdev evdev parport_pc psmouse sg parport processor ser [125671.834973] CPU: 10 PID: 19603 Comm: kworker/u32:19 Tainted: G W 4.6.0-rc7-btrfs-next-29+ #1 [125671.834973] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS by qemu-project.org 04/01/2014 [125671.834973] Workqueue: btrfs-readahead btrfs_readahead_helper [btrfs] [125671.834973] task: ffff8801ac520540 ti: ffff8801ac918000 task.ti: ffff8801ac918000 [125671.834973] RIP: 0010:[<ffffffff81270479>] [<ffffffff81270479>] __radix_tree_lookup+0x6a/0x105 [125671.834973] RSP: 0018:ffff8801ac91bc28 EFLAGS: 00010206 [125671.834973] RAX: 0000000000000000 RBX: 6b6b6b6b6b6b6b6a RCX: 0000000000000000 [125671.834973] RDX: 0000000000000000 RSI: 00000000000c1bff RDI: ffff88002ebd62a8 [125671.834973] RBP: ffff8801ac91bc70 R08: 0000000000000001 R09: 0000000000000000 [125671.834973] R10: ffff8801ac91bc70 R11: 0000000000000000 R12: ffff88002ebd62a8 [125671.834973] R13: 0000000000000000 R14: 0000000000000000 R15: 00000000000c1bff [125671.834973] FS: 0000000000000000(0000) GS:ffff88023fd40000(0000) knlGS:0000000000000000 [125671.834973] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [125671.834973] CR2: 000000000073cae4 CR3: 00000000b7723000 CR4: 00000000000006e0 [125671.834973] Stack: [125671.834973] 0000000000000000 ffff8801422d5600 ffff8802286bbc00 0000000000000000 [125671.834973] 0000000000000001 ffff8802286bbc00 00000000000c1bff 0000000000000000 [125671.834973] ffff88002e639eb8 ffff8801ac91bc80 ffffffff81270541 ffff8801ac91bcb0 [125671.834973] Call Trace: [125671.834973] [<ffffffff81270541>] radix_tree_lookup+0xd/0xf [125671.834973] [<ffffffffa04ae6a6>] reada_peer_zones_set_lock+0x3e/0x60 [btrfs] [125671.834973] [<ffffffffa04ae8b9>] reada_pick_zone+0x29/0x103 [btrfs] [125671.834973] [<ffffffffa04af42f>] reada_start_machine_worker+0x129/0x2d3 [btrfs] [125671.834973] [<ffffffffa04880be>] btrfs_scrubparity_helper+0x185/0x3aa [btrfs] [125671.834973] [<ffffffffa0488341>] btrfs_readahead_helper+0xe/0x10 [btrfs] [125671.834973] [<ffffffff81069691>] process_one_work+0x271/0x4e9 [125671.834973] [<ffffffff81069dda>] worker_thread+0x1eb/0x2c9 [125671.834973] [<ffffffff81069bef>] ? rescuer_thread+0x2b3/0x2b3 [125671.834973] [<ffffffff8106f403>] kthread+0xd4/0xdc [125671.834973] [<ffffffff8149e242>] ret_from_fork+0x22/0x40 [125671.834973] [<ffffffff8106f32f>] ? kthread_stop+0x286/0x286 So fix this by taking the device_list_mutex in the readahead code. We can't use here the lighter approach of using a rcu_read_lock() and rcu_read_unlock() pair together with a list_for_each_entry_rcu() call because we end up doing calls to sleeping functions (kzalloc()) in the respective code path. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/reada.c | 2 ++ 1 file changed, 2 insertions(+) commit 9f9cd7ee2c05881f151e5ee4889e667a031dd8d9 Author: Aaron Lu <aaron.lu@intel.com> Date: Sat May 21 15:30:46 2016 +0800 ACPI / Thermal / video: fix max_level incorrect value commit 059500940def (ACPI/video: export acpi_video_get_levels) mistakenly dropped the correct value of max_level and that caused the set_level function following failed and the acpi_video backlight interface didn't get created. Fix this by passing back the correct max_level value. While at it, also fix the param used in acpi_video_device_lcd_query_levels where acpi_handle is expected but acpi_video_device is passed. Fixes: 059500940def (ACPI/video: export acpi_video_get_levels) Reported-and-tested-by: Valdis Kletnieks <valdis.kletnieks@vt.edu> Signed-off-by: Aaron Lu <aaron.lu@intel.com> Acked-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpi_video.c | 9 ++++++--- drivers/thermal/int340x_thermal/int3406_thermal.c | 2 +- include/acpi/video.h | 6 ++++-- 3 files changed, 11 insertions(+), 6 deletions(-) commit 1691cf160048c0753036d0b3fad7f239234dab56 Author: Vinson Lee <vlee@freedesktop.org> Date: Sat May 28 07:04:38 2016 +0000 btrfs: Use __u64 in exported linux/btrfs.h. This patch fixes this build error. /usr/include/linux/btrfs.h:121:3: error: unknown type name ‘u64’ u64 devid; ^~~ Fixes: 6b526ed70cf1 ("btrfs: introduce device delete by devid") Signed-off-by: Vinson Lee <vlee@freedesktop.org> Signed-off-by: David Sterba <dsterba@suse.com> include/uapi/linux/btrfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eaa2bcd6d1d410a52df8c7b05e76d86c0319b7b0 Author: Phil Turnbull <phil.turnbull@oracle.com> Date: Fri May 27 13:34:04 2016 -0400 netfilter: nf_tables: validate NFTA_SET_TABLE parameter If the NFTA_SET_TABLE parameter is missing and the NLM_F_DUMP flag is not set, then a NULL pointer dereference is triggered in nf_tables_set_lookup because ctx.table is NULL. Signed-off-by: Phil Turnbull <phil.turnbull@oracle.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_tables_api.c | 2 ++ 1 file changed, 2 insertions(+) commit 83170f3beccccd7ceb4f9a0ac0c4dc736afde90c Author: Paolo Abeni <pabeni@redhat.com> Date: Thu May 26 19:08:10 2016 +0200 netfilter: nf_dup_ipv6: set again FLOWI_FLAG_KNOWN_NH at flowi6_flags With the commit 48e8aa6e3137 ("ipv6: Set FLOWI_FLAG_KNOWN_NH at flowi6_flags") ip6_pol_route() callers were asked to to set the FLOWI_FLAG_KNOWN_NH properly and xt_TEE was updated accordingly, but with the later refactor in commit bbde9fc1824a ("netfilter: factor out packet duplication for IPv4/IPv6") the flowi6_flags update was lost. This commit re-add it just before the routing decision. Fixes: bbde9fc1824a ("netfilter: factor out packet duplication for IPv4/IPv6") Signed-off-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv6/netfilter/nf_dup_ipv6.c | 1 + 1 file changed, 1 insertion(+) commit b7a8daa9f3d1688e994f5557577d3252c94ec282 Author: Taehee Yoo <ap420073@gmail.com> Date: Sat May 14 22:19:53 2016 +0900 netfilter: nf_ct_helper: Fix helper unregister count. helpers should unregister the only registered ports. but, helper cannot have correct registered ports value when failed to register. Signed-off-by: Taehee Yoo <ap420073@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_ftp.c | 1 + net/netfilter/nf_conntrack_irc.c | 1 + net/netfilter/nf_conntrack_sane.c | 1 + net/netfilter/nf_conntrack_sip.c | 1 + net/netfilter/nf_conntrack_tftp.c | 1 + 5 files changed, 5 insertions(+) commit 9feeed94d0a8f2586f15490c8e31e1e0954fc290 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:06:13 2016 +0200 MAINTAINERS: Add file patterns for pinctrl device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: linux-gpio@vger.kernel.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 6b1a7c9ecde434adb515e1c9a89a579a6feb3070 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue May 24 14:39:47 2016 +0200 pinctrl: nomadik: fix inversion of gpio direction The input/output directions were inversed on the GPIO direction read function. Loose a ! and it is correct. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/nomadik/pinctrl-nomadik.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9c10280d85c14a20751ab6c1185ad725172936d6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed May 25 10:56:03 2016 +0200 gpio: flush direction status in gpiochip_lock_as_irq() As irqchip and gpiochip functions are orthogonal, the IRQ set-up or something else can have changed the direction of the GPIO line from what the GPIO descriptor knows when we get into gpiochip_lock_as_irq(). Make sure to re-read the direction setting if we have the .get_direction() callback enabled for the chip. Else we get problems like this: iio iio:device2: interrupts on the rising edge gpio gpiochip2: (8012e080.gpio): gpiochip_lock_as_irq: tried to flag a GPIO set as output for IRQ gpio gpiochip2: (8012e080.gpio): unable to lock HW IRQ 0 for IRQ genirq: Failed to request resources for l3g4200d-trigger (irq 111) on irqchip nmk1-32-63 iio iio:device2: failed to request trigger IRQ. st-gyro-i2c: probe of 2-0068 failed with error -22 Fixes: 72d320006177 ("gpio: set up initial state from .get_direction()") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) commit 320a6480ef24b03655e1854bd01c9b0a8b8d4a3f Author: Sylvain Lemieux <slemieux@tycoint.com> Date: Wed May 11 13:40:00 2016 -0400 gpio: lpc32xx: disable broken to_irq support The "to_irq" functionality is broken inside this driver since commit 76ba59f8366f ("genirq: Add irq_domain-aware core IRQ handler"). The addition of the new lpc32xx irqchip driver in 4.7, fixed the lpc32xx platform interrupt issue. When switching to the new lpc32xx irqchip driver, a warning appear in the lpc32xx gpio driver: warning: "NR_IRQS" redefined. To remove this warning (temporary solution), this patch disables the broken "to_irq" mapping functionality support. Signed-off-by: Sylvain Lemieux <slemieux@tycoint.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-lpc32xx.c | 48 +-------------------------------------------- 1 file changed, 1 insertion(+), 47 deletions(-) commit 3183c0d519ff83af2926382c11716496f01d34bf Author: Xing Zheng <zhengxing@rock-chips.com> Date: Thu May 26 21:49:08 2016 +0800 clk: rockchip: fix cpuclk registration error handling It maybe due to a copy-paste error the error handing should be cclk not clk when checking if the cpuclk registration succeeded. Reported-by: Lin Huang <lin.huang@rock-chips.com> Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-cpu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4715f81afc342996f680b08c944a712d9cbef11b Author: Douglas Anderson <dianders@chromium.org> Date: Thu May 12 11:03:16 2016 -0700 clk: rockchip: Revert "clk: rockchip: reset init state before mmc card initialization" This reverts commit 7a03fe6f48f3 ("clk: rockchip: reset init state before mmc card initialization"). Though not totally obvious from the commit message nor from the source code, that commit appears to be trying to reset the "_drv" MMC clocks to 90 degrees (note that the "_sample" MMC clocks have a shift of 0 so are not touched). The major problem here is that it doesn't properly reset things. The phase is a two bit field and the commit only touches one of the two bits. Thus the commit had the following affect: - phase 0 => phase 90 - phase 90 => phase 90 - phase 180 => phase 270 - phase 270 => phase 270 Things get even weirder if you happen to have a bootloader that was actually using delay elements (should be no reason to, but you never know), since those are additional bits that weren't touched by the original patch. This is unlikely to be what we actually want. Checking on rk3288-veyron devices, I can see that the bootloader leaves these clocks as: - emmc: phase 180 - sdmmc: phase 90 - sdio0: phase 90 Thus on rk3288-veyron devices the commit we're reverting had the effect of changing the eMMC clock to phase 270. This probably explains the scattered reports I've heard of eMMC devices not working on some veyron devices when using the upstream kernel. The original commit was presumably made because previously the kernel didn't touch the "_drv" phase at all and relied on whatever value was there when the kernel started. If someone was using a bootloader that touched the "_drv" phase then, indeed, we should have code in the kernel to fix that. ...and also, to get ideal timings, we should also have the kernel change the phase depending on the speed mode. In fact, that's the subject of a recent patch I posted at <https://patchwork.kernel.org/patch/9075141/>. Ideally, we should take both the patch posted to dw_mmc and this revert. Since those will likely go through different trees, here I describe behavior with the combos: 1. Just this revert: likely will fix rk3288-veyron eMMC on some devices + other cases; might break someone with a strange bootloader that sets the phase to 0 or one that uses delay elements (pretty unpredicable what would happen in that case). 2. Just dw_mmc patch: fixes everyone. Effectly the dw_mmc patch will totally override the broken patch and fix everything. 3. Both patches: fixes everyone. Once dw_mmc is initting properly then any defaults from the clock code doesn't mattery. Fixes: 7a03fe6f48f3 ("clk: rockchip: reset init state before mmc card initialization") Signed-off-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com> [emmc and sdmmc still work on all current boards in mainline after this revert, so they should take precedence over any out-of-tree board that will hopefully again get fixed with the better upcoming dw_mmc change.] Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-mmc-phase.c | 11 ----------- 1 file changed, 11 deletions(-) commit 3bd14ae9da9194d369334556a70a7ff73ef94491 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Fri May 13 11:42:17 2016 -0700 clk: rockchip: fix incorrect parent for rk3399's {c,g}pll_aclk_perihp_src There was a typo, swapping 'c' <--> 'g'. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Brian Norris <briannorris@chromium.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 176df69cb080c8cd813e51f800069e13ee607641 Author: Brian Norris <briannorris@chromium.org> Date: Fri May 13 11:42:16 2016 -0700 clk: rockchip: mark rk3399 GIC clocks as critical We never want to kill the GIC. Noticed when making other clock fixups, and seeing the newly-constructed clock tree try to disable cpll, where we had this parent structure: aclk_gic <------\ |--- aclk_gic_pre <-- cpll <-- pll_cpll aclk_gic_noc <--/ Signed-off-by: Brian Norris <briannorris@chromium.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 2 ++ 1 file changed, 2 insertions(+) commit 595144c1141c951a3c6bb9004ae6a2bc29aad66f Author: Heiko Stuebner <heiko@sntech.de> Date: Tue May 17 20:57:50 2016 +0200 clk: rockchip: initialize flags of clk_init_data in mmc-phase clock The flags element of clk_init_data was never initialized for mmc- phase-clocks resulting in the element containing a random value and thus possibly enabling unwanted clock flags. Fixes: 89bf26cbc1a0 ("clk: rockchip: Add support for the mmc clock phases using the framework") Cc: stable@vger.kernel.org Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-mmc-phase.c | 1 + 1 file changed, 1 insertion(+) commit 151787ba0562fd70e7b669a1b5a398875e4fc8e7 Author: Liu Ying <gnuiyl@gmail.com> Date: Tue May 24 18:10:41 2016 +0800 drm/imx: plane: Don't set plane->crtc in ipu_plane_update() Since the drm core sets plane->crtc correctly, we don't need to do that. Signed-off-by: Liu Ying <gnuiyl@gmail.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/ipuv3-plane.c | 1 - 1 file changed, 1 deletion(-) commit 8b3ce87377dfd462c7300a1e8aa8c2c1966716c7 Author: Liu Ying <gnuiyl@gmail.com> Date: Tue May 24 18:10:40 2016 +0800 drm/imx: ipuv3-plane: Constify ipu_plane_funcs Signed-off-by: Liu Ying <gnuiyl@gmail.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/ipuv3-plane.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c82b4d73e2cd32fff41be0cd6e75ea83d32943b3 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue May 24 08:31:49 2016 +0200 drm/imx: imx-ldb: honor 'native-mode' property when selecting video mode from DT This patch allows to select a specific video mode from a list of modes defined in DT by setting the 'native-mode' property appropriately. This change does not affect the behaviour of existing platforms, since they either: - have just one display-timings subnode - have the native-mode property pointing to the first entry - let the bootloader select the appropriate timing Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/imx-ldb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 97a6075d7cfabd0d45f8667a89da2a5fd13b4e70 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue May 24 08:31:51 2016 +0200 drm/imx: parallel-display: remove dead code The 'mode_valid' flag is never set in this driver. Remove it and the code that depends on it. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/parallel-display.c | 12 ------------ 1 file changed, 12 deletions(-) commit 4ed094fd73a7c0b8534685d2ed0f0f3ccdb96bdf Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Mon May 9 17:02:13 2016 +0200 drm/imx: use bus_flags for pixel clock polarity This patch allows panels to set pixel clock and data enable pin polarity other than the default of driving data at the falling pixel clock edge and active high display enable. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/imx-drm-core.c | 13 ++++++++----- drivers/gpu/drm/imx/imx-drm.h | 7 ++++--- drivers/gpu/drm/imx/imx-tve.c | 6 ++++-- drivers/gpu/drm/imx/ipuv3-crtc.c | 10 +++++++--- drivers/gpu/drm/imx/parallel-display.c | 4 ++-- 5 files changed, 25 insertions(+), 15 deletions(-) commit 7932131f6381e5d2d4a78d9134f5f6bf45900ae5 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Fri Feb 12 14:35:55 2016 +0100 drm/imx: ipuv3-plane: enable UYVY and VYUY formats Advertise the DRM_FORMAT_UYVY and DRM_FORMAT_VYUY formats to userspace. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/ipuv3-plane.c | 2 ++ 1 file changed, 2 insertions(+) commit 3a1c117f8bf13435f6db78f294d5754b2eb6185b Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Tue May 3 14:39:29 2016 +0200 drm/imx: parallel-display: use of_graph_get_endpoint_by_regs helper Instead of using of_graph_get_port_by_id() to get the port and then of_get_child_by_name() to get the first endpoint, get to the endpoint in a single step. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/parallel-display.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit 620011e0477e485fc6112ace3c0a772130e8fd4f Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Tue May 3 14:37:13 2016 +0200 drm/imx: imx-ldb: use of_graph_get_endpoint_by_regs helper Instead of using of_graph_get_port_by_id() to get the port and then of_get_child_by_name() to get the first endpoint, get to the endpoint in a single step. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/imx-ldb.c | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) commit ee89686631174fa576e61400ac3580722edac120 Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Wed Apr 27 16:23:34 2016 -0400 dt-bindings: imx: ldb: Add ddc-i2c-bus property Document the ddc-i2c-bus property used by imx-ldb driver to read EDID information via I2C interface. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Documentation/devicetree/bindings/display/imx/ldb.txt | 1 + 1 file changed, 1 insertion(+) commit a6d206e28abe468aac5bb589669c6beb855b1a66 Author: Steve Longerbeam <steve_longerbeam@mentor.com> Date: Wed Apr 27 16:23:33 2016 -0400 drm/imx: imx-ldb: Add DDC support Add support for reading EDID over Display Data Channel. If no DDC adapter is available, falls back to hardcoded EDID or display-timings node as before. Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com> Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/imx/imx-ldb.c | 42 ++++++++++++++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 8 deletions(-) commit 0e6b5259824e97a0f7e7b450421ff12865d3b0e2 Author: Shmulik Ladkani <shmulik.ladkani@gmail.com> Date: Thu May 26 20:16:36 2016 +0300 net: l2tp: Make l2tp_ip6 namespace aware l2tp_ip6 tunnel and session lookups were still using init_net, although the l2tp core infrastructure already supports lookups keyed by 'net'. As a result, l2tp_ip6_recv discarded packets for tunnels/sessions created in namespaces other than the init_net. Fix, by using dev_net(skb->dev) or sock_net(sk) where appropriate. Signed-off-by: Shmulik Ladkani <shmulik.ladkani@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/l2tp/l2tp_ip6.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 13fef095bde04228316046f997eb963285d8532e Author: Chen-Yu Tsai <wens@csie.org> Date: Tue May 17 23:56:06 2016 +0800 drm: sun4i: do cleanup if RGB output init fails sun4i_rgb_init() can fail, which results in TCON failing to bind. In this case we need to do cleanup, specificly unregistering the dotclock, which is regmap based, and the regmap is registered as part of the sun4i_tcon_bind(). Failing to do so results in a NULL pointer reference when the CCF tries to turn off unused clocks. Fixes: 29e57fab97fc ("drm: sun4i: Add RGB output") Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_tcon.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 7aa2e2b731b337a7bc74cd076bbcd6b8b4b95fbf Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed May 11 19:04:18 2016 +0200 drm/sun4i: Convert to connector register helpers Now that connector register helpers have been created, switch to them. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_drv.c | 31 ++----------------------------- 1 file changed, 2 insertions(+), 29 deletions(-) commit 3d6bd9065b7acf8499d414d70bdb4b4955856299 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed May 11 16:52:50 2016 +0200 drm/sun4i: remove simplefb at probe If simplefb was setup by our bootloader and enabled in the DT, we will have a first framebuffer loaded in our system. However, as soon as our DRM driver will load, it will reset the controller, initialise it and, if the framebuffer emulation is enabled, register a second framebuffer device. This is obviously pretty bad, since the first framebuffer will be some kind of a black hole, with memory still reserved that we can write to safely, but not displayed anywhere. Make sure we remove that framebuffer when we probe so we don't end up in that situation. Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_drv.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 0de6e914a035076b1241f5738c06c9d3820abd6e Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed May 4 17:37:58 2016 +0200 drm/sun4i: rgb: panel is an error pointer In case of an error, our pointer to the drm_panel structure attached to our encoder will hold an error pointer, not a NULL pointer. Make sure we check the right thing. Fixes: 29e57fab97fc ("drm: sun4i: Add RGB output") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_rgb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0bbbb00bda57e6f091275b0103445596322b9277 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed May 4 17:38:32 2016 +0200 drm/sun4i: defer only if we didn't find our panel Our code currently defers our probe on any error, even if we were not expecting to have one at all. Make sure we return -EPROBE_DEFER only when we were supposed to have a panel, but it's not probed yet. Also fix a typo while we're at it. Fixes: 29e57fab97fc ("drm: sun4i: Add RGB output") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_tcon.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit bb43d40d7c830da5f623e3938fef908b003b7523 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Apr 21 11:25:26 2016 +0200 drm/sun4i: rgb: Validate the clock rate Our pixel clock cannot reach a high enough rate for some rather high while common resolutions (like 1080p60). Make sure we filter the resolutions we cannot reach in our mode_valid function. Fixes: 29e57fab97fc ("drm: sun4i: Add RGB output") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_rgb.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 4731a72df273bdbd225445424057c15dbb8d3495 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Sat Apr 2 12:30:11 2016 +0200 drm/sun4i: request exact rates to our parents Our pixel clock currently only tries to deal with the current parent rate. While that works when the resolution is the same than the one already program, or when we can compute directly the rate from the current parent rate, it cannot work in most situation when we want to change the frequency, and we end up with an improper pixel clock rate, which obviously doesn't work as expected. Ask our parent for all the possible dividers if it can reach that frequency, and return the best parent rate to the clock framework so that we can use it. Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_dotclock.c | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) commit 9fa2568d9fe0c6dbf3253af6840de9389f4e89cb Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 5 22:10:52 2016 +0200 drm: sun4i: fix probe error handling gcc points out a possible uninitialized variable use in sun4i_dclk_create(): drivers/gpu/drm/sun4i/sun4i_dotclock.c: In function 'sun4i_dclk_create': drivers/gpu/drm/sun4i/sun4i_dotclock.c:139:12: error: 'clk_name' may be used uninitialized in this function [-Werror=maybe-uninitialized] init.name = clk_name; The warning only shows up when CONFIG_OF is disabled, and the property is never filled, but the same bug can show up even when CONFIG_OF is enabled but of_property_read_string_index returns another error. To fix it, this ensures that sun4i_dclk_create propagates any error from of_property_read_string_index. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_dotclock.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit f1b78f0e759b174ec4f5e3b0dd27a079a2416b66 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:23:28 2016 +0200 drm: sun4i: print DMA address correctly The newly added sun4i drm driver prints a dma address using the %x format string, which cannot work when dma_addr_t is 64 bit, and gcc warns about this configuration: drm/sun4i/sun4i_backend.c: In function 'sun4i_backend_update_layer_buffer': drm/sun4i/sun4i_backend.c:193:84: error: format '%x' expects argument of type 'unsigned int', but argument 3 has type 'dma_addr_t {aka long long unsigned int}' [-Werror=format=] DRM_DEBUG_DRIVER("Using GEM @ 0x%x\n", gem->paddr); drm/sun4i/sun4i_backend.c:201:84: error: format '%x' expects argument of type 'unsigned int', but argument 3 has type 'dma_addr_t {aka long long unsigned int}' [-Werror=format=] DRM_DEBUG_DRIVER("Setting buffer address to 0x%x\n", paddr); This changes the code to use the explicit %pad format string, which always prints the right length. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_backend.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit bebef39842c8615180e711c0ff3e8c9c40c397da Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 2 12:59:48 2016 +0200 drm/sun4i: add COMMON_CLK dependency The sun4i drm driver uses the clk-provider interfaces, which are not available when CONFIG_COMMON_CLK is disabled: drivers/gpu/drm/sun4i/sun4i_dotclock.c:19:16: error: field 'hw' has incomplete type struct clk_hw hw; In file included from ../include/asm-generic/bug.h:13:0, from ../arch/arm/include/asm/bug.h:59, from ../include/linux/bug.h:4, from ../include/linux/io.h:23, from ../include/linux/clk-provider.h:14, from ../drivers/gpu/drm/sun4i/sun4i_dotclock.c:13: drivers/gpu/drm/sun4i/sun4i_dotclock.c: In function 'hw_to_dclk': include/linux/kernel.h:831:48: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types] ... This adds a Kconfig dependency to prevent the driver from being enabled in this case. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 176b346b37f0b9c03e91eb6f1460e00f3c0c3edf Author: Eric Garver <e@erig.me> Date: Thu May 26 12:28:05 2016 -0400 Documentation: ip-sysctl.txt: clarify secure_redirects Clarify how secure_redirects works. Mention that RFC1122 always applies. Signed-off-by: Eric Garver <e@erig.me> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/ip-sysctl.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 68bb399e656f244d3d173a20a8280c167632fca8 Author: Edward Cree <ecree@solarflare.com> Date: Thu May 26 21:46:05 2016 +0100 sfc: use flow dissector helpers for aRFS Signed-off-by: Edward Cree <ecree@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/sfc/rx.c | 75 ++++++++++++------------------------------- 1 file changed, 21 insertions(+), 54 deletions(-) commit 421eeea10d0a5e52256bce9544de477938104fdb Author: Baozeng Ding <sploving1@gmail.com> Date: Thu May 26 21:07:42 2016 +0800 ieee802154: fix logic error in ieee802154_llsec_parse_dev_addr Fix a logic error to avoid potential null pointer dereference. Signed-off-by: Baozeng Ding <sploving1@gmail.com> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ieee802154/nl802154.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 86651650d16a359e4142c6a8b0467c87e48c4c94 Author: Elad Kanfi <eladkan@mellanox.com> Date: Thu May 26 15:00:06 2016 +0300 net: nps_enet: Disable interrupts before napi reschedule Since NAPI works by shutting down event interrupts when theres work and turning them on when theres none, the net driver must make sure that interrupts are disabled when it reschedules polling. By calling napi_reschedule, the driver switches to polling mode, therefor there should be no interrupt interference. Any received packets will be handled in nps_enet_poll by polling the HW indication of received packet until all packets are handled. Signed-off-by: Elad Kanfi <eladkan@mellanox.com> Acked-by: Noam Camus <noamca@mellanox.com> Tested-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ezchip/nps_enet.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 0d08df6c493898e679d9c517e77ea95c063d40ec Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Thu May 26 14:43:52 2016 +0300 net/lapb: tuse %*ph to dump buffers Use %*ph specifier to dump small buffers in hex format instead doing this byte-by-byte. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/lapb/lapb_in.c | 5 ++--- net/lapb/lapb_out.c | 4 +--- net/lapb/lapb_subr.c | 14 +++++--------- 3 files changed, 8 insertions(+), 15 deletions(-) commit 6756325a9a1e2d36b6210f4a42f77501c917ebb9 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 26 09:46:22 2016 +0300 ptp: oops in ptp_ioctl() If we pass ERR_PTR(-EFAULT) to kfree() then it's going to oops. Fixes: 2ece068e1b1d ('ptp: use memdup_user().') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Richard Cochran <richardcochran@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/ptp/ptp_chardev.c | 1 + 1 file changed, 1 insertion(+) commit fabb13db448efc23c47851550867fc46519de97e Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 25 16:50:46 2016 +0200 fou: add Kconfig options for IPv6 support A previous patch added the fou6.ko module, but that failed to link in a couple of configurations: net/built-in.o: In function `ip6_tnl_encap_add_fou_ops': net/ipv6/fou6.c:88: undefined reference to `ip6_tnl_encap_add_ops' net/ipv6/fou6.c:94: undefined reference to `ip6_tnl_encap_add_ops' net/ipv6/fou6.c:97: undefined reference to `ip6_tnl_encap_del_ops' net/built-in.o: In function `ip6_tnl_encap_del_fou_ops': net/ipv6/fou6.c:106: undefined reference to `ip6_tnl_encap_del_ops' net/ipv6/fou6.c:107: undefined reference to `ip6_tnl_encap_del_ops' If CONFIG_IPV6=m, ip6_tnl_encap_add_ops/ip6_tnl_encap_del_ops are in a module, but fou6.c can still be built-in, and that obviously fails to link. Also, if CONFIG_IPV6=y, but CONFIG_IPV6_TUNNEL=m or CONFIG_IPV6_TUNNEL=n, the same problem happens for a different reason. This adds two new silent Kconfig symbols to work around both problems: - CONFIG_IPV6_FOU is now always set to 'm' if either CONFIG_NET_FOU=m or CONFIG_IPV6=m - CONFIG_IPV6_FOU_TUNNEL is set implicitly when IPV6_FOU is enabled and NET_FOU_IP_TUNNELS is also turned out, and it will ensure that CONFIG_IPV6_TUNNEL is also available. The options could be made user-visible as well, to give additional room for configuration, but it seems easier not to bother users with more choice here. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: aa3463d65e7b ("fou: Add encap ops for IPv6 tunnels") Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/Kconfig | 9 +++++++++ net/ipv6/Makefile | 2 +- net/ipv6/fou6.c | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) commit 9791d8e7627d1c4dbf8819646833f2f576b4f8f3 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 25 16:50:45 2016 +0200 ipv6: hide ip6_encap_hlen/ip6_tnl_encap definitions A recent cleanup moved MAX_IPTUN_ENCAP_OPS along with some other definitions, but it is now invisible when CONFIG_INET is not defined, but still referenced from ip6_tunnel.h: In file included from net/xfrm/xfrm_input.c:17:0: include/net/ip6_tunnel.h:67:17: error: 'MAX_IPTUN_ENCAP_OPS' undeclared here (not in a function) ip6tun_encaps[MAX_IPTUN_ENCAP_OPS]; ^~~~~~~~~~~~~~~~~~~ This hides the ip6_encap_hlen and ip6_tnl_encap functions inside of CONFIG_INET so we don't run into the the problem. Alternatively we could move the macro out of the #ifdef again to restore the previous behavior Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 55c2bc143224 ("net: Cleanup encap items in ip_tunnels.h") Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip6_tunnel.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9295c41d77ca93aac79cfca6fa09fa1ca5cab66f Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu May 12 16:54:10 2016 +0200 dmaengine: at_xdmac: double FIFO flush needed to compute residue Due to the way CUBC register is updated, a double flush is needed to compute an accurate residue. First flush aim is to get data from the DMA FIFO and second one ensures that we won't report data which are not in memory. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Fixes: e1f7c9eee707 ("dmaengine: at_xdmac: creation of the atmel eXtended DMA Controller driver") Cc: stable@vger.kernel.org #v4.1 and later Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/at_xdmac.c | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) commit 53398f488821c2b5b15291e3debec6ad33f75d3d Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu May 12 16:54:09 2016 +0200 dmaengine: at_xdmac: fix residue corruption An unexpected value of CUBC can lead to a corrupted residue. A more complex sequence is needed to detect an inaccurate value for NCA or CUBC. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Fixes: e1f7c9eee707 ("dmaengine: at_xdmac: creation of the atmel eXtended DMA Controller driver") Cc: stable@vger.kernel.org #v4.1 and later Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/at_xdmac.c | 54 ++++++++++++++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 22 deletions(-) commit 4a9723e8df68cfce4048517ee32e37f78854b6fb Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu May 12 16:54:08 2016 +0200 dmaengine: at_xdmac: align descriptors on 64 bits Having descriptors aligned on 64 bits allows update CNDA and CUBC in an atomic way. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Fixes: e1f7c9eee707 ("dmaengine: at_xdmac: creation of the atmel eXtended DMA Controller driver") Cc: stable@vger.kernel.org #v4.1 and later Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/at_xdmac.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c56d329e28cff2d7a1e77cafc2f9c7e986ba11cb Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:05:52 2016 +0200 MAINTAINERS: Add file patterns for dma device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Vinod Koul <vinod.koul@intel.com> Cc: dmaengine@vger.kernel.org Signed-off-by: Vinod Koul <vinod.koul@intel.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 49acadff2a0cb4f7ff4efe0fb6c23f5fad81a3b3 Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Wed May 25 15:11:29 2016 +0300 arc: Get rid of root core-frequency property Now when we switched to usage of real clk devices for CPU core frequency those root properties make no sense any longer. Se we're just getting rid of them here to not confuse readers of our .dts files. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Christian Ruppert <christian.ruppert@alitech.com> Cc: Noam Camus <noamca@mellanox.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/boot/dts/abilis_tb100.dtsi | 2 -- arch/arc/boot/dts/abilis_tb101.dtsi | 2 -- arch/arc/boot/dts/axc001.dtsi | 1 - arch/arc/boot/dts/axc003.dtsi | 1 - arch/arc/boot/dts/axc003_idu.dtsi | 1 - arch/arc/boot/dts/eznps.dts | 1 - arch/arc/boot/dts/nsim_700.dts | 1 - arch/arc/boot/dts/nsimosci.dts | 1 - arch/arc/boot/dts/nsimosci_hs.dts | 1 - arch/arc/boot/dts/nsimosci_hs_idu.dts | 1 - arch/arc/boot/dts/skeleton.dtsi | 1 - arch/arc/boot/dts/skeleton_hs.dtsi | 1 - arch/arc/boot/dts/skeleton_hs_idu.dtsi | 1 - arch/arc/boot/dts/vdk_axc003.dtsi | 1 - arch/arc/boot/dts/vdk_axc003_idu.dtsi | 1 - 15 files changed, 17 deletions(-) commit 2547476a5e4061f6addb88d5fc837d3a950f54c4 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 13:45:35 2016 +0200 Fix typos Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Makefile | 2 +- arch/arc/include/asm/entry-compact.h | 4 ++-- arch/arc/include/asm/mmu_context.h | 2 +- arch/arc/include/asm/pgtable.h | 2 +- arch/arc/include/asm/processor.h | 2 +- arch/arc/include/asm/smp.h | 2 +- arch/arc/include/asm/thread_info.h | 2 +- arch/arc/include/asm/uaccess.h | 2 +- arch/arc/include/uapi/asm/swab.h | 2 +- arch/arc/kernel/perf_event.c | 2 +- arch/arc/kernel/setup.c | 2 +- arch/arc/kernel/signal.c | 2 +- arch/arc/kernel/troubleshoot.c | 2 +- arch/arc/mm/cache.c | 6 +++--- arch/arc/mm/dma.c | 2 +- 15 files changed, 18 insertions(+), 18 deletions(-) commit bd000b82e86503d5e8b9e6d40a3257bc9dddb96d Author: Russell Currey <ruscur@russell.cc> Date: Thu Apr 7 16:28:27 2016 +1000 powerpc/pseries/eeh: Refactor the configure_bridge RTAS tokens The RTAS calls "ibm,configure-pe" and "ibm,configure-bridge" perform the same actions, however the former can skip configuration if unnecessary. The existing code treats them as different tokens even though only one will ever be called. Refactor this by making a single token that is assigned during init. Signed-off-by: Russell Currey <ruscur@russell.cc> Acked-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/eeh_pseries.c | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) commit 871e178e0f2c4fa788f694721a10b4758d494ce1 Author: Russell Currey <ruscur@russell.cc> Date: Thu Apr 7 16:28:26 2016 +1000 powerpc/pseries/eeh: Handle RTAS delay requests in configure_bridge In the "ibm,configure-pe" and "ibm,configure-bridge" RTAS calls, the spec states that values of 9900-9905 can be returned, indicating that software should delay for 10^x (where x is the last digit, i.e. 990x) milliseconds and attempt the call again. Currently, the kernel doesn't know about this, and respecting it fixes some PCI failures when the hypervisor is busy. The delay is capped at 0.2 seconds. Cc: <stable@vger.kernel.org> # 3.10+ Signed-off-by: Russell Currey <ruscur@russell.cc> Acked-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/eeh_pseries.c | 51 ++++++++++++++++++++-------- 1 file changed, 36 insertions(+), 15 deletions(-) commit 7cafc0b8bf130f038b0ec2dcdd6a9de6dc59b65a Author: David S. Miller <davem@davemloft.net> Date: Sat May 28 20:41:12 2016 -0700 sparc64: Fix return from trap window fill crashes. We must handle data access exception as well as memory address unaligned exceptions from return from trap window fill faults, not just normal TLB misses. Otherwise we can get an OOPS that looks like this: ld-linux.so.2(36808): Kernel bad sw trap 5 [#1] CPU: 1 PID: 36808 Comm: ld-linux.so.2 Not tainted 4.6.0 #34 task: fff8000303be5c60 ti: fff8000301344000 task.ti: fff8000301344000 TSTATE: 0000004410001601 TPC: 0000000000a1a784 TNPC: 0000000000a1a788 Y: 00000002 Not tainted TPC: <do_sparc64_fault+0x5c4/0x700> g0: fff8000024fc8248 g1: 0000000000db04dc g2: 0000000000000000 g3: 0000000000000001 g4: fff8000303be5c60 g5: fff800030e672000 g6: fff8000301344000 g7: 0000000000000001 o0: 0000000000b95ee8 o1: 000000000000012b o2: 0000000000000000 o3: 0000000200b9b358 o4: 0000000000000000 o5: fff8000301344040 sp: fff80003013475c1 ret_pc: 0000000000a1a77c RPC: <do_sparc64_fault+0x5bc/0x700> l0: 00000000000007ff l1: 0000000000000000 l2: 000000000000005f l3: 0000000000000000 l4: fff8000301347e98 l5: fff8000024ff3060 l6: 0000000000000000 l7: 0000000000000000 i0: fff8000301347f60 i1: 0000000000102400 i2: 0000000000000000 i3: 0000000000000000 i4: 0000000000000000 i5: 0000000000000000 i6: fff80003013476a1 i7: 0000000000404d4c I7: <user_rtt_fill_fixup+0x6c/0x7c> Call Trace: [0000000000404d4c] user_rtt_fill_fixup+0x6c/0x7c The window trap handlers are slightly clever, the trap table entries for them are composed of two pieces of code. First comes the code that actually performs the window fill or spill trap handling, and then there are three instructions at the end which are for exception processing. The userland register window fill handler is: add %sp, STACK_BIAS + 0x00, %g1; \ ldxa [%g1 + %g0] ASI, %l0; \ mov 0x08, %g2; \ mov 0x10, %g3; \ ldxa [%g1 + %g2] ASI, %l1; \ mov 0x18, %g5; \ ldxa [%g1 + %g3] ASI, %l2; \ ldxa [%g1 + %g5] ASI, %l3; \ add %g1, 0x20, %g1; \ ldxa [%g1 + %g0] ASI, %l4; \ ldxa [%g1 + %g2] ASI, %l5; \ ldxa [%g1 + %g3] ASI, %l6; \ ldxa [%g1 + %g5] ASI, %l7; \ add %g1, 0x20, %g1; \ ldxa [%g1 + %g0] ASI, %i0; \ ldxa [%g1 + %g2] ASI, %i1; \ ldxa [%g1 + %g3] ASI, %i2; \ ldxa [%g1 + %g5] ASI, %i3; \ add %g1, 0x20, %g1; \ ldxa [%g1 + %g0] ASI, %i4; \ ldxa [%g1 + %g2] ASI, %i5; \ ldxa [%g1 + %g3] ASI, %i6; \ ldxa [%g1 + %g5] ASI, %i7; \ restored; \ retry; nop; nop; nop; nop; \ b,a,pt %xcc, fill_fixup_dax; \ b,a,pt %xcc, fill_fixup_mna; \ b,a,pt %xcc, fill_fixup; And the way this works is that if any of those memory accesses generate an exception, the exception handler can revector to one of those final three branch instructions depending upon which kind of exception the memory access took. In this way, the fault handler doesn't have to know if it was a spill or a fill that it's handling the fault for. It just always branches to the last instruction in the parent trap's handler. For example, for a regular fault, the code goes: winfix_trampoline: rdpr %tpc, %g3 or %g3, 0x7c, %g3 wrpr %g3, %tnpc done All window trap handlers are 0x80 aligned, so if we "or" 0x7c into the trap time program counter, we'll get that final instruction in the trap handler. On return from trap, we have to pull the register window in but we do this by hand instead of just executing a "restore" instruction for several reasons. The largest being that from Niagara and onward we simply don't have enough levels in the trap stack to fully resolve all possible exception cases of a window fault when we are already at trap level 1 (which we enter to get ready to return from the original trap). This is executed inline via the FILL_*_RTRAP handlers. rtrap_64.S's code branches directly to these to do the window fill by hand if necessary. Now if you look at them, we'll see at the end: ba,a,pt %xcc, user_rtt_fill_fixup; ba,a,pt %xcc, user_rtt_fill_fixup; ba,a,pt %xcc, user_rtt_fill_fixup; And oops, all three cases are handled like a fault. This doesn't work because each of these trap types (data access exception, memory address unaligned, and faults) store their auxiliary info in different registers to pass on to the C handler which does the real work. So in the case where the stack was unaligned, the unaligned trap handler sets up the arg registers one way, and then we branched to the fault handler which expects them setup another way. So the FAULT_TYPE_* value ends up basically being garbage, and randomly would generate the backtrace seen above. Reported-by: Nick Alcock <nix@esperi.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/include/asm/head_64.h | 4 ++ arch/sparc/include/asm/ttable.h | 8 ++-- arch/sparc/kernel/Makefile | 1 + arch/sparc/kernel/rtrap_64.S | 57 ++++------------------- arch/sparc/kernel/urtt_fill.S | 98 ++++++++++++++++++++++++++++++++++++++++ 5 files changed, 116 insertions(+), 52 deletions(-) commit b02b1fbdd338f70e49efa9ca9899214134526701 Merge: 1a695a9 787ab6e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 29 13:28:39 2016 -0700 Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "This is a set of four fixes noticed in the merge window. The aacraid one is an optimisation, the mp3sas one fixes a spurious printk, the sd_check_events one fixes a theoretical race and the failed zero length commands fixes a bug in our completion/retry routines that has been causing problems in the field" * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: aacraid: do not activate events on non-SRC adapters mpt3sas: add missing curly braces sd: get disk reference in sd_check_events() scsi_lib: correctly retry failed zero length REQ_TYPE_FS commands commit 99147606155f09feccac67c65387dc62260b749b Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Fri May 13 21:43:34 2016 +0300 iio: st_sensors: Disable DRDY at init time This fixes odd behavior after reboot. The fact that we set the device to powerdown mode is not sufficient to prevent DRDY being active because we might still have an unread sample. Even if powerdown was sufficient keeping DRDY disabled while trigger is not active is a good idea. Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/st_sensors/st_sensors_core.c | 5 +++++ 1 file changed, 5 insertions(+) commit ff05916f94f912b25e8efcf9b02c10d481977bab Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Fri May 13 21:43:33 2016 +0300 iio: st_sensors: Init trigger before irq request This fixes a possible race where an interrupt arrives before complete initialization and crashes because iio_trigger_get_drvdata returns NULL. Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/st_sensors/st_sensors_trigger.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 65925b65ed98ffdb277cf5ea1af45731dac0b30b Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat May 21 20:43:16 2016 +0200 iio: st_sensors: switch to a threaded interrupt commit 98ad8b41f58dff6b30713d7f09ae3834b8df7ded ("iio: st_sensors: verify interrupt event to status") caused a regression when reading ST sensors from a HRTimer trigger rather than the intrinsic interrupts: the HRTimer may trigger faster than the sensor provides new values, and as the check against new values available as a cause of the interrupt trigger was done in the poll function, this would bail out of the HRTimer interrupt with IRQ_NONE. So clearly we need to only check the new values available from the proper interrupt handler and not from the poll function, which should rather just read the raw values from the registers, put them into the buffer and be happy. To achieve this: switch the ST Sensors over to using a true threaded interrupt handler. In the interrupt thread, check if new values are available, else yield to the (potential) next device on the same interrupt line to check the registers. If the interrupt was ours, proceed to poll the values. Instead of relying on iio_trigger_generic_data_rdy_poll() as a top half to wake up the thread that polls the sensor for new data, have the thread call iio_trigger_poll_chained() after determining that is is the proper source of the interrupt. This is modelled on drivers/iio/accel/mma8452.c which is already using a properly threaded interrupt handler. In order to get the same precision in timestamps as previously, where samples would be timestamped in the poll function pf->timestamp when calling iio_trigger_generic_data_rdy_poll() we introduce a local timestamp in the sensor data, set it in the top half (fastpath) of the interrupt handler and provide that to the core when calling iio_push_to_buffers_with_timestamp(). Additionally: if the active scanmask is not set for the sensor no IRQs should be enabled and we need to bail out with IRQ_NONE. This can happen if spurious IRQs fire when installing the threaded interrupt handler. Tested with hard interrupt triggers on LIS331DL, then also tested with hrtimers on the same sensor by creating a 75Hz HRTimer and using it to poll the sensor. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Reported-by: Crestez Dan Leonard <cdleonard@gmail.com> Tested-by: Crestez Dan Leonard <cdleonard@gmail.com> Tested-by: Jonathan Cameron <jic23@kernel.org> Fixes: 97865fe41322 ("iio: st_sensors: verify interrupt event to status") Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/st_accel_buffer.c | 2 +- drivers/iio/accel/st_accel_core.c | 1 + drivers/iio/common/st_sensors/st_sensors_buffer.c | 25 ++---- drivers/iio/common/st_sensors/st_sensors_core.c | 3 + drivers/iio/common/st_sensors/st_sensors_trigger.c | 88 +++++++++++++++++++++- drivers/iio/gyro/st_gyro_buffer.c | 2 +- drivers/iio/gyro/st_gyro_core.c | 1 + drivers/iio/magnetometer/st_magn_buffer.c | 2 +- drivers/iio/magnetometer/st_magn_core.c | 1 + drivers/iio/pressure/st_pressure_buffer.c | 2 +- drivers/iio/pressure/st_pressure_core.c | 1 + include/linux/iio/common/st_sensors.h | 9 ++- 12 files changed, 111 insertions(+), 26 deletions(-) commit 0dd09ca419d712d315ffd864158f515e6c64261a Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed May 25 09:40:27 2016 +0200 iio: light: bh1780: assign a static name Using the struct i2c_device->id field for naming the light sensor is a bad idea: when booting from the pure device tree this is NULL and that causes the device not to have the "name" property in sysfs and that in turn confuses the "lsiio" command to stop listing devices. So instead of using the device .id, use the hard string "bh1780", which works just fine. Fixes: 1f0477f18306 ("iio: light: new driver for the ROHM BH1780") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/bh1780.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 13c27e946ddc0e19f3d8b307b14cd8053fcb4844 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed May 25 09:40:26 2016 +0200 iio: bh1780: dereference the client properly The code in runtime_[suspend|resume] was assuming that the i2c client data was the bh1780 state container, but it contains the IIO device. So first dereference the IIO device from the i2c client, then get the state container using the iio_priv() call. Fixes: 1f0477f18306 ("iio: light: new driver for the ROHM BH1780") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/bh1780.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 09bc0ddaab6cab0fa95a67d5535ec772e2671193 Author: Matt Ranostay <mranostay@gmail.com> Date: Thu May 26 19:55:06 2016 -0700 iio: humidity: hdc100x: fix IIO_TEMP channel reporting IIO_TEMP channel was being incorrectly reported back as Celsius when it should have been milliCelsius. This is via an incorrect scale value being returned to userspace. Signed-off-by: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/hdc100x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d11c2a0de2824395656cf8ed15811580c9dd38aa Author: David S. Miller <davem@davemloft.net> Date: Sat May 28 21:21:31 2016 -0700 sparc: Harden signal return frame checks. All signal frames must be at least 16-byte aligned, because that is the alignment we explicitly create when we build signal return stack frames. All stack pointers must be at least 8-byte aligned. Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/kernel/signal32.c | 46 +++++++++++++++++++++++++++--------------- arch/sparc/kernel/signal_32.c | 41 +++++++++++++++++++++++-------------- arch/sparc/kernel/signal_64.c | 31 ++++++++++++++++++---------- arch/sparc/kernel/sigutil_32.c | 9 ++++++++- arch/sparc/kernel/sigutil_64.c | 10 +++++++-- 5 files changed, 92 insertions(+), 45 deletions(-) commit 711460514b1c80494f14001bdf30dd70fd401a8f Merge: 275ae41 5ea5888 Author: Ingo Molnar <mingo@kernel.org> Date: Sun May 29 20:15:37 2016 +0200 Merge tag 'perf-urgent-for-mingo-20160527' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent Pull perf/urgent fixes from Arnaldo Carvalho de Melo: - Fix kptr_restrict=2 related 'perf record' segfault (Wang Nan) - Fix CTF/libbabeltrace handling of chinese COMM strings (Wang Nan) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 1a695a905c18548062509178b98bc91e67510864 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 29 09:29:24 2016 -0700 Linux 4.7-rc1 Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d43a41152f8e9e4c0d19850884d1fada076dee10 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Tue Apr 19 11:18:33 2016 +0200 iio:st_pressure: fix sampling gains (bring inline with ABI) Temperature channels report scaled samples in Celsius although expected as milli degree Celsius in Documentation/ABI/testing/sysfs-bus-iio. Gains are not implemented at all for LPS001WP pressure and temperature channels. This patch ensures that proper offsets and scales are exposed to userpace for both pressure and temperature channels. Also fix a NULL pointer exception when userspace reads content of sysfs scale attribute when gains are not defined. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/st_pressure_core.c | 80 ++++++++++++++++++++------------- 1 file changed, 50 insertions(+), 30 deletions(-) commit e0ab7af9bd1c25e40b9a1dbeb2a634b88267b9d7 Author: George Spelvin <linux@sciencehorizons.net> Date: Sun May 29 08:05:56 2016 -0400 hash_string: Fix zero-length case for !DCACHE_WORD_ACCESS The self-test was updated to cover zero-length strings; the function needs to be updated, too. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: George Spelvin <linux@sciencehorizons.net> Fixes: fcfd2fbf22d2 ("fs/namei.c: Add hashlen_string() function") Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/namei.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f2a031b66ec6da1512f9db228e4174ad2c7d2688 Author: George Spelvin <linux@sciencehorizons.net> Date: Sun May 29 01:26:41 2016 -0400 Rename other copy of hash_string to hashlen_string The original name was simply hash_string(), but that conflicted with a function with that name in drivers/base/power/trace.c, and I decided that calling it "hashlen_" was better anyway. But you have to do it in two places. [ This caused build errors for architectures that don't define CONFIG_DCACHE_WORD_ACCESS - Linus ] Signed-off-by: George Spelvin <linux@sciencehorizons.net> Reported-by: Guenter Roeck <linux@roeck-us.net> Fixes: fcfd2fbf22d2 ("fs/namei.c: Add hashlen_string() function") Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/namei.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 037369b872940cd923835a0a589763180c4a36bc Author: Mikulas Patocka <mikulas@twibright.com> Date: Tue May 24 22:49:18 2016 +0200 hpfs: implement the show_options method The HPFS filesystem used generic_show_options to produce string that is displayed in /proc/mounts. However, there is a problem that the options may disappear after remount. If we mount the filesystem with option1 and then remount it with option2, /proc/mounts should show both option1 and option2, however it only shows option2 because the whole option string is replaced with replace_mount_options in hpfs_remount_fs. To fix this bug, implement the hpfs_show_options function that prints options that are currently selected. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/hpfs/super.c | 43 ++++++++++++++++++++++++++++++++----------- 1 file changed, 32 insertions(+), 11 deletions(-) commit 01d6e08711bf90bc4d7ead14a93a0cbd73b1896a Author: Mikulas Patocka <mikulas@twibright.com> Date: Tue May 24 22:48:33 2016 +0200 affs: fix remount failure when there are no options changed Commit c8f33d0bec99 ("affs: kstrdup() memory handling") checks if the kstrdup function returns NULL due to out-of-memory condition. However, if we are remounting a filesystem with no change to filesystem-specific options, the parameter data is NULL. In this case, kstrdup returns NULL (because it was passed NULL parameter), although no out of memory condition exists. The mount syscall then fails with ENOMEM. This patch fixes the bug. We fail with ENOMEM only if data is non-NULL. The patch also changes the call to replace_mount_options - if we didn't pass any filesystem-specific options, we don't call replace_mount_options (thus we don't erase existing reported options). Fixes: c8f33d0bec99 ("affs: kstrdup() memory handling") Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org # v4.1+ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/affs/super.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 44d51706b4685f965cd32acde3fe0fcc1e6198e8 Author: Mikulas Patocka <mikulas@twibright.com> Date: Tue May 24 22:47:00 2016 +0200 hpfs: fix remount failure when there are no options changed Commit ce657611baf9 ("hpfs: kstrdup() out of memory handling") checks if the kstrdup function returns NULL due to out-of-memory condition. However, if we are remounting a filesystem with no change to filesystem-specific options, the parameter data is NULL. In this case, kstrdup returns NULL (because it was passed NULL parameter), although no out of memory condition exists. The mount syscall then fails with ENOMEM. This patch fixes the bug. We fail with ENOMEM only if data is non-NULL. The patch also changes the call to replace_mount_options - if we didn't pass any filesystem-specific options, we don't call replace_mount_options (thus we don't erase existing reported options). Fixes: ce657611baf9 ("hpfs: kstrdup() out of memory handling") Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/hpfs/super.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 4029632c344142e0e92da3ff4937cd41bd647bb4 Merge: d66492b a8c5ddf Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 16:41:39 2016 -0700 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus Pull more MIPS updates from Ralf Baechle: "This is the secondnd batch of MIPS patches for 4.7. Summary: CPS: - Copy EVA configuration when starting secondary VPs. EIC: - Clear Status IPL. Lasat: - Fix a few off by one bugs. lib: - Mark intrinsics notrace. Not only are the intrinsics uninteresting, it would cause infinite recursion. MAINTAINERS: - Add file patterns for MIPS BRCM device tree bindings. - Add file patterns for mips device tree bindings. MT7628: - Fix MT7628 pinmux typos. - wled_an pinmux gpio. - EPHY LEDs pinmux support. Pistachio: - Enable KASLR VDSO: - Build microMIPS VDSO for microMIPS kernels. - Fix aliasing warning by building with `-fno-strict-aliasing' for debugging but also tracing them might result in recursion. Misc: - Add missing FROZEN hotplug notifier transitions. - Fix clk binding example for varioius PIC32 devices. - Fix cpu interrupt controller node-names in the DT files. - Fix XPA CPU feature separation. - Fix write_gc0_* macros when writing zero. - Add inline asm encoding helpers. - Add missing VZ accessor microMIPS encodings. - Fix little endian microMIPS MSA encodings. - Add 64-bit HTW fields and fix its configuration. - Fix sigreturn via VDSO on microMIPS kernel. - Lots of typo fixes. - Add definitions of SegCtl registers and use them" * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (49 commits) MIPS: Add missing FROZEN hotplug notifier transitions MIPS: Build microMIPS VDSO for microMIPS kernels MIPS: Fix sigreturn via VDSO on microMIPS kernel MIPS: devicetree: fix cpu interrupt controller node-names MIPS: VDSO: Build with `-fno-strict-aliasing' MIPS: Pistachio: Enable KASLR MIPS: lib: Mark intrinsics notrace MIPS: Fix 64-bit HTW configuration MIPS: Add 64-bit HTW fields MAINTAINERS: Add file patterns for mips device tree bindings MAINTAINERS: Add file patterns for mips brcm device tree bindings MIPS: Simplify DSP instruction encoding macros MIPS: Add missing tlbinvf/XPA microMIPS encodings MIPS: Fix little endian microMIPS MSA encodings MIPS: Add missing VZ accessor microMIPS encodings MIPS: Add inline asm encoding helpers MIPS: Spelling fix lets -> let's MIPS: VR41xx: Fix typo MIPS: oprofile: Fix typo MIPS: math-emu: Fix typo ... commit d66492bce151ac4c477cf1de97171777c0d62d20 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat May 28 15:26:02 2016 -0700 fs: fix binfmt_aout.c build error Various builds (such as i386:allmodconfig) fail with fs/binfmt_aout.c:133:2: error: expected identifier or '(' before 'return' fs/binfmt_aout.c:134:1: error: expected identifier or '(' before '}' token [ Oops. My bad, I had stupidly thought that "allmodconfig" covered this on x86-64 too, but it obviously doesn't. Egg on my face. - Linus ] Fixes: 5d22fc25d4fc ("mm: remove more IS_ERR_VALUE abuses") Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/binfmt_aout.c | 1 - 1 file changed, 1 deletion(-) commit 7e0fb73c52c4037b4d5ef9ff56c7296a3151bd92 Merge: 4e8440b 4684fe9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 16:15:25 2016 -0700 Merge branch 'hash' of git://ftp.sciencehorizons.net/linux Pull string hash improvements from George Spelvin: "This series does several related things: - Makes the dcache hash (fs/namei.c) useful for general kernel use. (Thanks to Bruce for noticing the zero-length corner case) - Converts the string hashes in <linux/sunrpc/svcauth.h> to use the above. - Avoids 64-bit multiplies in hash_64() on 32-bit platforms. Two 32-bit multiplies will do well enough. - Rids the world of the bad hash multipliers in hash_32. This finishes the job started in commit 689de1d6ca95 ("Minimal fix-up of bad hashing behavior of hash_64()") The vast majority of Linux architectures have hardware support for 32x32-bit multiply and so derive no benefit from "simplified" multipliers. The few processors that do not (68000, h8/300 and some models of Microblaze) have arch-specific implementations added. Those patches are last in the series. - Overhauls the dcache hash mixing. The patch in commit 0fed3ac866ea ("namei: Improve hash mixing if CONFIG_DCACHE_WORD_ACCESS") was an off-the-cuff suggestion. Replaced with a much more careful design that's simultaneously faster and better. (My own invention, as there was noting suitable in the literature I could find. Comments welcome!) - Modify the hash_name() loop to skip the initial HASH_MIX(). This would let us salt the hash if we ever wanted to. - Sort out partial_name_hash(). The hash function is declared as using a long state, even though it's truncated to 32 bits at the end and the extra internal state contributes nothing to the result. And some callers do odd things: - fs/hfs/string.c only allocates 32 bits of state - fs/hfsplus/unicode.c uses it to hash 16-bit unicode symbols not bytes - Modify bytemask_from_count to handle inputs of 1..sizeof(long) rather than 0..sizeof(long)-1. This would simplify users other than full_name_hash" Special thanks to Bruce Fields for testing and finding bugs in v1. (I learned some humbling lessons about "obviously correct" code.) On the arch-specific front, the m68k assembly has been tested in a standalone test harness, I've been in contact with the Microblaze maintainers who mostly don't care, as the hardware multiplier is never omitted in real-world applications, and I haven't heard anything from the H8/300 world" * 'hash' of git://ftp.sciencehorizons.net/linux: h8300: Add <asm/hash.h> microblaze: Add <asm/hash.h> m68k: Add <asm/hash.h> <linux/hash.h>: Add support for architecture-specific functions fs/namei.c: Improve dcache hash function Eliminate bad hash multipliers from hash_32() and hash_64() Change hash_64() return value to 32 bits <linux/sunrpc/svcauth.h>: Define hash_str() in terms of hashlen_string() fs/namei.c: Add hashlen_string() function Pull out string hash to <linux/stringhash.h> commit 4684fe95300c071983f77653e354c040fe80a265 Author: George Spelvin <linux@sciencehorizons.net> Date: Wed May 25 14:19:49 2016 -0400 h8300: Add <asm/hash.h> This will improve the performance of hash_32() and hash_64(), but due to complete lack of multi-bit shift instructions on H8, performance will still be bad in surrounding code. Designing H8-specific hash algorithms to work around that is a separate project. (But if the maintainers would like to get in touch...) Signed-off-by: George Spelvin <linux@sciencehorizons.net> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: uclinux-h8-devel@lists.sourceforge.jp arch/h8300/Kconfig | 1 + arch/h8300/include/asm/hash.h | 53 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+) commit 7b13277b682972c2ff8f6419e86c333d81936023 Author: George Spelvin <linux@sciencehorizons.net> Date: Wed May 25 11:06:09 2016 -0400 microblaze: Add <asm/hash.h> Microblaze is an FPGA soft core that can be configured various ways. If it is configured without a multiplier, the standard __hash_32() will require a call to __mulsi3, which is a slow software loop. Instead, use a shift-and-add sequence for the constant multiply. GCC knows how to do this, but it's not as clever as some. Signed-off-by: George Spelvin <linux@sciencehorizons.net> Cc: Alistair Francis <alistair.francis@xilinx.com> Cc: Michal Simek <michal.simek@xilinx.com> arch/microblaze/Kconfig | 1 + arch/microblaze/include/asm/hash.h | 81 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 82 insertions(+) commit 14c44b95b3dcb8ff1d627e6b78f57c4373d375cb Author: George Spelvin <linux@sciencehorizons.net> Date: Thu May 26 11:36:19 2016 -0400 m68k: Add <asm/hash.h> This provides a multiply by constant GOLDEN_RATIO_32 = 0x61C88647 for the original mc68000, which lacks a 32x32-bit multiply instruction. Yes, the amount of optimization effort put in is excessive. :-) Shift-add chain found by Yevgen Voronenko's Hcub algorithm at http://spiral.ece.cmu.edu/mcm/gen.html Signed-off-by: George Spelvin <linux@sciencehorizons.net> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Greg Ungerer <gerg@linux-m68k.org> Cc: Andreas Schwab <schwab@linux-m68k.org> Cc: Philippe De Muyter <phdm@macq.eu> Cc: linux-m68k@lists.linux-m68k.org arch/m68k/Kconfig.cpu | 1 + arch/m68k/include/asm/hash.h | 59 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+) commit 468a9428521e7d00fb21250af363eb94dc1d6861 Author: George Spelvin <linux@sciencehorizons.net> Date: Thu May 26 22:11:51 2016 -0400 <linux/hash.h>: Add support for architecture-specific functions This is just the infrastructure; there are no users yet. This is modelled on CONFIG_ARCH_RANDOM; a CONFIG_ symbol declares the existence of <asm/hash.h>. That file may define its own versions of various functions, and define HAVE_* symbols (no CONFIG_ prefix!) to suppress the generic ones. Included is a self-test (in lib/test_hash.c) that verifies the basics. It is NOT in general required that the arch-specific functions compute the same thing as the generic, but if a HAVE_* symbol is defined with the value 1, then equality is tested. Signed-off-by: George Spelvin <linux@sciencehorizons.net> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Greg Ungerer <gerg@linux-m68k.org> Cc: Andreas Schwab <schwab@linux-m68k.org> Cc: Philippe De Muyter <phdm@macq.eu> Cc: linux-m68k@lists.linux-m68k.org Cc: Alistair Francis <alistai@xilinx.com> Cc: Michal Simek <michal.simek@xilinx.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: uclinux-h8-devel@lists.sourceforge.jp arch/Kconfig | 8 ++ fs/namei.c | 6 +- include/linux/hash.h | 27 +++++- lib/Kconfig.debug | 11 +++ lib/Makefile | 1 + lib/test_hash.c | 250 +++++++++++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 299 insertions(+), 4 deletions(-) commit 2a18da7a9c7886f1c7307f8d3f23f24318583f03 Author: George Spelvin <linux@sciencehorizons.net> Date: Mon May 23 07:43:58 2016 -0400 fs/namei.c: Improve dcache hash function Patch 0fed3ac866 improved the hash mixing, but the function is slower than necessary; there's a 7-instruction dependency chain (10 on x86) each loop iteration. Word-at-a-time access is a very tight loop (which is good, because link_path_walk() is one of the hottest code paths in the entire kernel), and the hash mixing function must not have a longer latency to avoid slowing it down. There do not appear to be any published fast hash functions that: 1) Operate on the input a word at a time, and 2) Don't need to know the length of the input beforehand, and 3) Have a single iterated mixing function, not needing conditional branches or unrolling to distinguish different loop iterations. One of the algorithms which comes closest is Yann Collet's xxHash, but that's two dependent multiplies per word, which is too much. The key insights in this design are: 1) Barring expensive ops like multiplies, to diffuse one input bit across 64 bits of hash state takes at least log2(64) = 6 sequentially dependent instructions. That is more cycles than we'd like. 2) An operation like "hash ^= hash << 13" requires a second temporary register anyway, and on a 2-operand machine like x86, it's three instructions. 3) A better use of a second register is to hold a two-word hash state. With careful design, no temporaries are needed at all, so it doesn't increase register pressure. And this gets rid of register copying on 2-operand machines, so the code is smaller and faster. 4) Using two words of state weakens the requirement for one-round mixing; we now have two rounds of mixing before cancellation is possible. 5) A two-word hash state also allows operations on both halves to be done in parallel, so on a superscalar processor we get more mixing in fewer cycles. I ended up using a mixing function inspired by the ChaCha and Speck round functions. It is 6 simple instructions and 3 cycles per iteration (assuming multiply by 9 can be done by an "lea" instruction): x ^= *input++; y ^= x; x = ROL(x, K1); x += y; y = ROL(y, K2); y *= 9; Not only is this reversible, two consecutive rounds are reversible: if you are given the initial and final states, but not the intermediate state, it is possible to compute both input words. This means that at least 3 words of input are required to create a collision. (It also has the property, used by hash_name() to avoid a branch, that it hashes all-zero to all-zero.) The rotate constants K1 and K2 were found by experiment. The search took a sample of random initial states (I used 1023) and considered the effect of flipping each of the 64 input bits on each of the 128 output bits two rounds later. Each of the 8192 pairs can be considered a biased coin, and adding up the Shannon entropy of all of them produces a score. The best-scoring shifts also did well in other tests (flipping bits in y, trying 3 or 4 rounds of mixing, flipping all 64*63/2 pairs of input bits), so the choice was made with the additional constraint that the sum of the shifts is odd and not too close to the word size. The final state is then folded into a 32-bit hash value by a less carefully optimized multiply-based scheme. This also has to be fast, as pathname components tend to be short (the most common case is one iteration!), but there's some room for latency, as there is a fair bit of intervening logic before the hash value is used for anything. (Performance verified with "bonnie++ -s 0 -n 1536:-2" on tmpfs. I need a better benchmark; the numbers seem to show a slight dip in performance between 4.6.0 and this patch, but they're too noisy to quote.) Special thanks to Bruce fields for diligent testing which uncovered a nasty fencepost error in an earlier version of this patch. [checkpatch.pl formatting complaints noted and respectfully disagreed with.] Signed-off-by: George Spelvin <linux@sciencehorizons.net> Tested-by: J. Bruce Fields <bfields@redhat.com> fs/namei.c | 121 +++++++++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 81 insertions(+), 40 deletions(-) commit ef703f49a6c5b909a85149bb6625c4ed0d697186 Author: George Spelvin <linux@sciencehorizons.net> Date: Thu May 26 23:00:23 2016 -0400 Eliminate bad hash multipliers from hash_32() and hash_64() The "simplified" prime multipliers made very bad hash functions, so get rid of them. This completes the work of 689de1d6ca. To avoid the inefficiency which was the motivation for the "simplified" multipliers, hash_64() on 32-bit systems is changed to use a different algorithm. It makes two calls to hash_32() instead. drivers/media/usb/dvb-usb-v2/af9015.c uses the old GOLDEN_RATIO_PRIME_32 for some horrible reason, so it inherits a copy of the old definition. Signed-off-by: George Spelvin <linux@sciencehorizons.net> Cc: Antti Palosaari <crope@iki.fi> Cc: Mauro Carvalho Chehab <m.chehab@samsung.com> drivers/media/usb/dvb-usb-v2/af9015.c | 2 + include/linux/hash.h | 87 ++++++++++++++--------------------- 2 files changed, 36 insertions(+), 53 deletions(-) commit 92d567740f2ab5937b2c23bee94ea4b284bb1f98 Author: George Spelvin <linux@sciencehorizons.net> Date: Thu May 26 22:22:01 2016 -0400 Change hash_64() return value to 32 bits That's all that's ever asked for, and it makes the return type of hash_long() consistent. It also allows (upcoming patch) an optimized implementation of hash_64 on 32-bit machines. I tried adding a BUILD_BUG_ON to ensure the number of bits requested was never more than 32 (most callers use a compile-time constant), but adding <linux/bug.h> to <linux/hash.h> breaks the tools/perf compiler unless tools/perf/MANIFEST is updated, and understanding that code base well enough to update it is too much trouble. I did the rest of an allyesconfig build with such a check, and nothing tripped. Signed-off-by: George Spelvin <linux@sciencehorizons.net> include/linux/hash.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 917ea166f4672ec085f2cccc135c7c0eec72282c Author: George Spelvin <linux@sciencehorizons.net> Date: Fri May 20 13:31:33 2016 -0400 <linux/sunrpc/svcauth.h>: Define hash_str() in terms of hashlen_string() Finally, the first use of previous two patches: eliminate the separate ad-hoc string hash functions in the sunrpc code. Now hash_str() is a wrapper around hash_string(), and hash_mem() is likewise a wrapper around full_name_hash(). Note that sunrpc code *does* call hash_mem() with a zero length, which is why the previous patch needed to handle that in full_name_hash(). (Thanks, Bruce, for finding that!) This also eliminates the only caller of hash_long which asks for more than 32 bits of output. The comment about the quality of hashlen_string() and full_name_hash() is jumping the gun by a few patches; they aren't very impressive now, but will be improved greatly later in the series. Signed-off-by: George Spelvin <linux@sciencehorizons.net> Tested-by: J. Bruce Fields <bfields@redhat.com> Acked-by: J. Bruce Fields <bfields@redhat.com> Cc: Jeff Layton <jlayton@poochiereds.net> Cc: linux-nfs@vger.kernel.org include/linux/sunrpc/svcauth.h | 40 +++++++++------------------------------- 1 file changed, 9 insertions(+), 31 deletions(-) commit fcfd2fbf22d2587196890103d41e3d554c47da0e Author: George Spelvin <linux@sciencehorizons.net> Date: Fri May 20 08:41:37 2016 -0400 fs/namei.c: Add hashlen_string() function We'd like to make more use of the highly-optimized dcache hash functions throughout the kernel, rather than have every subsystem create its own, and a function that hashes basic null-terminated strings is required for that. (The name is to emphasize that it returns both hash and length.) It's actually useful in the dcache itself, specifically d_alloc_name(). Other uses in the next patch. full_name_hash() is also tweaked to make it more generally useful: 1) Take a "char *" rather than "unsigned char *" argument, to be consistent with hash_name(). 2) Handle zero-length inputs. If we want more callers, we don't want to make them worry about corner cases. Signed-off-by: George Spelvin <linux@sciencehorizons.net> fs/dcache.c | 3 +-- fs/namei.c | 51 +++++++++++++++++++++++++++++++++++++++++----- include/linux/stringhash.h | 8 ++++++-- 3 files changed, 53 insertions(+), 9 deletions(-) commit f4bcbe792b8f434e32487cff9d9e30ab45a3ce02 Author: George Spelvin <linux@sciencehorizons.net> Date: Fri May 20 07:26:00 2016 -0400 Pull out string hash to <linux/stringhash.h> ... so they can be used without the rest of <linux/dcache.h> The hashlen_* macros will make sense next patch. Signed-off-by: George Spelvin <linux@sciencehorizons.net> include/linux/dcache.h | 27 +---------------- include/linux/stringhash.h | 72 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 73 insertions(+), 26 deletions(-) commit 4e8440b3b6b801953b2e53c55491cf98fc8f6c01 Merge: a1842b2 e6be18f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 12:38:50 2016 -0700 Merge branch 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux Pull i2c fix from Wolfram Sang: "A fix for a regression introduced yesterday. The regression didn't show up here locally because I did not have PAGE_POISONING enabled. And buildbots discovered this only after it hit your tree. Thanks to Dan for the quick response" * 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux: i2c: dev: use after free in detach commit a1842b2b6fc011145c24180744d62d88b895f8e3 Merge: 0723ab4 8d057e3 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 12:32:01 2016 -0700 Merge tag 'chrome-platform' of git://git.kernel.org/pub/scm/linux/kernel/git/olof/chrome-platform Pull chrome platform updates from Olof Johansson "A handful of Chrome driver and binding changes this merge window: - a few patches to fix probing and configuration of pstore - a few patches adding Elan touchpad registration on a few devices - EC changes: a security fix dealing with max message sizes and addition of compat_ioctl support. - keyboard backlight control support There was also an accidential duplicate registration of trackpads on 'Leon', which was reverted just recently" * tag 'chrome-platform' of git://git.kernel.org/pub/scm/linux/kernel/git/olof/chrome-platform: Revert "platform/chrome: chromeos_laptop: Add Leon Touch" platform/chrome: chromeos_laptop - Add Elan touchpad for Wolf platform/chrome: chromeos_laptop - Add elan trackpad option for C720 platform/chrome: cros_ec_dev - Populate compat_ioctl platform/chrome: cros_ec_lightbar - use name instead of ID to hide lightbar attributes platform/chrome: cros_ec_dev - Fix security issue platform/chrome: Add Chrome OS keyboard backlight LEDs support platform/chrome: use to_platform_device() platform/chrome: pstore: Move to larger record size. platform/chrome: pstore: probe for ramoops buffer using acpi platform/chrome: chromeos_laptop: Add Leon Touch commit 0723ab4a97a19bf9da135d68529977aeba17570d Merge: 9ba55cf eb4606e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 12:23:12 2016 -0700 Merge tag 'sound-4.7-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull more sound updates from Takashi Iwai: "This is the second update round for 4.7-rc1. Most of changes are about the pending ASoC updates and fixes, including a few new drivers. Below are some highlights: ASoC: - New drivers for MAX98371 and TAS5720 - SPI support for TLV320AIC32x4, along with the module split - TDM support for STI Uniperf IPs - Remaining topology API fixes / updates HDA: - A couple of Dell quirks and new Realtek codec support" * tag 'sound-4.7-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (63 commits) ALSA: hda - Fix headset mic detection problem for one Dell machine spi: spi-ep93xx: Fix the PTR_ERR() argument ALSA: hda/realtek - Add support for ALC295/ALC3254 ASoC: kirkwood: fix build failure ALSA: hda - Fix headphone noise on Dell XPS 13 9360 ASoC: ak4642: Enable cache usage to fix crashes on resume ASoC: twl6040: Disconnect AUX output pads on digital mute ASoC: tlv320aic32x4: Properly implement the positive and negative pins into the mixers rcar: src: skip disabled-SRC nodes ASoC: max98371 Remove duplicate entry in max98371_reg ASoC: twl6040: Select LPPLL during standby ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS ASoC: simple-card: Add pm callbacks to platform driver ASoC: pxa: Fix module autoload for platform drivers ASoC: topology: Fix memory leak in widget creation ASoC: Add max98371 codec driver ASoC: rsnd: count .probe/.remove for rsnd_mod_call() ASoC: topology: Check size mismatch of ABI objects before parsing ASoC: topology: Check failure to create a widget ASoC: add support for TAS5720 digital amplifier ... commit 9ba55cf7cfbfd12a7e914d0d55b7581e896b3f0d Merge: 1cbe06c 8f0dfb3 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 12:04:17 2016 -0700 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending Pull SCSI target updates from Nicholas Bellinger: "Here are the outstanding target pending updates for v4.7-rc1. The highlights this round include: - Allow external PR/ALUA metadata path be defined at runtime via top level configfs attribute (Lee) - Fix target session shutdown bug for ib_srpt multi-channel (hch) - Make TFO close_session() and shutdown_session() optional (hch) - Drop se_sess->sess_kref + convert tcm_qla2xxx to internal kref (hch) - Add tcm_qla2xxx endpoint attribute for basic FC jammer (Laurence) - Refactor iscsi-target RX/TX PDU encode/decode into common code (Varun) - Extend iscsit_transport with xmit_pdu, release_cmd, get_rx_pdu, validate_parameters, and get_r2t_ttt for generic ISO offload (Varun) - Initial merge of cxgb iscsi-segment offload target driver (Varun) The bulk of the changes are Chelsio's new driver, along with a number of iscsi-target common code improvements made by Varun + Co along the way" * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending: (29 commits) iscsi-target: Fix early sk_data_ready LOGIN_FLAGS_READY race cxgbit: Use type ISCSI_CXGBIT + cxgbit tpg_np attribute iscsi-target: Convert transport drivers to signal rdma_shutdown iscsi-target: Make iscsi_tpg_np driver show/store use generic code tcm_qla2xxx Add SCSI command jammer/discard capability iscsi-target: graceful disconnect on invalid mapping to iovec target: need_to_release is always false, remove redundant check and kfree target: remove sess_kref and ->shutdown_session iscsi-target: remove usage of ->shutdown_session tcm_qla2xxx: introduce a private sess_kref target: make close_session optional target: make ->shutdown_session optional target: remove acl_stop target: consolidate and fix session shutdown cxgbit: add files for cxgbit.ko iscsi-target: export symbols iscsi-target: call complete on conn_logout_comp iscsi-target: clear tx_thread_active iscsi-target: add new offload transport type iscsi-target: use conn_transport->transport_type in text rsp ... commit 1cbe06c3cf542d48eb22180163e00f91760ef8cd Merge: ed2608f 7a226f9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 28 11:04:16 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma Pull more rdma updates from Doug Ledford: "This is the second group of code for the 4.7 merge window. It looks large, but only in one sense. I'll get to that in a minute. The list of changes here breaks down as follows: - Dynamic counter infrastructure in the IB drivers This is a sysfs based code to allow free form access to the hardware counters RDMA devices might support so drivers don't need to code this up repeatedly themselves - SendOnlyFullMember multicast support - IB router support - A couple misc fixes - The big item on the list: hfi1 driver updates, plus moving the hfi1 driver out of staging There was a group of 15 patches in the hfi1 list that I thought I had in the first pull request but they weren't. So that added to the length of the hfi1 section here. As far as these go, everything but the hfi1 is pretty straight forward. The hfi1 is, if you recall, the driver that Al had complaints about how it used the write/writev interfaces in an overloaded fashion. The write portion of their interface behaved like the write handler in the IB stack proper and did bi-directional communications. The writev interface, on the other hand, only accepts SDMA request structures. The completions for those structures are sent back via an entirely different event mechanism. With the security patch, we put security checks on the write interface, however, we also knew they would be going away soon. Now, we've converted the write handler in the hfi1 driver to use ioctls from the IB reserved magic area for its bidirectional communications. With that change, Intel has addressed all of the items originally on their TODO when they went into staging (as well as many items added to the list later). As such, I moved them out, and since they were the last item in the staging/rdma directory, and I don't have immediate plans to use the staging area again, I removed the staging/rdma area. Because of the move out of staging, as well as a series of 5 patches in the hfi1 driver that removed code people thought should be done in a different way and was optional to begin with (a snoop debug interface, an eeprom driver for an eeprom connected directory to their hfi1 chip and not via an i2c bus, and a few other things like that), the line count, especially the removal count, is high" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: (56 commits) staging/rdma: Remove the entire rdma subdirectory of staging IB/core: Make device counter infrastructure dynamic IB/hfi1: Fix pio map initialization IB/hfi1: Correct 8051 link parameter settings IB/hfi1: Update pkey table properly after link down or FM start IB/rdamvt: Fix rdmavt s_ack_queue sizing IB/rdmavt: Max atomic value should be a u8 IB/hfi1: Fix hard lockup due to not using save/restore spin lock IB/hfi1: Add tracing support for send with invalidate opcode IB/hfi1, qib: Add ieth to the packet header definitions IB/hfi1: Move driver out of staging IB/hfi1: Do not free hfi1 cdev parent structure early IB/hfi1: Add trace message in user IOCTL handling IB/hfi1: Remove write(), use ioctl() for user cmds IB/hfi1: Add ioctl() interface for user commands IB/hfi1: Remove unused user command IB/hfi1: Remove snoop/diag interface IB/hfi1: Remove EPROM functionality from data device IB/hfi1: Remove UI char device IB/hfi1: Remove multiple device cdev ... commit 8d057e3a180da16b0d1519056295165e7b8dc8f5 Author: Benson Leung <bleung@chromium.org> Date: Sat May 28 08:25:33 2016 -0700 Revert "platform/chrome: chromeos_laptop: Add Leon Touch" This reverts commit bff3c624dc7261a084a4d25a0b09c3fb0fec872a. Board "Leon" is otherwise known as "Toshiba CB35" and we already have the entry that supports that board as of this commit : 963cb6f platform/chrome: chromeos_laptop - Add Toshiba CB35 Touch Remove this duplicate. Signed-off-by: Benson Leung <bleung@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_laptop.c | 15 --------------- 1 file changed, 15 deletions(-) commit e6be18f6d62c1d3b331ae020b76a29c2ccf6b0bf Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Sat May 28 08:01:46 2016 +0300 i2c: dev: use after free in detach The call to put_i2c_dev() frees "i2c_dev" so there is a use after free when we call cdev_del(&i2c_dev->cdev). Fixes: d6760b14d4a1 ('i2c: dev: switch from register_chrdev to cdev API') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a8c5ddf08f1f7e587240c44f82f4762bd37df1f3 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Tue May 24 15:08:47 2016 +0200 MIPS: Add missing FROZEN hotplug notifier transitions The corresponding FROZEN hotplug notifier transitions used on suspend/resume are ignored. Therefore the switch case action argument is masked with the frozen hotplug notifier transition mask. Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: rt@linutronix.de Patchwork: https://patchwork.linux-mips.org/patch/13351/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bb93078e655be1e24d68f28f2756676e62c037ce Author: James Hogan <james.hogan@imgtec.com> Date: Tue May 24 09:35:11 2016 +0100 MIPS: Build microMIPS VDSO for microMIPS kernels MicroMIPS kernels may be expected to run on microMIPS only cores which don't support the normal MIPS instruction set, so be sure to pass the -mmicromips flag through to the VDSO cflags. Fixes: ebb5e78cc634 ("MIPS: Initial implementation of a VDSO") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.4.x- Patchwork: https://patchwork.linux-mips.org/patch/13349/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/vdso/Makefile | 1 + 1 file changed, 1 insertion(+) commit 13eb192d10bcc9ac518d57356179071d603bcb4e Author: James Hogan <james.hogan@imgtec.com> Date: Tue May 24 09:35:10 2016 +0100 MIPS: Fix sigreturn via VDSO on microMIPS kernel In microMIPS kernels, handle_signal() sets the isa16 mode bit in the vdso address so that the sigreturn trampolines (which are offset from the VDSO) get executed as microMIPS. However commit ebb5e78cc634 ("MIPS: Initial implementation of a VDSO") changed the offsets to come from the VDSO image, which already have the isa16 mode bit set correctly since they're extracted from the VDSO shared library symbol table. Drop the isa16 mode bit handling from handle_signal() to fix sigreturn for cores which support both microMIPS and normal MIPS. This doesn't fix microMIPS only cores, since the VDSO is still built for normal MIPS, but thats a separate problem. Fixes: ebb5e78cc634 ("MIPS: Initial implementation of a VDSO") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.4.x- Patchwork: https://patchwork.linux-mips.org/patch/13348/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/signal.c | 8 -------- 1 file changed, 8 deletions(-) commit 5214cae77c11f5fdb13ebe478067a6008c4da630 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Mon May 23 14:39:00 2016 +0300 MIPS: devicetree: fix cpu interrupt controller node-names Here is the quote from [1]: The unit-address must match the first address specified in the reg property of the node. If the node has no reg property, the @ and unit-address must be omitted and the node-name alone differentiates the node from other nodes at the same level This patch adjusts MIPS dts-files and devicetree binding documentation in accordance with [1]. [1] Power.org(tm) Standard for Embedded Power Architecture(tm) Platform Requirements (ePAPR). Version 1.1 – 08 April 2011. Chapter 2.2.1.1 Node Name Requirements Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13345/ Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/mips/cpu_irq.txt | 2 +- arch/mips/boot/dts/ingenic/jz4740.dtsi | 2 +- arch/mips/boot/dts/ralink/mt7620a.dtsi | 2 +- arch/mips/boot/dts/ralink/rt2880.dtsi | 2 +- arch/mips/boot/dts/ralink/rt3050.dtsi | 2 +- arch/mips/boot/dts/ralink/rt3883.dtsi | 2 +- arch/mips/boot/dts/xilfpga/nexys4ddr.dts | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) commit 94cc36b84acc29f543b48bc5ed786011b112a666 Author: Maciej W. Rozycki <macro@imgtec.com> Date: Thu May 26 12:55:45 2016 +0100 MIPS: VDSO: Build with `-fno-strict-aliasing' Avoid an aliasing issue causing a build error in VDSO: In file included from include/linux/srcu.h:34:0, from include/linux/notifier.h:15, from ./arch/mips/include/asm/uprobes.h:9, from include/linux/uprobes.h:61, from include/linux/mm_types.h:13, from ./arch/mips/include/asm/vdso.h:14, from arch/mips/vdso/vdso.h:27, from arch/mips/vdso/gettimeofday.c:11: include/linux/workqueue.h: In function 'work_static': include/linux/workqueue.h:186:2: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing] return *work_data_bits(work) & WORK_STRUCT_STATIC; ^ cc1: all warnings being treated as errors make[2]: *** [arch/mips/vdso/gettimeofday.o] Error 1 with a CONFIG_DEBUG_OBJECTS_WORK configuration and GCC 5.2.0. Include `-fno-strict-aliasing' along with compiler options used, as required for kernel code, fixing a problem present since the introduction of VDSO with commit ebb5e78cc634 ("MIPS: Initial implementation of a VDSO"). Thanks to Tejun for diagnosing this properly! Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Fixes: ebb5e78cc634 ("MIPS: Initial implementation of a VDSO") Cc: Tejun Heo <tj@kernel.org> Cc: linux-mips@linux-mips.org Cc: stable@vger.kernel.org # v4.3+ Patchwork: https://patchwork.linux-mips.org/patch/13357/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/vdso/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 41cc07be42835a5c35b409af3914b8fcaedd0d72 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Wed May 25 12:58:40 2016 +0100 MIPS: Pistachio: Enable KASLR Allow KASLR to be selected on Pistachio based systems. Tested on a Creator Ci40. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Andrew Bresticker <abrestic@chromium.org> Cc: Jonas Gorski <jogo@openwrt.org> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13356/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 1 + arch/mips/pistachio/init.c | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) commit aedcfbe06558a9f53002e82d5be64c6c94687726 Author: Harvey Hunt <harvey.hunt@imgtec.com> Date: Wed May 25 11:06:35 2016 +0100 MIPS: lib: Mark intrinsics notrace On certain MIPS32 devices, the ftrace tracer "function_graph" uses __lshrdi3() during the capturing of trace data. ftrace then attempts to trace __lshrdi3() which leads to infinite recursion and a stack overflow. Fix this by marking __lshrdi3() as notrace. Mark the other compiler intrinsics as notrace in case the compiler decides to use them in the ftrace path. Signed-off-by: Harvey Hunt <harvey.hunt@imgtec.com> Cc: <linux-mips@linux-mips.org> Cc: <linux-kernel@vger.kernel.org> Cc: <stable@vger.kernel.org> # 4.2.x- Patchwork: https://patchwork.linux-mips.org/patch/13354/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lib/ashldi3.c | 2 +- arch/mips/lib/ashrdi3.c | 2 +- arch/mips/lib/bswapdi.c | 2 +- arch/mips/lib/bswapsi.c | 2 +- arch/mips/lib/cmpdi2.c | 2 +- arch/mips/lib/lshrdi3.c | 2 +- arch/mips/lib/ucmpdi2.c | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) commit aa76042a016474775ccd187c068669148c30c3bb Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 27 22:25:23 2016 +0100 MIPS: Fix 64-bit HTW configuration The Hardware page Table Walker (HTW) is being misconfigured on 64-bit kernels. The PWSize.PS (pointer size) bit determines whether pointers within directories are loaded as 32-bit or 64-bit addresses, but was never being set to 1 for 64-bit kernels where the unsigned long in pgd_t is 64-bits wide. This actually reduces rather than improves performance when the HTW is enabled on P6600 since the HTW is initiated lots, but walks are all aborted due I think to bad intermediate pointers. Since we were already taking the width of the PTEs into account by setting PWSize.PTEW, which is the left shift applied to the page table index *in addition to* the native pointer size, we also need to reduce PTEW by 1 when PS=1. This is done by calculating PTEW based on the relative size of pte_t compared to pgd_t. Finally in order for the HTW to be used when PS=1, the appropriate XK/XS/XU bits corresponding to the different 64-bit segments need to be set in PWCtl. We enable only XU for now to enable walking for XUSeg. Supporting walking for XKSeg would be a bit more involved so is left for a future patch. It would either require the use of a per-CPU top level base directory if supported by the HTW (a bit like pgd_current but with a second entry pointing at swapper_pg_dir), or the HTW would prepend bit 63 of the address to the global directory index which doesn't really match how we split user and kernel page directories. Fixes: cab25bc7537b ("MIPS: Extend hardware table walking support to MIPS64") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13364/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 6446e6cf440f6ee0f8b64c32968a8434205c1f59 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 27 22:25:22 2016 +0100 MIPS: Add 64-bit HTW fields Add field definitions for some of the 64-bit specific Hardware page Table Walker (HTW) register fields in PWSize and PWCtl, in preparation for fixing the 64-bit HTW configuration. Also print these fields out along with the others in print_htw_config(). Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13363/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 8 ++++++++ arch/mips/mm/tlbex.c | 8 ++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) commit f46d92e86d21da7eb3b06e0675272ef57e1b8565 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:06:07 2016 +0200 MAINTAINERS: Add file patterns for mips device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13340/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 7ad2410c986b888323b8873df13d6505759c0275 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:05:45 2016 +0200 MAINTAINERS: Add file patterns for mips brcm device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Hauke Mehrtens <hauke@hauke-m.de> Cc: Rafał Miłecki <zajec5@gmail.com> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13339/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 5aadab0c1a3451565dec3b02ebbe162854d39181 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 20 23:28:41 2016 +0100 MIPS: Simplify DSP instruction encoding macros Simplify the DSP instruction wrapper macros which use explicit encodings for microMIPS and normal MIPS by using the new encoding macros and removing duplication. To me this makes it easier to read since it is much shorter, but it also ensures .insn is used, preventing objdump disassembling the microMIPS code as normal MIPS. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13314/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 107 +++++++-------------------------------- 1 file changed, 17 insertions(+), 90 deletions(-) commit c84700cc575f4625e719817595b3df33c00307c7 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 20 23:28:40 2016 +0100 MIPS: Add missing tlbinvf/XPA microMIPS encodings Hardcoded MIPS instruction encodings are provided for tlbinvf, mfhc0 & mthc0 instructions, but microMIPS encodings are missing. I doubt any microMIPS cores exist at present which support these instructions, but the microMIPS encodings exist, and microMIPS cores may support them in the future. Add the missing microMIPS encodings using the new macros. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13313/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 6e1b29c3094688b6803fa1f9d5da676a7d0fbff9 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 20 23:28:39 2016 +0100 MIPS: Fix little endian microMIPS MSA encodings When the toolchain doesn't support MSA we encode MSA instructions explicitly in assembly. Unfortunately we use .word for both MIPS and microMIPS encodings which is wrong, since 32-bit microMIPS instructions are made up from a pair of halfwords. - The most significant halfword always comes first, so for little endian builds the halves will be emitted in the wrong order. - 32-bit alignment isn't guaranteed, so the assembler may insert a 16-bit nop instruction to pad the instruction stream to a 32-bit boundary. Use the new instruction encoding macros to encode microMIPS MSA instructions correctly. Fixes: d96cc3d1ec5d ("MIPS: Add microMIPS MSA support.") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <Paul.Burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13312/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/asmmacro.h | 99 ++++++++++++++++++++-------------------- arch/mips/include/asm/msa.h | 21 ++++----- 2 files changed, 58 insertions(+), 62 deletions(-) commit 1c48a177351ba8cbf6871f035496fce0e11d8fa3 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 20 23:28:38 2016 +0100 MIPS: Add missing VZ accessor microMIPS encodings Toolchains may be used which support microMIPS but not VZ instructions (i.e. binutis 2.22 & 2.23), so extend the explicitly encoded versions of the guest COP0 register & guest TLB access macros to support microMIPS encodings too, using the new macros. This prevents non-microMIPS instructions being executed in microMIPS mode during CPU probe on cores supporting VZ (e.g. M5150), which cause reserved instruction exceptions early during boot. Fixes: bad50d79255a ("MIPS: Fix VZ probe gas errors with binutils <2.24") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13311/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) commit 0dfa1c12f300d06f95d861d2718ef198e37473a6 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 20 23:28:37 2016 +0100 MIPS: Add inline asm encoding helpers To allow simplification of macros which use inline assembly to explicitly encode instructions, add a few simple abstractions to mipsregs.h which expand to specific microMIPS or normal MIPS encodings depending on what type of kernel is being built: _ASM_INSN_IF_MIPS(_enc) : Emit a 32bit MIPS instruction if microMIPS is not enabled. _ASM_INSN32_IF_MM(_enc) : Emit a 32bit microMIPS instruction if enabled. _ASM_INSN16_IF_MM(_enc) : Emit a 16bit microMIPS instruction if enabled. The macros can be used one after another since the MIPS / microMIPS macros are mutually exclusive, for example: __asm__ __volatile__( ".set push\n\t" ".set noat\n\t" "# mfgc0 $1, $%1, %2\n\t" _ASM_INSN_IF_MIPS(0x40610000 | %1 << 11 | %2) _ASM_INSN32_IF_MM(0x002004fc | %1 << 16 | %2 << 11) "move %0, $1\n\t" ".set pop" : "=r" (__res) : "i" (source), "i" (sel)); Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13310/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit 4939788eb8559754a120531c49ffa96bb30fee06 Author: Ralf Baechle <ralf@linux-mips.org> Date: Sun May 22 00:39:18 2016 +0200 MIPS: Spelling fix lets -> let's As noticed by Sergei in the discussion of Andrea Gelmini's patch series. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Reported-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> arch/mips/include/asm/mach-au1x00/au1xxx_dbdma.h | 2 +- arch/mips/include/asm/mach-lantiq/falcon/lantiq_soc.h | 2 +- arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h | 2 +- arch/mips/kernel/branch.c | 4 ++-- arch/mips/kernel/elf.c | 2 +- arch/mips/kernel/mips-r2-to-r6-emul.c | 2 +- arch/mips/sgi-ip27/ip27-nmi.c | 2 +- arch/mips/sgi-ip27/ip27-xtalk.c | 2 +- arch/mips/sni/rm200.c | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) commit a320a1156ac987ae45d2a922f8f7355d67658e83 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:02:26 2016 +0200 MIPS: VR41xx: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13338/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/vr41xx/common/cmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5004614b34e8af205356f557ef1fec4a710bba20 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:57 2016 +0200 MIPS: oprofile: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: rric@kernel.org Cc: linux-mips@linux-mips.org Cc: trivial@kernel.org Cc: oprofile-list@lists.sf.net Patchwork: https://patchwork.linux-mips.org/patch/13334/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/oprofile/op_impl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e7e3346cc64fff306694bdc41908283d195339c1 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:51 2016 +0200 MIPS: math-emu: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: macro@imgtec.com Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13333/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/dsemul.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 209b877833ef256cae4091763f32635ba0b79fdc Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:36 2016 +0200 MIPS: lib: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13331/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lib/memcpy.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a90c59e636da2352ab9d2f51bf0d6c9b2eef3c13 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:27 2016 +0200 MIPS: kernel: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: paul.burton@imgtec.com Cc: macro@imgtec.com Cc: james.hogan@imgtec.com Cc: jslaby@suse.cz Cc: adam.buchbinder@gmail.com Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13330/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/process.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f5be47f5a4b74ca4bc58348a0b2a6aa4c8cba1be Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:20 2016 +0200 MIPS: R6: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: macro@imgtec.com Cc: paul.burton@imgtec.com Cc: Leonid.Yegoshin@imgtec.com Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13329/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/mips-r2-to-r6-emul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a9e7e4518c5152023b9ddebf1d47ee0473f3fab4 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:01:12 2016 +0200 MIPS: IP22/IP28: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: adam.buchbinder@gmail.com Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13328/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/sgi/hpc3.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit da66f8e637b1d9fbe285d9f3d1ea37e4b3029978 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:40 2016 +0200 MIPS: Cavium: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: david.daney@cavium.com Cc: janne.huttunen@nokia.com Cc: aaro.koskinen@nokia.com Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13324/ Patchwork: https://patchwork.linux-mips.org/patch/13325/ Patchwork: https://patchwork.linux-mips.org/patch/13326/ Patchwork: https://patchwork.linux-mips.org/patch/13327/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/octeon/cvmx-cmd-queue.h | 2 +- arch/mips/include/asm/octeon/cvmx-helper-board.h | 2 +- arch/mips/include/asm/octeon/cvmx-ipd.h | 2 +- arch/mips/include/asm/octeon/cvmx-pow.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 7a448b57a6165e9ff93adb4440459c22cbfa73a9 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:33 2016 +0200 MIPS: MT: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: linux-mips@linux-mips.org Cc: trivial@kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13323/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips_mt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fb0f6e8a2c0f01599bdf88a0ca146a44a0a58b5f Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:26 2016 +0200 MIPS: Loongson64: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: chenhc@lemote.com Cc: viresh.kumar@linaro.org Cc: linux-mips@linux-mips.org Cc: trivial@kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13322/ Patchwork: https://patchwork.linux-mips.org/patch/13332/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-loongson64/loongson_hwmon.h | 2 +- arch/mips/loongson64/loongson-3/hpet.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit dc3c27394d25360ac614c638fd505041792dd450 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:18 2016 +0200 MIPS: IP32: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13321/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-ip32/dma-coherence.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 87fd4e2692a2add7726fb5a497c617c99071de34 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:11 2016 +0200 MIPS: IP27: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13320/ Patchwork: https://patchwork.linux-mips.org/patch/13335/ Patchwork: https://patchwork.linux-mips.org/patch/13336/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-ip27/dma-coherence.h | 2 +- arch/mips/pci/ops-bridge.c | 4 ++-- arch/mips/sgi-ip27/ip27-hubio.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit e904b94a06c77a4241df7ba239c3b5fd1ddb1809 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:00:04 2016 +0200 MIPS: BCM63xx: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13319/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_enet.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit be9fde2eff7987067f58bea5d18d575335f9246f Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 13:59:56 2016 +0200 MIPS: Alchemy: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: trivial@kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13318/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-au1x00/gpio-au1300.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 20430e7648c8acd1ab70bd056293c6c571ca8fc5 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 13:59:48 2016 +0200 MIPS: hazards.h: Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: chenhc@lemote.com Cc: james.hogan@imgtec.com Cc: linux-mips@linux-mips.org Cc: trivial@kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13317/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/hazards.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 9b987c4d74ba2ac695d28a155e3cf2a8a48d426f Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Nov 8 12:44:31 2013 +0300 MIPS: Lasat: A couple off by one bugs in picvue_proc.c These should be ">=" instead of ">" or we go past the end of the pvc_lines[] array. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: linux-mips@linux-mips.org Cc: kernel-janitors@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/6124/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lasat/picvue_proc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2b436a351803f38d0c8ca9c26103472c8aaeb599 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Thu May 19 22:07:36 2016 +0200 MIPS: ralink: add MT7628 EPHY LEDs pinmux support Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: john@phrozen.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13308/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ralink/mt7620.c | 100 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) commit 07b50db6e685172a41b9978aebffb2438166d9b6 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Thu May 19 22:07:35 2016 +0200 MIPS: ralink: fix MT7628 wled_an pinmux gpio Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: john@phrozen.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13307/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ralink/mt7620.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit d7146829c9da24e285cb1b1f2156b5b3e2d40c07 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Thu May 19 22:07:34 2016 +0200 MIPS: ralink: fix MT7628 pinmux typos Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: john@phrozen.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13306/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ralink/mt7620.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f03984ca4fcfb356ee0765ae49a36288e6cdb165 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 18 17:04:38 2016 +0100 MIPS: Fix write_gc0_* macros when writing zero The versions of the __write_{32,64}bit_gc0_register() macros for when there is no virt support in the assembler use the "J" inline asm constraint to allow integer zero, but this needs to be accompanied by the "z" formatting string so that it turns into $0. Fix both macros to do this. Fixes: bad50d79255a ("MIPS: Fix VZ probe gas errors with binutils <2.24") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13289/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 63a8802f4fb60963d3f91b072f4d0424330ec0d4 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Wed May 18 17:12:36 2016 +0100 MIPS: CPS: Copy EVA configuration when starting secondary VPs. When starting secondary VPEs which support EVA and the SegCtl registers, copy the memory segmentation configuration from the running VPE to ensure that all VPEs in the core have a consistent virtual memory map. The EVA configuration of secondary cores is dealt with when starting the core via the CM. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13291/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cps-vec.S | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 5c33f8b2e54c519c42a30cfb34d9ecb70631bf83 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Wed May 18 17:12:35 2016 +0100 MIPS: Add definitions of SegCtl registers and use them The SegCtl registers are standard for MIPSr3..MIPSr5. Add definitions of these registers and use them rather than constants Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: Chris Packham <judge.packham@gmail.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13290/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-malta/kernel-entry-init.h | 6 +++--- arch/mips/include/asm/mipsregs.h | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) commit dd317403d057546a29ececb446500fc243d2a704 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:36:00 2016 +0530 dt/bindings: Correct clk binding example for PIC32 gpio. Update binding example based on new clock binding scheme. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: linux-gpio@vger.kernel.org Cc: Mark Rutland <mark.rutland@arm.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13270/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/gpio/microchip,pic32-gpio.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 761e52bc70c048e93038c52942fee7b4cdda6c22 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:59 2016 +0530 dt/bindings: Correct clk binding example for PIC32 WDT. Update binding example based on new clock binding scheme. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13269/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/watchdog/microchip,pic32-wdt.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 58c376893bfbf489ba0ad258ec72e067d643fe16 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:58 2016 +0530 dt/bindings: Correct clk binding example for PIC32 DMT. Update binding example based on new clock binding scheme. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13268/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/watchdog/microchip,pic32-dmt.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9c719d87e97b5b697e4425dfedd62230bda16c35 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:57 2016 +0530 dt/bindings: Correct clk binding example for PIC32 serial. Update binding example based on new clock binding scheme. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Cc: Andrei Pistirica <andrei.pistirica@microchip.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13267/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/serial/microchip,pic32-uart.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 82cc37f6d7fa667498b4804ab2888beffab1c8c6 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:56 2016 +0530 dt/bindings: Correct clk binding example for PIC32 pinctrl Update binding example based on new clock binding scheme. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13266/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/pinctrl/microchip,pic32-pinctrl.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 684b23c1c189b97d4c5426359029c8fc8d5ecd71 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:55 2016 +0530 dt/bindings: Correct clk binding example for PIC32 SDHCI Update binding example based on new clock binding documentation. [1] Documentation/devicetree/bindings/clock/microchip,pic32.txt Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Cc: Andrei Pistirica <andrei.pistirica@microchip.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ulf Hansson <ulf.hansson@linaro.org> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13265/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0f2d988d231373bd53d5102bf40792552ed11d87 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 18 00:08:49 2016 +0100 MIPS: Fix incomplete separation of XPA CPU feature Commit 12822570a29b ("MIPS: Separate XPA CPU feature into LPA and MVH") wasn't fully applied, possibly due to a conflict with commit f270d881fa55 ("MIPS: Detect MIPSr6 Virtual Processor support"). This left decode_config5() referring to the non-existent MIPS_CPU_XPA, which breaks the build when XPA is enabled: arch/mips/kernel/cpu-probe.c In function ‘decode_config5’: arch/mips/kernel/cpu-probe.c:838:17: error: ‘MIPS_CPU_XPA’ undeclared (first use in this function) c->options |= MIPS_CPU_XPA; ^ Apply the missing hunk, dropping the CONFIG_XPA ifdef and setting the MIPS_CPU_MVH option when Config5.MVH is set. Fixes: 12822570a29b ("MIPS: Separate XPA CPU feature into LPA and MVH") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Link: https://patchwork.linux-mips.org/patch/13112/ Patchwork: https://patchwork.linux-mips.org/patch/13277/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cpu-probe.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit ba01cf0e1244fc3e4a24b4a111148c0d70025b36 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue May 17 15:31:06 2016 +0100 irqchip: mips-gic: Setup EIC mode on each CPU if it's in use When EIC mode is in use (cpu_has_veic is true) enable it on each CPU during GIC initialisation. Otherwise there may be a mismatch between the hardware default interrupt model & that expected by the kernel. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: Matt Redfearn <matt.redfearn@imgtec.com> Tested-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13274/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/irqchip/irq-mips-gic.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit d642e4e7b42f379fb9383ef1505f9d67895fb815 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue May 17 15:31:05 2016 +0100 MIPS: smp-cps: Clear Status IPL field when using EIC When using an external interrupt controller (EIC) the interrupt mask bits in the cop0 Status register are reused for the Interrupt Priority Level, and any interrupts with a priority lower than the field will be ignored. Clear the field to 0 by default such that all interrupts are serviced. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: Matt Redfearn <matt.redfearn@imgtec.com> Tested-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Qais Yousef <qsyousef@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13273/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/smp-cps.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 640356a48750ff9ef3303d85158ef9c42c3a18b6 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue May 17 15:31:04 2016 +0100 MIPS: Clear Status IPL field when using EIC When using an external interrupt controller (EIC) the interrupt mask bits in the cop0 Status register are reused for the Interrupt Priority Level, and any interrupts with a priority lower than the field will be ignored. Clear the field to 0 by default such that all interrupts are serviced. Without doing so we default to arbitrarily ignoring all or some subset of interrupts. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: Matt Redfearn <matt.redfearn@imgtec.com> Tested-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Cc: Joe Perches <joe@perches.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13272/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/irq.c | 3 +++ 1 file changed, 3 insertions(+) commit ed2608faa0f701b1dbc65277a9e5c7ff7118bfd4 Merge: 06d2e78 f49cf3b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 19:14:35 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull more input subsystem updates from Dmitry Torokhov: "Just a few more driver fixes; new drivers will be coming in the next merge window" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: pwm-beeper - fix - scheduling while atomic Input: xpad - xbox one elite controller support Input: xpad - add more third-party controllers Input: xpad - prevent spurious input from wired Xbox 360 controllers Input: xpad - move pending clear to the correct location Input: uinput - handle compat ioctl for UI_SET_PHYS commit 06d2e7812ecd1b585c5e9e7bda8ee90acebaef8c Merge: 7d8eb50 72a71f8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 19:07:10 2016 -0700 Merge branch 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux Pull more i2c updates from Wolfram Sang: "Here is the second pull request from I2C for this merge window: - one new feature (which nearly fell through the cracks): i2c-dev does now use the cdev API so it can handle >256 minors. Seems people do need that. - two fixes for the just added DMA feature for i2c-rcar - some typo fixes" * 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux: i2c: dev: don't start function name with 'return' i2c: dev: switch from register_chrdev to cdev API i2c: xlr: rename ARCH_TANGOX to ARCH_TANGO i2c: at91: change log when dma configuration fails misc: at24: Fix typo in at24 header file i2c: rcar: should depend on HAS_DMA i2c: rcar: use dma_request_chan() commit 7d8eb50290e4edf8de36973728862f73ff0b94bc Merge: 23a3e17 a78ff11 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 18:54:59 2016 -0700 Merge branch 'for-linus-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml Pull UML updates from Richard Weinberger: "This contains a nice FPU fixup from Eli Cooper for UML" * 'for-linus-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml: um: add extended processor state save/restore support um: extend fpstate to _xstate to support YMM registers um: fix FPU state preservation around signal handlers commit 23a3e178b9f8be3a900c7b11d795e54b4a131af0 Merge: e0714ec 1112018 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 18:49:29 2016 -0700 Merge tag 'upstream-4.7-rc1' of git://git.infradead.org/linux-ubifs Pull UBI/UBIFS updates from Richard Weinberger: "This contains mostly cleanups and minor improvements of UBI and UBIFS" * tag 'upstream-4.7-rc1' of git://git.infradead.org/linux-ubifs: ubifs: ubifs_dump_inode: Fix dumping field bulk_read UBI: Fix static volume checks when Fastmap is used UBI: Set free_count to zero before walking through erase list UBI: Silence an unintialized variable warning UBI: Clean up return in ubi_remove_volume() UBI: Modify wrong comment in ubi_leb_map function. UBI: Don't read back all data in ubi_eba_copy_leb() UBI: Add ro-mode sysfs attribute commit e0714ec4f9efe7b86828b0dcc077fd8f5d8e5e91 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 17:20:27 2016 -0700 nfs: fix anonymous member initializer build failure with older compilers Older versions of gcc don't understand named initializers inside a anonymous structure or union member. It can be worked around by adding the bracin gin the initializer for the anonymous member. Without this, gcc 4.4.4 will fail the build with CC fs/nfs/nfs4state.o fs/nfs/nfs4state.c:69: error: unknown field ‘data’ specified in initializer fs/nfs/nfs4state.c:69: warning: missing braces around initializer fs/nfs/nfs4state.c:69: warning: (near initialization for ‘zero_stateid.<anonymous>.data’) make[2]: *** [fs/nfs/nfs4state.o] Error 1 introduced in commit 93b717fd81bf ("NFSv4: Label stateids with the type") Reported-and-tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Cc: Anna Schumaker <Anna.Schumaker@netapp.com> Cc: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nfs/nfs4state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d102a56edba7a3f236454716fa09920e66772044 Merge: 0121a32 3767e25 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 17:14:05 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs fixes from Al Viro: "Followups to the parallel lookup work: - update docs - restore killability of the places that used to take ->i_mutex killably now that we have down_write_killable() merged - Additionally, it turns out that I missed a prerequisite for security_d_instantiate() stuff - ->getxattr() wasn't the only thing that could be called before dentry is attached to inode; with smack we needed the same treatment applied to ->setxattr() as well" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: switch ->setxattr() to passing dentry and inode separately switch xattr_handler->set() to passing dentry and inode separately restore killability of old mutex_lock_killable(&inode->i_mutex) users add down_write_killable_nested() update D/f/directory-locking commit 3767e255b390d72f9a33c08d9e86c5f21f25860f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri May 27 11:06:05 2016 -0400 switch ->setxattr() to passing dentry and inode separately smack ->d_instantiate() uses ->setxattr(), so to be able to call it before we'd hashed the new dentry and attached it to inode, we need ->setxattr() instances getting the inode as an explicit argument rather than obtaining it from dentry. Similar change for ->getxattr() had been done in commit ce23e64. Unlike ->getxattr() (which is used by both selinux and smack instances of ->d_instantiate()) ->setxattr() is used only by smack one and unfortunately it got missed back then. Reported-by: Seung-Woo Kim <sw0312.kim@samsung.com> Tested-by: Casey Schaufler <casey@schaufler-ca.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 7 +++++++ drivers/staging/lustre/lustre/llite/llite_internal.h | 4 ++-- drivers/staging/lustre/lustre/llite/xattr.c | 6 ++---- fs/bad_inode.c | 4 ++-- fs/ecryptfs/crypto.c | 9 +++++---- fs/ecryptfs/ecryptfs_kernel.h | 4 ++-- fs/ecryptfs/inode.c | 7 ++++--- fs/ecryptfs/mmap.c | 3 ++- fs/fuse/dir.c | 6 +++--- fs/hfs/attr.c | 6 +++--- fs/hfs/hfs_fs.h | 2 +- fs/kernfs/inode.c | 11 ++++++----- fs/kernfs/kernfs-internal.h | 3 ++- fs/libfs.c | 5 +++-- fs/overlayfs/inode.c | 5 +++-- fs/overlayfs/overlayfs.h | 5 +++-- fs/xattr.c | 8 ++++---- include/linux/fs.h | 3 ++- include/linux/xattr.h | 3 ++- security/smack/smack_lsm.c | 2 +- 20 files changed, 59 insertions(+), 44 deletions(-) commit 0121a32201dcc72933fb6019c41661e2f8a02fc5 Merge: 559b6d9 2176519 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 16:44:39 2016 -0700 Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs Pull overlayfs update from Miklos Szeredi: "The meat of this is a change to use the mounter's credentials for operations that require elevated privileges (such as whiteout creation). This fixes behavior under user namespaces as well as being a nice cleanup" * 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs: ovl: Do d_type check only if work dir creation was successful ovl: update documentation ovl: override creds with the ones from the superblock mounter commit f49cf3b8b4c841457244c461c66186a719e13bcc Author: Manfred Schlaegl <manfred.schlaegl@gmx.at> Date: Fri May 27 16:36:36 2016 -0700 Input: pwm-beeper - fix - scheduling while atomic Pwm config may sleep so defer it using a worker. On a Freescale i.MX53 based board we ran into "BUG: scheduling while atomic" because input_inject_event locks interrupts, but imx_pwm_config_v2 sleeps. Tested on Freescale i.MX53 SoC with 4.6.0. Signed-off-by: Manfred Schlaegl <manfred.schlaegl@gmx.at> Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/pwm-beeper.c | 69 ++++++++++++++++++++++++++++------------- 1 file changed, 48 insertions(+), 21 deletions(-) commit 559b6d90a0beb375c46dffe18133012bfa29f441 Merge: aa00edc 56244ef Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 16:37:36 2016 -0700 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs cleanups and fixes from Chris Mason: "We have another round of fixes and a few cleanups. I have a fix for short returns from btrfs_copy_from_user, which finally nails down a very hard to find regression we added in v4.6. Dave is pushing around gfp parameters, mostly to cleanup internal apis and make it a little more consistent. The rest are smaller fixes, and one speelling fixup patch" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: (22 commits) Btrfs: fix handling of faults from btrfs_copy_from_user btrfs: fix string and comment grammatical issues and typos btrfs: scrub: Set bbio to NULL before calling btrfs_map_block Btrfs: fix unexpected return value of fiemap Btrfs: free sys_array eb as soon as possible btrfs: sink gfp parameter to convert_extent_bit btrfs: make state preallocation more speculative in __set_extent_bit btrfs: untangle gotos a bit in convert_extent_bit btrfs: untangle gotos a bit in __clear_extent_bit btrfs: untangle gotos a bit in __set_extent_bit btrfs: sink gfp parameter to set_record_extent_bits btrfs: sink gfp parameter to set_extent_new btrfs: sink gfp parameter to set_extent_defrag btrfs: sink gfp parameter to set_extent_delalloc btrfs: sink gfp parameter to clear_extent_dirty btrfs: sink gfp parameter to clear_record_extent_bits btrfs: sink gfp parameter to clear_extent_bits btrfs: sink gfp parameter to set_extent_bits btrfs: make find_workspace warn if there are no workspaces btrfs: make find_workspace always succeed ... commit 6f49a398b266d4895bd7e041db77a2b2ee1482a6 Author: Pavel Rojtberg <rojtberg@gmail.com> Date: Fri May 27 16:24:40 2016 -0700 Input: xpad - xbox one elite controller support added the according id and incresed XPAD_PKT_LEN to 64 as the elite controller sends at least 33 byte messages [1]. Verified to be working by [2]. [1]: https://franticrain.github.io/sniffs/XboxOneSniff.html [2]: https://github.com/paroj/xpad/issues/23 Signed-off-by: Pierre-Loup A. Griffais <eduke32@plagman.net> Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/joystick/xpad.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6538c3b2d2d220a974e47928b165ea09b9cfa6b4 Author: Pavel Rojtberg <rojtberg@gmail.com> Date: Fri May 27 16:24:20 2016 -0700 Input: xpad - add more third-party controllers Signed-off-by: Pierre-Loup A. Griffais <eduke32@plagman.net> Signed-off-by: Thomas Debesse <dev@illwieckz.net> Signed-off-by: aronschatz <aronschatz@aselabs.com> Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/joystick/xpad.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 1ff5fa3c6732f08e01ae12f12286d4728c9e4d86 Author: Cameron Gutman <aicommander@gmail.com> Date: Fri May 27 16:23:50 2016 -0700 Input: xpad - prevent spurious input from wired Xbox 360 controllers After initially connecting a wired Xbox 360 controller or sending it a command to change LEDs, a status/response packet is interpreted as controller input. This causes the state of buttons represented in byte 2 of the controller data packet to be incorrect until the next valid input packet. Wireless Xbox 360 controllers are not affected. Writing a new value to the LED device while holding the Start button and running jstest is sufficient to reproduce this bug. An event will come through with the Start button released. Xboxdrv also won't attempt to read controller input from a packet where byte 0 is non-zero. It also checks that byte 1 is 0x14, but that value differs between wired and wireless controllers and this code is shared by both. I think just checking byte 0 is enough to eliminate unwanted packets. The following are some examples of 3-byte status packets I saw: 01 03 02 02 03 00 03 03 03 08 03 00 Signed-off-by: Cameron Gutman <aicommander@gmail.com> Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com> Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/joystick/xpad.c | 4 ++++ 1 file changed, 4 insertions(+) commit 4efc6939a83c54fb3417541be48991afd0290ba3 Author: Pavel Rojtberg <rojtberg@gmail.com> Date: Fri May 27 16:22:25 2016 -0700 Input: xpad - move pending clear to the correct location otherwise we lose ff commands: https://github.com/paroj/xpad/issues/27 Signed-off-by: Pavel Rojtberg <rojtberg@gmail.com> Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/joystick/xpad.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa00edc1287a693eadc7bc67a3d73555d969b35d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 16:03:22 2016 -0700 make IS_ERR_VALUE() complain about non-pointer-sized arguments Now that the allmodconfig x86-64 build is clean wrt IS_ERR_VALUE() uses on integers, add a cast to a pointer and back to the argument, so that any new mis-uses of IS_ERR_VALUE() will cause warnings like warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] so that we don't re-introduce any bogus uses. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/err.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5d22fc25d4fc8096d2d7df27ea1893d4e055e764 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 15:57:31 2016 -0700 mm: remove more IS_ERR_VALUE abuses The do_brk() and vm_brk() return value was "unsigned long" and returned the starting address on success, and an error value on failure. The reasons are entirely historical, and go back to it basically behaving like the mmap() interface does. However, nobody actually wanted that interface, and it causes totally pointless IS_ERR_VALUE() confusion. What every single caller actually wants is just the simpler integer return of zero for success and negative error number on failure. So just convert to that much clearer and more common calling convention, and get rid of all the IS_ERR_VALUE() uses wrt vm_brk(). Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/ia32/ia32_aout.c | 17 ++++++++--------- fs/binfmt_aout.c | 18 +++++++----------- fs/binfmt_elf.c | 11 +++++------ include/linux/mm.h | 2 +- mm/mmap.c | 16 ++++++++-------- mm/nommu.c | 2 +- 6 files changed, 30 insertions(+), 36 deletions(-) commit 287980e49ffc0f6d911601e7e352a812ed27768e Author: Arnd Bergmann <arnd@arndb.de> Date: Fri May 27 23:23:25 2016 +0200 remove lots of IS_ERR_VALUE abuses Most users of IS_ERR_VALUE() in the kernel are wrong, as they pass an 'int' into a function that takes an 'unsigned long' argument. This happens to work because the type is sign-extended on 64-bit architectures before it gets converted into an unsigned type. However, anything that passes an 'unsigned short' or 'unsigned int' argument into IS_ERR_VALUE() is guaranteed to be broken, as are 8-bit integers and types that are wider than 'unsigned long'. Andrzej Hajda has already fixed a lot of the worst abusers that were causing actual bugs, but it would be nice to prevent any users that are not passing 'unsigned long' arguments. This patch changes all users of IS_ERR_VALUE() that I could find on 32-bit ARM randconfig builds and x86 allmodconfig. For the moment, this doesn't change the definition of IS_ERR_VALUE() because there are probably still architecture specific users elsewhere. Almost all the warnings I got are for files that are better off using 'if (err)' or 'if (err < 0)'. The only legitimate user I could find that we get a warning for is the (32-bit only) freescale fman driver, so I did not remove the IS_ERR_VALUE() there but changed the type to 'unsigned long'. For 9pfs, I just worked around one user whose calling conventions are so obscure that I did not dare change the behavior. I was using this definition for testing: #define IS_ERR_VALUE(x) ((unsigned long*)NULL == (typeof (x)*)NULL && \ unlikely((unsigned long long)(x) >= (unsigned long long)(typeof(x))-MAX_ERRNO)) which ends up making all 16-bit or wider types work correctly with the most plausible interpretation of what IS_ERR_VALUE() was supposed to return according to its users, but also causes a compile-time warning for any users that do not pass an 'unsigned long' argument. I suggested this approach earlier this year, but back then we ended up deciding to just fix the users that are obviously broken. After the initial warning that caused me to get involved in the discussion (fs/gfs2/dir.c) showed up again in the mainline kernel, Linus asked me to send the whole thing again. [ Updated the 9p parts as per Al Viro - Linus ] Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Andrew Morton <akpm@linux-foundation.org> Link: https://lkml.org/lkml/2016/1/7/363 Link: https://lkml.org/lkml/2016/5/27/486 Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> # For nvmem part Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/acpi/acpi_dbg.c | 22 +++++++++++----------- drivers/ata/sata_highbank.c | 2 +- drivers/clk/tegra/clk-tegra210.c | 2 +- drivers/cpufreq/omap-cpufreq.c | 2 +- drivers/crypto/caam/ctrl.c | 2 +- drivers/dma/sun4i-dma.c | 16 ++++++++-------- drivers/gpio/gpio-xlp.c | 2 +- drivers/gpu/drm/sti/sti_vtg.c | 4 ++-- drivers/gpu/drm/tilcdc/tilcdc_tfp410.c | 2 +- drivers/gpu/host1x/hw/intr_hw.c | 2 +- drivers/iommu/arm-smmu-v3.c | 18 +++++++++--------- drivers/iommu/arm-smmu.c | 8 ++++---- drivers/irqchip/irq-clps711x.c | 2 +- drivers/irqchip/irq-gic.c | 2 +- drivers/irqchip/irq-hip04.c | 2 +- drivers/irqchip/spear-shirq.c | 2 +- drivers/media/i2c/adp1653.c | 10 +++++----- drivers/media/platform/s5p-tv/mixer_drv.c | 2 +- drivers/mfd/twl4030-irq.c | 2 +- drivers/mmc/core/mmc.c | 4 ++-- drivers/mmc/host/dw_mmc.c | 6 +++--- drivers/mmc/host/sdhci-esdhc-imx.c | 2 +- drivers/mmc/host/sdhci-of-at91.c | 2 +- drivers/mmc/host/sdhci.c | 4 ++-- drivers/net/ethernet/freescale/fman/fman.c | 2 +- drivers/net/ethernet/freescale/fman/fman_muram.c | 4 ++-- drivers/net/ethernet/freescale/fman/fman_muram.h | 4 ++-- drivers/net/wireless/ti/wlcore/spi.c | 4 ++-- drivers/nvmem/core.c | 22 +++++++++++----------- drivers/tty/serial/amba-pl011.c | 2 +- drivers/tty/serial/sprd_serial.c | 2 +- drivers/video/fbdev/da8xx-fb.c | 4 ++-- fs/afs/write.c | 4 ---- fs/binfmt_flat.c | 6 +++--- fs/gfs2/dir.c | 15 +++++++++------ kernel/pid.c | 2 +- net/9p/client.c | 8 ++++---- sound/soc/qcom/lpass-platform.c | 4 ++-- 38 files changed, 102 insertions(+), 103 deletions(-) commit 7ded384a12688c2a86b618da16bc87713404dfcc Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 15:23:32 2016 -0700 mm: fix section mismatch warning The register_page_bootmem_info_node() function needs to be marked __init in order to avoid a new warning introduced by commit f65e91df25aa ("mm: use early_pfn_to_nid in register_page_bootmem_info_node"). Otherwise you'll get a warning about how a non-init function calls early_pfn_to_nid (which is __meminit) Cc: Yang Shi <yang.shi@linaro.org> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/memory_hotplug.h | 2 +- mm/memory_hotplug.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit af7d93729c7c2beadea8ec5a6e66c53bef0e6290 Merge: 564884f 11e6856 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 14:56:59 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge misc updates and fixes from Andrew Morton: - late-breaking ocfs2 updates - random bunch of fixes * emailed patches from Andrew Morton <akpm@linux-foundation.org>: mm: disable DEFERRED_STRUCT_PAGE_INIT on !NO_BOOTMEM mm/memcontrol.c: move comments for get_mctgt_type() to proper position mm/memcontrol.c: fix the margin computation in mem_cgroup_margin() mm/cma: silence warnings due to max() usage mm: thp: avoid false positive VM_BUG_ON_PAGE in page_move_anon_rmap() oom_reaper: close race with exiting task mm: use early_pfn_to_nid in register_page_bootmem_info_node mm: use early_pfn_to_nid in page_ext_init MAINTAINERS: Kdump maintainers update MAINTAINERS: add kexec_core.c and kexec_file.c mm: oom: do not reap task if there are live threads in threadgroup direct-io: fix direct write stale data exposure from concurrent buffered read ocfs2: bump up o2cb network protocol version ocfs2: o2hb: fix hb hung time ocfs2: o2hb: don't negotiate if last hb fail ocfs2: o2hb: add some user/debug log ocfs2: o2hb: add NEGOTIATE_APPROVE message ocfs2: o2hb: add NEGO_TIMEOUT message ocfs2: o2hb: add negotiate timer commit 11e685672a0861ce136cc4e7f6fdd11e5390b1fa Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Fri May 27 14:27:49 2016 -0700 mm: disable DEFERRED_STRUCT_PAGE_INIT on !NO_BOOTMEM When we have !NO_BOOTMEM, the deferred page struct initialization doesn't work well because the pages reserved in bootmem are released to the page allocator uncoditionally. It causes memory corruption and system crash eventually. As Mel suggested, the bootmem is retiring slowly. We fix the issue by simply hiding DEFERRED_STRUCT_PAGE_INIT when bootmem is enabled. Link: http://lkml.kernel.org/r/1460602170-5821-1-git-send-email-gwshan@linux.vnet.ibm.com Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Mel Gorman <mgorman@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7cf7806ce1e30f1691cf340f70b807acbdf419ef Author: Li RongQing <roy.qing.li@gmail.com> Date: Fri May 27 14:27:46 2016 -0700 mm/memcontrol.c: move comments for get_mctgt_type() to proper position Move the comments for get_mctgt_type() to be before get_mctgt_type() implementation. Link: http://lkml.kernel.org/r/1463644638-7446-1-git-send-email-roy.qing.li@gmail.com Signed-off-by: Li RongQing <roy.qing.li@gmail.com> Acked-by: 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> mm/memcontrol.c | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) commit cbedbac3e66121ddbac363776c23119f8eaeefda Author: Li RongQing <roy.qing.li@gmail.com> Date: Fri May 27 14:27:43 2016 -0700 mm/memcontrol.c: fix the margin computation in mem_cgroup_margin() mem_cgroup_margin() might return (memory.limit - memory_count) when the memsw.limit is in excess. This doesn't happen usually because we do not allow excess on hard limits and (memory.limit <= memsw.limit), but __GFP_NOFAIL charges can force the charge and cause the excess when no memory is really swappable (swap is full or no anonymous memory is left). [mhocko@suse.com: rewrote changelog] Link: http://lkml.kernel.org/r/20160525155122.GK20132@dhcp22.suse.cz Link: http://lkml.kernel.org/r/1464068266-27736-1-git-send-email-roy.qing.li@gmail.com Signed-off-by: Li RongQing <roy.qing.li@gmail.com> Acked-by: Vladimir Davydov <vdavydov@virtuozzo.com> Acked-by: 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> mm/memcontrol.c | 2 ++ 1 file changed, 2 insertions(+) commit badbda53e505089062e194c614e6f23450bc98b2 Author: Stephen Rothwell <sfr@canb.auug.org.au> Date: Fri May 27 14:27:41 2016 -0700 mm/cma: silence warnings due to max() usage pageblock_order can be (at least) an unsigned int or an unsigned long depending on the kernel config and architecture, so use max_t(unsigned long, ...) when comparing it. fixes these warnings: In file included from include/asm-generic/bug.h:13:0, from arch/powerpc/include/asm/bug.h:127, from include/linux/bug.h:4, from include/linux/mmdebug.h:4, from include/linux/mm.h:8, from include/linux/memblock.h:18, from mm/cma.c:28: mm/cma.c: In function 'cma_init_reserved_mem': include/linux/kernel.h:748:17: warning: comparison of distinct pointer types lacks a cast (void) (&_max1 == &_max2); ^ mm/cma.c:186:27: note: in expansion of macro 'max' alignment = PAGE_SIZE << max(MAX_ORDER - 1, pageblock_order); ^ mm/cma.c: In function 'cma_declare_contiguous': include/linux/kernel.h:748:17: warning: comparison of distinct pointer types lacks a cast (void) (&_max1 == &_max2); ^ include/linux/kernel.h:747:9: note: in definition of macro 'max' typeof(y) _max2 = (y); ^ mm/cma.c:270:29: note: in expansion of macro 'max' (phys_addr_t)PAGE_SIZE << max(MAX_ORDER - 1, pageblock_order)); ^ include/linux/kernel.h:748:17: warning: comparison of distinct pointer types lacks a cast (void) (&_max1 == &_max2); ^ include/linux/kernel.h:747:21: note: in definition of macro 'max' typeof(y) _max2 = (y); ^ mm/cma.c:270:29: note: in expansion of macro 'max' (phys_addr_t)PAGE_SIZE << max(MAX_ORDER - 1, pageblock_order)); ^ [akpm@linux-foundation.org: coding-style fixes] Link: http://lkml.kernel.org/r/20160526150748.5be38a4f@canb.auug.org.au Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/cma.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 0798d3c022dc63eb0ec02b511e1f76ca8411ef8e Author: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Date: Fri May 27 14:27:38 2016 -0700 mm: thp: avoid false positive VM_BUG_ON_PAGE in page_move_anon_rmap() If page_move_anon_rmap() is refiling a pmd-splitted THP mapped in a tail page from a pte, the "address" must be THP aligned in order for the page->index bugcheck to pass in the CONFIG_DEBUG_VM=y builds. Link: http://lkml.kernel.org/r/1464253620-106404-1-git-send-email-kirill.shutemov@linux.intel.com Fixes: 6d0a07edd17c ("mm: thp: calculate the mapcount correctly for THP pages during WP faults") Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Reported-by: Mika Westerberg <mika.westerberg@linux.intel.com> Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com> Reviewed-by: Andrea Arcangeli <aarcange@redhat.com> Cc: <stable@vger.kernel.org> [4.5] Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/rmap.c | 2 ++ 1 file changed, 2 insertions(+) commit e2fe14564d3316d1625ed20bf1083995f4960893 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 27 14:27:35 2016 -0700 oom_reaper: close race with exiting task Tetsuo has reported: Out of memory: Kill process 443 (oleg's-test) score 855 or sacrifice child Killed process 443 (oleg's-test) total-vm:493248kB, anon-rss:423880kB, file-rss:4kB, shmem-rss:0kB sh invoked oom-killer: gfp_mask=0x24201ca(GFP_HIGHUSER_MOVABLE|__GFP_COLD), order=0, oom_score_adj=0 sh cpuset=/ mems_allowed=0 CPU: 2 PID: 1 Comm: sh Not tainted 4.6.0-rc7+ #51 Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 07/31/2013 Call Trace: dump_stack+0x85/0xc8 dump_header+0x5b/0x394 oom_reaper: reaped process 443 (oleg's-test), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB In other words: __oom_reap_task exit_mm atomic_inc_not_zero tsk->mm = NULL mmput atomic_dec_and_test # > 0 exit_oom_victim # New victim will be # selected <OOM killer invoked> # no TIF_MEMDIE task so we can select a new one unmap_page_range # to release the memory The race exists even without the oom_reaper because anybody who pins the address space and gets preempted might race with exit_mm but oom_reaper made this race more probable. We can address the oom_reaper part by using oom_lock for __oom_reap_task because this would guarantee that a new oom victim will not be selected if the oom reaper might race with the exit path. This doesn't solve the original issue, though, because somebody else still might be pinning mm_users and so __mmput won't be called to release the memory but that is not really realiably solvable because the task will get away from the oom sight as soon as it is unhashed from the task_list and so we cannot guarantee a new victim won't be selected. [akpm@linux-foundation.org: fix use of unused `mm', Per Stephen] [akpm@linux-foundation.org: coding-style fixes] Fixes: aac453635549 ("mm, oom: introduce oom reaper") Link: http://lkml.kernel.org/r/1464271493-20008-1-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko <mhocko@suse.com> Reported-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/oom_kill.c | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) commit f65e91df25aa426289cbcb580ca3183e24979fb1 Author: Yang Shi <yang.shi@linaro.org> Date: Fri May 27 14:27:32 2016 -0700 mm: use early_pfn_to_nid in register_page_bootmem_info_node register_page_bootmem_info_node() is invoked in mem_init(), so it will be called before page_alloc_init_late() if DEFERRED_STRUCT_PAGE_INIT is enabled. But, pfn_to_nid() depends on memmap which won't be fully setup until page_alloc_init_late() is done, so replace pfn_to_nid() by early_pfn_to_nid(). Link: http://lkml.kernel.org/r/1464210007-30930-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memory_hotplug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe53ca54270a757f0a28ee6bf3a54d952b550ed0 Author: Yang Shi <yang.shi@linaro.org> Date: Fri May 27 14:27:30 2016 -0700 mm: use early_pfn_to_nid in page_ext_init page_ext_init() checks suitable pages with pfn_to_nid(), but pfn_to_nid() depends on memmap which will not be setup fully until page_alloc_init_late() is done. Use early_pfn_to_nid() instead of pfn_to_nid() so that page extension could be still used early even though CONFIG_ DEFERRED_STRUCT_PAGE_INIT is enabled and catch early page allocation call sites. Suggested by Joonsoo Kim [1], this fix basically undoes the change introduced by commit b8f1a75d61d840 ("mm: call page_ext_init() after all struct pages are initialized") and fixes the same problem with a better approach. [1] http://lkml.kernel.org/r/CAAmzW4OUmyPwQjvd7QUfc6W1Aic__TyAuH80MLRZNMxKy0-wPQ@mail.gmail.com Link: http://lkml.kernel.org/r/1464198689-23458-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> init/main.c | 3 +-- mm/page_ext.c | 4 +++- 2 files changed, 4 insertions(+), 3 deletions(-) commit f871f191357ebadb6ad7e8ecf6e8f40b694eea00 Author: Vivek Goyal <vgoyal@redhat.com> Date: Fri May 27 14:27:27 2016 -0700 MAINTAINERS: Kdump maintainers update I am proposing following updates to kdump maintainership. I have got busy in other things and not getting time to spend on kdump. Remove Haren Myneni as he has not participated in kdump development for a long time now. Add the names of Dave and Baoquan as kdump maintainers as they have been contributing to kdump for a long time now and they are in a much better position to spend time on this than me. Mark myself as a reviewer. Link: http://lkml.kernel.org/r/20160525131616.GB27291@redhat.com Signed-off-by: Vivek Goyal <vgoyal@redhat.com> Acked-by: Simon Horman <horms@verge.net.au> Cc: Haren Myneni <hbabu@us.ibm.com> Cc: Dave Young <dyoung@redhat.com> Cc: Baoquan He <bhe@redhat.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Cc: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 10540a6998de5d283e3e471f0d0f4e55e2a6872c Author: Minfei Huang <mnghuan@gmail.com> Date: Fri May 27 14:27:24 2016 -0700 MAINTAINERS: add kexec_core.c and kexec_file.c In the below commits kexec.c was split to kexec.c, kexec_file.c and kexec_core.c. commit a43cac0d9dc2 ("kexec: split kexec_file syscall code to kexec_file.c") commit 2965faa5e03d ("kexec: split kexec_load syscall from kexec core code") Both kexec_file.c and kexec_core.c still belong to the kexec component. In order to get correct mail lists by using the script get_maintainer.pl, add these files to MAINTAINERS. Link: http://lkml.kernel.org/r/1464189735-59113-1-git-send-email-mnghuan@gmail.com Signed-off-by: Minfei Huang <mnghuan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit edd9f7230f591b7988533b1cafb07f3c03555f19 Author: Vladimir Davydov <vdavydov@virtuozzo.com> Date: Fri May 27 14:27:21 2016 -0700 mm: oom: do not reap task if there are live threads in threadgroup If the current process is exiting, we don't invoke oom killer, instead we give it access to memory reserves and try to reap its mm in case nobody is going to use it. There's a mistake in the code performing this check - we just ignore any process of the same thread group no matter if it is exiting or not - see try_oom_reaper. Fix it. Link: http://lkml.kernel.org/r/1464087628-7318-1-git-send-email-vdavydov@virtuozzo.com Fixes: 3ef22dfff239 ("oom, oom_reaper: try to reap tasks which skip regular OOM killer path")Signed-off-by: Vladimir Davydov <vdavydov@virtuozzo.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/oom_kill.c | 2 -- 1 file changed, 2 deletions(-) commit 9ecd10b7a0270803fd5f36ab93173e6d5b41b895 Author: Eryu Guan <guaneryu@gmail.com> Date: Fri May 27 14:27:18 2016 -0700 direct-io: fix direct write stale data exposure from concurrent buffered read Currently direct writes inside i_size on a DIO_SKIP_HOLES filesystem are not allowed to allocate blocks(get_more_blocks() sets 'create' to 0 before calling get_block() callback), if it's a sparse file, direct writes fall back to buffered writes to avoid stale data exposure from concurrent buffered read. But there're two cases that can result in stale data exposure are not correctly detected. 1. The detection for "writing inside i_size" is not sufficient, writes can be treated as "extending writes" wrongly. For example, direct write 1FSB (file system block) to a 1FSB sparse file on ext2/3/4, starting from offset 0, in this case it's writing inside i_size, but 'create' is non-zero, because 'block_in_file' and '(i_size_read(inode) >> blkbits' are both zero. 2. Direct writes starting from or beyong i_size (not inside i_size) also could trigger block allocation and expose stale data. For example, consider a sparse file with i_size of 2k, and a write to offset 2k or 3k into the file, with a filesystem block size of 4k. (Thanks to Jeff Moyer for pointing this case out in his review.) The first problem can be demostrated by running ltp-aiodio test ADSP045 many times. When testing on extN filesystems, I see test failures occasionally, buffered read could read non-zero (stale) data. ADSP045: dio_sparse -a 4k -w 4k -s 2k -n 1 dio_sparse 0 TINFO : Dirtying free blocks dio_sparse 0 TINFO : Starting I/O tests non zero buffer at buf[0] => 0xffffffaa,ffffffaa,ffffffaa,ffffffaa non-zero read at offset 0 dio_sparse 0 TINFO : Killing childrens(s) dio_sparse 1 TFAIL : dio_sparse.c:191: 1 children(s) exited abnormally The second problem can also be reproduced easily by a hacked dio_sparse program, which accepts an option to specify the write offset. What we should really do is to disable block allocation for writes that could result in filling holes inside i_size. Link: http://lkml.kernel.org/r/1463156728-13357-1-git-send-email-guaneryu@gmail.com Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Eryu Guan <guaneryu@gmail.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/direct-io.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 38b52efd218bf2a11a5b4a8f56052cee6684cfec Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:16 2016 -0700 ocfs2: bump up o2cb network protocol version Two new messages are added to support negotiating hb timeout. Stop nodes frmo talking an old version to mount as they will cause the negotiation to fail. Link: http://lkml.kernel.org/r/1464231615-27939-1-git-send-email-junxiao.bi@oracle.com Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/tcp_internal.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 6633ca573165e000867e50caf94f60a75399b68b Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:13 2016 -0700 ocfs2: o2hb: fix hb hung time hr_last_timeout_start should be set as the last time where hb is still OK. When hb write timeout, hung time will be (jiffies - hr_last_timeout_start). Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 88dbe98dc72fa0c2b778210e2079cd69d2477b36 Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:10 2016 -0700 ocfs2: o2hb: don't negotiate if last hb fail Sometimes io error is returned when storage is down for a while. Like for iscsi device, stroage is made offline when session timeout, and this will make all io return -EIO. For this case, nodes shouldn't do negotiate timeout but should fence self. So let nodes fence self when o2hb_do_disk_heartbeat return an error, this is the same behavior with o2hb without negotiate timer. Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 1bd1290283d7939478062e80bdd9719d3a21522f Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:07 2016 -0700 ocfs2: o2hb: add some user/debug log Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 39 ++++++++++++++++++++++++++++++++------- 1 file changed, 32 insertions(+), 7 deletions(-) commit e76f8237a2f7b7220980c0fb3c6d0b1d48ba79ad Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:04 2016 -0700 ocfs2: o2hb: add NEGOTIATE_APPROVE message This message is used to re-queue write timeout timer and negotiate timer when all nodes suffer a write hung to storage, this makes node not fence self if storage down. Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) commit 34069b886f95356d68bf8315fa648c4ab3193cdd Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:27:01 2016 -0700 ocfs2: o2hb: add NEGO_TIMEOUT message This message is sent to master node when non-master nodes's negotiate timer expired. Master node records these nodes in a bitmap which is used to do write timeout timer re-queue decision. Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 66 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 65 insertions(+), 1 deletion(-) commit e0cbb79805083b8862182341ebf72266d58f6d12 Author: Junxiao Bi <junxiao.bi@oracle.com> Date: Fri May 27 14:26:58 2016 -0700 ocfs2: o2hb: add negotiate timer This series of patches is to fix the issue that when storage down, all nodes will fence self due to write timeout. With this patch set, all nodes will keep going until storage back online, except if the following issue happens, then all nodes will do as before to fence self. 1. io error got 2. network between nodes down 3. nodes panic This patch (of 6): When storage down, all nodes will fence self due to write timeout. The negotiate timer is designed to avoid this, with it node will wait until storage up again. Negotiate timer working in the following way: 1. The timer expires before write timeout timer, its timeout is half of write timeout now. It is re-queued along with write timeout timer. If expires, it will send NEGO_TIMEOUT message to master node(node with lowest node number). This message does nothing but marks a bit in a bitmap recording which nodes are negotiating timeout on master node. 2. If storage down, nodes will send this message to master node, then when master node finds its bitmap including all online nodes, it sends NEGO_APPROVL message to all nodes one by one, this message will re-queue write timeout timer and negotiate timer. For any node doesn't receive this message or meets some issue when handling this message, it will be fenced. If storage up at any time, o2hb_thread will run and re-queue all the timer, nothing will be affected by these two steps. Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Ryan Ding <ryan.ding@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> Cc: Gang He <ghe@suse.com> Cc: rwxybh <rwxybh@126.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 51 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 47 insertions(+), 4 deletions(-) commit 564884fbdecaea56fb65f2f32963059d3049b967 Merge: 4cae85b c7de572 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 14:28:09 2016 -0700 Merge branch 'for-linus' of git://git.kernel.dk/linux-block Pull block fixes from Jens Axboe: "A set of fixes that wasn't included in the first merge window pull request. This pull request contains: - A set of NVMe fixes from Keith, and one from Nic for the integrity side of it. - Fix from Ming, clearing ->mq_ops if we don't successfully setup a queue for multiqueue. - A set of stability fixes for bcache from Jiri, and also marking bcache as orphaned as it's no longer actively maintained (in mainline, at least)" * 'for-linus' of git://git.kernel.dk/linux-block: blk-mq: clear q->mq_ops if init fail MAINTAINERS: mark bcache as orphan bcache: bch_gc_thread() is not freezable bcache: bch_allocator_thread() is not freezable bcache: bch_writeback_thread() is not freezable nvme/host: Add missing blk_integrity tag_size + flags assignments NVMe: Add device ID's with stripe quirk NVMe: Short-cut removal on surprise hot-unplug NVMe: Allow user initiated rescan NVMe: Reduce driver log spamming NVMe: Unbind driver on failure NVMe: Delete only created queues NVMe: Allocate queues only for online cpus commit 4cae85bed43d890f840019e2d21e39f96430802a Merge: c61b49c 507e617 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 14:17:15 2016 -0700 Merge tag 'for-linus-20160527' of git://git.infradead.org/linux-mtd Pull MTD fixes from Brian Norris: "We've already noticed a few flaws in the MTD work for v4.7-rc1: - The Atmel folks got ahead of themselves on trying to support their latest hardware and were working off incorrect documentation. Fix up the NAND driver to get this correct. - Fix up device tree example documentation to use the latest recommendations for describing NAND ECC algorithms" * tag 'for-linus-20160527' of git://git.infradead.org/linux-mtd: Documentation: dt: mtd: drop "soft_bch" from example Revert "mtd: atmel_nand: Support variable RB_EDGE interrupts" commit c61b49c79e1c1d4bc0c2fdc053ef56e65759b5fd Merge: 1e8143d 7fa1d27 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 14:08:56 2016 -0700 Merge tag 'drm-fixes-v4.7-rc1' of git://people.freedesktop.org/~airlied/linux Pull drm fixes from Dave Airlie: - one IMX built-in regression fix - a set of amdgpu fixes, mostly powerplay and polaris GPU stuff - a set of i915 fixes all over, many cc'ed to stable. The i915 batch contain support for DP++ dongle detection, which is used to fix some regressions in the HDMI color depth area * tag 'drm-fixes-v4.7-rc1' of git://people.freedesktop.org/~airlied/linux: (44 commits) drm/amd: add Kconfig dependency for ACP on DRM_AMDGPU drm/amdgpu: Fix hdmi deep color support. drm/amdgpu: fix bug in fence driver fini drm/i915: Stop automatically retiring requests after a GPU hang drm/i915: Unify intel_ring_begin() drm/i915: Ignore stale wm register values on resume on ilk-bdw (v2) drm/i915/psr: Try to program link training times correctly drm/imx: Match imx-ipuv3-crtc components using device node in platform data drm/i915/bxt: Adjusting the error in horizontal timings retrieval drm/i915: Don't leave old junk in ilk active watermarks on readout drm/i915: s/DPPL/DPLL/ for SKL DPLLs drm/i915: Fix gen8 semaphores id for legacy mode drm/i915: Set crtc_state->lane_count for HDMI drm/i915/BXT: Retrieving the horizontal timing for DSI drm/i915: Protect gen7 irq_seqno_barrier with uncore lock drm/i915: Re-enable GGTT earlier during resume on pre-gen6 platforms drm/i915: Determine DP++ type 1 DVI adaptor presence based on VBT drm/i915: Enable/disable TMDS output buffers in DP++ adaptor as needed drm/i915: Respect DP++ adaptor TMDS clock limit drm: Add helper for DP++ adaptors ... commit 1e8143db755f745a9842984de5e8b423f583aea2 Merge: 2566278 b740d2e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 13:56:02 2016 -0700 Merge tag 'platform-drivers-x86-v4.7-1' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86 Pull x86 platform driver updates from Darren Hart: "Mostly minor updates and cleanups. One new power management controller driver for Intel Core SoCs. platform/x86: - Add PMC Driver for Intel Core SoC dell-rbtn: - Ignore ACPI notifications if device is suspended thinkpad_acpi: - save kbdlight state on suspend and restore it on resume intel_menlow: - reduce code duplication asus-wmi: - provide access to ALS control ideapad-laptop: - add a new WMI string for ESC key surfacepro3_button: - Add a warning when switching to tablet mode sony-laptop: - Avoid oops on module unload for older laptops intel_telemetry: - Constify telemetry_core_ops structures fujitsu-laptop: - Use IS_ENABLED() instead of checking for built-in or module asus-laptop: - correct error handling in sysfs_acpi_set - remove redundant initializers - correct error handling in asus_read_brightness() fujitsu-laptop: - Support radio LED" * tag 'platform-drivers-x86-v4.7-1' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86: platform/x86: Add PMC Driver for Intel Core SoC dell-rbtn: Ignore ACPI notifications if device is suspended thinkpad_acpi: save kbdlight state on suspend and restore it on resume intel_menlow: reduce code duplication asus-wmi: provide access to ALS control ideapad-laptop: add a new WMI string for ESC key surfacepro3_button: Add a warning when switching to tablet mode sony-laptop: Avoid oops on module unload for older laptops intel_telemetry: Constify telemetry_core_ops structures fujitsu-laptop: Use IS_ENABLED() instead of checking for built-in or module asus-laptop: correct error handling in sysfs_acpi_set asus-laptop: remove redundant initializers asus-laptop: correct error handling in asus_read_brightness() fujitsu-laptop: Support radio LED commit 2566278551d3db875bc3bbfc41b42f2e80392108 Merge: e28e909 22e2f9f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 13:49:24 2016 -0700 Merge git://git.infradead.org/intel-iommu Pull intel IOMMU updates from David Woodhouse: "This patchset improves the scalability of the Intel IOMMU code by resolving two spinlock bottlenecks and eliminating the linearity of the IOVA allocator, yielding up to ~5x performance improvement and approaching 'iommu=off' performance" * git://git.infradead.org/intel-iommu: iommu/vt-d: Use per-cpu IOVA caching iommu/iova: introduce per-cpu caching to iova allocation iommu/vt-d: change intel-iommu to use IOVA frame numbers iommu/vt-d: avoid dev iotlb logic for domains with no dev iotlbs iommu/vt-d: only unmap mapped entries iommu/vt-d: correct flush_unmaps pfn usage iommu/vt-d: per-cpu deferred invalidation queues iommu/vt-d: refactoring of deferred flush entries commit e28e909c36bb5d6319953822d84df00fce7cbd18 Merge: dc03c0f fabc712 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 27 13:41:54 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm Pull second batch of KVM updates from Radim Krčmář: "General: - move kvm_stat tool from QEMU repo into tools/kvm/kvm_stat (kvm_stat had nothing to do with QEMU in the first place -- the tool only interprets debugfs) - expose per-vm statistics in debugfs and support them in kvm_stat (KVM always collected per-vm statistics, but they were summarised into global statistics) x86: - fix dynamic APICv (VMX was improperly configured and a guest could access host's APIC MSRs, CVE-2016-4440) - minor fixes ARM changes from Christoffer Dall: - new vgic reimplementation of our horribly broken legacy vgic implementation. The two implementations will live side-by-side (with the new being the configured default) for one kernel release and then we'll remove the legacy one. - fix for a non-critical issue with virtual abort injection to guests" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (70 commits) tools: kvm_stat: Add comments tools: kvm_stat: Introduce pid monitoring KVM: Create debugfs dir and stat files for each VM MAINTAINERS: Add kvm tools tools: kvm_stat: Powerpc related fixes tools: Add kvm_stat man page tools: Add kvm_stat vm monitor script kvm:vmx: more complete state update on APICv on/off KVM: SVM: Add more SVM_EXIT_REASONS KVM: Unify traced vector format svm: bitwise vs logical op typo KVM: arm/arm64: vgic-new: Synchronize changes to active state KVM: arm/arm64: vgic-new: enable build KVM: arm/arm64: vgic-new: implement mapped IRQ handling KVM: arm/arm64: vgic-new: Wire up irqfd injection KVM: arm/arm64: vgic-new: Add vgic_v2/v3_enable KVM: arm/arm64: vgic-new: vgic_init: implement map_resources KVM: arm/arm64: vgic-new: vgic_init: implement vgic_init KVM: arm/arm64: vgic-new: vgic_init: implement vgic_create KVM: arm/arm64: vgic-new: vgic_init: implement kvm_vgic_hyp_init ... commit 4f3532506a339d91e593da59eea4e7143e698ca3 Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Tue May 17 08:42:12 2016 +0000 ASoC: rsnd: open 31bit of SSICKR mask SSICKR (Gen2) / BRGCKR (Gen3) 31bit mask should be opened, because BRGB (= for 48kHz) might select it. Special thanks Yokoyama-san Reported-by: Hiroyuki Yokoyama <hiroyuki.yokoyama.vx@renesas.com> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sh/rcar/adg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5930122683dff58f0846b0f0405b4bd598a3ba6a Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri May 27 10:19:30 2016 -0400 switch xattr_handler->set() to passing dentry and inode separately preparation for similar switch in ->setxattr() (see the next commit for rationale). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/9p/acl.c | 6 +++--- fs/9p/xattr.c | 5 +++-- fs/btrfs/xattr.c | 12 +++++------- fs/ceph/xattr.c | 7 ++++--- fs/cifs/xattr.c | 9 +++++---- fs/ext2/xattr_security.c | 7 ++++--- fs/ext2/xattr_trusted.c | 7 ++++--- fs/ext2/xattr_user.c | 9 +++++---- fs/ext4/xattr_security.c | 7 ++++--- fs/ext4/xattr_trusted.c | 7 ++++--- fs/ext4/xattr_user.c | 9 +++++---- fs/f2fs/xattr.c | 12 ++++++------ fs/gfs2/xattr.c | 6 +++--- fs/hfsplus/xattr.c | 12 ++++++------ fs/hfsplus/xattr.h | 2 +- fs/hfsplus/xattr_security.c | 7 ++++--- fs/hfsplus/xattr_trusted.c | 7 ++++--- fs/hfsplus/xattr_user.c | 7 ++++--- fs/jffs2/security.c | 7 ++++--- fs/jffs2/xattr_trusted.c | 7 ++++--- fs/jffs2/xattr_user.c | 7 ++++--- fs/jfs/xattr.c | 14 ++++++-------- fs/nfs/nfs4proc.c | 19 +++++++++---------- fs/ocfs2/xattr.c | 23 +++++++++++++---------- fs/orangefs/xattr.c | 10 ++++++---- fs/posix_acl.c | 6 +++--- fs/reiserfs/xattr_security.c | 9 +++++---- fs/reiserfs/xattr_trusted.c | 9 +++++---- fs/reiserfs/xattr_user.c | 9 +++++---- fs/ubifs/xattr.c | 7 +++---- fs/xattr.c | 6 ++++-- fs/xfs/xfs_xattr.c | 9 +++++---- include/linux/xattr.h | 4 ++-- mm/shmem.c | 7 ++++--- 34 files changed, 156 insertions(+), 135 deletions(-) commit b740d2e9233cb33626d3b62210bcfc6a34baa839 Author: Rajneesh Bhardwaj <rajneesh.bhardwaj@intel.com> Date: Thu May 26 14:41:19 2016 +0530 platform/x86: Add PMC Driver for Intel Core SoC This patch adds the Power Management Controller driver as a PCI driver for Intel Core SoC architecture. This driver can utilize debugging capabilities and supported features as exposed by the Power Management Controller. Please refer to the below specification for more details on PMC features. http://www.intel.in/content/www/in/en/chipsets/100-series-chipset-datasheet-vol-2.html The current version of this driver exposes SLP_S0_RESIDENCY counter. This counter can be used for detecting fragile SLP_S0 signal related failures and take corrective actions when PCH SLP_S0 signal is not asserted after kernel freeze as part of suspend to idle flow (echo freeze > /sys/power/state). Intel Platform Controller Hub (PCH) asserts SLP_S0 signal when it detects favorable conditions to enter its low power mode. As a pre-requisite the SoC should be in deepest possible Package C-State and devices should be in low power mode. For example, on Skylake SoC the deepest Package C-State is Package C10 or PC10. Suspend to idle flow generally leads to PC10 state but PC10 state may not be sufficient for realizing the platform wide power potential which SLP_S0 signal assertion can provide. SLP_S0 signal is often connected to the Embedded Controller (EC) and the Power Management IC (PMIC) for other platform power management related optimizations. In general, SLP_S0 assertion == PC10 + PCH low power mode + ModPhy Lanes power gated + PLL Idle. As part of this driver, a mechanism to read the SLP_S0_RESIDENCY is exposed as an API and also debugfs features are added to indicate SLP_S0 signal assertion residency in microseconds. echo freeze > /sys/power/state wake the system cat /sys/kernel/debug/pmc_core/slp_s0_residency_usec Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj@intel.com> Signed-off-by: Vishwanath Somayaji <vishwanath.somayaji@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> MAINTAINERS | 8 ++ arch/x86/include/asm/pmc_core.h | 27 +++++ drivers/platform/x86/Kconfig | 12 ++ drivers/platform/x86/Makefile | 1 + drivers/platform/x86/intel_pmc_core.c | 200 ++++++++++++++++++++++++++++++++++ drivers/platform/x86/intel_pmc_core.h | 51 +++++++++ 6 files changed, 299 insertions(+) commit ff8651237f39cea60dc89b2d9f25d9ede3fc82c0 Author: Gabriele Mazzotta <gabriele.mzt@gmail.com> Date: Tue May 24 22:53:08 2016 +0200 dell-rbtn: Ignore ACPI notifications if device is suspended Some BIOSes unconditionally send an ACPI notification to RBTN when the system is resuming from suspend. This makes dell-rbtn send an input event to userspace as if a function key was pressed. Prevent this by ignoring all the notifications received while the device is suspended. Link: https://bugzilla.kernel.org/show_bug.cgi?id=106031 Signed-off-by: Gabriele Mazzotta <gabriele.mzt@gmail.com> Tested-by: Alex Hung <alex.hung@canonical.com> Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Cc: stable@vger.kernel.org Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/dell-rbtn.c | 56 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) commit afcedebc6a094224973534f43b396bbbf33fe44e Author: Marco Trevisan (Treviño) <mail@3v1n0.net> Date: Tue May 24 00:39:51 2016 +0200 thinkpad_acpi: save kbdlight state on suspend and restore it on resume Override default LED class suspend/resume handles, by keeping track of the brightness level before suspending so that it can be automatically restored on resume by calling default resume handler. Signed-off-by: Marco Trevisan (Treviño) <mail@3v1n0.net> Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/thinkpad_acpi.c | 43 +++++++++++++++++++++++++++++++++--- 1 file changed, 40 insertions(+), 3 deletions(-) commit a29ccf6ff3e07061253b9209a65edb8c0126f78d Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Sat Mar 26 22:40:26 2016 +0100 intel_menlow: reduce code duplication aux0_show and aux1_show consists of almost identical code. Pull that into a common helper and make them thin wrappers. Similarly for _store. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/intel_menlow.c | 49 +++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 27 deletions(-) commit aca234f6378864d85514be558746c0ea6eabfa8e Author: Oleksij Rempel <linux@rempel-privat.de> Date: Fri Apr 1 13:35:21 2016 +0200 asus-wmi: provide access to ALS control Asus Zenbook ux31a is providing ACPI0008 interface for ALS (Ambient Light Sensor), which is accessible for OS => Win 7. This sensor can be used with iio/acpi-als driver. Since it is disabled by default, we should use asus-wmi interface to enable it. Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/asus-wmi.c | 5 +++++ 1 file changed, 5 insertions(+) commit 2d98e0b942dd5ac359ced5183b4a5a769620380f Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 23:49:21 2016 +0200 ideapad-laptop: add a new WMI string for ESC key My patch to the ideapad-laptop driver to get the ESC key working on the Yoga 1170 (Yoga 3) failed to do the same for the following model, the Lenovo Yoga 700. Denis Gordienko managed to get it working by adding another GUID for the new WMI interface. I have adapted his patch to normal coding style and simplified it a bit for inclusion, but this patch is currently untested. Link: https://forums.lenovo.com/t5/Lenovo-Yoga-Series-Notebooks/YOGA-3-14-How-to-reclaim-my-Esc-key-and-permanently-disable/m-p/3317499 Signed-off-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Denis Gordienko <denis.gordienko.mail@gmail.com> [dvhart: Whitespace cleanup, static const char *const array declaration] Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/ideapad-laptop.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) commit e27ffe7e41b1dc747fd1d32d52f7453137f89ed9 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue May 10 14:49:55 2016 +0300 surfacepro3_button: Add a warning when switching to tablet mode Microsoft Surface Book has a tablet mode button. Print another message once on this event instead of repeating "Unknown event...". Unfortunately, proper support involves the _DSM method, which is not a discoverable interface. Just print a warning for now. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/surfacepro3_button.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit de26859dcf363d520cc44e59f6dcaf20ebe0aadf Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Sat May 21 11:50:35 2016 -0500 rtlwifi: Fix scheduling while atomic error from commit 49f86ec21c01 Commit 49f86ec21c01 ("rtlwifi: Change long delays to sleeps") was correct for most cases; however, driver rtl8192ce calls the affected routines while in atomic context. The kernel bug output is as follows: BUG: scheduling while atomic: wpa_supplicant/627/0x00000002 [...] [<ffffffff815c2b39>] __schedule+0x899/0xad0 [<ffffffff815c2dac>] schedule+0x3c/0x90 [<ffffffff815c5bb2>] schedule_hrtimeout_range_clock+0xa2/0x120 [<ffffffff810e8b80>] ? hrtimer_init+0x120/0x120 [<ffffffff815c5ba6>] ? schedule_hrtimeout_range_clock+0x96/0x120 [<ffffffff815c5c43>] schedule_hrtimeout_range+0x13/0x20 [<ffffffff815c568f>] usleep_range+0x4f/0x70 [<ffffffffa0667218>] rtl_rfreg_delay+0x38/0x50 [rtlwifi] [<ffffffffa06dd0e7>] rtl92c_phy_config_rf_with_headerfile+0xc7/0xe0 [rtl8192ce] To fix this bug, three of the changes from delay to sleep are reverted. Unfortunately, one of the changes involves a delay of 50 msec. The calling code will be modified so that this long delay can be avoided; however, this change is being pushed now to fix the problem in kernel 4.6.0. Fixes: 49f86ec21c01 ("rtlwifi: Change long delays to sleeps") Reported-by: James Feeney <james@nurealm.net> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: James Feeney <james@nurealm.net> Cc: Stable <stable@vger.kernel.org> [4.6+] Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 94abd778a7bb00ed5d00f56d9fbfcbf5b7c02a5c Author: Jaap Jan Meijer <jjmeijer88@gmail.com> Date: Thu May 12 18:25:08 2016 +0200 brcmfmac: add fallback for devices that do not report per-chain values If brcmf_cfg80211_get_station fails to determine the RSSI from the per-chain values get the value individually as a fallback. Fixes: 1f0dc59a6de9 ("brcmfmac: rework .get_station() callback") Signed-off-by: Jaap Jan Meijer <jjmeijer88@gmail.com> Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 507e617440d70bc4269daac1b0ee96671bf2761a Author: Baruch Siach <baruch@tkos.co.il> Date: Wed May 25 06:45:10 2016 +0300 Documentation: dt: mtd: drop "soft_bch" from example Commit 32698aafc9f0 (Documentation: devicetree: deprecate "soft_bch" nand-ecc-mode value, 2016-04-22) deprecated "soft_bch". Update the example to match. Signed-off-by: Baruch Siach <baruch@tkos.co.il> Acked-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com> Documentation/devicetree/bindings/mtd/nand.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit eb4606e64a7d548f5d60a9583baa8104890b2c6e Merge: 86c72d1 bf65921 Author: Takashi Iwai <tiwai@suse.de> Date: Fri May 27 17:16:53 2016 +0200 Merge tag 'asoc-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Updates for v4.7 part 2 Really sorry about this late pull request. It looks like at the time I sent my pull request for v4.7 there was some conflict or other issue which caused my script to stop merging the ASoC branches at some point after the HDMI changes. It's all specific driver updates, including: - New drivers for MAX98371 and TAS5720. - SPI support for TLV320AIC32x4. - TDM support for STI Uniperf IPs. This code should all have been in -next prior to the merge window apart from some fixes, it dropped out on the 18th. commit 5ea5888b2fbf5b230da62b2a21c8247bebb6c9cf Author: Wang Nan <wangnan0@huawei.com> Date: Fri May 27 11:35:51 2016 +0000 perf ctf: Convert invalid chars in a string before set value We observed some crazy apps on Android set their comm to unprintable string. For example: # cat /proc/10607/task/*/comm tencent.qqmusic ... Binder_2 日志输出线 <-- Chinese word 'log output thread' WifiManager ... 'perf data convert' fails to convert perf.data with such string to CTF format. For example: # cat << EOF > ./badguy.c #include <sys/prctl.h> int main(int argc, char *argv[]) { prctl(PR_SET_NAME, "\xe6\x97\xa5\xe5\xbf\x97\xe8\xbe\x93\xe5\x87\xba\xe7\xba\xbf"); while(1) sleep(1); return 0; } EOF # gcc ./badguy.c # perf record -e sched:* ./a.out # perf data convert --to-ctf ./bad.ctf CTF stream 4 flush failed [ perf data convert: Converted 'perf.data' into CTF data './bad.ctf' ] [ perf data convert: Converted and wrote 0.008 MB (78 samples) ] # babeltrace ./bad.ctf/ [error] Packet size (18446744073709551615 bits) is larger than remaining file size (262144 bits). [error] Stream index creation error. [error] Open file stream error. [warning] [Context] Cannot open_trace of format ctf at path ./bad.ctf. [warning] [Context] cannot open trace "./bad.ctf" from ./bad.ctf/ for reading. [error] Cannot open any trace for reading. [error] opening trace "./bad.ctf/" for reading. [error] none of the specified trace paths could be opened. This patch converts unprintable characters to hexadecimal word. After applying this patch the above test works correctly: # ~/perf data convert --to-ctf ./good.ctf [ perf data convert: Converted 'perf.data' into CTF data './good.ctf' ] [ perf data convert: Converted and wrote 0.008 MB (78 samples) ] # babeltrace ./good.ctf .. [23:14:35.491665268] (+0.000001100) sched:sched_wakeup: { cpu_id = 4 }, { perf_ip = 0xFFFFFFFF810AEF33, perf_tid = 0, perf_pid = 0, perf_id = 5123, perf_period = 1, common_type = 270, common_flags = 45, common_preempt_count = 4, common_pid = 0, comm = "\xe6\x97\xa5\xe5\xbf\x97\xe8\xbe\x93\xe5\x87\xba\xe7\xba\xbf", pid = 1057, prio = 120, success = 1, target_cpu = 4 } [23:14:35.491666230] (+0.000000962) sched:sched_wakeup: { cpu_id = 4 }, { perf_ip = 0xFFFFFFFF810AEF33, perf_tid = 0, perf_pid = 0, perf_id = 5122, perf_period = 1, common_type = 270, common_flags = 45, common_preempt_count = 4, common_pid = 0, comm = "\xe6\x97\xa5\xe5\xbf\x97\xe8\xbe\x93\xe5\x87\xba\xe7\xba\xbf", pid = 1057, prio = 120, success = 1, target_cpu = 4 } .. Committer note: To build perf with libabeltrace, use: $ mkdir -p /tmp/build/perf $ make LIBBABELTRACE=1 LIBBABELTRACE_DIR=/usr/local O=/tmp/build/perf -C tools/perf install-bin Or equivalent (no O=, fixup LIBBABELTRACE_DIR, etc). Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1464348951-179595-1-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/data-convert-bt.c | 41 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 39 insertions(+), 2 deletions(-) commit bf65921380cd50b87618df550398e06581f4a361 Merge: bc4efdb 937e92d Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:46:02 2016 +0100 Merge remote-tracking branch 'asoc/topic/wm8962' into asoc-next commit bc4efdb65938f5afd2bf5e63e871b76876ddf5bd Merge: 83652a3 2dfadff Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:46:01 2016 +0100 Merge remote-tracking branch 'asoc/topic/rt5677' into asoc-next commit 83652a39d724c20f050560f314b771a0289fd571 Merge: 0422e5e0 3fcdfc9 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:59 2016 +0100 Merge remote-tracking branch 'asoc/topic/wm8960' into asoc-next commit 0422e5e0be4cce09ed6a095410efa7ee0f978607 Merge: 77c92d2 cef794f Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:57 2016 +0100 Merge remote-tracking branch 'asoc/topic/qcom' into asoc-next commit 77c92d2b4c6a65ef7e9ca0e7d574d4d48fd5efae Merge: 38e3c63 ee4c879 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:55 2016 +0100 Merge remote-tracking branch 'asoc/topic/sti' into asoc-next commit 38e3c63da388f25c0b472a6624eb005076ea0dfb Merge: 5d8cf76 f5cc177 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:54 2016 +0100 Merge remote-tracking branch 'asoc/topic/tlv320aic31xx' into asoc-next commit 5d8cf7688ede7128ebdad8741ed5bdea0f2cd637 Merge: 631476d 54aba08 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:52 2016 +0100 Merge remote-tracking branch 'asoc/topic/kconfig' into asoc-next commit 631476d7fd93cc1cde1fc9ea6b3875f8eca79871 Merge: ad2ab00 9ff49ce Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:50 2016 +0100 Merge remote-tracking branch 'asoc/topic/rt298' into asoc-next commit ad2ab00c991298b55108b0c3ce21adb3a4b24ce5 Merge: e61249b 27becea Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:48 2016 +0100 Merge remote-tracking branch 'asoc/topic/mtk' into asoc-next commit e61249bb8a67a9f31a52f91259569aa44e9f6ca2 Merge: aaa36d3 989ff77 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:41 2016 +0100 Merge remote-tracking branch 'asoc/topic/omap' into asoc-next commit aaa36d3a98e20b858438eb16cd5c81f27be6dfd5 Merge: 4c1c16d bd023ad Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:37 2016 +0100 Merge remote-tracking branch 'asoc/topic/tas5270' into asoc-next commit 4c1c16d9a90a7dc3e2a950f7a8629e85a7e114e6 Merge: 463f7e5 8ea4167 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:36 2016 +0100 Merge remote-tracking branch 'asoc/topic/topology' into asoc-next commit 463f7e504a8400f0cc9b814662739050540c1a9d Merge: fbbeb39 e5b7d71 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:35 2016 +0100 Merge remote-tracking branch 'asoc/topic/pxa' into asoc-next commit fbbeb39183e08120b4116cdbadde91385f30d4f3 Merge: ae14dbf 7c37671 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:33 2016 +0100 Merge remote-tracking branch 'asoc/topic/simple' into asoc-next commit ae14dbfaa04180cc07b32ad6c3852d73917878d3 Merge: 94eaec4 1135ef1 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:30 2016 +0100 Merge remote-tracking branch 'asoc/topic/twl6040' into asoc-next commit 94eaec458c037a8ec3a7cd39118d0d4378cabf11 Merge: db1f328 af37d21 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:29 2016 +0100 Merge remote-tracking branch 'asoc/topic/max98371' into asoc-next commit db1f3283edcff33719592f3b374f40cf6e8256f4 Merge: 84bf51e de19651 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:27 2016 +0100 Merge remote-tracking branch 'asoc/topic/rcar' into asoc-next commit 84bf51ea9d3495119244b62cc3d07fe4d7bdc1e9 Merge: a5a3717 2213fc3 Author: Mark Brown <broonie@kernel.org> Date: Fri May 27 13:45:24 2016 +0100 Merge remote-tracking branch 'asoc/topic/tlv320aic32x4' into asoc-next commit 3dc6c1d54ff4cc9ce7e8513c286c970304cde20b Author: Wang Nan <wangnan0@huawei.com> Date: Tue May 24 09:21:28 2016 +0000 perf record: Fix crash when kptr is restricted Before this patch, a simple 'perf record' could fail if kptr_restrict is set to 1 (for normal user) or 2 (for root): # perf record ls WARNING: Kernel address maps (/proc/{kallsyms,modules}) are restricted, check /proc/sys/kernel/kptr_restrict. Samples in kernel functions may not be resolved if a suitable vmlinux file is not found in the buildid cache or in the vmlinux path. Samples in kernel modules won't be resolved at all. If some relocation was applied (e.g. kexec) symbols may be misresolved even with a suitable vmlinux or kallsyms file. Segmentation fault (core dumped) This patch skips perf_event__synthesize_kernel_mmap() when kptr is not available. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Fixes: 45e90056904b ("perf machine: Do not bail out if not managing to read ref reloc symbol") Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1464081688-167940-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/event.c | 2 ++ 1 file changed, 2 insertions(+) commit 38272dc4f1b17437871b786d567e1242d0904f5a Author: Wang Nan <wangnan0@huawei.com> Date: Tue May 24 09:21:27 2016 +0000 perf symbols: Check kptr_restrict for root If kptr_restrict is set to 2, even root is not allowed to see pointers. This patch checks kptr_restrict even if euid == 0. For root, report error if kptr_restrict is 2. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1464081688-167940-1-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/symbol.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 72a71f869c95dc11b73f09fe18c593d4a0618c3f Author: Wolfram Sang <wsa@the-dreams.de> Date: Fri May 27 13:13:01 2016 +0200 i2c: dev: don't start function name with 'return' I stumbled multiple times over 'return_i2c_dev', especially before the actual 'return res'. It makes the code hard to read, so reanme the function to 'put_i2c_dev' which also better matches 'get_free_i2c_dev'. Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-dev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 21765194cecf2e4514ad75244df459f188140a0f Author: Vivek Goyal <vgoyal@redhat.com> Date: Fri May 20 09:04:26 2016 -0400 ovl: Do d_type check only if work dir creation was successful d_type check requires successful creation of workdir as iterates through work dir and expects work dir to be present in it. If that's not the case, this check will always return d_type not supported even if underlying filesystem might be supporting it. So don't do this check if work dir creation failed in previous step. Signed-off-by: Vivek Goyal <vgoyal@redhat.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> fs/overlayfs/super.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit 942fd803e6dfc64d32f2ae4f160b2986bc5897b8 Author: Miklos Szeredi <mszeredi@redhat.com> Date: Fri May 27 08:55:26 2016 +0200 ovl: update documentation Two "fixme" items are actually fixed now. Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> Documentation/filesystems/overlayfs.txt | 9 --------- 1 file changed, 9 deletions(-) commit 3fe6e52f062643676eb4518d68cee3bc1272091b Author: Antonio Murdaca <amurdaca@redhat.com> Date: Thu Apr 7 15:48:25 2016 +0200 ovl: override creds with the ones from the superblock mounter In user namespace the whiteout creation fails with -EPERM because the current process isn't capable(CAP_SYS_ADMIN) when setting xattr. A simple reproducer: $ mkdir upper lower work merged lower/dir $ sudo mount -t overlay overlay -olowerdir=lower,upperdir=upper,workdir=work merged $ unshare -m -p -f -U -r bash Now as root in the user namespace: \# touch merged/dir/{1,2,3} # this will force a copy up of lower/dir \# rm -fR merged/* This ends up failing with -EPERM after the files in dir has been correctly deleted: unlinkat(4, "2", 0) = 0 unlinkat(4, "1", 0) = 0 unlinkat(4, "3", 0) = 0 close(4) = 0 unlinkat(AT_FDCWD, "merged/dir", AT_REMOVEDIR) = -1 EPERM (Operation not permitted) Interestingly, if you don't place files in merged/dir you can remove it, meaning if upper/dir does not exist, creating the char device file works properly in that same location. This patch uses ovl_sb_creator_cred() to get the cred struct from the superblock mounter and override the old cred with these new ones so that the whiteout creation is possible because overlay is wrong in assuming that the creds it will get with prepare_creds will be in the initial user namespace. The old cap_raise game is removed in favor of just overriding the old cred struct. This patch also drops from ovl_copy_up_one() the following two lines: override_cred->fsuid = stat->uid; override_cred->fsgid = stat->gid; This is because the correct uid and gid are taken directly with the stat struct and correctly set with ovl_set_attr(). Signed-off-by: Antonio Murdaca <runcom@redhat.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> fs/overlayfs/copy_up.c | 26 +------------------ fs/overlayfs/dir.c | 67 ++++-------------------------------------------- fs/overlayfs/overlayfs.h | 1 + fs/overlayfs/readdir.c | 14 +++------- fs/overlayfs/super.c | 18 ++++++++++++- 5 files changed, 27 insertions(+), 99 deletions(-) commit 7fa1d27b638db86516d7b3d8dc1a3576c72ee423 Merge: 79b3c71 157d2c7 Author: Dave Airlie <airlied@redhat.com> Date: Fri May 27 16:08:38 2016 +1000 Merge tag 'drm-intel-next-fixes-2016-05-25' of git://anongit.freedesktop.org/drm-intel into drm-next I see the main drm pull got merged, here's the first batch of fixes for 4.7 already. Fixes all around, a large portion cc: stable stuff. [airlied: the DP++ stuff is a regression fix]. * tag 'drm-intel-next-fixes-2016-05-25' of git://anongit.freedesktop.org/drm-intel: drm/i915: Stop automatically retiring requests after a GPU hang drm/i915: Unify intel_ring_begin() drm/i915: Ignore stale wm register values on resume on ilk-bdw (v2) drm/i915/psr: Try to program link training times correctly drm/i915/bxt: Adjusting the error in horizontal timings retrieval drm/i915: Don't leave old junk in ilk active watermarks on readout drm/i915: s/DPPL/DPLL/ for SKL DPLLs drm/i915: Fix gen8 semaphores id for legacy mode drm/i915: Set crtc_state->lane_count for HDMI drm/i915/BXT: Retrieving the horizontal timing for DSI drm/i915: Protect gen7 irq_seqno_barrier with uncore lock drm/i915: Re-enable GGTT earlier during resume on pre-gen6 platforms drm/i915: Determine DP++ type 1 DVI adaptor presence based on VBT drm/i915: Enable/disable TMDS output buffers in DP++ adaptor as needed drm/i915: Respect DP++ adaptor TMDS clock limit drm: Add helper for DP++ adaptors commit 79b3c7164c18e2fe9e69b0dcc0d45bab7ae3c968 Merge: e411295 425c452 Author: Dave Airlie <airlied@redhat.com> Date: Fri May 27 16:03:48 2016 +1000 Merge branch 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-next AMD GPU bugfixes: - Various powerplay bug fixes - Add some new polaris pci ids - misc bug fixes and code cleanups * 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux: (27 commits) drm/amd: add Kconfig dependency for ACP on DRM_AMDGPU drm/amdgpu: Fix hdmi deep color support. drm/amdgpu: fix bug in fence driver fini drm/amd/powerplay/hwmgr: use kmemdup drm/amd/powerplay/hwmgr: use kmemdup drm/amd/powerplay/hwmgr: use kmemdup drm/amd/powerplay: fix bugs of checking if dpm is running on Tonga drm/amdgpu: update Polaris11 golden setting drm/amdgpu: Add more Polaris 11 PCI IDs drm/amdgpu: update Polaris10 golden setting drm/amdgpu: add more Polaris10 DID drm/amd/amdgpu : Remove unused variable drm/amd/amdgpu : Remove unused variable drm/amd/amdgpu : Remove unused variable drm/amd/amdgpu/cz_dpm: Remove unused variable drm/amd/amdgpu : Remove unused variable drm/amd/powerplay: use ARRAY_SIZE() to calculate array size. drm/amdgpu: fix array out of bounds drm/radeon: fix array out of bounds drm/amd/powerplay: fix a bug on updating sclk for Tonga ... commit dc03c0f9d12d85286d5e3623aa96d5c2a271b8e6 Merge: f429d35 2552a39 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 22:32:05 2016 -0700 Merge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild Pull misc kbuild updates from Michal Marek: "This is the non-critical part of kbuild: - Coccinelle fixes, one semantic patch less in this round [Vaishali Thakkar, Wolfram Sang, Kees Cook] - rpm-pkg support for (open)SUSE's update-bootloader [Jiří Kosian] - rpm-pkg restored support for $RPMOPTS [Srinivas Pandruvada] - deb-pkg fixes for the linux-headers package [Bjørn Mork, Azriel Samson]" * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: coccicheck: Fix missing 0 index in kill loop scripts/package/Makefile: rpmbuild add support of RPMOPTS builddeb: fix missing headers in linux-headers package builddeb: include objtool binary in headers package kbuild/mkspec: support 'update-bootloader'-based systems scripts: coccinelle: remove check to move constants to right Coccinelle: setup_timer: Add space in front of parentheses commit f429d35588847fa1048f9dbdcc3cc1ee1b530041 Merge: 5b26fc8 fa64e5f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 22:27:09 2016 -0700 Merge branch 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild Pull kconfig update from Michal Marek: - fix for behavior of tristate choice items and fix for documentation of existing kconfig behavior [Dirk Gouders] - more helpful "unexpected data" kconfig warning [Paul Bolle] * 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: kconfig/symbol.c: handle choice_values that depend on 'm' symbols kconfig-language: elaborate on the type of a choice kconfig-language: fix comment on dependency-generated menu structures. kconfig: add unexpected data itself to warning commit 5b26fc8824da15a2fe9df89338a5a3cad41ba8ee Merge: e12fab2 c9c6837 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 22:01:22 2016 -0700 Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild Pull kbuild updates from Michal Marek: - new option CONFIG_TRIM_UNUSED_KSYMS which does a two-pass build and unexports symbols which are not used in the current config [Nicolas Pitre] - several kbuild rule cleanups [Masahiro Yamada] - warning option adjustments for gcov etc [Arnd Bergmann] - a few more small fixes * 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: (31 commits) kbuild: move -Wunused-const-variable to W=1 warning level kbuild: fix if_change and friends to consider argument order kbuild: fix adjust_autoksyms.sh for modules that need only one symbol kbuild: fix ksym_dep_filter when multiple EXPORT_SYMBOL() on the same line gcov: disable -Wmaybe-uninitialized warning gcov: disable tree-loop-im to reduce stack usage gcov: disable for COMPILE_TEST Kbuild: disable 'maybe-uninitialized' warning for CONFIG_PROFILE_ALL_BRANCHES Kbuild: change CC_OPTIMIZE_FOR_SIZE definition kbuild: forbid kernel directory to contain spaces and colons kbuild: adjust ksym_dep_filter for some cmd_* renames kbuild: Fix dependencies for final vmlinux link kbuild: better abstract vmlinux sequential prerequisites kbuild: fix call to adjust_autoksyms.sh when output directory specified kbuild: Get rid of KBUILD_STR kbuild: rename cmd_as_s_S to cmd_cpp_s_S kbuild: rename cmd_cc_i_c to cmd_cpp_i_c kbuild: drop redundant "PHONY += FORCE" kbuild: delete unnecessary "@:" kbuild: mark help target as PHONY ... commit e12fab28df1d7ae9369839a3af260a41447a5e79 Merge: 478a146 bbccb9c Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 21:32:40 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge fixes from Andrew Morton: "10 fixes" * emailed patches from Andrew Morton <akpm@linux-foundation.org>: drivers/pinctrl/intel/pinctrl-baytrail.c: fix build with gcc-4.4 update "mm/zsmalloc: don't fail if can't create debugfs info" dma-debug: avoid spinlock recursion when disabling dma-debug mm: oom_reaper: remove some bloat memcg: fix mem_cgroup_out_of_memory() return value. ocfs2: fix improper handling of return errno mm: slub: remove unused virt_to_obj() mm: kasan: remove unused 'reserved' field from struct kasan_alloc_meta mm: make CONFIG_DEFERRED_STRUCT_PAGE_INIT depends on !FLATMEM explicitly seqlock: fix raw_read_seqcount_latch() commit 478a1469a7d27fe6b2f85fc801ecdeb8afc836e6 Merge: 315227f 4d9a2c8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 20:00:28 2016 -0700 Merge tag 'dax-locking-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm Pull DAX locking updates from Ross Zwisler: "Filesystem DAX locking for 4.7 - We use a bit in an exceptional radix tree entry as a lock bit and use it similarly to how page lock is used for normal faults. This fixes races between hole instantiation and read faults of the same index. - Filesystem DAX PMD faults are disabled, and will be re-enabled when PMD locking is implemented" * tag 'dax-locking-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: dax: Remove i_mmap_lock protection dax: Use radix tree entry lock to protect cow faults dax: New fault locking dax: Allow DAX code to replace exceptional entries dax: Define DAX lock bit for radix tree exceptional entry dax: Make huge page handling depend of CONFIG_BROKEN dax: Fix condition for filling of PMD holes commit 315227f6da389f3a560f27f7777080857278e1b4 Merge: a10c38a 40543f6 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 19:34:26 2016 -0700 Merge tag 'dax-misc-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm Pull misc DAX updates from Vishal Verma: "DAX error handling for 4.7 - Until now, dax has been disabled if media errors were found on any device. This enables the use of DAX in the presence of these errors by making all sector-aligned zeroing go through the driver. - The driver (already) has the ability to clear errors on writes that are sent through the block layer using 'DSMs' defined in ACPI 6.1. Other misc changes: - When mounting DAX filesystems, check to make sure the partition is page aligned. This is a requirement for DAX, and previously, we allowed such unaligned mounts to succeed, but subsequent reads/writes would fail. - Misc/cleanup fixes from Jan that remove unused code from DAX related to zeroing, writeback, and some size checks" * tag 'dax-misc-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: dax: fix a comment in dax_zero_page_range and dax_truncate_page dax: for truncate/hole-punch, do zeroing through the driver if possible dax: export a low-level __dax_zero_page_range helper dax: use sb_issue_zerout instead of calling dax_clear_sectors dax: enable dax in the presence of known media errors (badblocks) dax: fallback from pmd to pte on error block: Update blkdev_dax_capable() for consistency xfs: Add alignment check for DAX mount ext2: Add alignment check for DAX mount ext4: Add alignment check for DAX mount block: Add bdev_dax_supported() for dax mount checks block: Add vfs_msg() interface dax: Remove redundant inode size checks dax: Remove pointless writeback from dax_do_io() dax: Remove zeroing from dax_io() dax: Remove dead zeroing code from fault handlers ext2: Avoid DAX zeroing to corrupt data ext2: Fix block zeroing in ext2_get_blocks() for DAX dax: Remove complete_unwritten argument DAX: move RADIX_DAX_ definitions to dax.c commit bbccb9c7bbeb6c78eb467c191c97360160f13704 Author: Andrew Morton <akpm@linux-foundation.org> Date: Thu May 26 15:16:30 2016 -0700 drivers/pinctrl/intel/pinctrl-baytrail.c: fix build with gcc-4.4 gcc-4.4 and thereabouts has issues with initializers of anonymous unions, and it generates the following warnings: drivers/pinctrl/intel/pinctrl-baytrail.c:413: error: unknown field 'simple_funcs' specified in initializer drivers/pinctrl/intel/pinctrl-baytrail.c:413: warning: missing braces around initializer drivers/pinctrl/intel/pinctrl-baytrail.c:413: warning: (near initialization for 'byt_score_groups[0].<anonymous>') drivers/pinctrl/intel/pinctrl-baytrail.c:415: error: unknown field 'simple_funcs' specified in initializer drivers/pinctrl/intel/pinctrl-baytrail.c:417: error: unknown field 'simple_funcs' specified in initializer ... Work around this. Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com> Cc: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 4abaac9b733ea44fcf0d561ec1813e0394e61c9d Author: Dan Streetman <ddstreet@ieee.org> Date: Thu May 26 15:16:27 2016 -0700 update "mm/zsmalloc: don't fail if can't create debugfs info" Some updates to commit d34f615720d1 ("mm/zsmalloc: don't fail if can't create debugfs info"): - add pr_warn to all stat failure cases - do not prevent module loading on stat failure Link: http://lkml.kernel.org/r/1463671123-5479-1-git-send-email-ddstreet@ieee.org Signed-off-by: Dan Streetman <ddstreet@ieee.org> Reviewed-by: Ganesh Mahendran <opensource.ganesh@gmail.com> Acked-by: Minchan Kim <minchan@kernel.org> Cc: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Cc: Dan Streetman <dan.streetman@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 35 ++++++++++++++++------------------- 1 file changed, 16 insertions(+), 19 deletions(-) commit 3017cd63f26fc655d56875aaf497153ba60e9edf Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Thu May 26 15:16:25 2016 -0700 dma-debug: avoid spinlock recursion when disabling dma-debug With netconsole (at least) the pr_err("... disablingn") call can recurse back into the dma-debug code, where it'll try to grab free_entries_lock again. Avoid the problem by doing the printk after dropping the lock. Link: http://lkml.kernel.org/r/1463678421-18683-1-git-send-email-ville.syrjala@linux.intel.com Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: <stable@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/dma-debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7ef949d77f95f0d129f0d404b336459a34a00101 Author: Michal Hocko <mhocko@suse.com> Date: Thu May 26 15:16:22 2016 -0700 mm: oom_reaper: remove some bloat mmput_async is currently used only from the oom_reaper which is defined only for CONFIG_MMU. We can save work_struct in mm_struct for !CONFIG_MMU. [akpm@linux-foundation.org: fix typo, per Minchan] Link: http://lkml.kernel.org/r/20160520061658.GB19172@dhcp22.suse.cz Reported-by: Minchan Kim <minchan@kernel.org> Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Minchan Kim <minchan@kernel.org> Cc: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm_types.h | 2 ++ include/linux/sched.h | 4 +++- kernel/fork.c | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) commit 1ebab2db065e99eed9ab2304d3b7ad25c9568612 Author: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Date: Thu May 26 15:16:19 2016 -0700 memcg: fix mem_cgroup_out_of_memory() return value. mem_cgroup_out_of_memory() is returning "true" if it finds a TIF_MEMDIE task after an eligible task was found, "false" if it found a TIF_MEMDIE task before an eligible task is found. This difference confuses memory_max_write() which checks the return value of mem_cgroup_out_of_memory(). Since memory_max_write() wants to continue looping, mem_cgroup_out_of_memory() should return "true" in this case. This patch sets a dummy pointer in order to return "true". Link: http://lkml.kernel.org/r/1463753327-5170-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Acked-by: Michal Hocko <mhocko@suse.com> Acked-by: Vladimir Davydov <vdavydov@virtuozzo.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> mm/memcontrol.c | 2 ++ 1 file changed, 2 insertions(+) commit 1f3a437fa027c75b26a64e2e71d7c374ff70f866 Author: Eric Ren <zren@suse.com> Date: Thu May 26 15:16:16 2016 -0700 ocfs2: fix improper handling of return errno Previously, if a bad inode was found in ocfs2_iget(), -ESTALE was returned back to the caller anyway. Since commit d2b9d71a2da7 ("ocfs2: check/fix inode block for online file check") can handle with return value from ocfs2_read_locked_inode() now, we know the exact errno returned for us. Link: http://lkml.kernel.org/r/1463970656-18413-1-git-send-email-zren@suse.com Signed-off-by: Eric Ren <zren@suse.com> Reviewed-by: Joseph Qi <joseph.qi@huawei.com> Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/inode.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit d96c84f8d27ce57ff08f12b9654d9f505a8cce6e Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Thu May 26 15:16:14 2016 -0700 mm: slub: remove unused virt_to_obj() It's unused since commit 7ed2f9e66385 ("mm, kasan: SLAB support") Link: http://lkml.kernel.org/r/1464020961-2242-1-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: David Rientjes <rientjes@google.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: Christoph Lameter <cl@linux.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/slub_def.h | 16 ---------------- 1 file changed, 16 deletions(-) commit 9725759a96efb1ce56a1b93455ac0ab1901c5327 Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Thu May 26 15:16:11 2016 -0700 mm: kasan: remove unused 'reserved' field from struct kasan_alloc_meta Commit cd11016e5f52 ("mm, kasan: stackdepot implementation. Enable stackdepot for SLAB") added 'reserved' field, but never used it. Link: http://lkml.kernel.org/r/1464021054-2307-1-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/kasan/kasan.h | 1 - 1 file changed, 1 deletion(-) commit 957949243bac5dc25e2a651f17059f54f184913e Author: Yang Shi <yang.shi@linaro.org> Date: Thu May 26 15:16:08 2016 -0700 mm: make CONFIG_DEFERRED_STRUCT_PAGE_INIT depends on !FLATMEM explicitly Per the suggestion from Michal Hocko [1], DEFERRED_STRUCT_PAGE_INIT requires some ordering wrt other initialization operations, e.g. page_ext_init has to happen after the whole memmap is initialized properly. For SPARSEMEM this requires to wait for page_alloc_init_late. Other memory models (e.g. flatmem) might have different initialization layouts (page_ext_init_flatmem). Currently DEFERRED_STRUCT_PAGE_INIT depends on MEMORY_HOTPLUG which in turn depends on SPARSEMEM || X86_64_ACPI_NUMA depends on ARCH_ENABLE_MEMORY_HOTPLUG and X86_64_ACPI_NUMA depends on NUMA which in turn disable FLATMEM memory model: config ARCH_FLATMEM_ENABLE def_bool y depends on X86_32 && !NUMA so FLATMEM is ruled out via dependency maze. Be explicit and disable FLATMEM for DEFERRED_STRUCT_PAGE_INIT so that we do not reintroduce subtle initialization bugs [1] http://lkml.kernel.org/r/20160523073157.GD2278@dhcp22.suse.cz Link: http://lkml.kernel.org/r/1464027356-32282-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Michal Hocko <mhocko@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 50755bc1c305340660bbfa65fdae3ed113d8fe0e Author: Alexey Dobriyan <adobriyan@gmail.com> Date: Thu May 26 15:16:06 2016 -0700 seqlock: fix raw_read_seqcount_latch() lockless_dereference() is supposed to take pointer not integer. Link: http://lkml.kernel.org/r/20160521201448.GA7429@p183.telecom.by Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/seqlock.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a10c38a4f385f5d7c173a263ff6bb2d36021b3bb Merge: ea8ea73 e536030 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 14:10:32 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client Pull Ceph updates from Sage Weil: "This changeset has a few main parts: - Ilya has finished a huge refactoring effort to sync up the client-side logic in libceph with the user-space client code, which has evolved significantly over the last couple years, with lots of additional behaviors (e.g., how requests are handled when cluster is full and transitions from full to non-full). This structure of the code is more closely aligned with userspace now such that it will be much easier to maintain going forward when behavior changes take place. There are some locking improvements bundled in as well. - Zheng adds multi-filesystem support (multiple namespaces within the same Ceph cluster) - Zheng has changed the readdir offsets and directory enumeration so that dentry offsets are hash-based and therefore stable across directory fragmentation events on the MDS. - Zheng has a smorgasbord of bug fixes across fs/ceph" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: (71 commits) ceph: fix wake_up_session_cb() ceph: don't use truncate_pagecache() to invalidate read cache ceph: SetPageError() for writeback pages if writepages fails ceph: handle interrupted ceph_writepage() ceph: make ceph_update_writeable_page() uninterruptible libceph: make ceph_osdc_wait_request() uninterruptible ceph: handle -EAGAIN returned by ceph_update_writeable_page() ceph: make fault/page_mkwrite return VM_FAULT_OOM for -ENOMEM ceph: block non-fatal signals for fault/page_mkwrite ceph: make logical calculation functions return bool ceph: tolerate bad i_size for symlink inode ceph: improve fragtree change detection ceph: keep leaf frag when updating fragtree ceph: fix dir_auth check in ceph_fill_dirfrag() ceph: don't assume frag tree splits in mds reply are sorted ceph: fix inode reference leak ceph: using hash value to compose dentry offset ceph: don't forbid marking directory complete after forward seek ceph: record 'offset' for each entry of readdir result ceph: define 'end/complete' in readdir reply as bit flags ... commit 56244ef151c3cd11f505020ab0b3f45454363bcc Author: Chris Mason <clm@fb.com> Date: Mon May 16 09:21:01 2016 -0700 Btrfs: fix handling of faults from btrfs_copy_from_user When btrfs_copy_from_user isn't able to copy all of the pages, we need to adjust our accounting to reflect the work that was actually done. Commit 2e78c927d79 changed around the decisions a little and we ended up skipping the accounting adjustments some of the time. This commit makes sure that when we don't copy anything at all, we still hop into the adjustments, and switches to release_bytes instead of write_bytes, since write_bytes isn't aligned. The accounting errors led to warnings during btrfs_destroy_inode: [ 70.847532] WARNING: CPU: 10 PID: 514 at fs/btrfs/inode.c:9350 btrfs_destroy_inode+0x2b3/0x2c0 [ 70.847536] Modules linked in: i2c_piix4 virtio_net i2c_core input_leds button led_class serio_raw acpi_cpufreq sch_fq_codel autofs4 virtio_blk [ 70.847538] CPU: 10 PID: 514 Comm: umount Tainted: G W 4.6.0-rc6_00062_g2997da1-dirty #23 [ 70.847539] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.0-1.fc24 04/01/2014 [ 70.847542] 0000000000000000 ffff880ff5cafab8 ffffffff8149d5e9 0000000000000202 [ 70.847543] 0000000000000000 0000000000000000 0000000000000000 ffff880ff5cafb08 [ 70.847547] ffffffff8107bdfd ffff880ff5cafaf8 000024868120013d ffff880ff5cafb28 [ 70.847547] Call Trace: [ 70.847550] [<ffffffff8149d5e9>] dump_stack+0x51/0x78 [ 70.847551] [<ffffffff8107bdfd>] __warn+0xfd/0x120 [ 70.847553] [<ffffffff8107be3d>] warn_slowpath_null+0x1d/0x20 [ 70.847555] [<ffffffff8139c9e3>] btrfs_destroy_inode+0x2b3/0x2c0 [ 70.847556] [<ffffffff812003a1>] ? __destroy_inode+0x71/0x140 [ 70.847558] [<ffffffff812004b3>] destroy_inode+0x43/0x70 [ 70.847559] [<ffffffff810b7b5f>] ? wake_up_bit+0x2f/0x40 [ 70.847560] [<ffffffff81200c68>] evict+0x148/0x1d0 [ 70.847562] [<ffffffff81398ade>] ? start_transaction+0x3de/0x460 [ 70.847564] [<ffffffff81200d49>] dispose_list+0x59/0x80 [ 70.847565] [<ffffffff81201ba0>] evict_inodes+0x180/0x190 [ 70.847566] [<ffffffff812191ff>] ? __sync_filesystem+0x3f/0x50 [ 70.847568] [<ffffffff811e95f8>] generic_shutdown_super+0x48/0x100 [ 70.847569] [<ffffffff810b75c0>] ? woken_wake_function+0x20/0x20 [ 70.847571] [<ffffffff811e9796>] kill_anon_super+0x16/0x30 [ 70.847573] [<ffffffff81365cde>] btrfs_kill_super+0x1e/0x130 [ 70.847574] [<ffffffff811e99be>] deactivate_locked_super+0x4e/0x90 [ 70.847576] [<ffffffff811e9e61>] deactivate_super+0x51/0x70 [ 70.847577] [<ffffffff8120536f>] cleanup_mnt+0x3f/0x80 [ 70.847579] [<ffffffff81205402>] __cleanup_mnt+0x12/0x20 [ 70.847581] [<ffffffff81098358>] task_work_run+0x68/0xa0 [ 70.847582] [<ffffffff810022b6>] exit_to_usermode_loop+0xd6/0xe0 [ 70.847583] [<ffffffff81002e1d>] do_syscall_64+0xbd/0x170 [ 70.847586] [<ffffffff817d4dbc>] entry_SYSCALL64_slow_path+0x25/0x25 This is the test program I used to force short returns from btrfs_copy_from_user void *dontneed(void *arg) { char *p = arg; int ret; while(1) { ret = madvise(p, BUFSIZE/4, MADV_DONTNEED); if (ret) { perror("madvise"); exit(1); } } } int main(int ac, char **av) { int ret; int fd; char *filename; unsigned long offset; char *buf; int i; pthread_t tid; if (ac != 2) { fprintf(stderr, "usage: dammitdave filename\n"); exit(1); } buf = mmap(NULL, BUFSIZE, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0); if (buf == MAP_FAILED) { perror("mmap"); exit(1); } memset(buf, 'a', BUFSIZE); filename = av[1]; ret = pthread_create(&tid, NULL, dontneed, buf); if (ret) { fprintf(stderr, "error %d from pthread_create\n", ret); exit(1); } ret = pthread_detach(tid); if (ret) { fprintf(stderr, "pthread detach failed %d\n", ret); exit(1); } while (1) { fd = open(filename, O_RDWR | O_CREAT, 0600); if (fd < 0) { perror("open"); exit(1); } for (i = 0; i < ROUNDS; i++) { int this_write = BUFSIZE; offset = rand() % MAXSIZE; ret = pwrite(fd, buf, this_write, offset); if (ret < 0) { perror("pwrite"); exit(1); } else if (ret != this_write) { fprintf(stderr, "short write to %s offset %lu ret %d\n", filename, offset, ret); exit(1); } if (i == ROUNDS - 1) { ret = sync_file_range(fd, offset, 4096, SYNC_FILE_RANGE_WRITE); if (ret < 0) { perror("sync_file_range"); exit(1); } } } ret = ftruncate(fd, 0); if (ret < 0) { perror("ftruncate"); exit(1); } ret = close(fd); if (ret) { perror("close"); exit(1); } ret = unlink(filename); if (ret) { perror("unlink"); exit(1); } } return 0; } Signed-off-by: Chris Mason <clm@fb.com> Reported-by: Dave Jones <dsj@fb.com> Fixes: 2e78c927d79333f299a8ac81c2fd2952caeef335 cc: stable@vger.kernel.org # v4.6 Signed-off-by: Chris Mason <clm@fb.com> fs/btrfs/file.c | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) commit 9257b4ca9dff074918164e4fa10e9001c62bc27a Merge: c315ef8 4c6143d Author: Chris Mason <clm@fb.com> Date: Thu May 26 12:49:21 2016 -0700 Merge branch 'for-chris-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux into for-linus-4.7 commit b7e7ad611e24b95b0db2998428ce78370415c086 Merge: 6124872 3e7cfce Author: David S. Miller <davem@davemloft.net> Date: Thu May 26 12:27:33 2016 -0700 Merge branch 'qed-fixes' Yuval Mintz says: ==================== qed*: Bug fixes This series contain several small fixes, most of which deal with either 100g support, sriov or bandwidth configurations. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3e7cfce228c6c67dd31e09175eaca55fee0c7082 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:24 2016 +0300 qed: Don't config min BW on 100g on link flap Currently 100g devices don't support minimum/maximum BW configurations, yet link flaps might cause the driver to attempt to do such a configuration. Prevent this just as we do for the maximum BW. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 7 +++++++ 1 file changed, 7 insertions(+) commit bb13ace7dca5d2385847e43511acf5777da35c0e Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Thu May 26 11:01:23 2016 +0300 qed: Prevent 100g from working in MSI Adapter can support 100g in both MSIx and INTa, but not in MSI. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 5 +++++ drivers/net/ethernet/qlogic/qed/qed_main.c | 18 ++++++++++-------- 2 files changed, 15 insertions(+), 8 deletions(-) commit 1af9dcf7f90e6b75b7c42eaaf19cdd5da1354784 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:22 2016 +0300 qed: Add missing 100g init mode Some of the HW configurations are currently missing for 100g devices. This can cause various classification issues, as well as prevent device from fully reaching line-rate. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 7 +++++++ 1 file changed, 7 insertions(+) commit cc3d5eb09111a471f942c76e9610ee962e1d4c31 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:21 2016 +0300 qed: Save min/max accross dcbx-change When DCBx re-negotiation is occurring, the PF's configurations for maximum and minimum bandwidth guarantees are currently lost. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 795292916cf9d8c47c53b692bcb36b02953101cf Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Thu May 26 11:01:20 2016 +0300 qed: Fix allocation in interrupt context Commit 39651abd2814 ("qed: add support for dcbx") is re-configuring the QM hw-block as part of its sequence. This is done in attention handling context which is non-sleepable, yet memory is allocated in this flow using GFP_KERNEL. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) commit 6ecb0a0c0d9539fac1497d1d218e60a393a1070c Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:19 2016 +0300 qede: Don't expose self-test for VFs PFs and VFs differ in their registered ethtool operations, but they're using a common function for get_sset_count(). As a result, `ethtool -i' for a VF would indicate it supports selftest, although that's not the case. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit ce2b885cc5014d1cbcbe519c45f00f6a59e5ab70 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:18 2016 +0300 qede: Reload on GRO changes Since driver is using a FW-based GRO implementation, this has some effects on its ability to cope with GRO enablement/disablement. As a result, driver must perform an inner-reload as a result of a state change in the offload configuration of said feature. [Failure to do so means network stack would continue to receive aggregated packets even though user requested the feature to be disabled]. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_main.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit be7b6d64c0f2f31ea03746edaabb22f57234cb49 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Thu May 26 11:01:17 2016 +0300 qede: Fix VF minimum BW setting VF is currently ignoring the minimum provided by the API, mistakenly using the maximum for minimum as well. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d6760b14d4a1243f918d983bba1e35c5a5cd5a6d Author: Erico Nunes <erico.nunes@datacom.ind.br> Date: Tue May 3 15:45:43 2016 -0300 i2c: dev: switch from register_chrdev to cdev API i2c-dev had never moved away from the older register_chrdev interface to implement its char device registration. The register_chrdev API has the limitation of enabling only up to 256 i2c-dev busses to exist. Large platforms with lots of i2c devices (i.e. pluggable transceivers) with dedicated busses may have to exceed that limit. In particular, there are also platforms making use of the i2c bus multiplexing API, which instantiates a virtual bus for each possible multiplexed selection. This patch removes the register_chrdev usage and replaces it with the less old cdev API, which takes away the 256 i2c-dev bus limitation. It should not have any other impact for i2c bus drivers or user space. This patch has been tested on qemu x86 and qemu powerpc platforms with the aid of a module which adds and removes 5000 virtual i2c busses, as well as validated on an existing powerpc hardware platform which makes use of the i2c bus multiplexing API. i2c-dev busses with device minor numbers larger than 256 have also been validated to work with the existing i2c-tools. Signed-off-by: Erico Nunes <erico.nunes@datacom.ind.br> [wsa: kept includes sorted] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-dev.c | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) commit e3879e4f3179121b1b59fd0033379d0ee700dead Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Wed May 11 17:20:05 2016 +0200 i2c: xlr: rename ARCH_TANGOX to ARCH_TANGO The ARCH name was changed during the review process of the mach, and this driver was forgotten to be converted. Fix it now. http://article.gmane.org/gmane.linux.ports.arm.kernel/456331 Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> [wsa: updated commit message slightly] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b00c52dae6d9ee8d0f2407118ef6544ae5524781 Author: Wenwei Tao <ww.tao0320@gmail.com> Date: Fri May 13 22:59:20 2016 +0800 cgroup: remove redundant cleanup in css_create When create css failed, before call css_free_rcu_fn, we remove the css id and exit the percpu_ref, but we will do these again in css_free_work_fn, so they are redundant. Especially the css id, that would cause problem if we remove it twice, since it may be assigned to another css after the first remove. tj: This was broken by two commits updating the free path without synchronizing the creation failure path. This can be easily triggered by trying to create more than 64k memory cgroups. Signed-off-by: Wenwei Tao <ww.tao0320@gmail.com> Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Vladimir Davydov <vdavydov@parallels.com> Fixes: 9a1049da9bd2 ("percpu-refcount: require percpu_ref to be exited explicitly") Fixes: 01e586598b22 ("cgroup: release css->id after css_free") Cc: stable@vger.kernel.org # v3.17+ kernel/cgroup.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 67fed0da5ac23ab6187c362b7ade08339872f718 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Fri May 20 14:06:31 2016 +0200 i2c: at91: change log when dma configuration fails When the DMA configuration fails, there is a log reporting that we can't use DMA and indicating the error number. When booting the kernel, it is annoying to see this error number. Moreover, people can think something is going wrong. It is not the case, it means that DMA can't be used but it doesn't prevent to use i2c. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-at91.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 868b2072f09c8a698df8066ca72d30411dcc57d6 Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Mon May 23 11:44:39 2016 -0700 misc: at24: Fix typo in at24 header file This commit fixes a simple typo s/mvmem/nvmem in the example. Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> include/linux/platform_data/at24.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 79439d8308bb12b4bdb2ca42fba2b71f1600b88b Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 09:38:35 2016 +0200 i2c: rcar: should depend on HAS_DMA If NO_DMA=y: drivers/built-in.o: In function `rcar_i2c_dma_unmap': i2c-rcar.c:(.text+0x6f06c6): undefined reference to `bad_dma_ops' drivers/built-in.o: In function `rcar_i2c_dma': i2c-rcar.c:(.text+0x6f07e2): undefined reference to `bad_dma_ops' i2c-rcar.c:(.text+0x6f0838): undefined reference to `bad_dma_ops' Add a dependency on HAS_DMA to fix this. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 6aabf9d01facdcb6835272995b003956a9dabea0 Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Thu May 19 10:29:17 2016 +0200 i2c: rcar: use dma_request_chan() New drivers should not use dma_request_slave_channel_reason() but dma_request_chan(). The former is a macro to the later so this change do not effect the driver in any way. Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-rcar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ea8ea737c46cffa5d0ee74309f81e55a7e5e9c2a Merge: 0b9210c c7d73af Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 10:33:33 2016 -0700 Merge tag 'nfs-for-4.7-1' of git://git.linux-nfs.org/projects/anna/linux-nfs Pull NFS client updates from Anna Schumaker: "Highlights include: Features: - Add support for the NFS v4.2 COPY operation - Add support for NFS/RDMA over IPv6 Bugfixes and cleanups: - Avoid race that crashes nfs_init_commit() - Fix oops in callback path - Fix LOCK/OPEN race when unlinking an open file - Choose correct stateids when using delegations in setattr, read and write - Don't send empty SETATTR after OPEN_CREATE - xprtrdma: Prevent server from writing a reply into memory client has released - xprtrdma: Support using Read list and Reply chunk in one RPC call" * tag 'nfs-for-4.7-1' of git://git.linux-nfs.org/projects/anna/linux-nfs: (61 commits) pnfs: pnfs_update_layout needs to consider if strict iomode checking is on nfs/flexfiles: Use the layout segment for reading unless it a IOMODE_RW and reading is disabled nfs/flexfiles: Helper function to detect FF_FLAGS_NO_READ_IO nfs: avoid race that crashes nfs_init_commit NFS: checking for NULL instead of IS_ERR() in nfs_commit_file() pnfs: make pnfs_layout_process more robust pnfs: rework LAYOUTGET retry handling pnfs: lift retry logic from send_layoutget to pnfs_update_layout pnfs: fix bad error handling in send_layoutget flexfiles: add kerneldoc header to nfs4_ff_layout_prepare_ds flexfiles: remove pointless setting of NFS_LAYOUT_RETURN_REQUESTED pnfs: only tear down lsegs that precede seqid in LAYOUTRETURN args pnfs: keep track of the return sequence number in pnfs_layout_hdr pnfs: record sequence in pnfs_layout_segment when it's created pnfs: don't merge new ff lsegs with ones that have LAYOUTRETURN bit set pNFS/flexfiles: When initing reads or writes, we might have to retry connecting to DSes pNFS/flexfiles: When checking for available DSes, conditionally check for MDS io pNFS/flexfile: Fix erroneous fall back to read/write through the MDS NFS: Reclaim writes via writepage are opportunistic NFSv4: Use the right stateid for delegations in setattr, read and write ... commit 0b9210c9c86e46a7a62bbc7b69b84001315072ff Merge: c543673 555b67e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 10:13:40 2016 -0700 Merge tag 'xfs-for-linus-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/dgc/linux-xfs Pull xfs updates from Dave Chinner: "A pretty average collection of fixes, cleanups and improvements in this request. Summary: - fixes for mount line parsing, sparse warnings, read-only compat feature remount behaviour - allow fast path symlink lookups for inline symlinks. - attribute listing cleanups - writeback goes direct to bios rather than indirecting through bufferheads - transaction allocation cleanup - optimised kmem_realloc - added configurable error handling for metadata write errors, changed default error handling behaviour from "retry forever" to "retry until unmount then fail" - fixed several inode cluster writeback lookup vs reclaim race conditions - fixed inode cluster writeback checking wrong inode after lookup - fixed bugs where struct xfs_inode freeing wasn't actually RCU safe - cleaned up inode reclaim tagging" * tag 'xfs-for-linus-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/dgc/linux-xfs: (39 commits) xfs: fix warning in xfs_finish_page_writeback for non-debug builds xfs: move reclaim tagging functions xfs: simplify inode reclaim tagging interfaces xfs: rename variables in xfs_iflush_cluster for clarity xfs: xfs_iflush_cluster has range issues xfs: mark reclaimed inodes invalid earlier xfs: xfs_inode_free() isn't RCU safe xfs: optimise xfs_iext_destroy xfs: skip stale inodes in xfs_iflush_cluster xfs: fix inode validity check in xfs_iflush_cluster xfs: xfs_iflush_cluster fails to abort on error xfs: remove xfs_fs_evict_inode() xfs: add "fail at unmount" error handling configuration xfs: add configuration handlers for specific errors xfs: add configuration of error failure speed xfs: introduce table-based init for error behaviors xfs: add configurable error support to metadata buffers xfs: introduce metadata IO error class xfs: configurable error behavior via sysfs xfs: buffer ->bi_end_io function requires irq-safe lock ... commit 7a226f9c32b0481b0744e2726cd7f8349b866af5 Author: Doug Ledford <dledford@redhat.com> Date: Thu May 26 12:57:44 2016 -0400 staging/rdma: Remove the entire rdma subdirectory of staging This is no longer in use. Remove it. Signed-off-by: Doug Ledford <dledford@redhat.com> MAINTAINERS | 1 - drivers/staging/Kconfig | 2 -- drivers/staging/Makefile | 1 - drivers/staging/rdma/Kconfig | 25 ------------------------- drivers/staging/rdma/Makefile | 1 - 5 files changed, 30 deletions(-) commit b40f4757daa1b28e586fddad76638c98e2edfc34 Author: Christoph Lameter <cl@linux.com> Date: Mon May 16 12:49:33 2016 -0500 IB/core: Make device counter infrastructure dynamic In practice, each RDMA device has a unique set of counters that the hardware implements. Having a central set of counters that they must all adhere to is limiting and causes many useful counters to not be available. Therefore we create a dynamic counter registration infrastructure. The driver must implement a stats structure allocation routine, in which the driver must place the directory name it wants, a list of names for all of the counters, an array of u64 counters themselves, plus a few generic configuration options. We then implement a core routine to create a sysfs file for each of the named stats elements, and a core routine to retrieve the stats when any of the sysfs attribute files are read. To avoid excessive beating on the stats generation routine in the drivers, the core code also caches the stats for a short period of time so that someone attempting to read all of the stats in a given device's directory will not result in a stats generation call per file read. Future work will attempt to standardize just the shared stats elements, and possibly add a method to get the stats via netlink in addition to sysfs. Signed-off-by: Christoph Lameter <cl@linux.com> Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> [ Add caching, make structure names more informative, add i40iw support, other significant rewrites from the original patch ] Documentation/infiniband/sysfs.txt | 12 + drivers/infiniband/core/sysfs.c | 366 ++++++++++++++++++---------- drivers/infiniband/hw/cxgb3/iwch_provider.c | 147 +++++++---- drivers/infiniband/hw/cxgb4/provider.c | 58 ++++- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 145 ++++++++--- include/rdma/ib_verbs.h | 126 ++++++---- 6 files changed, 590 insertions(+), 264 deletions(-) commit 8779e7658df2496f27660586e3a20a86c75fb526 Merge: e6f6113 f158486 Author: Doug Ledford <dledford@redhat.com> Date: Thu May 26 12:50:05 2016 -0400 Merge branch 'hfi1-2' into k.o/for-4.7 commit c5436731de860b3a3cff70c62d99242418aab1d1 Merge: 0e77816 1dc2c9f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 09:48:23 2016 -0700 Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging Pull hwmon fixlets from Jean Delvare. * 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging: Documentation/hwmon: Update links in max34440 hwmon: (emc2103) Fix typo in MODULE_PARM_DESC commit 0e77816e096c4ae27e98977fef56b6b9169f9017 Merge: bfb7644 265984b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 09:36:10 2016 -0700 Merge tag 'mmc-v4.7-rc1' of git://git.linaro.org/people/ulf.hansson/mmc Pull MMC fixes from Ulf Hansson: "Here are some mmc fixes intended for v4.7 rc1. They are based on a commit earlier in the merge window and have been tested in linux-next for a while. MMC core: - Prevent re-tuning while serving requests for RPMB partitions - Extend timeout for long read time quirk to support more eMMCs MMC host: - sdhci-acpi: Ensure connected devices are powered when probing - sdhci-pci|acpi: Remove unreliable MMC_CAP_BUS_WIDTH_TEST for Intel HWs - dw_mmc: Correct the assigning of max_blk_size - dw_mmc-rockchip: Allow RPMB partitions to be created - dw_mmc-rockchip: Set the drive phase properly" * tag 'mmc-v4.7-rc1' of git://git.linaro.org/people/ulf.hansson/mmc: mmc: sdhci-acpi: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers mmc: sdhci-pci: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers mmc: longer timeout for long read time quirk mmc: dw_mmc: rockchip: Set the drive phase properly mmc: dw_mmc: fix the wrong max_blk_size mmc: dw_mmc-rockchip: add MMC_CAP_CMD23 capabilities mmc: sdhci-acpi: Ensure connected devices are powered when probing ACPI / PM: Export acpi_device_fix_up_power() mmc: block: Pause re-tuning while switched to the RPMB partition mmc: block: Always switch back to main area after RPMB access mmc: core: Add a facility to "pause" re-tuning commit bfb764440d5bee109003295473a0b387bc799222 Merge: 159d08f 88ac990 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 09:23:43 2016 -0700 Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux Pull thermal management updates from Zhang Rui: - Introduce generic ADC thermal driver, based on OF thermal (Laxman Dewangan) - Introduce new thermal driver for Tango chips (Marc Gonzalez) - Rockchip driver support for RK3399, RK3366, and some fixes (Caesar Wang, Elaine Zhang and Shawn Lin) - Add CPU power cooling model to Mediatek thermal driver (Dawei Chien) - Wider usage of dev_thermal_zone_of_sensor_register (Eduardo Valentin) - TI thermal driver gained a new maintainer (Keerthy). - Enabled powerclamp driver by checking CPU feature and package cstate counter instead of CPU whitelist (Jacob Pan) - Various fixes on thermal governor, OF thermal, Tegra, and RCAR * 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux: (50 commits) thermal: tango: initialize TEMPSI_CFG thermal: rockchip: use the usleep_range instead of udelay thermal: rockchip: add the notes for better reading thermal: rockchip: Support RK3366 SoCs in the thermal driver thermal: rockchip: handle the power sequence for tsadc controller thermal: rockchip: update the tsadc table for rk3399 thermal: rockchip: fixes the code_to_temp for tsadc driver thermal: rockchip: disable thermal->clk in err case thermal: tegra: add Tegra132 specific SOC_THERM driver thermal: fix ptr_ret.cocci warnings thermal: mediatek: Add cpu dynamic power cooling model. thermal: generic-adc: Add ADC based thermal sensor driver thermal: generic-adc: Add DT binding for ADC based thermal sensor thermal: tegra: fix static checker warning thermal: tegra: mark PM functions __maybe_unused thermal: add temperature sensor support for tango SoC thermal: hisilicon: fix IRQ imbalance enabling thermal: hisilicon: support to use any sensor thermal: rcar: Remove binding docs for r8a7794 thermal: tegra: add PM support ... commit f158486527ebfb4c1fe4dcb69b12479090d66b72 Author: Jubin John <jubin.john@intel.com> Date: Tue May 24 12:51:06 2016 -0700 IB/hfi1: Fix pio map initialization The pio map initialization function is off by 1 causing the last kernel send context that is allocated to not get mapped into the pio map which leads to the last kernel send context not being used by any of the qps. The send context reserved for VL15 is taken care of by setting the scontext variable that is used as the index into the kernel send context array to 1 and does not need to be accounted for in the kernel send context counting loop as it is currently done. Fix the kernel send context counting loop to account for all the allocated send contexts and map all of them to the different VLs. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/pio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit f6de3d39cfc30387ce7dadb8542e4a635c706670 Author: Dean Luick <dean.luick@intel.com> Date: Tue May 24 12:51:00 2016 -0700 IB/hfi1: Correct 8051 link parameter settings Two 8051 link settings, external device config and tuning method, were written in the wrong location and the previous settings were not cleared. For both, clear the old value and write the new value. Fixes: 8ebd4cf1852a ("staging/rdma/hfi1: Add active and optical cable support") Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/chip.h | 6 ++++++ drivers/infiniband/hw/hfi1/platform.c | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) commit ce8b2fd0950ccc14440b02f05d2c7023608cfa76 Author: Sebastian Sanchez <sebastian.sanchez@intel.com> Date: Tue May 24 12:50:47 2016 -0700 IB/hfi1: Update pkey table properly after link down or FM start When FM is disabled, and the HFI port on the switch is changed from MgmtAllowed=YES to MgmtAllowed=NO and the link is bounced, FULL_MGMT_P_KEY doesn't get cleared from the pkey table. This also occurs when the QSFP cable is moved from a switch port with MgmtAllowed=YES to a MgmtAllowed=NO port. Clear pkey entry properly. Also, when the driver is loaded and the switch port is set to MgmtAllowed=NO, FULL_MGMT_P_KEY shouldn't be added to pkey table after FM is started. Only set FULL_MGMT_P_KEY in the pkey table if switch port is configured to MgmtAllowed=YES. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Sebastian Sanchez <sebastian.sanchez@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/chip.c | 9 +++++++++ drivers/infiniband/hw/hfi1/mad.c | 6 ++++++ 2 files changed, 15 insertions(+) commit 8b103e9cdee5f381bc20a8a9f9bb5be11de8e68f Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue May 24 12:50:40 2016 -0700 IB/rdamvt: Fix rdmavt s_ack_queue sizing rdmavt allows the driver to specify the size of the ack queue, but only uses it for the modify QP limit testing for setting the atomic limit value. The driver dependent size is now used to size the s_ack_queue ring dynamicially. Since the driver knows its size, the driver will use its define for any ring size dependent code. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/sw/rdmavt/qp.c | 22 ++++++++++++++++++++-- include/rdma/rdma_vt.h | 9 +++++++++ include/rdma/rdmavt_qp.h | 5 +---- 3 files changed, 30 insertions(+), 6 deletions(-) commit 4c0b653335bbdfe62a5f4483c98cb5d581432917 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue May 24 12:50:34 2016 -0700 IB/rdmavt: Max atomic value should be a u8 This matches the ib_qp_attr size and avoids a extremely large value when the lower level driver registers. As part of the patch, the u8 ordinals are moved to the end of the struct to reduce pahole noted excesses. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/rdma/rdma_vt.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7049de65c9e520886f06d6f9deceaaed5d93fb7c Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue May 24 12:50:23 2016 -0700 IB/hfi1: Fix hard lockup due to not using save/restore spin lock Commit b9b06cb6feda ("IB/hfi1: Fix missing lock/unlock in verbs drain callback") added a spin lock. Unfortunately, the new lock code can be called from a base level interrupt state, and an interrupt that can get stacked will attempt to get the same lock. Fix by using the flag save/restore spin lock variation. Cc: stable@vger.kernel.org # 4.6+ Reviewed-by: Sebastian Sanchez <sebastian.sanchez@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/qp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit bdd8a98ce465df31b07ff6314db9ed31a7c6bb0d Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Tue May 24 12:50:17 2016 -0700 IB/hfi1: Add tracing support for send with invalidate opcode Enable trace generation for packets with the "Send Last with Invalidate" and "Send Only with Invalidate" opcodes. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/trace.c | 7 +++++++ drivers/infiniband/hw/hfi1/trace.h | 2 ++ drivers/infiniband/hw/hfi1/verbs.c | 2 ++ 3 files changed, 11 insertions(+) commit 23f7d0d29e842360cc20bf03460f52f14ced915d Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Tue May 24 12:50:10 2016 -0700 IB/hfi1, qib: Add ieth to the packet header definitions A new union member "ieth" (Invalidate Extended Transport Header) is added to the packet header definition in preparation of supporting the send with invalidate opcode. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/hfi1/verbs.h | 1 + drivers/infiniband/hw/qib/qib_verbs.h | 1 + 2 files changed, 2 insertions(+) commit 159d08f4b85ce454cd05fb9e2c539276e148d366 Merge: 2f7c3a1 dca6b41 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 26 09:15:19 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull Yama locking fix from James Morris: "Fix for the Yama LSM" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: Yama: fix double-spinlock and user access in atomic context commit e6f61130ed7a124138c4f7b1bd35e24e8113cb83 Merge: 0de4cbb 492a7e6 ae43f82 Author: Doug Ledford <dledford@redhat.com> Date: Thu May 26 11:55:19 2016 -0400 Merge branches 'misc-4.7-2', 'ipoib' and 'ib-router' into k.o/for-4.7 commit f48ad614c100783be1e7e777dc36328001b83999 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:51 2016 -0700 IB/hfi1: Move driver out of staging The TODO list for the hfi1 driver was completed during 4.6. In addition other objections raised (which are far beyond what was in the TODO list) have been addressed as well. It is now time to remove the driver from staging and into the drivers/infiniband sub-tree. Reviewed-by: Jubin John <jubin.john@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> MAINTAINERS | 13 +- drivers/infiniband/Kconfig | 2 + drivers/infiniband/hw/Makefile | 1 + drivers/infiniband/hw/hfi1/Kconfig | 29 + drivers/infiniband/hw/hfi1/Makefile | 21 + drivers/infiniband/hw/hfi1/affinity.c | 431 + drivers/infiniband/hw/hfi1/affinity.h | 108 + drivers/infiniband/hw/hfi1/aspm.h | 309 + drivers/infiniband/hw/hfi1/chip.c | 14703 ++++++++++++++++++++++++++ drivers/infiniband/hw/hfi1/chip.h | 1368 +++ drivers/infiniband/hw/hfi1/chip_registers.h | 1307 +++ drivers/infiniband/hw/hfi1/common.h | 411 + drivers/infiniband/hw/hfi1/debugfs.c | 1145 ++ drivers/infiniband/hw/hfi1/debugfs.h | 75 + drivers/infiniband/hw/hfi1/device.c | 183 + drivers/infiniband/hw/hfi1/device.h | 60 + drivers/infiniband/hw/hfi1/dma.c | 183 + drivers/infiniband/hw/hfi1/driver.c | 1404 +++ drivers/infiniband/hw/hfi1/efivar.c | 164 + drivers/infiniband/hw/hfi1/efivar.h | 57 + drivers/infiniband/hw/hfi1/eprom.c | 102 + drivers/infiniband/hw/hfi1/eprom.h | 52 + drivers/infiniband/hw/hfi1/file_ops.c | 1498 +++ drivers/infiniband/hw/hfi1/firmware.c | 2056 ++++ drivers/infiniband/hw/hfi1/hfi.h | 1950 ++++ drivers/infiniband/hw/hfi1/init.c | 1818 ++++ drivers/infiniband/hw/hfi1/intr.c | 200 + drivers/infiniband/hw/hfi1/iowait.h | 300 + drivers/infiniband/hw/hfi1/mad.c | 4443 ++++++++ drivers/infiniband/hw/hfi1/mad.h | 437 + drivers/infiniband/hw/hfi1/mmu_rb.c | 325 + drivers/infiniband/hw/hfi1/mmu_rb.h | 76 + drivers/infiniband/hw/hfi1/opa_compat.h | 111 + drivers/infiniband/hw/hfi1/pcie.c | 1338 +++ drivers/infiniband/hw/hfi1/pio.c | 2073 ++++ drivers/infiniband/hw/hfi1/pio.h | 328 + drivers/infiniband/hw/hfi1/pio_copy.c | 867 ++ drivers/infiniband/hw/hfi1/platform.c | 907 ++ drivers/infiniband/hw/hfi1/platform.h | 305 + drivers/infiniband/hw/hfi1/qp.c | 973 ++ drivers/infiniband/hw/hfi1/qp.h | 160 + drivers/infiniband/hw/hfi1/qsfp.c | 632 ++ drivers/infiniband/hw/hfi1/qsfp.h | 240 + drivers/infiniband/hw/hfi1/rc.c | 2580 +++++ drivers/infiniband/hw/hfi1/ruc.c | 979 ++ drivers/infiniband/hw/hfi1/sdma.c | 3054 ++++++ drivers/infiniband/hw/hfi1/sdma.h | 1082 ++ drivers/infiniband/hw/hfi1/sdma_txreq.h | 135 + drivers/infiniband/hw/hfi1/sysfs.c | 785 ++ drivers/infiniband/hw/hfi1/trace.c | 236 + drivers/infiniband/hw/hfi1/trace.h | 1370 +++ drivers/infiniband/hw/hfi1/twsi.c | 489 + drivers/infiniband/hw/hfi1/twsi.h | 65 + drivers/infiniband/hw/hfi1/uc.c | 604 ++ drivers/infiniband/hw/hfi1/ud.c | 911 ++ drivers/infiniband/hw/hfi1/user_exp_rcv.c | 1050 ++ drivers/infiniband/hw/hfi1/user_exp_rcv.h | 79 + drivers/infiniband/hw/hfi1/user_pages.c | 135 + drivers/infiniband/hw/hfi1/user_sdma.c | 1625 +++ drivers/infiniband/hw/hfi1/user_sdma.h | 84 + drivers/infiniband/hw/hfi1/verbs.c | 1762 +++ drivers/infiniband/hw/hfi1/verbs.h | 530 + drivers/infiniband/hw/hfi1/verbs_txreq.c | 149 + drivers/infiniband/hw/hfi1/verbs_txreq.h | 116 + drivers/staging/rdma/Kconfig | 2 - drivers/staging/rdma/Makefile | 1 - drivers/staging/rdma/hfi1/Kconfig | 29 - drivers/staging/rdma/hfi1/Makefile | 21 - drivers/staging/rdma/hfi1/TODO | 6 - drivers/staging/rdma/hfi1/affinity.c | 431 - drivers/staging/rdma/hfi1/affinity.h | 108 - drivers/staging/rdma/hfi1/aspm.h | 309 - drivers/staging/rdma/hfi1/chip.c | 14703 -------------------------- drivers/staging/rdma/hfi1/chip.h | 1368 --- drivers/staging/rdma/hfi1/chip_registers.h | 1307 --- drivers/staging/rdma/hfi1/common.h | 411 - drivers/staging/rdma/hfi1/debugfs.c | 1145 -- drivers/staging/rdma/hfi1/debugfs.h | 75 - drivers/staging/rdma/hfi1/device.c | 183 - drivers/staging/rdma/hfi1/device.h | 60 - drivers/staging/rdma/hfi1/dma.c | 183 - drivers/staging/rdma/hfi1/driver.c | 1404 --- drivers/staging/rdma/hfi1/efivar.c | 164 - drivers/staging/rdma/hfi1/efivar.h | 57 - drivers/staging/rdma/hfi1/eprom.c | 102 - drivers/staging/rdma/hfi1/eprom.h | 52 - drivers/staging/rdma/hfi1/file_ops.c | 1498 --- drivers/staging/rdma/hfi1/firmware.c | 2056 ---- drivers/staging/rdma/hfi1/hfi.h | 1950 ---- drivers/staging/rdma/hfi1/init.c | 1818 ---- drivers/staging/rdma/hfi1/intr.c | 200 - drivers/staging/rdma/hfi1/iowait.h | 300 - drivers/staging/rdma/hfi1/mad.c | 4443 -------- drivers/staging/rdma/hfi1/mad.h | 437 - drivers/staging/rdma/hfi1/mmu_rb.c | 325 - drivers/staging/rdma/hfi1/mmu_rb.h | 76 - drivers/staging/rdma/hfi1/opa_compat.h | 111 - drivers/staging/rdma/hfi1/pcie.c | 1338 --- drivers/staging/rdma/hfi1/pio.c | 2073 ---- drivers/staging/rdma/hfi1/pio.h | 328 - drivers/staging/rdma/hfi1/pio_copy.c | 867 -- drivers/staging/rdma/hfi1/platform.c | 907 -- drivers/staging/rdma/hfi1/platform.h | 305 - drivers/staging/rdma/hfi1/qp.c | 973 -- drivers/staging/rdma/hfi1/qp.h | 160 - drivers/staging/rdma/hfi1/qsfp.c | 632 -- drivers/staging/rdma/hfi1/qsfp.h | 240 - drivers/staging/rdma/hfi1/rc.c | 2580 ----- drivers/staging/rdma/hfi1/ruc.c | 979 -- drivers/staging/rdma/hfi1/sdma.c | 3054 ------ drivers/staging/rdma/hfi1/sdma.h | 1082 -- drivers/staging/rdma/hfi1/sdma_txreq.h | 135 - drivers/staging/rdma/hfi1/sysfs.c | 785 -- drivers/staging/rdma/hfi1/trace.c | 236 - drivers/staging/rdma/hfi1/trace.h | 1370 --- drivers/staging/rdma/hfi1/twsi.c | 489 - drivers/staging/rdma/hfi1/twsi.h | 65 - drivers/staging/rdma/hfi1/uc.c | 604 -- drivers/staging/rdma/hfi1/ud.c | 911 -- drivers/staging/rdma/hfi1/user_exp_rcv.c | 1050 -- drivers/staging/rdma/hfi1/user_exp_rcv.h | 79 - drivers/staging/rdma/hfi1/user_pages.c | 135 - drivers/staging/rdma/hfi1/user_sdma.c | 1625 --- drivers/staging/rdma/hfi1/user_sdma.h | 84 - drivers/staging/rdma/hfi1/verbs.c | 1762 --- drivers/staging/rdma/hfi1/verbs.h | 530 - drivers/staging/rdma/hfi1/verbs_txreq.c | 149 - drivers/staging/rdma/hfi1/verbs_txreq.h | 116 - 128 files changed, 60979 insertions(+), 60984 deletions(-) commit e11ffbd57520c3832e05f2f5f19e9ff6adbb7cdc Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:44 2016 -0700 IB/hfi1: Do not free hfi1 cdev parent structure early The deletion of a cdev is not a fence for holding off references to the structure. The driver attempts to delete the cdev and then proceeds to free the parent structure, the hfi1_devdata, or dd. This can potentially lead to a kernel panic in situations where a user has an FD for the cdev open, and the pci device gets removed. If the user then closes the FD there will be a NULL dereference when trying to do put on the cdev's kobject. Fix this by pointing the cdev's kobject.parent at a new kobject embedded in its parent structure. Also take a reference when the device is opened and put it back when it is closed. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/device.c | 4 +++- drivers/staging/rdma/hfi1/device.h | 3 ++- drivers/staging/rdma/hfi1/file_ops.c | 15 ++++++++++++--- drivers/staging/rdma/hfi1/hfi.h | 1 + drivers/staging/rdma/hfi1/init.c | 14 +++++++++++++- 5 files changed, 31 insertions(+), 6 deletions(-) commit 8a1882ebd4b593df0e36ba0b72e4e2f632573274 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:37 2016 -0700 IB/hfi1: Add trace message in user IOCTL handling Add a trace message to HFI1s user IOCTL handling. This allows debugging of which IOCTLs are being handled by the driver. Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/file_ops.c | 1 + drivers/staging/rdma/hfi1/trace.c | 1 + drivers/staging/rdma/hfi1/trace.h | 1 + 3 files changed, 3 insertions(+) commit 380fb942888e7afc3420ce195a5188ff73b5a782 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:31 2016 -0700 IB/hfi1: Remove write(), use ioctl() for user cmds Remove the write() handler for user space commands now that ioctl handling is available. User apps will need to change to use ioctl from this point forward. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/file_ops.c | 226 ----------------------------------- include/uapi/rdma/hfi/hfi1_user.h | 8 +- 2 files changed, 1 insertion(+), 233 deletions(-) commit 8d970cf991a6c38a5566572979487b906d643740 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:24 2016 -0700 IB/hfi1: Add ioctl() interface for user commands IOCTL is more suited to what user space commands need to do than the write() interface. Add IOCTL definitions for all existing write commands and the handling for those. The write() interface will be removed in a follow on patch. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/common.h | 5 +- drivers/staging/rdma/hfi1/file_ops.c | 204 +++++++++++++++++++++++++++++++++++ include/uapi/rdma/hfi/hfi1_user.h | 45 ++++++++ 3 files changed, 253 insertions(+), 1 deletion(-) commit ac56f162d4586885238da05131c4e6bbdb536d4e Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:17 2016 -0700 IB/hfi1: Remove unused user command The HFI1_CMD_SDMA_STATUS_UPD command was never implemented it has no reason to live in the driver. Remove it. Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/file_ops.c | 3 --- include/uapi/rdma/hfi/hfi1_user.h | 1 - 2 files changed, 4 deletions(-) commit 0f7b1f917ca84493d40e4fce32db29e3f7afd5ad Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:10 2016 -0700 IB/hfi1: Remove snoop/diag interface The snoop/diag interface is better served by an implementation which is more general and usable by other drivers perhaps. Go ahead and remove the code now and get rid of the char dev. We can put the feature back when we have a more agreeable solution. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/Makefile | 2 +- drivers/staging/rdma/hfi1/diag.c | 1925 ---------------------------------- drivers/staging/rdma/hfi1/file_ops.c | 9 +- 3 files changed, 2 insertions(+), 1934 deletions(-) commit d079031742023a00e1deda0fa847d403b4b91c76 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:26:04 2016 -0700 IB/hfi1: Remove EPROM functionality from data device Remove EPROM handling from the cdev which is used for user application data traffic. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/eprom.c | 369 ----------------------------------- drivers/staging/rdma/hfi1/file_ops.c | 23 --- include/uapi/rdma/hfi/hfi1_user.h | 7 - 3 files changed, 399 deletions(-) commit 7312f29d8ee5518c71572d7bfcbfcd5800b12d16 Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:25:57 2016 -0700 IB/hfi1: Remove UI char device Remove UI char device which exposes direct access to registers for user space. This was put in to aid in debugging the hardware. We are looking into alternatives means of providing the same functionality. This removes another char device from HFI1's footprint. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/file_ops.c | 168 +---------------------------------- 1 file changed, 1 insertion(+), 167 deletions(-) commit 0eb626590dcf1280c6d01a784e9d53a3de6d5e8e Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:25:50 2016 -0700 IB/hfi1: Remove multiple device cdev hfi1 current exports a cdev that can be used to target all of the hfi's in the system. However there is a problem with this approach in that the devices could be on different subnets. This is a problem that user space can figure out and explicitly tell the driver on which device to create a context. Remove the multi-purpose cdev leaving a dedicated cdev for each port. Also remove the striping capability that is dependent upon the user choosing the multi-purpose cdev. It is now up to user space to determine how to stripe contexts. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/file_ops.c | 102 +++++++---------------------------- include/uapi/rdma/hfi/hfi1_user.h | 19 +------ 2 files changed, 21 insertions(+), 100 deletions(-) commit f3225c3f1107104f5e143797550476182b844cfb Author: Dennis Dalessandro <dennis.dalessandro@intel.com> Date: Thu May 19 05:22:03 2016 -0700 IB/hfi1: Remove anti-pattern in cdev init Remove the usage of an anti-pattern goto in hfi1_cdev_init to improve code readability. Suggested-by: Jason Gunthorpe <jgunthorpe@obsidianresearch.com> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/device.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit b583faf4dc6eaa64895c37b81983e75a8c3c1e4e Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Thu May 19 05:21:57 2016 -0700 IB/hfi1: Fix bug that blocks process on exit after port bounce During the processing of a user SDMA request, if there was an error before the request counter was increased, the state of the packet queue could be updated incorrectly, causing the counter to underflow. As the result, the process could get stuck later since the counter could never get back to 0. This patch adds a condition to guard the packet queue update so that the counter is only decreased if it has been increased before the error happens. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/user_sdma.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit f70f5f6af36bce29fe2c4bc733a223b5746eb65f Author: Jubin John <jubin.john@intel.com> Date: Thu May 19 05:21:50 2016 -0700 IB/qib: Remove unused qib_7322_intr_msgs[] Building the qib driver with gcc version 6.1.0 raises the following build warning: drivers/infiniband/hw/qib/qib_iba7322.c:1311:39: warning: 'qib_7322_intr_msgs' defined but not used [-Wunused-const-variable=] static const struct qib_hwerror_msgs qib_7322_intr_msgs[] = { ^~~~~~~~~~~~~~~~~~ Remove the unused qib_7322_intr_msgs[] Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/qib/qib_iba7322.c | 15 --------------- 1 file changed, 15 deletions(-) commit 46aa5baf96107bb35cc549ad1d19cf312dd5fb58 Author: Ira Weiny <ira.weiny@intel.com> Date: Thu May 19 05:21:44 2016 -0700 IB/hfi1: Remove unnecessary comment This comment was old, the MTU enums have been defined. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/qp.c | 3 --- 1 file changed, 3 deletions(-) commit eac7193632e64383e35fa387e683dd317b9df047 Author: Jubin John <jubin.john@intel.com> Date: Thu May 19 05:21:37 2016 -0700 IB/hfi1: Fix sdma_event_names[] build warning sdma_event_names[] is only used within CONFIG_SDMA_VERBOSITY ifdefs, so when CONFIG_SDMA_VERBOSITY is disabled, it results in the following 0-day build warning: >> drivers/infiniband/hw/hfi1/sdma.c:137:27: warning: 'sdma_event_names' >> defined but not used [-Wunused-const-variable=] static const char * const sdma_event_names[] = { ^~~~~~~~~~~~~~~~ This occurs on the following compiler: compiler: gcc-6 (Debian 6.1.1-1) 6.1.1 20160430 For more information check: https://lists.01.org/pipermail/kbuild-all/2016-May/020060.html Fix this warning by defining sdma_event_name[] only within the CONFIG_SDMA_VERBOSITY ifdefs. Reported-by: kbuild test robot <fengguang.wu@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/sdma.c | 2 ++ 1 file changed, 2 insertions(+) commit 49961f8fe8264fa231fbdcc4ca52c6706fdb2577 Author: Jubin John <jubin.john@intel.com> Date: Thu May 19 05:21:31 2016 -0700 IB/rdmavt: Use kzalloc_node Use kzalloc_node instead of kzalloc for rdmavt memory region segment allocation to optimize for performance on NUMA platforms. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/sw/rdmavt/mr.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 654b643670d82f14a62c888710e25248e03b0716 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Thu May 19 05:21:25 2016 -0700 IB/rdmavt: Insure QP vmalloc variants zero memory The usage of the various vmalloc APIs do not consistently zero memory when allocating the swqe. Insure zeroing variants are used. Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/sw/rdmavt/qp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 9565c6a37a9d69f00e2a7dabbee2b4f6d20dc1ae Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Thu May 19 05:21:18 2016 -0700 IB/hfi1: Fix an interval RB node reference count leak Commit e88c9271d9f8 ("IB/hfi1: Fix buffer cache corner case which may cause corruption") introduced a bug which may cause a reference count of a interval RB node to be leaked in the case where an SDMA transfer from that node completes at the same time as the node is being extended. If a node is being extended, it is first removed from the RB tree in order to be processed without the risk of an invalidation event removing the node at the same time. If a SDMA completion happens during that time, the completion handler will fail to find the node in the RB tree and, therefore, fail to correctly decrement its refcount. This leaves the node in the tree and its pages pinned for the duration of the user process. To prevent this from happening the io vector adds a reference to the RB node, which is used during the SDMA completion instead of looking up the node in the RB tree. This change adds a performance improvement as a side effect by avoiding the RB tree lookup. Fixes: e88c9271d9f8 ("IB/hfi1: Fix buffer cache corner case which may cause corruption") Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Harish Chegondi <harish.chegondi@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/user_sdma.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit c7de5726307620711a4753b2a13d9e5daecc1081 Author: Ming Lin <ming.l@samsung.com> Date: Wed May 25 23:23:27 2016 -0700 blk-mq: clear q->mq_ops if init fail blk_mq_init_queue() calls blk_mq_init_allocated_queue(), but q->mq_ops was not cleared when blk_mq_init_allocated_queue() fails. Then blk_cleanup_queue() calls blk_mq_free_queue() which will crash because: - q->all_q_node is not added to all_q_list yet - q->tag_set is NULL - hctx was not setup yet or already freed Fixed it by clearing q->mq_ops on error path. Signed-off-by: Ming Lin <ming.l@samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit c7d73af2d249f0323f5cdb171a59497ce80011fb Author: Tom Haynes <thomas.haynes@primarydata.com> Date: Wed May 25 07:31:14 2016 -0700 pnfs: pnfs_update_layout needs to consider if strict iomode checking is on As flexfiles has FF_FLAGS_NO_READ_IO, there is a need to generically support enforcing that a IOMODE_RW segment will not allow READ I/O. Signed-off-by: Tom Haynes <loghyr@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/filelayout/filelayout.c | 2 ++ fs/nfs/flexfilelayout/flexfilelayout.c | 49 +++++++++++++++++++++++++--------- fs/nfs/pnfs.c | 34 ++++++++++++++--------- fs/nfs/pnfs.h | 1 + 4 files changed, 61 insertions(+), 25 deletions(-) commit 602c4cd452d93355166daf8a662c84a5f85d2856 Author: Tom Haynes <thomas.haynes@primarydata.com> Date: Wed May 25 07:31:13 2016 -0700 nfs/flexfiles: Use the layout segment for reading unless it a IOMODE_RW and reading is disabled Signed-off-by: Tom Haynes <loghyr@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit bea8205feeb1d28841541814ae375defb5b1986b Merge: c4e85b7 f7aa23c Author: Mark Brown <broonie@kernel.org> Date: Thu May 26 11:13:12 2016 +0100 Merge branch 'asoc-fix-ep93xx' into spi-fix-ep93xx commit 1dc2c9f54b4b781f5630a042c14a7098beae0f3c Author: Glenn Dayton <glenn.dayton24@gmail.com> Date: Thu May 26 11:06:53 2016 +0200 Documentation/hwmon: Update links in max34440 It appears the website for maxim-ic.com changed to maximintegrated.com. Signed-off-by: Glenn Dayton <glenn.dayton24@gmail.com> Signed-off-by: Jean Delvare <jdelvare@suse.de> Documentation/hwmon/max34440 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 54f0ffc4e249b7f7e7fffb10c83e8de99aca839c Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 26 11:06:53 2016 +0200 hwmon: (emc2103) Fix typo in MODULE_PARM_DESC "apd" was intended here instead of "init". Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jean Delvare <jdelvare@suse.de> drivers/hwmon/emc2103.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 61248720c4efb54e32d90cbb2a2106dcc2128b00 Merge: bed187b f73a6f4 Author: David S. Miller <davem@davemloft.net> Date: Wed May 25 22:15:50 2016 -0700 Merge branch 'mlx4-stats-fixes' Eric Dumazet says: ==================== net/mlx4_en: fix stats mlx4 has various bugs in its ndo_get_stats() and related functions. This patch series address the obvious issues. Remaining ones will be discussed later. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f73a6f439fca0e14f228726e5647d5afe141bc32 Author: Eric Dumazet <edumazet@google.com> Date: Wed May 25 09:50:39 2016 -0700 net/mlx4_en: get rid of private net_device_stats We simply can use the standard net_device stats. We do not need to clear fields that are already 0. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Eugenia Emantayev <eugenia@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_ethtool.c | 2 +- drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 3 +-- drivers/net/ethernet/mellanox/mlx4/en_port.c | 14 +++----------- drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 1 - 4 files changed, 5 insertions(+), 15 deletions(-) commit 9ed17db17fb01a7be5b84558b768c091bdf8bb41 Author: Eric Dumazet <edumazet@google.com> Date: Wed May 25 09:50:38 2016 -0700 net/mlx4_en: get rid of ret_stats mlx4 uses a private struct net_device_stats in a vain attempt to avoid races. This is buggy because multiple cpus could call mlx4_en_get_stats() at the same time, so ret_stats can not guarantee stable results. To fix this, we need to switch to ndo_get_stats64() as this method provides per-thread storage. This allows to reduce mlx4_en_priv bloat. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Eugenia Emantayev <eugenia@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 11 ++++++----- drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 1 - 2 files changed, 6 insertions(+), 6 deletions(-) commit 45acbac609e73991dd9c3c9b7ffd03ddb8c939ef Author: Eric Dumazet <edumazet@google.com> Date: Wed May 25 09:50:37 2016 -0700 net/mlx4_en: clear some TX ring stats in mlx4_en_clear_stats() mlx4_en_clear_stats() clears about everything but few TX ring fields are missing : - queue_stopped, wake_queue, tso_packets, xmit_more Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Eugenia Emantayev <eugenia@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 4 ++++ 1 file changed, 4 insertions(+) commit 63a664b7e92b14aaa1e1c3e9ae362aa70cf4cefb Author: Eric Dumazet <edumazet@google.com> Date: Wed May 25 09:50:36 2016 -0700 net/mlx4_en: fix tx_dropped bug 1) mlx4_en_xmit() can increment priv->stats.tx_dropped, but this variable is overwritten in mlx4_en_DUMP_ETH_STATS(). 2) This increment was not SMP safe, as a port might have many TX queues. Add a per TX ring tx_dropped to fix these issues. This is u32 as mlx4_en_DUMP_ETH_STATS() will add a 32bit field. So lets avoid bugs with SNMP agents having to cope with partial overwraps. (One of these agents being bond_fold_stats()) Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Willem de Bruijn <willemb@google.com> Cc: Eugenia Emantayev <eugenia@mellanox.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 1 + drivers/net/ethernet/mellanox/mlx4/en_port.c | 4 +++- drivers/net/ethernet/mellanox/mlx4/en_tx.c | 8 ++++---- drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 1 + 4 files changed, 9 insertions(+), 5 deletions(-) commit bed187b540167eb10320f6a2177604421650772e Author: Xin Long <lucien.xin@gmail.com> Date: Thu May 26 03:09:23 2016 +0800 sctp: fix double EPs display in sctp_diag We have this situation: that EP hash table, contains only the EPs that are listening, while the transports one, has the opposite. We have to traverse both to dump all. But when we traverse the transports one we will also get EPs that are in the EP hash if they are listening. In this case, the EP is dumped twice. We will fix it by checking if the endpoint that is in the endpoint hash table contains any ep->asoc in there, as it means we will also find it via transport hash, and thus we can/should skip it, depending on the filters used, like 'ss -l'. Still, we should NOT skip it if the user is listing only listening endpoints, because then we are not traversing the transport hash. so we have to check idiag_states there also. Signed-off-by: Xin Long <lucien.xin@gmail.com> Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/sctp_diag.c | 3 +++ 1 file changed, 3 insertions(+) commit 3424d9be8f09649e6290d066c5c3cccff1c0ce77 Author: Marek Vasut <marex@denx.de> Date: Thu May 26 00:40:05 2016 +0200 net: arc: trivial: Replace comma with a semicolon Fix a typo in the driver, replace comma with a semicolon at the end of statement. While using comma is a legal C here and probably does not even generate compiler warning, it was unlikely the intention. Signed-off-by: Marek Vasut <marex@denx.de> Cc: David S. Miller <davem@davemloft.net> Cc: Caesar Wang <wxt@rock-chips.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/arc/emac_mdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 643d60bf575daaba93c1ac0d0e1c4b1d4ded1f75 Author: Marek Vasut <marex@denx.de> Date: Thu May 26 00:40:23 2016 +0200 net: stmmac: Fix incorrect memcpy source memory The memcpy() currently copies mdio_bus_data into new_bus->irq, which makes no sense, since the mdio_bus_data structure contains more than just irqs. The code was likely supposed to copy mdio_bus_data->irqs into the new_bus->irq instead, so fix this. Fixes: e7f4dc3536a4 ("mdio: Move allocation of interrupts into core") Signed-off-by: Marek Vasut <marex@denx.de> Cc: David S. Miller <davem@davemloft.net> Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com> Cc: Alexandre Torgue <alexandre.torgue@st.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 002354112f1e3cc7400ef48b853aefb90e801588 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 26 00:05:12 2016 -0400 restore killability of old mutex_lock_killable(&inode->i_mutex) users The ones that are taking it exclusive, that is... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/btrfs/ioctl.c | 18 +++++++----------- fs/overlayfs/readdir.c | 4 +--- fs/readdir.c | 12 ++++++------ 3 files changed, 14 insertions(+), 20 deletions(-) commit 887bddfa90c79957d61067cd54a10087be0c8b23 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 26 00:04:58 2016 -0400 add down_write_killable_nested() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/rwsem.h | 2 ++ kernel/locking/rwsem.c | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) commit d42b386834ee1c22f6fac2f856bba8a6e4de38bb Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 26 00:04:18 2016 -0400 update D/f/directory-locking Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/directory-locking | 32 ++++++++++++++++++----------- 1 file changed, 20 insertions(+), 12 deletions(-) commit 53b74ed2d0b4170764bf6d4cba6b786be1cab846 Author: Wenyou Yang <wenyou.yang@atmel.com> Date: Mon May 9 14:51:18 2016 +0800 Revert "mtd: atmel_nand: Support variable RB_EDGE interrupts" This reverts commit 5ddc7bd43ccc ("mtd: atmel_nand: Support variable RB_EDGE interrupts") Because for current SoCs, the RB_EDGE3(i.e. bit 27) of HSMC_SR register does not exist, the RB_EDGE0 (i.e. bit 24) is the ready/busy line edge status bit. It is a datasheet bug. Cc: <stable@vger.kernel.org> Fixes: commit 5ddc7bd43ccc ("mtd: atmel_nand: Support variable RB_EDGE interrupts") Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com> .../devicetree/bindings/mtd/atmel-nand.txt | 2 +- drivers/mtd/nand/atmel_nand.c | 35 +++++----------------- drivers/mtd/nand/atmel_nand_nfc.h | 3 +- 3 files changed, 10 insertions(+), 30 deletions(-) commit 2f7c3a18a2dc79ddf7b83ae199b099a675e1adb2 Merge: f89eae4 dc4fac8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 17:37:33 2016 -0700 Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Ingo Molnar: "Misc fixes: EFI, entry code, pkeys and MPX fixes, TASK_SIZE cleanups and a tsc frequency table fix" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/mm: Switch from TASK_SIZE to TASK_SIZE_MAX in the page fault code x86/fsgsbase/64: Use TASK_SIZE_MAX for FSBASE/GSBASE upper limits x86/mm/mpx: Work around MPX erratum SKD046 x86/entry/64: Fix stack return address retrieval in thunk x86/efi: Fix 7-parameter efi_call()s x86/cpufeature, x86/mm/pkeys: Fix broken compile-time disabling of pkeys x86/tsc: Add missing Cherrytrail frequency to the table commit f89eae4ee7e075e576bd4b4d2db901023421a3be Merge: bdc6b75 b7e7ade Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 17:11:43 2016 -0700 Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Ingo Molnar: "Two fixes: one for a lost wakeup, the other to fix the compiler optimizing out preempt operations on ARM64 (and possibly other non-x86 architectures)" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/core: Fix remote wakeups sched/preempt: Fix preempt_count manipulations commit bdc6b758e443c21c39a14c075e5b7e01f095b37b Merge: c4a3460 0c9f790 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 17:05:40 2016 -0700 Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf updates from Ingo Molnar: "Mostly tooling and PMU driver fixes, but also a number of late updates such as the reworking of the call-chain size limiting logic to make call-graph recording more robust, plus tooling side changes for the new 'backwards ring-buffer' extension to the perf ring-buffer" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (34 commits) perf record: Read from backward ring buffer perf record: Rename variable to make code clear perf record: Prevent reading invalid data in record__mmap_read perf evlist: Add API to pause/resume perf trace: Use the ptr->name beautifier as default for "filename" args perf trace: Use the fd->name beautifier as default for "fd" args perf report: Add srcline_from/to branch sort keys perf evsel: Record fd into perf_mmap perf evsel: Add overwrite attribute and check write_backward perf tools: Set buildid dir under symfs when --symfs is provided perf trace: Only auto set call-graph to "dwarf" when syscalls are being traced perf annotate: Sort list of recognised instructions perf annotate: Fix identification of ARM blt and bls instructions perf tools: Fix usage of max_stack sysctl perf callchain: Stop validating callchains by the max_stack sysctl perf trace: Fix exit_group() formatting perf top: Use machine->kptr_restrict_warned perf trace: Warn when trying to resolve kernel addresses with kptr_restrict=1 perf machine: Do not bail out if not managing to read ref reloc symbol perf/x86/intel/p4: Trival indentation fix, remove space ... commit dca6b4149181baaa363b9a7ce7c550840bb3bc83 Author: Jann Horn <jann@thejh.net> Date: Sun May 22 06:01:34 2016 +0200 Yama: fix double-spinlock and user access in atomic context Commit 8a56038c2aef ("Yama: consolidate error reporting") causes lockups when someone hits a Yama denial. Call chain: process_vm_readv -> process_vm_rw -> process_vm_rw_core -> mm_access -> ptrace_may_access task_lock(...) is taken __ptrace_may_access -> security_ptrace_access_check -> yama_ptrace_access_check -> report_access -> kstrdup_quotable_cmdline -> get_cmdline -> access_process_vm -> get_task_mm task_lock(...) is taken again task_lock(p) just calls spin_lock(&p->alloc_lock), so at this point, spin_lock() is called on a lock that is already held by the current process. Also: Since the alloc_lock is a spinlock, sleeping inside security_ptrace_access_check hooks is probably not allowed at all? So it's not even possible to print the cmdline from in there because that might involve paging in userspace memory. It would be tempting to rewrite ptrace_may_access() to drop the alloc_lock before calling the LSM, but even then, ptrace_may_access() itself might be called from various contexts in which you're not allowed to sleep; for example, as far as I understand, to be able to hold a reference to another task, usually an RCU read lock will be taken (see e.g. kcmp() and get_robust_list()), so that also prohibits sleeping. (And using e.g. FUSE, a user can cause pagefault handling to take arbitrary amounts of time - see https://bugs.chromium.org/p/project-zero/issues/detail?id=808.) Therefore, AFAIK, in order to print the name of a process below security_ptrace_access_check(), you'd have to either grab a reference to the mm_struct and defer the access violation reporting or just use the "comm" value that's stored in kernelspace and accessible without big complications. (Or you could try to use some kind of atomic remote VM access that fails if the memory isn't paged in, similar to copy_from_user_inatomic(), and if necessary fall back to comm, but that'd be kind of ugly because the comm/cmdline choice would look pretty random to the user.) Fix it by deferring reporting of the access violation until current exits kernelspace the next time. v2: Don't oops on PTRACE_TRACEME, call report_access under task_lock(current). Also fix nonsensical comment. And don't use GPF_ATOMIC for memory allocation with no locks held. This patch is tested both for ptrace attach and ptrace traceme. Fixes: 8a56038c2aef ("Yama: consolidate error reporting") Signed-off-by: Jann Horn <jann@thejh.net> Acked-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> security/yama/yama_lsm.c | 69 +++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 63 insertions(+), 6 deletions(-) commit 26c5f03b2ae8018418ceb25b2e6a48560e8c2f5b Author: Feng Tang <feng.tang@intel.com> Date: Wed May 25 14:49:54 2016 +0800 net: alx: use custom skb allocator This patch follows Eric Dumazet's commit 7b70176421 for Atheros atl1c driver to fix one exactly same bug in alx driver, that the network link will be lost in 1-5 minutes after the device is up. My laptop Lenovo Y580 with Atheros AR8161 ethernet device hit the same problem with kernel 4.4, and it will be cured by Jarod Wilson's commit c406700c for alx driver which get merged in 4.5. But there are still some alx devices can't function well even with Jarod's patch, while this patch could make them work fine. More details on https://bugzilla.kernel.org/show_bug.cgi?id=70761 The debug shows the issue is very likely to be related with the RX DMA address, specifically 0x...f80, if RX buffer get 0x...f80 several times, their will be RX overflow error and device will stop working. For kernel 4.5.0 with Jarod's patch which works fine with my AR8161/Lennov Y580, if I made some change to the __netdev_alloc_skb --> __alloc_page_frag() to make the allocated buffer can get an address with 0x...f80, then the same error happens. If I make it to 0x...f40 or 0x....fc0, everything will be still fine. So I tend to believe that the 0x..f80 address cause the silicon to behave abnormally. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=70761 Cc: Eric Dumazet <edumazet@google.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: Jarod Wilson <jarod@redhat.com> Signed-off-by: Feng Tang <feng.tang@intel.com> Tested-by: Ole Lukoie <olelukoie@mail.ru> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/atheros/alx/alx.h | 4 +++ drivers/net/ethernet/atheros/alx/main.c | 48 ++++++++++++++++++++++++++++++++- 2 files changed, 51 insertions(+), 1 deletion(-) commit c4a346002bc06046bc51910a7ade3a0c650c3d34 Merge: 0985b65 2e51f26 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 16:52:19 2016 -0700 Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull objtool build fix from Ingo Molnar: "An libtool fix for older libelf versions" * 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: objtool: Allow building with older libelf commit e536030934aebf049fe6aaebc58dd37aeee21840 Author: Yan, Zheng <zyan@redhat.com> Date: Thu May 19 19:15:19 2016 +0800 ceph: fix wake_up_session_cb() We should reset i_requested_max_size before waking the waiters. (zero i_requested_max_size make waiter re-request the max size) Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/mds_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9abd4db713704aac146395e079224ddd716e9b95 Author: Yan, Zheng <zyan@redhat.com> Date: Wed May 18 20:58:26 2016 +0800 ceph: don't use truncate_pagecache() to invalidate read cache truncate_pagecache() drops dirty pages, it's dangerous to use it to invalidate read cache. Besides, we shouldn't start invalidating read cache while there are buffer writers. Because buffer writers may add dirty pages later. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/caps.c | 8 ++++---- fs/ceph/inode.c | 4 +++- 2 files changed, 7 insertions(+), 5 deletions(-) commit b109eec6f4332bd517e2f41e207037c4b9065094 Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 13 17:54:17 2016 +0800 ceph: SetPageError() for writeback pages if writepages fails Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit ad15ec06e51b6eb73981428109e32c75cbad7d3d Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 13 17:29:51 2016 +0800 ceph: handle interrupted ceph_writepage() writepage() can be interrupted when it's called by direct memory reclaimer (the direct memory relaimer is killed). To avoid lossing data, we redirty the page. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit a78bbd4b29c29784f0addb5e3b35790c7ed178ae Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 13 11:30:24 2016 +0800 ceph: make ceph_update_writeable_page() uninterruptible ceph_update_writeable_page() is used by ceph_write_begin(). It beaks atomicity of write operation if it's interruptible. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0e76abf21e769245b6eebb27b439ad014ac49292 Author: Yan, Zheng <zyan@redhat.com> Date: Fri May 13 11:04:33 2016 +0800 libceph: make ceph_osdc_wait_request() uninterruptible Ceph_osdc_wait_request() is used when cephfs issues sync IO. In most cases, the sync IO should be uninterruptible. The fix is use killale wait function in ceph_osdc_wait_request(). Signed-off-by: Yan, Zheng <zyan@redhat.com> net/ceph/osd_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f0b33df57a5f03c637f75ead7cb4d978c59cc63d Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 10 19:09:06 2016 +0800 ceph: handle -EAGAIN returned by ceph_update_writeable_page() when ceph_update_writeable_page() return -EAGAIN, caller should lock the page and call ceph_update_writeable_page() again. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) commit 6ce026e411c4f36c9e51189d28a5dd9d08095b9d Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 10 18:59:13 2016 +0800 ceph: make fault/page_mkwrite return VM_FAULT_OOM for -ENOMEM Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) commit 4f7e89f6ace0f6cd2f20110efd2d405e26bcbf31 Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 10 18:40:28 2016 +0800 ceph: block non-fatal signals for fault/page_mkwrite Fault and page_mkwrite are supposed to be uninterruptable. But they call ceph functions that are interruptible. So they should block signals before calling functions that are interruptible Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 66 ++++++++++++++++++++++++++++++++++------------------------ 1 file changed, 39 insertions(+), 27 deletions(-) commit 3b33f692c84c28cc8178aaeeb9264d82b48787f1 Author: Zhang Zhuoyu <zhangzhuoyu@cmss.chinamobile.com> Date: Fri Mar 25 05:18:39 2016 -0400 ceph: make logical calculation functions return bool This patch makes serverl logical caculation functions return bool to improve readability due to these particular functions only using 0/1 as their return value. No functional change. Signed-off-by: Zhang Zhuoyu <zhangzhuoyu@cmss.chinamobile.com> fs/ceph/cache.c | 2 +- fs/ceph/dir.c | 2 +- include/linux/ceph/ceph_frag.h | 4 ++-- include/linux/ceph/decode.h | 2 +- include/linux/ceph/osdmap.h | 6 +++--- net/ceph/ceph_common.c | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) commit 224a7542b8fdde3cc7c600f8b0870c5541a9f678 Author: Yan, Zheng <zyan@redhat.com> Date: Thu May 5 16:40:17 2016 +0800 ceph: tolerate bad i_size for symlink inode A mds bug can cause symlink's size to be truncated to zero. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit 1b1bc16d66a7c7af3b4f30d1cf5a363168b217f4 Author: Yan, Zheng <zyan@redhat.com> Date: Wed May 4 11:40:30 2016 +0800 ceph: improve fragtree change detection check if number of splits in i_fragtree is equal to number of splits in mds reply Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 24 ++++++++++++++++++++---- fs/ceph/super.h | 1 + 2 files changed, 21 insertions(+), 4 deletions(-) commit a4b7431f39438f415cef1fa28502ec58016686f7 Author: Yan, Zheng <zyan@redhat.com> Date: Wed May 4 11:05:10 2016 +0800 ceph: keep leaf frag when updating fragtree Nodes in i_fragtree are sorted according to ceph_compare_frag(). It means frag node in i_fragtree always follow its direct parent node. To check if a leaf node is valid, we just need to check if it's child of previous split node. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) commit 421721195a68f46a8218c664154076b5b06f5f51 Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 3 22:33:20 2016 +0800 ceph: fix dir_auth check in ceph_fill_dirfrag() -1 is CDIR_AUTH_PARENT, it means dir's auth mds is the same as inode's auth mds Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 3 +++ 1 file changed, 3 insertions(+) commit a407846ef7c6e7905ab0d1ebc0c86fbebb065b87 Author: Yan, Zheng <zyan@redhat.com> Date: Tue May 3 20:55:50 2016 +0800 ceph: don't assume frag tree splits in mds reply are sorted The algorithm that updates i_fragtree relies on that the frag tree splits in mds reply are of the same order of i_fragtree. This is not true because current MDS encodes frag tree splits in ascending order of (unsigned)frag_t. But nodes in i_fragtree are sorted according to ceph_frag_compare(). The fix is sort the frag tree splits first, then updates i_fragtree. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 209ae762a64397557be2bc48490fd968912e9a71 Author: Yan, Zheng <zyan@redhat.com> Date: Fri Apr 29 23:40:23 2016 +0800 ceph: fix inode reference leak Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f3c4ebe65ea149ec892f94474233cfebe9cbe299 Author: Yan, Zheng <zyan@redhat.com> Date: Fri Apr 29 11:27:30 2016 +0800 ceph: using hash value to compose dentry offset If MDS sorts dentries in dirfrag in hash order, we use hash value to compose dentry offset. dentry offset is: (0xff << 52) | ((24 bits hash) << 28) | (the nth entry hash hash collision) This offset is stable across directory fragmentation. This alos means there is no need to reset readdir offset if directory get fragmented in the middle of readdir. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 140 ++++++++++++++++++++++++++++++++----------- fs/ceph/inode.c | 31 ++++++++-- fs/ceph/mds_client.c | 1 + fs/ceph/mds_client.h | 4 +- fs/ceph/super.h | 6 +- include/linux/ceph/ceph_fs.h | 1 + 6 files changed, 136 insertions(+), 47 deletions(-) commit 076c40f18d10489e29c515bf5936952830df5e16 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 28 22:56:44 2016 +0800 ceph: don't forbid marking directory complete after forward seek Forward seek within same frag does not update fi->last_name, it will not affect contents of later readdir reply. So there is no need to forbid marking directory complete Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 5 ----- 1 file changed, 5 deletions(-) commit 8974eebd38737c9534d81c4131c5fdb1fe24d3e9 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 28 15:17:40 2016 +0800 ceph: record 'offset' for each entry of readdir result This is preparation for using hash value as dentry 'offset' Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 83 ++++++++++++++++++++++++++++++++++------------------ fs/ceph/inode.c | 1 + fs/ceph/mds_client.c | 2 ++ fs/ceph/mds_client.h | 1 + fs/ceph/super.h | 1 - 5 files changed, 59 insertions(+), 29 deletions(-) commit 956d39d631dbcf7b57854873a24e309047f2a7f5 Author: Yan, Zheng <zyan@redhat.com> Date: Wed Apr 27 17:48:30 2016 +0800 ceph: define 'end/complete' in readdir reply as bit flags Set a flag in readdir request, which indicates that client interprets 'end/complete' as bit flags. So that mds can reply additional flags in readdir reply. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 2 ++ fs/ceph/mds_client.c | 7 +++++-- fs/ceph/mds_client.h | 2 +- include/linux/ceph/ceph_fs.h | 12 ++++++++++++ 4 files changed, 20 insertions(+), 3 deletions(-) commit 2a5beea3f1b6544d6c72ea220e860a2eda2f9104 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 28 09:37:39 2016 +0800 ceph: define struct for dir entry in readdir reply This avoids defining multiple arrays for entries in readdir reply Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 27 ++++++++++++--------------- fs/ceph/inode.c | 21 +++++++++++---------- fs/ceph/mds_client.c | 42 +++++++++++++++++++----------------------- fs/ceph/mds_client.h | 12 ++++++++---- 4 files changed, 50 insertions(+), 52 deletions(-) commit a78600e7c4fb47fb5ef34265456b731fde27a9c3 Author: Yan, Zheng <zyan@redhat.com> Date: Wed Apr 27 17:32:34 2016 +0800 ceph: simplify 'offset in frag' don't distinguish leftmost frag from other frags. always use 2 as first entry's offset. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 12 +++--------- fs/ceph/inode.c | 5 +---- 2 files changed, 4 insertions(+), 13 deletions(-) commit 1cd42a429174689c0df1c37b642654a1ab4d1506 Author: Yan, Zheng <zyan@redhat.com> Date: Fri Apr 29 15:58:32 2016 +0800 ceph: remove unnecessary checks in __dcache_readdir we never add snapdir and the hidden .ceph dir into readdir cache Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 2 -- 1 file changed, 2 deletions(-) commit c530cd24c23818af8da35fe556f9a7754211e50a Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 28 17:43:35 2016 +0800 ceph: search cache postion for dcache readdir use binary search to find cache index that corresponds to readdir postion. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/dir.c | 129 +++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 83 insertions(+), 46 deletions(-) commit 04303d8ad06985bed4ea4f46018fc8f55a0962a8 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 21 12:11:54 2016 +0800 ceph: use CEPH_MDS_OP_RMXATTR request to remove xattr Setxattr with NULL value and XATTR_REPLACE flag should be equivalent to removexattr. But current MDS does not support deleting vxattrs through MDS_OP_SETXATTR request. The workaround is sending MDS_OP_RMXATTR request if setxattr actually removs xattr. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/xattr.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit 3f38495409b613071021fca86629df7ae81820ad Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 21 11:09:55 2016 +0800 ceph: report mount root in session metadata Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/mds_client.c | 4 +++- fs/ceph/super.c | 33 +++++++++++++++++++-------------- fs/ceph/super.h | 1 + 3 files changed, 23 insertions(+), 15 deletions(-) commit aeda081c5eb3d7668b64e2dc9bfc0bf30ef53632 Author: Yan, Zheng <zyan@redhat.com> Date: Mon Apr 18 16:51:37 2016 +0800 ceph: don't show symlink target in debugfs/mdsc symlink target is useless for debug and can be very long. It's annoying to show it in debugfs/mdsc. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6c93df5db628e710697c43bc1bd78a786549a548 Author: Yan, Zheng <zyan@redhat.com> Date: Fri Apr 15 13:56:12 2016 +0800 ceph: don't call truncate_pagecache in ceph_writepages_start truncate_pagecache() may decrease inode's reference. This can cause deadlock if inode's last reference is dropped and iput_final() wants to evict the inode. (evict() calls inode_wait_for_writeback(), which waits for ceph_writepages_start() to return). The fix is use work thead to truncate dirty pages. Also add 'forced umount' check to ceph_update_writeable_page(), which prevents new pages getting dirty. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/addr.c | 14 ++++++++++++-- fs/ceph/inode.c | 11 +++++++++++ fs/ceph/mds_client.c | 22 +++++++++++++++------- 3 files changed, 38 insertions(+), 9 deletions(-) commit 77310320c299b0dc050037ff8fc29fd1861fb005 Author: Yan, Zheng <zyan@redhat.com> Date: Fri Apr 8 15:27:16 2016 +0800 ceph: renew caps for read/write if mds session got killed. When mds session gets killed, read/write operation may hang. Client waits for Frw caps, but mds does not know what caps client wants. To recover this, client sends an open request to mds. The request will tell mds what caps client wants. Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/caps.c | 43 ++++++++++++++++++++++++++++++++---------- fs/ceph/file.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++ fs/ceph/mds_client.c | 6 +++++- fs/ceph/super.h | 2 ++ 4 files changed, 93 insertions(+), 11 deletions(-) commit d463a43d69f4af85887671d76182437775fd1631 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Mar 31 15:53:01 2016 +0800 ceph: CEPH_FEATURE_MDSENC support Signed-off-by: Yan, Zheng <zyan@redhat.com> fs/ceph/mdsmap.c | 43 ++++++++++++++++++++++++++++++++++--------- fs/ceph/super.c | 5 ++--- 2 files changed, 36 insertions(+), 12 deletions(-) commit 235a09821c2bc71d9d07f12217ce2ac00db99eba Author: Yan, Zheng <zyan@redhat.com> Date: Wed Mar 30 17:18:34 2016 +0800 ceph: multiple filesystem support To access non-default filesystem, we just need to subscribe to mdsmap.<MDS_NAMESPACE_ID> and add a new mount option for mds namespace id. Signed-off-by: Yan, Zheng <zyan@redhat.com> [idryomov@gmail.com: switch to a new libceph API] Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/super.c | 9 +++++++++ fs/ceph/super.h | 1 + 2 files changed, 10 insertions(+) commit 737cc81ead34bcef0b1f6ea8322228e4378cf21a Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu May 26 00:05:01 2016 +0200 libceph: support for subscribing to "mdsmap.<id>" maps Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/ceph_fs.h | 2 ++ include/linux/ceph/mon_client.h | 1 + net/ceph/debugfs.c | 1 + net/ceph/mon_client.c | 18 +++++++++++++----- 4 files changed, 17 insertions(+), 5 deletions(-) commit 7cca78c9dcd1afa243e46edc31896730df85d2b5 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:28 2016 +0200 libceph: replace ceph_monc_request_next_osdmap() ... with a wrapper around maybe_request_map() - no need for two osdmap-specific functions. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 2 +- include/linux/ceph/mon_client.h | 1 - include/linux/ceph/osd_client.h | 1 + net/ceph/mon_client.c | 14 -------------- net/ceph/osd_client.c | 7 +++++++ 5 files changed, 9 insertions(+), 16 deletions(-) commit b4f34795697de9d1ee84a10c8439b4b9970ebd96 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:27 2016 +0200 libceph: take osdc->lock in osdmap_show() and dump flags in hex There is now about a dozen CEPH_OSDMAP_* flags. This is a debugging interface, so just dump in hex instead of spelling each flag out. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/debugfs.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 4609245e2670e3698b083bcd9cc69a65b2b6f9a6 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:27 2016 +0200 libceph: pool deletion detection This adds the "map check" infrastructure for sending osdmap version checks on CALC_TARGET_POOL_DNE and completing in-flight requests with -ENOENT if the target pool doesn't exist or has just been deleted. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osd_client.h | 6 + net/ceph/osd_client.c | 248 +++++++++++++++++++++++++++++++++++++++- 2 files changed, 248 insertions(+), 6 deletions(-) commit d0b19705e99939f5ae5aa9b57bfe41dd4777d951 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:27 2016 +0200 libceph: async MON client generic requests For map check, we are going to need to send CEPH_MSG_MON_GET_VERSION messages asynchronously and get a callback on completion. Refactor MON client to allow firing off generic requests asynchronously and add an async variant of ceph_monc_get_version(). ceph_monc_do_statfs() is switched over and remains sync. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 4 +- include/linux/ceph/mon_client.h | 19 ++- net/ceph/mon_client.c | 316 ++++++++++++++++++++++++++-------------- 3 files changed, 228 insertions(+), 111 deletions(-) commit b07d3c4bd7270c74e2b6803af8ac8a00cb3e5ed2 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:27 2016 +0200 libceph: support for checking on status of watch Implement ceph_osdc_watch_check() to be able to check on status of watch. Note that the time it takes for a watch/notify event to get delivered through the notify_wq is taken into account. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osd_client.h | 4 ++++ net/ceph/osd_client.c | 52 ++++++++++++++++++++++++++++++++++++++++- 2 files changed, 55 insertions(+), 1 deletion(-) commit 1907920324f1f3ebb6618344417c03a2863bba01 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:27 2016 +0200 libceph: support for sending notifies Implement ceph_osdc_notify() for sending notifies. Due to the fact that the current messenger can't do read-in into pagelists (it can only do write-out from them), I had to go with a page vector for a NOTIFY_COMPLETE payload, for now. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osd_client.h | 20 ++++ include/linux/ceph/rados.h | 3 + net/ceph/debugfs.c | 5 +- net/ceph/osd_client.c | 232 ++++++++++++++++++++++++++++++++++++++-- 4 files changed, 249 insertions(+), 11 deletions(-) commit 922dab6134178cae317ae00de86376cba59f3147 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu May 26 01:15:02 2016 +0200 libceph, rbd: ceph_osd_linger_request, watch/notify v2 This adds support and switches rbd to a new, more reliable version of watch/notify protocol. As with the OSD client update, this is mostly about getting the right structures linked into the right places so that reconnects are properly sent when needed. watch/notify v2 also requires sending regular pings to the OSDs - send_linger_ping(). A major change from the old watch/notify implementation is the introduction of ceph_osd_linger_request - linger requests no longer piggy back on ceph_osd_request. ceph_osd_event has been merged into ceph_osd_linger_request. All the details are now hidden within libceph, the interface consists of a simple pair of watch/unwatch functions and ceph_osdc_notify_ack(). ceph_osdc_watch() does return ceph_osd_linger_request, but only to keep the lifetime management simple. ceph_osdc_notify_ack() accepts an optional data payload, which is relayed back to the notifier. Portions of this patch are loosely based on work by Douglas Fuller <dfuller@redhat.com> and Mike Christie <michaelc@cs.wisc.edu>. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 179 ++---- include/linux/ceph/ceph_fs.h | 5 +- include/linux/ceph/osd_client.h | 97 ++-- include/linux/ceph/rados.h | 17 +- net/ceph/ceph_strings.c | 16 + net/ceph/debugfs.c | 36 ++ net/ceph/osd_client.c | 1148 ++++++++++++++++++++++++++++++--------- 7 files changed, 1067 insertions(+), 431 deletions(-) commit c525f03601f52c83ded046624138f2a45e0ba56c Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:26 2016 +0200 rbd: rbd_dev_header_unwatch_sync() variant Introduce __rbd_dev_header_unwatch_sync(), which doesn't flush notify callbacks. This is for the new rados_watcherrcb_t, which would be called from a notify callback. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) commit 42b0696527c49a109e9558162b8d109ae257d402 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:26 2016 +0200 libceph: wait_request_timeout() The unwatch timeout is currently implemented in rbd. With watch/unwatch code moving into libceph, we are going to need a ceph_osdc_wait_request() variant with a timeout. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) commit 3540bfdb30fcb423a92cc959708e71bc39eb18c3 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:26 2016 +0200 libceph: request_init() and request_release_checks() These are going to be used by request_reinit() code. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 44 +++++++++++++++++++++++++++----------------- 1 file changed, 27 insertions(+), 17 deletions(-) commit 5aea3dcd50215fa9563270251ad7323e2f2490ee Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:26 2016 +0200 libceph: a major OSD client update This is a major sync up, up to ~Jewel. The highlights are: - per-session request trees (vs a global per-client tree) - per-session locking (vs a global per-client rwlock) - homeless OSD session - no ad-hoc global per-client lists - support for pool quotas - foundation for watch/notify v2 support - foundation for map check (pool deletion detection) support The switchover is incomplete: lingering requests can be setup and teared down but aren't ever reestablished. This functionality is restored with the introduction of the new lingering infrastructure (ceph_osd_linger_request, linger_work, etc) in a later commit. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/ioctl.c | 8 +- fs/ceph/xattr.c | 8 +- include/linux/ceph/osd_client.h | 18 +- net/ceph/debugfs.c | 34 +- net/ceph/osd_client.c | 1164 +++++++++++++++++++-------------------- 5 files changed, 602 insertions(+), 630 deletions(-) commit 9dd2845ccb40452d4ac943231ea34aade4a02c68 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:26 2016 +0200 libceph: protect osdc->osd_lru list with a spinlock OSD client is getting moved from the big per-client lock to a set of per-session locks. The big rwlock would only be held for read most of the time, so a global osdc->osd_lru needs additional protection. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osd_client.h | 1 + net/ceph/osd_client.c | 29 ++++++++++++++++++----------- 2 files changed, 19 insertions(+), 11 deletions(-) commit 7a28f59bf9fb220cdf56ac6ab539fc4a0ae59414 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:25 2016 +0200 libceph: allocate ceph_osd with GFP_NOFAIL create_osd() is called way too deep in the stack to be able to error out in a sane way; a failing create_osd() just messes everything up. The current req_notarget list solution is broken - the list is never traversed as it's not entirely clear when to do it, I guess. If we were to start traversing it at regular intervals and retrying each request, we wouldn't be far off from what __GFP_NOFAIL is doing, so allocate OSD sessions with __GFP_NOFAIL, at least until we come up with a better fix. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 0247a0cf3e777932a0cae37ab1d8055a3881458c Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:25 2016 +0200 libceph: osd_init() and osd_cleanup() These are going to be used by homeless OSD sessions code. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 46 +++++++++++++++++++++++++++++++++++++--------- 1 file changed, 37 insertions(+), 9 deletions(-) commit 42c1b1240326cbea86f15f5d4ce565d8b54be31f Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:25 2016 +0200 libceph: handle_one_map() Separate osdmap handling from decoding and iterating over a bag of maps in a fresh MOSDMap message. This sets up the scene for the updated OSD client. Of particular importance here is the addition of pi->was_full, which can be used to answer "did this pool go full -> not-full in this map?". This is the key bit for supporting pool quotas. We won't be able to downgrade map_sem for much longer, so drop downgrade_write(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/mon_client.h | 1 + include/linux/ceph/osdmap.h | 2 + net/ceph/mon_client.c | 8 ++ net/ceph/osd_client.c | 186 ++++++++++++++++++++++++++++------------ 4 files changed, 141 insertions(+), 56 deletions(-) commit 0985b65d3ba2c09f10a594b73df45c1f7f68d317 Merge: 55c1c7b2 19f1845 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 15:59:09 2016 -0700 Merge branch 'work.iov_iter' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs iov_iter regression fix from Al Viro: "Fix for braino in 'fold checks into iterate_and_advance()'" * 'work.iov_iter' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: do "fold checks into iterate_and_advance()" right commit 55c1c7b2b66e3011f981d81aaf21fa810935908a Merge: e92677d 0040773 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 15:54:35 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs xattr regression fixes from Al Viro. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: make xattr_resolve_handlers() safe to use with NULL ->s_xattr xattr: Fail with -EINVAL for NULL attribute names commit e92677dfce88b96ade9100c77eb3f76d98d29d74 Merge: 877c057 0cc4b48 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 15:38:56 2016 -0700 Merge tag 'acpi-4.7-rc1-more' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI fix from Rafael Wysocki: "Additional ACPI update for v4.7-rc1 Just one fix for incorrect async_synchronize_cookie() usage in the ACPI battery driver (Chris Wilson)" * tag 'acpi-4.7-rc1-more' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI / battery: Correctly serialise with the pending async probe commit e5253a7bde13788d9dc75f42eb47ea119af5609f Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:25 2016 +0200 libceph: allocate dummy osdmap in ceph_osdc_init() This leads to a simpler osdmap handling code, particularly when dealing with pi->was_full, which is introduced in a later commit. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osdmap.h | 1 + net/ceph/osd_client.c | 22 +++++++++++----------- net/ceph/osdmap.c | 23 ++++++++++++++++++----- 3 files changed, 30 insertions(+), 16 deletions(-) commit fbca963532eba779bffa14c70d1dc619e6bfa16d Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:24 2016 +0200 libceph: schedule tick from ceph_osdc_init() Both homeless OSD sessions and watch/notify v2, introduced in later commits, require periodic ticks which don't depend on ->num_requests. Schedule the initial tick from ceph_osdc_init() and reschedule from handle_timeout() unconditionally. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 37 +++++++++---------------------------- 1 file changed, 9 insertions(+), 28 deletions(-) commit b37ee1b9b840a6da63e78865f97a9a78b7534477 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:24 2016 +0200 libceph: move schedule_delayed_work() in ceph_osdc_init() ceph_osdc_stop() isn't called if ceph_osdc_init() fails, so we end up with handle_osds_timeout() running on invalid memory if any one of the allocations fails. Call schedule_delayed_work() after everything is setup, just before returning. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit fe5da05e979830b43b115d8a18ead521d507c783 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:24 2016 +0200 libceph: redo callbacks and factor out MOSDOpReply decoding If you specify ACK | ONDISK and set ->r_unsafe_callback, both ->r_callback and ->r_unsafe_callback(true) are called on ack. This is very confusing. Redo this so that only one of them is called: ->r_unsafe_callback(true), on ack ->r_unsafe_callback(false), on commit or ->r_callback, on ack|commit Decode everything in decode_MOSDOpReply() to reduce clutter. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/addr.c | 3 +- fs/ceph/file.c | 2 + include/linux/ceph/osd_client.h | 5 +- net/ceph/osd_client.c | 362 +++++++++++++++++++++++----------------- 4 files changed, 215 insertions(+), 157 deletions(-) commit 85e084feb47349d62989efe1713a8723af95f4ea Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:24 2016 +0200 libceph: drop msg argument from ceph_osdc_callback_t finish_read(), its only user, uses it to get to hdr.data_len, which is what ->r_result is set to on success. This gains us the ability to safely call callbacks from contexts other than reply, e.g. map check. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 5 ++--- fs/ceph/addr.c | 9 ++++----- fs/ceph/file.c | 7 +++---- include/linux/ceph/osd_client.h | 3 +-- net/ceph/osd_client.c | 4 ++-- 5 files changed, 12 insertions(+), 16 deletions(-) commit bb873b539154ab51893430b4ad6ba4051775276a Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu May 26 00:29:52 2016 +0200 libceph: switch to calc_target(), part 2 The crux of this is getting rid of ceph_osdc_build_request(), so that MOSDOp can be encoded not before but after calc_target() calculates the actual target. Encoding now happens within ceph_osdc_start_request(). Also nuked is the accompanying bunch of pointers into the encoded buffer that was used to update fields on each send - instead, the entire front is re-encoded. If we want to support target->name_len != base->name_len in the future, there is no other way, because oid is surrounded by other fields in the encoded buffer. Encoding OSD ops and adding data items to the request message were mixed together in osd_req_encode_op(). While we want to re-encode OSD ops, we don't want to add duplicate data items to the message when resending, so all call to ceph_osdc_msg_data_add() are factored out into a new setup_request_data(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 18 +- fs/ceph/addr.c | 16 +- fs/ceph/file.c | 16 +- include/linux/ceph/osd_client.h | 29 ++-- include/linux/ceph/rados.h | 7 + net/ceph/debugfs.c | 61 ++++--- net/ceph/osd_client.c | 355 ++++++++++++++++++++-------------------- 7 files changed, 247 insertions(+), 255 deletions(-) commit a66dd38309f5d9c66ec9bc7911ff8da8cc37bb9f Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:23 2016 +0200 libceph: switch to calc_target(), part 1 Replace __calc_request_pg() and most of __map_request() with calc_target() and start using req->r_t. ceph_osdc_build_request() however still encodes base_oid, because it's called before calc_target() is and target_oid is empty at that point in time; a printf in osdc_show() also shows base_oid. This is fixed in "libceph: switch to calc_target(), part 2". Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osd_client.h | 15 ++--- net/ceph/debugfs.c | 2 +- net/ceph/osd_client.c | 119 ++++++++-------------------------------- 3 files changed, 29 insertions(+), 107 deletions(-) commit 63244fa123a755e4bbaee03022b68613c71d1332 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:23 2016 +0200 libceph: introduce ceph_osd_request_target, calc_target() Introduce ceph_osd_request_target, containing all mapping-related fields of ceph_osd_request and calc_target() for calculating mappings and populating it. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/addr.c | 2 +- fs/ceph/file.c | 2 +- include/linux/ceph/osd_client.h | 23 ++++++ include/linux/ceph/osdmap.h | 34 +++++++++ include/linux/ceph/rados.h | 5 ++ net/ceph/osd_client.c | 157 +++++++++++++++++++++++++++++++++++++++- net/ceph/osdmap.c | 121 +++++++++++++++++++++++++++++++ 7 files changed, 340 insertions(+), 4 deletions(-) commit 04812acf572ef41fd51c11e0bf3385f34c0e1b5b Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:23 2016 +0200 libceph: pi->min_size, pi->last_force_request_resend Add and decode pi->min_size and pi->last_force_request_resend. These are going to be used by calc_target(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osdmap.h | 9 ++++++--- net/ceph/debugfs.c | 10 ++++++---- net/ceph/osdmap.c | 48 ++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 59 insertions(+), 8 deletions(-) commit f984cb76cc5fb9fc76d6abb6c4694a5412e3f49b Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:23 2016 +0200 libceph: make pgid_cmp() global calc_target() code is going to need to know how to compare PGs. Take lhs and rhs pgid by const * while at it. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osdmap.h | 2 ++ net/ceph/osdmap.c | 23 ++++++++++++----------- 2 files changed, 14 insertions(+), 11 deletions(-) commit f81f16339a05775df600b2ff75a79be1864975c1 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:23 2016 +0200 libceph: rename ceph_calc_pg_primary() Rename ceph_calc_pg_primary() to ceph_pg_to_acting_primary() to emphasise that it returns acting primary. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/ioctl.c | 2 +- include/linux/ceph/osdmap.h | 4 ++-- net/ceph/osdmap.c | 9 +++++---- 3 files changed, 8 insertions(+), 7 deletions(-) commit 6f3bfd45cd233eea0b07e3cabc0386b5de9321d2 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:22 2016 +0200 libceph: ceph_osds, ceph_pg_to_up_acting_osds() Knowning just acting set isn't enough, we need to be able to record up set as well to detect interval changes. This means returning (up[], up_len, up_primary, acting[], acting_len, acting_primary) and passing it around. Introduce and switch to ceph_osds to help with that. Rename ceph_calc_pg_acting() to ceph_pg_to_up_acting_osds() and return both up and acting sets from it. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/osdmap.h | 21 ++- net/ceph/osd_client.c | 36 +++--- net/ceph/osdmap.c | 304 ++++++++++++++++++++++++++------------------ 3 files changed, 215 insertions(+), 146 deletions(-) commit d9591f5e28686277d9312d3c7422faf1368b305e Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:22 2016 +0200 libceph: rename ceph_oloc_oid_to_pg() Rename ceph_oloc_oid_to_pg() to ceph_object_locator_to_pg(). Emphasise that returned is raw PG and return -ENOENT instead of -EIO if the pool doesn't exist. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/ioctl.c | 2 +- include/linux/ceph/osdmap.h | 9 ++++----- net/ceph/osd_client.c | 4 ++-- net/ceph/osdmap.c | 31 ++++++++++++++++--------------- 4 files changed, 23 insertions(+), 23 deletions(-) commit 985c1673885b77b2e0167c6478a833817d1e2fe5 Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:22 2016 +0200 libceph: fix ceph_eversion encoding eversion_t is version+epoch in userspace and is encoded in that order. ceph_eversion is defined as epoch+version in rados.h, yet we memcpy it in __send_request(). Reoder ceph_eversion fields. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/rados.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fcd00b68bbe2bf5606cb45c2cd4a250a390bcc1f Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:22 2016 +0200 libceph: DEFINE_RB_FUNCS macro Given struct foo { u64 id; struct rb_node bar_node; }; generate insert_bar(), erase_bar() and lookup_bar() functions with DEFINE_RB_FUNCS(bar, struct foo, id, bar_node) The key is assumed to be an integer (u64, int, etc), compared with < and >. nodefld has to be initialized with RB_CLEAR_NODE(). Start using it for MDS, MON and OSD requests and OSD sessions. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/mds_client.c | 54 ++++++------------------ include/linux/ceph/libceph.h | 57 ++++++++++++++++++++++++++ net/ceph/mon_client.c | 52 ++++-------------------- net/ceph/osd_client.c | 97 +++++--------------------------------------- 4 files changed, 88 insertions(+), 172 deletions(-) commit 42a2c09f2b0b95fa147bcdb56cdc02b980b9ac5e Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:22 2016 +0200 libceph: open-code remove_{all,old}_osds() They are called only once, from ceph_osdc_stop() and handle_osds_timeout() respectively. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 51 +++++++++++++++++++++------------------------------ 1 file changed, 21 insertions(+), 30 deletions(-) commit 0c0a8de13f9612a663b050afa955e6668858d1eb Author: Ilya Dryomov <idryomov@gmail.com> Date: Thu Apr 28 16:07:21 2016 +0200 libceph: nuke unused fields and functions Either unused or useless: osdmap->mkfs_epoch osd->o_marked_for_keepalive monc->num_generic_requests osdc->map_waiters osdc->last_requested_map osdc->timeout_tid osd_req_op_cls_response_data() osdmap_apply_incremental() @msgr arg Signed-off-by: Ilya Dryomov <idryomov@gmail.com> include/linux/ceph/mon_client.h | 1 - include/linux/ceph/osd_client.h | 8 -------- include/linux/ceph/osdmap.h | 6 ++---- net/ceph/mon_client.c | 3 --- net/ceph/osd_client.c | 13 +------------ net/ceph/osdmap.c | 3 +-- 6 files changed, 4 insertions(+), 30 deletions(-) commit c41d13a31fefed303f734c0c5106f6dcd262168e Author: Ilya Dryomov <idryomov@gmail.com> Date: Fri Apr 29 20:01:25 2016 +0200 rbd: use header_oid instead of header_name Switch to ceph_object_id and use ceph_oid_aprintf() instead of a bare const char *. This reduces noise in rbd_dev_header_name(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 57 ++++++++++++++++++++++------------------------------- 1 file changed, 24 insertions(+), 33 deletions(-) commit d30291b985d1854565d7f2c82a4457869d5265e8 Author: Ilya Dryomov <idryomov@gmail.com> Date: Fri Apr 29 19:54:20 2016 +0200 libceph: variable-sized ceph_object_id Currently ceph_object_id can hold object names of up to 100 (CEPH_MAX_OID_NAME_LEN) characters. This is enough for all use cases, expect one - long rbd image names: - a format 1 header is named "<imgname>.rbd" - an object that points to a format 2 header is named "rbd_id.<imgname>" We operate on these potentially long-named objects during rbd map, and, for format 1 images, during header refresh. (A format 2 header name is a small system-generated string.) Lift this 100 character limit by making ceph_object_id be able to point to an externally-allocated string. Apart from being able to work with almost arbitrarily-long named objects, this allows us to reduce the size of ceph_object_id from >100 bytes to 64 bytes. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 8 +++- fs/ceph/addr.c | 6 +-- fs/ceph/file.c | 2 +- fs/ceph/ioctl.c | 2 +- include/linux/ceph/osdmap.h | 62 ++++++++++++++++++------------ net/ceph/debugfs.c | 2 +- net/ceph/osd_client.c | 16 +++++--- net/ceph/osdmap.c | 93 ++++++++++++++++++++++++++++++++++++++++++++- 8 files changed, 150 insertions(+), 41 deletions(-) commit 711da55d36a6f1eddcd340969be7223110d2f6b0 Author: Ilya Dryomov <idryomov@gmail.com> Date: Wed Apr 27 18:32:56 2016 +0200 libceph: change how osd_op_reply message size is calculated For a message pool message, preallocate a page, just like we do for osd_op. For a normal message, take ceph_object_id into account and don't bother subtracting CEPH_OSD_SLAB_OPS ceph_osd_ops. Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) commit 13d1ad16d05eebb4db977eb955716b9da2c19fbd Author: Ilya Dryomov <idryomov@gmail.com> Date: Wed Apr 27 14:15:51 2016 +0200 libceph: move message allocation out of ceph_osdc_alloc_request() The size of ->r_request and ->r_reply messages depends on the size of the object name (ceph_object_id), while the size of ceph_osd_request is fixed. Move message allocation into a separate function that would have to be called after ceph_object_id and ceph_object_locator (which is also going to become variable in size with RADOS namespaces) have been filled in: req = ceph_osdc_alloc_request(...); <fill in req->r_base_oid> <fill in req->r_base_oloc> ceph_osdc_alloc_messages(req); Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 18 ++++++++- fs/ceph/addr.c | 8 ++++ fs/ceph/file.c | 7 ++++ include/linux/ceph/osd_client.h | 1 + net/ceph/osd_client.c | 88 +++++++++++++++++++++++------------------ 5 files changed, 82 insertions(+), 40 deletions(-) commit 841272825b2263174120ab02b4abac9005ee1420 Author: Ilya Dryomov <idryomov@gmail.com> Date: Tue Apr 26 15:39:47 2016 +0200 libceph: grab snapc in ceph_osdc_alloc_request() ceph_osdc_build_request() is going away. Grab snapc and initialize ->r_snapid in ceph_osdc_alloc_request(). Signed-off-by: Ilya Dryomov <idryomov@gmail.com> net/ceph/osd_client.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 3ed97d6345a36a0a61e6af62ad8a66ca40f1aa2e Author: Ilya Dryomov <idryomov@gmail.com> Date: Tue Apr 26 15:05:29 2016 +0200 libceph: make ceph_osdc_put_request() accept NULL Signed-off-by: Ilya Dryomov <idryomov@gmail.com> fs/ceph/addr.c | 9 +++------ net/ceph/osd_client.c | 8 +++++--- 2 files changed, 8 insertions(+), 9 deletions(-) commit 663ae2cc04773608e1e741f693e41200fd4faf14 Author: Ilya Dryomov <idryomov@gmail.com> Date: Mon May 16 13:18:57 2016 +0200 rbd: get/put img_request in rbd_img_request_submit() By the time we get to checking for_each_obj_request_safe(img_request) terminating condition, all obj_requests may be complete and img_request ref, that rbd_img_request_submit() takes away from its caller, may be put. Moving the next_obj_request cursor is then a use-after-free on img_request. It's totally benign, as the value that's read is never used, but I think it's still worth fixing. Cc: Alex Elder <elder@linaro.org> Signed-off-by: Ilya Dryomov <idryomov@gmail.com> drivers/block/rbd.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit 877c057d2b3cdac9f44c0fbe48e4208375395bf0 Merge: ecc5fbd 4c2628cd Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 15:29:21 2016 -0700 Merge tag 'pm-4.7-rc1-more' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull more power management updates from Rafael Wysocki: "These are two stable-candidate fixes (PM core, cpuidle) and a bunch of cpufreq cleanups. Specifics: - Stable-candidate cpuidle fix to make it check the right variable when deciding whether or not to enable interrupts on the local CPU so as to avoid enabling iterrupts too early in some cases if the system has both coupled and per-core idle states (Daniel Lezcano). - Stable-candidate PM core fix to make it handle failures at the "late suspend" stage of device suspend consistently for all devices regardless of whether or not async suspend/resume is enabled for them (Rafael Wysocki). - Cleanups in the cpufreq core, the schedutil governor and the intel_pstate driver (Rafael Wysocki, Pankaj Gupta, Viresh Kumar)" * tag 'pm-4.7-rc1-more' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PM / sleep: Handle failures in device_suspend_late() consistently cpufreq: schedutil: Improve prints messages with pr_fmt cpuidle: Fix cpuidle_state_is_coupled() argument in cpuidle_enter() cpufreq: simplified goto out in cpufreq_register_driver() cpufreq: governor: CPUFREQ_GOV_STOP never fails cpufreq: governor: CPUFREQ_GOV_POLICY_EXIT never fails intel_pstate: Simplify conditional in intel_pstate_set_policy() commit 19f18459330f4a65fb0b58e77fc58ceceecb1839 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 25 17:36:19 2016 -0400 do "fold checks into iterate_and_advance()" right the only case when we should skip the iterate_and_advance() guts is when nothing's left in the iterator, _not_ just when requested amount is 0. Said guts will do nothing in the latter case anyway; the problem we tried to deal with in the aforementioned commit is that when there's nothing left *and* the amount requested is 0, we might end up deferencing one iovec too many; the value we fetch from there is discarded in that case, but theoretically it might oops if the iovec array ends exactly at the end of page with the next page not mapped. Bailing out on zero size requested had an unexpected side effect - zero-length segment in the beginning of iovec array ended up throwing do_loop_readv_writev() into infinite spin; we do not advance past the empty segment at all. Reproducer is trivial: echo '#include <sys/uio.h>' >a.c echo 'main() {char c; struct iovec v[] = {{&c,0},{&c,1}}; readv(0,v,2);}' >>a.c cc a.c && ./a.out </proc/uptime which should end up with the process not hanging. Probably ought to go into LTP or xfstests... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> lib/iov_iter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0040773bff7b585fc948565a0558e5a6a4680e96 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 25 17:34:41 2016 -0400 make xattr_resolve_handlers() safe to use with NULL ->s_xattr Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/xattr.c | 1 + 1 file changed, 1 insertion(+) commit aaf431b4f92152d46ab54079692633aa422262b1 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Mon May 9 13:28:49 2016 +0200 xattr: Fail with -EINVAL for NULL attribute names Commit 98e9cb57 improved the xattr name checks in xattr_resolve_name but didn't update the NULL attribute name check appropriately, so NULL attribute names lead to NULL pointer dereferences. Turn that into -EINVAL results instead. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> fs/xattr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/xattr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4c6143dd497901e3537dc4324dc203dfda442009 Merge: 42f3173 ae55b9e Author: David Sterba <dsterba@suse.com> Date: Wed May 25 22:51:04 2016 +0200 Merge branch 'dev/comp-workspaces' into for-chris-4.7-20160525 commit 42f31734eb7658fd01fb186d56312be869450a42 Merge: e734408 0132761 Author: David Sterba <dsterba@suse.com> Date: Wed May 25 22:51:03 2016 +0200 Merge branch 'cleanups-4.7' into for-chris-4.7-20160525 commit e73440868fde7cce4a93583a4fa2db9a8938a7ed Merge: c315ef8 f1fee65 Author: David Sterba <dsterba@suse.com> Date: Wed May 25 22:51:02 2016 +0200 Merge branch 'misc-4.7' into for-chris-4.7-20160525 commit 0132761017e012ab4dc8584d679503f2ba26ca86 Author: Nicholas D Steeves <nsteeves@gmail.com> Date: Thu May 19 21:18:45 2016 -0400 btrfs: fix string and comment grammatical issues and typos Signed-off-by: Nicholas D Steeves <nsteeves@gmail.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/backref.c | 2 +- fs/btrfs/btrfs_inode.h | 2 +- fs/btrfs/check-integrity.c | 2 +- fs/btrfs/ctree.c | 14 +++++++------- fs/btrfs/ctree.h | 6 +++--- fs/btrfs/delayed-ref.h | 2 +- fs/btrfs/dev-replace.c | 2 +- fs/btrfs/disk-io.c | 10 +++++----- fs/btrfs/extent-tree.c | 32 ++++++++++++++++---------------- fs/btrfs/extent_io.c | 4 ++-- fs/btrfs/extent_map.c | 2 +- fs/btrfs/file.c | 4 ++-- fs/btrfs/free-space-cache.c | 2 +- fs/btrfs/free-space-cache.h | 2 +- fs/btrfs/inode.c | 22 +++++++++++----------- fs/btrfs/ioctl.c | 10 +++++----- fs/btrfs/ordered-data.h | 2 +- fs/btrfs/qgroup.c | 16 ++++++++-------- fs/btrfs/raid56.c | 6 +++--- fs/btrfs/relocation.c | 12 ++++++------ fs/btrfs/root-tree.c | 4 ++-- fs/btrfs/scrub.c | 4 ++-- fs/btrfs/send.c | 6 +++--- fs/btrfs/struct-funcs.c | 2 +- fs/btrfs/super.c | 8 ++++---- fs/btrfs/tests/extent-io-tests.c | 2 +- fs/btrfs/tests/free-space-tests.c | 7 ++++--- fs/btrfs/tests/inode-tests.c | 2 +- fs/btrfs/tests/qgroup-tests.c | 2 +- fs/btrfs/transaction.h | 2 +- fs/btrfs/tree-log.c | 8 ++++---- fs/btrfs/ulist.c | 2 +- fs/btrfs/volumes.c | 8 ++++---- 33 files changed, 106 insertions(+), 105 deletions(-) commit f1fee6534dcfbf468a159789aa202db2bce8c200 Author: Zhao Lei <zhaolei@cn.fujitsu.com> Date: Tue May 17 17:37:38 2016 +0800 btrfs: scrub: Set bbio to NULL before calling btrfs_map_block We usually call btrfs_put_bbio() when btrfs_map_block() failed, btrfs_put_bbio() works right whether bbio is a valid value, or NULL. But there is a exception, in some case, btrfs_map_block() will return fail without touching *bbio(keeping its original value), and if bbio was not initialized yet, invalid memory accessing will happened. Above case is in scrub_missing_raid56_pages(), and similar case in scrub_raid56_parity(). Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/scrub.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 0cc4b48149ff6948dd82a039ad55cdbec49107f7 Merge: 46c1345 5dfa0c7 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 25 22:11:28 2016 +0200 Merge branch 'acpi-battery' * acpi-battery: ACPI / battery: Correctly serialise with the pending async probe commit f6988cb63a4e698d8a62a1d085d263d1fcc351ea Author: Ivan Vecera <ivecera@redhat.com> Date: Wed May 25 21:21:52 2016 +0200 team: don't call netdev_change_features under team->lock The team_device_event() notifier calls team_compute_features() to fix vlan_features under team->lock to protect team->port_list. The problem is that subsequent __team_compute_features() calls netdev_change_features() to propagate vlan_features to upper vlan devices while team->lock is still taken. This can lead to deadlock when NETIF_F_LRO is modified on lower devices or team device itself. Example: The team0 as active backup with eth0 and eth1 NICs. Both eth0 & eth1 are LRO capable and LRO is enabled. Thus LRO is also enabled on team0. The command 'ethtool -K team0 lro off' now hangs due to this deadlock: dev_ethtool() -> ethtool_set_features() -> __netdev_update_features(team) -> netdev_sync_lower_features() -> netdev_update_features(lower_1) -> __netdev_update_features(lower_1) -> netdev_features_change(lower_1) -> call_netdevice_notifiers(...) -> team_device_event(lower_1) -> team_compute_features(team) [TAKES team->lock] -> netdev_change_features(team) -> __netdev_update_features(team) -> netdev_sync_lower_features() -> netdev_update_features(lower_2) -> __netdev_update_features(lower_2) -> netdev_features_change(lower_2) -> call_netdevice_notifiers(...) -> team_device_event(lower_2) -> team_compute_features(team) [DEADLOCK] The bug is present in team from the beginning but it appeared after the commit fd867d5 (net/core: generic support for disabling netdev features down stack) that adds synchronization of features with lower devices. Fixes: fd867d5 (net/core: generic support for disabling netdev features down stack) Cc: Jiri Pirko <jiri@resnulli.us> Signed-off-by: Ivan Vecera <ivecera@redhat.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/team/team.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 4c2628cd7580bc4f4a4994925cf366185ecc37a5 Merge: d57d394 60f05e8 e7387da 3a17fb3 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 25 21:54:45 2016 +0200 Merge branches 'pm-cpufreq', 'pm-cpuidle' and 'pm-core' * pm-cpufreq: cpufreq: schedutil: Improve prints messages with pr_fmt cpufreq: simplified goto out in cpufreq_register_driver() cpufreq: governor: CPUFREQ_GOV_STOP never fails cpufreq: governor: CPUFREQ_GOV_POLICY_EXIT never fails intel_pstate: Simplify conditional in intel_pstate_set_policy() * pm-cpuidle: cpuidle: Fix cpuidle_state_is_coupled() argument in cpuidle_enter() * pm-core: PM / sleep: Handle failures in device_suspend_late() consistently commit 9ea46abe22550e3366ff7cee2f8391b35b12f730 Author: David S. Miller <davem@davemloft.net> Date: Wed May 25 12:51:20 2016 -0700 sparc64: Take ctx_alloc_lock properly in hugetlb_setup(). On cheetahplus chips we take the ctx_alloc_lock in order to modify the TLB lookup parameters for the indexed TLBs, which are stored in the context register. This is called with interrupts disabled, however ctx_alloc_lock is an IRQ safe lock, therefore we must take acquire/release it properly with spin_{lock,unlock}_irq(). Reported-by: Meelis Roos <mroos@linux.ee> Tested-by: Meelis Roos <mroos@linux.ee> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/mm/init_64.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit f58fb330121d072fdfd8b36403bc421899fe8a40 Merge: c0795bf f05e2db Author: David S. Miller <davem@davemloft.net> Date: Wed May 25 12:45:41 2016 -0700 Merge branch 'dsa-doc-fixes' Florian Fainelli says: ==================== Documentation: dsa: misc fixes Here are some miscelaneous documentation fixes for DSA, I targeted "net" because these are not functional code changes, but still documentation fixes per-se. Changes in v2: - reword what the port_vlan_filtering is about based on feedback from Vivien and Ido ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f05e2db1996d7a640c76481ba5ea3d7a295a8f48 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue May 24 21:26:41 2016 -0700 Documentation: networking: dsa: Describe port_vlan_filtering Described what the port_vlan_filtering function is supposed to accomplish. Fixes: fb2dabad69f0 ("net: dsa: support VLAN filtering switchdev attr") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/dsa.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 7013d8e1d0a07b74dc6f81b470654290b769e9bb Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue May 24 21:26:40 2016 -0700 Documentation: networking: dsa: Remove priv_size description We no longer have a priv_size structure member since 5feebd0a8a79 ("net: dsa: Remove allocation of driver private memory") Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/dsa.txt | 2 -- 1 file changed, 2 deletions(-) commit 75c0bbd0e23a295faf80aa68bf5ab2b5fac709b2 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue May 24 21:26:39 2016 -0700 Documentation: networking: dsa: Remove poll_link description This function has been removed in 4baee937b8d5 ("net: dsa: remove DSA link polling") in favor of using the PHYLIB polling mechanism. Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/dsa.txt | 5 ----- 1 file changed, 5 deletions(-) commit c0795bf64cba4d1b796fdc5b74b33772841ed1bb Author: Edward Cree <ecree@solarflare.com> Date: Tue May 24 18:53:36 2016 +0100 sfc: on MC reset, clear PIO buffer linkage in TXQs Otherwise, if we fail to allocate new PIO buffers, our TXQs will try to use the old ones, which aren't there any more. Fixes: 183233bec810 "sfc: Allocate and link PIO buffers; map them with write-combining" Signed-off-by: Edward Cree <ecree@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/sfc/ef10.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 492a7e67ff83fc59adb768de25ccaecd33d46beb Author: Mark Bloch <markb@mellanox.com> Date: Wed May 18 16:42:43 2016 +0300 IB/IPoIB: Allow setting the device address In IB networks, and specifically in IPoIB/rdmacm traffic, the device address of an IPoIB interface is used as a means to exchange information between nodes needed for communication. Currently an IPoIB interface will always be created with a device address based on its node GUID without a way to change that. This change adds the ability to set the device address of an IPoIB interface by value. We use the set mac address ndo to do that. The flow should be broken down to two: 1) The GID value is already in the GID table, in this case the interface will be able to set carrier up. 2) The GID value is not yet in the GID table, in this case the interface won't try to join the multicast group and will wait (listen on GID_CHANGE event) until the GID is inserted. In order to track those changes, we add a new flag: * IPOIB_FLAG_DEV_ADDR_SET. When set, it means the dev_addr is a based on a value in the gid table. this bit will be cleared upon a dev_addr change triggered by the user and set after validation. Per IB spec the port GUID can't change if the module is loaded. port GUID is the basis for GID at index 0 which is the basis for the default device address of a ipoib interface. The issue is that there are devices that don't follow the spec, they change the port GUID while HCA is powered on, so in order not to break userspace applications. We need to check if the user wanted to control the device address and we assume that if he sets the device address back to be based on GID index 0, he no longer wishs to control it. In order to track this, we add an additional flag: * IPOIB_FLAG_DEV_ADDR_CTRL When setting the device address, there is no validation of the upper twelve bytes of the device address (flags, qpn, subnet prefix) as those bytes are not under the control of the user. Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/ipoib/ipoib.h | 2 + drivers/infiniband/ulp/ipoib/ipoib_ib.c | 109 ++++++++++++++++++++++++- drivers/infiniband/ulp/ipoib/ipoib_main.c | 67 +++++++++++++++ drivers/infiniband/ulp/ipoib/ipoib_multicast.c | 10 ++- drivers/infiniband/ulp/ipoib/ipoib_verbs.c | 3 + drivers/infiniband/ulp/ipoib/ipoib_vlan.c | 2 + 6 files changed, 187 insertions(+), 6 deletions(-) commit 3b56113016400a4e2b9870c368ebb8080cb5739b Author: Erez Shitrit <erezsh@mellanox.com> Date: Wed May 25 22:02:07 2016 +0300 IB/ipoib: Support SendOnlyFullMember MCG for SendOnly join Check (via an SA query) if the SM supports the new option for SendOnly multicast joins. If the SM supports that option it will use the new join state to create such multicast group. If SendOnlyFullMember is supported, we wouldn't use faked FullMember state join for SendOnly MCG, use the correct state if supported. This check is performed at every invocation of mcast_restart task, to be sure that the driver stays in sync with the current state of the SM. Signed-off-by: Erez Shitrit <erezsh@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/ipoib/ipoib.h | 2 + drivers/infiniband/ulp/ipoib/ipoib_main.c | 73 ++++++++++++++++++++++++++ drivers/infiniband/ulp/ipoib/ipoib_multicast.c | 38 +++++++++----- 3 files changed, 100 insertions(+), 13 deletions(-) commit cd6e9b7ef90515cb90962059ffb03b679de27f99 Author: Erez Shitrit <erezsh@mellanox.com> Date: Wed May 25 22:02:06 2016 +0300 IB/core: Support new type of join-state for multicast There are four types for MCG, FullMember, NonMember, SendOnlyNonMember, and the new added type: SendOnlyFullMember. Add support for the new SendOnlyFullMember join state. The new type allows host to send join request as sendonly, it will cause the group to be created but without getting packets from this multicast back to the host. Signed-off-by: Erez Shitrit <erezsh@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Reviewed-by: Christoph Lameter <cl@linux.com> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/multicast.c | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) commit 628e6f75156eac6979eacc2e9383e41f6432beb4 Author: Erez Shitrit <erezsh@mellanox.com> Date: Wed May 25 22:02:05 2016 +0300 IB/SA Agent: Add support for SA agent get ClassPortInfo New SA query function to return the ClassPortInfo struct from the SA. If the SM supports FullMemberSendOnly mode for MCG's, it sets a capability bit in the capability_mask2 field of the response. Signed-off-by: Erez Shitrit <erezsh@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/sa_query.c | 173 +++++++++++++++++++++++++++++++++++++ include/rdma/ib_sa.h | 12 +++ 2 files changed, 185 insertions(+) commit 507f6afa3ab6c9473d81c8091be0d1b859509a6d Author: Erez Shitrit <erezsh@mellanox.com> Date: Wed May 25 22:02:04 2016 +0300 IB/core: Introduce capabilitymask2 field in ClassPortInfo mad Change struct ib_class_port_info to conform to IB Spec 1.3 That in order to get specific capability mask from ClassPortInfo mad. >From the IB Spec, ClassPortInfo section: "CapabilityMask2 Bits 0-26: Additional class-specific capabilities... RespTimeValue the rest 5 bits" The new struct now has one field for capabilitymask2 (previously was the reserved field) and the resp_time field. And it fixes up qib and srpt, use of the field repurposed to be used as capabilitymask2: IB/qib: Change pma_get_classportinfo IB/srpt: Adjust the use of ib_class_port_info Signed-off-by: Erez Shitrit <erezsh@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Reviewed-by: Hal Rosenstock <hal@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/qib/qib_mad.c | 6 ++-- drivers/infiniband/ulp/srpt/ib_srpt.c | 2 +- include/rdma/ib_mad.h | 60 +++++++++++++++++++++++++++++++++-- 3 files changed, 63 insertions(+), 5 deletions(-) commit 217f97e85608c5878ccc7850d6f4ea332622f537 Merge: 297f7d2 b388fc7 Author: David S. Miller <davem@davemloft.net> Date: Wed May 25 12:35:09 2016 -0700 Merge branch 'hwbm-locking-fixes' Gregory CLEMENT says: ==================== Fix spinlock usage in HWBM these two patches fix spinlock related issues introduced in v4.6. They have been reported by Russell King and Jean-Jacques Hiblot. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b388fc7405e901c7d6f7817d05193c054e761815 Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Tue May 24 18:03:26 2016 +0200 net: hwbm: Fix unbalanced spinlock in error case When hwbm_pool_add exited in error the spinlock was not released. This patch fixes this issue. Fixes: 8cb2d8bf57e6 ("net: add a hardware buffer management helper API") Reported-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com> Cc: <stable@vger.kernel.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/hwbm.c | 3 +++ 1 file changed, 3 insertions(+) commit 91c45e38b9478ff507e05f10151d64cd0d1aad7b Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Tue May 24 18:03:25 2016 +0200 net: mvneta: Fix lacking spinlock initialization The spinlock used by the hwbm functions must be initialized by the network driver. This commit fixes this lack and the following erros when lockdep is enabled: INFO: trying to register non-static key. the code is fine but needs lockdep annotation. turning off the locking correctness validator. [<c010ff80>] (unwind_backtrace) from [<c010bd08>] (show_stack+0x10/0x14) [<c010bd08>] (show_stack) from [<c032913c>] (dump_stack+0xb4/0xe0) [<c032913c>] (dump_stack) from [<c01670e4>] (__lock_acquire+0x1f58/0x2060) [<c01670e4>] (__lock_acquire) from [<c0167dec>] (lock_acquire+0xa4/0xd0) [<c0167dec>] (lock_acquire) from [<c06f6650>] (_raw_spin_lock_irqsave+0x54/0x68) [<c06f6650>] (_raw_spin_lock_irqsave) from [<c058e830>] (hwbm_pool_add+0x1c/0xdc) [<c058e830>] (hwbm_pool_add) from [<c043f4e8>] (mvneta_bm_pool_use+0x338/0x490) [<c043f4e8>] (mvneta_bm_pool_use) from [<c0443198>] (mvneta_probe+0x654/0x1284) [<c0443198>] (mvneta_probe) from [<c03b894c>] (platform_drv_probe+0x4c/0xb0) [<c03b894c>] (platform_drv_probe) from [<c03b7158>] (driver_probe_device+0x214/0x2c0) [<c03b7158>] (driver_probe_device) from [<c03b72c4>] (__driver_attach+0xc0/0xc4) [<c03b72c4>] (__driver_attach) from [<c03b5440>] (bus_for_each_dev+0x68/0x9c) [<c03b5440>] (bus_for_each_dev) from [<c03b65b8>] (bus_add_driver+0x1a0/0x218) [<c03b65b8>] (bus_add_driver) from [<c03b79cc>] (driver_register+0x78/0xf8) [<c03b79cc>] (driver_register) from [<c01018f4>] (do_one_initcall+0x90/0x1dc) [<c01018f4>] (do_one_initcall) from [<c0900de4>] (kernel_init_freeable+0x15c/0x1fc) [<c0900de4>] (kernel_init_freeable) from [<c06eed90>] (kernel_init+0x8/0x114) [<c06eed90>] (kernel_init) from [<c0107910>] (ret_from_fork+0x14/0x24) Fixes: baa11ebc0c76 ("net: mvneta: Use the new hwbm framework") Reported-by: Russell King <rmk+kernel@armlinux.org.uk> Cc: <stable@vger.kernel.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/marvell/mvneta_bm.c | 1 + 1 file changed, 1 insertion(+) commit 297f7d2cce6a156c174334ee452f2f7a7ba405ca Author: Baozeng Ding <sploving1@gmail.com> Date: Tue May 24 22:33:24 2016 +0800 tipc: fix potential null pointer dereferences in some compat functions Before calling the nla_parse_nested function, make sure the pointer to the attribute is not null. This patch fixes several potential null pointer dereference vulnerabilities in the tipc netlink functions. Signed-off-by: Baozeng Ding <sploving1@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/netlink_compat.c | 111 ++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 93 insertions(+), 18 deletions(-) commit ec7c7f5cafdaeea509ad4e7e6f71c2312062c4c6 Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Tue May 24 05:25:23 2016 -0400 qed: Reset the enable flag for eth protocol. This patch fixes the coding error in determining the enable flag for the application/protocol. The enable flag should be set for all protocols but the eth. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3851112e4737cd52aaeda0ce8d084be9ee128106 Author: Vidya Sagar Ravipati <vidya@cumulusnetworks.com> Date: Sun May 22 23:59:00 2016 -0700 ethtool: add support for 25G/50G/100G speed modes This patch enhances ethtool link mode bitmap to include 25G/50G/100G speed along with interface modes Signed-off-by: Vidya Sagar Ravipati <vidya@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/ethtool.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit a5a3717a980cfa3c8bf194bf302e55b1ab8d6e50 Merge: c64f976 d3030d1 f7aa23c b01518c 45c0470 Author: Mark Brown <broonie@kernel.org> Date: Wed May 25 19:18:00 2016 +0100 Merge remote-tracking branches 'asoc/fix/ak4642', 'asoc/fix/ep93xx', 'asoc/fix/kirkwood' and 'asoc/fix/twl6040' into asoc-linus commit c64f976208f7f6d16ae0b980f8af42fb18759ace Merge: 2dcd0af 515511a Author: Mark Brown <broonie@kernel.org> Date: Wed May 25 19:18:00 2016 +0100 Merge tag 'asoc-v4.7' into asoc-linus ASoC: Updates for v4.7 The updates this time around are almost all driver code: - Further slow progress on the topology code. - Substantial updates and improvements for the da7219, es8328, fsl-ssi Intel and rcar drivers. # gpg: Signature made Mon 16 May 2016 12:08:43 BST using RSA key ID 5D5487D0 # gpg: Good signature from "Mark Brown <broonie@sirena.org.uk>" # gpg: aka "Mark Brown <broonie@debian.org>" # gpg: aka "Mark Brown <broonie@kernel.org>" # gpg: aka "Mark Brown <broonie@tardis.ed.ac.uk>" # gpg: aka "Mark Brown <broonie@linaro.org>" # gpg: aka "Mark Brown <Mark.Brown@linaro.org>" # gpg: WARNING: This key is not certified with a trusted signature! # gpg: There is no indication that the signature belongs to the owner. # Primary key fingerprint: 3F25 68AA C269 98F9 E813 A1C5 C3F4 36CA 30F5 D8EB # Subkey fingerprint: ADE6 68AA 6757 18B5 9FE2 9FEA 24D6 8B72 5D54 87D0 commit 2d324f59f343967a03eeb2690f0ff178304d0687 Author: Liu Bo <bo.li.liu@oracle.com> Date: Tue May 17 17:21:48 2016 -0700 Btrfs: fix unexpected return value of fiemap btrfs's fiemap is supposed to return 0 on success and return < 0 on error. however, ret becomes 1 after looking up the last file extent: btrfs_lookup_file_extent -> btrfs_search_slot(..., ins_len=0, cow=0) and if the offset is beyond EOF, we'll get 'path' pointed to the place of potentail insertion, and ret == 1. This may confuse applications using ioctl(FIEL_IOC_FIEMAP). Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 1c8b5b6e8b570a8038fa42cf9e7c23782bd4882c Author: Liu Bo <bo.li.liu@oracle.com> Date: Fri May 13 17:06:59 2016 -0700 Btrfs: free sys_array eb as soon as possible While reading sys_chunk_array in superblock, btrfs creates a temporary extent buffer. Since we don't use it after finishing reading sys_chunk_array, we don't need to keep it in memory. Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ecc5fbd5ef472a4c659dc56a5739b3f041c0530c Merge: 1f93d2a 18c5887 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 10:40:15 2016 -0700 Merge tag 'pwm/for-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm Pull pwm updates from Thierry Reding: "This set of changes introduces an atomic API to the PWM subsystem. This is influenced by the DRM atomic API that was introduced a while back, though it is obviously a lot simpler. The fundamental idea remains the same, though: drivers provide a single callback to implement the atomic configuration of a PWM channel. As a side-effect the PWM subsystem gains the ability for initial state retrieval, so that the logical state mirrors that of the hardware. Many use-cases don't care about this, but for others it is essential. These new features require changes in all users, which these patches take care of. The core is transitioned to use the atomic callback if available and provides a fallback mechanism for other drivers. Changes to transition users and drivers to the atomic API are postponed to v4.8" * tag 'pwm/for-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm: (30 commits) pwm: Add information about polarity, duty cycle and period to debugfs pwm: Switch to the atomic API pwm: Update documentation pwm: Add core infrastructure to allow atomic updates pwm: Add hardware readout infrastructure pwm: Move the enabled/disabled info into pwm_state pwm: Introduce the pwm_state concept pwm: Keep PWM state in sync with hardware state ARM: Explicitly apply PWM config extracted from pwm_args drm: i915: Explicitly apply PWM config extracted from pwm_args input: misc: pwm-beeper: Explicitly apply PWM config extracted from pwm_args input: misc: max8997: Explicitly apply PWM config extracted from pwm_args backlight: lm3630a: explicitly apply PWM config extracted from pwm_args backlight: lp855x: Explicitly apply PWM config extracted from pwm_args backlight: lp8788: Explicitly apply PWM config extracted from pwm_args backlight: pwm_bl: Use pwm_get_args() where appropriate fbdev: ssd1307fb: Use pwm_get_args() where appropriate regulator: pwm: Use pwm_get_args() where appropriate leds: pwm: Use pwm_get_args() where appropriate input: misc: max77693: Use pwm_get_args() where appropriate ... commit fb1084e3320555eca0fb86c9eaad5429ee761282 Author: Tom Haynes <thomas.haynes@primarydata.com> Date: Wed May 25 07:31:12 2016 -0700 nfs/flexfiles: Helper function to detect FF_FLAGS_NO_READ_IO The mds can inform the client not to use the IOMODE_RW layout segment for doing READs. I.e., it is basically a IOMODE_WRITE layout segment. It would do this to not interfere with the WRITEs. Signed-off-by: Tom Haynes <loghyr@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.h | 11 ++++++++++- fs/nfs/flexfilelayout/flexfilelayoutdev.c | 6 ++++++ 2 files changed, 16 insertions(+), 1 deletion(-) commit 1f93d2abf488c6a41bdd5e6caf80b559493eea8d Merge: 48dd7ce 540be8b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 10:19:17 2016 -0700 Merge git://www.linux-watchdog.org/linux-watchdog Pull watchdog updates from Wim Van Sebroeck: - add support for Fintek F81865 Super-IO chip - add support for watchdogs (RWDT and SWDT) found on RCar Gen3 based SoCs from Renesas - octeon: Handle the FROZEN hot plug notifier actions - f71808e_wdt fixes and cleanups - some small improvements in code and documentation * git://www.linux-watchdog.org/linux-watchdog: MAINTAINERS: Add file patterns for watchdog device tree bindings Documentation: Add ebc-c384_wdt watchdog-parameters.txt entry watchdog: shwdt: Use setup_timer() watchdog: cpwd: Use setup_timer() arm64: defconfig: enable Renesas Watchdog Timer watchdog: renesas-wdt: add driver watchdog: remove error message when unable to allocate watchdog device watchdog: f71808e_wdt: Fix WDTMOUT_STS register read watchdog: f71808e_wdt: Fix typo watchdog: f71808e_wdt: Add F81865 support watchdog: sp5100_tco: properly check for new register layouts watchdog: core: Fix circular locking dependency watchdog: core: fix trivial typo in a comment watchdog: hpwdt: Adjust documentation to match latest kernel module parameters. watchdog: imx2_wdt: add external reset support via dt prop watchdog: octeon: Handle the FROZEN hot plug notifier actions. watchdog: qcom: Report reboot reason commit ade8febde0271513360bac44883dbebad44276c3 Author: Weston Andros Adamson <dros@monkey.org> Date: Wed May 25 10:07:23 2016 -0400 nfs: avoid race that crashes nfs_init_commit Since the patch "NFS: Allow multiple commit requests in flight per file" we can run multiple simultaneous commits on the same inode. This introduced a race over collecting pages to commit that made it possible to call nfs_init_commit() with an empty list - which causes crashes like the one below. The fix is to catch this race and avoid calling nfs_init_commit and initiate_commit when there is no work to do. Here is the crash: [600522.076832] BUG: unable to handle kernel NULL pointer dereference at 0000000000000040 [600522.078475] IP: [<ffffffffa0479e72>] nfs_init_commit+0x22/0x130 [nfs] [600522.078745] PGD 4272b1067 PUD 4272cb067 PMD 0 [600522.078972] Oops: 0000 [#1] SMP [600522.079204] Modules linked in: nfsv3 nfs_layout_flexfiles rpcsec_gss_krb5 nfsv4 dns_resolver nfs fscache dcdbas ip6t_rpfilter ip6t_REJECT nf_reject_ipv6 xt_conntrack ebtable_nat ebtable_broute bridge stp llc ebtable_filter ebtables ip6table_nat nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv6 ip6table_mangle ip6table_security ip6table_raw ip6table_filter ip6_tables iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack iptable_mangle iptable_security iptable_raw vmw_vsock_vmci_transport vsock bonding ipmi_devintf ipmi_msghandler coretemp crct10dif_pclmul crc32_pclmul ghash_clmulni_intel ppdev vmw_balloon parport_pc parport acpi_cpufreq vmw_vmci i2c_piix4 shpchp nfsd auth_rpcgss nfs_acl lockd grace sunrpc xfs libcrc32c vmwgfx drm_kms_helper ttm drm crc32c_intel serio_raw vmxnet3 [600522.081380] vmw_pvscsi ata_generic pata_acpi [600522.081809] CPU: 3 PID: 15667 Comm: /usr/bin/python Not tainted 4.1.9-100.pd.88.el7.x86_64 #1 [600522.082281] Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 09/30/2014 [600522.082814] task: ffff8800bbbfa780 ti: ffff88042ae84000 task.ti: ffff88042ae84000 [600522.083378] RIP: 0010:[<ffffffffa0479e72>] [<ffffffffa0479e72>] nfs_init_commit+0x22/0x130 [nfs] [600522.083973] RSP: 0018:ffff88042ae87438 EFLAGS: 00010246 [600522.084571] RAX: 0000000000000000 RBX: ffff880003485e40 RCX: ffff88042ae87588 [600522.085188] RDX: 0000000000000000 RSI: ffff88042ae874b0 RDI: ffff880003485e40 [600522.085756] RBP: ffff88042ae87448 R08: ffff880003486010 R09: ffff88042ae874b0 [600522.086332] R10: 0000000000000000 R11: 0000000000000005 R12: ffff88042ae872d0 [600522.086905] R13: ffff88042ae874b0 R14: ffff880003485e40 R15: ffff88042704c840 [600522.087484] FS: 00007f4728ff2740(0000) GS:ffff88043fd80000(0000) knlGS:0000000000000000 [600522.088070] CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b [600522.088663] CR2: 0000000000000040 CR3: 000000042b6aa000 CR4: 00000000001406e0 [600522.089327] Stack: [600522.089926] 0000000000000001 ffff88042ae87588 ffff88042ae874f8 ffffffffa04f09fa [600522.090549] 0000000000017840 0000000000017840 ffff88042ae87588 ffff8803258d9930 [600522.091169] ffff88042ae87578 ffffffffa0563d80 0000000000000000 ffff88042704c840 [600522.091789] Call Trace: [600522.092420] [<ffffffffa04f09fa>] pnfs_generic_commit_pagelist+0x1da/0x320 [nfsv4] [600522.093052] [<ffffffffa0563d80>] ? ff_layout_commit_prepare_v3+0x30/0x30 [nfs_layout_flexfiles] [600522.093696] [<ffffffffa0562645>] ff_layout_commit_pagelist+0x15/0x20 [nfs_layout_flexfiles] [600522.094359] [<ffffffffa047bc78>] nfs_generic_commit_list+0xe8/0x120 [nfs] [600522.095032] [<ffffffffa047bd6a>] nfs_commit_inode+0xba/0x110 [nfs] [600522.095719] [<ffffffffa046ac54>] nfs_release_page+0x44/0xd0 [nfs] [600522.096410] [<ffffffff811a8122>] try_to_release_page+0x32/0x50 [600522.097109] [<ffffffff811bd4f1>] shrink_page_list+0x961/0xb30 [600522.097812] [<ffffffff811bdced>] shrink_inactive_list+0x1cd/0x550 [600522.098530] [<ffffffff811bea65>] shrink_lruvec+0x635/0x840 [600522.099250] [<ffffffff811bed60>] shrink_zone+0xf0/0x2f0 [600522.099974] [<ffffffff811bf312>] do_try_to_free_pages+0x192/0x470 [600522.100709] [<ffffffff811bf6ca>] try_to_free_pages+0xda/0x170 [600522.101464] [<ffffffff811b2198>] __alloc_pages_nodemask+0x588/0x970 [600522.102235] [<ffffffff811fbbd5>] alloc_pages_vma+0xb5/0x230 [600522.103000] [<ffffffff813a1589>] ? cpumask_any_but+0x39/0x50 [600522.103774] [<ffffffff811d6115>] wp_page_copy.isra.55+0x95/0x490 [600522.104558] [<ffffffff810e3438>] ? __wake_up+0x48/0x60 [600522.105357] [<ffffffff811d7d3b>] do_wp_page+0xab/0x4f0 [600522.106137] [<ffffffff810a1bbb>] ? release_task+0x36b/0x470 [600522.106902] [<ffffffff8126dbd7>] ? eventfd_ctx_read+0x67/0x1c0 [600522.107659] [<ffffffff811da2a8>] handle_mm_fault+0xc78/0x1900 [600522.108431] [<ffffffff81067ef1>] __do_page_fault+0x181/0x420 [600522.109173] [<ffffffff811446a6>] ? __audit_syscall_exit+0x1e6/0x280 [600522.109893] [<ffffffff810681c0>] do_page_fault+0x30/0x80 [600522.110594] [<ffffffff81024f36>] ? syscall_trace_leave+0xc6/0x120 [600522.111288] [<ffffffff81790a58>] page_fault+0x28/0x30 [600522.111947] Code: 5d c3 0f 1f 80 00 00 00 00 0f 1f 44 00 00 55 4c 8d 87 d0 01 00 00 48 89 e5 53 48 89 fb 48 83 ec 08 4c 8b 0e 49 8b 41 18 4c 39 ce <48> 8b 40 40 4c 8b 50 30 74 24 48 8b 87 d0 01 00 00 48 8b 7e 08 [600522.113343] RIP [<ffffffffa0479e72>] nfs_init_commit+0x22/0x130 [nfs] [600522.114003] RSP <ffff88042ae87438> [600522.114636] CR2: 0000000000000040 Fixes: af7cf057 (NFS: Allow multiple commit requests in flight per file) CC: stable@vger.kernel.org Signed-off-by: Weston Andros Adamson <dros@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs_nfs.c | 28 ++++++++++++++++++++++++++++ fs/nfs/write.c | 4 ++++ 2 files changed, 32 insertions(+) commit 48dd7cefa010b704eb2532a2883798fd6d703a0e Merge: b462b37 f705528 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 09:47:26 2016 -0700 Merge tag 'vfio-v4.7-rc1' of git://github.com/awilliam/linux-vfio Pull VFIO updates from Alex Williamson: - Hide INTx on certain known broken devices (Alex Williamson) - Additional backdoor reset detection (Alex Williamson) - Remove unused iommudata reference (Alexey Kardashevskiy) - Use cfg_size to avoid probing extended config space (Alexey Kardashevskiy) * tag 'vfio-v4.7-rc1' of git://github.com/awilliam/linux-vfio: vfio_pci: Test for extended capabilities if config space > 256 bytes vfio_iommu_spapr_tce: Remove unneeded iommu_group_get_iommudata vfio/pci: Add test for BAR restore vfio/pci: Hide broken INTx support from user commit b462b37b08be1b6a4e380d78b978ec1ff84e2783 Merge: 24c82fb 92181d4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 09:37:50 2016 -0700 Merge tag 'drm-4.7-rc1-headers-fix' of git://people.freedesktop.org/~airlied/linux Pull header warning fix from Dave Airlie: "Here is the C++ guards warning fix from Arnd" [ Background: there are 'extern "C" { }' guards in include/uapi for the GPU headers. They should arguably be wrapped somehow, but as it is they caused checkpatch to warn because it would trigger on the 'extern' and think it's exporting a function or variable from the kernel to user space. This just fixes checkpatch. Whether we wrap the C++ guards some way in the future will be an independent issue. ] * tag 'drm-4.7-rc1-headers-fix' of git://people.freedesktop.org/~airlied/linux: headers_check: don't warn about c++ guards commit 24c82fbb86c675bc265d2bd815d17c4861c50580 Merge: 28165ec 784c221 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 25 09:27:52 2016 -0700 Merge branch 'parisc-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux Pull parisc updates from Helge Deller: - Add native high-resolution timing code for sched_clock() and other timing functions based on the processor internal cr16 cycle counters - Add syscall tracepoint support - Add regset support - Speed up get_user() and put_user() functions - Updated futex.h to match generic implementation (John David Anglin) - A few smaller ftrace build fixes - Fixed thuge-gen kernel self test to utilize architectured MAP_HUGETLB value - Added parisc architecture to seccomp_bpf kernel self test - Various typo fixes (Andrea Gelmini) * 'parisc-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux: parisc: Whitespace cleanups in unistd.h parisc: Use long jump to reach ftrace_return_to_handler() parisc: Fix typo in fpudispatch.c parisc: Fix typos in eisa_eeprom.h parisc: Fix typo in ldcw.h parisc: Fix typo in pdc.h parisc: Update futex.h to match generic implementation parisc: Merge ftrace C-helper and assembler functions into .text.hot section selftests/thuge-gen: Use platform specific MAP_HUGETLB value parisc: Add native high-resolution sched_clock() implementation parisc: Add ARCH_TRACEHOOK and regset support parisc: Add 64bit get_user() and put_user() for 32bit kernel parisc: Simplify and speed up get_user() and put_user() parisc: Add syscall tracepoint support commit 2997bfd0492d33d230b1475909a0211157a734bc Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon May 23 13:21:01 2016 +0300 NFS: checking for NULL instead of IS_ERR() in nfs_commit_file() nfs_create_request() doesn't return NULL, it returns error pointers. Fixes: 67911c8f18b5 ('NFS: Add nfs_commit_file()') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/write.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6710e594f71ccaad8101bc64321152af7cd9ea28 Author: Tejun Heo <tj@kernel.org> Date: Wed May 25 11:48:25 2016 -0400 percpu: fix synchronization between synchronous map extension and chunk destruction For non-atomic allocations, pcpu_alloc() can try to extend the area map synchronously after dropping pcpu_lock; however, the extension wasn't synchronized against chunk destruction and the chunk might get freed while extension is in progress. This patch fixes the bug by putting most of non-atomic allocations under pcpu_alloc_mutex to synchronize against pcpu_balance_work which is responsible for async chunk management including destruction. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-and-tested-by: Alexei Starovoitov <alexei.starovoitov@gmail.com> Reported-by: Vlastimil Babka <vbabka@suse.cz> Reported-by: Sasha Levin <sasha.levin@oracle.com> Cc: stable@vger.kernel.org # v3.18+ Fixes: 1a4d76076cda ("percpu: implement asynchronous chunk population") mm/percpu.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 4f996e234dad488e5d9ba0858bc1bae12eff82c3 Author: Tejun Heo <tj@kernel.org> Date: Wed May 25 11:48:25 2016 -0400 percpu: fix synchronization between chunk->map_extend_work and chunk destruction Atomic allocations can trigger async map extensions which is serviced by chunk->map_extend_work. pcpu_balance_work which is responsible for destroying idle chunks wasn't synchronizing properly against chunk->map_extend_work and may end up freeing the chunk while the work item is still in flight. This patch fixes the bug by rolling async map extension operations into pcpu_balance_work. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-and-tested-by: Alexei Starovoitov <alexei.starovoitov@gmail.com> Reported-by: Vlastimil Babka <vbabka@suse.cz> Reported-by: Sasha Levin <sasha.levin@oracle.com> Cc: stable@vger.kernel.org # v3.18+ Fixes: 9c824b6a172c ("percpu: make sure chunk->map array has available space") mm/percpu.c | 57 ++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 36 insertions(+), 21 deletions(-) commit b9d8905e4a751e2cdc0fb474856b7183c594dcc6 Author: Mikulas Patocka <mikulas@twibright.com> Date: Tue May 24 22:51:27 2016 +0200 reiserfs: check kstrdup failure Check out-of-memory failure of the kstrdup option. Note that the argument "arg" may be NULL (in that case kstrup returns NULL), so out of memory condition happened if arg was non-NULL and kstrdup returned NULL. The patch also changes the call to replace_mount_options - if we didn't pass any filesystem-specific options, we don't call replace_mount_options (thus we don't erase existing reported options). Note that to properly report options after remount, the reiserfs filesystem should implement the show_options method. Without the show_options method, options changed with remount replace existing options. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Jan Kara <jack@suse.cz> fs/reiserfs/super.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit fabc712866435660f7fa1070e1fabe29eba5bc4c Author: Janosch Frank <frankja@linux.vnet.ibm.com> Date: Wed May 18 13:26:25 2016 +0200 tools: kvm_stat: Add comments A lot of the code works with the perf events about which only sparse documentation was available until 2012. Having that information now, we can clarify what is done in the code. Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> tools/kvm/kvm_stat/kvm_stat | 161 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 159 insertions(+), 2 deletions(-) commit f0cf040f842242d55744c2606e8b7177507fbbb0 Author: Janosch Frank <frankja@linux.vnet.ibm.com> Date: Wed May 18 13:26:24 2016 +0200 tools: kvm_stat: Introduce pid monitoring Having stats for single VMs can help to determine the problem of a VM without the need of running other tools like perf. The tracepoints already allowed pid level monitoring, but kvm_stat didn't have support for it till now. Support for the newly implemented debugfs vm monitoring was also implemented. Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> tools/kvm/kvm_stat/kvm_stat | 183 +++++++++++++++++++++++++++++++++++----- tools/kvm/kvm_stat/kvm_stat.txt | 6 +- 2 files changed, 167 insertions(+), 22 deletions(-) commit 536a6f88c49dd739961ffd53774775afed852c83 Author: Janosch Frank <frankja@linux.vnet.ibm.com> Date: Wed May 18 13:26:23 2016 +0200 KVM: Create debugfs dir and stat files for each VM This patch adds a kvm debugfs subdirectory for each VM, which is named after its pid and file descriptor. The directories contain the same kind of files that are already in the kvm debugfs directory, but the data exported through them is now VM specific. This makes the debugfs kvm data a convenient alternative to the tracepoints which already have per VM data. The debugfs data is easy to read and low overhead. CC: Dan Carpenter <dan.carpenter@oracle.com> [includes fixes by Dan Carpenter] Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> include/linux/kvm_host.h | 7 ++ virt/kvm/kvm_main.c | 187 ++++++++++++++++++++++++++++++++++++++++++++--- 2 files changed, 184 insertions(+), 10 deletions(-) commit 6d0a1a61e7b2eb21415aea7e3c5df7c6e456f33a Author: Janosch Frank <frankja@linux.vnet.ibm.com> Date: Wed May 18 13:26:22 2016 +0200 MAINTAINERS: Add kvm tools The new kvm subdirectory in tools contains kvm related scripts. Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit c7d4fb5a6ebea2d3e8b3a1c251cc30bc56319897 Author: Hemant Kumar <hemant@linux.vnet.ibm.com> Date: Tue Apr 19 08:54:54 2016 +0530 tools: kvm_stat: Powerpc related fixes kvm_stat script is failing to execute on powerpc : # ./kvm_stat Traceback (most recent call last): File "./kvm_stat", line 825, in <module> main() File "./kvm_stat", line 813, in main providers = get_providers(options) File "./kvm_stat", line 778, in get_providers providers.append(TracepointProvider()) File "./kvm_stat", line 416, in __init__ self.filters = get_filters() File "./kvm_stat", line 315, in get_filters if ARCH.exit_reasons: AttributeError: 'ArchPPC' object has no attribute 'exit_reasons' This is because, its trying to access a non-defined attribute. Also, the IOCTL number of RESET is incorrect for powerpc. The correct number has been added. Signed-off-by: Hemant Kumar <hemant@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> tools/kvm/kvm_stat/kvm_stat | 2 ++ 1 file changed, 2 insertions(+) commit fd41b5a96948f67785458c04e9ddb5ef619251d5 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Tue May 24 10:41:15 2016 +0200 tools: Add kvm_stat man page Converted from the Texinfo source in QEMU to asciidoc. The a2x incantation was provided by Janosch Frank. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> tools/kvm/kvm_stat/Makefile | 40 +++++++++++++++++++++++++-- tools/kvm/kvm_stat/kvm_stat.txt | 61 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 99 insertions(+), 2 deletions(-) commit f9bc9e65fbec1781f64effc6bcc3b6edc57f8d19 Author: Janosch Frank <frankja@linux.vnet.ibm.com> Date: Wed May 18 13:26:21 2016 +0200 tools: Add kvm_stat vm monitor script This tool displays kvm vm exit statistics to ease vm monitoring. It takes its data from the kvm debugfs files or the vm tracepoints and outputs them as a curses ui or simple text. It was moved from qemu, as it is dependent on the kernel whereas qemu works with a large number of kernel versions, some of which may break the script. Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> tools/Makefile | 6 +- tools/kvm/kvm_stat/Makefile | 5 + tools/kvm/kvm_stat/kvm_stat | 825 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 835 insertions(+), 1 deletion(-) commit 3ce424e45411cf5a13105e0386b6ecf6eeb4f66f Author: Roman Kagan <rkagan@virtuozzo.com> Date: Wed May 18 17:48:20 2016 +0300 kvm:vmx: more complete state update on APICv on/off The function to update APICv on/off state (in particular, to deactivate it when enabling Hyper-V SynIC) is incomplete: it doesn't adjust APICv-related fields among secondary processor-based VM-execution controls. As a result, Windows 2012 guests get stuck when SynIC-based auto-EOI interrupt intersected with e.g. an IPI in the guest. In addition, the MSR intercept bitmap isn't updated every time "virtualize x2APIC mode" is toggled. This path can only be triggered by a malicious guest, because Windows didn't use x2APIC but rather their own synthetic APIC access MSRs; however a guest running in a SynIC-enabled VM could switch to x2APIC and thus obtain direct access to host APIC MSRs (CVE-2016-4440). The patch fixes those omissions. Signed-off-by: Roman Kagan <rkagan@virtuozzo.com> Reported-by: Steve Rutherford <srutherford@google.com> Reported-by: Yang Zhang <yang.zhang.wz@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/vmx.c | 48 ++++++++++++++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 18 deletions(-) commit 425c452b547622fb728c9ed4fe99c3f2f51d816d Author: Jeff Mahoney <jeffm@suse.com> Date: Tue May 24 13:47:44 2016 -0400 drm/amd: add Kconfig dependency for ACP on DRM_AMDGPU The DRM_AMD_ACP option doesn't have any dependencies and selects MFD_CORE, which results in MFD_CORE=y. Since the code is only called from DRM_AMDGPU, it should depend on it. Adding the dependency results in MFD_CORE being selected as a module again if amdgpu is also a module. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/acp/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 9d746ab68163d642dae13756b2b3145b2e38cb65 Author: Mario Kleiner <mario.kleiner.de@gmail.com> Date: Tue May 24 18:12:43 2016 +0200 drm/amdgpu: Fix hdmi deep color support. When porting the hdmi deep color detection code from radeon-kms to amdgpu-kms apparently some kind of copy and paste error happened, attaching an else branch to the wrong if statement. The result is that hdmi deep color mode is always disabled, regardless of gpu and display capabilities and user wishes, as the code mistakenly thinks that the display doesn't provide the required max_tmds_clock limit and falls back to 8 bpc. This patch fixes deep color support, as tested on a R9 380 Tonga Pro + suitable display, and should be backported to all kernels with amdgpu-kms support. Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com> Cc: stable@vger.kernel.org Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_connectors.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 48c60c03bcac36bb443f771b5e221a47d501b2ad Author: Monk Liu <Monk.Liu@amd.com> Date: Wed May 18 16:15:47 2016 +0800 drm/amdgpu: fix bug in fence driver fini Using wrong counter for walking fences. Fixes a crash when unloading the driver. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 784c2213e79c094ffd9c1118722ac9ee5fce5e77 Author: Helge Deller <deller@gmx.de> Date: Wed May 25 15:40:49 2016 +0200 parisc: Whitespace cleanups in unistd.h Clean up whitespaces and mark unused syscalls as such. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/uapi/asm/unistd.h | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) commit ab6a11a7c8ef47f996974dd3c648c2c0b1a36ab1 Author: Tom Lendacky <thomas.lendacky@amd.com> Date: Fri May 20 17:33:03 2016 -0500 crypto: ccp - Fix AES XTS error for request sizes above 4096 The ccp-crypto module for AES XTS support has a bug that can allow requests greater than 4096 bytes in size to be passed to the CCP hardware. The CCP hardware does not support request sizes larger than 4096, resulting in incorrect output. The request should actually be handled by the fallback mechanism instantiated by the ccp-crypto module. Add a check to insure the request size is less than or equal to the maximum supported size and use the fallback mechanism if it is not. Cc: <stable@vger.kernel.org> # 3.14.x- Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/ccp/ccp-crypto-aes-xts.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit dc3ee32e96d74dd6c80eed63af5065cb75899299 Author: Eric W. Biederman <ebiederm@xmission.com> Date: Fri May 13 21:18:52 2016 -0500 netfilter: nf_queue: Make the queue_handler pernet Florian Weber reported: > Under full load (unshare() in loop -> OOM conditions) we can > get kernel panic: > > BUG: unable to handle kernel NULL pointer dereference at 0000000000000008 > IP: [<ffffffff81476c85>] nfqnl_nf_hook_drop+0x35/0x70 > [..] > task: ffff88012dfa3840 ti: ffff88012dffc000 task.ti: ffff88012dffc000 > RIP: 0010:[<ffffffff81476c85>] [<ffffffff81476c85>] nfqnl_nf_hook_drop+0x35/0x70 > RSP: 0000:ffff88012dfffd80 EFLAGS: 00010206 > RAX: 0000000000000008 RBX: ffffffff81add0c0 RCX: ffff88013fd80000 > [..] > Call Trace: > [<ffffffff81474d98>] nf_queue_nf_hook_drop+0x18/0x20 > [<ffffffff814738eb>] nf_unregister_net_hook+0xdb/0x150 > [<ffffffff8147398f>] netfilter_net_exit+0x2f/0x60 > [<ffffffff8141b088>] ops_exit_list.isra.4+0x38/0x60 > [<ffffffff8141b652>] setup_net+0xc2/0x120 > [<ffffffff8141bd09>] copy_net_ns+0x79/0x120 > [<ffffffff8106965b>] create_new_namespaces+0x11b/0x1e0 > [<ffffffff810698a7>] unshare_nsproxy_namespaces+0x57/0xa0 > [<ffffffff8104baa2>] SyS_unshare+0x1b2/0x340 > [<ffffffff81608276>] entry_SYSCALL_64_fastpath+0x1e/0xa8 > Code: 65 00 48 89 e5 41 56 41 55 41 54 53 83 e8 01 48 8b 97 70 12 00 00 48 98 49 89 f4 4c 8b 74 c2 18 4d 8d 6e 08 49 81 c6 88 00 00 00 <49> 8b 5d 00 48 85 db 74 1a 48 89 df 4c 89 e2 48 c7 c6 90 68 47 > The simple fix for this requires a new pernet variable for struct nf_queue that indicates when it is safe to use the dynamically allocated nf_queue state. As we need a variable anyway make nf_register_queue_handler and nf_unregister_queue_handler pernet. This allows the existing logic of when it is safe to use the state from the nfnetlink_queue module to be reused with no changes except for making it per net. The syncrhonize_rcu from nf_unregister_queue_handler is moved to a new function nfnl_queue_net_exit_batch so that the worst case of having a syncrhonize_rcu in the pernet exit path is not experienced in batch mode. Reported-by: Florian Westphal <fw@strlen.de> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Acked-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_queue.h | 4 ++-- include/net/netns/netfilter.h | 2 ++ net/netfilter/nf_queue.c | 17 ++++++++--------- net/netfilter/nfnetlink_queue.c | 18 ++++++++++++------ 4 files changed, 24 insertions(+), 17 deletions(-) commit 720b287d8382616a29524dd98264ac1e3a069e9f Author: Florian Westphal <fw@strlen.de> Date: Fri May 13 22:48:51 2016 +0200 netfilter: conntrack: remove leftover binary sysctl define Users got removed in f8572d8f2a2ba ("sysctl net: Remove unused binary sysctl code"). Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_standalone.c | 2 -- 1 file changed, 2 deletions(-) commit 275ae411e56f8f900fa364da29c4706f9af4e1f3 Author: Vincent Stehlé <vincent.stehle@intel.com> Date: Tue May 24 16:53:49 2016 +0200 perf/x86/intel/rapl: Fix pmus free during cleanup On rapl cleanup path, kfree() is given by mistake the address of the pointer of the structure to free (rapl_pmus->pmus + i). Pass the pointer instead (rapl_pmus->pmus[i]). Fixes: 9de8d686955b "perf/x86/intel/rapl: Convert it to a per package facility" Signed-off-by: Vincent Stehlé <vincent.stehle@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/1464101629-14905-1-git-send-email-vincent.stehle@intel.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> arch/x86/events/intel/rapl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b7e7ade34e6188bee2e3b0d42b51d25137d9e2a5 Author: Peter Zijlstra <peterz@infradead.org> Date: Mon May 23 11:19:07 2016 +0200 sched/core: Fix remote wakeups Commit: b5179ac70de8 ("sched/fair: Prepare to fix fairness problems on migration") ... introduced a bug: Mike Galbraith found that it introduced a performance regression, while Paul E. McKenney reported lost wakeups and bisected it to this commit. The reason is that I mis-read ttwu_queue() such that I assumed any wakeup that got a remote queue must have had the task migrated. Since this is not so; we need to transfer this information between queueing the wakeup and actually doing the wakeup. Use a new task_struct::sched_flag for this, we already write to sched_contributes_to_load in the wakeup path so this is a hot and modified cacheline. Reported-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reported-by: Mike Galbraith <umgwanakikbuti@gmail.com> Tested-by: Mike Galbraith <umgwanakikbuti@gmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Hunter <ahh@google.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ben Segall <bsegall@google.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Paul Turner <pjt@google.com> Cc: Pavan Kondeti <pkondeti@codeaurora.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Quentin Casasnovas <quentin.casasnovas@oracle.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: byungchul.park@lge.com Fixes: b5179ac70de8 ("sched/fair: Prepare to fix fairness problems on migration") Link: http://lkml.kernel.org/r/20160523091907.GD15728@worktop.ger.corp.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 1 + kernel/sched/core.c | 18 +++++++++++------- 2 files changed, 12 insertions(+), 7 deletions(-) commit 86c72d1ce91d804e4fa8d90b316a89597dd220f1 Author: Hui Wang <hui.wang@canonical.com> Date: Wed May 25 12:12:32 2016 +0800 ALSA: hda - Fix headset mic detection problem for one Dell machine Add the pin configuration value of this machine into the pin_quirk table to make DELL1_MIC_NO_PRESENCE apply to this machine. Cc: <stable@vger.kernel.org> Signed-off-by: Hui Wang <hui.wang@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 3 +++ 1 file changed, 3 insertions(+) commit e411295e3ec0b470795a860ec3cc51edf64407c4 Merge: 92181d4 310944d Author: Dave Airlie <airlied@redhat.com> Date: Wed May 25 12:36:20 2016 +1000 Merge tag 'imx-drm-fixes-2016-05-24' of git://git.pengutronix.de/git/pza/linux into drm-next imx-drm probing fix Commit 950b410dd1ab ("gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading") broke probing of the imx-drm driver in the non-modular case because the unset dev->of_node during probing of imx-ipuv3-crtc would cause the component matching to fail. This patch patch instead matches against an of_node pointer stored in platform data, allowing dev->of_node to be left unset for the platform probed imx-ipuv3-crtc devices. * tag 'imx-drm-fixes-2016-05-24' of git://git.pengutronix.de/git/pza/linux: drm/imx: Match imx-ipuv3-crtc components using device node in platform data commit 3d3ed18151172c845a11b7c184f2120220ae19fc Author: Jamal Hadi Salim <jhs@mojatatu.com> Date: Mon May 23 21:07:20 2016 -0400 net sched actions: policer missing timestamp processing Policer was not dumping or updating timestamps Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com> Acked-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/pkt_cls.h | 4 +++- net/sched/act_police.c | 11 +++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) commit 28165ec7a99be98123aa89540bf2cfc24df19498 Merge: 08344f3 09564b7 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 15:50:58 2016 -0700 Merge tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC fixes from Arnd Bergmann: "This is a first set of bug fixes on top of what was merged for 4.7. Two patches for lpc32xx address a harmless build warning that was just introduced, one patch for the mediatek soc driver fixes a warning for arm64, and the pxa changes are minor cleanups that should have been part of the original pull requests but that I forgot to apply to the cleanup-fixes branch earlier" * tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: ARM: lpc32xx: fix NR_IRQS confict ARM: lpc32xx: remove legacy irq controller driver soc: mtk-pmic-wrap: avoid integer overflow warning ARM: pxa: Remove CLK_IS_ROOT ARM: pxa: activate pinctrl for device-tree machines commit 08344f3b43a6bfaf2926122cef44d9a9583c2a4e Merge: d04f90f 88f1847 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 15:46:06 2016 -0700 Merge tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC late DT updates from Arnd Bergmann: "This is a collection of a few late fixes and other misc stuff that had dependencies on things being merged from other trees. The Renesas R-Car power domain handling, and the Nvidia Tegra USB support both hand notable changes that required changing the DT binding in a way that only provides compatibility with old DT blobs on new kernels but not vice versa. As a consequence, the DT changes are based on top of the driver changes and are now in this branch. For NXP i.MX and Samsung Exynos, the changes in here depend on other changes that got merged through the clk maintainer tree" * tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (35 commits) ARM: dts: exynos: Add support of Bus frequency using VDD_INT for exynos5422-odroidxu3 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos542x SoC ARM: dts: exynos: Add NoC Probe dt node for Exynos542x SoC ARM: dts: exynos: Add support of bus frequency for exynos4412-trats/odroidu3 ARM: dts: exynos: Expand the voltage range of buck1/3 regulator for exynos4412-odroidu3 ARM: dts: exynos: Add support of bus frequency using VDD_INT for exynos3250-rinato ARM: dts: exynos: Add exynos4412-ppmu-common dtsi to delete duplicate PPMU nodes ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4210 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos4x12 ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4x12 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos3250 ARM: dts: exynos: Add DMC bus frequency for exynos3250-rinato/monk ARM: dts: exynos: Add DMC bus node for Exynos3250 ARM: tegra: Enable XUSB on Nyan ARM: tegra: Enable XUSB on Jetson TK1 ARM: tegra: Enable XUSB on Venice2 ARM: tegra: Add Tegra124 XUSB controller ARM: tegra: Move Tegra124 to the new XUSB pad controller binding ARM: dts: r8a7794: Use SYSC "always-on" PM Domain ARM: dts: r8a7793: Use SYSC "always-on" PM Domain ... commit d04f90ffecb7f6d7358197d7544f5536b6d4d8cc Merge: 5d22c5a b0da6d4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 15:24:37 2016 -0700 Merge tag 'asm-generic-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic Pull asm-generic cleanup from Arnd Bergmann: "I have only one patch for asm-generic in this release, this one is from James Hogan and updates the generic system call table for renameat2 so we don't need to provide both renameat and renameat2 in newly added architectures" * tag 'asm-generic-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic: asm-generic: Drop renameat syscall from default list commit a9efad8b24bd22616f6c749a6c029957dc76542b Author: Eric Dumazet <edumazet@google.com> Date: Mon May 23 14:24:56 2016 -0700 net_sched: avoid too many hrtimer_start() calls I found a serious performance bug in packet schedulers using hrtimers. sch_htb and sch_fq are definitely impacted by this problem. We constantly rearm high resolution timers if some packets are throttled in one (or more) class, and other packets are flying through qdisc on another (non throttled) class. hrtimer_start() does not have the mod_timer() trick of doing nothing if expires value does not change : if (timer_pending(timer) && timer->expires == expires) return 1; This issue is particularly visible when multiple cpus can queue/dequeue packets on the same qdisc, as hrtimer code has to lock a remote base. I used following fix : 1) Change htb to use qdisc_watchdog_schedule_ns() instead of open-coding it. 2) Cache watchdog prior expiration. hrtimer might provide this, but I prefer to not rely on some hrtimer internal. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/pkt_sched.h | 1 + net/sched/sch_api.c | 4 ++++ net/sched/sch_htb.c | 13 +++---------- 3 files changed, 8 insertions(+), 10 deletions(-) commit 3275c0c6c522ab04afa14f80efdac6213c3883d6 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Mon May 23 11:58:28 2016 +1000 net/qlge: Avoids recursive EEH error One timer, whose handler keeps reading on MMIO register for EEH core to detect error in time, is started when the PCI device driver is loaded. MMIO register can't be accessed during PE reset in EEH recovery. Otherwise, the unexpected recursive error is triggered. The timer isn't closed that time if the interface isn't brought up. So the unexpected recursive error is seen during EEH recovery when the interface is down. This avoids the unexpected recursive EEH error by closing the timer in qlge_io_error_detected() before EEH PE reset unconditionally. The timer is started unconditionally after EEH PE reset in qlge_io_resume(). Also, the timer should be closed unconditionally when the device is removed from the system permanently in qlge_io_error_detected(). Reported-by: Shriya R. Kulkarni <shriyakul@in.ibm.com> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qlge/qlge_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5d22c5ab85e4de3c14d9e79eefc2835f4a8f9b2a Merge: 0e01df1 c0cb8bf Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 14:39:20 2016 -0700 Merge tag 'nfsd-4.7' of git://linux-nfs.org/~bfields/linux Pull nfsd updates from Bruce Fields: "A very quiet cycle for nfsd, mainly just an RDMA update from Chuck Lever" * tag 'nfsd-4.7' of git://linux-nfs.org/~bfields/linux: sunrpc: fix stripping of padded MIC tokens svcrpc: autoload rdma module svcrdma: Generalize svc_rdma_xdr_decode_req() svcrdma: Eliminate code duplication in svc_rdma_recvfrom() svcrdma: Drain QP before freeing svcrdma_xprt svcrdma: Post Receives only for forward channel requests svcrdma: Remove superfluous line from rdma_read_chunks() svcrdma: svc_rdma_put_context() is invoked twice in Send error path svcrdma: Do not add XDR padding to xdr_buf page vector svcrdma: Support IPv6 with NFS/RDMA nfsd: handle seqid wraparound in nfsd4_preprocess_layout_stateid Remove unnecessary allocation commit 252f3f5a1189a7f6c309d8e4ff1c4c1888a27f13 Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Sat May 21 18:17:35 2016 +0800 ip6_gre: Set flowi6_proto as IPPROTO_GRE in xmit path. In gre6 xmit path, we are sending a GRE packet, so set fl6 proto to IPPROTO_GRE properly. Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 1 + 1 file changed, 1 insertion(+) commit 1b227e536662eae4b7beee3037edbecdc577495f Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Sat May 21 18:17:34 2016 +0800 ip6_gre: Fix MTU setting for ip6gretap When creat an ip6gretap interface with an unreachable route, the MTU is about 14 bytes larger than what was needed. If the remote address is reachable: ping6 2001:0:130::1 -c 2 PING 2001:0:130::1(2001:0:130::1) 56 data bytes 64 bytes from 2001:0:130::1: icmp_seq=1 ttl=64 time=1.46 ms 64 bytes from 2001:0:130::1: icmp_seq=2 ttl=64 time=81.1 ms Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 2 ++ 1 file changed, 2 insertions(+) commit 0e01df100b6bf22a1de61b66657502a6454153c5 Merge: a56f489 12735f8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 12:55:26 2016 -0700 Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 Pull ext4 updates from Ted Ts'o: "Fix a number of bugs, most notably a potential stale data exposure after a crash and a potential BUG_ON crash if a file has the data journalling flag enabled while it has dirty delayed allocation blocks that haven't been written yet. Also fix a potential crash in the new project quota code and a maliciously corrupted file system. In addition, fix some DAX-specific bugs, including when there is a transient ENOSPC situation and races between writes via direct I/O and an mmap'ed segment that could lead to lost I/O. Finally the usual set of miscellaneous cleanups" * tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (23 commits) ext4: pre-zero allocated blocks for DAX IO ext4: refactor direct IO code ext4: fix race in transient ENOSPC detection ext4: handle transient ENOSPC properly for DAX dax: call get_blocks() with create == 1 for write faults to unwritten extents ext4: remove unmeetable inconsisteny check from ext4_find_extent() jbd2: remove excess descriptions for handle_s ext4: remove unnecessary bio get/put ext4: silence UBSAN in ext4_mb_init() ext4: address UBSAN warning in mb_find_order_for_block() ext4: fix oops on corrupted filesystem ext4: fix check of dqget() return value in ext4_ioctl_setproject() ext4: clean up error handling when orphan list is corrupted ext4: fix hang when processing corrupted orphaned inode list ext4: remove trailing \n from ext4_warning/ext4_error calls ext4: fix races between changing inode journal mode and ext4_writepages ext4: handle unwritten or delalloc buffers before enabling data journaling ext4: fix jbd2 handle extension in ext4_ext_truncate_extend_restart() ext4: do not ask jbd2 to write data for delalloc buffers jbd2: add support for avoiding data writes during transaction commits ... commit 09564b7d84d753e4aa1198017b5a5e86c7b0539f Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 19 10:31:31 2016 +0200 ARM: lpc32xx: fix NR_IRQS confict With the change to sparse IRQs, the lpc32xx platform gets a warning about conflicting macros: In file included from arch/arm/mach-lpc32xx/irq.c:31:0: arch/arm/mach-lpc32xx/include/mach/irqs.h:115:0: warning: "NR_IRQS" redefined #define NR_IRQS 96 arch/arm/include/asm/irq.h:9:0: note: this is the location of the previous definition #define NR_IRQS NR_IRQS_LEGACY One such instance was in the old irq driver that is now removed by the previous patch, but any other file including mach/irqs.h still has the issue. Since none of them use this constant, we can just remove the old definition. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 8cb17b5ed017 ("irqchip: Add LPC32xx interrupt controller driver") arch/arm/mach-lpc32xx/include/mach/irqs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 342f3f9bf6fc2af67f00a07703053e2b1f882afd Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 25 04:00:44 2016 +0300 ARM: lpc32xx: remove legacy irq controller driver New NXP LPC32xx irq chip driver is used instead of a legacy one. [this also fixes a harmless build warning about the NR_IRQS redefinition] Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/mach-lpc32xx/Makefile | 2 +- arch/arm/mach-lpc32xx/irq.c | 477 ----------------------------------------- 2 files changed, 1 insertion(+), 478 deletions(-) commit ae43f8286730d1f2d241c34601df59f6d2286ac4 Author: Mark Bloch <markb@mellanox.com> Date: Thu May 19 17:12:36 2016 +0300 IB/core: Add IP to GID netlink offload There is an assumption that rdmacm is used only between nodes in the same IB subnet, this why ARP resolution can be used to turn IP to GID in rdmacm. When dealing with IB communication between subnets this assumption is no longer valid. ARP resolution will get us the next hop device address and not the peer node's device address. To solve this issue, we will check user space if it can provide the GID of the peer node, and fail if not. We add a sequence number to identify each request and fill in the GID upon answer from userspace. Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/addr.c | 217 ++++++++++++++++++++++++++++++++---- drivers/infiniband/core/core_priv.h | 2 + drivers/infiniband/core/device.c | 3 + 3 files changed, 198 insertions(+), 24 deletions(-) commit 735c631ae99d4b6cffc9e2774258329c526daa65 Author: Mark Bloch <markb@mellanox.com> Date: Thu May 19 17:12:35 2016 +0300 IB/core: Register SA ibnl client during ib_core initialization Move SA ibnl client registration to ib_core module init. This will allow us to register a single client to handle all RDMA_NL_LS operations and make it SA independent. Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/core_priv.h | 5 +++++ drivers/infiniband/core/device.c | 28 ++++++++++++++++++++++++++++ drivers/infiniband/core/sa_query.c | 27 +++++---------------------- 3 files changed, 38 insertions(+), 22 deletions(-) commit c34d3761872a2784d7bae2a0bb6205e8ee07a7f7 Author: Mark Bloch <markb@mellanox.com> Date: Thu May 19 17:12:34 2016 +0300 IB/netlink: Add a new local service operation This commits adds a new RDMA local service operation: - IP to GID resolution. The client request would include the ifindex of the outgoing interface and would place in an attribute (LS_NLA_TYPE_IPV4 or LS_NLA_TYPE_IPV6) the destnation IP. The local service would answer with a message that has the attribute: - LS_NLA_TYPE_DGID - The destination GID. Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/uapi/rdma/rdma_netlink.h | 10 ++++++++++ 1 file changed, 10 insertions(+) commit c2e49c92326f9baaa490492c48bea5a7f49d3244 Author: Mark Bloch <markb@mellanox.com> Date: Thu May 19 17:12:33 2016 +0300 IB/SA: Integrate ib_sa module into ib_core module Consolidate ib_sa into ib_core, this commit eliminates ib_sa.ko and makes it part of ib_core.ko Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/Makefile | 9 +++------ drivers/infiniband/core/core_priv.h | 3 +++ drivers/infiniband/core/device.c | 9 +++++++++ drivers/infiniband/core/sa_query.c | 11 ++--------- 4 files changed, 17 insertions(+), 15 deletions(-) commit 4c2cb4220431cbf92233dc12733ee8962abb9081 Author: Mark Bloch <markb@mellanox.com> Date: Thu May 19 17:12:32 2016 +0300 IB/MAD: Integrate ib_mad module into ib_core module Consolidate ib_mad into ib_core, this commit eliminates ib_mad.ko and makes it part of ib_core.ko Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/Makefile | 7 +++---- drivers/infiniband/core/core_priv.h | 3 +++ drivers/infiniband/core/device.c | 9 +++++++++ drivers/infiniband/core/mad.c | 13 +++---------- 4 files changed, 18 insertions(+), 14 deletions(-) commit e3f20f02864f6da1509c523bfa1e928619e59095 Author: Leon Romanovsky <leonro@mellanox.com> Date: Thu May 19 17:12:31 2016 +0300 IB/core: Integrate IB address resolution module into core IB address resolution is declared as a module (ib_addr.ko) which loads itself before IB core module (ib_core.ko). It causes to the scenario where IB netlink which is initialized by IB core can't be used by ib_addr.ko. In order to solve it, we are converting ib_addr.ko to be part of IB core module. Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Signed-off-by: Mark Bloch <markb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/Makefile | 6 ++---- drivers/infiniband/core/addr.c | 11 ++--------- drivers/infiniband/core/core_priv.h | 3 +++ drivers/infiniband/core/device.c | 9 +++++++++ 4 files changed, 16 insertions(+), 13 deletions(-) commit a56f489502e28caac56c8a0735549740f0ae0711 Merge: 8bc4d5f c4e85b7 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 11:12:32 2016 -0700 Merge tag 'spi-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi Pull spi updates from Mark Brown: "Another quiet release for SPI, almost entirely driver specific changes with the diffstat dominated by two new drivers which are about two thirds of it in terms of lines of code: - new drivers for PIC32 standard and SQI controllers - the Cadence driver has had runtime PM support added and quite a few fixes and cleanups - flash-specific accelerated path support now has a feature query interface - the pxa2xx driver has been moved to use the core DMA mapping support" * tag 'spi-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: (48 commits) spi: pic32-sqi: Fix linker error, undefined reference to `bad_dma_ops' spi: dw-pci: Spelling s/paltforms/platforms/g spi: pic32-sqi: Remove pic32_sqi_setup and pic32_sqi_cleanup spi: Fix simple typo s/impelment/implement spi: rockchip: potential NULL dereference on error spi: zynqmp: disable clocks in error paths spi: Drop unnecessary dependencies on relaxed I/O accessors spi: qup: Add spi_master_put in remove function spi: qup: Handle clocks in pm_runtime suspend and resume spi: st-ssc4: Fix missing spi_master_put in spi_st_probe error paths spi: st-ssc4: Allow compile test build spi: omap2-mcspi: Use dma_request_chan() for requesting DMA channel spi: davinci: Use dma_request_chan() for requesting DMA channel spi: pic32: Fix checking return value of devm_ioremap_resource spi: spi-fsl-dspi: Update DT binding documentation spi: Drop duplicate code to set master->dev.parent spi: pic32: Set proper bits_per_word_mask spi: return error if kmap'd buffers passed to spi_map_buf() spi: core: add hook flash_read_supported to spi_master spi: pic32-sqi: silence array overflow warning ... commit 8bc4d5f394a3facbad6af2f18940f1db3b1a0844 Merge: 2956729 e5366a2 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 11:00:20 2016 -0700 Merge tag 'for-linus-20160523' of git://git.infradead.org/linux-mtd Pull MTD updates from Brian Norris: "First cycle with Boris as NAND maintainer! Many (most) bullets stolen from him. Generic: - Migrated NAND LED trigger to be a generic MTD trigger NAND: - Introduction of the "ECC algorithm" concept, to avoid overloading the ECC mode field too much more - Replaced the nand_ecclayout infrastructure with something a little more flexible (finally!) and future proof - Rework of the OMAP GPMC and NAND drivers; the TI folks pulled some of this into their own tree as well - Prepare the sunxi NAND driver to receive DMA support - Handle bitflips in erased pages on GPMI revisions that do not support this in hardware. SPI NOR: - Start using the spi_flash_read() API for SPI drivers that support it (i.e., SPI drivers with special memory-mapped flash modes) And other small scattered improvments" * tag 'for-linus-20160523' of git://git.infradead.org/linux-mtd: (155 commits) mtd: spi-nor: support GigaDevice gd25lq64c mtd: nand_bch: fix spelling of "probably" mtd: brcmnand: respect ECC algorithm set by NAND subsystem gpmi-nand: Handle ECC Errors in erased pages Documentation: devicetree: deprecate "soft_bch" nand-ecc-mode value mtd: nand: add support for "nand-ecc-algo" DT property mtd: mtd: drop NAND_ECC_SOFT_BCH enum value mtd: drop support for NAND_ECC_SOFT_BCH as "soft_bch" mapping mtd: nand: read ECC algorithm from the new field mtd: nand: fsmc: validate ECC setup by checking algorithm directly mtd: nand: set ECC algorithm to Hamming on fallback staging: mt29f_spinand: set ECC algorithm explicitly CRIS v32: nand: set ECC algorithm explicitly mtd: nand: atmel: set ECC algorithm explicitly mtd: nand: davinci: set ECC algorithm explicitly mtd: nand: bf5xx: set ECC algorithm explicitly mtd: nand: omap2: Fix high memory dma prefetch transfer mtd: nand: omap2: Start dma request before enabling prefetch mtd: nandsim: add __init attribute mtd: nand: move of_get_nand_xxx() helpers into nand_base.c ... commit 29567292c0b5b2fb484125c280a2175141fe2205 Merge: ecaba71 dd14be9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 10:22:34 2016 -0700 Merge tag 'for-linus-4.7-rc0-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip Pull xen bug fixes from David Vrabel. * tag 'for-linus-4.7-rc0-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen: use same main loop for counting and remapping pages xen/events: Don't move disabled irqs xen/x86: actually allocate legacy interrupts on PV guests Xen: don't warn about 2-byte wchar_t in efi xen/gntdev: reduce copy batch size to 16 xen/x86: don't lose event interrupts commit ecaba7185894778c24895356d117a7f92e3c92de Merge: e989cc5 bb99128 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 09:46:45 2016 -0700 Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost Pull virtio updates from Michael Tsirkin: "Looks like a quiet cycle for virtio. There's a new inorder option for the ringtest tool, and a bugfix for balloon for ppc platforms when using virtio 1 mode" * tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost: ringtest: pass buf != NULL virtio_balloon: fix PFN format for virtio-1 virtio: add inorder option commit e989cc564691901d42e957059592fe3e7b6893fc Merge: 36b150b 9fa78f6 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 09:41:46 2016 -0700 Merge tag 'nios2-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lftan/nios2 Pull nios2 update from Ley Foon Tan: - add order-only DTC dependency to %.dtb target - fix libgcc location detection * tag 'nios2-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lftan/nios2: nios2: Add order-only DTC dependency to %.dtb target nios2: Fix libgcc location detection commit 36b150bbcc1125abaad89963420a37ff70686d5a Merge: 84787c5 52e9e6e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 24 09:19:38 2016 -0700 Merge tag 'microblaze-4.7-rc1' of git://git.monstr.eu/linux-2.6-microblaze Pull Microblaze updates from Michal Simek: - Wire-up new syscalls - Fix link error * tag 'microblaze-4.7-rc1' of git://git.monstr.eu/linux-2.6-microblaze: microblaze: pci: export isa_io_base to fix link errors microblaze: Wire up userfaultfd, membarrier, mlock2 syscalls commit f7aa23cb8dba96b92f46e47101d360c5e0fa4e3b Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon May 23 23:24:21 2016 -0300 spi: spi-ep93xx: Fix the PTR_ERR() argument PTR_ERR should access the value just tested by IS_ERR. The semantic patch that makes this change is available in scripts/coccinelle/tests/odd_ptr_err.cocci. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-ep93xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0de4cbb3dddca35ecd06b95918f38439c9c6401f Author: Honggang Li <honli@redhat.com> Date: Mon May 23 08:32:09 2016 +0800 RDMA/cxgb3: device driver frees DMA memory with different size [ 598.852037] ------------[ cut here ]------------ [ 598.856698] WARNING: at lib/dma-debug.c:887 check_unmap+0xf8/0x920() [ 598.863079] cxgb3 0000:01:00.0: DMA-API: device driver frees DMA memory with different size [device address=0x0000000003310000] [map size=17 bytes] [unmap size=16 bytes] [ 598.878265] Modules linked in: xprtrdma ib_isert iscsi_target_mod ib_iser libiscsi scsi_transport_iscsi ib_srpt target_core_mod ib_srp scsi_transport_srp scsi_tgt ib_ipoib rdma_ucm ib_ucm ib_uverbs ib_umad rdma_cm ib_cm iw_cm ib_sa ib_mad kvm_amd kvm ipmi_devintf ipmi_ssif dcdbas pcspkr ipmi_si sg ipmi_msghandler acpi_power_meter amd64_edac_mod shpchp edac_core sp5100_tco k10temp edac_mce_amd i2c_piix4 acpi_cpufreq nfsd auth_rpcgss nfs_acl lockd grace sunrpc ip_tables xfs libcrc32c sd_mod crc_t10dif crct10dif_generic crct10dif_common ata_generic iw_cxgb3 pata_acpi ib_core ib_addr mgag200 syscopyarea sysfillrect sysimgblt i2c_algo_bit drm_kms_helper ttm pata_atiixp drm ahci libahci serio_raw i2c_core cxgb3 libata bnx2 mdio dm_mirror dm_region_hash dm_log dm_mod [ 598.946822] CPU: 3 PID: 11820 Comm: cmtime Not tainted 3.10.0-327.el7.x86_64.debug #1 [ 598.954681] Hardware name: Dell Inc. PowerEdge R415/0GXH08, BIOS 2.0.2 10/22/2012 [ 598.962193] ffff8808077479a8 000000000381a432 ffff880807747960 ffffffff81700918 [ 598.969663] ffff880807747998 ffffffff8108b6c0 ffff880807747a80 ffff8808063f55c0 [ 598.977132] ffffffff833ca850 0000000000000282 ffff88080b1bb800 ffff880807747a00 [ 598.984602] Call Trace: [ 598.987062] [<ffffffff81700918>] dump_stack+0x19/0x1b [ 598.992224] [<ffffffff8108b6c0>] warn_slowpath_common+0x70/0xb0 [ 598.998254] [<ffffffff8108b75c>] warn_slowpath_fmt+0x5c/0x80 [ 599.004033] [<ffffffff813903b8>] check_unmap+0xf8/0x920 [ 599.009369] [<ffffffff81025959>] ? sched_clock+0x9/0x10 [ 599.014702] [<ffffffff81390cee>] debug_dma_free_coherent+0x7e/0xa0 [ 599.021008] [<ffffffffa01ece2c>] cxio_destroy_cq+0xcc/0x160 [iw_cxgb3] [ 599.027654] [<ffffffffa01e8da0>] iwch_destroy_cq+0xf0/0x140 [iw_cxgb3] [ 599.034307] [<ffffffffa01c4bfe>] ib_destroy_cq+0x1e/0x30 [ib_core] [ 599.040601] [<ffffffffa04ff2d2>] ib_uverbs_close+0x302/0x4d0 [ib_uverbs] [ 599.047417] [<ffffffff812335a2>] __fput+0x102/0x310 [ 599.052401] [<ffffffff8123388e>] ____fput+0xe/0x10 [ 599.057297] [<ffffffff810bbde4>] task_work_run+0xb4/0xe0 [ 599.062719] [<ffffffff81092a84>] do_exit+0x304/0xc60 [ 599.067789] [<ffffffff81025905>] ? native_sched_clock+0x35/0x80 [ 599.073820] [<ffffffff81025959>] ? sched_clock+0x9/0x10 [ 599.079153] [<ffffffff8170a49c>] ? _raw_spin_unlock_irq+0x2c/0x50 [ 599.085358] [<ffffffff8109346c>] do_group_exit+0x4c/0xc0 [ 599.090779] [<ffffffff810a8661>] get_signal_to_deliver+0x2e1/0x960 [ 599.097071] [<ffffffff8101c497>] do_signal+0x57/0x6e0 [ 599.102229] [<ffffffff81714bd1>] ? sysret_signal+0x5/0x4e [ 599.107738] [<ffffffff8101cb7f>] do_notify_resume+0x5f/0xb0 [ 599.113418] [<ffffffff81714e7d>] int_signal+0x12/0x17 [ 599.118576] ---[ end trace 1e4653102e7e7019 ]--- [ 599.123211] Mapped at: [ 599.125577] [<ffffffff8138ed8b>] debug_dma_alloc_coherent+0x2b/0x80 [ 599.131968] [<ffffffffa01ec862>] cxio_create_cq+0xf2/0x1f0 [iw_cxgb3] [ 599.139920] [<ffffffffa01e9c05>] iwch_create_cq+0x105/0x4e0 [iw_cxgb3] [ 599.147895] [<ffffffffa0500584>] create_cq.constprop.14+0x184/0x2e0 [ib_uverbs] [ 599.156649] [<ffffffffa05027fb>] ib_uverbs_create_cq+0x10b/0x140 [ib_uverbs] Fixes: b955150ea784 ('RDMA/cxgb3: When a user QP is marked in error, also mark the CQs in error') Signed-off-by: Honggang Li <honli@redhat.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb3/cxio_hal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4d1034eb7c2f5e32d48ddc4dfce0f1a723d28667 Author: Jiri Kosina <jikos@kernel.org> Date: Tue May 24 16:38:50 2016 +0200 MAINTAINERS: mark bcache as orphan The submitted patches are not being reacted upon, and Jens is only picking up stable fixes on an rather ad-hoc basis. Link: lkml.kernel.org/r/574462C5.40307@kernel.dk Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 29e6c57cc78eb7cb8302088061a0721a41ade658 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 24 16:38:34 2016 +0200 bcache: bch_gc_thread() is not freezable bch_gc_thread() doesn't mark itself freezable, so calling try_to_freeze() in its context is just an expensive no-op. Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/md/bcache/btree.c | 2 -- 1 file changed, 2 deletions(-) commit 770b8ce400123af89ac469361d7912f458915547 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 24 16:38:15 2016 +0200 bcache: bch_allocator_thread() is not freezable bch_allocator_thread() is calling try_to_freeze(), but that's just an expensive no-op given the fact that the thread is not marked freezable. Bucket allocator has to be up and running to the very last stages of the suspend, as the bcache I/O that's in flight (think of writing an hibernation image to a swap device served by bcache). Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/md/bcache/alloc.c | 2 -- 1 file changed, 2 deletions(-) commit 7c87df9c159aa1d228f0d77b37942216cff34922 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 24 16:38:10 2016 +0200 bcache: bch_writeback_thread() is not freezable bch_writeback_thread() is calling try_to_freeze(), but that's just an expensive no-op given the fact that the thread is not marked freezable. I/O helper kthreads, exactly such as the bcache writeback thread, actually shouldn't be freezable, because they are potentially necessary for finalizing the image write-out. Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/md/bcache/writeback.c | 3 --- 1 file changed, 3 deletions(-) commit 7d727869c7b86da0874436ac5675dcdadaf3a0a1 Author: Kailang Yang <kailang@realtek.com> Date: Tue May 24 16:46:07 2016 +0800 ALSA: hda/realtek - Add support for ALC295/ALC3254 Add support for ALC295/ALC3254. They are simply compatible with ALC225 chip. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 59fa5860204ffc95128d60cba9f54f9740a42c7d Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue May 24 11:42:30 2016 +0100 genirq: Fix missing return value in irq_destroy_ipi() Commit 7cec18a3906b changed the return type of irq_destroy_ipi to int, but missed adding a value to one return statement. Fix this to silence the resulting compiler warning: kernel/irq/ipi.c In function ‘irq_destroy_ipi’: kernel/irq/ipi.c:128:3: warning: ‘return’ with no value, in function returning non-void [-Wreturn-type] Fixes: 7cec18a3906b "genirq: Add error code reporting to irq_{reserve,destroy}_ipi" Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Link: http://lkml.kernel.org/r/1464086550-24734-1-git-send-email-matt.redfearn@imgtec.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/irq/ipi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1112018cefc586cba924770a2b28bff6d2f0aa5c Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Mon May 16 21:46:30 2016 +0200 ubifs: ubifs_dump_inode: Fix dumping field bulk_read The wrong field (xattr) is dumped here due to a copy-and-paste error. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Richard Weinberger <richard@nod.at> fs/ubifs/debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1900149c835ab5b48bea31a823ea5e5a401fb560 Author: Richard Weinberger <richard@nod.at> Date: Tue Apr 26 16:39:48 2016 +0200 UBI: Fix static volume checks when Fastmap is used Ezequiel reported that he's facing UBI going into read-only mode after power cut. It turned out that this behavior happens only when updating a static volume is interrupted and Fastmap is used. A possible trace can look like: ubi0 warning: ubi_io_read_vid_hdr [ubi]: no VID header found at PEB 2323, only 0xFF bytes ubi0 warning: ubi_eba_read_leb [ubi]: switch to read-only mode CPU: 0 PID: 833 Comm: ubiupdatevol Not tainted 4.6.0-rc2-ARCH #4 Hardware name: SAMSUNG ELECTRONICS CO., LTD. 300E4C/300E5C/300E7C/NP300E5C-AD8AR, BIOS P04RAP 10/15/2012 0000000000000286 00000000eba949bd ffff8800c45a7b38 ffffffff8140d841 ffff8801964be000 ffff88018eaa4800 ffff8800c45a7bb8 ffffffffa003abf6 ffffffff850e2ac0 8000000000000163 ffff8801850e2ac0 ffff8801850e2ac0 Call Trace: [<ffffffff8140d841>] dump_stack+0x63/0x82 [<ffffffffa003abf6>] ubi_eba_read_leb+0x486/0x4a0 [ubi] [<ffffffffa00453b3>] ubi_check_volume+0x83/0xf0 [ubi] [<ffffffffa0039d97>] ubi_open_volume+0x177/0x350 [ubi] [<ffffffffa00375d8>] vol_cdev_open+0x58/0xb0 [ubi] [<ffffffff8124b08e>] chrdev_open+0xae/0x1d0 [<ffffffff81243bcf>] do_dentry_open+0x1ff/0x300 [<ffffffff8124afe0>] ? cdev_put+0x30/0x30 [<ffffffff81244d36>] vfs_open+0x56/0x60 [<ffffffff812545f4>] path_openat+0x4f4/0x1190 [<ffffffff81256621>] do_filp_open+0x91/0x100 [<ffffffff81263547>] ? __alloc_fd+0xc7/0x190 [<ffffffff812450df>] do_sys_open+0x13f/0x210 [<ffffffff812451ce>] SyS_open+0x1e/0x20 [<ffffffff81a99e32>] entry_SYSCALL_64_fastpath+0x1a/0xa4 UBI checks static volumes for data consistency and reads the whole volume upon first open. If the volume is found erroneous users of UBI cannot read from it, but another volume update is possible to fix it. The check is performed by running ubi_eba_read_leb() on every allocated LEB of the volume. For static volumes ubi_eba_read_leb() computes the checksum of all data stored in a LEB. To verify the computed checksum it has to read the LEB's volume header which stores the original checksum. If the volume header is not found UBI treats this as fatal internal error and switches to RO mode. If the UBI device was attached via a full scan the assumption is correct, the volume header has to be present as it had to be there while scanning to get known as mapped. If the attach operation happened via Fastmap the assumption is no longer correct. When attaching via Fastmap UBI learns the mapping table from Fastmap's snapshot of the system state and not via a full scan. It can happen that a LEB got unmapped after a Fastmap was written to the flash. Then UBI can learn the LEB still as mapped and accessing it returns only 0xFF bytes. As UBI is not a FTL it is allowed to have mappings to empty PEBs, it assumes that the layer above takes care of LEB accounting and referencing. UBIFS does so using the LEB property tree (LPT). For static volumes UBI blindly assumes that all LEBs are present and therefore special actions have to be taken. The described situation can happen when updating a static volume is interrupted, either by a user or a power cut. The volume update code first unmaps all LEBs of a volume and then writes LEB by LEB. If the sequence of operations is interrupted UBI detects this either by the absence of LEBs, no volume header present at scan time, or corrupted payload, detected via checksum. In the Fastmap case the former method won't trigger as no scan happened and UBI automatically thinks all LEBs are present. Only by reading data from a LEB it detects that the volume header is missing and incorrectly treats this as fatal error. To deal with the situation ubi_eba_read_leb() from now on checks whether we attached via Fastmap and handles the absence of a volume header like a data corruption error. This way interrupted static volume updates will correctly get detected also when Fastmap is used. Cc: <stable@vger.kernel.org> Reported-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Tested-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/eba.c | 21 +++++++++++++++++++-- drivers/mtd/ubi/fastmap.c | 1 + drivers/mtd/ubi/ubi.h | 2 ++ 3 files changed, 22 insertions(+), 2 deletions(-) commit 73b0cd57fcd07201b138214f9a2353f76dd9ae2c Author: Heiko Schocher <hs@denx.de> Date: Fri Apr 22 12:06:38 2016 +0200 UBI: Set free_count to zero before walking through erase list Set free_count to zero before walking through ai->erase list in wl_init(). Found in U-Boot as U-Boot has no workqueue/threads, it immediately calls erase_worker(), which increase for each erased block free_count. Without this patch, free_count gets after this initialized to zero in wl_init(), so the free_count variable always has the maybe wrong value 0 in U-Boot. Signed-off-by: Heiko Schocher <hs@denx.de> Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/wl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 24663e7281b8fbfaae22467ec2625e2bffe07815 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:41:55 2016 +0300 UBI: Silence an unintialized variable warning My static checker complains that "val" is uninitialized when kstrtoint() fails. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/debug.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit fadb3665bad96be8f696e4899ee0f618536d54c7 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:41:26 2016 +0300 UBI: Clean up return in ubi_remove_volume() My static checker says that "err" can be uninitialized if "vol->reserved_pebs" is <= 0. I don't think that can happen but returning a literal is cleaner anyway. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/vmt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 960b35d06b6d6b377fd47a8a44e41a96f35ce485 Author: z00189512 <abc.zhangliang@huawei.com> Date: Wed Mar 30 02:41:19 2016 +0800 UBI: Modify wrong comment in ubi_leb_map function. Signed-off-by: z00189512 <abc.zhangliang@huawei.com> Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/kapi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1e0a74f10d76021988ecd9e34e6c0c65d1c5403e Author: Richard Weinberger <richard@nod.at> Date: Sat May 7 18:09:18 2016 +0200 UBI: Don't read back all data in ubi_eba_copy_leb() Drop this paranoia check from the old days. If our MTD driver or the flash is so bad that we even cannot trust it to write data we have bigger problems. If one really does not trust the flash and wants write-verify she can enable UBI io checks using debugfs. Signed-off-by: Richard Weinberger <richard@nod.at> drivers/mtd/ubi/eba.c | 26 -------------------------- 1 file changed, 26 deletions(-) commit 525bab71feb152bccb65054cc2bca1537e3bd2b5 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Thu Apr 28 18:13:58 2016 -0300 UBI: Add ro-mode sysfs attribute On serious situations, UBI may detect serious device corruption, and switch to read-only mode to protect the data and allow debugging. This commit exposes this ro-mode on sysfs, so it can be obtained by userspace tools. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Richard Weinberger <richard@nod.at> Documentation/ABI/stable/sysfs-class-ubi | 9 +++++++++ drivers/mtd/ubi/build.c | 5 +++++ 2 files changed, 14 insertions(+) commit dd14be92fbf5bc1ef7343f34968440e44e21b46a Author: Juergen Gross <jgross@suse.com> Date: Wed May 18 16:44:54 2016 +0200 xen: use same main loop for counting and remapping pages Instead of having two functions for cycling through the E820 map in order to count to be remapped pages and remap them later, just use one function with a caller supplied sub-function called for each region to be processed. This eliminates the possibility of a mismatch between both loops which showed up in certain configurations. Suggested-by: Ed Swierk <eswierk@skyportsystems.com> Signed-off-by: Juergen Gross <jgross@suse.com> Cc: <stable@vger.kernel.org> Signed-off-by: David Vrabel <david.vrabel@citrix.com> arch/x86/xen/setup.c | 65 +++++++++++++++++++++------------------------------- 1 file changed, 26 insertions(+), 39 deletions(-) commit f0f393877c71ad227d36705d61d1e4062bc29cf5 Author: Ross Lagerwall <ross.lagerwall@citrix.com> Date: Tue May 10 16:11:00 2016 +0100 xen/events: Don't move disabled irqs Commit ff1e22e7a638 ("xen/events: Mask a moving irq") open-coded irq_move_irq() but left out checking if the IRQ is disabled. This broke resuming from suspend since it tries to move a (disabled) irq without holding the IRQ's desc->lock. Fix it by adding in a check for disabled IRQs. The resulting stacktrace was: kernel BUG at /build/linux-UbQGH5/linux-4.4.0/kernel/irq/migration.c:31! invalid opcode: 0000 [#1] SMP Modules linked in: xenfs xen_privcmd ... CPU: 0 PID: 9 Comm: migration/0 Not tainted 4.4.0-22-generic #39-Ubuntu Hardware name: Xen HVM domU, BIOS 4.6.1-xs125180 05/04/2016 task: ffff88003d75ee00 ti: ffff88003d7bc000 task.ti: ffff88003d7bc000 RIP: 0010:[<ffffffff810e26e2>] [<ffffffff810e26e2>] irq_move_masked_irq+0xd2/0xe0 RSP: 0018:ffff88003d7bfc50 EFLAGS: 00010046 RAX: 0000000000000000 RBX: ffff88003d40ba00 RCX: 0000000000000001 RDX: 0000000000000001 RSI: 0000000000000100 RDI: ffff88003d40bad8 RBP: ffff88003d7bfc68 R08: 0000000000000000 R09: ffff88003d000000 R10: 0000000000000000 R11: 000000000000023c R12: ffff88003d40bad0 R13: ffffffff81f3a4a0 R14: 0000000000000010 R15: 00000000ffffffff FS: 0000000000000000(0000) GS:ffff88003da00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fd4264de624 CR3: 0000000037922000 CR4: 00000000003406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Stack: ffff88003d40ba38 0000000000000024 0000000000000000 ffff88003d7bfca0 ffffffff814c8d92 00000010813ef89d 00000000805ea732 0000000000000009 0000000000000024 ffff88003cc39b80 ffff88003d7bfce0 ffffffff814c8f66 Call Trace: [<ffffffff814c8d92>] eoi_pirq+0xb2/0xf0 [<ffffffff814c8f66>] __startup_pirq+0xe6/0x150 [<ffffffff814ca659>] xen_irq_resume+0x319/0x360 [<ffffffff814c7e75>] xen_suspend+0xb5/0x180 [<ffffffff81120155>] multi_cpu_stop+0xb5/0xe0 [<ffffffff811200a0>] ? cpu_stop_queue_work+0x80/0x80 [<ffffffff811203d0>] cpu_stopper_thread+0xb0/0x140 [<ffffffff810a94e6>] ? finish_task_switch+0x76/0x220 [<ffffffff810ca731>] ? __raw_callee_save___pv_queued_spin_unlock+0x11/0x20 [<ffffffff810a3935>] smpboot_thread_fn+0x105/0x160 [<ffffffff810a3830>] ? sort_range+0x30/0x30 [<ffffffff810a0588>] kthread+0xd8/0xf0 [<ffffffff810a04b0>] ? kthread_create_on_node+0x1e0/0x1e0 [<ffffffff8182568f>] ret_from_fork+0x3f/0x70 [<ffffffff810a04b0>] ? kthread_create_on_node+0x1e0/0x1e0 Signed-off-by: Ross Lagerwall <ross.lagerwall@citrix.com> Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Cc: <stable@vger.kernel.org> Signed-off-by: David Vrabel <david.vrabel@citrix.com> drivers/xen/events/events_base.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 702f926067d2a4b28c10a3c41a1172dd62d9e735 Author: Stefano Stabellini <sstabellini@kernel.org> Date: Wed Apr 20 14:15:01 2016 +0100 xen/x86: actually allocate legacy interrupts on PV guests b4ff8389ed14 is incomplete: relies on nr_legacy_irqs() to get the number of legacy interrupts when actually nr_legacy_irqs() returns 0 after probe_8259A(). Use NR_IRQS_LEGACY instead. Signed-off-by: Stefano Stabellini <sstabellini@kernel.org> CC: stable@vger.kernel.org arch/x86/pci/xen.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 971a69db7dc02faaeed325c195f5db5da597cb58 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 14:47:59 2016 +0200 Xen: don't warn about 2-byte wchar_t in efi The XEN UEFI code has become available on the ARM architecture recently, but now causes a link-time warning: ld: warning: drivers/xen/efi.o uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail This seems harmless, because the efi code only uses 2-byte characters when interacting with EFI, so we don't pass on those strings to elsewhere in the system, and we just need to silence the warning. It is not clear to me whether we actually need to build the file with the -fshort-wchar flag, but if we do, then we should also pass --no-wchar-size-warning to the linker, to avoid the warning. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Stefano Stabellini <sstabellini@kernel.org> Fixes: 37060935dc04 ("ARM64: XEN: Add a function to initialize Xen specific UEFI runtime services") drivers/xen/Makefile | 1 + 1 file changed, 1 insertion(+) commit 36ae220aa62d382a8bacbf7ec080d9d36a2b4d49 Author: David Vrabel <david.vrabel@citrix.com> Date: Mon May 9 10:59:48 2016 +0100 xen/gntdev: reduce copy batch size to 16 IOCTL_GNTDEV_GRANT_COPY batches copy operations to reduce the number of hypercalls. The stack is used to avoid a memory allocation in a hot path. However, a batch size of 24 requires more than 1024 bytes of stack which in some configurations causes a compiler warning. xen/gntdev.c: In function ‘gntdev_ioctl_grant_copy’: xen/gntdev.c:949:1: warning: the frame size of 1248 bytes is larger than 1024 bytes [-Wframe-larger-than=] This is a harmless warning as there is still plenty of stack spare, but people keep trying to "fix" it. Reduce the batch size to 16 to reduce stack usage to less than 1024 bytes. This should have minimal impact on performance. Signed-off-by: David Vrabel <david.vrabel@citrix.com> drivers/xen/gntdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c06b6d70feb32d28f04ba37aa3df17973fd37b6b Author: Stefano Stabellini <sstabellini@kernel.org> Date: Fri Apr 15 18:23:00 2016 -0700 xen/x86: don't lose event interrupts On slow platforms with unreliable TSC, such as QEMU emulated machines, it is possible for the kernel to request the next event in the past. In that case, in the current implementation of xen_vcpuop_clockevent, we simply return -ETIME. To be precise the Xen returns -ETIME and we pass it on. However the result of this is a missed event, which simply causes the kernel to hang. Instead it is better to always ask the hypervisor for a timer event, even if the timeout is in the past. That way there are no lost interrupts and the kernel survives. To do that, remove the VCPU_SSHOTTMR_future flag. Signed-off-by: Stefano Stabellini <sstabellini@kernel.org> Acked-by: Juergen Gross <jgross@suse.com> arch/x86/xen/time.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 079d08555cd116e3e04cb588aad1fd6f08b2a31b Author: Jan Kiszka <jan.kiszka@siemens.com> Date: Mon May 23 08:43:31 2016 +0200 KVM: SVM: Add more SVM_EXIT_REASONS Useful when tracing nested setups where the guest may trigger more than the host usually does. But even some typical host exits were missing. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/uapi/asm/svm.h | 44 ++++++++++++++++++++++++++++++++++++++--- 1 file changed, 41 insertions(+), 3 deletions(-) commit cfc5abbcd043752c426740e61700010abfcc71e1 Author: Jan Kiszka <jan.kiszka@siemens.com> Date: Mon May 23 08:43:33 2016 +0200 KVM: Unify traced vector format Specifically the change from hex to decimal helps correlating events. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> include/trace/events/kvm.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 5446a979e0805cedd3b7b4909d7f68f69b201fe3 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon May 23 13:20:10 2016 +0300 svm: bitwise vs logical op typo These were supposed to be a bitwise operation but there is a typo. The result is mostly harmless, but sparse correctly complains. Fixes: 44a95dae1d22 ('KVM: x86: Detect and Initialize AVIC support') Fixes: 18f40c53e10f ('svm: Add VMEXIT handlers for AVIC') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/svm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 44bcc922381e24c4f38dc5dfd8d34d60b2ede898 Merge: 9842df6 35a2d58 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Tue May 24 12:10:51 2016 +0200 Merge tag 'kvm-arm-for-4-7-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into kvm-next KVM/ARM Changes for v4.7 take 2 "The GIC is dead; Long live the GIC" This set of changes include the new vgic, which is a reimplementation of our horribly broken legacy vgic implementation. The two implementations will live side-by-side (with the new being the configured default) for one kernel release and then we'll remove it. Also fixes a non-critical issue with virtual abort injection to guests. commit 0c9f790fcbdaf8cfb6dd7fb4e88fadf55082e37e Merge: 408cf67 3a62a7b Author: Ingo Molnar <mingo@kernel.org> Date: Tue May 24 07:40:52 2016 +0200 Merge tag 'perf-core-for-mingo-20160523' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent Pull perf/core improvements from Arnaldo Carvalho de Melo: User visible changes: - Add "srcline_from" and "srcline_to" branch sort keys to 'perf top' and 'perf report' (Andi Kleen) Infrastructure changes: - Make 'perf trace' auto-attach fd->name and ptr->name beautifiers based on the name of syscall arguments, this way new syscalls that have 'const char * (path,pathname,filename)' will use the fd->name beautifier (vfs_getname perf probe, if in place) and the 'fd->name' (vfs_getname or via /proc/PID/fd/) (Arnaldo Carvalho de Melo) - Infrastructure to read from a ring buffer in backward write mode (Wang Nan) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 92181d47ee74749bdf902f080dab9fa9ef44b37f Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 18:07:29 2016 +0200 headers_check: don't warn about c++ guards A recent addition to the DRM tree for 4.7 added 'extern "C"' guards for c++ to all the DRM headers, and that now causes warnings in 'make headers_check': usr/include/drm/amdgpu_drm.h:38: userspace cannot reference function or variable defined in the kernel usr/include/drm/drm.h:63: userspace cannot reference function or variable defined in the kernel usr/include/drm/drm.h:699: userspace cannot reference function or variable defined in the kernel usr/include/drm/drm_fourcc.h:30: userspace cannot reference function or variable defined in the kernel usr/include/drm/drm_mode.h:33: userspace cannot reference function or variable defined in the kernel usr/include/drm/drm_sarea.h:38: userspace cannot reference function or variable defined in the kernel usr/include/drm/exynos_drm.h:21: userspace cannot reference function or variable defined in the kernel usr/include/drm/i810_drm.h:7: userspace cannot reference function or variable defined in the kernel This changes the headers_check.pl script to not warn about this. I'm listing the merge commit as introducing the problem, because there are several patches in this branch that each do this for one file. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 7c10ddf87472 ("Merge branch 'drm-uapi-extern-c-fixes' of https://github.com/evelikov/linux into drm-next") Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com> scripts/headers_check.pl | 4 ++++ 1 file changed, 4 insertions(+) commit 84787c572d402644dca4874aba73324d9f8e3948 Merge: d62a023 c5d2cac Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 19:42:28 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge yet more updates from Andrew Morton: - Oleg's "wait/ptrace: assume __WALL if the child is traced". It's a kernel-based workaround for existing userspace issues. - A few hotfixes - befs cleanups - nilfs2 updates - sys_wait() changes - kexec updates - kdump - scripts/gdb updates - the last of the MM queue - a few other misc things * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (84 commits) kgdb: depends on VT drm/amdgpu: make amdgpu_mn_get wait for mmap_sem killable drm/radeon: make radeon_mn_get wait for mmap_sem killable drm/i915: make i915_gem_mmap_ioctl wait for mmap_sem killable uprobes: wait for mmap_sem for write killable prctl: make PR_SET_THP_DISABLE wait for mmap_sem killable exec: make exec path waiting for mmap_sem killable aio: make aio_setup_ring killable coredump: make coredump_wait wait for mmap_sem for write killable vdso: make arch_setup_additional_pages wait for mmap_sem for write killable ipc, shm: make shmem attach/detach wait for mmap_sem killable mm, fork: make dup_mmap wait for mmap_sem for write killable mm, proc: make clear_refs killable mm: make vm_brk killable mm, elf: handle vm_brk error mm, aout: handle vm_brk failures mm: make vm_munmap killable mm: make vm_mmap killable mm: make mmap_sem for write waits killable for mm syscalls MAINTAINERS: add co-maintainer for scripts/gdb ... commit d62a0234c87f1457a3d2ba519ef90cf164a5eb23 Merge: 4496a1d 6eab37d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 19:37:41 2016 -0700 Merge tag 'linux-kselftest-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest Pull kselftest updates from Shuah Khan: "This update for Kselftest adds: - a new ftrace testcase - fixes for ftrace and intel_pstate tests" * tag 'linux-kselftest-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest: tools: testing: define the _GNU_SOURCE macro kselftests/ftrace: Add a test case for event pid filtering kselftests/ftrace: Detect tracefs mount point commit 4496a1d9638644484d0d99e9de63742248f3c119 Merge: d6542d7 97f8827 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 19:30:30 2016 -0700 Merge tag 'trace-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing fix from Steven Rostedt: "Reviewing the selftest I recently submitted, I realize that the second part of it uses my old hack to get the PID of the spawned background tasks, which doesn't work for all shells, instead of the common use of $!" * tag 'trace-v4.7-3' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: ftracetest: Use proper logic to find process PID commit d6542d76ec88dde3305b06c03952d87b15bbc292 Merge: 3ec438a bdf03e5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 19:05:11 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile Pull arch/tile updates from Chris Metcalf: "This is an even quieter cycle than usual" * git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile: Fix typo Fix typo Fix typo tile: sort the "select" lines in the TILE/TILEGX configs tile: clarify barrier semantics of atomic_add_return tile/defconfigs: Remove CONFIG_IPV6_PRIVACY commit 3ec438afed6f166f1774b3e95b9a65e3b6da5f2c Merge: e4f7bdc 7598469a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 18:19:21 2016 -0700 Merge branch 'for-4.7-dw' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata Pull libata sata_dwc_460ex updates from Tejun Heo: "Patches to bring sata_dwc_460ex up to snuff. It was a separate pull request because it depends on dmaengine dw platform changes which are now in mainline" * 'for-4.7-dw' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata: (24 commits) ata: dwc: add DMADEVICES dependency powerpc/4xx: Device tree update for the 460ex DWC SATA ata: sata_dwc_460ex: make debug messages neat ata: sata_dwc_460ex: supply physical address of FIFO to DMA ata: sata_dwc_460ex: use devm_ioremap ata: sata_dwc_460ex: tidy up sata_dwc_clear_dmacr() ata: sata_dwc_460ex: use readl/writel_relaxed() ata: sata_dwc_460ex: switch to new dmaengine_terminate_* API ata: sata_dwc_460ex: add __iomem to register base pointer ata: sata_dwc_460ex: get rid of incorrect cast ata: sata_dwc_460ex: get rid of some pointless casts ata: sata_dwc_460ex: remove empty libata callback ata: sata_dwc_460ex: correct HOSTDEV{P}_FROM_*() macros ata: sata_dwc_460ex: get rid of global data ata: sata_dwc_460ex: add phy support ata: sata_dwc_460ex: use "dmas" DT property to find dma channel ata: sata_dwc_460ex: don't call ata_sff_qc_issue() on DMA commands ata: sata_dwc_460ex: skip dma setup for non-dma commands ata: sata_dwc_460ex: select only core part of DMA driver ata: sata_dwc_460ex: DMA is always a flow controller ... commit e4f7bdc2ec0d0dcc27f7d70db27a620dfdc1f697 Merge: 3159ee5 6d1003a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 17:53:39 2016 -0700 Merge branch 'for-4.7-zac' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata Pull libata ZAC support from Tejun Heo: "This contains Zone ATA Command support for Shingled Magnetic Recording devices. In addition to sending the new commands down to the device, as ZAC commands depend on getting a lot of responses from the device, piping up responses is beefed up too. However, it doesn't involve changes to libata core mechanism or its interaction with upper layers, so I'm not expecting too many fallouts. Kudos to Hannes for driving SMR support" * 'for-4.7-zac' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata: (28 commits) libata: support host-aware and host-managed ZAC devices libata: support device-managed ZAC devices libata: NCQ encapsulation for ZAC MANAGEMENT OUT libata: Implement ZBC OUT translation libata: implement ZBC IN translation libata: fixup ZAC device disabling libata-scsi: Generate sense code for disabled devices libata-trace: decode subcommands libata: Check log page directory before accessing pages libata: Add command definitions for NCQ Encapsulation for READ LOG DMA EXT libata: Separate out ata_dev_config_ncq_send_recv() libata/libsas: Define ATA_CMD_NCQ_NON_DATA libsas: enable FPDMA SEND/RECEIVE libata: do not attempt to retrieve sense code twice libata-scsi: Set information sense field for invalid parameter libata-scsi: set bit pointer for sense code information libata-scsi: Set field pointer in sense code scsi: add scsi_set_sense_field_pointer() libata: Implement control mode page to select sense format libata-scsi: generate correct ATA pass-through sense ... commit 3159ee58d2133fbf9a710c21201ce717a8cf61a0 Merge: 1d6da87 653bd45 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 17:26:27 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull more security subsystem updates from James Morris: "Minor updates for the keys code" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: MAINTAINERS: Update keyrings record and add asymmetric keys record lib: asn1_decoder - add MODULE_LICENSE("GPL") KEYS: The PKCS#7 test key type should use the secondary keyring commit c5d2cac0f1caaf7dd21350146fb29c55b3e74249 Author: Jiri Slaby <jslaby@suse.cz> Date: Mon May 23 16:26:20 2016 -0700 kgdb: depends on VT With VT=n, the kernel build fails with: drivers/built-in.o: In function `kgdboc_pre_exp_handler': kgdboc.c:(.text+0x7b5aa): undefined reference to `fg_console' kgdboc.c:(.text+0x7b5ce): undefined reference to `vc_cons' kgdboc.c:(.text+0x7b5d5): undefined reference to `vc_cons' kgdboc.o is built when KGDB_SERIAL_CONSOLE is set. So make KGDB_SERIAL_CONSOLE depend on HW_CONSOLE which includes those symbols. Link: http://lkml.kernel.org/r/1459412955-4696-1-git-send-email-jslaby@suse.cz Signed-off-by: Jiri Slaby <jslaby@suse.cz> Reported-by: "Jim Davis" <jim.epost@gmail.com> Acked-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/Kconfig.kgdb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b5637051f1ed48f68370234e879d40d8dd4ab087 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:17 2016 -0700 drm/amdgpu: make amdgpu_mn_get wait for mmap_sem killable amdgpu_mn_get which is called during ioct path relies on mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. [arnd@arndb.de: use ERR_PTR() to return from amdgpu_mn_get] Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Reviewed-by: Christian König <christian.koenig@amd.com> Cc: David Airlie <airlied@linux.ie> Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 2267c2999b49682ae4801dab3b1ac96584f57da0 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:14 2016 -0700 drm/radeon: make radeon_mn_get wait for mmap_sem killable radeon_mn_get which is called during ioct path relies on mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Reviewed-by: Christian König <christian.koenig@amd.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: David Airlie <airlied@linux.ie> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/gpu/drm/radeon/radeon_mn.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 80a89a5e8513c6a1158fb07946cfe63c8430ba7a Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:11 2016 -0700 drm/i915: make i915_gem_mmap_ioctl wait for mmap_sem killable i915_gem_mmap_ioctl relies on mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: David Airlie <airlied@linux.ie> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/gpu/drm/i915/i915_gem.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 598fdc1d66674264e122ca9d007ad822e98d8b8d Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:08 2016 -0700 uprobes: wait for mmap_sem for write killable xol_add_vma needs mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Do not warn in dup_xol_work if __create_xol_area failed due to fatal signal pending because this is usually considered a kernel issue. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/events/uprobes.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 17b0573d77fbd547cbf1d711b90d269bdcc1efd3 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:05 2016 -0700 prctl: make PR_SET_THP_DISABLE wait for mmap_sem killable PR_SET_THP_DISABLE requires mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Alex Thorlton <athorlton@sgi.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/sys.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit f268dfe905d4682150d4acbb25f59adc04cd9398 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:26:02 2016 -0700 exec: make exec path waiting for mmap_sem killable setup_arg_pages requires mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. All the callers are already handling error path and the fatal signal doesn't need any additional treatment. The same applies to __bprm_mm_init. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/exec.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 013373e8b86735086ac86aff782637f7e58ff84d Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:59 2016 -0700 aio: make aio_setup_ring killable aio_setup_ring waits for mmap_sem in writable mode. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. This will also expedite the return to the userspace and do_exit. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Jeff Moyer <jmoyer@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Benamin LaHaise <bcrl@kvack.org> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/aio.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 4136c26b65d12d0c5ef58b7d30dc0aa2a11ed491 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:57 2016 -0700 coredump: make coredump_wait wait for mmap_sem for write killable coredump_wait waits for mmap_sem for write currently which can prevent oom_reaper to reclaim the oom victims address space asynchronously because that requires mmap_sem for read. This might happen if the oom victim is multi threaded and some thread(s) is holding mmap_sem for read (e.g. page fault) and it is stuck in the page allocator while other thread(s) reached coredump_wait already. This patch simply uses down_write_killable and bails out with EINTR if the lock got interrupted by the fatal signal. do_coredump will return right away and do_group_exit will take care to zap the whole thread group. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/coredump.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 69048176078adda4087a648c9b1812ddd800fad1 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:54 2016 -0700 vdso: make arch_setup_additional_pages wait for mmap_sem for write killable most architectures are relying on mmap_sem for write in their arch_setup_additional_pages. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Andy Lutomirski <luto@amacapital.net> [x86 vdso] Acked-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/arm/kernel/process.c | 3 ++- arch/arm64/kernel/vdso.c | 6 ++++-- arch/hexagon/kernel/vdso.c | 3 ++- arch/mips/kernel/vdso.c | 3 ++- arch/powerpc/kernel/vdso.c | 3 ++- arch/s390/kernel/vdso.c | 3 ++- arch/sh/kernel/vsyscall/vsyscall.c | 4 +++- arch/x86/entry/vdso/vma.c | 3 ++- arch/x86/um/vdso/vma.c | 3 ++- 9 files changed, 21 insertions(+), 10 deletions(-) commit 91f4f94ea3f2eabb4cee68149a31e30f84a993dd Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:51 2016 -0700 ipc, shm: make shmem attach/detach wait for mmap_sem killable shmat and shmdt rely on mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Davidlohr Bueso <dave@stgolabs.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Hugh Dickins <hughd@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> ipc/shm.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 7c051267931a9be9c6620cc17b362bc6ee6dedc8 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:48 2016 -0700 mm, fork: make dup_mmap wait for mmap_sem for write killable dup_mmap needs to lock current's mm mmap_sem for write. If the waiting task gets killed by the oom killer it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Ingo Molnar <mingo@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/fork.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 4e80153a6044bcd9a7d65c1ec4b1d1c44ba0ed6c Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:45 2016 -0700 mm, proc: make clear_refs killable CLEAR_REFS_MM_HIWATER_RSS and CLEAR_REFS_SOFT_DIRTY are relying on mmap_sem for write. If the waiting task gets killed by the oom killer and it would operate on the current's mm it would block oom_reaper from asynchronous address space reclaim and reduce the chances of timely OOM resolving. Wait for the lock in the killable mode and return with EINTR if the task got killed while waiting. This will also expedite the return to the userspace and do_exit even if the mm is remote. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Petr Cermak <petrcermak@chromium.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/proc/task_mmu.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 2d6c928241add2848e4eebfce407e95164229976 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:42 2016 -0700 mm: make vm_brk killable Now that all the callers handle vm_brk failure we can change it wait for mmap_sem killable to help oom_reaper to not get blocked just because vm_brk gets blocked behind mmap_sem readers. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 2 +- mm/mmap.c | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) commit ecc2bc8ac03884266cf73f8a2a42b911465b2fbc Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:39 2016 -0700 mm, elf: handle vm_brk error load_elf_library doesn't handle vm_brk failure although nothing really indicates it cannot do that because the function is allowed to fail due to vm_mmap failures already. This might be not a problem now but later patch will make vm_brk killable (resp. mmap_sem for write waiting will become killable) and so the failure will be more probable. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/binfmt_elf.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 864778b154233d3a673c520aa9606777589ecee7 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:36 2016 -0700 mm, aout: handle vm_brk failures vm_brk is allowed to fail but load_aout_binary simply ignores the error and happily continues. I haven't noticed any problem from that in real life but later patches will make the failure more likely because vm_brk will become killable (resp. mmap_sem for write waiting will become killable) so we should be more careful now. The error handling should be quite straightforward because there are calls to vm_mmap which check the error properly already. The only notable exception is set_brk which is called after beyond_if label. But nothing indicates that we cannot move it above set_binfmt as the two do not depend on each other and fail before we do set_binfmt and alter reference counting. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@kernel.org> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/ia32/ia32_aout.c | 22 +++++++++++++++------- fs/binfmt_aout.c | 11 ++++++++--- 2 files changed, 23 insertions(+), 10 deletions(-) commit ae7987835643e470cb220e6685bd36d92179ef9c Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:33 2016 -0700 mm: make vm_munmap killable Almost all current users of vm_munmap are ignoring the return value and so they do not handle potential error. This means that some VMAs might stay behind. This patch doesn't try to solve those potential problems. Quite contrary it adds a new failure mode by using down_write_killable in vm_munmap. This should be safer than other failure modes, though, because the process is guaranteed to die as soon as it leaves the kernel and exit_mmap will clean the whole address space. This will help in the OOM conditions when the oom victim might be stuck waiting for the mmap_sem for write which in turn can block oom_reaper which relies on the mmap_sem for read to make a forward progress and reclaim the address space of the victim. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/mmap.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 9fbeb5ab59a2b2a09cca2eb68283e7a090d4b98d Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:30 2016 -0700 mm: make vm_mmap killable All the callers of vm_mmap seem to check for the failure already and bail out in one way or another on the error which means that we can change it to use killable version of vm_mmap_pgoff and return -EINTR if the current task gets killed while waiting for mmap_sem. This also means that vm_mmap_pgoff can be killable by default and drop the additional parameter. This will help in the OOM conditions when the oom victim might be stuck waiting for the mmap_sem for write which in turn can block oom_reaper which relies on the mmap_sem for read to make a forward progress and reclaim the address space of the victim. Please note that load_elf_binary is ignoring vm_mmap error for current->personality & MMAP_PAGE_ZERO case but that shouldn't be a problem because the address is not used anywhere and we never return to the userspace if we got killed. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 2 +- mm/internal.h | 3 +-- mm/mmap.c | 2 +- mm/nommu.c | 2 +- mm/util.c | 13 ++++--------- 5 files changed, 8 insertions(+), 14 deletions(-) commit dc0ef0df7b6a90892ec41933212ac701152a254c Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 16:25:27 2016 -0700 mm: make mmap_sem for write waits killable for mm syscalls This is a follow up work for oom_reaper [1]. As the async OOM killing depends on oom_sem for read we would really appreciate if a holder for write didn't stood in the way. This patchset is changing many of down_write calls to be killable to help those cases when the writer is blocked and waiting for readers to release the lock and so help __oom_reap_task to process the oom victim. Most of the patches are really trivial because the lock is help from a shallow syscall paths where we can return EINTR trivially and allow the current task to die (note that EINTR will never get to the userspace as the task has fatal signal pending). Others seem to be easy as well as the callers are already handling fatal errors and bail and return to userspace which should be sufficient to handle the failure gracefully. I am not familiar with all those code paths so a deeper review is really appreciated. As this work is touching more areas which are not directly connected I have tried to keep the CC list as small as possible and people who I believed would be familiar are CCed only to the specific patches (all should have received the cover though). This patchset is based on linux-next and it depends on down_write_killable for rw_semaphores which got merged into tip locking/rwsem branch and it is merged into this next tree. I guess it would be easiest to route these patches via mmotm because of the dependency on the tip tree but if respective maintainers prefer other way I have no objections. I haven't covered all the mmap_write(mm->mmap_sem) instances here $ git grep "down_write(.*\<mmap_sem\>)" next/master | wc -l 98 $ git grep "down_write(.*\<mmap_sem\>)" | wc -l 62 I have tried to cover those which should be relatively easy to review in this series because this alone should be a nice improvement. Other places can be changed on top. [0] http://lkml.kernel.org/r/1456752417-9626-1-git-send-email-mhocko@kernel.org [1] http://lkml.kernel.org/r/1452094975-551-1-git-send-email-mhocko@kernel.org [2] http://lkml.kernel.org/r/1456750705-7141-1-git-send-email-mhocko@kernel.org This patch (of 18): This is the first step in making mmap_sem write waiters killable. It focuses on the trivial ones which are taking the lock early after entering the syscall and they are not changing state before. Therefore it is very easy to change them to use down_write_killable and immediately return with -EINTR. This will allow the waiter to pass away without blocking the mmap_sem which might be required to make a forward progress. E.g. the oom reaper will need the lock for reading to dismantle the OOM victim address space. The only tricky function in this patch is vm_mmap_pgoff which has many call sites via vm_mmap. To reduce the risk keep vm_mmap with the original non-killable semantic for now. vm_munmap callers do not bother checking the return value so open code it into the munmap syscall path for now for simplicity. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Mel Gorman <mgorman@suse.de> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Hugh Dickins <hughd@google.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: David Rientjes <rientjes@google.com> Cc: Dave Hansen <dave.hansen@linux.intel.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> mm/internal.h | 5 +++-- mm/madvise.c | 8 +++++--- mm/mlock.c | 16 ++++++++++------ mm/mmap.c | 27 +++++++++++++++++++++++---- mm/mprotect.c | 3 ++- mm/mremap.c | 3 ++- mm/nommu.c | 2 +- mm/util.c | 12 +++++++++--- 8 files changed, 55 insertions(+), 21 deletions(-) commit e10af1328b13554dee3de91b713496704cb5822e Author: Kieran Bingham <kieran@bingham.xyz> Date: Mon May 23 16:25:24 2016 -0700 MAINTAINERS: add co-maintainer for scripts/gdb Add myself as a co-maintainer for scripts/gdb supporting Jan Kizka Link: http://lkml.kernel.org/r/fb5d34ce563f33d2f324f26f592b24ded30032ee.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran@bingham.xyz> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit b3b08429857b209d8bb9785a15b8247421bf4973 Author: Kieran Bingham <kieran@bingham.xyz> Date: Mon May 23 16:25:21 2016 -0700 scripts/gdb: decode bytestream on dmesg for Python3 The recent fixes to lx-dmesg, now allow the command to print successfully on Python3, however the python interpreter wraps the bytes for each line with a b'<text>' marker. To remove this, we need to decode the line, where .decode() will default to 'UTF-8' Link: http://lkml.kernel.org/r/d67ccf93f2479c94cb3399262b9b796e0dbefcf2.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran@bingham.xyz> Acked-by: Dom Cote <buzdelabuz2@gmail.com> Tested-by: Dom Cote <buzdelabuz2@gmail.com> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/dmesg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d21d5b9eb0e1e492232a3b56d0cc03bcdaa7ee17 Author: Dom Cote <buzdelabuz2+git@gmail.com> Date: Mon May 23 16:25:19 2016 -0700 scripts/gdb: fix issue with dmesg.py and python 3.X When built against Python 3, GDB differs in the return type for its read_memory function, causing the lx-dmesg command to fail. Now that we have an improved read_16() we can use the new read_memoryview() abstraction to make lx-dmesg return valid data on both current Python APIs Tested with python 3.4 and 2.7 Tested with gdb 7.7 Link: http://lkml.kernel.org/r/28477b727ff7fe3101fd4e426060e8a68317a639.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Dom Cote <buzdelabuz2+git@gmail.com> [kieran@bingham.xyz: Adjusted commit log to better reflect code changes] Tested-by: Kieran Bingham <kieran@bingham.xyz> (Py2.7,Py3.4,GDB10) Signed-off-by: Kieran Bingham <kieran@bingham.xyz> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/dmesg.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 321958d9710c33e74ec98c0f3c96aa2a5dbe3008 Author: Dom Cote <buzdelabuz2+git@gmail.com> Date: Mon May 23 16:25:16 2016 -0700 scripts/gdb: improve types abstraction for gdb python scripts Change the read_u16 function so it accepts both 'str' and 'byte' as type for the arguments. When calling read_memory() from gdb API, depending on if it was built with 2.7 or 3.X, the format used to return the data will differ ( 'str' for 2.7, and 'byte' for 3.X ). Add a function read_memoryview() to be able to get a 'memoryview' object back from read_memory() both with python 2.7 and 3.X . Tested with python 3.4 and 2.7 Tested with gdb 7.7 Link: http://lkml.kernel.org/r/73621f564503137a002a639d174e4fb35f73f462.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Dom Cote <buzdelabuz2+git@gmail.com> Tested-by: Kieran Bingham <kieran@bingham.xyz> (Py2.7,Py3.4,GDB10) Signed-off-by: Kieran Bingham <kieran@bingham.xyz> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/utils.py | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) commit 9f66dee720984edcbc6ea07ad70fe5b8f0421c04 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:25:13 2016 -0700 scripts/gdb: add lx_thread_info_by_pid helper The tasks module already provides helpers to find the task struct by pid, and the thread_info by task struct; however this is cumbersome to utilise on the gdb commandline. Wrap these two functionalities together in an extra single helper to allow exploring the thread info, from a PID value Link: http://lkml.kernel.org/r/dadc5667f053ec811eb3e3033d99d937fedbc93b.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/tasks.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 9b5580359a844cc88bdfdbbb3a740817ba01526e Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:25:10 2016 -0700 scripts/gdb: add documentation example for radix tree Provide a worked example for utilising the lx_radix_tree_lookup function Link: http://lkml.kernel.org/r/e786008ac5aec4b84198812805b326d718bdeb4b.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Cc: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/gdb-kernel-debugging.txt | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit e127a73d41ac471d7e3ba950cf128f42d6ee3448 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:25:07 2016 -0700 scripts/gdb: add a Radix Tree Parser Linux makes use of the Radix Tree data structure to store pointers indexed by integer values. This structure is utilised across many structures in the kernel including the IRQ descriptor tables, and several filesystems. This module provides a method to lookup values from a structure given its head node. Usage: The function lx_radix_tree_lookup, must be given a symbol of type struct radix_tree_root, and an index into that tree. The object returned is a generic integer value, and must be cast correctly to the type based on the storage in the data structure. For example, to print the irq descriptor in the sparse irq_desc_tree at index 18, try the following: (gdb) print (struct irq_desc)$lx_radix_tree_lookup(irq_desc_tree, 18) Link: http://lkml.kernel.org/r/d2028c55e50cf95a9b7f8ca0d11885174b0cc709.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/constants.py.in | 7 +++ scripts/gdb/linux/radixtree.py | 97 +++++++++++++++++++++++++++++++++++++++ scripts/gdb/vmlinux-gdb.py | 1 + 3 files changed, 105 insertions(+) commit 4bc393dbcf1915224e8947211a0ca906f9de7c56 Author: Jan Kiszka <jan.kiszka@siemens.com> Date: Mon May 23 16:25:05 2016 -0700 scripts/gdb: cast CPU numbers to integer We won't see more than 2 billion CPUs any time soon, and having cpu_list return long makes the output of lx-cpus a bit ugly. Link: http://lkml.kernel.org/r/dcb45c3b0a59e0fd321fa56ff7aa398458c689b3.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/cpus.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b1503934a5e51e74b2f4c72ad77b33231e7b6953 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:25:02 2016 -0700 scripts/gdb: add cpu iterators The linux kernel provides macro's for iterating against values from the cpu_list masks. By providing some commonly used masks, we can mirror the kernels helper macros with easy to use generators. Link: http://lkml.kernel.org/r/d045c6599771ada1999d49612ee30fd2f9acf17f.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/cpus.py | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit c1a153992ea86307d2b8c3c0be2e060102b02aff Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:59 2016 -0700 scripts/gdb: add mount point list command lx-mounts will identify current mount points based on the 'init_task' namespace by default, as we do not yet have a kernel thread list implementation to select the current running thread. Optionally, a user can specify a PID to list from that process' namespace Link: http://lkml.kernel.org/r/e614c7bc32d2350b4ff1627ec761a7148e65bfe6.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/constants.py.in | 20 ++++++++ scripts/gdb/linux/proc.py | 99 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 119 insertions(+) commit e7165a2d7d87cd397d166ebf4d49763d28f5fc3d Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:56 2016 -0700 scripts/gdb: add io resource readers Provide iomem_resource and ioports_resource printers and command hooks It can be quite interesting to halt the kernel as it's booting and check to see this list as it is being populated. It should be useful in the event that a kernel is not booting, you can identify what memory resources have been registered Link: http://lkml.kernel.org/r/f0a6b9fa9c92af4d7ed2e7343ccc84150e9c6fc5.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/proc.py | 57 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit 74627cf2df50bfc29f51341578038e284796a101 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:53 2016 -0700 scripts/gdb: provide a dentry_name VFS path helper Walk the VFS entries, pre-pending the iname strings to generate a full VFS path name from a dentry. Link: http://lkml.kernel.org/r/4328fdb2d15ba7f1b21ad21c2eecc38d9cfc4d13.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/utils.py | 8 ++++++++ 1 file changed, 8 insertions(+) commit 958ef8a09a158d16cf398675c7bdfa3938472974 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:51 2016 -0700 scripts/gdb: support !CONFIG_MODULES gracefully If CONFIG_MODULES is not enabled, lx-lsmod tries to find a non-existent symbol and generates an unfriendly traceback: (gdb) lx-lsmod Address Module Size Used by Traceback (most recent call last): File "scripts/gdb/linux/modules.py", line 75, in invoke for module in module_list(): File "scripts/gdb/linux/modules.py", line 24, in module_list module_ptr_type = module_type.get_type().pointer() File "scripts/gdb/linux/utils.py", line 28, in get_type self._type = gdb.lookup_type(self._name) gdb.error: No struct type named module. Error occurred in Python command: No struct type named module. Catch the error and return an empty module_list() for a clean command output as follows: (gdb) lx-lsmod Address Module Size Used by (gdb) Link: http://lkml.kernel.org/r/94d533819437408b85ae5864f939dd7ca6fbfcd6.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/modules.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit e78f3d70b3f5b045173961cb9cda16d005ecafa7 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:48 2016 -0700 scripts/gdb: provide exception catching parser If we attempt to read a value that is not available to GDB, an exception is raised. Most of the time, this is a good thing; however on occasion we will want to be able to determine if a symbol is available. By catching the exception to simply return None, we can determine if we tried to read an invalid value, without the exception taking our execution context away from us Link: http://lkml.kernel.org/r/c72b25c06fc66e1d68371154097e2cbb112555d8.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/utils.py | 7 +++++++ 1 file changed, 7 insertions(+) commit 619ccaf3e94958485fd237000c24e06bce686bd2 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:45 2016 -0700 scripts/gdb: convert modules usage to lists functions Simplify the module list functions with the new list_for_each_entry abstractions Link: http://lkml.kernel.org/r/ad0101c9391088608166fcec26af179868973d86.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/modules.py | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit a84be61d0e38034634e7cbe076179cc6f1c16d22 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:42 2016 -0700 scripts/gdb: provide kernel list item generators Facilitate linked-list items by providing a generator to return the dereferenced, and type-cast objects from a kernel linked list Link: http://lkml.kernel.org/r/2b0998564e6e5abe53585d466f87e491331fd2a4.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Cc: Jeff Mahoney <jeffm@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/lists.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit f197d75fcad125f41cc6e2fdf1b3ea733db995f1 Author: Kieran Bingham <kieran.bingham@linaro.org> Date: Mon May 23 16:24:40 2016 -0700 scripts/gdb: provide linux constants Some macro's and defines are needed when parsing memory, and without compiling the kernel as -g3 they are not available in the debug-symbols. We use the pre-processor here to extract constants to a dedicated module for the linux debugger extensions Top level Kbuild is used to call in and generate the constants file, while maintaining dependencies on autogenerated files in include/generated Link: http://lkml.kernel.org/r/bc3df9c25f57ea72177c066a51a446fc19e2c27f.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Kieran Bingham <kieran.bingham@linaro.org> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Cc: Michal Marek <mmarek@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Kbuild | 10 ++++++++++ scripts/gdb/linux/Makefile | 12 +++++++++++- scripts/gdb/linux/constants.py.in | 32 ++++++++++++++++++++++++++++++++ scripts/gdb/vmlinux-gdb.py | 1 + 4 files changed, 54 insertions(+), 1 deletion(-) commit 0c22fde8b0e674a201f277688f1b3a38f6e09ada Author: Jan Kiszka <jan.kiszka@siemens.com> Date: Mon May 23 16:24:37 2016 -0700 scripts/gdb: Adjust module reference counter reported by lx-lsmod This takes the MODULE_REF_BASE into account. Link: http://lkml.kernel.org/r/d926d2d54caa034adb964b52215090cbdb875249.1462865983.git.jan.kiszka@siemens.com Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/gdb/linux/modules.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7efb2a7b85f2d2a53ae50e35cf5df260dd5278b7 Author: Konstantin Khlebnikov <koct9i@gmail.com> Date: Mon May 23 16:24:34 2016 -0700 arch/defconfig: remove CONFIG_RESOURCE_COUNTERS This option was replaced by PAGE_COUNTER which is selected by MEMCG. Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/arm/configs/bcm_defconfig | 1 - arch/arm/configs/zx_defconfig | 1 - arch/mips/configs/db1xxx_defconfig | 1 - arch/mips/configs/loongson3_defconfig | 1 - arch/mn10300/configs/asb2364_defconfig | 1 - arch/sh/configs/apsh4ad0a_defconfig | 1 - arch/sh/configs/sdk7786_defconfig | 1 - arch/sh/configs/se7206_defconfig | 1 - arch/sh/configs/shx3_defconfig | 1 - arch/sh/configs/urquell_defconfig | 1 - arch/tile/configs/tilegx_defconfig | 1 - arch/tile/configs/tilepro_defconfig | 1 - arch/um/configs/i386_defconfig | 1 - arch/um/configs/x86_64_defconfig | 1 - arch/x86/configs/i386_defconfig | 1 - arch/x86/configs/x86_64_defconfig | 1 - arch/xtensa/configs/generic_kc705_defconfig | 1 - arch/xtensa/configs/smp_lx200_defconfig | 1 - 18 files changed, 18 deletions(-) commit de6cdcb5ce504c9d346858569e4ad2ca3ac2fe45 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Mon May 23 16:24:31 2016 -0700 drivers/memstick/core/mspro_block: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. [akpm@linux-foundation.org: remove unneeded cast to void*] Link: http://lkml.kernel.org/r/1463665743-16269-1-git-send-email-falakreyaz@gmail.com Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/memstick/core/mspro_block.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit a831979f855f1a19db1b3b194c5fab5e04ad26ff Author: Oleksandr Natalenko <oleksandr@natalenko.name> Date: Mon May 23 16:24:28 2016 -0700 rtsx_usb_ms: use schedule_timeout_idle() in polling loop First version of this patch has already been posted to LKML by Ben Hutchings ~6 months ago, but no further action were performed. Ben's original message: : rtsx_usb_ms creates a task that mostly sleeps, but tasks in : uninterruptible sleep still contribute to the load average (for : bug-compatibility with Unix). A load average of ~1 on a system that : should be idle is somewhat alarming. : : Change the sleep to be interruptible, but still ignore signals. References: https://bugs.debian.org/765717 Link: http://lkml.kernel.org/r/b49f95ae83057efa5d96f532803cba47@natalenko.name Signed-off-by: Oleksandr Natalenko <oleksandr@natalenko.name> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Ben Hutchings <ben@decadent.org.uk> Cc: Lee Jones <lee.jones@linaro.org> Cc: Wolfram Sang <wsa@the-dreams.de> Cc: Roger Tseng <rogerable@realtek.com> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/memstick/host/rtsx_usb_ms.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a0c20deae992527ba90df9a6f87d396b7cee3922 Author: Corey Minyard <cminyard@mvista.com> Date: Mon May 23 16:24:25 2016 -0700 kdump: fix gdb macros work work with newer and 64-bit kernels Lots of little changes needed to be made to clean these up, remove the four byte pointer assumption and traverse the pid queue properly. Also consolidate the traceback code into a single function instead of having three copies of it. Link: http://lkml.kernel.org/r/1462926655-9390-1-git-send-email-minyard@acm.org Signed-off-by: Corey Minyard <cminyard@mvista.com> Acked-by: Baoquan He <bhe@redhat.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Haren Myneni <hbabu@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/kdump/gdbmacros.txt | 96 ++++++++++++++++++--------------------- 1 file changed, 44 insertions(+), 52 deletions(-) commit 7a0058ec78602da02b34fa2ae3afc523e90d1ab2 Author: Xunlei Pang <xlpang@redhat.com> Date: Mon May 23 16:24:22 2016 -0700 s390/kexec: consolidate crash_map/unmap_reserved_pages() and arch_kexec_protect(unprotect)_crashkres() Commit 3f625002581b ("kexec: introduce a protection mechanism for the crashkernel reserved memory") is a similar mechanism for protecting the crash kernel reserved memory to previous crash_map/unmap_reserved_pages() implementation, the new one is more generic in name and cleaner in code (besides, some arch may not be allowed to unmap the pgtable). Therefore, this patch consolidates them, and uses the new arch_kexec_protect(unprotect)_crashkres() to replace former crash_map/unmap_reserved_pages() which by now has been only used by S390. The consolidation work needs the crash memory to be mapped initially, this is done in machine_kdump_pm_init() which is after reserve_crashkernel(). Once kdump kernel is loaded, the new arch_kexec_protect_crashkres() implemented for S390 will actually unmap the pgtable like before. Signed-off-by: Xunlei Pang <xlpang@redhat.com> Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Acked-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Cc: Minfei Huang <mhuang@redhat.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Dave Young <dyoung@redhat.com> Cc: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/s390/kernel/machine_kexec.c | 28 ++++++++++++++++++---------- include/linux/kexec.h | 2 -- kernel/kexec.c | 12 ------------ kernel/kexec_core.c | 11 ++--------- 4 files changed, 20 insertions(+), 33 deletions(-) commit 0eea08678ebe9f7d8ef98fed974a5bf1a0dd2dd2 Author: Minfei Huang <mnfhuang@gmail.com> Date: Mon May 23 16:24:19 2016 -0700 kexec: do a cleanup for function kexec_load There are a lof of work to be done in function kexec_load, not only for allocating structs and loading initram, but also for some misc. To make it more clear, wrap a new function do_kexec_load which is used to allocate structs and load initram. And the pre-work will be done in kexec_load. Signed-off-by: Minfei Huang <mnfhuang@gmail.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Cc: Xunlei Pang <xlpang@redhat.com> Cc: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/kexec.c | 125 +++++++++++++++++++++++++++++++-------------------------- 1 file changed, 69 insertions(+), 56 deletions(-) commit 917a35605f09c0d16aeb2e92c7fbff562e19a116 Author: Minfei Huang <mnfhuang@gmail.com> Date: Mon May 23 16:24:16 2016 -0700 kexec: make a pair of map/unmap reserved pages in error path For some arch, kexec shall map the reserved pages, then use them, when we try to start the kdump service. kexec may return directly, without unmaping the reserved pages, if it fails during starting service. To fix it, we make a pair of map/unmap reserved pages both in generic path and error path. This patch only affects s390. Other architecturess don't implement the interface of crash_unmap_reserved_pages and crash_map_reserved_pages. It isn't a urgent patch. Kernel can work well without any risk, although the reserved pages are not unmapped before returning in error path. Signed-off-by: Minfei Huang <mnfhuang@gmail.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Cc: Xunlei Pang <xlpang@redhat.com> Cc: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/kexec.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 1e5768ae7500e7ce6eb73e1b263574d5c19606cf Author: Xunlei Pang <xlpang@redhat.com> Date: Mon May 23 16:24:13 2016 -0700 kexec: provide arch_kexec_protect(unprotect)_crashkres() Implement the protection method for the crash kernel memory reservation for the 64-bit x86 kdump. Signed-off-by: Xunlei Pang <xlpang@redhat.com> Cc: Eric Biederman <ebiederm@xmission.com> Cc: Dave Young <dyoung@redhat.com> Cc: Minfei Huang <mhuang@redhat.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/kernel/machine_kexec_64.c | 45 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) commit 9b492cf58077a0254eb4b9574029ac6e79add9f9 Author: Xunlei Pang <xlpang@redhat.com> Date: Mon May 23 16:24:10 2016 -0700 kexec: introduce a protection mechanism for the crashkernel reserved memory For the cases that some kernel (module) path stamps the crash reserved memory(already mapped by the kernel) where has been loaded the second kernel data, the kdump kernel will probably fail to boot when panic happens (or even not happens) leaving the culprit at large, this is unacceptable. The patch introduces a mechanism for detecting such cases: 1) After each crash kexec loading, it simply marks the reserved memory regions readonly since we no longer access it after that. When someone stamps the region, the first kernel will panic and trigger the kdump. The weak arch_kexec_protect_crashkres() is introduced to do the actual protection. 2) To allow multiple loading, once 1) was done we also need to remark the reserved memory to readwrite each time a system call related to kdump is made. The weak arch_kexec_unprotect_crashkres() is introduced to do the actual protection. The architecture can make its specific implementation by overriding arch_kexec_protect_crashkres() and arch_kexec_unprotect_crashkres(). Signed-off-by: Xunlei Pang <xlpang@redhat.com> Cc: Eric Biederman <ebiederm@xmission.com> Cc: Dave Young <dyoung@redhat.com> Cc: Minfei Huang <mhuang@redhat.com> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/kexec.h | 2 ++ kernel/kexec.c | 9 ++++++++- kernel/kexec_core.c | 6 ++++++ kernel/kexec_file.c | 8 +++++++- 4 files changed, 23 insertions(+), 2 deletions(-) commit 9eb8a659dea694b0dcbd6287f6b1fbdc523b80bc Author: Oleg Nesterov <oleg@redhat.com> Date: Mon May 23 16:24:08 2016 -0700 exec: remove the no longer needed remove_arg_zero()->free_arg_page() remove_arg_zero() does free_arg_page() for no reason. This was needed before and only if CONFIG_MMU=y: see commit 4fc75ff4816c ("exec: fix remove_arg_zero"), install_arg_page() was called for every page != NULL in bprm->page[] array. Today install_arg_page() has already gone and free_arg_page() is nop after another commit b6a2fea39318 ("mm: variable length argument support"). CONFIG_MMU=n does free_arg_pages() in free_bprm() and thus it doesn't need remove_arg_zero()->free_arg_page() too; apart from get_arg_page() it never checks if the page in bprm->page[] was allocated or not, so the "extra" non-freed page is fine. OTOH, this free_arg_page() can add the minor pessimization, the caller is going to do copy_strings_kernel() right after remove_arg_zero() which will likely need to re-allocate the same page again. And as Hujunjie pointed out, the "offset == PAGE_SIZE" check is wrong because we are going to increment bprm->p once again before return, so CONFIG_MMU=n "leaks" the page anyway if '0' is the final byte in this page. NOTE: remove_arg_zero() assumes that argv[0] is null-terminated but this is not necessarily true. copy_strings() does "len = strnlen_user(...)", then copy_from_user(len) but another thread or debuger can overwrite the trailing '0' in between. Afaics nothing really bad can happen because we must always have the null-terminated bprm->filename copied by the 1st copy_strings_kernel(), but perhaps we should change this code to check "bprm->p < bprm->exec" anyway, and/or change copy_strings() to ensure that the last byte in string is always zero. Link: http://lkml.kernel.org/r/20160517155335.GA31435@redhat.com Signed-off-by: Oleg Nesterov <oleg@redhat.com> Reported by: hujunjie <jj.net@163.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/exec.c | 7 ------- 1 file changed, 7 deletions(-) commit 725fc629ff2545b061407305ae51016c9f928fce Author: Andi Kleen <ak@linux.intel.com> Date: Mon May 23 16:24:05 2016 -0700 kernek/fork.c: allocate idle task for a CPU always on its local node Linux preallocates the task structs of the idle tasks for all possible CPUs. This currently means they all end up on node 0. This also implies that the cache line of MWAIT, which is around the flags field in the task struct, are all located in node 0. We see a noticeable performance improvement on Knights Landing CPUs when the cache lines used for MWAIT are located in the local nodes of the CPUs using them. I would expect this to give a (likely slight) improvement on other systems too. The patch implements placing the idle task in the node of its CPUs, by passing the right target node to copy_process() [akpm@linux-foundation.org: use NUMA_NO_NODE, not a bare -1] Link: http://lkml.kernel.org/r/1463492694-15833-1-git-send-email-andi@firstfloor.org Signed-off-by: Andi Kleen <ak@linux.intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/fork.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 5c8ccefdf46c5f87d87b694c7fbc04941c2c99a5 Author: Oleg Nesterov <oleg@redhat.com> Date: Mon May 23 16:24:02 2016 -0700 signal: move the "sig < SIGRTMIN" check into siginmask(sig) All the users of siginmask() must ensure that sig < SIGRTMIN. sig_fatal() doesn't and this is wrong: UBSAN: Undefined behaviour in kernel/signal.c:911:6 shift exponent 32 is too large for 32-bit type 'long unsigned int' the patch doesn't add the neccesary check to sig_fatal(), it moves the check into siginmask() and updates other callers. Link: http://lkml.kernel.org/r/20160517195052.GA15187@redhat.com Reported-by: Meelis Roos <mroos@linux.ee> Signed-off-by: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/signal.h | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) commit 747800efbe8b98459f48d1d9d742298f8283f8fa Author: Wang Xiaoqiang <wangxq10@lzu.edu.cn> Date: Mon May 23 16:23:59 2016 -0700 kernel/signal.c: convert printk(KERN_<LEVEL> ...) to pr_<level>(...) Use pr_<level> instead of printk(KERN_<LEVEL> ). Signed-off-by: Wang Xiaoqiang <wangxq10@lzu.edu.cn> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/signal.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit c96fc2d85f4a827e3bb2abe7de2394a1fb8a0fe7 Author: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Date: Mon May 23 16:23:57 2016 -0700 signal: make oom_flags a bool Currently the size of "struct signal_struct"->oom_flags member is sizeof(unsigned) bytes, but only one flag OOM_FLAG_ORIGIN which is updated by current thread is defined. We can convert OOM_FLAG_ORIGIN into a bool, and reuse the saved bytes for updating from the OOM killer and/or the OOM reaper thread. By the way, do we care about a race window between run_store() and swapoff() because it would be theoretically possible that two threads sharing the "struct signal_struct" concurrently call respective functions? If we care, we can make oom_flags an atomic_t. Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Hugh Dickins <hughd@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/oom.h | 9 +++------ include/linux/sched.h | 6 +++++- include/linux/types.h | 1 - 3 files changed, 8 insertions(+), 8 deletions(-) commit 91c4e8ea8f05916df0c8a6f383508ac7c9e10dba Author: Oleg Nesterov <oleg@redhat.com> Date: Mon May 23 16:23:53 2016 -0700 wait: allow sys_waitid() to accept __WNOTHREAD/__WCLONE/__WALL I see no reason why waitid() can't support other linux-specific flags allowed in sys_wait4(). In particular this change can help if we reconsider the previous change ("wait/ptrace: assume __WALL if the child is traced") which adds the "automagical" __WALL for debugger. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Jan Kratochvil <jan.kratochvil@redhat.com> Cc: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com> Cc: Pedro Alves <palves@redhat.com> Cc: Roland McGrath <roland@hack.frob.com> Cc: <syzkaller@googlegroups.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/exit.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit bf959931ddb88c4e4366e96dd22e68fa0db9527c Author: Oleg Nesterov <oleg@redhat.com> Date: Mon May 23 16:23:50 2016 -0700 wait/ptrace: assume __WALL if the child is traced The following program (simplified version of generated by syzkaller) #include <pthread.h> #include <unistd.h> #include <sys/ptrace.h> #include <stdio.h> #include <signal.h> void *thread_func(void *arg) { ptrace(PTRACE_TRACEME, 0,0,0); return 0; } int main(void) { pthread_t thread; if (fork()) return 0; while (getppid() != 1) ; pthread_create(&thread, NULL, thread_func, NULL); pthread_join(thread, NULL); return 0; } creates an unreapable zombie if /sbin/init doesn't use __WALL. This is not a kernel bug, at least in a sense that everything works as expected: debugger should reap a traced sub-thread before it can reap the leader, but without __WALL/__WCLONE do_wait() ignores sub-threads. Unfortunately, it seems that /sbin/init in most (all?) distributions doesn't use it and we have to change the kernel to avoid the problem. Note also that most init's use sys_waitid() which doesn't allow __WALL, so the necessary user-space fix is not that trivial. This patch just adds the "ptrace" check into eligible_child(). To some degree this matches the "tsk->ptrace" in exit_notify(), ->exit_signal is mostly ignored when the tracee reports to debugger. Or WSTOPPED, the tracer doesn't need to set this flag to wait for the stopped tracee. This obviously means the user-visible change: __WCLONE and __WALL no longer have any meaning for debugger. And I can only hope that this won't break something, but at least strace/gdb won't suffer. We could make a more conservative change. Say, we can take __WCLONE into account, or !thread_group_leader(). But it would be nice to not complicate these historical/confusing checks. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Reported-by: Dmitry Vyukov <dvyukov@google.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Jan Kratochvil <jan.kratochvil@redhat.com> Cc: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com> Cc: Pedro Alves <palves@redhat.com> Cc: Roland McGrath <roland@hack.frob.com> Cc: <syzkaller@googlegroups.com> Cc: <stable@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/exit.c | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) commit 076a378ba6e6b6ddd5f2336aa0876349b7d36409 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:48 2016 -0700 nilfs2: fix block comments This fixes block comments with proper formatting to eliminate the following checkpatch.pl warnings: "WARNING: Block comments use * on subsequent lines" "WARNING: Block comments use a trailing */ on a separate line" Link: http://lkml.kernel.org/r/1462886671-3521-8-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/alloc.c | 12 +++++--- fs/nilfs2/bmap.h | 12 +++++--- fs/nilfs2/cpfile.c | 6 ++-- fs/nilfs2/ifile.c | 6 ++-- fs/nilfs2/inode.c | 73 ++++++++++++++++++++++++++++++----------------- fs/nilfs2/nilfs.h | 24 ++++++++++------ fs/nilfs2/recovery.c | 14 +++++---- fs/nilfs2/segment.c | 56 ++++++++++++++++++++++++------------ fs/nilfs2/segment.h | 34 ++++++++++++++-------- fs/nilfs2/the_nilfs.c | 6 ++-- include/linux/nilfs2_fs.h | 66 +++++++++++++++++++++++++++--------------- 11 files changed, 202 insertions(+), 107 deletions(-) commit 80d6505232ec2476eef8d988ea98ac81eb2e0975 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:45 2016 -0700 nilfs2: remove loops of single statement macros This fixes checkpatch.pl warning "WARNING: Single statement macros should not use a do {} while (0) loop". Link: http://lkml.kernel.org/r/1462886671-3521-7-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/the_nilfs.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 7f00184e9cb534aca1f10f3027cb6137b03f101e Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:42 2016 -0700 nilfs2: remove unnecessary else after return or break This fixes the checkpatch.pl warning that suggests else is not generally useful after a break or return. Link: http://lkml.kernel.org/r/1462886671-3521-6-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/btree.c | 12 ++++++------ fs/nilfs2/direct.c | 6 +++--- fs/nilfs2/segment.c | 26 ++++++++++++-------------- 3 files changed, 21 insertions(+), 23 deletions(-) commit 0c6c44cb9f93f7c0ad803b41ae7c0b08cf6942e2 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:39 2016 -0700 nilfs2: avoid bare use of 'unsigned' This fixes checkpatch.pl warning "WARNING: Prefer 'unsigned int' to bare use of 'unsigned'". Link: http://lkml.kernel.org/r/1462886671-3521-5-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/alloc.c | 8 ++++---- fs/nilfs2/alloc.h | 2 +- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/bmap.h | 4 ++-- fs/nilfs2/btree.c | 3 ++- fs/nilfs2/cpfile.c | 8 +++++--- fs/nilfs2/cpfile.h | 4 ++-- fs/nilfs2/dat.c | 2 +- fs/nilfs2/dat.h | 2 +- fs/nilfs2/dir.c | 47 ++++++++++++++++++++++++----------------------- fs/nilfs2/direct.c | 5 +++-- fs/nilfs2/inode.c | 14 +++++++------- fs/nilfs2/mdt.c | 4 ++-- fs/nilfs2/mdt.h | 6 +++--- fs/nilfs2/namei.c | 2 +- fs/nilfs2/nilfs.h | 2 +- fs/nilfs2/page.c | 8 ++++---- fs/nilfs2/page.h | 3 ++- fs/nilfs2/recovery.c | 4 ++-- fs/nilfs2/segbuf.c | 4 ++-- fs/nilfs2/segbuf.h | 5 +++-- fs/nilfs2/segment.c | 18 +++++++++--------- fs/nilfs2/segment.h | 4 ++-- fs/nilfs2/sysfs.c | 6 +++--- fs/nilfs2/the_nilfs.c | 4 ++-- fs/nilfs2/the_nilfs.h | 10 +++++----- include/linux/nilfs2_fs.h | 6 +++--- 27 files changed, 97 insertions(+), 90 deletions(-) commit 7592ecde65f908f082cfd3440888fd6ae99f4cbb Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:36 2016 -0700 nilfs2: fix code indent coding style issue This fixes checkpatch.pl warning "WARNING: suspect code indent for conditional statements". Link: http://lkml.kernel.org/r/1462886671-3521-4-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c9cb9b5c85265acf3e40118727630fd3d57a0bdb Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:34 2016 -0700 nilfs2: remove space before semicolon This fixes the checkpatch.pl warning "WARNING: space prohibited before semicolon" at nilfs_store_magic_and_option(). Link: http://lkml.kernel.org/r/1462886671-3521-3-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 06f4abf6ca9364cdbbfac5b6e0fb1a5bf3468195 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:31 2016 -0700 nilfs2: do not emit extra newline on nilfs_warning() and nilfs_error() This updates call sites of nilfs_warning() and nilfs_error() so that they don't add a duplicate newline. These output functions are already designed to add a trailing newline to the message. Link: http://lkml.kernel.org/r/1462886671-3521-2-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/alloc.c | 10 +++++----- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/dir.c | 4 ++-- fs/nilfs2/inode.c | 6 +++--- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 8 ++++---- 6 files changed, 16 insertions(+), 16 deletions(-) commit facb9ec5e6e376c25a00bb7a64332287c7a1403c Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:28 2016 -0700 nilfs2: clean trailing semicolons in macros Remove trailing semicolons from macros, as suggested by checkpatch.pl. Link: http://lkml.kernel.org/r/1461935747-10380-12-git-send-email-konishi.ryusuke@lab.ntt.co.jp [konishi.ryusuke@lab.ntt.co.jp: fix style issues] Link: http://lkml.kernel.org/r/20160509.231703.1481729973362188932.konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/sysfs.c | 4 ++-- fs/nilfs2/sysfs.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) commit 4ad364ca1ce3f4f96e04aaeb7974de4380eb6004 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:25 2016 -0700 nilfs2: add missing line spacing Clean up checkpatch.pl warnings "WARNING: Missing a blank line after declarations" from nilfs2. Link: http://lkml.kernel.org/r/1461935747-10380-11-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/cpfile.c | 2 ++ fs/nilfs2/dir.c | 2 ++ fs/nilfs2/ifile.h | 1 + fs/nilfs2/inode.c | 1 + fs/nilfs2/namei.c | 1 + fs/nilfs2/recovery.c | 1 + fs/nilfs2/segment.c | 1 + fs/nilfs2/sufile.c | 2 ++ fs/nilfs2/super.c | 1 + fs/nilfs2/the_nilfs.h | 2 ++ 10 files changed, 14 insertions(+) commit e7a142aaa09fa5db015fd176d6943f888665829f Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:23 2016 -0700 nilfs2: replace __attribute__((packed)) with __packed This fixes the following checkpatch.pl warning: WARNING: __packed is preferred over __attribute__((packed)) #23: FILE: export.h:23: +} __attribute__ ((packed)); Link: http://lkml.kernel.org/r/1461935747-10380-10-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/export.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d19961d83524c69e44f179b43aee2daf0906eda Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:20 2016 -0700 nilfs2: move cleanup code of metadata file from inode routines Refactor nilfs_clear_inode() and nilfs_i_callback() so that cleanup code or resource deallocation related to metadata file will be moved out to mdt.c. Link: http://lkml.kernel.org/r/1461935747-10380-9-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/inode.c | 5 ++--- fs/nilfs2/mdt.c | 25 +++++++++++++++++++++++++ fs/nilfs2/mdt.h | 8 ++++++++ fs/nilfs2/super.c | 8 +++----- 4 files changed, 38 insertions(+), 8 deletions(-) commit 24e20ead2fb2e1b67a76a04550d29c9027f707eb Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:17 2016 -0700 nilfs2: get rid of nilfs_mdt_mark_block_dirty() nilfs_mdt_mark_block_dirty() can be replaced with primary functions like nilfs_mdt_get_block() and mark_buffer_dirty(), and it's used only by nilfs_ioctl_mark_blocks_dirty(). This gets rid of the function to simplify the interface of metadata file. Link: http://lkml.kernel.org/r/1461935747-10380-8-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/ioctl.c | 11 ++++++++--- fs/nilfs2/mdt.c | 28 ---------------------------- fs/nilfs2/mdt.h | 1 - 3 files changed, 8 insertions(+), 32 deletions(-) commit 756cbdb353c597dd265f070527b5ee9901f35261 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:14 2016 -0700 nilfs2: clarify permission to replicate the design To respond to a certain developer's request, this explicitly state that developers can reimplement the nilfs2 design for other operating systems to share data stored in that format. Link: http://lkml.kernel.org/r/1461935747-10380-7-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/filesystems/nilfs2.txt | 5 +++++ 1 file changed, 5 insertions(+) commit 9e92e516ed4321b7c96206d92a21d6a36249f680 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:11 2016 -0700 MAINTAINERS: add web link for nilfs project Add nilfs.osdn.jp as the second web site of nilfs project. Link: http://lkml.kernel.org/r/1461935747-10380-6-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 4b420ab4eedc7a816ad0f2278871019de1a8ccef Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:09 2016 -0700 nilfs2: clean up old e-mail addresses E-mail addresses of osrg.net domain are no longer available. This removes them from authorship notices and prevents reporters from being confused. Link: http://lkml.kernel.org/r/1461935747-10380-5-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/alloc.c | 5 ++--- fs/nilfs2/alloc.h | 5 ++--- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/bmap.h | 2 +- fs/nilfs2/btnode.c | 5 ++--- fs/nilfs2/btnode.h | 4 ++-- fs/nilfs2/btree.c | 2 +- fs/nilfs2/btree.h | 2 +- fs/nilfs2/cpfile.c | 2 +- fs/nilfs2/cpfile.h | 2 +- fs/nilfs2/dat.c | 2 +- fs/nilfs2/dat.h | 2 +- fs/nilfs2/dir.c | 2 +- fs/nilfs2/direct.c | 2 +- fs/nilfs2/direct.h | 2 +- fs/nilfs2/file.c | 3 +-- fs/nilfs2/gcinode.c | 5 ++--- fs/nilfs2/ifile.c | 4 ++-- fs/nilfs2/ifile.h | 4 ++-- fs/nilfs2/inode.c | 2 +- fs/nilfs2/ioctl.c | 2 +- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/mdt.h | 2 +- fs/nilfs2/namei.c | 3 +-- fs/nilfs2/nilfs.h | 3 +-- fs/nilfs2/page.c | 3 +-- fs/nilfs2/page.h | 3 +-- fs/nilfs2/recovery.c | 2 +- fs/nilfs2/segbuf.c | 2 +- fs/nilfs2/segbuf.h | 2 +- fs/nilfs2/segment.c | 2 +- fs/nilfs2/segment.h | 2 +- fs/nilfs2/sufile.c | 4 ++-- fs/nilfs2/sufile.h | 2 +- fs/nilfs2/super.c | 2 +- fs/nilfs2/the_nilfs.c | 2 +- fs/nilfs2/the_nilfs.h | 2 +- include/linux/nilfs2_fs.h | 3 +-- 38 files changed, 46 insertions(+), 56 deletions(-) commit 5726d0b454614a47e641a04c8106392d67a8e1ad Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:06 2016 -0700 nilfs2: remove FSF mailing address from GPL notices This removes the extra paragraph which mentions FSF address in GPL notices from source code of nilfs2 and avoids the checkpatch.pl error related to it. Link: http://lkml.kernel.org/r/1461935747-10380-4-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/alloc.c | 4 ---- fs/nilfs2/alloc.h | 4 ---- fs/nilfs2/bmap.c | 4 ---- fs/nilfs2/bmap.h | 4 ---- fs/nilfs2/btnode.c | 4 ---- fs/nilfs2/btnode.h | 4 ---- fs/nilfs2/btree.c | 4 ---- fs/nilfs2/btree.h | 4 ---- fs/nilfs2/cpfile.c | 4 ---- fs/nilfs2/cpfile.h | 4 ---- fs/nilfs2/dat.c | 4 ---- fs/nilfs2/dat.h | 4 ---- fs/nilfs2/dir.c | 4 ---- fs/nilfs2/direct.c | 4 ---- fs/nilfs2/direct.h | 4 ---- fs/nilfs2/file.c | 4 ---- fs/nilfs2/gcinode.c | 4 ---- fs/nilfs2/ifile.c | 4 ---- fs/nilfs2/ifile.h | 4 ---- fs/nilfs2/inode.c | 4 ---- fs/nilfs2/ioctl.c | 4 ---- fs/nilfs2/mdt.c | 4 ---- fs/nilfs2/mdt.h | 4 ---- fs/nilfs2/namei.c | 4 ---- fs/nilfs2/nilfs.h | 4 ---- fs/nilfs2/page.c | 4 ---- fs/nilfs2/page.h | 4 ---- fs/nilfs2/recovery.c | 4 ---- fs/nilfs2/segbuf.c | 4 ---- fs/nilfs2/segbuf.h | 4 ---- fs/nilfs2/segment.c | 4 ---- fs/nilfs2/segment.h | 4 ---- fs/nilfs2/sufile.c | 4 ---- fs/nilfs2/sufile.h | 4 ---- fs/nilfs2/super.c | 4 ---- fs/nilfs2/the_nilfs.c | 4 ---- fs/nilfs2/the_nilfs.h | 4 ---- include/linux/nilfs2_fs.h | 4 ---- 38 files changed, 152 deletions(-) commit f19e78dee9d5adc90af086175f8e3640da3f613c Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:03 2016 -0700 nilfs2: remove space before comma Fix checkpatch.pl error "ERROR: space prohibited before that ',' (ctx:WxW)" at nilfs_sufile_set_suinfo(). This also fixes checkpatch.pl warning "WARNING: Prefer 'unsigned int' to bare use of 'unsigned'" at nilfs_sufile_set_suinfo() and nilfs_sufile_get_suinfo(). Link: http://lkml.kernel.org/r/1461935747-10380-3-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/sufile.c | 4 ++-- fs/nilfs2/sufile.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 8fa7c32094d806c23b35f9f51bcefb3148d3eb54 Author: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Date: Mon May 23 16:23:00 2016 -0700 nilfs2: fix white space issue in nilfs_mount() Fix the following checkpatch.pl error and warnings: ERROR: code indent should use tabs where possible #1317: FILE: super.c:1317: + ^I^Is_new = true;$ WARNING: please, no space before tabs #1317: FILE: super.c:1317: + ^I^Is_new = true;$ WARNING: please, no spaces at the start of a line #1317: FILE: super.c:1317: + ^I^Is_new = true;$ Link: http://lkml.kernel.org/r/1461935747-10380-2-git-send-email-konishi.ryusuke@lab.ntt.co.jp Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1c613cb9868359031eb1344a33ac661908804bab Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Mon May 23 16:22:57 2016 -0700 nilfs2: constify nilfs_sc_operations structures The nilfs_sc_operations structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/nilfs2/segment.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit a46d8c3fc7f520632e773ff51209e98770a56846 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:55 2016 -0700 fs/befs/io.c:befs_bread(): remove unneeded initialization to NULL bh is reinitialized by sb_bread() so no need to init it with NULL in the beginning of befs_bread() Link: http://lkml.kernel.org/r/88481760b43226fac16adb1f1e68897e47d8235c.1462841692.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 77169af8b90c96ac40e49ba45da6520dcccf5d8e Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:52 2016 -0700 fs/befs/io.c:befs_bread_iaddr(): remove unneeded initialization to NULL bh is reinitialized by sb_bread() so no need to init it with NULL in the beginning of befs_bread_iaddr() Link: http://lkml.kernel.org/r/586d2639d729345b9c07aac10ba713d8ceb8745a.1462841692.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d6e0203369ec2f9425e6d6e7ced7b365f5b97bf3 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:49 2016 -0700 fs/befs/linuxvfs.c:befs_iget(): remove unneeded befs_nio initialization to NULL befs_ino is reinitialized by BEFS_I() so no need to init it with NULL in the beginning of befs_iget() Link: http://lkml.kernel.org/r/a5c02445e436629c4d4ba1b65d91501878942f58.1462842887.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/linuxvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44ad809865299c7c961161c45094e1bb3a12eaa0 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:46 2016 -0700 fs/befs/linuxvfs.c:befs_iget(): remove unneeded raw_inode initialization to NULL raw_inode is reinitialized to bh->b_data so no need to init it with NULL in the beginning of befs_iget() Link: http://lkml.kernel.org/r/0a66baaaacb6b7e5fcea5b31b57b649261152281.1462842887.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/linuxvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e4c7f5b10931595097815c9d36e041efb49a42c7 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:43 2016 -0700 fs/befs/linuxvfs.c:befs_iget(): remove unneeded initialization to NULL bh is reinitialized by befs_bread() so no need to init it with NULL in the beginning of befs_iget() Link: http://lkml.kernel.org/r/38d62b1469bc3b316ba6b81fd8e26fc66fdd713b.1462842886.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/linuxvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c940876368982afa9c5413f23bf70766dbfa8ac0 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:40 2016 -0700 fs/befs/linuxvfs.c:befs_get_block(): remove unneeded initialization to NULL inode is reinitialized by befs_iget() so no need to init it with NULL in the beginning of befs_lookup() Link: http://lkml.kernel.org/r/03d7e46890aef94078130bed97c4f8f8ae9ea2b2.1462842886.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/linuxvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6c8da24b903851656dc565e8d2336b72a35efe14 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:38 2016 -0700 fs/befs/datastream.c:befs_find_brun_dblindirect(): remove unneeded initializations to NULL iaddr_array is unconditionally initialized to NULL in befs_find_brun_dblindirect(). Link: http://lkml.kernel.org/r/940def273e30ef37957fba9da6981a10fb3c9741.1462649034.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/datastream.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 3080ea9e5bb4cb337b7f061a085645b9dabf365f Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:35 2016 -0700 fs/befs/datastream.c:befs_read_lsymlink(): remove unneeded initialization to NULL bh is reinitialized by befs_read_datastream() so no need to init it with NULL in the beginning of befs_read_lsymlink(). Link: http://lkml.kernel.org/r/e22f279bceb8d026af048952e02ba98925b21c92.1462649034.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/datastream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ff2fe0aa2e17ff78c676d9c450b819c8b87af801 Author: Salah Triki <salah.triki@acm.org> Date: Mon May 23 16:22:32 2016 -0700 fs/befs/datastream.c:befs_read_datastream(): remove unneeded initialization to NULL bh is reinitialized by befs_bread_iaddr() so no need to init it with NULL in the beginning of befs_read_datastream(). Link: http://lkml.kernel.org/r/81e1f70187db34d195c8e42b1ff78be6a71c0060.1462649034.git.salah.triki@acm.org Signed-off-by: Salah Triki <salah.triki@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/befs/datastream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1383399d7be029281997889df23150fa6c16be6e Author: Vladimir Davydov <vdavydov@virtuozzo.com> Date: Mon May 23 16:22:29 2016 -0700 mm: memcontrol: fix possible css ref leak on oom mem_cgroup_oom may be invoked multiple times while a process is handling a page fault, in which case current->memcg_in_oom will be overwritten leaking the previously taken css reference. Link: http://lkml.kernel.org/r/1464019330-7579-1-git-send-email-vdavydov@virtuozzo.com Signed-off-by: Vladimir Davydov <vdavydov@virtuozzo.com> Acked-by: 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> mm/memcontrol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f43edca7ed08fc02279f2a62015da5cb6aa0ad61 Author: Ralf Baechle <ralf@linux-mips.org> Date: Mon May 23 16:22:26 2016 -0700 ELF/MIPS build fix CONFIG_MIPS32_N32=y but CONFIG_BINFMT_ELF disabled results in the following linker errors: arch/mips/built-in.o: In function `elf_core_dump': binfmt_elfn32.c:(.text+0x23dbc): undefined reference to `elf_core_extra_phdrs' binfmt_elfn32.c:(.text+0x246e4): undefined reference to `elf_core_extra_data_size' binfmt_elfn32.c:(.text+0x248d0): undefined reference to `elf_core_write_extra_phdrs' binfmt_elfn32.c:(.text+0x24ac4): undefined reference to `elf_core_write_extra_data' CONFIG_MIPS32_O32=y but CONFIG_BINFMT_ELF disabled results in the following linker errors: arch/mips/built-in.o: In function `elf_core_dump': binfmt_elfo32.c:(.text+0x28a04): undefined reference to `elf_core_extra_phdrs' binfmt_elfo32.c:(.text+0x29330): undefined reference to `elf_core_extra_data_size' binfmt_elfo32.c:(.text+0x2951c): undefined reference to `elf_core_write_extra_phdrs' binfmt_elfo32.c:(.text+0x29710): undefined reference to `elf_core_write_extra_data' This is because binfmt_elfn32 and binfmt_elfo32 are using symbols from elfcore but for these configurations elfcore will not be built. Fixed by making elfcore selectable by a separate config symbol which unlike the current mechanism can also be used from other directories than kernel/, then having each flavor of ELF that relies on elfcore.o, select it in Kconfig, including CONFIG_MIPS32_N32 and CONFIG_MIPS32_O32 which fixes this issue. Link: http://lkml.kernel.org/r/20160520141705.GA1913@linux-mips.org Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: "Maciej W. Rozycki" <macro@linux-mips.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/mips/Kconfig | 1 + fs/Kconfig.binfmt | 8 ++++++++ kernel/Makefile | 4 +--- 3 files changed, 10 insertions(+), 3 deletions(-) commit ededb49a9aa54960fce35c705d505d409f5b5483 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Mon May 23 16:22:23 2016 -0700 m32r: fix build failure m32r allmodconfig build was failing with the error: ERROR: "smp_flush_cache_all" [drivers/misc/lkdtm.ko] undefined! lkdtm driver at drivers/misc is using flush_icache_range() which for m32r is defined as smp_flush_cache_all() if CONFIG_SMP is defined. But as smp_flush_cache_all() was not exported so the build was failing with the error of undefined symbol. Link: http://lkml.kernel.org/r/1464001182-8329-1-git-send-email-sudipm.mukherjee@gmail.com Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/m32r/kernel/smp.c | 1 + 1 file changed, 1 insertion(+) commit 54b9430f04b0be3beb7f2711152c61e7d39c58e5 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon May 23 13:19:35 2016 +0300 qed: signedness bug in qed_dcbx_process_tlv() "priority" needs to be signed for the error handling to work. Fixes: 39651abd2814 ('qed: add support for dcbx.') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 612bacad78ba6d0a91166fc4487af114bac172a8 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Sun May 22 23:16:18 2016 +0200 bpf, inode: disallow userns mounts Follow-up to commit e27f4a942a0e ("bpf: Use mount_nodev not mount_ns to mount the bpf filesystem"), which removes the FS_USERNS_MOUNT flag. The original idea was to have a per mountns instance instead of a single global fs instance, but that didn't work out and we had to switch to mount_nodev() model. The intent of that middle ground was that we avoid users who don't play nice to create endless instances of bpf fs which are difficult to control and discover from an admin point of view, but at the same time it would have allowed us to be more flexible with regard to namespaces. Therefore, since we now did the switch to mount_nodev() as a fix where individual instances are created, we also need to remove userns mount flag along with it to avoid running into mentioned situation. I don't expect any breakage at this early point in time with removing the flag and we can revisit this later should the requirement for this come up with future users. This and commit e27f4a942a0e have been split to facilitate tracking should any of them run into the unlikely case of causing a regression. Fixes: b2197755b263 ("bpf: add support for persistent maps/progs") Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/inode.c | 1 - 1 file changed, 1 deletion(-) commit 156f4fbcc2bd1ce38da483f932d3963ba9a79ad0 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:06:09 2016 +0200 MAINTAINERS: Add file patterns for net device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: David S. Miller <davem@davemloft.net> Cc: netdev@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 5fece5ad24ab5b57f51f3f18bc9332545ea8705a Author: Helge Deller <deller@gmx.de> Date: Mon May 23 23:23:26 2016 +0200 parisc: Use long jump to reach ftrace_return_to_handler() Depending on config options we will need to use a long jump to reach ftrace_return_to_handler(). Additionally only compile the parisc_return_to_handler code when CONFIG_FUNCTION_GRAPH_TRACER is set. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/kernel/entry.S | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 049bbf589ec651685205bd8ce73221fdd62345cf Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Fri May 20 13:21:10 2016 -0300 ipv4: Fix non-initialized TTL when CONFIG_SYSCTL=n Commit fa50d974d104 ("ipv4: Namespaceify ip_default_ttl sysctl knob") moves the default TTL assignment, and as side-effect IPv4 TTL now has a default value only if sysctl support is enabled (CONFIG_SYSCTL=y). The sysctl_ip_default_ttl is fundamental for IP to work properly, as it provides the TTL to be used as default. The defautl TTL may be used in ip_selected_ttl, through the following flow: ip_select_ttl ip4_dst_hoplimit net->ipv4.sysctl_ip_default_ttl This commit fixes the issue by assigning net->ipv4.sysctl_ip_default_ttl in net_init_net, called during ipv4's initialization. Without this commit, a kernel built without sysctl support will send all IP packets with zero TTL (unless a TTL is explicitly set, e.g. with setsockopt). Given a similar issue might appear on the other knobs that were namespaceify, this commit also moves them. Fixes: fa50d974d104 ("ipv4: Namespaceify ip_default_ttl sysctl knob") Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/af_inet.c | 8 ++++++++ net/ipv4/sysctl_net_ipv4.c | 4 ---- 2 files changed, 8 insertions(+), 4 deletions(-) commit 3a62a7b8200a177ad96161e4f2678514e6ee301e Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 23 07:13:41 2016 +0000 perf record: Read from backward ring buffer Introduce rb_find_range() to find start and end position from a backward ring buffer. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463987628-163563-5-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 52 +++++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/evlist.c | 1 + tools/perf/util/evlist.h | 1 + 3 files changed, 54 insertions(+) commit 09fa4f401296f555afb6f2f4282717644d94722e Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 23 07:13:40 2016 +0000 perf record: Rename variable to make code clear record__mmap_read() writes data from ring buffer into perf.data. 'head' is maintained by the kernel, points to the last written record. 'old' is maintained by perf, points to the record read in previous round. record__mmap_read() saves data from 'old' to 'head' to perf.data. The names of these variables are not very intutive. In addition, when dealing with backward writing ring buffer, the md->prev pointer should point to 'head' instead of the last byte it got. Add 'start' and 'end' pointer to make code clear and set md->prev to 'head' instead of the moved 'old' pointer. This patch doesn't change behavior since: buf = &data[old & md->mask]; size = head - old; old += size; <--- Here, old == head Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463987628-163563-4-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit 2d11c65071d489e20b3a811167507939dd8c2eac Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 23 07:13:39 2016 +0000 perf record: Prevent reading invalid data in record__mmap_read When record__mmap_read() requires data more than the size of ring buffer, drop those data to avoid accessing invalid memory. This can happen when reading from overwritable ring buffer, which should be avoided. However, check this for robustness. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463987628-163563-3-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 65aea2338765da1a58cc26eeb84d72308492ecb5 Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 23 07:13:38 2016 +0000 perf evlist: Add API to pause/resume perf_evlist__toggle_{pause,resume}() are introduced to pause/resume events in an evlist. Utilize PERF_EVENT_IOC_PAUSE_OUTPUT ioctl. Following commits use them to ensure overwrite ring buffer is paused before reading. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463987628-163563-2-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Return -1, like all other ioctl() usage in evlist.c, rename 'pause' arg to avoid breaking the build on ubuntu 12.04 and other old systems ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 27 +++++++++++++++++++++++++++ tools/perf/util/evlist.h | 2 ++ 2 files changed, 29 insertions(+) commit 2ece068e1b1d6e76ecd07e04b027013e931287ff Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Fri May 20 17:51:02 2016 +0530 ptp: use memdup_user(). Use memdup_user to duplicate a memory region from user-space to kernel-space, instead of open coding using kmalloc & copy_from_user. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Acked-by: Richard Cochran <richardcochran@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/ptp/ptp_chardev.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) commit 8da07a393f48864a87c61bb1dfbee640d9b97fd6 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Thu May 19 21:20:55 2016 +0200 net: hns: avoid null pointer dereference In the statement assert(priv || priv->ae_handle); the right side of || is only evaluated if priv is null. v2: As suggested by David Leight and David Miller the assert statements are removed. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ethtool.c | 11 ----------- 1 file changed, 11 deletions(-) commit c685293aa379b9d17e44fcc2f96a402b7648e838 Author: Stefan Hajnoczi <stefanha@redhat.com> Date: Wed May 18 17:42:13 2016 -0700 net/atm: sk_err_soft must be positive The sk_err and sk_err_soft fields are positive errno values and userspace applications rely on this when using getsockopt(SO_ERROR). ATM code places an -errno into sk_err_soft in sigd_send() and returns it from svc_addparty()/svc_dropparty(). Although I am not familiar with ATM code I came to this conclusion because: 1. sigd_send() msg->type cases as_okay and as_error both have: sk->sk_err = -msg->reply; while the as_addparty and as_dropparty cases have: sk->sk_err_soft = msg->reply; This is the source of the inconsistency. 2. svc_addparty() returns an -errno and assumes sk_err_soft is also an -errno: if (flags & O_NONBLOCK) { error = -EINPROGRESS; goto out; } ... error = xchg(&sk->sk_err_soft, 0); out: release_sock(sk); return error; This shows that sk_err_soft is indeed being treated as an -errno. This patch ensures that sk_err_soft is always a positive errno. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/atm/signaling.c | 2 +- net/atm/svc.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit bbf178e0a0a323d896611905718db112b1ab1807 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Wed May 18 20:40:51 2016 +0200 net: pegasus: simplify logical constraint If !count is true, count < 4 is also true. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/pegasus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 12f3ca4fc8e27aa602c9c3c717d755b1e8f7fd47 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon May 23 16:37:55 2016 -0300 perf trace: Use the ptr->name beautifier as default for "filename" args Auto-attach the ptr->name beautifier to syscall args "filename", "path" and "pathname" if they are of type "const char *". Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-jxii4qmcgoppftv0zdvml9d7@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 120 ++++++++++++++++----------------------------- 1 file changed, 43 insertions(+), 77 deletions(-) commit b6565c908ad7eb28dfdda9578ec5a074e080cedc Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon May 23 12:59:53 2016 -0300 perf trace: Use the fd->name beautifier as default for "fd" args Noticed when the 'setsockopt' 'fd' arg wasn't being formatted via the SCA_FD beautifier, so just remove the setting of "fd" args to SCA_FD and do it when reading the syscall info, like we do for args of type "pid_t", i.e. "fd" as the name should be enough as the decision to use the SFA_FD beautifier. For odd cases we can just do it explicitely. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-0qissgetiuqmqyj4b6ancmpn@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 132 +++++++++++++++++++-------------------------- 1 file changed, 54 insertions(+), 78 deletions(-) commit 1d6da87a3241deb13d073c4125d19ed0e5a0c62c Merge: 1f40c49 a39ed68 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 11:48:48 2016 -0700 Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux Pull drm updates from Dave Airlie: "Here's the main drm pull request for 4.7, it's been a busy one, and I've been a bit more distracted in real life this merge window. Lots more ARM drivers, not sure if it'll ever end. I think I've at least one more coming the next merge window. But changes are all over the place, support for AMD Polaris GPUs is in here, some missing GM108 support for nouveau (found in some Lenovos), a bunch of MST and skylake fixes. I've also noticed a few fixes from Arnd in my inbox, that I'll try and get in asap, but I didn't think they should hold this up. New drivers: - Hisilicon kirin display driver - Mediatek MT8173 display driver - ARC PGU - bitstreamer on Synopsys ARC SDP boards - Allwinner A13 initial RGB output driver - Analogix driver for DisplayPort IP found in exynos and rockchip DRM Core: - UAPI headers fixes and C++ safety - DRM connector reference counting - DisplayID mode parsing for Dell 5K monitors - Removal of struct_mutex from drivers - Connector registration cleanups - MST robustness fixes - MAINTAINERS updates - Lockless GEM object freeing - Generic fbdev deferred IO support panel: - Support for a bunch of new panels i915: - VBT refactoring - PLL computation cleanups - DSI support for BXT - Color manager support - More atomic patches - GEM improvements - GuC fw loading fixes - DP detection fixes - SKL GPU hang fixes - Lots of BXT fixes radeon/amdgpu: - Initial Polaris support - GPUVM/Scheduler/Clock/Power improvements - ASYNC pageflip support - New mesa feature support nouveau: - GM108 support - Power sensor support improvements - GR init + ucode fixes. - Use GPU provided topology information vmwgfx: - Add host messaging support gma500: - Some cleanups and fixes atmel: - Bridge support - Async atomic commit support fsl-dcu: - Timing controller for LCD support - Pixel clock polarity support rcar-du: - Misc fixes exynos: - Pipeline clock support - Exynoss4533 SoC support - HW trigger mode support - export HDMI_PHY clock - DECON5433 fixes - Use generic prime functions - use DMA mapping APIs rockchip: - Lots of little fixes vc4: - Render node support - Gamma ramp support - DPI output support msm: - Mostly cleanups and fixes - Conversion to generic struct fence etnaviv: - Fix for prime buffer handling - Allow hangcheck to be coalesced with other wakeups tegra: - Gamme table size fix" * 'drm-next' of git://people.freedesktop.org/~airlied/linux: (1050 commits) drm/edid: add displayid detailed 1 timings to the modelist. (v1.1) drm/edid: move displayid validation to it's own function. drm/displayid: Iterate over all DisplayID blocks drm/edid: move displayid tiled block parsing into separate function. drm: Nuke ->vblank_disable_allowed drm/vmwgfx: Report vmwgfx version to vmware.log drm/vmwgfx: Add VMWare host messaging capability drm/vmwgfx: Kill some lockdep warnings drm/nouveau/gr/gf100-: fix race condition in fecs/gpccs ucode drm/nouveau/core: recognise GM108 chipsets drm/nouveau/gr/gm107-: fix touching non-existent ppcs in attrib cb setup drm/nouveau/gr/gk104-: share implementation of ppc exception init drm/nouveau/gr/gk104-: move rop_active_fbps init to nonctx drm/nouveau/bios/pll: check BIT table version before trying to parse it drm/nouveau/bios/pll: prevent oops when limits table can't be parsed drm/nouveau/volt/gk104: round up in gk104_volt_set drm/nouveau/fb/gm200: setup mmu debug buffer registers at init() drm/nouveau/fb/gk20a,gm20b: setup mmu debug buffer registers at init() drm/nouveau/fb/gf100-: allocate mmu debug buffers drm/nouveau/fb: allow chipset-specific actions for oneinit() ... commit 1f40c49570eb01436786a9b5845c4469a9a1f362 Merge: 7639dad 36092ee Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 23 11:18:01 2016 -0700 Merge tag 'libnvdimm-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm Pull libnvdimm updates from Dan Williams: "The bulk of this update was stabilized before the merge window and appeared in -next. The "device dax" implementation was revised this week in response to review feedback, and to address failures detected by the recently expanded ndctl unit test suite. Not included in this pull request are two dax topic branches (dax error handling, and dax radix-tree locking). These topics were deferred to get a few more days of -next integration testing, and to coordinate a branch baseline with Ted and the ext4 tree. Vishal and Ross will send the error handling and locking topics respectively in the next few days. This branch has received a positive build result from the kbuild robot across 226 configs. Summary: - Device DAX for persistent memory: Device DAX is the device-centric analogue of Filesystem DAX (CONFIG_FS_DAX). It allows memory ranges to be allocated and mapped without need of an intervening file system. Device DAX is strict, precise and predictable. Specifically this interface: a) Guarantees fault granularity with respect to a given page size (pte, pmd, or pud) set at configuration time. b) Enforces deterministic behavior by being strict about what fault scenarios are supported. Persistent memory is the first target, but the mechanism is also targeted for exclusive allocations of performance/feature differentiated memory ranges. - Support for the HPE DSM (device specific method) command formats. This enables management of these first generation devices until a unified DSM specification materializes. - Further ACPI 6.1 compliance with support for the common dimm identifier format. - Various fixes and cleanups across the subsystem" * tag 'libnvdimm-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm: (40 commits) libnvdimm, dax: fix deletion libnvdimm, dax: fix alignment validation libnvdimm, dax: autodetect support libnvdimm: release ida resources Revert "block: enable dax for raw block devices" /dev/dax, core: file operations and dax-mmap /dev/dax, pmem: direct access to persistent memory libnvdimm: stop requiring a driver ->remove() method libnvdimm, dax: record the specified alignment of a dax-device instance libnvdimm, dax: reserve space to store labels for device-dax libnvdimm, dax: introduce device-dax infrastructure nfit: add sysfs dimm 'family' and 'dsm_mask' attributes tools/testing/nvdimm: ND_CMD_CALL support nfit: disable vendor specific commands nfit: export subsystem ids as attributes nfit: fix format interface code byte order per ACPI6.1 nfit, libnvdimm: limited/whitelisted dimm command marshaling mechanism nfit, libnvdimm: clarify "commands" vs "_DSMs" libnvdimm: increase max envelope size for ioctl acpi/nfit: Add sysfs "id" for NVDIMM ID ... commit b01518ca88410195ace38ce755c1206588e5c167 Author: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Date: Mon May 23 16:00:54 2016 +0530 ASoC: kirkwood: fix build failure While building m32r allmodconfig the build failed with: ERROR: "bad_dma_ops" [sound/soc/kirkwood/snd-soc-kirkwood.ko] undefined! To satisfy the dependency CONFIG_SND_KIRKWOOD_SOC should depend on HAS_DMA. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/kirkwood/Kconfig | 1 + 1 file changed, 1 insertion(+) commit bdf03e59f8c136f709dd44987ad21f6ce19dc98c Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:10:59 2016 +0200 Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/kernel/unaligned.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 94ceaf381d09e9f1f5ba4b621ea0f0c11c77a6fc Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:10:49 2016 +0200 Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/kernel/pci_gx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a87e2cdc21332592fc1c62041cfcb85111f6df5e Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:10:39 2016 +0200 Fix typo Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/gxio/mpipe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c0cb8bf3a8e4bd82e640862cdd8891400405cb89 Author: Tomáš Trnka <ttrnka@mail.muni.cz> Date: Fri May 20 16:41:10 2016 +0200 sunrpc: fix stripping of padded MIC tokens The length of the GSS MIC token need not be a multiple of four bytes. It is then padded by XDR to a multiple of 4 B, but unwrap_integ_data() would previously only trim mic.len + 4 B. The remaining up to three bytes would then trigger a check in nfs4svc_decode_compoundargs(), leading to a "garbage args" error and mount failure: nfs4svc_decode_compoundargs: compound not properly padded! nfsd: failed to decode arguments! This would prevent older clients using the pre-RFC 4121 MIC format (37-byte MIC including a 9-byte OID) from mounting exports from v3.9+ servers using krb5i. The trimming was introduced by commit 4c190e2f913f ("sunrpc: trim off trailing checksum before returning decrypted or integrity authenticated buffer"). Fixes: 4c190e2f913f "unrpc: trim off trailing checksum..." Signed-off-by: Tomáš Trnka <ttrnka@mail.muni.cz> Cc: stable@vger.kernel.org Acked-by: Jeff Layton <jlayton@poochiereds.net> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/auth_gss/svcauth_gss.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d96b9c9398fcddca7f2386cff44a6788edfe7db1 Author: J. Bruce Fields <bfields@redhat.com> Date: Wed May 18 14:50:14 2016 -0400 svcrpc: autoload rdma module This should fix failures like: # rpc.nfsd --rdma rpc.nfsd: Unable to request RDMA services: Protocol not supported Reported-by: Steve Dickson <steved@redhat.com> Reviewed-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/svc_xprt.c | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) commit cf0d44d513f275be9ce42158079d4257e8973889 Author: Michal Hocko <mhocko@suse.com> Date: Mon May 23 15:35:51 2016 +0200 s390: fix info leak in do_sigsegv Aleksa has reported incorrect si_errno value when stracing task which received SIGSEGV: [pid 20799] --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_errno=2510266, si_addr=0x100000000000000} The reason seems to be that do_sigsegv is not initializing siginfo structure defined on the stack completely so it will leak 4B of the previous stack content. Fix it simply by initializing si_errno to 0 (same as do_sigbus does already). Cc: stable # introduced pre-git times Reported-by: Aleksa Sarai <asarai@suse.de> Signed-off-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/mm/fault.c | 1 + 1 file changed, 1 insertion(+) commit 508be0dfe6287d4e6452f5a1dc08856df74cb217 Author: Andi Kleen <ak@linux.intel.com> Date: Fri May 20 13:15:08 2016 -0700 perf report: Add srcline_from/to branch sort keys Add "srcline_from" and "srcline_to" branch sort keys that allow to show the source lines of a branch. That makes it much easier to track down where particular branches happen in the program, for example to examine branch mispredictions, or to associate it with cycle counts: % perf record -b -e cycles:p ./tcall % perf report --sort srcline_from,srcline_to,mispredict ... 15.10% tcall.c:18 tcall.c:10 N 14.83% tcall.c:11 tcall.c:5 N 14.12% tcall.c:7 tcall.c:12 N 14.04% tcall.c:12 tcall.c:5 N 12.42% tcall.c:17 tcall.c:18 N 12.39% tcall.c:7 tcall.c:13 N 12.27% tcall.c:13 tcall.c:17 N ... % perf report --sort srcline_from,srcline_to,cycles ... 17.12% tcall.c:18 tcall.c:11 1 17.01% tcall.c:12 tcall.c:6 1 16.98% tcall.c:11 tcall.c:6 1 15.91% tcall.c:17 tcall.c:18 1 6.38% tcall.c:7 tcall.c:17 7 4.80% tcall.c:7 tcall.c:12 8 4.21% tcall.c:7 tcall.c:17 8 2.67% tcall.c:7 tcall.c:12 7 2.62% tcall.c:7 tcall.c:12 10 2.10% tcall.c:7 tcall.c:17 9 1.58% tcall.c:7 tcall.c:12 6 1.44% tcall.c:7 tcall.c:12 5 1.38% tcall.c:7 tcall.c:12 9 1.06% tcall.c:7 tcall.c:17 13 1.05% tcall.c:7 tcall.c:12 4 1.01% tcall.c:7 tcall.c:17 6 Open issues: - Some kernel symbols get misresolved. Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Link: http://lkml.kernel.org/r/1463775308-32748-1-git-send-email-andi@firstfloor.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-report.txt | 3 +- tools/perf/util/hist.c | 9 ++++ tools/perf/util/hist.h | 2 + tools/perf/util/sort.c | 84 ++++++++++++++++++++++++++++++++ tools/perf/util/sort.h | 2 + tools/perf/util/symbol.h | 2 + 6 files changed, 101 insertions(+), 1 deletion(-) commit 97f8827a8c7963756ae7d3ee898675b4667eca73 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Mon May 23 10:04:46 2016 -0400 ftracetest: Use proper logic to find process PID Half of the test in instance-event.tc was updated to use $! to find the PID of the previous background process that was launched, but the second part of the test still used the parsing of "jobs", which does not work on all shells like $! does. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> .../selftests/ftrace/test.d/instances/instance-event.tc | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 157d2c7fad0863222f6f3b11c4690f2a6e74d809 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri May 13 11:57:22 2016 +0100 drm/i915: Stop automatically retiring requests after a GPU hang Following a GPU hang, we break out of the request loop in order to unlock the struct_mutex for use by the GPU reset. However, if we retire all the requests at that moment, we cannot identify the guilty request after performing the reset. v2: Not automatically retiring requests forces us to recheck for available ringspace. Fixes: f4457ae71fd6 ("drm/i915: Prevent leaking of -EIO from i915_wait_request()") Testcase: igt/gem_reset_stats/ban-* Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Tested-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1463137042-9669-4-git-send-email-chris@chris-wilson.co.uk (cherry picked from commit e075a32f515becef66dc849f5eca47409ccf5473) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_gem.c | 8 ++++++-- drivers/gpu/drm/i915/intel_ringbuffer.c | 2 ++ 2 files changed, 8 insertions(+), 2 deletions(-) commit 92dcc67c11d51671cca8df543e25c601e52336ad Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 28 09:56:46 2016 +0100 drm/i915: Unify intel_ring_begin() Combine the near identical implementations of intel_logical_ring_begin() and intel_ring_begin() - the only difference is that the logical wait has to check for a matching ring (which is assumed by legacy). In the process some debug messages are culled as there were following a WARN if we hit an actual error. v2: Updated commentary Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461833819-3991-12-git-send-email-chris@chris-wilson.co.uk (cherry picked from commit 987046ad65361a8b038fbf8d76d152237fb7acf1) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_lrc.c | 146 ++----------------------- drivers/gpu/drm/i915/intel_lrc.h | 1 - drivers/gpu/drm/i915/intel_mocs.c | 12 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 188 +++++++++++++------------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 3 - 5 files changed, 89 insertions(+), 261 deletions(-) commit 9bd18728a3f2edee33d4d241d20f394c798fb414 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri May 13 10:10:42 2016 -0700 drm/i915: Ignore stale wm register values on resume on ilk-bdw (v2) When we resume the watermark register may contain some BIOS leftovers, or just the hardware reset values. We should ignore those as the pipes will be off anyway, and so frobbing around with intermediate watermarks doesn't make much sense. In fact I think we should just throw the skip_intermediate_wm flag out, and instead properly sanitize the "active" watermarks to match the current plane and pipe states. The actual wm state readout might also need a bit of work. But for now, let's continue with the skip_intermediate_wm to keep the fix more minimal. Fixes this sort of errors on resume [drm:ilk_validate_pipe_wm] LP0 watermark invalid [drm:intel_crtc_atomic_check] No valid intermediate pipe watermarks are possible [drm:intel_display_resume [i915]] *ERROR* Restoring old state failed with -22 and a boatload of subsequent modeset BAT fails on my ILK. v2: - Rebase; the SKL atomic WM patches that just landed changed the WM structure fields in intel_crtc_state slightly. (Matt) Cc: Matt Roper <matthew.d.roper@intel.com> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Fixes: ed4a6a7ca853 ("drm/i915: Add two-stage ILK-style watermark programming (v11)") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1463159442-20478-1-git-send-email-matthew.d.roper@intel.com (cherry picked from commit e3d5457c7caabb77b3f1d0b09c4a63362e9b04d2) [Jani: rebase on drm-next while cherry-picking] Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 03b7b5f983091bca17e9c163832fcde56971d7d1 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed May 18 18:47:11 2016 +0200 drm/i915/psr: Try to program link training times correctly The default of 0 is 500us of link training, but that's not enough for some platforms. Decoding this correctly means we're using 2.5ms of link training on these platforms, which fixes flickering issues associated with enabling PSR. v2: Unbotch the math a bit. v3: Drop debug hunk. v4: Improve commit message. Tested-by: Lyude <cpaul@redhat.com> Cc: Lyude <cpaul@redhat.com> Cc: stable@vger.kernel.org Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=95176 Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> Cc: Sonika Jindal <sonika.jindal@intel.com> Cc: Durgadoss R <durgadoss.r@intel.com> Cc: "Pandiyan, Dhinakaran" <dhinakaran.pandiyan@intel.com> Tested-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Tested-by: fritsch@kodi.tv Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1463590036-17824-2-git-send-email-daniel.vetter@ffwll.ch (cherry picked from commit 50db139018f9c94376d5f4db94a3bae65fdfac14) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_psr.c | 55 ++++++++++++++++++++++++++++++++++------ 1 file changed, 47 insertions(+), 8 deletions(-) commit 653bd4568ba083dfd5a06a83de3f0dc1e53dd42b Merge: 7639dad 75aeddd Author: James Morris <james.l.morris@oracle.com> Date: Mon May 23 21:23:47 2016 +1000 Merge tag 'keys-next-20160511' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs into for-linus commit c4e85b7e6ff71a130710692fcb8daae5a638941f Merge: c8d6a77 ba412e3 Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:58 2016 +0100 Merge remote-tracking branch 'spi/topic/zynqmp' into spi-next commit c8d6a77b5850dbf910e68ffe2054a6503ee2af47 Merge: b340941 280af2b d244228 5de7ed0 1051550 bf23d19 Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:55 2016 +0100 Merge remote-tracking branches 'spi/topic/pxa2xx', 'spi/topic/qup', 'spi/topic/rockchip', 'spi/topic/st-ssc4' and 'spi/topic/xlp' into spi-next commit b340941af9d85ca74d3efacb7210e95296c484aa Merge: c36581c 3ae36c8 b085c61 710a1d5 866e48b 21825ff Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:51 2016 +0100 Merge remote-tracking branches 'spi/topic/octeon', 'spi/topic/omap2-mcspi', 'spi/topic/orion', 'spi/topic/pic32' and 'spi/topic/pic32-qspi' into spi-next commit c36581c9a536405a4bb56f88d8d7c55f93d73cd1 Merge: 4b744af 3208a1c 7ba2f27 c145344 6319a68 46cb415 Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:48 2016 +0100 Merge remote-tracking branches 'spi/topic/dw', 'spi/topic/flash-read', 'spi/topic/fsl-dspi', 'spi/topic/fsl-espi' and 'spi/topic/kconfig' into spi-next commit 4b744afa7d91be50171f5483f44b4e0abc37048b Merge: 38accef a7b221d 148b1eb fe5fd25 71c5e53 Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:45 2016 +0100 Merge remote-tracking branches 'spi/topic/bcm53xx', 'spi/topic/cadence', 'spi/topic/davinci' and 'spi/topic/dln2' into spi-next commit 38acceff8f02caa8d6b7b4068bb849b619a438d6 Merge: 2dcd0af 8ba811a Author: Mark Brown <broonie@kernel.org> Date: Mon May 23 12:16:45 2016 +0100 Merge remote-tracking branch 'spi/topic/core' into spi-next commit 310944d148e3600dcff8b346bee7fa01d34903b1 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Thu May 12 15:00:44 2016 +0200 drm/imx: Match imx-ipuv3-crtc components using device node in platform data The component master driver imx-drm-core matches component devices using their of_node. Since commit 950b410dd1ab ("gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading"), the imx-ipuv3-crtc dev->of_node is not set during probing. Before that, of_node was set and caused an of: modalias to be used instead of the platform: modalias, which broke module autoloading. On the other hand, if dev->of_node is not set yet when the imx-ipuv3-crtc probe function calls component_add, component matching in imx-drm-core fails. While dev->of_node will be set once the next component tries to bring up the component master, imx-drm-core component binding will never succeed if one of the crtc devices is probed last. Add of_node to the component platform data and match against the pdata->of_node instead of dev->of_node in imx-drm-core to work around this problem. Cc: <stable@vger.kernel.org> # 4.4.x Fixes: 950b410dd1ab ("gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading") Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Tested-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Lothar Waßmann <LW@KARO-electronics.de> Tested-by: Heiko Schocher <hs@denx.de> Tested-by: Chris Ruehl <chris.ruehl@gtsys.com.hk> drivers/gpu/drm/imx/imx-drm-core.c | 8 ++++++++ drivers/gpu/drm/imx/ipuv3-crtc.c | 2 +- drivers/gpu/ipu-v3/ipu-common.c | 5 +++-- include/video/imx-ipu-v3.h | 2 ++ 4 files changed, 14 insertions(+), 3 deletions(-) commit 265984b36ce82fec67957d452dd2b22e010611e4 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Fri May 20 10:33:48 2016 +0300 mmc: sdhci-acpi: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers The CMD19/CMD14 bus width test has been found to be unreliable in some cases. It is not essential, so simply remove it. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: stable@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-acpi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 822969369482166050c5b2f7013501505e025c39 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Fri May 20 10:33:47 2016 +0300 mmc: sdhci-pci: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers The CMD19/CMD14 bus width test has been found to be unreliable in some cases. It is not essential, so simply remove it. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: stable@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pci-core.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 32ecd320db39bcb007679ed42f283740641b81ea Author: Matt Gumbel <matthew.k.gumbel@intel.com> Date: Fri May 20 10:33:46 2016 +0300 mmc: longer timeout for long read time quirk 008GE0 Toshiba mmc in some Intel Baytrail tablets responds to MMC_SEND_EXT_CSD in 450-600ms. This patch will... () Increase the long read time quirk timeout from 300ms to 600ms. Original author of that quirk says 300ms was only a guess and that the number may need to be raised in the future. () Add this specific MMC to the quirk Signed-off-by: Matt Gumbel <matthew.k.gumbel@intel.com> Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: stable@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 5 +++-- drivers/mmc/core/core.c | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) commit d4aa908c7978f60557a799ca53b5ae4166fd8355 Author: Douglas Anderson <dianders@chromium.org> Date: Thu May 12 11:31:50 2016 -0700 mmc: dw_mmc: rockchip: Set the drive phase properly Historically for Rockchip devices we've relied on the power-on default (or perhaps the firmware setting) to get the correct drive phase for dw_mmc devices. This worked OK for the most part, but: * Relying on the setting just "being right" is a bit fragile. * As soon as there is an instance where the power on default is wrong or where the firmware didn't configure this properly then we'll get a mysterious failure. In commit 7a03fe6f48f3 ("clk: rockchip: reset init state before mmc card initialization") we actually started setting this explicitly in the kernel, but that commit wasn't quite right and also wasn't quite enough. See <https://patchwork.kernel.org/patch/9085311/> for some details. Let's explicitly set this phase in dw_mmc. The comments inside this patch try to explain the situation quite throughly, but the high level overview of this is: Before this patch on rk3288 devices tested (after revert of the clock patch described above): * eMMC: 180 degrees * SDMMC/SDIO0/SDIO1: 90 degrees After this patch: * Use 90 degree phase offset usually. * Use 180 degree phase offset for MMC_DDR52, SDR104, HS200. That means we are _changing_ behavior for those devices in this way: * If we have HS200 eMMC or DDR52 eMMC, we'll run ID mode at 90 degrees (vs 180) but otherwise have no change. * For any non-HS200 / non-DDR52 eMMC devices we'll now _always_ run at 90 degrees (vs 180). It seems fairly unlikely that building modern hardware is using an eMMC that isn't using DDR52 or HS200, of course. * For SDR104 cards we'll now run with 180 degree phase offset (vs 90). It's expected that 90 degree phase offset would have worked OK, but this gives us extra margin. I have tested this by inserting my collection of uSD cards (mostly UHS, though a few not) into a veyron_minnie and confirmed that they still seem to enumerate properly. For a subset of them I tried putting a filesystem on them and also tried running mmc_test. Fixes: 7a03fe6f48f3 ("clk: rockchip: reset init state before mmc card initialization") Signed-off-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-rockchip.c | 64 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) commit 225faf871ec24f3fa6daa4d2324b5de56690e1c5 Author: Jaehoon Chung <jh80.chung@samsung.com> Date: Wed May 4 11:24:14 2016 +0900 mmc: dw_mmc: fix the wrong max_blk_size According to DesignWare TRM, BLKSIZ is 16bits. Then it's correct that max_blk_size should be 0xFFFF, not 0x10000. Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d57fe83e0744cdc88236226980c613435ad5c10c Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Tue Apr 26 14:53:59 2016 +0800 mmc: dw_mmc-rockchip: add MMC_CAP_CMD23 capabilities Add MMC_CAP_CMD23 for dw_mmc-rockchip, otherwise failing to create rpmb partition. With it, we can get rpmb successfully: mmc1: new HS200 MMC card at address 0001 mmcblk0: mmc1:0001 DS2016 14.7 GiB mmcblk0boot0: mmc1:0001 DS2016 partition 1 4.00 MiB mmcblk0boot1: mmc1:0001 DS2016 partition 2 4.00 MiB mmcblk0rpmb: mmc1:0001 DS2016 partition 3 4.00 MiB Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-rockchip.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4832aa16c4cdfc750e47c5752a32776f93b6448d Author: Ramalingam C <ramalingam.c@intel.com> Date: Tue Apr 19 13:48:14 2016 +0530 drm/i915/bxt: Adjusting the error in horizontal timings retrieval In BXT DSI there is no regs programmed with few horizontal timings in Pixels but txbyteclkhs.. So retrieval process adds some ROUND_UP ERRORS in the process of PIXELS<==>txbyteclkhs. Actually here for the given adjusted_mode, we are calculating the value programmed to the port and then back to the horizontal timing param in pixels. This is the expected value at the end of get_config, including roundup errors. And if that is same as retrieved value from port, then retrieved (HW state) adjusted_mode's horizontal timings are corrected to match with SW state to nullify the errors. Signed-off-by: Ramalingam C <ramalingam.c@intel.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461053894-5058-2-git-send-email-ramalingam.c@intel.com (cherry picked from commit 042ab0c3c40be1efcaad6b526173b5536fc6c3bf) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi.c | 97 ++++++++++++++++++++++++++++++++++++---- 1 file changed, 88 insertions(+), 9 deletions(-) commit 7045c3689f148a0c95f42bae8ef3eb2829ac7de9 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri May 13 17:55:17 2016 +0300 drm/i915: Don't leave old junk in ilk active watermarks on readout When we read out the watermark state from the hardware we're supposed to transfer that into the active watermarks, but currently we fail to any part of the active watermarks that isn't explicitly written. Let's clear it all upfront. Looks like this has been like this since the beginning, when I added the readout. No idea why I didn't clear it up. Cc: Matt Roper <matthew.d.roper@intel.com> Fixes: 243e6a44b9ca ("drm/i915: Init HSW watermark tracking in intel_modeset_setup_hw_state()") Cc: stable@vger.kernel.org Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1463151318-14719-2-git-send-email-ville.syrjala@linux.intel.com (cherry picked from commit 15606534bf0a65d8a74a90fd57b8712d147dbca6) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_pm.c | 2 ++ 1 file changed, 2 insertions(+) commit 9f7e6f33d4ffe6ab0855e851d964b6aa68451161 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed May 11 22:04:33 2016 +0300 drm/i915: s/DPPL/DPLL/ for SKL DPLLs SKL DPLLs shouldn't be called DPPLs. Cc: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Fixes: 2edd6443e3d0 ("drm/i915: Use a table to initilize shared dplls") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462993473-8254-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> (cherry picked from commit d5aab9d40135725cbe81ed5e3af5209382063193) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dpll_mgr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 83e538020018e3235f5ec40a1f2dfc673bb5ae3c Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 29 13:18:23 2016 +0100 drm/i915: Fix gen8 semaphores id for legacy mode With the introduction of a distinct engine->id vs the hardware id, we need to fix up the value we use for selecting the target engine when signaling a semaphore. Note that these values can be merged with engine->guc_id. Fixes: de1add360522c876c25ef2bbbbab1c94bdb509ab Cc: stable@vger.kernel.org # v4.6 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461932305-14637-3-git-send-email-chris@chris-wilson.co.uk (cherry picked from commit 215a7e3210eb208abe634480741e418b5a8bf60c) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_ringbuffer.c | 9 +++++++-- drivers/gpu/drm/i915/intel_ringbuffer.h | 3 ++- 2 files changed, 9 insertions(+), 3 deletions(-) commit 2bae0304684cab917f348ec411cae600130fa6a9 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Wed Apr 27 15:44:16 2016 +0300 drm/i915: Set crtc_state->lane_count for HDMI Set the lane count for HDMI to 4. This will make it easier to unduplicate CHV phy code. This also fixes the the soft reset programming for HDMI with CHV. After commit a8f327fb8464 ("drm/i915: Clean up CHV lane soft reset programming"), it wouldn't set the right bits for PCS23 since it relied on a lane count that was never set. v2: Set lane_count in *_get_config() to please state checker. (0day) v3: Set lane_count for DDI in DVI mode too. (CI) v4: Add note about CHV soft lane reset. (Ander) Fixes: a8f327fb8464 ("drm/i915: Clean up CHV lane soft reset programming") Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Jim Bride <jim.bride@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461761065-21195-2-git-send-email-ander.conselvan.de.oliveira@intel.com (cherry picked from commit d4d6279abe9a4a2d52115bad122118db4995df17) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_ddi.c | 4 +++- drivers/gpu/drm/i915/intel_hdmi.c | 4 ++++ 2 files changed, 7 insertions(+), 1 deletion(-) commit 130b62f74af3600897714045fcab553f01f46df4 Author: Ramalingam C <ramalingam.c@intel.com> Date: Tue Apr 19 13:48:13 2016 +0530 drm/i915/BXT: Retrieving the horizontal timing for DSI Retriving the horizontal timings from the port registers as part of get_config(). This fixes a division by zero: [ 56.916557] divide error: 0000 [#1] PREEMPT SMP [ 56.921741] Modules linked in: i915(+) drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm intel_gtt agpgart cf g80211 rfkill binfmt_misc ax88179_178a kvm_intel kvm irqbypass crc32c_intel efivars tpm_tis tpm fuse [ 56.944106] CPU: 3 PID: 1097 Comm: modprobe Not tainted 4.6.0-rc4+ #433 [ 56.951501] Hardware name: Intel Corp. Broxton M/RVP, BIOS BXT1RVPA.X64.0131.B30.1604142217 04/14/2016 [ 56.961908] task: ffff88007a854d00 ti: ffff88007aea0000 task.ti: ffff88007aea0000 [ 56.970273] RIP: 0010:[<ffffffffa01235b2>] [<ffffffffa01235b2>] drm_mode_hsync+0x22/0x40 [drm] [ 56.980043] RSP: 0018:ffff88007aea3788 EFLAGS: 00010206 [ 56.985982] RAX: 000000000788b600 RBX: ffff880073c22108 RCX: 0000000000000000 [ 56.993957] RDX: 0000000000000000 RSI: ffff88007ab06800 RDI: ffff880073c22108 [ 57.001935] RBP: ffff88007aea3788 R08: 0000000000000001 R09: ffff880073c221e8 [ 57.009903] R10: ffff880073c22108 R11: 0000000000000001 R12: ffff88007a300000 [ 57.017872] R13: ffff880073c22000 R14: ffff880175f78000 R15: ffff880175f78798 [ 57.025849] FS: 00007f105d3e6700(0000) GS:ffff88017fd80000(0000) knlGS:0000000000000000 [ 57.034894] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 57.041317] CR2: 00007f4d485101d0 CR3: 000000007a820000 CR4: 00000000003406e0 [ 57.049292] Stack: [ 57.051539] ffff88007aea37a0 ffffffffa043b632 ffff880175f787c8 ffff88007aea3810 [ 57.059825] ffffffffa043d59e ffff880175f787b0 ffff88007ab68c00 ffff88007aea37f0 [ 57.068128] ffff880073c221e8 ffff880073c22108 ffff880175f78780 ffff880100000000 [ 57.076430] Call Trace: [ 57.079254] [<ffffffffa043b632>] intel_mode_from_pipe_config+0x82/0xb0 [i915] [ 57.087405] [<ffffffffa043d59e>] intel_modeset_setup_hw_state+0x55e/0xd60 [i915] [ 57.095847] [<ffffffffa043ff94>] intel_modeset_init+0x8e4/0x1630 [i915] [ 57.103415] [<ffffffffa047bcf0>] i915_driver_load+0xbe0/0x1980 [i915] [ 57.110745] [<ffffffffa0116c19>] drm_dev_register+0xa9/0xc0 [drm] [ 57.117681] [<ffffffffa011921d>] drm_get_pci_dev+0x8d/0x1e0 [drm] [ 57.124600] [<ffffffff8195f942>] ? _raw_spin_unlock_irqrestore+0x42/0x70 [ 57.132253] [<ffffffffa03b0384>] i915_pci_probe+0x34/0x50 [i915] [ 57.139070] [<ffffffff8149c375>] local_pci_probe+0x45/0xa0 [ 57.145303] [<ffffffff8149d300>] ? pci_match_device+0xe0/0x110 [ 57.151924] [<ffffffff8149d6cb>] pci_device_probe+0xdb/0x130 [ 57.158355] [<ffffffff81579b93>] driver_probe_device+0x223/0x440 [ 57.165169] [<ffffffff81579e85>] __driver_attach+0xd5/0x100 [ 57.171500] [<ffffffff81579db0>] ? driver_probe_device+0x440/0x440 [ 57.178510] [<ffffffff81577736>] bus_for_each_dev+0x66/0xa0 [ 57.184841] [<ffffffff815793de>] driver_attach+0x1e/0x20 [ 57.190881] [<ffffffff81578d6e>] bus_add_driver+0x1ee/0x280 [ 57.197212] [<ffffffff8157abc0>] driver_register+0x60/0xe0 [ 57.203447] [<ffffffff8149bc50>] __pci_register_driver+0x60/0x70 [ 57.210285] [<ffffffffa0119450>] drm_pci_init+0xe0/0x110 [drm] [ 57.216911] [<ffffffff810dcd8d>] ? trace_hardirqs_on+0xd/0x10 [ 57.223434] [<ffffffffa023a000>] ? 0xffffffffa023a000 [ 57.229237] [<ffffffffa023a092>] i915_init+0x92/0x99 [i915] [ 57.235570] [<ffffffff810003db>] do_one_initcall+0xab/0x1d0 [ 57.241900] [<ffffffff810f9eef>] ? rcu_read_lock_sched_held+0x7f/0x90 [ 57.249205] [<ffffffff81204f18>] ? kmem_cache_alloc_trace+0x248/0x2b0 [ 57.256509] [<ffffffff811a5eee>] ? do_init_module+0x27/0x1d9 [ 57.262934] [<ffffffff811a5f26>] do_init_module+0x5f/0x1d9 [ 57.269167] [<ffffffff8112392f>] load_module+0x20ef/0x27b0 [ 57.275401] [<ffffffff8111f8e0>] ? store_uevent+0x40/0x40 [ 57.281541] [<ffffffff81124243>] SYSC_finit_module+0xc3/0xf0 [ 57.287969] [<ffffffff8112428e>] SyS_finit_module+0xe/0x10 [ 57.294203] [<ffffffff81960069>] entry_SYSCALL_64_fastpath+0x1c/0xac [ 57.301406] Code: ff 5d c3 66 0f 1f 44 00 00 0f 1f 44 00 00 8b 87 d8 00 00 00 55 48 89 e5 85 c0 75 22 8b 4f 68 85 c9 78 1b 69 47 58 e8 03 00 00 99 <f7> f9 b9 d3 4d 62 10 05 f4 01 00 00 f7 e1 89 d0 c1 e8 06 5d c3 [ 57.322964] RIP [<ffffffffa01235b2>] drm_mode_hsync+0x22/0x40 [drm] [ 57.330103] RSP <ffff88007aea3788> [ 57.334276] ---[ end trace d414224cb2e2a4cf ]--- [ 57.339861] modprobe (1097) used greatest stack depth: 12048 bytes left Fixes: 6f0e7535e7e1 ("drm/i915/BXT: Get pipe conf from the port registers") Signed-off-by: Ramalingam C <ramalingam.c@intel.com> Acked-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461053894-5058-1-git-send-email-ramalingam.c@intel.com (cherry picked from commit cefc4e18785123326c5d4d985085e32160fef7f5) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi.c | 44 +++++++++++++++++++++++++++++++++------- 1 file changed, 37 insertions(+), 7 deletions(-) commit e32da7adaf3c511e7e6ffa0d5b680e07201630b8 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 27 09:02:01 2016 +0100 drm/i915: Protect gen7 irq_seqno_barrier with uncore lock Faced with sporadic machine hangs on gen7, that mimic the issue of concurrent writes to the same cacheline and seem to start with commit 9b9ed3093613 (drm/i915: Remove forcewake dance from seqno/irq barrier on legacy gen6+), let us restore the spinlock around the mmio read. Fixes: 9b9ed3093613 (drm/i915: Remove forcewake dance from seqno/irq...) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461744121-27051-1-git-send-email-chris@chris-wilson.co.uk Tested-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> (cherry picked from commit bcbdb6d01150dcc1769ddc9baaaf7f102f27f919) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_ringbuffer.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 5fbd0418eef283269f2cc1b90b63d88f20c887bf Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri May 6 21:35:55 2016 +0300 drm/i915: Re-enable GGTT earlier during resume on pre-gen6 platforms Move the intel_enable_gtt() call to happen before we touch the GTT during resume. Right now it's done way too late. Before commit ebb7c78d358b ("agp/intel-gtt: Only register fake agp driver for gen1") it was actually done earlier on account of also getting called from the resume hook of the fake agp driver. With the fake agp driver no longer getting registered we must move the call up. The symptoms I've seen on my 830 machine include lowmem corruption, other kinds of memory corruption, and straight up hung machine during or just after resume. Not really sure what causes the memory corruption, but so far I've not seen any with this fix. I think we shouldn't really need to call this during init, but we have been doing that so I've decided to keep the call. However moving that call earlier could be prudent as well. Doing it right after the intel-gtt probe seems appropriate. Also tested this on 946gz,elk,ilk and all seemed quite happy with this change. v2: Reorder init_hw vs. enable_hw functions (Chris) Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: drm-intel-fixes@lists.freedesktop.org Fixes: ebb7c78d358b ("agp/intel-gtt: Only register fake agp driver for gen1") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462559755-353-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (cherry picked from commit ac840ae53573d9f435c88c131f6707a79aecb466) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_dma.c | 6 ++++++ drivers/gpu/drm/i915/i915_drv.c | 5 +++++ drivers/gpu/drm/i915/i915_gem.c | 3 --- drivers/gpu/drm/i915/i915_gem_gtt.c | 8 ++++++++ drivers/gpu/drm/i915/i915_gem_gtt.h | 1 + 5 files changed, 20 insertions(+), 3 deletions(-) commit 55d7f30ee1096474cb5bdbca46b60f23ce8b1f83 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed May 4 14:45:22 2016 +0300 drm/i915: Determine DP++ type 1 DVI adaptor presence based on VBT DP dual mode type 1 DVI adaptors aren't required to implement any registers, so it's a bit hard to detect them. The best way would be to check the state of the CONFIG1 pin, but we have no way to do that. So as a last resort, check the VBT to see if the HDMI port is in fact a dual mode capable DP port. v2: Deal with VBT code reorganization Deal with DRM_DP_DUAL_MODE_UNKNOWN Reduce DEVICE_TYPE_DP_DUAL_MODE_BITS a bit Accept both DP and HDMI dvo_port in VBT as my BSW at least declare its DP port as HDMI :( v3: Ignore DEVICE_TYPE_NOT_HDMI_OUTPUT (Shashank) Cc: stable@vger.kernel.org Cc: Tore Anderson <tore@fud.no> Reported-by: Tore Anderson <tore@fud.no> Fixes: 7a0baa623446 ("Revert "drm/i915: Disable 12bpc hdmi for now"") Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Cc: Shashank Sharma <shashank.sharma@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462362322-31278-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> (cherry picked from commit d61992565bd3cc5b66d74ed2e96df043c2a207e2) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 36 +++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_hdmi.c | 30 +++++++++++++++++++++++++---- drivers/gpu/drm/i915/intel_vbt_defs.h | 12 ++++++++++++ 4 files changed, 75 insertions(+), 4 deletions(-) commit 0c2fb7c6c8fef2092051192095a7788231ba9a42 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon May 2 22:08:24 2016 +0300 drm/i915: Enable/disable TMDS output buffers in DP++ adaptor as needed To save a bit of power, let's try to turn off the TMDS output buffers in DP++ adaptors when we're not driving the port. v2: Let's not forget DDI, toss in a debug message while at it v3: Just do the TMDS output control based on adaptor type. With the helper getting passed the type, we wouldn't actually have to check at all in the driver, but the check eliminates the debug output more honest Cc: stable@vger.kernel.org Cc: Tore Anderson <tore@fud.no> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Cc: Shashank Sharma <shashank.sharma@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462216105-20881-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> (cherry picked from commit b2ccb822d376d1bbbe5d1f9118d1488b25e6bc6d) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_ddi.c | 12 ++++++++++++ drivers/gpu/drm/i915/intel_drv.h | 1 + drivers/gpu/drm/i915/intel_hdmi.c | 20 ++++++++++++++++++++ 3 files changed, 33 insertions(+) commit c578d15226c99f0566d5d022f81af6b7d69928db Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon May 2 22:08:23 2016 +0300 drm/i915: Respect DP++ adaptor TMDS clock limit Try to detect the max TMDS clock limit for the DP++ adaptor (if any) and take it into account when checking the port clock. Note that as with the sink (HDMI vs. DVI) TMDS clock limit we'll ignore the adaptor TMDS clock limit in the modeset path, in case users are already "overclocking" their TMDS links. One subtle change here is that we'll have to respect the adaptor TMDS clock limit when we decide whether to do 12bpc or 8bpc, otherwise we might end up picking 12bpc and accidentally driving the TMDS link out of spec even when the user chose a mode that fits wihting the limits at 8bpc. This means you can't "overclock" your DP++ dongle at 12bpc anymore, but you can continue to do so at 8bpc. Note that for simplicity we'll use the I2C access method for all dual mode adaptors including type 2. Otherwise we'd have to start mixing DP AUX and HDMI together. In the future we may need to do that if we come across any board designs that don't hook up the DDC pins to the DP++ connectors. Such boards would obviously only work with type 2 dual mode adaptors, and not type 1. v2: Store adaptor type under indel_hdmi->dp_dual_mode Deal with DRM_DP_DUAL_MODE_UNKNOWN Pass adaptor type to drm_dp_dual_mode_max_tmds_clock(), and use it for type1 adaptors as well Cc: stable@vger.kernel.org Reported-by: Tore Anderson <tore@fud.no> Fixes: 7a0baa623446 ("Revert "drm/i915: Disable 12bpc hdmi for now"") Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Cc: Shashank Sharma <shashank.sharma@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462216105-20881-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> (cherry picked from commit b1ba124d8e95cca48d33502a4a76b1ed09d213ce) Signed-off-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_drv.h | 5 ++++ drivers/gpu/drm/i915/intel_hdmi.c | 58 +++++++++++++++++++++++++++++++++------ 2 files changed, 55 insertions(+), 8 deletions(-) commit b3daa5ef52c26acd7432c787989bd92d48070c76 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri May 6 16:46:52 2016 +0300 drm: Add helper for DP++ adaptors Add a helper which aids in the identification of DP dual mode (aka. DP++) adaptors. There are several types of adaptors specified: type 1 DVI, type 1 HDMI, type 2 DVI, type 2 HDMI Type 1 adaptors have a max TMDS clock limit of 165MHz, type 2 adaptors may go as high as 300MHz and they provide a register informing the source device what the actual limit is. Supposedly also type 1 adaptors may optionally implement this register. This TMDS clock limit is the main reason why we need to identify these adaptors. Type 1 adaptors provide access to their internal registers and the sink DDC bus through I2C. Type 2 adaptors provide this access both via I2C and I2C-over-AUX. A type 2 source device may choose to implement either of these methods. If a source device implements the I2C-over-AUX method, then the driver will obviously need specific support for such adaptors since the port is driven like an HDMI port, but DDC communication happes over the AUX channel. This helper should be enough to identify the adaptor type (some type 1 DVI adaptors may be a slight exception) and the maximum TMDS clock limit. Another feature that may be available is control over the TMDS output buffers on the adaptor, possibly allowing for some power saving when the TMDS link is down. Other user controllable features that may be available in the adaptors are downstream i2c bus speed control when using i2c-over-aux, and some control over the CEC pin. I chose not to provide any helper functions for those since I have no use for them in i915 at this time. The rest of the registers in the adaptor are mostly just information, eg. IEEE OUI, hardware and firmware revision, etc. v2: Pass adaptor type to helper functions to ease driver implementation Fix a bunch of typoes (Paulo) Add DRM_DP_DUAL_MODE_UNKNOWN for the case where we don't (yet) know the type (Paulo) Reject 0x00 and 0xff DP_DUAL_MODE_MAX_TMDS_CLOCK values (Paulo) Adjust drm_dp_dual_mode_detect() type2 vs. type1 detection to ease future LSPCON enabling Remove the unused DP_DUAL_MODE_LAST_RESERVED define v3: Fix kernel doc function argument descriptions (Jani) s/NONE/UNKNOWN/ in drm_dp_dual_mode_detect() docs Add kernel doc for enum drm_dp_dual_mode_type Actually build the docs Fix more typoes v4: Adjust code indentation of type2 adaptor detection (Shashank) Add debug messages for failurs cases (Shashank) v5: EXPORT_SYMBOL(drm_dp_dual_mode_read) (Paulo) Cc: stable@vger.kernel.org Cc: Tore Anderson <tore@fud.no> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Cc: Shashank Sharma <shashank.sharma@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Shashank Sharma <shashank.sharma@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> (v4) Link: http://patchwork.freedesktop.org/patch/msgid/1462542412-25533-1-git-send-email-ville.syrjala@linux.intel.com (cherry picked from commit ede53344dbfd1dd43bfd73eb6af743d37c56a7c3) Signed-off-by: Jani Nikula <jani.nikula@intel.com> Documentation/DocBook/gpu.tmpl | 6 + drivers/gpu/drm/Makefile | 2 +- drivers/gpu/drm/drm_dp_dual_mode_helper.c | 366 ++++++++++++++++++++++++++++++ include/drm/drm_dp_dual_mode_helper.h | 92 ++++++++ 4 files changed, 465 insertions(+), 1 deletion(-) commit e9bc15f28e5f0db44aba609780d6850eabefbf11 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Wed Jan 13 10:45:44 2016 +0100 s390/config: update default configuration Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/configs/default_defconfig | 44 ++++++++++++++++++++++----------- arch/s390/configs/gcov_defconfig | 34 ++++++++++++++----------- arch/s390/configs/performance_defconfig | 36 ++++++++++++++++----------- arch/s390/configs/zfcpdump_defconfig | 4 +-- arch/s390/defconfig | 44 +++++++++++++++++++-------------- 5 files changed, 98 insertions(+), 64 deletions(-) commit 540be8b2add1a18a4289b11c1a9b6956eb846630 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun May 22 11:06:29 2016 +0200 MAINTAINERS: Add file patterns for watchdog device tree bindings Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> Cc: linux-watchdog@vger.kernel.org MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 7639dad93a5564579987abded4ec05e3db13659d Merge: 77ed402 8329e81 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 22 19:40:39 2016 -0700 Merge tag 'trace-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull motr tracing updates from Steven Rostedt: "Three more changes. - I forgot that I had another selftest to stress test the ftrace instance creation. It was actually suppose to go into the 4.6 merge window, but I never committed it. I almost forgot about it again, but noticed it was missing from your tree. - Soumya PN sent me a clean up patch to not disable interrupts when taking the tasklist_lock for read, as it's unnecessary because that lock is never taken for write in irq context. - Newer gcc's can cause the jump in the function_graph code to the global ftrace_stub label to be a short jump instead of a long one. As that jump is dynamically converted to jump to the trace code to do function graph tracing, and that conversion expects a long jump it can corrupt the ftrace_stub itself (it's directly after that call). One way to prevent gcc from using a short jump is to declare the ftrace_stub as a weak function, which we do here to keep gcc from optimizing too much" * tag 'trace-v4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: ftrace/x86: Set ftrace_stub to weak to prevent gcc from using short jumps to it ftrace: Don't disable irqs when taking the tasklist_lock read_lock ftracetest: Add instance created, delete, read and enable event test commit 77ed402b7f53cbe50ae8384a172a5b9713020400 Merge: 21f9deb 44156af Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 22 19:35:27 2016 -0700 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu Pull m68knommu update from Greg Ungerer: "Only a single change to update my email address in the MAINTAINERS file" * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu: m68k: change m68knommu maintainer email address commit 21f9debf74c3ae8fdd26fd2bc3c0169a08eba6b4 Merge: bd28b14 24e49ee Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 22 19:24:13 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc Pull sparc updates from David Miller: "Some 32-bit kgdb cleanups from Sam Ravnborg, and a hugepage TLB flush overhead fix on 64-bit from Nitin Gupta" * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc: sparc64: Reduce TLB flushes during hugepte changes aeroflex/greth: fix warning about unused variable openprom: fix warning sparc32: drop superfluous cast in calls to __nocache_pa() sparc32: fix build with STRICT_MM_TYPECHECKS sparc32: use proper prototype for trapbase sparc32: drop local prototype in kgdb_32 sparc32: drop hardcoding trap_level in kgdb_trap commit a39ed680bddb1ead592e22ed812c7e47286bfc03 Author: Dave Airlie <airlied@redhat.com> Date: Mon May 2 08:35:05 2016 +1000 drm/edid: add displayid detailed 1 timings to the modelist. (v1.1) The tiled 5K Dell monitor appears to be hiding it's tiled mode inside the displayid timings block, this patch parses this blocks and adds the modes to the modelist. v1.1: add missing __packed. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=95207 Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_edid.c | 108 ++++++++++++++++++++++++++++++++++++++++++++ include/drm/drm_displayid.h | 17 +++++++ 2 files changed, 125 insertions(+) commit c97291774c1b867b56c3d439ddaec9a965cf559e Author: Dave Airlie <airlied@redhat.com> Date: Tue May 3 15:38:37 2016 +1000 drm/edid: move displayid validation to it's own function. We need to use this for validating modeline additions. Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_edid.c | 44 ++++++++++++++++++++++++++------------------ 1 file changed, 26 insertions(+), 18 deletions(-) commit 3a4a2ea39f86c581054794c0a727597745f1084b Author: Tomas Bzatek <tomas@bzatek.net> Date: Sun May 1 15:02:45 2016 +0200 drm/displayid: Iterate over all DisplayID blocks This will iterate over all DisplayID blocks found in the buffer. Previously only the first block was parsed. https://bugs.freedesktop.org/show_bug.cgi?id=95207 Signed-off-by: Tomas Bzatek <tomas@bzatek.net> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_edid.c | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) commit 5e546cd5b3bc76824069ffa98c52a5f48cf91aba Author: Dave Airlie <airlied@redhat.com> Date: Tue May 3 15:31:12 2016 +1000 drm/edid: move displayid tiled block parsing into separate function. This just makes the code easier to follow. Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_edid.c | 110 ++++++++++++++++++++++++--------------------- 1 file changed, 59 insertions(+), 51 deletions(-) commit bd28b14591b98f696bc9f94c5ba2e598ca487dfd Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 22 17:21:27 2016 -0700 x86: remove more uaccess_32.h complexity I'm looking at trying to possibly merge the 32-bit and 64-bit versions of the x86 uaccess.h implementation, but first this needs to be cleaned up. For example, the 32-bit version of "__copy_from_user_inatomic()" is mostly the special cases for the constant size, and it's actually almost never relevant. Most users aren't actually using a constant size anyway, and the few cases that do small constant copies are better off just using __get_user() instead. So get rid of the unnecessary complexity. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/include/asm/uaccess_32.h | 26 -------------------------- kernel/events/uprobes.c | 3 +-- kernel/futex.c | 2 +- mm/maccess.c | 3 +-- 4 files changed, 3 insertions(+), 31 deletions(-) commit 5b09c3edecd37ec1a52fbd5ae97a19734edc7a77 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sun May 22 14:19:37 2016 -0700 x86: remove pointless uaccess_32.h complexity I'm looking at trying to possibly merge the 32-bit and 64-bit versions of the x86 uaccess.h implementation, but first this needs to be cleaned up. For example, the 32-bit version of "__copy_to_user_inatomic()" is mostly the special cases for the constant size, and it's actually never relevant. Every user except for one aren't actually using a constant size anyway, and the one user that uses it is better off just using __put_user() instead. So get rid of the unnecessary complexity. [ The same cleanup should likely happen to __copy_from_user_inatomic() as well, but that one has a lot more users that I need to take a look at first ] Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/include/asm/uaccess_32.h | 36 ------------------------------ drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +--- 2 files changed, 1 insertion(+), 39 deletions(-) commit 90afe0a98e81f8d2cb1146368d86f67769956e58 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:03:32 2016 +0200 parisc: Fix typo in fpudispatch.c Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/math-emu/fpudispatch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1a2a0f78170425eef16a8af96ec1323e2df88f52 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:02:59 2016 +0200 parisc: Fix typos in eisa_eeprom.h Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/asm/eisa_eeprom.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d14b3dfc251d8524a3d24bfaf4c983a5b950a7d9 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:03:06 2016 +0200 parisc: Fix typo in ldcw.h Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/asm/ldcw.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 13ff6313f9938fc304abaa6ecca416a705d1b642 Author: Andrea Gelmini <andrea.gelmini@gelma.net> Date: Sat May 21 14:03:14 2016 +0200 parisc: Fix typo in pdc.h Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/uapi/asm/pdc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 37b1ba2c68cfbe37f5f45bb91bcfaf2b016ae6a1 Author: Matt Ranostay <mranostay@gmail.com> Date: Sat May 21 20:01:03 2016 -0700 iio: proximity: as3935: fix buffer stack trashing Buffer wasn't of a valid size to allow the timestamp, and correct padding. This patchset also moves the buffer off the stack, and onto the heap. Cc: george.mccollister@gmail.com Signed-off-by: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/proximity/as3935.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 7d0643634ea567969bf3f3ed6193a9d6fc75653b Author: Matt Ranostay <mranostay@gmail.com> Date: Sat May 21 20:01:02 2016 -0700 iio: proximity: as3935: remove triggered buffer processing Triggered buffers shouldn't return processed data, and the respective conversion was overflowing the defined .realbits for the channel. Cc: george.mccollister@gmail.com Signed-off-by: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/proximity/as3935.c | 1 - 1 file changed, 1 deletion(-) commit 5138806f16c74c7cb8ac3e408a859c79eb7c9567 Author: Matt Ranostay <mranostay@gmail.com> Date: Sat May 21 20:01:01 2016 -0700 iio: proximity: as3935: correct IIO_CHAN_INFO_RAW output IIO_CHAN_INFO_RAW was returning processed data which was incorrect. This also adds the IIO_CHAN_INFO_SCALE value to convert to a processed value. Signed-off-by: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935 | 2 +- drivers/iio/proximity/as3935.c | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) commit 99aed91a8dc6e398003333decacc101e5e504988 Author: John David Anglin <dave.anglin@bell.net> Date: Sat May 21 15:03:54 2016 -0400 parisc: Update futex.h to match generic implementation The attached patch updates the parisc version of futex.h to match the current generic implementation except for the spinlock code. Signed-off-by: John David Anglin <dave.anglin@bell.net> Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/asm/futex.h | 70 +++++++++++++++++------------------------ 1 file changed, 29 insertions(+), 41 deletions(-) commit 4df3c9ec12077384e0add54f28a9b079a87b59ef Author: Helge Deller <deller@gmx.de> Date: Fri Apr 29 22:07:31 2016 +0200 parisc: Merge ftrace C-helper and assembler functions into .text.hot section When enabling all-branch ftrace support (CONFIG_PROFILE_ALL_BRANCHES) the kernel gets really huge and some ftrace assembler functions like mcount can't reach the ftrace helper functions which are written in C. Avoid this problem of too distant branches by moving the ftrace C-helper functions into the .text.hot section which is put in front of the standard .text section by the linker. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/kernel/entry.S | 2 +- arch/parisc/kernel/ftrace.c | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) commit a4351cb5511b917556c796d97068318a53a00849 Author: Helge Deller <deller@gmx.de> Date: Thu Mar 31 13:11:05 2016 +0200 selftests/thuge-gen: Use platform specific MAP_HUGETLB value Do not hardcode MAP_HUGETLB to 0x40000, since quite some architectures use a different value. Tested with a parisc architecture 64bit kernel. Signed-off-by: Helge Deller <deller@gmx.de> tools/testing/selftests/vm/thuge-gen.c | 2 ++ 1 file changed, 2 insertions(+) commit 54b668009076caddbede8fde513ca2c982590bfe Author: Helge Deller <deller@gmx.de> Date: Wed Apr 20 21:34:15 2016 +0200 parisc: Add native high-resolution sched_clock() implementation Add a native implementation for the sched_clock() function which utilizes the processor-internal cycle counter (Control Register 16) as high-resolution time source. With this patch we now get much more fine-grained resolutions in various in-kernel time measurements (e.g. when viewing the function tracing logs), and probably a more accurate scheduling on SMP systems. There are a few specific implementation details in this patch: 1. On a 32bit kernel we emulate the higher 32bits of the required 64-bit resolution of sched_clock() by increasing a per-cpu counter at every wrap-around of the 32bit cycle counter. 2. In a SMP system, the cycle counters of the various CPUs are not syncronized (similiar to the TSC in a x86_64 system). To cope with this we define HAVE_UNSTABLE_SCHED_CLOCK and let the upper layers do the adjustment work. 3. Since we need HAVE_UNSTABLE_SCHED_CLOCK, we need to provide a cmpxchg64() function even on a 32-bit kernel. 4. A 64-bit SMP kernel which is started on a UP system will mark the sched_clock() implementation as "stable", which means that we don't expect any jumps in the returned counter. This is true because we then run only on one CPU. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/Kconfig | 1 + arch/parisc/include/asm/cmpxchg.h | 9 +++--- arch/parisc/kernel/time.c | 63 ++++++++++++++++++++++++++++++++++++++- arch/parisc/lib/bitops.c | 6 ++-- 4 files changed, 70 insertions(+), 9 deletions(-) commit 64e2a42bca12e408f0258c56adcf3595bcd116e7 Author: Helge Deller <deller@gmx.de> Date: Fri Apr 1 22:40:53 2016 +0200 parisc: Add ARCH_TRACEHOOK and regset support By adding TRACEHOOK support we now get a clean user interface to access registers via PTRACE_GETREGS, PTRACE_SETREGS, PTRACE_GETFPREGS and PTRACE_SETFPREGS. The user-visible regset struct user_regs_struct and user_fp_struct are modelled similiar to x86 and can be accessed via PTRACE_GETREGSET. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/Kconfig | 1 + arch/parisc/include/uapi/asm/ptrace.h | 48 ++++ arch/parisc/kernel/ptrace.c | 356 +++++++++++++++++++++++++- tools/testing/selftests/seccomp/seccomp_bpf.c | 8 +- 4 files changed, 410 insertions(+), 3 deletions(-) commit d2ad824f4bb8d146ea6e5f440dddb30b9ccfd98c Author: Helge Deller <deller@gmx.de> Date: Sat Apr 9 08:27:08 2016 +0200 parisc: Add 64bit get_user() and put_user() for 32bit kernel Allow accessing 64-bit values in userspace from a 32-bit kernel. The access is not atomic. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/include/asm/uaccess.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) commit 06bff6b9d7d50566a9320f64b0624957798cb08b Author: Helge Deller <deller@gmx.de> Date: Sat Apr 9 08:26:14 2016 +0200 parisc: Simplify and speed up get_user() and put_user() This patch simplifies the code for get_user() and put_user() a lot. Instead of accessing kernel memory (%sr0) and userspace memory (%sr3) hard-coded in the assembler instruction, we now preload %sr2 with either %sr0 (for accessing KERNEL_DS) or with sr3 (to access USER_DS) and use %sr2 in the load directly. The generated code avoids a branch and speeds up execution by generating less assembler instructions. Signed-off-by: Helge Deller <deller@gmx.de> Tested-by: Rolf Eike Beer <eike-kernel@sf-tec.de> arch/parisc/include/asm/uaccess.h | 79 +++++++++++---------------------------- 1 file changed, 21 insertions(+), 58 deletions(-) commit fc79168a7c75423047d60a033dc4844955ccae0b Author: Helge Deller <deller@gmx.de> Date: Wed Apr 13 22:44:54 2016 +0200 parisc: Add syscall tracepoint support This patch adds support for the TIF_SYSCALL_TRACEPOINT on the parisc architecture. Basically, it calls the appropriate tracepoints on syscall entry and exit. Signed-off-by: Helge Deller <deller@gmx.de> arch/parisc/Kconfig | 1 + arch/parisc/include/asm/ftrace.h | 2 ++ arch/parisc/include/asm/syscall.h | 9 +++++++++ arch/parisc/include/asm/thread_info.h | 4 +++- arch/parisc/kernel/ptrace.c | 12 ++++++++++++ arch/parisc/kernel/syscall.S | 1 + 6 files changed, 28 insertions(+), 1 deletion(-) commit 787ab6e97024926f38773287d9f98a9b330bce23 Author: Hannes Reinecke <hare@suse.de> Date: Wed May 18 10:16:51 2016 +0200 aacraid: do not activate events on non-SRC adapters Only SRC-based adapters support the AifReqEvent function, so there is no point in trying to activate it on older, non-SRC based adapters. Doing so lead to crashes on older adapters. Signed-off-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.com> Reviewed-by: Raghava Aditya Renukunta <RaghavaAaditya.Renukunta@microsemi.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aacraid.h | 5 +++++ drivers/scsi/aacraid/linit.c | 11 ++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) commit 7ebd67e0dece0ec53e5541fc600eda4e050fab72 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 12 23:37:38 2016 +0300 mpt3sas: add missing curly braces There are some missing curly braces on this if statement, so we end up printing when we shouldn't. Fixes: a470a51cd648 ('mpt3sas: Handle active cable exception event') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Chaitra P B <chaitra.basappa@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_scsih.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit eb72d0bb84eee5d0dc3044fd17b75e7101dabb57 Author: Hannes Reinecke <hare@suse.de> Date: Tue Apr 26 08:06:58 2016 +0200 sd: get disk reference in sd_check_events() sd_check_events() is called asynchronously, and might race with device removal. So always take a disk reference when processing the event to avoid the device being removed while the event is processed. Signed-off-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Ewan D. Milne <emilne@redhat.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/sd.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit a621bac3044ed6f7ec5fa0326491b2d4838bfa93 Author: James Bottomley <James.Bottomley@HansenPartnership.com> Date: Fri May 13 12:04:06 2016 -0700 scsi_lib: correctly retry failed zero length REQ_TYPE_FS commands When SCSI was written, all commands coming from the filesystem (REQ_TYPE_FS commands) had data. This meant that our signal for needing to complete the command was the number of bytes completed being equal to the number of bytes in the request. Unfortunately, with the advent of flush barriers, we can now get zero length REQ_TYPE_FS commands, which confuse this logic because they satisfy the condition every time. This means they never get retried even for retryable conditions, like UNIT ATTENTION because we complete them early assuming they're done. Fix this by special casing the early completion condition to recognise zero length commands with errors and let them drop through to the retry code. Cc: stable@vger.kernel.org Reported-by: Sebastian Parschauer <s.parschauer@gmx.de> Signed-off-by: James E.J. Bottomley <jejb@linux.vnet.ibm.com> Tested-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_lib.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit bb991288728e6a47a6f0fac6a4e9dfaeecc27956 Author: Michael S. Tsirkin <mst@redhat.com> Date: Sun May 22 15:10:49 2016 +0300 ringtest: pass buf != NULL just a stub pointer for now. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> tools/virtio/ringtest/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 87c9403b0d1de4676b0bd273eea68fcf6de68e68 Author: Michael S. Tsirkin <mst@redhat.com> Date: Tue May 17 13:31:18 2016 +0300 virtio_balloon: fix PFN format for virtio-1 Everything should be LE when using virtio-1, but the linux balloon driver does not seem to care about that. Reported-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> drivers/virtio/virtio_balloon.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit ce10c1b95095c652461616a3f887f6412ab6e1cc Author: Michael S. Tsirkin <mst@redhat.com> Date: Sun May 8 18:43:54 2016 +0300 virtio: add inorder option skips ring accesses but drops out of order support Signed-off-by: Michael S. Tsirkin <mst@redhat.com> tools/virtio/ringtest/Makefile | 5 ++- tools/virtio/ringtest/virtio_ring_0_9.c | 49 ++++++++++++++++++++++++++++- tools/virtio/ringtest/virtio_ring_inorder.c | 2 ++ 3 files changed, 54 insertions(+), 2 deletions(-) commit f6c658df63856db3bf8f467024b1dbee37b5399c Merge: 07be133 0f3311a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 21 18:25:28 2016 -0700 Merge tag 'for-f2fs-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs Pull f2fs updates from Jaegeuk Kim: "In this round, as Ted pointed out, fscrypto allows one more key prefix given by filesystem to resolve backward compatibility issues. Other than that, we've fixed several error handling cases by introducing a fault injection facility. We've also achieved performance improvement in some workloads as well as a bunch of bug fixes. Summary: Enhancements: - fs-specific prefix for fscrypto - fault injection facility - expose validity bitmaps for user to be aware of fragmentation - fallocate/rm/preallocation speed up - use percpu counters Bug fixes: - some inline_dentry/inline_data bugs - error handling for atomic/volatile/orphan inodes - recover broken superblock" * tag 'for-f2fs-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs: (73 commits) f2fs: fix to update dirty page count correctly f2fs: flush pending bios right away when error occurs f2fs: avoid ENOSPC fault in the recovery process f2fs: make exit_f2fs_fs more clear f2fs: use percpu_counter for total_valid_inode_count f2fs: use percpu_counter for alloc_valid_block_count f2fs: use percpu_counter for # of dirty pages in inode f2fs: use percpu_counter for page counters f2fs: use bio count instead of F2FS_WRITEBACK page count f2fs: manipulate dirty file inodes when DATA_FLUSH is set f2fs: add fault injection to sysfs f2fs: no need inc dirty pages under inode lock f2fs: fix incorrect error path handling in f2fs_move_rehashed_dirents f2fs: fix i_current_depth during inline dentry conversion f2fs: correct return value type of f2fs_fill_super f2fs: fix deadlock when flush inline data f2fs: avoid f2fs_bug_on during recovery f2fs: show # of orphan inodes f2fs: support in batch fzero in dnode page f2fs: support in batch multi blocks preallocation ... commit a78ff1112263fdd871d3506dbcff44f6f12e8423 Author: Eli Cooper <elicooper@gmx.com> Date: Sun Mar 20 00:58:41 2016 +0800 um: add extended processor state save/restore support This patch extends save_fp_registers() and restore_fp_registers() to use PTRACE_GETREGSET and PTRACE_SETREGSET with the XSTATE note type, adding support for new processor state extensions between context switches. When the new ptrace requests are unavailable, it falls back to the old PTRACE_GETFPREGS and PTRACE_SETFPREGS methods, which have been renamed to save_i387_registers() and restore_i387_registers(). Now these functions expect *fp_regs to have the space of an _xstate struct. Thus, this also makes ptrace in UML responde to PTRACE_GETFPREGS/_SETFPREG requests with a user_i387_struct (thus independent from HOST_FP_SIZE), and by calling save_i387_registers() and restore_i387_registers() instead of the extended save_fp_registers() and restore_fp_registers() functions. Signed-off-by: Eli Cooper <elicooper@gmx.com> arch/um/include/shared/registers.h | 2 ++ arch/um/kernel/process.c | 2 +- arch/x86/um/os-Linux/registers.c | 49 +++++++++++++++++++++++++++++++++-- arch/x86/um/ptrace_32.c | 5 ++-- arch/x86/um/ptrace_64.c | 16 ++++++------ arch/x86/um/shared/sysdep/ptrace_64.h | 4 +-- 6 files changed, 62 insertions(+), 16 deletions(-) commit b6024b21fec8367ef961a771cc9dde31f1831965 Author: Eli Cooper <elicooper@gmx.com> Date: Sun Mar 20 00:58:40 2016 +0800 um: extend fpstate to _xstate to support YMM registers Extends fpstate to _xstate, in order to hold AVX/YMM registers. To avoid oversized stack frame, the following functions have been refactored by using malloc. - sig_handler_common - timer_real_alarm_handler Signed-off-by: Eli Cooper <elicooper@gmx.com> arch/um/os-Linux/signal.c | 28 ++++++++++++++++++++-------- arch/x86/um/signal.c | 23 +++++++++++------------ arch/x86/um/user-offsets.c | 2 +- 3 files changed, 32 insertions(+), 21 deletions(-) commit 6de5a8a5001687df720b36729c799991cc0faff5 Author: Eli Cooper <elicooper@gmx.com> Date: Sun Mar 20 00:58:39 2016 +0800 um: fix FPU state preservation around signal handlers This patch makes UML saves/restores FPU state from/to the fpstate in pt_regs when setting up or returning from a signal stack, rather than calling ptrace directly. This ensures that FPU state is correctly preserved around signal handlers in a multi-threaded scenario. Signed-off-by: Eli Cooper <elicooper@gmx.com> arch/x86/um/signal.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) commit 36092ee8ba695fce023b2118ececa6c2a56b1331 Merge: 1b982ba 03dca34 Author: Dan Williams <dan.j.williams@intel.com> Date: Sat May 21 12:33:04 2016 -0700 Merge branch 'for-4.7/dax' into libnvdimm-for-next commit 03dca343afe080968d90c4d9196404b5bbbc8461 Author: Dan Williams <dan.j.williams@intel.com> Date: Sat May 21 12:22:41 2016 -0700 libnvdimm, dax: fix deletion The ndctl unit tests discovered that the dax enabling omitted updates to nd_detach_and_reset(). This routine clears device the configuration when the namespace is detached. Without this clearing userspace may assume that the device is in the process of being configured by another agent in the system. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/claim.c | 23 +++++++++++++++++++++-- drivers/nvdimm/nd-core.h | 1 + drivers/nvdimm/pfn_devs.c | 19 ------------------- 3 files changed, 22 insertions(+), 21 deletions(-) commit 14f2461b822dffb116256ee9155f7eca96064f7a Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Fri May 20 17:44:36 2016 +0300 max44000: Remove scale from proximity This is not implemented and doesn't really make sense because IIO proximity is unit-less. Remove IIO_CHAN_INFO_SCALE from info_mask because so that the _scale sysfs entry won't appear. This fixes userspace tools like generic_buffer which abort when reads returns an error. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/max44000.c | 1 - 1 file changed, 1 deletion(-) commit 5e24c9fd36285535c704e84748d6c890be870fb6 Author: Dan Williams <dan.j.williams@intel.com> Date: Sat May 21 11:01:41 2016 -0700 libnvdimm, dax: fix alignment validation Testing the dax-device autodetect support revealed a probe failure with the following result: dax0.1: bad offset: 0x8200000 dax disabled The original pfn-device implementation inferred the alignment from ilog2(offset), now that the alignment is explicit the is_power_of_2() needs replacing with a real sanity check against the recorded alignment. Otherwise the alignment check is useless in the implicit case and only the minimum size of the offset matters. This self-consistency check is further validated by the probe path that will re-check that the offset is large enough to contain all the metadata required to enable the device. Cc: <stable@vger.kernel.org> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pfn_devs.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 07be1337b9e8bfcd855c6e9175b5066a30ac609b Merge: 63d222b c315ef8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 21 10:49:22 2016 -0700 Merge branch 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs updates from Chris Mason: "This has our merge window series of cleanups and fixes. These target a wide range of issues, but do include some important fixes for qgroups, O_DIRECT, and fsync handling. Jeff Mahoney moved around a few definitions to make them easier for userland to consume. Also whiteout support is included now that issues with overlayfs have been cleared up. I have one more fix pending for page faults during btrfs_copy_from_user, but I wanted to get this bulk out the door first" * 'for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: (90 commits) btrfs: fix memory leak during RAID 5/6 device replacement Btrfs: add semaphore to synchronize direct IO writes with fsync Btrfs: fix race between block group relocation and nocow writes Btrfs: fix race between fsync and direct IO writes for prealloc extents Btrfs: fix number of transaction units for renames with whiteout Btrfs: pin logs earlier when doing a rename exchange operation Btrfs: unpin logs if rename exchange operation fails Btrfs: fix inode leak on failure to setup whiteout inode in rename btrfs: add support for RENAME_EXCHANGE and RENAME_WHITEOUT Btrfs: pin log earlier when renaming Btrfs: unpin log if rename operation fails Btrfs: don't do unnecessary delalloc flushes when relocating Btrfs: don't wait for unrelated IO to finish before relocation Btrfs: fix empty symlink after creating symlink and fsync parent dir Btrfs: fix for incorrect directory entries after fsync log replay btrfs: build fixup for qgroup_account_snapshot btrfs: qgroup: Fix qgroup accounting when creating snapshot Btrfs: fix fspath error deallocation btrfs: make find_workspace warn if there are no workspaces btrfs: make find_workspace always succeed ... commit 63d222b9d277c4d7bf08afd1631a7f8e327a825c Merge: 10cd715 b9ba1eb Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 21 10:42:11 2016 -0700 Merge tag 'rtc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/abelloni/linux Pull RTC updates from Alexandre Belloni: "Subsystem wide cleanups: - Use IS_ENABLED() instead of checking for built-in or module - remove useless DRV_VERSION - remove CLK_IS_ROOT - remove UIE signaling Drivers: - ds1302: rewritten to be a proper SPI device driver - m41t80: huge cleanup, alarm, wakelarm ans oscialltor failure detection support - rv3029: switch to regmap to handle rv3049, alarm support, fixes - zynqmp: enable switching to battery power, fixes - small fixes for at91sam9, da9053, ds1307, ds1685, ds3232, r2025, sa1100, snvs, stmp3xxx, tps6586x" * tag 'rtc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/abelloni/linux: (40 commits) rtc: tps6586x: rename so module can be autoloaded rtc: rv3029: hide unused i2c device table rtc: rs5c372: r2025: fix check for 'oscillator halted' condition rtc: rv3029: add alarm IRQ rtc: rv3029: fix set_time function rtc: rv3029: fix alarm support rtc: rv3029: Remove some checks and warnings rtc: rv3029: Add support of RV3049 rtc: rv3029: convert to use regmap rtc: rv3029: remove 'i2c' in functions names rtc: stmp3xxx: print message on error rtc: Use IS_ENABLED() instead of checking for built-in or module rtc: ds3232: fix call trace when rtc->ops_lock is used as NULL rtc: snvs: return error in case enable_irq_wake fails rtc: zynqmp: Update seconds time programming logic rtc: sa1100: DT spelling s/interrupt-name/interrupt-names/ rtc: mc13xxx: remove UIE signaling rtc: mxc: remove UIE signaling rtc: ds1307: Remove CLK_IS_ROOT rtc: hym8563: Remove CLK_IS_ROOT ... commit 10cd7158042bf9c949c19dbf0c7ee600d198ed39 Merge: 51e68d0 c430cf3 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 21 10:32:48 2016 -0700 Merge branch 'mailbox-for-next' of git://git.linaro.org/landing-teams/working/fujitsu/integration Pull mailbox updates from Jassi Brar: "OMAP: - Remove non-DT support from mailbox driver - Move PM from client calls to native driver suspend/resume - Trivial cleanups to make checkpatch happy STI: - Check return from devm_ioremap_resource as ERR_PTR, not NULL" * 'mailbox-for-next' of git://git.linaro.org/landing-teams/working/fujitsu/integration: mailbox: Fix devm_ioremap_resource error detection code mailbox/omap: kill omap_mbox_{save/restore}_ctx() functions mailbox/omap: check for any unread messages during suspend mailbox/omap: add support for suspend/resume mailbox/omap: store mailbox interrupt type in omap_mbox_device mailbox/omap: add blank lines after declarations mailbox/omap: remove FSF mailing address paragraph mailbox/omap: use variable name for sizeof() operator mailbox/omap: drop legacy platform device support commit 51e68d055cbabfd36cba3903fd2a223bc98514b1 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat May 21 10:25:19 2016 -0700 x86 isa: add back X86_32 dependency on CONFIG_ISA Commit b3c1be1b789c ("base: isa: Remove X86_32 dependency") made ISA support available on x86-64 too. That's not right - while there are some LPC-style devices that might be useful still and be based on ISA-like IP blocks, that is *not* an excuse to try to enable any random legacy drivers. Such drivers should be individually enabled and made to perhaps depend on ISA_DMA_API instead (which we have continued to support on x86-64). Or we could add another "ISA_XYZ_API" that we support that doesn't enable random old drivers that aren't even 64-bit clean nor do we have any test coverage for. Turning off ISA will now also turn off some drivers that have been marked as depending on it as part of this series, and that used to work on modern platforms. See for example commits ad7afc38eab3..cc736607c86d, which may also need to be reverted. This commit means that the warnings that came in due to enabling ISA widely are now gone again. Acked-by: William Breathitt Gray <vilhelm.gray@gmail.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Guenter Roeck <linux@roeck-us.net> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1cb0d06a00f2ec0ed8f926ec62f53bc9e12ea55e Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 17 11:02:56 2016 +0300 iio: humidity: am2315: Remove a stray unlock We haven't taken the lock yet so we don't need to unlock here. Fixes: 0d96d5ead3f7 ('iio: humidity: Add triggered buffer support for AM2315') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Tiberiu Breana <tiberiu.a.breana@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/am2315.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 0e35cf5ce00d873d6e529d2b2cd7598d52438051 Author: Alison Schofield <amsfield22@gmail.com> Date: Fri May 20 10:06:41 2016 -0700 iio: humidity: hdc100x: correct humidity integration time mask Apply the correct mask to enable all available humidity integration times. Currently, the driver defaults to 6500 and all is okay with that. However, if 3850 is selected we get a stuck bit and can't change back to 6500 or select 2500. (Verified with HDC1008) Signed-off-by: Alison Schofield <amsfield22@gmail.com> Cc: Daniel Baluta <daniel.baluta@gmail.com> Reviewed-by: Matt Ranostay <mranostay@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/hdc100x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b9ba1eb0336877b9b83556fd30d2becda110fd8c Author: Nicolas Chauvet <kwizart@gmail.com> Date: Tue May 10 12:26:42 2016 +0200 rtc: tps6586x: rename so module can be autoloaded This module is loaded by the related mfd driver which has the needed MODULE_DEVICE_TABLE(i2c,...). This patch fix the modalias when the rtc driver is built as a module, so the right name is used. Everything operates correctly when this module is builtin. Fixes: esdc59ed3865 ("rtc: add RTC driver for TPS6586x") Signed-off-by: Nicolas Chauvet <kwizart@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-tps6586x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 814db2bc4c4e19530eae818354dceb861ceb9fb1 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 4 11:50:02 2016 +0200 rtc: rv3029: hide unused i2c device table The added support for SPI mode made it possible to configure the driver when I2C is disabled, leaving an unused device table: drivers/rtc/rtc-rv3029c2.c:794:29: error: 'rv3029_id' defined but not used [-Werror=unused-variable] This moves the table inside of the #ifdef section that has the only user, to avoid the harmless warning. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: d08f50dd0afc ("rtc: rv3029: Add support of RV3049") Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit a9dbe558920e12ea286cd4479039df26991a95de Author: Thomas Koeller <thomas.koeller@baslerweb.com> Date: Wed Jun 2 15:53:05 2010 +0200 rtc: rs5c372: r2025: fix check for 'oscillator halted' condition The R2025SD chip, according to its data sheet, sets the /XST bit to zero if the oscillator stops. Hence the check for this condition was wrong. Signed-off-by: Thomas Koeller <thomas.koeller@baslerweb.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rs5c372.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0ddc5b89cd12938e251c691563f45409b4d15d98 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:38 2016 +0200 rtc: rv3029: add alarm IRQ Add the alarm IRQ functionality. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 114 ++++++++++++++++++++++++++++++++++++--------- 1 file changed, 93 insertions(+), 21 deletions(-) commit 38201ca3c58d27ac95ee08995558c7176b4feb13 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:37 2016 +0200 rtc: rv3029: fix set_time function The bin2bcd function in set_time is uncorrect on weekdays as the bit mask should be done at the end of arithmetic operations. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc492e866a997b3df2a551fa772d6887a19e53b8 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:36 2016 +0200 rtc: rv3029: fix alarm support The RTC RV3029 handles different types of alarms : seconds, minutes, ... These alarms can be enabled or disabled individually using an AE_x bit which is the last bit (BIT(7)) on each alarm registers. To prepare the alarm IRQ support, the current code enables all the alarm types by setting each AE_x to 1. It also fixes others alarms issues : - month and weekday errors : it was performing -1 instead of +1. - wrong use of bit mask with bin2bcd Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) commit abe2f551efc65760d61668ad6fb511bf834082dc Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:35 2016 +0200 rtc: rv3029: Remove some checks and warnings Remove some checks from checkpatch such as spaces around arithmetic operations or prefer "unsigned int". Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 68 +++++++++++++++++++++++----------------------- 1 file changed, 34 insertions(+), 34 deletions(-) commit c2a1c145401df063d1197ace5d3b5bd323e26f86 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:34 2016 +0200 rtc: rv3029: Add support of RV3049 Add support of Microcrystal RV3049 RTC (SPI) using regmap on the RV3029 (I2C) driver. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/Kconfig | 37 ++++++++-------- drivers/rtc/rtc-rv3029c2.c | 108 +++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 124 insertions(+), 21 deletions(-) commit e6e380821236b628a1379db97d777da3e36b8240 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:33 2016 +0200 rtc: rv3029: convert to use regmap To add support of rv3049, the current driver is converted to use regmap. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 275 +++++++++++++++++++++++---------------------- 1 file changed, 142 insertions(+), 133 deletions(-) commit 4e7f1a6051d7d5a62021fde0c9ed7005a1a82307 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue May 3 11:54:32 2016 +0200 rtc: rv3029: remove 'i2c' in functions names To prepare the use of regmap to add the support of RV-3049, all the 'i2c' in functions's names are removed. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-rv3029c2.c | 132 ++++++++++++++++++++------------------------- 1 file changed, 57 insertions(+), 75 deletions(-) commit 5469dc270cd44c451590d40c031e6a71c1f637e8 Merge: 2f37dd1 ea9b501 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 22:31:33 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge more updates from Andrew Morton: - the rest of MM - KASAN updates - procfs updates - exit, fork updates - printk updates - lib/ updates - radix-tree testsuite updates - checkpatch updates - kprobes updates - a few other misc bits * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (162 commits) samples/kprobes: print out the symbol name for the hooks samples/kprobes: add a new module parameter kprobes: add the "tls" argument for j_do_fork init/main.c: simplify initcall_blacklisted() fs/efs/super.c: fix return value checkpatch: improve --git <commit-count> shortcut checkpatch: reduce number of `git log` calls with --git checkpatch: add support to check already applied git commits checkpatch: add --list-types to show message types to show or ignore checkpatch: advertise the --fix and --fix-inplace options more checkpatch: whine about ACCESS_ONCE checkpatch: add test for keywords not starting on tabstops checkpatch: improve CONSTANT_COMPARISON test for structure members checkpatch: add PREFER_IS_ENABLED test lib/GCD.c: use binary GCD algorithm instead of Euclidean radix-tree: free up the bottom bit of exceptional entries for reuse dax: move RADIX_DAX_ definitions to dax.c radix-tree: make radix_tree_descend() more useful radix-tree: introduce radix_tree_replace_clear_tags() radix-tree: tidy up __radix_tree_create() ... commit 2f37dd131c5d3a2eac21cd5baf80658b1b02a8ac Merge: 3aa2fc1 ffc83a7 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 22:20:48 2016 -0700 Merge tag 'staging-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging and IIO driver updates from Greg KH: "Here's the big staging and iio driver update for 4.7-rc1. I think we almost broke even with this release, only adding a few more lines than we removed, which isn't bad overall given that there's a bunch of new iio drivers added. The Lustre developers seem to have woken up from their sleep and have been doing a great job in cleaning up the code and pruning unused or old cruft, the filesystem is almost readable :) Other than that, just a lot of basic coding style cleanups in the churn. All have been in linux-next for a while with no reported issues" * tag 'staging-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (938 commits) Staging: emxx_udc: emxx_udc: fixed coding style issue staging/gdm724x: fix "alignment should match open parenthesis" issues staging/gdm724x: Fix avoid CamelCase staging: unisys: rename misleading var ii with frag staging: unisys: visorhba: switch success handling to error handling staging: unisys: visorhba: main path needs to flow down the left margin staging: unisys: visorinput: handle_locking_key() simplifications staging: unisys: visorhba: fail gracefully for thread creation failures staging: unisys: visornic: comment restructuring and removing bad diction staging: unisys: fix format string %Lx to %llx for u64 staging: unisys: remove unused struct members staging: unisys: visorchannel: correct variable misspelling staging: unisys: visorhba: replace functionlike macro with function staging: dgnc: Need to check for NULL of ch staging: dgnc: remove redundant condition check staging: dgnc: fix 'line over 80 characters' staging: dgnc: clean up the dgnc_get_modem_info() staging: lustre: lnet: enable configuration per NI interface staging: lustre: o2iblnd: properly set ibr_why staging: lustre: o2iblnd: remove last of kiblnd_tunables_fini ... commit c5ed9268643c7c4c9f2aaa0fd4c936095e6480ef Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 14:50:12 2016 -0700 libnvdimm, dax: autodetect support For autodetecting a previously established dax configuration we need the info block to indicate block-device vs device-dax mode, and we need to have the default namespace probe hand-off the configuration to the dax_pmem driver. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/dax_devs.c | 35 +++++++++++++++++++++++++++++++++++ drivers/nvdimm/nd.h | 11 +++++++++-- drivers/nvdimm/pfn.h | 1 + drivers/nvdimm/pfn_devs.c | 15 ++++++++++----- drivers/nvdimm/pmem.c | 3 ++- 5 files changed, 57 insertions(+), 8 deletions(-) commit b354aba0165519a74f540f2ba89d7ec78efca21d Author: Dan Williams <dan.j.williams@intel.com> Date: Tue May 17 20:24:16 2016 -0700 libnvdimm: release ida resources ida instances allocate some internal memory for ->free_bitmap in addition to the base 'struct ida'. Use ida_destroy() to release that memory at module_exit(). Reported-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/core.c | 3 +++ drivers/nvdimm/dimm_devs.c | 5 +++++ drivers/nvdimm/nd-core.h | 2 ++ drivers/nvdimm/region_devs.c | 5 +++++ 4 files changed, 15 insertions(+) commit acc93d30d7d43f428272c20a047389c4cbca82ba Author: Dan Williams <dan.j.williams@intel.com> Date: Sat May 7 11:40:28 2016 -0700 Revert "block: enable dax for raw block devices" This reverts commit 5a023cdba50c5f5f2bc351783b3131699deb3937. The functionality is superseded by the new "Device DAX" facility. Cc: Jeff Moyer <jmoyer@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Dave Chinner <david@fromorbit.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Jan Kara <jack@suse.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> block/ioctl.c | 32 ----------------- fs/block_dev.c | 96 +++++++++++++++---------------------------------- include/linux/fs.h | 8 ----- include/uapi/linux/fs.h | 1 - 4 files changed, 29 insertions(+), 108 deletions(-) commit dee410792419aaa8bc3e3b35d2ccb6515835916d Author: Dan Williams <dan.j.williams@intel.com> Date: Sat May 14 12:20:44 2016 -0700 /dev/dax, core: file operations and dax-mmap The "Device DAX" core enables dax mappings of performance / feature differentiated memory. An open mapping or file handle keeps the backing struct device live, but new mappings are only possible while the device is enabled. Faults are handled under rcu_read_lock to synchronize with the enabled state of the device. Similar to the filesystem-dax case the backing memory may optionally have struct page entries. However, unlike fs-dax there is no support for private mappings, or mappings that are not backed by media (see use of zero-page in fs-dax). Mappings are always guaranteed to match the alignment of the dax_region. If the dax_region is configured to have a 2MB alignment, all mappings are guaranteed to be backed by a pmd entry. Contrast this determinism with the fs-dax case where pmd mappings are opportunistic. If userspace attempts to force a misaligned mapping, the driver will fail the mmap attempt. See dax_dev_check_vma() for other scenarios that are rejected, like MAP_PRIVATE mappings. Cc: Hannes Reinecke <hare@suse.de> Cc: Jeff Moyer <jmoyer@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Acked-by: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/dax/Kconfig | 1 + drivers/dax/dax.c | 322 ++++++++++++++++++++++++++++++++++++++++++++++++++++ mm/huge_memory.c | 1 + mm/hugetlb.c | 1 + 4 files changed, 325 insertions(+) commit ab68f26221366f92611650e8470e6a926801c7d4 Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 09:15:08 2016 -0700 /dev/dax, pmem: direct access to persistent memory Device DAX is the device-centric analogue of Filesystem DAX (CONFIG_FS_DAX). It allows memory ranges to be allocated and mapped without need of an intervening file system. Device DAX is strict, precise and predictable. Specifically this interface: 1/ Guarantees fault granularity with respect to a given page size (pte, pmd, or pud) set at configuration time. 2/ Enforces deterministic behavior by being strict about what fault scenarios are supported. For example, by forcing MADV_DONTFORK semantics and omitting MAP_PRIVATE support device-dax guarantees that a mapping always behaves/performs the same once established. It is the "what you see is what you get" access mechanism to differentiated memory vs filesystem DAX which has filesystem specific implementation semantics. Persistent memory is the first target, but the mechanism is also targeted for exclusive allocations of performance differentiated memory ranges. This commit is limited to the base device driver infrastructure to associate a dax device with pmem range. Cc: Jeff Moyer <jmoyer@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/Kconfig | 2 + drivers/Makefile | 1 + drivers/dax/Kconfig | 25 ++++ drivers/dax/Makefile | 4 + drivers/dax/dax.c | 253 ++++++++++++++++++++++++++++++++++++ drivers/dax/dax.h | 24 ++++ drivers/dax/pmem.c | 158 ++++++++++++++++++++++ tools/testing/nvdimm/Kbuild | 9 ++ tools/testing/nvdimm/config_check.c | 2 + 9 files changed, 478 insertions(+) commit 3aa2fc1667acdd9cca816a2bc9529f494bd61b05 Merge: 5af2344 c6e360a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 21:26:15 2016 -0700 Merge tag 'driver-core-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core Pull driver core updates from Greg KH: "Here's the "big" driver core update for 4.7-rc1. Mostly just debugfs changes, the long-known and messy races with removing debugfs files should be fixed thanks to the great work of Nicolai Stange. We also have some isa updates in here (the x86 maintainers told me to take it through this tree), a new warning when we run out of dynamic char major numbers, and a few other assorted changes, details in the shortlog. All have been in linux-next for some time with no reported issues" * tag 'driver-core-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (32 commits) Revert "base: dd: don't remove driver_data in -EPROBE_DEFER case" gpio: ws16c48: Utilize the ISA bus driver gpio: 104-idio-16: Utilize the ISA bus driver gpio: 104-idi-48: Utilize the ISA bus driver gpio: 104-dio-48e: Utilize the ISA bus driver watchdog: ebc-c384_wdt: Utilize the ISA bus driver iio: stx104: Utilize the module_isa_driver and max_num_isa_dev macros iio: stx104: Add X86 dependency to STX104 Kconfig option Documentation: Add ISA bus driver documentation isa: Implement the max_num_isa_dev macro isa: Implement the module_isa_driver macro pnp: pnpbios: Add explicit X86_32 dependency to PNPBIOS isa: Decouple X86_32 dependency from the ISA Kconfig option driver-core: use 'dev' argument in dev_dbg_ratelimited stub base: dd: don't remove driver_data in -EPROBE_DEFER case kernfs: Move faulting copy_user operations outside of the mutex devcoredump: add scatterlist support debugfs: unproxify files created through debugfs_create_u32_array() debugfs: unproxify files created through debugfs_create_blob() debugfs: unproxify files created through debugfs_create_bool() ... commit 5af2344013454640e0133bb62e8cf2e30190a472 Merge: 19e36ad 725d012 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 21:20:31 2016 -0700 Merge tag 'char-misc-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc Pull char / misc driver updates from Greg KH: "Here's the big char and misc driver update for 4.7-rc1. Lots of different tiny driver subsystems have updates here with new drivers and functionality. Details in the shortlog. All have been in linux-next with no reported issues for a while" * tag 'char-misc-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (125 commits) mcb: Delete num_cells variable which is not required mcb: Fixed bar number assignment for the gdd mcb: Replace ioremap and request_region with the devm version mcb: Implement bus->dev.release callback mcb: export bus information via sysfs mcb: Correctly initialize the bus's device mei: bus: call mei_cl_read_start under device lock coresight: etb10: adjust read pointer only when needed coresight: configuring ETF in FIFO mode when acting as link coresight: tmc: implementing TMC-ETF AUX space API coresight: moving struct cs_buffers to header file coresight: tmc: keep track of memory width coresight: tmc: make sysFS and Perf mode mutually exclusive coresight: tmc: dump system memory content only when needed coresight: tmc: adding mode of operation for link/sinks coresight: tmc: getting rid of multiple read access coresight: tmc: allocating memory when needed coresight: tmc: making prepare/unprepare functions generic coresight: tmc: splitting driver in ETB/ETF and ETR components coresight: tmc: cleaning up header file ... commit 19e36ad292ab24980db64a5ff17973d3118a8fb9 Merge: e10abc6 60d5794 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 21:12:25 2016 -0700 Merge tag 'usb-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Pull USB updates from Greg KH: "Here's the big pull request for USB and PHY drivers for 4.7-rc1 Full details in the shortlog, but it's the normal major gadget driver updates, phy updates, new usbip code, as well as a bit of lots of other stuff. All have been in linux-next with no reported issues" * tag 'usb-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (164 commits) USB: serial: ti_usb_3410_5052: add MOXA UPORT 11x0 support USB: serial: fix minor-number allocation USB: serial: quatech2: fix use-after-free in probe error path USB: serial: mxuport: fix use-after-free in probe error path USB: serial: keyspan: fix debug and error messages USB: serial: keyspan: fix URB unlink USB: serial: keyspan: fix use-after-free in probe error path USB: serial: io_edgeport: fix memory leaks in probe error path USB: serial: io_edgeport: fix memory leaks in attach error path usb: Remove unnecessary space before operator ','. usb: Remove unnecessary space before open square bracket. USB: FHCI: avoid redundant condition usb: host: xhci-rcar: Avoid long wait in xhci_reset() usb/host/fotg210: remove dead code in create_sysfs_files usb: wusbcore: Do not initialise statics to 0. usb: wusbcore: Remove space before ',' and '(' . USB: serial: cp210x: clean up CRTSCTS flag code USB: serial: cp210x: get rid of magic numbers in CRTSCTS flag code USB: serial: cp210x: fix hardware flow-control disable USB: serial: option: add even more ZTE device ids ... commit e10abc629f38efd9b6936cf3612583cc846104d9 Merge: 0eff458 d20bb59 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 20:57:27 2016 -0700 Merge tag 'tty-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty Pull tty and serial driver updates from Greg KH: "Here's the large TTY and Serial driver update for 4.7-rc1. A few new serial drivers are added here, and Peter has fixed a bunch of long-standing bugs in the tty layer and serial drivers as normal. Full details in the shortlog. All of these have been in linux-next for a while with no reported issues" * tag 'tty-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (88 commits) MAINTAINERS: 8250: remove website reference serial: core: Fix port mutex assert if lockdep disabled serial: 8250_dw: fix wrong logic in dw8250_check_lcr() tty: vt, finish looping on duplicate tty: vt, return error when con_startup fails QE-UART: add "fsl,t1040-ucc-uart" to of_device_id serial: mctrl_gpio: Drop support for out1-gpios and out2-gpios serial: 8250dw: Add device HID for future AMD UART controller Fix OpenSSH pty regression on close serial: mctrl_gpio: add IRQ locking serial: 8250: Integrate Fintek into 8250_base serial: mps2-uart: add support for early console serial: mps2-uart: add MPS2 UART driver dt-bindings: document the MPS2 UART bindings serial: sirf: Use generic uart-has-rtscts DT property serial: sirf: Introduce helper variable struct device_node *np serial: mxs-auart: Use generic uart-has-rtscts DT property serial: imx: Use generic uart-has-rtscts DT property doc: DT: Add Generic Serial Device Tree Bindings serial: 8250: of: Make tegra_serial_handle_break() static ... commit 0eff4589c36edd03d50b835d0768b2c2ef3f20bd Merge: 087afe8 ef56b79 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 20:18:12 2016 -0700 Merge tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk updates from Stephen Boyd: "It's the usual big pile of driver updates and additions, but we do have a couple core changes in here as well. Core: - CLK_IS_CRITICAL support has been added. This should allow drivers to properly express that a certain clk should stay on even if their prepare/enable count drops to 0 (and in turn the parents of these clks should stay enabled). - A clk registration API has been added, clk_hw_register(), and an OF clk provider API has been added, of_clk_add_hw_provider(). These APIs have been put in place to further split clk providers from clk consumers, with the goal being to have clk providers never deal with struct clk pointers at all. Conversion of provider drivers is on going. clkdev has also gained support for registering clk_hw pointers directly so we can convert drivers that don't use devicetree. New Drivers: - Marvell ap806 and cp110 system controllers (with clks inside!) - Hisilicon Hi3519 clock and reset controller - Axis ARTPEC-6 clock controllers - Oxford Semiconductor OXNAS clock controllers - AXS10X I2S PLL - Rockchip RK3399 clock and reset controller Updates: - MMC2 and UART2 clks on Samsung Exynos 3250, ACLK on Samsung Exynos 542x SoCs, and some more clk ID exporting for bus frequency scaling - Proper BCM2835 PCM clk support and various other clks - i.MX clk updates for i.MX6SX, i.MX7, and VF610 - Renesas updates for R-Car H3 - Tegra210 got updates for DisplayPort and HDMI 2.0 - Rockchip driver refactorings and fixes due to adding RK3399 support" * tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: (139 commits) clk: fix critical clock locking clk: qcom: mmcc-8996: Remove clocks that should be controlled by RPM clk: ingenic: Allow divider value to be divided clk: sunxi: Add display and TCON0 clocks driver clk: rockchip: drop old_rate calculation on pll rate changes clk: rockchip: simplify GRF handling in pll clocks clk: rockchip: lookup General Register Files in rockchip_clk_init clk: rockchip: fix the rk3399 sdmmc sample / drv name clk: mvebu: new driver for Armada CP110 system controller dt-bindings: arm: add DT binding for Marvell CP110 system controller clk: mvebu: new driver for Armada AP806 system controller clk: hisilicon: add CRG driver for hi3519 soc clk: hisilicon: export some hisilicon APIs to modules reset: hisilicon: add reset controller driver for hisilicon SOCs clk: bcm/kona: Do not use sizeof on pointer type clk: qcom: msm8916: Fix crypto clock flags clk: nxp: lpc18xx: Initialize clk_init_data::flags to 0 clk/axs10x: Add I2S PLL clock driver clk: imx7d: fix ahb clock mux 1 clk: fix comment of devm_clk_hw_register() ... commit 087afe8aaf562dc7a53f2577049830d6a3245742 Merge: 54cf809 95829b3 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 20:01:26 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Pull networking fixes and more updates from David Miller: 1) Tunneling fixes from Tom Herbert and Alexander Duyck. 2) AF_UNIX updates some struct sock bit fields with the socket lock, whereas setsockopt() sets overlapping ones with locking. Seperate out the synchronized vs. the AF_UNIX unsynchronized ones to avoid corruption. From Andrey Ryabinin. 3) Mount BPF filesystem with mount_nodev rather than mount_ns, from Eric Biederman. 4) A couple kmemdup conversions, from Muhammad Falak R Wani. 5) BPF verifier fixes from Alexei Starovoitov. 6) Don't let tunneled UDP packets get stuck in socket queues, if something goes wrong during the encapsulation just drop the packet rather than signalling an error up the call stack. From Hannes Frederic Sowa. 7) SKB ref after free in batman-adv, from Florian Westphal. 8) TCP iSCSI, ocfs2, rds, and tipc have to disable BH in it's TCP callbacks since the TCP stack runs pre-emptibly now. From Eric Dumazet. 9) Fix crash in fixed_phy_add, from Rabin Vincent. 10) Fix length checks in xen-netback, from Paul Durrant. 11) Fix mixup in KEY vs KEYID macsec attributes, from Sabrina Dubroca. 12) RDS connection spamming bug fixes from Sowmini Varadhan * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (152 commits) net: suppress warnings on dev_alloc_skb uapi glibc compat: fix compilation when !__USE_MISC in glibc udp: prevent skbs lingering in tunnel socket queues bpf: teach verifier to recognize imm += ptr pattern bpf: support decreasing order in direct packet access net: usb: ch9200: use kmemdup ps3_gelic: use kmemdup net:liquidio: use kmemdup bpf: Use mount_nodev not mount_ns to mount the bpf filesystem net: cdc_ncm: update datagram size after changing mtu tuntap: correctly wake up process during uninit intel: Add support for IPv6 IP-in-IP offload ip6_gre: Do not allow segmentation offloads GRE_CSUM is enabled with FOU/GUE RDS: TCP: Avoid rds connection churn from rogue SYNs RDS: TCP: rds_tcp_accept_worker() must exit gracefully when terminating rds-tcp net: sock: move ->sk_shutdown out of bitfields. ipv6: Don't reset inner headers in ip6_tnl_xmit ip4ip6: Support for GSO/GRO ip6ip6: Support for GSO/GRO ipv6: Set features for IPv6 tunnels ... commit 54cf809b9512be95f53ed4a5e3b631d1ac42f0fa Author: Peter Zijlstra <peterz@infradead.org> Date: Fri May 20 18:04:36 2016 +0200 locking,qspinlock: Fix spin_is_locked() and spin_unlock_wait() Similar to commits: 51d7d5205d33 ("powerpc: Add smp_mb() to arch_spin_is_locked()") d86b8da04dfa ("arm64: spinlock: serialise spin_unlock_wait against concurrent lockers") qspinlock suffers from the fact that the _Q_LOCKED_VAL store is unordered inside the ACQUIRE of the lock. And while this is not a problem for the regular mutual exclusive critical section usage of spinlocks, it breaks creative locking like: spin_lock(A) spin_lock(B) spin_unlock_wait(B) if (!spin_is_locked(A)) do_something() do_something() In that both CPUs can end up running do_something at the same time, because our _Q_LOCKED_VAL store can drop past the spin_unlock_wait() spin_is_locked() loads (even on x86!!). To avoid making the normal case slower, add smp_mb()s to the less used spin_unlock_wait() / spin_is_locked() side of things to avoid this problem. Reported-and-tested-by: Davidlohr Bueso <dave@stgolabs.net> Reported-by: Giovanni Gherdovich <ggherdovich@suse.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: stable@vger.kernel.org # v4.2 and later Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/asm-generic/qspinlock.h | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) commit b99a9e8776ca837344c6b64d518483fc5d5eefb4 Merge: be1332c 48a77aa Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 19:16:12 2016 -0700 Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 Pull cifs fixes from Steve French: "Two small cifs fixes, including one spnego upcall cifs security fix for stable" * 'for-next' of git://git.samba.org/sfrench/cifs-2.6: CIFS: Remove some obsolete comments cifs: Create dedicated keyring for spnego operations commit 24e49ee3d76b70853a96520e46b8837e5eae65b2 Author: Nitin Gupta <nitin.m.gupta@oracle.com> Date: Wed Mar 30 11:17:13 2016 -0700 sparc64: Reduce TLB flushes during hugepte changes During hugepage map/unmap, TSB and TLB flushes are currently issued at every PAGE_SIZE'd boundary which is unnecessary. We now issue the flush at REAL_HPAGE_SIZE boundaries only. Without this patch workloads which unmap a large hugepage backed VMA region get CPU lockups due to excessive TLB flush calls. Orabug: 22365539, 22643230, 22995196 Signed-off-by: Nitin Gupta <nitin.m.gupta@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/include/asm/pgtable_64.h | 43 +++++++++++++++++++++++++++--------- arch/sparc/include/asm/tlbflush_64.h | 3 ++- arch/sparc/mm/hugetlbpage.c | 33 ++++++++++++++++++++++----- arch/sparc/mm/init_64.c | 12 ---------- arch/sparc/mm/tlb.c | 25 +++++++++++++++------ arch/sparc/mm/tsb.c | 32 ++++++++++++++------------- 6 files changed, 97 insertions(+), 51 deletions(-) commit b1ac6b7b4061f6c92bacf6938f94fb61b2fbf7f3 Author: Sam Ravnborg <sam@ravnborg.org> Date: Sun Apr 24 18:39:52 2016 +0200 aeroflex/greth: fix warning about unused variable Fix following warning: aeroflex/greth.c:1326:11: warning: unused variable 'phy' [-Wunused-variable] The variable was unused - remove it. It looks like this warning has been there forever - was found by an allyesconfig build of sparc32. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Kristoffer Glembo <kristoffer@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/aeroflex/greth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 21916a4a2973ab1684e921689ef8a48a6626ac4c Author: Sam Ravnborg <sam@ravnborg.org> Date: Sun Apr 24 15:24:33 2016 +0200 openprom: fix warning Fix following warnings: openprom.c:510:2: warning: 'tmp' may be used uninitialized in this function [-Wmaybe-uninitialized] openprom.c:503:3: warning: 'str' may be used uninitialized in this function [-Wmaybe-uninitialized] openprom.c:459:8: warning: 'str' may be used uninitialized in this function [-Wmaybe-uninitialized] openprom.c:422:7: warning: 'str' may be used uninitialized in this function [-Wmaybe-uninitialized] Fixed by introducing PTR_ERR etc. This simplified the code as a nice side effect. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/sbus/char/openprom.c | 40 ++++++++++++++++------------------------ 1 file changed, 16 insertions(+), 24 deletions(-) commit ea9b50133ffebbd580cb5cd0aa222784d7a2fcb1 Author: Huang Shijie <shijie.huang@arm.com> Date: Fri May 20 17:04:36 2016 -0700 samples/kprobes: print out the symbol name for the hooks Print out the symbol name for the hooks, it makes the logs more readable. Link: http://lkml.kernel.org/r/1463535417-29637-2-git-send-email-shijie.huang@arm.com Signed-off-by: Huang Shijie <shijie.huang@arm.com> Cc: Petr Mladek <pmladek@suse.com> Cc: Steve Capper <steve.capper@arm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> samples/kprobes/kprobe_example.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) commit d04659ac94528e9224dbf1aed37dd11dd952cacc Author: Huang Shijie <shijie.huang@arm.com> Date: Fri May 20 17:04:33 2016 -0700 samples/kprobes: add a new module parameter Add a new module parameter which can be used as the symbol name. Without this patch, we can only test the "_do_fork" function with this kernel module. With this patch, the module becomes more flexible; we can test any functions with this module with # insmod kprobe_example.ko symbol="xxx" Link: http://lkml.kernel.org/r/1463535417-29637-1-git-send-email-shijie.huang@arm.com Signed-off-by: Huang Shijie <shijie.huang@arm.com> Cc: Petr Mladek <pmladek@suse.com> Cc: Steve Capper <steve.capper@arm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> samples/kprobes/kprobe_example.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 603ac5df86df5bfd26ed4d9c310dd196b07590ae Author: Huang Shijie <shijie.huang@arm.com> Date: Fri May 20 17:04:30 2016 -0700 kprobes: add the "tls" argument for j_do_fork Commit 3033f14ab78c ("clone: support passing tls argument via C rather than pt_regs magic") added the tls argument for _do_fork(). This patch adds the "tls" argument for j_do_fork to make it match _do_fork(). Signed-off-by: Huang Shijie <shijie.huang@arm.com> Acked-by: Steve Capper <steve.capper@arm.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Andy Lutomirski <luto@kernel.org> Cc: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> samples/kprobes/jprobe_example.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c8cdd2be213f0f5372287a764225665f1ac64e56 Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Fri May 20 17:04:27 2016 -0700 init/main.c: simplify initcall_blacklisted() Using kasprintf to get the function name makes us look up the name twice, along with all the vsnprintf overhead of parsing the format string etc. It also means there is an allocation failure case to deal with. Since symbol_string in vsprintf.c would anyway allocate an array of size KSYM_SYMBOL_LEN on the stack, that might as well be done up here. Moreover, since this is a debug feature and the blacklisted_initcalls list is usually empty, we might as well test that and thus avoid looking up the symbol name even once in the common case. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Acked-by: Prarit Bhargava <prarit@redhat.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> init/main.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 4108124f5c46efc951c4c6be947598a21d6b7fde Author: Heloise <os@iscas.ac.cn> Date: Fri May 20 17:04:25 2016 -0700 fs/efs/super.c: fix return value When sb_bread() fails, the return value should be -EIO, fix it. Link: http://lkml.kernel.org/r/1463464943-4142-1-git-send-email-os@iscas.ac.cn Signed-off-by: Heloise <os@iscas.ac.cn> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Firo Yang <firogm@gmail.com> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/efs/super.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 28898fd1a85fa37a59c090271e8be37afe710276 Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:22 2016 -0700 checkpatch: improve --git <commit-count> shortcut The --git <commit-count> shortcut can be confused by a tag with a dash like v4.4-rc1. Improve the test to verify the <commit-count> expression ends with a dash followed by a numeric value. Improve the git log result to verify the "<sha1> <subject>" output as well. Link: http://lkml.kernel.org/r/c4a3f759291d967641860c3a54bb81177f34325f.1462711962.git.joe@perches.com Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 0dea9f1eef86bedacad91b6f652ca1ab0d08854c Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:19 2016 -0700 checkpatch: reduce number of `git log` calls with --git checkpatch currently calls git log multiple times to first get the <revision range> sha1 values and again to get the subject for each individual sha1 commit. Always get the sha1 and subject at the same time instead. Store the subject in a sha1 hash to avoid the second git log exec. Link: http://lkml.kernel.org/r/274efab2332ad2308ab5de85a95d255f6e2de5f3.1462711962.git.joe@perches.com Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) commit 4a593c3448312906358b00898c29a95278d82cc9 Author: Du, Changbin <changbin.du@intel.com> Date: Fri May 20 17:04:16 2016 -0700 checkpatch: add support to check already applied git commits It's sometimes useful to scan already committed patches. Add --git <revision range> to scan specific or multiple commits. Single commits are scanned with --git <rev> Multiple commits are scanned with --git <range> --git <commit>-<count> [joe@perches.com: o Don't exec git for each <commit>-<count>, use a single "git log -<count> <commit>" o Consolidate the git exec for the <range> and <commit>-<count> variants o Output 12 character commit hash ids o Don't scan git commit merges o Use -M to reduce the size of rename commits] Signed-off-by: "Du, Changbin" <changbin.du@intel.com> Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 48 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) commit 3beb42eced39c00011ba4d608d52718af765e5d4 Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:14 2016 -0700 checkpatch: add --list-types to show message types to show or ignore The message types are not currently knowable without reading the code. Add a mechanism to see what they are. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) commit ef212196369cbc2e694eab39261f9785ec252028 Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:11 2016 -0700 checkpatch: advertise the --fix and --fix-inplace options more The --fix option is relatively unknown and underutilized. Add some text to show that it's available when style defects are found. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 8 ++++++++ 1 file changed, 8 insertions(+) commit 481aea5c59a57123b66d5850be1be79f9f230c0e Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:08 2016 -0700 checkpatch: whine about ACCESS_ONCE Add a test for use of ACCESS_ONCE that could be written using READ_ONCE or WRITE_ONCE. --fix it too if desired. The WRITE_ONCE fixes are less correct than the coccinelle script below as checkpatch cannot have a completely correct "expression" mechanism because checkpatch works on patches and not complete files. $ cat access_once.cocci @@ expression e1; expression e2; @@ - ACCESS_ONCE(e1) = e2 + WRITE_ONCE(e1, e2) @@ expression e1; @@ - ACCESS_ONCE(e1) + READ_ONCE(e1) Signed-off-by: Joe Perches <joe@perches.com> Cc: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit a91e8994f242a500bf05b9ee96fcd7ab0228f05f Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:05 2016 -0700 checkpatch: add test for keywords not starting on tabstops It's somewhat common and in general a defect for c90 keywords to not start on a tabstop. Add a test for this condition and warn when it occurs. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit f39e1769bbfc4936ff8364fb2529dc8bf6bc6888 Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:02 2016 -0700 checkpatch: improve CONSTANT_COMPARISON test for structure members A "." dereference to an all uppercase structure member can be incorrectly reported as a CONSTANT_COMPARISON. ie: "if (table[i].PANELID == tempdx)" Fix it by checking for "." before the constant test. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d6327459ec5e63a89b12945f483f6d7378a8839 Author: Joe Perches <joe@perches.com> Date: Fri May 20 17:04:00 2016 -0700 checkpatch: add PREFER_IS_ENABLED test Using #if defined CONFIG_<FOO> || defined CONFIG_<FOO>_MODULE is more verbose than necessary and IS_ENABLED(CONFIG_<FOO>) is preferred. So add a test and a message for it. --fix it to if desired. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/checkpatch.pl | 10 ++++++++++ 1 file changed, 10 insertions(+) commit fff7fb0b2d908dec779783d8eaf3d7725230f75e Author: Zhaoxiu Zeng <zhaoxiu.zeng@gmail.com> Date: Fri May 20 17:03:57 2016 -0700 lib/GCD.c: use binary GCD algorithm instead of Euclidean The binary GCD algorithm is based on the following facts: 1. If a and b are all evens, then gcd(a,b) = 2 * gcd(a/2, b/2) 2. If a is even and b is odd, then gcd(a,b) = gcd(a/2, b) 3. If a and b are all odds, then gcd(a,b) = gcd((a-b)/2, b) = gcd((a+b)/2, b) Even on x86 machines with reasonable division hardware, the binary algorithm runs about 25% faster (80% the execution time) than the division-based Euclidian algorithm. On platforms like Alpha and ARMv6 where division is a function call to emulation code, it's even more significant. There are two variants of the code here, depending on whether a fast __ffs (find least significant set bit) instruction is available. This allows the unpredictable branches in the bit-at-a-time shifting loop to be eliminated. If fast __ffs is not available, the "even/odd" GCD variant is used. I use the following code to benchmark: #include <stdio.h> #include <stdlib.h> #include <stdint.h> #include <string.h> #include <time.h> #include <unistd.h> #define swap(a, b) \ do { \ a ^= b; \ b ^= a; \ a ^= b; \ } while (0) unsigned long gcd0(unsigned long a, unsigned long b) { unsigned long r; if (a < b) { swap(a, b); } if (b == 0) return a; while ((r = a % b) != 0) { a = b; b = r; } return b; } unsigned long gcd1(unsigned long a, unsigned long b) { unsigned long r = a | b; if (!a || !b) return r; b >>= __builtin_ctzl(b); for (;;) { a >>= __builtin_ctzl(a); if (a == b) return a << __builtin_ctzl(r); if (a < b) swap(a, b); a -= b; } } unsigned long gcd2(unsigned long a, unsigned long b) { unsigned long r = a | b; if (!a || !b) return r; r &= -r; while (!(b & r)) b >>= 1; for (;;) { while (!(a & r)) a >>= 1; if (a == b) return a; if (a < b) swap(a, b); a -= b; a >>= 1; if (a & r) a += b; a >>= 1; } } unsigned long gcd3(unsigned long a, unsigned long b) { unsigned long r = a | b; if (!a || !b) return r; b >>= __builtin_ctzl(b); if (b == 1) return r & -r; for (;;) { a >>= __builtin_ctzl(a); if (a == 1) return r & -r; if (a == b) return a << __builtin_ctzl(r); if (a < b) swap(a, b); a -= b; } } unsigned long gcd4(unsigned long a, unsigned long b) { unsigned long r = a | b; if (!a || !b) return r; r &= -r; while (!(b & r)) b >>= 1; if (b == r) return r; for (;;) { while (!(a & r)) a >>= 1; if (a == r) return r; if (a == b) return a; if (a < b) swap(a, b); a -= b; a >>= 1; if (a & r) a += b; a >>= 1; } } static unsigned long (*gcd_func[])(unsigned long a, unsigned long b) = { gcd0, gcd1, gcd2, gcd3, gcd4, }; #define TEST_ENTRIES (sizeof(gcd_func) / sizeof(gcd_func[0])) #if defined(__x86_64__) #define rdtscll(val) do { \ unsigned long __a,__d; \ __asm__ __volatile__("rdtsc" : "=a" (__a), "=d" (__d)); \ (val) = ((unsigned long long)__a) | (((unsigned long long)__d)<<32); \ } while(0) static unsigned long long benchmark_gcd_func(unsigned long (*gcd)(unsigned long, unsigned long), unsigned long a, unsigned long b, unsigned long *res) { unsigned long long start, end; unsigned long long ret; unsigned long gcd_res; rdtscll(start); gcd_res = gcd(a, b); rdtscll(end); if (end >= start) ret = end - start; else ret = ~0ULL - start + 1 + end; *res = gcd_res; return ret; } #else static inline struct timespec read_time(void) { struct timespec time; clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &time); return time; } static inline unsigned long long diff_time(struct timespec start, struct timespec end) { struct timespec temp; if ((end.tv_nsec - start.tv_nsec) < 0) { temp.tv_sec = end.tv_sec - start.tv_sec - 1; temp.tv_nsec = 1000000000ULL + end.tv_nsec - start.tv_nsec; } else { temp.tv_sec = end.tv_sec - start.tv_sec; temp.tv_nsec = end.tv_nsec - start.tv_nsec; } return temp.tv_sec * 1000000000ULL + temp.tv_nsec; } static unsigned long long benchmark_gcd_func(unsigned long (*gcd)(unsigned long, unsigned long), unsigned long a, unsigned long b, unsigned long *res) { struct timespec start, end; unsigned long gcd_res; start = read_time(); gcd_res = gcd(a, b); end = read_time(); *res = gcd_res; return diff_time(start, end); } #endif static inline unsigned long get_rand() { if (sizeof(long) == 8) return (unsigned long)rand() << 32 | rand(); else return rand(); } int main(int argc, char **argv) { unsigned int seed = time(0); int loops = 100; int repeats = 1000; unsigned long (*res)[TEST_ENTRIES]; unsigned long long elapsed[TEST_ENTRIES]; int i, j, k; for (;;) { int opt = getopt(argc, argv, "n:r:s:"); /* End condition always first */ if (opt == -1) break; switch (opt) { case 'n': loops = atoi(optarg); break; case 'r': repeats = atoi(optarg); break; case 's': seed = strtoul(optarg, NULL, 10); break; default: /* You won't actually get here. */ break; } } res = malloc(sizeof(unsigned long) * TEST_ENTRIES * loops); memset(elapsed, 0, sizeof(elapsed)); srand(seed); for (j = 0; j < loops; j++) { unsigned long a = get_rand(); /* Do we have args? */ unsigned long b = argc > optind ? strtoul(argv[optind], NULL, 10) : get_rand(); unsigned long long min_elapsed[TEST_ENTRIES]; for (k = 0; k < repeats; k++) { for (i = 0; i < TEST_ENTRIES; i++) { unsigned long long tmp = benchmark_gcd_func(gcd_func[i], a, b, &res[j][i]); if (k == 0 || min_elapsed[i] > tmp) min_elapsed[i] = tmp; } } for (i = 0; i < TEST_ENTRIES; i++) elapsed[i] += min_elapsed[i]; } for (i = 0; i < TEST_ENTRIES; i++) printf("gcd%d: elapsed %llu\n", i, elapsed[i]); k = 0; srand(seed); for (j = 0; j < loops; j++) { unsigned long a = get_rand(); unsigned long b = argc > optind ? strtoul(argv[optind], NULL, 10) : get_rand(); for (i = 1; i < TEST_ENTRIES; i++) { if (res[j][i] != res[j][0]) break; } if (i < TEST_ENTRIES) { if (k == 0) { k = 1; fprintf(stderr, "Error:\n"); } fprintf(stderr, "gcd(%lu, %lu): ", a, b); for (i = 0; i < TEST_ENTRIES; i++) fprintf(stderr, "%ld%s", res[j][i], i < TEST_ENTRIES - 1 ? ", " : "\n"); } } if (k == 0) fprintf(stderr, "PASS\n"); free(res); return 0; } Compiled with "-O2", on "VirtualBox 4.4.0-22-generic #38-Ubuntu x86_64" got: zhaoxiuzeng@zhaoxiuzeng-VirtualBox:~/develop$ ./gcd -r 500000 -n 10 gcd0: elapsed 10174 gcd1: elapsed 2120 gcd2: elapsed 2902 gcd3: elapsed 2039 gcd4: elapsed 2812 PASS zhaoxiuzeng@zhaoxiuzeng-VirtualBox:~/develop$ ./gcd -r 500000 -n 10 gcd0: elapsed 9309 gcd1: elapsed 2280 gcd2: elapsed 2822 gcd3: elapsed 2217 gcd4: elapsed 2710 PASS zhaoxiuzeng@zhaoxiuzeng-VirtualBox:~/develop$ ./gcd -r 500000 -n 10 gcd0: elapsed 9589 gcd1: elapsed 2098 gcd2: elapsed 2815 gcd3: elapsed 2030 gcd4: elapsed 2718 PASS zhaoxiuzeng@zhaoxiuzeng-VirtualBox:~/develop$ ./gcd -r 500000 -n 10 gcd0: elapsed 9914 gcd1: elapsed 2309 gcd2: elapsed 2779 gcd3: elapsed 2228 gcd4: elapsed 2709 PASS [akpm@linux-foundation.org: avoid #defining a CONFIG_ variable] Signed-off-by: Zhaoxiu Zeng <zhaoxiu.zeng@gmail.com> Signed-off-by: George Spelvin <linux@horizon.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/Kconfig | 3 ++ arch/alpha/Kconfig | 1 + arch/arc/Kconfig | 1 + arch/arm/mm/Kconfig | 3 ++ arch/h8300/Kconfig | 1 + arch/m32r/Kconfig | 1 + arch/m68k/Kconfig.cpu | 11 ++++++ arch/metag/Kconfig | 1 + arch/microblaze/Kconfig | 1 + arch/mips/include/asm/cpu-features.h | 10 +++++ arch/nios2/Kconfig | 1 + arch/openrisc/Kconfig | 1 + arch/parisc/Kconfig | 1 + arch/s390/Kconfig | 1 + arch/score/Kconfig | 1 + arch/sh/Kconfig | 1 + arch/sparc/Kconfig | 1 + lib/gcd.c | 77 +++++++++++++++++++++++++++++++----- 18 files changed, 107 insertions(+), 10 deletions(-) commit 3bcadd6fa6c4fd07ace3626357c824eb532488a6 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:54 2016 -0700 radix-tree: free up the bottom bit of exceptional entries for reuse We are guaranteed that pointers to radix_tree_nodes always have the bottom two bits clear (because they come from a slab cache, and slab caches have a minimum alignment of sizeof(void *)), so we can redefine 'radix_tree_is_internal_node' to only return true if the bottom two bits have value '01'. This frees up one quarter of the potential values for use by the user. Idea from Neil Brown. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Suggested-by: Neil Brown <neilb@suse.de> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 38 +++++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 15 deletions(-) commit 78a9be0a0a3367b94af242632c525d22b26f1a87 Author: NeilBrown <neilb@suse.com> Date: Fri May 20 17:03:51 2016 -0700 dax: move RADIX_DAX_ definitions to dax.c These don't belong in radix-tree.h any more than PAGECACHE_TAG_* do. Let's try to maintain the idea that radix-tree simply implements an abstract data type. Signed-off-by: NeilBrown <neilb@suse.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/dax.c | 9 +++++++++ include/linux/radix-tree.h | 9 --------- 2 files changed, 9 insertions(+), 9 deletions(-) commit 9e85d811196583126785a0405d0c879ae7a9eb2f Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:48 2016 -0700 radix-tree: make radix_tree_descend() more useful Now that the shift amount is stored in the node, radix_tree_descend() can calculate offset itself from index, which removes several lines of code from each of the tree walkers. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 78 +++++++++++++++++++------------------------------------- 1 file changed, 26 insertions(+), 52 deletions(-) commit d604c324524bf61c68182bb27db64656a78fe911 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:45 2016 -0700 radix-tree: introduce radix_tree_replace_clear_tags() In addition to replacing the entry, we also clear all associated tags. This is really a one-off special for page_cache_tree_delete() which had far too much detailed knowledge about how the radix tree works. For efficiency, factor node_tag_clear() out of radix_tree_tag_clear() It can be used by radix_tree_delete_item() as well as radix_tree_replace_clear_tags(). Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 9 ++++-- lib/radix-tree.c | 76 ++++++++++++++++++++++++++++------------------ mm/filemap.c | 23 ++------------ 3 files changed, 56 insertions(+), 52 deletions(-) commit 89148aa40201def3fa552f9d07dd99740d880ab2 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:42 2016 -0700 radix-tree: tidy up __radix_tree_create() 1. Rename the existing variable 'slot' to 'child'. 2. Introduce a new variable called 'slot' which is the address of the slot we're dealing with. This lets us simplify the tree insertion, and removes the recalculation of 'slot' at the end of the function. 3. Using 'slot' in the sibling pointer insertion part makes the code more readable. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 48 +++++++++++++++++++++++------------------------- 1 file changed, 23 insertions(+), 25 deletions(-) commit a8e4da25d3c573a0c3cf2fb33e91ec5cad8d7f16 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:39 2016 -0700 radix-tree: tidy up range_tag_if_tagged Convert radix_tree_range_tag_if_tagged to name the nodes parent, node and child instead of node & slot. Use parent->offset instead of playing games with 'upindex'. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 39 +++++++++++++++++---------------------- 1 file changed, 17 insertions(+), 22 deletions(-) commit 8c1244de00ef98f73e21eecc42d84b2742fbb4f9 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:36 2016 -0700 radix-tree: tidy up next_chunk Convert radix_tree_next_chunk to use 'child' instead of 'slot' as the name of the child node. Also use node_maxindex() where it makes sense. The 'rnode' variable was unnecessary; it doesn't overlap in usage with 'node', so we can just use 'node' the whole way through the function. Improve the testcase to start the walk from every index in the carefully constructed tree, and to accept any index within the range covered by the entry. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 53 +++++++------------ tools/testing/radix-tree/multiorder.c | 99 +++++++++++++++++++---------------- 2 files changed, 74 insertions(+), 78 deletions(-) commit af49a63e101eb62376cc1d6bd25b97eb8c691d54 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:33 2016 -0700 radix-tree: change naming conventions in radix_tree_shrink Use the more standard 'node' and 'child' instead of 'to_free' and 'slot'. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit b194d16c27af905d6e3552f4851bc7d9fee4e90f Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:30 2016 -0700 radix-tree: rename radix_tree_is_indirect_ptr() As with indirect_to_ptr(), ptr_to_indirect() and RADIX_TREE_INDIRECT_PTR, change radix_tree_is_indirect_ptr() to radix_tree_is_internal_node(). Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 10 ++++----- lib/radix-tree.c | 48 ++++++++++++++++++++--------------------- tools/testing/radix-tree/test.c | 4 ++-- 3 files changed, 31 insertions(+), 31 deletions(-) commit 4dd6c0987ca43d6544f4f0a3f86f6ea3bfc60fc1 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:27 2016 -0700 radix-tree: rename indirect_to_ptr() to entry_to_node() Mirrors the earlier commit introducing node_to_entry(). Also change the type returned to be a struct radix_tree_node pointer. That lets us simplify a couple of places in the radix tree shrink & extend paths where we could convert an entry into a pointer, modify the node, then convert the pointer back into an entry. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 12 +++++------ lib/radix-tree.c | 48 ++++++++++++++++++----------------------- tools/testing/radix-tree/test.c | 4 ++-- tools/testing/radix-tree/test.h | 1 - 4 files changed, 28 insertions(+), 37 deletions(-) commit a4db4dcea1b3990e8c5dc8a03d11f36a3c0c6d8b Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:24 2016 -0700 radix-tree: rename ptr_to_indirect() to node_to_entry() ptr_to_indirect() was a bad name. What it really means is "Convert this pointer to a node into an entry suitable for storing in the radix tree". So node_to_entry() seemed like a better name. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit 30ff46ccb303fb6f6c28b9aa9f2cdc4ba900ed3f Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:22 2016 -0700 radix-tree: rename INDIRECT_PTR to INTERNAL_NODE The name RADIX_TREE_INDIRECT_PTR doesn't really match the meaning. RADIX_TREE_INTERNAL_NODE is a better name. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 30 +++++++++++++----------------- lib/radix-tree.c | 2 +- 2 files changed, 14 insertions(+), 18 deletions(-) commit d0891265bbc988dc91ed8580b38eb3dac128581b Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:19 2016 -0700 radix-tree: remove root->height The only remaining references to root->height were in extend and shrink, where it was updated. Now we can remove it entirely. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 3 -- lib/radix-tree.c | 106 +++++++++++++-------------------------------- 2 files changed, 31 insertions(+), 78 deletions(-) commit 0694f0c9e20c47063e4237e5f6649ae5ce5a369a Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:16 2016 -0700 radix tree test suite: remove dependencies on height verify_node() can use node->shift instead of the height. tree_verify_min_height() can be converted over to using node_maxindex() and shift_maxindex() instead of radix_tree_maxindex(). Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/test.c | 34 +++++++++++++++++++++++----------- tools/testing/radix-tree/test.h | 3 ++- 2 files changed, 25 insertions(+), 12 deletions(-) commit fb209019c92a9141fd73f3c4928edc1b299b3490 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:13 2016 -0700 radix-tree: remove a use of root->height from delete_node If radix_tree_shrink returns whether it managed to shrink, then __radix_tree_delete_node doesn't ned to query the tree to find out whether it did any work or not. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit c12e51b07b3ac4c188fd91a82f96840fdb9cca6f Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:10 2016 -0700 radix-tree: replace node->height with node->shift node->shift represents the shift necessary for looking in the slots array at this level. It is equal to the old (node->height - 1) * RADIX_TREE_MAP_SHIFT. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 2 +- lib/radix-tree.c | 30 ++++++++++++++++-------------- 2 files changed, 17 insertions(+), 15 deletions(-) commit 0c7fa0a8418cbe0e8963fe36db9575d03b8589f7 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:07 2016 -0700 radix-tree: split node->path into offset and height Neither piece of information we're storing in node->path can be larger than 64, so store each in its own unsigned char instead of shifting and masking to store them both in an unsigned int. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 7 ++----- lib/radix-tree.c | 38 +++++++++++++++++--------------------- 2 files changed, 19 insertions(+), 26 deletions(-) commit 2fcd9005cc03ab09ea2a940515ed728d43df66c4 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:04 2016 -0700 radix-tree: miscellaneous fixes Typos, whitespace, grammar, line length, using the correct types, etc. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 70 +++++++++++++++++++++++++++++--------------------------- 1 file changed, 36 insertions(+), 34 deletions(-) commit b76ba4af4ddd6a06f7f65769e7be1bc56556cdf5 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:03:01 2016 -0700 drivers/hwspinlock: use correct radix tree API radix_tree_is_indirect_ptr() is an internal API. The correct call to use is radix_tree_deref_retry() which has the appropriate unlikely() annotation. Fixes: c6400ba7e13a ("drivers/hwspinlock: fix race between radix tree insertion and lookup") Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/hwspinlock/hwspinlock_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6b053b8e5f5e12089fbbc127167199746bb5b4c1 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:58 2016 -0700 radix-tree: add copyright statements The multiorder support is a sufficiently large feature to be worth adding copyrigt lines for. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 2 ++ 1 file changed, 2 insertions(+) commit 0796c58325533f87c00949a545eb607baa8441cb Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:55 2016 -0700 radix-tree: fix radix_tree_dump() for multi-order entries - Print which indices are covered by every leaf entry - Print sibling entries - Print the node pointer instead of the slot entry - Build by default in userspace, and make it accessible to the test-suite Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 48 +++++++++++++++++++++++++---------------- tools/testing/radix-tree/test.h | 1 + 2 files changed, 30 insertions(+), 19 deletions(-) commit 070c5ac2740b5db89d381a09fb03b2480b2f7a74 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:52 2016 -0700 radix-tree: fix radix_tree_range_tag_if_tagged() for multiorder entries I had previously decided that tagging a single multiorder entry would count as tagging 2^order entries for the purposes of 'nr_to_tag'. I now believe that decision to be a mistake, and it should count as a single entry. That's more likely to be what callers expect. When walking back up the tree from a newly-tagged entry, the current code assumed we were starting from the lowest level of the tree; if we have a multiorder entry with an order at least RADIX_TREE_MAP_SHIFT in size then we need to shift the index by 'shift' before we start walking back up the tree, or we will end up not setting tags on higher entries, and then mistakenly thinking that entries below a certain point in the tree are not tagged. If the first index we examine is a sibling entry of a tagged multiorder entry, we were not tagging it. We need to examine the canonical entry, and the easiest way to do that is to use radix_tree_descend(). We then have to skip over sibling slots when looking for the next entry in the tree or we will end up walking back to the canonical entry. Add several tests for radix_tree_range_tag_if_tagged(). Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 76 +++++++++++++++-------------------- tools/testing/radix-tree/multiorder.c | 25 +++++++++++- tools/testing/radix-tree/tag_check.c | 10 +++++ 3 files changed, 67 insertions(+), 44 deletions(-) commit eb73f7f3300c144c4b886dd56ea4c3d2b2d58249 Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:49 2016 -0700 radix-tree: add test for radix_tree_locate_item() Add a unit test that provides coverage for the bug fixed in the commit entitled "radix-tree: rewrite radix_tree_locate_item fix" from Hugh Dickins. I've verified that this test fails before his patch due to miscalculated 'index' values in __locate() in lib/radix-tree.c, and passes with his fix. Link: http://lkml.kernel.org/r/1462307263-20623-1-git-send-email-ross.zwisler@linux.intel.com Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.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> tools/testing/radix-tree/linux/init.h | 1 + tools/testing/radix-tree/main.c | 15 ++++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) commit 0a2efc6c809b01872321d9c7e7d82d59ac6fde10 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:46 2016 -0700 radix-tree: rewrite radix_tree_locate_item Use the new multi-order support functions to rewrite radix_tree_locate_item(). Modify the locate tests to test multiorder entries too. [hughd@google.com: radix_tree_locate_item() is often returning the wrong index] Link: http://lkml.kernel.org/r/alpine.LSU.2.11.1605012108490.1166@eggly.anvils Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 87 ++++++++++++++++++++--------------------- tools/testing/radix-tree/main.c | 30 ++++++++------ 2 files changed, 61 insertions(+), 56 deletions(-) commit 8a14f4d8328cc8615f8a5487c4173f36a8314796 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:44 2016 -0700 radix-tree: fix radix_tree_create for sibling entries If the radix tree user attempted to insert a colliding entry with an existing multiorder entry, then radix_tree_create() could encounter a sibling entry when walking down the tree to look for a slot. Use radix_tree_descend() to fix the problem, and add a test-case to make sure the problem doesn't come back in future. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 4 ++-- tools/testing/radix-tree/multiorder.c | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) commit 0fc9b8ca2b1df4948e9516697b1cf12f030968bd Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:41 2016 -0700 radix-tree test suite: add multi-order tag test Add a generic test for multi-order tag verification, and call it using several different configurations. This test creates a multi-order radix tree using the given index and order, and then sets, checks and clears tags using the indices covered by the single multi-order radix tree entry. With the various calls done by this test we verify root multi-order entries without siblings, multi-order entries without siblings in a radix tree node, as well as multi-order entries with siblings of various sizes. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/multiorder.c | 97 +++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) commit 4589ba6d0f439e4673830fdc65099179832ddde5 Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:38 2016 -0700 radix-tree: rewrite radix_tree_tag_get Use the new multi-order support functions to rewrite radix_tree_tag_get() Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 44 ++++++++++++++++++-------------------------- 1 file changed, 18 insertions(+), 26 deletions(-) commit 00f47b581105b91f8f18edd3074322ae609a8bc5 Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:35 2016 -0700 radix-tree: rewrite radix_tree_tag_clear Use the new multi-order support functions to rewrite radix_tree_tag_clear() Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 44 ++++++++++++++++++++------------------------ 1 file changed, 20 insertions(+), 24 deletions(-) commit fb969909dd18930ad68d8f8b8e7895816cf74b0a Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:32 2016 -0700 radix-tree: rewrite radix_tree_tag_set Use the new multi-order support functions to rewrite radix_tree_tag_set() Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) commit 643b57d0a9bd4c93625a2f5da4cebc3ceb402b9b Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:29 2016 -0700 radix tree test suite: multi-order iteration test Add a unit test to verify that we can iterate over multi-order entries properly via a radix_tree_for_each_slot() loop. This was done with a single, somewhat complicated configuration that was meant to test many of the various corner cases having to do with multi-order entries: - An iteration could begin at a sibling entry, and we need to return the canonical entry. - We could have entries of various orders in the same slots[] array. - We could have multi-order entries at a nonzero height, followed by indirect pointers to more radix tree nodes later in that same slots[] array. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/multiorder.c | 92 +++++++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) commit 21ef533931f73a8e963a6107aa5ec51b192f28be Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:02:26 2016 -0700 radix-tree: add support for multi-order iterating This enables the macros radix_tree_for_each_slot() and friends to be used with multi-order entries. The way that this works is that we treat all entries in a given slots[] array as a single chunk. If the index given to radix_tree_next_chunk() happens to point us to a sibling entry, we will back up iter->index so that it points to the canonical entry, and that will be the place where we start our iteration. As we're processing a chunk in radix_tree_next_slot(), we process canonical entries, skip over sibling entries, and restart the chunk lookup if we find a non-sibling indirect pointer. This drops back to the radix_tree_next_chunk() code, which will re-walk the tree and look for another chunk. This allows us to properly handle multi-order entries mixed with other entries that are at various heights in the radix tree. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 69 +++++++++++++++++++++++---- lib/radix-tree.c | 66 ++++++++++++++----------- tools/testing/radix-tree/generated/autoconf.h | 3 ++ tools/testing/radix-tree/linux/kernel.h | 5 +- 4 files changed, 102 insertions(+), 41 deletions(-) commit 7b60e9ad59a31dd98c2f7ef841e2882c2b0e0f3b Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:23 2016 -0700 radix-tree: fix multiorder BUG_ON in radix_tree_insert These BUG_ON tests are to ensure that all the tags are clear when inserting a new entry. If we insert a multiorder entry, we'll end up looking at the tags for a different node, and so the BUG_ON can end up triggering spuriously. Also, we now have three tags, not two, so check all three are clear, and check all the root tags with a single call to BUG_ON since the bits are stored contiguously. Include a test-case to ensure this problem does not reoccur. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 14 ++++++++++---- tools/testing/radix-tree/multiorder.c | 12 ++++++++++++ 2 files changed, 22 insertions(+), 4 deletions(-) commit 858299544efcf2577511bb018b9e73637ac71a2f Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:20 2016 -0700 radix-tree: rewrite __radix_tree_lookup Use the new multi-order support functions to rewrite __radix_tree_lookup() Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 48 ++++++++++++++++-------------------------------- 1 file changed, 16 insertions(+), 32 deletions(-) commit afe0e395b6d1817fa5393f1ad6fcbf71406b016d Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:17 2016 -0700 radix-tree: fix several shrinking bugs with multiorder entries Setting the indirect bit on the user data entry used to be unambiguous because the tree walking code knew not to expect internal nodes in the last level of the tree. Multiorder entries can appear at any level of the tree, and a leaf with the indirect bit set is indistinguishable from a pointer to a node. Introduce a special entry (RADIX_TREE_RETRY) which is neither a valid user entry, nor a valid pointer to a node. The radix_tree_deref_retry() function continues to work the same way, but tree walking code can distinguish it from a pointer to a node. Also fix the condition for setting slot->parent to NULL; it does not matter what height the tree is, it only matters whether slot is an indirect pointer. Move this code above the comment which is referring to the assignment to root->rnode. Also fix the condition for preventing the tree from shrinking to a single entry if it's a multiorder entry. Add a test-case to the test suite that checks that the tree goes back down to its original height after an item is inserted & deleted from a higher index in the tree. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 23 +++++++++++---------- tools/testing/radix-tree/multiorder.c | 39 +++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+), 11 deletions(-) commit 4f3755d1ae3cd856a5c7da3dea12cced8dc51fbf Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:14 2016 -0700 radix tree test suite: start adding multiorder tests Test suite infrastructure for working with multiorder entries. The test itself is pretty basic: Add an entry, check that all expected indices return that entry and that indices around that entry don't return an entry. Then delete the entry and check no index returns that entry. Tests a few edge conditions including the multiorder entry at index 0 and at a higher index. Also tests deleting through an alias as well as through the canonical index. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/Makefile | 2 +- tools/testing/radix-tree/main.c | 2 ++ tools/testing/radix-tree/multiorder.c | 58 +++++++++++++++++++++++++++++++++++ tools/testing/radix-tree/test.c | 13 ++++++-- tools/testing/radix-tree/test.h | 6 +++- 5 files changed, 76 insertions(+), 5 deletions(-) commit 49ea6ebcd3080ebf2c589b5f1437dd8bb2f90395 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:11 2016 -0700 radix-tree: fix extending the tree for multi-order entries at offset 0 The current code will insert entries at each level, as if we're going to add a new entry at the bottom level, so we then get an -EEXIST when we try to insert the entry into the tree. The best way to fix this is to not check 'order' when inserting into an empty tree. We still need to 'extend' the tree to the height necessary for the maximum index corresponding to this entry, so pass that value to radix_tree_extend() rather than the index we're asked to create, or we won't create a tree that's deep enough. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) commit 1456a439fc2dcc0c3d1a2d7af1fd83962813aaee Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:08 2016 -0700 radix-tree: introduce radix_tree_load_root() All the tree walking functions start with some variant of this code; centralise it in one place so we're not chasing subtly different bugs everywhere. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit aa5475760235672f316fbf29cdfb82a75016dbdf Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:05 2016 -0700 radix-tree: remove restriction on multi-order entries Now that sibling pointers are handled explicitly, there is no purpose served by restricting the order to be >= RADIX_TREE_MAP_SHIFT. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 2 -- 1 file changed, 2 deletions(-) commit 29e0967c2f66771f654cef7168c90a53737abcdf Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:02:02 2016 -0700 radix-tree: fix deleting a multi-order entry through an alias If we deleted an entry through an index which looked up a sibling pointer, we'd end up zeroing out the wrong slots in the node. Use get_slot_offset() to find the right slot. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3b8c00f68405e9c037a6d8ae0d5d9da7f8a34e6a Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:59 2016 -0700 radix-tree: fix sibling entry insertion The subtraction was the wrong way round, leading to undefined behaviour (shift by an amount larger than the size of the type). Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit db050f2924fcf39428bdadf28970a32cfaf256ef Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:57 2016 -0700 radix-tree: add missing sibling entry functionality The code I previously added to enable multiorder radix tree entries was untested and therefore buggy. This commit adds the support functions that Ross and I decided were necessary over a four-week period of iterating various designs. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/radix-tree.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 57578c2ea2cb2e0d362a9212ac83cf90221d4883 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:54 2016 -0700 raxix-tree: introduce CONFIG_RADIX_TREE_MULTIORDER I've been receiving increasingly concerned notes from 0day about how much my recent changes have been bloating the radix tree. Make it happier by only including multiorder support if CONFIG_TRANSPARENT_HUGEPAGES is set. This is an independent Kconfig option, so other radix tree users can also set it if they have a need. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/Kconfig | 3 +++ lib/radix-tree.c | 26 ++++++++++++++++++-------- mm/Kconfig | 1 + tools/testing/radix-tree/linux/kernel.h | 1 + 4 files changed, 23 insertions(+), 8 deletions(-) commit 6c4bd68a2962c03423a226d949caf64216d013cc Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:01:51 2016 -0700 radix-tree: remove unused looping macros radix_tree_for_each_chunk() and radix_tree_for_each_chunk_slot() have never been used in the kernel since their introduction in 2012, so remove them. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 28 ---------------------------- 1 file changed, 28 deletions(-) commit 7f308671c79899c1b4e275867d3647f64e896e78 Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:01:48 2016 -0700 radix tree test suite: rebuild when headers change When we make changes to radix-tree.h in the regular kernel source (include/linux/radix-tree.h), we really want our test code to be rebuilt. We also include a few other headers from tools/include and probably want to rebuild if these have been changed. Update the makefile so that all of our objects will be rebuilt when any of the headers we depend on are changed. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa1d62d8530d5adf158dd633d360108466f93fcd Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:01:45 2016 -0700 radix tree test suite: keep regression test runs short Currently the full suite of regression tests take upwards of 30 minutes to run on my development machine. The vast majority of this time is taken by the big_gang_check() and copy_tag_check() tests, which each run their tests through thousands of iterations...does this have value? Without big_gang_check() and copy_tag_check(), the test suite runs in around 15 seconds on my box. Honestly the first time I ever ran through the entire test suite was to gather the timings for this email - it simply takes too long to be useful on a normal basis. Instead, hide the excessive iterations through big_gang_check() and copy_tag_check() tests behind an '-l' flag (for "long run") in case they are still useful, but allow the regression test suite to complete in a reasonable amount of time. We still run each of these tests a few times (3 at present) to try and keep the test coverage. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/main.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit 97d778b2de9213c7a7483dad0f533c1af9f0810f Author: Ross Zwisler <ross.zwisler@linux.intel.com> Date: Fri May 20 17:01:42 2016 -0700 radix tree test suite: allow testing other fan-out values The defines in regression2.c are already in radix-tree.h and duplicating them in the test case makes experimenting with other values for the fan-out harder than necessary. Allow the user of the radix tree to decide what the fan-out should be rather than fixing it to 8 for non-kernel uses. Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 4 +--- tools/testing/radix-tree/linux/kernel.h | 2 ++ tools/testing/radix-tree/regression2.c | 7 ------- 3 files changed, 3 insertions(+), 10 deletions(-) commit d42cb1a9fffa9dc760c13302f00cdec25106e2f1 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:39 2016 -0700 radix tree test suite: add tests for radix_tree_locate_item() Fairly simple tests; add various items to the tree, then make sure we can find them again. Also check that a pointer that we know isn't in the tree is not found. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/linux/kernel.h | 3 +++ tools/testing/radix-tree/main.c | 41 +++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) commit f518b1607e128a8dcfa75f539864c1321c5a18ea Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:36 2016 -0700 radix tree test suite: fix build Add an empty linux/init.h, and definitions for a few parts of the kernel API either in use now, or to be used in the near future. Start using the common definitions in tools/include/linux, although more work needs to be done here. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Jan Kara <jack@suse.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> tools/testing/radix-tree/linux/kernel.h | 12 ++++++++++-- tools/testing/radix-tree/linux/slab.h | 1 - tools/testing/radix-tree/linux/types.h | 7 ++----- 3 files changed, 12 insertions(+), 8 deletions(-) commit e9256efcc8e390fa4fcf796a0c0b47d642d77d32 Author: Matthew Wilcox <willy@linux.intel.com> Date: Fri May 20 17:01:33 2016 -0700 radix-tree: introduce radix_tree_empty Commit e61452365372 ("radix_tree: add support for multi-order entries") left the impression that the support for multiorder radix tree entries was functional. As soon as Ross tried to use it, it became apparent that my testing was completely inadequate, and it didn't even work a little bit for orders that were not a multiple of shift. This series of patches is the result of about 6 weeks of redesign, reimplementation, testing, arguing and hair-pulling. The great news is that the test-suite is now far better than it was. That's reflected in the diffstat for the test-suite alone: 12 files changed, 436 insertions(+), 28 deletions(-) The highlight for users of the tree is that the restriction on the order of inserted entries being >= RADIX_TREE_MAP_SHIFT is now gone; the radix tree now supports any order between 0 and 64. For those who are interested in how the tree works, patch 9 is probably the most interesting one as it introduces the new machinery for handling sibling entries. I've tried to be fair in attributing authorship to the person who contributed the majority of the code in each patch; Ross has been an invaluable partner in the development of this support and it's fair to say that each of us has code in every commit. I should also express my appreciation of the 0day testing. It prompted me that I was bloating the tinyconfig in an unacceptable way, and it bisected to a commit which contained a rather nasty memory-corruption bug. This patch (of 29): The irqdomain code was checking for 0 or 1 entries, not 0 entries like the comment said they were. Introduce a new helper that will actually check for an empty tree. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Jan Kara <jack@suse.cz> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kirill Shutemov <kirill.shutemov@linux.intel.com> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/radix-tree.h | 5 +++++ kernel/irq/irqdomain.c | 7 +------ 2 files changed, 6 insertions(+), 6 deletions(-) commit 538d7eb86d58b3d7d73f3bb3ff960c4bdf411c1a Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:30 2016 -0700 drivers/platform/x86/wmi.c: use generic UUID library Instead of opencoding let's use generic UUID library functions here. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/platform/x86/wmi.c | 104 ++++++--------------------------------------- 1 file changed, 13 insertions(+), 91 deletions(-) commit 7244ad69cc1382fd4dfb18a4fea5613acd67a2e9 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:27 2016 -0700 block/partitions/ldm.c: use generic UUID library Instead of opencoding let's use generic UUID library functions here. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: "Richard Russon (FlatCap)" <ldm@flatcap.org> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> block/partitions/ldm.c | 60 ++++---------------------------------------------- 1 file changed, 4 insertions(+), 56 deletions(-) commit 63579785752ba7d0e842078ec6b2875367046f06 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:24 2016 -0700 include/linux/genhd.h: move to use generic UUID library UUID library provides uuid_be type and uuid_be_to_bin() function. This substitutes open coded variant by generic library calls. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/genhd.h | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) commit 8236431d8d09eee70e6cbc506426a7c97778a2e6 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:21 2016 -0700 fs/efivarfs/inode.c: use generic UUID library Instead of opencoding let's use generic UUID library functions here. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/efivarfs/inode.c | 40 +++------------------------------------- 1 file changed, 3 insertions(+), 37 deletions(-) commit ba7e34b1bbd2722685bbc75d168672d5154d8614 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:18 2016 -0700 include/linux/efi.h: redefine type, constant, macro from generic code Generic UUID library defines structure type, macro to define UUID, and the length of the UUID string. This patch removes duplicate data structure definition, UUID string length constant as well as macro for UUID handling. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/efi.h | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) commit ede9c27749b9b35efdffa4f63a39f819d7913752 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:10 2016 -0700 kernel/sysctl_binary.c: use generic UUID library UUID library provides uuid_be type and uuid_be_to_bin() function. This substitutes open coded variant by generic library calls. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/sysctl_binary.c | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) commit e3a93bce69ad3e2c38927abe311b8cb4f17abbaf Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:07 2016 -0700 lib/uuid.c: remove FSF address There is no point in keeping an address in the file since it's subject to change. While here, update Intel Copyright years. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/uuid.h | 6 +----- include/uapi/linux/uuid.h | 4 ---- lib/uuid.c | 6 +----- 3 files changed, 2 insertions(+), 14 deletions(-) commit 2b1b0d66704a8cafe83be7114ec4c15ab3a314ad Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:04 2016 -0700 lib/uuid.c: introduce a few more generic helpers There are new helpers in this patch: uuid_is_valid checks if a UUID is valid uuid_be_to_bin converts from string to binary (big endian) uuid_le_to_bin converts from string to binary (little endian) They will be used in future, i.e. in the following patches in the series. This also moves the indices arrays to lib/uuid.c to be shared accross modules. [andriy.shevchenko@linux.intel.com: fix typo] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/uuid.h | 13 +++++++++++ lib/uuid.c | 65 ++++++++++++++++++++++++++++++++++++++++++++++++++++ lib/vsprintf.c | 9 ++++---- 3 files changed, 82 insertions(+), 5 deletions(-) commit 8da4b8c48e7b43cb16d05e1dbb34ad9f73ab7efd Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:01:00 2016 -0700 lib/uuid.c: move generate_random_uuid() to uuid.c Let's gather the UUID related functions under one hood. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/char/random.c | 21 +-------------------- fs/btrfs/volumes.c | 2 +- fs/ext4/ioctl.c | 2 +- fs/f2fs/file.c | 2 +- fs/reiserfs/objectid.c | 2 +- fs/ubifs/sb.c | 2 +- include/linux/random.h | 1 - include/linux/uuid.h | 2 ++ lib/uuid.c | 20 ++++++++++++++++++++ 9 files changed, 28 insertions(+), 26 deletions(-) commit b8b572789cde5118b2cee49d426d48fcf5b30e47 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:00:57 2016 -0700 security/integrity/ima/ima_policy.c: use %pU to output UUID in printable format Instead of open coded variant re-use extension that vsprintf.c provides us for ages. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> security/integrity/ima/ima_policy.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) commit aa4ea1c3b3948d325a6826adf9c367d11fa1ab74 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 20 17:00:54 2016 -0700 lib/vsprintf: simplify UUID printing There are few functions here and there along with type definitions that provide UUID API. This series consolidates everything under one hood and converts current users. This has been tested for a while internally, however it doesn't mean we covered all possible cases (especially accuracy of UUID constants after conversion). So, please test this as much as you can and provide your tag. We appreciate the effort. The ACPI conversion is postponed for now to sort more generic things out first. This patch (of 9): Since we have hex_byte_pack_upper() we may use it directly and avoid second loop. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Dmitry Kasatkin <dmitry.kasatkin@gmail.com> Cc: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/vsprintf.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit f4970682d73bba79cba10149d62482338d065086 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:51 2016 -0700 MAINTAINERS: remove Koichi Yasutake The MTA says: <yasutake.koichi@jp.panasonic.com>: unknown user: "yasutake.koichi@jp.panasonic.com" Link: http://lkml.kernel.org/r/1462776755-9607-1-git-send-email-jslaby@suse.cz Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: David Howells <dhowells@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 1 - 1 file changed, 1 deletion(-) commit 2e11246351012a0247307f8a0545e21dd841ba4f Author: Eric Engestrom <eric.engestrom@imgtec.com> Date: Fri May 20 17:00:49 2016 -0700 MAINTAINERS: remove defunct spear mailing list It looks like the email address for this mailing list doesn't exist anymore: <spear-devel@list.st.com>: host mxb-00178001.gslb.pphosted.com[91.207.212.93] said: 550 5.1.1 User Unknown (in reply to RCPT TO command) Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Kalle Valo <kvalo@codeaurora.org> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: Jiri Slaby <jslaby@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 4 ---- 1 file changed, 4 deletions(-) commit 6c41a3b7b2f8d10eefe5be9109fd4258dd6cf495 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:46 2016 -0700 MAINTAINERS: remove linux@lists.openrisc.net $ host -t mx lists.openrisc.net Host lists.openrisc.net not found: 3(NXDOMAIN) Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: Jonas Bonn <jonas@southpole.se> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 1 - 1 file changed, 1 deletion(-) commit cf9b1106c81c45cde02208fca49d3f3e4ab6ee74 Author: Petr Mladek <pmladek@suse.com> Date: Fri May 20 17:00:42 2016 -0700 printk/nmi: flush NMI messages on the system panic In NMI context, printk() messages are stored into per-CPU buffers to avoid a possible deadlock. They are normally flushed to the main ring buffer via an IRQ work. But the work is never called when the system calls panic() in the very same NMI handler. This patch tries to flush NMI buffers before the crash dump is generated. In this case it does not risk a double release and bails out when the logbuf_lock is already taken. The aim is to get the messages into the main ring buffer when possible. It makes them better accessible in the vmcore. Then the patch tries to flush the buffers second time when other CPUs are down. It might be more aggressive and reset logbuf_lock. The aim is to get the messages available for the consequent kmsg_dump() and console_flush_on_panic() calls. The patch causes vprintk_emit() to be called even in NMI context again. But it is done via printk_deferred() so that the console handling is skipped. Consoles use internal locks and we could not prevent a deadlock easily. They are explicitly called later when the crash dump is not generated, see console_flush_on_panic(). Signed-off-by: Petr Mladek <pmladek@suse.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Daniel Thompson <daniel.thompson@linaro.org> Cc: David Miller <davem@davemloft.net> Cc: Ingo Molnar <mingo@redhat.com> Cc: Jan Kara <jack@suse.cz> Cc: Jiri Kosina <jkosina@suse.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/printk.h | 2 ++ kernel/kexec_core.c | 1 + kernel/panic.c | 6 +++++- kernel/printk/internal.h | 2 ++ kernel/printk/nmi.c | 39 ++++++++++++++++++++++++++++++++++++++- kernel/printk/printk.c | 2 +- 6 files changed, 49 insertions(+), 3 deletions(-) commit 427934b8714ec130b068d1c9d88f25b24aaede32 Author: Petr Mladek <pmladek@suse.com> Date: Fri May 20 17:00:39 2016 -0700 printk/nmi: increase the size of NMI buffer and make it configurable Testing has shown that the backtrace sometimes does not fit into the 4kB temporary buffer that is used in NMI context. The warnings are gone when I double the temporary buffer size. This patch doubles the buffer size and makes it configurable. Note that this problem existed even in the x86-specific implementation that was added by the commit a9edc8809328 ("x86/nmi: Perform a safe NMI stack trace on all CPUs"). Nobody noticed it because it did not print any warnings. Signed-off-by: Petr Mladek <pmladek@suse.com> Cc: Jan Kara <jack@suse.cz> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Daniel Thompson <daniel.thompson@linaro.org> Cc: Jiri Kosina <jkosina@suse.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: David Miller <davem@davemloft.net> Cc: Daniel Thompson <daniel.thompson@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> init/Kconfig | 22 ++++++++++++++++++++++ kernel/printk/nmi.c | 3 ++- 2 files changed, 24 insertions(+), 1 deletion(-) commit b522deabc6f18e4f938d93a84f345f2cbf3347d1 Author: Petr Mladek <pmladek@suse.com> Date: Fri May 20 17:00:36 2016 -0700 printk/nmi: warn when some message has been lost in NMI context We could not resize the temporary buffer in NMI context. Let's warn if a message is lost. This is rather theoretical. printk() should not be used in NMI. The only sensible use is when we want to print backtrace from all CPUs. The current buffer should be enough for this purpose. [akpm@linux-foundation.org: whitespace fixlet] Signed-off-by: Petr Mladek <pmladek@suse.com> Cc: Jan Kara <jack@suse.cz> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Daniel Thompson <daniel.thompson@linaro.org> Cc: Jiri Kosina <jkosina@suse.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: David Miller <davem@davemloft.net> Cc: Daniel Thompson <daniel.thompson@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/printk/internal.h | 11 +++++++++++ kernel/printk/nmi.c | 5 ++++- kernel/printk/printk.c | 10 ++++++++++ 3 files changed, 25 insertions(+), 1 deletion(-) commit 42a0bb3f71383b457a7db362f1c69e7afb96732b Author: Petr Mladek <pmladek@suse.com> Date: Fri May 20 17:00:33 2016 -0700 printk/nmi: generic solution for safe printk in NMI printk() takes some locks and could not be used a safe way in NMI context. The chance of a deadlock is real especially when printing stacks from all CPUs. This particular problem has been addressed on x86 by the commit a9edc8809328 ("x86/nmi: Perform a safe NMI stack trace on all CPUs"). The patchset brings two big advantages. First, it makes the NMI backtraces safe on all architectures for free. Second, it makes all NMI messages almost safe on all architectures (the temporary buffer is limited. We still should keep the number of messages in NMI context at minimum). Note that there already are several messages printed in NMI context: WARN_ON(in_nmi()), BUG_ON(in_nmi()), anything being printed out from MCE handlers. These are not easy to avoid. This patch reuses most of the code and makes it generic. It is useful for all messages and architectures that support NMI. The alternative printk_func is set when entering and is reseted when leaving NMI context. It queues IRQ work to copy the messages into the main ring buffer in a safe context. __printk_nmi_flush() copies all available messages and reset the buffer. Then we could use a simple cmpxchg operations to get synchronized with writers. There is also used a spinlock to get synchronized with other flushers. We do not longer use seq_buf because it depends on external lock. It would be hard to make all supported operations safe for a lockless use. It would be confusing and error prone to make only some operations safe. The code is put into separate printk/nmi.c as suggested by Steven Rostedt. It needs a per-CPU buffer and is compiled only on architectures that call nmi_enter(). This is achieved by the new HAVE_NMI Kconfig flag. The are MN10300 and Xtensa architectures. We need to clean up NMI handling there first. Let's do it separately. The patch is heavily based on the draft from Peter Zijlstra, see https://lkml.org/lkml/2015/6/10/327 [arnd@arndb.de: printk-nmi: use %zu format string for size_t] [akpm@linux-foundation.org: min_t->min - all types are size_t here] Signed-off-by: Petr Mladek <pmladek@suse.com> Suggested-by: Peter Zijlstra <peterz@infradead.org> Suggested-by: Steven Rostedt <rostedt@goodmis.org> Cc: Jan Kara <jack@suse.cz> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> [arm part] Cc: Daniel Thompson <daniel.thompson@linaro.org> Cc: Jiri Kosina <jkosina@suse.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: David Miller <davem@davemloft.net> Cc: Daniel Thompson <daniel.thompson@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/Kconfig | 4 + arch/arm/Kconfig | 1 + arch/arm/kernel/smp.c | 2 + arch/avr32/Kconfig | 1 + arch/blackfin/Kconfig | 1 + arch/cris/Kconfig | 1 + arch/mips/Kconfig | 1 + arch/powerpc/Kconfig | 1 + arch/s390/Kconfig | 1 + arch/sh/Kconfig | 1 + arch/sparc/Kconfig | 1 + arch/tile/Kconfig | 1 + arch/x86/Kconfig | 1 + arch/x86/kernel/apic/hw_nmi.c | 1 - include/linux/hardirq.h | 2 + include/linux/percpu.h | 3 - include/linux/printk.h | 12 ++- init/Kconfig | 5 + init/main.c | 1 + kernel/printk/Makefile | 1 + kernel/printk/internal.h | 44 +++++++++ kernel/printk/nmi.c | 219 ++++++++++++++++++++++++++++++++++++++++++ kernel/printk/printk.c | 19 +--- lib/nmi_backtrace.c | 89 +---------------- 24 files changed, 306 insertions(+), 107 deletions(-) commit 2eeed7e98d6a1341b1574893a95ce5b8379140f2 Author: René Nyffenegger <mail@renenyffenegger.ch> Date: Fri May 20 17:00:30 2016 -0700 include/linux/syscalls.h: use pid_t instead of int In include/linux/syscalls.h, the four functions sys_kill, sys_tgkill, sys_tkill and sys_rt_sigqueueinfo are declared with "int pid" and "int tgid". However, in kernel/signal.c, the corresponding definitions use the more appropriate "pid_t" (which is a typedef'd int). This patch changes "int" to "pid_t" in the declarations of sys_kill, sys_tgkill, sys_tkill and sys_rt_sigqueueinfo in <linux/syscalls.h> in order to harmonize the function declarations with their respective definitions. Link: http://lkml.kernel.org/r/57302FDA.7020205@renenyffenegger.ch Signed-off-by: René Nyffenegger <mail@renenyffenegger.ch> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org> Cc: Zach Brown <zab@redhat.com> Cc: Milosz Tanski <milosz@adfin.com> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/syscalls.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 0740aa5f6375681c57488c4ea55d05a0341cfc9c Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:25 2016 -0700 fork: free thread in copy_process on failure When using this program (as root): #include <err.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <sys/io.h> #include <sys/types.h> #include <sys/wait.h> #define ITER 1000 #define FORKERS 15 #define THREADS (6000/FORKERS) // 1850 is proc max static void fork_100_wait() { unsigned a, to_wait = 0; printf("\t%d forking %d\n", THREADS, getpid()); for (a = 0; a < THREADS; a++) { switch (fork()) { case 0: usleep(1000); exit(0); break; case -1: break; default: to_wait++; break; } } printf("\t%d forked from %d, waiting for %d\n", THREADS, getpid(), to_wait); for (a = 0; a < to_wait; a++) wait(NULL); printf("\t%d waited from %d\n", THREADS, getpid()); } static void run_forkers() { pid_t forkers[FORKERS]; unsigned a; for (a = 0; a < FORKERS; a++) { switch ((forkers[a] = fork())) { case 0: fork_100_wait(); exit(0); break; case -1: err(1, "DIE fork of %d'th forker", a); break; default: break; } } for (a = 0; a < FORKERS; a++) waitpid(forkers[a], NULL, 0); } int main() { unsigned a; int ret; ret = ioperm(10, 20, 0); if (ret < 0) err(1, "ioperm"); for (a = 0; a < ITER; a++) run_forkers(); return 0; } kmemleak reports many occurences of this leak: unreferenced object 0xffff8805917c8000 (size 8192): comm "fork-leak", pid 2932, jiffies 4295354292 (age 1871.028s) hex dump (first 32 bytes): ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................ ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................ backtrace: [<ffffffff814cfbf5>] kmemdup+0x25/0x50 [<ffffffff8103ab43>] copy_thread_tls+0x6c3/0x9a0 [<ffffffff81150174>] copy_process+0x1a84/0x5790 [<ffffffff811dc375>] wake_up_new_task+0x2d5/0x6f0 [<ffffffff8115411d>] _do_fork+0x12d/0x820 ... Due to the leakage of the memory items which should have been freed in arch/x86/kernel/process.c:exit_thread(). Make sure the memory is freed when fork fails later in copy_process. This is done by calling exit_thread with the thread to kill. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: "David S. Miller" <davem@davemloft.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: "James E.J. Bottomley" <jejb@parisc-linux.org> Cc: Aurelien Jacquiot <a-jacquiot@ti.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Chen Liqin <liqin.linux@gmail.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Chris Zankel <chris@zankel.net> Cc: David Howells <dhowells@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn> Cc: Haavard Skinnemoen <hskinnemoen@gmail.com> Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Helge Deller <deller@gmx.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: James Hogan <james.hogan@imgtec.com> Cc: Jeff Dike <jdike@addtoit.com> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Jonas Bonn <jonas@southpole.se> Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com> Cc: Lennox Wu <lennox.wu@gmail.com> Cc: Ley Foon Tan <lftan@altera.com> Cc: Mark Salter <msalter@redhat.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Matt Turner <mattst88@gmail.com> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Michal Simek <monstr@monstr.eu> Cc: Mikael Starvik <starvik@axis.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Rich Felker <dalias@libc.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Richard Kuo <rkuo@codeaurora.org> Cc: Richard Weinberger <richard@nod.at> Cc: Russell King <linux@arm.linux.org.uk> Cc: Steven Miao <realmz6@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/fork.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e64646946ed32902fd597fa6e514b1da84642de3 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:20 2016 -0700 exit_thread: accept a task parameter to be exited We need to call exit_thread from copy_process in a fail path. So make it accept task_struct as a parameter. [v2] * s390: exit_thread_runtime_instr doesn't make sense to be called for non-current tasks. * arm: fix the comment in vfp_thread_copy * change 'me' to 'tsk' for task_struct * now we can change only archs that actually have exit_thread [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: "David S. Miller" <davem@davemloft.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: "James E.J. Bottomley" <jejb@parisc-linux.org> Cc: Aurelien Jacquiot <a-jacquiot@ti.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Chen Liqin <liqin.linux@gmail.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Chris Zankel <chris@zankel.net> Cc: David Howells <dhowells@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn> Cc: Haavard Skinnemoen <hskinnemoen@gmail.com> Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Helge Deller <deller@gmx.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: James Hogan <james.hogan@imgtec.com> Cc: Jeff Dike <jdike@addtoit.com> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Jonas Bonn <jonas@southpole.se> Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com> Cc: Lennox Wu <lennox.wu@gmail.com> Cc: Ley Foon Tan <lftan@altera.com> Cc: Mark Salter <msalter@redhat.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Matt Turner <mattst88@gmail.com> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Michal Simek <monstr@monstr.eu> Cc: Mikael Starvik <starvik@axis.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Rich Felker <dalias@libc.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Richard Kuo <rkuo@codeaurora.org> Cc: Richard Weinberger <richard@nod.at> Cc: Russell King <linux@arm.linux.org.uk> Cc: Steven Miao <realmz6@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/arm/kernel/process.c | 4 ++-- arch/arm/vfp/vfpmodule.c | 4 ---- arch/avr32/kernel/process.c | 4 ++-- arch/cris/arch-v32/kernel/process.c | 4 ++-- arch/ia64/kernel/perfmon.c | 4 ++-- arch/ia64/kernel/process.c | 14 +++++++------- arch/metag/kernel/process.c | 6 +++--- arch/mn10300/kernel/process.c | 4 ++-- arch/s390/kernel/process.c | 5 +++-- arch/sh/kernel/process_64.c | 5 ++--- arch/sparc/kernel/process_32.c | 12 ++++++------ arch/sparc/kernel/process_64.c | 4 ++-- arch/tile/kernel/process.c | 4 ++-- arch/x86/kernel/process.c | 5 ++--- arch/xtensa/kernel/process.c | 4 ++-- include/linux/sched.h | 4 ++-- kernel/exit.c | 2 +- 17 files changed, 42 insertions(+), 47 deletions(-) commit 5f56a5dfdb9bcb3bca03df59980d4d2f012cbb53 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:16 2016 -0700 exit_thread: remove empty bodies Define HAVE_EXIT_THREAD for archs which want to do something in exit_thread. For others, let's define exit_thread as an empty inline. This is a cleanup before we change the prototype of exit_thread to accept a task parameter. [akpm@linux-foundation.org: fix mips] Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: "David S. Miller" <davem@davemloft.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: "James E.J. Bottomley" <jejb@parisc-linux.org> Cc: Aurelien Jacquiot <a-jacquiot@ti.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Chen Liqin <liqin.linux@gmail.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Chris Zankel <chris@zankel.net> Cc: David Howells <dhowells@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn> Cc: Haavard Skinnemoen <hskinnemoen@gmail.com> Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Helge Deller <deller@gmx.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: James Hogan <james.hogan@imgtec.com> Cc: Jeff Dike <jdike@addtoit.com> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Jonas Bonn <jonas@southpole.se> Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com> Cc: Lennox Wu <lennox.wu@gmail.com> Cc: Ley Foon Tan <lftan@altera.com> Cc: Mark Salter <msalter@redhat.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Matt Turner <mattst88@gmail.com> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Michal Simek <monstr@monstr.eu> Cc: Mikael Starvik <starvik@axis.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Rich Felker <dalias@libc.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Richard Kuo <rkuo@codeaurora.org> Cc: Richard Weinberger <richard@nod.at> Cc: Russell King <linux@arm.linux.org.uk> Cc: Steven Miao <realmz6@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/Kconfig | 5 +++++ arch/alpha/kernel/process.c | 8 -------- arch/arc/kernel/process.c | 7 ------- arch/arm/Kconfig | 1 + arch/arm64/kernel/process.c | 7 ------- arch/avr32/Kconfig | 1 + arch/blackfin/include/asm/processor.h | 7 ------- arch/c6x/kernel/process.c | 4 ---- arch/cris/Kconfig | 1 + arch/cris/arch-v10/kernel/process.c | 9 --------- arch/frv/include/asm/processor.h | 7 ------- arch/h8300/include/asm/processor.h | 7 ------- arch/hexagon/kernel/process.c | 7 ------- arch/ia64/Kconfig | 1 + arch/m32r/kernel/process.c | 9 --------- arch/m68k/include/asm/processor.h | 7 ------- arch/metag/Kconfig | 1 + arch/metag/include/asm/processor.h | 2 -- arch/microblaze/include/asm/processor.h | 10 ---------- arch/mips/kernel/process.c | 4 ---- arch/mn10300/Kconfig | 1 + arch/nios2/include/asm/processor.h | 5 ----- arch/openrisc/include/asm/processor.h | 9 --------- arch/parisc/kernel/process.c | 7 ------- arch/powerpc/kernel/process.c | 4 ---- arch/s390/Kconfig | 1 + arch/score/kernel/process.c | 2 -- arch/sh/Kconfig | 1 + arch/sh/kernel/process_32.c | 7 ------- arch/sparc/Kconfig | 1 + arch/tile/Kconfig | 1 + arch/um/kernel/process.c | 4 ---- arch/unicore32/kernel/process.c | 7 ------- arch/x86/Kconfig | 1 + arch/xtensa/Kconfig | 1 + include/linux/sched.h | 7 +++++++ 36 files changed, 24 insertions(+), 140 deletions(-) commit 2ec656eb4054ce55e6d453b8614ef9669e84c542 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 20 17:00:11 2016 -0700 mn10300: let exit_fpu accept a task We need to call exit_thread from copy_process in a fail path. Since exit_thread on mn10300 calls exit_thread_runtime_instr, make it accept task_struct as a parameter now. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: "David S. Miller" <davem@davemloft.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: "James E.J. Bottomley" <jejb@parisc-linux.org> Cc: Aurelien Jacquiot <a-jacquiot@ti.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Chen Liqin <liqin.linux@gmail.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Chris Zankel <chris@zankel.net> Cc: David Howells <dhowells@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn> Cc: Haavard Skinnemoen <hskinnemoen@gmail.com> Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Helge Deller <deller@gmx.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: James Hogan <james.hogan@imgtec.com> Cc: Jeff Dike <jdike@addtoit.com> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Jonas Bonn <jonas@southpole.se> Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com> Cc: Lennox Wu <lennox.wu@gmail.com> Cc: Ley Foon Tan <lftan@altera.com> Cc: Mark Salter <msalter@redhat.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Matt Turner <mattst88@gmail.com> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Michal Simek <monstr@monstr.eu> Cc: Mikael Starvik <starvik@axis.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Rich Felker <dalias@libc.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Richard Kuo <rkuo@codeaurora.org> Cc: Richard Weinberger <richard@nod.at> Cc: Russell King <linux@arm.linux.org.uk> Cc: Steven Miao <realmz6@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/mn10300/include/asm/fpu.h | 6 ++---- arch/mn10300/kernel/process.c | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) commit 1b3044e39a89cb1d4d5313da477e8dfea2b5232d Author: Janis Danisevskis <jdanis@google.com> Date: Fri May 20 17:00:08 2016 -0700 procfs: fix pthread cross-thread naming if !PR_DUMPABLE The PR_DUMPABLE flag causes the pid related paths of the proc file system to be owned by ROOT. The implementation of pthread_set/getname_np however needs access to /proc/<pid>/task/<tid>/comm. If PR_DUMPABLE is false this implementation is locked out. This patch installs a special permission function for the file "comm" that grants read and write access to all threads of the same group regardless of the ownership of the inode. For all other threads the function falls back to the generic inode permission check. [akpm@linux-foundation.org: fix spello in comment] Signed-off-by: Janis Danisevskis <jdanis@google.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Cyrill Gorcunov <gorcunov@openvz.org> Cc: Alexey Dobriyan <adobriyan@gmail.com> Cc: Colin Ian King <colin.king@canonical.com> Cc: David Rientjes <rientjes@google.com> Cc: Minfei Huang <mnfhuang@gmail.com> Cc: John Stultz <john.stultz@linaro.org> Cc: Calvin Owens <calvinowens@fb.com> Cc: Jann Horn <jann@thejh.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/proc/base.c | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) commit 3e42979e65dace1f9268dd5440e5ab096b8dee59 Author: Richard W.M. Jones <rjones@redhat.com> Date: Fri May 20 17:00:05 2016 -0700 procfs: expose umask in /proc/<PID>/status It's not possible to read the process umask without also modifying it, which is what umask(2) does. A library cannot read umask safely, especially if the main program might be multithreaded. Add a new status line ("Umask") in /proc/<PID>/status. It contains the file mode creation mask (umask) in octal. It is only shown for tasks which have task->fs. This patch is adapted from one originally written by Pierre Carrier. The use case is that we have endless trouble with people setting weird umask() values (usually on the grounds of "security"), and then everything breaking. I'm on the hook to fix these. We'd like to add debugging to our program so we can dump out the umask in debug reports. Previous versions of the patch used a syscall so you could only read your own umask. That's all I need. However there was quite a lot of push-back from those, so this new version exports it in /proc. See: https://lkml.org/lkml/2016/4/13/704 [umask2] https://lkml.org/lkml/2016/4/13/487 [getumask] Signed-off-by: Richard W.M. Jones <rjones@redhat.com> Acked-by: Konstantin Khlebnikov <koct9i@gmail.com> Acked-by: Jerome Marchand <jmarchan@redhat.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Michal Hocko <mhocko@kernel.org> Cc: Pierre Carrier <pierre@spotify.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/filesystems/proc.txt | 1 + fs/proc/array.c | 20 +++++++++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) commit 623e47fc64f8de480b322b7ed68855f97137e2a5 Author: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Date: Fri May 20 17:00:02 2016 -0700 zram: introduce per-device debug_stat sysfs node debug_stat sysfs is read-only and represents various debugging data that zram developers may need. This file is not meant to be used by anyone else: its content is not documented and will change any time w/o any notice. Therefore, the output of debug_stat file contains a version string. To avoid any confusion, we will increase the version number every time we modify the output. At the moment this file exports only one value -- the number of re-compressions, IOW, the number of times compression fast path has failed. This stat is temporary any will be useful in case if any per-cpu compression streams regressions will be reported. Link: http://lkml.kernel.org/r/20160513230834.GB26763@bbox Link: http://lkml.kernel.org/r/20160511134553.12655-1-sergey.senozhatsky@gmail.com Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/ABI/testing/sysfs-block-zram | 9 +++++++++ Documentation/blockdev/zram.txt | 1 + drivers/block/zram/zram_drv.c | 21 +++++++++++++++++++++ drivers/block/zram/zram_drv.h | 1 + 4 files changed, 32 insertions(+) commit 43209ea2d17aae1540d4e28274e36404f72702f2 Author: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Date: Fri May 20 16:59:59 2016 -0700 zram: remove max_comp_streams internals Remove the internal part of max_comp_streams interface, since we switched to per-cpu streams. We will keep RW max_comp_streams attr around, because: a) we may (silently) switch back to idle compression streams list and don't want to disturb user space b) max_comp_streams attr must wait for the next 'lay off cycle'; we give user space 2 years to adjust before we remove/downgrade the attr, and there are already several attrs scheduled for removal in 4.11, so it's too late for max_comp_streams. This slightly change a user visible behaviour: - First, reading from max_comp_stream file now will always return the number of online CPUs. - Second, writing to max_comp_stream will not take any effect. Link: http://lkml.kernel.org/r/20160503165546.25201-1-sergey.senozhatsky@gmail.com Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Cc: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/blockdev/zram.txt | 27 ++++++++----------------- drivers/block/zram/zcomp.c | 5 ----- drivers/block/zram/zram_drv.c | 45 ++++++++++------------------------------- drivers/block/zram/zram_drv.h | 1 - 4 files changed, 19 insertions(+), 59 deletions(-) commit d34f615720d17c49b6779f6fcd5cb7eb82231a38 Author: Dan Streetman <ddstreet@ieee.org> Date: Fri May 20 16:59:56 2016 -0700 mm/zsmalloc: don't fail if can't create debugfs info Change the return type of zs_pool_stat_create() to void, and remove the logic to abort pool creation if the stat debugfs dir/file could not be created. The debugfs stat file is for debugging/information only, and doesn't affect operation of zsmalloc; there is no reason to abort creating the pool if the stat file can't be created. This was seen with zswap, which used the same name for all pool creations, which caused zsmalloc to fail to create a second pool for zswap if CONFIG_ZSMALLOC_STAT was enabled. Signed-off-by: Dan Streetman <ddstreet@ieee.org> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Cc: Dan Streetman <dan.streetman@canonical.com> Cc: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) commit 200867af4dedfe7cb707f96773684de1d1fd21e6 Author: Dan Streetman <ddstreet@ieee.org> Date: Fri May 20 16:59:54 2016 -0700 mm/zswap: use workqueue to destroy pool Add a work_struct to struct zswap_pool, and change __zswap_pool_empty to use the workqueue instead of using call_rcu(). When zswap destroys a pool no longer in use, it uses call_rcu() to perform the destruction/freeing. Since that executes in softirq context, it must not sleep. However, actually destroying the pool involves freeing the per-cpu compressors (which requires locking the cpu_add_remove_lock mutex) and freeing the zpool, for which the implementation may sleep (e.g. zsmalloc calls kmem_cache_destroy, which locks the slab_mutex). So if either mutex is currently taken, or any other part of the compressor or zpool implementation sleeps, it will result in a BUG(). It's not easy to reproduce this when changing zswap's params normally. In testing with a loaded system, this does not fail: $ cd /sys/module/zswap/parameters $ echo lz4 > compressor ; echo zsmalloc > zpool nor does this: $ while true ; do > echo lzo > compressor ; echo zbud > zpool > sleep 1 > echo lz4 > compressor ; echo zsmalloc > zpool > sleep 1 > done although it's still possible either of those might fail, depending on whether anything else besides zswap has locked the mutexes. However, changing a parameter with no delay immediately causes the schedule while atomic BUG: $ while true ; do > echo lzo > compressor ; echo lz4 > compressor > done This is essentially the same as Yu Zhao's proposed patch to zsmalloc, but moved to zswap, to cover compressor and zpool freeing. Fixes: f1c54846ee45 ("zswap: dynamic pool creation") Signed-off-by: Dan Streetman <ddstreet@ieee.org> Reported-by: Yu Zhao <yuzhao@google.com> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Cc: Minchan Kim <minchan@kernel.org> Cc: Dan Streetman <dan.streetman@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zswap.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit da9556a2367cf2261ab4d3e100693c82fb1ddb26 Author: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Date: Fri May 20 16:59:51 2016 -0700 zram: user per-cpu compression streams Remove idle streams list and keep compression streams in per-cpu data. This removes two contented spin_lock()/spin_unlock() calls from write path and also prevent write OP from being preempted while holding the compression stream, which can cause slow downs. For instance, let's assume that we have N cpus and N-2 max_comp_streams.TASK1 owns the last idle stream, TASK2-TASK3 come in with the write requests: TASK1 TASK2 TASK3 zram_bvec_write() spin_lock find stream spin_unlock compress <<preempted>> zram_bvec_write() spin_lock find stream spin_unlock no_stream schedule zram_bvec_write() spin_lock find_stream spin_unlock no_stream schedule spin_lock release stream spin_unlock wake up TASK2 not only TASK2 and TASK3 will not get the stream, TASK1 will be preempted in the middle of its operation; while we would prefer it to finish compression and release the stream. Test environment: x86_64, 4 CPU box, 3G zram, lzo The following fio tests were executed: read, randread, write, randwrite, rw, randrw with the increasing number of jobs from 1 to 10. 4 streams 8 streams per-cpu =========================================================== jobs1 READ: 2520.1MB/s 2566.5MB/s 2491.5MB/s READ: 2102.7MB/s 2104.2MB/s 2091.3MB/s WRITE: 1355.1MB/s 1320.2MB/s 1378.9MB/s WRITE: 1103.5MB/s 1097.2MB/s 1122.5MB/s READ: 434013KB/s 435153KB/s 439961KB/s WRITE: 433969KB/s 435109KB/s 439917KB/s READ: 403166KB/s 405139KB/s 403373KB/s WRITE: 403223KB/s 405197KB/s 403430KB/s jobs2 READ: 7958.6MB/s 8105.6MB/s 8073.7MB/s READ: 6864.9MB/s 6989.8MB/s 7021.8MB/s WRITE: 2438.1MB/s 2346.9MB/s 3400.2MB/s WRITE: 1994.2MB/s 1990.3MB/s 2941.2MB/s READ: 981504KB/s 973906KB/s 1018.8MB/s WRITE: 981659KB/s 974060KB/s 1018.1MB/s READ: 937021KB/s 938976KB/s 987250KB/s WRITE: 934878KB/s 936830KB/s 984993KB/s jobs3 READ: 13280MB/s 13553MB/s 13553MB/s READ: 11534MB/s 11785MB/s 11755MB/s WRITE: 3456.9MB/s 3469.9MB/s 4810.3MB/s WRITE: 3029.6MB/s 3031.6MB/s 4264.8MB/s READ: 1363.8MB/s 1362.6MB/s 1448.9MB/s WRITE: 1361.9MB/s 1360.7MB/s 1446.9MB/s READ: 1309.4MB/s 1310.6MB/s 1397.5MB/s WRITE: 1307.4MB/s 1308.5MB/s 1395.3MB/s jobs4 READ: 20244MB/s 20177MB/s 20344MB/s READ: 17886MB/s 17913MB/s 17835MB/s WRITE: 4071.6MB/s 4046.1MB/s 6370.2MB/s WRITE: 3608.9MB/s 3576.3MB/s 5785.4MB/s READ: 1824.3MB/s 1821.6MB/s 1997.5MB/s WRITE: 1819.8MB/s 1817.4MB/s 1992.5MB/s READ: 1765.7MB/s 1768.3MB/s 1937.3MB/s WRITE: 1767.5MB/s 1769.1MB/s 1939.2MB/s jobs5 READ: 18663MB/s 18986MB/s 18823MB/s READ: 16659MB/s 16605MB/s 16954MB/s WRITE: 3912.4MB/s 3888.7MB/s 6126.9MB/s WRITE: 3506.4MB/s 3442.5MB/s 5519.3MB/s READ: 1798.2MB/s 1746.5MB/s 1935.8MB/s WRITE: 1792.7MB/s 1740.7MB/s 1929.1MB/s READ: 1727.6MB/s 1658.2MB/s 1917.3MB/s WRITE: 1726.5MB/s 1657.2MB/s 1916.6MB/s jobs6 READ: 21017MB/s 20922MB/s 21162MB/s READ: 19022MB/s 19140MB/s 18770MB/s WRITE: 3968.2MB/s 4037.7MB/s 6620.8MB/s WRITE: 3643.5MB/s 3590.2MB/s 6027.5MB/s READ: 1871.8MB/s 1880.5MB/s 2049.9MB/s WRITE: 1867.8MB/s 1877.2MB/s 2046.2MB/s READ: 1755.8MB/s 1710.3MB/s 1964.7MB/s WRITE: 1750.5MB/s 1705.9MB/s 1958.8MB/s jobs7 READ: 21103MB/s 20677MB/s 21482MB/s READ: 18522MB/s 18379MB/s 19443MB/s WRITE: 4022.5MB/s 4067.4MB/s 6755.9MB/s WRITE: 3691.7MB/s 3695.5MB/s 5925.6MB/s READ: 1841.5MB/s 1933.9MB/s 2090.5MB/s WRITE: 1842.7MB/s 1935.3MB/s 2091.9MB/s READ: 1832.4MB/s 1856.4MB/s 1971.5MB/s WRITE: 1822.3MB/s 1846.2MB/s 1960.6MB/s jobs8 READ: 20463MB/s 20194MB/s 20862MB/s READ: 18178MB/s 17978MB/s 18299MB/s WRITE: 4085.9MB/s 4060.2MB/s 7023.8MB/s WRITE: 3776.3MB/s 3737.9MB/s 6278.2MB/s READ: 1957.6MB/s 1944.4MB/s 2109.5MB/s WRITE: 1959.2MB/s 1946.2MB/s 2111.4MB/s READ: 1900.6MB/s 1885.7MB/s 2082.1MB/s WRITE: 1896.2MB/s 1881.4MB/s 2078.3MB/s jobs9 READ: 19692MB/s 19734MB/s 19334MB/s READ: 17678MB/s 18249MB/s 17666MB/s WRITE: 4004.7MB/s 4064.8MB/s 6990.7MB/s WRITE: 3724.7MB/s 3772.1MB/s 6193.6MB/s READ: 1953.7MB/s 1967.3MB/s 2105.6MB/s WRITE: 1953.4MB/s 1966.7MB/s 2104.1MB/s READ: 1860.4MB/s 1897.4MB/s 2068.5MB/s WRITE: 1858.9MB/s 1895.9MB/s 2066.8MB/s jobs10 READ: 19730MB/s 19579MB/s 19492MB/s READ: 18028MB/s 18018MB/s 18221MB/s WRITE: 4027.3MB/s 4090.6MB/s 7020.1MB/s WRITE: 3810.5MB/s 3846.8MB/s 6426.8MB/s READ: 1956.1MB/s 1994.6MB/s 2145.2MB/s WRITE: 1955.9MB/s 1993.5MB/s 2144.8MB/s READ: 1852.8MB/s 1911.6MB/s 2075.8MB/s WRITE: 1855.7MB/s 1914.6MB/s 2078.1MB/s perf stat 4 streams 8 streams per-cpu ==================================================================================================================== jobs1 stalled-cycles-frontend 23,174,811,209 ( 38.21%) 23,220,254,188 ( 38.25%) 23,061,406,918 ( 38.34%) stalled-cycles-backend 11,514,174,638 ( 18.98%) 11,696,722,657 ( 19.27%) 11,370,852,810 ( 18.90%) instructions 73,925,005,782 ( 1.22) 73,903,177,632 ( 1.22) 73,507,201,037 ( 1.22) branches 14,455,124,835 ( 756.063) 14,455,184,779 ( 755.281) 14,378,599,509 ( 758.546) branch-misses 69,801,336 ( 0.48%) 80,225,529 ( 0.55%) 72,044,726 ( 0.50%) jobs2 stalled-cycles-frontend 49,912,741,782 ( 46.11%) 50,101,189,290 ( 45.95%) 32,874,195,633 ( 35.11%) stalled-cycles-backend 27,080,366,230 ( 25.02%) 27,949,970,232 ( 25.63%) 16,461,222,706 ( 17.58%) instructions 122,831,629,690 ( 1.13) 122,919,846,419 ( 1.13) 121,924,786,775 ( 1.30) branches 23,725,889,239 ( 692.663) 23,733,547,140 ( 688.062) 23,553,950,311 ( 794.794) branch-misses 90,733,041 ( 0.38%) 96,320,895 ( 0.41%) 84,561,092 ( 0.36%) jobs3 stalled-cycles-frontend 66,437,834,608 ( 45.58%) 63,534,923,344 ( 43.69%) 42,101,478,505 ( 33.19%) stalled-cycles-backend 34,940,799,661 ( 23.97%) 34,774,043,148 ( 23.91%) 21,163,324,388 ( 16.68%) instructions 171,692,121,862 ( 1.18) 171,775,373,044 ( 1.18) 170,353,542,261 ( 1.34) branches 32,968,962,622 ( 628.723) 32,987,739,894 ( 630.512) 32,729,463,918 ( 717.027) branch-misses 111,522,732 ( 0.34%) 110,472,894 ( 0.33%) 99,791,291 ( 0.30%) jobs4 stalled-cycles-frontend 98,741,701,675 ( 49.72%) 94,797,349,965 ( 47.59%) 54,535,655,381 ( 33.53%) stalled-cycles-backend 54,642,609,615 ( 27.51%) 55,233,554,408 ( 27.73%) 27,882,323,541 ( 17.14%) instructions 220,884,807,851 ( 1.11) 220,930,887,273 ( 1.11) 218,926,845,851 ( 1.35) branches 42,354,518,180 ( 592.105) 42,362,770,587 ( 590.452) 41,955,552,870 ( 716.154) branch-misses 138,093,449 ( 0.33%) 131,295,286 ( 0.31%) 121,794,771 ( 0.29%) jobs5 stalled-cycles-frontend 116,219,747,212 ( 48.14%) 110,310,397,012 ( 46.29%) 66,373,082,723 ( 33.70%) stalled-cycles-backend 66,325,434,776 ( 27.48%) 64,157,087,914 ( 26.92%) 32,999,097,299 ( 16.76%) instructions 270,615,008,466 ( 1.12) 270,546,409,525 ( 1.14) 268,439,910,948 ( 1.36) branches 51,834,046,557 ( 599.108) 51,811,867,722 ( 608.883) 51,412,576,077 ( 729.213) branch-misses 158,197,086 ( 0.31%) 142,639,805 ( 0.28%) 133,425,455 ( 0.26%) jobs6 stalled-cycles-frontend 138,009,414,492 ( 48.23%) 139,063,571,254 ( 48.80%) 75,278,568,278 ( 32.80%) stalled-cycles-backend 79,211,949,650 ( 27.68%) 79,077,241,028 ( 27.75%) 37,735,797,899 ( 16.44%) instructions 319,763,993,731 ( 1.12) 319,937,782,834 ( 1.12) 316,663,600,784 ( 1.38) branches 61,219,433,294 ( 595.056) 61,250,355,540 ( 598.215) 60,523,446,617 ( 733.706) branch-misses 169,257,123 ( 0.28%) 154,898,028 ( 0.25%) 141,180,587 ( 0.23%) jobs7 stalled-cycles-frontend 162,974,812,119 ( 49.20%) 159,290,061,987 ( 48.43%) 88,046,641,169 ( 33.21%) stalled-cycles-backend 92,223,151,661 ( 27.84%) 91,667,904,406 ( 27.87%) 44,068,454,971 ( 16.62%) instructions 369,516,432,430 ( 1.12) 369,361,799,063 ( 1.12) 365,290,380,661 ( 1.38) branches 70,795,673,950 ( 594.220) 70,743,136,124 ( 597.876) 69,803,996,038 ( 732.822) branch-misses 181,708,327 ( 0.26%) 165,767,821 ( 0.23%) 150,109,797 ( 0.22%) jobs8 stalled-cycles-frontend 185,000,017,027 ( 49.30%) 182,334,345,473 ( 48.37%) 99,980,147,041 ( 33.26%) stalled-cycles-backend 105,753,516,186 ( 28.18%) 107,937,830,322 ( 28.63%) 51,404,177,181 ( 17.10%) instructions 418,153,161,055 ( 1.11) 418,308,565,828 ( 1.11) 413,653,475,581 ( 1.38) branches 80,035,882,398 ( 592.296) 80,063,204,510 ( 589.843) 79,024,105,589 ( 730.530) branch-misses 199,764,528 ( 0.25%) 177,936,926 ( 0.22%) 160,525,449 ( 0.20%) jobs9 stalled-cycles-frontend 210,941,799,094 ( 49.63%) 204,714,679,254 ( 48.55%) 114,251,113,756 ( 33.96%) stalled-cycles-backend 122,640,849,067 ( 28.85%) 122,188,553,256 ( 28.98%) 58,360,041,127 ( 17.35%) instructions 468,151,025,415 ( 1.10) 467,354,869,323 ( 1.11) 462,665,165,216 ( 1.38) branches 89,657,067,510 ( 585.628) 89,411,550,407 ( 588.990) 88,360,523,943 ( 730.151) branch-misses 218,292,301 ( 0.24%) 191,701,247 ( 0.21%) 178,535,678 ( 0.20%) jobs10 stalled-cycles-frontend 233,595,958,008 ( 49.81%) 227,540,615,689 ( 49.11%) 160,341,979,938 ( 43.07%) stalled-cycles-backend 136,153,676,021 ( 29.03%) 133,635,240,742 ( 28.84%) 65,909,135,465 ( 17.70%) instructions 517,001,168,497 ( 1.10) 516,210,976,158 ( 1.11) 511,374,038,613 ( 1.37) branches 98,911,641,329 ( 585.796) 98,700,069,712 ( 591.583) 97,646,761,028 ( 728.712) branch-misses 232,341,823 ( 0.23%) 199,256,308 ( 0.20%) 183,135,268 ( 0.19%) per-cpu streams tend to cause significantly less stalled cycles; execute less branches and hit less branch-misses. perf stat reported execution time 4 streams 8 streams per-cpu ==================================================================== jobs1 seconds elapsed 20.909073870 20.875670495 20.817838540 jobs2 seconds elapsed 18.529488399 18.720566469 16.356103108 jobs3 seconds elapsed 18.991159531 18.991340812 16.766216066 jobs4 seconds elapsed 19.560643828 19.551323547 16.246621715 jobs5 seconds elapsed 24.746498464 25.221646740 20.696112444 jobs6 seconds elapsed 28.258181828 28.289765505 22.885688857 jobs7 seconds elapsed 32.632490241 31.909125381 26.272753738 jobs8 seconds elapsed 35.651403851 36.027596308 29.108024711 jobs9 seconds elapsed 40.569362365 40.024227989 32.898204012 jobs10 seconds elapsed 44.673112304 43.874898137 35.632952191 Please see Link: http://marc.info/?l=linux-kernel&m=146166970727530 Link: http://marc.info/?l=linux-kernel&m=146174716719650 for more test results (under low memory conditions). Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Suggested-by: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/block/zram/zcomp.c | 297 ++++++++++++------------------------------ drivers/block/zram/zcomp.h | 14 +- drivers/block/zram/zram_drv.c | 36 ++++- 3 files changed, 116 insertions(+), 231 deletions(-) commit d0d8da2dc49dfdfe1d788eaf4d55eb5d4964d926 Author: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Date: Fri May 20 16:59:48 2016 -0700 zsmalloc: require GFP in zs_malloc() Pass GFP flags to zs_malloc() instead of using a fixed mask supplied to zs_create_pool(), so we can be more flexible, but, more importantly, we need this to switch zram to per-cpu compression streams -- zram will try to allocate handle with preemption disabled in a fast path and switch to a slow path (using different gfp mask) if the fast one has failed. Apart from that, this also align zs_malloc() interface with zspool/zbud. [sergey.senozhatsky@gmail.com: pass GFP flags to zs_malloc() instead of using a fixed mask] Link: http://lkml.kernel.org/r/20160429150942.GA637@swordfish Link: http://lkml.kernel.org/r/20160429150942.GA637@swordfish Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Acked-by: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/block/zram/zram_drv.c | 4 ++-- include/linux/zsmalloc.h | 4 ++-- mm/zsmalloc.c | 24 +++++++++++++----------- 3 files changed, 17 insertions(+), 15 deletions(-) commit 1ee4716585ed80b7917ba3c5aa38e5e0d677d583 Author: Minchan Kim <minchan@kernel.org> Date: Fri May 20 16:59:45 2016 -0700 zsmalloc: remove unused pool param in obj_free Let's remove unused pool param in obj_free Signed-off-by: Minchan Kim <minchan@kernel.org> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 251cbb951b831acd8451d75b40696834f07c29c5 Author: Minchan Kim <minchan@kernel.org> Date: Fri May 20 16:59:42 2016 -0700 zsmalloc: reorder function parameters Clean up function parameter ordering to order higher data structure first. Signed-off-by: Minchan Kim <minchan@kernel.org> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 50 ++++++++++++++++++++++++++------------------------ 1 file changed, 26 insertions(+), 24 deletions(-) commit 830e4bc5baa9fda5d45257e9a3dbb3555c6c180e Author: Minchan Kim <minchan@kernel.org> Date: Fri May 20 16:59:39 2016 -0700 zsmalloc: clean up many BUG_ON There are many BUG_ON in zsmalloc.c which is not recommened so change them as alternatives. Normal rule is as follows: 1. avoid BUG_ON if possible. Instead, use VM_BUG_ON or VM_BUG_ON_PAGE 2. use VM_BUG_ON_PAGE if we need to see struct page's fields 3. use those assertion in primitive functions so higher functions can rely on the assertion in the primitive function. 4. Don't use assertion if following instruction can trigger Oops Signed-off-by: Minchan Kim <minchan@kernel.org> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 42 +++++++++++++++--------------------------- 1 file changed, 15 insertions(+), 27 deletions(-) commit a42094676f076534bf4998625456fe0bb99c1f1e Author: Minchan Kim <minchan@kernel.org> Date: Fri May 20 16:59:36 2016 -0700 zsmalloc: use first_page rather than page Clean up function parameter "struct page". Many functions of zsmalloc expect that page paramter is "first_page" so use "first_page" rather than "page" for code readability. Signed-off-by: Minchan Kim <minchan@kernel.org> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/zsmalloc.c | 62 ++++++++++++++++++++++++++++++----------------------------- 1 file changed, 32 insertions(+), 30 deletions(-) commit eae08dcab80c695c16c9f1f7dcd5b8ed52bfc88b Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Fri May 20 16:59:34 2016 -0700 kasan/tests: add tests for user memory access functions Add some tests for the newly-added user memory access API. Link: http://lkml.kernel.org/r/1462538722-1574-1-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/test_kasan.c | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) commit 1771c6e1a567ea0ba2cccc0a4ffe68a1419fd8ef Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Fri May 20 16:59:31 2016 -0700 x86/kasan: instrument user memory access API Exchange between user and kernel memory is coded in assembly language. Which means that such accesses won't be spotted by KASAN as a compiler instruments only C code. Add explicit KASAN checks to user memory access API to ensure that userspace writes to (or reads from) a valid kernel memory. Note: Unlike others strncpy_from_user() is written mostly in C and KASAN sees memory accesses in it. However, it makes sense to add explicit check for all @count bytes that *potentially* could be written to the kernel. [aryabinin@virtuozzo.com: move kasan check under the condition] Link: http://lkml.kernel.org/r/1462869209-21096-1-git-send-email-aryabinin@virtuozzo.com Link: http://lkml.kernel.org/r/1462538722-1574-4-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/include/asm/uaccess.h | 5 +++++ arch/x86/include/asm/uaccess_64.h | 7 +++++++ lib/strncpy_from_user.c | 2 ++ 3 files changed, 14 insertions(+) commit 64f8ebaf115bcddc4aaa902f981c57ba6506bc42 Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Fri May 20 16:59:28 2016 -0700 mm/kasan: add API to check memory regions Memory access coded in an assembly won't be seen by KASAN as a compiler can instrument only C code. Add kasan_check_[read,write]() API which is going to be used to check a certain memory range. Link: http://lkml.kernel.org/r/1462538722-1574-3-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Acked-by: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> MAINTAINERS | 2 +- include/linux/kasan-checks.h | 12 ++++++++++++ mm/kasan/kasan.c | 12 ++++++++++++ 3 files changed, 25 insertions(+), 1 deletion(-) commit 936bb4bbbb832f81055328b84e5afe1fc7246a8d Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Fri May 20 16:59:20 2016 -0700 mm/kasan: print name of mem[set,cpy,move]() caller in report When bogus memory access happens in mem[set,cpy,move]() it's usually caller's fault. So don't blame mem[set,cpy,move]() in bug report, blame the caller instead. Before: BUG: KASAN: out-of-bounds access in memset+0x23/0x40 at <address> After: BUG: KASAN: out-of-bounds access in <memset_caller> at <address> Link: http://lkml.kernel.org/r/1462538722-1574-2-git-send-email-aryabinin@virtuozzo.com Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Acked-by: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/kasan/kasan.c | 64 ++++++++++++++++++++++++++++++-------------------------- 1 file changed, 34 insertions(+), 30 deletions(-) commit 96fe805fb6fe9b2ed12fc54ad0e3e6829a4152cb Author: Alexander Potapenko <glider@google.com> Date: Fri May 20 16:59:17 2016 -0700 mm, kasan: add a ksize() test Add a test that makes sure ksize() unpoisons the whole chunk. Signed-off-by: Alexander Potapenko <glider@google.com> Acked-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andrey Konovalov <adech.fo@gmail.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Christoph Lameter <cl@linux.com> Cc: Konstantin Serebryany <kcc@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/test_kasan.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 4ebb31a42ffa03912447fe1aabbdb28242f909ba Author: Alexander Potapenko <glider@google.com> Date: Fri May 20 16:59:14 2016 -0700 mm, kasan: don't call kasan_krealloc() from ksize(). Instead of calling kasan_krealloc(), which replaces the memory allocation stack ID (if stack depot is used), just unpoison the whole memory chunk. Signed-off-by: Alexander Potapenko <glider@google.com> Acked-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andrey Konovalov <adech.fo@gmail.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Christoph Lameter <cl@linux.com> Cc: Konstantin Serebryany <kcc@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 2 +- mm/slub.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) commit 55834c59098d0c5a97b0f3247e55832b67facdcf Author: Alexander Potapenko <glider@google.com> Date: Fri May 20 16:59:11 2016 -0700 mm: kasan: initial memory quarantine implementation Quarantine isolates freed objects in a separate queue. The objects are returned to the allocator later, which helps to detect use-after-free errors. When the object is freed, its state changes from KASAN_STATE_ALLOC to KASAN_STATE_QUARANTINE. The object is poisoned and put into quarantine instead of being returned to the allocator, therefore every subsequent access to that object triggers a KASAN error, and the error handler is able to say where the object has been allocated and deallocated. When it's time for the object to leave quarantine, its state becomes KASAN_STATE_FREE and it's returned to the allocator. From now on the allocator may reuse it for another allocation. Before that happens, it's still possible to detect a use-after free on that object (it retains the allocation/deallocation stacks). When the allocator reuses this object, the shadow is unpoisoned and old allocation/deallocation stacks are wiped. Therefore a use of this object, even an incorrect one, won't trigger ASan warning. Without the quarantine, it's not guaranteed that the objects aren't reused immediately, that's why the probability of catching a use-after-free is lower than with quarantine in place. Quarantine isolates freed objects in a separate queue. The objects are returned to the allocator later, which helps to detect use-after-free errors. Freed objects are first added to per-cpu quarantine queues. When a cache is destroyed or memory shrinking is requested, the objects are moved into the global quarantine queue. Whenever a kmalloc call allows memory reclaiming, the oldest objects are popped out of the global queue until the total size of objects in quarantine is less than 3/4 of the maximum quarantine size (which is a fraction of installed physical memory). As long as an object remains in the quarantine, KASAN is able to report accesses to it, so the chance of reporting a use-after-free is increased. Once the object leaves quarantine, the allocator may reuse it, in which case the object is unpoisoned and KASAN can't detect incorrect accesses to it. Right now quarantine support is only enabled in SLAB allocator. Unification of KASAN features in SLAB and SLUB will be done later. This patch is based on the "mm: kasan: quarantine" patch originally prepared by Dmitry Chernenkov. A number of improvements have been suggested by Andrey Ryabinin. [glider@google.com: v9] Link: http://lkml.kernel.org/r/1462987130-144092-1-git-send-email-glider@google.com Signed-off-by: Alexander Potapenko <glider@google.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Andrey Konovalov <adech.fo@gmail.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Konstantin Serebryany <kcc@google.com> Cc: Dmitry Chernenkov <dmitryc@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/kasan.h | 13 ++- mm/kasan/Makefile | 1 + mm/kasan/kasan.c | 57 ++++++++-- mm/kasan/kasan.h | 21 +++- mm/kasan/quarantine.c | 291 ++++++++++++++++++++++++++++++++++++++++++++++++++ mm/kasan/report.c | 1 + mm/mempool.c | 2 +- mm/slab.c | 12 ++- mm/slab.h | 2 + mm/slab_common.c | 2 + 10 files changed, 387 insertions(+), 15 deletions(-) commit b8f1a75d61d8405a753380c6fb17ba84a5603cd4 Author: Yang Shi <yang.shi@linaro.org> Date: Fri May 20 16:59:08 2016 -0700 mm: call page_ext_init() after all struct pages are initialized When DEFERRED_STRUCT_PAGE_INIT is enabled, just a subset of memmap at boot are initialized, then the rest are initialized in parallel by starting one-off "pgdatinitX" kernel thread for each node X. If page_ext_init is called before it, some pages will not have valid extension, this may lead the below kernel oops when booting up kernel: BUG: unable to handle kernel NULL pointer dereference at (null) IP: [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 PGD 0 Oops: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC Modules linked in: CPU: 11 PID: 106 Comm: pgdatinit1 Not tainted 4.6.0-rc5-next-20160427 #26 Hardware name: Intel Corporation S5520HC/S5520HC, BIOS S5500.86B.01.10.0025.030220091519 03/02/2009 task: ffff88017c080040 ti: ffff88017c084000 task.ti: ffff88017c084000 RIP: 0010:[<ffffffff8118d982>] [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 RSP: 0000:ffff88017c087c48 EFLAGS: 00010046 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000001 RDX: 0000000000000980 RSI: 0000000000000080 RDI: 0000000000660401 RBP: ffff88017c087cd0 R08: 0000000000000401 R09: 0000000000000009 R10: ffff88017c080040 R11: 000000000000000a R12: 0000000000000400 R13: ffffea0019810000 R14: ffffea0019810040 R15: ffff88066cfe6080 FS: 0000000000000000(0000) GS:ffff88066cd40000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000000 CR3: 0000000002406000 CR4: 00000000000006e0 Call Trace: free_hot_cold_page+0x192/0x1d0 __free_pages+0x5c/0x90 __free_pages_boot_core+0x11a/0x14e deferred_free_range+0x50/0x62 deferred_init_memmap+0x220/0x3c3 kthread+0xf8/0x110 ret_from_fork+0x22/0x40 Code: 49 89 d4 48 c1 e0 06 49 01 c5 e9 de fe ff ff 4c 89 f7 44 89 4d b8 4c 89 45 c0 44 89 5d c8 48 89 4d d0 e8 62 c7 07 00 48 8b 4d d0 <48> 8b 00 44 8b 5d c8 4c 8b 45 c0 44 8b 4d b8 a8 02 0f 84 05 ff RIP [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 RSP <ffff88017c087c48> CR2: 0000000000000000 Move page_ext_init() after page_alloc_init_late() to make sure page extension is setup for all pages. Link: http://lkml.kernel.org/r/1463696006-31360-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> init/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit dfef2ef4027b1304149a65dc33794eab65e8a3bf Author: David Rientjes <rientjes@google.com> Date: Fri May 20 16:59:05 2016 -0700 mm, migrate: increment fail count on ENOMEM If page migration fails due to -ENOMEM, nr_failed should still be incremented for proper statistics. This was encountered recently when all page migration vmstats showed 0, and inferred that migrate_pages() was never called, although in reality the first page migration failed because compaction_alloc() failed to find a migration target. This patch increments nr_failed so the vmstat is properly accounted on ENOMEM. Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1605191510230.32658@chino.kir.corp.google.com Signed-off-by: David Rientjes <rientjes@google.com> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/migrate.c | 1 + 1 file changed, 1 insertion(+) commit 6cd9dc3e75078ef646076fa63adfb9b85ced0b66 Author: Chen Feng <puck.chen@hisilicon.com> Date: Fri May 20 16:59:02 2016 -0700 mm/compaction.c: fix zoneindex in kcompactd() While testing the kcompactd in my platform 3G MEM only DMA ZONE. I found the kcompactd never wakeup. It seems the zoneindex has already minus 1 before. So the traverse here should be <=. It fixes a regression where kswapd could previously compact, but kcompactd not. Not a crash fix though. [akpm@linux-foundation.org: fix kcompactd_do_work() as well, per Hugh] Link: http://lkml.kernel.org/r/1463659121-84124-1-git-send-email-puck.chen@hisilicon.com Fixes: accf62422b3a ("mm, kswapd: replace kswapd compaction with waking up kcompactd") Signed-off-by: Chen Feng <puck.chen@hisilicon.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Hugh Dickins <hughd@google.com> Cc: Michal Hocko <mhocko@suse.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Tejun Heo <tj@kernel.org> Cc: Zhuangluan Su <suzhuangluan@hisilicon.com> Cc: Yiping Xu <xuyiping@hisilicon.com> Cc: <stable@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/compaction.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0bb2fd13b69abfd88880f356903b5c7ca36d5eea Author: Yang Shi <yang.shi@linaro.org> Date: Fri May 20 16:58:59 2016 -0700 mm: page_is_guard(): return false when page_ext arrays are not allocated yet When enabling the below kernel configs: CONFIG_DEFERRED_STRUCT_PAGE_INIT CONFIG_DEBUG_PAGEALLOC CONFIG_PAGE_EXTENSION CONFIG_DEBUG_VM kernel bootup may fail due to the following oops: BUG: unable to handle kernel NULL pointer dereference at (null) IP: [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 PGD 0 Oops: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC Modules linked in: CPU: 11 PID: 106 Comm: pgdatinit1 Not tainted 4.6.0-rc5-next-20160427 #26 Hardware name: Intel Corporation S5520HC/S5520HC, BIOS S5500.86B.01.10.0025.030220091519 03/02/2009 task: ffff88017c080040 ti: ffff88017c084000 task.ti: ffff88017c084000 RIP: 0010:[<ffffffff8118d982>] [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 RSP: 0000:ffff88017c087c48 EFLAGS: 00010046 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000001 RDX: 0000000000000980 RSI: 0000000000000080 RDI: 0000000000660401 RBP: ffff88017c087cd0 R08: 0000000000000401 R09: 0000000000000009 R10: ffff88017c080040 R11: 000000000000000a R12: 0000000000000400 R13: ffffea0019810000 R14: ffffea0019810040 R15: ffff88066cfe6080 FS: 0000000000000000(0000) GS:ffff88066cd40000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000000 CR3: 0000000002406000 CR4: 00000000000006e0 Call Trace: free_hot_cold_page+0x192/0x1d0 __free_pages+0x5c/0x90 __free_pages_boot_core+0x11a/0x14e deferred_free_range+0x50/0x62 deferred_init_memmap+0x220/0x3c3 kthread+0xf8/0x110 ret_from_fork+0x22/0x40 Code: 49 89 d4 48 c1 e0 06 49 01 c5 e9 de fe ff ff 4c 89 f7 44 89 4d b8 4c 89 45 c0 44 89 5d c8 48 89 4d d0 e8 62 c7 07 00 48 8b 4d d0 <48> 8b 00 44 8b 5d c8 4c 8b 45 c0 44 8b 4d b8 a8 02 0f 84 05 ff RIP [<ffffffff8118d982>] free_pcppages_bulk+0x2d2/0x8d0 RSP <ffff88017c087c48> CR2: 0000000000000000 The problem is lookup_page_ext() returns NULL then page_is_guard() tried to access it in page freeing. page_is_guard() depends on PAGE_EXT_DEBUG_GUARD bit of page extension flag, but freeing page might reach here before the page_ext arrays are allocated when feeding a range of pages to the allocator for the first time during bootup or memory hotplug. When it returns NULL, page_is_guard() should just return false instead of checking PAGE_EXT_DEBUG_GUARD unconditionally. Link: http://lkml.kernel.org/r/1463610225-29060-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 3 +++ 1 file changed, 3 insertions(+) commit f0508977787b3bcfd54e82111ab50d6245b9f4df Author: David Rientjes <rientjes@google.com> Date: Fri May 20 16:58:56 2016 -0700 mm, thp: khugepaged should scan when sleep value is written If a large value is written to scan_sleep_millisecs, for example, that period must lapse before khugepaged will wake up for periodic collapsing. If this value is tuned to 1 day, for example, and then re-tuned to its default 10s, khugepaged will still wait for a day before scanning again. This patch causes khugepaged to wakeup immediately when the value is changed and then sleep until that value is rewritten or the new value lapses. Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1605181453200.4786@chino.kir.corp.google.com Signed-off-by: David Rientjes <rientjes@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/huge_memory.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) commit a53eaff8c1192bb5bdfda5deb484bc8f415c5dfd Author: NeilBrown <neilb@suse.com> Date: Fri May 20 16:58:53 2016 -0700 MM: increase safety margin provided by PF_LESS_THROTTLE When nfsd is exporting a filesystem over NFS which is then NFS-mounted on the local machine there is a risk of deadlock. This happens when there are lots of dirty pages in the NFS filesystem and they cause NFSD to be throttled, either in throttle_vm_writeout() or in balance_dirty_pages(). To avoid this problem the PF_LESS_THROTTLE flag is set for NFSD threads and it provides a 25% increase to the limits that affect NFSD. Any process writing to an NFS filesystem will be throttled well before the number of dirty NFS pages reaches the limit imposed on NFSD, so NFSD will not deadlock on pages that it needs to write out. At least it shouldn't. All processes are allowed a small excess margin to avoid performing too many calculations: ratelimit_pages. ratelimit_pages is set so that if a thread on every CPU uses the entire margin, the total will only go 3% over the limit, and this is much less than the 25% bonus that PF_LESS_THROTTLE provides, so this margin shouldn't be a problem. But it is. The "total memory" that these 3% and 25% are calculated against are not really total memory but are "global_dirtyable_memory()" which doesn't include anonymous memory, just free memory and page-cache memory. The "ratelimit_pages" number is based on whatever the global_dirtyable_memory was on the last CPU hot-plug, which might not be what you expect, but is probably close to the total freeable memory. The throttle threshold uses the global_dirtable_memory at the moment when the throttling happens, which could be much less than at the last CPU hotplug. So if lots of anonymous memory has been allocated, thus pushing out lots of page-cache pages, then NFSD might end up being throttled due to dirty NFS pages because the "25%" bonus it gets is calculated against a rather small amount of dirtyable memory, while the "3%" margin that other processes are allowed to dirty without penalty is calculated against a much larger number. To remove this possibility of deadlock we need to make sure that the margin granted to PF_LESS_THROTTLE exceeds that rate-limit margin. Simply adding ratelimit_pages isn't enough as that should be multiplied by the number of cpus. So add "global_wb_domain.dirty_limit / 32" as that more accurately reflects the current total over-shoot margin. This ensures that the number of dirty NFS pages never gets so high that nfsd will be throttled waiting for them to be written. Link: http://lkml.kernel.org/r/87futgowwv.fsf@notabene.neil.brown.name Signed-off-by: NeilBrown <neilb@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page-writeback.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e570f56cccd215db68e50870ee74b7d9c0022109 Author: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Date: Fri May 20 16:58:50 2016 -0700 mm: check_new_page_bad() directly returns in __PG_HWPOISON case Currently we check page->flags twice for "HWPoisoned" case of check_new_page_bad(), which can cause a race with unpoisoning. This race unnecessarily taints kernel with "BUG: Bad page state". check_new_page_bad() is the only caller of bad_page() which is interested in __PG_HWPOISON, so let's move the hwpoison related code in bad_page() to it. Link: http://lkml.kernel.org/r/20160518100949.GA17299@hori1.linux.bs1.fc.nec.co.jp Signed-off-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Mel Gorman <mgorman@techsingularity.net> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 29b52de182acf50f85a8284ad39104d84c9bbf57 Author: seokhoon.yoon <iamyooon@gmail.com> Date: Fri May 20 16:58:47 2016 -0700 mm, kasan: fix to call kasan_free_pages() after poisoning page When CONFIG_PAGE_POISONING and CONFIG_KASAN is enabled, free_pages_prepare()'s codeflow is below. 1)kmemcheck_free_shadow() 2)kasan_free_pages() - set shadow byte of page is freed 3)kernel_poison_pages() 3.1) check access to page is valid or not using kasan ---> error occur, kasan think it is invalid access 3.2) poison page 4)kernel_map_pages() So kasan_free_pages() should be called after poisoning the page. Link: http://lkml.kernel.org/r/1463220405-7455-1-git-send-email-iamyooon@gmail.com Signed-off-by: seokhoon.yoon <iamyooon@gmail.com> Cc: Andrey Ryabinin <a.ryabinin@samsung.com> Cc: Laura Abbott <labbott@fedoraproject.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d0834a6c2c5b0c76cfb806bd7dba6556d8b4edbb Author: Minchan Kim <minchan@kernel.org> Date: Fri May 20 16:58:44 2016 -0700 mm: disable fault around on emulated access bit architecture fault_around aims to reduce minor faults of file-backed pages via speculative ahead pte mapping and relying on readahead logic. However, on non-HW access bit architecture the benefit is highly limited because they should emulate the young bit with minor faults for reclaim's page aging algorithm. IOW, we cannot reduce minor faults on those architectures. I did quick a test on my ARM machine. 512M file mmap sequential every word read on eSATA drive 4 times. stddev is stable. = fault_around 4096 = elapsed time(usec): 6747645 = fault_around 65536 = elapsed time(usec): 6709263 0.5% gain. Even when I tested it with eMMC there is no gain because I guess with slow storage the major fault is the dominant factor. Also, fault_around has the side effect of shrinking slab more aggressively and causes higher vmpressure, so if such speculation fails, it can evict slab more which can result in page I/O (e.g., inode cache). In the end, it would make void any benefit of fault_around. So let's make the default "disabled" on those architectures. Link: http://lkml.kernel.org/r/20160518014229.GB21538@bbox Signed-off-by: Minchan Kim <minchan@kernel.org> Cc: Kirill A. Shutemov <kirill@shutemov.name> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memory.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 5c0a85fad949212b3e059692deecdeed74ae7ec7 Author: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Date: Fri May 20 16:58:41 2016 -0700 mm: make faultaround produce old ptes Currently, faultaround code produces young pte. This can screw up vmscan behaviour[1], as it makes vmscan think that these pages are hot and not push them out on first round. During sparse file access faultaround gets more pages mapped and all of them are young. Under memory pressure, this makes vmscan swap out anon pages instead, or to drop other page cache pages which otherwise stay resident. Modify faultaround to produce old ptes, so they can easily be reclaimed under memory pressure. This can to some extend defeat the purpose of faultaround on machines without hardware accessed bit as it will not help us with reducing the number of minor page faults. We may want to disable faultaround on such machines altogether, but that's subject for separate patchset. Minchan: "I tested 512M mmap sequential word read test on non-HW access bit system (i.e., ARM) and confirmed it doesn't increase minor fault any more. old: 4096 fault_around minor fault: 131291 elapsed time: 6747645 usec new: 65536 fault_around minor fault: 131291 elapsed time: 6709263 usec 0.56% benefit" [1] https://lkml.kernel.org/r/1460992636-711-1-git-send-email-vinmenon@codeaurora.org Link: http://lkml.kernel.org/r/1463488366-47723-1-git-send-email-kirill.shutemov@linux.intel.com Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Acked-by: Michal Hocko <mhocko@suse.com> Acked-by: Minchan Kim <minchan@kernel.org> Tested-by: Minchan Kim <minchan@kernel.org> Acked-by: Rik van Riel <riel@redhat.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Michal Hocko <mhocko@kernel.org> Cc: Vinayak Menon <vinmenon@codeaurora.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 2 +- mm/filemap.c | 2 +- mm/memory.c | 23 ++++++++++++++++++----- 3 files changed, 20 insertions(+), 7 deletions(-) commit 4b50bcc7eda4d3cc9e3f2a0aa60e590fedf728c5 Author: Stefan Bader <stefan.bader@canonical.com> Date: Fri May 20 16:58:38 2016 -0700 mm: use phys_addr_t for reserve_bootmem_region() arguments Since commit 92923ca3aace ("mm: meminit: only set page reserved in the memblock region") the reserved bit is set on reserved memblock regions. However start and end address are passed as unsigned long. This is only 32bit on i386, so it can end up marking the wrong pages reserved for ranges at 4GB and above. This was observed on a 32bit Xen dom0 which was booted with initial memory set to a value below 4G but allowing to balloon in memory (dom0_mem=1024M for example). This would define a reserved bootmem region for the additional memory (for example on a 8GB system there was a reverved region covering the 4GB-8GB range). But since the addresses were passed on as unsigned long, this was actually marking all pages from 0 to 4GB as reserved. Fixes: 92923ca3aacef63 ("mm: meminit: only set page reserved in the memblock region") Link: http://lkml.kernel.org/r/1463491221-10573-1-git-send-email-stefan.bader@canonical.com Signed-off-by: Stefan Bader <stefan.bader@canonical.com> Cc: <stable@vger.kernel.org> [4.2+] Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 2 +- mm/page_alloc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit d2005e3f41d4f9299e2df6a967c8beb5086967a9 Author: Oleg Nesterov <oleg@redhat.com> Date: Fri May 20 16:58:36 2016 -0700 userfaultfd: don't pin the user memory in userfaultfd_file_create() userfaultfd_file_create() increments mm->mm_users; this means that the memory won't be unmapped/freed if mm owner exits/execs, and UFFDIO_COPY after that can populate the orphaned mm more. Change userfaultfd_file_create() and userfaultfd_ctx_put() to use mm->mm_count to pin mm_struct. This means that atomic_inc_not_zero(mm->mm_users) is needed when we are going to actually play with this memory. Except handle_userfault() path doesn't need this, the caller must already have a reference. The patch adds the new trivial helper, mmget_not_zero(), it can have more users. Link: http://lkml.kernel.org/r/20160516172254.GA8595@redhat.com Signed-off-by: Oleg Nesterov <oleg@redhat.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Michal Hocko <mhocko@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/userfaultfd.c | 41 ++++++++++++++++++++++++++++------------- include/linux/sched.h | 7 ++++++- 2 files changed, 34 insertions(+), 14 deletions(-) commit cd33a76b0f2805fb0d6a05a2d53933f3817ccc9b Author: Richard Leitner <dev@g0hl1n.net> Date: Fri May 20 16:58:33 2016 -0700 mm/memblock.c: remove unnecessary always-true comparison Comparing an u64 variable to >= 0 returns always true and can therefore be removed. This issue was detected using the -Wtype-limits gcc flag. This patch fixes following type-limits warning: mm/memblock.c: In function `__next_reserved_mem_region': mm/memblock.c:843:11: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits] if (*idx >= 0 && *idx < type->cnt) { Link: http://lkml.kernel.org/r/20160510103625.3a7f8f32@g0hl1n.net Signed-off-by: Richard Leitner <dev@g0hl1n.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memblock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9a001fc19cccdeb9be4c3b89ad089d92df303c44 Author: Vitaly Wool <vitalywool@gmail.com> Date: Fri May 20 16:58:30 2016 -0700 z3fold: the 3-fold allocator for compressed pages This patch introduces z3fold, a special purpose allocator for storing compressed pages. It is designed to store up to three compressed pages per physical page. It is a ZBUD derivative which allows for higher compression ratio keeping the simplicity and determinism of its predecessor. This patch comes as a follow-up to the discussions at the Embedded Linux Conference in San-Diego related to the talk [1]. The outcome of these discussions was that it would be good to have a compressed page allocator as stable and deterministic as zbud with with higher compression ratio. To keep the determinism and simplicity, z3fold, just like zbud, always stores an integral number of compressed pages per page, but it can store up to 3 pages unlike zbud which can store at most 2. Therefore the compression ratio goes to around 2.6x while zbud's one is around 1.7x. The patch is based on the latest linux.git tree. This version has been updated after testing on various simulators (e.g. ARM Versatile Express, MIPS Malta, x86_64/Haswell) and basing on comments from Dan Streetman [3]. [1] https://openiotelc2016.sched.org/event/6DAC/swapping-and-embedded-compression-relieves-the-pressure-vitaly-wool-softprise-consulting-ou [2] https://lkml.org/lkml/2016/4/21/799 [3] https://lkml.org/lkml/2016/5/4/852 Link: http://lkml.kernel.org/r/20160509151753.ec3f9fda3c9898d31ff52a32@gmail.com Signed-off-by: Vitaly Wool <vitalywool@gmail.com> Cc: Seth Jennings <sjenning@redhat.com> Cc: Dan Streetman <ddstreet@ieee.org> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/vm/z3fold.txt | 26 ++ mm/Kconfig | 12 +- mm/Makefile | 1 + mm/z3fold.c | 792 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 830 insertions(+), 1 deletion(-) commit d5ee7c3bcca6fe2b4f7a1fdee253250059c110d2 Author: Andrea Arcangeli <aarcange@redhat.com> Date: Fri May 20 16:58:27 2016 -0700 mm: thp: split_huge_pmd_address() comment improvement Comment is partly wrong, this improves it by including the case of split_huge_pmd_address() called by try_to_unmap_one if TTU_SPLIT_HUGE_PMD is set. Link: http://lkml.kernel.org/r/1462547040-1737-4-git-send-email-aarcange@redhat.com Signed-off-by: Andrea Arcangeli <aarcange@redhat.com> Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/huge_memory.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 5f527c2b3ea261bfccb7d12f9feade924cc4987c Author: Andrea Arcangeli <aarcange@redhat.com> Date: Fri May 20 16:58:24 2016 -0700 mm: thp: microoptimize compound_mapcount() compound_mapcount() is only called after PageCompound() has already been checked by the caller, so there's no point to check it again. Gcc may optimize it away too because it's inline but this will remove the runtime check for sure and add it'll add an assert instead. Link: http://lkml.kernel.org/r/1462547040-1737-3-git-send-email-aarcange@redhat.com Signed-off-by: Andrea Arcangeli <aarcange@redhat.com> Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 7b8da4c7f0777489f8690115b5fd7704ac0abb8f Author: Christoph Lameter <cl@linux.com> Date: Fri May 20 16:58:21 2016 -0700 vmstat: get rid of the ugly cpu_stat_off variable The cpu_stat_off variable is unecessary since we can check if a workqueue request is pending otherwise. Removal of cpu_stat_off makes it pretty easy for the vmstat shepherd to ensure that the proper things happen. Removing the state also removes all races related to it. Should a workqueue not be scheduled as needed for vmstat_update then the shepherd will notice and schedule it as needed. Should a workqueue be unecessarily scheduled then the vmstat updater will disable it. [akpm@linux-foundation.org: fix indentation, per Michal] Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1605061306460.17934@east.gentwo.org Signed-off-by: Christoph Lameter <cl@linux.com> Cc: Tejun Heo <htejun@gmail.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmstat.c | 51 ++++++++++----------------------------------------- 1 file changed, 10 insertions(+), 41 deletions(-) commit 51038171b7ecf0017fbe3e06bd246eaa26f4d2e7 Author: Greg Thelen <gthelen@google.com> Date: Fri May 20 16:58:18 2016 -0700 memcg: fix stale mem_cgroup_force_empty() comment Commit f61c42a7d911 ("memcg: remove tasks/children test from mem_cgroup_force_empty()") removed memory reparenting from the function. Fix the function's comment. Link: http://lkml.kernel.org/r/1462569810-54496-1-git-send-email-gthelen@google.com Signed-off-by: Greg Thelen <gthelen@google.com> Acked-by: Johannes Weiner <hannes@cmpxchg.org> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memcontrol.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit d2a1a1f0a97a77d25cbada37161dc2ecdf01f93d Author: Yu Zhao <yuzhao@google.com> Date: Fri May 20 16:58:16 2016 -0700 mm: use unsigned long constant for page flags struct page->flags is unsigned long, so when shifting bits we should use UL suffix to match it. Found this problem after I added 64-bit CPU specific page flags and failed to compile the kernel: mm/page_alloc.c: In function '__free_one_page': mm/page_alloc.c:672:2: error: integer overflow in expression [-Werror=overflow] Link: http://lkml.kernel.org/r/1461971723-16187-1-git-send-email-yuzhao@google.com Signed-off-by: Yu Zhao <yuzhao@google.com> Cc: "Kirill A . Shutemov" <kirill.shutemov@linux.intel.com> Cc: Michal Hocko <mhocko@suse.com> Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/page-flags.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 2a138dc7e50bfdc90f9db9b52584ac5564952425 Author: Minfei Huang <mnghuan@gmail.com> Date: Fri May 20 16:58:13 2016 -0700 mm: use existing helper to convert "on"/"off" to boolean It's more convenient to use existing function helper to convert string "on/off" to boolean. Link: http://lkml.kernel.org/r/1461908824-16129-1-git-send-email-mnghuan@gmail.com Signed-off-by: Minfei Huang <mnghuan@gmail.com> Acked-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 9 +-------- mm/page_poison.c | 8 +------- 2 files changed, 2 insertions(+), 15 deletions(-) commit 78ebc2f7146156f488083c9e5a7ded9d5c38c58b Author: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Date: Fri May 20 16:58:10 2016 -0700 mm,writeback: don't use memory reserves for wb_start_writeback When writeback operation cannot make forward progress because memory allocation requests needed for doing I/O cannot be satisfied (e.g. under OOM-livelock situation), we can observe flood of order-0 page allocation failure messages caused by complete depletion of memory reserves. This is caused by unconditionally allocating "struct wb_writeback_work" objects using GFP_ATOMIC from PF_MEMALLOC context. __alloc_pages_nodemask() { __alloc_pages_slowpath() { __alloc_pages_direct_reclaim() { __perform_reclaim() { current->flags |= PF_MEMALLOC; try_to_free_pages() { do_try_to_free_pages() { wakeup_flusher_threads() { wb_start_writeback() { kzalloc(sizeof(*work), GFP_ATOMIC) { /* ALLOC_NO_WATERMARKS via PF_MEMALLOC */ } } } } } current->flags &= ~PF_MEMALLOC; } } } } Since I/O is stalling, allocating writeback requests forever shall deplete memory reserves. Fortunately, since wb_start_writeback() can fall back to wb_wakeup() when allocating "struct wb_writeback_work" failed, we don't need to allow wb_start_writeback() to use memory reserves. Mem-Info: active_anon:289393 inactive_anon:2093 isolated_anon:29 active_file:10838 inactive_file:113013 isolated_file:859 unevictable:0 dirty:108531 writeback:5308 unstable:0 slab_reclaimable:5526 slab_unreclaimable:7077 mapped:9970 shmem:2159 pagetables:2387 bounce:0 free:3042 free_pcp:0 free_cma:0 Node 0 DMA free:6968kB min:44kB low:52kB high:64kB active_anon:6056kB inactive_anon:176kB active_file:712kB inactive_file:744kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:15988kB managed:15904kB mlocked:0kB dirty:756kB writeback:0kB mapped:736kB shmem:184kB slab_reclaimable:48kB slab_unreclaimable:208kB kernel_stack:160kB pagetables:144kB unstable:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:9708 all_unreclaimable? yes lowmem_reserve[]: 0 1732 1732 1732 Node 0 DMA32 free:5200kB min:5200kB low:6500kB high:7800kB active_anon:1151516kB inactive_anon:8196kB active_file:42640kB inactive_file:451076kB unevictable:0kB isolated(anon):116kB isolated(file):3564kB present:2080640kB managed:1775332kB mlocked:0kB dirty:433368kB writeback:21232kB mapped:39144kB shmem:8452kB slab_reclaimable:22056kB slab_unreclaimable:28100kB kernel_stack:20976kB pagetables:9404kB unstable:0kB bounce:0kB free_pcp:120kB local_pcp:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:2701604 all_unreclaimable? no lowmem_reserve[]: 0 0 0 0 Node 0 DMA: 25*4kB (UME) 16*8kB (UME) 3*16kB (UE) 5*32kB (UME) 2*64kB (UM) 2*128kB (ME) 2*256kB (ME) 1*512kB (E) 1*1024kB (E) 2*2048kB (ME) 0*4096kB = 6964kB Node 0 DMA32: 925*4kB (UME) 140*8kB (UME) 5*16kB (ME) 5*32kB (M) 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 5060kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=1048576kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 126847 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 524157 pages RAM 0 pages HighMem/MovableOnly 76348 pages reserved 0 pages hwpoisoned Out of memory: Kill process 4450 (file_io.00) score 998 or sacrifice child Killed process 4450 (file_io.00) total-vm:4308kB, anon-rss:100kB, file-rss:1184kB, shmem-rss:0kB kthreadd: page allocation failure: order:0, mode:0x2200020 file_io.00: page allocation failure: order:0, mode:0x2200020 CPU: 0 PID: 4457 Comm: file_io.00 Not tainted 4.5.0-rc7+ #45 Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 07/31/2013 Call Trace: warn_alloc_failed+0xf7/0x150 __alloc_pages_nodemask+0x23f/0xa60 alloc_pages_current+0x87/0x110 new_slab+0x3a1/0x440 ___slab_alloc+0x3cf/0x590 __slab_alloc.isra.64+0x18/0x1d kmem_cache_alloc+0x11c/0x150 wb_start_writeback+0x39/0x90 wakeup_flusher_threads+0x7f/0xf0 do_try_to_free_pages+0x1f9/0x410 try_to_free_pages+0x94/0xc0 __alloc_pages_nodemask+0x566/0xa60 alloc_pages_current+0x87/0x110 __page_cache_alloc+0xaf/0xc0 pagecache_get_page+0x88/0x260 grab_cache_page_write_begin+0x21/0x40 xfs_vm_write_begin+0x2f/0xf0 generic_perform_write+0xca/0x1c0 xfs_file_buffered_aio_write+0xcc/0x1f0 xfs_file_write_iter+0x84/0x140 __vfs_write+0xc7/0x100 vfs_write+0x9d/0x190 SyS_write+0x50/0xc0 entry_SYSCALL_64_fastpath+0x12/0x6a Mem-Info: active_anon:293335 inactive_anon:2093 isolated_anon:0 active_file:10829 inactive_file:110045 isolated_file:32 unevictable:0 dirty:109275 writeback:822 unstable:0 slab_reclaimable:5489 slab_unreclaimable:10070 mapped:9999 shmem:2159 pagetables:2420 bounce:0 free:3 free_pcp:0 free_cma:0 Node 0 DMA free:12kB min:44kB low:52kB high:64kB active_anon:6060kB inactive_anon:176kB active_file:708kB inactive_file:756kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:15988kB managed:15904kB mlocked:0kB dirty:756kB writeback:0kB mapped:736kB shmem:184kB slab_reclaimable:48kB slab_unreclaimable:7160kB kernel_stack:160kB pagetables:144kB unstable:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:9844 all_unreclaimable? yes lowmem_reserve[]: 0 1732 1732 1732 Node 0 DMA32 free:0kB min:5200kB low:6500kB high:7800kB active_anon:1167280kB inactive_anon:8196kB active_file:42608kB inactive_file:439424kB unevictable:0kB isolated(anon):0kB isolated(file):128kB present:2080640kB managed:1775332kB mlocked:0kB dirty:436344kB writeback:3288kB mapped:39260kB shmem:8452kB slab_reclaimable:21908kB slab_unreclaimable:33120kB kernel_stack:20976kB pagetables:9536kB unstable:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:11073180 all_unreclaimable? yes lowmem_reserve[]: 0 0 0 0 Node 0 DMA: 0*4kB 0*8kB 0*16kB 0*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 0kB Node 0 DMA32: 0*4kB 0*8kB 0*16kB 0*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 0kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=1048576kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 123086 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 524157 pages RAM 0 pages HighMem/MovableOnly 76348 pages reserved 0 pages hwpoisoned SLUB: Unable to allocate memory on node -1 (gfp=0x2088020) cache: kmalloc-64, object size: 64, buffer size: 64, default order: 0, min order: 0 node 0: slabs: 3218, objs: 205952, free: 0 file_io.00: page allocation failure: order:0, mode:0x2200020 CPU: 0 PID: 4457 Comm: file_io.00 Not tainted 4.5.0-rc7+ #45 Assuming that somebody will find a better solution, let's apply this patch for now to stop bleeding, for this problem frequently prevents me from testing OOM livelock condition. Link: http://lkml.kernel.org/r/20160318131136.GE7152@quack.suse.cz Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Jan Kara <jack@suse.cz> Cc: Tejun Heo <tj@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/fs-writeback.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 89474d50a0d6b9a06e043351b4e658f4f0b6ee97 Author: Eric Engestrom <eric@engestrom.ch> Date: Fri May 20 16:58:07 2016 -0700 Documentation: vm: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Cc: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/vm/transhuge.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 0c9ad804f178eae02a34045bb0916fa0e31623d5 Author: Weijie Yang <weijie.yang@samsung.com> Date: Fri May 20 16:58:04 2016 -0700 mm fix commmets: if SPARSEMEM, pgdata doesn't have page_ext If SPARSEMEM, use page_ext in mem_section if !SPARSEMEM, use page_ext in pgdata Signed-off-by: Weijie Yang <weijie.yang@samsung.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mmzone.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d70c17d436b3fb9dbdae8c93bf908a6110b0cb4f Author: Chen Gang <chengang@emindsoft.com.cn> Date: Fri May 20 16:58:01 2016 -0700 include/linux/hugetlb.h: use bool instead of int for hugepage_migration_supported() It is used as a pure bool function within kernel source wide. Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/hugetlb.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7fab358d90e6ba9d9cb702bee0c8a5f5c13bb6df Author: Chen Gang <gang.chen.5i5j@gmail.com> Date: Fri May 20 16:57:59 2016 -0700 include/linux/hugetlb*.h: clean up code Macro HUGETLBFS_SB is clear enough, so one statement is clearer than 3 lines statements. Remove redundant return statements for non-return functions, which can save lines, at least. Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/hugetlb.h | 4 +--- include/linux/hugetlb_cgroup.h | 4 ---- 2 files changed, 1 insertion(+), 7 deletions(-) commit a4a921aa5c7a1ab621e71fd1a4289e76fe230cbd Author: Ming Li <mingli199x@qq.com> Date: Fri May 20 16:57:56 2016 -0700 mm/swap.c: put activate_page_pvecs and other pagevecs together Put the activate_page_pvecs definition next to those of the other pagevecs, for clarity. Signed-off-by: Ming Li <mingli199x@qq.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/swap.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit b8ca9e3a612eaf3e54c6fa136c62246a1a9aece7 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 20 16:57:53 2016 -0700 mm: tighten fault_in_pages_writeable() copy_page_to_iter_iovec() is currently the only user of fault_in_pages_writeable(), and it definitely can use fragments from high order pages. Make sure fault_in_pages_writeable() is only touching two adjacent pages at most, as claimed. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/pagemap.h | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) commit 297880f4af4e492ed5084be9397d65a18ade56ee Author: David Rientjes <rientjes@google.com> Date: Fri May 20 16:57:50 2016 -0700 mm, hugetlb_cgroup: round limit_in_bytes down to hugepage size The page_counter rounds limits down to page size values. This makes sense, except in the case of hugetlb_cgroup where it's not possible to charge partial hugepages. If the hugetlb_cgroup margin is less than the hugepage size being charged, it will fail as expected. Round the hugetlb_cgroup limit down to hugepage size, since it is the effective limit of the cgroup. For consistency, round down PAGE_COUNTER_MAX as well when a hugetlb_cgroup is created: this prevents error reports when a user cannot restore the value to the kernel default. Signed-off-by: David Rientjes <rientjes@google.com> Cc: Michal Hocko <mhocko@kernel.org> Cc: Nikolay Borisov <kernel@kyup.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/hugetlb_cgroup.c | 35 ++++++++++++++++++++++++++--------- 1 file changed, 26 insertions(+), 9 deletions(-) commit 63678c32e209bd165f33432bbed72b2954ce5ae4 Author: Rich Felker <dalias@libc.org> Date: Fri May 20 16:57:47 2016 -0700 tmpfs/ramfs: fix VM_MAYSHARE mappings for NOMMU The nommu do_mmap expects f_op->get_unmapped_area to either succeed or return -ENOSYS for VM_MAYSHARE (e.g. private read-only) mappings. Returning addr in the non-MAP_SHARED case was completely wrong, and only happened to work because addr was 0. However, it prevented VM_MAYSHARE mappings from sharing backing with the fs cache, and forced such mappings (including shareable program text) to be copied whenever the number of mappings transitioned from 0 to 1, impacting performance and memory usage. Subsequent mappings beyond the first still correctly shared memory with the first. Instead, treat VM_MAYSHARE identically to VM_SHARED at the file ops level; do_mmap already handles the semantic differences between them. Signed-off-by: Rich Felker <dalias@libc.org> Cc: Michal Hocko <mhocko@suse.com> Cc: Greg Ungerer <gerg@uclinux.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ramfs/file-nommu.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit f4fcd55841fc9e46daac553b39361572453c2b88 Author: Konstantin Khlebnikov <koct9i@gmail.com> Date: Fri May 20 16:57:45 2016 -0700 mm: enable RLIMIT_DATA by default with workaround for valgrind Since commit 84638335900f ("mm: rework virtual memory accounting") RLIMIT_DATA limits both brk() and private mmap() but this's disabled by default because of incompatibility with older versions of valgrind. Valgrind always set limit to zero and fails if RLIMIT_DATA is enabled. Fortunately it changes only rlim_cur and keeps rlim_max for reverting limit back when needed. This patch checks current usage also against rlim_max if rlim_cur is zero. This is safe because task anyway can increase rlim_cur up to rlim_max. Size of brk is still checked against rlim_cur, so this part is completely compatible - zero rlim_cur forbids brk() but allows private mmap(). Link: http://lkml.kernel.org/r/56A28613.5070104@de.ibm.com Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Cyrill Gorcunov <gorcunov@openvz.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/mmap.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit d5957d2fc232a689543bdbed1a5ff8002f0e9843 Author: Yongji Xie <xyjxie@linux.vnet.ibm.com> Date: Fri May 20 16:57:41 2016 -0700 mm: fix incorrect pfn passed to untrack_pfn() in remap_pfn_range() We use generic hooks in remap_pfn_range() to help archs to track pfnmap regions. The code is something like: int remap_pfn_range() { ... track_pfn_remap(vma, &prot, pfn, addr, PAGE_ALIGN(size)); ... pfn -= addr >> PAGE_SHIFT; ... untrack_pfn(vma, pfn, PAGE_ALIGN(size)); ... } Here we can easily find the pfn is changed but not recovered before untrack_pfn() is called. That's incorrect. There are no known runtime effects - this is from inspection. Signed-off-by: Yongji Xie <xyjxie@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Matthew Wilcox <matthew.r.wilcox@intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Michal Hocko <mhocko@suse.com> Cc: Andy Lutomirski <luto@kernel.org> Cc: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memory.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 80c4bd7a5e4368b680e0aeb57050a1b06eb573d8 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri May 20 16:57:38 2016 -0700 mm/vmalloc: keep a separate lazy-free list When mixing lots of vmallocs and set_memory_*() (which calls vm_unmap_aliases()) I encountered situations where the performance degraded severely due to the walking of the entire vmap_area list each invocation. One simple improvement is to add the lazily freed vmap_area to a separate lockless free list, such that we then avoid having to walk the full list on each purge. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Roman Pen <r.peniaev@gmail.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Roman Pen <r.peniaev@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Toshi Kani <toshi.kani@hp.com> Cc: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/vmalloc.h | 3 ++- mm/vmalloc.c | 39 +++++++++++++++++++-------------------- 2 files changed, 21 insertions(+), 21 deletions(-) commit f705ac4b39f30a6a5f8411a42114758f4d4655bc Author: Alexander Kuleshov <kuleshovmail@gmail.com> Date: Fri May 20 16:57:35 2016 -0700 mm/memblock.c: move memblock_{add,reserve}_region into memblock_{add,reserve} memblock_add_region() and memblock_reserve_region() do nothing specific before the call of memblock_add_range(), only print debug output. We can do the same in memblock_add() and memblock_reserve() since both memblock_add_region() and memblock_reserve_region() are not used by anybody outside of memblock.c and memblock_{add,reserve}() have the same set of flags and nids. Since memblock_add_region() and memblock_reserve_region() will be inlined, there will not be functional changes, but will improve code readability a little. Signed-off-by: Alexander Kuleshov <kuleshovmail@gmail.com> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Pekka Enberg <penberg@kernel.org> Cc: Tony Luck <tony.luck@intel.com> Cc: Tang Chen <tangchen@cn.fujitsu.com> Cc: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memblock.c | 28 ++++++---------------------- 1 file changed, 6 insertions(+), 22 deletions(-) commit 495367c051fb200a42636bdc63be78ca1713a85a Author: Chen Yucong <slaoub@gmail.com> Date: Fri May 20 16:57:32 2016 -0700 mm/memory-failure.c: replace "MCE" with "Memory failure" HWPoison was specific to some particular x86 platforms. And it is often seen as high level machine check handler. And therefore, 'MCE' is used for the format prefix of printk(). However, 'PowerNV' has also used HWPoison for handling memory errors[1], so 'MCE' is no longer suitable to memory_failure.c. Additionally, 'MCE' and 'Memory failure' have different context. The former belongs to exception context and the latter belongs to process context. Furthermore, HWPoison can also be used for off-lining those sub-health pages that do not trigger any machine check exception. This patch aims to replace 'MCE' with a more appropriate prefix. [1] commit 75eb3d9b60c2 ("powerpc/powernv: Get FSP memory errors and plumb into memory poison infrastructure.") Signed-off-by: Chen Yucong <slaoub@gmail.com> Acked-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memory-failure.c | 72 +++++++++++++++++++++++++++++------------------------ 1 file changed, 40 insertions(+), 32 deletions(-) commit 340a43bed674a70308f196f2a61ec0b01f8a14d9 Author: Yang Shi <yang.shi@linaro.org> Date: Fri May 20 16:57:30 2016 -0700 mm: thp: simplify the implementation of mk_huge_pmd() The implementation of mk_huge_pmd looks verbose, it could be just simplified to one line code. Signed-off-by: Yang Shi <yang.shi@linaro.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/huge_memory.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit f44666b04605d1c7fd94ab90b7ccf633e7eff228 Author: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Date: Fri May 20 16:57:27 2016 -0700 mm,oom: speed up select_bad_process() loop Since commit 3a5dda7a17cf ("oom: prevent unnecessary oom kills or kernel panics"), select_bad_process() is using for_each_process_thread(). Since oom_unkillable_task() scans all threads in the caller's thread group and oom_task_origin() scans signal_struct of the caller's thread group, we don't need to call oom_unkillable_task() and oom_task_origin() on each thread. Also, since !mm test will be done later at oom_badness(), we don't need to do !mm test on each thread. Therefore, we only need to do TIF_MEMDIE test on each thread. Although the original code was correct it was quite inefficient because each thread group was scanned num_threads times which can be a lot especially with processes with many threads. Even though the OOM is extremely cold path it is always good to be as effective as possible when we are inside rcu_read_lock() - aka unpreemptible context. If we track number of TIF_MEMDIE threads inside signal_struct, we don't need to do TIF_MEMDIE test on each thread. This will allow select_bad_process() to use for_each_process(). This patch adds a counter to signal_struct for tracking how many TIF_MEMDIE threads are in a given thread group, and check it at oom_scan_process_thread() so that select_bad_process() can use for_each_process() rather than for_each_process_thread(). [mhocko@suse.com: do not blow the signal_struct size] Link: http://lkml.kernel.org/r/20160520075035.GF19172@dhcp22.suse.cz Link: http://lkml.kernel.org/r/201605182230.IDC73435.MVSOHLFOQFOJtF@I-love.SAKURA.ne.jp Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Acked-by: Michal Hocko <mhocko@suse.com> Cc: David Rientjes <rientjes@google.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/sched.h | 1 + mm/oom_kill.c | 17 ++++++----------- 2 files changed, 7 insertions(+), 11 deletions(-) commit 98748bd722005be9de2662bd4f7e41ad8148bdbd Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:24 2016 -0700 oom: consider multi-threaded tasks in task_will_free_mem task_will_free_mem is a misnomer for a more complex PF_EXITING test for early break out from the oom killer because it is believed that such a task would release its memory shortly and so we do not have to select an oom victim and perform a disruptive action. Currently we make sure that the given task is not participating in the core dumping because it might get blocked for a long time - see commit d003f371b270 ("oom: don't assume that a coredumping thread will exit soon"). The check can still do better though. We shouldn't consider the task unless the whole thread group is going down. This is rather unlikely but not impossible. A single exiting thread would surely leave all the address space behind. If we are really unlucky it might get stuck on the exit path and keep its TIF_MEMDIE and so block the oom killer. Link: http://lkml.kernel.org/r/1460452756-15491-1-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: David Rientjes <rientjes@google.com> Cc: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/oom.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit ec8d7c14ea14922fe21945b458a75e39f11dd832 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:21 2016 -0700 mm, oom_reaper: do not mmput synchronously from the oom reaper context Tetsuo has properly noted that mmput slow path might get blocked waiting for another party (e.g. exit_aio waits for an IO). If that happens the oom_reaper would be put out of the way and will not be able to process next oom victim. We should strive for making this context as reliable and independent on other subsystems as much as possible. Introduce mmput_async which will perform the slow path from an async (WQ) context. This will delay the operation but that shouldn't be a problem because the oom_reaper has reclaimed the victim's address space for most cases as much as possible and the remaining context shouldn't bind too much memory anymore. The only exception is when mmap_sem trylock has failed which shouldn't happen too often. The issue is only theoretical but not impossible. Signed-off-by: Michal Hocko <mhocko@suse.com> Reported-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm_types.h | 2 ++ include/linux/sched.h | 5 +++++ kernel/fork.c | 50 +++++++++++++++++++++++++++++++++--------------- mm/oom_kill.c | 8 ++++++-- 4 files changed, 48 insertions(+), 17 deletions(-) commit bb8a4b7fd1266ef888b3a80aa5f266062b224ef4 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:18 2016 -0700 mm, oom_reaper: hide oom reaped tasks from OOM killer more carefully Commit 36324a990cf5 ("oom: clear TIF_MEMDIE after oom_reaper managed to unmap the address space") not only clears TIF_MEMDIE for oom reaped task but also set OOM_SCORE_ADJ_MIN for the target task to hide it from the oom killer. This works in simple cases but it is not sufficient for (unlikely) cases where the mm is shared between independent processes (as they do not share signal struct). If the mm had only small amount of memory which could be reaped then another task sharing the mm could be selected and that wouldn't help to move out from the oom situation. Introduce MMF_OOM_REAPED mm flag which is checked in oom_badness (same as OOM_SCORE_ADJ_MIN) and task is skipped if the flag is set. Set the flag after __oom_reap_task is done with a task. This will force the select_bad_process() to ignore all already oom reaped tasks as well as no such task is sacrificed for its parent. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/sched.h | 1 + mm/oom_kill.c | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) commit 31e49bfda18464b9b0cfe42044d5a4be4a0ca0f3 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:15 2016 -0700 mm, oom: protect !costly allocations some more for !CONFIG_COMPACTION Joonsoo has reported that he is able to trigger OOM for !costly high order requests (heavy fork() workload close the OOM) with the new oom detection rework. This is because we rely only on should_reclaim_retry when the compaction is disabled and it only checks watermarks for the requested order and so we might trigger OOM when there is a lot of free memory. It is not very clear what are the usual workloads when the compaction is disabled. Relying on high order allocations heavily without any mechanism to create those orders except for unbound amount of reclaim is certainly not a good idea. To prevent from potential regressions let's help this configuration some. We have to sacrifice the determinsm though because there simply is none here possible. should_compact_retry implementation for !CONFIG_COMPACTION, which was empty so far, will do watermark check for order-0 on all eligible zones. This will cause retrying until either the reclaim cannot make any further progress or all the zones are depleted even for order-0 pages. This means that the number of retries is basically unbounded for !costly orders but that was the case before the rework as well so this shouldn't regress. [akpm@linux-foundation.org: coding-style fixes] Link: http://lkml.kernel.org/r/1463051677-29418-3-git-send-email-mhocko@kernel.org Reported-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 86a294a81f93d6f36d00ec3ff779d36d218f852d Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:12 2016 -0700 mm, oom, compaction: prevent from should_compact_retry looping for ever for costly orders "mm: consider compaction feedback also for costly allocation" has removed the upper bound for the reclaim/compaction retries based on the number of reclaimed pages for costly orders. While this is desirable the patch did miss a mis interaction between reclaim, compaction and the retry logic. The direct reclaim tries to get zones over min watermark while compaction backs off and returns COMPACT_SKIPPED when all zones are below low watermark + 1<<order gap. If we are getting really close to OOM then __compaction_suitable can keep returning COMPACT_SKIPPED a high order request (e.g. hugetlb order-9) while the reclaim is not able to release enough pages to get us over low watermark. The reclaim is still able to make some progress (usually trashing over few remaining pages) so we are not able to break out from the loop. I have seen this happening with the same test described in "mm: consider compaction feedback also for costly allocation" on a swapless system. The original problem got resolved by "vmscan: consider classzone_idx in compaction_ready" but it shows how things might go wrong when we approach the oom event horizont. The reason why compaction requires being over low rather than min watermark is not clear to me. This check was there essentially since 56de7263fcf3 ("mm: compaction: direct compact when a high-order allocation fails"). It is clearly an implementation detail though and we shouldn't pull it into the generic retry logic while we should be able to cope with such eventuality. The only place in should_compact_retry where we retry without any upper bound is for compaction_withdrawn() case. Introduce compaction_zonelist_suitable function which checks the given zonelist and returns true only if there is at least one zone which would would unblock __compaction_suitable if more memory got reclaimed. In this implementation it checks __compaction_suitable with NR_FREE_PAGES plus part of the reclaimable memory as the target for the watermark check. The reclaimable memory is reduced linearly by the allocation order. The idea is that we do not want to reclaim all the remaining memory for a single allocation request just unblock __compaction_suitable which doesn't guarantee we will make a further progress. The new helper is then used if compaction_withdrawn() feedback was provided so we do not retry if there is no outlook for a further progress. !costly requests shouldn't be affected much - e.g. order-2 pages would require to have at least 64kB on the reclaimable LRUs while order-9 would need at least 32M which should be enough to not lock up. [vbabka@suse.cz: fix classzone_idx vs. high_zoneidx usage in compaction_zonelist_suitable] [akpm@linux-foundation.org: fix it for Mel's mm-page_alloc-remove-field-from-alloc_context.patch] Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 4 ++++ include/linux/mmzone.h | 3 +++ mm/compaction.c | 42 +++++++++++++++++++++++++++++++++++++++--- mm/page_alloc.c | 23 +++++++++++++---------- 4 files changed, 59 insertions(+), 13 deletions(-) commit 7854ea6c28c6076050e24773eeb78e2925bd7411 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:09 2016 -0700 mm: consider compaction feedback also for costly allocation PAGE_ALLOC_COSTLY_ORDER retry logic is mostly handled inside should_reclaim_retry currently where we decide to not retry after at least order worth of pages were reclaimed or the watermark check for at least one zone would succeed after reclaiming all pages if the reclaim hasn't made any progress. Compaction feedback is mostly ignored and we just try to make sure that the compaction did at least something before giving up. The first condition was added by a41f24ea9fd6 ("page allocator: smarter retry of costly-order allocations) and it assumed that lumpy reclaim could have created a page of the sufficient order. Lumpy reclaim, has been removed quite some time ago so the assumption doesn't hold anymore. Remove the check for the number of reclaimed pages and rely on the compaction feedback solely. should_reclaim_retry now only makes sure that we keep retrying reclaim for high order pages only if they are hidden by watermaks so order-0 reclaim makes really sense. should_compact_retry now keeps retrying even for the costly allocations. The number of retries is reduced wrt. !costly requests because they are less important and harder to grant and so their pressure shouldn't cause contention for other requests or cause an over reclaim. We also do not reset no_progress_loops for costly request to make sure we do not keep reclaiming too agressively. This has been tested by running a process which fragments memory: - compact memory - mmap large portion of the memory (1920M on 2GRAM machine with 2G of swapspace) - MADV_DONTNEED single page in PAGE_SIZE*((1UL<<MAX_ORDER)-1) steps until certain amount of memory is freed (250M in my test) and reduce the step to (step / 2) + 1 after reaching the end of the mapping - then run a script which populates the page cache 2G (MemTotal) from /dev/zero to a new file And then tries to allocate nr_hugepages=$(awk '/MemAvailable/{printf "%d\n", $2/(2*1024)}' /proc/meminfo) huge pages. root@test1:~# echo 1 > /proc/sys/vm/overcommit_memory;echo 1 > /proc/sys/vm/compact_memory; ./fragment-mem-and-run /root/alloc_hugepages.sh 1920M 250M Node 0, zone DMA 31 28 31 10 2 0 2 1 2 3 1 Node 0, zone DMA32 437 319 171 50 28 25 20 16 16 14 437 * This is the /proc/buddyinfo after the compaction Done fragmenting. size=2013265920 freed=262144000 Node 0, zone DMA 165 48 3 1 2 0 2 2 2 2 0 Node 0, zone DMA32 35109 14575 185 51 41 12 6 0 0 0 0 * /proc/buddyinfo after memory got fragmented Executing "/root/alloc_hugepages.sh" Eating some pagecache 508623+0 records in 508623+0 records out 2083319808 bytes (2.1 GB) copied, 11.7292 s, 178 MB/s Node 0, zone DMA 3 5 3 1 2 0 2 2 2 2 0 Node 0, zone DMA32 111 344 153 20 24 10 3 0 0 0 0 * /proc/buddyinfo after page cache got eaten Trying to allocate 129 129 * 129 hugepages requested and all of them granted. Node 0, zone DMA 3 5 3 1 2 0 2 2 2 2 0 Node 0, zone DMA32 127 97 30 99 11 6 2 1 4 0 0 * /proc/buddyinfo after hugetlb allocation. 10 runs will behave as follows: Trying to allocate 130 130 -- Trying to allocate 129 129 -- Trying to allocate 128 128 -- Trying to allocate 129 129 -- Trying to allocate 128 128 -- Trying to allocate 129 129 -- Trying to allocate 132 132 -- Trying to allocate 129 129 -- Trying to allocate 128 128 -- Trying to allocate 129 129 So basically 100% success for all 10 attempts. Without the patch numbers looked much worse: Trying to allocate 128 12 -- Trying to allocate 129 14 -- Trying to allocate 129 7 -- Trying to allocate 129 16 -- Trying to allocate 129 30 -- Trying to allocate 129 38 -- Trying to allocate 129 19 -- Trying to allocate 129 37 -- Trying to allocate 129 28 -- Trying to allocate 129 37 Just for completness the base kernel without oom detection rework looks as follows: Trying to allocate 127 30 -- Trying to allocate 129 12 -- Trying to allocate 129 52 -- Trying to allocate 128 32 -- Trying to allocate 129 12 -- Trying to allocate 129 10 -- Trying to allocate 129 32 -- Trying to allocate 128 14 -- Trying to allocate 128 16 -- Trying to allocate 129 8 As we can see the success rate is much more volatile and smaller without this patch. So the patch not only makes the retry logic for costly requests more sensible the success rate is even higher. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 63 +++++++++++++++++++++++++++++---------------------------- 1 file changed, 32 insertions(+), 31 deletions(-) commit 33c2d21438daea807947923377995c73ee8ed3fc Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:06 2016 -0700 mm, oom: protect !costly allocations some more should_reclaim_retry will give up retries for higher order allocations if none of the eligible zones has any requested or higher order pages available even if we pass the watermak check for order-0. This is done because there is no guarantee that the reclaimable and currently free pages will form the required order. This can, however, lead to situations where the high-order request (e.g. order-2 required for the stack allocation during fork) will trigger OOM too early - e.g. after the first reclaim/compaction round. Such a system would have to be highly fragmented and there is no guarantee further reclaim/compaction attempts would help but at least make sure that the compaction was active before we go OOM and keep retrying even if should_reclaim_retry tells us to oom if - the last compaction round backed off or - we haven't completed at least MAX_COMPACT_RETRIES active compaction rounds. The first rule ensures that the very last attempt for compaction was not ignored while the second guarantees that the compaction has done some work. Multiple retries might be needed to prevent occasional pigggy backing of other contexts to steal the compacted pages before the current context manages to retry to allocate them. compaction_failed() is taken as a final word from the compaction that the retry doesn't make much sense. We have to be careful though because the first compaction round is MIGRATE_ASYNC which is rather weak as it ignores pages under writeback and gives up too easily in other situations. We therefore have to make sure that MIGRATE_SYNC_LIGHT mode has been used before we give up. With this logic in place we do not have to increase the migration mode unconditionally and rather do it only if the compaction failed for the weaker mode. A nice side effect is that the stronger migration mode is used only when really needed so this has a potential of smaller latencies in some cases. Please note that the compaction doesn't tell us much about how successful it was when returning compaction_made_progress so we just have to blindly trust that another retry is worthwhile and cap the number to something reasonable to guarantee a convergence. If the given number of successful retries is not sufficient for a reasonable workloads we should focus on the collected compaction tracepoints data and try to address the issue in the compaction code. If this is not feasible we can increase the retries limit. [mhocko@suse.com: fix warning] Link: http://lkml.kernel.org/r/20160512061636.GA4200@dhcp22.suse.cz Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 88 ++++++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 78 insertions(+), 10 deletions(-) commit ede37713737834d98ec72ed299a305d53e909f73 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:03 2016 -0700 mm: throttle on IO only when there are too many dirty and writeback pages wait_iff_congested has been used to throttle allocator before it retried another round of direct reclaim to allow the writeback to make some progress and prevent reclaim from looping over dirty/writeback pages without making any progress. We used to do congestion_wait before commit 0e093d99763e ("writeback: do not sleep on the congestion queue if there are no congested BDIs or if significant congestion is not being encountered in the current zone") but that led to undesirable stalls and sleeping for the full timeout even when the BDI wasn't congested. Hence wait_iff_congested was used instead. But it seems that even wait_iff_congested doesn't work as expected. We might have a small file LRU list with all pages dirty/writeback and yet the bdi is not congested so this is just a cond_resched in the end and can end up triggering pre mature OOM. This patch replaces the unconditional wait_iff_congested by congestion_wait which is executed only if we _know_ that the last round of direct reclaim didn't make any progress and dirty+writeback pages are more than a half of the reclaimable pages on the zone which might be usable for our target allocation. This shouldn't reintroduce stalls fixed by 0e093d99763e because congestion_wait is called only when we are getting hopeless when sleeping is a better choice than OOM with many pages under IO. We have to preserve logic introduced by commit 373ccbe59270 ("mm, vmstat: allow WQ concurrency to discover memory reclaim doesn't make any progress") into the __alloc_pages_slowpath now that wait_iff_congested is not used anymore. As the only remaining user of wait_iff_congested is shrink_inactive_list we can remove the WQ specific short sleep from wait_iff_congested because the sleep is needed to be done only once in the allocation retry cycle. [mhocko@suse.com: high_zoneidx->ac_classzone_idx to evaluate memory reserves properly] Link: http://lkml.kernel.org/r/1463051677-29418-2-git-send-email-mhocko@kernel.org Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/backing-dev.c | 20 +++----------------- mm/page_alloc.c | 41 +++++++++++++++++++++++++++++++++++++---- 2 files changed, 40 insertions(+), 21 deletions(-) commit 0a0337e0d1d134465778a16f5cbea95086e8e9e0 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:57:00 2016 -0700 mm, oom: rework oom detection __alloc_pages_slowpath has traditionally relied on the direct reclaim and did_some_progress as an indicator that it makes sense to retry allocation rather than declaring OOM. shrink_zones had to rely on zone_reclaimable if shrink_zone didn't make any progress to prevent from a premature OOM killer invocation - the LRU might be full of dirty or writeback pages and direct reclaim cannot clean those up. zone_reclaimable allows to rescan the reclaimable lists several times and restart if a page is freed. This is really subtle behavior and it might lead to a livelock when a single freed page keeps allocator looping but the current task will not be able to allocate that single page. OOM killer would be more appropriate than looping without any progress for unbounded amount of time. This patch changes OOM detection logic and pulls it out from shrink_zone which is too low to be appropriate for any high level decisions such as OOM which is per zonelist property. It is __alloc_pages_slowpath which knows how many attempts have been done and what was the progress so far therefore it is more appropriate to implement this logic. The new heuristic is implemented in should_reclaim_retry helper called from __alloc_pages_slowpath. It tries to be more deterministic and easier to follow. It builds on an assumption that retrying makes sense only if the currently reclaimable memory + free pages would allow the current allocation request to succeed (as per __zone_watermark_ok) at least for one zone in the usable zonelist. This alone wouldn't be sufficient, though, because the writeback might get stuck and reclaimable pages might be pinned for a really long time or even depend on the current allocation context. Therefore there is a backoff mechanism implemented which reduces the reclaim target after each reclaim round without any progress. This means that we should eventually converge to only NR_FREE_PAGES as the target and fail on the wmark check and proceed to OOM. The backoff is simple and linear with 1/16 of the reclaimable pages for each round without any progress. We are optimistic and reset counter for successful reclaim rounds. Costly high order pages mostly preserve their semantic and those without __GFP_REPEAT fail right away while those which have the flag set will back off after the amount of reclaimable pages reaches equivalent of the requested order. The only difference is that if there was no progress during the reclaim we rely on zone watermark check. This is more logical thing to do than previous 1<<order attempts which were a result of zone_reclaimable faking the progress. [vdavydov@virtuozzo.com: check classzone_idx for shrink_zone] [hannes@cmpxchg.org: separate the heuristic into should_reclaim_retry] [rientjes@google.com: use zone_page_state_snapshot for NR_FREE_PAGES] [rientjes@google.com: shrink_zones doesn't need to return anything] Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/swap.h | 1 + mm/page_alloc.c | 100 ++++++++++++++++++++++++++++++++++++++++++++++----- mm/vmscan.c | 25 +++---------- 3 files changed, 97 insertions(+), 29 deletions(-) commit cab1802b5f0dddea30547a7451fda8c7e4c593f0 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:56 2016 -0700 mm, compaction: abstract compaction feedback to helpers Compaction can provide a wild variation of feedback to the caller. Many of them are implementation specific and the caller of the compaction (especially the page allocator) shouldn't be bound to specifics of the current implementation. This patch abstracts the feedback into three basic types: - compaction_made_progress - compaction was active and made some progress. - compaction_failed - compaction failed and further attempts to invoke it would most probably fail and therefore it is not worth retrying - compaction_withdrawn - compaction wasn't invoked for an implementation specific reasons. In the current implementation it means that the compaction was deferred, contended or the page scanners met too early without any progress. Retrying is still worthwhile. [vbabka@suse.cz: do not change thp back off behavior] [akpm@linux-foundation.org: fix typo in comment, per Hillf] Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 79 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) commit c5d01d0d18e2ab7a21f0371b00e4d1a06f79cdf5 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:53 2016 -0700 mm, compaction: simplify __alloc_pages_direct_compact feedback interface __alloc_pages_direct_compact communicates potential back off by two variables: - deferred_compaction tells that the compaction returned COMPACT_DEFERRED - contended_compaction is set when there is a contention on zone->lock resp. zone->lru_lock locks __alloc_pages_slowpath then backs of for THP allocation requests to prevent from long stalls. This is rather messy and it would be much cleaner to return a single compact result value and hide all the nasty details into __alloc_pages_direct_compact. This patch shouldn't introduce any functional changes. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 67 ++++++++++++++++++++++++++------------------------------- 1 file changed, 31 insertions(+), 36 deletions(-) commit 4f9a358c36fcdad3ea1db263ec4d484a70ad543e Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:50 2016 -0700 mm, compaction: update compaction_result ordering compaction_result will be used as the primary feedback channel for compaction users. At the same time try_to_compact_pages (and potentially others) assume a certain ordering where a more specific feedback takes precendence. This gets a bit awkward when we have conflicting feedback from different zones. E.g one returing COMPACT_COMPLETE meaning the full zone has been scanned without any outcome while other returns with COMPACT_PARTIAL aka made some progress. The caller should get COMPACT_PARTIAL because that means that the compaction still can make some progress. The same applies for COMPACT_PARTIAL vs COMPACT_PARTIAL_SKIPPED. Reorder PARTIAL to be the largest one so the larger the value is the more progress we have done. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) commit c8f7de0bfae36e8532e5e25a39d15407f02aca78 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:47 2016 -0700 mm, compaction: distinguish between full and partial COMPACT_COMPLETE COMPACT_COMPLETE now means that compaction and free scanner met. This is not very useful information if somebody just wants to use this feedback and make any decisions based on that. The current caller might be a poor guy who just happened to scan tiny portion of the zone and that could be the reason no suitable pages were compacted. Make sure we distinguish the full and partial zone walks. Consumers should treat COMPACT_PARTIAL_SKIPPED as a potential success and be optimistic in retrying. The existing users of COMPACT_COMPLETE are conservatively changed to use COMPACT_PARTIAL_SKIPPED as well but some of them should be probably reconsidered and only defer the compaction only for COMPACT_COMPLETE with the new semantic. This patch shouldn't introduce any functional changes. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 10 +++++++++- include/trace/events/compaction.h | 1 + mm/compaction.c | 14 +++++++++++--- mm/internal.h | 1 + 4 files changed, 22 insertions(+), 4 deletions(-) commit 1d4746d395975e0ff5103e20ab169d1a95b4ef9e Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:44 2016 -0700 mm, compaction: distinguish COMPACT_DEFERRED from COMPACT_SKIPPED try_to_compact_pages() can currently return COMPACT_SKIPPED even when the compaction is defered for some zone just because zone DMA is skipped in 99% of cases due to watermark checks. This makes COMPACT_DEFERRED basically unusable for the page allocator as a feedback mechanism. Make sure we distinguish those two states properly and switch their ordering in the enum. This would mean that the COMPACT_SKIPPED will be returned only when all eligible zones are skipped. As a result COMPACT_DEFERRED handling for THP in __alloc_pages_slowpath will be more precise and we would bail out rather than reclaim. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 7 +++++-- include/trace/events/compaction.h | 2 +- mm/compaction.c | 8 +++++--- 3 files changed, 11 insertions(+), 6 deletions(-) commit c46649deae3f00aa8ba8716f0ddb8eef2dc9532f Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:41 2016 -0700 mm, compaction: cover all compaction mode in compact_zone The compiler is complaining after "mm, compaction: change COMPACT_ constants into enum" mm/compaction.c: In function `compact_zone': mm/compaction.c:1350:2: warning: enumeration value `COMPACT_DEFERRED' not handled in switch [-Wswitch] switch (ret) { ^ mm/compaction.c:1350:2: warning: enumeration value `COMPACT_COMPLETE' not handled in switch [-Wswitch] mm/compaction.c:1350:2: warning: enumeration value `COMPACT_NO_SUITABLE_PAGE' not handled in switch [-Wswitch] mm/compaction.c:1350:2: warning: enumeration value `COMPACT_NOT_SUITABLE_ZONE' not handled in switch [-Wswitch] mm/compaction.c:1350:2: warning: enumeration value `COMPACT_CONTENDED' not handled in switch [-Wswitch] compaction_suitable is allowed to return only COMPACT_PARTIAL, COMPACT_SKIPPED and COMPACT_CONTINUE so other cases are simply impossible. Put a VM_BUG_ON to catch an impossible return value. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/compaction.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit ea7ab982b6bdb7ce218fd3a7850bb2e2b414fdd0 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:38 2016 -0700 mm, compaction: change COMPACT_ constants into enum Compaction code is doing weird dances between COMPACT_FOO -> int -> unsigned long But there doesn't seem to be any reason for that. All functions which return/use one of those constants are not expecting any other value so it really makes sense to define an enum for them and make it clear that no other values are expected. This is a pure cleanup and shouldn't introduce any functional changes. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 45 +++++++++++++++++++++++++++------------------ mm/compaction.c | 27 ++++++++++++++------------- mm/page_alloc.c | 2 +- 3 files changed, 42 insertions(+), 32 deletions(-) commit b6459cc154e804f0de0d61fa023c4946b742cc96 Author: Michal Hocko <mhocko@suse.com> Date: Fri May 20 16:56:34 2016 -0700 vmscan: consider classzone_idx in compaction_ready Motivation: As pointed out by Linus [2][3] relying on zone_reclaimable as a way to communicate the reclaim progress is rater dubious. I tend to agree, not only it is really obscure, it is not hard to imagine cases where a single page freed in the loop keeps all the reclaimers looping without getting any progress because their gfp_mask wouldn't allow to get that page anyway (e.g. single GFP_ATOMIC alloc and free loop). This is rather rare so it doesn't happen in the practice but the current logic which we have is rather obscure and hard to follow a also non-deterministic. This is an attempt to make the OOM detection more deterministic and easier to follow because each reclaimer basically tracks its own progress which is implemented at the page allocator layer rather spread out between the allocator and the reclaim. The more on the implementation is described in the first patch. I have tested several different scenarios but it should be clear that testing OOM killer is quite hard to be representative. There is usually a tiny gap between almost OOM and full blown OOM which is often time sensitive. Anyway, I have tested the following 2 scenarios and I would appreciate if there are more to test. Testing environment: a virtual machine with 2G of RAM and 2CPUs without any swap to make the OOM more deterministic. 1) 2 writers (each doing dd with 4M blocks to an xfs partition with 1G file size, removes the files and starts over again) running in parallel for 10s to build up a lot of dirty pages when 100 parallel mem_eaters (anon private populated mmap which waits until it gets signal) with 80M each. This causes an OOM flood of course and I have compared both patched and unpatched kernels. The test is considered finished after there are no OOM conditions detected. This should tell us whether there are any excessive kills or some of them premature (e.g. due to dirty pages): I have performed two runs this time each after a fresh boot. * base kernel $ grep "Out of memory:" base-oom-run1.log | wc -l 78 $ grep "Out of memory:" base-oom-run2.log | wc -l 78 $ grep "Kill process" base-oom-run1.log | tail -n1 [ 91.391203] Out of memory: Kill process 3061 (mem_eater) score 39 or sacrifice child $ grep "Kill process" base-oom-run2.log | tail -n1 [ 82.141919] Out of memory: Kill process 3086 (mem_eater) score 39 or sacrifice child $ grep "DMA32 free:" base-oom-run1.log | sed 's@.*free:\([0-9]*\)kB.*@\1@' | calc_min_max.awk min: 5376.00 max: 6776.00 avg: 5530.75 std: 166.50 nr: 61 $ grep "DMA32 free:" base-oom-run2.log | sed 's@.*free:\([0-9]*\)kB.*@\1@' | calc_min_max.awk min: 5416.00 max: 5608.00 avg: 5514.15 std: 42.94 nr: 52 $ grep "DMA32.*all_unreclaimable? no" base-oom-run1.log | wc -l 1 $ grep "DMA32.*all_unreclaimable? no" base-oom-run2.log | wc -l 3 * patched kernel $ grep "Out of memory:" patched-oom-run1.log | wc -l 78 miso@tiehlicka /mnt/share/devel/miso/kvm $ grep "Out of memory:" patched-oom-run2.log | wc -l 77 e grep "Kill process" patched-oom-run1.log | tail -n1 [ 497.317732] Out of memory: Kill process 3108 (mem_eater) score 39 or sacrifice child $ grep "Kill process" patched-oom-run2.log | tail -n1 [ 316.169920] Out of memory: Kill process 3093 (mem_eater) score 39 or sacrifice child $ grep "DMA32 free:" patched-oom-run1.log | sed 's@.*free:\([0-9]*\)kB.*@\1@' | calc_min_max.awk min: 5420.00 max: 5808.00 avg: 5513.90 std: 60.45 nr: 78 $ grep "DMA32 free:" patched-oom-run2.log | sed 's@.*free:\([0-9]*\)kB.*@\1@' | calc_min_max.awk min: 5380.00 max: 6384.00 avg: 5520.94 std: 136.84 nr: 77 e grep "DMA32.*all_unreclaimable? no" patched-oom-run1.log | wc -l 2 $ grep "DMA32.*all_unreclaimable? no" patched-oom-run2.log | wc -l 3 The patched kernel run noticeably longer while invoking OOM killer same number of times. This means that the original implementation is much more aggressive and triggers the OOM killer sooner. free pages stats show that neither kernels went OOM too early most of the time, though. I guess the difference is in the backoff when retries without any progress do sleep for a while if there is memory under writeback or dirty which is highly likely considering the parallel IO. Both kernels have seen races where zone wasn't marked unreclaimable and we still hit the OOM killer. This is most likely a race where a task managed to exit between the last allocation attempt and the oom killer invocation. 2) 2 writers again with 10s of run and then 10 mem_eaters to consume as much memory as possible without triggering the OOM killer. This required a lot of tuning but I've considered 3 consecutive runs in three different boots without OOM as a success. * base kernel size=$(awk '/MemFree/{printf "%dK", ($2/10)-(16*1024)}' /proc/meminfo) * patched kernel size=$(awk '/MemFree/{printf "%dK", ($2/10)-(12*1024)}' /proc/meminfo) That means 40M more memory was usable without triggering OOM killer. The base kernel sometimes managed to handle the same as patched but it wasn't consistent and failed in at least on of the 3 runs. This seems like a minor improvement. I was testing also GPF_REPEAT costly requests (hughetlb) with fragmented memory and under memory pressure. The results are in patch 11 where the logic is implemented. In short I can see huge improvement there. I am certainly interested in other usecases as well as well as any feedback. Especially those which require higher order requests. This patch (of 14): While playing with the oom detection rework [1] I have noticed that my heavy order-9 (hugetlb) load close to OOM ended up in an endless loop where the reclaim hasn't made any progress but did_some_progress didn't reflect that and compaction_suitable was backing off because no zone is above low wmark + 1 << order. It turned out that this is in fact an old standing bug in compaction_ready which ignores the requested_highidx and did the watermark check for 0 classzone_idx. This succeeds for zone DMA most of the time as the zone is mostly unused because of lowmem protection. As a result costly high order allocatios always report a successfull progress even when there was none. This wasn't a problem so far because these allocations usually fail quite early or retry only few times with __GFP_REPEAT but this will change after later patch in this series so make sure to not lie about the progress and propagate requested_highidx down to compaction_ready and use it for both the watermak check and compaction_suitable to fix this issue. [1] http://lkml.kernel.org/r/1459855533-4600-1-git-send-email-mhocko@kernel.org [2] https://lkml.org/lkml/2015/10/12/808 [3] https://lkml.org/lkml/2015/10/13/597 Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: David Rientjes <rientjes@google.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Joonsoo Kim <js1304@gmail.com> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmscan.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 59dc76b0d4dfdd7dc46a1010e4afb44f60f3e97f Author: Rik van Riel <riel@redhat.com> Date: Fri May 20 16:56:31 2016 -0700 mm: vmscan: reduce size of inactive file list The inactive file list should still be large enough to contain readahead windows and freshly written file data, but it no longer is the only source for detecting multiple accesses to file pages. The workingset refault measurement code causes recently evicted file pages that get accessed again after a shorter interval to be promoted directly to the active list. With that mechanism in place, we can afford to (on a larger system) dedicate more memory to the active file list, so we can actually cache more of the frequently used file pages in memory, and not have them pushed out by streaming writes, once-used streaming file reads, etc. This can help things like database workloads, where only half the page cache can currently be used to cache the database working set. This patch automatically increases that fraction on larger systems, using the same ratio that has already been used for anonymous memory. [hannes@cmpxchg.org: cgroup-awareness] Signed-off-by: Rik van Riel <riel@redhat.com> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Reported-by: Andres Freund <andres@anarazel.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/memcontrol.h | 25 ----------- mm/page_alloc.c | 44 ------------------- mm/vmscan.c | 104 ++++++++++++++++++--------------------------- 3 files changed, 42 insertions(+), 131 deletions(-) commit bbddabe2e436aa7869b3ac5248df5c14ddde0cbf Author: Johannes Weiner <hannes@cmpxchg.org> Date: Fri May 20 16:56:28 2016 -0700 mm: filemap: only do access activations on reads Andres observed that his database workload is struggling with the transaction journal creating pressure on frequently read pages. Access patterns like transaction journals frequently write the same pages over and over, but in the majority of cases those pages are never read back. There are no caching benefits to be had for those pages, so activating them and having them put pressure on pages that do benefit from caching is a bad choice. Leave page activations to read accesses and don't promote pages based on writes alone. It could be said that partially written pages do contain cache-worthy data, because even if *userspace* does not access the unwritten part, the kernel still has to read it from the filesystem for correctness. However, a counter argument is that these pages enjoy at least *some* protection over other inactive file pages through the writeback cache, in the sense that dirty pages are written back with a delay and cache reclaim leaves them alone until they have been written back to disk. Should that turn out to be insufficient and we see increased read IO from partial writes under memory pressure, we can always go back and update grab_cache_page_write_begin() to take (pos, len) so that it can tell partial writes from pages that don't need partial reads. But for now, keep it simple. Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Reported-by: Andres Freund <andres@anarazel.de> Cc: Rik van Riel <riel@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/filemap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f0281a00fe80f0e689dd51e68c3aed5f6ef1bf58 Author: Rik van Riel <riel@redhat.com> Date: Fri May 20 16:56:25 2016 -0700 mm: workingset: only do workingset activations on reads This is a follow-up to http://www.spinics.net/lists/linux-mm/msg101739.html where Andres reported his database workingset being pushed out by the minimum size enforcement of the inactive file list - currently 50% of cache - as well as repeatedly written file pages that are never actually read. Two changes fell out of the discussions. The first change observes that pages that are only ever written don't benefit from caching beyond what the writeback cache does for partial page writes, and so we shouldn't promote them to the active file list where they compete with pages whose cached data is actually accessed repeatedly. This change comes in two patches - one for in-cache write accesses and one for refaults triggered by writes, neither of which should promote a cache page. Second, with the refault detection we don't need to set 50% of the cache aside for used-once cache anymore since we can detect frequently used pages even when they are evicted between accesses. We can allow the active list to be bigger and thus protect a bigger workingset that isn't challenged by streamers. Depending on the access patterns, this can increase major faults during workingset transitions for better performance during stable phases. This patch (of 3): When rewriting a page, the data in that page is replaced with new data. This means that evicting something else from the active file list, in order to cache data that will be replaced by something else, is likely to be a waste of memory. It is better to save the active list for frequently read pages, because reads actually use the data that is in the page. This patch ignores partial writes, because it is unclear whether the complexity of identifying those is worth any potential performance gain obtained from better caching pages that see repeated partial writes at large enough intervals to not get caught by the use-twice promotion code used for the inactive file list. Signed-off-by: Rik van Riel <riel@redhat.com> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Reported-by: Andres Freund <andres@anarazel.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/filemap.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 20c698d7791420fb242a0d49b80790fb2d951ace Merge: 33656a1 6b1cabe Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 17:55:51 2016 -0700 Merge branch 'sparc32-cosmetic-changes' Sam Ravnborg says: ==================== sparc32: kgdb_32 and STRICT_MM_TYPECHECKS updates A few cosmetic pathes for sparc32 follows. I noticed some inconsistency in kgdb_32 that triggered a few patches. The inconsistency in kgdb_32 turned out to have no functional impact. But I anyway fixed it so kgdb_32 and kgdb_64 became just a tiny bit more alike. The STRICT_MM_TYPECHECKS patch was triggered by a discussion on linux-arch where Arnd considered removing this cruft. The resulting benary of srmmu.c (I checked an assembler file) was _smaller_ when I defined STRICT_MM_TYPECHECKS. But due to lack of testing I left it undefined. With the build errors fixed it should be trivial to try out if defining STRICT_MM_TYPECHECKS breaks anything. Any takers? As I miss any working sparc32 gear for the moment this has only been build tested - so please consider if it is worth taking the risk to apply the patches. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 6b1cabe8992441afb542503781f11b9cce91e285 Author: Sam Ravnborg <sam@ravnborg.org> Date: Fri Apr 22 19:41:07 2016 +0200 sparc32: drop superfluous cast in calls to __nocache_pa() Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/include/asm/pgalloc_32.h | 2 +- arch/sparc/mm/srmmu.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 6e6e41879e07daccb967bc75a31f29689354d11b Author: Sam Ravnborg <sam@ravnborg.org> Date: Fri Apr 22 19:41:06 2016 +0200 sparc32: fix build with STRICT_MM_TYPECHECKS Based on recent thread on linux-arch (some weeks ago) I decided to check how much work was required to build sparc32 with STRICT_MM_TYPECHECKS enabled. The resulting binary (checked srmmu.o) was to my suprise smaller with STRICT_MM_TYPECHECKS defined, than without. As I have no working gear to test sparc32 bits at for the moment, I did not enable STRICT_MM_TYPECHECKS - but was tempeted to do so. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/include/asm/page_32.h | 2 -- arch/sparc/include/asm/pgalloc_32.h | 2 +- arch/sparc/include/asm/pgtable_32.h | 2 +- arch/sparc/mm/io-unit.c | 4 ++-- arch/sparc/mm/srmmu.c | 15 ++++++++++----- 5 files changed, 14 insertions(+), 11 deletions(-) commit 3c46e2d61cfc389dc6e000489fcfcaea805710e0 Author: Sam Ravnborg <sam@ravnborg.org> Date: Fri Apr 22 19:41:05 2016 +0200 sparc32: use proper prototype for trapbase This killed an extern ... in a .c file. No functional change. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/kernel/kernel.h | 1 + arch/sparc/kernel/kgdb_32.c | 3 +-- arch/sparc/kernel/setup_32.c | 4 +--- 3 files changed, 3 insertions(+), 5 deletions(-) commit 06fc7b5008d7f0be2912b830725035616756d183 Author: Sam Ravnborg <sam@ravnborg.org> Date: Fri Apr 22 19:41:04 2016 +0200 sparc32: drop local prototype in kgdb_32 Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/kernel/kgdb_32.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d097efa95059e6a36a365add3deaf43fcafc4067 Author: Sam Ravnborg <sam@ravnborg.org> Date: Fri Apr 22 19:41:03 2016 +0200 sparc32: drop hardcoding trap_level in kgdb_trap Fix this so we pass the trap_level from the actual trap code like we do in sparc64. Add use on ENTRY(), ENDPROC() in the assembler function too. This fixes a bug where the hardcoded value for trap_level was the sparc64 value. As the generic code does not use the trap_level argument (for sparc32) - this patch does not have any functional impact. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/sparc/include/asm/head_32.h | 8 ++++---- arch/sparc/include/asm/kgdb.h | 2 +- arch/sparc/kernel/entry.S | 10 ++++------ arch/sparc/kernel/kgdb_32.c | 6 +++--- 4 files changed, 12 insertions(+), 14 deletions(-) commit 95829b3a9c0b1d88778b23bc2afdf5a83de066ff Author: Neil Horman <nhorman@tuxdriver.com> Date: Thu May 19 11:30:54 2016 -0400 net: suppress warnings on dev_alloc_skb Noticed an allocation failure in a network driver the other day on a 32 bit system: DMA-API: debugging out of memory - disabling bnx2fc: adapter_lookup: hba NULL lldpad: page allocation failure. order:0, mode:0x4120 Pid: 4556, comm: lldpad Not tainted 2.6.32-639.el6.i686.debug #1 Call Trace: [<c08a4086>] ? printk+0x19/0x23 [<c05166a4>] ? __alloc_pages_nodemask+0x664/0x830 [<c0649d02>] ? free_object+0x82/0xa0 [<fb4e2c9b>] ? ixgbe_alloc_rx_buffers+0x10b/0x1d0 [ixgbe] [<fb4e2fff>] ? ixgbe_configure_rx_ring+0x29f/0x420 [ixgbe] [<fb4e228c>] ? ixgbe_configure_tx_ring+0x15c/0x220 [ixgbe] [<fb4e3709>] ? ixgbe_configure+0x589/0xc00 [ixgbe] [<fb4e7be7>] ? ixgbe_open+0xa7/0x5c0 [ixgbe] [<fb503ce6>] ? ixgbe_init_interrupt_scheme+0x5b6/0x970 [ixgbe] [<fb4e8e54>] ? ixgbe_setup_tc+0x1a4/0x260 [ixgbe] [<fb505a9f>] ? ixgbe_dcbnl_set_state+0x7f/0x90 [ixgbe] [<c088d80d>] ? dcb_doit+0x10ed/0x16d0 ... Thought that perhaps the big splat in the logs wasn't really necessecary, as all call sites for dev_alloc_skb: a) check the return code for the function and b) either print their own error message or have a recovery path that makes the warning moot. Fix it by modifying dev_alloc_pages to pass __GFP_NOWARN as a gfp flag to suppress the warning applies to the net tree Signed-off-by: Neil Horman <nhorman@tuxdriver.com> CC: "David S. Miller" <davem@davemloft.net> CC: Eric Dumazet <eric.dumazet@gmail.com> CC: Alexander Duyck <alexander.duyck@gmail.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/skbuff.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f0a3fdca794d1e68ae284ef4caefe681f7c18e89 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Thu May 19 17:26:29 2016 +0200 uapi glibc compat: fix compilation when !__USE_MISC in glibc These structures are defined only if __USE_MISC is set in glibc net/if.h headers, ie when _BSD_SOURCE or _SVID_SOURCE are defined. CC: Jan Engelhardt <jengelh@inai.de> CC: Josh Boyer <jwboyer@fedoraproject.org> CC: Stephen Hemminger <shemming@brocade.com> CC: Waldemar Brodkorb <mail@waldemar-brodkorb.de> CC: Gabriel Laskar <gabriel@lse.epita.fr> CC: Mikko Rapeli <mikko.rapeli@iki.fi> Fixes: 4a91cb61bb99 ("uapi glibc compat: fix compile errors when glibc net/if.h included before linux/if.h") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/libc-compat.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e5aed006be918af163eb397e45aa5ea6cefd5e01 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Thu May 19 15:58:33 2016 +0200 udp: prevent skbs lingering in tunnel socket queues In case we find a socket with encapsulation enabled we should call the encap_recv function even if just a udp header without payload is available. The callbacks are responsible for correctly verifying and dropping the packets. Also, in case the header validation fails for geneve and vxlan we shouldn't put the skb back into the socket queue, no one will pick them up there. Instead we can simply discard them in the respective encap_recv functions. Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/geneve.c | 10 +++------- drivers/net/vxlan.c | 4 ++-- net/ipv4/udp.c | 2 +- net/ipv6/udp.c | 2 +- 4 files changed, 7 insertions(+), 11 deletions(-) commit cb543e80f43b2db9d3adcc80d522b27829e60d82 Merge: 238a958 1b9b69e Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 19:53:09 2016 -0400 Merge branch 'bpf-verifier-fixes' Alexei Starovoitov says: ==================== bpf: verifier fixes Further testing of 'direct packet access' uncovered several usability issues. Fix them. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 1b9b69ecb3a5236d4d3da0f0fa11af916371841e Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 19 18:17:14 2016 -0700 bpf: teach verifier to recognize imm += ptr pattern Humans don't write C code like: u8 *ptr = skb->data; int imm = 4; imm += ptr; but from llvm backend point of view 'imm' and 'ptr' are registers and imm += ptr may be preferred vs ptr += imm depending which register value will be used further in the code, while verifier can only recognize ptr += imm. That caused small unrelated changes in the C code of the bpf program to trigger rejection by the verifier. Therefore teach the verifier to recognize both ptr += imm and imm += ptr. For example: when R6=pkt(id=0,off=0,r=62) R7=imm22 after r7 += r6 instruction will be R6=pkt(id=0,off=0,r=62) R7=pkt(id=0,off=22,r=62) Fixes: 969bf05eb3ce ("bpf: direct packet access") Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit d91b28ed42de99217efb2e8cb0357263d6fb737c Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 19 18:17:13 2016 -0700 bpf: support decreasing order in direct packet access when packet headers are accessed in 'decreasing' order (like TCP port may be fetched before the program reads IP src) the llvm may generate the following code: [...] // R7=pkt(id=0,off=22,r=70) r2 = *(u32 *)(r7 +0) // good access [...] r7 += 40 // R7=pkt(id=0,off=62,r=70) r8 = *(u32 *)(r7 +0) // good access [...] r1 = *(u32 *)(r7 -20) // this one will fail though it's within a safe range // it's doing *(u32*)(skb->data + 42) Fix verifier to recognize such code pattern Alos turned out that 'off > range' condition is not a verifier bug. It's a buggy program that may do something like: if (ptr + 50 > data_end) return 0; ptr += 60; *(u32*)ptr; in such case emit "invalid access to packet, off=0 size=4, R1(id=0,off=60,r=50)" error message, so all information is available for the program author to fix the program. Fixes: 969bf05eb3ce ("bpf: direct packet access") Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 238a9584e9e2c7b3ea23924e9183fee05d584789 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 19:26:50 2016 +0530 net: usb: ch9200: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/ch9200.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 5877debe27917dfd7aa8f960c228dbbc1de8282f Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 19:24:41 2016 +0530 ps3_gelic: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/toshiba/ps3_gelic_wireless.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7c542772cc5ff061ec3d06658f5d36304bcd5395 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 19:22:49 2016 +0530 net:liquidio: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cavium/liquidio/octeon_device.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit e27f4a942a0ee4b84567a3c6cfa84f273e55cbb7 Author: Eric W. Biederman <ebiederm@xmission.com> Date: Fri May 20 17:22:48 2016 -0500 bpf: Use mount_nodev not mount_ns to mount the bpf filesystem While reviewing the filesystems that set FS_USERNS_MOUNT I spotted the bpf filesystem. Looking at the code I saw a broken usage of mount_ns with current->nsproxy->mnt_ns. As the code does not acquire a reference to the mount namespace it can not possibly be correct to store the mount namespace on the superblock as it does. Replace mount_ns with mount_nodev so that each mount of the bpf filesystem returns a distinct instance, and the code is not buggy. In discussion with Hannes Frederic Sowa it was reported that the use of mount_ns was an attempt to have one bpf instance per mount namespace, in an attempt to keep resources that pin resources from hiding. That intent simply does not work, the vfs is not built to allow that kind of behavior. Which means that the bpf filesystem really is buggy both semantically and in it's implemenation as it does not nor can it implement the original intent. This change is userspace visible, but my experience with similar filesystems leads me to believe nothing will break with a model of each mount of the bpf filesystem is distinct from all others. Fixes: b2197755b263 ("bpf: add support for persistent maps/progs") Cc: Hannes Frederic Sowa <hannes@stressinduktion.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 56025caa821d8e398b7cff2c45fb1e3e769549d7 Merge: 05a5648 52776a7 Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 19:40:35 2016 -0400 Merge tag 'wireless-drivers-next-for-davem-2016-05-13' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== wireless-drivers patches for 4.7 Major changes: iwlwifi * remove IWLWIFI_DEBUG_EXPERIMENTAL_UCODE kconfig option * work for RX multiqueue continues * dynamic queue allocation work continues * add Luca as maintainer * a bunch of fixes and improvements all over brcmfmac * add 4356 sdio support ath6kl * add ability to set debug uart baud rate with a module parameter wil6210 * add debugfs file to configure firmware led functionality ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 05a56487174d33fff5986f13c0c8e4b32f046da9 Author: Rafal Redzimski <rafal.f.redzimski@intel.com> Date: Thu May 19 11:56:09 2016 +0200 net: cdc_ncm: update datagram size after changing mtu Current implementation updates the mtu size and notify cdc_ncm device using USB_CDC_SET_MAX_DATAGRAM_SIZE request about datagram size change instead of changing rx_urb_size. Whenever mtu is being changed, datagram size should also be updated. Also updating maxmtu formula so it takes max_datagram_size with use of cdc_ncm_max_dgram_size() and not ctx. Signed-off-by: Robert Dobrowolski <robert.dobrowolski@linux.intel.com> Signed-off-by: Rafal Redzimski <rafal.f.redzimski@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/cdc_ncm.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit addf8fc4acb1cf79492ac64966f07178793cb3d7 Author: Jason Wang <jasowang@redhat.com> Date: Thu May 19 13:36:51 2016 +0800 tuntap: correctly wake up process during uninit We used to check dev->reg_state against NETREG_REGISTERED after each time we are woke up. But after commit 9e641bdcfa4e ("net-tun: restructure tun_do_read for better sleep/wakeup efficiency"), it uses skb_recv_datagram() which does not check dev->reg_state. This will result if we delete a tun/tap device after a process is blocked in the reading. The device will wait for the reference count which was held by that process for ever. Fixes this by using RCV_SHUTDOWN which will be checked during sk_recv_datagram() before trying to wake up the process during uninit. Fixes: 9e641bdcfa4e ("net-tun: restructure tun_do_read for better sleep/wakeup efficiency") Cc: Eric Dumazet <edumazet@google.com> Cc: Xi Wang <xii@google.com> Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7fd3c56d60e9919be6b1ef70524eeb28f140653b Merge: 9a0351d bf2d1df Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 19:25:58 2016 -0400 Merge branch 'GREoIPV6-followups' Alexander Duyck says: ==================== Follow-ups for GUEoIPv6 patches This patch series is meant to be applied after: [PATCH v7 net-next 00/16] ipv6: Enable GUEoIPv6 and more fixes for v6 tunneling The first patch addresses an issue we already resolved in the GREv4 and is now present in GREv6 with the introduction of FOU/GUE for IPv6 based GRE tunnels. The second patch goes through and enables IPv6 tunnel offloads for the Intel NICs that already support the IPv4 based IP-in-IP tunnel offloads. I have only done a bit of touch testing but have seen ~20 Gb/s over an i40e interface using a v4-in-v6 tunnel, and I have verified IPv6 GRE is still passing traffic at around the same rate. I plan to do further testing but with these patches present it should enable a wider audience to be able to test the new features introduced in Tom's patchset with hardware offloads. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bf2d1df395028519f7a435ccde02820d16ec27a7 Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed May 18 10:44:53 2016 -0700 intel: Add support for IPv6 IP-in-IP offload This patch adds support for offloading IPXIP6 type packets that represent either IPv4 or IPv6 encapsulated inside of an IPv6 outer IP header. In addition with this change we should also be able to support FOU encapsulated traffic with outer IPv6 headers. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + drivers/net/ethernet/intel/i40e/i40e_txrx.c | 1 + drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 1 + drivers/net/ethernet/intel/i40evf/i40evf_main.c | 1 + drivers/net/ethernet/intel/igb/igb_main.c | 1 + drivers/net/ethernet/intel/igbvf/netdev.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 1 + drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 1 + 8 files changed, 8 insertions(+) commit 6a5536810180bb2c739df890a36cfa29da1914eb Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed May 18 10:44:47 2016 -0700 ip6_gre: Do not allow segmentation offloads GRE_CSUM is enabled with FOU/GUE This patch addresses the same issue we had for IPv4 where enabling GRE with an inner checksum cannot be supported with FOU/GUE due to the fact that they will jump past the GRE header at it is treated like a tunnel header. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit 5dfa0c73953360e07a47731e412d33dfc896bf4e Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu May 19 09:11:52 2016 +0100 ACPI / battery: Correctly serialise with the pending async probe async_synchronize_cookie() only serialises all tasks up to the specified cookie, and importantly does not wait for the task corresponding with the cookie. [This is so that it can be trivially used from inside the async_func_t in order to serialise with all preceding tasks.] In order to serialise with acpi_battery_init_async() we need to compensate and pass in the next cookie instead. The impact today is zero since performing an async_schedule() from inside a module init function will trigger an async_synchronize_full() prior to the module loader's completion. However, if the probe was moved to its own unregistered async_domain, then the async_synchronize_cookie would be replaced with an async_synchronize_full_domain. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/battery.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9a0351dfca14b44443a98c0cafe4de234d1ba469 Merge: fc64869 c948bb5 Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 19:20:12 2016 -0400 Merge branch 'rds-conn-spamming' Sowmini Varadhan says: ==================== RDS: TCP: connection spamming fixes We have been testing the RDS-TCP code with a connection spammer that sends incoming SYNs to the RDS listen port well after an rds-tcp connection has been established, and found a few race-windows that are fixed by this patch series. Patch 1 avoids a null pointer deref when an incoming SYN shows up when a netns is being dismantled, or when the rds-tcp module is being unloaded. Patch 2 addresses the case when a SYN is received after the connection arbitration algorithm has converged: the incoming SYN should not needlessly quiesce the transmit path, and it should not result in needless TCP connection resets due to re-execution of the connection arbitration logic. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c948bb5c2cc4d63f9d76fc02baf5a8331e3cd27f Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Wed May 18 10:06:24 2016 -0700 RDS: TCP: Avoid rds connection churn from rogue SYNs When a rogue SYN is received after the connection arbitration algorithm has converged, the incoming SYN should not needlessly quiesce the transmit path, and it should not result in needless TCP connection resets due to re-execution of the connection arbitration logic. Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rds/tcp_listen.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 37e14f4fe2991f6089a9c8a3830e3ab634ec7190 Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Wed May 18 10:06:23 2016 -0700 RDS: TCP: rds_tcp_accept_worker() must exit gracefully when terminating rds-tcp There are two instances where we want to terminate RDS-TCP: when exiting the netns or during module unload. In either case, the termination sequence is to stop the listen socket, mark the rtn->rds_tcp_listen_sock as null, and flush any accept workqs. Thus any workqs that get flushed at this point will encounter a null rds_tcp_listen_sock, and must exit gracefully to allow the RDS-TCP termination to complete successfully. Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rds/tcp_listen.c | 3 +++ 1 file changed, 3 insertions(+) commit be1332c0994fbf016fa4ef0f0c4acda566fe6cb3 Merge: e7f44b6 68cd4ce Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 15:11:26 2016 -0700 Merge tag 'gfs2-4.7.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2 Pull GFS2 updates from Bob Peterson: "We've got nine patches this time: - Abhi Das has two patches that fix a GFS2 splice issue (and an adjustment). - Ben Marzinski has a patch which allows the proper unmount of a GFS2 file system after hitting a withdraw error. - I have a patch to fix a problem where GFS2 would dereference an error value, plus three cosmetic / refactoring patches. - Daniel DeFreez has a patch to fix two glock reference count problems, where GFS2 was not properly "uninitializing" its glock holder on error paths. - Denys Vlasenko has a patch to change a function to not be inlined, thus reducing the memory footprint of the GFS2 module" * tag 'gfs2-4.7.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2: GFS2: Refactor gfs2_remove_from_journal GFS2: Remove allocation parms from gfs2_rbm_find gfs2: use inode_lock/unlock instead of accessing i_mutex directly GFS2: Add calls to gfs2_holder_uninit in two error handlers GFS2: Don't dereference inode in gfs2_inode_lookup until it's valid GFS2: fs/gfs2/glock.c: Deinline do_error, save 1856 bytes gfs2: Use gfs2 wrapper to sync inode before calling generic_file_splice_read() GFS2: Get rid of dead code in inode_go_demote_ok GFS2: ignore unlock failures after withdraw commit fc64869c48494a401b1fb627c9ecc4e6c1d74b0d Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Wed May 18 19:19:27 2016 +0300 net: sock: move ->sk_shutdown out of bitfields. ->sk_shutdown bits share one bitfield with some other bits in sock struct, such as ->sk_no_check_[r,t]x, ->sk_userlocks ... sock_setsockopt() may write to these bits, while holding the socket lock. In case of AF_UNIX sockets, we change ->sk_shutdown bits while holding only unix_state_lock(). So concurrent setsockopt() and shutdown() may lead to corrupting these bits. Fix this by moving ->sk_shutdown bits out of bitfield into a separate byte. This will not change the 'struct sock' size since ->sk_shutdown moved into previously unused 16-bit hole. Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Suggested-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 911f6b1f57c48c9f379e6658e2e5198d84acdab3 Merge: 9483501 3ee93ea Author: David S. Miller <davem@davemloft.net> Date: Fri May 20 18:03:26 2016 -0400 Merge branch 'GREoIPV6' Tom Herbert says: ==================== ipv6: Enable GUEoIPv6 and more fixes for v6 tunneling This patch set: - Fixes GRE6 to process translate flags correctly from configuration - Adds support for GSO and GRO for ip6ip6 and ip4ip6 - Add support for FOU and GUE in IPv6 - Support GRE, ip6ip6 and ip4ip6 over FOU/GUE - Fixes ip6_input to deal with UDP encapsulations - Some other minor fixes v2: - Removed a check of GSO types in MPLS - Define GSO type SKB_GSO_IPXIP6 and SKB_GSO_IPXIP4 (based on input from Alexander) - Don't define GSO types specifically for IP6IP6 and IP4IP6, above fix makes that unnecessary - Don't bother clearing encapsulation flag in UDP tunnel segment (another item suggested by Alexander). v3: - Address some minor comments from Alexander v4: - Rebase on changes to fix IP TX tunnels - Fix MTU issues in ip4ip6, ip6ip6 - Add test data for above v5: - Address feedback from Shmulik Ladkani regarding extension header code that does not return next header but in instead relies on returning value via nhoff. Solution here is to fix EH processing to return nexthdr value. - Refactored IPv4 encaps so that we won't need to create a ip6_tunnel_core.c when adding encap support IPv6. v6: - Fix build issues with regard to new GSO constants - FIx MTU calculation issues ip6_tunnel.c pointed out byt ALex - Add encap_hlen into headroom for GREv6 to work with FOU/GUE v7: - Added skb_set_inner_ipproto to ip4ip6 and ip6ip6 - Clarified max_headroom in ip6_tnl_xmit - Set features for IPv6 tunnels - Other cleanup suggested by Alexander - Above fixes throughput performance issues in ip4ip6 and ip6ip6, updated test results to reflect that Tested: Various cases of IP tunnels with netperf TCP_STREAM and TCP_RR. - IPv4/GRE/GUE/IPv6 with RCO 1 TCP_STREAM 6616 Mbps 200 TCP_RR 1244043 tps 141/243/446 90/95/99% latencies 86.61% CPU utilization - IPv6/GRE/GUE/IPv6 with RCO 1 TCP_STREAM 6940 Mbps 200 TCP_RR 1270903 tps 138/236/440 90/95/99% latencies 87.51% CPU utilization - IP6IP6 1 TCP_STREAM 5307 Mbps 200 TCP_RR 498981 tps 388/498/631 90/95/99% latencies 19.75% CPU utilization (1 CPU saturated) - IP6IP6/GUE with RCO 1 TCP_STREAM 5575 Mbps 200 TCP_RR 1233818 tps 143/244/451 90/95/99% latencies 87.57 CPU utilization - IP4IP6 1 TCP_STREAM 5235 Mbps 200 TCP_RR 763774 tps 250/318/466 90/95/99% latencies 35.25% CPU utilization (1 CPU saturated) - IP4IP6/GUE with RCO 1 TCP_STREAM 5337 Mbps 200 TCP_RR 1196385 tps 148/251/460 90/95/99% latencies 87.56 CPU utilization - GRE with keyid 200 TCP_RR 744173 tps 258/332/461 90/95/99% latencies 34.59% CPU utilization (1 CPU saturated) ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3ee93eaf2bbfbe0083f71a18a265d48adbd5bb27 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:24 2016 -0700 ipv6: Don't reset inner headers in ip6_tnl_xmit Since iptunnel_handle_offloads() is called in all paths we can probably drop the block in ip6_tnl_xmit that was checking for skb->encapsulation and resetting the inner headers. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_tunnel.c | 5 ----- 1 file changed, 5 deletions(-) commit b8921ca83eed2496108ee308e9a41c5084089680 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:23 2016 -0700 ip4ip6: Support for GSO/GRO Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/inet_common.h | 5 +++++ net/ipv4/af_inet.c | 12 +++++++----- net/ipv6/ip6_offload.c | 33 ++++++++++++++++++++++++++++++++- net/ipv6/ip6_tunnel.c | 5 +++++ 4 files changed, 49 insertions(+), 6 deletions(-) commit 815d22e55b0eba3bfb8f0ba532ce9ae364fee556 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:22 2016 -0700 ip6ip6: Support for GSO/GRO Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_offload.c | 24 +++++++++++++++++++++--- net/ipv6/ip6_tunnel.c | 5 +++++ 2 files changed, 26 insertions(+), 3 deletions(-) commit 51c052d4f5871554377278762065450b4e64f6d1 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:21 2016 -0700 ipv6: Set features for IPv6 tunnels Need to set dev features, use same values that are used in GREv6. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_tunnel.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit b3a27b519b22d4bf03788f6826190d4c5a130b3c Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:20 2016 -0700 ip6_tunnel: Add support for fou/gue encapsulation Add netlink and setup for encapsulation Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_tunnel.c | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) commit 1faf3d9f7c06c803397665ada1448f374e8f48e0 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:19 2016 -0700 ip6_gre: Add support for fou/gue encapsulation Add netlink and setup for encapsulation Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 75 insertions(+), 4 deletions(-) commit aa3463d65e7b9f5ae322db4a12214c2cb041bc8e Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:18 2016 -0700 fou: Add encap ops for IPv6 tunnels This patch add a new fou6 module that provides encapsulation operations for IPv6. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/fou.h | 2 +- net/ipv6/Makefile | 1 + net/ipv6/fou6.c | 140 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 142 insertions(+), 1 deletion(-) commit 058214a4d1dfefed9f01a277fadd3590acb5f990 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:17 2016 -0700 ip6_tun: Add infrastructure for doing encapsulation Add encap_hlen and ip_tunnel_encap structure to ip6_tnl. Add functions for getting encap hlen, setting up encap on a tunnel, performing encapsulation operation. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip6_tunnel.h | 58 +++++++++++++++++++++++++++++ net/ipv4/ip_tunnel_core.c | 5 +++ net/ipv6/ip6_tunnel.c | 94 ++++++++++++++++++++++++++++++++++++++++------- 3 files changed, 144 insertions(+), 13 deletions(-) commit 5f914b681253966612e052df364c3b8e4a3d5f63 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:16 2016 -0700 fou: Support IPv6 in fou This patch adds receive path support for IPv6 with fou. - Add address family to fou structure for open sockets. This supports AF_INET and AF_INET6. Lookups for fou ports are performed on both the port number and family. - In fou and gue receive adjust tot_len in IPv4 header or payload_len based on address family. - Allow AF_INET6 in FOU_ATTR_AF netlink attribute. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/fou.c | 47 +++++++++++++++++++++++++++++++++++------------ 1 file changed, 35 insertions(+), 12 deletions(-) commit dc969b81ebb37d6ec3d7659763bf017ee03f3ac1 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:15 2016 -0700 fou: Split out {fou,gue}_build_header Create __fou_build_header and __gue_build_header. These implement the protocol generic parts of building the fou and gue header. fou_build_header and gue_build_header implement the IPv4 specific functions and call the __*_build_header functions. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/fou.h | 8 ++++---- net/ipv4/fou.c | 47 +++++++++++++++++++++++++++++++++++++---------- 2 files changed, 41 insertions(+), 14 deletions(-) commit 440924bbc0e11fb429ccc25f6d9597d5a7a02296 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:14 2016 -0700 fou: Call setup_udp_tunnel_sock Use helper function to set up UDP tunnel related information for a fou socket. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/fou.c | 50 ++++++++++++++++---------------------------------- 1 file changed, 16 insertions(+), 34 deletions(-) commit 55c2bc1432241e7be39b11339bd00e85f878ebd6 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:13 2016 -0700 net: Cleanup encap items in ip_tunnels.h Consolidate all the ip_tunnel_encap definitions in one spot in the header file. Also, move ip_encap_hlen and ip_tunnel_encap from ip_tunnel.c to ip_tunnels.h so they call be called without a dependency on ip_tunnel module. Similarly, move iptun_encaps to ip_tunnel_core.c. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip_tunnels.h | 76 ++++++++++++++++++++++++++++++++++++----------- net/ipv4/ip_tunnel.c | 45 ---------------------------- net/ipv4/ip_tunnel_core.c | 4 +++ 3 files changed, 62 insertions(+), 63 deletions(-) commit 1da44f9c15e6389d45e034d5fd0b937e2928b412 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:12 2016 -0700 ipv6: Change "final" protocol processing for encapsulation When performing foo-over-UDP, UDP packets are processed by the encapsulation handler which returns another protocol to process. This may result in processing two (or more) protocols in the loop that are marked as INET6_PROTO_FINAL. The actions taken for hitting a final protocol, in particular the skb_postpull_rcsum can only be performed once. This patch set adds a check of a final protocol has been seen. The rules are: - If the final protocol has not been seen any protocol is processed (final and non-final). In the case of a final protocol, the final actions are taken (like the skb_postpull_rcsum) - If a final protocol has been seen (e.g. an encapsulating UDP header) then no further non-final protocols are allowed (e.g. extension headers). For more final protocols the final actions are not taken (e.g. skb_postpull_rcsum). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_input.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit 4c64242a90a4932260d9ad32b12c745c466e2987 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:11 2016 -0700 ipv6: Fix nexthdr for reinjection In ip6_input_finish the nexthdr protocol is retrieved from the next header offset that is returned in the cb of the skb. This method does not work for UDP encapsulation that may not even have a concept of a nexthdr field (e.g. FOU). This patch checks for a final protocol (INET6_PROTO_FINAL) when a protocol handler returns > 0. If the protocol is not final then resubmission is performed on nhoff value. If the protocol is final then the nexthdr is taken to be the return value. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_input.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) commit 7e13318daa4a67bff2f800923a993ef3818b3c53 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:10 2016 -0700 net: define gso types for IPx over IPv4 and IPv6 This patch defines two new GSO definitions SKB_GSO_IPXIP4 and SKB_GSO_IPXIP6 along with corresponding NETIF_F_GSO_IPXIP4 and NETIF_F_GSO_IPXIP6. These are used to described IP in IP tunnel and what the outer protocol is. The inner protocol can be deduced from other GSO types (e.g. SKB_GSO_TCPV4 and SKB_GSO_TCPV6). The GSO types of SKB_GSO_IPIP and SKB_GSO_SIT are removed (these are both instances of SKB_GSO_IPXIP4). SKB_GSO_IPXIP6 will be used when support for GSO with IP encapsulation over IPv6 is added. Signed-off-by: Tom Herbert <tom@herbertland.com> Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c | 5 ++--- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 5 ++--- drivers/net/ethernet/intel/i40e/i40e_main.c | 3 +-- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 3 +-- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 3 +-- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 3 +-- drivers/net/ethernet/intel/igb/igb_main.c | 3 +-- drivers/net/ethernet/intel/igbvf/netdev.c | 3 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 3 +-- drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 3 +-- include/linux/netdev_features.h | 12 ++++++------ include/linux/netdevice.h | 4 ++-- include/linux/skbuff.h | 4 ++-- net/core/ethtool.c | 4 ++-- net/ipv4/af_inet.c | 2 +- net/ipv4/ipip.c | 2 +- net/ipv6/ip6_offload.c | 4 ++-- net/ipv6/sit.c | 4 ++-- net/netfilter/ipvs/ip_vs_xmit.c | 17 +++++++---------- 19 files changed, 37 insertions(+), 50 deletions(-) commit 5c7cdf339af560f980b12eb6b0b5aa5f68ac6658 Author: Tom Herbert <tom@herbertland.com> Date: Wed May 18 09:06:09 2016 -0700 gso: Remove arbitrary checks for unsupported GSO In several gso_segment functions there are checks of gso_type against a seemingly arbitrary list of SKB_GSO_* flags. This seems like an attempt to identify unsupported GSO types, but since the stack is the one that set these GSO types in the first place this seems unnecessary to do. If a combination isn't valid in the first place that stack should not allow setting it. This is a code simplication especially for add new GSO types. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/af_inet.c | 18 ------------------ net/ipv4/gre_offload.c | 14 -------------- net/ipv4/tcp_offload.c | 19 ------------------- net/ipv4/udp_offload.c | 10 ---------- net/ipv6/ip6_offload.c | 18 ------------------ net/ipv6/udp_offload.c | 13 ------------- net/mpls/mpls_gso.c | 11 +---------- 7 files changed, 1 insertion(+), 102 deletions(-) commit 948350140ef060a42621de0de5c396807f7ec1fc Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed May 18 13:05:00 2016 -0300 Revert "phy: add support for a reset-gpio specification" Commit da47b4572056 ("phy: add support for a reset-gpio specification") causes the following xtensa qemu crash according to Guenter Roeck: [ 9.366256] libphy: ethoc-mdio: probed [ 9.367389] (null): could not attach to PHY [ 9.368555] (null): failed to probe MDIO bus [ 9.371540] Unable to handle kernel paging request at virtual address 0000001c [ 9.371540] pc = d0320926, ra = 903209d1 [ 9.375358] Oops: sig: 11 [#1] This reverts commit da47b4572056487fd7941c26f73b3e8815ff712a. Reported-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/devicetree/bindings/net/phy.txt | 3 --- drivers/net/phy/phy_device.c | 8 -------- 2 files changed, 11 deletions(-) commit 0f3311a8c266b9f4fae4e5cdfcd9a86970e2b9bd Author: Chao Yu <yuchao0@huawei.com> Date: Sat May 21 00:11:09 2016 +0800 f2fs: fix to update dirty page count correctly Once we failed to merge inline data into inode page during flushing inline inode, we will skip invoking inode_dec_dirty_pages, which makes dirty page count incorrect, result in panic in ->evict_inode, Fix it. ------------[ cut here ]------------ kernel BUG at /home/yuchao/git/devf2fs/inode.c:336! invalid opcode: 0000 [#1] PREEMPT SMP CPU: 3 PID: 10004 Comm: umount Tainted: G O 4.6.0-rc5+ #17 Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006 task: f0c33000 ti: c5212000 task.ti: c5212000 EIP: 0060:[<f89aacb5>] EFLAGS: 00010202 CPU: 3 EIP is at f2fs_evict_inode+0x85/0x490 [f2fs] EAX: 00000001 EBX: c4529ea0 ECX: 00000001 EDX: 00000000 ESI: c0131000 EDI: f89dd0a0 EBP: c5213e9c ESP: c5213e78 DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068 CR0: 80050033 CR2: b75878c0 CR3: 1a36a700 CR4: 000406f0 Stack: c4529ea0 c4529ef4 c5213e8c c176d45c c4529ef4 00000000 c4529ea0 c4529fac f89dd0a0 c5213eb0 c1204a68 c5213ed8 c452a2b4 c6680930 c5213ec0 c1204b64 c6680d44 c6680620 c5213eec c120588d ee84b000 ee84b5c0 c5214000 ee84b5e0 Call Trace: [<c176d45c>] ? _raw_spin_unlock+0x2c/0x50 [<c1204a68>] evict+0xa8/0x170 [<c1204b64>] dispose_list+0x34/0x50 [<c120588d>] evict_inodes+0x10d/0x130 [<c11ea941>] generic_shutdown_super+0x41/0xe0 [<c1185190>] ? unregister_shrinker+0x40/0x50 [<c1185190>] ? unregister_shrinker+0x40/0x50 [<c11eac52>] kill_block_super+0x22/0x70 [<f89af23e>] kill_f2fs_super+0x1e/0x20 [f2fs] [<c11eae1d>] deactivate_locked_super+0x3d/0x70 [<c11eb383>] deactivate_super+0x43/0x60 [<c1208ec9>] cleanup_mnt+0x39/0x80 [<c1208f50>] __cleanup_mnt+0x10/0x20 [<c107d091>] task_work_run+0x71/0x90 [<c105725a>] exit_to_usermode_loop+0x72/0x9e [<c1001c7c>] do_fast_syscall_32+0x19c/0x1c0 [<c176dd48>] sysenter_past_esp+0x45/0x74 EIP: [<f89aacb5>] f2fs_evict_inode+0x85/0x490 [f2fs] SS:ESP 0068:c5213e78 ---[ end trace d30536330b7fdc58 ]--- Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/node.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit e7f44b65b532040ac90b73b60ea0b629742ced33 Merge: 76b584d f2c2776 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 14:51:34 2016 -0700 Merge tag 'devicetree-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux Pull devicetree updates from Rob Herring: - Rewrite of the unflattening code to avoid recursion and lessen the stack usage. - Rewrite of the phandle args parsing code to get rid of the fixed args size. This is needed for IOMMU code. - Sync to latest dtc which adds more dts style checking. These warnings are enabled with "W=1" compiles. - Tegra documentation updates related to the above warnings. - A bunch of spelling and other doc fixes. - Various vendor prefix additions. * tag 'devicetree-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: (52 commits) devicetree: Add Creative Technology vendor id gpio: dt-bindings: add ibm,ppc4xx-gpio binding of/unittest: Remove unnecessary module.h header inclusion drivers/of: Fix build warning in populate_node() drivers/of: Fix depth when unflattening devicetree of: dynamic: changeset prop-update revert fix drivers/of: Export of_detach_node() drivers/of: Return allocated memory from of_fdt_unflatten_tree() drivers/of: Specify parent node in of_fdt_unflatten_tree() drivers/of: Rename unflatten_dt_node() drivers/of: Avoid recursively calling unflatten_dt_node() drivers/of: Split unflatten_dt_node() of: include errno.h in of_graph.h of: document refcount incrementation of of_get_cpu_node() Documentation: dt: soc: fix spelling mistakes Documentation: dt: power: fix spelling mistake Documentation: dt: pinctrl: fix spelling mistake Documentation: dt: opp: fix spelling mistake Documentation: dt: net: fix spelling mistakes Documentation: dt: mtd: fix spelling mistake ... commit c0fcded2e6879d817cec822b8513a2f6b6e4dfe9 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Wed May 18 15:55:42 2016 +0100 xen-netback: only deinitialized hash if it was initialized A domain with a frontend that does not implement a control ring has been seen to cause a crash during domain save. This was apparently because the call to xenvif_deinit_hash() in xenvif_disconnect_ctrl() is made regardless of whether a control ring was connected, and hence xenvif_hash_init() was called. This patch brings the call to xenvif_deinit_hash() in xenvif_disconnect_ctrl() inside the if clause that checks whether the control ring event channel was connected. This is sufficient to ensure it is only called if xenvif_init_hash() was called previously. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Reported-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Cc: Wei Liu <wei.liu2@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/interface.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 76b584d3125a1f7d8b64e9c522a4555bc2844bde Merge: 7992893 c16d275 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 14:35:07 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma Pull rdma updates from Doug Ledford: "Primary 4.7 merge window changes - Updates to the new Intel X722 iWARP driver - Updates to the hfi1 driver - Fixes for the iw_cxgb4 driver - Misc core fixes - Generic RDMA READ/WRITE API addition - SRP updates - Misc ipoib updates - Minor mlx5 updates" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: (148 commits) IB/mlx5: Fire the CQ completion handler from tasklet net/mlx5_core: Use tasklet for user-space CQ completion events IB/core: Do not require CAP_NET_ADMIN for packet sniffing IB/mlx4: Fix unaligned access in send_reply_to_slave IB/mlx5: Report Scatter FCS device capability when supported IB/mlx5: Add Scatter FCS support for Raw Packet QP IB/core: Add Scatter FCS create flag IB/core: Add Raw Scatter FCS device capability IB/core: Add extended device capability flags i40iw: pass hw_stats by reference rather than by value i40iw: Remove unnecessary synchronize_irq() before free_irq() i40iw: constify i40iw_vf_cqp_ops structure IB/mlx5: Add UARs write-combining and non-cached mapping IB/mlx5: Allow mapping the free running counter on PROT_EXEC IB/mlx4: Use list_for_each_entry_safe IB/SA: Use correct free function IB/core: Fix a potential array overrun in CMA and SA agent IB/core: Remove unnecessary check in ibnl_rcv_msg IB/IWPM: Fix a potential skb leak RDMA/nes: replace custom print_hex_dump() ... commit 3a17fb329da68cb00558721aff876a80bba2fdb9 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 20 23:09:49 2016 +0200 PM / sleep: Handle failures in device_suspend_late() consistently Grygorii Strashko reports: The PM runtime will be left disabled for the device if its .suspend_late() callback fails and async suspend is not allowed for this device. In this case device will not be added in dpm_late_early_list and dpm_resume_early() will ignore this device, as result PM runtime will be disabled for it forever (side effect: after 8 subsequent failures for the same device the PM runtime will be reenabled due to disable_depth overflow). To fix this problem, add devices to dpm_late_early_list regardless of whether or not device_suspend_late() returns errors for them. That will ensure failures in there to be handled consistently for all devices regardless of their async suspend/resume status. Reported-by: Grygorii Strashko <grygorii.strashko@ti.com> Tested-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Cc: All applicable <stable@vger.kernel.org> drivers/base/power/main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 7992893c5a9fdffa42117f6f749359466e06bdf6 Merge: 6eb59af 4a99fa0 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 14:06:21 2016 -0700 Merge tag 'for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply Pull power supply and reset updates from Sebastian Reichel: - alternative reset driver for new at91 SoCs - misc fixes * tag 'for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply: sbs-battery: fix power status when battery charging near dry power: ipaq-micro-battery: freeing the wrong variable power/max8925: freeing wrong variable power: reset: at91-shdwc: add new shutdown controller driver ARM: dts: at91: shdwc binding: add new shutdown controller documentation commit fcee59065e58498682c60069cc6fb90694bab27e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed May 18 21:47:38 2016 +0200 drm: Nuke ->vblank_disable_allowed This was added in commit 0a3e67a4caac273a3bfc4ced3da364830b1ab241 Author: Jesse Barnes <jbarnes@virtuousgeek.org> Date: Tue Sep 30 12:14:26 2008 -0700 drm: Rework vblank-wait handling to allow interrupt reduction. to stay backwards-compatible with old UMS code that didn't even tell the kernel when it did a modeset, so that the kernel could save/restore vblank counters. At worst this means vblanks will be somewhat funky on a setup that very likely no one still runs. So let's just nuke it. Plan B would be to set it unconditionally in drm_vblank_init for kms drivers, instead of in each driver separately. So if this patch breaks anything please only restore the hunks in drmP.h and drm_irq.c, plus add a check for DRIVER_MODESET in drm_vblank_init. Stumbled over this in a discussion on irc with Chris. Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Liviu Dudau <liviu.dudau@arm.com> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Eric Anholt <eric@anholt.net> Cc: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Cc: Inki Dae <inki.dae@samsung.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Mark Yao <mark.yao@rock-chips.com> Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Liviu Dudau <Liviu.Dudau@arm.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 1 - drivers/gpu/drm/arm/hdlcd_drv.c | 1 - drivers/gpu/drm/armada/armada_drv.c | 1 - drivers/gpu/drm/drm_irq.c | 6 ------ drivers/gpu/drm/exynos/exynos_drm_drv.c | 7 ------- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 1 - drivers/gpu/drm/gma500/psb_drv.c | 1 - drivers/gpu/drm/i915/i915_dma.c | 3 --- drivers/gpu/drm/imx/imx-drm-core.c | 7 ------- drivers/gpu/drm/radeon/radeon_irq_kms.c | 1 - drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 7 ------- drivers/gpu/drm/tegra/drm.c | 1 - drivers/gpu/drm/vc4/vc4_kms.c | 2 -- include/drm/drmP.h | 8 -------- 14 files changed, 47 deletions(-) commit fc7fedc20b7c819b9ef003afa16a64dc9e5ac30e Merge: d5fa33f f921791 Author: Dave Airlie <airlied@redhat.com> Date: Sat May 21 06:41:59 2016 +1000 Merge tag 'vmwgfx-next-160520' of git://people.freedesktop.org/~thomash/linux into drm-next Pull request of 2016-05-20 * tag 'vmwgfx-next-160520' of git://people.freedesktop.org/~thomash/linux: drm/vmwgfx: Report vmwgfx version to vmware.log drm/vmwgfx: Add VMWare host messaging capability drm/vmwgfx: Kill some lockdep warnings commit eb0a4a47ae89aaa0674ab3180de6a162f3be2ddf Author: Miklos Szeredi <mszeredi@redhat.com> Date: Fri May 20 22:13:45 2016 +0200 af_unix: fix hard linked sockets on overlay Overlayfs uses separate inodes even in the case of hard links on the underlying filesystems. This is a problem for AF_UNIX socket implementation which indexes sockets based on the inode. This resulted in hard linked sockets not working. The fix is to use the real, underlying inode. Test case follows: -- ovl-sock-test.c -- #include <unistd.h> #include <err.h> #include <sys/socket.h> #include <sys/un.h> #define SOCK "test-sock" #define SOCK2 "test-sock2" int main(void) { int fd, fd2; struct sockaddr_un addr = { .sun_family = AF_UNIX, .sun_path = SOCK, }; struct sockaddr_un addr2 = { .sun_family = AF_UNIX, .sun_path = SOCK2, }; unlink(SOCK); unlink(SOCK2); if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) err(1, "socket"); if (bind(fd, (struct sockaddr *) &addr, sizeof(addr)) == -1) err(1, "bind"); if (listen(fd, 0) == -1) err(1, "listen"); if (link(SOCK, SOCK2) == -1) err(1, "link"); if ((fd2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) err(1, "socket"); if (connect(fd2, (struct sockaddr *) &addr2, sizeof(addr2)) == -1) err (1, "connect"); return 0; } ---- Reported-by: Alexander Morozov <alexandr.morozov@docker.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> Cc: <stable@vger.kernel.org> net/unix/af_unix.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit a118084432d642eeccb961c7c8cc61525a941fcb Author: Miklos Szeredi <mszeredi@redhat.com> Date: Fri May 20 22:13:45 2016 +0200 vfs: add d_real_inode() helper Needed by the following fix. Signed-off-by: Miklos Szeredi <mszeredi@redhat.com> Cc: <stable@vger.kernel.org> include/linux/dcache.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit d5fa33f28401414959b68591075c8053e8276547 Merge: 24e04d7 ca79e49 Author: Dave Airlie <airlied@redhat.com> Date: Sat May 21 06:12:13 2016 +1000 Merge branch 'linux-4.7' of git://github.com/skeggsb/linux into drm-next Nothing too exciting here, there's a larger chunk of work that still needs more testing but not likely to get that done today - so - here's the rest of it. Assuming nothing else goes horribly wrong, I should be able to send the rest Monday if it isn't too late.... Changes: - Improvements to power sensor support - Initial attempt at GM108 support - Minor fixes to GR init + ucode - Make use of topology information (provided by the GPU) in various places, should at least fix some fault recovery issues and engine/runlist mapping confusion on newer GPUs. * 'linux-4.7' of git://github.com/skeggsb/linux: (51 commits) drm/nouveau/gr/gf100-: fix race condition in fecs/gpccs ucode drm/nouveau/core: recognise GM108 chipsets drm/nouveau/gr/gm107-: fix touching non-existent ppcs in attrib cb setup drm/nouveau/gr/gk104-: share implementation of ppc exception init drm/nouveau/gr/gk104-: move rop_active_fbps init to nonctx drm/nouveau/bios/pll: check BIT table version before trying to parse it drm/nouveau/bios/pll: prevent oops when limits table can't be parsed drm/nouveau/volt/gk104: round up in gk104_volt_set drm/nouveau/fb/gm200: setup mmu debug buffer registers at init() drm/nouveau/fb/gk20a,gm20b: setup mmu debug buffer registers at init() drm/nouveau/fb/gf100-: allocate mmu debug buffers drm/nouveau/fb: allow chipset-specific actions for oneinit() drm/nouveau/gr/gm200-: fix bad hardcoding of a max-tpcs-per-gpc value drm/nouveau/gr/gm200-: rop count == ltc count drm/nouveau/gr/gm200: modify the mask when copying mmu settings from fb drm/nouveau/gr/gm200: move some code into init_gpc_mmu() hook drm/nouveau/gr/gm200: make generate_main() static drm/nouveau/gr/gf100-: abstract fetching rop count drm/nouveau/gr/gf100-: rename magic_not_rop_nr to screen_tile_row_offset drm/nouveau/gr/gf100-: remove hardcoded idle_timeout values ... commit 38f91ca8c0ea69f707c26f592dcc70f937088bcc Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed May 18 14:07:56 2016 -0700 f2fs: flush pending bios right away when error occurs Given errors, this patch flushes pending bios as soon as possible. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 10 +++++++++- fs/f2fs/data.c | 2 +- fs/f2fs/f2fs.h | 7 +------ fs/f2fs/file.c | 8 ++++---- fs/f2fs/inode.c | 2 +- 5 files changed, 16 insertions(+), 13 deletions(-) commit 975756c41332bc5e523e9f843271ed5ab6aaaaaa Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Thu May 19 11:57:21 2016 -0700 f2fs: avoid ENOSPC fault in the recovery process This patch avoids impossible error injection, ENOSPC, during recovery process. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/recovery.c | 4 ++++ 1 file changed, 4 insertions(+) commit e6790fd861100a01838077b9b59bc339a80ee462 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 16:21:07 2016 +0200 mlx5: avoid unused variable warning When CONFIG_NET_CLS_ACT is disabled, we get a new warning in the mlx5 ethernet driver because the tc_for_each_action() loop never references the iterator: mellanox/mlx5/core/en_tc.c: In function 'mlx5e_stats_flower': mellanox/mlx5/core/en_tc.c:431:20: error: unused variable 'a' [-Werror=unused-variable] struct tc_action *a; This changes the dummy tc_for_each_action() macro by adding a cast to void, letting the compiler know that the variable is intentionally declared but not used here. I could not come up with a nicer workaround, but this seems to do the trick. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: aad7e08d39bd ("net/mlx5e: Hardware offloaded flower filter statistics support") Fixes: 00175aec941e ("net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef") Acked-By: Amir Vadai <amir@vadai.me> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/act_api.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4c1d76a1e15e0d66e581764b4d29d08d207aff4a Merge: 7f058c0 e4c740e Author: Arnd Bergmann <arnd@arndb.de> Date: Fri May 20 20:22:44 2016 +0200 Merge tag 'pxa-for-4.7' of https://github.com/rjarzmik/linux into fixes Merge "pxa changes for v4.7 cycle" from Robert Jarzmik: This is a minor cycle with : - cleanup fix from Stephen on clocks (CLK_ROOT deprecated) - pin control activation for device-tree platforms * tag 'pxa-for-4.7' of https://github.com/rjarzmik/linux: ARM: pxa: Remove CLK_IS_ROOT ARM: pxa: activate pinctrl for device-tree machines These should have been part of the original pull request but got accidentally dropped. Both changes in this branch can be considered bugfixes, so I'm putting them in the fixes branch now. commit b7552e1bccbe3da9c8e7386c6188e8ea4667c8e7 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed May 18 14:14:28 2016 +0200 bpf: rather use get_random_int for randomizations Start address randomization and blinding in BPF currently use prandom_u32(). prandom_u32() values are not exposed to unpriviledged user space to my knowledge, but given other kernel facilities such as ASLR, stack canaries, etc make use of stronger get_random_int(), we better make use of it here as well given blinding requests successively new random values. get_random_int() has minimal entropy pool depletion, is not cryptographically secure, but doesn't need to be for our use cases here. Suggested-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 09ec8e7fb6bcb351bbded18a571ea037504bb3a6 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Wed May 18 07:43:57 2016 -0400 qede: Fix DMA address APIs usage Driver incorrectly uses dma_unmap_addr_set() to set a variable which is in truth a dma_addr_t [i.e not defined using DEFINE_DMA_UNMAP_ADDR()] and is being used by the driver flows other than unmapping physical addresses. This patch fixes driver fastpath where CONFIG_NEED_DMA_MAP_STATE is not set. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_main.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 1968a0b8b6ca088bc029bd99ee696f1aca4090d0 Author: Sabrina Dubroca <sd@queasysnail.net> Date: Wed May 18 13:34:40 2016 +0200 macsec: fix netlink attribute for key id In my last commit I replaced MACSEC_SA_ATTR_KEYID by MACSEC_SA_ATTR_KEY. Fixes: 8acca6acebd0 ("macsec: key identifier is 128 bits, not 64") Signed-off-by: Sabrina Dubroca <sd@queasysnail.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macsec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6eb59af580dcffc6f6982ac8ef6d27a1a5f26b27 Merge: 4d230d4 b52207e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 11:10:24 2016 -0700 Merge tag 'mfd-for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd Pull MFD updates from Lee Jones: "New Drivers: - Add new driver for MAXIM MAX77620/MAX20024 PMIC - Add new driver for Hisilicon HI665X PMIC New Device Support: - Add support for AXP809 in axp20x-rsb - Add support for Power Supply in axp20x New core features: - devm_mfd_* managed resources Fix-ups: - Remove unused code (da9063-irq, wm8400-core, tps6105x, smsc-ece1099, twl4030-power) - Improve clean-up in error path (intel_quark_i2c_gpio) - Explicitly include headers (syscon.h) - Allow building as modules (max77693) - Use IS_ENABLED() instead of rolling your own (dm355evm_msp, wm8400-core) - DT adaptions (axp20x, hi655x, arizona, max77620) - Remove CLK_IS_ROOT flag (intel-lpss, intel_quark) - Move to gpiochip API (asic3, dm355evm_msp, htc-egpio, htc-i2cpld, sm501, tc6393xb, tps65010, ucb1x00, vexpress) - Make use of devm_mfd_* calls (act8945a, as3711, atmel-hlcdc, bcm590xx, hi6421-pmic-core, lp3943, menf21bmc, mt6397, rdc321x, rk808, rn5t618, rt5033, sky81452, stw481x, tps6507x, tps65217, wm8400) Bug Fixes" - Fix ACPI child matching (mfd-core) - Fix start-up ordering issues (mt6397-core, arizona-core) - Fix forgotten register state on resume (intel-lpss) - Fix Clock related issues (twl6040) - Fix scheduling whilst atomic (omap-usb-tll) - Kconfig changes (vexpress)" * tag 'mfd-for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (73 commits) mfd: hi655x: Add MFD driver for hi655x mfd: ab8500-debugfs: Trivial fix of spelling mistake on "between" mfd: vexpress: Add !ARCH_USES_GETTIMEOFFSET dependency mfd: Add device-tree binding doc for PMIC MAX77620/MAX20024 mfd: max77620: Add core driver for MAX77620/MAX20024 mfd: arizona: Add defines for GPSW values that can be used from DT mfd: omap-usb-tll: Fix scheduling while atomic BUG mfd: wm5110: ARIZONA_CLOCK_CONTROL should be volatile mfd: axp20x: Add a cell for the ac power_supply part of the axp20x PMICs mfd: intel_soc_pmic_core: Terminate panel control GPIO lookup table correctly mfd: wl1273-core: Use devm_mfd_add_devices() for mfd_device registration mfd: tps65910: Use devm_mfd_add_devices and devm_regmap_add_irq_chip mfd: sec: Use devm_mfd_add_devices and devm_regmap_add_irq_chip mfd: rc5t583: Use devm_mfd_add_devices and devm_request_threaded_irq mfd: max77686: Use devm_mfd_add_devices and devm_regmap_add_irq_chip mfd: as3722: Use devm_mfd_add_devices and devm_regmap_add_irq_chip mfd: twl4030-power: Remove driver path in file comment MAINTAINERS: Add entry for X-Powers AXP family PMIC drivers mfd: smsc-ece1099: Remove unnecessarily remove callback mfd: Use IS_ENABLED(CONFIG_FOO) instead of checking FOO || FOO_MODULE ... commit 4d230d4d030e34e6eb8911fb669d1b42298eca9e Merge: 410b429 c2f90a4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 11:05:40 2016 -0700 Merge tag 'hsi-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-hsi Pull HSI updates from Sebastian Reichel: - merge omap-ssi and omap-ssi-port modules - fix omap-ssi module reloading - add DVFS support to omap-ssi * tag 'hsi-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-hsi: HSI: omap-ssi: move omap_ssi_port_update_fclk HSI: omap-ssi: include pinctrl header files HSI: omap-ssi: add COMMON_CLK dependency HSI: omap-ssi: add clk change support HSI: omap_ssi: built omap_ssi and omap_ssi_port into one module HSI: omap_ssi: fix removal of port platform device HSI: omap_ssi: make sure probe stays available HSI: omap_ssi: fix module unloading HSI: omap_ssi_port: switch to gpiod API commit 410b42978a241dc4a269d0d75c75d260e6d016e8 Merge: e4fba88 ab366b4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 11:01:02 2016 -0700 Merge tag 'fbdev-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux Pull fbdev updates from Tomi Valkeinen: - imxfb: fix lcd power up - small fixes and cleanups * tag 'fbdev-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux: fbdev: Use IS_ENABLED() instead of checking for built-in or module efifb: Don't show the mapping VA video: AMBA CLCD: Remove unncessary include in amba-clcd.c fbdev: ssd1307fb: Fix charge pump setting Documentation: fb: fix spelling mistakes fbdev: fbmem: implement error handling in fbmem_init() fbdev: sh_mipi_dsi: remove driver video: fbdev: imxfb: add some error handling video: fbdev: imxfb: fix semantic of .get_power and .set_power video: fbdev: omap2: Remove deprecated regulator_can_change_voltage() usage commit affa80bd97f7ca282d1faa91667b3ee9e4c590e6 Author: Ricky Liang <jcliang@chromium.org> Date: Fri May 20 10:58:59 2016 -0700 Input: uinput - handle compat ioctl for UI_SET_PHYS When running a 32-bit userspace on a 64-bit kernel, the UI_SET_PHYS ioctl needs to be treated with special care, as it has the pointer size encoded in the command. Signed-off-by: Ricky Liang <jcliang@chromium.org> Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/uinput.c | 6 ++++++ 1 file changed, 6 insertions(+) commit d4c6fb36ac2c82f8f0c05b04cf102dcdc2d5a14d Author: Wang Nan <wangnan0@huawei.com> Date: Fri May 20 16:38:24 2016 +0000 perf evsel: Record fd into perf_mmap Add a fd field into struct perf_mmap so that perf can track the mmap fd. This feature will be used for toggling overwrite ring buffers. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463762315-155689-3-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 6 ++++++ tools/perf/util/evlist.h | 1 + 2 files changed, 7 insertions(+) commit b90dc17a5d14a881f9bb3b58edb3d71075d58afb Author: Wang Nan <wangnan0@huawei.com> Date: Fri May 20 16:38:23 2016 +0000 perf evsel: Add overwrite attribute and check write_backward Add 'overwrite' attribute to evsel to mark whether this event is overwritable. The following commits will support syntax like: # perf record -e cycles/overwrite/ ... An overwritable evsel requires kernel support for the perf_event_attr.write_backward ring buffer feature. Add it to perf_missing_feature. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1463762315-155689-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 13 +++++++++++++ tools/perf/util/evsel.h | 1 + 2 files changed, 14 insertions(+) commit f86911e2de129fb3c8ca402c251138d12c4a9d37 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Wed May 18 08:53:01 2016 +0100 xen-netback: correct length checks on hash copy_ops The length checks on the grant table copy_ops for setting hash key and hash mapping are checking the local 'len' value which is correct in the case of the former but not the latter. This was picked up by static analysis checks. This patch replaces checks of 'len' with 'copy_op.len' in both cases to correct the incorrect check, keep the two checks consistent, and to make it clear what the checks are for. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: Wei Liu <wei.liu2@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/hash.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 185be5aef1739fff0298f59b54f2ef7ccf5a849d Author: Rabin Vincent <rabinv@axis.com> Date: Wed May 18 12:47:31 2016 +0200 phy: fix crash in fixed_phy_add() Since e7f4dc3536a ("mdio: Move allocation of interrupts into core"), platforms which call fixed_phy_add() before fixed_mdio_bus_init() is called (for example, because the platform code and the fixed_phy driver use the same initcall level) crash in fixed_phy_add() since the ->mii_bus is not allocated. Also since e7f4dc3536a, these interrupts are initalized to polling by default. The few (old) platforms which directly use fixed_phy_add() from their platform code all pass PHY_POLL for the irq argument, so we can keep these platforms not crashing by simply not attempting to set the irq if PHY_POLL is passed. Also, even if problems have not been reported on more modern platforms which used fixed_phy_register() from drivers' probe functions, we return -EPROBE_DEFER if the MDIO bus is not yet registered so that the probe is retried later. Fixes: e7f4dc3536a400 ("mdio: Move allocation of interrupts into core") Signed-off-by: Rabin Vincent <rabinv@axis.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/fixed_phy.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 408cf677073a5d1a7343bc6430a7297ba7b280d4 Merge: 1ab9418 a706670 Author: Ingo Molnar <mingo@kernel.org> Date: Fri May 20 19:37:43 2016 +0200 Merge tag 'perf-core-for-mingo-20160520' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - We should not use the current value of the kernel.perf_event_max_stack as the default value for --max-stack in tools that can process perf.data files, they will only match if that sysctl wasn't changed from its default value at the time the perf.data file was recorded, fix it. This fixes a bug where a 'perf record -a --call-graph dwarf ; perf report' produces a glibc invalid free backtrace (Arnaldo Carvalho de Melo) - Provide a better warning when running 'perf trace' on a system where the kernel.kptr_restrict is set to 1, similar to the one produced by 'perf record', noticed on ubuntu 16.04 where this is the default kptr_restrict setting. (Arnaldo Carvalho de Melo) - Fix ordering of instructions in the annotation code, noticed when annotating ARM binaries, now that table is auto-ordered at first use, to avoid more such problems (Chris Ryder) - Set buildid dir under symfs when --symfs is provided (He Kuang) - Fix the 'exit_group()' syscall output in 'perf trace' (Arnaldo Carvalho de Melo) - Only auto set call-graph to "dwarf" in 'perf trace' when syscalls are being traced (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 8329e818f14926a6040df86b2668568bde342ebf Author: Steven Rostedt <rostedt@goodmis.org> Date: Mon May 16 23:00:35 2016 -0400 ftrace/x86: Set ftrace_stub to weak to prevent gcc from using short jumps to it Matt Fleming reported seeing crashes when enabling and disabling function profiling which uses function graph tracer. Later Namhyung Kim hit a similar issue and he found that the issue was due to the jmp to ftrace_stub in ftrace_graph_call was only two bytes, and when it was changed to jump to the tracing code, it overwrote the ftrace_stub that was after it. Masami Hiramatsu bisected this down to a binutils change: 8dcea93252a9ea7dff57e85220a719e2a5e8ab41 is the first bad commit commit 8dcea93252a9ea7dff57e85220a719e2a5e8ab41 Author: H.J. Lu <hjl.tools@gmail.com> Date: Fri May 15 03:17:31 2015 -0700 Add -mshared option to x86 ELF assembler This patch adds -mshared option to x86 ELF assembler. By default, assembler will optimize out non-PLT relocations against defined non-weak global branch targets with default visibility. The -mshared option tells the assembler to generate code which may go into a shared library where all non-weak global branch targets with default visibility can be preempted. The resulting code is slightly bigger. This option only affects the handling of branch instructions. Declaring ftrace_stub as a weak call prevents gas from using two byte jumps to it, which would be converted to a jump to the function graph code. Link: http://lkml.kernel.org/r/20160516230035.1dbae571@gandalf.local.home Reported-by: Matt Fleming <matt@codeblueprint.co.uk> Reported-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> arch/x86/kernel/mcount_64.S | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit e4fba88d00d21f50239eac7d653027bfaf844296 Merge: ffd565e 4a6b27b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 10:25:16 2016 -0700 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto fix from Herbert Xu: "Fix a regression that causes sha-mb to crash" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: sha1-mb - make sha1_x8_avx2() conform to C function ABI commit ffd565e315aa8211365bb6864000f04e7b277f59 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 12 23:03:35 2016 +0200 irqchip: nps: add 64BIT dependency The newly added nps irqchip driver causes build warnings on ARM64. include/soc/nps/common.h: In function 'nps_host_reg_non_cl': include/soc/nps/common.h:148:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] As the driver is only used on ARC, we don't need to see it without COMPILE_TEST elsewhere, and we can avoid the warnings by only building on 32-bit architectures even with CONFIG_COMPILE_TEST. Acked-by: Marc Zyngier <narc.zyngier@arm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/irqchip/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 6112a300c9e41993cc0dc56ac393743d28381284 Author: Soumya PN <soumya.p.n@hpe.com> Date: Tue May 17 21:31:14 2016 +0530 ftrace: Don't disable irqs when taking the tasklist_lock read_lock In ftrace.c inside the function alloc_retstack_tasklist() (which will be invoked when function_graph tracing is on) the tasklist_lock is being held as reader while iterating through a list of threads. Here the lock is being held as reader with irqs disabled. The tasklist_lock is never write_locked in interrupt context so it is safe to not disable interrupts for the duration of read_lock in this block which, can be significant, given the block of code iterates through all threads. Hence changing the code to call read_lock() and read_unlock() instead of read_lock_irqsave() and read_unlock_irqrestore(). A similar change was made in commits: 8063e41d2ffc ("tracing: Change syscall_*regfunc() to check PF_KTHREAD and use for_each_process_thread()")' and 3472eaa1f12e ("sched: normalize_rt_tasks(): Don't use _irqsave for tasklist_lock, use task_rq_lock()")' Link: http://lkml.kernel.org/r/1463500874-77480-1-git-send-email-soumya.p.n@hpe.com Signed-off-by: Soumya PN <soumya.p.n@hpe.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/ftrace.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit c04a5880299eab3da8c10547db96ea9cdffd44a6 Merge: a1c28b7 138a076 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 10:12:41 2016 -0700 Merge tag 'powerpc-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc updates from Michael Ellerman: "Highlights: - Support for Power ISA 3.0 (Power9) Radix Tree MMU from Aneesh Kumar K.V - Live patching support for ppc64le (also merged via livepatching.git) Various cleanups & minor fixes from: - Aaro Koskinen, Alexey Kardashevskiy, Andrew Donnellan, Aneesh Kumar K.V, Chris Smart, Daniel Axtens, Frederic Barrat, Gavin Shan, Ian Munsie, Lennart Sorensen, Madhavan Srinivasan, Mahesh Salgaonkar, Markus Elfring, Michael Ellerman, Oliver O'Halloran, Paul Gortmaker, Paul Mackerras, Rashmica Gupta, Russell Currey, Suraj Jitindar Singh, Thiago Jung Bauermann, Valentin Rothberg, Vipin K Parashar. General: - Update LMB associativity index during DLPAR add/remove from Nathan Fontenot - Fix branching to OOL handlers in relocatable kernel from Hari Bathini - Add support for userspace Power9 copy/paste from Chris Smart - Always use STRICT_MM_TYPECHECKS from Michael Ellerman - Add mask of possible MMU features from Michael Ellerman PCI: - Enable pass through of NVLink to guests from Alexey Kardashevskiy - Cleanups in preparation for powernv PCI hotplug from Gavin Shan - Don't report error in eeh_pe_reset_and_recover() from Gavin Shan - Restore initial state in eeh_pe_reset_and_recover() from Gavin Shan - Revert "powerpc/eeh: Fix crash in eeh_add_device_early() on Cell" from Guilherme G Piccoli - Remove the dependency on EEH struct in DDW mechanism from Guilherme G Piccoli selftests: - Test cp_abort during context switch from Chris Smart - Add several tests for transactional memory support from Rashmica Gupta perf: - Add support for sampling interrupt register state from Anju T - Add support for unwinding perf-stackdump from Chandan Kumar cxl: - Configure the PSL for two CAPI ports on POWER8NVL from Philippe Bergheaud - Allow initialization on timebase sync failures from Frederic Barrat - Increase timeout for detection of AFU mmio hang from Frederic Barrat - Handle num_of_processes larger than can fit in the SPA from Ian Munsie - Ensure PSL interrupt is configured for contexts with no AFU IRQs from Ian Munsie - Add kernel API to allow a context to operate with relocate disabled from Ian Munsie - Check periodically the coherent platform function's state from Christophe Lombard Freescale: - Updates from Scott: "Contains 86xx fixes, minor device tree fixes, an erratum workaround, and a kconfig dependency fix." * tag 'powerpc-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: (192 commits) powerpc/86xx: Fix PCI interrupt map definition powerpc/86xx: Move pci1 definition to the include file powerpc/fsl: Fix build of the dtb embedded kernel images powerpc/fsl: Fix rcpm compatible string powerpc/fsl: Remove FSL_SOC dependency from FSL_LBC powerpc/fsl-pci: Add a workaround for PCI 5 errata powerpc/fsl: Fix SPI compatible on t208xrdb and t1040rdb powerpc/powernv/npu: Add PE to PHB's list powerpc/powernv: Fix insufficient memory allocation powerpc/iommu: Remove the dependency on EEH struct in DDW mechanism Revert "powerpc/eeh: Fix crash in eeh_add_device_early() on Cell" powerpc/eeh: Drop unnecessary label in eeh_pe_change_owner() powerpc/eeh: Ignore handlers in eeh_pe_reset_and_recover() powerpc/eeh: Restore initial state in eeh_pe_reset_and_recover() powerpc/eeh: Don't report error in eeh_pe_reset_and_recover() Revert "powerpc/powernv: Exclude root bus in pnv_pci_reset_secondary_bus()" powerpc/powernv/npu: Enable NVLink pass through powerpc/powernv/npu: Rework TCE Kill handling powerpc/powernv/npu: Add set/unset window helpers powerpc/powernv/ioda2: Export debug helper pe_level_printk() ... commit a1c28b75a95808161cacbb3531c418abe248994e Merge: a05a70d 5632a9f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Fri May 20 10:01:38 2016 -0700 Merge branch 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm Pull ARM updates from Russell King: "Changes included in this pull request: - revert pxa2xx-flash back to using ioremap_cached() and switch memremap() to use arch_memremap_wb() - remove pci=firmware command line argument handling - remove unnecessary arm_dma_set_mask() implementation, the generic implementation will do for ARM - removal of the ARM kallsyms "hack" to work around mode switching veneers and vectors located below PAGE_OFFSET - tidy up build system output a little - add L2 cache power management DT bindings - remove duplicated local_irq_disable() in reboot paths - handle AMBA primecell devices better at registration time with PM domains (needed for Samsung SoCs) - ARM specific preparation to support Keystone II kexec" * 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm: ARM: 8567/1: cache-uniphier: activate ways for secondary CPUs ARM: 8570/2: Documentation: devicetree: Add PL310 PM bindings ARM: 8569/1: pl2x0: Add OF control of cache power management ARM: 8568/1: reboot: remove duplicated local_irq_disable() ARM: 8566/1: drivers: amba: properly handle devices with power domains ARM: provide arm_has_idmap_alias() helper ARM: kexec: remove 512MB restriction on kexec crashdump ARM: provide improved virt_to_idmap() functionality ARM: kexec: fix crashkernel= handling ARM: 8557/1: specify install, zinstall, and uinstall as PHONY targets ARM: 8562/1: suppress "include/generated/mach-types.h is up to date." ARM: 8553/1: kallsyms: remove --page-offset command line option ARM: 8552/1: kallsyms: remove special lower address limit for CONFIG_ARM ARM: 8555/1: kallsyms: ignore ARM mode switching veneers ARM: 8548/1: dma-mapping: remove arm_dma_set_mask() ARM: 8554/1: kernel: pci: remove pci=firmware command line parameter handling ARM: memremap: implement arch_memremap_wb() memremap: add arch specific hook for MEMREMAP_WB mappings mtd: pxa2xx-flash: switch back from memremap to ioremap_cached ARM: reintroduce ioremap_cached() for creating cached I/O mappings commit f921791314811afa00bb7fbbd40f51bd3b8eff01 Author: Sinclair Yeh <syeh@vmware.com> Date: Wed Apr 27 19:11:18 2016 -0700 drm/vmwgfx: Report vmwgfx version to vmware.log When tracking down a customer issue, it is useful to know exactly which version of the vmwgfx they are using. Since vmware.log is often the only available debug log, report vmwgfx version in there. Signed-off-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> drivers/gpu/drm/vmwgfx/Makefile | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 19 ++++++++++++++++++- drivers/gpu/drm/vmwgfx/vmwgfx_drv.h | 6 ++++++ 3 files changed, 25 insertions(+), 2 deletions(-) commit 89da76fde68de1205756707133508e930be4f389 Author: Sinclair Yeh <syeh@vmware.com> Date: Wed Apr 27 19:10:19 2016 -0700 drm/vmwgfx: Add VMWare host messaging capability This patch adds capabilities for a VMWare guest to send and receive messages from the host, and adds functions to sending log messages to vmware.log and to request device settings that aren't available through the virtual hardware, e.g. certain settings in the VMX file. Signed-off-by: Sinclair Yeh <syeh@vmware.com> Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com> drivers/gpu/drm/vmwgfx/vmwgfx_msg.c | 416 ++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/vmwgfx/vmwgfx_msg.h | 191 +++++++++++++++++ 2 files changed, 607 insertions(+) commit 93cd16817ae5ddcfc548784b51c76bf6d7923442 Author: Thomas Hellstrom <thellstrom@vmware.com> Date: Tue May 3 11:24:35 2016 +0200 drm/vmwgfx: Kill some lockdep warnings Some global KMS state that is elsewhere protected by the mode_config mutex here needs to be protected with a local mutex. Remove corresponding lockdep checks and introduce a new driver-private global_kms_state_mutex, and make sure its locking order is *after* the crtc locks in order to avoid having to release those when the new mutex is taken. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Sinclair Yeh <syeh@vmware.com> Cc: <stable@vger.kernel.org> # 4.6 drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 1 + drivers/gpu/drm/vmwgfx/vmwgfx_drv.h | 1 + drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 27 +++++++++++++-------------- drivers/gpu/drm/vmwgfx/vmwgfx_scrn.c | 3 +++ drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c | 3 +++ 5 files changed, 21 insertions(+), 14 deletions(-) commit a706670900073d236938d539d1109338d64b47bb Author: He Kuang <hekuang@huawei.com> Date: Thu May 19 11:47:37 2016 +0000 perf tools: Set buildid dir under symfs when --symfs is provided This patch moves the reference of buildid dir to 'symfs/.debug' and skips the local buildid dir when '--symfs' is given, so that every single file opened by perf is relative to symfs directory now. Signed-off-by: He Kuang <hekuang@huawei.com> Acked-by: David Ahern <dsahern@gmail.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Ekaterina Tumanova <tumanova@linux.vnet.ibm.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1463658462-85131-2-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-annotate.c | 5 +++-- tools/perf/builtin-diff.c | 5 +++-- tools/perf/builtin-report.c | 5 +++-- tools/perf/builtin-script.c | 5 +++-- tools/perf/builtin-timechart.c | 5 +++-- tools/perf/util/dso.c | 4 +--- tools/perf/util/symbol.c | 23 +++++++++++++++++++++++ tools/perf/util/symbol.h | 2 ++ 8 files changed, 41 insertions(+), 13 deletions(-) commit caa36ed7ba82caa9f685dd04aa10d0bf87ea8b6a Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 19 19:00:27 2016 -0300 perf trace: Only auto set call-graph to "dwarf" when syscalls are being traced When --min-stack or --max-stack is passwd but --no-syscalls is also in effect, there is no point in automatically setting '--call-graph dwarf'. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-pq922i7h9wef0pho1dqpttvn@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7e4c1498130d7b6c26e6669839af4c7e321c9fec Author: Chris Ryder <chris.ryder@arm.com> Date: Thu May 19 17:59:46 2016 +0100 perf annotate: Sort list of recognised instructions Currently the list of instructions recognised by perf annotate has to be explicitly written in sorted order. This makes it easy to make mistakes when adding new instructions. Sort the list of instructions on first access. Signed-off-by: Chris Ryder <chris.ryder@arm.com> Acked-by: Pawel Moll <pawel.moll@arm.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Will Deacon <will.deacon@arm.com> Link: http://lkml.kernel.org/r/4268febaf32f47f322c166fb2fe98cfec7041e11.1463676839.git.chris.ryder@arm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/annotate.c | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) commit 58c0400176b2cd35da43f3115fa94ca937483aca Author: Chris Ryder <chris.ryder@arm.com> Date: Thu May 19 17:59:45 2016 +0100 perf annotate: Fix identification of ARM blt and bls instructions The ARM blt and bls instructions are not correctly identified when parsing assembly because the list of recognised instructions must be sorted by name. Swap the ordering of blt and bls. Signed-off-by: Chris Ryder <chris.ryder@arm.com> Acked-by: Pawel Moll <pawel.moll@arm.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Will Deacon <will.deacon@arm.com> Link: http://lkml.kernel.org/r/560e196b7c79b7ff853caae13d8719a31479cb1a.1463676839.git.chris.ryder@arm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/annotate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe176085a4d45fb241c04beea872ecbb8bef6a55 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 19 11:34:06 2016 -0300 perf tools: Fix usage of max_stack sysctl We cannot limit processing stacks from the current value of the sysctl, as we may be processing perf.data files, possibly from other machines. Instead use the old PERF_MAX_STACK_DEPTH, the sysctl default, that can be overriden using --max-stack or equivalent. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Fixes: 4cb93446c587 ("perf tools: Set the maximum allowed stack from /proc/sys/kernel/perf_event_max_stack") Link: http://lkml.kernel.org/n/tip-eqeutsr7n7wy0c36z24ytvii@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-report.txt | 2 +- tools/perf/Documentation/perf-script.txt | 2 +- tools/perf/Documentation/perf-trace.txt | 3 ++- tools/perf/builtin-report.c | 2 +- tools/perf/builtin-script.c | 2 -- tools/perf/builtin-trace.c | 2 +- tools/perf/util/db-export.c | 3 +-- tools/perf/util/scripting-engines/trace-event-perl.c | 3 +-- 8 files changed, 8 insertions(+), 11 deletions(-) commit bf8bddbf1971d40549f33bc6f70623cf53bbfa2f Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 19 11:14:15 2016 -0300 perf callchain: Stop validating callchains by the max_stack sysctl As thread__resolve_callchain_sample can be used for handling perf.data files, that could've been recorded with a large max_stack sysctl setting than what the system used for analysis has set. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/n/tip-2995bt2g5yq2m05vga4kip6m@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/machine.c | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) commit c008f78f9309a3be3548e11f48b8dfb08f2eb8fc Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 17 12:13:54 2016 -0300 perf trace: Fix exit_group() formatting This doesn't return, so there is no raw_syscalls:sys_exit for it, add the ending ')', without any return value, since it is void. Reported-by: Ingo Molnar <mingo@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-vh2mii0g4qlveuc4joufbipu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e77a07425f4391da2f08b0f9a09df4e70626204d Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 17 11:58:52 2016 -0300 perf top: Use machine->kptr_restrict_warned Its now there, no need to have it too. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-y18oeou494uy11im7u9to0dx@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-top.c | 6 +++--- tools/perf/util/top.h | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) commit caf8a0d0499792ac1b3f5b0b84e5890df0039cb6 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 17 11:56:24 2016 -0300 perf trace: Warn when trying to resolve kernel addresses with kptr_restrict=1 Hook into the libtraceevent plugin kernel symbol resolver to warn the user that that can't happen with kptr_restrict=1. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-9gc412xx1gl0lvqj1d1xwlyb@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 20 +++++++++++++++++++- tools/perf/util/machine.c | 1 + tools/perf/util/machine.h | 1 + 3 files changed, 21 insertions(+), 1 deletion(-) commit 45e90056904b12d8dd74e0d2ea6dfd5e4394104d Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 17 11:52:26 2016 -0300 perf machine: Do not bail out if not managing to read ref reloc symbol This means the user can't access /proc/kallsyms, for instance, because /proc/sys/kernel/kptr_restrict is set to 1. Instead leave the ref_reloc_sym as NULL and code using it will cope. This allows 'perf trace' to work on such systems for !root, the only issue would be when trying to resolve kernel symbols, which happens, for instance, in some libtracevent plugins. A warning for that case will be provided in the next patch in this series. Noticed in Ubuntu 16.04, that comes with kptr_restrict=1. Reported-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-knpu3z4iyp2dxpdfm798fac4@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/machine.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 35a2d58588f0992627e74b447ccab21570544c86 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Fri May 20 15:25:28 2016 +0200 KVM: arm/arm64: vgic-new: Synchronize changes to active state When modifying the active state of an interrupt via the MMIO interface, we should ensure that the write has the intended effect. If a guest sets an interrupt to active, but that interrupt is already flushed into a list register on a running VCPU, then that VCPU will write the active state back into the struct vgic_irq upon returning from the guest and syncing its state. This is a non-benign race, because the guest can observe that an interrupt is not active, and it can have a reasonable expectations that other VCPUs will not ack any IRQs, and then set the state to active, and expect it to stay that way. Currently we are not honoring this case. Thefore, change both the SACTIVE and CACTIVE mmio handlers to stop the world, change the irq state, potentially queue the irq if we're setting it to active, and then continue. We take this chance to slightly optimize these functions by not stopping the world when touching private interrupts where there is inherently no possible race. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/include/asm/kvm_host.h | 2 + arch/arm/kvm/arm.c | 8 ++- arch/arm64/include/asm/kvm_host.h | 2 + virt/kvm/arm/vgic/vgic-mmio.c | 105 ++++++++++++++++++++++++-------------- 4 files changed, 77 insertions(+), 40 deletions(-) commit e5bbf30733f930a1d17b4ccf19eac88e30a39cc7 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Thu May 19 15:25:42 2016 +0200 mmc: sdhci-acpi: Ensure connected devices are powered when probing Some devices connected to the SDHCI controller may have separate enabling lines that are controlled through GPIO. These devices need to be powered on and enabled before probing. This is to ensure all devices connected can be seen by the controller. Note, for "stable" this patch depends on the following change: commit 78a898d0e395 ("ACPI / PM: Export acpi_device_fix_up_power()") Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Reported-and-tested-by: Laszlo Fiat <laszlo.fiat@gmail.com> Cc: <stable@vger.kernel.org> # 4.5+ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reported-by: Laszlo Fiat <laszlo.fiat@gmail.com> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=112571 Link: http://lkml.kernel.org/r/CA+7w51inLtQSr656bJvOjGG9oQWKYPXH+xxDPJKbeJ=CcrkS9Q@mail.gmail.com drivers/mmc/host/sdhci-acpi.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 78a898d0e39513469858de990de83210fee28ee9 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu May 19 15:25:41 2016 +0200 ACPI / PM: Export acpi_device_fix_up_power() Drivers that needs acpi_device_fix_up_power(), allow them to be built as modules by exporting this function. Cc: <stable@vger.kernel.org> # 4.5+ Tested-by: Laszlo Fiat <laszlo.fiat@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/device_pm.c | 1 + 1 file changed, 1 insertion(+) commit efffe55af5e16f7935aa0175cf25c386f08219f5 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Mar 16 15:06:41 2016 +0000 KVM: arm/arm64: vgic-new: enable build Now that the new VGIC implementation has reached feature parity with the old one, add the new files to the build system and add a Kconfig option to switch between the two versions. We set the default to the new version to get maximum test coverage, in case people experience problems they can switch back to the old behaviour if needed. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/kvm/Kconfig | 7 +++++++ arch/arm/kvm/Makefile | 11 +++++++++++ arch/arm64/kvm/Kconfig | 7 +++++++ arch/arm64/kvm/Makefile | 12 ++++++++++++ virt/kvm/arm/hyp/vgic-v2-sr.c | 5 +++++ 5 files changed, 42 insertions(+) commit 568e8c901eaa62004640cad8b9773819f27461a0 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 22 00:52:33 2015 +0000 KVM: arm/arm64: vgic-new: implement mapped IRQ handling We now store the mapped hardware IRQ number in our struct, so we don't need the irq_phys_map for the new VGIC. Implement the hardware IRQ mapping on top of the reworked arch timer interface. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 5 +++++ virt/kvm/arm/vgic/vgic.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 58 insertions(+) commit 03f0c94c73b9d7d55e057e4035cf3127ac44d41e Author: Andre Przywara <andre.przywara@arm.com> Date: Fri Mar 25 00:04:53 2016 +0000 KVM: arm/arm64: vgic-new: Wire up irqfd injection Connect to the new VGIC to the irqfd framework, so that we can inject IRQs. GSI routing and MSI routing is not yet implemented. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-irqfd.c | 52 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) commit f7b6985cc3d0f0f6f35990301d80d858c148e10c Author: Eric Auger <eric.auger@linaro.org> Date: Wed Dec 2 10:30:13 2015 +0100 KVM: arm/arm64: vgic-new: Add vgic_v2/v3_enable Enable the VGIC operation by properly initialising the registers in the hypervisor GIC interface. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-v2.c | 11 ++++++++++- virt/kvm/arm/vgic/vgic-v3.c | 23 ++++++++++++++++++++++- 2 files changed, 32 insertions(+), 2 deletions(-) commit b0442ee227e826afc4df16cdfb8bd6eef6a8f425 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 15:04:42 2015 +0100 KVM: arm/arm64: vgic-new: vgic_init: implement map_resources map_resources is the last initialization step. It is executed on first VCPU run. At that stage the code checks that userspace has provided the base addresses for the relevant VGIC regions, which depend on the type of VGIC that is exposed to the guest. Also we check if the two regions overlap. If the checks succeeded, we register the respective register frames with the kvm_io_bus framework. If we emulate a GICv2, the function also forces vgic_init execution if it has not been executed yet. Also we map the virtual GIC CPU interface onto the guest's CPU interface. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 1 + virt/kvm/arm/vgic/vgic-init.c | 28 +++++++++++++++++ virt/kvm/arm/vgic/vgic-v2.c | 69 +++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-v3.c | 71 +++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 7 +++++ 5 files changed, 176 insertions(+) commit ad275b8bb1e659b14120174d87e3c1fdc22e9978 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 18:09:38 2015 +0100 KVM: arm/arm64: vgic-new: vgic_init: implement vgic_init This patch allocates and initializes the data structures used to model the vgic distributor and virtual cpu interfaces. At that stage the number of IRQs and number of virtual CPUs is frozen. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 7 +- virt/kvm/arm/vgic/vgic-init.c | 217 ++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-v2.c | 5 + virt/kvm/arm/vgic/vgic-v3.c | 5 + virt/kvm/arm/vgic/vgic.c | 4 + virt/kvm/arm/vgic/vgic.h | 8 ++ 6 files changed, 245 insertions(+), 1 deletion(-) commit 5e6431da8f3a04759ac8d77b7c98eec0de580343 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 14:50:50 2015 +0100 KVM: arm/arm64: vgic-new: vgic_init: implement vgic_create This patch implements the vgic_creation function which is called on CREATE_IRQCHIP VM IOCTL (v2 only) or KVM_CREATE_DEVICE Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 1 + virt/kvm/arm/vgic/vgic-init.c | 84 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 85 insertions(+) commit 909777324588b40d431e6e3af0911ee62e0d00e3 Author: Eric Auger <eric.auger@linaro.org> Date: Tue Dec 1 15:02:35 2015 +0100 KVM: arm/arm64: vgic-new: vgic_init: implement kvm_vgic_hyp_init Implements kvm_vgic_hyp_init and vgic_probe function. This uses the new firmware independent VGIC probing to support both ACPI and DT based systems (code from Marc Zyngier). The vgic_global struct is enriched with new fields populated by those functions. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 1 + virt/kvm/arm/vgic/vgic-init.c | 123 ++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-v2.c | 64 ++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-v3.c | 49 +++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 9 ++++ 5 files changed, 246 insertions(+) commit 878c569e45066a76a2a841dab965e6d22c4e187e Author: Andre Przywara <andre.przywara@arm.com> Date: Thu Dec 3 11:48:42 2015 +0000 KVM: arm/arm64: vgic-new: Add userland GIC CPU interface access Using the VMCR accessors we provide access to GIC CPU interface state to userland by wiring it up to the existing userland interface. [Marc: move and make VMCR accessors static, streamline MMIO handlers] Signed-off-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 2 +- virt/kvm/arm/vgic/vgic-mmio-v2.c | 114 +++++++++++++++++++++++++++++++++++- virt/kvm/arm/vgic/vgic.h | 2 + 3 files changed, 116 insertions(+), 2 deletions(-) commit e4823a7a1b4a4f2549dd223f243779ab9510db22 Author: Andre Przywara <andre.przywara@arm.com> Date: Thu Dec 3 11:47:37 2015 +0000 KVM: arm/arm64: vgic-new: Add GICH_VMCR accessors Since the GIC CPU interface is always virtualized by the hardware, we don't have CPU interface state information readily available in our emulation if userland wants to save or restore it. Fortunately the GIC hypervisor interface provides the VMCR register to access the required virtual CPU interface bits. Provide wrappers for GICv2 and GICv3 hosts to have access to this register. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-v2.c | 29 +++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-v3.c | 22 ++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 21 +++++++++++++++++++++ 3 files changed, 72 insertions(+) commit 7d450e2821710718fd6703e9c486249cee913bab Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 22:36:37 2015 +0000 KVM: arm/arm64: vgic-new: Add userland access to VGIC dist registers Userland may want to save and restore the state of the in-kernel VGIC, so we provide the code which takes a userland request and translate that into calls to our MMIO framework. From Christoffer: When accessing the VGIC state from userspace we really don't want a VCPU to be messing with the state at the same time, and the API specifies that we should return -EBUSY if any VCPUs are running. Check and prevent VCPUs from running by grabbing their mutexes, one by one, and error out if we fail. (Note: This could potentially be simplified to just do a simple check and see if any VCPUs are running, and return -EBUSY then, without enforcing the locking throughout the duration of the uaccess, if we think that taking/releasing all these mutexes for every single GIC register access is too heavyweight.) Signed-off-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 55 ++++++++++++++++++++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) commit c3199f28e09496aa9fec9313b4f6e90e7dc913f0 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Mon Apr 25 01:11:37 2016 +0200 KVM: arm/arm64: vgic-new: Export register access interface Userland can access the emulated GIC to save and restore its state for initialization or migration purposes. The kvm_io_bus API requires an absolute gpa, which does not fit the KVM_DEV_ARM_VGIC_GRP_DIST_REGS user API, that only provides relative offsets. So we provide a wrapper to plug into our MMIO framework and find the respective register handler. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> virt/kvm/arm/vgic/vgic-mmio-v2.c | 36 ++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 2 ++ 2 files changed, 38 insertions(+) commit f94591e2e6fdca6e9a2cbf23e36a8803b4f605fe Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 17:34:52 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: access to VGIC registers This patch implements the switches for KVM_DEV_ARM_VGIC_GRP_DIST_REGS and KVM_DEV_ARM_VGIC_GRP_CPU_REGS API which allows the userspace to access VGIC registers. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 53 +++++++++++++++++++++++++++++++++++-- virt/kvm/arm/vgic/vgic-mmio-v2.c | 38 ++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 1 + 3 files changed, 90 insertions(+), 2 deletions(-) commit e5c3029467cfa0acd89cfbd9cee1ae848e5eb8b0 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 17:27:39 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: KVM_DEV_ARM_VGIC_GRP_ADDR This patch implements the KVM_DEV_ARM_VGIC_GRP_ADDR group which enables to set the base address of GIC regions as seen by the guest. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 38 +++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit e2c1f9abff83ee0ad0f78e03918c7edf070edb39 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 16:36:04 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: implement kvm_vgic_addr kvm_vgic_addr is used by the userspace to set the base address of the following register regions, as seen by the guest: - distributor(v2 and v3), - re-distributors (v3), - CPU interface (v2). Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 2 + virt/kvm/arm/vgic/vgic-kvm-device.c | 86 +++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 3 ++ 3 files changed, 91 insertions(+) commit afcc7c50ce6e2fb18fd0535813c1d612265b1899 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 17:22:05 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: KVM_DEV_ARM_VGIC_GRP_CTRL This patch implements the KVM_DEV_ARM_VGIC_GRP_CTRL group API featuring KVM_DEV_ARM_VGIC_CTRL_INIT attribute. The vgic_init function is not yet implemented though. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit fca256026bb0d78991f975a7d4a3f601b7234401 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 21 16:33:22 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: KVM_DEV_ARM_VGIC_GRP_NR_IRQS This patch implements the KVM_DEV_ARM_VGIC_GRP_NR_IRQS group. This modality is supported by both VGIC V2 and V3 KVM device as will be other groups, hence the introduction of common helpers. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 83 +++++++++++++++++++++++++++++++++++-- 1 file changed, 79 insertions(+), 4 deletions(-) commit c86c772191d7e65f873e6908e9604b31168936cd Author: Eric Auger <eric.auger@linaro.org> Date: Mon Nov 30 14:01:58 2015 +0100 KVM: arm/arm64: vgic-new: vgic_kvm_device: KVM device ops registration This patch introduces the skeleton for the KVM device operations associated to KVM_DEV_TYPE_ARM_VGIC_V2 and KVM_DEV_TYPE_ARM_VGIC_V3. At that stage kvm_vgic_create is stubbed. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-kvm-device.c | 108 ++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 2 + 2 files changed, 110 insertions(+) commit 621ecd8d2123bc13e140b519e01a18200aeb614c Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Jan 26 15:31:15 2016 +0000 KVM: arm/arm64: vgic-new: Add GICv3 SGI system register trap handler In contrast to GICv2 SGIs in a GICv3 implementation are not triggered by a MMIO write, but with a system register write. KVM knows about that register already, we just need to implement the handler and wire it up to the core KVM/ARM code. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 8 +++ virt/kvm/arm/vgic/vgic-mmio-v3.c | 106 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 114 insertions(+) commit 78a714aba030395e72d03f0ff8a4c1481956e808 Author: Andre Przywara <andre.przywara@arm.com> Date: Mon Jan 25 16:45:37 2016 +0000 KVM: arm/arm64: vgic-new: Add GICv3 IROUTER register handlers Since GICv3 supports much more than the 8 CPUs the GICv2 ITARGETSR register can handle, the new IROUTER register covers the whole range of possible target (V)CPUs by using the same MPIDR that the cores report themselves. In addition to translating this MPIDR into a vcpu pointer we store the originally written value as well. The architecture allows to write any values into the register, which must be read back as written. Since we don't support affinity level 3, we don't need to take care about the upper word of this 64-bit register, which simplifies the handling a bit. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v3.c | 41 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) commit 54f59d2b3a0a3d4e6f5038f5831aedb21350209d Author: Andre Przywara <andre.przywara@arm.com> Date: Fri Jan 22 18:18:52 2016 +0000 KVM: arm/arm64: vgic-new: Add GICv3 IDREGS register handler We implement the only one ID register that is required by the architecture, also this is the one that Linux actually checks. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v3.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) commit 741972d8a69ce748d84dfe0d68403054dfcae657 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Jan 27 14:54:46 2016 +0000 KVM: arm/arm64: vgic-new: Add GICv3 redistributor IIDR and TYPER handler The redistributor TYPER tells the OS about the associated MPIDR, also the LAST bit is crucial to determine the number of redistributors. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v3.c | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) commit fd59ed3be17e414aa3400f35d0f5faa01dd74185 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Jan 27 14:54:30 2016 +0000 KVM: arm/arm64: vgic-new: Add GICv3 CTLR, IIDR, TYPER handlers As in the GICv2 emulation we handle those three registers in one function. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v3.c | 48 +++++++++++++++++++++++++++++++++++++++- virt/kvm/arm/vgic/vgic.h | 1 + 2 files changed, 48 insertions(+), 1 deletion(-) commit ed9b8cefa91695119e634979db6090d0700a21f8 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 14:34:34 2015 +0000 KVM: arm/arm64: vgic-new: Add GICv3 MMIO handling framework Create a new file called vgic-mmio-v3.c and describe the GICv3 distributor and redistributor registers there. This adds a special macro to deal with the split of SGI/PPI in the redistributor and SPIs in the distributor, which allows us to reuse the existing GICv2 handlers for those registers which are compatible. Also we provide a function to deal with the registration of the two separate redistributor frames per VCPU. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v3.c | 224 +++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.c | 5 + virt/kvm/arm/vgic/vgic-mmio.h | 2 + virt/kvm/arm/vgic/vgic.h | 7 ++ 4 files changed, 238 insertions(+) commit ed40213ef9b02b0f5e9e1807c45ee45407765a27 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Dec 9 16:21:37 2015 +0000 KVM: arm/arm64: vgic-new: Add SGIPENDR register handlers As this register is v2 specific, its implementation lives entirely in vgic-mmio-v2.c. This register allows setting the source mask of an IPI. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 62 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 60 insertions(+), 2 deletions(-) commit 55cc01fb9004ea93345f30aa26a3c3fc22d4f46a Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 12:42:05 2015 +0000 KVM: arm/arm64: vgic-new: Add SGIR register handler Triggering an IPI via this register is v2 specific, so the implementation lives entirely in vgic-mmio-v2.c. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 43 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) commit 2c234d6f18267614aaa9b0e9148a7daa6e2b234d Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 12:41:55 2015 +0000 KVM: arm/arm64: vgic-new: Add TARGET registers handlers The target register handlers are v2 emulation specific, so their implementation lives entirely in vgic-mmio-v2.c. We copy the old VGIC behaviour of assigning an IRQ to the first VCPU set in the target mask instead of making it possibly pending on multiple VCPUs. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 43 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) commit 79717e4ac09c7c0c1414a3338fec457d982e9dd8 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 12:41:31 2015 +0000 KVM: arm/arm64: vgic-new: Add CONFIG registers handlers The config register handlers are shared between the v2 and v3 emulation, so their implementation goes into vgic-mmio.c, to be easily referenced from the v3 emulation as well later. Signed-off-by: Andre Przywara <andre.przywara@arm.com> virt/kvm/arm/vgic/vgic-mmio-v2.c | 2 +- virt/kvm/arm/vgic/vgic-mmio.c | 47 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 7 ++++++ 3 files changed, 55 insertions(+), 1 deletion(-) commit 055658bf48fcc6afdf90810e7e8f4e98f486c0d2 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 14:34:02 2015 +0000 KVM: arm/arm64: vgic-new: Add PRIORITY registers handlers The priority register handlers are shared between the v2 and v3 emulation, so their implementation goes into vgic-mmio.c, to be easily referenced from the v3 emulation as well later. There is a corner case when we change the priority of a pending interrupt which we don't handle at the moment. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 2 +- virt/kvm/arm/vgic/vgic-mmio.c | 40 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 7 +++++++ virt/kvm/arm/vgic/vgic.h | 2 ++ 4 files changed, 50 insertions(+), 1 deletion(-) commit 69b6fe0c6e7f560165d655bbb127f8d69b7358ea Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 12:40:58 2015 +0000 KVM: arm/arm64: vgic-new: Add ACTIVE registers handlers The active register handlers are shared between the v2 and v3 emulation, so their implementation goes into vgic-mmio.c, to be easily referenced from the v3 emulation as well later. Since activation/deactivation of an interrupt may happen entirely in the guest without it ever exiting, we need some extra logic to properly track the active state. For clearing the active state, we basically have to halt the guest to make sure this is properly propagated into the respective VCPUs. Signed-off-by: Andre Przywara <andre.przywara@arm.com> virt/kvm/arm/vgic/vgic-mmio-v2.c | 4 +- virt/kvm/arm/vgic/vgic-mmio.c | 81 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 10 +++++ 3 files changed, 93 insertions(+), 2 deletions(-) commit 96b298000db48360e49a1f8f9edc6d2b9c1b2548 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 14:33:41 2015 +0000 KVM: arm/arm64: vgic-new: Add PENDING registers handlers The pending register handlers are shared between the v2 and v3 emulation, so their implementation goes into vgic-mmio.c, to be easily referenced from the v3 emulation as well later. For level triggered interrupts the real line level is unaffected by this write, so we keep this state separate and combine it with the device's level to get the actual pending state. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 4 +-- virt/kvm/arm/vgic/vgic-mmio.c | 60 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 12 ++++++++ 3 files changed, 74 insertions(+), 2 deletions(-) commit fd122e620983003c376aca56892ac14a34a38d57 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Dec 1 14:33:05 2015 +0000 KVM: arm/arm64: vgic-new: Add ENABLE registers handlers As the enable register handlers are shared between the v2 and v3 emulation, their implementation goes into vgic-mmio.c, to be easily referenced from the v3 emulation as well later. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 4 +-- virt/kvm/arm/vgic/vgic-mmio.c | 56 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 11 ++++++++ 3 files changed, 69 insertions(+), 2 deletions(-) commit 2b0cda8789654bfcebca397daebc37aff081bd75 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Tue Apr 26 11:06:47 2016 +0100 KVM: arm/arm64: vgic-new: Add CTLR, TYPER and IIDR handlers Those three registers are v2 emulation specific, so their implementation lives entirely in vgic-mmio-v2.c. Also they are handled in one function, as their implementation is pretty simple. When the guest enables the distributor, we kick all VCPUs to get potentially pending interrupts serviced. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/linux/irqchip/arm-gic.h | 1 + virt/kvm/arm/vgic/vgic-mmio-v2.c | 46 +++++++++++++++++++++++++++++++++++++++- virt/kvm/arm/vgic/vgic.c | 15 +++++++++++++ virt/kvm/arm/vgic/vgic.h | 4 ++++ 4 files changed, 65 insertions(+), 1 deletion(-) commit fb848db39661a1243f6ae939ef7e9251a765b972 Author: Andre Przywara <andre.przywara@arm.com> Date: Tue Apr 26 21:32:49 2016 +0100 KVM: arm/arm64: vgic-new: Add GICv2 MMIO handling framework Create vgic-mmio-v2.c to describe GICv2 emulation specific handlers using the initializer macros provided by the VGIC MMIO framework. Provide a function to register the GICv2 distributor registers to the kvm_io_bus framework. The actual handler functions are still stubs in this patch. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic/vgic-mmio-v2.c | 76 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.c | 26 ++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 2 ++ virt/kvm/arm/vgic/vgic.h | 2 ++ 4 files changed, 106 insertions(+) commit 4493b1c4866a03963a35be7d157c911a617a3694 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Tue Apr 26 11:06:12 2016 +0100 KVM: arm/arm64: vgic-new: Add MMIO handling framework Add an MMIO handling framework to the VGIC emulation: Each register is described by its offset, size (or number of bits per IRQ, if applicable) and the read/write handler functions. We provide initialization macros to describe each GIC register later easily. Separate dispatch functions for read and write accesses are connected to the kvm_io_bus framework and binary-search for the responsible register handler based on the offset address within the region. We convert the incoming data (referenced by a pointer) to the host's endianess and use pass-by-value to hand the data over to the actual handler functions. The register handler prototype and the endianess conversion are courtesy of Christoffer Dall. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 13 +++ virt/kvm/arm/vgic/vgic-mmio.c | 184 ++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic-mmio.h | 99 +++++++++++++++++++++++ 3 files changed, 296 insertions(+) commit 90eee56c5f9081686035972dfcddfd6c85cafdf9 Author: Eric Auger <eric.auger@linaro.org> Date: Mon Dec 7 15:30:38 2015 +0000 KVM: arm/arm64: vgic-new: Implement kvm_vgic_vcpu_pending_irq Tell KVM whether a particular VCPU has an IRQ that needs handling in the guest. This is used to decide whether a VCPU is runnable. Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> include/kvm/vgic/vgic.h | 2 ++ virt/kvm/arm/vgic/vgic.c | 25 +++++++++++++++++++++++++ 2 files changed, 27 insertions(+) commit 59529f69f5048e50dcde3434661981c01f8208b4 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Nov 30 13:09:53 2015 +0000 KVM: arm/arm64: vgic-new: Add GICv3 world switch backend As the GICv3 virtual interface registers differ from their GICv2 siblings, we need different handlers for processing maintenance interrupts and reading/writing to the LRs. Implement the respective handler functions and connect them to existing code to be called if the host is using a GICv3. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/linux/irqchip/arm-gic-v3.h | 1 + virt/kvm/arm/vgic/vgic-v3.c | 162 +++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.c | 25 ++++-- virt/kvm/arm/vgic/vgic.h | 29 +++++++ 4 files changed, 212 insertions(+), 5 deletions(-) commit 140b086dd19771410915a924db2e635c2b51a0f4 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Thu Nov 26 17:19:25 2015 +0000 KVM: arm/arm64: vgic-new: Add GICv2 world switch backend Processing maintenance interrupts and accessing the list registers are dependent on the host's GIC version. Introduce vgic-v2.c to contain GICv2 specific functions. Implement the GICv2 specific code for syncing the emulation state into the VGIC registers. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/linux/irqchip/arm-gic.h | 1 + virt/kvm/arm/vgic/vgic-v2.c | 176 ++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.c | 6 ++ virt/kvm/arm/vgic/vgic.h | 6 ++ 4 files changed, 189 insertions(+) commit 0919e84c0fc1fc73525fdcedefab89ea8460f697 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Thu Nov 26 17:19:25 2015 +0000 KVM: arm/arm64: vgic-new: Add IRQ sync/flush framework Implement the framework for syncing IRQs between our emulation and the list registers, which represent the guest's view of IRQs. This is done in kvm_vgic_flush_hwstate and kvm_vgic_sync_hwstate, which gets called on guest entry and exit. The code talking to the actual GICv2/v3 hardware is added in the following patches. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/vgic/vgic.h | 4 + virt/kvm/arm/vgic/vgic.c | 192 +++++++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 2 + 3 files changed, 198 insertions(+) commit 8e4447457965a7ddc576d0b9fd34c9905eb0416d Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed Nov 25 10:02:16 2015 -0800 KVM: arm/arm64: vgic-new: Add IRQ sorting Adds the sorting function to cover the case where you have more IRQs to consider than you have LRs. We now consider priorities. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> virt/kvm/arm/vgic/vgic.c | 57 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit 81eeb95ddbabbb998a6b39f762bc7edaa2a979b4 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed Nov 25 10:02:16 2015 -0800 KVM: arm/arm64: vgic-new: Implement virtual IRQ injection Provide a vgic_queue_irq_unlock() function which decides whether a given IRQ needs to be queued to a VCPU's ap_list. This should be called whenever an IRQ becomes pending or enabled, either as a result of userspace injection, from in-kernel emulated devices like the architected timer or from MMIO accesses to the distributor emulation. Also provides the necessary functions to allow userland to inject an IRQ to a guest. Since this is the first code that starts using our locking mechanism, we add some (hopefully) clear documentation of our locking strategy and requirements along with this patch. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> include/kvm/vgic/vgic.h | 3 + virt/kvm/arm/vgic/vgic.c | 211 +++++++++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 1 + 3 files changed, 215 insertions(+) commit 64a959d66e47039833e7f3c8d7e50fd4afa078ca Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Tue Nov 24 16:51:12 2015 +0100 KVM: arm/arm64: vgic-new: Add acccessor to new struct vgic_irq instance The new VGIC implementation centers around a struct vgic_irq instance per virtual IRQ. Provide a function to retrieve the right instance for a given IRQ number and (in case of private interrupts) the right VCPU. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Acked-by: Marc Zyngier <marc.zyngier@arm.com> virt/kvm/arm/vgic/vgic.c | 41 +++++++++++++++++++++++++++++++++++++++++ virt/kvm/arm/vgic/vgic.h | 22 ++++++++++++++++++++++ 2 files changed, 63 insertions(+) commit b18b57787f5e469b2825784ae3c522fc14472e97 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Mon Nov 23 07:20:05 2015 -0800 KVM: arm/arm64: vgic-new: Add data structure definitions Add a new header file for the new and improved GIC implementation. The big change is that we now have a struct vgic_irq per IRQ instead of spreading all the information over various bitmaps. We include this new header conditionally from within the old header file for the time being to avoid touching all the users. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> include/kvm/arm_vgic.h | 5 ++ include/kvm/vgic/vgic.h | 201 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 206 insertions(+) commit 44bfc42e94cd76a0bd44f3fce98d4a7b76f31bc0 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed May 4 14:35:48 2016 +0100 KVM: arm/arm64: move GICv2 emulation defines into arm-gic-v3.h As (some) GICv3 hosts can emulate a GICv2, some GICv2 specific masks for the list register definition also apply to GICv3 LRs. At the moment we have those definitions in the KVM VGICv3 implementation, so let's move them into the GICv3 header file to have them automatically defined. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> include/linux/irqchip/arm-gic-v3.h | 5 +++++ virt/kvm/arm/vgic-v3.c | 8 +------- 2 files changed, 6 insertions(+), 7 deletions(-) commit b13216cf6010ef482e69875e00711de7f9573c80 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed Apr 27 10:28:00 2016 +0100 KVM: arm/arm64: Provide functionality to pause and resume a guest For some rare corner cases in our VGIC emulation later we have to stop the guest to make sure the VGIC state is consistent. Provide the necessary framework to pause and resume a guest. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> arch/arm/include/asm/kvm_host.h | 4 ++++ arch/arm/kvm/arm.c | 25 +++++++++++++------------ arch/arm64/include/asm/kvm_host.h | 4 ++++ 3 files changed, 21 insertions(+), 12 deletions(-) commit 2defaff48aaf16072a6eac4cf8234917197dfa72 Author: Andre Przywara <andre.przywara@arm.com> Date: Mon Mar 7 17:32:29 2016 +0700 KVM: arm/arm64: pmu: abstract access to number of SPIs Currently the PMU uses a member of the struct vgic_dist directly, which not only breaks abstraction, but will fail with the new VGIC. Abstract this access in the VGIC header file and refactor the validity check in the PMU code. Signed-off-by: Andre Przywara <andre.przywara@arm.com> include/kvm/arm_vgic.h | 2 ++ virt/kvm/arm/pmu.c | 25 ++++++++++++++----------- 2 files changed, 16 insertions(+), 11 deletions(-) commit d5a5a0eff368f039ed2222b47c15f09cb60e1245 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Sun Apr 24 21:41:36 2016 +0200 KVM: arm/arm64: Export mmio_read/write_bus Rename mmio_{read,write}_bus to kvm_mmio_{read,write}_bus and export them out of mmio.c. This will be needed later for the new VGIC implementation. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Andre Przywara <andre.przywara@arm.com> arch/arm/include/asm/kvm_mmio.h | 3 +++ arch/arm/kvm/mmio.c | 10 +++++----- arch/arm64/include/asm/kvm_mmio.h | 3 +++ 3 files changed, 11 insertions(+), 5 deletions(-) commit 83091db981e105d97562d3ed3ffe676e21927e3a Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Tue Mar 29 14:29:28 2016 +0200 KVM: arm/arm64: Fix MMIO emulation data handling When the kernel was handling a guest MMIO read access internally, we need to copy the emulation result into the run->mmio structure in order for the kvm_handle_mmio_return() function to pick it up and inject the result back into the guest. Currently the only user of kvm_io_bus for ARM is the VGIC, which did this copying itself, so this was not causing issues so far. But with the upcoming new vgic implementation we need this done properly. Update the kvm_handle_mmio_return description and cleanup the code to only perform a single copying when needed. Code and commit message inspired by Andre Przywara. Reported-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Andre Przywara <andre.przywara@arm.com> arch/arm/kvm/mmio.c | 14 +++++++------- virt/kvm/arm/vgic.c | 7 ------- 2 files changed, 7 insertions(+), 14 deletions(-) commit 2db4c104fa2a9af12c07433642e2e4fee37fe2fd Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed Apr 6 14:48:53 2016 +0200 KVM: arm/arm64: Get rid of vgic_cpu->nr_lr The number of list registers is a property of the underlying system, not of emulated VGIC CPU interface. As we are about to move this variable to global state in the new vgic for clarity, move it from the legacy implementation as well to make the merge of the new code easier. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Andre Przywara <andre.przywara@arm.com> include/kvm/arm_vgic.h | 3 --- virt/kvm/arm/hyp/vgic-v2-sr.c | 12 +++++++----- virt/kvm/arm/vgic-v2.c | 4 +++- virt/kvm/arm/vgic.c | 12 ++---------- 4 files changed, 12 insertions(+), 19 deletions(-) commit 41a54482c010d8806cf56e1501bb3b61fac14cf9 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Wed May 18 16:26:00 2016 +0100 KVM: arm/arm64: Move timer IRQ map to latest possible time We are about to modify the VGIC to allocate all data structures dynamically and store mapped IRQ information on a per-IRQ struct, which is indeed allocated dynamically at init time. Therefore, we cannot record the mapped IRQ info from the timer at timer reset time like it's done now, because VCPU reset happens before timer init. A possible later time to do this is on the first run of a per VCPU, it just requires us to move the enable state to be a per-VCPU state and do the lookup of the physical IRQ number when we are about to run the VCPU. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> arch/arm/kvm/arm.c | 6 ++-- include/kvm/arm_arch_timer.h | 8 +++--- virt/kvm/arm/arch_timer.c | 66 +++++++++++++++++++++++++------------------- virt/kvm/arm/hyp/timer-sr.c | 5 ++-- 4 files changed, 47 insertions(+), 38 deletions(-) commit c8eb3f6b9bc31abc0ab3230737fde1639c8b1ea6 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 11:49:07 2016 +0100 KVM: arm/arm64: vgic: Remove irq_phys_map from interface Now that the virtual arch timer does not care about the irq_phys_map anymore, let's rework kvm_vgic_map_phys_irq() to return an error value instead. Any reference to that mapping can later be done by passing the correct combination of VCPU and virtual IRQ number. This makes the irq_phys_map handling completely private to the VGIC code. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_vgic.h | 3 +-- virt/kvm/arm/arch_timer.c | 7 +------ virt/kvm/arm/vgic.c | 15 +++++++-------- 3 files changed, 9 insertions(+), 16 deletions(-) commit a7e33ad9b25552b75a2523cc598db8bcd218ede5 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 11:03:02 2016 +0100 KVM: arm/arm64: arch_timer: Remove irq_phys_map Now that the interface between the arch timer and the VGIC does not require passing the irq_phys_map entry pointer anymore, let's remove it from the virtual arch timer and use the virtual IRQ number instead directly. The remaining pointer returned by kvm_vgic_map_phys_irq() will be removed in the following patch. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_arch_timer.h | 3 --- virt/kvm/arm/arch_timer.c | 10 ++++------ 2 files changed, 4 insertions(+), 9 deletions(-) commit b452cb52072d21f026e38ac7af36a969bab2ed22 Author: Christoffer Dall <christoffer.dall@linaro.org> Date: Sat Jun 4 15:41:00 2016 +0100 KVM: arm/arm64: Remove the IRQ field from struct irq_phys_map The communication of a Linux IRQ number from outside the VGIC to the vgic was a leftover from the day when the vgic code cared about how a particular device injects virtual interrupts mapped to a physical interrupt. We can safely remove this notion, leaving all physical IRQ handling to be done in the device driver (the arch timer in this case), which makes room for a saner API for the new VGIC. Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> include/kvm/arm_vgic.h | 3 +-- virt/kvm/arm/arch_timer.c | 23 +++++++++++++++++++++-- virt/kvm/arm/vgic.c | 28 ++++++---------------------- 3 files changed, 28 insertions(+), 26 deletions(-) commit 63306c28ac92bdf9e41aef367708d762f9f725f2 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 10:04:06 2016 +0100 KVM: arm/arm64: vgic: avoid map in kvm_vgic_unmap_phys_irq() kvm_vgic_unmap_phys_irq() only needs the virtual IRQ number, so let's just pass that between the arch timer and the VGIC to get rid of the irq_phys_map pointer. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_vgic.h | 2 +- virt/kvm/arm/arch_timer.c | 2 +- virt/kvm/arm/vgic.c | 11 ++++------- 3 files changed, 6 insertions(+), 9 deletions(-) commit e262f4193638fff2de458f0c70284f0cb50926a7 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 10:03:49 2016 +0100 KVM: arm/arm64: vgic: avoid map in kvm_vgic_map_is_active() For getting the active state of a mapped IRQ, we actually only need the virtual IRQ number, not the pointer to the mapping entry. Pass the virtual IRQ number from the arch timer to the VGIC directly. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_vgic.h | 2 +- virt/kvm/arm/arch_timer.c | 6 ++---- virt/kvm/arm/vgic.c | 6 +++--- 3 files changed, 6 insertions(+), 8 deletions(-) commit 4f551a3d96a2de85a041ee60e806bda1d5b06255 Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 09:48:02 2016 +0100 KVM: arm/arm64: vgic: avoid map in kvm_vgic_inject_mapped_irq() When we want to inject a hardware mapped IRQ into a guest, we actually only need the virtual IRQ number from the irq_phys_map. So let's pass this number directly from the arch timer to the VGIC to avoid using the map as a parameter. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_vgic.h | 2 +- virt/kvm/arm/arch_timer.c | 2 +- virt/kvm/arm/vgic.c | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) commit 7cbc084dc22ca4adb8fd741502e43f29b577abfb Author: Andre Przywara <andre.przywara@arm.com> Date: Wed Apr 13 09:43:59 2016 +0100 KVM: arm/arm64: vgic: streamline vgic_update_irq_pending() interface We actually don't use the irq_phys_map parameter in vgic_update_irq_pending(), so let's just remove it. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Eric Auger <eric.auger@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/vgic.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit e4fe9e7dc3828bf6a5714eb3c55aef6260d823a2 Author: Matt Evans <matt.evans@arm.com> Date: Mon May 16 13:54:56 2016 +0100 kvm: arm64: Fix EC field in inject_abt64 The EC field of the constructed ESR is conditionally modified by ORing in ESR_ELx_EC_DABT_LOW for a data abort. However, ESR_ELx_EC_SHIFT is missing from this condition. Signed-off-by: Matt Evans <matt.evans@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Cc: <stable@vger.kernel.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm64/kvm/inject_fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3497610a45d15bd33d1993ddd84951ad21b35ded Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 20:11:30 2016 +0100 rtc: stmp3xxx: print message on error stmp3xxx_wdt_register() can fail as platform_device_alloc() or platform_device_add() can fail. But when it fails it failed silently. Lets print out an error message on failure so that user will atlest know that there was some error. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-stmp3xxx.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 6fca3fc51632685635cb7143065ae74d44673871 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Tue Apr 26 18:17:35 2016 -0400 rtc: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-cmos.c | 2 +- drivers/rtc/rtc-mrst.c | 2 +- drivers/rtc/rtc-rs5c372.c | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) commit b4b77f3c280e38cec178f81d7a4d7e65f4045913 Author: Qianyu Gong <qianyu.gong@nxp.com> Date: Thu Apr 21 14:55:40 2016 +0800 rtc: ds3232: fix call trace when rtc->ops_lock is used as NULL The rtc->ops_lock would be accessed in ds3232_irq() without being initialized as rtc_device_register() is called too late. So move devm_rtc_device_register() just before registering irq handler to initialize rtc->ops_lock earlier. Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com> Reviewed-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds3232.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit a350259da4b0556fcf276c506a14f406d608c2b3 Author: Stefan Agner <stefan@agner.ch> Date: Wed Apr 20 16:09:57 2016 -0700 rtc: snvs: return error in case enable_irq_wake fails If enable_irq_wake fails, we should return that error code so that entering suspend fails. Otherwise we will get a WARNING along with the hint of a unbalanced wake disable: Unbalanced IRQ 37 wake disable Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-snvs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b62c3a1158c0abc98e03c68934fa7ee6ca10dd49 Author: Anurag Kumar Vulisha <anurag.kumar.vulisha@xilinx.com> Date: Wed Apr 20 21:17:35 2016 +0530 rtc: zynqmp: Update seconds time programming logic We program RTC time using SET_TIME_WRITE register and read the RTC current time using CURRENT_TIME register. When we set the time by writing into SET_TIME_WRITE Register and immediately try to read the rtc time from CURRENT_TIME register, the previous old value is returned instead of the new loaded time. This is because RTC takes nearly 1 sec to update the new loaded value into the CURRENT_TIME register. This behaviour is expected in our RTC IP. This patch updates the driver to read the current time from SET_TIME_WRITE register instead of CURRENT_TIME when rtc time is requested within an 1sec period after setting the RTC time. Doing so will ensure the correct time is given to the user. Since there is a delay of 1sec in updating the CURRENT_TIME we are loading set time +1sec while programming the SET_TIME_WRITE register, doing this will give correct time without any delay when read from CURRENT_TIME. Signed-off-by: Anurag Kumar Vulisha <anuragku@xilinx.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-zynqmp.c | 45 +++++++++++++++++++++++++++++++++++++++------ 1 file changed, 39 insertions(+), 6 deletions(-) commit 01dc6992b3e888e7bf17691e4e86c9cc33e8f8b5 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:18 2016 +0200 rtc: sa1100: DT spelling s/interrupt-name/interrupt-names/ Fix typo in interrupt-names Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Documentation/devicetree/bindings/rtc/sa1100-rtc.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5333a4044d7b4af8bb01e031d0ee619e9ab86601 Author: Wolfram Sang <w.sang@pengutronix.de> Date: Wed May 4 17:31:26 2011 +0200 rtc: mc13xxx: remove UIE signaling The RTC core handles it since 6610e08 (RTC: Rework RTC code to use timerqueue for events). So far, only the callbacks to the RTC core have been removed, but not the handlers. Do this now. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-mc13xxx.c | 19 ------------------- 1 file changed, 19 deletions(-) commit 1726982f20ebb90f9b2fcdda6686e244f6af83e2 Author: Wolfram Sang <w.sang@pengutronix.de> Date: Wed May 4 17:31:28 2011 +0200 rtc: mxc: remove UIE signaling The RTC core handles it since 6610e08 (RTC: Rework RTC code to use timerqueue for events). Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-mxc.c | 3 --- 1 file changed, 3 deletions(-) commit 7457d5f588dfc038cef66e4645abbe9c06481504 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:15:48 2016 -0700 rtc: ds1307: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Akinobu Mita <akinobu.mita@gmail.com> Cc: Michael Tatarinov <kukabu@gmail.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1307.c | 2 -- 1 file changed, 2 deletions(-) commit bdcaace5ef99eeb112decfa739b4b16e709a677b Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:13:58 2016 -0700 rtc: hym8563: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-hym8563.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 74e1af3246dfb9840d99a18363dec4dc66ac9731 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:12:19 2016 -0700 rtc: pcf8563: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Heiko Schocher <hs@denx.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Heiko Schocher <hs@denx.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-pcf8563.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 58c4ed3ba2e0c97e33affd237dc05738fa55a725 Author: Anurag Kumar Vulisha <anurag.kumar.vulisha@xilinx.com> Date: Tue Apr 12 17:45:45 2016 +0530 rtc: zynqmp: Write Calibration value before setting time It is suggested to program CALIB_WRITE register with the calibration value before updating the SET_TIME_WRITE register, doing so will clear the Tick Counter and force the next second to be signaled exactly in 1 second. Signed-off-by: Anurag Kumar Vulisha <anuragku@xilinx.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-zynqmp.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) commit 9092984f1a8440ea52bf53c2d53bf8f5953a5126 Author: Anurag Kumar Vulisha <anurag.kumar.vulisha@xilinx.com> Date: Tue Apr 12 17:45:44 2016 +0530 rtc: zynqmp: Enable RTC switching to battery power when VCC_PSAUX is N/A In order to conserve battery energy, during the PS operation, it is expected that the supply for the battery-powered domain to be switched from the battery (VCC_PSBATT) to (VCC_PSAUX) and automatically be switched back to battery when VCC_PSAUX voltage drops below a limit, doing so prevents the logic within the battery-powered domain from functioning incorrectly. Signed-off-by: Anurag Kumar Vulisha <anuragku@xilinx.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-zynqmp.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 19105f424b803f32757abab5fb13eaac22b6481f Author: Josh Poimboeuf <jpoimboe@redhat.com> Date: Fri Apr 15 09:21:10 2016 -0500 rtc: ds1685: actually spin forever in poweroff path objtool reports the following warning: drivers/rtc/rtc-ds1685.o: warning: objtool: ds1685_rtc_poweroff() falls through to next function ds1685_rtc_work_queue() Similar to commit 361c6ed6b153 ("rtc: ds1685: actually spin forever in poweroff error path"), there's another unreachable() annotation which is actually reachable, which we missed the first time. Actually spin forever to be consistent with the comment and to make the unreachable() annotation guaranteed to be unreachable. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1685.c | 1 + 1 file changed, 1 insertion(+) commit 6406d96e74a59ae98cf3197a9f9498e14d2df562 Author: Steve Twiss <stwiss.opensource@diasemi.com> Date: Thu Apr 14 12:04:54 2016 +0100 rtc: da9053: fix access ordering error during RTC interrupt at system power on This fix alters the ordering of the IRQ and device registrations in the RTC driver probe function. This change will apply to the RTC driver that supports both DA9052 and DA9053 PMICs. A problem could occur with the existing RTC driver if: A system is started from a cold boot using the PMIC RTC IRQ to initiate a power on operation. For instance, if an RTC alarm is used to start a platform from power off. The existing driver IRQ is requested before the device has been properly registered. i.e. ret = da9052_request_irq() comes before rtc->rtc = devm_rtc_device_register(); In this case, an interrupt exists before the device has been registered and the IRQ handler can be called immediately: this can happen be before the memory for rtc->rtc has been allocated. The IRQ handler da9052_rtc_irq() contains the function call: rtc_update_irq(rtc->rtc, 1, RTC_IRQF | RTC_AF); which in turn tries to access the unavailable rtc->rtc. The fix is to reorder the functions inside the RTC probe. The IRQ is requested after the RTC device resource has been registered so that da9052_request_irq() is the last thing to happen. Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-da9052.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 5919fb97dd85e7ee200ab60151244cca62f61368 Author: Nicolas Boullis <nboullis@debian.org> Date: Sun Apr 10 13:23:05 2016 +0200 rtc: ds1307: ensure that any pending alarm is cleared before a new alarm is enabled If a previously-set alarm was disabled and then triggered, it may still be pending when a new alarm is configured. Then, if the alarm is enabled before the pending alarm is cleared, then an interrupt is immediately raised. Unfortunately, when the alarm is cleared and enabled during the same I²C block write, the chip (at least the DS1339 I have) considers that the alarm is enabled before it is cleared, and raises an interrupt. This patch ensures that the pending alarm is cleared before the alarm is enabled. Signed-off-by: Nicolas Boullis <nboullis@debian.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1307.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 1d87951c398e35118a0fb67b287022f008513f42 Author: Nicolas Boullis <nboullis@debian.org> Date: Sun Apr 3 00:10:37 2016 +0200 rtc: ds1307: fix ds1307_native_smbus_read_block_data function The i2c_smbus_read_i2c_block_data function returns 0 on success, not the number of bytes written. Hence, when there are 32 bytes or less to send, the ds1307_native_smbus_write_block_data function returns 0 on success, while it returns the number of bytes when there are more than 32. The ds1307_write_block_data always returns the number of bytes on success. Signed-off-by: Nicolas Boullis <nboullis@debian.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1307.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit ef50f86e15f2516658f0badd7890292d7a685106 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sun Apr 10 23:59:24 2016 +0900 rtc: ds1302: fix write value for day of week register The valid range of day of week register for DS1302 is 1 to 7. But the set_time callback for rtc-ds1302 attempts to write the value of tm->tm_wday which is in the range 0 to 6. While the get_time callback correctly decodes the register. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Sergey Yanovich <ynvich@gmail.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1302.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc83a141b8351f6d4458dd13eca5a66f2c0f3323 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sun Apr 10 23:59:23 2016 +0900 rtc: ds1302: fix error check in set_time The set_time callback for rtc-ds1302 doesn't write clock registers because the error check for the return value from spi_write_then_read() is not correct. spi_write_then_read() which returns zero on success. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Sergey Yanovich <ynvich@gmail.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1302.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 05a7f27a889f1635b7b7d5b051b17cacb25267fa Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:56:05 2016 +0200 rtc: m41t80: handle oscillator failure bit Handle the Oscillator Failure (OF) bit on each read of date-time. If the OF is set, an error is returned (-EINVAL) instead of the date-time. The OF bit is cleared each time the date is set. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) commit 3726a21833c9c96255735bddb5dacc8eacbff3ef Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:56:04 2016 +0200 rtc: m41t80: add wakealarm functionality To enable the wakealarm, the device must be able to wakeup. This is done by setting the device wakeup capability to true with 'device_init_wakeup' function. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 2 ++ 1 file changed, 2 insertions(+) commit 9c6dfed92c3e86d6f84780625c0595ba56d03986 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 11:04:13 2016 +0200 rtc: m41t80: add alarm functionality Previous 'commit c3b79770e51a ("Expire alarms after the time is set")' and 'commit 48e9766726eb ("remove disabled alarm functionality")' removed the alarm support because the alarm irq was not functional. Add the alarm IRQ functionality with newer functions than previous code. Tested with 'rtctest' and the alarm is functional. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 180 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 167 insertions(+), 13 deletions(-) commit fc99b90154e519dd6cd21cb11d013f36017a1b94 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:56:02 2016 +0200 rtc: m41t80: remove warnings and replace obsolete function Replace the obsolete "simple_strtoul" function to "kstrtoul". Remove some checkpatch's errors, warnings and checks : - alignment with open parenthesis - spaces around '<' and '<<' - blank line after structure - quoted string split across lines Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) commit 54339f3b311f1b2cbef7b84d6794e00e7ecb2184 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:56:01 2016 +0200 rtc: m41t80: add the use of 'BIT' macro Replace bit shifts by BIT macro. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit f2b84ee88d367dd563c25b6900da279ab2ffa3ea Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:56:00 2016 +0200 rtc: m41t80: replace i2c functions for smbus ones The driver used i2c_transfer methods to read and set date/time. The smbus methods should be used. This commit replaces i2c_transfer functions by i2c_smbus_XX_i2c_block_data for reading and setting the datetime. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 134 ++++++++++++++++------------------------------- 1 file changed, 44 insertions(+), 90 deletions(-) commit ca91607fe76cc34b54957f5963f7102b37b861dd Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:55:59 2016 +0200 rtc: m41t80: remove proc macro Remove the CONFIG_RTC_INTF_PROC and CONFIG_RTC_INTF_PROC_MODULE macro which is not necessary anymore. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 4 ---- 1 file changed, 4 deletions(-) commit ef6b3125ca6f4319e760dc27617025b8af58d9d3 Author: Mylène Josserand <mylene.josserand@free-electrons.com> Date: Tue Mar 29 08:55:58 2016 +0200 rtc: m41t80: update sysfs entries export The driver used an old sysfs entry export. Update it to use the DEVICE_ATTR_XX macro and remove the unnecessary CONFIG_RTC_INTF_SYSFS macro. Signed-off-by: Mylène Josserand <mylene.josserand@free-electrons.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-m41t80.c | 56 +++++++++++++++++++++++++++--------------------- 1 file changed, 32 insertions(+), 24 deletions(-) commit fa5691131a87a36ee2d535aa3e8886e4e4f1e9f3 Author: Alexandre Belloni <alexandre.belloni@free-electrons.com> Date: Thu Mar 31 15:07:26 2016 +0200 rtc: remove useless DRV_VERSION Many drivers are defining a DRV_VERSION. This is often only used for MODULE_VERSION and sometimes to print an info message at probe time. This is kind of pointless as they are all versionned with the kernel anyway. Also the core will print a message when a new rtc is found. Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-ds1216.c | 3 --- drivers/rtc/rtc-ds1286.c | 3 --- drivers/rtc/rtc-ds1302.c | 2 -- drivers/rtc/rtc-ds1343.c | 2 -- drivers/rtc/rtc-ds1511.c | 3 --- drivers/rtc/rtc-ds1553.c | 3 --- drivers/rtc/rtc-ds1672.c | 5 ----- drivers/rtc/rtc-ds1685.c | 3 --- drivers/rtc/rtc-ds1742.c | 3 --- drivers/rtc/rtc-ep93xx.c | 3 --- drivers/rtc/rtc-gemini.c | 1 - drivers/rtc/rtc-isl12022.c | 5 ----- drivers/rtc/rtc-isl1208.c | 6 ------ drivers/rtc/rtc-m48t35.c | 3 --- drivers/rtc/rtc-m48t86.c | 4 ---- drivers/rtc/rtc-max6900.c | 5 ----- drivers/rtc/rtc-pcf2123.c | 4 ---- drivers/rtc/rtc-pcf8563.c | 5 ----- drivers/rtc/rtc-rs5c313.c | 2 -- drivers/rtc/rtc-rs5c348.c | 4 ---- drivers/rtc/rtc-rs5c372.c | 6 +----- drivers/rtc/rtc-rx8581.c | 5 ----- drivers/rtc/rtc-sh.c | 2 -- drivers/rtc/rtc-stk17ta8.c | 3 --- drivers/rtc/rtc-x1205.c | 5 ----- 25 files changed, 1 insertion(+), 89 deletions(-) commit df2d741f0e00669b94d675564f92949752a5d241 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 12:24:00 2016 +0100 rtc: at91sam9: remove duplicate assignment of variable mr mr is written twice with the same value, remove one of the redundant assignments to mr. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> drivers/rtc/rtc-at91sam9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d25a5ed37d5fdd25f3cfbffc2f9a0f62e58f884c Author: Sergey Yanovich <ynvich@gmail.com> Date: Tue Feb 23 13:54:57 2016 +0300 rtc: ds1302: rewrite using SPI DS1302 is an half-duplex SPI device. The driver respects this fact now. Pin configurations should be implemented using SPI subsystem. Signed-off-by: Sergei Ianovich <ynvich@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> .../devicetree/bindings/rtc/maxim-ds1302.txt | 46 +++ drivers/rtc/Kconfig | 15 +- drivers/rtc/rtc-ds1302.c | 348 ++++++++++----------- 3 files changed, 212 insertions(+), 197 deletions(-) commit 423cd785619ac6778252fbdb916505aa1c153959 Author: Kai-Heng Feng <kaihengfeng@gmail.com> Date: Fri May 20 15:47:23 2016 +0800 ALSA: hda - Fix headphone noise on Dell XPS 13 9360 The headphone has noise when playing sound or switching microphone sources. It uses the same codec on XPS 13 9350, but with different subsystem ID. Applying the fixup can solve the issue. Also, changing the model name to better differentiate models. v2: Reorder by device ID. Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1ab94188e4923629f296eb065ebf56d64ef3324a Author: Colin Ian King <colin.king@canonical.com> Date: Tue May 17 17:40:15 2016 +0100 perf/x86/intel/p4: Trival indentation fix, remove space Remove an extraneous space to fix up indentation. Trivial and no functional change Signed-off-by: Colin Ian King <colin.king@canonical.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Quentin Casasnovas <quentin.casasnovas@oracle.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1463503215-18339-1-git-send-email-colin.king@canonical.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/p4.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc4fac84f8e66b147921ebdc385e767d5def7422 Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 10 14:10:29 2016 -0700 x86/mm: Switch from TASK_SIZE to TASK_SIZE_MAX in the page fault code x86's page fault handlers had two TASK_SIZE uses that should have been TASK_SIZE_MAX. I don't think that either one had a visible effect, but this makes the code clearer and should save a few bytes of text. (And I eventually want to eradicate TASK_SIZE. This will help.) Reported-by: Cyrill Gorcunov <gorcunov@gmail.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Safonov <0x7f454c46@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ruslan Kabatsayev <b7.10110111@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1242fb23b0d05c3069dbf5758ac55d26bc114bef.1462914565.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/fault.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit d696ca016d579d43fc043f28ba656d9305fba651 Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 10 09:18:46 2016 -0700 x86/fsgsbase/64: Use TASK_SIZE_MAX for FSBASE/GSBASE upper limits The GSBASE upper limit exists to prevent user code from confusing the paranoid idtentry path. The FSBASE upper limit is just for consistency. There's no need to enforce a smaller limit for 32-bit tasks. Just use TASK_SIZE_MAX. This simplifies the logic and will save a few bytes of code. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/5357f2fe0f103eabf005773b70722451eab09a89.1462897104.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/process_64.c | 4 ++-- arch/x86/kernel/ptrace.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 06cd3d8c14bdd06f49f1c6a06acf219749c5598e Merge: 0f6ff2b bc231d9 Author: Ingo Molnar <mingo@kernel.org> Date: Fri May 20 09:09:26 2016 +0200 Merge branch 'linus' into x86/urgent, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 0f6ff2bce0d4c3e4ff34f5d2ffb7329025b30844 Author: Dave Hansen <dave@sr71.net> Date: Thu May 12 15:04:00 2016 -0700 x86/mm/mpx: Work around MPX erratum SKD046 This erratum essentially causes the CPU to forget which privilege level it is operating on (kernel vs. user) for the purposes of MPX. This erratum can only be triggered when a system is not using Supervisor Mode Execution Prevention (SMEP). Our workaround for the erratum is to ensure that MPX can only be used in cases where SMEP is present in the processor and is enabled. This erratum only affects Core processors. Atom is unaffected. But, there is no architectural way to determine Atom vs. Core. So, we just apply this workaround to all processors. It's possible that it will mistakenly disable MPX on some Atom processsors or future unaffected Core processors. There are currently no processors that have MPX and not SMEP. It would take something akin to a hypervisor masking SMEP out on an Atom processor for this to present itself on current hardware. More details can be found at: http://www.intel.com/content/dam/www/public/us/en/documents/specification-updates/desktop-6th-gen-core-family-spec-update.pdf " SKD046 Branch Instructions May Initialize MPX Bound Registers Incorrectly Problem: Depending on the current Intel MPX (Memory Protection Extensions) configuration, execution of certain branch instructions (near CALL, near RET, near JMP, and Jcc instructions) without a BND prefix (F2H) initialize the MPX bound registers. Due to this erratum, such a branch instruction that is executed both with CPL = 3 and with CPL < 3 may not use the correct MPX configuration register (BNDCFGU or BNDCFGS, respectively) for determining whether to initialize the bound registers; it may thus initialize the bound registers when it should not, or fail to initialize them when it should. Implication: A branch instruction that has executed both in user mode and in supervisor mode (from the same linear address) may cause a #BR (bound range fault) when it should not have or may not cause a #BR when it should have. Workaround An operating system can avoid this erratum by setting CR4.SMEP[bit 20] to enable supervisor-mode execution prevention (SMEP). When SMEP is enabled, no code can be executed both with CPL = 3 and with CPL < 3. " Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Hansen <dave@sr71.net> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160512220400.3B35F1BC@viggo.jf.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/bugs.h | 8 ++++++++ arch/x86/kernel/cpu/common.c | 3 +++ arch/x86/kernel/cpu/intel.c | 37 +++++++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+) commit 21f77d231fabd33c5de61fbff31818d93203353e Merge: b0a434f a29d5c9 Author: Ingo Molnar <mingo@kernel.org> Date: Fri May 20 08:19:20 2016 +0200 Merge tag 'perf-core-for-mingo-20160516' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Honour the kernel.perf_event_max_stack knob more precisely by not counting PERF_CONTEXT_{KERNEL,USER} when deciding when to stop adding entries to the perf_sample->ip_callchain[] array (Arnaldo Carvalho de Melo) - Fix identation of 'stalled-backend-cycles' in 'perf stat' (Namhyung Kim) - Update runtime using 'cpu-clock' event in 'perf stat' (Namhyung Kim) - Use 'cpu-clock' for cpu targets in 'perf stat' (Namhyung Kim) - Avoid fractional digits for integer scales in 'perf stat' (Andi Kleen) - Store vdso buildid unconditionally, as it appears in callchains and we're not checking those when creating the build-id table, so we end up not being able to resolve VDSO symbols when doing analysis on a different machine than the one where recording was done, possibly of a different arch even (arm -> x86_64) (He Kuang) Infrastructure changes: - Generalize max_stack sysctl handler, will be used for configuring multiple kernel knobs related to callchains (Arnaldo Carvalho de Melo) Cleanups: - Introduce DSO__NAME_KALLSYMS and DSO__NAME_KCORE, to stop using open coded strings (Masami Hiramatsu) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 52103b70e13ae1381020b5a9fa15824a9b35baeb Author: David S. Miller <davem@davemloft.net> Date: Thu May 19 22:56:48 2016 -0700 Revert "net: pegasus: remove dead coding" This reverts commit e00be9e4d0ffcc0121606229f0aa4b246d6881d7. It causes warnings and has several problems. Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/pegasus.c | 53 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) commit ca79e49d6add77b69be3362ddfe5b068f62bf1de Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri May 20 09:04:41 2016 +1000 drm/nouveau/gr/gf100-: fix race condition in fecs/gpccs ucode This is a simplied version of the fix by Roy in fdo#93629. While this doesn't appear to fix the issues for the users in that report, it's a real issue that deserves to be resolved. Reported-by: Roy Spliet <rspliet@eclipso.eu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpc.fuc | 7 ++++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgf100.fuc3.h | 9 +++++---- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgf117.fuc3.h | 11 ++++++----- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgk104.fuc3.h | 11 ++++++----- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgk110.fuc3.h | 11 ++++++----- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgk208.fuc5.h | 11 ++++++----- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/gpcgm107.fuc5.h | 11 ++++++----- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hub.fuc | 7 ++++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgf100.fuc3.h | 13 +++++++------ drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgf117.fuc3.h | 13 +++++++------ drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgk104.fuc3.h | 13 +++++++------ drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgk110.fuc3.h | 13 +++++++------ drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgk208.fuc5.h | 13 +++++++------ drivers/gpu/drm/nouveau/nvkm/engine/gr/fuc/hubgm107.fuc5.h | 13 +++++++------ 14 files changed, 85 insertions(+), 71 deletions(-) commit f9e2029443afc550365864abf760419371cc3bc1 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 21 10:35:38 2016 +1000 drm/nouveau/core: recognise GM108 chipsets Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 35 +++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 00f50c662c5aa3cebea62015d1df8cd5b19a41b6 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 21 10:28:55 2016 +1000 drm/nouveau/gr/gm107-: fix touching non-existent ppcs in attrib cb setup Also removes an XXX; according to nvgpu headers the field is called NV_PGRAPH_GPCS_SWDX_TC_BETA_CB_SIZE_DIV3, so, apparently not some magic we need to figure out :) Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit a00ecf2212be0196c7485786c7b0c0263dfbf88a Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 21 10:23:10 2016 +1000 drm/nouveau/gr/gk104-: share implementation of ppc exception init This was really inconsistent, some implementations could touch PPCs that didn't exist, others neglected to touch ones that did. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 2 ++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gk104.c | 19 ++++++++++++++++++- drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110b.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk208.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 7 ++++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 7 ++++--- 7 files changed, 31 insertions(+), 7 deletions(-) commit 87ac331e3f9aca9bdc3697bb936b3b2b43cbf5a0 Author: Ben Skeggs <bskeggs@redhat.com> Date: Tue Apr 19 11:10:38 2016 +1000 drm/nouveau/gr/gk104-: move rop_active_fbps init to nonctx Matches newer RM. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h | 2 -- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c | 10 ---------- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk20a.c | 2 -- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c | 2 -- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c | 11 ----------- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm20b.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 2 ++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gk104.c | 12 ++++++++++++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110b.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk208.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk20a.c | 3 +++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 3 +++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 12 ++++++++++++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gm20b.c | 1 + 15 files changed, 36 insertions(+), 28 deletions(-) commit 4d3df19a8e6c9e60eed7f3c6e2025362b3ca2da5 Author: Ben Skeggs <bskeggs@redhat.com> Date: Tue Apr 19 10:28:44 2016 +1000 drm/nouveau/bios/pll: check BIT table version before trying to parse it Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/bios/pll.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 2781c928b1b3d5d56d72b4955e19c0d963e2c22e Author: Ben Skeggs <bskeggs@redhat.com> Date: Tue Apr 19 10:07:04 2016 +1000 drm/nouveau/bios/pll: prevent oops when limits table can't be parsed Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/bios/pll.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d07a97e939cd1e257d833758c43dd5b7ffd7ba44 Author: Karol Herbst <nouveau@karolherbst.de> Date: Sat Apr 16 20:01:59 2016 +0200 drm/nouveau/volt/gk104: round up in gk104_volt_set We always want a equal or higher voltage than the requested ones, otherwise nouveau undervolts. Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e976278ad231dbc44c00729df72cf9fe9a164412 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 11:14:33 2016 +1000 drm/nouveau/fb/gm200: setup mmu debug buffer registers at init() Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 6 +-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 6 --- drivers/gpu/drm/nouveau/nvkm/subdev/fb/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm200.c | 60 +++++++++++++++++++++++ 5 files changed, 65 insertions(+), 9 deletions(-) commit 834b21f5e902b4fdf3217779d10d4f388b667e85 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 10:50:55 2016 +1000 drm/nouveau/fb/gk20a,gm20b: setup mmu debug buffer registers at init() Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gk20a.c | 5 ----- drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c | 4 ++++ 2 files changed, 4 insertions(+), 5 deletions(-) commit 99c5917253a6c5584a7052f9ee578e2c6852253f Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 10:39:18 2016 +1000 drm/nouveau/fb/gf100-: allocate mmu debug buffers Later chipsets require setting this up both in FB and GR, so let's just move the allocation to FB. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h | 3 +++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 29 ++++-------------------- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 3 --- drivers/gpu/drm/nouveau/nvkm/engine/gr/gk104.c | 7 ++++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gk20a.c | 6 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 6 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 6 +++-- drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c | 4 ++++ drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c | 26 +++++++++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk104.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm107.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h | 1 + 13 files changed, 58 insertions(+), 36 deletions(-) commit 917d95a86e7b7036d481323240443566be82a619 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 10:38:55 2016 +1000 drm/nouveau/fb: allow chipset-specific actions for oneinit() Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c | 8 ++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h | 1 + 2 files changed, 9 insertions(+) commit 06d4f26cc33b11be4b41fa0409130cbdf34d9343 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 15:36:16 2016 +1000 drm/nouveau/gr/gm200-: fix bad hardcoding of a max-tpcs-per-gpc value Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) commit 734a0aa669fd032f40e27e3d3df7228e1fe27681 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 14:28:03 2016 +1000 drm/nouveau/gr/gm200-: rop count == ltc count Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 8 +++++++- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm20b.c | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) commit c83e7d6836e1e7bf6ed30905444fa47d4ef0a82e Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 14:41:52 2016 +1000 drm/nouveau/gr/gm200: modify the mask when copying mmu settings from fb Appears to more closely match what RM does. For GM20B, now also copying bit 12 from NV_PFB_MMU_CTRL as upcoming changes will require it. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 4 +--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm20b.c | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) commit 54aa38a8ad5cf91fece3d4b70f9eb1701599c0d1 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 11:19:54 2016 +1000 drm/nouveau/gr/gm200: move some code into init_gpc_mmu() hook Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 28 +++++++++++++++++--------- 1 file changed, 19 insertions(+), 9 deletions(-) commit 560e6da2678d033cd8dac3cea7acf987d16f4550 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 12:58:29 2016 +1000 drm/nouveau/gr/gm200: make generate_main() static Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h | 1 - drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) commit 64cb5a31f477fe1540bfdbb7f72e7324d21208f4 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 14:26:18 2016 +1000 drm/nouveau/gr/gf100-: abstract fetching rop count Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 12 ++++++++++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 2 ++ drivers/gpu/drm/nouveau/nvkm/engine/gr/gf104.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gf110.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gf119.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk104.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk110b.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk208.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gk20a.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gm20b.c | 1 + 15 files changed, 25 insertions(+), 2 deletions(-) commit 5ec3def7355a6f4d08ca612c775cf2320c1012e4 Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 14:08:25 2016 +1000 drm/nouveau/gr/gf100-: rename magic_not_rop_nr to screen_tile_row_offset Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.c | 6 +++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c | 6 +++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 24 +++++++++++------------ drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/gk104.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gk20a.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm200.c | 4 ++-- 8 files changed, 26 insertions(+), 26 deletions(-) commit 933ad445946f3818fc9f991c989de01993c1e8dc Author: Ben Skeggs <bskeggs@redhat.com> Date: Thu Apr 14 12:57:01 2016 +1000 drm/nouveau/gr/gf100-: remove hardcoded idle_timeout values Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.c | 5 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c | 5 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c | 5 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk20a.c | 7 +++---- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c | 5 +++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c | 6 +++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm20b.c | 7 +++---- 7 files changed, 21 insertions(+), 19 deletions(-) commit 0cdc3fdfb7162c0ea5d467ae0c06bc47c6fea26e Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gm107-: remove engines from mmu engine mapping array These are specified by PTOP on Maxwell GPUs. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.h | 2 ++ drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm107.c | 25 +++++++++++++++++++++++- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm200.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm20b.c | 2 +- 4 files changed, 28 insertions(+), 3 deletions(-) commit 289e082706ca8191be16298ca8f06879a70d0f46 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gk104-: identify mmu engine ids for host faults It appears these don't map to PBDMAs (at least on Kepler, it may or may be valid for Fermi - this hasn't been checked), but to runlists. This drops the NVKM_ENGINE_FIFO data from the entries too, as resetting all of PFIFO is *not* the way to handle such faults. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) commit e50d0237fc371be7053082f35efab03a740d055f Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gk104-: implement support for PTOP fault info Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit 91419acf7819d8a0ca5f36b924f224c92f96eeb8 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gk104-: abstract mmu fault data structures Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 223 ++++++++++++----------- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.h | 14 +- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk110.c | 4 + drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk208.c | 4 + drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk20a.c | 4 + drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm107.c | 4 + drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm200.c | 4 + drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm20b.c | 4 + 8 files changed, 150 insertions(+), 111 deletions(-) commit 98ac3f061afa9b8347948451cb4e2d336d0a8912 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gk104-: subclass func Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/base.c | 11 +++++ drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 55 ++++++++++++++++-------- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.h | 15 +++---- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk110.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk208.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk20a.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm107.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm200.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/gm20b.c | 9 +--- drivers/gpu/drm/nouveau/nvkm/engine/fifo/priv.h | 3 ++ 10 files changed, 65 insertions(+), 73 deletions(-) commit e93e198d468f6ae41cf62265f389da2925fe16bb Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/fifo/gk104-: use device info from top subdev Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 89 +++++------------------- 1 file changed, 16 insertions(+), 73 deletions(-) commit 56d06fa29edd58c448766014afd833b7ff51247b Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/core: remove pmc_enable argument from subdev ctor These are now specified directly in the MC subdev. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/core/engine.h | 6 ++---- drivers/gpu/drm/nouveau/include/nvkm/core/subdev.h | 3 +-- drivers/gpu/drm/nouveau/include/nvkm/engine/falcon.h | 1 - drivers/gpu/drm/nouveau/include/nvkm/engine/xtensa.h | 1 - drivers/gpu/drm/nouveau/nvkm/core/engine.c | 14 ++++++-------- drivers/gpu/drm/nouveau/nvkm/core/subdev.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/bsp/g84.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/ce/gf100.c | 2 -- drivers/gpu/drm/nouveau/nvkm/engine/ce/gk104.c | 14 +------------- drivers/gpu/drm/nouveau/nvkm/engine/ce/gm107.c | 14 +------------- drivers/gpu/drm/nouveau/nvkm/engine/ce/gm200.c | 14 +------------- drivers/gpu/drm/nouveau/nvkm/engine/ce/gt215.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/cipher/g84.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/disp/base.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/dma/base.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/falcon.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/fifo/base.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/gr/base.c | 5 ++--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/nv04.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/gr/nv10.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/nv20.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/nv40.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/nv50.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/priv.h | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/mpeg/g84.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/mpeg/nv31.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/mpeg/nv44.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/mpeg/nv50.c | 3 +-- drivers/gpu/drm/nouveau/nvkm/engine/mspdec/g98.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/mspdec/gf100.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/mspdec/gk104.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/mspdec/gt215.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msppp/g98.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msppp/gf100.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msppp/gt215.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msvld/g98.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msvld/gf100.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msvld/gk104.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msvld/gt215.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/msvld/mcp89.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/sec/g98.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/sw/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/vp/g84.c | 1 - drivers/gpu/drm/nouveau/nvkm/engine/xtensa.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/bar/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/bios/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/bus/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/devinit/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/fuse/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/gpio/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/i2c/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gf100.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gf117.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gk104.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gk20a.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gm200.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/ltc/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 7 +------ drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mxm/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/pci/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gk20a.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/secboot/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/timer/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/top/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/volt/base.c | 2 +- 74 files changed, 62 insertions(+), 139 deletions(-) commit d85e2a8dd8f0d7592feaecb97ad0b0478f4e2cb7 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/nv04: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv04.c | 14 +++++--------- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 1 - 2 files changed, 5 insertions(+), 10 deletions(-) commit 667e99ab23c21b2f38f64dded0c0061ec712c40e Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/nv11: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv04.c | 7 ++++ drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv11.c | 50 +++++++++++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 1 + 6 files changed, 61 insertions(+), 1 deletion(-) commit 79360b7d5f6be90b934c20345ab3bac1d98e3c08 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/nv17: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 40 +++++++++++------------ drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv17.c | 27 +++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv44.c | 3 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv50.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 1 + 6 files changed, 52 insertions(+), 21 deletions(-) commit 9199fbdbf8a94dae63615cceed79766fa04f3db8 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/nv50: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv17.c | 32 +++++++++++++++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv50.c | 20 +++++++---------- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 3 ++- 4 files changed, 43 insertions(+), 13 deletions(-) commit 7354902001eef2299826ced3c4e2a7235b6b1f30 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/g84: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 12 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/mc/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c | 68 +++++++++++++++++++++++ 4 files changed, 76 insertions(+), 6 deletions(-) commit e56f90fe1702a533f78b2dfc08b038a93111b24d Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/g98: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/g98.c | 36 +++++++++++++++++----------- 1 file changed, 22 insertions(+), 14 deletions(-) commit 88c0de2cdb25b8b9e1c286a9f4a3a8de898151ce Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/gt215: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 8 +-- drivers/gpu/drm/nouveau/nvkm/subdev/mc/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/gt215.c | 70 +++++++++++++++++++++++ 4 files changed, 76 insertions(+), 4 deletions(-) commit a6bb38e90232dfc9c592cf1dca935f69b9b9b3f4 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/gf100: define reset masks + intr cleanup Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/gf100.c | 49 ++++++++++++++++---------- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 1 - 2 files changed, 30 insertions(+), 20 deletions(-) commit 33537d6fdc2e7ed87d569a2a9ab0a571385d4318 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc/gk104: define reset masks + intr cleanup Engine fields have been removed, as they're specified by PTOP. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 10 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/mc/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/mc/gk104.c | 64 +++++++++++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/mc/gk20a.c | 3 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 3 ++ 6 files changed, 76 insertions(+), 6 deletions(-) commit 921be10d85ca10973b374ef10273c2f228081ee8 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc: implement support for PTOP interrupt routing Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 583f8e4ea216d9d0212e63ede384893ec0c1b742 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc: implement support for PTOP reset info Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 70b01f07dbd093c96e9910ba613c3d40346ee222 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc: allow for local definition of reset bits With the addition of PTOP-specified reset bits, it makes more sense to move the definitions here rather than in individual subdev implementations. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 17 +++++++++++++++-- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 1 + 2 files changed, 16 insertions(+), 2 deletions(-) commit 6defde5ab3e1d8b8fcd187517f878955b5e30465 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc: add helper function to handle device reset This will be later extended to handle PTOP-specified reset masks as well as the hardcoded ones. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/mc.h | 1 + drivers/gpu/drm/nouveau/nvkm/core/subdev.c | 8 ++------ drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 20 ++++++++++++++++++++ 3 files changed, 23 insertions(+), 6 deletions(-) commit 87f313e6e6dcd1f46cc4ad134980584c822b67d6 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/mc: rename struct nvkm_mc_intr to nvkm_mc_map This will also be used to define NV_PMC_ENABLE <-> subdev mappings in an upcoming commit. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/g98.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/gf100.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv04.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/nv50.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mc/priv.h | 10 +++++----- 6 files changed, 10 insertions(+), 10 deletions(-) commit fb3e9c61caef12e537d6d8cd79b6c8d3de238d79 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/top/gk104: initial implementation Ported from the code currently in engine/fifo/gk104.c. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/top.h | 2 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 13 +++ drivers/gpu/drm/nouveau/nvkm/subdev/top/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/top/gk104.c | 110 ++++++++++++++++++++++ 4 files changed, 126 insertions(+) commit 5f76f294d1ffb2955370b439226ea072c378a3f7 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/top: initial implementation Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/top.h | 7 + drivers/gpu/drm/nouveau/nvkm/subdev/top/Kbuild | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/top/base.c | 148 ++++++++++++++++++++++ drivers/gpu/drm/nouveau/nvkm/subdev/top/priv.h | 20 +++ 4 files changed, 176 insertions(+), 1 deletion(-) commit eaebfcc34e52ca2c1a0d852674b72eecf31a2737 Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri Apr 8 17:24:40 2016 +1000 drm/nouveau/core: add top plumbing Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/core/device.h | 3 +++ drivers/gpu/drm/nouveau/include/nvkm/subdev/top.h | 8 ++++++++ drivers/gpu/drm/nouveau/nvkm/core/subdev.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/base.c | 2 ++ drivers/gpu/drm/nouveau/nvkm/engine/device/priv.h | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/top/Kbuild | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/top/priv.h | 5 +++++ 8 files changed, 22 insertions(+) commit 2e9a43f901482195144e04311f682ede5d6d73f6 Author: Karol Herbst <nouveau@karolherbst.de> Date: Mon Mar 28 14:24:32 2016 +0200 drm/nouveau/iccsense: configure sensors like nvidia does v2: rename ina209/ina219 read function Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Reviewed-by: Martin Peres <martin.peres@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> .../gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 68 ++++++++++++++++++++++ 1 file changed, 68 insertions(+) commit 5f1f07de4114ae0012d98330d8e6b5c1cfcace41 Author: Karol Herbst <nouveau@karolherbst.de> Date: Mon Mar 28 14:24:31 2016 +0200 drm/nouveau/iccsense: split sensor into own struct v2: add list_del call, reword error message Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Reviewed-by: Martin Peres <martin.peres@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> .../gpu/drm/nouveau/include/nvkm/subdev/iccsense.h | 1 + .../gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 142 +++++++++++++++------ .../gpu/drm/nouveau/nvkm/subdev/iccsense/priv.h | 15 ++- 3 files changed, 113 insertions(+), 45 deletions(-) commit 92224e751f97847195b8e90a033b3e7b30ff0bd3 Author: Karol Herbst <nouveau@karolherbst.de> Date: Mon Mar 28 14:24:30 2016 +0200 drm/nouveau/iccsense: convert to linked list v2: add list_del calls Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Reviewed-by: Martin Peres <martin.peres@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> .../gpu/drm/nouveau/include/nvkm/subdev/iccsense.h | 4 +-- drivers/gpu/drm/nouveau/nouveau_hwmon.c | 2 +- .../gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 34 ++++++++++------------ .../gpu/drm/nouveau/nvkm/subdev/iccsense/priv.h | 1 + 4 files changed, 19 insertions(+), 22 deletions(-) commit d03e0f2748a7da3911fd54af16eb07f325ce830f Author: Karol Herbst <nouveau@karolherbst.de> Date: Mon Mar 28 14:24:29 2016 +0200 drm/nouveau/iccsense: remove read function Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Reviewed-by: Martin Peres <martin.peres@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> .../gpu/drm/nouveau/include/nvkm/subdev/iccsense.h | 1 - .../gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 23 ++++++++++------------ 2 files changed, 10 insertions(+), 14 deletions(-) commit 7d28dbae228d16b28b6af98bf020effabfb7e0b0 Author: Karol Herbst <nouveau@karolherbst.de> Date: Mon Jan 11 02:58:03 2016 +0100 drm/nouveau/pmu: be more strict about locking When we start communicating with the pmu a bit more, the current code is a real issue. I encountered a dead lock here, while testing my dynamic reclocking code Signed-off-by: Karol Herbst <nouveau@karolherbst.de> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit c6007dc4e55e1a483c4d1e32dc1055b41aeacfc1 Author: Alexandre Courbot <acourbot@nvidia.com> Date: Fri Apr 1 15:40:59 2016 +0900 drm/nouveau/devinit/gf100: make devinit on resume safer In case of successful suspend, devinit will have to be run and this is the behavior currently hardcoded. However, as FD bug 94725 suggests, there might be cases where runtime suspend leaves the GPU powered, and in such cases devinit should not be run on resume. On GF100+ we have a reliable way to know whether we need to run devinit. Use it instead of blindly trusting the flag set by nvkm_devinit_fini(). The code around the NvForcePost also needs to be slightly reworked in order to keep working. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Suggested-by: Dave Airlie <airlied@redhat.com> Suggested-by: Karol Herbst <nouveau@karolherbst.de> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/include/nvkm/subdev/devinit.h | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/devinit/base.c | 8 +++++++- drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c | 8 +++++--- 3 files changed, 13 insertions(+), 4 deletions(-) commit 4dc28134a8c124aa01b441e1e5b8b54312edc5dd Author: Ben Skeggs <bskeggs@redhat.com> Date: Fri May 20 09:22:55 2016 +1000 drm/nouveau: rename nouveau_drm.h to nouveau_drv.h Fixes out-of-tree build issue where uapi/drm/nouveau_drm.h gets picked up instead. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> drivers/gpu/drm/nouveau/dispnv04/arb.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/crtc.c | 3 +- drivers/gpu/drm/nouveau/dispnv04/cursor.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/dac.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/dfp.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/disp.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/disp.h | 2 +- drivers/gpu/drm/nouveau/dispnv04/hw.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/overlay.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/tvmodesnv17.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/tvnv04.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/tvnv17.c | 2 +- drivers/gpu/drm/nouveau/nouveau_abi16.c | 2 +- drivers/gpu/drm/nouveau/nouveau_acpi.c | 2 +- drivers/gpu/drm/nouveau/nouveau_backlight.c | 2 +- drivers/gpu/drm/nouveau/nouveau_bios.c | 2 +- drivers/gpu/drm/nouveau/nouveau_bo.c | 2 +- drivers/gpu/drm/nouveau/nouveau_chan.c | 2 +- drivers/gpu/drm/nouveau/nouveau_connector.c | 2 +- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 2 +- drivers/gpu/drm/nouveau/nouveau_debugfs.h | 2 +- drivers/gpu/drm/nouveau/nouveau_display.h | 2 +- drivers/gpu/drm/nouveau/nouveau_dma.c | 2 +- drivers/gpu/drm/nouveau/nouveau_dp.c | 2 +- drivers/gpu/drm/nouveau/nouveau_drm.c | 2 +- drivers/gpu/drm/nouveau/nouveau_drm.h | 207 ------------------------- drivers/gpu/drm/nouveau/nouveau_drv.h | 207 +++++++++++++++++++++++++ drivers/gpu/drm/nouveau/nouveau_fbcon.c | 2 +- drivers/gpu/drm/nouveau/nouveau_fence.c | 2 +- drivers/gpu/drm/nouveau/nouveau_gem.c | 2 +- drivers/gpu/drm/nouveau/nouveau_gem.h | 2 +- drivers/gpu/drm/nouveau/nouveau_hwmon.c | 2 +- drivers/gpu/drm/nouveau/nouveau_nvif.c | 2 +- drivers/gpu/drm/nouveau/nouveau_platform.h | 2 +- drivers/gpu/drm/nouveau/nouveau_prime.c | 2 +- drivers/gpu/drm/nouveau/nouveau_sgdma.c | 2 +- drivers/gpu/drm/nouveau/nouveau_ttm.c | 2 +- drivers/gpu/drm/nouveau/nouveau_usif.c | 2 +- drivers/gpu/drm/nouveau/nouveau_vga.c | 2 +- drivers/gpu/drm/nouveau/nv04_fbcon.c | 2 +- drivers/gpu/drm/nouveau/nv04_fence.c | 2 +- drivers/gpu/drm/nouveau/nv10_fence.c | 2 +- drivers/gpu/drm/nouveau/nv17_fence.c | 2 +- drivers/gpu/drm/nouveau/nv50_display.c | 2 +- drivers/gpu/drm/nouveau/nv50_fbcon.c | 2 +- drivers/gpu/drm/nouveau/nv50_fence.c | 2 +- drivers/gpu/drm/nouveau/nv84_fence.c | 2 +- drivers/gpu/drm/nouveau/nvc0_fbcon.c | 2 +- drivers/gpu/drm/nouveau/nvc0_fence.c | 2 +- 49 files changed, 255 insertions(+), 254 deletions(-) commit a05a70db34ba24ca009e1c9cedaef26fd17d5470 Merge: 03b979d 4741526 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 20:00:06 2016 -0700 Merge branch 'akpm' (patches from Andrew) Merge updates from Andrew Morton: - fsnotify fix - poll() timeout fix - a few scripts/ tweaks - debugobjects updates - the (small) ocfs2 queue - Minor fixes to kernel/padata.c - Maybe half of the MM queue * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (117 commits) mm, page_alloc: restore the original nodemask if the fast path allocation failed mm, page_alloc: uninline the bad page part of check_new_page() mm, page_alloc: don't duplicate code in free_pcp_prepare mm, page_alloc: defer debugging checks of pages allocated from the PCP mm, page_alloc: defer debugging checks of freed pages until a PCP drain cpuset: use static key better and convert to new API mm, page_alloc: inline pageblock lookup in page free fast paths mm, page_alloc: remove unnecessary variable from free_pcppages_bulk mm, page_alloc: pull out side effects from free_pages_check mm, page_alloc: un-inline the bad part of free_pages_check mm, page_alloc: check multiple page fields with a single branch mm, page_alloc: remove field from alloc_context mm, page_alloc: avoid looking up the first zone in a zonelist twice mm, page_alloc: shortcut watermark checks for order-0 pages mm, page_alloc: reduce cost of fair zone allocation policy retry mm, page_alloc: shorten the page allocator fast path mm, page_alloc: check once if a zone has isolated pageblocks mm, page_alloc: move __GFP_HARDWALL modifications out of the fastpath mm, page_alloc: simplify last cpupid reset mm, page_alloc: remove unnecessary initialisation from __alloc_pages_nodemask() ... commit 48a77aa7e20557319205f9bd4cc02d4b67b5f761 Author: Steve French <smfrench@gmail.com> Date: Wed May 18 20:48:32 2016 -0500 CIFS: Remove some obsolete comments Remove some obsolete comments in the cifs inode_operations structs that were pointed out by Stephen Rothwell. CC: Stephen Rothwell <sfr@canb.auug.org.au> CC: Al Viro <viro@zeniv.linux.org.uk> Reviewed-by: Sachin Prabhu <sprabhu@redhat.com> Signed-off-by: Steve French <steve.french@primarydata.com> fs/cifs/cifsfs.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit b74cb9a80268be5c80cf4c87c74debf0ff2129ac Author: Sachin Prabhu <sprabhu@redhat.com> Date: Tue May 17 18:20:13 2016 -0500 cifs: Create dedicated keyring for spnego operations The session key is the default keyring set for request_key operations. This session key is revoked when the user owning the session logs out. Any long running daemon processes started by this session ends up with revoked session keyring which prevents these processes from using the request_key mechanism from obtaining the krb5 keys. The problem has been reported by a large number of autofs users. The problem is also seen with multiuser mounts where the share may be used by processes run by a user who has since logged out. A reproducer using automount is available on the Red Hat bz. The patch creates a new keyring which is used to cache cifs spnego upcalls. Red Hat bz: 1267754 Signed-off-by: Sachin Prabhu <sprabhu@redhat.com> Reported-by: Scott Mayhew <smayhew@redhat.com> Reviewed-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> CC: Stable <stable@vger.kernel.org> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/cifs_spnego.c | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++ fs/cifs/cifsfs.c | 4 +-- fs/cifs/cifsproto.h | 2 ++ 3 files changed, 71 insertions(+), 2 deletions(-) commit 4741526b83c5d3a3d661d1896f9e7414c5730bcb Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:44 2016 -0700 mm, page_alloc: restore the original nodemask if the fast path allocation failed The page allocator fast path uses either the requested nodemask or cpuset_current_mems_allowed if cpusets are enabled. If the allocation context allows watermarks to be ignored then it can also ignore memory policies. However, on entering the allocator slowpath the nodemask may still be cpuset_current_mems_allowed and the policies are enforced. This patch resets the nodemask appropriately before entering the slowpath. Link: http://lkml.kernel.org/r/20160504143628.GU2858@techsingularity.net Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 4e6118016eb7986109ad61b00186579f384f956a Author: Vlastimil Babka <vbabka@suse.cz> Date: Thu May 19 17:14:41 2016 -0700 mm, page_alloc: uninline the bad page part of check_new_page() Bad pages should be rare so the code handling them doesn't need to be inline for performance reasons. Put it to separate function which returns void. This also assumes that the initial page_expected_state() result will match the result of the thorough check, i.e. the page doesn't become "good" in the meanwhile. This matches the same expectations already in place in free_pages_check(). !DEBUG_VM bloat-o-meter: add/remove: 1/0 grow/shrink: 0/1 up/down: 134/-274 (-140) function old new delta check_new_page_bad - 134 +134 get_page_from_freelist 3468 3194 -274 Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) commit e2769dbdc51f1baa1908ecf6c84d50f19577e1db Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:38 2016 -0700 mm, page_alloc: don't duplicate code in free_pcp_prepare The new free_pcp_prepare() function shares a lot of code with free_pages_prepare(), which makes this a maintenance risk when some future patch modifies only one of them. We should be able to achieve the same effect (skipping free_pages_check() from !DEBUG_VM configs) by adding a parameter to free_pages_prepare() and making it inline, so the checks (and the order != 0 parts) are eliminated from the call from free_pcp_prepare(). !DEBUG_VM: bloat-o-meter reports no difference, as my gcc was already inlining free_pages_prepare() and the elimination seems to work as expected DEBUG_VM bloat-o-meter: add/remove: 0/1 grow/shrink: 2/0 up/down: 1035/-778 (257) function old new delta __free_pages_ok 297 1060 +763 free_hot_cold_page 480 752 +272 free_pages_prepare 778 - -778 Here inlining didn't occur before, and added some code, but it's ok for a debug option. [akpm@linux-foundation.org: fix build] Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 133 +++++++++++++++++++++++--------------------------------- 1 file changed, 55 insertions(+), 78 deletions(-) commit 479f854a207ce2b97545a0a83856778b541063d0 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:35 2016 -0700 mm, page_alloc: defer debugging checks of pages allocated from the PCP Every page allocated checks a number of page fields for validity. This catches corruption bugs of pages that are already freed but it is expensive. This patch weakens the debugging check by checking PCP pages only when the PCP lists are being refilled. All compound pages are checked. This potentially avoids debugging checks entirely if the PCP lists are never emptied and refilled so some corruption issues may be missed. Full checking requires DEBUG_VM. With the two deferred debugging patches applied, the impact to a page allocator microbenchmark is 4.6.0-rc3 4.6.0-rc3 inline-v3r6 deferalloc-v3r7 Min alloc-odr0-1 344.00 ( 0.00%) 317.00 ( 7.85%) Min alloc-odr0-2 248.00 ( 0.00%) 231.00 ( 6.85%) Min alloc-odr0-4 209.00 ( 0.00%) 192.00 ( 8.13%) Min alloc-odr0-8 181.00 ( 0.00%) 166.00 ( 8.29%) Min alloc-odr0-16 168.00 ( 0.00%) 154.00 ( 8.33%) Min alloc-odr0-32 161.00 ( 0.00%) 148.00 ( 8.07%) Min alloc-odr0-64 158.00 ( 0.00%) 145.00 ( 8.23%) Min alloc-odr0-128 156.00 ( 0.00%) 143.00 ( 8.33%) Min alloc-odr0-256 168.00 ( 0.00%) 154.00 ( 8.33%) Min alloc-odr0-512 178.00 ( 0.00%) 167.00 ( 6.18%) Min alloc-odr0-1024 186.00 ( 0.00%) 174.00 ( 6.45%) Min alloc-odr0-2048 192.00 ( 0.00%) 180.00 ( 6.25%) Min alloc-odr0-4096 198.00 ( 0.00%) 184.00 ( 7.07%) Min alloc-odr0-8192 200.00 ( 0.00%) 188.00 ( 6.00%) Min alloc-odr0-16384 201.00 ( 0.00%) 188.00 ( 6.47%) Min free-odr0-1 189.00 ( 0.00%) 180.00 ( 4.76%) Min free-odr0-2 132.00 ( 0.00%) 126.00 ( 4.55%) Min free-odr0-4 104.00 ( 0.00%) 99.00 ( 4.81%) Min free-odr0-8 90.00 ( 0.00%) 85.00 ( 5.56%) Min free-odr0-16 84.00 ( 0.00%) 80.00 ( 4.76%) Min free-odr0-32 80.00 ( 0.00%) 76.00 ( 5.00%) Min free-odr0-64 78.00 ( 0.00%) 74.00 ( 5.13%) Min free-odr0-128 77.00 ( 0.00%) 73.00 ( 5.19%) Min free-odr0-256 94.00 ( 0.00%) 91.00 ( 3.19%) Min free-odr0-512 108.00 ( 0.00%) 112.00 ( -3.70%) Min free-odr0-1024 115.00 ( 0.00%) 118.00 ( -2.61%) Min free-odr0-2048 120.00 ( 0.00%) 125.00 ( -4.17%) Min free-odr0-4096 123.00 ( 0.00%) 129.00 ( -4.88%) Min free-odr0-8192 126.00 ( 0.00%) 130.00 ( -3.17%) Min free-odr0-16384 126.00 ( 0.00%) 131.00 ( -3.97%) Note that the free paths for large numbers of pages is impacted as the debugging cost gets shifted into that path when the page data is no longer necessarily cache-hot. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 92 +++++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 64 insertions(+), 28 deletions(-) commit 4db7548ccbd9ec8e666f35df4a530f55904dec39 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:32 2016 -0700 mm, page_alloc: defer debugging checks of freed pages until a PCP drain Every page free checks a number of page fields for validity. This catches premature frees and corruptions but it is also expensive. This patch weakens the debugging check by checking PCP pages at the time they are drained from the PCP list. This will trigger the bug but the site that freed the corrupt page will be lost. To get the full context, a kernel rebuild with DEBUG_VM is necessary. [akpm@linux-foundation.org: fix build] Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 152 +++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 101 insertions(+), 51 deletions(-) commit 002f290627c27068087f6204baec7a334e5a3b48 Author: Vlastimil Babka <vbabka@suse.cz> Date: Thu May 19 17:14:30 2016 -0700 cpuset: use static key better and convert to new API An important function for cpusets is cpuset_node_allowed(), which optimizes on the fact if there's a single root CPU set, it must be trivially allowed. But the check "nr_cpusets() <= 1" doesn't use the cpusets_enabled_key static key the right way where static keys eliminate branching overhead with jump labels. This patch converts it so that static key is used properly. It's also switched to the new static key API and the checking functions are converted to return bool instead of int. We also provide a new variant __cpuset_zone_allowed() which expects that the static key check was already done and they key was enabled. This is needed for get_page_from_freelist() where we want to also avoid the relatively slower check when ALLOC_CPUSET is not set in alloc_flags. The impact on the page allocator microbenchmark is less than expected but the cleanup in itself is worthwhile. 4.6.0-rc2 4.6.0-rc2 multcheck-v1r20 cpuset-v1r20 Min alloc-odr0-1 348.00 ( 0.00%) 348.00 ( 0.00%) Min alloc-odr0-2 254.00 ( 0.00%) 254.00 ( 0.00%) Min alloc-odr0-4 213.00 ( 0.00%) 213.00 ( 0.00%) Min alloc-odr0-8 186.00 ( 0.00%) 183.00 ( 1.61%) Min alloc-odr0-16 173.00 ( 0.00%) 171.00 ( 1.16%) Min alloc-odr0-32 166.00 ( 0.00%) 163.00 ( 1.81%) Min alloc-odr0-64 162.00 ( 0.00%) 159.00 ( 1.85%) Min alloc-odr0-128 160.00 ( 0.00%) 157.00 ( 1.88%) Min alloc-odr0-256 169.00 ( 0.00%) 166.00 ( 1.78%) Min alloc-odr0-512 180.00 ( 0.00%) 180.00 ( 0.00%) Min alloc-odr0-1024 188.00 ( 0.00%) 187.00 ( 0.53%) Min alloc-odr0-2048 194.00 ( 0.00%) 193.00 ( 0.52%) Min alloc-odr0-4096 199.00 ( 0.00%) 198.00 ( 0.50%) Min alloc-odr0-8192 202.00 ( 0.00%) 201.00 ( 0.50%) Min alloc-odr0-16384 203.00 ( 0.00%) 202.00 ( 0.49%) Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Zefan Li <lizefan@huawei.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/cpuset.h | 42 ++++++++++++++++++++++++++++-------------- kernel/cpuset.c | 14 +++++++------- mm/page_alloc.c | 2 +- 3 files changed, 36 insertions(+), 22 deletions(-) commit 0b423ca22f95a867f789aab1fe57ee4e378df43b Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:27 2016 -0700 mm, page_alloc: inline pageblock lookup in page free fast paths The function call overhead of get_pfnblock_flags_mask() is measurable in the page free paths. This patch uses an inlined version that is faster. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mmzone.h | 7 -- mm/page_alloc.c | 188 ++++++++++++++++++++++++++----------------------- mm/page_owner.c | 2 +- mm/vmstat.c | 2 +- 4 files changed, 102 insertions(+), 97 deletions(-) commit e5b31ac2ca2cd0cf6bf2fcbb708ed01466c89aaa Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:24 2016 -0700 mm, page_alloc: remove unnecessary variable from free_pcppages_bulk The original count is never reused so it can be removed. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit da838d4fcba675cbf864f225d76f970e91220ee6 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:21 2016 -0700 mm, page_alloc: pull out side effects from free_pages_check Check without side-effects should be easier to maintain. It also removes the duplicated cpupid and flags reset done in !DEBUG_VM variant of both free_pcp_prepare() and then bulkfree_pcp_prepare(). Finally, it enables the next patch. It shouldn't result in new branches, thanks to inlining of the check. !DEBUG_VM bloat-o-meter: add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-27 (-27) function old new delta __free_pages_ok 748 739 -9 free_pcppages_bulk 1403 1385 -18 DEBUG_VM: add/remove: 0/0 grow/shrink: 0/1 up/down: 0/-28 (-28) function old new delta free_pages_prepare 806 778 -28 This is also slightly faster because cpupid information is not set on tail pages so we can avoid resets there. Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit bb552ac6c6b4f24e7a7b491286f87b63f9478d42 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:18 2016 -0700 mm, page_alloc: un-inline the bad part of free_pages_check From: Vlastimil Babka <vbabka@suse.cz> !DEBUG_VM size and bloat-o-meter: add/remove: 1/0 grow/shrink: 0/2 up/down: 124/-370 (-246) function old new delta free_pages_check_bad - 124 +124 free_pcppages_bulk 1288 1171 -117 __free_pages_ok 948 695 -253 DEBUG_VM: add/remove: 1/0 grow/shrink: 0/1 up/down: 124/-214 (-90) function old new delta free_pages_check_bad - 124 +124 free_pages_prepare 1112 898 -214 [akpm@linux-foundation.org: fix whitespace] Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 7bfec6f47bb0ffd207c7e813e819235e6c1c0f34 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:15 2016 -0700 mm, page_alloc: check multiple page fields with a single branch Every page allocated or freed is checked for sanity to avoid corruptions that are difficult to detect later. A bad page could be due to a number of fields. Instead of using multiple branches, this patch combines multiple fields into a single branch. A detailed check is only necessary if that check fails. 4.6.0-rc2 4.6.0-rc2 initonce-v1r20 multcheck-v1r20 Min alloc-odr0-1 359.00 ( 0.00%) 348.00 ( 3.06%) Min alloc-odr0-2 260.00 ( 0.00%) 254.00 ( 2.31%) Min alloc-odr0-4 214.00 ( 0.00%) 213.00 ( 0.47%) Min alloc-odr0-8 186.00 ( 0.00%) 186.00 ( 0.00%) Min alloc-odr0-16 173.00 ( 0.00%) 173.00 ( 0.00%) Min alloc-odr0-32 165.00 ( 0.00%) 166.00 ( -0.61%) Min alloc-odr0-64 162.00 ( 0.00%) 162.00 ( 0.00%) Min alloc-odr0-128 161.00 ( 0.00%) 160.00 ( 0.62%) Min alloc-odr0-256 170.00 ( 0.00%) 169.00 ( 0.59%) Min alloc-odr0-512 181.00 ( 0.00%) 180.00 ( 0.55%) Min alloc-odr0-1024 190.00 ( 0.00%) 188.00 ( 1.05%) Min alloc-odr0-2048 196.00 ( 0.00%) 194.00 ( 1.02%) Min alloc-odr0-4096 202.00 ( 0.00%) 199.00 ( 1.49%) Min alloc-odr0-8192 205.00 ( 0.00%) 202.00 ( 1.46%) Min alloc-odr0-16384 205.00 ( 0.00%) 203.00 ( 0.98%) Again, the benefit is marginal but avoiding excessive branches is important. Ideally the paths would not have to check these conditions at all but regrettably abandoning the tests would make use-after-free bugs much harder to detect. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 55 +++++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 43 insertions(+), 12 deletions(-) commit 93ea9964d14ad583492ffb9ab7543f015876aaf2 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:13 2016 -0700 mm, page_alloc: remove field from alloc_context The classzone_idx can be inferred from preferred_zoneref so remove the unnecessary field and save stack space. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/compaction.c | 4 ++-- mm/internal.h | 3 ++- mm/page_alloc.c | 8 +++----- 3 files changed, 7 insertions(+), 8 deletions(-) commit c33d6c06f60f710f0305ae792773e1c2560e1e51 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:10 2016 -0700 mm, page_alloc: avoid looking up the first zone in a zonelist twice The allocator fast path looks up the first usable zone in a zonelist and then get_page_from_freelist does the same job in the zonelist iterator. This patch preserves the necessary information. 4.6.0-rc2 4.6.0-rc2 fastmark-v1r20 initonce-v1r20 Min alloc-odr0-1 364.00 ( 0.00%) 359.00 ( 1.37%) Min alloc-odr0-2 262.00 ( 0.00%) 260.00 ( 0.76%) Min alloc-odr0-4 214.00 ( 0.00%) 214.00 ( 0.00%) Min alloc-odr0-8 186.00 ( 0.00%) 186.00 ( 0.00%) Min alloc-odr0-16 173.00 ( 0.00%) 173.00 ( 0.00%) Min alloc-odr0-32 165.00 ( 0.00%) 165.00 ( 0.00%) Min alloc-odr0-64 161.00 ( 0.00%) 162.00 ( -0.62%) Min alloc-odr0-128 159.00 ( 0.00%) 161.00 ( -1.26%) Min alloc-odr0-256 168.00 ( 0.00%) 170.00 ( -1.19%) Min alloc-odr0-512 180.00 ( 0.00%) 181.00 ( -0.56%) Min alloc-odr0-1024 190.00 ( 0.00%) 190.00 ( 0.00%) Min alloc-odr0-2048 196.00 ( 0.00%) 196.00 ( 0.00%) Min alloc-odr0-4096 202.00 ( 0.00%) 202.00 ( 0.00%) Min alloc-odr0-8192 206.00 ( 0.00%) 205.00 ( 0.49%) Min alloc-odr0-16384 206.00 ( 0.00%) 205.00 ( 0.49%) The benefit is negligible and the results are within the noise but each cycle counts. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/buffer.c | 10 +++++----- include/linux/mmzone.h | 18 +++++++++++------- mm/internal.h | 2 +- mm/mempolicy.c | 19 ++++++++++--------- mm/page_alloc.c | 34 ++++++++++++++++------------------ 5 files changed, 43 insertions(+), 40 deletions(-) commit 48ee5f3696f62496481a8b6d852bcad9b3ebbe37 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:07 2016 -0700 mm, page_alloc: shortcut watermark checks for order-0 pages Watermarks have to be checked on every allocation including the number of pages being allocated and whether reserves can be accessed. The reserves only matter if memory is limited and the free_pages adjustment only applies to high-order pages. This patch adds a shortcut for order-0 pages that avoids numerous calculations if there is plenty of free memory yielding the following performance difference in a page allocator microbenchmark; 4.6.0-rc2 4.6.0-rc2 optfair-v1r20 fastmark-v1r20 Min alloc-odr0-1 380.00 ( 0.00%) 364.00 ( 4.21%) Min alloc-odr0-2 273.00 ( 0.00%) 262.00 ( 4.03%) Min alloc-odr0-4 227.00 ( 0.00%) 214.00 ( 5.73%) Min alloc-odr0-8 196.00 ( 0.00%) 186.00 ( 5.10%) Min alloc-odr0-16 183.00 ( 0.00%) 173.00 ( 5.46%) Min alloc-odr0-32 173.00 ( 0.00%) 165.00 ( 4.62%) Min alloc-odr0-64 169.00 ( 0.00%) 161.00 ( 4.73%) Min alloc-odr0-128 169.00 ( 0.00%) 159.00 ( 5.92%) Min alloc-odr0-256 180.00 ( 0.00%) 168.00 ( 6.67%) Min alloc-odr0-512 190.00 ( 0.00%) 180.00 ( 5.26%) Min alloc-odr0-1024 198.00 ( 0.00%) 190.00 ( 4.04%) Min alloc-odr0-2048 204.00 ( 0.00%) 196.00 ( 3.92%) Min alloc-odr0-4096 209.00 ( 0.00%) 202.00 ( 3.35%) Min alloc-odr0-8192 213.00 ( 0.00%) 206.00 ( 3.29%) Min alloc-odr0-16384 214.00 ( 0.00%) 206.00 ( 3.74%) Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) commit 305347550becd08fdb576df32fc0767842ed71a6 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:04 2016 -0700 mm, page_alloc: reduce cost of fair zone allocation policy retry The fair zone allocation policy is not without cost but it can be reduced slightly. This patch removes an unnecessary local variable, checks the likely conditions of the fair zone policy first, uses a bool instead of a flags check and falls through when a remote node is encountered instead of doing a full restart. The benefit is marginal but it's there 4.6.0-rc2 4.6.0-rc2 decstat-v1r20 optfair-v1r20 Min alloc-odr0-1 377.00 ( 0.00%) 380.00 ( -0.80%) Min alloc-odr0-2 273.00 ( 0.00%) 273.00 ( 0.00%) Min alloc-odr0-4 226.00 ( 0.00%) 227.00 ( -0.44%) Min alloc-odr0-8 196.00 ( 0.00%) 196.00 ( 0.00%) Min alloc-odr0-16 183.00 ( 0.00%) 183.00 ( 0.00%) Min alloc-odr0-32 175.00 ( 0.00%) 173.00 ( 1.14%) Min alloc-odr0-64 172.00 ( 0.00%) 169.00 ( 1.74%) Min alloc-odr0-128 170.00 ( 0.00%) 169.00 ( 0.59%) Min alloc-odr0-256 183.00 ( 0.00%) 180.00 ( 1.64%) Min alloc-odr0-512 191.00 ( 0.00%) 190.00 ( 0.52%) Min alloc-odr0-1024 199.00 ( 0.00%) 198.00 ( 0.50%) Min alloc-odr0-2048 204.00 ( 0.00%) 204.00 ( 0.00%) Min alloc-odr0-4096 210.00 ( 0.00%) 209.00 ( 0.48%) Min alloc-odr0-8192 213.00 ( 0.00%) 213.00 ( 0.00%) Min alloc-odr0-16384 214.00 ( 0.00%) 214.00 ( 0.00%) The benefit is marginal at best but one of the most important benefits, avoiding a second search when falling back to another node is not triggered by this particular test so the benefit for some corner cases is understated. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) commit 4fcb0971175f6037590d7b7772fe6619261d2165 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:14:01 2016 -0700 mm, page_alloc: shorten the page allocator fast path The page allocator fast path checks page multiple times unnecessarily. This patch avoids all the slowpath checks if the first allocation attempt succeeds. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) commit 3777999dd47ec00ec34a151b1d93c0a2b721e822 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:58 2016 -0700 mm, page_alloc: check once if a zone has isolated pageblocks When bulk freeing pages from the per-cpu lists the zone is checked for isolated pageblocks on every release. This patch checks it once per drain. [mgorman@techsingularity.net: fix locking radce, per Vlastimil] Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 83d4ca8148fd9092715fd8ef75b30bbfd67fd2a9 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:56 2016 -0700 mm, page_alloc: move __GFP_HARDWALL modifications out of the fastpath __GFP_HARDWALL only has meaning in the context of cpusets but the fast path always applies the flag on the first attempt. Move the manipulations into the cpuset paths where they will be masked by a static branch in the common case. With the other micro-optimisations in this series combined, the impact on a page allocator microbenchmark is 4.6.0-rc2 4.6.0-rc2 decstat-v1r20 micro-v1r20 Min alloc-odr0-1 381.00 ( 0.00%) 377.00 ( 1.05%) Min alloc-odr0-2 275.00 ( 0.00%) 273.00 ( 0.73%) Min alloc-odr0-4 229.00 ( 0.00%) 226.00 ( 1.31%) Min alloc-odr0-8 199.00 ( 0.00%) 196.00 ( 1.51%) Min alloc-odr0-16 186.00 ( 0.00%) 183.00 ( 1.61%) Min alloc-odr0-32 179.00 ( 0.00%) 175.00 ( 2.23%) Min alloc-odr0-64 174.00 ( 0.00%) 172.00 ( 1.15%) Min alloc-odr0-128 172.00 ( 0.00%) 170.00 ( 1.16%) Min alloc-odr0-256 181.00 ( 0.00%) 183.00 ( -1.10%) Min alloc-odr0-512 193.00 ( 0.00%) 191.00 ( 1.04%) Min alloc-odr0-1024 201.00 ( 0.00%) 199.00 ( 1.00%) Min alloc-odr0-2048 206.00 ( 0.00%) 204.00 ( 0.97%) Min alloc-odr0-4096 212.00 ( 0.00%) 210.00 ( 0.94%) Min alloc-odr0-8192 215.00 ( 0.00%) 213.00 ( 0.93%) Min alloc-odr0-16384 216.00 ( 0.00%) 214.00 ( 0.93%) Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 09940a4f1e816abe3248fa0d185fc0e7f54c8c12 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:53 2016 -0700 mm, page_alloc: simplify last cpupid reset The current reset unnecessarily clears flags and makes pointless calculations. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 5bb1b169757875a72e05bfcbb76e22602cb1a760 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:50 2016 -0700 mm, page_alloc: remove unnecessary initialisation from __alloc_pages_nodemask() page is guaranteed to be set before it is read with or without the initialisation. [akpm@linux-foundation.org: fix warning] Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit be06af002f6d50de10fd602ce3a6aa5d28e88d38 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:47 2016 -0700 mm, page_alloc: remove unnecessary initialisation in get_page_from_freelist Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4dfa6cd8fdb1682586d463bc34888980fe98eb46 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:44 2016 -0700 mm, page_alloc: remove unnecessary local variable in get_page_from_freelist zonelist here is a copy of a struct field that is used once. Ditch it. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit fa379b9586c7507c607d031dadf3681ed29614a9 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:41 2016 -0700 mm, page_alloc: convert nr_fair_skipped to bool The number of zones skipped to a zone expiring its fair zone allocation quota is irrelevant. Convert to bool. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c603844bdcb5238980de8d58b393f52d7729d651 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:38 2016 -0700 mm, page_alloc: convert alloc_flags to unsigned alloc_flags is a bitmask of flags but it is signed which does not necessarily generate the best code depending on the compiler. Even without an impact, it makes more sense that this be unsigned. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compaction.h | 6 +++--- include/linux/mmzone.h | 3 ++- mm/compaction.c | 12 +++++++----- mm/internal.h | 2 +- mm/page_alloc.c | 26 ++++++++++++++------------ 5 files changed, 27 insertions(+), 22 deletions(-) commit f75fb889d18d362e336f8d3fba158a8636d0a063 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:36 2016 -0700 mm, page_alloc: avoid unnecessary zone lookups during pageblock operations Pageblocks have an associated bitmap to store migrate types and whether the pageblock should be skipped during compaction. The bitmap may be associated with a memory section or a zone but the zone is looked up unconditionally. The compiler should optimise this away automatically so this is a cosmetic patch only in many cases. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) commit 754078eb45df8069f389f3371002e7e24962e1a2 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:33 2016 -0700 mm, page_alloc: use __dec_zone_state for order-0 page allocation __dec_zone_state is cheaper to use for removing an order-0 page as it has fewer conditions to check. The performance difference on a page allocator microbenchmark is; 4.6.0-rc2 4.6.0-rc2 optiter-v1r20 decstat-v1r20 Min alloc-odr0-1 382.00 ( 0.00%) 381.00 ( 0.26%) Min alloc-odr0-2 282.00 ( 0.00%) 275.00 ( 2.48%) Min alloc-odr0-4 233.00 ( 0.00%) 229.00 ( 1.72%) Min alloc-odr0-8 203.00 ( 0.00%) 199.00 ( 1.97%) Min alloc-odr0-16 188.00 ( 0.00%) 186.00 ( 1.06%) Min alloc-odr0-32 182.00 ( 0.00%) 179.00 ( 1.65%) Min alloc-odr0-64 177.00 ( 0.00%) 174.00 ( 1.69%) Min alloc-odr0-128 175.00 ( 0.00%) 172.00 ( 1.71%) Min alloc-odr0-256 184.00 ( 0.00%) 181.00 ( 1.63%) Min alloc-odr0-512 197.00 ( 0.00%) 193.00 ( 2.03%) Min alloc-odr0-1024 203.00 ( 0.00%) 201.00 ( 0.99%) Min alloc-odr0-2048 209.00 ( 0.00%) 206.00 ( 1.44%) Min alloc-odr0-4096 214.00 ( 0.00%) 212.00 ( 0.93%) Min alloc-odr0-8192 218.00 ( 0.00%) 215.00 ( 1.38%) Min alloc-odr0-16384 219.00 ( 0.00%) 216.00 ( 1.37%) Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 682a3385e7734fa3abbd504cbeb5fe91793f1827 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:30 2016 -0700 mm, page_alloc: inline the fast path of the zonelist iterator The page allocator iterates through a zonelist for zones that match the addressing limitations and nodemask of the caller but many allocations will not be restricted. Despite this, there is always functional call overhead which builds up. This patch inlines the optimistic basic case and only calls the iterator function for the complex case. A hindrance was the fact that cpuset_current_mems_allowed is used in the fastpath as the allowed nodemask even though all nodes are allowed on most systems. The patch handles this by only considering cpuset_current_mems_allowed if a cpuset exists. As well as being faster in the fast-path, this removes some junk in the slowpath. The performance difference on a page allocator microbenchmark is; 4.6.0-rc2 4.6.0-rc2 statinline-v1r20 optiter-v1r20 Min alloc-odr0-1 412.00 ( 0.00%) 382.00 ( 7.28%) Min alloc-odr0-2 301.00 ( 0.00%) 282.00 ( 6.31%) Min alloc-odr0-4 247.00 ( 0.00%) 233.00 ( 5.67%) Min alloc-odr0-8 215.00 ( 0.00%) 203.00 ( 5.58%) Min alloc-odr0-16 199.00 ( 0.00%) 188.00 ( 5.53%) Min alloc-odr0-32 191.00 ( 0.00%) 182.00 ( 4.71%) Min alloc-odr0-64 187.00 ( 0.00%) 177.00 ( 5.35%) Min alloc-odr0-128 185.00 ( 0.00%) 175.00 ( 5.41%) Min alloc-odr0-256 193.00 ( 0.00%) 184.00 ( 4.66%) Min alloc-odr0-512 207.00 ( 0.00%) 197.00 ( 4.83%) Min alloc-odr0-1024 213.00 ( 0.00%) 203.00 ( 4.69%) Min alloc-odr0-2048 220.00 ( 0.00%) 209.00 ( 5.00%) Min alloc-odr0-4096 226.00 ( 0.00%) 214.00 ( 5.31%) Min alloc-odr0-8192 229.00 ( 0.00%) 218.00 ( 4.80%) Min alloc-odr0-16384 229.00 ( 0.00%) 219.00 ( 4.37%) perf indicated that next_zones_zonelist disappeared in the profile and __next_zones_zonelist did not appear. This is expected as the micro-benchmark would hit the inlined fast-path every time. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mmzone.h | 13 +++++++++++-- mm/mmzone.c | 2 +- mm/page_alloc.c | 26 +++++++++----------------- 3 files changed, 21 insertions(+), 20 deletions(-) commit 060e74173f292fb3e0398b3dca8765568d195ff1 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:27 2016 -0700 mm, page_alloc: inline zone_statistics zone_statistics has one call-site but it's a public function. Make it static and inline. The performance difference on a page allocator microbenchmark is; 4.6.0-rc2 4.6.0-rc2 statbranch-v1r20 statinline-v1r20 Min alloc-odr0-1 419.00 ( 0.00%) 412.00 ( 1.67%) Min alloc-odr0-2 305.00 ( 0.00%) 301.00 ( 1.31%) Min alloc-odr0-4 250.00 ( 0.00%) 247.00 ( 1.20%) Min alloc-odr0-8 219.00 ( 0.00%) 215.00 ( 1.83%) Min alloc-odr0-16 203.00 ( 0.00%) 199.00 ( 1.97%) Min alloc-odr0-32 195.00 ( 0.00%) 191.00 ( 2.05%) Min alloc-odr0-64 191.00 ( 0.00%) 187.00 ( 2.09%) Min alloc-odr0-128 189.00 ( 0.00%) 185.00 ( 2.12%) Min alloc-odr0-256 198.00 ( 0.00%) 193.00 ( 2.53%) Min alloc-odr0-512 210.00 ( 0.00%) 207.00 ( 1.43%) Min alloc-odr0-1024 216.00 ( 0.00%) 213.00 ( 1.39%) Min alloc-odr0-2048 221.00 ( 0.00%) 220.00 ( 0.45%) Min alloc-odr0-4096 227.00 ( 0.00%) 226.00 ( 0.44%) Min alloc-odr0-8192 232.00 ( 0.00%) 229.00 ( 1.29%) Min alloc-odr0-16384 232.00 ( 0.00%) 229.00 ( 1.29%) Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/vmstat.h | 2 -- mm/page_alloc.c | 31 +++++++++++++++++++++++++++++++ mm/vmstat.c | 29 ----------------------------- 3 files changed, 31 insertions(+), 31 deletions(-) commit b9f00e147f27d86691f7f52a3c8126d25432477c Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:24 2016 -0700 mm, page_alloc: reduce branches in zone_statistics zone_statistics has more branches than it really needs to take an unlikely GFP flag into account. Reduce the number and annotate the unlikely flag. The performance difference on a page allocator microbenchmark is; 4.6.0-rc2 4.6.0-rc2 nocompound-v1r10 statbranch-v1r10 Min alloc-odr0-1 417.00 ( 0.00%) 419.00 ( -0.48%) Min alloc-odr0-2 308.00 ( 0.00%) 305.00 ( 0.97%) Min alloc-odr0-4 253.00 ( 0.00%) 250.00 ( 1.19%) Min alloc-odr0-8 221.00 ( 0.00%) 219.00 ( 0.90%) Min alloc-odr0-16 205.00 ( 0.00%) 203.00 ( 0.98%) Min alloc-odr0-32 199.00 ( 0.00%) 195.00 ( 2.01%) Min alloc-odr0-64 193.00 ( 0.00%) 191.00 ( 1.04%) Min alloc-odr0-128 191.00 ( 0.00%) 189.00 ( 1.05%) Min alloc-odr0-256 200.00 ( 0.00%) 198.00 ( 1.00%) Min alloc-odr0-512 212.00 ( 0.00%) 210.00 ( 0.94%) Min alloc-odr0-1024 219.00 ( 0.00%) 216.00 ( 1.37%) Min alloc-odr0-2048 225.00 ( 0.00%) 221.00 ( 1.78%) Min alloc-odr0-4096 231.00 ( 0.00%) 227.00 ( 1.73%) Min alloc-odr0-8192 234.00 ( 0.00%) 232.00 ( 0.85%) Min alloc-odr0-16384 234.00 ( 0.00%) 232.00 ( 0.85%) Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmstat.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit 175145748d00794369317070dd19ce12dd816241 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:21 2016 -0700 mm, page_alloc: use new PageAnonHead helper in the free page fast path The PageAnon check always checks for compound_head but this is a relatively expensive check if the caller already knows the page is a head page. This patch creates a helper and uses it in the page free path which only operates on head pages. With this patch and "Only check PageCompound for high-order pages", the performance difference on a page allocator microbenchmark is; 4.6.0-rc2 4.6.0-rc2 vanilla nocompound-v1r20 Min alloc-odr0-1 425.00 ( 0.00%) 417.00 ( 1.88%) Min alloc-odr0-2 313.00 ( 0.00%) 308.00 ( 1.60%) Min alloc-odr0-4 257.00 ( 0.00%) 253.00 ( 1.56%) Min alloc-odr0-8 224.00 ( 0.00%) 221.00 ( 1.34%) Min alloc-odr0-16 208.00 ( 0.00%) 205.00 ( 1.44%) Min alloc-odr0-32 199.00 ( 0.00%) 199.00 ( 0.00%) Min alloc-odr0-64 195.00 ( 0.00%) 193.00 ( 1.03%) Min alloc-odr0-128 192.00 ( 0.00%) 191.00 ( 0.52%) Min alloc-odr0-256 204.00 ( 0.00%) 200.00 ( 1.96%) Min alloc-odr0-512 213.00 ( 0.00%) 212.00 ( 0.47%) Min alloc-odr0-1024 219.00 ( 0.00%) 219.00 ( 0.00%) Min alloc-odr0-2048 225.00 ( 0.00%) 225.00 ( 0.00%) Min alloc-odr0-4096 230.00 ( 0.00%) 231.00 ( -0.43%) Min alloc-odr0-8192 235.00 ( 0.00%) 234.00 ( 0.43%) Min alloc-odr0-16384 235.00 ( 0.00%) 234.00 ( 0.43%) Min free-odr0-1 215.00 ( 0.00%) 191.00 ( 11.16%) Min free-odr0-2 152.00 ( 0.00%) 136.00 ( 10.53%) Min free-odr0-4 119.00 ( 0.00%) 107.00 ( 10.08%) Min free-odr0-8 106.00 ( 0.00%) 96.00 ( 9.43%) Min free-odr0-16 97.00 ( 0.00%) 87.00 ( 10.31%) Min free-odr0-32 91.00 ( 0.00%) 83.00 ( 8.79%) Min free-odr0-64 89.00 ( 0.00%) 81.00 ( 8.99%) Min free-odr0-128 88.00 ( 0.00%) 80.00 ( 9.09%) Min free-odr0-256 106.00 ( 0.00%) 95.00 ( 10.38%) Min free-odr0-512 116.00 ( 0.00%) 111.00 ( 4.31%) Min free-odr0-1024 125.00 ( 0.00%) 118.00 ( 5.60%) Min free-odr0-2048 133.00 ( 0.00%) 126.00 ( 5.26%) Min free-odr0-4096 136.00 ( 0.00%) 130.00 ( 4.41%) Min free-odr0-8192 138.00 ( 0.00%) 130.00 ( 5.80%) Min free-odr0-16384 137.00 ( 0.00%) 130.00 ( 5.11%) There is a sizable boost to the free allocator performance. While there is an apparent boost on the allocation side, it's likely a co-incidence or due to the patches slightly reducing cache footprint. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/page-flags.h | 7 ++++++- mm/page_alloc.c | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) commit d61f8590397480981f0d3ee7a2b38b5ea990db52 Author: Mel Gorman <mgorman@techsingularity.net> Date: Thu May 19 17:13:18 2016 -0700 mm, page_alloc: only check PageCompound for high-order pages Another year, another round of page allocator optimisations focusing this time on the alloc and free fast paths. This should be of help to workloads that are allocator-intensive from kernel space where the cost of zeroing is not nceessraily incurred. The series is motivated by the observation that page alloc microbenchmarks on multiple machines regressed between 3.12.44 and 4.4. Second, there is discussions before LSF/MM considering the possibility of adding another page allocator which is potentially hazardous but a patch series improving performance is better than whining. After the series is applied, there are still hazards. In the free paths, the debugging checking and page zone/pageblock lookups dominate but there was not an obvious solution to that. In the alloc path, the major contributers are dealing with zonelists, new page preperation, the fair zone allocation and numerous statistic updates. The fair zone allocator is removed by the per-node LRU series if that gets merged so it's nor a major concern at the moment. On normal userspace benchmarks, there is little impact as the zeroing cost is significant but it's visible aim9 4.6.0-rc3 4.6.0-rc3 vanilla deferalloc-v3 Min page_test 828693.33 ( 0.00%) 887060.00 ( 7.04%) Min brk_test 4847266.67 ( 0.00%) 4966266.67 ( 2.45%) Min exec_test 1271.00 ( 0.00%) 1275.67 ( 0.37%) Min fork_test 12371.75 ( 0.00%) 12380.00 ( 0.07%) The overall impact on a page allocator microbenchmark for a range of orders and number of pages allocated in a batch is 4.6.0-rc3 4.6.0-rc3 vanilla deferalloc-v3r7 Min alloc-odr0-1 428.00 ( 0.00%) 316.00 ( 26.17%) Min alloc-odr0-2 314.00 ( 0.00%) 231.00 ( 26.43%) Min alloc-odr0-4 256.00 ( 0.00%) 192.00 ( 25.00%) Min alloc-odr0-8 222.00 ( 0.00%) 166.00 ( 25.23%) Min alloc-odr0-16 207.00 ( 0.00%) 154.00 ( 25.60%) Min alloc-odr0-32 197.00 ( 0.00%) 148.00 ( 24.87%) Min alloc-odr0-64 193.00 ( 0.00%) 144.00 ( 25.39%) Min alloc-odr0-128 191.00 ( 0.00%) 143.00 ( 25.13%) Min alloc-odr0-256 203.00 ( 0.00%) 153.00 ( 24.63%) Min alloc-odr0-512 212.00 ( 0.00%) 165.00 ( 22.17%) Min alloc-odr0-1024 221.00 ( 0.00%) 172.00 ( 22.17%) Min alloc-odr0-2048 225.00 ( 0.00%) 179.00 ( 20.44%) Min alloc-odr0-4096 232.00 ( 0.00%) 185.00 ( 20.26%) Min alloc-odr0-8192 235.00 ( 0.00%) 187.00 ( 20.43%) Min alloc-odr0-16384 236.00 ( 0.00%) 188.00 ( 20.34%) Min alloc-odr1-1 519.00 ( 0.00%) 450.00 ( 13.29%) Min alloc-odr1-2 391.00 ( 0.00%) 336.00 ( 14.07%) Min alloc-odr1-4 313.00 ( 0.00%) 268.00 ( 14.38%) Min alloc-odr1-8 277.00 ( 0.00%) 235.00 ( 15.16%) Min alloc-odr1-16 256.00 ( 0.00%) 218.00 ( 14.84%) Min alloc-odr1-32 252.00 ( 0.00%) 212.00 ( 15.87%) Min alloc-odr1-64 244.00 ( 0.00%) 206.00 ( 15.57%) Min alloc-odr1-128 244.00 ( 0.00%) 207.00 ( 15.16%) Min alloc-odr1-256 243.00 ( 0.00%) 207.00 ( 14.81%) Min alloc-odr1-512 245.00 ( 0.00%) 209.00 ( 14.69%) Min alloc-odr1-1024 248.00 ( 0.00%) 214.00 ( 13.71%) Min alloc-odr1-2048 253.00 ( 0.00%) 220.00 ( 13.04%) Min alloc-odr1-4096 258.00 ( 0.00%) 224.00 ( 13.18%) Min alloc-odr1-8192 261.00 ( 0.00%) 229.00 ( 12.26%) Min alloc-odr2-1 560.00 ( 0.00%) 753.00 (-34.46%) Min alloc-odr2-2 424.00 ( 0.00%) 351.00 ( 17.22%) Min alloc-odr2-4 339.00 ( 0.00%) 393.00 (-15.93%) Min alloc-odr2-8 298.00 ( 0.00%) 246.00 ( 17.45%) Min alloc-odr2-16 276.00 ( 0.00%) 227.00 ( 17.75%) Min alloc-odr2-32 271.00 ( 0.00%) 221.00 ( 18.45%) Min alloc-odr2-64 264.00 ( 0.00%) 217.00 ( 17.80%) Min alloc-odr2-128 264.00 ( 0.00%) 217.00 ( 17.80%) Min alloc-odr2-256 264.00 ( 0.00%) 218.00 ( 17.42%) Min alloc-odr2-512 269.00 ( 0.00%) 223.00 ( 17.10%) Min alloc-odr2-1024 279.00 ( 0.00%) 230.00 ( 17.56%) Min alloc-odr2-2048 283.00 ( 0.00%) 235.00 ( 16.96%) Min alloc-odr2-4096 285.00 ( 0.00%) 239.00 ( 16.14%) Min alloc-odr3-1 629.00 ( 0.00%) 505.00 ( 19.71%) Min alloc-odr3-2 472.00 ( 0.00%) 374.00 ( 20.76%) Min alloc-odr3-4 383.00 ( 0.00%) 301.00 ( 21.41%) Min alloc-odr3-8 341.00 ( 0.00%) 266.00 ( 21.99%) Min alloc-odr3-16 316.00 ( 0.00%) 248.00 ( 21.52%) Min alloc-odr3-32 308.00 ( 0.00%) 241.00 ( 21.75%) Min alloc-odr3-64 305.00 ( 0.00%) 241.00 ( 20.98%) Min alloc-odr3-128 308.00 ( 0.00%) 244.00 ( 20.78%) Min alloc-odr3-256 317.00 ( 0.00%) 249.00 ( 21.45%) Min alloc-odr3-512 327.00 ( 0.00%) 256.00 ( 21.71%) Min alloc-odr3-1024 331.00 ( 0.00%) 261.00 ( 21.15%) Min alloc-odr3-2048 333.00 ( 0.00%) 266.00 ( 20.12%) Min alloc-odr4-1 767.00 ( 0.00%) 572.00 ( 25.42%) Min alloc-odr4-2 578.00 ( 0.00%) 429.00 ( 25.78%) Min alloc-odr4-4 474.00 ( 0.00%) 346.00 ( 27.00%) Min alloc-odr4-8 422.00 ( 0.00%) 310.00 ( 26.54%) Min alloc-odr4-16 399.00 ( 0.00%) 295.00 ( 26.07%) Min alloc-odr4-32 392.00 ( 0.00%) 293.00 ( 25.26%) Min alloc-odr4-64 394.00 ( 0.00%) 293.00 ( 25.63%) Min alloc-odr4-128 405.00 ( 0.00%) 305.00 ( 24.69%) Min alloc-odr4-256 417.00 ( 0.00%) 319.00 ( 23.50%) Min alloc-odr4-512 425.00 ( 0.00%) 326.00 ( 23.29%) Min alloc-odr4-1024 426.00 ( 0.00%) 329.00 ( 22.77%) Min free-odr0-1 216.00 ( 0.00%) 178.00 ( 17.59%) Min free-odr0-2 152.00 ( 0.00%) 125.00 ( 17.76%) Min free-odr0-4 120.00 ( 0.00%) 99.00 ( 17.50%) Min free-odr0-8 106.00 ( 0.00%) 85.00 ( 19.81%) Min free-odr0-16 97.00 ( 0.00%) 80.00 ( 17.53%) Min free-odr0-32 92.00 ( 0.00%) 76.00 ( 17.39%) Min free-odr0-64 89.00 ( 0.00%) 74.00 ( 16.85%) Min free-odr0-128 89.00 ( 0.00%) 73.00 ( 17.98%) Min free-odr0-256 107.00 ( 0.00%) 90.00 ( 15.89%) Min free-odr0-512 117.00 ( 0.00%) 108.00 ( 7.69%) Min free-odr0-1024 125.00 ( 0.00%) 118.00 ( 5.60%) Min free-odr0-2048 132.00 ( 0.00%) 125.00 ( 5.30%) Min free-odr0-4096 135.00 ( 0.00%) 130.00 ( 3.70%) Min free-odr0-8192 137.00 ( 0.00%) 130.00 ( 5.11%) Min free-odr0-16384 137.00 ( 0.00%) 131.00 ( 4.38%) Min free-odr1-1 318.00 ( 0.00%) 289.00 ( 9.12%) Min free-odr1-2 228.00 ( 0.00%) 207.00 ( 9.21%) Min free-odr1-4 182.00 ( 0.00%) 165.00 ( 9.34%) Min free-odr1-8 163.00 ( 0.00%) 146.00 ( 10.43%) Min free-odr1-16 151.00 ( 0.00%) 135.00 ( 10.60%) Min free-odr1-32 146.00 ( 0.00%) 129.00 ( 11.64%) Min free-odr1-64 145.00 ( 0.00%) 130.00 ( 10.34%) Min free-odr1-128 148.00 ( 0.00%) 134.00 ( 9.46%) Min free-odr1-256 148.00 ( 0.00%) 137.00 ( 7.43%) Min free-odr1-512 151.00 ( 0.00%) 140.00 ( 7.28%) Min free-odr1-1024 154.00 ( 0.00%) 143.00 ( 7.14%) Min free-odr1-2048 156.00 ( 0.00%) 144.00 ( 7.69%) Min free-odr1-4096 156.00 ( 0.00%) 142.00 ( 8.97%) Min free-odr1-8192 156.00 ( 0.00%) 140.00 ( 10.26%) Min free-odr2-1 361.00 ( 0.00%) 457.00 (-26.59%) Min free-odr2-2 258.00 ( 0.00%) 224.00 ( 13.18%) Min free-odr2-4 208.00 ( 0.00%) 223.00 ( -7.21%) Min free-odr2-8 185.00 ( 0.00%) 160.00 ( 13.51%) Min free-odr2-16 173.00 ( 0.00%) 149.00 ( 13.87%) Min free-odr2-32 166.00 ( 0.00%) 145.00 ( 12.65%) Min free-odr2-64 166.00 ( 0.00%) 146.00 ( 12.05%) Min free-odr2-128 169.00 ( 0.00%) 148.00 ( 12.43%) Min free-odr2-256 170.00 ( 0.00%) 152.00 ( 10.59%) Min free-odr2-512 177.00 ( 0.00%) 156.00 ( 11.86%) Min free-odr2-1024 182.00 ( 0.00%) 162.00 ( 10.99%) Min free-odr2-2048 181.00 ( 0.00%) 160.00 ( 11.60%) Min free-odr2-4096 180.00 ( 0.00%) 159.00 ( 11.67%) Min free-odr3-1 431.00 ( 0.00%) 367.00 ( 14.85%) Min free-odr3-2 306.00 ( 0.00%) 259.00 ( 15.36%) Min free-odr3-4 249.00 ( 0.00%) 208.00 ( 16.47%) Min free-odr3-8 224.00 ( 0.00%) 186.00 ( 16.96%) Min free-odr3-16 208.00 ( 0.00%) 176.00 ( 15.38%) Min free-odr3-32 206.00 ( 0.00%) 174.00 ( 15.53%) Min free-odr3-64 210.00 ( 0.00%) 178.00 ( 15.24%) Min free-odr3-128 215.00 ( 0.00%) 182.00 ( 15.35%) Min free-odr3-256 224.00 ( 0.00%) 189.00 ( 15.62%) Min free-odr3-512 232.00 ( 0.00%) 195.00 ( 15.95%) Min free-odr3-1024 230.00 ( 0.00%) 195.00 ( 15.22%) Min free-odr3-2048 229.00 ( 0.00%) 193.00 ( 15.72%) Min free-odr4-1 561.00 ( 0.00%) 439.00 ( 21.75%) Min free-odr4-2 418.00 ( 0.00%) 318.00 ( 23.92%) Min free-odr4-4 339.00 ( 0.00%) 269.00 ( 20.65%) Min free-odr4-8 299.00 ( 0.00%) 239.00 ( 20.07%) Min free-odr4-16 289.00 ( 0.00%) 234.00 ( 19.03%) Min free-odr4-32 291.00 ( 0.00%) 235.00 ( 19.24%) Min free-odr4-64 298.00 ( 0.00%) 238.00 ( 20.13%) Min free-odr4-128 308.00 ( 0.00%) 251.00 ( 18.51%) Min free-odr4-256 321.00 ( 0.00%) 267.00 ( 16.82%) Min free-odr4-512 327.00 ( 0.00%) 269.00 ( 17.74%) Min free-odr4-1024 326.00 ( 0.00%) 271.00 ( 16.87%) Min total-odr0-1 644.00 ( 0.00%) 494.00 ( 23.29%) Min total-odr0-2 466.00 ( 0.00%) 356.00 ( 23.61%) Min total-odr0-4 376.00 ( 0.00%) 291.00 ( 22.61%) Min total-odr0-8 328.00 ( 0.00%) 251.00 ( 23.48%) Min total-odr0-16 304.00 ( 0.00%) 234.00 ( 23.03%) Min total-odr0-32 289.00 ( 0.00%) 224.00 ( 22.49%) Min total-odr0-64 282.00 ( 0.00%) 218.00 ( 22.70%) Min total-odr0-128 280.00 ( 0.00%) 216.00 ( 22.86%) Min total-odr0-256 310.00 ( 0.00%) 243.00 ( 21.61%) Min total-odr0-512 329.00 ( 0.00%) 273.00 ( 17.02%) Min total-odr0-1024 346.00 ( 0.00%) 290.00 ( 16.18%) Min total-odr0-2048 357.00 ( 0.00%) 304.00 ( 14.85%) Min total-odr0-4096 367.00 ( 0.00%) 315.00 ( 14.17%) Min total-odr0-8192 372.00 ( 0.00%) 317.00 ( 14.78%) Min total-odr0-16384 373.00 ( 0.00%) 319.00 ( 14.48%) Min total-odr1-1 838.00 ( 0.00%) 739.00 ( 11.81%) Min total-odr1-2 619.00 ( 0.00%) 543.00 ( 12.28%) Min total-odr1-4 495.00 ( 0.00%) 433.00 ( 12.53%) Min total-odr1-8 440.00 ( 0.00%) 382.00 ( 13.18%) Min total-odr1-16 407.00 ( 0.00%) 353.00 ( 13.27%) Min total-odr1-32 398.00 ( 0.00%) 341.00 ( 14.32%) Min total-odr1-64 389.00 ( 0.00%) 336.00 ( 13.62%) Min total-odr1-128 392.00 ( 0.00%) 341.00 ( 13.01%) Min total-odr1-256 391.00 ( 0.00%) 344.00 ( 12.02%) Min total-odr1-512 396.00 ( 0.00%) 349.00 ( 11.87%) Min total-odr1-1024 402.00 ( 0.00%) 357.00 ( 11.19%) Min total-odr1-2048 409.00 ( 0.00%) 364.00 ( 11.00%) Min total-odr1-4096 414.00 ( 0.00%) 366.00 ( 11.59%) Min total-odr1-8192 417.00 ( 0.00%) 369.00 ( 11.51%) Min total-odr2-1 921.00 ( 0.00%) 1210.00 (-31.38%) Min total-odr2-2 682.00 ( 0.00%) 576.00 ( 15.54%) Min total-odr2-4 547.00 ( 0.00%) 616.00 (-12.61%) Min total-odr2-8 483.00 ( 0.00%) 406.00 ( 15.94%) Min total-odr2-16 449.00 ( 0.00%) 376.00 ( 16.26%) Min total-odr2-32 437.00 ( 0.00%) 366.00 ( 16.25%) Min total-odr2-64 431.00 ( 0.00%) 363.00 ( 15.78%) Min total-odr2-128 433.00 ( 0.00%) 365.00 ( 15.70%) Min total-odr2-256 434.00 ( 0.00%) 371.00 ( 14.52%) Min total-odr2-512 446.00 ( 0.00%) 379.00 ( 15.02%) Min total-odr2-1024 461.00 ( 0.00%) 392.00 ( 14.97%) Min total-odr2-2048 464.00 ( 0.00%) 395.00 ( 14.87%) Min total-odr2-4096 465.00 ( 0.00%) 398.00 ( 14.41%) Min total-odr3-1 1060.00 ( 0.00%) 872.00 ( 17.74%) Min total-odr3-2 778.00 ( 0.00%) 633.00 ( 18.64%) Min total-odr3-4 632.00 ( 0.00%) 510.00 ( 19.30%) Min total-odr3-8 565.00 ( 0.00%) 452.00 ( 20.00%) Min total-odr3-16 524.00 ( 0.00%) 424.00 ( 19.08%) Min total-odr3-32 514.00 ( 0.00%) 415.00 ( 19.26%) Min total-odr3-64 515.00 ( 0.00%) 419.00 ( 18.64%) Min total-odr3-128 523.00 ( 0.00%) 426.00 ( 18.55%) Min total-odr3-256 541.00 ( 0.00%) 438.00 ( 19.04%) Min total-odr3-512 559.00 ( 0.00%) 451.00 ( 19.32%) Min total-odr3-1024 561.00 ( 0.00%) 456.00 ( 18.72%) Min total-odr3-2048 562.00 ( 0.00%) 459.00 ( 18.33%) Min total-odr4-1 1328.00 ( 0.00%) 1011.00 ( 23.87%) Min total-odr4-2 997.00 ( 0.00%) 747.00 ( 25.08%) Min total-odr4-4 813.00 ( 0.00%) 615.00 ( 24.35%) Min total-odr4-8 721.00 ( 0.00%) 550.00 ( 23.72%) Min total-odr4-16 689.00 ( 0.00%) 529.00 ( 23.22%) Min total-odr4-32 683.00 ( 0.00%) 528.00 ( 22.69%) Min total-odr4-64 692.00 ( 0.00%) 531.00 ( 23.27%) Min total-odr4-128 713.00 ( 0.00%) 556.00 ( 22.02%) Min total-odr4-256 738.00 ( 0.00%) 586.00 ( 20.60%) Min total-odr4-512 753.00 ( 0.00%) 595.00 ( 20.98%) Min total-odr4-1024 752.00 ( 0.00%) 600.00 ( 20.21%) This patch (of 27): order-0 pages by definition cannot be compound so avoid the check in the fast path for those pages. [akpm@linux-foundation.org: use unlikely(order) in free_pages_prepare(), per Vlastimil] Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) commit 449d777d7ad6d7f9ac5ed8f618fa13e6ff36c32f Author: Michal Hocko <mhocko@suse.com> Date: Thu May 19 17:13:15 2016 -0700 mm, oom_reaper: clear TIF_MEMDIE for all tasks queued for oom_reaper Right now the oom reaper will clear TIF_MEMDIE only for tasks which were successfully reaped. This is the safest option because we know that such an oom victim would only block forward progress of the oom killer without a good reason because it is highly unlikely it would release much more memory. Basically most of its memory has been already torn down. We can relax this assumption to catch more corner cases though. The first obvious one is when the oom victim clears its mm and gets stuck later on. oom_reaper would back of on find_lock_task_mm returning NULL. We can safely try to clear TIF_MEMDIE in this case because such a task would be ignored by the oom killer anyway. The flag would be cleared by that time already most of the time anyway. The less obvious one is when the oom reaper fails due to mmap_sem contention. Even if we clear TIF_MEMDIE for this task then it is not very likely that we would select another task too easily because we haven't reaped the last victim and so it would be still the #1 candidate. There is a rare race condition possible when the current victim terminates before the next select_bad_process but considering that oom_reap_task had retried several times before giving up then this sounds like a borderline thing. After this patch we should have a guarantee that the OOM killer will not be block for unbounded amount of time for most cases. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Raushaniya Maksudova <rmaksudova@parallels.com> Cc: Michael S. Tsirkin <mst@redhat.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: David Rientjes <rientjes@google.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/oom_kill.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit 3ef22dfff2390e75b379f9715388a852aa56e0d5 Author: Michal Hocko <mhocko@suse.com> Date: Thu May 19 17:13:12 2016 -0700 oom, oom_reaper: try to reap tasks which skip regular OOM killer path If either the current task is already killed or PF_EXITING or a selected task is PF_EXITING then the oom killer is suppressed and so is the oom reaper. This patch adds try_oom_reaper which checks the given task and queues it for the oom reaper if that is safe to be done meaning that the task doesn't share the mm with an alive process. This might help to release the memory pressure while the task tries to exit. [akpm@linux-foundation.org: fix nommu build] Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Raushaniya Maksudova <rmaksudova@parallels.com> Cc: Michael S. Tsirkin <mst@redhat.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: David Rientjes <rientjes@google.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/oom.h | 8 +++++ mm/memcontrol.c | 1 + mm/oom_kill.c | 86 ++++++++++++++++++++++++++++++++++++++++++----------- 3 files changed, 77 insertions(+), 18 deletions(-) commit 3da88fb3bacfaa33ff9d13730d17110bb2d9604d Author: Michal Hocko <mhocko@suse.com> Date: Thu May 19 17:13:09 2016 -0700 mm, oom: move GFP_NOFS check to out_of_memory __alloc_pages_may_oom is the central place to decide when the out_of_memory should be invoked. This is a good approach for most checks there because they are page allocator specific and the allocation fails right after for all of them. The notable exception is GFP_NOFS context which is faking did_some_progress and keep the page allocator looping even though there couldn't have been any progress from the OOM killer. This patch doesn't change this behavior because we are not ready to allow those allocation requests to fail yet (and maybe we will face the reality that we will never manage to safely fail these request). Instead __GFP_FS check is moved down to out_of_memory and prevent from OOM victim selection there. There are two reasons for that - OOM notifiers might release some memory even from this context as none of the registered notifier seems to be FS related - this might help a dying thread to get an access to memory reserves and move on which will make the behavior more consistent with the case when the task gets killed from a different context. Keep a comment in __alloc_pages_may_oom to make sure we do not forget how GFP_NOFS is special and that we really want to do something about it. Note to the current oom_notifier users: The observable difference for you is that oom notifiers cannot depend on any fs locks because we could deadlock. Not that this would be allowed today because that would just lockup machine in most of the cases and ruling out the OOM killer along the way. Another difference is that callbacks might be invoked sooner now because GFP_NOFS is a weaker reclaim context and so there could be reclaimable memory which is just not reachable now. That would require GFP_NOFS only loads which are really rare and more importantly the observable result would be dropping of reconstructible object and potential performance drop which is not such a big deal when we are struggling to fulfill other important allocation requests. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Raushaniya Maksudova <rmaksudova@parallels.com> Cc: Michael S. Tsirkin <mst@redhat.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: David Rientjes <rientjes@google.com> Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/oom_kill.c | 9 +++++++++ mm/page_alloc.c | 24 ++++++++++-------------- 2 files changed, 19 insertions(+), 14 deletions(-) commit 86dd995d63241039e0ad9123f9b424013c611510 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Thu May 19 17:13:06 2016 -0700 memory_hotplug: introduce memhp_default_state= command line parameter CONFIG_MEMORY_HOTPLUG_DEFAULT_ONLINE specifies the default value for the memory hotplug onlining policy. Add a command line parameter to make it possible to override the default. It may come handy for debug and testing purposes. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Dan Williams <dan.j.williams@intel.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: David Vrabel <david.vrabel@citrix.com> Cc: David Rientjes <rientjes@google.com> Cc: Igor Mammedov <imammedo@redhat.com> Cc: Lennart Poettering <lennart@poettering.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/kernel-parameters.txt | 8 ++++++++ mm/memory_hotplug.c | 11 +++++++++++ 2 files changed, 19 insertions(+) commit 8604d9e534a3e662600e288bcfd1a5acd2763d28 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Thu May 19 17:13:03 2016 -0700 memory_hotplug: introduce CONFIG_MEMORY_HOTPLUG_DEFAULT_ONLINE This patchset continues the work I started with commit 31bc3858ea3e ("memory-hotplug: add automatic onlining policy for the newly added memory"). Initially I was going to stop there and bring the policy setting logic to userspace. I met two issues on this way: 1) It is possible to have memory hotplugged at boot (e.g. with QEMU). These blocks stay offlined if we turn the onlining policy on by userspace. 2) My attempt to bring this policy setting to systemd failed, systemd maintainers suggest to change the default in kernel or ... to use tmpfiles.d to alter the policy (which looks like a hack to me): https://github.com/systemd/systemd/pull/2938 Here I suggest to add a config option to set the default value for the policy and a kernel command line parameter to make the override. This patch (of 2): Introduce config option to set the default value for memory hotplug onlining policy (/sys/devices/system/memory/auto_online_blocks). The reason one would want to turn this option on are to have early onlining for hotpluggable memory available at boot and to not require any userspace actions to make memory hotplug work. [akpm@linux-foundation.org: tweak Kconfig text] Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Dan Williams <dan.j.williams@intel.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: David Vrabel <david.vrabel@citrix.com> Cc: David Rientjes <rientjes@google.com> Cc: Igor Mammedov <imammedo@redhat.com> Cc: Lennart Poettering <lennart@poettering.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/memory-hotplug.txt | 9 +++++---- mm/Kconfig | 16 ++++++++++++++++ mm/memory_hotplug.c | 4 ++++ 3 files changed, 25 insertions(+), 4 deletions(-) commit fd8cfd3000191cb7f5b9ea8640bd46181f6b4b74 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:13:00 2016 -0700 arch: fix has_transparent_hugepage() I've just discovered that the useful-sounding has_transparent_hugepage() is actually an architecture-dependent minefield: on some arches it only builds if CONFIG_TRANSPARENT_HUGEPAGE=y, on others it's also there when not, but on some of those (arm and arm64) it then gives the wrong answer; and on mips alone it's marked __init, which would crash if called later (but so far it has not been called later). Straighten this out: make it available to all configs, with a sensible default in asm-generic/pgtable.h, removing its definitions from those arches (arc, arm, arm64, sparc, tile) which are served by the default, adding #define has_transparent_hugepage has_transparent_hugepage to those (mips, powerpc, s390, x86) which need to override the default at runtime, and removing the __init from mips (but maybe that kind of code should be avoided after init: set a static variable the first time it's called). Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Acked-by: David S. Miller <davem@davemloft.net> Acked-by: Vineet Gupta <vgupta@synopsys.com> [arch/arc] Acked-by: Gerald Schaefer <gerald.schaefer@de.ibm.com> [arch/s390] Acked-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/arc/include/asm/hugepage.h | 2 -- arch/arm/include/asm/pgtable-3level.h | 5 ----- arch/arm64/include/asm/pgtable.h | 5 ----- arch/mips/include/asm/pgtable.h | 1 + arch/mips/mm/tlb-r4k.c | 21 +++++++++++---------- arch/powerpc/include/asm/book3s/64/pgtable.h | 1 + arch/powerpc/include/asm/pgtable.h | 1 - arch/s390/include/asm/pgtable.h | 1 + arch/sparc/include/asm/pgtable_64.h | 2 -- arch/tile/include/asm/pgtable.h | 1 - arch/x86/include/asm/pgtable.h | 1 + include/asm-generic/pgtable.h | 8 ++++++++ 12 files changed, 23 insertions(+), 26 deletions(-) commit 1d069b7dd56728a0eb6acb138dce0d37600dee00 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:57 2016 -0700 huge pagecache: extend mremap pmd rmap lockout to files Whatever huge pagecache implementation we go with, file rmap locking must be added to anon rmap locking, when mremap's move_page_tables() finds a pmd_trans_huge pmd entry: a simple change, let's do it now. Factor out take_rmap_locks() and drop_rmap_locks() to handle the locking for make move_ptes() and move_page_tables(), and delete the VM_BUG_ON_VMA which rejected vm_file and required anon_vma. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/mremap.c | 42 ++++++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 20 deletions(-) commit bf8616d5fa179d6c755f06726567c6d63c6fbbc7 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:54 2016 -0700 huge mm: move_huge_pmd does not need new_vma Remove move_huge_pmd()'s redundant new_vma arg: all it was used for was a VM_NOHUGEPAGE check on new_vma flags, but the new_vma is cloned from the old vma, so a trans_huge_pmd in the new_vma will be as acceptable as it was in the old vma, alignment and size permitting. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/huge_mm.h | 4 +--- mm/huge_memory.c | 7 ++----- mm/mremap.c | 5 ++--- 3 files changed, 5 insertions(+), 11 deletions(-) commit 52b6f46bc163eef17ecba4cd552beeafe2b24453 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:50 2016 -0700 mm: /proc/sys/vm/stat_refresh to force vmstat update Provide /proc/sys/vm/stat_refresh to force an immediate update of per-cpu into global vmstats: useful to avoid a sleep(2) or whatever before checking counts when testing. Originally added to work around a bug which left counts stranded indefinitely on a cpu going idle (an inaccuracy magnified when small below-batch numbers represent "huge" amounts of memory), but I believe that bug is now fixed: nonetheless, this is still a useful knob. Its schedule_on_each_cpu() is probably too expensive just to fold into reading /proc/meminfo itself: give this mode 0600 to prevent abuse. Allow a write or a read to do the same: nothing to read, but "grep -h Shmem /proc/sys/vm/stat_refresh /proc/meminfo" is convenient. Oh, and since global_page_state() itself is careful to disguise any underflow as 0, hack in an "Invalid argument" and pr_warn() if a counter is negative after the refresh - this helped to fix a misaccounting of NR_ISOLATED_FILE in my migration code. But on recent kernels, I find that NR_ALLOC_BATCH and NR_PAGES_SCANNED often go negative some of the time. I have not yet worked out why, but have no evidence that it's actually harmful. Punt for the moment by just ignoring the anomaly on those. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/sysctl/vm.txt | 14 +++++++++++ include/linux/vmstat.h | 4 +++ kernel/sysctl.c | 7 ++++++ mm/vmstat.c | 60 +++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 85 insertions(+) commit 9e18eb29356b7dfd55183bd42cf73919d1590835 Author: Andres Lagar-Cavilla <andreslc@google.com> Date: Thu May 19 17:12:47 2016 -0700 tmpfs: mem_cgroup charge fault to vm_mm not current mm Although shmem_fault() has been careful to count a major fault to vm_mm, shmem_getpage_gfp() has been careless in charging a remote access fault to current->mm owner's memcg instead of to vma->vm_mm owner's memcg: that is inconsistent with all the mem_cgroup charging on remote access faults in mm/memory.c. Fix it by passing fault_mm along with fault_type to shmem_get_page_gfp(); but in that case, now knowing the right mm, it's better for it to handle the PGMAJFAULT updates itself. And let's keep this clutter out of most callers' way: change the common shmem_getpage() wrapper to hide fault_mm and fault_type as well as gfp. Signed-off-by: Andres Lagar-Cavilla <andreslc@google.com> Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/shmem.c | 61 ++++++++++++++++++++++++++++++++++--------------------------- 1 file changed, 34 insertions(+), 27 deletions(-) commit 75edd345e8ede51bc8f00672feff5d622f2b3af6 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:44 2016 -0700 tmpfs: preliminary minor tidyups Make a few cleanups in mm/shmem.c, before going on to complicate it. shmem_alloc_page() will become more complicated: we can't afford to to have that complication duplicated between a CONFIG_NUMA version and a !CONFIG_NUMA version, so rearrange the #ifdef'ery there to yield a single shmem_swapin() and a single shmem_alloc_page(). Yes, it's a shame to inflict the horrid pseudo-vma on non-NUMA configurations, but eliminating it is a larger cleanup: I have an alloc_pages_mpol() patchset not yet ready - mpol handling is subtle and bug-prone, and changed yet again since my last version. Move __SetPageLocked, __SetPageSwapBacked from shmem_getpage_gfp() to shmem_alloc_page(): that SwapBacked flag will be useful in future, to help to distinguish different cases appropriately. And the SGP_DIRTY variant of SGP_CACHE is hard to understand and of little use (IIRC it dates back to when shmem_getpage() returned the page unlocked): kill it and do the necessary in shmem_file_read_iter(). But an arm64 build then complained that info may be uninitialized (where shmem_getpage_gfp() deletes a freshly alloced page beyond eof), and advancing to an "sgp <= SGP_CACHE" test jogged it back to reality. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mempolicy.h | 6 +++++ mm/shmem.c | 69 ++++++++++++++++++----------------------------- 2 files changed, 32 insertions(+), 43 deletions(-) commit fa9949da59a15017a02c86b087c7499d7b5702be Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:41 2016 -0700 mm: use __SetPageSwapBacked and dont ClearPageSwapBacked v3.16 commit 07a427884348 ("mm: shmem: avoid atomic operation during shmem_getpage_gfp") rightly replaced one instance of SetPageSwapBacked by __SetPageSwapBacked, pointing out that the newly allocated page is not yet visible to other users (except speculative get_page_unless_zero- ers, who may not update page flags before their further checks). That was part of a series in which Mel was focused on tmpfs profiles: but almost all SetPageSwapBacked uses can be so optimized, with the same justification. Remove ClearPageSwapBacked from __read_swap_cache_async() error path: it's not an error to free a page with PG_swapbacked set. Follow a convention of __SetPageLocked, __SetPageSwapBacked instead of doing it differently in different places; but that's for tidiness - if the ordering actually mattered, we should not be using the __variants. There's probably scope for further __SetPageFlags in other places, but SwapBacked is the one I'm interested in at the moment. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Reviewed-by: Mel Gorman <mgorman@techsingularity.net> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/migrate.c | 6 +++--- mm/rmap.c | 2 +- mm/shmem.c | 4 ++-- mm/swap_state.c | 3 +-- 4 files changed, 7 insertions(+), 8 deletions(-) commit 9d5e6a9f22311b00a20ff9b072760ad3e73f0d99 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:38 2016 -0700 mm: update_lru_size do the __mod_zone_page_state Konstantin Khlebnikov pointed out (nearly four years ago, when lumpy reclaim was removed) that lru_size can be updated by -nr_taken once per call to isolate_lru_pages(), instead of page by page. Update it inside isolate_lru_pages(), or at its two callsites? I chose to update it at the callsites, rearranging and grouping the updates by nr_taken and nr_scanned together in both. With one exception, mem_cgroup_update_lru_size(,lru,) is then used where __mod_zone_page_state(,NR_LRU_BASE+lru,) is used; and we shall be adding some more calls in a future commit. Make the code a little smaller and simpler by incorporating stat update in lru_size update. The exception was move_active_pages_to_lru(), which aggregated the pgmoved stat update separately from the individual lru_size updates; but I still think this a simplification worth making. However, the __mod_zone_page_state is not peculiar to mem_cgroups: so better use the name update_lru_size, calls mem_cgroup_update_lru_size when CONFIG_MEMCG. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/memcontrol.h | 6 ------ include/linux/mm_inline.h | 24 ++++++++++++++++++------ mm/memcontrol.c | 2 ++ mm/vmscan.c | 23 ++++++++++------------- 4 files changed, 30 insertions(+), 25 deletions(-) commit ca707239e8a7958ffb1c31737d41cae1a674c938 Author: Hugh Dickins <hughd@google.com> Date: Thu May 19 17:12:35 2016 -0700 mm: update_lru_size warn and reset bad lru_size Though debug kernels have a VM_BUG_ON to help protect from misaccounting lru_size, non-debug kernels are liable to wrap it around: and then the vast unsigned long size draws page reclaim into a loop of repeatedly doing nothing on an empty list, without even a cond_resched(). That soft lockup looks confusingly like an over-busy reclaim scenario, with lots of contention on the lru_lock in shrink_inactive_list(): yet has a totally different origin. Help differentiate with a custom warning in mem_cgroup_update_lru_size(), even in non-debug kernels; and reset the size to avoid the lockup. But the particular bug which suggested this change was mine alone, and since fixed. Make it a WARN_ONCE: the first occurrence is the most informative, a flurry may follow, yet even when rate-limited little more is learnt. Signed-off-by: Hugh Dickins <hughd@google.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Yang Shi <yang.shi@linaro.org> Cc: Ning Qu <quning@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Andres Lagar-Cavilla <andreslc@google.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Michal Hocko <mhocko@kernel.org> Cc: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm_inline.h | 2 +- mm/memcontrol.c | 24 ++++++++++++++++++++---- 2 files changed, 21 insertions(+), 5 deletions(-) commit 1269019e69a6798db15edea8921f83215ef954d6 Author: Konstantin Khlebnikov <koct9i@gmail.com> Date: Thu May 19 17:12:32 2016 -0700 mm/mmap: kill hook arch_rebalance_pgtables() Nobody uses it. Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/mmap.c | 5 ----- 1 file changed, 5 deletions(-) commit e87d59f7a2002aa2d4582d4ea16da91dd3c72752 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:29 2016 -0700 mm/vmstat: make node_page_state() handles all zones by itself node_page_state() manually adds statistics per each zone and returns total value for all zones. Whenever we add a new zone, we need to consider this function and it's really troublesome. Make it handle all zones by itself. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmstat.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) commit 33499bfe507c844f2c6f55ae8cec17705d0eda95 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:26 2016 -0700 mm/highmem: make nr_free_highpages() handles all highmem zones by itself nr_free_highpages() manually adds statistics per each highmem zone and returns a total value for them. Whenever we add a new highmem zone, we need to consider this function and it's really troublesome. Make it handle all highmem zones by itself. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/highmem.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit fc2bd799c7c79c84a59da6f9221370bc6f38c503 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:23 2016 -0700 mm/page_alloc: correct highmem memory statistics ZONE_MOVABLE could be treated as highmem so we need to consider it for accurate statistics. And, in following patches, ZONE_CMA will be introduced and it can be treated as highmem, too. So, instead of manually adding stat of ZONE_MOVABLE, looping all zones and check whether the zone is highmem or not and add stat of the zone which can be treated as highmem. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) commit 09b4ab3c433733127f8644290e94548a4cb8122f Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:20 2016 -0700 mm/writeback: correct dirty page calculation for highmem ZONE_MOVABLE could be treated as highmem so we need to consider it for accurate calculation of dirty pages. And, in following patches, ZONE_CMA will be introduced and it can be treated as highmem, too. So, instead of manually adding stat of ZONE_MOVABLE, looping all zones and check whether the zone is highmem or not and add stat of the zone which can be treated as highmem. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page-writeback.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit ba6b0979e346fd91d3b7ef6956d7155877308f0f Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:16 2016 -0700 power: add zone range overlapping check There is a system thats node's pfns are overlapped as follows: -----pfn--------> N0 N1 N2 N0 N1 N2 Therefore, we need to care this overlapping when iterating pfn range. mark_free_pages() iterates requested zone's pfn range and unset all range's bitmap first. And then it marks freepages in a zone to the bitmap. If there is an overlapping zone, above unset could clear previous marked bit and reference to this bitmap in the future will cause the problem. To prevent it, this patch adds a zone check in mark_free_pages(). Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 4 ++++ 1 file changed, 4 insertions(+) commit 9d43f5aec9506d98ad492a783aa8a18226c5d474 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:13 2016 -0700 mm/page_owner: add zone range overlapping check There is a system thats node's pfns are overlapped as follows: -----pfn--------> N0 N1 N2 N0 N1 N2 Therefore, we need to care this overlapping when iterating pfn range. There are one place in page_owner.c that iterates pfn range and it doesn't consider this overlapping. Add it. Without this patch, above system could over count early allocated page number before page_owner is activated. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_owner.c | 3 +++ 1 file changed, 3 insertions(+) commit a91c43c7313a995a8908f8f6b911a85d00fdbffd Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:10 2016 -0700 mm/vmstat: add zone range overlapping check There is a system thats node's pfns are overlapped as follows: -----pfn--------> N0 N1 N2 N0 N1 N2 Therefore, we need to care this overlapping when iterating pfn range. There are two places in vmstat.c that iterates pfn range and they don't consider this overlapping. Add it. Without this patch, above system could over count pageblock number on a zone. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/vmstat.c | 7 +++++++ 1 file changed, 7 insertions(+) commit b9eb63191a6ad70127ebdd83650b810cdc1d1117 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:06 2016 -0700 mm/memory_hotplug: add comment to some functions related to memory hotplug __offline_isolated_pages() and test_pages_isolated() are used by memory hotplug. These functions require that range is in a single zone but there is no code to do this because memory hotplug checks it before calling these functions. To avoid confusing future user of these functions, this patch adds comments to them. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 3 ++- mm/page_isolation.c | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) commit f44b2dda8bc29de36ccdc1e04092de7d0b2d5868 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:12:03 2016 -0700 mm/hugetlb: add same zone check in pfn_range_valid_gigantic() This patchset deals with some problematic sites that iterate pfn ranges. There is a system thats node's pfns are overlapped as follows: -----pfn--------> N0 N1 N2 N0 N1 N2 Therefore, we need to take care of this overlapping when iterating pfn range. I audit many iterating sites that uses pfn_valid(), pfn_valid_within(), zone_start_pfn and etc. and others looks safe to me. This is a preparation step for a new CMA implementation, ZONE_CMA (https://lkml.org/lkml/2015/2/12/95), because it would be easily overlapped with other zones. But, zone overlap check is also needed for the general case so I send it separately. This patch (of 5): alloc_gigantic_page() uses alloc_contig_range() and this requires that the requested range is in a single zone. To satisfy this requirement, add this check to pfn_range_valid_gigantic(). Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Rik van Riel <riel@redhat.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/hugetlb.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 1aa8aea535977f0e0b398f39d052e7befff81da6 Author: Andrew Morton <akpm@linux-foundation.org> Date: Thu May 19 17:12:00 2016 -0700 mm: uninline page_mapped() It's huge. Uninlining it saves 206 bytes per callsite. Shaves 4924 bytes from the x86_64 allmodconfig vmlinux. [akpm@linux-foundation.org: coding-style fixes] Cc: Steve Capper <steve.capper@arm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 21 +-------------------- mm/util.c | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+), 20 deletions(-) commit 29f9cb53d25cd9916537b44b0af7f0b95a2e4438 Author: Chanho Min <chanho.min@lge.com> Date: Thu May 19 17:11:57 2016 -0700 mm/highmem: simplify is_highmem() is_highmem() can be simplified by use of is_highmem_idx(). This patch removes redundant code and will make it easier to maintain if the zone policy is changed or a new zone is added. (akpm: saves me 25 bytes of text per is_highmem() callsite) Signed-off-by: Chanho Min <chanho.min@lge.com> Reviewed-by: Dan Williams <dan.j.williams@intel.com> Cc: Michal Hocko <mhocko@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mmzone.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit fdd048e12c9a46d058f69822cb15641adae181e1 Author: Vlastimil Babka <vbabka@suse.cz> Date: Thu May 19 17:11:55 2016 -0700 mm, compaction: skip blocks where isolation fails in async direct compaction The goal of direct compaction is to quickly make a high-order page available for the pending allocation. Within an aligned block of pages of desired order, a single allocated page that cannot be isolated for migration means that the block cannot fully merge to a buddy page that would satisfy the allocation request. Therefore we can reduce the allocation stall by skipping the rest of the block immediately on isolation failure. For async compaction, this also means a higher chance of succeeding until it detects contention. We however shouldn't completely sacrifice the second objective of compaction, which is to reduce overal long-term memory fragmentation. As a compromise, perform the eager skipping only in direct async compaction, while sync compaction (including kcompactd) remains thorough. Testing was done using stress-highalloc from mmtests, configured for order-4 GFP_KERNEL allocations: 4.6-rc1 4.6-rc1 before after Success 1 Min 24.00 ( 0.00%) 27.00 (-12.50%) Success 1 Mean 30.20 ( 0.00%) 31.60 ( -4.64%) Success 1 Max 37.00 ( 0.00%) 35.00 ( 5.41%) Success 2 Min 42.00 ( 0.00%) 32.00 ( 23.81%) Success 2 Mean 44.00 ( 0.00%) 44.80 ( -1.82%) Success 2 Max 48.00 ( 0.00%) 52.00 ( -8.33%) Success 3 Min 91.00 ( 0.00%) 92.00 ( -1.10%) Success 3 Mean 92.20 ( 0.00%) 92.80 ( -0.65%) Success 3 Max 94.00 ( 0.00%) 93.00 ( 1.06%) We can see that success rates are unaffected by the skipping. 4.6-rc1 4.6-rc1 before after User 2587.42 2566.53 System 482.89 471.20 Elapsed 1395.68 1382.00 Times are not so useful metric for this benchmark as main portion is the interfering kernel builds, but results do hint at reduced system times. 4.6-rc1 4.6-rc1 before after Direct pages scanned 163614 159608 Kswapd pages scanned 2070139 2078790 Kswapd pages reclaimed 2061707 2069757 Direct pages reclaimed 163354 159505 Reduced direct reclaim was unintended, but could be explained by more successful first attempt at (async) direct compaction, which is attempted before the first reclaim attempt in __alloc_pages_slowpath(). Compaction stalls 33052 39853 Compaction success 12121 19773 Compaction failures 20931 20079 Compaction is indeed more successful, and thus less likely to get deferred, so there are also more direct compaction stalls. Page migrate success 3781876 3326819 Page migrate failure 45817 41774 Compaction pages isolated 7868232 6941457 Compaction migrate scanned 168160492 127269354 Compaction migrate prescanned 0 0 Compaction free scanned 2522142582 2326342620 Compaction free direct alloc 0 0 Compaction free dir. all. miss 0 0 Compaction cost 5252 4476 The patch reduces migration scanned pages by 25% thanks to the eager skipping. [hughd@google.com: prevent nr_isolated_* from going negative] Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Hugh Dickins <hughd@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Rik van Riel <riel@redhat.com> Cc: David Rientjes <rientjes@google.com> Cc: Minchan Kim <minchan@kernel.org> Cc: Michal Hocko <mhocko@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/compaction.c | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 80 insertions(+), 9 deletions(-) commit a34753d275576896b06af9baa6f54bee258368c2 Author: Vlastimil Babka <vbabka@suse.cz> Date: Thu May 19 17:11:51 2016 -0700 mm, compaction: reduce spurious pcplist drains Compaction drains the local pcplists each time migration scanner moves away from a cc->order aligned block where it isolated pages for migration, so that the pages freed by migrations can merge into higher orders. The detection is currently coarser than it could be. The cc->last_migrated_pfn variable should track the lowest pfn that was isolated for migration. But it is set to the pfn where isolate_migratepages_block() starts scanning, which is typically the first pfn of the pageblock. There, the scanner might fail to isolate several order-aligned blocks, and then isolate COMPACT_CLUSTER_MAX in another block. This would cause the pcplists drain to be performed, although the scanner didn't yet finish the block where it isolated from. This patch thus makes cc->last_migrated_pfn handling more accurate by setting it to the pfn of an actually isolated page in isolate_migratepages_block(). Although practical effects of this patch are likely low, it arguably makes the intent of the code more obvious. Also the next patch will make async direct compaction skip blocks more aggressively, and draining pcplists due to skipped blocks is wasteful. Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Rik van Riel <riel@redhat.com> Cc: David Rientjes <rientjes@google.com> Cc: Minchan Kim <minchan@kernel.org> Cc: Michal Hocko <mhocko@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/compaction.c | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) commit 06b6640a3902d6d50c1bb4fb1f29a46b207dbf08 Author: Vlastimil Babka <vbabka@suse.cz> Date: Thu May 19 17:11:48 2016 -0700 mm, compaction: wrap calculating first and last pfn of pageblock Compaction code has accumulated numerous instances of manual calculations of the first (inclusive) and last (exclusive) pfn of a pageblock (or a smaller block of given order), given a pfn within the pageblock. Wrap these calculations by introducing pageblock_start_pfn(pfn) and pageblock_end_pfn(pfn) macros. [vbabka@suse.cz: fix crash in get_pfnblock_flags_mask() from isolate_freepages():] Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Rik van Riel <riel@redhat.com> Cc: David Rientjes <rientjes@google.com> Cc: Minchan Kim <minchan@kernel.org> Cc: Michal Hocko <mhocko@suse.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> mm/compaction.c | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) commit e4c5800a3991f0c6a766983535dfc10d51802cf6 Author: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Date: Thu May 19 17:11:46 2016 -0700 mm/rmap: replace BUG_ON(anon_vma->degree) with VM_WARN_ON This check effectively catches anon vma hierarchy inconsistence and some vma corruptions. It was effective for catching corner cases in anon vma reusing logic. For now this code seems stable so check could be hidden under CONFIG_DEBUG_VM and replaced with WARN because it's not so fatal. Signed-off-by: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Suggested-by: Vasily Averin <vvs@virtuozzo.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/rmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fee83b3aba4b7ddb0cb1497a04ddebcaa43f236e Author: Andrew Morton <akpm@linux-foundation.org> Date: Thu May 19 17:11:43 2016 -0700 mm/mempolicy.c:offset_il_node() document and clarify This code was pretty obscure and was relying upon obscure side-effects of next_node(-1, ...) and was relying upon NUMA_NO_NODE being equal to -1. Clean that all up and document the function's intent. Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Xishi Qiu <qiuxishi@huawei.com> Cc: Joonsoo Kim <js1304@gmail.com> Cc: David Rientjes <rientjes@google.com> Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: Laura Abbott <lauraa@codeaurora.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/mempolicy.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit 54f18d35263334ebcc6bf409fee3c0c8c22e5588 Author: Andrew Morton <akpm@linux-foundation.org> Date: Thu May 19 17:11:40 2016 -0700 mm/hugetlb.c: use first_memory_node Instead of open-coding it. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/hugetlb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 949698a31af3b3808b0ff0cca26f36e68953bd1f Author: Li Zhang <zhlcindy@linux.vnet.ibm.com> Date: Thu May 19 17:11:37 2016 -0700 mm/page_alloc: Remove useless parameter of __free_pages_boot_core __free_pages_boot_core has parameter pfn which is not used at all. Remove it. Signed-off-by: Li Zhang <zhlcindy@linux.vnet.ibm.com> Reviewed-by: Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/page_alloc.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit fda3d69be9fe7a24ad32b840cb2ed7c30b6ba1c9 Author: Michal Hocko <mhocko@kernel.org> Date: Thu May 19 17:11:34 2016 -0700 mm/memcontrol.c:mem_cgroup_select_victim_node(): clarify comment > The comment seems to have not much to do with the code? I guess the comment tries to say that the code path is triggered when we charge the page which happens _before_ it is added to the LRU list and so last_scanned_node might contain the stale data. Cc: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/memcontrol.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 4ee815be1d34a6f254b3d09bdebcb27f294f2bd3 Author: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Date: Thu May 19 17:11:32 2016 -0700 mm/mempolicy.c: vma_migratable() can return bool Make vma_migratable() return bool due to this particular function only using either one or zero as its return value. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mempolicy.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit bb00a789e565b96c52b2224c2280f7ac83175bec Author: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Date: Thu May 19 17:11:29 2016 -0700 mm/vmalloc.c: is_vmalloc_addr() can return bool Make is_vmalloc_addr() return bool to improve readability due to this particular function only using either one or zero as its return value. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/mm.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c98940f6fa3d06fa8fec75aa2362b25227573d06 Author: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Date: Thu May 19 17:11:26 2016 -0700 mm/memory_hotplug: is_mem_section_removable() can return bool Make is_mem_section_removable() return bool to improve readability due to this particular function only using either one or zero as its return value. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/memory_hotplug.h | 6 +++--- mm/memory_hotplug.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) commit 32f6271dbdc351dce96b11c5f3567bae8188004f Author: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Date: Thu May 19 17:11:23 2016 -0700 mm/hugetlb: is_vm_hugetlb_page() can return bool Make is_vm_hugetlb_page() return bool to improve readability due to this particular function only using either one or zero as its return value. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/hugetlb_inline.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 2b18e5321f512aa85fd91db835a4c0dcdb2cd063 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:20 2016 -0700 x86: mm: use hugetlb_bad_size() Update setup_hugepagesz() to call hugetlb_bad_size() when unsupported hugepage size is found. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: "H. Peter Anvin" <hpa@zytor.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/x86/mm/hugetlbpage.c | 1 + 1 file changed, 1 insertion(+) commit b3d424f1a534949bce27847aa871b3ce75c60f4d Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:17 2016 -0700 tile: mm: use hugetlb_bad_size() Update setup_hugepagesz() to call hugetlb_bad_size() when unsupported hugepage size is found. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: James Hogan <james.hogan@imgtec.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/tile/mm/hugetlbpage.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 71bf79cc3ff8e7be3e61399c6a9787d0c57c5cd1 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:14 2016 -0700 powerpc: mm: use hugetlb_bad_size() Update setup_hugepagesz() to call hugetlb_bad_size() when unsupported hugepage size is found. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/powerpc/mm/hugetlbpage.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 9cc3387fa29fe7827ea6249a1e138ba2a5965082 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:11 2016 -0700 metag: mm: use hugetlb_bad_size() Update setup_hugepagesz() to call hugetlb_bad_size() when unsupported hugepage size is found. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/metag/mm/hugetlbpage.c | 1 + 1 file changed, 1 insertion(+) commit d77e20cea7183145acff928f64b9cba4c825fd83 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:08 2016 -0700 arm64: mm: use hugetlb_bad_size() Update setup_hugepagesz() to call hugetlb_bad_size() when unsupported hugepage size is found. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/arm64/mm/hugetlbpage.c | 1 + 1 file changed, 1 insertion(+) commit 9fee021d15ddd884d40d1540913474e8112313fe Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu May 19 17:11:04 2016 -0700 mm/hugetlb: introduce hugetlb_bad_size() When any unsupported hugepage size is specified, 'hugepagesz=' and 'hugepages=' should be ignored during command line parsing until any supported hugepage size is found. But currently incorrect number of hugepages are allocated when unsupported size is specified as it fails to ignore the 'hugepages=' command. Test case: Note that this is specific to x86 architecture. Boot the kernel with command line option 'hugepagesz=256M hugepages=X'. After boot, dmesg output shows that X number of hugepages of the size 2M is pre-allocated instead of 0. So, to handle such command line options, introduce new routine hugetlb_bad_size. The routine hugetlb_bad_size sets the global variable parsed_valid_hugepagesz. We are using parsed_valid_hugepagesz to save the state when unsupported hugepagesize is found so that we can ignore the 'hugepages=' parameters after that and then reset the variable when supported hugepage size is found. The routine hugetlb_bad_size can be called while setting 'hugepagesz=' parameter in an architecture specific code. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Cc: Dominik Dingel <dingel@linux.vnet.ibm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: "H. Peter Anvin" <hpa@zytor.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/hugetlb.h | 1 + mm/hugetlb.c | 14 +++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) commit 09a95e29cb30a3930db22d340ddd072a82b6b0db Author: Mike Kravetz <mike.kravetz@oracle.com> Date: Thu May 19 17:11:01 2016 -0700 mm/hugetlb: optimize minimum size (min_size) accounting It was observed that minimum size accounting associated with the hugetlbfs min_size mount option may not perform optimally and as expected. As huge pages/reservations are released from the filesystem and given back to the global pools, they are reserved for subsequent filesystem use as long as the subpool reserved count is less than subpool minimum size. It does not take into account used pages within the filesystem. The filesystem size limits are not exceeded and this is technically not a bug. However, better behavior would be to wait for the number of used pages/reservations associated with the filesystem to drop below the minimum size before taking reservations to satisfy minimum size. An optimization is also made to the hugepage_subpool_get_pages() routine which is called when pages/reservations are allocated. This does not change behavior, but simply avoids the accounting if all reservations have already been taken (subpool reserved count == 0). Signed-off-by: Mike Kravetz <mike.kravetz@oracle.com> Acked-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: Hillf Danton <hillf.zj@alibaba-inc.com> Cc: David Rientjes <rientjes@google.com> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/hugetlb.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 0edaf86cf1a6a97d811fc34765ddbcbc310de564 Author: Andrew Morton <akpm@linux-foundation.org> Date: Thu May 19 17:10:58 2016 -0700 include/linux/nodemask.h: create next_node_in() helper Lots of code does node = next_node(node, XXX); if (node == MAX_NUMNODES) node = first_node(XXX); so create next_node_in() to do this and use it in various places. [mhocko@suse.com: use next_node_in() helper] Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Michal Hocko <mhocko@kernel.org> Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Xishi Qiu <qiuxishi@huawei.com> Cc: Joonsoo Kim <js1304@gmail.com> Cc: David Rientjes <rientjes@google.com> Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: Laura Abbott <lauraa@codeaurora.org> Cc: Hui Zhu <zhuhui@xiaomi.com> Cc: Wang Xiaoqiang <wangxq10@lzu.edu.cn> Cc: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> arch/tile/kernel/setup.c | 4 +--- arch/x86/mm/numa.c | 4 +--- include/linux/nodemask.h | 11 ++++++++++- kernel/cpuset.c | 8 +------- lib/Makefile | 2 +- lib/nodemask.c | 30 ++++++++++++++++++++++++++++++ mm/hugetlb.c | 4 +--- mm/memcontrol.c | 4 +--- mm/mempolicy.c | 24 ++---------------------- mm/page_isolation.c | 9 +++------ mm/slab.c | 13 +++---------- 11 files changed, 54 insertions(+), 59 deletions(-) commit 48a270554a3251681ae11173f2fd6389d943e183 Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Thu May 19 17:10:55 2016 -0700 include/linux: apply __malloc attribute Attach the malloc attribute to a few allocation functions. This helps gcc generate better code by telling it that the return value doesn't alias any existing pointers (which is even more valuable given the pessimizations implied by -fno-strict-aliasing). A simple example of what this allows gcc to do can be seen by looking at the last part of drm_atomic_helper_plane_reset: plane->state = kzalloc(sizeof(*plane->state), GFP_KERNEL); if (plane->state) { plane->state->plane = plane; plane->state->rotation = BIT(DRM_ROTATE_0); } which compiles to e8 99 bf d6 ff callq ffffffff8116d540 <kmem_cache_alloc_trace> 48 85 c0 test %rax,%rax 48 89 83 40 02 00 00 mov %rax,0x240(%rbx) 74 11 je ffffffff814015c4 <drm_atomic_helper_plane_reset+0x64> 48 89 18 mov %rbx,(%rax) 48 8b 83 40 02 00 00 mov 0x240(%rbx),%rax [*] c7 40 40 01 00 00 00 movl $0x1,0x40(%rax) With this patch applied, the instruction at [*] is elided, since the store to plane->state->plane is known to not alter the value of plane->state. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Andi Kleen <ak@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/bootmem.h | 16 ++++++++-------- include/linux/device.h | 12 ++++++------ include/linux/kernel.h | 4 ++-- include/linux/mempool.h | 3 ++- include/linux/slab.h | 16 ++++++++-------- include/linux/string.h | 2 +- 6 files changed, 27 insertions(+), 26 deletions(-) commit d64e85d3e1c59c3664b9ec1183052ec4641ea1e2 Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Thu May 19 17:10:52 2016 -0700 compiler.h: add support for malloc attribute gcc as far back as at least 3.04 documents the function attribute __malloc__. Add a shorthand for attaching that to a function declaration. This was also suggested by Andi Kleen way back in 2002 [1], but didn't get applied, perhaps because gcc at that time generated the exact same code with and without this attribute. This attribute tells the compiler that the return value (if non-NULL) can be assumed not to alias any other valid pointers at the time of the call. Please note that the documentation for a range of gcc versions (starting from around 4.7) contained a somewhat confusing and self-contradicting text: The malloc attribute is used to tell the compiler that a function may be treated as if any non-NULL pointer it returns cannot alias any other pointer valid when the function returns and *that the memory has undefined content*. [...] Standard functions with this property include malloc and *calloc*. (emphasis mine). The intended meaning has later been clarified [2]: This tells the compiler that a function is malloc-like, i.e., that the pointer P returned by the function cannot alias any other pointer valid when the function returns, and moreover no pointers to valid objects occur in any storage addressed by P. What this means is that we can apply the attribute to kmalloc and friends, and it is ok for the returned memory to have well-defined contents (__GFP_ZERO). But it is not ok to apply it to kmemdup(), nor to other functions which both allocate and possibly initialize the memory with existing pointers. So unless someone is doing something pretty perverted kstrdup() should also be a fine candidate. [1] http://thread.gmane.org/gmane.linux.kernel/57172 [2] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56955 Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Andi Kleen <ak@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/compiler-gcc.h | 1 + include/linux/compiler.h | 4 ++++ 2 files changed, 5 insertions(+) commit 0139aa7b7fa12ceef095d99dc36606a5b10ab83a Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:49 2016 -0700 mm: rename _count, field of the struct page, to _refcount Many developers already know that field for reference count of the struct page is _count and atomic type. They would try to handle it directly and this could break the purpose of page reference count tracepoint. To prevent direct _count modification, this patch rename it to _refcount and add warning message on the code. After that, developer who need to handle reference count will find that field should not be accessed directly. [akpm@linux-foundation.org: fix comments, per Vlastimil] [akpm@linux-foundation.org: Documentation/vm/transhuge.txt too] [sfr@canb.auug.org.au: sync ethernet driver changes] Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Hugh Dickins <hughd@google.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: "David S. Miller" <davem@davemloft.net> Cc: Sunil Goutham <sgoutham@cavium.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Manish Chopra <manish.chopra@qlogic.com> Cc: Yuval Mintz <yuval.mintz@qlogic.com> Cc: Tariq Toukan <tariqt@mellanox.com> Cc: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/vm/transhuge.txt | 10 +++++----- arch/tile/mm/init.c | 2 +- drivers/block/aoe/aoecmd.c | 2 +- drivers/hwtracing/intel_th/msu.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 20 +++++++++---------- drivers/net/ethernet/qlogic/qede/qede_main.c | 4 ++-- fs/proc/page.c | 2 +- include/linux/mm.h | 2 +- include/linux/mm_types.h | 14 ++++++++----- include/linux/page_ref.h | 26 ++++++++++++------------- include/linux/pagemap.h | 8 ++++---- kernel/kexec_core.c | 2 +- mm/huge_memory.c | 4 ++-- mm/internal.h | 2 +- mm/page_alloc.c | 4 ++-- mm/slub.c | 4 ++-- mm/vmscan.c | 4 ++-- 17 files changed, 58 insertions(+), 54 deletions(-) commit 6d061f9f6136d477932088c24ce155d7dc785746 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:46 2016 -0700 mm/page_ref: use page_ref helper instead of direct modification of _count page_reference manipulation functions are introduced to track down reference count change of the page. Use it instead of direct modification of _count. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Hugh Dickins <hughd@google.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: "David S. Miller" <davem@davemloft.net> Cc: Sunil Goutham <sgoutham@cavium.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/net/ethernet/cavium/thunder/nicvf_queues.c | 2 +- drivers/net/ethernet/qlogic/qede/qede_main.c | 2 +- mm/filemap.c | 2 +- net/wireless/util.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 43efd3ea64f3cf8920e8793e6953321a466023e3 Author: Li Peng <lip@dtdream.com> Date: Thu May 19 17:10:43 2016 -0700 mm/slub.c: fix sysfs filename in comment /sys/kernel/slab/xx/defrag_ratio should be remote_node_defrag_ratio. Link: http://lkml.kernel.org/r/1463449242-5366-1-git-send-email-lip@dtdream.com Signed-off-by: Li Peng <lip@dtdream.com> Acked-by: Christoph Lameter <cl@linux.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slub.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit a3187e438bc6565d6e54a550a19073d1b453f041 Author: Yang Shi <yang.shi@linaro.org> Date: Thu May 19 17:10:41 2016 -0700 mm: slab: remove ZONE_DMA_FLAG Now we have IS_ENABLED helper to check if a Kconfig option is enabled or not, so ZONE_DMA_FLAG sounds no longer useful. And, the use of ZONE_DMA_FLAG in slab looks pointless according to the comment [1] from Johannes Weiner, so remove them and ORing passed in flags with the cache gfp flags has been done in kmem_getpages(). [1] https://lkml.org/lkml/2014/9/25/553 Link: http://lkml.kernel.org/r/1462381297-11009-1-git-send-email-yang.shi@linaro.org Signed-off-by: Yang Shi <yang.shi@linaro.org> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.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> mm/Kconfig | 5 ----- mm/slab.c | 23 +---------------------- 2 files changed, 1 insertion(+), 27 deletions(-) commit c7ce4f60ac199fb3521c5fcd64da21cee801ec2b Author: Thomas Garnier <thgarnie@google.com> Date: Thu May 19 17:10:37 2016 -0700 mm: SLAB freelist randomization Provides an optional config (CONFIG_SLAB_FREELIST_RANDOM) to randomize the SLAB freelist. The list is randomized during initialization of a new set of pages. The order on different freelist sizes is pre-computed at boot for performance. Each kmem_cache has its own randomized freelist. Before pre-computed lists are available freelists are generated dynamically. This security feature reduces the predictability of the kernel SLAB allocator against heap overflows rendering attacks much less stable. For example this attack against SLUB (also applicable against SLAB) would be affected: https://jon.oberheide.org/blog/2010/09/10/linux-kernel-can-slub-overflow/ Also, since v4.6 the freelist was moved at the end of the SLAB. It means a controllable heap is opened to new attacks not yet publicly discussed. A kernel heap overflow can be transformed to multiple use-after-free. This feature makes this type of attack harder too. To generate entropy, we use get_random_bytes_arch because 0 bits of entropy is available in the boot stage. In the worse case this function will fallback to the get_random_bytes sub API. We also generate a shift random number to shift pre-computed freelist for each new set of pages. The config option name is not specific to the SLAB as this approach will be extended to other allocators like SLUB. Performance results highlighted no major changes: Hackbench (running 90 10 times): Before average: 0.0698 After average: 0.0663 (-5.01%) slab_test 1 run on boot. Difference only seen on the 2048 size test being the worse case scenario covered by freelist randomization. New slab pages are constantly being created on the 10000 allocations. Variance should be mainly due to getting new pages every few allocations. Before: Single thread testing ===================== 1. Kmalloc: Repeatedly allocate then free test 10000 times kmalloc(8) -> 99 cycles kfree -> 112 cycles 10000 times kmalloc(16) -> 109 cycles kfree -> 140 cycles 10000 times kmalloc(32) -> 129 cycles kfree -> 137 cycles 10000 times kmalloc(64) -> 141 cycles kfree -> 141 cycles 10000 times kmalloc(128) -> 152 cycles kfree -> 148 cycles 10000 times kmalloc(256) -> 195 cycles kfree -> 167 cycles 10000 times kmalloc(512) -> 257 cycles kfree -> 199 cycles 10000 times kmalloc(1024) -> 393 cycles kfree -> 251 cycles 10000 times kmalloc(2048) -> 649 cycles kfree -> 228 cycles 10000 times kmalloc(4096) -> 806 cycles kfree -> 370 cycles 10000 times kmalloc(8192) -> 814 cycles kfree -> 411 cycles 10000 times kmalloc(16384) -> 892 cycles kfree -> 455 cycles 2. Kmalloc: alloc/free test 10000 times kmalloc(8)/kfree -> 121 cycles 10000 times kmalloc(16)/kfree -> 121 cycles 10000 times kmalloc(32)/kfree -> 121 cycles 10000 times kmalloc(64)/kfree -> 121 cycles 10000 times kmalloc(128)/kfree -> 121 cycles 10000 times kmalloc(256)/kfree -> 119 cycles 10000 times kmalloc(512)/kfree -> 119 cycles 10000 times kmalloc(1024)/kfree -> 119 cycles 10000 times kmalloc(2048)/kfree -> 119 cycles 10000 times kmalloc(4096)/kfree -> 121 cycles 10000 times kmalloc(8192)/kfree -> 119 cycles 10000 times kmalloc(16384)/kfree -> 119 cycles After: Single thread testing ===================== 1. Kmalloc: Repeatedly allocate then free test 10000 times kmalloc(8) -> 130 cycles kfree -> 86 cycles 10000 times kmalloc(16) -> 118 cycles kfree -> 86 cycles 10000 times kmalloc(32) -> 121 cycles kfree -> 85 cycles 10000 times kmalloc(64) -> 176 cycles kfree -> 102 cycles 10000 times kmalloc(128) -> 178 cycles kfree -> 100 cycles 10000 times kmalloc(256) -> 205 cycles kfree -> 109 cycles 10000 times kmalloc(512) -> 262 cycles kfree -> 136 cycles 10000 times kmalloc(1024) -> 342 cycles kfree -> 157 cycles 10000 times kmalloc(2048) -> 701 cycles kfree -> 238 cycles 10000 times kmalloc(4096) -> 803 cycles kfree -> 364 cycles 10000 times kmalloc(8192) -> 835 cycles kfree -> 404 cycles 10000 times kmalloc(16384) -> 896 cycles kfree -> 441 cycles 2. Kmalloc: alloc/free test 10000 times kmalloc(8)/kfree -> 121 cycles 10000 times kmalloc(16)/kfree -> 121 cycles 10000 times kmalloc(32)/kfree -> 123 cycles 10000 times kmalloc(64)/kfree -> 142 cycles 10000 times kmalloc(128)/kfree -> 121 cycles 10000 times kmalloc(256)/kfree -> 119 cycles 10000 times kmalloc(512)/kfree -> 119 cycles 10000 times kmalloc(1024)/kfree -> 119 cycles 10000 times kmalloc(2048)/kfree -> 119 cycles 10000 times kmalloc(4096)/kfree -> 119 cycles 10000 times kmalloc(8192)/kfree -> 119 cycles 10000 times kmalloc(16384)/kfree -> 119 cycles [akpm@linux-foundation.org: propagate gfp_t into cache_random_seq_create()] Signed-off-by: Thomas Garnier <thgarnie@google.com> Acked-by: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Kees Cook <keescook@chromium.org> Cc: Greg Thelen <gthelen@google.com> Cc: Laura Abbott <labbott@fedoraproject.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/slab_def.h | 4 ++ init/Kconfig | 9 +++ mm/slab.c | 167 ++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 178 insertions(+), 2 deletions(-) commit 81ae6d03952c1bfb96e1a716809bd65e7cd14360 Author: Vladimir Davydov <vdavydov@virtuozzo.com> Date: Thu May 19 17:10:34 2016 -0700 mm/slub.c: replace kick_all_cpus_sync() with synchronize_sched() in kmem_cache_shrink() When we call __kmem_cache_shrink on memory cgroup removal, we need to synchronize kmem_cache->cpu_partial update with put_cpu_partial that might be running on other cpus. Currently, we achieve that by using kick_all_cpus_sync, which works as a system wide memory barrier. Though fast it is, this method has a flaw - it issues a lot of IPIs, which might hurt high performance or real-time workloads. To fix this, let's replace kick_all_cpus_sync with synchronize_sched. Although the latter one may take much longer to finish, it shouldn't be a problem in this particular case, because memory cgroups are destroyed asynchronously from a workqueue so that no user visible effects should be introduced. OTOH, it will save us from excessive IPIs when someone removes a cgroup. Anyway, even if using synchronize_sched turns out to take too long, we can always introduce a kind of __kmem_cache_shrink batching so that this method would only be called once per one cgroup destruction (not per each per memcg kmem cache as it is now). Signed-off-by: Vladimir Davydov <vdavydov@virtuozzo.com> Reported-by: Peter Zijlstra <peterz@infradead.org> Suggested-by: Peter Zijlstra <peterz@infradead.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 801faf0db8947e01877920e848a4d338dd7a99e7 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:31 2016 -0700 mm/slab: lockless decision to grow cache To check whether free objects exist or not precisely, we need to grab a lock. But, accuracy isn't that important because race window would be even small and if there is too much free object, cache reaper would reap it. So, this patch makes the check for free object exisistence not to hold a lock. This will reduce lock contention in heavily allocation case. Note that until now, n->shared can be freed during the processing by writing slabinfo, but, with some trick in this patch, we can access it freely within interrupt disabled period. Below is the result of concurrent allocation/free in slab allocation benchmark made by Christoph a long time ago. I make the output simpler. The number shows cycle count during alloc/free respectively so less is better. * Before Kmalloc N*alloc N*free(32): Average=248/966 Kmalloc N*alloc N*free(64): Average=261/949 Kmalloc N*alloc N*free(128): Average=314/1016 Kmalloc N*alloc N*free(256): Average=741/1061 Kmalloc N*alloc N*free(512): Average=1246/1152 Kmalloc N*alloc N*free(1024): Average=2437/1259 Kmalloc N*alloc N*free(2048): Average=4980/1800 Kmalloc N*alloc N*free(4096): Average=9000/2078 * After Kmalloc N*alloc N*free(32): Average=344/792 Kmalloc N*alloc N*free(64): Average=347/882 Kmalloc N*alloc N*free(128): Average=390/959 Kmalloc N*alloc N*free(256): Average=393/1067 Kmalloc N*alloc N*free(512): Average=683/1229 Kmalloc N*alloc N*free(1024): Average=1295/1325 Kmalloc N*alloc N*free(2048): Average=2513/1664 Kmalloc N*alloc N*free(4096): Average=4742/2172 It shows that allocation performance decreases for the object size up to 128 and it may be due to extra checks in cache_alloc_refill(). But, with considering improvement of free performance, net result looks the same. Result for other size class looks very promising, roughly, 50% performance improvement. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) commit 213b46958c65c7adaaf3201102da16ce0264e9cf Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:29 2016 -0700 mm/slab: refill cpu cache through a new slab without holding a node lock Until now, cache growing makes a free slab on node's slab list and then we can allocate free objects from it. This necessarily requires to hold a node lock which is very contended. If we refill cpu cache before attaching it to node's slab list, we can avoid holding a node lock as much as possible because this newly allocated slab is only visible to the current task. This will reduce lock contention. Below is the result of concurrent allocation/free in slab allocation benchmark made by Christoph a long time ago. I make the output simpler. The number shows cycle count during alloc/free respectively so less is better. * Before Kmalloc N*alloc N*free(32): Average=355/750 Kmalloc N*alloc N*free(64): Average=452/812 Kmalloc N*alloc N*free(128): Average=559/1070 Kmalloc N*alloc N*free(256): Average=1176/980 Kmalloc N*alloc N*free(512): Average=1939/1189 Kmalloc N*alloc N*free(1024): Average=3521/1278 Kmalloc N*alloc N*free(2048): Average=7152/1838 Kmalloc N*alloc N*free(4096): Average=13438/2013 * After Kmalloc N*alloc N*free(32): Average=248/966 Kmalloc N*alloc N*free(64): Average=261/949 Kmalloc N*alloc N*free(128): Average=314/1016 Kmalloc N*alloc N*free(256): Average=741/1061 Kmalloc N*alloc N*free(512): Average=1246/1152 Kmalloc N*alloc N*free(1024): Average=2437/1259 Kmalloc N*alloc N*free(2048): Average=4980/1800 Kmalloc N*alloc N*free(4096): Average=9000/2078 It shows that contention is reduced for all the object sizes and performance increases by 30 ~ 40%. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 68 +++++++++++++++++++++++++++++++++------------------------------ 1 file changed, 36 insertions(+), 32 deletions(-) commit 76b342bdc71badea2cbac7bf6590aa86e895c507 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:26 2016 -0700 mm/slab: separate cache_grow() to two parts This is a preparation step to implement lockless allocation path when there is no free objects in kmem_cache. What we'd like to do here is to refill cpu cache without holding a node lock. To accomplish this purpose, refill should be done after new slab allocation but before attaching the slab to the management list. So, this patch separates cache_grow() to two parts, allocation and attaching to the list in order to add some code inbetween them in the following patch. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 74 ++++++++++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 52 insertions(+), 22 deletions(-) commit 511e3a05881221a7fc63e36f3d604887040fc845 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:23 2016 -0700 mm/slab: make cache_grow() handle the page allocated on arbitrary node Currently, cache_grow() assumes that allocated page's nodeid would be same with parameter nodeid which is used for allocation request. If we discard this assumption, we can handle fallback_alloc() case gracefully. So, this patch makes cache_grow() handle the page allocated on arbitrary node and clean-up relevant code. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 60 +++++++++++++++++++++--------------------------------------- 1 file changed, 21 insertions(+), 39 deletions(-) commit 03d1d43a1262b347a9aa814980438fff8eb32edc Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:20 2016 -0700 mm/slab: racy access/modify the slab color Slab color isn't needed to be changed strictly. Because locking for changing slab color could cause more lock contention so this patch implements racy access/modify the slab color. This is a preparation step to implement lockless allocation path when there is no free objects in the kmem_cache. Below is the result of concurrent allocation/free in slab allocation benchmark made by Christoph a long time ago. I make the output simpler. The number shows cycle count during alloc/free respectively so less is better. * Before Kmalloc N*alloc N*free(32): Average=365/806 Kmalloc N*alloc N*free(64): Average=452/690 Kmalloc N*alloc N*free(128): Average=736/886 Kmalloc N*alloc N*free(256): Average=1167/985 Kmalloc N*alloc N*free(512): Average=2088/1125 Kmalloc N*alloc N*free(1024): Average=4115/1184 Kmalloc N*alloc N*free(2048): Average=8451/1748 Kmalloc N*alloc N*free(4096): Average=16024/2048 * After Kmalloc N*alloc N*free(32): Average=355/750 Kmalloc N*alloc N*free(64): Average=452/812 Kmalloc N*alloc N*free(128): Average=559/1070 Kmalloc N*alloc N*free(256): Average=1176/980 Kmalloc N*alloc N*free(512): Average=1939/1189 Kmalloc N*alloc N*free(1024): Average=3521/1278 Kmalloc N*alloc N*free(2048): Average=7152/1838 Kmalloc N*alloc N*free(4096): Average=13438/2013 It shows that contention is reduced for object size >= 1024 and performance increases by roughly 15%. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Christoph Lameter <cl@linux.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 6052b7880a95554993898f7cac075c2669f1dd7c Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:17 2016 -0700 mm/slab: don't keep free slabs if free_objects exceeds free_limit Currently, determination to free a slab is done whenever each freed object is put into the slab. This has a following problem. Assume free_limit = 10 and nr_free = 9. Free happens as following sequence and nr_free changes as following. free(become a free slab) free(not become a free slab) nr_free: 9 -> 10 (at first free) -> 11 (at second free) If we try to check if we can free current slab or not on each object free, we can't free any slab in this situation because current slab isn't a free slab when nr_free exceed free_limit (at second free) even if there is a free slab. However, if we check it lastly, we can free 1 free slab. This problem would cause to keep too much memory in the slab subsystem. This patch try to fix it by checking number of free object after all free work is done. If there is free slab at that time, we can free slab as much as possible so we keep free slab as minimal. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) commit c3d332b6b2c11ddda9cce3e2f3135b68929d4b82 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:14 2016 -0700 mm/slab: clean-up kmem_cache_node setup There are mostly same code for setting up kmem_cache_node either in cpuup_prepare() or alloc_kmem_cache_node(). Factor out and clean-up them. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Tested-by: Nishanth Menon <nm@ti.com> Tested-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Christoph Lameter <cl@linux.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 168 +++++++++++++++++++++++++------------------------------------- 1 file changed, 68 insertions(+), 100 deletions(-) commit ded0ecf61118930988f0943e741056c8fd5d439c Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:11 2016 -0700 mm/slab: factor out kmem_cache_node initialization code It can be reused on other place, so factor out it. Following patch will use it. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Christoph Lameter <cl@linux.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 74 ++++++++++++++++++++++++++++++++++++++------------------------- 1 file changed, 45 insertions(+), 29 deletions(-) commit a5aa63a5f7352aa8991f64d46854dcb8d3788d55 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:08 2016 -0700 mm/slab: drain the free slab as much as possible slabs_tofree() implies freeing all free slab. We can do it with just providing INT_MAX. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Acked-by: Christoph Lameter <cl@linux.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) commit 8888177ea116d4d14ca0a2ba054d02f35b0dae29 Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:05 2016 -0700 mm/slab: remove BAD_ALIEN_MAGIC again Initial attemp to remove BAD_ALIEN_MAGIC is once reverted by 'commit edcad2509550 ("Revert "slab: remove BAD_ALIEN_MAGIC"")' because it causes a problem on m68k which has many node but !CONFIG_NUMA. In this case, although alien cache isn't used at all but to cope with some initialization path, garbage value is used and that is BAD_ALIEN_MAGIC. Now, this patch set use_alien_caches to 0 when !CONFIG_NUMA, there is no initialization path problem so we don't need BAD_ALIEN_MAGIC at all. So remove it. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Tested-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Christoph Lameter <cl@linux.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 18726ca8b34bbfb3ab5a1c0a52a5d8dd392466ed Author: Joonsoo Kim <iamjoonsoo.kim@lge.com> Date: Thu May 19 17:10:02 2016 -0700 mm/slab: fix the theoretical race by holding proper lock While processing concurrent allocation, SLAB could be contended a lot because it did a lots of work with holding a lock. This patchset try to reduce the number of critical section to reduce lock contention. Major changes are lockless decision to allocate more slab and lockless cpu cache refill from the newly allocated slab. Below is the result of concurrent allocation/free in slab allocation benchmark made by Christoph a long time ago. I make the output simpler. The number shows cycle count during alloc/free respectively so less is better. * Before Kmalloc N*alloc N*free(32): Average=365/806 Kmalloc N*alloc N*free(64): Average=452/690 Kmalloc N*alloc N*free(128): Average=736/886 Kmalloc N*alloc N*free(256): Average=1167/985 Kmalloc N*alloc N*free(512): Average=2088/1125 Kmalloc N*alloc N*free(1024): Average=4115/1184 Kmalloc N*alloc N*free(2048): Average=8451/1748 Kmalloc N*alloc N*free(4096): Average=16024/2048 * After Kmalloc N*alloc N*free(32): Average=344/792 Kmalloc N*alloc N*free(64): Average=347/882 Kmalloc N*alloc N*free(128): Average=390/959 Kmalloc N*alloc N*free(256): Average=393/1067 Kmalloc N*alloc N*free(512): Average=683/1229 Kmalloc N*alloc N*free(1024): Average=1295/1325 Kmalloc N*alloc N*free(2048): Average=2513/1664 Kmalloc N*alloc N*free(4096): Average=4742/2172 It shows that performance improves greatly (roughly more than 50%) for the object class whose size is more than 128 bytes. This patch (of 11): If we don't hold neither the slab_mutex nor the node lock, node's shared array cache could be freed and re-populated. If __kmem_cache_shrink() is called at the same time, it will call drain_array() with n->shared without holding node lock so problem can happen. This patch fix the situation by holding the node lock before trying to drain the shared array. In addition, add a debug check to confirm that n->shared access race doesn't exist. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Christoph Lameter <cl@linux.com> Cc: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> mm/slab.c | 68 ++++++++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 45 insertions(+), 23 deletions(-) commit 19d795b677bda354644cfb87a196b087fdc2a965 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 19 17:09:59 2016 -0700 kernel/padata.c: hide unused functions A recent cleanup removed some exported functions that were not used anywhere, which in turn exposed the fact that some other functions in the same file are only used in some configurations. We now get a warning about them when CONFIG_HOTPLUG_CPU is disabled: kernel/padata.c:670:12: error: '__padata_remove_cpu' defined but not used [-Werror=unused-function] static int __padata_remove_cpu(struct padata_instance *pinst, int cpu) ^~~~~~~~~~~~~~~~~~~ kernel/padata.c:650:12: error: '__padata_add_cpu' defined but not used [-Werror=unused-function] static int __padata_add_cpu(struct padata_instance *pinst, int cpu) This rearranges the code so the __padata_remove_cpu/__padata_add_cpu functions are within the #ifdef that protects the code that calls them. [akpm@linux-foundation.org: coding-style fixes] Fixes: 4ba6d78c671e ("kernel/padata.c: removed unused code") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Richard Cochran <rcochran@linutronix.de> Cc: Steffen Klassert <steffen.klassert@secunet.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/padata.c | 74 ++++++++++++++++++++++++++++----------------------------- 1 file changed, 37 insertions(+), 37 deletions(-) commit 815613da6a67c196d7458d0e6c278ea88e21933f Author: Richard Cochran <rcochran@linutronix.de> Date: Thu May 19 17:09:56 2016 -0700 kernel/padata.c: removed unused code By accident I stumbled across code that has never been used. This driver has EXPORT_SYMBOL functions, and the only user of the code is pcrypt.c, but this only uses a subset of the exported symbols. According to 'git log -G', the functions, padata_set_cpumasks, padata_add_cpu, and padata_remove_cpu have never been used since they were first introduced. This patch removes the unused code. On one 64 bit build, with CRYPTO_PCRYPT built in, the text is more than 4k smaller. kbuild_hp> size $KBUILD_OUTPUT/vmlinux text data bss dec hex filename 10566658 4678360 1122304 16367322 f9beda vmlinux 10561984 4678360 1122304 16362648 f9ac98 vmlinux On another config, 32 bit, the saving is about 0.5k bytes. kbuild_hp-x86> size $KBUILD_OUTPUT/vmlinux 6012005 2409513 2785280 11206798 ab008e vmlinux 6011491 2409513 2785280 11206284 aafe8c vmlinux Signed-off-by: Richard Cochran <rcochran@linutronix.de> Cc: Steffen Klassert <steffen.klassert@secunet.com> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/padata.h | 5 ---- kernel/padata.c | 64 -------------------------------------------------- 2 files changed, 69 deletions(-) commit 8f9b1802c20ace68a7d6603e1fd82a44fedb4078 Author: Guozhonghua <guozhonghua@h3c.com> Date: Thu May 19 17:09:53 2016 -0700 ocfs2: clean up an unneeded goto in ocfs2_put_slot() The goto is not useful in ocfs2_put_slot(), so delete it. Signed-off-by: Guozhonghua <guozhonghua@h3c.com> Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/slot_map.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit aa6913dbd26af386e7703f6c0d4ed2a848b7a052 Author: Jun Piao <piaojun@huawei.com> Date: Thu May 19 17:09:50 2016 -0700 ocfs2: clean up unused parameter 'count' in o2hb_read_block_input() Clean up unused parameter 'count' in o2hb_read_block_input(). Signed-off-by: Jun Piao <piaojun@huawei.com> Reviewed-by: Joseph Qi <joseph.qi@huawei.com> Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/cluster/heartbeat.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit c14688ea248c5ddfb6b8b97151de0a8620ba4a68 Author: piaojun <piaojun@huawei.com> Date: Thu May 19 17:09:47 2016 -0700 ocfs2: clean up an unused variable 'wants_rotate' in ocfs2_truncate_rec Clean up an unused variable 'wants_rotate' in ocfs2_truncate_rec. Signed-off-by: Jun Piao <piaojun@huawei.com> Reviewed-by: Joseph Qi <joseph.qi@huawei.com> Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/alloc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 8ba442214c332a2a10ac90bc24ebb00aea4ae0ec Author: Guozhonghua <guozhonghua@h3c.com> Date: Thu May 19 17:09:44 2016 -0700 ocfs2: fix comment in struct ocfs2_extended_slot The comment in ocfs2_extended_slot has the offset wrong. Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Cc: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/ocfs2/ocfs2_fs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b9fdac7f660609abb157500e468d2165b3c9cf08 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:41 2016 -0700 debugobjects: insulate non-fixup logic related to static obj from fixup callbacks When activating a static object we need make sure that the object is tracked in the object tracker. If it is a non-static object then the activation is illegal. In previous implementation, each subsystem need take care of this in their fixup callbacks. Actually we can put it into debugobjects core. Thus we can save duplicated code, and have *pure* fixup callbacks. To achieve this, a new callback "is_static_object" is introduced to let the type specific code decide whether a object is static or not. If yes, we take it into object tracker, otherwise give warning and invoke fixup callback. This change has paassed debugobjects selftest, and I also do some test with all debugobjects supports enabled. At last, I have a concern about the fixups that can it change the object which is in incorrect state on fixup? Because the 'addr' may not point to any valid object if a non-static object is not tracked. Then Change such object can overwrite someone's memory and cause unexpected behaviour. For example, the timer_fixup_activate bind timer to function stub_timer. Link: http://lkml.kernel.org/r/1462576157-14539-1-git-send-email-changbin.du@intel.com [changbin.du@intel.com: improve code comments where invoke the new is_static_object callback] Link: http://lkml.kernel.org/r/1462777431-8171-1-git-send-email-changbin.du@intel.com Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/debugobjects.h | 2 ++ kernel/rcu/update.c | 26 +++-------------------- kernel/time/hrtimer.c | 7 +------ kernel/time/timer.c | 43 +++++++++++++------------------------- kernel/workqueue.c | 42 ++++++++----------------------------- lib/debugobjects.c | 49 +++++++++++++++++++++++++++++--------------- 6 files changed, 60 insertions(+), 109 deletions(-) commit 8bad1cd0e1edd124c0f05f925762ef84e6047586 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:38 2016 -0700 Documentation: update debugobjects doc Update documentation creangponding to change(debugobjects: make fixup functions return bool instead of int). Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Documentation/DocBook/debugobjects.tmpl | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) commit d99b1d8912654c4bdeb51063d2e934afc2372cc2 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:35 2016 -0700 percpu_counter: update debugobjects fixup callbacks return type Update the return type to use bool instead of int, corresponding to cheange (debugobjects: make fixup functions return bool instead of int). Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/percpu_counter.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 3263d28eb5b93b3c1b024366df87b1d0c774228f Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:32 2016 -0700 rcu: update debugobjects fixup callbacks return type Update the return type to use bool instead of int, corresponding to cheange (debugobjects: make fixup functions return bool instead of int). Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/rcu/update.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e3252464da222ef2c2ca52dff383a824080ea3d5 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:29 2016 -0700 timer: update debugobjects fixup callbacks return type Update the return type to use bool instead of int, corresponding to cheange (debugobjects: make fixup functions return bool instead of int). Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/time/hrtimer.c | 18 +++++++++--------- kernel/time/timer.c | 30 +++++++++++++++--------------- 2 files changed, 24 insertions(+), 24 deletions(-) commit 02a982a6ec631d871571f940ca13817551759884 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:26 2016 -0700 workqueue: update debugobjects fixup callbacks return type Update the return type to use bool instead of int, corresponding to change (debugobjects: make fixup functions return bool instead of int) Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> kernel/workqueue.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit e7a8e78bd4ad931660743bd2dbabd9170a715294 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:23 2016 -0700 debugobjects: correct the usage of fixup call results If debug_object_fixup() return non-zero when problem has been fixed. But the code got it backwards, it taks 0 as fixup successfully. So fix it. Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> lib/debugobjects.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b1e4d9d82df8ab9097f80aa208c40eab6fc29858 Author: Du, Changbin <changbin.du@intel.com> Date: Thu May 19 17:09:20 2016 -0700 debugobjects: make fixup functions return bool instead of int I am going to introduce debugobjects infrastructure to USB subsystem. But before this, I found the code of debugobjects could be improved. This patchset will make fixup functions return bool type instead of int. Because fixup only need report success or no. boolean is the 'real' type. This patch (of 7): The object debugging infrastructure core provides some fixup callbacks for the subsystem who use it. These callbacks are called from the debug code whenever a problem in debug_object_init is detected. And debugobjects core suppose them returns 1 when the fixup was successful, otherwise 0. So the return type is boolean. A bad thing is that debug_object_fixup use the return value for arithmetic operation. It confused me that what is the reall return type. Reading over the whole code, I found some place do use the return value incorrectly(see next patch). So why use bool type instead? Signed-off-by: Du, Changbin <changbin.du@intel.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Josh Triplett <josh@kernel.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tejun Heo <tj@kernel.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/debugobjects.h | 15 ++++++++------- lib/debugobjects.c | 43 +++++++++++++++++++++---------------------- 2 files changed, 29 insertions(+), 29 deletions(-) commit b21e91c305bcebf55b7a34638e5885528f3fb453 Author: Vineet Gupta <Vineet.Gupta1@synopsys.com> Date: Thu May 19 17:09:17 2016 -0700 scripts/bloat-o-meter: print percent change This adds an additional line of output (to reduce the chances of breaking any existing output parsers) which prints the total size before and after and the relative difference. add/remove: 39/0 grow/shrink: 12408/55 up/down: 362227/-1430 (360797) function old new delta ext4_fill_super 10556 12590 +2034 _fpadd_parts - 1186 +1186 ntfs_fill_super 5340 6164 +824 ... ... __divdf3 752 386 -366 unlzma 3682 3274 -408 Total: Before=5023101, After=5383898, chg 7.000000% ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Link: http://lkml.kernel.org/r/1463124110-30314-1-git-send-email-vgupta@synopsys.com Signed-off-by: Vineet Gupta <vgupta@synopsys.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Michal Marek <mmarek@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/bloat-o-meter | 6 ++++++ 1 file changed, 6 insertions(+) commit bad7de742d8192e9759e7f462bd2055a7e7d71f3 Author: Kees Cook <keescook@chromium.org> Date: Thu May 19 17:09:14 2016 -0700 scripts/spelling.txt: add "fimware" misspelling A few instances of "fimware" instead of "firmware" were found. Fix these and add it to the spelling.txt file. Signed-off-by: Kees Cook <keescook@chromium.org> Reported-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/media/usb/dvb-usb/dib0700_core.c | 2 +- drivers/scsi/bfa/bfi.h | 2 +- drivers/staging/comedi/drivers/daqboard2000.c | 2 +- scripts/spelling.txt | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) commit 310c6dd06a0b3c6e808067379cfb56c864e95ffc Author: Konstantin Khlebnikov <koct9i@gmail.com> Date: Thu May 19 17:09:11 2016 -0700 scripts/decode_stacktrace.sh: handle symbols in modules scripts/decode_stacktrace.sh presently displays module symbols as func+0x0ff/0x5153 [module] Add a third argument: the pathname of a directory where the script should look for the file module.ko so that the output appears as func (foo/bar.c:123) module Without the argument or if the module file isn't found the script prints such symbols as is without decoding. Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Sasha Levin <sasha.levin@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> scripts/decode_stacktrace.sh | 55 +++++++++++++++++++++++++++++++------------- 1 file changed, 39 insertions(+), 16 deletions(-) commit 8e4f70e21877297577dce13cca97599a5864a91f Author: Deepa Dinamani <deepa.kernel@gmail.com> Date: Thu May 19 17:09:08 2016 -0700 time: remove timespec_add_safe() All references to timespec_add_safe() now use timespec64_add_safe(). The plan is to replace struct timespec references with struct timespec64 throughout the kernel as timespec is not y2038 safe. Drop timespec_add_safe() and use timespec64_add_safe() for all architectures. Link: http://lkml.kernel.org/r/1461947989-21926-4-git-send-email-deepa.kernel@gmail.com Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Acked-by: John Stultz <john.stultz@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/time64.h | 15 +++++++-------- kernel/time/time.c | 4 ---- 2 files changed, 7 insertions(+), 12 deletions(-) commit 766b9f928bd5b9b185d986d40355d1f143484136 Author: Deepa Dinamani <deepa.kernel@gmail.com> Date: Thu May 19 17:09:05 2016 -0700 fs: poll/select/recvmmsg: use timespec64 for timeout events struct timespec is not y2038 safe. Even though timespec might be sufficient to represent timeouts, use struct timespec64 here as the plan is to get rid of all timespec reference in the kernel. The patch transitions the common functions: poll_select_set_timeout() and select_estimate_accuracy() to use timespec64. And, all the syscalls that use these functions are transitioned in the same patch. The restart block parameters for poll uses monotonic time. Use timespec64 here as well to assign timeout value. This parameter in the restart block need not change because this only holds the monotonic timestamp at which timeout should occur. And, unsigned long data type should be big enough for this timestamp. The system call interfaces will be handled in a separate series. Compat interfaces need not change as timespec64 is an alias to struct timespec on a 64 bit system. Link: http://lkml.kernel.org/r/1461947989-21926-3-git-send-email-deepa.kernel@gmail.com Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Acked-by: John Stultz <john.stultz@linaro.org> Acked-by: David S. Miller <davem@davemloft.net> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/eventpoll.c | 12 +++++----- fs/select.c | 67 +++++++++++++++++++++++++++++----------------------- include/linux/poll.h | 11 +++++---- net/socket.c | 8 ++++--- 4 files changed, 54 insertions(+), 44 deletions(-) commit bc2c53e5f1a2bae69ae50ce3a592633da7fcf6d9 Author: Deepa Dinamani <deepa.kernel@gmail.com> Date: Thu May 19 17:09:02 2016 -0700 time: add missing implementation for timespec64_add_safe() timespec64_add_safe() has been defined in time64.h for 64 bit systems. But, 32 bit systems only have an extern function prototype defined. Provide a definition for the above function. The function will be necessary as part of y2038 changes. struct timespec is not y2038 safe. All references to timespec will be replaced by struct timespec64. The function is meant to be a replacement for timespec_add_safe(). The implementation is similar to timespec_add_safe(). Link: http://lkml.kernel.org/r/1461947989-21926-2-git-send-email-deepa.kernel@gmail.com Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Acked-by: John Stultz <john.stultz@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> include/linux/time64.h | 4 +--- kernel/time/time.c | 25 +++++++++++++++++++++++++ 2 files changed, 26 insertions(+), 3 deletions(-) commit 35e481761cdc688dbee0ef552a13f49af8eba6cc Author: Jan Kara <jack@suse.cz> Date: Thu May 19 17:08:59 2016 -0700 fsnotify: avoid spurious EMFILE errors from inotify_init() Inotify instance is destroyed when all references to it are dropped. That not only means that the corresponding file descriptor needs to be closed but also that all corresponding instance marks are freed (as each mark holds a reference to the inotify instance). However marks are freed only after SRCU period ends which can take some time and thus if user rapidly creates and frees inotify instances, number of existing inotify instances can exceed max_user_instances limit although from user point of view there is always at most one existing instance. Thus inotify_init() returns EMFILE error which is hard to justify from user point of view. This problem is exposed by LTP inotify06 testcase on some machines. We fix the problem by making sure all group marks are properly freed while destroying inotify instance. We wait for SRCU period to end in that path anyway since we have to make sure there is no event being added to the instance while we are tearing down the instance. So it takes only some plumbing to allow for marks to be destroyed in that path as well and not from a dedicated work item. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Jan Kara <jack@suse.cz> Reported-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com> Tested-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/notify/fsnotify.h | 7 ++++ fs/notify/group.c | 17 ++++++--- fs/notify/mark.c | 78 +++++++++++++++++++++++++++++++--------- include/linux/fsnotify_backend.h | 2 -- 4 files changed, 81 insertions(+), 23 deletions(-) commit 03b979dd0323ace8e29a0561cd5232f73a060c09 Merge: e9ad9b9 787ca32 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 18:14:49 2016 -0700 Merge tag 'please-pull-misc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux Pull ia64 updates from Tony Luck: "A bunch of cleanups from Matt and some dead code removal from Anna-Maria" * tag 'please-pull-misc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux: ia64/unaligned: Silence another GCC warning about an uninitialised variable ia64/traps: Silence GCC warning about uninitialised variable ia64: Reduce stack usage by iterating over nodemask ia64/PCI: Remove unused 'addr' and fix build warning ia64/PCI: Fix incorrect PCI resource end address ia64: Remove superfluous SMP function call commit e9ad9b9bd3a3b95c89a29b2a197476e662db4233 Merge: 78975f2 9f80366 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 18:07:25 2016 -0700 Merge tag 'docs-for-linus' of git://git.lwn.net/linux Pull Documentation updates from Jon Corbet: "A bit busier this time around. The most interesting thing (IMO) this time around is some beginning infrastructural work to allow documents to be written using restructured text. Maybe someday, in a galaxy far far away, we'll be able to eliminate the DocBook dependency and have a much better integrated set of kernel docs. Someday. Beyond that, there's a new document on security hardening from Kees, the movement of some sample code over to samples/, a number of improvements to the serial docs from Geert, and the usual collection of corrections, typo fixes, etc" * tag 'docs-for-linus' of git://git.lwn.net/linux: (55 commits) doc: self-protection: provide initial details serial: doc: Use port->state instead of info serial: doc: Always refer to tty_port->mutex Documentation: vm: Spelling s/paltform/platform/g Documentation/memcg: update kmem limit doc as codes behavior docproc: print a comment about autogeneration for rst output docproc: add support for reStructuredText format via --rst option docproc: abstract terminating lines at first space docproc: abstract docproc directive detection docproc: reduce unnecessary indentation docproc: add variables for subcommand and filename kernel-doc: use rst C domain directives and references for types kernel-doc: produce RestructuredText output kernel-doc: rewrite usage description, remove duplicated comments Doc: correct the location of sysrq.c Documentation: fix common spelling mistakes samples: v4l: from Documentation to samples directory samples: connector: from Documentation to samples directory Documentation: xillybus: fix spelling mistake Documentation: x86: fix spelling mistakes ... commit 78975f23cba0cd195db01cdbd6eb48138a655890 Merge: feaa7cb 73e8b05 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 17:48:12 2016 -0700 Merge branch 'i2c/for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux Pull i2c updates from Wolfram Sang: - Peter Rosin did some major rework on the locking of i2c muxes by seperating parent-locked muxes and mux-locked muxes. This avoids deadlocks/workarounds when the mux itself needs i2c commands for muxing. And as a side-effect, other workarounds in the media layer could be eliminated. Also, Peter stepped up as the i2c mux maintainer and will keep an eye on these changes. - major updates to the octeon driver - add a helper to the core to generate the address+rw_bit octal and make drivers use it - quite a bunch of driver updates * 'i2c/for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux: (84 commits) i2c: rcar: add DMA support i2c: st: Implement bus clear i2c: only check scl functions when using generic recovery i2c: algo-bit: declare i2c_bit_quirk_no_clk_stretch as static i2c: tegra: disable clock before returning error [media] rtl2832: regmap is aware of lockdep, drop local locking hack [media] rtl2832_sdr: get rid of empty regmap wrappers [media] rtl2832: change the i2c gate to be mux-locked [media] si2168: change the i2c gate to be mux-locked iio: imu: inv_mpu6050: change the i2c gate to be mux-locked i2c: mux: document i2c muxes and elaborate on parent-/mux-locked muxes i2c: mux: relax locking of the top i2c adapter during mux-locked muxing i2c: muxes always lock the parent adapter i2c: allow adapter drivers to override the adapter locking i2c: uniphier: add "\n" at the end of error log i2c: mv64xxx: remove CONFIG_HAVE_CLK conditionals i2c: mv64xxx: use clk_{prepare_enable,disable_unprepare} i2c: mv64xxx: handle probe deferral for the clock i2c: mv64xxx: enable the driver on ARCH_MVEBU i2c: octeon: Add workaround for broken irqs on CN3860 ... commit 555b67e4e729ca544bb4028ab12e532c68b70ddb Merge: 544ad71 ad438c4 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:34:00 2016 +1000 Merge branch 'xfs-4.7-inode-reclaim' into for-next commit 544ad71fc8e20fb3a6f50f00d487751492cd8409 Merge: 2a4ad58 e6b3bb7 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:33:38 2016 +1000 Merge branch 'xfs-4.7-error-cfg' into for-next commit 2a4ad5894c819978dca5595396d54d51c3aca694 Merge: a7792aa 6e3e6d5 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:33:17 2016 +1000 Merge branch 'xfs-4.7-misc-fixes' into for-next commit a7792aad644a259375002db8c9d9e03fd50bf509 Merge: 5b911354 3ab3ffc Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:32:35 2016 +1000 Merge branch 'xfs-4.7-cleanup-attr-listent' into for-next commit 5b9113547fedca92bb39b828f7f8cd11a153247b Merge: d6bd961 30ee052 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:32:10 2016 +1000 Merge branch 'xfs-4.7-optimise-inline-symlinks' into for-next commit d6bd9615abdf89b147eb200ea4f63156af8a279e Merge: 8b7a242 710b1e2 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:31:52 2016 +1000 Merge branch 'xfs-4.7-trans-type-cleanup' into for-next commit 8b7a242e53e20dc3f2a071ff4d3d8dfa063174dd Merge: ce5c767 690a787 Author: Dave Chinner <david@fromorbit.com> Date: Fri May 20 10:31:29 2016 +1000 Merge branch 'xfs-4.7-writeback-bio' into for-next commit 690a7871225b7f91f8fe13c465a79e183a61cfe3 Author: Christoph Hellwig <hch@lst.de> Date: Fri May 20 10:29:15 2016 +1000 xfs: fix warning in xfs_finish_page_writeback for non-debug builds blockmask is unused if ASSERTs are disabled. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Christoph Hellwig <hch@lst.de> fs/xfs/xfs_aops.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit feaa7cb5c59416143432829b15826be76605b8fe Merge: e0fb1b3 1fa9a1a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 17:25:13 2016 -0700 Merge tag 'md/4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md Pull MD updates from Shaohua Li: "Several patches from Guoqing fixing md-cluster bugs and several patches from Heinz fixing dm-raid bugs" * tag 'md/4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md: md-cluster: check the return value of process_recvd_msg md-cluster: gather resync infos and enable recv_thread after bitmap is ready md: set MD_CHANGE_PENDING in a atomic region md: raid5: add prerequisite to run underneath dm-raid md: raid10: add prerequisite to run underneath dm-raid md: md.c: fix oops in mddev_suspend for raid0 md-cluster: fix ifnullfree.cocci warnings md-cluster/bitmap: unplug bitmap to sync dirty pages to disk md-cluster/bitmap: fix wrong page num in bitmap_file_clear_bit and bitmap_file_set_bit md-cluster/bitmap: fix wrong calcuation of offset md-cluster: sync bitmap when node received RESYNCING msg md-cluster: always setup in-memory bitmap md-cluster: wakeup thread if activated a spare disk md-cluster: change array_sectors and update size are not supported md-cluster: fix locking when node joins cluster during message broadcast md-cluster: unregister thread if err happened md-cluster: wake up thread to continue recovery md-cluser: make resync_finish only called after pers->sync_request md-cluster: change resync lock from asynchronous to synchronous commit e0fb1b36398487475e0d2c50264e4ec1eaed3e11 Merge: f4c80d5 6c0b43d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 17:07:04 2016 -0700 Merge tag 'iommu-updates-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu Pull IOMMU updates from Joerg Roedel: "The updates include: - rate limiting for the VT-d fault handler - remove statistics code from the AMD IOMMU driver. It is unused and should be replaced by something more generic if needed - per-domain pagesize-bitmaps in IOMMU core code to support systems with different types of IOMMUs - support for ACPI devices in the AMD IOMMU driver - 4GB mode support for Mediatek IOMMU driver - ARM-SMMU updates from Will Deacon: - support for 64k pages with SMMUv1 implementations (e.g MMU-401) - remove open-coded 64-bit MMIO accessors - initial support for 16-bit VMIDs, as supported by some ThunderX SMMU implementations - a couple of errata workarounds for silicon in the field - various fixes here and there" * tag 'iommu-updates-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu: (44 commits) iommu/arm-smmu: Use per-domain page sizes. iommu/amd: Remove statistics code iommu/dma: Finish optimising higher-order allocations iommu: Allow selecting page sizes per domain iommu: of: enforce const-ness of struct iommu_ops iommu: remove unused priv field from struct iommu_ops iommu/dma: Implement scatterlist segment merging iommu/arm-smmu: Clear cache lock bit of ACR iommu/arm-smmu: Support SMMUv1 64KB supplement iommu/arm-smmu: Decouple context format from kernel config iommu/arm-smmu: Tidy up 64-bit/atomic I/O accesses io-64-nonatomic: Add relaxed accessor variants iommu/arm-smmu: Work around MMU-500 prefetch errata iommu/arm-smmu: Convert ThunderX workaround to new method iommu/arm-smmu: Differentiate specific implementations iommu/arm-smmu: Workaround for ThunderX erratum #27704 iommu/arm-smmu: Add support for 16 bit VMID iommu/amd: Move get_device_id() and friends to beginning of file iommu/amd: Don't use IS_ERR_VALUE to check integer values iommu/amd: Signedness bug in acpihid_device_group() ... commit 4d9a2c8746671efbb0c27d3ae28c7474597a7aad Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:20 2016 +0200 dax: Remove i_mmap_lock protection Currently faults are protected against truncate by filesystem specific i_mmap_sem and page lock in case of hole page. Cow faults are protected DAX radix tree entry locking. So there's no need for i_mmap_lock in DAX code. Remove it. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/dax.c | 24 +++++------------------- mm/memory.c | 2 -- 2 files changed, 5 insertions(+), 21 deletions(-) commit bc2466e4257369d0ebee2b6265070d323343fa72 Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:19 2016 +0200 dax: Use radix tree entry lock to protect cow faults When doing cow faults, we cannot directly fill in PTE as we do for other faults as we rely on generic code to do proper accounting of the cowed page. We also have no page to lock to protect against races with truncate as other faults have and we need the protection to extend until the moment generic code inserts cowed page into PTE thus at that point we have no protection of fs-specific i_mmap_sem. So far we relied on using i_mmap_lock for the protection however that is completely special to cow faults. To make fault locking more uniform use DAX entry lock instead. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/dax.c | 12 +++++------- include/linux/dax.h | 7 +++++++ include/linux/mm.h | 7 +++++++ mm/memory.c | 38 ++++++++++++++++++-------------------- 4 files changed, 37 insertions(+), 27 deletions(-) commit ac401cc782429cc8560ce4840b1405d603740917 Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:18 2016 +0200 dax: New fault locking Currently DAX page fault locking is racy. CPU0 (write fault) CPU1 (read fault) __dax_fault() __dax_fault() get_block(inode, block, &bh, 0) -> not mapped get_block(inode, block, &bh, 0) -> not mapped if (!buffer_mapped(&bh)) if (vmf->flags & FAULT_FLAG_WRITE) get_block(inode, block, &bh, 1) -> allocates blocks if (page) -> no if (!buffer_mapped(&bh)) if (vmf->flags & FAULT_FLAG_WRITE) { } else { dax_load_hole(); } dax_insert_mapping() And we are in a situation where we fail in dax_radix_entry() with -EIO. Another problem with the current DAX page fault locking is that there is no race-free way to clear dirty tag in the radix tree. We can always end up with clean radix tree and dirty data in CPU cache. We fix the first problem by introducing locking of exceptional radix tree entries in DAX mappings acting very similarly to page lock and thus synchronizing properly faults against the same mapping index. The same lock can later be used to avoid races when clearing radix tree dirty tag. Reviewed-by: NeilBrown <neilb@suse.com> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/dax.c | 553 ++++++++++++++++++++++++++++++++++++++-------------- include/linux/dax.h | 3 + mm/filemap.c | 9 +- mm/truncate.c | 62 +++--- 4 files changed, 447 insertions(+), 180 deletions(-) commit 4f622938a5e2b7f1374ffb1e5fc212744898f513 Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:17 2016 +0200 dax: Allow DAX code to replace exceptional entries Currently we forbid page_cache_tree_insert() to replace exceptional radix tree entries for DAX inodes. However to make DAX faults race free we will lock radix tree entries and when hole is created, we need to replace such locked radix tree entry with a hole page. So modify page_cache_tree_insert() to allow that. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> include/linux/dax.h | 1 + mm/filemap.c | 21 ++++++++++++++------- 2 files changed, 15 insertions(+), 7 deletions(-) commit e804315dd0f574b56155c5a2406ab5e0318104f7 Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:16 2016 +0200 dax: Define DAX lock bit for radix tree exceptional entry We will use lowest available bit in the radix tree exceptional entry for locking of the entry. Define it. Also clean up definitions of DAX entry type bits in DAX exceptional entries to use defined constants instead of hardcoding numbers and cleanup checking of these bits to not rely on how other bits in the entry are set. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/dax.c | 17 +++++++++++------ include/linux/dax.h | 3 +++ 2 files changed, 14 insertions(+), 6 deletions(-) commit 348e967ab07c96a9e7a6a194812254a8df2045c0 Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:15 2016 +0200 dax: Make huge page handling depend of CONFIG_BROKEN Currently the handling of huge pages for DAX is racy. For example the following can happen: CPU0 (THP write fault) CPU1 (normal read fault) __dax_pmd_fault() __dax_fault() get_block(inode, block, &bh, 0) -> not mapped get_block(inode, block, &bh, 0) -> not mapped if (!buffer_mapped(&bh) && write) get_block(inode, block, &bh, 1) -> allocates blocks truncate_pagecache_range(inode, lstart, lend); dax_load_hole(); This results in data corruption since process on CPU1 won't see changes into the file done by CPU0. The race can happen even if two normal faults race however with THP the situation is even worse because the two faults don't operate on the same entries in the radix tree and we want to use these entries for serialization. So make THP support in DAX code depend on CONFIG_BROKEN for now. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/Kconfig | 1 + fs/dax.c | 2 +- include/linux/dax.h | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) commit b9953536c95fd0013695542bfa4694c7468673aa Author: Jan Kara <jack@suse.cz> Date: Thu May 12 18:29:14 2016 +0200 dax: Fix condition for filling of PMD holes Currently dax_pmd_fault() decides to fill a PMD-sized hole only if returned buffer has BH_Uptodate set. However that doesn't get set for any mapping buffer so that branch is actually a dead code. The BH_Uptodate check doesn't make any sense so just remove it. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com> fs/dax.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ef56b79b66faeeb0dc14213d3cc9e0534a960dee Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Fri May 13 10:00:31 2016 +0200 clk: fix critical clock locking The critical clock handling in __clk_core_init isn't taking the enable lock before calling clk_core_enable, which in turns triggers the warning in the lockdep_assert_held call in that function when lockep is enabled. Add the calls to clk_enable_lock/unlock to make sure it doesn't happen. Fixes: 32b9b1096186 ("clk: Allow clocks to be marked as CRITICAL") Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk.c | 5 +++++ 1 file changed, 5 insertions(+) commit f70552809419cd2abc0cc6469a07c9792a3aaa6c Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 14:11:52 2016 +1000 vfio_pci: Test for extended capabilities if config space > 256 bytes PCI-Express spec says that reading 4 bytes at offset 100h should return zero if there is no extended capability so VFIO reads this dword to know if there are extended capabilities. However it is not always possible to access the extended space so generic PCI code in pci_cfg_space_size_ext() checks if pci_read_config_dword() can read beyond 100h and if the check fails, it sets the config space size to 100h. VFIO does its own extended capabilities check by reading at offset 100h which may produce 0xffffffff which VFIO treats as the extended config space presense and calls vfio_ecap_init() which fails to parse capabilities (which is expected) but right before the exit, it writes zero at offset 100h which is beyond the buffer allocated for vdev->vconfig (which is 256 bytes) which leads to random memory corruption. This makes VFIO only check for the extended capabilities if the discovered config size is more than 256 bytes. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/pci/vfio_pci_config.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit f4c80d5a16eb4b08a0d9ade154af1ebdc63f5752 Merge: 7afd16f 17e1717 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 13:41:32 2016 -0700 Merge tag 'sound-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound updates from Takashi Iwai: "This time was again a relatively calm development cycle; most of updates are about drivers, and no radical changes are seen in any core code. Here are some highlights: ALSA core: - Continued hardening of ALSA hrtimer - A few leak fixes in timer interface - Fix poll error handling in PCM and compress - Add error propagation in compress API - Removal of dead rtctimer driver HD-audio: - Native ELD notify support for i915 HDMI - Realtek ALC234 & co support - Code refactoring to standardize chmap support - Continued development for SKL HDMI core support Firewire: - Apply delayed card registration to all drivers - Improved / stabilized the handling of PCM stream start / stop - Add tracepoints to dump a part of isochronous packet data - Fixed incoming/outgoing packet parameter usages - Add support for M-Audio profire series USB-audio: - Fixes for UAC2 clock source - SS+ support - Workaround for oft-seen repeated sample rate read errors ASoC: - Further slow progress on the topology code - Substantial updates and improvements for the da7219, es8328, fsl-ssi, Intel and rcar drivers. - Compress error handling in WM ADSP driver" * tag 'sound-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (177 commits) ALSA: firewire-lib: change a member of event structure to suppress sparse wanings to bool type sound: oss: Use setup_timer and mod_timer. ASoC: hdac_hdmi: Remove the unused 'timeout' variable ASoC: fsl_ssi: Fix channel slipping on capture (or playback) restart in full duplex. ASoC: fsl_ssi: Fix channel slipping in Playback at startup ASoC: fsl_ssi: Fix samples being dropped at Playback startup ASoC: fsl_ssi: Save a dev reference for dev_err() purpose. ASoC: fsl_ssi: The IPG/5 limitation concerns the bitclk, not the sysclk. ASoC: fsl_ssi: Real hardware channels max number is 32 ASoC: pcm5102a: Add support for PCM5102A codec ASoC: hdac_hdmi: add link management ASoC: Intel: Skylake: add link management ALSA: hdac: add link pm and ref counting ALSA: au88x0: Fix zero clear of stream->resources ASoC: rt298: Add DMI match for Broxton-P reference platform ASoC: rt298: fix null deref on acpi driver data ASoC: dapm: deprecate MICBIAS widget type ALSA: firewire-lib: drop skip argument from helper functions to queue a packet ALSA: firewire-lib: add context information to tracepoints ALSA: firewire-lib: permit to flush queued packets only in process context for better PCM period granularity ... commit 7afd16f882887c9adc69cd1794f5e57777723217 Merge: a37571a e257ef5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 13:10:54 2016 -0700 Merge tag 'pci-v4.7-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci Pull PCI updates from Bjorn Helgaas: "Enumeration: - Refine PCI support check in pcibios_init() (Adrian-Ken Rueegsegger) - Provide common functions for ECAM mapping (Jayachandran C) - Allow all PCIe services on non-ACPI host bridges (Jon Derrick) - Remove return values from pcie_port_platform_notify() and relatives (Jon Derrick) - Widen portdrv service type from 4 bits to 8 bits (Keith Busch) - Add Downstream Port Containment portdrv service type (Keith Busch) - Add Downstream Port Containment driver (Keith Busch) Resource management: - Identify Enhanced Allocation (EA) BAR Equivalent resources in sysfs (Alex Williamson) - Supply CPU physical address (not bus address) to iomem_is_exclusive() (Bjorn Helgaas) - alpha: Call iomem_is_exclusive() for IORESOURCE_MEM, but not IORESOURCE_IO (Bjorn Helgaas) - Mark Broadwell-EP Home Agent 1 as having non-compliant BARs (Prarit Bhargava) - Disable all BAR sizing for devices with non-compliant BARs (Prarit Bhargava) - Move PCI I/O space management from OF to PCI core code (Tomasz Nowicki) PCI device hotplug: - acpiphp_ibm: Avoid uninitialized variable reference (Dan Carpenter) - Use cached copy of PCI_EXP_SLTCAP_HPC bit (Lukas Wunner) Virtualization: - Mark Intel i40e NIC INTx masking as broken (Alex Williamson) - Reverse standard ACS vs device-specific ACS enabling (Alex Williamson) - Work around Intel Sunrise Point PCH incorrect ACS capability (Alex Williamson) IOMMU: - Add pci_add_dma_alias() to abstract implementation (Bjorn Helgaas) - Move informational printk to pci_add_dma_alias() (Bjorn Helgaas) - Add support for multiple DMA aliases (Jacek Lawrynowicz) - Add DMA alias quirk for mic_x200_dma (Jacek Lawrynowicz) Thunderbolt: - Fix double free of drom buffer (Andreas Noever) - Add Intel Thunderbolt device IDs (Lukas Wunner) - Fix typos and magic number (Lukas Wunner) - Support 1st gen Light Ridge controller (Lukas Wunner) Generic host bridge driver: - Use generic ECAM API (Jayachandran C) Cavium ThunderX host bridge driver: - Don't clobber read-only bits in bridge config registers (David Daney) - Use generic ECAM API (Jayachandran C) Freescale i.MX6 host bridge driver: - Use enum instead of bool for variant indicator (Andrey Smirnov) - Implement reset sequence for i.MX6+ (Andrey Smirnov) - Factor out ref clock enable (Bjorn Helgaas) - Add initial imx6sx support (Christoph Fritz) - Add reset-gpio-active-high boolean property to DT (Petr Štetiar) - Add DT property for link gen, default to Gen1 (Tim Harvey) - dts: Specify imx6qp version of PCIe core (Andrey Smirnov) - dts: Fix PCIe reset GPIO polarity on Toradex Apalis Ixora (Petr Štetiar) Marvell Armada host bridge driver: - add DT binding for Marvell Armada 7K/8K PCIe controller (Thomas Petazzoni) - Add driver for Marvell Armada 7K/8K PCIe controller (Thomas Petazzoni) Marvell MVEBU host bridge driver: - Constify mvebu_pcie_pm_ops structure (Jisheng Zhang) - Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS for mvebu_pcie_pm_ops (Jisheng Zhang) Microsoft Hyper-V host bridge driver: - Report resources release after stopping the bus (Vitaly Kuznetsov) - Add explicit barriers to config space access (Vitaly Kuznetsov) Renesas R-Car host bridge driver: - Select PCI_MSI_IRQ_DOMAIN (Arnd Bergmann) Synopsys DesignWare host bridge driver: - Remove incorrect RC memory base/limit configuration (Gabriele Paoloni) - Move Root Complex setup code to dw_pcie_setup_rc() (Jisheng Zhang) TI Keystone host bridge driver: - Add error IRQ handler (Murali Karicheri) - Remove unnecessary goto statement (Murali Karicheri) Miscellaneous: - Fix spelling errors (Colin Ian King)" * tag 'pci-v4.7-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (48 commits) PCI: Disable all BAR sizing for devices with non-compliant BARs x86/PCI: Mark Broadwell-EP Home Agent 1 as having non-compliant BARs PCI: Identify Enhanced Allocation (EA) BAR Equivalent resources in sysfs PCI, of: Move PCI I/O space management to PCI core code PCI: generic, thunder: Use generic ECAM API PCI: Provide common functions for ECAM mapping PCI: hv: Add explicit barriers to config space access PCI: Use cached copy of PCI_EXP_SLTCAP_HPC bit PCI: Add Downstream Port Containment driver PCI: Add Downstream Port Containment portdrv service type PCI: Widen portdrv service type from 4 bits to 8 bits PCI: designware: Remove incorrect RC memory base/limit configuration PCI: hv: Report resources release after stopping the bus ARM: dts: imx6qp: Specify imx6qp version of PCIe core PCI: imx6: Implement reset sequence for i.MX6+ PCI: imx6: Use enum instead of bool for variant indicator PCI: thunder: Don't clobber read-only bits in bridge config registers thunderbolt: Fix double free of drom buffer PCI: rcar: Select PCI_MSI_IRQ_DOMAIN PCI: armada: Add driver for Marvell Armada 7K/8K PCIe controller ... commit a37571a29eca963562ff5a9233db4a5c73c72cf9 Merge: a0d3c7c 0d53583 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 12:50:56 2016 -0700 Merge tag 'pinctrl-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Pull pin control updates from Linus Walleij: "This kernel cycle was quite calm when it comes to pin control and there is really just one major change, and that is the introduction of devm_pinctrl_register() managed resources. Apart from that linear development, details below. Core changes: - Add the devm_pinctrl_register() API and switch all applicable drivers to use it, saving lots of lines of code all over the place. New drivers: - driver for the Broadcom NS2 SoC - subdriver for the PXA25x SoCs - subdriver for the AMLogic Meson GXBB SoC Driver improvements: - the Intel Baytrail driver now properly supports pin control - Nomadik, Rockchip, Broadcom BCM2835 support the .get_direction() callback in the GPIO portions - continued development and stabilization of several SH-PFC SoC subdrivers: r8a7795, r8a7790, r8a7794 etc" * tag 'pinctrl-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: (85 commits) Revert "pinctrl: tegra: avoid parked_reg and parked_bank" pinctrl: meson: Fix eth_tx_en bit index pinctrl: tegra: avoid parked_reg and parked_bank pinctrl: tegra: Correctly check the supported configuration pinctrl: amlogic: Add support for Amlogic Meson GXBB SoC pinctrl: rockchip: fix pull setting error for rk3399 pinctrl: stm32: Implement .pin_config_dbg_show() pinctrl: nomadik: hide nmk_gpio_get_mode when unused pinctrl: ns2: rename pinctrl_utils_dt_free_map pinctrl: at91: Merge clk_prepare and clk_enable into clk_prepare_enable pinctrl: at91: Make at91_gpio_template const pinctrl: baytrail: fix some error handling in debugfs pinctrl: ns2: add pinmux driver support for Broadcom NS2 SoC pinctrl: sirf/atlas7: trivial fix of spelling mistake on flagged pinctrl: sh-pfc: Kill unused variable in sh_pfc_remove() pinctrl: nomadik: implement .get_direction() pinctrl: nomadik: use BIT() with offsets consequently pinctrl: exynos5440: Use off-stack memory for pinctrl_gpio_range pinctrl: zynq: Use devm_pinctrl_register() for pinctrl registration pinctrl: u300: Use devm_pinctrl_register() for pinctrl registration ... commit e22cb5e787623a98e22a2660041b455a2c138b02 Merge: 6104503 ebe24ce Author: David S. Miller <davem@davemloft.net> Date: Thu May 19 11:51:14 2016 -0700 Merge tag 'batman-adv-fix-for-davem' of git://git.open-mesh.org/linux-merge Antonio Quartulli says: ==================== During the Wireless Battle Mesh v9 in Porto (PT) at the beginning of May, we managed to uncover and fix some important bugs in our new B.A.T.M.A.N. V algorithm. These are the fixes we came up with together with others that I collected in the past weeks: - avoid potential crash due to NULL pointer dereference in B.A.T.M.A.N. V routine when a neigh_ifinfo object is not found, by Sven Eckelmann - avoid use-after-free of skb when counting outgoing bytes, by Florian Westphal - fix neigh_ifinfo object reference counting imbalance when using B.A.T.M.A.N. V, by Sven Eckelmann. Such imbalance may lead to the impossibility of releasing the related netdev object on shutdown - avoid invalid memory access in case of error while allocating bcast_own_sum when a new hard-interface is added, by Sven Eckelmann - ensure originator address is updated in OMG/ELP packet content upon primary interface address change, by Antonio Quartulli - fix integer overflow when computing TQ metric (B.A.T.M.A.N. IV), by Sven Eckelmann - avoid race condition while adding new neigh_node which would result in having two objects mapping to the same physical neighbour, by Linus Lüssing - ensure originator address is initialized in ELP packet content on secondary interfaces, by Marek Lindner ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 6104503cddbbaf341c091fa900d93488d6342ad6 Author: Amit Ghadge <amitg.b14@gmail.com> Date: Wed May 18 06:46:30 2016 +0530 net: Fix coding style warnings and errors. This is a patch to clean checkpatch warnings and errors in the Space.c file. Clean up the following warnings and errors. WARNING : * Block comments use * on subsequent lines * Missing a blank line after declarations * networking block comments don't use an empty /* line, use /* * please, no space before tabs * please, no spaces at the start of a line * line over 80 characters ERROR : * code indent should use tabs where possible * space prohibited after that open parenthesis '(' Signed-off-by: Amit Ghadge <amitg.b14@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/Space.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit a0d3c7c5c07cfbe00ab89438ddf82482f5a99422 Merge: ec67b14 f9114a5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 11:47:18 2016 -0700 Merge tag 'dmaengine-4.7-rc1' of git://git.infradead.org/users/vkoul/slave-dma Pull dmaengine updates from Vinod Koul: "This time round the update brings in following changes: - new tegra driver for ADMA device - support for Xilinx AXI Direct Memory Access Engine and Xilinx AXI Central Direct Memory Access Engine and few updates to this driver - new cyclic capability to sun6i and few updates - slave-sg support in bcm2835 - updates to many drivers like designware, hsu, mv_xor, pxa, edma, qcom_hidma & bam" * tag 'dmaengine-4.7-rc1' of git://git.infradead.org/users/vkoul/slave-dma: (84 commits) dmaengine: ioatdma: disable relaxed ordering for ioatdma dmaengine: of_dma: approximate an average distribution dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module dmaengine: edma: Re-evaluate errors when ccerr is triggered w/o error event dmaengine: qcom_hidma: add support for object hierarchy dmaengine: qcom_hidma: add debugfs hooks dmaengine: qcom_hidma: implement lower level hardware interface dmaengine: vdma: Add clock support Documentation: DT: vdma: Add clock support for dmas dmaengine: vdma: Add config structure to differentiate dmas MAINTAINERS: Update Tegra DMA maintainers dmaengine: tegra-adma: Add support for Tegra210 ADMA Documentation: DT: Add binding documentation for NVIDIA ADMA dmaengine: vdma: Add Support for Xilinx AXI Central Direct Memory Access Engine Documentation: DT: vdma: update binding doc for AXI CDMA dmaengine: vdma: Add Support for Xilinx AXI Direct Memory Access Engine Documentation: DT: vdma: update binding doc for AXI DMA dmaengine: vdma: Rename xilinx_vdma_ prefix to xilinx_dma dmaengine: slave means at least one of DMA_SLAVE, DMA_CYCLIC dmaengine: mv_xor: Allow selecting mv_xor for mvebu only compatible SoC ... commit 87553aa5212f43d3d14b9b5d1dfba89f1a6e6f21 Merge: e00be9e b91083a Author: David S. Miller <davem@davemloft.net> Date: Thu May 19 11:36:50 2016 -0700 Merge branch 'tcp_bh_fixes' Eric Dumazet says: ==================== net: block BH in TCP callbacks Four layers using TCP stack were assuming sk_callback_lock could be locked using read_lock() in their handlers because TCP stack was running with BH disabled. This is no longer the case. Since presumably the rest could also depend on BH being disabled, just use read_lock_bh(). Then each layer might consider switching to RCU protection and no longer depend on BH. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b91083a45e4c41b8c952cf02ceb0ce16f0b1b9b1 Author: Eric Dumazet <edumazet@google.com> Date: Tue May 17 17:44:09 2016 -0700 tipc: block BH in TCP callbacks TCP stack can now run from process context. Use read_lock_bh(&sk->sk_callback_lock) variant to restore previous assumption. Fixes: 5413d1babe8f ("net: do not block BH while processing socket backlog") Fixes: d41a69f1d390 ("tcp: make tcp_sendmsg() aware of socket backlog") Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Jon Maloy <jon.maloy@ericsson.com> Cc: Ying Xue <ying.xue@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/server.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 38036629cded6b96a9f9689758a88d067c4d4d44 Author: Eric Dumazet <edumazet@google.com> Date: Tue May 17 17:44:08 2016 -0700 rds: tcp: block BH in TCP callbacks TCP stack can now run from process context. Use read_lock_bh(&sk->sk_callback_lock) variant to restore previous assumption. Fixes: 5413d1babe8f ("net: do not block BH while processing socket backlog") Fixes: d41a69f1d390 ("tcp: make tcp_sendmsg() aware of socket backlog") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rds/tcp_connect.c | 4 ++-- net/rds/tcp_listen.c | 4 ++-- net/rds/tcp_recv.c | 4 ++-- net/rds/tcp_send.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) commit e1daca289a36965d923ec26647b5668e023eb0ac Author: Eric Dumazet <edumazet@google.com> Date: Tue May 17 17:44:07 2016 -0700 ocfs2/cluster: block BH in TCP callbacks TCP stack can now run from process context. Use read_lock_bh() variant to restore previous assumption. Fixes: 5413d1babe8f ("net: do not block BH while processing socket backlog") Fixes: d41a69f1d390 ("tcp: make tcp_sendmsg() aware of socket backlog") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> fs/ocfs2/cluster/tcp.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 7cb001d4c4fa7e1cc1a55388a9544e160dddc610 Author: Eric Dumazet <edumazet@google.com> Date: Tue May 17 17:44:06 2016 -0700 scsi_tcp: block BH in TCP callbacks iscsi_sw_tcp_data_ready() and iscsi_sw_tcp_state_change() were using read_lock(&sk->sk_callback_lock) which is fine if caller disabled BH. TCP stack no longer has this requirement and can run from process context. Use read_lock_bh() variant to restore previous assumption. Ideally this code could use RCU instead... Fixes: 5413d1babe8f ("net: do not block BH while processing socket backlog") Fixes: d41a69f1d390 ("tcp: make tcp_sendmsg() aware of socket backlog") Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Mike Christie <michaelc@cs.wisc.edu> Cc: Venkatesh Srinivas <venkateshs@google.com> Acked-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/scsi/iscsi_tcp.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit ec67b14c1be4ebe4cf08f06746a8d0313ab85432 Merge: 7beaa24 5bcba79 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 11:36:26 2016 -0700 Merge tag 'localmodconfig-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-kconfig Pull localmodconfig updates from Steven Rostedt. "Benjamin Poirier added some minor fixes and clean ups to localmodconfig. One is a fix for making sure that module signing still works when coming from a different environment. If original keys are not found it will warn and reset the keys to their default value" * tag 'localmodconfig-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-kconfig: localmodconfig: Fix whitespace repeat count after "tristate" localmodconfig: Reset certificate paths localmodconfig: Add missing $ to reference a variable localmodconfig: Fix parsing of "help" text localmodconfig: Recognize more keywords that end a menu entry localmodconfig: Fix parsing of Kconfig "source" statements commit e00be9e4d0ffcc0121606229f0aa4b246d6881d7 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Wed May 18 02:13:30 2016 +0200 net: pegasus: remove dead coding (!count || count < 4) is always true. So let's remove the coding which is dead at least since 2005. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/pegasus.c | 53 ----------------------------------------------- 1 file changed, 53 deletions(-) commit 074ba1e232f5a562ddd87e6ed0b342faae0aeb9b Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Wed May 18 01:58:45 2016 +0200 net: au1000 eth: simplify logical expression (a && a > 0) is equivalent to (a > 0). Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/amd/au1000_eth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 30119059703f94e9e4936477bc33e918fb41e9c8 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Wed May 18 00:06:02 2016 +0200 net: irda: avoid null pointer dereference Only dereference variable self after checking it is not NULL. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/irda/nsc-ircc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit d113412859e49620ce8fe67d5ff9f34fe5006f99 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Tue May 17 23:58:40 2016 +0200 net: ieee802154/adf7242: syntax error ifdef DEBUG If DEBUG is defined, a superfluous closing brace is introduced. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ieee802154/adf7242.c | 1 - 1 file changed, 1 deletion(-) commit 7beaa24ba49717419e24d1f6321e8b3c265a719c Merge: 07b7526 9842df6 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 11:27:09 2016 -0700 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm Pull KVM updates from Paolo Bonzini: "Small release overall. x86: - miscellaneous fixes - AVIC support (local APIC virtualization, AMD version) s390: - polling for interrupts after a VCPU goes to halted state is now enabled for s390 - use hardware provided information about facility bits that do not need any hypervisor activity, and other fixes for cpu models and facilities - improve perf output - floating interrupt controller improvements. MIPS: - miscellaneous fixes PPC: - bugfixes only ARM: - 16K page size support - generic firmware probing layer for timer and GIC Christoffer Dall (KVM-ARM maintainer) says: "There are a few changes in this pull request touching things outside KVM, but they should all carry the necessary acks and it made the merge process much easier to do it this way." though actually the irqchip maintainers' acks didn't make it into the patches. Marc Zyngier, who is both irqchip and KVM-ARM maintainer, later acked at http://mid.gmane.org/573351D1.4060303@arm.com ('more formally and for documentation purposes')" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (82 commits) KVM: MTRR: remove MSR 0x2f8 KVM: x86: make hwapic_isr_update and hwapic_irr_update look the same svm: Manage vcpu load/unload when enable AVIC svm: Do not intercept CR8 when enable AVIC svm: Do not expose x2APIC when enable AVIC KVM: x86: Introducing kvm_x86_ops.apicv_post_state_restore svm: Add VMEXIT handlers for AVIC svm: Add interrupt injection via AVIC KVM: x86: Detect and Initialize AVIC support svm: Introduce new AVIC VMCB registers KVM: split kvm_vcpu_wake_up from kvm_vcpu_kick KVM: x86: Introducing kvm_x86_ops VCPU blocking/unblocking hooks KVM: x86: Introducing kvm_x86_ops VM init/destroy hooks KVM: x86: Rename kvm_apic_get_reg to kvm_lapic_get_reg KVM: x86: Misc LAPIC changes to expose helper functions KVM: shrink halt polling even more for invalid wakeups KVM: s390: set halt polling to 80 microseconds KVM: halt_polling: provide a way to qualify wakeups during poll KVM: PPC: Book3S HV: Re-enable XICS fast path for irqfd-generated interrupts kvm: Conditionally register IRQ bypass consumer ... commit f1971a2e0393a86464caa77aa52168b731960dfa Author: WANG Cong <xiyou.wangcong@gmail.com> Date: Tue May 17 14:05:49 2016 -0700 kcm: fix a signedness in kcm_splice_read() skb_splice_bits() returns int, kcm_splice_read() returns ssize_t, both are signed. We may need another patch to make them all ssize_t, but that deserves a separated patch. Fixes: 91687355b927 ("kcm: Splice support") Reported-by: David Binderman <linuxdev.baldrick@gmail.com> Cc: Tom Herbert <tom@herbertland.com> Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/kcm/kcmsock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1740c29a46b30a2f157afc473156f157e599d4c2 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Tue May 17 22:28:54 2016 +0200 net: ehea: avoid null pointer dereference ehea_get_port may return NULL. Do not dereference NULL value. Fixes: 8c4877a4128e ("ehea: Use the standard logging functions") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: Thadeu Lima de Souza Cascardo <cascardo@debian.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ibm/ehea/ehea_main.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 099a728d5819da80ff9fff3df980ea6e89a01e60 Author: xypron.glpk@gmx.de <xypron.glpk@gmx.de> Date: Tue May 17 21:40:38 2016 +0200 net: thunderx: avoid null pointer dereference In function bgx_lmac_handler only use a member of lmac after checking it is not null. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: David Daney <david.daney@cavium.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cavium/thunder/thunder_bgx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 07b75260ebc2c789724c594d7eaf0194fa47b3be Merge: 0efacbb 6e4ad1b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 10:02:26 2016 -0700 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus Pull MIPS updates from Ralf Baechle: "This is the main pull request for MIPS for 4.7. Here's the summary of the changes: - ATH79: Support for DTB passuing using the UHI boot protocol - ATH79: Remove support for builtin DTB. - ATH79: Add zboot debug serial support. - ATH79: Add initial support for Dragino MS14 (Dragine 2), Onion Omega and DPT-Module. - ATH79: Update devicetree clock support for AR9132 and AR9331. - ATH79: Cleanup the DT code. - ATH79: Support newer SOCs in ath79_ddr_ctrl_init. - ATH79: Fix regression in PCI window initialization. - BCM47xx: Move SPROM driver to drivers/firmware/ - BCM63xx: Enable partition parser in defconfig. - BMIPS: BMIPS5000 has I cache filing from D cache - BMIPS: BMIPS: Add cpu-feature-overrides.h - BMIPS: Add Whirlwind support - BMIPS: Adjust mips-hpt-frequency for BCM7435 - BMIPS: Remove maxcpus from BCM97435SVMB DTS - BMIPS: Add missing 7038 L1 register cells to BCM7435 - BMIPS: Various tweaks to initialization code. - BMIPS: Enable partition parser in defconfig. - BMIPS: Cache tweaks. - BMIPS: Add UART, I2C and SATA devices to DT. - BMIPS: Add BCM6358 and BCM63268support - BMIPS: Add device tree example for BCM6358. - BMIPS: Improve Improve BCM6328 and BCM6368 device trees - Lantiq: Add support for device tree file from boot loader - Lantiq: Allow build with no built-in DT. - Loongson 3: Reserve 32MB for RS780E integrated GPU. - Loongson 3: Fix build error after ld-version.sh modification - Loongson 3: Move chipset ACPI code from drivers to arch. - Loongson 3: Speedup irq processing. - Loongson 3: Add basic Loongson 3A support. - Loongson 3: Set cache flush handlers to nop. - Loongson 3: Invalidate special TLBs when needed. - Loongson 3: Fast TLB refill handler. - MT7620: Fallback strategy for invalid syscfg0. - Netlogic: Fix CP0_EBASE redefinition warnings - Octeon: Initialization fixes - Octeon: Add DTS files for the D-Link DSR-1000N and EdgeRouter Lite - Octeon: Enable add Octeon-drivers in cavium_octeon_defconfig - Octeon: Correctly handle endian-swapped initramfs images. - Octeon: Support CN73xx, CN75xx and CN78xx. - Octeon: Remove dead code from cvmx-sysinfo. - Octeon: Extend number of supported CPUs past 32. - Octeon: Remove some code limiting NR_IRQS to 255. - Octeon: Simplify octeon_irq_ciu_gpio_set_type. - Octeon: Mark some functions __init in smp.c - Octeon: Octeon: Add Octeon III CN7xxx interface detection - PIC32: Add serial driver and bindings for it. - PIC32: Add PIC32 deadman timer driver and bindings. - PIC32: Add PIC32 clock timer driver and bindings. - Pistachio: Determine SoC revision during boot - Sibyte: Fix Kconfig dependencies of SIBYTE_BUS_WATCHER. - Sibyte: Strip redundant comments from bcm1480_regs.h. - Panic immediately if panic_on_oops is set. - module: fix incorrect IS_ERR_VALUE macro usage. - module: Make consistent use of pr_* - Remove no longer needed work_on_cpu() call. - Remove CONFIG_IPV6_PRIVACY from defconfigs. - Fix registers of non-crashing CPUs in dumps. - Handle MIPSisms in new vmcore_elf32_check_arch. - Select CONFIG_HANDLE_DOMAIN_IRQ and make it work. - Allow RIXI to be used on non-R2 or R6 cores. - Reserve nosave data for hibernation - Fix siginfo.h to use strict POSIX types. - Don't unwind user mode with EVA. - Fix watchpoint restoration - Ptrace watchpoints for R6. - Sync icache when it fills from dcache - I6400 I-cache fills from dcache. - Various MSA fixes. - Cleanup MIPS_CPU_* definitions. - Signal: Move generic copy_siginfo to signal.h - Signal: Fix uapi include in exported asm/siginfo.h - Timer fixes for sake of KVM. - XPA TLB refill fixes. - Treat perf counter feature - Update John Crispin's email address - Add PIC32 watchdog and bindings. - Handle R10000 LL/SC bug in set_pte() - cpufreq: Various fixes for Longson1. - R6: Fix R2 emulation. - mathemu: Cosmetic fix to ADDIUPC emulation, plenty of other small fixes - ELF: ABI and FP fixes. - Allow for relocatable kernel and use that to support KASLR. - Fix CPC_BASE_ADDR mask - Plenty fo smp-cps, CM, R6 and M6250 fixes. - Make reset_control_ops const. - Fix kernel command line handling of leading whitespace. - Cleanups to cache handling. - Add brcm, bcm6345-l1-intc device tree bindings. - Use generic clkdev.h header - Remove CLK_IS_ROOT usage. - Misc small cleanups. - CM: Fix compilation error when !MIPS_CM - oprofile: Fix a preemption issue - Detect DSP ASE v3 support:1" * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (275 commits) MIPS: pic32mzda: fix getting timer clock rate. MIPS: ath79: fix regression in PCI window initialization MIPS: ath79: make ath79_ddr_ctrl_init() compatible for newer SoCs MIPS: Fix VZ probe gas errors with binutils <2.24 MIPS: perf: Fix I6400 event numbers MIPS: DEC: Export `ioasic_ssr_lock' to modules MIPS: MSA: Fix a link error on `_init_msa_upper' with older GCC MIPS: CM: Fix compilation error when !MIPS_CM MIPS: Fix genvdso error on rebuild USB: ohci-jz4740: Remove obsolete driver MIPS: JZ4740: Probe OHCI platform device via DT MIPS: JZ4740: Qi LB60: Remove support for AVT2 variant MIPS: pistachio: Determine SoC revision during boot MIPS: BMIPS: Adjust mips-hpt-frequency for BCM7435 mips: mt7620: fallback to SDRAM when syscfg0 does not have a valid value for the memory type MIPS: Prevent "restoration" of MSA context in non-MSA kernels MIPS: cevt-r4k: Dynamically calculate min_delta_ns MIPS: malta-time: Take seconds into account MIPS: malta-time: Start GIC count before syncing to RTC MIPS: Force CPUs to lose FP context during mode switches ... commit 0efacbbaee1e94e9942da0912f5b46ffd45a74bd Merge: f4f27d0 776d7f1 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 09:46:18 2016 -0700 Merge tag 'arc-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc Pull ARC updates from Vineet Gupta: "We have a relatively big changeset for ARC for 4.7. The highlight is support for EZChip (now Mellanox) NPS-400 network processor, a 400-Gb throughput C-programmable packet processor based on ARC700 cores from Synopsys. See http://www.mellanox.com/related-docs/prod_npu/PB_NPS-400.pdf Also present are irqchip and clocksource drivers for NPS as agreed with respective maintainers to go via ARC tree due to an soc header dependency. I have the needed ACKs from Jason, Marc, Daniel. You might run into a trivial merge conflict in drivers/irqchip/* This EZChip platform support required some deep changes in ARC architecture code and also opportunity to cleanup past sins (legacy irq domains, missing irq domain lookup, hard coded timer irqs...) Summary: - Support for EZChip (now Mellanox) NPS-400 Network processor based on ARC700 - NPS interrupt controller and clocksource drivers - ARC timers probed off DT - ARC iqrchips switching to linear domain (upgrade from legacy domains)" * tag 'arc-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc: (37 commits) arc: axs103_smp: Fix CPU frequency to 100MHz for dual-core arc: axs10x: Add DT bindings for I2S PLL Clock ARC: pae: STRICT_MM_TYPECHECKS was broken ARC: Add eznps platform to Kconfig and Makefile ARC: [plat-eznps] Use dedicated COMMAND_LINE_SIZE ARC: [plat-eznps] Use dedicated cpu_relax() ARC: [plat-eznps] Use dedicated identity auxiliary register. ARC: [plat-eznps] Use dedicated SMP barriers ARC: [plat-eznps] Use dedicated atomic/bitops/cmpxchg ARC: [plat-eznps] Use dedicated user stack top ARC: [plat-eznps] Add eznps platform ARC: [plat-eznps] Add eznps board defconfig and dts ARC: Mark secondary cpu online only after all HW setup is done ARC: rwlock: disable interrupts in !LLSC variant ARC: Make vmalloc size configurable ARC: clean out UAPI byteorder.h clean off Kconfig symbol irqchip: add nps Internal and external irqchips clocksource: Add NPS400 timers driver soc: Support for EZchip SoC Documentation: Add EZchip vendor to binding list ... commit f4f27d0028aabce57e44c16c2fdefccd6310d2f3 Merge: 2600a46 b937190 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Thu May 19 09:21:36 2016 -0700 Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull security subsystem updates from James Morris: "Highlights: - A new LSM, "LoadPin", from Kees Cook is added, which allows forcing of modules and firmware to be loaded from a specific device (this is from ChromeOS, where the device as a whole is verified cryptographically via dm-verity). This is disabled by default but can be configured to be enabled by default (don't do this if you don't know what you're doing). - Keys: allow authentication data to be stored in an asymmetric key. Lots of general fixes and updates. - SELinux: add restrictions for loading of kernel modules via finit_module(). Distinguish non-init user namespace capability checks. Apply execstack check on thread stacks" * 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: (48 commits) LSM: LoadPin: provide enablement CONFIG Yama: use atomic allocations when reporting seccomp: Fix comment typo ima: add support for creating files using the mknodat syscall ima: fix ima_inode_post_setattr vfs: forbid write access when reading a file into memory fs: fix over-zealous use of "const" selinux: apply execstack check on thread stacks selinux: distinguish non-init user namespace capability checks LSM: LoadPin for kernel file loading restrictions fs: define a string representation of the kernel_read_file_id enumeration Yama: consolidate error reporting string_helpers: add kstrdup_quotable_file string_helpers: add kstrdup_quotable_cmdline string_helpers: add kstrdup_quotable selinux: check ss_initialized before revalidating an inode label selinux: delay inode label lookup as long as possible selinux: don't revalidate an inode's label when explicitly setting it selinux: Change bool variable name to index. KEYS: Add KEYCTL_DH_COMPUTE command ... commit c688c641c514933aa82c9707c99a6fff8831e103 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 16:45:28 2016 +0530 drm/amd/powerplay/hwmgr: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 510e65dfb0e1817ef48c43839b8789131800a6f6 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 16:45:29 2016 +0530 drm/amd/powerplay/hwmgr: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 761de5f9da8306c80c75883e0cbaa78f0244c1a0 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 19 16:45:27 2016 +0530 drm/amd/powerplay/hwmgr: use kmemdup Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit f2c27767af0a91cbdc3d832231f953110473e853 Author: Marek Vasut <marek.vasut@gmail.com> Date: Sun May 8 22:33:22 2016 +0200 devicetree: Add Creative Technology vendor id Add vendor ID for Creative technology. Signed-off-by: Marek Vasut <marek.vasut@gmail.com> Cc: Antony Pavlov <antonynpavlov@gmail.com> Cc: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 9a0d440427bfd1716410b13dea5feb6eb7cd7277 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Thu May 12 00:07:48 2016 +0200 gpio: dt-bindings: add ibm,ppc4xx-gpio binding This patch adds binding information for IBM/AMCC/APM GPIO Controllers of the PowerPC 4XX series and compatible SoCs. The "PowerPC 405EP Embedded Processor Data Sheet" has the following to say about the GPIO controllers: " - Controller functions and GPIO registers are programmed and accessed via memory-mapped OPB bus master accesses - All GPIOs are pin-shared with other functions. DCRs control whether a particular pin that has GPIO capabilities acts as a GPIO or is used for another purpose. - Each GPIO outputs is separately programmable to emulate an open-drain driver (i.e. drives to zero, threestated if output bit is 1) " The ppc4xx_gpio.c driver is part of the platform/sysdev drivers in arch/powerpc/sysdev. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Rob Herring <robh@kernel.org> .../devicetree/bindings/gpio/ibm,ppc4xx-gpio.txt | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 27f4ec1443fb71127ed6fc8b43d6195d9473b049 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed May 11 16:26:18 2016 -0400 of/unittest: Remove unnecessary module.h header inclusion The OF_UNITTEST Kconfig symbol is bool so this unittest can only be built-in and not build as a module. Also, nothing defined in this header file used so is not necessary to include it. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/unittest.c | 1 - 1 file changed, 1 deletion(-) commit dddc33e50a074152d0ba447dcaa6184b19dffab2 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Fri May 13 21:31:39 2016 +1000 drivers/of: Fix build warning in populate_node() Function populate_node() is used to unflatten FDT blob to device tree. It supports maximal 64 level of device nodes. There is one array @fpsizes[64] tracking the full name length of last unflattened device node in the corresponding level (index of element in the array - 1). Build warning is seen with CONFIG_FRAME_WARN=1024 like below on ARM64 as Geert reported. The issue can be reproduced on PPC64 as well. $ make drivers/of/fdt.o drivers/of/fdt.c:443:1: warning: the frame size of 1136 bytes is \ larger than 1024 bytes [-Wframe-larger-than=] This changes the data type of @fpsizes[i] from "unsigned long" to "unsigned int" to avoid the build warning. The return value type of populate_node() and its @fpsize argument is adjusted accordingly. With this applied, 256 bytes saved from the stack frame on ARM64 and PPC64 platforms and the above warning isn't seen. Fixes: 50800082f176 ("drivers/of: Avoid recursively calling unflatten_dt_node()") Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 78c44d910d3e5f96dc6b3695fc1e4efd7c46a455 Author: Rhyland Klein <rklein@nvidia.com> Date: Wed May 11 13:36:57 2016 -0400 drivers/of: Fix depth when unflattening devicetree When the implementation for unflatten_dt_node() changed from being recursive to being non-recursive, it had a side effect of increasing the depth passed to fdt_next_node() by 1. This is fine most of the time, but it seems that when the end of the dtb is being parsed, it will cause the FDT_END condition in fdt_next_node() to return a different value (returning nextoffset instead of -FDT_ERR_NOTFOUND). This ends up passing an FDT_ERR_TRUNCATED error back to the unflatten_dt_node() which then sees that and complains "Error -8 processing FDT" causing boot to fail. This patch simply avoids incrementing depth and uses modified accesses for local array indices so that the depth is the same as it was before the change as far as fdt_next_node() is concerned. This problem was discovered trying to boot Tegra210-Smaug platforms. Fixes: 50800082f176 ("drivers/of: Avoid recursively calling unflatten_dt_node()") Signed-off-by: Rhyland Klein <rklein@nvidia.com> [robh: squashed in KASAN fix from Rhyland] Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 7f058c0a4a0441044f96fcc863533004bc82cf65 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 12 14:28:14 2016 +0200 soc: mtk-pmic-wrap: avoid integer overflow warning On ARM64, the mtk-pmic-wrap driver causes a harmless warning: mtk-pmic-wrap.c:1062:16: warning: large integer implicitly truncated to unsigned type [-Woverflow] mtk-pmic-wrap.c:1074:16: warning: large integer implicitly truncated to unsigned type [-Woverflow] mtk-pmic-wrap.c:1086:16: warning: large integer implicitly truncated to unsigned type [-Woverflow] .int_en_all = ~(BIT(31) | BIT(1)), The problem is that the result of the BIT() macro is an 'unsigned long', so taking the bitwise NOT operation of that results in an integer with the upper 32 bits all set and that cannot be assigned to a 'u32' variable without loss of information. This is harmless because we were never interested in the upper bits here anyway, so we can shut up the warning by adding a simple cast to 'u32'. Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/soc/mediatek/mtk-pmic-wrap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b0a434fb7412937d55f15b8897c5646c81497bbe Author: Peter Zijlstra <peterz@infradead.org> Date: Thu May 19 12:30:19 2016 +0200 perf: Update MAINTAINERS for x86 move The move of the x86 perf implementation forgot to update the MAINTAINERS F(ile) pattern. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Borislav Petkov <bp@suse.de> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: fa9cbf320e99 ("perf/x86: Move perf_event.c ............... => x86/events/core.c") Link: http://lkml.kernel.org/r/20160519103019.GJ3206@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 7888824b0b1c9c3753d2aedf1d00e7a1c20c18af Author: Alden Tondettar <alden.tondettar@gmail.com> Date: Wed May 18 14:09:19 2016 -0700 udf: Use correct partition reference number for metadata UDF/OSTA terminology is confusing. Partition Numbers (PNs) are arbitrary 16-bit values, one for each physical partition in the volume. Partition Reference Numbers (PRNs) are indices into the the Partition Map Table and do not necessarily equal the PN of the mapped partition. The current metadata code mistakenly uses the PN instead of the PRN when mapping metadata blocks to physical/sparable blocks. Windows-created UDF 2.5 discs for some reason use large, arbitrary PNs, resulting in mount failure and KASAN read warnings in udf_read_inode(). For example, a NetBSD UDF 2.5 partition might look like this: PRN PN Type --- -- ---- 0 0 Sparable 1 0 Metadata Since PRN == PN, we are fine. But Windows could gives us: PRN PN Type --- ---- ---- 0 8192 Sparable 1 8192 Metadata So udf_read_inode() will start out by checking the partition length in sbi->s_partmaps[8192], which is obviously out of bounds. Fix this by creating a new field (s_phys_partition_ref) in struct udf_meta_data, referencing whatever physical or sparable map has the same partition number as the metadata partition. [JK: Add comment about s_phys_partition_ref, change its name] Signed-off-by: Alden Tondettar <alden.tondettar@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz> fs/udf/partition.c | 6 ++++-- fs/udf/super.c | 22 ++++++++++++---------- fs/udf/udf_sb.h | 5 +++++ 3 files changed, 21 insertions(+), 12 deletions(-) commit bad6a185b4d6f81d0ed2b6e4c16307969f160b95 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 16:55:56 2016 +0200 crypto: public_key: select CRYPTO_AKCIPHER In some rare randconfig builds, we can end up with ASYMMETRIC_PUBLIC_KEY_SUBTYPE enabled but CRYPTO_AKCIPHER disabled, which fails to link because of the reference to crypto_alloc_akcipher: crypto/built-in.o: In function `public_key_verify_signature': :(.text+0x110e4): undefined reference to `crypto_alloc_akcipher' This adds a Kconfig 'select' statement to ensure the dependency is always there. Cc: <stable@vger.kernel.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> crypto/asymmetric_keys/Kconfig | 1 + 1 file changed, 1 insertion(+) commit d462e32259810aaaf13440b033b99e1aad33eccd Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 18 13:39:05 2016 +0300 crypto: omap-sham - potential Oops on error in probe This if statement is reversed so we end up either leaking or Oopsing on error. Fixes: dbe246209bc1 ('crypto: omap-sham - Use dma_request_chan() for requesting DMA channel') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/omap-sham.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3743a03e72b73b6234768bce06d7bf5a57c47285 Author: Alden Tondettar <alden.tondettar@gmail.com> Date: Wed May 18 14:09:18 2016 -0700 udf: Use IS_ERR when loading metadata mirror file entry Currently when udf_get_pblock_meta25() fails to map a block using the primary metadata file, it will attempt to load the mirror file entry by calling udf_find_metadata_inode_efe(). That function will return a ERR_PTR if it fails, but the return value is only checked against NULL. Test the return value using IS_ERR() and change it to NULL if needed. Signed-off-by: Alden Tondettar <alden.tondettar@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz> fs/udf/partition.c | 2 ++ 1 file changed, 2 insertions(+) commit 585d70006f6e30f42e96d56c6c0933671c516c7b Author: Alden Tondettar <alden.tondettar@gmail.com> Date: Wed May 18 14:09:17 2016 -0700 udf: Don't BUG on missing metadata partition descriptor Currently, if a metadata partition map is missing its partition descriptor, then udf_get_pblock_meta25() will BUG() out the first time it is called. This is rather drastic for a corrupted filesystem, so just treat this case as an invalid mapping instead. Signed-off-by: Alden Tondettar <alden.tondettar@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz> fs/udf/partition.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 5632a9fbcd451892332d45553ce8b831d5143691 Merge: a41980f e31db4c 07a7056 6427a84 Author: Russell King <rmk+kernel@armlinux.org.uk> Date: Thu May 19 10:31:35 2016 +0100 Merge branches 'amba', 'devel-stable', 'kexec-for-next' and 'misc' into for-linus commit 2552a39facb6609007a02eeda5d5edee4fcaca30 Author: Kees Cook <keescook@chromium.org> Date: Mon May 16 05:55:58 2016 -0700 coccicheck: Fix missing 0 index in kill loop By default, "seq" counts from 1, but processes were starting counting from 0, so when interrupted, coccicheck would leave the 0th process running. Signed-off-by: Kees Cook <keescook@chromium.org> Acked-by: Nicolas Palix <nicolas.palix@imag.fr> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/coccicheck | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 138a076496e61c68ebc1dcccc088705826bbe26d Merge: 1d4e89c 1eef33b Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu May 19 17:43:20 2016 +1000 Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/scottwood/linux into next Freescale updates from Scott: "Contains include 86xx fixes, minor device tree fixes, an erratum workaround, and a kconfig dependency fix." commit 6edf0aa4f8bbdfbb4d6d786892fa02728d05dc36 Author: Michael Holzheu <holzheu@linux.vnet.ibm.com> Date: Wed May 11 21:13:13 2016 +0200 s390/bpf: fix recache skb->data/hlen for skb_vlan_push/pop In case of usage of skb_vlan_push/pop, in the prologue we store the SKB pointer on the stack and restore it after BPF_JMP_CALL to skb_vlan_push/pop. Unfortunately currently there are two bugs in the code: 1) The wrong stack slot (offset 170 instead of 176) is used 2) The wrong register (W1 instead of B1) is saved So fix this and use correct stack slot and register. Fixes: 9db7f2b81880 ("s390/bpf: recache skb->data/hlen for skb_vlan_push/pop") Cc: stable@vger.kernel.org # 4.3+ Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/net/bpf_jit.h | 4 ++-- arch/s390/net/bpf_jit_comp.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 0fa963553a5c28d8f8aabd8878326d3f782045fc Author: Michael Holzheu <holzheu@linux.vnet.ibm.com> Date: Thu May 12 18:10:48 2016 +0200 s390/bpf: reduce maximum program size to 64 KB The s390 BFP compiler currently uses relative branch instructions that only support jumps up to 64 KB. Examples are "j", "jnz", "cgrj", etc. Currently the maximum size of s390 BPF programs is set to 0x7ffff. If branches over 64 KB are generated the, kernel can crash due to incorrect code. So fix this an reduce the maximum size to 64 KB. Programs larger than that will be interpreted. Fixes: ce2b6ad9c185 ("s390/bpf: increase BPF_SIZE_MAX") Cc: stable@vger.kernel.org # 4.3+ Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/net/bpf_jit_comp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d4bf7078c43e11097e0d6f04d3fb999bf92c4fb0 Author: Josh Poimboeuf <jpoimboe@redhat.com> Date: Tue May 17 13:06:06 2016 -0500 x86/entry/64: Fix stack return address retrieval in thunk With CONFIG_FRAME_POINTER enabled, a thunk can pass a bad return address value to the called function. '9*8(%rsp)' actually gets the frame pointer, not the return address. The only users of the 'put_ret_addr_in_rdi' option are two functions which trace the enabling and disabling of interrupts, so this bug can result in bad debug or tracing information with CONFIG_IRQSOFF_TRACER or CONFIG_PROVE_LOCKING. Fix this by implementing the suggestion of Linus: explicitly push the frame pointer all the time and constify the stack offsets that way. This is both correct and easier to read. Reported-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> [ Extended the changelog a bit. ] Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Alex Thorlton <athorlton@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: 058fb73274f9 ("x86/asm/entry: Create stack frames in thunk functions") Link: http://lkml.kernel.org/r/20160517180606.v5o7wcgdni7443ol@treble Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/thunk_64.S | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 2600a46ee0ed57c0e0a382c2a37ebac64d374d20 Merge: 03e1aa1 0fc1b09 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 18:55:19 2016 -0700 Merge tag 'trace-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing updates from Steven Rostedt: "This includes two new updates for the ftrace infrastructure. - With the changing of the code for filtering events by pid, from a list of pids to a bitmask, we can now easily implement following forks. With a new tracing option "event-fork" which, when set, will have tasks with pids in set_event_pid, when they fork, to have their child pids added to set_event_pid and the child will be traced as well. Note, if "event-fork" is set and a task with its pid in set_event_pid exits, its pid will be removed from set_event_pid - The addition of Tom Zanussi's hist triggers. This includes a very thorough documentatino on how to use the hist triggers with events. This introduces a quick and easy way to get histogram data from events and their fields. Some other cleanups and updates were added as well. Like Masami Hiramatsu added test cases for the event trigger and hist triggers. Also I added a speed up of filtering by using a temp buffer when filters are set" * tag 'trace-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: (45 commits) tracing: Use temp buffer when filtering events tracing: Remove TRACE_EVENT_FL_USE_CALL_FILTER logic tracing: Remove unused function trace_current_buffer_lock_reserve() tracing: Remove one use of trace_current_buffer_lock_reserve() tracing: Have trace_buffer_unlock_commit() call the _regs version with NULL tracing: Remove unused function trace_current_buffer_discard_commit() tracing: Move trace_buffer_unlock_commit{_regs}() to local header tracing: Fold filter_check_discard() into its only user tracing: Make filter_check_discard() local tracing: Move event_trigger_unlock_commit{_regs}() to local header tracing: Don't use the address of the buffer array name in copy_from_user tracing: Handle tracing_map_alloc_elts() error path correctly tracing: Add check for NULL event field when creating hist field tracing: checking for NULL instead of IS_ERR() tracing: Do not inherit event-fork option for instances tracing: Fix unsigned comparison to zero in hist trigger code kselftests/ftrace: Add a test for log2 modifier of hist trigger tracing: Add hist trigger 'log2' modifier kselftests/ftrace: Add hist trigger testcases kselftests/ftrace : Add event trigger testcases ... commit 03e1aa1cbb65d8fb214d82a98933362d1c115a4f Merge: 97f0090 188e3c5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 18:46:55 2016 -0700 Merge branch 'stable-4.7' of git://git.infradead.org/users/pcmoore/audit Pull audit updates from Paul Moore: "Four small audit patches for 4.7. Two are simple cleanups around the audit thread management code, one adds a tty field to AUDIT_LOGIN events, and the final patch makes tty_name() usable regardless of CONFIG_TTY. Nothing controversial, and it all passes our regression test" * 'stable-4.7' of git://git.infradead.org/users/pcmoore/audit: tty: provide tty_name() even without CONFIG_TTY audit: add tty field to LOGIN event audit: we don't need to __set_current_state(TASK_RUNNING) audit: cleanup prune_tree_thread commit 9fa78f63a8921ce37252be34ef8eea2f4bfbb13f Author: Marek Vasut <marex@denx.de> Date: Thu May 19 09:05:38 2016 +0800 nios2: Add order-only DTC dependency to %.dtb target The dtc dependency is missing, thus dtc is not built before it's invoked, resulting in the following problem: linux-2.6$ make 10m50_defconfig && make 10m50_devboard.dtb [...] scripts/kconfig/conf --silentoldconfig Kconfig DTC arch/nios2/boot/10m50_devboard.dtb /bin/sh: 1: ./scripts/dtc/dtc: not found arch/nios2/boot/Makefile:52: recipe for target 'arch/nios2/boot/10m50_devboard.dtb' failed make[1]: *** [arch/nios2/boot/10m50_devboard.dtb] Error 127 arch/nios2/Makefile:57: recipe for target '10m50_devboard.dtb' failed make: *** [10m50_devboard.dtb] Error 2 Signed-off-by: Marek Vasut <marex@denx.de> Cc: Ley Foon Tan <lftan@altera.com> Cc: Romain Perier <romain.perier@free-electrons.com> Acked-by: Ley Foon Tan <lftan@altera.com> arch/nios2/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97f00905ec98472050d65c46629237b299f29035 Merge: 676d973 b3d3903 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 17:22:19 2016 -0700 Merge tag 'rproc-v4.7' of git://github.com/andersson/remoteproc Pull remoteproc updates from Bjorn Andersson: "Introduce a synchronization point between the async firmware loading and clients requesting the remote processor to boot, as well as support for remote processors that are not interested in the resource table information" * tag 'rproc-v4.7' of git://github.com/andersson/remoteproc: remoteproc: Add additional crash reasons remoteproc: core: Make the loaded resource table optional remoteproc: core: Task sync during rproc_fw_boot() commit 676d9735cd010fc439566e2b6e9b6adc3e1179ef Merge: 888dae5 b4f7825 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 17:17:20 2016 -0700 Merge tag 'rpmsg-v4.7' of git://github.com/andersson/remoteproc Pull rpmsg updates from Bjorn Andersson: "Refactor rpmsg module registration to follow other subsystems; by introduction of module_rpmsg_driver and hiding of THIS_MODULE from clients" * tag 'rpmsg-v4.7' of git://github.com/andersson/remoteproc: rpmsg: use module_rpmsg_driver in existing drivers and examples rpmsg: add helper macro module_rpmsg_driver rpmsg: drop owner assignment from rpmsg_drivers rpmsg: add THIS_MODULE to rpmsg_driver in rpmsg core commit 888dae5361e605efc553b645a7c95bbcc5e904db Merge: 19c5abc 23ea596 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 17:12:23 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull input updates from Dmitry Torokhov: "First round of updates for the input subsystem. No new drivers here, just some driver fixes" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: rotary-encoder - fix bare use of 'unsigned' Input: cm109 - spin_lock in complete() cleanup Input: cm109 - fix handling of volume and mute buttons Input: byd - don't wipe dynamically allocated memory twice Input: twl4030 - fix unsafe macro definition Input: twl6040-vibra - remove mutex Input: bcm_iproc_tsc - DT spelling s/clock-name/clock-names/ Input: bcm_iproc_tsc - use syscon to access shared registers Input: ti_am335x_tsc - use SIMPLE_DEV_PM_OPS Input: omap-keypad - remove set_col_gpio_val() and get_row_gpio_val() Input: omap-keypad - drop empty PM stubs Input: omap-keypad - remove adjusting of scan delay Input: gpio-keys - clean up device tree binding example Input: kbtab - stop saving struct usb_device Input: gtco - stop saving struct usb_device Input: aiptek - stop saving struct usb_device Input: acecad - stop saving struct usb_device commit 19c5abcb74b712a7824ae7c55862932534e7dfec Merge: 675e065 aff093d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 17:03:51 2016 -0700 Merge tag 'media/v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media Pull media updates from Mauro Carvalho Chehab: - added support for Intersil/Techwell TW686x-based video capture cards - v4l PCI skeleton driver moved to samples directory - Documentation cleanups and improvements - RC: reduced the memory footprint for IR raw events - tpg: Export the tpg code from vivid as a module - adv7180: Add device tree binding documentation - lots of driver improvements and fixes * tag 'media/v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (173 commits) [media] exynos-gsc: avoid build warning without CONFIG_OF [media] samples: v4l: from Documentation to samples directory [media] dib0700: add USB ID for another STK8096-PVR ref design based card [media] tvp5150: propagate I2C write error in .s_register callback [media] tvp5150: return I2C write operation failure to callers [media] em28xx: add support for Hauppauge WinTV-dualHD DVB tuner [media] em28xx: add missing USB IDs [media] update cx23885 and em28xx cardlists [media] media: au0828 fix au0828_v4l2_device_register() to not unlock and free [media] c8sectpfe: Rework firmware loading mechanism [media] c8sectpfe: Demote print to dev_dbg [media] c8sectpfe: Fix broken circular buffer wp management [media] media-device: Simplify compat32 logic [media] media: i2c: ths7303: remove redundant assignment on bt [media] dvb-usb: hide unused functions [media] xilinx-vipp: remove unnecessary of_node_put [media] drivers/media/media-devnode: clear private_data before put_device() [media] drivers/media/media-device: move debug log before _devnode_unregister() [media] drivers/media/rc: postpone kfree(rc_dev) [media] media/dvb-core: forward media_create_pad_links() return value ... commit 675e0655c12209ba1f40af0dff7cd76b17a1315c Merge: d974f09 e7ca7f9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 16:38:59 2016 -0700 Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI updates from James Bottomley: "First round of SCSI updates for the 4.6+ merge window. This batch includes the usual quota of driver updates (bnx2fc, mp3sas, hpsa, ncr5380, lpfc, hisi_sas, snic, aacraid, megaraid_sas). There's also a multiqueue update for scsi_debug, assorted bug fixes and a few other minor updates (refactor of scsi_sg_pools into generic code, alua and VPD updates, and struct timeval conversions)" * tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (138 commits) mpt3sas: Used "synchronize_irq()"API to synchronize timed-out IO & TMs mpt3sas: Set maximum transfer length per IO to 4MB for VDs mpt3sas: Updating mpt3sas driver version to 13.100.00.00 mpt3sas: Fix initial Reference tag field for 4K PI drives. mpt3sas: Handle active cable exception event mpt3sas: Update MPI header to 2.00.42 Revert "lpfc: Delete unnecessary checks before the function call mempool_destroy" eata_pio: missing break statement hpsa: Fix type ZBC conditional checks scsi_lib: Decode T10 vendor IDs scsi_dh_alua: do not fail for unknown VPD identification scsi_debug: use locally assigned naa scsi_debug: uuid for lu name scsi_debug: vpd and mode page work scsi_debug: add multiple queue support bfa: fix bfa_fcb_itnim_alloc() error handling megaraid_sas: Downgrade two success messages to info cxlflash: Fix to resolve dead-lock during EEH recovery scsi_debug: rework resp_report_luns scsi_debug: use pdt constants ... commit 60f05e86cf3e8c5f379fe5ba94634fcec17dd67e Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed May 18 17:55:28 2016 +0530 cpufreq: schedutil: Improve prints messages with pr_fmt Prefix print messages with KBUILD_MODNAME, i.e 'cpufreq_schedutil: '. This helps to keep similar formatting for all the print messages particular to a file and identify those easily in kernel logs. Its already done this way for rest of the governors. Along with that, remove the (now) redundant bits from a print message. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> kernel/sched/cpufreq_schedutil.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit d974f09ea4970d0299a8267111312b80adbd20e6 Merge: 4a5219e b3c8eb5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 15:30:04 2016 -0700 Merge branch 'stable/for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/ibft Pull iscsi_ibft updates from Konrad Rzeszutek Wilk: "The pull has two features - both of them expand the SysFS entries: - 'prefix-len' - which is subnet_mask_prefix of the iBFT header. - 'acpi_header' dir with: 'iBFT', OEM-ID (whatever it extracts from the iBFT header) and OEM_TABLE_ID (also whatever it extracts from the iBFT header). This is to help NIC drivers to figure out during bootup how to deal with BIOS created iBFT tables (like by TianoCore UEFI implemenation)" * 'stable/for-linus-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/ibft: ibft: Expose iBFT acpi header via sysfs iscsi_ibft: Add prefix-len attr and display netmask commit b8bef79df709533416a278c4c3aef3577cefa61a Author: Tiezhu Yang <kernelpatch@126.com> Date: Wed May 18 08:02:25 2016 +0800 f2fs: make exit_f2fs_fs more clear init_f2fs_fs does: 1) f2fs_build_trace_ios 2) init_inodecache 3) create_node_manager_caches 4) create_segment_manager_caches 5) create_checkpoint_caches 6) create_extent_cache 7) kset_create_and_add 8) kobject_init_and_add 9) register_shrinker 10) register_filesystem 11) f2fs_create_root_stats 12) proc_mkdir exit_f2fs_fs should do cleanup in the reverse order to make the code more clear. Signed-off-by: Tiezhu Yang <kernelpatch@126.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 513c5f3735a9bd0bd8b58b6cdafbad5ef19f2159 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon May 16 11:42:32 2016 -0700 f2fs: use percpu_counter for total_valid_inode_count This patch uses percpu_counter to avoid stat_lock. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 18 +++++++----------- fs/f2fs/super.c | 11 ++++++++--- 2 files changed, 15 insertions(+), 14 deletions(-) commit 41382ec43255b502321c3c27f1347efeb3279290 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon May 16 11:06:50 2016 -0700 f2fs: use percpu_counter for alloc_valid_block_count This patch uses percpu_count for sbi->alloc_valid_block_count. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 2 +- fs/f2fs/f2fs.h | 8 +++++--- fs/f2fs/recovery.c | 5 +++-- fs/f2fs/super.c | 7 +++++-- 4 files changed, 14 insertions(+), 8 deletions(-) commit 1beba1b3a953107c3ff5448ab4e4297db4619c76 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri May 13 12:47:11 2016 -0700 f2fs: use percpu_counter for # of dirty pages in inode This patch adds percpu_counter for # of dirty pages in inode. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 10 +++++----- fs/f2fs/file.c | 2 +- fs/f2fs/super.c | 7 ++++++- 3 files changed, 12 insertions(+), 7 deletions(-) commit 523be8a6b3418eb7e0f0f042fe0490345eb5d516 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri May 13 12:36:58 2016 -0700 f2fs: use percpu_counter for page counters This patch substitutes percpu_counter for atomic_counter when counting various types of pages. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/debug.c | 11 ++++++----- fs/f2fs/f2fs.h | 24 ++++++++++++++---------- fs/f2fs/super.c | 31 +++++++++++++++++++++++++++---- include/trace/events/f2fs.h | 10 +++++----- 4 files changed, 52 insertions(+), 24 deletions(-) commit f573018491fd823e909d587cfe16758f3dd9e6d6 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue May 17 16:23:36 2016 -0700 f2fs: use bio count instead of F2FS_WRITEBACK page count This can reduce page counting overhead. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 2 +- fs/f2fs/data.c | 26 +++++++++++++++----------- fs/f2fs/debug.c | 6 +++--- fs/f2fs/f2fs.h | 4 ++-- fs/f2fs/super.c | 3 +-- 5 files changed, 22 insertions(+), 19 deletions(-) commit 24e04d72eb43d36d28fa7908f9f8d506d1cb06e7 Merge: 7c10ddf c6740c9 Author: Dave Airlie <airlied@redhat.com> Date: Thu May 19 06:48:29 2016 +1000 Merge tag 'topic/drm-misc-2016-05-18' of git://anongit.freedesktop.org/drm-intel into drm-next Update drm-misc pull with a few more fixes included, plus the two from Arnd for the fallout from the drm_gem_object_lookup() refactor that I failed to spot :( * tag 'topic/drm-misc-2016-05-18' of git://anongit.freedesktop.org/drm-intel: drm: remove unused dev variables drm: mediatek: fixup drm_gem_object_lookup API change drm/tegra: Fix crash caused by reference count imbalance drm: Fix error handling in drm_connector_register drm: Avoid connector reference imbalance on error path drm/fb_helper: Fix references to dev->mode_config.num_connector drm/i915/fbdev: Fix num_connector references in intel_fb_initial_config() qxl: catch qxlfb_create_pinned_object failures drm/exynos/hdmi: add a missing tab drm/fb-cma-helper: Add function drm_fb_cma_create_with_funcs() drm/fb-cma-helper: Use const for drm_framebuffer_funcs argument drm: Drop connector argument from __drm_atomic_helper_connector_destroy_state drm: Drop plane argument from __drm_atomic_helper_plane_destroy_state drm: Drop crtc argument from __drm_atomic_helper_crtc_destroy_state drm: Remove unused drm_device from drm_gem_object_lookup() commit 4a5219edcdae52bfb5eea0dfc2a7bd575961dad7 Merge: 9797f6b 5420f9f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 13:14:02 2016 -0700 Merge tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC driver updates from Arnd Bergmann: "Driver updates for ARM SoCs, these contain various things that touch the drivers/ directory but got merged through arm-soc for practical reasons. For the most part, this is now related to power management controllers, which have not yet been abstracted into a separate subsystem, and typically require some code in drivers/soc or arch/arm to control the power domains. Another large chunk here is a rework of the NVIDIA Tegra USB3.0 support, which was surprisingly tricky and took a long time to get done. Finally, reset controller handling as always gets merged through here as well" * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (97 commits) arm-ccn: Enable building as module soc/tegra: pmc: Add generic PM domain support usb: xhci: tegra: Add Tegra210 support usb: xhci: Add NVIDIA Tegra XUSB controller driver dt-bindings: usb: xhci-tegra: Add Tegra210 XUSB controller support dt-bindings: usb: Add NVIDIA Tegra XUSB controller binding PCI: tegra: Support per-lane PHYs dt-bindings: pci: tegra: Update for per-lane PHYs phy: tegra: Add Tegra210 support phy: Add Tegra XUSB pad controller support dt-bindings: phy: tegra-xusb-padctl: Add Tegra210 support dt-bindings: phy: Add NVIDIA Tegra XUSB pad controller binding phy: core: Allow children node to be overridden clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs drivers: firmware: psci: make two helper functions inline soc: renesas: rcar-sysc: Add support for R-Car H3 power areas soc: renesas: rcar-sysc: Add support for R-Car E2 power areas soc: renesas: rcar-sysc: Add support for R-Car M2-N power areas soc: renesas: rcar-sysc: Add support for R-Car M2-W power areas soc: renesas: rcar-sysc: Add support for R-Car H2 power areas ... commit 9797f6b0504122e4ad9ff047a3d0521ad6706386 Merge: 2ec3240 0ef659a Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 13:07:57 2016 -0700 Merge tag 'armsoc-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC defconfig updates from Arnd Bergmann: "As usual, a bunch of commits, mostly adding drivers and other options to defconfigs. We are adding three new defconfig files for the newly added 32-bit machines (aspeed and mps2), the rest is mainly housekeeping. The changes outside of arch/arm/config/ are for a Kconfig symbol that got renamed" * tag 'armsoc-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (63 commits) ARM: aspeed: adapt defconfigs for new CONFIG_PRINTK_TIME ARM: u8500_defconfig: update sensor config ARM: u8500_defconfig: remove staging from defconfig ARM: multi_v7_defconfig: Remove unused Kconfig option MACH_UX500_DT ARM: at91/defconfig: sama5: add CONFIG_FHANDLE arm/configs: Add Aspeed defconfig arm/configs/multi_v5: Add Aspeed ast2400 ARM: at91: sama5: Update defconfig ARM: imx_v6_v7_defconfig: add CONFIG_MICREL_PHY ARM: imx_v6_v7_defconfig: add CONFIG_I2C_GPIO ARM: multi_v7: Enable Tegra XUSB controller in defconfig ARM: tegra: Enable XUSB controller in defconfig ARM: omap2plus_defconfig: Enable PWM and ir-rx51 as loadable modules ARM: multi_v7_defconfig: add the Atmel sama5d2-compatible ADC driver ARM: multi_v7_defconfig: add the Atmel Audio microphone interface PDMIC ARM: multi_v7_defconfig: add Atmel ISI (Image Sensor Interface) driver ARM: multi_v7_defconfig: add Atmel watchdog timers ARM: multi_v7_defconfig: add HLCDC drivers as modules ARM: at91/defconfig: add PDMIC driver to sama5_defconfig ARM: at91/defconfig: add HLCDC driver to sama5_defconfig ... commit 2ec3240fd7956fe9525c336947b4473f7276f2b1 Merge: f7df9be 9910f5b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:58:39 2016 -0700 Merge tag 'armsoc-dt64' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM 64-bit DT updates from Arnd Bergmann: "We continue ramping up platform support for 64-bit ARM machines, with 111 individual non-merge changesets touching 21 platforms. The LG1312 platform is completely new and is the first ARM platform by LG that we support in the mainline kernel. Two other SoCs got added that are updated versions of existing SoC families, so the port mainly consists of new dts files: - The Hisilicon Hip06/D03 is the latest server platform from Huawei/Hisilicon, and follows the Hip05/D02 platform. - Rockchip RK3399 follows the 32-bit RK3288 that is popular in low-end Chromebooks and the 64-bit RK3368 that is mainly found in chinese Android TV boxes. The 96Boards HiKey based on the Hisilicon Hi6220 (Kirin 620) gets a long-awaited overhaul with a lot of devices enabled in the DT, so it should be much more usable with a mainline kernel now. See also https://plus.google.com/111524780435806926688/posts/PeGb2VsNhJd A lot of work went into enabling new device drivers on existing machines, but we also have a couple of new commercially available machines: - Google Pixel C laptop based on Tegra210 - Hardkernel Odroid C2 Based on Amlogic Meson GXBB (S905) - Geekbuying GeekBox based on Rockchip RK3368 And finally, a couple of reference or development platforms that are not end-user platforms but are used for trying out the respective SoC platforms: - Amlogic Meson GXBB P200 and P201 development systems - NXP Layerscape 1043A QDS development board - Hisilicon Hip06 D03 server board, as mentioned above - LG1312 Reference Design - RK3399 Evaluation Board" * tag 'armsoc-dt64' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (104 commits) arm64: dts: marvell: add XOR node for Armada 3700 SoC dt-bindings: document rockchip rk3399-evb board arm64: dts: rockchip: add dts file for RK3399 evaluation board arm64: dts: rockchip: add core dtsi file for RK3399 SoCs dt-bindings: rockchip-dw-mshc: add description for rk3399 arm64: dts: marvell: Use a SoC-specific compatible for xHCI on Armada37xx arm64: dts: marvell: Rename armada-37xx USB node arm64: dts: marvell: Clean up armada-3720-db Documentation: arm64: Add Hisilicon Hip06 D03 dts binding arm64: dts: Add initial dts for Hisilicon Hip06 D03 board arm64: dts: hip05: Add nor flash support arm64: dts: hip05: fix its node without msi-cells arm64: dts: r8a7795: Don't disable referenced optional clocks arm64: dts: salvator-x: populate EXTALR arm64: dts: r8a7795: enable PCIe on Salvator-X arm64: dts: r8a7795: Add PCIe nodes arm64: tegra: Add IOMMU node to GM20B on Tegra210 arm64: tegra: Add reference clock to GM20B on Tegra210 dt-bindings: Add documentation for GM20B GPU dt-bindings: gk20a: Document iommus property ... commit f7df9be067160eef52f04bd2f137a20683fb1c12 Merge: 9f8f202 ec42083 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:48:46 2016 -0700 Merge tag 'armsoc-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM DT updates from Arnd Bergmann: "These are all the updates to device tree files for 32-bit platforms, which as usual makes up the bulk of the ARM SoC changes: 462 non-merge changesets, 450 files changed, 23340 insertions, 5216 deletions. The three platforms that are added with the "soc" branch are here as well, and we add some related machine files: - For Aspeed AST2400/AST2500, we get the evaluation platform and the Tyan Palmetto POWER8 mainboard that uses the AST2400 BMC - For Oxnas 810SE, the Western Digital "My Book World Edition" is added as the only platform at the moment. - For ARM MPS2, the AN385 (Cortex-M3) and AN399 (Cortex-M7) are supported On the ARM Realview development platform, we now support all machines with device tree, previously only the board files were supported, which in turn will likely be removed soon. Qualcomm IPQ4019 is the second generation ARM based "Internet Processor", following the IPQ806x that is used in many high-end WiFi routers. This one integrates two ath10k wifi radios that were previously on separate chips. Other boards that got added for existing chips are: Ti OMAP family: - Amazon Kindle Fire, first generation, tablet and ebook reader - OnRISC Baltos iR 2110 and 3220 embedded industrial PCs - TI AM5728 IDK, TI AM3359 ICE-V2, and TI DRA722 Rev C EVM development systems Samsung EXYNOS platform: - Samsung ARTIK5 evaluation board, see https://www.artik.io/modules/overview/artik-5/ NXP i.MX platforms: - Ka-Ro electronics TX6S-8034, TX6S-8035, TX6U-8033, TX6U-81xx, TX6Q-1036, TX6Q-1110/-1130, TXUL-0010 and TXUL-0011 industrial SoM modules - Embest MarS Board i.MX6Dual DIY platform - Boundary Devices i.MX6 Quad Plus Nitrogen6_MAX and SoloX Nitrogen6sx embedded boards - Technexion Pico i.MX6UL compute module - ZII VF610 Development Board Marvell embedded (mvebu, orion, kirkwood) platforms: - Linksys Viper (E4200v2 / EA4500) WiFi router - Buffalo Kurobox Pro NAS Qualcomm Snapdragon: - Arrow DragonBoard 600c (96boards) with APQ8064 Snapdragon 600 Rockchips platform: - mqmaker MiQi single-board computer Altera SoCFPGA: - samtec VIN|ING 1000 vehicle communication interface Allwinner Sunxi platforms: - Dserve DSRV9703C tablet - Difrnce DIT4350 tablet - Colorfly E708 Q1 tablet - Polaroid MID2809PXE04 tablet - Olimex A20 OLinuXino LIME2 single board computer - Xunlong Orange Pi 2, Orange Pi One, and Orange Pi PC single board computers Across many platforms, bug fixes went in to address warnings that dtc now emits with 'make dtbs W=1'. Further changes for device enablement went into Ti OMAP, bcm283x (Raspberry Pi), bcm47xx (wifi router), Ti Davinci, Samsung EXYNOS, Marvell mvebu/kirkwood/orion, NXP i.MX/Vybrid NXP LPC18xx, NXP LPC32xx, Renesas shmobile/r-mobile/r-car, Rockchips rk3xxx, ST Ux500, ST STi, Atmel AT91/SAMA5, Altera SoCFPGA, Allwinner Sunxi, Sigma Designs Tango, NVIDIA Tegra, Socionext Uniphier and ARM Versatile Express" * tag 'armsoc-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (458 commits) ARM: dts: tango4: Import watchdog node ARM: dts: tango4: Update cpus node for cpufreq ARM: dts: tango4: Update DT to match clk driver ARM: dts: tango4: Initial thermal support arm/dst: Add Aspeed ast2500 device tree arm/dts: Add Aspeed ast2400 device tree ARM: sun7i: dt: Add pll3 and pll7 clocks ARM: dts: sunxi: Add a olinuxino-lime2-emmc ARM: dts: at91: sama5d4: add trng node ARM: dts: at91: sama5d3: add trng node ARM: dts: at91: sama5d2: add trng node ARM: dts: at91: at91sam9g45 family: reduce the trng register map size ARM: sun4i: dt: Add pll3 and pll7 clocks ARM: sun5i: chip: Enable the TV Encoder ARM: sun5i: r8: Add display blocks to the DTSI ARM: sun5i: a13: Add display and TCON clocks ARM: dts: ux500: configure the accelerometers open drain ARM: mx5: dts: Enable USB OTG on M53EVK ARM: dts: imx6ul-14x14-evk: Add audio support ARM: dts: imx6qdl: Remove unneeded unit-addresses ... commit 9f8f2022786dae0bd48ba35006d6c3ed1ffb469d Merge: 9896c7b da4a95d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:43:08 2016 -0700 Merge tag 'armsoc-arm64' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC 64-bit changes from Arnd Bergmann: "One new platform gets added this time: The Cortex-A53 based LG Electronics LG1K platform used in digital TVs. The other changes are mostly smaller updates to the defconfig files, to enable additional platform specific drivers, as they get merged through the subsystem trees" * tag 'armsoc-arm64' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: arm64: configs: add options useful for Armada 7K/8K support arm64: defconfig: Add Juno SATA controller arm64: defconfig: enable freescale/nxp config options arm64: defconfig: enable 48-bit virtual addresses arm64: defconfig: cleanup the defconfig MAINTAINERS: update entry for Marvell ARM platform maintainers arm64: marvell: enable AP806 and CP110 syscon driver arm64: Kconfig: select sp804 timer for ARCH_HISI arm64: defconfig: enable configs for WLAN and TI WL1835 as modules arm64: defconfig: enable several common USB network adapters arm64: defconfig: add CONFIG_SPI_SPIDEV as module arm64: defconfig: Enable the PMIC and regulator for Hi6220 and 96boards HiKey arm64: defconfig: Add Renesas R-Car USB 3.0 driver support MAINTAINERS: add Chanho Min as ARM/LG1K maintainer arm64: defconfig: enable ARCH_LG1K arm64: add Kconfig entry for LG1K SoC family arm64: defconfig: Enable PL330 DMA controller arm64: defconfig: enable basic boot for Amlogic meson commit 9896c7b57e9d67948f1f52f903efae5ec6c74321 Merge: f2b1e0f b54891b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:35:46 2016 -0700 Merge tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC platform updates from Arnd Bergmann: "We get support for three new 32-bit SoC platforms this time. The amount of changes in arch/arm for any of them is miniscule, as all the interesting code is in device driver subsystems (irqchip, clk, pinctrl, ...) these days. I'm listing them here, as the addition of the Kconfig statement is the main relevant milestone for a new platform. In each case, some drivers are are shared with existing platforms, while other drivers are added for v4.7 as well, or come in a later release. - The Aspeed platform is probably the most interesting one, this is what most whitebox servers use as their baseboard management controller. We get support for the very common ast2400 and ast2500 SoCs. The OpenBMC project focuses on this chip, and the LWN article about their ELC 2016 presentation at https://lwn.net/Articles/683320/ triggered the submission, but the code comes from IBM's OpenPOWER team rather than the team at Facebook. There are still a lot more drivers that need to get added over time, and I hope both teams can work together on that. - OXNAS is an old platform for Network Attached Storage devices from Oxford Semiconductor. There are models with ARM10 (!) and ARM11MPCore cores, but for now, we only support the original ARM9 based versions. The product lineup was subsequently part of PLX, Avago and now the new Broadcom Ltd. https://wiki.openwrt.org/doc/hardware/soc/soc.oxnas has some more information. - V2M-MPS2 is a prototyping platform from ARM for their Cortex-M cores and is related to the existing Realview / Versatile Express lineup, but without MMU. We now support various NOMMU platforms, so adding a new one is fairly straightforward. http://infocenter.arm.com/help/topic/com.arm.doc.100112_0100_03_en/ has detailed information about the platform. Other noteworthy updates: - Work on LPC32xx has resumed, and Vladimir Zapolskiy and Sylvain Lemieux are now maintaining the platform. This is an older ARM9 based platform from NXP (not Freescale), but it remains in use in embedded markets. - Kevin Hilman is now co-maintaining the Amlogic Meson platform for both 32-bit and 64-bit ARM, and started contributing some patches. - As is often the case, work on the OMAP platforms makes up the bulk of the actual SoC code changes in arch/arm, but there isn't a lot of that either" * tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (42 commits) MAINTAINERS: ARM/Amlogic: add co-maintainer, misc. updates MAINTAINERS: add ARM/NXP LPC32XX SoC specific drivers to the section MAINTAINERS: add new maintainers of NXP LPC32xx SoC MAINTAINERS: move ARM/NXP LPC32xx record to ARM section arm: Add Aspeed machine ARM: lpc32xx: remove duplicate const on lpc32xx_auxdata_lookup ARM: lpc32xx: remove leftovers of legacy clock source and provider drivers ARM: lpc32xx: remove reboot header file ARM: dove: Remove CLK_IS_ROOT ARM: orion5x: Remove CLK_IS_ROOT ARM: mv78xx0: Remove CLK_IS_ROOT ARM: davinci: da850: use clk->set_parent for async3 ARM: davinci: Move clock init after ioremap. MAINTAINERS: Update ARM Versatile Express platform entry ARM: vexpress/mps2: introduce MPS2 platform MAINTAINERS: add maintainer entry for ARM/OXNAS platform ARM: Add new mach-oxnas irqchip: versatile-fpga: add new compatible for OX810SE SoC ARM: uniphier: correct the call order of of_node_put() MAINTAINERS: fix stale TI DaVinci entries ... commit f2b1e0f6385d4487a81871eb47809a1375af527f Merge: f61a657 2e629eb Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:28:29 2016 -0700 Merge tag 'armsoc-cleanups-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC cleanups and fixes from Arnd Bergmann: "Traditionally we've had two separate branches for cleanups and non-critical bug fixes, but both of these got smaller with each release and the differences are rather unclear now, so it seems more appropriate to have a combined branch. The most notable change is for OMAP, which gets a small rework to simplify handling of the AUXDATA mechanism used on machines that are not completely DT based yet, along with other work that is used as preparation for dropping the legacy board files" * tag 'armsoc-cleanups-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: ARM: dts: exynos: Add interrupt line to MAX8997 PMIC on exynos4210-trats ARM: dts: exynos: Fix regulator name to avoid forbidden character on exynos4210-trats ARM: dts: exynos: Add MFC memory banks for Peach boards ARM: OMAP2+: n900 needs MMC slot names for legacy user space ARM: OMAP2+: Add more functions to pwm pdata for ir-rx51 ARM: debug: remove extraneous DEBUG_HI3716_UART option ARM: OMAP2+: Simplify auxdata by using the generic match of/platform: Allow secondary compatible match in of_dev_lookup ARM: davinci: use IRQCHIP_DECLARE for cp_intc ARM: davinci: remove unused DA8XX_NUM_UARTS ARM: davinci: simplify call to of populate ARM: DaVinci USB: removed deprecated properties from MUSB config ARM: rockchip: Fix use of plain integer as NULL pointer ARM: realview: hide unused 'pmu_device' object soc: versatile: dynamically detect RealView HBI numbers commit f61a657fdf221403d99e6f0d4c6d24762920d4a9 Merge: 0e034f5 c53db52 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 12:17:16 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux Pull s390 updates from Martin Schwidefsky: "The s390 patches for the 4.7 merge window have the usual bug fixes and cleanups, and the following new features: - An interface for dasd driver to query if a volume is online to another operating system - A new ioctl for the dasd driver to verify the format for a range of tracks - Following the example of x86 the struct fpu is now allocated with the task_struct - The 'report_error' interface for the PCI bus to send an adapter-error notification from user space to the service element of the machine" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: (29 commits) s390/vmem: remove unused function parameter s390/vmem: fix identity mapping s390: add missing include statements s390: add missing declarations s390: make couple of variables and functions static s390/cache: remove superfluous locking s390/cpuinfo: simplify locking and skip offline cpus early s390/3270: hangup the 3270 tty after a disconnect s390/3270: handle reconnect of a tty with a different size s390/3270: avoid endless I/O loop with disconnected 3270 terminals s390/3270: fix garbled output on 3270 tty view s390/3270: fix view reference counting s390/3270: add missing tty_kref_put s390/dumpstack: implement and use return_address() s390/cpum_sf: Remove superfluous SMP function call s390/cpum_cf: Remove superfluous SMP function call s390/Kconfig: make z196 the default processor type s390/sclp: avoid compile warning in sclp_pci_report s390/fpu: allocate 'struct fpu' with the task_struct s390/crypto: cleanup and move the header with the cpacf definitions ... commit 0e034f5c4bc408c943f9c4a06244415d75d7108c Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 11:51:25 2016 -0700 iwlwifi: fix mis-merge that breaks the driver My laptop that uses the intel 7680 iwlwifi module would no longer connects to the network. It would fail with a "Microcode SW error detected." and spew out register state over and over again without ever connecting to the network. The cause is mis-merge in commit 909b27f70643, where David seems to have lost some of the changes to iwl_mvm_set_tx_cmd() from commit 5c08b0f5026f ("iwlwifi: mvm: don't override the rate with the AMSDU len"). The reason seems to be a conflict with commit d8fe484470dd ("iwlwifi: mvm: add support for new TX CMD API"), which touched a line adjacent to the changes in 909b27f70643. David missed the fact that "info->driver_data[0]" had become "skb_info->driver_data[0]". Then he removed the skb_info because it was unused. This just re-updates iwl_mvm_set_tx_cmd() with the lost two lines. Reported-and-tested-by: Linus Torvalds <torvalds@linux-foundation.org> Reported-by: Reinoud Koornstra <reinoudkoornstra@gmail.com> Cc: Luciano Coelho <luciano.coelho@intel.com> Cc: Kalle Valo <kvalo@codeaurora.org> Cc: David Miller <davem@davemloft.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9e17632c0a146891c90a4353a160cfcf71f34b8f Merge: 6937047 2c4cb04 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 11:51:59 2016 -0700 Merge branch 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull misc vfs cleanups from Al Viro: "Assorted cleanups and fixes all over the place" * 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: coredump: only charge written data against RLIMIT_CORE coredump: get rid of coredump_params->written ecryptfs_lookup(): try either only encrypted or plaintext name ecryptfs: avoid multiple aliases for directories bpf: reject invalid names right in ->lookup() __d_alloc(): treat NULL name as QSTR("/", 1) mtd: switch ubi_open_volume_path() to vfs_stat() mtd: switch open_mtd_by_chdev() to use of vfs_stat() commit 69370471d0b2fc3020c60f5473b1eef5977d165a Merge: e34df33 dd254f5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 11:46:23 2016 -0700 Merge branch 'work.iov_iter' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull iov_iter cleanups from Al Viro. * 'work.iov_iter' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: fold checks into iterate_and_advance() rw_verify_area(): saner calling conventions aio: remove a pointless assignment commit 40543f62cbdce42633e3fe10923099feee272e1f Author: Vishal Verma <vishal.l.verma@intel.com> Date: Thu Apr 21 16:45:56 2016 -0400 dax: fix a comment in dax_zero_page_range and dax_truncate_page The distinction between PAGE_SIZE and PAGE_CACHE_SIZE was removed in 09cbfea mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros The comments for the above functions described a distinction between those, that is now redundant, so remove those paragraphs Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 12 ------------ 1 file changed, 12 deletions(-) commit 4b0228fa1d753f77fe0e6cf4c41398ec77dfbd2a Author: Vishal Verma <vishal.l.verma@intel.com> Date: Thu Apr 21 15:13:46 2016 -0400 dax: for truncate/hole-punch, do zeroing through the driver if possible In the truncate or hole-punch path in dax, we clear out sub-page ranges. If these sub-page ranges are sector aligned and sized, we can do the zeroing through the driver instead so that error-clearing is handled automatically. For sub-sector ranges, we still have to rely on clear_pmem and have the possibility of tripping over errors. Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Jeff Moyer <jmoyer@redhat.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Dave Chinner <david@fromorbit.com> Cc: Jan Kara <jack@suse.cz> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> Documentation/filesystems/dax.txt | 32 ++++++++++++++++++++++++++++++++ fs/dax.c | 30 +++++++++++++++++++++++++----- 2 files changed, 57 insertions(+), 5 deletions(-) commit 679c8bd3b29428e736eabb7fc66a978f312f0c86 Author: Christoph Hellwig <hch@lst.de> Date: Mon May 9 10:47:04 2016 +0200 dax: export a low-level __dax_zero_page_range helper This allows XFS to perform zeroing using the iomap infrastructure and avoid buffer heads. Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Christoph Hellwig <hch@lst.de> [vishal: fix conflicts with dax-error-handling] Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 35 ++++++++++++++++++++--------------- include/linux/dax.h | 7 +++++++ 2 files changed, 27 insertions(+), 15 deletions(-) commit 3dc29161070ab14d065554c0ad58988ab77a7bfd Author: Matthew Wilcox <matthew.r.wilcox@intel.com> Date: Tue Mar 15 11:20:41 2016 -0600 dax: use sb_issue_zerout instead of calling dax_clear_sectors dax_clear_sectors() cannot handle poisoned blocks. These must be zeroed using the BIO interface instead. Convert ext2 and XFS to use only sb_issue_zerout(). Reviewed-by: Jeff Moyer <jmoyer@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com> [vishal: Also remove the dax_clear_sectors function entirely] Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 32 -------------------------------- fs/ext2/inode.c | 8 ++++---- fs/xfs/xfs_bmap_util.c | 15 ++++----------- include/linux/dax.h | 1 - 4 files changed, 8 insertions(+), 48 deletions(-) commit 0a70bd43053331d99881211e1d09f32de531432f Author: Dan Williams <dan.j.williams@intel.com> Date: Wed Feb 24 14:02:11 2016 -0800 dax: enable dax in the presence of known media errors (badblocks) 1/ If a mapping overlaps a bad sector fail the request. 2/ Do not opportunistically report more dax-capable capacity than is requested when errors present. Reviewed-by: Jeff Moyer <jmoyer@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> [vishal: fix a conflict with system RAM collision patches] [vishal: add a 'size' parameter to ->direct_access] [vishal: fix a conflict with DAX alignment check patches] Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> arch/powerpc/sysdev/axonram.c | 2 +- drivers/block/brd.c | 2 +- drivers/nvdimm/pmem.c | 10 +++++++++- drivers/s390/block/dcssblk.c | 4 ++-- fs/block_dev.c | 13 +------------ include/linux/blkdev.h | 2 +- 6 files changed, 15 insertions(+), 18 deletions(-) commit d3030d11961a8c103cf07aed59905276ddfc06c2 Author: Mark Brown <broonie@kernel.org> Date: Wed May 18 18:30:39 2016 +0100 ASoC: ak4642: Enable cache usage to fix crashes on resume The ak4642 driver is using a regmap cache sync to restore the configuration of the chip on resume but (as Peter observed) does not actually define a register cache which means that the resume is never going to work and we trigger asserts in regmap. Fix this by enabling caching. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Reported-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Mark Brown <broonie@kernel.org> Cc: stable@vger.kernel.org sound/soc/codecs/ak4642.c | 3 +++ 1 file changed, 3 insertions(+) commit e34df3344d7b6f284e958147d7225faa340a1f39 Merge: 442c9ac 9f54180 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 10:28:45 2016 -0700 Merge branch 'work.lookups' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull parallel lookup fixups from Al Viro: "Fix for xfs parallel readdir (turns out the cxfs exposure was not enough to catch all problems), and a reversion of btrfs back to ->iterate() until the fs/btrfs/delayed-inode.c gets fixed" * 'work.lookups' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: xfs: concurrent readdir hangs on data buffer locks Revert "btrfs: switch to ->iterate_shared()" commit 9f5418010940236b2c39ea53b99055ca26ff1279 Author: Dave Chinner <david@fromorbit.com> Date: Thu May 19 00:17:26 2016 +1000 xfs: concurrent readdir hangs on data buffer locks There's a three-process deadlock involving shared/exclusive barriers and inverted lock orders in the directory readdir implementation. It's a pre-existing problem with lock ordering, exposed by the VFS parallelisation code. process 1 process 2 process 3 --------- --------- --------- readdir iolock(shared) get_leaf_dents iterate entries ilock(shared) map, lock and read buffer iunlock(shared) process entries in buffer ..... readdir iolock(shared) get_leaf_dents iterate entries ilock(shared) map, lock buffer <blocks> finish ->iterate_shared file_accessed() ->update_time start transaction ilock(excl) <blocks> ..... finishes processing buffer get next buffer ilock(shared) <blocks> And that's the deadlock. Fix this by dropping the current buffer lock in process 1 before trying to map the next buffer. This means we keep the lock order of ilock -> buffer lock intact and hence will allow process 3 to make progress and drop it's ilock(shared) once it is done. Reported-by: Xiong Zhou <xzhou@redhat.com> Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/xfs/xfs_dir2_readdir.c | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) commit fe742fd4f90fa53cf31296bc5131ae1cdd6d84bb Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 18 13:15:05 2016 -0400 Revert "btrfs: switch to ->iterate_shared()" This reverts commit 972b241f8441dc37a3f89dcd7e71d7f013873d13. Quoth Chris: didn't take the delayed inode stuff into account it got an rbtree of items and it pulls things out so in shared mode, its hugely racey sorry, lets revert and fix it for real inside of btrfs Signed-off-by: Chris Mason <clm@fb.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/btrfs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 442c9ac989d71599ebc39f4ea4d5b0e64996904b Merge: ba5a265 7133566 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 10:17:56 2016 -0700 Merge branch 'sendmsg.cifs' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull cifs iovec cleanups from Al Viro. * 'sendmsg.cifs' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: cifs: don't bother with kmap on read_pages side cifs_readv_receive: use cifs_read_from_socket() cifs: no need to wank with copying and advancing iovec on recvmsg side either cifs: quit playing games with draining iovecs cifs: merge the hash calculation helpers commit c6740c9c9e914742fd2ec159142c40701f7df966 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 18:07:33 2016 +0200 drm: remove unused dev variables After drm_gem_object_lookup() was changed along with all its callers, we have several drivers that have unused variables: drm/armada/armada_crtc.c: In function 'armada_drm_crtc_cursor_set': drm/armada/armada_crtc.c:900:21: error: unused variable 'dev' [-Werror=unused-variable] drm/nouveau/nouveau_gem.c: In function 'validate_init': drm/nouveau/nouveau_gem.c:371:21: error: unused variable 'dev' [-Werror=unused-variable] drm/nouveau/nv50_display.c: In function 'nv50_crtc_cursor_set': drm/nouveau/nv50_display.c:1308:21: error: unused variable 'dev' [-Werror=unused-variable] drm/radeon/radeon_cs.c: In function 'radeon_cs_parser_relocs': drm/radeon/radeon_cs.c:77:21: error: unused variable 'ddev' [-Werror=unused-variable] This fixes all the instances I found with ARM randconfig builds so far. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: a8ad0bd84f98 ("drm: Remove unused drm_device from drm_gem_object_lookup()") Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463587653-3035181-6-git-send-email-arnd@arndb.de drivers/gpu/drm/armada/armada_crtc.c | 1 - drivers/gpu/drm/nouveau/nouveau_gem.c | 1 - drivers/gpu/drm/nouveau/nv50_display.c | 1 - drivers/gpu/drm/radeon/radeon_cs.c | 1 - 4 files changed, 4 deletions(-) commit de4ae068ebf599f46ddfc5f8541a302226230267 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 18:07:31 2016 +0200 drm: mediatek: fixup drm_gem_object_lookup API change The drm_gem_object_lookup() function prototype changed while this driver was added, so it fails to build now: drivers/gpu/drm/mediatek/mtk_drm_gem.c: In function 'mtk_drm_gem_dumb_map_offset': drivers/gpu/drm/mediatek/mtk_drm_gem.c:142:30: error: passing argument 1 of 'drm_gem_object_lookup' from incompatible pointer type [-Werror=incompatible-pointer-types] obj = drm_gem_object_lookup(dev, file_priv, handle); This fixes the new caller as well. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: a8ad0bd84f98 ("drm: Remove unused drm_device from drm_gem_object_lookup()") Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463587653-3035181-4-git-send-email-arnd@arndb.de drivers/gpu/drm/mediatek/mtk_drm_fb.c | 2 +- drivers/gpu/drm/mediatek/mtk_drm_gem.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit ba5a2655c270f59dea2d9b4d764aec2f6e7f5f41 Merge: 8908c94 e0d46f5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 10:08:45 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull remaining vfs xattr work from Al Viro: "The rest of work.xattr (non-cifs conversions)" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: btrfs: Switch to generic xattr handlers ubifs: Switch to generic xattr handlers jfs: Switch to generic xattr handlers jfs: Clean up xattr name mapping gfs2: Switch to generic xattr handlers ceph: kill __ceph_removexattr() ceph: Switch to generic xattr handlers ceph: Get rid of d_find_alias in ceph_set_acl commit 1b982baf75e7d9585967fcfccd05b77bf9054010 Merge: 1f716d0 6ca7208 Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 10:07:19 2016 -0700 Merge branch 'for-4.7/acpi6.1' into libnvdimm-for-next commit 1f716d05f8daee4f393dc568ea7a53c7ecfd0bfc Merge: 2159669 a94e3fb Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 10:06:59 2016 -0700 Merge branch 'for-4.7/dsm' into libnvdimm-for-next commit 2159669f581917c4d197d3ea183d3d85b47faf66 Merge: 594d6d9 9dec489 Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 10:06:48 2016 -0700 Merge branch 'for-4.7/libnvdimm' into libnvdimm-for-next commit 8908c94d6cd7513ba4512295abc945a6ff7f979c Merge: 0b7962a 897fba1 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Wed May 18 10:01:47 2016 -0700 Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 Pull cifs updates from Steve French: "Various small CIFS and SMB3 fixes (including some for stable)" * 'for-next' of git://git.samba.org/sfrench/cifs-2.6: remove directory incorrectly tries to set delete on close on non-empty directories Update cifs.ko version to 2.09 fs/cifs: correctly to anonymous authentication for the NTLM(v2) authentication fs/cifs: correctly to anonymous authentication for the NTLM(v1) authentication fs/cifs: correctly to anonymous authentication for the LANMAN authentication fs/cifs: correctly to anonymous authentication via NTLMSSP cifs: remove any preceding delimiter from prefix_path cifs: Use file_dentry() commit 594d6d96ea042366878aa7dc7f5711b8c245db5a Merge: 1b8d2af 45a0dac Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 09:59:34 2016 -0700 Merge branch 'for-4.7/dax' into libnvdimm-for-next commit 45c04704e467fffe3525205454d9627325dae308 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Wed May 18 16:19:01 2016 +0300 ASoC: twl6040: Disconnect AUX output pads on digital mute Disconnect also the path to AUXL from the HF path during digital_mute to avoid pop noise leakage to Line-out pads. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/mfd/twl6040.h | 1 + sound/soc/codecs/twl6040.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) commit 6cf9c5babd980ec1959e0dd45e3036474c6a294f Author: Dan Williams <dan.j.williams@intel.com> Date: Wed May 18 09:13:13 2016 -0700 libnvdimm: stop requiring a driver ->remove() method The dax_pmem driver was implementing an empty ->remove() method to satisfy the nvdimm bus driver that unconditionally calls ->remove(). Teach the core bus driver to check if ->remove() is NULL to remove that requirement. Reported-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/bus.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 9842df62004f366b9fed2423e24df10542ee0dc5 Author: Andy Honig <ahonig@google.com> Date: Tue May 17 17:41:47 2016 +0200 KVM: MTRR: remove MSR 0x2f8 MSR 0x2f8 accessed the 124th Variable Range MTRR ever since MTRR support was introduced by 9ba075a664df ("KVM: MTRR support"). 0x2f8 became harmful when 910a6aae4e2e ("KVM: MTRR: exactly define the size of variable MTRRs") shrinked the array of VR MTRRs from 256 to 8, which made access to index 124 out of bounds. The surrounding code only WARNs in this situation, thus the guest gained a limited read/write access to struct kvm_arch_vcpu. 0x2f8 is not a valid VR MTRR MSR, because KVM has/advertises only 16 VR MTRR MSRs, 0x200-0x20f. Every VR MTRR is set up using two MSRs, 0x2f8 was treated as a PHYSBASE and 0x2f9 would be its PHYSMASK, but 0x2f9 was not implemented in KVM, therefore 0x2f8 could never do anything useful and getting rid of it is safe. This fixes CVE-2016-3713. Fixes: 910a6aae4e2e ("KVM: MTRR: exactly define the size of variable MTRRs") Cc: stable@vger.kernel.org Reported-by: David Matlack <dmatlack@google.com> Signed-off-by: Andy Honig <ahonig@google.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/mtrr.c | 2 -- 1 file changed, 2 deletions(-) commit 67c9dddc95ac16a09db996e8e4dcacfd94cf2306 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Tue May 10 17:01:23 2016 +0200 KVM: x86: make hwapic_isr_update and hwapic_irr_update look the same Neither APICv nor AVIC actually need the first argument of hwapic_isr_update, but the vCPU makes more sense than passing the pointer to the whole virtual machine! In fact in the APICv case it's just happening that the vCPU is used implicitly, through the loaded VMCS. The second argument instead is named differently, make it consistent. Reviewed-by: Radim Krčmář <rkrcmar@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 2 +- arch/x86/kvm/lapic.c | 6 +++--- arch/x86/kvm/svm.c | 2 +- arch/x86/kvm/vmx.c | 10 +++++----- 4 files changed, 10 insertions(+), 10 deletions(-) commit 8221c13700561b36fb1bfda583888cbb43b572f0 Author: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Date: Wed May 4 14:09:52 2016 -0500 svm: Manage vcpu load/unload when enable AVIC When a vcpu is loaded/unloaded to a physical core, we need to update host physical APIC ID information in the Physical APIC-ID table accordingly. Also, when vCPU is blocking/un-blocking (due to halt instruction), we need to make sure that the is-running bit in set accordingly in the physical APIC-ID table. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Reviewed-by: Radim Krčmář <rkrcmar@redhat.com> [Return void from new functions, add WARN_ON when they returned negative errno; split load and put into separate function as they have almost nothing in common. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/svm.c | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) commit 3bbf3565f48ce3999b5a12cde946f81bd4475312 Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:51 2016 -0500 svm: Do not intercept CR8 when enable AVIC When enable AVIC: * Do not intercept CR8 since this should be handled by AVIC HW. * Also, we don't need to sync cr8/V_TPR and APIC backing page. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> [Rename svm_in_nested_interrupt_shadow to svm_nested_virtualize_tpr. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/svm.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit 46781eae2e3210153476958ea023ce7b44825963 Author: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Date: Wed May 4 14:09:50 2016 -0500 svm: Do not expose x2APIC when enable AVIC Since AVIC only virtualizes xAPIC hardware for the guest, this patch disable x2APIC support in guest CPUID. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/svm.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit be8ca170edf342cc45ae4a6431ef192e5cbe211e Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:49 2016 -0500 KVM: x86: Introducing kvm_x86_ops.apicv_post_state_restore Adding kvm_x86_ops hooks to allow APICv to do post state restore. This is required to support VM save and restore feature. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 1 + arch/x86/kvm/lapic.c | 2 ++ arch/x86/kvm/svm.c | 10 ++++++++++ 3 files changed, 13 insertions(+) commit 18f40c53e10f8d1267dc47cce4487664eececd6d Author: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Date: Wed May 4 14:09:48 2016 -0500 svm: Add VMEXIT handlers for AVIC This patch introduces VMEXIT handlers, avic_incomplete_ipi_interception() and avic_unaccelerated_access_interception() along with two trace points (trace_kvm_avic_incomplete_ipi and trace_kvm_avic_unaccelerated_access). Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 1 + arch/x86/include/uapi/asm/svm.h | 9 +- arch/x86/kvm/lapic.h | 3 + arch/x86/kvm/svm.c | 279 ++++++++++++++++++++++++++++++++++++++++ arch/x86/kvm/trace.h | 57 ++++++++ arch/x86/kvm/x86.c | 2 + 6 files changed, 350 insertions(+), 1 deletion(-) commit 340d3bc3664e5d3fb922fe6e3ae2d901d4900d88 Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:47 2016 -0500 svm: Add interrupt injection via AVIC This patch introduces a new mechanism to inject interrupt using AVIC. Since VINTR is not supported when enable AVIC, we need to inject interrupt via APIC backing page instead. This patch also adds support for AVIC doorbell, which is used by KVM to signal a running vcpu to check IRR for injected interrupts. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/svm.c | 39 +++++++++++++++++++++++++++++++++++---- 1 file changed, 35 insertions(+), 4 deletions(-) commit 44a95dae1d229a4967bbfcc56fb2116a9b4fe942 Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:46 2016 -0500 KVM: x86: Detect and Initialize AVIC support This patch introduces AVIC-related data structure, and AVIC initialization code. There are three main data structures for AVIC: * Virtual APIC (vAPIC) backing page (per-VCPU) * Physical APIC ID table (per-VM) * Logical APIC ID table (per-VM) Currently, AVIC is disabled by default. Users can manually enable AVIC via kernel boot option kvm-amd.avic=1 or during kvm-amd module loading with parameter avic=1. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> [Avoid extra indentation (Boris). - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 4 + arch/x86/include/asm/svm.h | 3 + arch/x86/kvm/svm.c | 225 +++++++++++++++++++++++++++++++++++++++- 3 files changed, 231 insertions(+), 1 deletion(-) commit 3d5615e5342781453633af7107d72afd601b36a7 Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:45 2016 -0500 svm: Introduce new AVIC VMCB registers Introduce new AVIC VMCB registers. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/svm.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit dd1a4cc1fbdf516bb38ca31b65c76e720d414d0d Author: Radim Krčmář <rkrcmar@redhat.com> Date: Wed May 4 14:09:44 2016 -0500 KVM: split kvm_vcpu_wake_up from kvm_vcpu_kick AVIC has a use for kvm_vcpu_wake_up. Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> Tested-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> include/linux/kvm_host.h | 1 + virt/kvm/kvm_main.c | 19 +++++++++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) commit d1ed092f77ef562edcc1b45ae331ff1683f50295 Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:43 2016 -0500 KVM: x86: Introducing kvm_x86_ops VCPU blocking/unblocking hooks Adding new function pointer in struct kvm_x86_ops, and calling them from the kvm_arch_vcpu[blocking/unblocking]. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit 03543133cea646406307870823343912c1ef0a3a Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:42 2016 -0500 KVM: x86: Introducing kvm_x86_ops VM init/destroy hooks Adding function pointers in struct kvm_x86_ops for processor-specific layer to provide hooks for when KVM initialize and destroy VM. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 3 +++ arch/x86/kvm/x86.c | 5 +++++ 2 files changed, 8 insertions(+) commit dfb9595429c65f72656551b9e1ad20126486badb Author: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Date: Wed May 4 14:09:41 2016 -0500 KVM: x86: Rename kvm_apic_get_reg to kvm_lapic_get_reg Rename kvm_apic_get_reg to kvm_lapic_get_reg to be consistent with the existing kvm_lapic_set_reg counterpart. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/ioapic.c | 2 +- arch/x86/kvm/lapic.c | 58 +++++++++++++++++++++++++-------------------------- arch/x86/kvm/lapic.h | 6 +++--- 3 files changed, 33 insertions(+), 33 deletions(-) commit 1e6e2755b635e85ce0b1ce827b7c375b6a0a890c Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Wed May 4 14:09:40 2016 -0500 KVM: x86: Misc LAPIC changes to expose helper functions Exporting LAPIC utility functions and macros for re-use in SVM code. Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Reviewed-by: Radim Krčmář <rkrcmar@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/lapic.c | 127 +++++++++++++++++++++------------------------------ arch/x86/kvm/lapic.h | 29 ++++++++++++ 2 files changed, 82 insertions(+), 74 deletions(-) commit 2086d3200dc9966c96a6c319a1214a94f00223f8 Author: Christian Borntraeger <borntraeger@de.ibm.com> Date: Tue May 17 10:49:22 2016 +0200 KVM: shrink halt polling even more for invalid wakeups commit 3491caf2755e ("KVM: halt_polling: provide a way to qualify wakeups during poll") added more aggressive shrinking of the polling interval if the wakeup did not match some criteria. This still allows to keep polling enabled if the polling time was smaller that the current max poll time (block_ns <= vcpu->halt_poll_ns). Performance measurement shows that even more aggressive shrinking (shrink polling on any invalid wakeup) reduces absolute and relative (to the workload) CPU usage even further. Cc: David Matlack <dmatlack@google.com> Cc: Wanpeng Li <kernellwp@gmail.com> Cc: Radim Krčmář <rkrcmar@redhat.com> CC: Paolo Bonzini <pbonzini@redhat.com> CC: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> virt/kvm/kvm_main.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 280dc0e145b2b04fd1b414e512118ce6eb9b93e8 Author: Jon Hunter <jonathanh@nvidia.com> Date: Wed May 18 16:37:36 2016 +0100 drm/tegra: Fix crash caused by reference count imbalance Commit d2307dea14a4 ("drm/atomic: use connector references (v3)") added reference counting for DRM connectors and this caused a crash when exercising system suspend on Tegra114 Dalmore. The Tegra DSI driver implements a Tegra specific function, tegra_dsi_connector_duplicate_state(), to duplicate the connector state and destroys the state using the generic helper function, drm_atomic_helper_connector_destroy_state(). Following commit d2307dea14a4 ("drm/atomic: use connector references (v3)") there is now an imbalance in the connector reference count because the Tegra function to duplicate state does not take a reference when duplicating the state information. However, the generic helper function to destroy the state information assumes a reference has been taken and during system suspend, when the connector state is destroyed, this leads to a crash because we attempt to put the reference for an object that has already been freed. Fix this by calling __drm_atomic_helper_connector_duplicate_state() from tegra_dsi_connector_duplicate_state() to ensure that we take a reference on a connector if crtc is set. Note that this will also copy the connector state a 2nd time, but this should be harmless. By fixing tegra_dsi_connector_duplicate_state() to take a reference, although a crash was no longer seen, it was then observed that after each system suspend-resume cycle, the reference would be one greater than before the suspend-resume cycle. Following commit d2307dea14a4 ("drm/atomic: use connector references (v3)"), it was found that we also need to put the reference when calling the function tegra_dsi_connector_reset() before freeing the state. Fix this by updating tegra_dsi_connector_reset() to call the function __drm_atomic_helper_connector_destroy_state() in order to put the reference for the connector. Fixes: d2307dea14a4 ("drm/atomic: use connector references (v3)") Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463585856-16606-1-git-send-email-jonathanh@nvidia.com drivers/gpu/drm/tegra/dsi.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit 8a6f71ccb6c39ca5ae442d1478d3a076e2b1361e Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 18 16:17:36 2016 +0200 ARM: exynos: don't select keyboard driver The samsung-keypad driver is implicitly selected by ARCH_EXYNOS4 (why?), but this fails if CONFIG_INPUT is a loadable module: drivers/input/built-in.o: In function `samsung_keypad_remove': drivers/input/keyboard/samsung-keypad.c:461: undefined reference to `input_unregister_device' drivers/input/built-in.o: In function `samsung_keypad_irq': drivers/input/keyboard/samsung-keypad.c:137: undefined reference to `input_event' drivers/input/built-in.o: In function `samsung_keypad_irq': include/linux/input.h:389: undefined reference to `input_event' drivers/input/built-in.o: In function `samsung_keypad_probe': drivers/input/keyboard/samsung-keypad.c:358: undefined reference to `devm_input_allocate_device' drivers/input/built-in.o:(.debug_addr+0x34): undefined reference to `input_set_capability' This removes the 'select' as suggested by Krzysztof Kozlowski and instead enables the driver from the defconfig files. The problem does not happen on mainline kernels, as we don't normally build built-in input drivers when CONFIG_INPUT=m, but I am experimenting with a patch to change this, and the samsung keypad driver showed up as one example that was silently broken before. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Link: https://lkml.org/lkml/2016/2/14/55 Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/configs/exynos_defconfig | 1 + arch/arm/configs/multi_v7_defconfig | 1 + arch/arm/mach-exynos/Kconfig | 1 - 3 files changed, 2 insertions(+), 1 deletion(-) commit 4cb54493ab2003568222e6ad7449747354f22ce3 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 12 10:38:31 2016 +0200 ARM: samsung: improve static dma_mask definition When no DMA master devices are part of the kernel configuration, we get a warning about the unused dma mask definition: arch/arm/plat-samsung/devs.c:71:12: error: 'samsung_device_dma_mask' defined but not used [-Werror=unused-variable] static u64 samsung_device_dma_mask = DMA_BIT_MASK(32); We could simply mark this as __maybe_unused to shut up that warning, but a nicer solution seems to be to have a separate mask for each device. The advantage is that a driver that happens to call dma_set_mask() on one device doesn't implicitly change the mask for the other devices as well. This is more of a theoretical problem, as obviously nothing does it for the devices in this file (or they would have always been broken), but it feels cleaner that way. The definition works by creating an array in place so we can take the address of it and let the compiler generate a hidden symbol for it at compile time. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/plat-samsung/devs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c16d2750a08c8ccaf98d65f287a8aec91bb9610d Author: Matan Barak <matanb@mellanox.com> Date: Sun Apr 17 17:08:41 2016 +0300 IB/mlx5: Fire the CQ completion handler from tasklet Previously, mlx5_ib_cq_comp was executed from interrupt context. Under heavy load, this could cause the CPU core to be in an interrupt context too long. Instead of executing the handler from the interrupt context we execute it from a much friendly tasklet context. Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx5/cq.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 94c6825e0ff75829207af6246782811b7c7af2c0 Author: Matan Barak <matanb@mellanox.com> Date: Sun Apr 17 17:08:40 2016 +0300 net/mlx5_core: Use tasklet for user-space CQ completion events Previously, we've fired all our completion callbacks straight from our ISR. Some of those callbacks were lightweight (for example, mlx5 Ethernet napi callbacks), but some of them did more work (for example, the user-space RDMA stack uverbs' completion handler). Besides that, doing more than the minimal work in ISR is generally considered wrong, it could even lead to a hard lockup of the system. Since when a lot of completion events are generated by the hardware, the loop over those events could be so long, that we'll get into a hard lockup by the system watchdog. In order to avoid that, add a new way of invoking completion events callbacks. In the interrupt itself, we add the CQs which receive completion event to a per-EQ list and schedule a tasklet. In the tasklet context we loop over all the CQs in the list and invoke the user callback. Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/net/ethernet/mellanox/mlx5/core/cq.c | 59 ++++++++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/eq.c | 12 ++++- drivers/net/ethernet/mellanox/mlx5/core/main.c | 17 +++++++ .../net/ethernet/mellanox/mlx5/core/mlx5_core.h | 2 + include/linux/mlx5/cq.h | 5 ++ include/linux/mlx5/driver.h | 10 ++++ 6 files changed, 104 insertions(+), 1 deletion(-) commit 17e1717c11a34f9b0956e33e0c4a4e4ae8c51a57 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Wed May 18 22:27:43 2016 +0900 ALSA: firewire-lib: change a member of event structure to suppress sparse wanings to bool type Commit a9c4284bf5a9 ("ALSA: firewire-lib: add context information to tracepoints") adds new members to tracepoint events of this module, to represent context information. One of the members is bool type and this causes sparse warnings. 16:1: warning: expression using sizeof bool 60:1: warning: expression using sizeof bool 16:1: warning: odd constant _Bool cast (ffffffffffffffff becomes 1) 60:1: warning: odd constant _Bool cast (ffffffffffffffff becomes 1) This commit suppresses the warnings, by changing type of the member to 'unsigned int'. Additionally, this commit applies '!!' idiom to get 0/1 from 'in_interrupt()'. Fixes: a9c4284bf5a9 ("ALSA: firewire-lib: add context information to tracepoints") Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream-trace.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e3b6d8cf8de6d07af9a27c86861edfa5b3290cb6 Author: Christoph Lameter <cl@linux.com> Date: Fri May 13 10:52:26 2016 -0500 IB/core: Do not require CAP_NET_ADMIN for packet sniffing In the Ethernet/TCP world, CAP_NET_RAW is sufficient to allow a program to listen to all incoming packets on a specific interface, and the higher CAP_NET_ADMIN is required to set the interface into promiscuous mode. We want to emulate that same basic division of privilege in the RDMA stack, so when dealing with Raw Ethernet QPs, allow apps with CAP_NET_RAW to listen to all incoming flows (and direct them as they see fit in their own listen stream). Do not require CAP_NET_ADMIN just to listen to traffic already incoming. Reserve CAP_NET_ADMIN if we attempt to set promiscuous mode. Signed-off-by: Christoph Lameter <cl@linux.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/uverbs_cmd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 04ef0f1a0169a14b8e653af1178524ab4390133f Author: shamir rabinovitch <shamir.rabinovitch@oracle.com> Date: Wed May 18 06:18:10 2016 -0400 IB/mlx4: Fix unaligned access in send_reply_to_slave The problem is that the function 'send_reply_to_slave' gets the 'req_sa_mad' as a pointer whose address is only aliged to 4 bytes but is 8 bytes in size. This can result in unaligned access faults on certain architectures. Sowmini Varadhan pointed to this reply from Dave Miller that say that memcpy should not be used to solve alignment issues: https://lkml.org/lkml/2015/10/21/352 Optimization of memcpy to 'ldx' instruction can only happen if the compiler knows that the size of the data we are copying is 8 bytes and it assumes it is aligned to 8 bytes. If the compiler know the type is not aligned to 8 it must not optimize the 8 byte copy. Defining the data type as aligned to 4 forces the compiler to treat all accesses as though they aren't aligned and avoids the 'ldx' optimization. Full credit for the idea goes to Jason Gunthorpe <jgunthorpe@obsidianresearch.com>. Signed-off-by: Shamir Rabinovitch <shamir.rabinovitch@oracle.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx4/mcg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ef3f00a4d38e01ec0e7ad1b1c8edc2f5667aaa32 Author: Jiri Olsa <jolsa@redhat.com> Date: Wed May 18 08:16:10 2016 +0200 perf/x86/intel/uncore: Remove WARN_ON_ONCE in uncore_pci_probe When booting with nr_cpus=1, uncore_pci_probe tries to init the PCI/uncore also for the other packages and fails with warning when they are not found. The warning is bogus because it's correct to fail here for packages which are not initialized. Remove it and return silently. Fixes: cf6d445f6897 "perf/x86/uncore: Track packages, not per CPU data" Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: stable@vger.kernel.org Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> arch/x86/events/intel/uncore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3b59c344ab6e2d00b0f4ad946024572618c87502 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri May 13 17:07:59 2016 -0400 drm/amd/powerplay: fix bugs of checking if dpm is running on Tonga Fixes OD failures on Tonga. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit b9934878fdbabd7eea5dbc953b66d74decdf5fbd Author: Flora Cui <Flora.Cui@amd.com> Date: Tue May 17 09:52:22 2016 +0800 drm/amdgpu: update Polaris11 golden setting Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 5 +++-- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 ++ 3 files changed, 6 insertions(+), 3 deletions(-) commit 35621b80085b371d1e9bb9b6de58bf173d12f31e Author: Flora Cui <Flora.Cui@amd.com> Date: Tue May 17 09:52:02 2016 +0800 drm/amdgpu: Add more Polaris 11 PCI IDs Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit d4ab989fc39897e9b6b24c4c5dd0eea288daee7e Author: Flora Cui <Flora.Cui@amd.com> Date: Mon May 16 17:18:17 2016 +0800 drm/amdgpu: update Polaris10 golden setting Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) commit 1dcf480167cdba271df73a48460d60ad0f5e3845 Author: Flora Cui <Flora.Cui@amd.com> Date: Mon May 16 17:17:41 2016 +0800 drm/amdgpu: add more Polaris10 DID Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 2f46b2a5c74c35f785c10fe910621662e3188682 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Tue May 17 15:12:47 2016 +0530 drm/amd/amdgpu : Remove unused variable Remove unused variable 'ret', and directly return 0. Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/tonga_ih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit a280a42aa351bab5eaf8e253f172487a6785f62e Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Tue May 17 15:12:46 2016 +0530 drm/amd/amdgpu : Remove unused variable Remove unused variable 'ret', and directly return 0. Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/iceland_ih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 0e2b854ed4ce764e7de781901b49aedd3f7a3dfa Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Tue May 17 15:12:45 2016 +0530 drm/amd/amdgpu : Remove unused variable Remove unused variable 'ret', and directly return 0. Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/cz_ih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit d05f2c7aeb5ec6ef6066992517d4a9af40729913 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Tue May 17 15:12:44 2016 +0530 drm/amd/amdgpu/cz_dpm: Remove unused variable Remove unused variable 'ret' from functions where it was not used anyway, and directly return 0. Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/cz_dpm.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 734711b71d3339045141a7e934f1c53d98ad0b98 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Tue May 17 15:12:43 2016 +0530 drm/amd/amdgpu : Remove unused variable Remove unused variable 'ret', and directly return 0. Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/cik_ih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit fdf2c85f26a656df3c9ef2114ff508a4be26bbff Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri May 6 14:55:02 2016 +0200 drm: Fix error handling in drm_connector_register When debugfs or sysfs registration failed, we failed to clean up the idr registration. Reorder to fix this. Cc: Dave Airlie <airlied@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462539302-27764-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_crtc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e2d800a3ce1b16a9c25fc6ca91f26df5509ca11d Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri May 6 12:47:45 2016 +0100 drm: Avoid connector reference imbalance on error path Whilst looking at the fallout from using connector references for atomic, I noticed that there is an early return buried in drm_atomic_set_crtc_for_connector() that if hit could cause us to leak a reference on the connector. Fixes: d2307dea14 (drm/atomic: use connector references (v3)) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Stone <daniels@collabora.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462535265-13058-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/drm_atomic.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit 88ac99063e6e38bf9577e75f0d65dd02e2326d58 Merge: 191b075 5af897e 431c30f Author: Zhang Rui <rui.zhang@intel.com> Date: Wed May 18 15:37:08 2016 +0800 Merge branches 'thermal-core', 'thermal-intel' and 'thermal-soc' into next commit b52207ef4ea56f8c22288ec3387399aac72c26cf Author: Chen Feng <puck.chen@hisilicon.com> Date: Sun Feb 14 14:29:21 2016 +0800 mfd: hi655x: Add MFD driver for hi655x Add PMIC MFD driver to support hisilicon hi665x. Signed-off-by: Chen Feng <puck.chen@hisilicon.com> Signed-off-by: Fei Wang <w.f@huawei.com> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Reviewed-by: Haojian Zhuang <haojian.zhuang@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/Kconfig | 10 +++ drivers/mfd/Makefile | 1 + drivers/mfd/hi655x-pmic.c | 162 ++++++++++++++++++++++++++++++++++++++++ include/linux/mfd/hi655x-pmic.h | 55 ++++++++++++++ 4 files changed, 228 insertions(+) commit 776d7f1694a7d678291354a05f0243965708306a Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Mon May 16 12:57:43 2016 +0300 arc: axs103_smp: Fix CPU frequency to 100MHz for dual-core The most recent release of AXS103 [v1.1] is proven to work at 100 MHz in dual-core mode so this change uses mentioned feature. For that we: * Update axc003_idu.dtsi with mention of really-used CPU clock freq * Remove clock override in AXS platform code for dual-core HW Note we're still leaving a hack for clock "downgrade" on early boot for quad-core hardware. Also note this change will break functionality of AXS103 v1.0 hardware. That means all users of AXS103 __must__ upgrade their boards with the most recent firmware. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/boot/dts/axc003_idu.dtsi | 2 +- arch/arc/plat-axs10x/axs10x.c | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) commit ad438c4038968e5ca5248f851212634e474983e8 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:20:08 2016 +1000 xfs: move reclaim tagging functions Rearrange the inode tagging functions so that they are higher up in xfs_cache.c and so there is no need for forward prototypes to be defined. This is purely code movement, no other change. Signed-off-by: Dave Chinner <dchinner@redhat.com> fs/xfs/xfs_icache.c | 234 ++++++++++++++++++++++++++-------------------------- 1 file changed, 116 insertions(+), 118 deletions(-) commit 545c0889d26d47e1139c527002eb131343d13b63 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:11:41 2016 +1000 xfs: simplify inode reclaim tagging interfaces Inode radix tree tagging for reclaim passes a lot of unnecessary variables around. Over time the xfs-perag has grown a xfs_mount backpointer, and an internal agno so we don't need to pass other variables into the tagging functions to supply this information. Rework the functions to pass the minimal variable set required and simplify the internal logic and flow. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_icache.c | 98 +++++++++++++++++++++++++++-------------------------- 1 file changed, 50 insertions(+), 48 deletions(-) commit 194293631d009254348f43710a7673bbb84a4172 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:09:46 2016 +1000 xfs: rename variables in xfs_iflush_cluster for clarity The cluster inode variable uses unconventional naming - iq - which makes it hard to distinguish it between the inode passed into the function - ip - and that is a vector for mistakes to be made. Rename all the cluster inode variables to use a more conventional prefixes to reduce potential future confusion (cilist, cilist_size, cip). Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 74 +++++++++++++++++++++++++++--------------------------- 1 file changed, 37 insertions(+), 37 deletions(-) commit 5a90e53e8124d3ebe4b2a6309fa3c3225c23a62a Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:09:13 2016 +1000 xfs: xfs_iflush_cluster has range issues xfs_iflush_cluster() does a gang lookup on the radix tree, meaning it can find inodes beyond the current cluster if there is sparse cache population. gang lookups return results in ascending index order, so stop trying to cluster inodes once the first inode outside the cluster mask is detected. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 8a17d7ddedb4d9031f046ae0e97c40b46aa69db5 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:09:12 2016 +1000 xfs: mark reclaimed inodes invalid earlier The last thing we do before using call_rcu() on an xfs_inode to be freed is mark it as invalid. This means there is a window between when we know for certain that the inode is going to be freed and when we do actually mark it as "freed". This is important in the context of RCU lookups - we can look up the inode, find that it is valid, and then use it as such not realising that it is in the final stages of being freed. As such, mark the inode as being invalid the moment we know it is going to be reclaimed. This can be done while we still hold the XFS_ILOCK_EXCL and the flush lock in xfs_inode_reclaim, meaning that it occurs well before we remove it from the radix tree, and that the i_flags_lock, the XFS_ILOCK and the inode flush lock all act as synchronisation points for detecting that an inode is about to go away. For defensive purposes, this allows us to add a further check to xfs_iflush_cluster to ensure we skip inodes that are being freed after we grab the XFS_ILOCK_SHARED and the flush lock - we know that if the inode number if valid while we have these locks held we know that it has not progressed through reclaim to the point where it is clean and is about to be freed. [bfoster: fixed __xfs_inode_clear_reclaim() using ip->i_ino after it had already been zeroed.] Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_icache.c | 46 ++++++++++++++++++++++++++++++++++------------ fs/xfs/xfs_inode.c | 13 +++++++++++++ 2 files changed, 47 insertions(+), 12 deletions(-) commit 1f2dcfe89edac4e3bf5b76c56f745191f921fd2a Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 14:01:53 2016 +1000 xfs: xfs_inode_free() isn't RCU safe The xfs_inode freed in xfs_inode_free() has multiple allocated structures attached to it. We free these in xfs_inode_free() before we mark the inode as invalid, and before we run call_rcu() to queue the structure for freeing. Unfortunately, this freeing can race with other accesses that are in the RCU current grace period that have found the inode in the radix tree with a valid state. This includes xfs_iflush_cluster(), which calls xfs_inode_clean(), and that accesses the inode log item on the xfs_inode. The log item structure is freed in xfs_inode_free(), so there is the possibility we can be accessing freed memory in xfs_iflush_cluster() after validating the xfs_inode structure as being valid for this RCU context. Hence we can get spuriously incorrect clean state returned from such checks. This can lead to use thinking the inode is dirty when it is, in fact, clean, and so incorrectly attaching it to the buffer for IO and completion processing. This then leads to use-after-free situations on the xfs_inode itself if the IO completes after the current RCU grace period expires. The buffer callbacks will access the xfs_inode and try to do all sorts of things it shouldn't with freed memory. IOWs, xfs_iflush_cluster() only works correctly when racing with inode reclaim if the inode log item is present and correctly stating the inode is clean. If the inode is being freed, then reclaim has already made sure the inode is clean, and hence xfs_iflush_cluster can skip it. However, we are accessing the inode inode under RCU read lock protection and so also must ensure that all dynamically allocated memory we reference in this context is not freed until the RCU grace period expires. To fix this, move all the potential memory freeing into xfs_inode_free_callback() so that we are guarantee RCU protected lookup code will always have the memory structures it needs available during the RCU grace period that lookup races can occur in. Discovered-by: Brain Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_icache.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 32b43ab6fb983e5a117048443e628c235cd2c5bd Author: Alex Lyakas <alex@zadarastorage.com> Date: Wed May 18 14:01:52 2016 +1000 xfs: optimise xfs_iext_destroy When unmounting XFS, we call: xfs_inode_free => xfs_idestroy_fork => xfs_iext_destroy This goes over the whole indirection array and calls xfs_iext_irec_remove for each one of the erps (from the last one to the first one). As a result, we keep shrinking (reallocating actually) the indirection array until we shrink out all of its elements. When we have files with huge numbers of extents, umount takes 30-80 sec, depending on the amount of files that XFS loaded and the amount of indirection entries of each file. The unmount stack looks like: [<ffffffffc0b6d200>] xfs_iext_realloc_indirect+0x40/0x60 [xfs] [<ffffffffc0b6cd8e>] xfs_iext_irec_remove+0xee/0xf0 [xfs] [<ffffffffc0b6cdcd>] xfs_iext_destroy+0x3d/0xb0 [xfs] [<ffffffffc0b6cef6>] xfs_idestroy_fork+0xb6/0xf0 [xfs] [<ffffffffc0b87002>] xfs_inode_free+0xb2/0xc0 [xfs] [<ffffffffc0b87260>] xfs_reclaim_inode+0x250/0x340 [xfs] [<ffffffffc0b87583>] xfs_reclaim_inodes_ag+0x233/0x370 [xfs] [<ffffffffc0b8823d>] xfs_reclaim_inodes+0x1d/0x20 [xfs] [<ffffffffc0b96feb>] xfs_unmountfs+0x7b/0x1a0 [xfs] [<ffffffffc0b98e4d>] xfs_fs_put_super+0x2d/0x70 [xfs] [<ffffffff811e9e36>] generic_shutdown_super+0x76/0x100 [<ffffffff811ea207>] kill_block_super+0x27/0x70 [<ffffffff811ea519>] deactivate_locked_super+0x49/0x60 [<ffffffff811eaaee>] deactivate_super+0x4e/0x70 [<ffffffff81207593>] cleanup_mnt+0x43/0x90 [<ffffffff81207632>] __cleanup_mnt+0x12/0x20 [<ffffffff8108f8e7>] task_work_run+0xa7/0xe0 [<ffffffff81014ff7>] do_notify_resume+0x97/0xb0 [<ffffffff81717c6f>] int_signal+0x12/0x17 Further, this reallocation prevents us from freeing the extent list from a RCU callback as allocation can block. Hence if the extent list is in indirect format, optimise the freeing of the extent list to only use kmem_free calls by freeing entire extent buffer pages at a time, rather than extent by extent. [dchinner: simplified freeing loop based on Christoph's suggestion] Signed-off-by: Alex Lyakas <alex@zadarastorage.com> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/libxfs/xfs_inode_fork.c | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) commit 7d3aa7fe970791f1a674b14572a411accf2f4d4e Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 13:54:23 2016 +1000 xfs: skip stale inodes in xfs_iflush_cluster We don't write back stale inodes so we should skip them in xfs_iflush_cluster, too. cc: <stable@vger.kernel.org> # 3.10.x- Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 1 + 1 file changed, 1 insertion(+) commit 51b07f30a71c27405259a0248206ed4e22adbee2 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 13:54:22 2016 +1000 xfs: fix inode validity check in xfs_iflush_cluster Some careless idiot(*) wrote crap code in commit 1a3e8f3 ("xfs: convert inode cache lookups to use RCU locking") back in late 2010, and so xfs_iflush_cluster checks the wrong inode for whether it is still valid under RCU protection. Fix it to lock and check the correct inode. (*) Careless-idiot: Dave Chinner <dchinner@redhat.com> cc: <stable@vger.kernel.org> # 3.10.x- Discovered-by: Brain Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit b1438f477934f5a4d5a44df26f3079a7575d5946 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 13:53:42 2016 +1000 xfs: xfs_iflush_cluster fails to abort on error When a failure due to an inode buffer occurs, the error handling fails to abort the inode writeback correctly. This can result in the inode being reclaimed whilst still in the AIL, leading to use-after-free situations as well as filesystems that cannot be unmounted as the inode log items left in the AIL never get removed. Fix this by ensuring fatal errors from xfs_imap_to_bp() result in the inode flush being aborted correctly. cc: <stable@vger.kernel.org> # 3.10.x- Reported-by: Shyam Kaushik <shyam@zadarastorage.com> Diagnosed-by: Shyam Kaushik <shyam@zadarastorage.com> Tested-by: Shyam Kaushik <shyam@zadarastorage.com> Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit 8179c03629de67f515d3ab825b5a9428687d4b85 Author: Dave Chinner <dchinner@redhat.com> Date: Wed May 18 13:52:42 2016 +1000 xfs: remove xfs_fs_evict_inode() Joe Lawrence reported a list_add corruption with 4.6-rc1 when testing some custom md administration code that made it's own block device nodes for the md array. The simple test loop of: for i in {0..100}; do mknod --mode=0600 $tmp/tmp_node b $MAJOR $MINOR mdadm --detail --export $tmp/tmp_node > /dev/null rm -f $tmp/tmp_node done Would produce this warning in bd_acquire() when mdadm opened the device node: list_add double add: new=ffff88043831c7b8, prev=ffff8804380287d8, next=ffff88043831c7b8. And then produce this from bd_forget from kdevtmpfs evicting a block dev inode: list_del corruption. prev->next should be ffff8800bb83eb10, but was ffff88043831c7b8 This is a regression caused by commit c19b3b05 ("xfs: mode di_mode to vfs inode"). The issue is that xfs_inactive() frees the unlinked inode, and the above commit meant that this freeing zeroed the mode in the struct inode. The problem is that after evict() has called ->evict_inode, it expects the i_mode to be intact so that it can call bd_forget() or cd_forget() to drop the reference to the block device inode attached to the XFS inode. In reality, the only thing we do in xfs_fs_evict_inode() that is not generic is call xfs_inactive(). We can move the xfs_inactive() call to xfs_fs_destroy_inode() without any problems at all, and this will leave the VFS inode intact until it is completely done with it. So, remove xfs_fs_evict_inode(), and do the work it used to do in ->destroy_inode instead. cc: <stable@vger.kernel.org> # 4.6 Reported-by: Joe Lawrence <joe.lawrence@stratus.com> Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_super.c | 28 +++++++--------------------- 1 file changed, 7 insertions(+), 21 deletions(-) commit ebe24cea95ab969f76f2922032f6c390fdc816f2 Author: Marek Lindner <mareklindner@neomailbox.ch> Date: Sat May 7 19:54:17 2016 +0800 batman-adv: initialize ELP orig address on secondary interfaces This fix prevents nodes to wrongly create a 00:00:00:00:00:00 originator which can potentially interfere with the rest of the neighbor statistics. Fixes: d6f94d91f766 ("batman-adv: ELP - adding basic infrastructure") Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v.c | 10 ++++++++++ net/batman-adv/bat_v_elp.c | 31 ++++++++++++++++++++++--------- net/batman-adv/bat_v_elp.h | 2 ++ 3 files changed, 34 insertions(+), 9 deletions(-) commit e123705e58bf171be8c6eb0902ebfb5d6ed255ad Author: Linus Lüssing <linus.luessing@c0d3.blue> Date: Thu Jan 7 08:11:12 2016 +0100 batman-adv: Avoid duplicate neigh_node additions Two parallel calls to batadv_neigh_node_new() might race for creating and adding the same neig_node. Fix this by including the check for any already existing, identical neigh_node within the spin-lock. This fixes splats like the following: [ 739.535069] ------------[ cut here ]------------ [ 739.535079] WARNING: CPU: 0 PID: 0 at /usr/src/batman-adv/git/batman-adv/net/batman-adv/bat_iv_ogm.c:1004 batadv_iv_ogm_process_per_outif+0xe3f/0xe60 [batman_adv]() [ 739.535092] too many matching neigh_nodes [ 739.535094] Modules linked in: dm_mod tun ip6table_filter ip6table_mangle ip6table_nat nf_nat_ipv6 ip6_tables xt_nat iptable_nat nf_nat_ipv4 nf_nat xt_TCPMSS xt_mark iptable_mangle xt_tcpudp xt_conntrack iptable_filter ip_tables x_tables ip_gre ip_tunnel gre bridge stp llc thermal_sys kvm_intel kvm crct10dif_pclmul crc32_pclmul sha256_ssse3 sha256_generic hmac drbg ansi_cprng aesni_intel aes_x86_64 lrw gf128mul glue_helper ablk_helper cryptd evdev pcspkr ip6_gre ip6_tunnel tunnel6 batman_adv(O) libcrc32c nf_conntrack_ipv6 nf_defrag_ipv6 nf_conntrack_ipv4 nf_defrag_ipv4 nf_conntrack autofs4 ext4 crc16 mbcache jbd2 xen_netfront xen_blkfront crc32c_intel [ 739.535177] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G W O 4.2.0-0.bpo.1-amd64 #1 Debian 4.2.6-3~bpo8+2 [ 739.535186] 0000000000000000 ffffffffa013b050 ffffffff81554521 ffff88007d003c18 [ 739.535201] ffffffff8106fa01 0000000000000000 ffff8800047a087a ffff880079c3a000 [ 739.735602] ffff88007b82bf40 ffff88007bc2d1c0 ffffffff8106fa7a ffffffffa013aa8e [ 739.735624] Call Trace: [ 739.735639] <IRQ> [<ffffffff81554521>] ? dump_stack+0x40/0x50 [ 739.735677] [<ffffffff8106fa01>] ? warn_slowpath_common+0x81/0xb0 [ 739.735692] [<ffffffff8106fa7a>] ? warn_slowpath_fmt+0x4a/0x50 [ 739.735715] [<ffffffffa012448f>] ? batadv_iv_ogm_process_per_outif+0xe3f/0xe60 [batman_adv] [ 739.735740] [<ffffffffa0124813>] ? batadv_iv_ogm_receive+0x363/0x380 [batman_adv] [ 739.735762] [<ffffffffa0124813>] ? batadv_iv_ogm_receive+0x363/0x380 [batman_adv] [ 739.735783] [<ffffffff810b0841>] ? __raw_callee_save___pv_queued_spin_unlock+0x11/0x20 [ 739.735804] [<ffffffffa012cb39>] ? batadv_batman_skb_recv+0xc9/0x110 [batman_adv] [ 739.735825] [<ffffffff81464891>] ? __netif_receive_skb_core+0x841/0x9a0 [ 739.735838] [<ffffffff810b0841>] ? __raw_callee_save___pv_queued_spin_unlock+0x11/0x20 [ 739.735853] [<ffffffff81465681>] ? process_backlog+0xa1/0x140 [ 739.735864] [<ffffffff81464f1a>] ? net_rx_action+0x20a/0x320 [ 739.735878] [<ffffffff81073aa7>] ? __do_softirq+0x107/0x270 [ 739.735891] [<ffffffff81073d82>] ? irq_exit+0x92/0xa0 [ 739.735905] [<ffffffff8137e0d1>] ? xen_evtchn_do_upcall+0x31/0x40 [ 739.735924] [<ffffffff8155b8fe>] ? xen_do_hypervisor_callback+0x1e/0x40 [ 739.735939] <EOI> [<ffffffff810013aa>] ? xen_hypercall_sched_op+0xa/0x20 [ 739.735965] [<ffffffff810013aa>] ? xen_hypercall_sched_op+0xa/0x20 [ 739.735979] [<ffffffff8100a39c>] ? xen_safe_halt+0xc/0x20 [ 739.735991] [<ffffffff8101da6c>] ? default_idle+0x1c/0xa0 [ 739.736004] [<ffffffff810abf6b>] ? cpu_startup_entry+0x2eb/0x350 [ 739.736019] [<ffffffff81b2af5e>] ? start_kernel+0x480/0x48b [ 739.736032] [<ffffffff81b2d116>] ? xen_start_kernel+0x507/0x511 [ 739.736048] ---[ end trace c106bb901244bc8c ]--- Fixes: f987ed6ebd99 ("batman-adv: protect neighbor list with rcu locks") Reported-by: Martin Weinelt <martin@darmstadt.freifunk.net> Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/originator.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit d285f52cc0f23564fd61976d43fd5b991b4828f6 Author: Sven Eckelmann <sven.eckelmann@open-mesh.com> Date: Tue Feb 16 10:47:07 2016 +0100 batman-adv: Fix integer overflow in batadv_iv_ogm_calc_tq The undefined behavior sanatizer detected an signed integer overflow in a setup with near perfect link quality UBSAN: Undefined behaviour in net/batman-adv/bat_iv_ogm.c:1246:25 signed integer overflow: 8713350 * 255 cannot be represented in type 'int' The problems happens because the calculation of mixed unsigned and signed integers resulted in an integer multiplication. batadv_ogm_packet::tq (u8 255) * tq_own (u8 255) * tq_asym_penalty (int 134; max 255) * tq_iface_penalty (int 255; max 255) The tq_iface_penalty, tq_asym_penalty and inv_asym_penalty can just be changed to unsigned int because they are not expected to become negative. Fixes: c039876892e3 ("batman-adv: add WiFi penalty") Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 1653f61d656516aae7130db19561258a847d1e94 Author: Antonio Quartulli <a@unstable.cc> Date: Mon May 2 01:14:40 2016 +0800 batman-adv: make sure ELP/OGM orig MAC is updated on address change When the MAC address of the primary interface is changed, update the originator address in the ELP and OGM skb buffers as well in order to reflect the change. Fixes: d6f94d91f766 ("batman-adv: ELP - adding basic infrastructure") Reported-by: Marek Lindner <marek@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v.c | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) commit f7dcdf5fdbe8fec7670d8f65a5db595c98e0ecab Author: Sven Eckelmann <sven@narfation.org> Date: Mon Feb 22 22:56:33 2016 +0100 batman-adv: Fix unexpected free of bcast_own on add_if error The function batadv_iv_ogm_orig_add_if allocates new buffers for bcast_own and bcast_own_sum. It is expected that these buffers are unchanged in case either bcast_own or bcast_own_sum couldn't be resized. But the error handling of this function frees the already resized buffer for bcast_own when the allocation of the new bcast_own_sum buffer failed. This will lead to an invalid memory access when some code will try to access bcast_own. Instead the resized new bcast_own buffer has to be kept. This will not lead to problems because the size of the buffer was only increased and therefore no user of the buffer will try to access bytes outside of the new buffer. Fixes: d0015fdd3d2c ("batman-adv: provide orig_node routing API") Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 71f9d27daa2cbcca7159c27f0c0c381cc2dd1053 Author: Sven Eckelmann <sven@narfation.org> Date: Fri May 6 11:43:39 2016 +0200 batman-adv: Fix refcnt leak in batadv_v_neigh_* The functions batadv_neigh_ifinfo_get increase the reference counter of the batadv_neigh_ifinfo. These have to be reduced again when the reference is not used anymore to correctly free the objects. Fixes: 9786906022eb ("batman-adv: B.A.T.M.A.N. V - implement neighbor comparison API calls") Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v.c | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) commit a45e932a3c58eac11a7458c6888910e23f615077 Author: Sven Eckelmann <sven@narfation.org> Date: Fri May 6 11:43:38 2016 +0200 batman-adv: Avoid nullptr derefence in batadv_v_neigh_is_sob batadv_neigh_ifinfo_get can return NULL when it cannot find (even when only temporarily) anymore the neigh_ifinfo in the list neigh->ifinfo_list. This has to be checked to avoid kernel Oopses when the ifinfo is dereferenced. This a situation which isn't expected but is already handled by functions like batadv_v_neigh_cmp. The same kind of warning is therefore used before the function returns without dereferencing the pointers. Fixes: 9786906022eb ("batman-adv: B.A.T.M.A.N. V - implement neighbor comparison API calls") Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v.c | 4 ++++ 1 file changed, 4 insertions(+) commit 63d443efe8be2c1d02b30d7e4edeb9aa085352b3 Author: Florian Westphal <fw@strlen.de> Date: Tue May 10 23:17:59 2016 +0200 batman-adv: fix skb deref after free batadv_send_skb_to_orig() calls dev_queue_xmit() so we can't use skb->len. Fixes: 953324776d6d ("batman-adv: network coding - buffer unicast packets before forward") Signed-off-by: Florian Westphal <fw@strlen.de> Reviewed-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/routing.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e7ca7f9fa2cda220ba807620c992ce77c33a32ea Merge: 5f0dfb7 d65c8ff Author: James Bottomley <James.Bottomley@HansenPartnership.com> Date: Tue May 17 21:12:50 2016 -0400 Merge branch 'fixes' into misc commit e6b3bb78962e65c4ad125598755cfbf2a8779e86 Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:11:27 2016 +1000 xfs: add "fail at unmount" error handling configuration If we take "retry forever" literally on metadata IO errors, we can hang at unmount, once it retries those writes forever. This is the default behavior, unfortunately. Add an error configuration option for this behavior and default it to "fail" so that an unmount will trigger actuall errors, a shutdown and allow the unmount to succeed. It will be noisy, though, as it will log the errors and shutdown that occurs. To fix this, we need to mark the filesystem as being in the process of unmounting. Do this with a mount flag that is added at the appropriate time (i.e. before the blocking AIL sync). We also need to add this flag if mount fails after the initial phase of log recovery has been run. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_buf_item.c | 4 ++++ fs/xfs/xfs_mount.c | 12 ++++++++++++ fs/xfs/xfs_mount.h | 2 ++ fs/xfs/xfs_sysfs.c | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 64 insertions(+) commit e0a431b3a3cc3d0a4c38ccfca8c7320fde40efb6 Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:09:28 2016 +1000 xfs: add configuration handlers for specific errors now most of the infrastructure is in place, we can start adding support for configuring specific errors such as ENODEV, ENOSPC, EIO, etc. Add these error configurations and configure them all to have appropriate behaviours. That is, all will be configured to retry forever by default, except for ENODEV, which is an unrecoverable error, so it will be configured to not retry on error Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_mount.h | 3 +++ fs/xfs/xfs_sysfs.c | 22 +++++++++++++++++++++- 2 files changed, 24 insertions(+), 1 deletion(-) commit a5ea70d25d76950e11690110b526374307d05d81 Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:08:15 2016 +1000 xfs: add configuration of error failure speed On reception of an error, we can fail immediately, perform some bound amount of retries or retry indefinitely. The current behaviour we have is to retry forever. However, we'd like the ability to choose how long the filesystem should try after an error, it can either fail immediately, retry a few times, or retry forever. This is implemented by using max_retries sysfs attribute, to hold the amount of times we allow the filesystem to retry after an error. Being -1 a special case where the filesystem will retry indefinitely. Add both a maximum retry count and a retry timeout so that we can bound by time and/or physical IO attempts. Finally, plumb these into xfs_buf_iodone error processing so that the error behaviour follows the selected configuration. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_buf.h | 21 ++++++++++++- fs/xfs/xfs_buf_item.c | 13 +++++++-- fs/xfs/xfs_mount.h | 3 ++ fs/xfs/xfs_sysfs.c | 81 ++++++++++++++++++++++++++++++++++++++++++++++++--- 4 files changed, 111 insertions(+), 7 deletions(-) commit ef6a50fbb1bba7951aa23adcfb40e99ca72dc51c Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:06:44 2016 +1000 xfs: introduce table-based init for error behaviors Before we start expanding the number of error classes and errors we can configure behaviour for, we need a simple and clear way to define the default behaviour that we initialized each mount with. Introduce a table based method for keeping the initial configuration in, and apply that to the existing initialization code. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_sysfs.c | 72 +++++++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 60 insertions(+), 12 deletions(-) commit df3093907ccc718459c54c99da29dd774af41186 Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:05:33 2016 +1000 xfs: add configurable error support to metadata buffers With the error configuration handle for async metadata write errors in place, we can now add initial support to the IO error processing in xfs_buf_iodone_error(). Add an infrastructure function to look up the configuration handle, and rearrange the error handling to prepare the way for different error handling conigurations to be used. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_buf.h | 1 + fs/xfs/xfs_buf_item.c | 112 ++++++++++++++++++++++++++++++-------------------- fs/xfs/xfs_mount.h | 3 ++ fs/xfs/xfs_sysfs.c | 17 ++++++++ fs/xfs/xfs_trace.h | 1 - 5 files changed, 88 insertions(+), 46 deletions(-) commit ffd40ef697dfd3e06f44b1bb5fea93079de8c77d Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 11:01:00 2016 +1000 xfs: introduce metadata IO error class Now we have the basic infrastructure, add the first error class so we can build up the infrastructure in a meaningful way. Add the metadata async write IO error class and sysfs entry, and introduce a default configuration that matches the existing "retry forever" behavior for async write metadata buffers. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_mount.h | 3 +++ fs/xfs/xfs_sysfs.c | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+) commit 0b7962a6c4a37ef3cbb25d976af7b9ec4ce8ad01 Merge: 6f88b5b f8d1a93 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 18:00:39 2016 -0700 Merge branch 'for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata Pull libata updates from Tejun Heo: "Trivial changes except for special case timeout bumping. I have two more libata branches which depend on SCSI and dmaengine tree respectively. I'll send pull requests for them once the prerequisite trees are pulled in" * 'for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata: libata-scsi: use %*ph to dump small buffers treewide: Fix typos in libata.xml libata-core: Allow longer timeout for drive spinup from PUIS libata: Fixup awkward whitespace in warning by removing line continuation. commit 192852be8b5fb14268c2133fe9ce5312e4745963 Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed May 18 10:58:51 2016 +1000 xfs: configurable error behavior via sysfs We need to be able to change the way XFS behaviours in error conditions depending on the type of underlying storage. This is necessary for handling non-traditional block devices with extended error cases, such as thin provisioned devices that can return ENOSPC as an IO error. Introduce the basic sysfs infrastructure needed to define and configure error behaviours. This is done to be generic enough to extend to configuring behaviour in other error conditions, such as ENOMEM, which also has different desired behaviours according to machine configuration. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_mount.c | 10 +++++++++- fs/xfs/xfs_mount.h | 20 ++++++++++++++++++++ fs/xfs/xfs_sysfs.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++- fs/xfs/xfs_sysfs.h | 3 +++ 4 files changed, 84 insertions(+), 2 deletions(-) commit 9bdd9bd69b826875531bb1b2efb6aeb8d70e6f72 Author: Brian Foster <bfoster@redhat.com> Date: Wed May 18 10:56:41 2016 +1000 xfs: buffer ->bi_end_io function requires irq-safe lock Reports have surfaced of a lockdep splat complaining about an irq-safe -> irq-unsafe locking order in the xfs_buf_bio_end_io() bio completion handler. This only occurs when I/O errors are present because bp->b_lock is only acquired in this context to protect setting an error on the buffer. The problem is that this lock can be acquired with the (request_queue) q->queue_lock held. See scsi_end_request() or ata_qc_schedule_eh(), for example. Replace the locked test/set of b_io_error with a cmpxchg() call. This eliminates the need for the lock and thus the lock ordering problem goes away. Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_buf.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit e7387da52028b072489c45efeb7a916c0205ebd2 Author: Daniel Lezcano <daniel.lezcano@linaro.org> Date: Tue May 17 16:54:00 2016 +0200 cpuidle: Fix cpuidle_state_is_coupled() argument in cpuidle_enter() Commit 0b89e9aa2856 (cpuidle: delay enabling interrupts until all coupled CPUs leave idle) rightfully fixed a regression by letting the coupled idle state framework to handle local interrupt enabling when the CPU is exiting an idle state. The current code checks if the idle state is coupled and, if so, it will let the coupled code to enable interrupts. This way, it can decrement the ready-count before handling the interrupt. This mechanism prevents the other CPUs from waiting for a CPU which is handling interrupts. But the check is done against the state index returned by the back end driver's ->enter functions which could be different from the initial index passed as parameter to the cpuidle_enter_state() function. entered_state = target_state->enter(dev, drv, index); [ ... ] if (!cpuidle_state_is_coupled(drv, entered_state)) local_irq_enable(); [ ... ] If the 'index' is referring to a coupled idle state but the 'entered_state' is *not* coupled, then the interrupts are enabled again. All CPUs blocked on the sync barrier may busy loop longer if the CPU has interrupts to handle before decrementing the ready-count. That's consuming more energy than saving. Fixes: 0b89e9aa2856 (cpuidle: delay enabling interrupts until all coupled CPUs leave idle) Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: 3.15+ <stable@vger.kernel.org> # 3.15+ [ rjw: Subject & changelog ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpuidle/cpuidle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6f88b5be84985f751746d313b8d2a4e18494a602 Merge: 1eccc6e ec4c436 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 17:47:31 2016 -0700 Merge tag 'regulator-fix-can-change-voltage' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fix from Mark Brown: "Fix build warnings from regulator_can_change_voltage() Cut down on noise for mainstream users of the API and people doing build testing by dropping the deprecated flag from regulator_can_change_voltage() as it triggers even on the EXPORT_SYMBOL_GPL() which affects all builds rather than just the remaining drivers with calls to it (for which fixes are currently pending). The function remains deprecated and is expected to be removed entirely in v4.8" * tag 'regulator-fix-can-change-voltage' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: Silence build warnings from regulator_can_change_voltage() commit 1eccc6e1529ec7ad1cebbd2c97ceb2a1a39f7d76 Merge: dcc4c2f d30a2b4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 17:39:42 2016 -0700 Merge tag 'gpio-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO updates from Linus Walleij: "This is the bulk of GPIO changes for kernel cycle v4.7: Core infrastructural changes: - Support for natively single-ended GPIO driver stages. This means that if the hardware has registers to configure open drain or open source configuration, we use that rather than (as we did before) try to emulate it by switching the line to an input to get high impedance. This is also documented throughly in Documentation/gpio/driver.txt for those of you who did not understand one word of what I just wrote. - Start to do away with the unnecessarily complex and unitelligible ARCH_REQUIRE_GPIOLIB and ARCH_WANT_OPTIONAL_GPIOLIB, another evolutional artifact from the time when the GPIO subsystem was unmaintained. Archs can now just select GPIOLIB and be done with it, cleanups to arches will trickle in for the next kernel. Some minor archs ACKed the changes immediately so these are included in this pull request. - Advancing the use of the data pointer inside the GPIO device for storing driver data by switching the PowerPC, Super-H Unicore and a few other subarches or subsystem drivers in ALSA SoC, Input, serial, SSB, staging etc to use it. - The initialization now reads the input/output state of the GPIO lines, so that each GPIO descriptor knows - if this callback is implemented - whether the line is input or output. This also reflects nicely in userspace "lsgpio". - It is now possible to name GPIO producer names, line names, from the device tree. (Platform data has been supported for a while). I bet we will get a similar mechanism for ACPI one of those days. This makes is possible to get sensible producer names for e.g. GPIO rails in "lsgpio" in userspace. New drivers: - New driver for the Loongson1. - The XLP driver now supports Broadcom Vulcan ARM64. - The IT87 driver now supports IT8620 and IT8628. - The PCA953X driver now supports Galileo Gen2. Driver improvements: - MCP23S08 was switched to use the gpiolib irqchip helpers and now also suppors level-triggered interrupts. - 74x164 and RCAR now supports the .set_multiple() callback - AMDPT was converted to use generic GPIO. - TC3589x, TPS65218, SX150X, F7188X, MENZ127, VX855, WM831X, WM8994 support the new single ended callback for open drain and in some cases open source. - Implement the .get_direction() callback for a few more drivers like PL061, Xgene. Cleanups: - Paul Gortmaker combed through the drivers and de-modularized those who are not really modules. - Move the GPIO poweroff DT bindings to the power subdir where they belong. - Rename gpio-generic.c to gpio-mmio.c, which is much more to the point. That's what it is handling, nothing more, nothing less" * tag 'gpio-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: (126 commits) MIPS: do away with ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB gpio: zevio: make it explicitly non-modular gpio: timberdale: make it explicitly non-modular gpio: stmpe: make it explicitly non-modular gpio: sodaville: make it explicitly non-modular pinctrl: sh-pfc: Let gpio_chip.to_irq() return zero on error gpio: dwapb: Add ACPI device ID for DWAPB GPIO controller on X-Gene platforms gpio: dt-bindings: add wd,mbl-gpio bindings gpio: of: make it possible to name GPIO lines gpio: make gpiod_to_irq() return negative for NO_IRQ gpio: xgene: implement .get_direction() gpio: xgene: Enable ACPI support for X-Gene GFC GPIO driver gpio: tegra: Implement gpio_get_direction callback gpio: set up initial state from .get_direction() gpio: rename gpio-generic.c into gpio-mmio.c gpio: generic: fix GPIO_GENERIC_PLATFORM is set to module case gpio: dwapb: add gpio-signaled acpi event support gpio: dwapb: convert device node to fwnode gpio: dwapb: remove name from dwapb_port_property gpio/qoriq: select IRQ_DOMAIN ... commit 3834abb4e64483af7af7500e54c0a5f957a52b1b Author: Pankaj Gupta <Pankaj.Gupta@spreadtrum.com> Date: Mon May 16 11:07:19 2016 +0000 cpufreq: simplified goto out in cpufreq_register_driver() simplified goto out in cpufreq_register_driver for increasing code readability Signed-off-by: Pankaj Gupta <pankaj.gupta@spreadtrum.com> Signed-off-by: Sanjeev Yadav <sanjeev.yadav@spreadtrum.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit dcc4c2f61cdc7e0ab61b25b8d28205302497a8c4 Merge: 0b86c75 66bc5ba Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 17:34:33 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid Pull HID updates from Jiri Kosina: "No biggies this time: - micro-optimization of implement() in HID core parses, from Dmitry Torokhov - thingm driver cleanups from Heiner Kallweit - fine-graining detection of distance and tilt axes in wacom driver from Jason Gerecke - New hid-asus driver, currently supporting X205TA and VivoBook E200HA, from Yusuke Fujimaki" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid: HID: wacom: Add fuzz factor to distance and tilt axes HID: usbhid: quirks for Corsair RGB keyboard & mice (K70R, K95RGB, M65RGB, K70RGB, K65RGB) HID: thingm: remove not needed error message HID: thingm: set new flag LED_HW_PLUGGABLE HID: thingm: factor out duplicated code to thingm_init_led HID: simplify implement() a bit HID: asus: add support for VivoBook E200HA HID: hidraw: silence an uninitialized variable warning HID: roccat: silence an uninitialized variable warning HID: Asus X205TA keyboard driver HID: hidraw: switch to using memdup_user commit 45482c703b8c7e86e339e92f186cadd9a735fd0e Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu May 12 15:14:12 2016 +0200 cpufreq: governor: CPUFREQ_GOV_STOP never fails None of the cpufreq governors currently in the tree will ever fail an invocation of the ->governor() callback with the event argument equal to CPUFREQ_GOV_STOP (unless invoked with incorrect arguments which doesn't matter anyway) and it is rather difficult to imagine a valid reason for such a failure. Accordingly, rearrange the code in the core to make it clear that this call never fails. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 40 +++++++++++----------------------------- 1 file changed, 11 insertions(+), 29 deletions(-) commit 36be3418eb769c66bc16eb1c9b402591cf1219b7 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu May 12 15:13:35 2016 +0200 cpufreq: governor: CPUFREQ_GOV_POLICY_EXIT never fails None of the cpufreq governors currently in the tree will ever fail an invocation of the ->governor() callback with the event argument equal to CPUFREQ_GOV_POLICY_EXIT (unless invoked with incorrect arguments which doesn't matter anyway) and it wouldn't really make sense to fail it, because the caller won't be able to handle that failure in a meaningful way. Accordingly, rearrange the code in the core to make it clear that this call never fails. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 35 ++++++++++++----------------------- 1 file changed, 12 insertions(+), 23 deletions(-) commit c749c64f45fa07d20e11af2e3f3caa9d7650d341 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu May 12 00:46:45 2016 +0200 intel_pstate: Simplify conditional in intel_pstate_set_policy() One of the if () statements in intel_pstate_set_policy() causes another if () to be evaluated if the condition is true and it doesn't do anything else, so merge the two if () statements into one. No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> drivers/cpufreq/intel_pstate.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 0b86c75db6e7f68c22ac5d0dae0f551c4897cdf5 Merge: 16bf834 be69f70 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 17:11:27 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/livepatching Pull livepatching updates from Jiri Kosina: - remove of our own implementation of architecture-specific relocation code and leveraging existing code in the module loader to perform arch-dependent work, from Jessica Yu. The relevant patches have been acked by Rusty (for module.c) and Heiko (for s390). - live patching support for ppc64le, which is a joint work of Michael Ellerman and Torsten Duwe. This is coming from topic branch that is share between livepatching.git and ppc tree. - addition of livepatching documentation from Petr Mladek * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/livepatching: livepatch: make object/func-walking helpers more robust livepatch: Add some basic livepatch documentation powerpc/livepatch: Add live patching support on ppc64le powerpc/livepatch: Add livepatch stack to struct thread_info powerpc/livepatch: Add livepatch header livepatch: Allow architectures to specify an alternate ftrace location ftrace: Make ftrace_location_range() global livepatch: robustify klp_register_patch() API error checking Documentation: livepatch: outline Elf format and requirements for patch modules livepatch: reuse module loader code to write relocations module: s390: keep mod_arch_specific for livepatch modules module: preserve Elf information for livepatch modules Elf: add livepatch-specific Elf constants commit 16bf8348055fe4615bd08ef50f9874f5dcc10268 Merge: a7fd20d 52bbe14 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 17:05:30 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial Pull trivial tree updates from Jiri Kosina. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (21 commits) gitignore: fix wording mfd: ab8500-debugfs: fix "between" in printk memstick: trivial fix of spelling mistake on management cpupowerutils: bench: fix "average" treewide: Fix typos in printk IB/mlx4: printk fix pinctrl: sirf/atlas7: fix printk spelling serial: mctrl_gpio: Grammar s/lines GPIOs/line GPIOs/, /sets/set/ w1: comment spelling s/minmum/minimum/ Blackfin: comment spelling s/divsor/divisor/ metag: Fix misspellings in comments. ia64: Fix misspellings in comments. hexagon: Fix misspellings in comments. tools/perf: Fix misspellings in comments. cris: Fix misspellings in comments. c6x: Fix misspellings in comments. blackfin: Fix misspelling of 'register' in comment. avr32: Fix misspelling of 'definitions' in comment. treewide: Fix typos in printk Doc: treewide : Fix typos in DocBook/filesystem.xml ... commit a7fd20d1c476af4563e66865213474a2f9f473a4 Merge: b80fed9 917fa53 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 16:26:30 2016 -0700 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next Pull networking updates from David Miller: "Highlights: 1) Support SPI based w5100 devices, from Akinobu Mita. 2) Partial Segmentation Offload, from Alexander Duyck. 3) Add GMAC4 support to stmmac driver, from Alexandre TORGUE. 4) Allow cls_flower stats offload, from Amir Vadai. 5) Implement bpf blinding, from Daniel Borkmann. 6) Optimize _ASYNC_ bit twiddling on sockets, unless the socket is actually using FASYNC these atomics are superfluous. From Eric Dumazet. 7) Run TCP more preemptibly, also from Eric Dumazet. 8) Support LED blinking, EEPROM dumps, and rxvlan offloading in mlx5e driver, from Gal Pressman. 9) Allow creating ppp devices via rtnetlink, from Guillaume Nault. 10) Improve BPF usage documentation, from Jesper Dangaard Brouer. 11) Support tunneling offloads in qed, from Manish Chopra. 12) aRFS offloading in mlx5e, from Maor Gottlieb. 13) Add RFS and RPS support to SCTP protocol, from Marcelo Ricardo Leitner. 14) Add MSG_EOR support to TCP, this allows controlling packet coalescing on application record boundaries for more accurate socket timestamp sampling. From Martin KaFai Lau. 15) Fix alignment of 64-bit netlink attributes across the board, from Nicolas Dichtel. 16) Per-vlan stats in bridging, from Nikolay Aleksandrov. 17) Several conversions of drivers to ethtool ksettings, from Philippe Reynes. 18) Checksum neutral ILA in ipv6, from Tom Herbert. 19) Factorize all of the various marvell dsa drivers into one, from Vivien Didelot 20) Add VF support to qed driver, from Yuval Mintz" * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1649 commits) Revert "phy dp83867: Fix compilation with CONFIG_OF_MDIO=m" Revert "phy dp83867: Make rgmii parameters optional" r8169: default to 64-bit DMA on recent PCIe chips phy dp83867: Make rgmii parameters optional phy dp83867: Fix compilation with CONFIG_OF_MDIO=m bpf: arm64: remove callee-save registers use for tmp registers asix: Fix offset calculation in asix_rx_fixup() causing slow transmissions switchdev: pass pointer to fib_info instead of copy net_sched: close another race condition in tcf_mirred_release() tipc: fix nametable publication field in nl compat drivers: net: Don't print unpopulated net_device name qed: add support for dcbx. ravb: Add missing free_irq() calls to ravb_close() qed: Remove a stray tab net: ethernet: fec-mpc52xx: use phy_ethtool_{get|set}_link_ksettings net: ethernet: fec-mpc52xx: use phydev from struct net_device bpf, doc: fix typo on bpf_asm descriptions stmmac: hardware TX COE doesn't work when force_thresh_dma_mode is set net: ethernet: fs-enet: use phy_ethtool_{get|set}_link_ksettings net: ethernet: fs-enet: use phydev from struct net_device ... commit e0d46f5c6e0ba3a79e64cd60e62b7b7191ed93f3 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Fri Apr 22 22:36:44 2016 +0200 btrfs: Switch to generic xattr handlers The btrfs_{set,remove}xattr inode operations check for a read-only root (btrfs_root_readonly) before calling into generic_{set,remove}xattr. If this check is moved into __btrfs_setxattr, we can get rid of btrfs_{set,remove}xattr. This patch applies to mainline, I would like to keep it together with the other xattr cleanups if possible, though. Could you please review? Thanks, Andreas Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/btrfs/inode.c | 16 ++++++++-------- fs/btrfs/xattr.c | 22 +++------------------- fs/btrfs/xattr.h | 3 --- 3 files changed, 11 insertions(+), 30 deletions(-) commit 2b88fc21cae91e925bc5e361e6ea67467b471da5 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Fri Apr 22 19:14:00 2016 +0200 ubifs: Switch to generic xattr handlers Ubifs internally uses special inodes for storing xattrs. Those inodes had NULL {get,set,remove}xattr inode operations before this change, so xattr operations on them would fail. The super block's s_xattr field would also apply to those special inodes. However, the inodes are not visible outside of ubifs, and so no xattr operations will ever be carried out on them anyway. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Reviewed-by: Richard Weinberger <richard@nod.at> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ubifs/dir.c | 6 +-- fs/ubifs/file.c | 12 ++--- fs/ubifs/super.c | 1 + fs/ubifs/ubifs.h | 7 +-- fs/ubifs/xattr.c | 143 ++++++++++++++++++++++++++----------------------------- 5 files changed, 79 insertions(+), 90 deletions(-) commit ba36c21b0cd8b55fd7f010e9052656c2c03d9e5e Author: Nicholas Bellinger <nab@linux-iscsi.org> Date: Sat Apr 9 03:04:42 2016 +0000 nvme/host: Add missing blk_integrity tag_size + flags assignments While doing recent bring-up of nvme/host with target-core T10-PI, I noticed /sys/block/nvme*/integrity/device_is_integrity_capable was false, and /sys/block/nvme*/integrity/tag_size contained a bogus value. AFAICT outside of blk_integrity_compare() for DM + MD these are informational values, but go ahead and add the missing assignments for nvme/host to match what SCSI does within sd_dif_config_host() for consistency's sake. Cc: Keith Busch <keith.busch@intel.com> Cc: Jay Freyensee <james.p.freyensee@intel.com> Cc: Martin K. Petersen <martin.petersen@oracle.com> Cc: Sagi Grimberg <sagig@grimberg.me> Cc: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> Reviewed-by: Sagi Grimberg <sagi at grimberg.me> Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 4 ++++ 1 file changed, 4 insertions(+) commit 99466e708ddce8904c8635c213f2deb523ef4fb9 Author: Keith Busch <keith.busch@intel.com> Date: Mon May 2 15:14:24 2016 -0600 NVMe: Add device ID's with stripe quirk Adds two Intel controllers that have the "stripe" quirk. Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 0ff9d4e1a284a9282a049bf064f123e27f838907 Author: Keith Busch <keith.busch@intel.com> Date: Thu May 12 08:37:14 2016 -0600 NVMe: Short-cut removal on surprise hot-unplug This patch adds a new state that when set has the core automatically kill request queues prior to removing namespaces. If PCI device is not present at the time the nvme driver's remove is called, we can kill all IO queues immediately instead of waiting for the watchdog thread to do that at its polling interval. This improves scenarios where multiple hot plug events occur at the same time since it doesn't block the pci enumeration for as long. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 18 ++++++++++++++++++ drivers/nvme/host/nvme.h | 1 + drivers/nvme/host/pci.c | 4 ++++ 3 files changed, 23 insertions(+) commit 9ec3bb2f994bda9c8817856fdcbfaebe8f62fbd3 Author: Keith Busch <keith.busch@intel.com> Date: Fri Apr 29 15:45:18 2016 -0600 NVMe: Allow user initiated rescan This exposes ioctl and sysfs methods a user can invoke to request the driver rescan a controller and its namespaces. This is less harsh than doing a controller reset, which temporarilly halts all IO, just to surface a newly attached namespace. This is mainly useful for controllers that implement the namespace management command, but do not support the namespace notify change asynchronous event notification. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 15 +++++++++++++++ include/uapi/linux/nvme_ioctl.h | 1 + 2 files changed, 16 insertions(+) commit d011fb3164e8694d7839f10a497f8ab6c660149a Author: Keith Busch <keith.busch@intel.com> Date: Mon Apr 4 15:07:41 2016 -0600 NVMe: Reduce driver log spamming Reduce error logging when no corrective action is required. Suggessted-by: Chris Petersen <cpetersen@fb.com> Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 921920ab32f290dafdb0359024d4587897712728 Author: Keith Busch <keith.busch@intel.com> Date: Mon Mar 28 16:03:21 2016 -0600 NVMe: Unbind driver on failure Instead of removing the PCI device from the kernel's topology on controller failure, this patch simply requests unbinding the device from the driver. This avoids concurrently running pci removal with the hot plug event, which has been reported to be problematic when multiple surprise events occur near simultaneously. The other benefit is that we will have PCI config and memory space available to poke around for debugging a failed controller, assuming the device was not physically removed. The down side occurs if the platform and/or kernel do not support any type of surprise hot removal. The device will remain visible through sysfs (and therefore lspci), and some manual work is necessary to get the logical topology corrected. But if your platform and/or kernel don't support surprise removal, you probably shouldn't be doing that anyway. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 014a0d609eb4721d1e416cf10da2d5602f9b34d5 Author: Keith Busch <keith.busch@intel.com> Date: Fri May 6 11:50:52 2016 -0600 NVMe: Delete only created queues Use the online queue count instead of the number of allocated queues. The controller should just return an invalid queue identifier error to the commands if a queue wasn't created. While it's not harmful, it's still not correct. Reported-by: Saar Gross <saar@annapurnalabs.com> Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2800b8e7d9dfca1fd9d044dcf7a046b5de5a7239 Author: Keith Busch <keith.busch@intel.com> Date: Fri May 13 12:38:09 2016 -0600 NVMe: Allocate queues only for online cpus The driver previously requested allocating queues for the total possible number of CPUs so that blk-mq could rebalance these if CPUs were added after initialization. The number of hardware contexts can now be changed at runtime, so we only need to allocate the number of online queues since we can add more later. Suggested-by: Jeff Lien <jeff.lien@hgst.com> Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b80fed9595513384424cd141923c9161c4b5021b Merge: 24b9f0c 202bae5 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 16:13:00 2016 -0700 Merge tag 'dm-4.7-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm Pull device mapper updates from Mike Snitzer: - based on Jens' 'for-4.7/core' to have DM thinp's discard support use bio_inc_remaining() and the block core's new async __blkdev_issue_discard() interface - make DM multipath's fast code-paths lockless, using lockless_deference, to significantly improve large NUMA performance when using blk-mq. The m->lock spinlock contention was a serious bottleneck. - a few other small code cleanups and Documentation fixes * tag 'dm-4.7-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm: dm thin: unroll issue_discard() to create longer discard bio chains dm thin: use __blkdev_issue_discard for async discard support dm thin: remove __bio_inc_remaining() and switch to using bio_inc_remaining() dm raid: make sure no feature flags are set in metadata dm ioctl: drop use of __GFP_REPEAT in copy_params()'s __vmalloc() call dm stats: fix spelling mistake in Documentation dm cache: update cache-policies.txt now that mq is an alias for smq dm mpath: eliminate use of spinlock in IO fast-paths dm mpath: move trigger_event member to the end of 'struct multipath' dm mpath: use atomic_t for counting members of 'struct multipath' dm mpath: switch to using bitops for state flags dm thin: Remove return statement from void function dm: remove unused mapped_device argument from free_tio() commit 24b9f0cf00c8e8df29a4ddfec8c139ad62753113 Merge: a4d1dbe 116f7d4 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 16:03:32 2016 -0700 Merge branch 'for-4.7/drivers' of git://git.kernel.dk/linux-block Pull block driver updates from Jens Axboe: "On top of the core pull request, this is the drivers pull request for this merge window. This contains: - Switch drivers to the new write back cache API, and kill off the flush flags. From me. - Kill the discard support for the STEC pci-e flash driver. It's trivially broken, and apparently unmaintained, so it's safer to just remove it. From Jeff Moyer. - A set of lightnvm updates from the usual suspects (Matias/Javier, and Simon), and fixes from Arnd, Jeff Mahoney, Sagi, and Wenwei Tao. - A set of updates for NVMe: - Turn the controller state management into a proper state machine. From Christoph. - Shuffling of code in preparation for NVMe-over-fabrics, also from Christoph. - Cleanup of the command prep part from Ming Lin. - Rewrite of the discard support from Ming Lin. - Deadlock fix for namespace removal from Ming Lin. - Use the now exported blk-mq tag helper for IO termination. From Sagi. - Various little fixes from Christoph, Guilherme, Keith, Ming Lin, Wang Sheng-Hui. - Convert mtip32xx to use the now exported blk-mq tag iter function, from Keith" * 'for-4.7/drivers' of git://git.kernel.dk/linux-block: (74 commits) lightnvm: reserved space calculation incorrect lightnvm: rename nr_pages to nr_ppas on nvm_rq lightnvm: add is_cached entry to struct ppa_addr lightnvm: expose gennvm_mark_blk to targets lightnvm: remove mgt targets on mgt removal lightnvm: pass dma address to hardware rather than pointer lightnvm: do not assume sequential lun alloc. nvme/lightnvm: Log using the ctrl named device lightnvm: rename dma helper functions lightnvm: enable metadata to be sent to device lightnvm: do not free unused metadata on rrpc lightnvm: fix out of bound ppa lun id on bb tbl lightnvm: refactor set_bb_tbl for accepting ppa list lightnvm: move responsibility for bad blk mgmt to target lightnvm: make nvm_set_rqd_ppalist() aware of vblks lightnvm: remove struct factory_blks lightnvm: refactor device ops->get_bb_tbl() lightnvm: introduce nvm_for_each_lun_ppa() macro lightnvm: refactor dev->online_target to global nvm_targets lightnvm: rename nvm_targets to nvm_tgt_type ... commit a4d1dbed0e27030b3c3ca2d1d5c33a1b45bc53d2 Merge: c2e7b20 b3a834b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 15:29:49 2016 -0700 Merge branch 'for-4.7/core' of git://git.kernel.dk/linux-block Pull core block layer updates from Jens Axboe: "This is the core block IO changes for this merge window. Nothing earth shattering in here, it's mostly just fixes. In detail: - Fix for a long standing issue where wrong ordering in blk-mq caused order_to_size() to spew a warning. From Bart. - Async discard support from Christoph. Basically just splitting our sync interface into a submit + wait part. - Add a cleaner interface for flagging whether a device has a write back cache or not. We've previously overloaded blk_queue_flush() with this, but let's make it more explicit. Drivers cleaned up and updated in the drivers pull request. From me. - Fix for a double check for whether IO accounting is enabled or not. From Michael Callahan. - Fix for the async discard from Mike Snitzer, reinstating the early EOPNOTSUPP return if the device doesn't support discards. - Also from Mike, export bio_inc_remaining() so dm can drop it's private copy of it. - From Ming Lin, add support for passing in an offset for request payloads. - Tag function export from Sagi, which will be used in NVMe in the drivers pull. - Two blktrace related fixes from Shaohua. - Propagate NOMERGE flag when making a request from a bio, also from Shaohua. - An optimization to not parse cgroup paths in blk-throttle, if we don't need to. From Shaohua" * 'for-4.7/core' of git://git.kernel.dk/linux-block: blk-mq: fix undefined behaviour in order_to_size() blk-throttle: don't parse cgroup path if trace isn't enabled blktrace: add missed mask name blktrace: delete garbage for message trace block: make bio_inc_remaining() interface accessible again block: reinstate early return of -EOPNOTSUPP from blkdev_issue_discard block: Minor blk_account_io_start usage cleanup block: add __blkdev_issue_discard block: remove struct bio_batch block: copy NOMERGE flag from bio to request block: add ability to flag write back caching on a device blk-mq: Export tagset iter function block: add offset in blk_add_request_payload() writeback: Fix performance regression in wb_over_bg_thresh() commit 9f8036643dd9609b329aa1b89c9a95981e9ba62f Author: Kees Cook <keescook@chromium.org> Date: Mon May 16 19:27:28 2016 -0700 doc: self-protection: provide initial details This document attempts to codify the intent around kernel self-protection along with discussion of both existing and desired technologies, with attention given to the rationale behind them, and the expectations of their usage. Signed-off-by: Kees Cook <keescook@chromium.org> Reviewed-by: Randy Dunlap <rdunlap@infradead.org> [jc: applied fixes suggested by Randy] Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/security/self-protection.txt | 261 +++++++++++++++++++++++++++++ 1 file changed, 261 insertions(+) commit c2e7b207058d4ff6a9010430763fb561f307eb67 Merge: c52b761 24368aa Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 15:05:23 2016 -0700 Merge branch 'work.preadv2' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs cleanups from Al Viro: "More cleanups from Christoph" * 'work.preadv2' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: nfsd: use RWF_SYNC fs: add RWF_DSYNC aand RWF_SYNC ceph: use generic_write_sync fs: simplify the generic_write_sync prototype fs: add IOCB_SYNC and IOCB_DSYNC direct-io: remove the offset argument to dio_complete direct-io: eliminate the offset argument to ->direct_IO xfs: eliminate the pos variable in xfs_file_dio_aio_write filemap: remove the pos argument to generic_file_direct_write filemap: remove pos variables in generic_file_read_iter commit c315ef8d9db7f1a0ebd023a395ebdfde1c68057e Merge: a88336d 5f9a8a5 Author: Chris Mason <clm@fb.com> Date: Tue May 17 14:43:19 2016 -0700 Merge branch 'for-chris-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/fdmanana/linux into for-linus-4.7 Signed-off-by: Chris Mason <clm@fb.com> commit c52b76185b7a1b300e5f15ff871c8f45ced3dee9 Merge: 681750c 81cd889 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 14:41:03 2016 -0700 Merge branch 'work.const-path' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull 'struct path' constification update from Al Viro: "'struct path' is passed by reference to a bunch of Linux security methods; in theory, there's nothing to stop them from modifying the damn thing and LSM community being what it is, sooner or later some enterprising soul is going to decide that it's a good idea. Let's remove the temptation and constify all of those..." * 'work.const-path' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: constify ima_d_path() constify security_sb_pivotroot() constify security_path_chroot() constify security_path_{link,rename} apparmor: remove useless checks for NULL ->mnt constify security_path_{mkdir,mknod,symlink} constify security_path_{unlink,rmdir} apparmor: constify common_perm_...() apparmor: constify aa_path_link() apparmor: new helper - common_path_perm() constify chmod_common/security_path_chmod constify security_sb_mount() constify chown_common/security_path_chown tomoyo: constify assorted struct path * apparmor_path_truncate(): path->mnt is never NULL constify vfs_truncate() constify security_path_truncate() [apparmor] constify struct path * in a bunch of helpers commit 681750c0468185f92acb8080c13f26a19cb4ee0d Merge: 820c687 a9ae008 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 14:35:45 2016 -0700 Merge branch 'for-cifs' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull cifs xattr updates from Al Viro: "This is the remaining parts of the xattr work - the cifs bits" * 'for-cifs' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: cifs: Switch to generic xattr handlers cifs: Fix removexattr for os2.* xattrs cifs: Check for equality with ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT cifs: Fix xattr name checks commit 820c687b70ae2c72972240b83c053cb7c85ddbc3 Merge: dba1e98 2a28900 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 14:25:02 2016 -0700 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs Pull UDF fixes from Jan Kara: "A fix for UDF crash on corrupted media and one UDF header fixup" * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs: udf: Export superblock magic to userspace udf: Prevent stack overflow on corrupted filesystem mount commit a88336d13c66fc171f336c6332fcb67339894e08 Merge: 02da2d7 680834c Author: Chris Mason <clm@fb.com> Date: Tue May 17 14:24:44 2016 -0700 Merge branch 'for-chris-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux into for-linus-4.7 commit dba1e987312ed318dfd46d4684e9e97b2223f2e8 Merge: cb6fd68 6ed71e9 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 14:15:18 2016 -0700 Merge tag 'jfs-4.7' of git://github.com/kleikamp/linux-shaggy Pull jfs updates from Dave Kleikamp: "Some jfs logging cleanups from Joe Perches" * tag 'jfs-4.7' of git://github.com/kleikamp/linux-shaggy: jfs: Coalesce some formats jfs: Remove unnecessary line continuations and terminating newlines jfs: Remove terminating newlines from jfs_info, jfs_warn, jfs_err uses commit cb6fd68fdd4a94880a99ad8515844c7a25e50d3e Author: Kees Cook <keescook@chromium.org> Date: Tue May 17 12:14:39 2016 -0700 exec: clarify reasoning for euid/egid reset This section of code initially looks redundant, but is required. This improves the comment to explain more clearly why the reset is needed. Signed-off-by: Kees Cook <keescook@chromium.org> Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/exec.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 1b3c6d07e29515064aca8a9f86efaea7da4da027 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:48 2016 -0400 pnfs: make pnfs_layout_process more robust It can return NULL if layoutgets are blocked currently. Fix it to return -EAGAIN in that case, so we can properly handle it in pnfs_update_layout. Also, clean up and simplify the error handling -- eliminate "status" and just use "lseg". Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) commit 183d9e7b112aaed0d19c16ffcf0f8c3a86dc71e0 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:47 2016 -0400 pnfs: rework LAYOUTGET retry handling There are several problems in the way a stateid is selected for a LAYOUTGET operation: We pick a stateid to use in the RPC prepare op, but that makes it difficult to serialize LAYOUTGETs that use the open stateid. That serialization is done in pnfs_update_layout, which occurs well before the rpc_prepare operation. Between those two events, the i_lock is dropped and reacquired. pnfs_update_layout can find that the list has lsegs in it and not do any serialization, but then later pnfs_choose_layoutget_stateid ends up choosing the open stateid. This patch changes the client to select the stateid to use in the LAYOUTGET earlier, when we're searching for a usable layout segment. This way we can do it all while holding the i_lock the first time, and ensure that we serialize any LAYOUTGET call that uses a non-layout stateid. This also means a rework of how LAYOUTGET replies are handled, as we must now get the latest stateid if we want to retransmit in response to a retryable error. Most of those errors boil down to the fact that the layout state has changed in some fashion. Thus, what we really want to do is to re-search for a layout when it fails with a retryable error, so that we can avoid reissuing the RPC at all if possible. While the LAYOUTGET RPC is async, the initiating thread always waits for it to complete, so it's effectively synchronous anyway. Currently, when we need to retry a LAYOUTGET because of an error, we drive that retry via the rpc state machine. This means that once the call has been submitted, it runs until it completes. So, we must move the error handling for this RPC out of the rpc_call_done operation and into the caller. In order to handle errors like NFS4ERR_DELAY properly, we must also pass a pointer to the sliding timeout, which is now moved to the stack in pnfs_update_layout. The complicating errors are -NFS4ERR_RECALLCONFLICT and -NFS4ERR_LAYOUTTRYLATER, as those involve a timeout after which we give up and return NULL back to the caller. So, there is some special handling for those errors to ensure that the layers driving the retries can handle that appropriately. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/nfs4proc.c | 115 ++++++++++++++++---------------------- fs/nfs/nfs4trace.h | 10 +++- fs/nfs/pnfs.c | 144 +++++++++++++++++++++++++----------------------- fs/nfs/pnfs.h | 6 +- include/linux/errno.h | 1 + include/linux/nfs4.h | 2 + include/linux/nfs_xdr.h | 2 - 7 files changed, 136 insertions(+), 144 deletions(-) commit 83026d80a16ea6a4e4f06a994fc7831b1d8d6375 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:46 2016 -0400 pnfs: lift retry logic from send_layoutget to pnfs_update_layout If we get back something like NFS4ERR_OLD_STATEID, that will be translated into -EAGAIN, and the do/while loop in send_layoutget will drive the call again. This is not quite what we want, I think. An error like that is a sign that something has changed. That something could have been a concurrent LAYOUTGET that would give us a usable lseg. Lift the retry logic into pnfs_update_layout instead. That allows us to redo the layout search, and may spare us from having to issue an RPC. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 72 +++++++++++++++++++++++++++++------------------------------ 1 file changed, 36 insertions(+), 36 deletions(-) commit d03ab29dbbe905c6c7c5abd78e02547fa954ec07 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:45 2016 -0400 pnfs: fix bad error handling in send_layoutget Currently, the code will clear the fail bit if we get back a fatal error. I don't think that's correct -- we want to clear that bit if we do not get a fatal error. Fixes: 0bcbf039f6 (nfs: handle request add failure properly) Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 95e2b7e95d43c5c95620b12355a90713268376d3 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:44 2016 -0400 flexfiles: add kerneldoc header to nfs4_ff_layout_prepare_ds Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayoutdev.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit 094069f1d96f691637b5c335f5eb79566d2457ff Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:43 2016 -0400 flexfiles: remove pointless setting of NFS_LAYOUT_RETURN_REQUESTED Setting just the NFS_LAYOUT_RETURN_REQUESTED flag doesn't do anything, unless there are lsegs that are also being marked for return. At the point where that happens this flag is also set, so these set_bit calls don't do anything useful. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 2 -- fs/nfs/flexfilelayout/flexfilelayoutdev.c | 8 +------- 2 files changed, 1 insertion(+), 9 deletions(-) commit 6d597e1750126a2c6fd99e4b2cc176955bb9972e Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:42 2016 -0400 pnfs: only tear down lsegs that precede seqid in LAYOUTRETURN args LAYOUTRETURN is "special" in that servers and clients are expected to work with old stateids. When the client sends a LAYOUTRETURN with an old stateid in it then the server is expected to only tear down layout segments that were present when that seqid was current. Ensure that the client handles its accounting accordingly. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/callback_proc.c | 3 ++- fs/nfs/nfs42proc.c | 2 +- fs/nfs/nfs4proc.c | 5 ++-- fs/nfs/pnfs.c | 64 +++++++++++++++++++++++++++++++++----------------- fs/nfs/pnfs.h | 6 +++-- 5 files changed, 52 insertions(+), 28 deletions(-) commit 3982a6a2d0e64441c938f4e7f93985aff37d8fb3 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:41 2016 -0400 pnfs: keep track of the return sequence number in pnfs_layout_hdr When we want to selectively do a LAYOUTRETURN, we need to specify a stateid that represents most recent layout acquisition that is to be returned. When we mark a layout stateid to be returned, we update the return sequence number in the layout header with that value, if it's newer than the existing one. Then, when we go to do a LAYOUTRETURN on layout header put, we overwrite the seqid in the stateid with the saved one, and then zero it out. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 11 ++++++++--- fs/nfs/pnfs.h | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) commit 6675528380f8b7fffa82047211d8352dc6797321 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:40 2016 -0400 pnfs: record sequence in pnfs_layout_segment when it's created In later patches, we're going to teach the client to be more selective about how it returns layouts. This means keeping a record of what the stateid's seqid was at the time that the server handed out a layout segment. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 1 + fs/nfs/pnfs.h | 1 + 2 files changed, 2 insertions(+) commit ee26bdd680aa10df628499fe95a7b88345574248 Author: Jeff Layton <jlayton@poochiereds.net> Date: Tue May 17 12:28:39 2016 -0400 pnfs: don't merge new ff lsegs with ones that have LAYOUTRETURN bit set Otherwise, we'll end up returning layouts that we've just received if the client issues a new LAYOUTGET prior to the LAYOUTRETURN. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 446ca2195303c550b1cec7dcf9a478910dc84672 Author: Tom Haynes <loghyr@primarydata.com> Date: Tue May 17 12:28:38 2016 -0400 pNFS/flexfiles: When initing reads or writes, we might have to retry connecting to DSes If we are initializing reads or writes and can not connect to a DS, then check whether or not IO is allowed through the MDS. If it is allowed, reset to the MDS. Else, fail the layout segment and force a retry of a new layout segment. Signed-off-by: Tom Haynes <loghyr@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) commit 3b13b4b311a508a5899070936a873e30fcc96a2f Author: Tom Haynes <loghyr@primarydata.com> Date: Tue May 17 12:28:37 2016 -0400 pNFS/flexfiles: When checking for available DSes, conditionally check for MDS io Whenever we check to see if we have the needed number of DSes for the action, we may also have to check to see whether IO is allowed to go to the MDS or not. [jlayton: fix merge conflict due to lack of localio patches here] Signed-off-by: Tom Haynes <loghyr@primarydata.com> Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 5 ++--- fs/nfs/flexfilelayout/flexfilelayout.h | 1 + fs/nfs/flexfilelayout/flexfilelayoutdev.c | 6 ++++++ 3 files changed, 9 insertions(+), 3 deletions(-) commit 75bf47ebf6b5349d875fdffe7d64b0fc4e936170 Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Tue May 17 12:28:36 2016 -0400 pNFS/flexfile: Fix erroneous fall back to read/write through the MDS This patch fixes a problem whereby the pNFS client falls back to doing reads and writes through the metadata server even when the layout flag FF_FLAGS_NO_IO_THRU_MDS is set. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) commit cca588d6c835e21fd7a3e02a964ce5fe09fdad26 Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Mon May 16 17:42:45 2016 -0400 NFS: Reclaim writes via writepage are opportunistic No need to make them a priority any more, or to make them succeed. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/write.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit abf4e13cc1e16ed83ec8363d44f76149034b2851 Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Mon May 16 17:42:44 2016 -0400 NFSv4: Use the right stateid for delegations in setattr, read and write When we're using a delegation to represent our open state, we should ensure that we use the stateid that was used to create that delegation. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/delegation.c | 9 ++++++--- fs/nfs/delegation.h | 2 +- fs/nfs/nfs4_fs.h | 5 +++-- fs/nfs/nfs4proc.c | 13 +++++++++---- fs/nfs/nfs4state.c | 13 +++++++++---- 5 files changed, 28 insertions(+), 14 deletions(-) commit 93b717fd81bf6b9a73c3702e9b079b4de8148b34 Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Mon May 16 17:42:43 2016 -0400 NFSv4: Label stateids with the type In order to more easily distinguish what kind of stateid we are dealing with, introduce a type that can be used to label the stateid structure. The label will be useful both for debugging, but also when dealing with operations like SETATTR, READ and WRITE that can take several different types of stateid as arguments. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/callback_xdr.c | 17 ++++++++++--- fs/nfs/flexfilelayout/flexfilelayout.c | 7 +++--- fs/nfs/flexfilelayout/flexfilelayoutdev.c | 3 ++- fs/nfs/nfs4_fs.h | 7 ++++-- fs/nfs/nfs4proc.c | 3 +++ fs/nfs/nfs4state.c | 5 +++- fs/nfs/nfs4xdr.c | 42 ++++++++++++++++++++++++------- include/linux/nfs4.h | 25 ++++++++++++++---- 8 files changed, 85 insertions(+), 24 deletions(-) commit 9a8f6b5ea275ff01fc8ef3b8630a3d4ed6b0a362 Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Mon May 16 17:42:42 2016 -0400 SUNRPC: Ensure get_rpccred() and put_rpccred() can take NULL arguments Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/auth.h | 3 ++- net/sunrpc/auth.c | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) commit f538d0ba5be39c52addff01c7ec31f0b90e57dfc Author: Trond Myklebust <trond.myklebust@primarydata.com> Date: Mon May 16 14:41:14 2016 -0400 pNFS: Fix a leaked layoutstats flag Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6e14a92c363e1f42c6e1339da8413fcfbe1bdc3a Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:41:48 2016 -0400 xprtrdma: Remove qplock Clean up. After "xprtrdma: Remove ro_unmap() from all registration modes", there are no longer any sites that take rpcrdma_ia::qplock for read. The one site that takes it for write is always single-threaded. It is safe to remove it. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/verbs.c | 3 --- net/sunrpc/xprtrdma/xprt_rdma.h | 1 - 2 files changed, 4 deletions(-) commit b2dde94bfa374b9e851756ab8191209f1a604e0a Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:43:03 2016 -0400 xprtrdma: Faster server reboot recovery In a cluster failover scenario, it is desirable for the client to attempt to reconnect quickly, as an alternate NFS server is already waiting to take over for the down server. The client can't see that a server IP address has moved to a new server until the existing connection is gone. For fabrics and devices where it is meaningful, set a definite upper bound on the amount of time before it is determined that a connection is no longer valid. This allows the RPC client to detect connection loss in a timely matter, then perform a fresh resolution of the server GUID in case it has changed (cluster failover). Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/verbs.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 0b043b9fb5dabcb6f187136cc685b26a7f8bcdb1 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:54 2016 -0400 xprtrdma: Remove ro_unmap() from all registration modes Clean up: The ro_unmap method is no longer used. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/fmr_ops.c | 31 --------------------------- net/sunrpc/xprtrdma/frwr_ops.c | 43 -------------------------------------- net/sunrpc/xprtrdma/physical_ops.c | 12 ----------- net/sunrpc/xprtrdma/xprt_rdma.h | 2 -- 4 files changed, 88 deletions(-) commit ead3f26e359e12ac8d90baff8ed399b85e82fe5b Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:46 2016 -0400 xprtrdma: Add ro_unmap_safe memreg method There needs to be a safe method of releasing registered memory resources when an RPC terminates. Safe can mean a number of things: + Doesn't have to sleep + Doesn't rely on having a QP in RTS ro_unmap_safe will be that safe method. It can be used in cases where synchronous memory invalidation can deadlock, or needs to have an active QP. The important case is fencing an RPC's memory regions after it is signaled (^C) and before it exits. If this is not done, there is a window where the server can write an RPC reply into memory that the client has released and re-used for some other purpose. Note that this is a full solution for FRWR, but FMR and physical still have some gaps where a particularly bad server can wreak some havoc on the client. These gaps are not made worse by this patch and are expected to be exceptionally rare and timing-based. They are noted in documenting comments. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/fmr_ops.c | 105 +++++++++++++++++++++++++++++++++---- net/sunrpc/xprtrdma/frwr_ops.c | 27 ++++++++++ net/sunrpc/xprtrdma/physical_ops.c | 20 +++++++ net/sunrpc/xprtrdma/rpc_rdma.c | 5 +- net/sunrpc/xprtrdma/transport.c | 9 ++-- net/sunrpc/xprtrdma/xprt_rdma.h | 3 ++ 6 files changed, 150 insertions(+), 19 deletions(-) commit 763bc230b63c9106fd0b0a75ba5052fe3d68b786 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:38 2016 -0400 xprtrdma: Refactor __fmr_dma_unmap() Separate the DMA unmap operation from freeing the MW. In a subsequent patch they will not always be done at the same time, and they are not related operations (except by order; freeing the MW must be the last step during invalidation). Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/fmr_ops.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 766656b022a629201b6e183c7837160cd0919286 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:29 2016 -0400 xprtrdma: Move fr_xprt and fr_worker to struct rpcrdma_mw In a subsequent patch, the fr_xprt and fr_worker fields will be needed by another memory registration mode. Move them into the generic rpcrdma_mw structure that wraps struct rpcrdma_frmr. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/frwr_ops.c | 10 +++++----- net/sunrpc/xprtrdma/xprt_rdma.h | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) commit 660bb497d0ae0c9e6be5beaff7ba17bfa5c9718c Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:21 2016 -0400 xprtrdma: Refactor the FRWR recovery worker Maintain the order of invalidation and DMA unmapping when doing a background MR reset. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/frwr_ops.c | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) commit d7a21c1bed54adcf96e1713019a6ad87e90fbbc3 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:12 2016 -0400 xprtrdma: Reset MRs in frwr_op_unmap_sync() frwr_op_unmap_sync() is now invoked in a workqueue context, the same as __frwr_queue_recovery(). There's no need to defer MR reset if posting LOCAL_INV MRs fails. This means that even when ib_post_send() fails (which should occur very rarely) the invalidation and DMA unmapping steps are still done in the correct order. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/frwr_ops.c | 98 ++++++++++++++++++++++++++---------------- 1 file changed, 60 insertions(+), 38 deletions(-) commit a3aa8b2b84a59ddd5f624aae9ee0f8b3333793e8 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:42:04 2016 -0400 xprtrdma: Save I/O direction in struct rpcrdma_frwr Move the the I/O direction field from rpcrdma_mr_seg into the rpcrdma_frmr. This makes it possible to DMA-unmap the frwr long after an RPC has exited and its rpcrdma_mr_seg array has been released and re-used. This might occur if an RPC times out while waiting for a new connection to be established. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/frwr_ops.c | 6 +++--- net/sunrpc/xprtrdma/xprt_rdma.h | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) commit 55fdfce101a0afe7bb9da17b4edbee049ae1c18d Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:56 2016 -0400 xprtrdma: Rename rpcrdma_frwr::sg and sg_nents Clean up: Follow same naming convention as other fields in struct rpcrdma_frwr. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/frwr_ops.c | 36 ++++++++++++++++++------------------ net/sunrpc/xprtrdma/xprt_rdma.h | 4 ++-- 2 files changed, 20 insertions(+), 20 deletions(-) commit 550d7502cf66ccc38bfa4c99f6526e402f918d98 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:47 2016 -0400 xprtrdma: Use core ib_drain_qp() API Clean up: Replace rpcrdma_flush_cqs() and rpcrdma_clean_cqs() with the new ib_drain_qp() API. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Reviewed-By: Leon Romanovsky <leonro@mellanox.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/verbs.c | 41 ++++++----------------------------------- 1 file changed, 6 insertions(+), 35 deletions(-) commit 3c19409b3d5173cf13adcf53b6423dc139994fc3 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:39 2016 -0400 xprtrdma: Remove rpcrdma_create_chunks() rpcrdma_create_chunks() has been replaced, and can be removed. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/rpc_rdma.c | 151 ----------------------------------------- 1 file changed, 151 deletions(-) commit 94f58c58c0b4315542036ce7703adeeaf4764940 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:30 2016 -0400 xprtrdma: Allow Read list and Reply chunk simultaneously rpcrdma_marshal_req() makes a simplifying assumption: that NFS operations with large Call messages have small Reply messages, and vice versa. Therefore with RPC-over-RDMA, only one chunk type is ever needed for each Call/Reply pair, because one direction needs chunks, the other direction will always fit inline. In fact, this assumption is asserted in the code: if (rtype != rpcrdma_noch && wtype != rpcrdma_noch) { dprintk("RPC: %s: cannot marshal multiple chunk lists\n", __func__); return -EIO; } But RPCGSS_SEC breaks this assumption. Because krb5i and krb5p perform data transformation on RPC messages before they are transmitted, direct data placement techniques cannot be used, thus RPC messages must be sent via a Long call in both directions. All such calls are sent with a Position Zero Read chunk, and all such replies are handled with a Reply chunk. Thus the client must provide every Call/Reply pair with both a Read list and a Reply chunk. Without any special security in effect, NFSv4 WRITEs may now also use the Read list and provide a Reply chunk. The marshal_req logic was preventing that, meaning an NFSv4 WRITE with a large payload that included a GETATTR result larger than the inline threshold would fail. The code that encodes each chunk list is now completely contained in its own function. There is some code duplication, but the trade-off is that the overall logic should be more clear. Note that all three chunk lists now share the rl_segments array. Some additional per-req accounting is necessary to track this usage. For the same reasons that the above simplifying assumption has held true for so long, I don't expect more array elements are needed at this time. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/rpc_rdma.c | 327 ++++++++++++++++++++++++++++++++-------- net/sunrpc/xprtrdma/xprt_rdma.h | 5 +- 2 files changed, 272 insertions(+), 60 deletions(-) commit 88b18a120332cada6ff4adb9b5b7b6e4bbb653e5 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:22 2016 -0400 xprtrdma: Update comments in rpcrdma_marshal_req() Update documenting comments to reflect code changes over the past year. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/rpc_rdma.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) commit cce6deeb56aa8aad1d3154d70ea419cf25967f5c Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:14 2016 -0400 xprtrdma: Avoid using Write list for small NFS READ requests Avoid the latency and interrupt overhead of registering a Write chunk when handling NFS READ requests of a few hundred bytes or less. This change does not interoperate with Linux NFS/RDMA servers that do not have commit 9d11b51ce7c1 ('svcrdma: Fix send_reply() scatter/gather set-up'). Commit 9d11b51ce7c1 was introduced in v4.3, and is included in 4.2.y, 4.1.y, and 3.18.y. Oracle bug 22925946 has been filed to request that the above fix be included in the Oracle Linux UEK4 NFS/RDMA server. Red Hat bugzillas 1327280 and 1327554 have been filed to request that RHEL NFS/RDMA server backports include the above fix. Workaround: Replace the "proto=rdma,port=20049" mount options with "proto=tcp" until commit 9d11b51ce7c1 is applied to your NFS server. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/rpc_rdma.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 302d3deb20682a076e1ab551821cacfdc81c5e4f Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:41:05 2016 -0400 xprtrdma: Prevent inline overflow When deciding whether to send a Call inline, rpcrdma_marshal_req doesn't take into account header bytes consumed by chunk lists. This results in Call messages on the wire that are sometimes larger than the inline threshold. Likewise, when a Write list or Reply chunk is in play, the server's reply has to emit an RDMA Send that includes a larger-than-minimal RPC-over-RDMA header. The actual size of a Call message cannot be estimated until after the chunk lists have been registered. Thus the size of each RPC-over-RDMA header can be estimated only after chunks are registered; but the decision to register chunks is based on the size of that header. Chicken, meet egg. The best a client can do is estimate header size based on the largest header that might occur, and then ensure that inline content is always smaller than that. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/fmr_ops.c | 3 ++ net/sunrpc/xprtrdma/frwr_ops.c | 3 ++ net/sunrpc/xprtrdma/physical_ops.c | 5 ++- net/sunrpc/xprtrdma/rpc_rdma.c | 85 +++++++++++++++++++++++++++++++++----- net/sunrpc/xprtrdma/xprt_rdma.h | 5 +++ 5 files changed, 90 insertions(+), 11 deletions(-) commit 949317464bc2baca0ccc69e35a7b5cd3715633a6 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:40:56 2016 -0400 xprtrdma: Limit number of RDMA segments in RPC-over-RDMA headers Send buffer space is shared between the RPC-over-RDMA header and an RPC message. A large RPC-over-RDMA header means less space is available for the associated RPC message, which then has to be moved via an RDMA Read or Write. As more segments are added to the chunk lists, the header increases in size. Typical modern hardware needs only a few segments to convey the maximum payload size, but some devices and registration modes may need a lot of segments to convey data payload. Sometimes so many are needed that the remaining space in the Send buffer is not enough for the RPC message. Sending such a message usually fails. To ensure a transport can always make forward progress, cap the number of RDMA segments that are allowed in chunk lists. This prevents less-capable devices and memory registrations from consuming a large portion of the Send buffer by reducing the maximum data payload that can be conveyed with such devices. For now I choose an arbitrary maximum of 8 RDMA segments. This allows a maximum size RPC-over-RDMA header to fit nicely in the current 1024 byte inline threshold with over 700 bytes remaining for an inline RPC message. The current maximum data payload of NFS READ or WRITE requests is one megabyte. To convey that payload on a client with 4KB pages, each chunk segment would need to handle 32 or more data pages. This is well within the capabilities of FMR. For physical registration, the maximum payload size on platforms with 4KB pages is reduced to 32KB. For FRWR, a device's maximum page list depth would need to be at least 34 to support the maximum 1MB payload. A device with a smaller maximum page list depth means the maximum data payload is reduced when using that device. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xprtrdma/fmr_ops.c | 2 +- net/sunrpc/xprtrdma/frwr_ops.c | 2 +- net/sunrpc/xprtrdma/physical_ops.c | 2 +- net/sunrpc/xprtrdma/verbs.c | 22 ---------------------- net/sunrpc/xprtrdma/xprt_rdma.h | 21 ++++++++++++++++++++- 5 files changed, 23 insertions(+), 26 deletions(-) commit 29c554227aeec48cde5c22f911e51763f096e125 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:40:48 2016 -0400 xprtrdma: Bound the inline threshold values Currently the sysctls that allow setting the inline threshold allow any value to be set. Small values only make the transport run slower. The default 1KB setting is as low as is reasonable. And the logic that decides how to divide a Send buffer between RPC-over-RDMA header and RPC message assumes (but does not check) that the lower bound is not crazy (say, 57 bytes). Send and receive buffers share a page with some control information. Values larger than about 3KB can't be supported, currently. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/xprtrdma.h | 4 +++- net/sunrpc/xprtrdma/transport.c | 6 ++++++ 2 files changed, 9 insertions(+), 1 deletion(-) commit 6b26cc8c8ead3636a18bfd9489984983f4ddd6f4 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:40:40 2016 -0400 sunrpc: Advertise maximum backchannel payload size RPC-over-RDMA transports have a limit on how large a backward direction (backchannel) RPC message can be. Ensure that the NFSv4.x CREATE_SESSION operation advertises this limit to servers. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/nfs4proc.c | 10 ++++++---- include/linux/sunrpc/clnt.h | 1 + include/linux/sunrpc/xprt.h | 1 + net/sunrpc/clnt.c | 17 +++++++++++++++++ net/sunrpc/xprtrdma/backchannel.c | 16 ++++++++++++++++ net/sunrpc/xprtrdma/transport.c | 1 + net/sunrpc/xprtrdma/xprt_rdma.h | 1 + net/sunrpc/xprtsock.c | 6 ++++++ 8 files changed, 49 insertions(+), 4 deletions(-) commit 4b9c7f9db9a003f5c342184dc4401c1b7f2efb39 Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon May 2 14:40:31 2016 -0400 sunrpc: Update RPCBIND_MAXNETIDLEN Commit 176e21ee2ec8 ("SUNRPC: Support for RPC over AF_LOCAL transports") added a 5-character netid, but did not bump RPCBIND_MAXNETIDLEN from 4 to 5. Fixes: 176e21ee2ec8 ("SUNRPC: Support for RPC over AF_LOCAL ...") Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/msg_prot.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 181342c5ebe8cc31f75b80ace18ae8a89a0c145a Author: Shirley Ma <shirley.ma@oracle.com> Date: Mon May 2 14:40:23 2016 -0400 xprtrdma: Add rdma6 option to support NFS/RDMA IPv6 RFC 5666: The "rdma" netid is to be used when IPv4 addressing is employed by the underlying transport, and "rdma6" for IPv6 addressing. Add mount -o proto=rdma6 option to support NFS/RDMA IPv6 addressing. Changes from v2: - Integrated comments from Chuck Level, Anna Schumaker, Trodt Myklebust - Add a little more to the patch description to describe NFS/RDMA IPv6 suggested by Chuck Level and Anna Schumaker - Removed duplicated rdma6 define - Remove Opt_xprt_rdma mountfamily since it doesn't support Signed-off-by: Shirley Ma <shirley.ma@oracle.com> Reviewed-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/super.c | 4 ++++ 1 file changed, 4 insertions(+) commit a1d1c4f11adf8a0036cd40a643543047fc952eb6 Author: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> Date: Thu May 12 11:16:38 2016 +0200 nfs4: client: do not send empty SETATTR after OPEN_CREATE OPEN_CREATE with EXCLUSIVE4_1 sends initial file permission. Ignoring fact, that server have indicated that file mod is set, client will send yet another SETATTR request, but, as mode is already set, new SETATTR will be empty. This is not a problem, nevertheless an extra roundtrip and slow open on high latency networks. This change is aims to skip extra setattr after open if there are no attributes to be set. Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/nfs4proc.c | 34 +++++++++++++++++++++++++--------- 1 file changed, 25 insertions(+), 9 deletions(-) commit 2e72448b07dc3ff1b7593e9bfff91db182262857 Author: Anna Schumaker <Anna.Schumaker@netapp.com> Date: Tue May 21 16:53:03 2013 -0400 NFS: Add COPY nfs operation This adds the copy_range file_ops function pointer used by the sys_copy_range() function call. This patch only implements sync copies, so if an async copy happens we decode the stateid and ignore it. Signed-off-by: Anna Schumaker <bjschuma@netapp.com> fs/nfs/nfs42.h | 1 + fs/nfs/nfs42proc.c | 105 +++++++++++++++++++++++++++++++++ fs/nfs/nfs42xdr.c | 146 ++++++++++++++++++++++++++++++++++++++++++++++ fs/nfs/nfs4file.c | 23 ++++++++ fs/nfs/nfs4proc.c | 1 + fs/nfs/nfs4xdr.c | 1 + include/linux/nfs4.h | 1 + include/linux/nfs_fs_sb.h | 1 + include/linux/nfs_xdr.h | 26 +++++++++ 9 files changed, 305 insertions(+) commit 67911c8f18b595040f5c2df0550c69a7c9397891 Author: Anna Schumaker <Anna.Schumaker@Netapp.com> Date: Tue Jan 19 14:37:30 2016 -0500 NFS: Add nfs_commit_file() Copy will use this to set up a commit request for a generic range. I don't want to allocate a new pagecache entry for the file, so I needed to change parts of the commit path to handle requests with a null wb_page. Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/internal.h | 1 + fs/nfs/pagelist.c | 6 ++++-- fs/nfs/write.c | 41 +++++++++++++++++++++++++++++++++++++---- 3 files changed, 42 insertions(+), 6 deletions(-) commit c2985d001d2fb77357aeae675545893b61c50044 Author: Olga Kornievskaia <kolga@netapp.com> Date: Tue May 10 16:57:41 2016 -0400 Fixing oops in callback path Commit 80f9642724af5 ("NFSv4.x: Enforce the ca_maxreponsesize_cached on the back channel") causes an oops when it receives a callback with cachethis=yes. [ 109.667378] BUG: unable to handle kernel NULL pointer dereference at 00000000000002c8 [ 109.669476] IP: [<ffffffffa08a3e68>] nfs4_callback_compound+0x4f8/0x690 [nfsv4] [ 109.671216] PGD 0 [ 109.671736] Oops: 0000 [#1] SMP [ 109.705427] CPU: 1 PID: 3579 Comm: nfsv4.1-svc Not tainted 4.5.0-rc1+ #1 [ 109.706987] Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 05/20/2014 [ 109.709468] task: ffff8800b4408000 ti: ffff88008448c000 task.ti: ffff88008448c000 [ 109.711207] RIP: 0010:[<ffffffffa08a3e68>] [<ffffffffa08a3e68>] nfs4_callback_compound+0x4f8/0x690 [nfsv4] [ 109.713521] RSP: 0018:ffff88008448fca0 EFLAGS: 00010286 [ 109.714762] RAX: ffff880081ee202c RBX: ffff8800b7b5b600 RCX: 0000000000000001 [ 109.716427] RDX: 0000000000000008 RSI: 0000000000000008 RDI: 0000000000000000 [ 109.718091] RBP: ffff88008448fda8 R08: 0000000000000000 R09: 000000000b000000 [ 109.719757] R10: ffff880137786000 R11: ffff8800b7b5b600 R12: 0000000001000000 [ 109.721415] R13: 0000000000000002 R14: 0000000053270000 R15: 000000000000000b [ 109.723061] FS: 0000000000000000(0000) GS:ffff880139640000(0000) knlGS:0000000000000000 [ 109.724931] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 109.726278] CR2: 00000000000002c8 CR3: 0000000034d50000 CR4: 00000000001406e0 [ 109.727972] Stack: [ 109.728465] ffff880081ee202c ffff880081ee201c 000000008448fcc0 ffff8800baccb800 [ 109.730349] ffff8800baccc800 ffffffffa08d0380 0000000000000000 0000000000000000 [ 109.732211] ffff8800b7b5b600 0000000000000001 ffffffff81d073c0 ffff880081ee3090 [ 109.734056] Call Trace: [ 109.734657] [<ffffffffa03795d4>] svc_process_common+0x5c4/0x6c0 [sunrpc] [ 109.736267] [<ffffffffa0379a4c>] bc_svc_process+0x1fc/0x360 [sunrpc] [ 109.737775] [<ffffffffa08a2c2c>] nfs41_callback_svc+0x10c/0x1d0 [nfsv4] [ 109.739335] [<ffffffff810cb380>] ? prepare_to_wait_event+0xf0/0xf0 [ 109.740799] [<ffffffffa08a2b20>] ? nfs4_callback_svc+0x50/0x50 [nfsv4] [ 109.742349] [<ffffffff810a6998>] kthread+0xd8/0xf0 [ 109.743495] [<ffffffff810a68c0>] ? kthread_park+0x60/0x60 [ 109.744776] [<ffffffff816abc4f>] ret_from_fork+0x3f/0x70 [ 109.746037] [<ffffffff810a68c0>] ? kthread_park+0x60/0x60 [ 109.747324] Code: cc 45 31 f6 48 8b 85 00 ff ff ff 44 89 30 48 8b 85 f8 fe ff ff 44 89 20 48 8b 9d 38 ff ff ff 48 8b bd 30 ff ff ff 48 85 db 74 4c <4c> 8b af c8 02 00 00 4d 8d a5 08 02 00 00 49 81 c5 98 02 00 00 [ 109.754361] RIP [<ffffffffa08a3e68>] nfs4_callback_compound+0x4f8/0x690 [nfsv4] [ 109.756123] RSP <ffff88008448fca0> [ 109.756951] CR2: 00000000000002c8 [ 109.757738] ---[ end trace 2b8555511ab5dfb4 ]--- [ 109.758819] Kernel panic - not syncing: Fatal exception [ 109.760126] Kernel Offset: disabled [ 118.938934] ---[ end Kernel panic - not syncing: Fatal exception It doesn't unlock the table nor does it set the cps->clp pointer which is later needed by nfs4_cb_free_slot(). Fixes: 80f9642724af5 ("NFSv4.x: Enforce the ca_maxresponsesize_cached ...") CC: stable@vger.kernel.org Signed-off-by: Olga Kornievskaia <kolga@netapp.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/callback_proc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit e257ef55ce51d7ec399193ee85acda8b8759d930 Merge: 45604e6 c5076cf bdd7444 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Tue May 17 14:35:46 2016 -0500 Merge branches 'pci/arm64' and 'pci/host-hv' into next * pci/arm64: PCI, of: Move PCI I/O space management to PCI core code PCI: generic, thunder: Use generic ECAM API PCI: Provide common functions for ECAM mapping * pci/host-hv: PCI: hv: Add explicit barriers to config space access commit 45604e68ed7acf23e6c4cbac9930c61df19220c8 Merge: d9322d2 f841522 ad67b43 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Tue May 17 14:35:38 2016 -0500 Merge branches 'pci/hotplug' and 'pci/resource' into next * pci/hotplug: PCI: Use cached copy of PCI_EXP_SLTCAP_HPC bit * pci/resource: PCI: Disable all BAR sizing for devices with non-compliant BARs x86/PCI: Mark Broadwell-EP Home Agent 1 as having non-compliant BARs PCI: Identify Enhanced Allocation (EA) BAR Equivalent resources in sysfs commit 897fba1172d637d344f009d700f7eb8a1fa262f1 Author: Steve French <smfrench@gmail.com> Date: Thu May 12 21:20:36 2016 -0500 remove directory incorrectly tries to set delete on close on non-empty directories Wrong return code was being returned on SMB3 rmdir of non-empty directory. For SMB3 (unlike for cifs), we attempt to delete a directory by set of delete on close flag on the open. Windows clients set this flag via a set info (SET_FILE_DISPOSITION to set this flag) which properly checks if the directory is empty. With this patch on smb3 mounts we correctly return "DIRECTORY NOT EMPTY" on attempts to remove a non-empty directory. Signed-off-by: Steve French <steve.french@primarydata.com> CC: Stable <stable@vger.kernel.org> Acked-by: Sachin Prabhu <sprabhu@redhat.com> fs/cifs/smb2glob.h | 1 + fs/cifs/smb2inode.c | 8 ++++++-- fs/cifs/smb2pdu.c | 16 ++++++++++++++++ fs/cifs/smb2proto.h | 2 ++ 4 files changed, 25 insertions(+), 2 deletions(-) commit 5a4f7e8e7ff5e81f57b08797cca41d307878dfc7 Author: Steve French <smfrench@gmail.com> Date: Tue May 10 08:24:05 2016 -0500 Update cifs.ko version to 2.09 Signed-off-by: Steven French <steve.french@primarydata.com> fs/cifs/cifsfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1a967d6c9b39c226be1b45f13acd4d8a5ab3dc44 Author: Stefan Metzmacher <metze@samba.org> Date: Tue May 3 10:52:30 2016 +0200 fs/cifs: correctly to anonymous authentication for the NTLM(v2) authentication Only server which map unknown users to guest will allow access using a non-null NTLMv2_Response. For Samba it's the "map to guest = bad user" option. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11913 Signed-off-by: Stefan Metzmacher <metze@samba.org> CC: Stable <stable@vger.kernel.org> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/sess.c | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) commit 777f69b8d26bf35ade4a76b08f203c11e048365d Author: Stefan Metzmacher <metze@samba.org> Date: Tue May 3 10:52:30 2016 +0200 fs/cifs: correctly to anonymous authentication for the NTLM(v1) authentication Only server which map unknown users to guest will allow access using a non-null NTChallengeResponse. For Samba it's the "map to guest = bad user" option. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11913 Signed-off-by: Stefan Metzmacher <metze@samba.org> CC: Stable <stable@vger.kernel.org> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/sess.c | 41 +++++++++++++++++++++++------------------ 1 file changed, 23 insertions(+), 18 deletions(-) commit fa8f3a354bb775ec586e4475bcb07f7dece97e0c Author: Stefan Metzmacher <metze@samba.org> Date: Tue May 3 10:52:30 2016 +0200 fs/cifs: correctly to anonymous authentication for the LANMAN authentication Only server which map unknown users to guest will allow access using a non-null LMChallengeResponse. For Samba it's the "map to guest = bad user" option. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11913 Signed-off-by: Stefan Metzmacher <metze@samba.org> CC: Stable <stable@vger.kernel.org> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/sess.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) commit cfda35d98298131bf38fbad3ce4cd5ecb3cf18db Author: Stefan Metzmacher <metze@samba.org> Date: Tue May 3 10:52:30 2016 +0200 fs/cifs: correctly to anonymous authentication via NTLMSSP See [MS-NLMP] 3.2.5.1.2 Server Receives an AUTHENTICATE_MESSAGE from the Client: ... Set NullSession to FALSE If (AUTHENTICATE_MESSAGE.UserNameLen == 0 AND AUTHENTICATE_MESSAGE.NtChallengeResponse.Length == 0 AND (AUTHENTICATE_MESSAGE.LmChallengeResponse == Z(1) OR AUTHENTICATE_MESSAGE.LmChallengeResponse.Length == 0)) -- Special case: client requested anonymous authentication Set NullSession to TRUE ... Only server which map unknown users to guest will allow access using a non-null NTChallengeResponse. For Samba it's the "map to guest = bad user" option. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11913 CC: Stable <stable@vger.kernel.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/sess.c | 32 ++++++++++++++++++++------------ 1 file changed, 20 insertions(+), 12 deletions(-) commit 11e31647c9263185cfd990db656dbb7f06697faf Author: Sachin Prabhu <sprabhu@redhat.com> Date: Mon Feb 8 13:44:01 2016 +0530 cifs: remove any preceding delimiter from prefix_path We currently do not check if any delimiter exists before the prefix path in cifs_compose_mount_options(). Consequently when building the devname using cifs_build_devname() we can end up with multiple delimiters separating the UNC and the prefix path. An issue was reported by the customer mounting a folder within a DFS share from a Netapp server which uses McAfee antivirus. We have narrowed down the cause to the use of double backslashes in the file name used to open the file. This was determined to be caused because of additional delimiters as a result of the bug. In addition to changes in cifs_build_devname(), we also fix cifs_parse_devname() to ignore any preceding delimiter for the prefix path. The problem was originally reported on RHEL 6 in RHEL bz 1252721. This is the upstream version of the fix. The fix was confirmed by looking at the packet capture of a DFS mount. Signed-off-by: Sachin Prabhu <sprabhu@redhat.com> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/cifs_dfs_ref.c | 6 +++++- fs/cifs/connect.c | 8 ++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) commit 1f1735cb75ab31ed948a7fce65beaaa6c0ed4ed4 Author: Goldwyn Rodrigues <rgoldwyn@suse.com> Date: Mon Apr 18 06:41:52 2016 -0500 cifs: Use file_dentry() CIFS may be used as lower layer of overlayfs and accessing f_path.dentry can lead to a crash. Fix by replacing direct access of file->f_path.dentry with the file_dentry() accessor, which will always return a native object. Signed-off-by: Goldwyn Rodrigues <rgoldwyn@suse.com> Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Signed-off-by: Steve French <smfrench@gmail.com> fs/cifs/file.c | 4 ++-- fs/cifs/readdir.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 917fa5353da05e8a0045b8acacba8d50400d5b12 Author: David S. Miller <davem@davemloft.net> Date: Tue May 17 14:49:55 2016 -0400 Revert "phy dp83867: Fix compilation with CONFIG_OF_MDIO=m" This reverts commit 7f32541c2fdaa84af418c3e1431bbd066ab44d09. This needs reverting too, as per requests. Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/dp83867.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c606b4999b8b11600baabab6a18fb02d296569a3 Author: David S. Miller <davem@davemloft.net> Date: Tue May 17 14:49:24 2016 -0400 Revert "phy dp83867: Make rgmii parameters optional" This reverts commit 81003bc924bac0a99bfdc2869f5dff5a87aa4a3d. Developers have asked me to revert this for now. Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/dp83867.c | 31 +++---------------------------- 1 file changed, 3 insertions(+), 28 deletions(-) commit 27896c83fe94e2190f121a2fdbffffbf1d83d573 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Sat May 14 22:40:15 2016 +0200 r8169: default to 64-bit DMA on recent PCIe chips The current logic around the 'use_dac' module parameter prevents the r81969 driver from being loadable on 64-bit systems without any RAM below 4 GB when the parameter is left at its default value. So introduce a new default value -1 which indicates that 64-bit DMA should be enabled on sufficiently recent PCIe chips, i.e., versions RTL_GIGA_MAC_VER_18 or later. Explicit param values of 0 or 1 retain the existing behavior of unconditionally enabling/disabling 64-bit DMA on 64-bit architectures (i.e., regardless of the type and version of the chip) Since PCIe chips do not need to CPlusCmd Dual Address Cycle to be set, make that conditional on the device type as well. Cc: Realtek linux nic maintainers <nic_swsd@realtek.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/realtek/r8169.c | 44 ++++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 19 deletions(-) commit 81003bc924bac0a99bfdc2869f5dff5a87aa4a3d Author: Alexander Graf <agraf@suse.de> Date: Mon May 16 20:52:43 2016 +0200 phy dp83867: Make rgmii parameters optional If you compile without OF_MDIO support in an RGMII configuration, we fail to configure the dp83867 phy today by writing garbage into its configuration registers. On the other hand if you do compile with OF_MDIO and the phy gets loaded via device tree, you have to have the properties set in the device tree, otherwise we fail to load the driver and don't even attach the generic phy driver to the interface anymore. To make things slightly more consistent, make the rgmii configuration properties optional and allow a user to omit them in their device tree. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/dp83867.c | 31 ++++++++++++++++++++++++++++--- 1 file changed, 28 insertions(+), 3 deletions(-) commit 7f32541c2fdaa84af418c3e1431bbd066ab44d09 Author: Alexander Graf <agraf@suse.de> Date: Mon May 16 20:52:42 2016 +0200 phy dp83867: Fix compilation with CONFIG_OF_MDIO=m When CONFIG_OF_MDIO is configured as module, the #define for it really is CONFIG_OF_MDIO_MODULE, not CONFIG_OF_MDIO. So if we are compiling it as module, the dp83867 doesn't see that OF_MDIO was selected and doesn't read the dt rgmii parameters. The fix is simple: Use IS_ENABLED(). It checks for both - module as well as compiled in code. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/dp83867.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 08a6ee5807711c4dfa0726e315864a408aa6c13c Merge: 4c1cd4f f79a917 Author: David S. Miller <davem@davemloft.net> Date: Tue May 17 14:11:19 2016 -0400 Merge tag 'net-next-qcom-soc-4.7-2-merge' of git://github.com/andersson/kernel Merge tag 'qcom-soc-for-4.7-2' into net-next This merges the Qualcomm SOC tree with the net-next, solving the merge conflict in the SMD API between the two. commit 4c1cd4fdfd14ecd417962f8c2166506132697f7c Author: Yang Shi <yang.shi@linaro.org> Date: Mon May 16 16:36:26 2016 -0700 bpf: arm64: remove callee-save registers use for tmp registers In the current implementation of ARM64 eBPF JIT, R23 and R24 are used for tmp registers, which are callee-saved registers. This leads to variable size of JIT prologue and epilogue. The latest blinding constant change prefers to constant size of prologue and epilogue. AAPCS reserves R9 ~ R15 for temp registers which not need to be saved/restored during function call. So, replace R23 and R24 to R10 and R11, and remove tmp_used flag to save 2 instructions for some jited BPF program. CC: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Zi Shen Lim <zlim.lnx@gmail.com> Signed-off-by: Yang Shi <yang.shi@linaro.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/net/bpf_jit_comp.c | 34 +++++----------------------------- 1 file changed, 5 insertions(+), 29 deletions(-) commit cd9e2e5d3ff148be9ea210f622ce3e8e8292fcd6 Author: John Stultz <john.stultz@linaro.org> Date: Mon May 16 20:36:15 2016 -0700 asix: Fix offset calculation in asix_rx_fixup() causing slow transmissions In testing with HiKey, we found that since commit 3f30b158eba5 ("asix: On RX avoid creating bad Ethernet frames"), we're seeing lots of noise during network transfers: [ 239.027993] asix 1-1.1:1.0 eth0: asix_rx_fixup() Data Header synchronisation was lost, remaining 988 [ 239.037310] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0x54ebb5ec, offset 4 [ 239.045519] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0xcdffe7a2, offset 4 [ 239.275044] asix 1-1.1:1.0 eth0: asix_rx_fixup() Data Header synchronisation was lost, remaining 988 [ 239.284355] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0x1d36f59d, offset 4 [ 239.292541] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0xaef3c1e9, offset 4 [ 239.518996] asix 1-1.1:1.0 eth0: asix_rx_fixup() Data Header synchronisation was lost, remaining 988 [ 239.528300] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0x2881912, offset 4 [ 239.536413] asix 1-1.1:1.0 eth0: asix_rx_fixup() Bad Header Length 0x5638f7e2, offset 4 And network throughput ends up being pretty bursty and slow with a overall throughput of at best ~30kB/s (where as previously we got 1.1MB/s with the slower USB1.1 "full speed" host). We found the issue also was reproducible on a x86_64 system, using a "high-speed" USB2.0 port but the throughput did not measurably drop (possibly due to the scp transfer being cpu bound on my slow test hardware). After lots of debugging, I found the check added in the problematic commit seems to be calculating the offset incorrectly. In the normal case, in the main loop of the function, we do: (where offset is zero, or set to "offset += (copy_length + 1) & 0xfffe" in the previous loop) rx->header = get_unaligned_le32(skb->data + offset); offset += sizeof(u32); But the problematic patch calculates: offset = ((rx->remaining + 1) & 0xfffe) + sizeof(u32); rx->header = get_unaligned_le32(skb->data + offset); Adding some debug logic to check those offset calculation used to find rx->header, the one in problematic code is always too large by sizeof(u32). Thus, this patch removes the incorrect " + sizeof(u32)" addition in the problematic calculation, and resolves the issue. Cc: Dean Jenkins <Dean_Jenkins@mentor.com> Cc: "David B. Robins" <linux@davidrobins.net> Cc: Mark Craske <Mark_Craske@mentor.com> Cc: Emil Goode <emilgoode@gmail.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: YongQin Liu <yongqin.liu@linaro.org> Cc: Guodong Xu <guodong.xu@linaro.org> Cc: Ivan Vecera <ivecera@redhat.com> Cc: linux-usb@vger.kernel.org Cc: netdev@vger.kernel.org Cc: stable <stable@vger.kernel.org> #4.4+ Reported-by: Yongqin Liu <yongqin.liu@linaro.org> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/asix_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7f427d3a6029331304f91ef4d7cf646f054216d2 Merge: ede4090 0e0162b Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 11:01:31 2016 -0700 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull parallel filesystem directory handling update from Al Viro. This is the main parallel directory work by Al that makes the vfs layer able to do lookup and readdir in parallel within a single directory. That's a big change, since this used to be all protected by the directory inode mutex. The inode mutex is replaced by an rwsem, and serialization of lookups of a single name is done by a "in-progress" dentry marker. The series begins with xattr cleanups, and then ends with switching filesystems over to actually doing the readdir in parallel (switching to the "iterate_shared()" that only takes the read lock). A more detailed explanation of the process from Al Viro: "The xattr work starts with some acl fixes, then switches ->getxattr to passing inode and dentry separately. This is the point where the things start to get tricky - that got merged into the very beginning of the -rc3-based #work.lookups, to allow untangling the security_d_instantiate() mess. The xattr work itself proceeds to switch a lot of filesystems to generic_...xattr(); no complications there. After that initial xattr work, the series then does the following: - untangle security_d_instantiate() - convert a bunch of open-coded lookup_one_len_unlocked() to calls of that thing; one such place (in overlayfs) actually yields a trivial conflict with overlayfs fixes later in the cycle - overlayfs ended up switching to a variant of lookup_one_len_unlocked() sans the permission checks. I would've dropped that commit (it gets overridden on merge from #ovl-fixes in #for-next; proper resolution is to use the variant in mainline fs/overlayfs/super.c), but I didn't want to rebase the damn thing - it was fairly late in the cycle... - some filesystems had managed to depend on lookup/lookup exclusion for *fs-internal* data structures in a way that would break if we relaxed the VFS exclusion. Fixing hadn't been hard, fortunately. - core of that series - parallel lookup machinery, replacing ->i_mutex with rwsem, making lookup_slow() take it only shared. At that point lookups happen in parallel; lookups on the same name wait for the in-progress one to be done with that dentry. Surprisingly little code, at that - almost all of it is in fs/dcache.c, with fs/namei.c changes limited to lookup_slow() - making it use the new primitive and actually switching to locking shared. - parallel readdir stuff - first of all, we provide the exclusion on per-struct file basis, same as we do for read() vs lseek() for regular files. That takes care of most of the needed exclusion in readdir/readdir; however, these guys are trickier than lookups, so I went for switching them one-by-one. To do that, a new method '->iterate_shared()' is added and filesystems are switched to it as they are either confirmed to be OK with shared lock on directory or fixed to be OK with that. I hope to kill the original method come next cycle (almost all in-tree filesystems are switched already), but it's still not quite finished. - several filesystems get switched to parallel readdir. The interesting part here is dealing with dcache preseeding by readdir; that needs minor adjustment to be safe with directory locked only shared. Most of the filesystems doing that got switched to in those commits. Important exception: NFS. Turns out that NFS folks, with their, er, insistence on VFS getting the fuck out of the way of the Smart Filesystem Code That Knows How And What To Lock(tm) have grown the locking of their own. They had their own homegrown rwsem, with lookup/readdir/atomic_open being *writers* (sillyunlink is the reader there). Of course, with VFS getting the fuck out of the way, as requested, the actual smarts of the smart filesystem code etc. had become exposed... - do_last/lookup_open/atomic_open cleanups. As the result, open() without O_CREAT locks the directory only shared. Including the ->atomic_open() case. Backmerge from #for-linus in the middle of that - atomic_open() fix got brought in. - then comes NFS switch to saner (VFS-based ;-) locking, killing the homegrown "lookup and readdir are writers" kinda-sorta rwsem. All exclusion for sillyunlink/lookup is done by the parallel lookups mechanism. Exclusion between sillyunlink and rmdir is a real rwsem now - rmdir being the writer. Result: NFS lookups/readdirs/O_CREAT-less opens happen in parallel now. - the rest of the series consists of switching a lot of filesystems to parallel readdir; in a lot of cases ->llseek() gets simplified as well. One backmerge in there (again, #for-linus - rockridge fix)" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (74 commits) ext4: switch to ->iterate_shared() hfs: switch to ->iterate_shared() hfsplus: switch to ->iterate_shared() hostfs: switch to ->iterate_shared() hpfs: switch to ->iterate_shared() hpfs: handle allocation failures in hpfs_add_pos() gfs2: switch to ->iterate_shared() f2fs: switch to ->iterate_shared() afs: switch to ->iterate_shared() befs: switch to ->iterate_shared() befs: constify stuff a bit isofs: switch to ->iterate_shared() get_acorn_filename(): deobfuscate a bit btrfs: switch to ->iterate_shared() logfs: no need to lock directory in lseek switch ecryptfs to ->iterate_shared 9p: switch to ->iterate_shared() fat: switch to ->iterate_shared() romfs, squashfs: switch to ->iterate_shared() more trivial ->iterate_shared conversions ... commit da4ed55165d41b1073f9a476f1c18493e9bf8c8e Author: Jiri Pirko <jiri@mellanox.com> Date: Tue May 17 18:58:08 2016 +0200 switchdev: pass pointer to fib_info instead of copy The problem is that fib_info->nh is [0] so the struct fib_info allocation size depends on number of nexthops. If we just copy fib_info, we do not copy the nexthops info and driver accesses memory which is not ours. Given the fact that fib4 does not defer operations and therefore it does not need copy, just pass the pointer down to drivers as it was done before. Fixes: 850d0cbc91 ("switchdev: remove pointers from switchdev objects") Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/rocker/rocker_ofdpa.c | 4 ++-- include/net/switchdev.h | 2 +- net/switchdev/switchdev.c | 6 ++---- 3 files changed, 5 insertions(+), 7 deletions(-) commit ede40902cf80714ece199977b308e2ee437cae0b Merge: 91e8d0c 0097852 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 10:27:29 2016 -0700 Merge branch 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull irq updates from Thomas Gleixner: "This update delivers: - Yet another interrupt chip diver (LPC32xx) - Core functions to handle partitioned per-cpu interrupts - Enhancements to the IPI core - Proper handling of irq type configuration - A large set of ARM GIC enhancements - The usual pile of small fixes, cleanups and enhancements" * 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (31 commits) irqchip/bcm2836: Use a more generic memory barrier call irqchip/bcm2836: Fix compiler warning on 64-bit build irqchip/bcm2836: Drop smp_set_ops on arm64 builds irqchip/gic: Add helper functions for GIC setup and teardown irqchip/gic: Store GIC configuration parameters irqchip/gic: Pass GIC pointer to save/restore functions irqchip/gic: Return an error if GIC initialisation fails irqchip/gic: Remove static irq_chip definition for eoimode1 irqchip/gic: Don't initialise chip if mapping IO space fails irqchip/gic: WARN if setting the interrupt type for a PPI fails irqchip/gic: Don't unnecessarily write the IRQ configuration irqchip: Mask the non-type/sense bits when translating an IRQ genirq: Ensure IRQ descriptor is valid when setting-up the IRQ irqchip/gic-v3: Configure all interrupts as non-secure Group-1 irqchip/gic-v2m: Add workaround for Broadcom NS2 GICv2m erratum irqchip/irq-alpine-msi: Don't use <asm-generic/msi.h> irqchip/mbigen: Checking for IS_ERR() instead of NULL irqchip/gic-v3: Remove inexistant register definition irqchip/gicv3-its: Don't allow devices whose ID is outside range irqchip: Add LPC32xx interrupt controller driver ... commit ec4c436652cfdf5dcad60f553020ee99596b937b Author: Mark Brown <broonie@kernel.org> Date: Tue May 17 18:06:18 2016 +0100 regulator: Silence build warnings from regulator_can_change_voltage() Cut down on noise for mainstream users of the API and people doing build testing by dropping the deprecated flag from regulator_can_change_voltage() as it triggers even on the EXPORT_SYMBOL_GPL() which affects all builds rather than just the remaining drivers with calls to it (for which fixes are currently pending). The function remains deprecated and is expected to be removed entirely in v4.8. Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/regulator/consumer.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 91e8d0cbc94f81f110e508c3105dd93fb146d6b5 Merge: 2fe2edf 9999c5f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 09:49:28 2016 -0700 Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull timer updates from Thomas Gleixner: "A rather small set of patches from the timer departement: - Some more y2038 work - Yet another new clocksource driver - The usual set of small fixes, cleanups and enhancements" * 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: clocksource/drivers/tegra: Remove unused suspend/resume code clockevents/driversi/mps2: add MPS2 Timer driver dt-bindings: document the MPS2 timer bindings clocksource/drivers/mtk_timer: Add __init attribute clockevents/drivers/dw_apb_timer: Implement ->set_state_oneshot_stopped() time: Introduce do_sys_settimeofday64() security: Introduce security_settime64() clocksource: Add missing include of of.h. commit 2fe2edf85ffe51fddb800bb0b332c7ae454a6db3 Merge: 9a07a79 59643d1 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 09:42:58 2016 -0700 Merge tag 'trace-fixes-v4.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing ring-buffer fixes from Steven Rostedt: "Hao Qin reported an integer overflow possibility with signed and unsigned numbers in the ring-buffer code. https://bugzilla.kernel.org/show_bug.cgi?id=118001 At first I did not think this was too much of an issue, because the overflow would be caught later when either too much data was allocated or it would trigger RB_WARN_ON() which shuts down the ring buffer. But looking closer into it, I found that the right settings could bypass the checks and crash the kernel. Luckily, this is only accessible by root. The first fix is to convert all the variables into long, such that we don't get into issues between 32 bit variables being assigned 64 bit ones. This fixes the RB_WARN_ON() triggering. The next fix is to get rid of a duplicate DIV_ROUND_UP() that when called twice with the right value, can cause a kernel crash. The first DIV_ROUND_UP() is to normalize the input and it is checked against the minimum allowable value. But then DIV_ROUND_UP() is called again, which can overflow due to the (a + b - 1)/b, logic. The first called upped the value, the second can overflow (with the +b part). The second call to DIV_ROUND_UP() came in via a second change a while ago and the code is cleaned up to remove it" * tag 'trace-fixes-v4.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: ring-buffer: Prevent overflow of size in ring_buffer_resize() ring-buffer: Use long for nr_pages to avoid overflow failures commit dc327f8931cb9d66191f489eb9a852fc04530546 Author: WANG Cong <xiyou.wangcong@gmail.com> Date: Mon May 16 15:11:18 2016 -0700 net_sched: close another race condition in tcf_mirred_release() We saw the following extra refcount release on veth device: kernel: [7957821.463992] unregister_netdevice: waiting for mesos50284 to become free. Usage count = -1 Since we heavily use mirred action to redirect packets to veth, I think this is caused by the following race condition: CPU0: tcf_mirred_release(): (in RCU callback) struct net_device *dev = rcu_dereference_protected(m->tcfm_dev, 1); CPU1: mirred_device_event(): spin_lock_bh(&mirred_list_lock); list_for_each_entry(m, &mirred_list, tcfm_list) { if (rcu_access_pointer(m->tcfm_dev) == dev) { dev_put(dev); /* Note : no rcu grace period necessary, as * net_device are already rcu protected. */ RCU_INIT_POINTER(m->tcfm_dev, NULL); } } spin_unlock_bh(&mirred_list_lock); CPU0: tcf_mirred_release(): spin_lock_bh(&mirred_list_lock); list_del(&m->tcfm_list); spin_unlock_bh(&mirred_list_lock); if (dev) // <======== Stil refers to the old m->tcfm_dev dev_put(dev); // <======== dev_put() is called on it again The action init code path is good because it is impossible to modify an action that is being removed. So, fix this by moving everything under the spinlock. Fixes: 2ee22a90c7af ("net_sched: act_mirred: remove spinlock in fast path") Fixes: 6bd00b850635 ("act_mirred: fix a race condition on mirred_list") Cc: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com> Acked-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sched/act_mirred.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 03aaaa9b941e136757b55c4cf775aab6068dfd94 Author: Richard Alpe <richard.alpe@ericsson.com> Date: Tue May 17 16:57:37 2016 +0200 tipc: fix nametable publication field in nl compat The publication field of the old netlink API should contain the publication key and not the publication reference. Fixes: 44a8ae94fd55 (tipc: convert legacy nl name table dump to nl compat) Signed-off-by: Richard Alpe <richard.alpe@ericsson.com> Acked-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/netlink_compat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9a07a7968407e20fe87ed6b5eb6a6000e4819492 Merge: 1649098 256b1cf Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Tue May 17 09:33:39 2016 -0700 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto update from Herbert Xu: "API: - Crypto self tests can now be disabled at boot/run time. - Add async support to algif_aead. Algorithms: - A large number of fixes to MPI from Nicolai Stange. - Performance improvement for HMAC DRBG. Drivers: - Use generic crypto engine in omap-des. - Merge ppc4xx-rng and crypto4xx drivers. - Fix lockups in sun4i-ss driver by disabling IRQs. - Add DMA engine support to ccp. - Reenable talitos hash algorithms. - Add support for Hisilicon SoC RNG. - Add basic crypto driver for the MXC SCC. Others: - Do not allocate crypto hash tfm in NORECLAIM context in ecryptfs" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (77 commits) crypto: qat - change the adf_ctl_stop_devices to void crypto: caam - fix caam_jr_alloc() ret code crypto: vmx - comply with ABIs that specify vrsave as reserved. crypto: testmgr - Add a flag allowing the self-tests to be disabled at runtime. crypto: ccp - constify ccp_actions structure crypto: marvell/cesa - Use dma_pool_zalloc crypto: qat - make adf_vf_isr.c dependant on IOV config crypto: qat - Fix typo in comments lib: asn1_decoder - add MODULE_LICENSE("GPL") crypto: omap-sham - Use dma_request_chan() for requesting DMA channel crypto: omap-des - Use dma_request_chan() for requesting DMA channel crypto: omap-aes - Use dma_request_chan() for requesting DMA channel crypto: omap-des - Integrate with the crypto engine framework crypto: s5p-sss - fix incorrect usage of scatterlists api crypto: s5p-sss - Fix missed interrupts when working with 8 kB blocks crypto: s5p-sss - Use common BIT macro crypto: mxc-scc - fix unwinding in mxc_scc_crypto_register() crypto: mxc-scc - signedness bugs in mxc_scc_ablkcipher_req_init() crypto: talitos - fix ahash algorithms registration crypto: ccp - Ensure all dependencies are specified ... commit 3274940bd3d87043c74aa444ff3b0dff56b3e9ea Author: Harvey Hunt <harvey.hunt@imgtec.com> Date: Tue May 17 14:33:27 2016 +0100 drivers: net: Don't print unpopulated net_device name For ethernet devices, net_device.name will be eth%d before register_netdev() is called. Don't print the net_device name until the format string is replaced. Signed-off-by: Harvey Hunt <harvey.hunt@imgtec.com> Cc: Marcel Ziswiler <marcel@ziswiler.com> Cc: Robert Jarzmik <robert.jarzmik@free.fr> Cc: Barry Song <Baohua.Song@csr.com> Cc: netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/davicom/dm9000.c | 11 +++++++---- drivers/net/ethernet/micrel/ks8695net.c | 7 +++++-- drivers/net/ethernet/netx-eth.c | 12 ++++++++---- 3 files changed, 20 insertions(+), 10 deletions(-) commit 39651abd28146fff2bfac63d68a7a56250a4aead Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Tue May 17 06:44:26 2016 -0400 qed: add support for dcbx. This patch adds the necessary driver support for Management Firmware to configure the device/firmware with the dcbx results. Management Firmware is responsible for communicating the DCBX and driving the negotiation, but the driver has responsibility of receiving async notification and configuring the results in hw/fw. This patch also adds the dcbx support for future protocols (e.g., FCoE) as preparation to their imminent submission. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/Makefile | 2 +- drivers/net/ethernet/qlogic/qed/qed.h | 2 + drivers/net/ethernet/qlogic/qed/qed_cxt.h | 10 + drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 562 ++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_dcbx.h | 80 +++ drivers/net/ethernet/qlogic/qed/qed_dev.c | 105 +++- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 21 +- drivers/net/ethernet/qlogic/qed/qed_mcp.c | 13 + drivers/net/ethernet/qlogic/qed/qed_sp.h | 13 + drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 25 + include/linux/qed/qed_if.h | 9 + 11 files changed, 834 insertions(+), 8 deletions(-) commit ccf928249c92b04ec9527e97a7c6b2cd8cd9dc10 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue May 17 11:05:34 2016 +0200 ravb: Add missing free_irq() calls to ravb_close() When reopening the network device on ra7795/salvator-x, e.g. after a DHCP timeout: IP-Config: Reopening network devices... genirq: Flags mismatch irq 139. 00000000 (eth0:ch0:rx_be) vs. 00000000 (ravb e6800000.ethernet eth0: cannot request IRQ eth0:ch0:rx_be IP-Config: Failed to open eth0 IP-Config: No network devices available The "mismatch" is due to requesting an IRQ that is already in use, while IRQF_PROBE_SHARED wasn't set. However, the real cause is that ravb_close() doesn't release any of the R-Car Gen3-specific secondary IRQs. Add the missing free_irq() calls to fix this. Fixes: f51bdc236b6c5835 ("ravb: Add dma queue interrupt support") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/ravb_main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit f82731b454a953b6ff2aa1f601f65dec52551600 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 17 11:09:20 2016 +0300 qed: Remove a stray tab This line was indented more than it should be. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2cc632dbc75d72f64bc3c966929c77306bd46a05 Merge: b172542 5eee87c Author: David S. Miller <davem@davemloft.net> Date: Tue May 17 12:18:27 2016 -0400 Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 10GbE Intel Wired LAN Driver Updates 2016-05-16 This series contains 2 fixes to ixgbe only. Emil fixes transmit hangs when enabling SRIOV by swapping the parameters in GENMASK in order to generate the correct mask. Alex fixes his previous patch b83e30104bd9 ("ixgbe/ixgbevf: Add support for GSO partial") where he somehow transposed the location of setting the VLAN features in netdev->features and the configuration of the vlan_features. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c7c5856b6f6f30de622bf87947363890b286553f Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Sun May 15 16:26:51 2016 +0530 sound: oss: Use setup_timer and mod_timer. The function setup_timer combines the initialization of a timer with the initialization of the timer's function and data fields. The mulitiline code for timer initialization is now replaced with function setup_timer. Also, quoting the mod_timer() function comment: -> mod_timer() is a more efficient way to update the expire field of an active timer (if the timer is inactive it will be activated). Use setup_timer() and mod_timer() to setup and arm a timer, making the code compact and aid readablity. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/oss/waveartist.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 57da0c042f4af52614f4bd1a148155a299ae5cd8 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Wed May 4 14:38:13 2016 +0300 mmc: block: Pause re-tuning while switched to the RPMB partition Re-tuning is not possible when switched to the RPMB partition. However re-tuning should not be needed if re-tuning is done immediately before switching, a small set of operations is done, and then we immediately switch back to the main partition. A previous patch ensured that we immediately switch back to the main partition. This patch uses the new facility to "pause" re-tuning before switching to the RPMB partition, and to "unpause" it after switching from the RPMB partition. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 3c866568aff7dcfc0bbd5ffc7fcc34fa8f100f67 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Wed May 4 14:38:12 2016 +0300 mmc: block: Always switch back to main area after RPMB access In preparation to support the use of the RPMB partition with transfer modes that might require re-tuning, always switch back to the main area after RPMB access. RPMB is accessible only via IOCTL so only those paths are affected. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 7ff2760999a86e4d2b1af93dcf0f0d336c309571 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Mon May 16 15:35:24 2016 +0300 mmc: core: Add a facility to "pause" re-tuning Re-tuning is not possible when switched to the RPMB partition. However re-tuning should not be needed if re-tuning is done immediately before switching, a small set of operations is done, and then we immediately switch back to the main partition. To ensure that re-tuning can't be done for a short while, add a facility to "pause" re-tuning. The existing facility to hold / release re-tuning is used but it also flags re-tuning as needed to cause re-tuning before the next command (which will be the switch to RPMB). We also need to "unpause" in the recovery path, which is catered for by adding it to mmc_retune_disable(). Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/host.c | 24 ++++++++++++++++++++++++ include/linux/mmc/host.h | 4 ++++ 2 files changed, 28 insertions(+) commit 431c30f74cdffba6456b52742e80f9b629228940 Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Tue May 3 17:40:08 2016 +0200 thermal: tango: initialize TEMPSI_CFG TEMPSI_CFG is not equal to 0 at reset. It must be initialized. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tango_thermal.c | 1 + 1 file changed, 1 insertion(+) commit 2fe5c1b0453c445f8a19e1a53f8297b21c2cba4c Author: Caesar Wang <wxt@rock-chips.com> Date: Tue May 3 10:23:50 2016 +0800 thermal: rockchip: use the usleep_range instead of udelay Documentation/timers/timers-howto.txt recommends to use usleep_range on delays > 10usec. The usleep_range indeed reduces CPU load, since the udelay will busy wait for enough loop cycles to achieve the desired delay. Fixes commit b06c52db39fd ("thermal: rockchip: handle the power sequence for tsadc controller"). Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Suggested-by: Eduardo Valentin <edubezval@gmail.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 678065d5b786763cb9f5d97673409ae32ead2314 Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Apr 18 11:35:58 2016 +0800 thermal: rockchip: add the notes for better reading To update the notes for keeping in mind that quickly in case someone re-read this driver in the future. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 74 +++++++++++++++++++++++++++----------- 1 file changed, 53 insertions(+), 21 deletions(-) commit 1cd602693740fafcf6e5e9ed3aa93f11924275cb Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Mon Apr 18 11:35:57 2016 +0800 thermal: rockchip: Support RK3366 SoCs in the thermal driver The RK3366 SoCs have two Temperature Sensors, channel 0 is for CPU channel 1 is for GPU. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit b948476327d8162e179b1b7fe73e68b48bbe4481 Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Apr 18 11:35:56 2016 +0800 thermal: rockchip: handle the power sequence for tsadc controller This adds the grf property to handle the tsadc power sequence on rockchip some SoCs. Verified on rk3399 can work with this patch on now. while true; do grep "" /sys/class/thermal/thermal_zone[0-1]/temp sleep .5; done /sys/class/thermal/thermal_zone0/temp:40555 /sys/class/thermal/thermal_zone1/temp:41111 /sys/class/thermal/thermal_zone0/temp:40555 /sys/class/thermal/thermal_zone1/temp:41111 /sys/class/thermal/thermal_zone0/temp:40555 /sys/class/thermal/thermal_zone1/temp:41666 /sys/class/thermal/thermal_zone0/temp:40555 /sys/class/thermal/thermal_zone1/temp:41111 /sys/class/thermal/thermal_zone0/temp:40555 /sys/class/thermal/thermal_zone1/temp:41111 /sys/class/thermal/thermal_zone0/temp:40555 Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 87 +++++++++++++++++++++++++++++++++++--- 1 file changed, 82 insertions(+), 5 deletions(-) commit f762a35d89cd6f62b4b8180983c91f46f7aecb7e Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Apr 18 11:35:55 2016 +0800 thermal: rockchip: update the tsadc table for rk3399 This patch fixes the incorrect conversion table. The Code to Temperature mapping is updated based on sillcon results. Fixes commit b0d70338bca22cb14 ("thermal: rockchip: Support the RK3399 SoCs in thermal driver"). Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 68 +++++++++++++++++++------------------- 1 file changed, 34 insertions(+), 34 deletions(-) commit a87dd79761764accbb5f66a6ff089701fbac4b32 Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Apr 18 11:35:54 2016 +0800 thermal: rockchip: fixes the code_to_temp for tsadc driver We should judge the table.id[mid].code insearch algorithm on matter the adc value increment or decrement. Or otherwise, the temperature return the incorrect value in some cases. [ 1.438589] adc_val=402,temp=-40000 [ 1.438903] adc_val=403,temp=-39375 [ 1.439217] adc_val=404,temp=-38750 ... [ 1.441102] adc_val=410,temp=-40000 [ 1.441416] adc_val=411,temp=-34445 [ 1.441737] adc_val=412,temp=-33889 ... Let's fix it right now. Fixes commit 020ba95dbbbe ("thermal: rockchip: Add the sort mode for adc value increment or decrement"). Reported-by: Rocky Hao <rocky.hao@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ab5b52f1606f3a83e541102adf5d50e7a9bfdef5 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Mon Apr 18 11:35:53 2016 +0800 thermal: rockchip: disable thermal->clk in err case Disable thermal->clk when enabling pclk fails in resume routine. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 44cb6a7df13d3f6e663262e8c264a46cf84aa679 Author: Wei Ni <wni@nvidia.com> Date: Wed Apr 27 11:25:46 2016 +0800 thermal: tegra: add Tegra132 specific SOC_THERM driver add Tegra132 specific SOC_THERM driver. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/Makefile | 1 + drivers/thermal/tegra/soctherm.c | 6 + drivers/thermal/tegra/soctherm.h | 4 + drivers/thermal/tegra/tegra132-soctherm.c | 196 ++++++++++++++++++++++++++++++ 4 files changed, 207 insertions(+) commit bba07c133f668d64378d92e1f536df618e640ba6 Author: kbuild test robot <fengguang.wu@intel.com> Date: Thu Apr 21 09:04:01 2016 +0800 thermal: fix ptr_ret.cocci warnings drivers/thermal/tango_thermal.c:86:1-3: WARNING: PTR_ERR_OR_ZERO can be used Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR Generated by: scripts/coccinelle/api/ptr_ret.cocci CC: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tango_thermal.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit d29016034e5b2bb55fd370e3545685a8536f5474 Author: Dawei Chien <dawei.chien@mediatek.com> Date: Wed Dec 16 21:29:14 2015 +0800 thermal: mediatek: Add cpu dynamic power cooling model. MT8173 cpufreq driver select of_cpufreq_power_cooling_register registering cooling devices with dynamic power coefficient. Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Dawei Chien <dawei.chien@mediatek.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/cpufreq/mt8173-cpufreq.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit b3aef78f76959b94e6df54f80040669a11cc4897 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Tue Apr 19 12:52:01 2016 +0530 thermal: generic-adc: Add ADC based thermal sensor driver In some of platform, thermal sensors like NCT thermistors are connected to the one of ADC channel. The temperature is read by reading the voltage across the sensor resistance via ADC. Lookup table for ADC read value to temperature is referred to get temperature. ADC is read via IIO framework. Add support for thermal sensor driver which read the voltage across sensor resistance from ADC through IIO framework. Acked-by: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/Kconfig | 10 ++ drivers/thermal/Makefile | 1 + drivers/thermal/thermal-generic-adc.c | 182 ++++++++++++++++++++++++++++++++++ 3 files changed, 193 insertions(+) commit 9e389e383b30c5d63de67e7a0cfa39c527a98bbc Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Tue Apr 19 12:52:00 2016 +0530 thermal: generic-adc: Add DT binding for ADC based thermal sensor Sometimes, thermal sensors like NCT thermistors are connected to the ADC channel. The temperature is read by reading the voltage across the sensor resistance via ADC and referring the lookup table for ADC value to temperature. Add DT binding doc for the ADC based thermal sensor driver to detail the DT property and provide the example for how to use it. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Rob Herring <rob@kernel.org> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> .../bindings/thermal/thermal-generic-adc.txt | 89 ++++++++++++++++++++++ 1 file changed, 89 insertions(+) commit f350098070e36e1f51f925264146eff18a4e42dd Author: Wei Ni <wni@nvidia.com> Date: Wed Apr 6 17:48:04 2016 +0800 thermal: tegra: fix static checker warning There has a static checker warning: warn: variable dereferenced before check 'dev' (see line 222) Since check 'dev' is unnecessary, so remove this check. Fixes: ee6d79f202a4 ("thermal: tegra: add thermtrip function") Signed-off-by: Wei Ni <wni@nvidia.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit a977c41ec65bbdc5000a130372adba1f85c86833 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:19:33 2016 +0200 thermal: tegra: mark PM functions __maybe_unused After the PM support has been added to this driver, we get a harmless warning when that support is disabled at compile time: drivers/thermal/tegra/soctherm.c:641:12: error: 'soctherm_resume' defined but not used [-Werror=unused-function] static int soctherm_resume(struct device *dev) This marks the two PM functions as __maybe_unused to shut up the warning. This is preferred over adding an #ifdef around them, as it is harder to get wrong, and provides better compile-time coverage. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: a134b4143b65 ("thermal: tegra: add PM support") Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0b58c08b593d082858e74503bdf553ea01f9f15a Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Tue Apr 19 16:21:16 2016 +0200 thermal: add temperature sensor support for tango SoC The Tango thermal driver provides support for the primitive temperature sensor embedded in Tango chips since the SMP8758. This sensor only generates a 1-bit signal to indicate whether the die temperature exceeds a programmable threshold. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> .../devicetree/bindings/thermal/tango-thermal.txt | 17 ++++ drivers/thermal/Kconfig | 9 ++ drivers/thermal/Makefile | 1 + drivers/thermal/tango_thermal.c | 111 +++++++++++++++++++++ 4 files changed, 138 insertions(+) commit 469ace07c29310b1401316e5e910c157c7544af3 Author: Leo Yan <leo.yan@linaro.org> Date: Tue Mar 29 19:27:13 2016 +0800 thermal: hisilicon: fix IRQ imbalance enabling When register sensors into thermal zone during initialization phase, it reports error for IRQ imbalance enabling: [ 2.040713] WARNING: at kernel/irq/manage.c:513 [ 2.040719] Modules linked in: [ 2.040721] [ 2.040729] CPU: 1 PID: 804 Comm: irq/33-hisi_the Not tainted 4.5.0-rc4+ #505 [ 2.040732] Hardware name: HiKey Development Board (DT) [ 2.040736] task: ffffffc03ae82580 ti: ffffffc0379c8000 task.ti: ffffffc0379c8000 [ 2.040745] PC is at __enable_irq+0x74/0x84 [ 2.040749] LR is at __enable_irq+0x74/0x84 This warning is for IRQ imbalance enabling, which is caused by enable_irq() twice. During sensor's initialization it tries to enable IRQ, the driver will call thermal_zone_of_sensor_register() to bind sensors and read sensor's temperature. But at this moment the flag "data->irq_enabled" has been not initialized as correct state, so it finally introduces the function enabled_irq() to be called twice. In essentially this is caused by the flag "data->irq_enabled" is inconsistent with real hardware IRQ enabling state. So this patch is to fix this issue, firstly init "irq_enabled" flag before binding sensors to thermal zone. Also change to use the function irq_get_irqchip_state() to read back real interrupt line state. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/hisi_thermal.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 439dc96811739ad5440143140fe92df5140daf11 Author: Leo Yan <leo.yan@linaro.org> Date: Tue Mar 29 19:27:12 2016 +0800 thermal: hisilicon: support to use any sensor In current code sensor driver registers all 4 sensors together and if any of them has not bound to thermal zone successfully then driver will return failure for driver's initialization. As a result, if DT binds thermal zone with only one sensor, then the thermal driver will not work well anymore. So this patch is to fix this issue. It allows the thermal sensor driver can register any number sensors at initialization phase, and fix up code for other related code to skip related sensor's accessing if the sensor has not been enabled in initialization phase. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/hisi_thermal.c | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) commit 13849883475408272aaddcea00052bd9f4d9b4ca Author: Simon Horman <horms+renesas@verge.net.au> Date: Tue Mar 29 14:07:45 2016 +0900 thermal: rcar: Remove binding docs for r8a7794 The latest information that I have is that there is no thermal IP block present on the r8a7794 SoC so remove the corresponding binding. Cc: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> Documentation/devicetree/bindings/thermal/rcar-thermal.txt | 1 - 1 file changed, 1 deletion(-) commit f09d698494289cdf1f0afc0baddbac8db30f195d Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:22 2016 +0800 thermal: tegra: add PM support Add suspend/resume function in soctherm driver. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 46 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) commit 1ed895c2a27ebc862241926945f4adcbc88c6cd6 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:21 2016 +0800 thermal: tegra: handle HW initialization in one funcotion Handle HW initialization in one function soctherm_init(), so that the codes are more clear. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 85 +++++++++++++++++++++------------------- 1 file changed, 44 insertions(+), 41 deletions(-) commit 8de2ab023598bcb874e2182ab6ea7355bbf33af6 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:20 2016 +0800 thermal: tegra: handle clocks in one function Handle clock enable/disable codes in one function soctherm_clk_enable(), so that the codes are more clear. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 51 ++++++++++++++++++++++++++++------------ 1 file changed, 36 insertions(+), 15 deletions(-) commit 2a895871f27fdc82ac7b365d3f94e2c7b3467898 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:19 2016 +0800 thermal: tegra: add thermtrip function Add support for hardware critical thermal limits to the SOC_THERM driver. It use the Linux thermal framework to create critical trip temp, and set it to SOC_THERM hardware. If these limits are breached, the chip will reset, and if appropriately configured, will turn off the PMIC. This support is critical for safe usage of the chip. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 166 +++++++++++++++++++++++++++++- drivers/thermal/tegra/soctherm.h | 7 ++ drivers/thermal/tegra/tegra124-soctherm.c | 24 +++++ drivers/thermal/tegra/tegra210-soctherm.c | 24 +++++ 4 files changed, 216 insertions(+), 5 deletions(-) commit 4d44cd4ae96ed3744d26d9615ea103df5afc3ed7 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:18 2016 +0800 of: add notes of critical trips for soctherm The "critical" type trip in thermal zone can be set to SOC_THERM hardware, it can trigger shut down or reset event from hardware. Signed-off-by: Wei Ni <wni@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> Documentation/devicetree/bindings/thermal/tegra-soctherm.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit c35095215a80b13af2f521e1ab1c727a5224e53b Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:17 2016 +0800 thermal: of-thermal: allow setting trip_temp on hardware In current of-thermal, the .set_trip_temp only support to set trip_temp for SW. But some sensors support to set trip_temp on hardware, so that can trigger interrupt, shutdown or any other events. This patch adds .set_trip_temp() callback in thermal_zone_of_device_ops{}, so that the sensor device can use it to set trip_temp on hardware. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/of-thermal.c | 8 ++++++++ include/linux/thermal.h | 1 + 2 files changed, 9 insertions(+) commit d753b22d8b2d500377bc85c4909cc0d6f199d1c8 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:16 2016 +0800 thermal: tegra: add a debugfs to show registers Add a debugfs interface to show register contents for debug. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/soctherm.c | 146 ++++++++++++++++++++++++++++++++++++++- drivers/thermal/tegra/soctherm.h | 2 + 2 files changed, 145 insertions(+), 3 deletions(-) commit 8204104f3598b6f29a8858df16c15c156014b863 Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:15 2016 +0800 thermal: tegra: add Tegra210 specific SOC_THERM driver Add Tegra210 specific SOC_THERM driver. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/Makefile | 1 + drivers/thermal/tegra/soctherm-fuse.c | 11 ++ drivers/thermal/tegra/soctherm.c | 6 ++ drivers/thermal/tegra/soctherm.h | 4 + drivers/thermal/tegra/tegra210-soctherm.c | 173 ++++++++++++++++++++++++++++++ 5 files changed, 195 insertions(+) commit 65b6d57c24ed0aff1fc571e42d8f51bdfcce9a8e Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:14 2016 +0800 thermal: tegra: split tegra_soctherm driver Split most of the Tegra124 data and code into a Tegra124-specific file. Split most of the fuse-related code into a fuse-related source file. This is in preparation for adding a Tegra210-specific driver in a future patch. Beyond the maintainability improvements, this is intended to separate chip-specific ATE and characterization-related hacks into chip-specific files, in the hopes that they won't pollute code for other chips. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/Kconfig | 2 +- drivers/thermal/tegra/Makefile | 3 + drivers/thermal/tegra/soctherm-fuse.c | 158 +++++++++ drivers/thermal/tegra/soctherm.c | 310 ++++++++++++++++ drivers/thermal/tegra/soctherm.h | 110 ++++++ drivers/thermal/tegra/tegra-soctherm.c | 565 ------------------------------ drivers/thermal/tegra/tegra124-soctherm.c | 172 +++++++++ 7 files changed, 754 insertions(+), 566 deletions(-) commit 1c3bdc1627c331b4925a95453f7b61226077bebe Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:13 2016 +0800 thermal: tegra: get rid of PDIV/HOTSPOT hack Get rid of T124-specific PDIV/HOTSPOT hack. tegra-soctherm.c contained a hack to set the SENSOR_PDIV and SENSOR_HOTSPOT_OFFSET registers - it just did two writes of T124-specific opaque values. Convert these into a form that can be substituted on a per-chip basis, and into structure fields that have at least some independent meaning. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/tegra-soctherm.c | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) commit 6f7e0d9d08c7fa3847b1380b16dff7e14523933c Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:12 2016 +0800 thermal: tegra: combine sensor group-related data Combine sensor group-related data structures into struct tegra_tsensor_group. This provides a single location for sensor group data storage. More sensor group data will be added in subsequent patches. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra/tegra-soctherm.c | 145 +++++++++++++++++++----- include/dt-bindings/thermal/tegra124-soctherm.h | 1 + 2 files changed, 119 insertions(+), 27 deletions(-) commit a4dff94ffde7df6aeeb11cd548e53b22bdabd04e Author: Wei Ni <wni@nvidia.com> Date: Tue Mar 29 18:29:11 2016 +0800 thermal: tegra: move tegra thermal files into tegra directory Move Tegra soctherm driver to tegra directory, it's easy to maintain and add more new function support for Tegra platforms. This will also help to split soctherm driver into common parts and chip specific data related parts. Signed-off-by: Wei Ni <wni@nvidia.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/Kconfig | 12 +- drivers/thermal/Makefile | 2 +- drivers/thermal/tegra/Kconfig | 13 + drivers/thermal/tegra/Makefile | 1 + drivers/thermal/tegra/tegra-soctherm.c | 463 +++++++++++++++++++++++++++++++++ drivers/thermal/tegra_soctherm.c | 463 --------------------------------- 6 files changed, 480 insertions(+), 474 deletions(-) commit 3982204cc9baab0c28ac48e859acf7692c6159e6 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:12:52 2016 -0800 thermal: convert ti-thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: linux-pm@vger.kernel.org Cc: linux-omap@vger.kernel.org Cc: linux-kernel@vger.kernel.org Tested-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/ti-soc-thermal/ti-thermal-common.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 71ca46eeeff3273f6641ab3e30292d3d36f1d3be Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:12:13 2016 -0800 thermal: convert tegra_thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Stephen Warren <swarren@wwwdotorg.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-pm@vger.kernel.org Cc: linux-tegra@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/tegra_soctherm.c | 31 +++++++++---------------------- 1 file changed, 9 insertions(+), 22 deletions(-) commit 2633ad19137760e3d2313e492704843a6751b3d1 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:10:28 2016 -0800 thermal: convert rockchip_thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Heiko Stuebner <heiko@sntech.de> Cc: linux-pm@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-rockchip@lists.infradead.org Cc: linux-kernel@vger.kernel.org Tested-by: Caesar Wang <wxt@rock-chips.com> Reviewed-by: Caesar Wang <wxt@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rockchip_thermal.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) commit 5e325868aa59d3c743aa1c9526f386f30c234cd7 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:09:43 2016 -0800 thermal: convert rcar_thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/rcar_thermal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e936491e5c005620951fe5d67e441b936f583702 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:08:48 2016 -0800 thermal: convert qcom-spmi to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/qcom-spmi-temp-alarm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit c417bdedb14c12671a199bb5d4f3b78b438598b3 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:08:14 2016 -0800 thermal: convert mtk_thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Matthias Brugger <matthias.bgg@gmail.com> Cc: linux-pm@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-mediatek@lists.infradead.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/mtk_thermal.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 44a520d81e70eac35833b0c2dc24d8daa371f557 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:07:13 2016 -0800 thermal: convert hisi_thermal to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Zhang Rui <rui.zhang@intel.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/hisi_thermal.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit e28d0c9cd381e115c2270bf1d6fe4de95289234a Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:05:42 2016 -0800 input: convert sun4i-ts to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Cc: Chen-Yu Tsai <wens@csie.org> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Heiko Stuebner <heiko@sntech.de> Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Jens Thiele <karme@karme.de> Cc: linux-input@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/input/touchscreen/sun4i-ts.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit d7817ff27b06bf15902ef021d0f55a678a4afd34 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:03:17 2016 -0800 hwmon: convert scpi-hwmon to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Jean Delvare <jdelvare@suse.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: lm-sensors@lm-sensors.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/hwmon/scpi-hwmon.c | 48 +++++++++------------------------------------- 1 file changed, 9 insertions(+), 39 deletions(-) commit 51b77fd7b17f03114bb1809e35be0b434d89cb76 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:02:54 2016 -0800 hwmon: convert tmp102 to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Jean Delvare <jdelvare@suse.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: lm-sensors@lm-sensors.org Cc: linux-kernel@vger.kernel.org Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/hwmon/tmp102.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 0e058bc3acc03d6b028f2bc4fd67486238b10bec Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 13:02:22 2016 -0800 hwmon: convert ntc_thermistor to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Jean Delvare <jdelvare@suse.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: lm-sensors@lm-sensors.org Cc: linux-kernel@vger.kernel.org Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/hwmon/ntc_thermistor.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 2a48802f376bbb56a68c530255dfc3dc744b3e97 Author: Eduardo Valentin <edubezval@gmail.com> Date: Wed Mar 9 12:39:58 2016 -0800 hwmon: convert lm75 to use devm_thermal_zone_of_sensor_register This changes the driver to use the devm_ version of thermal_zone_of_sensor_register and cleans up the local points and unregister calls. Cc: Jean Delvare <jdelvare@suse.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: lm-sensors@lm-sensors.org Cc: linux-kernel@vger.kernel.org Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/hwmon/lm75.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit ef41be8168b6ceaa6220d5ca5430b960194ea94f Author: Keerthy <j-keerthy@ti.com> Date: Wed Mar 16 11:42:58 2016 +0530 MAINTAINERS: ti-soc-thermal: add a co-maintainer and update the entry Add myself as a co-maintainer for ti-soc-thermal Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 1cd91c1820801267b5579fa65842cdf843c73c4d Author: Ulises Brindis <brindisu@lab126.com> Date: Fri Mar 25 12:55:41 2016 -0700 thermal: of: fix cleanup when building a thermal zone of_node_put is iterating through all terms in the tbps array even though the bind has failed. We need to only iterate through the terms that have already passed the binding step. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Ulises Brindis <brindisu@lab126.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> drivers/thermal/of-thermal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c212ed912b73f804d5f897ec0a84f58dfd3da9e1 Author: Andy Champ <andycham@amazon.com> Date: Tue Mar 22 12:37:25 2016 +0000 thermal: Syntactic and factual errors in the API document There are several places where the English in the document is syntactically invalid, or unclear. There are also one or two factual errors. Reviewed-by: Durgadoss R <durgadoss.r@intel.com> Signed-off-by: Andy Champ <andycham@amazon.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com> Documentation/thermal/sysfs-api.txt | 44 ++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 22 deletions(-) commit 255f0e7c418ad95a4baeda017ae6182ba9b3c423 Author: Lyude <cpaul@redhat.com> Date: Thu May 12 10:56:59 2016 -0400 drm/fb_helper: Fix references to dev->mode_config.num_connector During boot, MST hotplugs are generally expected (even if no physical hotplugging occurs) and result in DRM's connector topology changing. This means that using num_connector from the current mode configuration can lead to the number of connectors changing under us. This can lead to some nasty scenarios in fbcon: - We allocate an array to the size of dev->mode_config.num_connectors. - MST hotplug occurs, dev->mode_config.num_connectors gets incremented. - We try to loop through each element in the array using the new value of dev->mode_config.num_connectors, and end up going out of bounds since dev->mode_config.num_connectors is now larger then the array we allocated. fb_helper->connector_count however, will always remain consistent while we do a modeset in fb_helper. Note: This is just polish for 4.7, Dave Airlie's drm_connector refcounting fixed these bugs for real. But it's good enough duct-tape for stable kernel backporting, since backporting the refcounting changes is way too invasive. Cc: stable@vger.kernel.org Signed-off-by: Lyude <cpaul@redhat.com> [danvet: Clarify why we need this. Also remove the now unused "dev" local variable to appease gcc.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463065021-18280-3-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_fb_helper.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 14a3842a1d5945067d1dd0788f314e14d5b18e5b Author: Lyude <cpaul@redhat.com> Date: Thu May 12 10:56:58 2016 -0400 drm/i915/fbdev: Fix num_connector references in intel_fb_initial_config() During boot time, MST devices usually send a ton of hotplug events irregardless of whether or not any physical hotplugs actually occurred. Hotplugs mean connectors being created/destroyed, and the number of DRM connectors changing under us. This isn't a problem if we use fb_helper->connector_count since we only set it once in the code, however if we use num_connector from struct drm_mode_config we risk it's value changing under us. On top of that, there's even a chance that dev->mode_config.num_connector != fb_helper->connector_count. If the number of connectors happens to increase under us, we'll end up using the wrong array size for memcpy and start writing beyond the actual length of the array, occasionally resulting in kernel panics. Note: This is just polish for 4.7, Dave Airlie's drm_connector refcounting fixed these bugs for real. But it's good enough duct-tape for stable kernel backporting, since backporting the refcounting changes is way too invasive. Cc: stable@vger.kernel.org Signed-off-by: Lyude <cpaul@redhat.com> [danvet: Clarify why we need this.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463065021-18280-2-git-send-email-cpaul@redhat.com drivers/gpu/drm/i915/intel_fbdev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 2e629ebc24d463ffb6c17b15daf908e6f968a1de Merge: 3b9d78a ff628a4 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 17 15:06:31 2016 +0200 Merge branches 'next/cleanup' and 'next/fixes-non-critical' into next/cleanups-fixes This is a merge of the cleanup and fixes-non-critical branches for the 4.7 merge window. It seems more appropriate to send a single pull request for these than two separate ones, as both branches really contain both fixes and cleanups. * next/cleanup: ARM: debug: remove extraneous DEBUG_HI3716_UART option ARM: davinci: use IRQCHIP_DECLARE for cp_intc ARM: davinci: remove unused DA8XX_NUM_UARTS ARM: davinci: simplify call to of populate ARM: DaVinci USB: removed deprecated properties from MUSB config ARM: rockchip: Fix use of plain integer as NULL pointer ARM: realview: hide unused 'pmu_device' object soc: versatile: dynamically detect RealView HBI numbers * next/fixes-non-critical: ARM: dts: exynos: Add interrupt line to MAX8997 PMIC on exynos4210-trats ARM: dts: exynos: Fix regulator name to avoid forbidden character on exynos4210-trats ARM: dts: exynos: Add MFC memory banks for Peach boards ARM: OMAP2+: n900 needs MMC slot names for legacy user space ARM: OMAP2+: Add more functions to pwm pdata for ir-rx51 ARM: EXYNOS: Properly skip unitialized parent clock in power domain on ARM: OMAP2+: Simplify auxdata by using the generic match of/platform: Allow secondary compatible match in of_dev_lookup commit 18c588786c08458f5d965d8735ab48f9e51e0b4b Merge: d2a3f20 23e3523 Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 17 14:57:58 2016 +0200 Merge branch 'for-4.7/pwm-atomic' into for-next commit d2a3f206846b4b140aa1fe5be29499e9191fb1fe Merge: bf5dd9a 8c12ad8 Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 17 14:57:53 2016 +0200 Merge branch 'for-4.7/pwm-regulator' into for-next commit bf5dd9abcb4443bbab8cb63b9d82b96a4a45c802 Merge: c3499f0 fbd45a1 Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 17 14:57:47 2016 +0200 Merge branch 'for-4.7/pwm-args' into for-next commit c3499f0bc38d6db78f119f8f95d5d471e026ef88 Merge: f55532a 2907f8a Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 17 14:57:35 2016 +0200 Merge branch 'for-4.7/pwm-cleanup' into for-next commit 23e3523f5d3a980edf7f189743cf4bb9490400a9 Author: Heiko Stübner <heiko@sntech.de> Date: Thu Apr 14 21:17:44 2016 +0200 pwm: Add information about polarity, duty cycle and period to debugfs The PWM states make it possible to also output the polarity, duty cycle and period information in the debugfs summary output. This simplifies gathering information about PWMs without needing to walk through the sysfs attributes of every PWM. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> [thierry.reding@gmail.com: use more spaces in debugfs output] Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 5 +++++ 1 file changed, 5 insertions(+) commit 39100ceea79ff2efeb2fb094baf120c73d5ccf47 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:43 2016 +0200 pwm: Switch to the atomic API Replace legacy pwm_get/set_xxx() and pwm_config/enable/disable() calls by pwm_get/apply_state(). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 5 ++++- drivers/pwm/sysfs.c | 48 +++++++++++++++++++++++++++++++++++++----------- 2 files changed, 41 insertions(+), 12 deletions(-) commit a07136fdcf12281781142caf1f78c6696721accd Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:42 2016 +0200 pwm: Update documentation Update the PWM subsystem documentation to reflect the atomic PWM changes. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> Documentation/pwm.txt | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) commit 5ec803edcb703fe379836f13560b79dfac79b01d Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:41 2016 +0200 pwm: Add core infrastructure to allow atomic updates Add an ->apply() method to the pwm_ops struct to allow PWM drivers to implement atomic updates. This method is preferred over the ->enable(), ->disable() and ->config() methods if available. Add the pwm_apply_state() function to the PWM user API. Note that the pwm_apply_state() does not guarantee the atomicity of the update operation, it all depends on the availability and implementation of the ->apply() method. pwm_enable/disable/set_polarity/config() are now implemented as wrappers around the pwm_apply_state() function. pwm_adjust_config() is allowing smooth handover between the bootloader and the kernel. This function tries to adapt the current PWM state to the PWM arguments coming from a PWM lookup table or a DT definition without changing the duty_cycle/period proportion. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> [thierry.reding@gmail.com: fix a couple of typos] Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 187 +++++++++++++++++++++++------------- include/linux/pwm.h | 269 +++++++++++++++++++++++++++++++++++----------------- 2 files changed, 303 insertions(+), 153 deletions(-) commit 15fa8a43c147213a9563903c87b29671035eb6e8 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:40 2016 +0200 pwm: Add hardware readout infrastructure Add a ->get_state() function to the pwm_ops struct to let PWM drivers initialize the PWM state attached to a PWM device. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 3 +++ include/linux/pwm.h | 28 ++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) commit 09a7e4a3d9fcb95ade2cb02167e85fbeb8315ce0 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:39 2016 +0200 pwm: Move the enabled/disabled info into pwm_state Prepare the transition to PWM atomic update by moving the enabled and disabled state into the pwm_state struct. This way we can easily update the whole PWM state by copying the new state in the ->state field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 13 +++++++++---- include/linux/pwm.h | 11 ++++++++--- 2 files changed, 17 insertions(+), 7 deletions(-) commit 43a276b003ed2e03de9d94b02a1ba49c1849b931 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:38 2016 +0200 pwm: Introduce the pwm_state concept The PWM state, represented by its period, duty_cycle and polarity is currently directly stored in the PWM device. Declare a pwm_state structure embedding those field so that we can later use this struct to atomically update all the PWM parameters at once. All pwm_get_xxx() helpers are now implemented as wrappers around pwm_get_state(). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 8 ++++---- include/linux/pwm.h | 54 +++++++++++++++++++++++++++++++++++++++++------------ 2 files changed, 46 insertions(+), 16 deletions(-) commit a8c3862551e063344f80c3e05d595f9d8836f355 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:37 2016 +0200 pwm: Keep PWM state in sync with hardware state Before the introduction of pwm_args, the core was resetting the PWM period and polarity states to the reference values (those provided through the DT, a PWM lookup table or hardcoded in the driver). Now that all PWM users are correctly using pwm_args to configure their PWM device, we can safely remove the pwm_apply_args() call in pwm_get() and of_pwm_get(). We can also get rid of the pwm_set_period() call in pwm_apply_args(), because PWM users are now directly using pargs->period instead of pwm_get_period(). By doing that we avoid messing with the current PWM period. The only remaining bit in pwm_apply_args() is the initial polarity setting, and it should go away when all PWM users have been patched to use the atomic API (with this API the polarity will be set along with other PWM arguments when configuring the PWM). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 14 -------------- include/linux/pwm.h | 1 - 2 files changed, 15 deletions(-) commit 102232c54601071304cb6946f9758e3cd74d3e1e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:36 2016 +0200 ARM: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> arch/arm/mach-s3c24xx/mach-rx1950.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 2347aa7c34be284b266ab6b5f2bdf5daf14f582e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:35 2016 +0200 drm: i915: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/gpu/drm/i915/intel_panel.c | 6 ++++++ 1 file changed, 6 insertions(+) commit cfae56f18c7cbdb0542025b0d3f000d9ba0152d0 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:34 2016 +0200 input: misc: pwm-beeper: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/input/misc/pwm-beeper.c | 6 ++++++ 1 file changed, 6 insertions(+) commit de93170b85d7ee2a6a6a881c019160a65adeb636 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:33 2016 +0200 input: misc: max8997: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/input/misc/max8997_haptic.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 7ff666bc4b821650a03cadeb4108c77328c98c0a Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:32 2016 +0200 backlight: lm3630a: explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/lm3630a_bl.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 6fbab835a973cee2e6a7742bbc990055b24de5cd Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:31 2016 +0200 backlight: lp855x: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/lp855x_bl.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 058be4d6c67d9fc043623cb26e4abe5608755d65 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:30 2016 +0200 backlight: lp8788: Explicitly apply PWM config extracted from pwm_args Call pwm_apply_args() just after requesting the PWM device so that the polarity and period are initialized according to the information provided in pwm_args. This is an intermediate state, and pwm_apply_args() should be dropped as soon as the atomic PWM infrastructure is in place and the driver makes use of it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/lp8788_bl.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 6cb9644db7364ff5d2980ccd365b8cb684145327 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:29 2016 +0200 backlight: pwm_bl: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/pwm_bl.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 717c18f0e4653bbb74a164e88e5b7ccc5db7684b Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:28 2016 +0200 fbdev: ssd1307fb: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/fbdev/ssd1307fb.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 6bc24526f8010f208a243cc73df4c6cc48fa18a4 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:27 2016 +0200 regulator: pwm: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/regulator/pwm-regulator.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) commit 1b50673dfa6486a69895bd45bb5eeaaede0a2b93 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:26 2016 +0200 leds: pwm: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Jacek Anaszewski <j.anaszewski@samsung.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/leds/leds-pwm.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit ad4e9fec143c453cae145d7d5ccac902c37fb912 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:25 2016 +0200 input: misc: max77693: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/input/misc/max77693-haptic.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) commit 2289711c9d4d588954ff86a06685f1579bf6c446 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:24 2016 +0200 hwmon: pwm-fan: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Kamil Debski <k.debski@samsung.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/hwmon/pwm-fan.c | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) commit dd0b38b7ca0d8c8aadcf8a17d7c90d36ab8ab6e4 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:23 2016 +0200 clk: pwm: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/clk/clk-pwm.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit 4b58896f72176b781816a9e14dcea5f755b19b5c Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:22 2016 +0200 pwm: Use pwm_get/set_xxx() helpers where appropriate Use pwm_get/set_xxx() helpers instead of directly accessing the pwm->xxx field. Doing that will ease adaptation of the PWM framework to support atomic update. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/pwm-crc.c | 2 +- drivers/pwm/pwm-lpc18xx-sct.c | 2 +- drivers/pwm/pwm-omap-dmtimer.c | 2 +- drivers/pwm/pwm-sun4i.c | 3 ++- 4 files changed, 5 insertions(+), 4 deletions(-) commit 459a25afe97cb3d7f978b90c881f4d7aac8fb755 Author: Boris BREZILLON <boris.brezillon@free-electrons.com> Date: Wed Mar 30 22:03:27 2016 +0200 pwm: Get rid of pwm->lock PWM devices are not protected against concurrent accesses. The lock in struct pwm_device might let PWM users think it is, but it's actually only protecting the enabled state. Removing this lock should be fine as long as all PWM users are aware that accesses to the PWM device have to be serialized, which seems to be the case for all of them except the sysfs interface. Patch the sysfs code by adding a lock to the pwm_export struct and making sure it's taken for all relevant accesses to the exported PWM device. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 19 ++++--------------- drivers/pwm/sysfs.c | 24 ++++++++++++++++++++---- include/linux/pwm.h | 2 -- 3 files changed, 24 insertions(+), 21 deletions(-) commit 4ff66efd59102280a71d432c9f0e89cdaf66b849 Author: Boris BREZILLON <boris.brezillon@free-electrons.com> Date: Wed Mar 30 22:03:26 2016 +0200 backlight: lm3630a_bl: Stop messing with the pwm->period field pwm->period field is not supposed to be changed by PWM users. The only ones authorized to change it are the PWM core and PWM drivers. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/lm3630a_bl.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 7f044b09b68d36811518c55f736a20648e8ed6e2 Author: Boris BREZILLON <boris.brezillon@free-electrons.com> Date: Wed Mar 30 22:03:25 2016 +0200 backlight: pwm_bl: Remove useless call to pwm_set_period() The PWM period will be set when calling pwm_config. Remove this useless call to pwm_set_period(), which might mess up the internal PWM state. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/video/backlight/pwm_bl.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 3587c260906259632df07652743269627f408d85 Author: Boris BREZILLON <boris.brezillon@free-electrons.com> Date: Wed Mar 30 22:03:24 2016 +0200 pwm: rcar: Make use of pwm_is_enabled() Commit 5c31252c4a86 ("pwm: Add the pwm_is_enabled() helper") introduced a new function to test whether a PWM device is enabled or not without manipulating PWM internal fields. Hiding this is necessary if we want to smoothly move to the atomic PWM config approach without impacting PWM drivers. Fix this driver to use pwm_is_enabled() instead of directly accessing the ->flags field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/pwm-rcar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3f1f368e4ab5ac2692e3dfec66a9e6a0a2f6cea7 Merge: f55532a fbd45a1 Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 17 14:44:37 2016 +0200 Merge branch 'for-4.7/pwm-args' into for-4.7/pwm-atomic commit fbd45a12988e75a48d392feb8b0e5feb5d612513 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue May 17 14:27:25 2016 +0200 pwm: Fix pwm_apply_args() call sites pwm_apply_args() is supposed to initialize a PWM device according to the arguments provided by the DT or the PWM lookup, but this function was called inside pwm_device_request(), which in turn was called before the core had a chance to initialize the pwm->args fields. Fix that by calling pwm_apply_args directly in pwm_get() and of_pwm_get() after initializing pwm->args field. This commit also fixes an invalid pointer dereference introduced by commit e39c0df1be5a ("pwm: Introduce the pwm_args concept"). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Fixes: e39c0df1be5a ("pwm: Introduce the pwm_args concept") Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) commit 6971ce4134174b9772ed79ff7747696eab087d30 Merge: a158f2b 29cf67b Author: Takashi Iwai <tiwai@suse.de> Date: Tue May 17 12:45:31 2016 +0200 Merge tag 'asoc-v4.7-fix-hdac' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Fix for v4.7 Fix an unused variable warning in the HDAC code. commit 66bc5ba5236519297d4ba2b52cdb6fc003a897d3 Merge: 3390e57 bef7e20 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 17 12:42:27 2016 +0200 Merge branch 'for-4.7/wacom' into for-linus commit 3390e579b3dac71e630ed879a73c5ac3b4447045 Merge: 27fd38c 282bf1f Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 17 12:41:22 2016 +0200 Merge branch 'for-4.7/upstream' into for-linus Conflicts: drivers/hid/usbhid/hid-quirks.c commit 27fd38c5226ed0f1712d071880fa8e739eb78650 Merge: eff6ca9 b94f7d5 8f507c8 bbf4ac9 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 17 12:38:03 2016 +0200 Merge branches 'for-4.6/upstream-fixes', 'for-4.7/asus', 'for-4.7/hidraw' and 'for-4.7/thingm' into for-linus commit 29cf67b99527296e9c9b9f6995c1d271d21f79c0 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon May 16 09:50:07 2016 -0300 ASoC: hdac_hdmi: Remove the unused 'timeout' variable Commit b2047e996cd88d3 ("ASoC: hdac_hdmi: add link management") introuduced the following build warning: sound/soc/codecs/hdac_hdmi.c:1721:16: warning: unused variable 'timeout' [-Wunused-variable] Remove the unused 'timeout' variable. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 1 - 1 file changed, 1 deletion(-) commit 2e636d5e66c35dfcbaf617aa8fa963f6847478fe Author: Peter Zijlstra <peterz@infradead.org> Date: Mon May 16 15:01:11 2016 +0200 sched/preempt: Fix preempt_count manipulations Vikram reported that his ARM64 compiler managed to 'optimize' away the preempt_count manipulations in code like: preempt_enable_no_resched(); put_user(); preempt_disable(); Irrespective of that fact that that is horrible code that should be fixed for many reasons, it does highlight a deficiency in the generic preempt_count manipulators. As it is never right to combine/elide preempt_count manipulations like this. Therefore sprinkle some volatile in the two generic accessors to ensure the compiler is aware of the fact that the preempt_count is observed outside of the regular program-order view and thus cannot be optimized away like this. x86; the only arch not using the generic code is not affected as we do all this in asm in order to use the segment base per-cpu stuff. Reported-by: Vikram Mulukutla <markivx@codeaurora.org> Tested-by: Vikram Mulukutla <markivx@codeaurora.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: a787870924db ("sched, arch: Create asm/preempt.h") Link: http://lkml.kernel.org/r/20160516131751.GH3205@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> include/asm-generic/preempt.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b937190c40de0f6f07f592042e3097b16c6b0130 Author: Kees Cook <keescook@chromium.org> Date: Tue May 17 01:45:52 2016 -0700 LSM: LoadPin: provide enablement CONFIG Instead of being enabled by default when SECURITY_LOADPIN is selected, provide an additional (default off) config to determine the boot time behavior. As before, the "loadpin.enabled=0/1" kernel parameter remains available. Suggested-by: James Morris <jmorris@namei.org> Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> security/loadpin/Kconfig | 19 ++++++++++++++----- security/loadpin/loadpin.c | 2 +- 2 files changed, 15 insertions(+), 6 deletions(-) commit be69f70e6395a4ba9c178b2531433547e1955195 Merge: f09d908 5e4e384 4d4fb97 Author: Jiri Kosina <jkosina@suse.cz> Date: Tue May 17 12:06:35 2016 +0200 Merge branches 'for-4.7/core', 'for-4.7/livepatching-doc' and 'for-4.7/livepatching-ppc64' into for-linus commit 6e4ad1b413604b9130bdbe532aafdbd47ff5318e Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Tue May 17 10:35:52 2016 +0530 MIPS: pic32mzda: fix getting timer clock rate. PIC32 clock driver is now implemented as platform driver instead of as part of of_clk_init(). It meants all the clock modules are available quite late in the boot sequence. So request for CPU clock by clk_get_sys() and clk_get_rate() to find c0_timer rate fails. To fix this use PIC32 specific early clock functions implemented for early console support. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: Joshua Henderson <digitalpeer@digitalpeer.com> Patchwork: https://patchwork.linux-mips.org/patch/13262/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/pic32/pic32mzda/time.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 9184dc8ffa56844352b3b9860e562ec4ee41176f Author: Felix Fietkau <nbd@nbd.name> Date: Mon May 16 19:51:55 2016 +0200 MIPS: ath79: fix regression in PCI window initialization ath79_ddr_pci_win_base has the type void __iomem *, so register offsets need to be a multiple of 4. Cc: Alban Bedel <albeu@free.fr> Fixes: 24b0e3e84fbf ("MIPS: ath79: Improve the DDR controller interface") Signed-off-by: Felix Fietkau <nbd@nbd.name> Cc: sergei.shtylyov@cogentembedded.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13258/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/common.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 6241bf6a59a41c7ca742c043416b6d57109c6b5d Author: Felix Fietkau <nbd@nbd.name> Date: Mon May 16 19:51:54 2016 +0200 MIPS: ath79: make ath79_ddr_ctrl_init() compatible for newer SoCs AR913x, AR724x and AR933x are the only SoCs where the ath79_ddr_wb_flush_base starts at 0x7c, all newer SoCs use 0x9c Invert the logic to make the code compatible with AR95xx Signed-off-by: Felix Fietkau <nbd@nbd.name> Cc: albeu@free.fr Cc: sergei.shtylyov@cogentembedded.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13257/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/common.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit bad50d79255a8a479ea63bea89e859bf08fd0f24 Author: James Hogan <james.hogan@imgtec.com> Date: Mon May 16 12:50:04 2016 +0100 MIPS: Fix VZ probe gas errors with binutils <2.24 The VZ guest register & TLB access macros introduced in commit "MIPS: Add guest CP0 accessors" use VZ ASE specific instructions that aren't understood by versions of binutils prior to 2.24. Add a check for whether the toolchain supports the -mvirt option, similar to the MSA toolchain check, and implement the accessors using .word if not. Due to difficulty in converting compiler specified registers (e.g. "$3") to usable numbers (e.g. "3") in inline asm, we need to copy to/from a temporary register, namely the assembler temporary (at/$1), and specify guest CP0 registers numerically in the gc0 macros. Fixes: 7eb91118227d ("MIPS: Add guest CP0 accessors") Signed-off-by: James Hogan <james.hogan@imgtec.com> Reported-by: Guenter Roeck <linux@roeck-us.net> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: linux-next@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13255/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Makefile | 2 + arch/mips/include/asm/mipsregs.h | 473 ++++++++++++++++++++++++--------------- 2 files changed, 295 insertions(+), 180 deletions(-) commit fd716fca10fc3dc0f18b8c16d4ecfa6d93f010d2 Author: James Hogan <james.hogan@imgtec.com> Date: Mon May 16 19:32:35 2016 +0100 MIPS: perf: Fix I6400 event numbers Fix perf hardware performance counter event numbers for I6400. This core does not follow the performance event numbering scheme of previous MIPS cores. All performance counters (both odd and even) are capable of counting any of the available events. Fixes: 4e88a8621301 ("MIPS: Add cases for CPU_I6400") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13259/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/perf_event_mipsxx.c | 54 ++++++++++++++++++++++++++++++++++-- 1 file changed, 52 insertions(+), 2 deletions(-) commit e48b4dacbc94fcb59b86f70f01837ed75ea6d616 Author: Maciej W. Rozycki <macro@linux-mips.org> Date: Mon May 16 13:15:47 2016 +0100 MIPS: DEC: Export `ioasic_ssr_lock' to modules Fix a modular `declance' regression caused by LMO commit bb46bf30d13f ("DECstation SCSI driver clean-ups.") Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13256/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/dec/setup.c | 1 + 1 file changed, 1 insertion(+) commit e49d38488515057dba8f0c2ba4cfde5be4a7281f Author: Maciej W. Rozycki <macro@imgtec.com> Date: Tue May 17 06:12:27 2016 +0100 MIPS: MSA: Fix a link error on `_init_msa_upper' with older GCC Fix a build regression from commit c9017757c532 ("MIPS: init upper 64b of vector registers when MSA is first used"): arch/mips/built-in.o: In function `enable_restore_fp_context': traps.c:(.text+0xbb90): undefined reference to `_init_msa_upper' traps.c:(.text+0xbb90): relocation truncated to fit: R_MIPS_26 against `_init_msa_upper' traps.c:(.text+0xbef0): undefined reference to `_init_msa_upper' traps.c:(.text+0xbef0): relocation truncated to fit: R_MIPS_26 against `_init_msa_upper' to !CONFIG_CPU_HAS_MSA configurations with older GCC versions, which are unable to figure out that calls to `_init_msa_upper' are indeed dead. Of the many ways to tackle this failure choose the approach we have already taken in `thread_msa_context_live'. [ralf@linux-mips.org: Drop patch segment to junk file.] Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: stable@vger.kernel.org # v3.16+ Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13271/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/msa.h | 13 +++++++++++++ arch/mips/kernel/traps.c | 6 +++--- 2 files changed, 16 insertions(+), 3 deletions(-) commit 2e51f26245701cb28f154552836b7807159088a8 Author: Jan Beulich <JBeulich@suse.com> Date: Mon May 16 15:31:07 2016 -0500 objtool: Allow building with older libelf The switch to elf_getshdr{num,strndx} post-dates the oldest tool chain the kernel is supposed to be able to build with, so try to cope with such an environment. Signed-off-by: Jan Beulich <jbeulich@suse.com> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Cc: <stable@vger.kernel.org> # for v4.6 Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jan Beulich <JBeulich@suse.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/732dae6872b7ff187d94f22bb699a12849d3fe04.1463430618.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/objtool/Makefile | 4 ++++ tools/objtool/elf.h | 5 +++++ 2 files changed, 9 insertions(+) commit 8f0dfb3d8b1120c61f6e2cc3729290db10772b2d Author: Nicholas Bellinger <nab@linux-iscsi.org> Date: Sat Feb 27 18:15:46 2016 -0800 iscsi-target: Fix early sk_data_ready LOGIN_FLAGS_READY race There is a iscsi-target/tcp login race in LOGIN_FLAGS_READY state assignment that can result in frequent errors during iscsi discovery: "iSCSI Login negotiation failed." To address this bug, move the initial LOGIN_FLAGS_READY assignment ahead of iscsi_target_do_login() when handling the initial iscsi_target_start_negotiation() request PDU during connection login. As iscsi_target_do_login_rx() work_struct callback is clearing LOGIN_FLAGS_READ_ACTIVE after subsequent calls to iscsi_target_do_login(), the early sk_data_ready ahead of the first iscsi_target_do_login() expects LOGIN_FLAGS_READY to also be set for the initial login request PDU. As reported by Maged, this was first obsered using an MSFT initiator running across multiple VMWare host virtual machines with iscsi-target/tcp. Reported-by: Maged Mokhtar <mmokhtar@binarykinetics.com> Tested-by: Maged Mokhtar <mmokhtar@binarykinetics.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target_nego.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 2d6b1d403ebeba464cc43b768f42fb2a612d9b99 Author: Gerd Hoffmann <kraxel@redhat.com> Date: Thu May 12 19:06:56 2016 +0200 qxl: catch qxlfb_create_pinned_object failures Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463072816-11788-1-git-send-email-kraxel@redhat.com drivers/gpu/drm/qxl/qxl_fb.c | 3 +++ 1 file changed, 3 insertions(+) commit f9628c2a8ecce1d9fbd74893e42bb0edd4c30fd4 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 12 22:54:57 2016 +0300 drm/exynos/hdmi: add a missing tab Smatch warns that the if statement isn't indented. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/20160512195457.GA19095@mwanda drivers/gpu/drm/exynos/exynos_hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3995b3954eba2d5768d655ea2ef9ad8054f1b06d Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu May 12 20:25:22 2016 +0200 drm/fb-cma-helper: Add function drm_fb_cma_create_with_funcs() Add drm_fb_cma_create_with_funcs() for drivers that need to set the dirty() callback. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463077523-23959-3-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_fb_cma_helper.c | 31 +++++++++++++++++++++++++------ include/drm/drm_fb_cma_helper.h | 3 +++ 2 files changed, 28 insertions(+), 6 deletions(-) commit fdce184609ee56bc4d035b0886458625154a7e98 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu May 12 20:25:21 2016 +0200 drm/fb-cma-helper: Use const for drm_framebuffer_funcs argument drm_framebuffer_init() uses const for the drm_framebuffer_funcs argument so use that on drm_fb_cma_alloc() and drm_fbdev_cma_create_with_funcs() as well. Cc: laurent.pinchart@ideasonboard.com Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1463077523-23959-2-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_fb_cma_helper.c | 4 ++-- include/drm/drm_fb_cma_helper.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit fabd9106f758714ed614c8c2a7321386aa58bdb1 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon May 9 16:34:11 2016 +0200 drm: Drop connector argument from __drm_atomic_helper_connector_destroy_state It's unused, and really this helper should only look at the state structure and nothing else. Note that this conflicts with a patch from Dave that adds refcounting to drm_connectors. It's not yet clear whether the check Dave adds for connector != NULL is really needed or the right check. v2: Fix commmit message (Laurent). Cc: Dave Airlie <airlied@gmail.com> Acked-by: Thierry Reding <thierry.reding@gmail.com> Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462804451-15318-3-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_atomic_helper.c | 9 +++------ include/drm/drm_atomic_helper.h | 3 +-- 2 files changed, 4 insertions(+), 8 deletions(-) commit 2f701695fd3a5876cd302662554f6c0ece5197eb Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon May 9 16:34:10 2016 +0200 drm: Drop plane argument from __drm_atomic_helper_plane_destroy_state It's unused, and really this helper should only look at the state structure and nothing else. v2: Fix commit message (Laurent). v3: Rebase onto mtk driver merge. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Eric Anholt <eric@anholt.net> Cc: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Cc: Inki Dae <inki.dae@samsung.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Mark Yao <mark.yao@rock-chips.com> Acked-by: Thierry Reding <thierry.reding@gmail.com> Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462804451-15318-2-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_atomic_helper.c | 8 +++----- drivers/gpu/drm/exynos/exynos_drm_plane.c | 2 +- drivers/gpu/drm/mediatek/mtk_drm_plane.c | 2 +- drivers/gpu/drm/omapdrm/omap_plane.c | 2 +- drivers/gpu/drm/rcar-du/rcar_du_plane.c | 2 +- drivers/gpu/drm/rcar-du/rcar_du_vsp.c | 2 +- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 2 +- drivers/gpu/drm/tegra/dc.c | 4 ++-- drivers/gpu/drm/vc4/vc4_plane.c | 2 +- include/drm/drm_atomic_helper.h | 3 +-- 10 files changed, 13 insertions(+), 16 deletions(-) commit ec2dc6a0fe38de8d73a7b7638a16e7d33a19a5eb Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon May 9 16:34:09 2016 +0200 drm: Drop crtc argument from __drm_atomic_helper_crtc_destroy_state It's unused, and really this helper should only look at the state structure and nothing else. v2: Rebase on top of rockchip changes v3: Drop unrelated hunk, spotted by Laurent. v4: Rebase onto mtk driver merge. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Eric Anholt <eric@anholt.net> Cc: Mark Yao <mark.yao@rock-chips.com> Acked-by: Thierry Reding <thierry.reding@gmail.com> Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462804451-15318-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 2 +- drivers/gpu/drm/drm_atomic_helper.c | 8 +++----- drivers/gpu/drm/i915/intel_display.c | 4 ++-- drivers/gpu/drm/mediatek/mtk_drm_crtc.c | 2 +- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 2 +- drivers/gpu/drm/tegra/dc.c | 4 ++-- drivers/gpu/drm/vc4/vc4_crtc.c | 2 +- include/drm/drm_atomic_helper.h | 3 +-- 8 files changed, 12 insertions(+), 15 deletions(-) commit a8ad0bd84f986072314595d05444719fdf29e412 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon May 9 11:04:54 2016 +0100 drm: Remove unused drm_device from drm_gem_object_lookup() drm_gem_object_lookup() has never required the drm_device for its file local translation of the user handle to the GEM object. Let's remove the unused parameter and save some space. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: dri-devel@lists.freedesktop.org Cc: Dave Airlie <airlied@redhat.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> [danvet: Fixup kerneldoc too.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 3 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 10 +++++----- drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 2 +- drivers/gpu/drm/armada/armada_crtc.c | 2 +- drivers/gpu/drm/armada/armada_fb.c | 2 +- drivers/gpu/drm/armada/armada_gem.c | 6 +++--- drivers/gpu/drm/armada/armada_gem.h | 4 ++-- drivers/gpu/drm/ast/ast_main.c | 4 ++-- drivers/gpu/drm/ast/ast_mode.c | 2 +- drivers/gpu/drm/bochs/bochs_mm.c | 4 ++-- drivers/gpu/drm/cirrus/cirrus_main.c | 4 ++-- drivers/gpu/drm/drm_fb_cma_helper.c | 2 +- drivers/gpu/drm/drm_gem.c | 14 ++++---------- drivers/gpu/drm/drm_gem_cma_helper.c | 2 +- drivers/gpu/drm/drm_prime.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 8 ++++---- drivers/gpu/drm/exynos/exynos_drm_fb.c | 3 +-- drivers/gpu/drm/exynos/exynos_drm_gem.c | 10 +++++----- drivers/gpu/drm/gma500/framebuffer.c | 2 +- drivers/gpu/drm/gma500/gem.c | 2 +- drivers/gpu/drm/gma500/gma_display.c | 2 +- drivers/gpu/drm/i915/i915_gem.c | 22 +++++++++++----------- drivers/gpu/drm/i915/i915_gem_tiling.c | 4 ++-- drivers/gpu/drm/i915/intel_display.c | 3 +-- drivers/gpu/drm/i915/intel_overlay.c | 2 +- drivers/gpu/drm/mgag200/mgag200_cursor.c | 2 +- drivers/gpu/drm/mgag200/mgag200_main.c | 4 ++-- drivers/gpu/drm/msm/mdp/mdp4/mdp4_crtc.c | 2 +- drivers/gpu/drm/msm/mdp/mdp5/mdp5_crtc.c | 2 +- drivers/gpu/drm/msm/msm_drv.c | 6 +++--- drivers/gpu/drm/msm/msm_fb.c | 3 +-- drivers/gpu/drm/msm/msm_gem.c | 2 +- drivers/gpu/drm/nouveau/dispnv04/crtc.c | 2 +- drivers/gpu/drm/nouveau/nouveau_display.c | 4 ++-- drivers/gpu/drm/nouveau/nouveau_gem.c | 8 ++++---- drivers/gpu/drm/nouveau/nv50_display.c | 2 +- drivers/gpu/drm/omapdrm/omap_drv.c | 6 +++--- drivers/gpu/drm/omapdrm/omap_drv.h | 4 ++-- drivers/gpu/drm/omapdrm/omap_fb.c | 2 +- drivers/gpu/drm/omapdrm/omap_gem.c | 2 +- drivers/gpu/drm/qxl/qxl_display.c | 6 ++++-- drivers/gpu/drm/qxl/qxl_dumb.c | 2 +- drivers/gpu/drm/qxl/qxl_ioctl.c | 11 +++++------ drivers/gpu/drm/radeon/radeon_cs.c | 2 +- drivers/gpu/drm/radeon/radeon_cursor.c | 2 +- drivers/gpu/drm/radeon/radeon_display.c | 2 +- drivers/gpu/drm/radeon/radeon_gem.c | 16 ++++++++-------- drivers/gpu/drm/rockchip/rockchip_drm_fb.c | 3 +-- drivers/gpu/drm/rockchip/rockchip_drm_gem.c | 2 +- drivers/gpu/drm/tegra/drm.c | 20 ++++++++++---------- drivers/gpu/drm/tegra/fb.c | 2 +- drivers/gpu/drm/tegra/gem.c | 2 +- drivers/gpu/drm/udl/udl_fb.c | 2 +- drivers/gpu/drm/udl/udl_gem.c | 2 +- drivers/gpu/drm/vc4/vc4_bo.c | 2 +- drivers/gpu/drm/vc4/vc4_gem.c | 2 +- drivers/gpu/drm/vgem/vgem_drv.c | 2 +- drivers/gpu/drm/virtio/virtgpu_display.c | 4 ++-- drivers/gpu/drm/virtio/virtgpu_gem.c | 2 +- drivers/gpu/drm/virtio/virtgpu_ioctl.c | 11 +++++------ include/drm/drm_gem.h | 4 +--- 65 files changed, 134 insertions(+), 147 deletions(-) commit 8b3db9798c689ba2dc509f6ca1a8c7e1c1a3e62a Author: Dan Williams <dan.j.williams@intel.com> Date: Wed Feb 24 14:02:06 2016 -0800 dax: fallback from pmd to pte on error In preparation for consulting a badblocks list in pmem_direct_access(), teach dax_pmd_fault() to fallback rather than fail immediately upon encountering an error. The thought being that reducing the span of the dax request may avoid the error region. Reviewed-by: Jeff Moyer <jmoyer@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a8078b1fc616da6112eb95f0063cd34531d4ccf0 Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:57 2016 -0600 block: Update blkdev_dax_capable() for consistency blkdev_dax_capable() is similar to bdev_dax_supported(), but needs to remain as a separate interface for checking dax capability of a raw block device. Rename and relocate blkdev_dax_capable() to keep them maintained consistently, and call bdev_direct_access() for the dax capability check. There is no change in the behavior. Link: https://lkml.org/lkml/2016/5/9/950 Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Jan Kara <jack@suse.cz> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@fb.com> Cc: Andreas Dilger <adilger.kernel@dilger.ca> Cc: Jan Kara <jack@suse.cz> Cc: Dave Chinner <david@fromorbit.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> block/ioctl.c | 30 ------------------------------ fs/block_dev.c | 39 +++++++++++++++++++++++++++++++++++++-- include/linux/blkdev.h | 1 + include/linux/fs.h | 8 -------- 4 files changed, 38 insertions(+), 40 deletions(-) commit 1e937cddd1ff4b823fc9d148ebabd443f105211e Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:56 2016 -0600 xfs: Add alignment check for DAX mount When a partition is not aligned by 4KB, mount -o dax succeeds, but any read/write access to the filesystem fails, except for metadata update. Call bdev_dax_supported() to perform proper precondition checks which includes this partition alignment check. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Cc: Dave Chinner <david@fromorbit.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/xfs/xfs_super.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 284854be2b85e967d17c098a1d4c176b5cd37eb3 Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:55 2016 -0600 ext2: Add alignment check for DAX mount When a partition is not aligned by 4KB, mount -o dax succeeds, but any read/write access to the filesystem fails, except for metadata update. Call bdev_dax_supported() to perform proper precondition checks which includes this partition alignment check. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Jan Kara <jack@suse.cz> Cc: Jan Kara <jack@suse.cz> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/ext2/super.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 87eefeb4e80b1526be83e670a08d059a003b7d0e Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:54 2016 -0600 ext4: Add alignment check for DAX mount When a partition is not aligned by 4KB, mount -o dax succeeds, but any read/write access to the filesystem fails, except for metadata update. Call bdev_dax_supported() to perform proper precondition checks which includes this partition alignment check. Reported-by: Micah Parrish <micah.parrish@hpe.com> Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Jan Kara <jack@suse.cz> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Andreas Dilger <adilger.kernel@dilger.ca> Cc: Jan Kara <jack@suse.cz> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/ext4/super.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 2d96afc8f70ef86c66a0b5d80c24a27d6dd13df3 Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:53 2016 -0600 block: Add bdev_dax_supported() for dax mount checks DAX imposes additional requirements to a device. Add bdev_dax_supported() which performs all the precondition checks necessary for filesystem to mount the device with dax option. Also add a new check to verify if a partition is aligned by 4KB. When a partition is unaligned, any dax read/write access fails, except for metadata update. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@fb.com> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Andreas Dilger <adilger.kernel@dilger.ca> Cc: Jan Kara <jack@suse.cz> Cc: Dave Chinner <david@fromorbit.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/block_dev.c | 45 +++++++++++++++++++++++++++++++++++++++++++++ include/linux/blkdev.h | 1 + 2 files changed, 46 insertions(+) commit 2af3a8159cd204fc8437ed2f75863f0fb930f0d0 Author: Toshi Kani <toshi.kani@hpe.com> Date: Tue May 10 10:23:52 2016 -0600 block: Add vfs_msg() interface In preparation of moving DAX capability checks to the block layer from filesystem code, add a VFS message interface that aligns with filesystem's message format. For instance, a vfs_msg() message followed by XFS messages in case of a dax mount error may look like: VFS (pmem0p1): error: unaligned partition for dax XFS (pmem0p1): DAX unsupported by block device. Turning off DAX. XFS (pmem0p1): Mounting V5 Filesystem : vfs_msg() is largely based on ext4_msg(). Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Jens Axboe <axboe@fb.com> Cc: "Theodore Ts'o" <tytso@mit.edu> Cc: Andreas Dilger <adilger.kernel@dilger.ca> Cc: Jan Kara <jack@suse.cz> Cc: Dave Chinner <david@fromorbit.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Boaz Harrosh <boaz@plexistor.com> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/block_dev.c | 12 ++++++++++++ include/linux/blkdev.h | 11 +++++++++++ 2 files changed, 23 insertions(+) commit 7795bec89ebf927ea3ad9ed5f396c227e5c73271 Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:53 2016 +0200 dax: Remove redundant inode size checks Callers of dax fault handlers must make sure these calls cannot race with truncate. Thus it is enough to check inode size when entering the function and we don't have to recheck it again later in the handler. Note that inode size itself can be decreased while the fault handler runs but filesystem locking prevents against any radix tree or block mapping information changes resulting from the truncate and that is what we really care about. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 60 +----------------------------------------------------------- 1 file changed, 1 insertion(+), 59 deletions(-) commit c3d98e39d5b37320b15f227686575d58f676e6ef Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:52 2016 +0200 dax: Remove pointless writeback from dax_do_io() dax_do_io() is calling filemap_write_and_wait() if DIO_LOCKING flags is set. Presumably this was copied over from direct IO code. However DAX inodes have no pagecache pages to write so the call is pointless. Remove it. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) commit 069c77bc9eaee70fa9ecbd942372b1693b8cdeb0 Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:51 2016 +0200 dax: Remove zeroing from dax_io() All the filesystems are now zeroing blocks themselves for DAX IO to avoid races between dax_io() and dax_fault(). Remove the zeroing code from dax_io() and add warning to catch the case when somebody unexpectedly returns new or unwritten buffer. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 28 ++++++++++------------------ 1 file changed, 10 insertions(+), 18 deletions(-) commit 2b10945c532c165a824f541df76a15ed0be04d78 Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:50 2016 +0200 dax: Remove dead zeroing code from fault handlers Now that all filesystems zero out blocks allocated for a fault handler, we can just remove the zeroing from the handler itself. Also add checks that no filesystem returns to us unwritten or new buffer. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) commit 86b0624e42d03a424e9571b8591d191c436f9af1 Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:49 2016 +0200 ext2: Avoid DAX zeroing to corrupt data Currently ext2 zeroes any data blocks allocated for DAX inode however it still returns them as BH_New. Thus DAX code zeroes them again in dax_insert_mapping() which can possibly overwrite the data that has been already stored to those blocks by a racing dax_io(). Avoid marking pre-zeroed buffers as new. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/ext2/inode.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9b6cd5f76d60b563d75e55e432e03ed134761432 Author: Jan Kara <jack@suse.cz> Date: Mon May 16 17:17:04 2016 +0200 ext2: Fix block zeroing in ext2_get_blocks() for DAX When zeroing allocated blocks for DAX, we accidentally zeroed only the first allocated block instead of all of them. So far this problem is hidden by the fact that page faults always need only a single block and DAX write code zeroes blocks again. But the zeroing in DAX code is racy and needs to be removed so fix the zeroing in ext2 to zero all allocated blocks. Reported-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/ext2/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7c10ddf87472c07eabc206e273dc59f77c700858 Merge: 99ee872 d3450e0 Author: Dave Airlie <airlied@redhat.com> Date: Tue May 17 16:34:43 2016 +1000 Merge branch 'drm-uapi-extern-c-fixes' of https://github.com/evelikov/linux into drm-next Not the biggest fan of doing it this way, but what the hell. * 'drm-uapi-extern-c-fixes' of https://github.com/evelikov/linux: (22 commits) drm/vmwgfx: add extern C guard for the UAPI header drm/virgl: add extern C guard for the UAPI header drm/via: add extern C guard for the UAPI header drm/vc4: add extern C guard for the UAPI header drm/tegra: add extern C guard for the UAPI header drm/sis: add extern C guard for the UAPI header drm/savage: add extern C guard for the UAPI header drm/radeon: add extern C guard for the UAPI header drm/r128: add extern C guard for the UAPI header drm/qxl: add extern C guard for the UAPI header drm/omap: add extern C guard for the UAPI header drm/nouveau: drop drm/ prefix from include drm/nouveau: add extern C guard for the UAPI header drm/msm: add extern C guard for the UAPI header drm/mga: add extern C guard for the UAPI header drm/i915: add extern C guard for the UAPI header drm/i810: add extern C guard for the UAPI header drm/exynos: add extern C guard for the UAPI header drm/etnaviv: add extern C guard for the UAPI header drm: add extern C guard for the UAPI headers ... commit fb75a2bb53a16069e2837ea1a4fa1bd99d636dd4 Author: Marek Vasut <marex@denx.de> Date: Tue May 17 14:01:18 2016 +0800 nios2: Fix libgcc location detection The extra CFLAGS required for correct operation of the toolchain are not propagated into the libgcc detection code. In case of the compiler from poky sdk, these extra CFLAGS contain the location of compiler sysroot (the --sysroot= option) and without this option, the location of libgcc is not properly reported. Add the missing CFLAGS to address this issue. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Ley Foon Tan <lftan@altera.com> Cc: Romain Perier <romain.perier@free-electrons.com> Acked-by: Romain Perier <romain.perier@free-electrons.com> Acked-by: Ley Foon Tan <lftan@altera.com> arch/nios2/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4a6b27b79da5ccc6b85dc05bbe6a091e58be896a Author: Josh Poimboeuf <jpoimboe@redhat.com> Date: Mon May 16 15:16:18 2016 -0500 crypto: sha1-mb - make sha1_x8_avx2() conform to C function ABI Megha Dey reported a kernel panic in crypto code. The problem is that sha1_x8_avx2() clobbers registers r12-r15 without saving and restoring them. Before commit aec4d0e301f1 ("x86/asm/crypto: Simplify stack usage in sha-mb functions"), those registers were saved and restored by the callers of the function. I removed them with that commit because I didn't realize sha1_x8_avx2() clobbered them. Fix the potential undefined behavior associated with clobbering the registers and make the behavior less surprising by changing the registers to be callee saved/restored to conform with the C function call ABI. Also, rdx (aka RSP_SAVE) doesn't need to be saved: I verified that none of the callers rely on it being saved, and it's not a callee-saved register in the C ABI. Fixes: aec4d0e301f1 ("x86/asm/crypto: Simplify stack usage in sha-mb functions") Cc: stable@vger.kernel.org # 4.6 Reported-by: Megha Dey <megha.dey@linux.intel.com> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> arch/x86/crypto/sha-mb/sha1_x8_avx2.S | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 683ad8092cd262a02d01377dd17a29d492438b90 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 13:05:45 2016 -0700 x86/efi: Fix 7-parameter efi_call()s Alex Thorlton reported that the SGI/UV code crashes in the efi_call() code when invoked with 7 parameters, due to: mov (%rsp), %rax mov 8(%rax), %rax ... mov %rax, 40(%rsp) Offset 8 is only true if CONFIG_FRAME_POINTERS is disabled, with frame pointers enabled it should be 16. Furthermore, the SAVE_XMM code saves the old stack pointer, but that's just crazy. It saves the stack pointer *AFTER* we've done the: FRAME_BEGIN ... which will have *changed* the stack pointer, depending on whether stack frames are enabled or not. So when the code then does: mov (%rsp), %rax ... we now move that old stack pointer into %rax, but the offset off that stack pointer will depend on whether that FRAME_BEGIN saved off %rbp or not. So that whole 8-vs-16 offset confusion depends on the frame pointer! If frame pointers were enabled, it will be 16. If they weren't, it will be 8. The right fix is to just get rid of that silly conditional frame pointer thing, and always use frame pointers in this stub function. And then we don't need that (odd) load to get the old stack pointer into %rax - we can just use the frame pointer. Reported-by: Alex Thorlton <athorlton@sgi.com> Tested-by: Alex Thorlton <athorlton@sgi.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/CA%2B55aFzBS2v%3DWnEH83cUDg7XkOremFqJ30BJwF40dCYjReBkUQ@mail.gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/platform/efi/efi_stub_64.S | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 0e0162bb8c008fa7742f69d4d4982c8a37b88f95 Merge: ae05327 38b78a5 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue May 17 02:17:59 2016 -0400 Merge branch 'ovl-fixes' into for-linus Backmerge to resolve a conflict in ovl_lookup_real(); "ovl_lookup_real(): use lookup_one_len_unlocked()" instead, but it was too late in the cycle to rebase. commit ff7199b04f08e1a72637ba66cd2c05842dc592d0 Author: Nicholas Bellinger <nab@linux-iscsi.org> Date: Sat May 14 22:28:51 2016 -0700 cxgbit: Use type ISCSI_CXGBIT + cxgbit tpg_np attribute Instead of having cxgbit use type ISCSI_HW_OFFLOAD + 'hw_offload' tpg_np attribute, it should be using it's own driver specific type + attribute Cc: Varun Prakash <varun@chelsio.com> Cc: Hariprasad Shenai <hariprasad@chelsio.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/cxgbit/cxgbit_main.c | 2 +- drivers/target/iscsi/iscsi_target_configfs.c | 14 +++++++------- include/target/iscsi/iscsi_target_core.h | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) commit bd027d856d3d7260017d0dc932201ce5fd7561f9 Author: Nicholas Bellinger <nab@linux-iscsi.org> Date: Sat May 14 22:23:34 2016 -0700 iscsi-target: Convert transport drivers to signal rdma_shutdown Instead of special casing the handful of callers that check for iser-target rdma verbs specific shutdown, use a simple flag at iscsit_transport->rdma_shutdown so each driver can signal this. Also, update iscsi-target/tcp + cxgbit to rdma_shutdown = false. Cc: Varun Prakash <varun@chelsio.com> Cc: Hariprasad Shenai <hariprasad@chelsio.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/infiniband/ulp/isert/ib_isert.c | 1 + drivers/target/iscsi/cxgbit/cxgbit_main.c | 1 + drivers/target/iscsi/iscsi_target.c | 10 ++++------ include/target/iscsi/iscsi_transport.h | 1 + 4 files changed, 7 insertions(+), 6 deletions(-) commit d4b3fa4b0881b600ddeee9dd47b27dea9709f322 Author: Nicholas Bellinger <nab@linux-iscsi.org> Date: Sat May 14 21:44:01 2016 -0700 iscsi-target: Make iscsi_tpg_np driver show/store use generic code Go ahead and fold the duplicate iscsi_tpg_np driver attribute show/store functions into generic callers, invoked by current driver specific functions. This allows for future v4.8+ changes to have iscsi_target_mod use tpg_np driver attributes at runtime, instead of having the defaults hardcoded in iscsi_target_configfs.c. Also, drop the unused/legacy 'sctp' attribute for non standard RFC-3720 operation with IPPROTO_SCTP. Cc: Varun Prakash <varun@chelsio.com> Cc: Hariprasad Shenai <hariprasad@chelsio.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target_configfs.c | 199 ++++++--------------------- 1 file changed, 41 insertions(+), 158 deletions(-) commit f9114a54c1d828abbe87ac446a2da49d9720203f Merge: 0f5c85f ba16db3 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:15:34 2016 +0530 Merge branch 'topic/xilinx' into for-linus commit 0f5c85f48a3d5cb4f551a7d68592085e75591df3 Merge: 53b84ba 86e486a Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:15:27 2016 +0530 Merge branch 'topic/tegra' into for-linus commit 53b84bad9e49e28faff74c51b137d036944291f4 Merge: 82770a2 a90e173 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:15:20 2016 +0530 Merge branch 'topic/sun6i' into for-linus commit 82770a2f657ac4674db6db95b906218b526ef2a6 Merge: ba8b6cc0 42d236f Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:15:13 2016 +0530 Merge branch 'topic/qcom' into for-linus commit ba8b6cc07267fbf792cb7521cabc13879b227f4f Merge: 4dc5006 4e0def8 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:15:06 2016 +0530 Merge branch 'topic/pxa' into for-linus commit 4dc50060c9fe68db800b14b2996de7ab88240986 Merge: 112db20 f9cd476 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:59 2016 +0530 Merge branch 'topic/pl08x' into for-linus commit 112db20e8106a28b1c0b6997d614f43483c90ded Merge: ee5644c c39290a Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:50 2016 +0530 Merge branch 'topic/mv_xor' into for-linus commit ee5644ce4b391e3e46064756da0d68b07fecc12d Merge: 8dfc27a 77fc397 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:40 2016 +0530 Merge branch 'topic/mpc512x' into for-linus commit 8dfc27af62b37b98c29768be7057663fd5c16c4d Merge: 5621488 17b3cf4 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:30 2016 +0530 Merge branch 'topic/hsu' into for-linus commit 56214883c586a235ea73c07a423b27ee62ea2810 Merge: 95c4dc7 3a14c66 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:16 2016 +0530 Merge branch 'topic/dw' into for-linus commit 95c4dc7b2c622a3cc41535f67f46dd31332186c8 Merge: a365c96 0eef727 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:14:07 2016 +0530 Merge branch 'topic/bcm' into for-linus commit a365c9685438713dbf88828282c4699f571b97de Merge: 511deae 20ea6be Author: Vinod Koul <vinod.koul@intel.com> Date: Tue May 17 10:13:40 2016 +0530 Merge branch 'topic/core' into for-linus commit 16490980e396fac079248b23b1dd81e7d48bebf3 Merge: 46c1345 dab2e29 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:51:04 2016 -0700 Merge tag 'device-properties-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull device properties update from Rafael Wysocki: "Generic device properties framework update. Just one commit reworking the handling of built-in properties initialization and updating a few drivers in accordance with the core framework changes" * tag 'device-properties-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: device property: don't bother the drivers with struct property_set commit 46c13450624e36302547a2ac3695f2350fe7ffc3 Merge: d57d394 fc72395 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:41:41 2016 -0700 Merge tag 'acpi-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull ACPI updates from Rafael Wysocki: "The new features here are ACPI 6.1 support (and some previously missing bits of ACPI 6.0 support) in ACPICA and two new drivers, a driver for the ACPI Generic Event Device (GED) feature introduced by ACPI 6.1 and the INT3406 thermal driver for display thermal management. Also the value returned by the _HRV (hardware revision) ACPI object will be exported to user space via sysfs now. In addition to that, ACPI on ARM64 will not depend on EXPERT any more. The rest is mostly fixes and cleanups and some code reorganization. Specifics: - In-kernel ACPICA code update to the upstream release 20160422 adding support for ACPI 6.1 along with some previously missing bits of ACPI 6.0 support, making a fair amount of fixes and cleanups and reducing divergences between the upstream ACPICA and the in-kernel code (Bob Moore, Lv Zheng, Al Stone, Aleksey Makarov, Will Miles) - ACPI Generic Event Device (GED) support and a fix for it (Sinan Kaya, Paul Gortmaker) - INT3406 thermal driver for display thermal management and ACPI backlight support code reorganization related to it (Aaron Lu, Arnd Bergmann) - Support for exporting the value returned by the _HRV (hardware revision) ACPI object via sysfs (Betty Dall) - Removal of the EXPERT dependency for ACPI on ARM64 (Mark Brown) - Rework of the handling of ACPI _OSI mechanism allowing the _OSI("Darwin") support to be overridden from the kernel command line among other things (Lv Zheng, Chen Yu) - Rework of the ACPI tables override mechanism to prepare it for the introduction of overlays support going forward (Lv Zheng, Rafael Wysocki) - Fixes related to the ECDT support and module-level execution of AML (Lv Zheng) - ACPI PCI interrupts management update to make it work better on ARM64 mostly (Sinan Kaya) - ACPI SRAT handling update to make the code process all entires in the table order regardless of the entry type (Lukasz Anaczkowski) - EFI power off support for full-hardware ACPI platforms that don't support ACPI S5 (Chen Yu) - Fixes and cleanups related to the ACPI core's sysfs interface (Dan Carpenter, Betty Dall) - acpi_dev_present() API rework to reduce possible confusion related to it (Lukas Wunner) - Removal of CLK_IS_ROOT from two ACPI drivers (Stephen Boyd)" * tag 'acpi-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (82 commits) ACPI / video: mark acpi_video_get_levels() inline Thermal / ACPI / video: add INT3406 thermal driver ACPI / GED: make evged.c explicitly non-modular ACPI / tables: Fix DSDT override mechanism ACPI / sysfs: fix error code in get_status() ACPICA: Update version to 20160422 ACPICA: Move all ASCII utilities to a common file ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write() ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support in acpi_hw_read() ACPICA: Executer: Introduce a set of macros to handle bit width mask generation ACPICA: Hardware: Add optimized access bit width support ACPICA: Utilities: Add ACPI_IS_ALIGNED() macro ACPICA: Renamed some #defined flag constants for clarity ACPICA: ACPI 6.0, tools/iasl: Add support for new resource descriptors ACPICA: ACPI 6.0: Update _BIX support for new package element ACPICA: ACPI 6.1: Support for new PCCT subtable ACPICA: Refactor evaluate_object to reduce nesting ACPICA: Divergence: remove unwanted spaces for typedef ACPI,PCI,IRQ: remove SCI penalize function ACPI,PCI,IRQ: remove redundant code in acpi_irq_penalty_init() .. commit b1725423732dd7b58856adcc03cbf1145fcea491 Author: Philippe Reynes <tremyfr@gmail.com> Date: Tue May 17 00:32:34 2016 +0200 net: ethernet: fec-mpc52xx: use phy_ethtool_{get|set}_link_ksettings There are two generics functions phy_ethtool_{get|set}_link_ksettings, so we can use them instead of defining the same code in the driver. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_mpc52xx.c | 26 ++------------------------ 1 file changed, 2 insertions(+), 24 deletions(-) commit a54d20f85ab12fab4873d2947b2be965430bf609 Author: Philippe Reynes <tremyfr@gmail.com> Date: Tue May 17 00:32:33 2016 +0200 net: ethernet: fec-mpc52xx: use phydev from struct net_device The private structure contain a pointer to phydev, but the structure net_device already contain such pointer. So we can remove the pointer phydev in the private structure, and update the driver to use the one contained in struct net_device. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_mpc52xx.c | 43 +++++++++++++--------------- 1 file changed, 20 insertions(+), 23 deletions(-) commit 9295c034726e025395e6eff3013fa9e3753bcb39 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Mon May 16 23:06:53 2016 +0200 bpf, doc: fix typo on bpf_asm descriptions Fix description of some of the bpf_asm tool related jump instructions and generally move them to format A <op> k. Reported-by: Sebastian Amend <sebastian.amend@googlemail.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/filter.txt | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit a8df35d45800c2af2b9bac04a8f9d4e426862e4d Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Mon May 16 12:41:07 2016 -0300 stmmac: hardware TX COE doesn't work when force_thresh_dma_mode is set Commit f748be531d70 ("stmmac: support new GMAC4") reverted a previous fix by mistake. This commit re-applies said fix: commit dec2165ff38a99f937fe61875d102c6c8596c815 Author: Sonic Zhang <sonic.zhang@analog.com> Date: Thu Jan 22 14:55:57 2015 +0800 stmmac: hardware TX COE doesn't work when force_thresh_dma_mode is set Clear the TX COE bit when force_thresh_dma_mode is set even hardware dma capability says support. Tested on BF609. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Acked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> Tested on LPC4350 Hitex board. Fixes: f748be531d70 ("stmmac: support new GMAC4") Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Tested-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit d57d39431924d1628ac9b93a2de7f806fc80680a Merge: 3e21e5d 27c4a1c Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:17:22 2016 -0700 Merge tag 'pm-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management updates from Rafael Wysocki: "The majority of changes go into the cpufreq subsystem this time. To me, quite obviously, the biggest ticket item is the new "schedutil" governor. Interestingly enough, it's the first new cpufreq governor since the beginning of the git era (except for some out-of-the-tree ones). There are two main differences between it and the existing governors. First, it uses the information provided by the scheduler directly for making its decisions, so it doesn't have to track anything by itself. Second, it can invoke drivers (supporting that feature) to adjust CPU performance right away without having to spawn work items to be executed in process context or similar. Currently, the acpi-cpufreq driver is the only one supporting that mode of operation, but then it is used on a large number of systems. The "schedutil" governor as included here is very simple and mostly regarded as a foundation for future work on the integration of the scheduler with CPU power management (in fact, there is work in progress on top of it already). Nevertheless it works and the preliminary results obtained with it are encouraging. There also is some consolidation of CPU frequency management for ARM platforms that can add their machine IDs the the new stub dt-platdev driver now and that will take care of creating the requisite platform device for cpufreq-dt, so it is not necessary to do that in platform code any more. Several ARM platforms are switched over to using this generic mechanism. In addition to that, the intel_pstate driver is now going to respect CPU frequency limits set by the platform firmware (or a BMC) and provided via the ACPI _PPC object. The devfreq subsystem is getting a new "passive" governor for SoCs subsystems that will depend on somebody else to manage their voltage rails and its support for Samsung Exynos SoCs is consolidated. The rest is support for new hardware (Intel Broxton support in intel_idle for one example), bug fixes, optimizations and cleanups in a number of places. Specifics: - New cpufreq "schedutil" governor (making decisions based on CPU utilization information provided by the scheduler and capable of switching CPU frequencies right away if the underlying driver supports that) and support for fast frequency switching in the acpi-cpufreq driver (Rafael Wysocki) - Consolidation of CPU frequency management on ARM platforms allowing them to get rid of some platform-specific boilerplate code if they are going to use the cpufreq-dt driver (Viresh Kumar, Finley Xiao, Marc Gonzalez) - Support for ACPI _PPC and CPU frequency limits in the intel_pstate driver (Srinivas Pandruvada) - Fixes and cleanups in the cpufreq core and generic governor code (Rafael Wysocki, Sai Gurrappadi) - intel_pstate driver optimizations and cleanups (Rafael Wysocki, Philippe Longepe, Chen Yu, Joe Perches) - cpufreq powernv driver fixes and cleanups (Akshay Adiga, Shilpasri Bhat) - cpufreq qoriq driver fixes and cleanups (Jia Hongtao) - ACPI cpufreq driver cleanups (Viresh Kumar) - Assorted cpufreq driver updates (Ashwin Chaugule, Geliang Tang, Javier Martinez Canillas, Paul Gortmaker, Sudeep Holla) - Assorted cpufreq fixes and cleanups (Joe Perches, Arnd Bergmann) - Fixes and cleanups in the OPP (Operating Performance Points) framework, mostly related to OPP sharing, and reorganization of OF-dependent code in it (Viresh Kumar, Arnd Bergmann, Sudeep Holla) - New "passive" governor for devfreq (for SoC subsystems that will rely on someone else for the management of their power resources) and consolidation of devfreq support for Exynos platforms, coding style and typo fixes for devfreq (Chanwoo Choi, MyungJoo Ham) - PM core fixes and cleanups, mostly to make it work better with the generic power domains (genpd) framework, and updates for that framework (Ulf Hansson, Thierry Reding, Colin Ian King) - Intel Broxton support for the intel_idle driver (Len Brown) - cpuidle core optimization and fix (Daniel Lezcano, Dave Gerlach) - ARM cpuidle cleanups (Jisheng Zhang) - Intel Kabylake support for the RAPL power capping driver (Jacob Pan) - AVS (Adaptive Voltage Switching) rockchip-io driver update (Heiko Stuebner) - Updates for the cpupower tool (Arjun Sreedharan, Colin Ian King, Mattia Dongili, Thomas Renninger)" * tag 'pm-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (112 commits) intel_pstate: Clean up get_target_pstate_use_performance() intel_pstate: Use sample.core_avg_perf in get_avg_pstate() intel_pstate: Clarify average performance computation intel_pstate: Avoid unnecessary synchronize_sched() during initialization cpufreq: schedutil: Make default depend on CONFIG_SMP cpufreq: powernv: del_timer_sync when global and local pstate are equal cpufreq: powernv: Move smp_call_function_any() out of irq safe block intel_pstate: Clean up intel_pstate_get() cpufreq: schedutil: Make it depend on CONFIG_SMP cpufreq: governor: Fix handling of special cases in dbs_update() PM / OPP: Move CONFIG_OF dependent code in a separate file cpufreq: intel_pstate: Ignore _PPC processing under HWP cpufreq: arm_big_little: use generic OPP functions for {init, free}_opp_table PM / OPP: add non-OF versions of dev_pm_opp_{cpumask_, }remove_table cpufreq: tango: Use generic platdev driver PM / OPP: pass cpumask by reference cpufreq: Fix GOV_LIMITS handling for the userspace governor cpupower: fix potential memory leak PM / devfreq: style/typo fixes PM / devfreq: exynos: Add the detailed correlation for Exynos5422 bus .. commit 73d9011c1f50ad3f82886d2187799acba1feb236 Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 16:52:37 2016 +0200 net: ethernet: fs-enet: use phy_ethtool_{get|set}_link_ksettings There are two generics functions phy_ethtool_{get|set}_link_ksettings, so we can use them instead of defining the same code in the driver. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/freescale/fs_enet/fs_enet-main.c | 26 ++-------------------- 1 file changed, 2 insertions(+), 24 deletions(-) commit c1c511a275c9c0a14836c2071d37946df3862c25 Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 16:52:36 2016 +0200 net: ethernet: fs-enet: use phydev from struct net_device The private structure contain a pointer to phydev, but the structure net_device already contain such pointer. So we can remove the pointer phydev in the private structure, and update the driver to use the one contained in struct net_device. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/freescale/fs_enet/fs_enet-main.c | 31 +++++++++------------- drivers/net/ethernet/freescale/fs_enet/fs_enet.h | 1 - drivers/net/ethernet/freescale/fs_enet/mac-fcc.c | 4 +-- drivers/net/ethernet/freescale/fs_enet/mac-fec.c | 6 ++--- drivers/net/ethernet/freescale/fs_enet/mac-scc.c | 2 +- 5 files changed, 18 insertions(+), 26 deletions(-) commit a29d5c9b8167dbc21a7ca8c0302e3799f9063b4e Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon May 16 21:16:54 2016 -0300 perf tools: Separate accounting of contexts and real addresses in a stack trace The perf_sample->ip_callchain->nr value includes all the entries in the ip_callchain->ip[] array, real addresses and PERF_CONTEXT_{KERNEL,USER,etc}, while what the user expects is that what is in the kernel.perf_event_max_stack sysctl or in the upcoming per event perf_event_attr.sample_max_stack knob be honoured in terms of IP addresses in the stack trace. So match the kernel support and validate chain->nr taking into account both kernel.perf_event_max_stack and kernel.perf_event_max_contexts_per_stack. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/n/tip-mgx0jpzfdq4uq4abfa40byu0@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/perf.c | 3 +++ tools/perf/util/machine.c | 26 +++++++++++++++++--------- tools/perf/util/util.c | 3 ++- tools/perf/util/util.h | 3 ++- 4 files changed, 24 insertions(+), 11 deletions(-) commit c85b03349640b34f3545503c8429fc43005e9a92 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 12 13:06:21 2016 -0300 perf core: Separate accounting of contexts and real addresses in a stack trace The perf_sample->ip_callchain->nr value includes all the entries in the ip_callchain->ip[] array, real addresses and PERF_CONTEXT_{KERNEL,USER,etc}, while what the user expects is that what is in the kernel.perf_event_max_stack sysctl or in the upcoming per event perf_event_attr.sample_max_stack knob be honoured in terms of IP addresses in the stack trace. So allocate a bunch of extra entries for contexts, and do the accounting via perf_callchain_entry_ctx struct members. A new sysctl, kernel.perf_event_max_contexts_per_stack is also introduced for investigating possible bugs in the callchain implementation by some arch. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/n/tip-3b4wnqk340c4sg4gwkfdi9yk@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Documentation/sysctl/kernel.txt | 14 ++++++++++++++ include/linux/perf_event.h | 18 ++++++++++++++++-- include/uapi/linux/perf_event.h | 1 + kernel/events/callchain.c | 10 +++++++++- kernel/sysctl.c | 9 +++++++++ 5 files changed, 49 insertions(+), 3 deletions(-) commit 3e4de4ec4cfea40994b47a79767610153edbf45b Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 12 13:01:50 2016 -0300 perf core: Add perf_callchain_store_context() helper We need have different helpers to account how many contexts we have in the sample and for real addresses, so do it now as a prep patch, to ease review. Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/n/tip-q964tnyuqrxw5gld18vizs3c@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> arch/powerpc/perf/callchain.c | 6 +++--- include/linux/perf_event.h | 2 ++ kernel/events/callchain.c | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) commit 3b1fff08038bd0792b1aa1e9703b2dd0512a3fd0 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 10 18:08:32 2016 -0300 perf core: Add a 'nr' field to perf_event_callchain_context We will use it to count how many addresses are in the entry->ip[] array, excluding PERF_CONTEXT_{KERNEL,USER,etc} entries, so that we can really return the number of entries specified by the user via the relevant sysctl, kernel.perf_event_max_contexts, or via the per event perf_event_attr.sample_max_stack knob. This way we keep the perf_sample->ip_callchain->nr meaning, that is the number of entries, be it real addresses or PERF_CONTEXT_ entries, while honouring the max_stack knobs, i.e. the end result will be max_stack entries if we have at least that many entries in a given stack trace. Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/n/tip-s8teto51tdqvlfhefndtat9r@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> arch/arm/kernel/perf_callchain.c | 2 +- arch/arm64/kernel/perf_callchain.c | 4 ++-- arch/metag/kernel/perf_callchain.c | 2 +- arch/mips/kernel/perf_event.c | 4 ++-- arch/powerpc/perf/callchain.c | 4 ++-- arch/sparc/kernel/perf_event.c | 6 +++--- arch/x86/events/core.c | 4 ++-- include/linux/perf_event.h | 6 ++++-- kernel/events/callchain.c | 3 +-- 9 files changed, 18 insertions(+), 17 deletions(-) commit cfbcf468454ab4b20f0b4b62da51920b99fdb19e Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 28 12:30:53 2016 -0300 perf core: Pass max stack as a perf_callchain_entry context This makes perf_callchain_{user,kernel}() receive the max stack as context for the perf_callchain_entry, instead of accessing the global sysctl_perf_event_max_stack. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/n/tip-kolmn1yo40p7jhswxwrc7rrd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> arch/arc/kernel/perf_event.c | 6 +++--- arch/arm/kernel/perf_callchain.c | 10 +++++----- arch/arm64/kernel/perf_callchain.c | 14 +++++++------- arch/metag/kernel/perf_callchain.c | 10 +++++----- arch/mips/kernel/perf_event.c | 12 ++++++------ arch/powerpc/perf/callchain.c | 14 +++++++------- arch/s390/kernel/perf_event.c | 4 ++-- arch/sh/kernel/perf_callchain.c | 4 ++-- arch/sparc/kernel/perf_event.c | 14 +++++++------- arch/tile/kernel/perf_event.c | 6 +++--- arch/x86/events/core.c | 14 +++++++------- arch/xtensa/kernel/perf_event.c | 10 +++++----- include/linux/perf_event.h | 16 +++++++++++----- kernel/bpf/stackmap.c | 3 ++- kernel/events/callchain.c | 20 ++++++++++++-------- 15 files changed, 84 insertions(+), 73 deletions(-) commit a831100aeefbe6d9f3e47a3e2712f82c042f1f5c Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 10 16:34:53 2016 -0300 perf core: Generalize max_stack sysctl handler So that it can be used for other stack related knobs, such as the upcoming one to tweak the max number of of contexts per stack sample. In all those cases we can only change the value if there are no perf sessions collecting stacks, so they need to grab that mutex, etc. Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/n/tip-8t3fk94wuzp8m2z1n4gc0s17@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> kernel/events/callchain.c | 5 +++-- kernel/sysctl.c | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) commit 0a77582f0407e7f9b5d775bebc31297a1b890be0 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Sun May 15 12:19:40 2016 +0900 perf symbols: Introduce DSO__NAME_KALLSYMS and DSO__NAME_KCORE Instead of using a raw string, use DSO__NAME_KALLSYMS and DSO__NAME_KCORE macros for kallsyms and kcore. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160515031935.4017.50971.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-buildid-cache.c | 8 ++++---- tools/perf/util/annotate.c | 2 +- tools/perf/util/machine.c | 2 +- tools/perf/util/symbol.c | 10 +++++----- tools/perf/util/symbol.h | 3 +++ 5 files changed, 14 insertions(+), 11 deletions(-) commit a1f3d56761df31f0ffeb215b974e26d5613e92a4 Author: Namhyung Kim <namhyung@kernel.org> Date: Fri May 13 15:01:03 2016 +0900 perf stat: Use cpu-clock event for cpu targets Currently 'perf stat' always counts task-clock event by default. But it's somewhat confusing for system-wide targets (especially with 'sleep N' as the 'sleep' task just sleeps and doesn't use cputime). Changing to cpu-clock event instead for that case makes more sense IMHO. Before: # perf stat -a sleep 0.1 Performance counter stats for 'system wide': 403.038603 task-clock (msec) # 4.001 CPUs utilized 150 context-switches # 0.372 K/sec 7 cpu-migrations # 0.017 K/sec 71 page-faults # 0.176 K/sec 23,705,169 cycles # 0.059 GHz 15,888,166 instructions # 0.67 insn per cycle 3,326,078 branches # 8.253 M/sec 87,643 branch-misses # 2.64% of all branches 0.100737009 seconds time elapsed # After: # perf stat -a sleep 0.1 Performance counter stats for 'system wide': 404.271182 cpu-clock (msec) # 4.000 CPUs utilized 143 context-switches # 0.354 K/sec 13 cpu-migrations # 0.032 K/sec 73 page-faults # 0.181 K/sec 22,119,220 cycles # 0.055 GHz 13,622,065 instructions # 0.62 insn per cycle 2,918,769 branches # 7.220 M/sec 85,033 branch-misses # 2.91% of all branches 0.101073089 seconds time elapsed # Signed-off-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1463119263-5569-3-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-stat.c | 3 +++ 1 file changed, 3 insertions(+) commit daf4f4786e8af371048e72cb37ac05190e89198a Author: Namhyung Kim <namhyung@kernel.org> Date: Fri May 13 15:01:02 2016 +0900 perf stat: Update runtime using cpu-clock event Currently only the task-clock event updates the runtime_nsec so it cannot show the metric when using cpu-clock events. However cpu clock works basically same as task-clock, so no need to not update the runtime IMHO. Before: # perf stat -a -e cpu-clock,context-switches,page-faults,cycles sleep 0.1 Performance counter stats for 'system wide': 1217.759506 cpu-clock (msec) 93 context-switches 61 page-faults 18,958,022 cycles 0.101393794 seconds time elapsed After: Performance counter stats for 'system wide': 1220.471884 cpu-clock (msec) # 12.013 CPUs utilized 118 context-switches # 0.097 K/sec 59 page-faults # 0.048 K/sec 17,941,247 cycles # 0.015 GHz 0.101594777 seconds time elapsed Signed-off-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1463119263-5569-2-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/stat-shadow.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit b0404be8d6186f9f3c23e2b5ff247e667be90652 Author: Namhyung Kim <namhyung@kernel.org> Date: Fri May 13 15:01:01 2016 +0900 perf stat: Fix indentation of stalled backend cycle The commit 140aeadc1fb5 ("perf stat: Abstract stat metrics printing") changed how shadow metrics are printed, but it missed to update the width of the stalled backend cycles event to 7.2% like others. This resulted in misaligned output like below: Performance counter stats for 'pwd': 0.638313 task-clock (msec) # 0.567 CPUs utilized 0 context-switches # 0.000 K/sec 0 cpu-migrations # 0.000 K/sec 54 page-faults # 0.085 M/sec 885,600 cycles # 1.387 GHz 558,438 stalled-cycles-frontend # 63.06% frontend cycles idle 431,355 stalled-cycles-backend # 48.71% backend cycles idle 674,956 instructions # 0.76 insn per cycle # 0.83 stalled cycles per insn 130,380 branches # 204.257 M/sec <not counted> branch-misses 0.001125426 seconds time elapsed Signed-off-by: Namhyung Kim <namhyung@kernel.org> Cc: Andi Kleen <andi@firstfloor.org> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Fixes: 140aeadc1fb5 ("perf stat: Abstract stat metrics printing") Link: http://lkml.kernel.org/r/1463119263-5569-1-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/stat-shadow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6ae98ba611ed1c11ddc5645475bc03b46a3c04e7 Author: He Kuang <hekuang@huawei.com> Date: Thu May 12 08:43:11 2016 +0000 perf symbols: Store vdso buildid unconditionally When unwinding callchains on a different machine, vdso info should be available so the unwind process won't be interrupted if address falls into vdso region. But in most cases, the addresses of sample events are not in vdso range, the buildid of a zero hit vdso won't be stored into perf.data. This patch stores vdso buildid regardless of whether the vdso is hit or not. Signed-off-by: He Kuang <hekuang@huawei.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Ekaterina Tumanova <tumanova@linux.vnet.ibm.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1463042596-61703-3-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/build-id.c | 2 +- tools/perf/util/dso.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) commit e3b03b6c1a4f3b4564be08809f58584592621a0a Author: Andi Kleen <ak@linux.intel.com> Date: Thu May 5 16:04:03 2016 -0700 perf stat: Avoid fractional digits for integer scales When the scaling factor is a full integer don't display fractional digits. This avoids unnecessary .00 output for topdown metrics with scale factors. v2: Remove redundant check. Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462489447-31832-7-git-send-email-andi@firstfloor.org [ Rename 'round' to 'stat_round' as 'round' is defined in math.h, included by this patch, and this breaks the build on ubuntu 12.04 ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-stat.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit 3e21e5dda4907ecb21a124517ab0eb1d176e5231 Merge: d9dce51 1c44711 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:10:40 2016 -0700 Merge tag 'mmc-v4.7' of git://git.linaro.org/people/ulf.hansson/mmc Pull MMC updates from Ulf Hansson: "MMC core: - Add TRACE support to be able to debug request flow - Extend/improve reset support for (e)MMC - Convert MMC pwrseq to platform device drivers - Use IDA for indexes - Some additional minor improvements MMC host: - sdhci: Re-factoring, clean-ups and improvements - sdhci-acpi|pci: Use MMC_CAP_AGGRESSIVE_PM for Broxton - omap/omap_hsmmc: Convert to use dma_request_chan() - usdhi6rol0: Add support for UHS modes - sh_mmcif: Update runtime PM support - tmio: Wolfram Sang steps in as maintainer - tmio: Add UHS-I mode support - sh_mobile_sdhi: Add UHS-I mode support - tmio/sdhi: Re-factoring, clean-ups and improvements - dw_mmc: Re-factoring and clean-ups - davinci: Convert to use dma_request_chan()" * tag 'mmc-v4.7' of git://git.linaro.org/people/ulf.hansson/mmc: (99 commits) mmc: mmc: Fix partition switch timeout for some eMMCs mmc: sh_mobile_sdhi: enable SDIO IRQs for RCar Gen3 mmc: sdio: fall back to SDIO 1.0 for broken 1.1 cards mmc: sdhci-st: correct name of sd-uhs-sdr50 property MAINTAINERS: update entry for TMIO MMC driver mmc: block: improve logging of handling emmc timeouts mmc: sdhci: removed unneeded function wrappers mmc: core: remove the invalid message in mmc_select_timing mmc: core: fix using wrong io voltage if mmc_select_hs200 fails mmc: sdhci-of-arasan: fix set_clock when a phy is supported mmc: omap: Use dma_request_chan() for requesting DMA channel mmc: mmc: Attempt to flush cache before reset mmc: sh_mobile_sdhi: check return value when changing clk mmc: sh_mobile_sdhi: only change the clock on RCar Gen2+ mmc: tmio/sdhi: introduce flag for RCar 2+ specific features mmc: sh_mobile_sdhi: make clk_update function more compact mmc: omap_hsmmc: Use dma_request_chan() for requesting DMA channel mmc: sdhci-of-at91: add presets setup mmc: usdhi6rol0: add pinctrl to set pin drive strength mmc: usdhi6rol0: add support for UHS modes ... commit 92964c79b357efd980812c4de5c1fd2ec8bb5520 Author: Herbert Xu <herbert@gondor.apana.org.au> Date: Mon May 16 17:28:16 2016 +0800 netlink: Fix dump skb leak/double free When we free cb->skb after a dump, we do it after releasing the lock. This means that a new dump could have started in the time being and we'll end up freeing their skb instead of ours. This patch saves the skb and module before we unlock so we free the right memory. Fixes: 16b304f3404f ("netlink: Eliminate kmalloc in netlink dump operation.") Reported-by: Baozeng Ding <sploving1@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Acked-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/netlink/af_netlink.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit d9dce51c9b77b803348c787165a884b6e11011f0 Merge: e2ca542 4f38c56 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:04:53 2016 -0700 Merge tag 'regulator-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator updates from Mark Brown: "A few core enhancements to deal with some of the slightly more complicated edge cases that have started cropping up in systems, both new ones and old ones that people started worrying about upstream, but otherwise a quiet release for the regulator API: - When applying constraints at system image if we have a voltage range specified and the regulator is currently configured outside the bounds of that range bring the regulator to the nearest end of the range. - When regulators are in non-regulating bypass modes make sure that we always use the voltage from the parent regulator. - Support for LP873x, PV88080, PM8894 and FAN53555 chips" * tag 'regulator-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (71 commits) regulator: rk808: Migrate to regulator core's simplified DT parsing code regulator: lp873x: Add support for lp873x PMIC regulators regulator: tps65917/palmas: Simplify multiple dereference of match->of_node regulator: tps65917/palmas: Handle possible memory allocation failure regulator: tps65917/palmas: Simplify multiple dereference of pdata->reg_init[idx] regulator: tps65917/palmas: Simplify multiple dereference of ddata->palmas_matches[idx] regulator: pwm: Use pwm_get_args() where appropriate pwm: Introduce the pwm_args concept regulator: max77686: Configure enable time to properly handle regulator enable regulator: rk808: Add rk808_reg_ops_ranges for LDO3 regulator: core: Add early supply resolution for regulators regulator: axp20x: Fix axp22x ldo_io voltage ranges regulator: tps65917/palmas: Add bypass "On" value regulator: rk808: remove unused rk808_reg_ops_ranges regulator: refactor valid_ops_mask checking code regulator: rk808: remove linear range definitions with a single range regulator: max77620: Add support for device specific ramp rate setting regulator: max77620: Add details of device specific ramp rate setting regulator: helpers: Ensure bypass register field matches ON value regulator: core: Move registration of regulator device ... commit e2ca54250d14347c35c55e9304296c2f04f3fbad Merge: 27d6caf d4ab78d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 19:00:09 2016 -0700 Merge tag 'regmap-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap Pull regmap updates from Mark Brown: "The updates for this kernel release really are trivial: - Check that max_register is set for the flat cache to avoid a crash on initialization - Fix a typo in the documentation" * tag 'regmap-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap: regcache: flat: Require max_registers to be set regmap: cache: Fix typo in cache_bypass parameter description commit 5af897e433e6ba2963c0edcb12f2f75c53d5fae4 Author: Richard Cochran <rcochran@linutronix.de> Date: Fri Mar 18 22:26:09 2016 +0100 thermal: x86_pkg_temp: Handle the FROZEN hot plug notifier actions. When performing a suspend operation, the kernel brings all of the non-boot CPUs offline, calling the hot plug notifiers with the flag, CPU_TASKS_FROZEN, set in the action code. Similarly, during resume, the CPUs are brought back online, but again the notifiers have the FROZEN flag set. While some very few drivers really need to treat suspend/resume specially, this driver unintentionally ignores the notifications. This patch changes the driver to cancel its work item when the CPU goes down, even during a suspend operation. As a result, the suspended state is no longer a special case. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: linux-pm@vger.kernel.org Signed-off-by: Richard Cochran <rcochran@linutronix.de> Signed-off-by: Zhang Rui <rui.zhang@intel.com> drivers/thermal/x86_pkg_temp_thermal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 45e093ae2830cd1264677d47ff9a95a71f5d9f9c Author: Richard Alpe <richard.alpe@ericsson.com> Date: Mon May 16 11:14:54 2016 +0200 tipc: check nl sock before parsing nested attributes Make sure the socket for which the user is listing publication exists before parsing the socket netlink attributes. Prior to this patch a call without any socket caused a NULL pointer dereference in tipc_nl_publ_dump(). Tested-and-reported-by: Baozeng Ding <sploving1@gmail.com> Signed-off-by: Richard Alpe <richard.alpe@ericsson.com> Acked-by: Jon Maloy <jon.maloy@ericsson.cm> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/socket.c | 3 +++ 1 file changed, 3 insertions(+) commit 27d6cafa7e10ca0f97b57ea4da2d8a73e41d6e65 Merge: fdb8a29 70f95b7 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 18:55:43 2016 -0700 Merge tag 'for-linus-4.7' of git://git.code.sf.net/p/openipmi/linux-ipmi Pull IPMI updates from Corey Minyard: "Some small fixes and cleanups, these latest have been in linux-next for a few weeks" * tag 'for-linus-4.7' of git://git.code.sf.net/p/openipmi/linux-ipmi: ipmi: Fix the I2C address extraction from SPMI tables IPMI: reserve memio regions separately ipmi: Fix some minor coding style issues commit 77f57761466e9aef2b57acf8ce07df11bf360e34 Author: Eric Dumazet <edumazet@google.com> Date: Sun May 15 18:16:38 2016 -0700 fq_codel: fix memory limitation drift memory_usage must be decreased in dequeue_func(), not in fq_codel_dequeue(), otherwise packets dropped by Codel algo are missing this decrease. Also we need to clear memory_usage in fq_codel_reset() Fixes: 95b58430abe7 ("fq_codel: add memory limitation per queue") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sched/sch_fq_codel.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit fd24d72ca9b52558b1511edc814951cdfe5f21cf Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 01:35:14 2016 +0200 net: ethernet: ftgmac100: use phy_ethtool_{get|set}_link_ksettings There are two generics functions phy_ethtool_{get|set}_link_ksettings, so we can use them instead of defining the same code in the driver. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/faraday/ftgmac100.c | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) commit b3c40adcc9891a709d30b620f0cabd4679a355b5 Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 01:35:13 2016 +0200 net: ethernet: ftgmac100: use phydev from struct net_device The private structure contain a pointer to phydev, but the structure net_device already contain such pointer. So we can remove the pointer phydev in the private structure, and update the driver to use the one contained in struct net_device. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/faraday/ftgmac100.c | 24 ++++++++---------------- 1 file changed, 8 insertions(+), 16 deletions(-) commit cd5f9bb4be950079e911a64972dd7311f0bf8534 Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 01:30:09 2016 +0200 net: ethernet: gianfar: use phy_ethtool_{get|set}_link_ksettings There are two generics functions phy_ethtool_{get|set}_link_ksettings, so we can use them instead of defining the same code in the driver. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/gianfar_ethtool.c | 27 ++---------------------- 1 file changed, 2 insertions(+), 25 deletions(-) commit 4c4a6b0e8fa24a628cbca3931745d482c66d303e Author: Philippe Reynes <tremyfr@gmail.com> Date: Mon May 16 01:30:08 2016 +0200 net: ethernet: gianfar: use phydev from struct net_device The private structure contain a pointer to phydev, but the structure net_device already contain such pointer. So we can remove the pointer phydev in the private structure, and update the driver to use the one contained in struct net_device. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Acked-by: Claudiu Manoil <claudiu.manoil@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/gianfar.c | 42 +++++++++++++----------- drivers/net/ethernet/freescale/gianfar.h | 1 - drivers/net/ethernet/freescale/gianfar_ethtool.c | 24 +++++++------- 3 files changed, 35 insertions(+), 32 deletions(-) commit fdb8a291227338fe54a2a790dae457726e5c237b Merge: 1cc3880 d6a442d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 18:50:49 2016 -0700 Merge tag 'hwmon-for-linus-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging Pull hwmon updates from Guenter Roeck: - major rework of it87 driver: cleanup, added support for additional attributes, added support for two chips in the system, added support for IT8728E - fam17h_power driver now reports accumulated power consumption - new driver for MAX31722/MAX31723 temperature sensors - minor fixes to sch5636 and ads7828 drivers * tag 'hwmon-for-linus-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: (35 commits) hwmon: (sch5636) trivial fix of spelling mistake on revision hwmon: (it87) Add support for IT8628E hwmon: (it87) Fix pwm_temp_map for system with 6 pwm channels hwmon: (it87) Support automatic pwm control on newer chips hwmon: (it87) Enhance validation for fan4 and fan5 hwmon: (it87) Support disabling fan control for all pwm control and chips hwmon: (it87) Formatting cleanup hwmon: (it87) Use defines for array sizes and sensor counts hwmon: (it87) Use BIT macro hwmon: (it87) Add support for VIN7 to VIN10 on IT8620E hwmon: (it87) Simplify reading voltage registers hwmon: (it87) Support up to 6 temperature sensors on IT8620E hwmon: (it87) Convert to use new hwmon API hwmon: (it87) Use single group and is_visible for miscellaneous attributes hwmon: (it87) Use is_visible for pwm attributes hwmon: (it87) Use is_visible for fan attributes hwmon: (it87) Use is_visible for temperature sensors hwmon: (it87) Use is_visible for voltage sensors hwmon: (it87) Rearrange code to avoid forward declarations hwmon: (it87) Add support for second Super-IO chip ... commit 1cc3880a3c99f1be73f9024bd9db6248ffdcec70 Merge: 490e142 3f37a36 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 18:44:39 2016 -0700 Merge tag 'edac_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp Pull EDAC updates from Borislav Petkov: "It was pretty busy in EDAC land this time: - Altera Arria10 L2 cache and On-Chip RAM ECC handling (Thor Thayer) - Remove ad-hoc buffering of MCE records in sb_edac and i7core_edac (Tony Luck) - Do not register sb_edac with pci_register_driver() (Tony Luck) - Add support for Skylake to ie31200_edac (Jason Baron) - Do not register amd64_edac with pci_register_driver() (Borislav Petkov) ... plus the usual round of cleanups and fixes all over the place" * tag 'edac_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp: (25 commits) EDAC, amd64_edac: Drop pci_register_driver() use EDAC, ie31200_edac: Add Skylake support EDAC, sb_edac: Use cpu family/model in driver detection EDAC, i7core: Remove double buffering of error records EDAC, amd64_edac: Issue driver banner only on success ARM: socfpga: Initialize Arria10 OCRAM ECC on startup EDAC: Increment correct counter in edac_inc_ue_error() EDAC, sb_edac: Remove double buffering of error records EDAC: Fix used after kfree() error in edac_unregister_sysfs() EDAC, altera: Avoid unused function warnings EDAC, altera: Remove useless casts ARM: socfpga: Enable Arria10 OCRAM ECC on startup EDAC, altera: Add Arria10 OCRAM ECC support Documentation: dt: socfpga: Add Altera Arria10 OCRAM binding EDAC, altera: Make OCRAM ECC dependency check generic EDAC, altera: Add register offset for ECC Enable EDAC, altera: Extract error inject operations to a struct fops ARM: socfpga: Enable Arria10 L2 cache ECC on startup EDAC, altera: Add Arria10 L2 Cache ECC handling Documentation, dt, socfpga: Add Altera Arria10 L2 cache binding ... commit 490e142209da64243577a997b6d2ed050684ef7b Merge: b6ae405 80d6737 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 18:37:06 2016 -0700 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds Pull LED updates from Jacek Anaszewski: "In this merge cycle we had an interaction with MTD subsystem, that included converting drivers/mtd/nand/nand_base.c to use newly introduced MTD (NAND/NOR) LED trigger instead of implementing it on its own. Related MTD patches are intended to be merged through the LED tree, before MTD tree is merged, since further MTD development is based on those modifications. Summary: LEDs: - Introduce a kernel panic LED trigger - Introduce a MTD (NAND/NOR) trigger - led-tca6507: silence an uninitialized variable warning - ledtrig-ide-disk: Move ide_blink_delay to ledtrig_ide_activity() - leds-ss4200: Add depend on x86 arch - leds-ss4200: add DMI data for FSC SCALEO Home Server - leds-triggers: Allow to switch the trigger to "panic" on a kernel panic - devicetree: leds: Introduce "panic-indicator" optional property - leds-gpio: Support the "panic-indicator" firmware property MTD: - Uninline mtd_write_oob and move it to mtdcore.c - Remove the "nand-disk" LED trigger - Hook I/O activity to the MTD LED trigger" * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds: leds: gpio: Support the "panic-indicator" firmware property devicetree: leds: Introduce "panic-indicator" optional property leds: triggers: Allow to switch the trigger to "panic" on a kernel panic leds: ss4200: add DMI data for FSC SCALEO Home Server leds: ss4200: Add depend on x86 arch leds: ledtrig-ide-disk: Move ide_blink_delay to ledtrig_ide_activity() leds: tca6507: silence an uninitialized variable warning mtd: Hook I/O activity to the MTD LED trigger mtd: nand: Remove the "nand-disk" LED trigger leds: trigger: Introduce a MTD (NAND/NOR) trigger mtd: Uninline mtd_write_oob and move it to mtdcore.c leds: trigger: Introduce a kernel panic LED trigger commit 70f95b76f155153a2a51a9a4568b9bcd4e573f5c Author: Corey Minyard <cminyard@mvista.com> Date: Fri May 6 12:57:13 2016 -0500 ipmi: Fix the I2C address extraction from SPMI tables Unlike everywhere else in the IPMI specification, the I2C address specified in the SPMI table is not shifted to the left one bit with the LSB zero. Instead it is not shifted with the MSB zero. Reported-by: Sanjeev <singhsan@codeaurora.org> Signed-off-by: Corey Minyard <cminyard@mvista.com> drivers/char/ipmi/ipmi_ssif.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 57a38f1340eb2b036dbc4ec34f4a14603e5dd47c Author: Corey Minyard <cminyard@mvista.com> Date: Tue Apr 26 22:25:12 2016 -0500 IPMI: reserve memio regions separately Commit d61a3ead2680 ("[PATCH] IPMI: reserve I/O ports separately") changed the way I/O ports were reserved and includes this comment in log: Some BIOSes reserve disjoint I/O regions in their ACPI tables for the IPMI controller. This causes problems when trying to register the entire I/O region. Therefore we must register each I/O port separately. There is a similar problem with memio regions on an arm64 platform (AMD Seattle). Where I see: ipmi message handler version 39.2 ipmi_si AMDI0300:00: probing via device tree ipmi_si AMDI0300:00: ipmi_si: probing via ACPI ipmi_si AMDI0300:00: [mem 0xe0010000] regsize 1 spacing 4 irq 23 ipmi_si: Adding ACPI-specified kcs state machine IPMI System Interface driver. ipmi_si: Trying ACPI-specified kcs state machine at mem \ address 0xe0010000, slave address 0x0, irq 23 ipmi_si: Could not set up I/O space The problem is that the ACPI core registers disjoint regions for the platform device: e0010000-e0010000 : AMDI0300:00 e0010004-e0010004 : AMDI0300:00 and the ipmi_si driver tries to register one region e0010000-e0010004. Based on a patch from Mark Salter <msalter@redhat.com>, who also wrote all the above text. Signed-off-by: Corey Minyard <cminyard@mvista.com> Tested-by: Mark Salter <msalter@redhat.com> drivers/char/ipmi/ipmi_si_intf.c | 40 +++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) commit 76824852a941375aad640b35025dac75d077113a Author: Corey Minyard <cminyard@mvista.com> Date: Tue Apr 26 22:40:15 2016 -0500 ipmi: Fix some minor coding style issues Signed-off-by: Corey Minyard <cminyard@mvista.com> drivers/char/ipmi/ipmi_si_intf.c | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) commit b6ae4055f4ab55c05df31cc1b6a7ea8c85eb525d Merge: be09201 4ba2578 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 17:39:29 2016 -0700 Merge tag 'arm64-perf' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 perf updates from Will Deacon: "The main addition here is support for Broadcom's Vulcan core using the architected ID registers for discovering supported events. - Support for the PMU in Broadcom's Vulcan CPU - Dynamic event detection using the PMCEIDn_EL0 ID registers" * tag 'arm64-perf' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: arm64: perf: don't expose CHAIN event in sysfs arm64/perf: Add Broadcom Vulcan PMU support arm64/perf: Filter common events based on PMCEIDn_EL0 arm64/perf: Access pmu register using <read/write>_sys_reg arm64/perf: Define complete ARMv8 recommended implementation defined events arm64/perf: Changed events naming as per the ARM ARM arm64: dts: Add Broadcom Vulcan PMU in dts Documentation: arm64: pmu: Add Broadcom Vulcan PMU binding commit 23ea5967d6bd30ed59480edbc5fe21eec81682a3 Merge: c52c545 d96caf8 Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Mon May 16 17:25:08 2016 -0700 Merge branch 'next' into for-linus Prepare first round of input updates for 4.7 merge window. commit be092017b6ffbd013f481f915632db6aa9fc3ca3 Merge: fb6363e e6d9a52 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 17:17:24 2016 -0700 Merge tag 'arm64-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux Pull arm64 updates from Will Deacon: - virt_to_page/page_address optimisations - support for NUMA systems described using device-tree - support for hibernate/suspend-to-disk - proper support for maxcpus= command line parameter - detection and graceful handling of AArch64-only CPUs - miscellaneous cleanups and non-critical fixes * tag 'arm64-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux: (92 commits) arm64: do not enforce strict 16 byte alignment to stack pointer arm64: kernel: Fix incorrect brk randomization arm64: cpuinfo: Missing NULL terminator in compat_hwcap_str arm64: secondary_start_kernel: Remove unnecessary barrier arm64: Ensure pmd_present() returns false after pmd_mknotpresent() arm64: Replace hard-coded values in the pmd/pud_bad() macros arm64: Implement pmdp_set_access_flags() for hardware AF/DBM arm64: Fix typo in the pmdp_huge_get_and_clear() definition arm64: mm: remove unnecessary EXPORT_SYMBOL_GPL arm64: always use STRICT_MM_TYPECHECKS arm64: kvm: Fix kvm teardown for systems using the extended idmap arm64: kaslr: increase randomization granularity arm64: kconfig: drop CONFIG_RTC_LIB dependency arm64: make ARCH_SUPPORTS_DEBUG_PAGEALLOC depend on !HIBERNATION arm64: hibernate: Refuse to hibernate if the boot cpu is offline arm64: kernel: Add support for hibernate/suspend-to-disk PM / Hibernate: Call flush_icache_range() on pages restored in-place arm64: Add new asm macro copy_page arm64: Promote KERNEL_START/KERNEL_END definitions to a header file arm64: kernel: Include _AC definition in page.h ... commit 02fbd139759feb1f331cebd858523b5d774082e6 Author: Jan Kara <jack@suse.cz> Date: Wed May 11 11:58:48 2016 +0200 dax: Remove complete_unwritten argument Fault handlers currently take complete_unwritten argument to convert unwritten extents after PTEs are updated. However no filesystem uses this anymore as the code is racy. Remove the unused argument. Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/block_dev.c | 4 ++-- fs/dax.c | 43 +++++++++---------------------------------- fs/ext2/file.c | 4 ++-- fs/ext4/file.c | 4 ++-- fs/xfs/xfs_file.c | 7 +++---- include/linux/dax.h | 17 +++++++---------- include/linux/fs.h | 1 - 7 files changed, 25 insertions(+), 55 deletions(-) commit e4b2749158631e6d74bf14d2ef3804d780e2f770 Author: NeilBrown <neilb@suse.com> Date: Wed May 11 11:58:47 2016 +0200 DAX: move RADIX_DAX_ definitions to dax.c These don't belong in radix-tree.c any more than PAGECACHE_TAG_* do. Let's try to maintain the idea that radix-tree simply implements an abstract data type. Acked-by: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Matthew Wilcox <willy@linux.intel.com> Signed-off-by: NeilBrown <neilb@suse.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com> fs/dax.c | 9 +++++++++ include/linux/radix-tree.h | 9 --------- 2 files changed, 9 insertions(+), 9 deletions(-) commit fb6363e9f4eeb37323feb8253b93854195942b8b Merge: ce6a01c 9a64627 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:56:42 2016 -0700 Merge tag 'm68k-for-v4.7-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k Pull m68k updates from Geert Uytterhoeven: "Preparatory work for Arnd's genrtc removal series" * tag 'm68k-for-v4.7-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k: m68k/mvme16x: Include generic <linux/rtc.h> m68k/bvme6000: Include generic <linux/rtc.h> commit 5eee87cd51df8492d7e61c2d8b5154a15a4888b2 Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed May 11 13:23:34 2016 -0700 ixgbe: Fix VLAN features error It looks like at some point I somehow transposed the location of setting the VLAN features in netdev->features and the configuration of the vlan_features. As a result the driver is now generating a warning about vlan_features being setup incorrectly. This patch corrects that by placing the update of netdev->features to include the VLAN features so that it is after the point where we write netdev->features into netdev->vlan_features. Fixes: b83e30104bd9 ("ixgbe/ixgbevf: Add support for GSO partial") Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit ce6a01c2d50e1d400cb6d492841f9b1932034fc2 Merge: bc231d9 096a8b6 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:50:38 2016 -0700 Merge tag 'metag-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag Pull metag architecture updates from James Hogan: "Three minor fixes: - removal of stale comment - fix build for Meta1 when perf events are enabled - fix inline asm constraint in atomics" * tag 'metag-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag: metag: Fix atomic_*_return inline asm constraints metag: perf: fix build on Meta1 metag: ftrace: remove the misleading comment for ftrace_dyn_arch_init commit 11f2b494bc07f3d054687159ad6b1f3ec12a9040 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Wed May 4 15:01:27 2016 -0700 ixgbe: use correct mask when enabling sriov Swap the parameters in GENMASK in order to generate the correct mask. This change fixes Tx hangs when enabling SRIOV. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit bc231d9ede99518b67a77544d9084f15b898fe2e Merge: 62a0027 3cd0b53 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:46:03 2016 -0700 Merge branch 'x86-platform-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 platform updates from Ingo Molnar: "The main change is the addition of SGI/UV4 support" * 'x86-platform-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (22 commits) x86/platform/UV: Fix incorrect nodes and pnodes for cpuless and memoryless nodes x86/platform/UV: Remove Obsolete GRU MMR address translation x86/platform/UV: Update physical address conversions for UV4 x86/platform/UV: Build GAM reference tables x86/platform/UV: Support UV4 socket address changes x86/platform/UV: Add obtaining GAM Range Table from UV BIOS x86/platform/UV: Add UV4 addressing discovery function x86/platform/UV: Fold blade info into per node hub info structs x86/platform/UV: Allocate common per node hub info structs on local node x86/platform/UV: Move blade local processor ID to the per cpu info struct x86/platform/UV: Move scir info to the per cpu info struct x86/platform/UV: Create per cpu info structs to replace per hub info structs x86/platform/UV: Update MMIOH setup function to work for both UV3 and UV4 x86/platform/UV: Clean up redunduncies after merge of UV4 MMR definitions x86/platform/UV: Add UV4 Specific MMR definitions x86/platform/UV: Prep for UV4 MMR updates x86/platform/UV: Add UV MMR Illegal Access Function x86/platform/UV: Add UV4 Specific Defines x86/platform/UV: Add UV Architecture Defines x86/platform/UV: Add Initial UV4 definitions ... commit 1eef33bec12d7e46a58f12b3604556a80c362a0d Author: Alessio Igor Bogani <alessio.bogani@elettra.eu> Date: Tue May 3 14:31:18 2016 +0200 powerpc/86xx: Fix PCI interrupt map definition Fix PCI interrupt map definition from 2 to 4 cells. Move interrupt-map and interrupt-map-mask and clone interrupts into the pcie child nodes. Signed-off-by: Alessio Igor Bogani <alessio.bogani@elettra.eu> Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/boot/dts/fsl/mpc8641si-post.dtsi | 32 +++++++++++++-------------- 1 file changed, 16 insertions(+), 16 deletions(-) commit 62a0027839a4a69bc5d2696672242019a6bb6221 Merge: bcea36d 8fad7ec Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:45:03 2016 -0700 Merge branch 'x86-debug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 debug cleanup from Ingo Molnar: "A printk() output simplification" * 'x86-debug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/dumpstack: Combine some printk()s commit bcea36df7ae4b0db0b6e5e6dd3e5efe03410f5da Merge: 05e30f0 a3819e3 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:40:14 2016 -0700 Merge branch 'x86-cleanups-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 cleanup from Ingo Molnar: "Inline optimizations" * 'x86-cleanups-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86: Fix non-static inlines commit a66639d4eec5e03bdc5d9a312b7eebd3827a4d14 Author: Alessio Igor Bogani <alessio.bogani@elettra.eu> Date: Wed Apr 20 10:18:29 2016 +0200 powerpc/86xx: Move pci1 definition to the include file Signed-off-by: Alessio Igor Bogani <alessio.bogani@elettra.eu> Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/boot/dts/fsl/gef_ppc9a.dts | 4 ++++ arch/powerpc/boot/dts/fsl/gef_sbc310.dts | 22 --------------------- arch/powerpc/boot/dts/fsl/gef_sbc610.dts | 4 ++++ arch/powerpc/boot/dts/fsl/mpc8641_hpcn.dts | 24 +---------------------- arch/powerpc/boot/dts/fsl/mpc8641_hpcn_36b.dts | 24 +---------------------- arch/powerpc/boot/dts/fsl/mpc8641si-post.dtsi | 27 ++++++++++++++++++++++++++ arch/powerpc/boot/dts/fsl/mpc8641si-pre.dtsi | 1 + arch/powerpc/boot/dts/fsl/sbc8641d.dts | 23 ---------------------- 8 files changed, 38 insertions(+), 91 deletions(-) commit 05e30f01b70e5f75f3c3a62010c0f059826da565 Merge: 9a45f03 7a09b225f Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 16:27:53 2016 -0700 Merge branch 'x86-build-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86-64 defconfig update from Ingo Molnar: "Small defconfig addition" [ I'm not actually convinced our defconfig is sensible, but whatever ] * 'x86-build-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/build/defconfig/64: Enable CONFIG_E1000E=y commit 4680c9d50637f78338e786c920aef6c171c7cc00 Author: Alessio Igor Bogani <alessio.bogani@elettra.eu> Date: Mon Apr 18 08:36:19 2016 +0200 powerpc/fsl: Fix build of the dtb embedded kernel images Commit dc37374b9c833 ("powerpc/fsl: Move Freescale device tree files into fsl folder") moved a lot of device tree files into fsl directory, fixing Makefile for cuImage target only. Unfortunately there are other targets which require embedding a device tree into the kernel image (e.g. dtbImage.%). So use a more generic approach. Signed-off-by: Alessio Igor Bogani <alessio.bogani@elettra.eu> [scottwood: cleaned up commit message] Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/boot/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d2d79dcc661d6a5b70597ab982e09d7752d66101 Author: Chenhui Zhao <chenhui.zhao@nxp.com> Date: Fri Apr 15 18:47:46 2016 +0800 powerpc/fsl: Fix rcpm compatible string For T1040, T1042, T1023, and T1024, they should use the compatible string "fsl,qoriq-rcpm-2.1". Signed-off-by: Chenhui Zhao <chenhui.zhao@nxp.com> Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/boot/dts/fsl/t1023si-post.dtsi | 2 +- arch/powerpc/boot/dts/fsl/t1040si-post.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 9a45f036af363aec1efec08827c825d69c115a9a Merge: 168f1a7 d2d3462 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 15:54:01 2016 -0700 Merge branch 'x86-boot-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 boot updates from Ingo Molnar: "The biggest changes in this cycle were: - prepare for more KASLR related changes, by restructuring, cleaning up and fixing the existing boot code. (Kees Cook, Baoquan He, Yinghai Lu) - simplifly/concentrate subarch handling code, eliminate paravirt_enabled() usage. (Luis R Rodriguez)" * 'x86-boot-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (50 commits) x86/KASLR: Clarify purpose of each get_random_long() x86/KASLR: Add virtual address choosing function x86/KASLR: Return earliest overlap when avoiding regions x86/KASLR: Add 'struct slot_area' to manage random_addr slots x86/boot: Add missing file header comments x86/KASLR: Initialize mapping_info every time x86/boot: Comment what finalize_identity_maps() does x86/KASLR: Build identity mappings on demand x86/boot: Split out kernel_ident_mapping_init() x86/boot: Clean up indenting for asm/boot.h x86/KASLR: Improve comments around the mem_avoid[] logic x86/boot: Simplify pointer casting in choose_random_location() x86/KASLR: Consolidate mem_avoid[] entries x86/boot: Clean up pointer casting x86/boot: Warn on future overlapping memcpy() use x86/boot: Extract error reporting functions x86/boot: Correctly bounds-check relocations x86/KASLR: Clean up unused code from old 'run_size' and rename it to 'kernel_total_size' x86/boot: Fix "run_size" calculation x86/boot: Calculate decompression size during boot not build ... commit ed8fd100b494b95118097ddfcc3f8c112a9a04f0 Author: Scott Wood <oss@buserror.net> Date: Tue Mar 8 17:30:36 2016 -0600 powerpc/fsl: Remove FSL_SOC dependency from FSL_LBC This dependency led to kconfig errors when MTD_NAND_FSL_ELBC was enabled, which selects FSL_LBC, in the absence of FSL_SOC, as reported in http://patchwork.ozlabs.org/patch/564405/ It was originally suggested to add an FSL_SOC dependency to MTD_NAND_FSL_ELBC, but the FSL_SOC symbol has been a growing problem due to hardware being shared between PPC and ARM SoCs. Even though eLBC isn't found on ARM SoCs (the newer IFC is used instead), I don't want to expand the use of FSL_SOC for things other than functions exported by fsl_soc.c. In particular, it would be odd to add it to MTD_NAND_FSL_ELBC and then remove it from MTD_NAND_FSL_IFC. Removing artificial dependencies also helps get compile-test exposure via randconfig, allyesconfig, etc. Reported-by: Brian Norris <computersforpeace@gmail.com> Cc: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/Kconfig | 1 - 1 file changed, 1 deletion(-) commit 10aa97c379cdd1e9f537a00ef2d787989759269d Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon May 16 10:33:40 2016 -0700 f2fs: manipulate dirty file inodes when DATA_FLUSH is set It needs to maintain dirty file inodes only if DATA_FLUSH is set. Otherwise, let's avoid its overhead. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 087968974fcd9e8c910bba73f3393a49b7380ca6 Author: Sheng Yong <shengyong1@huawei.com> Date: Mon May 16 12:38:50 2016 +0800 f2fs: add fault injection to sysfs This patch introduces a new struct f2fs_fault_info and a global f2fs_fault to save fault injection status. Fault injection entries are created in /sys/fs/f2fs/fault_injection/ during initializing f2fs module. Signed-off-by: Sheng Yong <shengyong1@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 31 ++++++++++++++++++++----- fs/f2fs/super.c | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++----- 2 files changed, 91 insertions(+), 10 deletions(-) commit b951a4ec165af4973b2bd9c80fb5845fbd840435 Author: Yunlei He <heyunlei@huawei.com> Date: Fri May 13 14:57:43 2016 +0800 f2fs: no need inc dirty pages under inode lock No need inc dirty pages under inode lock Signed-off-by: Yunlei He <heyunlei@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8975bdf48220cca703ad4586528e04b76b40ea1c Author: Chao Yu <yuchao0@huawei.com> Date: Sat May 14 19:03:53 2016 +0800 f2fs: fix incorrect error path handling in f2fs_move_rehashed_dirents Fix two bugs in error path of f2fs_move_rehashed_dirents: - release dir's inode page if fail to call kmalloc - recover i_current_depth if fail to converting Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/inline.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit e4103849ba784368e802eec4f15832ac54eb7d39 Author: Chao Yu <yuchao0@huawei.com> Date: Sat May 14 19:03:52 2016 +0800 f2fs: fix i_current_depth during inline dentry conversion With below steps, we will see that dentry page becoming unaccessable later. This is because we forget updating i_current_depth in inode during inline dentry conversion, after that, once we failed at somewhere, it will leave i_current_depth as 0 in non-inline directory. Then, during ->lookup, the current_depth value makes all dentry pages in first level invisible. Fix it. 1) mount f2fs with inline_dentry option 2) mkdir dir 3) touch 180 files named [0-179] in dir 4) touch 180 in dir (fail after inline dir conversion) 5) ll dir ls: cannot access /mnt/f2fs/dir/0: No such file or directory ls: cannot access /mnt/f2fs/dir/1: No such file or directory ls: cannot access /mnt/f2fs/dir/2: No such file or directory ls: cannot access /mnt/f2fs/dir/3: No such file or directory ls: cannot access /mnt/f2fs/dir/4: No such file or directory drwxr-xr-x 2 root root 4096 may 13 21:47 ./ drwxr-xr-x 3 root root 4096 may 13 21:46 ../ -????????? ? ? ? ? ? 0 -????????? ? ? ? ? ? 1 -????????? ? ? ? ? ? 10 -????????? ? ? ? ? ? 100 -????????? ? ? ? ? ? 101 -????????? ? ? ? ? ? 102 Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/inline.c | 1 + 1 file changed, 1 insertion(+) commit 99e3e858a486ccef93da0d4b67a71ed1c171b2fe Author: Sheng Yong <shengyong1@huawei.com> Date: Wed May 11 17:08:14 2016 +0800 f2fs: correct return value type of f2fs_fill_super Signed-off-by: Sheng Yong <shengyong1@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 168f1a7163b37294a0ef33829e1ed54d41e33c42 Merge: 825a3b2 4afd056 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 15:15:17 2016 -0700 Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 asm updates from Ingo Molnar: "The main changes in this cycle were: - MSR access API fixes and enhancements (Andy Lutomirski) - early exception handling improvements (Andy Lutomirski) - user-space FS/GS prctl usage fixes and improvements (Andy Lutomirski) - Remove the cpu_has_*() APIs and replace them with equivalents (Borislav Petkov) - task switch micro-optimization (Brian Gerst) - 32-bit entry code simplification (Denys Vlasenko) - enhance PAT handling in enumated CPUs (Toshi Kani) ... and lots of other cleanups/fixlets" * 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (70 commits) x86/arch_prctl/64: Restore accidentally removed put_cpu() in ARCH_SET_GS x86/entry/32: Remove asmlinkage_protect() x86/entry/32: Remove GET_THREAD_INFO() from entry code x86/entry, sched/x86: Don't save/restore EFLAGS on task switch x86/asm/entry/32: Simplify pushes of zeroed pt_regs->REGs selftests/x86/ldt_gdt: Test set_thread_area() deletion of an active segment x86/tls: Synchronize segment registers in set_thread_area() x86/asm/64: Rename thread_struct's fs and gs to fsbase and gsbase x86/arch_prctl/64: Remove FSBASE/GSBASE < 4G optimization x86/segments/64: When load_gs_index fails, clear the base x86/segments/64: When loadsegment(fs, ...) fails, clear the base x86/asm: Make asm/alternative.h safe from assembly x86/asm: Stop depending on ptrace.h in alternative.h x86/entry: Rename is_{ia32,x32}_task() to in_{ia32,x32}_syscall() x86/asm: Make sure verify_cpu() has a good stack x86/extable: Add a comment about early exception handlers x86/msr: Set the return value to zero when native_rdmsr_safe() fails x86/paravirt: Make "unsafe" MSR accesses unsafe even if PARAVIRT=y x86/paravirt: Add paravirt_{read,write}_msr() x86/msr: Carry on after a non-"safe" MSR access fails ... commit 825a3b2605c3aa193e0075d0f9c72e33c17ab16a Merge: cf6ed9a ef0491e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 14:47:16 2016 -0700 Merge branch 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler updates from Ingo Molnar: - massive CPU hotplug rework (Thomas Gleixner) - improve migration fairness (Peter Zijlstra) - CPU load calculation updates/cleanups (Yuyang Du) - cpufreq updates (Steve Muckle) - nohz optimizations (Frederic Weisbecker) - switch_mm() micro-optimization on x86 (Andy Lutomirski) - ... lots of other enhancements, fixes and cleanups. * 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (66 commits) ARM: Hide finish_arch_post_lock_switch() from modules sched/core: Provide a tsk_nr_cpus_allowed() helper sched/core: Use tsk_cpus_allowed() instead of accessing ->cpus_allowed sched/loadavg: Fix loadavg artifacts on fully idle and on fully loaded systems sched/fair: Correct unit of load_above_capacity sched/fair: Clean up scale confusion sched/nohz: Fix affine unpinned timers mess sched/fair: Fix fairness issue on migration sched/core: Kill sched_class::task_waking to clean up the migration logic sched/fair: Prepare to fix fairness problems on migration sched/fair: Move record_wakee() sched/core: Fix comment typo in wake_q_add() sched/core: Remove unused variable sched: Make hrtick_notifier an explicit call sched/fair: Make ilb_notifier an explicit call sched/hotplug: Make activate() the last hotplug step sched/hotplug: Move migration CPU_DYING to sched_cpu_dying() sched/migration: Move CPU_ONLINE into scheduler state sched/migration: Move calc_load_migrate() into CPU_DYING sched/migration: Move prepare transition to SCHED_STARTING state ... commit cf6ed9a6682d3f171cf9550d4bbe0ef31b768a7e Merge: 36db171 754a923 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 14:24:51 2016 -0700 Merge branch 'ras-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull RAS updates from Ingo Molnar: "Main changes in this cycle were: - AMD MCE/RAS handling updates (Yazen Ghannam, Aravind Gopalakrishnan) - Cleanups (Borislav Petkov) - logging fix (Tony Luck)" * 'ras-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/RAS: Add SMCA support to AMD Error Injector EDAC, mce_amd: Detect SMCA using X86_FEATURE_SMCA x86/mce: Update AMD mcheck init to use cpu_has() facilities x86/cpu: Add detection of AMD RAS Capabilities x86/mce/AMD: Save an indentation level in prepare_threshold_block() x86/mce/AMD: Disable LogDeferredInMcaStat for SMCA systems x86/mce/AMD: Log Deferred Errors using SMCA MCA_DE{STAT,ADDR} registers x86/mce: Detect local MCEs properly x86/mce: Look in genpool instead of mcelog for pending error records x86/mce: Detect and use SMCA-specific msr_ops x86/mce: Define vendor-specific MSR accessors x86/mce: Carve out writes to MCx_STATUS and MCx_CTL x86/mce: Grade uncorrected errors for SMCA-enabled systems x86/mce: Log MCEs after a warm rest on AMD, Fam17h and later x86/mce: Remove explicit smp_rmb() when starting CPUs sync x86/RAS: Rename AMD MCE injector config item commit 36db171cc733bc7b8c628ef21831467d1919decd Merge: 3469d26 3f56e68 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 14:08:43 2016 -0700 Merge branch 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf updates from Ingo Molnar: "Bigger kernel side changes: - Add backwards writing capability to the perf ring-buffer code, which is preparation for future advanced features like robust 'overwrite support' and snapshot mode. (Wang Nan) - Add pause and resume ioctls for the perf ringbuffer (Wang Nan) - x86 Intel cstate code cleanups and reorgnization (Thomas Gleixner) - x86 Intel uncore and CPU PMU driver updates (Kan Liang, Peter Zijlstra) - x86 AUX (Intel PT) related enhancements and updates (Alexander Shishkin) - x86 MSR PMU driver enhancements and updates (Huang Rui) - ... and lots of other changes spread out over 40+ commits. Biggest tooling side changes: - 'perf trace' features and enhancements. (Arnaldo Carvalho de Melo) - BPF tooling updates (Wang Nan) - 'perf sched' updates (Jiri Olsa) - 'perf probe' updates (Masami Hiramatsu) - ... plus 200+ other enhancements, fixes and cleanups to tools/ The merge commits, the shortlog and the changelogs contain a lot more details" * 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (249 commits) perf/core: Disable the event on a truncated AUX record perf/x86/intel/pt: Generate PMI in the STOP region as well perf buildid-cache: Use lsdir() for looking up buildid caches perf symbols: Use lsdir() for the search in kcore cache directory perf tools: Use SBUILD_ID_SIZE where applicable perf tools: Fix lsdir to set errno correctly perf trace: Move seccomp args beautifiers to tools/perf/trace/beauty/ perf trace: Move flock op beautifier to tools/perf/trace/beauty/ perf build: Add build-test for debug-frame on arm/arm64 perf build: Add build-test for libunwind cross-platforms support perf script: Fix export of callchains with recursion in db-export perf script: Fix callchain addresses in db-export perf script: Fix symbol insertion behavior in db-export perf symbols: Add dso__insert_symbol function perf scripting python: Use Py_FatalError instead of die() perf tools: Remove xrealloc and ALLOC_GROW perf help: Do not use ALLOC_GROW in add_cmd_list perf pmu: Make pmu_formats_string to check return value of strbuf perf header: Make topology checkers to check return value of strbuf perf tools: Make alias handler to check return value of strbuf ... commit 99ee87295017e36abb6925e6139ca303cb55aee7 Merge: 76e9cab 9ecb549 Author: Dave Airlie <airlied@redhat.com> Date: Tue May 17 07:06:14 2016 +1000 Merge tag 'topic/drm-misc-2016-05-13' of git://anongit.freedesktop.org/drm-intel into drm-next I kinda hoped that I could still sneak in Noralf's drm_simple_display_pipe, since there's intereset by others now (for tilcdc at least). But it wasn't ready by a hair. Oh well. Otherwise random stuff plus prep patches from Noralf. * tag 'topic/drm-misc-2016-05-13' of git://anongit.freedesktop.org/drm-intel: drm/atomic: Add drm_atomic_helper_best_encoder() drm/atomic: Don't skip drm_bridge_*() calls if !drm_encoder_helper_funcs drm/fb-cma-helper: Hook up to DocBook and fix some docs drm/fb-helper: Remove mention of CONFIG_FB_DEFERRED_IO in docs drm/sti: include linux/seq_file.h where needed drm/tegra: Use lockless gem BO free callback drm/exynos: Use lockless gem BO free callback drm: Make drm_encoder_helper_funcs optional commit ad67b437f187ea818b2860524d10f878fadfdd99 Author: Prarit Bhargava <prarit@redhat.com> Date: Wed May 11 12:27:16 2016 -0400 PCI: Disable all BAR sizing for devices with non-compliant BARs b84106b4e229 ("PCI: Disable IO/MEM decoding for devices with non-compliant BARs") disabled BAR sizing for BARs 0-5 of devices that don't comply with the PCI spec. But it didn't do anything for expansion ROM BARs, so we still try to size them, resulting in warnings like this on Broadwell-EP: pci 0000:ff:12.0: BAR 6: failed to assign [mem size 0x00000001 pref] Move the non-compliant BAR check from __pci_read_base() up to pci_read_bases() so it applies to the expansion ROM BAR as well as to BARs 0-5. Note that direct callers of __pci_read_base(), like sriov_init(), will now bypass this check. We haven't had reports of devices with broken SR-IOV BARs yet. [bhelgaas: changelog] Fixes: b84106b4e229 ("PCI: Disable IO/MEM decoding for devices with non-compliant BARs") Signed-off-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: stable@vger.kernel.org CC: Thomas Gleixner <tglx@linutronix.de> CC: Ingo Molnar <mingo@redhat.com> CC: "H. Peter Anvin" <hpa@zytor.com> CC: Andi Kleen <ak@linux.intel.com> drivers/pci/probe.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit da77b67195de1c65bef4908fa29967c4d0af2da2 Author: Prarit Bhargava <prarit@redhat.com> Date: Wed May 11 12:27:15 2016 -0400 x86/PCI: Mark Broadwell-EP Home Agent 1 as having non-compliant BARs Commit b894157145e4 ("x86/PCI: Mark Broadwell-EP Home Agent & PCU as having non-compliant BARs") marked Home Agent 0 & PCU has having non-compliant BARs. Home Agent 1 also has non-compliant BARs. Mark Home Agent 1 as having non-compliant BARs so the PCI core doesn't touch them. The problem with these devices is documented in the Xeon v4 specification update: BDF2 PCI BARs in the Home Agent Will Return Non-Zero Values During Enumeration Problem: During system initialization the Operating System may access the standard PCI BARs (Base Address Registers). Due to this erratum, accesses to the Home Agent BAR registers (Bus 1; Device 18; Function 0,4; Offsets (0x14-0x24) will return non-zero values. Implication: The operating system may issue a warning. Intel has not observed any functional failures due to this erratum. Link: http://www.intel.com/content/www/us/en/processors/xeon/xeon-e5-v4-spec-update.html Fixes: b894157145e4 ("x86/PCI: Mark Broadwell-EP Home Agent & PCU as having non-compliant BARs") Signed-off-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: Thomas Gleixner <tglx@linutronix.de> CC: Ingo Molnar <mingo@redhat.com> CC: "H. Peter Anvin" <hpa@zytor.com> CC: Andi Kleen <ak@linux.intel.com> arch/x86/pci/fixup.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 3469d261eac65912927dca13ee8f77c744ad7aa2 Merge: 1c19b68 4544ba8 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 13:41:02 2016 -0700 Merge branch 'locking-rwsem-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull support for killable rwsems from Ingo Molnar: "This, by Michal Hocko, implements down_write_killable(). The main usecase will be to update mm_sem usage sites to use this new API, to allow the mm-reaper introduced in commit aac453635549 ("mm, oom: introduce oom reaper") to tear down oom victim address spaces asynchronously with minimum latencies and without deadlock worries" [ The vfs will want it too as the inode lock is changed from a mutex to a rwsem due to the parallel lookup and readdir updates ] * 'locking-rwsem-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: locking/rwsem: Fix comment on register clobbering locking/rwsem: Fix down_write_killable() locking/rwsem, x86: Add frame annotation for call_rwsem_down_write_failed_killable() locking/rwsem: Provide down_write_killable() locking/rwsem, x86: Provide __down_write_killable() locking/rwsem, s390: Provide __down_write_killable() locking/rwsem, ia64: Provide __down_write_killable() locking/rwsem, alpha: Provide __down_write_killable() locking/rwsem: Introduce basis for down_write_killable() locking/rwsem, sparc: Drop superfluous arch specific implementation locking/rwsem, sh: Drop superfluous arch specific implementation locking/rwsem, xtensa: Drop superfluous arch specific implementation locking/rwsem: Drop explicit memory barriers locking/rwsem: Get rid of __down_write_nested() commit 76e9cab5403809fa1fa6f698d2f7c1b7dd224022 Merge: cf15fab cb2ad5e Author: Dave Airlie <airlied@redhat.com> Date: Tue May 17 06:36:08 2016 +1000 Merge branch 'topic-arcpgu-updates' of https://github.com/foss-for-synopsys-dwc-arc-processors/linux into drm-next Please pull this mini-series that allows ARC PGU to use dedicated memory location as framebuffer backing storage. * 'topic-arcpgu-updates' of https://github.com/foss-for-synopsys-dwc-arc-processors/linux: ARC: [axs10x] Specify reserved memory for frame buffer drm/arcpgu: use dedicated memory area for frame buffer commit 1c19b68a279c58d6da4379bf8b6d679a300a1daf Merge: 49817c3 a1cc5bc Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 13:17:56 2016 -0700 Merge branch 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull locking changes from Ingo Molnar: "The main changes in this cycle were: - pvqspinlock statistics fixes (Davidlohr Bueso) - flip atomic_fetch_or() arguments (Peter Zijlstra) - locktorture simplification (Paul E. McKenney) - documentation updates (SeongJae Park, David Howells, Davidlohr Bueso, Paul E McKenney, Peter Zijlstra, Will Deacon) - various fixes" * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: locking/atomics: Flip atomic_fetch_or() arguments locking/pvqspinlock: Robustify init_qspinlock_stat() locking/pvqspinlock: Avoid double resetting of stats lcoking/locktorture: Simplify the torture_runnable computation locking/Documentation: Clarify that ACQUIRE applies to loads, RELEASE applies to stores locking/Documentation: State purpose of memory-barriers.txt locking/Documentation: Add disclaimer locking/Documentation/lockdep: Fix spelling mistakes locking/lockdep: Deinline register_lock_class(), save 2328 bytes locking/locktorture: Fix NULL pointer dereference for cleanup paths locking/locktorture: Fix deboosting NULL pointer dereference locking/Documentation: Mention smp_cond_acquire() locking/Documentation: Insert white spaces consistently locking/Documentation: Fix formatting inconsistencies locking/Documentation: Add missed subsection in TOC locking/Documentation: Fix missed s/lock/acquire renames locking/Documentation: Clarify relationship of barrier() to control dependencies commit 92efb1bd9bcbdf83cc0e6cfead752d0c82f63677 Author: Alex Williamson <alex.williamson@redhat.com> Date: Mon May 16 15:12:02 2016 -0500 PCI: Identify Enhanced Allocation (EA) BAR Equivalent resources in sysfs Resource flags are exposed to userspace via the sysfs "resource" file. lspci reads the sysfs file to determine resource properties. Add a "BAR Equivalent Indicator" flag so lspci can distinguish between [virtual] and [enhanced] resources. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Sean O. Stalley <sean.stalley@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pci.c | 2 +- include/linux/ioport.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) commit 49817c33433a3cd6f320b13699e6746cc39b453b Merge: 230e51f 6c5450e Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 13:06:27 2016 -0700 Merge branch 'efi-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull EFI updates from Ingo Molnar: "The main changes in this cycle were: - Drop the unused EFI_SYSTEM_TABLES efi.flags bit and ensure the ARM/arm64 EFI System Table mapping is read-only (Ard Biesheuvel) - Add a comment to explain that one of the code paths in the x86/pat code is only executed for EFI boot (Matt Fleming) - Improve Secure Boot status checks on arm64 and handle unexpected errors (Linn Crosetto) - Remove the global EFI memory map variable 'memmap' as the same information is already available in efi::memmap (Matt Fleming) - Add EFI Memory Attribute table support for ARM/arm64 (Ard Biesheuvel) - Add EFI GOP framebuffer support for ARM/arm64 (Ard Biesheuvel) - Add EFI Bootloader Control driver for storing reboot(2) data in EFI variables for consumption by bootloaders (Jeremy Compostella) - Add Core EFI capsule support (Matt Fleming) - Add EFI capsule char driver (Kweh, Hock Leong) - Unify EFI memory map code for ARM and arm64 (Ard Biesheuvel) - Add generic EFI support for detecting when firmware corrupts CPU status register bits (like IRQ flags) when performing EFI runtime service calls (Mark Rutland) ... and other misc cleanups" * 'efi-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (46 commits) efivarfs: Make efivarfs_file_ioctl() static efi: Merge boolean flag arguments efi/capsule: Move 'capsule' to the stack in efi_capsule_supported() efibc: Fix excessive stack footprint warning efi/capsule: Make efi_capsule_pending() lockless efi: Remove unnecessary (and buggy) .memmap initialization from the Xen EFI driver efi/runtime-wrappers: Remove ARCH_EFI_IRQ_FLAGS_MASK #ifdef x86/efi: Enable runtime call flag checking arm/efi: Enable runtime call flag checking arm64/efi: Enable runtime call flag checking efi/runtime-wrappers: Detect firmware IRQ flag corruption efi/runtime-wrappers: Remove redundant #ifdefs x86/efi: Move to generic {__,}efi_call_virt() arm/efi: Move to generic {__,}efi_call_virt() arm64/efi: Move to generic {__,}efi_call_virt() efi/runtime-wrappers: Add {__,}efi_call_virt() templates efi/arm-init: Reserve rather than unmap the memory map for ARM as well efi: Add misc char driver interface to update EFI firmware x86/efi: Force EFI reboot to process pending capsules efi: Add 'capsule' update support ... commit 230e51f21101e49c8d73018d414adbd0d57459a1 Merge: a3871bd 91c6180 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 12:25:25 2016 -0700 Merge branch 'core-signals-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull core signal updates from Ingo Molnar: "These updates from Stas Sergeev and Andy Lutomirski, improve the sigaltstack interface by extending its ABI with the SS_AUTODISARM feature, which makes it possible to use swapcontext() in a sighandler that works on sigaltstack. Without this flag, the subsequent signal will corrupt the state of the switched-away sighandler. The inspiration is more robust dosemu signal handling" * 'core-signals-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: signals/sigaltstack: Change SS_AUTODISARM to (1U << 31) signals/sigaltstack: Report current flag bits in sigaltstack() selftests/sigaltstack: Fix the sigaltstack test on old kernels signals/sigaltstack: If SS_AUTODISARM, bypass on_sig_stack() selftests/sigaltstack: Add new testcase for sigaltstack(SS_ONSTACK|SS_AUTODISARM) signals/sigaltstack: Implement SS_AUTODISARM flag signals/sigaltstack: Prepare to add new SS_xxx flags signals/sigaltstack, x86/signals: Unify the x86 sigaltstack check with other architectures commit a3871bd434cfc313cdcd1edc433507298f4aa928 Merge: 0052af4 41ed943 Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 12:02:08 2016 -0700 Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull RCU updates from Ingo Molnar: "The main changes are: - Documentation updates, including fixes to the design-level requirements documentation and a fixed version of the design-level data-structure documentation. These fixes include removing cartoons and getting rid of the html/htmlx duplication. - Further improvements to the new-age expedited grace periods. - Miscellaneous fixes. - Torture-test changes, including a new rcuperf module for measuring RCU grace-period performance and scalability, which is useful for the expedited-grace-period changes" * 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (56 commits) rcutorture: Add boot-time adjustment of leaf fanout rcutorture: Add irqs-disabled test for call_rcu() rcutorture: Dump trace buffer upon shutdown rcutorture: Don't rebuild identical kernel rcutorture: Add OS-jitter capability documentation: Add documentation for RCU's major data structures rcutorture: Convert test duration to seconds early torture: Kill qemu, not parent process torture: Clarify refusal to run more than one torture test rcutorture: Consider FROZEN hotplug notifier transitions rcutorture: Remove redundant initialization to zero rcuperf: Do not wake up shutdown wait queue if "shutdown" is false. rcutorture: Add largish-system rcuperf scenario rcutorture: Avoid RCU CPU stall warning and RT throttling rcutorture: Add rcuperf holdoff boot parameter to reduce interference rcutorture: Make scripts analyze rcuperf trace data, if present rcutorture: Make rcuperf collect expedited event-trace data rcutorture: Print measure of batching efficiency rcutorture: Set rcuperf writer kthreads to real-time priority rcutorture: Bind rcuperf reader/writer kthreads to CPUs ... commit 0052af4411b048eb6c0b0adb73d0fb4803ba1794 Merge: 0fed3ac d18d12d Author: Linus Torvalds <torvalds@linux-foundation.org> Date: Mon May 16 11:36:02 2016 -0700 Merge branch 'core-lib-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull core/lib update from Ingo Molnar: "This contains a single commit that removes an unused facility that the scheduler used to make use of" * 'core-lib-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: lib/proportions: Remove unused code commit 0fed3ac866eabf01924457921ee3684c8e4c9005 Author: George Spelvin <linux@horizon.com> Date: Mon May 2 06:31:01 2016 -0400 namei: Improve hash mixing if CONFIG_DCACHE_WORD_ACCESS The hash mixing between adding the next 64 bits of name was just a bit weak. Replaced with a still very fast but slightly more effective mixing function. Signed-off-by: George Spelvin <linux@horizon.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> fs/namei.c | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) commit 7e2c3aea4398d079745b9faa2c17b6cbd010f221 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Sun May 15 23:28:29 2016 +0200 net: also make sch_handle_egress() drop monitor ready Follow-up for 8a3a4c6e7b34 ("net: make sch_handle_ingress() drop monitor ready") to also make the egress side drop monitor ready. Also here only TC_ACT_SHOT is a clear indication that something went wrong. Hence don't provide false positives to drop monitors such as 'perf record -e skb:kfree_skb ...'. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 15db6e0dc73ebdbf42c35f2f64907a5f4e154be1 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Sun May 15 19:37:44 2016 +0530 net/hsr: Use setup_timer and mod_timer. The function setup_timer combines the initialization of a timer with the initialization of the timer's function and data fields. The mulitiline code for timer initialization is now replaced with function setup_timer. Also, quoting the mod_timer() function comment: -> mod_timer() is a more efficient way to update the expire field of an active timer (if the timer is inactive it will be activated). Use setup_timer() and mod_timer() to setup and arm a timer, making the code compact and aid readablity. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/hsr/hsr_device.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) commit a2a658a303486b95d766f690672c9f706b280704 Merge: 2bb07e1 416cdf0 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:59:20 2016 -0400 Merge branch 'qed-next' Yuval Mintz says: ==================== qed: IOV enhncements and fixups This is a follow-up on the recent patch series that adds SR-IOV support to qed. All content here is iov-related fixups [nothing terminal] and enhancements. Please consider applying this series to `net-next'. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 416cdf0635b2173e96b7a66b303e768e0749b778 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Sun May 15 14:48:09 2016 +0300 qed: VFs gracefully accept lack of PM VF's probe might log that it has no PM capability in its PCI configuration space. As this is a valid configuration, silence such prints. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 83f34bd436fefc70376efe6f6dd7ddcb5265d88b Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Sun May 15 14:48:08 2016 +0300 qed: Allow more than 16 VFs In multi-function modes, PFs are currently limited to using 16 VFs - But that limitation would also currently apply in case there's a single PCI function exposed, where no such restriction should have existed. This lifts the restriction for the default mode; User should be able to start the maximum number of VFs as appear in the PCI config space. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_sriov.c | 3 +++ 1 file changed, 3 insertions(+) commit 079d20a6739e0b4a06d73f37b8435d443897cc0c Author: Manish Chopra <Manish.Chopra@qlogic.com> Date: Sun May 15 14:48:07 2016 +0300 qed: Reset link on IOV disable PF updates its VFs' bulletin boards with link configurations whenever the physical carrier changes or whenever hyper-user explicitly requires some setting of the VFs link via the hypervisor's PF. Since the bulletin board is getting cleaned as part of the IOV disable flow on the PF side, re-enabling sriov would lead to a VF that sees the carrier as 'down', until an event causing the PF to re-fill the bulletin with the link configuration would occur. To fix this we simply refelect the link state during the flows, giving the later VFs a default reflecting the PFs link state. Signed-off-by: Manish Chopra <Manish.Chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_sriov.c | 90 ++++++++++++++++------------- 1 file changed, 51 insertions(+), 39 deletions(-) commit b2b897eba66636b7fd8e56cc4f7464819623609e Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Sun May 15 14:48:06 2016 +0300 qed: Improve VF interrupt reset During FLR flow, need to make sure HW is no longer capable of writing to host memory as part of its interrupt mechanisms. While we're at it, unify the logic cleaning the driver's status-blocks into using a single API function for both PFs and VFs. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_int.c | 59 ++++++++++++++------------ drivers/net/ethernet/qlogic/qed/qed_int.h | 20 +-------- drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 2 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 20 +++------ 4 files changed, 41 insertions(+), 60 deletions(-) commit b0409fa0940b59dc0c313eb424cfbc4730778ecc Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Sun May 15 14:48:05 2016 +0300 qed: Correct PF-sanity check Seems like something broke in commit 1408cc1fa48c ("qed: Introduce VFs") and the function no longer verifies that the vf is indeed a valid one. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_sriov.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 2bb07e155bb3e0c722c806723f737cf8020961ef Author: Tariq Toukan <tariqt@mellanox.com> Date: Sun May 15 10:21:26 2016 +0300 net/mlx4_core: Fix access to uninitialized index Prevent using uninitialized or negative index when handling steering entries. Fixes: b12d93d63c32 ('mlx4: Add support for promiscuous mode in the new steering model.') Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/mcg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2ffd7e035601268915a393ae0b7cac34c27e190e Merge: 14d7e48 72f9f8b Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:56:37 2016 -0400 Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next Johan Hedberg says: ==================== pull request: bluetooth-next 2016-05-14 Here are two more Bluetooth patches for the 4.7 kernel which we wanted to get into net-next before the merge window opens. Please let me know if there are any issues pulling. Thanks. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 14d7e48751925b4d48f0fd2317b0570fd243f6fd Merge: b0456b2 c3875ca Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:55:49 2016 -0400 Merge branch 'w5100-small-changes' Akinobu Mita says: ==================== net: w5100: collection of small changes This patch series is the collection of relatively small changes for w5100 driver which includes a cleanup with no functional change, two fixes, and adding a functionality. * Changes from v1 - Remove the watchdong_timeo assignment to set default tx timeout, suggested by David Miller. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c3875ca7d9f9ad135debc78e211ea062ac48323c Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sat May 14 14:55:50 2016 +0900 net: w5100-spi: add support to specify MAC address by device tree This adds support to specify the MAC address by 'mac-address' or 'local-mac-address' properties in the device tree. These are common properties for the Ethernet controller. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100-spi.c | 4 +++- drivers/net/ethernet/wiznet/w5100.c | 5 +++-- drivers/net/ethernet/wiznet/w5100.h | 3 ++- 3 files changed, 8 insertions(+), 4 deletions(-) commit 7d6da453efce17fae35707fa7e5757e7ade8b3cc Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sat May 14 14:55:49 2016 +0900 net: w5100: increase TX timeout period This increases TX timeout period from one second to 5 seconds which is the default value if the driver doesn't explicitly set net_device->watchdog_timeo. The one second timeout is too short for W5100 with SPI interface mode which doesn't support burst READ/WRITE processing in the SPI transfer. If the packet is transmitted while RX packets are being received at a very high rate, the TX transmittion work in the workqueue is delayed and the watchdog timer is expired. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 1 - 1 file changed, 1 deletion(-) commit d41cd5f7e2fce8d3c5b1345a7cf9ed3f0d2d99c1 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sat May 14 14:55:48 2016 +0900 net: w5100: fix MAC filtering for W5500 W5500 has different bit position for MAC filter in Socket n mode register from W5100 and W5200. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit e9f0cd94c1697ad6c98422a1953105c8ffc515f3 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sat May 14 14:55:47 2016 +0900 net: w5100: remove unused is_w5200() The is_w5200() function is not used anymore by the commit which adds the W5500 support. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 5 ----- 1 file changed, 5 deletions(-) commit b0456b24ff4c8f408feaf97ea465897672bb1ac1 Merge: 485b777 c8396d8 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:53:20 2016 -0400 Merge branch 'lxt-cleanups' Sergei Shtylyov says: ==================== Here's the set of 2 patches against DaveM's 'net-next.git' repo. We save several LoCs on the unneeded local variables.... [1/2] lxt: simplify lxt97[01]_config_intr() [2/2] lxt: simplify lxt970_config_init() ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c8396d84c70b47b31b5a9e34732e88bcc7dae9e9 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sat May 14 02:09:07 2016 +0300 lxt: simplify lxt970_config_init() This function declares the 'err' local variable for no good reason, get rid of it. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/lxt.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 04e6233d57a9e68e97c248f97d1aa2cb354f3947 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Fri May 13 16:08:02 2016 -0700 lxt: simplify lxt97[01]_config_intr() Both these functions declare the 'err' local variables for no good reason, get rid of them. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/lxt.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) commit 485b777855ed74dfcde5c46cfc88e2bc1b7c0714 Merge: 553eb54 d93a47f Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:49:33 2016 -0400 Merge branch 'bpf-blinding' Daniel Borkmann says: ==================== BPF updates This set implements constant blinding for BPF, first couple of patches are some preparatory cleanups, followed by the blinding. Please see individual patches for details. Thanks a lot! ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d93a47f735f3455a896e46b18d0ac26fa19639e6 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:35 2016 +0200 bpf, s390: add support for constant blinding This patch adds recently added constant blinding helpers into the s390 eBPF JIT. In the bpf_int_jit_compile() path, requirements are to utilize bpf_jit_blind_constants()/bpf_jit_prog_release_other() pair for rewriting the program into a blinded one, and to map the BPF_REG_AX register to a CPU register. The mapping of BPF_REG_AX is at r12 and similarly like in x86 case performs reloading when ld_abs/ind is used. When blinding is not used, there's no additional overhead in the generated image. When BPF_REG_AX is used, we don't need to emit skb->data reload when helper function changed skb->data, as this will be reloaded later on anyway from stack on ld_abs/ind, where skb->data is needed. s390 allows for this w/o much additional complexity unlike f.e. x86. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/s390/net/bpf_jit_comp.c | 73 +++++++++++++++++++++++++++++++++----------- 1 file changed, 56 insertions(+), 17 deletions(-) commit 26eb042ee4c7845aa395c41c4e125c240b82b984 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:34 2016 +0200 bpf, arm64: add support for constant blinding This patch adds recently added constant blinding helpers into the arm64 eBPF JIT. In the bpf_int_jit_compile() path, requirements are to utilize bpf_jit_blind_constants()/bpf_jit_prog_release_other() pair for rewriting the program into a blinded one, and to map the BPF_REG_AX register to a CPU register. The mapping is on x9. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Zi Shen Lim <zlim.lnx@gmail.com> Acked-by: Yang Shi <yang.shi@linaro.org> Tested-by: Yang Shi <yang.shi@linaro.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/net/bpf_jit_comp.c | 52 +++++++++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 12 deletions(-) commit 959a7579160349d222cc5da30db3b138139b6fbc Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:33 2016 +0200 bpf, x86: add support for constant blinding This patch adds recently added constant blinding helpers into the x86 eBPF JIT. In the bpf_int_jit_compile() path, requirements are to utilize bpf_jit_blind_constants()/bpf_jit_prog_release_other() pair for rewriting the program into a blinded one, and to map the BPF_REG_AX register to a CPU register. The mapping of BPF_REG_AX is at non-callee saved register r10, and thus shared with cached skb->data used for ld_abs/ind and not in every program type needed. When blinding is not used, there's zero additional overhead in the generated image. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/x86/net/bpf_jit_comp.c | 66 ++++++++++++++++++++++++++++++++++++--------- 1 file changed, 53 insertions(+), 13 deletions(-) commit 4f3446bb809f20ad56cadf712e6006815ae7a8f9 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:32 2016 +0200 bpf: add generic constant blinding for use in jits This work adds a generic facility for use from eBPF JIT compilers that allows for further hardening of JIT generated images through blinding constants. In response to the original work on BPF JIT spraying published by Keegan McAllister [1], most BPF JITs were changed to make images read-only and start at a randomized offset in the page, where the rest was filled with trap instructions. We have this nowadays in x86, arm, arm64 and s390 JIT compilers. Additionally, later work also made eBPF interpreter images read only for kernels supporting DEBUG_SET_MODULE_RONX, that is, x86, arm, arm64 and s390 archs as well currently. This is done by default for mentioned JITs when JITing is enabled. Furthermore, we had a generic and configurable constant blinding facility on our todo for quite some time now to further make spraying harder, and first implementation since around netconf 2016. We found that for systems where untrusted users can load cBPF/eBPF code where JIT is enabled, start offset randomization helps a bit to make jumps into crafted payload harder, but in case where larger programs that cross page boundary are injected, we again have some part of the program opcodes at a page start offset. With improved guessing and more reliable payload injection, chances can increase to jump into such payload. Elena Reshetova recently wrote a test case for it [2, 3]. Moreover, eBPF comes with 64 bit constants, which can leave some more room for payloads. Note that for all this, additional bugs in the kernel are still required to make the jump (and of course to guess right, to not jump into a trap) and naturally the JIT must be enabled, which is disabled by default. For helping mitigation, the general idea is to provide an option bpf_jit_harden that admins can tweak along with bpf_jit_enable, so that for cases where JIT should be enabled for performance reasons, the generated image can be further hardened with blinding constants for unpriviledged users (bpf_jit_harden == 1), with trading off performance for these, but not for privileged ones. We also added the option of blinding for all users (bpf_jit_harden == 2), which is quite helpful for testing f.e. with test_bpf.ko. There are no further e.g. hardening levels of bpf_jit_harden switch intended, rationale is to have it dead simple to use as on/off. Since this functionality would need to be duplicated over and over for JIT compilers to use, which are already complex enough, we provide a generic eBPF byte-code level based blinding implementation, which is then just transparently JITed. JIT compilers need to make only a few changes to integrate this facility and can be migrated one by one. This option is for eBPF JITs and will be used in x86, arm64, s390 without too much effort, and soon ppc64 JITs, thus that native eBPF can be blinded as well as cBPF to eBPF migrations, so that both can be covered with a single implementation. The rule for JITs is that bpf_jit_blind_constants() must be called from bpf_int_jit_compile(), and in case blinding is disabled, we follow normally with JITing the passed program. In case blinding is enabled and we fail during the process of blinding itself, we must return with the interpreter. Similarly, in case the JITing process after the blinding failed, we return normally to the interpreter with the non-blinded code. Meaning, interpreter doesn't change in any way and operates on eBPF code as usual. For doing this pre-JIT blinding step, we need to make use of a helper/auxiliary register, here BPF_REG_AX. This is strictly internal to the JIT and not in any way part of the eBPF architecture. Just like in the same way as JITs internally make use of some helper registers when emitting code, only that here the helper register is one abstraction level higher in eBPF bytecode, but nevertheless in JIT phase. That helper register is needed since f.e. manually written program can issue loads to all registers of eBPF architecture. The core concept with the additional register is: blind out all 32 and 64 bit constants by converting BPF_K based instructions into a small sequence from K_VAL into ((RND ^ K_VAL) ^ RND). Therefore, this is transformed into: BPF_REG_AX := (RND ^ K_VAL), BPF_REG_AX ^= RND, and REG <OP> BPF_REG_AX, so actual operation on the target register is translated from BPF_K into BPF_X one that is operating on BPF_REG_AX's content. During rewriting phase when blinding, RND is newly generated via prandom_u32() for each processed instruction. 64 bit loads are split into two 32 bit loads to make translation and patching not too complex. Only basic thing required by JITs is to call the helper bpf_jit_blind_constants()/bpf_jit_prog_release_other() pair, and to map BPF_REG_AX into an unused register. Small bpf_jit_disasm extract from [2] when applied to x86 JIT: echo 0 > /proc/sys/net/core/bpf_jit_harden ffffffffa034f5e9 + <x>: [...] 39: mov $0xa8909090,%eax 3e: mov $0xa8909090,%eax 43: mov $0xa8ff3148,%eax 48: mov $0xa89081b4,%eax 4d: mov $0xa8900bb0,%eax 52: mov $0xa810e0c1,%eax 57: mov $0xa8908eb4,%eax 5c: mov $0xa89020b0,%eax [...] echo 1 > /proc/sys/net/core/bpf_jit_harden ffffffffa034f1e5 + <x>: [...] 39: mov $0xe1192563,%r10d 3f: xor $0x4989b5f3,%r10d 46: mov %r10d,%eax 49: mov $0xb8296d93,%r10d 4f: xor $0x10b9fd03,%r10d 56: mov %r10d,%eax 59: mov $0x8c381146,%r10d 5f: xor $0x24c7200e,%r10d 66: mov %r10d,%eax 69: mov $0xeb2a830e,%r10d 6f: xor $0x43ba02ba,%r10d 76: mov %r10d,%eax 79: mov $0xd9730af,%r10d 7f: xor $0xa5073b1f,%r10d 86: mov %r10d,%eax 89: mov $0x9a45662b,%r10d 8f: xor $0x325586ea,%r10d 96: mov %r10d,%eax [...] As can be seen, original constants that carry payload are hidden when enabled, actual operations are transformed from constant-based to register-based ones, making jumps into constants ineffective. Above extract/example uses single BPF load instruction over and over, but of course all instructions with constants are blinded. Performance wise, JIT with blinding performs a bit slower than just JIT and faster than interpreter case. This is expected, since we still get all the performance benefits from JITing and in normal use-cases not every single instruction needs to be blinded. Summing up all 296 test cases averaged over multiple runs from test_bpf.ko suite, interpreter was 55% slower than JIT only and JIT with blinding was 8% slower than JIT only. Since there are also some extremes in the test suite, I expect for ordinary workloads that the performance for the JIT with blinding case is even closer to JIT only case, f.e. nmap test case from suite has averaged timings in ns 29 (JIT), 35 (+ blinding), and 151 (interpreter). BPF test suite, seccomp test suite, eBPF sample code and various bigger networking eBPF programs have been tested with this and were running fine. For testing purposes, I also adapted interpreter and redirected blinded eBPF image to interpreter and also here all tests pass. [1] http://mainisusuallyafunction.blogspot.com/2012/11/attacking-hardened-linux-systems-with.html [2] https://github.com/01org/jit-spray-poc-for-ksp/ [3] http://www.openwall.com/lists/kernel-hardening/2016/05/03/5 Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Reviewed-by: Elena Reshetova <elena.reshetova@intel.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/sysctl/net.txt | 11 +++ include/linux/filter.h | 42 +++++++++ kernel/bpf/core.c | 203 +++++++++++++++++++++++++++++++++++++++++++ net/Kconfig | 7 +- net/core/sysctl_net_core.c | 9 ++ 5 files changed, 270 insertions(+), 2 deletions(-) commit d1c55ab5e41fcd72cb0a8bef86d3f652ad9ad9f5 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:31 2016 +0200 bpf: prepare bpf_int_jit_compile/bpf_prog_select_runtime apis Since the blinding is strictly only called from inside eBPF JITs, we need to change signatures for bpf_int_jit_compile() and bpf_prog_select_runtime() first in order to prepare that the eBPF program we're dealing with can change underneath. Hence, for call sites, we need to return the latest prog. No functional change in this patch. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/net/bpf_jit_comp.c | 7 ++++--- arch/s390/net/bpf_jit_comp.c | 8 +++++--- arch/x86/net/bpf_jit_comp.c | 7 ++++--- include/linux/filter.h | 5 +++-- kernel/bpf/core.c | 18 ++++++++++++++---- kernel/bpf/syscall.c | 2 +- lib/test_bpf.c | 5 ++++- net/core/filter.c | 6 +++++- 8 files changed, 40 insertions(+), 18 deletions(-) commit c237ee5eb33bf19fe0591c04ff8db19da7323a83 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:30 2016 +0200 bpf: add bpf_patch_insn_single helper Move the functionality to patch instructions out of the verifier code and into the core as the new bpf_patch_insn_single() helper will be needed later on for blinding as well. No changes in functionality. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/filter.h | 3 +++ kernel/bpf/core.c | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++ kernel/bpf/verifier.c | 53 +++++++------------------------------ 3 files changed, 83 insertions(+), 44 deletions(-) commit 93a73d442d370e20ed1009cd79cb29c4d7c0ee86 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:29 2016 +0200 bpf, x86/arm64: remove useless checks on prog There is never such a situation, where bpf_int_jit_compile() is called with either prog as NULL or len as 0, so the tests are unnecessary and confusing as people would just copy them. s390 doesn't have them, so no change is needed there. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/net/bpf_jit_comp.c | 3 --- arch/x86/net/bpf_jit_comp.c | 3 --- 2 files changed, 6 deletions(-) commit 6077776b5908e0493a3946f7d3bc63871b201e87 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:28 2016 +0200 bpf: split HAVE_BPF_JIT into cBPF and eBPF variant Split the HAVE_BPF_JIT into two for distinguishing cBPF and eBPF JITs. Current cBPF ones: # git grep -n HAVE_CBPF_JIT arch/ arch/arm/Kconfig:44: select HAVE_CBPF_JIT arch/mips/Kconfig:18: select HAVE_CBPF_JIT if !CPU_MICROMIPS arch/powerpc/Kconfig:129: select HAVE_CBPF_JIT arch/sparc/Kconfig:35: select HAVE_CBPF_JIT Current eBPF ones: # git grep -n HAVE_EBPF_JIT arch/ arch/arm64/Kconfig:61: select HAVE_EBPF_JIT arch/s390/Kconfig:126: select HAVE_EBPF_JIT if PACK_STACK && HAVE_MARCH_Z196_FEATURES arch/x86/Kconfig:94: select HAVE_EBPF_JIT if X86_64 Later code also needs this facility to check for eBPF JITs. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm/Kconfig | 2 +- arch/arm64/Kconfig | 2 +- arch/mips/Kconfig | 2 +- arch/powerpc/Kconfig | 2 +- arch/s390/Kconfig | 2 +- arch/sparc/Kconfig | 2 +- arch/x86/Kconfig | 2 +- net/Kconfig | 14 +++++++++++--- 8 files changed, 18 insertions(+), 10 deletions(-) commit c94987e40ebbae3b7b6c3ece37b6f8338830f6b1 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:27 2016 +0200 bpf: move bpf_jit_enable declaration Move the bpf_jit_enable declaration to the filter.h file where most other core code is declared, also since we're going to add a second knob there. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/filter.h | 2 ++ include/linux/netdevice.h | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) commit 4936e3528e3e272c567fe4ff0abb7ce3e1500575 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri May 13 19:08:26 2016 +0200 bpf: minor cleanups in ebpf code Besides others, remove redundant comments where the code is self documenting enough, and properly indent various bpf_verifier_ops and bpf_prog_type_list declarations. Moreover, remove two exports that actually have no module user. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/core.c | 2 -- net/core/filter.c | 34 +++++++++++++++------------------- 2 files changed, 15 insertions(+), 21 deletions(-) commit 553eb544444e28749e2d752dee11e2ae4a3ecfb6 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Fri May 13 20:38:23 2016 -0400 net: dsa: mv88e6xxx: remove bridge work Now that the bridge code defers the switchdev port state setting, there is no need to defer the port STP state change within the mv88e6xxx code. Thus get rid of the driver's bridge work code. This also fixes a race condition where the DSA layer assumes that the bridge code already set the unbridged port's STP state to Disabled before restoring the Forwarding state. As a consequence, this also fixes the FDB flush for the unbridged port which now correctly occurs during the Forwarding to Disabled transition. Fixes: 0bc05d585d38 ("switchdev: allow caller to explicitly request attr_set as deferred") Reported-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 37 ++++++++----------------------------- drivers/net/dsa/mv88e6xxx.h | 5 ----- 2 files changed, 8 insertions(+), 34 deletions(-) commit b0e95ccdd77591f108c938bbc702b57554a1665d Author: David Ahern <dsa@cumulusnetworks.com> Date: Fri May 13 12:23:45 2016 -0700 net: vrf: protect changes to private data with rcu One cpu can be processing packets which includes using the cached route entries in the vrf device's private data and on another cpu the device gets deleted which releases the routes and sets the pointers in net_vrf to NULL. This results in datapath dereferencing a NULL pointer. Fix by protecting access to dst's with rcu. Fixes: 193125dbd8eb ("net: Introduce VRF device driver") Fixes: 35402e313663 ("net: Add IPv6 support to VRF device") Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vrf.c | 70 +++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 47 insertions(+), 23 deletions(-) commit ea1627c20c3462168a087ccecc69084b55b9c0b2 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 13 09:16:40 2016 -0700 tcp: minor optimizations around tcp_hdr() usage tcp_hdr() is slightly more expensive than using skb->data in contexts where we know they point to the same byte. In receive path, tcp_v4_rcv() and tcp_v6_rcv() are in this situation, as tcp header has not been pulled yet. In output path, the same can be said when we just pushed the tcp header in the skb, in tcp_transmit_skb() and tcp_make_synack() Also factorize the two checks for tcb->tcp_flags & TCPHDR_SYN in tcp_transmit_skb() and pass tcp header pointer to tcp_ecn_send(), so that compiler can further optimize and avoid a reload. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_ipv4.c | 6 +++--- net/ipv4/tcp_output.c | 30 ++++++++++++++---------------- net/ipv6/tcp_ipv6.c | 6 +++--- 3 files changed, 20 insertions(+), 22 deletions(-) commit 5022524308c64f2954ac206a8781b64a98cddf00 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri May 13 15:25:40 2016 +0200 netlink: kill nla_put_u64() This function is not used anymore. nla_put_u64_64bit() should be used instead. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) commit 2632616bc484de9281bc2a1f5b033325783f8a10 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 13 06:14:37 2016 -0700 sock: propagate __sock_cmsg_send() error __sock_cmsg_send() might return different error codes, not only -EINVAL. Fixes: 24025c465f77 ("ipv4: process socket-level control messages in IPv4") Fixes: ad1e46a83716 ("ipv6: process socket-level control messages in IPv6") Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/ip_sockglue.c | 5 +++-- net/ipv6/datagram.c | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) commit a986a05de95b730fd6a00b2b2f82a06d917fd6a2 Author: Arnd Bergmann <arnd@arndb.de> Date: Fri May 13 15:09:58 2016 +0200 net: qrtr: fix build problems Having multiple loadable modules with the same name cannot work with modprobe, and having both net/qrtr/smd.ko and drivers/soc/qcom/smd.ko results in a (somewhat cryptic) build error: ERROR: "qcom_smd_driver_unregister" [net/qrtr/smd.ko] undefined! ERROR: "qcom_smd_driver_register" [net/qrtr/smd.ko] undefined! ERROR: "qcom_smd_set_drvdata" [net/qrtr/smd.ko] undefined! ERROR: "qcom_smd_send" [net/qrtr/smd.ko] undefined! ERROR: "qcom_smd_get_drvdata" [net/qrtr/smd.ko] undefined! ERROR: "qcom_smd_driver_unregister" [drivers/soc/qcom/wcnss_ctrl.ko] undefined! ERROR: "qcom_smd_driver_register" [drivers/soc/qcom/wcnss_ctrl.ko] undefined! ERROR: "qcom_smd_set_drvdata" [drivers/soc/qcom/wcnss_ctrl.ko] undefined! ERROR: "qcom_smd_send" [drivers/soc/qcom/wcnss_ctrl.ko] undefined! ERROR: "qcom_smd_get_drvdata" [drivers/soc/qcom/wcnss_ctrl.ko] undefined! Also, the qrtr driver uses the SMD interface and has a Kconfig dependency, but also allows for compile-testing when SMD is disabled. However, if with QCOM_SMD=m and COMPILE_TEST=y we can end up with QRTR_SMD=y and that fails with a related link error. The changes the dependency so we can still compile-test the driver but not have it built-in if SMD is a module, to avoid running in the broken configuration, and changes the Makefile to provide the driver under a different module name. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: bdabad3e363d ("net: Add Qualcomm IPC router") Signed-off-by: David S. Miller <davem@davemloft.net> net/qrtr/Kconfig | 2 +- net/qrtr/Makefile | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 148bd3a34b426031355fdff2778bdab4e008766b Merge: 388665a aad7e08 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:43:52 2016 -0400 Merge branch 'tc_flower_offload' Amir Vadai says: ==================== sched,mlx5: Offloaded TC flower filter statistics This patchset introduces counters support for offloaded cls_flower filters. When the user calls 'tc show -s ..', fl_dump is called. Before fl_dump() returns the statistics, it calls the NIC driver (using a new ndo_setup_tc() command - TC_CLSFLOWER_STATS) to read the hardware counters and update the statistics accordingly. A new TC action op was added (stats_update()) to be used by the NIC driver to update the statistics. Patchset was applied and tested over commit ed7cbbc ("udp: Resolve NULL pointer dereference over flow-based vxlan device") ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit aad7e08d39bda94aedc594a82576980941306fc9 Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:42 2016 +0000 net/mlx5e: Hardware offloaded flower filter statistics support Introduce support in updating statistics of offloaded TC flower classifiers. Currently only the DROP action is supported. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 + drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 71 ++++++++++++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_tc.h | 3 + 3 files changed, 69 insertions(+), 7 deletions(-) commit 43a335e055bb7ebdc8a68ce7362ef26ef5bda92b Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:41 2016 +0000 net/mlx5_core: Flow counters infrastructure If a counter has the aging flag set when created, it is added to a list of counters that will be queried periodically from a workqueue. query result and last use timestamp are cached. add/del counter must be very efficient since thousands of such operations might be issued in a second. There is only a single reference to counters without aging, therefore no need for locks. But, counters with aging enabled are stored in a list. In order to make code as lockless as possible, all the list manipulation and access to hardware is done from a single context - the periodic counters query thread. The hardware supports multiple counters per FTE, however currently we are using one counter for each FTE. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/Makefile | 2 +- drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 7 +- drivers/net/ethernet/mellanox/mlx5/core/fs_core.h | 3 + .../net/ethernet/mellanox/mlx5/core/fs_counters.c | 226 +++++++++++++++++++++ include/linux/mlx5/driver.h | 14 ++ include/linux/mlx5/fs.h | 5 + 6 files changed, 255 insertions(+), 2 deletions(-) commit bd5251dbf156b6bc0661a9409d46e47160df61dd Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:40 2016 +0000 net/mlx5_core: Introduce flow steering destination of type counter When adding a flow steering rule with a counter, need to supply a destination of type MLX5_FLOW_DESTINATION_TYPE_COUNTER, with a pointer to a struct mlx5_fc. Also, MLX5_FLOW_CONTEXT_ACTION_COUNT bit should be set in the action. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c | 36 +++++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.h | 1 + drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 52 +++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlx5/core/fs_core.h | 23 ++++++++++ include/linux/mlx5/fs.h | 2 + include/linux/mlx5/mlx5_ifc.h | 2 + 6 files changed, 106 insertions(+), 10 deletions(-) commit 9dc0b289c4c09bc1a92bdcc055cb37af9b72eb28 Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:39 2016 +0000 net/mlx5_core: Firmware commands to support flow counters Getting packet/byte statistics on flows is done through flow counters. Implement the firmware commands to alloc, free and query flow counters. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 6 ++ drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c | 66 ++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.h | 5 ++ include/linux/mlx5/mlx5_ifc.h | 99 +++++++++++++++++++++++- 4 files changed, 173 insertions(+), 3 deletions(-) commit 42ca502e179d0654ef441333a9d0f35c948734f3 Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:38 2016 +0000 net/mlx5_core: Use a macro in mlx5_command_str() Use a macro instead of copying the OP name. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 303 +++++++++++--------------- 1 file changed, 132 insertions(+), 171 deletions(-) commit 10cbc6843446165ee250e1ee80dc19ee325f1e6d Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:37 2016 +0000 net/sched: cls_flower: Hardware offloaded filters statistics support Introduce a new command in ndo_setup_tc() for hardware offloaded filters, to call the NIC driver, and make it update the statistics. This will be done before dumping the filter and its statistics. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/pkt_cls.h | 1 + net/sched/cls_flower.c | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) commit 9fea47d93bcc98946a6eca0f019ced337564a344 Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:36 2016 +0000 net/sched: act_gact: Update statistics when offloaded to hardware Implement the stats_update callback that will be called by NIC drivers for hardware offloaded filters. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sched/act_gact.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 3804070235264ea883c3fdccd9ed16fef20b5ccb Author: Amir Vadai <amirva@mellanox.com> Date: Fri May 13 12:55:35 2016 +0000 net/sched: Enable netdev drivers to update statistics of offloaded actions Introduce stats_update callback. netdev driver could call it for offloaded actions to update the basic statistics (packets, bytes and last use). Since bstats_update() and bstats_cpu_update() use skb as an argument to get the counters, _bstats_update() and _bstats_cpu_update(), that get bytes and packets as arguments, were added. Signed-off-by: Amir Vadai <amirva@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/act_api.h | 12 ++++++++++++ include/net/sch_generic.h | 20 ++++++++++++++++++-- 2 files changed, 30 insertions(+), 2 deletions(-) commit 388665a9be5fd16abd3d9762b1995208355e6f6d Merge: 8be0cfa b17d155 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:39:50 2016 -0400 Merge branch 'pxa168_eth-perf' Jisheng Zhang says: ==================== net: pxa168_eth: improve performance This series is to improve the pxa168_eth driver performance by using {readl|writel}_relaxed or appropriate memory barriers. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b17d15592df057437ad356b431bb876889940620 Author: Jisheng Zhang <jszhang@marvell.com> Date: Fri May 13 19:57:30 2016 +0800 net: pxa168_eth: Use dma_wmb/rmb where appropriate Update the pxa168_eth driver to use the dma_rmb/wmb calls instead of the full barriers in order to improve performance: reduced 97ns/39ns on average in tx/rx path on Marvell BG4CT platform. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/marvell/pxa168_eth.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3ed687823c298b2349ab1f3d38ac88d967b8eaea Author: Jisheng Zhang <jszhang@marvell.com> Date: Fri May 13 19:57:29 2016 +0800 net: pxa168_eth: use {readl|writel}_relaxed instead of readl/writel Since appropriate memory barriers are already there, use the relaxed version to improve performance a bit. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/marvell/pxa168_eth.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8be0cfa4d352167df508acd571eb19afd8a2ce93 Author: Jiri Benc <jbenc@redhat.com> Date: Fri May 13 10:48:42 2016 +0200 vxlan: set mac_header correctly in GPE mode For VXLAN-GPE, the interface is ARPHRD_NONE, thus we need to reset mac_header after pulling the outer header. v2: Put the code to the existing conditional block as suggested by Shmulik Ladkani. Fixes: e1e5314de08b ("vxlan: implement GPE") Signed-off-by: Jiri Benc <jbenc@redhat.com> Reviewed-by: Shmulik Ladkani <shmulik.ladkani@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 1 + 1 file changed, 1 insertion(+) commit 41ae56ce3507d2967a29ae809200962d12cecb2b Merge: 1ca4673 c2d09fd Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:35:57 2016 -0400 Merge branch 'xen-netback-control-ring' Paul Durrant says: ==================== xen-netback: support for control ring My recent patch to import an up-to-date include/xen/interface/io/netif.h from the Xen Project brought in the necessary definitions to support the new control shared ring and protocol. This patch series updates xen-netback to support the new ring. Patch #1 adds the necessary boilerplate to map the control ring and handle messages. No implementation of the new protocol is included in this patch so that it can be kept to a reasonable size. Patch #2 adds the protocol implementation. Patch #3 adds support for passing has values calculated by xen-netback to capable frontends. Patch #4 adds support for accepting hash values calculated by capable frontends and using them the set the socket buffer hash. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c2d09fde7299f68f29e84fe5a415d5c1a7abae75 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Fri May 13 09:37:29 2016 +0100 xen-netback: use hash value from the frontend My recent patch to include/xen/interface/io/netif.h defines a new extra info type that can be used to pass hash values between backend and guest frontend. This patch adds code to xen-netback to use the value in a hash extra info fragment passed from the guest frontend in a transmit-side (i.e. netback receive side) packet to set the skb hash accordingly. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/netback.c | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit f07f989338587bc2b202f6e3c8e8468c450bd6a2 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Fri May 13 09:37:28 2016 +0100 xen-netback: pass hash value to the frontend My recent patch to include/xen/interface/io/netif.h defines a new extra info type that can be used to pass hash values between backend and guest frontend. This patch adds code to xen-netback to pass hash values calculated for guest receive-side packets (i.e. netback transmit side) to the frontend. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/interface.c | 13 ++++++- drivers/net/xen-netback/netback.c | 78 +++++++++++++++++++++++++++++++------ 2 files changed, 77 insertions(+), 14 deletions(-) commit 40d8abdee806d496a60ee607a6d01b1cd7fabaf0 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Fri May 13 09:37:27 2016 +0100 xen-netback: add control protocol implementation My recent patch to include/xen/interface/io/netif.h defines a new shared ring (in addition to the rx and tx rings) for passing control messages from a VM frontend driver to a backend driver. A previous patch added the necessary boilerplate for mapping the control ring from the frontend, should it be created. This patch adds implementations for each of the defined protocol messages. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Cc: Wei Liu <wei.liu2@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/Makefile | 2 +- drivers/net/xen-netback/common.h | 46 +++++ drivers/net/xen-netback/hash.c | 384 ++++++++++++++++++++++++++++++++++++ drivers/net/xen-netback/interface.c | 24 +++ drivers/net/xen-netback/netback.c | 49 ++++- 5 files changed, 502 insertions(+), 3 deletions(-) commit 4e15ee2cb46fed730fe6f0195a86d44e5aeef129 Author: Paul Durrant <Paul.Durrant@citrix.com> Date: Fri May 13 09:37:26 2016 +0100 xen-netback: add control ring boilerplate My recent patch to include/xen/interface/io/netif.h defines a new shared ring (in addition to the rx and tx rings) for passing control messages from a VM frontend driver to a backend driver. This patch adds the necessary code to xen-netback to map this new shared ring, should it be created by a frontend, but does not add implementations for any of the defined protocol messages. These are added in a subsequent patch for clarity. Signed-off-by: Paul Durrant <paul.durrant@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/xen-netback/common.h | 28 +++++++--- drivers/net/xen-netback/interface.c | 101 +++++++++++++++++++++++++++++++++--- drivers/net/xen-netback/netback.c | 99 +++++++++++++++++++++++++++++++++-- drivers/net/xen-netback/xenbus.c | 79 ++++++++++++++++++++++++---- 4 files changed, 277 insertions(+), 30 deletions(-) commit 1ca467343240be738c8e61edd4b421ca9ebe2d77 Merge: 860d7ef d34e3e1 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:30:57 2016 -0400 Merge branch 'cls_u32_hw_sw' Sridhar Samudrala says: ==================== Enable SW only or HW only offloads with u32 classifier This set of patches export TCA_CLS_FLAGS_SKIP_HW to userspace and also introduces another flag TCA_CLS_FLAGS_SKIP_SW. These flags enable offloading u32 filters to either SW or HW only. The default semantics with no flags is to add the filter to HW if possible and also into SW. With SKIP_HW flag, the filter is only added to SW. With SKIP_SW flag, the filter is added to HW and an error is returned to user on failure. These flags are mutually exclusive. There was an earlier discussion on these semantics in the following email thread. http://thread.gmane.org/gmane.linux.network/401733 ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d34e3e181395192d6d1f50dd97bd7854e04e33a4 Author: Samudrala, Sridhar <sridhar.samudrala@intel.com> Date: Thu May 12 17:08:23 2016 -0700 net: cls_u32: Add support for skip-sw flag to tc u32 classifier. On devices that support TC U32 offloads, this flag enables a filter to be added only to HW. skip-sw and skip-hw are mutually exclusive flags. By default without any flags, the filter is added to both HW and SW, but no error checks are done in case of failure to add to HW. With skip-sw, failure to add to HW is treated as an error. Here is a sample script that adds 2 filters, one with skip-sw and the other with skip-hw flag. # add ingress qdisc tc qdisc add dev p4p1 ingress # enable hw tc offload. ethtool -K p4p1 hw-tc-offload on # add u32 filter with skip-sw flag. tc filter add dev p4p1 parent ffff: protocol ip prio 99 \ handle 800:0:1 u32 ht 800: flowid 800:1 \ skip-sw \ match ip src 192.168.1.0/24 \ action drop # add u32 filter with skip-hw flag. tc filter add dev p4p1 parent ffff: protocol ip prio 99 \ handle 800:0:2 u32 ht 800: flowid 800:2 \ skip-hw \ match ip src 192.168.2.0/24 \ action drop Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Acked-by: John Fastabend <john.r.fastabend@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/pkt_cls.h | 17 +++++++++++++++++ include/uapi/linux/pkt_cls.h | 1 + net/sched/cls_u32.c | 45 +++++++++++++++++++++++++++++++++++--------- 3 files changed, 54 insertions(+), 9 deletions(-) commit 760edee8b59ebf05bb268d0a6b568f76bb1bb599 Author: Samudrala, Sridhar <sridhar.samudrala@intel.com> Date: Thu May 12 17:08:22 2016 -0700 net: sched: Move TCA_CLS_FLAGS_SKIP_HW to uapi header file. Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Acked-by: John Fastabend <john.r.fastabend@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/pkt_cls.h | 3 --- include/uapi/linux/pkt_cls.h | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) commit 860d7ef64da14b642a2b0dc15381b69b7263fc44 Merge: da47b45 8809883 Author: David S. Miller <davem@davemloft.net> Date: Mon May 16 13:26:01 2016 -0400 Merge branch 'hv_netvsc-races' Vitaly Kuznetsov says: ==================== hv_netvsc: avoid races on mtu change/set channels Changes since v1: - Rebased to net-next [Haiyang Zhang] Original description: MTU change and set channels operations are implemented as netvsc device re-creation destroying internal structures (struct net_device stays). This is really unfortunate but there is no support from Hyper-V host to do it in a different way. Such re-creation is unsurprisingly racy, Haiyang reported a crash when netvsc_change_mtu() is racing with netvsc_link_change() but I was able to identify additional races upon investigation. Both netvsc_set_channels() and netvsc_change_mtu() race against: 1) netvsc_link_change() 2) netvsc_remove() 3) netvsc_send() To solve these issues without introducing new locks some refactoring is required. We need to get rid of very complex link graph in all the internal structures and avoid traveling through structures which are being removed. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 88098834827025cc04c15f1b4b0d9bbef3cf55af Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:25 2016 +0200 hv_netvsc: set nvdev link after populating chn_table Crash in netvsc_send() is observed when netvsc device is re-created on mtu change/set channels. The crash is caused by dereferencing of NULL channel pointer which comes from chn_table. The root cause is a mixture of two facts: - we set nvdev pointer in net_device_context in alloc_net_device() before we populate chn_table. - we populate chn_table[0] only. The issue could be papered over by checking channel != NULL in netvsc_send() but populating the whole chn_table and writing the nvdev pointer afterwards seems more appropriate. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/netvsc.c | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) commit 6da7225f5a95ba68e3c6225c4051182bef30eed4 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:24 2016 +0200 hv_netvsc: synchronize netvsc_change_mtu()/netvsc_set_channels() with netvsc_remove() When netvsc device is removed during mtu change or channels setup we get into troubles as both paths are trying to remove the device. Synchronize them with start_remove flag and rtnl lock. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/netvsc_drv.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 0a1275ca5128b84ffffc149960969ed351ae00eb Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:23 2016 +0200 hv_netvsc: get rid of struct net_device pointer in struct netvsc_device Simplify netvsvc pointer graph by getting rid of the redundant ndev pointer. We can always get a pointer to struct net_device from somewhere else. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/hyperv_net.h | 5 +-- drivers/net/hyperv/netvsc.c | 36 +++++++--------- drivers/net/hyperv/netvsc_drv.c | 91 +++++++++++++++++++++++---------------- drivers/net/hyperv/rndis_filter.c | 4 +- 4 files changed, 72 insertions(+), 64 deletions(-) commit 3d541ac5a92af708d0085925d136f875f3a58d57 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:22 2016 +0200 hv_netvsc: untangle the pointer mess We have the following structures keeping netvsc adapter state: - struct net_device - struct net_device_context - struct netvsc_device - struct rndis_device - struct hv_device and there are pointers/dependencies between them: - struct net_device_context is contained in struct net_device - struct hv_device has driver_data pointer which points to 'struct net_device' OR 'struct netvsc_device' depending on driver's state (!). - struct net_device_context has a pointer to 'struct hv_device'. - struct netvsc_device has pointers to 'struct hv_device' and 'struct net_device_context'. - struct rndis_device has a pointer to 'struct netvsc_device'. Different functions get different structures as parameters and use these pointers for traveling. The problem is (in addition to keeping in mind this complex graph) that some of these structures (struct netvsc_device and struct rndis_device) are being removed and re-created on mtu change (as we implement it as re-creation of hyper-v device) so our travel using these pointers is dangerous. Simplify this to a the following: - add struct netvsc_device pointer to struct net_device_context (which is a part of struct net_device and thus never disappears) - remove struct hv_device and struct net_device_context pointers from struct netvsc_device - replace pointer to 'struct netvsc_device' with pointer to 'struct net_device'. - always keep 'struct net_device' in hv_device driver_data. We'll end up with the following 'circular' structure: net_device: [net_device_context] -> netvsc_device -> rndis_device -> net_device -> hv_device -> net_device On MTU change we'll be removing the 'netvsc_device -> rndis_device' branch and re-creating it making the synchronization easier. There is one additional redundant pointer left, it is struct net_device link in struct netvsc_device, it is going to be removed in a separate commit. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/hyperv_net.h | 10 ++--- drivers/net/hyperv/netvsc.c | 82 ++++++++++++++++----------------------- drivers/net/hyperv/netvsc_drv.c | 51 ++++++++++-------------- drivers/net/hyperv/rndis_filter.c | 78 +++++++++++++++++++------------------ 4 files changed, 99 insertions(+), 122 deletions(-) commit 1bdcec8a5f05445752a0639edd603ac09ae6c553 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:21 2016 +0200 hv_netvsc: use start_remove flag to protect netvsc_link_change() netvsc_link_change() can race with netvsc_change_mtu() or netvsc_set_channels() as these functions destroy struct netvsc_device and rndis filter. Use start_remove flag for syncronization. As netvsc_change_mtu()/netvsc_set_channels() are called with rtnl lock held we need to take it before checking start_remove value in netvsc_link_change(). Reported-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/netvsc_drv.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) commit f580aec4bfd7babe51f086e599400027def08ed8 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri May 13 13:55:20 2016 +0200 hv_netvsc: move start_remove flag to net_device_context struct netvsc_device is destroyed on mtu change so keeping the protection flag there is not a good idea. Move it to struct net_device_context which is preserved. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/hyperv_net.h | 4 +++- drivers/net/hyperv/netvsc.c | 3 +-- drivers/net/hyperv/netvsc_drv.c | 12 +++++++++--- 3 files changed, 13 insertions(+), 6 deletions(-) commit da47b4572056487fd7941c26f73b3e8815ff712a Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu May 12 12:00:33 2016 +0200 phy: add support for a reset-gpio specification The framework only asserts (for now) that the reset gpio is not active. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Roger Quadros <rogerq@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/devicetree/bindings/net/phy.txt | 3 +++ drivers/net/phy/phy_device.c | 8 ++++++++ 2 files changed, 11 insertions(+) commit a7aabcc8a5f5e7834abb538ad97db04d29968fbe Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Fri May 13 23:06:40 2016 +0530 drm/amd/powerplay: use ARRAY_SIZE() to calculate array size. It is preferred to use ARRAY_SIZE() for size calculation, instead using sizeof(array)/sizeof(*array). It makes the code more readable. Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3a834b1596ac668df206aa2bb1f191c31f5f5e4 Author: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Date: Mon May 16 09:54:47 2016 -0600 blk-mq: fix undefined behaviour in order_to_size() When this_order variable in blk_mq_init_rq_map() becomes zero the code incorrectly decrements the variable and passes the result to order_to_size() helper causing undefined behaviour: UBSAN: Undefined behaviour in block/blk-mq.c:1459:27 shift exponent 4294967295 is too large for 32-bit type 'unsigned int' CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.6.0-rc6-00072-g33656a1 #22 Fix the code by checking this_order variable for not having the zero value first. Reported-by: Meelis Roos <mroos@linux.ee> Fixes: 320ae51feed5 ("blk-mq: new multi-queue block IO queueing mechanism") Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3c8eb50383178f3a4dcf1dc867001156da6473d Author: David Bond <dbond@suse.com> Date: Wed Mar 23 21:49:26 2016 -0400 ibft: Expose iBFT acpi header via sysfs Some ethernet adapter vendors are supplying products which support optional (payed license) features. On some adapters this includes a hardware iscsi initiator. The same adapters in a normal (no extra licenses) mode of operation can be used as a software iscsi initiator. In addition, software iscsi boot initiators are becoming a standard part of many vendors uefi implementations. This is creating difficulties during early boot/install determining the proper configuration method for these adapters when they are used as a boot device. The attached patch creates sysfs entries to expose information from the acpi header of the ibft table. This information allows for a method to easily determining if an ibft table was created by a ethernet card's firmware or the system uefi/bios. In the case of a hardware initiator this information in combination with the pci vendor and device id can be used to ascertain any vendor specific behaviors that need to be accommodated. Reviewed-by: Lee Duncan <lduncan@suse.com> Signed-off-by: David Bond <dbond@suse.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Documentation/ABI/testing/sysfs-ibft | 10 ++++++ drivers/firmware/iscsi_ibft.c | 66 +++++++++++++++++++++++++++++++++++- drivers/scsi/iscsi_boot_sysfs.c | 62 +++++++++++++++++++++++++++++++++ include/linux/iscsi_boot_sysfs.h | 13 +++++++ 4 files changed, 150 insertions(+), 1 deletion(-) commit 9a99425f0736a416442525ac7b15903173888b86 Author: Hannes Reinecke <hare@suse.de> Date: Thu Feb 25 09:56:04 2016 -0800 iscsi_ibft: Add prefix-len attr and display netmask The iBFT table only specifies a prefix length, not a netmask. And the netmask is pretty much pointless for IPv6. So introduce a new attribute 'prefix-len'. Some older user-space code might rely on the netmask attribute being present, so we should always display it. Changes from v1: - Combined two patches into one Changes from v2: - Cleaned up/corrected wording for patch description Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Lee Duncan <lduncan@suse.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Konrad Rzeszutek Wilk <konrad@kernel.org> drivers/firmware/iscsi_ibft.c | 4 ++++ drivers/scsi/iscsi_boot_sysfs.c | 5 +++++ include/linux/iscsi_boot_sysfs.h | 1 + 3 files changed, 10 insertions(+) commit 6eab37daf0ec1077fd612ff27ab513db20f33767 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Fri May 13 17:35:43 2016 +0530 tools: testing: define the _GNU_SOURCE macro Add the macro _GNU_SOURCE, to fix CPU_ZERO and CPU_SET undefined compile errors. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> tools/testing/selftests/intel_pstate/run.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2c6c3946c3955f96ae0d48fdac940903918207d8 Author: Namhyung Kim <namhyung@kernel.org> Date: Tue May 10 23:53:06 2016 +0900 kselftests/ftrace: Add a test case for event pid filtering Check event is filtered by set_event_pid and options/event-fork. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> .../selftests/ftrace/test.d/event/event-pid.tc | 72 ++++++++++++++++++++++ 1 file changed, 72 insertions(+) commit 5a614ec8a7cfe9098475fa1221b409fb7eec6054 Author: Namhyung Kim <namhyung@kernel.org> Date: Tue May 10 23:53:05 2016 +0900 kselftests/ftrace: Detect tracefs mount point Currently ftracetest assumes tracing directory is located under $DEBUGFS/tracing. But it's possible to mount tracefs directly without debugfs. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> tools/testing/selftests/ftrace/ftracetest | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit fc723957801465c4a911d0a509709f0f8b91aa8a Merge: efc499f 9e5ed6d f18ebc2 60438d9 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 16:45:48 2016 +0200 Merge branches 'acpi-pci', 'acpi-misc' and 'acpi-tools' * acpi-pci: ACPI,PCI,IRQ: remove SCI penalize function ACPI,PCI,IRQ: remove redundant code in acpi_irq_penalty_init() ACPI,PCI,IRQ: reduce static IRQ array size to 16 ACPI,PCI,IRQ: reduce resource requirements * acpi-misc: ACPI / sysfs: fix error code in get_status() ACPI / device_sysfs: Clean up checkpatch errors ACPI / device_sysfs: Change _SUN and _STA show functions error return to EIO ACPI / device_sysfs: Add sysfs support for _HRV hardware revision arm64: defconfig: Enable ACPI ACPI / ARM64: Remove EXPERT dependency for ACPI on ARM64 ACPI / ARM64: Don't enable ACPI by default on ARM64 acer-wmi: Use acpi_dev_found() eeepc-wmi: Use acpi_dev_found() ACPI / utils: Rename acpi_dev_present() * acpi-tools: tools/power/acpi: close file only if it is open commit efc499f9807bfc179c66b7c3524e30370c6fd1b1 Merge: a6becfb 702b07f 7421669 e5f660e Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 16:45:25 2016 +0200 Merge branches 'acpi-numa', 'acpi-tables' and 'acpi-osi' * acpi-numa: ACPI / SRAT: fix SRAT parsing order with both LAPIC and X2APIC present * acpi-tables: ACPI / tables: Fix DSDT override mechanism ACPI / tables: Convert initrd table override to table upgrade mechanism ACPI / x86: Cleanup initrd related code ACPI / tables: Move table override mechanisms to tables.c * acpi-osi: ACPI / osi: Collect _OSI handling into one single file ACPI / osi: Cleanup coding style issues before creating a separate OSI source file ACPI / osi: Cleanup OSI handling code to use bool ACPI / osi: Fix default _OSI(Darwin) support ACPI / osi: Add acpi_osi=!! to allow reverting acpi_osi=! ACPI / osi: Cleanup _OSI("Linux") related code before introducing new support ACPI / osi: Fix an issue that acpi_osi=!* cannot disable ACPICA internal strings Conflicts: drivers/acpi/internal.h commit a6becfbaba801ccac4ca2708e4689a9ef013b080 Merge: 407aa3f 437014b 1373718 3d4b7ae e4f35c1 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 16:44:41 2016 +0200 Merge branches 'acpi-drivers', 'acpi-pm', 'acpi-ec' and 'acpi-video' * acpi-drivers: ACPI / GED: make evged.c explicitly non-modular ACPI / amba: Remove CLK_IS_ROOT ACPI / APD: Remove CLK_IS_ROOT ACPI: implement Generic Event Device * acpi-pm: ACPI / PM: Introduce efi poweroff for HW-full platforms without _S5 * acpi-ec: ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis ACPI 2.0 / ECDT: Enable correct ECDT initialization order ACPI 2.0 / ECDT: Remove early namespace reference from EC ACPI 2.0 / ECDT: Split EC_FLAGS_HANDLERS_INSTALLED * acpi-video: ACPI / video: mark acpi_video_get_levels() inline Thermal / ACPI / video: add INT3406 thermal driver ACPI/video: export acpi_video_get_levels video / backlight: remove the backlight_device_registered API video / backlight: add two APIs for drivers to use commit 407aa3ff6f54ea2be7959639d664ae5183e2e9f8 Merge: 44549e8 d1ce3bb Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 16:44:15 2016 +0200 Merge branch 'acpica' * acpica: (41 commits) ACPICA: Update version to 20160422 ACPICA: Move all ASCII utilities to a common file ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write() ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support in acpi_hw_read() ACPICA: Executer: Introduce a set of macros to handle bit width mask generation ACPICA: Hardware: Add optimized access bit width support ACPICA: Utilities: Add ACPI_IS_ALIGNED() macro ACPICA: Renamed some #defined flag constants for clarity ACPICA: ACPI 6.0, tools/iasl: Add support for new resource descriptors ACPICA: ACPI 6.0: Update _BIX support for new package element ACPICA: ACPI 6.1: Support for new PCCT subtable ACPICA: Refactor evaluate_object to reduce nesting ACPICA: Divergence: remove unwanted spaces for typedef ACPICA: Update version to 20160318 ACPICA: Namespace: Reorder \_SB._INI to make sure it is evaluated before _REG evaluations ACPICA: Events: Fix an issue that _REG association can happen before namespace is initialized ACPICA: Tables: Fix wrong MLC condition for dynamic table loading ACPICA: Interpreter: Fix wrong conditions for acpi_ev_install_region_handlers() invocation ACPICA: Hardware: Enhance acpi_hw_validate_register() with access_width/bit_offset awareness Utilities: Fix missing parentheses in ACPI_GET_BITS()/ACPI_SET_BITS() ... commit 484f689fc9d4eb91c68f53e97dc355b1b06c3edb Author: tom will <os@iscas.ac.cn> Date: Mon May 16 10:31:07 2016 -0400 drm/amdgpu: fix array out of bounds When the initial value of i is greater than zero, it may cause endless loop, resulting in array out of bounds, fix it. This is a port of the radeon fix to amdgpu. Signed-off-by: tom will <os@iscas.ac.cn> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/kv_dpm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a8efd58815a8d8bdca409a4b8319281cd9c24f7f Author: tom will <os@iscas.ac.cn> Date: Sun May 15 21:58:11 2016 -0700 drm/radeon: fix array out of bounds When the initial value of i is greater than zero, it may cause endless loop, resulting in array out of bounds, fix it. Signed-off-by: tom will <os@iscas.ac.cn> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/kv_dpm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 680834ca0ad4e9827048d4bda1e38db69c3dd1e4 Merge: 36fac9e 14b05c5 Author: David Sterba <dsterba@suse.com> Date: Mon May 16 15:46:29 2016 +0200 Merge branch 'foreign/jeffm/uapi' into for-chris-4.7-20160516 # Conflicts: # include/uapi/linux/btrfs.h commit 36fac9e9ff20f71fe7ba21978f5949a38d390a4b Merge: 5ef64a3 88acff6 Author: David Sterba <dsterba@suse.com> Date: Mon May 16 15:46:26 2016 +0200 Merge branch 'foreign/anand/dev-del-by-id-ext' into for-chris-4.7-20160516 commit 5ef64a3e757c94b2f2fc61465ef9603aaacaecff Merge: 73d32ce e1860a7 Author: David Sterba <dsterba@suse.com> Date: Mon May 16 15:46:24 2016 +0200 Merge branch 'cleanups-4.7' into for-chris-4.7-20160516 commit 73d32ce21e1701eaafcea3cbc2a8f27ab1967abe Merge: 02da2d7 4673272 Author: David Sterba <dsterba@suse.com> Date: Mon May 16 15:46:23 2016 +0200 Merge branch 'misc-4.7' into for-chris-4.7-20160516 commit a158f2b79ff1948c864a38296ea4249f7296362b Merge: 581abba 515511a Author: Takashi Iwai <tiwai@suse.de> Date: Mon May 16 14:59:00 2016 +0200 Merge tag 'asoc-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Updates for v4.7 The updates this time around are almost all driver code: - Further slow progress on the topology code. - Substantial updates and improvements for the da7219, es8328, fsl-ssi Intel and rcar drivers. commit 27c4a1c5ef61b6d4a9aeae68b24419b4319b97ed Merge: aa24781 bc19b9a 0b26985 6c51cc0 0b81561 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:31:56 2016 +0200 Merge branches 'pm-avs', 'pm-clk', 'powercap' and 'pm-tools' * pm-avs: PM / AVS: rockchip-io: make io-domains a child of the GRF * pm-clk: PM / clk: ensure we don't allocate a -ve size of count clks * powercap: powercap/intel_rapl: Add support for Kabylake * pm-tools: cpupower: fix potential memory leak cpupower: Add cpuidle parts into library cpupowerutils: bench: trivial fix of spelling mistake on "average" Fix cpupower manpages "NAME" section cpupower: bench: parse.c: fix several resource leaks Honour user's LDFLAGS commit aa24781b1cbd62cc7e7d2f1964bfd5727388bf3e Merge: 7777c27 fba1fbf 164a215 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:31:29 2016 +0200 Merge branches 'pm-core' and 'pm-domains' * pm-core: PM / sleep: Drop unused `info' variable PM / Runtime: Move ignore_children flag under CONFIG_PM PM / Runtime: Fix error path in pm_runtime_force_resume() * pm-domains: PM / Domains: Drop unnecessary wakeup code from pm_genpd_prepare() PM / Domains: Remove redundant pm_runtime_get|put*() in pm_genpd_prepare() PM / Domains: Remove ->save|restore_state() callbacks PM / Domains: Rename pm_genpd_runtime_suspend|resume() PM / Domains: Rename stop_ok to suspend_ok for the genpd governor commit 7777c2785b4ae5bfbef1c9f7dd4a08660541cb45 Merge: acc53b4 512eae3 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:31:15 2016 +0200 Merge branch 'pm-devfreq' * pm-devfreq: PM / devfreq: style/typo fixes PM / devfreq: exynos: Add the detailed correlation for Exynos5422 bus PM / devfreq: event: Find the instance of devfreq-event device by using phandle PM / devfreq: event: Add new Exynos NoC probe driver MAINTAINERS: Add samsung bus frequency driver entry PM / devfreq: exynos: Remove unused exynos4/5 busfreq driver PM / devfreq: exynos: Add the detailed correlation between sub-blocks and power line PM / devfreq: exynos: Update documentation for bus devices using passive governor PM / devfreq: exynos: Add support of bus frequency of sub-blocks using passive governor PM / devfreq: Add new passive governor PM / devfreq: Add new DEVFREQ_TRANSITION_NOTIFIER notifier PM / devfreq: Add devfreq_get_devfreq_by_phandle() PM / devfreq: exynos: Add documentation for generic exynos bus frequency driver PM / devfreq: exynos: Add generic exynos bus frequency driver commit acc53b49b183adaee6c839430a04b464908db84f Merge: c47b3bd fd7c3c2 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:31:03 2016 +0200 Merge branch 'pm-cpuidle' * pm-cpuidle: cpuidle: Replace ktime_get() with local_clock() drivers: firmware: psci: use const and __initconst for psci_cpuidle_ops soc: qcom: spm: Use const and __initconst for qcom_cpuidle_ops ARM: cpuidle: constify return value of arm_cpuidle_get_ops() ARM: cpuidle: add const qualifier to cpuidle_ops member in structures intel_idle: add BXT support cpuidle: Indicate when a device has been unregistered commit c47b3bd0d3a18a93d62b91d2d02e3fe599805e6d Merge: 29cff18 1aa7a6e Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:30:43 2016 +0200 Merge branch 'pm-cpufreq' * pm-cpufreq: (63 commits) intel_pstate: Clean up get_target_pstate_use_performance() intel_pstate: Use sample.core_avg_perf in get_avg_pstate() intel_pstate: Clarify average performance computation intel_pstate: Avoid unnecessary synchronize_sched() during initialization cpufreq: schedutil: Make default depend on CONFIG_SMP cpufreq: powernv: del_timer_sync when global and local pstate are equal cpufreq: powernv: Move smp_call_function_any() out of irq safe block intel_pstate: Clean up intel_pstate_get() cpufreq: schedutil: Make it depend on CONFIG_SMP cpufreq: governor: Fix handling of special cases in dbs_update() cpufreq: intel_pstate: Ignore _PPC processing under HWP cpufreq: arm_big_little: use generic OPP functions for {init, free}_opp_table cpufreq: tango: Use generic platdev driver cpufreq: Fix GOV_LIMITS handling for the userspace governor cpufreq: mvebu: Move cpufreq code into drivers/cpufreq/ cpufreq: dt: Kill platform-data mvebu: Use dev_pm_opp_set_sharing_cpus() to mark OPP tables as shared cpufreq: dt: Identify cpu-sharing for platforms without operating-points-v2 cpufreq: governor: Change confusing struct field and variable names cpufreq: intel_pstate: Enable PPC enforcement for servers ... commit 29cff1844a340f27fa8b9a47adcee880dcc3ae6f Merge: 44549e8 c854120 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 16 14:30:14 2016 +0200 Merge branch 'pm-opp' * pm-opp: PM / OPP: Move CONFIG_OF dependent code in a separate file PM / OPP: add non-OF versions of dev_pm_opp_{cpumask_, }remove_table PM / OPP: pass cpumask by reference PM / OPP: Add dev_pm_opp_get_sharing_cpus() PM / OPP: Mark cpumask as const in dev_pm_opp_set_sharing_cpus() PM / OPP: -ENOSYS is applicable only to syscalls PM / OPP: Mark shared-opp for non-dt case PM / OPP: Relocate dev_pm_opp_set_sharing_cpus() PM / OPP: dev_pm_opp_set_sharing_cpus() doesn't depend on CONFIG_OF PM / OPP: Add missing doc style comments PM / OPP: Propagate the error returned by _find_opp_table() commit b9c43856f21d97ffdfdd642acf2eb0b52d3b1555 Author: Pantelis Antoniou <pantelis.antoniou@konsulko.com> Date: Mon May 9 16:20:42 2016 +0300 of: dynamic: changeset prop-update revert fix When reverting an update property changeset entry that created a property the reverse operation is a remove property and not an update. Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/dynamic.c | 5 +++++ 1 file changed, 5 insertions(+) commit bb91f923d176578257aed682047653cc33148413 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:52 2016 +1000 drivers/of: Export of_detach_node() This exports of_detach_node() for PowerPC PowerNV PCI hotplug driver. No functional changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/dynamic.c | 1 + 1 file changed, 1 insertion(+) commit 83262418b0ef8bda66eca7c72d4c24ae6f7b230e Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:51 2016 +1000 drivers/of: Return allocated memory from of_fdt_unflatten_tree() This returns the allocate memory chunk, storing the unflattened device tree, from of_fdt_unflatten_tree() so that memory chunk can be released on demand in PowerNV PCI hotplug driver. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 33 ++++++++++++++++++++++----------- include/linux/of_fdt.h | 6 +++--- 2 files changed, 25 insertions(+), 14 deletions(-) commit c4263233f30e72f2645ff83c9074c994f88b015a Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:50 2016 +1000 drivers/of: Specify parent node in of_fdt_unflatten_tree() This adds one more argument to of_fdt_unflatten_tree() to specify the parent node of the FDT blob that is going to be unflattened. In the result, the function can be used to unflatten FDT blob that represents device sub-tree in PowerNV PCI hotplug driver. Cc: Jyri Sarha <jsarha@ti.com> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Jyri Sarha <jsarha@ti.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/gpu/drm/tilcdc/tilcdc_slave_compat.c | 2 +- drivers/of/fdt.c | 14 ++++++++++---- drivers/of/unittest.c | 2 +- include/linux/of_fdt.h | 1 + 4 files changed, 13 insertions(+), 6 deletions(-) commit 947c82cbf01c9c6012cb96e385b5f6d6d1e1decb Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:49 2016 +1000 drivers/of: Rename unflatten_dt_node() This renames unflatten_dt_node() to unflatten_dt_nodes() as it populates multiple device nodes from FDT blob. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 50800082f17645620bfdd357ba9141c86b76363d Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:48 2016 +1000 drivers/of: Avoid recursively calling unflatten_dt_node() In current implementation, unflatten_dt_node() is called recursively to unflatten device nodes in FDT blob. It's stress to limited stack capacity, especially to adopt the function to unflatten device sub-tree that possibly has multiple root nodes. In that case, we runs out of stack and the system can't boot up successfully. In order to reuse the function to unflatten device sub-tree, this avoids calling the function recursively, meaning the device nodes are unflattened in one call on unflatten_dt_node(): two arrays are introduced to track the parent path size and the device node of current level of depth, which will be used by the device node on next level of depth to be unflattened. All device nodes in more than 64 level of depth are dropped and hopefully, the system can boot up successfully with the partial device-tree. Also, the parameter "poffset" and "fpsize" are unused and dropped and the parameter "dryrun" is figured out from "mem == NULL". Besides, the return value of the function is changed to indicate the size of memory consumed by the unflatten device tree or error code. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 122 +++++++++++++++++++++++++++++++++---------------------- 1 file changed, 74 insertions(+), 48 deletions(-) commit dfbd4c6eff35f1b1065cca046003cc9d7ff27222 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 23:22:47 2016 +1000 drivers/of: Split unflatten_dt_node() The function unflatten_dt_node() is called recursively to unflatten device nodes and properties in the FDT blob. It looks complicated and hard to be understood. This splits the function into 3 functions: populate_properties(), populate_node() and unflatten_dt_node(). populate_properties(), which is called by populate_node(), creates properties for the indicated device node. The later one creates the device nodes from FDT blob. populate_node() gets the offset in FDT blob for next device nodes and then calls populate_node(). No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 249 ++++++++++++++++++++++++++++++++----------------------- 1 file changed, 147 insertions(+), 102 deletions(-) commit 65a9f31c5042e5bb50d30ed8ae374044be561054 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Sat May 14 20:09:52 2016 -0700 scripts/package/Makefile: rpmbuild add support of RPMOPTS After commit 21a59991ce0c ("scripts/package/Makefile: rpmbuild is needed for rpm targets"), it is no longer possible to specify RPMOPTS. For example, we can no longer able to control _topdir using the following make command. make RPMOPTS="--define '_topdir /home/xyz/workspace/'" binrpm-pkg Fixes: 21a59991ce0c ("scripts/package/Makefile: rpmbuild is needed for rpm targets") Cc: <stable@vger.kernel.org> # 4.3+ Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/package/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e8df1a95b685af84a81698199ee206e0e66a8b44 Author: Dave Hansen <dave.hansen@linux.intel.com> Date: Fri May 13 15:13:28 2016 -0700 x86/cpufeature, x86/mm/pkeys: Fix broken compile-time disabling of pkeys When I added support for the Memory Protection Keys processor feature, I had to reindent the REQUIRED/DISABLED_MASK macros, and also consult the later cpufeature words. I'm not quite sure how I bungled it, but I consulted the wrong word at the end. This only affected required or disabled cpu features in cpufeature words 14, 15 and 16. So, only Protection Keys itself was screwed over here. The result was that if you disabled pkeys in your .config, you might still see some code show up that should have been compiled out. There should be no functional problems, though. In verifying this patch I also realized that the DISABLE_PKU/OSPKE macros were defined backwards and that the cpu_has() check in setup_pku() was not doing the compile-time disabled checks. So also fix the macro for DISABLE_PKU/OSPKE and add a compile-time check for pkeys being enabled in setup_pku(). Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Cc: <stable@vger.kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Dave Hansen <dave@sr71.net> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Fixes: dfb4a70f20c5 ("x86/cpufeature, x86/mm/pkeys: Add protection keys related CPUID definitions") Link: http://lkml.kernel.org/r/20160513221328.C200930B@viggo.jf.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 12 ++++++------ arch/x86/include/asm/disabled-features.h | 6 +++--- arch/x86/kernel/cpu/common.c | 4 ++++ 3 files changed, 13 insertions(+), 9 deletions(-) commit 4544ba8c6b1743499cabb682897a469911845f15 Author: Borislav Petkov <bp@suse.de> Date: Mon May 16 11:34:28 2016 +0200 locking/rwsem: Fix comment on register clobbering Document explicitly that %edx can get clobbered on the slow path, on 32-bit kernels. Something I learned the hard way. :-\ Suggested-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Guenter Roeck <linux@roeck-us.net> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: linux-next@vger.kernel.org Link: http://lkml.kernel.org/r/20160516093428.GA26108@pd.tnic Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/lib/rwsem.S | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 1c447116d017a98c90f8f71c8c5a611e0aa42178 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Thu May 5 08:12:28 2016 +0300 mmc: mmc: Fix partition switch timeout for some eMMCs Some eMMCs set the partition switch timeout too low. Now typically eMMCs are considered a critical component (e.g. because they store the root file system) and consequently are expected to be reliable. Thus we can neglect the use case where eMMCs can't switch reliably and we might want a lower timeout to facilitate speedy recovery. Although we could employ a quirk for the cards that are affected (if we could identify them all), as described above, there is little benefit to having a low timeout, so instead simply set a minimum timeout. The minimum is set to 300ms somewhat arbitrarily - the examples that have been seen had a timeout of 10ms but were sometimes taking 60-70ms. Cc: stable@vger.kernel.org Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 685d29ef1783af0049c4aeeec43722e410d5845d Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 9 17:01:07 2016 +0200 mmc: sh_mobile_sdhi: enable SDIO IRQs for RCar Gen3 Tested on a Salvator-X board with a Spectec SDW-823 WLAN card. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 88ea46bcbfd677b779897bbada32ec0709a6c92f Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 9 09:59:59 2016 +0200 mmc: sdio: fall back to SDIO 1.0 for broken 1.1 cards I have two SDIO WLAN cards which specify being SDIO Rev. 1.1 cards but their FUNCE tuple reports the smaller size of a Rev 1.0 card. So, enforce 1.0 on these cards to avoid reading the not present registers. They are not really used anyhow. My cards initialize properly after this patch. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/sdio_cis.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 5b5fe95a6977b9cdd30749cb1576df2329d70da9 Author: Simon Horman <horms+renesas@verge.net.au> Date: Tue May 10 09:14:24 2016 +0900 mmc: sdhci-st: correct name of sd-uhs-sdr50 property Correct what appears to be a typo in the name of the sd-uhs-sdr50. Also fix mixed tab/space indentation. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Documentation/devicetree/bindings/mmc/sdhci-st.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 560e647515ca90f4277fb8d8f94d370dae0709b5 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 9 10:26:58 2016 +0200 MAINTAINERS: update entry for TMIO MMC driver I have some more additions planned for this driver, so I'd like to get notified of other changes and coordinate them. Drop Ian as maintainer because he hasn't been involved in development for a while. Thanks for all the initial work, of course! Also, reflect the recent changes to the include file layout. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Cc: Ian Molton <ian@mnementh.co.uk> Acked-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> MAINTAINERS | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit cc4d04be94e34fc6d53307b534f830c6854c8721 Author: Ken Sumrall <ksumrall@android.com> Date: Tue May 10 14:53:13 2016 +0530 mmc: block: improve logging of handling emmc timeouts Add some logging to make it clear just how the emmc timeout was handled. Signed-off-by: Ken Sumrall <ksumrall@android.com> [AmitP: cherry-picked this Android patch from aosp common kernel android-4.4] Signed-off-by: Amit Pundir <amit.pundir@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit ded97e0b165076556714d4a5708c87f5bcf03783 Author: Dong Aisheng <aisheng.dong@nxp.com> Date: Sat Apr 16 01:29:25 2016 +0800 mmc: sdhci: removed unneeded function wrappers After commit d6463f170cf0 ("mmc: sdhci: Remove redundant runtime PM calls"), some of original sdhci_do_xx() function wrappers becomes meaningless, so remove them. Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 60 ++++++++++++------------------------------------ 1 file changed, 15 insertions(+), 45 deletions(-) commit 4673272f43ae790ab9ec04e38a7542f82bb8f020 Author: Scott Talbert <scott.talbert@hgst.com> Date: Mon May 9 09:14:28 2016 -0400 btrfs: fix memory leak during RAID 5/6 device replacement A 'struct bio' is allocated in scrub_missing_raid56_pages(), but it was never freed anywhere. Signed-off-by: Scott Talbert <scott.talbert@hgst.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/scrub.c | 2 ++ 1 file changed, 2 insertions(+) commit 52e9e6e05617264e6e609a8699098380d6b7a6aa Author: Fengguang Wu <fengguang.wu@intel.com> Date: Thu Mar 17 10:36:28 2016 +0800 microblaze: pci: export isa_io_base to fix link errors ERROR: "isa_io_base" [sound/pci/vx222/snd-vx222.ko] undefined! ERROR: "isa_io_base" [sound/pci/trident/snd-trident.ko] undefined! ERROR: "isa_io_base" [sound/pci/snd-via82xx.ko] undefined! ... ERROR: "isa_io_base" [drivers/watchdog/wdt_pci.ko] undefined! ERROR: "isa_io_base" [drivers/watchdog/pcwd_pci.ko] undefined! ERROR: "isa_io_base" [drivers/video/vgastate.ko] undefined! ... ERROR: "isa_io_base" [drivers/video/fbdev/cirrusfb.ko] undefined! ERROR: "isa_io_base" [drivers/video/fbdev/arkfb.ko] undefined! ERROR: "isa_io_base" [drivers/usb/host/uhci-hcd.ko] undefined! ERROR: "isa_io_base" [drivers/usb/host/isp1362-hcd.ko] undefined! ERROR: "isa_io_base" [drivers/tty/serial/jsm/jsm.ko] undefined! ERROR: "isa_io_base" [drivers/tty/serial/8250/8250_pci.ko] undefined! ... ERROR: "isa_io_base" [drivers/scsi/qla2xxx/qla2xxx.ko] undefined! ERROR: "isa_io_base" [drivers/scsi/ppa.ko] undefined! Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> arch/microblaze/pci/pci-common.c | 2 ++ 1 file changed, 2 insertions(+) commit fbce3befd60d40639bf3c6b60f7477b2f988f92d Author: Michal Simek <michal.simek@xilinx.com> Date: Mon Nov 16 08:53:38 2015 +0100 microblaze: Wire up userfaultfd, membarrier, mlock2 syscalls Wire up new syscalls userfaultfd, membarrier and mlock2. Signed-off-by: Michal Simek <michal.simek@xilinx.com> arch/microblaze/include/asm/unistd.h | 2 +- arch/microblaze/include/uapi/asm/unistd.h | 3 +++ arch/microblaze/kernel/syscall_table.S | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) commit 581abbaa03367f0b1327521f30bd2b69b8075b2f Merge: 84add30 639db59 Author: Takashi Iwai <tiwai@suse.de> Date: Mon May 16 09:13:08 2016 +0200 Merge branch 'for-next' into for-linus commit 191b07541fcdd1de1ccc71d00bc28ca5060dd484 Author: Michele Di Giorgio <michele.digiorgio@arm.com> Date: Wed May 11 10:49:07 2016 +0100 thermal: check validity get_trip_hyst function pointer in bang-bang governor Bang-bang thermal governor uses trip point hysteresis to make decisions. Hysteresis is a required property in the device tree for trip points, but it is an optional thermal zone device operation. Hence, we need to check whether the function pointer is valid or not. If it is not available, we assume the hysteresis to be zero. Consequently, a highly varying temperature will make the governor continuosly switch a cooling device ON and OFF. CC: Zhang Rui <rui.zhang@intel.com> CC: Eduardo Valentin <edubezval@gmail.com> CC: Peter Feuerer <peter@piie.net> Signed-off-by: Michele Di Giorgio <michele.digiorgio@arm.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com> drivers/thermal/gov_bang_bang.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit a8165d421dabd476d811f89942e345827f7b1497 Author: chenhui zhao <chenhui.zhao@freescale.com> Date: Fri Jan 15 17:38:20 2016 +0800 powerpc/fsl-pci: Add a workaround for PCI 5 errata Issue: As a master, the PCI IP block can combine a memory write to the last PCI double word (4 bytes) of a cacheline with a 4 byte memory write to the first PCI double word of the subsequent cacheline. This affects 32-bit PCI target devices that blindly assert STOP on memory-write transactions, without detecting that the data beat being transferred is the last data beat of the transaction. It can cause a hang. PCI-X operation is not affected by this erratum. Workaround: Setting the bit MDS in the PCI Bus Function Register will disable the combining of crossing cacheline boundary requests into one burst transaction. Therefore, it can prevent the errata scenario from occurring. This errata exists in MPC8543, MPC8543E, MPC8545, MPC8545E, MPC8547, MPC8547E, MPC8548 and MPC8548E. Refer to PCI 5 in MPC8548 errata document. Signed-off-by: Zhao Chenhui <chenhui.zhao@freescale.com> Signed-off-by: Zhiqiang Hou <Zhiqiang.Hou@freescale.com> [scottwood: whitespace fix] Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/sysdev/fsl_pci.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 6a369fa28509c3b6a35db979d6fa97a075b94876 Author: Hou Zhiqiang <Zhiqiang.Hou@freescale.com> Date: Wed Jan 13 15:54:46 2016 +0800 powerpc/fsl: Fix SPI compatible on t208xrdb and t1040rdb On the t208xrdb and t1040rdb, the SPI device is n25q512ax3 instead of n25q512a. Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@freescale.com> Signed-off-by: Scott Wood <oss@buserror.net> arch/powerpc/boot/dts/fsl/t104xrdb.dtsi | 2 +- arch/powerpc/boot/dts/fsl/t208xrdb.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 04cafed7fc19a8010771c788708ac97c405fc3de Author: Peter Zijlstra <peterz@infradead.org> Date: Thu May 12 13:57:45 2016 +0200 locking/rwsem: Fix down_write_killable() The new signal_pending exit path in __rwsem_down_write_failed_common() was fingered as breaking his kernel by Tetsuo Handa. Upon inspection it was found that there are two things wrong with it; - it forgets to remove WAITING_BIAS if it leaves the list empty, or - it forgets to wake further waiters that were blocked on the now removed waiter. Especially the first issue causes new lock attempts to block and stall indefinitely, as the code assumes that pending waiters mean there is an owner that will wake when it releases the lock. Reported-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Tested-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Tested-by: Michal Hocko <mhocko@kernel.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Davidlohr Bueso <dave@stgolabs.net> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Waiman Long <Waiman.Long@hpe.com> Link: http://lkml.kernel.org/r/20160512115745.GP3192@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/rwsem-xadd.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) commit f23e0f6507d9e5bcfc30a7f6be5d8df8fad9ec85 Merge: bf14e9e 1c306f7 Author: David S. Miller <davem@davemloft.net> Date: Sun May 15 13:47:27 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-05-14 This series contains updates to i40e and i40evf. Kevin adds support to disable link on all ports and changes bits set for telling firmware the PHY needs to be modified by the driver. Anjali adds a feature to enable/disable all multicast for a trusted VF. Added priv-flag knob to configure global true promiscuous support. Shannon adds the support code for calling the admin queue API call aq_set_switch_config(). Mitch modifies the VF, to log a message if an untrusted VF attempts to configure promiscuous mode, but lies to it and returns everything is ok instead of returning an error. Corrects the logic for reporting the receive packet hash. Fixed the adding of a broadcast filter for VFs, since that all VSIs are configured to receive broadcasts as default, so do not need to add a filter. Catherine refactors the ethtool get_settings to report the possible supported link modes from what we know about the current PHY type and that with the firmware supported PHY types. Jacob changes the driver to use WARN_ONCE in order to highlight the issue, but do not display a warning every time when receive hang message is received. Akeem corrects receive ptype payload layer for non_tunneled IPv6, when it should be layer 4 for UDP, instead of layer 3. Dan Carpenter fixes an uninitialized variable bug. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bf14e9ec80dea9a16cd47bdf1d7c418add2594f0 Merge: 909b27f7 b67daab Author: David S. Miller <davem@davemloft.net> Date: Sun May 15 13:35:49 2016 -0400 Merge branch 'bnxt_en-next' Michael Chan says: ==================== bnxt_en: updates for net-next. Non-critical bug fixes, improvements, a new ethtool feature, and a new device ID. v2: Fixed a bug in bnxt_get_module_eeprom() found by Ben Hutchings. Ajit Khaparde (2): bnxt_en: Add Support for ETHTOOL_GMODULEINFO and ETHTOOL_GMODULEEEPRO bnxt_en: Report PCIe link speed and width during driver load Michael Chan (6): bnxt_en: Reduce maximum ring pages if page size is 64K. bnxt_en: Improve the delay logic for firmware response. bnxt_en: Fix length value in dmesg log firmware error message. bnxt_en: Simplify and improve unsupported SFP+ module reporting. bnxt_en: Add BCM57314 device ID. bnxt_en: Use dma_rmb() instead of rmb(). Satish Baddipadige (1): bnxt_en: Fix invalid max channel parameter in ethtool -l. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b67daab033293b3882ba4dc926ffb084d70044e0 Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:51 2016 -0400 bnxt_en: Use dma_rmb() instead of rmb(). Use the weaker but more appropriate dma_rmb() to order the reading of the completion ring. Suggested-by: Ajit Khaparde <ajit.khaparde@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5049e33b559a44e9f216d86c58c7c7fce6f5df2f Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:50 2016 -0400 bnxt_en: Add BCM57314 device ID. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 +++ 1 file changed, 3 insertions(+) commit 10289bec0072b13f629a654d94faf1dadd44f335 Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:49 2016 -0400 bnxt_en: Simplify and improve unsupported SFP+ module reporting. The current code is more complicated than necessary and can only report unsupported SFP+ module if it is plugged in after the device is up. Rename bnxt_port_module_event() to bnxt_get_port_module_status(). We already have the current module_status in the link_info structure, so just check that and report any unsupported SFP+ module status. Delete the unnecessary last_port_module_event. Call this function at the end of bnxt_open to report unsupported module already plugged in. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 66 ++++++++++++++----------------- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 1 - 2 files changed, 30 insertions(+), 37 deletions(-) commit 8578d6c19a308dea3daf3d03acdf18724ec05590 Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:48 2016 -0400 bnxt_en: Fix length value in dmesg log firmware error message. The len value in the hwrm error message is wrong. Use the properly adjusted value in the variable len. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a11fa2be6d1564375dc57530680268ad569c2632 Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:47 2016 -0400 bnxt_en: Improve the delay logic for firmware response. The current code has 2 problems: 1. The maximum wait time is not long enough. It is about 60% of the duration specified by the firmware. It is calling usleep_range(600, 800) for every 1 msec we are supposed to wait. 2. The granularity of the delay is too coarse. Many simple firmware commands finish in 25 usec or less. We fix these 2 issues by multiplying the original 1 msec loop counter by 40 and calling usleep_range(25, 40) for each iteration. There is also a second delay loop to wait for the last DMA word to complete. This delay loop should be a very short 5 usec wait. This change results in much faster bring-up/down time: Before the patch: time ip link set p4p1 up real 0m0.120s user 0m0.001s sys 0m0.009s After the patch: time ip link set p4p1 up real 0m0.030s user 0m0.000s sys 0m0.010s Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit d0a42d6fc8eaf1b64f62b0bbc3b829b756eacf57 Author: Michael Chan <michael.chan@broadcom.com> Date: Sun May 15 03:04:46 2016 -0400 bnxt_en: Reduce maximum ring pages if page size is 64K. The chip supports 4K/8K/64K page sizes for the rings and we try to match it to the CPU PAGE_SIZE. The current page size limits for the rings are based on 4K/8K page size. If the page size is 64K, these limits are too large. Reduce them appropriately. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.h | 7 +++++++ 1 file changed, 7 insertions(+) commit 90c4f788f6c08aaa52edbb47a817403376523375 Author: Ajit Khaparde <ajit.khaparde@broadcom.com> Date: Sun May 15 03:04:45 2016 -0400 bnxt_en: Report PCIe link speed and width during driver load Add code to log a message during driver load indicating PCIe link speed and width. The log message will look like this: bnxt_en 0000:86:00.0 eth0: PCIe: Speed 8.0GT/s Width x8 Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 42ee18fe4ca2a12b8370bb1c53fa6b9f9300c70c Author: Ajit Khaparde <ajit.khaparde@broadcom.com> Date: Sun May 15 03:04:44 2016 -0400 bnxt_en: Add Support for ETHTOOL_GMODULEINFO and ETHTOOL_GMODULEEEPRO Add support to fetch the SFP EEPROM settings from the firmware and display it via the ethtool -m command. We support SFP+ and QSFP modules. v2: Fixed a bug in bnxt_get_module_eeprom() found by Ben Hutchings. Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 1 + drivers/net/ethernet/broadcom/bnxt/bnxt.h | 11 ++ drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 121 ++++++++++++++++++++++ drivers/net/ethernet/broadcom/bnxt/bnxt_hsi.h | 34 ++++++ 4 files changed, 167 insertions(+) commit 18d6e4e2d800cbd44a7d7d215a49f99c6508e4a5 Author: Satish Baddipadige <sbaddipa@broadcom.com> Date: Sun May 15 03:04:43 2016 -0400 bnxt_en: Fix invalid max channel parameter in ethtool -l. When there is only 1 MSI-X vector or in INTA mode, tx and rx pre-set max channel parameters are shown incorrectly in ethtool -l. With only 1 vector, bnxt_get_max_rings() will return -ENOMEM. bnxt_get_channels should check this return value, and set max_rx/max_tx to 0 if it is non-zero. Signed-off-by: Satish Baddipadige <sbaddipa@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 909b27f706433a0b3dff79aa259de63aafe40a42 Merge: 8fbb89c 272911b Author: David S. Miller <davem@davemloft.net> Date: Sun May 15 13:32:12 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net The nf_conntrack_core.c fix in 'net' is not relevant in 'net-next' because we no longer have a per-netns conntrack hash. The ip_gre.c conflict as well as the iwlwifi ones were cases of overlapping changes. Conflicts: drivers/net/wireless/intel/iwlwifi/mvm/tx.c net/ipv4/ip_gre.c net/netfilter/nf_conntrack_core.c Signed-off-by: David S. Miller <davem@davemloft.net> commit 73e8b0528346e88a0624f2d9821f382cd6256677 Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Sat May 14 14:17:08 2016 +0200 i2c: rcar: add DMA support Make it possible to transfer i2c message buffers via DMA. Start/Stop/Sending_Slave_Address and some data is still handled using the old state machine, it is sending the bulk of the data that is done via DMA. The first byte of a transmission and the last two bytes of reception are sent/received using PIO. This is needed for the HW to have access to the first byte before DMA transmit and to be able to set the STOP condition for DMA reception. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Acked-by: Rob Herring <robh@kernel.org> Tested-by: Wolfram Sang <wsa+renesas@sang-engineering.com> [wsa: fixed a checkpatch warning] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Documentation/devicetree/bindings/i2c/i2c-rcar.txt | 3 + drivers/i2c/busses/i2c-rcar.c | 233 ++++++++++++++++++++- 2 files changed, 232 insertions(+), 4 deletions(-) commit 8fbb89c6fbfd1cda9ae413cd1e042837a8edbdeb Author: Florian Fainelli <f.fainelli@gmail.com> Date: Sat May 14 12:49:54 2016 -0700 net: switchdev: Drop EXPERIMENTAL from description Switchdev has been around for quite a while now, putting "EXPERIMENTAL" in the description is no longer accurate, drop it. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/switchdev/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a3e5afe491bf7462013aa9f0bb3b55e3d05b784d Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Thu Apr 28 23:39:53 2016 +0900 iio: pressure: bmp280: fix error message for wrong chip id The bmp280 driver also supports BMP180 which has a different chip id with BMP280. The probe routine verifies that the device reports the correct chip id but the error message is confusing as if BMP280's chip id is always expected. Reported-by: Matt Ranostay <mranostay@gmail.com> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Matt Ranostay <mranostay@gmail.com> Cc: Vlad Dogaru <vlad.dogaru@intel.com> Cc: Christoph Mair <christoph.mair@gmail.com> Cc: Jonathan Cameron <jic23@kernel.org> Cc: Hartmut Knaack <knaack.h@gmx.de> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/bmp280.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ae67643edc6edcab41d8d5d35cb796416b253a01 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Wed May 11 08:47:46 2016 -0400 Documentation: Add ebc-c384_wdt watchdog-parameters.txt entry The WinSystems EBC-C384 watchdog timer driver supports two module parameters: timeout and nowayout. These parameters should be documented in the watchdog-parameters.txt file. Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> Documentation/watchdog/watchdog-parameters.txt | 4 ++++ 1 file changed, 4 insertions(+) commit 12fe36e2ca0e474a2d7b48ab018d16977f9745a4 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Fri May 6 18:29:41 2016 +0530 watchdog: shwdt: Use setup_timer() The function setup_timer combines the initialization of a timer with the initialization of the timer's function and data fields. The multiline code for timer initialization is now replaced with function setup_timer. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/shwdt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit d904ac34bdbcf62a50c745cfe991681ae3948e4e Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Fri May 6 18:29:40 2016 +0530 watchdog: cpwd: Use setup_timer() The function setup_timer combines the initialization of a timer with the initialization of the timer's function and data fields. The multiline code for timer initialization is now replaced with function setup_timer. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/cpwd.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 022eedeebfdd54c67c7c3b8ef4f5ff42b4ba0cc5 Merge: b79ef07 0e95abf Author: Jonathan Corbet <corbet@lwn.net> Date: Sat May 14 10:21:57 2016 -0600 Merge branch 'jani-rest' into docs-next Patch series from Jani Nikula: > Jon, I was hoping we could consider nudging things forward a bit in the > kernel-doc and docproc reStructuredText front already in 4.7. I know > it's a bit close to the merge window, but this should not interfere with > anything else, and some of it are just trivial cleanups that I've been > carrying around locally. > > Obviously this doesn't actually add anything that uses them yet, but I > think it would be helpful to have some common base in to ease > collaboration. commit b79ef07d205c6504e701b48380d33fe2bab78ec5 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed May 11 13:56:05 2016 +0200 serial: doc: Use port->state instead of info As of commit ebd2c8f6d2ec4012 ("serial: kill off uart_info"), the circular transmission buffer is part of struct uart_state instead of struct uart_info. Make it clear this structure is pointed to from struct uart_port. Change 'circ' to 'circ_buf' to match the structure name while we're at it. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 95f981f2e3b9a27ea2eb744b6861a3b9c81a1fde Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed May 11 13:56:04 2016 +0200 serial: doc: Always refer to tty_port->mutex Stop referring to the mutex member of the tty_port struct as 'port->mutex', as 'port' is ambiguous, and usually refers to the uart_port struct in this document. Use 'tty_port->mutex' instead, following the single existing use. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit fc4d2c7390dde766ec62f8f83be06e9227e9eb7a Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 13:56:26 2016 +0200 arm64: defconfig: enable Renesas Watchdog Timer Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> arch/arm64/configs/defconfig | 2 ++ 1 file changed, 2 insertions(+) commit bd99b68ed7f96c9c845aad2a25f84145213058f2 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 13:56:23 2016 +0200 watchdog: renesas-wdt: add driver Add support for watchdogs (RWDT and SWDT) found on RCar Gen3 based SoCs from Renesas. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> .../devicetree/bindings/watchdog/renesas-wdt.txt | 25 +++ drivers/watchdog/Kconfig | 8 + drivers/watchdog/Makefile | 1 + drivers/watchdog/renesas_wdt.c | 213 +++++++++++++++++++++ 4 files changed, 247 insertions(+) commit 30955e71fc2bd1b966ce6531285ac59ae653819f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue May 10 20:59:56 2016 +0200 Documentation: vm: Spelling s/paltform/platform/g Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/vm/hugetlbpage.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2bdbc5bc16c338a43c9ac7ef93c1a60a8b17ee7d Author: Qiang Huang <h.huangqiang@huawei.com> Date: Wed May 11 14:07:31 2016 +0800 Documentation/memcg: update kmem limit doc as codes behavior The restriction of kmem setting is not there anymore because the accounting is enabled by default even in the cgroup v1 - see b313aeee2509 ("mm: memcontrol: enable kmem accounting for all cgroups in the legacy hierarchy"). Update docs accordingly. Signed-off-by: Qiang Huang <h.huangqiang@huawei.com> Acked-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/cgroup-v1/memory.txt | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 0e95abf9be3108498128458ffb087209e0a1b5fa Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:44 2016 +0300 docproc: print a comment about autogeneration for rst output Leave a hint to folks which file to edit instead. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 064669b43baa4b74b262c49db3ce69118e2f0f2d Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:43 2016 +0300 docproc: add support for reStructuredText format via --rst option Expect reStructuredText input and have kernel-doc produce reStructuredText output with the new --rst option. Also add --docbook option for completeness. If no option is given, default to reStructuredText if the input file has ".rst" extension, DocBook otherwise. Directives for reStructuredText use .. ! instead of just !, to make them reStructuredText comments. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 90 ++++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 80 insertions(+), 10 deletions(-) commit 1dcdad0aacb6d762b77f3e17167d131a14c0dbce Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:42 2016 +0300 docproc: abstract terminating lines at first space Cleaner code. Also fixes a bug when F or P directives didn't in fact have space. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) commit a48dc45e9c02ebaebc79de5b3fec8e4f59a9fe9f Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:41 2016 +0300 docproc: abstract docproc directive detection Helps follow-up work. No functional changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) commit 868fb19212ca5bdbfa765a97a4bf6d2439b89056 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:40 2016 +0300 docproc: reduce unnecessary indentation Improves clarity. No functional changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 93 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 47 insertions(+), 46 deletions(-) commit 568fb2dec9c68bb38c2a1ad01fb3d4dd41488115 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:39 2016 +0300 docproc: add variables for subcommand and filename Improves clarity. No functional changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/docproc.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit 6285097654725f39357527b553d03b70bfbaf4d2 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:38 2016 +0300 kernel-doc: use rst C domain directives and references for types First, the headings for structs, enums and typedefs will be similar to functions. Second, this provides a kind of namespace for cross references. Third, and most importantly, the return and parameter types from .. c:function:: definitions will automagically become cross references to the documented types. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/kernel-doc | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) commit c0d1b6ee780ab16f16cdbe046aa9c83a2a31f9e2 Author: Jonathan Corbet <corbet@lwn.net> Date: Thu May 12 16:15:37 2016 +0300 kernel-doc: produce RestructuredText output If given the -rst flag, output will now be in RestructuredText. Various glitches to be worked out yet. In the end I decided not to use RST section headings within the kerneldoc comments. gpu.tmpl already has headings five levels deep; adding more is not going to bring clarity. This is really just Jani Nikula's asciidoc change with the serial numbers filed off. It's a hack job that doubtless needs a lot of cleaning up. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/kernel-doc | 233 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 233 insertions(+) commit fadc0b31cba0bb56bce1a3259cc60e4d7ee67333 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu May 12 16:15:36 2016 +0300 kernel-doc: rewrite usage description, remove duplicated comments Instead of having the kernel-doc usage in both comments and in output to the user, merge them all to one here document. While at it, imrove the text and make it pretty. Give shoemaker's children some shoes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> scripts/kernel-doc | 83 ++++++++++++++++++++++++------------------------------ 1 file changed, 37 insertions(+), 46 deletions(-) commit e26e74b15468b42c47cf9b045539720006abb1e4 Author: Colin Ian King <colin.king@canonical.com> Date: Tue Apr 26 18:18:49 2016 +0100 watchdog: remove error message when unable to allocate watchdog device The dev_err message is superfluous because the failure is already printed by dev_kzalloc, so remove it. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/jz4740_wdt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit b97cb21a46341575c6cbe3d327a08b99030c3aee Author: Knud Poulsen <knpo@ieee.org> Date: Tue Apr 26 08:44:16 2016 +0200 watchdog: f71808e_wdt: Fix WDTMOUT_STS register read Tested and verified on Lanner LEC-3030 Industrial PC (with F81865) Datasheet verified for F71808, F71858, F71862, F71869, F71869A, F71882, F71889, F81865 Datasheet references: F71808A: http://www.electronicsdatasheets.com/download/534cf560e34e2406135f4658.pdf?format=pdf F71858: http://www.electronicsdatasheets.com/download/534cf55fe34e2406135f4635.pdf?format=pdf F71862: http://www.hardwaresecrets.com/datasheets/F71862_V027P.pdf F71869: http://www.clubedohardware.com.br/datasheets/366451_F71869.pdf F71869A: http://www.chipset-ic.com/datasheet/F71869AD.pdf F71882: http://www.digchip.com/datasheets/parts/datasheet/931/F71882-pdf.php F71889: http://pdf1.alldatasheet.com/datasheet-pdf/view/406312/FINTEK/F71889.html F81865: http://www.hardwaresecrets.com/datasheets/F81865_V028P.pdf http://www.alldatasheet.com/datasheet-pdf/pdf/406317/FINTEK/F81865.html Signed-off-by: Knud Poulsen <knpo@ieee.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/f71808e_wdt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 85c130a8bf542205a84edbca225972375fcb07eb Author: Knud Poulsen <knpo@ieee.org> Date: Mon Apr 25 17:34:47 2016 +0200 watchdog: f71808e_wdt: Fix typo Spelling/ typo Signed-off-by: Knud Poulsen <knpo@ieee.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/f71808e_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ea0c03e80ccd99cb0ab208397da5a417dabf9a22 Author: Knud Poulsen <knpo@ieee.org> Date: Mon Apr 25 12:28:51 2016 +0200 watchdog: f71808e_wdt: Add F81865 support Adds watchdog enable support for Fintek F81865 Super-IO chip to Fintek wdt driver (f71808e_wdt) Tested and verified on Lanner LEC-3030 Industrial PC Datasheet references: http://www.hardwaresecrets.com/datasheets/F81865_V028P.pdf http://www.alldatasheet.com/datasheet-pdf/pdf/406317/FINTEK/F81865.html Signed-off-by: Knud Poulsen <knpo@ieee.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/f71808e_wdt.c | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) commit 46856fabe40cc80f92134683cdec7dc0fc8f4000 Author: Lucas Stach <dev@lynxeye.de> Date: Tue May 3 19:15:58 2016 +0200 watchdog: sp5100_tco: properly check for new register layouts Commits 190aa4304de6 (Add AMD Mullins platform support) and cca118fa2a0a94 (Add AMD Carrizo platform support) enabled the driver on a lot more devices, but the following commit missed a single location in the code when checking if the SB800 register offsets should be used. This leads to the wrong register being written which in turn causes ACPI to go haywire. Fix this by introducing a helper function to check for the new register layout and use this consistently. https://bugzilla.kernel.org/show_bug.cgi?id=114201 https://bugzilla.redhat.com/show_bug.cgi?id=1329910 Fixes: bdecfcdb5461 (sp5100_tco: fix the device check for SB800 and later chipsets) Cc: stable@vger.kernel.org (4.5+) Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/sp5100_tco.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit e1f30282a1d3d0c75d5a08e47c6ac1563065be52 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Apr 21 07:38:14 2016 -0700 watchdog: core: Fix circular locking dependency lockdep reports the following circular locking dependency. ====================================================== INFO: possible circular locking dependency detected ] 4.6.0-rc3-00191-gfabf418 #162 Not tainted ------------------------------------------------------- systemd/1 is trying to acquire lock: ((&(&wd_data->work)->work)){+.+...}, at: [<80141650>] flush_work+0x0/0x280 but task is already holding lock: (&wd_data->lock){+.+...}, at: [<804acfa8>] watchdog_release+0x18/0x190 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&wd_data->lock){+.+...}: [<80662310>] mutex_lock_nested+0x64/0x4a8 [<804aca4c>] watchdog_ping_work+0x18/0x4c [<80143128>] process_one_work+0x1ac/0x500 [<801434b4>] worker_thread+0x38/0x554 [<80149510>] kthread+0xf4/0x108 [<80107c10>] ret_from_fork+0x14/0x24 -> #0 ((&(&wd_data->work)->work)){+.+...}: [<8017c4e8>] lock_acquire+0x70/0x90 [<8014169c>] flush_work+0x4c/0x280 [<801440f8>] __cancel_work_timer+0x9c/0x1e0 [<804acfcc>] watchdog_release+0x3c/0x190 [<8022c5e8>] __fput+0x80/0x1c8 [<80147b28>] task_work_run+0x94/0xc8 [<8010b998>] do_work_pending+0x8c/0xb4 [<80107ba8>] slow_work_pending+0xc/0x20 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&wd_data->lock); lock((&(&wd_data->work)->work)); lock(&wd_data->lock); lock((&(&wd_data->work)->work)); *** DEADLOCK *** 1 lock held by systemd/1: stack backtrace: CPU: 2 PID: 1 Comm: systemd Not tainted 4.6.0-rc3-00191-gfabf418 #162 Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree) [<8010f5e4>] (unwind_backtrace) from [<8010c038>] (show_stack+0x10/0x14) [<8010c038>] (show_stack) from [<8039d7fc>] (dump_stack+0xa8/0xd4) [<8039d7fc>] (dump_stack) from [<80177ee0>] (print_circular_bug+0x214/0x334) [<80177ee0>] (print_circular_bug) from [<80179230>] (check_prevs_add+0x4dc/0x8e8) [<80179230>] (check_prevs_add) from [<8017b3d8>] (__lock_acquire+0xc6c/0x14ec) [<8017b3d8>] (__lock_acquire) from [<8017c4e8>] (lock_acquire+0x70/0x90) [<8017c4e8>] (lock_acquire) from [<8014169c>] (flush_work+0x4c/0x280) [<8014169c>] (flush_work) from [<801440f8>] (__cancel_work_timer+0x9c/0x1e0) [<801440f8>] (__cancel_work_timer) from [<804acfcc>] (watchdog_release+0x3c/0x190) [<804acfcc>] (watchdog_release) from [<8022c5e8>] (__fput+0x80/0x1c8) [<8022c5e8>] (__fput) from [<80147b28>] (task_work_run+0x94/0xc8) [<80147b28>] (task_work_run) from [<8010b998>] (do_work_pending+0x8c/0xb4) [<8010b998>] (do_work_pending) from [<80107ba8>] (slow_work_pending+0xc/0x20) Turns out the call to cancel_delayed_work_sync() in watchdog_release() is not necessary and can be dropped. If the worker is no longer necessary, the subsequent call to watchdog_update_worker() will cancel it. If it is already running, it won't do anything, since the worker function checks if it needs to ping the watchdog or not. Reported-by: Clemens Gruber <clemens.gruber@pqgruber.com> Tested-by: Clemens Gruber <clemens.gruber@pqgruber.com> Fixes: 11d7aba9ceb7 ("watchdog: imx2: Convert to use infrastructure triggered keepalives") Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> Cc: stable <stable@vger.kernel.org> drivers/watchdog/watchdog_dev.c | 1 - 1 file changed, 1 deletion(-) commit 358d5a565fa6a5f51fcd04f8e890a0a474a814fe Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 12 17:56:11 2016 +0200 watchdog: core: fix trivial typo in a comment Let's have balanced round brackets. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/watchdog_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60d5794fe5a50d02f4a0df84b45910a4dfa8b487 Merge: 13069bd b923c6c Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Sat May 14 11:25:35 2016 +0200 Merge tag 'usb-serial-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial into usb-next Johan writes: USB-serial updates for v4.7-rc1 These updates fixes a number of issues where resources were not properly released on probe errors. Included is also a fix for hardware flow-control disable for cp210x. Support for Moxa UPort 11x0 is added to the ti_usb_3410_5052 driver, and included are also some general code clean ups. Signed-off-by: Johan Hovold <johan@kernel.org> commit 511deae0261c839461948f2d4d1c13b8c8a59cd8 Author: Dave Jiang <dave.jiang@intel.com> Date: Wed May 11 14:32:49 2016 -0700 dmaengine: ioatdma: disable relaxed ordering for ioatdma ioatdma by default is in snoop mode. Relaxed ordering according to spec does not do anything in snoop mode. However, it causes hang or significant performance degrade when tested with NTB. Disabling in the driver due to some BIOS do not configure it correctly. Signed-off-by: Dave Jiang <dave.jiang@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/ioat/init.c | 12 ++++++++++++ drivers/dma/ioat/registers.h | 7 +++++++ 2 files changed, 19 insertions(+) commit 20ea6be6bffd4da8cfe3aeea9e6a090f346a54da Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Wed May 11 15:15:11 2016 +0200 dmaengine: of_dma: approximate an average distribution Currently the following DT description would result in dmac0 always being tried first and dmac1 second if dmac0 was unavailable. This results in heavier use of dmac0 then of dmac1. This patch adds an approximate average distribution over the two nodes lessening the load of anyone of them. i2c6: i2c@e60b0000 { ... dmas = <&dmac0 0x77>, <&dmac0 0x78>, <&dmac1 0x77>, <&dmac1 0x78>; dma-names = "tx", "rx", "tx", "rx"; ... }; Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Suggested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/of-dma.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit d57d3a48ca784615e839475d8bdf8f3cecf77c8d Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed May 11 13:39:27 2016 -0400 dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dmaengine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 3b2bc8a732a8dc2a7c4407aea64127229eb8fdd1 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Tue May 10 13:40:54 2016 +0300 dmaengine: edma: Re-evaluate errors when ccerr is triggered w/o error event When the ccerr handler is called but the error registers indicate no error events we need to command eDMA to re-evaluate the errors. Otherwise we can receive flood of error interrupts. Reported-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/edma.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 84df082cad236a6ec70df1fbbf3d8dcb5c5f994e Author: Nigel Croxon <nigel.croxon@hpe.com> Date: Wed Apr 6 14:40:05 2016 -0400 watchdog: hpwdt: Adjust documentation to match latest kernel module parameters. Adjust documentation to match latest kernel module parameters. Signed-off-by: Nigel Croxon <nigel.croxon@hpe.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> Documentation/watchdog/hpwdt.txt | 57 +++++++++++++++++++++------------------- 1 file changed, 30 insertions(+), 27 deletions(-) commit bc677ff42e81bbf78308a7b66cf7b63b0f5c26b0 Author: Tim Harvey <tharvey@gateworks.com> Date: Fri Apr 1 08:16:43 2016 -0700 watchdog: imx2_wdt: add external reset support via dt prop The IMX6 watchdog supports assertion of a signal (WDOG_B) which can be pinmux'd to an external pin. This is typically used for boards that have PMIC's in control of the IMX6 power rails. In fact, failure to use such an external reset on boards with external PMIC's can result in various hangs due to the IMX6 not being fully reset [1] as well as the board failing to reset because its PMIC has not been reset to provide adequate voltage for the CPU when coming out of reset at 800Mhz. This uses a new device-tree property 'fsl,ext-reset-output' to indicate the board has such a reset and to cause the watchdog to be configured to assert WDOG_B instead of an internal reset both on a watchdog timeout and in system_restart. [1] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-March/333689.html Cc: Fabio Estevam <festevam@gmail.com> Cc: Lucas Stach <l.stach@pengutronix.de> Cc: Stefan Roese <sr@denx.de> Cc: Iain Paton <ipaton0@gmail.com> Cc: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tim Harvey <tharvey@gateworks.com> Reviewed-by: Lucas Stach <l.stach@pengutronix.de> Acked-by: Shawn Guo <shawn.guo@linaro.org> Tested-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> .../devicetree/bindings/watchdog/fsl-imx-wdt.txt | 4 +++- drivers/watchdog/imx2_wdt.c | 19 +++++++++++++++++-- 2 files changed, 20 insertions(+), 3 deletions(-) commit ebbf677a3fb54fda56c58fc985c4617c215da6a0 Author: Richard Cochran <rcochran@linutronix.de> Date: Fri Mar 18 22:26:08 2016 +0100 watchdog: octeon: Handle the FROZEN hot plug notifier actions. When performing a suspend operation, the kernel brings all of the non-boot CPUs offline, calling the hot plug notifiers with the flag, CPU_TASKS_FROZEN, set in the action code. Similarly, during resume, the CPUs are brought back online, but again the notifiers have the FROZEN flag set. While some very few drivers really need to treat suspend/resume specially, this driver unintentionally ignores the notifications. This patch changes the driver to disable the watchdog interrupt whenever the CPU goes offline, and to enable it whenever the CPU goes back online. As a result, the suspended state is no longer a special case that leaves the watchdog active. Signed-off-by: Richard Cochran <rcochran@linutronix.de> Cc: linux-watchdog@vger.kernel.org Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/octeon-wdt-main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1c306f7f62a38ee5f05f0ee994dfe82d654cf47c Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 5 16:18:02 2016 +0300 i40e: fix an uninitialized variable bug We removed this initialization but it is required. Let's put it back. Fixes: 895106a577c4 ('i40e: trivial fixes') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_hmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c74dff1aaaf2ee51368a0cbf2f903cc3d8690abc Author: Bimmy Pujari <bimmy.pujari@intel.com> Date: Tue May 3 15:13:20 2016 -0700 i40e: Bump version from 1.5.10 to 1.5.16 Signed-off-by: Bimmy Pujari <bimmy.pujari@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d96a83def2f70ea7b26268efdd44eb9f1e400171 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue May 3 15:13:19 2016 -0700 i40e: don't add broadcast filter for VFs Now that all VSIs are configured to receive broadcasts as default, we don't need to add a filter. This eliminates an annoying but harmless error message each time VFs are created or reset. Change-ID: I4cd6339684df45b0d2722133eeb84c14fa93ea19 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 8 -------- 1 file changed, 8 deletions(-) commit b6ef36d2c1e391adc1fe1b2dd2a0f887a9f3052b Author: Guenter Roeck <groeck@chromium.org> Date: Mon Apr 4 17:37:46 2016 -0700 watchdog: qcom: Report reboot reason The Qualcom watchdog timer block reports if the system was reset by the watchdog. Pass the information to user space. Reviewed-by: Grant Grundler <grundler@chromium.org> Tested-by: Grant Grundler <grundler@chromium.org> Signed-off-by: Guenter Roeck <groeck@chromium.org> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> drivers/watchdog/qcom-wdt.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit a876c3ba59a69a1d4ba240ee7cb50acf31116647 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue May 3 15:13:18 2016 -0700 i40e/i40evf: properly report Rx packet hash This logic is inverted. If the RXHASH flag is set, then we should go ahead and call skb_set_hash. Change-ID: Ib2e30356dced1d3e939c8061ab6ad5bd94197e7c Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4b28cdba4859c2d1eb77144fe2383afb8daea1ca Author: Ashish Shah <ashish.n.shah@intel.com> Date: Tue May 3 15:13:17 2016 -0700 i40e: set context to use VSI RSS LUT for SR-IOV For the SR-IOV VSIs, when the queue filtering section is valid, the RSS LUT needs to be set to use the VSI specific lookup table (otherwise it will use the PF RSS LUT table). Change-ID: Ia9377cc818078238a75c3bdeade1b593a91b3480 Signed-off-by: Ashish Shah <ashish.n.shah@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 73df8c9e3e3d1d5d38d48ba4bfb0f709f68c8e13 Author: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Date: Tue May 3 15:13:16 2016 -0700 i40e: Correct UDP packet header for non_tunnel-ipv6 This patch corrects Rx ptype payload layer for non_tunneled ipv6. It should be layer 4 for UDP, instead of layer 3. Change-ID: I9382e4458ab3c4e58f6d2e9f195d5d4ee513805e Signed-off-by: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c420815d12b744ad8cf9312af13af794bad48216 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Tue May 3 15:13:15 2016 -0700 i40e: change Rx hang message into a WARN_ONCE Use WARN_ONCE in order to highlight the issue, but don't display a warning every time. The user should be able to see the ethtool counter we created if necessary to see how often it is occurring. Change-ID: I40c4ea159819b64a7d33b7f5716749089791533a Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ptp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 06566e5dd4e53f57fc3daa12fb8b5252772d70de Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Tue May 3 15:13:14 2016 -0700 i40e: Refactor ethtool get_settings Previously we were only looking at the FW supported PHY types if link was down, because we want to be more specific when link is up. This refactor changes this. When link is down, we still rely on the FW supported PHY types, but when link is up, we select the possible supported link modes from what we know about the current PHY type, and AND that with the FW supported PHY types. Change-ID: Ice5dad83f2a17932b0b8b59f07439696ad6aa013 Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 258 +++++++++++++------------ 1 file changed, 135 insertions(+), 123 deletions(-) commit 42d236f8a4479fefb69b20da3962a462e05a112d Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun May 1 00:25:28 2016 -0400 dmaengine: qcom_hidma: add support for object hierarchy In order to create a relationship model between the channels and the management object, we are adding support for object hierarchy to the drivers. This patch simplifies the userspace application development. We will not have to traverse different firmware paths based on device tree or ACPI based kernels. No matter what flavor of kernel is used, objects will be represented as platform devices. The new layout is as follows: hidmam_10: hidma-mgmt@0x5A000000 { compatible = "qcom,hidma-mgmt-1.0"; ... hidma_10: hidma@0x5a010000 { compatible = "qcom,hidma-1.0"; ... } } The hidma_mgmt_init detects each instance of the hidma-mgmt-1.0 objects in device tree and calls into the channel driver to create platform devices for each child of the management object. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/ABI/testing/sysfs-platform-hidma | 9 ++ drivers/dma/qcom/hidma.c | 39 ++++++++- drivers/dma/qcom/hidma_mgmt.c | 113 ++++++++++++++++++++++++- 3 files changed, 156 insertions(+), 5 deletions(-) commit 570d0176296f0d17c4b5ab206ad4a4bc027b863b Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun May 1 00:25:27 2016 -0400 dmaengine: qcom_hidma: add debugfs hooks Add debugfs hooks for debugging the execution behavior of the DMA channel. The debugfs hooks get initialized by the probe function and uninitialized by the remove function. A stats file is created in debugfs. The stats file will show the information about each HIDMA channel as well as each asynchronous job queued and completed at a given time. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/Makefile | 2 +- drivers/dma/qcom/hidma.c | 5 +- drivers/dma/qcom/hidma.h | 2 + drivers/dma/qcom/hidma_dbg.c | 217 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 224 insertions(+), 2 deletions(-) commit d1615ca2e085222025118793b7b4af2cf4867b6e Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun May 1 00:25:26 2016 -0400 dmaengine: qcom_hidma: implement lower level hardware interface This patch implements the hardware hooks for the HIDMA channel driver. The main functions of interest are: - hidma_ll_init - hidma_ll_request - hidma_ll_queue_request - hidma_ll_hw_start OS layer calls the hidma_ll_init function during probe to set up the hardware. At this moment, the number of supported descriptors are also given. On each request, a descriptor is allocated from the free pool and filled in with the transfer parameters. Multiple requests can be queued into the hardware via the OS interface. When client is ready for requests to be executed, start method is called. Completions are delivered via callbacks via tasklet. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/Makefile | 2 + drivers/dma/qcom/hidma.c | 8 +- drivers/dma/qcom/hidma.h | 38 +- drivers/dma/qcom/hidma_ll.c | 872 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 895 insertions(+), 25 deletions(-) commit eee4172abcdcc610e40eb9513d19ff16c7820270 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue May 3 15:13:13 2016 -0700 i40e: lie to the VF If an untrusted VF attempts to configure promiscuous mode, log a message pointing out its naughty behavior. But then, instead of returning an error to the offender, just lie to it and say everything's OK. It will continue on its way, thinking it's in promiscuous mode, but receiving no packets except its own. Change-ID: I63369215b1720f3c531eedfc06af86ff8c0e3dc8 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit b5569892309e2e62641076f43aef6919286343b4 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Tue May 3 15:13:12 2016 -0700 i40e: Add vf-true-promisc-support priv flag This patch adds priv-flag knob to configure global true promisc support. With this patch the user can decide the flavor of promiscuous that the VFs will see when promiscuous mode is enabled on the interface. Since this a global setting for the whole device, the priv-flag is exposed only on the first PF of the device. The default is true promisc support is off, which means the promisc mode for the VF will be limited/defport mode. For the PF, we still will be in limited promisc unless in MFP mode irrespective of the flavor picked through this knob. Usage: On PF0 ethtool --show-priv-flags p261p1 Private flags for p261p1: MFP : off LinkPolling : off flow-director-atr : on veb-stats : off hw-atr-eviction : off vf-true-promisc-support: off to enable setting true promisc ethtool --set-priv-flags p261p1 vf-true-promisc-support on At this point if the VF is set to trust and promisc is enabled on the VF through ip link set ... promisc on The VF/VFs will be able to see ALL ingress traffic Change-Id: I8fac4b6eb1af9ca77b5376b79c50bdce5055bd94 Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 12 ++-- drivers/net/ethernet/intel/i40e/i40e_common.c | 9 ++- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 72 +++++++++++++++++++--- drivers/net/ethernet/intel/i40e/i40e_main.c | 30 ++++++++- drivers/net/ethernet/intel/i40e/i40e_prototype.h | 3 +- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 3 +- 6 files changed, 111 insertions(+), 18 deletions(-) commit f3d5849756f0da14edabb1835e35aea8b6bc7440 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Tue May 3 15:13:11 2016 -0700 i40e: Implement the API function for aq_set_switch_config Add the support code for calling the AdminQ API call aq_set_switch_config Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 29 ++++++++++++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_prototype.h | 4 ++++ 2 files changed, 33 insertions(+) commit f42a5c74da9996d602093d7760f6916444009a9d Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Tue May 3 15:13:10 2016 -0700 i40e: Add allmulti support for the VF This patch enables a feature to enable/disable all multicast for a trusted VF. Change-Id: I926eba7f8850c8d40f8ad7e08bbe4056bbd3985f Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf.h | 3 +++ drivers/net/ethernet/intel/i40evf/i40evf_main.c | 15 ++++++++++++++- drivers/net/ethernet/intel/i40evf/i40evf_virtchnl.c | 15 +++++++++++++-- 3 files changed, 30 insertions(+), 3 deletions(-) commit 06c0e39bbefd04b19ca50f29be698eeed21630b5 Author: Kevin Scott <kevin.c.scott@intel.com> Date: Tue May 3 15:13:09 2016 -0700 i40e: Add support for disabling all link and change bits needed for PHY interactions Add flag to tell firmware to disable link on all ports. This patch changes the bits set for telling firmware the PHY needs to be modified by driver. Without this patch, the setting will only set that mode for the current port on the device. Because the MDIO interface is common for the copper device. The command needs to set the mode for all ports. Change-ID: I8baa7da91d384291ac95b41ae1a516604f8eb67f Signed-off-by: Kevin Scott <kevin.c.scott@intel.com> Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 4 +++- drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 3 +++ drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) commit 8ea658cea453e3deede3851b58113112ae1dd9cb Merge: ed7cbbc aa524b6 Author: David S. Miller <davem@davemloft.net> Date: Fri May 13 21:08:24 2016 -0400 Merge branch '1GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 1GbE Intel Wired LAN Driver Updates 2016-05-13 This series contains updates to e1000e, igb and igbvf. Steve Shih fixes an issue for disabling auto-negotiation and forcing speed and duplex settings for non-copper media. Brian Walsh cleanups some inconsistency in the use of return variables names to avoid confusion. Jake cleans up the drivers to use the BIT() macro when it can, which will future proof the drivers for GCC 6 when it gets released. Cleaned up dead code which was never being used. Also fixed e1000e, where it was incorrectly restting the SYSTIM registers every time the ioctl was being run. Denys Vlasenko fixes an oversight where incvalue variable holds a 32 bit value so we should declare it as such, instead of 64 bits. Also fixed an overflow check, where two reads are the same, then it is not an overflow. Nathan Sullivan fixes the PTP timestamps for transmit and receive latency based on the current link speed. Alexander Duyck adds support for partial GSO segmentation in the case of tunnels for igb and igbvf. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0651ec932afffce6547efb3e0352e5d229273962 Merge: e9bb8af ba987e5 78c49f8 e3614bc 37aa5c3 cff5a0f Author: Doug Ledford <dledford@redhat.com> Date: Fri May 13 19:40:38 2016 -0400 Merge branches 'cxgb4-2', 'i40iw-2', 'ipoib', 'misc-4.7' and 'mlx5-fcs' into k.o/for-4.7 commit cff5a0f3a3cda0d852425093f92acca169eb5aea Author: Majd Dibbiny <majd@mellanox.com> Date: Sun Apr 17 17:19:38 2016 +0300 IB/mlx5: Report Scatter FCS device capability when supported Report Scatter FCS support when the Firmware supports as well. Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx5/main.c | 4 ++++ 1 file changed, 4 insertions(+) commit 358e42ea66e26d30a7a3e2c967c78f01ec31fe4f Author: Majd Dibbiny <majd@mellanox.com> Date: Sun Apr 17 17:19:37 2016 +0300 IB/mlx5: Add Scatter FCS support for Raw Packet QP Enable Scatter FCS in the RQ context when the user passes Scatter FCS create flag. Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx5/mlx5_ib.h | 1 + drivers/infiniband/hw/mlx5/qp.c | 20 +++++++++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) commit b531b909481933f78493e4d2fcda25c606acf120 Author: Majd Dibbiny <majd@mellanox.com> Date: Sun Apr 17 17:19:36 2016 +0300 IB/core: Add Scatter FCS create flag Raw Packet QPs that were created with Scatter FCS flag, will scatter the FCS into the receive buffers. Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/uverbs_cmd.c | 3 ++- include/rdma/ib_verbs.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) commit 45686f2d6535525a9875e4a77a35da013814de82 Author: Majd Dibbiny <majd@mellanox.com> Date: Sun Apr 17 17:19:35 2016 +0300 IB/core: Add Raw Scatter FCS device capability Raw Scatter FCS device capability is set when the NIC supports scattering the FCS to the receive buffers of Raw Packet QPs. Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/rdma/ib_verbs.h | 1 + 1 file changed, 1 insertion(+) commit 0b24e5ac93c2d0792ba8604e9f64e0b564d5f23e Author: Majd Dibbiny <majd@mellanox.com> Date: Sun Apr 17 17:19:34 2016 +0300 IB/core: Add extended device capability flags Since all the uverbs device_cap_flags are occupied, we need a place to expose more device capabilities. This patch adds a new 64 bit device_cap_flags_ex to expose new device capabilities. The lower 32 bits will be identical to the original device_cap_flags, The upper 32 bits will be new capabilities. Signed-off-by: Majd Dibbiny <majd@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/uverbs_cmd.c | 5 +++++ include/uapi/rdma/ib_user_verbs.h | 1 + 2 files changed, 6 insertions(+) commit 73fbb4db6cf3682f12b68a64040897fe226fd409 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 12:14:46 2016 +0100 i40iw: pass hw_stats by reference rather than by value passing hw_stats by value requires a 280 byte copy so instead pass it by reference is much more efficient. Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Chien Tin Tung <chien.tin.tung@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d42ed55aaf0e9040b063189b72928279848c0a1b Author: Lars-Peter Clausen <lars@metafoo.de> Date: Mon Mar 28 11:31:26 2016 +0200 i40iw: Remove unnecessary synchronize_irq() before free_irq() Calling synchronize_irq() right before free_irq() is quite useless. On one hand the IRQ can easily fire again before free_irq() is entered, on the other hand free_irq() itself calls synchronize_irq() internally (in a race condition free way), before any state associated with the IRQ is freed. Patch was generated using the following semantic patch: // <smpl> @@ expression irq; @@ -synchronize_irq(irq); free_irq(irq, ...); // </smpl> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Acked-by: Faisal Latif <faisal.latif#intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 1 - 1 file changed, 1 deletion(-) commit fb997816fdf3475fd9bd9a76b6b77aba03864835 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 14:22:21 2016 +0200 i40iw: constify i40iw_vf_cqp_ops structure The i40iw_vf_cqp_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_type.h | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 37aa5c36aa70c9fc5f633b89cce990f04aaa3cd4 Author: Guy Levi <guyle@mellanox.com> Date: Wed Apr 27 16:49:50 2016 +0300 IB/mlx5: Add UARs write-combining and non-cached mapping By this patch, the user space library will be able to improve performance using appropriate ringing DoorBell method according to the memory type it asked for. Currently only one mapping command is allowed for UARs: MLX5_IB_MMAP_REGULAR_PAGE. Using this mapping, the kernel maps the UARs to write-combining (WC) if the system supports it. If the system is not supporting WC the UARs are mapped to non-cached(NC). In this case the user space library can't tell which mapping is applied. This patch adds 2 new mapping commands: MLX5_IB_MMAP_WC_PAGE and MLX5_IB_MMAP_NC_PAGE. For these commands the kernel maps exactly as requested and fails if it can't. Since there is no generic way to check if the requested memory region can be mapped as WC, driver enables conclusive WC mapping only for x86, PowerPC and ARM which support WC for the device's memory region. Signed-off-by: Guy Levy <guyle@mellanox.com> Signed-off-by: Moshe Lazer <moshel@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx5/main.c | 96 ++++++++++++++++++++++++++++-------- drivers/infiniband/hw/mlx5/mlx5_ib.h | 2 + 2 files changed, 77 insertions(+), 21 deletions(-) commit 6cbac1e4cd0e0110b4be38c201fc055249dfd365 Author: Matan Barak <matanb@mellanox.com> Date: Thu Apr 14 16:52:10 2016 +0300 IB/mlx5: Allow mapping the free running counter on PROT_EXEC The current mlx5 code disallows mapping the free running counter of mlx5 based hardwares when PROT_EXEC is set. Although this behaviour is correct, Linux does add an implicit VM_EXEC to the vm_flags if the READ_IMPLIES_EXEC bit is set in the process personality. This happens for example if the process stack is executable. This causes libmlx5 to output a warning and prevents the user from reading the free running clock. Executing the init segment of the hardware isn't a security risk (at least no more than executing a process own stack), so we just prevent writes to there. Fixes: d69e3bcf7976 ('IB/mlx5: Mmap the HCA's core clock register to user-space') Signed-off-by: Matan Barak <matanb@mellanox.com> Reviewed-by: Haggai Eran <haggaie@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx5/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ee71b9681df6b71b7fa110d42200bec05dfaf19a Author: Geliang Tang <geliangtang@163.com> Date: Mon Dec 7 23:04:43 2015 +0800 IB/mlx4: Use list_for_each_entry_safe Simplify the code in search_relocate_mgid0_group with by using list_for_each_entry_safe(). Signed-off-by: Geliang Tang <geliangtang@163.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx4/mcg.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 0f377d86252d11bfea941852785e3094b93601a7 Author: Mark Bloch <markb@mellanox.com> Date: Fri May 6 22:45:27 2016 +0300 IB/SA: Use correct free function Fixes a direct call to kfree_skb when nlmsg_free should be used. Fixes: 2ca546b92a02 ('IB/sa: Route SA pathrecord query through netlink') Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Reviewed-by: Ira Weiny <ira.weiny@intel.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/sa_query.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2fa2d4fb1166d1ef35f0aacac6165d53ab1b89c7 Author: Mark Bloch <markb@mellanox.com> Date: Fri May 6 22:45:26 2016 +0300 IB/core: Fix a potential array overrun in CMA and SA agent Fix array overrun when going over callback table. In declaration of callback table, the max size isn't provided and in registration phase, it is provided. There is potential scenario where a new operation is added and it is not supported by current client. The acceptance of such operation by ib_netlink will cause to array overrun. Fixes: 809d5fc9bf65 ("infiniband: pass rdma_cm module to netlink_dump_start") Fixes: b493d91d333e ("iwcm: common code for port mapper") Fixes: 2ca546b92a02 ("IB/sa: Route SA pathrecord query through netlink") Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/cma.c | 3 ++- drivers/infiniband/core/iwcm.c | 2 +- drivers/infiniband/core/sa_query.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) commit 1ae5ccc78105490cd1f73bdf4847e7c6d03f0aa1 Author: Mark Bloch <markb@mellanox.com> Date: Fri May 6 22:45:25 2016 +0300 IB/core: Remove unnecessary check in ibnl_rcv_msg RDMA_NL_GET_OP is defined like this: (type & ((1 << 10) - 1)) which means op (defined as an int) can never be a negative number. Fixes: b2cbae2c2487 ('RDMA: Add netlink infrastructure') Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/netlink.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 5ed935e861a4cbf2158ad3386d6d26edd60d2658 Author: Mark Bloch <markb@mellanox.com> Date: Fri May 6 22:45:24 2016 +0300 IB/IWPM: Fix a potential skb leak In case ibnl_put_msg fails in send_nlmsg_done, the function returns with -ENOMEM without freeing. This patch fixes this behavior. Fixes: 30dc5e63d6a5 ("RDMA/core: Add support for iWARP Port Mapper user space service") Signed-off-by: Mark Bloch <markb@mellanox.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Leon Romanovsky <leon@kernel.org> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/iwpm_util.c | 1 + 1 file changed, 1 insertion(+) commit faca88273b68b71a15749e04037a4d7ee98fff2d Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 6 20:19:42 2016 +0300 RDMA/nes: replace custom print_hex_dump() There is no need to duplicate a lot of code that is in the kernel library for ages. Replace duplicating code by calling to print_hex_dump() directly. Note that output is slightly changed: - hex and ascii parts have just two spaces delimeter - there is no delimeter for ascii portions - file and line removed from prefix (they were redundant anyway since previous output shows same closer enough) Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/nes/nes_utils.c | 60 ++--------------------------------- 1 file changed, 3 insertions(+), 57 deletions(-) commit aa70345369e251779c0372ef6dd2bd6325a3350c Author: Colin Ian King <colin.king@canonical.com> Date: Mon Apr 25 20:26:50 2016 +0100 IB/mlx4: trivial fix of spelling mistake on "argument" fix spelling mistake, argumant -> argument Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/mlx4/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit da74bf4aea3d9ec6cf653ad0014c13e9680f3903 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Fri Apr 8 20:58:42 2016 +0200 IB/nes: Deinline nes_free_qp_mem, save 1072 bytes This function compiles to 550 bytes of machine code. Three callsites, all in nes_create_qp. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: Faisal Latif <faisal.latif@intel.com> CC: Doug Ledford <dledford@redhat.com> CC: linux-rdma@vger.kernel.org CC: linux-kernel@vger.kernel.org Reviewed-By: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/nes/nes_verbs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1997412db64bae810edd9ef77d62aefccf965e80 Author: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Date: Tue Mar 29 12:58:37 2016 -0500 RDMA/nes: Adding queue drain functions Adding sq and rq drain functions, which block until all previously posted wr-s in the specified queue have completed. A completion object is signaled to unblock the thread, when the last cqe for the corresponding queue is processed. Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/nes/nes_verbs.c | 34 ++++++++++++++++++++++++++++++++++ drivers/infiniband/hw/nes/nes_verbs.h | 2 ++ 2 files changed, 36 insertions(+) commit 825107a237bd0a1589e5af3853a14ba61bef02ef Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Tue Apr 12 14:43:41 2016 -0700 iwcm: Fix a sparse warning Avoid that sparse complains about the comparison of s_addr with INADDR_ANY. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Steve Wise <swise@opengridcomputing.com> Cc: Faisal Latif <faisal.latif@intel.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/iwcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 54f5c9c52d69afa55abf2b034df8d45f588466c3 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Tue Apr 12 14:39:18 2016 -0700 IB/srp: Fix a debug kernel crash Avoid that the following BUG() is triggered against a debug kernel: kernel BUG at include/linux/scatterlist.h:92! RIP: 0010:[<ffffffffa0467199>] [<ffffffffa0467199>] srp_map_idb+0x199/0x1a0 [ib_srp] Call Trace: [<ffffffffa04685fa>] srp_map_data+0x84a/0x890 [ib_srp] [<ffffffffa0469674>] srp_queuecommand+0x1e4/0x610 [ib_srp] [<ffffffff813f5a5e>] scsi_dispatch_cmd+0x9e/0x180 [<ffffffff813f8b07>] scsi_request_fn+0x477/0x610 [<ffffffff81298ffe>] __blk_run_queue+0x2e/0x40 [<ffffffff81299070>] blk_delay_work+0x20/0x30 [<ffffffff81071f07>] process_one_work+0x197/0x480 [<ffffffff81072239>] worker_thread+0x49/0x490 [<ffffffff810787ea>] kthread+0xea/0x100 [<ffffffff8159b632>] ret_from_fork+0x22/0x40 Fixes: f7f7aab1a5c0 ("IB/srp: Convert to new registration API") Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Christoph Hellwig <hch@lst.de> Cc: <stable@vger.kernel.org> # v4.4+ Reviewed-by: Max Gurtovoy <maxg@mellanox.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e3614bc9dc448c3395adf311098dfc64abcc5a35 Author: Hans Westgaard Ry <hans.westgaard.ry@oracle.com> Date: Thu Apr 21 13:13:21 2016 +0200 IB/ipoib: Add readout of statistics using ethtool IPoIB collects statistics of traffic including number of packets sent/received, number of bytes transferred, and certain errors. This patch makes these statistics available to be queried by ethtool. Signed-off-by: Hans Westgaard Ry <hans.westgaard.ry@oracle.com> Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com> Reviewed-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Tested-by: Yuval Shaia <yuval.shaia@oracle.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 67 ++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) commit 01690e9c70c0b42072d6c82470d78b747fcc5c70 Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Date: Wed May 11 12:04:09 2016 +0200 infiniband/ulp/ipoib: remove pkey_mutex The last user of pkey_mutex was removed in db84f8803759 ("IB/ipoib: Use P_Key change event instead of P_Key polling mechanism") but the lock remained. This patch removes it. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/ipoib/ipoib_ib.c | 2 -- 1 file changed, 2 deletions(-) commit 78c49f83ee282dd08fd264fecb90f4f9e2f21a6d Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 12:14:46 2016 +0100 i40iw: pass hw_stats by reference rather than by value passing hw_stats by value requires a 280 byte copy so instead pass it by reference is much more efficient. Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Chien Tin Tung <chien.tin.tung@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6d6c5c1eb39badb85be1df9b1d6aa5b345dac75f Author: Lars-Peter Clausen <lars@metafoo.de> Date: Mon Mar 28 11:31:26 2016 +0200 i40iw: Remove unnecessary synchronize_irq() before free_irq() Calling synchronize_irq() right before free_irq() is quite useless. On one hand the IRQ can easily fire again before free_irq() is entered, on the other hand free_irq() itself calls synchronize_irq() internally (in a race condition free way), before any state associated with the IRQ is freed. Patch was generated using the following semantic patch: // <smpl> @@ expression irq; @@ -synchronize_irq(irq); free_irq(irq, ...); // </smpl> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Acked-by: Faisal Latif <faisal.latif#intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 1 - 1 file changed, 1 deletion(-) commit 2016de7ba013462d56fb344a5a8ed93f7a4c460a Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 14:22:21 2016 +0200 i40iw: constify i40iw_vf_cqp_ops structure The i40iw_vf_cqp_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_type.h | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit eea570788ebeb817a5ecb173dafc316779120081 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Sun May 1 18:05:31 2016 +0530 staging/rdma/hfi1: use RCU_INIT_POINTER() when NULLing. It is safe to use RCU_INIT_POINTER() to NULL a pointer, instead of rcu_assign_pointer(). This results in slightly smaller/faster code. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3923979e9bc6aa6f168a644314d6729e9f98eccc Author: Ashutosh Dixit <ashutosh.dixit@intel.com> Date: Thu May 12 10:24:00 2016 -0700 IB/hfi1: Change hfi1_init loop to preserve error returns If one iteration of the loop causes an error return and a later iteration doesn't, the later iteration causes the earlier error condition to be lost. This could result in driver probe succeeding when it should have failed. Therefore save off the error return in the loop itself rather than outside the loop. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/init.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit bf77cc34f3e6905bc8841489dd628bbffe37d743 Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Thu May 12 10:23:53 2016 -0700 ib_pack.h: Add opcode definition for send with invalidate The opcode for "SEND Last with Invalidate" and "SEND Only with Invalidate" have been defined for RC in IBA Specification Vol 1 since Release 1.2. Add the definition to the header file in preparation of supporting these opcodes in rdmavt based drivers. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/rdma/ib_pack.h | 5 +++++ 1 file changed, 5 insertions(+) commit 859b527f00ad1364a4152c0365e2e5ef5a6bf20a Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Thu May 12 10:23:47 2016 -0700 IB/hfi1: Keep SC_USER as the last send context type SC_USER needs to be the last send context type to ensure other send context types get their allocation when num_user_contexts is set to a large number. This fixes a panic when the module parameter num_user_contexts is set to 141 and larger. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/pio.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit f036780be8ac7abee912bd1eeb459230e6bcc878 Author: Dean Luick <dean.luick@intel.com> Date: Thu May 12 10:23:41 2016 -0700 IB/hfi1: Immediately apply congestion setting MAD The handling of the congestion setting MAD packet only saved off the values, waiting for a congestion control table packet before going active. Instead, immediately apply the values. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mad.c | 93 ++++++++++++++++++++++++++--------------- 1 file changed, 60 insertions(+), 33 deletions(-) commit cde10afa6c8d0db75a3dc038ec46ae901c51cfab Author: Jakub Pawlak <jakub.pawlak@intel.com> Date: Thu May 12 10:23:35 2016 -0700 IB/hfi1: Correct log message strings Remove "IB" keyword from log messages. Correct comment for thermal sensor init function. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Jakub Pawlak <jakub.pawlak@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 2 +- drivers/staging/rdma/hfi1/driver.c | 2 +- drivers/staging/rdma/hfi1/hfi.h | 5 ++--- drivers/staging/rdma/hfi1/sysfs.c | 4 ++-- 4 files changed, 6 insertions(+), 7 deletions(-) commit cdbff5042d69bbe3f9840bea03863c93f93c88fa Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Thu May 12 10:23:28 2016 -0700 IB/rdmavt: Increase CQ callback thread priority The priority of the send engines is higher than the CQ completion thread potentially causing completions to be starved for very fast interfaces. Change the CQ kthread to match the send engine threads to minimize this delay for ULP completion processing. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/sw/rdmavt/cq.c | 1 + 1 file changed, 1 insertion(+) commit 02ba00c0bbfbbe8abd81abd38302d400b59e220f Author: Jubin John <jubin.john@intel.com> Date: Thu May 12 10:23:22 2016 -0700 IB/hfi1: Fix hfi_rcvhdr tracepoint The hfi_rcvhdr tracepoint has the ctxt and eflags switched in the prototype of the trace event, compared to the args and usage of the trace function. Fix this by swapping these 2 fields in the trace event prototype. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/trace.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 63d0b4a5fc5f589c6e980fc5d43c220e74a6f06c Author: Jubin John <jubin.john@intel.com> Date: Thu May 12 10:23:16 2016 -0700 IB/hfi1: Remove unnecessary header While running perftests, there is a significant utilization of the random number daemon. This is due to the linux/random.h header being included in qp.c and verbs.c. However, none of the functions from this header are being used in these files, so remove the unnecessary header. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/qp.c | 1 - drivers/staging/rdma/hfi1/verbs.c | 1 - 2 files changed, 2 deletions(-) commit 67caea1fec85266590dddfa431e1cb000bc942f4 Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Thu May 12 10:23:09 2016 -0700 IB/hfi1: Improve performance of interval RB trees The interval RB tree management functions use handlers to store user-specific callback for the various tree operations. These handlers are put on a doubly-linked list. When a RB tree function is called, the list is searched for the handler of the particular tree. The list which holds the handlers is modified very rarely - when a handler is created and when a handler is removed. On the other hand, it is searched very often. This a perfect usage scenario for RCU. The result is a much lower overhead of traversing the list as most of the time no locking will be required. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mmu_rb.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit b96b040445f5d84fb8aa2ff986be71f5069c976e Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Thu May 12 10:23:03 2016 -0700 IB/hfi1: Fix potential panic with sdma drained mechanism The guard is backwards, potentially causing the SDMA client to panic if a wait structure was not specified. psm and verbs are not exposed to the issue, but fix the code just to be correct. Fixes: a545f5308b6c ("staging/rdma/hfi: fix CQ completion order issue") Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/sdma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 17f15bf66884b9e33c5005ee0149b039af8f7af2 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Thu May 12 10:22:57 2016 -0700 IB/hfi1: Fix pio wait counter double increment The code unconditionlly increments the pio wait counter making the counter inacurate and unusable. Fixes: 14553ca11039 ("staging/rdma/hfi1: Adaptive PIO for short messages") Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/verbs.c | 1 - 1 file changed, 1 deletion(-) commit 1ebe79c9484bb1b9bd51b3dd6e82b8ff87ebaeba Author: Dean Luick <dean.luick@intel.com> Date: Thu May 12 10:22:51 2016 -0700 IB/hfi1: Remove no-op QSFP reset code The RESET_N bit of the ASIC_QSFPn_OE register is not used by the hardware. Remove code that tries to use it - it does nothing. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 3 --- 1 file changed, 3 deletions(-) commit 27a340f6b206dd2a0208d3bc4605c0708b55d7b4 Author: Easwar Hariharan <easwar.hariharan@intel.com> Date: Thu May 12 10:22:45 2016 -0700 IB/hfi1: Correct external device configuration shift The external device configuration was incorrectly shifted to byte 3 of the 32 bit DC_HOST_COMM_SETTINGS instead of byte 0. This patch corrects the shift and provides the cable capability information in byte 0. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/platform.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9775a991f9bdbdde3cc38e553326755af5b2b2a9 Author: Easwar Hariharan <easwar.hariharan@intel.com> Date: Thu May 12 10:22:39 2016 -0700 IB/hfi1: Wait for QSFP modules to initialize The function level reset in init_chip() and subsequent write of all 1s to the ASIC_QSFP registers effectively resets attached active and optical QSFP modules that pay attention to the RESET_N pin. We subsequently try to access the QSFP management interface to qualify and tune the channel and fabric SerDes before enough time (2 seconds per SFF 8679 spec for QSFP28 modules) has elapsed for the module to finish initialization. This fails and causes the failure of the channel tuning algorithm, preventing us from bringing the link up. This patch checks the port type prior to beginning channel and SerDes tuning, and if found to be QSFP, watches for the QSFP initialization complete interrupt, with a maximum timeout of 2 seconds, to allow the initialization to complete. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 10 +++++++++- drivers/staging/rdma/hfi1/platform.c | 17 +++++++++++------ drivers/staging/rdma/hfi1/platform.h | 1 + 3 files changed, 21 insertions(+), 7 deletions(-) commit 0c7f77afb7f6e74af899584ac672c8d9e63058b0 Author: Easwar Hariharan <easwar.hariharan@intel.com> Date: Thu May 12 10:22:33 2016 -0700 IB/hfi1: Ignore non-temperature warnings on a downed link QSFP modules can raise an interrupt to inform us of expected conditions while the link is down, such as RX power low. Actively ignore these conditions when the link is down as they only add reporting noise. Continue reporting conditions that are valid at all times, such as temperature alarms and warnings. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 17 +++++++++++------ drivers/staging/rdma/hfi1/diag.c | 2 +- drivers/staging/rdma/hfi1/hfi.h | 1 + 3 files changed, 13 insertions(+), 7 deletions(-) commit ba987e51a63713669ce6bdbe9b120d72e59eec8e Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Tue Apr 12 14:45:24 2016 -0700 iw_cxgb4: Convert a __force cast __force casts should be avoided if there is a better alternative. Hence modify the comparison of s_addr with INADDR_ANY such that the __force cast is no longer necessary. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Steve Wise <swise@opengridcomputing.com> Cc: Vipul Pandya <vipul@chelsio.com> Acked-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 64bec74a9b3ccc0e9795161427ea49864462f612 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:10 2016 +0530 RDMA/iw_cxgb4: Add arp failure handlers to send_mpa_reply/reject() These handlers when called print error message to the kernel log, but the actual handling is done by _c4iw_free_ep() and process_timeout(). Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 093108cb3640844cfdabb0f506fa6b592b64272d Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:09 2016 +0530 RDMA/iw_cxgb4: Always wake up waiter in c4iw_peer_abort_intr() Currently c4iw_peer_abort_intr() does not wake up the waiter if the endpoint state indicates we're using MPAv2 and we're currently trying to connect. This was introduced with commit 7c0a33d61187a ("RDMA/cxgb4: Don't wakeup threads for MPAv2") However, this original fix is flawed because it introduces a race that can cause a deadlock of the iwarp stack. Here is the race: ->local side sets up an active offload connection. ->local side sends MPA_START request. ->peer sends MPA_START response. ->local side ingress cpl thread begins processing the MPA_START response, but before it changes the state from MPA_REQ_SENT to FPDU_MODE: ->peer sends a RST which results in a ABORT_REQ_RSS. This triggers peer_abort_intr() which sees the state in MPA_REQ_SENT and since mpa_rev is 2, it will avoid waking up the endpoint with -ECONNRESET, assuming the stack will re-attempt the connection using MPAv1. ->Meanwhile, the cpl thread moves the state to FPDU_MODE and calls c4iw_modify_rc_qp() which calls rdma_init() which sends a RI_WR/INIT WR to firmware. But since HW sent an abort, FW correctly drops the RI_WR/INIT WR. ->So the cpl thread is stuck waiting for a reply and cannot process the ABORT_REQ_RSS cpl sitting in its input queue. Thus everything comes to a halt because no more ingress cpls are processed by the stack... The correct fix for the issue is to always do the wake up in c4iw_abort_intr() but reinitialize the wait object in c4iw_reconnect(). Fixes: 7c0a33d61187a ("RDMA/cxgb4: Don't wakeup threads for MPAv2") Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 4a4dd8db9dc15579edc62631326f37c43fda0942 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:08 2016 +0530 RDMA/iw_cxgb4: Handle ret value of process_mpa_reply() in rx_data Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f86fac79afecb41682886785364b15cb13f22280 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:07 2016 +0530 RDMA/iw_cxgb4: atomic find and reference for listening endpoints Add get_ep_from_stid() which will atomically find and reference the endpoint struct if found. This avoids touch-after-free races between threads destroying listening endpoints and the CPL processing thread processing an incoming PASS_ACCEPT_REQ CPL. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) commit e8667a9b35c550e3daf4519058a52252bf41d9db Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:06 2016 +0530 RDMA/iw_cxgb4: Handle ULP accept/reject during ABORTING c4iw_reject() and c4iw_accept() need to handle the case where the endpoint has timed out and is in the middle of ABORTING the connection. Here is the flow that causes the BUG_ON() to fire on the server side: 1) offload connection setup and endpoint timer started 2) MPA_START request received from peer, CONNECT_REQUEST passed to ULP 3) endpoint timer fires, and process_timeout() aborts the connection, this moves the endpoint state to ABORTING until HW sends up the ABORT_RPL_RSS. 4) application exits closing the CONNECT_REQUEST cm_id. The IWCM calls c4iw_reject_cr() to destroy this connection request. 5) WHAMO: BUG_ON() because the state is ABORTING. The fix is to change c4iw_reject_cr() and c4iw_accept_cr() to fail the operation if the state is not in MPA_REQ_RCVD vs in DEAD. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit ceb110a8c1518f54913568bf84f84df573db99e4 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:05 2016 +0530 RDMA/iw_cxgb4: Release ep for for FPDU_MODE and MPA_REQ_RCVD in process_timeout ARP failure may also happen when ep in FPDU_MODE and these failures need to be handled by process_timeout(). process_timeout() also has to handle case MPA_REQ_RCVD, setting abort to 1, leading to ep resource release. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 2 ++ 1 file changed, 2 insertions(+) commit c878b706ffcb1f71908491dcadb2ff556fc86d95 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:04 2016 +0530 RDMA/iw_cxgb4: Free skb in case of arp failure in _c4iw_free_ep() Arp failure for send_mpa_reply/reject() is handled by freeing the mpa_skb in c4iw_free_ep() before releasing ep. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 2 ++ 1 file changed, 2 insertions(+) commit 944661dd97f4f257cd914fffec7eb80832ff9141 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:03 2016 +0530 RDMA/iw_cxgb4: atomically lookup ep and get a reference There is a race between ULP threads calling c4iw_ep_disconnect() via c4iw_modify_rc_qp() and the ingress CPL thread where the ULP thread can free the endpoint just after the ingress CPL thread finds the ep pointer in the tid table. To avoid this, we now use the hwtid_idr table for lookups instead of the LLD tid table so we can lock around insert, remove, and lookup+get_ep to avoid the race. The CPL handlers now will either find the ep ptr and have a ref on it, or not find it and they can discard the CPL. Callers of get_ep_from_tid() will have a ref on the ep if found, and thus must deref when they are done. Negative advice in peer_abort_intr() need to dereference the ep. therefore peer_abort() is scheduled to dereference the ep later. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 110 +++++++++++++++++++++++++++++---------- 1 file changed, 82 insertions(+), 28 deletions(-) commit 761e19a504afa55ec0ede0ed490cddb99b2596a5 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:02 2016 +0530 RDMA/iw_cxgb4: Handle return value of c4iw_ofld_send() in abort_arp_failure() In abort_arp_failure(), the return value from c4iw_ofld_send() is ignored and thus if the CPL isn't sent, the endpoint is stuck and never gets aborted. Failure of c4iw_ofld_send() is treated as fatal error, and the ep resources are released in a safer context through process_work(). Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 8a70f812b16ea4523938749a168817ffed232df9 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:01 2016 +0530 RDMA/iw_cxgb4: in process_timeout() don't move ep state to ABORTING Moving the state to ABORTING causes the ep to get stuck because c4iw_ep_timeout() thinks the ABORT has already been done. So leave the state alone and let c4iw_ep_disconnect() do the right thing given the ep state. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 3 --- 1 file changed, 3 deletions(-) commit caa6c9f247d64f7f7c183514d71113f472124f55 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:18:00 2016 +0530 RDMA/iw_cxgb4: handle return value of c4iw_l2t_send() and send_mpa_req() ->In act_open_rpl(), CPL_ERR_TCAM_FULL error handling branch, there is no handling of the return value of send_fw_act_open_req(). ->In send_fw_act_open_req(), there is no handling of return value of c4iw_l2t_send(), which may cause a ep leak and won't notify upper layers on connection establish failure. ->send_mpa_req() should act on the return from c4iw_l2t_send() and return the error to the caller. ->In case of c4iw_l2t_send() failure in send_mpa_req(), returns without starting the timer and not changing the ep state, which is further handled by act_establish() -> In act_establish()?if send_mpa_request's get_skb returns an error, may cause an ep leak. So handle return value of send_mpa_req() Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 35 ++++++++++++++++++++++------------- 1 file changed, 22 insertions(+), 13 deletions(-) commit e4b76a2a2619e95deb1ae2b088c0aa4f24a0bbee Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:59 2016 +0530 RDMA/iw_cxgb4: stop_ep_timer() after MPA negotiation ->Stop the ep timer after MPA negotiation so that the arp failures during send_mpa_reply/reject will be handled by process_timeout() after the ep timer expires. ->Added case MPA_REP_SENT in process_timeout(). ->For MPA reject, c4iw_ep_disconnect tries to start an already started timer, which leads to warning message "timer already started". -> In case of mpa reject stop the timer and call send_mpa_reject(). -> Added new ep flag STOP_MPA_TIMER to tell fw4_ack() to stop the timer only for send_mpa_reply(), which is set in c4iw_accept_cr(). Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 39 +++++++++++++++++----------------- drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 1 + 2 files changed, 20 insertions(+), 20 deletions(-) commit da1cecdffc13494bef012d598ed3dc1ed9572204 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:58 2016 +0530 RDMA/iw_cxgb4: Do not stop timer in case of incomplete messages In case of incomplete mpa messages we should not stop timer as it results in return with timeout for the next mpa message Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) commit 8d1f1a6b3fccfce5d95ee0d6456b1437e93f2bba Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:57 2016 +0530 RDMA/iw_cxgb4: parent_ep has to be dereferenced in case of passive accept failure -> On passive side of connection parent_ep referenced during connection request has to be dereferenced during the passive accept failure. -> As passive accept failure error handlinglogic runs in atomic context, the parent ep is dereferenced by scheduling work request. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) commit 92f850ec3a18d9d8bf2157a8509d435d49ce80b6 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:56 2016 +0530 RDMA/iw_cxgb4: set the correct FID value in DSGL commands The FID value in a ULP_MEMIO command needs to be set to an IQ ID of a queue configured for our PF. The FID/IQ id is used to index into the PCIE FID table, to find out on which function the DMA needs to be issued. Essentially, every DMA needs to have the ingress queue. The exact ingress queue doesn't matter, but it needs to be an ingress queue associated with the function you want to see the DMA on. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/mem.c | 5 +++-- drivers/net/ethernet/chelsio/cxgb4/t4_msg.h | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) commit ccd2c30b4513905a0624a696ec3eeaa3bf93530d Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:55 2016 +0530 RDMA/iw_cxgb4: Correct RFC number of MPA Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9ca6f7cf9c9e2ae9a28618be320d09407c312a46 Author: Hariprasad S <hariprasad@chelsio.com> Date: Fri May 6 22:17:54 2016 +0530 RDMA/iw_cxgb4: Add few history bits for ep - add EP_DISC_FAIL history bit - add QP_REFED/DEREFED history bits - Add functions to ref/deref the cm_id and add history bit for the same - add CLOSE_CON_RPL history Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 46 +++++++++++++++++++++------------- drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 8 +++++- 2 files changed, 36 insertions(+), 18 deletions(-) commit aa524b66c5efd1d3220b74168d803e8b2ee1d212 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 20 11:36:42 2016 -0700 e1000e: don't modify SYSTIM registers during SIOCSHWTSTAMP ioctl The e1000e_config_hwtstamp function was incorrectly resetting the SYSTIM registers every time the ioctl was being run. If you happened to be running ptp4l and lost the PTP connect (removing cable, or blocking the UDP traffic for example), then ptp4l will eventually perform a restart which involves re-requesting timestamp settings. In e1000e this has the unfortunate and incorrect result of resetting SYSTIME to the kernel time. Since kernel time is usually in UTC, and PTP time is in TAI, this results in the leap second being re-applied. Fix this by extracting the SYSTIME reset out into its own function, e1000e_ptp_reset, which we call during reset to restore the hardware registers. This function will (a) restart the timecounter based on the new system time, (b) restore the previous PPB setting, and (c) restore the previous hwtstamp settings. In order to perform (b), I had to modify the adjfreq ptp function pointer to store the old delta each time it is called. This also has the side effect of restoring the correct base timinca register correctly. The driver does not need to explicitly zero the ptp_delta variable since the entire adapter structure comes zero-initialized. Reported-by: Brian Walsh <brian@walsh.ws> Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Brian Walsh <brian@walsh.ws> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/e1000.h | 1 + drivers/net/ethernet/intel/e1000e/netdev.c | 68 +++++++++++++++++++++++------- drivers/net/ethernet/intel/e1000e/ptp.c | 2 + 3 files changed, 55 insertions(+), 16 deletions(-) commit e10715d3e9618901c5ef820a92e6a8e6548b43d3 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 17:19:38 2016 -0400 igb/igbvf: Add support for GSO partial This patch adds support for partial GSO segmentation in the case of tunnels. Specifically with this change the driver an perform segmentation as long as the frame either has IPv6 inner headers, or we are allowed to mangle the IP IDs on the inner header. This is needed because we will not be modifying any fields from the start of the start of the outer transport header to the start of the inner transport header as we are treating them like they are just a block of IP options. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 137 +++++++++++++++------- drivers/net/ethernet/intel/igbvf/netdev.c | 182 ++++++++++++++++++------------ 2 files changed, 203 insertions(+), 116 deletions(-) commit 942c711206d1e0cd3dffc591829cbcbb9bcc0b1b Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:33 2016 -0700 e1000e: mark shifted values as unsigned The E1000_ICH_NVM_SIG_MASK value is shifted, out to the 31st bit, which is the signed bit for signed constants. Mark these values as unsigned to prevent compiler warnings and issues on platforms which a different signed bit implementation. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/ich8lan.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 18dd23920703891c39c7965873f8ae369bd3a237 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:32 2016 -0700 e1000e: use BIT() macro for bit defines This prevents signed bitshift issues when the shift would overwrite the signed bit, and prevents making this mistake in the future when copying and modifying code. Use GENMASK or the unsigned postfix for cases which aren't suitable for BIT() macro. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/80003es2lan.c | 12 +-- drivers/net/ethernet/intel/e1000e/82571.c | 30 +++---- drivers/net/ethernet/intel/e1000e/e1000.h | 108 ++++++++++++------------ drivers/net/ethernet/intel/e1000e/ethtool.c | 45 +++++----- drivers/net/ethernet/intel/e1000e/ich8lan.c | 44 +++++----- drivers/net/ethernet/intel/e1000e/mac.c | 2 +- drivers/net/ethernet/intel/e1000e/netdev.c | 28 +++--- drivers/net/ethernet/intel/e1000e/nvm.c | 2 +- drivers/net/ethernet/intel/e1000e/phy.c | 4 +- drivers/net/ethernet/intel/e1000e/phy.h | 10 +-- 10 files changed, 143 insertions(+), 142 deletions(-) commit 0ed2dbf4f469e2e286d903ebc091edfd9be4d063 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:31 2016 -0700 igbvf: use BIT() macro instead of shifts To prevent signed bitshift issues, and improve code readability, use the BIT() macro. Also make use of GENMASK or the unsigned postfix where this is more appropriate than BIT() Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igbvf/defines.h | 2 +- drivers/net/ethernet/intel/igbvf/ethtool.c | 3 ++- drivers/net/ethernet/intel/igbvf/igbvf.h | 4 ++-- drivers/net/ethernet/intel/igbvf/netdev.c | 10 +++++----- drivers/net/ethernet/intel/igbvf/vf.c | 2 +- 5 files changed, 11 insertions(+), 10 deletions(-) commit 12b28b41084aa61970fecb417c66c88dcce6afed Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:30 2016 -0700 igbvf: remove unused variable and dead code The variable rdlen is set but never used, and thus setting it is dead code. Remove it. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igbvf/netdev.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 3f544d2a4d5c2d817cfee9e6302fc2909aaef155 Author: Nathan Sullivan <nathan.sullivan@ni.com> Date: Tue May 3 18:10:56 2016 -0500 igb: adjust PTP timestamps for Tx/Rx latency Table 7-62 on page 338 of the i210 datasheet lists TX and RX latencies for the various speeds the chip supports. To give better PTP timestamp accuracy, adjust the timestamps by the amounts Intel gives based on current link speed. Signed-off-by: Nathan Sullivan <nathan.sullivan@ni.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb.h | 8 +++++++ drivers/net/ethernet/intel/igb/igb_ptp.c | 36 ++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) commit e4f35c1339f0cfcf38d3f63dd6fea2b070399263 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu May 12 23:00:12 2016 +0200 ACPI / video: mark acpi_video_get_levels() inline A recent patch added a stub function for acpi_video_get_levels when CONFIG_ACPI_VIDEO is disabled. However, this is marked as 'static' and causes a warning about an unused function whereever the header gets included: In file included from ../drivers/gpu/drm/radeon/radeon_acpi.c:28:0: include/acpi/video.h:74:12: error: 'acpi_video_get_levels' defined but not used [-Werror=unused-function] This makes the declaration 'static inline', which gets rid of the warning. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 059500940def (ACPI/video: export acpi_video_get_levels) Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/video.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ab507c9a54ce3580e6a3829c9f4c24a13c32cbac Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Wed Apr 20 17:45:56 2016 +0200 e1000e: e1000e_cyclecounter_read(): do overflow check only if needed SYSTIMH:SYSTIML registers are incremented by 24-bit value TIMINCA[23..0] er32(SYSTIML) are probably moderately expensive (they are pci bus reads). Can we avoid one of them? Yes, we can. If the SYSTIML value we see is smaller than 0xff000000, the overflow into SYSTIMH would require at least two increments. We do two reads, er32(SYSTIML) and er32(SYSTIMH), in this order. Even if one increment happens between them, the overflow into SYSTIMH is impossible, and we can avoid doing another er32(SYSTIML) read and overflow check. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/netdev.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) commit a07fd74d5ea9c45a5c6e41f7cb4b997cf40d50f3 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Wed Apr 20 17:45:55 2016 +0200 e1000e: e1000e_cyclecounter_read(): fix er32(SYSTIML) overflow check If two consecutive reads of the counter are the same, it is also not an overflow. "systimel_1 < systimel_2" should be "systimel_1 <= systimel_2". Before the patch, we could perform an *erroneous* correction: Let's say that systimel_1 == systimel_2 == 0xffffffff. "systimel_1 < systimel_2" is false, we think it's an overflow, we read "systimeh = er32(SYSTIMH)" which meanwhile had incremented, and use "(systimeh << 32) + systimel_2" value which is 2^32 too large. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: intel-wired-lan@lists.osuosl.org Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/netdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fb5277f2c2e4db4a29740ff071072a688892d2df Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Wed Apr 20 17:45:54 2016 +0200 e1000e: e1000e_cyclecounter_read(): incvalue is 32 bits, not 64 "incvalue" variable holds a result of "er32(TIMINCA) & E1000_TIMINCA_INCVALUE_MASK" and used in "do_div(temp, incvalue)" as a divisor. Thus, "u64 incvalue" declaration is probably a mistake. Even though it seems to be a harmless one, let's fix it. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/netdev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit f79a917e69e1f5cd86e864b67f06147f1b0340f4 Merge: ed7cbbc b853cb9 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Fri May 13 14:36:11 2016 -0700 Merge tag 'qcom-soc-for-4.7-2' into net-next This merges the Qualcomm SOC tree with the net-next, solving the merge conflict in the SMD API between the two. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> commit 8008f68cb805c0099723ba1b58d26257a52ce890 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:29 2016 -0700 igb: make igb_update_pf_vlvf static Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a51d8c217b15b97fede844dd6860f7b3c6ffcfef Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:28 2016 -0700 igb: use BIT() macro or unsigned prefix For bitshifts, we should make use of the BIT macro when possible, and ensure that other bitshifts are marked as unsigned. This helps prevent signed bitshift errors, and ensures similar style. Make use of GENMASK and the unsigned postfix where BIT() isn't appropriate. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/e1000_82575.c | 8 +- drivers/net/ethernet/intel/igb/e1000_82575.h | 30 +++---- drivers/net/ethernet/intel/igb/e1000_defines.h | 108 ++++++++++++------------- drivers/net/ethernet/intel/igb/e1000_mac.c | 10 +-- drivers/net/ethernet/intel/igb/e1000_mbx.c | 4 +- drivers/net/ethernet/intel/igb/e1000_nvm.c | 2 +- drivers/net/ethernet/intel/igb/e1000_phy.h | 6 +- drivers/net/ethernet/intel/igb/igb.h | 32 ++++---- drivers/net/ethernet/intel/igb/igb_ethtool.c | 18 ++--- drivers/net/ethernet/intel/igb/igb_main.c | 48 +++++------ drivers/net/ethernet/intel/igb/igb_ptp.c | 6 +- 11 files changed, 136 insertions(+), 136 deletions(-) commit 847042a6a51e6dbb789c259750609b78aa3f27a3 Author: Brian Walsh <brian@walsh.ws> Date: Tue Apr 12 23:22:30 2016 -0400 e1000e: Cleanup consistency in ret_val variable usage Fixed the file to use a consistent ret_val for return value checking. Signed-off-by: Brian Walsh <brian@walsh.ws> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/netdev.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit e11f303e3d0731a7379252192e7d02a1ae319238 Author: Steve Shih <sshih@cisco.com> Date: Tue Apr 5 11:30:03 2016 -0700 e1000e: fix ethtool autoneg off for non-copper This patch fixes the issues for disabling auto-negotiation and forcing speed and duplex settings for the non-copper media. For non-copper media, e1000_get_settings should return ETH_TP_MDI_INVALID for eth_tp_mdix_ctrl instead of ETH_TP_MDI_AUTO so subsequent e1000_set_settings call would not fail with -EOPNOTSUPP. e1000_set_spd_dplx should not automatically turn autoneg back on for forced 1000 Mbps full duplex settings for non-copper media. Cc: xe-kernel@external.cisco.com Cc: Daniel Walker <dwalker@fifo99.com> Signed-off-by: Steve Shih <sshih@cisco.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/ethtool.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit f8d1a93930a754c4ea27238ae1c0fb2356d12e9a Merge: 26f5883 535dac4 Author: Tejun Heo <tj@kernel.org> Date: Fri May 13 17:20:48 2016 -0400 Merge branch 'for-4.6-fixes' into for-4.7 commit 0868971a8dad52e726711a2a4b161ace9ed011fa Author: Tony Wu <tung7970@gmail.com> Date: Fri Dec 4 19:40:00 2015 +0800 MIPS: CM: Fix compilation error when !MIPS_CM Fix mips_cm_lock_other compilation error when MIPS_CM is not selected. This was introduced in commit 23d5de8efb9a (MIPS: CM: Introduce core-other locking functions) Signed-off-by: Tony Wu <tung7970@gmail.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11698/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips-cm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2afb97454347f641dd2435a3956ba12f816fb1df Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 13 19:41:06 2016 +0100 MIPS: Fix genvdso error on rebuild The genvdso program modifies the debug and stripped versions of the VDSOs in place, and errors if the modification has already taken place. Unfortunately this means that a rebuild which tries to rerun genvdso to generate vdso*-image.c without also rebuilding vdso.so.dbg (for example if genvdso.c is modified) hits a build error like this: arch/mips/vdso/genvdso 'arch/mips/vdso/vdso.so.dbg' already contains a '.MIPS.abiflags' section This is fixed by reorganising the rules such that unmodified .so files have a .raw suffix, and these are copied in the same rule that runs genvdso on the copies. I.e. previously we had: cmd_vdsold: link objects -> vdso.so.dbg cmd_genvdso: strip vdso.so.dbg -> vdso.so run genvdso -> vdso-image.c and modify vdso.so.dbg and vdso.so in place Now we have: cmd_vdsold: link objects -> vdso.so.dbg.raw a new cmd_objcopy based strip rule (inspired by ARM): strip vdso.so.dbg.raw -> vdso.so.raw cmd_genvdso: copy vdso.so.dbg.raw -> vdso.so.dbg copy vdso.so.raw -> vdso.so run genvdso -> vdso-image.c and modify vdso.so.dbg and vdso.so in place Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13250/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/vdso/Makefile | 40 ++++++++++++++++++++++++++++------------ 1 file changed, 28 insertions(+), 12 deletions(-) commit 59643d1535eb220668692a5359de22545af579f6 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri May 13 09:34:12 2016 -0400 ring-buffer: Prevent overflow of size in ring_buffer_resize() If the size passed to ring_buffer_resize() is greater than MAX_LONG - BUF_PAGE_SIZE then the DIV_ROUND_UP() will return zero. Here's the details: # echo 18014398509481980 > /sys/kernel/debug/tracing/buffer_size_kb tracing_entries_write() processes this and converts kb to bytes. 18014398509481980 << 10 = 18446744073709547520 and this is passed to ring_buffer_resize() as unsigned long size. size = DIV_ROUND_UP(size, BUF_PAGE_SIZE); Where DIV_ROUND_UP(a, b) is (a + b - 1)/b BUF_PAGE_SIZE is 4080 and here 18446744073709547520 + 4080 - 1 = 18446744073709551599 where 18446744073709551599 is still smaller than 2^64 2^64 - 18446744073709551599 = 17 But now 18446744073709551599 / 4080 = 4521260802379792 and size = size * 4080 = 18446744073709551360 This is checked to make sure its still greater than 2 * 4080, which it is. Then we convert to the number of buffer pages needed. nr_page = DIV_ROUND_UP(size, BUF_PAGE_SIZE) but this time size is 18446744073709551360 and 2^64 - (18446744073709551360 + 4080 - 1) = -3823 Thus it overflows and the resulting number is less than 4080, which makes 3823 / 4080 = 0 an nr_pages is set to this. As we already checked against the minimum that nr_pages may be, this causes the logic to fail as well, and we crash the kernel. There's no reason to have the two DIV_ROUND_UP() (that's just result of historical code changes), clean up the code and fix this bug. Cc: stable@vger.kernel.org # 3.5+ Fixes: 83f40318dab00 ("ring-buffer: Make removal of ring buffer pages atomic") Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/ring_buffer.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit d9e4084f6c9746e51a78a4d7ebf4983023289b32 Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:47 2016 -0400 svcrdma: Generalize svc_rdma_xdr_decode_req() Clean up: Pass in just the piece of the svc_rqst that is needed here. While we're in the area, add an informative documenting comment. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> include/linux/sunrpc/svc_rdma.h | 2 +- net/sunrpc/xprtrdma/svc_rdma_marshal.c | 32 ++++++++++++++++++++++---------- net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 2 +- 3 files changed, 24 insertions(+), 12 deletions(-) commit 84f225c23d8906c9371d0749e062975c018ef6c4 Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:39 2016 -0400 svcrdma: Eliminate code duplication in svc_rdma_recvfrom() Clean up. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 26 +++++--------------------- 1 file changed, 5 insertions(+), 21 deletions(-) commit 76ee8fd64ac9af36b03b68912c18b3d3cd5c99de Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:30 2016 -0400 svcrdma: Drain QP before freeing svcrdma_xprt If the server has forced a disconnect, the associated QP has not been moved to the Error state, and thus Receives are still posted. Ensure Receives (and any other outstanding WRs) are drained to release resources that can be freed during teardown of the svcrdma_xprt. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_transport.c | 3 +++ 1 file changed, 3 insertions(+) commit 0319aafc95eaae10fdb867c35ce9bacfca27eaa3 Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:22 2016 -0400 svcrdma: Post Receives only for forward channel requests Since backward direction support was added, the rq_depth was increased to accommodate both forward and backward Receives. But only forward Receives need to be posted after a connection has been accepted. Receives for backward replies are posted as needed by svc_rdma_bc_sendto(). This doesn't break anything, but it means some resources are wasted. Fixes: 03fe9931536f ('svcrdma: Define maximum number of ...') Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_transport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cac7f15036dc69c8708fa73369a9fae193e82bfb Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:14 2016 -0400 svcrdma: Remove superfluous line from rdma_read_chunks() Clean up: svc_rdma_get_read_chunk() already returns a pointer to the Read list. No need to set "ch" again to the value it already contains. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 9ec64052060f972101b49f47631f5072f075426c Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:53:05 2016 -0400 svcrdma: svc_rdma_put_context() is invoked twice in Send error path Get a fresh op_ctxt in send_reply() instead of in svc_rdma_sendto(). This ensures that svc_rdma_put_context() is invoked only once if send_reply() fails. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_sendto.c | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) commit 6625d0913771df5f12b9531c8cb8414e55f1c21d Author: Chuck Lever <chuck.lever@oracle.com> Date: Wed May 4 10:52:55 2016 -0400 svcrdma: Do not add XDR padding to xdr_buf page vector An xdr_buf has a head, a vector of pages, and a tail. Each RPC request is presented to the NFS server contained in an xdr_buf. The RDMA transport would like to supply the NFS server with only the NFS WRITE payload bytes in the page vector. In some common cases, that would allow the NFS server to swap those pages right into the target file's page cache. Have the transport's RDMA Read logic put XDR pad bytes in the tail iovec, and not in the pages that hold the data payload. The NFSv3 WRITE XDR decoder is finicky about the lengths involved, so make sure it is looking in the correct places when computing the total length of the incoming NFS WRITE request. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> fs/nfsd/nfs3xdr.c | 2 +- net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 696190eaf168e83fcbf0c9cf087995cdd15807e5 Author: Shirley Ma <shirley.ma@oracle.com> Date: Wed May 4 10:52:47 2016 -0400 svcrdma: Support IPv6 with NFS/RDMA Allow both IPv4 and IPv6 to bind same port at the same time, restricts use of the IPv6 socket to IPv6 communication. Changes from v1: - Check rdma_set_afonly return value (suggested by Leon Romanovsky) Changes from v2: - Acked-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Shirley Ma <shirley.ma@oracle.com> Acked-by: Leon Romanovsky <leonro@mellanox.com> Reviewed-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/xprtrdma/svc_rdma_transport.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 14b7f4a1edf15808cf52dc38277ffe1d84854839 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu May 5 06:53:47 2016 -0400 nfsd: handle seqid wraparound in nfsd4_preprocess_layout_stateid Move the existing static function to an inline helper, and call it. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> fs/nfsd/nfs4layouts.c | 2 +- fs/nfsd/nfs4state.c | 8 +------- fs/nfsd/state.h | 5 +++++ 3 files changed, 7 insertions(+), 8 deletions(-) commit e2ed8a132a70dc61ef6d9979bec4f37a3abbba4b Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu May 12 14:41:04 2016 -0400 drm/amd/powerplay: fix a bug on updating sclk for Tonga Update sclk smc table rather than mclk smc table for sclk updates. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bd6080d662f08b4c4540c4e3735f0738cab7004f Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Tue May 10 14:39:09 2016 -0400 drm/amd/powerplay: fix a bug on updating sclk for Fiji Update sclk smc table rather than mclk smc table for sclk updates. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d573de2d00835e38cef1fb4bff7b49c174c68941 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Thu May 12 13:27:28 2016 +0800 drm/amdgpu: create fence slab once when amdgpu module init. This avoids problems with multiple GPUs. For example, if the first GPU failed before amdgpu_fence_init() was called, amdgpu_fence_slab_ref is still 0 and it will get decremented in amdgpu_fence_driver_fini(). This will lead to a crash during init of the second GPU since amdgpu_fence_slab_ref is not 0. v2: add functions for init/exit instead of moving the variables into the driver. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 5 ++++- drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 25 ++++++++++++++----------- 3 files changed, 20 insertions(+), 12 deletions(-) commit 8b41e7a03a306d93276f91c1dae39dc51a1af58d Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue May 10 15:37:00 2016 +0800 drm/amd/powerplay: move asic unrelated function to hwmgr.c. It's generic and used by multiple asics. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 37 +-------------------- drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 38 ++++++++++++++++++++++ .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 36 -------------------- drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 2 +- 4 files changed, 40 insertions(+), 73 deletions(-) commit 2dcbffad94f3c2f85cc2c433dad382a741e91dc4 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue May 10 13:39:29 2016 +0800 drm/amd/powerplay: fix NULL point check error && was used instead of || Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 9ab9cf058a5de590146fdc67bf9c483c8bdcbffa Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue May 3 15:47:15 2016 +0800 drm/amd/powerplay: SCLK will have a big drop with low VDDC when PPlib was enabled. SMC uses CurrSclkPllRange structure to keep track of what range of PLL SCLK is sitting on. Driver overwrites this value to 0 because it's part of DPM table and driver doesn't program this. This change will set this field to 0xFF every time there's a init SMC table call. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit e9bb8af98a981fe404010706a192ca0450a87760 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 12:14:46 2016 +0100 i40iw: pass hw_stats by reference rather than by value passing hw_stats by value requires a 280 byte copy so instead pass it by reference is much more efficient. Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Chien Tin Tung <chien.tin.tung@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e381b3bbd7969a2bf134e10c1ead96644f985b10 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Mon Mar 28 11:31:26 2016 +0200 i40iw: Remove unnecessary synchronize_irq() before free_irq() Calling synchronize_irq() right before free_irq() is quite useless. On one hand the IRQ can easily fire again before free_irq() is entered, on the other hand free_irq() itself calls synchronize_irq() internally (in a race condition free way), before any state associated with the IRQ is freed. Patch was generated using the following semantic patch: // <smpl> @@ expression irq; @@ -synchronize_irq(irq); free_irq(irq, ...); // </smpl> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Acked-by: Faisal Latif <faisal.latif#intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 1 - 1 file changed, 1 deletion(-) commit dc1badf63026550ce8d099c3a4d1c803d23b038f Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 14:22:21 2016 +0200 i40iw: constify i40iw_vf_cqp_ops structure The i40iw_vf_cqp_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_type.h | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_vf.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit a647040ea85ae0bf5bd93f2a1b42dba57b0d0059 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 14:07:23 2016 +0200 i40e: constify i40e_client_ops structure The i40e_client_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 2 +- drivers/net/ethernet/intel/i40e/i40e_client.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit c222a39f0d2652ff32e10a95979af9bf906b9844 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:51:01 2016 -0700 IB/srp: Do not register memory if never_register has been set This makes it easier to test the code path that does not use memory registration (srp_map_sg_dma()). Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 509c5f33f4f6dc328d96bf4099ef6589739f22d4 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:50:35 2016 -0700 IB/srp: Prevent mapping failures If both max_sectors and the queue_depth are high enough it can happen that the MR pool is depleted temporarily. This causes the SRP initiator to report mapping failures. Although the SRP initiator recovers from such mapping failures, prevent that this can happen by allocating more memory regions. Additionally, only enable memory registration if at least two pages can be registered per memory region. Reported-by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 137 +++++++++++++++++++++++++++++++----- drivers/infiniband/ulp/srp/ib_srp.h | 1 + 2 files changed, 119 insertions(+), 19 deletions(-) commit 835ee624c99d0b63797babf25abe208182bb88bf Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:49:39 2016 -0700 IB/srp: Swap two code blocks in srp_add_one() This patch does not change any functionality but makes the next patch in this series easier to read. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) commit 9aa8b3217ed3c13d4e3496020b140da0e6f49a08 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:49:15 2016 -0700 IB/core: Enhance ib_map_mr_sg() The SRP initiator allows to set max_sectors to a value that exceeds the largest amount of data that can be mapped at once with an mlx4 HCA using fast registration and a page size of 4 KB. Hence modify ib_map_mr_sg() such that it can map partial sg-elements. If an sg-element has been mapped partially, let the caller know which fraction has been mapped by adjusting *sg_offset. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/rw.c | 2 +- drivers/infiniband/core/verbs.c | 26 +++++++++++++++++++++----- drivers/infiniband/hw/cxgb3/iwch_provider.c | 2 +- drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 2 +- drivers/infiniband/hw/cxgb4/mem.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 +- drivers/infiniband/hw/mlx4/mlx4_ib.h | 2 +- drivers/infiniband/hw/mlx4/mr.c | 2 +- drivers/infiniband/hw/mlx5/mlx5_ib.h | 2 +- drivers/infiniband/hw/mlx5/mr.c | 8 ++++++-- drivers/infiniband/hw/nes/nes_verbs.c | 2 +- drivers/infiniband/hw/ocrdma/ocrdma_verbs.c | 2 +- drivers/infiniband/hw/ocrdma/ocrdma_verbs.h | 2 +- drivers/infiniband/ulp/iser/iser_memory.c | 4 ++-- drivers/infiniband/ulp/srp/ib_srp.c | 2 +- include/rdma/ib_verbs.h | 8 ++++---- net/sunrpc/xprtrdma/frwr_ops.c | 2 +- net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 2 +- 18 files changed, 47 insertions(+), 27 deletions(-) commit f83b2561a6d4ff12959660ad597580097b744941 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:48:48 2016 -0700 IB/srp: Fix srp_create_target() error handling Avoid that the following kernel oops occurs if memory pool allocation fails: BUG: unable to handle kernel NULL pointer dereference at (null) IP: [<ffffffffa048d0a0>] ib_drain_rq+0x0/0x20 [ib_core] Call Trace: [<ffffffffa04af386>] srp_create_target+0xca6/0x13a9 [ib_srp] [<ffffffff813cc863>] dev_attr_store+0x13/0x20 [<ffffffff81214b50>] sysfs_kf_write+0x40/0x50 [<ffffffff81213f1c>] kernfs_fop_write+0x13c/0x180 [<ffffffff81197683>] __vfs_write+0x23/0xf0 [<ffffffff81198744>] vfs_write+0xa4/0x1a0 [<ffffffff81199a44>] SyS_write+0x44/0xa0 [<ffffffff8159e3e9>] entry_SYSCALL_64_fastpath+0x1c/0xac Fixes: 1dc7b1f10dcb ("IB/srp: use the new CQ API") Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: <stable@vger.kernel.org> # v4.5+ Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 9d8e7d0dacf09ddac7e617d17dbeec6af56e81e8 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:48:13 2016 -0700 IB/srp: Fix a memory descriptor leak in an error path If an error occurs after srp_fr_pool_get() succeeded and before the descriptor is stored in srp_map_state (*state->fr.next++ = desc) then srp_unmap_data() won't free the newly allocated memory descriptor. Hence free the descriptor explicitly. Fixes: f7f7aab1a5c0 ("IB/srp: Convert to new registration API") Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Sagi Grimberg <sai@grimberg.me> Cc: Christoph Hellwig <hch@lst.de> Cc: <stable@vger.kernel.org> # v4.4+ Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit cf1acab7d75652a372ee5b9c996689d518914e83 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu May 12 10:47:38 2016 -0700 IB/srp: Print "ib_srp: " prefix once pr_debug() already prints prefix PFX. Avoid that PFX is printed twice if the debug statement in srp_add_target() is enabled. Fixes: 34aa654ecb8e ("IB/srp: Avoid that I/O hangs due to a cable pull during LUN scanning") Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Tested-by: Laurence Oberman <loberman@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 38a2d0d429f1d87315c55d9139b8bdf66d51c4f4 Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:13 2016 +0200 IB/isert: convert to the generic RDMA READ/WRITE API Replace the homegrown RDMA READ/WRITE code in isert with the generic API, which also adds iWarp support to the I/O path as a side effect. Note that full iWarp operation will need a few additional patches from Steve. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/isert/ib_isert.c | 841 ++++---------------------------- drivers/infiniband/ulp/isert/ib_isert.h | 69 +-- 2 files changed, 85 insertions(+), 825 deletions(-) commit 0e353e34e1e740fe575eb479ca0f2a723a4ef51c Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:12 2016 +0200 IB/core: add RW API support for signature MRs Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/rw.c | 228 +++++++++++++++++++++++++++++++++++++++- drivers/infiniband/core/verbs.c | 1 + include/rdma/ib_verbs.h | 1 + include/rdma/rw.h | 19 ++++ 4 files changed, 244 insertions(+), 5 deletions(-) commit b99f8e4d7bcd3bfbb3cd965918523299370d0cb2 Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:11 2016 +0200 IB/srpt: convert to the generic RDMA READ/WRITE API Replace the homegrown RDMA READ/WRITE code in srpt with the generic API. The only real twist here is that we need to allocate one Linux scatterlist per direct buffer in the SRP command, and chain them before handing them off to the target core. As a side-effect of the conversion the driver will also chain the SEND of the SRP response to the RDMA WRITE WRs for a DATA OUT command, and properly account for RDMA WRITE WRs instead of just for RDMA READ WRs like the driver previously did. We now allocate half of the SQ size to RDMA READ/WRITE contexts, assuming by default one RDMA READ or WRITE operation per command. If a command has multiple operations it will eat into the budget but will still succeed, possible after waiting for WQEs to be available. Also ensure the QPs request the maximum allowed SGEs so that RDMA R/W API works correctly. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srpt/ib_srpt.c | 729 ++++++++++++---------------------- drivers/infiniband/ulp/srpt/ib_srpt.h | 31 +- 2 files changed, 265 insertions(+), 495 deletions(-) commit e64aa657c3d0dae84c2ccc166f6fe25b7d1d28c6 Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:10 2016 +0200 target: enhance and export target_alloc_sgl/target_free_sgl The SRP target driver will need to allocate and chain it's own SGLs soon. For this export target_alloc_sgl, and add a new argument to it so that it can allocate an additional chain entry that doesn't point to a page. Also export transport_free_sgl after renaming it to target_free_sgl to free these SGLs again. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/target/target_core_transport.c | 32 ++++++++++++++++++-------------- drivers/target/target_core_xcopy.c | 2 +- include/target/target_core_backend.h | 1 - include/target/target_core_fabric.h | 4 ++++ 4 files changed, 23 insertions(+), 16 deletions(-) commit a060b5629ab066dd1d321430eeb96f70939a1790 Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:09 2016 +0200 IB/core: generic RDMA READ/WRITE API This supports both manual mapping of lots of SGEs, as well as using MRs from the QP's MR pool, for iWarp or other cases where it's more optimal. For now, MRs are only used for iWARP transports. The user of the RDMA-RW API must allocate the QP MR pool as well as size the SQ accordingly. Thanks to Steve Wise for testing, fixing and rewriting the iWarp support, and to Sagi Grimberg for ideas, reviews and fixes. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/Makefile | 2 +- drivers/infiniband/core/rw.c | 509 +++++++++++++++++++++++++++++++++++++++ drivers/infiniband/core/verbs.c | 25 ++ include/rdma/ib_verbs.h | 14 +- include/rdma/rw.h | 69 ++++++ 5 files changed, 617 insertions(+), 2 deletions(-) commit d4a85c309b33f93cb211f2fa9d26fa77d0bb7b5e Author: Steve Wise <swise@chelsio.com> Date: Tue May 3 18:01:08 2016 +0200 IB/core: add a need_inval flag to struct ib_mr This is the first step toward moving MR invalidation decisions to the core. It will be needed by the upcoming RW API. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/verbs.c | 2 ++ include/rdma/ib_verbs.h | 1 + 2 files changed, 3 insertions(+) commit fffb0383cf0b433ad029d19e6e9d6f1f46523ace Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:07 2016 +0200 IB/core: add a simple MR pool Signed-off-by: Christoph Hellwig <hch@lst.de> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/Makefile | 2 +- drivers/infiniband/core/mr_pool.c | 86 +++++++++++++++++++++++++++++++++++++++ drivers/infiniband/core/verbs.c | 5 +++ include/rdma/ib_verbs.h | 8 +++- include/rdma/mr_pool.h | 25 ++++++++++++ 5 files changed, 124 insertions(+), 2 deletions(-) commit 04c41bf39f5b2de72bda04cf10bb95ea1870a94f Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:06 2016 +0200 IB/core: refactor ib_create_qp Split the XRC magic into a separate function, and return early on failure to make the initialization code readable. Signed-off-by: Christoph Hellwig <hch@lst.de> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/verbs.c | 103 +++++++++++++++++++++------------------- 1 file changed, 54 insertions(+), 49 deletions(-) commit 002516edf5176dde2bee54addb7e6e8129a9532b Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:05 2016 +0200 IB/core: add a helper to check for READ WITH INVALIDATE support Signed-off-by: Christoph Hellwig <hch@lst.de> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Doug Ledford <dledford@redhat.com> include/rdma/ib_verbs.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit ff2ba9936591a1364ae21adf18366dca7608395a Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:04 2016 +0200 IB/core: Add passing an offset into the SG to ib_map_mr_sg Signed-off-by: Christoph Hellwig <hch@lst.de> Tested-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/verbs.c | 24 ++++++++++++------------ drivers/infiniband/hw/cxgb3/iwch_provider.c | 7 +++---- drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 5 ++--- drivers/infiniband/hw/cxgb4/mem.c | 7 +++---- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 5 +++-- drivers/infiniband/hw/mlx4/mlx4_ib.h | 5 ++--- drivers/infiniband/hw/mlx4/mr.c | 7 +++---- drivers/infiniband/hw/mlx5/mlx5_ib.h | 5 ++--- drivers/infiniband/hw/mlx5/mr.c | 21 ++++++++++++--------- drivers/infiniband/hw/nes/nes_verbs.c | 7 +++---- drivers/infiniband/hw/ocrdma/ocrdma_verbs.c | 7 +++---- drivers/infiniband/hw/ocrdma/ocrdma_verbs.h | 5 ++--- drivers/infiniband/ulp/iser/iser_memory.c | 4 ++-- drivers/infiniband/ulp/isert/ib_isert.c | 2 +- drivers/infiniband/ulp/srp/ib_srp.c | 2 +- include/rdma/ib_verbs.h | 23 +++++++++-------------- net/rds/ib_frmr.c | 2 +- net/sunrpc/xprtrdma/frwr_ops.c | 2 +- net/sunrpc/xprtrdma/svc_rdma_recvfrom.c | 2 +- 19 files changed, 66 insertions(+), 76 deletions(-) commit b071c5d7998a79919e83565ddfb98fdf6fa804bc Author: Maarten ter Huurne <maarten@treewalker.org> Date: Mon Apr 18 20:58:53 2016 +0200 USB: ohci-jz4740: Remove obsolete driver The ohci-platform driver can control the clock, while usb-nop-xceiv as the PHY can control the vbus regulator. So this JZ4740-specific glue is not needed anymore. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Paul Cercueil <paul@crapouillou.net> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13105/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/usb/host/ohci-hcd.c | 5 - drivers/usb/host/ohci-jz4740.c | 245 ----------------------------------------- 2 files changed, 250 deletions(-) commit 9d1e7875fafc45dbcbe3d816b022aa1f17219f32 Author: Maarten ter Huurne <maarten@treewalker.org> Date: Mon Apr 18 20:58:52 2016 +0200 MIPS: JZ4740: Probe OHCI platform device via DT The DT fragment will select the ohci-platform driver, since that can handle the JZ4740 OHCI just fine. While I don't have a JZ4740-based board with anything connected to the USB host controller, I did test the generic OHCI driver successfully on a JZ4770-based board. The device is disabled by default; boards that want to use it can override the "status" property. The mass-production Qi LB60 boards don't use the USB host controller. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Paul Cercueil <paul@crapouillou.net> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13104/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/ingenic/jz4740.dtsi | 14 ++++++++++++++ arch/mips/include/asm/mach-jz4740/platform.h | 1 - arch/mips/jz4740/platform.c | 25 ------------------------- 3 files changed, 14 insertions(+), 26 deletions(-) commit 46d6ccdbf384f3659e204824d3bce40c1fa989de Author: Maarten ter Huurne <maarten@treewalker.org> Date: Mon Apr 18 20:58:51 2016 +0200 MIPS: JZ4740: Qi LB60: Remove support for AVT2 variant AVT2 was a prototype board of which about 5 were made, none of which are in use anymore. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Cc: Paul Cercueil <paul@crapouillou.net> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13103/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/jz4740/board-qi_lb60.c | 52 ++-------------------------------------- 1 file changed, 2 insertions(+), 50 deletions(-) commit ae07ea85bd2900d0df0c17724b252131ddae4b50 Author: James Hartley <James.Hartley@imgtec.com> Date: Tue Apr 19 15:46:55 2016 +0100 MIPS: pistachio: Determine SoC revision during boot Now that there are different revisions of the Pistachio SoC in circulation, add this information to the boot log to make it easier for users to determine which hardware they have. Signed-off-by: James Hartley <james.hartley@imgtec.com> Signed-off-by: Ionela Voinescu <ionela.voinescu@imgtec.com> Cc: Andrew Bresticker <abrestic@chromium.org> Cc: Jonas Gorski <jogo@openwrt.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13130/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/pistachio/init.c | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) commit 80fa40acaa1dad5a0a9c15ed2e5d2e72461843f5 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue Apr 19 15:35:39 2016 -0700 MIPS: BMIPS: Adjust mips-hpt-frequency for BCM7435 The CPU actually runs at 1405Mhz which gives us a 175625000 Hz MIPS timer frequency (CPU frequency / 8). Fixes: e4c7d009654a ("MIPS: BMIPS: Add BCM7435 dtsi") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jaedon.shin@gmail.com Patchwork: https://patchwork.linux-mips.org/patch/13132/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm7435.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c4a8de357ef1916c38e4419c0bafad86ca4fbcf7 Author: Christian Borntraeger <borntraeger@de.ibm.com> Date: Fri May 13 12:16:36 2016 +0200 KVM: s390: set halt polling to 80 microseconds on s390 we disabled the halt polling with commit 920552b213e3 ("KVM: disable halt_poll_ns as default for s390x"), as floating interrupts would let all CPUs have a successful poll, resulting in much higher CPU usage (on otherwise idle systems). With the improved selection of polls we can now retry halt polling. Performance measurements with different choices like 25,50,80,100,200 microseconds showed that 80 microseconds seems to improve several cases without increasing the CPU costs too much. Higher values would improve the performance even more but increased the cpu time as well. So let's start small and use this value of 80 microseconds on s390 until we have a better understanding of cost/benefit of higher values. Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/s390/include/asm/kvm_host.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3491caf2755e9f312666712510d80b00c81ff247 Author: Christian Borntraeger <borntraeger@de.ibm.com> Date: Fri May 13 12:16:35 2016 +0200 KVM: halt_polling: provide a way to qualify wakeups during poll Some wakeups should not be considered a sucessful poll. For example on s390 I/O interrupts are usually floating, which means that _ALL_ CPUs would be considered runnable - letting all vCPUs poll all the time for transactional like workload, even if one vCPU would be enough. This can result in huge CPU usage for large guests. This patch lets architectures provide a way to qualify wakeups if they should be considered a good/bad wakeups in regard to polls. For s390 the implementation will fence of halt polling for anything but known good, single vCPU events. The s390 implementation for floating interrupts does a wakeup for one vCPU, but the interrupt will be delivered by whatever CPU checks first for a pending interrupt. We prefer the woken up CPU by marking the poll of this CPU as "good" poll. This code will also mark several other wakeup reasons like IPI or expired timers as "good". This will of course also mark some events as not sucessful. As KVM on z runs always as a 2nd level hypervisor, we prefer to not poll, unless we are really sure, though. This patch successfully limits the CPU usage for cases like uperf 1byte transactional ping pong workload or wakeup heavy workload like OLTP while still providing a proper speedup. This also introduced a new vcpu stat "halt_poll_no_tuning" that marks wakeups that are considered not good for polling. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Acked-by: Radim Krčmář <rkrcmar@redhat.com> (for an earlier version) Cc: David Matlack <dmatlack@google.com> Cc: Wanpeng Li <kernellwp@gmail.com> [Rename config symbol. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/arm/include/asm/kvm_host.h | 2 ++ arch/arm64/include/asm/kvm_host.h | 2 ++ arch/mips/include/asm/kvm_host.h | 2 ++ arch/mips/kvm/mips.c | 1 + arch/powerpc/include/asm/kvm_host.h | 2 ++ arch/powerpc/kvm/book3s.c | 1 + arch/powerpc/kvm/booke.c | 1 + arch/s390/include/asm/kvm_host.h | 3 +++ arch/s390/kvm/Kconfig | 1 + arch/s390/kvm/interrupt.c | 5 +++++ arch/s390/kvm/kvm-s390.c | 6 ++++++ arch/x86/include/asm/kvm_host.h | 2 ++ arch/x86/kvm/x86.c | 1 + include/linux/kvm_host.h | 15 +++++++++++++++ include/trace/events/kvm.h | 11 +++++++---- virt/kvm/Kconfig | 3 +++ virt/kvm/kvm_main.c | 8 ++++++-- 17 files changed, 60 insertions(+), 6 deletions(-) commit 9b94a8fba501f38368aef6ac1b30e7335252a220 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Thu May 12 11:01:24 2016 -0400 ring-buffer: Use long for nr_pages to avoid overflow failures The size variable to change the ring buffer in ftrace is a long. The nr_pages used to update the ring buffer based on the size is int. On 64 bit machines this can cause an overflow problem. For example, the following will cause the ring buffer to crash: # cd /sys/kernel/debug/tracing # echo 10 > buffer_size_kb # echo 8556384240 > buffer_size_kb Then you get the warning of: WARNING: CPU: 1 PID: 318 at kernel/trace/ring_buffer.c:1527 rb_update_pages+0x22f/0x260 Which is: RB_WARN_ON(cpu_buffer, nr_removed); Note each ring buffer page holds 4080 bytes. This is because: 1) 10 causes the ring buffer to have 3 pages. (10kb requires 3 * 4080 pages to hold) 2) (2^31 / 2^10 + 1) * 4080 = 8556384240 The value written into buffer_size_kb is shifted by 10 and then passed to ring_buffer_resize(). 8556384240 * 2^10 = 8761737461760 3) The size passed to ring_buffer_resize() is then divided by BUF_PAGE_SIZE which is 4080. 8761737461760 / 4080 = 2147484672 4) nr_pages is subtracted from the current nr_pages (3) and we get: 2147484669. This value is saved in a signed integer nr_pages_to_update 5) 2147484669 is greater than 2^31 but smaller than 2^32, a signed int turns into the value of -2147482627 6) As the value is a negative number, in update_pages_handler() it is negated and passed to rb_remove_pages() and 2147482627 pages will be removed, which is much larger than 3 and it causes the warning because not all the pages asked to be removed were removed. Link: https://bugzilla.kernel.org/show_bug.cgi?id=118001 Cc: stable@vger.kernel.org # 2.6.28+ Fixes: 7a8e76a3829f1 ("tracing: unified trace buffer") Reported-by: Hao Qin <QEver.cn@gmail.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/ring_buffer.c | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) commit 72f9f8b58bc743e6b6abdc68f60db98486c3ffcf Author: Lauro Costa <lauro@polilinux.com.br> Date: Mon May 9 17:36:11 2016 -0300 Bluetooth: Add USB ID 13D3:3487 to ath3k Add hw id to ath3k usb device list and btusb blacklist T: Bus=01 Lev=01 Prnt=01 Port=08 Cnt=02 Dev#= 4 Spd=12 MxCh= 0 D: Ver= 1.10 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=64 #Cfgs= 1 P: Vendor=13d3 ProdID=3487 Rev=00.02 C: #Ifs= 2 Cfg#= 1 Atr=e0 MxPwr=100mA I: If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb I: If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb Requires these firmwares: ar3k/AthrBT_0x11020100.dfu and ar3k/ramps_0x11020100_40.dfu Firmwares are available in linux-firmware. Device found in a laptop ASUS model N552VW. It's an Atheros AR9462 chip. Signed-off-by: Lauro Costa <lauro@polilinux.com.br> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/ath3k.c | 2 ++ drivers/bluetooth/btusb.c | 1 + 2 files changed, 3 insertions(+) commit bf389cabb3b8079c23f9762e62b05f291e2d5e99 Author: Jiri Slaby <jslaby@suse.cz> Date: Fri May 13 10:38:49 2016 +0200 Bluetooth: fix power_on vs close race With all the latest fixes applied, I am still able to reproduce this (and other) warning(s): WARNING: CPU: 1 PID: 19684 at ../kernel/workqueue.c:4092 destroy_workqueue+0x70a/0x770() ... Call Trace: [<ffffffff819fee81>] ? dump_stack+0xb3/0x112 [<ffffffff8117377e>] ? warn_slowpath_common+0xde/0x140 [<ffffffff811ce68a>] ? destroy_workqueue+0x70a/0x770 [<ffffffff811739ae>] ? warn_slowpath_null+0x2e/0x40 [<ffffffff811ce68a>] ? destroy_workqueue+0x70a/0x770 [<ffffffffa0c944c9>] ? hci_unregister_dev+0x2a9/0x720 [bluetooth] [<ffffffffa0b301db>] ? vhci_release+0x7b/0xf0 [hci_vhci] [<ffffffffa0b30160>] ? vhci_flush+0x50/0x50 [hci_vhci] [<ffffffff8117cd73>] ? do_exit+0x863/0x2b90 This is due to race present in the hci_unregister_dev path. hdev->power_on work races with hci_dev_do_close. One tries to open, the other tries to close, leading to warning like the above. (Another example is a warning in kobject_get or kobject_put depending on who wins the race.) Fix this by switching those two racers to ensure hdev->power_on never triggers while hci_dev_do_close is in progress. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/bluetooth/hci_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ef0491ea17f8019821c7e9c8e801184ecf17f85a Author: Steven Rostedt <rostedt@goodmis.org> Date: Fri May 13 15:30:13 2016 +0200 ARM: Hide finish_arch_post_lock_switch() from modules The introduction of switch_mm_irqs_off() brought back an old bug regarding the use of preempt_enable_no_resched: As part of: 62b94a08da1b ("sched/preempt: Take away preempt_enable_no_resched() from modules") the definition of preempt_enable_no_resched() is only available in built-in code, not in loadable modules, so we can't generally use it from header files. However, the ARM version of finish_arch_post_lock_switch() calls preempt_enable_no_resched() and is defined as a static inline function in asm/mmu_context.h. This in turn means we cannot include asm/mmu_context.h from modules. With today's tip tree, asm/mmu_context.h gets included from linux/mmu_context.h, which is normally the exact pattern one would expect, but unfortunately, linux/mmu_context.h can be included from the vhost driver that is a loadable module, now causing this compile time error with modular configs: In file included from ../include/linux/mmu_context.h:4:0, from ../drivers/vhost/vhost.c:18: ../arch/arm/include/asm/mmu_context.h: In function 'finish_arch_post_lock_switch': ../arch/arm/include/asm/mmu_context.h:88:3: error: implicit declaration of function 'preempt_enable_no_resched' [-Werror=implicit-function-declaration] preempt_enable_no_resched(); Andy already tried to fix the bug by including linux/preempt.h from asm/mmu_context.h, but that didn't help. Arnd suggested reordering the header files, which wasn't popular, so let's use this workaround instead: The finish_arch_post_lock_switch() definition is now also hidden inside of #ifdef MODULE, so we don't see anything referencing preempt_enable_no_resched() from a header file. I've built a few hundred randconfig kernels with this, and did not see any new problems. Tested-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King - ARM Linux <linux@armlinux.org.uk> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: linux-arm-kernel@lists.infradead.org Fixes: f98db6013c55 ("sched/core: Add switch_mm_irqs_off() and use it in the scheduler") Link: http://lkml.kernel.org/r/1463146234-161304-1-git-send-email-arnd@arndb.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/mmu_context.h | 2 ++ 1 file changed, 2 insertions(+) commit 86ce9a340e38bcba664fb11c7ab9ba03fcf5e55e Author: Sashka Nochkin <linux-mips@durdom.com> Date: Tue Apr 19 23:44:45 2016 -0400 mips: mt7620: fallback to SDRAM when syscfg0 does not have a valid value for the memory type Mediatek MT7620 SoC has syscfg0 bits where it sets the type of memory being used. However, sometimes those bits are not set properly (reading "11"). In this case, the SoC assumes SDRAM. The patch below reflects that. Signed-off-by: Sashka Nochkin <linux-mips@durdom.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13135/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-ralink/mt7620.h | 1 + arch/mips/ralink/mt7620.c | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) commit 6533af4d4831c421cd9aa4dce7cfc19a3514cc09 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 18:04:53 2016 +0100 MIPS: Prevent "restoration" of MSA context in non-MSA kernels If a kernel doesn't support MSA context (ie. CONFIG_CPU_HAS_MSA=n) then it will only keep 64 bits per FP register in thread context, and the calls to set_fpr64 in restore_msa_extcontext will overrun the end of the FP register context into the FCSR & MSACSR values. GCC 6.x has become smart enough to detect this & complain like so: arch/mips/kernel/signal.c: In function 'protected_restore_fp_context': ./arch/mips/include/asm/processor.h:114:17: error: array subscript is above array bounds [-Werror=array-bounds] fpr->val##width[FPR_IDX(width, idx)] = val; \ ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~ ./arch/mips/include/asm/processor.h:118:1: note: in expansion of macro 'BUILD_FPR_ACCESS' BUILD_FPR_ACCESS(64) The only way to trigger this code to run would be for a program to set up an artificial extended MSA context structure following a sigframe & execute sigreturn. Whilst this doesn't allow a program to write to any state that it couldn't already, it makes little sense to allow this "restoration" of MSA context in a system that doesn't support MSA. Fix this by killing a program with SIGSYS if it tries something as crazy as "restoring" fake MSA context in this way, also fixing the build error & allowing for most of restore_msa_extcontext to be optimised out of kernels without support for MSA. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reported-by: Michal Toman <michal.toman@imgtec.com> Fixes: bf82cb30c7e5 ("MIPS: Save MSA extended context around signals") Tested-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: James Hogan <james.hogan@imgtec.com> Cc: Michal Toman <michal.toman@imgtec.com> Cc: linux-mips@linux-mips.org Cc: stable <stable@vger.kernel.org> # v4.3+ Patchwork: https://patchwork.linux-mips.org/patch/13164/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/signal.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 1fa405552e33f2169d173cdb7ca0c03e094904f6 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 18:19:17 2016 +0100 MIPS: cevt-r4k: Dynamically calculate min_delta_ns Calculate the MIPS clockevent device's min_delta_ns dynamically based on the time it takes to perform the mips_next_event() sequence. Virtualisation in particular makes the current fixed min_delta of 0x300 inappropriate under some circumstances, as the CP0_Count and CP0_Compare registers may be being emulated by the hypervisor, and the frequency may not correspond directly to the CPU frequency. We actually use twice the median of multiple 75th percentiles of multiple measurements of how long the mips_next_event() sequence takes, in order to fairly efficiently eliminate outliers due to unexpected hypervisor latency (which would need handling with retries when it occurs during normal operation anyway). Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13176/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cevt-r4k.c | 82 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 80 insertions(+), 2 deletions(-) commit 24e1df664fd3c025664ae0b64a4aec691507959a Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 18:19:15 2016 +0100 MIPS: malta-time: Take seconds into account When estimating the clock frequency based on the RTC, take seconds into account in case the Update In Progress (UIP) bit wasn't seen. This can happen in virtual machines (which may get pre-empted by the hypervisor at inopportune times) with QEMU emulating the RTC (and in fact not setting the UIP bit for very long), especially on slow hosts such as FPGA systems and hardware emulators. This results in several seconds actually having elapsed before seeing the UIP bit instead of just one second, and exaggerated timer frequencies. While updating the comments, they're also fixed to match the code in that the rising edge of the update flag is detected first, not the falling edge. The rising edge gives a more precise point to read the counters in a virtualised system than the falling edge, resulting in a more accurate frequency. It does however mean that we have to also wait for the falling edge before doing the read of the RTC seconds register, otherwise it seems to be possible in slow hardware emulation to stray into the interval when the RTC time is undefined during the update (at least 244uS after the rising edge of the update flag). This can result in both seconds values reading the same, and it wrapping to 60 seconds, vastly underestimating the frequency. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13174/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mti-malta/malta-time.c | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) commit aab4673b599d8037c713afce40fabae398ca96c4 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 18:19:14 2016 +0100 MIPS: malta-time: Start GIC count before syncing to RTC The sampling of the GIC counter on Malta after observing a rising edge of the RTC update flag differs slightly between the first and second sample, with the first sample also calling gic_start_count(). The two samples should really be taken as similarly as possible to get the most accurate figure, so move the gic_start_count() call before detecting the rising edge. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13173/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mti-malta/malta-time.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 6b8322576e9d325b65c54fbef64e4e8690ad70ce Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 12:43:58 2016 +0100 MIPS: Force CPUs to lose FP context during mode switches Commit 9791554b45a2 ("MIPS,prctl: add PR_[GS]ET_FP_MODE prctl options for MIPS") added support for the PR_SET_FP_MODE prctl, which allows a userland program to modify its FP mode at runtime. This is most notably required if dynamic linking leads to the FP mode requirement changing at runtime from that indicated in the initial executable's ELF header. In order to avoid overhead in the general FP context restore code, it aimed to have threads in the process become unable to enable the FPU during a mode switch & have the thread calling the prctl syscall wait for all other threads in the process to be context switched at least once. Once that happens we can know that no thread in the process whose mode will be switched has live FP context, and it's safe to perform the mode switch. However in the (rare) case of modeswitches occurring in multithreaded programs this can lead to indeterminate delays for the thread invoking the prctl syscall, and the code monitoring for those context switches was woefully inadequate for all but the simplest cases. Fix this by broadcasting an IPI if other CPUs may have live FP context for an affected thread, with a handler causing those CPUs to relinquish their FPU ownership. Threads will then be allowed to continue running but will stall on the wait_on_atomic_t in enable_restore_fp_context if they attempt to use FP again whilst the mode switch is still in progress. The end result is less fragile poking at scheduler context switch counts & a more expedient completion of the mode switch. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Fixes: 9791554b45a2 ("MIPS,prctl: add PR_[GS]ET_FP_MODE prctl options for MIPS") Reviewed-by: Maciej W. Rozycki <macro@imgtec.com> Cc: Adam Buchbinder <adam.buchbinder@gmail.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: stable <stable@vger.kernel.org> # v4.0+ Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13145/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/process.c | 40 +++++++++++++++++----------------------- 1 file changed, 17 insertions(+), 23 deletions(-) commit bd239f1e1429e7781096bf3884bdb1b2b1bb4f28 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 12:43:57 2016 +0100 MIPS: Disable preemption during prctl(PR_SET_FP_MODE, ...) Whilst a PR_SET_FP_MODE prctl is performed there are decisions made based upon whether the task is executing on the current CPU. This may change if we're preempted, so disable preemption to avoid such changes for the lifetime of the mode switch. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Fixes: 9791554b45a2 ("MIPS,prctl: add PR_[GS]ET_FP_MODE prctl options for MIPS") Reviewed-by: Maciej W. Rozycki <macro@imgtec.com> Tested-by: Aurelien Jarno <aurelien@aurel32.net> Cc: Adam Buchbinder <adam.buchbinder@gmail.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: stable <stable@vger.kernel.org> # v4.0+ Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13144/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/process.c | 4 ++++ 1 file changed, 4 insertions(+) commit e70ac023f9515c70cf2b291a294f0f250df29847 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 12:25:38 2016 +0100 MIPS: Allow emulation for unaligned [LS]DXC1 instructions If an address error exception occurs for a LDXC1 or SDXC1 instruction, within the cop1x opcode space, allow it to be passed through to the FPU emulator rather than resulting in a SIGILL. This causes LDXC1 & SDXC1 to be handled in a manner consistent with the more common LDC1 & SDC1 instructions. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Tested-by: Aurelien Jarno <aurelien@aurel32.net> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13143/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/unaligned.c | 1 + 1 file changed, 1 insertion(+) commit abf378be49f38c4d3e23581d3df3fa9f1b1b11d2 Author: Maciej W. Rozycki <macro@imgtec.com> Date: Thu May 12 10:19:08 2016 +0100 MIPS: ptrace: Prevent writes to read-only FCSR bits Correct the cases missed with commit 9b26616c8d9d ("MIPS: Respect the ISA level in FCSR handling") and prevent writes to read-only FCSR bits there. This in particular applies to FP context initialisation where any IEEE 754-2008 bits preset by `mips_set_personality_nan' are cleared before the relevant ptrace(2) call takes effect and the PTRACE_POKEUSR request addressing FPC_CSR where no masking of read-only FCSR bits is done. Remove the FCSR clearing from FP context initialisation then and unify PTRACE_POKEUSR/FPC_CSR and PTRACE_SETFPREGS handling, by factoring out code from `ptrace_setfpregs' and calling it from both places. This mostly matters to soft float configurations where the emulator can be switched this way to a mode which should not be accessible and cannot be set with the CTC1 instruction. With hard float configurations any effect is transient anyway as read-only bits will retain their values at the time the FP context is restored. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: stable@vger.kernel.org # v4.0+ Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13239/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/ptrace.c | 28 +++++++++++++++++++--------- 1 file changed, 19 insertions(+), 9 deletions(-) commit 4249548454f7ba4581aeee26bd83f42b48a14d15 Author: Maciej W. Rozycki <macro@imgtec.com> Date: Thu May 12 10:18:27 2016 +0100 MIPS: ptrace: Fix FP context restoration FCSR regression Fix a floating-point context restoration regression introduced with commit 9b26616c8d9d ("MIPS: Respect the ISA level in FCSR handling") that causes a Floating Point exception and consequently a kernel oops with hard float configurations when one or more FCSR Enable and their corresponding Cause bits are set both at a time via a ptrace(2) call. To do so reinstate Cause bit masking originally introduced with commit b1442d39fac2 ("MIPS: Prevent user from setting FCSR cause bits") to address this exact problem and then inadvertently removed from the PTRACE_SETFPREGS request with the commit referred above. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: stable@vger.kernel.org # v4.0+ Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13238/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/ptrace.c | 1 + 1 file changed, 1 insertion(+) commit 9125f19bbb97e7444b5ea01f8262fa09679e1376 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri May 13 13:22:41 2016 +0530 MIPS: dts: pic32: Update dts to reflect new PIC32MZDA clk binding - now clock nodes definition is merged with core .dtsi file - only one rootclk is now part of DT - clock clients also updated based on new binding doc Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Sandeep Sheriker <sandeepsheriker.mallikarjun@microchip.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13248/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/pic32/pic32mzda-clk.dtsi | 236 ---------------------------- arch/mips/boot/dts/pic32/pic32mzda.dtsi | 63 +++++--- arch/mips/boot/dts/pic32/pic32mzda_sk.dts | 5 +- 3 files changed, 45 insertions(+), 259 deletions(-) commit ce6e1188465998820e7182455261b1f5d508ca17 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri May 13 13:22:40 2016 +0530 CLK: microchip: Add Microchip PIC32 clock driver. This clock driver implements PIC32 specific clock-tree. clock-tree entities can only be configured through device-tree file (OF). Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13247/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/clk/Kconfig | 3 + drivers/clk/Makefile | 1 + drivers/clk/microchip/Makefile | 2 + drivers/clk/microchip/clk-core.c | 1031 +++++++++++++++++++++++++++++++++ drivers/clk/microchip/clk-core.h | 84 +++ drivers/clk/microchip/clk-pic32mzda.c | 275 +++++++++ 6 files changed, 1396 insertions(+) commit d863dc9e5840b319105ebc90b46df8e26f1ea723 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri May 13 13:22:39 2016 +0530 dt/bindings/clk: Add PIC32 clock binding documentation. Document the devicetree bindings for the clock driver found on Microchip PIC32 class devices. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Purna Chandra Mandal <purna.mandal@microchip.com> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13246/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../devicetree/bindings/clock/microchip,pic32.txt | 39 ++++++++++++++++++++ include/dt-bindings/clock/microchip,pic32-clock.h | 42 ++++++++++++++++++++++ 2 files changed, 81 insertions(+) commit c9babb1926852d88ebee3c27f2b8bac848560c0e Author: Maciej W. Rozycki <macro@imgtec.com> Date: Fri May 13 07:21:40 2016 +0100 MIPS: ELF: Unify ABI classification macros Remove a duplicate o32 `elf_check_arch' implementation, move all macro variants to <asm/elf.h> and define them unconditionally under indvidual names, substituting alias `elf_check_arch' definitions in variant code. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13245/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/elf.h | 91 ++++++++++++++++++++++++++-------------- arch/mips/kernel/binfmt_elfn32.c | 16 +------ arch/mips/kernel/binfmt_elfo32.c | 20 +-------- 3 files changed, 62 insertions(+), 65 deletions(-) commit 4a60ad51d660200adcb8bfecda472f0179ff22ec Author: Maciej W. Rozycki <macro@imgtec.com> Date: Fri May 13 07:20:55 2016 +0100 MIPS: ELF: Unify __MIPS_O32_FP64_MUST_BE_ZERO definitions Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13244/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/elf.h | 25 ++++++++++++------------- arch/mips/kernel/binfmt_elfo32.c | 12 ------------ 2 files changed, 12 insertions(+), 25 deletions(-) commit de704161aa05a594fcd596cb7f50e231c384355e Author: Maciej W. Rozycki <macro@imgtec.com> Date: Fri May 13 07:20:16 2016 +0100 MIPS: ELF: Deconditionalise ABI flags definitions Move the `mips_elf_abiflags_v0' structure and FP ABI flag macros outside #ifndef ELF_ARCH. These are public interfaces. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13243/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/elf.h | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) commit 4b62fad50efd1cff9017d3e4dcfcf5c4b6c13193 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:32 2016 +0100 MIPS: Print GuestCtl1 on machine check exception The GuestCtl1 CP0 register can contain the GuestID used for root TLB operations, which affects TLB matching. The other TLB registers are already dumped out to the log on a machine check exception due to multiple matching TLB entries, so also dump the value of the GuestCtl1 register if GuestIDs are supported. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13232/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lib/dump_tlb.c | 2 ++ 1 file changed, 2 insertions(+) commit 382208dc8c856b4d8ba602031412842b121decb2 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:31 2016 +0100 MIPS: dump_tlb: Preserve and dump GuestID The GuestID for root TLB operations (GuestCtl1.RID) is modified by TLB reads, so needs preserving by dump_tlb() like the ASID field of EntryHi. Also dump the GuestID of each entry if it exists alongside the ASID, as it forms an important part of the TLB entry when VZ guests are used. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13230/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lib/dump_tlb.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) commit 6ad816e77ed77538fe729050cf6631328c6113f7 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:30 2016 +0100 MIPS: Add probing & defs for VZ & guest features Add a few new cpu-features.h definitions for VZ sub-features, namely the existence of the CP0_GuestCtl0Ext, CP0_GuestCtl1, and CP0_GuestCtl2 registers, and support for GuestID to dialias TLB entries belonging to different guests. Also add certain features present in the guest, with the naming scheme cpu_guest_has_*. These are added separately to the main options bitfield since they generally parallel similar features in the root context. A few of these (FPU, MSA, watchpoints, perf counters, CP0_[X]ContextConfig registers, MAAR registers, and probably others in future) can be dynamically configured in the guest context, for which the cpu_guest_has_dyn_* macros are added. [ralf@linux-mips.org: Resolve merge conflict.] Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13231/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 98 +++++++++++++++ arch/mips/include/asm/cpu-info.h | 14 +++ arch/mips/include/asm/cpu.h | 5 + arch/mips/kernel/cpu-probe.c | 232 +++++++++++++++++++++++++++++++++++ 4 files changed, 349 insertions(+) commit 7eb91118227d71132ca2da06a9b376ba656171d9 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:29 2016 +0100 MIPS: Add guest CP0 accessors Add guest CP0 accessors and guest TLB operations along the same lines as the existing macros and functions for the root CP0. Signed-off-by: James Hogan <james.hogan@imgtec.com> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13229/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 341 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 330 insertions(+), 11 deletions(-) commit f913e9ea3946902f5443e703d70d5daf90f4498a Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:28 2016 +0100 MIPS: Add register definitions for VZ ASE registers Add various register definitions to <asm/mipsregs.h> for the coprocessor zero registers in the VZ ASE, namely CP0_GuestCtl0, CP0_GuestCtl0Ext, CP0_GuestCtl1, CP0_GuestCtl2, CP0_GuestCtl3, and CP0_GTOffset. Signed-off-by: James Hogan <james.hogan@imgtec.com> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13228/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 117 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) commit 9e575f753576d85e83ae0afc27eca9708259a797 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 15:50:27 2016 +0100 MIPS: Avoid magic numbers probing kscratch_mask The decode_config4() function reads kscratch_mask from CP0_Config4.KScrExist using a hard coded shift and mask. We already have a definition for the mask in mipsregs.h, so add a definition for the shift and make use of them. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13227/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 3 ++- arch/mips/kernel/cpu-probe.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 30228c40f0c6f0a93910325f120904505a4c39cc Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 13:50:53 2016 +0100 MIPS: Add perf counter feature Add CPU feature for standard MIPS r2 performance counters, as determined by the Config1.PC bit. Both perf_events and oprofile probe this bit, so lets combine the probing and change both to use cpu_has_perf. This will also be used for VZ support in KVM to know whether performance counters exist which can be exposed to guests. [ralf@linux-mips.org: resolve conflict.] Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Robert Richter <rric@kernel.org> Cc: linux-mips@linux-mips.org Cc: oprofile-list@lists.sf.net Patchwork: https://patchwork.linux-mips.org/patch/13226/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 4 ++++ arch/mips/include/asm/cpu.h | 1 + arch/mips/kernel/cpu-probe.c | 2 ++ arch/mips/kernel/perf_event_mipsxx.c | 4 +--- arch/mips/oprofile/op_model_mipsxx.c | 4 +--- 5 files changed, 9 insertions(+), 6 deletions(-) commit f18bdfa191df3947879f93519ce4a4985e5f5fce Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 13:50:52 2016 +0100 MIPS: Add defs & probing of [X]ContextConfig The CP0_[X]ContextConfig registers are present if CP0_Config3.CTXTC or CP0_Config3.SM are set, and provide more control over which bits of CP0_[X]Context are set to the faulting virtual address on a TLB exception. KVM/VZ will need to be able to save and restore these registers in the guest context, so add the relevant definitions and probing of the ContextConfig feature in the root context first. [ralf@linux-mips.org: resolve merge conflict.] Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13225/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 4 ++++ arch/mips/include/asm/cpu.h | 1 + arch/mips/include/asm/mipsregs.h | 6 ++++++ arch/mips/kernel/cpu-probe.c | 4 +++- 4 files changed, 14 insertions(+), 1 deletion(-) commit e06a1548f3043febb658b58ec5ccbc7d03a785af Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 13:50:51 2016 +0100 MIPS: Add defs & probing of BadInstr[P] registers The optional CP0_BadInstr and CP0_BadInstrP registers are written with the encoding of the instruction that caused a synchronous exception to occur, and the prior branch instruction if in a delay slot. These will be useful for instruction emulation in KVM, and especially for VZ support where reading guest virtual memory is a bit more awkward. Add CPU option numbers and cpu_has_* definitions to indicate the presence of each registers, and add code to probe for them using bits in the CP0_Config3 register. [ralf@linux-mips.org: resolve merge conflict.] Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13224/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 8 ++++++++ arch/mips/include/asm/cpu.h | 2 ++ arch/mips/include/asm/mipsregs.h | 3 +++ arch/mips/kernel/cpu-probe.c | 4 ++++ 4 files changed, 17 insertions(+) commit 37fb60f8e3f011c25c120081a73886ad8dbc42fd Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 13:50:50 2016 +0100 MIPS: Add defs & probing of extended CP0_EBase The CP0_EBase register may optionally have a write gate (WG) bit to allow the upper bits to be written, i.e. bits 31:30 on MIPS32 since r3 (to allow for an exception base outside of KSeg0/KSeg1 when segmentation control is in use) and bits 63:30 on MIPS64 (which also implies the extension of CP0_EBase to 64 bits long). The presence of this feature will need to be known about for VZ support in order to correctly save and restore all the bits of the guest CP0_EBase register, so add CPU feature definition and probing for this feature. Probing the WG bit on MIPS64 can be a bit fiddly, since 64-bit COP0 register access instructions were UNDEFINED for 32-bit registers prior to MIPS r6, and it'd be nice to be able to probe without clobbering the existing state, so there are 3 potential paths: - If we do a 32-bit read of CP0_EBase and the WG bit is already set, the register must be 64-bit. - On MIPS r6 we can do a 64-bit read-modify-write to set CP0_EBase.WG, since the upper bits will read 0 and be ignored on write if the register is 32-bit. - On pre-r6 cores, we do a 32-bit read-modify-write of CP0_EBase. This avoids the potentially UNDEFINED behaviour, but will clobber the upper 32-bits of CP0_EBase if it isn't a simple sign extension (which also requires us to ensure BEV=1 or modifying the exception base would be UNDEFINED too). It is hopefully unlikely a bootloader would set up CP0_EBase to a 64-bit segment and leave WG=0. [ralf@linux-mips.org: Resolved merge conflict.] Signed-off-by: James Hogan <james.hogan@imgtec.com> Tested-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13223/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 4 ++++ arch/mips/include/asm/cpu.h | 1 + arch/mips/include/asm/mipsregs.h | 3 +++ arch/mips/kernel/cpu-probe.c | 35 +++++++++++++++++++++++++++++++++++ 4 files changed, 43 insertions(+) commit 37af2f3077d9202f8f8d17f453c91c9d08e11c76 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 11 13:50:49 2016 +0100 MIPS: Define & use CP0_EBase bit definitions Add definitions for the bits & fields in the CP0_EBase register, and use them from a few different places in arch/mips which hardcoded these values. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Jayachandran C <jchandra@broadcom.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13222/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 10 +++++++++- arch/mips/kvm/trap_emul.c | 3 ++- arch/mips/netlogic/xlp/nlm_hal.c | 2 +- arch/mips/netlogic/xlr/setup.c | 2 +- 4 files changed, 13 insertions(+), 4 deletions(-) commit dc3ee608d6f16947b812c7fac33c18863acdc074 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:34:37 2016 -0700 MIPS: alchemy: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Cc: Manuel Lauss <manuel.lauss@gmail.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13134/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/alchemy/common/clock.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 9c938a0df074d4100de38ff967b97451f9b9ae7e Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:33:21 2016 -0700 MIPS: ath79: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Cc: Antony Pavlov <antonynpavlov@gmail.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13133/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/clock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f4703aa4df758def78e9a39cc5d1ff73c3ef51f Author: Aurelien Jarno <aurelien@aurel32.net> Date: Wed May 11 00:50:03 2016 +0200 MIPS: Octeon: detect and fix byte swapped initramfs Octeon machines support running in little endian mode. U-Boot usually runs in big endian-mode. Therefore the initramfs is loaded in big endian mode, and the kernel later tries to access it in little endian mode. This patch fixes that by detecting byte swapped initramfs using either the CPIO header or the header from standard compression methods, and byte swaps it if needed. It first checks that the header doesn't match in the native endianness to avoid false detections. It uses the kernel decompress library so that we don't have to maintain the list of magics if some decompression methods are added to the kernel. Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13219/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/setup.c | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit b47208091291ea2990b69eb59c72d04c7161303e Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue Feb 9 12:55:53 2016 -0800 MIPS: BMIPS: BMIPS4380 and BMIPS5000 support RIXI Make BMIPS4380 and BMIPS5000 advertise support for RIXI through cpu_probe_broadcom(). bmips_cpu_setup() needs to be called shortly after that, during prom_init() in order to enable the proper Broadcom-specific register to turn on RIXI and the "rotr" instruction. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: pgynther@google.com Cc: paul.burton@imgtec.com Cc: ddaney.cavm@gmail.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12507/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 ++ arch/mips/kernel/cpu-probe.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) commit 2e274768e4dd9565a31cd1979ed6d534cd4e656f Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue Feb 9 12:55:52 2016 -0800 MIPS: Move RIXI exception enabling after vendor-specific cpu_probe Some processors may not have the RIXI bit advertised in the Config3 register, not being a MIPS32R2 or R6 core, yet, they might be supporting it through a different way, which is overriden during vendor-specific cpu_probe(). Move the RIXI exceptions enabling after the vendor-specific cpu_probe() function has had a change to run and override the current CPU's options with MIPS_CPU_RIXI. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: pgynther@google.com Cc: paul.burton@imgtec.com Cc: ddaney.cavm@gmail.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12506/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cpu-probe.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 8256b17ecb028949d80c982d0f28ad46fe4e73d8 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue Feb 9 12:55:51 2016 -0800 MIPS: Allow RIXI to be used on non-R2 or R6 cores Some processors, like Broadcom's BMIPS4380 and BMIPS5000 support RIXI and the "rotr" instruction, which can be used to get a slightly more efficient page table layout. Introduce a CONFIG_CPU_HAS_RIXI such that those cores can benefit from this feature. Perform the conditional check updates where relevant. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: pgynther@google.com Cc: paul.burton@imgtec.com Cc: ddaney.cavm@gmail.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12505/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 5 +++++ arch/mips/include/asm/pgtable-bits.h | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) commit e56c7e18818dd721179f9ca95c77dd941a360384 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:11 2016 +0100 MIPS: mm: Panic if an XPA kernel is run without RIXI XPA kernels hardcode for the presence of RIXI - the PTE format & its handling presume RI & XI bits. Make this dependence explicit by panicing if we run on a system that violates it. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13125/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 3 +++ 1 file changed, 3 insertions(+) commit 4b6f99d307ed6c7a28b952bfb7b66fb26a6a4cf0 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Apr 19 09:25:10 2016 +0100 MIPS: mm: Don't do MTHC0 if XPA not present Performing an MTHC0 instruction without XPA being present will trigger a reserved instruction exception, therefore conditionalise the use of this instruction when building TLB handlers (build_update_entries()), and in __update_tlb(). This allows an XPA kernel to run on non XPA hardware without that instruction implemented, just like it can run on XPA capable hardware without XPA in use (with the noxpa kernel argument) or with XPA not configured in hardware. [paul.burton@imgtec.com: - Rebase atop other TLB work. - Add "mm" to subject. - Handle the __kmap_pgprot case.] Fixes: c5b367835cfc ("MIPS: Add support for XPA.") Signed-off-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: David Hildenbrand <dahi@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13124/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/init.c | 8 +++++--- arch/mips/mm/tlb-r4k.c | 6 ++++-- arch/mips/mm/tlbex.c | 16 ++++++++++------ 3 files changed, 19 insertions(+), 11 deletions(-) commit 2caa89b49b21737b2b7b6fce37cb323535188b06 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:09 2016 +0100 MIPS: mm: Simplify build_update_entries We can simplify build_update_entries by unifying the code for the 36 bit physical addressing with MIPS32 case with the general case, by using pte_off_ variables in all cases & handling the trivial _PAGE_GLOBAL_SHIFT == 0 case in build_convert_pte_to_entrylo. This leaves XPA as the only special case. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13123/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 37 ++++++++++++++++--------------------- 1 file changed, 16 insertions(+), 21 deletions(-) commit b4ebbb876dca9327cc964138f5558ca3c6832392 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:08 2016 +0100 MIPS: mm: Be more explicit about PTE mode bit handling The XPA case in iPTE_SW or's in software mode bits to the pte_low value (which is what actually ends up in the high 32 bits of EntryLo...). It does this presuming that only bits in the upper 16 bits of the 32 bit pte_low value will be set. Make this assumption explicit with a BUG_ON. A similar assumption is made for the hardware mode bits, which are or'd in with a single ori instruction. Make that assumption explicit with a BUG_ON too. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13122/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit bbeeffec6f14a04454906032e9322538535030dc Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:07 2016 +0100 MIPS: mm: Pass scratch register through to iPTE_SW Rather than hardcode a scratch register for the XPA case in iPTE_SW, pass one through from the work registers allocated by the caller. This allows for the XPA path to function correctly regardless of the work registers in use. Without doing this there are cases (where KScratch registers are unavailable) in which iPTE_SW will incorrectly clobber $1 despite it already being in use for the PTE or PTE pointer. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13121/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit f383219674b72f390911c60e1d8ae95e32622398 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Apr 19 09:25:06 2016 +0100 MIPS: mm: Don't clobber $1 on XPA TLB refill For XPA kernels build_update_entries() uses $1 (at) as a scratch register, but doesn't arrange for it to be preserved, so it will always be clobbered by the TLB refill exception. Although this register normally has a very short lifetime that doesn't cross memory accesses, TLB refills due to instruction fetches (either on a page boundary or after preemption) could clobber live data, and its easy to reproduce the clobber with a little bit of assembler code. Note that the use of a hardware page table walker will partly mask the problem, as the TLB refill handler will not always be invoked. This is fixed by avoiding the use of the extra scratch register. The pte_high parts (going into the lower half of the EntryLo registers) are loaded and manipulated separately so as to keep the PTE pointer around for the other halves (instead of storing in the scratch register), and the pte_low parts (going into the high half of the EntryLo registers) are masked with 0x00ffffff using an ext instruction (instead of loading 0x00ffffff into the scratch register and AND'ing). [paul.burton@imgtec.com: - Rebase atop other TLB work. - Use ext instead of an sll, srl sequence. - Use cpu_has_xpa instead of #ifdefs. - Modify commit subject to include "mm".] Fixes: c5b367835cfc ("MIPS: Add support for XPA.") Signed-off-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13120/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) commit 7b2cb64f91f25a7293b10054e20d1c0734ffab6f Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:05 2016 +0100 MIPS: mm: Fix MIPS32 36b physical addressing (alchemy, netlogic) There are 2 distinct cases in which a kernel for a MIPS32 CPU (CONFIG_CPU_MIPS32=y) may use 64 bit physical addresses (CONFIG_PHYS_ADDR_T_64BIT=y): - 36 bit physical addressing as used by RMI Alchemy & Netlogic XLP/XLR CPUs. - MIPS32r5 eXtended Physical Addressing (XPA). These 2 cases are distinct in that they require different behaviour from the kernel - the EntryLo registers have different formats. Until Linux v4.1 we only supported the first case, with code conditional upon the 2 aforementioned Kconfig variables being set. Commit c5b367835cfc ("MIPS: Add support for XPA.") added support for the second case, but did so by modifying the code that existed for the first case rather than treating the 2 cases as distinct. Since the EntryLo registers have different formats this breaks the 36 bit Alchemy/XLP/XLR case. Fix this by splitting the 2 cases, with XPA cases now being conditional upon CONFIG_XPA and the non-XPA case matching the code as it existed prior to commit c5b367835cfc ("MIPS: Add support for XPA."). Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reported-by: Manuel Lauss <manuel.lauss@gmail.com> Tested-by: Manuel Lauss <manuel.lauss@gmail.com> Fixes: c5b367835cfc ("MIPS: Add support for XPA.") Cc: James Hogan <james.hogan@imgtec.com> Cc: David Daney <david.daney@cavium.com> Cc: Huacai Chen <chenhc@lemote.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: David Hildenbrand <dahi@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Ingo Molnar <mingo@kernel.org> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: stable@vger.kernel.org # v4.1+ Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13119/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable-32.h | 27 +++++++++++++++-- arch/mips/include/asm/pgtable-bits.h | 29 +++++++++++++++--- arch/mips/include/asm/pgtable.h | 57 +++++++++++++++++++++++++++++++----- arch/mips/mm/init.c | 4 ++- arch/mips/mm/tlbex.c | 35 ++++++++++++++-------- 5 files changed, 125 insertions(+), 27 deletions(-) commit 745f35587846249b392aa548b4c5f54cd69ed688 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:04 2016 +0100 MIPS: mm: Unify pte_page definition The same definition for pte_page is duplicated for the MIPS32 PHYS_ADDR_T_64BIT case & the generic case. Unify them by moving a single definition outside of preprocessor conditionals. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13117/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable-32.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 780602d740fc0b723ea3a05bd7f35d2d7f31aa68 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:03 2016 +0100 MIPS: mm: Standardise on _PAGE_NO_READ, drop _PAGE_READ Ever since support for RI/XI was implemented by commit 6dd9344cfc41 ("MIPS: Implement Read Inhibit/eXecute Inhibit") we've had a mixture of _PAGE_READ & _PAGE_NO_READ bits. Rather than keep both around, switch away from using _PAGE_READ to determine page presence & instead invert the use to _PAGE_NO_READ. Wherever we formerly had no definition for _PAGE_NO_READ, change what was _PAGE_READ to _PAGE_NO_READ. The end result is that we consistently use _PAGE_NO_READ to determine whether a page is readable, regardless of whether RI/XI is implemented. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: David Daney <david.daney@cavium.com> Cc: Huacai Chen <chenhc@lemote.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13116/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable-bits.h | 19 ++++--------------- arch/mips/include/asm/pgtable.h | 23 +++++++---------------- arch/mips/mm/tlbex.c | 13 ++++--------- 3 files changed, 15 insertions(+), 40 deletions(-) commit 694977006a7ba71e33e1f5df4f66ffd5ae19ec84 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:02 2016 +0100 MIPS: Use enums to make asm/pgtable-bits.h readable asm/pgtable-bits.h has grown to become an unreadable mess of #ifdef directives defining bits conditionally upon other bits all at the preprocessing stage, for no good reason. Instead of having quite so many #ifdef's, simply use enums to provide sequential numbering for bit shifts, without having to keep track manually of what the last bit defined was. Masks are defined separately, after the shifts, which allows for most of their definitions to be reused for all systems rather than duplicated. This patch is not intended to make any behavioural change to the code - all bits should be used in the same way they were before this patch. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13115/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable-bits.h | 189 +++++++++++++++-------------------- 1 file changed, 81 insertions(+), 108 deletions(-) commit 253f0d4a5fdcba9367b83df7fb504407efc20ec2 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Apr 19 09:25:01 2016 +0100 MIPS: Remove redundant asm/pgtable-bits.h inclusions asm/pgtable-bits.h is included in 2 assembly files and thus has to ifdef around C code, however nothing defined by the header is used in either of the assembly files that include it. Remove the redundant inclusions such that asm/pgtable-bits.h doesn't need to #ifdef around C code, for cleanliness and in preparation for later patches which will add more C. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: Jonas Gorski <jogo@openwrt.org> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13114/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable-bits.h | 2 -- arch/mips/kernel/head.S | 1 - arch/mips/kernel/r4k_switch.S | 1 - 3 files changed, 4 deletions(-) commit 515511a7920c69aebf7f5fef0cb8e1df6767f34c Merge: 180bc41 8f65881 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:27:16 2016 +0100 Merge remote-tracking branch 'asoc/topic/hdmi' into asoc-next commit 180bc41ad11b9a7ec5b420fbcef6570163d09204 Merge: e449f7a ca0d879 fbb88b5 aeea2fd 4d24585 027db2e Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:27:01 2016 +0100 Merge remote-tracking branches 'asoc/topic/es8328', 'asoc/topic/find-dai', 'asoc/topic/fsl', 'asoc/topic/fsl-sai' and 'asoc/topic/fsl-ssi' into asoc-next commit e449f7a394dfa444d2e3c15be2cffb758c79a6c9 Merge: 1c21e63 ddecd14 3fafd14 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:46 2016 +0100 Merge remote-tracking branches 'asoc/topic/davinci' and 'asoc/topic/dwc' into asoc-next commit 1c21e63465d1cbe051256951236a694c0a32e39d Merge: 3b15d43 beff053 de06f22 abc189e ae48a35 b58cea7 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:43 2016 +0100 Merge remote-tracking branches 'asoc/topic/bcm2835', 'asoc/topic/cs42l56', 'asoc/topic/da7213', 'asoc/topic/da7218' and 'asoc/topic/da7219' into asoc-next commit 3b15d43bdf9f51c81701663f35db57e10543f405 Merge: 87b88aa 721be3b b6bf328 80833ff 896491b Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:35 2016 +0100 Merge remote-tracking branches 'asoc/topic/adsp', 'asoc/topic/ak4624', 'asoc/topic/atmel' and 'asoc/topic/au1x' into asoc-next commit 87b88aafbfce5a08b04f3ffba05a92ea6a342cdb Merge: e74ac45 381437d Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:26 2016 +0100 Merge remote-tracking branch 'asoc/topic/rt5645' into asoc-next commit e74ac45d892f3c03756bd9e9fb4d242fe08cb35d Merge: c988e26 97d3ddd Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:23 2016 +0100 Merge remote-tracking branch 'asoc/topic/pcm5102' into asoc-next commit c988e26130132813e3550a7b97ab2ed2ae0455eb Merge: 3530215 b2047e9 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:22 2016 +0100 Merge remote-tracking branch 'asoc/topic/intel' into asoc-next commit 35302156ea791f96bdc7e0ca3c44cb25341fbcb1 Merge: bf10262 e92077c Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:21 2016 +0100 Merge remote-tracking branch 'asoc/topic/imx' into asoc-next commit bf10262159cfd7ed76b777927e7cba628cea85ba Merge: f84025b 73fe01c Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:20 2016 +0100 Merge remote-tracking branch 'asoc/topic/dmaengine' into asoc-next commit f84025ba12ec843daf81511feef764f6b5f1972f Merge: 86d811d 3290217 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:20 2016 +0100 Merge remote-tracking branch 'asoc/topic/dapm' into asoc-next commit 86d811d898cdd823d3ee35f6441c72216ae89e1e Merge: 44549e8 823ecdd 3cc6185 7e885d2 b9c17f1 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:26:15 2016 +0100 Merge remote-tracking branches 'asoc/fix/davinci', 'asoc/fix/fsl-ssi', 'asoc/fix/rockchip' and 'asoc/fix/rt286' into asoc-linus commit 4f38c566a0967ce9291537ba04891391681a7661 Merge: 39d652e ae714c3 74d8b45 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:49 2016 +0100 Merge remote-tracking branches 'regulator/topic/tps6524x' and 'regulator/topic/twl' into regulator-next commit 39d652e0660bbad6a90a21042dc9f22584dfaabd Merge: eb76d84 bc0868c b1d21a2 9e9daa0 94be46b Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:46 2016 +0100 Merge remote-tracking branches 'regulator/topic/pwm', 'regulator/topic/qcom-spmi', 'regulator/topic/rk808' and 'regulator/topic/s2mps11' into regulator-next commit eb76d8407ced8d96eb3bcf3112348b8de5bd1c02 Merge: ce59ded a959730 d2d5437 724fef5 6c7d614 99cf3af Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:38 2016 +0100 Merge remote-tracking branches 'regulator/topic/max77686', 'regulator/topic/max8973', 'regulator/topic/maxim', 'regulator/topic/palmas' and 'regulator/topic/pv88080' into regulator-next commit ce59dedfef302216d1ee93d5089d7dad59bd13fa Merge: 78d5501 e57cbb7 40e1d79 7cb7348 994aae3 5aa4359 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:34 2016 +0100 Merge remote-tracking branches 'regulator/topic/fan53555', 'regulator/topic/lp3971', 'regulator/topic/lp3972', 'regulator/topic/lp873x' and 'regulator/topic/max77620' into regulator-next commit 78d5501cf41d25a2a78dd571d91fee3e1e271d3f Merge: 8595bb2 6a0028b 8a34e97 2d80a91 abf2f82 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:27 2016 +0100 Merge remote-tracking branches 'regulator/topic/can-change', 'regulator/topic/constrain', 'regulator/topic/debugfs' and 'regulator/topic/doc' into regulator-next commit 8595bb27cebe8b823167fd11b2b506f2e59e83f5 Merge: ab36885 1a4d5a3 c5c9c2d 162c5a3 f2e6721 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:08 2016 +0100 Merge remote-tracking branches 'regulator/topic/abb', 'regulator/topic/act8865', 'regulator/topic/as3722' and 'regulator/topic/axp20x' into regulator-next commit ab3688541d72cae7570840c7e3c7770b35adc0ba Merge: 170b649 45389c4 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:23:01 2016 +0100 Merge remote-tracking branch 'regulator/topic/supply' into regulator-next commit 170b649e40c0dac86eba6bd446fc79dd3b38c7ea Merge: 75941a1 de4a54c Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:57 2016 +0100 Merge remote-tracking branch 'regulator/topic/core' into regulator-next commit 75941a1ba32d36fe6230a6388f10c493b3f6232b Merge: 93878cd fef9501 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:55 2016 +0100 Merge remote-tracking branch 'regulator/topic/bypass' into regulator-next commit 93878cd540500884b2ea428f620c8e1426fc4d6d Merge: 5535fc7 45fa203 a215137 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:43 2016 +0100 Merge remote-tracking branches 'regulator/fix/constrain' and 'regulator/fix/defer' into regulator-linus commit 5535fc7958efbd68542def0abd6c9e6b3a9e6812 Merge: e9cb77d 2c0a303 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:41 2016 +0100 Merge remote-tracking branch 'regulator/fix/core' into regulator-linus commit e9cb77d03ca1055d0d65483bc972a5a0e8d3eeed Merge: 099cba2 dd1a571 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:38 2016 +0100 Merge remote-tracking branch 'regulator/fix/bypass' into regulator-linus commit 099cba20b211dd0ca66b0991a32bb22dc64bdcb8 Merge: 44549e8 9689dab Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 14:22:36 2016 +0100 Merge tag 'regulator-fix-v4.6-rc7' into regulator-linus regulator: Fixes for v4.6 A small collection of driver specific fixes for the regulator subsysetem: - Fix handling of probe deferral for GPIO regulators. - Fix a typo in the module alias for DA9053. - Fix the definition of BUCK9 in the S2MPS11 driver. This change looks larger than it is because an irregularity in the hardware means that the macro used to define bucks 6-10 needs duplicating and tweaking to have a separate macro for 9. - Fix a series of errors in the definitions of the LDOs the AXP20x regulators, some of which had always been present and some of which were introduced in the merge window. # gpg: Signature made Fri 13 May 2016 11:31:13 BST using RSA key ID 5D5487D0 # gpg: key CD7BEEBC: no public key for trusted key - skipped # gpg: key CD7BEEBC marked as ultimately trusted # gpg: key AF88CD16: no public key for trusted key - skipped # gpg: key AF88CD16 marked as ultimately trusted # gpg: key 16005C11: no public key for trusted key - skipped # gpg: key 16005C11 marked as ultimately trusted # gpg: key 5621E907: no public key for trusted key - skipped # gpg: key 5621E907 marked as ultimately trusted # gpg: key 5C6153AD: no public key for trusted key - skipped # gpg: key 5C6153AD marked as ultimately trusted # gpg: Good signature from "Mark Brown <broonie@sirena.org.uk>" # gpg: aka "Mark Brown <broonie@debian.org>" # gpg: aka "Mark Brown <broonie@kernel.org>" # gpg: aka "Mark Brown <broonie@tardis.ed.ac.uk>" # gpg: aka "Mark Brown <broonie@linaro.org>" # gpg: aka "Mark Brown <Mark.Brown@linaro.org>" commit d3450e009f9038f3c7824f64695fa51ef2474e08 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:40:10 2016 +0100 drm/vmwgfx: add extern C guard for the UAPI header Cc: Thomas Hellstrom <thellstrom@vmware.com> Cc: Brian Paul <brianp@vmware.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Sinclair Yeh <syeh@vmware.com> include/uapi/drm/vmwgfx_drm.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit 3818081565b01f126c1fcb22f810466fa589cf97 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:38:49 2016 +0100 drm/virgl: add extern C guard for the UAPI header Cc: Dave Airlie <airlied@redhat.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/virtgpu_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit b6c2b64223d27ca579cce61fa5ffbf71b3f12a38 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:37:48 2016 +0100 drm/via: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/via_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 6a982350f892c286c645a6fe0e1da1f869a0c43f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:36:57 2016 +0100 drm/vc4: add extern C guard for the UAPI header Cc: Eric Anholt <eric@anholt.net> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/vc4_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 7aa8ceeb5709bddd2202f637101b69c81af732c5 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:35:50 2016 +0100 drm/tegra: add extern C guard for the UAPI header Cc: Erik Faye-Lund <kusmabite@gmail.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Thierry Reding <treding@nvidia.com> include/uapi/drm/tegra_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 81dda38710ffe1fb94e755235e60f10d7e63f51b Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri May 13 13:59:03 2016 +0100 drm/sis: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/sis_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit ea526b7f17a4f27202aa368a6ac4668826f75d4a Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:14:34 2016 +0100 drm/savage: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/savage_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 6db26a941461cc5a544c737cf654c346b2a8da07 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:13:24 2016 +0100 drm/radeon: add extern C guard for the UAPI header Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/radeon_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 99be554c23096ff35fb49d94df730168b1baece3 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:12:25 2016 +0100 drm/r128: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/r128_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 485c40b467a25a4e376d283c7bc679b6d20caa52 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:09:39 2016 +0100 drm/qxl: add extern C guard for the UAPI header Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/qxl_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit c92378a06181456c4d8e45a33764c8524c15b99b Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:06:40 2016 +0100 drm/omap: add extern C guard for the UAPI header Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com> include/uapi/drm/omap_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit c6734c689a26591fe43946ffa8911f22e7c631c6 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:05:47 2016 +0100 drm/nouveau: drop drm/ prefix from include Similar to the rest of the DRM UAPI - these are to be imported unmodified into libdrm. In current form that's impossible. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Ben Skeggs <bskeggs@redhat.com> include/uapi/drm/nouveau_drm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8daf6359c48dc42979463f5cd575948b46a8143b Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:05:06 2016 +0100 drm/nouveau: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Ben Skeggs <bskeggs@redhat.com> include/uapi/drm/nouveau_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit a62424e29dc33fdf1cf9efadfbf54deefbcfe7bf Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:03:46 2016 +0100 drm/msm: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Rob Clark <robdclark@gmail.com> (over irc) include/uapi/drm/msm_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit c56e046f17a40571cf2bddd0edaeafa769ffba9a Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:01:39 2016 +0100 drm/mga: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/mga_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit b1c1f5c400f4c5dfd5405c210fcc9e019b734335 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 19:00:35 2016 +0100 drm/i915: add extern C guard for the UAPI header Cc: Jani Nikula <jani.nikula@linux.intel.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Daniel Vetter <daniel.vetter@intel.com> include/uapi/drm/i915_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 79e7328db71350e652a963aa6049d13e272a6d24 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:59:30 2016 +0100 drm/i810: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> include/uapi/drm/i810_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 202bae52934d4eb79ffaebf49f49b1cc64d8e40b Author: Joe Thornber <ejt@redhat.com> Date: Wed May 4 14:12:42 2016 -0400 dm thin: unroll issue_discard() to create longer discard bio chains There is little benefit to doing this but it does structure DM thinp's code to more cleanly use the __blkdev_issue_discard() interface -- particularly in passdown_double_checking_shared_status(). Signed-off-by: Joe Thornber <ejt@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-thin.c | 108 +++++++++++++++++++++++++++++++++------------------ 1 file changed, 71 insertions(+), 37 deletions(-) commit 3dba53a958a758fe7bed5002f6a2846e1acefe8e Author: Mike Snitzer <snitzer@redhat.com> Date: Mon May 2 20:16:21 2016 -0400 dm thin: use __blkdev_issue_discard for async discard support With commit 38f25255330 ("block: add __blkdev_issue_discard") DM thinp no longer needs to carry its own async discard method. Signed-off-by: Mike Snitzer <snitzer@redhat.com> Acked-by: Joe Thornber <ejt@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/md/dm-thin.c | 70 ++++++++++++---------------------------------------- 1 file changed, 16 insertions(+), 54 deletions(-) commit 13e4f8a695aa1dc7c94525047fc2ffb9abc8125e Author: Mike Snitzer <snitzer@redhat.com> Date: Wed May 4 15:05:44 2016 -0400 dm thin: remove __bio_inc_remaining() and switch to using bio_inc_remaining() DM thinp's use of bio_inc_remaining() is critical to ensure the original parent discard bio isn't completed before sub-discards have. DM thinp needs this due to the extra quiescing that occurs, via multiple DM thinp mappings, while processing large discards. As such DM thinp must build the async discard bio chain after some delay -- so bio_inc_remaining() is used to enable DM thinp to take a reference on the original parent discard bio for each mapping. This allows the immediate use of bio_endio() on that discard bio; but with the understanding that the actual completion won't occur until each of the sub-discards' per-mapping references are dropped. Signed-off-by: Mike Snitzer <snitzer@redhat.com> Acked-by: Joe Thornber <ejt@redhat.com> drivers/md/dm-thin.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 4c9971ca6a172e70f52a7f9b6796e843c3f70293 Author: Heinz Mauelshagen <heinzm@redhat.com> Date: Fri Apr 29 18:59:56 2016 +0200 dm raid: make sure no feature flags are set in metadata Given we don't yet support any feature flags in the dm-raid ondisk metadata (see: 'features' member of 'struct dm_raid_superblock'), add a check to ensure no flags are actually set, if any features are set reject the activation of the RAID mapping. This is to prevent possible data corruption in case of a kernel downgrade when there'll potentially be feature flags set by a future dm-raid target. Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-raid.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 445a64214285073ebc02af633a8a149e1522b7cb Author: Jose Abreu <Jose.Abreu@synopsys.com> Date: Thu Apr 21 18:19:35 2016 +0100 arc: axs10x: Add DT bindings for I2S PLL Clock Add device tree bindings for AXS10X I2S PLL Clock driver. Acked-by: Alexey Brodkin <abrodkin@synopsys.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> Signed-off-by: Jose Abreu <joabreu@synopsys.com> arch/arc/boot/dts/axs10x_mb.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 37a96bedae42317e85dcb1a5064a3ef39ded338c Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:58:35 2016 +0100 drm/exynos: add extern C guard for the UAPI header Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/exynos_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 60ef910d0d7f007c805c2824906d4d6ea24f7890 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:54:33 2016 +0100 drm/etnaviv: add extern C guard for the UAPI header Cc: Lucas Stach <l.stach@pengutronix.de> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Christian Gmeiner <christian.gmeiner@gmail.com> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> include/uapi/drm/etnaviv_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit ebbb0e5cfd2ceb1150b1af7f9fcf7aeebfb1b69f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:49:00 2016 +0100 drm: add extern C guard for the UAPI headers Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/drm.h | 16 ++++++++++++++++ include/uapi/drm/drm_fourcc.h | 8 ++++++++ include/uapi/drm/drm_mode.h | 8 ++++++++ include/uapi/drm/drm_sarea.h | 8 ++++++++ 4 files changed, 40 insertions(+) commit 1224649a9c842b4bb2ba4bd06af0c24d2b941ff0 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:47:05 2016 +0100 drm/armada: add extern C guard for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> include/uapi/drm/armada_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit cfa7152f1cfeedba7c4ab3abcb4accee94cc2c0f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 7 18:45:18 2016 +0100 drm/amdgpu: add extern C guard for the UAPI header Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> include/uapi/drm/amdgpu_drm.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit ab366b40b8513e7590858229ecbb5e1434a52b54 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed May 11 11:59:23 2016 -0400 fbdev: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/via/accel.c | 2 +- drivers/video/fbdev/via/via-core.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 14bc241443e126c62fcbf571b7d4c79740debc58 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Apr 19 09:25:00 2016 +0100 MIPS: Fix HTW config on XPA kernel without LPA enabled The hardware page table walker (HTW) configuration is broken on XPA kernels where XPA couldn't be enabled (either nohtw or the hardware doesn't support it). This is because the PWSize.PTEW field (PTE width) was only set to 8 bytes (an extra shift of 1) in config_htw_params() if PageGrain.ELPA (enable large physical addressing) is set. On an XPA kernel though the size of PTEs is fixed at 8 bytes regardless of whether XPA could actually be enabled. Fix the initialisation of this field based on sizeof(pte_t) instead. Fixes: c5b367835cfc ("MIPS: Add support for XPA.") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13113/ Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/tlbex.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 12822570a29bdc12c69fca2c021753cb5ce319c5 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Apr 19 09:24:59 2016 +0100 MIPS: Separate XPA CPU feature into LPA and MVH XPA (eXtended Physical Addressing) should be detected as a combination of two architectural features: - Large Physical Address (as per Config3.LPA). With XPA this will be set on MIPS32r5 cores, but it may also be set for MIPS64r2 cores too. - MTHC0/MFHC0 instructions (as per Config5.MVH). With XPA this will be set, but it may also be set in VZ guest context even when Config3.LPA in the guest context has been cleared by the hypervisor. As such, XPA is only usable if both bits are set. Update CPU features to separate these two features, with cpu_has_xpa requiring both to be set. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13112/ Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 8 +++++++- arch/mips/include/asm/cpu.h | 3 ++- arch/mips/kernel/cpu-probe.c | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) commit ab4a92e66741b35ca12f8497896bafbe579c28a1 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:55 2016 +0100 MIPS: math-emu: Fix jalr emulation when rd == $0 When emulating a jalr instruction with rd == $0, the code in isBranchInstr was incorrectly writing to GPR $0 which should actually always remain zeroed. This would lead to any further instructions emulated which use $0 operating on a bogus value until the task is next context switched, at which point the value of $0 in the task context would be restored to the correct zero by a store in SAVE_SOME. Fix this by not writing to rd if it is $0. Fixes: 102cedc32a6e ("MIPS: microMIPS: Floating point support.") Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: stable <stable@vger.kernel.org> # v3.10 Patchwork: https://patchwork.linux-mips.org/patch/13160/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/cp1emu.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit db57f29d50683afd75c7f8b9908af7669837c3a9 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:54 2016 +0100 MIPS: math-emu: Fix m{add,sub}.s shifts The code in _sp_maddf (formerly ieee754sp_madd) appears to have been copied verbatim from ieee754sp_add, and although it's adding the unpacked "r" & "z" floats it kept using macros that operate on "x" & "y". This led to the addition being carried out incorrectly on some mismash of the product, accumulator & multiplicand fields. Typically this would lead to the assertions "ze == re" & "ze <= SP_EMAX" failing since ze & re hadn't been operated upon. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Fixes: e24c3bec3e8e ("MIPS: math-emu: Add support for the MIPS R6 MADDF FPU instruction") Cc: Adam Buchbinder <adam.buchbinder@gmail.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13159/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/ieee754sp.c | 3 ++- arch/mips/math-emu/ieee754sp.h | 16 +++++++--------- arch/mips/math-emu/sp_add.c | 6 ++++-- arch/mips/math-emu/sp_maddf.c | 13 ++++++++----- arch/mips/math-emu/sp_sub.c | 6 ++++-- 5 files changed, 25 insertions(+), 19 deletions(-) commit 5c18c936b52ae80db5737849e11f436e79b84b2d Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:53 2016 +0100 MIPS: math-emu: Fix code indentation A line incrementing the re variable was indented a level too deep in ieee754dp_mul, making the code unclear to read. Fix the indentation. This appears to have been copied verbatim along with the rest of the multiplication code to ieee754dp_maddf, now _dp_maddf, too so fix the indentation there too. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13158/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/dp_maddf.c | 2 +- arch/mips/math-emu/dp_mul.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 95bff2410cdccfe2cf4b99f4e86165956767740e Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:52 2016 +0100 MIPS: math-emu: Fix bit-width in ieee754dp_{mul, maddf, msubf} comments A comment in ieee754dp_mul indicates that the code is about to perform a 32b x 32b multiplication & keep the high 32b of the result. It appears this was copied from the single-precision multiplication code, since the code actually goes on to perform a 64b x 64b multiplication & keep the high 64b of the result. Fix the comment to indicate 64b. It appears also that this comment was copied verbatim along with the rest of the multiplication code into ieee754dp_maddf, which has since been renamed _dp_maddf. Fix the same issue there. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13157/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/dp_maddf.c | 2 +- arch/mips/math-emu/dp_mul.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit e2d11e1a8398b7447d337add50521a5abc6267fd Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:51 2016 +0100 MIPS: math-emu: Add z argument macros Introduce macros for handling the "z" argument to maddf & msubf, making its handling consistent with that of the "x" & "y" arguments rather than open-coding equivalents. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13156/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/dp_maddf.c | 9 ++++----- arch/mips/math-emu/ieee754dp.h | 1 + arch/mips/math-emu/ieee754int.h | 10 ++++++++++ arch/mips/math-emu/ieee754sp.h | 1 + arch/mips/math-emu/sp_maddf.c | 8 ++++---- 5 files changed, 20 insertions(+), 9 deletions(-) commit d728f6709bcc49c98097485e3561f1faaf52b4f3 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:50 2016 +0100 MIPS: math-emu: Unify ieee754dp_m{add,sub}f The code for emulating MIPSr6 madd.d & msub.d instructions has previously been implemented as 2 different functions, namely ieee754dp_maddf & ieee754dp_msubf. The difference in behaviour of these 2 instructions is merely the sign of the product, so we can easily share the code implementing them. Do this for the double precision variant, removing the original ieee754dp_msubf in favor of reusing the code from ieee754dp_maddf. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13155/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/Makefile | 2 +- arch/mips/math-emu/dp_maddf.c | 22 +++- arch/mips/math-emu/dp_msubf.c | 269 ------------------------------------------ 3 files changed, 21 insertions(+), 272 deletions(-) commit 6162051e87f6ea785cb51ad99bdcf8eb0bd9cb07 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:49 2016 +0100 MIPS: math-emu: Unify ieee754sp_m{add,sub}f The code for emulating MIPSr6 madd.s & msub.s instructions has previously been implemented as 2 different functions, namely ieee754sp_maddf & ieee754sp_msubf. The difference in behaviour of these 2 instructions is merely the sign of the product, so we can easily share the code implementing them. Do this for the single precision variant, removing the original ieee754sp_msubf in favor of reusing the code from ieee754sp_maddf. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13154/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/Makefile | 2 +- arch/mips/math-emu/sp_maddf.c | 22 +++- arch/mips/math-emu/sp_msubf.c | 258 ------------------------------------------ 3 files changed, 21 insertions(+), 261 deletions(-) commit 4b820d95dc53c15e6e727da964430a3ed60e05ef Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:48 2016 +0100 MIPS: math-emu: Emulate MIPSr6 sel.fmt instruction Add support for emulating the MIPSr6 sel.fmt instruction, which was previously missing from the FPU emulation code. This instruction selects its result from 2 possible source registers, based upon bit 0 of the destination register, and is valid only for S (single) & D (double) data types. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13153/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/cp1emu.c | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) commit b6d5c4eda7a771e72b3640500e026d72c4f64419 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:47 2016 +0100 MIPS: inst: Declare fsel_op for sel.fmt instruction Declare the opcode for the MIPSr6 sel.fmt instruction, as fsel_op in order to match other FP op names. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13152/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/uapi/asm/inst.h | 1 + 1 file changed, 1 insertion(+) commit ac1496980f1d2752f26769f5db63afbc9ac2b603 Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:46 2016 +0100 MIPS: Fix BC1{EQ,NE}Z return offset calculation The conditions for branching when emulating the BC1EQZ & BC1NEZ instructions were backwards, leading to each of those instructions being treated as the other. Fix this by reversing the conditions, and clear up the code a little for readability & checkpatch. Fixes: c8a34581ec09 ("MIPS: Emulate the BC1{EQ,NE}Z FPU instructions") Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13151/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/branch.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) commit 93583e178ebfdd2fadf950eef1547f305cac12ca Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Apr 21 14:04:45 2016 +0100 MIPS: math-emu: Fix BC1{EQ,NE}Z emulation The conditions for branching when emulating the BC1EQZ & BC1NEZ instructions were backwards, leading to each of those instructions being treated as the other. Fix this by reversing the conditions, and clear up the code a little for readability & checkpatch. Fixes: c909ca718e8f ("MIPS: math-emu: Emulate missing BC1{EQ,NE}Z instructions") Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13150/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/cp1emu.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit ed47e1533292e26baaec1b5ed7d425690289d5df Author: Rabin Vincent <rabinv@axis.com> Date: Thu Apr 28 11:03:09 2016 +0200 MIPS: Add support for extending builtin cmdline Allow the builtin command line to be extended by what the bootloader passes in. For example, the bootloader can pass specific arguments depending on the boot mode, and these should override the defaults in the builtin cmdline. The default MIPS_CMDLINE_FROM_BOOTLOADER option prepends the bootloader's cmdline to the builtin cmdline so is not suitable for this purpose. Signed-off-by: Rabin Vincent <rabinv@axis.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13181/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 4 ++++ arch/mips/kernel/setup.c | 8 ++++++++ 2 files changed, 12 insertions(+) commit e54ad8c56258af3b414a3e5707a45c18f1db69e1 Author: Rabin Vincent <rabinv@axis.com> Date: Thu Apr 28 11:03:08 2016 +0200 MIPS: Don't add leading spacing to command lines The leading spaces don't affect functionality but are unnecessary. Signed-off-by: Rabin Vincent <rabinv@axis.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13180/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/setup.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 105c22c5cf3f420ce5ab792b3577ef330f1f6133 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 29 17:29:29 2016 +0100 MIPS: genex: Indent delay slots & clean whitespace Various branches and jumps in noreorder parts of genex.S don't have their delay slot instructions indented conventionally with the extra space. Fix these, as well as various other inconsistent whitespace problems in this file, such as spaces used after some opcodes instead of a tab. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13196/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/genex.S | 56 ++++++++++++++++++++++++------------------------ 1 file changed, 28 insertions(+), 28 deletions(-) commit 2db003a5ddee986d4bc67c069ee3aa1b1b320f1d Author: Paul Burton <paul.burton@imgtec.com> Date: Fri May 6 14:36:24 2016 +0100 MIPS: Support extended ASIDs Add support for extended ASIDs as determined by the Config4.AE bit. Since the only supported CPUs known to implement this are Netlogic XLP and MIPS I6400, select this variable ASID support based upon CONFIG_CPU_XLP and CONFIG_CPU_MIPSR6. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Jayachandran C. <jchandra@broadcom.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13211/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 6 ++++++ arch/mips/include/asm/cpu-info.h | 14 ++++++++++++++ arch/mips/kernel/asm-offsets.c | 10 ++++++++++ arch/mips/kernel/cpu-probe.c | 13 +++++++++++++ arch/mips/kernel/genex.S | 2 +- arch/mips/kvm/locore.S | 14 ++++++++++++++ 6 files changed, 58 insertions(+), 1 deletion(-) commit 4edf00a46bee692f62578b5280c5774f9b65a08f Author: Paul Burton <paul.burton@imgtec.com> Date: Fri May 6 14:36:23 2016 +0100 MIPS: Retrieve ASID masks using function accepting struct cpuinfo_mips In preparation for supporting variable ASID masks, retrieve ASID masks using functions in asm/cpu-info.h which accept struct cpuinfo_mips. This will allow those functions to determine the ASID mask based upon the CPU in a later patch. This also allows for the r3k & r8k cases to be handled in Kconfig, which is arguably cleaner than the previous #ifdefs. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13210/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 11 ++++++++++ arch/mips/include/asm/cpu-info.h | 10 +++++++++ arch/mips/include/asm/mmu_context.h | 41 ++++++++++++++++--------------------- arch/mips/kernel/traps.c | 2 +- arch/mips/kvm/tlb.c | 30 +++++++++++++++++---------- arch/mips/lib/dump_tlb.c | 10 +++++---- arch/mips/lib/r3k_dump_tlb.c | 9 ++++---- arch/mips/mm/tlb-r3k.c | 24 +++++++++++++--------- arch/mips/mm/tlb-r4k.c | 2 +- arch/mips/mm/tlb-r8k.c | 2 +- 10 files changed, 86 insertions(+), 55 deletions(-) commit f1b711c638c7df56112eff8e9661c91202782516 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 6 14:36:22 2016 +0100 MIPS: KVM/locore.S: Relax noat Now that the at register ($1) is no longer saved by __kvm_mips_vcpu_run(), relax the noat assembler directive so that it only applies around code where at is restored before entering guest, and saved after exiting guest. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13209/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kvm/locore.S | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit 1300fcd5e1754b654954717410c7035c0daac605 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 6 14:36:21 2016 +0100 MIPS: KVM/locore.S: Only preserve callee saved registers Update __kvm_mips_vcpu_run() to only save and restore callee saved registers. It is always called using the standard ABIs, so the caller will preserve any other registers that need preserving. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13208/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kvm/locore.S | 48 +----------------------------------------------- 1 file changed, 1 insertion(+), 47 deletions(-) commit ca64c2beecd43e9621f5265edf14a76f7a2ffd7b Author: Paul Burton <paul.burton@imgtec.com> Date: Fri May 6 14:36:20 2016 +0100 MIPS: KVM: Abstract guest ASID mask In preparation for supporting varied widths of ASID mask in the kernel in general, switch KVM's guest ASIDs to a new KVM_ENTRYHI_ASID definition based on the 8-bit MIPS_ENTRYHI_ASID instead of ASID_MASK. It could potentially be used to support extended guest ASIDs in the future. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13207/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/kvm_host.h | 5 +++-- arch/mips/kvm/emulate.c | 25 +++++++++++++------------ arch/mips/kvm/tlb.c | 3 ++- 3 files changed, 18 insertions(+), 15 deletions(-) commit 9b5c3399584b6f6aa755dbe11e3cef5776fd279d Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 6 14:36:19 2016 +0100 MIPS: Add & use CP0_EntryHi ASID definitions Add definitions for the ASID field in CP0_EntryHi (along with the soon to be used ASIDX field), and use them in a few previously hardcoded cases. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Manuel Lauss <manuel.lauss@gmail.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13205/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 2 ++ arch/mips/kernel/genex.S | 2 +- arch/mips/kvm/locore.S | 4 ++-- arch/mips/pci/pci-alchemy.c | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) commit 5fb59fd2e7f7ee6bfc20ab9c0ef82e33c0057be5 Author: James Hogan <james.hogan@imgtec.com> Date: Fri May 6 14:36:18 2016 +0100 MIPS: KVM/locore.S: Don't preserve host ASID around vcpu_run MIPS KVM uses different ASIDs for guest execution than for the host. The host ASID is saved on the stack when entering the guest with __kvm_mips_vcpu_run(), and restored again before returning back to the caller (exit to userland). - This does not take into account that pre-emption may have taken place during that time, which may have started a new ASID cycle and resulted in that process' ASID being invalidated and reused. - This does not take into account that the process may have migrated to a different CPU during that time, with a different ASID assignment since they are managed per-CPU. - It is actually redundant, since the host ASID will be restored correctly by kvm_arch_vcpu_put(), which is called almost immediately after kvm_arch_vcpu_ioctl_run() returns. Therefore drop this code from locore.S Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13206/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kvm/locore.S | 12 ------------ 1 file changed, 12 deletions(-) commit 97b921087fa76b1b0b2a20ae70d0e8b6d394c4ea Author: John Crispin <john@phrozen.org> Date: Thu May 5 09:57:56 2016 +0200 MIPS: Change my email address The old address is no longer valid. Use the my new one instead. Signed-off-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13201/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-lantiq/falcon/lantiq_soc.h | 2 +- arch/mips/include/asm/mach-lantiq/lantiq.h | 2 +- arch/mips/include/asm/mach-lantiq/lantiq_platform.h | 2 +- arch/mips/include/asm/mach-lantiq/xway/irq.h | 2 +- arch/mips/include/asm/mach-lantiq/xway/lantiq_irq.h | 2 +- arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h | 2 +- arch/mips/include/asm/mach-lantiq/xway/xway_dma.h | 2 +- arch/mips/include/asm/mach-ralink/mt7620.h | 2 +- arch/mips/include/asm/mach-ralink/mt7621.h | 2 +- arch/mips/include/asm/mach-ralink/pinmux.h | 2 +- arch/mips/include/asm/mach-ralink/ralink_regs.h | 2 +- arch/mips/include/asm/mach-ralink/rt288x.h | 2 +- arch/mips/include/asm/mach-ralink/rt305x.h | 2 +- arch/mips/lantiq/Makefile | 2 +- arch/mips/lantiq/clk.c | 2 +- arch/mips/lantiq/clk.h | 2 +- arch/mips/lantiq/early_printk.c | 2 +- arch/mips/lantiq/falcon/prom.c | 2 +- arch/mips/lantiq/falcon/reset.c | 2 +- arch/mips/lantiq/falcon/sysctrl.c | 2 +- arch/mips/lantiq/irq.c | 2 +- arch/mips/lantiq/prom.c | 2 +- arch/mips/lantiq/prom.h | 2 +- arch/mips/lantiq/xway/clk.c | 2 +- arch/mips/lantiq/xway/dcdc.c | 2 +- arch/mips/lantiq/xway/dma.c | 2 +- arch/mips/lantiq/xway/gptu.c | 2 +- arch/mips/lantiq/xway/prom.c | 2 +- arch/mips/lantiq/xway/reset.c | 2 +- arch/mips/lantiq/xway/sysctrl.c | 2 +- arch/mips/lantiq/xway/vmmc.c | 2 +- arch/mips/lantiq/xway/xrx200_phy_fw.c | 4 ++-- arch/mips/pci/fixup-lantiq.c | 2 +- arch/mips/pci/ops-lantiq.c | 2 +- arch/mips/pci/pci-lantiq.c | 2 +- arch/mips/pci/pci-lantiq.h | 2 +- arch/mips/pci/pci-mt7620.c | 2 +- arch/mips/pci/pci-rt2880.c | 2 +- arch/mips/ralink/Makefile | 2 +- arch/mips/ralink/bootrom.c | 2 +- arch/mips/ralink/cevt-rt3352.c | 2 +- arch/mips/ralink/clk.c | 2 +- arch/mips/ralink/common.h | 2 +- arch/mips/ralink/ill_acc.c | 2 +- arch/mips/ralink/irq-gic.c | 2 +- arch/mips/ralink/irq.c | 2 +- arch/mips/ralink/mt7620.c | 2 +- arch/mips/ralink/mt7621.c | 2 +- arch/mips/ralink/of.c | 2 +- arch/mips/ralink/prom.c | 2 +- arch/mips/ralink/reset.c | 2 +- arch/mips/ralink/rt288x.c | 2 +- arch/mips/ralink/rt305x.c | 2 +- arch/mips/ralink/rt3883.c | 2 +- arch/mips/ralink/timer-gic.c | 2 +- arch/mips/ralink/timer.c | 4 ++-- 56 files changed, 58 insertions(+), 58 deletions(-) commit bdb40e8e8874476ad3396e96470639575416245c Author: John Crispin <john@phrozen.org> Date: Thu May 5 09:57:55 2016 +0200 MAINTAINERS: Change my email address The old address is no longer valid. Use the my new one instead. Signed-off-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13200/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 87321fddaeb8706a91293dc244408697a0a24ece Author: Paul Burton <paul.burton@imgtec.com> Date: Fri May 6 13:35:03 2016 +0100 MIPS: Implement __arch_bitrev* using bitswap for MIPSr6 Release 6 of the MIPS architecture introduced the bitswap instruction, which reverses the bits within each byte of a word. Make use of this instruction to implement the __arch_bitrev* functions, which should be faster for most MIPSr6 CPUs, reduces code size slightly and allows us to avoid the lookup table used by the generic implementation, saving 256 bytes in the kernel binary by dropping that. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13204/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 1 + arch/mips/include/asm/bitrev.h | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) commit 015aa05f534adabff2e4380f5ae6ea0fe20ec321 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Mon May 2 11:00:49 2016 +0200 MIPS: Remove no longer needed work_on_cpu() call Since commit 3b9d6da67e11 ("cpu/hotplug: Fix rollback during error-out in __cpu_disable()") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this work_on_cpu() calls are no longer required. Replace work_on_cpu() with a direct call of mips_cdmm_bus_up() or mips_cdmm_bus_down(). Description of those functions are adapted. Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: rt@linutronix.de Patchwork: https://patchwork.linux-mips.org/patch/13197/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/bus/mips_cdmm.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit e8b5325ca3d01c512be6f04d587869a01e0ea59f Author: Sergey Ryazanov <ryazanov.s.a@gmail.com> Date: Sat Aug 30 06:06:28 2014 +0400 MIPS: make PCI_DMA_BUS_IS_PHYS=1 constant No one of supported MIPS machines has an IOMMU unit, so we can safely define PCI_DMA_BUS_IS_PHYS = 1. Also remove iommu flag from the pci controller structure, since it is useless. Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com> Cc: Linux MIPS <linux-mips@linux-mips.org> Patchwork: https://patchwork.linux-mips.org/patch/7604/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pci.h | 10 ++++------ arch/mips/kernel/setup.c | 7 ------- arch/mips/pci/pci-ip32.c | 1 - arch/mips/pci/pci.c | 3 --- arch/mips/pnx833x/common/setup.c | 3 --- 5 files changed, 4 insertions(+), 20 deletions(-) commit 1e321fa917fb2d30d39ff1c6ea89d6f1cf4f34a5 Author: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Date: Thu May 14 18:34:43 2015 -0700 MIPS64: Support of at least 48 bits of SEGBITS SEGBITS is 40 bits or more, depending on CPU type. Introduces optional support for 48 bits of application virtual address space. Only 16K and 64K pages are supported. Enabling will result in a memory overhead of a small number of pages for small applications. For 64K pages a 3rd level of page tables is required which has some impact during software TLB refill. [ralf@linux-mips.org: Fixed things raised in the review of the version posted and changed kconfig to be a bit more userfriendly.] Signed-off-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: aleksey.makarov@auriga.com Cc: james.hogan@imgtec.com Cc: paul.burton@imgtec.com Cc: david.daney@cavium.com Cc: peterz@infradead.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: davidlohr@hp.com Cc: kirill@shutemov.name Cc: akpm@linux-foundation.org Cc: mingo@kernel.org Patchwork: https://patchwork.linux-mips.org/patch/10051/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 13 +++++++++++++ arch/mips/include/asm/pgtable-64.h | 18 +++++++++++------- arch/mips/include/asm/processor.h | 6 +++++- 3 files changed, 29 insertions(+), 8 deletions(-) commit 7939469da29a8dfa3947e5d9648d0f0501bc4ba0 Author: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Date: Mon Oct 19 11:39:55 2015 -0700 MIPS64: signal: Fix o32 sigaction syscall MIPS32 o32 ABI sigaction() processing on MIPS64 n64 kernel was incorrectly set to processing aka rt_sigaction() variant only. Signed-off-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: paul.burton@imgtec.com Cc: richard@nod.at Cc: luto@amacapital.net Cc: alex.smith@imgtec.com Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: mpe@ellerman.id.au Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/11321/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/signal.h | 12 +++++++++--- arch/mips/kernel/signal.c | 2 +- 2 files changed, 10 insertions(+), 4 deletions(-) commit cb80b2a38bd609b2f5a650e9ab87ea50105ad5ea Author: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Date: Thu Nov 19 17:38:21 2015 -0800 MIPS: remove aliasing alignment if HW has antialising support MIPS hardware may have an antialising support and it works even page size is small. Setup a shared memory aliasing mask to page size if hardware has an antialising support. Big shared memory mask forces a disruption in page address assignment and that corrupts Android library memory handling. Signed-off-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: cernekee@gmail.com Cc: paul.gortmaker@windriver.com Cc: kumba@gentoo.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/11516/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 201233e6b5d8c7adb84e3a718b0cb33f3665fb7c Author: Tony Wu <tung7970@gmail.com> Date: Fri Dec 4 19:41:12 2015 +0800 MIPS: traps: remove unused variable flags is indeed unused. Signed-off-by: Tony Wu <tung7970@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11699/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/traps.c | 1 - 1 file changed, 1 deletion(-) commit 1e820da3c9af4f5771d2ad47099919429b906ac6 Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 3 09:45:13 2016 +0800 MIPS: Loongson-3: Introduce CONFIG_LOONGSON3_ENHANCEMENT New Loongson 3 CPU (since Loongson-3A R2, as opposed to Loongson-3A R1, Loongson-3B R1 and Loongson-3B R2) has many enhancements, such as FTLB, L1-VCache, EI/DI/Wait/Prefetch instruction, DSP/DSPv2 ASE, User Local register, Read-Inhibit/Execute-Inhibit, SFB (Store Fill Buffer), Fast TLB refill support, etc. This patch introduce a config option, CONFIG_LOONGSON3_ENHANCEMENT, to enable those enhancements which are not probed at run time. If you want a generic kernel to run on all Loongson 3 machines, please say 'N' here. If you want a high-performance kernel to run on new Loongson 3 machines only, please say 'Y' here. Some additional explanations: 1) SFB locates between core and L1 cache, it causes memory access out of order, so writel/outl (and other similar functions) need a I/O reorder barrier. 2) Loongson 3 has a bug that di instruction can not save the irqflag, so arch_local_irq_save() is modified. Since CPU_MIPSR2 is selected by CONFIG_LOONGSON3_ENHANCEMENT, generic kernel doesn't use ei/di at all. 3) CPU_HAS_PREFETCH is selected by CONFIG_LOONGSON3_ENHANCEMENT, so MIPS_CPU_PREFETCH (used by uasm) probing is also put in this patch. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12755/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 18 ++++++++++++++++++ arch/mips/include/asm/hazards.h | 7 ++++--- arch/mips/include/asm/io.h | 10 +++++----- arch/mips/include/asm/irqflags.h | 5 +++++ .../include/asm/mach-loongson64/kernel-entry-init.h | 12 ++++++++++++ arch/mips/mm/c-r4k.c | 2 ++ arch/mips/mm/page.c | 9 +++++++++ 7 files changed, 55 insertions(+), 8 deletions(-) commit 380cd582c08831217ae693c86411902e6300ba6b Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 3 09:45:12 2016 +0800 MIPS: Loongson-3: Fast TLB refill handler Loongson-3A R2 has pwbase/pwfield/pwsize/pwctl registers in CP0 (this is very similar to HTW) and lwdir/lwpte/lddir/ldpte instructions which can be used for fast TLB refill. [ralf@linux-mips.org: Resolve conflict.] Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12754/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 3 + arch/mips/include/asm/cpu.h | 1 + arch/mips/include/asm/mipsregs.h | 6 ++ arch/mips/include/asm/uasm.h | 3 +- arch/mips/include/uapi/asm/inst.h | 10 +++ arch/mips/kernel/cpu-probe.c | 2 +- arch/mips/mm/tlbex.c | 124 ++++++++++++++++++++++++++++++++++- arch/mips/mm/uasm-mips.c | 2 + arch/mips/mm/uasm.c | 3 + 9 files changed, 149 insertions(+), 5 deletions(-) commit 06e4814eec988f7ee01c29762f945b3ff59355fb Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 3 09:45:11 2016 +0800 MIPS: Loongson: Invalidate special TLBs when needed Loongson-2 has a 4 entry itlb which is a subset of jtlb, Loongson-3 has a 4 entry itlb and a 4 entry dtlb which are subsets of jtlb. We should write diag register to invalidate itlb/dtlb when flushing jtlb because itlb/dtlb are not totally transparent to software. For Loongson-3A R2 (and newer), we should invalidate ITLB, DTLB, VTLB and FTLB before we enable/disable FTLB. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12753/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 9 +++++++++ arch/mips/kernel/cpu-probe.c | 3 +++ arch/mips/mm/tlb-r4k.c | 27 +++++++++++++++------------ 3 files changed, 27 insertions(+), 12 deletions(-) commit 37fbe8faa94fa8cae889a3a793fd7b32508b26ab Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 3 09:45:10 2016 +0800 MIPS: Loongson-3: Set cache flush handlers to cache_noop Loongson-3 maintains cache coherency by hardware, this means: 1) It's icache is coherent with dcache. 2) It's dcaches don't alias (maybe depend on PAGE_SIZE). 3) It maintains cache coherency across cores (and for DMA). So we can skip most cache flush operations by setting relevant handlers to `cache_noop' in `r4k_cache_init'. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12752/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit b2edcfc814017eb278e29bfdc72844f0434dd8b1 Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 3 09:45:09 2016 +0800 MIPS: Loongson: Add Loongson-3A R2 basic support Loongson-3 CPU family: Code-name Brand-name PRId Loongson-3A R1 Loongson-3A1000 0x6305 Loongson-3A R2 Loongson-3A2000 0x6308 Loongson-3B R1 Loongson-3B1000 0x6306 Loongson-3B R2 Loongson-3B1500 0x6307 Features of R2 revision of Loongson-3A: - Primary cache includes I-Cache, D-Cache and V-Cache (Victim Cache). - I-Cache, D-Cache and V-Cache are 16-way set-associative, linesize is 64 bytes. - 64 entries of VTLB (classic TLB), 1024 entries of FTLB (8-way set-associative). - Supports DSP/DSPv2 instructions, UserLocal register and Read-Inhibit/ Execute-Inhibit. [ralf@linux-mips.org: Resolved merge conflicts.] Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12751/ Patchwork: https://patchwork.linux-mips.org/patch/13136/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 + arch/mips/include/asm/cacheops.h | 6 ++ arch/mips/include/asm/cpu-info.h | 1 + arch/mips/include/asm/cpu.h | 4 +- .../asm/mach-loongson64/cpu-feature-overrides.h | 18 +--- .../asm/mach-loongson64/kernel-entry-init.h | 6 +- arch/mips/include/asm/mipsregs.h | 2 + arch/mips/include/asm/pgtable.h | 4 +- arch/mips/kernel/cpu-probe.c | 38 +++++++- arch/mips/kernel/idle.c | 5 + arch/mips/kernel/traps.c | 3 +- arch/mips/loongson64/common/env.c | 7 +- arch/mips/loongson64/loongson-3/smp.c | 106 +++++++++++++++++++-- arch/mips/mm/c-r4k.c | 27 ++++++ drivers/platform/mips/cpu_hwmon.c | 4 +- 15 files changed, 201 insertions(+), 32 deletions(-) commit 24653515e5d2cb07772919599ad799ce50f8af4f Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 17 20:41:07 2016 +0800 MIPS: Loongson-3: Adjust irq dispatch to speedup processing This patch adjust the logic in mach_irq_dispatch(), allow multiple IPs handled in the same dispatching. This can speedup interrupt processing. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12891/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/loongson64/loongson-3/irq.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit d0514728247b91476a525a064f8b3c2f0c47bec4 Author: Huacai Chen <chenhc@lemote.com> Date: Wed Oct 7 14:08:00 2015 +0800 MIPS: Loongson-3: Move chipset ACPI code from drivers to arch SB700/SB710/SB800 chipset ACPI code is mostly Loongson-3 specific routines rather than a "platform driver". Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: John Crispin <john@phrozen.org> Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11273/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/loongson64/loongson-3/Makefile | 2 +- arch/mips/loongson64/loongson-3/acpi_init.c | 150 ++++++++++++++++++++++++++++ drivers/platform/mips/Kconfig | 4 - drivers/platform/mips/Makefile | 1 - drivers/platform/mips/acpi_init.c | 150 ---------------------------- 5 files changed, 151 insertions(+), 156 deletions(-) commit 44896afe214e780e172f1bbbea7a2e6d087c908d Author: Antonio Ospite <ao2@ao2.it> Date: Wed Jan 27 14:56:06 2016 +0100 MIPS: BCM1480: bcm1480_regs.h: strip redundant comments Strip some comments which probably meant to repeat the same value of the define; they also contained a confusing 0x0x prefix. Signed-off-by: Antonio Ospite <ao2@ao2.it> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12254/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/sibyte/bcm1480_regs.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 50af501cd84b4e005fd54c351184ec89cfc940e4 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Mar 1 22:19:39 2016 +0000 MIPS: Add and use watch register field definitions The files watch.c and ptrace.c contain various magic masks for WatchLo/WatchHi register fields. Add some definitions to mipsregs.h for these registers and make use of them in both watch.c and ptrace.c, hopefully making them more readable. Signed-off-by: James Hogan <james.hogan@imgtec.com> Reviewed-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12729/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 18 ++++++++++ arch/mips/kernel/ptrace.c | 7 ++-- arch/mips/kernel/watch.c | 74 ++++++++++++++++++++++------------------ 3 files changed, 63 insertions(+), 36 deletions(-) commit e233c733786a8ca70cd12cc30aeb80e5b390ad71 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Mar 1 22:19:38 2016 +0000 MIPS: Add and use CAUSEF_WP definition do_watch() clears bit 22 of cause without using a CAUSEF_* definition from mipsregs.h. Add a definition for this bit (CAUSEF_WP) and make use of it. Also use clear_c0_cause() instead of manual read/modify/write. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12728/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mipsregs.h | 2 ++ arch/mips/kernel/traps.c | 5 +---- 2 files changed, 3 insertions(+), 4 deletions(-) commit b0d8a082ce9c82600ebf8949dab937cf53019356 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Feb 26 10:20:22 2016 -0700 watchdog: pic32-dmt: Add PIC32 deadman timer driver Adds support for the deadman timer peripheral found on PIC32 class devices. The primary function of the deadman timer (DMT) is to reset the processor in the event of a software malfunction. The DMT is a free-running instruction fetch timer, which is clocked whenever an instruction fetch occurs until a count match occurs. Instructions are not fetched when the processor is in sleep mode. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Wim Van Sebroeck <wim@iguana.be> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-watchdog@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12703/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/watchdog/Kconfig | 13 +++ drivers/watchdog/Makefile | 1 + drivers/watchdog/pic32-dmt.c | 257 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 271 insertions(+) commit bfa43267bc1c6484fe63570774c381ddc7b32f40 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Feb 26 10:20:21 2016 -0700 dt/bindings: Add bindings for PIC32 deadman timer peripheral Document the devicetree bindings for the deadman timer peripheral found on Microchip PIC32 SoC class devices. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Wim Van Sebroeck <wim@iguana.be> Cc: Guenter Roeck <linux@roeck-us.net> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-watchdog@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12702/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../bindings/watchdog/microchip,pic32-dmt.txt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 8f91fc56bc439a5baefae598040d263f48526596 Author: Joshua Henderson <joshua.henderson@microchip.com> Date: Fri Feb 26 10:19:28 2016 -0700 watchdog: pic32-wdt: Add PIC32 watchdog driver Add support for the watchdog peripheral found on PIC32 class devices. Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Wim Van Sebroeck <wim@iguana.be> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-watchdog@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12701/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/watchdog/Kconfig | 13 +++ drivers/watchdog/Makefile | 1 + drivers/watchdog/pic32-wdt.c | 263 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 277 insertions(+) commit 80c2902b3f1b458d4f99e4355fb48e8616d9a088 Author: Joshua Henderson <joshua.henderson@microchip.com> Date: Fri Feb 26 10:19:27 2016 -0700 dt/bindings: Add bindings for PIC32 watchdog peripheral Document the devicetree bindings for the watchdog peripheral found on Microchip PIC32 SoC class devices. Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Wim Van Sebroeck <wim@iguana.be> Cc: Guenter Roeck <linux@roeck-us.net> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Cc: linux-watchdog@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12700/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../bindings/watchdog/microchip,pic32-wdt.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit ba837d387195ea043900d2101cf90bcc083cff1b Author: Andrzej Hajda <a.hajda@samsung.com> Date: Mon Feb 15 15:35:20 2016 +0100 MIPS: module: fix incorrect IS_ERR_VALUE macro usages IS_ERR_VALUE macro should be used only with unsigned long type. Specifically it works incorrectly with longer types. The patch follows conclusion from discussion on LKML [1][2]. [1]: http://permalink.gmane.org/gmane.linux.kernel/2120927 [2]: http://permalink.gmane.org/gmane.linux.kernel/2150581 [ralf@linux-mips.org: While it may not immediately be obvious, the type of st_value in the end is an unsigned long equivalent so the invocation of IS_ERR_VALUE() was valid but I'm applying the patch anyway for clarity.] Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12553/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/module-rela.c | 2 +- arch/mips/kernel/module.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit acd9e20cd9d0e6af5680e1870a966d8082a1130a Author: Maciej W. Rozycki <macro@imgtec.com> Date: Fri Nov 13 00:48:48 2015 +0000 MIPS: math-emu: Always propagate sNaN payload in quieting Propagate sNaN payload in quieting in the legacy-NaN mode as well. If clearing the quiet bit would produce infinity, then set the next lower trailing significand field bit, matching the SB-1 and BMIPS5000 hardware implementations. Some other MIPS FPU hardware implementations do produce the default qNaN bit pattern instead. This reverts some changes made for semantics preservation with commit dc3ddf42 [MIPS: math-emu: Update sNaN quieting handlers], consequently bringing back most of the semantics from before commit fdffbafb [Lots of FPU bug fixes from Kjeld Borch Egevang.], except from the qNaN produced in the infinity case. Previously the default qNaN bit pattern was produced in that case. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Matthew Fortune <Matthew.Fortune@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/11483/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/ieee754dp.c | 9 ++++++--- arch/mips/math-emu/ieee754sp.c | 9 ++++++--- 2 files changed, 12 insertions(+), 6 deletions(-) commit 2e5832ab589459265e70163a7dea3abdc1429eb7 Author: Maciej W. Rozycki <macro@imgtec.com> Date: Fri Nov 13 00:48:39 2015 +0000 MIPS: ELF: Restructure personality macros Update the ELF personality macros used for individual ABIs to make actions in the same order across all of them and match formatting too. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Matthew Fortune <Matthew.Fortune@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/elf.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 987e5b834467c9251ca584febda65ef8f66351a9 Author: James Hogan <james.hogan@imgtec.com> Date: Mon Feb 8 18:43:51 2016 +0000 MIPS: Fix uapi include in exported asm/siginfo.h Since commit 8cb48fe169dd ("MIPS: Provide correct siginfo_t.si_stime"), MIPS' uapi/asm/siginfo.h has included uapi/asm-generic/siginfo.h directly before defining MIPS' struct siginfo, in order to get the necessary definitions needed for the siginfo struct without the generic copy_siginfo() hitting compiler errors due to struct siginfo not yet being defined. Now that the generic copy_siginfo() is moved out to linux/signal.h we can safely include asm-generic/siginfo.h before defining the MIPS specific struct siginfo, which avoids the uapi/ include as well as breakage due to generic copy_siginfo() being defined before struct siginfo. Reported-by: Christopher Ferris <cferris@google.com> Fixes: 8cb48fe169dd ("MIPS: Provide correct siginfo_t.si_stime") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Petr Malat <oss@malat.biz> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.0- Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/uapi/asm/siginfo.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit ca9eb49aa9562eaadf3cea071ec7018ad6800425 Author: James Hogan <james.hogan@imgtec.com> Date: Mon Feb 8 18:43:50 2016 +0000 SIGNAL: Move generic copy_siginfo() to signal.h The generic copy_siginfo() is currently defined in asm-generic/siginfo.h, after including uapi/asm-generic/siginfo.h which defines the generic struct siginfo. However this makes it awkward for an architecture to use it if it has to define its own struct siginfo (e.g. MIPS and potentially IA64), since it means that asm-generic/siginfo.h can only be included after defining the arch-specific siginfo, which may be problematic if the arch-specific definition needs definitions from uapi/asm-generic/siginfo.h. It is possible to work around this by first including uapi/asm-generic/siginfo.h to get the constants before defining the arch-specific siginfo, and include asm-generic/siginfo.h after. However uapi headers can't be included by other uapi headers, so that first include has to be in an ifdef __kernel__, with the non __kernel__ case including the non-UAPI header instead. Instead of that mess, move the generic copy_siginfo() definition into linux/signal.h, which allows an arch-specific uapi/asm/siginfo.h to include asm-generic/siginfo.h and define the arch-specific siginfo, and for the generic copy_siginfo() to see that arch-specific definition. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Petr Malat <oss@malat.biz> Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Christopher Ferris <cferris@google.com> Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-ia64@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: <stable@vger.kernel.org> # 4.0- Patchwork: https://patchwork.linux-mips.org/patch/12478/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> include/asm-generic/siginfo.h | 15 --------------- include/linux/signal.h | 15 +++++++++++++++ 2 files changed, 15 insertions(+), 15 deletions(-) commit 0e8c1a3247629ecb0e344655124fd59682410913 Author: Yang Shi <yang.shi@windriver.com> Date: Fri Feb 19 17:04:07 2016 -0800 MIPS: Octeon: Mark some functions __init in smp.c octeon_smp_setup and octeon_prepare_cpus are just used during initialization period, so mark them as __init. And, octeon_prepare_cpus is just used in smp.c, so make it static as well. Signed-off-by: Yang Shi <yang.shi@windriver.com> Cc: david.daney@cavium.com Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12574/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/smp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2d52ee82b4756d11565e94b8c09e77bb8c036a11 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Sat Apr 9 12:57:49 2016 +0200 MIPS: BMIPS: Improve BCM6368 device tree - Remove unneeded leds0 alias. - Switch to bcm6345-l1-intc interrupt controller. - Use interrupt-controller instead of periph_intc and cpu_intc. - Add uart1 node. - Single ohci and ehci nodes. - Avoid using underscores in node names. - Rename uart aliases to serial. - Remove blank line in cpus node. [ralf@linux-mips.org: fix references in bcm96368mvwg.dts so the file keeps building.] Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: f.fainelli@gmail.com Cc: jogo@openwrt.org Cc: cernekee@gmail.com Cc: robh@kernel.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: devicetree@vger.kernel.org Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm6368.dtsi | 32 ++++++++++++++++++++------------ arch/mips/boot/dts/brcm/bcm96368mvwg.dts | 4 ++-- 2 files changed, 22 insertions(+), 14 deletions(-) commit e3b992d028f828621fa2441b445478fd86651cad Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Sat Apr 9 12:57:48 2016 +0200 MIPS: BMIPS: Improve BCM6328 device tree - Remove unneeded leds0 alias. - Switch to bcm6345-l1-intc interrupt controller. - Use interrupt-controller instead of periph_intc and cpu_intc. - Add uart1, ehci and ohci nodes. - Refactor syscon and syscon-reboot. - Avoid using underscores in node names. - Rename uart aliases to serial. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: f.fainelli@gmail.com Cc: jogo@openwrt.org Cc: cernekee@gmail.com Cc: robh@kernel.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13043/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm6328.dtsi | 50 ++++++++++++++++++++++++++++-------- 1 file changed, 39 insertions(+), 11 deletions(-) commit 3652acd2315562614826eba7d38fae51389636f9 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Sat Apr 9 12:57:19 2016 +0200 MIPS: BMIPS: Add support for BCM63268 This SoC is very similar to BCM63168 and Broadcom usually refers to them as BCM63268. Add BCM63268 and missing BCM63168 to device tree documentation. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Cc: f.fainelli@gmail.com Cc: jogo@openwrt.org Cc: cernekee@gmail.com Cc: robh@kernel.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13042/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/mips/brcm/soc.txt | 1 + arch/mips/bmips/setup.c | 1 + 2 files changed, 2 insertions(+) commit 7537d273e2f3c95c17f6a2c8662209f5d18dbbbc Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Sat Apr 9 12:56:48 2016 +0200 MIPS: BMIPS: Add device tree example for BCM6358 This adds a device tree example for SFR Neufbox4 (Sercomm version), which also serves as a real example for brcm,bcm6358-leds. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Cc: f.fainelli@gmail.com Cc: jogo@openwrt.org Cc: cernekee@gmail.com Cc: robh@kernel.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13041/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../devicetree/bindings/mips/brcm/soc.txt | 2 +- arch/mips/bmips/Kconfig | 4 + arch/mips/boot/dts/brcm/Makefile | 2 + arch/mips/boot/dts/brcm/bcm6358.dtsi | 130 +++++++++++++++++++++ arch/mips/boot/dts/brcm/bcm96358nb4ser.dts | 46 ++++++++ 5 files changed, 183 insertions(+), 1 deletion(-) commit 3604b4510c17c16271b3446528807227dfb02b04 Author: Álvaro Fernández Rojas <noltari@gmail.com> Date: Sat Apr 9 12:56:47 2016 +0200 MIPS: BMIPS: Add BCM6358 support BCM6358 has a shared TLB which conflicts with current SMP support, so it must be disabled for now. BCM6358 uses >= 0xfffe0000 addresses for internal registers, which need to be remapped (by using a simplified version of BRCM63xx ioremap.h). However, 0xfff80000 is a better address, since it also covers BCM3368, leaving the possibility to add it in the future. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Cc: f.fainelli@gmail.com Cc: jogo@openwrt.org Cc: cernekee@gmail.com Cc: robh@kernel.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13040/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/bmips/setup.c | 10 +++++++++ arch/mips/include/asm/mach-bmips/ioremap.h | 33 ++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+) commit 65b2849a022031f7aa42770daa8478a943dbc123 Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Tue Apr 12 18:40:19 2016 +0800 CPUFREQ: Loongson1: Replace goto out with return in ls1x_cpufreq_probe() This patch replaces goto out with return in ls1x_cpufreq_probe(). Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13056/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/cpufreq/loongson1-cpufreq.c | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) commit 99bf2e68988f46d969329dc964950062e805ed1b Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Tue Apr 12 18:40:18 2016 +0800 CPUFREQ: Loongson1: Use devm_kzalloc() instead of global structure This patch uses devm_kzalloc() instead of global structure. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13055/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/cpufreq/loongson1-cpufreq.c | 63 ++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 28 deletions(-) commit 25581d2b76ef8564d592bf3bc61a5d6d4f5f2ea2 Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Tue Apr 12 18:40:17 2016 +0800 CPUFREQ: Loongson1: Use dev_get_platdata() to get platform_data This patch uses dev_get_platdata() to get the platform_data instead of referencing it directly. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13054/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/cpufreq/loongson1-cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 379e38a763dd63838411cc2fa765515e7535570b Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Tue Apr 12 18:40:16 2016 +0800 CPUFREQ: Loongson1: Replace kzalloc() with kcalloc() This patch replaces kzalloc() with kcalloc() when allocating frequency table, and remove unnecessary 'out of memory' message. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13053/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/cpufreq/loongson1-cpufreq.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 6a1d55ccd8bcb304f060987e265d71068724f0d2 Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Tue Apr 12 18:40:15 2016 +0800 CPUFREQ: Loongson1: Rename the file to loongson1-cpufreq.c This patch renames the file to loongson1-cpufreq.c, and also includes some minor updates. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13052/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/cpufreq/Makefile | 2 +- drivers/cpufreq/loongson1-cpufreq.c | 222 ++++++++++++++++++++++++++++++++++++ drivers/cpufreq/ls1x-cpufreq.c | 222 ------------------------------------ 3 files changed, 223 insertions(+), 223 deletions(-) commit 37808d62afcdc420d98875c4b514c178d56f6815 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 4 10:55:38 2016 -0700 MIPS: BMIPS: Pretty print BMIPS5200 processor name Just to ease debugging of multiplatform kernel, make sure we print "Broadcom BMIPS5200" for the BMIPS5200 implementation instead of Broadcom BMIPS5000. Fixes: 68e6a78373a6d ("MIPS: BMIPS: Add PRId for BMIPS5200 (Whirlwind)") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13014/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cpu-probe.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit f337967d6d87da39f6e59d90430f3bec0909edf5 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 4 10:55:37 2016 -0700 MIPS: BMIPS: Add cpu-feature-overrides.h BMIPS_GENERIC being multiplatform and intended to support BMIPS3200, BMIPS3300, BMIPS4350, BMIPS4380 and BMIPS5000-class processors, there is not much more we can put in there since they do not share the same I and D cache line sizes at all (doubled for every new generation essentially), some processors have a S-cache, some don't, some have a FPU, some don't. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13013/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mach-bmips/cpu-feature-overrides.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit f675843ddfdfdf467d08cc922201614a149e439e Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 4 10:55:36 2016 -0700 MIPS: BMIPS: local_r4k___flush_cache_all needs to blast S-cache local_r4k___flush_cache_all() is missing a special check for BMIPS5000 processors, we need to blast the S-cache, just like other MTI processors since we have an inclusive cache. We also need an additional __sync() to make sure this is completed. Fixes: d74b0172e4e2c ("MIPS: BMIPS: Add special cache handling in c-r4k.c") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13012/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 5 +++++ 1 file changed, 5 insertions(+) commit 73c4ca047f440c79f545bc6133e3033f754cd239 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 4 10:55:35 2016 -0700 MIPS: BMIPS: Clear MIPS_CACHE_ALIASES earlier BMIPS5000 and BMIPS5200 processor have no D cache aliases, and this is properly handled by the per-CPU override added at the end of r4k_cache_init(), the problem is that the output of probe_pcache() disagrees with that, since this is too late: Primary instruction cache 32kB, VIPT, 4-way, linesize 64 bytes. Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes With the change moved earlier, we now have a consistent output with the settings we are intending to have: Primary instruction cache 32kB, VIPT, 4-way, linesize 64 bytes. Primary data cache 32kB, 4-way, VIPT, no aliases, linesize 32 bytes Fixes: d74b0172e4e2c ("MIPS: BMIPS: Add special cache handling in c-r4k.c") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13011/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c130d2fd3d59fbd5d269f7d5827bd4ed1d94aec6 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 4 10:55:34 2016 -0700 MIPS: BMIPS: BMIPS5000 has I cache filing from D cache BMIPS5000 and BMIPS52000 processors have their I-cache filling from the D-cache. Since BMIPS_GENERIC does not provide (yet) a cpu-feature-overrides.h file, this was not set anywhere, so make sure the R4K cache detection takes care of that. Fixes: d74b0172e4e2c ("MIPS: BMIPS: Add special cache handling in c-r4k.c") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13010/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 4 ++++ 1 file changed, 4 insertions(+) commit 0201bfb1af4747f3642fa7a707fd81bbf78390b7 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Jan 27 12:13:16 2016 -0800 MIPS: BMIPS: Enable partition parser in defconfig Enable CONFIG_MTD_BCM63XX_PARTS in arch/mips/configs/bmips_be_defconfig since this is a necessary option to parse the built-in flash partition table on BMIPS big-endian SoCs (Cable Modem and DSL). Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Cc: cernekee@gmail.com Cc: jogo@openwrt.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12256/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/configs/bmips_be_defconfig | 1 + 1 file changed, 1 insertion(+) commit eb1472e7df2c0e1f1c3e207630ffdd008e98f271 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Jan 27 12:13:15 2016 -0800 MIPS: BCM63xx: Enable partition parser in defconfig Enable CONFIG_MTD_BCM63XX_PARTS in arch/mips/configs/bcm63xx_defconfig since this is a necessary option to parse the built-in flash partition table on BCM63xx SoCs. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Cc: cernekee@gmail.com Cc: jogo@openwrt.org Cc: simon@fire.lp0.eu Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12255/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/configs/bcm63xx_defconfig | 1 + 1 file changed, 1 insertion(+) commit 413ef3f6c9746154db7b4daeed89cac94490391a Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Wed Apr 6 20:34:55 2016 +0800 MAINTAINERS: add Loongson1 architecture entry This patch adds Loongson1 architecture entry. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: Viresh Kumar <viresh.kumar@linaro.org> Cc: Vinod Koul <vinod.koul@intel.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Cc: Richard Weinberger <richard@nod.at> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Brian Norris <computersforpeace@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Cc: linux-pm@vger.kernel.org Cc: dmaengine@vger.kernel.org Cc: linux-gpio@vger.kernel.org Cc: linux-mtd@lists.infradead.org Patchwork: https://patchwork.linux-mips.org/patch/13034/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+) commit 9ec88b60cb481a6862dc98a78400a6945d9675ba Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Wed Apr 6 20:34:54 2016 +0800 MIPS: Loongson1B: Some updates/fixes for LS1B - Add DMA device - Add NAND device - Add GPIO device - Add LED device - Update the defconfig and rename it to loongson1b_defconfig - Fix ioremap size - Other minor fixes Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: Viresh Kumar <viresh.kumar@linaro.org> Cc: Vinod Koul <vinod.koul@intel.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Cc: Richard Weinberger <richard@nod.at> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Brian Norris <computersforpeace@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Cc: linux-pm@vger.kernel.org Cc: dmaengine@vger.kernel.org Cc: linux-gpio@vger.kernel.org Cc: linux-mtd@lists.infradead.org Patchwork: https://patchwork.linux-mips.org/patch/13033/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 + arch/mips/configs/loongson1b_defconfig | 125 ++++++++++++++++++++++ arch/mips/configs/ls1b_defconfig | 110 ------------------- arch/mips/include/asm/mach-loongson32/cpufreq.h | 1 - arch/mips/include/asm/mach-loongson32/dma.h | 25 +++++ arch/mips/include/asm/mach-loongson32/irq.h | 1 - arch/mips/include/asm/mach-loongson32/loongson1.h | 4 +- arch/mips/include/asm/mach-loongson32/nand.h | 30 ++++++ arch/mips/include/asm/mach-loongson32/platform.h | 14 ++- arch/mips/include/asm/mach-loongson32/regs-clk.h | 24 ++--- arch/mips/include/asm/mach-loongson32/regs-mux.h | 84 +++++++-------- arch/mips/include/asm/mach-loongson32/regs-pwm.h | 12 +-- arch/mips/loongson32/common/platform.c | 105 +++++++++++++++++- arch/mips/loongson32/common/reset.c | 13 +-- arch/mips/loongson32/common/time.c | 27 ++--- arch/mips/loongson32/ls1b/board.c | 67 +++++++++++- 16 files changed, 440 insertions(+), 204 deletions(-) commit 0d61ed17dd30fc31533ce07750d03bdb34fb6d7a Author: Maciej W. Rozycki <macro@imgtec.com> Date: Thu Feb 11 14:25:43 2016 +0000 ld-version: Drop the 4th and 5th version components ... making upstream development binutils snapshots work as expected, e.g.: $ mips64el-linux-ld --version GNU ld (GNU Binutils) 2.20.1.20100303 [...] $ Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Acked-by: Michal Marek <mmarek@suse.cz> Cc: Michael S. Tsirkin <mst@redhat.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-kbuild@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12537/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> scripts/ld-version.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 69ca2b81c2f63eb48eccdf70a4433641c5041527 Author: Jaedon Shin <jaedon.shin@gmail.com> Date: Wed Apr 6 14:58:01 2016 +0900 MIPS: BMIPS: Fix interrupt and remove needless properties Fixes wrong bcm7425 SATA AHCI hardware interrupt property value with periph_intc and SATA PHY unit address, and removes needless brcm,broken-{ncq,phy} properties what are not used anywhere. Signed-off-by: Jaedon Shin <jaedon.shin@gmail.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Cc: Kevin Cernekee <cernekee@gmail.com> Cc: Dragan Stancevic <dragan.stancevic@gmail.com> Cc: Linux-MIPS <linux-mips@linux-mips.org> Patchwork: https://patchwork.linux-mips.org/patch/13017/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm7346.dtsi | 4 +--- arch/mips/boot/dts/brcm/bcm7362.dtsi | 4 +--- arch/mips/boot/dts/brcm/bcm7425.dtsi | 6 ++---- 3 files changed, 4 insertions(+), 10 deletions(-) commit 5c40d493e2e63d2979610aed75df7e3744b87921 Author: Jaedon Shin <jaedon.shin@gmail.com> Date: Wed Apr 6 15:01:08 2016 +0900 MIPS: BMIPS: Add support UART, I2C, SATA device Add UART, I2C, SATA device tree nodes on Broadcom BCM7xxx MIPS-based platforms. Signed-off-by: Jaedon Shin <jaedon.shin@gmail.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Cc: Kevin Cernekee <cernekee@gmail.com> Cc: Dragan Stancevic <dragan.stancevic@gmail.com> Cc: Linux-MIPS <linux-mips@linux-mips.org> Patchwork: https://patchwork.linux-mips.org/patch/13016/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm7125.dtsi | 69 +++++++++++++++- arch/mips/boot/dts/brcm/bcm7346.dtsi | 2 - arch/mips/boot/dts/brcm/bcm7358.dtsi | 2 - arch/mips/boot/dts/brcm/bcm7360.dtsi | 42 +++++++++- arch/mips/boot/dts/brcm/bcm7362.dtsi | 2 - arch/mips/boot/dts/brcm/bcm7420.dtsi | 77 +++++++++++++++++- arch/mips/boot/dts/brcm/bcm7425.dtsi | 94 +++++++++++++++++++++- arch/mips/boot/dts/brcm/bcm7435.dtsi | 134 ++++++++++++++++++++++++++++++- arch/mips/boot/dts/brcm/bcm97125cbmb.dts | 24 ++++++ arch/mips/boot/dts/brcm/bcm97360svmb.dts | 8 ++ arch/mips/boot/dts/brcm/bcm97420c.dts | 28 +++++++ arch/mips/boot/dts/brcm/bcm97425svmb.dts | 28 +++++++ arch/mips/boot/dts/brcm/bcm97435svmb.dts | 36 +++++++++ 13 files changed, 530 insertions(+), 16 deletions(-) commit 23021b2bb98543d08e22725122650644d824bf18 Author: Yang Shi <yang.shi@windriver.com> Date: Fri Feb 19 15:42:11 2016 -0800 MIPS: Kconfig: replace OPROFILE=n to !OPROFILE In Kconfig "=n" is not correct syntax, "!" is the preferred way for false-positive expression. Signed-off-by: Yang Shi <yang.shi@windriver.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12572/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 919beb4eedc587b70f8c1390fedac10cda783c36 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:42 2016 +0100 MIPS: KASLR: Print relocation Information on boot When debugging a relocated kernel, the addresses of the relocated symbols and the offset applied is essential information. If the kernel is compiled with debugging information, then print this information during bootup using the same function as the panic notifier. [ralf@linux-mips.org: Fixed spelling mistake pointed out by Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>.] Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Aaro Koskinen <aaro.koskinen@nokia.com> Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Cc: Alexander Sverdlin <alexander.sverdlin@gmail.com> Cc: Jaedon Shin <jaedon.shin@gmail.com> Cc: Jonas Gorski <jogo@openwrt.org> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12989/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/setup.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 405bc8fd12f59ec865714447b2f6e1a961f49025 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:41 2016 +0100 MIPS: Kernel: Implement KASLR using CONFIG_RELOCATABLE This patch adds KASLR to the MIPS kernel. Entropy is derived from the banner, which will change every build and random_get_entropy() which should provide additional runtime entropy. Additionally the bootloader may pass entropy via the /chosen/kaslr-seed node in device tree. The kernel is relocated by up to RANDOMIZE_BASE_MAX_OFFSET bytes from its link address (PHYSICAL_START). Because relocation happens so early in the kernel boot, the amount of physical memory has not yet been determined. This means the only way to limit relocation within the available memory is via Kconfig. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12990/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 30 +++++++++ arch/mips/kernel/relocate.c | 146 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 176 insertions(+) commit 5e7c1c918a4433c5dd1844d99f5648e17425fa16 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:40 2016 +0100 MIPS: Introduce plat_get_fdt a platform API to retrieve the FDT Early access to the kernel command line requires early access to the FDT for platforms which pass the command line within the device tree. There was no common way to retrieve the location of the FDT without incurring side effects, such as plat_mem_setup which, on Malta at least, initializes a bunch of other stuff. This patch adds plat_get_ftd() for IMG platforms. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12988/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/bootinfo.h | 18 ++++++++++++++++++ arch/mips/mti-malta/malta-setup.c | 7 ++++++- arch/mips/mti-sead3/sead3-setup.c | 5 +++++ 3 files changed, 29 insertions(+), 1 deletion(-) commit 8c530ea35caef8bc293b56580ab55352f7d86bfc Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:39 2016 +0100 MIPS: Add CONFIG_RELOCATABLE Kconfig option Add option to KConfig to enable the kernel to relocate itself at runtime. Relocation is supported R2 and later of the MIPS architecture, 32bit and 64bit. The platform is also required to provide support through plat_get_fdt() added in a later patch. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12987/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 61cd52d4e44d7d8c55dad939b1877fd39d7103a2 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:38 2016 +0100 MIPS: bootmem: When relocatable, free memory below kernel The kernel reserves all memory before the _end symbol as bootmem, however, once the kernel can be relocated elsewhere in memory this may result in a large amount of wasted memory. The assumption is that the memory between the link and relocated address of the kernel may be released back to the available memory pool. Memory statistics for a Malta with the kernel relocating by 16Mb, without the patch: Memory: 105952K/131072K available (4604K kernel code, 242K rwdata, 892K rodata, 1280K init, 183K bss, 25120K reserved, 0K cma-reserved) And with the patch: Memory: 122336K/131072K available (4604K kernel code, 242K rwdata, 892K rodata, 1280K init, 183K bss, 8736K reserved, 0K cma-reserved) The 16Mb offset is removed from the reserved region and added back to the available region. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Aaro Koskinen <aaro.koskinen@nokia.com> Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Cc: Alexander Sverdlin <alexander.sverdlin@gmail.com> Cc: Jaedon Shin <jaedon.shin@gmail.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Jonas Gorski <jogo@openwrt.org> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12986/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/setup.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit af09ab5e3fa7b6e137b135325a2ca00d57b4aea2 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:37 2016 +0100 MIPS: Call relocate_kernel if CONFIG_RELOCATABLE=y If CONFIG_RELOCATABLE is enabled, call relocate_kernel. This function will return the entry point of the relocated kernel if copy/relocate is sucessful or the original entry point if not. The stack pointer must then be pointed into the new image. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Jonas Gorski <jogo@openwrt.org> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12984/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/head.S | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 279b991b24d2439fbe9d2f093988b9c8aed2603d Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:36 2016 +0100 MIPS: Kernel: Add relocate.c arch/mips/kernel/relocate.c contains the functions necessary to relocate the kernel elsewhere in memory The kernel makes a copy of itself at the new address. It uses the relocation table inserted by the relocs tool to fix symbol references within the new image. If copy/relocation is sucessful then the entry point of the new kernel is returned, otherwise fall back to starting the kernel in place. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12985/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/Makefile | 2 + arch/mips/kernel/relocate.c | 240 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 242 insertions(+) commit e818fac595ab94900f0046baba1f1a0e2d5c2435 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:35 2016 +0100 MIPS: Generate relocation table when CONFIG_RELOCATABLE When CONFIG_RELOCATABLE is enabled (added in later patch) add --emit-relocs to vmlinux LDFLAGS so that fully linked vmlinux contains relocation information. Run the previously added relocs tool to fill in the .data.relocs section of vmlinux with a table of relocations. The relocs tool will also remove (mark as 0 length) the relocation sections added to vmlinux. When vmlinux is passed to the boot makefile for conversion into a boot image the now empty relocation sections will be removed and the populated relocation table will be included in the binary image. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12983/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Makefile | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 069fd766271de65ec4dc2eb8d15f7f44727b1ea1 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:34 2016 +0100 MIPS: Reserve space for relocation table When CONFIG_RELOCATABLE is enabled, add a new section in the memory map to be filled with relocation data. CONFIG_RELOCATION_TABLE_SIZE allows the amount of space reserved to be adjusted if necessary. The relocs tool will populate this reserved space with relocation information. The space is reserved within the elf by filling it with 0's, and an invalid entry is left at the start of the space such that kernel relocation will be aborted if the table is empty. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Aaro Koskinen <aaro.koskinen@nokia.com> Cc: David Daney <ddaney@caviumnetworks.com> Cc: Jonas Gorski <jogo@openwrt.org> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12982/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 16 ++++++++++++++++ arch/mips/kernel/vmlinux.lds.S | 21 +++++++++++++++++++++ 2 files changed, 37 insertions(+) commit aadeec4df9b33526f45a27e61df6891dd21b1e39 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:33 2016 +0100 MIPS: tools: Build relocs tool Build the relocs tool as part of the kbuild Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12980/ Patchwork: https://patchwork.linux-mips.org/patch/13242/ Patchwork: https://patchwork.linux-mips.org/patch/13233/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Makefile | 4 ++++ arch/mips/boot/tools/.gitignore | 1 + 2 files changed, 5 insertions(+) commit 766c580356ecca88b32c47b8128bec7d6d014533 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Thu Mar 31 10:05:32 2016 +0100 MIPS: tools: Add relocs tool This tool is based on the x86/boot/tools/relocs tool. It parses the relocations present in the vmlinux elf file, building a table of relocations that will be necessary to run the kernel from an address other than its link address. This table is inserted into the vmlinux elf, in the .data.relocs section. The table is subsequently used by the code in arch/mips/kernel/relocate.c (added later) to relocate the kernel. The tool, by default, also marks all relocation sections as 0 length. This is due to objcopy currently being unable to handle copying the relocations between 64 and 32 bit elf files as is done when building a 64 bit kernel. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: kernel-hardening@lists.openwall.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12981/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/tools/Makefile | 8 + arch/mips/boot/tools/relocs.c | 680 +++++++++++++++++++++++++++++++++++++ arch/mips/boot/tools/relocs.h | 45 +++ arch/mips/boot/tools/relocs_32.c | 17 + arch/mips/boot/tools/relocs_64.c | 27 ++ arch/mips/boot/tools/relocs_main.c | 84 +++++ 6 files changed, 861 insertions(+) commit cb4253aa0f77f20be018970dbe5d01d78b930ef9 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:34 2016 +0100 secomp: Constify mode1 syscall whitelist These values are constant and should be marked as such. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Will Drewry <wad@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12979/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> kernel/seccomp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b1b4fad5cc678442c8184a7b91b6cfb0b8b461a5 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:33 2016 +0100 MIPS: seccomp: Support compat with both O32 and N32 Previously the seccomp would only support strict mode on O32 userland programs when the kernel had support for both O32 and N32 ABIs. Remove kludge and support both ABIs. With this patch in place, the seccomp_bpf self test now passes global.mode_strict_support with N32 userland. Suggested-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12917/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/seccomp.h | 47 +++++++++++++++++++++++------------------ 1 file changed, 26 insertions(+), 21 deletions(-) commit c983f0e8677d5d686ea81de13f9c9ac34f21a2a7 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:32 2016 +0100 seccomp: Get compat syscalls from asm-generic header Move retrieval of compat syscall numbers into inline function defined in asm-generic header so that arches may override it. [ralf@linux-mips.org: Resolve merge conflict.] Suggested-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: Arnd Bergmann <arnd@arndb.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Will Drewry <wad@chromium.org> Cc: linux-arch@vger.kernel.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12978/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> include/asm-generic/seccomp.h | 14 ++++++++++++++ kernel/seccomp.c | 9 +-------- 2 files changed, 15 insertions(+), 8 deletions(-) commit a400bed6d105c23d3673f763596e4b85de14e41a Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:31 2016 +0100 MIPS: scall: Handle seccomp filters which redirect syscalls Commit d218af78492a ("MIPS: scall: Always run the seccomp syscall filters") modified the syscall code to always call the seccomp filters, but missed the case where a filter may redirect the syscall, as revealed by the seccomp_bpf self test. The syscall path now restores the syscall from the stack after the filter rather than saving it locally. Syscall number checking and syscall function table lookup is done after the filter may have run such that redirected syscalls are also checked, and executed. The regular path of syscall number checking and pointer lookup is also made more consistent between ABIs with scall64-64.S being the reference. With this patch in place, the seccomp_bpf self test now passes TRACE_syscall.syscall_redirected and TRACE_syscall.syscall_dropped on all MIPS ABIs. Fixes: d218af78492a ("MIPS: scall: Always run the seccomp syscall filters") Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Eric B Munson <emunson@akamai.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12916/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/scall32-o32.S | 11 +++++------ arch/mips/kernel/scall64-64.S | 3 +-- arch/mips/kernel/scall64-n32.S | 14 +++++++++----- arch/mips/kernel/scall64-o32.S | 14 +++++++++----- 4 files changed, 24 insertions(+), 18 deletions(-) commit 5050e91fa650ecd6260ef62bbed9dfc5b4d05dfa Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:30 2016 +0100 MIPS: Support sending SIG_SYS to 32bit userspace from 64bit kernel The seccomp_bpf self test revealed that a 64bit kernel delivered an invalid SIG_SYS to a 32bit userspace, because it was falling into the default of the switch statement. Add a case to handle delivering the signal. With this patch, the seccomp_bpf self test now passes the TRAP.handler case with O32 and N32 userlands. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12915/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/signal32.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 0ce105bf9723e9a2dc7ec0a1e164c1b63aa64546 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Tue Mar 29 09:35:29 2016 +0100 selftests/seccomp: add MIPS self-test support This adds self-test support on MIPS, based on RFC patch from Kees Cook. Modifications from the RFC: - support the O32 syscall which passes the real syscall number in a0. - Use PTRACE_{GET,SET}REGS - Because SYSCALL_NUM and SYSCALL_RET are the same register, it is not possible to test modifying the syscall return value when skipping, since both would need to set the same register. Therefore modify that test case to just detect the skipped test. Tested on MIPS32r2 / MIPS64r2 with O32, N32 and N64 userlands. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Acked-by: Kees Cook <keescook@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Will Drewry <wad@chromium.org> Cc: IMG-MIPSLinuxKerneldevelopers@imgtec.com Cc: linux-kernel@vger.kernel.org Cc: linux-kselftest@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12977/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> tools/testing/selftests/seccomp/seccomp_bpf.c | 30 +++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) commit 8571e645d1d15a560a32d262817f3b1d901cedac Author: Martin Schiller <mschiller@tdt.de> Date: Thu Nov 26 11:00:08 2015 +0100 pinctrl/lantiq: update devicetree binding in dts file This patch updates the compatible string in the easy50712.dts file to the new "lantiq,danube-pinctrl". Signed-off-by: Martin Schiller <mschiller@tdt.de> Acked-by: Linus Walleij <linus.walleij@linaro.org> Cc: robh+dt@kernel.org Cc: pawel.moll@arm.com Cc: mark.rutland@arm.com Cc: ijc+devicetree@hellion.org.uk Cc: galak@codeaurora.org Cc: john@phrozen.org Cc: hauke@hauke-m.de Cc: jogo@openwrt.org Cc: daniel.schwierzeck@gmail.com Cc: linux-gpio@vger.kernel.org Cc: devicetree@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11589/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/lantiq/easy50712.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e55d5312444087eb6bfb34c1cd5f6e0bf626cf26 Author: Daniel Wagner <daniel.wagner@bmw-carit.de> Date: Thu Feb 11 13:36:54 2016 +0100 crash_dump: Add vmcore_elf32_check_arch parse_crash_elf{32|64}_headers will check the headers via the elf_check_arch respectively vmcore_elf64_check_arch macro. The MIPS architecture implements those two macros differently. In order to make the differentiation more explicit, let's introduce an vmcore_elf32_check_arch to allow the archs to overwrite it. Signed-off-by: Daniel Wagner <daniel.wagner@bmw-carit.de> Suggested-by: Maciej W. Rozycki <macro@imgtec.com> Reviewed-by: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12535/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> fs/proc/vmcore.c | 2 +- include/linux/crash_dump.h | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) commit 331ae5fc3eb439b4ef2e26c25c8d1431d74b7a6f Author: Simon Arlott <simon@fire.lp0.eu> Date: Wed Dec 9 20:27:09 2015 +0000 irqchip: Add brcm, bcm6345-l1-intc device tree binding Add device tree binding for the BCM6345 interrupt controller. This controller is similar to the SMP-capable BCM7038 and the BCM3380 but with packed interrupt registers. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Acked-by: Rob Herring <robh@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: Kevin Cernekee <cernekee@gmail.com> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Jonas Gorski <jogo@openwrt.org> Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org> Cc: devicetree@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11804/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../interrupt-controller/brcm,bcm6345-l1-intc.txt | 57 ++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit e2c93cf14b40e8b8e755bb163ced004edb4691e2 Author: Borislav Petkov <bp@suse.de> Date: Wed Mar 30 13:42:45 2016 +0200 MIPS: defconfigs: Remove CONFIG_IPV6_PRIVACY Option is long gone, see 5d9efa7ee99e ("ipv6: Remove privacy config option.") Signed-off-by: Borislav Petkov <bp@suse.de> Cc: linux-mips@linux-mips.org Cc: LKML <linux-kernel@vger.kernel.org> Patchwork: https://patchwork.linux-mips.org/patch/12919/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/configs/bcm47xx_defconfig | 1 - arch/mips/configs/bigsur_defconfig | 1 - arch/mips/configs/decstation_defconfig | 1 - arch/mips/configs/ip22_defconfig | 1 - arch/mips/configs/ip27_defconfig | 1 - arch/mips/configs/jazz_defconfig | 1 - arch/mips/configs/lemote2f_defconfig | 1 - arch/mips/configs/mtx1_defconfig | 1 - arch/mips/configs/nlm_xlp_defconfig | 1 - arch/mips/configs/nlm_xlr_defconfig | 1 - arch/mips/configs/rm200_defconfig | 1 - 11 files changed, 11 deletions(-) commit 3d2ca73af4eb4a33ae021e37b5f395ac5631cb3f Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed Jan 27 14:23:36 2016 -0800 MIPS: Use generic clkdev.h header The generic header file is equivalent to the MIPS one, so use the generic one instead. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Cc: linux-kernel@vger.kernel.org Cc: linux-clk@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12261/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/Kbuild | 1 + arch/mips/include/asm/clkdev.h | 27 --------------------------- 2 files changed, 1 insertion(+), 27 deletions(-) commit 37d22a0d798b5c938b277d32cfd86dc231381342 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Mar 1 02:37:59 2016 +0000 MIPS: Sync icache & dcache in set_pte_at It's possible for pages to become visible prior to update_mmu_cache running if a thread within the same address space preempts the current thread or runs simultaneously on another CPU. That is, the following scenario is possible: CPU0 CPU1 write to page flush_dcache_page flush_icache_page set_pte_at map page update_mmu_cache If CPU1 maps the page in between CPU0's set_pte_at, which marks it valid & visible, and update_mmu_cache where the dcache flush occurs then CPU1s icache will fill from stale data (unless it fills from the dcache, in which case all is good, but most MIPS CPUs don't have this property). Commit 4d46a67a3eb8 ("MIPS: Fix race condition in lazy cache flushing.") attempted to fix that by performing the dcache flush in flush_icache_page such that it occurs before the set_pte_at call makes the page visible. However it has the problem that not all code that writes to pages exposed to userland call flush_icache_page. There are many callers of set_pte_at under mm/ and only 2 of them do call flush_icache_page. Thus the race window between a page becoming visible & being coherent between the icache & dcache remains open in some cases. To illustrate some of the cases, a WARN was added to __update_cache with this patch applied that triggered in cases where a page about to be flushed from the dcache was not the last page provided to flush_icache_page. That is, backtraces were obtained for cases in which the race window is left open without this patch. The 2 standout examples follow. When forking a process: [ 15.271842] [<80417630>] __update_cache+0xcc/0x188 [ 15.277274] [<80530394>] copy_page_range+0x56c/0x6ac [ 15.282861] [<8042936c>] copy_process.part.54+0xd40/0x17ac [ 15.289028] [<80429f80>] do_fork+0xe4/0x420 [ 15.293747] [<80413808>] handle_sys+0x128/0x14c When exec'ing an ELF binary: [ 14.445964] [<80417630>] __update_cache+0xcc/0x188 [ 14.451369] [<80538d88>] move_page_tables+0x414/0x498 [ 14.457075] [<8055d848>] setup_arg_pages+0x220/0x318 [ 14.462685] [<805b0f38>] load_elf_binary+0x530/0x12a0 [ 14.468374] [<8055ec3c>] search_binary_handler+0xbc/0x214 [ 14.474444] [<8055f6c0>] do_execveat_common+0x43c/0x67c [ 14.480324] [<8055f938>] do_execve+0x38/0x44 [ 14.485137] [<80413808>] handle_sys+0x128/0x14c These code paths write into a page, call flush_dcache_page then call set_pte_at without flush_icache_page inbetween. The end result is that the icache can become corrupted & userland processes may execute unexpected or invalid code, typically resulting in a reserved instruction exception, a trap or a segfault. Fix this race condition fully by performing any cache maintenance required to keep the icache & dcache in sync in set_pte_at, before the page is made valid. This has the added bonus of ensuring the cache maintenance always happens in one location, rather than being duplicated in flush_icache_page & update_mmu_cache. It also matches the way other architectures solve the same problem (see arm, ia64 & powerpc). Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reported-by: Ionela Voinescu <ionela.voinescu@imgtec.com> Cc: Lars Persson <lars.persson@axis.com> Fixes: 4d46a67a3eb8 ("MIPS: Fix race condition in lazy cache flushing.") Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: David Daney <david.daney@cavium.com> Cc: Huacai Chen <chenhc@lemote.com> Cc: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: stable <stable@vger.kernel.org> # v4.1+ Patchwork: https://patchwork.linux-mips.org/patch/12722/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cacheflush.h | 6 ------ arch/mips/include/asm/pgtable.h | 26 +++++++++++++++++++++----- arch/mips/mm/cache.c | 19 +++---------------- 3 files changed, 24 insertions(+), 27 deletions(-) commit f4281bba818105c7c91799abe40bc05c0dbdaa25 Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Mar 1 02:37:58 2016 +0000 MIPS: Handle highmem pages in __update_cache The following patch will expose __update_cache to highmem pages. Handle them by mapping them in for the duration of the cache maintenance, just like in __flush_dcache_page. The code for that isn't shared because we need the page address in __update_cache so sharing became messy. Given that the entirity is an extra 5 lines, just duplicate it. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Lars Persson <lars.persson@axis.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: stable <stable@vger.kernel.org> # v4.1+ Patchwork: https://patchwork.linux-mips.org/patch/12721/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/cache.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 234859e49a15323cf1b2331bdde7f658c4cb45fb Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Mar 1 02:37:57 2016 +0000 MIPS: Flush highmem pages in __flush_dcache_page When flush_dcache_page is called on an executable page, that page is about to be provided to userland & we can presume that the icache contains no valid entries for its address range. However if the icache does not fill from the dcache then we cannot presume that the pages content has been written back as far as the memories that the dcache will fill from (ie. L2 or further out). This was being done for lowmem pages, but not for highmem which can lead to icache corruption. Fix this by mapping highmem pages & flushing their content from the dcache in __flush_dcache_page before providing the page to userland, just as is done for lowmem pages. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Lars Persson <lars.persson@axis.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12720/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/cache.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 763fee97e743acb4f6e683a00fd2e7f5ad2484fb Author: Paul Burton <paul.burton@imgtec.com> Date: Tue Mar 1 02:37:56 2016 +0000 MIPS: Flush dcache for flush_kernel_dcache_page The flush_kernel_dcache_page function was previously essentially a nop. This is incorrect for MIPS, where if a page has been modified & either it aliases or it's executable & the icache doesn't fill from dcache then the content needs to be written back from dcache to the next level of the cache hierarchy (which is shared with the icache). Implement this by simply calling flush_dcache_page, treating this kmapped cache flush function (flush_kernel_dcache_page) exactly the same as its non-kmapped counterpart (flush_dcache_page). Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Lars Persson <lars.persson@axis.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12719/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cacheflush.h | 1 + 1 file changed, 1 insertion(+) commit b4f37b2f2f7ed83847c8010b2649ea03ff429f43 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Wed Mar 2 22:47:19 2016 +0200 MIPS: OCTEON: cavium_octeon_defconfig: enable all OCTEON SoC drivers Some drivers for SoC provided functionality are missing. Enable to those in defconfig to provide better build/testing coverage. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12750/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/configs/cavium_octeon_defconfig | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit b5a6455cde3d63466ac31bacdb42afcf30932f75 Author: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Date: Tue Mar 29 15:50:25 2016 +0100 MIPS: Detect DSP v3 support DSPv3 is supported on all MIPSr6 systems which indicate support for DSPv2. This doesn't require any changes to the kernel's handling of DSP resources. The patch is to detect support and indicate it in /proc/cpuinfo DSP v3 introduces a new instruction BPOSGE32C Signed-off-by: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Reviewed-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12918/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 4 ++++ arch/mips/include/asm/cpu.h | 1 + arch/mips/kernel/cpu-probe.c | 5 ++++- arch/mips/kernel/proc.c | 1 + 4 files changed, 10 insertions(+), 1 deletion(-) commit 157b9394709ed5233288986a293405def22792ed Author: Andrei Pistirica <andrei.pistirica@microchip.com> Date: Wed Jan 13 18:15:43 2016 -0700 serial: pic32_uart: Add PIC32 UART driver This adds UART and a serial console driver for Microchip PIC32 class devices. [ralf@linux-mips.org: Resolved merge conflict.] Signed-off-by: Andrei Pistirica <andrei.pistirica@microchip.com> Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Reviewed-by: Alan Cox <alan@linux.intel.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jiri Slaby <jslaby@suse.com> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-serial@vger.kernel.org Cc: linux-api@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12101/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/tty/serial/Kconfig | 21 + drivers/tty/serial/Makefile | 1 + drivers/tty/serial/pic32_uart.c | 960 +++++++++++++++++++++++++++++++++++++++ drivers/tty/serial/pic32_uart.h | 126 +++++ include/uapi/linux/serial_core.h | 3 + 5 files changed, 1111 insertions(+) commit 81dfdd39c76dc65f3a0fd5e6a231c3cbca9c49bc Author: Andrei Pistirica <andrei.pistirica@microchip.com> Date: Wed Jan 13 18:15:42 2016 -0700 dt/bindings: Add bindings for PIC32 UART driver Document the devicetree bindings for the UART peripheral found on Microchip PIC32 class devices. Signed-off-by: Andrei Pistirica <andrei.pistirica@microchip.com> Signed-off-by: Joshua Henderson <joshua.henderson@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12100/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../bindings/serial/microchip,pic32-uart.txt | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit 0c94fa33b4de55a0dcb60519ba04a0fd49da124d Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 13 16:17:14 2015 +0100 MIPS: cpu: Convert MIPS_CPU_* defs to (1ull << x) The MIPS_CPU_* definitions have now filled the first 32-bits, and are getting longer since they're written in hex without zero padding. Adding my 8 extra MIPS_CPU_* definitions which I haven't upstreamed yet this is getting increasingly ugly as the comments get shifted progressively to the right. Its also error prone, and I've seen this cause mistakes on 3 separate occasions now, not helped by it being a conflict hotspot. Convert all the MIPS_CPU_* definitions to the form (1ull << x). Humans are better at incrementing than shifting. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/10045/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 89 ++++++++++++++++++++++++--------------------- 1 file changed, 48 insertions(+), 41 deletions(-) commit c0291f7c735941f2cf5c8d5264c2cc2402b77869 Author: James Hogan <james.hogan@imgtec.com> Date: Wed May 13 16:17:13 2015 +0100 MIPS: cpu: Alter MIPS_CPU_* definitions to fill gap The MIPS_CPU_* definitions accidentally missed bits 27..30 when MIPS_CPU_EVA was added, and further definitions have continued from there. Shift all the definitions since MIPS_CPU_EVA right by 4 so there are no gaps. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/10044/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 738a3f79027bef44b0bd3bfcc325f53b518749d4 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Tue Feb 9 12:55:50 2016 -0800 MIPS: BMIPS: Add early CPU initialization code Port the stblinux-3.3 code to perform a bunch of CPU-specific initialization, make it compatible with run-time detection of the CPU, and unroll the brcmstb-specific macros: BDEV_RB(), BDEV_UNSET. The "pref 30" disabling is done as a quirk. This is a preliminary change to allow the use of the "rotr" instruction gated by cpu_has_rixi. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: pgynther@google.com Cc: paul.burton@imgtec.com Cc: ddaney.cavm@gmail.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12504/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/bmips/setup.c | 1 + arch/mips/include/asm/bmips.h | 1 + arch/mips/kernel/smp-bmips.c | 87 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 89 insertions(+) commit 036aff91c30a6f15d5bf25f22827abc26b6d06c1 Author: Maciej W. Rozycki <macro@imgtec.com> Date: Sat Jan 30 09:09:43 2016 +0000 MIPS: math-emu: dsemul: Remove an unused bit in ADDIUPC emulation Avoid a reader's confusion, as the calculation is correct either way. Signed-off-by: Maciej W. Rozycki <macro@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12283/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/math-emu/dsemul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c400d5ebec1828ee00acb53890741a62b45fb23b Author: Florian Fainelli <f.fainelli@gmail.com> Date: Sun Jan 31 12:29:27 2016 -0800 BUS: brcmstb_gisb: Hook to MIPS board_be_handler MIPS kernels allow platforms to invoke a custom Bus Error handler, add the necessary code to do this for Broadcom SoCs where the GISB bus error handler can be used. We may get a bus error from an address decoded outside of the GISB bus space, so we need to check the validity of such a capture before printing anything. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: cernekee@gmail.com Cc: arnd@arndb.de Cc: jaedon.shin@gmail.com Cc: pgynther@google.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12284/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/bus/brcmstb_gisb.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit 885872b722b73b2026a48bdff4621f289be2b044 Author: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Date: Wed Feb 3 18:01:36 2016 +0000 MIPS: Octeon: Add Octeon III CN7xxx interface detection Add basic CN7XXX interface detection. This allows the kernel to boot with ethernet working as it initializes the ethernet ports with SGMII instead of defaulting to RGMII routines. Tested on the utm8 from Rhino Labs with a CN7130. Signed-off-by: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> Acked-by: David Daney <david.daney@cavium.com> Cc: janne.huttunen@nokia.com Cc: aaro.koskinen@nokia.com Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12376/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/executive/cvmx-helper.c | 43 +++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 04cc89d120f94131de89a6e20da27016db4782ce Author: Ralf Baechle <ralf@linux-mips.org> Date: Sun Mar 27 00:07:14 2016 +0100 MIPS: Make flush_thread Avoids function calls to an empty function. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/processor.h | 4 ++++ arch/mips/kernel/process.c | 4 ---- 2 files changed, 4 insertions(+), 4 deletions(-) commit 5d3c792583b6040607e178925ccc8316a207210f Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Feb 4 13:05:05 2016 +0000 MIPS: Support R_MIPS_PC{16,21,26} rel-style relocs MIPS32 code uses rel-style relocs, and MIPS32r6 modules may include R_MIPS_PC16, R_MIPS_PC21 & R_MIPS_PC26 relocations. We thus need to support these relocations in order to load MIPS32r6 kernel modules. This patch adds such support, which is similar to the rela-style support in module-rela.c but making use of the implicit addend from the instruction encoding. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12435/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/module.c | 51 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) commit ad8319ea4647c897c837643a611714a83d8f6a0f Author: Paul Burton <paul.burton@imgtec.com> Date: Thu Feb 4 13:05:04 2016 +0000 MIPS: Support R_MIPS_PC{21,26} rela-style relocs MIPS64 code uses rela-style relocs, and MIPS64r6 modules may include the new R_MIPS_PC21 & R_MIPS_PC26 relocations. We thus need to support these relocations in order to load MIPS64r6 kernel modules. They are similar to the existing R_MIPS_PC16 relocation but applying to a wider field. Implement support for them by genericising the existing R_MIPS_PC16 implementation such that it can be used for different field widths, and calling it for all 3 reloc types. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Kees Cook <keescook@chromium.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12434/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/elf.h | 5 +++++ arch/mips/kernel/module-rela.c | 48 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 52 insertions(+), 1 deletion(-) commit 55d791f37c905b9ca68b96cdab89678654a5d16e Author: Steven J. Hill <Steven.Hill@imgtec.com> Date: Thu Feb 4 13:05:03 2016 +0000 MIPS: module: Make consistent use of pr_*() The module relocation handling code has inconsistent use of printk() and pr_*() functions. Convert printk() calls to use pr_err() and pr_warn(). [paul.burton@imgtec.com: Do the same thing in module.c] Signed-off-by: Steven J. Hill <sjhill@realitydiluted.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Andrey Konovalov <adech.fo@gmail.com> Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12433/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/module-rela.c | 8 +++----- arch/mips/kernel/module.c | 7 +++---- 2 files changed, 6 insertions(+), 9 deletions(-) commit 43aff742b64d8756d5612f4805af89635ae6c622 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 16:17:30 2016 +0000 MIPS: Probe the M6250 CPU Support probing the M6250 CPU now that cases for handling it have been added where required in the core MIPS kernel code. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12375/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cpu-probe.c | 4 ++++ 1 file changed, 4 insertions(+) commit 1dbf6a81c845a748e46b4bcaf25d958038624ad8 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 16:17:29 2016 +0000 MIPS: Add M6250 cases to CPU switch statements Add casses supporting the M6250 CPU to various switch statements in the core MIPS kernel code that define behaviour dependent upon the CPU. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Maciej W. Rozycki <macro@codesourcery.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12374/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-type.h | 4 ++++ arch/mips/mm/c-r4k.c | 1 + 2 files changed, 5 insertions(+) commit df8b1a5ee9f7f5fbb5e8f0df9537c648481019ea Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 16:17:28 2016 +0000 MIPS: Add M6250 PRID & cpu_type_enum values Define the processor ID for the M6250 CPU and add a value to the enum cpu_type_enum for the core. [ralf@linux-mips.org: Fix merge conflict.] Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12373/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit eba20a3a37ff9fe8a4ae99f108ee4ce52db61247 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:26:39 2016 +0000 MIPS: Probe the P6600 core Support probing the P6600 core now that cases for handling it have been added throughout the core MIPS kernel code. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12344/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cpu-probe.c | 4 ++++ 1 file changed, 4 insertions(+) commit 1091bfa20b94ba14a3c8a3eaf3a5b9d3df975da2 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:26:38 2016 +0000 MIPS: Add P6600 cases to CPU switch statements Add cases supporting the P6600 CPU to various switch statements in core MIPS kernel code that define behaviour dependent upon the CPU. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Joshua Kinard <kumba@gentoo.org> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Petri Gynther <pgynther@google.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12343/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-type.h | 1 + arch/mips/kernel/cpu-probe.c | 1 + arch/mips/kernel/perf_event_mipsxx.c | 6 ++++++ arch/mips/kernel/spram.c | 1 + arch/mips/kernel/traps.c | 1 + arch/mips/mm/c-r4k.c | 1 + arch/mips/mm/sc-mips.c | 1 + 7 files changed, 12 insertions(+) commit 5cd0d5beef2bf34e3ec850aa75637e73fd8f5f82 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:26:37 2016 +0000 MIPS: Add P6600 PRID & cpu_type_enum values Define the processor ID for the P6600 core and add a value to the enum cpu_type_enum for the core. [ralf@linux-mips.org: Fix merge conflict.] Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12342/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit bff3d472b82300274cac16007d76a70d67c7a643 Author: Ralf Baechle <ralf@linux-mips.org> Date: Fri Mar 25 00:41:58 2016 +0100 MIPS: <asm/cpu.h>: Reformat to 80 columns. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d4594b2763f2cb5bc13ca05e312a389d15462cdf Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 12:06:35 2016 +0000 MIPS: SEAD3 can support MIPS32r6 CPUs There are CPUs/bitfiles available for use with SEAD3 boards which implement release 6 of the MIPS architecture. Allow building the kernel for such a system. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12372/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 6609ccdc852f7bfbfa54300dd5b3cd89eb4ced6f Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:35 2016 +0000 MIPS: smp-cps: Stop printing EJTAG exceptions to UART When CONFIG_MIPS_CPS_NS16550 is enabled, some register state is dumped to the UART when an exception is taken via the BEV on secondary cores. EJTAG exceptions are architecturally expected to be handled by the BEV even when Status.BEV is 0. This effectively means that if userland executes an sdbbp instruction on a secondary core then the kernel dumps register state to the UART even though the exception is perfectly normal & expected. Prevent this by simply not dumping information to the UART for EJTAG exceptions. Fixes: 609cf6f2291a ("MIPS: CPS: Early debug using an ns16550-compatible UART") Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12341/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cps-vec.S | 1 - 1 file changed, 1 deletion(-) commit 6422a913856716be080dba4c2cb9d083d4e244ed Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:34 2016 +0000 MIPS: smp-cps: Add nothreads kernel parameter When debugging a new system or core it can be useful to disable the use of multithreading. Introduce a "nothreads" kernel command line parameter that can be set in order to do so. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Niklas Cassel <niklas.cassel@axis.com> Cc: Ezequiel Garcia <ezequiel.garcia@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12340/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/smp-cps.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 5a3e7c02d84fd31e6a2b1b242612363b6131a09e Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:33 2016 +0000 MIPS: smp-cps: Support MIPSr6 Virtual Processors Introduce support for bringing up Virtual Processors in MIPSr6 systems as CPUs, much like their VPE parallel from the now-deprecated MT ASE. The existing mips_cps_boot_vpes function fits the MIPSr6 architecture pretty well - it can now simply write the mask of running VPs to the VC_RUN register, rather than looping through each & starting or stopping as appropriate as is done for VPEs from the MT ASE. Thus the VP support is in general an extension & simplification of the existing MT ASE VPE (aka SMVP) support. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: Niklas Cassel <niklas.cassel@axis.com> Cc: Ezequiel Garcia <ezequiel.garcia@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12339/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 +- arch/mips/include/asm/cpu-info.h | 4 +-- arch/mips/kernel/cps-vec.S | 53 ++++++++++++++++++++++++++++++++++++++-- arch/mips/kernel/smp-cps.c | 35 +++++++++++++++++++++++--- 4 files changed, 85 insertions(+), 9 deletions(-) commit 87a70bcdb41008decfcf7c217e26b0bcd7f52642 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:32 2016 +0000 MIPS: smp-cps: Skip core setup if coherent In preparation for supporting MIPSr6 multithreading (ie. VPs) which will begin execution from the core reset vector, skip core level setup if the core is already coherent. This is never the case when a core is first started, since boot_core explicitly clears the cores GCR_Cx_COH_EN register, and always the case when secondary VPs start since the first VP to start will have enabled coherence after initialising the core & its caches. One notable side effect of this patch is that eva_init gets called slightly earlier, prior to mips_cps_core_init rather than after it. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12338/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cps-vec.S | 39 ++++++++++++++++++++++++--------------- 1 file changed, 24 insertions(+), 15 deletions(-) commit f12401d7219f5a1e361ded834016e5777a10262b Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:31 2016 +0000 MIPS: smp-cps: Pull boot config retrieval out of mips_cps_boot_vpes The mips_cps_boot_vpes function previously included code to retrieve pointers to the core & VPE boot configuration structs. These structures were used both by mips_cps_boot_vpes and by its mips_cps_core_entry callsite. In preparation for skipping the call to mips_cps_boot_vpes on some invocations of mips_cps_core_entry, pull the calculation of those pointers out into a separate function such that it can continue to be shared. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Niklas Cassel <niklas.cassel@axis.com> Cc: Ezequiel Garcia <ezequiel.garcia@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12337/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/smp-cps.h | 2 +- arch/mips/kernel/cps-vec.S | 74 +++++++++++++++++++++++++---------------- arch/mips/kernel/smp-cps.c | 7 ++-- 3 files changed, 52 insertions(+), 31 deletions(-) commit 3dbc9971618ba0e88f25f2168aa5731b53af6f0b Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:30 2016 +0000 MIPS: smp-cps: Pull cache init into a function In preparation for further modifications to mips_cps_core_entry, pull the L1 cache initialisation out into a separate function. This both makes the code in mips_cps_core_entry read more clearly, particularly when modifying it, and shortens it which will become important as code is added that needs to continue to fit within the reset vector. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12336/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/cps-vec.S | 143 ++++++++++++++++++++++++--------------------- 1 file changed, 76 insertions(+), 67 deletions(-) commit ba1c0a490a1fa61971b1cf9dd89acc7b4424e798 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:29 2016 +0000 MIPS: smp-cps: Ensure our VP ident calculation is correct When bringing up a CPU, ensure that its local ID as provided by the GIC matches up with our calculation of it. This is vital, since if the condition doesn't hold then we won't have configured interrupts correctly for the VP. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Niklas Cassel <niklas.cassel@axis.com> Cc: Ezequiel Garcia <ezequiel.garcia@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12335/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/smp-cps.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 835d2b452969820fd67a755a2c01fb6e12822448 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:28 2016 +0000 irqchip: mips-gic: Provide VP ID accessor Provide a gic_read_local_vp_id() function to read the VCNUM field of the GICs local VP_IDENT register. This will be used by a further patch to check that the value reported by the GIC matches up with the kernels calculation. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Acked-by: Jason Cooper <jason@lakedaemon.net> Cc: Andrew Bresticker <abrestic@chromium.org> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: James Hogan <james.hogan@imgtec.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12334/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/irqchip/irq-mips-gic.c | 8 ++++++++ include/linux/irqchip/mips-gic.h | 17 +++++++++++++++++ 2 files changed, 25 insertions(+) commit d46812bb0bef04efa4e6cba677ba54c2e4f1ae59 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:27 2016 +0000 irqchip: mips-gic: Use HW IDs for VPE_OTHER_ADDR The Linux CPU number doesn't necessarily match up with the ID used for a VP by hardware. Convert the CPU number to the HW ID using mips_cm_vp_id when writing to the VP(E)_OTHER_ADDR register in order to ensure that we correctly access registers for the VPs of secondary cores. This most notably affects systems using CM3, such as those based around I6400. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Acked-by: Jason Cooper <jason@lakedaemon.net> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12333/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> drivers/irqchip/irq-mips-gic.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit a60ae81e5e5918138703f22427dd8f2445985b55 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:26 2016 +0000 MIPS: CM: Fix mips_cm_max_vp_width for UP kernels Fix mips_cm_max_vp_width for UP kernels where it previously referenced smp_num_siblings, which is not declared for UP kernels. This led to build errors such as the following: drivers/built-in.o: In function `$L446': irq-mips-gic.c:(.text+0x1994): undefined reference to `smp_num_siblings' drivers/built-in.o:irq-mips-gic.c:(.text+0x199c): more undefined references to `smp_num_siblings' follow On UP kernels simply return 1, leaving the reference to smp_num_siblings in place only for SMP kernels. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12332/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips-cm.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit db8e00af7b4a09ef5924140c1c42494fc88204ef Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:25 2016 +0000 MIPS: CM: Add CM GCR_BEV_BASE accessors Generate accessor functions for the GCR_BEV_BASE register introduced by CM3, for use by a later patch. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Matt Redfearn <matt.redfearn@imgtec.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12331/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips-cm.h | 1 + 1 file changed, 1 insertion(+) commit 88036557bac3c831a564dcd6c860da48ae55756f Author: Markos Chandras <markos.chandras@imgtec.com> Date: Wed Feb 3 03:15:24 2016 +0000 MIPS: CPC: Add start, stop and running CM3 CPC registers Add the new CM3 registers for controlling bringing up and powering down VPs on MIPSR6 cores. Signed-off-by: Markos Chandras <markos.chandras@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Bjorn Helgaas <bhelgaas@google.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12330/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips-cpc.h | 3 +++ 1 file changed, 3 insertions(+) commit 0f2a1484487407390196ca5b3c3a07bee6df15ad Author: Markos Chandras <markos.chandras@imgtec.com> Date: Wed Feb 3 03:15:23 2016 +0000 MIPS: pm-cps: Avoid offset overflow on MIPSr6 This is similar to commit 934c79231c1b ("MIPS: asm: r4kcache: Add MIPS R6 cache unroll functions"). The CACHE instruction has been redefined for MIPSr6 and it reduced its offset field to 8 bits. This leads to micro-assembler field overflow warnings when booting SMP MIPSr6 cores like the following one: Call Trace: [<ffffffff8010af88>] show_stack+0x68/0x88 [<ffffffff8056ddf0>] dump_stack+0x68/0x88 [<ffffffff801305bc>] warn_slowpath_common+0x8c/0xc8 [<ffffffff80130630>] warn_slowpath_fmt+0x38/0x48 [<ffffffff80125814>] build_insn+0x514/0x5c0 [<ffffffff806ee134>] cps_gen_cache_routine.isra.3+0xe0/0x1b8 [<ffffffff806ee570>] cps_pm_init+0x364/0x9ec [<ffffffff80100538>] do_one_initcall+0x90/0x1a8 [<ffffffff806e8c14>] kernel_init_freeable+0x160/0x21c [<ffffffff8056b6a0>] kernel_init+0x10/0xf8 [<ffffffff801059f8>] ret_from_kernel_thread+0x14/0x1c We fix this by incrementing the base register on every loop. Signed-off-by: Markos Chandras <markos.chandras@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12329/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/pm-cps.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit 04d83f948510f17f8f2ab320b2386f4b5fbd0bd4 Author: Markos Chandras <markos.chandras@imgtec.com> Date: Wed Feb 3 03:15:22 2016 +0000 MIPS: traps: Make sure secondary cores have a sane ebase register We shouldn't trust that the secondary cores will have a sane ebase register (either from the bootloader or during the hardware design phase) so use the ebase address as calculated by the boot CPU. Signed-off-by: Markos Chandras <markos.chandras@imgtec.com> Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Cc: James Hogan <james.hogan@imgtec.com> Cc: Petri Gynther <pgynther@google.com> Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12328/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/traps.c | 7 +++++++ 1 file changed, 7 insertions(+) commit f270d881fa552c9c21c37417af2bf95da9a74347 Author: Paul Burton <paul.burton@imgtec.com> Date: Wed Feb 3 03:15:21 2016 +0000 MIPS: Detect MIPSr6 Virtual Processor support MIPSr6 introduces support for "Virtual Processors", which are conceptually similar to VPEs from the now-deprecated MT ASE. Detect whether the system supports VPs using the VP bit in Config5, adding cpu_has_vp for use by later patches. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: Maciej W. Rozycki <macro@imgtec.com> Cc: Joshua Kinard <kumba@gentoo.org> Cc: Steven J. Hill <sjhill@realitydiluted.com> Cc: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12327/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu-features.h | 4 ++++ arch/mips/include/asm/cpu.h | 1 + arch/mips/include/asm/mipsregs.h | 1 + arch/mips/kernel/cpu-probe.c | 2 ++ 4 files changed, 8 insertions(+) commit 98c1c5078deba1feb9c040eb7708a299e41a8d84 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:25 2016 +0300 MIPS: ath79: add initial support for DPT-Module The following features are supported: * UART; * SPI-flash; * USB host; * GPIO key and LED. Links: * https://dptechnics.com/shop/index.php?route=product/product&path=59&product_id=50 * https://dptechnics.com/shop/index.php?route=product/product&path=59&product_id=63 Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Daan Pape <daan@dptechnics.com> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12886/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/Makefile | 1 + arch/mips/boot/dts/qca/ar9331_dpt_module.dts | 78 ++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+) commit f40aec27ea9943c01db34ef95317768073e8d118 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:24 2016 +0300 devicetree: add DPTechnics vendor id Please see https://www.dptechnics.com/contact for details. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Daan Pape <daan@dptechnics.com> Cc: devicetree@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12885/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 930c54ff39fcbe988c2eecf1ae52764c780fe893 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:23 2016 +0300 MIPS: ath79: add initial support for Onion Omega The following features are supported: * UART; * SPI-flash; * USB host; * GPIO key and LED. Please see https://onion.io/omega for details. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: L. D. Pinney <ldpinney@gmail.com> Cc: Boken Lin <bl@onion.io> Cc: Jacky Huang <huangfangcheng@163.com> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12884/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/Makefile | 1 + arch/mips/boot/dts/qca/ar9331_omega.dts | 78 +++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+) commit e454cc4943c9e7e0d46ef78c368dc0a630e02461 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:22 2016 +0300 devicetree: add Onion Corporation vendor id Please see https://onion.io/contact for details. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12883/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 3b9ec1b32585438eddd6ec28029fd9620213027d Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:21 2016 +0300 MIPS: ath79: add initial support for Dragino MS14 (Dragino 2) The following features are supported: * UART; * SPI-flash; * USB host; * GPIO keys and LEDs. Links: * http://www.dragino.com/products/mother-board/item/71-ms14-p.html * https://wiki.openwrt.org/toh/dragino/ms14 Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12882/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/Makefile | 1 + arch/mips/boot/dts/qca/ar9331_dragino_ms14.dts | 102 +++++++++++++++++++++++++ 2 files changed, 103 insertions(+) commit 4d536731f8169477ed0f908c9bc30a3a997841de Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:20 2016 +0300 devicetree: add Dragino vendor id Please see http://www.dragino.com/about/about.html for details. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12881/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 2c3694d2e6ead3964aafb31e4e529de219ced92b Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:19 2016 +0300 MIPS: ath79: add initial support for TP-LINK MR3020 The following features are supported: * UART; * SPI-flash; * USB host; * GPIO keys and LEDs. Links: * http://www.tp-link.com/en/products/details/?model=TL-MR3020 * http://wiki.openwrt.org/toh/tp-link/tl-mr3020 * https://wikidevi.com/wiki/TP-LINK_TL-MR3020 Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12880/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/Makefile | 1 + arch/mips/boot/dts/qca/ar9331_tl_mr3020.dts | 118 ++++++++++++++++++++++++++++ 2 files changed, 119 insertions(+) commit 5ae5c452e3361612cd8182eb8bdfecf0ebf42288 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:18 2016 +0300 MIPS: ath79: update devicetree clock support for AR9331 Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-clk@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12879/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/clock.c | 96 +++++++++++++++++++++++++++++++------------------ 1 file changed, 62 insertions(+), 34 deletions(-) commit 1e6a3492e7bb12aa8ee26050ff6829c39ebaa152 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:17 2016 +0300 MIPS: dts: qca: introduce AR9331 devicetree This patch introduces devicetree for Atheros AR9331 SoC (AKA Hornet). The AR9331 chip is a Wi-Fi System-On-Chip (WiSOC), typically used in very cheap Access Points and Routers. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12878/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/ar9331.dtsi | 155 +++++++++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) commit f4fe969d7f43d92505b09adad2ae93ccaa453ae0 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:16 2016 +0300 MIPS: ath79: Disable platform code for OF boards. For OF boards we have to skip platform initialization code so we can prove that OF code do all necessary initialization. [ralf@linux-mips.org: Fix merge conflict.] Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Reviewed-by: Marek Vasut <marex@denx.de> Cc: Alban Bedel <albeu@free.fr> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12877/ Patchwork: https://patchwork.linux-mips.org/patch/12920/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/setup.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 3bdf1071ba7de08c55a5cce54964ded7c0c8540d Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:15 2016 +0300 MIPS: ath79: update devicetree clock support for AR9132 Current ath79 clock.c code does not read reference clock and pll setup from devicetree. E.g. you can set any clock rate value in board DTS but it will have no effect on the real clk calculation. This patch fixes some AR9132 devicetree clock support defects: * clk initialization function ath79_clocks_init_dt_ng() is introduced; it actually gets pll block base register address and reference clock from devicetree; * pll register parsing code is moved to the separate ar724x_clk_init() function; this function can be called from platform code or from devicetree code. Also mips_hpt_frequency value is set from dt, so the appropriate clock parameter is added to the cpu@0 devicetree node. The same approach can be used for adding AR9331 devicetree support. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-clk@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12876/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/clock.c | 96 ++++++++++++++++++++++++++++---------- arch/mips/ath79/setup.c | 36 ++++++++++++++ arch/mips/boot/dts/qca/ar9132.dtsi | 1 + 3 files changed, 108 insertions(+), 25 deletions(-) commit af5ad0de22480a452049e0e942b10af77ef60530 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:14 2016 +0300 MIPS: ath79: Introduce <dt-bindings/clock/ath79-clk.h> The include/dt-bindings/clock/ath79-clk.h header file is introduced so we can use symbolic identifiers for SoC clocks. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: Alban Bedel <albeu@free.fr> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-mips@linux-mips.org Cc: linux-clk@vger.kernel.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12875/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/clock.c | 33 +++++++++++++++++---------------- arch/mips/boot/dts/qca/ar9132.dtsi | 8 +++++--- include/dt-bindings/clock/ath79-clk.h | 19 +++++++++++++++++++ 3 files changed, 41 insertions(+), 19 deletions(-) commit 83fe838466ec9bfcba4f477656cb9a67172d2c29 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:12 2016 +0300 MIPS: dts: qca: ar9132: use short references for dt nodes Here are some Sascha Hauer's arguments for using aliases in the dts files: - using aliases reduces the number of indentations in dts files; - dts files become independent of the layout of the dtsi files (it becomes possible to introduce another bus {} hierarchy between a toplevel bus and the devices when you have to); - less chances for typos. if &i2c2 does not exist you get an error. If instead you duplicate the whole path in the dts file a typo in the path will just create another node. Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Cc: Alban Bedel <albeu@free.fr> Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Rob Herring <robh+dt@kernel.org> Cc: Frank Rowand <frowand.list@gmail.com> Cc: Grant Likely <grant.likely@linaro.org> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12873/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/ar9132.dtsi | 8 +- arch/mips/boot/dts/qca/ar9132_tl_wr1043nd_v1.dts | 94 ++++++++++++------------ 2 files changed, 49 insertions(+), 53 deletions(-) commit 2cdfec1bbb0a093836f6a471ca15e4e26f8b6401 Author: Antony Pavlov <antonynpavlov@gmail.com> Date: Thu Mar 17 06:34:11 2016 +0300 MIPS: dts: qca: ar9132_tl_wr1043nd_v1.dts: drop unused alias node The TP-LINK TL-WR1043ND board has only one serial port, so replacing the default of 0 with 0 does nothing useful. Moreover, the correct name for aliases node is "aliases" not "alias". An overview of the "aliases" node usage can be found on the device tree usage page at devicetree.org [1]. Also please see chapter 3.3 ("Aliases node") of the ePAPR 1.1 [2]. [1] http://devicetree.org/Device_Tree_Usage#aliases_Node [2] https://www.power.org/documentation/epapr-version-1-1/ Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com> Acked-by: Alban Bedel <albeu@free.fr> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12872/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/qca/ar9132_tl_wr1043nd_v1.dts | 4 ---- 1 file changed, 4 deletions(-) commit e791dfb5fb91c05ce027d147042c5061d0f5cf89 Author: Hauke Mehrtens <hauke@hauke-m.de> Date: Sat Mar 19 18:28:52 2016 +0100 MIPS: Lantiq: Make it possible to build in no device tree Now it is possible to build in no device tree at all and depend on the boot loader providing one or someone concatenating a device tree to the end of the image. This was copied from arch/mips/bmips/Kconfig Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12899/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lantiq/Kconfig | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 84f47cf49e3c8348f4a0a04e8fa2404f1e2722cc Author: Hauke Mehrtens <hauke@hauke-m.de> Date: Sat Mar 19 18:28:51 2016 +0100 MIPS: Lantiq: Add support for device tree file from boot loader This fetches the device tree file like it is specified in the MIPS UHI interface if one was found. This is also used when the device tree file was appended to the kernel image with cat. This code is copied from arch/mips/bmips/setup.c. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Acked-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12898/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lantiq/prom.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 842c1e2c4aaa94ec314d2b0f6595cfb85f42b09d Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Tue Mar 8 23:32:27 2016 +0200 MIPS: Octeon: Add DTS for EdgeRouter Lite Add DTS for EdgeRouter Lite that is usable as is without any "pruning" with APPENDED_DTB. Compared to builtin generic DTB, we can avoid errors and delays from probing non-existent I2C devices. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/cavium-octeon/ubnt_e100.dts | 59 ++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) commit fa0a497b9e13cd3c494dbbb93b156752fd15fdd2 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Tue Mar 8 23:32:26 2016 +0200 MIPS: Octeon: Add DTS for D-Link DSR-1000N Add DTS for D-Link DSR-1000N that is usable as is without any "pruning" with APPENDED_DTB. Split out the common parts from octeon_3xxx.dts into octeon_3xxx.dtsi. Compared to builtin generic DTB, we can specificy fixed links properly and avoid probing non-existent I2C devices. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Cc: devicetree@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12840/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../boot/dts/cavium-octeon/dlink_dsr-1000n.dts | 78 +++++++ arch/mips/boot/dts/cavium-octeon/octeon_3xxx.dts | 205 +----------------- arch/mips/boot/dts/cavium-octeon/octeon_3xxx.dtsi | 231 +++++++++++++++++++++ 3 files changed, 312 insertions(+), 202 deletions(-) commit 99a7a234c890177c4d4f2b0fb02317ef19c364a2 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Wed Mar 9 22:08:42 2016 +0200 MIPS: panic immediately when panic_on_oops MIPS wants to sleep 5 seconds before panicking when panic_on_oops is set, with no apparent reason. Remove this feature, since some users may want their systems to fail as quickly as possible. Users who want to delay reboot after panic can use PANIC_TIMEOUT. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: James E.J. Bottomley <jejb@parisc-linux.org> Cc: Helge Deller <deller@gmx.de> Cc: linux-mips@linux-mips.org Cc: linux-parisc@vger.kernel.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12845/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/traps.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 2ab71a02c56f8244ac611b5c6e6603c6fe83b966 Author: Rafał Miłecki <zajec5@gmail.com> Date: Mon Jan 25 09:50:29 2016 +0100 MIPS: BCM47xx: Move SPROM driver to drivers/firmware/ Broadcom ARM home routers store SPROM content in NVRAM just like MIPS ones. To share SPROM code we need to move it out of arch/mips/ to some common place. We already have bcm47xx_nvram in firmware path and SPROM should fit there as well. This driver is responsible for parsing SoC configuration data into a struct shared between ssb and bcma buses. This was tested with BCM4706 & BCM5357C0 (BCM47XX) and BCM4708A0 (ARCH_BCM_5301X). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Cc: Hauke Mehrtens <hauke@hauke-m.de> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12210/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 1 + arch/mips/bcm47xx/Makefile | 2 +- arch/mips/bcm47xx/bcm47xx_private.h | 3 - arch/mips/bcm47xx/setup.c | 2 +- arch/mips/bcm47xx/sprom.c | 724 ----------------------------- drivers/firmware/broadcom/Kconfig | 11 + drivers/firmware/broadcom/Makefile | 1 + drivers/firmware/broadcom/bcm47xx_sprom.c | 737 ++++++++++++++++++++++++++++++ include/linux/bcm47xx_sprom.h | 24 + 9 files changed, 776 insertions(+), 729 deletions(-) commit b11d022767f78357f08bc3d548e99af1c6cf7808 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Thu Feb 25 10:45:47 2016 +0100 MIPS: ralink: Make reset_control_ops const The reset_ops structure is never modified. Make it const. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Cc: kernel@pengutronix.de Patchwork: https://patchwork.linux-mips.org/patch/12618/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ralink/reset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 24bc827beb2b0dea026015914924aede9c278a90 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Thu Feb 25 10:45:46 2016 +0100 MIPS: lantiq: Make reset_control_ops const The reset_ops structure is never modified. Make it const. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: John Crispin <john@phrozen.org> Cc: linux-mips@linux-mips.org Cc: kernel@pengutronix.de Patchwork: https://patchwork.linux-mips.org/patch/12619/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lantiq/xway/reset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2296cecf719caad9bcda3c8b82830fe3736ffa90 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Wed Feb 24 00:52:07 2016 +0200 MIPS: Octeon: device_tree_init: fill mac addresses when using appended dtb Fill MAC addresses from bootinfo when using appended DTB. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12590/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 377de399a1ad191b1c67aca99cfbc65061639f07 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Wed Feb 24 00:52:06 2016 +0200 MIPS: Octeon: device_tree_init: don't fill mac if already set Don't fill MAC address if it's already set. This allows DTB to override the bootinfo. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12589/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/octeon-platform.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 43349b9e4bb008a2fb7e92de53fe2aa1ccf8ea24 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Wed Feb 24 00:52:05 2016 +0200 MIPS: Octeon: device_tree_init: use separate pass to fill mac addresses Use separate pass to fill MAC addresses. This is needed because we want to do this also for the appended DTB. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Acked-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12588/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/octeon-platform.c | 86 +++++++++++++++++++++++++------ arch/mips/cavium-octeon/setup.c | 2 + 2 files changed, 72 insertions(+), 16 deletions(-) commit 1a1590ab1a4a0898fe0a6809e5bcd7c225e3b4d6 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Tue Feb 23 00:22:57 2016 +0200 MIPS: Octeon: Use model string from DTB for unknown board type Use model string from DTB for board type if the board is unknown. This is more informative, e.g. with EdgeRouter Pro the /proc/cpuinfo will display "ubnt,e200 (CN6120p1.1-1000-NSP)" instead of misleading "Unsupported Board". Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12582/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 8f2068bc9e875540b5fb372294095833651ea1e2 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Tue Feb 23 00:22:56 2016 +0200 MIPS: Octeon: Initialize system type string after device tree init. Initialize system type string after device tree init. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12583/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 6ecffafe242ec6d2789631499452c54177f0bb4c Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Tue Feb 23 00:22:55 2016 +0200 MIPS: Octeon: board_type_to_string: return NULL for unsupported board Return NULL for unsupported board. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12581/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 9 +++++++-- arch/mips/include/asm/octeon/cvmx-bootinfo.h | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) commit 490f7548cfce36b63ec517a8ff7382287db86c29 Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:13 2016 -0800 MIPS: OCTEON: Simplify code in octeon_irq_ciu_gpio_set_type() Use the trigger type passed in to the function instead of reading it back out of the irq_data. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12501/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/octeon-irq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c6d2b22eb5211e96e932428bc1183c6ad57d5e54 Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:12 2016 -0800 MIPS: OCTEON: Add SMP support for OCTEON cn78xx et al. OCTEON chips with the CIU3 interrupt controller use a different IPI mechanism that previous models. Add plat_smp_ops for the cn78xx and probing code to choose between the two types of ops. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12499/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 4 +- arch/mips/cavium-octeon/smp.c | 145 +++++++++++++++++++++++++++++++--- arch/mips/include/asm/octeon/octeon.h | 6 ++ 3 files changed, 139 insertions(+), 16 deletions(-) commit ce210d35bb93c2c5c8857878123275ecdcfd7018 Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:11 2016 -0800 MIPS: OCTEON: Add support for OCTEON III interrupt controller. Add irq_chip support for both IPI and "normal" interrupts of the CIU3 controller. Document the device tree binding for the CIU3. Some functions are non-static as they will be used by follow-on support for MSI-X. Signed-off-by: David Daney <david.daney@cavium.com> Acked-by: Rob Herring <robh@kernel.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: devicetree@vger.kernel.org Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12500/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> .../devicetree/bindings/mips/cavium/ciu3.txt | 27 + arch/mips/cavium-octeon/octeon-irq.c | 650 ++++++++++++++++++++- arch/mips/include/asm/octeon/octeon.h | 19 + 3 files changed, 695 insertions(+), 1 deletion(-) commit 9bc22239956e3877d085b843bfe89ab2a98ab50a Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:10 2016 -0800 MIPS: OCTEON: Don't attempt to use nonexistent registers on OCTEON III models. Attempts to read the nonexistent registers results in bus errors. Either use registers that exist, or don't do the access as appropriate. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12502/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/csrc-octeon.c | 13 +++++++++---- arch/mips/cavium-octeon/setup.c | 34 +++++++++++++++++++++------------- 2 files changed, 30 insertions(+), 17 deletions(-) commit 182a6d1cd393226350ec22d973d2139adb194daa Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:09 2016 -0800 MIPS: OCTEON: Add model checking support for cn73xx, cnf75xx and cn78xx Follow on patchs need to be able to distinguish the new models. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12498/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/executive/octeon-model.c | 82 +++++++++++++++++++++++- arch/mips/include/asm/octeon/cvmx.h | 27 +++++++- arch/mips/include/asm/octeon/octeon-feature.h | 19 +++++- arch/mips/include/asm/octeon/octeon-model.h | 5 ++ 4 files changed, 125 insertions(+), 8 deletions(-) commit 2df11221bdc32f62ff1d8b6b945a8b19bf2a681c Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:08 2016 -0800 MIPS: OCTEON: Add register definitions for cn73xx, cnf75xx and cn78xx. These new members of the OCTEON III family have some new registers, update some of the definitions for use in follow on patches. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12497/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/octeon/cvmx-ciu3-defs.h | 353 ++++++++++++++++++++++ arch/mips/include/asm/octeon/cvmx-fpa-defs.h | 1 + arch/mips/include/asm/octeon/cvmx-mio-defs.h | 410 +++++++++++++++++++++++++- 3 files changed, 748 insertions(+), 16 deletions(-) commit 1d2753a66acbb101a0ec495cd13b9031ac1b171f Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:07 2016 -0800 MIPS: Select CONFIG_HANDLE_DOMAIN_IRQ and make it work. Per the subject, always select HANDLE_DOMAIN_IRQ, and implement set_irq_regs() so that it actually works. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12496/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 1 + arch/mips/include/asm/irq_regs.h | 10 ++++++++++ 2 files changed, 11 insertions(+) commit 2253e0b9d991e82210dd08c89bf91584ad25f993 Author: David Daney <david.daney@cavium.com> Date: Tue Feb 9 11:00:06 2016 -0800 MIPS: OCTEON: Remove some code limiting NR_IRQS to 255 Follow-on patches for OCTEON III will increase the number of irqs to potentially more than 256. Increase the width of the octeon_irq_ciu_to_irq to int to be able to handle this case. Remove the hacky code that verified that u8 would not be overflowed. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12495/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/octeon-irq.c | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) commit 7d52ab163c75bb830185f7ea12bae1db87f12b56 Author: David Daney <david.daney@cavium.com> Date: Mon Feb 1 17:46:54 2016 -0800 MIPS: OCTEON: Extend number of supported CPUs past 32 To support more than 48 CPUs, the bootinfo structure grows a new coremask structure. Add the definition of the structure and add it to struct cvmx_bootinfo. In prom_init(), copy the new coremask data into the sysinfo structure, and use it in smp_setup(). Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12319/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/setup.c | 19 +++++- arch/mips/cavium-octeon/smp.c | 4 +- arch/mips/include/asm/octeon/cvmx-bootinfo.h | 14 ++++- arch/mips/include/asm/octeon/cvmx-coremask.h | 89 ++++++++++++++++++++++++++++ arch/mips/include/asm/octeon/cvmx-sysinfo.h | 7 ++- 5 files changed, 125 insertions(+), 8 deletions(-) commit 58546e3b735cc9f695bba1559be76a68b072761f Author: David Daney <david.daney@cavium.com> Date: Mon Feb 1 17:46:53 2016 -0800 MIPS: OCTEON: Remove dead code from cvmx-sysinfo. Get rid of the long unused code. Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12318/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/executive/cvmx-sysinfo.c | 72 ++---------------------- arch/mips/include/asm/octeon/cvmx-sysinfo.h | 30 +--------- 2 files changed, 5 insertions(+), 97 deletions(-) commit b8c8f665076604762fd15eb815f2fd75eb511b2e Author: David Daney <david.daney@cavium.com> Date: Mon Feb 1 14:43:41 2016 -0800 MIPS: Add CPU identifiers and probing for Cavium CN73xx and CNF75xx processors. Add new processor identifiers for Cavium CN73xx and CNF75xx processors, and probe for them in cpu-probe.c Signed-off-by: David Daney <david.daney@cavium.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12311/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/cpu.h | 2 ++ arch/mips/kernel/cpu-probe.c | 2 ++ 2 files changed, 4 insertions(+) commit 34ae8e3688fb8af2afaf52b78c6f20c74c6ae650 Author: Ralf Baechle <ralf@linux-mips.org> Date: Thu Jan 28 14:26:00 2016 +0100 MIPS: highmem: Turn flush_cache_kmaps into a no-op. It was calling flush_cache_all() which is a no-op since a long time anyway and which was overkill in the old days when it was actually doing something because only the D-cache needs to be flushed, never the I-cache, never the S-cache. Since however highmem on MIPS is still only supported on processors that don't suffer from cache aliases, we could turn flush_cache_kmaps() into a no-op - but for paranoia's sake we rather make it BUG_ON(cpu_has_dc_aliases()). Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/highmem.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 429365b2a1a90b593a730f54819a4c5dfd98553b Author: Ralf Baechle <ralf@linux-mips.org> Date: Wed Jan 27 19:02:12 2016 +0100 MIPS: Loongson64: Remove call to flush_cache_all(). flush_cache_all() is a nop and loongson 3 is fully coherent. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/loongson64/loongson-3/smp.c | 1 - 1 file changed, 1 deletion(-) commit a48ac3a131c1675de4c8293f59f6864db2a83240 Author: Ralf Baechle <ralf@linux-mips.org> Date: Wed Jan 27 18:39:33 2016 +0100 MIPS: VR41xx: Use __flush_cache_all instead of flush_cache_all. It's probably a good idea to flush caches before reset and by the time this code was written flush_cache_all did actually still do something. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/vr41xx/common/pmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7c8196fd43e41e7b699d2f7a54bafd10dd2f65bb Author: Ralf Baechle <ralf@linux-mips.org> Date: Wed Jan 27 18:16:15 2016 +0100 MIPS: MSP71xx: Use __flush_cache_all instead of flush_cache_all. Flushing caches is probably sensible on reset but flush_cache_all has been a no-op for a very long time. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/pmcs-msp71xx/msp_setup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9329c154e4a8a253347829c1d8cc416061cc055a Author: Ralf Baechle <ralf@linux-mips.org> Date: Wed Jan 27 18:07:00 2016 +0100 MIPS: Octeon: Use __flush_cache_all instead of flush_cache_all. flush_cache_all will go away. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/cavium-octeon/smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 81424d0ad0d41f05049aac6d4959d17a5a3c69c8 Author: Alban Bedel <albeu@free.fr> Date: Tue Jan 26 09:39:30 2016 +0100 MIPS: ath79: Use the reset controller to restart OF machines Don't set _machine_restart() on OF machines as the reset driver now provides a system restart handler. Signed-off-by: Alban Bedel <albeu@free.fr> Cc: Felix Fietkau <nbd@openwrt.org> Cc: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12235/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/setup.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit b3f0a250d6eda645cee719cc11ea70e28f62145c Author: Alban Bedel <albeu@free.fr> Date: Tue Jan 26 09:38:29 2016 +0100 MIPS: ath79: Add zboot debug serial support Reuse the early printk code to support the serial in zboot. We copy early_printk.c instead of referencing it because we need to build a different object file for the normal kernel and zboot. Signed-off-by: Alban Bedel <albeu@free.fr> Cc: Andrew Bresticker <abrestic@chromium.org> Cc: Alex Smith <alex.smith@imgtec.com> Cc: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12234/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 +- arch/mips/boot/compressed/Makefile | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) commit ea3a7085bfa85ad52118822df73123b7e7056dab Author: Alban Bedel <albeu@free.fr> Date: Tue Jan 26 08:27:16 2016 +0100 MIPS: ath79: Remove the builtin DTB support Now that appended DTB is usable we can drop the builtin DTB support. Signed-off-by: Alban Bedel <albeu@free.fr> Cc: Felix Fietkau <nbd@openwrt.org> Cc: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12231/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/Kconfig | 12 ------------ arch/mips/ath79/setup.c | 4 ---- arch/mips/boot/dts/qca/Makefile | 3 --- 3 files changed, 19 deletions(-) commit 8f4d4d1bfb47014f324309781917e4fd3eb6a316 Author: Alban Bedel <albeu@free.fr> Date: Tue Jan 26 08:27:15 2016 +0100 MIPS: ath79: Add support for DTB passed using the UHI boot protocol This is needed for bootloader supporting UHI and to support appended DTB. Signed-off-by: Alban Bedel <albeu@free.fr> Cc: Felix Fietkau <nbd@openwrt.org> Cc: Antony Pavlov <antonynpavlov@gmail.com> Cc: Gabor Juhos <juhosg@openwrt.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12230/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/ath79/setup.c | 2 ++ 1 file changed, 2 insertions(+) commit 4afd0565552c87f23834db9121dd9cf6955d0b43 Author: Mateusz Guzik <mguzik@redhat.com> Date: Tue May 10 22:56:43 2016 +0200 x86/arch_prctl/64: Restore accidentally removed put_cpu() in ARCH_SET_GS This fixes an oversight in: 731e33e39a5b95 ("Remove FSBASE/GSBASE < 4G optimization") Signed-off-by: Mateusz Guzik <mguzik@redhat.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1462913803-29634-1-git-send-email-mguzik@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/process_64.c | 1 + 1 file changed, 1 insertion(+) commit a53dd258279c1e8bff205e3273a285bdd4b87406 Author: Andy Lutomirski <luto@kernel.org> Date: Wed May 11 16:57:47 2016 -0700 efifb: Don't show the mapping VA The framebuffer mapping virtual address leaks information about the kernel memory layout. Stop logging it. Cc: Peter Jones <pjones@redhat.com> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: linux-fbdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Andy Lutomirski <luto@kernel.org> Signed-off-by: Peter Jones <pjones@redhat.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/efifb.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 9e9daa0a67d59df432664cdca1cf4659057fd00c Author: Wadim Egorov <w.egorov@phytec.de> Date: Tue May 10 15:18:55 2016 +0200 regulator: rk808: Migrate to regulator core's simplified DT parsing code A common simplified DT parsing code for regulators was introduced in commit a0c7b164ad11 ("regulator: of: Provide simplified DT parsing method") While at it also added RK8XX_DESC and RK8XX_DESC_SWITCH macros for the regulator_desc struct initialization. This just makes the driver more compact. Signed-off-by: Wadim Egorov <w.egorov@phytec.de> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/rk808-regulator.c | 250 ++++++++++++------------------------ 1 file changed, 79 insertions(+), 171 deletions(-) commit 027db2e122db81b055a2b569d72f2f1d29c4d007 Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:14:00 2016 +0200 ASoC: fsl_ssi: Fix channel slipping on capture (or playback) restart in full duplex. Happened when the Playback (or Capture) is running continuously and Capture (or Playback) is restarted (xrun, manual stop/start...) Since the RX (or TX) FIFO are only reset when the whole SSI is disabled, pending samples from previous capture (or playback) session may still be present. They must be erased to not introduce channel slipping. FIFO Clear register fields are documented in IMX51, IMX35 reference manual. They are not documented in IMX50 or IMX6 RM, despite they are working as expected on IMX6SL and IMX6solo. Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit 61fcf10a0ee44763e0347b297a377137f8950772 Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:13:59 2016 +0200 ASoC: fsl_ssi: Fix channel slipping in Playback at startup Previously, SCR.SSIEN and SCR.TE were enabled at once if no capture stream was also running. This may not give a chance for the DMA to write the first sample in TX FIFO before the streaming starts on the PCM bus, inserting void samples first. Those void samples are then responsible for slipping the channels. Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 34 +++++++++++++++++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) commit d9f2a202877c15818d98268f47d6b4bcfcb84437 Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:13:58 2016 +0200 ASoC: fsl_ssi: Fix samples being dropped at Playback startup If the capture is already running while playback is started, it is highly probable (>80% in a 8 channels scenario) that samples are lost between the DMA and TX fifo. The reason is that SIER.TDMAE is set before STCR.TFEN0, leaving a time window where the FIFO doesn't receive the samples written by the DMA. This particular case happened only if capture is already enabled as SCR.SSIEN is already set at the playback startup instant. Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0096b693962d3abde4f41b13cf03c765f33e9d8d Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:13:57 2016 +0200 ASoC: fsl_ssi: Save a dev reference for dev_err() purpose. Most of functions only receive the ssi_private reference and don't have a knowledge of 'dev' pointer, even for debug purpose. Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 2 ++ 1 file changed, 2 insertions(+) commit e09745f2e6a1f692fc63db01850aacf025475aad Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:13:56 2016 +0200 ASoC: fsl_ssi: The IPG/5 limitation concerns the bitclk, not the sysclk. im6sl reference manual 47.7.4: " Bit clock - Used to serially clock the data bits in and out of the SSI port. This clock is either generated internally (from SSI's sys clock) or taken from external clock source (through the Tx/Rx clock ports). [...] Care should be taken to ensure that the bit clock frequency (either internally generated by dividing the SSI's sys clock or sourced from external device through Tx/Rx clock ports) is never greater than 1/5 of the ipg_clk (from CCM) frequency. " Since, in master mode, the sysclk is a multiple of bitclk, we can easily reach a high sysclk value, whereas keeping a reasonable bitclk. ex: 8ch x 16bit x 48kHz = 6144000, requires a 24576000 sysclk (PM=1) yet ipg_clk/5 = 66Mhz/5 = 13.2 Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 48a260eec301fd7a112d1737ca2755d91558a349 Author: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Date: Tue May 3 14:13:55 2016 +0200 ASoC: fsl_ssi: Real hardware channels max number is 32 The max number of slots in TDM mode is 32: - Frame Rate Divider Control is a 5bit value - Time slot mask registers control 32 slots. Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Caleb Crome <caleb@crome.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2213fc350841e99598e52232b56add7b873529a0 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Wed May 11 12:09:53 2016 -0700 ASoC: tlv320aic32x4: Properly implement the positive and negative pins into the mixers The TLV320AIC32x4 has a very flexible mixer on the inputs to the ADCs. Each mixer has an available set of available pins that can be connected to the ADC positive and negative pins via three different resistor values. This allows for configuration of differential inputs as well as doing level manipulation between sources going into the mixers. The current code only provides positive pins and I implemented the resistors in an earlier patch. It turns out that it appears to more accurately model what's happening to implement each of the pins as a MUX rather than on/off switches and a mixer. This way each pin can be set to its desired resistor value. Since there are no switches, the mixer is no longer necessary in the DAPM path. I set the DAPM paths such that the "off" position of any of the MUXes turns the path off. This should allow for any input confiuration available on the codec. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic32x4.c | 210 ++++++++++++++++++++++++++++++--------- 1 file changed, 161 insertions(+), 49 deletions(-) commit 21825ff11d683fa2fc0f5668cc2ec0a0652ee64b Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri May 13 14:12:53 2016 +0530 spi: pic32-sqi: Fix linker error, undefined reference to `bad_dma_ops'. Even if DMA support is disabled code using DMA mapping APIs compiles fine, but fails in linking. ------- drivers/built-in.o: In function `ring_desc_ring_free': spi-pic32-sqi.c:(.text+0x2cfbe0): undefined reference to `bad_dma_ops' spi-pic32-sqi.c:(.text+0x2cfbe4): undefined reference to `bad_dma_ops' drivers/built-in.o: In function `pic32_sqi_probe': spi-pic32-sqi.c:(.text+0x2cfe48): undefined reference to `bad_dma_ops' spi-pic32-sqi.c:(.text+0x2cfeb0): undefined reference to `bad_dma_ops' spi-pic32-sqi.c:(.text+0x2cff38): undefined reference to `bad_dma_ops' -------- Correct dependency by adding 'depends on HAS_DMA' in Kconfig. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 97d3ddd71fbf663a5da52897757333341a8b254f Author: Florian Meier <florian.meier@koalo.de> Date: Fri May 13 09:14:12 2016 +0000 ASoC: pcm5102a: Add support for PCM5102A codec Some definitions to support the PCM5102A codec by Texas Instruments. Signed-off-by: Florian Meier <florian.meier@koalo.de> Changes to original patch by Florian Meier: * rebased (Makefile and Kconfig * fixed checkpath errors (spaces, newlines) * added dt-binding documentation Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/pcm5102a.txt | 13 ++++ sound/soc/codecs/Kconfig | 4 ++ sound/soc/codecs/Makefile | 2 + sound/soc/codecs/pcm5102a.c | 69 ++++++++++++++++++++++ 4 files changed, 88 insertions(+) commit b2047e996cd88d36eb0f4e84fe6aedab831a4b31 Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 12 08:58:55 2016 +0530 ASoC: hdac_hdmi: add link management Manage the hda idisp link using shiny new link APIs. We need to keep link On while we probe and also hold the reference in runtime resume and drop in suspend Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) commit cce6c149eba3aabf678ffea91ac1e4103b9c185e Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 12 08:58:54 2016 +0530 ASoC: Intel: Skylake: add link management Use shiny new link APIs to manage the links. Also remove old link configuration logic from driver. We need to keep link and cmd dma to off during active suspend to allow system to enter low power state and turn it on if the link and cmd dma was on before active suspend in active resume. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-pcm.c | 1 - sound/soc/intel/skylake/skl.c | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) commit 4446085d21e75dd6c0c45577f12db0bd7c7bf35f Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 12 08:58:53 2016 +0530 ALSA: hdac: add link pm and ref counting The HDA links can be switched off when not is use, similarly command DMA can be stopped as well. This calls for a reference counting mechanism on the link by it's users to manage the link power. The DMA can be turned off when all links are off For this we add two APIs snd_hdac_ext_bus_link_get snd_hdac_ext_bus_link_put They help users to turn up/down link and manage the DMA as well Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Acked-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/hdaudio_ext.h | 13 ++++++++ sound/hda/ext/hdac_ext_bus.c | 3 ++ sound/hda/ext/hdac_ext_controller.c | 66 +++++++++++++++++++++++++++++++++++++ 3 files changed, 82 insertions(+) commit 40027b2fffc2dcef20080847b0913d210ef3ced0 Author: Peter Griffin <peter.griffin@linaro.org> Date: Wed May 11 17:21:59 2016 +0100 i2c: st: Implement bus clear >From I2C specifications: http://www.nxp.com/documents/user_manual/UM10204.pdf Chapter 3.1.16, when the i2c device held the SDA line low, the master should send 9 clocks pulses to try to recover. Signed-off-by: Frederic Pillon <frederic.pillon@st.com> Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-st.c | 45 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 44 insertions(+), 1 deletion(-) commit 3a9ddaf4dca87f86f70b88d7710da20abfc9aca1 Author: Wolfram Sang <wsa@the-dreams.de> Date: Thu May 12 11:25:19 2016 +0200 i2c: only check scl functions when using generic recovery A custom recovery function doesn't need these pointers to be populated because it may work differently internally. Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Tested-by: Peter Griffin <peter.griffin@linaro.org> drivers/i2c/i2c-core.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit d7e1633abf9b1cc198bb673a59a01a3767f16b94 Merge: 14717e2 b1a4286 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Fri May 13 11:48:22 2016 +0200 Merge branch 'kvm-ppc-next' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc into HEAD commit d4ab78d7076d2a58a2d690b2f4a03a24d978ac1c Merge: 2a2cd52 267c858 6e4f287 Author: Mark Brown <broonie@kernel.org> Date: Fri May 13 10:36:14 2016 +0100 Merge remote-tracking branches 'regmap/topic/doc' and 'regmap/topic/flat' into regmap-next commit 256b1cfb9a346bb4808cd27b7b8f9b120f96491e Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Wed May 11 13:21:29 2016 -0700 crypto: qat - change the adf_ctl_stop_devices to void Change the adf_ctl_stop_devices to a void function. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_ctl_drv.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit ba16db36b5dd6a0f053ba7d50745f29678b4ca8f Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Fri May 13 12:33:31 2016 +0530 dmaengine: vdma: Add clock support Added basic clock support for axi dma's. The clocks are requested at probe and released at remove. Reviewed-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 226 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 224 insertions(+), 2 deletions(-) commit 4ac4e120677481277e092c5f44cb781266e7853e Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Fri May 13 12:33:30 2016 +0530 Documentation: DT: vdma: Add clock support for dmas This patch updates the binding doc with clock description for AXI DMA's. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com> Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> .../devicetree/bindings/dma/xilinx/xilinx_vdma.txt | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit fb2366675ec2221241bea83dc4ec57ed33ce3dcd Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Fri May 13 12:33:29 2016 +0530 dmaengine: vdma: Add config structure to differentiate dmas This patch adds config structure in the driver to differentiate AXI DMA's and to add more features(clock support etc..) to these DMA's. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 83 ++++++++++++++++++++++++---------------- 1 file changed, 51 insertions(+), 32 deletions(-) commit 86e486a098b6251e3931ca04b7078aa037bfe5ad Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu May 12 18:02:24 2016 +0100 MAINTAINERS: Update Tegra DMA maintainers Update the Tegra DMA driver maintainer field to include the newly added Tegra210 ADMA and add Jon Hunter as a co-maintainer for Tegra DMA. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> MAINTAINERS | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit f46b195799b5cb05338e7c44cb3617eacb56d755 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu May 12 18:02:23 2016 +0100 dmaengine: tegra-adma: Add support for Tegra210 ADMA Add support for the Tegra210 Audio DMA controller that is used for transferring data between system memory and the Audio sub-system. The driver only supports cyclic transfers because this is being solely used for audio. This driver is based upon the work by Dara Ramesh <dramesh@nvidia.com>. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/Kconfig | 14 + drivers/dma/Makefile | 1 + drivers/dma/tegra210-adma.c | 840 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 855 insertions(+) commit f4cb295ba6b3f95ea988dcf8ed8c39d249bfde21 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu May 12 18:02:22 2016 +0100 Documentation: DT: Add binding documentation for NVIDIA ADMA Add device-tree binding documentation for the Tegra210 Audio DMA controller. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> .../bindings/dma/nvidia,tegra210-adma.txt | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) commit ed7cbbce544856b20e5811de373cf92e92499771 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu May 12 16:23:44 2016 -0700 udp: Resolve NULL pointer dereference over flow-based vxlan device While testing an OpenStack configuration using VXLANs I saw the following call trace: RIP: 0010:[<ffffffff815fad49>] udp4_lib_lookup_skb+0x49/0x80 RSP: 0018:ffff88103867bc50 EFLAGS: 00010286 RAX: ffff88103269bf00 RBX: ffff88103269bf00 RCX: 00000000ffffffff RDX: 0000000000004300 RSI: 0000000000000000 RDI: ffff880f2932e780 RBP: ffff88103867bc60 R08: 0000000000000000 R09: 000000009001a8c0 R10: 0000000000004400 R11: ffffffff81333a58 R12: ffff880f2932e794 R13: 0000000000000014 R14: 0000000000000014 R15: ffffe8efbfd89ca0 FS: 0000000000000000(0000) GS:ffff88103fd80000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000488 CR3: 0000000001c06000 CR4: 00000000001426e0 Stack: ffffffff81576515 ffffffff815733c0 ffff88103867bc98 ffffffff815fcc17 ffff88103269bf00 ffffe8efbfd89ca0 0000000000000014 0000000000000080 ffffe8efbfd89ca0 ffff88103867bcc8 ffffffff815fcf8b ffff880f2932e794 Call Trace: [<ffffffff81576515>] ? skb_checksum+0x35/0x50 [<ffffffff815733c0>] ? skb_push+0x40/0x40 [<ffffffff815fcc17>] udp_gro_receive+0x57/0x130 [<ffffffff815fcf8b>] udp4_gro_receive+0x10b/0x2c0 [<ffffffff81605863>] inet_gro_receive+0x1d3/0x270 [<ffffffff81589e59>] dev_gro_receive+0x269/0x3b0 [<ffffffff8158a1b8>] napi_gro_receive+0x38/0x120 [<ffffffffa0871297>] gro_cell_poll+0x57/0x80 [vxlan] [<ffffffff815899d0>] net_rx_action+0x160/0x380 [<ffffffff816965c7>] __do_softirq+0xd7/0x2c5 [<ffffffff8107d969>] run_ksoftirqd+0x29/0x50 [<ffffffff8109a50f>] smpboot_thread_fn+0x10f/0x160 [<ffffffff8109a400>] ? sort_range+0x30/0x30 [<ffffffff81096da8>] kthread+0xd8/0xf0 [<ffffffff81693c82>] ret_from_fork+0x22/0x40 [<ffffffff81096cd0>] ? kthread_park+0x60/0x60 The following trace is seen when receiving a DHCP request over a flow-based VXLAN tunnel. I believe this is caused by the metadata dst having a NULL dev value and as a result dev_net(dev) is causing a NULL pointer dereference. To resolve this I am replacing the check for skb_dst(skb)->dev with just skb->dev. This makes sense as the callers of this function are usually in the receive path and as such skb->dev should always be populated. In addition other functions in the area where these are called are already using dev_net(skb->dev) to determine the namespace the UDP packet belongs in. Fixes: 63058308cd55 ("udp: Add udp6_lib_lookup_skb and udp4_lib_lookup_skb") Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/udp.c | 10 ++-------- net/ipv6/udp.c | 8 +++----- 2 files changed, 5 insertions(+), 13 deletions(-) commit b4411457d5c9062f07f0762f1ddb513d90dd1379 Author: Eric Dumazet <edumazet@google.com> Date: Thu May 12 21:41:39 2016 -0700 sunrpc: set SOCK_FASYNC sunrpc is using SOCKWQ_ASYNC_NOSPACE without setting SOCK_FASYNC, so the recent optimizations done in sk_set_bit() and sk_clear_bit() broke it. There is still the risk that a subsequent sock_fasync() call would clear SOCK_FASYNC, but sunrpc does not use this yet. Fixes: 9317bb69824e ("net: SOCKWQ_ASYNC_NOSPACE optimizations") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Jiri Pirko <jiri@resnulli.us> Reported-by: Huang, Ying <ying.huang@intel.com> Tested-by: Jiri Pirko <jiri@resnulli.us> Tested-by: Huang, Ying <ying.huang@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sunrpc/xprtsock.c | 3 +++ 1 file changed, 3 insertions(+) commit 12735f881952c32b31bc4e433768f18489f79ec9 Author: Jan Kara <jack@suse.cz> Date: Fri May 13 00:51:15 2016 -0400 ext4: pre-zero allocated blocks for DAX IO Currently ext4 treats DAX IO the same way as direct IO. I.e., it allocates unwritten extents before IO is done and converts unwritten extents afterwards. However this way DAX IO can race with page fault to the same area: ext4_ext_direct_IO() dax_fault() dax_io() get_block() - allocates unwritten extent copy_from_iter_pmem() get_block() - converts unwritten block to written and zeroes it out ext4_convert_unwritten_extents() So data written with DAX IO gets lost. Similarly dax_new_buf() called from dax_io() can overwrite data that has been already written to the block via mmap. Fix the problem by using pre-zeroed blocks for DAX IO the same way as we use them for DAX mmap. The downside of this solution is that every allocating write writes each block twice (once zeros, once data). Fixing the race with locking is possible as well however we would need to lock-out faults for the whole range written to by DAX IO. And that is not easy to do without locking-out faults for the whole file which seems too aggressive. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ext4.h | 11 +++++++++-- fs/ext4/file.c | 4 ++-- fs/ext4/inode.c | 43 +++++++++++++++++++++++++++++++++---------- 3 files changed, 44 insertions(+), 14 deletions(-) commit 914f82a32d026884743fb3de9f6f0a5908a9d5dd Author: Jan Kara <jack@suse.cz> Date: Fri May 13 00:44:16 2016 -0400 ext4: refactor direct IO code Currently ext4 direct IO handling is split between ext4_ext_direct_IO() and ext4_ind_direct_IO(). However the extent based function calls into the indirect based one for some cases and for example it is not able to handle file extending. Previously it was not also properly handling retries in case of ENOSPC errors. With DAX things would get even more contrieved so just refactor the direct IO code and instead of indirect / extent split do the split to read vs writes. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ext4.h | 2 - fs/ext4/indirect.c | 127 --------------------------------------------------- fs/ext4/inode.c | 131 ++++++++++++++++++++++++++++++++++++++++++++++------- 3 files changed, 114 insertions(+), 146 deletions(-) commit dbc427ce4028580f1244b5b57ca1cbea31aad1e7 Author: Jan Kara <jack@suse.cz> Date: Fri May 13 00:42:40 2016 -0400 ext4: fix race in transient ENOSPC detection When there are blocks to free in the running transaction, block allocator can return ENOSPC although the filesystem has some blocks to free. We use ext4_should_retry_alloc() to force commit of the current transaction and return whether anything was committed so that it makes sense to retry the allocation. However the transaction may get committed after block allocation fails but before we call ext4_should_retry_alloc(). So ext4_should_retry_alloc() returns false because there is nothing to commit and we wrongly return ENOSPC. Fix the race by unconditionally returning 1 from ext4_should_retry_alloc() when we tried to commit a transaction. This should not add any unnecessary retries since we had a transaction running a while ago when trying to allocate blocks and we want to retry the allocation once that transaction has committed anyway. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/balloc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7cb476f834d0dc2092e04eeafe9cbe509f6380eb Author: Jan Kara <jack@suse.cz> Date: Fri May 13 00:38:16 2016 -0400 ext4: handle transient ENOSPC properly for DAX ext4_dax_get_blocks() was accidentally omitted fixing get blocks handlers to properly handle transient ENOSPC errors. Fix it now to use ext4_get_blocks_trans() helper which takes care of these errors. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/inode.c | 75 +++++++++++++++------------------------------------------ 1 file changed, 20 insertions(+), 55 deletions(-) commit aef39ab1534d1a07061e0ee7e428499e127232eb Author: Jan Kara <jack@suse.cz> Date: Fri May 13 00:38:15 2016 -0400 dax: call get_blocks() with create == 1 for write faults to unwritten extents Currently, __dax_fault() does not call get_blocks() callback with create argument set, when we got back unwritten extent from the initial get_blocks() call during a write fault. This is because originally filesystems were supposed to convert unwritten extents to written ones using complete_unwritten() callback. Later this was abandoned in favor of using pre-zeroed blocks however the condition whether get_blocks() needs to be called with create == 1 remained. Fix the condition so that filesystems are not forced to zero-out and convert unwritten extents when get_blocks() is called with create == 0 (which introduces unnecessary overhead for read faults and can be problematic as the filesystem may possibly be read-only). Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/dax.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5035cd5b666b7378e32e1985225aae5746a59ac9 Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue May 3 14:53:40 2016 +0530 ARC: pae: STRICT_MM_TYPECHECKS was broken Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/page.h | 4 ++++ 1 file changed, 4 insertions(+) commit c8b6056a504fa384f36e7577fc5a1c1684fcf18a Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Fri Apr 22 14:43:49 2016 +0200 jfs: Switch to generic xattr handlers This is mostly the same as on other filesystems except for attribute names with an "os2." prefix: for those, the prefix is not stored on disk, and on-attribute names without a prefix have "os2." added. As on several other filesystems, the underlying function for setting/removing xattrs (__jfs_setxattr) removes attributes when the value is NULL, so the set xattr handlers will work as expected. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/jfs/file.c | 6 +- fs/jfs/jfs_xattr.h | 6 +- fs/jfs/namei.c | 6 +- fs/jfs/symlink.c | 12 ++-- fs/jfs/xattr.c | 170 ++++++++++++++++++++++------------------------------- 5 files changed, 84 insertions(+), 116 deletions(-) commit 6c8f980c75185f8ba897814363d21882f7453f53 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Fri Apr 22 14:43:48 2016 +0200 jfs: Clean up xattr name mapping Instead of stripping "os2." prefixes in __jfs_setxattr, make callers strip them, as __jfs_getxattr already does. With that change, use the same name mapping function in jfs_{get,set,remove}xattr. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/jfs/xattr.c | 80 ++++++++++++++++++---------------------------------------- 1 file changed, 25 insertions(+), 55 deletions(-) commit 1a39ba99b5d533647c5dac45cd6a3e0baa7cb66a Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri May 13 03:59:17 2016 +0200 gfs2: Switch to generic xattr handlers Switch to the generic xattr handlers and take the necessary glocks at the layer below. The following are the new xattr "entry points"; they are called with the glock held already in the following cases: gfs2_xattr_get: From SELinux, during lookups. gfs2_xattr_set: The glock is never held. gfs2_get_acl: From gfs2_create_inode -> posix_acl_create and gfs2_setattr -> posix_acl_chmod. gfs2_set_acl: From gfs2_setattr -> posix_acl_chmod. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/gfs2/acl.c | 58 ++++++++++++++++++++++++++++++++-------- fs/gfs2/acl.h | 1 + fs/gfs2/inode.c | 82 ++++++++------------------------------------------------- fs/gfs2/xattr.c | 46 +++++++++++++++++++++++++++----- 4 files changed, 99 insertions(+), 88 deletions(-) commit cf15fabd6f66e966ae5744f088538f7936df9a4d Merge: 7d02067 227e4f4 Author: Dave Airlie <airlied@redhat.com> Date: Fri May 13 11:48:01 2016 +1000 Merge tag 'drm/panel/for-4.7-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next drm/panel: Changes for v4.7-rc1 This contains support for a bunch of new panels in the simple panel driver along with some cleanup and support for a new Analogix HDMI to DP bridge. * tag 'drm/panel/for-4.7-rc1' of git://anongit.freedesktop.org/tegra/linux: drm/panel: simple: Add support for TPK U.S.A. LLC Fusion 7" and 10.1" panels drm/bridge: Add Analogix anx78xx support devicetree: Add ANX7814 SlimPort transmitter binding of: Add vendor prefix for Analogix Semiconductor drm/dp: Add define to set 0.5% down-spread in MAX_DOWNSPREAD register drm/panel: simple: Add support for Innolux AT070TN92 drm/panel: simple: Remove useless drm_mode_set_name() drm/panel: simple: Set appropriate mode type drm/panel: simple: Add timings for the Olimex LCD-OLinuXino-4.3TS drm/panel: simple: Add the 7" DPI panel from Adafruit of: Add vendor prefix for On Tat Industrial Company. commit 5f9a8a51d8b95505d8de8b7191ae2ed8c504d4af Author: Filipe Manana <fdmanana@suse.com> Date: Thu May 12 13:53:36 2016 +0100 Btrfs: add semaphore to synchronize direct IO writes with fsync Due to the optimization of lockless direct IO writes (the inode's i_mutex is not held) introduced in commit 38851cc19adb ("Btrfs: implement unlocked dio write"), we started having races between such writes with concurrent fsync operations that use the fast fsync path. These races were addressed in the patches titled "Btrfs: fix race between fsync and lockless direct IO writes" and "Btrfs: fix race between fsync and direct IO writes for prealloc extents". The races happened because the direct IO path, like every other write path, does create extent maps followed by the corresponding ordered extents while the fast fsync path collected first ordered extents and then it collected extent maps. This made it possible to log file extent items (based on the collected extent maps) without waiting for the corresponding ordered extents to complete (get their IO done). The two fixes mentioned before added a solution that consists of making the direct IO path create first the ordered extents and then the extent maps, while the fsync path attempts to collect any new ordered extents once it collects the extent maps. This was simple and did not require adding any synchonization primitive to any data structure (struct btrfs_inode for example) but it makes things more fragile for future development endeavours and adds an exceptional approach compared to the other write paths. This change adds a read-write semaphore to the btrfs inode structure and makes the direct IO path create the extent maps and the ordered extents while holding read access on that semaphore, while the fast fsync path collects extent maps and ordered extents while holding write access on that semaphore. The logic for direct IO write path is encapsulated in a new helper function that is used both for cow and nocow direct IO writes. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/btrfs_inode.h | 10 ++++ fs/btrfs/inode.c | 134 +++++++++++++++++++------------------------------ fs/btrfs/tree-log.c | 51 ++++++------------- 3 files changed, 77 insertions(+), 118 deletions(-) commit f78c436c3931e7df713688028f2b4faf72bf9f2a Author: Filipe Manana <fdmanana@suse.com> Date: Mon May 9 13:15:41 2016 +0100 Btrfs: fix race between block group relocation and nocow writes Relocation of a block group waits for all existing tasks flushing dellaloc, starting direct IO writes and any ordered extents before starting the relocation process. However for direct IO writes that end up doing nocow (inode either has the flag nodatacow set or the write is against a prealloc extent) we have a short time window that allows for a race that makes relocation proceed without waiting for the direct IO write to complete first, resulting in data loss after the relocation finishes. This is illustrated by the following diagram: CPU 1 CPU 2 btrfs_relocate_block_group(bg X) direct IO write starts against an extent in block group X using nocow mode (inode has the nodatacow flag or the write is for a prealloc extent) btrfs_direct_IO() btrfs_get_blocks_direct() --> can_nocow_extent() returns 1 btrfs_inc_block_group_ro(bg X) --> turns block group into RO mode btrfs_wait_ordered_roots() --> returns and does not know about the DIO write happening at CPU 2 (the task there has not created yet an ordered extent) relocate_block_group(bg X) --> rc->stage == MOVE_DATA_EXTENTS find_next_extent() --> returns extent that the DIO write is going to write to relocate_data_extent() relocate_file_extent_cluster() --> reads the extent from disk into pages belonging to the relocation inode and dirties them --> creates DIO ordered extent btrfs_submit_direct() --> submits bio against a location on disk obtained from an extent map before the relocation started btrfs_wait_ordered_range() --> writes all the pages read before to disk (belonging to the relocation inode) relocation finishes bio completes and wrote new data to the old location of the block group So fix this by tracking the number of nocow writers for a block group and make sure relocation waits for that number to go down to 0 before starting to move the extents. The same race can also happen with buffered writes in nocow mode since the patch I recently made titled "Btrfs: don't do unnecessary delalloc flushes when relocating", because we are no longer flushing all delalloc which served as a synchonization mechanism (due to page locking) and ensured the ordered extents for nocow buffered writes were created before we called btrfs_wait_ordered_roots(). The race with direct IO writes in nocow mode existed before that patch (no pages are locked or used during direct IO) and that fixed only races with direct IO writes that do cow. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/ctree.h | 13 +++++++++++++ fs/btrfs/extent-tree.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++ fs/btrfs/inode.c | 15 +++++++++++++- fs/btrfs/relocation.c | 1 + 4 files changed, 81 insertions(+), 1 deletion(-) commit 0b901916a00bc7b14ee83cc8e41c3b0d561a8f22 Author: Filipe Manana <fdmanana@suse.com> Date: Mon May 9 13:15:27 2016 +0100 Btrfs: fix race between fsync and direct IO writes for prealloc extents When we do a direct IO write against a preallocated extent (fallocate) that does not go beyond the i_size of the inode, we do the write operation without holding the inode's i_mutex (an optimization that landed in commit 38851cc19adb ("Btrfs: implement unlocked dio write")). This allows for a very tiny time window where a race can happen with a concurrent fsync using the fast code path, as the direct IO write path creates first a new extent map (no longer flagged as a prealloc extent) and then it creates the ordered extent, while the fast fsync path first collects ordered extents and then it collects extent maps. This allows for the possibility of the fast fsync path to collect the new extent map without collecting the new ordered extent, and therefore logging an extent item based on the extent map without waiting for the ordered extent to be created and complete. This can result in a situation where after a log replay we end up with an extent not marked anymore as prealloc but it was only partially written (or not written at all), exposing random, stale or garbage data corresponding to the unwritten pages and without any checksums in the csum tree covering the extent's range. This is an extension of what was done in commit de0ee0edb21f ("Btrfs: fix race between fsync and lockless direct IO writes"). So fix this by creating first the ordered extent and then the extent map, so that this way if the fast fsync patch collects the new extent map it also collects the corresponding ordered extent. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> fs/btrfs/inode.c | 43 +++++++++++++++++++++++++++++++++++++------ 1 file changed, 37 insertions(+), 6 deletions(-) commit 5062af35c3c6e49110ab1ec99295339259298a3d Author: Filipe Manana <fdmanana@suse.com> Date: Thu May 5 10:26:26 2016 +0100 Btrfs: fix number of transaction units for renames with whiteout When we do a rename with the whiteout flag, we need to create the whiteout inode, which in the worst case requires 5 transaction units (1 inode item, 1 inode ref, 2 dir items and 1 xattr if selinux is enabled). So bump the number of transaction units from 11 to 16 if the whiteout flag is set. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 376e5a57bf7f1466031a957d04bf8b8f6801ee6d Author: Filipe Manana <fdmanana@suse.com> Date: Thu May 5 02:08:56 2016 +0100 Btrfs: pin logs earlier when doing a rename exchange operation The btrfs_rename_exchange() started as a copy-paste from btrfs_rename(), which had a race fixed by my previous patch titled "Btrfs: pin log earlier when renaming", and so it suffers from the same problem. We pin the logs of the affected roots after we insert the new inode references, leaving a time window where concurrent tasks logging the inodes can end up logging both the new and old references, resulting in log trees that when replayed can turn the metadata into inconsistent states. This behaviour was added to btrfs_rename() in 2009 without any explanation about why not pinning the logs earlier, just leaving a comment about the posibility for the race. As of today it's perfectly safe and sane to pin the logs before we start doing any of the steps involved in the rename operation. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 86e8aa0e772caba5f0e0471d5f836b2b997dcb3e Author: Filipe Manana <fdmanana@suse.com> Date: Thu May 5 02:02:27 2016 +0100 Btrfs: unpin logs if rename exchange operation fails If rename exchange operations fail at some point after we pinned any of the logs, we end up aborting the current transaction but never unpin the logs, which leaves concurrent tasks that are trying to sync the logs (as part of an fsync request from user space) blocked forever and preventing the filesystem from being unmountable. Fix this by safely unpinning the log. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 38 ++++++++++++++++++++++++++++++++++++-- 1 file changed, 36 insertions(+), 2 deletions(-) commit c990161888f387db136856337c237aa8d5003292 Author: Filipe Manana <fdmanana@suse.com> Date: Thu May 5 01:41:57 2016 +0100 Btrfs: fix inode leak on failure to setup whiteout inode in rename If we failed to fully setup the whiteout inode during a rename operation with the whiteout flag, we ended up leaking the inode, not decrementing its link count nor removing all its items from the fs/subvol tree. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit cdd1fedf8261cd7a73c0596298902ff4f0f04492 Author: Dan Fuhry <dfuhry@datto.com> Date: Thu Mar 17 15:23:38 2016 +0100 btrfs: add support for RENAME_EXCHANGE and RENAME_WHITEOUT Two new flags, RENAME_EXCHANGE and RENAME_WHITEOUT, provide for new behavior in the renameat2() syscall. This behavior is primarily used by overlayfs. This patch adds support for these flags to btrfs, enabling it to be used as a fully functional upper layer for overlayfs. RENAME_EXCHANGE support was written by Davide Italiano originally submitted on 2 April 2015. Signed-off-by: Davide Italiano <dccitaliano@gmail.com> Signed-off-by: Dan Fuhry <dfuhry@datto.com> [ remove unlikely ] Signed-off-by: David Sterba <dsterba@suse.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 264 +++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 257 insertions(+), 7 deletions(-) commit c4aba9545430ed0f842d0833072f990a42da90f0 Author: Filipe Manana <fdmanana@suse.com> Date: Fri Apr 29 13:14:42 2016 +0100 Btrfs: pin log earlier when renaming We were pinning the log right after the first step in the rename operation (inserting inode ref for the new name in the destination directory) instead of doing it before. This behaviour was introduced in 2009 for some reason that was not mentioned neither on the changelog nor any comment, with the drawback of a small time window where concurrent log writers can end up logging the new inode reference for the inode we are renaming while the rename operation is in progress (so that we can end up with a log containing both the new and old references). As of today there's no reason to not pin the log before that first step anymore, so just fix this. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 3dc9e8f76720fbbd9c56a11775932733fe13d214 Author: Filipe Manana <fdmanana@suse.com> Date: Fri Apr 29 11:34:22 2016 +0100 Btrfs: unpin log if rename operation fails If rename operations fail at some point after we pinned the log, we end up aborting the current transaction but never unpin the log, which leaves concurrent tasks that are trying to sync the log (as part of an fsync request from user space) blocked forever and preventing the filesystem from being unmountable. Fix this by safely unpinning the log. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/inode.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) commit 9cfa3e34e20e6798a671236000d9e97c8aa5d318 Author: Filipe Manana <fdmanana@suse.com> Date: Tue Apr 26 15:39:32 2016 +0100 Btrfs: don't do unnecessary delalloc flushes when relocating Before we start the actual relocation process of a block group, we do calls to flush delalloc of all inodes and then wait for ordered extents to complete. However we do these flush calls just to make sure we don't race with concurrent tasks that have actually already started to run delalloc and have allocated an extent from the block group we want to relocate, right before we set it to readonly mode, but have not yet created the respective ordered extents. The flush calls make us wait for such concurrent tasks because they end up calling filemap_fdatawrite_range() (through btrfs_start_delalloc_roots() -> __start_delalloc_inodes() -> btrfs_alloc_delalloc_work() -> btrfs_run_delalloc_work()) which ends up serializing us with those tasks due to attempts to lock the same pages (and the delalloc flush procedure calls the allocator and creates the ordered extents before unlocking the pages). These flushing calls not only make us waste time (cpu, IO) but also reduce the chances of writing larger extents (applications might be writing to contiguous ranges and we flush before they finish dirtying the whole ranges). So make sure we don't flush delalloc and just wait for concurrent tasks that have already started flushing delalloc and have allocated an extent from the block group we are about to relocate. This change also ends up fixing a race with direct IO writes that makes relocation not wait for direct IO ordered extents. This race is illustrated by the following diagram: CPU 1 CPU 2 btrfs_relocate_block_group(bg X) starts direct IO write, target inode currently has no ordered extents ongoing nor dirty pages (delalloc regions), therefore the root for our inode is not in the list fs_info->ordered_roots btrfs_direct_IO() __blockdev_direct_IO() btrfs_get_blocks_direct() btrfs_lock_extent_direct() locks range in the io tree btrfs_new_extent_direct() btrfs_reserve_extent() --> extent allocated from bg X btrfs_inc_block_group_ro(bg X) btrfs_start_delalloc_roots() __start_delalloc_inodes() --> does nothing, no dealloc ranges in the inode's io tree so the inode's root is not in the list fs_info->delalloc_roots btrfs_wait_ordered_roots() --> does not find the inode's root in the list fs_info->ordered_roots --> ends up not waiting for the direct IO write started by the task at CPU 2 relocate_block_group(rc->stage == MOVE_DATA_EXTENTS) prepare_to_relocate() btrfs_commit_transaction() iterates the extent tree, using its commit root and moves extents into new locations btrfs_add_ordered_extent_dio() --> now a ordered extent is created and added to the list root->ordered_extents and the root added to the list fs_info->ordered_roots --> this is too late and the task at CPU 1 already started the relocation btrfs_commit_transaction() btrfs_finish_ordered_io() btrfs_alloc_reserved_file_extent() --> adds delayed data reference for the extent allocated from bg X relocate_block_group(rc->stage == UPDATE_DATA_PTRS) prepare_to_relocate() btrfs_commit_transaction() --> delayed refs are run, so an extent item for the allocated extent from bg X is added to extent tree --> commit roots are switched, so the next scan in the extent tree will see the extent item sees the extent in the extent tree When this happens the relocation produces the following warning when it finishes: [ 7260.832836] ------------[ cut here ]------------ [ 7260.834653] WARNING: CPU: 5 PID: 6765 at fs/btrfs/relocation.c:4318 btrfs_relocate_block_group+0x245/0x2a1 [btrfs]() [ 7260.838268] Modules linked in: btrfs crc32c_generic xor ppdev raid6_pq psmouse sg acpi_cpufreq evdev i2c_piix4 tpm_tis serio_raw tpm i2c_core pcspkr parport_pc [ 7260.850935] CPU: 5 PID: 6765 Comm: btrfs Not tainted 4.5.0-rc6-btrfs-next-28+ #1 [ 7260.852998] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS by qemu-project.org 04/01/2014 [ 7260.852998] 0000000000000000 ffff88020bf57bc0 ffffffff812648b3 0000000000000000 [ 7260.852998] 0000000000000009 ffff88020bf57bf8 ffffffff81051608 ffffffffa03c1b2d [ 7260.852998] ffff8800b2bbb800 0000000000000000 ffff8800b17bcc58 ffff8800399dd000 [ 7260.852998] Call Trace: [ 7260.852998] [<ffffffff812648b3>] dump_stack+0x67/0x90 [ 7260.852998] [<ffffffff81051608>] warn_slowpath_common+0x99/0xb2 [ 7260.852998] [<ffffffffa03c1b2d>] ? btrfs_relocate_block_group+0x245/0x2a1 [btrfs] [ 7260.852998] [<ffffffff810516d4>] warn_slowpath_null+0x1a/0x1c [ 7260.852998] [<ffffffffa03c1b2d>] btrfs_relocate_block_group+0x245/0x2a1 [btrfs] [ 7260.852998] [<ffffffffa039d9de>] btrfs_relocate_chunk.isra.29+0x66/0xdb [btrfs] [ 7260.852998] [<ffffffffa039f314>] btrfs_balance+0xde1/0xe4e [btrfs] [ 7260.852998] [<ffffffff8127d671>] ? debug_smp_processor_id+0x17/0x19 [ 7260.852998] [<ffffffffa03a9583>] btrfs_ioctl_balance+0x255/0x2d3 [btrfs] [ 7260.852998] [<ffffffffa03ac96a>] btrfs_ioctl+0x11e0/0x1dff [btrfs] [ 7260.852998] [<ffffffff811451df>] ? handle_mm_fault+0x443/0xd63 [ 7260.852998] [<ffffffff81491817>] ? _raw_spin_unlock+0x31/0x44 [ 7260.852998] [<ffffffff8108b36a>] ? arch_local_irq_save+0x9/0xc [ 7260.852998] [<ffffffff811876ab>] vfs_ioctl+0x18/0x34 [ 7260.852998] [<ffffffff81187cb2>] do_vfs_ioctl+0x550/0x5be [ 7260.852998] [<ffffffff81190c30>] ? __fget_light+0x4d/0x71 [ 7260.852998] [<ffffffff81187d77>] SyS_ioctl+0x57/0x79 [ 7260.852998] [<ffffffff81492017>] entry_SYSCALL_64_fastpath+0x12/0x6b [ 7260.893268] ---[ end trace eb7803b24ebab8ad ]--- This is because at the end of the first stage, in relocate_block_group(), we commit the current transaction, which makes delayed refs run, the commit roots are switched and so the second stage will find the extent item that the ordered extent added to the delayed refs. But this extent was not moved (ordered extent completed after first stage finished), so at the end of the relocation our block group item still has a positive used bytes counter, triggering a warning at the end of btrfs_relocate_block_group(). Later on when trying to read the extent contents from disk we hit a BUG_ON() due to the inability to map a block with a logical address that belongs to the block group we relocated and is no longer valid, resulting in the following trace: [ 7344.885290] BTRFS critical (device sdi): unable to find logical 12845056 len 4096 [ 7344.887518] ------------[ cut here ]------------ [ 7344.888431] kernel BUG at fs/btrfs/inode.c:1833! [ 7344.888431] invalid opcode: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC [ 7344.888431] Modules linked in: btrfs crc32c_generic xor ppdev raid6_pq psmouse sg acpi_cpufreq evdev i2c_piix4 tpm_tis serio_raw tpm i2c_core pcspkr parport_pc [ 7344.888431] CPU: 0 PID: 6831 Comm: od Tainted: G W 4.5.0-rc6-btrfs-next-28+ #1 [ 7344.888431] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS by qemu-project.org 04/01/2014 [ 7344.888431] task: ffff880215818600 ti: ffff880204684000 task.ti: ffff880204684000 [ 7344.888431] RIP: 0010:[<ffffffffa037c88c>] [<ffffffffa037c88c>] btrfs_merge_bio_hook+0x54/0x6b [btrfs] [ 7344.888431] RSP: 0018:ffff8802046878f0 EFLAGS: 00010282 [ 7344.888431] RAX: 00000000ffffffea RBX: 0000000000001000 RCX: 0000000000000001 [ 7344.888431] RDX: ffff88023ec0f950 RSI: ffffffff8183b638 RDI: 00000000ffffffff [ 7344.888431] RBP: ffff880204687908 R08: 0000000000000001 R09: 0000000000000000 [ 7344.888431] R10: ffff880204687770 R11: ffffffff82f2d52d R12: 0000000000001000 [ 7344.888431] R13: ffff88021afbfee8 R14: 0000000000006208 R15: ffff88006cd199b0 [ 7344.888431] FS: 00007f1f9e1d6700(0000) GS:ffff88023ec00000(0000) knlGS:0000000000000000 [ 7344.888431] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 7344.888431] CR2: 00007f1f9dc8cb60 CR3: 000000023e3b6000 CR4: 00000000000006f0 [ 7344.888431] Stack: [ 7344.888431] 0000000000001000 0000000000001000 ffff880204687b98 ffff880204687950 [ 7344.888431] ffffffffa0395c8f ffffea0004d64d48 0000000000000000 0000000000001000 [ 7344.888431] ffffea0004d64d48 0000000000001000 0000000000000000 0000000000000000 [ 7344.888431] Call Trace: [ 7344.888431] [<ffffffffa0395c8f>] submit_extent_page+0xf5/0x16f [btrfs] [ 7344.888431] [<ffffffffa03970ac>] __do_readpage+0x4a0/0x4f1 [btrfs] [ 7344.888431] [<ffffffffa039680d>] ? btrfs_create_repair_bio+0xcb/0xcb [btrfs] [ 7344.888431] [<ffffffffa037eeb4>] ? btrfs_writepage_start_hook+0xbc/0xbc [btrfs] [ 7344.888431] [<ffffffff8108df55>] ? trace_hardirqs_on+0xd/0xf [ 7344.888431] [<ffffffffa039728c>] __do_contiguous_readpages.constprop.26+0xc2/0xe4 [btrfs] [ 7344.888431] [<ffffffffa037eeb4>] ? btrfs_writepage_start_hook+0xbc/0xbc [btrfs] [ 7344.888431] [<ffffffffa039739b>] __extent_readpages.constprop.25+0xed/0x100 [btrfs] [ 7344.888431] [<ffffffff81129d24>] ? lru_cache_add+0xe/0x10 [ 7344.888431] [<ffffffffa0397ea8>] extent_readpages+0x160/0x1aa [btrfs] [ 7344.888431] [<ffffffffa037eeb4>] ? btrfs_writepage_start_hook+0xbc/0xbc [btrfs] [ 7344.888431] [<ffffffff8115daad>] ? alloc_pages_current+0xa9/0xcd [ 7344.888431] [<ffffffffa037cdc9>] btrfs_readpages+0x1f/0x21 [btrfs] [ 7344.888431] [<ffffffff81128316>] __do_page_cache_readahead+0x168/0x1fc [ 7344.888431] [<ffffffff811285a0>] ondemand_readahead+0x1f6/0x207 [ 7344.888431] [<ffffffff811285a0>] ? ondemand_readahead+0x1f6/0x207 [ 7344.888431] [<ffffffff8111cf34>] ? pagecache_get_page+0x2b/0x154 [ 7344.888431] [<ffffffff8112870e>] page_cache_sync_readahead+0x3d/0x3f [ 7344.888431] [<ffffffff8111dbf7>] generic_file_read_iter+0x197/0x4e1 [ 7344.888431] [<ffffffff8117773a>] __vfs_read+0x79/0x9d [ 7344.888431] [<ffffffff81178050>] vfs_read+0x8f/0xd2 [ 7344.888431] [<ffffffff81178a38>] SyS_read+0x50/0x7e [ 7344.888431] [<ffffffff81492017>] entry_SYSCALL_64_fastpath+0x12/0x6b [ 7344.888431] Code: 8d 4d e8 45 31 c9 45 31 c0 48 8b 00 48 c1 e2 09 48 8b 80 80 fc ff ff 4c 89 65 e8 48 8b b8 f0 01 00 00 e8 1d 42 02 00 85 c0 79 02 <0f> 0b 4c 0 [ 7344.888431] RIP [<ffffffffa037c88c>] btrfs_merge_bio_hook+0x54/0x6b [btrfs] [ 7344.888431] RSP <ffff8802046878f0> [ 7344.970544] ---[ end trace eb7803b24ebab8ae ]--- Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> fs/btrfs/ctree.h | 14 ++++++++++++ fs/btrfs/extent-tree.c | 58 ++++++++++++++++++++++++++++++++++++++++++++++++-- fs/btrfs/inode.c | 8 +++++++ fs/btrfs/relocation.c | 6 +----- 4 files changed, 79 insertions(+), 7 deletions(-) commit 578def7c50f236432ba140d35bb7ca4ef0a1b20b Author: Filipe Manana <fdmanana@suse.com> Date: Tue Apr 26 15:36:38 2016 +0100 Btrfs: don't wait for unrelated IO to finish before relocation Before the relocation process of a block group starts, it sets the block group to readonly mode, then flushes all delalloc writes and then finally it waits for all ordered extents to complete. This last step includes waiting for ordered extents destinated at extents allocated in other block groups, making us waste unecessary time. So improve this by waiting only for ordered extents that fall into the block group's range. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> fs/btrfs/dev-replace.c | 4 ++-- fs/btrfs/extent-tree.c | 11 +++++++---- fs/btrfs/ioctl.c | 2 +- fs/btrfs/ordered-data.c | 26 +++++++++++++++++++------- fs/btrfs/ordered-data.h | 6 ++++-- fs/btrfs/relocation.c | 4 +++- fs/btrfs/super.c | 2 +- fs/btrfs/transaction.c | 2 +- 8 files changed, 38 insertions(+), 19 deletions(-) commit 3f9749f6e9edcf8ec569fb542efc3be35e06e84a Author: Filipe Manana <fdmanana@suse.com> Date: Mon Apr 25 04:45:02 2016 +0100 Btrfs: fix empty symlink after creating symlink and fsync parent dir If we create a symlink, fsync its parent directory, crash/power fail and mount the filesystem, we end up with an empty symlink, which not only is useless it's also not allowed in linux (the man page symlink(2) is well explicit about that). So we just need to make sure to fully log an inode if it's a symlink, to ensure its inline extent gets logged, ensuring the same behaviour as ext3, ext4, xfs, reiserfs, f2fs, nilfs2, etc. Example reproducer: $ mkfs.btrfs -f /dev/sdb $ mount /dev/sdb /mnt $ mkdir /mnt/testdir $ sync $ ln -s /mnt/foo /mnt/testdir/bar $ xfs_io -c fsync /mnt/testdir <power fail> $ mount /dev/sdb /mnt $ readlink /mnt/testdir/bar <empty string> A test case for fstests follows soon. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/tree-log.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 657ed1aa4898c8304500e0d13f240d5a67e8be5f Author: Filipe Manana <fdmanana@suse.com> Date: Wed Apr 6 17:11:56 2016 +0100 Btrfs: fix for incorrect directory entries after fsync log replay If we move a directory to a new parent and later log that parent and don't explicitly log the old parent, when we replay the log we can end up with entries for the moved directory in both the old and new parent directories. Besides being ilegal to have directories with multiple hard links in linux, it also resulted in the leaving the inode item with a link count of 1. A similar issue also happens if we move a regular file - after the log tree is replayed the file has a link in both the old and new parent directories, when it should be only at the new directory. Sample reproducer: $ mkfs.btrfs -f /dev/sdc $ mount /dev/sdc /mnt $ mkdir /mnt/x $ mkdir /mnt/y $ touch /mnt/x/foo $ mkdir /mnt/y/z $ sync $ ln /mnt/x/foo /mnt/x/bar $ mv /mnt/y/z /mnt/x/z < power fail > $ mount /dev/sdc /mnt $ ls -1Ri /mnt /mnt: 257 x 258 y /mnt/x: 259 bar 259 foo 260 z /mnt/x/z: /mnt/y: 260 z /mnt/y/z: $ umount /dev/sdc $ btrfs check /dev/sdc Checking filesystem on /dev/sdc UUID: a67e2c4a-a4b4-4fdc-b015-9d9af1e344be checking extents checking free space cache checking fs roots root 5 inode 260 errors 2000, link count wrong unresolved ref dir 257 index 4 namelen 1 name z filetype 2 errors 0 unresolved ref dir 258 index 2 namelen 1 name z filetype 2 errors 0 (...) Attempting to remove the directory becomes impossible: $ mount /dev/sdc /mnt $ rmdir /mnt/y/z $ ls -lh /mnt/y ls: cannot access /mnt/y/z: No such file or directory total 0 d????????? ? ? ? ? ? z $ rmdir /mnt/x/z rmdir: failed to remove ‘/mnt/x/z’: Stale file handle $ ls -lh /mnt/x ls: cannot access /mnt/x/z: Stale file handle total 0 -rw-r--r-- 2 root root 0 Apr 6 18:06 bar -rw-r--r-- 2 root root 0 Apr 6 18:06 foo d????????? ? ? ? ? ? z So make sure that on rename we set the last_unlink_trans value for our inode, even if it's a directory, to the value of the current transaction's ID and that if the new parent directory is logged that we fallback to a transaction commit. A test case for fstests is being submitted as well. Signed-off-by: Filipe Manana <fdmanana@suse.com> fs/btrfs/tree-log.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 0d5358330c20d50e52e3e65ff07a5db8007041fc Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri May 13 02:45:04 2016 +0200 Revert "pinctrl: tegra: avoid parked_reg and parked_bank" This reverts commit 1d18a3f0f0809f6c71f1f6e9e268ee904ce0b588. drivers/pinctrl/tegra/pinctrl-tegra.c | 8 ++++---- drivers/pinctrl/tegra/pinctrl-tegra.h | 6 +++++- drivers/pinctrl/tegra/pinctrl-tegra114.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra124.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra20.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra210.c | 4 +++- drivers/pinctrl/tegra/pinctrl-tegra30.c | 4 ++-- 7 files changed, 20 insertions(+), 14 deletions(-) commit ae05327a00fd47c34dfe25294b359a3f3fef96e8 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 20:36:01 2016 -0400 ext4: switch to ->iterate_shared() Note that we need relax_dir() equivalent for directories locked shared. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ext4/dir.c | 4 ++-- include/linux/fs.h | 7 +++++++ 2 files changed, 9 insertions(+), 2 deletions(-) commit 9717a91b01feda644f45fd63624a641385ef8f2d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 20:13:50 2016 -0400 hfs: switch to ->iterate_shared() exact parallel of hfsplus analogue Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/hfs/catalog.c | 3 +++ fs/hfs/dir.c | 12 +++++++++--- fs/hfs/hfs_fs.h | 1 + fs/hfs/inode.c | 2 ++ 4 files changed, 15 insertions(+), 3 deletions(-) commit 323ee8fc544d407eb053471b9607f95f987f5f12 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 20:02:09 2016 -0400 hfsplus: switch to ->iterate_shared() We need to protect the list of hfsplus_readdir_data against parallel insertions (in readdir) and removals (in release). Add a spinlock for that. Note that it has nothing to do with protection of hfsplus_readdir_data->key - we have an exclusion between hfsplus_readdir() and hfsplus_delete_cat() on directory lock and between several hfsplus_readdir() for the same struct file on ->f_pos_lock. The spinlock is strictly for list changes. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/hfsplus/catalog.c | 3 +++ fs/hfsplus/dir.c | 12 +++++++++--- fs/hfsplus/hfsplus_fs.h | 1 + fs/hfsplus/inode.c | 1 + fs/hfsplus/super.c | 1 + 5 files changed, 15 insertions(+), 3 deletions(-) commit 552a9d489f1412beb5914f0c64a54d921a9c6624 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 19:49:30 2016 -0400 hostfs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/hostfs/hostfs_kern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d674b3195b854eec26724b8e85c97da79cdcf9d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 19:44:04 2016 -0400 hpfs: switch to ->iterate_shared() NOTE: the only reason we can do that without ->i_rdir_offs races is that hpfs_lock() serializes everything in there anyway. It's not that hard to get rid of, but not as part of this series... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/hpfs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e82c3147554785414a10a2d424590758646972b2 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 19:35:57 2016 -0400 hpfs: handle allocation failures in hpfs_add_pos() pr_err() is nice, but we'd better propagate the error to caller and not proceed to violate the invariants (namely, "every file with f_pos tied to directory block should have its address visible in per-inode array"). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/hpfs/dir.c | 10 ++++++++-- fs/hpfs/dnode.c | 8 +++++--- fs/hpfs/hpfs_fn.h | 2 +- 3 files changed, 14 insertions(+), 6 deletions(-) commit b3d39032d7b33029373fbce6459aff6ac316e130 Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Mon Mar 28 20:36:59 2016 -0700 remoteproc: Add additional crash reasons The Qualcomm WCNSS can crash by watchdog or a fatal software error. Add these types to the list of remoteproc crash reasons. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> drivers/remoteproc/remoteproc_core.c | 2 ++ include/linux/remoteproc.h | 4 ++++ 2 files changed, 6 insertions(+) commit e395f9ce49eb5a9fa69c3fd74b6de59a5cb5a300 Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Mon Mar 28 20:36:58 2016 -0700 remoteproc: core: Make the loaded resource table optional Remote processors like the ones found in the Qualcomm SoCs does not have a resource table passed to them, so make it optional by only populating it if it does exist. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> drivers/remoteproc/remoteproc_core.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 9ffee1c4be7c1981e47e520172638a4b00881880 Author: Archit Taneja <architt@codeaurora.org> Date: Wed May 11 15:07:32 2016 +0530 clk: qcom: mmcc-8996: Remove clocks that should be controlled by RPM The branch clocks MMSS_MMAGIC_AXI_CLK and MMAGIC_BIMC_AXI_CLK are controlled by RPM when the APPs processor enable or disable the RPM_MMAXI_CLK. During the boot sequence, someone can enable the RPM_MMAXI_CLK, resulting in register status bits showing that these clocks are enabled, our clock driver may look at the enabled status of these clocks and try to disable them since it thinks they are unused. Don't make the clock driver touch these clocks. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/qcom/mmcc-msm8996.c | 32 -------------------------------- 1 file changed, 32 deletions(-) commit d8609a3a2e4f6fb1fa5cf2468547eb30507e78c4 Merge: 4afe2d1 3397c2c Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed May 11 11:39:17 2016 -0700 Merge tag 'imx-clk-fixes-4.6-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into clk-next Pull some non-critical i.MX clk fixes from Shawn Guo: * Fix the commit 3713e3f5e927 ("clk: imx35: define two clocks for rtc") which messed up the clock enumeration when adding new clock. * tag 'imx-clk-fixes-4.6-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: dts: imx35: restore existing used clock enumeration clk: imx6q: fix typo in CAN clock definition commit 4afe2d1a6ed5cba794aeeaa816e7c97a45167b01 Author: Harvey Hunt <harvey.hunt@imgtec.com> Date: Mon May 9 17:29:52 2016 +0100 clk: ingenic: Allow divider value to be divided The JZ4780's MSC clock divider registers multiply the clock divider by 2. This means that MMC devices run at half their expected speed. Add the ability to divide the clock divider in order to solve this. Signed-off-by: Harvey Hunt <harvey.hunt@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-clk@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ingenic/cgu.c | 11 ++++++++++- drivers/clk/ingenic/cgu.h | 6 +++++- drivers/clk/ingenic/jz4740-cgu.c | 24 ++++++++++++------------ drivers/clk/ingenic/jz4780-cgu.c | 40 ++++++++++++++++++++-------------------- 4 files changed, 47 insertions(+), 34 deletions(-) commit 5707291c6cada6db7344c90a548d02f427bf376c Merge: 98b8525 7e5385d Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon May 9 16:04:37 2016 -0700 Merge tag 'v4.7-rockchip-clk4' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-next Pull rockchip clk updates from Heiko Stuebner: Another small rk3399 fixup as well as simplifications around our handling of the General-Register-Files syscon. * tag 'v4.7-rockchip-clk4' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: drop old_rate calculation on pll rate changes clk: rockchip: simplify GRF handling in pll clocks clk: rockchip: lookup General Register Files in rockchip_clk_init clk: rockchip: fix the rk3399 sdmmc sample / drv name commit 98b8525abb7f0d9a5ab942a2e044011d7e635490 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Mon Apr 25 15:22:42 2016 +0200 clk: sunxi: Add display and TCON0 clocks driver The A10 SoCs and its relatives has a special clock controller to drive the display engines (both frontend and backend), that have a lot in common with the clock to drive the first TCON channel. Add a driver to support both. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> [sboyd@codeaurora.org: Silence variable sized array warning] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Documentation/devicetree/bindings/clock/sunxi.txt | 2 + drivers/clk/sunxi/Makefile | 1 + drivers/clk/sunxi/clk-sun4i-display.c | 261 ++++++++++++++++++++++ 3 files changed, 264 insertions(+) commit e7142c341c9ce3678f3533a2cfbf8477a09a95ad Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Wed May 11 19:15:45 2016 -0400 tipc: eliminate risk of double link_up events When an ACTIVATE or data packet is received in a link in state ESTABLISHING, the link does not immediately change state to ESTABLISHED, but does instead return a LINK_UP event to the caller, which will execute the state change in a different lock context. This non-atomic approach incurs a low risk that we may have two LINK_UP events pending simultaneously for the same link, resulting in the final part of the setup procedure being executed twice. The only potential harm caused by this it that we may see two LINK_UP events issued to subsribers of the topology server, something that may cause confusion. This commit eliminates this risk by checking if the link is already up before proceeding with the second half of the setup. Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/node.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d1bb236bc2ffb3586d6cc73e58c0d8351758123 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 12 17:00:20 2016 -0400 gfs2: switch to ->iterate_shared() protected by glock and already used without locking the directory by gfs2_get_name() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/gfs2/file.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2c4cb04300fa160e9d78335c74184c4e66a56437 Author: Omar Sandoval <osandov@fb.com> Date: Wed May 11 15:16:37 2016 -0700 coredump: only charge written data against RLIMIT_CORE Commit 9b56d54380ad ("dump_skip(): dump_seek() replacement taking coredump_params") introduced a regression with regard to RLIMIT_CORE. Previously, when a core dump was sparse, only the data that was actually written out would count against the limit. Now, the sparse ranges are also included, which leads to truncated core dumps when the actual disk usage is still well below the limit. Restore the old behavior by only counting what gets emitted and ignoring what gets skipped. Signed-off-by: Omar Sandoval <osandov@fb.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/coredump.c | 5 ++--- include/linux/binfmts.h | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) commit a00839395103d5e2d132a6c4a9680256580ed3d1 Author: Omar Sandoval <osandov@fb.com> Date: Wed May 11 15:16:36 2016 -0700 coredump: get rid of coredump_params->written cprm->written is redundant with cprm->file->f_pos, so use that instead. Signed-off-by: Omar Sandoval <osandov@fb.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> arch/powerpc/platforms/cell/spufs/coredump.c | 5 +++-- fs/binfmt_elf.c | 2 +- fs/binfmt_elf_fdpic.c | 2 +- fs/coredump.c | 8 +++----- include/linux/binfmts.h | 1 - 5 files changed, 8 insertions(+), 10 deletions(-) commit f893a99e7e2125ed7874d69cb309ca40a0bea371 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed May 11 17:02:05 2016 -0300 phy: micrel: Use MICREL_PHY_ID_MASK definition Replace the hardcoded mask 0x00fffff0 with MICREL_PHY_ID_MASK for better readability. Suggested-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/micrel.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) commit da73b4e9538b9be96498241ab3f13eab94181e96 Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Wed May 11 18:48:32 2016 +0800 gre: Fix wrong tpi->proto in WCCP When dealing with WCCP in gre6 tunnel, it sets the wrong tpi->protocol, that is, ETH_P_IP instead of ETH_P_IPV6 for the encapuslated traffic. Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/gre.h | 2 +- net/ipv4/gre_demux.c | 6 +++--- net/ipv4/ip_gre.c | 4 ++-- net/ipv6/ip6_gre.c | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) commit 23f72215bc030d1eea437713abfef91c635e2e1f Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Wed May 11 18:48:31 2016 +0800 ip6_gre: Fix get_size calculation for gre6 tunnel Do not include attribute IFLA_GRE_TOS. Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 3 --- 1 file changed, 3 deletions(-) commit a1f6ad14176d466c00e6a687f9c78ec6c7ad6bf8 Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Fri May 6 23:02:34 2016 +0200 ARM: dts: igep0020: Add SD card write-protect pin. A host device that supports write protection should refuse to write to an SD card that is designated read-only when write-protect is set. This is an optional feature of the SD specification. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-igep0020-common.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit b44f788cce4086da00fd2f14b6b4d5abcf85f842 Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Fri May 6 23:02:33 2016 +0200 ARM: dts: igep00x0: Add SD card-detect. Fix SD card remove/insert detection by adding the correct card-detect pin. All IGEP OMAP3 based boards use the same card-detect pin. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: Ladislav Michl <ladis@linux-mips.org> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-igep.dtsi | 1 + 1 file changed, 1 insertion(+) commit 65db875d110b8e517f81fa71c57a65fc6d0019ac Author: Dave Gerlach <d-gerlach@ti.com> Date: Thu May 12 13:20:52 2016 -0500 ARM: OMAP2+: AM43XX: Enable fixes for Cortex-A9 errata This patch explicitly enables the fixes for the below errata applicable for AM43x Socs as was done for OMAP4. 754322: Faulty MMU translations following ASID switch 775420: A data cache maintenance operation which aborts, followed by an ISB, without any DSB in-between, might lead to deadlock Signed-off-by: Dave Gerlach <d-gerlach@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/Kconfig | 2 ++ 1 file changed, 2 insertions(+) commit 3d9f77be066ccf8d364928154552ed6ca910793b Author: Nishanth Menon <nm@ti.com> Date: Fri May 6 08:37:57 2016 -0500 ARM: dts: am57xx-idk-common: Fix input supply names Palmas Regulator is an exception and does not follow the standard "vin-supply" common definitions for all regulators, as a result of this, the input supplies are not reported to regulator framework, with the obvious result of not being appropriately mapped. Fix the same. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-idk-common.dtsi | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) commit 10ce2404ccab6828f86fb038e4888837f49f9f48 Author: Franklin S Cooper Jr <fcooper@ti.com> Date: Wed May 4 12:43:55 2016 -0500 ARM: dts: dra7: Add gpmc dma channel Add dma channel information to the gpmc. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 1ddbef4d596ce51bf25825549bc5865de08a7e62 Author: Nicolas Chauvet <kwizart@gmail.com> Date: Tue May 10 12:14:58 2016 +0200 ARM: dts: disable mmc by default and enable when needed for dm814x This patch disable mmc nodes by default in the dm814x.dtsi and enable only when needed on a given dts v2: Disable un-used mmc nodes on the related boards dts files instead of from the included SOC dts Signed-off-by: Nicolas Chauvet <kwizart@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dm8148-evm.dts | 8 ++++++++ arch/arm/boot/dts/dm8148-t410.dts | 8 ++++++++ 2 files changed, 16 insertions(+) commit 54c78870e4d70420b887d712a3e73a6783d5b51d Author: Nicolas Chauvet <kwizart@gmail.com> Date: Tue May 10 12:14:57 2016 +0200 ARM: dts: Add non-removable to hsmmc on hp-t410 This will clean-up warnings at boot, since either that or cd-gpio{,s} are mandated by the dts specification of_get_named_gpiod_flags: can't parse 'cd-gpios' property of node '/ocp/mmc@47810000[0]' of_get_named_gpiod_flags: can't parse 'cd-gpio' property of node '/ocp/mmc@47810000[0]' v2: use the generic non-removable instead of ti,non-removable Signed-off-by: Nicolas Chauvet <kwizart@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dm8148-t410.dts | 1 + 1 file changed, 1 insertion(+) commit 6c05495d6d0507a6e7886265f82339bebf25cfed Author: Tony Lindgren <tony@atomide.com> Date: Thu May 12 13:29:48 2016 -0700 ARM: dts: Fix ldo7 source for HDMI on igepv5 Fix ldo7 source for HDMI on igepv5. Suggested-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-igep0050.dts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit e0e80d43fc0c5aace76a6c5f9462a1aec3e004f8 Author: Tony Lindgren <tony@atomide.com> Date: Thu May 12 13:29:48 2016 -0700 ARM: dts: Fix uart wakeirq on omap5 by removing WAKEUP_EN for omaps The padconf register WAKEUP_EN is now handled in a generic way using Linux wakeirqs where pinctrl-single toggles the WAKEUP_EN bit when a wakeirq is enabled or disabled. At least omap5 gets confused if the WAKEUP_EN bit is set and the pin is not claimed as a wakeirq. The end result is that wakeirqs don't work properly as there is nothing handling the wakeirq. So let's just remove the WAKEUP_EN usage from dts files. Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-evm-37xx.dts | 2 +- arch/arm/boot/dts/omap3-n900.dts | 4 ++-- arch/arm/boot/dts/omap3-n950-n9.dtsi | 6 +++--- arch/arm/boot/dts/omap3-zoom3.dts | 6 +++--- arch/arm/boot/dts/omap5-board-common.dtsi | 2 +- 5 files changed, 10 insertions(+), 10 deletions(-) commit 49111cd1c5498d2a356b0e51d74987dad0e88530 Author: Tony Lindgren <tony@atomide.com> Date: Thu May 12 13:29:48 2016 -0700 ARM: dts: Fix igepv5 audiopwon-gpio Playing audio works on omap5-uevm, but produces an "Unhandled fault: imprecise external abort (0x1406) at 0x00000000" error on igepv5. Looks like the twl6040 audpwron GPIO pin is different for these boards. Let's fix the issue by configuring the audpwron in the board specific dts file. Cc: Agustí Fontquerni <af@iseebcn.com> Cc: Eduard Gavin <egavin@iseebcn.com> Cc: Enric Balletbo i Serra <eballetbo@gmail.com> Acked-by: Peter Ujfalusi <peter.ujflausi@ti com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-board-common.dtsi | 3 ++- arch/arm/boot/dts/omap5-igep0050.dts | 10 ++++++++++ arch/arm/boot/dts/omap5-uevm.dts | 10 ++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) commit 0691a286d59183c44b68defd398cb7af0354bd00 Author: Christoph Hellwig <hch@lst.de> Date: Tue May 3 18:01:03 2016 +0200 IB/cma: pass the port number to ib_create_qp The new RW API will need this. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Tested-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/cma.c | 1 + 1 file changed, 1 insertion(+) commit 321aebb880d2bfdf9cff503f57207e930aee6b1d Merge: 80835cb 3849e44 Author: Doug Ledford <dledford@redhat.com> Date: Thu May 12 14:21:02 2016 -0400 Merge branches 'mlx5-1' and 'srp-1' into k.o/for-4.7 commit 80835cba4b857485b068e1ce83512e896e6f001e Author: Saeed Mahameed <saeedm@mellanox.com> Date: Wed Apr 13 19:11:04 2016 +0300 net/mlx5: Update mlx5_ifc hardware features Adding the needed mlx5_ifc hardware bits and structs for the following features: * Add vport to steering commands for SRIOV ACL support * Add mlcr, pcmr and mcia registers for dump module EEPROM * Add support for FCS, beacon led and disable_link bits to hca caps * Add CQE period mode bit in CQ context for CQE based CQ moderation support * Add umr SQ bit for fragmented memory registration * Add needed bits and caps for Striding RQ support In-order to avoid possible future conflicts between rdma and net-next we added all expected updates to this file for this release. If more changes will be submitted, we plan to do it only through one of the subsystems, probably net-next. All updated bits in this patch will be later used in the up-coming submissions to net-next and rdma trees. Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Acked-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/linux/mlx5/mlx5_ifc.h | 146 +++++++++++++++++++++++++++++++++++------- 1 file changed, 124 insertions(+), 22 deletions(-) commit c16aea129bf788127465771cab97134a94af33e4 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 13 19:11:03 2016 +0300 net/mlx5: Fix mlx5 ifc cmd_hca_cap bad offsets All reserved fields after early_vf_enable are off by 1, since early_vf_enable was not explicitly declared as array of size 1. Reserved field before cqe_zip had a wrong size, it should be 0x80 + 0x3f. Fixes: b0844444590e ("net/mlx5_core: Introduce access function to read internal timer ") Fixes: b4ff3a36d3e4 ("net/mlx5: Use offset based reserved field names in the IFC header file") Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Acked-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/linux/mlx5/mlx5_ifc.h | 107 ++++++++++++++++++++++-------------------- 1 file changed, 55 insertions(+), 52 deletions(-) commit 3849e44d1c4b11c9e0f0f0343a0360b5e9594fb6 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:15:04 2016 -0700 IB/srp: Move common code into the caller Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Sagi Grimberg <sai@grimberg.m> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 1 - 1 file changed, 1 deletion(-) commit 3b59b7a693b0e5b2dc244bcd78899aa2585a434b Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:14:43 2016 -0700 IB/srp: Move code out of a loop Since all srp_map_finish_fr() callers pass a non-zero value as the fourth argument (sg_nents), the sg_nents == 0 check in that function can be removed. Add a count == 0 check in the caller of that function. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit ffc548bb3601f0250474afcfa10ceb0b8b8b9764 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:14:15 2016 -0700 IB/srp: Avoid that mapping failure triggers an infinite loop The srp_queuecommand() function translates ENOMEM into QUEUE_FULL which causes the SCSI mid-layer to retry the command. All other error codes are translated into DID_ERROR which causes the SCSI command to fail. Return E2BIG if mapping will always fail to prevent that the SCSI mid-layer keeps resubmitting a command forever. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 ++ 1 file changed, 2 insertions(+) commit fa9863f869202a4ccc673cbd8dd326bf54a8efff Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:13:57 2016 -0700 IB/srp: Introduce target->mr_pool_size This patch does not change any functionality. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagig@mellanox.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 6 +++--- drivers/infiniband/ulp/srp/ib_srp.h | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) commit e012f3639c95498d4e8d7a9f44e33f1cd2f241b0 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:13:35 2016 -0700 IB/srp: Fix srp_map_data() error paths Ensure that req->nmdesc is set correctly in srp_map_sg() if mapping fails. Avoid that mapping failure causes a memory descriptor leak. Report srp_map_sg() failure to the caller. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) commit 77269cdfcab5f01ebd2095273f4060fbe1001e68 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:13:09 2016 -0700 IB/srp: Document srp_map_data() return value Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagig@mellanox.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 6ec2ba02e6b7fc4fcf8032bfd2bc6e6e20ca9c4a Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:12:47 2016 -0700 IB/srp: Fix a comment The free request list was removed through patch "IB/srp: Use block layer tags". Hence update a comment that refers to that free request list. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagi@grimberg.me> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d3d98c4cf4698324d71b29c84dcdc7802444376 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Fri Apr 22 14:12:10 2016 -0700 IB/srp: Fix a spelling error in a source code comment Change one occurrence of "boundries" into "boundaries". Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Sagi Grimberg <sagig@mellanox.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Laurence Oberman <loberman@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c0053bd50af57c4ebf032a9de1b07ca78c982452 Author: Nishanth Menon <nm@ti.com> Date: Thu Aug 6 10:54:24 2015 -0500 ARM: OMAP5 / DRA7: Introduce workaround for 801819 Add workaround for Cortex-A15 ARM erratum 801819 which says in summary that "A livelock can occur in the L2 cache arbitration that might prevent a snoop from completing. Under certain conditions this can cause the system to deadlock. " Recommended workaround is as follows: Do both of the following: 1) Do not use the write-back no-allocate memory type. 2) Do not issue write-back cacheable stores at any time when the cache is disabled (SCTLR.C=0) and the MMU is enabled (SCTLR.M=1). Because it is implementation defined whether cacheable stores update the cache when the cache is disabled it is not expected that any portable code will execute cacheable stores when the cache is disabled. For implementations of Cortex-A15 configured without the “L2 arbitration register slice” option (typically one or two core systems), you must also do the following: 3) Disable write-streaming in each CPU by setting ACTLR[28:25] = 0b1111 So, we provide an option to disable write streaming on OMAP5 and DRA7. It is a rare condition to occur and may be enabled selectively based on platform acceptance of risk. Applies to: A15 revisions r2p0, r2p1, r2p2, r2p3 or r2p4 and REVIDR[3] is set to 0. Based on ARM errata Document revision 18.0 (22 Nov 2013) Note: the configuration for the workaround needs to be done with each CPU bringup, since CPU0 bringup is done by bootloader, it is recommended to have the workaround in the bootloader, kernel also does ensure that CPU0 has the workaround and makes the workaround active when CPU1 gets active. With CONFIG_SMP disabled, it is expected to be done by the bootloader. This does show significant degradation in synthetic tests such as mbw (https://packages.qa.debian.org/m/mbw.html) mbw -n 100 100|grep AVG (on a test platform) Without enabling the erratum: AVG Method: MEMCPY Elapsed: 0.13406 MiB: 100.00000 Copy: 745.913 MiB/s AVG Method: DUMB Elapsed: 0.06746 MiB: 100.00000 Copy: 1482.357 MiB/s AVG Method: MCBLOCK Elapsed: 0.03058 MiB: 100.00000 Copy: 3270.569 MiB/s After enabling the erratum: AVG Method: MEMCPY Elapsed: 0.13757 MiB: 100.00000 Copy: 726.913 MiB/s AVG Method: DUMB Elapsed: 0.12024 MiB: 100.00000 Copy: 831.668 MiB/s AVG Method: MCBLOCK Elapsed: 0.09243 MiB: 100.00000 Copy: 1081.942 MiB/s Most benchmarks are designed for specific performance analysis, so overall usecase must be considered before making a decision to enable/disable the erratum workaround. Pending internal investigation, the erratum is kept disabled by default. Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Tony Lindgren <tony@atomide.com> Suggested-by: Richard Woodruff <r-woodruff2@ti.com> Suggested-by: Brad Griffis <bgriffis@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/Kconfig | 8 +++++++ arch/arm/mach-omap2/omap-secure.h | 1 + arch/arm/mach-omap2/omap-smp.c | 48 +++++++++++++++++++++++++++++++++++---- 3 files changed, 52 insertions(+), 5 deletions(-) commit 27ee441a43392ebe5b027fe5d78640e839673d21 Author: Pablo Neira <pablo@netfilter.org> Date: Thu May 12 17:16:31 2016 +0200 gtp: put back reference to netns when not required anymore This patch fixes a netns leak. Fixes: 93edb8c7f94f ("gtp: reload GTPv1 header after pskb_may_pull()") Reported-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/gtp.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 639db596165746ca87bbcb56559b094fd9042890 Author: Takashi Iwai <tiwai@suse.de> Date: Thu May 12 18:04:16 2016 +0200 ALSA: au88x0: Fix zero clear of stream->resources There are a few calls of memset() to stream->resources, but they all are called in a wrong size, sizeof(unsigned char) * VORTEX_RESOURCE_LAST, while this field is a u32 array. This may leave the memories not zero-cleared. Fix it by replacing them with a simpler sizeof(stream->resources) instead. Reported-by: David Binderman <dcb314@hotmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/au88x0/au88x0_core.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit 7598469a6184e1017a77ebe78b5b66c52a6afc1c Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 15:42:08 2016 +0200 ata: dwc: add DMADEVICES dependency The dwc_460ex SATA driver has become available on non-powerpc architectures and may cause randconfig build errors when CONFIG_DMADEVICES is not set and SATA_DWC_OLD_DMA is enabled: warning: (SATA_DWC_OLD_DMA) selects DW_DMAC_CORE which has unmet direct dependencies (DMADEVICES) ERROR: "dw_dma_probe" [drivers/ata/sata_dwc_460ex.ko] undefined! ERROR: "dw_dma_remove" [drivers/ata/sata_dwc_460ex.ko] undefined! This adds an explcit Kconfig dependency to CONFIG_SATA_DWC so we cannot run into broken configurations. While it would also be possible to build the driver with both CONFIG_DMADEVICES and SATA_DWC_OLD_DMA disabled, that case is not useful because there is no fallback to PIO mode when the DMA engine is not usable. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 50b433753df6 ("ata: sata_dwc_460ex: use "dmas" DT property to find dma channel") Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 7fd38193d0473acc6e8f108107d0466f07768853 Merge: 4889929 46fa38e Author: David S. Miller <davem@davemloft.net> Date: Thu May 12 11:46:58 2016 -0400 Merge tag 'mac80211-next-for-davem-2016-05-12' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next Johannes Berg says: ==================== Some more work for 4.7, notably: * completion and fixups of nla_put_64_64bit() work * remove a/b/g/n from wext nickname to avoid confusion with 11ac (which wouldn't even fit fully there due to string length restrictions) along with some other minor changes/cleanups. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a7f1884554b81bd68cd435d72f09a3527629ac43 Author: Florian Westphal <fw@strlen.de> Date: Thu May 12 14:43:54 2016 +0200 netfilter: nfnetlink_queue: fix timestamp attribute Since 4.4 we erronously use timestamp of the netlink skb (which is zero). Bugzilla: https://bugzilla.netfilter.org/show_bug.cgi?id=1066 Fixes: b28b1e826f818c30ea7 ("netfilter: nfnetlink_queue: use y2038 safe timestamp") Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nfnetlink_queue.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 951b8e4e673196932fa4c3b87d719644636e5ac9 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:24 2016 +0300 powerpc/4xx: Device tree update for the 460ex DWC SATA Device tree update for the Applied micro processor 460ex on-chip SATA to use "dmas" property. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> arch/powerpc/boot/dts/canyonlands.dts | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit bb08ab6a4c9cee6e544aeb5de3ed92cd78c6ede4 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:23 2016 +0300 ata: sata_dwc_460ex: make debug messages neat There is a duplication in the debug messages when accessing SCR registers. Remove duplication to make the messages neat. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit d6ecf0c27d71666a4be46e13a1b234d17c63eb98 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:18 2016 +0300 ata: sata_dwc_460ex: supply physical address of FIFO to DMA DMA operates with physical addresses which is not exactly the same as ioremap() returns. Introduce variable to keep physical address of the SATA FIFO register and supply it when prepare DMA channel. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit 73ec1b5ab3a713141318ee845d8b0cc822db65b1 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:22 2016 +0300 ata: sata_dwc_460ex: use devm_ioremap This simplifies error handling and cleanup by using devm to manage IO mappings. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 30 +++++++++++------------------- 1 file changed, 11 insertions(+), 19 deletions(-) commit af50f3a8b61cfdfcf4a01b01ec2759200d362605 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:21 2016 +0300 ata: sata_dwc_460ex: tidy up sata_dwc_clear_dmacr() This consolidates the reads from each of the if/else branches to one place making the code a lot nicer to look at. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit ee81d6cc8e8aa667aabce72f39a4b806419e1d55 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:20 2016 +0300 ata: sata_dwc_460ex: use readl/writel_relaxed() Rename the register access macros and use standard _relaxed() ops instead of __raw variants with explicit byte swapping. The original driver used the ppc-specific in/out_le32(). When it was adapted to other systems, these were added to the driver under ifdefs. However, those names are not defined as macros on ppc, so it ended up replacing them there as well with altered semantics. This patch restores the original semantics on ppc and makes the accesses no less strict on other systems. Also fixes too many sparse warnings to count. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 91 +++++++++++++++++++++----------------------- 1 file changed, 43 insertions(+), 48 deletions(-) commit 9e8b855e9841eeb9c13e79d50f70dc000b0dfbfd Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:19 2016 +0300 ata: sata_dwc_460ex: switch to new dmaengine_terminate_* API Convert dmaengine_terminate_all() calls to synchronous and asynchronous versions where appropriate. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de1965159a34951a86267d13db4f2a67234139d3 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Thu May 12 01:36:40 2016 +0300 rcar: src: skip disabled-SRC nodes The current device tree representation of the R-Car Sample Rate Converters (SRC) assumes that they are numbered consecutively, starting from 0. Alas, this is not the case with the R8A7794 SoC where SRC0 isn't present. In order to keep the existing device trees working, I'm suggesting to use a disabled node for SRC0. Teach the SRC probe to just skip disabled nodes. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sh/rcar/src.c | 4 ++++ 1 file changed, 4 insertions(+) commit b9c17f13ba484d8492278c67cd95b7207def776f Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 12 09:38:50 2016 +0530 ASoC: rt298: Add DMI match for Broxton-P reference platform Broxton-P reference platform also uses combo jack for audio connector so we need to set codec pdata to use this based on DMI match for this board. Signed-off-by: Ramesh Babu <ramesh.babu@intel.com> Signed-off-by: Senthilnathan Veppur <senthilnathanx.veppur@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Acked-by: Bard Liao <bardliao@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt298.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit bb7cb54b388d8d0fbb3af27f14b121ee9c92e867 Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 12 09:38:49 2016 +0530 ASoC: rt298: fix null deref on acpi driver data ACPI driver data can be NULL so we need to check that before dereference the driver data. Signed-off-by: Senthilnathan Veppur <senthilnathanx.veppur@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Acked-by: Bard Liao <bardliao@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt298.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 32902177f7f6ae70e1d5e71d935aa1bfcae7f01c Author: John Keeping <john@metanate.com> Date: Thu May 12 13:55:53 2016 +0100 ASoC: dapm: deprecate MICBIAS widget type Commit 086d7f804e26 ("ASoC: Convert WM8962 MICBIAS to a supply widget", 2011-09-23) says: A supply widget is generally clearer than a MICBIAS widget and a mic bias is just a type of supply so use a supply widget for the MICBIAS. This also avoids confusion with the routing when connected to multiple inputs. but this has never been documented as a policy. Add some comments to make it clear. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/soc-dapm.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit e6d9a52543338603e25e71e0e4942f05dae0dd8a Author: Colin Ian King <colin.king@canonical.com> Date: Wed May 11 17:56:54 2016 +0100 arm64: do not enforce strict 16 byte alignment to stack pointer copy_thread should not be enforcing 16 byte aligment and returning -EINVAL. Other architectures trap misaligned stack access with SIGBUS so arm64 should follow this convention, so remove the strict enforcement check. For example, currently clone(2) fails with -EINVAL when passing a misaligned stack and this gives little clue to what is wrong. Instead, it is arguable that a SIGBUS on the fist access to a misaligned stack allows one to figure out that it is a misaligned stack issue rather than trying to figure out why an unconventional (and undocumented) -EINVAL is being returned. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/process.c | 3 --- 1 file changed, 3 deletions(-) commit e2724e9d969294879936daf7833d4adda26c8efc Author: Jeremy Compostella <jeremy.compostella@intel.com> Date: Wed May 11 17:23:34 2016 +0200 x86/tsc: Add missing Cherrytrail frequency to the table Intel Cherrytrail is based on Airmont core so MSR_FSB_FREQ[2:0] = 4 means that the CPU reference clock runs at 80MHz. Add this missing frequency to the table. Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com> Link: http://lkml.kernel.org/r/87y47gty89.fsf@intel.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> arch/x86/kernel/tsc_msr.c | 3 +++ 1 file changed, 3 insertions(+) commit c5076cfe768998e9d395bc8486b29b18b0f99fd9 Author: Tomasz Nowicki <tn@semihalf.com> Date: Wed May 11 17:34:51 2016 -0500 PCI, of: Move PCI I/O space management to PCI core code No functional changes in this patch. PCI I/O space mapping code does not depend on OF; therefore it can be moved to PCI core code. This way we will be able to use it, e.g., in ACPI PCI code. Suggested-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Tomasz Nowicki <tn@semihalf.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: Arnd Bergmann <arnd@arndb.de> CC: Liviu Dudau <Liviu.Dudau@arm.com> drivers/of/address.c | 116 +-------------------------------------------- drivers/pci/pci.c | 115 ++++++++++++++++++++++++++++++++++++++++++++ include/linux/of_address.h | 9 ---- include/linux/pci.h | 5 ++ 4 files changed, 121 insertions(+), 124 deletions(-) commit 1958e7173df14ff50d75ed2fbd24b349d25caf80 Author: Jayachandran C <jchandra@broadcom.com> Date: Wed May 11 17:34:46 2016 -0500 PCI: generic, thunder: Use generic ECAM API Use functions provided by drivers/pci/ecam.h for mapping the config space in drivers/pci/host/pci-host-common.c, and update its users to use 'struct pci_config_window' and 'struct pci_ecam_ops'. The changes are mostly to use 'struct pci_config_window' in place of 'struct gen_pci'. Some of the fields of gen_pci were only used temporarily and can be eliminated by using local variables or function arguments, these are not carried over to struct pci_config_window. pci-thunder-ecam.c and pci-thunder-pem.c are the only users of the pci_host_common_probe function and the gen_pci structure; these have been updated to use the new API as well. The patch does not introduce any functional changes other than a very minor one: with the new code, on 64-bit platforms, we do just a single ioremap for the whole config space. Signed-off-by: Jayachandran C <jchandra@broadcom.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/ecam.h | 5 ++ drivers/pci/host/Kconfig | 1 + drivers/pci/host/pci-host-common.c | 114 +++++++++++++++--------------------- drivers/pci/host/pci-host-common.h | 47 --------------- drivers/pci/host/pci-host-generic.c | 52 ++++------------ drivers/pci/host/pci-thunder-ecam.c | 39 +++--------- drivers/pci/host/pci-thunder-pem.c | 92 ++++++++++++++--------------- 7 files changed, 113 insertions(+), 237 deletions(-) commit 1d4e89cf0a4e819fbde428e9e5286e7141a02e06 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Thu May 12 15:47:10 2016 +1000 powerpc/powernv/npu: Add PE to PHB's list Before commit 3e68dc57 "powerpc/powernv: Remove DMA32 PE list", NPU PEs were linked to the NPU PHB via phb->ioda.pe_dma_list; after that fix, the phb->ioda.pe_list is used. During the pe_dma_list removal, list_add_tail(&phb->ioda.pe_dma_list) was removed, however no list_add() was added so does this patch. Fixes: 3e68dc57219a ("powerpc/powernv: Remove DMA32 PE list") Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 3 +++ 1 file changed, 3 insertions(+) commit 92a86756904b127a3450262b33c0b9f8e99f6b36 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Thu May 12 15:47:09 2016 +1000 powerpc/powernv: Fix insufficient memory allocation The pnv_pci_init_ioda_phb() helper allocates a blob to store auxilary data such PE and M32/M64 segment allocation maps; this single blob has few partitions, size of each is derived from the PE number - phb->ioda.total_pe_num. It was assumed that the minimum PE number is 8, however it is 4 for NPU so the pe_alloc part was missing in the allocated blob. It was invisible till recently as we were not tracking used M64 segments and NPUs do not use M32 segments so the phb->ioda.m32_segmap (which was pointing to the same address as phb->ioda.pe_alloc) has never been written to leaving the pe_alloc memory intact. After commit 401203ac2d "powerpc/powernv: Track M64 segment consumption" the pe_alloc gets corrupted and PE allocation cannot work. This fixes the issue by enforcing the minimum PE number to 8. Fixes: 401203ac2d15 ("powerpc/powernv: Track M64 segment consumption") Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8445a87f7092bc8336ea1305be9306f26b846d93 Author: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Date: Mon Apr 11 16:17:23 2016 -0300 powerpc/iommu: Remove the dependency on EEH struct in DDW mechanism Commit 39baadbf36ce ("powerpc/eeh: Remove eeh information from pci_dn") changed the pci_dn struct by removing its EEH-related members. As part of this clean-up, DDW mechanism was modified to read the device configuration address from eeh_dev struct. As a consequence, now if we disable EEH mechanism on kernel command-line for example, the DDW mechanism will fail, generating a kernel oops by dereferencing a NULL pointer (which turns to be the eeh_dev pointer). This patch just changes the configuration address calculation on DDW functions to a manual calculation based on pci_dn members instead of using eeh_dev-based address. No functional changes were made. This was tested on pSeries, both in PHyp and qemu guest. Fixes: 39baadbf36ce ("powerpc/eeh: Remove eeh information from pci_dn") Cc: stable@vger.kernel.org # v3.4+ Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/iommu.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit c2078d9ef600bdbe568c89e5ddc2c6f15b7982c8 Author: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Date: Mon Apr 11 16:17:22 2016 -0300 Revert "powerpc/eeh: Fix crash in eeh_add_device_early() on Cell" This reverts commit 89a51df5ab1d38b257300b8ac940bbac3bb0eb9b. The function eeh_add_device_early() is used to perform EEH initialization in devices added later on the system, like in hotplug/DLPAR scenarios. Since the commit 89a51df5ab1d ("powerpc/eeh: Fix crash in eeh_add_device_early() on Cell") a new check was introduced in this function - Cell has no EEH capabilities which led to kernel oops if hotplug was performed, so checking for eeh_enabled() was introduced to avoid the issue. However, in architectures that EEH is present like pSeries or PowerNV, we might reach a case in which no PCI devices are present on boot time and so EEH is not initialized. Then, if a device is added via DLPAR for example, eeh_add_device_early() fails because eeh_enabled() is false, and EEH end up not being enabled at all. This reverts the aforementioned patch since a new verification was introduced by the commit d91dafc02f42 ("powerpc/eeh: Delay probing EEH device during hotplug") and so the original Cell issue does not happen anymore. Cc: stable@vger.kernel.org # v4.1+ Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d6d63d720db3a63dd45142c2ce7978b52e0e684f Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Wed Apr 27 11:14:53 2016 +1000 powerpc/eeh: Drop unnecessary label in eeh_pe_change_owner() The label "reset" in eeh_pe_change_owner() is used only for once. No need to keep it and just drop it. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 2efc771f2492dfce71ce281efb9cc93c3ae8f2fc Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Wed Apr 27 11:14:52 2016 +1000 powerpc/eeh: Ignore handlers in eeh_pe_reset_and_recover() The function eeh_pe_reset_and_recover() is used to recover EEH error when the passthrough device are transferred to guest and backwards, meaning the device's driver is vfio-pci or none. In both cases, the handlers triggered by eeh_report_reset() and eeh_report_resume() shouldn't be called. This ignores the error handlers from eeh_report_reset() and eeh_report_resume(). Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh_driver.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 5a0cdbfd17b90a89c64a71d8aec9773ecdb20d0d Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Wed Apr 27 11:14:51 2016 +1000 powerpc/eeh: Restore initial state in eeh_pe_reset_and_recover() The function eeh_pe_reset_and_recover() is used to recover EEH error when the passthrou device are transferred to guest and backwards. The content in the device's config space will be lost on PE reset issued in the middle of the recovery. The function saves/restores it before/after the reset. However, config access to some adapters like Broadcom BCM5719 at this point will causes fenced PHB. The config space is always blocked and we save 0xFF's that are restored at late point. The memory BARs are totally corrupted, causing another EEH error upon access to one of the memory BARs. This restores the config space on those adapters like BCM5719 from the content saved to the EEH device when it's populated, to resolve above issue. Fixes: 5cfb20b9 ("powerpc/eeh: Emulate EEH recovery for VFIO devices") Cc: stable@vger.kernel.org #v3.18+ Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh_driver.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit affeb0f2d3a9af419ad7ef4ac782e1540b2f7b28 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Wed Apr 27 11:14:50 2016 +1000 powerpc/eeh: Don't report error in eeh_pe_reset_and_recover() The function eeh_pe_reset_and_recover() is used to recover EEH error when the passthrough device are transferred to guest and backwards, meaning the device's driver is vfio-pci or none. When the driver is vfio-pci that provides error_detected() error handler only, the handler simply stops the guest and it's not expected behaviour. On the other hand, no error handlers will be called if we don't have a bound driver. This ignores the error handler in eeh_pe_reset_and_recover() that reports the error to device driver to avoid the exceptional behaviour. Fixes: 5cfb20b9 ("powerpc/eeh: Emulate EEH recovery for VFIO devices") Cc: stable@vger.kernel.org #v3.18+ Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh_driver.c | 3 --- 1 file changed, 3 deletions(-) commit 848912e547c4569445a61203a7df402646a88c25 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu May 12 19:43:37 2016 +1000 Revert "powerpc/powernv: Exclude root bus in pnv_pci_reset_secondary_bus()" This reverts commit c8ceacc22bce95d3a9cff198c9c27a30105a16b8. Gavin says: I missed the fact that it affects the PCI passthrou path as reported by Alexey: When passing GPU (0003:01:00.0) which seats behind the root port, the reset request is routed to skiboot in original code. In skiboot, the link bouncing events are masked during the reset. So we don't see EEH (freeze all) error even link bouncing happens. With the changes included, the reset is done by kernel and the link bouncing events aren't masked by altering content of PHB3 (or P7IOC) specific hardware registers which are invisible to kernel (skiboot hides the hardware specific). It means the link bouncing is seen by the root port and it causes a EEH (freeze all) error. The PCI passthrough on GPU device cannot work. Requested-by: Alexey Kardashevskiy <aik@ozlabs.ru> Requested-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/eeh-powernv.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 227e4f4079e198695b9b5df344aa0e29676a5a29 Author: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Date: Thu May 5 11:47:07 2016 +0530 drm/panel: simple: Add support for TPK U.S.A. LLC Fusion 7" and 10.1" panels Add support for TPK U.S.A. LLC Fusion 7", 10.1" panels to the DRM simple panel driver. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/display/panel/tpk,f07a-0102.txt | 8 ++++ .../bindings/display/panel/tpk,f10a-0102.txt | 8 ++++ .../devicetree/bindings/vendor-prefixes.txt | 1 + drivers/gpu/drm/panel/panel-simple.c | 51 ++++++++++++++++++++++ 4 files changed, 68 insertions(+) commit 0647e7dd3f7ab2e0490691eae185ab0c49fc266f Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Mon May 2 09:54:26 2016 +0200 drm/bridge: Add Analogix anx78xx support Although there are other chips from the same family that can reuse this driver, at the moment we only tested ANX7814 chip. The ANX7814 is an ultra-low power Full-HD (1080p60) SlimPort transmitter designed for portable devices. This driver adds initial support for HDMI to DP pass-through mode. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Tested-by: Nicolas Boichat <drinkcat@chromium.org> Reviewed-by: Nicolas Boichat <drinkcat@chromium.org> Cc: Emil Velikov <emil.l.velikov@gmail.com> Cc: Rob Herring <robh@kernel.org> Cc: Dan Carpenter <dan.carpenter@oracle.com> Cc: Daniel Kurtz <djkurtz@chromium.org> Cc: Nicolas Boichat <drinkcat@chromium.org> Cc: Thierry Reding <treding@nvidia.com> [treding@nvidia.com: coding style, propagate regulator_get() errors] Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/gpu/drm/bridge/Kconfig | 10 + drivers/gpu/drm/bridge/Makefile | 1 + drivers/gpu/drm/bridge/analogix-anx78xx.c | 1514 +++++++++++++++++++++++++++++ drivers/gpu/drm/bridge/analogix-anx78xx.h | 719 ++++++++++++++ 4 files changed, 2244 insertions(+) commit 6060fd42a24d1c3fd6282659da3b097582dc1bca Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Mon May 2 09:54:25 2016 +0200 devicetree: Add ANX7814 SlimPort transmitter binding The ANX7814 is an ultra-low power Full-HD (1080p60) SlimPort transmitter designed for portable devices. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../devicetree/bindings/video/bridge/anx7814.txt | 40 ++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit ae4927ffc7f7090ddb4c833b88f6f09f294502cd Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Mon May 2 09:54:24 2016 +0200 of: Add vendor prefix for Analogix Semiconductor Analogix Semiconductor Inc. develops analog and mixed-signal devices for digital media and communications interconnect applications. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 56c5da00271e656466d34b853d6c2b5f3ce3ee5a Author: Enric Balletbo i Serra <enric.balletbo@collabora.com> Date: Mon May 2 09:54:23 2016 +0200 drm/dp: Add define to set 0.5% down-spread in MAX_DOWNSPREAD register Support of 0.5% down-spread is required for DisplayPort Specification Version 1.1 Sink. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> [treding@nvidia.com: rename to DP_MAX_DOWNSPREAD_0_5] Signed-off-by: Thierry Reding <treding@nvidia.com> include/drm/drm_dp_helper.h | 1 + 1 file changed, 1 insertion(+) commit 4fc24ab3a13b071b2574ef6e0f28b8f2cd2e85a8 Author: Riccardo Bortolato <bortolato@navaltechitalia.it> Date: Wed Apr 20 15:37:15 2016 +0200 drm/panel: simple: Add support for Innolux AT070TN92 Add support for the Innolux AT070TN92 panel. Signed-off-by: Riccardo Bortolato <bortolato@navaltechitalia.it> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/display/panel/innolux,at070tn92.txt | 7 ++++++ drivers/gpu/drm/panel/panel-simple.c | 26 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) commit 844e2f5290799e9eac04951371593efcf2ad4660 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 30 16:38:36 2015 +0200 drm/panel: simple: Remove useless drm_mode_set_name() drm_display_mode_from_videomode() already calls drm_mode_set_name() on the provided mode. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> [treding@nvidia.com: slightly reword commit message] Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/gpu/drm/panel/panel-simple.c | 2 -- 1 file changed, 2 deletions(-) commit cda553725c92b9f908f6f69e9bc05de81384d817 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 15 18:23:33 2016 +0200 drm/panel: simple: Set appropriate mode type All modes exposed by simple panels should be tagged as driver defined modes. Moreover, if a panel supports only one mode, this mode is obviously the preferred one. Doing this also fix a problem occurring when a 'video=' parameter is passed on the kernel command line. In some cases the user provided mode will be preferred over the simple panel ones, which might result in unpredictable behavior. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> [treding@nvidia.com: reshuffle some code for consistency] Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/gpu/drm/panel/panel-simple.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit cf5c9e6dc70d9d8af00ea45b4ebd67e1fc35764e Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:34 2016 +0100 drm/panel: simple: Add timings for the Olimex LCD-OLinuXino-4.3TS Add support for the Olimex LCD-OLinuXino-4.3TS panel to the DRM simple panel driver. It is a 480x272 panel connected through a 24-bits RGB interface. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../display/panel/olimex,lcd-olinuxino-43-ts.txt | 7 ++++++ drivers/gpu/drm/panel/panel-simple.c | 26 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) commit e8b6f561b2eeb667aff932d9a5af5a6279221283 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 24 17:23:48 2016 -0700 drm/panel: simple: Add the 7" DPI panel from Adafruit This is a basic TFT panel with a 40-pin FPC connector on it. The specification doesn't define timings, but the Adafruit instructions were setting up 800x480 CVT. v2: Add .bus_format and vsync/hsync flags. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Rob Herring <robh@kernel.org> [treding@nvidia.com: keep entries properly sorted] Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/display/panel/ontat,yx700wv03.txt | 7 ++++ drivers/gpu/drm/panel/panel-simple.c | 37 ++++++++++++++++++++++ 2 files changed, 44 insertions(+) commit 686cfbd18668eaab303b28de2b45a1ffaf1e6247 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 24 17:23:47 2016 -0700 of: Add vendor prefix for On Tat Industrial Company. This is the vendor for a 7" DPI panel sold by Adafruit which I'd like to describe in DT. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 46fa38e84b656f80edf83d21144221b0cad18d61 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue May 3 16:58:00 2016 +0300 mac80211: allow software PS-Poll/U-APSD with AP_LINK_PS When using RSS, frames might not be processed in the correct order, and thus AP_LINK_PS must be used; most likely with firmware keeping track of the powersave state, this is the case in iwlwifi now. In this case, the driver can use ieee80211_sta_ps_transition() to still have mac80211 manage powersave buffering. However, for U-APSD and PS-Poll this isn't sufficient. If the device can't manage that entirely on its own, mac80211's code should be used. To allow this, export two functions: ieee80211_sta_uapsd_trigger() and ieee80211_sta_pspoll(). Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 27 +++++++++++++++++++ net/mac80211/rx.c | 70 +++++++++++++++++++++++++++++++------------------- 2 files changed, 71 insertions(+), 26 deletions(-) commit 53873f134d285191ef6435882d55837093a36c53 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue May 3 16:52:04 2016 +0300 cfg80211: make wdev_list accessible to drivers There's no harm in having drivers read the list, since they can use RCU protection or RTNL locking; allow this to not require each and every driver to also implement its own bookkeeping. Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 5 +++++ net/wireless/chan.c | 2 +- net/wireless/core.c | 17 ++++++++++------- net/wireless/core.h | 3 +-- net/wireless/nl80211.c | 16 ++++++++-------- net/wireless/reg.c | 2 +- net/wireless/sme.c | 4 ++-- net/wireless/sysfs.c | 2 +- net/wireless/util.c | 4 ++-- 9 files changed, 31 insertions(+), 24 deletions(-) commit 8b9b2f06998f33bdd1774a9860ec60e945977384 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue May 3 16:26:40 2016 +0300 cfg80211: remove erroneous comment The devlist_mtx mutex was removed about two years ago, in favour of just using RTNL/RCU protection. Remove the comment still referencing it. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/wireless/core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9e9ea43905597d9ba79b421b87c7851b8350717c Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Tue May 3 16:08:07 2016 +0300 cfg80211: allow finding vendor with OUI without specifying the OUI type This allows finding vendor IE from a specific vendor. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 4 ++-- net/wireless/scan.c | 8 ++++++-- 2 files changed, 8 insertions(+), 4 deletions(-) commit f631a77ba920f7153a1094d09cd8f2ebbffd0328 Author: Sara Sharon <sara.sharon@intel.com> Date: Tue May 3 15:59:44 2016 +0300 mac80211: allow same PN for AMSDU sub-frames Some hardware (iwlwifi an example) de-aggregate AMSDUs and copy the IV as is to the generated MPDUs, so the same PN appears in multiple packets without being a replay attack. Allow driver to explicitly indicate that a frame is allowed to have the same PN as the previous frame. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 6 +++++- net/mac80211/wpa.c | 16 ++++++++++++---- 2 files changed, 17 insertions(+), 5 deletions(-) commit 20eb7ea93f7ffaaa24b19b8bfc411b1f7605759f Author: David Spinadel <david.spinadel@intel.com> Date: Tue May 3 16:05:02 2016 +0300 mac80211: remove disconnected APs from BSS table In some cases, after a sudden AP disappearing and reconnection to another AP in the same ESS, user space gets the old AP in scan results (cached). User space may decide to roam to that old AP which will cause a disconnection and longer recovery. Remove APs that are probably out of range from BSS table. Signed-off-by: David Spinadel <david.spinadel@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mlme.c | 5 +++++ 1 file changed, 5 insertions(+) commit 2c1984f244838477aab4e5882f4479491ae1084a Author: David Sterba <dsterba@suse.com> Date: Thu May 12 11:05:03 2016 +0200 btrfs: build fixup for qgroup_account_snapshot The macro btrfs_std_error got renamed to btrfs_handle_fs_error in an independent branch for the same merge target (4.7). To make the code compilable for bisectability reasons, add a temporary stub. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/transaction.c | 5 +++++ 1 file changed, 5 insertions(+) commit 6426c7ad697df4bddf1d222685e6802e7616feaa Author: Qu Wenruo <quwenruo@cn.fujitsu.com> Date: Wed May 11 12:53:52 2016 -0700 btrfs: qgroup: Fix qgroup accounting when creating snapshot Current btrfs qgroup design implies a requirement that after calling btrfs_qgroup_account_extents() there must be a commit root switch. Normally this is OK, as btrfs_qgroup_accounting_extents() is only called inside btrfs_commit_transaction() just be commit_cowonly_roots(). However there is a exception at create_pending_snapshot(), which will call btrfs_qgroup_account_extents() but no any commit root switch. In case of creating a snapshot whose parent root is itself (create a snapshot of fs tree), it will corrupt qgroup by the following trace: (skipped unrelated data) ====== btrfs_qgroup_account_extent: bytenr = 29786112, num_bytes = 16384, nr_old_roots = 0, nr_new_roots = 1 qgroup_update_counters: qgid = 5, cur_old_count = 0, cur_new_count = 1, rfer = 0, excl = 0 qgroup_update_counters: qgid = 5, cur_old_count = 0, cur_new_count = 1, rfer = 16384, excl = 16384 btrfs_qgroup_account_extent: bytenr = 29786112, num_bytes = 16384, nr_old_roots = 0, nr_new_roots = 0 ====== The problem here is in first qgroup_account_extent(), the nr_new_roots of the extent is 1, which means its reference got increased, and qgroup increased its rfer and excl. But at second qgroup_account_extent(), its reference got decreased, but between these two qgroup_account_extent(), there is no switch roots. This leads to the same nr_old_roots, and this extent just got ignored by qgroup, which means this extent is wrongly accounted. Fix it by call commit_cowonly_roots() after qgroup_account_extent() in create_pending_snapshot(), with needed preparation. Mark: I added a check at the top of qgroup_account_snapshot() to skip this code if qgroups are turned off. xfstest btrfs/122 exposes this problem. Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: Mark Fasheh <mfasheh@suse.de> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/transaction.c | 129 ++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 105 insertions(+), 24 deletions(-) commit 3f56e687a138481894a1088d5aa7d41951bdb020 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Tue May 10 16:18:33 2016 +0300 perf/core: Disable the event on a truncated AUX record When the PMU driver reports a truncated AUX record, it effectively means that there is no more usable room in the event's AUX buffer (even though there may still be some room, so that perf_aux_output_begin() doesn't take action). At this point the consumer still has to be woken up and the event has to be disabled, otherwise the event will just keep spinning between perf_aux_output_begin() and perf_aux_output_end() until its context gets unscheduled. Again, for cpu-wide events this means never, so once in this condition, they will be forever losing data. Fix this by disabling the event and waking up the consumer in case of a truncated AUX record. Reported-by: Markus Metzger <markus.t.metzger@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1462886313-13660-3-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/ring_buffer.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 5fbe4788b55540a6c4fe2c47e05482ac356eaf74 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Tue May 10 16:18:32 2016 +0300 perf/x86/intel/pt: Generate PMI in the STOP region as well Currently, the PT driver always sets the PMI bit one region (page) before the STOP region so that we can wake up the consumer before we run out of room in the buffer and have to disable the event. However, we also need an interrupt in the last output region, so that we actually get to disable the event (if no more room from new data is available at that point), otherwise hardware just quietly refuses to start, but the event is scheduled in and we end up losing trace data till the event gets removed. For a cpu-wide event it is even worse since there may not be any re-scheduling at all and no chance for the ring buffer code to notice that its buffer is filled up and the event needs to be disabled (so that the consumer can re-enable it when it finishes reading the data out). In other words, all the trace data will be lost after the buffer gets filled up. This patch makes PT also generate a PMI when the last output region is full. Reported-by: Markus Metzger <markus.t.metzger@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1462886313-13660-2-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 2 ++ 1 file changed, 2 insertions(+) commit 5319e5ad0c4ed416d00515c96f493653f9929c65 Merge: 9ab975a 6d6f283 Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 12 10:14:45 2016 +0200 Merge branch 'perf/urgent' into perf/core, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 50605ffbdaf6d7ccab70d4631fd8347fc78af14f Author: Thomas Gleixner <tglx@linutronix.de> Date: Wed May 11 14:23:31 2016 +0200 sched/core: Provide a tsk_nr_cpus_allowed() helper tsk_nr_cpus_allowed() is an accessor for task->nr_cpus_allowed which allows us to change the representation of ->nr_cpus_allowed if required. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1462969411-17735-2-git-send-email-bigeasy@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 5 +++++ kernel/sched/core.c | 2 +- kernel/sched/deadline.c | 28 ++++++++++++++-------------- kernel/sched/rt.c | 24 ++++++++++++------------ 4 files changed, 32 insertions(+), 27 deletions(-) commit ade42e092b5d1fb9a77b026f019b9953d66f1573 Author: Thomas Gleixner <tglx@linutronix.de> Date: Wed May 11 14:23:30 2016 +0200 sched/core: Use tsk_cpus_allowed() instead of accessing ->cpus_allowed Use the future-safe accessor for struct task_struct's. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1462969411-17735-1-git-send-email-bigeasy@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/cpudeadline.c | 4 ++-- kernel/sched/cpupri.c | 4 ++-- kernel/sched/deadline.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) commit 20878232c52329f92423d27a60e48b6a6389e0dd Author: Vik Heyndrickx <vik.heyndrickx@veribox.net> Date: Thu Apr 28 20:46:28 2016 +0200 sched/loadavg: Fix loadavg artifacts on fully idle and on fully loaded systems Systems show a minimal load average of 0.00, 0.01, 0.05 even when they have no load at all. Uptime and /proc/loadavg on all systems with kernels released during the last five years up until kernel version 4.6-rc5, show a 5- and 15-minute minimum loadavg of 0.01 and 0.05 respectively. This should be 0.00 on idle systems, but the way the kernel calculates this value prevents it from getting lower than the mentioned values. Likewise but not as obviously noticeable, a fully loaded system with no processes waiting, shows a maximum 1/5/15 loadavg of 1.00, 0.99, 0.95 (multiplied by number of cores). Once the (old) load becomes 93 or higher, it mathematically can never get lower than 93, even when the active (load) remains 0 forever. This results in the strange 0.00, 0.01, 0.05 uptime values on idle systems. Note: 93/2048 = 0.0454..., which rounds up to 0.05. It is not correct to add a 0.5 rounding (=1024/2048) here, since the result from this function is fed back into the next iteration again, so the result of that +0.5 rounding value then gets multiplied by (2048-2037), and then rounded again, so there is a virtual "ghost" load created, next to the old and active load terms. By changing the way the internally kept value is rounded, that internal value equivalent now can reach 0.00 on idle, and 1.00 on full load. Upon increasing load, the internally kept load value is rounded up, when the load is decreasing, the load value is rounded down. The modified code was tested on nohz=off and nohz kernels. It was tested on vanilla kernel 4.6-rc5 and on centos 7.1 kernel 3.10.0-327. It was tested on single, dual, and octal cores system. It was tested on virtual hosts and bare hardware. No unwanted effects have been observed, and the problems that the patch intended to fix were indeed gone. Tested-by: Damien Wyart <damien.wyart@free.fr> Signed-off-by: Vik Heyndrickx <vik.heyndrickx@veribox.net> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: <stable@vger.kernel.org> Cc: Doug Smythies <dsmythies@telus.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: 0f004f5a696a ("sched: Cure more NO_HZ load average woes") Link: http://lkml.kernel.org/r/e8d32bff-d544-7748-72b5-3c86cc71f09f@veribox.net Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/loadavg.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit cfa10334318d8212d007da8c771187643c9cef35 Author: Morten Rasmussen <morten.rasmussen@arm.com> Date: Fri Apr 29 20:32:40 2016 +0100 sched/fair: Correct unit of load_above_capacity In calculate_imbalance() load_above_capacity currently has the unit [capacity] while it is used as being [load/capacity]. Not only is it wrong it also makes it unlikely that load_above_capacity is ever used as the subsequent code picks the smaller of load_above_capacity and the avg_load This patch ensures that load_above_capacity has the right unit [load/capacity]. Signed-off-by: Morten Rasmussen <morten.rasmussen@arm.com> [ Changed changelog to note it was in capacity unit; +rebase. ] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1461958364-675-4-git-send-email-dietmar.eggemann@arm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 1be0eb2a97d756fb7dd8c9baf372d81fa9699c09 Author: Peter Zijlstra <peterz@infradead.org> Date: Fri May 6 12:21:23 2016 +0200 sched/fair: Clean up scale confusion Wanpeng noted that the scale_load_down() in calculate_imbalance() was weird. I agree, it should be SCHED_CAPACITY_SCALE, since we're going to compare against busiest->group_capacity, which is in [capacity] units. Reported-by: Wanpeng Li <wanpeng.li@hotmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yuyang Du <yuyang.du@intel.com> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 444969223c81c7d0a95136b7b4cfdcfbc96ac5bd Author: Wanpeng Li <wanpeng.li@hotmail.com> Date: Wed May 4 14:45:34 2016 +0800 sched/nohz: Fix affine unpinned timers mess The following commit: 9642d18eee2c ("nohz: Affine unpinned timers to housekeepers")' intended to affine unpinned timers to housekeepers: unpinned timers(full dynaticks, idle) => nearest busy housekeepers(otherwise, fallback to any housekeepers) unpinned timers(full dynaticks, busy) => nearest busy housekeepers(otherwise, fallback to any housekeepers) unpinned timers(houserkeepers, idle) => nearest busy housekeepers(otherwise, fallback to itself) However, the !idle_cpu(i) && is_housekeeping_cpu(cpu) check modified the intention to: unpinned timers(full dynaticks, idle) => any housekeepers(no mattter cpu topology) unpinned timers(full dynaticks, busy) => any housekeepers(no mattter cpu topology) unpinned timers(housekeepers, idle) => any busy cpus(otherwise, fallback to any housekeepers) This patch fixes it by checking if there are busy housekeepers nearby, otherwise falls to any housekeepers/itself. After the patch: unpinned timers(full dynaticks, idle) => nearest busy housekeepers(otherwise, fallback to any housekeepers) unpinned timers(full dynaticks, busy) => nearest busy housekeepers(otherwise, fallback to any housekeepers) unpinned timers(housekeepers, idle) => nearest busy housekeepers(otherwise, fallback to itself) Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> [ Fixed the changelog. ] Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Fixes: 'commit 9642d18eee2c ("nohz: Affine unpinned timers to housekeepers")' Link: http://lkml.kernel.org/r/1462344334-8303-1-git-send-email-wanpeng.li@hotmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 2f950354e6d535b892f133d20bd6a8b09430424c Author: Peter Zijlstra <peterz@infradead.org> Date: Wed May 11 19:27:56 2016 +0200 sched/fair: Fix fairness issue on migration Pavan reported that in the presence of very light tasks (or cgroups) the placement of migrated tasks can cause severe fairness issues. The problem is that enqueue_entity() places the task before it updates time, thereby it can place the task far in the past (remember that light tasks will shoot virtual time forward at a high speed, so in relation to the pre-existing light task, we can land far in the past). This is done because update_curr() needs the current task, and we might be placing the current task. The obvious solution is to differentiate between the current and any other task; placing the current before we update time, and placing any other task after, such that !curr tasks end up at the current moment in time, and not in the past. This commit re-introduces the previously reverted commit: 3a47d5124a95 ("sched/fair: Fix fairness issue on migration") ... which is now safe to do, after we've also fixed another underlying bug first, in: sched/fair: Prepare to fix fairness problems on migration and cleaned up other details in the migration code: sched/core: Kill sched_class::task_waking Reported-by: Pavan Kondeti <pkondeti@codeaurora.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) commit 59efa0bac9cf8b2ef8d08f7632826c6d90f6a9bb Author: Peter Zijlstra <peterz@infradead.org> Date: Tue May 10 18:24:37 2016 +0200 sched/core: Kill sched_class::task_waking to clean up the migration logic With sched_class::task_waking being called only when we do set_task_cpu(), we can make sched_class::migrate_task_rq() do the work and eliminate sched_class::task_waking entirely. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Hunter <ahh@google.com> Cc: Ben Segall <bsegall@google.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Mike Galbraith <efault@gmx.de> Cc: Mike Galbraith <umgwanakikbuti@gmail.com> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Paul Turner <pjt@google.com> Cc: Pavan Kondeti <pkondeti@codeaurora.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: byungchul.park@lge.com Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 9 +------- kernel/sched/fair.c | 58 +++++++++++++++++++++++++--------------------------- kernel/sched/sched.h | 7 +++---- 3 files changed, 32 insertions(+), 42 deletions(-) commit b5179ac70de85ef477cedf8b026a57913754cf1e Author: Peter Zijlstra <peterz@infradead.org> Date: Wed May 11 16:10:34 2016 +0200 sched/fair: Prepare to fix fairness problems on migration Mike reported that our recent attempt to fix migration problems: 3a47d5124a95 ("sched/fair: Fix fairness issue on migration") broke interactivity and the signal starve test. We reverted that commit and now let's try it again more carefully, with some other underlying problems fixed first. One problem is that I assumed ENQUEUE_WAKING was only set when we do a cross-cpu wakeup (migration), which isn't true. This means we now destroy the vruntime history of tasks and wakeup-preemption suffers. Cure this by making my assumption true, only call sched_class::task_waking() when we do a cross-cpu wakeup. This avoids the indirect call in the case we do a local wakeup. Reported-by: Mike Galbraith <mgalbraith@suse.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Hunter <ahh@google.com> Cc: Ben Segall <bsegall@google.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Paul Turner <pjt@google.com> Cc: Pavan Kondeti <pkondeti@codeaurora.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: byungchul.park@lge.com Cc: linux-kernel@vger.kernel.org Fixes: 3a47d5124a95 ("sched/fair: Fix fairness issue on migration") Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 29 +++++++++++++++++++++-------- kernel/sched/fair.c | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 58 insertions(+), 8 deletions(-) commit c58d25f371f5e4b2dfbec3a7bd6f3c24dd79095b Author: Peter Zijlstra <peterz@infradead.org> Date: Thu May 12 09:19:59 2016 +0200 sched/fair: Move record_wakee() Since I want to make ->task_woken() conditional on the task getting migrated, we cannot use it to call record_wakee(). Move it to select_task_rq_fair(), which gets called in almost all the same conditions. The only exception is if the woken task (@p) is CPU-bound (as per the nr_cpus_allowed test in select_task_rq()). Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Hunter <ahh@google.com> Cc: Ben Segall <bsegall@google.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Mike Galbraith <efault@gmx.de> Cc: Mike Galbraith <umgwanakikbuti@gmail.com> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Paul Turner <pjt@google.com> Cc: Pavan Kondeti <pkondeti@codeaurora.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: byungchul.park@lge.com Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 61 +++++++++++++++++++++++++++++------------------------ 1 file changed, 33 insertions(+), 28 deletions(-) commit 4eb867651721228ee2eeae142c53378375303e8b Merge: eb60b3e e5ef27d Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 12 09:51:36 2016 +0200 Merge branch 'smp/hotplug' into sched/core, to resolve conflicts Conflicts: kernel/sched/core.c Signed-off-by: Ingo Molnar <mingo@kernel.org> commit eb60b3e5e8dfdd590e586a6fc22daf2f63a7b7e6 Merge: 58fe9c4 53d3bc7 Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 12 09:18:13 2016 +0200 Merge branch 'sched/urgent' into sched/core to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 754a92305980b1fecffe033dd3fdc49c37f8e4b0 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:29 2016 +0200 x86/RAS: Add SMCA support to AMD Error Injector Use SMCA MSRs when writing to MCA_{STATUS,ADDR,MISC} and MCA_DE{STAT,ADDR} when injecting Deferred Errors on SMCA platforms. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-8-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/ras/mce_amd_inj.c | 31 +++++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 6 deletions(-) commit a348ed83d9efe8c11ecc85c15d7329825b97431e Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:28 2016 +0200 EDAC, mce_amd: Detect SMCA using X86_FEATURE_SMCA Use X86_FEATURE_SMCA when detecting if SMCA is available instead of directly using CPUID 0x80000007_EBX. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-7-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/edac/mce_amd.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 14cddfd5308b0880abd6e58b6660f5cc8e8020f9 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:27 2016 +0200 x86/mce: Update AMD mcheck init to use cpu_has() facilities Use cpu_has() facilities to find available RAS features rather than directly reading CPUID 0x80000007_EBX. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Use the struct cpuinfo_x86 ptr instead. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-6-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 71faad43060d3d2040583635fbf7d1bdb3d04118 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:26 2016 +0200 x86/cpu: Add detection of AMD RAS Capabilities Add a new CPUID leaf to hold the contents of CPUID 0x80000007_EBX (RasCap). Define bits that are currently in use: Bit 0: McaOverflowRecov Bit 1: SUCCOR Bit 3: ScalableMca Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Shorten comment. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-5-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 + arch/x86/include/asm/cpufeatures.h | 7 ++++++- arch/x86/kernel/cpu/common.c | 10 +++++++--- 3 files changed, 14 insertions(+), 4 deletions(-) commit e128b4f4833cc1e0ce46dfb978763b260f166188 Author: Borislav Petkov <bp@suse.de> Date: Wed May 11 14:58:25 2016 +0200 x86/mce/AMD: Save an indentation level in prepare_threshold_block() Do the !SMCA work first and then save us an indentation level for the SMCA code. No functionality change. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Yazen Ghannam <Yazen.Ghannam@amd.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-4-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce_amd.c | 78 ++++++++++++++++++------------------ 1 file changed, 38 insertions(+), 40 deletions(-) commit 32544f060326bffa60dade49ce4595652df4d3ab Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:24 2016 +0200 x86/mce/AMD: Disable LogDeferredInMcaStat for SMCA systems Disable Deferred Error logging in MCA_{STATUS,ADDR} additionally for SMCA systems as this information will retrieved from MCA_DE{STAT,ADDR} on those systems. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Simplify, drop SMCA_MCAX_EN_OFF define too. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce_amd.c | 38 +++++++++++++++++++++++++++--------- 1 file changed, 29 insertions(+), 9 deletions(-) commit 34102009580a047c02b21f089f7fc7f65e605887 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Wed May 11 14:58:23 2016 +0200 x86/mce/AMD: Log Deferred Errors using SMCA MCA_DE{STAT,ADDR} registers Scalable MCA provides new registers for all banks for logging deferred errors: MCA_DESTAT and MCA_DEADDR. Deferred errors are always logged to these registers. Update the AMD deferred error handler to use these registers, if available. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Sanity-check __log_error() args, massage a bit. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462971509-3856-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/mce.h | 4 ++++ arch/x86/kernel/cpu/mcheck/mce_amd.c | 32 ++++++++++++++++++++++++-------- 2 files changed, 28 insertions(+), 8 deletions(-) commit 9ab975a029ec96b47c2f830aef6efd0e24f5c304 Merge: 38f5d8b d65444d Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 12 08:57:52 2016 +0200 Merge tag 'perf-core-for-mingo-20160511' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Fix symbol insertion and callchain behavior in db-export (Chris Phlipot) Infrastructure changes: - Add libunwind build test (feature query), working towards supporting cross-platform DWARF callchains, starting with arm/arm64 (He Kuang) - Use lsdir() more extensively (Masami Hiramatsu) - Use SBUILD_ID_SIZE in places where the equivalent expression was being used (Masami Hiramatsu) - Split some more 'perf trace' syscall arg beautifiers (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit b1a4286b8f3393857a205ec89607683161b75f90 Author: Paul Mackerras <paulus@ozlabs.org> Date: Wed May 4 21:07:52 2016 +1000 KVM: PPC: Book3S HV: Re-enable XICS fast path for irqfd-generated interrupts Commit c9a5eccac1ab ("kvm/eventfd: add arch-specific set_irq", 2015-10-16) added the possibility for architecture-specific code to handle the generation of virtual interrupts in atomic context where possible, without having to schedule a work function. Since we can easily generate virtual interrupts on XICS without having to do anything worse than take a spinlock, we define a kvm_arch_set_irq_inatomic() for XICS. We also remove kvm_set_msi() since it is not used any more. The one slightly tricky thing is that with the new interface, we don't get told whether the interrupt is an MSI (or other edge sensitive interrupt) vs. level-sensitive. The difference as far as interrupt generation is concerned is that for LSIs we have to set the asserted flag so it will continue to fire until it is explicitly cleared. In fact the XICS code gets told which interrupts are LSIs by userspace when it configures the interrupt via the KVM_DEV_XICS_GRP_SOURCES attribute group on the XICS device. To store this information, we add a new "lsi" field to struct ics_irq_state. With that we can also do a better job of returning accurate values when reading the attribute group. Signed-off-by: Paul Mackerras <paulus@samba.org> arch/powerpc/kvm/book3s_xics.c | 25 +++++++++++++++---------- arch/powerpc/kvm/book3s_xics.h | 1 + 2 files changed, 16 insertions(+), 10 deletions(-) commit 07b0e7d49cbcadebad9d3b986f3298e33286dea2 Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Thu Apr 7 10:59:45 2016 +0530 dmaengine: vdma: Add Support for Xilinx AXI Central Direct Memory Access Engine This patch adds support for the AXI Central Direct Memory Access (AXI CDMA) core to the existing vdma driver, AXI CDMA is a soft Xilinx IP core that provides high-bandwidth Direct Memory Access(DMA) between a memory-mapped source address and a memory-mapped destination address. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 236 ++++++++++++++++++++++++++++++++++++++- include/linux/dma/xilinx_dma.h | 2 + 2 files changed, 236 insertions(+), 2 deletions(-) commit 3843dc282e2b48730c4dc669d7d5671331155c2f Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Thu Apr 7 10:59:44 2016 +0530 Documentation: DT: vdma: update binding doc for AXI CDMA This patch updates the device-tree binding doc for adding support for AXI CDMA. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/devicetree/bindings/dma/xilinx/xilinx_vdma.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit c0bba3a99f0709c24c2c7ada7cb098966b1d791f Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Thu Apr 7 10:59:43 2016 +0530 dmaengine: vdma: Add Support for Xilinx AXI Direct Memory Access Engine This patch adds support for the AXI Direct Memory Access (AXI DMA) core in the existing vdma driver, AXI DMA Core is a soft Xilinx IP core that provides high-bandwidth direct memory access between memory and AXI4-Stream type target peripherals. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 474 +++++++++++++++++++++++++++++++++++---- include/linux/dma/xilinx_dma.h | 12 + 2 files changed, 444 insertions(+), 42 deletions(-) commit 7e4cda70c0be3c82c0248aee5c4c255e46469fd7 Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Thu Apr 7 10:59:42 2016 +0530 Documentation: DT: vdma: update binding doc for AXI DMA This patch updates the device-tree binding doc for adding support for AXI DMA. Also this patch differentiates required properties b/w DMA and VDMA. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> .../devicetree/bindings/dma/xilinx/xilinx_vdma.txt | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 42c1a2ede4f6a320d6843fc846f5466bff836a0c Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Thu Apr 7 10:59:41 2016 +0530 dmaengine: vdma: Rename xilinx_vdma_ prefix to xilinx_dma This patch renames the xilinx_vdma_ prefix to xilinx_dma for the API's and masks that will be shared b/w three DMA IP cores. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 632 +++++++++++++++++++-------------------- 1 file changed, 316 insertions(+), 316 deletions(-) commit dd4e91d538b3d16d5241575a3fb654a9aa50392c Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue May 10 20:43:34 2016 +0300 dmaengine: slave means at least one of DMA_SLAVE, DMA_CYCLIC When check for capabilities recognize slave support by either DMA_SLAVE or DMA_CYCLIC bit set. If we don't do that the user can't get a normally worked DMA support for engines that doesn't have one of the mentioned bits set. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dmaengine.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 488992916c50890fbe5e7057e29681a4c4fdf1f8 Merge: 631ad4a 831bfb0 Author: David S. Miller <davem@davemloft.net> Date: Thu May 12 00:04:08 2016 -0400 Merge branch 'qed-sriov' Yuval Mintz says: ==================== qed*: Add SR-IOV support This patch adds SR-IOV support to qed/qede drivers, adding a new PCI device ID for a VF that is shared between all the various PFs that support IOV. This is quite a massive series - the first 7 parts of the series add the infrastructure of supporting vfs in qed - mainly adding support in a HW-based vf<->pf channel, as well as diverging all existing configuration flows based on the pf/vf decision. I.e., while PF-originated requests head directly to HW/FW, the VF requests first have to traverse to the PF which will perform the configuration. The 8th patch is the one that adds the support for the VF device in qede. The remaining 6 patches each adds some user-based API support related to VFs that can be used over the PF - forcing mac/vlan, changing speed, etc. Dave, Sorry in advance for the length of the series. Most of the bulk here is in the infrastructure patches that have to go together [or at least, it makes little sense to try splitting them up]. Please consider applying this to `net-next'. Thanks, Yuval Changes from previous revision: ------------------------------ - V2 - Replace aligned_u64 with regular u64; This was possible as the shared structures [between PF and VF] were already sufficiently padded as-is in the API, making this redundant. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 831bfb0e88b54726d6e027a1d547066ffeb8b27e Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:25 2016 +0300 qed*: Tx-switching configuration Device should be configured by default to VEB once VFs are active. This changes the configuration of both PFs' and VFs' vports into enabling tx-switching once sriov is enabled. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 3 ++- drivers/net/ethernet/qlogic/qed/qed_l2.c | 4 ++++ drivers/net/ethernet/qlogic/qed/qed_l2.h | 1 + drivers/net/ethernet/qlogic/qed/qed_main.c | 1 + drivers/net/ethernet/qlogic/qed/qed_sp.h | 3 ++- drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 5 ++++- drivers/net/ethernet/qlogic/qed/qed_sriov.c | 1 + drivers/net/ethernet/qlogic/qed/qed_vf.c | 12 ++++++++++++ drivers/net/ethernet/qlogic/qede/qede_main.c | 24 ++++++++++++++++++++++- include/linux/qed/qed_eth_if.h | 2 ++ include/linux/qed/qed_if.h | 1 + 11 files changed, 53 insertions(+), 4 deletions(-) commit 73390ac9d82bf9f0c849ff57b06a03145fbf05d6 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:24 2016 +0300 qed*: support ndo_get_vf_config Allows the user to view the VF configuration by observing the PF's device. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_sriov.c | 93 ++++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qede/qede_main.c | 12 ++++ include/linux/qed/qed_iov_if.h | 3 + 3 files changed, 108 insertions(+) commit 6ddc7608258d57d61e16d55461400bb6eff18d72 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:23 2016 +0300 qed*: IOV support spoof-checking Add support in `ndo_set_vf_spoofchk' for allowing PF control over its VF spoof-checking configuration. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_l2.c | 4 ++ drivers/net/ethernet/qlogic/qed/qed_l2.h | 2 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 91 ++++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 2 + drivers/net/ethernet/qlogic/qede/qede_main.c | 11 ++++ include/linux/qed/qed_iov_if.h | 2 + 6 files changed, 112 insertions(+) commit 733def6a04bf3d2810dd675e1240f8df94d633c3 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:22 2016 +0300 qed*: IOV link control This adds support in 2 ndo that allow PF to tweak the VF's view of the link - `ndo_set_vf_link_state' to allow it a view independent of the PF's, and `ndo_set_vf_rate' which would allow the PF to limit the VF speed. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 2 + drivers/net/ethernet/qlogic/qed/qed_dev.c | 76 +++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.c | 164 +++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 6 + drivers/net/ethernet/qlogic/qede/qede_main.c | 26 +++++ include/linux/qed/qed_iov_if.h | 6 + 6 files changed, 280 insertions(+) commit eff169608c250193e72089dc4ab15cb79e0bd68c Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:21 2016 +0300 qed*: Support forced MAC Allows the PF to enforce the VF's mac. i.e., by using `ip link ... vf <x> mac <value>'. While a MAC is forced, PF would prevent the VF from configuring any other MAC. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_l2.c | 9 ++ drivers/net/ethernet/qlogic/qed/qed_sriov.c | 120 +++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 1 + drivers/net/ethernet/qlogic/qed/qed_vf.c | 47 +++++++++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 21 +++++ drivers/net/ethernet/qlogic/qede/qede_main.c | 31 +++++++ include/linux/qed/qed_eth_if.h | 3 + include/linux/qed/qed_iov_if.h | 2 + 8 files changed, 234 insertions(+) commit 08feecd7fc709077ce92d21a979f522a5f57170a Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:20 2016 +0300 qed*: Support PVID configuration This adds support for PF control over the VF vlan configuration. I.e., `ip link ... vf <x> vlan <vid>' should now be supported. 1. <vid> != 0 => VF receives [unknowingly] only traffic tagged by <vid> and tags all outgoing traffic sent by VF with <vid>. 2. <vid> == 0 ==> Remove the pvid configuration, reverting to previous. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 9 +- drivers/net/ethernet/qlogic/qed/qed_l2.c | 14 +- drivers/net/ethernet/qlogic/qed/qed_l2.h | 6 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 364 ++++++++++++++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_sriov.h | 26 ++ drivers/net/ethernet/qlogic/qed/qed_vf.c | 18 +- drivers/net/ethernet/qlogic/qed/qed_vf.h | 19 +- drivers/net/ethernet/qlogic/qede/qede_main.c | 18 ++ include/linux/qed/qed_iov_if.h | 1 + 9 files changed, 468 insertions(+), 7 deletions(-) commit fefb0202cc5c12172abba78a8404e69c6d82d680 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:19 2016 +0300 qede: Add VF support Adding a PCI callback for `sriov_configure' and a new PCI device id for the VF [+ Some minor changes to accomodate differences between PF and VF at the qede]. Following this, VF creation should be possible and the entire subset of existing PF functionality that's allow to VFs should be supported. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede.h | 4 ++ drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 43 +++++++++++++++++++- drivers/net/ethernet/qlogic/qede/qede_main.c | 52 +++++++++++++++++++++---- 3 files changed, 90 insertions(+), 9 deletions(-) commit 17b235c1456e4ab203c39050c5535e28fe7d0de9 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:18 2016 +0300 qed: Align TLVs As the VF infrastructure is supposed to offer backward/forward compatibility, the various types associated with VF<->PF communication should be aligned across all various platforms that support IOV on our family of adapters. This adds a couple of currently missing values, specifically aligning the enum for the various TLVs possible in the communication between them. It then adds the PF implementation for some of those missing VF requests. This support isn't really necessary for the Linux VF as those VFs aren't requiring it [at least today], but are required by VFs running on other OSes. LRO is an example of one such configuration. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_l2.c | 92 ++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_l2.h | 52 +++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.c | 169 ++++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 4 + drivers/net/ethernet/qlogic/qed/qed_vf.c | 6 + drivers/net/ethernet/qlogic/qed/qed_vf.h | 54 ++++++++- 6 files changed, 375 insertions(+), 2 deletions(-) commit 36558c3d77032feb2a49ff7818338256378a774f Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:17 2016 +0300 qed: Bulletin and Link Up to this point, VF and PF communication always originates from VF. As a result, VF cannot be notified of any async changes, and specifically cannot be informed of the current link state. This introduces the bulletin board, the mechanism through which the PF is going to communicate async notifications back to the VF. basically, it's a well-defined structure agreed by both PF and VF which the VF would continuously poll and into which the PF would DMA messages when needed. [Bulletin board is actually allocated and communicated in previous patches but never before used] Based on the bulletin infrastructure, the VF can query its link status and receive said async carrier changes. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 12 ++- drivers/net/ethernet/qlogic/qed/qed_sriov.c | 136 +++++++++++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_sriov.h | 5 + drivers/net/ethernet/qlogic/qed/qed_vf.c | 122 ++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 156 ++++++++++++++++++++++++++++ 5 files changed, 425 insertions(+), 6 deletions(-) commit dacd88d6f6851510735e8db7a5981d4abcda6cb2 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:16 2016 +0300 qed: IOV l2 functionality This adds sufficient changes to allow VFs l2-configuration flows to work. While the fastpath of the VF and the PF are meant to be exactly the same, the configuration of the VF is done by the PF. This diverges all VF-related configuration flows that originate from a VF, making them pass through the VF->PF channel and adding sufficient logic on the PF side to support them. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 1 + drivers/net/ethernet/qlogic/qed/qed_dev.c | 10 +- drivers/net/ethernet/qlogic/qed/qed_l2.c | 456 ++++++++-------- drivers/net/ethernet/qlogic/qed/qed_l2.h | 178 +++++++ drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 2 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 704 +++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 24 + drivers/net/ethernet/qlogic/qed/qed_vf.c | 445 ++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 383 +++++++++++++- 9 files changed, 1957 insertions(+), 246 deletions(-) commit 0b55e27d563f493665693b494735574e68c3c5b9 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:15 2016 +0300 qed: IOV configure and FLR While previous patches have already added the necessary logic to probe VFs as well as enabling them in the HW, this patch adds the ability to support VF FLR & SRIOV disable. It then wraps both flows together into the first IOV callback to be provided to the protocol driver - `configure'. This would later to be used to enable and disable SRIOV in the adapter. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 17 +- drivers/net/ethernet/qlogic/qed/qed_dev_api.h | 4 +- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 11 +- drivers/net/ethernet/qlogic/qed/qed_l2.c | 7 + drivers/net/ethernet/qlogic/qed/qed_main.c | 1 + drivers/net/ethernet/qlogic/qed/qed_mcp.c | 72 +++ drivers/net/ethernet/qlogic/qed/qed_mcp.h | 12 + drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 10 + drivers/net/ethernet/qlogic/qed/qed_sp.h | 1 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 660 +++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 33 +- drivers/net/ethernet/qlogic/qed/qed_vf.c | 97 ++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 45 ++ include/linux/qed/qed_eth_if.h | 4 + include/linux/qed/qed_iov_if.h | 20 + 15 files changed, 983 insertions(+), 11 deletions(-) commit 1408cc1fa48c5450c0dc4b40cbd9718ecb09d1c9 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:14 2016 +0300 qed: Introduce VFs This adds the qed VFs for the first time - The vfs are limited functions, with a very different PCI bar structure [when compared with PFs] to better impose the related security demands associated with them. This patch includes the logic neccesary to allow VFs to successfully probe [without actually adding the ability to enable iov]. This includes diverging all the flows that would occur as part of the pci probe of the driver, preventing VF from accessing registers/memories it can't and instead utilize the VF->PF channel to query the PF for needed information. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/Makefile | 2 +- drivers/net/ethernet/qlogic/qed/qed.h | 5 + drivers/net/ethernet/qlogic/qed/qed_cxt.c | 186 +++++++++-- drivers/net/ethernet/qlogic/qed/qed_cxt.h | 3 + drivers/net/ethernet/qlogic/qed/qed_dev.c | 182 +++++++++-- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 47 ++- drivers/net/ethernet/qlogic/qed/qed_hw.c | 12 +- drivers/net/ethernet/qlogic/qed/qed_init_ops.c | 4 + drivers/net/ethernet/qlogic/qed/qed_int.c | 101 +++++- drivers/net/ethernet/qlogic/qed/qed_int.h | 16 + drivers/net/ethernet/qlogic/qed/qed_l2.c | 57 +++- drivers/net/ethernet/qlogic/qed/qed_main.c | 192 +++++++---- drivers/net/ethernet/qlogic/qed/qed_mcp.c | 83 ++++- drivers/net/ethernet/qlogic/qed/qed_mcp.h | 27 +- drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 6 + drivers/net/ethernet/qlogic/qed/qed_sp.h | 2 + drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 8 + drivers/net/ethernet/qlogic/qed/qed_spq.c | 3 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 379 +++++++++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_sriov.h | 49 +++ drivers/net/ethernet/qlogic/qed/qed_vf.c | 357 ++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 229 +++++++++++++ drivers/net/ethernet/qlogic/qede/qede_main.c | 13 +- include/linux/qed/common_hsi.h | 57 ++++ include/linux/qed/qed_if.h | 10 +- 25 files changed, 1842 insertions(+), 188 deletions(-) commit 37bff2b9c6addf6216c8d04e95be596678e8deff Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:13 2016 +0300 qed: Add VF->PF channel infrastructure Communication between VF and PF is based on a dedicated HW channel; VF will prepare a messge, and by signaling the HW the PF would get a notification of that message existance. The PF would then copy the message, process it and DMA an answer back to the VF as a response. The messages themselves are TLV-based - allowing easier backward/forward compatibility. This patch adds the infrastructure of the channel on the PF side - starting with the arrival of the notification and ending with DMAing the response back to the VF. It also adds a dummy-response as reference, as it only lays the groundwork of the communication; it doesn't really add support of any actual messages. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 6 + drivers/net/ethernet/qlogic/qed/qed_dev_api.h | 27 +- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 2 +- drivers/net/ethernet/qlogic/qed/qed_hw.c | 44 ++- drivers/net/ethernet/qlogic/qed/qed_main.c | 10 +- drivers/net/ethernet/qlogic/qed/qed_spq.c | 16 +- drivers/net/ethernet/qlogic/qed/qed_sriov.c | 385 ++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 53 ++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 52 ++++ include/linux/qed/common_hsi.h | 5 + 10 files changed, 585 insertions(+), 15 deletions(-) commit 32a47e72c9eb17e3b1bb507184e788b10d69ad4b Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Wed May 11 16:36:12 2016 +0300 qed: Add CONFIG_QED_SRIOV Add support for a new Kconfig option for qed* driver which would allow [eventually] the support in VFs. This patch adds the necessary logic in the PF to learn about the possible VFs it will have to support [Based on PCI configuration space and HW], and prepare a database with an entry per-VF as infrastructure for future interaction with said VFs. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/Kconfig | 10 + drivers/net/ethernet/qlogic/qed/Makefile | 1 + drivers/net/ethernet/qlogic/qed/qed.h | 7 + drivers/net/ethernet/qlogic/qed/qed_dev.c | 19 ++ drivers/net/ethernet/qlogic/qed/qed_hw.c | 11 + drivers/net/ethernet/qlogic/qed/qed_hw.h | 10 + drivers/net/ethernet/qlogic/qed/qed_sriov.c | 366 ++++++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sriov.h | 185 ++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_vf.h | 41 ++++ 9 files changed, 650 insertions(+) commit 7d020672615d09cf6ec42c500f34d70adf6758a9 Merge: 9530697 b4eeed5 Author: Dave Airlie <airlied@redhat.com> Date: Thu May 12 11:16:55 2016 +1000 Merge branch 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-next More amdgpu fixes for 4.7. Highlights: - enable async pageflips - UVD fixes for polaris - lots of GPUVM fixes - whitespace and code cleanups - misc bug fixes * 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux: (32 commits) drm/amd/powerplay: rewrite pp_sw_init to make code readable drm/amdgpu/dce11: fix audio offset for asics with >7 audio pins drm/amdgpu: fix and cleanup user fence handling v2 drm/amdgpu: move VM fields into job drm/amdgpu: move the context from the IBs into the job drm/amdgpu: move context switch handling into common code v2 drm/amdgpu: move preamble IB handling into common code drm/amdgpu/gfx7: fix pipeline sync amdgpu/uvd: separate context buffer from DPB drm/amdgpu: use fence_context to judge ctx switch v2 drm/amd/amdgpu: Added more named DRM info messages for debugging drm/amd/amdgpu: Add name field to amd_ip_funcs (v2) drm/amdgpu: Support DRM_MODE_PAGE_FLIP_ASYNC (v2) drm/amdgpu/dce11: don't share PLLs on Polaris drm/amdgpu: Drop unused parameter for *get_sleep_divider_id_from_clock drm/amdgpu: Simplify calculation in *get_sleep_divider_id_from_clock drm/amdgpu: Use max macro in *get_sleep_divider_id_from_clock drm/amd/powerplay: Use defined constants for minium engine clock drm/amdgpu: add missing licenses on a couple of files drm/amdgpu: fetch cu_info once at init ... commit 95306975e9dd38ba2775dd96cb29987ecc7d9360 Merge: 93f517c 057eab2 Author: Dave Airlie <airlied@redhat.com> Date: Thu May 12 11:15:18 2016 +1000 Merge tag 'drm/tegra/for-4.7-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next drm/tegra: Changes for v4.7-rc1 Two small changes, one getting rid of the bogus gamma table size and another removing Terje from the MAINTAINERS file since he no longer does any work on host1x or display. * tag 'drm/tegra/for-4.7-rc1' of git://anongit.freedesktop.org/tegra/linux: MAINTAINERS: Remove Terje Bergström as Tegra DRM maintainer drm/tegra: Don't set a gamma table size commit 93f517c4a76ffba270c42c9bf0bc32801572c077 Merge: 6d23abf 165cccc Author: Dave Airlie <airlied@redhat.com> Date: Thu May 12 11:11:03 2016 +1000 Merge branch 'drm-hisilicon-next' of github.com:xin3liang/linux into drm-next misc hisilicon cleanups. * 'drm-hisilicon-next' of github.com:xin3liang/linux: drm/hisilicon: Fix DRM_INFO printed issue drm/hisilicon: Make kirin_drm_unbind sufficient drm/hisilicon: Use drm_connector_register_all commit 6d23abf58a9afd3bc28aaf0384155b04c4b77912 Merge: 19ea5da dd65a68 Author: Dave Airlie <airlied@redhat.com> Date: Thu May 12 10:10:53 2016 +1000 Merge branch 'exynos-drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-next Summary: - expose HDMI-PHY clock to other drivers. . this patch was included in below patch series but I missed. http://www.spinics.net/lists/dri-devel/msg103097.html - some fixups about DECON5433 driver . this patch corrects vblank handling and fixes up trigger configuration. - use generic functions - gem_prime_mmap and dma_buf_mmap. - use DMA-Mapping API instead of specific one. - some code cleanups and fixeups. * 'exynos-drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: drm/exynos/decon5433: fix trigger configuration drm/exynos/dsi: use of_graph_get_endpoint_by_regs helper drm/exynos/dpi: use of_graph_get_endpoint_by_regs helper drm/exynos: Nuke dummy fb->dirty callback drm/exynos: use directly DMA mapping APIs on g2d drm/exynos/hdmi: Don't print error on deferral due to regulators drm/exynos: fix imported dma-buf to be mapped drm/exynos: support gem_prime_mmap drm/exynos: fimd: harden fimd_calc_clkdiv() drm/exynos: fix cancel page flip code drm/exynos/decon5433: do not use unnecessary software trigger drm/exynos/decon5433: handle vblank in vblank interrupt drm/exynos/hdmi: expose HDMI-PHY clock as pipeline clock commit 631ad4a3e74d998b089e75983c0c5bf893c94b62 Merge: 6a47a57 b31d510 Author: David S. Miller <davem@davemloft.net> Date: Wed May 11 20:00:54 2016 -0400 Merge tag 'nfc-next-4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/nfc-next Samuel Ortiz says: ==================== NFC 4.7 pull request This is the first NFC pull request for 4.7. With this one we mainly have: - Support for NXP's pn532 NFC chipset. The pn532 is based on the same microcontroller as the pn533, but it talks to the host through i2c instead of USB. By separating the pn533 driver into core and PHY parts, we can not add the i2c layer and support the pn532 chipset. - Support for NCI's loopback mode. This is a testing mode where each packet received by the NFCC is sent back to the DH, allowing the host to test that the controller can receive and send data. - A few ACPI related fixes for the STMicro drivers, in order to match the device tree naming scheme. - A bunch of cleanups for the st-nci and the st21nfca STMicro drivers. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 6a47a570321fdcd2b6fc9e6537b2a3650d0fd04b Merge: c1869d5 b797a68 Author: David S. Miller <davem@davemloft.net> Date: Wed May 11 19:42:39 2016 -0400 Merge branch 'mlx5-next' Saeed Mahameed says: ==================== Mellanox 100G mlx5 CQE compression Introducing ConnectX-4 CQE (Completion Queue Entry) compression feature for mlx5 etherent driver. CQE Compressing reduces PCI overhead by coalescing and compressing multiple CQEs into a single merged CQE. Successful compressing improves message rate especially for small packet traffic. CQE Compressing in details: Instead of writing full CQEs to memory, multiple almost identical CQEs are merged and compressed. Information that is shared between the CQEs is written once, regardless of the number of compressed CQEs. In addition, only the unique information (small amount of bytes compared to full CQE size) is written per CQE. CQE Compression Block: This block contains multiple compressed CQEs. CQE Compression Block contains a single copy of CQEs properties which are shared between all the compressed CQEs (called Title, see below) and multiple mini CQEs (CQEs in compressed form). Title: The Title holds information which is shared between all the compressed CQEs in the CQE Compression Block. In each Compression Block there is only a single Title regardless of the number of compressed CQEs. Mini CQE: A CQE in compressed form that holds some data needed to extract a single full CQE, for example 8 Bytes instead of 64 Bytes. The shared information between all compressed CQEs, which belong to the same CQE Compression Block called Title, is written once, and only the unique information in each compressed CQE, for example 8 bytes, is written per compressed CQE, called mini CQE. Since CQE Compression can add overhead to the software (CPU), it will be only enabled on "weak/slow" PCI slots, where it can actually help. Applied on top: c047c3b1af62 ('netfilter: conntrack: remove uninitialized shadow variable') ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b797a684b0ddeb6f78193c9b1bfae6bd824ec01a Author: Saeed Mahameed <saeedm@mellanox.com> Date: Wed May 11 00:29:16 2016 +0300 net/mlx5e: Enable CQE compression when PCI is slower than link We turn the feature ON, only for servers with PCI BW < MAX LINK BW, as it helps reducing PCI pressure on weak PCI slots, but it adds some software overhead. Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 1 + .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 19 ++++++++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 52 ++++++++++++++++++++++ 3 files changed, 72 insertions(+) commit d9d9f156f3807b07bb84c1cfb074d620383c016a Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed May 11 00:29:15 2016 +0300 net/mlx5e: Expand WQE stride when CQE compression is enabled Make the MPWQE/Striding RQ default configuration dynamic and not statically set at compile time. Now at driver load we set stride size and num strides dynamically. By default we use same values as before, but when CQE compression is enabled, we set larger stride size to benefit from CQE compression for larger packets. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 13 ++++---- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 23 ++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 39 ++++++++++++----------- 3 files changed, 46 insertions(+), 29 deletions(-) commit 7219ab34f184b5d864be38f5ada7cdff1ab5b18a Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed May 11 00:29:14 2016 +0300 net/mlx5e: CQE compression CQE compression feature is meant to save PCIe bandwidth by compressing few CQEs into smaller amount of bytes on PCIe. CQE compression can be selectively enabled per CQ. By default is disabled for now and will be enabled later on. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Eugenia Emantayev <eugenia@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 10 ++ drivers/net/ethernet/mellanox/mlx5/core/en_clock.c | 4 + drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 6 + drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 151 ++++++++++++++++++++- drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 8 ++ include/linux/mlx5/device.h | 34 +++++ 6 files changed, 211 insertions(+), 2 deletions(-) commit c1869d584a9d1e51544d747524662d5d2b8bf63f Merge: cb9b902 f8cd875 Author: David S. Miller <davem@davemloft.net> Date: Wed May 11 19:36:29 2016 -0400 Merge branch 'more-dsa-probing' Andrew Lunn says: ==================== More enabler patches for DSA probing The complete set of patches for the reworked DSA probing is too big to post as once. These subset contains some enablers which are easy to review. Eventually, the Marvell driver will instantiate its own internal MDIO bus, rather than have the framework do it, thus allows devices on the bus to be listed in the device tree. Initialize the main mutex as soon as it is created, to avoid lifetime issues with the mdio bus. A previous patch renamed all the DSA probe functions to make room for a true device probe. However the recent merging of all the Marvell switch drivers resulted in mv88e6xxx going back to the old probe name. Rename it again, so we can have a driver probe function. Add minimum support for the Marvell switch driver to probe as an MDIO device, as well as an DSA driver. Later patches will then register this device with the new DSA core framework. Move the GPIO reset code out of the DSA code. Different drivers may need different reset mechanisms, e.g. via a reset controller for memory mapped devices. Don't clutter up the core with this. Let each driver implement what it needs. master_dev is no longer needed in the switch drivers, since they have access to a device pointer from the probe function. Remove it. Let the switch parse the eeprom length from its one device tree node. This is required with the new binding when the central DSA platform device no longer exists. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f8cd8753def081b92b93209265bce68a73885ed0 Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:25 2016 +0200 dsa: mv88e6xxx: Handle eeprom-length property A switch can export an attached EEPROM using the standard ethtool API. However the switch itself cannot determine the size of the EEPROM, and multiple sizes are allowed. Thus a device tree property is supported to indicate the length of the EEPROM. Parse this property during device probe, and implement a callback function to retrieve it. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 17 +++++++++++++++++ drivers/net/dsa/mv88e6xxx.h | 3 +++ 2 files changed, 20 insertions(+) commit ff04955c2f678a2c4c3207e0184c4c389da9d1e2 Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:24 2016 +0200 dsa: Rename switch chip data to cd The dsa_switch structure contains a dsa_chip_data member called pd. However in the rest of the code, pd is used for dsa_platform_data. This is confusing. Rename it cd, which is already often used in dsa.c and slave.c for this data type. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 4 ++-- drivers/net/dsa/mv88e6xxx.c | 4 ++-- include/net/dsa.h | 4 ++-- net/dsa/dsa.c | 18 +++++++++--------- net/dsa/slave.c | 10 +++++----- 5 files changed, 20 insertions(+), 20 deletions(-) commit c33063d6a0d83a553faacf32f3cb834e63d8ecd7 Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:23 2016 +0200 dsa: Remove master_dev from switch structure The switch drivers only use the master_dev member for dev_info() messages. Now that the device is passed to the old style probe, and new style drivers are probed as true linux drivers, this is no longer needed. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 1 + include/net/dsa.h | 7 ++----- net/dsa/dsa.c | 2 +- net/dsa/slave.c | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) commit 52638f71fcff9386fe64c83a18a129b122333fdf Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:22 2016 +0200 dsa: Move gpio reset into switch driver Resetting the switch is something the driver does, not the framework. So move the parsing of this property into the driver. There are no in kernel users of this property, so moving it does not break anything. There is however a board which will make use of this property making its way into the kernel. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/devicetree/bindings/net/dsa/dsa.txt | 2 -- Documentation/devicetree/bindings/net/dsa/marvell.txt | 8 ++++++++ drivers/net/dsa/mv88e6xxx.c | 14 +++++++++++++- drivers/net/dsa/mv88e6xxx.h | 7 +++++++ include/net/dsa.h | 8 -------- net/dsa/dsa.c | 16 ---------------- 6 files changed, 28 insertions(+), 27 deletions(-) commit 14c7b3c3877075e6df22e071d4619cbdeac82ffd Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:21 2016 +0200 dsa: Add mdio device support to Marvell switches Allow Marvell switches to be mdio devices. Currently the driver just allocate the private structure and detects what device is on the bus. Later patches will make them register with the DSA framework. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> .../devicetree/bindings/net/dsa/marvell.txt | 27 +++++++ drivers/net/dsa/mv88e6xxx.c | 90 +++++++++++++++++----- 2 files changed, 99 insertions(+), 18 deletions(-) commit fcdce7d0751096bbc863d5db12726e9253abbc3c Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:20 2016 +0200 dsa: mv88e6xxx: Rename probe function to fit the normal pattern All other DSA drivers use _drv_ in there DSA probe function name, thus allowing for a true linux driver probe function to use the conventional name. Make mv88e6xxx fit this pattern. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit b681957ad439daf1ea67111463df783d3113c2da Author: Andrew Lunn <andrew@lunn.ch> Date: Tue May 10 23:27:19 2016 +0200 dsa: mv88e6xxx: Initialise the mutex as soon as it is created By initialising immediately it, we don't run the danger of using it before it is initialised. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit cb9b9020fca5fd34ab2e21fb36fc2c7a85329426 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Tue May 10 15:44:29 2016 -0400 net: dsa: mv88e6xxx: add STU capability Some switch models have a STU (per VLAN port state database). Add a new capability flag to switches info, instead of checking their family. Also if the 6165 family has an STU, it must have a VTU, so add the MV88E6XXX_FLAG_VTU to its family flags. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 14 ++------------ drivers/net/dsa/mv88e6xxx.h | 16 ++++++++++++++-- 2 files changed, 16 insertions(+), 14 deletions(-) commit 15d7d7d435cfe1faa1abf62459d6269bb734cfe7 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Tue May 10 15:44:28 2016 -0400 net: dsa: mv88e6xxx: abstract VTU/STU data access Both VTU and STU operations use the same routine to access their (common) data registers, with a different offset. Add VTU and STU specific read and write functions to the data registers to abstract the required offset. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) commit c3f1010b30f7fc611139cfb702a8685741aa6827 Merge: ca4aa97 0b922b7 Author: David S. Miller <davem@davemloft.net> Date: Wed May 11 19:31:40 2016 -0400 Merge branch 'vrf-pktinfo' David Ahern says: ==================== net: vrf: Fixup PKTINFO to return enslaved device index Applications such as OSPF and BFD need the original ingress device not the VRF device; the latter can be derived from the former. To that end move the packet intercept from an rx handler that is invoked by __netif_receive_skb_core to the ipv4 and ipv6 receive processing. IPv6 already saves the skb_iif to the control buffer in ipv6_rcv. Since the skb->dev has not been switched the cb has the enslaved device. Make the same happen for IPv4 by adding the skb_iif to inet_skb_parm and set it in ipv4 code after clearing the skb control buffer similar to IPv6. From there the pktinfo can just pull it from cb with the PKTINFO_SKB_CB cast. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0b922b7a829c06e3b0790c58cd9ca026de86096e Author: David Ahern <dsa@cumulusnetworks.com> Date: Tue May 10 11:19:51 2016 -0700 net: original ingress device index in PKTINFO Applications such as OSPF and BFD need the original ingress device not the VRF device; the latter can be derived from the former. To that end add the skb_iif to inet_skb_parm and set it in ipv4 code after clearing the skb control buffer similar to IPv6. From there the pktinfo can just pull it from cb with the PKTINFO_SKB_CB cast. The previous patch moving the skb->dev change to L3 means nothing else is needed for IPv6; it just works. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 1 + net/ipv4/ip_input.c | 1 + net/ipv4/ip_sockglue.c | 7 ++++++- 3 files changed, 8 insertions(+), 1 deletion(-) commit 74b20582ac389ee9f18a6fcc0eef244658ce8de0 Author: David Ahern <dsa@cumulusnetworks.com> Date: Tue May 10 11:19:50 2016 -0700 net: l3mdev: Add hook in ip and ipv6 Currently the VRF driver uses the rx_handler to switch the skb device to the VRF device. Switching the dev prior to the ip / ipv6 layer means the VRF driver has to duplicate IP/IPv6 processing which adds overhead and makes features such as retaining the ingress device index more complicated than necessary. This patch moves the hook to the L3 layer just after the first NF_HOOK for PRE_ROUTING. This location makes exposing the original ingress device trivial (next patch) and allows adding other NF_HOOKs to the VRF driver in the future. dev_queue_xmit_nit is exported so that the VRF driver can cycle the skb with the switched device through the packet taps to maintain current behavior (tcpdump can be used on either the vrf device or the enslaved devices). Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vrf.c | 189 ++++++++++++++++++++++------------------------ include/linux/ipv6.h | 17 ++++- include/linux/netdevice.h | 2 + include/net/l3mdev.h | 42 +++++++++++ include/net/tcp.h | 4 +- net/core/dev.c | 3 +- net/ipv4/ip_input.c | 7 ++ net/ipv6/ip6_input.c | 7 ++ 8 files changed, 170 insertions(+), 101 deletions(-) commit ca4aa976f04d14bc7da60dce0e2afc34c9f0f1d2 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue May 10 16:08:17 2016 +0200 ipv6: fix 4in6 tunnel receive path Protocol for 4in6 tunnel is IPPROTO_IPIP. This was wrongly changed by the last cleanup. CC: Tom Herbert <tom@herbertland.com> Fixes: 0d3c703a9d17 ("ipv6: Cleanup IPv6 tunnel receive path") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_tunnel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 35ff9477d880986441981010585399c1d7201fee Author: Jayachandran C <jchandra@broadcom.com> Date: Tue May 10 17:19:51 2016 +0200 PCI: Provide common functions for ECAM mapping Add config option PCI_ECAM and file drivers/pci/ecam.c to provide generic functions for accessing memory-mapped PCI config space. The API is defined in drivers/pci/ecam.h and is written to replace the API in drivers/pci/host/pci-host-common.h. The file defines a new 'struct pci_config_window' to hold the information related to a PCI config area and its mapping. This structure is expected to be used as sysdata for controllers that have ECAM based mapping. Helper functions are provided to setup the mapping, free the mapping and to implement the map_bus method in 'struct pci_ops' Signed-off-by: Jayachandran C <jchandra@broadcom.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/Kconfig | 3 + drivers/pci/Makefile | 2 + drivers/pci/ecam.c | 164 +++++++++++++++++++++++++++++++++++++++++++++++++++ drivers/pci/ecam.h | 62 +++++++++++++++++++ 4 files changed, 231 insertions(+) commit 1aa7a6e2b8105f22a5f7d6def281f776459c95ba Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 11 19:11:26 2016 +0200 intel_pstate: Clean up get_target_pstate_use_performance() The comments and the core_busy variable name in get_target_pstate_use_performance() are totally confusing, so modify them to reflect what's going on. The results of the computations should be the same as before. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) commit 8edb0a6e48d147bb2aa466c58e03c52d2b0d6ee7 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 11 19:10:42 2016 +0200 intel_pstate: Use sample.core_avg_perf in get_avg_pstate() Notice that get_avg_pstate() can use sample.core_avg_perf instead of carrying the same division again, so make it do that. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a1c9787dc38097d554f9da8372031b3d6f8c140a Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 11 19:09:12 2016 +0200 intel_pstate: Clarify average performance computation The core_pct_busy field of struct sample actually contains the average performace during the last sampling period (in percent) and not the utilization of the core as suggested by its name which is confusing. For this reason, change the name of that field to core_avg_perf and rename the function that computes its value accordingly. Also notice that storing this value as percentage requires a costly integer multiplication to be carried out in a hot path, so instead store it as an "extended fixed point" value with more fraction bits and update the code using it accordingly (it is better to change the name of the field along with its meaning in one go than to make those two changes separately, as that would likely lead to more confusion). Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 40 ++++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 16 deletions(-) commit 4578ee7e1defe534582fe3afdb747b86023207f0 Author: Chen Yu <yu.c.chen@intel.com> Date: Wed May 11 14:33:08 2016 +0800 intel_pstate: Avoid unnecessary synchronize_sched() during initialization Currently, in intel_pstate_clear_update_util_hook(), after clearing the utilization update hook, we leverage synchronize_sched() to deal with synchronization, which is a little bit time-costly because synchronize_sched() has to wait for all the CPUs to go through a grace period. Actually, the synchronize_sched() is not necessary if the utilization update hook has not been set for the given CPU yet, so make the driver check if that's the case and avoid the synchronize_sched() call then. Link: https://bugzilla.kernel.org/show_bug.cgi?id=116371 Tested-by: Tian Ye <yex.tian@intel.com> Signed-off-by: Chen Yu <yu.c.chen@intel.com> [ rjw : Rebase ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit c29af6f1a4e6f54e806fed1c40e7d338650b7791 Merge: 0bc10b9 cfe9492 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 11 22:48:20 2016 +0200 Merge branch 'pm-cpufreq-sched' into pm-cpufreq commit cfe9492fdf04d1191e7ac3a43e6df5e20c3f4164 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 14:52:01 2016 +0200 cpufreq: schedutil: Make default depend on CONFIG_SMP CPU_FREQ_GOV_SCHEDUTIL gained a dependency on SMP, so now we get a warning if it gets selected by CPU_FREQ_DEFAULT_GOV_SCHEDUTIL without SMP: warning: (CPU_FREQ_DEFAULT_GOV_SCHEDUTIL) selects CPU_FREQ_GOV_SCHEDUTIL which has unmet direct dependencies (CPU_FREQ && SMP) This adds another dependency to avoid the problem. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: bf7cdff19429 (cpufreq: schedutil: Make it depend on CONFIG_SMP) Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 14717e2031862d9aa2512b24a7df42cf68a977ec Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu May 5 11:58:35 2016 -0600 kvm: Conditionally register IRQ bypass consumer If we don't support a mechanism for bypassing IRQs, don't register as a consumer. This eliminates meaningless dev_info()s when the connect fails between producer and consumer, such as on AMD systems where kvm_x86_ops->update_pi_irte is not implemented Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/x86.c | 19 ++++++++----------- include/linux/kvm_host.h | 1 + virt/kvm/eventfd.c | 18 ++++++++++-------- 3 files changed, 19 insertions(+), 19 deletions(-) commit b52f3ed02221252d8ee2c7d756e76fad4a5e84f6 Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu May 5 11:58:29 2016 -0600 irqbypass: Disallow NULL token A NULL token is meaningless and can only lead to unintended problems. Error on registration with a NULL token, ignore de-registrations with a NULL token. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> include/linux/irqbypass.h | 4 ++-- virt/lib/irqbypass.c | 12 +++++++++++- 2 files changed, 13 insertions(+), 3 deletions(-) commit 0b1b1dfd52a67f4f09a18cb82337199bc90ad7fb Author: Greg Kurz <gkurz@linux.vnet.ibm.com> Date: Mon May 9 18:13:37 2016 +0200 kvm: introduce KVM_MAX_VCPU_ID The KVM_MAX_VCPUS define provides the maximum number of vCPUs per guest, and also the upper limit for vCPU ids. This is okay for all archs except PowerPC which can have higher ids, depending on the cpu/core/thread topology. In the worst case (single threaded guest, host with 8 threads per core), it limits the maximum number of vCPUS to KVM_MAX_VCPUS / 8. This patch separates the vCPU numbering from the total number of vCPUs, with the introduction of KVM_MAX_VCPU_ID, as the maximal valid value for vCPU ids plus one. The corresponding KVM_CAP_MAX_VCPU_ID allows userspace to validate vCPU ids before passing them to KVM_CREATE_VCPU. This patch only implements KVM_MAX_VCPU_ID with a specific value for PowerPC. Other archs continue to return KVM_MAX_VCPUS instead. Suggested-by: Radim Krcmar <rkrcmar@redhat.com> Signed-off-by: Greg Kurz <gkurz@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Documentation/virtual/kvm/api.txt | 10 ++++++++-- arch/powerpc/include/asm/kvm_host.h | 3 +++ include/linux/kvm_host.h | 4 ++++ include/uapi/linux/kvm.h | 1 + virt/kvm/kvm_main.c | 4 +++- 5 files changed, 19 insertions(+), 3 deletions(-) commit 9b9e3fc4d5a31f6050508f2404369beac4356867 Author: Greg Kurz <gkurz@linux.vnet.ibm.com> Date: Mon May 9 18:11:54 2016 +0200 KVM: remove NULL return path for vcpu ids >= KVM_MAX_VCPUS Commit c896939f7cff ("KVM: use heuristic for fast VCPU lookup by id") added a return path that prevents vcpu ids to exceed KVM_MAX_VCPUS. This is a problem for powerpc where vcpu ids can grow up to 8*KVM_MAX_VCPUS. This patch simply reverses the logic so that we only try fast path if the vcpu id can be tried as an index in kvm->vcpus[]. The slow path is not affected by the change. Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Greg Kurz <gkurz@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> include/linux/kvm_host.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit bdb4094eb57aeab6683ea9c90d8b29271bf34405 Merge: 6ac0f61 0648505 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Wed May 11 22:37:37 2016 +0200 Merge tag 'kvm-arm-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD KVM/ARM Changes for Linux v4.7 Reworks our stage 2 page table handling to have page table manipulation macros separate from those of the host systems as the underlying hardware page tables can be configured to be noticably different in layout from the stage 1 page tables used by the host. Adds 16K page size support based on the above. Adds a generic firmware probing layer for the timer and GIC so that KVM initializes using the same logic based on both ACPI and FDT. Finally adds support for hardware updating of the access flag. commit 52776a700b53969345a3cc5daed1c797d016a188 Merge: d9739a2 ee9ca14 Author: Kalle Valo <kvalo@codeaurora.org> Date: Wed May 11 23:23:51 2016 +0300 Merge ath-next from ath.git ath.git patches for 4.7. Major changes: ath6kl * add ability to set debug uart baud rate with a module parameter wil6210 * add debugfs file to configure firmware led functionality commit 5f0dfb7a9bcc8139958f59ecb9bbd7e738ae702d Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:31 2016 +0530 mpt3sas: Used "synchronize_irq()"API to synchronize timed-out IO & TMs Replaced mpt3sas_base_flush_reply_queues() with mpt3sas_base_sync_reply_irqs(),as mpt3sas_base_flush_reply_queues() skips over reply queues that are currently busy (i.e. being handled by interrupt processing in another core). If a reply queue is busy, then call to synchronize_irq()in mpt3sas_base_sync_reply_irqs()make sures the other core has finished flushing the queue and completed any calls to the mid-layer scsi_done() routine. Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_base.c | 15 +++++++-------- drivers/scsi/mpt3sas/mpt3sas_base.h | 3 ++- drivers/scsi/mpt3sas/mpt3sas_scsih.c | 4 +++- 3 files changed, 12 insertions(+), 10 deletions(-) commit 6c197093847e8cdec844df39a373bfe1f9a1ac8a Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:30 2016 +0530 mpt3sas: Set maximum transfer length per IO to 4MB for VDs Set maximum transfer length per IO on RAID volumes to 4MB by setting VD's queue's max_sector to 8192. Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_base.h | 2 ++ drivers/scsi/mpt3sas/mpt3sas_scsih.c | 8 ++++++++ 2 files changed, 10 insertions(+) commit b2500d76a0dbaa8993cd6b43941d23d31a312831 Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:29 2016 +0530 mpt3sas: Updating mpt3sas driver version to 13.100.00.00 Bump mpt3sas driver version from 12.100.00.00 to 13.100.00.00 Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_base.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 648512ccd7d42ccf761f515b7c0cb456a48c477a Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:28 2016 +0530 mpt3sas: Fix initial Reference tag field for 4K PI drives. Modified driver code to use scsi_prot_ref_tag() API instead of scsi_get_lba(), while initializing reference tag field in the CDB. Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_scsih.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a470a51cd6481373cdf2b5934b1b9f7853688de9 Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:27 2016 +0530 mpt3sas: Handle active cable exception event In-order to handle this 'MPI2_EVENT_ACTIVE_CABLE_EXCEPTION' event, driver need to follow below steps, 1. Unmask the 'MPI2_EVENT_ACTIVE_CABLE_EXCEPTION' event, so that FW can notify this event to host driver. 2. After receiving this event, add this event to AEN event queue, for notifying this event to applications. 3. Then Print below message in kernel logs if the event data's reason code is zero, "Currently an active cable with ReceptacleID <ID_Value> cannot be powered and devices connected to this active cable will not be seen. This active cable requires <PowerValue_in_mW> of power" This event is only for Intruder/Cutlass HBAs. Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_base.c | 5 +++++ drivers/scsi/mpt3sas/mpt3sas_scsih.c | 13 +++++++++++++ 2 files changed, 18 insertions(+) commit 4fe6bc97efebdc5083aa749850928fad1740a60d Author: Chaitra P B <chaitra.basappa@broadcom.com> Date: Fri May 6 14:29:26 2016 +0530 mpt3sas: Update MPI header to 2.00.42 Updated MPI version and MPI header files. ChangeList: * Added SATADeviceWaitTime to SAS IO Unit Page 4 * Added EEDPObservedValue added to SCSI IO Reply message * Added MPI2_EVENT_ACTIVE_CABLE_EXCEPTION and MPI26_EVENT_DATA_ACTIVE_CABLE_EXCEPT Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpi/mpi2.h | 7 +++++-- drivers/scsi/mpt3sas/mpi/mpi2_cnfg.h | 18 +++++++++++----- drivers/scsi/mpt3sas/mpi/mpi2_init.h | 15 +++++++++++--- drivers/scsi/mpt3sas/mpi/mpi2_ioc.h | 40 +++++++++++++++++++++++++++++++----- 4 files changed, 65 insertions(+), 15 deletions(-) commit d65c8fff867a6450c58ce31572e883148a445ddf Author: Martin K. Petersen <martin.petersen@oracle.com> Date: Mon May 9 21:39:43 2016 -0400 Revert "lpfc: Delete unnecessary checks before the function call mempool_destroy" This reverts commit 9be321819c43417432a8376428b90fe3fe3a3510 which caused a regression on hardware using the SLI3 interface. Reported-by: Dick Kennedy <dick.kennedy@broadcom.com> Cc: <stable@vger.kernel.org> # 4.6+ Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: James Bottomley <jejb@linux.vnet.ibm.com> drivers/scsi/lpfc/lpfc_mem.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit ee9ca147c59c0ee128bbf7fc079ee49401070086 Author: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Date: Mon May 9 21:57:14 2016 +0300 ath10k: Fix survey reporting with QCA4019 In QCA4019, cycle counter wraparound in same fashion as QCA988X. When the cycle counter wraparound it resets to 0x7fffffff. Set has_shifted_cc_wraparound to true for QCA4019 to enable the code path to handle cycle counter wraparound for consistent survey report. Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 1 + 1 file changed, 1 insertion(+) commit 36bd39bb0ae8544e3f5b9c1af45f39f51075611b Author: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Date: Mon May 9 21:57:14 2016 +0300 ath10k: suppress warnings when getting wmi peer_rate_code_list event In 10.4, fw sends WMI PEER_RATECODE_LIST_EVENTID after successful peer_assoc cmd. As of now this event is not of much use and not implemented. Change the debug level and messsage as appropriate to suppress "Unknown eventid: 36898". Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 1 + 1 file changed, 1 insertion(+) commit 10d599ad84a1b98450c8867ce548ea4bf0f6df1a Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Mon May 9 21:57:11 2016 +0300 wil6210: add support for device led configuration Add the ability to configure the device led to be used for notifying the AP activity (60G device supports leds 0-2). The host can also configure the blinking frequency of the led in three states. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/debugfs.c | 115 +++++++++++++++++++++++++++++ drivers/net/wireless/ath/wil6210/main.c | 3 + drivers/net/wireless/ath/wil6210/wil6210.h | 25 +++++++ drivers/net/wireless/ath/wil6210/wmi.c | 77 +++++++++++++++++++ drivers/net/wireless/ath/wil6210/wmi.h | 61 +++++++++++++++ 5 files changed, 281 insertions(+) commit d9739a26fbcaa11c026dd79bc310af96003f20d8 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 10 22:21:17 2016 +0300 atmel: potential underflow in atmel_set_freq() Smatch complains that we cap the upper bound of "fwrq->m" but not the lower bound. I don't know if it can actually happen but it's simple enough to check for negatives. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/atmel/atmel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 03ba4a1b718e3a018f38f1ee030de4cd052bb3f3 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 10 22:20:37 2016 +0300 airo: prevent potential underflow in airo_set_freq() I'm not sure if this can underflow but Smatch complains. It seems harmless to add a check for negatives. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/cisco/airo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 50d4d8feb9133abb5b8fcb22c48ec509295fdc43 Author: Wei-Ning Huang <wnhuang@chromium.org> Date: Tue May 10 14:21:23 2016 +0800 mwifiex: fixup error messages Use dev_err instead of pr_err and add newline character at the end. Signed-off-by: Wei-Ning Huang <wnhuang@chromium.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/sdio.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit cf968937d27751296920e6b82ffa89735e3a0023 Author: wang yanqing <udknight@gmail.com> Date: Sat May 7 00:33:53 2016 +0800 rtlwifi: pci: use dev_kfree_skb_irq instead of kfree_skb in rtl_pci_reset_trx_ring We can't use kfree_skb in irq disable context, because spin_lock_irqsave make sure we are always in irq disable context, use dev_kfree_skb_irq instead of kfree_skb is better than dev_kfree_skb_any. This patch fix below kernel warning: [ 7612.095528] ------------[ cut here ]------------ [ 7612.095546] WARNING: CPU: 3 PID: 4460 at kernel/softirq.c:150 __local_bh_enable_ip+0x58/0x80() [ 7612.095550] Modules linked in: rtl8723be x86_pkg_temp_thermal btcoexist rtl_pci rtlwifi rtl8723_common [ 7612.095567] CPU: 3 PID: 4460 Comm: ifconfig Tainted: G W 4.4.0+ #4 [ 7612.095570] Hardware name: LENOVO 20DFA04FCD/20DFA04FCD, BIOS J5ET48WW (1.19 ) 08/27/2015 [ 7612.095574] 00000000 00000000 da37fc70 c12ce7c5 00000000 da37fca0 c104cc59 c19d4454 [ 7612.095584] 00000003 0000116c c19d4784 00000096 c10508a8 c10508a8 00000200 c1b42400 [ 7612.095594] f29be780 da37fcb0 c104ccad 00000009 00000000 da37fcbc c10508a8 f21f08b8 [ 7612.095604] Call Trace: [ 7612.095614] [<c12ce7c5>] dump_stack+0x41/0x5c [ 7612.095620] [<c104cc59>] warn_slowpath_common+0x89/0xc0 [ 7612.095628] [<c10508a8>] ? __local_bh_enable_ip+0x58/0x80 [ 7612.095634] [<c10508a8>] ? __local_bh_enable_ip+0x58/0x80 [ 7612.095640] [<c104ccad>] warn_slowpath_null+0x1d/0x20 [ 7612.095646] [<c10508a8>] __local_bh_enable_ip+0x58/0x80 [ 7612.095653] [<c16b7d34>] destroy_conntrack+0x64/0xa0 [ 7612.095660] [<c16b300f>] nf_conntrack_destroy+0xf/0x20 [ 7612.095665] [<c1677565>] skb_release_head_state+0x55/0xa0 [ 7612.095670] [<c16775bb>] skb_release_all+0xb/0x20 [ 7612.095674] [<c167760b>] __kfree_skb+0xb/0x60 [ 7612.095679] [<c16776f0>] kfree_skb+0x30/0x70 [ 7612.095686] [<f81b869d>] ? rtl_pci_reset_trx_ring+0x22d/0x370 [rtl_pci] [ 7612.095692] [<f81b869d>] rtl_pci_reset_trx_ring+0x22d/0x370 [rtl_pci] [ 7612.095698] [<f81b87f9>] rtl_pci_start+0x19/0x190 [rtl_pci] [ 7612.095705] [<f81970e6>] rtl_op_start+0x56/0x90 [rtlwifi] [ 7612.095712] [<c17e3f16>] drv_start+0x36/0xc0 [ 7612.095717] [<c17f5ab3>] ieee80211_do_open+0x2d3/0x890 [ 7612.095725] [<c16820fe>] ? call_netdevice_notifiers_info+0x2e/0x60 [ 7612.095730] [<c17f60bd>] ieee80211_open+0x4d/0x50 [ 7612.095736] [<c16891b3>] __dev_open+0xa3/0x130 [ 7612.095742] [<c183fa53>] ? _raw_spin_unlock_bh+0x13/0x20 [ 7612.095748] [<c1689499>] __dev_change_flags+0x89/0x140 [ 7612.095753] [<c127c70d>] ? selinux_capable+0xd/0x10 [ 7612.095759] [<c1689589>] dev_change_flags+0x29/0x60 [ 7612.095765] [<c1700b93>] devinet_ioctl+0x553/0x670 [ 7612.095772] [<c12db758>] ? _copy_to_user+0x28/0x40 [ 7612.095777] [<c17018b5>] inet_ioctl+0x85/0xb0 [ 7612.095783] [<c166e647>] sock_ioctl+0x67/0x260 [ 7612.095788] [<c166e5e0>] ? sock_fasync+0x80/0x80 [ 7612.095795] [<c115c99b>] do_vfs_ioctl+0x6b/0x550 [ 7612.095800] [<c127c812>] ? selinux_file_ioctl+0x102/0x1e0 [ 7612.095807] [<c10a8914>] ? timekeeping_suspend+0x294/0x320 [ 7612.095813] [<c10a256a>] ? __hrtimer_run_queues+0x14a/0x210 [ 7612.095820] [<c1276e24>] ? security_file_ioctl+0x34/0x50 [ 7612.095827] [<c115cef0>] SyS_ioctl+0x70/0x80 [ 7612.095832] [<c1001804>] do_fast_syscall_32+0x84/0x120 [ 7612.095839] [<c183ff91>] sysenter_past_esp+0x36/0x55 [ 7612.095844] ---[ end trace 97e9c637a20e8348 ]--- Signed-off-by: Wang YanQing <udknight@gmail.com> Cc: Stable <stable@vger.kernel.org> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9e96aa70e9acd03eee61c2094b4755b80a386c47 Author: Charlie Mooney <charliemooney@chromium.org> Date: Mon May 2 08:57:17 2016 +0800 platform/chrome: chromeos_laptop - Add Elan touchpad for Wolf The upcoming Elan Wolf (Dell Chromebook 11) devices need to know to look for Elan touchpads on the i2c bus so that they will be functional. Based on the chromeos-kernel commit : https://chromium-review.googlesource.com/198283 Signed-off-by: Charlie Mooney <charliemooney@chromium.org> Signed-off-by: Benson Leung <bleung@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_laptop.c | 2 ++ 1 file changed, 2 insertions(+) commit 9bd9a90b013c647ed88ed4fa69b664b770924cf0 Author: Benson Leung <bleung@chromium.org> Date: Mon May 2 08:57:16 2016 +0800 platform/chrome: chromeos_laptop - Add elan trackpad option for C720 Add the elan trackpad to the Acer C720 (peppy) list, as it is an alternate trackpad option. It may exist at i2c address 0x15. Based on this change from the chromeos kernel : https://chromium-review.googlesource.com/186253 Signed-off-by: Benson Leung <bleung@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_laptop.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit 2521ea3e0d1b285cea371a38772d3eefa0490c71 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Apr 14 19:35:29 2016 -0700 platform/chrome: cros_ec_dev - Populate compat_ioctl compat_ioctl has to be populated for 32 bit userspace applications to work with 64 bit kernels. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Tested-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/cros_ec_dev.c | 3 +++ 1 file changed, 3 insertions(+) commit d940f3065c120af233d36933e94ebb577a695b44 Author: Clinton Sprain <clintonsprain@gmail.com> Date: Wed May 11 11:05:35 2016 -0700 platform/chrome: cros_ec_lightbar - use name instead of ID to hide lightbar attributes Lightbar attributes are hidden if the ID of the device is not 0 (the assumption being that 0 = cros_ec = might have a lightbar, 1 = cros_pd = hide); however, sometimes these devices get IDs 1 and 2 (or something else) instead of IDs 0 and 1. This prevents the lightbar attributes from appearing when they should. Proposed change is to instead check whether the name assigned to the device is CROS_EC_DEV_NAME (true for cros_ec, false for cros_pd). Signed-off-by: Clinton Sprain <clintonsprain@gmail.com> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/cros_ec_lightbar.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 5d749d0bbe811c10d9048cde6dfebc761713abfd Author: Gwendal Grignou <gwendal@chromium.org> Date: Tue Mar 8 09:13:52 2016 -0800 platform/chrome: cros_ec_dev - Fix security issue Prevent memory scribble by checking that ioctl buffer size parameters are sane. Without this check, on 32 bits system, if .insize = 0xffffffff - 20 and .outsize the amount to scribble, we would overflow, allocate a small amounts and be able to write outside of the malloc'ed area. Adding a hard limit allows argument checking of the ioctl. With the current EC, it is expected .insize and .outsize to be at around 512 bytes or less. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/cros_ec_dev.c | 4 ++++ drivers/platform/chrome/cros_ec_proto.c | 4 ++-- include/linux/mfd/cros_ec.h | 6 ++++-- 3 files changed, 10 insertions(+), 4 deletions(-) commit 492ef7829d2d09428803bffb187d5781bbc12ca5 Author: Simon Que <sque@chromium.org> Date: Tue Mar 8 11:12:46 2016 -0800 platform/chrome: Add Chrome OS keyboard backlight LEDs support This is a driver for ACPI-based keyboard backlight LEDs found on Chromebooks. The driver locates \\_SB.KBLT ACPI device and exports backlight as "chromeos::kbd_backlight" LED class device in sysfs. Signed-off-by: Simon Que <sque@chromium.org> Signed-off-by: Duncan Laurie <dlaurie@chromium.org> Tested-by: Evan McClain <aeroevan@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/Kconfig | 10 ++ drivers/platform/chrome/Makefile | 15 +-- drivers/platform/chrome/cros_kbd_led_backlight.c | 122 +++++++++++++++++++++++ 3 files changed, 140 insertions(+), 7 deletions(-) commit 48b9b6d4699e23cda45756b6a1fe5d481ba45914 Author: Geliang Tang <geliangtang@163.com> Date: Sun Dec 27 21:15:45 2015 +0800 platform/chrome: use to_platform_device() Use to_platform_device() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/cros_ec_lightbar.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit f929efb06578d2f9afd869911a8b4cc21b2e6e73 Author: Olof Johansson <olofj@chromium.org> Date: Tue Feb 16 08:25:16 2016 +0100 platform/chrome: pstore: Move to larger record size. Accidentally specified a smaller record size, bring it back to the same size as we had when we used the config file. Signed-off-by: Olof Johansson <olofj@chromium.org> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Reviewed-by: Sameer Nanda <snanda@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_pstore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 59a356d2f1e6e2fbb700c9a9cda1658f5934c7d2 Author: Aaron Durbin <adurbin@chromium.org> Date: Tue Feb 16 08:25:15 2016 +0100 platform/chrome: pstore: probe for ramoops buffer using acpi In order to handle the firmware placing the ramoops buffer in a different location than the kernel is configured to look probe for an ACPI device specified by GOOG9999 acpi id. If no device is found or the first memory resource is not defined properly fall back to the configured base and length. Signed-off-by: Aaron Durbin <adurbin@chromium.org> Signed-off-by: Ben Zhang <benzh@chromium.org> Signed-off-by: Filipe Brandenburger <filbranden@chromium.org> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Reviewed-by: Olof Johansson <olofj@chromium.org> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_pstore.c | 53 ++++++++++++++++++++++++++++++- 1 file changed, 52 insertions(+), 1 deletion(-) commit bff3c624dc7261a084a4d25a0b09c3fb0fec872a Author: Gene Chen <gene.chen@intel.com> Date: Tue Feb 16 08:25:14 2016 +0100 platform/chrome: chromeos_laptop: Add Leon Touch Add support for Leon touch devices, which is the same as slippy/falco/peppy/wolf on the same buses using the LynxPoint-LP I2C via the i2c-designware-pci driver. Based on the following patch: https://chromium-review.googlesource.com/#/c/168351/ Signed-off-by: Gene Chen <gene.chen@intel.com> Reviewed-by: Benson Leung <bleung@chromium.org> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: Olof Johansson <olof@lixom.net> drivers/platform/chrome/chromeos_laptop.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 976aff5fc94b0a505ccd85391f0e82c3d2d031e9 Author: wang yanqing <udknight@gmail.com> Date: Thu May 5 23:08:22 2016 +0800 rtlwifi: Remove double check for cnt_after_linked rtl_lps_enter does two successive check for cnt_after_linked to make sure some time has elapsed after linked. The second check isn't necessary, because if cnt_after_linked is bigger than 5, it is bigger than 2 of course! This patch remove the second check code. Signed-off-by: Wang YanQing <udknight@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/ps.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 496aec577b5183716ed9d8bcc853ad9003485fe8 Author: Christian Daudt <csd@broadcom.com> Date: Wed May 4 17:55:20 2016 -0700 brcmfmac: Add 4356 sdio support This adds support for the 4356-sdio wireless chip. Signed-off-by: Christian Daudt <csd@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c | 1 + drivers/net/wireless/broadcom/brcm80211/brcmfmac/chip.c | 1 + drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 4 +++- include/linux/mmc/sdio_ids.h | 1 + 4 files changed, 6 insertions(+), 1 deletion(-) commit 2f8514b8b03643a598706bf88214b10153324d11 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:16:39 2016 +0300 rtlwifi: rtl818x: silence uninitialized variable warning What about if "rtlphy->pwrgroup_cnt" is 2? In that case we would use an uninitialized "chnlgroup" variable and probably crash. Maybe that can't happen for some reason which is not obvious but in that case this patch is harmless. Setting it to zero seems like a standard default in the surrounding code so it's probably fine here as well. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8192se/rf.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 30cfe9f61c2e78b55b33c780bc0a57f9adb00e62 Author: Lukas Wunner <lukas@wunner.de> Date: Tue May 3 21:44:40 2016 +0200 mwifiex: Drop unnecessary include pcieport_if.h This header file is only needed for drivers binding to a PCI bridge device allocated by drivers/pci/pcie/portdrv_core.c. The mwifiex driver doesn't do that nor use any symbols defined in pcieport_if.h. Cc: Amitkumar Karwar <akarwar@marvell.com> Cc: Nishant Sarmukadam <nishants@marvell.com> Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.h | 1 - 1 file changed, 1 deletion(-) commit 873ffe154ae074c46ed2d72dbd9a2a99f06f55b4 Author: wang yanqing <udknight@gmail.com> Date: Tue May 3 00:38:36 2016 +0800 rtlwifi: Fix logic error in enter/exit power-save mode In commit a269913c52ad ("rtlwifi: Rework rtl_lps_leave() and rtl_lps_enter() to use work queue"), the tests for enter/exit power-save mode were inverted. With this change applied, the wifi connection becomes much more stable. Fixes: a269913c52ad ("rtlwifi: Rework rtl_lps_leave() and rtl_lps_enter() to use work queue") Signed-off-by: Wang YanQing <udknight@gmail.com> CC: Stable <stable@vger.kernel.org> [3.10+] Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/base.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 756ee1729b2feb3a45767da29e338f70f2086ba3 Author: Lawrence Brakmo <brakmo@fb.com> Date: Wed May 11 10:02:13 2016 -0700 tcp: replace cnt & rtt with struct in pkts_acked() Replace 2 arguments (cnt and rtt) in the congestion control modules' pkts_acked() function with a struct. This will allow adding more information without having to modify existing congestion control modules (tcp_nv in particular needs bytes in flight when packet was sent). As proposed by Neal Cardwell in his comments to the tcp_nv patch. Signed-off-by: Lawrence Brakmo <brakmo@fb.com> Acked-by: Yuchung Cheng <ycheng@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 7 ++++++- net/ipv4/tcp_bic.c | 6 +++--- net/ipv4/tcp_cdg.c | 14 +++++++------- net/ipv4/tcp_cubic.c | 6 +++--- net/ipv4/tcp_htcp.c | 10 +++++----- net/ipv4/tcp_illinois.c | 21 +++++++++++---------- net/ipv4/tcp_input.c | 8 ++++++-- net/ipv4/tcp_lp.c | 6 +++--- net/ipv4/tcp_vegas.c | 6 +++--- net/ipv4/tcp_vegas.h | 2 +- net/ipv4/tcp_veno.c | 7 ++++--- net/ipv4/tcp_westwood.c | 7 ++++--- net/ipv4/tcp_yeah.c | 7 ++++--- 13 files changed, 60 insertions(+), 47 deletions(-) commit 1bfcfdcca142f6468c665016b2b58c3012196af0 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 21:57:44 2016 +0200 rtlwifi: rtl818x: constify rtl_intf_ops structures The rtl_intf_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/pci.c | 2 +- drivers/net/wireless/realtek/rtlwifi/pci.h | 2 +- drivers/net/wireless/realtek/rtlwifi/usb.c | 2 +- drivers/net/wireless/realtek/rtlwifi/wifi.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit ff38e0c70adce96de0be0bf470cbb9e283ba6965 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Wed May 11 07:35:09 2016 +0900 ALSA: firewire-lib: drop skip argument from helper functions to queue a packet On most of audio and music units on IEEE 1394 bus which ALSA firewire stack supports (or plans to support), CIP with two quadlets header is used. Thus, there's no cases to queue packets with blank payload. If such packets are going to be queued, it means that they're for skips of the cycle. This commit simplifies helper functions to queue a packet. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Acked-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit a9c4284bf5a95c4788e7fbf3c46b14dcbfda3a6d Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Wed May 11 07:33:27 2016 +0900 ALSA: firewire-lib: add context information to tracepoints In current implementation, packet processing is done in both of software IRQ contexts of IR/IT contexts and process contexts. This is usual interrupt handling of IR/IT context for 1394 OHCI. (in hardware IRQ context) irq_handler() (drivers/firewire/ohci.c) ->tasklet_schedule() (in software IRQ context) handle_it_packet() or handle_ir_packet_per_buffer() (drivers/firewire/ohci.c) ->flush_iso_completions() ->struct fw_iso_context.callback.sc() = out_stream_callback() or in_stream_callback() However, we have another chance for packet processing. It's done in PCM frame handling via ALSA PCM interfaces. (in process context) ioctl(i.e. SNDRV_PCM_IOCTL_HWSYNC) ->snd_pcm_hwsync() (sound/core/pcm_native.c) ->snd_pcm_update_hw_ptr() (sound/core/pcm_lib.c) ->snd_pcm_update_hw_ptr0() ->struct snd_pcm_ops.pointer() = amdtp_stream_pcm_pointer() ->fw_iso_context_flush_completions() (drivers/firewire/core-iso.c) ->struct fw_card_driver.flush_iso_completions() = ohci_flush_iso_completions() (drivers/firewire/ohci.c) ->flush_iso_completions() ->struct fw_iso_context.callback.sc() = out_stream_callback() or in_stream_callback() This design is for a better granularity of PCM pointer. When ioctl(2) is executed with some commands for ALSA PCM interface, queued packets are handled at first. Then, the latest number of handled PCM frames is reported. The number can represent PCM frames transferred in most near isochronous cycle. Current tracepoints include no information to distinguish running contexts. When tracing the interval of software IRQ context, this is not good. This commit adds more information for current context. Additionally, the index of packet processed in one context is added in a case that packet processing is executed in continuous context of the same kind, As a result, the output includes 11 fields with additional two fields to commit 0c95c1d6197f ("ALSA: firewire-lib: add tracepoints to dump a part of isochronous packet data"): 17131.9186: out_packet: 07 7494 ffc0 ffc1 00 000700c0 9001a496 058 45 1 13 17131.9186: out_packet: 07 7495 ffc0 ffc1 00 000700c8 9001ba00 058 46 1 14 17131.9186: out_packet: 07 7496 ffc0 ffc1 00 000700d0 9001ffff 002 47 1 15 17131.9189: out_packet: 07 7497 ffc0 ffc1 00 000700d0 9001d36a 058 00 0 00 17131.9189: out_packet: 07 7498 ffc0 ffc1 00 000700d8 9001e8d4 058 01 0 01 17131.9189: out_packet: 07 7499 ffc0 ffc1 00 000700e0 9001023e 058 02 0 00 17131.9206: in_packet: 07 7447 ffc1 ffc0 01 3f070072 9001783d 058 32 1 00 17131.9206: in_packet: 07 7448 ffc1 ffc0 01 3f070072 90ffffff 002 33 1 01 17131.9206: in_packet: 07 7449 ffc1 ffc0 01 3f07007a 900191a8 058 34 1 02 (Here, some common fields are omitted so that a line is within 80 characters.) The legend is: - The second of cycle scheduled for the packet - The count of cycle scheduled for the packet - The ID of node as source (hex) - The ID of node as destination (hex) - The value of isochronous channel - The first quadlet of CIP header (hex) - The second quadlet of CIP header (hex) - The number of included quadlets - The index of packet in a buffer maintained by this module - 0 in process context, 1 in IRQ context - The index of packet processed in the context Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream-trace.h | 28 ++++++++++++++++++++-------- sound/firewire/amdtp-stream.c | 14 ++++++++------ 2 files changed, 28 insertions(+), 14 deletions(-) commit 1dba9db0eaa64d362d9d9afb5eeaececdaef948d Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu May 12 02:17:39 2016 +0900 ALSA: firewire-lib: permit to flush queued packets only in process context for better PCM period granularity These three commits were merged to improve PCM pointer granularity. commit 76fb87894828 ("ALSA: firewire-lib: taskletize the snd_pcm_period_elapsed() call") commit e9148dddc3c7 ("ALSA: firewire-lib: flush completed packets when reading PCM position") commit 92b862c7d685 ("ALSA: firewire-lib: optimize packet flushing") The point of them is to handle queued packets not only in software IRQ context of IR/IT contexts, but also in process context. As a result of handling packets, period tasklet is scheduled when acrossing PCM period boundary. This is to prevent recursive call of 'struct snd_pcm_ops.pointer()' in the same context. When the pointer callback is executed in the process context, it's better to avoid the second callback in the software IRQ context. The software IRQ context runs immediately after scheduled in the process context because few packets are queued yet. For the aim, 'pointer_flush' is used, however it causes a race condition between the process context and software IRQ context of IR/IT contexts. Practically, this race is not so critical because it influences process context to skip flushing queued packet and to get worse granularity of PCM pointer. The race condition is quite rare but it should be improved for stable service. The similar effect can be achieved by using 'in_interrupt()' macro. This commit obsoletes 'pointer_flush' with it. Acked-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 23 +++++++++++++++++------ sound/firewire/amdtp-stream.h | 1 - 2 files changed, 17 insertions(+), 7 deletions(-) commit 6fe813e3d5618a1fdc77497f8d74938e975b63fa Author: Guy Mishol <guym@ti.com> Date: Thu Apr 14 11:58:17 2016 +0300 wlcore/wl12xx: Fix fw logger over sdio The commit fb724ed5c617 ("wlcore: Fix regression in wlcore_set_partition()") fixed wl12xx functionality. However, it reverted the support in fw logger over sdio in wl18xx. This patch reverts the changes made and also fixes the original functionality issue introduced in wl12xx. Fixes: fb724ed5c617 ("wlcore: Fix regression in wlcore_set_partition()") Signed-off-by: Guy Mishol <guym@ti.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ti/wl12xx/main.c | 4 ++-- drivers/net/wireless/ti/wlcore/io.c | 17 ++++++++++++++--- drivers/net/wireless/ti/wlcore/io.h | 3 ++- 3 files changed, 18 insertions(+), 6 deletions(-) commit 2befc4e003a6093db8dce34c7dc9dee8426c973b Merge: 251a960 af5e964 Author: Kalle Valo <kvalo@codeaurora.org> Date: Wed May 11 20:54:07 2016 +0300 Merge tag 'iwlwifi-next-for-kalle-2016-05-10' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next * work for RX multiqueue continues (Sara); * dynamic queue allocation work continues (Liad); * add Luca as maintainer; * a bunch of fixes and improvements all over; commit f4833c4fd4d76ddee9e647814a64251801844db7 Author: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com> Date: Thu Apr 21 10:40:18 2016 -0400 drm/amdgpu: Encapsulate some VM table update parameters (v2) Bundle some VM table parameters into amdgpu_vm_update_params structure, so that number of function parameters can be reduced. Only structural change, no logic change. v2: agd: squash in fix from Harish Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 111 ++++++++++++++++++--------------- 1 file changed, 62 insertions(+), 49 deletions(-) commit f84e63f2ffed8a12ba58a154dc17a5ed6d31d61d Author: Marek Olšák <marek.olsak@amd.com> Date: Thu Apr 28 14:32:44 2016 +0200 drm/amdgpu: fix TC cache flushing TC_WB_ACTION must be set according to the docs Signed-off-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) commit b4eeed590deeff13a53db641129f0301d70248f3 Author: Huang Rui <ray.huang@amd.com> Date: Mon May 9 17:29:41 2016 +0800 drm/amd/powerplay: rewrite pp_sw_init to make code readable Actually, pp_sw_init executes pptable_init and backend_init orderly if they are initialized successfully. So rewrite it to make code more readable. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 67b1fcc9ac3f05660809e14cf76a046fc1cc7e41 Author: Alex Deucher <alexander.deucher@amd.com> Date: Tue May 10 09:29:56 2016 -0400 drm/amdgpu/dce11: fix audio offset for asics with >7 audio pins Missing offset in the audio offset array. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 1 + drivers/gpu/drm/amd/amdgpu/vid.h | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit 758ac17f963f3497aae4e767d3a9eb68fea71f71 Author: Christian König <christian.koenig@amd.com> Date: Fri May 6 22:14:00 2016 +0200 drm/amdgpu: fix and cleanup user fence handling v2 We leaked the BO in the error pass, additional to that we only have one user fence for all IBs in a job. v2: remove white space changes Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 19 +++++------- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 55 +++++++++++++++------------------ drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 9 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 2 +- 4 files changed, 38 insertions(+), 47 deletions(-) commit d88bf583bd06eecb31f82871c90ef6a5a09b5766 Author: Christian König <christian.koenig@amd.com> Date: Fri May 6 17:50:03 2016 +0200 drm/amdgpu: move VM fields into job They are the same for all IBs. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 15 +++++++------- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 36 +++++++++++++++------------------ drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 19 +++++++++-------- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 12 ++--------- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 3 ++- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.h | 3 ++- drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 5 +++-- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 10 +++++---- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 10 +++++---- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 5 +++-- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 5 +++-- drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 3 ++- drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 3 ++- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 3 ++- 14 files changed, 66 insertions(+), 66 deletions(-) commit 92f250989b7098f4b52d50183a7b2fc4e010731b Author: Christian König <christian.koenig@amd.com> Date: Fri May 6 15:57:42 2016 +0200 drm/amdgpu: move the context from the IBs into the job We only have one context for all IBs. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 10 +++++----- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 22 +++++++++++++++------- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 7 +++---- 4 files changed, 24 insertions(+), 17 deletions(-) commit f153d2867bf74f84d47f67c377a8e3a34865e562 Author: Christian König <christian.koenig@amd.com> Date: Fri May 6 15:31:19 2016 +0200 drm/amdgpu: move context switch handling into common code v2 It was a source of bugs to repeat that in each IP version. v2: rename parameter Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 16 +++++++--------- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.h | 2 +- drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 9 ++++----- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 9 ++++----- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 +- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 2 +- 12 files changed, 25 insertions(+), 29 deletions(-) commit 9f8fb5a2b339ba83493991ca8f1173a939a696d3 Author: Christian König <christian.koenig@amd.com> Date: Fri May 6 14:52:57 2016 +0200 drm/amdgpu: move preamble IB handling into common code This fixes the handling which was completely broken when you ad more than one preamble IB. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 8 +++++++- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 ---- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 ---- 3 files changed, 7 insertions(+), 9 deletions(-) commit 914f9e18c859d9413058c3632aba54d348a6527e Author: Chunming Zhou <David1.Zhou@amd.com> Date: Mon May 9 17:29:39 2016 +0800 drm/amdgpu/gfx7: fix pipeline sync Need to wait on the fence as well. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) commit 8e008dd70e0cf5b0fd7a5a29e00f613370e5ca74 Author: Sonny Jiang <sonny.jiang@amd.com> Date: Wed May 11 13:29:48 2016 -0400 amdgpu/uvd: separate context buffer from DPB Updated to handle latest UVD ucode. Signed-off-by: Sonny Jiang <sonny.jiang@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 62 +++++++++++++++++++++++++++++++-- 1 file changed, 59 insertions(+), 3 deletions(-) commit 3208a1ccb23018c650ff9e08c4bd1c8b01f6d8f1 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue May 10 20:59:58 2016 +0200 spi: dw-pci: Spelling s/paltforms/platforms/g Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-dw-pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ab47036d8f7227361cad7894adee8e66ab6f95b2 Author: Chao Yu <yuchao0@huawei.com> Date: Wed May 11 19:48:44 2016 +0800 f2fs: fix deadlock when flush inline data Below backtrace info was reported by Yunlei He: Call Trace: [<ffffffff817a9395>] schedule+0x35/0x80 [<ffffffff817abb7d>] rwsem_down_read_failed+0xed/0x130 [<ffffffff813c12a8>] call_rwsem_down_read_failed+0x18/0x [<ffffffff817ab1d0>] down_read+0x20/0x30 [<ffffffffa02a1a12>] f2fs_evict_inode+0x242/0x3a0 [f2fs] [<ffffffff81217057>] evict+0xc7/0x1a0 [<ffffffff81217cd6>] iput+0x196/0x200 [<ffffffff812134f9>] __dentry_kill+0x179/0x1e0 [<ffffffff812136f9>] dput+0x199/0x1f0 [<ffffffff811fe77b>] __fput+0x18b/0x220 [<ffffffff811fe84e>] ____fput+0xe/0x10 [<ffffffff81097427>] task_work_run+0x77/0x90 [<ffffffff81074d62>] exit_to_usermode_loop+0x73/0xa2 [<ffffffff81003b7a>] do_syscall_64+0xfa/0x110 [<ffffffff817acf65>] entry_SYSCALL64_slow_path+0x25/0x25 Call Trace: [<ffffffff817a9395>] schedule+0x35/0x80 [<ffffffff81216dc3>] __wait_on_freeing_inode+0xa3/0xd0 [<ffffffff810bc300>] ? autoremove_wake_function+0x40/0x4 [<ffffffff8121771d>] find_inode_fast+0x7d/0xb0 [<ffffffff8121794a>] ilookup+0x6a/0xd0 [<ffffffffa02bc740>] sync_node_pages+0x210/0x650 [f2fs] [<ffffffff8122e690>] ? do_fsync+0x70/0x70 [<ffffffffa02b085e>] block_operations+0x9e/0xf0 [f2fs] [<ffffffff8137b795>] ? bio_endio+0x55/0x60 [<ffffffffa02b0942>] write_checkpoint+0x92/0xba0 [f2fs] [<ffffffff8117da57>] ? mempool_free_slab+0x17/0x20 [<ffffffff8117de8b>] ? mempool_free+0x2b/0x80 [<ffffffff8122e690>] ? do_fsync+0x70/0x70 [<ffffffffa02a53e3>] f2fs_sync_fs+0x63/0xd0 [f2fs] [<ffffffff8129630f>] ? ext4_sync_fs+0xbf/0x190 [<ffffffff8122e6b0>] sync_fs_one_sb+0x20/0x30 [<ffffffff812002e9>] iterate_supers+0xb9/0x110 [<ffffffff8122e7b5>] sys_sync+0x55/0x90 [<ffffffff81003ae9>] do_syscall_64+0x69/0x110 [<ffffffff817acf65>] entry_SYSCALL64_slow_path+0x25/0x25 With following excuting serials, we will set inline_node in inode page after inode was unlinked, result in a deadloop described as below: 1. open file 2. write file 3. unlink file 4. write file 5. close file Thread A Thread B - dput - iput_final - inode->i_state |= I_FREEING - evict - f2fs_evict_inode - f2fs_sync_fs - write_checkpoint - block_operations - f2fs_lock_all (down_write(cp_rwsem)) - f2fs_lock_op (down_read(cp_rwsem)) - sync_node_pages - ilookup - find_inode_fast - __wait_on_freeing_inode (wait on I_FREEING clear) Here, we change to set inline_node flag only for linked inode for fixing. Reported-by: Yunlei He <heyunlei@huawei.com> Signed-off-by: Chao Yu <yuchao0@huawei.com> Tested-by: Jaegeuk Kim <jaegeuk@kernel.org> Cc: stable@vger.kernel.org # v4.6 Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 3b9b10f9ce61b574c63d71ff3eeec9cf5dbe763f Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed May 11 09:13:13 2016 -0700 f2fs: avoid f2fs_bug_on during recovery We don't need to use f2fs_bug_on() to treat with any error case when allocating a block during recovery. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/recovery.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 652be55162dcf3eb4440a4f7536ffedbe0352dcf Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue May 10 19:13:50 2016 -0700 f2fs: show # of orphan inodes This adds debug information for # of orphan inodes. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/debug.c | 5 ++++- fs/f2fs/f2fs.h | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) commit 6e9619499f53b22ead972e476c0e8341c997d929 Author: Chao Yu <yuchao0@huawei.com> Date: Mon May 9 19:56:31 2016 +0800 f2fs: support in batch fzero in dnode page This patch tries to speedup fzero_range by making space preallocation and address removal of blocks in one dnode page as in batch operation. In virtual machine, with zram driver: dd if=/dev/zero of=/mnt/f2fs/file bs=1M count=4096 time xfs_io -f /mnt/f2fs/file -c "fzero 0 4096M" Before: real 0m3.276s user 0m0.008s sys 0m3.260s After: real 0m1.568s user 0m0.000s sys 0m1.564s Signed-off-by: Chao Yu <yuchao0@huawei.com> [Jaegeuk Kim: consider ENOSPC case] Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 72 +++++++++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 56 insertions(+), 16 deletions(-) commit 46008c6d42328710f9beaf5c2b47dc92b1cc1a75 Author: Chao Yu <yuchao0@huawei.com> Date: Mon May 9 19:56:30 2016 +0800 f2fs: support in batch multi blocks preallocation This patch introduces reserve_new_blocks to make preallocation of multi blocks as in batch operation, so it can avoid lots of redundant operation, result in better performance. In virtual machine, with rotational device: time fallocate -l 32G /mnt/f2fs/file Before: real 0m4.584s user 0m0.000s sys 0m4.580s After: real 0m0.292s user 0m0.000s sys 0m0.272s In x86, with SSD: time fallocate -l 500G $MNT/testfile Before : 24.758 s After : 1.604 s Signed-off-by: Chao Yu <yuchao0@huawei.com> [Jaegeuk Kim: fix bugs and add performance numbers measured in x86.] Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 132 +++++++++++++++++++++++++++++++------------- fs/f2fs/f2fs.h | 20 ++++--- include/trace/events/f2fs.h | 14 +++-- 3 files changed, 117 insertions(+), 49 deletions(-) commit 0fac558b96584799876498248020dc49a98bd131 Author: Chao Yu <yuchao0@huawei.com> Date: Mon May 9 19:56:33 2016 +0800 f2fs: make atomic/volatile operation exclusive atomic/volatile ioctl interfaces are exposed to user like other file operation interface, it needs to make them getting exclusion against to each other to avoid potential conflict among these operations in concurrent scenario. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 7fb17fe44b70c854d380686d8b7e63217f9f1dcf Author: Chao Yu <yuchao0@huawei.com> Date: Mon May 9 19:56:32 2016 +0800 f2fs: use mnt_{want,drop}_write_file in ioctl In interfaces of ioctl, mnt_{want,drop}_write_file should be used for: - get exclusion against file system freezing which may used by lvm snapshot. - do telling filesystem that a write is about to be performed on it, and make sure that the writes are permitted. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 117 ++++++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 87 insertions(+), 30 deletions(-) commit 9ecb549867d7f642f0379f574f0e52870009a8bf Author: Noralf Trønnes <noralf@tronnes.org> Date: Wed May 11 18:09:21 2016 +0200 drm/atomic: Add drm_atomic_helper_best_encoder() Add (struct drm_connector_helper_funcs *)->best_encoder callback helper for connectors that support exactly 1 encoder, statically determined at driver init time. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462982962-10530-6-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_atomic_helper.c | 17 +++++++++++++++++ include/drm/drm_atomic_helper.h | 2 ++ 2 files changed, 19 insertions(+) commit 2827635e39a35f7263fc290c0a39ea3d1dbe35fa Author: Noralf Trønnes <noralf@tronnes.org> Date: Wed May 11 18:09:20 2016 +0200 drm/atomic: Don't skip drm_bridge_*() calls if !drm_encoder_helper_funcs Don't skip drm_bridge_*() calls if encoder->helper_private is NULL. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462982962-10530-5-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_atomic_helper.c | 39 ++++++++++++++++--------------------- 1 file changed, 17 insertions(+), 22 deletions(-) commit 994aae32b13e373dcbe001af33d5b01379483463 Author: Keerthy <j-keerthy@ti.com> Date: Tue May 10 09:34:39 2016 +0530 regulator: lp873x: Add support for lp873x PMIC regulators The regulators set consists of 2 BUCKs and 2 LDOs. The output voltages are configurable and are meant to supply power to the main processor and other components. The ramp delay is configurable for both BUCKs. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/Kconfig | 9 ++ drivers/regulator/Makefile | 1 + drivers/regulator/lp873x-regulator.c | 241 +++++++++++++++++++++++++++++++++++ 3 files changed, 251 insertions(+) commit 02da16d0fbe2cde3d7befb8a907c167c4a79a681 Author: Noralf Trønnes <noralf@tronnes.org> Date: Wed May 11 18:09:18 2016 +0200 drm/fb-cma-helper: Hook up to DocBook and fix some docs Hook up fb_cma_helper to DocBook. Remove mention of CONFIG_FB_DEFERRED_IO in the docs, which was forgotten in the latest version of the deferred_io patch. Use & when referencing drm_mode_config_funcs in docs. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462982962-10530-3-git-send-email-noralf@tronnes.org Documentation/DocBook/gpu.tmpl | 5 +++++ drivers/gpu/drm/drm_fb_cma_helper.c | 8 +++----- 2 files changed, 8 insertions(+), 5 deletions(-) commit 2dad551cfb72f85c4f08b0c06e777f23a4df2f33 Author: Noralf Trønnes <noralf@tronnes.org> Date: Wed May 11 18:09:17 2016 +0200 drm/fb-helper: Remove mention of CONFIG_FB_DEFERRED_IO in docs This was forgotten to fixup in the latest version of the deferred_io patch which made FB_DEFERRED_IO mandatory. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462982962-10530-2-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_fb_helper.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit aa3b73f67bda66637f17c3d847a8a36d3649f3f8 Author: Christian König <christian.koenig@amd.com> Date: Tue May 3 15:17:40 2016 +0200 drm/amdgpu: use fence_context to judge ctx switch v2 Use of the ctx pointer is not safe, because they are likely already be assigned to another ctx when doing comparing. v2: recreate from scratch, avoid all unnecessary changes. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Monk.Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit 822b2cef4d9ffe680b880ec39734ad8a1d178b02 Author: Tom St Denis <tom.stdenis@amd.com> Date: Thu May 5 10:23:40 2016 -0400 drm/amd/amdgpu: Added more named DRM info messages for debugging Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 88a907d67c03e80a71c49681bbccf3bfebe74ab4 Author: Tom St Denis <tom.stdenis@amd.com> Date: Wed May 4 14:28:35 2016 -0400 drm/amd/amdgpu: Add name field to amd_ip_funcs (v2) Add name that we can print out in kernel messages to aid in debugging. v2: drop DAL changes for upstream Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_acp.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 1 + drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/cik.c | 1 + drivers/gpu/drm/amd/amdgpu/cik_ih.c | 1 + drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 1 + drivers/gpu/drm/amd/amdgpu/cz_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/cz_ih.c | 1 + drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 1 + drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 1 + drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 1 + drivers/gpu/drm/amd/amdgpu/fiji_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 1 + drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 + drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c | 1 + drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 1 + drivers/gpu/drm/amd/amdgpu/iceland_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/iceland_ih.c | 1 + drivers/gpu/drm/amd/amdgpu/kv_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 1 + drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 1 + drivers/gpu/drm/amd/amdgpu/tonga_dpm.c | 1 + drivers/gpu/drm/amd/amdgpu/tonga_ih.c | 1 + drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 1 + drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 1 + drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 1 + drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 1 + drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 1 + drivers/gpu/drm/amd/amdgpu/vi.c | 1 + drivers/gpu/drm/amd/include/amd_shared.h | 2 ++ drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 1 + 32 files changed, 33 insertions(+), 1 deletion(-) commit cb9e59d7e999c68b79f23d6016b08fc5d0bb8a8d Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu May 5 16:03:57 2016 -0400 drm/amdgpu: Support DRM_MODE_PAGE_FLIP_ASYNC (v2) When this flag is set, we program the hardware to execute the flip during horizontal blank (i.e. for the next scanline) instead of during vertical blank (i.e. for the next frame). Ported from radeon commit: drm/radeon: Support DRM_MODE_PAGE_FLIP_ASYNC v2: drop DAL change for upstream Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 3 ++- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 3 ++- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 2 +- drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 25 +++++++++++++++++-------- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 26 ++++++++++++++++++-------- drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 20 ++++++++++++-------- 6 files changed, 52 insertions(+), 27 deletions(-) commit a71dd897599c94d38eb1c4d6c8d9f8e3275e82ce Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu May 5 11:17:22 2016 -0400 drm/amdgpu/dce11: don't share PLLs on Polaris They are part of the phy so you can't share them. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 4 ---- 1 file changed, 4 deletions(-) commit 438498a862723b36369858611321478d8b444ee9 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Thu May 5 09:07:48 2016 +0200 drm/amdgpu: Drop unused parameter for *get_sleep_divider_id_from_clock Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 6 ++---- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 6 +++--- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 6 +++--- 3 files changed, 8 insertions(+), 10 deletions(-) commit 354ef928a0e67166249c0136cdba21fdfef31702 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Thu May 5 09:07:47 2016 +0200 drm/amdgpu: Simplify calculation in *get_sleep_divider_id_from_clock a / (1 << b) is equivalent to a >> b for unsigned values Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 2 +- drivers/gpu/drm/amd/amdgpu/kv_dpm.c | 7 +------ drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 2 +- 5 files changed, 5 insertions(+), 10 deletions(-) commit 9887e425f91b063d68ee1fbec76dea15d6a82085 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Thu May 5 09:07:46 2016 +0200 drm/amdgpu: Use max macro in *get_sleep_divider_id_from_clock Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 3 +-- drivers/gpu/drm/amd/amdgpu/kv_dpm.c | 3 +-- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 3 +-- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 3 +-- 4 files changed, 4 insertions(+), 8 deletions(-) commit 859b8b6a27eb6f22d082282f5fd234d6323f849d Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Thu May 5 09:07:45 2016 +0200 drm/amd/powerplay: Use defined constants for minium engine clock Replacing magic numbers in calculation of sleep divider id for fiji and polaris. Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 3 ++- drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) commit f9fbac64ebb0306d2b88479325aaa4e61f359cb6 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu May 5 09:04:38 2016 -0400 drm/amdgpu: add missing licenses on a couple of files Noticed by n1s on IRC. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/pp_acpi.c | 23 ++++++++++++++++++++++ .../gpu/drm/amd/powerplay/inc/smu_ucode_xfer_cz.h | 22 +++++++++++++++++++++ 2 files changed, 45 insertions(+) commit 7dae69a2905c34a97678645c8e4c95095f5390b8 Author: Alex Deucher <alexander.deucher@amd.com> Date: Tue May 3 16:25:53 2016 -0400 drm/amdgpu: fetch cu_info once at init Fetch this info once at init and just store the results for future requests. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 20 +++++++++----------- drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 4 +--- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 9 ++++----- drivers/gpu/drm/amd/amdgpu/cik.c | 1 - drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 23 +++++++---------------- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.h | 1 - drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 11 ++++------- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.h | 1 - drivers/gpu/drm/amd/amdgpu/vi.c | 1 - 9 files changed, 25 insertions(+), 46 deletions(-) commit edf600dac65eecb6c8bcf21fa986db30ee21a2ac Author: Christian König <christian.koenig@amd.com> Date: Tue May 3 15:54:54 2016 +0200 drm/amd: cleanup remaining spaces and tabs v2 This is the result of running the following commands: find drivers/gpu/drm/amd/ -name "*.h" -exec sed -i 's/[ \t]\+$//' {} \; find drivers/gpu/drm/amd/ -name "*.c" -exec sed -i 's/[ \t]\+$//' {} \; find drivers/gpu/drm/amd/ -name "*.h" -exec sed -i 's/ \+\t/\t/' {} \; find drivers/gpu/drm/amd/ -name "*.c" -exec sed -i 's/ \+\t/\t/' {} \; v2: drop changes to DAL and internal headers Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 12 ++++++------ drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gds.h | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/atom.h | 2 +- drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 2 +- drivers/gpu/drm/amd/amdgpu/cik_ih.c | 2 +- drivers/gpu/drm/amd/amdgpu/cikd.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/cz_ih.c | 2 +- drivers/gpu/drm/amd/amdgpu/cz_smumgr.h | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/vid.h | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 6 +++--- drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 8 ++++---- drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.c | 4 ++-- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 8 ++++---- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.h | 18 +++++++++--------- drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 2 +- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 2 +- 23 files changed, 56 insertions(+), 56 deletions(-) commit b1c8a81fdd346274e3c38909740eec7182ef8f8a Author: Christian König <christian.koenig@amd.com> Date: Wed May 4 10:34:03 2016 +0200 drm/amdgpu: remove define for reserved client ID Just set it to zero instead. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) commit 79aa03893df937967201b6ea34e8d4216b893a38 Author: Christian König <christian.koenig@amd.com> Date: Wed May 4 10:33:11 2016 +0200 drm/amdgpu: remove owner cleanup v2 The client ID is now unique, so no need to resert the owner fields any more. v2: remove unused variables as well Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> (v1) Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 13 ------------- 1 file changed, 13 deletions(-) commit 0ea54b9b6c4ebc04cc6f68246b03577a25dbd4bb Author: Christian König <christian.koenig@amd.com> Date: Wed May 4 10:20:01 2016 +0200 drm/amdgpu: make the VMID owner always 64bit Otherwise we could (in theory) run into problems on 32bit systems. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 4d9c514d8ccff2b4bd0db5d3e178c0c0b3f3bc77 Author: Christian König <christian.koenig@amd.com> Date: Tue May 3 18:46:19 2016 +0200 drm/amdgpu: two minor 80 char fixes Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 10 ++++++---- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 3 ++- drivers/gpu/drm/amd/amdgpu/amdgpu_prime.c | 7 ++++--- 3 files changed, 12 insertions(+), 8 deletions(-) commit 794ff5710eb1d8bea4acc79cd005f6342623ec46 Author: Monk Liu <Monk.Liu@amd.com> Date: Wed May 4 16:27:41 2016 +0800 drm/amdgpu: hdp flush&inval should always do This fixes Tonga vm-fault issue when running disaster (a multiple context GL heavy tests), We should always flush & invalidate hdp no matter vm used or not. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <David1.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit f0f3a8fbdb1e40a37ec44b1df5f82341272c1871 Author: Tom St Denis <tom.stdenis@amd.com> Date: Tue May 3 10:36:28 2016 -0400 drm/amd/amdgpu: Enable CG for UVD6 on Carrizo Tested via vdpau/mpv. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit fe707664879b15b9caafd3b9f0f9897aa26a7edd Author: Chunming Zhou <David1.Zhou@amd.com> Date: Wed Apr 27 18:07:41 2016 +0800 drm/amdgpu: add pipeline sync for compute job hardware ring is async processed, the job is executed in parallel. In some case, this will result vm fault, like jobs with different vmids. This works around a CPC hw issue which will eventually be fixed in fw. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c5637837ba5d5b5e962e73f5a1a7c5456fa85a68 Author: Monk Liu <Monk.Liu@amd.com> Date: Tue Apr 19 20:11:32 2016 +0800 drm/amdgpu: keep vm in job instead of ib (v2) ib.vm is a legacy way to get vm, after scheduler implemented vm should be get from job, and all ibs from one job share the same vm, no need to keep ib.vm just move vm field to job. this patch as well add job as paramter to ib_schedule so it can get vm from job->vm. v2: agd: sqaush in: drm/amdgpu: check if ring emit_vm_flush exists in vm flush No vm flush on engines that don't support VM. bug: https://bugs.freedesktop.org/show_bug.cgi?id=95195 Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 3 ++- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 16 ++++------------ drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 9 +++++---- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 3 ++- drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 +- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 +- 12 files changed, 25 insertions(+), 30 deletions(-) commit 1f207f81e371bed8aa4c898de091d5cfbf68f59e Author: Chunming Zhou <David1.Zhou@amd.com> Date: Mon Apr 25 10:23:34 2016 +0800 drm/amdgpu: make vmid owner be client_id Using the pointer is not adequate. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 031e2983e8e385b9c99367586decabf6323ae049 Author: Chunming Zhou <David1.Zhou@amd.com> Date: Mon Apr 25 10:19:13 2016 +0800 drm/amdgpu: add client id for every vm This adds a unique id for each vm client so we can properly track them. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 6 ++++++ drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 ++ 2 files changed, 8 insertions(+) commit 444066b915c1b9d0aa4ec7b2d2bbe627e08bf7a6 Author: Chunming Zhou <David1.Zhou@amd.com> Date: Mon Apr 25 10:28:24 2016 +0800 drm/amdgpu: fix wrong release of vmid owner The release of the vmid owner was not handled correctly. We need to take the lock and walk the lru list. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit bfb7802a06ac1855096a3f248822e8f943e6574d Author: Stephen Rothwell <sfr@canb.auug.org.au> Date: Wed May 11 11:07:02 2016 +1000 ASoC: Intel: fix up for DAI link's be_id change Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/boards/bxt_rt298.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 7a1be1a5536242bbd15b227173a89d28607a27a8 Merge: 396cbeb 2f0ad49 Author: Mark Brown <broonie@kernel.org> Date: Wed May 11 17:11:22 2016 +0100 Merge branch 'topic/dai-link' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-intel commit d65444d2fba98dcd4fa028ffada39c36a46f0038 Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Wed May 11 22:52:17 2016 +0900 perf buildid-cache: Use lsdir() for looking up buildid caches Use new lsdir() for looking up buildid caches. This changes logic a bit to ignore all dot files, since the build-id cache must not start with dot. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160511135217.23943.94596.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/build-id.c | 30 ++++-------------------------- 1 file changed, 4 insertions(+), 26 deletions(-) commit c48903b816e6cdffb09b473352851bf199d0c582 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Wed May 11 22:52:08 2016 +0900 perf symbols: Use lsdir() for the search in kcore cache directory Use lsdir() to search in kcore cache directory. This also avoids checking hidden dot directory entries, because kcore cache directories must always have the name from timestamps when taking the kcore snapshots, and it never start with dot. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160511135208.23943.68071.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/symbol.c | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) commit b5d8bbe8601a45b908f7952707bbb30bf221ca3b Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Wed May 11 22:51:59 2016 +0900 perf tools: Use SBUILD_ID_SIZE where applicable Use the existing SBUILD_ID_SIZE macro instead of the equivalent BUILD_ID_SIZE * 2 + 1 expression for allocating a buffer for build-id strings. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160511135159.23943.57120.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/annotate.c | 2 +- tools/perf/util/dso.c | 4 ++-- tools/perf/util/header.c | 2 +- tools/perf/util/map.c | 2 +- tools/perf/util/scripting-engines/trace-event-python.c | 2 +- tools/perf/util/symbol.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) commit 357a54f32a065835d3e6a08b07a91a57e52f32c7 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Wed May 11 22:51:27 2016 +0900 perf tools: Fix lsdir to set errno correctly Fix lsdir() to set correct positive error number (ENOMEM). Since "errno" must have a positive error number instead of negative number, fix lsdir to set it correctly. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Fixes: e1ce726e1db2 ("perf tools: Add lsdir() helper to read a directory") Link: http://lkml.kernel.org/r/20160511135127.23943.40644.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f5cd95ea6082d389be3337bea16c65d4220614fc Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed May 11 10:32:20 2016 -0300 perf trace: Move seccomp args beautifiers to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/n/tip-ovxifncj34ynrjjseg33lil3@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 53 +-------------------------------------- tools/perf/trace/beauty/seccomp.c | 52 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+), 52 deletions(-) commit af37d21a3245c4a54d608c1d85588203ebfe1ef9 Author: Axel Lin <axel.lin@ingics.com> Date: Wed May 11 11:48:11 2016 +0800 ASoC: max98371 Remove duplicate entry in max98371_reg Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/max98371.c | 1 - 1 file changed, 1 deletion(-) commit 8bf382ce0aef999663bf8d2b02bbfa7da1e9d272 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed May 11 10:29:36 2016 -0300 perf trace: Move flock op beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/n/tip-c4c47w2a2jx13terl2p2hros@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 32 +------------------------------- tools/perf/trace/beauty/flock.c | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 31 deletions(-) commit f9be7eefcce9de7323c922bea6b45183eb9ef5f0 Author: He Kuang <hekuang@huawei.com> Date: Tue May 10 07:40:32 2016 +0000 perf build: Add build-test for debug-frame on arm/arm64 Debug-frame for remote platforms is not related to the host platform, so we should test each platform separately. Signed-off-by: He Kuang <hekuang@huawei.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Ekaterina Tumanova <tumanova@linux.vnet.ibm.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1462866037-30382-5-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/build/Makefile.feature | 4 +++- tools/build/feature/Makefile | 7 +++++++ tools/build/feature/test-libunwind-debug-frame-aarch64.c | 16 ++++++++++++++++ tools/build/feature/test-libunwind-debug-frame-arm.c | 16 ++++++++++++++++ 4 files changed, 42 insertions(+), 1 deletion(-) commit b1d960000ca12508c25776f1fd375ee81578ae1f Author: He Kuang <hekuang@huawei.com> Date: Tue May 10 07:40:31 2016 +0000 perf build: Add build-test for libunwind cross-platforms support Currently only test for local libunwind. We should check all supported platforms so we can use them to parse perf.data with callchain info on different machines. Signed-off-by: He Kuang <hekuang@huawei.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Ekaterina Tumanova <tumanova@linux.vnet.ibm.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1462866037-30382-4-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/build/Makefile.feature | 4 ++++ tools/build/feature/Makefile | 16 ++++++++++++++++ tools/build/feature/test-libunwind-aarch64.c | 26 ++++++++++++++++++++++++++ tools/build/feature/test-libunwind-arm.c | 27 +++++++++++++++++++++++++++ tools/build/feature/test-libunwind-x86.c | 27 +++++++++++++++++++++++++++ tools/build/feature/test-libunwind-x86_64.c | 27 +++++++++++++++++++++++++++ 6 files changed, 127 insertions(+) commit 83302e79b18f75266e4a44281e8432f61d57d441 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue May 10 20:26:49 2016 -0700 perf script: Fix export of callchains with recursion in db-export When an IP with an unresolved symbol occurs in the callchain more than once (ie. recursion), then duplicate symbols can be created because the callchain nodes are never updated after they are first created. To fix this issue we call dso__find_symbol whenever we encounter a NULL symbol, in case we already added a symbol at that IP since we started traversing the callchain. This change prevents duplicate symbols from being exported when duplicate IPs are present in the callchain. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462937209-6032-5-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/db-export.c | 4 ++++ 1 file changed, 4 insertions(+) commit 7a2544c004a6c576b1e307f30925b165affe6a22 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue May 10 20:26:48 2016 -0700 perf script: Fix callchain addresses in db-export Remove the call to map_ip() to adjust al.addr, because it has already been called when assembling the callchain, in: thread__resolve_callchain_sample(perf_sample) add_callchain_ip(ip = perf_sample->callchain->ips[j]) thread__find_addr_location(addr = ip) thread__find_addr_map(addr) { al->addr = addr if (al->map) al->addr = al->map->map_ip(al->map, al->addr); } Calling it a second time can result in incorrect addresses being used. This can have effects such as duplicate symbols being created and exported. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462937209-6032-4-git-send-email-cphlipot0@gmail.com [ Show the callchain where it is done, to help reviewing this change down the line ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/db-export.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit bd0a51dd2794f1d17d4e7a34ad66db845cef3e5a Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue May 10 20:26:47 2016 -0700 perf script: Fix symbol insertion behavior in db-export Use the dso__insert_symbol function instead of symbols__insert() in order to properly update the dso symbol cache. If the cache is not updated, then duplicate symbols can be unintentionally created, inserted, and exported. This change prevents duplicate symbols from being exported due to dso__find_symbol() using a stale symbol cache. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462937209-6032-3-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/db-export.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit ae93a6c70838b87151ac12589dc507dbf4f2f067 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue May 10 20:26:46 2016 -0700 perf symbols: Add dso__insert_symbol function The current method for inserting symbols is to use the symbols__insert() function. However symbols__insert() does not update the dso symbol cache. This causes problems in the following scenario: 1. symbol not found at addr using dso__find_symbol 2. symbol inserted at addr using the existing symbols__insert function 3. symbol still not found at addr using dso__find_symbol() because cache isn't updated. This is undesired behavior. The undesired behavior in (3) is addressed by creating a new function, dso__insert_symbol() to both insert the symbol and update the symbol cache if necessary. If dso__insert_symbol() is used in (2) instead of symbols__insert(), then the undesired behavior in (3) is avoided. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462937209-6032-2-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/symbol.c | 12 ++++++++++++ tools/perf/util/symbol.h | 3 +++ 2 files changed, 15 insertions(+) commit 62665dff754a80e2fdd214ef2ed21abb2a7d03a2 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue May 10 12:33:52 2016 -0300 perf scripting python: Use Py_FatalError instead of die() It probably is equivalent, but that seems to be the "pythonic" way of dieing? Anyway, one less die() in the tools/perf codebase. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Cc: Chris Phlipot <cphlipot0@gmail.com> Link: http://lkml.kernel.org/n/tip-nlzgepdv2818zs4e7faif9tu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/scripting-engines/trace-event-python.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit ef51d3ff0da445a2de8f836f0e81881465a18200 Author: Michele Curti <michele.curti@gmail.com> Date: Wed Apr 27 21:37:51 2016 +0200 i2c: algo-bit: declare i2c_bit_quirk_no_clk_stretch as static i2c_bit_quirk_no_clk_stretch is used in i2c-algo-bit.c only, so declare it as static. Signed-off-by: Michele Curti <michele.curti@gmail.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/algos/i2c-algo-bit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 38f5d8b32f36bcac1f54d4511a81e02ed8771a29 Merge: d295015 452e8401 Author: Ingo Molnar <mingo@kernel.org> Date: Tue May 10 22:23:34 2016 +0200 Merge tag 'perf-core-for-mingo-20160510' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Recording 'dwarf' callchains do not need DWARF unwinding support (He Kuang) - Print recently added perf_event_attr.write_backward bit flag in -vv verbose mode (Arnaldo Carvalho de Melo) - Fix incorrect python db-export error message in 'perf script' (Chris Phlipot) - Fix handling of zero-length symbols (Chris Phlipot) - perf stat: Scale values by unit before metrics (Andi Kleen) Infrastructure changes: - Rewrite strbuf not to die(), making tools using it to check its return value instead (Masami Hiramatsu) - Support reading from backward ring buffer, add a 'perf test' entry for it (Wang Nan) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit d2950158d0d7bc376503393ca5f73f6f8d27c56b Merge: ea7c285 e9d848c Author: Ingo Molnar <mingo@kernel.org> Date: Wed May 11 16:56:38 2016 +0200 Merge branch 'perf/urgent' into perf/core, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 21e9efd92bb5e205b6243166b0fd38d3a5be8235 Author: Shardar Shariff Md <smohammed@nvidia.com> Date: Mon Apr 25 19:08:36 2016 +0530 i2c: tegra: disable clock before returning error Disable clock before returning error in tegra_i2c_init() as its leaves i2c clock ON in case of error and never turns off again as it will have unbalanced clock enable/disable Signed-off-by: Shardar Shariff Md <smohammed@nvidia.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-tegra.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 396cbebeeb9734aee8efe39431d3b96655bf1e94 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Tue May 10 09:08:57 2016 +0300 ASoC: Intel: Fix printk formatting Format number after 0x in hex. Cc: Jie Yang <yang.jie@linux.intel.com> Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: Mark Brown <broonie@kernel.org> Cc: Jaroslav Kysela <perex@perex.cz> Cc: Takashi Iwai <tiwai@suse.com> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/haswell/sst-haswell-pcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1135ef1139b3ebd5dc762b6b02384f8a7a84f8d4 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Wed May 11 14:14:05 2016 +0300 ASoC: twl6040: Select LPPLL during standby When the codec is in standby we do not need to keep the HPPLL active. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/twl6040.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit 75aeddd12f205d07b36ed76db3426e974b8f2a21 Author: David Howells <dhowells@redhat.com> Date: Wed May 11 14:36:14 2016 +0100 MAINTAINERS: Update keyrings record and add asymmetric keys record Add some stuff to the coverage of the keyrings record and add an asymmetric keys record. Signed-off-by: David Howells <dhowells@redhat.com> MAINTAINERS | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit cc74545a8b67fb193d01f4639d0b93dc913c3c4c Author: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Date: Fri Apr 29 17:48:08 2016 +0300 lib: asn1_decoder - add MODULE_LICENSE("GPL") A kernel taint results when loading the rsa_generic module: root@(none):~# modprobe rsa_generic asn1_decoder: module license 'unspecified' taints kernel. Disabling lock debugging due to kernel taint "Tainting" of the kernel is (usually) a way of indicating that a proprietary module has been inserted, which is not the case here. Signed-off-by: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Signed-off-by: David Howells <dhowells@redhat.com> lib/asn1_decoder.c | 3 +++ 1 file changed, 3 insertions(+) commit 3c8f2278716dc862c420d3d256a83ce30fd12e74 Author: David Howells <dhowells@redhat.com> Date: Wed May 11 14:31:55 2016 +0100 KEYS: The PKCS#7 test key type should use the secondary keyring The PKCS#7 test key type should use the secondary keyring instead of the built-in keyring if available as the source of trustworthy keys. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/pkcs7_key_type.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d6d5c125350dae960a22b45a4ffad46c4abb3ecc Author: Alexander Müller <serveralex@gmail.com> Date: Sun May 8 19:59:49 2016 +0200 pinctrl: meson: Fix eth_tx_en bit index Fix pinctrl eth_tx_en bit index according to Hardkernel ODROID-C1 datasheet. Signed-off-by: Alexander Müller <serveralex@gmail.com> Acked-by: Carlo Caione <carlo@endlessm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/meson/pinctrl-meson8b.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0ef659a30055e5ec914b51f5294789ea2a92b08c Author: Arnd Bergmann <arnd@arndb.de> Date: Wed May 11 14:11:13 2016 +0200 ARM: aspeed: adapt defconfigs for new CONFIG_PRINTK_TIME Commit 94ea9c7a579f ("lib, switch CONFIG_PRINTK_TIME to int") changes the type of CONFIG_PRINTK_TIME and adapts all existing defconfig files, while we add two new defconfig files with d0bc3483da87 ("arm/configs: Add Aspeed defconfig"), with the old type. This changes the two new defconfig files to match the other ones. As a result, we get harmless warnings for the arm-soc defconfig branch by itself, but everything will work when 4.7-rc1 is out. Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/configs/aspeed_g4_defconfig | 2 +- arch/arm/configs/aspeed_g5_defconfig | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit b5cb9ab1a00b112fcb96164c814f1f111deeafba Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:24 2016 +1000 powerpc/powernv/npu: Enable NVLink pass through IBM POWER8 NVlink systems come with Tesla K40-ish GPUs each of which also has a couple of fast speed links (NVLink). The interface to links is exposed as an emulated PCI bridge which is included into the same IOMMU group as the corresponding GPU. In the kernel, NPUs get a separate PHB of the PNV_PHB_NPU type and a PE which behave pretty much as the standard IODA2 PHB except NPU PHB has just a single TVE in the hardware which means it can have either 32bit window or 64bit window or DMA bypass but never two of these. In order to make these links work when GPU is passed to the guest, these bridges need to be passed as well; otherwise performance will degrade. This implements and exports API to manage NPU state in regard to VFIO; it replicates iommu_table_group_ops. This defines a new pnv_pci_ioda2_npu_ops which is assigned to the IODA2 bridge if there are NPUs for a GPU on the bridge. The new callbacks call the default IODA2 callbacks plus new NPU API. This adds a gpe_table_group_to_npe() helper to find NPU PE for the IODA2 table_group, it is not expected to fail as the helper is only called from the pnv_pci_ioda2_npu_ops. This does not define NPU-specific .release_ownership() so after VFIO is finished, DMA on NPU is disabled which is ok as the nvidia driver sets DMA mask when probing which enable 32 or 64bit DMA on NPU. This adds a pnv_pci_npu_setup_iommu() helper which adds NPUs to the GPU group if any found. The helper uses helpers to look for the "ibm,gpu" property in the device tree which is a phandle of the corresponding GPU. This adds an additional loop over PEs in pnv_ioda_setup_dma() as the main loop skips NPU PEs as they do not have 32bit DMA segments. As pnv_npu_set_window() and pnv_npu_unset_window() are started being used by the new IODA2-NPU IOMMU group, this makes the helpers public and adds the DMA window number parameter. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-By: Alistair Popple <alistair@popple.id.au> [mpe: Add pnv_pci_ioda_setup_iommu_api() to fix build with IOMMU_API=n] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 64 +++++++++++++++-- arch/powerpc/platforms/powernv/pci-ioda.c | 112 ++++++++++++++++++++++++++++++ arch/powerpc/platforms/powernv/pci.h | 6 ++ 3 files changed, 176 insertions(+), 6 deletions(-) commit 85674868cecebdf6eb7239ecf9c32b6273208d03 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:23 2016 +1000 powerpc/powernv/npu: Rework TCE Kill handling The pnv_ioda_pe struct keeps an array of peers. At the moment it is only used to link GPU and NPU for 2 purposes: 1. Access NPU quickly when configuring DMA for GPU - this was addressed in the previos patch by removing use of it as DMA setup is not what the kernel would constantly do. 2. Invalidate TCE cache for NPU when it is invalidated for GPU. GPU and NPU are in different PE. There is already a mechanism to attach multiple iommu_table_group to the same iommu_table (used for VFIO), we can reuse it here so does this patch. This gets rid of peers[] array and PNV_IODA_PE_PEER flag as they are not needed anymore. While we are here, add TCE cache invalidation after enabling bypass. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-By: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 71 +++++++++---------------------- arch/powerpc/platforms/powernv/pci-ioda.c | 62 +++------------------------ arch/powerpc/platforms/powernv/pci.h | 6 --- 3 files changed, 27 insertions(+), 112 deletions(-) commit b575c731fe58c1ecb1247c6a334ba6c7b4c0b480 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:22 2016 +1000 powerpc/powernv/npu: Add set/unset window helpers The upcoming NVLink passthrough support will require NPU code to cope with two DMA windows. This adds a pnv_npu_set_window() helper which programs 32bit window to the hardware. This also adds multilevel TCE support. This adds a pnv_npu_unset_window() helper which removes the DMA window from the hardware. This does not make difference now as the caller - pnv_npu_dma_set_bypass() - enables bypass in the hardware but the next patch will use it to manage TCE table lists for TCE Kill handling. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-By: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 65 +++++++++++++++++++++++++++----- 1 file changed, 55 insertions(+), 10 deletions(-) commit 7d623e42560ea69eb248d48a1b1b105f28807e6e Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:21 2016 +1000 powerpc/powernv/ioda2: Export debug helper pe_level_printk() This exports debugging helper pe_level_printk() and corresponding macroses so they can be used in npu-dma.c. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-By: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 9 +-------- arch/powerpc/platforms/powernv/pci.h | 9 +++++++++ 2 files changed, 10 insertions(+), 8 deletions(-) commit f9f834567432e4d21f26debe10e1ca0ab52446e5 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:20 2016 +1000 powerpc/powernv/npu: Simplify DMA setup NPU devices are emulated in firmware and mainly used for NPU NVLink training; one NPU device is per a hardware link. Their DMA/TCE setup must match the GPU which is connected via PCIe and NVLink so any changes to the DMA/TCE setup on the GPU PCIe device need to be propagated to the NVLink device as this is what device drivers expect and it doesn't make much sense to do anything else. This makes NPU DMA setup explicit. pnv_npu_ioda_controller_ops::pnv_npu_dma_set_mask is moved to pci-ioda, made static and prints warning as dma_set_mask() should never be called on this function as in any case it will not configure GPU; so we make this explicit. Instead of using PNV_IODA_PE_PEER and peers[] (which the next patch will remove), we test every PCI device if there are corresponding NVLink devices. If there are any, we propagate bypass mode to just found NPU devices by calling the setup helper directly (which takes @bypass) and avoid guessing (i.e. calculating from DMA mask) whether we need bypass or not on NPU devices. Since DMA setup happens in very rare occasion, this will not slow down booting or VFIO start/stop much. This renames pnv_npu_disable_bypass to pnv_npu_dma_set_32 to make it more clear what the function really does which is programming 32bit table address to the TVT ("disabling bypass" means writing zeroes to the TVT). This removes pnv_npu_dma_set_bypass() from pnv_npu_ioda_fixup() as the DMA configuration on NPU does not matter until dma_set_mask() is called on GPU and that will do the NPU DMA configuration. This removes phb->dma_dev_setup initialization for NPU as pnv_pci_ioda_dma_dev_setup is no-op for it anyway. This stops using npe->tce_bypass_base as it never changes and values other than zero are not supported. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 87 ++++++++++++++----------------- arch/powerpc/platforms/powernv/pci-ioda.c | 30 +++++------ arch/powerpc/platforms/powernv/pci.h | 3 +- 3 files changed, 52 insertions(+), 68 deletions(-) commit 6969af73521a9042d91c9efd41f22cf7be7f1ba9 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:19 2016 +1000 powerpc/powernv/npu: Use the correct IOMMU page size This uses the page size from iommu_table instead of hard-coded 4K. This should cause no change in behavior. While we are here, move bits around to prepare for further rework which will define and use iommu_table_group_ops. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 0bbcdb437da0c4acba582058d3d1a84b93bc081d Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:18 2016 +1000 powerpc/powernv/npu: TCE Kill helpers cleanup NPU PHB TCE Kill register is exactly the same as in the rest of POWER8 so let's reuse the existing code for NPU. The only bit missing is a helper to reset the entire TCE cache so this moves such a helper from NPU code and renames it. Since pnv_npu_tce_invalidate() does really invalidate the entire cache, this uses pnv_pci_ioda2_tce_invalidate_entire() directly for NPU. This adds an explicit comment for workaround for invalidating NPU TCE cache. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Alistair Popple <alistair@popple.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/npu-dma.c | 41 ------------------------------- arch/powerpc/platforms/powernv/pci-ioda.c | 29 ++++++++++++++++++---- arch/powerpc/platforms/powernv/pci.h | 7 +----- 3 files changed, 25 insertions(+), 52 deletions(-) commit bef9253f551189febf0052a06dc079eb34137a58 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:17 2016 +1000 powerpc/powernv: Define TCE Kill flags This replaces magic constants for TCE Kill IODA2 register with macros. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit a7cf13caad8bf368a28f31dbb4807d61bc9ace18 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:16 2016 +1000 powerpc/powernv: Rename pnv_pci_ioda2_tce_invalidate_entire As in fact pnv_pci_ioda2_tce_invalidate_entire() invalidates TCEs for the specific PE rather than the entire cache, rename it to pnv_pci_ioda2_tce_invalidate_pe(). In later patches we will add a proper pnv_pci_ioda2_tce_invalidate_entire(). Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 54de285beb9ef8b85cf240f7cda161bd6ae5d04c Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 18:55:15 2016 +1000 vfio/spapr: Relax the IOMMU compatibility check We are going to have multiple different types of PHB on the same system with POWER8 + NVLink and PHBs will have different IOMMU ops. However we only really care about one callback - create_table - so we can relax the compatibility check here. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Acked-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/vfio/vfio_iommu_spapr_tce.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c8ceacc22bce95d3a9cff198c9c27a30105a16b8 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:45 2016 +1000 powerpc/powernv: Exclude root bus in pnv_pci_reset_secondary_bus() The function pnv_pci_reset_secondary_bus() is called like below. It's impossible for call the function on root bus. So it's safe to remove the root bus case in the function. No functional changes introduced. pci_parent_bus_reset() / pci_bus_reset() / pci_try_reset_bus() pci_reset_bridge_secondary_bus() pcibios_reset_secondary_bus() pnv_pci_reset_secondary_bus() Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/eeh-powernv.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 4fad494321351f0ac412945c6a464109ad96734a Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:44 2016 +1000 powerpc/powernv: Simplify pnv_eeh_reset() This drops unnecessary nested if statements in pnv_eeh_reset() to improve the code readability. After the changes, the unused local variable "ret" is dropped as well. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/eeh-powernv.c | 67 +++++++++++++--------------- 1 file changed, 31 insertions(+), 36 deletions(-) commit 4a5954ed7726497415ae49204cfc8e38ee8b127e Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:43 2016 +1000 powerpc/pci: Don't scan empty slot In hotplug case, function pci_add_pci_devices() is called to rescan the specified PCI bus, which might not have any child devices. Access to the PCI bus's child device node will cause kernel crash without exception. This adds one more check to skip scanning PCI bus that doesn't have any subordinate devices from device-tree, in order to avoid kernel crash. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/pci-hotplug.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit cdddc577d956d55a62581ba3681f8ba66eca3873 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:42 2016 +1000 powerpc/pci: Export pci_traverse_device_nodes() This renames traverse_pci_devices() to pci_traverse_device_nodes(). The function traverses all subordinate device nodes of the specified one. Also, below cleanup applied to the function. No logical changes introduced. * Rename "pre" to "fn". * Avoid assignment in if condition reported from checkpatch.pl. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/ppc-pci.h | 6 +++--- arch/powerpc/kernel/pci_dn.c | 15 ++++++++++----- arch/powerpc/platforms/pseries/msi.c | 4 ++-- 3 files changed, 15 insertions(+), 10 deletions(-) commit de5a28ac5a2d9619dc82286b08dadca577133bbe Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:41 2016 +1000 powerpc/pci: Introduce pci_remove_device_node_info() This implements and exports pci_remove_device_node_info(). It's used to remove the pdn (struct pci_dn) for the indicated device node. The function is going to be used by PowerNV PCI hotplug driver. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 1 + arch/powerpc/kernel/pci_dn.c | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+) commit d8f66f411e2dc1c27413f0ba73f49bccfa998f1b Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:40 2016 +1000 powerpc/pci: Export pci_add_device_node_info() This renames update_dn_pci_info() to pci_add_device_node_info() with corresponding adjustment on the parameter type and exports it. The function is used to create pdn (struct pci_dn) for the indicated device node. Another function add_pdn(), almost wrapper of pci_add_device_node_info(), to be used in traverse_pci_devices(). No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 3 ++- arch/powerpc/kernel/pci_dn.c | 30 +++++++++++++++++++----------- arch/powerpc/platforms/pseries/setup.c | 2 +- 3 files changed, 22 insertions(+), 13 deletions(-) commit 6384d97780c123d2e167242862ed4ea9051210e4 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:39 2016 +1000 powerpc/pci: Move pci_find_bus_by_node() around This moves pci_find_bus_by_node() from arch/powerpc/platforms/ pseries/pci_dlpar.c to arch/powerpc/kernel/pci-hotplug.c so that the function can be used by pSeries and PowerNV platform at the same time. Also, below cleanup applied. No functional changes introduced. * Remove variable "busdn" in find_bus_among_children() * Use PCI_DN() to convert device node to pci_dn Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/pci-hotplug.c | 29 ++++++++++++++++++++++++++++ arch/powerpc/platforms/pseries/pci_dlpar.c | 31 ------------------------------ 2 files changed, 29 insertions(+), 31 deletions(-) commit 3773dd258e91e1e14d95cdf17b9d83a1a7b27af1 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:38 2016 +1000 powerpc/pci: Rename pcibios_find_pci_bus() This renames pcibios_find_pci_bus() to pci_find_bus_by_node() to avoid conflicts with those PCI subsystem weak function names, which have prefix "pcibios". No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 2 +- arch/powerpc/platforms/pseries/pci_dlpar.c | 5 ++--- drivers/pci/hotplug/rpadlpar_core.c | 6 +++--- drivers/pci/hotplug/rpaphp_pci.c | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) commit bd251b893d46240fc12d9fa9316d9ea6ec2b69a7 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:37 2016 +1000 powerpc/pci: Rename pcibios_{add, remove}_pci_devices() This renames pcibios_{add,remove}_pci_devices() to avoid conflicts with names of the weak functions in PCI subsystem, which have the prefix "pcibios". No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-By: Alistair Popple <alistair@popple.id.au> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 4 ++-- arch/powerpc/kernel/eeh_driver.c | 12 ++++++------ arch/powerpc/kernel/pci-hotplug.c | 15 +++++++-------- drivers/pci/hotplug/rpadlpar_core.c | 2 +- drivers/pci/hotplug/rpaphp_core.c | 4 ++-- drivers/pci/hotplug/rpaphp_pci.c | 2 +- 6 files changed, 19 insertions(+), 20 deletions(-) commit 1e9167726c41b8d2126327379f4f82acbd548ba8 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:36 2016 +1000 powerpc/powernv: Use PE instead of number during setup and release In current implementation, the PEs that are allocated or picked from the reserved list are identified by PE number. The PE instance has to be picked according to the PE number eventually. We have same issue when PE is released. For pnv_ioda_pick_m64_pe() and pnv_ioda_alloc_pe(), this returns PE instance so that pnv_ioda_setup_bus_PE() can use the allocated or reserved PE instance directly. Also, pnv_ioda_setup_bus_PE() returns the reserved/allocated PE instance to be used in subsequent patches. On the other hand, pnv_ioda_free_pe() uses PE instance (not number) as its argument. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 104 +++++++++++++++++------------- arch/powerpc/platforms/powernv/pci.h | 2 +- 2 files changed, 59 insertions(+), 47 deletions(-) commit 2b923ed1bd96cc471bb0f0eddfed6ae4753d717b Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Thu May 5 12:04:16 2016 +1000 powerpc/powernv/ioda1: Improve DMA32 segment track In current implementation, the DMA32 segments required by one specific PE isn't calculated with the information hold in the PE independently. It conflicts with the PCI hotplug design: PE centralized, meaning the PE's DMA32 segments should be calculated from the information hold in the PE independently. This introduces an array (@dma32_segmap) for every PHB to track the DMA32 segmeng usage. Besides, this moves the logic calculating PE's consumed DMA32 segments to pnv_pci_ioda1_setup_dma_pe() so that PE's DMA32 segments are calculated/allocated from the information hold in the PE (DMA32 weight). Also the logic is improved: we try to allocate as much DMA32 segments as we can. It's acceptable that number of DMA32 segments less than the expected number are allocated. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 115 ++++++++++++++++-------------- arch/powerpc/platforms/powernv/pci.h | 7 +- 2 files changed, 66 insertions(+), 56 deletions(-) commit 801846d1deff943114f6f468b21386247b008321 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:34 2016 +1000 powerpc/powernv: Remove DMA32 PE list PEs are put into PHB DMA32 list (phb->ioda.pe_dma_list) according to their DMA32 weight. The PEs on the list are iterated to setup their TCE32 tables at system booting time. The list is used for once at boot time and no need to keep it. This moves the logic calculating DMA32 weight of PHB and PE to pnv_ioda_setup_dma() to drop PHB's DMA32 list. Also, every PE traces the consumed DMA32 segment by @tce32_seg and @tce32_segcount are useless and they're removed. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 171 ++++++++++++++---------------- arch/powerpc/platforms/powernv/pci.h | 19 ---- 2 files changed, 78 insertions(+), 112 deletions(-) commit acce971c0e72c63cc2247e2412375e13a0be1ee1 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:33 2016 +1000 powerpc/powernv/ioda1: Introduce PNV_IODA1_DMA32_SEGSIZE Currently, there is one macro (TCE32_TABLE_SIZE) representing the TCE table size for one DMA32 segment. The constant representing the DMA32 segment size (1 << 28) is still used in the code. This defines PNV_IODA1_DMA32_SEGSIZE representing one DMA32 segment size. the TCE table size can be calcualted when the page has fixed 4KB size. So all the related calculation depends on one macro (PNV_IODA1_DMA32_SEGSIZE). No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-By: Alistair Popple <alistair@popple.id.au> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) commit b30d936f6f3ee357e48b7f50754b0855d87f1cce Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:32 2016 +1000 powerpc/powernv/ioda1: Rename pnv_pci_ioda_setup_dma_pe() This renames pnv_pci_ioda_setup_dma_pe() to pnv_pci_ioda1_setup_dma_pe() as it's the counter-part of IODA2's pnv_pci_ioda2_setup_dma_pe(). No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 9945155143926c1191bc0a1178ac2bb290467370 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Thu May 5 12:02:13 2016 +1000 powerpc/powernv/ioda1: M64 support on P7IOC This enables M64 window on P7IOC, which has been enabled on PHB3. Different from PHB3 where 16 M64 BARs are supported and each of them can be owned by one particular PE# exclusively or divided evenly to 256 segments, every P7IOC PHB has 16 M64 BARs and each of them are divided to 8 segments. So every P7IOC PHB supports 128 M64 segments in total. P7IOC has M64DT, which helps mapping one particular M64 segment# to arbitrary PE#. PHB3 doesn't have M64DT, indicating that one M64 segment can only be pinned to the fixed PE#. In order to unified M64 support M64 on P7IOC and PHB3, we just provide 128 M64 segments on every P7IOC PHB and each of them is pinned to the fixed PE# by bypassing the function of M64DT. In turn, we just need different phb->init_m64() for P7IOC and PHB3 and maps M64 segment in pnv_ioda_reserve_m64_pe() for P7IOC, most of the code are shared by them. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alistair Popple <alistair@popple.id.au> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 89 +++++++++++++++++++++++++++++-- 1 file changed, 86 insertions(+), 3 deletions(-) commit c430670ad11aa8c5a9f9706bf6f7376310af7f4b Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:30 2016 +1000 powerpc/powernv: Rename M64 related functions This renames those functions picking PE number based on consumed M64 segments, mapping M64 segments to PEs as those functions are going to be shared by IODA1/IODA2 in next patch. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 93289d8c08dc038a3efccf6b7fa563e1683cd868 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:29 2016 +1000 powerpc/powernv: Track M64 segment consumption When unplugging PCI devices, their parent PEs might be offline. The consumed M64 resource by the PEs should be released at that time. As we track M32 segment consumption, this introduces an array to the PHB to track the mapping between M64 segment and PE number. Note: M64 mapping isn't covered by pnv_ioda_setup_pe_seg() as IODA2 doesn't support the mapping explicitly while it's supported on IODA1. Until now, no M64 is supported on IODA1 in software. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 10 ++++++++-- arch/powerpc/platforms/powernv/pci.h | 1 + 2 files changed, 9 insertions(+), 2 deletions(-) commit 69d733e72ddae1680ffd3b5c648ff31cb46d9cc9 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:28 2016 +1000 powerpc/powernv: IO and M32 mapping based on PCI device resources Currently, the IO and M32 segments are mapped to the corresponding PE based on the windows of the parent bridge of PE's primary bus. It's not going to work when the windows of root port or upstream port of the PCIe switch behind root port are extended to PHB's apertures in order to support hotplug in subsequent patch. This fixes the issue by mapping IO and M32 segments based on the resources of the PCI devices included in the PE, instead of the windows of the parent bridge of the PE's primary bus. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) commit 23e79425fe7caaa93ddcee18ac4c57069f0fb4b6 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:27 2016 +1000 powerpc/powernv: Simplify pnv_ioda_setup_pe_seg() pnv_ioda_setup_pe_seg() associates the IO and M32 segments with the owner PE. The code mapping segments should be fixed and immune from logic changes introduced to pnv_ioda_setup_pe_seg(). This moves the code mapping segments to helper pnv_ioda_setup_pe_res(). The data type for @rc is changed to "int64_t". Also, argument @hose is removed from pnv_ioda_setup_pe() as it can be got from @pe. No functional changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-By: Alistair Popple <alistair@popple.id.au> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 121 +++++++++++++++--------------- 1 file changed, 62 insertions(+), 59 deletions(-) commit 3fa23ff8ff3f0fa4f187bc46f81c69b1fdeecd9a Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:26 2016 +1000 powerpc/powernv: Fix initial IO and M32 segmap There are two arrays for IO and M32 segment maps on every PHB. The index of the arrays are segment number and the value stored in the corresponding element is PE number, indicating the segment is assigned to the PE. Initially, all elements in those two arrays are zeroes, meaning all segments are assigned to PE#0. It's wrong. This fixes the initial values in the elements of those two arrays to IODA_INVALID_PE, meaning all segments aren't assigned to any PE. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 689ee8c95f399998f52eda827849b7771629a53c Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:25 2016 +1000 powerpc/powernv: Data type unsigned int for PE number This changes the data type of PE number from "int" to "unsigned int" in order to match the fact PE number is never negative: * The number of PE to which the specified PCI device is attached. * The PE number map for SRIOV VFs. * The returned PE number from pnv_ioda_alloc_pe(). * The returned PE number from pnv_ioda2_pick_m64_pe(). Suggested-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-By: Alistair Popple <alistair@popple.id.au> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 6 +++--- arch/powerpc/platforms/powernv/pci-ioda.c | 8 ++++---- arch/powerpc/platforms/powernv/pci.c | 2 +- arch/powerpc/platforms/powernv/pci.h | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) commit 92b8f137b3620b0a07c71b1bd191f9a22d0cf0ab Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:24 2016 +1000 powerpc/powernv: Rename PE# fields in struct pnv_phb This renames the fields related to PE number in "struct pnv_phb" for better reflecting of their usages as Alexey suggested. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/eeh-powernv.c | 2 +- arch/powerpc/platforms/powernv/pci-ioda.c | 58 ++++++++++++++-------------- arch/powerpc/platforms/powernv/pci.c | 2 +- arch/powerpc/platforms/powernv/pci.h | 4 +- 4 files changed, 33 insertions(+), 33 deletions(-) commit 13ce7598b6c0d9b3734fb070242de21b05aedd0d Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:23 2016 +1000 powerpc/powernv: Reorder fields in struct pnv_phb This moves those fields in struct pnv_phb that are related to PE allocation around. No logical change. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 475d92c27f3b32ea31f5f7c4ed7009a7b895b9e7 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:22 2016 +1000 powerpc/powernv: Drop phb->bdfn_to_pe() The last usage of pnv_phb::bdfn_to_pe() was removed in ff57b454ddb9 ("powerpc/eeh: Do probe on pci_dn"), so drop it. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 9 --------- arch/powerpc/platforms/powernv/pci.h | 1 - 2 files changed, 10 deletions(-) commit cb4224c501802940c41e2f46ae57de08fd0ca119 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:21 2016 +1000 powerpc/powernv: Cleanup on pci_controller_ops instances This cleans up on below data struct instances to use tab instead of space indent of statement to avoid complains from scripts/checkpatch.pl. No logical changes introduced. @pnv_pci_ioda_controller_ops @pnv_npu_ioda_controller_ops Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Acked-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci-ioda.c | 36 +++++++++++++++---------------- 1 file changed, 18 insertions(+), 18 deletions(-) commit 062b26ba3e6c5bc80f01056f5aa8546d18a2eb85 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Tue May 3 15:41:20 2016 +1000 powerpc/pci: Cleanup on struct pci_controller_ops Each PHB has one instance of "struct pci_controller_ops" that includes various callbacks called by PCI subsystem. In the definition of this struct, some callbacks have explicit names for its arguments, but the left don't have. This adds all explicit names of the arguments to the callbacks in "struct pci_controller_ops" so that the code looks consistent. Also, argument name @dev is replaced by @pdev as the later one is the preferred name for PCI device. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pci-bridge.h | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) commit 16aab321872400a4ce35b90ba40484fcb5d636ba Author: Rashmica Gupta <rashmicy@gmail.com> Date: Wed Dec 23 16:49:54 2015 +1100 selftests/powerpc: Add test to check if TM SPRs are corrupted Testing that the TM SPRs are behaving the way they should. Uses more threads than cpus to see if the following register values persist with context switching: - the FS (failure summary) flag in TEXASR - TFIAR and TFHAR Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/tm/.gitignore | 1 + tools/testing/selftests/powerpc/tm/Makefile | 3 +- tools/testing/selftests/powerpc/tm/tm-tmspr.c | 143 ++++++++++++++++++++++++++ 3 files changed, 146 insertions(+), 1 deletion(-) commit dbccb4940c9c9c8c93fcf733445e96dd2d6890d6 Author: Rashmica Gupta <rashmicy@gmail.com> Date: Wed Dec 23 16:49:53 2015 +1100 selftests/powerpc: Add TM test to check if TAR is corrupted If the transaction is aborted, the TAR should be rolled back to the checkpointed value before the transaction began. The value written to the TAR when the transaction is suspended should only remain there if the transaction completes successfully. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/tm/.gitignore | 1 + tools/testing/selftests/powerpc/tm/Makefile | 2 +- tools/testing/selftests/powerpc/tm/tm-tar.c | 90 +++++++++++++++++++++++++++ 3 files changed, 92 insertions(+), 1 deletion(-) commit d95be4ca3e457044be55c8b1c1b5ac64f17d8a92 Author: Rashmica Gupta <rashmicy@gmail.com> Date: Wed Dec 23 16:49:52 2015 +1100 selftests/powerpc: Add test for forking inside transaction This test does a fork syscall inside a transaction. Basic sniff test to see if we can enter the kernel during a transaction. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/tm/.gitignore | 1 + tools/testing/selftests/powerpc/tm/Makefile | 2 +- tools/testing/selftests/powerpc/tm/tm-fork.c | 42 +++++++++++++++++++++++++++ 3 files changed, 44 insertions(+), 1 deletion(-) commit da3ddc3b5fea695f7b2fa89c4ca17dfd529293d2 Author: Rashmica Gupta <rashmicy@gmail.com> Date: Wed Dec 23 16:49:51 2015 +1100 selftests/powerpc: Standardise TM calls Currently tbegin, tend etc are written as opcodes or asm instructions. So standardise these to asm instructions. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/tm/tm-resched-dscr.c | 16 +++++----------- tools/testing/selftests/powerpc/tm/tm-signal-stack.c | 4 ++-- 2 files changed, 7 insertions(+), 13 deletions(-) commit 2d59b3b25659463a24f05df367574d90b3cd7145 Author: Rashmica Gupta <rashmicy@gmail.com> Date: Wed Dec 23 16:49:50 2015 +1100 selftests/powerpc: Make reg.h common to all powerpc selftests Currently there is a reg.h in pmu/ebb that has defines that are useful in other powerpc selftests so move this up into selftests/powerpc folder. Also include in utils.h - as this is often used in self tests. Add in some other useful register defines. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/pmu/ebb/ebb.c | 1 - tools/testing/selftests/powerpc/pmu/ebb/reg.h | 49 ------------------- .../selftests/powerpc/pmu/ebb/reg_access_test.c | 1 - tools/testing/selftests/powerpc/reg.h | 55 ++++++++++++++++++++++ tools/testing/selftests/powerpc/utils.h | 1 + 5 files changed, 56 insertions(+), 51 deletions(-) commit 2513767d2255acfec707328948dcaefe887f6044 Author: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Date: Tue Mar 1 11:17:46 2016 +0530 powerpc/powernv: Rename machine_check_pSeries_early() to powernv The routine machine_check_pSeries_early() is only used on powernv, not pseries. Hence rename machine_check_pSeries_early() to machine_check_powernv_early(). Reported-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/exceptions-64s.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 266eab8f32cc43b688c2e9aaab63c2565a3998c2 Author: Christophe Lombard <clombard@linux.vnet.ibm.com> Date: Fri Apr 22 15:39:22 2016 +0200 cxl: Check periodically the coherent platform function's state In the PowerVM environment, the PHYP CoherentAccel component manages the state of the Coherent Accelerator Processor Interface adapter and virtualizes CAPI resources, handles CAPP, PSL, PSL Slice errors - and interrupts - and provides a new set of hcalls for the OS APIs to utilize Accelerator Function Unit (AFU). During the course of operation, a coherent platform function can encounter errors. Some possible reason for errors are: • Hardware recoverable and unrecoverable errors • Transient and over-threshold correctable errors PHYP implements its own state model for the coherent platform function. The state of the AFU is available through a hcall. The current implementation of the cxl driver, for the PowerVM environment, checks this state of the AFU only when an action is requested - open a device, ioctl command, memory map, attach/detach a process - from an external driver - cxlflash, libcxl. If an error is detected the cxl driver handles the error according the content of the Power Architecture Platform Requirements document. But in case of low-level troubles (or error injection), the PHYP component may reset the card and change the AFU state. The PHYP interface doesn't provide any way to be notified when that happens thus implies that the cxl driver: • cannot handle immediatly the state change of the AFU. • cannot notify other drivers (cxlflash, ...) The purpose of this patch is to wake up the cpu periodically to check the current state of each AFU and to see if we need to enter an error recovery path. Signed-off-by: Christophe Lombard <clombard@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/cxl.h | 4 +++- drivers/misc/cxl/guest.c | 57 +++++++++++++++++++++++++----------------------- 2 files changed, 33 insertions(+), 28 deletions(-) commit 7a0d85d313c2066712e530e668bc02bb741a685c Author: Ian Munsie <imunsie@au1.ibm.com> Date: Fri May 6 17:46:36 2016 +1000 cxl: Add kernel API to allow a context to operate with relocate disabled cxl devices typically access memory using an MMU in much the same way as the CPU, and each context includes a state register much like the MSR in the CPU. Like the CPU, the state register includes a bit to enable relocation, which we currently always enable. In some cases, it may be desirable to allow a device to access memory using real addresses instead of effective addresses, so this adds a new API, cxl_set_translation_mode, that can be used to disable relocation on a given kernel context. This can allow for the creation of a special privileged context that the device can use if it needs relocation disabled, and can use regular contexts at times when it needs relocation enabled. This interface is only available to users of the kernel API for obvious reasons, and will never be supported in a virtualised environment. This will be used by the upcoming cxl support in the mlx5 driver. Signed-off-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/api.c | 19 +++++++++++++++++++ drivers/misc/cxl/cxl.h | 1 + drivers/misc/cxl/guest.c | 3 +++ drivers/misc/cxl/native.c | 5 +++-- include/misc/cxl.h | 8 ++++++++ 5 files changed, 34 insertions(+), 2 deletions(-) commit 3c206fa77aaaac8cd7d4cfcd840c82495b01b288 Author: Ian Munsie <imunsie@au1.ibm.com> Date: Wed May 4 14:52:58 2016 +1000 cxl: Ensure PSL interrupt is configured for contexts with no AFU IRQs In the cxl kernel API, it is possible to create a context and start it without allocating any interrupts. Since we assign or allocate the PSL interrupt when allocating AFU interrupts this will lead to a situation where we start the context with no means to take any faults. The user API is not affected as it always goes through the cxl interrupt allocation code paths and will have the PSL interrupt allocated or assigned, even if no AFU interrupts were requested. This checks that at least one interrupt is configured at the time of attach, and if not it will assign the multiplexed PSL interrupt for powernv, or allocate a single interrupt for PowerVM. Signed-off-by: Ian Munsie <imunsie@au1.ibm.com> Reviewed-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/guest.c | 12 ++++++++++++ drivers/misc/cxl/native.c | 9 +++++++++ 2 files changed, 21 insertions(+) commit 0e5b5ba17ac33a05d9f4a48b5eb8b5e30f2274d7 Author: Ian Munsie <imunsie@au1.ibm.com> Date: Wed May 4 14:48:32 2016 +1000 cxl: Remove duplicate #defines These defines are not used, but other equivalent definitions (CXL_SPA_SW_CMD_*) are used. Remove the unused defines. Signed-off-by: Ian Munsie <imunsie@au1.ibm.com> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/cxl.h | 9 --------- 1 file changed, 9 deletions(-) commit 895a79805c287df73142f1b424b22ea5190734c2 Author: Ian Munsie <imunsie@au1.ibm.com> Date: Wed May 4 14:46:30 2016 +1000 cxl: Handle num_of_processes larger than can fit in the SPA num_of_process is a 16 bit field, theoretically allowing an AFU to support 16K processes, however the scheduled process area currently has a maximum size of 1MB, which limits the maximum number of processes to 7704. Some AFUs may not necessarily care what the limit is and just want to be able to use the maximum by setting the field to 16K. To allow these to work, detect this situation and use the maximum size for the SPA. Downgrade the WARN_ON to a dev_warn. Signed-off-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/native.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 171cb719dacd0f102b39bd5ab5eea0ce11813853 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Fri Feb 26 11:26:26 2016 +1100 powerpc/mm: Improve readability of update_mmu_cache() The function is used to update the MMU with software PTE. It can be called by data access exception handler (0x300) or instruction access exception handler (0x400). If the function is called by 0x400 handler, the local variable @access is set to _PAGE_EXEC to indicate the software PTE should have that flag set. When the function is called by 0x300 handler, @access is set to zero. This improves the readability of the function by replacing if statements with switch. No logical changes introduced. Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/mem.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) commit dd0b52c47a2d71b7960c9a5ce7d51f17ed03d9f5 Author: Oliver O'Halloran <oohall@gmail.com> Date: Thu May 5 17:54:08 2016 +1000 powerpc/mm: define TOP_ZONE as a constant The zone that contains the top of memory will be either ZONE_NORMAL or ZONE_HIGHMEM depending on the kernel config. There are two functions that require this information and both of them use an #ifdef to set a local variable (top_zone). This is a little silly so lets just make it a constant. Signed-off-by: Oliver O'Halloran <oohall@gmail.com> Cc: linux-mm@kvack.org Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/mem.c | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) commit 66707836062db62756b395d1fb16ab02ff162862 Author: Oliver O'Halloran <oohall@gmail.com> Date: Tue Feb 16 17:31:53 2016 +1100 powerpc/sstep: Fix emulation fall-through There is a switch fallthough in instr_analyze() which can cause an invalid instruction to be emulated as a different, valid, instruction. The rld* (opcode 30) case extracts a sub-opcode from bits 3:1 of the instruction word. However, the only valid values of this field are 001 and 000. These cases are correctly handled, but the others are not which causes execution to fall through into case 31. Breaking out of the switch causes the instruction to be marked as unknown and allows the caller to deal with the invalid instruction in a manner consistent with other invalid instructions. Signed-off-by: Oliver O'Halloran <oohall@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/lib/sstep.c | 1 + 1 file changed, 1 insertion(+) commit dd21731022faf43c1250050e5d28d11add599149 Author: Lennart Sorensen <lsorense@csclub.uwaterloo.ca> Date: Thu May 5 16:44:44 2016 -0400 powerpc/sstep: Fix sstep.c compile on powerpcspe Commit be96f63375a1 ("powerpc: Split out instruction analysis part of emulate_step()") introduced ldarx and stdcx into the instructions in sstep.c, which are not accepted by the assembler on powerpcspe, but does seem to be accepted by the normal powerpc assembler even in 32 bit mode. Wrap these two instructions in a __powerpc64__ check like it is everywhere else in the file. Fixes: be96f63375a1 ("powerpc: Split out instruction analysis part of emulate_step()") Signed-off-by: Len Sorensen <lsorense@csclub.uwaterloo.ca> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/lib/sstep.c | 4 ++++ 1 file changed, 4 insertions(+) commit 31cdd0c39c7544ced79da53aa0b7e989f3a39582 Author: Paul Mackerras <paulus@ozlabs.org> Date: Wed Apr 13 21:31:24 2016 +1000 powerpc/xmon: Fix SPR read/write commands and add command to dump SPRs xmon has commands for reading and writing SPRs, but they don't work currently for several reasons. They attempt to synthesize a small function containing an mfspr or mtspr instruction and call it. However, the instructions are on the stack, which is usually not executable. Also, for 64-bit we set up a procedure descriptor, which is fine for the big-endian ABIv1, but not correct for ABIv2. Finally, the code uses the infrastructure for catching memory errors, but that only catches data storage interrupts and machine check interrupts, but a failed mfspr/mtspr can generate a program interrupt or a hypervisor emulation assist interrupt, or be a no-op. Instead of trying to synthesize a function on the fly, this adds two new functions, xmon_mfspr() and xmon_mtspr(), which take an SPR number as an argument and read or write the SPR. Because there is no Power ISA instruction which takes an SPR number in a register, we have to generate one of each possible mfspr and mtspr instruction, for all 1024 possible SPRs. Thus we get just over 8k bytes of code for each of xmon_mfspr() and xmon_mtspr(). However, this 16kB of code pales in comparison to the > 130kB of PPC opcode tables used by the xmon disassembler. To catch interrupts caused by the mfspr/mtspr instructions, we add a new 'catch_spr_faults' flag. If an interrupt occurs while it is set, we come back into xmon() via program_check_interrupt(), _exception() and die(), see that catch_spr_faults is set and do a longjmp to bus_error_jmp, back into read_spr() or write_spr(). This adds a couple of other nice features: first, a "Sa" command that attempts to read and print out the value of all 1024 SPRs. If any mfspr instruction acts as a no-op, then the SPR is not implemented and not printed. Secondly, the Sr and Sw commands detect when an SPR is not implemented (i.e. mfspr is a no-op) and print a message to that effect rather than printing a bogus value. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/xmon/Makefile | 2 +- arch/powerpc/xmon/spr_access.S | 45 ++++++++++++++ arch/powerpc/xmon/xmon.c | 136 +++++++++++++++++++++++------------------ 3 files changed, 122 insertions(+), 61 deletions(-) commit f47822078dece7189cad0a5f472f148e5e916736 Author: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Date: Thu Apr 28 15:01:10 2016 +0530 perf tools: Fix perf regs mask generation On some architectures (powerpc in particular), the number of registers exceeds what can be represented in an integer bitmask. Ensure we generate the proper bitmask on such platforms. Fixes: 71ad0f5e4 ("perf tools: Support for DWARF CFI unwinding on post processing") Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/perf/util/perf_regs.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c4522469e6418fb547fbcd9d3aeb73bea0f6f859 Author: Chandan Kumar <chandan.kumar@linux.vnet.ibm.com> Date: Thu Apr 28 15:01:09 2016 +0530 perf/powerpc: Add support for unwinding perf-stackdump Adds support for unwinding user stack dump by linking with libunwind. Signed-off-by: Chandan Kumar <chandan.kumar@linux.vnet.ibm.com> Reviewed-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Tested-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/perf/arch/powerpc/util/Build | 1 + tools/perf/arch/powerpc/util/unwind-libunwind.c | 96 +++++++++++++++++++++++++ tools/perf/config/Makefile | 1 + 3 files changed, 98 insertions(+) commit 17ed7c38427ff84ef77eac15724b6faf35e5492e Author: Chandan Kumar <chandan.kumar@linux.vnet.ibm.com> Date: Thu Apr 28 15:01:08 2016 +0530 powerpc: Add HAVE_PERF_USER_STACK_DUMP support With perf regs support enabled for powerpc, in commit ed4a4ef85cf5 ("powerpc/perf: Add support for sampling interrupt register state"), the support for obtaining perf user stack dump is already enabled. This patch declares the support for same and also updates documentation to mark the support for perf-regs and perf-stackdump. Signed-off-by: Chandan Kumar <chandan.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Documentation/features/perf/perf-regs/arch-support.txt | 2 +- Documentation/features/perf/perf-stackdump/arch-support.txt | 2 +- arch/powerpc/Kconfig | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) commit aac55d7573c5d46ed9a62818d5d3e69dd2060105 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri May 6 16:47:12 2016 +1000 powerpc/mm/hash64: Fix subpage protection with 4K HPTE config With Linux page size of 64K and hardware only supporting 4K HPTE, if we use subpage protection, we always fail for the subpage 0 as shown below (using the selftest subpage_prot test): 520175565: (4520111850): Failed at 0x3fffad4b0000 (p=13,sp=0,w=0), want=fault, got=pass ! 4520890210: (4520826495): Failed at 0x3fffad5b0000 (p=29,sp=0,w=0), want=fault, got=pass ! 4521574251: (4521510536): Failed at 0x3fffad6b0000 (p=45,sp=0,w=0), want=fault, got=pass ! 4522258324: (4522194609): Failed at 0x3fffad7b0000 (p=61,sp=0,w=0), want=fault, got=pass ! This is because hash preload wrongly inserts the HPTE entry for subpage 0 without looking at the subpage protection information. Fix it by teaching should_hash_preload() not to preload if we have subpage protection configured for that range. It appears this has been broken since it was introduced in 2008. Fixes: fa28237cfcc5 ("[POWERPC] Provide a way to protect 4k subpages when using 64k pages") Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> [mpe: Rework into should_hash_preload() to avoid build fails w/SLICES=n] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hash_utils_64.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 8bbc9b7b001eaab8abf7e9e24edf1bb285c8d825 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri May 6 16:46:00 2016 +1000 powerpc/mm/hash64: Factor out hash preload psize check Currently we have a check in hash_preload() against the psize, which is only included when CONFIG_PPC_MM_SLICES is enabled. We want to expand this check in a subsequent patch, so factor it out to allow that. As a bonus it removes the #ifdef in the C code. Unfortunately we can't put this in the existing CONFIG_PPC_MM_SLICES block because it would require a forward declaration. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hash_utils_64.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) commit 925e2d1ded80fcc92210c9a9e5009887553dd83f Author: Suraj Jitindar Singh <sjitindarsingh@gmail.com> Date: Thu Apr 28 15:34:55 2016 +1000 powerpc: Update of_remove_property() call sites to remove null checking After obtaining a property from of_find_property() and before calling of_remove_property() most code checks to ensure that the property returned from of_find_property() is not null. The previous patch moved this check to the start of the function of_remove_property() in order to avoid the case where this check isn't done and a null value is passed. This ensures the check is always conducted before taking locks and attempting to remove the property. Thus it is no longer necessary to perform a check for null values before invoking of_remove_property(). Update of_remove_property() call sites in order to remove redundant checking for null property value as check is now performed within the of_remove_property function(). Signed-off-by: Suraj Jitindar Singh <sjitindarsingh@gmail.com> [mpe: Unbreak some lines which are just >80 chars for readability] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/machine_kexec.c | 18 +++++------------- arch/powerpc/kernel/machine_kexec_64.c | 9 ++------- arch/powerpc/platforms/pseries/mobility.c | 4 ++-- arch/powerpc/platforms/pseries/reconfig.c | 5 +---- 4 files changed, 10 insertions(+), 26 deletions(-) commit 201b3fe586361c0241105f6e3de2c4749010f897 Author: Suraj Jitindar Singh <sjitindarsingh@gmail.com> Date: Thu Apr 28 15:34:54 2016 +1000 drivers/of: Add check for null property in of_remove_property() The validity of the property input argument to of_remove_property() is never checked within the function and thus it is possible to pass a null value. It happens that this will be picked up in __of_remove_property() as no matching property of the device node will be found and thus an error will be returned, however once again there is no explicit check for a null value. By the time this is detected 2 locks have already been acquired which is completely unnecessary if the property to remove is null. Add an explicit check in the function of_remove_property() for a null property value and return -ENODEV in this case, this is consistent with what the previous return value would have been when the null value was not detected and passed to __of_remove_property(). By moving an explicit check for the property paramenter into the of_remove_property() function, this will remove the need to perform this check in calling code before invocation of the of_remove_property() function. Signed-off-by: Suraj Jitindar Singh <sjitindarsingh@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/of/base.c | 3 +++ 1 file changed, 3 insertions(+) commit b2ed059642875a699a195cb136b2e57e7e07cedf Author: Suraj Jitindar Singh <sjitindarsingh@gmail.com> Date: Thu Apr 28 15:53:45 2016 +1000 powerpc/pseries: Add null property check to pseries_discover_pic() The return value of of_get_property() isn't checked before it is passed to the strstr() function, if it happens that the return value is null then this will result in a null pointer being dereferenced. Add a check to see if the return value of of_get_property() is null and if it is continue straight on to the next node. Signed-off-by: Suraj Jitindar Singh <sjitindarsingh@gmail.com> Reviewed-by: Chris Smart <chris@distroguy.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/setup.c | 2 ++ 1 file changed, 2 insertions(+) commit 9e44754755528f78dbc3a5e64cd48dadf4773777 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Mon May 2 17:06:12 2016 +1000 powerpc/powernv/pci: Fix cfg_dbg() & replace with pr_devel() When cfg_dbg() is enabled (i.e. mapped to printk()), gcc produces errors as the __func__ parameter is missing (pnv_pci_cfg_read() has one); this adds the missing parameter. cfg_dbg() is just an inferior version of pr_devel() so use the latter instead. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/pci.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) commit 2f67798c1f9f35ba576ac0639b9b648b9b2033f6 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Mon May 2 14:54:29 2016 +1000 selftests/powerpc: Fix subpage_prot test to return !0 on failure It's helpful for automated testing if the test returns error codes back to the calling program. While we're here fix all the usages of %p to remove the double 0x, ie. %p already includes 0x. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> tools/testing/selftests/powerpc/mm/subpage_prot.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 438517ec78fa4e9db9892e749ed50e2a21f5f17f Author: Chris Smart <chris@distroguy.com> Date: Mon May 2 13:51:38 2016 +1000 selftests/powerpc: Test cp_abort during context switch Test that performing a copy paste sequence in userspace on P9 does not result in a leak of the copy into the paste of another process. This is based on Anton Blanchard's context_switch benchmarking code. It sets up two processes tied to the same CPU, one which copies and one which pastes. The paste should never succeed and the test fails if it does. This is a test for commit, "8a64904 powerpc: Add support for userspace P9 copy paste." Patch created with much assistance from Michael Neuling <mikey@neuling.org> Signed-off-by: Chris Smart <chris@distroguy.com> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/testing/selftests/powerpc/Makefile | 1 + .../selftests/powerpc/context_switch/.gitignore | 1 + .../selftests/powerpc/context_switch/Makefile | 10 ++ .../selftests/powerpc/context_switch/cp_abort.c | 110 +++++++++++++++++++++ tools/testing/selftests/powerpc/utils.h | 7 ++ 5 files changed, 129 insertions(+) commit e44c1b15cf32e33cd4521f7278333d448eda170b Author: Chris Smart <chris@distroguy.com> Date: Mon May 2 16:00:58 2016 +1000 powerpc: Remove unnecessary CONFIG_SMP #ifdefs The code in machine_restart/power_off/halt() includes #ifdefs around calls to smp_send_stop(), however these are not required as include/linux/smp.h includes an empty version of this function for CONFIG_SMP=n builds. Signed-off-by: Chris Smart <chris@distroguy.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/setup-common.c | 6 ------ 1 file changed, 6 deletions(-) commit c415c9cb8ab2c852a56f5d592057fc14c585301d Author: Rashmica Gupta <rashmicy@gmail.com> Date: Tue Apr 12 15:33:58 2016 +1000 powerpc: Remove unused remnants from A2 cpu Support for the A2 cpu was removed in commit fb5a515704d7 ("powerpc: Remove platforms/wsp and associated pieces"), and the externs: __setup_cpu_a2 and __restore_cpu_a2 are still around and unused, so remove them. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/cputable.c | 2 -- 1 file changed, 2 deletions(-) commit 62ccf5bf1f4704986844440069df70b6509a9213 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Mon May 2 18:26:07 2016 +0530 powerpc/mm/slice: Remove slice_mm_new_context() The usage in mm mmu_context_nohash.c is bogus, because we set the context.id value to MMU_NO_CONTEXT 4 lines previously in the same function, meaning slice_mm_new_context() will always be true. The book3s 64 usage was removed in the previous commit. So remove it as unused. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/page_64.h | 3 --- arch/powerpc/mm/mmu_context_nohash.c | 3 +-- 2 files changed, 1 insertion(+), 5 deletions(-) commit 2d566537dd2c69bd6898ef5d95ecccdfbab97eef Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Mon May 2 16:21:50 2016 +0530 powerpc/mm/subpage: Initialise user psize correctly As part of the radix support we switched Book3s64 to use a value of ~0 for MMU_NO_CONTEXT. That is because id 0 is special on radix. However that broke the logic in init_new_context(). The code there needs to differentiate between a newly allocated context and one inherited via fork. Previously it worked because a newly allocated context has an id of zero (because it was just memset() to zero), which used to match MMU_NO_CONTEXT, and therefore slice_mm_new_context() did the right thing. Instead check against a context.id value of zero instead of using slice_mm_new_context(). Without this patch we never call slice_set_user_psize(), and end up with a slice psize value of zero and we always end up using 4K HPTE. Fixes: 1a472c9dba6b ("powerpc/mm/radix: Add tlbflush routines") Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/mmu_context_book3s64.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit bb03efe2b7409d83a279ea1ef2317c26dbfb0c6c Author: Valentin Rothberg <valentinrothberg@gmail.com> Date: Tue May 3 08:59:27 2016 +0200 powerpc/mm/radix: Fix CONFIG_PPC_MMU_STD_64 typo It's CONFIG_PPC_STD_MMU_64 not ... CONFIG_PPC_MMU_STD_64. Fixes: 11ffc1cfa4c2 ("powerpc/mm/radix: Use STD_MMU_64 to properly isolate hash related code") Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/mce_power.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 69dfbaeb657bad13dddb3204603490206b859a7e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:33 2016 +1000 powerpc/mm/radix: Document software bits for radix Add #defines for Power ISA 3.0 software defined bits. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 17a3dd2f5fc75fc12d0a2ebf05327cf965bdf84b Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:32 2016 +1000 powerpc/mm/radix: Use firmware feature to enable Radix MMU We use the existing "ibm,pa-features" device-tree property to enable Radix MMU mode. This means we default to hash mode unless firmware tells us it's OK to start using Radix mode. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/prom.c | 1 + 1 file changed, 1 insertion(+) commit ab62476240d59a9d7d78ca5ff32499dd50db2069 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:31 2016 +1000 powerpc/mm/radix: Add THP support for 4K linux page size This adds THP support for 4K Linux page size config with radix. We still don't do THP with 4K Linux page size and hash page table. Hash page table needs a 16MB hugepage and we can't do THP with 16MM hugepage and 4K Linux page size. We add missing functions to 4K hash config to get it to build and hash__has_transparent_hugepage() makes sure we don't enable THP for 4K hash config. To catch wrong usage of THP related with 4K config, we add BUG() in those dummy functions we added to get it compile. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 59 ++++++++++++++++++++++++ arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 25 ---------- arch/powerpc/include/asm/book3s/64/pgtable.h | 22 +++++++++ arch/powerpc/platforms/Kconfig.cputype | 2 +- 4 files changed, 82 insertions(+), 26 deletions(-) commit bde3eb6222e49673d2ee9dfdc6ab6e7b6ff69e91 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:30 2016 +1000 powerpc/mm/radix: Add radix THP callbacks The deposited pgtable_t is a pte fragment hence we cannot use page->lru for linking then together. We use the first two 64 bits for pte fragment as list_head type to link all deposited fragments together. On withdraw we properly zero then out. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 2 + arch/powerpc/include/asm/book3s/64/pgtable.h | 16 ++++ arch/powerpc/include/asm/book3s/64/radix.h | 22 +++++ arch/powerpc/mm/pgtable-book3s64.c | 2 +- arch/powerpc/mm/pgtable-radix.c | 117 +++++++++++++++++++++++ 5 files changed, 158 insertions(+), 1 deletion(-) commit 3df33f12be2f6fa88dff12564ab1d069482e3224 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:29 2016 +1000 powerpc/mm/thp: Abstraction for THP functions Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-64k.h | 23 +++- arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 42 +------ arch/powerpc/include/asm/book3s/64/pgtable.h | 83 +++++++++++--- arch/powerpc/mm/Makefile | 2 +- arch/powerpc/mm/pgtable-book3s64.c | 118 +++++++++++++++++++ arch/powerpc/mm/pgtable-hash64.c | 137 +++-------------------- 6 files changed, 226 insertions(+), 179 deletions(-) commit 6a1ea36260f69f1aea85bbf8afcd6a8c193485b9 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:28 2016 +1000 powerpc/mm: THP is only available on hash64 as of now Only code movement in this patch. No functionality change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 24 +- arch/powerpc/mm/pgtable-hash64.c | 358 ++++++++++++++++++++++++++ arch/powerpc/mm/pgtable_64.c | 359 --------------------------- 3 files changed, 369 insertions(+), 372 deletions(-) commit c0a6c719d2a153abe5d8c3b42f0379a5bd752517 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:27 2016 +1000 powerpc/mm/radix: Add hugetlb support 4K page size We have hugepage at the pmd level with 4K radix config. Hence we don't need to use hugepd format with radix. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 22 +----------- arch/powerpc/include/asm/book3s/64/pgtable-4k.h | 46 +++++++++++++++++++++++++ 2 files changed, 47 insertions(+), 21 deletions(-) commit 43a5c684270ee9b5b13c91ec048831dd5b7e0cdc Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:26 2016 +1000 powerpc/mm/radix: Make sure swapper pgdir is properly aligned With 4K page size radix config our level 1 page table size is 64K and it should be naturally aligned. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/head_64.S | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 484837601d4dd048d1f8d2cedd39934bb3ad6d59 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:25 2016 +1000 powerpc/mm: Add radix support for hugetlb Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hugetlb-radix.h | 14 ++++ arch/powerpc/include/asm/hugetlb.h | 14 ++++ arch/powerpc/mm/Makefile | 1 + arch/powerpc/mm/hugetlbpage-radix.c | 87 ++++++++++++++++++++++ arch/powerpc/mm/hugetlbpage.c | 8 +- arch/powerpc/mm/tlb-radix.c | 9 +++ 6 files changed, 132 insertions(+), 1 deletion(-) commit 2f5f0dfd1e5f9840560e85ad26cb4a6f06c19e07 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:24 2016 +1000 powerpc/mm: Fix vma_mmu_pagesize() for radix Radix doesn't use the slice framework to find the page size. Hence use vma to find the page size. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hugetlbpage.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 5ed7ecd08a0807d6d616c3d958402f9c723bb048 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:23 2016 +1000 powerpc/mm: pte_frag abstraction In this patch we make the number of pte fragments per level 4 page table page a variable. Radix level 4 table size is 256 bytes and hence we can have 256 fragments per level 4 page. We don't update the fragment count in this patch. We need to do performance measurements to find the right value for fragment count. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 2 ++ arch/powerpc/include/asm/book3s/64/hash-64k.h | 4 ++-- arch/powerpc/include/asm/book3s/64/pgtable.h | 6 ++++++ arch/powerpc/mm/hash_utils_64.c | 3 +++ arch/powerpc/mm/pgtable-radix.c | 5 +++++ arch/powerpc/mm/pgtable_64.c | 4 ++++ 6 files changed, 22 insertions(+), 2 deletions(-) commit a3dece6d69b0ad21b64104dff508c67a1a1f14dd Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:22 2016 +1000 powerpc/radix: Update MMU cache With radix there is no MMU cache. Hence we don't need to do anything in update_mmu_cache(). Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/mem.c | 2 ++ 1 file changed, 2 insertions(+) commit d6a9996e84ac4beb7713e9485f4563e100a9b03e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:21 2016 +1000 powerpc/mm: vmalloc abstraction in preparation for radix The vmalloc range differs between hash and radix config. Hence make VMALLOC_START and related constants a variable which will be runtime initialized depending on whether hash or radix mode is active. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> [mpe: Fix missing init of ioremap_bot in pgtable_64.c for ppc64e] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 14 +++--- arch/powerpc/include/asm/book3s/64/pgtable.h | 15 ++++-- arch/powerpc/include/asm/book3s/64/radix.h | 68 ++++++++++++++++++++++++++++ arch/powerpc/kernel/pci_64.c | 3 +- arch/powerpc/mm/hash_utils_64.c | 8 ++++ arch/powerpc/mm/pgtable-radix.c | 7 +++ arch/powerpc/mm/pgtable_64.c | 15 +++++- arch/powerpc/mm/slb_low.S | 2 +- 8 files changed, 118 insertions(+), 14 deletions(-) commit 4dfb88ca9b66690d21030ccacc1cca73db90655e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:20 2016 +1000 powerpc/mm: Update pte filter for radix Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/pgtable.c | 3 +++ 1 file changed, 3 insertions(+) commit a2f41eb99208adf4732529c4df1fd12b39f4c333 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:19 2016 +1000 powerpc/mm: Add radix pgalloc details Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgalloc.h | 34 ++++++++++++++++++++++++---- arch/powerpc/include/asm/book3s/64/pgtable.h | 10 ++++++-- arch/powerpc/mm/hash_utils_64.c | 7 ++++++ arch/powerpc/mm/pgtable-radix.c | 5 +++- arch/powerpc/mm/pgtable_64.c | 6 +++++ 5 files changed, 55 insertions(+), 7 deletions(-) commit 934828edfadc43be07e53429ce501741bedf4a5e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:18 2016 +1000 powerpc/mm: Make 4K and 64K use pte_t for pgtable_t This patch switches 4K Linux page size config to use pte_t * type instead of struct page * for pgtable_t. This simplifies the code a lot and helps in consolidating both 64K and 4K page allocator routines. The changes should not have any impact, because we already store physical address in the upper level page table tree and that implies we already do struct page * to physical address conversion. One change to note here is we move the pgtable_page_dtor() call for nohash to pte_fragment_free_mm(). The nohash related change is due to the related changes in pgtable_64.c. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgalloc.h | 147 +++++++-------------------- arch/powerpc/include/asm/nohash/64/pgalloc.h | 38 +------ arch/powerpc/include/asm/page.h | 10 +- arch/powerpc/mm/pgtable_64.c | 2 +- 4 files changed, 52 insertions(+), 145 deletions(-) commit 74701d5947a6fb38ece37c1ff1e5a77c36ee7b9c Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:17 2016 +1000 powerpc/mm: Rename function to indicate we are allocating fragments Only code cleanup. No functionality change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgalloc.h | 12 ++++++------ arch/powerpc/include/asm/nohash/64/pgalloc.h | 12 ++++++------ arch/powerpc/mm/pgtable_64.c | 21 ++++----------------- 3 files changed, 16 insertions(+), 29 deletions(-) commit bcbe7f777eb396f9bbf4cb1cab3b206f50881191 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:16 2016 +1000 powerpc/mm: Simplify the code dropping 4-level table #ifdef Simplify the code by dropping 4-level page table #ifdef. We are always 4-level now. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgalloc.h | 57 +++++++++------------------- 1 file changed, 18 insertions(+), 39 deletions(-) commit 27209206a60fa6ffc92e8d9886ae32abaad5b442 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:15 2016 +1000 powerpc/mm: Revert changes made to nohash pgalloc-64.h This reverts pgalloc related changes WRT implementing 4-level page table for 64K Linux page size and storing of physical address in higher level page tables since they are only applicable to book3s64 variant and we now have a separate copy for book3s64. This helps to keep these headers simpler. Cc: Scott Wood <scottwood@freescale.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/nohash/64/pgalloc.h | 42 +++++++--------------------- arch/powerpc/include/asm/nohash/64/pgtable.h | 3 -- 2 files changed, 10 insertions(+), 35 deletions(-) commit 75a9b8a6c2533064a8d5d090ada7bf9e4c4c84c1 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:14 2016 +1000 powerpc/mm: Copy pgalloc (part 2) This moves the nohash variant of pgalloc headers to nohash/ directory Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/32/pgalloc.h | 6 +- arch/powerpc/include/asm/book3s/64/pgalloc.h | 17 +- arch/powerpc/include/asm/book3s/pgalloc.h | 19 ++ arch/powerpc/include/asm/nohash/32/pgalloc.h | 109 +++++++++++ arch/powerpc/include/asm/nohash/64/pgalloc.h | 266 +++++++++++++++++++++++++++ arch/powerpc/include/asm/nohash/pgalloc.h | 23 +++ arch/powerpc/include/asm/pgalloc-32.h | 109 ----------- arch/powerpc/include/asm/pgalloc-64.h | 266 --------------------------- arch/powerpc/include/asm/pgalloc.h | 19 +- 9 files changed, 434 insertions(+), 400 deletions(-) commit 101ad5c65ef2631f402643c760574a6f0f7f64d0 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:13 2016 +1000 powerpc/mm: Make a copy of pgalloc.h for 32 and 64 book3s This patch start to make a book3s variant for pgalloc headers. We have multiple book3s specific changes such as: * 4 level page table * store physical address in higher level table * use pte_t * for pgtable_t Having a book3s64 specific variant helps to keep code simpler and remove lots of #ifdef around code. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/32/pgalloc.h | 109 +++++++++++ arch/powerpc/include/asm/book3s/64/pgalloc.h | 266 +++++++++++++++++++++++++++ 2 files changed, 375 insertions(+) commit b5dcc6096971b7c11b443b79ae8b69ccb01ec04e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:12 2016 +1000 powerpc/mm/radix: Update PTCR on secondary CPUs Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hash_utils_64.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 7a0eedeedd5d192f64fd4cd46634e409cb7a513b Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:11 2016 +1000 powerpc/mm/radix: Pick the address layout for radix config Hash needs special get_unmapped_area() handling because of limitations around base page size, so we have to set HAVE_ARCH_UNMAPPED_AREA. With radix we don't have such restrictions, so we could use the generic code. But because we've set HAVE_ARCH_UNMAPPED_AREA (for hash), we have to re-implement the same logic as the generic code. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/mmap.c | 109 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) commit 177ba7c647f37bc3f31667192059ee794347d79d Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:10 2016 +1000 powerpc/mm/radix: Limit paca allocation in radix On return from RTAS we access the paca variables and we have 64 bit disabled. This requires us to limit paca in 32 bit range. Fix this by setting ppc64_rma_size to first_memblock_size/1G range. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/pgtable-radix.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit 764041e0f43cc7846f6d8eb246d65b53cc06c764 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:09 2016 +1000 powerpc/mm/radix: Add checks in slice code to catch radix usage Radix doesn't need slice support. Catch incorrect usage of slice code when radix is enabled. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/slice.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit d8c476eeb697c9aac46b390e9cbd7af7032814f1 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:08 2016 +1000 powerpc/mm/radix: Isolate hash table function from pseries guest code Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/lpar.c | 14 +++++++++++--- arch/powerpc/platforms/pseries/lparcfg.c | 3 ++- 2 files changed, 13 insertions(+), 4 deletions(-) commit caca285e5ab4a7a19fede51688106ceed6fc45dd Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:07 2016 +1000 powerpc/mm/radix: Use STD_MMU_64 to properly isolate hash related code We also use MMU_FTR_RADIX to branch out from code path specific to hash. No functionality change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/entry_64.S | 7 +++++-- arch/powerpc/kernel/exceptions-64s.S | 28 +++++++++++++++++++++++----- arch/powerpc/kernel/machine_kexec_64.c | 6 ++++-- arch/powerpc/kernel/mce_power.c | 10 ++++++++++ arch/powerpc/kernel/process.c | 15 +++++++++------ arch/powerpc/xmon/xmon.c | 2 +- 6 files changed, 52 insertions(+), 16 deletions(-) commit d30a2b47d4c2b75573d93f60655d48ba8e3ed2b3 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 11:23:22 2016 +0200 MIPS: do away with ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB This replaces: - "select ARCH_REQUIRE_GPIOLIB" with "select GPIOLIB" as this can now be selected directly. - "select ARCH_WANT_OPTIONAL_GPIOLIB" with no dependency: GPIOLIB is now selectable by everyone, so we need not declare our intent to select it. When ordering the symbols the following rationale was used: if the selects were in alphabetical order, I moved select GPIOLIB to be in alphabetical order, but if the selects were not maintained in alphabetical order, I just replaced "select ARCH_REQUIRE_GPIOLIB" with "select GPIOLIB". Cc: Michael Büsch <m@bues.ch> Cc: linux-mips@linux-mips.org Acked-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/mips/Kconfig | 32 +++++++++++++++----------------- arch/mips/alchemy/Kconfig | 2 +- arch/mips/pic32/Kconfig | 2 +- 3 files changed, 17 insertions(+), 19 deletions(-) commit a90295b4884f7467f4d5a4ffccc6facdf3ba9fe2 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Mon May 9 19:59:58 2016 -0400 gpio: zevio: make it explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_ZEVIO drivers/gpio/Kconfig: bool "LSI ZEVIO SoC memory mapped GPIOs" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. We explicitly disallow a driver unbind, since that doesn't have a sensible use case anyway, and it allows us to drop the ".remove" code for non-modular drivers. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Fabian Vogt <fabian@ritter-vogt.de> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-zevio.c | 21 +++------------------ 1 file changed, 3 insertions(+), 18 deletions(-) commit a8ed87c92adf1fd45142323e04f15b522117d575 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:06 2016 +1000 powerpc/mm/radix: Add MMU_FTR_RADIX We are going to add asm changes in the follow up patches. Add the feature bit now so that we can get it all build. mpe: When CONFIG_PPC_RADIX_MMU=n we omit MMU_FTR_RADIX from the MMU_FTRS_POSSIBLE mask. This allows the compiler to work out that those checks will always be false and so the code can be elided completely. Note we do *not* define MMU_FTR_RADIX to 0 in the RADIX_MMU=n case, because that doesn't work with the ASM_FTR patching. In particular an IF_SET section will result in a mask and value of zero, which is always true, meaning the section *won't* be patched, which is the opposite of what we want. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu.h | 3 ++- arch/powerpc/include/asm/mmu.h | 11 ++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) commit 52ad90531aaebf101699974cd7fb7d7def729078 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Mon May 9 19:59:57 2016 -0400 gpio: timberdale: make it explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_TIMBERDALE drivers/gpio/Kconfig: bool "Support for timberdale GPIO IP" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. We explicitly disallow a driver unbind, since that doesn't have a sensible use case anyway, and it allows us to drop the ".remove" code for non-modular drivers. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-timberdale.c | 35 +++++------------------------------ 1 file changed, 5 insertions(+), 30 deletions(-) commit 3b52bb960ec66f3788697e42e72ec3fa0e7f8178 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Mon May 9 19:59:56 2016 -0400 gpio: stmpe: make it explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_STMPE drivers/gpio/Kconfig: bool "STMPE GPIOs" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. We explicitly disallow a driver unbind, since that doesn't have a sensible use case anyway, and it allows us to drop the ".remove" code for non-modular drivers. Curiously, this driver was using subsys_initcall since day one, so we don't have the "normal" module_init replacement in this change like we've done in other similar driver updates. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Rabin Vincent <rabin.vincent@stericsson.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-stmpe.c | 31 +++++-------------------------- 1 file changed, 5 insertions(+), 26 deletions(-) commit 6a5ead91d45d091f6d60b20d47e595a1b9e25d67 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Mon May 9 19:59:55 2016 -0400 gpio: sodaville: make it explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_SODAVILLE drivers/gpio/Kconfig: bool "Intel Sodaville GPIO support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. We explicitly disallow a driver unbind, since that doesn't have a sensible use case anyway, and it allows us to drop the ".remove" code for non-modular drivers. Since module_pci_driver() uses the same init level as the builtin_pci_driver() does, there is no init ordering change caused by this commit. We don't replace module.h with init.h since the file already has that. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Hans J. Koch <hjk@linutronix.de> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-sodaville.c | 28 ++++++---------------------- 1 file changed, 6 insertions(+), 22 deletions(-) commit 773edeadf672546cd554e0797fc02a9e6edf01ae Author: Michael Ellerman <mpe@ellerman.id.au> Date: Wed May 11 15:30:47 2016 +1000 powerpc/mm: Add mask of possible MMU features Follow the example of the cpu feature code, and add a mask of possible MMU features, MMU_FTRS_POSSIBLE. This is used in mmu_has_feature(), which allows the possible mask to act as a shortcut for any features that are not possible, but still allows the feature bit itself to be defined. We will use this in the next commit to allow MMU_FTR_RADIX checks to be elided when MMU_FTR_RADIX is not possible. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/mmu.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit 9697643ff3edca036e8843235cd6e4d598a50e63 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed May 4 10:21:53 2016 +0200 pinctrl: sh-pfc: Let gpio_chip.to_irq() return zero on error Currrently the gpio_chip.to_irq() callback returns -ENOSYS on error, which causes bad interactions with the serial_mctrl_gpio helpers. mctrl_gpio_init() returns -ENOSYS if GPIOLIB is not enabled, which is intended to be ignored by its callers. However, ignoring -ENOSYS when it was caused by a gpiod_to_irq() failure will lead to a crash later: Unable to handle kernel paging request at virtual address ffffffde ... PC is at mctrl_gpio_set+0x14/0x78 Fix this by returning zero instead, like gpiochip_to_irq() does. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/sh-pfc/gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d18a3f0f0809f6c71f1f6e9e268ee904ce0b588 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Tue May 3 00:17:32 2016 +0530 pinctrl: tegra: avoid parked_reg and parked_bank NVIDIA's Tegra210 support the park bit to make pinmux configuration enable/disable. If parked bit is 1 then configuration does not apply and if it is 0 then pinmux configuration applies. This is to support to avoid any glitch in pinmux configurations. The parked bit is part of mux register and mux bank and hence it is not required to have member for the parked_reg and parked bank very similar to other bit field of the same register. Remove the need of the parked register and parked bank and get whether parked function supported or not by parked_bit. This is to make the parked bit handling same as other fields of mux registers. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/tegra/pinctrl-tegra.c | 8 ++++---- drivers/pinctrl/tegra/pinctrl-tegra.h | 6 +----- drivers/pinctrl/tegra/pinctrl-tegra114.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra124.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra20.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra210.c | 4 +--- drivers/pinctrl/tegra/pinctrl-tegra30.c | 4 ++-- 7 files changed, 14 insertions(+), 20 deletions(-) commit 07f8ab255fcc0bce1fabc8fb35ace4f0f5d2ac67 Author: Gavin Shan <gwshan@linux.vnet.ibm.com> Date: Wed May 11 11:15:55 2016 +1000 KVM: PPC: Book3S HV: Fix build error in book3s_hv.c When CONFIG_KVM_XICS is enabled, CPU_UP_PREPARE and other macros for CPU states in linux/cpu.h are needed by arch/powerpc/kvm/book3s_hv.c. Otherwise, build error as below is seen: gwshan@gwshan:~/sandbox/l$ make arch/powerpc/kvm/book3s_hv.o : CC arch/powerpc/kvm/book3s_hv.o arch/powerpc/kvm/book3s_hv.c: In function ‘kvmppc_cpu_notify’: arch/powerpc/kvm/book3s_hv.c:3072:7: error: ‘CPU_UP_PREPARE’ \ undeclared (first use in this function) This fixes the issue introduced by commit <6f3bb80944> ("KVM: PPC: Book3S HV: kvmppc_host_rm_ops - handle offlining CPUs"). Fixes: 6f3bb8094414 Cc: stable@vger.kernel.org # v4.6 Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Reviewed-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Paul Mackerras <paulus@samba.org> arch/powerpc/kvm/book3s_hv.c | 1 + 1 file changed, 1 insertion(+) commit eb8b0560160d8363bc40ca05a75ef144cebaae72 Author: Paul Mackerras <paulus@ozlabs.org> Date: Thu May 5 16:17:10 2016 +1000 KVM: PPC: Fix emulated MMIO sign-extension When the guest does a sign-extending load instruction (such as lha or lwa) to an emulated MMIO location, it results in a call to kvmppc_handle_loads() in the host. That function sets the vcpu->arch.mmio_sign_extend flag and calls kvmppc_handle_load() to do the rest of the work. However, kvmppc_handle_load() sets the mmio_sign_extend flag to 0 unconditionally, so the sign extension never gets done. To fix this, we rename kvmppc_handle_load to __kvmppc_handle_load and add an explicit parameter to indicate whether sign extension is required. kvmppc_handle_load() and kvmppc_handle_loads() then become 1-line functions that just call __kvmppc_handle_load() with the extra parameter. Reported-by: Bin Lu <lblulb@linux.vnet.ibm.com> Signed-off-by: Paul Mackerras <paulus@ozlabs.org> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Paul Mackerras <paulus@samba.org> arch/powerpc/kvm/powerpc.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) commit ade3ac660a1813344bcf4fe58b9ac5fbe7c0ed4b Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 29 14:57:23 2016 +1000 KVM: PPC: Fix debug macros When XICS_DBG is enabled, gcc produces format errors. This fixes formats to match passed values types. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Paul Mackerras <paulus@samba.org> arch/powerpc/kvm/book3s_xics.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 11dd6ac0254ed9a2b6994e22c903192edd0fa8fc Author: Laurent Vivier <lvivier@redhat.com> Date: Fri Apr 8 18:05:00 2016 +0200 KVM: PPC: Book3S PR: Manage single-step mode Until now, when we connect gdb to the QEMU gdb-server, the single-step mode is not managed. This patch adds this, only for kvm-pr: If KVM_GUESTDBG_SINGLESTEP is set, we enable single-step trace bit in the MSR (MSR_SE) just before the __kvmppc_vcpu_run(), and disable it just after. In kvmppc_handle_exit_pr, instead of routing the interrupt to the guest, we return to host, with KVM_EXIT_DEBUG reason. Signed-off-by: Laurent Vivier <lvivier@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Paul Mackerras <paulus@samba.org> arch/powerpc/kvm/book3s_pr.c | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) commit c9c6837d39311b0cc14cdbe7c18e815ab44aefb1 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 23:30:01 2016 +0200 kbuild: move -Wunused-const-variable to W=1 warning level gcc-6 started warning by default about variables that are not used anywhere and that are marked 'const', generating many false positives in an allmodconfig build, e.g.: arch/arm/mach-davinci/board-da830-evm.c:282:20: warning: 'da830_evm_emif25_pins' defined but not used [-Wunused-const-variable=] arch/arm/plat-omap/dmtimer.c:958:34: warning: 'omap_timer_match' defined but not used [-Wunused-const-variable=] drivers/bluetooth/hci_bcm.c:625:39: warning: 'acpi_bcm_default_gpios' defined but not used [-Wunused-const-variable=] drivers/char/hw_random/omap-rng.c:92:18: warning: 'reg_map_omap4' defined but not used [-Wunused-const-variable=] drivers/devfreq/exynos/exynos5_bus.c:381:32: warning: 'exynos5_busfreq_int_pm' defined but not used [-Wunused-const-variable=] drivers/dma/mv_xor.c:1139:34: warning: 'mv_xor_dt_ids' defined but not used [-Wunused-const-variable=] This is similar to the existing -Wunused-but-set-variable warning that was added in an earlier release and that we disable by default now and only enable when W=1 is set, so it makes sense to do the same here. Once we have eliminated the majority of the warnings for both, we can put them back into the default list. We probably want this in backport kernels as well, to allow building them with gcc-6 without introducing extra warnings. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Olof Johansson <olof@lixom.net> Acked-by: Lee Jones <lee.jones@linaro.org> Cc: stable@vger.kernel.org Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 5 +++-- scripts/Makefile.extrawarn | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) commit 165cccc8437704d9f41eae2946774bdf2966245f Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Mon May 9 09:59:50 2016 +0800 drm/hisilicon: Fix DRM_INFO printed issue This patch fixed the bellow no DRM_INFO is printed issue: if (!delay_count) DRM_INFO("phylock and phystopstateclklane is not ready.\n"); There will some printed issues with above info, under certain circumstances: If ((BIT(0) | BIT(2)) & val) is never true, break will not happen and delay_count will be max u32 value (?), and no DRM_INFO is printed. Also if ((BIT(0) | BIT(2)) & val) is true at the last possible loop round, break happens, but now delay_count is already zero ( because of earlier delay_count-- ) and DRM_INFO is erroneously printed. Thanks to Juha Leppänen, he reports to me this issue. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Reported-by: Juha Leppänen <juha_efku@dnainternet.net> drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 12cb4c87aa587ff476ffc71120f2dc5d2e857256 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sun May 8 17:48:55 2016 +0800 drm/hisilicon: Make kirin_drm_unbind sufficient Remove deprecated drm_put_dev. Clean up everything needed in unbind. Thanks to Daniel Vetter, this issue is reported by him. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reported-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit b93c846273b9eda820f618a07d8871e20639e0b9 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri May 6 10:28:41 2016 +0200 drm/hisilicon: Use drm_connector_register_all Use drm_connector_register_all helper to register connectors. Cc: Xinliang Liu <xinliang.liu@linaro.org> Cc: Xinwei Kong <kong.kongxinwei@hisilicon.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 31 +------------------------ 1 file changed, 1 insertion(+), 30 deletions(-) commit 61462c8a6b140fe2f93cb911684837e05950e680 Author: Kees Cook <keescook@chromium.org> Date: Tue May 10 10:55:49 2016 -0700 arm64: kernel: Fix incorrect brk randomization This fixes two issues with the arm64 brk randomziation. First, the STACK_RND_MASK was being used incorrectly. The original code was: unsigned long range_end = base + (STACK_RND_MASK << PAGE_SHIFT) + 1; STACK_RND_MASK is 0x7ff (32-bit) or 0x3ffff (64-bit), with 4K pages where PAGE_SHIFT is 12: #define STACK_RND_MASK (test_thread_flag(TIF_32BIT) ? \ 0x7ff >> (PAGE_SHIFT - 12) : \ 0x3ffff >> (PAGE_SHIFT - 12)) This means the resulting offset from base would be 0x7ff0001 or 0x3ffff0001, which is wrong since it creates an unaligned end address. It was likely intended to be: unsigned long range_end = base + ((STACK_RND_MASK + 1) << PAGE_SHIFT) Which would result in offsets of 0x800000 (32-bit) and 0x40000000 (64-bit). However, even this corrected 32-bit compat offset (0x00800000) is much smaller than native ARM's brk randomization value (0x02000000): unsigned long arch_randomize_brk(struct mm_struct *mm) { unsigned long range_end = mm->brk + 0x02000000; return randomize_range(mm->brk, range_end, 0) ? : mm->brk; } So, instead of basing arm64's brk randomization on mistaken STACK_RND_MASK calculations, just use specific corrected values for compat (0x2000000) and native arm64 (0x40000000). Reviewed-by: Jon Medhurst <tixy@linaro.org> Signed-off-by: Kees Cook <keescook@chromium.org> [will: use is_compat_task() as suggested by tixy] Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/process.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 0097852c302aca943a8b76f7f85e133af6e1701a Merge: 9d9b7ee a1dcbd1 Author: Thomas Gleixner <tglx@linutronix.de> Date: Wed May 11 12:06:25 2016 +0200 Merge tag 'irqchip-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms into irq/core Pull irqchip updates for Linux 4.7 from Marc Zyngier - Layerscape SCFG MSI controller support - LPC32xx interrupt controller support - RPi irqchip support on arm64 - GICv2 cleanup - GICv2 and GICv3 bug fixes commit 1b0d5287dafc7651af1d55cf47209209f79a964b Author: Duc Dang <dhdang@apm.com> Date: Tue May 3 00:53:41 2016 -0700 gpio: dwapb: Add ACPI device ID for DWAPB GPIO controller on X-Gene platforms This patch enables DWAPB GPIO controller support on X-Gene platforms in ACPI boot mode. Signed-off-by: Duc Dang <dhdang@apm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-dwapb.c | 1 + 1 file changed, 1 insertion(+) commit b923c6c62981cec5e2d2187fd700c2fc4386fc45 Author: Mathieu OTHACEHE <m.othacehe@gmail.com> Date: Tue May 10 09:08:48 2016 +0200 USB: serial: ti_usb_3410_5052: add MOXA UPORT 11x0 support Add support for : - UPort 1110 : 1 port RS-232 USB to Serial Hub. - UPort 1130 : 1 port RS-422/485 USB to Serial Hub. - UPort 1130I : 1 port RS-422/485 USB to Serial Hub with Isolation. - UPort 1150 : 1 port RS-232/422/485 USB to Serial Hub. - UPort 1150I : 1 port RS-232/422/485 USB to Serial Hub with Isolation. These devices are based on TI 3410 chip. Signed-off-by: Mathieu OTHACEHE <m.othacehe@gmail.com> [johan: fix rs485-only check ] Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/ti_usb_3410_5052.c | 55 +++++++++++++++++++++++++++++++++-- drivers/usb/serial/ti_usb_3410_5052.h | 8 +++++ 2 files changed, 60 insertions(+), 3 deletions(-) commit f228b494e56d949be8d8ea09d4f973d1979201bf Author: Julien Grall <julien.grall@arm.com> Date: Tue May 10 15:40:31 2016 +0100 arm64: cpuinfo: Missing NULL terminator in compat_hwcap_str The loop that browses the array compat_hwcap_str will stop when a NULL is encountered, however NULL is missing at the end of array. This will lead to overrun until a NULL is found somewhere in the following memory. In reality, this works out because the compat_hwcap2_str array tends to follow immediately in memory, and that *is* terminated correctly. Furthermore, the unsigned int compat_elf_hwcap is checked before printing each capability, so we end up doing the right thing because the size of the two arrays is less than 32. Still, this is an obvious mistake and should be fixed. Note for backporting: commit 12d11817eaafa414 ("arm64: Move /proc/cpuinfo handling code") moved this code in v4.4. Prior to that commit, the same change should be made in arch/arm64/kernel/setup.c. Fixes: 44b82b7700d0 "arm64: Fix up /proc/cpuinfo" Cc: <stable@vger.kernel.org> # v3.19+ (but see note above prior to v4.4) Signed-off-by: Julien Grall <julien.grall@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/cpuinfo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b22ef2a0979f2b91cfeeabb086e4d665183a93a1 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon May 2 22:53:24 2016 +0530 pinctrl: tegra: Correctly check the supported configuration The pincontrol registers of Tegra chips has multiple filed per registers. There is two type of registers mux and drive. All configurations belongs to one of these registers. If any configurations are supported then <config>_bit is set to bit position of these registers otherwise -1 to not support it. The member is defined as s32 <config>_bit:6; So if config is not supported ifor given SoC then it is set to -1 in soc pinmmux table. In common driver code, to find out that given config is supported or not, it is checked as: s8 bit = <config>_bit; if (bit > 31) { /* Not supported config */ } But in this case, bit is s8 and hence for non supporting it is -1. Correct the check as: if (bit < 0) { /* Not supported config */ } Fixes: e4c02dced975cb ("pinctrl: tegra: use signed bitfields for optional fields") Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/tegra/pinctrl-tegra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a1dcbd11d09be1cb357b2f217c0eaa1461128da0 Author: Eric Anholt <eric@anholt.net> Date: Wed Apr 13 13:28:43 2016 -0700 irqchip/bcm2836: Use a more generic memory barrier call dsb() requires an argument on arm64, so we needed to add "sy". Instead, take this opportunity to switch to the same smp_wmb() call that gic uses for its IPIs. This is a less strong barrier than we were doing before (dmb(ishst) compared to dsb(sy)), but it seems to be the correct one. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-bcm2836.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cb290d827eb0378447095093b4ea712482d31ae8 Author: Eric Anholt <eric@anholt.net> Date: Wed Apr 13 13:28:42 2016 -0700 irqchip/bcm2836: Fix compiler warning on 64-bit build Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-bcm2836.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0dc17be87647cd4c891e748a0753ad0606dc5775 Author: Eric Anholt <eric@anholt.net> Date: Wed Apr 13 13:28:41 2016 -0700 irqchip/bcm2836: Drop smp_set_ops on arm64 builds For arm64, the bootloader will instead be implementing the spin-table enable method. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-bcm2836.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit d6490461a102094891d8a2712c51365f86ac1a40 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:45 2016 +0100 irqchip/gic: Add helper functions for GIC setup and teardown Move the code that sets-up a GIC via device-tree into it's own function and add a generic function for GIC teardown that can be used for both device-tree and ACPI to unmap the GIC memory. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 61 ++++++++++++++++++++++++++++++++--------------- 1 file changed, 42 insertions(+), 19 deletions(-) commit f673b9b5cb5453fa14032d99edd55f49ac3980cc Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:44 2016 +0100 irqchip/gic: Store GIC configuration parameters Store the GIC configuration parameters in the GIC chip data structure. This will allow us to simplify the code by reducing the number of parameters passed between functions. Update the __gic_init_bases() function so that we only need to pass a pointer to the GIC chip data structure and no longer need to pass the GIC index in order to look-up the chip data. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 114 ++++++++++++++++++++++++++-------------------- 1 file changed, 65 insertions(+), 49 deletions(-) commit 6e5b5924d9a897062527b6fc9b06f31f7bfd5744 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:43 2016 +0100 irqchip/gic: Pass GIC pointer to save/restore functions Instead of passing the GIC index to the save/restore functions pass a pointer to the GIC chip data. This will allow these save/restore functions to be re-used by a platform driver where the GIC chip data structure is allocated dynamically and so there is no applicable index for identifying the GIC. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 74 +++++++++++++++++++++++++---------------------- 1 file changed, 39 insertions(+), 35 deletions(-) commit dc9722cc57eba336038b2ade111436656c5a87d0 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:42 2016 +0100 irqchip/gic: Return an error if GIC initialisation fails If the GIC initialisation fails, then currently we do not return an error or clean-up afterwards. Although for root controllers, this failure may be fatal anyway, for secondary controllers, it may not be fatal and so return an error on failure and clean-up. Update the functions gic_cpu_init() and gic_pm_init() to return an error instead of calling BUG() and perform any necessary clean-up. For non-banked GIC controllers, make sure that we free any memory allocated if we fail to initialise the IRQ domain. Please note that free_percpu() only frees memory if the pointer passed to it is not NULL and so it is unnecessary to check if both pointers are valid or not. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 99 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 73 insertions(+), 26 deletions(-) commit c2baa2f3f42fc6ea302bb666889c5843986a19a3 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:41 2016 +0100 irqchip/gic: Remove static irq_chip definition for eoimode1 There are only 3 differences (not including the name) in the definitions of the gic_chip and gic_eoimode1_chip structures. Instead of statically defining the gic_eoimode1_chip structure, remove it and populate the eoimode1 functions dynamically for the appropriate GIC irqchips. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) commit 26acfe7463dc7162e595a8f7bd7ef3e06111e25d Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:40 2016 +0100 irqchip/gic: Don't initialise chip if mapping IO space fails If we fail to map the address space for the GIC distributor or CPU interface, then don't attempt to initialise the chip, just WARN and return. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 992345a58e0cbcd63c26226e3e818b4583c4a34d Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:39 2016 +0100 irqchip/gic: WARN if setting the interrupt type for a PPI fails Setting the interrupt type for private peripheral interrupts (PPIs) may not be supported by a given GIC because it is IMPLEMENTATION DEFINED whether this is allowed. There is no way to know if setting the type is supported for a given GIC and so the value written is read back to verify it matches the desired configuration. If it does not match then an error is return. There are cases where the interrupt configuration read from firmware (such as a device-tree blob), has been incorrect and hence gic_configure_irq() has returned an error. This error has gone undetected because the error code returned was ignored but the interrupt still worked fine because the configuration for the interrupt could not be overwritten. Given that this has done undetected and that failing to set the configuration for a PPI may not be a catastrophic, don't return an error but WARN if we fail to configure a PPI. This will allows us to fix up any places in the kernel where we should be checking the return status and maintain backward compatibility with firmware images that may have incorrect PPI configurations. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-common.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit ec1a454d6136b93e26902ead21025efc08047d05 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:38 2016 +0100 irqchip/gic: Don't unnecessarily write the IRQ configuration If the interrupt configuration matches the current configuration, then don't bother writing the configuration again. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-common.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit a2a8fa5563d8740efaa8e62f653a6a85569c858b Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:37 2016 +0100 irqchip: Mask the non-type/sense bits when translating an IRQ The firmware parameter that contains the IRQ sense bits may also contain other data. When return the IRQ type, bits outside of these sense bits should be masked. If these bits are not masked and irq_create_fwspec_mapping() is called to map an IRQ, then the comparison of the type returned from irq_domain_translate() will never match that returned by irq_get_trigger_type() (because this function masks the none sense bits) and so we will always call irq_set_irq_type() to program the type even if it was not really necessary. Currently, the downside to this is unnecessarily re-programmming the type but nevertheless this should be avoided. The Tegra LIC and TI Crossbar irqchips all have client instances (from reviewing the device-tree sources) where bits outside the IRQ sense bits are set, but do not mask these bits. Therefore, ensure these bits are masked for these irqchips. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-crossbar.c | 2 +- drivers/irqchip/irq-tegra.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 9b5d585d148a19bcadae81fa17ddbe3e22efb9e9 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue May 10 16:14:35 2016 +0100 genirq: Ensure IRQ descriptor is valid when setting-up the IRQ In the function, setup_irq(), we don't check that the descriptor returned from irq_to_desc() is valid before we start using it. For example chip_bus_lock() called from setup_irq(), assumes that the descriptor pointer is valid and doesn't check before dereferencing it. In many other functions including setup/free_percpu_irq() we do check that the descriptor returned is not NULL and therefore add the same test to setup_irq() to ensure the descriptor returned is valid. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> kernel/irq/manage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7c9b973061b03af62734f613f6abec46c0dd4a88 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Fri May 6 19:41:56 2016 +0100 irqchip/gic-v3: Configure all interrupts as non-secure Group-1 The GICv3 driver wrongly assumes that it runs on the non-secure side of a secure-enabled system, while it could be on a system with a single security state, or a GICv3 with GICD_CTLR.DS set. Either way, it is important to configure this properly, or interrupts will simply not be delivered on this HW. Cc: stable@vger.kernel.org Reported-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-v3.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 74c967aaffeace8a85fc3d7be773fd165ebde3da Author: Ray Jui <ray.jui@broadcom.com> Date: Thu May 5 09:32:01 2016 -0700 irqchip/gic-v2m: Add workaround for Broadcom NS2 GICv2m erratum Alex Barba <alex.barba@broadcom.com> discovered Broadcom NS2 GICv2m implementation has an erratum where the MSI data needs to be the SPI number subtracted by an offset of 32, for the correct MSI interrupt to be triggered. Here we are adding the workaround based on readings from the MSI_IIDR register, which contains a value unique to Broadcom NS2 GICv2m Reported-by: Alex Barba <alex.barba@broadcom.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-v2m.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) commit 1228d53d3df7826eaa6fe2fa267ee41131f9825d Author: Christoph Hellwig <hch@lst.de> Date: Thu May 5 16:41:05 2016 +0200 irqchip/irq-alpine-msi: Don't use <asm-generic/msi.h> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-alpine-msi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 086eec2de00ef5c1ac12ddb5a537289fbdc22689 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Apr 4 14:17:36 2016 +0300 irqchip/mbigen: Checking for IS_ERR() instead of NULL of_platform_device_create() returns NULL on error, it never returns error pointers. Fixes: ed2a1002d25c ('irqchip/mbigen: Handle multiple device nodes in a mbigen module') Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-mbigen.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 074f23b675f9f2a9c51c16ecefd06b4658d5e629 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Wed May 4 10:22:27 2016 +0100 irqchip/gic-v3: Remove inexistant register definition The GICv3 include file defines GICR_ISACTIVER and GICR_ICACTIVER in the RD_base page. News flash, they do not exist (probably a copy/paste brain fart). Just drop them. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> include/linux/irqchip/arm-gic-v3.h | 2 -- 1 file changed, 2 deletions(-) commit 466b7d168881f477ec8ddcc42d4206618acccf18 Author: Shanker Donthineni <shankerd@codeaurora.org> Date: Wed Mar 9 22:10:49 2016 -0600 irqchip/gicv3-its: Don't allow devices whose ID is outside range We are not checking whether the requested device identifier fits into the device table memory or not. The function its_create_device() assumes that enough memory has been allocated for whole DevID space (reported by ITS_TYPER.Devbits) during the ITS probe() and continues to initialize ITS hardware. This assumption is not perfect, sometimes we reduce memory size either because of its size crossing MAX_ORDER-1 or BASERn max size limit. The MAPD command fails if 'Device ID' is outside of device table range. Add a simple validation check to avoid MAPD failures since we are not handling ITS command errors. This change also helps to return an error -ENOMEM instead of success to caller. Signed-off-by: Shanker Donthineni <shankerd@codeaurora.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-v3-its.c | 42 ++++++++++++++++++++++++++++++++++++---- 1 file changed, 38 insertions(+), 4 deletions(-) commit 8cb17b5ed0177d1b613aadd53c7e570b81625728 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 25 04:00:38 2016 +0300 irqchip: Add LPC32xx interrupt controller driver The change adds improved support of NXP LPC32xx MIC, SIC1 and SIC2 interrupt controllers. This is a list of new features in comparison to the legacy driver: * irq types are taken from device tree settings, no more need to hardcode them, * old driver is based on irq_domain_add_legacy, which causes problems with handling MIC hardware interrupt 0 produced by SIC1, * there is one driver for MIC, SIC1 and SIC2, no more need to handle them separately, e.g. have two separate handlers for SIC1 and SIC2, * the driver does not have any dependencies on hardcoded register offsets, * the driver is much simpler for maintenance, * SPARSE_IRQS option is supported. Legacy LPC32xx interrupt controller driver was broken since commit 76ba59f8366f ("genirq: Add irq_domain-aware core IRQ handler"), which requires a private interrupt handler, otherwise any SIC1 generated interrupt (mapped to MIC hwirq 0) breaks the kernel with the message "unexpected IRQ trap at vector 00". The change disables compilation of a legacy driver found at arch/arm/mach-lpc32xx/irq.c, the file will be removed in a separate commit. Fixes: 76ba59f8366f ("genirq: Add irq_domain-aware core IRQ handler") Tested-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> arch/arm/Kconfig | 2 + arch/arm/mach-lpc32xx/phy3250.c | 1 - drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-lpc32xx.c | 238 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 241 insertions(+), 1 deletion(-) commit f86c4fbd930ff6fecf3d8a1c313182bd0f49f496 Author: Will Deacon <will.deacon@arm.com> Date: Tue Apr 26 12:00:00 2016 +0100 irqchip/gic: Ensure ordering between read of INTACK and shared data When an IPI is generated by a CPU, the pattern looks roughly like: <write shared data> smp_wmb(); <write to GIC to signal SGI> On the receiving CPU we rely on the fact that, once we've taken the interrupt, then the freshly written shared data must be visible to us. Put another way, the CPU isn't going to speculate taking an interrupt. Unfortunately, this assumption turns out to be broken. Consider that CPUx wants to send an IPI to CPUy, which will cause CPUy to read some shared_data. Before CPUx has done anything, a random peripheral raises an IRQ to the GIC and the IRQ line on CPUy is raised. CPUy then takes the IRQ and starts executing the entry code, heading towards gic_handle_irq. Furthermore, let's assume that a bunch of the previous interrupts handled by CPUy were SGIs, so the branch predictor kicks in and speculates that irqnr will be <16 and we're likely to head into handle_IPI. The prefetcher then grabs a speculative copy of shared_data which contains a stale value. Meanwhile, CPUx gets round to updating shared_data and asking the GIC to send an SGI to CPUy. Internally, the GIC decides that the SGI is more important than the peripheral interrupt (which hasn't yet been ACKed) but doesn't need to do anything to CPUy, because the IRQ line is already raised. CPUy then reads the ACK register on the GIC, sees the SGI value which confirms the branch prediction and we end up with a stale shared_data value. This patch fixes the problem by adding an smp_rmb() to the IPI entry code in gic_handle_irq. As it turns out, the combination of a control dependency and an ISB instruction from the EOI in the GICv3 driver is enough to provide the ordering we need, so we add a comment there justifying the absence of an explicit smp_rmb(). Cc: stable@vger.kernel.org Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/irq-gic-v3.c | 7 +++++++ drivers/irqchip/irq-gic.c | 8 ++++++++ 2 files changed, 15 insertions(+) commit 99aa036241ed4a08a71b627bb903b5d7c75d78c1 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue May 10 11:14:41 2016 +0100 arm64: secondary_start_kernel: Remove unnecessary barrier Remove the unnecessary smp_wmb(), which was added to make sure that the update_cpu_boot_status() completes before we mark the CPU online. But update_cpu_boot_status() already has dsb() (required for the failing CPUs) to ensure the correct behavior. Cc: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Reported-by: Dennis Chen <dennis.chen@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/smp.c | 2 -- 1 file changed, 2 deletions(-) commit 468c234f9ed759b059d7fe11a6cc4b903a594722 Author: Carlo Caione <carlo@endlessm.com> Date: Mon May 2 10:02:15 2016 +0200 pinctrl: amlogic: Add support for Amlogic Meson GXBB SoC This patch adds the basic platform file to support the pin controller found on the Amlogic Meson GXBB SoCs. Signed-off-by: Carlo Caione <carlo@endlessm.com> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Tested-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/meson/Makefile | 2 +- drivers/pinctrl/meson/pinctrl-meson-gxbb.c | 432 +++++++++++++++++++++++++++++ drivers/pinctrl/meson/pinctrl-meson.c | 8 + drivers/pinctrl/meson/pinctrl-meson.h | 2 + include/dt-bindings/gpio/meson-gxbb-gpio.h | 154 ++++++++++ 5 files changed, 597 insertions(+), 1 deletion(-) commit 3ba6767a56127d7b2f8f124129f94c0556c594d0 Author: David Wu <david.wu@rock-chips.com> Date: Wed May 11 11:39:28 2016 +0800 pinctrl: rockchip: fix pull setting error for rk3399 This patch fixes the pinctrl pull bias setting, since the pull up/down setting is the contrary for gpio0(just the gpio0a and gpio0b) and gpio2(just the gpio2c and gpio2d). From the TRM said, the gpio0a pull polarity setting: gpio0a_p GPIO0A PE/PS programmation section, every GPIO bit corresponding to 2bits[PS:PE] 2'b00: Z(Normal operation); 2'b11: weak 1(pull-up); 2'b01: weak 0(pull-down); 2'b10: Z(Normal operation); Then, the other gpios setting as the following: gpio1a_p (e.g.: gpio1, gpio2a, gpio2b, gpio3...) GPIO1A PU/PD programmation section, every GPIO bit corresponding to 2bits 2'b00: Z(Normal operation); 2'b01: weak 1(pull-up); 2'b10: weak 0(pull-down); 2'b11: Z(Normal operation); For example,(rk3399evb board) sdmmc_cd --->gpio0_a7 localhost / # io -r -4 0xff320040 ff320040: 00004d5f In general,the value should be 0x0000cd5f since the pin has been set in the dts. Signed-off-by: David Wu <david.wu@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: linux-gpio@vger.kernel.org Reviewed-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-rockchip.c | 179 ++++++++++++++++++++++++++----------- 1 file changed, 127 insertions(+), 52 deletions(-) commit c53db5222b92d1df384a89ceba7808f8e4c535dd Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Mon May 9 15:52:28 2016 +0200 s390/vmem: remove unused function parameter vmem_pte_alloc() has an unused function parameter. Let's remove it. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/mm/vmem.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c34a69059d7876e0793eb410deedfb08ccb22b02 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Tue May 10 12:10:22 2016 +0200 s390/vmem: fix identity mapping The identity mapping is suboptimal for the last 2GB frame. The mapping will be established with a mix of 4KB and 1MB mappings instead of a single 2GB mapping. This happens because of a off-by-one bug introduced with commit 50be63450728 ("s390/mm: Convert bootmem to memblock"). Currently the identity mapping looks like this: 0x0000000080000000-0x0000000180000000 4G PUD RW 0x0000000180000000-0x00000001fff00000 2047M PMD RW 0x00000001fff00000-0x0000000200000000 1M PTE RW With the bug fixed it looks like this: 0x0000000080000000-0x0000000200000000 6G PUD RW Fixes: 50be63450728 ("s390/mm: Convert bootmem to memblock") Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/mm/vmem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0f3e15618d5b2c47a14236be66ed0d3a1324a049 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 23:51:28 2016 +0200 drm/sti: include linux/seq_file.h where needed The sti drm driver has a lot of debugfs interface that cause build errors in some configurations when seq_file.h is not included implicitly: drm/sti/sti_mixer.c: In function 'mixer_dbg_ctl': drm/sti/sti_mixer.c:88:2: error: implicit declaration of function 'seq_puts' [-Werror=implicit-function-declaration] drm/sti/sti_mixer.c:91:4: error: implicit declaration of function 'seq_printf' [-Werror=implicit-function-declaration] drm/sti/sti_gdp.c: In function 'gdp_dbg_ctl': drm/sti/sti_gdp.c:146:2: error: implicit declaration of function 'seq_puts' [-Werror=implicit-function-declaration] drm/sti/sti_gdp.c:149:4: error: implicit declaration of function 'seq_printf' [-Werror=implicit-function-declaration] drm/sti/sti_gdp.c: In function 'gdp_dbg_show': drm/sti/sti_gdp.c:208:32: error: dereferencing pointer to incomplete type 'struct seq_file' This adds an explicit #include statement in all of the affected files. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Benjamin Gaignard <benjamin.gaignard@linaro.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462830733-1710590-2-git-send-email-arnd@arndb.de drivers/gpu/drm/sti/sti_cursor.c | 2 ++ drivers/gpu/drm/sti/sti_gdp.c | 1 + drivers/gpu/drm/sti/sti_hda.c | 1 + drivers/gpu/drm/sti/sti_hqvdp.c | 1 + drivers/gpu/drm/sti/sti_mixer.c | 1 + drivers/gpu/drm/sti/sti_tvout.c | 1 + drivers/gpu/drm/sti/sti_vid.c | 1 + 7 files changed, 8 insertions(+) commit 1ddbdbd6e996c7459d585062edcf2ca28a09f829 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:30:00 2016 +0200 drm/tegra: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Terje Bergström <tbergstrom@nvidia.com> Cc: linux-tegra@vger.kernel.org Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-28-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/tegra/drm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cf88585b1d5ce49515aabb381812976e2840a967 Merge: 953abb3 676970e Author: David S. Miller <davem@davemloft.net> Date: Tue May 10 23:36:14 2016 -0400 Merge tag 'batman-adv-for-davem' of git://git.open-mesh.org/linux-merge Antonio Quartulli says: ==================== Included changes: - remove useless skb size check in batadv_interface_rx - basic netns support introduced by Andrew Lunn: - prevent virtual interface from changing netns by setting NETIF_F_NETNS_LOCAL - create virtual interface within the netns of the first hard-interface - introduce detection of complex bridge loops and report event to the user (via udev) when the Bridge Loop Avoidance mechanism can't prevent them - minor reference counting bugfixes for the hard_iface object that couldn't make it via the net tree - use kref_get() instead of kref_get_unless_zero() to make reference counting bug more visible - use batadv_compare_eth() all over the code when possible instead of plain memcmp() - minor code cleanup and style adjustments ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b324f6392eda4124f25017bd4633c167301ad9e3 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:13:41 2016 +0300 eata_pio: missing break statement This missing break statement bug predates git. It's a very minor thing, it means that we print a '?' instead of a 'z' in dmesg. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/eata_pio.c | 1 + 1 file changed, 1 insertion(+) commit ff615f065a48137e48985c78d8b17ce14b22fa90 Author: Petros Koutoupis <petros@petroskoutoupis.com> Date: Mon May 9 13:44:10 2016 -0500 hpsa: Fix type ZBC conditional checks The device ID obtained from the inquiry can only be of a single type. The original code places a check for TYPE_ZBC right after the check for TYPE_DISK. Logically, if the first if statement sees a device of a TYPE_DISK and moves on to the second statement checking if not TYPE_ZBC, it will always hit the continue. [mkp: Applied by hand] Signed-off-by: Petros Koutoupis <petros@petroskoutoupis.com> Acked-by: Don Brace <don.brace@microsemi.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit d230823a1c4c3e97afd4c934b86b3975d5e20249 Author: Hannes Reinecke <hare@suse.de> Date: Mon May 9 09:14:29 2016 +0200 scsi_lib: Decode T10 vendor IDs Some arrays / HBAs will only present T10 vendor IDs, so we should be decoding them, too. [mkp: Fixed T10 spelling] Suggested-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Hannes Reinecke <hare@suse.com> Tested-by: Paul Mackerras <paulus@ozlabs.org> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_lib.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit fe8b9534a0a0356f8a76467e2c561194bdb53c84 Author: Hannes Reinecke <hare@suse.de> Date: Fri May 6 10:34:35 2016 +0200 scsi_dh_alua: do not fail for unknown VPD identification Not every device will return a useable VPD identification, but still might support ALUA. Rather than disable ALUA support we should be allowing the device identification to be empty and attach individual ALUA device handler to each devices. [mkp: Fixed typo reported by Bart] Reported-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Hannes Reinecke <hare@suse.com> Tested-by: Paul Mackerras <paulus@ozlabs.org> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/device_handler/scsi_dh_alua.c | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) commit 1b37bd606deef0a787bdbbab6ff51dbebdeb9d3d Author: Douglas Gilbert <dgilbert@interlog.com> Date: Fri May 6 00:40:29 2016 -0400 scsi_debug: use locally assigned naa For reported SAS addresses replace fake IEEE registered NAAs (5) with locally assigned NAAs (3). Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) commit 09ba24c18c7e0c215c39b3d92332b64132dae170 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Fri May 6 00:40:28 2016 -0400 scsi_debug: uuid for lu name Permit changing of a LU name from a (fake) IEEE registered NAA (5) to a locally assigned UUID. Using a UUID (RFC 4122) for a SCSI designation descriptor (e.g. a LU name) was added in spc5r08.pdf (a draft INCITS standard) on 25 January 2016. Add parameter uuid_ctl to use a separate UUID for each LU (storage device) name. Additional option for all LU names to have the same UUID (since their storage is shared). Previous action of using NAA identifier for LU name remains the default. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 61 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 51 insertions(+), 10 deletions(-) commit 760f3b0342df19c2cfe53fffcc5ff5e2311447a6 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Fri May 6 00:40:27 2016 -0400 scsi_debug: vpd and mode page work Cleanup some mode and vpd pages. Stop reporting SBC (disk) pages when peripheral type is something else (e.g. tape). Update version descriptors. Expand LBPRZ flag handling. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 187 ++++++++++++++++++++++++++-------------------- 1 file changed, 108 insertions(+), 79 deletions(-) commit c483739430f107c14b3fa316e9cdd3d1e065864a Author: Douglas Gilbert <dgilbert@interlog.com> Date: Fri May 6 00:40:26 2016 -0400 scsi_debug: add multiple queue support Add submit_queue parameter (minimum and default: 1; maximum: nr_cpu_ids) that controls how many queues are built, each with their own lock and in_use bit vector. Add statistics parameter which is default off. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 702 +++++++++++++++++++++++++++++----------------- 1 file changed, 446 insertions(+), 256 deletions(-) commit 0bc10b93f2d9c6089ce968681ef9febecdc9b8e0 Author: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Date: Tue May 3 20:49:36 2016 +0530 cpufreq: powernv: del_timer_sync when global and local pstate are equal When global and local pstate are equal in a powernv_target_index() call, we don't queue a timer. But we may have timer already queued for future. This could cause the timer to fire one additional time for no use. Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/powernv-cpufreq.c | 2 ++ 1 file changed, 2 insertions(+) commit 1fd3ff2874f79c04354f3e80e583afbe6fa6eaa2 Author: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Date: Tue May 3 20:49:35 2016 +0530 cpufreq: powernv: Move smp_call_function_any() out of irq safe block Fix a WARN_ON caused by smp_call_function_any() when irq is disabled, because of changes made in the patch ('cpufreq: powernv: Ramp-down global pstate slower than local-pstate') https://patchwork.ozlabs.org/patch/612058/ WARNING: CPU: 0 PID: 4 at kernel/smp.c:291 smp_call_function_single+0x170/0x180 Call Trace: [c0000007f648f9f0] [c0000007f648fa90] 0xc0000007f648fa90 (unreliable) [c0000007f648fa30] [c0000000001430e0] smp_call_function_any+0x170/0x1c0 [c0000007f648fa90] [c0000000007b4b00] powernv_cpufreq_target_index+0xe0/0x250 [c0000007f648fb00] [c0000000007ac9dc] __cpufreq_driver_target+0x20c/0x3d0 [c0000007f648fbc0] [c0000000007b1b4c] od_dbs_timer+0xcc/0x260 [c0000007f648fc10] [c0000000007b3024] dbs_work_handler+0x54/0xa0 [c0000007f648fc50] [c0000000000c49a8] process_one_work+0x1d8/0x590 [c0000007f648fce0] [c0000000000c4e08] worker_thread+0xa8/0x660 [c0000007f648fd80] [c0000000000cca88] kthread+0x108/0x130 [c0000007f648fe30] [c0000000000095e8] ret_from_kernel_thread+0x5c/0x74 - Calling smp_call_function_any() with interrupt disabled (through spin_lock_irqsave) could cause a deadlock, as smp_call_function_any() relies on the IPI to complete. This is detected in the smp_call_function_any() call and hence the WARN_ON. - As the spinlock (gpstates->lock) is only used to synchronize access of global_pstate_info between timer irq handler and target_index calls. And the timer irq handler just try_locks() hence it would not cause a deadlock. Hence could do without making spinlocks irq safe. - As the smp_call_function_any() is a blocking call and does not access global_pstates_info, it could reduce the critcal section by moving smp_call_function_any() after giving up the lock. Reported-by: Abdul Haleem <abdhalee@linux.vnet.linux.com> Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/powernv-cpufreq.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit a3c89334f06bacf7e2f23203ad64cfd6e78dbbf4 Author: Aaron Lu <aaron.lu@intel.com> Date: Mon May 9 15:54:58 2016 +0800 Thermal / ACPI / video: add INT3406 thermal driver INT3406 ACPI device object resembles an ACPI video output device, but its _BCM is said to be deprecated and should not be used. So we will make use of the raw interface to do the actual cooling. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Acked-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/thermal/Kconfig | 28 +-- drivers/thermal/int340x_thermal/Kconfig | 42 ++++ drivers/thermal/int340x_thermal/Makefile | 1 + drivers/thermal/int340x_thermal/int3406_thermal.c | 236 ++++++++++++++++++++++ 4 files changed, 282 insertions(+), 25 deletions(-) commit e5366a266a8cd4cd6b0fe66876462cca2e1c6a89 Author: Brian Norris <computersforpeace@gmail.com> Date: Fri May 6 08:37:41 2016 -0700 mtd: spi-nor: support GigaDevice gd25lq64c Also note the GigaDevice JEDEC ID. No write-protect support yet, since this flash uses a different status register layout. Cc: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Marek Vasut <marex@denx.de> drivers/mtd/spi-nor/spi-nor.c | 1 + include/linux/mtd/spi-nor.h | 1 + 2 files changed, 2 insertions(+) commit e77d0c63f00137add5d7966d9bd9fd5115ce0841 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue May 10 16:41:13 2016 -0400 f2fs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/f2fs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9910f5b199621aecfbdb0b63feb31ddd41fd63e2 Merge: 19d91c0 bb4b4e9 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:19:36 2016 +0200 Merge tag 'imx-dt64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/dt64 Merge "The Freescale/NXP arm64 device tree updates for 4.7" from Shawn Guo: - New board support of LS1043a-QDS from Freescale/NXP - Add new compatible for LS1043A and LS2080A GPIO devices - Update device tree bindings and sources for LS2080A fsl-mc device - Update QSPI and DSPI support on LS1043A and LS2080A * tag 'imx-dt64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: arm64: dts: ls2080a: fsl-mc dt node updates Documentation: fsl-mc: binding updates for MSIs, ranges, PHYs arm64: dts: ls1043a: add the DTS node for QSPI support Documentation: fsl-quadspi: Add fsl,ls1043a-qspi compatible string arm64: dts: ls2080a: Add compatible "fsl,ls2080a-gpio" for ls2080a gpio nodes arm64: dts: ls1043a: Add compatible "fsl,qoriq-gpio" for ls1043a gpio nodes arm64: dts: ls2080a: update the DTS for QSPI and DSPI support Documentation: fsl: dspi: Add fsl,ls2080a-dspi compatible string arm64: dts: ls1043a-rdb: add the DTS for DSPI support arm64: dts: add LS1043a-QDS board support Documentation: DT: Add entry for Freescale LS1043a-QDS board commit 19d91c04af478522d2382a3a8edaedef60af57f6 Merge: 8ed5898 962f514 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:19:00 2016 +0200 Merge tag 'v4.6-next-dts64' of https://github.com/mbgg/linux-mediatek into next/dt64 Merge "ARM: mediatek: dts64 updates for v4.7" from Matthias Brugger: - add thermal and auxadc device nodes to mt8173 - add thermal zone nodes to mt8173 * tag 'v4.6-next-dts64' of https://github.com/mbgg/linux-mediatek: arm64: dts: mt8173: Add thermal zone node. ARM64: dts: mt8173: Add thermal/auxadc device nodes commit 8ed589854a3e3daa030660e7688eb8348e03ffe1 Merge: 0378fe8 30f949b Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:18:14 2016 +0200 Merge tag 'tegra-for-4.7-gm20b' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/dt64 Merge "arm64: tegra: Enable GM20B GPU on Tegra210" from Thierry Reding: Complement the GM20B GPU device tree node on Tegra210 with missing properties to make it usable. * tag 'tegra-for-4.7-gm20b' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: arm64: tegra: Add IOMMU node to GM20B on Tegra210 arm64: tegra: Add reference clock to GM20B on Tegra210 dt-bindings: Add documentation for GM20B GPU dt-bindings: gk20a: Document iommus property dt-bindings: gk20a: Fix typo in compatible name commit 0378fe89d847131a95984ce3704795a64c0dc8f2 Merge: 3a005c1 ec6b925 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:16:51 2016 +0200 Merge tag 'tegra-for-4.7-gpio' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/dt64 Merge "dt-bindings: gpio: tegra: Add Tegra186 support" from Thierry Reding: Adds device tree bindings for the GPIO and AON controllers found on the Tegra186 SoC. * tag 'tegra-for-4.7-gpio' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: ARM: tegra: Add DT binding for Tegra186 GPIO controllers ARM: tegra: Fix naming in GPIO DT binding header commit 3a005c1d59057ef290f44b560c362faf4d164ced Merge: f1c09c3 19b67d5 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:14:52 2016 +0200 Merge tag 'mvebu-dt64-4.7-1' of git://git.infradead.org/linux-mvebu into next/dt64 Merge "mvebu dt64 for 4.7" from Gregory CLEMENT: - switch to label in the mvebu arm64 device tree - use new clock binding on Armada 7K/8K - improve SPI and I2C description on Armada 7K/8k - add CP110 block adding PCIe, SATA and USB3 - add XOR support on Armada 3700 - few more little fix * tag 'mvebu-dt64-4.7-1' of git://git.infradead.org/linux-mvebu: arm64: dts: marvell: add XOR node for Armada 3700 SoC arm64: dts: marvell: Use a SoC-specific compatible for xHCI on Armada37xx arm64: dts: marvell: Rename armada-37xx USB node arm64: dts: marvell: Clean up armada-3720-db arm64: dts: marvell: enable several CP interfaces on Armada 7040-DB arm64: dts: marvell: initial DT description of Armada 7K/8K CP110 master arm64: dts: marvell: use the proper I2C controller compatible string for 7K/8K arm64: dts: marvell: improve SPI flash description on Armada 7040-DB arm64: dts: marvell: use new clock binding on Armada AP806 arm64: dts: marvell: add UART aliases and define stdout-path arm64: dts: marvell: rename armada-ap806 XOR nodes arm64: dts: marvell: clean up armada-7040-db commit f1c09c3e9644fec5571cca1287730868d0809f97 Merge: 41caed5 51c454d Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 22:06:49 2016 +0200 Merge tag 'v4.7-rockchip-dts64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/dt64 Merge "Rockchip dts64 updates for v4.7 - part2" from Heiko Stübner: Adding the new rk3399 core devicetree support as well as a board dts for the evaluation board of this chip and similar to the arm32 side also move the rk3368 thermal data into the core soc dtsi, as there really is no need to keep it separate. * tag 'v4.7-rockchip-dts64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: dt-bindings: document rockchip rk3399-evb board arm64: dts: rockchip: add dts file for RK3399 evaluation board arm64: dts: rockchip: add core dtsi file for RK3399 SoCs dt-bindings: rockchip-dw-mshc: add description for rk3399 clk: rockchip: export some necessary rk3399 clock ids clk: rockchip: rename rga clock-id on rk3399 clk: rockchip: add general gpu soft-reset on rk3399 arm64: dts: rockchip: move the rk3368 thermal data into rk3368.dtsi clk: rockchip: fix checkpatch errors in rk3399 dt-binding header clk: rockchip: add dt-binding header for rk3399 commit 953abb3823633385b1235add9c30c3e775dee0bc Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Tue May 10 12:38:08 2016 -0400 skbuff: remove unused variable `doff' There are two instances of an unused variable, `doff' added by commit 6fa01ccd8830 ("skbuff: Add pskb_extract() helper function") in pskb_carve_inside_header() and pskb_carve_inside_nonlinear(). Remove these instances, they are not used. Reported by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/skbuff.c | 6 ------ 1 file changed, 6 deletions(-) commit 1ddb6b71b9b572edb2b9c09086ee3bbbc550d9cd Author: Tom Herbert <tom@herbertland.com> Date: Tue May 10 11:56:32 2016 +0200 ila: ipv6/ila: fix nlsize calculation for lwtunnel The handler 'ila_fill_encap_info' adds two attributes: ILA_ATTR_LOCATOR and ILA_ATTR_CSUM_MODE. nla_total_size_64bit() must be use for ILA_ATTR_LOCATOR. Also, do nla_put_u8 instead of nla_put_u64 for ILA_ATTR_CSUM_MODE. Fixes: f13a82d87b21 ("ipv6: use nla_put_u64_64bit()") Fixes: 90bfe662db13 ("ila: add checksum neutral ILA translations") Reported-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Acked-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ila/ila_lwt.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 93edb8c7f94fb3d384790ac8a83c3fb9389f6ca5 Author: Pablo Neira <pablo@netfilter.org> Date: Tue May 10 21:33:38 2016 +0200 gtp: reload GTPv1 header after pskb_may_pull() The GTPv1 header flags indicate the presence of optional extensions after this header. Refresh the pointer to the GTPv1 header as skb->head might have be reallocated via pskb_may_pull(). Fixes: 459aa660eb1d ("gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U)") Reported-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/gtp.c | 2 ++ 1 file changed, 2 insertions(+) commit 1dee3f59a8d5e711797dc82628aaf94a64e99922 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon May 9 11:40:20 2016 +0200 block/drbd: align properly u64 in nl messages The attribute 0 is never used in drbd, so let's use it as pad attribute in netlink messages. This minimizes the patch. Note that this patch is only compile-tested. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/block/drbd/drbd_nl.c | 28 ++++++++++++++++------------ include/linux/genl_magic_struct.h | 7 ++++++- 2 files changed, 22 insertions(+), 13 deletions(-) commit af5e964f3045b66f1cd720b9c5abd37e47e613e2 Author: Luca Coelho <luciano.coelho@intel.com> Date: Tue Apr 19 12:03:45 2016 +0300 MAINTAINERS: add myself as co-maintainer of the iwlwifi driver I'm starting to take a more active role in the iwlwifi driver maintainership. Cc: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Cc: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 5c8877593a44ae914327a7fe850645766635b9b9 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Mon Mar 14 15:21:06 2016 +0200 iwlwifi: add default value to disable_11ac mod param description Small change to make it clear that the default value is false. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dfcfeef96cf56d2be344250ca472ca559b722112 Author: Sara Sharon <sara.sharon@intel.com> Date: Tue Apr 12 18:41:32 2016 +0300 iwlwifi: pcie: grab NIC access only once on RX init When initializing RX we grab NIC access for every read and write. This is redundant - we can just grab access once. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 97 ++++++++++++++++------------ 1 file changed, 57 insertions(+), 40 deletions(-) commit 1554ed20882798b1da3d9830b0d996a0bc1aaecd Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Apr 17 15:08:59 2016 +0300 iwlwifi: pcie: use shadow registers for updating write pointer The RX queues have a shadow register for the write pointer that enables updates without grabbing NIC access. Use them instead of the periphery registers because accessing those is much more expensive. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-fh.h | 3 +++ drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) commit cf961e16620f88686e0662753bd92d8383f36862 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Thu Aug 13 19:16:08 2015 +0300 iwlwifi: mvm: support dqa-mode agg on non-shared queue In non-shared queues, DQA requires re-configuring existing queues to become aggregated rather than allocating a new one. It also requires "un-aggregating" an existing queue when aggregations are turned off. Support this requirement for non-shared queues. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 5 +- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 33 ++++- drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 9 +- drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 148 ++++++++++++++++++---- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 15 ++- drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 37 +++++- 6 files changed, 207 insertions(+), 40 deletions(-) commit 192185d68dcc9b4517001fcec645111946f84d40 Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Apr 13 10:31:14 2016 +0200 iwlwifi: pcie: avoid msleep() with short timeout Since msleep is based on jiffies, it can sleep for a long time. Use usleep_range() instead to shorten the maximum time. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b7a08b284dcf7fb3d7b99473a87fabad04b2c548 Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Apr 13 10:24:59 2016 +0200 iwlwifi: pcie: extend device reset delay Newer hardware generations will take longer to be accessible again after reset, so we need to wait longer before continuing any flow that did a reset. Rather than make the wait time configurable, simply extend it for all. Since all of these code paths can sleep, use usleep_range() rather than mdelay(). Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit fbbd48595f2689619bab6957c6c2ee2895005b51 Author: Gregory Greenman <gregory.greenman@intel.com> Date: Tue Apr 12 15:16:24 2016 +0300 iwlwifi: turn on SGI support for VHT 160MHz Devices supporting VHT 160MHz width are supporting also Short GI. Turn on this capability in vht cap. Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 77d76931343aae1d36bf5d39231db2464abd5aa0 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 12 12:36:01 2016 +0200 iwlwifi: make configuration structs smaller Since we have a lot of configuration structs (almost 70) saving some memory in each one of them leads to an overall saving of ~2.6KiB of memory. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-1000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-2000.c | 2 - drivers/net/wireless/intel/iwlwifi/iwl-5000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-6000.c | 3 - drivers/net/wireless/intel/iwlwifi/iwl-7000.c | 1 - drivers/net/wireless/intel/iwlwifi/iwl-8000.c | 1 - drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 1 - drivers/net/wireless/intel/iwlwifi/iwl-config.h | 118 ++++++++++++------------ drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 5 +- 9 files changed, 65 insertions(+), 70 deletions(-) commit 39654cb3a6a2a04bb055e62e8ece16d611c2e517 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Tue Apr 12 13:07:52 2016 +0300 iwlwifi: don't access a nonexistent register upon assert The commit below added code to dump the content of FIFOs that are present only on dual CPU products (8000 and up). This broke 7265D whose firmware does advertise IWL_UCODE_TLV_CAPA_EXTEND_SHARED_MEM_CFG but doesn't have 2 CPUs. The current code does check the length of the FIFO before dumping them (and the nonexistent FIFO has a 0 length), but we still accessed a register to set the FIFO number and that made the DMA unhappy. The impact was a much longer recovery upon firmware assert. Fixes: 5b086414293f ("iwlwifi: mvm: support dumping UMAC internal txfifos") Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-dbg.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 75094dc8487935a0d95b78b7d21804805fc3a3be Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Sun Apr 10 08:48:46 2016 +0300 iwlwifi: remove IWLWIFI_DEBUG_EXPERIMENTAL_UCODE This Kconfig option allows to load a firmware for debugging with a different name. This mechanism has not been used for a few years now and replacing the firmware file works as well. Kill this Kconfig option and all the code that goes with it. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/Kconfig | 6 ----- drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 35 +++++++--------------------- 2 files changed, 9 insertions(+), 32 deletions(-) commit 13303c0fb1481e40377d072a29570e005e7bd032 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Apr 10 15:51:54 2016 +0300 iwlwifi: mvm: use helpers to get iwl_mvm_sta Getting the mvm station out of station id requires dereferencing the station id to get ieee80211_sta, then checking for pointer validity and only then extract mvm station out. Given that there are helpers to do it - use them instead of duplicating the code whenever we need only mvm station. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/d3.c | 8 ++------ drivers/net/wireless/intel/iwlwifi/mvm/debugfs-vif.c | 9 +++------ drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 6 ++---- drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 7 +------ drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 8 +++----- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 7 +++---- 6 files changed, 14 insertions(+), 31 deletions(-) commit ce1f27787d493bc28d2f523a3b4c9f72aa9cee7d Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Apr 10 16:02:12 2016 +0300 iwlwifi: mvm: remove redundant alloc_ctx parameter iwl_phy_db_set_section() is get called only from atomic context, the alloc_ctx parameter is not needed. Remove it. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-phy-db.c | 6 +++--- drivers/net/wireless/intel/iwlwifi/iwl-phy-db.h | 4 ++-- drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) commit 0ec84d1d1e6db6e0b4c1eb9bd9cdd2da64451da6 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Apr 10 12:27:25 2016 +0300 iwlwifi: mvm: make phy_db size dynamic Driver is agnostic to the number of the phy_db entries and only serves the firmware as a pipe to move the data from init image to RT image. As the size of the arrays may change (as it does in 9000 device) allocate it dynamically. Firmware sends the largest index first so we can use this to know how much we should allocate. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-phy-db.c | 62 +++++++++++++++++++------ 1 file changed, 49 insertions(+), 13 deletions(-) commit dd02fbeb8fedecd8b2d55fdfde664eaa05afac6f Author: Sara Sharon <sara.sharon@intel.com> Date: Thu Apr 7 17:26:53 2016 +0300 iwlwifi: mvm: set correct vht capability Our device supports only 160 GHz and not 80+80. Fix VHT flag accordingly. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 74dd17648c849eb401b8f4401e72628d9e7c7bd0 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 30 20:04:48 2016 +0300 iwlwifi: mvm: loosen nssn comparison to reorder buffer head Up till now, the reorder buffer uses standard spec based comparison when comparing the buffer status to NSSN. This indeed works for the regular case, since we shouldn't cross the 2048 boundary without getting a frame release notification. However, this is problematic due to packet filtering that may be performed by the FW while we are in d0i3. Theoretically we may filter over 2048 packets, and then the check of the NSSN will get incorrect. Change the comparison to always trust nssn unless it is 64 or less frames behind the head - which might happen due to a timeout. This new comparison is to be used only when comparing reorder buffer head with nssn, and not when comparing the packet SN to nssn or reorder buffer head. Put this in a separate commit as the logic is a bit tricky and stands for its own commit message. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit 7ef3dd264edbe8fdec163bf19dc9b3458e878cf4 Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Sun Apr 3 20:15:26 2016 +0300 iwlwifi: pcie: don't wake up the NIC when writing CSRs in MSIX mode CSR registers are always available even when the NIC is not awake, no need to wake up the NIC before accessing them. This has a huge impact when we re-enable an interrupt at the end of the ISR since waking up the NIC can take some time. Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 0730ffb19e9af9b021927c266b6fbff0b5d93d45 Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Wed Apr 6 10:45:05 2016 +0300 iwlwifi: Fix firmware name maximum length definition Previous patch had changed firmware name convention for new generation product. The firmware name is now longer than the former convention. Adapt max firmware name length to the new convention. Fixes: e1ba684f762b ("iwlwifi: 8000: fix MODULE_FIRMWARE input") Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9c8fa9bc08f60ac657751daba9fccf828a36cfed Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sat May 7 15:48:26 2016 +0900 kbuild: fix if_change and friends to consider argument order Currently, arg-check is implemented as follows: arg-check = $(strip $(filter-out $(cmd_$(1)), $(cmd_$@)) \ $(filter-out $(cmd_$@), $(cmd_$(1))) ) This does not care about the order of arguments that appear in $(cmd_$(1)) and $(cmd_$@). So, if_changed and friends never rebuild the target if only the argument order is changed. This is a problem when the link order is changed. Apparently, obj-y += foo.o obj-y += bar.o and obj-y += bar.o obj-y += foo.o should be distinguished because the link order determines the probe order of drivers. So, built-in.o should be rebuilt when the order of objects is changed. This commit fixes arg-check to compare the old/current commands including the argument order. Of course, this change has a side effect; Kbuild will react to the change of compile option order. For example, "-DFOO -DBAR" and "-DBAR -DFOO" should give no difference to the build result, but false positive should be better than false negative. I am moving space_escape to the top of Kbuild.include just for a matter of preference. In practical terms, space_escape can be defined after arg-check because arg-check uses "=" flavor, not ":=". Having said that, collecting convenient variables in one place makes sense from the point of readability. Chaining "%%%SPACE%%%" to "_-_SPACE_-_" is also a matter of taste at this point. Actually, it can be arbitrary as long as it is an unlikely used string. The only problem I see in "%%%SPACE%%%" is that "%" is a special character in "$(patsubst ...)" context. This commit just uses "$(subst ...)" for arg-check, but I am fixing it now in case we might want to use it in $(patsubst ...) context in the future. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Kbuild.include | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 16c45822a89f3b53b300784d08e9665681a43a20 Author: Sara Sharon <sara.sharon@intel.com> Date: Mon Apr 4 19:30:05 2016 +0300 iwlwifi: mvm: don't allow negative reference count Currently code allows mvm reference to become negative and only warns in case mvm reference is released while reference counting is 0. However, we better prevent this from happening at all since iwl_mvm_unref() may race against iwl_mvm_unref_all_except() which is called on restart. As a result we might get the same reference unreferenced twice ending with a negative value: An example for an easily reproduced log: [ 2689.909166] iwl_mvm_ref Take mvm reference - type 8 [ 2690.732716] iwl_mvm_unref_all_except Cleanup: remove mvm ref type 8 (1) [ 2690.849708] iwl_mvm_unref Leave mvm reference - type 8 [ 2690.849721] WARNING: ... iwl_mvm_unref+0xb0/0xc0 [iwlmvm]() If there will be yet another another restart iwl_mvm_unref_all_except will run from 0 up to ref count, and since it is unsigned, we will throw the transport ref count completely out of balance: iwl_mvm_unref_all_except[I] -- Cleanup: remove mvm ref type 8 (255) iwl_trans_slv_unref[I] -- rpm counter: 0 iwl_trans_slv_unref[I] -- rpm counter: -1 iwl_trans_slv_unref[I] -- rpm counter: -2 ... iwl_trans_slv_unref[I] -- rpm counter: -253 iwl_trans_slv_unref[I] -- rpm counter: -254 As there is no valid scenario where we can get to a negative reference count - prevent it from happening. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit e87e2639f9ca9bc273e5d67d84cf6880d42d92af Author: Golan Ben-Ami <golan.ben.ami@intel.com> Date: Wed Apr 6 11:59:50 2016 +0300 iwlwifi: mvm: add more registers to dump upon error Add UREG, RXFC, RFH, WMAL and RL2P registers to the prph dump upon error. These regesiters could help to debug MSI-X and other issues. These register should be dumped only when multi-queue rx is supported so separate the prph ranges static array to two different arrays, and enable dumping different prph ranges according to run-time decision. Signed-off-by: Golan Ben-Ami <golan.ben.ami@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-dbg.c | 53 ++++++++++++++++++++----- 1 file changed, 44 insertions(+), 9 deletions(-) commit 16e4dd8faa9e5de9dd956a18c0f19d911a97ef79 Author: Luca Coelho <luciano.coelho@intel.com> Date: Wed Mar 30 15:05:56 2016 +0300 iwlwifi: mvm: add a new mvm reference type for RX data When a data packet is received, we need to make sure that we stay awake until it can be processed and wait a while before trying to enter runtime_suspend os system_suspend again. To do so, add a new reference type for RX data and take the reference when sending the packet to mac80211. We only do this for data packets, all the other RX packets sent by the firmware (e.g. notifications) are not a reason to prevent suspend. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c | 1 + drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 1 + drivers/net/wireless/intel/iwlwifi/mvm/rx.c | 15 +++++++++++++++ 3 files changed, 17 insertions(+) commit 43ec72b75a8851b48e561c29f49586cc747bdad8 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 10 11:55:44 2016 +0100 iwlwifi: mvm: pass station to mac80211 RX where known When we've already looked up the transmitter station, we can just pass it to mac80211 using the new ieee80211_rx_napi(). This saves the overhead of looking it up in mac80211 again. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/rx.c | 11 ++++++++--- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-) commit 4896d7642fd34251ba7119bcb8304d9a73e51bf8 Author: Gregory Greenman <gregory.greenman@intel.com> Date: Sun Apr 3 14:06:12 2016 +0300 iwlwifi: consider VHT 160MHz while parsing NVM Devices belonging to 9000 family can support VHT 160MHz channel width, so need to consider it when configuring VHT capabilities. However, NVM file doesn't have a single bit specifying that 160MHz is supported. This patch turns on 160MHz support in VHT capabilities in case there's at least one channel supporting 160MHz. Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-eeprom-parse.h | 1 + drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.c | 16 +++++++++++++--- 2 files changed, 14 insertions(+), 3 deletions(-) commit 1afb0ae4217423f7864cba0684362de99782fa4e Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Sun Apr 3 19:55:59 2016 +0300 iwlwifi: allow combining different phy images with mac images Currently there is one to one function between device id to it's ucode. The new generation devices allows to combine different phy and mac images. Now we have two different ucode images with the same device id. Read RF ID to identify phy image and overwrite it if needed. Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 29 ++++++++++++++++++++++--- drivers/net/wireless/intel/iwlwifi/iwl-config.h | 3 +++ drivers/net/wireless/intel/iwlwifi/iwl-csr.h | 15 +++++++++++++ drivers/net/wireless/intel/iwlwifi/iwl-trans.h | 2 ++ drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 10 +++++++++ drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 2 ++ 6 files changed, 58 insertions(+), 3 deletions(-) commit 71b1230ca97e60d26b4205ac553af6331724ca60 Author: Luca Coelho <luciano.coelho@intel.com> Date: Fri Mar 11 12:12:16 2016 +0200 iwlwifi: wake from runtime suspend before sending sync commands If a host command was queued while in runtime suspend, it would go out before the D0I3_END_CMD was sent. Sometimes it works, but sometimes it fails, and it is obviously the wrong thing to do. To fix this, have the opmode take a reference before sending a SYNC command and make the pcie trans wait for the runtime state to become active before actually queueing the command. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c | 1 + drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 1 + drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 8 +++++++- drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 11 +++++++++++ 4 files changed, 20 insertions(+), 1 deletion(-) commit fa820d696c0ac0bb3cf1b49a817899982d774d61 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Sun Apr 3 10:15:59 2016 +0300 iwlwifi: mvm: allow a debug knob for Tx A-MSDU even if rate control forbids it There is a debugfs knob to configure the maximal length of the A-MSDU. If this value is not 0 (which is the default), allow Tx A-MSDU even if the rate control disallows it. While at it, add "unlikely" to the if that limits the length of the A-MSDU based on the debugfs hook. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit aea2a5f0d84745f34eb37bc5eada9ecced40fa88 Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Sun Apr 3 18:56:15 2016 +0300 iwlwifi: Rename 9560 to 9260 and add new PCI IDs for it Rename 9560 to 9260. Add new PCI ID for 9260 and change some entries from 5165 to 9260. Also order the 9000 series. Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 4 ++-- drivers/net/wireless/intel/iwlwifi/iwl-config.h | 2 +- drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 21 +++++++++++---------- 3 files changed, 14 insertions(+), 13 deletions(-) commit e9eb5e338fb77fd6839f1efba9f2b6000a1c8166 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Apr 3 10:19:16 2016 +0300 iwlwifi: mvm: add a flag to disable checksum Add a constant to allow disabling checksum. This will enable easier debugging in early phases. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/constants.h | 1 + drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit 80938abc79a0d14d747a4b3a0c93cb0aa70f238e Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Mar 30 11:05:16 2016 +0200 iwlwifi: mvm: advertise RSS queue usage In order for mac80211 to use per-CPU statistics for RSS RX, the driver needs to advertise that it uses RSS. Do this when using more than a single queue. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 3 +++ 1 file changed, 3 insertions(+) commit c24c7f58d77a75343010d88fdf85ddebad2d7438 Author: Luca Coelho <luciano.coelho@intel.com> Date: Wed Mar 30 20:59:27 2016 +0300 iwlwifi: trans: don't call the trans-specific ref/unref directly It's cleaner to always call the iwl_trans_ref/unref() functions instead of sometimes calling the trans-specific ops directly. This also prepares for moving some of the code from the trans-specific ops to the common trans code. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/internal.h | 3 --- drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 4 ++-- drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 10 +++++----- 3 files changed, 7 insertions(+), 10 deletions(-) commit 2b1ba3ef921078ac3bd0375fdac9eea2c69ec144 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Mon Sep 21 14:14:23 2015 +0200 iwlwifi: mvm: support queue removal in ADD_STA hcmd To indicate to the FW that a queue has been removed, an existing flag in the ADD_STA HCMD (that hasn't been in use) has been changed to indicate that a queue is being removed from a STA. Update this in the driver code. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-sta.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a338384bb31f01dc1306c7200ace61a55fa25947 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Feb 28 15:41:47 2016 +0200 iwlwifi: mvm: utilize the frame release infrastructure The firmware will send frame release notification in order to release "stuck" frames on a queue where no more frames arrive on. Upon receiving the message the driver shall indicate the frames up to the NSSN. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 4 ++-- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 33 +++++++++++++++++++++++++-- 3 files changed, 34 insertions(+), 5 deletions(-) commit 0690405fef290c3ae9bf466d603731b2ba478053 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Feb 28 20:28:17 2016 +0200 iwlwifi: mvm: add reorder timeout per frame Add a timer in order to release expired frames from the reorder buffer. This is needed since some APs do not retransmit frames to fill in the reorder holes and in TCP it results with a complete stall of traffic. This has a few side effects on the general design: The nssn may not reflect the the head of the reorder buffer. This situation is valid, and packets with SN lower than the reorder buffer head will be dropped. Another side effect is that since the reorder timer might expire we need to lock the reorder buffer. This however is fine since the locking is only inside a single reorder buffer between RX path and reorder timeout and there is no outside contention. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 12 ++++ drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 81 ++++++++++++++++++++++++++- drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 23 +++++++- 3 files changed, 114 insertions(+), 2 deletions(-) commit b915c10174fb7df533b7928046129c8f626cca42 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 23 16:32:02 2016 +0200 iwlwifi: mvm: add reorder buffer per queue Next hardware will direct packets to core based on the TCP/UDP streams. This logic can create holes in reorder buffer since packets that belong to other stream were directed to a different core. However, those are valid holes and the packets can be indicated in L3 order. The hardware will utilize a mechanism of informing the driver of the normalized ssn and the driver shall release all packets that SN is lower than the nssn. This enables managing the reorder across the queues without sharing any data between them. The reorder buffer is allocated and released directly in the RX path in order to avoid various races between control path and rx path. The code utilizes the internal messaging to notify rx queues of when to delete the reorder buffer. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 2 + drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 24 +++ drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 181 +++++++++++++++++++++- drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 69 ++++++++- drivers/net/wireless/intel/iwlwifi/mvm/sta.h | 9 ++ 5 files changed, 276 insertions(+), 9 deletions(-) commit 2dd493434db68f89c690a665e3ac3dad11b69134 Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Mar 30 11:57:01 2016 +0200 iwlwifi: mvm: add firmware API name comment Add the firmware API name to the struct iwl_wowlan_gtk_status. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-d3.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 10b2b2019d810f6cc6cc1461615371014d0d11c8 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Mar 20 16:23:41 2016 +0200 iwlwifi: mvm: add infrastructure for tracking BA session in driver According to the spec when a BA session is started there is a timeout set for the session in the ADDBA request. If there is not activity on the TA/TID then the session expires and a DELBA is sent. In order to check for the timeout, data must be shared among the rx queues. Add a timer that runs as long as BA session is active for the station and stops aggregation session if needed. This patch also lays the infrastructure for the reordering buffer which will be enabled in the next patches. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> .../net/wireless/intel/iwlwifi/mvm/fw-api-sta.h | 6 +- drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 7 +- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 25 ++++ drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 35 ++++++ drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 130 +++++++++++++++++++-- drivers/net/wireless/intel/iwlwifi/mvm/sta.h | 4 +- 6 files changed, 194 insertions(+), 13 deletions(-) commit d0ff5d2297aa03f346c82d8c90528f00f90ea26d Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 23 16:31:43 2016 +0200 iwlwifi: mvm: change RX sync notification to be an attribute and not a type Currently the sync notification is a type of notification. However, it is better fitted as an attribute of a notification, since there might be another message in the payload (delba for instance) that should be sent while control path is waiting for all queues to process. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-rx.h | 9 ++++--- drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 30 ++++++++++++++-------- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 3 +++ drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 15 ++++++----- 4 files changed, 37 insertions(+), 20 deletions(-) commit 0636b938214c90c3a7d145ad86b64a061bb10c50 Author: Sara Sharon <sara.sharon@intel.com> Date: Thu Feb 18 14:21:12 2016 +0200 iwlwifi: mvm: implement driver RX queues sync command mac80211 will call the driver whenever there is a race between RSS queues and control path that requires a processing of all pending frames in RSS queues. Implement that by utilizing the internal notification mechanism: queue a message to all queues. When the message is received on a queue it decrements the atomic counter. This guarantees that all pending frames in the RX queue were processed since the message is in order inside the queue. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-rx.h | 4 ++ drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 43 ++++++++++++++++++++++ drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 2 + drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 2 + drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 7 ++++ 5 files changed, 58 insertions(+) commit fa64e5f6a35efd5e77d639125d973077ca506074 Author: Dirk Gouders <dirk@gouders.net> Date: Fri Apr 29 10:24:52 2016 +0200 kconfig/symbol.c: handle choice_values that depend on 'm' symbols If choices consist of choice_values of type tristate that depend on symbols set to 'm', those choice_values are not set to 'n' if the choice is changed from 'm' to 'y' (in which case only one active choice_value is allowed). Those values are also written to the config file causing modules to be built when they should not. The following config can be used to reproduce and examine the problem; with the frontend of your choice set "Choice 0" and "Choice 1" to 'm', then set "Tristate Choice" to 'y' and save the configuration: config modules boolean modules default y option modules config dependency tristate "Dependency" default m choice prompt "Tristate Choice" default choice0 config choice0 tristate "Choice 0" config choice1 tristate "Choice 1" depends on dependency endchoice This patch sets tristate choice_values' visibility that depend on symbols set to 'm' to 'n' if the corresponding choice is set to 'y'. This makes them disappear from the choice list and will also cause the choice_values' value set to 'n' in sym_calc_value() and as a result they are written as "not set" to the resulting .config file. Reported-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Dirk Gouders <dirk@gouders.net> Tested-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Tested-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/kconfig/symbol.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit dc6079d8ab24283f07b8180574dcf42c78ceeb7c Merge: 7a27de7 9365fbf Author: David S. Miller <davem@davemloft.net> Date: Tue May 10 15:06:21 2016 -0400 Merge branch 'phy_ksettings' Philippe Reynes says: ==================== net: phy: add phy_ethtool_{get|set}_link_ksettings Ethtool callbacks {get|set}_link_ksettings may be the same for many drivers. So we add two generics callbacks phy_ethtool_{get|set}_link_ksettings. To use those generics callbacks, the ethernet driver must use the pointer phydev contained in struct net_device, and not use a private structure to store this pointer. Changelog: v3: - rename function to phy_ethtool_{get|set}_link_ksettings - move code to net/phy/phy.c This feedback were provided by David Decotigny v2: - use generic function instead of macro - ethernet driver use the pointer phydev provided by struct net_device Those idea were provided by Ben Hutchings, and Florian Fainelli acknowledge them. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 9365fbf5781f2c7f182e8b5c78ff757d3ff9d722 Author: Philippe Reynes <tremyfr@gmail.com> Date: Tue May 10 00:19:43 2016 +0200 net: ethernet: fec: use phy_ethtool_{get|set}_link_ksettings There are two generics functions phy_ethtool_{get|set}_link_ksettings, so we can use them instead of defining the same code in the driver. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_main.c | 26 ++------------------------ 1 file changed, 2 insertions(+), 24 deletions(-) commit 45f5c327ce5ce9178147279b5d6b95eac216c84c Author: Philippe Reynes <tremyfr@gmail.com> Date: Tue May 10 00:19:42 2016 +0200 net: ethernet: fec: use phydev from struct net_device The private structure contain a pointer to phydev, but the structure net_device already contain such pointer. So we can remove the pointer phydev in the private structure, and update the driver to use the one contained in struct net_device. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec.h | 1 - drivers/net/ethernet/freescale/fec_main.c | 49 +++++++++++++------------------ 2 files changed, 21 insertions(+), 29 deletions(-) commit 9d9a77cee1ab53dc6419b1ab9da88c4e9342d26a Author: Philippe Reynes <tremyfr@gmail.com> Date: Tue May 10 00:19:41 2016 +0200 net: phy: add phy_ethtool_{get|set}_link_ksettings Ethtool callbacks {get|set}_link_ksettings are often the same, so we add two generics functions phy_ethtool_{get|set}_link_ksettings to avoid writing severals times the same function. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Acked-By: David Decotigny <decot@googlers.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/phy.c | 24 ++++++++++++++++++++++++ include/linux/phy.h | 4 ++++ 2 files changed, 28 insertions(+) commit 29884eff1f0f7b03417eaaffa898f9d9d53b0203 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue May 10 14:27:44 2016 -0400 afs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/afs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e23e9aa75283ac093421ca71339ec4eb1afbe8be Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue May 10 14:24:57 2016 -0400 befs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/befs/linuxvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit abc189eadf6c12e60f95030e9c84083175526eaf Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue May 10 16:11:08 2016 +0100 ASoC: da7213: Allow PLL disable/bypass when using 32KHz sysclk Current checking for PLL 32KHz mode fails in driver code when bypassing the PLL. This is due to an incorrect check of PLL source type when 32KHz clock is provided. Removal of this check resolves the issue. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7213.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1e62c52ddc2d23a02ac2308cc1bb6ff18f0cf3cd Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue May 10 16:11:07 2016 +0100 ASoC: da7213: Update PLL ranges to improve locking at frequency boundary This update changes the dividers used for ranges of input MCLK frequencies, to improve PLL locking for a corner case when at edge of MCLK frequency input divider range. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7213.c | 26 +++++++++++++------------- sound/soc/codecs/da7213.h | 28 ++++++++++++++-------------- 2 files changed, 27 insertions(+), 27 deletions(-) commit 7e28fd469624fc41ec326a31abbc63a7afdd10f5 Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue May 10 16:11:06 2016 +0100 ASoC: da7213: Default PC counter to free-running when DAI disabled Currently PC counter is always synchronised to DAI which means that when the DAI is disabled, features such as ALC calibration cannot be executed successfully. This patch makes sure that when the DAI is disabled, PC counter is set to free-running. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7213.c | 13 +++++++++++++ sound/soc/codecs/da7213.h | 3 +++ 2 files changed, 16 insertions(+) commit d575b0b0f01a805508c5cf48b540f004e9b5de07 Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue May 10 16:11:05 2016 +0100 ASoC: da7213: Add checking of SRM lock status before enabling DAI When the codec is DAI clk slave, and the SRM feature of the PLL is being used, the enabling of the DAI should occur only after the PLL has locked to the incoming WCLK. This update adds checking to the the DAI widget event, so it waits for SRM to lock. There is also a timeout if that lock doesn't occur within a given time. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7213.c | 23 +++++++++++++++++++++++ sound/soc/codecs/da7213.h | 4 ++++ 2 files changed, 27 insertions(+) commit a0d5caeaebfd00853efa0080afc850e10be7b39a Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue May 10 16:11:04 2016 +0100 ASoC: da7213: Add DAI DAPM event to control DAI clocks Currently, when Codec is I2S master DAI clocks are continuously generated even if all audio streams have stopped. To improve efficiency, control of the DAI clocks for master mode have been moved to a DAPM widget event so they're only enabled as required. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7213.c | 35 ++++++++++++++++++++++++++++++++--- sound/soc/codecs/da7213.h | 2 -- 2 files changed, 32 insertions(+), 5 deletions(-) commit 22341d8f33084c575ce5b7ea63b07d7290b68e2d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue May 10 14:24:06 2016 -0400 befs: constify stuff a bit Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/befs/befs.h | 4 ++-- fs/befs/btree.c | 16 ++++++++-------- fs/befs/btree.h | 4 ++-- fs/befs/datastream.c | 26 ++++++++++++++------------ fs/befs/datastream.h | 11 ++++++----- fs/befs/linuxvfs.c | 4 ++-- 6 files changed, 34 insertions(+), 31 deletions(-) commit 7a27de7810aee8d839e4a70d86ab450af60f72e5 Merge: 459aa66 5bbd655 Author: David S. Miller <davem@davemloft.net> Date: Tue May 10 14:19:06 2016 -0400 Merge tag 'linux-can-next-for-4.7-20160509' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-next Marc Kleine-Budde says: ==================== pull-request: can-next 2016-05-09 this is a pull request of 12 patches for net-next/master. Alexander Gerasiov and Nikita Edward Baruzdin each contribute a patch improving the sja1000 driver. Amitoj Kaur Chawla's patch converts the mcp251x driver to alloc_workqueue(). A patch by Oliver Hartkopp fixes the handling of CAN config options. Andreas Gröger improves the error handling in the janz-ican3 driver. The patch by Maximilian Schneider for the gs_usb improves probing of the USB driver. Finally there are 6 improvement patches by Marek Vasut for the ifi CAN driver. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 76016322ec5670052fdabb08c586d6b16bd5062f Author: Ramesh Babu <ramesh.babu@intel.com> Date: Tue May 10 22:02:06 2016 +0530 ASoC: Intel: Add Broxton-P machine driver This patch adds the Broxton-P machine driver for Intel Broxton-P reference boards. This machine uses the RT298 codec Signed-off-by: Ramesh Babu <ramesh.babu@intel.com> Signed-off-by: Senthilnathan Veppur <senthilnathanx.veppur@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/Kconfig | 15 ++ sound/soc/intel/boards/Makefile | 2 + sound/soc/intel/boards/bxt_rt298.c | 353 +++++++++++++++++++++++++++++++++++++ 3 files changed, 370 insertions(+) commit fcc494af3cfaefc9f8a51c3c7e7f208a0553b28f Author: Pardha Saradhi K <pardha.saradhi.kesapragada@intel.com> Date: Tue May 10 22:02:05 2016 +0530 ASoC: Intel: Skylake: Add more SSP DAIs The Broxton-P platform has 6 SSPs so we need to add ssp2 thru ssp5 to DAI list for the driver. Signed-off-by: Pardha Saradhi K <pardha.saradhi.kesapragada@intel.com> Signed-off-by: Ramesh Babu <ramesh.babu@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-pcm.c | 72 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) commit ee057d2ee73259f455cfbb7a4db808fc6b6405dd Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Tue May 10 02:22:37 2016 +0000 ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS Current rsnd_dmapp_get_id() returns 0xFF as error code if system used strange connection. It will be used as PDMACHCRn.SRS, but 0xFF is prohibited number. In order not to use prohibited number, this patch indicates error message and returns 0x00 (same as SSI00) in error case. Special thanks to Dung-san. Reported-by: Nguyen Viet Dung <nv-dung@jinso.co.jp> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sh/rcar/dma.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit ca0d8797397c5daa6260a6c67b845d79f65140f5 Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:37 2016 +0100 ASoC: es8328: Set symmetric rates Although the ES8328 does support different rates for capture and playback, only very limited combinations are supported (8kHz and 48kHz or 8.0182kHz and 44.1kHz) with most rates required to be symmetric. Instead of adding a lot of complexity for little gain, let's enforce symmetric rates. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 1 + 1 file changed, 1 insertion(+) commit 45749c918129e409c44777f051dc0a5afb689459 Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:36 2016 +0100 ASoC: es8328: Support more sample rates Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 135 ++++++++++++++++++++++++++++++++++------------ 1 file changed, 100 insertions(+), 35 deletions(-) commit 779e86a31402c3f33f20bb02e99a5b75595bdf7f Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:35 2016 +0100 ASoC: es8328: Support more sample formats The values are the same for the DAC and ADC so remove the specific values and use values with shifts. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 35 +++++++++++++++++++++++++++++------ sound/soc/codecs/es8328.h | 12 ++---------- 2 files changed, 31 insertions(+), 16 deletions(-) commit 8865c95e43257e6676bc0f6b042ecce17eff74fe Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:34 2016 +0100 ASoC: es8328: Move sample size setup to hw_params This is a refactor in preparation for supporting more sample sizes which has no functional change. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 19 ++++++++++++++----- sound/soc/codecs/es8328.h | 4 ++++ 2 files changed, 18 insertions(+), 5 deletions(-) commit f2ed04a4317e5c8074d98a5c1da175596811a2d8 Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:32 2016 +0100 ASoC: es8328: Use single R/W for regmap The chip only supports single reads and writes. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 1 + 1 file changed, 1 insertion(+) commit 2da1ab667a506cc6a7dea88b70e6df3d281458f8 Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:31 2016 +0100 ASoC: es8328: Fix mask for VMIDSEL This is always used along with ES8328_CONTROL1_ENREF so there is no change in the generated code as a result of this fix. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 57e41f3fb32a359753a3b2679c2502b2750bf6af Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:30 2016 +0100 ASoC: es8328: Fix ADC format setup The ADCCONTROL4 and DACCONTROL1 registers are similar but not identical, with the DACCONTROL1 having each field starting one bit higher than ADCCONTROL4. Instead of introducing a magic shift, add new constants for the values in ADCCONTROL4 and use a second variable to setup the ADC. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 16 ++++++++++------ sound/soc/codecs/es8328.h | 15 +++++++++++++++ 2 files changed, 25 insertions(+), 6 deletions(-) commit 420c470d6b5c2924a3182edf5b002870ff770331 Author: John Keeping <john@metanate.com> Date: Mon May 9 12:24:29 2016 +0100 ASoC: es8328: Move clock setup to hw_params This ensures that the clock is setup after its frequency has been set; the existing code in set_dai_fmt may be called before the clock rate has been set resulting in an incorrect configuration. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/es8328.c | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) commit 251a9605ab882998009002bf1f5176a049beba53 Author: Shengzhen Li <szli@marvell.com> Date: Tue Apr 26 07:25:45 2016 -0700 mwifiex: change sleep cookie poll count Sometimes current polling count is not sufficient. This patch increases it to 100. Signed-off-by: Shengzhen Li <szli@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit adc64ecf8dd941e24456de9b4a02a4152ff7df15 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:17 2016 +0300 ata: sata_dwc_460ex: add __iomem to register base pointer The pointer to the mmio register base is missing the __iomem annotation. Fix this. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 175553ed18491bf654a64f4e1c3f8d4137ae1a56 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:16 2016 +0300 ata: sata_dwc_460ex: get rid of incorrect cast The (void *__iomem) cast is wrong. Change the target type of the "base" pointer to void __iomem instead and drop the cast. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ae95d951f7cd116f663b7326422c4c759ea25b25 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:15 2016 +0300 ata: sata_dwc_460ex: get rid of some pointless casts Casting a pointer to unsigned long only to immediately cast it back to a pointer makes no sense. Fix this. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit cd12ff0b5a8becd143df1f0a9dc97a4222e2cf6f Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:14 2016 +0300 ata: sata_dwc_460ex: remove empty libata callback The sata_dwc_qc_prep() does nothing. Use the default ata_noop_qc_prep instead. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 22 ---------------------- 1 file changed, 22 deletions(-) commit 4bb41be5eaa2788f5a5fa2047886ffeae7b0e21f Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:13 2016 +0300 ata: sata_dwc_460ex: correct HOSTDEV{P}_FROM_*() macros Here we refactor HOSTDEV{P}_FROM_*() macros to fit one line and fix the definition of HSDEV_FROM_HSDEVP() where wrong name of the parameter waas used. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit 2d20da00c324b9a4dd1c4ab9429a6376e7f4b735 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:12 2016 +0300 ata: sata_dwc_460ex: get rid of global data This moves all global data into the driver private struct, thus permitting multiple devices of this type to be used. The core_scr_read/write() functions are replaced with equivalent calls to the existing sata_dwc_scr_read/write(). Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 79 ++++++++++++++++---------------------------- 1 file changed, 29 insertions(+), 50 deletions(-) commit 0f48debdb90601ec37cdcb81f796ca120aae60f4 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:11 2016 +0300 ata: sata_dwc_460ex: add phy support This adds support for powering on an optional PHY when activating the device. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/Kconfig | 1 + drivers/ata/sata_dwc_460ex.c | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) commit 50b433753df69262ed1c098328f692e882a31001 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:10 2016 +0300 ata: sata_dwc_460ex: use "dmas" DT property to find dma channel Currently this driver only works with a DesignWare DMA engine which it registers manually using the second "reg" address range and interrupt number from the DT node. This patch makes the driver instead use the "dmas" property if present, otherwise optionally falling back on the old way so existing device trees can continue to work. With this change, there is no longer any reason to depend on the 460EX machine type so drop that from Kconfig. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/Kconfig | 11 ++- drivers/ata/sata_dwc_460ex.c | 198 ++++++++++++++++++++++++++++--------------- 2 files changed, 138 insertions(+), 71 deletions(-) commit 077028ecc99dc66acb3c89e33cc15c69d2edf8cb Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:09 2016 +0300 ata: sata_dwc_460ex: don't call ata_sff_qc_issue() on DMA commands ata_sff_qc_issue() can't handle DMA commands and thus we have to avoid it for them. Do call ata_bmdma_qc_issue() instead for this case. Note that the former one distinguishes PIO and DMA mode and behaves accordingly. Suggested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ae4c3485fa861af51336e066e1ba42b92af03627 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:08 2016 +0300 ata: sata_dwc_460ex: skip dma setup for non-dma commands Calling dmaengine_prep_slave_sg() for non-dma ATA commands is unnecessary at best and could be harmful if the dma driver reacts badly to this. It also causes this driver to print a bogus error message in these cases. This patch changes sata_dwc_qc_issue() to only do the dma setup for dma commands and also reports an error to libata if if fails. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 35 +++++++++-------------------------- 1 file changed, 9 insertions(+), 26 deletions(-) commit e1c1bee34f077baf88f78b24d08c0ba1ba506abd Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:07 2016 +0300 ata: sata_dwc_460ex: select only core part of DMA driver There is no need to have a platform driver compiled since the DMA driver is used as a library. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 59a75cef9de055e79779600f983c45580b902e6d Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:06 2016 +0300 ata: sata_dwc_460ex: DMA is always a flow controller In the original code the DMA is always a flow controller. Set this accordingly in updated code. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4ea8c205e5fd1f7cac8f634347f842e12d8af9b4 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:05 2016 +0300 ata: sata_dwc_460ex: burst size must be in items not bytes The burst size as defined by DMAengine API is in items of address width. Derive burst size from AHB_DMA_BRST_DFLT (64 bytes) by dividing it to DMA_SLAVE_BUSWIDTH_4_BYTES (4 bytes) that gives us 16 items. Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6689dfac00ef3118f88d5b06e1f1d13899b79997 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Tue Apr 26 12:03:04 2016 +0300 ata: sata_dwc_460ex: set dma_boundary to 0x1fff The original code states: Make sure a LLI block is not created that will span 8K max FIS boundary. If the block spans such a FIS boundary, there is a chance that a DMA burst will cross that boundary -- this results in an error in the host controller. Since we have switched to generic DMAengine API we satisfy above by setting dma_boundary value to 0x1fff. Suggested-by: Mans Rullgard <mans@mansr.com> Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit a7e6de544c5c238a06935c96d27151432c94d2e6 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Tue Apr 26 12:03:03 2016 +0300 ata: sata_dwc_460ex: fix crash on offline links without an attached drive This patch fixes Machine Check "Data Write PLB Error" which happens when libata-sff's ata_sff_dev_select is trying to write into the device_addr in order to select a drive. However, SATA has no master or slave devices like the old ATA Bus, therefore selecting a different drive is kind of pointless. Data Write PLB Error Oops: Machine check, sig: 7 [#1] PowerPC 44x Platform Modules linked in: CPU: 0 PID: 508 Comm: scsi_eh_0 Not tainted 4.6.0-rc3-next-20160412+ #10 [...] NIP [c027e820] ata_sff_dev_select+0x3c/0x44 LR [c027e810] ata_sff_dev_select+0x2c/0x44 Call Trace: [cec31cd0] [c027da00] ata_sff_postreset+0x40/0xb4 (unreliable) [cec31ce0] [c027a03c] ata_eh_reset+0x5cc/0x928 [cec31d60] [c027a840] ata_eh_recover+0x330/0x10bc [cec31df0] [c027bae0] ata_do_eh+0x4c/0xa4 [...] Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 55e610cdd28c0ad3dce0652030c0296d549673f3 Author: Mans Rullgard <mans@mansr.com> Date: Tue Apr 26 12:03:02 2016 +0300 ata: sata_dwc_460ex: remove incorrect locking This lock is already taken in ata_scsi_queuecmd() a few levels up the call stack so attempting to take it here is an error. Moreover, it is pointless in the first place since it only protects a single, atomic assignment. Enabling lock debugging gives the following output: ============================================= [ INFO: possible recursive locking detected ] 4.4.0-rc5+ #189 Not tainted --------------------------------------------- kworker/u2:3/37 is trying to acquire lock: (&(&host->lock)->rlock){-.-...}, at: [<90283294>] sata_dwc_exec_command_by_tag.constprop.14+0x44/0x8c but task is already holding lock: (&(&host->lock)->rlock){-.-...}, at: [<902761ac>] ata_scsi_queuecmd+0x2c/0x330 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&(&host->lock)->rlock); lock(&(&host->lock)->rlock); *** DEADLOCK *** May be due to missing lock nesting notation 4 locks held by kworker/u2:3/37: #0: ("events_unbound"){.+.+.+}, at: [<9003a0a4>] process_one_work+0x12c/0x430 #1: ((&entry->work)){+.+.+.}, at: [<9003a0a4>] process_one_work+0x12c/0x430 #2: (&bdev->bd_mutex){+.+.+.}, at: [<9011fd54>] __blkdev_get+0x50/0x380 #3: (&(&host->lock)->rlock){-.-...}, at: [<902761ac>] ata_scsi_queuecmd+0x2c/0x330 stack backtrace: CPU: 0 PID: 37 Comm: kworker/u2:3 Not tainted 4.4.0-rc5+ #189 Workqueue: events_unbound async_run_entry_fn Stack : 90b38e30 00000021 00000003 9b2a6040 00000000 9005f3f0 904fc8dc 00000025 906b96e4 00000000 90528648 9b3336c4 904fc8dc 9009bf18 00000002 00000004 00000000 00000000 9b3336c4 9b3336e4 904fc8dc 9003d074 00000000 90500000 9005e738 00000000 00000000 00000000 00000000 00000000 00000000 00000000 6e657665 755f7374 756f626e 0000646e 00000000 00000000 9b00ca00 9b025000 ... Call Trace: [<90009d6c>] show_stack+0x88/0xa4 [<90057744>] __lock_acquire+0x1ce8/0x2154 [<900583e4>] lock_acquire+0x64/0x8c [<9045ff10>] _raw_spin_lock_irqsave+0x54/0x78 [<90283294>] sata_dwc_exec_command_by_tag.constprop.14+0x44/0x8c [<90283484>] sata_dwc_qc_issue+0x1a8/0x24c [<9026b39c>] ata_qc_issue+0x1f0/0x410 [<90273c6c>] ata_scsi_translate+0xb4/0x200 [<90276234>] ata_scsi_queuecmd+0xb4/0x330 [<9025800c>] scsi_dispatch_cmd+0xd0/0x128 [<90259934>] scsi_request_fn+0x58c/0x638 [<901a3e50>] __blk_run_queue+0x40/0x5c [<901a83d4>] blk_queue_bio+0x27c/0x28c [<901a5914>] generic_make_request+0xf0/0x188 [<901a5a54>] submit_bio+0xa8/0x194 [<9011adcc>] submit_bh_wbc.isra.23+0x15c/0x17c [<9011c908>] block_read_full_page+0x3e4/0x428 [<9009e2e0>] do_read_cache_page+0xac/0x210 [<9009fd90>] read_cache_page+0x18/0x24 [<901bbd18>] read_dev_sector+0x38/0xb0 [<901bd174>] msdos_partition+0xb4/0x5c0 [<901bcb8c>] check_partition+0x140/0x274 [<901bba60>] rescan_partitions+0xa0/0x2b0 [<9011ff68>] __blkdev_get+0x264/0x380 [<901201ac>] blkdev_get+0x128/0x36c [<901b9378>] add_disk+0x3c0/0x4bc [<90268268>] sd_probe_async+0x100/0x224 [<90043a44>] async_run_entry_fn+0x50/0x124 [<9003a11c>] process_one_work+0x1a4/0x430 [<9003a4f4>] worker_thread+0x14c/0x4fc [<900408f4>] kthread+0xd0/0xe8 [<90004338>] ret_from_kernel_thread+0x14/0x1c Fixes: 62936009f35a ("[libata] Add 460EX on-chip SATA driver, sata_dwc_460ex") Tested-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Mans Rullgard <mans@mansr.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/sata_dwc_460ex.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 459aa660eb1d8ce67080da1983bb81d716aa5a69 Author: Pablo Neira <pablo@netfilter.org> Date: Mon May 9 00:55:48 2016 +0200 gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U) This is an initial implementation of a netdev driver for GTP datapath (GTP-U) v0 and v1, according to the GSM TS 09.60 and 3GPP TS 29.060 standards. This tunneling protocol is used to prevent subscribers from accessing mobile carrier core network infrastructure. This implementation requires a GGSN userspace daemon that implements the signaling protocol (GTP-C), such as OpenGGSN [1]. This userspace daemon updates the PDP context database that represents active subscriber sessions through a genetlink interface. For more context on this tunneling protocol, you can check the slides that were presented during the NetDev 1.1 [2]. Only IPv4 is supported at this time. [1] http://git.osmocom.org/openggsn/ [2] http://www.netdevconf.org/1.1/proceedings/slides/schultz-welte-osmocom-gtp.pdf Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/Kconfig | 17 + drivers/net/Makefile | 1 + drivers/net/gtp.c | 1364 ++++++++++++++++++++++++++++++++++++++++++ include/net/gtp.h | 34 ++ include/uapi/linux/Kbuild | 1 + include/uapi/linux/gtp.h | 33 + include/uapi/linux/if_link.h | 10 + include/uapi/linux/udp.h | 3 +- 8 files changed, 1462 insertions(+), 1 deletion(-) commit da4a95d23beea1c3d1d131480f681b0b276e207e Merge: 6d5853f e5d8b0a Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 17:46:15 2016 +0200 Merge tag 'mvebu-defconfig64-4.7-1' of git://git.infradead.org/linux-mvebu into next/arm64 Merge "mvebu defconfig for arm64 for 4.7" from Gregory CLEMENT: - update arm64 defconfig with options useful for Armada 7K/8K support * tag 'mvebu-defconfig64-4.7-1' of git://git.infradead.org/linux-mvebu: arm64: configs: add options useful for Armada 7K/8K support commit 962475ac2f9662fe69a9f86220ab31bbbf3911d2 Author: Azriel Samson <asamson@codeaurora.org> Date: Thu Mar 31 11:31:18 2016 -0600 builddeb: fix missing headers in linux-headers package The kernel headers package (linux-headers) doesn't include header files from other architectures required to build out-of-tree modules. For e.g. on ARM64, opcodes.h includes the same file from ARM which causes the following error: ./arch/arm64/include/asm/opcodes.h:1:43: fatal error: ../../arm/include/asm/opcodes.h: No such file or directory compilation terminated. Signed-off-by: Azriel Samson <asamson@codeaurora.org> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/package/builddeb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 697bbc7b832048d3a679cd55caf2268a325efbe0 Author: Bjørn Mork <bjorn@mork.no> Date: Wed May 4 15:35:39 2016 +0200 builddeb: include objtool binary in headers package "objtool" is required for building external m dules if "Compile-time stack metadata validation" is enabled. Otherwise all builds based on the headers package fail with: make[1]: Entering directory '/usr/src/linux-headers-4.6.0-rc6' make[2]: *** No rule to make target 'tools/objtool/objtool', needed by 'foo.o'. Stop. Makefile:1598: recipe for target 'foo.ko' failed make[1]: *** [foo.ko] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-4.6.0-rc6' Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/package/builddeb | 3 +++ 1 file changed, 3 insertions(+) commit e5ed17929bf4177c523465af187ab70c9a454caa Author: Mordechai Goodstein <mordechay.goodstein@intel.com> Date: Tue Mar 29 14:41:49 2016 +0300 iwlwifi: Edit the 8265 SDIO ID Add new 8265 series SDIO ID. Signed-off-by: Mordechai Goodstein <mordechay.goodstein@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-8000.c | 14 ++++++++++++++ drivers/net/wireless/intel/iwlwifi/iwl-config.h | 1 + 2 files changed, 15 insertions(+) commit 4c965139a3cdd7211b74ce27eccf9bb7485cd58a Author: Liad Kaufman <liad.kaufman@intel.com> Date: Sun Aug 9 19:26:56 2015 +0300 iwlwifi: mvm: support p2p device frames tx on dqa queue #2 Support sending P2P device frames should be sent from queue #2, as required in DQA mode. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 2 ++ drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 16 ++++++++++------ drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 7 +++++++ drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 12 ++++++++---- 4 files changed, 27 insertions(+), 10 deletions(-) commit de24f638025a0bfef2ea81396382358df2c7c875 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Tue Aug 4 15:19:18 2015 +0300 iwlwifi: mvm: allocate queue for probe response in dqa mode In DQA mode, allocate a dedicated queue (#9) for P2P GO/soft AP probe responses. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 3 ++ drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 6 ++++ drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 44 ++++++++++++++++++----- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 26 +++++++++++--- 4 files changed, 66 insertions(+), 13 deletions(-) commit 032a3187194e050383d7c2df804b194b6fecc6f3 Author: Dirk Gouders <dirk@gouders.net> Date: Fri Apr 29 12:43:38 2016 +0200 kconfig-language: elaborate on the type of a choice The type of a choice can be specified explicitely or it will be set according to members of the choice group, see menu.c:menu_finalize(). Signed-off-by: Dirk Gouders <dirk@gouders.net> Signed-off-by: Michal Marek <mmarek@suse.com> Documentation/kbuild/kconfig-language.txt | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit 3e2ba95f43360f22b882965d153e9cf3087de986 Author: Dirk Gouders <dirk@gouders.net> Date: Fri Apr 29 11:02:08 2016 +0200 kconfig-language: fix comment on dependency-generated menu structures. In the given example, the comment becomes visible when it's dependency is set to 'n', but the text asserts the opposite. Signed-off-by: Dirk Gouders <dirk@gouders.net> Signed-off-by: Michal Marek <mmarek@suse.com> Documentation/kbuild/kconfig-language.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit a7c65b9729e4a5e9c0809784bc52466b0dbaafa7 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Thu Apr 28 17:33:38 2016 -0400 kbuild: fix adjust_autoksyms.sh for modules that need only one symbol When only one symbol was listed and therefore the line didn't contain any space to separate multiple symbols, that symbol got ignored. Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Nicolas Pitre <nico@linaro.org> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/adjust_autoksyms.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f110e0fec89935879a76aebe1726dce3fcb6ab13 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Thu Apr 28 17:29:42 2016 -0400 kbuild: fix ksym_dep_filter when multiple EXPORT_SYMBOL() on the same line In kernel/cgroup.c there is: #define SUBSYS(_x) \ DEFINE_STATIC_KEY_TRUE(_x ## _cgrp_subsys_enabled_key); \ DEFINE_STATIC_KEY_TRUE(_x ## _cgrp_subsys_on_dfl_key); \ EXPORT_SYMBOL_GPL(_x ## _cgrp_subsys_enabled_key); \ EXPORT_SYMBOL_GPL(_x ## _cgrp_subsys_on_dfl_key); The expansion of this macro causes multiple EXPORT_SYMBOL_GPL() instances to appear on the same preprocessor line output, confusing the sed script expecting only one of them per line. Unfortunately this can't be fixed nicely in the sed script as sed's regexp can't do non greedy matching. Fix this by turning any semicolon into a line break before filtering. Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Nicolas Pitre <nico@linaro.org> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Kbuild.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a4663911392efdc504ce97b192d46f2677a6fe35 Author: Paul Bolle <pebolle@tiscali.nl> Date: Wed Mar 16 21:27:27 2016 +0100 kconfig: add unexpected data itself to warning If the .config parser runs into unexpected data it emits warnings like: .config:6911:warning: unexpected data Add the unexpected data itself to this warning. That makes it easier to discover what is actually going wrong: .config:6911:warning: unexpected data: CONFOG_CHARGER_TPS65217=m Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/kconfig/confdata.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e72e2dfe7c16ffbfbabf9cb24adc6d9f93a4fe37 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 17:35:31 2016 +0200 gcov: disable -Wmaybe-uninitialized warning When gcov profiling is enabled, we see a lot of spurious warnings about possibly uninitialized variables being used: arch/arm/mm/dma-mapping.c: In function 'arm_coherent_iommu_map_page': arch/arm/mm/dma-mapping.c:1085:16: warning: 'start' may be used uninitialized in this function [-Wmaybe-uninitialized] drivers/clk/st/clk-flexgen.c: In function 'st_of_flexgen_setup': drivers/clk/st/clk-flexgen.c:323:9: warning: 'num_parents' may be used uninitialized in this function [-Wmaybe-uninitialized] kernel/cgroup.c: In function 'cgroup_mount': kernel/cgroup.c:2119:11: warning: 'root' may be used uninitialized in this function [-Wmaybe-uninitialized] All of these are false positives, so it seems better to just disable the warnings whenever GCOV is enabled. Most users don't enable GCOV, and based on a prior patch, it is now also disabled for 'allmodconfig' builds, so there should be no downsides of doing this. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c87bf431448b404a6ef5fbabd74c0e3e42157a7f Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 17:35:30 2016 +0200 gcov: disable tree-loop-im to reduce stack usage Enabling CONFIG_GCOV_PROFILE_ALL produces us a lot of warnings like lib/lz4/lz4hc_compress.c: In function 'lz4_compresshcctx': lib/lz4/lz4hc_compress.c:514:1: warning: the frame size of 1504 bytes is larger than 1024 bytes [-Wframe-larger-than=] After some investigation, I found that this behavior started with gcc-4.9, and opened https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69702. A suggested workaround for it is to use the -fno-tree-loop-im flag that turns off one of the optimization stages in gcc, so the code runs a little slower but does not use excessive amounts of stack. We could make this conditional on the gcc version, but I could not find an easy way to do this in Kbuild and the benefit would be fairly small, given that most of the gcc version in production are affected now. I'm marking this for 'stable' backports because it addresses a bug with code generation in gcc that exists in all kernel versions with the affected gcc releases. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com> Cc: stable@vger.kernel.org Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cc622420798c4bcf093785d872525087a7798db9 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 17:35:29 2016 +0200 gcov: disable for COMPILE_TEST Enabling gcov is counterproductive to compile testing: it significantly increases the kernel image size, compile time, and it produces lots of false positive "may be used uninitialized" warnings as the result of missed optimizations. This is in line with how UBSAN_SANITIZE_ALL and PROFILE_ALL_BRANCHES work, both of which have similar problems. With an ARM allmodconfig kernel, I see the build time drop from 283 minutes CPU time to 225 minutes, and the vmlinux size drops from 43MB to 26MB. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com> Signed-off-by: Michal Marek <mmarek@suse.com> kernel/gcov/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 815eb71e7149ecce40db9dd0ad09c4dd9d33c60f Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 17:35:28 2016 +0200 Kbuild: disable 'maybe-uninitialized' warning for CONFIG_PROFILE_ALL_BRANCHES CONFIG_PROFILE_ALL_BRANCHES confuses gcc-5.x to the degree that it prints incorrect warnings about a lot of variables that it thinks can be used uninitialized, e.g.: i2c/busses/i2c-diolan-u2c.c: In function 'diolan_usb_xfer': i2c/busses/i2c-diolan-u2c.c:391:16: warning: 'byte' may be used uninitialized in this function iio/gyro/itg3200_core.c: In function 'itg3200_probe': iio/gyro/itg3200_core.c:213:6: warning: 'val' may be used uninitialized in this function leds/leds-lp55xx-common.c: In function 'lp55xx_update_bits': leds/leds-lp55xx-common.c:350:6: warning: 'tmp' may be used uninitialized in this function misc/bmp085.c: In function 'show_pressure': misc/bmp085.c:363:10: warning: 'pressure' may be used uninitialized in this function power/ds2782_battery.c: In function 'ds2786_get_capacity': power/ds2782_battery.c:214:17: warning: 'raw' may be used uninitialized in this function These are all false positives that either rob someone's time when trying to figure out whether they are real, or they get people to send wrong patches to shut up the warnings. Nobody normally wants to run a CONFIG_PROFILE_ALL_BRANCHES kernel in production, so disabling the whole class of warnings for this configuration has no serious downsides either. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Steven Rostedt <rostedtgoodmis.org> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 877417e6ffb9578e8580abf76a71e15732473456 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 17:35:27 2016 +0200 Kbuild: change CC_OPTIMIZE_FOR_SIZE definition CC_OPTIMIZE_FOR_SIZE disables the often useful -Wmaybe-unused warning, because that causes a ridiculous amount of false positives when combined with -Os. This means a lot of warnings don't show up in testing by the developers that should see them with an 'allmodconfig' kernel that has CC_OPTIMIZE_FOR_SIZE enabled, but only later in randconfig builds that don't. This changes the Kconfig logic around CC_OPTIMIZE_FOR_SIZE to make it a 'choice' statement defaulting to CC_OPTIMIZE_FOR_PERFORMANCE that gets added for this purpose. The allmodconfig and allyesconfig kernels now default to -O2 with the maybe-unused warning enabled. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Michal Marek <mmarek@suse.com> init/Kconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 8d879be882ba5a8bd4c2bc39bd2c336392564e13 Author: Takashi Iwai <tiwai@suse.de> Date: Tue May 10 16:07:40 2016 +0200 ALSA: pcm: Bail out when chmap is already present When snd_pcm_add_chmap_ctls() is called to the PCM stream to which a chmap has been already assigned, it returns as an error due to the conflicting snd_ctl_add() result. However, this also clears the already assigned chmap_kctl field via pcm_chmap_ctl_private_free(), and becomes inconsistent in the later operation. This patch adds the check of the conflicting chmap kctl before actually trying to allocate / assign. The check failure is treated as a kernel warning, as the double call of snd_pcm_add_chmap_ctls() is basically a driver bug and having the stack trace would help developers to figure out the bad code path. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/pcm_lib.c | 2 ++ 1 file changed, 2 insertions(+) commit 62f00e40b0718ebd8bd54fc7a9e89e873524d495 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:56 2016 +0900 ALSA: firewire-lib: enable the same feature as CIP_SKIP_INIT_DBC_CHECK flag In former commit, drivers in ALSA firewire stack always starts IT context before IR context. If IR context starts after packets are transmitted by peer unit, packet discontinuity may be detected because the context starts in the middle of packet streaming. This situation is rare because IT context usually starts immediately. However, it's better to solve this issue. This is suppressed with CIP_SKIP_INIT_DBC_CHECK flag. This commit enables the same feature as CIP_SKIP_INIT_DBC_CHECK. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 3 +-- sound/firewire/amdtp-stream.h | 7 ++----- sound/firewire/bebob/bebob_stream.c | 2 -- sound/firewire/digi00x/amdtp-dot.c | 2 +- sound/firewire/oxfw/oxfw-stream.c | 3 +-- 5 files changed, 5 insertions(+), 12 deletions(-) commit 390a1512e6ccda2ec32ea1395814f36cf4d30e48 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:55 2016 +0900 ALSA: firewire-lib: code cleanup for outgoing packet handling In previous commit, this module has no need to reuse parameters of incoming packets for outgoing packets anymore. This commit arranges some needless codes for outgoing packet processing. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit d9a16fc926a950c9e481cb7e89c554593b8e29e2 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:54 2016 +0900 ALSA: firewire-lib: code cleanup for incoming packet handling In previous commit, this module has no need to reuse parameters of incoming packets for outgoing packets anymore. This commit arranges some needless codes for incoming packet processing. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 44 +++++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 23 deletions(-) commit dec63cc8b65b04c0ebb5d82b6b399665d6d44dca Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:53 2016 +0900 ALSA: firewire-lib: handle IT/IR contexts in each software interrupt context In clause 6.3 of IEC 61883-6:2000, there's an explanation about processing of presentation timestamp. In the clause, we can see "If a function block receives a CIP, processes it and subsequently re-transmits it, then the SYT of the outgoing CIP shall be the sum of the incoming SYT and the processing delay." ALSA firewire stack has an implementation to partly satisfy this specification. Developers assumed the stack to perform as an Audio function block[1]. Following to the assumption, current implementation of ALSA firewire stack use one software interrupt context to handle both of in/out packets. In most case, this is processed in 1394 OHCI IR context independently of the opposite context. Thus, this implementation uses longer CPU time in the software interrupt context. This is not better for whole system. Against the assumption, I confirmed that each ASIC for IEC 61883-1/6 doesn't necessarily expect it to the stack. Thus, current implementation of ALSA firewire stack includes over-engineering. This commit purges the implementation. As a result, packets of one direction are handled in one software interrupt context and spends minimum CPU time. [1] [alsa-devel] [PATCH 0/8] [RFC] new driver for Echo Audio's Fireworks based devices http://mailman.alsa-project.org/pipermail/alsa-devel/2013-June/062660.html Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 40 ++++------------------------------------ sound/firewire/amdtp-stream.h | 35 +++++++---------------------------- 2 files changed, 11 insertions(+), 64 deletions(-) commit 28e64f5176387bf5b9458d213650b90fa719be88 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:52 2016 +0900 ALSA: firewire-tascam: drop reuse of incoming packet parameter for outgoing packet parameter In packet streaming protocol applied to TASCAM FireWire series, the value of SYT field in CIP header is always zero, therefore it has no meaning. There's no need to synchronize packets in both direction for the series. In current implementation of ALSA firewire stack, driver for the series uses incoming packet parameter for outgoing packet parameter to calculate the number of data blocks. This can be simplified because the task of corresponding driver is to transfer data blocks enough to sampling transfer frequency. This commit purges support of full duplex synchronization to prevent over-engineering implementation. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/tascam/tascam-stream.c | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) commit eb4a378fc99d876e98e01d67701c49343fae3e39 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:51 2016 +0900 ALSA: fireworks: drop reuse of incoming packet parameter for ougoing packet parameter On Fireworks board module of Echo Audio, TSB43Cx43A (IceLynx Micro, iCEM) is used to process payload of isochronous packets. There's an public document of this chip[1]. This document is for firmware programmers to transfer/receive AMDTP with IEC60958 data format, however in clause 2.5, 2.6 and 2.7, we can see system design to utilize the sequence of value in SYT field of CIP header. In clause 2.3, we can see the specification of Audio Master Clock (MCLK) from iCEM. Well, this clock is actually not used for sampling clock. This can be confirmed when corresponding driver transfer random value as the sequence of SYT field. Even if in this case, the unit generates proper sound. Additionally, in unique command set for this board module, the format of CIP is changed; for IEC 61883-6 mode which we use, and for Windows Operating System. In the latter mode, the whole 32 bit field in second CIP header from Windows driver is used to represent counter of packets (NO-DATA code is still used for packets without data blocks). If the master clock was physically used by DSP on the board module, the Windows driver must have transferred correct sequence of SYT field. Furthermore, as long as seeing capacities of AudioFire2, AudioFire4, AudioFire8, AudioFirePre8 and AudioFire12, these models don't support SYT-Match clock source. Summary, we have no need to relate incoming/outgoing packets. This commit drops reusing SYT sequence of incoming packets for outgoing packets. [1] Using TSB43Cx43A: S/PDIF over 1394 (2003, Texus Instruments Incorporated) http://www.ti.com/analog/docs/litabsmultiplefilelist.tsp?literatureNumber=slla148&docCategoryId=1&familyId=361 Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/fireworks/fireworks.h | 1 - sound/firewire/fireworks/fireworks_stream.c | 84 ++++++----------------------- 2 files changed, 17 insertions(+), 68 deletions(-) commit c71283cb682c28085125bea35e4c6149b538f5db Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 23:15:50 2016 +0900 ALSA: bebob: drop reuse of incoming packet parameter for outgoing packet parameter Windows driver for BeBoB-based models mostly wait for transmitted packets, then transfer packets to the models. This looks for the relationship between incoming packets and outgoing packets to synchronize the sequence of presentation timestamp. However, the sequence between packets of both direction has no relationship. Even if receiving NO-DATA packets, the drivers transfer packets with meaningful value in SYT field. Additionally, the order of starting packets is always the same, independently of the source of clock. The corresponding driver is expected as a generator of presentation timestamp and these models can select it as a source of sampling clock. This commit drops reusing SYT sequence from ALSA bebob driver. The driver always transfer packets with presentation timestamp generated by ALSA firewire stack, without re-using the sequence of value in SYT field in incoming packets to outgoing packets. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/bebob/bebob.h | 1 - sound/firewire/bebob/bebob_stream.c | 99 ++++++++++--------------------------- 2 files changed, 26 insertions(+), 74 deletions(-) commit 452e84012595d681f254a3a0d733fb0b18ffaf42 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:48:01 2016 +0900 perf tools: Remove xrealloc and ALLOC_GROW Remove unused xrealloc() and ALLOC_GROW() from libperf. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054801.6158.6204.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/Build | 1 - tools/perf/util/cache.h | 19 ------------------- tools/perf/util/util.h | 6 ------ tools/perf/util/wrapper.c | 29 ----------------------------- 4 files changed, 55 deletions(-) commit 682f4f035e0fcffce511fe77a02a0f19f0996d70 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:53 2016 +0900 perf help: Do not use ALLOC_GROW in add_cmd_list Replace ALLOC_GROW with normal realloc code in add_cmd_list() so that it can handle errors directly. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054752.6158.30562.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/help-unknown-cmd.c | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-) commit 11db4e29bb50442ecef2173f325b7be4e7790025 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:44 2016 +0900 perf pmu: Make pmu_formats_string to check return value of strbuf Make pmu_formats_string() to check return value of strbuf APIs so that it can detect errors in it. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054744.6158.37810.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/pmu.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 642aadaa320bf9466fd12e3c0903977410bcb731 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:35 2016 +0900 perf header: Make topology checkers to check return value of strbuf Make topology checkers to check the return value of strbuf APIs so that it can detect errors in it. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054735.6158.98650.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/header.c | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) commit 70a6898fdc11272249622f77b034f47f1e9adb35 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:26 2016 +0900 perf tools: Make alias handler to check return value of strbuf Make alias handler and sq_quote_argv to check the return value of strbuf APIs. In sq_quote_argv() calls die(), but this fix handles strbuf failure as a special case and returns to caller, since the caller - handle_alias() also has to check the return value of other strbuf APIs and those checks can be merged to one if() statement. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054725.6158.84597.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/perf.c | 8 +++++--- tools/perf/util/quote.c | 36 ++++++++++++++++++++---------------- tools/perf/util/quote.h | 2 +- 3 files changed, 26 insertions(+), 20 deletions(-) commit b72ca4039099e953f1ea2dbd58c201b14feb6605 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:17 2016 +0900 perf help: Make check_emacsclient_version to check strbuf APIs Make check_emacsclient_version() to check the return value of strbuf APIs so that it can handle errors in strbuf. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054716.6158.11755.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-help.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 51193b76bfff5027cf96ba63effae808ad67cca7 Author: Robert Jarzmik <robert.jarzmik@free.fr> Date: Sat Apr 2 21:38:53 2016 +0200 kbuild: forbid kernel directory to contain spaces and colons When the kernel path contains a space or a colon somewhere in the path name, the modules_install target doesn't work anymore, as the path names are not enclosed in double quotes. It is also supposed that and O= build will suffer from the same weakness as modules_install. Instead of checking and improving kbuild to resist to directories including these characters, error out early to prevent any build if the kernel's main directory contains a space. Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 4 ++++ 1 file changed, 4 insertions(+) commit bf4d5f25c90bf2eca8671f2fc4e3d15919cd7f9c Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:47:07 2016 +0900 perf probe: Check the return value of strbuf APIs Check the return value of strbuf APIs in perf-probe related code, so that it can handle errors in strbuf. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054707.6158.69861.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/dwarf-aux.c | 52 +++++++-------- tools/perf/util/probe-event.c | 143 +++++++++++++++++++++++++---------------- tools/perf/util/probe-finder.c | 30 +++++---- 3 files changed, 128 insertions(+), 97 deletions(-) commit 59fa0224cfea31dde596e29555de94c961b139f9 Author: Shaohua Li <shli@fb.com> Date: Mon May 9 17:22:15 2016 -0700 blk-throttle: don't parse cgroup path if trace isn't enabled if trace isn't enabled, parsing cgroup path just wastes cpu Signed-off-by: Shaohua Li <shli@fb.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-throttle.c | 5 ++--- include/linux/blktrace_api.h | 9 +++++++++ 2 files changed, 11 insertions(+), 3 deletions(-) commit 8d1547e08dda8848f01185b3fd6bb946b68de99f Author: Shaohua Li <shli@fb.com> Date: Mon May 9 17:22:14 2016 -0700 blktrace: add missed mask name BLK_TC_NOTIFY is missed in mask_maps, so we can't print out notify or set mask with 'notify' name. Signed-off-by: Shaohua Li <shli@fb.com> Signed-off-by: Jens Axboe <axboe@fb.com> kernel/trace/blktrace.c | 1 + 1 file changed, 1 insertion(+) commit b7d7641e2a8640a2f6ac7cdadd6c56eb12728b70 Author: Shaohua Li <shli@fb.com> Date: Mon May 9 17:22:13 2016 -0700 blktrace: delete garbage for message trace commit f4a1d08ce65 introduces a regression. Originally for BLK_TN_MESSAGE, we add message in trace and return. The commit ignores the early return and add garbage info. Signed-off-by: Shaohua Li <shli@fb.com> Reviewed-by: Jeff Moyer <jmoyer@redhat.com> Signed-off-by: Jens Axboe <axboe@fb.com> kernel/trace/blktrace.c | 1 + 1 file changed, 1 insertion(+) commit 6ac0f61f47a24bad3fa99ee6a46c0cc5a245ee91 Merge: 4ac3342 60a3770 Author: Paolo Bonzini <pbonzini@redhat.com> Date: Tue May 10 16:37:38 2016 +0200 Merge tag 'kvm-s390-next-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD KVM: s390: features and fixes for 4.7 part2 - Use hardware provided information about facility bits that do not need any hypervisor activitiy - Add missing documentation for KVM_CAP_S390_RI - Some updates/fixes for handling cpu models and facilities commit 5cea57f30a12443c05e0c5273f35d2fcef00d30a Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue May 10 14:46:58 2016 +0900 perf tools: Rewrite strbuf not to die() Rewrite strbuf implementation not to use die() nor xrealloc(). Instead of die(), now most of the API returns error code or 0 if succeeded. Suggested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160510054658.6158.24080.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/strbuf.c | 93 ++++++++++++++++++++++++++++++++++-------------- tools/perf/util/strbuf.h | 25 +++++++------ 2 files changed, 82 insertions(+), 36 deletions(-) commit 72928f2476d08c79f132b4f44a17c9a011dd98e3 Author: Vincent Stehlé <vincent.stehle@intel.com> Date: Tue May 10 14:56:20 2016 +0200 Btrfs: fix fspath error deallocation Make sure to deallocate fspath with vfree() in case of error in init_ipath(). fspath is allocated with vmalloc() in init_data_container() since commit 425d17a290c0 ("Btrfs: use larger limit for translation of logical to inode"). Signed-off-by: Vincent Stehlé <vincent.stehle@intel.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/backref.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 88f1847639d68d732f83adb7aae94e0d989f7e28 Merge: 28f3136 3f2129f Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 16:17:55 2016 +0200 Merge tag 'samsung-dt-devfreq-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/late Merge "ARM: dts: exynos: Devfreq for v4.7: from Krzysztof Kozłowski: Topic branch for Device Tree changes adding new generic devfreq driver, for v4.7: 1. Add bus nodes for Exynos3250, Exynos4x12, Exynos4210 and Exynos542x. 2. Split out common PPMU (Performance Monitoring Unit) nodes into separate DTSI. The PPMU provides performance data for devfreq. 3. Add NoCP (Network on Chip Probe) node for Exynos542x. On this SoC, like PPMU on older designs, provides performance data for devfreq. 4. Enable DFVS (Dynamic Voltage and Frequency Scaling) on boards: - Exynos3250 Rinato, - Exynos4412 Odroid-X/X2/U3 and Trats2, - Exynos5422 Odroid XU3/XU3-Lite/XU4. * tag 'samsung-dt-devfreq-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: exynos: Add support of Bus frequency using VDD_INT for exynos5422-odroidxu3 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos542x SoC ARM: dts: exynos: Add NoC Probe dt node for Exynos542x SoC ARM: dts: exynos: Add support of bus frequency for exynos4412-trats/odroidu3 ARM: dts: exynos: Expand the voltage range of buck1/3 regulator for exynos4412-odroidu3 ARM: dts: exynos: Add support of bus frequency using VDD_INT for exynos3250-rinato ARM: dts: exynos: Add exynos4412-ppmu-common dtsi to delete duplicate PPMU nodes ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4210 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos4x12 ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4x12 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos3250 ARM: dts: exynos: Add DMC bus frequency for exynos3250-rinato/monk ARM: dts: exynos: Add DMC bus node for Exynos3250 clk: samsung: exynos542x: Add the clock id for ACLK dt-bindings: clock: Add the clock id for ACLK clock of Exynos542x SoC commit 28f3136910b9733b9647e84430096f613dcec9e9 Merge: 0683e59 77f0862 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 16:15:20 2016 +0200 Merge tag 'imx-dt-clkdep-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/late Merge "The i.MX device tree updates with new clocks for 4.7" from Shawn Guo: - Add LCDIF and FlexCAN device support for i.MX7D - New support i.MX7D based Nitrogen7 board from Boundary Devices - Add display support for vf610-colibri board * tag 'imx-dt-clkdep-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: dts: vf610-colibri: enable display controller ARM: dts: vf610: add display nodes ARM: dts: imx: add Boundary Devices Nitrogen7 board ARM: dts: imx7d: add flexcan support ARM: dts: imx7d: add lcdif support clk: imx: vf610: fix whitespace in vf610-clock.h clk: imx: vf610: add TCON ipg clock clk: imx: vf610: fix DCU clock tree clk: imx: add ckil clock for i.MX7 clk: imx: vf610: add suspend/resume support clk: imx: vf610: add WKPU unit clk: imx: vf610: leave DDR clock on clk: imx: clk-gate2: allow custom gate configuration clk: imx6sx: Register SAI clocks as shared clocks commit ec42083b98bc7a85c736a8ae1b4c045901ed259e Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Wed May 4 12:49:56 2016 +0200 ARM: dts: tango4: Import watchdog node The device driver was added in v4.5 by commit dca536c433a2 ("watchdog: add support for Sigma Designs SMP86xx/SMP87xx") Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/tango4-common.dtsi | 6 ++++++ 1 file changed, 6 insertions(+) commit 862ccbfb9ce8ca1c2544815c88990ce1163eb2b2 Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Wed May 4 12:48:56 2016 +0200 ARM: dts: tango4: Update cpus node for cpufreq This platform will use the new generic platdev driver. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/tango4-smp8758.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit dd65a6867454117ecaeb8944dc231a4737681782 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Fri Apr 29 15:42:49 2016 +0200 drm/exynos/decon5433: fix trigger configuration It seems trigger cannot be configured too early, otherwise it does not work in case of panel. The patch fixes also trigger flag logic, previously HW-TRIGGER flag was cleared in case of panel - as a result panel used always software trigger. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 17ef49bd23eadfb22ad4ddcdaf1f6a08691ec49e Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Tue May 3 15:47:25 2016 +0200 drm/exynos/dsi: use of_graph_get_endpoint_by_regs helper This allows to remove the local of_graph_get_port_by_reg(), of_graph_get_endpoint_by_reg(), and of_get_child_by_name_reg() functions. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_dsi.c | 57 ++------------------------------- 1 file changed, 3 insertions(+), 54 deletions(-) commit fb38b1f60865567e74aeb540038fbaaa1144c432 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Tue May 3 15:47:24 2016 +0200 drm/exynos/dpi: use of_graph_get_endpoint_by_regs helper This allows to remove the local of_graph_get_port_by_reg(), of_graph_get_endpoint_by_reg(), of_get_child_by_name_reg(), and of_graph_get_remote_port_parent() functions. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_dpi.c | 69 +-------------------------------- 1 file changed, 2 insertions(+), 67 deletions(-) commit 562d54567f56a6228f53c2affa215dcff0cb1e3c Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Apr 27 13:38:41 2016 +0200 drm/exynos: Nuke dummy fb->dirty callback It's an optional hook. Might be needed for frontbuffer rendering on manual upload displays, but a simple TODO doesn't explain at all what needs to be done or why. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_fb.c | 11 ----------- 1 file changed, 11 deletions(-) commit 6aa5e85d7c1578cbe09881289403cba68c1e891d Author: Joonyoung Shim <jy0922.shim@samsung.com> Date: Fri Apr 22 16:34:07 2016 +0900 drm/exynos: use directly DMA mapping APIs on g2d There is no reason to be wapper functions to use DMA mapping APIs. Use directly DMA mapping APIs and remove the wapper functions. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_g2d.c | 10 +++++----- drivers/gpu/drm/exynos/exynos_drm_gem.c | 22 ---------------------- drivers/gpu/drm/exynos/exynos_drm_gem.h | 10 ---------- 3 files changed, 5 insertions(+), 37 deletions(-) commit b85881ddf2aa70d4a3ab9f8451127007e9f82496 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Thu Apr 21 14:51:38 2016 -0400 drm/exynos/hdmi: Don't print error on deferral due to regulators The regulators may not be available just because their driver's probe function was just not executed and so the regulators not registered. So, in this case the Exynos HDMI driver should not print logs since a -EPROBE_DEFER is not really an error and that will just pollute the kernel log and confuse users. This patch prevents the following misleading messages to be printed: [ 1.443638] [drm:hdmi_probe] *ERROR* failed to get regulators [ 1.449326] [drm:hdmi_probe] *ERROR* hdmi_resources_init failed Reported-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 55b19fc75ff325c17d71236866a0cd17152a355c Author: Joonyoung Shim <jy0922.shim@samsung.com> Date: Fri Apr 22 16:30:48 2016 +0900 drm/exynos: fix imported dma-buf to be mapped The imported dma-buf should be mapped by sub-system exporting it. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 +++ 1 file changed, 3 insertions(+) commit 5a0202f75803e9c366e5355de03a60d09c5d76d0 Author: Joonyoung Shim <jy0922.shim@samsung.com> Date: Fri Apr 22 16:30:47 2016 +0900 drm/exynos: support gem_prime_mmap This allows exported dma-bufs to be mapped using gem_prime_mmap. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_drv.c | 1 + drivers/gpu/drm/exynos/exynos_drm_gem.c | 45 +++++++++++++++++++++++---------- drivers/gpu/drm/exynos/exynos_drm_gem.h | 2 ++ 3 files changed, 35 insertions(+), 13 deletions(-) commit fa9971d62a8cfc085b07b3eda1f45c236acc7d70 Author: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Date: Thu May 5 18:23:38 2016 +0200 drm/exynos: fimd: harden fimd_calc_clkdiv() Don't use the vrefresh field of the DRM mode since this one is supposed to only be used for debug purpose. Instead use the clock field which should also provide much more precise information. Also sanitize the case in which the clock value should be zero. We then just default to the maximum clock divisor. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_fimd.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit fc173ae6ddd0e7271447f1cb2d048b11cb6fd872 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed May 4 15:23:11 2016 +0200 drm/exynos: fix cancel page flip code Driver code did not remove event from the list of pending events before destroy. As a result drm core later tried to inspect invalid memory location. The patch replaces removal code with call to core helper. The bug was detected using KASAN: [ 10.107249] ================================================================== [ 10.107518] BUG: KASAN: use-after-free in drm_release+0xe9c/0x1000 at addr ffffffc089154a18 [ 10.107784] Read of size 8 by task modetest/103 [ 10.107931] ============================================================================= [ 10.113191] BUG kmalloc-128 (Not tainted): kasan: bad access detected [ 10.119608] ----------------------------------------------------------------------------- [ 10.119608] [ 10.129243] Disabling lock debugging due to kernel taint [ 10.134551] INFO: Allocated in drm_mode_page_flip_ioctl+0x500/0xa98 age=4 cpu=0 pid=103 [ 10.142532] alloc_debug_processing+0x18c/0x198 [ 10.147043] ___slab_alloc.constprop.28+0x360/0x380 [ 10.151906] __slab_alloc.isra.25.constprop.27+0x54/0xa0 [ 10.157197] kmem_cache_alloc_trace+0x370/0x3b0 [ 10.161709] drm_mode_page_flip_ioctl+0x500/0xa98 [ 10.166400] drm_ioctl+0x4c4/0xb68 [ 10.169787] do_vfs_ioctl+0x16c/0xeb8 [ 10.173429] SyS_ioctl+0x8c/0xa0 [ 10.176642] el0_svc_naked+0x24/0x28 [ 10.180204] INFO: Freed in exynos_drm_crtc_cancel_page_flip+0xe0/0x160 age=0 cpu=0 pid=103 [ 10.188447] free_debug_processing+0x174/0x388 [ 10.192871] __slab_free+0x2e8/0x438 [ 10.196431] kfree+0x350/0x360 [ 10.199469] exynos_drm_crtc_cancel_page_flip+0xe0/0x160 [ 10.204762] exynos_drm_preclose+0x58/0xa0 [ 10.208844] drm_release+0x1f0/0x1000 [ 10.212491] __fput+0x1c4/0x5b8 [ 10.215613] ____fput+0xc/0x18 [ 10.218654] task_work_run+0x130/0x198 [ 10.222385] do_exit+0x700/0x2278 [ 10.225681] do_group_exit+0xe4/0x2c8 [ 10.229327] SyS_exit_group+0x1c/0x20 [ 10.232973] el0_svc_naked+0x24/0x28 [ 10.236532] INFO: Slab 0xffffffbdc2a45500 objects=32 used=10 fp=0xffffffc089154a00 flags=0x4080 [ 10.245210] INFO: Object 0xffffffc089154a00 @offset=2560 fp=0xffffffc089157600 [ 10.245210] ... [ 10.384532] CPU: 0 PID: 103 Comm: modetest Tainted: G B 4.5.0-rc3-00748-gd5e2881 #271 [ 10.398325] Call trace: [ 10.400764] [<ffffffc000091428>] dump_backtrace+0x0/0x328 [ 10.406141] [<ffffffc000091764>] show_stack+0x14/0x20 [ 10.411176] [<ffffffc00089c550>] dump_stack+0xb0/0xe8 [ 10.416210] [<ffffffc000395778>] print_trailer+0xf8/0x160 [ 10.421592] [<ffffffc00039b5cc>] object_err+0x3c/0x50 [ 10.426626] [<ffffffc00039d630>] kasan_report_error+0x248/0x550 [ 10.432527] [<ffffffc00039da50>] __asan_report_load8_noabort+0x40/0x48 [ 10.439039] [<ffffffc000b5b724>] drm_release+0xe9c/0x1000 [ 10.444419] [<ffffffc0003d340c>] __fput+0x1c4/0x5b8 [ 10.449280] [<ffffffc0003d3884>] ____fput+0xc/0x18 [ 10.454055] [<ffffffc000101aa8>] task_work_run+0x130/0x198 [ 10.459522] [<ffffffc0000bc058>] do_exit+0x700/0x2278 [ 10.464557] [<ffffffc0000bdcfc>] do_group_exit+0xe4/0x2c8 [ 10.469939] [<ffffffc0000bdefc>] SyS_exit_group+0x1c/0x20 [ 10.475320] [<ffffffc000087530>] el0_svc_naked+0x24/0x28 Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_crtc.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 3f4c8e5c286fa1be4d033f79c73242d5111c69d6 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Fri Apr 29 15:42:48 2016 +0200 drm/exynos/decon5433: do not use unnecessary software trigger Software trigger should not be used if hardware trigger is configured. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b0bb3d0775224ef2ac6f0b68df353281a399d78e Author: Andrzej Hajda <a.hajda@samsung.com> Date: Fri Apr 29 15:42:47 2016 +0200 drm/exynos/decon5433: handle vblank in vblank interrupt vblank should be signaled to userspace after reading framebuffers not before, signaling it in TE interrupt looks wrong. TE triggers reading framebuffers so it is the worst moment. Tearing is not observable because hardware prevents it, but there are frequently skipped vblank events. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 59b62d3c8bb8a5da351c5690f83b25c7e7252d94 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Tue May 10 13:56:32 2016 +0900 drm/exynos/hdmi: expose HDMI-PHY clock as pipeline clock HDMI-PHY clock should be accessible from other components in the pipeline. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 67 ++++++++++++++++++++++++++---------- 1 file changed, 48 insertions(+), 19 deletions(-) commit 692fbddccb9eefa1211c1135920e64cb9802bdd5 Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Wed May 4 12:48:12 2016 +0200 ARM: dts: tango4: Update DT to match clk driver Commit fefe0535b74f ("clk: tango4: improve clkgen driver") added support for USB and SDIO clocks. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/tango4-common.dtsi | 10 ++++++---- arch/arm/boot/dts/tango4-smp8758.dtsi | 2 +- arch/arm/boot/dts/tango4-vantage-1172.dts | 1 - 3 files changed, 7 insertions(+), 6 deletions(-) commit a6e818898caeb5cb7bf478f74d58938ae1d520d3 Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Wed May 4 12:47:02 2016 +0200 ARM: dts: tango4: Initial thermal support Define the CPU temperature sensor, and critical trip point. Commit 799d71da471c ("add temperature sensor support for tango SoC") added the device driver. Acked-by: Eduardo Valentin <edubezval@gmail.com> Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/tango4-smp8758.dtsi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 0f02588434a448dc593d4fae35eda10fad1897c5 Merge: 18aab73 068655dc Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 16:10:28 2016 +0200 Merge tag 'sunxi-dt-for-4.7-2' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into next/dt Merge "Allwinner DT changes for 4.7, round 2" from Maxime Ripard: Mostly DT patches to enable the new DRM driver on the CHIP, preliminary support for the A10 and A20, and a support for a new variant of the Olimex A20-Olinuxino-Lime2 featuring an eMMC * tag 'sunxi-dt-for-4.7-2' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: ARM: sun7i: dt: Add pll3 and pll7 clocks ARM: dts: sunxi: Add a olinuxino-lime2-emmc ARM: sun4i: dt: Add pll3 and pll7 clocks ARM: sun5i: chip: Enable the TV Encoder ARM: sun5i: r8: Add display blocks to the DTSI ARM: sun5i: a13: Add display and TCON clocks commit 18aab73fba7abee4df472424d115d76b199877cb Merge: e3cef9b 0244062 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 16:08:21 2016 +0200 Merge tag 'aspeed-for-4.7-dts' of https://github.com/shenki/linux into next/dt Merge "aspeed devicetree for 4.7" from Joel Stanley: This device trees for a pair of Aspeed BMC SoCs and the boards that they sit in. * tag 'aspeed-for-4.7-dts' of https://github.com/shenki/linux: arm/dst: Add Aspeed ast2500 device tree arm/dts: Add Aspeed ast2400 device tree doc/devicetree: Add Aspeed and Tyan to vendor-prefixes commit e3cef9bbb5a2b3c7dd0e11fe2e6e38574e5061c0 Merge: 3a99f3d 00bf4f7 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 16:06:19 2016 +0200 Merge tag 'at91-dt3' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91 into next/dt Merge "Third batch of DT changes for 4.7" from Nicolas Ferre: - a fix for the VInCo platform: reset gpio specification for Ethernet - addition of True Random Number Generator (TRNG) for all sama5 platforms - trivial adjustment of TRNG register map size for at91sam9g45 family * tag 'at91-dt3' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91: ARM: dts: at91: sama5d4: add trng node ARM: dts: at91: sama5d3: add trng node ARM: dts: at91: sama5d2: add trng node ARM: dts: at91: at91sam9g45 family: reduce the trng register map size ARM: dts: at91: VInCo: fix phy reset gpio flag commit 2e00fde5c6ed8535244332ebb55e881baa54ae46 Merge: 39f0ccd 3231e20 Author: Takashi Iwai <tiwai@suse.de> Date: Tue May 10 16:06:04 2016 +0200 Merge branch 'for-linus' into for-next commit 4ac334295e4f3b996e9feabe36e79e44bf77a06f Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 10:38:49 2016 +0100 MIPS: KVM: Add missing disable FPU hazard barriers Add the necessary hazard barriers after disabling the FPU in kvm_lose_fpu(), just to be safe. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Radim Krčmář" <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/mips/kvm/mips.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 556f2a5231bf3ec4ce98d46434920e31787f79d6 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 10:38:48 2016 +0100 MIPS: KVM: Fix preemption warning reading FPU capability Reading the KVM_CAP_MIPS_FPU capability returns cpu_has_fpu, however this uses smp_processor_id() to read the current CPU capabilities (since some old MIPS systems could have FPUs present on only a subset of CPUs). We don't support any such systems, so work around the warning by using raw_cpu_has_fpu instead. We should probably instead claim not to support FPU at all if any one CPU is lacking an FPU, but this should do for now. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Radim Krčmář" <rkrcmar@redhat.com> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/mips/kvm/mips.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit f049729c05cc5338174d52e2bee6678131da5e08 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 10:38:47 2016 +0100 MIPS: KVM: Fix preemptable kvm_mips_get_*_asid() calls There are a couple of places in KVM fault handling code which implicitly use smp_processor_id() via kvm_mips_get_kernel_asid() and kvm_mips_get_user_asid() from preemptable context. This is unsafe as a preemption could cause the guest kernel ASID to be changed, resulting in a host TLB entry being written with the wrong ASID. Fix by disabling preemption around the kvm_mips_get_*_asid() call and the corresponding kvm_mips_host_tlb_write(). Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Radim Krčmář" <rkrcmar@redhat.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/mips/kvm/tlb.c | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) commit b45bacd2d048f405c7760e5cc9b60dd67708734f Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 10:38:46 2016 +0100 MIPS: KVM: Fix timer IRQ race when writing CP0_Compare Writing CP0_Compare clears the timer interrupt pending bit (CP0_Cause.TI), but this wasn't being done atomically. If a timer interrupt raced with the write of the guest CP0_Compare, the timer interrupt could end up being pending even though the new CP0_Compare is nowhere near CP0_Count. We were already updating the hrtimer expiry with kvm_mips_update_hrtimer(), which used both kvm_mips_freeze_hrtimer() and kvm_mips_resume_hrtimer(). Close the race window by expanding out kvm_mips_update_hrtimer(), and clearing CP0_Cause.TI and setting CP0_Compare between the freeze and resume. Since the pending timer interrupt should not be cleared when CP0_Compare is written via the KVM user API, an ack argument is added to distinguish the source of the write. Fixes: e30492bbe95a ("MIPS: KVM: Rewrite count/compare timer emulation") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Radim Krčmář" <rkrcmar@redhat.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Cc: <stable@vger.kernel.org> # 3.16.x- Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/mips/include/asm/kvm_host.h | 2 +- arch/mips/kvm/emulate.c | 61 ++++++++++++++++++---------------------- arch/mips/kvm/trap_emul.c | 2 +- 3 files changed, 29 insertions(+), 36 deletions(-) commit 4355c44f063d3de4f072d796604c7f4ba4085cc3 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 22 10:38:45 2016 +0100 MIPS: KVM: Fix timer IRQ race when freezing timer There's a particularly narrow and subtle race condition when the software emulated guest timer is frozen which can allow a guest timer interrupt to be missed. This happens due to the hrtimer expiry being inexact, so very occasionally the freeze time will be after the moment when the emulated CP0_Count transitions to the same value as CP0_Compare (so an IRQ should be generated), but before the moment when the hrtimer is due to expire (so no IRQ is generated). The IRQ won't be generated when the timer is resumed either, since the resume CP0_Count will already match CP0_Compare. With VZ guests in particular this is far more likely to happen, since the soft timer may be frozen frequently in order to restore the timer state to the hardware guest timer. This happens after 5-10 hours of guest soak testing, resulting in an overflow in guest kernel timekeeping calculations, hanging the guest. A more focussed test case to intentionally hit the race (with the help of a new hypcall to cause the timer state to migrated between hardware & software) hits the condition fairly reliably within around 30 seconds. Instead of relying purely on the inexact hrtimer expiry to determine whether an IRQ should be generated, read the guest CP0_Compare and directly check whether the freeze time is before or after it. Only if CP0_Count is on or after CP0_Compare do we check the hrtimer expiry to determine whether the last IRQ has already been generated (which will have pushed back the expiry by one timer period). Fixes: e30492bbe95a ("MIPS: KVM: Rewrite count/compare timer emulation") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Radim Krčmář" <rkrcmar@redhat.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-mips@linux-mips.org Cc: kvm@vger.kernel.org Cc: <stable@vger.kernel.org> # 3.16.x- Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/mips/kvm/emulate.c | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) commit 3a99f3d8d27b643e923cd55e435f8f879f017fef Merge: 21c9a64 7ba5dd5 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:46:55 2016 +0200 Merge tag 'ux500-armsoc-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson into next/dt Merge "ux500 Devicetree updates for v4.7" from Linus Walleij: - Use generic include files - Make accelerometers open drain on the TVK board * tag 'ux500-armsoc-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson: ARM: dts: ux500: configure the accelerometers open drain ARM: dts: ux500: use the GIC include header ARM: dts: ux500: use the GPIO DT header commit 21c9a6487387fc629955992ef62672bc0aae5daa Merge: 7430bc1 194521f Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:45:41 2016 +0200 Merge tag 'imx-dt-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/dt Merge "i.MX device tree updates for 4.7, take 2: from Shawn Guo: The i.MX device tree updates for 4.7, take 2: - Update display clock configuration for imx6q-b850v3 board - Use watchdog external reset for imx6q-ba16 board - Update operating points settings for i.MX6UL/SX/DL - New board support: imx6ul-pico-hobbit and imx6q-marsboard - Add SAI audio support for imx6ul-14x14-evk board - Enable USB OTG support for M53EVK board - A couple of fixes on DTC warnings * tag 'imx-dt-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: mx5: dts: Enable USB OTG on M53EVK ARM: dts: imx6ul-14x14-evk: Add audio support ARM: dts: imx6qdl: Remove unneeded unit-addresses ARM: dts: imx6: apalis: parallel lcd display support on ixora ARM: dts: imx6sx-sdb: Add 198MHz operational point ARM: dts: imx28-m28: Remove unneeded partition nodes ARM: dts: imx6ul-pico-hobbit: Add initial support ARM: dts: imx6: Do not hardcode the CLKO clock ARM: dts: imx6: Add dts for Embest MarS Board ARM: dts: imx6: fix dtc warnings for ipu endpoints ARM: dts: imx6dl: Fix the VDD_ARM_CAP voltage for 396MHz operation ARM: dts: imx6sx: Add 198MHz operating point ARM: dts: imx6ul: Fix operating points ARM: dts: imx6q-ba16: use wdog external reset ARM: dts: imx: b450/b650v3: Move ldb_di clk assignment ARM: dts: imx6q-b850v3: Update display clock source ARM: dts: imx6q-b850v3: Remove ldb panel commit 7430bc1942f1f340a149abfbe007900ece743903 Merge: e8f72bf 610175b Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:44:27 2016 +0200 Merge tag 'v4.6-next-dts' of https://github.com/mbgg/linux-mediatek into next/dt Merge "ARM: mediatek: dts updates for v4.7" from Matthias Brugger: - add pinctrl node for mt2701 - add mt2701 pmic wrapper binding - add auxadc binding document * tag 'v4.6-next-dts' of https://github.com/mbgg/linux-mediatek: dt-bindings: MediaTek: Add binding document for the AUXADC dt-bindings: ARM: Mediatek: add MT2701/7623 string to the PMIC wrapper doc arm: dts: Add pinctrl/GPIO/EINT node for mt2701 commit e8f72bf9d45cfaaf550a85f177c7407ceae72645 Merge: 10bd9eb b52e345 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:43:20 2016 +0200 Merge tag 'sunxi-dt-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into next/dt Merge "Allwinner DT additions for 4.7" from Maxime Ripard: The usual bunch of changes, mostly: * Addition of the SPDIF support * Addition of the pre-requisites for the display support * New boards: Difrence DIT4350, colorfly e708 q1, Dserve DSRV9703C, Polaroid MID2809PXE4, Orange Pi PC, Orange Pi 2 * tag 'sunxi-dt-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: (38 commits) ARM: dts: sun7i: Enable S/PDIF on the Cubietruck ARM: sun5i: Add DRAM gates ARM: sun5i: Add TV encoder gate to the DTSI ARM: sun5i: dt: Add pll3 and pll7 clocks ARM: dts: sun8i: Add dts file for the Orange Pi One SBC ARM: sun7i: dt: Enable dram gate 5 (tve0 clock) for simplefb TV output ARM: sun4i: dt: Enable dram gate 5 (tve0 clock) for simplefb TV output ARM: dts: sun5i-a13-olinuxino-micro: enable USB DRC ARM: dts: sun8i: Base Orange Pi Plus dts on the Orange Pi 2 dts ARM: dts: sun8i: Orangepi plus gpio keys fixes and improvements ARM: dts: sun8i: Add dts for Orange Pi 2 SBC ARM: dts: sun8i: Add Orange Pi PC support ARM: dts: sun8i: Fix pio nodes Orangepi Plus dts ARM: dts: sun7i: Add SPDIF to the Itead Ibox ARM: dts: sun4i: Add SPDIF to the Mele A1000 ARM: dts: sun7i: Add the SPDIF block to the A20 ARM: dts: sun4i: Add the SPDIF block to the A10 ARM: dts: sun7i: Add the SPDIF clk to the A20 ARM: dts: sun4i: Add the SPDIF clk to the A10 ARM: dts: sun7i: Add SPDIF TX pin to the A20 ... commit 10bd9eb7dddb5046399cbfa6cf24a1f302fd7fce Merge: c5e51c9 c6d3b5d Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:39:18 2016 +0200 Merge tag 'davinci-for-v4.7/dt-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/dt Merge "DaVinci DT updates for v4.7 (part 2)" from Sekhar Nori: Second set of DT updates for DaVinci adding support for SPI0 and some low priority fixes for ethernet and interrupt controller. * tag 'davinci-for-v4.7/dt-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: dts: da850: There are 101 interrupts. ARM: dts: da850: disable mdio and eth0 in da850.dtsi ARM: davinci: da8xx-dt: Add spi0 lookup for clock matching ARM: dts: da850: add spi0 to device tree commit c5e51c98e3177339815e62006a288b3ec83f5067 Merge: 48ea582 f87305f Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 15:38:13 2016 +0200 Merge tag 'v4.7-rockchip-dts32-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/dt Merge "Rockchip dts32 updates for v4.7 - part2" from Heiko Stübner: This adds the rk3288-miqi as new board, adapts the edp-phy settings to the binding-change that made it into 4.6, adds rk3288 i2c controller nodes and moves the rk3288 thermal data into the soc dtsi, as there really is no need to have that separate file. * tag 'v4.7-rockchip-dts32-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: ARM: dts: rockchip: move the rk3288 thermal data into rk3288.dtsi ARM: dts: rockchip: add MiQi board from mqmaker dt-bindings: add vendor-prefix for mqmaker ARM: dts: rockchip: move rk3288 edp phy under the GRF ARM: dts: rockchip: make rk3288-grf a simple-mfd ARM: dts: rockchip: add i2c nodes for RK3228 SoCs commit 6d5853ffe655192d4b18d7092bb060d5e69d777c Merge: d7c38ff 1f664ab Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:53:01 2016 +0200 Merge tag 'mvebu-arm64-4.7-1' of git://git.infradead.org/linux-mvebu into next/arm64 Merge "mvebu arm64 for 4.7" from Gregory CLEMENT: - Mention the arm64 SoCs in the MAINTAINER file - Enable syscon drivers for Marvell Armada 7K/8K (replacing the clk one) * tag 'mvebu-arm64-4.7-1' of git://git.infradead.org/linux-mvebu: MAINTAINERS: update entry for Marvell ARM platform maintainers arm64: marvell: enable AP806 and CP110 syscon driver commit e5d8b0ad5ae4c70a7081865a3c6c83ae1afe3087 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:38 2016 +0200 arm64: configs: add options useful for Armada 7K/8K support This commit updates the ARM64 defconfig to include additional options useful to support the Armada 7K/8K platforms: - the SPI controller driver, spi-orion - the support for SPI flashes Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/configs/defconfig | 4 ++++ 1 file changed, 4 insertions(+) commit d7c38ff1cd868cd61b96cf1ff8c2bd72445332c7 Author: Andre Przywara <andre.przywara@arm.com> Date: Thu May 5 10:44:18 2016 +0100 arm64: defconfig: Add Juno SATA controller The ARM Juno (r1 and r2) boards feature a SATA controller soldered on the board and connected to the PCI bus. Add the respective driver to defconfig to get hard disks supported out of the box on the Junos. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit cbeefdab99941648729c3839626c908b8f04fec7 Merge: e45a70b 3892132 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:32:09 2016 +0200 Merge tag 'imx-defconfig64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/arm64 Merge "The arm64 defconfig update for Freescale/NXP support" from Shawn Guo: - Clean up defconfig with savedefconfig - Enable 48-bit virtual address support - Enable driver support for various Freescale/NXP devices * tag 'imx-defconfig64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: arm64: defconfig: enable freescale/nxp config options arm64: defconfig: enable 48-bit virtual addresses arm64: defconfig: cleanup the defconfig commit b80dc598eb997bf8a7942fa0cedc1e02001825f7 Merge: 2cbb21d f0d5236 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:30:01 2016 +0200 Merge tag 'at91-defconfig2' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91 into next/defconfig Merge "Second batch of defconfig" from Nicolas Ferre: - sama5_defconfig: update to support easy use of systemd userspace * tag 'at91-defconfig2' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91: ARM: at91/defconfig: sama5: add CONFIG_FHANDLE ARM: at91: sama5: Update defconfig ARM: multi_v7_defconfig: add the Atmel sama5d2-compatible ADC driver ARM: multi_v7_defconfig: add the Atmel Audio microphone interface PDMIC ARM: multi_v7_defconfig: add Atmel ISI (Image Sensor Interface) driver ARM: multi_v7_defconfig: add Atmel watchdog timers ARM: multi_v7_defconfig: add HLCDC drivers as modules ARM: at91/defconfig: add PDMIC driver to sama5_defconfig ARM: at91/defconfig: add HLCDC driver to sama5_defconfig ARM: at91/defconfig: add the HDMA controller to sama5_defconfig commit 2cbb21d749efb9ca1eef04f04d189d4961b33b79 Merge: 11d708f d0bc348 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:25:54 2016 +0200 Merge tag 'aspeed-for-4.7-defconfig' of https://github.com/shenki/linux into next/defconfig Merge "aspeed defconfig for 4.7" from Joel Stanley: This adds configurations used for testing Aspeed BMC SoCs, as well as adding the v5 part to the multi defconfig. * tag 'aspeed-for-4.7-defconfig' of https://github.com/shenki/linux: arm/configs: Add Aspeed defconfig arm/configs/multi_v5: Add Aspeed ast2400 commit 11d708f414a78b8e2903cbcff34bec69c73ba1b5 Merge: 48bc03e 35bee33 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:24:06 2016 +0200 Merge tag 'ux500-defconfig-armsoc2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson into next/defconfig Merge "Ux500 defconfig update for v4.7" from Linus Walleij: - Remove the unused MACH_UX500_DT option from the multi_v7 defconfig - Remove staging driver from u8500_defconfig - Update sensor support in u8500_defconfig * tag 'ux500-defconfig-armsoc2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson: ARM: u8500_defconfig: update sensor config ARM: u8500_defconfig: remove staging from defconfig ARM: multi_v7_defconfig: Remove unused Kconfig option MACH_UX500_DT commit 35bee33355db8347d5f84caef9d2ddde200b8ba6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 2 10:38:04 2016 +0200 ARM: u8500_defconfig: update sensor config The Ux500 is using buffered IIO as the sensors support IRQs. The BH1780 ambient light sensor was added to IIO, so disable the old misc driver and activate the driver in IIO. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/configs/u8500_defconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6cf8440c2b7bf7db3925dfe5419985f19046e5ca Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 2 10:34:09 2016 +0200 ARM: u8500_defconfig: remove staging from defconfig Ux500 was enabling the staging drivers due to the RMI4 touchscreen driver, this is now properly upstream, so drop this and the dead symbol for the old RMI4 hack from the defconfig. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/configs/u8500_defconfig | 2 -- 1 file changed, 2 deletions(-) commit 3ef875479c93bcd7e8ec4ffd1c71ea59afc20643 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Mar 31 09:45:24 2016 +0100 ARM: multi_v7_defconfig: Remove unused Kconfig option MACH_UX500_DT Cc: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/configs/multi_v7_defconfig | 1 - 1 file changed, 1 deletion(-) commit 48bc03e5411eb0fd006e54ba62ca77a6dfe5c68d Merge: b6e3f6d 2ead04d Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:08:29 2016 +0200 Merge tag 'imx-defconfig-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/defconfig Merge "i.MX defconfig updates for 4.7" from Shawn Guo: - Update multi_v5_defconfig for i.MX21/27 and systemd support - Update imx_v6_v7_defconfig to support devices found on various i.MX6 board: FT5x06 and TSC2004 touch, I2C GPIO, MICREL PHY and M41T80 RTC * tag 'imx-defconfig-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: imx_v6_v7_defconfig: add CONFIG_MICREL_PHY ARM: imx_v6_v7_defconfig: add CONFIG_I2C_GPIO ARM: multi_v5_defconfig: Enable recommended options for systemd ARM: multi_v5_defconfig: Enable support for MX21/MX27 ARM: imx_v6_v7_defconfig: add CONFIG_RTC_DRV_M41T80 ARM: imx_v6_v7_defconfig: add CONFIG_I2C_MUX_GPIO ARM: imx_v6_v7_defconfig: add FT5x06 and TSC2004 touch support commit b6e3f6d543777eec632b3639a32335e2d04768b3 Merge: cbf3bbe fe42f03 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:06:01 2016 +0200 Merge tag 'tegra-for-4.7-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/defconfig Merge "ARM: tegra: Default configuration updates for v4.7-rc1" from Thierry Reding: Enable the XUSB pad controller and XUSB controller drivers on the Tegra and multi-v7 default configurations. * tag 'tegra-for-4.7-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: ARM: multi_v7: Enable Tegra XUSB controller in defconfig ARM: tegra: Enable XUSB controller in defconfig commit cbf3bbeb2e0a5a996207d48c0546c7ae5fc5e8f4 Merge: a651b61 8b182f3 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 14:03:53 2016 +0200 Merge tag 'davinci-for-v4.7/defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/defconfig Merge "DaVinci defconfig updates for v4.7" from Sekhar Nori: Some defconfig updates to support systemd based filesystems, SPI NOR and GPIO sysfs entries. * tag 'davinci-for-v4.7/defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: davinci_all_defconfig: enable SPI and NOR as modules ARM: davinci_all_defconfig: support systemd ARM: davinci_all_defconfig: enable GPIO_SYSFS commit 5b64250b614a9d3dff380035be17811cd479d8e8 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Sun May 8 15:08:22 2016 +0200 gpio: dt-bindings: add wd,mbl-gpio bindings This patch adds the device tree bindings for the Western Digital's MyBook Live memory-mapped GPIO controllers. The gpios will be supported by gpio-mmio code of the GPIO generic library. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Acked-by: Rob Herring <robh@kernel.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> .../devicetree/bindings/gpio/wd,mbl-gpio.txt | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit 41caed560f800768f0f475ff2bec1e1b92674c0b Merge: d6a58a5 f5515f9 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 10 13:48:48 2016 +0200 Merge branch 'renesas/fixes-2' into next/dt64 This merges fixes from linux-4.6 into the next/dt64 tree to avoid a later merge conflict. * renesas/fixes-2: arm64: dts: r8a7795: Don't disable referenced optional scif clock ARM: shmobile: timer: Fix preset_lpj leading to too short delays Revert "ARM: dts: porter: Enable SCIF_CLK frequency and pins" ARM: dts: r8a7791: Don't disable referenced optional clocks commit 3beed93c16170eacbfaa189dd4c1dc71866d3d3a Author: Patrice Chotard <patrice.chotard@st.com> Date: Fri Apr 29 16:25:43 2016 +0200 pinctrl: stm32: Implement .pin_config_dbg_show() Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/stm32/pinctrl-stm32.c | 174 ++++++++++++++++++++++++++++++++++ 1 file changed, 174 insertions(+) commit fd9c55315db9bc89c54bb644a0f8b1f9306010d4 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 15:26:26 2016 +0200 gpio: of: make it possible to name GPIO lines Make it possible to name the producer side of a GPIO line using a "gpio-line-names" property array, modeled on the "clock-output-names" property from the clock bindings. This naming is especially useful for: - Debugging: lines are named after function, not just opaque offset numbers. - Exploration: systems where some or all GPIO lines are available to end users, such as prototyping, one-off's "makerspace usecases" users are helped by the names of the GPIO lines when tinkering. This usecase has been surfacing recently. The gpio-line-names attribute is completely optional. Example output from lsgpio on a patched Snowball tree: GPIO chip: gpiochip6, "8000e180.gpio", 32 GPIO lines line 0: unnamed unused line 1: "AP_GPIO161" "extkb3" [kernel] line 2: "AP_GPIO162" "extkb4" [kernel] line 3: "ACCELEROMETER_INT1_RDY" unused [kernel] line 4: "ACCELEROMETER_INT2" unused line 5: "MAG_DRDY" unused [kernel] line 6: "GYRO_DRDY" unused [kernel] line 7: "RSTn_MLC" unused line 8: "RSTn_SLC" unused line 9: "GYRO_INT" unused line 10: "UART_WAKE" unused line 11: "GBF_RESET" unused line 12: unnamed unused Cc: Grant Likely <grant.likely@linaro.org> Cc: Amit Kucheria <amit.kucheria@linaro.org> Cc: David Mandala <david.mandala@linaro.org> Cc: Lee Campbell <leecam@google.com> Cc: devicetree@vger.kernel.org Acked-by: Rob Herring <robh@kernel.org> Reviewed-by: Michael Welling <mwelling@ieee.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/devicetree/bindings/gpio/gpio.txt | 19 ++++++++++ drivers/gpio/gpiolib-of.c | 49 +++++++++++++++++++++++++ 2 files changed, 68 insertions(+) commit ca21872e43e82c2a5c2e056ee4aea40a921720b1 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Sat May 7 12:15:34 2016 +0200 s390: add missing include statements arch_mmap_rnd, cpu_have_feature, and arch_randomize_brk are all defined as globally visible variables. However the files they are defined in do not include the header files with the declaration. To avoid a possible mismatch add the missing include statements so we have proper type checking in place. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/process.c | 1 + arch/s390/kernel/processor.c | 1 + arch/s390/mm/mmap.c | 1 + 3 files changed, 3 insertions(+) commit 521b00cd7a6491fbec7d1ede5b6b33f106a6addc Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Sat May 7 12:15:21 2016 +0200 s390: add missing declarations arch_dup_task_struct and the per cpu variable mt_cycles are globally visible, but do not have any header file with a declaration. Therefore add it so we have proper type checking in place. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/include/asm/thread_info.h | 1 + arch/s390/kernel/entry.h | 4 ++++ arch/s390/kernel/vtime.c | 2 ++ 3 files changed, 7 insertions(+) commit f70a34c57602f5791a63869db95f3b97276cd1d2 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Sat May 7 12:14:29 2016 +0200 s390: make couple of variables and functions static copy_oldmem_user() and ap_jumptable are private to the files they are being used in. Therefore make them static. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/crash_dump.c | 2 +- drivers/s390/crypto/ap_bus.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 4c07a399f98278f2a784cdf71053c85a4082f4db Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Fri May 6 10:57:33 2016 +0200 s390/cache: remove superfluous locking With "s390/cpuinfo: simplify locking and skip offline cpus early" we prevent already that cpus will go away. The additional get_online_cpus() / put_online_cpus() within show_cacheinfo() is not needed anymore. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/cache.c | 2 -- 1 file changed, 2 deletions(-) commit 281eaa8cb67c27e56da1e7fd6b55c6cd3e8c4638 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Wed Apr 13 14:49:12 2016 +0200 s390/cpuinfo: simplify locking and skip offline cpus early Move the get_online_cpus() and put_online_cpus() to the start and stop operation of the seqfile ops. This way there is no need to lock cpu hotplug again and again for each single cpu. This way we can also skip offline cpus early if we simply use cpumask_next() within the next operation. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/processor.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit 0c756914920fc13061222d12fbbe85990df64928 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon May 2 15:09:01 2016 +0200 s390/3270: hangup the 3270 tty after a disconnect The disconnect and later reconnect of a 3270 terminal does not do a tty hangup. The current session is resumed which is a security issue. Do a tty hangup after a unit check has been received. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/tty3270.c | 38 +++++++++++++++++++++++++++++++++++--- 1 file changed, 35 insertions(+), 3 deletions(-) commit 7e36eff1eece29eaa37501806ded0e0fb88e61ee Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon May 2 15:07:00 2016 +0200 s390/3270: handle reconnect of a tty with a different size If an existing 3270 terminal disconnects and reconnects with a different size, the 3270 driver still works with the old size. If the new dimensions are larger the output merely looks funny, if the new dimensions are smaller the terminal is unusable. To fix this restart the size detection after a unit check has been received. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/raw3270.c | 32 +++++++++++++++++++++++++++++--- drivers/s390/char/tty3270.c | 25 ++++++++++++++++++++++++- 2 files changed, 53 insertions(+), 4 deletions(-) commit ffe1b6c453ef49e6fcf31c23636333aa4e65aa47 Author: Wang Hongcheng <annie.wang@amd.com> Date: Mon Mar 14 10:29:09 2016 +0800 video: AMBA CLCD: Remove unncessary include in amba-clcd.c The header file asm/sizes.h is unnecessary. And it can also be compiled under X86 arch after the removal. Signed-off-by: Wang Hongcheng <annie.wang@amd.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/amba-clcd.c | 2 -- 1 file changed, 2 deletions(-) commit 80403b232b7af033bb5a2043fc4d60f16e46519f Author: Julian Scheel <julian@jusst.de> Date: Thu Mar 24 22:14:23 2016 +0100 fbdev: ssd1307fb: Fix charge pump setting Make sure bit 4 is set for the charge pump setting. It is required according to SSD1306 App Note. Signed-off-by: Julian Scheel <julian@jusst.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/ssd1307fb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 676970e55b1033af7f0a03d4037b4d9b76327ded Author: Antonio Quartulli <a@unstable.cc> Date: Fri Mar 11 14:01:10 2016 +0100 batman-adv: use batadv_compare_eth when possible When comparing Ethernet address it is better to use the more generic batadv_compare_eth. The latter is also optimised for architectures having a fast unaligned access. Signed-off-by: Antonio Quartulli <a@unstable.cc> [sven@narfation.org: fix conflicts with current version] Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> net/batman-adv/network-coding.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 9d1601ef4347b27dfa627d61ccfa9a724cc6e303 Author: Marek Lindner <mareklindner@neomailbox.ch> Date: Sun Mar 20 18:39:56 2016 +0800 batman-adv: replace ethertype variable with ETH_P_BATMAN for readability Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Reviewed-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/soft-interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4b426b108ac82b27f5af40df7da05a2501fd2aca Author: Sven Eckelmann <sven@narfation.org> Date: Mon Feb 22 21:02:39 2016 +0100 batman-adv: Use bool as return type for boolean functions It is easier to understand that the returned value of a specific function doesn't have to be 0 when the functions was successful when the actual return type is bool. This is especially true when all surrounding functions with return type int use negative values to return the error code. Reported-by: Nicholas Krause <xerofoify@gmail.com> Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 23 ++--- net/batman-adv/bitarray.c | 16 +-- net/batman-adv/bitarray.h | 15 +-- net/batman-adv/bridge_loop_avoidance.c | 175 +++++++++++++++++---------------- net/batman-adv/bridge_loop_avoidance.h | 43 ++++---- net/batman-adv/debugfs.c | 2 +- net/batman-adv/distributed-arp-table.c | 6 +- net/batman-adv/hard-interface.c | 15 ++- net/batman-adv/hash.h | 6 +- net/batman-adv/main.h | 2 +- net/batman-adv/network-coding.c | 12 +-- net/batman-adv/originator.c | 4 +- net/batman-adv/originator.h | 2 +- net/batman-adv/routing.c | 37 +++---- net/batman-adv/routing.h | 6 +- net/batman-adv/soft-interface.c | 6 +- net/batman-adv/soft-interface.h | 3 +- net/batman-adv/translation-table.c | 31 +++--- 18 files changed, 205 insertions(+), 199 deletions(-) commit f0b94ebccd2b924237ca7a101da3db70c3a8f0f2 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 19:05:24 2016 +0100 batman-adv: Use kref_get for _batadv_update_route _batadv_update_route requires that the caller already has a valid reference for neigh_node. It is therefore not possible that it has an reference counter of 0 and was still given to this function The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/routing.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 17a8691502c9d2d792cfea7253b17382279ffb3e Author: Sven Eckelmann <sven@narfation.org> Date: Mon Apr 11 13:06:40 2016 +0200 batman-adv: Use kref_get for hard_iface subfunctions The callers of the functions using batadv_hard_iface objects already make sure that they hold a valid reference. The subfunctions don't have to check whether the reference counter is > 0 because this was checked by the callers. The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 14 +++----------- net/batman-adv/hard-interface.c | 7 +++---- net/batman-adv/originator.c | 30 +++++++----------------------- 3 files changed, 13 insertions(+), 38 deletions(-) commit c3ba37a778ecab4f8ddb117a2ceff3e13184a7db Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:23 2016 +0100 batman-adv: Use kref_get for batadv_gw_node_add batadv_gw_node_add requires that the caller already has a valid reference for orig_node. It is therefore not possible that it has an reference counter of 0 and was still given to this function The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/gateway_client.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit a08d497d6718d579e496a801115aecc1c4fbb770 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:22 2016 +0100 batman-adv: Use kref_get for batadv_gw_select batadv_gw_select requires that the caller already has a valid reference for new_gw_node. It is therefore not possible that it has an reference counter of 0 and was still given to this function The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/gateway_client.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0de32ceee156787429035c974316f4e5098cf722 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:21 2016 +0100 batman-adv: Use kref_get for batadv_nc_get_nc_node batadv_nc_get_nc_node requires that the caller already has a valid reference for orig_neigh_node. It is therefore not possible that it has an reference counter of 0 and was still given to this function The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/network-coding.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit c9dad805e9f4fd3978f22c970bae49eaa00b46dd Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:20 2016 +0100 batman-adv: Use kref_get for batadv_tvlv_container_get batadv_tvlv_container_get requires that tvlv.container_list_lock is held by the caller. It is therefore not possible that an item in tvlv.container_list has an reference counter of 0 and is still in the list The kref_get function instead WARNs (with debug information) when the reference counter would still be 0. This makes a bug in batman-adv better visible because kref_get_unless_zero would have ignored this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/main.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit d7d6de9530db7e385a05e1ae6cde642a617e6c89 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:18 2016 +0100 batman-adv: Increase hard_iface refcnt for ptype The hard_iface is referenced in the packet_type for batman-adv. Increase the refcounter of the hard_interface for it to have an explicit reference for it in case this functionality gets refactorted and the currently used implicit reference for it will be removed. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/hard-interface.c | 2 ++ 1 file changed, 2 insertions(+) commit 4fe56e60ac1be4d103f64743d0a36fd31a70657c Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:17 2016 +0100 batman-adv: Check hard_iface refcnt when receiving skb The receive function may start processing an incoming packet while the hard_iface is shut down in a different context. All called functions called with the batadv_hard_iface object belonging to the incoming interface would have to check whether the reference counter is still > 0. This is rather error-prone because this check can be forgotten easily. Instead check the reference counter when receiving the object to make sure that all called functions have a valid reference. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/main.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit 273534468f050744b32054f84a1e20ee6b5bd329 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 16:09:16 2016 +0100 batman-adv: Check hard_iface refcnt before calling function The batadv_hardif_list list is checked in many situations and the items in this list are given to specialized functions to modify the routing behavior. At the moment each of these called functions has to check itself whether the received batadv_hard_iface has a refcount > 0 before it can increase the reference counter and use it in other objects. This can easily lead to problems because it is not easily visible where all callers of a function got the batadv_hard_iface object from and whether they already hold a valid reference. Checking the reference counter directly before calling a subfunction with a pointer from the batadv_hardif_list avoids this problem. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 11 +++++++++++ net/batman-adv/bat_v_ogm.c | 14 +++++++++++++- net/batman-adv/originator.c | 5 +++++ net/batman-adv/send.c | 6 ++++++ 4 files changed, 35 insertions(+), 1 deletion(-) commit cd9c7bfbbae81bbe75de585ac57b1097e86cf109 Author: Simon Wunderlich <simon.wunderlich@open-mesh.com> Date: Sat Mar 12 10:49:33 2016 +0100 batman-adv: add detection for complex bridge loops There are network setups where the current bridge loop avoidance can't detect bridge loops. The minimal setup affected would consist of two LANs and two separate meshes, connected in a ring like that: A...(mesh1)...B | | (LAN1) (LAN2) | | C...(mesh2)...D Since both the meshes and backbones are separate, the bridge loop avoidance has not enough information to detect and avoid the loop in this case. Even if these scenarios can't be fixed easily, these kind of loops can be detected. This patch implements a periodic check (running every 60 seconds for now) which sends a broadcast frame with a random MAC address on each backbone VLAN. If a broadcast frame with the same MAC address is received shortly after on the mesh, we know that there must be a loop and report that incident as well as throw an uevent to let others handle that problem. Signed-off-by: Simon Wunderlich <simon.wunderlich@open-mesh.com> [sven@narfation.org: fix conflicts with current version] Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bridge_loop_avoidance.c | 139 +++++++++++++++++++++++++++++++++ net/batman-adv/main.h | 4 + net/batman-adv/packet.h | 1 + net/batman-adv/sysfs.c | 6 +- net/batman-adv/types.h | 8 ++ 5 files changed, 156 insertions(+), 2 deletions(-) commit 2cd45a0671d9e37ab20e844fc4c84717a38b7f52 Author: Andrew Lunn <andrew@lunn.ch> Date: Thu Apr 21 12:57:27 2016 +0200 batman-adv: Create batman soft interfaces within correct netns. When creating a soft interface, create it in the same netns as the hard interface. Replace all references to init_net with the correct name space for the interface being manipulated. Suggested-by: Daniel Ehlers <danielehlers@mindeye.net> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Antonio Quartulli <a@unstable.cc> Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/hard-interface.c | 10 +++++----- net/batman-adv/hard-interface.h | 3 ++- net/batman-adv/soft-interface.c | 7 +++++-- net/batman-adv/soft-interface.h | 3 ++- net/batman-adv/sysfs.c | 3 ++- net/batman-adv/translation-table.c | 4 ++-- 6 files changed, 18 insertions(+), 12 deletions(-) commit 0d21cdaa9bbf5efae95cfb6346d26ff6e61f8896 Author: Andrew Lunn <andrew@lunn.ch> Date: Tue Mar 1 22:19:05 2016 +0100 batman-adv: NETIF_F_NETNS_LOCAL feature to prevent netns moves The batX soft interface should not be moved between network name spaces. This is similar to bridges, bonds, tunnels, which are not allowed to move between network namespaces. Suggested-by: Daniel Ehlers <danielehlers@mindeye.net> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Antonio Quartulli <a@unstable.cc> Reviewed-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/soft-interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7142fc107274a0ebfd31e995de61e71a1e84770f Author: Sven Eckelmann <sven@narfation.org> Date: Sun Feb 28 11:38:52 2016 +0100 batman-adv: Remove hdr_size skb size check in batadv_interface_rx The callers of batadv_interface_rx have to make sure that enough data can be pulled from the skb when they read the batman-adv header. The only two functions using it are either calling pskb_may_pull with hdr_size directly (batadv_recv_bcast_packet) or indirectly via batadv_check_unicast_packet (batadv_recv_unicast_packet). Reported-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/soft-interface.c | 4 ---- 1 file changed, 4 deletions(-) commit 6535db56d5453555b7a40230024225d9ec700585 Author: Sven Eckelmann <sven@narfation.org> Date: Sun Feb 28 11:38:51 2016 +0100 batman-adv: Remove unused parameter recv_if of batadv_interface_rx Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/routing.c | 5 ++--- net/batman-adv/soft-interface.c | 5 ++--- net/batman-adv/soft-interface.h | 4 ++-- 3 files changed, 6 insertions(+), 8 deletions(-) commit e930c765ca5c6b039cd22ebfb4504ea7b5dab43d Author: Catalin Vasile <cata.vasile@nxp.com> Date: Fri May 6 16:18:53 2016 +0300 crypto: caam - fix caam_jr_alloc() ret code caam_jr_alloc() used to return NULL if a JR device could not be allocated for a session. In turn, every user of this function used IS_ERR() function to verify if anything went wrong, which does NOT look for NULL values. This made the kernel crash if the sanity check failed, because the driver continued to think it had allocated a valid JR dev instance to the session and at some point it tries to do a caam_jr_free() on a NULL JR dev pointer. This patch is a fix for this issue. Cc: <stable@vger.kernel.org> Signed-off-by: Catalin Vasile <cata.vasile@nxp.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/caam/jr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5ca55738201c7ae1b556ad87bbb22c139ecc01dd Author: Paulo Flabiano Smorigo <pfsmorigo@linux.vnet.ibm.com> Date: Thu May 5 11:09:27 2016 -0300 crypto: vmx - comply with ABIs that specify vrsave as reserved. It gives significant improvements ( ~+15%) on some modes. These code has been adopted from OpenSSL project in collaboration with the original author (Andy Polyakov <appro@openssl.org>). Signed-off-by: Paulo Flabiano Smorigo <pfsmorigo@linux.vnet.ibm.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/vmx/ppc-xlate.pl | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit ad6a2d0f8d2991102e89a0b24a0a49fa7b0ec844 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:21 2016 +0100 Documentation: fb: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Documentation/fb/udlfb.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 524edf3877775c46e8b3ba56f9dd75d07914392c Author: Alexey Khoroshilov <khoroshilov@ispras.ru> Date: Tue May 3 05:22:27 2016 +0300 fbdev: fbmem: implement error handling in fbmem_init() fbmem_init() ignores all errors, while fbmem_exit() does not check if deallocating resources are valid. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/core/fbmem.c | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) commit a525d0eab17d2ca39c3fbc03783eb2350b040d45 Merge: bae6692 5c08b0f Author: Luca Coelho <luciano.coelho@intel.com> Date: Tue May 10 11:56:24 2016 +0300 Merge tag 'iwlwifi-for-kalle-2016-05-04' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes * fix P2P rates (and possibly other issues) Signed-off-by: Luca Coelho <luciano.coelho@intel.com> commit 18b6562c243f3a4be91a7a240090ebefccf39761 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Apr 4 10:48:04 2016 +0900 fbdev: sh_mipi_dsi: remove driver Remove the sh_mipi_dsi driver as it appears to be unused since c0bb9b302769 ("ARCH: ARM: shmobile: Remove ag5evm board support"). Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/Kconfig | 4 - drivers/video/fbdev/Kconfig | 1 - drivers/video/fbdev/Makefile | 1 - drivers/video/fbdev/sh_mipi_dsi.c | 587 -------------------------------------- include/video/sh_mipi_dsi.h | 59 ---- 5 files changed, 652 deletions(-) commit cc6df3a24587b3c9f191e34ffb67e269766e2ffc Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Wed May 4 11:43:18 2016 +0200 video: fbdev: imxfb: add some error handling clk_prepare_enable can fail and if it does the controller must not be considered enabled. So check for errors, properly unwind and give the error code back to the caller. While touching the clock code also enable the clocks in the same direction and disable in reverse order. Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/imxfb.c | 35 +++++++++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 8 deletions(-) commit 46ffe1097bc05d6ca8c5b293cbfe167d17447af1 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Wed May 4 11:43:16 2016 +0200 video: fbdev: imxfb: fix semantic of .get_power and .set_power .set_power gets passed an FB_BLANK_XXX value, not a bool. So 0 signals on; and >1 means off. The same applies for return values of .get_power. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/imxfb.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 0400ed0a083a6567d45df96fb813f4702ece7d1b Author: Dong Aisheng <aisheng.dong@nxp.com> Date: Thu Apr 21 00:51:31 2016 +0800 mmc: core: remove the invalid message in mmc_select_timing mmc_select_hs200() and mmc_select_hs() will keep the timing as before if switch fails. So it's meaningless to print the failed switched mode outside based on the current host timing. Furthermore, the original print is wrong, it should be: pr_warn("%s: switch to %s failed\n", mmc_hostname(card->host), mmc_card_hs(card) ? "high-speed" : (mmc_card_hs200(card) ? "hs200" : "")); Since we already have error message in mmc_select_hs200(), simply remove it outside. Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) commit e51534c806609c806d81bfb034f02737461f855c Author: Dong Aisheng <aisheng.dong@nxp.com> Date: Thu Apr 21 00:51:30 2016 +0800 mmc: core: fix using wrong io voltage if mmc_select_hs200 fails Currently MMC core will keep going if HS200/HS timing switch failed with -EBADMSG error by the assumption that the old timing is still valid. However, for mmc_select_hs200 case, the signal voltage may have already been switched. If the timing switch failed, we should fall back to the old voltage in case the card is continue run with legacy timing. If fall back signal voltage failed, we explicitly report an EIO error to force retry during the next power cycle. Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 54a5e73f4d6e31d5628e08b4d575c71d71670e09 Author: Laurence Oberman <loberman@redhat.com> Date: Tue May 10 01:23:17 2016 -0700 tcm_qla2xxx Add SCSI command jammer/discard capability This patch introduces support for TCM_QLA2XXX_DEBUG and associated tcm_qla2xxx_tpg->tpg_attrib.jam_host checking used to test dropped packets to FC host environments. Tested by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Laurence Oberman <loberman@redhat.com> Acked-by: Himanshu Madhani <himanshu.madhani@qlogic.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> Documentation/scsi/tcm_qla2xxx.txt | 22 ++++++++++++++++++++++ drivers/scsi/qla2xxx/Kconfig | 9 +++++++++ drivers/scsi/qla2xxx/tcm_qla2xxx.c | 20 ++++++++++++++++++++ drivers/scsi/qla2xxx/tcm_qla2xxx.h | 1 + 4 files changed, 52 insertions(+) commit 2b16509c5f26d6c160bd89164cf18f18d713daf6 Author: Imran Haider <imran1008@gmail.com> Date: Sun May 8 11:17:54 2016 -0400 iscsi-target: graceful disconnect on invalid mapping to iovec Ensures the first page entry is within bounds. A failed check would terminate the iSCSI connection instead of causing a NULL-dereference. This violation seems to happen with certain iSCSI commands where the computed CDB length is zero but the expected transfer length is non-zero. The real problem is probably on the iSCSI initiator side since there is a discrepancy between the iSCSI header and the encapsulated CDB Opcode. Signed-off-by: Imran Haider <imran1008@gmail.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit cb7911694771faf16930b72a104d3cd41d500e2c Author: Colin Ian King <colin.king@canonical.com> Date: Fri May 6 00:16:17 2016 +0100 target: need_to_release is always false, remove redundant check and kfree The removal the #ifdef'd code on CONFIG_ARCH_HAS_SG_CHAIN in commit 02c4de53add1b79 ("target/rd: always chain S/G list") removed the setting of need_to_release to true, so we are now left with need_to_release always being false and hence the conditional kfree is never reached. Clean up the dead code by removing need_to_release and the conditional kfree. Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_rd.c | 4 ---- 1 file changed, 4 deletions(-) commit d94331fab6d4d48280a5cea646352db90777966d Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:25 2016 +0200 target: remove sess_kref and ->shutdown_session Both of them are unused now that drivers handle any delayed session shutdown internally. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_tpg.c | 14 +++----------- drivers/target/target_core_transport.c | 23 ----------------------- include/target/target_core_base.h | 1 - include/target/target_core_fabric.h | 6 ------ 4 files changed, 3 insertions(+), 41 deletions(-) commit 44f33d0fb5a7181cc34529c211d7b5039d8a0a4b Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:24 2016 +0200 iscsi-target: remove usage of ->shutdown_session ->shutdown session only decideѕ if the target core calls ->close_session directly, or if the fabrics drivers calls it manually later through target_put_session, which at this point will always close the session as it has been removed from the lookup list and thus no new references will be acquired from the core. So instead remove ->shutdown and have the core call ->close_session directly, and replace all calls to target_put_session in the iSCSI target with direct calls to iscsit_close_session. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 10 +++++++--- drivers/target/iscsi/iscsi_target_configfs.c | 19 ++----------------- drivers/target/iscsi/iscsi_target_erl0.c | 2 +- drivers/target/iscsi/iscsi_target_login.c | 4 ++-- 4 files changed, 12 insertions(+), 23 deletions(-) commit e3dc0e316559de8c0139bc84d82244e0907c4f17 Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:23 2016 +0200 tcm_qla2xxx: introduce a private sess_kref This stops abusing the common sess_kref to overload it for private usage, which allows removing the shutdown_session method as well. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/scsi/qla2xxx/qla_target.c | 56 +++++++++++++++++++++----------------- drivers/scsi/qla2xxx/qla_target.h | 4 +-- drivers/scsi/qla2xxx/tcm_qla2xxx.c | 39 ++------------------------ 3 files changed, 35 insertions(+), 64 deletions(-) commit 36ec2ddc0d9309d52e14eb84c0807a78604460dc Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:22 2016 +0200 target: make close_session optional Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> Documentation/target/tcm_mod_builder.py | 8 -------- drivers/target/loopback/tcm_loop.c | 6 ------ drivers/target/sbp/sbp_target.c | 6 ------ drivers/target/target_core_configfs.c | 4 ---- drivers/target/target_core_transport.c | 3 ++- drivers/usb/gadget/function/f_tcm.c | 5 ----- drivers/vhost/scsi.c | 6 ------ drivers/xen/xen-scsiback.c | 5 ----- 8 files changed, 2 insertions(+), 41 deletions(-) commit 22d11759a4e7018f8cd7914e4e706ca2c96d6c01 Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:21 2016 +0200 target: make ->shutdown_session optional Turns out the template and thus many drivers got the return value wrong: 0 means the fabrics driver needs to put a session reference, which no driver except for the iSCSI target drivers did. Fortunately none of these drivers supports explicit Node ACLs, so the bug was harmless. Even without that only qla2xxx and iscsi every did real work in shutdown_session, so get rid of the boilerplate code in all other drivers. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> Documentation/target/tcm_mod_builder.py | 8 -------- drivers/infiniband/ulp/srpt/ib_srpt.c | 9 --------- drivers/target/loopback/tcm_loop.c | 6 ------ drivers/target/sbp/sbp_target.c | 6 ------ drivers/target/target_core_configfs.c | 4 ---- drivers/target/target_core_tpg.c | 5 ++++- drivers/target/tcm_fc/tcm_fc.h | 1 - drivers/target/tcm_fc/tfc_conf.c | 1 - drivers/target/tcm_fc/tfc_sess.c | 12 ------------ drivers/usb/gadget/function/f_tcm.c | 6 ------ drivers/vhost/scsi.c | 6 ------ drivers/xen/xen-scsiback.c | 6 ------ 12 files changed, 4 insertions(+), 66 deletions(-) commit fba81f8831b20272a97a990e5d47c332e9b1f65d Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:20 2016 +0200 target: remove acl_stop Ensure we can use list_empty on the sess_acl_list to remove the need for this flag. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_tpg.c | 13 +++++-------- drivers/target/target_core_transport.c | 4 ++-- include/target/target_core_base.h | 1 - 3 files changed, 7 insertions(+), 11 deletions(-) commit bc6e6bb470eda42f44bcac96c261cff1216577b3 Author: Christoph Hellwig <hch@lst.de> Date: Mon May 2 15:45:19 2016 +0200 target: consolidate and fix session shutdown Factor out a helper to shutdown sessions for a Node ACL, and make it properly restart the list walk after dropping the lock. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_tpg.c | 87 +++++++++++++++------------------------- 1 file changed, 33 insertions(+), 54 deletions(-) commit d2d3462f9f08da364c8fbd41e8e32229d610d49d Author: Kees Cook <keescook@chromium.org> Date: Mon May 9 13:22:09 2016 -0700 x86/KASLR: Clarify purpose of each get_random_long() KASLR will be calling get_random_long() twice, but the debug output won't distinguishing between them. This patch adds a report on when it is fetching the physical vs virtual address. With this, once the virtual offset is separate, the report changes from: KASLR using RDTSC... KASLR using RDTSC... into: Physical KASLR using RDTSC... Virtual KASLR using RDTSC... Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-7-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 071a74930e60d1fa51207d71f00a35b4f9d4d179 Author: Baoquan He <bhe@redhat.com> Date: Mon May 9 13:22:08 2016 -0700 x86/KASLR: Add virtual address choosing function To support randomizing the kernel virtual address separately from the physical address, this patch adds find_random_virt_addr() to choose a slot anywhere between LOAD_PHYSICAL_ADDR and KERNEL_IMAGE_SIZE. Since this address is virtual, not physical, we can place the kernel anywhere in this region, as long as it is aligned and (in the case of kernel being larger than the slot size) placed with enough room to load the entire kernel image. For clarity and readability, find_random_addr() is renamed to find_random_phys_addr() and has "size" renamed to "image_size" to match find_random_virt_addr(). Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote changelog, refactored slot calculation for readability. ] [ Renamed find_random_phys_addr() and size argument. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-6-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) commit 06486d6c97cebc2433a40a979f3849cd68184de9 Author: Kees Cook <keescook@chromium.org> Date: Mon May 9 13:22:07 2016 -0700 x86/KASLR: Return earliest overlap when avoiding regions In preparation for being able to detect where to split up contiguous memory regions that overlap with memory regions to avoid, we need to pass back what the earliest overlapping region was. This modifies the overlap checker to return that information. Based on a separate mem_min_overlap() implementation by Baoquan He. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-5-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) commit c401cf1524153f9c2ede7ab8ece403513925770a Author: Baoquan He <bhe@redhat.com> Date: Mon May 9 13:22:06 2016 -0700 x86/KASLR: Add 'struct slot_area' to manage random_addr slots In order to support KASLR moving the kernel anywhere in physical memory (which could be up to 64TB), we need to handle counting the potential randomization locations in a more efficient manner. In the worst case with 64TB, there could be roughly 32 * 1024 * 1024 randomization slots if CONFIG_PHYSICAL_ALIGN is 0x1000000. Currently the starting address of candidate positions is stored into the slots[] array, one at a time. This method would cost too much memory and it's also very inefficient to get and save the slot information into the slot array one by one. This patch introduces 'struct slot_area' to manage each contiguous region of randomization slots. Each slot_area will contain the starting address and how many available slots are in this area. As with the original code, the slot_areas[] will avoid the mem_avoid[] regions. Since setup_data is a linked list, it could contain an unknown number of memory regions to be avoided, which could cause us to fragment the contiguous memory that the slot_area array is tracking. In normal operation this level of fragmentation will be extremely rare, but we choose a suitably large value (100) for the array. If setup_data forces the slot_area array to become highly fragmented and there are more slots available beyond the first 100 found, the rest will be ignored for KASLR selection. The function store_slot_info() is used to calculate the number of slots available in the passed-in memory region and stores it into slot_areas[] after adjusting for alignment and size requirements. Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote changelog, squashed with new functions. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-4-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit cb18ef0da259db611fbf52806592fde5f469ae67 Author: Kees Cook <keescook@chromium.org> Date: Mon May 9 13:22:05 2016 -0700 x86/boot: Add missing file header comments There were some files with missing header comments. Since they are included from both compressed and regular kernels, make note of that. Also corrects a typo in the mem_avoid comments. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 2 +- arch/x86/boot/early_serial_console.c | 4 ++++ arch/x86/mm/ident_map.c | 5 +++++ 3 files changed, 10 insertions(+), 1 deletion(-) commit 434a6c9f90f7ab5ade619455df01ef5ebea533ee Author: Kees Cook <keescook@chromium.org> Date: Mon May 9 13:22:04 2016 -0700 x86/KASLR: Initialize mapping_info every time As it turns out, mapping_info DOES need to be initialized every time, because pgt_data address could be changed during kernel relocation. So it can not be build time assigned. Without this, page tables were not being corrected updated, which could cause reboots when a physical address beyond 2G was chosen. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462825332-10505-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/pagetable.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit 36a39ac967a548154a0fe44d71cb0063fa05010f Author: Borislav Petkov <bp@suse.de> Date: Sat May 7 11:59:40 2016 +0200 x86/boot: Comment what finalize_identity_maps() does So it is not really obvious that finalize_identity_maps() doesn't do any finalization but it *actually* writes CR3 with the ident PGD. Comment that at the call site. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Kees Cook <keescook@chromium.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: akpm@linux-foundation.org Cc: bhe@redhat.com Cc: dyoung@redhat.com Cc: jkosina@suse.cz Cc: linux-tip-commits@vger.kernel.org Cc: luto@kernel.org Cc: vgoyal@redhat.com Cc: yinghai@kernel.org Link: http://lkml.kernel.org/r/20160507100541.GA24613@pd.tnic Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 2 ++ 1 file changed, 2 insertions(+) commit f0d523668cb122905a541cb6b86e3ae49260ae5e Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue May 10 09:57:41 2016 +0200 ARM: at91/defconfig: sama5: add CONFIG_FHANDLE CONFIG_FHANDLE is listed as a mandatory kernel option for systemd. So explicitly enable it to allow easy use of systemd userspace. Reported-by: Marek Vasut <marex@denx.de> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/sama5_defconfig | 1 + 1 file changed, 1 insertion(+) commit 523567168da04bae0f88802ddef49d00072c5d58 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 03:07:39 2016 +0200 btrfs: make find_workspace warn if there are no workspaces Be verbose if there are no workspaces at all, ie. the module init time preallocation failed. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit e721e49dd1681d45d71919f0561f5e978a34153c Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:41:17 2016 +0200 btrfs: make find_workspace always succeed With just one preallocated workspace we can guarantee forward progress even if there's no memory available for new workspaces. The cost is more waiting but we also get rid of several error paths. On average, there will be several idle workspaces, so the waiting penalty won't be so bad. In the worst case, all cpus will compete for one workspace until there's some memory. Attempts to allocate a new one are done each time the waiters are woken up. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit f77dd0d6b2f0f2cf290cacbd48f5eee18586e52b Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:55:15 2016 +0200 btrfs: preallocate compression workspaces Preallocate one workspace for each compression type so we can guarantee forward progress in the worst case. A failure cannot be a hard error as we might not use compression at all on the filesystem. If we can't allocate the workspaces later when need them, it might actually deadlock, but in such situation the system has effectively not enough memory to operate properly. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 6ac10a6ac2b11ada24580cc76dcd0c182061c576 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:15:15 2016 +0200 btrfs: rename and document compression workspace members The names are confusing, pick more fitting names and add comments. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) commit e1860a7724828a341037b010b3f4ff58bad53f95 Author: David Sterba <dsterba@suse.com> Date: Mon May 9 14:11:38 2016 +0200 btrfs: GFP_NOFS does not GFP_HIGHMEM Masking HIGHMEM out of NOFS does not make sense. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/delayed-inode.c | 2 +- fs/btrfs/disk-io.c | 2 +- fs/btrfs/extent_io.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) commit 05135f597adcb94dc34fa87b82e68eb55e00f0eb Author: David Sterba <dsterba@suse.com> Date: Mon May 9 11:32:39 2016 +0200 btrfs: switch to common message helpers in open_ctree, adjust messages Currently we lack the identification of the filesystem in most if not all mount messages, done via printk/pr_* functions. We can use the btrfs_* helpers in open_ctree, as the fs_info <-> sb link is established at the beginning of the function. The messages have been updated at the same time to be more consistent: * dropped sb->s_id, as it's not available via btrfs_* * added %d for return code where appropriate * wording changed * %Lx replaced by %llx Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/disk-io.c | 102 ++++++++++++++++++++++++++--------------------------- 1 file changed, 50 insertions(+), 52 deletions(-) commit 194e958c5c3bf4fa0805b0653fe2d0428d3791ff Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:08:03 2016 +0200 USB: serial: fix minor-number allocation Due to a missing upper bound, invalid minor numbers could be assigned to ports. Such devices would later fail to register, but let's catch this early as intended and avoid having devices with only a subset of their ports registered (potentially the empty set). Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/usb-serial.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 028c49f5e02a257c94129cd815f7c8485f51d4ef Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:08:02 2016 +0200 USB: serial: quatech2: fix use-after-free in probe error path The interface read URB is submitted in attach, but was only unlinked by the driver at disconnect. In case of a late probe error (e.g. due to failed minor allocation), disconnect is never called and we would end up with active URBs for an unbound interface. This in turn could lead to deallocated memory being dereferenced in the completion callback. Fixes: f7a33e608d9a ("USB: serial: add quatech2 usb to serial driver") Cc: stable <stable@vger.kernel.org> # v3.5: 40d04738491d Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/quatech2.c | 1 + 1 file changed, 1 insertion(+) commit 9e45284984096314994777f27e1446dfbfd2f0d7 Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:08:01 2016 +0200 USB: serial: mxuport: fix use-after-free in probe error path The interface read and event URBs are submitted in attach, but were never explicitly unlinked by the driver. Instead the URBs would have been killed by usb-serial core on disconnect. In case of a late probe error (e.g. due to failed minor allocation), disconnect is never called and we could end up with active URBs for an unbound interface. This in turn could lead to deallocated memory being dereferenced in the completion callbacks. Fixes: ee467a1f2066 ("USB: serial: add Moxa UPORT 12XX/14XX/16XX driver") Cc: stable <stable@vger.kernel.org> # v3.14 Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/mxuport.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 0cd782b0bea1917a522efaedf79429fd7f6621b9 Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:08:00 2016 +0200 USB: serial: keyspan: fix debug and error messages The URB status is signed and should be printed using %d rather than %x. Also print endpoint addresses consistently using %x rather than %d, and merge a broken-up error message string. Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/keyspan.c | 42 +++++++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 17 deletions(-) commit 61924505ae0037527879446b36ac27c60210bc77 Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:07:59 2016 +0200 USB: serial: keyspan: fix URB unlink A driver must not rely on the URB status field to try to determine if an URB is active. Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/keyspan.c | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) commit 35be1a71d70775e7bd7e45fa6d2897342ff4c9d2 Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:07:58 2016 +0200 USB: serial: keyspan: fix use-after-free in probe error path The interface instat and indat URBs were submitted in attach, but never unlinked in release before deallocating the corresponding transfer buffers. In the case of a late probe error (e.g. due to failed minor allocation), disconnect would not have been called before release, causing the buffers to be freed while the URBs are still in use. We'd also end up with active URBs for an unbound interface. Fixes: f9c99bb8b3a1 ("USB: usb-serial: replace shutdown with disconnect, release") Cc: stable <stable@vger.kernel.org> # v2.6.31 Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/keyspan.c | 4 ++++ 1 file changed, 4 insertions(+) commit c8d62957d450cc1a22ce3242908709fe367ddc8e Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:07:57 2016 +0200 USB: serial: io_edgeport: fix memory leaks in probe error path URBs and buffers allocated in attach for Epic devices would never be deallocated in case of a later probe error (e.g. failure to allocate minor numbers) as disconnect is then never called. Fix by moving deallocation to release and making sure that the URBs are first unlinked. Fixes: f9c99bb8b3a1 ("USB: usb-serial: replace shutdown with disconnect, release") Cc: stable <stable@vger.kernel.org> # v2.6.31 Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/io_edgeport.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit c5c0c55598cefc826d6cfb0a417eeaee3631715c Author: Johan Hovold <johan@kernel.org> Date: Sun May 8 20:07:56 2016 +0200 USB: serial: io_edgeport: fix memory leaks in attach error path Private data, URBs and buffers allocated for Epic devices during attach were never released on errors (e.g. missing endpoints). Fixes: 6e8cf7751f9f ("USB: add EPIC support to the io_edgeport driver") Cc: stable <stable@vger.kernel.org> # v2.6.21 Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/serial/io_edgeport.c | 39 ++++++++++++++++++++++++++++----------- 1 file changed, 28 insertions(+), 11 deletions(-) commit bae6692c24236d0203f88a444986d86437a858fa Merge: 46167a8 57fbcce Author: Luca Coelho <luciano.coelho@intel.com> Date: Tue May 10 10:30:56 2016 +0300 Merge tag 'mac80211-next-for-davem-2016-04-13' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next into master To synchronize with Kalle, here's just a big change that affects all drivers - removing the duplicated enum ieee80211_band and replacing it by enum nl80211_band. On top of that, just a small documentation update. commit 201f9b9751bd3f0fc546df87a69c436b162910f0 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:50 2016 +0200 drm/exynos: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-18-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/exynos/exynos_drm_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44156affd1844bdfd90cc791cf5fdb6f9a04e238 Author: Greg Ungerer <gerg@linux-m68k.org> Date: Tue May 10 16:56:37 2016 +1000 m68k: change m68knommu maintainer email address Change my email address in the "UCLINUX (M68KNOMMU and COLDFIRE)" entry from gerg@uclinux.org to gerg@linux-m68k.org. I intend using that for m68k (and uclinux) specific work from now on. Signed-off-by: Greg Ungerer <gerg@linux-m68k.org> MAINTAINERS | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 75229eca569fb275de6d1a0e019df7d63b298762 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu May 5 15:24:32 2016 +0200 drm: Make drm_encoder_helper_funcs optional Make drm_encoder_helper_funcs and it's functions optional to avoid having dummy functions. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462454674-2246-3-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_atomic_helper.c | 11 ++++++++-- drivers/gpu/drm/drm_crtc_helper.c | 41 +++++++++++++++++++++++++++++-------- 2 files changed, 42 insertions(+), 10 deletions(-) commit 9730ffcb8957e1ce9e7d903f7a5db09038a9db8d Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:20 2016 +0530 cxgbit: add files for cxgbit.ko cxgbit.h - This file contains data structure definitions for cxgbit.ko. cxgbit_lro.h - This file contains data structure definitions for LRO support. cxgbit_main.c - This file contains code for registering with iscsi target transport and cxgb4 driver. cxgbit_cm.c - This file contains code for connection management. cxgbit_target.c - This file contains code for processing iSCSI PDU. cxgbit_ddp.c - This file contains code for Direct Data Placement. (added check for NULL sg in cxgbit_set_one_ppod) Reported-by: Dan Carpenter <dan.carpenter@oracle.com> (add Kconfig and Makefile v2: added dependency on INET) Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/Kconfig | 2 + drivers/target/iscsi/Makefile | 1 + drivers/target/iscsi/cxgbit/Kconfig | 7 + drivers/target/iscsi/cxgbit/Makefile | 6 + drivers/target/iscsi/cxgbit/cxgbit.h | 353 +++++ drivers/target/iscsi/cxgbit/cxgbit_cm.c | 2086 +++++++++++++++++++++++++++ drivers/target/iscsi/cxgbit/cxgbit_ddp.c | 325 +++++ drivers/target/iscsi/cxgbit/cxgbit_lro.h | 72 + drivers/target/iscsi/cxgbit/cxgbit_main.c | 701 +++++++++ drivers/target/iscsi/cxgbit/cxgbit_target.c | 1561 ++++++++++++++++++++ 10 files changed, 5114 insertions(+) commit d2faaefb8d4c63fbc680512b04f9eb57667e2682 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:19 2016 +0530 iscsi-target: export symbols export symbols for ISCSI_HW_OFFLOAD transport drivers. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 25 ++++++++++------- drivers/target/iscsi/iscsi_target_datain_values.c | 1 + drivers/target/iscsi/iscsi_target_login.c | 3 ++- drivers/target/iscsi/iscsi_target_nego.c | 1 + drivers/target/iscsi/iscsi_target_parameters.c | 1 + drivers/target/iscsi/iscsi_target_util.c | 2 ++ include/target/iscsi/iscsi_transport.h | 33 +++++++++++++++++++++++ 7 files changed, 56 insertions(+), 10 deletions(-) commit b4869ee9525dd6ded57f1898b65035d5529acfa0 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:18 2016 +0530 iscsi-target: call complete on conn_logout_comp ISCSI_HW_OFFLOAD transport drivers waits on conn_logout_comp as ISCSI_TCP driver so call complete if transport type is ISCSI_HW_OFFLOAD. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 1c50ff424e3d9a392ec2df797c3b6083ed70fca6 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:17 2016 +0530 iscsi-target: clear tx_thread_active clear tx_thread_active for ISCSI_HW_OFFLOAD transport in logout_post_handler functions. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 1c46960e3310adf6ac95078210fdb16987c3b31d Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:16 2016 +0530 iscsi-target: add new offload transport type Add new transport type ISCSI_HW_OFFLOAD, hw offload transport drivers will use this transport type. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target_configfs.c | 76 ++++++++++++++++++++++++++++ include/target/iscsi/iscsi_target_core.h | 1 + 2 files changed, 77 insertions(+) commit 864e504ae2bbdd7efcd6923075047a7a6b5ade02 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:15 2016 +0530 iscsi-target: use conn_transport->transport_type in text rsp Use conn_transport->transport_type instead of ISCSI_TCP to build text response. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c0b7373be811307c5ff1de8c8547aae3597d24aa Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:14 2016 +0530 iscsi-target: move iscsit_thread_check_cpumask() Move iscsit_thread_check_cpumask() to header file so that ISCSI_HW_OFFLOAD and other transport drivers can call this function to ensure both tx and rx thread runs on same cpu. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 26 -------------------------- include/target/iscsi/iscsi_target_core.h | 26 ++++++++++++++++++++++++++ 2 files changed, 26 insertions(+), 26 deletions(-) commit 8567270d8de6192eb2632b45421b1fde9bcda2f2 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:13 2016 +0530 iscsi-target: add void (*iscsit_get_r2t_ttt)() Add void (*iscsit_get_r2t_ttt)() to struct iscsit_transport, iscsi-target uses this callback to get r2t->targ_xfer_tag. cxgbit.ko needs this callback for Direct Data Placement of Data Out pdus, adapter uses ttt in Data Out pdus for placing data directly in to the host buffers. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 5 ++++- include/target/iscsi/iscsi_transport.h | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) commit 42bc3e57877f2357ccbbc3ad6e6c7d9be44579f9 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:12 2016 +0530 iscsi-target: add int (*iscsit_validate_params)() Add int (*iscsit_validate_params)() to struct iscsit_transport, iscsi-target uses this callback for validating conn operational parameters. cxgbit.ko needs this callback to check and update the value of MAXXMITDATASEGMENTLENGTH. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target_login.c | 10 ++++++++++ include/target/iscsi/iscsi_transport.h | 1 + 2 files changed, 11 insertions(+) commit e8205cca0abd126418c18030fb8c9ef272080d70 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:11 2016 +0530 iscsi-target: split iscsi_target_rx_thread() split iscsi_target_rx_thread() into two parts, 1. iscsi_target_rx_thread() is common to all transport drivers, it will call Rx function registered by transport driver. 2. iscsit_get_rx_pdu() is Rx function for ISCSI_TCP transport. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 59 +++++++++++++++++++++---------------- 1 file changed, 33 insertions(+), 26 deletions(-) commit 187e84f7c2e4fa0028241c253c24658ef658e5d3 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:10 2016 +0530 iscsi-target: add void (*iscsit_get_rx_pdu)() Add void (*iscsit_get_rx_pdu)() to struct iscsit_transport, iscsi-target uses this callback to receive and process Rx iSCSI PDUs. cxgbit.ko needs this callback to reuse iscsi-target Rx thread. Signed-off-by: Varun Prakash <varun@chelsio.com> Acked-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/infiniband/ulp/isert/ib_isert.c | 10 ++++++++++ drivers/target/iscsi/iscsi_target.c | 10 ++-------- include/target/iscsi/iscsi_transport.h | 1 + 3 files changed, 13 insertions(+), 8 deletions(-) commit 7ec811a8e9c3b8289a863d0dac717e08a5093403 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:09 2016 +0530 iscsi-target: add void (*iscsit_release_cmd)() Add void (*iscsit_release_cmd)() to struct iscsit_transport, iscsi-target uses this callback to release transport driver resources associated with an iSCSI cmd. cxgbit.ko needs this callback to release DDP resource and sg page in case of PASSTHROUGH_SG_TO_MEM_NOALLOC. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target_util.c | 3 +++ include/target/iscsi/iscsi_transport.h | 1 + 2 files changed, 4 insertions(+) commit 2854bb23cd5bef39fd845b7bdfac7799438bb920 Author: Varun Prakash <varun@chelsio.com> Date: Wed Apr 20 00:00:08 2016 +0530 iscsi-target: add int (*iscsit_xmit_pdu)() Add int (*iscsit_xmit_pdu)() to struct iscsit_transport, iscsi-target uses this callback to transmit an iSCSI PDU. cxgbit.ko needs this callback to avoid duplicating iscsit_immediate_queue() and iscsit_response_queue() code. Signed-off-by: Varun Prakash <varun@chelsio.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/iscsi/iscsi_target.c | 546 ++++++++++++--------------------- include/target/iscsi/iscsi_transport.h | 2 + 2 files changed, 197 insertions(+), 351 deletions(-) commit fdddf932269a75c3dd1c68d82b9a0fbc1821a2a8 Author: Lee Duncan <lduncan@suse.com> Date: Thu Apr 14 18:18:51 2016 -0700 target: use new "dbroot" target attribute This commit updates the target core ALUA and PR modules to use the new "dbroot" attribute instead of assuming the target database is in "/var/target". Signed-off-by: Lee Duncan <lduncan@suse.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_alua.c | 6 +++--- drivers/target/target_core_pr.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit a96e9783e05851d5f06da0ae7635aec55a228e3d Author: Lee Duncan <lduncan@suse.com> Date: Thu Apr 14 18:18:50 2016 -0700 target: make target db location configurable This commit adds the read-write attribute "dbroot", in the top-level CONFIGFS (core) target directory, normally /sys/kernel/config/target. This attribute defaults to "/var/target" but can be changed by writing a new pathname string to it. Changing this attribute is only allowed when no fabric drivers are loaded and the supplied value specifies an existing directory. Target modules that care about the target database root directory will be modified to use this attribute in a future commit. Signed-off-by: Lee Duncan <lduncan@suse.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> drivers/target/target_core_configfs.c | 62 +++++++++++++++++++++++++++++++++++ drivers/target/target_core_internal.h | 6 ++++ 2 files changed, 68 insertions(+) commit 19ea5da07a1f315191212e094ec44fb1caec9580 Merge: 2e726dc a10e2bde Author: Dave Airlie <airlied@redhat.com> Date: Tue May 10 15:07:50 2016 +1000 Merge branch 'drm-etnaviv-next' of git://git.pengutronix.de:/git/lst/linux into drm-next not much new stuff this time. A (micro-)optimization to allow the hangcheck timer to be coalesced with other wakeups in the system and a fix to handle mmaping of prime imported and userptr buffers correctly. I don't think we have seen any actual issues going back to this yet, so I figured it's safer to get this in via drm-next rather than smashing it into fixes. * 'drm-etnaviv-next' of git://git.pengutronix.de:/git/lst/linux: drm/etnaviv: fix mmap operations for userptr and dma-buf objects drm/etnaviv: take etnaviv_gem_obj in etnaviv_gem_mmap_obj drm/etnaviv: use deferrable timer for hangcheck handler timer: add setup_deferrable_timer macro commit c047c3b1af6214b447e353527e394fa3f3e86397 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 21:47:23 2016 +0200 netfilter: conntrack: remove uninitialized shadow variable A recent commit introduced an unconditional use of an uninitialized variable, as reported in this gcc warning: net/netfilter/nf_conntrack_core.c: In function '__nf_conntrack_confirm': net/netfilter/nf_conntrack_core.c:632:33: error: 'ctinfo' may be used uninitialized in this function [-Werror=maybe-uninitialized] bytes = atomic64_read(&counter[CTINFO2DIR(ctinfo)].bytes); ^ net/netfilter/nf_conntrack_core.c:628:26: note: 'ctinfo' was declared here enum ip_conntrack_info ctinfo; The problem is that a local variable shadows the function parameter. This removes the local variable, which looks like what Pablo originally intended. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 71d8c47fc653 ("netfilter: conntrack: introduce clash resolution on insertion race") Acked-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/netfilter/nf_conntrack_core.c | 1 - 1 file changed, 1 deletion(-) commit 2e726dc4b4e2dd3ae3fe675f9d3af88a2d593ee1 Merge: bafb86f ac4b128 Author: Dave Airlie <airlied@redhat.com> Date: Tue May 10 15:01:47 2016 +1000 Merge tag 'mediatek-drm-2016-05-09' of git://git.pengutronix.de/git/pza/linux into drm-next MT8173 DRM support - device tree binding documentation for all MT8173 display subsystem components - basic mediatek-drm driver for MT8173 with two optional, currently fixed output paths: - DSI encoder support for DSI and (via bridge) eDP panels - DPI encoder support for output to HDMI bridge - necessary clock tree changes for the DPI->HDMI path - export mtk-smi functions used by mediatek-drm * tag 'mediatek-drm-2016-05-09' of git://git.pengutronix.de/git/pza/linux: clk: mediatek: remove hdmitx_dig_cts from TOP clocks clk: mediatek: Add hdmi_ref HDMI PHY PLL reference clock output clk: mediatek: make dpi0_sel propagate rate changes drm/mediatek: Add DPI sub driver drm/mediatek: Add DSI sub driver drm/mediatek: Add DRM Driver for Mediatek SoC MT8173. dt-bindings: drm/mediatek: Add Mediatek display subsystem dts binding memory: mtk-smi: export mtk_smi_larb_get/put commit 0e3c82df576aa8d99e5a867f2c8fac43686d10b7 Merge: bfca2eb b45bd1d Author: David S. Miller <davem@davemloft.net> Date: Tue May 10 00:39:28 2016 -0400 Merge branch 'ip6-tunnel-tx-fixes' Tom Herbert says: ==================== ip6: Transmit tunneling fixes Several fixes suggested by Alexander. Tested: Running netperf TCP_STREAM with gretap and keyid configured. Visually verified that MTU is correctly being set. Did not test HW offload (Alexander plese try) ==================== Tested-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> commit b45bd1d787969d3ae5662a56ed431cd13e3b8b92 Author: Tom Herbert <tom@herbertland.com> Date: Mon May 9 17:12:12 2016 -0700 ip6_gre: Use correct flags for reading TUNNEL_SEQ Fix two spots where o_flags in a tunnel are being compared to GRE_SEQ instead of TUNNEL_SEQ. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4b4a0c91438c2471d7ab9504c0096ffc47d2389b Author: Tom Herbert <tom@herbertland.com> Date: Mon May 9 17:12:11 2016 -0700 ip6: Don't set transport header in IPv6 tunneling We only need to reset network header here. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_tunnel.c | 2 -- 1 file changed, 2 deletions(-) commit d27bff9ca294ac76548ee97db5d92f39e4752a01 Author: Tom Herbert <tom@herbertland.com> Date: Mon May 9 17:12:10 2016 -0700 ip6_gre: Set inner protocol correctly in __gre6_xmit Need to use adjusted protocol value for setting inner protocol. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f41fe3c2acc9e40304ac1dae0f243ef27fe85dee Author: Tom Herbert <tom@herbertland.com> Date: Mon May 9 17:12:09 2016 -0700 gre6: Fix flag translations GRE for IPv6 does not properly translate for GRE flags to tunnel flags and vice versa. This patch fixes that. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit db2ec95d1ba419b766aae7b1d7c0271f3c9cd9f4 Author: Tom Herbert <tom@herbertland.com> Date: Mon May 9 17:12:08 2016 -0700 ip6_gre: Fix MTU setting In ip6gre_tnl_link_config set t->tun_len and t->hlen correctly for the configuration. For hard_header_len and mtu calculation include IPv6 header and encapsulation overhead. In ip6gre_tunnel_init_common set t->tun_len and t->hlen correctly for the configuration. Revert to setting hard_header_len instead of needed_headroom. Tested: ./ip link add name tun8 type ip6gretap remote \ 2401:db00:20:911a:face:0:27:0 local \ 2401:db00:20:911a:face:0:25:0 ttl 225 Gives MTU of 1434. That is equal to 1500 - 40 - 14 - 4 - 8. ./ip link add name tun8 type ip6gretap remote \ 2401:db00:20:911a:face:0:27:0 local \ 2401:db00:20:911a:face:0:25:0 ttl 225 okey 123 Gives MTU of 1430. That is equal to 1500 - 40 - 14 - 4 - 8 - 4. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) commit bfca2eba2adaa9501656f503559a971de6927fa8 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 8 13:47:23 2016 +0200 stmmac: dwmac-socfpga: make socfpga_dwmac_pm_ops static Fix the following sparse warning: drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c:274:1: warning: symbol 'socfpga_dwmac_pm_ops' was not declared. Should it be static? Signed-off-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 20e61335d8db0caf0c50236c1c9c2ea546f61f1a Merge: 27c0f73 1ff23be Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 22:33:53 2016 -0400 Merge branch 'l3mdev-send-enslaved' David Ahern says: ==================== net: l3mdev: Allow send on enslaved interface First patch preps for the second. The second is required for several use cases such as ping on an interface and BFD that need to send packets on a specific interface, including ones enslaved to a VRF device. v2 - fixed brackets on both patches per comment from DaveM ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 1ff23beebdd315fe4d16070c08c065e89d7debb3 Author: David Ahern <dsa@cumulusnetworks.com> Date: Sat May 7 16:49:00 2016 -0700 net: l3mdev: Allow send on enslaved interface Allow udp and raw sockets to send by oif that is an enslaved interface versus the l3mdev/VRF device. For example, this allows BFD to use ifindex from IP_PKTINFO on a receive to send a response without the need to convert to the VRF index. It also allows ping and ping6 to work when specifying an enslaved interface (e.g., ping -I swp1 <ip>) which is a natural use case. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vrf.c | 2 ++ net/ipv4/route.c | 4 ++++ net/l3mdev/l3mdev.c | 17 +++++++++++++---- 3 files changed, 19 insertions(+), 4 deletions(-) commit 4a65896f94fa82370041823837cd75aac1186b54 Author: David Ahern <dsa@cumulusnetworks.com> Date: Sat May 7 16:48:59 2016 -0700 net: l3mdev: Move get_saddr and rt6_dst Move l3mdev_rt6_dst_by_oif and l3mdev_get_saddr to l3mdev.c. Collapse l3mdev_get_rt6_dst into l3mdev_rt6_dst_by_oif since it is the only user and keep the l3mdev_get_rt6_dst name for consistency with other hooks. A follow-on patch adds more code to these functions making them long for inlined functions. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/l3mdev.h | 56 +++------------------------------------------------- net/ipv6/route.c | 2 +- net/l3mdev/l3mdev.c | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 58 insertions(+), 54 deletions(-) commit 4e51af9ee7afa0ecf4829e7a44f7055db7968e02 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 14:14:41 2016 +0300 bfa: fix bfa_fcb_itnim_alloc() error handling The caller assumes that "itnim" is NULL on error and non-NULL on success but really "itnim" is uninitialized on error. This function should just use normal error handling where it returns zero on success and negative on failure. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Anil Gurumurthy <anil.gurumurthy@qlogic.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bfa/bfa_fcs.h | 4 ++-- drivers/scsi/bfa/bfa_fcs_fcpim.c | 5 +++-- drivers/scsi/bfa/bfad_im.c | 5 +++-- 3 files changed, 8 insertions(+), 6 deletions(-) commit 27c0f739a009971aaf43ee71d9b150a56ee57012 Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Tue May 10 10:28:49 2016 +0900 fjes: Fix unnecessary spinlock_irqsave commit-bd5a256 introduces a deadlock bug in fjes_change_mtu(). This spin_lock_irqsave() is obviously unnecessary. This patch eliminates unnecessary spin_lock_irqsave() in fjes_change_mtu() Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_main.c | 1 - 1 file changed, 1 deletion(-) commit 1de1d449c6cf701e09d2941d042b28328118ad1a Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 22:05:13 2016 -0400 mlx5: Fix merge errors. I accidently let Arnd's VXLAN dependency changes slip into net-next, they are only appropriate for net. Also the flow steering structural changes to mlx5e_priv got scrambled during the merge resolution as well. Fix that all up. Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 7 ------- drivers/net/ethernet/mellanox/mlx5/core/Makefile | 3 +-- drivers/net/ethernet/mellanox/mlx5/core/en.h | 5 ----- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 3 --- drivers/net/ethernet/mellanox/mlx5/core/vxlan.h | 8 +------- 5 files changed, 2 insertions(+), 24 deletions(-) commit d96caf8c33cad42b5eabcf1b686dd91581e306f4 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Mon May 9 17:00:22 2016 -0700 Input: rotary-encoder - fix bare use of 'unsigned' fix checkpatch.pl warning about 'Prefer 'unsigned int' to bare use of 'unsigned'' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/rotary_encoder.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 45a0dac0451136fa7ae34a6fea53ef6a136287ce Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 31 15:41:18 2016 -0700 libnvdimm, dax: record the specified alignment of a dax-device instance We want to use the alignment as the allocation and mapping unit. Previously this information was only useful for establishing the data offset, but now it is important to remember the granularity for the later use. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pfn.h | 4 +++- drivers/nvdimm/pfn_devs.c | 8 ++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) commit 52ac23b25eb26511f8dea2382534eeada2fa8244 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 31 09:37:11 2016 -0700 libnvdimm, dax: reserve space to store labels for device-dax We may want to subdivide a device-dax range into multiple devices so that each can have separate permissions or naming. Reserve 128K of label space by default so we have the capability of making allocation decisions persistent. This reservation is not something we can add later since it would result in the default size of a device-dax range changing between kernel versions. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pfn_devs.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit cd03412a51ac4cb3001a8cdfae4560c9602f3387 Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Mar 11 10:15:36 2016 -0800 libnvdimm, dax: introduce device-dax infrastructure Device DAX is the device-centric analogue of Filesystem DAX (CONFIG_FS_DAX). It allows persistent memory ranges to be allocated and mapped without need of an intervening file system. This initial infrastructure arranges for a libnvdimm pfn-device to be represented as a different device-type so that it can be attached to a driver other than the pmem driver. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/Kconfig | 13 ++++++ drivers/nvdimm/Makefile | 1 + drivers/nvdimm/bus.c | 4 ++ drivers/nvdimm/claim.c | 2 + drivers/nvdimm/dax_devs.c | 99 +++++++++++++++++++++++++++++++++++++++ drivers/nvdimm/namespace_devs.c | 19 +++++++- drivers/nvdimm/nd-core.h | 1 + drivers/nvdimm/nd.h | 25 ++++++++++ drivers/nvdimm/pfn_devs.c | 100 +++++++++++++++++++++++++++------------- drivers/nvdimm/region.c | 2 + drivers/nvdimm/region_devs.c | 29 ++++++++++++ include/uapi/linux/ndctl.h | 2 + tools/testing/nvdimm/Kbuild | 1 + 13 files changed, 264 insertions(+), 34 deletions(-) commit 91e6f1ce8657795cec83a81090c20cbaa8337c68 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Mon May 9 18:10:00 2016 -0400 ftracetest: Add instance created, delete, read and enable event test Add a new ftrace test that creates three threads. One that creates and removes an ftrace instance, one that reads the instance, and one that enables and disables events in the instance. This is a stress test for accessing and removing instances at the same time. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> .../ftrace/test.d/instances/instance-event.tc | 143 +++++++++++++++++++++ 1 file changed, 143 insertions(+) commit b31d5103c33280738188c51e226224dff4401c7b Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Thu Apr 21 16:43:53 2016 +0200 NFC: pn533: handle interrupted commands in pn533_recv_frame When pn533_recv_frame is called from within abort_command context the current dev->cmd is not guaranteed to be set. Additionally on receiving an error status we can omit frame checking and simply schedule the workqueue. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/pn533.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit c952f915ce8567120ffdf12998ad0c945fbc93ac Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Thu Apr 21 16:43:52 2016 +0200 NFC: pn533: reset poll modulation list before calling targets_found We need to reset the poll modulation list before calling nfc_targets_found because otherwise userspace could run before the modulation list is cleared and then get a "Cannot activate target while polling" error upon calling activate_target. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/pn533.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 30f98489f54e027001cc9b27c59840975871de65 Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Thu Apr 21 16:43:51 2016 +0200 NFC: pn533: i2c: do not call pn533_recv_frame with aborted commands When a command gets aborted the pn533 core does not need any RX frames that may be received until a new frame is sent. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/i2c.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit b16931b13c67f06ca74cc8d02797de480dea348b Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Thu Apr 21 16:43:50 2016 +0200 NFC: pn533: fix order of initialization Correctly call nfc_set_parent_dev before nfc_register_device. Otherwise the driver will OOPS when being removed. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/i2c.c | 3 ++- drivers/nfc/pn533/pn533.c | 4 +++- drivers/nfc/pn533/pn533.h | 3 ++- drivers/nfc/pn533/usb.c | 3 +-- 4 files changed, 8 insertions(+), 5 deletions(-) commit 79f09fa79cefdd9df40c9c590cc8dda544ebff26 Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Thu Apr 21 16:43:49 2016 +0200 NFC: pn533: i2c: free irq on driver remove The requested irq needs to be freed when removing the driver, otherwise a following driver load fails to request the irq. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/i2c.c | 2 ++ 1 file changed, 2 insertions(+) commit 9c7b37cd63d0d910c531233209286f169993cbd9 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Sat May 7 02:16:59 2016 -0700 perf symbols: Fix handling of zero-length symbols. This change introduces a fix to symbols__find, so that it is able to find symbols of length zero (where start == end). The current code has the following problem: - The current implementation of symbols__find is unable to find any symbols of length zero. - The db-export framework explicitly creates zero length symbols at locations where no symbol currently exists. The combination of the two above behaviors results in behavior similar to the example below. 1. addr_location is created for a sample, but symbol is unable to be resolved. 2. db export creates an "unknown" symbol of length zero at that address and inserts it into the dso. 3. A new sample comes in at the same address, but symbol__find is unable to find the zero length symbol, so it is still unresolved. 4. db export sees the symbol is unresolved, and allocated a duplicate symbol, even though it already did this in step 2. This behavior continues every time an address without symbol information is seen, which causes a very large number of these symbols to be allocated. The effect of this fix can be observed by looking at the contents of an exported database before/after the fix (generated with scripts/python/export-to-postgresql.py) Ex. BEFORE THE CHANGE: example_db=# select count(*) from symbols; count -------- 900213 (1 row) example_db=# select count(*) from symbols where symbols.name='unknown'; count -------- 897355 (1 row) example_db=# select count(*) from symbols where symbols.name!='unknown'; count ------- 2858 (1 row) AFTER THE CHANGE: example_db=# select count(*) from symbols; count ------- 25217 (1 row) example_db=# select count(*) from symbols where name='unknown'; count ------- 22359 (1 row) example_db=# select count(*) from symbols where name!='unknown'; count ------- 2858 (1 row) Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462612620-25008-1-git-send-email-cphlipot0@gmail.com [ Moved the test to later in the rb_tree tests, as this not the likely case ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/symbol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aff093d4bbca91f543e24cde2135f393b8130f4b Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 06:15:38 2016 -0300 [media] exynos-gsc: avoid build warning without CONFIG_OF When building the exynos-gsc driver with CONFIG_OF disabled, we get a warning about an out-of-bounds access: drivers/media/platform/exynos-gsc/gsc-core.c: In function 'gsc_probe': drivers/media/platform/exynos-gsc/gsc-core.c:1078:34: error: array subscript is above array bounds [-Werror=array-bounds] This is harmless because the driver will never be used without CONFIG_OF, but it's better to avoid the warning anyway. Checking the return value of of_alias_get_id() for an error condition is probably a good idea anyway, and it makes sure the compiler can verify that we don't get into that situation. Fixes: 26a7ed9c1819 ("[media] exynos-gsc: remove an always false condition") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos-gsc/gsc-core.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 0185f850176201260e0f02c5bccca1defb8e0884 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 10:17:21 2016 -0300 [media] samples: v4l: from Documentation to samples directory With the new autoksyms support, we can run into a situation where the v4l pci skeleton module is the only one using some exported symbols that get dropped because they are never referenced by the kernel otherwise, causing a build problem: ERROR: "vb2_dma_contig_memops" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "vb2_dma_contig_init_ctx_attrs" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "v4l2_match_dv_timings" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "v4l2_find_dv_timings_cap" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "v4l2_valid_dv_timings" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "v4l2_enum_dv_timings_cap" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! ERROR: "vb2_dma_contig_cleanup_ctx" [Documentation/video4linux/v4l2-pci-skeleton.ko] undefined! Specifically, we do look in the samples directory for users of symbols, but not the Documentation directory. This solves the build problem by moving the connector sample into the same directory as the other samples. Fixes: 23121ca2b56b ("kbuild: create/adjust generated/autoksyms.h") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Documentation/Makefile | 3 +- Documentation/video4linux/Makefile | 1 - Documentation/video4linux/v4l2-framework.txt | 2 +- Documentation/video4linux/v4l2-pci-skeleton.c | 922 -------------------------- samples/Makefile | 2 +- samples/v4l/Makefile | 1 + samples/v4l/v4l2-pci-skeleton.c | 922 ++++++++++++++++++++++++++ 7 files changed, 926 insertions(+), 927 deletions(-) commit 0a241ef4a27a00807fefdf913da104a4534c606a Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon May 9 18:08:33 2016 -0300 perf evsel: Print state of perf_event_attr.write_backward Now we can see if it is set when using verbose mode in various tools, such as 'perf test': # perf test -vv back 45: Test backward reading from ring buffer : --- start --- <SNIP> ------------------------------------------------------------ perf_event_attr: type 2 size 112 config 0x98 { sample_period, sample_freq } 1 sample_type IP|TID|TIME|CPU|PERIOD|RAW disabled 1 mmap 1 comm 1 task 1 sample_id_all 1 exclude_guest 1 mmap2 1 comm_exec 1 write_backward 1 ------------------------------------------------------------ sys_perf_event_open: pid 20911 cpu -1 group_fd -1 flags 0x8 <SNIP> ---- end ---- Test backward reading from ring buffer: Ok # Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-kxv05kv9qwl5of7rzfeiiwbv@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 1 + 1 file changed, 1 insertion(+) commit ee74701ed8add8ad13e642e8618b51fd75add32d Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 9 01:47:51 2016 +0000 perf tests: Add test to check backward ring buffer This test checks reading from backward ring buffer. Test result: # ~/perf test 'ring buffer' 45: Test backward reading from ring buffer : Ok The test case is a while loop which calls prctl(PR_SET_NAME) multiple times. Each prctl should issue 2 events: one PERF_RECORD_SAMPLE, one PERF_RECORD_COMM. The first round creates a relative large ring buffer (256 pages). It can afford all events. Read from it and check the count of each type of events. The second round creates a small ring buffer (1 page) and makes it overwritable. Check the correctness of the buffer. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1462758471-89706-3-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/Build | 1 + tools/perf/tests/backward-ring-buffer.c | 151 ++++++++++++++++++++++++++++++++ tools/perf/tests/builtin-test.c | 4 + tools/perf/tests/tests.h | 1 + 4 files changed, 157 insertions(+) commit 437014bdac9680e3b32c006635ac270b808ce476 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Mon May 9 14:40:27 2016 -0400 ACPI / GED: make evged.c explicitly non-modular The Makefile/Kconfig currently controlling compilation of this code is: Makefile:acpi-$(CONFIG_ACPI_REDUCED_HARDWARE_ONLY) += evged.o drivers/acpi/Kconfig:config ACPI_REDUCED_HARDWARE_ONLY drivers/acpi/Kconfig: bool "Hardware-reduced ACPI support only" if EXPERT ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity so that when reading the code there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. The file wasn't explicitly including the module.h file but it did already have init.h so, unlike similar changes, this one has no header changes at all. We also delete the MODULE_LICENSE tag since all that information is already contained at the top of the file in the comments. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/evged.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit f96fd0c86f081c27a0ba5efadfc13f612b4071d3 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat May 7 02:24:48 2016 +0200 intel_pstate: Clean up intel_pstate_get() intel_pstate_get() contains a local variable that's initialized but never used and it can be written in fewer lines of code, so clean it up. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> drivers/cpufreq/intel_pstate.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit c2f90a465df75254fb41bf6e7975464929c21e26 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:16:22 2016 +0200 HSI: omap-ssi: move omap_ssi_port_update_fclk After the clk change support, the ssi omap ssi core driver now calls into the port driver to change fclk. This function was previously inside of an #ifdef, because it was only used when CONFIG_PM is enabled. Now it also gets used without power management support: drivers/hsi/built-in.o: In function `ssi_clk_event': omap_ssi_port.c:(.text+0x1bf8): undefined reference to `omap_ssi_port_update_fclk' This moves the function outside of the CONFIG_PM guard. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 4bcf7414528a ("HSI: omap-ssi: add clk change support") Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi_port.c | 35 ++++++++++++++++----------------- 1 file changed, 17 insertions(+), 18 deletions(-) commit ac8e3ff3a07cb8bf7a5ce4627c39a50e71dcd394 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:16:21 2016 +0200 HSI: omap-ssi: include pinctrl header files The driver now uses some pinctrl functions, but fails to build if PINCTRL is disabled because the respective header files are only included indirectly: drivers/hsi/controllers/omap_ssi_core.c: In function 'ssi_clk_event': drivers/hsi/controllers/omap_ssi_core.c:317:4: error: implicit declaration of function 'pinctrl_pm_select_idle_state' [-Werror=implicit-function-declaration] drivers/hsi/controllers/omap_ssi_core.c:339:4: error: implicit declaration of function 'pinctrl_pm_select_default_state' [-Werror=implicit-function-declaration] drivers/hsi/controllers/omap_ssi_port.c: In function 'ssi_flush': drivers/hsi/controllers/omap_ssi_port.c:520:2: error: implicit declaration of function 'pinctrl_pm_select_idle_state' [-Werror=implicit-function-declaration] This includes the headers from the files that call the functions, which works even if pinctrl is turned off. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 4bcf7414528a ("HSI: omap-ssi: add clk change support") Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi_core.c | 1 + drivers/hsi/controllers/omap_ssi_port.c | 1 + 2 files changed, 2 insertions(+) commit 53c703501e3c10283315f1c846d4ebea7d371c4d Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:16:20 2016 +0200 HSI: omap-ssi: add COMMON_CLK dependency Enabling the omap ssi driver without COMMON_CLK results in a build failure: drivers/hsi/controllers/omap_ssi_core.c: In function 'ssi_clk_event': drivers/hsi/controllers/omap_ssi_core.c:304:7: error: 'PRE_RATE_CHANGE' undeclared (first use in this function) This adds a Kconfig dependency to avoid the invalid configuration. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 4bcf7414528a ("HSI: omap-ssi: add clk change support") Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 06485053244480f5f403d8f89b8617bd7d549113 Author: Catalin Marinas <catalin.marinas@arm.com> Date: Wed Apr 13 17:57:37 2016 +0100 kvm: arm64: Enable hardware updates of the Access Flag for Stage 2 page tables The ARMv8.1 architecture extensions introduce support for hardware updates of the access and dirty information in page table entries. With VTCR_EL2.HA enabled (bit 21), when the CPU accesses an IPA with the PTE_AF bit cleared in the stage 2 page table, instead of raising an Access Flag fault to EL2 the CPU sets the actual page table entry bit (10). To ensure that kernel modifications to the page table do not inadvertently revert a bit set by hardware updates, certain Stage 2 software pte/pmd operations must be performed atomically. The main user of the AF bit is the kvm_age_hva() mechanism. The kvm_age_hva_handler() function performs a "test and clear young" action on the pte/pmd. This needs to be atomic in respect of automatic hardware updates of the AF bit. Since the AF bit is in the same position for both Stage 1 and Stage 2, the patch reuses the existing ptep_test_and_clear_young() functionality if __HAVE_ARCH_PTEP_TEST_AND_CLEAR_YOUNG is defined. Otherwise, the existing pte_young/pte_mkold mechanism is preserved. The kvm_set_s2pte_readonly() (and the corresponding pmd equivalent) have to perform atomic modifications in order to avoid a race with updates of the AF bit. The arm64 implementation has been re-written using exclusives. Currently, kvm_set_s2pte_writable() (and pmd equivalent) take a pointer argument and modify the pte/pmd in place. However, these functions are only used on local variables rather than actual page table entries, so it makes more sense to follow the pte_mkwrite() approach for stage 1 attributes. The change to kvm_s2pte_mkwrite() makes it clear that these functions do not modify the actual page table entries. The (pte|pmd)_mkyoung() uses on Stage 2 entries (setting the AF bit explicitly) do not need to be modified since hardware updates of the dirty status are not supported by KVM, so there is no possibility of losing such information. Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/include/asm/kvm_mmu.h | 10 +++++---- arch/arm/kvm/mmu.c | 46 +++++++++++++++++++++++++--------------- arch/arm64/include/asm/kvm_arm.h | 2 ++ arch/arm64/include/asm/kvm_mmu.h | 27 +++++++++++++++++------ arch/arm64/include/asm/pgtable.h | 13 ++++++++---- arch/arm64/kvm/hyp/s2-setup.c | 8 +++++++ 6 files changed, 74 insertions(+), 32 deletions(-) commit e24c7520ea9c3e5bb51592c2134aafbf75a3f88a Author: Wang Nan <wangnan0@huawei.com> Date: Mon May 9 01:47:50 2016 +0000 perf tools: Support reading from backward ring buffer perf_evlist__mmap_read_backward() is introduced for reading backward ring buffer. Since direction for reading such ring buffer is different from the direction kernel writing to it, and since user need to fetch most recent record from it, a perf_evlist__mmap_read_catchup() is introduced to move the reading pointer to the end of the buffer. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1462758471-89706-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/evlist.h | 4 ++++ 2 files changed, 54 insertions(+) commit e800072c18f0d7b89a80fa46dceb3d080c80e09c Merge: e8ed77d b507146 Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 15:59:24 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net In netdevice.h we removed the structure in net-next that is being changes in 'net'. In macsec.c and rtnetlink.c we have overlaps between fixes in 'net' and the u64 attribute changes in 'net-next'. The mlx5 conflicts have to do with vxlan support dependencies. Signed-off-by: David S. Miller <davem@davemloft.net> commit e8ed77dfa90dd79c5343415a4bbbfdab9787b35a Merge: e26522c 0c5366b Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 15:02:58 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next Pablo Neira Ayuso says: ==================== Netfilter updates for net-next The following large patchset contains Netfilter updates for your net-next tree. My initial intention was to send you this in two goes but when I looked back twice I already had this burden on top of me. Several updates for IPVS from Marco Angaroni: 1) Allow SIP connections originating from real-servers to be load balanced by the SIP persistence engine as is already implemented in the other direction. 2) Release connections immediately for One-packet-scheduling (OPS) in IPVS, instead of making it via timer and rcu callback. 3) Skip deleting conntracks for each one packet in OPS, and don't call nf_conntrack_alter_reply() since no reply is expected. 4) Enable drop on exhaustion for OPS + SIP persistence. Miscelaneous conntrack updates from Florian Westphal, including fix for hash resize: 5) Move conntrack generation counter out of conntrack pernet structure since this is only used by the init_ns to allow hash resizing. 6) Use get_random_once() from packet path to collect hash random seed instead of our compound. 7) Don't disable BH from ____nf_conntrack_find() for statistics, use NF_CT_STAT_INC_ATOMIC() instead. 8) Fix lookup race during conntrack hash resizing. 9) Introduce clash resolution on conntrack insertion for connectionless protocol. Then, Florian's netns rework to get rid of per-netns conntrack table, thus we use one single table for them all. There was consensus on this change during the NFWS 2015 and, on top of that, it has recently been pointed as a source of multiple problems from unpriviledged netns: 11) Use a single conntrack hashtable for all namespaces. Include netns in object comparisons and make it part of the hash calculation. Adapt early_drop() to consider netns. 12) Use single expectation and NAT hashtable for all namespaces. 13) Use a single slab cache for all namespaces for conntrack objects. 14) Skip full table scanning from nf_ct_iterate_cleanup() if the pernet conntrack counter tells us the table is empty (ie. equals zero). Fixes for nf_tables interval set element handling, support to set conntrack connlabels and allow set names up to 32 bytes. 15) Parse element flags from element deletion path and pass it up to the backend set implementation. 16) Allow adjacent intervals in the rbtree set type for dynamic interval updates. 17) Add support to set connlabel from nf_tables, from Florian Westphal. 18) Allow set names up to 32 bytes in nf_tables. Several x_tables fixes and updates: 19) Fix incorrect use of IS_ERR_VALUE() in x_tables, original patch from Andrzej Hajda. And finally, miscelaneous netfilter updates such as: 20) Disable automatic helper assignment by default. Note this proc knob was introduced by a9006892643a ("netfilter: nf_ct_helper: allow to disable automatic helper assignment") 4 years ago to start moving towards explicit conntrack helper configuration via iptables CT target. 21) Get rid of obsolete and inconsistent debugging instrumentation in x_tables. 22) Remove unnecessary check for null after ip6_route_output(). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3f37a36b6282621d7c5a99b6911275f989766996 Author: Borislav Petkov <bp@suse.de> Date: Fri May 6 19:44:27 2016 +0200 EDAC, amd64_edac: Drop pci_register_driver() use - remove homegrown instances counting. - take F3 PCI device from amd_nb caching instead of F2 which was used with the PCI core. With those changes, the driver doesn't need to register a PCI driver and relies on the northbridges caching which we do anyway on AMD. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Yazen Ghannam <yazen.ghannam@amd.com> drivers/edac/amd64_edac.c | 125 ++++++++++++++++------------------------------ drivers/edac/amd64_edac.h | 2 +- 2 files changed, 44 insertions(+), 83 deletions(-) commit e26522cd0b63fdbf3b4e9a39d73a985cc9b4fe27 Merge: 908578e f81ec90 Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 14:26:14 2016 -0400 Merge branch 'dsa-mv88e6xxx-monolithic' Vivien Didelot says: ==================== net: dsa: mv88e6xxx: turn into monolithic driver This patchset merges all mv88e6* drivers supported by the shared mv88e6xxx code into a single mv88e6xxx DSA switch driver. Some flags are added to describe the capabilities of a switch model, such as the presence of a PPU, EEPROM, some old or new registers, etc. First these flags are used to conditionally support the same set of functions in every driver, then specific driver files are removed in favor of the common mv88e6xxx driver. Only the merge of driver specific setup code assumes a few differences. If these differences such as frames priorities are really needed for some models, they can easily be brought back in a future patch. Some inconsistencies might show up, such as the need for MV88E6XXX_FLAG_PPU and MV88E6XXX_FLAG_PPU_ACTIVE flags. But this patchset does not aim to fix them yet. A future patch can do that if they end up being unwanted. The patchset has been tested on interconnected 88E6352 and 88E6185. Changes v1 -> v2: - add missing MV88E6XXX_FLAG_EEPROM flag checks - remove a few remaining _ prefixes - remove MV88E6XXX_FLAG_CORE_TAG_TYPE which is a specific default Changes RFC -> v1: - introduce flags in a separate patch - do not refactor anything yet - do not add new functions prefixed with _ - drop packet discarding and mentioned tested platforms - factorize family flags - update text for NET_DSA_MV88E6XXX Kconfig entry ==================== Reviewed-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> commit f81ec90fe9cbf512f3c632130a37c6d353fa94ea Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:58 2016 -0400 net: dsa: mv88e6xxx: factorize the switch driver Now that all drivers support the same set of functions and the same setup code, drop every model-specific DSA switch driver and replace them with a common mv88e6xxx driver. This merges the info tables into one, removes the function exports, the model-specific files, and update the defconfigs. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm/configs/multi_v5_defconfig | 5 +- arch/arm/configs/mvebu_v7_defconfig | 2 +- arch/arm/configs/orion5x_defconfig | 3 +- arch/tile/configs/tilegx_defconfig | 3 +- arch/tile/configs/tilepro_defconfig | 3 +- drivers/net/dsa/Kconfig | 40 +--- drivers/net/dsa/Makefile | 15 +- drivers/net/dsa/mv88e6123.c | 93 ---------- drivers/net/dsa/mv88e6131.c | 101 ---------- drivers/net/dsa/mv88e6171.c | 101 ---------- drivers/net/dsa/mv88e6352.c | 121 ------------ drivers/net/dsa/mv88e6xxx.c | 354 +++++++++++++++++++++++++++--------- drivers/net/dsa/mv88e6xxx.h | 91 +++------ 13 files changed, 302 insertions(+), 630 deletions(-) commit b9729e53ade9be2637b46ac98fd85c7eac1b77c8 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:57 2016 -0400 net: dsa: mv88e6131: use EDSA tag protocol 6131 is the only driver to set the tag protocol to DSA_TAG_PROTO_DSA. Since it works fine with DSA_TAG_PROTO_EDSA, change its value, like all other mv88e6xxx drivers. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/Kconfig | 2 +- drivers/net/dsa/mv88e6131.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit a1a6a4d1f76aab009e6e0b1003b9c7bca3991e9c Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:56 2016 -0400 net: dsa: mv88e6xxx: factorize switch setup Provide a shared mv88e6xxx_setup function to the drivers. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 16 +---------- drivers/net/dsa/mv88e6131.c | 16 +---------- drivers/net/dsa/mv88e6171.c | 16 +---------- drivers/net/dsa/mv88e6352.c | 16 +---------- drivers/net/dsa/mv88e6xxx.c | 69 ++++++++++++++++++++++----------------------- drivers/net/dsa/mv88e6xxx.h | 3 +- 6 files changed, 38 insertions(+), 98 deletions(-) commit 8698fd9595c3b90a76c878159328ac6ebd923963 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:55 2016 -0400 net: dsa: mv88e6131: drop frames priorities setup 6131 is the only driver which setups the priority of IGMP/MLD snoop frames and ARP frames to the highest setting. Drop such change until we figure out a common configuration for all switch models. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6131.c | 18 ------------------ 1 file changed, 18 deletions(-) commit 50484ff4d11c1eca0059f3b3d407ecec0f1b83b0 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:54 2016 -0400 net: dsa: mv88e6xxx: factorize GLOBAL_CONTROL_2 setup All switch models setup the GLOBAL_CONTROL_2 register with slightly differences. Since the cascade mode is valid even in a single chip setup, factorize such configuration. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 15 --------------- drivers/net/dsa/mv88e6131.c | 16 ---------------- drivers/net/dsa/mv88e6171.c | 15 --------------- drivers/net/dsa/mv88e6352.c | 14 -------------- drivers/net/dsa/mv88e6xxx.c | 7 +++++++ 5 files changed, 7 insertions(+), 60 deletions(-) commit b0745e87943b40734e6c341dcf47a6ec80ee4346 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:53 2016 -0400 net: dsa: mv88e6xxx: factorize GLOBAL_MONITOR_CONTROL setup All switch drivers configure the GLOBAL_MONITOR_CONTROL register with slightly changes. Assume the setup of the upstream port, and configure it as the port to which ingress and egress and ARP monitor frames are to be sent. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 14 -------------- drivers/net/dsa/mv88e6131.c | 13 ------------- drivers/net/dsa/mv88e6171.c | 15 --------------- drivers/net/dsa/mv88e6352.c | 14 -------------- drivers/net/dsa/mv88e6xxx.c | 12 ++++++++++++ 5 files changed, 12 insertions(+), 56 deletions(-) commit 709643aa626ec8f0bd678be79187beefffae32c7 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:52 2016 -0400 net: dsa: mv88e6131: drop VLAN Ethertype setup The 6131 switch models have a Core Tag Type register. Their setup code is setting it to 0x8100, which is the reset default. Drop this specific part which is correctly configured on reset anyway. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6131.c | 5 ----- 1 file changed, 5 deletions(-) commit 119477bd987cbaf29af10b9cb1b731547906787e Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:51 2016 -0400 net: dsa: mv88e6xxx: factorize GLOBAL_CONTROL setup All switch models configure the GLOBAL_CONTROL register with slightly differences. Discarding packets with excessive collisions (GLOBAL_CONTROL_DISCARD_EXCESS) is specific to 6352 and similar switches, and setting a maximum frame size (GLOBAL_CONTROL_MAX_FRAME_1632) is specific to 6185 and similar switches. As we are centralizing the chips setup, skip these settings and don't discard any frames yet, until we found out that such discarding by the hardware is necessary. Assume a common setup to enable the PHY Polling Unit if present, don't discard any packets, and mask all interrupt sources. Tested on 88E6352 and 88E6185. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 8 -------- drivers/net/dsa/mv88e6131.c | 11 ----------- drivers/net/dsa/mv88e6171.c | 9 --------- drivers/net/dsa/mv88e6352.c | 9 --------- drivers/net/dsa/mv88e6xxx.c | 13 +++++++++++++ 5 files changed, 13 insertions(+), 37 deletions(-) commit 08a012619a0349b8e02797bdfe57051fe7df3d3b Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:50 2016 -0400 net: dsa: mv88e6xxx: factorize global setup Every driver is calling mv88e6xxx_setup_global after mv88e6xxx_setup_common. Call the former in the latter. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 4 -- drivers/net/dsa/mv88e6131.c | 4 -- drivers/net/dsa/mv88e6171.c | 4 -- drivers/net/dsa/mv88e6352.c | 4 -- drivers/net/dsa/mv88e6xxx.c | 109 +++++++++++++++++++++++--------------------- drivers/net/dsa/mv88e6xxx.h | 1 - 6 files changed, 56 insertions(+), 70 deletions(-) commit 552238b59487eaac1477bdb7b0c4c652f29cbc86 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:49 2016 -0400 net: dsa: mv88e6xxx: factorize switch reset Add a MV88E6XXX_FLAG_PPU_ACTIVE flag to describe how to reset the switch, and merge the reset call to the common setup code. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 4 -- drivers/net/dsa/mv88e6131.c | 4 -- drivers/net/dsa/mv88e6171.c | 4 -- drivers/net/dsa/mv88e6352.c | 4 -- drivers/net/dsa/mv88e6xxx.c | 137 +++++++++++++++++++++++--------------------- drivers/net/dsa/mv88e6xxx.h | 6 +- 6 files changed, 76 insertions(+), 83 deletions(-) commit 2672f82548de2be29adcf5ef3c99fdaa1e5ace32 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:48 2016 -0400 net: dsa: mv88e6xxx: factorize ATU access Add a MV88E6XXX_FLAG_ATU flag to identify switch models with an Address Translation Unit. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 4 ++++ drivers/net/dsa/mv88e6xxx.c | 14 ++++++++++++++ drivers/net/dsa/mv88e6xxx.h | 24 ++++++++++++++++++------ 3 files changed, 36 insertions(+), 6 deletions(-) commit 54d77b5b6ac92c76ee7dd360d8b7b0dfabf9f5f0 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:47 2016 -0400 net: dsa: mv88e6xxx: factorize VTU access Add a MV88E6XXX_FLAG_VTU flag to indentify switch models with a VLAN Table Unit. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 5 +++++ drivers/net/dsa/mv88e6xxx.c | 16 ++++++++++++++++ drivers/net/dsa/mv88e6xxx.h | 24 ++++++++++++++++++------ 3 files changed, 39 insertions(+), 6 deletions(-) commit 936f234a9624dbce9f723cbb24f135c60f76c148 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:46 2016 -0400 net: dsa: mv88e6xxx: factorize bridge support Add MV88E6XXX_FLAG_PORTSTATE and MV88E6XXX_FLAG_VLANTABLE flags to identify switch models with required 802.1D operations. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 3 +++ drivers/net/dsa/mv88e6131.c | 1 + drivers/net/dsa/mv88e6xxx.c | 9 +++++++++ drivers/net/dsa/mv88e6xxx.h | 38 ++++++++++++++++++++++++++++++-------- 4 files changed, 43 insertions(+), 8 deletions(-) commit 2306251341bda39f1c3260bb96479db4dff2fe95 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:45 2016 -0400 net: dsa: mv88e6131: add registers access Only 6131 was not supporting the port registers access yet. Assume such support and use the unlock access routines in the meantime. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6131.c | 2 ++ drivers/net/dsa/mv88e6xxx.c | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) commit aadbdb8a0da6c38e8370fb7cd860f38b266c6037 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:44 2016 -0400 net: dsa: mv88e6xxx: factorize EEE access Add a MV88E6XXX_FLAG_EEE flag to describe switch models featuring Energy Efficient Ethernet. Use it to conditionally support such access in the common code. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 2 ++ drivers/net/dsa/mv88e6131.c | 2 ++ drivers/net/dsa/mv88e6171.c | 2 ++ drivers/net/dsa/mv88e6xxx.c | 6 ++++++ drivers/net/dsa/mv88e6xxx.h | 11 +++++++++-- 5 files changed, 21 insertions(+), 2 deletions(-) commit 1d13a06e00bdcde27d4d88e011841ff0924b3dde Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:43 2016 -0400 net: dsa: mv88e6xxx: factorize MAC address setting Some switch models have a dedicated register for Switch MAC/WoF/WoL. This register, when present, is used to indirectly set the switch MAC address, instead of a direct write to 3 global registers. Identify this feature and share a common mv88e6xxx_set_addr function. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 2 +- drivers/net/dsa/mv88e6131.c | 2 +- drivers/net/dsa/mv88e6171.c | 2 +- drivers/net/dsa/mv88e6352.c | 2 +- drivers/net/dsa/mv88e6xxx.c | 14 ++++++++++++-- drivers/net/dsa/mv88e6xxx.h | 17 ++++++++++++++--- 6 files changed, 30 insertions(+), 9 deletions(-) commit 6594f615792a52ccb66c07000ade917e8c8f62fd Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:42 2016 -0400 net: dsa: mv88e6xxx: factorize temperature access Add MV88E6XXX_FLAG_TEMP and MV88E6XXX_FLAG_TEMP_LIMIT flags to describe switch models featuring a temperature access. Use them to centralize the access to the temperature feature. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 3 +++ drivers/net/dsa/mv88e6131.c | 6 ++++++ drivers/net/dsa/mv88e6171.c | 3 +++ drivers/net/dsa/mv88e6xxx.c | 9 ++++++--- drivers/net/dsa/mv88e6xxx.h | 22 ++++++++++++++++++---- 5 files changed, 36 insertions(+), 7 deletions(-) commit d24645bebce2b13b3c5c49ff392cfb7f3efe0d76 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:41 2016 -0400 net: dsa: mv88e6xxx: factorize EEPROM access Add a MV88E6XXX_FLAG_EEPROM flag to describe switch models featuring an EEPROM and distribute the EEPROM access routines to all models. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 2 + drivers/net/dsa/mv88e6131.c | 2 + drivers/net/dsa/mv88e6171.c | 2 + drivers/net/dsa/mv88e6352.c | 207 +----------------------------------------- drivers/net/dsa/mv88e6xxx.c | 216 +++++++++++++++++++++++++++++++++++++++++++- drivers/net/dsa/mv88e6xxx.h | 18 +++- 6 files changed, 236 insertions(+), 211 deletions(-) commit 6d5834a1adefd6199bbd7c8b2ba3a131f38e161e Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:40 2016 -0400 net: dsa: mv88e6xxx: factorize PHY indirect access Some switch has dedicated SMI PHY Command and Data registers, used to indirectly access the PHYs, instead of direct access. Identify these switch models and make mv88e6xxx_phy_{read,write} generic enough to support every models. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6171.c | 4 ++-- drivers/net/dsa/mv88e6352.c | 4 ++-- drivers/net/dsa/mv88e6xxx.c | 37 ++++--------------------------------- drivers/net/dsa/mv88e6xxx.h | 22 +++++++++++++--------- 4 files changed, 21 insertions(+), 46 deletions(-) commit 8c9983a2249269f9b0f22bf070bf856ec1ff58d7 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:39 2016 -0400 net: dsa: mv88e6xxx: factorize PHY access with PPU Add a MV88E6XXX_FLAG_PPU flag to describe switch models with a PHY Polling Unit. This allows to merge PPU specific PHY access code in the share code. Make the mv88e6xxx_ppu_disable and mv88e6xxx_phy_{read,write}_ppu functions use unlocked register accesses in order to call them in mv88e6xxx_phy_{read,write} in a locked context. Since the PPU code is shared, also remove NET_DSA_MV88E6XXX_NEED_PPU. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/Kconfig | 5 ----- drivers/net/dsa/mv88e6131.c | 39 ++------------------------------------- drivers/net/dsa/mv88e6xxx.c | 40 +++++++++++++++++++++++++--------------- drivers/net/dsa/mv88e6xxx.h | 25 ++++++++++++++++--------- 4 files changed, 43 insertions(+), 66 deletions(-) commit b5058d7a308035233db18032edc17135cb17ae27 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon May 9 13:22:38 2016 -0400 net: dsa: mv88e6xxx: add flags to info Add a flags bitmap to the info structure in order to identify features supported or not by the different switch models. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 3 +++ drivers/net/dsa/mv88e6131.c | 4 ++++ drivers/net/dsa/mv88e6171.c | 4 ++++ drivers/net/dsa/mv88e6352.c | 6 ++++++ drivers/net/dsa/mv88e6xxx.h | 21 +++++++++++++++++++++ 5 files changed, 38 insertions(+) commit 41842dc1f072d69ca40f36ce5032ccfd23488f51 Author: Helmut Schaa <helmut.schaa@googlemail.com> Date: Fri Apr 29 15:06:34 2016 +0200 ath9k: Fix symbol overlap window for half/quarter channels Since commit cd6cfd7311a385144a2f9c74f692ae2df3ae033f "ath9k: do not set half/quarter channel flags in AR_PHY_MODE" the condition "rfMode & (AR_PHY_MODE_QUARTER | AR_PHY_MODE_HALF)" would never evaluate to true. Fix this by using the available IS_CHAN_HALF_RATE and IS_CHAN_QUARTER_RATE marcros instead. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Cc: Felix Fietkau <nbd@openwrt.org> Acked-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dd254f5a382cc7879db7a07ed266b12d38fe3ab6 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon May 9 11:54:48 2016 -0400 fold checks into iterate_and_advance() they are open-coded in all users except iov_iter_advance(), and there they wouldn't be a bad idea either - as it is, iov_iter_advance(i, 0) ends up dereferencing potentially past the end of iovec array. It doesn't do anything with the value it reads, and very unlikely to trigger an oops on dereference, but it is not impossible. Reported-by: Jiri Slaby <jslaby@suse.cz> Reported-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> lib/iov_iter.c | 104 ++++++++++++++++++++------------------------------------- 1 file changed, 36 insertions(+), 68 deletions(-) commit ec788795dde419af4935c3c9d08d641707114eec Author: Alejandro Torrado <aletorrado@gmail.com> Date: Mon Apr 18 13:37:00 2016 -0300 [media] dib0700: add USB ID for another STK8096-PVR ref design based card USB_PID_DIBCOM_STK8096GP also comes with USB_VID_DIBCOM vendor ID. Signed-off-by: Alejandro Torrado <aletorrado@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/dvb-usb/dib0700_devices.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit b0291715d31c891bcb5de936271881f58600f7c1 Author: Helmut Schaa <helmut.schaa@googlemail.com> Date: Thu Apr 28 16:45:06 2016 +0200 ath9k: Simplify ar9003_hw_tx99_set_txpower There's no need to keep the same for loop twice in the code. Move the txpower cap before the loop to reduce code complexity. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_phy.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit e7ae328961ffcf78bb18d0ecdb1e5a50d1185336 Author: Helmut Schaa <helmut.schaa@googlemail.com> Date: Thu Apr 28 16:45:05 2016 +0200 ath9k: Move TX99 config option under ath9k debugging Since ATH9K_TX99 depends on ATH9K_DEBUGFS anyway move it there such that "make menuconfig" will indent TX99 support below ath9k debugging. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/Kconfig | 40 +++++++++++++++++----------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit 8569f5915456f462c8a88b751fa6c14596bfa3fe Author: Helmut Schaa <helmut.schaa@googlemail.com> Date: Thu Apr 28 16:45:04 2016 +0200 ath9k: reuse ar9003_hw_tx_power_regwrite for tx99 setup The same functionality as ar9003_hw_tx_power_regwrite is hardcoded in ar9003_hw_tx99_set_txpower. Just reuse the existing ar9003_hw_tx_power_regwrite for TX99 setup too. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_eeprom.c | 2 +- drivers/net/wireless/ath/ath9k/ar9003_eeprom.h | 1 + drivers/net/wireless/ath/ath9k/ar9003_phy.c | 60 ++------------------------ 3 files changed, 5 insertions(+), 58 deletions(-) commit eca4ca84a965d7fcc3430439898d0728818edc56 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Thu Apr 14 22:00:08 2016 -0300 [media] tvp5150: propagate I2C write error in .s_register callback The tvp5150_write() function can fail so don't return 0 unconditionally in tvp5150_s_register() but propagate what's returned by tvp5150_write(). Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/tvp5150.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit cacdd6a4a8d5115da2767769b44bd435455f6424 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Thu Apr 14 22:00:07 2016 -0300 [media] tvp5150: return I2C write operation failure to callers The tvp5150_write() function calls i2c_smbus_write_byte_data() that can fail but does not propagate the error to the caller. Instead it just prints a debug, so callers can't know if the operation failed. So change the function to return the error code to the caller so it knows that the write failed and also print an error instead of just printing a debug information. While being there remove the inline keyword from tvp5150_write() to make it consistent with tvp5150_read() and also because it's called in a lot of places, so making inline is in fact counter productive since it makes the kernel image size to be much bigger (~16 KiB). Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/tvp5150.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 6c0b43df74f900e7f31a49d1844f166df0f8afc6 Merge: e88ccab 8d7f2d8 a5c0e0b 3d1a244 a0d284d d546635 e85e8f6 Author: Joerg Roedel <jroedel@suse.de> Date: Mon May 9 19:39:17 2016 +0200 Merge branches 'arm/io-pgtable', 'arm/rockchip', 'arm/omap', 'x86/vt-d', 'ppc/pamu', 'core' and 'x86/amd' into next commit d546635731317a5f8923b1045d0f4403e8024a7d Author: Robin Murphy <robin.murphy@arm.com> Date: Mon May 9 17:20:09 2016 +0100 iommu/arm-smmu: Use per-domain page sizes. Now that we can accurately reflect the context format we choose for each domain, do that instead of imposing the global lowest-common-denominator restriction and potentially ending up with nothing. We currently have a strict 1:1 correspondence between domains and context banks, so we don't need to entertain the possibility of multiple formats _within_ a domain. Signed-off-by: Will Deacon <will.deacon@arm.com> [rm: split from original patch, added SMMUv3] Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/arm-smmu-v3.c | 19 ++++++++++--------- drivers/iommu/arm-smmu.c | 27 +++++++++++++++------------ 2 files changed, 25 insertions(+), 21 deletions(-) commit 11a2a949d05e9d2d9823f0c45fa476743d9e462b Author: Olli Salonen <olli.salonen@iki.fi> Date: Mon Apr 4 12:12:52 2016 -0300 [media] em28xx: add support for Hauppauge WinTV-dualHD DVB tuner Hauppauge WinTV-dualHD is a USB 2.0 dual DVB-T/T2/C tuner with following components: USB bridge: Empia EM28274 (chip id is the same as EM28174) Demodulator: 2x Silicon Labs Si2168-B40 Tuner: 2x Silicon Labs Si2157-A30 This patch adds support only for the first tuner. The demodulator needs firmware, available for example here: http://palosaari.fi/linux/v4l-dvb/firmware/Si2168/Si2168-B40/4.0.11/ The demodulators sit on the same I2C bus and their addresses are 0x64 and 0x67. The tuners are behind the demodulators and their addresses are 0x60 and 0x63. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/video4linux/CARDLIST.em28xx | 1 + drivers/media/usb/em28xx/em28xx-cards.c | 58 ++++++++++++++++++++++++++++ drivers/media/usb/em28xx/em28xx-dvb.c | 64 +++++++++++++++++++++++++++++++ drivers/media/usb/em28xx/em28xx-reg.h | 13 +++++++ drivers/media/usb/em28xx/em28xx.h | 2 + 5 files changed, 138 insertions(+) commit 628288d08a6162aa50e4dbd5918a9867b4c40e2f Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon May 9 14:15:00 2016 -0300 [media] em28xx: add missing USB IDs Add missing USB id's for em281xx devices. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/video4linux/CARDLIST.em28xx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit aff633406ca2772554bad7b37f2dfbc409b6ea74 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Sat May 7 02:17:00 2016 -0700 perf script: Fix incorrect python db-export error message Fix the error message printed when attempting and failing to create the call path root incorrectly references the call return process. This change fixes the message to properly reference the failure to create the call path root. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462612620-25008-2-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/scripting-engines/trace-event-python.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 685f11097ab21221d734a259f2ba20684ffe3f05 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon May 9 14:06:09 2016 -0300 [media] update cx23885 and em28xx cardlists Some new boards were added without updating those lists. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/video4linux/CARDLIST.cx23885 | 2 ++ Documentation/video4linux/CARDLIST.em28xx | 1 + 2 files changed, 3 insertions(+) commit e899108994540f09dae236571d100af6e0749905 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon May 9 12:53:03 2016 -0400 isofs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/isofs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f340c5fc93bda334efd9f2b5855ef0d3746e1564 Author: Andi Kleen <ak@linux.intel.com> Date: Thu May 5 16:04:04 2016 -0700 perf stat: Scale values by unit before metrics Scale values by unit before passing them to the metrics printing functions. This is needed for TopDown, because it needs to scale the slots correctly by pipeline width / SMTness. For existing metrics it shouldn't make any difference, as those generally use events that don't have any units. Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1462489447-31832-8-git-send-email-andi@firstfloor.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/stat.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6d1003ae8db228b74ef61536364cd2a1bd973dd8 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:56 2016 +0200 libata: support host-aware and host-managed ZAC devices Byte 69 bits 0:1 in the IDENTIFY DEVICE data indicate a host-aware ZAC device. Host-managed ZAC devices have their own individual signature, and to not set the bits in the IDENTIFY DEVICE data. And whenever we detect a ZAC-compatible device we should be displaying the zoned block characteristics VPD page. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 94 +++++++++++++++++++++++++++++++++++++++++++++++ drivers/ata/libata-scsi.c | 38 ++++++++++++++++++- include/linux/ata.h | 1 + include/linux/libata.h | 7 ++++ 4 files changed, 138 insertions(+), 2 deletions(-) commit 856c4663930988118d9f355aad66811dd6df06de Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:55 2016 +0200 libata: support device-managed ZAC devices Device-managed ZAC devices just set the zoned capabilities field in INQUIRY byte 69 (cf ACS-4). This corresponds to the 'zoned' field in the block device characteristics VPD page. As this is only defined in SPC-5/SBC-4 we also need to update the supported SCSI version descriptor. Reviewed-by: Shaun Tancheff <shaun.tancheff@seagate.com> Tested-by: Shaun Tancheff <shaun.tancheff@seagate.com> Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 19 ++++++++++--------- include/linux/ata.h | 5 +++++ 2 files changed, 15 insertions(+), 9 deletions(-) commit 284b3b77ea883234dadb2cbf97b145c3c30fe4bd Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:54 2016 +0200 libata: NCQ encapsulation for ZAC MANAGEMENT OUT Add NCQ encapsulation for ZAC MANAGEMENT OUT and evaluate NCQ Non-Data log pages to figure out if NCQ encapsulation is supported. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 43 ++++++++++++++++++++++++++++++++++++++++--- drivers/ata/libata-scsi.c | 18 +++++++++++++----- drivers/ata/libata-trace.c | 3 +++ include/linux/ata.h | 7 +++++++ include/linux/libata.h | 7 +++++++ 5 files changed, 70 insertions(+), 8 deletions(-) commit 27708a9579ee069c6e0ebb6e61ac1114ed1d546c Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:53 2016 +0200 libata: Implement ZBC OUT translation ZAC drives implement a 'ZAC Management Out' command template, which maps onto the ZBC OUT command. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 1 + drivers/ata/libata-scsi.c | 67 +++++++++++++++++++++++++++++++++++++++++++ drivers/ata/libata-trace.c | 16 +++++++++++ include/linux/ata.h | 7 +++++ include/trace/events/libata.h | 1 + 5 files changed, 92 insertions(+) commit 28a3fc2295a744a0d2ddf86b2ccdf03fbab123f9 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:52 2016 +0200 libata: implement ZBC IN translation ZAC drives implement a 'ZAC Management In' command template, which maps onto the ZBC IN command. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 1 + drivers/ata/libata-scsi.c | 157 ++++++++++++++++++++++++++++++++++++++++++ drivers/ata/libata-trace.c | 10 +++ include/linux/ata.h | 10 ++- include/linux/libata.h | 7 ++ include/trace/events/libata.h | 1 + 6 files changed, 185 insertions(+), 1 deletion(-) commit 3a92945b24c7ff46757a3d5d5112bfc62d2e45b2 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:51 2016 +0200 libata: fixup ZAC device disabling libata device disabling is ... curious. So add the correct definitions that we can disable ZAC devices properly. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> include/linux/libata.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 59f68474c2a1f5f0cedede60b60de97c603dc194 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:50 2016 +0200 libata-scsi: Generate sense code for disabled devices If a device is disabled after error recovery it doesn't make any sense to generate an ATA sense, but we should rather return a generic sense code indicating the device is gone. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 6 ++++++ 1 file changed, 6 insertions(+) commit a57038496422d7d21b7e41ed70d63bf0c6ff6068 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:49 2016 +0200 libata-trace: decode subcommands Some commands like FPDMA RECEIVE or NCQ NON DATA can encapsulate other commands to NCQ transport. So decode the subcmds, too. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-trace.c | 43 +++++++++++++++++++++++++++++++++++++++++++ include/linux/ata.h | 17 +++++++++++++++++ include/trace/events/libata.h | 7 ++++++- 3 files changed, 66 insertions(+), 1 deletion(-) commit fe5af0cc3029d52e31d282f5d53787d308e9695a Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:48 2016 +0200 libata: Check log page directory before accessing pages When reading the NCQ Send/Recv log it might actually not supported, thereby causing irritating messages 'READ LOG DMA EXT failed'. Instead we should be reading the log directory first to figure out if the log is actually supported before trying to access it. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 17 +++++++++++++++++ include/linux/ata.h | 1 + 2 files changed, 18 insertions(+) commit 5c65d8bb3503beb12864895426a69269c19e6e87 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:47 2016 +0200 libata: Add command definitions for NCQ Encapsulation for READ LOG DMA EXT ACS-4 defines an NCQ encapsulation for READ LOG DMA EXT. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> include/linux/ata.h | 5 +++++ include/linux/libata.h | 7 +++++++ 2 files changed, 12 insertions(+) commit 5a2335512ad30ea38e53e112ca51e8a314dc6874 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:46 2016 +0200 libata: Separate out ata_dev_config_ncq_send_recv() Move NCQ SEND/RECEIVE checks into a separate function. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 47 +++++++++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 20 deletions(-) commit 661ce1f0c4a69f92ad781d8d2c205c90dd9c5833 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:45 2016 +0200 libata/libsas: Define ATA_CMD_NCQ_NON_DATA Define the NCQ NON DATA command and update libsas to handle it correctly. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 1 + drivers/scsi/isci/request.c | 3 ++- drivers/scsi/libsas/sas_ata.c | 3 ++- drivers/scsi/mvsas/mv_sas.c | 3 ++- drivers/scsi/pm8001/pm8001_sas.c | 3 ++- include/linux/ata.h | 1 + include/trace/events/libata.h | 1 + 7 files changed, 11 insertions(+), 4 deletions(-) commit ef026b18bb8260e21b4a61685eac46ecdc490d00 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:44 2016 +0200 libsas: enable FPDMA SEND/RECEIVE Update libsas and dependent drivers to handle FPDMA SEND/RECEIVE correctly. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 2 ++ drivers/scsi/isci/request.c | 4 +++- drivers/scsi/libsas/sas_ata.c | 6 ++++-- drivers/scsi/mvsas/mv_sas.c | 4 +++- drivers/scsi/pm8001/pm8001_sas.c | 4 +++- 5 files changed, 15 insertions(+), 5 deletions(-) commit d238ffd59d3c65c608f39a0ab2819b63c912f783 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 25 12:45:43 2016 +0200 libata: do not attempt to retrieve sense code twice Do not call ata_request_sense() if the sense code is already present. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 698f6700a6f19ba4550a722eaacf9f9d212b3fd9 Merge: 7780081 13f3077 Author: Tejun Heo <tj@kernel.org> Date: Mon May 9 12:34:39 2016 -0400 Merge branch '4.7/scsi-queue' of git://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi into for-4.7-zac Pulling in the dependencies for further ZAC changes. Signed-off-by: Tejun Heo <tj@kernel.org> commit 26f588308efc7f1834b7ee0b1dd4f9a904f555a3 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 6 21:40:40 2016 +0300 libata-scsi: use %*ph to dump small buffers Replace custom approach by %*ph specifier to dump small buffers in hex format. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 841e3558b2de6d8c53dae4f01c7a81cd53e42e5c Author: He Kuang <hekuang@huawei.com> Date: Fri May 6 08:59:07 2016 +0000 perf callchain: Recording 'dwarf' callchains do not need DWARF unwinding support There is no need to check for DWARF unwinding support when using the 'dwarf' callchain record method, as this will only ask the kernel to collect stack dumps for later DWARF CFI processing, which can be done in another machine, where the support for DWARF unwinding need to be present. Signed-off-by: He Kuang <hekuang@huawei.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Ekaterina Tumanova <tumanova@linux.vnet.ibm.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pekka Enberg <penberg@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1462525154-125656-2-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/util.c | 2 -- 1 file changed, 2 deletions(-) commit 1fa9a1ad0a9db3c745fe0c1bfa73fd87901fd7f3 Author: Guoqing Jiang <gqjiang@suse.com> Date: Tue May 3 22:22:15 2016 -0400 md-cluster: check the return value of process_recvd_msg We don't need to run the full path of recv_daemon if process_recvd_msg doesn't return 0. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md-cluster.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 51e453aecb267b6a99b1d2853bccd5bba7340236 Author: Guoqing Jiang <gqjiang@suse.com> Date: Wed May 4 02:17:09 2016 -0400 md-cluster: gather resync infos and enable recv_thread after bitmap is ready The in-memory bitmap is not ready when node joins cluster, so it doesn't make sense to make gather_all_resync_info() called so earlier, we need to call it after the node's bitmap is setup. Also, recv_thread could be wake up after node joins cluster, but it could cause problem if node receives RESYNCING message without persionality since mddev->pers->quiesce is called in process_suspend_info. This commit introduces a new cluster interface load_bitmaps to fix above problems, load_bitmaps is called in bitmap_load where bitmap and persionality are ready, and load_bitmaps does the following tasks: 1. call gather_all_resync_info to load all the node's bitmap info. 2. set MD_CLUSTER_ALREADY_IN_CLUSTER bit to recv_thread could be wake up, and wake up recv_thread if there is pending recv event. Then ack_bast only wakes up recv_thread after IN_CLUSTER bit is ready otherwise MD_CLUSTER_PENDING_RESYNC_EVENT is set. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 3 +++ drivers/md/md-cluster.c | 30 ++++++++++++++++++++++++------ drivers/md/md-cluster.h | 1 + 3 files changed, 28 insertions(+), 6 deletions(-) commit 85ad1d13ee9b3db00615ea24b031c15e5ba14fd1 Author: Guoqing Jiang <gqjiang@suse.com> Date: Tue May 3 22:22:13 2016 -0400 md: set MD_CHANGE_PENDING in a atomic region Some code waits for a metadata update by: 1. flagging that it is needed (MD_CHANGE_DEVS or MD_CHANGE_CLEAN) 2. setting MD_CHANGE_PENDING and waking the management thread 3. waiting for MD_CHANGE_PENDING to be cleared If the first two are done without locking, the code in md_update_sb() which checks if it needs to repeat might test if an update is needed before step 1, then clear MD_CHANGE_PENDING after step 2, resulting in the wait returning early. So make sure all places that set MD_CHANGE_PENDING are atomicial, and bit_clear_unless (suggested by Neil) is introduced for the purpose. Cc: Martin Kepplinger <martink@posteo.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: <linux-kernel@vger.kernel.org> Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md.c | 27 ++++++++++++++------------- drivers/md/raid1.c | 4 ++-- drivers/md/raid10.c | 8 ++++---- drivers/md/raid5-cache.c | 4 ++-- drivers/md/raid5.c | 4 ++-- include/linux/bitops.h | 16 ++++++++++++++++ 6 files changed, 40 insertions(+), 23 deletions(-) commit fe67d19a2d7b31f1c29efbe1819c921d4a9bb012 Author: Heinz Mauelshagen <heinzm@redhat.com> Date: Tue May 3 22:15:31 2016 +0200 md: raid5: add prerequisite to run underneath dm-raid In case md runs underneath the dm-raid target, the mddev does not have a request queue or gendisk, thus avoid accesses. This patch adds a missing conditional to the raid5 personality. Signed-of-by: Heinz Mauelshagen <heinzm@redhat.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/raid5.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 859644f0fa2141b5f7db0e3744999ec3bb5719d3 Author: Heinz Mauelshagen <heinzm@redhat.com> Date: Tue May 3 19:43:24 2016 +0200 md: raid10: add prerequisite to run underneath dm-raid In case md runs underneath the dm-raid target, the mddev does not have a request queue or gendisk, thus avoid accesses to it. This patch adds two missing conditionals to the raid10 personality. Signed-of-by: Heinz Mauelshagen <heinzm@redhat.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/raid10.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit 092398dce8c2406bfb0c9eebc3e764ff2ddb62a8 Author: Heinz Mauelshagen <heinzm@redhat.com> Date: Tue May 3 19:43:57 2016 +0200 md: md.c: fix oops in mddev_suspend for raid0 Introduced by upstream commit 70d9798b95562abac005d4ba71d28820f9a201eb The raid0 personality does not create mddev->thread as oposed to other personalities leading to its unconditional access in mddev_suspend() causing an oops. Patch checks for mddev->thread in order to keep the intention of aforementioned commit. Fixes: 70d9798b9556 ("MD: warn for potential deadlock") Cc: stable@vger.kernel.org (4.5+) Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eda220acd5f2cef789430110f66a74cb49309b68 Author: Shuah Khan <shuahkh@osg.samsung.com> Date: Mon Mar 28 21:25:29 2016 -0300 [media] media: au0828 fix au0828_v4l2_device_register() to not unlock and free au0828_v4l2_device_register() unlocks au0828_dev->lock and frees au0828 dev in error legs before return. au0828_usb_probe() does the same when au0828_v4l2_device_register() returns error. Fix au0828_v4l2_device_register() to not to unlock and free in its error legs. Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/au0828/au0828-video.c | 4 ---- 1 file changed, 4 deletions(-) commit c23ac90f78aa9190643c82c1975a0cfe480d7c60 Author: Peter Griffin <peter.griffin@linaro.org> Date: Thu Mar 24 08:23:52 2016 -0300 [media] c8sectpfe: Rework firmware loading mechanism c8sectpfe driver relied on CONFIG_FW_LOADER_USER_HELPER_FALLBACK option for loading its xp70 firmware. A previous commit removed this Kconfig option, as it is apparently harmful, but did not update the driver code which relied on it. This patch reworks the firmware loading into the start_feed callback. At this point we can be sure the rootfs is present, thereby removing the depedency on CONFIG_FW_LOADER_USER_HELPER_FALLBACK. Fixes: 79f5b6ae960d ('[media] c8sectpfe: Remove select on CONFIG_FW_LOADER_USER_HELPER_FALLBACK') Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> .../media/platform/sti/c8sectpfe/c8sectpfe-core.c | 65 ++++++++-------------- 1 file changed, 22 insertions(+), 43 deletions(-) commit ddecd1492de476488a92493510fb86c6ffe9acbd Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:42:32 2016 +0300 ASoC: davinci-mcasp: Calculate AUXCLK divider when setting up master clocks If the McASP is used as clock master and the reference clock is AUXCLK we can have additional level of divider. The BCLK divider is limited to maximum 32, if the desired bclk can not be reached with this, the AUXCLK divider also needs to be used. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) commit 3e9bee11d83190b852d428b3e35a942c6e2293cd Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:42:31 2016 +0300 ASoC: davinci-mcasp: Restructure the davinci_mcasp_calc_clk_div() Change the return value to error_pmm instead of the BCLK div and handle the divider configuration to McASP within the function when the set flag is true. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) commit 226e73e23b6b7f7d6df47562a7555ddb121163cf Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:42:30 2016 +0300 ASoC: davinci-mcasp: Change __davinci_mcasp_set_clkdiv() first parameter Change the first parameter to struct davinci_mcasp* from struct snd_soc_dai* The function internally does not use or need the DAI information. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 20d4b10730183a02851580f072bd9b0122873dc5 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:42:29 2016 +0300 ASoC: davinci-mcasp: Use defines for clkdiv IDs Instead of hardwired IDs add defines for the available dividers. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 7 ++++--- sound/soc/davinci/davinci-mcasp.h | 5 +++++ 2 files changed, 9 insertions(+), 3 deletions(-) commit ee105cac24693c8f3ea92e1700d5d16c4b035eb5 Author: Peter Griffin <peter.griffin@linaro.org> Date: Thu Mar 24 08:23:51 2016 -0300 [media] c8sectpfe: Demote print to dev_dbg Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/sti/c8sectpfe/c8sectpfe-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a6311d275126f65e4ccb88d3d384003b8dab47d8 Author: Peter Griffin <peter.griffin@linaro.org> Date: Thu Mar 24 08:23:50 2016 -0300 [media] c8sectpfe: Fix broken circular buffer wp management During the review process, a regression was intoduced in the circular buffer write pointer management. This means that wp doesn't get managed properly once the buffer becomes full. Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/sti/c8sectpfe/c8sectpfe-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 39f0ccde3624e7cf882faccf7f72a47b7a763bfb Author: Takashi Iwai <tiwai@suse.de> Date: Mon May 9 17:47:37 2016 +0200 ALSA: hda - Clarify CONFIG_SND_HDA_RECONFIG usages Since the recent rewrite of HD-audio infrastructure, CONFIG_SND_HDA_RECONFIG has a slightly different meaning. In the earlier versions, it implicitly assumed only the usage via hwdep sysfs entries. Meanwhile, in the recent version, this option is meant to enable the reconfig code in HD-audio driver, which may be used by the patch loader without hwdep interface. This patch tries to clarify the usage pattern a bit better, hopefully avoid the further confusion. Reported-by: Jochen Henneberg <jh@henneberg-systemdesign.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/Kconfig | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit e17a21d3bb067e561fc0112a3957f579af26d9d9 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu May 5 10:48:47 2016 -0400 get_acorn_filename(): deobfuscate a bit Lots of Idiotic Silly Parentheses is -> that way... What that condition checks is that there's exactly 32 bytes between the end of name and the end of entire drectory record. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/isofs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 972b241f8441dc37a3f89dcd7e71d7f013873d13 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 4 16:24:53 2016 -0400 btrfs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/btrfs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5e261246ce337280087f5211fbc91764daa12286 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 4 16:24:04 2016 -0400 logfs: no need to lock directory in lseek Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/logfs/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 51a16a9cd538736784e8471602d867bf6a26d0d5 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed May 4 16:21:20 2016 -0400 switch ecryptfs to ->iterate_shared Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ecryptfs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a063ff1e43833559efff0ef782deb464a803644b Merge: 5963ded 99d8258 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon May 9 11:41:30 2016 -0400 Merge branch 'for-linus' into work.lookups commit 5963ded8fecedbab6b99274126434c7a22c45c84 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun May 1 00:08:03 2016 -0400 9p: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/9p/vfs_dir.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 98d4b8d8f07128c127f767c0a8726db948b28e96 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Apr 30 23:26:25 2016 -0400 fat: switch to ->iterate_shared() ... and make that weird ioctl lock directory only shared. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/fat/dir.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d375570fa83761161bb3d9120e0260dec66f051d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Apr 30 23:08:45 2016 -0400 romfs, squashfs: switch to ->iterate_shared() don't need to lock directory in ->llseek(), either Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/romfs/super.c | 4 ++-- fs/squashfs/dir.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit c51da20c48b76ef1114d14b6b6ff190e11afab0e Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Apr 30 22:37:34 2016 -0400 more trivial ->iterate_shared conversions Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/bfs/dir.c | 2 +- fs/cramfs/inode.c | 2 +- fs/efs/dir.c | 3 +-- fs/exofs/dir.c | 2 +- fs/freevxfs/vxfs_lookup.c | 2 +- fs/jffs2/dir.c | 2 +- fs/libfs.c | 2 +- fs/logfs/dir.c | 2 +- fs/nilfs2/dir.c | 2 +- fs/omfs/dir.c | 2 +- fs/openpromfs/inode.c | 2 +- fs/qnx4/dir.c | 2 +- fs/qnx6/dir.c | 2 +- fs/reiserfs/dir.c | 2 +- fs/ubifs/dir.c | 2 +- fs/udf/dir.c | 2 +- 16 files changed, 16 insertions(+), 17 deletions(-) commit 060ff688cadac398a17f09bd87b16fd0bf943899 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 20:49:14 2016 -0400 lustre: don't need to lock inode in directory lseek Note that lustre has its private mutex protecting directory pagecache; if they ever remove it, they'll need to be careful with PageChecked() use. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> drivers/staging/lustre/lustre/llite/dir.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 8cb0d2c1c7dea61e9b976cadedeae228f1180cbd Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 19:59:01 2016 -0400 kernfs: no point locking directory around that generic_file_llseek() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/kernfs/dir.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) commit a01b3007ffb9be0180e744f0d15b130b0a76a29f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 19:50:05 2016 -0400 configfs_readdir(): make safe under shared lock Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/configfs/dir.c | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) commit 884be175351e73c515303118150f195dd611787c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 23:56:31 2016 -0400 nfs: per-name sillyunlink exclusion use d_alloc_parallel() for sillyunlink/lookup exclusion and explicit rwsem (nfs_rmdir() being a writer and nfs_call_unlink() - a reader) for rmdir/sillyunlink one. That ought to make lookup/readdir/!O_CREAT atomic_open really parallel on NFS. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/nfs/dir.c | 9 +-- fs/nfs/inode.c | 4 +- fs/nfs/nfs4proc.c | 2 +- fs/nfs/nfstrace.h | 2 +- fs/nfs/unlink.c | 193 +++++++++++++----------------------------------- include/linux/nfs_fs.h | 11 +-- include/linux/nfs_xdr.h | 4 +- 7 files changed, 61 insertions(+), 164 deletions(-) commit 875f6fffa2e09b48fa07ecbf2e28dd2425b5ce01 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 14:59:11 2016 +0100 ALSA: compress: Replace complex if statement with switch A switch statement looks a bit cleaner than an if statement spread over 3 lines, as such update this to a switch. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/compress_offload.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 1d03f2bd56f3a45123a7572fb536c063068cfb83 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 14:59:10 2016 +0100 ALSA: compress: Fix poll error return codes We can't return a negative error code from the poll callback the return type is unsigned and is checked against the poll specific flags we need to return POLLERR if we encounter an error. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/compress_offload.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5bd05390ff084d7a1ea7efa8f8dc111c24b2454c Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 14:59:09 2016 +0100 ALSA: compress: Remove pointless NULL check stream can't be NULL here as we have just taken the address of it, so no need for the check. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/compress_offload.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 0b92b0cdbe419575b2233c08192b2ad28e7dbcfa Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 14:59:08 2016 +0100 ALSA: compress: Use snd_compr_get_poll on error path We have a function that returns the appropriate flags for the stream direction, so we should use it. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/compress_offload.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit e099aeea639ce491d3cd1c3802fe34d98045ffd8 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 14:59:07 2016 +0100 ALSA: pcm: Fix poll error return codes We can't return a negative error code from the poll callback the return type is unsigned and is checked against the poll specific flags we need to return POLLERR if we encounter an error. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Reviewed-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/pcm_native.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 68b21094ef9ba3ef0dd8b1e24b03e00cd3b34e26 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Apr 25 22:42:25 2016 +0100 mfd: ab8500-debugfs: Trivial fix of spelling mistake on "between" fix spelling mistake, beetween -> between Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/ab8500-debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fcdad4210fc001b2d46f4bf97a2860792f4265f8 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Apr 27 19:49:22 2016 +0200 mfd: vexpress: Add !ARCH_USES_GETTIMEOFFSET dependency The MFD_VEXPRESS_SYSREG driver selects CLKSRC_MMIO, which in turn conflicts with ARCH_USES_GETTIMEOFFSET, causing a harmless Kconfig warning when it is set: warning: (ARCH_MVEBU && ARCH_DIGICOLOR && ARCH_GEMINI && ARCH_KEYSTONE && ARCH_MOXART && ARCH_MXS && PLAT_SPEAR && ARCH_SUNXI && ARCH_TEGRA && ARCH_U300 && PLAT_ORION && ARCH_CLPS711X && ARCH_EP93XX && ARCH_NETX && ARCH_IXP4XX && ARCH_KS8695 && ARCH_W90X900 && ARCH_PXA && ARCH_SA1100 && ARCH_OMAP1 && ARCH_BCM_IPROC && ARCH_INTEGRATOR_AP && ARCH_OMAP2PLUS && MFD_VEXPRESS_SYSREG) selects CLKSRC_MMIO which has unmet direct dependencies (!ARCH_USES_GETTIMEOFFSET) This was apparently hidden by the fact that no ARM platform that still sets ARCH_USES_GETTIMEOFFSET has gpiolib support, and we already have a dependency on GPIOLIB that I added a while ago. However, after 296ad4acb8ef ("gpio: remove deps on ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB"), any platform can enable CONFIG_GPIOLIB, and that lets us enable MFD_VEXPRESS_SYSREG as well. This adds an explicit dependency on !ARCH_USES_GETTIMEOFFSET to guarantee that we can enable the CLKSRC_MMIO driver without getting warnings. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 19357366633cfc53532b587180af3655f0e453f3 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:39:14 2016 +0300 ASoC: davinci-mcasp: Do not allow multiple streams in one direction Make sure that the user can not start multiple streams with the same direction. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 7c3767115a04bc7aa87bdbd3352d1801d4bbeea4 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon May 9 13:38:10 2016 +0300 ASoC: simple-card: Add pm callbacks to platform driver Set snd_soc_pm_ops for the pm ops to make sure that the ASoC level of PM operations are going to happen. This is needed to get suspend/resume working correctly when the audio is using simple-card. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/generic/simple-card.c | 1 + 1 file changed, 1 insertion(+) commit aeea2fdd9b623fcd6991ac3617ef6a3b646c2899 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Sat May 7 20:04:52 2016 -0300 MAINTAINERS: Add myself as reviewer of FSL/NXP SoC sound drivers I would like to help reviewing FSL/NXP SoC sound drivers. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Timur Tabi <timur@tabi.org> Signed-off-by: Mark Brown <broonie@kernel.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit a022f9347a30b56dc503811a62b8e4b9c36e9a15 Merge: f736962 44549e8 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon May 9 12:21:49 2016 -0300 Merge tag 'v4.6-rc7' into patchwork Linux 4.6-rc7 * tag 'v4.6-rc7': (185 commits) Linux 4.6-rc7 parisc: fix a bug when syscall number of tracee is __NR_Linux_syscalls x86/tsc: Read all ratio bits from MSR_PLATFORM_INFO mailmap: add John Paul Adrian Glaubitz byteswap: try to avoid __builtin_constant_p gcc bug lib/stackdepot: avoid to return 0 handle mm: fix kcompactd hang during memory offlining modpost: fix module autoloading for OF devices with generic compatible property proc: prevent accessing /proc/<PID>/environ until it's ready mm/zswap: provide unique zpool name mm: thp: kvm: fix memory corruption in KVM with THP enabled MAINTAINERS: fix Rajendra Nayak's address mm, cma: prevent nr_isolated_* counters from going negative mm: update min_free_kbytes from khugepaged after core initialization huge pagecache: mmap_sem is unlocked when truncation splits pmd rapidio/mport_cdev: fix uapi type definitions mm: memcontrol: let v2 cgroups follow changes in system swappiness mm: thp: correct split_huge_pages file permission maintainers: update rmk's email address(es) writeback: Fix performance regression in wb_over_bg_thresh() ... commit e85e8f69cedb5fbc7cd16f56dd97220e61ed616e Author: Joerg Roedel <jroedel@suse.de> Date: Mon May 9 16:58:37 2016 +0200 iommu/amd: Remove statistics code The statistics are not really used for anything and should be replaced by generic and per-device statistic counters. Remove the code for now. Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/Kconfig | 10 ----- drivers/iommu/amd_iommu.c | 95 ----------------------------------------- drivers/iommu/amd_iommu_types.h | 26 ----------- 3 files changed, 131 deletions(-) commit 0c5366b3a8c77fd6d67b763c5a76dfdc314e7726 Author: Florian Westphal <fw@strlen.de> Date: Mon May 9 16:24:32 2016 +0200 netfilter: conntrack: use single slab cache An earlier patch changed lookup side to also net_eq() namespaces after obtaining a reference on the conntrack, so a single kmemcache can be used. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netns/conntrack.h | 2 -- net/netfilter/nf_conntrack_core.c | 36 ++++++++++++++---------------------- 2 files changed, 14 insertions(+), 24 deletions(-) commit a76ae1c85576b4b833a506925417d746bc839302 Author: Florian Westphal <fw@strlen.de> Date: Mon May 9 16:24:31 2016 +0200 netfilter: conntrack: use a single nat bysource table for all namespaces We already include netns address in the hash, so we only need to use net_eq in find_appropriate_src and can then put all entries into same table. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netns/conntrack.h | 4 ---- net/netfilter/nf_nat_core.c | 33 +++++++++++++++++---------------- 2 files changed, 17 insertions(+), 20 deletions(-) commit 464c38556e06723b4c77d36fecff140b8527bc59 Author: Florian Westphal <fw@strlen.de> Date: Mon May 9 16:24:30 2016 +0200 netfilter: conntrack: make netns address part of nat bysrc hash Will be needed soon when we place all in the same hash table. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_nat_core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit ff628a4dbdc4867ef9706b306fb1e8b1abbe8062 Merge: 11c3aea d4f414e Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:42:14 2016 +0200 Merge tag 'omap-for-v4.7/auxdata-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/fixes-non-critical Merge "non urgent auxdata fix for v4.7 merge window" from Tony Lindgren: Device tree auxdata handling fix that allows a match based on the compatible string if no exact match based on the IO address is found. This leaves out the need to patch auxdata for each driver when adding new SoCs. And it also reprotedly fixes the issue of passing auxdata to a child if the parent instantiates the child from DT as discussed in the "[PATCH] of/platform: Allow secondary compatible match in of_dev_lookup" mailing list thread. As a minimal use case, let's also convert omap pinctrl auxdatato use a generic match. There is no need to get this in to the v4.6-rc cycle and it can wait for v4.7 merge window. Note that these changes have now been sitting in Linux next for about two weeks so far as I wanted to make sure no new issues are popping up. * tag 'omap-for-v4.7/auxdata-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP2+: Simplify auxdata by using the generic match of/platform: Allow secondary compatible match in of_dev_lookup commit e5e3dea890804134f65d51eb42963b8659908d40 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 28 15:28:55 2016 +0530 mfd: Add device-tree binding doc for PMIC MAX77620/MAX20024 The MAXIM PMIC MAX77620 and MAX20024 are power management IC which supports RTC, GPIO, DCDC/LDO regulators, interrupt, watchdog etc. Add DT binding document for the different functionality of this device. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Documentation/devicetree/bindings/mfd/max77620.txt | 143 +++++++++++++++++++++ include/dt-bindings/mfd/max77620.h | 39 ++++++ 2 files changed, 182 insertions(+) commit 327156c593600e0f08575621c2a56f311d482e7a Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 28 15:28:56 2016 +0530 mfd: max77620: Add core driver for MAX77620/MAX20024 MAX77620/MAX20024 are Power Management IC from the MAXIM. It supports RTC, multiple GPIOs, multiple DCDC and LDOs, watchdog, clock etc. Add MFD drier to provides common support for accessing the device; additional drivers is developed on respected subsystem in order to use the functionality of the device. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mallikarjun Kasoju <mkasoju@nvidia.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/Kconfig | 15 ++ drivers/mfd/Makefile | 1 + drivers/mfd/max77620.c | 590 +++++++++++++++++++++++++++++++++++++++++++ include/linux/mfd/max77620.h | 346 +++++++++++++++++++++++++ 4 files changed, 952 insertions(+) commit 37ac9c9029905b5b3a3e4526fdcde1892d8f5501 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon May 2 10:27:37 2016 +0100 mfd: arizona: Add defines for GPSW values that can be used from DT Add defines for the possible values the GPSW can be set to using the wlf,gpsw device tree binding. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> include/dt-bindings/mfd/arizona.h | 5 +++++ 1 file changed, 5 insertions(+) commit b49b927f16acee626c56a1af4ab4cb062f75b5df Author: Roger Quadros <rogerq@ti.com> Date: Mon May 9 11:28:37 2016 +0300 mfd: omap-usb-tll: Fix scheduling while atomic BUG We shouldn't be calling clk_prepare_enable()/clk_prepare_disable() in an atomic context. Fixes the following issue: [ 5.830970] ehci-omap: OMAP-EHCI Host Controller driver [ 5.830974] driver_register 'ehci-omap' [ 5.895849] driver_register 'wl1271_sdio' [ 5.896870] BUG: scheduling while atomic: udevd/994/0x00000002 [ 5.896876] 4 locks held by udevd/994: [ 5.896904] #0: (&dev->mutex){......}, at: [<c049597c>] __driver_attach+0x60/0xac [ 5.896923] #1: (&dev->mutex){......}, at: [<c049598c>] __driver_attach+0x70/0xac [ 5.896946] #2: (tll_lock){+.+...}, at: [<c04c2630>] omap_tll_enable+0x2c/0xd0 [ 5.896966] #3: (prepare_lock){+.+...}, at: [<c05ce9c8>] clk_prepare_lock+0x48/0xe0 [ 5.897042] Modules linked in: wlcore_sdio(+) ehci_omap(+) dwc3_omap snd_soc_ts3a225e leds_is31fl319x bq27xxx_battery_i2c tsc2007 bq27xxx_battery bq2429x_charger ina2xx tca8418_keypad as5013 leds_tca6507 twl6040_vibra gpio_twl6040 bmp085_i2c(+) palmas_gpadc usb3503 palmas_pwrbutton bmg160_i2c(+) bmp085 bma150(+) bmg160_core bmp280 input_polldev snd_soc_omap_mcbsp snd_soc_omap_mcpdm snd_soc_omap snd_pcm_dmaengine [ 5.897048] Preemption disabled at:[< (null)>] (null) [ 5.897051] [ 5.897059] CPU: 0 PID: 994 Comm: udevd Not tainted 4.6.0-rc5-letux+ #233 [ 5.897062] Hardware name: Generic OMAP5 (Flattened Device Tree) [ 5.897076] [<c010e714>] (unwind_backtrace) from [<c010af34>] (show_stack+0x10/0x14) [ 5.897087] [<c010af34>] (show_stack) from [<c040aa7c>] (dump_stack+0x88/0xc0) [ 5.897099] [<c040aa7c>] (dump_stack) from [<c020c558>] (__schedule_bug+0xac/0xd0) [ 5.897111] [<c020c558>] (__schedule_bug) from [<c06f3d44>] (__schedule+0x88/0x7e4) [ 5.897120] [<c06f3d44>] (__schedule) from [<c06f46d8>] (schedule+0x9c/0xc0) [ 5.897129] [<c06f46d8>] (schedule) from [<c06f4904>] (schedule_preempt_disabled+0x14/0x20) [ 5.897140] [<c06f4904>] (schedule_preempt_disabled) from [<c06f64e4>] (mutex_lock_nested+0x258/0x43c) [ 5.897150] [<c06f64e4>] (mutex_lock_nested) from [<c05ce9c8>] (clk_prepare_lock+0x48/0xe0) [ 5.897160] [<c05ce9c8>] (clk_prepare_lock) from [<c05d0e7c>] (clk_prepare+0x10/0x28) [ 5.897169] [<c05d0e7c>] (clk_prepare) from [<c04c2668>] (omap_tll_enable+0x64/0xd0) [ 5.897180] [<c04c2668>] (omap_tll_enable) from [<c04c1728>] (usbhs_runtime_resume+0x18/0x17c) [ 5.897192] [<c04c1728>] (usbhs_runtime_resume) from [<c049d404>] (pm_generic_runtime_resume+0x2c/0x40) [ 5.897202] [<c049d404>] (pm_generic_runtime_resume) from [<c049f180>] (__rpm_callback+0x38/0x68) [ 5.897210] [<c049f180>] (__rpm_callback) from [<c049f220>] (rpm_callback+0x70/0x88) [ 5.897218] [<c049f220>] (rpm_callback) from [<c04a0a00>] (rpm_resume+0x4ec/0x7ec) [ 5.897227] [<c04a0a00>] (rpm_resume) from [<c04a0f48>] (__pm_runtime_resume+0x4c/0x64) [ 5.897236] [<c04a0f48>] (__pm_runtime_resume) from [<c04958dc>] (driver_probe_device+0x30/0x70) [ 5.897246] [<c04958dc>] (driver_probe_device) from [<c04959a4>] (__driver_attach+0x88/0xac) [ 5.897256] [<c04959a4>] (__driver_attach) from [<c04940f8>] (bus_for_each_dev+0x50/0x84) [ 5.897267] [<c04940f8>] (bus_for_each_dev) from [<c0494e40>] (bus_add_driver+0xcc/0x1e4) [ 5.897276] [<c0494e40>] (bus_add_driver) from [<c0496914>] (driver_register+0xac/0xf4) [ 5.897286] [<c0496914>] (driver_register) from [<c01018e0>] (do_one_initcall+0x100/0x1b8) [ 5.897296] [<c01018e0>] (do_one_initcall) from [<c01c7a54>] (do_init_module+0x58/0x1c0) [ 5.897304] [<c01c7a54>] (do_init_module) from [<c01c8a3c>] (SyS_finit_module+0x88/0x90) [ 5.897313] [<c01c8a3c>] (SyS_finit_module) from [<c0107120>] (ret_fast_syscall+0x0/0x1c) [ 5.912697] ------------[ cut here ]------------ [ 5.912711] WARNING: CPU: 0 PID: 994 at kernel/sched/core.c:2996 _raw_spin_unlock+0x28/0x58 [ 5.912717] DEBUG_LOCKS_WARN_ON(val > preempt_count()) Cc: <stable@vger.kernel.org> Reported-by: H. Nikolaus Schaller <hns@goldelico.com> Tested-by: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/omap-usb-tll.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) commit 409b6246cd1c564ea377d5cbe8c6fd184e96119e Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Tue Apr 26 17:06:19 2016 +0100 mfd: wm5110: ARIZONA_CLOCK_CONTROL should be volatile Some of the bits in this register can be changed by the codec so we must mark it volatile. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/wm5110-tables.c | 1 + 1 file changed, 1 insertion(+) commit cd7cf27b8f49505e7419b48e8b51962663819922 Author: Michael Haas <haas@computerlinguist.org> Date: Fri May 6 07:19:49 2016 +0200 mfd: axp20x: Add a cell for the ac power_supply part of the axp20x PMICs As a counterpart to the usb power_supply cell, this commit adds an AC power_supply cell to the axp20x driver. Still missing are the RTC backup battery and the main battery charger cells. Signed-off-by: Michael Haas <haas@computerlinguist.org> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/axp20x.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 11c3aead82879448943a1d1795b9d2e52a7bb669 Merge: ea46a1f 10c1f7d Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:39:14 2016 +0200 Merge tag 'omap-for-v4.7/legacy-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/fixes-non-critical Merge "omap legacy boot vs dt boot fixes for v4.7 merge window" from Tony Lindgren: Legacy booting vs device tree booting fixes for omaps for v4.7 merge window. These are not considered urgent fixes enough for the v4.6-rc cycle, but we need them in v4.7 in order to drop the last remaining board-*.c files for omap3 for v4.8 merge window. On Nokia N900, we need to pass the MMC slot names for the legacy user space to work. Let's do that using auxdata as the driver is setting up things already with the pdata for legacy booting. Then we can later on discuss if we may want to have some generic binding describing where the MMC slots are on the device. N900 also has had the ir-rx51 device driver unusable with multiarch for a long time. Let's pass the dmtimer data in pdata for the driver to get it going again. Then once things are working, we can eventually change the driver to use just hrtimer and PWM framework. The driver changes will be queued separately. * tag 'omap-for-v4.7/legacy-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP2+: n900 needs MMC slot names for legacy user space ARM: OMAP2+: Add more functions to pwm pdata for ir-rx51 commit 3dbe345885115513ec2f97db0e49f0873f8392ef Author: Borislav Petkov <bp@suse.de> Date: Thu May 5 10:18:23 2016 +0200 x86/kvm: Do not use BIT() in user-exported header Apparently, we're not exporting BIT() to userspace. Reported-by: Brooks Moses <bmoses@google.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/include/uapi/asm/kvm.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit ea46a1f8d328331db949586145644c17a4f975d4 Merge: bf16200 330d127 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:38:04 2016 +0200 Merge tag 'samsung-fixes-non-critical-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/fixes-non-critical Merge "Samsung DTS non-critical fixes for v4.7": 1. Fix s5p-mfc driver probe on Exynos542x Peach boards (need to provide MFC memory banks). On these boards this was broken for long time but apparently no one enabled this driver till now. 2. Fix creation of debugfs entries for one regulator on Exynos4210 Trats board. 3. Fix probing of max8997 MFD driver (and its children) because of missing interrupt. Actually the current version of the driver probes (just without interrupts) but after switching to regmap and regmap-irq, the interrupt will be mandatory. * tag 'samsung-fixes-non-critical-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: exynos: Add interrupt line to MAX8997 PMIC on exynos4210-trats ARM: dts: exynos: Fix regulator name to avoid forbidden character on exynos4210-trats ARM: dts: exynos: Add MFC memory banks for Peach boards ARM: EXYNOS: Properly skip unitialized parent clock in power domain on commit 5420f9fd159761b88978c312c3b350546f8615bb Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Thu Apr 28 16:05:01 2016 +0100 arm-ccn: Enable building as module arm-ccn driver uses irq_set_affinity, which is not exported and hence cannot be built as a module, eventhough we have all the bits ready. This patch makes use of the exported helper irq_set_affinity_hint() instead. Also, the __free_irq expects the affinity_hint to be NULL when we free the irq. So set the affinity_hint to NULL at clean up. Now that we can build it as a module, update the Kconfig to reflect the change. Cc: Will Deacon <will.deacon@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Acked-by: Pawel Moll <pawel.moll@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/bus/Kconfig | 2 +- drivers/bus/arm-ccn.c | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) commit 1644de03cbc05b70d0283c570b75fe9339b375b7 Merge: 182e084 4113652 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:32:29 2016 +0200 Merge tag 'reset-for-4.7-2' of git://git.pengutronix.de/git/pza/linux into next/drivers Merge "Reset controller changes for v4.7" from Philipp Zabel: - add missing stub for device_reset - add support for OXNAS SoCs * tag 'reset-for-4.7-2' of git://git.pengutronix.de/git/pza/linux: reset: Add missing function stub for device_reset dt-bindings: Add Oxford Semiconductor Reset Controller bindings reset: Add Oxford Semiconductor Reset Controller driver commit b54891be1a7785de7ec0e5c1fc9ba597713d22a8 Merge: abb2c53 d867864 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:31:16 2016 +0200 Merge tag 'v4.6-next-kconfig' of https://github.com/mbgg/linux-mediatek into next/soc Merge "ARM: mediatek: kconfig updates for v4.7" from Matthias Brugger: Add mt2701 support * tag 'v4.6-next-kconfig' of https://github.com/mbgg/linux-mediatek: ARM: mediatek: Add MT2701 config options for mediatek SoCs. commit 182e0842b0109aa934f1fe76b96d3a79efec3912 Merge: b7dcc6d 601bac7 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:29:36 2016 +0200 Merge tag 'v4.6-next-soc' of https://github.com/mbgg/linux-mediatek into next/drivers Merge "ARM: mediatek soc updates for v4.7" from Matthias Brugger: - re-organize pmic wrapper code for easier and cleaner addiont of new SoCs and pmic wrappers - add support for pmic wrapper mt6323 - add support for SoC mt2701 - enable gpt6 arch timer on mt7623 * tag 'v4.6-next-soc' of https://github.com/mbgg/linux-mediatek: ARM: mediatek: enable gpt6 on boot up to make arch timer work on mt7623 soc: mediatek: PMIC wrap: add MT2701/7623 support soc: mediatek: PMIC wrap: add mt6323 slave support soc: mediatek: PMIC wrap: add a slave specific struct soc: mediatek: PMIC wrap: remove pwrap_is_mt8135() and pwrap_is_mt8173() soc: mediatek: PMIC wrap: move wdt_src into the pmic_wrapper_type struct soc: mediatek: PMIC wrap: SPI_WRITE needs a different bitmask for MT2701/7623 soc: mediatek: PMIC wrap: WRAP_INT_EN needs a different bitmask for MT2701/7623 soc: mediatek: PMIC wrap: split SoC specific init into callback soc: mediatek: PMIC wrap: add wrapper callbacks for init_reg_clock soc: mediatek: PMIC wrap: don't duplicate the wrapper data commit b7dcc6d01ffcaab262d52af0b91110463ee045f5 Merge: 2f0e234 a380451 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:28:46 2016 +0200 Merge tag 'tegra-for-4.7-genpd' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers Merge "soc/tegra: Add generic PM domain support" from Thierry Reding: Implements generic PM domain support on top of the existing Tegra power- gate API. Drivers are thus allowed to move away from the Tegra-specific API and towards using generic power domains directly. * tag 'tegra-for-4.7-genpd' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: soc/tegra: pmc: Add generic PM domain support dt-bindings: Add power domain info for NVIDIA PMC commit 0683e598a1341029141b7dbb9d1bd362612ffaae Merge: 43419b0 1333ce4 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:26:08 2016 +0200 Merge tag 'tegra-for-4.7-xusb-no-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/late Merge "ARM: tegra: Enable the XUSB controller" from Thierry Reding: These changes add support for the XUSB controller on Tegra124. It is an XHCI compatible controller that replaces the existing EHCI controllers. Support is enabled on Venice2, Jetson TK1 and Nyan-based Chromebooks. * tag 'tegra-for-4.7-xusb-no-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: ARM: tegra: Enable XUSB on Nyan ARM: tegra: Enable XUSB on Jetson TK1 ARM: tegra: Enable XUSB on Venice2 ARM: tegra: Add Tegra124 XUSB controller ARM: tegra: Move Tegra124 to the new XUSB pad controller binding commit 43419b0939b8d8c5d4942a7ebaebd8d483a2cc14 Merge: 783fb3c 6fe7c18 ab065e9 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:25:12 2016 +0200 Merge branches 'tegra/pci' and 'tegra/usb' into next/late This is a prerequisite for enabling the Tegra XUSB, all the branches should be merged already at the time we get here. * tegra/pci: PCI: tegra: Support per-lane PHYs dt-bindings: pci: tegra: Update for per-lane PHYs phy: tegra: Add Tegra210 support phy: Add Tegra XUSB pad controller support dt-bindings: phy: tegra-xusb-padctl: Add Tegra210 support dt-bindings: phy: Add NVIDIA Tegra XUSB pad controller binding phy: core: Allow children node to be overridden clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs * tegra/usb: usb: xhci: tegra: Add Tegra210 support usb: xhci: Add NVIDIA Tegra XUSB controller driver dt-bindings: usb: xhci-tegra: Add Tegra210 XUSB controller support dt-bindings: usb: Add NVIDIA Tegra XUSB controller binding phy: tegra: Add Tegra210 support phy: Add Tegra XUSB pad controller support dt-bindings: phy: tegra-xusb-padctl: Add Tegra210 support dt-bindings: phy: Add NVIDIA Tegra XUSB pad controller binding phy: core: Allow children node to be overridden clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs commit 2f0e234039339784ac9b3035d13e2e125844d69d Merge: 675de1d ab065e9 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:23:47 2016 +0200 Merge tag 'tegra-for-4.7-xhci' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers Merge "usb: host: xhci-tegra: Changes for v4.7-rc1" from Thierry Reding: This set of patches introduces a driver for the XUSB controller found on NVIDIA Tegra SoCs. When loaded with a firmware (available via the linux- firmware repository), it provides an XHCI-compatible interface. * tag 'tegra-for-4.7-xhci' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: usb: xhci: tegra: Add Tegra210 support usb: xhci: Add NVIDIA Tegra XUSB controller driver dt-bindings: usb: xhci-tegra: Add Tegra210 XUSB controller support dt-bindings: usb: Add NVIDIA Tegra XUSB controller binding commit 675de1d5145bc5e6ef436f2eac00a08516e38e62 Merge: 4ace926 6fe7c18 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:20:35 2016 +0200 Merge tag 'tegra-for-4.7-pci' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers Merge "PCI: tegra: Changes for v4.7-rc1" from Thierry Reding: These patches update the Tegra PCIe host bridge controller device tree bindings and driver to cope with per-lane PHYs on Tegra124 and later. * tag 'tegra-for-4.7-pci' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: PCI: tegra: Support per-lane PHYs dt-bindings: pci: tegra: Update for per-lane PHYs commit 4ace926172a7d93182381a3c7a2d05acb2dd91a4 Merge: f0653f6 87d66f2 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:18:37 2016 +0200 Merge tag 'tegra-for-4.7-phy' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers Merge "phy: tegra: Changes for v4.7-rc1" from Thierry Reding: This set of patches adds support for the Tegra XUSB pad controller. The controller provides a set of pads (lanes) that are used for I/O by other IP blocks within Tegra SoCs (PCIe, SATA and XUSB). * tag 'tegra-for-4.7-phy' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: phy: tegra: Add Tegra210 support phy: Add Tegra XUSB pad controller support dt-bindings: phy: tegra-xusb-padctl: Add Tegra210 support dt-bindings: phy: Add NVIDIA Tegra XUSB pad controller binding phy: core: Allow children node to be overridden clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs commit f0653f6768ee9d66e25b2476facb74c9c2d88118 Merge: 036dae8 074c6a4 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:17:16 2016 +0200 Merge tag 'v4.7-rockchip-drivers-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/drivers Merge "Rockchip driver updates for v4.7 - part2" from Heiko Stübner: Ability to save and restore the power-domain quality of service settings that get lost and reset on power-domain power cycles. * tag 'v4.7-rockchip-drivers-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: soc: rockchip: power-domain: support qos save and restore dt-bindings: modify document of Rockchip power domains commit abb2c53a5536019f3af9917d00e5a9be6853e1f6 Merge: 6683d91 8c2ed9b Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:13:53 2016 +0200 Merge tag 'aspeed-for-4.7-arch' of https://github.com/shenki/linux into next/soc Merge "aspeed arch tag for 4.7" from Joel Stanley <joel@jms.id.au>: This is the initial pull request for the Aspeed BMC SoCs. I put 4.7 in the subject for this and the subsequent requests but if it's a bit late in the cycle then I understand. Following review I got rid of the board file by pushing the functionality out to a watchdog and clock driver, so it's just the Kconfig bits. I've also added myself to maintainers for the Aspeed arch and drivers as I intend on looking after them. * tag 'aspeed-for-4.7-arch' of https://github.com/shenki/linux: arm: Add Aspeed machine commit 6683d91cde25e6e915c47eca53789193f078a6e6 Author: Kevin Hilman <khilman@baylibre.com> Date: Fri May 6 06:59:26 2016 -0700 MAINTAINERS: ARM/Amlogic: add co-maintainer, misc. updates Add myself as co-maintainer, update mailing list entry and add a couple more directories. Signed-off-by: Kevin Hilman <khilman@baylibre.com> Acked-by: Carlo Caione <carlo@caione.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> MAINTAINERS | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 2a73e08d1ad38bda19196ccf8ed9da8198489423 Merge: 121711b 42c031d Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:09:24 2016 +0200 Merge tag 'davinci-for-v4.7/doc' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/soc Merge "DaVinci documentation update for v4.7" from Sekhar Nori: MAINTAINERS file update to fix some stale entries. * tag 'davinci-for-v4.7/doc' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: MAINTAINERS: fix stale TI DaVinci entries commit 121711bbe43044ce824922ede472c16540bfbffb Merge: 8946bdf acc9800 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:08:46 2016 +0200 Merge tag 'imx-soc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/soc Merge "The i.MX SoC updates for 4.7" from Shawn Guo": - Allow TWD to be used on UP kernel, as the PREEMPT-RT and cyclictest shows that TWD has a slightly better performance than i.MX timer. * tag 'imx-soc-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: ARM: imx: always use TWD on IMX6Q commit 7e5385dc722258c862f969ab7e67907156ad0e3f Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Mar 15 17:34:56 2016 +0100 clk: rockchip: drop old_rate calculation on pll rate changes Previously when everything happened in the set_rate callbacks itself we needed the old_rate value for the possible rate rollback, so that made it easy to also use it in the debug output. Now with the param-handling being done in separate functions, reading and recalculating the current pll rate only to use it in a debug message that won't get displayed in regular cases anyway is quite a waste. Therefore drop that value from the debug output. In the worst case that previous rate will have been displayed on the rate change before. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-pll.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) commit c9c3c6eecc5533d14bb9bc82319257eb8bc52768 Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Mar 15 16:55:41 2016 +0100 clk: rockchip: simplify GRF handling in pll clocks With the previous commit, the clock drivers now know at init time if the GRF regmap is available. That means if it isn't available then, it also won't become available later and we can therefore switch PLLs, that need the GRF for the lock-status, to read-only mode - similar behaviour as the aborting of rate changes we did before. This saves some conditionals on every rate change and we can also drop the rockchip_clk_get_grf function completely. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-pll.c | 30 +++--------------------------- drivers/clk/rockchip/clk.c | 5 ----- drivers/clk/rockchip/clk.h | 1 - 3 files changed, 3 insertions(+), 33 deletions(-) commit 6f339dc2719eb01448c70fe3d56287d1eb9bd67e Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Mar 15 16:40:32 2016 +0100 clk: rockchip: lookup General Register Files in rockchip_clk_init In the distant past syscons were initialized pretty late and weren't available at the time the clock init ran. As the GRF is mainly needed for PLL lock-status checking, we had this lazy init that tried to grab the syscon on PLL rate changes and denied these changes if it was not available. These days syscons are available very early and recent addition to rockchip clocks, like the PLL clk_init actually also rely on them being available at that time, so there is no need to keep that lazy init around, as it will also result in some more simplifications in other parts of the clock-code. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8946bdf7c746c220d1ceb68eb6d2f9e7770d677c Merge: eb07e08 3a1a455 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 16:00:18 2016 +0200 Merge tag 'mvebu-soc-4.7-1' of git://git.infradead.org/linux-mvebu into next/soc Merge "mvebu soc for 4.7" from Gregory CLEMENT: - Clock framework cleanup with the "Remove CLK_IS_ROOT" series * tag 'mvebu-soc-4.7-1' of git://git.infradead.org/linux-mvebu: ARM: dove: Remove CLK_IS_ROOT ARM: orion5x: Remove CLK_IS_ROOT ARM: mv78xx0: Remove CLK_IS_ROOT commit d87de8f38a6739ad180923dbefd3e08e087a8f51 Merge: da43af9 bf7cdff Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon May 9 16:00:10 2016 +0200 Merge branch 'pm-cpufreq-sched' into pm-cpufreq commit eb07e08d54621a2e7bd48a4962b2a786c82a713a Merge: b65b98d 3f2a09d Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 15:57:27 2016 +0200 Merge tag 'davinci-for-v4.7/soc-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/soc Merge "DaVinci SoC updates for v4.7 (part 2)" from Sekhar Nori: These patches provide ability to add non-PSC clocks to DaVinci clock framwork and are required to support USB PHY clock setting from USB PHY driver. * tag 'davinci-for-v4.7/soc-part2' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: davinci: da850: use clk->set_parent for async3 ARM: davinci: Move clock init after ioremap. commit b65b98d9ac27a97a715b076ead50e408026bfbf4 Merge: 2377f9f 71d42e9 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 15:41:24 2016 +0200 Merge tag 'lpc32xx-soc-4.7' of git://github.com/vzapolskiy/linux-lpc32xx into next/soc Merge "NXP LPC32xx mach updates for v4.7" from Vladimir Zapolskiy: This includes a few nonfunctional clean-ups for NXP LPC32xx: * removed leftover from restart code migration to a watchdog driver * removed dead code leftovers from migration to CCF driver * fix double const qualifier * tag 'lpc32xx-soc-4.7' of git://github.com/vzapolskiy/linux-lpc32xx: ARM: lpc32xx: remove duplicate const on lpc32xx_auxdata_lookup ARM: lpc32xx: remove leftovers of legacy clock source and provider drivers ARM: lpc32xx: remove reboot header file commit 783fb3c393b17237aa504c6a5f9b2f5bce3d7a28 Merge: 1cf257a 38dbb45 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 9 15:39:00 2016 +0200 Merge tag 'renesas-arm64-dt-pm-domain-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/late Merge "Renesas ARM64 Based SoC DT PM Domain Updates for v4.7" from Simon Horman: * Add SYSC PM Domains to DT of r8a7795 SoC * tag 'renesas-arm64-dt-pm-domain-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: arm64: dts: r8a7795: Use SYSC "always-on" PM Domain arm64: dts: r8a7795: Add SYSC PM Domains arm64: dts: r8a7795: Don't disable referenced optional clocks arm64: dts: salvator-x: populate EXTALR arm64: dts: r8a7795: enable PCIe on Salvator-X arm64: dts: r8a7795: Add PCIe nodes arm64: dts: r8a7795: Use USB3.0 fallback compatibility string arm64: dts: r8a7795: Add CAN support arm64: dts: r8a7795: Add CAN external clock support commit 2377f9fdac3086c6bb167c83f05ad91fb66d8e9d Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 02:55:19 2016 +0300 MAINTAINERS: add ARM/NXP LPC32XX SoC specific drivers to the section The change adds a list of files for maintenance under NXP LPC32xx section, the listed files are NXP LPC32xx SoC series mach files, DTS files of NXP LPC32xx SoC powered boards and NXP LPC32xx SoC peripheral drivers, most of the peripheral driver file names match 'lpc32xx' pattern. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> MAINTAINERS | 6 ++++++ 1 file changed, 6 insertions(+) commit 8d5a6b42ff1124b8efa0f472ce6bcaf16065bdc4 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 02:55:18 2016 +0300 MAINTAINERS: add new maintainers of NXP LPC32xx SoC Roland Stigge added initial support of NXP LPC32xx SoC series and first boards powered by it, but for a while since v3.18-rc1 the SoC support is unmaintained and became stale. Vladimir Zapolskiy and Sylvain Lemieux expressed interest in continuation of NXP LPC32xx maintenance, reflect this in MAINTAINERS record file for better communication with Linux kernel community. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> MAINTAINERS | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 15e4f7daf33166106a2163ebb4dde265eb3145fe Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 02:55:17 2016 +0300 MAINTAINERS: move ARM/NXP LPC32xx record to ARM section A record of NXP LPC32xx SoC support is lost between LMxx hwmon drivers and lockdep, rename and move it to a place where all other ARM SoC and machines settle. Note, NXP LPC32xx maintenance is actually about SoC series itself, SoC peripherals and a number of machines powered by LPC32xx SoC, so while we are here correct the title name to emphasize that the maintenance concerns SoC support in general. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> MAINTAINERS | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 3b6b7e19e31a816ee02a8d4372cbea9ad7db3784 Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 17:29:10 2016 +0100 iommu/dma: Finish optimising higher-order allocations Now that we know exactly which page sizes our caller wants to use in the given domain, we can restrict higher-order allocation attempts to just those sizes, if any, and avoid wasting any time or effort on other sizes which offer no benefit. In the same vein, this also lets us accommodate a minimum order greater than 0 for special cases. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Acked-by: Will Deacon <will.deacon@arm.com> Tested-by: Yong Wu <yong.wu@mediatek.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> arch/arm64/mm/dma-mapping.c | 4 +-- drivers/iommu/dma-iommu.c | 60 +++++++++++++++++++++++++++++---------------- include/linux/dma-iommu.h | 4 +-- 3 files changed, 43 insertions(+), 25 deletions(-) commit d16e0faab911cc0e100a1e8e93635b432566608e Author: Robin Murphy <robin.murphy@arm.com> Date: Thu Apr 7 18:42:06 2016 +0100 iommu: Allow selecting page sizes per domain Many IOMMUs support multiple page table formats, meaning that any given domain may only support a subset of the hardware page sizes presented in iommu_ops->pgsize_bitmap. There are also certain use-cases where the creator of a domain may want to control which page sizes are used, for example to force the use of hugepage mappings to reduce pagetable walk depth. To this end, add a per-domain pgsize_bitmap to represent the subset of page sizes actually in use, to make it possible for domains with different requirements to coexist. Signed-off-by: Will Deacon <will.deacon@arm.com> [rm: hijacked and rebased original patch with new commit message] Signed-off-by: Robin Murphy <robin.murphy@arm.com> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/dma-iommu.c | 2 +- drivers/iommu/iommu.c | 22 ++++++++++++---------- drivers/iommu/mtk_iommu.c | 2 +- drivers/vfio/vfio_iommu_type1.c | 2 +- include/linux/iommu.h | 3 ++- 5 files changed, 17 insertions(+), 14 deletions(-) commit 53c92d793395fdab9edbd2f79b084bb6b2e6ae79 Author: Robin Murphy <Robin.Murphy@arm.com> Date: Thu Apr 7 18:42:05 2016 +0100 iommu: of: enforce const-ness of struct iommu_ops As a set of driver-provided callbacks and static data, there is no compelling reason for struct iommu_ops to be mutable in core code, so enforce const-ness throughout. Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> arch/arm/include/asm/dma-mapping.h | 2 +- arch/arm/mm/dma-mapping.c | 6 +++--- arch/arm64/include/asm/dma-mapping.h | 2 +- arch/arm64/mm/dma-mapping.c | 4 ++-- drivers/iommu/of_iommu.c | 14 +++++++------- drivers/of/device.c | 2 +- include/linux/dma-mapping.h | 2 +- include/linux/of_iommu.h | 8 ++++---- 8 files changed, 20 insertions(+), 20 deletions(-) commit 3c3e8943ac6f36ca5d18ca61b30634fb560b4ebb Author: Will Deacon <will.deacon@arm.com> Date: Thu Apr 7 18:42:04 2016 +0100 iommu: remove unused priv field from struct iommu_ops The priv field from iommu_ops is a hangover from the of_dma_configure series and isn't actually used. Remove it before it has chance to spread. Signed-off-by: Will Deacon <will.deacon@arm.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> include/linux/iommu.h | 2 -- 1 file changed, 2 deletions(-) commit 9a51f3fc77f52b0ebdca5797bbbdb8e043037807 Merge: 809eac5 8801561 Author: Joerg Roedel <jroedel@suse.de> Date: Mon May 9 15:33:17 2016 +0200 Merge branch 'arm/smmu' into core commit 0c95c1d6197f3edd3f6ef76f927d67e8ec0794ed Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 21:12:46 2016 +0900 ALSA: firewire-lib: add tracepoints to dump a part of isochronous packet data When audio and music units have some quirks in their sequence of packet, it's really hard for non-owners to identify the quirks. Although developers need dumps for sequence of packets, it's difficult for users who have no knowledges and no equipments for this purpose. This commit adds tracepoints for this situation. When users encounter the issue, they can dump a part of packet data via Linux tracing framework as long as using drivers in ALSA firewire stack. Additionally, tracepoints for outgoing packets will be our help to check and debug packet processing of ALSA firewire stack. This commit newly adds 'snd_firewire_lib' subsystem with 'in_packet' and 'out_packet' events. In the events, some attributes of packets and the index of packet managed by this module are recorded per packet. This is an usage: $ trace-cmd record -e snd_firewire_lib:out_packet \ -e snd_firewire_lib:in_packet /sys/kernel/tracing/events/snd_firewire_lib/out_packet/filter /sys/kernel/tracing/events/snd_firewire_lib/in_packet/filter Hit Ctrl^C to stop recording ^C $ trace-cmd report trace.dat ... 23647.033934: in_packet: 01 4073 ffc0 ffc1 00 000f0040 9001b2d1 122 44 23647.033936: in_packet: 01 4074 ffc0 ffc1 00 000f0048 9001c83b 122 45 23647.033937: in_packet: 01 4075 ffc0 ffc1 00 000f0050 9001ffff 002 46 23647.033938: in_packet: 01 4076 ffc0 ffc1 00 000f0050 9001e1a6 122 47 23647.035426: out_packet: 01 4123 ffc1 ffc0 01 010f00d0 9001fb40 122 17 23647.035428: out_packet: 01 4124 ffc1 ffc0 01 010f00d8 9001ffff 002 18 23647.035429: out_packet: 01 4125 ffc1 ffc0 01 010f00d8 900114aa 122 19 23647.035430: out_packet: 01 4126 ffc1 ffc0 01 010f00e0 90012a15 122 20 (Here, some common fields are omitted so that a line to be within 80 characters.) ... One line represent one packet. The legend for the last nine fields is: - The second of cycle scheduled for the packet - The count of cycle scheduled for the packet - The ID of node as source (hex) - Some devices transfer packets with invalid source node ID in their CIP header. - The ID of node as destination (hex) - The value is not in CIP header of packets. - The value of isochronous channel - The first quadlet of CIP header (hex) - The second quadlet of CIP header (hex) - The number of included quadlets - The index of packet in a buffer maintained by this module This is an example to parse these lines from text file by Python3 script: \#!/usr/bin/env python3 import sys def parse_ts(second, cycle, syt): offset = syt & 0xfff syt >>= 12 if cycle & 0x0f > syt: cycle += 0x10 cycle &= 0x1ff0 cycle |= syt second += cycle // 8000 cycle %= 8000 # In CYCLE_TIMER of 1394 OHCI, second is represented in 8 bit. second %= 128 return (second, cycle, offset) def calc_ts(second, cycle, offset): ts = offset ts += cycle * 3072 # In DMA descriptor of 1394 OHCI, second is represented in 3 bit. ts += (second % 8) * 8000 * 3072 return ts def subtract_ts(minuend, subtrahend): # In DMA descriptor of 1394 OHCI, second is represented in 3 bit. if minuend < subtrahend: minuend += 8 * 8000 * 3072 return minuend - subtrahend if len(sys.argv) != 2: print('At least, one argument is required for packet dump.') sys.exit() filename = sys.argv[1] data = [] prev = 0 with open(filename, 'r') as f: for line in f: pos = line.find('packet:') if pos < 0: continue pos += len('packet:') line = line[pos:].strip() fields = line.split(' ') datum = [] datum.append(fields[8]) syt = int(fields[6][4:], 16) # Empty packet in IEC 61883-1, or NODATA in IEC 61883-6 if syt == 0xffff: data_blocks = 0 else: payload_size = int(fields[7], 10) data_block_size = int(fields[5][2:4], 16) data_blocks = (payload_size - 2) / data_block_size datum.append(data_blocks) second = int(fields[0], 10) cycle = int(fields[1], 10) start = (second << 25) | (cycle << 12) datum.append('0x{0:08x}'.format(start)) start = calc_ts(second, cycle, 0) datum.append("0x" + fields[5]) datum.append("0x" + fields[6]) if syt == 0xffff: second = 0 cycle = 0 tick = 0 else: second, cycle, tick = parse_ts(second, cycle, syt) ts = calc_ts(second, cycle, tick) datum.append(start) datum.append(ts) if ts == 0: datum.append(0) datum.append(0) else: # Usual case, or a case over 8 seconds. if ts > start or start > 7 * 8000 * 3072: datum.append(subtract_ts(ts, start)) if ts > prev or start > 7 * 8000 * 3072: gap = subtract_ts(ts, prev) datum.append(gap) else: datum.append('backward') else: datum.append('invalid') prev = ts data.append(datum) sys.exit() The data variable includes array with these elements: - The index of the packet - The number of data blocks in the packet - The value of cycle count (hex) - The value of CIP header 1 (hex) - The value of CIP header 2 (hex) - The value of cycle count (tick) - The value of calculated presentation timestamp (tick) - The offset between the cycle count and presentation timestamp - The elapsed ticks from the previous presentation timestamp Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/Makefile | 3 ++ sound/firewire/amdtp-stream-trace.h | 98 +++++++++++++++++++++++++++++++++++++ sound/firewire/amdtp-stream.c | 21 +++++--- 3 files changed, 116 insertions(+), 6 deletions(-) commit f90e2dedf7f47ff4f2f757188a0360fbf526a81e Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 21:12:45 2016 +0900 ALSA: firewire-lib: compute the value of second field in cycle count for IR context In callback function of isochronous context, modules can queue packets to indicated isochronous cycles. Although the cycle to queue a packet is deterministic by calculation, this module doesn't implement the calculation because it's useless for processing. In future, the cycle count is going to be printed with the other parameters for debugging. This commit is the preparation. The cycle count is computed by cycle unit, and correctly arranged to corresponding packets. The calculated count is used in later commit. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 73fc7f080105b16d9f189c82d0092f22107cc67b Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Mon May 9 21:12:44 2016 +0900 ALSA: firewire-lib: compute the value of second field in cycle count for IT context In callback function of isochronous context, u32 variable is passed for cycle count. The value of this variable comes from DMA descriptors of 1394 Open Host Controller Interface (1394 OHCI). In the specification, DMA descriptors transport lower 3 bits for second field and full cycle field in 16 bits field, therefore 16 bits of the u32 variable are available. The value for second is modulo 8, and the value for cycle is modulo 8,000. Currently, ALSA firewire-lib module don't use the value of the second field, because the value is useless to calculate presentation timestamp in IEC 61883-6. However, the value may be useful for debugging. In later commit, it will be printed with the other parameters for debugging. This commit makes this module to handle the whole cycle count including second. The value is calculated by cycle unit. The existed code is already written with ignoring the value of second, thus this commit causes no issues. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 42 ++++++++++++++++++++++++++++++------------ 1 file changed, 30 insertions(+), 12 deletions(-) commit 7e3fcf61abde92a895533b1c6932ad17e073a49c Author: J. Bruce Fields <bfields@redhat.com> Date: Tue May 3 15:16:02 2016 -0400 nfs: don't share mounts between network namespaces There's no guarantee that an IP address in a different network namespace actually represents the same endpoint. Also, if we allow unprivileged nfs mounts some day then this might allow an unprivileged user in another network namespace to misdirect somebody else's nfs mounts. If sharing between containers is really what's wanted then that could still be arranged explicitly, for example with bind mounts. Reported-by: "Eric W. Biederman" <ebiederm@redhat.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/super.c | 5 +++++ 1 file changed, 5 insertions(+) commit 11476e9dec39d90fe1e9bf12abc6f3efe35a073d Author: Chuck Lever <chuck.lever@oracle.com> Date: Mon Apr 11 16:20:22 2016 -0400 NFS: Fix an LOCK/OPEN race when unlinking an open file At Connectathon 2016, we found that recent upstream Linux clients would occasionally send a LOCK operation with a zero stateid. This appeared to happen in close proximity to another thread returning a delegation before unlinking the same file while it remained open. Earlier, the client received a write delegation on this file and returned the open stateid. Now, as it is getting ready to unlink the file, it returns the write delegation. But there is still an open file descriptor on that file, so the client must OPEN the file again before it returns the delegation. Since commit 24311f884189 ('NFSv4: Recovery of recalled read delegations is broken'), nfs_open_delegation_recall() clears the NFS_DELEGATED_STATE flag _before_ it sends the OPEN. This allows a racing LOCK on the same inode to be put on the wire before the OPEN operation has returned a valid open stateid. To eliminate this race, serialize delegation return with the acquisition of a file lock on the same file. Adopt the same approach as is used in the unlock path. This patch also eliminates a similar race seen when sending a LOCK operation at the same time as returning a delegation on the same file. Fixes: 24311f884189 ('NFSv4: Recovery of recalled read ... ') Signed-off-by: Chuck Lever <chuck.lever@oracle.com> [Anna: Add sentence about LOCK / delegation race] Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/nfs4proc.c | 4 ++++ 1 file changed, 4 insertions(+) commit 3064b6861d00b7124558cdf79f9387f948361be3 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:52:00 2016 -0400 nfs: have flexfiles mirror keep creds for both ro and rw layouts A mirror can be shared between multiple layouts, even with different iomodes. That makes stats gathering simpler, but it causes a problem when we get different creds in READ vs. RW layouts. The current code drops the newer credentials onto the floor when this occurs. That's problematic when you fetch a READ layout first, and then a RW. If the READ layout doesn't have the correct creds to do a write, then writes will fail. We could just overwrite the READ credentials with the RW ones, but that would break the ability for the server to fence the layout for reads if things go awry. We need to be able to revert to the earlier READ creds if the RW layout is returned afterward. The simplest fix is to just keep two sets of creds per mirror. One for READ layouts and one for RW, and then use the appropriate set depending on the iomode of the layout segment. Also fix up some RCU nits that sparse found. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 30 +++++++++++++++++++++++------- fs/nfs/flexfilelayout/flexfilelayout.h | 3 ++- fs/nfs/flexfilelayout/flexfilelayoutdev.c | 7 +++++-- 3 files changed, 30 insertions(+), 10 deletions(-) commit 90a0be00e9d29d9baac27c0c63a5e71ca1334001 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:51:59 2016 -0400 nfs: get a reference to the credential in ff_layout_alloc_lseg We're just as likely to have allocation problems here as we would if we delay looking up the credential like we currently do. Fix the code to get a rpc_cred reference early, as soon as the mirror is set up. This allows us to eliminate the mirror early if there is a problem getting an rpc credential. This also allows us to drop the uid/gid from the layout_mirror struct as well. In the event that we find an existing mirror where this one would go, we swap in the new creds unconditionally, and drop the reference to the old one. Note that the old ff_layout_update_mirror_cred function wouldn't set this pointer unless the DS version was 3, but we don't know what the DS version is at this point. I'm a little unclear on why it did that as you still need creds to talk to v4 servers as well. I have the code set it regardless of the DS version here. Also note the change to using generic creds instead of calling lookup_cred directly. With that change, we also need to populate the group_info pointer in the acred as some functions expect that to never be NULL. Instead of allocating one every time however, we can allocate one when the module is loaded and share it since the group_info is refcounted. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 41 ++++++++++++++++++++++----- fs/nfs/flexfilelayout/flexfilelayout.h | 2 -- fs/nfs/flexfilelayout/flexfilelayoutdev.c | 47 ++----------------------------- 3 files changed, 36 insertions(+), 54 deletions(-) commit 57f3f4c0cd50e90aa92eec20d9c309dd67c594a5 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:51:58 2016 -0400 nfs: have ff_layout_get_ds_cred take a reference to the cred In later patches, we're going to want to allow the creds to be updated when we get a new layout with updated creds. Have this function take a reference to the cred that is later put once the call has been dispatched. Also, prepare for this change by ensuring we follow RCU rules when getting a reference to the cred as well. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayout.c | 15 +++++++++------ fs/nfs/flexfilelayout/flexfilelayoutdev.c | 30 ++++++++++++++++++++++++++---- 2 files changed, 35 insertions(+), 10 deletions(-) commit 547a637630c61b9e1dae9abce2b44ce7076244af Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:51:57 2016 -0400 nfs: don't call nfs4_ff_layout_prepare_ds from ff_layout_get_ds_cred All the callers already call that function before calling into here, so it ends up being a no-op anyway. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/flexfilelayout/flexfilelayoutdev.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 62dbef2ae41393eba2f6853ca174130f2d09c7d3 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:51:56 2016 -0400 sunrpc: add a get_rpccred_rcu inline Sometimes we might have a RCU managed credential pointer and don't want to use locking to handle it. Add a function that will take a reference to the cred iff the refcount is not already zero. Callers can dereference the pointer under the rcu_read_lock and use that function to take a reference only if the cred is not on its way to destruction. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/auth.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit c065d229e308ede426a3608cf480c61983b36fb8 Author: Weston Andros Adamson <dros@primarydata.com> Date: Thu Apr 21 20:51:55 2016 -0400 sunrpc: add rpc_lookup_generic_cred Add function rpc_lookup_generic_cred, which allows lookups of a generic credential that's not current_cred(). [jlayton: add gfp_t parm] Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/auth.h | 1 + net/sunrpc/auth_generic.c | 7 +++++++ 2 files changed, 8 insertions(+) commit 3c6e0bc8a14cfc8e1d4ab87f46f77b070c815bf1 Author: Jeff Layton <jlayton@poochiereds.net> Date: Thu Apr 21 20:51:54 2016 -0400 sunrpc: plumb gfp_t parm into crcreate operation We need to be able to call the generic_cred creator from different contexts. Add a gfp_t parm to the crcreate operation and to rpcauth_lookup_credcache. For now, we just push the gfp_t parms up one level to the *_lookup_cred functions. Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> include/linux/sunrpc/auth.h | 4 ++-- net/sunrpc/auth.c | 4 ++-- net/sunrpc/auth_generic.c | 6 +++--- net/sunrpc/auth_gss/auth_gss.c | 6 +++--- net/sunrpc/auth_unix.c | 6 +++--- 5 files changed, 13 insertions(+), 13 deletions(-) commit 06ef26a0e35199cc0445d7d5708533a12af8ff5b Author: Benjamin Coddington <bcodding@redhat.com> Date: Wed Apr 6 11:32:52 2016 -0400 SUNRPC: init xdr_stream for zero iov_len, page_len An xdr_buf with head[0].iov_len = 0 and page_len = 0 will cause xdr_init_decode() to incorrectly setup the xdr_stream. Specifically, xdr->end is never initialized. Signed-off-by: Benjamin Coddington <bcodding@redhat.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> net/sunrpc/xdr.c | 2 ++ 1 file changed, 2 insertions(+) commit fe238e601d2519f259103ab65caea3b077ed7b39 Author: Dave Wysochanski <dwysocha@redhat.com> Date: Fri Apr 1 13:45:09 2016 -0400 NFS: Save struct inode * inside nfs_commit_info to clarify usage of i_lock Commit ea2cf22 created nfs_commit_info and saved &inode->i_lock inside this NFS specific structure. This obscures the usage of i_lock. Instead, save struct inode * so later it's clear the spinlock taken is i_lock. Should be no functional change. Signed-off-by: Dave Wysochanski <dwysocha@redhat.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/direct.c | 10 +++++----- fs/nfs/filelayout/filelayout.c | 4 ++-- fs/nfs/flexfilelayout/flexfilelayout.c | 4 ++-- fs/nfs/pnfs_nfs.c | 32 ++++++++++++++++---------------- fs/nfs/write.c | 16 ++++++++-------- include/linux/nfs_xdr.h | 2 +- 6 files changed, 34 insertions(+), 34 deletions(-) commit ed3743a6d4f309f5278c87a69e3125382b78455c Author: Weston Andros Adamson <dros@primarydata.com> Date: Fri Apr 1 11:42:29 2016 -0400 nfs: add debug to directio "good_bytes" counting This will pop a warning if we count too many good bytes. Signed-off-by: Weston Andros Adamson <dros@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/direct.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 1b1bc66bb4ebd737fb750b0e1afc753098f4a1b2 Author: Weston Andros Adamson <dros@primarydata.com> Date: Fri Apr 1 11:42:28 2016 -0400 pnfs: set NFS_IOHDR_REDO in pnfs_read_resend_pnfs Like other resend paths, mark the (old) hdr as NFS_IOHDR_REDO. This ensures the hdr completion function will not count the (old) hdr as good bytes. Also, vector the error back through the hdr->task.tk_status like other retry calls. This fixes a bug with the FlexFiles layout where libaio was reporting more bytes read than requested. Signed-off-by: Weston Andros Adamson <dros@primarydata.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com> fs/nfs/pnfs.c | 14 ++++++++------ fs/nfs/pnfs.h | 2 +- 2 files changed, 9 insertions(+), 7 deletions(-) commit 36e6d081cfb2cb64e6d8e5121cffb1e62f894d36 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Apr 22 22:38:55 2016 +0300 mfd: intel_soc_pmic_core: Terminate panel control GPIO lookup table correctly GPIO lookup tables are supposed to be zero terminated. Let's do that and avoid accidentally walking off the end. Cc: stable@vger.kernel.org Fixes: 61dd2ca2d44e ("mfd: intel_soc_pmic_core: Add lookup table for Panel Control as GPIO signal") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Daniel Vetter <daniel@ffwll.ch> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel_soc_pmic_core.c | 1 + 1 file changed, 1 insertion(+) commit 14856f75825f77b13564a8cc71deb21409671ab1 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:58 2016 +0530 mfd: wl1273-core: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/wl1273-core.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) commit 6167c5bcef722819ff536dc63ec89825001161ed Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:57 2016 +0530 mfd: tps65910: Use devm_mfd_add_devices and devm_regmap_add_irq_chip Use devm_mfd_add_devices() for adding MFD child devices and devm_regmap_add_irq_chip() for IRQ chip registration. This reduces the error code path and .remove callback for removing MFD child devices and deleting IRQ chip data. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps65910.c | 25 ++++--------------------- 1 file changed, 4 insertions(+), 21 deletions(-) commit 3dc6f4aaafbe9e745fd1183b7a7a91aeeae99fcd Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:56 2016 +0530 mfd: sec: Use devm_mfd_add_devices and devm_regmap_add_irq_chip Use devm_mfd_add_devices() for adding MFD child devices and devm_regmap_add_irq_chip() for IRQ chip registration. This reduces the error code path and .remove callback for removing MFD child devices and deleting IRQ chip data. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/sec-core.c | 20 +++----------------- drivers/mfd/sec-irq.c | 14 +++++--------- 2 files changed, 8 insertions(+), 26 deletions(-) commit b36c82724fa10da7cc73693c6c2c3ab9a6c8034b Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:55 2016 +0530 mfd: rc5t583: Use devm_mfd_add_devices and devm_request_threaded_irq Use devm_mfd_add_devices() for adding MFD child devices and devm_request_threaded_irq() for IRQ registration. This reduces the need of remove callback for removing MFD child devices and unregistering IRQ. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/rc5t583-irq.c | 11 ++--------- drivers/mfd/rc5t583.c | 24 +++--------------------- 2 files changed, 5 insertions(+), 30 deletions(-) commit 1a5422c9e56a20898a73da5726d935d5d8072f78 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:54 2016 +0530 mfd: max77686: Use devm_mfd_add_devices and devm_regmap_add_irq_chip Use devm_mfd_add_devices() for adding MFD child devices and devm_regmap_add_irq_chip() for IRQ chip registration. This reduces the error code path and .remove callback for removing MFD child devices and deleting IRQ chip data. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/max77686.c | 31 ++++++++----------------------- 1 file changed, 8 insertions(+), 23 deletions(-) commit ffc83a79b44e02995ab5e93af07e26f6c7243c53 Author: Shyam Saini <mayhs11saini@gmail.com> Date: Sun May 8 07:30:58 2016 +0530 Staging: emxx_udc: emxx_udc: fixed coding style issue fixed checkpatch.pl warning about 'Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: Shyam Saini <mayhs11saini@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/emxx_udc/emxx_udc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 47678e37927019265ab9c9a2103a0ef76b2584a6 Author: Bruno Carvalho <brunocarvalhofarias@gmail.com> Date: Sat May 7 22:15:53 2016 -0400 staging/gdm724x: fix "alignment should match open parenthesis" issues Fix checkpatch issues: "CHECK: Alignment should match open parenthesis" Signed-off-by: Bruno Carvalho <brunocarvalhofarias@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gdm724x/gdm_mux.c | 5 +++-- drivers/staging/gdm724x/netlink_k.c | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) commit 3cbe6a1c1acd9777f3d6a6a0409c0fcfbb7f832a Author: Bruno Carvalho <brunocarvalhofarias@gmail.com> Date: Sat May 7 22:39:41 2016 -0400 staging/gdm724x: Fix avoid CamelCase Fix checkpatch issues: "CHECK: Avoid CamelCase" Signed-off-by: Bruno Carvalho <brunocarvalhofarias@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gdm724x/gdm_usb.c | 6 +++--- drivers/staging/gdm724x/hci_packet.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit 03759f8cd6e88517980b11c96f377e51d765d403 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Fri May 6 13:11:24 2016 -0400 staging: unisys: rename misleading var ii with frag This patch removes misleading variable name with a more appropriate name. Since ii is keeping track of fragments inside a for loop I renamed it frag. ii->frag Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visornic/visornic_main.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 3b5e11d7f566495f7ff3f4178b814a59b4ea84a5 Author: David Binder <david.binder@unisys.com> Date: Fri May 6 13:11:23 2016 -0400 staging: unisys: visorhba: switch success handling to error handling Addresses code audit feeback to switch from success handling to error handling in visorhba_main.c/process_disk_notify(). Signed-off-by: David Binder <david.binder@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorhba/visorhba_main.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 825157aedabc2b4c0cb3152012b00ea0bdcd6fac Author: Tim Sell <Timothy.Sell@unisys.com> Date: Fri May 6 13:11:22 2016 -0400 staging: unisys: visorhba: main path needs to flow down the left margin In del_scsipending_ent(), the error-path and main-path were switched, so the error-path is handled like 'if (err) return;', and the main-path flows down the left margin. This also allowed us to remove the initialization of "sent". Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorhba/visorhba_main.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 73ba8afe33e22b4bae26098add458bed3e666bc2 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Fri May 6 13:11:21 2016 -0400 staging: unisys: visorinput: handle_locking_key() simplifications By directly returning for the error-case, a test was eliminated. Also, the old_state variable was removed as it was not necessary, and some redundant parens were removed. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorinput/visorinput.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) commit 0fab0f4fcbc08763158529b5ff124c596aef6bf9 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Fri May 6 13:11:20 2016 -0400 staging: unisys: visorhba: fail gracefully for thread creation failures Previously, if visorhba ever failed to create its thread, it would have subsequently attempted to do a kthread_stop() on an invalid task_struct pointer. This was fixed via the new visor_thread_stop() function, which validates the task_struct pointer before doing the kthread_stop(). Also, the other thread-related fields in visor_thread_info (has_stopped and id) were not being used, so visor_thead_info was just removed. We also now spit out an error message if thread creation fails. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorhba/visorhba_main.c | 54 +++++++++++++------------ 1 file changed, 28 insertions(+), 26 deletions(-) commit 77c9a4ae81940fb97a8ec720b64b94a999698963 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Fri May 6 13:11:19 2016 -0400 staging: unisys: visornic: comment restructuring and removing bad diction The purpose of this patch is to clean up commenting and making the code with comments be pleasant to eyes. Also make commenting be consistent throughout the file. Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Reviewed-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visornic/visornic_main.c | 152 +++++++++--------------- 1 file changed, 58 insertions(+), 94 deletions(-) commit 8a1cca31abd4d6470b8fe6f1b2a6fc2f8868ca8b Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Fri May 6 13:11:18 2016 -0400 staging: unisys: fix format string %Lx to %llx for u64 this patch fixes the following sonarqube issue. %Lx in format string (no. 1) requires 'unsigned long long' but the argument type is 'unsigned long long' Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 456743c357895678431c91c7305d8abaabc92781 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Fri May 6 13:11:17 2016 -0400 staging: unisys: remove unused struct members The following struct members were never used: putfile_active_buffer::pnext putfile_request::file_request_number putfile_request::data_sequence_number Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Reviewed-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 6 ------ 1 file changed, 6 deletions(-) commit 80bee2617ac0c39925023b78a883f154c2b1f86b Author: David Binder <david.binder@unisys.com> Date: Fri May 6 13:11:16 2016 -0400 staging: unisys: visorchannel: correct variable misspelling Fixes the spelling of a global variable passed into a kernel macro. Signed-off-by: David Binder <david.binder@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9136d04fe9255522c4c8ef5124be899906de7dd1 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Fri May 6 13:11:15 2016 -0400 staging: unisys: visorhba: replace functionlike macro with function The `set_no_disk_inquiry_request` function now uses the correct min macro. Also I removed an unnecessary conditional. Get rid of u8 casts, u32 len, and u32 lun (which is actually defined as a u64 in the scsidev->lun field from whence it originated). Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/iochannel.h | 42 ------------------------- drivers/staging/unisys/visorhba/visorhba_main.c | 26 ++++++++++++--- 2 files changed, 22 insertions(+), 46 deletions(-) commit bddb1531086ff40e8eb81dd1e30b56407a7a4279 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon May 9 11:47:34 2016 +0900 staging: dgnc: Need to check for NULL of ch the "ch" from brd structure could be NULL, it need to check for NULL. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c246e2305aa2a70d720b4d50427d25bf786de7e6 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon May 9 11:47:11 2016 +0900 staging: dgnc: remove redundant condition check dgnc_board(brd) was already checked for NULL before calling neo_parse_isr(). And also port doesn't need to check. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 6 ------ 1 file changed, 6 deletions(-) commit edd19a2f9fd85824d7ae2ca24b7f04f2b8fa0920 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon May 9 11:46:50 2016 +0900 staging: dgnc: fix 'line over 80 characters' fix checkpatch.pl warning about 'line over 80 characters'. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_sysfs.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit a5b90ef7a1fed3fc0f7a4bf0ad0159eaddb2acfb Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Wed May 4 14:13:48 2016 +0900 staging: dgnc: clean up the dgnc_get_modem_info() the "ch" in dgnc_get_modem_info() was already checked before calling this function and also if "ch" is not NULL, dgnc_get_mstat() returns valid value so it doesn't need to check an error. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit 1b30ccded52fb2b297128b190b47641457ecc8f5 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:31 2016 -0400 staging: lustre: lnet: enable configuration per NI interface Add the ability to configure each NI interface at bring up. Also give the ability for user land utilities to query the configuration of each NI interface. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/lnet/api-ni.c | 42 +++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit 2c6a1845e62a02386ab61352c382f4ef9ce82e44 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:30 2016 -0400 staging: lustre: o2iblnd: properly set ibr_why For the case of when the connections supported fragment count is smaller than what is supported locally only set ibr_why to IBLND_REJECT_RDMA_FRAGS if the ko2iblnd protocol verison is IBLND_MSG_VERSION. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 69b48fffc087cd212f3d109de298d0d23981e9ad Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:29 2016 -0400 staging: lustre: o2iblnd: remove last of kiblnd_tunables_fini The function kibnd_tunables_fini() no longer exist. Remove it from o2iblnd.h Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 1 - 1 file changed, 1 deletion(-) commit 32c8deb8b620918db0c55fb3f3b3f9ff9f935635 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:28 2016 -0400 staging: lustre: o2iblnd: per NI map-on-demand value Enables support of different map-on-demand values per NI. This is required to support OPA coexistence with MLX5 cards. MLX5 does not support FMR, which is enabled via map-on-demand. However OPA's performance is greatly enahanced when FMR is enabled. In order to enable coexistence of both of these two types of cards we need to be able to set different map-on-demand values for both NIs. This patch also lays the ground work for other per NI tunables to be added in future patches. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 66 ++++++++++------- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 35 ++++----- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 13 ++-- .../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c | 84 +++++++++++++++------- 4 files changed, 125 insertions(+), 73 deletions(-) commit f6e500660d74bdcc32560eb7f94a434f38d1c9f2 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:27 2016 -0400 staging: lustre: o2iblnd: use data in lnet_ni_t instead of kiblnd_tunables Currently the ko2iblnd creates a kib_tunable_t stucture to allow the ko2iblnd driver to access the module parameters throught the code. Some of those data fields also exist in lnet_ni_t. Migrate to using the lnet_ni_t data fields instead of kib_tunable_t. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 8 +--- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 6 +-- .../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c | 54 +++++++++++++--------- 3 files changed, 34 insertions(+), 34 deletions(-) commit 025ba826316c9809073702302578efcfa4ba3f6f Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:26 2016 -0400 staging: lustre: o2iblnd: create default o2iblnd tunable settings Create and set the default o2iblnd tunables when the ko2iblnd module loads. Move kiblnd_tunables_setup() to when the NI iterface is initialized. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 9 ++++----- drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 3 ++- .../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c | 16 ++++++++++++++-- 3 files changed, 20 insertions(+), 8 deletions(-) commit 9e7d5bf357fa798f21b4a775b47faa64e4b5f6e8 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:25 2016 -0400 staging: lustre: o2iblnd: convert macros to inline functions Convert a few macros in o2iblnd.h to inline functions. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 2 +- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 62 +++++++++++++--------- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 21 ++++---- .../lustre/lnet/klnds/o2iblnd/o2iblnd_modparams.c | 11 ++++ 4 files changed, 61 insertions(+), 35 deletions(-) commit 243a941c0d17599bfee4cf3c48775f155c0b89a3 Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:24 2016 -0400 staging: lustre: lnet: add per NI configuration structures Currently for LNet all hardware configuration is done with the modprobe configuration file. These settings are applied to all hardware instances for a node. That makes it impossible to configure two different pieces of infiniband hardware that require very different settings to function. Here we introduce the infrastructre to allow applying per interface settings. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/lnet/lib-dlc.h | 29 +++++++++++++++++++++- .../staging/lustre/include/linux/lnet/lib-types.h | 2 ++ drivers/staging/lustre/lnet/lnet/config.c | 3 +++ 3 files changed, 33 insertions(+), 1 deletion(-) commit 27c7f7caa694aee34665f06c0f6b0c49995d9e4f Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:23 2016 -0400 staging: lustre: lnet: use struct lnet_ioctl_config_data for NI query The functions used to query the NI state passes around the individual fields of struct lnet_ioctl_config_data. To simplify the code lets just pass struct lnet_ioctl_config directly. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/lnet/lib-lnet.h | 4 -- drivers/staging/lustre/lnet/lnet/api-ni.c | 60 +++++++--------------- 2 files changed, 18 insertions(+), 46 deletions(-) commit d76d938589eadb1295cb03c672b84f4869d0fe2c Author: Amir Shehata <amir.shehata@intel.com> Date: Fri May 6 21:30:22 2016 -0400 staging: lustre: lnet: use struct lnet_ioctl_config_data for NI bring up The LNet layer passes around the individual fields of struct lnet_ioctl_config_data for the case of NI bring up. To simplify the code lets just pass struct lnet_ioctl_config directly. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7101 Reviewed-on: http://review.whamcloud.com/16367 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Olaf Weber <olaf@sgi.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/lnet/lib-lnet.h | 5 ++- drivers/staging/lustre/lnet/lnet/api-ni.c | 37 ++++++++++++---------- drivers/staging/lustre/lnet/lnet/module.c | 7 +--- 3 files changed, 24 insertions(+), 25 deletions(-) commit 80e05b34f882dd03e3b7eaa1923e49deae6e409e Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:07 2016 -0400 staging: lustre: o2iblnd: Add Fast Reg memory registration support FMR is deprecated and it not supported by the mlx5 driver. This patch adds memory management extensions support as backup of FMR. This was combined with the work from Li Dongyang to make it work with the latest kernels. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 237 ++++++++++++++++++--- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 25 ++- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 50 +++-- 3 files changed, 257 insertions(+), 55 deletions(-) commit 4d65730bd674b44cb4c7c9bc45b98692215d0881 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:06 2016 -0400 staging: lustre: o2iblnd: add IBLND_WID_MR We need to add a new error field to be passed with wr_id to handle Fast Registration failures. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1f199a0c46fbdec52e25afaeb0b4736d40850409 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:05 2016 -0400 staging: lustre: o2iblnd: handle unmapping of FMR in kiblnd_fmr_pool_unmap Move FMR unmapping from kiblnd_unmap_tx() to the function kiblnd_fmr_pool_unmap() so kiblnd_unmap_tx() can be used with the Fast Registration API as well. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 14 ++++++++++---- drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 4 +--- 2 files changed, 11 insertions(+), 7 deletions(-) commit c1b2e0b517d0eba6936c69fa6d9a1a727534f879 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:04 2016 -0400 staging: lustre: o2iblnd: cache FMR key in kib_fmr_t Move the FMR key handling from kiblnd_fmr_map_tx() to the function kiblnd_fmr_pool_map(). This will allow the function kiblnd_fmr_map_tx() to handle keys for both FMR and Fast Registration. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 11 +++++++---- drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 5 +++-- drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 8 ++++---- 3 files changed, 14 insertions(+), 10 deletions(-) commit f66fb15996fb9d75c552b6d1dafe71b5737261d9 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:03 2016 -0400 staging: lustre: o2iblnd: break up kiblnd_create_fmr_pool Break the function kiblnd_create_fmr_pool() into two functions, with the new function called kiblnd_alloc_fmr_pool(). The function kiblnd_create_fmr_pool() will be used as the front end to allocate any type of pool. The new function will used to create specifically FMR pools. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 55 ++++++++++++++++------ 1 file changed, 41 insertions(+), 14 deletions(-) commit 87f4f6f53424ed010bc45fe2accb4582cc490b58 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:02 2016 -0400 staging: lustre: o2iblnd: create union to contain FMR Create an union to contain the FMR pool structure. This is for the preparation of adding handling Fast Registeration support. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 14 +++++++------- drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 8 ++++++-- 2 files changed, 13 insertions(+), 9 deletions(-) commit 0d33ec5f95fe068d7e96b6e7ed9216de93f6b5b0 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:01 2016 -0400 staging: lustre: o2iblnd: Use list_for_each_entry_safe in kiblnd_destroy_fmr_pool_list Doubly linked lists which are iterated using list_empty and list_entry macros have been replaced with list_for_each_entry_safe macro. This makes the iteration simpler and more readable. This patch replaces the while loop containing list_empty and list_entry with list_for_each_entry_safe. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 8daab0a4dea3655ba336a24d7258a94c256e03b1 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Thu May 5 14:53:00 2016 -0400 staging: lustre: o2iblnd: rename kib_fmr_pool_t Rename kib_fmr_pool_t named pool to fpo. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5783 Reviewed-on: http://review.whamcloud.com/17606 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 51a1c3804b06bd3877e3c5e886ea39b1eb891695 Author: John L. Hammond <john.hammond@intel.com> Date: Wed May 4 10:29:00 2016 -0400 staging: lustre: lov: remove unused lov obd functions Remove the unused lov functions lov_get_reqset, lov_check_index_in_pool, and lov_find_pool functions. Remove unused data structures. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-on: http://review.whamcloud.com/5581 Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lov/lov_ea.c | 5 --- drivers/staging/lustre/lustre/lov/lov_internal.h | 11 ------ drivers/staging/lustre/lustre/lov/lov_obd.c | 1 - drivers/staging/lustre/lustre/lov/lov_pool.c | 47 ------------------------ drivers/staging/lustre/lustre/lov/lov_request.c | 3 -- 5 files changed, 67 deletions(-) commit ebde64c0657709e7260d2e73583309761e904dd7 Author: wang di <di.wang@intel.com> Date: Wed May 4 10:28:59 2016 -0400 staging: lustre: fid: init FID client for OSP on MDT. Initialize FID client for OSP on MDT. Signed-off-by: wang di <di.wang@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3529 Reviewed-on: http://review.whamcloud.com/7158 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/fid/fid_request.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 2ff1d8fbba493538e0d0c4f0e2dcd9c4bb0eb21a Author: Niu Yawei <yawei.niu@intel.com> Date: Wed May 4 10:28:58 2016 -0400 staging: lustre: ptlrpc: fix nrs cleanup When service start failed due to short of memory, the cleanup code could operate on uninitialized structure and cause crash at the end. This patch fix the nrs_svcpt_cleanup_locked() to perform cleanup only on the nrs which has been properly initialized. Signed-off-by: Niu Yawei <yawei.niu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3772 Reviewed-on: http://review.whamcloud.com/7410 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ptlrpc/nrs.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 4fd9a8e937368781ac830402a3bcb87646999946 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Wed May 4 10:28:57 2016 -0400 staging: lustre: debug: clean up console messages Clean up overly verbose console error messages, improve others. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1095 Reviewed-on: http://review.whamcloud.com/8617 Reviewed-by: Faccini Bruno <bruno.faccini@intel.com> Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_lib.c | 4 +--- drivers/staging/lustre/lustre/obdclass/obd_mount.c | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) commit 221446263ee59c632bce0901d6293c34be1dcd57 Author: Fan Yong <fan.yong@intel.com> Date: Wed May 4 10:28:56 2016 -0400 staging: lustre: fid: packing ost_idx in IDIF For a normal FID, we can know on which target the related object is allocated via querying FLDB; but it is not true for an IDIF. To locate the OST via the given IDIF, when the IDIF is generated, we pack the OST index in it. Then for any given FID, in spite of t is a normal FID or not, we has the method to know which target it belongs to. That is useful for LFSCK. For old IDIF, the OST index is not part of the IDIF, means that ifferent OSTs may have the same IDIFs, that may cause the IFID in LMA does not match the read FID. Under such case, we need to make some compatible check to avoid to trigger unexpected. tgt_validate_obdo() converts the ostid contained in the RPC body to fid and changes the "struct ost_id" union, then the users can access ost_id::oi_fid directly without call ostid_to_fid() again. It also contains some other fixing and cleanup. Signed-off-by: wang di <di.wang@intel.com> Signed-off-by: Fan Yong <fan.yong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3569 Reviewed-on: http://review.whamcloud.com/7053 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/include/lustre/lustre_idl.h | 76 +++++++++++++++------- drivers/staging/lustre/lustre/include/lustre_fid.h | 22 ++----- 2 files changed, 57 insertions(+), 41 deletions(-) commit 483eec0deba1505e437b639dd353f8cd4336133d Author: wang di <di.wang@intel.com> Date: Wed May 4 10:28:55 2016 -0400 staging: lustre: mdt: extra checking for getattr RPC. Check whether getattr RPC can hold layout MD(RMF_MDT_MD), in case the client sends some invalid RPC, which can cause panic on MDT. Client will retrieve cl_max_md_size/cl_default_md_size from MDS during mount process, so it will initialize cl_max_md_size/cl_default_md_size before sending getattr to MDS. Signed-off-by: wang di <di.wang@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4222 Reviewed-on: http://review.whamcloud.com/8599 Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_lib.c | 2 +- drivers/staging/lustre/lustre/mdc/mdc_request.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) commit ae322e05ebc033b89d46e37df744f08240cf0a3d Author: John L. Hammond <john.hammond@intel.com> Date: Wed May 4 10:28:54 2016 -0400 staging: lustre: lov: remove lov and lod stuff from obd.h Remove QOS related data structures from obd.h to the lov_internal.h. Remove the declarations of several functions that no longer exist. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-on: http://review.whamcloud.com/8687 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/obd.h | 60 ------------------------ drivers/staging/lustre/lustre/lov/lov_internal.h | 21 +++++++-- drivers/staging/lustre/lustre/lov/lov_obd.c | 2 - drivers/staging/lustre/lustre/lov/lov_pool.c | 15 +----- 4 files changed, 18 insertions(+), 80 deletions(-) commit 219eeac841fb8fd70b73bec9c986c2d0044faf92 Author: Alexander Boyko <alexander_boyko@xyratex.com> Date: Wed May 4 10:28:53 2016 -0400 staging: lustre: osc: Allow lock to be canceled at ENQ time A cl_lock can be canceled when it's in CLS_ENQUEUED state. We can't unuse this kind of lock in lov_lock_unuse() because it will bring this lock into CLS_NEW state and then confuse osc_lock_upcall(). Add a regression test case by Alexander Boyko. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Alexander Boyko <alexander_boyko@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3889 Reviewed-on: http://review.whamcloud.com/8405 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/obd_support.h | 1 + drivers/staging/lustre/lustre/osc/osc_request.c | 3 +++ 2 files changed, 4 insertions(+) commit 1e5a6fa96689232faf92b2352dd4bb0fda28b37e Author: Bobi Jam <bobijam.xu@intel.com> Date: Wed May 4 10:28:52 2016 -0400 staging: lustre: nfs: don't panic NFS server if MDS fails to find FID When MDS fails to retrive the parent's fid, we'd handle it without crashing the NFS server. Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3952 Reviewed-on: http://review.whamcloud.com/8459 Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: wangdi <di.wang@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_nfs.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 60a37709ce603da62d0b60699b713558b4cfd513 Author: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Date: Fri Apr 1 15:38:57 2016 +0300 KVM: s390: Populate mask of non-hypervisor managed facility bits When a guest is initializing, KVM provides facility bits that can be successfully used by the guest. It's done by applying kvm_s390_fac_list_mask mask on host facility bits stored by the STFLE instruction. Facility bits can be one of two kinds: it's either a hypervisor managed bit or non-hypervisor managed. The hardware provides information which bits need special handling. Let's automatically passthrough to guests new facility bits, that don't require hypervisor support. Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Reviewed-by: Eric Farman <farman@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/kvm-s390.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) commit 154fa27e6ba37931ca585598acf17c4dcd44c81a Author: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Date: Fri Apr 1 15:36:51 2016 +0300 s390/sclp: Add hmfai field Let's add hypervisor-managed facility-apportionment indications field to SCLP structs. KVM will use it to reduce maintenance cost of Non-Hypervisor-Managed facility bits. Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Reviewed-by: Eric Farman <farman@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/include/asm/sclp.h | 1 + drivers/s390/char/sclp_early.c | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) commit ed8dda0bf74b4fb8e73d8880c78effabd3285fd8 Author: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Date: Thu Mar 31 13:48:52 2016 +0300 KVM: s390: Enable all facility bits that are known good for passthrough Some facility bits are in a range that is defined to be "ok for guests without any necessary hypervisor changes". Enable those bits. Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/kvm-s390.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 051c87f744a21b866872b16821084e96794231b5 Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Tue Apr 19 13:13:40 2016 +0200 KVM: s390: document KVM_CAP_S390_RI We forgot to document that capability, let's add documentation. Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Documentation/virtual/kvm/api.txt | 8 ++++++++ 1 file changed, 8 insertions(+) commit 053dd2308d8174566af4ac0059397c3e4042ebfb Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Mon Apr 4 13:59:42 2016 +0200 KVM: s390: force ibc into valid range Some hardware variants will round the ibc value up/down themselves, others will report a validity intercept. Let's always round it up/down. This patch will also make sure that the ibc is set to 0 in case we don't have ibc support (lowest_ibc == 0). Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/kvm-s390.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 9bb0ec099756078118d8079e09f2bf3d6e7e00b6 Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Mon Apr 4 14:27:51 2016 +0200 KVM: s390: cleanup cpuid handling We only have one cpuid for all VCPUs, so let's directly use the one in the cpu model. Also always store it directly as u64, no need for struct cpuid. Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/include/asm/kvm_host.h | 6 +----- arch/s390/kvm/kvm-s390.c | 17 +++++++++-------- arch/s390/kvm/priv.c | 2 +- 3 files changed, 11 insertions(+), 14 deletions(-) commit bd50e8ec8f668de472b3bf782ac95866056257dd Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Fri Mar 4 12:23:55 2016 +0100 KVM: s390: enable SRS only if enabled for the guest If we don't have SIGP SENSE RUNNING STATUS enabled for the guest, let's not enable interpretation so we can correctly report an invalid order. Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/include/asm/sigp.h | 1 + arch/s390/kvm/kvm-s390.c | 4 +++- arch/s390/kvm/sigp.c | 6 ++++++ 3 files changed, 10 insertions(+), 1 deletion(-) commit d6af0b491b1f675e5e5a12c5587f804c698a6ba5 Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Fri Mar 4 11:55:56 2016 +0100 KVM: s390: enable PFMFI only if guest has EDAT1 Only enable PFMF interpretation if the necessary facility (EDAT1) is available, otherwise the pfmf handler in priv.c will inject an exception Reviewed-by: Dominik Dingel <dingel@linux.vnet.ibm.com> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/kvm-s390.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 4096e645d85d575e7b6e699f470f5519c34fda5d Merge: a0ca97b 44549e8 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon May 9 13:20:04 2016 +0200 Merge 4.6-rc7 into staging-next This fixes some merge issues with some iio drivers that were found in linux-next. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit d20bb59af64667a16f2468b54fc0adb2f824a3b6 Author: Baruch Siach <baruch@tkos.co.il> Date: Mon Mar 7 08:31:14 2016 +0200 MAINTAINERS: 8250: remove website reference This website is obsolete, as it has not been updated in more than a decade. Cc: "Theodore Ts'o" <tytso@mit.edu> Signed-off-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> MAINTAINERS | 1 - 1 file changed, 1 deletion(-) commit 13069bd94d559c0d91dd97341bfed9d237a5032d Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Wed May 4 08:00:54 2016 +0530 usb: Remove unnecessary space before operator ','. Remove unnecessary space before operator ','. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/phy/phy-twl6030-usb.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 2b320d87f30ad2c91df8d05e29cc37c3b4df143b Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Wed May 4 07:45:37 2016 +0530 usb: Remove unnecessary space before open square bracket. Remove unnecessary space before open square bracket. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/isp1760/isp1760-if.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2b4ba254d2c1f7489da435fba0add68e6695fefa Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Mon May 9 00:15:31 2016 +0200 USB: FHCI: avoid redundant condition The right part of the following or expression is only evaluated if td is nonzero. !td || (td && td.status == USB_TD_INPROGRESS) So no need to check td again. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/fhci-sched.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f879fc32aa0c96fbac261b3d857a1239d554ad01 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Fri May 6 15:20:11 2016 +0900 usb: host: xhci-rcar: Avoid long wait in xhci_reset() The firmware of R-Car USB 3.0 host controller will control the reset. So, if the xhci driver doesn't do firmware downloading (e.g. kernel configuration is CONFIG_USB_XHCI_PLATFORM=y and CONFIG_USB_XHCI_RCAR is not set), the reset of USB 3.0 host controller doesn't work correctly. Then, the host controller will cause long wait in xhci_reset() because the CMD_RESET bit of op_regs->command is not cleared for 10 seconds. So, this patch modifies the Kconfig to enable both CONFIG_USB_XHCI_PLATFORM and CONFIG_USB_XHCI_RCAR. Fixes: 4ac8918f3a7 (usb: host: xhci-plat: add support for the R-Car H2 and M2 xHCI controllers) Cc: <stable@vger.kernel.org> # v3.17+ Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Reviewed-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9f3b3f6a30cbf9a9664fc7ca3510f1df00098f19 Author: Colin Ian King <colin.king@canonical.com> Date: Sun May 8 20:14:29 2016 +0100 usb/host/fotg210: remove dead code in create_sysfs_files The goto in create_sysfs_files is never executed, so remove it and clean up the code. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/fotg210-hcd.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit ef23db9c5ee2dd240ad6875e03d004416f4ee0df Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon May 9 08:26:01 2016 +0530 usb: wusbcore: Do not initialise statics to 0. Do not initialise statics to 0. This patch is found by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/wusbcore/crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 06acefde5bf1fb64b2d450ddb17c843f76837dc6 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon May 9 08:42:07 2016 +0530 usb: wusbcore: Remove space before ',' and '(' . Remove space before ',' and '(' . This patch is detected by checkpatch.pl Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/wusbcore/crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 809eac54cdd62c67afea1e17080e681dfa33dc09 Author: Robin Murphy <robin.murphy@arm.com> Date: Mon Apr 11 12:32:31 2016 +0100 iommu/dma: Implement scatterlist segment merging Stop wasting IOVA space by over-aligning scatterlist segments for a theoretical worst-case segment boundary mask, and instead take the real limits into account to merge consecutive segments wherever appropriate, so our callers can benefit from getting back nicely simplified lists. This also represents the last piece of functionality wanted by users of the current arch/arm implementation, thus brings us a small step closer to converting that over to the common code. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/dma-iommu.c | 84 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 61 insertions(+), 23 deletions(-) commit 8801561ce029ef2bf6927c53b834d711830bc8be Merge: 44549e8 3ca3712 Author: Joerg Roedel <jroedel@suse.de> Date: Mon May 9 12:03:37 2016 +0200 Merge branch 'for-joerg/arm-smmu/updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu commit 32eb6e8bee147b45e5e59230630d59541ccbb6e5 Author: James Hogan <james.hogan@imgtec.com> Date: Thu Apr 28 17:06:16 2016 +0100 MIPS: Netlogic: Fix CP0_EBASE redefinition warnings A couple of netlogic assembly files define CP0_EBASE to $15, the same as CP0_PRID in mipsregs.h, and use it for accessing both CP0_PRId and CP0_EBase registers. However commit 609cf6f2291a ("MIPS: CPS: Early debug using an ns16550-compatible UART") added a different definition of CP0_EBASE to mipsregs.h, which included a register select of 1. This causes harmless build warnings like the following: arch/mips/netlogic/common/reset.S:53:0: warning: "CP0_EBASE" redefined #define CP0_EBASE $15 ^ In file included from arch/mips/netlogic/common/reset.S:41:0: ./arch/mips/include/asm/mipsregs.h:63:0: note: this is the location of the previous definition #define CP0_EBASE $15, 1 ^ Update the code to use the definitions from mipsregs.h for accessing both registers. Fixes: 609cf6f2291a ("MIPS: CPS: Early debug using an ns16550-compatible UART") Signed-off-by: James Hogan <james.hogan@imgtec.com> Acked-by: Jayachandran C <jchandra@broadcom.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13183/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/netlogic/common/reset.S | 11 +++++------ arch/mips/netlogic/common/smpboot.S | 4 +--- 2 files changed, 6 insertions(+), 9 deletions(-) commit 128639395b2ceacc6a56a0141d0261012bfe04d3 Author: Joshua Kinard <kumba@gentoo.org> Date: Mon Sep 7 06:42:30 2015 -0400 MIPS: Adjust set_pte() SMP fix to handle R10000_LLSC_WAR Update the recent changes to set_pte() that were added in 46011e6ea392 to handle R10000_LLSC_WAR, and format the assembly to match other areas of the MIPS tree using the same WAR. This also incorporates a patch recently sent in my Markos Chandras, "Remove local LL/SC preprocessor variants", so that patch doesn't need to be applied if this one is accepted. Signed-off-by: Joshua Kinard <kumba@gentoo.org> Fixes: 46011e6ea392 ("MIPS: Make set_pte() SMP safe.) Cc: David Daney <david.daney@cavium.com> Cc: Linux/MIPS <linux-mips@linux-mips.org> Patchwork: https://patchwork.linux-mips.org/patch/11103/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/pgtable.h | 45 +++++++++++++++++++++++++++++------------ 1 file changed, 32 insertions(+), 13 deletions(-) commit 05490626d5f535baaaec60cdd37167f1a8031a9b Author: Ralf Baechle <ralf@linux-mips.org> Date: Fri Apr 15 10:25:33 2016 +0200 MIPS: Move definitions for 32/64-bit agonstic inline assembler to new file. Inspired by Markos Chandras' patch. I just didn't want do pull bitsops.h into pgtable.h. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> References: https://patchwork.linux-mips.org/patch/11052/ arch/mips/include/asm/bitops.h | 17 +---------------- arch/mips/include/asm/llsc.h | 28 ++++++++++++++++++++++++++++ arch/mips/include/asm/pgtable.h | 11 ++--------- 3 files changed, 31 insertions(+), 25 deletions(-) commit 92e9953c5865b47281d74d43f08d7cecde11e58a Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 15 10:07:26 2016 +0100 MIPS: Fix MSA assembly warnings Building an MSA capable kernel with a toolchain that supports MSA produces warnings such as this: arch/mips/kernel/r4k_fpu.S:229: Warning: the `msa' extension requires 64-bit FPRs This is due to ".set msa" without ".set fp=64" in the non doubleword MSA load/store macros, since MSA requires the 64-bit FPU registers (FR=1). Add the missing fp=64 in these macros to silence the warnings. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13063/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/asmmacro.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 143e93d74e19febd491792cdd3aec3054883b776 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 15 10:07:25 2016 +0100 MIPS: Fix MSA assembly with big thread offsets When lockdep is enabled on a 64-bit kernel the FPR offset into the thread structure exceeds the maximum range of the MSA ld.d/st.d instructions. For example THREAD_FPR31 = 4644 (instead of 2448), while the signed immediate field is only 10 bits with an implicit multiply by 8, giving a maximum offset of 511*8 = 4088. This isn't a problem when the toolchain doesn't support MSA as the ld_*/st_* macros perform the addition separately into $1 with [d]addui which has a 16bit signed immediate field. Fix the case where the toolchain does support MSA by doing a single addition of THREAD_FPR0 into $1 with [d]addui, and doing the ld_*/st_* relative to that. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13064/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/asmmacro.h | 149 ++++++++++++++++++++++----------------- 1 file changed, 83 insertions(+), 66 deletions(-) commit ea1688573426adc2587ed52d086b51c7c62eaca3 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 15 10:07:24 2016 +0100 MIPS: Fix MSA ld_*/st_* asm macros to use PTR_ADDU The MSA ld_*/st_* assembler macros for when the toolchain doesn't support MSA use addu to offset the base address. However it is a virtual memory pointer so fix it to use PTR_ADDU which expands to daddu for 64-bit kernels. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.3.y- Patchwork: https://patchwork.linux-mips.org/patch/13062/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/asmmacro.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 8a3c8b48aca8771bff3536e40aa26ffb311699d1 Author: Paul Burton <paul.burton@imgtec.com> Date: Fri Apr 15 10:07:23 2016 +0100 MIPS: Use copy_s.fmt rather than copy_u.fmt In revision 1.12 of the MSA specification, the copy_u.w instruction has been removed for MIPS32 & the copy_u.d instruction has been removed for MIPS64. Newer toolchains (eg. Codescape SDK essentials 2015.10) will complain about this like so: arch/mips/kernel/r4k_fpu.S:290: Error: opcode not supported on this processor: mips32r2 (mips32r2) `copy_u.w $1,$w26[3]' Since we always copy to the width of a GPR, simply use copy_s instead of copy_u to fix this. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.3.x+ Patchwork: https://patchwork.linux-mips.org/patch/13061/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/asmmacro.h | 24 ++++++++++++------------ arch/mips/kernel/r4k_fpu.S | 10 +++++----- 2 files changed, 17 insertions(+), 17 deletions(-) commit 8e85f275e934fe4e9be02c1d80583b042de5438c Author: Maciej W. Rozycki <macro@linux-mips.org> Date: Sun Feb 7 11:05:58 2016 +0000 MIPS: memset.S: Disable code unused with non-R6 MIPS configs This complements commit 8c56208aff77 ("MIPS: lib: memset: Add MIPS R6 support"). Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12452/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/lib/memset.S | 2 ++ 1 file changed, 2 insertions(+) commit 41fa29e4d8cf4150568a0fe9bb4d62229f9caed5 Author: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Date: Tue Apr 28 12:53:35 2015 -0700 MIPS64: R6: R2 emulation bugfix Error recovery pointers for fixups was improperly set as ".word" which is unsuitable for MIPS64. Replaced by STR(PTR) [ralf@linux-mips.org: Apply changes as requested in the review process.] Signed-off-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Reviewed-by: Markos Chandras <markos.chandras@imgtec.com> Fixes: b0a668fb2038 ("MIPS: kernel: mips-r2-to-r6-emul: Add R2 emulator for MIPS R6") Cc: macro@linux-mips.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Cc: <stable@vger.kernel.org> # 4.0+ Patchwork: https://patchwork.linux-mips.org/patch/9911/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/mips-r2-to-r6-emul.c | 105 +++++++++++++++++----------------- 1 file changed, 53 insertions(+), 52 deletions(-) commit 8d4925e9a5e5fb360b091b94a9682e02dfbf8e2b Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Mon Dec 21 15:21:42 2015 +0000 MIPS: dma-default: Defend against NULL dev in massage_gfp_flags This patch ensures that the dev parameter is checked for NULL before it is dereferenced in massage_gfp_flags. If dev is NULL, then fall back setting the GFP flag requested and available. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11919/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/dma-default.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit fa0c879ffc869e2597364c72080fd4756a96e99a Author: Yanjiang Jin <yanjiang.jin@windriver.com> Date: Wed Dec 9 11:15:27 2015 +0800 MIPS: oprofile: Fix a preemption issue Use boot_cpu_type() instead of current_cpu_type() in oprofile_arch_init() to avoid the below warning, cpu_type is normally consistent in a MIPS SMP system. There are a few exceptions such as SGI servers where it is possible to mix R10000, R12000, R14000 and R16000 within certain constraints. Let's not worry about those now. BUG: using smp_processor_id() in preemptible [00000000] code: insmod/952 caller is oprofile_arch_init+0x30/0x194 [oprofile] CPU: 5 PID: 952 Comm: insmod Not tainted 4.1.13-WR8.0.0.0_standard #1 Stack : ffffffff80c10000 0000000000000001 8000000025bf0790 ffffffff80e10000 ffffffff80e50000 ffffffff80254e2c ffffffff80b64428 ffffffff80e10790 0000000000000000 ffffffff801caeb8 0000000000000045 0000000000000005 ffffffff80c10000 ffffffff801cb798 0000000000000000 ffffffff80e30000 0000000000000000 ffffffff801ff1c0 ffffffff80e2d2f8 000000000000000b ffffffff801cbba0 ffffffff80e107b0 ffffffff80a77828 0000000000000005 00000000000003b8 ffffffff80e2d2f8 800000040ad39960 ffffffff801f9950 0000000000000124 80000004093b7990 80000004093b7ab8 ffffffff80925108 ffffffff80b69a07 ffffffff80a6f0d0 8000000407240e00 ffffffff801cc934 000000000000005d ffffffff80159080 0000000000000005 00000000000003b8 ... Call Trace: [<ffffffff80159080>] show_stack+0xe8/0x108 [<ffffffff80925108>] dump_stack+0x8c/0xd8 [<ffffffff80606570>] check_preemption_disabled+0x110/0x118 [<ffffffffc0086104>] oprofile_arch_init+0x30/0x194 [oprofile] [<ffffffffc008602c>] oprofile_init+0x2c/0xc0 [oprofile] [<ffffffff80100550>] do_one_initcall+0xa0/0x1c0 [<ffffffff80921e04>] do_init_module+0x80/0x1d8 [<ffffffff801fd0d4>] load_module+0x1b74/0x2278 [<ffffffff801fdab4>] SyS_finit_module+0xcc/0xf0 [<ffffffff80165884>] handle_sysn32+0x44/0x70 [ralf@linux-mips.org: Correct commit message.] Signed-off-by: Yanjiang Jin <yanjiang.jin@windriver.com> Cc: rric@kernel.org Cc: jinyanjiang@gmail.com Cc: linux-mips@linux-mips.org Cc: oprofile-list@lists.sf.net Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/11769/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/oprofile/common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 820880cdba0137baff6cc0e828c3c418c363ae44 Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 17 20:41:06 2016 +0800 MIPS: Loongson-3: Fix build error after ld-version.sh modification Commit d5ece1cb074b2c ("Fix ld-version.sh to handle large 3rd version part") modifies the ld version description. This causes a build error on Loongson-3, so fix it. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: Huacai Chen <chenhc@lemote.com> Cc: linux-mips@linux-mips.org Cc: stable@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12890/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/loongson64/Platform | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3484de7bcbed20ecbf2b8d80671619e7059e2dd7 Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 17 20:41:05 2016 +0800 MIPS: Loongson-3: Reserve 32MB for RS780E integrated GPU Due to datasheet, reserving 0xff800000~0xffffffff (8MB below 4GB) is not enough for RS780E integrated GPU's TOM (top of memory) registers and MSI/MSI-x memory region, so we reserve 0xfe000000~0xffffffff (32MB below 4GB). Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Cc: stable@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12889/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/loongson64/loongson-3/numa.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit a95d069204e178f18476f5499abab0d0d9cbc32c Author: Huacai Chen <chenhc@lemote.com> Date: Thu Mar 17 20:37:10 2016 +0800 MIPS: Reserve nosave data for hibernation After commit 92923ca3aacef63c92d ("mm: meminit: only set page reserved in the memblock region"), the MIPS hibernation is broken. Because pages in nosave data section should be "reserved", but currently they aren't set to "reserved" at initialization. This patch makes hibernation work again. Signed-off-by: Huacai Chen <chenhc@lemote.com> Cc: Aurelien Jarno <aurelien@aurel32.net> Cc: Steven J . Hill <sjhill@realitydiluted.com> Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Cc: stable@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12888/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/setup.c | 3 +++ 1 file changed, 3 insertions(+) commit 54292850e8f56c8408db44ea3a5167a0f7c156d5 Author: Andreas Ruprecht <andreas.ruprecht@fau.de> Date: Thu Jul 16 17:52:11 2015 +0200 MIPS: Sibyte: Fix Kconfig dependencies of SIBYTE_BUS_WATCHER Commit 6793f55cbc84 ("MIPS: sibyte: Amend dependencies for SIBYTE_BUS_WATCHER") changed the dependencies for SIBYTE_BUS_WATCHER to make it visible only if SIBYTE_BCM112X or SIBYTE_SB1250 are enabled. In the code in arch/mips/sibyte/common/bus_watcher, however, a #if defined() check suggests that this functionality should also be available for SIBYTE_BCM1x55 and SIBYTE_BCM1x80. Make it selectable by extending the dependencies of SIBYTE_BUS_WATCHER in arch/mips/sibyte/Kconfig. Reported-by: Jonas Rabenstein <jonas.rabenstein@studium.uni-erlangen.de> Signed-off-by: Andreas Ruprecht <andreas.ruprecht@fau.de> Cc: valentinrothberg@gmail.com Cc: stefan.hengelein@fau.de Cc: pebolle@tiscali.nl Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/10736/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/sibyte/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 47f2ac5058a19cbbe70bbccba13d104c60b35bff Author: James Hogan <james.hogan@imgtec.com> Date: Fri Jan 22 10:58:26 2016 +0000 MIPS: I6400: Icache fills from dcache Coherence Manager 3 (CM3) as present in I6400 can fill icache lines effectively from dirty dcaches, so there is no need to flush dirty lines from dcaches through to L2 prior to icache invalidation. Set the MIPS_CACHE_IC_F_DC flag such that cpu_has_ic_fills_f_dc evaluates to true, which avoids those dcache flushes. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Leonid Yegoshin <leonid.yegoshin@imgtec.com> Cc: Manuel Lauss <manuel.lauss@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12180/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 1 + 1 file changed, 1 insertion(+) commit b2a3c5be4d6df3b04781f430c2201cbbc9900f66 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Jan 22 10:58:25 2016 +0000 MIPS: c-r4k: Sync icache when it fills from dcache It is still necessary to handle icache coherency in flush_cache_range() and copy_to_user_page() when the icache fills from the dcache, even though the dcache does not need to be written back. However when this handling was added in commit 2eaa7ec286db ("[MIPS] Handle I-cache coherency in flush_cache_range()"), it did not do any icache flushing when it fills from dcache. Therefore fix r4k_flush_cache_range() to run local_r4k_flush_cache_range() without taking into account whether icache fills from dcache, so that the icache coherency gets handled. Checks are also added in local_r4k_flush_cache_range() so that the dcache blast doesn't take place when icache fills from dcache. A test to mmap a page PROT_READ|PROT_WRITE, modify code in it, and mprotect it to VM_READ|VM_EXEC (similar to case described in above commit) can hit this case quite easily to verify the fix. A similar check was added in commit f8829caee311 ("[MIPS] Fix aliasing bug in copy_to_user_page / copy_from_user_page"), so also fix copy_to_user_page() similarly, to call flush_cache_page() without taking into account whether icache fills from dcache, since flush_cache_page() already takes that into account to avoid performing a dcache flush. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Leonid Yegoshin <leonid.yegoshin@imgtec.com> Cc: Manuel Lauss <manuel.lauss@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12179/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/mm/c-r4k.c | 11 +++++++++-- arch/mips/mm/init.c | 2 +- 2 files changed, 10 insertions(+), 3 deletions(-) commit 679eb63779dffbd1fc40d4c218a4ff7c04508a48 Author: James Hogan <james.hogan@imgtec.com> Date: Tue Mar 1 22:19:37 2016 +0000 MIPS: Enable ptrace hw watchpoints on MIPS R6 HARDWARE_WATCHPOINTS isn't being enabled for CPU_MIPSR6, even though it has an identical hardware watchpoint interface to CPU_MIPSR2, which prevents ptrace watchpoints from being loaded when executing a ptraced process even though the watchpoints are described in /proc/cpuinfo. Enable HARDWARE_WATCHPOINTS for CPU_MIPSR6 too. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12727/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a7e89326b415b5d81c4b1016fd4a40db861eb58d Author: James Hogan <james.hogan@imgtec.com> Date: Tue Mar 1 22:19:36 2016 +0000 MIPS: Fix watchpoint restoration Commit f51246efee2b ("MIPS: Get rid of finish_arch_switch().") moved the __restore_watch() call from finish_arch_switch() (i.e. after resume() returns) to before the resume() call in switch_to(). This results in watchpoints only being restored when a task is descheduled, preventing the watchpoints from being effective most of the time, except due to chance before the watchpoints are lazily removed. Fix the call sequence from switch_to() through to mips_install_watch_registers() to pass the task_struct pointer of the next task, instead of using current. This allows the watchpoints for the next (non-current) task to be restored without reintroducing finish_arch_switch(). Fixes: f51246efee2b ("MIPS: Get rid of finish_arch_switch().") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 4.3.x- Patchwork: https://patchwork.linux-mips.org/patch/12726/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/switch_to.h | 2 +- arch/mips/include/asm/watch.h | 10 +++++----- arch/mips/kernel/pm.c | 2 +- arch/mips/kernel/watch.c | 5 ++--- 4 files changed, 9 insertions(+), 10 deletions(-) commit 81a76d7119f63c359750e4adeff922a31ad1135f Author: James Hogan <james.hogan@imgtec.com> Date: Fri Dec 4 22:25:02 2015 +0000 MIPS: Avoid using unwind_stack() with usermode When showing backtraces in response to traps, for example crashes and address errors (usually unaligned accesses) when they are set in debugfs to be reported, unwind_stack will be used if the PC was in the kernel text address range. However since EVA it is possible for user and kernel address ranges to overlap, and even without EVA userland can still trigger an address error by jumping to a KSeg0 address. Adjust the check to also ensure that it was running in kernel mode. I don't believe any harm can come of this problem, since unwind_stack() is sufficiently defensive, however it is only meant for unwinding kernel code, so to be correct it should use the raw backtracing instead. Signed-off-by: James Hogan <james.hogan@imgtec.com> Reviewed-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 3.15+ Patchwork: https://patchwork.linux-mips.org/patch/11701/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> (cherry picked from commit d2941a975ac745c607dfb590e92bb30bc352dad9) arch/mips/kernel/traps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a816b306c62195b7c43c92cb13330821a96bdc27 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Dec 4 22:25:01 2015 +0000 MIPS: Don't unwind to user mode with EVA When unwinding through IRQs and exceptions, the unwinding only continues if the PC is a kernel text address, however since EVA it is possible for user and kernel address ranges to overlap, potentially allowing unwinding to continue to user mode if the user PC happens to be in the kernel text address range. Adjust the check to also ensure that the register state from before the exception is actually running in kernel mode, i.e. !user_mode(regs). I don't believe any harm can come of this problem, since the PC is only output, the stack pointer is checked to ensure it resides within the task's stack page before it is dereferenced in search of the return address, and the return address register is similarly only output (if the PC is in a leaf function or the beginning of a non-leaf function). However unwind_stack() is only meant for unwinding kernel code, so to be correct the unwind should stop there. Signed-off-by: James Hogan <james.hogan@imgtec.com> Reviewed-by: Leonid Yegoshin <Leonid.Yegoshin@imgtec.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 3.15+ Patchwork: https://patchwork.linux-mips.org/patch/11700/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/process.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6cc0ee98b230b085e019f0c791af68a4f99e446 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Feb 3 18:14:53 2016 -0800 MIPS: BMIPS: Fill in current_cpu_data.core Read the core ID in bmips_smp_finish() for BMIPS5000 CPUs to get appropriate processor parenting in set_cpu_sibling_map(). Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: jaedon.shin@gmail.com Cc: dragan.stancevic@gmail.com Cc: jogo@openwrt.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12380/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/smp-bmips.c | 1 + 1 file changed, 1 insertion(+) commit 904c3b4952fff6d9d7a5e26b27d4a194b8f538d4 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Feb 3 18:14:52 2016 -0800 MIPS: BMIPS: Remove maxcpus from BCM97435SVMB DTS Now that SMP properly works on 7435, do not restrict the number of core, unleash them all. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: jaedon.shin@gmail.com Cc: dragan.stancevic@gmail.com Cc: jogo@openwrt.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12379/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm97435svmb.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a5b143ec51bbfda3dc385e51f8c404fb415be691 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Feb 3 18:14:51 2016 -0800 MIPS: BMIPS: Add missing 7038 L1 register cells to BCM7435 7435 has 4 7038 L1 base register address for each of its Core + TP (for a total of 4 threads of execution), add the two missing cells for Core 1. We are providing HW interrupts 2/3 even for Core 1/TP0/TP1 because that's what they are, and we can later decide to remap these in software to provide proper interrupt affinity/parenting. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: jaedon.shin@gmail.com Cc: dragan.stancevic@gmail.com Cc: jogo@openwrt.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12378/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/boot/dts/brcm/bcm7435.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit f241265fdcc37a171ba246780462e19960a49e7f Author: Ralf Baechle <ralf@linux-mips.org> Date: Wed Apr 13 01:17:57 2016 +0200 MIPS: BMIPS: Make whitespacely correct. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/bmips_5xxx_init.S | 272 ++++++++++++++++++------------------- 1 file changed, 136 insertions(+), 136 deletions(-) commit 21b30c00f3067001519eda166675c1958b163c91 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Feb 3 18:14:50 2016 -0800 MIPS: BMIPS: Add Whirlwind (BMIPS5200) initialization code Import bmips_5xxx_init.S from the stblinux-3.3 tree, and to make sure that this would work nicely with a BMIPS multiplatform kernel (with BMIPS330, BMIPS43XX and BMIPS5000 enabled), update soft_reset to check for the BMIPS5200 processor id (PRID_IMP_BMIPS5200) and execute bmips_5xxx_init for these processors to bring them online. Tested on 7425, 7429 and 7435 with CPU hotplug. 7435 SMP still needs some additional changes in the L1 interrupt area to work properly with interrupt affinity. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: linux-mips@linux-mips.org Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jon.fraser@broadcom.com Cc: jaedon.shin@gmail.com Cc: dragan.stancevic@gmail.com Cc: jogo@openwrt.org Patchwork: https://patchwork.linux-mips.org/patch/12377/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/Makefile | 2 +- arch/mips/kernel/bmips_5xxx_init.S | 753 +++++++++++++++++++++++++++++++++++++ arch/mips/kernel/bmips_vec.S | 41 +- 3 files changed, 792 insertions(+), 4 deletions(-) commit cbbda6e7c9c3e4532bd70a73ff9d5e6655c894dc Author: Florian Fainelli <f.fainelli@gmail.com> Date: Fri Jan 29 21:17:26 2016 -0800 MIPS: BMIPS: Fix PRID_IMP_BMIPS5000 masking for BMIPS5200 BMIPS5000 have a PrID value of 0x5A00 and BMIPS5200 have a PrID value of 0x5B00, which, masked with 0x5A00, returns 0x5A00. Update all conditionals on the PrID to cover both variants since we are going to need this to enable BMIPS5200 SMP. The existing check, masking with 0xFF00 would not cover BMIPS5200 at all. Fixes: 68e6a78373a6d ("MIPS: BMIPS: Add PRId for BMIPS5200 (Whirlwind)") Fixes: 6465460c92a85 ("MIPS: BMIPS: change compile time checks to runtime checks") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Cc: john@phrozen.org Cc: cernekee@gmail.com Cc: jogo@openwrt.org Cc: jaedon.shin@gmail.com Cc: jfraser@broadcom.com Cc: pgynther@google.com Cc: dragan.stancevic@gmail.com Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/12279/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/bmips_vec.S | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 578bffc82ec5332d97860ac529f90b0bcfaf8b5f Author: Paul Burton <paul.burton@imgtec.com> Date: Mon Apr 4 10:04:52 2016 +0100 MIPS: Don't BUG_ON when no IPI domain is found Commit fbde2d7d8290 ("MIPS: Add generic SMP IPI support") introduced code that BUG_ON's in the case of a kernel that supports IPI domains but does not have one at runtime. This case is possible on Malta where for IPIs we may use either the GIC (which has an IPI IRQ domain implementation) or core-local software interrupts between VPEs (which do not currently have an IPI IRQ domain implementation). We can not know which will be used until runtime when we know whether a GIC is actually present, and if we run on a system with multiple VPEs and no GIC then the BUG_ON is hit. Commit 19fb5818ed60 ("IPS: Fix broken malta qemu") worked around this for the single-core single-VPE case typically seen using QEMU, but does not catch the multi-VPE case. This patch removes the insufficient CPU presence check that was added and works around the bug differently, effectively reverting that commit. A simple way to reproduce this bug is by using QEMU, which partially implements the MT ASE but does not implement the GIC as of version 2.5. Using "-cpu 34Kf -smp 2" will present a system with 2 VPEs in one core & no GIC, hitting the BUG_ON. Given that we're post-merge-window on the way to v4.6, avoid this by just returning from mips_smp_ipi_init when no IPI IRQ domain is found. Ideally at some point all IPI implementations would be converted to the same IPI IRQ domain interface & we'd be able to restore the check. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Cc: Qais Yousef <qsyousef@gmail.com> Fixes: fbde2d7d8290 ("MIPS: Add generic SMP IPI support") Fixes: 19fb5818ed60 ("IPS: Fix broken malta qemu") Reverts: 19fb5818ed60 ("IPS: Fix broken malta qemu") Cc: Qais Yousef <qsyousef@gmail.com> Cc: James Hogan <james.hogan@imgtec.com> Cc: Alex Smith <alex.smith@imgtec.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/13007/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/smp.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit 5daebc477da4dfeb31ae193d83084def58fd2697 Author: James Hogan <james.hogan@imgtec.com> Date: Mon Feb 8 18:43:49 2016 +0000 MIPS: Fix siginfo.h to use strict posix types Commit 85efde6f4e0d ("make exported headers use strict posix types") changed the asm-generic siginfo.h to use the __kernel_* types, and commit 3a471cbc081b ("remove __KERNEL_STRICT_NAMES") make the internal types accessible only to the kernel, but the MIPS implementation hasn't been updated to match. Switch to proper types now so that the exported asm/siginfo.h won't produce quite so many compiler errors when included alone by a user program. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Christopher Ferris <cferris@google.com> Cc: linux-mips@linux-mips.org Cc: <stable@vger.kernel.org> # 2.6.30- Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/12477/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/uapi/asm/siginfo.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit c80e1b62ffca52e2d1d865ee58bc79c4c0c55005 Author: Corey Minyard <cminyard@mvista.com> Date: Mon Apr 11 09:10:19 2016 -0500 MIPS: Fix crash registers on non-crashing CPUs As part of handling a crash on an SMP system, an IPI is send to all other CPUs to save their current registers and stop. It was using task_pt_regs(current) to get the registers, but that will only be accurate if the CPU was interrupted running in userland. Instead allow the architecture to pass in the registers (all pass NULL now, but allow for the future) and then use get_irq_regs() which should be accurate as we are in an interrupt. Fall back to task_pt_regs(current) if nothing else is available. Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: David Daney <ddaney@caviumnetworks.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/13050/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/kernel/crash.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit e03ac9f0c3f5f2e79c41fd02d9b90831dfd78a2e Author: Nikolay Martynov <mar.kolya@gmail.com> Date: Tue Dec 8 13:27:02 2015 -0500 mips: Fix CPC_BASE_ADDR mask to match datasheet According to 'MIPS32® interAptivTM Multiprocessing System Programmer’s Guide' CPC_BASE_ADDR takes bits [31:15]. This change is tested ith mt7621 which wasn't working without it. Signed-off-by: Nikolay Martynov <mar.kolya@gmail.com> Reviewed-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/11766/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> arch/mips/include/asm/mips-cm.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit caee57ec71e1a0cb50b6028c706cfe541dcb080a Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:26:53 2016 +0200 pinctrl: nomadik: hide nmk_gpio_get_mode when unused nmk_gpio_get_mode is only used in one place, and that is conditionally compiled if DEBUG_FS is enabled. A recent cleanup has marked the definition 'static', which now leads to a warning: drivers/pinctrl/nomadik/pinctrl-nomadik.c:614:12: error: 'nmk_gpio_get_mode' defined but not used [-Werror=unused-function] static int nmk_gpio_get_mode(struct nmk_gpio_chip *nmk_chip, int offset) ^~~~~~~~~~~~~~~~~ Moving the function itself inside the #ifdef shuts it up again. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 5e81e0a0913c ("pinctrl: nomadik: use BIT() with offsets consequently") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/nomadik/pinctrl-nomadik.c | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) commit 8eb0dfdbda3f56bf7d248ed87fcc383df114ecbb Author: Adam Borowski <kilobyte@angband.pl> Date: Sun May 8 15:08:00 2016 +0200 btrfs: fix int32 overflow in shrink_delalloc(). UBSAN: Undefined behaviour in fs/btrfs/extent-tree.c:4623:21 signed integer overflow: 10808 * 262144 cannot be represented in type 'int [8]' If 8192<=items<16384, we request a writeback of an insane number of pages which is benign (everything will be written). But if items>=16384, the space reservation won't be enough. Signed-off-by: Adam Borowski <kilobyte@angband.pl> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent-tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9d814d410ddc61426a852b45ad514f3b924b9164 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:26:54 2016 +0200 pinctrl: ns2: rename pinctrl_utils_dt_free_map A conflict of two patches caused a build error when a function got renamed but a new user appeared in the other patch: drivers/pinctrl/bcm/pinctrl-ns2-mux.c:540:17: error: 'pinctrl_utils_dt_free_map' undeclared here (not in a function) .dt_free_map = pinctrl_utils_dt_free_map, ^~~~~~~~~~~~~~~~~~~~~~~~~ This renames the new user of pinctrl_utils_dt_free_map accordingly. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: d32f7fd3bbc3 ("pinctrl: Rename pinctrl_utils_dt_free_map to pinctrl_utils_free_map") Fixes: b5aa1006e4a9 ("pinctrl: ns2: add pinmux driver support for Broadcom NS2 SoC") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-ns2-mux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d0bc3483da8774dcea1e0692586830031783f08c Author: Joel Stanley <joel@jms.id.au> Date: Wed Apr 13 16:29:14 2016 +0930 arm/configs: Add Aspeed defconfig Signed-off-by: Joel Stanley <joel@jms.id.au> arch/arm/configs/aspeed_g4_defconfig | 86 +++++++++++++++++++++++++++++++++++ arch/arm/configs/aspeed_g5_defconfig | 88 ++++++++++++++++++++++++++++++++++++ 2 files changed, 174 insertions(+) commit 0d0f88969d7ee5ada0c9e951c811b63560be0a01 Author: Joel Stanley <joel@jms.id.au> Date: Mon May 9 19:08:05 2016 +0930 arm/configs/multi_v5: Add Aspeed ast2400 This adds the Aspeed ast2400 BMC SoC to the build. The SoC has six UARTs so we need to enable the appropriate options for SERIAL_8250 Signed-off-by: Joel Stanley <joel@jms.id.au> arch/arm/configs/multi_v5_defconfig | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 5bbd655a8bd000579d135ddf30660f759db89996 Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:16 2016 +0200 can: ifi: Add more detailed error reporting The updated specification for the IFI CANFD core contains description of more detailed error reporting capability of the core. Implement support for this detailed error reporting. Signed-off-by: Marek Vasut <marex@denx.de> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 113 ++++++++++++++++++++++++++++++++-- 1 file changed, 107 insertions(+), 6 deletions(-) commit 1acd80fb982728b8bf467184d5ec4c5a77a5601b Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:15 2016 +0200 can: ifi: Increment TX counters only on real transmission Only increment the TX counters in the irq handler if a CAN message was sent. The current code incremented the counters also if the TX FIFO empty interrupt happened, which is incorrect. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Oliver Hartkopp <socketcan@hartkopp.net> Cc: Wolfgang Grandegger <wg@grandegger.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit ca79408986bf250c22f3130c333787ec44c4d103 Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:14 2016 +0200 can: ifi: Treat CAN_CTRLMODE_FD_NON_ISO correctly The CAN_CTRLMODE_FD flag is set for both ISO and BOSCH CANFD mode, while the CAN_CTRLMODE_FD_NON_ISO is additional flag which is only set for CANFD-BOSCH mode. Fix the handling of the flags to reflect this. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Oliver Hartkopp <socketcan@hartkopp.net> Cc: Wolfgang Grandegger <wg@grandegger.com> Reviewed-by: Oliver Hartkopp <socketcan@hartkopp.net> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 478ad12c9f5a2f5a1d39fc898b098992980d3abc Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:13 2016 +0200 can: ifi: Unify timing constants There is no distinction between bittiming constants for the slow and fast part of the CANFD operation on this controller, so just use one single bittiming constant set. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Oliver Hartkopp <socketcan@hartkopp.net> Cc: Wolfgang Grandegger <wg@grandegger.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) commit be1861320a9ec599b6862ebb71db9bd3ad897150 Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:12 2016 +0200 can: ifi: Update timing configuration code The updated documentation regarding the IFI CANFD core from April 2016 adds more details regarding the timing calculation. There is no longer any distinction in the timing calculation between CANFD and CAN2.0, but instead there are two timing modes -- 4_12_6_6 and 7_9_8_8 -- where the numbers mean the width in bits of the SJW/Prescaler/TimeA/TimeB fields. The code uses 7_9_8_8 mode, which allows more fine-grained control over the timing. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Oliver Hartkopp <socketcan@hartkopp.net> Cc: Wolfgang Grandegger <wg@grandegger.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 54 ++++++++++++++--------------------- 1 file changed, 21 insertions(+), 33 deletions(-) commit 496c798db0b81af67572a2052ea30504c863235f Author: Marek Vasut <marex@denx.de> Date: Sun May 8 00:34:11 2016 +0200 can: ifi: Start NAPI poll on bus warning too Start the NAPI polling in case the bus warning interrupt happens, since it is the poll function which checks and reports the warning. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Oliver Hartkopp <socketcan@hartkopp.net> Cc: Wolfgang Grandegger <wg@grandegger.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/ifi_canfd/ifi_canfd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 2fe6c943147c5bb0550f5c3e941de3824986330e Author: Maximilian Schneider <max@schneidersoft.net> Date: Mon Apr 25 08:54:19 2016 +0000 can: gs_usb: modify the usb device table to use only the first usb interface Modified the USB device table to use only the first USB interface, as is the case with GS USB devices. This allows other GS USB compatible devices to be more flexible with their remaining interfaces. Signed-off-by: Maximilian Schneider <max@schneidersoft.net> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/usb/gs_usb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b16e368ed6193d8d1774b4cc874d7892d55c4780 Author: Andreas Gröger <andreas24groeger@gmail.com> Date: Fri May 6 10:04:37 2016 +0200 can: janz-ican3: error handling for CAL/CANopen firmware My patch of May 2015 was missing the changed handling of error indications. With CAL/CANopen firmware the NMTS-SlaveEventIndication must be used instead of CAN-EventIndication. An appropriate slave node must be configured to report the errors. In our department (about 15 development systems with Janz ICAN3- modules with firmware 1.48, my system also with firmware ICANOS 1.35) we use the driver with this patch for about one year: no known problems. Signed-off-by: Andreas Gröger <andreas24groeger@gmail.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/janz-ican3.c | 104 +++++++++++++++++++++++++++++++++++++++---- 1 file changed, 95 insertions(+), 9 deletions(-) commit bb208f144cf3f59d8f89a09a80efd04389718907 Author: Oliver Hartkopp <socketcan@hartkopp.net> Date: Mon Mar 21 20:18:21 2016 +0100 can: fix handling of unmodifiable configuration options As described in 'can: m_can: tag current CAN FD controllers as non-ISO' (6cfda7fbebe) it is possible to define fixed configuration options by setting the according bit in 'ctrlmode' and clear it in 'ctrlmode_supported'. This leads to the incovenience that the fixed configuration bits can not be passed by netlink even when they have the correct values (e.g. non-ISO, FD). This patch fixes that issue and not only allows fixed set bit values to be set again but now requires(!) to provide these fixed values at configuration time. A valid CAN FD configuration consists of a nominal/arbitration bittiming, a data bittiming and a control mode with CAN_CTRLMODE_FD set - which is now enforced by a new can_validate() function. This fix additionally removed the inconsistency that was prohibiting the support of 'CANFD-only' controller drivers, like the RCar CAN FD. For this reason a new helper can_set_static_ctrlmode() has been introduced to provide a proper interface to handle static enabled CAN controller options. Reported-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net> Reviewed-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Cc: <stable@vger.kernel.org> # >= 3.18 Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/dev.c | 56 +++++++++++++++++++++++++++++++++++++++---- drivers/net/can/m_can/m_can.c | 2 +- include/linux/can/dev.h | 22 +++++++++++++++-- 3 files changed, 73 insertions(+), 7 deletions(-) commit b6fd3aba6041922e115bd8e10539b8545f4120ac Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Fri Apr 8 21:02:10 2016 +0530 can: mcp251x: Replace create_freezable_workqueue with alloc_workqueue Replace scheduled to be removed create_freezable_workqueue with alloc_workqueue. priv->wq should be explicitly set as freezable to ensure it is frozen in the suspend sequence and work items are drained so that no new work item starts execution until thawed. Thus, use of WQ_FREEZABLE flag here is required. WQ_MEM_RECLAIM flag has been set here to ensure forward progress regardless of memory pressure. The order of execution is not important so set @max_active as 0. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/spi/mcp251x.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 056a7201ac7a659880b43c2e62a5aa85ca06bebf Author: Nikita Edward Baruzdin <nebaruzdin@gmail.com> Date: Wed Apr 6 16:04:32 2016 +0300 can: sja1000: plx_pci: Add support for Marathon CAN-bus-PCIe card This patch adds support for the Marathon CAN-bus-PCIe card to the sja1000 driver. For more information see: http://can.marathon.ru/page/devices/can-bus-pcie Signed-off-by: Nikita Edward Baruzdin <nebaruzdin@gmail.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/sja1000/plx_pci.c | 64 ++++++++++++++++++++++++++++++++++----- 1 file changed, 56 insertions(+), 8 deletions(-) commit 3e51a3356cb2a1a35c07607f93d79484b1496bbf Author: Alexander Gerasiov <gq@cs.msu.su> Date: Fri Apr 1 19:16:45 2016 +0300 can: sja1000: Fix error location forwarding According to SJA1000 documentation the location of error is available regardless of an error type. Therefore it should always be forwarded to SocketCAN. Signed-off-by: Nikita Edward Baruzdin <nebaruzdin@lvk.cs.msu.su> Signed-off-by: Alexander GQ Gerasiov <gq@cs.msu.su> Acked-by: Oliver Hartkopp <socketcan@hartkopp.net> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> drivers/net/can/sja1000/sja1000.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 02440622656d26a0d68308db9e4ce1d2510f6530 Author: Joel Stanley <joel@jms.id.au> Date: Sun Apr 17 15:50:56 2016 +0930 arm/dst: Add Aspeed ast2500 device tree This adds a common device tree for all fifth generation Aspeed systems, and a board specific device tree for the ast2500 evaluation board. Signed-off-by: Joel Stanley <joel@jms.id.au> arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/aspeed-ast2500-evb.dts | 25 +++++ arch/arm/boot/dts/aspeed-g5.dtsi | 170 +++++++++++++++++++++++++++++++ 3 files changed, 197 insertions(+), 1 deletion(-) commit d44a1138cd829d232899ef4fe5cd59e861ed3984 Author: Joel Stanley <joel@jms.id.au> Date: Wed Mar 16 22:03:37 2016 +1030 arm/dts: Add Aspeed ast2400 device tree A common device tree for all forth gen/ast2400 systems and a board specific dts for the Palmetto OpenPower developemnt machine which was used for testing. Signed-off-by: Joel Stanley <joel@jms.id.au> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/aspeed-bmc-opp-palmetto.dts | 25 ++++ arch/arm/boot/dts/aspeed-g4.dtsi | 161 ++++++++++++++++++++++++++ 3 files changed, 187 insertions(+) commit 8c2ed9bcfbeb7f313b567b25e87effd75e7dc3d6 Author: Joel Stanley <joel@jms.id.au> Date: Mon Mar 21 17:22:31 2016 +1030 arm: Add Aspeed machine Aspeed devices are a common Baseboard Management Controller (BMC) system on chip containing an ARM9 or ARM11 core, off-chip DDR RAM and support for a large number of peripherals. This patch adds basic support for the ast2400 and ast2500 machines, capable of booting to a prompt in QEMU (-M palmetto-bmc), on an Palmetto OpenPower development machine, and on the ast2500 EVB. Signed-off-by: Joel Stanley <joel@jms.id.au> MAINTAINERS | 7 +++++++ arch/arm/Kconfig | 2 ++ arch/arm/mach-aspeed/Kconfig | 30 ++++++++++++++++++++++++++++++ 3 files changed, 39 insertions(+) commit 10ee08292028d3d22d201a34ba7d24a085818cb3 Merge: 7da4b8b 44549e8 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon May 9 09:39:13 2016 +0200 Merge 4.6-rc7 into tty-next We want the pty fixes in here as well so that patches can build on it. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit 725d0123dfff3d7b666cf57f5d29c50addfc99d3 Merge: 8cd1f9d 44549e8 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon May 9 09:34:49 2016 +0200 Merge 4.6-rc7 into char-misc-testing This resolves a merge issue with drivers/hv/ring_buffer.c Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit 7844b8927e78bfb060ba88c36c99d3e07c3fb631 Merge: 545feef 44549e8 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon May 9 09:29:13 2016 +0200 Merge 4.6-rc7 into usb-next We want the USB fixes in here to resolve merge issues and make it easier for testing. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit 545feeff158e03318bfaf34d0877da7ebfea3540 Merge: 792f752 74d2a91 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon May 9 09:26:56 2016 +0200 Merge tag 'usb-serial-4.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial into usb-next Johan writes: USB-serial fixes for v4.6-rc7 Here are some more new device ids. Signed-off-by: Johan Hovold <johan@kernel.org> commit 0bbfb87c567d982fd698b41e9fb68478727460f9 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:55:52 2016 +0530 mfd: as3722: Use devm_mfd_add_devices and devm_regmap_add_irq_chip Use devm_mfd_add_devices() for adding MFD child devices and devm_regmap_add_irq_chip() for IRQ chip registration. This reduces the error code path and .remove callback for removing MFD child devices and deleting IRQ chip data. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/as3722.c | 31 +++++++++---------------------- 1 file changed, 9 insertions(+), 22 deletions(-) commit ae9810e275d5847ded7e1cbcf231c3fcf95b6e52 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Mon Apr 25 13:06:32 2016 -0400 mfd: twl4030-power: Remove driver path in file comment The driver's file path in the comment is wrong, so just remove it since these tends to get out of date and they serve very little purpose. Suggested-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/twl4030-power.c | 1 - 1 file changed, 1 deletion(-) commit 39ac9f48f63acefbcd0f2c6eece89915565d6a59 Author: Chen-Yu Tsai <wens@csie.org> Date: Tue Mar 29 17:22:24 2016 +0800 MAINTAINERS: Add entry for X-Powers AXP family PMIC drivers Add an entry for X-Powers AXP family PMIC drivers and list myself as maintainer. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> MAINTAINERS | 6 ++++++ 1 file changed, 6 insertions(+) commit 030ab2beb4cb045891395bb5e849cf583193b5fb Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Thu Apr 21 17:45:39 2016 +0530 mfd: smsc-ece1099: Remove unnecessarily remove callback SMSC MFD driver does not add any MFD child devices via mfd_add_devices() and hence it is not required to call mfd_remove_devices() to remove MFD child devices. Remove the call of the API mfd_remove_devices() which will result as remove of .remove callback for driver. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Sourav Poddar <sourav.poddar@ti.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/smsc-ece1099.c | 10 ---------- 1 file changed, 10 deletions(-) commit 5eb519f3f6df367d43ec0c6e063fd62943fe4dcf Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 13:45:46 2016 -0400 mfd: Use IS_ENABLED(CONFIG_FOO) instead of checking FOO || FOO_MODULE The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/dm355evm_msp.c | 8 ++++---- drivers/mfd/wm8400-core.c | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) commit d6441dc5ce2bc8b296a65952d840d2f16e37f974 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 11:16:37 2016 -0400 mfd: twl6040: Disable and unprepare clk32k in twl6040_power() error path The clk32k clock is prepared and enabled in twl6040_power() but the clock is left enabled in case of an error while it should be disable/unprepared. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/twl6040.c | 2 ++ 1 file changed, 2 insertions(+) commit 32852bcab29d8d43c5d4ddeed9937817e8e8c990 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 11:16:38 2016 -0400 mfd: twl6040: Check clk_prepare_enable() return value in twl6040_power() The clk_prepare_enable() function can fail so check the return value and propagate the error in case of a failure. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/twl6040.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 38fc2eec95a750f2a69d82307ab721265e34939f Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 20 17:40:55 2016 +0100 mfd: tps6105x: Remove linux/regulator/driver.h include This driver makes no use of linux/regulator/driver.h which should only be used by drivers implementing a regulator. Since it's unlikely to ever need anything from there remove the include. Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps6105x.c | 1 - 1 file changed, 1 deletion(-) commit 36a0c08848285bb12ed8b83f5eec4a92a5efadf9 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:19:20 2016 -0700 mfd: intel_quark_i2c_gpio: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel_quark_i2c_gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0f7e70e7da0a09d9d0a814f17272ea7da7855f64 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:20:49 2016 -0700 mfd: intel-lpss: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel-lpss.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 41a3da2b8e1639d983192e3650670df4ecc94cf7 Author: Heikki Krogerus <heikki.krogerus@linux.intel.com> Date: Mon Apr 18 15:14:56 2016 +0300 mfd: intel-lpss: Save register context on suspend All configurations are lost and the registers will have default values when the hardware is suspended and resumed, so saving the private register space context on suspend, and restoring it on resume. Fixes: 4b45efe85263 (mfd: Add support for Intel Sunrisepoint LPSS devices) Cc: stable@vger.kernel.org # v4.3+ Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel-lpss.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) commit 0e10d549f6eebd0a26bf075309b6fb947f4c1cb2 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 15 17:44:18 2016 +0300 mfd: wm8400-core: Delete wm8400_reg_read() There was a static checker warning in wm8400_reg_read() because we were returning u16 and that can't hold the negative error codes. The function isn't used, so let's just delete it. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/wm8400-core.c | 21 --------------------- include/linux/mfd/wm8400-private.h | 1 - 2 files changed, 22 deletions(-) commit f83c218c1705a0d38fb9791bdee268c4092a37cb Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Fri Apr 15 13:18:47 2016 +0100 mfd: arizona: Update device ordering to allow clean driver removal Since this commit: commit b9a8a271c38f ("mfd: make mfd_remove_devices() iterate in reverse order") The order in which the MFD children remove has been reversed, as our driver contains some dependencies between the devices we need to make some changes to ensure the driver unloads cleanly. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/arizona-core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 1387ff53568ba409eef072087fa02359b3a3551b Author: Henry Chen <henryc.chen@mediatek.com> Date: Fri Apr 15 16:30:29 2016 +0800 mfd: mt6397: IRQ domain should initialize before mfd_add_devices() Some sub driver like RTC module need irq domain from parent to create irq mapping when driver initialize. so move mt6397_irq_init() before mfd_add_devices(). Acked-by: John Crispin <blogic@openwrt.org> Signed-off-by: Henry Chen <henryc.chen@mediatek.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/mt6397-core.c | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) commit 58fe9c4621b7219e724c0b7af053112f974a08c3 Author: Davidlohr Bueso <dave@stgolabs.net> Date: Sun May 8 20:58:10 2016 -0700 sched/core: Fix comment typo in wake_q_add() ... the comment clearly refers to wake_up_q(), and not wake_up_list(). Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: dave@stgolabs.net Link: http://lkml.kernel.org/r/1462766290-28664-1-git-send-email-dave@stgolabs.net Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8c5e95548d41a48b1eb2be741107a259251ebd86 Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Thu May 5 15:21:19 2016 +0530 sched/core: Remove unused variable Remove unused variable 'ret', and directly return 0. Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462441879-10092-1-git-send-email-falakreyaz@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 908578e7d5f69087241434c872f8f4a8ab70045f Merge: 59efcba c66b258 Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 00:15:31 2016 -0400 Merge branch 'sh_eth-sw-reset' Sergei Shtylyov says: ==================== sh_eth: couple of software reset bit cleanups Here's a set of 2 patches against DaveM's 'net-next.git' repo. We can save on the repetitive chip reset code... [1/2] sh_eth: call sh_eth_tsu_write() from sh_eth_chip_reset_giga() [2/2] sh_eth: reuse sh_eth_chip_reset() ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c66b2581123cd1527b6a084f39e9271cb02673b7 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sat May 7 14:09:01 2016 -0700 sh_eth: reuse sh_eth_chip_reset() All the chip_reset() methods repeat the code writing to the ARSTR register and delaying for 1 ms, so that we can reuse sh_eth_chip_reset() twice. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/sh_eth.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 7927092253da598331542bdedb8fd5612f161f80 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun May 8 00:08:05 2016 +0300 sh_eth: call sh_eth_tsu_write() from sh_eth_chip_reset_giga() sh_eth_chip_reset_giga() doesn't really need to use direct iowrite32() when writing to the ARSTR register, it can use sh_eth_tsu_write() as all other chip_reset() methods. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/sh_eth.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 59efcbaf434964f324928619fcd0a6f506134753 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sat May 7 22:53:40 2016 +0300 pxa168_eth: mdiobus_scan() doesn't return NULL anymore Now that mdiobus_scan() doesn't return NULL on failure anymore, this driver no longer needs to check for it... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/marvell/pxa168_eth.c | 2 -- 1 file changed, 2 deletions(-) commit 7c878bb3183067b741ecac745000ed8e7e3b2782 Merge: b75803d a0af53b Author: David S. Miller <davem@davemloft.net> Date: Mon May 9 00:10:00 2016 -0400 Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next Johan Hedberg says: ==================== pull request: bluetooth-next 2016-05-07 Here are a few more Bluetooth patches for the 4.7 kernel: - NULL pointer fix in hci_intel driver - New Intel Bluetooth controller id in btusb driver - Added device tree binding documentation for Marvel's bt-sd8xxx - Platform specific wakeup interrupt support for btmrvl driver Please let me know if there are any issues pulling. Thanks. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b75803d52a2ce1f6cbaf7ae0ae40a369210070cf Author: Lawrence Brakmo <brakmo@fb.com> Date: Fri May 6 20:35:35 2016 -0700 tcp: refactor struct tcp_skb_cb Refactor tcp_skb_cb to create two overlaping areas to store state for incoming or outgoing skbs based on comments by Neal Cardwell to tcp_nv patch: AFAICT this patch would not require an increase in the size of sk_buff cb[] if it were to take advantage of the fact that the tcp_skb_cb header.h4 and header.h6 fields are only used in the packet reception code path, and this in_flight field is only used on the transmit side. Signed-off-by: Lawrence Brakmo <brakmo@fb.com> Acked-by: Yuchung Cheng <ycheng@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 966657890e874d3b01d94b1ec156b7da54ba99b0 Author: Noam Camus <noamc@ezchip.com> Date: Fri Oct 16 16:52:43 2015 +0300 ARC: Add eznps platform to Kconfig and Makefile This commit should be left last since only now eznps platform is in state which one can actually use. Signed-off-by: Noam Camus <noamc@ezchip.com> arch/arc/Kconfig | 1 + arch/arc/Makefile | 5 +++++ 2 files changed, 6 insertions(+) commit 085572f3cc88cf223f0dfdee2dcbb0672e938527 Author: Noam Camus <noamc@ezchip.com> Date: Fri May 29 11:40:02 2015 +0300 ARC: [plat-eznps] Use dedicated COMMAND_LINE_SIZE The default 256 bytes sometimes is just not enough. We usually provide earlycon=... and console=... and ip=... All this and more may need more room. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/setup.h | 4 ++++ 1 file changed, 4 insertions(+) commit 46c3e6b8768643d9bc7325324d17e37781b7bbf8 Author: Tal Zilcer <talz@ezchip.com> Date: Mon Mar 9 16:58:39 2015 +0200 ARC: [plat-eznps] Use dedicated cpu_relax() Since the CTOP is SMT hardware multi-threaded, we need to hint the HW that now will be a very good time to do a hardware thread context switching. This is done by issuing the schd.rw instruction (binary coded here so as to not require specific revision of GCC to build the kernel). sched.rw means that Thread becomes eligible for execution by the threads scheduler after all pending read/write transactions were completed. Implementing cpu_relax_lowlatency() with barrier() Since with current semantics of cpu_relax() it may take a while till yielded CPU will get back. Signed-off-by: Noam Camus <noamc@ezchip.com> Cc: Peter Zijlstra <peterz@infradead.org> Acked-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/processor.h | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 86c25466f7414d6396f1aaa13e4b34f36ec272d5 Author: Noam Camus <noamc@ezchip.com> Date: Mon Jun 3 15:17:25 2013 +0300 ARC: [plat-eznps] Use dedicated identity auxiliary register. With generic "identity" num of CPUs is limited to 256 (8 bit). We use our alternative AUX register GLOBAL_ID (12 bit). Now we can support up to 4096 CPUs. Signed-off-by: Noam Camus <noamc@ezchip.com> arch/arc/include/asm/entry-compact.h | 6 ++++++ arch/arc/kernel/ctx_sw.c | 13 +++++++++++++ arch/arc/plat-eznps/include/plat/ctop.h | 9 +++++++++ 3 files changed, 28 insertions(+) commit b1f2f6f3cf5e37f0418f6cebf365cff7c3abf6d7 Author: Noam Camus <noamc@ezchip.com> Date: Fri Apr 10 21:28:50 2015 +0300 ARC: [plat-eznps] Use dedicated SMP barriers NPS device got 256 cores and each got 16 HW threads (SMT). We use EZchip dedicated ISA to trigger HW scheduler of the core that current HW thread belongs to. This scheduling makes sure that data beyond barrier is available to all HW threads in core and by that to all in device (4K). Signed-off-by: Noam Camus <noamc@ezchip.com> Cc: Peter Zijlstra <peterz@infradead.org> arch/arc/include/asm/barrier.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit a5a10d99a946602cf4ae50eadc65c2480dbd2e56 Author: Noam Camus <noamc@ezchip.com> Date: Sat May 16 17:49:35 2015 +0300 ARC: [plat-eznps] Use dedicated atomic/bitops/cmpxchg We need our own implementaions since we lack LLSC support. Our extended ISA provided with optimized solution for all 32bit operations we see in these three headers. Signed-off-by: Noam Camus <noamc@ezchip.com> arch/arc/include/asm/atomic.h | 83 ++++++++++++++++++++++++++++++++++++++++-- arch/arc/include/asm/bitops.h | 60 ++++++++++++++++++++++++++++-- arch/arc/include/asm/cmpxchg.h | 76 ++++++++++++++++++++++++++++++++++---- 3 files changed, 205 insertions(+), 14 deletions(-) commit 8bcf2c48f32e22f923b69f779c95b1348308d5b1 Author: Noam Camus <noamc@ezchip.com> Date: Sun Dec 6 15:40:55 2015 +0200 ARC: [plat-eznps] Use dedicated user stack top NPS use special mapping right below TASK_SIZE. Hence we need to lower STACK_TOP so that user stack won't overlap NPS special mapping. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/processor.h | 18 ++++++++++++++++++ arch/arc/mm/tlb.c | 6 ++++++ 2 files changed, 24 insertions(+) commit 4a66d3fecf6554c4e1482774833da4f07cade787 Author: Noam Camus <noamc@ezchip.com> Date: Sun Aug 19 11:54:33 2012 +0300 ARC: [plat-eznps] Add eznps platform This platform include boards: Hardware Emulator (HE) Simulator based upon nSIM. Signed-off-by: Noam Camus <noamc@ezchip.com> MAINTAINERS | 6 + arch/arc/plat-eznps/Kconfig | 35 ++++++ arch/arc/plat-eznps/Makefile | 7 ++ arch/arc/plat-eznps/entry.S | 70 +++++++++++ arch/arc/plat-eznps/include/plat/ctop.h | 200 ++++++++++++++++++++++++++++++++ arch/arc/plat-eznps/include/plat/mtm.h | 60 ++++++++++ arch/arc/plat-eznps/include/plat/smp.h | 26 +++++ arch/arc/plat-eznps/mtm.c | 133 +++++++++++++++++++++ arch/arc/plat-eznps/platform.c | 102 ++++++++++++++++ arch/arc/plat-eznps/smp.c | 155 +++++++++++++++++++++++++ 10 files changed, 794 insertions(+) commit 845033be0041d1f8c8c691dbd54223d425c9ace5 Author: Noam Camus <noamc@ezchip.com> Date: Mon Sep 10 16:00:48 2012 +0300 ARC: [plat-eznps] Add eznps board defconfig and dts Adding default configuration file and DTS file Signed-off-by: Noam Camus <noamc@ezchip.com> arch/arc/boot/dts/eznps.dts | 96 ++++++++++++++++++++++++++++++++++++++++++ arch/arc/configs/nps_defconfig | 84 ++++++++++++++++++++++++++++++++++++ 2 files changed, 180 insertions(+) commit 71f9cf8fdd72e5f5c3a60f632bd1534fc7996b81 Author: Noam Camus <noamc@ezchip.com> Date: Sat Nov 7 09:16:19 2015 +0200 ARC: Mark secondary cpu online only after all HW setup is done In SMP setup, master loops for each_present_cpu calling cpu_up(). For ARC it returns as soon as new cpu's status becomes online, However secondary may still do HW initializing, machine or platform hook level. So turn secondary online only after all HW setup is done. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/smp.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 2a1021fce85cb9867f3655c58a9c826a3612fae9 Author: Noam Camus <noamc@ezchip.com> Date: Tue Jun 9 14:05:50 2015 +0300 ARC: rwlock: disable interrupts in !LLSC variant If we hold rwlock and interrupt occures we may end up spinning on it for ever during softirq. Note that this lock is an internal lock and since the lock is free to be used from any context, the lock needs to be IRQ-safe. Below you may see an example for interrupt we get while nl_table_lock is holding its rw->lock_mutex and we spinned on it for ever. The concept for the fix was taken from SPARC. [2015-05-12 19:16:12] Stack Trace: [2015-05-12 19:16:12] arc_unwind_core+0xb8/0x11c [2015-05-12 19:16:12] dump_stack+0x68/0xac [2015-05-12 19:16:12] _raw_read_lock+0xa8/0xac [2015-05-12 19:16:12] netlink_broadcast_filtered+0x56/0x35c [2015-05-12 19:16:12] nlmsg_notify+0x42/0xa4 [2015-05-12 19:16:13] neigh_update+0x1fe/0x44c [2015-05-12 19:16:13] neigh_event_ns+0x40/0xa4 [2015-05-12 19:16:13] arp_process+0x46e/0x5a8 [2015-05-12 19:16:13] __netif_receive_skb_core+0x358/0x500 [2015-05-12 19:16:13] process_backlog+0x92/0x154 [2015-05-12 19:16:13] net_rx_action+0xb8/0x188 [2015-05-12 19:16:13] __do_softirq+0xda/0x1d8 [2015-05-12 19:16:14] irq_exit+0x8a/0x8c [2015-05-12 19:16:14] arch_do_IRQ+0x6c/0xa8 [2015-05-12 19:16:14] handle_interrupt_level1+0xe4/0xf0 Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Peter Zijlstra <peterz@infradead.org> arch/arc/include/asm/spinlock.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 15ca68a993d10767c37793e6a0a780b0a7e395dd Author: Noam Camus <noamc@ezchip.com> Date: Sun Sep 7 22:52:33 2014 +0300 ARC: Make vmalloc size configurable On ARC, lower 2G of address space is translated and used for - user vaddr space (region 0 to 5) - unused kernel-user gutter (region 6) - kernel vaddr space (region 7) where each region simply represents 256MB of address space. The kernel vaddr space of 256MB is used to implement vmalloc, modules So far this was enough, but not on EZChip system with 4K CPUs (given that per cpu mechanism uses vmalloc for allocating chunks) So allow VMALLOC_SIZE to be configurable by expanding down into the unused kernel-user gutter region which at default 256M was excessive anyways. Also use _BITUL() to fix a build error since PGDIR_SIZE cannot use "1UL" as called from assembly code in mm/tlbex.S Signed-off-by: Noam Camus <noamc@ezchip.com> [vgupta: rewrote changelog, debugged bootup crash due to int vs. hex] Acked-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 11 +++++++++++ arch/arc/include/asm/pgtable.h | 2 +- arch/arc/include/asm/processor.h | 19 +++++++++---------- arch/arc/mm/tlb.c | 5 +++++ 4 files changed, 26 insertions(+), 11 deletions(-) commit 4bb40c6d6c011dc616d6d7fbad2bce21794f97a0 Author: Noam Camus <noamc@ezchip.com> Date: Wed Jan 13 01:58:38 2016 +0000 ARC: clean out UAPI byteorder.h clean off Kconfig symbol UAPI header should not use Kconfig items Use __BIG_ENDIAN__ defined as a compiler intrinsic Signed-off-by: Noam Camus <noamc@ezchip.com> [vgupta: fix changelog] Signed-off-by: Vineet Gupta <vgupta@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/uapi/asm/byteorder.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44df427c894a4357e43bb35769baefa7cdf09833 Author: Noam Camus <noamc@ezchip.com> Date: Thu Oct 29 00:26:22 2015 +0200 irqchip: add nps Internal and external irqchips Adding EZchip NPS400 support. Internal interrupts are handled by Multi Thread Manager (MTM) Once interrupt is serviced MTM is acked for deactivating the interrupt. External interrupts are handled by MTM as well as at Global Interrupt Controller (GIC) e.g. serial and network devices. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> Acked-by: Jason Cooper <jason@lakedaemon.net> Cc: Thomas Gleixner <tglx@linutronix.de> .../interrupt-controller/ezchip,nps400-ic.txt | 17 +++ drivers/irqchip/Kconfig | 6 + drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-eznps.c | 165 +++++++++++++++++++++ 4 files changed, 189 insertions(+) commit a53224577e317d010f61aa1b1b8b18f2b168a137 Author: Noam Camus <noamc@ezchip.com> Date: Sat Oct 17 22:37:30 2015 +0300 clocksource: Add NPS400 timers driver Add internal tick generator which is shared by all cores. Each cluster of cores view it through dedicated address. This is used for SMP system where all CPUs synced by same clock source. Signed-off-by: Noam Camus <noamc@ezchip.com> Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Rob Herring <robh+dt@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: John Stultz <john.stultz@linaro.org> Acked-by: Vineet Gupta <vgupta@synopsys.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> .../bindings/timer/ezchip,nps400-timer.txt | 15 ++++ drivers/clocksource/Kconfig | 10 +++ drivers/clocksource/Makefile | 1 + drivers/clocksource/timer-nps.c | 98 ++++++++++++++++++++++ 4 files changed, 124 insertions(+) commit ebc326be87e5989a878872cd3e42cc0061458ab7 Author: Noam Camus <noamc@ezchip.com> Date: Sun Dec 6 09:00:56 2015 +0200 soc: Support for EZchip SoC This header file is for NPS400 SoC. It includes macros for accessing memory mapped registers. These are functional registers that core can use to configure SoC. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Acked-by: Vineet Gupta <vgupta@synopsys.com> include/soc/nps/common.h | 166 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 166 insertions(+) commit 37f0e658eeeac720f3d558cf5aaf9edf0705ff23 Author: Noam Camus <noamc@ezchip.com> Date: Wed Apr 29 15:07:43 2015 +0300 Documentation: Add EZchip vendor to binding list Add EZchip to vendor prefixes list. EZchip introduce the NPS platform for the ARC architecture. Signed-off-by: Noam Camus <noamc@ezchip.com> Acked-by: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Documentation/devicetree/bindings/arc/eznps.txt | 7 +++++++ Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 2 files changed, 8 insertions(+) commit 6e9318d1be83714e004a0ac795a936df4d2bed3e Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Mon Feb 1 17:30:17 2016 +0300 ARC: RIP arc_{get|set}_core_freq() clk API There are no more users of this - so RIP! Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> [vgupta: update changelog] Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/clk.h | 22 ---------------------- arch/arc/kernel/Makefile | 2 +- arch/arc/kernel/clk.c | 21 --------------------- arch/arc/kernel/devtree.c | 7 ------- 4 files changed, 1 insertion(+), 51 deletions(-) commit 20c7dbbdbe12db75f9e9ac3fd0d713ab95549623 Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Mon Feb 1 17:30:17 2016 +0300 ARC: Don't try to use value of top level clock-frequency in DT We no longer use it and instead a real clk device such as fixed-clk instance is fed to timers etc. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> [vgupta: broken out of a bigger patch, rewrote changelog] Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/setup.c | 12 +++++++----- arch/arc/plat-axs10x/axs10x.c | 2 -- 2 files changed, 7 insertions(+), 7 deletions(-) commit 0e6e9b648d802fe6641fe543b6dc4828baded159 Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Mon Feb 1 16:31:14 2016 +0300 ARC: use fixed frequencies in arc_set_early_base_baud() UARTs usually have fixed clock so we're switching to use of constant values instead of something derived from core clock frequency. Among other things this will allow us to get rid of arc_{get|set}_core_freq() and switch to generic clock framework later on. Acked-by: Christian Ruppert <christian.ruppert@alitech.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/devtree.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit d21beffb0b9181c8823f71a5a7fabce6a0d4cf29 Author: Vineet Gupta <vgupta@synopsys.com> Date: Thu Jan 28 09:40:10 2016 +0530 ARC: [intc-*] switch to linear domain Now that we have Timers probed from DT, don't need legacy domain This however requires mapping to be called explicitly for the IRQ which still can't (and probably never) be probed from DT such as IPI and SOFTIRQ Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/intc-arcv2.c | 8 ++++++-- arch/arc/kernel/intc-compact.c | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) commit 1b0ccb8a4eee2d8c14adc996e07335cb7aa9e2ac Author: Vineet Gupta <vgupta@synopsys.com> Date: Fri Jan 1 15:12:54 2016 +0530 ARC: [intc-*] Do a domain lookup in primary handler for hwirq -> linux virq The primary interrupt handler arch_do_IRQ() was passing hwirq as linux virq to core code. This was fragile and worked so far as we only had legacy/linear domains. This came out of a rant by Marc Zyngier. http://lists.infradead.org/pipermail/linux-snps-arc/2015-December/000298.html Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Noam Camus <noamc@ezchip.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 1 + arch/arc/kernel/intc-arcv2.c | 9 ++++++--- arch/arc/kernel/intc-compact.c | 10 ++++++---- arch/arc/kernel/irq.c | 9 ++------- 4 files changed, 15 insertions(+), 14 deletions(-) commit 88555cc584d93e658722f090d3f8fb84d5fa15a5 Author: Vineet Gupta <vgupta@synopsys.com> Date: Wed Mar 30 18:35:28 2016 +0530 ARC: irq: export some IRQs again This will be needed for switching to linear irq domain as irq_create_mapping() called by intr code needs the IRQ numbers in addition to existing usage in mcip.c for requesting the irq Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/irq.h | 6 ++++++ arch/arc/kernel/mcip.c | 3 --- 2 files changed, 6 insertions(+), 3 deletions(-) commit e608b53ea863a92eb458cb1ec7c2fcf3ca2b043a Author: Vineet Gupta <vgupta@synopsys.com> Date: Fri Jan 1 18:05:48 2016 +0530 ARC: clocksource: DT based probe - Remove explicit clocksource setup and let it be done by OF framework by defining CLOCKSOURCE_OF_DECLARE() for various timers - This allows multiple clocksources to be potentially registered simultaneouly: previously we could only do one - as all of them had same arc_counter_setup() routine for registration - Setup routines also ensure that the underlying timer actually exists. - Remove some of the panic() calls if underlying timer is NOT detected as fallback clocksource might still be available 1. If GRFC doesn't exist, jiffies clocksource gets registered anyways 2. if RTC doesn't exist, TIMER1 can take over (as it is always present) Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/mcip.c | 4 +- arch/arc/kernel/setup.c | 3 -- arch/arc/kernel/time.c | 134 +++++++++++++++++++++++++++++------------------- 3 files changed, 82 insertions(+), 59 deletions(-) commit 77c8d0d6b3f4ea0989b9ca42fb368cc2aac02495 Author: Vineet Gupta <vgupta@synopsys.com> Date: Fri Jan 1 17:58:45 2016 +0530 ARC: clockevent: DT based probe - timer frequency is derived from DT (no longer rely on top level DT "clock-frequency" probed early and exported by asm/clk.h) - TIMER0_IRQ need not be exported across arch code, confined to intc as it is property of same - Any failures in clockevent setup are considered pedantic and system panic()'s as there is no generic fallback (unlike clocksource where a jiffies based soft clocksource always exists) Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/irq.h | 9 ------- arch/arc/kernel/intc-compact.c | 2 ++ arch/arc/kernel/time.c | 59 ++++++++++++++++++++++++++++++------------ 3 files changed, 45 insertions(+), 25 deletions(-) commit 7ec9f34a03e4a08469cca206ff5324f6b99fdc3f Author: Vineet Gupta <vgupta@synopsys.com> Date: Fri Jan 1 18:48:40 2016 +0530 ARC: [dts] Introduce Timer bindings ARC Timers have historically been probed directly. As precursor to start probing Timers thru DT introduce these bindings Note that to keep series bisectable, these bindings are not yet used in code. Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: devicetree@vger.kernel.org Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vineet Gupta <vgupta@synopsys.com> .../devicetree/bindings/timer/snps,arc-timer.txt | 31 ++++++++++++++++++++++ .../devicetree/bindings/timer/snps,archs-gfrc.txt | 14 ++++++++++ .../devicetree/bindings/timer/snps,archs-rtc.txt | 14 ++++++++++ arch/arc/boot/dts/abilis_tb10x.dtsi | 14 ++++++++++ arch/arc/boot/dts/skeleton.dtsi | 14 ++++++++++ arch/arc/boot/dts/skeleton_hs.dtsi | 20 ++++++++++++++ arch/arc/boot/dts/skeleton_hs_idu.dtsi | 14 ++++++++++ 7 files changed, 121 insertions(+) commit b3d6aba8bd92c20b7748ccd82b6fab8ea5081066 Author: Vineet Gupta <vgupta@synopsys.com> Date: Fri Jan 1 18:48:40 2016 +0530 ARC: [dts] Add clk feeding into timers to DTs This allows us to introduce timers in DT in next commit The core clk frequency hack in AXS103 platform is also extended, where the core clk feeding into timers is updated in-place in FDT. Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/boot/dts/axc001.dtsi | 6 ++++++ arch/arc/boot/dts/axc003.dtsi | 6 ++++++ arch/arc/boot/dts/axc003_idu.dtsi | 6 ++++++ arch/arc/boot/dts/nsim_700.dts | 6 ++++++ arch/arc/boot/dts/nsim_hs.dts | 6 ++++++ arch/arc/boot/dts/nsim_hs_idu.dts | 6 ++++++ arch/arc/boot/dts/nsimosci.dts | 6 ++++++ arch/arc/boot/dts/nsimosci_hs.dts | 6 ++++++ arch/arc/boot/dts/nsimosci_hs_idu.dts | 6 ++++++ arch/arc/boot/dts/vdk_axc003.dtsi | 6 ++++++ arch/arc/boot/dts/vdk_axc003_idu.dtsi | 6 ++++++ arch/arc/plat-axs10x/axs10x.c | 14 +++++++++++++- 12 files changed, 79 insertions(+), 1 deletion(-) commit 9ba7648cc9b363dd5597caf68968502493996ce5 Author: Vineet Gupta <vgupta@synopsys.com> Date: Thu Jan 28 09:57:12 2016 +0530 ARC: [dts] Rename cpu_intc -> core_intc This is again for future changes to use common DTSI for timers which refer to @core_intc Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/boot/dts/axc001.dtsi | 6 +++--- arch/arc/boot/dts/axc003.dtsi | 8 ++++---- arch/arc/boot/dts/axc003_idu.dtsi | 6 +++--- arch/arc/boot/dts/nsim_700.dts | 4 ++-- arch/arc/boot/dts/nsimosci.dts | 4 ++-- arch/arc/boot/dts/vdk_axc003.dtsi | 6 +++--- arch/arc/boot/dts/vdk_axc003_idu.dtsi | 4 ++-- 7 files changed, 19 insertions(+), 19 deletions(-) commit 2e8cd93877b2f97439e417839dbd250f0a0f12a7 Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue Jan 19 16:00:42 2016 +0530 ARCv2: [dts]: Introduce HS38 specific include DTS ... ... and add them to plat-sim DTS. This allows for future change to introduce timers in DT in single place Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/boot/dts/axc001.dtsi | 2 ++ arch/arc/boot/dts/axc003.dtsi | 2 ++ arch/arc/boot/dts/axc003_idu.dtsi | 2 ++ arch/arc/boot/dts/nsim_hs.dts | 2 +- arch/arc/boot/dts/nsim_hs_idu.dts | 2 +- arch/arc/boot/dts/nsimosci_hs.dts | 2 +- arch/arc/boot/dts/nsimosci_hs_idu.dts | 2 +- arch/arc/boot/dts/skeleton_hs.dtsi | 32 ++++++++++++++++++++++++++++++++ arch/arc/boot/dts/skeleton_hs_idu.dtsi | 32 ++++++++++++++++++++++++++++++++ arch/arc/boot/dts/vdk_axc003.dtsi | 2 ++ arch/arc/boot/dts/vdk_axc003_idu.dtsi | 2 ++ 11 files changed, 78 insertions(+), 4 deletions(-) commit 69fbd09874ded099d445271d05681529dac4d00a Author: Noam Camus <noamc@ezchip.com> Date: Thu Jan 14 12:20:08 2016 +0530 ARC: clockevent: Prepare for DT based probe - call clocksource_probe() - This in turns needs of_clk_init() to be called earlier Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Noam Camus <noamc@ezchip.com> [vgupta: broken off from a bigger patch] Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/Kconfig | 3 ++- arch/arc/kernel/setup.c | 2 -- arch/arc/kernel/time.c | 5 +++++ 3 files changed, 7 insertions(+), 3 deletions(-) commit eec3c58efa271d7dfa30c978dda2c88280212634 Author: Noam Camus <noamc@ezchip.com> Date: Fri Jan 1 15:48:49 2016 +0530 ARC: clockevent: switch to cpu notifier for clockevent setup ARC Timers so far have been handled as "legacy" w/o explicit description in DT. This poses challenge for newer platforms wanting to use them. This series will eventually help move timers over to DT. This patch does a small change of using a CPU notifier to set clockevent on non-boot CPUs. So explicit setup is done only on boot CPU (which will later be done by DT) Signed-off-by: Noam Camus <noamc@ezchip.com> [vgupta: broken off from a bigger patch] Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/irq.h | 1 - arch/arc/kernel/smp.c | 2 -- arch/arc/kernel/time.c | 62 ++++++++++++++++++++++++++++++---------------- 3 files changed, 41 insertions(+), 24 deletions(-) commit 0eeb3dfe4b85aa7367e5e4efc365abbe4e50bbfa Author: Vineet Gupta <vgupta@synopsys.com> Date: Tue Apr 5 19:32:32 2016 +0530 ARC: [plat-axs] Refactor core freq get/set Reduces diff in future patches ! Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/plat-axs10x/axs10x.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 569579401ae1c9b9f317f38261e32135b153e9b3 Author: Vineet Gupta <vgupta@synopsys.com> Date: Thu Jan 28 12:56:03 2016 +0530 ARC: opencode arc_request_percpu_irq - The idea is to remove the API usage since it has a subltle design flaw - relies on being called on cpu0 first. This is true for some early per cpu irqs such as TIMER/IPI, but not for late probed per cpu peripherals such a perf. And it's usage in perf has already bitten us once: see c6317bc7c5ab ("ARCv2: perf: Ensure perf intr gets enabled on all cores") where we ended up open coding it anyways - The seeming duplication will go away once we start using cpu notifier for timer setup Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/include/asm/irq.h | 3 --- arch/arc/kernel/irq.c | 29 ----------------------------- arch/arc/kernel/smp.c | 15 ++++++++++++++- arch/arc/kernel/time.c | 14 +++++++++++--- 4 files changed, 25 insertions(+), 36 deletions(-) commit db4c4426daedffefcfd890d04a6ec9ed93268878 Author: Vineet Gupta <vgupta@synopsys.com> Date: Thu Jan 28 12:52:33 2016 +0530 ARC: [intc-compact] setup TIMER as percpu_dev This removes the quirk from arc_request_percpu_irq() and paves way for future simplifications Signed-off-by: Vineet Gupta <vgupta@synopsys.com> arch/arc/kernel/intc-compact.c | 3 ++- arch/arc/kernel/irq.c | 12 ------------ 2 files changed, 2 insertions(+), 13 deletions(-) commit 7d945796754a0394b0c5c35d8f80a4a805c7dbb9 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 6 18:19:59 2016 -0700 ifb: support more features When using ifb+netem on ingress on SIT/IPIP/GRE traffic, GRO packets are not properly processed. Segmentation should not be forced, since ifb is already adding quite a performance hit. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ifb.c | 3 +++ 1 file changed, 3 insertions(+) commit 8a3a4c6e7b343f1b648b63e55700243e98bfc892 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 6 15:55:50 2016 -0700 net: make sch_handle_ingress() drop monitor ready TC_ACT_STOLEN is used when ingress traffic is mirred/redirected to say ifb. Packet is not dropped, but consumed. Only TC_ACT_SHOT is a clear indication something went wrong. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Jamal Hadi Salim <jhs@mojatatu.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit acf87a3f5794f58743996c1b627b91622df6dd1d Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri May 6 20:55:23 2016 +0300 ISDN: eicon: replace custom hex_asc_lo() / hex_pack_byte() Instead of custom approach re-use generic helpers to convert byte to hex format. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/isdn/hardware/eicon/message.c | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) commit bafb86f5bc3173479002555dea7f31d943b12332 Merge: ba39164 44549e8 Author: Dave Airlie <airlied@redhat.com> Date: Mon May 9 13:49:56 2016 +1000 Merge tag 'v4.6-rc7' into drm-next Merge this back as we've built up a fair few conflicts, and I have some newer trees to pull in. commit 95b58430abe74f5e50970c57d27380bd5b8be324 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 6 08:55:12 2016 -0700 fq_codel: add memory limitation per queue On small embedded routers, one wants to control maximal amount of memory used by fq_codel, instead of controlling number of packets or bytes, since GRO/TSO make these not practical. Assuming skb->truesize is accurate, we have to keep track of skb->truesize sum for skbs in queue. This patch adds a new TCA_FQ_CODEL_MEMORY_LIMIT attribute. I chose a default value of 32 MBytes, which looks reasonable even for heavy duty usages. (Prior fq_codel users should not be hurt when they upgrade their kernels) Two fields are added to tc_fq_codel_qd_stats to report : - Current memory usage - Number of drops caused by memory limits # tc qd replace dev eth1 root est 1sec 4sec fq_codel memory_limit 4M .. # tc -s -d qd sh dev eth1 qdisc fq_codel 8008: root refcnt 257 limit 10240p flows 1024 quantum 1514 target 5.0ms interval 100.0ms memory_limit 4Mb ecn Sent 2083566791363 bytes 1376214889 pkt (dropped 4994406, overlimits 0 requeues 21705223) rate 9841Mbit 812549pps backlog 3906120b 376p requeues 21705223 maxpacket 68130 drop_overlimit 4994406 new_flow_count 28855414 ecn_mark 0 memory_used 4190048 drop_overmemory 4994406 new_flows_len 1 old_flows_len 177 Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Cc: Dave Täht <dave.taht@gmail.com> Cc: Sebastian Möller <moeller0@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/pkt_sched.h | 3 +++ net/sched/sch_fq_codel.c | 27 ++++++++++++++++++++++++--- 2 files changed, 27 insertions(+), 3 deletions(-) commit bdabad3e363d825ddf9679dd431cca0b2c30f881 Author: Courtney Cavin <courtney.cavin@sonymobile.com> Date: Fri May 6 07:09:08 2016 -0700 net: Add Qualcomm IPC router Add an implementation of Qualcomm's IPC router protocol, used to communicate with service providing remote processors. Signed-off-by: Courtney Cavin <courtney.cavin@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> [bjorn: Cope with 0 being a valid node id and implement RTM_NEWADDR] Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/socket.h | 4 +- include/uapi/linux/qrtr.h | 12 + net/Kconfig | 1 + net/Makefile | 1 + net/qrtr/Kconfig | 24 ++ net/qrtr/Makefile | 2 + net/qrtr/qrtr.c | 1007 +++++++++++++++++++++++++++++++++++++++++++++ net/qrtr/qrtr.h | 31 ++ net/qrtr/smd.c | 117 ++++++ 9 files changed, 1198 insertions(+), 1 deletion(-) commit 43315f31adc2bf3b35e04dcf2372c3bb08014ed1 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Fri May 6 07:09:07 2016 -0700 soc: qcom: smd: Introduce compile stubs Introduce compile stubs for the SMD API, allowing consumers to be compile tested. Acked-by: Andy Gross <andy.gross@linaro.org> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/soc/qcom/smd.h | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) commit ba391646d0d43aee3596b616113cce0f22dde627 Author: Dave Airlie <airlied@redhat.com> Date: Mon May 9 10:30:42 2016 +1000 drm/amdgpu: fix build on aarch64. Same fix went in previously for some other files. Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_thermal.c | 1 + 1 file changed, 1 insertion(+) commit 2c3d68abe2f06b21f047b52e6f0e1b82542e1332 Merge: 2958cf0 2b66987 Author: Dave Airlie <airlied@redhat.com> Date: Mon May 9 10:19:38 2016 +1000 Merge branch 'msm-next' of git://people.freedesktop.org/~robclark/linux into drm-next Mostly cleanups, fixes, and 'struct fence' conversion this time around, with one reservation patch which is a-b Sumit (which the fence conversion patches depend on). * 'msm-next' of git://people.freedesktop.org/~robclark/linux: (25 commits) drm/msm: Drop load/unload drm_driver ops drm/msm: Centralize connector registration/unregistration drm/msm/hdmi: Prevent gpio_free related kernel warnings drm/msm: print offender task name on hangcheck recovery drm/msm: fix leak in failed submit path drm/msm: de-indent submit_create() drm/msm: drop return from gpu->submit() drm/msm/mdp4: Don't manage DSI PLL regulators in MDP driver drm/msm/edp: Drop regulator_set_voltage call drm/msm/dsi: Fix regulator API abuse drm/msm: Move call to PTR_ERR_OR_ZERO after reassignment drm/msm/mdp: Add support for more RGBX formats drm: msm: remove unused variable drm/msm: fix ->last_fence() after recover drm/msm: 'struct fence' conversion drm/msm: remove fence_cbs drm/msm: introduce msm_fence_context drm/msm: split locking and pinning BO's drm/msm/gpu: simplify tracking in-flight bo's drm/msm: split out timeout_to_jiffies helper ... commit 2958cf0ee2232cddf06cc9efaf143a0919b266f5 Merge: fd50c3a 8863dc7 Author: Dave Airlie <airlied@redhat.com> Date: Mon May 9 10:16:50 2016 +1000 Merge tag 'topic/drm-misc-2016-05-08' of git://anongit.freedesktop.org/drm-intel into drm-next Refcounting is hard, so here's a quick pull request with the one-liner to fix up i915. Otherwise just a few other small things I picked up. Plus the regression fix from Marten for rmfb behaviour that lingered around forever since no testers. Feel free to cherry-pick that over to drm-fixes, but given that there's not many who seemed to have cared, meh. * tag 'topic/drm-misc-2016-05-08' of git://anongit.freedesktop.org/drm-intel: drm/i915: Correctly refcount connectors in hw state readou drm/panel: Flesh out kerneldoc drm: Add gpu.tmpl docbook to MAINTAINERS entry drm/core: Do not preserve framebuffer on rmfb, v4. drm: Fix up markup fumble drm/fb_helper: Fix a few typos commit 84752e8d8ab6bb72feab96785e9366783b4b9787 Author: Douglas Anderson <dianders@chromium.org> Date: Wed May 4 16:36:25 2016 -0700 clk: rockchip: fix the rk3399 sdmmc sample / drv name The rk3399 clock table had a simple typo in it, calling the SDMMC sample and drive clocks by the wrong name. Fix this minor typo. Signed-off-by: Douglas Anderson <dianders@chromium.org> Tested-by: Brian Norris <briannorris@chromium.org> Acked-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 068655dc9b7c71c4bea25c41eeaa5125c6724a91 Author: Priit Laes <plaes@plaes.org> Date: Thu May 5 20:39:04 2016 +0300 ARM: sun7i: dt: Add pll3 and pll7 clocks Enable pll3 and pll7 clocks that are needed by display clocks. Signed-off-by: Priit Laes <plaes@plaes.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20.dtsi | 41 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit 27dd9af6bc000ab21fdd41e58e3dddedba57ab92 Author: Olliver Schinagl <oliver@schinagl.nl> Date: Thu May 5 11:08:52 2016 +0200 ARM: dts: sunxi: Add a olinuxino-lime2-emmc There are 3 kinds of OLinuXino Lime2 boards. One without any on board storage, one with NAND storage and one with eMMC storage. This patch adds the eMMC variant of boards. eMMC storage is different from a regular SD card in that it is soldered on the board and cannot be changed. Additionally, it shares pins with the NAND module and with the second SPI port. Signed-off-by: Olliver Schinagl <oliver@schinagl.nl> [Maxime: Removed the change log from the commit log] Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> .../boot/dts/sun7i-a20-olinuxino-lime2-emmc.dts | 82 ++++++++++++++++++++++ 1 file changed, 82 insertions(+) commit c430cf376fee0b03d9c9293615f9737649de1b12 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Thu May 5 17:50:49 2016 +0530 mailbox: Fix devm_ioremap_resource error detection code devm_ioremap_resource returns an ERR_PTR value, not NULL, on failure. The Coccinelle semantic patch used to make this change is as follows: @@ expression e,e1; statement S; @@ *e = devm_ioremap_resource(...); if (!e1) S Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/mailbox-sti.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2b669875332fbdff0a7ad559e8662e875e7a1526 Author: Archit Taneja <architt@codeaurora.org> Date: Mon May 2 11:05:54 2016 +0530 drm/msm: Drop load/unload drm_driver ops The load/unload drm_driver ops are deprecated. They should be removed as they result in creation of devices visible to userspace even before the drm_device is registered. Drop these ops and use drm_dev_alloc/register and drm_dev_unregister/unref to explicitly create and destroy the drm device in the msm platform driver's bind and unbind ops. With this in use, the drm connectors are only registered once the drm_device is registered. It also fixes the issue of stray debugfs files after the msm module is removed. With this, all the debugfs files are removed, and allows successive module insertions/removals. Signed-off-by: Archit Taneja <architt@codeaurora.org> drivers/gpu/drm/msm/msm_drv.c | 125 ++++++++++++++++++++++++------------------ 1 file changed, 71 insertions(+), 54 deletions(-) commit 8208ed931eea9b00a3b29c9ef36da382b5480881 Author: Archit Taneja <architt@codeaurora.org> Date: Mon May 2 11:05:53 2016 +0530 drm/msm: Centralize connector registration/unregistration Move the drm_connector registration from the encoder(HDMI/DSI etc) drivers to the msm platform driver. This will simplify the task of ensuring that the connectors are registered only after the drm_device itself is registered. The connectors' destroy ops are made to use kzalloc instead of devm_kzalloc to ensure that that the connectors can be successfully unregistered when the msm driver module is removed. The memory for the connectors is unallocated when drm_mode_config_cleanup() is called during either during an error or during driver remove. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/dsi/dsi_manager.c | 27 ++++++++-------------- drivers/gpu/drm/msm/edp/edp_connector.c | 20 ++++------------ drivers/gpu/drm/msm/hdmi/hdmi_connector.c | 17 +++----------- drivers/gpu/drm/msm/mdp/mdp4/mdp4_lvds_connector.c | 16 ++----------- drivers/gpu/drm/msm/msm_drv.c | 8 +++++++ 5 files changed, 26 insertions(+), 62 deletions(-) commit c899f9358485869a6e18902233eb77b31f0428ee Author: Archit Taneja <architt@codeaurora.org> Date: Mon May 2 11:05:52 2016 +0530 drm/msm/hdmi: Prevent gpio_free related kernel warnings Calling the legacy gpio_free on an invalid GPIO (a GPIO numbered -1) results in kernel warnings. This causes a lot of backtraces when we try to unload the drm/msm module. Call gpio_free only on valid GPIOs. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/hdmi/hdmi_connector.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 4816b6267cf078f40158ff2e6bf9d0223f0c1cf6 Author: Rob Clark <robdclark@gmail.com> Date: Tue May 3 10:10:15 2016 -0400 drm/msm: print offender task name on hangcheck recovery Track the pid per submit, so we can print the name of the task which submitted the batch that caused the gpu to hang. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_gem.h | 1 + drivers/gpu/drm/msm/msm_gem_submit.c | 2 ++ drivers/gpu/drm/msm/msm_gpu.c | 23 +++++++++++++++++++---- 3 files changed, 22 insertions(+), 4 deletions(-) commit 40e6815bba6e34e5560e8855b43cd3eb17b24b09 Author: Rob Clark <robdclark@gmail.com> Date: Tue May 3 09:50:26 2016 -0400 drm/msm: fix leak in failed submit path Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_drv.h | 1 + drivers/gpu/drm/msm/msm_gem_submit.c | 13 +++++++++++-- drivers/gpu/drm/msm/msm_gpu.c | 4 +--- 3 files changed, 13 insertions(+), 5 deletions(-) commit 6860b56c4b84bf9dba479c3f881d45a0b09a879c Author: Rob Clark <robdclark@gmail.com> Date: Tue May 3 09:49:40 2016 -0400 drm/msm: de-indent submit_create() Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_gem_submit.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit 1193c3bcb581807d58dd7df90528ec744af387a9 Author: Rob Clark <robdclark@gmail.com> Date: Tue May 3 09:46:49 2016 -0400 drm/msm: drop return from gpu->submit() At this point, there is nothing left to fail. And submit already has a fence assigned and is added to the submit_list. Any problems from here on out are asynchronous (ie. hangcheck/recovery). Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/adreno/adreno_gpu.c | 4 +--- drivers/gpu/drm/msm/adreno/adreno_gpu.h | 2 +- drivers/gpu/drm/msm/msm_gpu.c | 4 ++-- drivers/gpu/drm/msm/msm_gpu.h | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) commit ed19075be1100f8958066ed798e225173583eb2e Author: Archit Taneja <architt@codeaurora.org> Date: Fri Apr 29 15:19:37 2016 +0530 drm/msm/mdp4: Don't manage DSI PLL regulators in MDP driver The MDP4 driver tries to request and set voltages for regulators required by the DSI PLLs. Firstly, the MDP4 driver shouldn't manage the DSI regulators, this should be handled in the DSI driver. Secondly, it shouldn't try to set a fixed voltage for regulators. Voltage constraints should be specified on the regulator via DT and managed by the regulator core. Remove all the DSI PLL regulator related code from the MDP4 driver. It's managed in the DSI driver for MSM8960/APQ8064 already. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/mdp/mdp4/mdp4_kms.c | 34 --------------------------------- drivers/gpu/drm/msm/mdp/mdp4/mdp4_kms.h | 2 -- 2 files changed, 36 deletions(-) commit 1d15c1654f8c438694a8680a4faa6e5f77abd507 Author: Archit Taneja <architt@codeaurora.org> Date: Fri Apr 29 15:19:36 2016 +0530 drm/msm/edp: Drop regulator_set_voltage call The eDP driver tries to set a fixed voltage for one of its regulators(vdda) before enabling it. This shouldn't be done by the driver, the voltage constraints should be specified on the regulator via DT and managed by the regulator core. A driver should call regulator_set_voltage only if it needs to change the voltage during runtime. Drop the regulator_set_voltage call. Mention in a comment the voltage that the regulator expects. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/edp/edp_ctrl.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) commit f377d59729e744122751977eb79b349d2e166095 Author: Archit Taneja <architt@codeaurora.org> Date: Fri Apr 29 15:19:35 2016 +0530 drm/msm/dsi: Fix regulator API abuse The voltage changing code in this driver is broken and should be removed. The driver sets a single, exact voltage on probe. Unless there is a very good reason for this (which should be documented in comments) constraints like this need to be set via the machine constraints, voltage setting in a driver is expected to be used in cases where the voltage varies at runtime. In addition client drivers should almost never be calling regulator_can_set_voltage(), if the device needs to set a voltage it needs to set the voltage and the regulator core will handle the case where the regulator is fixed voltage. If the driver simply skips setting the voltage if it doesn't have permission then it should just not bother in the first place. Originally authored by Mark Brown <broonie@kernel.org> Remove the min/max voltage data entries per SoC managed by the driver. These aren't needed as we don't try to set voltages any more. Mention in comments the voltages that each regulator expects. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/dsi/dsi.h | 2 -- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 34 ++++++++++++------------- drivers/gpu/drm/msm/dsi/dsi_host.c | 12 --------- drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 13 ---------- drivers/gpu/drm/msm/dsi/phy/dsi_phy_20nm.c | 4 +-- drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c | 4 +-- drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c | 2 +- 7 files changed, 22 insertions(+), 49 deletions(-) commit d6c925cada0d92e49c3473bc0a69ea3913fff905 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu Apr 28 18:52:49 2016 +0530 drm/msm: Move call to PTR_ERR_OR_ZERO after reassignment Here, a location is reset to NULL before being passed to PTR_ERR. So, PTR_ERR should be called before its argument is reassigned to NULL. Further to simplify things use PTR_ERR_OR_ZERO instead of PTR_ERR and IS_ERR. Problem found using Coccinelle. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com> [fixed fmt string warning (s/%ld/%d/)] Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/edp/edp_ctrl.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit 30c6bfe8abb51098889c6f894641aff22d2a65d1 Author: Rob Herring <robh@kernel.org> Date: Mon Apr 11 18:23:51 2016 -0500 drm/msm/mdp: Add support for more RGBX formats Android needs XBGR8888 format. Add all the missing 32-bpp formats without alpha for completeness. Cc: Archit Taneja <architt@codeaurora.org> Cc: Rob Clark <robdclark@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/mdp/mdp_format.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 6979cd54c0667189bb0805c0fcebfef8afc5a191 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:41:46 2016 +0200 drm: msm: remove unused variable A recent cleanup removed the only user of the 'kms' variable in msm_preclose(), causing a harmless compiler warning: drivers/gpu/drm/msm/msm_drv.c: In function 'msm_preclose': drivers/gpu/drm/msm/msm_drv.c:468:18: error: unused variable 'kms' [-Werror=unused-variable] This removes the variable as well. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 4016260ba47a ("drm/msm: fix bug after preclose removal") Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_drv.c | 1 - 1 file changed, 1 deletion(-) commit 2755734390c18ca33d9755c9caa2685567563c19 Author: Rob Clark <robdclark@gmail.com> Date: Thu Mar 17 10:18:38 2016 -0400 drm/msm: fix ->last_fence() after recover It is no longer true that we discard all in-flight submits on recover (these days we only discard the first one that hung). After the first re-submitted batch completes it would overwrite the fence with a correct value, but there would be a window of time which showed all re-submitted batches as already complete. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/adreno/adreno_gpu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b6295f9a38fc3f7d59ec0caa45aa803461c6cea5 Author: Rob Clark <robdclark@gmail.com> Date: Tue Mar 15 18:26:28 2016 -0400 drm/msm: 'struct fence' conversion Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/adreno/adreno_gpu.c | 4 +- drivers/gpu/drm/msm/msm_atomic.c | 42 ++++++----- drivers/gpu/drm/msm/msm_drv.h | 5 +- drivers/gpu/drm/msm/msm_fence.c | 71 +++++++++++++++++- drivers/gpu/drm/msm/msm_fence.h | 4 ++ drivers/gpu/drm/msm/msm_gem.c | 124 ++++++++++++++++++++++++-------- drivers/gpu/drm/msm/msm_gem.h | 16 +---- drivers/gpu/drm/msm/msm_gem_submit.c | 22 +++++- drivers/gpu/drm/msm/msm_gpu.c | 27 ++++--- drivers/gpu/drm/msm/msm_rd.c | 2 +- 10 files changed, 233 insertions(+), 84 deletions(-) commit ba00c3f2f0c84456ffe9d548823ff4fb8e4e7ed4 Author: Rob Clark <robdclark@gmail.com> Date: Wed Mar 16 18:18:17 2016 -0400 drm/msm: remove fence_cbs This was only used for atomic commit these days. So instead just give atomic it's own work-queue where we can do a block on each bo in turn. Simplifies things a whole bunch and makes the 'struct fence' conversion easier. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_atomic.c | 77 +++++++++++++++++----------------------- drivers/gpu/drm/msm/msm_drv.c | 4 +++ drivers/gpu/drm/msm/msm_drv.h | 5 +-- drivers/gpu/drm/msm/msm_fence.c | 43 ---------------------- drivers/gpu/drm/msm/msm_fence.h | 16 --------- drivers/gpu/drm/msm/msm_gem.c | 9 ++++- 6 files changed, 47 insertions(+), 107 deletions(-) commit ca762a8ae7f453978a4769af9dcd3cb08e45b932 Author: Rob Clark <robdclark@gmail.com> Date: Tue Mar 15 17:22:13 2016 -0400 drm/msm: introduce msm_fence_context Better encapsulate the per-timeline stuff into fence-context. For now there is just a single fence-context, but eventually we'll also have one per-CRTC to enable fully explicit fencing. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/adreno/adreno_gpu.c | 6 +-- drivers/gpu/drm/msm/msm_atomic.c | 9 ++-- drivers/gpu/drm/msm/msm_drv.c | 8 +-- drivers/gpu/drm/msm/msm_drv.h | 9 +--- drivers/gpu/drm/msm/msm_fence.c | 87 ++++++++++++++++++++------------- drivers/gpu/drm/msm/msm_fence.h | 21 ++++++-- drivers/gpu/drm/msm/msm_gem.c | 16 ++---- drivers/gpu/drm/msm/msm_gpu.c | 23 +++++---- drivers/gpu/drm/msm/msm_gpu.h | 7 ++- 9 files changed, 108 insertions(+), 78 deletions(-) commit 340faef2418989b2573b82e6c708ef9e24ca439b Author: Rob Clark <robdclark@gmail.com> Date: Mon Mar 14 13:56:37 2016 -0400 drm/msm: split locking and pinning BO's Split up locking and pinning buffers in the submit path. This is needed because we'll want to insert fencing in between the two steps. This makes things end up looking more similar to etnaviv submit code (which was originally modelled on the msm code but has already added 'struct fence' support). Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_gem.h | 2 +- drivers/gpu/drm/msm/msm_gem_submit.c | 69 ++++++++++++++++++++---------------- 2 files changed, 40 insertions(+), 31 deletions(-) commit 7d12a279d421255792f2092f68262a79e3311dc2 Author: Rob Clark <robdclark@gmail.com> Date: Wed Mar 16 16:07:38 2016 -0400 drm/msm/gpu: simplify tracking in-flight bo's Since we already track the array of bo's in the submit object, just unconditionally take and drop ref's per submit (rather than only taking ref's if bo is not already active). This simplifies later patches. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_gpu.c | 51 +++++++++++++++++++------------------------ 1 file changed, 22 insertions(+), 29 deletions(-) commit 340ff4104f4454f8f1c3bf793c46411115309545 Author: Rob Clark <robdclark@gmail.com> Date: Wed Mar 16 14:57:22 2016 -0400 drm/msm: split out timeout_to_jiffies helper Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_drv.h | 15 +++++++++++++++ drivers/gpu/drm/msm/msm_fence.c | 11 +---------- 2 files changed, 16 insertions(+), 10 deletions(-) commit 79f0e20215bb902352cf7eb31222f4120563775c Author: Rob Clark <robdclark@gmail.com> Date: Wed Mar 16 12:40:35 2016 -0400 drm/msm: use imported dmabuf's reservation object This was always the intention, but somehow it was never wired up properly. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/msm_drv.h | 2 +- drivers/gpu/drm/msm/msm_gem.c | 18 ++++++++++++------ drivers/gpu/drm/msm/msm_gem_prime.c | 2 +- 3 files changed, 14 insertions(+), 8 deletions(-) commit fde5de6cb4617a160a6cc5c034284618350c2961 Author: Rob Clark <robdclark@gmail.com> Date: Tue Mar 15 15:35:08 2016 -0400 drm/msm: move fence code to it's own file Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/Makefile | 1 + drivers/gpu/drm/msm/msm_atomic.c | 1 + drivers/gpu/drm/msm/msm_drv.c | 108 +------------------------------- drivers/gpu/drm/msm/msm_drv.h | 27 +------- drivers/gpu/drm/msm/msm_fence.c | 129 +++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/msm/msm_fence.h | 43 +++++++++++++ drivers/gpu/drm/msm/msm_gem.c | 1 + drivers/gpu/drm/msm/msm_gpu.c | 1 + 8 files changed, 178 insertions(+), 133 deletions(-) commit edcd60ce243d16f1b50dacb8f0643308b23f1070 Author: Rob Clark <robdclark@gmail.com> Date: Wed Mar 16 12:56:12 2016 -0400 drm/msm: move debugfs code to it's own file Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/Makefile | 1 + drivers/gpu/drm/msm/msm_debugfs.c | 168 ++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/msm/msm_debugfs.h | 26 ++++++ drivers/gpu/drm/msm/msm_drv.c | 153 +--------------------------------- 4 files changed, 196 insertions(+), 152 deletions(-) commit 824815c4cd13e384ef5a4be725ec4b06e4ad2c2a Author: Rob Clark <robdclark@gmail.com> Date: Thu Mar 31 16:23:51 2016 -0400 reservation: add reservation_object_get_excl_rcu() In the atomic modesetting path, each driver simply wants to grab a ref to the exclusive fence from a reservation object to store in the incoming drm_plane_state, without doing the whole RCU dance. Since each driver will need to do this, lets make a helper. v2: rename to _rcu instead of _unlocked to be more consistent Signed-off-by: Rob Clark <robdclark@gmail.com> Acked-by: Sumit Semwal <sumit.semwal@linaro.org> include/linux/reservation.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit feb46f02c3fa70e6d3e5307cb105cc69c60a3fe3 Author: Rob Clark <robdclark@gmail.com> Date: Sun Mar 20 10:16:29 2016 -0400 drm/msm: make HDCP support optional It is already optional at runtime. But this at least simplifies backports to kernels without QCOM_SCM. Signed-off-by: Rob Clark <robdclark@gmail.com> drivers/gpu/drm/msm/Kconfig | 7 +++++++ drivers/gpu/drm/msm/Makefile | 3 ++- drivers/gpu/drm/msm/hdmi/hdmi.h | 11 +++++++++++ 3 files changed, 20 insertions(+), 1 deletion(-) commit 38b19ed7f81ec930f3ad2066ae088f574970c814 Author: Jeeja KP <jeeja.kp@intel.com> Date: Thu May 5 11:24:43 2016 +0530 ALSA: hda: fix to wait for RIRB & CORB DMA to set If the DMAs are not being quiesced properly, it may lead to stability issues, so the recommendation is to wait till DMAs are stopped. After setting the stop bit of RIRB/CORB DMA, we should wait for stop bit to be set. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/hda/hdac_controller.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 94e9080ce22d9fb7c0a4361a5890b2c6affc9b1b Author: Vinod Koul <vinod.koul@intel.com> Date: Thu May 5 11:24:42 2016 +0530 ALSA: hda: fix the missing ptr initialization ebus is a member of extended device and was never initialized, so do this at device creation. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/hda/ext/hdac_ext_bus.c | 1 + 1 file changed, 1 insertion(+) commit 89e448b33a101dfc7218f3181bc3095af850db7a Author: Oliver Neukum <ONeukum@suse.com> Date: Wed May 4 14:18:40 2016 +0200 ALSA: usb-midi: correct speed checking Allow for SS+ USB devices Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/usb/midi.c | 1 + 1 file changed, 1 insertion(+) commit 748a1ccc433f1c4edb214fff4b340af9c1da3f88 Author: Oliver Neukum <ONeukum@suse.com> Date: Wed May 4 14:18:39 2016 +0200 ALSA: usb-audio: correct speed checking Allow handling SS+ USB devices correctly. Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/usb/card.c | 4 ++++ sound/usb/helper.c | 1 + 2 files changed, 5 insertions(+) commit dcd4f0db6141d6bf2cb897309d5d6f53d1b1696f Author: Kailang Yang <kailang@realtek.com> Date: Wed May 4 15:50:18 2016 +0800 ALSA: hda/realtek - New codecs support for ALC234/ALC274/ALC294 Support new codecs for ALC234/ALC274/ALC294. This three codecs was the same IC. But bonding is not the same. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_realtek.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 84d7a4470dbac0dd9389050100b54a1625d04264 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:27:37 2016 +0300 ALSA: isa/wavefront: prevent some out of bound writes "header->number" can be up to USHRT_MAX and it comes from the ioctl so it needs to be capped. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/isa/wavefront/wavefront_synth.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit e4ec8cc8039a7063e24204299b462bd1383184a5 Author: Kangjie Lu <kangjielu@gmail.com> Date: Tue May 3 16:44:32 2016 -0400 ALSA: timer: Fix leak in events via snd_timer_user_tinterrupt The stack object “r1” has a total size of 32 bytes. Its field “event” and “val” both contain 4 bytes padding. These 8 bytes padding bytes are sent to user without being initialized. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/timer.c | 1 + 1 file changed, 1 insertion(+) commit 9a47e9cff994f37f7f0dbd9ae23740d0f64f9fe6 Author: Kangjie Lu <kangjielu@gmail.com> Date: Tue May 3 16:44:20 2016 -0400 ALSA: timer: Fix leak in events via snd_timer_user_ccallback The stack object “r1” has a total size of 32 bytes. Its field “event” and “val” both contain 4 bytes padding. These 8 bytes padding bytes are sent to user without being initialized. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/timer.c | 1 + 1 file changed, 1 insertion(+) commit cec8f96e49d9be372fdb0c3836dcf31ec71e457e Author: Kangjie Lu <kangjielu@gmail.com> Date: Tue May 3 16:44:07 2016 -0400 ALSA: timer: Fix leak in SNDRV_TIMER_IOCTL_PARAMS The stack object “tread” has a total size of 32 bytes. Its field “event” and “val” both contain 4 bytes padding. These 8 bytes padding bytes are sent to user without being initialized. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/timer.c | 1 + 1 file changed, 1 insertion(+) commit 242658ff99ab9d87e704475ef78c3102ead344cf Author: Vinod Koul <vinod.koul@intel.com> Date: Mon May 2 14:06:28 2016 +0530 ALSA: compress: fix some typo Noticed two typos in Documentation, so fix them up Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Documentation/sound/alsa/compress_offload.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f8ff65bce4fe9e94794beb21a3ba5e0cced43b1a Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Sat Apr 30 22:06:46 2016 +0900 ALSA: dice: add support for M-Audio Profire 610 and perhaps 2626 M-Audio Profire 610 has an unexpected value in version field of its config ROM, thus ALSA dice driver is not assigned to the model due to a mismatch of modalias. This commit adds an entry to support the model. I expect the entry is also for Profire 2626. I note that Profire 610 uses TCD2220 (so-called Dice Jr.), and supports a part of Extended Application Protocol (EAP). $ cd linux-firewire-utils/src $ ./crpp < /sys/bus/firewire/devices/fw1/config_rom ROM header and bus information block ------------------------------------------------------------ 400 04047689 bus_info_length 4, crc_length 4, crc 30345 404 31333934 bus_name "1394" 408 e0ff8112 irmc 1, cmc 1, isc 1, bmc 0, pmc 0, cyc_clk_acc 255, max_rec 8 (512), max_rom 1, gen 1, spd 2 (S400) 40c 000d6c04 company_id 000d6c | 410 04400002 device_id 0404400002 | EUI-64 000d6c0404400002 root directory ------------------------------------------------------------ 414 000695fe directory_length 6, crc 38398 418 03000d6c vendor 41c 8100000a --> descriptor leaf at 444 420 17000011 model 424 8100000d --> descriptor leaf at 458 428 0c0087c0 node capabilities per IEEE 1394 42c d1000001 --> unit directory at 430 unit directory at 430 ------------------------------------------------------------ 430 0004fb14 directory_length 4, crc 64276 434 12000d6c specifier id 438 130100d1 version 43c 17000011 model 440 8100000c --> descriptor leaf at 470 descriptor leaf at 444 ------------------------------------------------------------ 444 0004b8e4 leaf_length 4, crc 47332 448 00000000 textual descriptor 44c 00000000 minimal ASCII 450 4d2d4175 "M-Au" 454 64696f00 "dio" descriptor leaf at 458 ------------------------------------------------------------ 458 00053128 leaf_length 5, crc 12584 45c 00000000 textual descriptor 460 00000000 minimal ASCII 464 50726f46 "ProF" 468 69726520 "ire " 46c 36313000 "610" descriptor leaf at 470 ------------------------------------------------------------ 470 00053128 leaf_length 5, crc 12584 474 00000000 textual descriptor 478 00000000 minimal ASCII 47c 50726f46 "ProF" 480 69726520 "ire " 484 36313000 "610" $ cat /proc/asound/card1/dice sections: global: offset 10, size 90 tx: offset 100, size 142 rx: offset 242, size 282 ext_sync: offset 524, size 4 unused2: offset 0, size 0 global: owner: ffc0:000100000000 notification: 00000040 nick name: FW610 clock select: internal 48000 enable: 1 status: locked 48000 ext status: 00000040 sample rate: 48000 version: 1.0.4.0 clock caps: 32000 44100 48000 88200 96000 176400 192000 aes1 aes4 aes adat tdif wc arx1 arx2 internal clock source names: SPDIF\AES34\AES56\TOS\AES_ANY\ADAT\ADAT_AUX\Word Clock\Unused\Unused\Unused\Unused\Internal\\ ... Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/dice/dice.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 218d48e701f08a71df57c410e596e30b3285bd25 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Thu May 5 11:05:39 2016 +0530 cxgb4: Reset dcb state machine and tx queue prio only if dcb is enabled When cxgb4 is enabled with CONFIG_CHELSIO_T4_DCB set, VI enable command gets called with DCB enabled. But when we have a back to back setup with DCB enabled on one side and non-DCB on the Peer side. Firmware doesn't send any DCB_L2_CFG, and DCB priority is never set for Tx queue. But driver resets the queue priority and state machine whenever there is a link down, this patch fixes it by adding a check to reset only if cxgb4_dcb_enabled() returns true. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 38 +++++++++++++------------ 1 file changed, 20 insertions(+), 18 deletions(-) commit 0080c5076409d211fbe28d6f07966f7d39e58bad Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Sat May 7 08:52:57 2016 -0700 f2fs: do not preallocate block unaligned to 4KB Previously f2fs_preallocate_blocks() tries to allocate unaligned blocks. In f2fs_write_begin(), however, prepare_write_begin() does not skip its allocation due to (len != 4KB). So, it needs locking node page twice unexpectedly. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 79344efb93a26378a91193bed133cee42162cd81 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri May 6 16:19:43 2016 -0700 f2fs: read node blocks ahead when truncating blocks This patch enables reading node blocks in advance when truncating large data blocks. > time rm $MNT/testfile (500GB) after drop_cachees Before : 9.422 s After : 4.821 s Reported-by: Stephen Bates <stephen.bates@microsemi.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 2 +- fs/f2fs/node.c | 52 ++++++++++++++++++++++++++++------------------------ 2 files changed, 29 insertions(+), 25 deletions(-) commit e12dd7bd874cb1c8658d5e8c1eab5f91a71939dc Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri May 6 15:30:38 2016 -0700 f2fs: fallocate data blocks in single locked node page This patch is to improve the expand_inode speed in fallocate by allocating data blocks as many as possible in single locked node page. In SSD, # time fallocate -l 500G $MNT/testfile Before : 1m 33.410 s After : 24.758 s Reported-by: Stephen Bates <stephen.bates@microsemi.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 51 ++++++++++++++++++++++----------------------------- 1 file changed, 22 insertions(+), 29 deletions(-) commit f61cce5b81f91ba336184008b24baec84afbb3dd Author: Chao Yu <yuchao0@huawei.com> Date: Sat May 7 16:15:05 2016 +0800 f2fs: fix inode cache leak When testing f2fs with inline_dentry option, generic/342 reports: VFS: Busy inodes after unmount of dm-0. Self-destruct in 5 seconds. Have a nice day... After rmmod f2fs module, kenrel shows following dmesg: ============================================================================= BUG f2fs_inode_cache (Tainted: G O ): Objects remaining in f2fs_inode_cache on __kmem_cache_shutdown() ----------------------------------------------------------------------------- Disabling lock debugging due to kernel taint INFO: Slab 0xf51ca0e0 objects=22 used=1 fp=0xd1e6fc60 flags=0x40004080 CPU: 3 PID: 7455 Comm: rmmod Tainted: G B O 4.6.0-rc4+ #16 Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006 00000086 00000086 d062fe18 c13a83a0 f51ca0e0 d062fe38 d062fea4 c11c7276 c1981040 f51ca0e0 00000016 00000001 d1e6fc60 40004080 656a624f 20737463 616d6572 6e696e69 6e692067 66326620 6e695f73 5f65646f 68636163 6e6f2065 Call Trace: [<c13a83a0>] dump_stack+0x5f/0x8f [<c11c7276>] slab_err+0x76/0x80 [<c11cbfc0>] ? __kmem_cache_shutdown+0x100/0x2f0 [<c11cbfc0>] ? __kmem_cache_shutdown+0x100/0x2f0 [<c11cbfe5>] __kmem_cache_shutdown+0x125/0x2f0 [<c1198a38>] kmem_cache_destroy+0x158/0x1f0 [<c176b43d>] ? mutex_unlock+0xd/0x10 [<f8f15aa3>] exit_f2fs_fs+0x4b/0x5a8 [f2fs] [<c10f596c>] SyS_delete_module+0x16c/0x1d0 [<c1001b10>] ? do_fast_syscall_32+0x30/0x1c0 [<c13c59bf>] ? __this_cpu_preempt_check+0xf/0x20 [<c10afa7d>] ? trace_hardirqs_on_caller+0xdd/0x210 [<c10ad50b>] ? trace_hardirqs_off+0xb/0x10 [<c1001b81>] do_fast_syscall_32+0xa1/0x1c0 [<c176d888>] sysenter_past_esp+0x45/0x74 INFO: Object 0xd1e6d9e0 @offset=6624 kmem_cache_destroy f2fs_inode_cache: Slab cache still has objects CPU: 3 PID: 7455 Comm: rmmod Tainted: G B O 4.6.0-rc4+ #16 Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006 00000286 00000286 d062fef4 c13a83a0 f174b000 d062ff14 d062ff28 c1198ac7 c197fe18 f3c5b980 d062ff20 000d04f2 d062ff0c d062ff0c d062ff14 d062ff14 f8f20dc0 fffffff5 d062e000 d062ff30 f8f15aa3 d062ff7c c10f596c 73663266 Call Trace: [<c13a83a0>] dump_stack+0x5f/0x8f [<c1198ac7>] kmem_cache_destroy+0x1e7/0x1f0 [<f8f15aa3>] exit_f2fs_fs+0x4b/0x5a8 [f2fs] [<c10f596c>] SyS_delete_module+0x16c/0x1d0 [<c1001b10>] ? do_fast_syscall_32+0x30/0x1c0 [<c13c59bf>] ? __this_cpu_preempt_check+0xf/0x20 [<c10afa7d>] ? trace_hardirqs_on_caller+0xdd/0x210 [<c10ad50b>] ? trace_hardirqs_off+0xb/0x10 [<c1001b81>] do_fast_syscall_32+0xa1/0x1c0 [<c176d888>] sysenter_past_esp+0x45/0x74 The reason is: in recovery flow, we use delayed iput mechanism for directory which has recovered dentry block. It means the reference of inode will be held until last dirty dentry page being writebacked. But when we mount f2fs with inline_dentry option, during recovery, dirent may only be recovered into dir inode page rather than dentry page, so there are no chance for us to release inode reference in ->writepage when writebacking last dentry page. We can call paired iget/iput explicityly for inline_dentry case, but for non-inline_dentry case, iput will call writeback_single_inode to write all data pages synchronously, but during recovery, ->writepages of f2fs skips writing all pages, result in losing dirent. This patch fixes this issue by obsoleting old mechanism, and introduce a new dir_list to hold all directory inodes which has recovered datas until finishing recovery. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 16 --------------- fs/f2fs/f2fs.h | 2 -- fs/f2fs/recovery.c | 56 +++++++++++++++++++++++++++++----------------------- 3 files changed, 31 insertions(+), 43 deletions(-) commit b5a7aef1ef436ec005fef0efe31a676ec5f4ab31 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed May 4 22:05:01 2016 -0700 fscrypto/f2fs: allow fs-specific key prefix for fs encryption This patch allows fscrypto to handle a second key prefix given by filesystem. The main reason is to provide backward compatibility, since previously f2fs used "f2fs:" as a crypto prefix instead of "fscrypt:". Later, ext4 should also provide key_prefix() to give "ext4:". One concern decribed by Ted would be kinda double check overhead of prefixes. In x86, for example, validate_user_key consumes 8 ms after boot-up, which turns out derive_key_aes() consumed most of the time to load specific crypto module. After such the cold miss, it shows almost zero latencies, which treats as a negligible overhead. Note that request_key() detects wrong prefix in prior to derive_key_aes() even. Cc: Ted Tso <tytso@mit.edu> Cc: stable@vger.kernel.org # v4.6 Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/crypto/keyinfo.c | 120 ++++++++++++++++++++++++++++++----------------- fs/f2fs/f2fs.h | 8 ++++ fs/f2fs/super.c | 13 +++++ include/linux/fscrypto.h | 1 + 4 files changed, 98 insertions(+), 44 deletions(-) commit 09210c973af30320edc03a6325422cdd0f03b580 Author: Chao Yu <yuchao0@huawei.com> Date: Thu May 5 19:13:03 2016 +0800 f2fs: avoid panic when truncating to max filesize The following panic occurs when truncating inode which has inline xattr to max filesize. [<ffffffffa013d3be>] get_dnode_of_data+0x4e/0x580 [f2fs] [<ffffffffa013aca1>] ? read_node_page+0x51/0x90 [f2fs] [<ffffffffa013ad99>] ? get_node_page.part.34+0xb9/0x170 [f2fs] [<ffffffffa01235b1>] truncate_blocks+0x131/0x3f0 [f2fs] [<ffffffffa01238e3>] f2fs_truncate+0x73/0x100 [f2fs] [<ffffffffa01239d2>] f2fs_setattr+0x62/0x2a0 [f2fs] [<ffffffff811a72c8>] notify_change+0x158/0x300 [<ffffffff8118a42b>] do_truncate+0x6b/0xa0 [<ffffffff8118e539>] ? __sb_start_write+0x49/0x100 [<ffffffff8118a798>] do_sys_ftruncate.constprop.12+0x118/0x170 [<ffffffff8118a82e>] SyS_ftruncate+0xe/0x10 [<ffffffff8169efcf>] tracesys+0xe1/0xe6 [<ffffffffa0139ae0>] get_node_path+0x210/0x220 [f2fs] <ffff880206a89ce8> --[ end trace 5fea664dfbcc6625 ]--- The reason is truncate_blocks tries to truncate all node and data blocks start from specified block offset with value of (max filesize / block size), but actually, our valid max block offset is (max filesize / block size) - 1, so f2fs detects such invalid block offset with BUG_ON in truncation path. This patch lets f2fs skip truncating data which is exceeding max filesize. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 43473f96453f0b075c480a26ec4fc846d5fb3bd4 Author: Chao Yu <yuchao0@huawei.com> Date: Thu May 5 19:13:02 2016 +0800 f2fs: fix incorrect mapping in ->bmap Currently, generic_block_bmap is used in f2fs_bmap, its semantics is when the mapping is been found, return position of target physical block, otherwise return zero. But, previously, when there is no mapping info for specified logical block, f2fs_bmap will map target physical block to a uninitialized variable, which should be wrong. Fix it. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit fb58ae22067e0595d974e3d856522c1ed6d2d7bf Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed May 4 09:58:10 2016 -0700 f2fs: remove an obsolete variable This patch removes an obsolete variable used in add_free_nid. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/node.c | 3 --- 1 file changed, 3 deletions(-) commit 29234b1d6d2d4ecbd8f85831285c20329617859f Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed May 4 19:48:53 2016 -0700 f2fs: don't worry about inode leak in evict_inode Even if an inode failed to release its blocks, it should be kept in an orphan inode list, so it will be released later. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/inode.c | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) commit f51b4ce6c1759a64d68d314545854dc226ab69a0 Author: Chao Yu <yuchao0@huawei.com> Date: Wed May 4 23:19:48 2016 +0800 f2fs: shrink size of struct seg_entry Restructure struct seg_entry to eliminate holes in it, after that, in 32-bits machine, it reduces size from 32 bytes to 24 bytes; in 64-bits machine, it reduces size from 56 bytes to 40 bytes. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/segment.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit bd933d4faedf3a79034e67e8032d153bf1afcd83 Author: Chao Yu <yuchao0@huawei.com> Date: Wed May 4 23:19:47 2016 +0800 f2fs: reuse get_extent_info Reuse get_extent_info for readability. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/extent_cache.c | 3 +-- fs/f2fs/f2fs.h | 8 ++++---- 2 files changed, 5 insertions(+), 6 deletions(-) commit e3bc808ca869f0070d438257e4085602636498da Author: Chao Yu <yuchao0@huawei.com> Date: Wed May 4 23:19:46 2016 +0800 f2fs: remove unneeded memset when updating xattr Each of fields in struct f2fs_xattr_entry will be assigned later, so previously we don't need to memset the struct. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/xattr.c | 1 - 1 file changed, 1 deletion(-) commit ae8d1db34ff57b11feceeaaa26940015b14e30fb Author: Chao Yu <yuchao0@huawei.com> Date: Wed May 4 23:17:00 2016 +0800 f2fs: remove unneeded readahead in find_fsync_dnodes In find_fsync_dnodes, get_tmp_page will read dnode page synchronously, previously, ra_meta_page did the same work, which is redundant, remove it. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/recovery.c | 2 -- 1 file changed, 2 deletions(-) commit 4c0c294934b055aca765737c3b06698f51e9124d Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue May 3 09:22:18 2016 -0700 f2fs: retry to truncate blocks in -ENOMEM case This patch modifies to retry truncating node blocks in -ENOMEM case. Signed-off-by: Hou Pengyang <houpengyang@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/inode.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 74ef924167ad9d2897ffc0ef83c7ebf322fcc535 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon May 2 22:09:56 2016 -0700 f2fs: fix leak of orphan inode objects When unmounting filesystem, we should release all the ino entries. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 6 +++--- fs/f2fs/f2fs.h | 2 +- fs/f2fs/super.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) commit 221149c00e64c202e6e172a9c4efad142a6b610d Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon May 2 12:34:48 2016 -0700 f2fs: revisit error handling flows This patch fixes a couple of bugs regarding to orphan inodes when handling errors. This tries to - call alloc_nid_done with add_orphan_inode in handle_failed_inode - let truncate blocks in f2fs_evict_inode - not make a bad inode due to i_mode change Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/dir.c | 20 ++++++++++++-------- fs/f2fs/inode.c | 40 ++++++++++++++++------------------------ 2 files changed, 28 insertions(+), 32 deletions(-) commit cb78942b821380913e6810375c9ce72858e64c4f Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 16:29:22 2016 -0700 f2fs: inject ENOSPC failures This patch injects ENOSPC failures. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 7 +++++++ fs/f2fs/dir.c | 4 ++++ fs/f2fs/f2fs.h | 10 ++++++++++ fs/f2fs/node.c | 4 ++++ fs/f2fs/super.c | 4 ++++ 5 files changed, 29 insertions(+) commit c41f3cc3ae34acdbcec328084b4b74f686c02f0d Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 16:17:09 2016 -0700 f2fs: inject page allocation failures This patch adds page allocation failures. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 9 +++++++++ fs/f2fs/super.c | 1 + 2 files changed, 10 insertions(+) commit 2c63fead9e372b3b65d1883bb174df6c9820f1dd Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 15:49:56 2016 -0700 f2fs: inject kmalloc failure This patch injects kmalloc failure given a fault injection rate. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 29 +++++++++++++++++++++++++++++ fs/f2fs/super.c | 6 ++++++ 2 files changed, 35 insertions(+) commit 73faec4d99358b79815866dd660ae2f9f6f9110a Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 15:34:32 2016 -0700 f2fs: add mount option to select fault injection ratio This patch adds a mount option to select fault ratio. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/Kconfig | 8 ++++++++ fs/f2fs/f2fs.h | 1 + fs/f2fs/super.c | 19 +++++++++++++++++++ 3 files changed, 28 insertions(+) commit 300e129c15f0ed2f94482900a4cb65b28eb09d94 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 16:11:53 2016 -0700 f2fs: use f2fs_grab_cache_page instead of grab_cache_page This patch converts grab_cache_page to f2fs_grab_cache_page. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 7 ++++--- fs/f2fs/inline.c | 4 ++-- fs/f2fs/node.c | 8 ++++---- 3 files changed, 10 insertions(+), 9 deletions(-) commit 0414b004a894746921bbc05f05dced1e7907b092 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 29 15:16:42 2016 -0700 f2fs: introduce f2fs_kmalloc to wrap kmalloc This patch adds f2fs_kmalloc. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/acl.c | 4 ++-- fs/f2fs/dir.c | 2 +- fs/f2fs/f2fs.h | 5 +++++ fs/f2fs/gc.c | 2 +- fs/f2fs/inline.c | 2 +- 5 files changed, 10 insertions(+), 5 deletions(-) commit f00d6fa727a4c4977241bd21910cafc139f77989 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Apr 27 16:29:05 2016 -0700 f2fs: add proc entry to show valid block bitmap This patch adds a new proc entry to show segment information in more detail. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) commit b7a15f3dbe3f3d009360273b62a633e47a1a65d6 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Apr 27 16:07:56 2016 -0700 f2fs: introduce macros for proc entries This adds macros to be used multiple proc entries. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) commit f1ba9eb85b5e2ad79a3fcd594c6fe4d6956fd163 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Tue Apr 5 14:52:57 2016 -0700 thermal: int340x: processor_thermal: support acpi notification BIOS/EC can change PPCC element dynamically and inform OS about the change. When this driver receives notification, it will read PPCC element again. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com> .../int340x_thermal/processor_thermal_device.c | 108 +++++++++++++++------ 1 file changed, 77 insertions(+), 31 deletions(-) commit b721ca0d192754deccb89fb01c77e41e6fd91ad9 Author: Jacob Pan <jacob.jun.pan@linux.intel.com> Date: Thu Mar 17 11:26:13 2016 -0700 thermal/powerclamp: remove cpu whitelist Powerclamp works by aligning idle time to achieve package level idle states, aka cstates. As long as one of the package cstates is available, synchronized idle injection is meaningful. This patch replaces the CPU whitelist with CPU feature and package cstate counter check such that we don't have to modify this whitelist for every new CPU. Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com> drivers/thermal/intel_powerclamp.c | 47 ++++++++------------------------------ 1 file changed, 9 insertions(+), 38 deletions(-) commit f73696275e64d55c59947b42979b531cb026d718 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon Mar 21 09:19:31 2016 -0300 [media] media-device: Simplify compat32 logic Only MEDIA_IOC_ENUM_LINKS32 require an special logic when userspace is 32 bits and Kernel is 64 bits. For the rest, media_device_ioctl() will do the right thing, and will return -ENOIOCTLCMD if the ioctl is unknown. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-device.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 00303f9134c2db5d17bacda541c07d46517485d9 Author: Colin Ian King <colin.king@canonical.com> Date: Wed Mar 23 10:03:03 2016 -0300 [media] media: i2c: ths7303: remove redundant assignment on bt The extraneous assignment on bt is redundant and can be removed. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/ths7303.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e8e20f1f02eb34b4d446101547159418346b65d4 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Mar 23 07:30:38 2016 -0300 [media] dvb-usb: hide unused functions A couple of data structures in the dibusb-common file are only accessed when CONFIG_DVB_DIB3000MC is enabled, otherwise we get a harmless gcc warning: usb/dvb-usb/dibusb-common.c:223:34: error: 'dib3000p_panasonic_agc_config' defined but not used usb/dvb-usb/dibusb-common.c:211:32: error: 'stk3000p_dib3000p_config' defined but not used This moves the existing #ifdef a few lines up to correctly cover all the conditional data structures, which gets rid of the warning. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/dvb-usb/dibusb-common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c64ee34712eeeee95de0376f424dd4dc7661d3ed Author: Franck Jullien <franck.jullien@odyssee-systemes.fr> Date: Tue Mar 22 07:43:58 2016 -0300 [media] xilinx-vipp: remove unnecessary of_node_put of_graph_get_next_endpoint(node, ep) decrements refcount on ep. When next==NULL we break and refcount on ep is decremented again. Signed-off-by: Franck Jullien <franck.jullien@odyssee-systemes.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/xilinx/xilinx-vipp.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit bf244f665d76d20312c80524689b32a752888838 Author: Max Kellermann <max@duempel.org> Date: Mon Mar 21 10:30:28 2016 -0300 [media] drivers/media/media-devnode: clear private_data before put_device() Callbacks invoked from put_device() may free the struct media_devnode pointer, so any cleanup needs to be done before put_device(). Signed-off-by: Max Kellermann <max@duempel.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-devnode.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c56d34a73ea3622fbc3f5a85140f2353f14b591c Author: Max Kellermann <max@duempel.org> Date: Mon Mar 21 10:30:33 2016 -0300 [media] drivers/media/media-device: move debug log before _devnode_unregister() After media_devnode_unregister(), the struct media_device may be freed already, and dereferencing it may crash. Signed-off-by: Max Kellermann <max@duempel.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-device.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 47cae1e1cfdb6a07ca19c61345c4d96f828b14d7 Author: Max Kellermann <max@duempel.org> Date: Mon Mar 21 08:33:05 2016 -0300 [media] drivers/media/rc: postpone kfree(rc_dev) CONFIG_DEBUG_KOBJECT_RELEASE found this bug. Signed-off-by: Max Kellermann <max@duempel.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/rc/rc-main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit acc37e8f86a8f2a3e1d1dc97d99b7625ccc95424 Author: Max Kellermann <max@duempel.org> Date: Fri Mar 18 18:31:35 2016 -0300 [media] media/dvb-core: forward media_create_pad_links() return value Instead of always return -ENOMEM, return the real error that should come from media_create_pad_link(). Signed-off-by: Max Kellermann <max@duempel.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-core/dvbdev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5f61ff86116cf637ae926f44c1857716ec89e9fb Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Thu Mar 17 16:39:13 2016 -0300 [media] media: rc: reduce size of struct ir_raw_event struct ir_raw_event currently has a size of 12 bytes on most (all?) architectures. This can be reduced to 8 bytes whilst maintaining full backwards compatibility. This saves 2KB in size of struct ir_raw_event_ctrl (as element kfifo is reduced by 512 * 4 bytes) and it allows to copy the full struct ir_raw_event with a single 64 bit operation. Successfully tested with the Nuvoton driver and successfully compile-tested with the ene_ir driver (as it uses the carrier / duty_cycle elements). Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/media/rc-core.h | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) commit 18693843870bfc3ebd682874c1171398f4c8a002 Author: Olli Salonen <olli.salonen@iki.fi> Date: Thu Mar 17 10:11:10 2016 -0300 [media] mceusb: add support for SMK eHome receiver Add USB ID of SMK RXX6000 series IR receiver. Often branded as Lenovo receiver. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/rc/mceusb.c | 3 +++ 1 file changed, 3 insertions(+) commit e186613aed01867b73ca0dcdab91ac29c8da6e2a Author: Olli Salonen <olli.salonen@iki.fi> Date: Thu Mar 17 10:11:09 2016 -0300 [media] mceusb: add support for Adaptec eHome receiver New USB ID for Adaptec eHome receiver in some HP laptops. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/rc/mceusb.c | 3 +++ 1 file changed, 3 insertions(+) commit 36ac2f32598fb4d1d4ab3b15fa63063b8e81a7ab Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Wed Mar 16 18:32:56 2016 -0300 [media] media: rc: remove unneeded mutex in rc_register_device Access to dev->initialized is atomic and dev->initialized isn't accessed in any other code protected by this mutex. Therefore we don't need to get the mutex here. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/rc/rc-main.c | 2 -- 1 file changed, 2 deletions(-) commit a403ceeb6968b7e796c47331d10269cd9c8f7f7e Author: Olli Salonen <olli.salonen@iki.fi> Date: Wed Mar 16 16:16:41 2016 -0300 [media] pctv452e: correct parameters for TechnoTrend TT S2-3600 2008-02-25 Andre Weidemann added support for TT S2-3600 and noted that he still gets image distortions every now and then. It seems to be common knowledge in many projects that changing the USB parameters seems to help. OpenELEC has included this patch for a few years, for example. Nobody bothered to report the issue upstream though, it seems. https://github.com/OpenELEC/OpenELEC.tv/issues/1957 http://www.vdr-portal.de/board60-linux/board14-betriebssystem/board96-yavdr/p1033458-darstellungsproblem-bei-2-tt-3600-usb/#post1033458 (in German) Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/dvb-usb/pctv452e.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 27924dccedb141ac965076f332126236aad65e6f Author: Olli Salonen <olli.salonen@iki.fi> Date: Wed Mar 16 08:04:50 2016 -0300 [media] ds3000: return meaningful return codes The ds3000 driver returned 1 as an error code in many places. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-frontends/ds3000.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 6dfe991113504108b04b1c36d09436e1712942b8 Author: Olli Salonen <olli.salonen@iki.fi> Date: Fri Mar 11 03:48:03 2016 -0300 [media] smipcie: add RC map into card configuration options Remove the if..else statement from smipcie-ir.c and add the remote controller map as a configuration parameter for the card. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/smipcie/smipcie-ir.c | 5 +---- drivers/media/pci/smipcie/smipcie-main.c | 4 ++++ drivers/media/pci/smipcie/smipcie.h | 1 + 3 files changed, 6 insertions(+), 4 deletions(-) commit 9b8537de47f4a4fbca571a393d36ba725c9795f7 Author: Olli Salonen <olli.salonen@iki.fi> Date: Wed Mar 9 19:38:28 2016 -0300 [media] smipcie: MAC address printout formatting Modify the printout for MAC address to be more vendor agnostic. Print also the port number. Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/smipcie/smipcie-main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 0ed8289bd6fff6eda3d57ff09e4b54fd823930ab Author: Olli Salonen <olli.salonen@iki.fi> Date: Wed Mar 9 19:38:27 2016 -0300 [media] smipcie: add support for TechnoTrend S2-4200 Twin Add support for TechnoTrend TT-budget S2-4200 Twin DVB-S2 tuner. The device seems to be rather similar to DVBSky S952 V3. This is a PCIe card with 2 tuners. SMI PCIe bridge is used and the card has two Montage M88RS6000 demod/tuners. The M88RS6000 demod/tuner package needs firmware. You can download one here: http://palosaari.fi/linux/v4l-dvb/firmware/M88RS6000/ Signed-off-by: Olli Salonen <olli.salonen@iki.fi> Reviewed-by: Max Nibble <nibble.max@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/smipcie/smipcie-ir.c | 5 ++++- drivers/media/pci/smipcie/smipcie-main.c | 10 ++++++++++ drivers/media/pci/smipcie/smipcie.h | 1 + 3 files changed, 15 insertions(+), 1 deletion(-) commit 869f076bd68b27e0990e3fc5036a8eb571014473 Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Tue Mar 8 17:40:53 2016 -0300 [media] ati_remote: avoid fragile snprintf use Passing overlapping source and destination to snprintf is fragile. Replace with a single (mostly) equivalent call. If one wants to preserve the space preceding udev->product whether or not there was a manufacturer, just remove udev->manufacturer from the && expression. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/rc/ati_remote.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit e57b36c0c46d7288d6d5bd602003b8fcd17efe3f Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Tue Mar 8 17:40:51 2016 -0300 [media] drivers/media/pci/zoran: avoid fragile snprintf use Appending to a string by doing snprintf(buf, bufsize, "%s...", buf, ...) is not guaranteed to work. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/zoran/videocodec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 3a94707d7a7bb1eb82acae5fbc035247dd1ba8a5 Author: Kees Cook <keescook@chromium.org> Date: Fri May 6 15:01:35 2016 -0700 x86/KASLR: Build identity mappings on demand Currently KASLR only supports relocation in a small physical range (from 16M to 1G), due to using the initial kernel page table identity mapping. To support ranges above this, we need to have an identity mapping for the desired memory range before we can decompress (and later run) the kernel. 32-bit kernels already have the needed identity mapping. This patch adds identity mappings for the needed memory ranges on 64-bit kernels. This happens in two possible boot paths: If loaded via startup_32(), we need to set up the needed identity map. If loaded from a 64-bit bootloader, the bootloader will have already set up an identity mapping, and we'll start via the compressed kernel's startup_64(). In this case, the bootloader's page tables need to be avoided while selecting the new uncompressed kernel location. If not, the decompressor could overwrite them during decompression. To accomplish this, we could walk the pagetable and find every page that is used, and add them to mem_avoid, but this needs extra code and will require increasing the size of the mem_avoid array. Instead, we can create a new set of page tables for our own identity mapping instead. The pages for the new page table will come from the _pagetable section of the compressed kernel, which means they are already contained by in mem_avoid array. To do this, we reuse the code from the uncompressed kernel's identity mapping routines. The _pgtable will be shared by both the 32-bit and 64-bit paths to reduce init_size, as now the compressed kernel's _rodata to _end will contribute to init_size. To handle the possible mappings, we need to increase the existing page table buffer size: When booting via startup_64(), we need to cover the old VO, params, cmdline and uncompressed kernel. In an extreme case we could have them all beyond the 512G boundary, which needs (2+2)*4 pages with 2M mappings. And we'll need 2 for first 2M for VGA RAM. One more is needed for level4. This gets us to 19 pages total. When booting via startup_32(), KASLR could move the uncompressed kernel above 4G, so we need to create extra identity mappings, which should only need (2+2) pages at most when it is beyond the 512G boundary. So 19 pages is sufficient for this case as well. The resulting BOOT_*PGT_SIZE defines use the "_SIZE" suffix on their names to maintain logical consistency with the existing BOOT_HEAP_SIZE and BOOT_STACK_SIZE defines. This patch is based on earlier patches from Yinghai Lu and Baoquan He. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jiri Kosina <jkosina@suse.cz> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462572095-11754-4-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/Makefile | 3 + arch/x86/boot/compressed/head_64.S | 4 +- arch/x86/boot/compressed/kaslr.c | 17 +++++ arch/x86/boot/compressed/misc.h | 11 +++ arch/x86/boot/compressed/pagetable.c | 135 +++++++++++++++++++++++++++++++++++ arch/x86/include/asm/boot.h | 19 +++++ 6 files changed, 187 insertions(+), 2 deletions(-) commit cf4fb15b3110df070fe9829a1ef38fef8316fb90 Author: Yinghai Lu <yinghai@kernel.org> Date: Fri May 6 15:01:34 2016 -0700 x86/boot: Split out kernel_ident_mapping_init() In order to support on-demand page table creation when moving the kernel for KASLR, we need to use kernel_ident_mapping_init() in the decompression code. This splits it out into its own file for use outside of init_64.c. Additionally, checking for __pa/__va defines is added since they need to be overridden in the decompression code. [kees: rewrote changelog] Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462572095-11754-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/page.h | 5 +++ arch/x86/mm/ident_map.c | 74 +++++++++++++++++++++++++++++++++++++++++++++ arch/x86/mm/init_64.c | 74 +-------------------------------------------- 3 files changed, 80 insertions(+), 73 deletions(-) commit 8665e6ff2107204f981ba8f9ee37085a003fc9e9 Author: Kees Cook <keescook@chromium.org> Date: Fri May 6 15:01:33 2016 -0700 x86/boot: Clean up indenting for asm/boot.h Before adding more defines to asm/boot.h, this cleans up the existing indenting for readability. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462572095-11754-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/boot.h | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) commit ed09acde44e301b5c13755ab84821fa44b188b5e Author: Kees Cook <keescook@chromium.org> Date: Fri May 6 12:44:59 2016 -0700 x86/KASLR: Improve comments around the mem_avoid[] logic This attempts to improve the comments that describe how the memory range used for decompression is avoided. Additionally uses an enum instead of raw numbers for the mem_avoid[] indexing. Suggested-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/20160506194459.GA16480@www.outflux.net Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 126 ++++++++++++++++++++++++--------------- 1 file changed, 78 insertions(+), 48 deletions(-) commit 549f90db68c9f8e21a40ec21c8047441984e7164 Author: Borislav Petkov <bp@suse.de> Date: Fri May 6 13:50:15 2016 +0200 x86/boot: Simplify pointer casting in choose_random_location() Pass them down as 'unsigned long' directly and get rid of more casting and assignments. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Kees Cook <keescook@chromium.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: akpm@linux-foundation.org Cc: bhe@redhat.com Cc: dyoung@redhat.com Cc: linux-tip-commits@vger.kernel.org Cc: luto@kernel.org Cc: vgoyal@redhat.com Cc: yinghai@kernel.org Link: http://lkml.kernel.org/r/20160506115015.GI24044@pd.tnic Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 17 ++++++----------- arch/x86/boot/compressed/misc.c | 3 ++- arch/x86/boot/compressed/misc.h | 10 +++++----- 3 files changed, 13 insertions(+), 17 deletions(-) commit 6c5450ef66816216e574885cf8d3ddb31ef77428 Author: Peter Jones <pjones@redhat.com> Date: Fri May 6 22:39:31 2016 +0100 efivarfs: Make efivarfs_file_ioctl() static There are no callers except through the file_operations struct below this, so it should be static like everything else here. Signed-off-by: Peter Jones <pjones@redhat.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1462570771-13324-6-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> fs/efivarfs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1cfd63166c8e7494a1b457df9bb291a601091c26 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri May 6 22:39:30 2016 +0100 efi: Merge boolean flag arguments The parameters atomic and duplicates of efivar_init always have opposite values. Drop the parameter atomic, replace the uses of !atomic with duplicates, and update the call sites accordingly. The code using duplicates is slightly reorganized with an 'else', to avoid duplicating the lock code. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Jeremy Kerr <jk@ozlabs.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Matthew Garrett <mjg59@srcf.ucam.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Saurabh Sengar <saurabh.truth@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vaishali Thakkar <vaishali.thakkar@oracle.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1462570771-13324-5-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/efivars.c | 5 ++--- drivers/firmware/efi/vars.c | 23 ++++++++++------------- fs/efivarfs/super.c | 3 +-- include/linux/efi.h | 3 +-- 4 files changed, 14 insertions(+), 20 deletions(-) commit fb7a84cac03541f4da18dfa25b3f4767d4efc6fc Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Fri May 6 22:39:29 2016 +0100 efi/capsule: Move 'capsule' to the stack in efi_capsule_supported() Dan Carpenter reports that passing the address of the pointer to the kmalloc()'d memory for 'capsule' is dangerous: "drivers/firmware/efi/capsule.c:109 efi_capsule_supported() warn: did you mean to pass the address of 'capsule' 108 109 status = efi.query_capsule_caps(&capsule, 1, &max_size, reset); ^^^^^^^^ If we modify capsule inside this function call then at the end of the function we aren't freeing the original pointer that we allocated." Ard Biesheuvel noted that we don't even need to call kmalloc() since the object we allocate isn't very big and doesn't need to persist after the function returns. Place 'capsule' on the stack instead. Suggested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Bryan O'Donoghue <pure.logic@nexus-software.ie> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1462570771-13324-4-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/capsule.c | 29 +++++++++++------------------ 1 file changed, 11 insertions(+), 18 deletions(-) commit 2e121d711a51f91e792595a05cf9ef6963cb8464 Author: Jeremy Compostella <jeremy.compostella@intel.com> Date: Fri May 6 22:39:28 2016 +0100 efibc: Fix excessive stack footprint warning GCC complains about a newly added file for the EFI Bootloader Control: drivers/firmware/efi/efibc.c: In function 'efibc_set_variable': drivers/firmware/efi/efibc.c:53:1: error: the frame size of 2272 bytes is larger than 1024 bytes [-Werror=frame-larger-than=] The problem is the declaration of a local variable of type struct efivar_entry, which is by itself larger than the warning limit of 1024 bytes. Use dynamic memory allocation instead of stack memory for the entry object. This patch also fixes a potential buffer overflow. Reported-by: Ingo Molnar <mingo@kernel.org> Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com> [ Updated changelog to include GCC error ] Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1462570771-13324-3-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/efibc.c | 34 +++++++++++++++++++++++----------- 1 file changed, 23 insertions(+), 11 deletions(-) commit 62075e581802ea1842d5d3c490a7e46330bdb9e1 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Fri May 6 22:39:27 2016 +0100 efi/capsule: Make efi_capsule_pending() lockless Taking a mutex in the reboot path is bogus because we cannot sleep with interrupts disabled, such as when rebooting due to panic(), BUG: sleeping function called from invalid context at kernel/locking/mutex.c:97 in_atomic(): 0, irqs_disabled(): 1, pid: 7, name: rcu_sched Call Trace: dump_stack+0x63/0x89 ___might_sleep+0xd8/0x120 __might_sleep+0x49/0x80 mutex_lock+0x20/0x50 efi_capsule_pending+0x1d/0x60 native_machine_emergency_restart+0x59/0x280 machine_emergency_restart+0x19/0x20 emergency_restart+0x18/0x20 panic+0x1ba/0x217 In this case all other CPUs will have been stopped by the time we execute the platform reboot code, so 'capsule_pending' cannot change under our feet. We wouldn't care even if it could since we cannot wait for it complete. Also, instead of relying on the external 'system_state' variable just use a reboot notifier, so we can set 'stop_capsules' while holding 'capsule_mutex', thereby avoiding a race where system_state is updated while we're in the middle of efi_capsule_update_locked() (since CPUs won't have been stopped at that point). Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Bryan O'Donoghue <pure.logic@nexus-software.ie> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1462570771-13324-2-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/capsule.c | 35 +++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) commit 35dc9ec1076b79c31bf7ed538af008b7f23bb14d Merge: 0ec7ae9 0783783 Author: Ingo Molnar <mingo@kernel.org> Date: Sat May 7 07:00:07 2016 +0200 Merge branch 'linus' into efi/core, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit ea7c28518943b26a85d73cd76acd03b71962cb18 Merge: c0edb74 d5d71e8 Author: Ingo Molnar <mingo@kernel.org> Date: Sat May 7 06:49:28 2016 +0200 Merge tag 'perf-core-for-mingo-20160506' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Fix ordering of kernel/user entries in 'caller' mode, where the kernel and user parts were being correctly inverted but kept in place wrt each other, i.e. 'callee' (k1, k2, u3, u4) became 'caller' (k2, k1, u4, u3) when it should be 'caller' (u4, u3, k2, k1) (Chris Phlipot) - In 'perf trace' don't print the raw arg syscall args for a syscall that has no arguments, like gettid(). This was happening because just checking if the syscall args list is NULL may mean that there are no args (e.g.: gettid) or that there is no tracepoint info (e.g.: clone) (Arnaldo Carvalho de Melo) - Add extra output of counter values with 'perf stat -vv' (Andi Kleen) Infrastructure changes: - Expose callchain db export via the python API (Chris Phlipot) Code reorganization: - Move some more syscall arg beautifiers from the 'perf trace' main file to separate files in tools/perf/trace/beauty/, to reduce the main file line count (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 9c574ad4d360353ec8dd6bc85e78d8b2d0f8e775 Author: Antti Palosaari <crope@iki.fi> Date: Wed Apr 27 17:07:03 2016 -0300 [media] af9035: correct eeprom offsets Used memory mapped eeprom offsets were off-by 8 bytes. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/dvb-usb-v2/af9035.h | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit ab4d14528fdf946dfa7177b53e64f78bf8cce03a Author: Satoshi Nagahama <sattnag@aim.com> Date: Fri May 6 16:35:05 2016 -0300 [media] em28xx: add support for PLEX PX-BCUD (ISDB-S) PX-BCUD has the following components: USB interface: Empia EM28178 Demodulator: Toshiba TC90532 (works by code for TC90522) Tuner: Next version of Sharp QM1D1C0042 em28xx_dvb_init(): add init code for PLEX PX-BCUD with calling px_bcud_init() that does things like pin configuration. qm1d1c0042_init(): support the next version of QM1D1C0042, change to choose an appropriate array of initial registers by reading chip id. [mchehab@osg.samsung.com: fold a fixup patch and fix checkpatch.pl errors/warnings, where applicable] Signed-off-by: Satoshi Nagahama <sattnag@aim.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/tuners/qm1d1c0042.c | 38 +++++++--- drivers/media/usb/em28xx/Kconfig | 2 + drivers/media/usb/em28xx/em28xx-cards.c | 30 ++++++++ drivers/media/usb/em28xx/em28xx-dvb.c | 121 ++++++++++++++++++++++++++++++++ drivers/media/usb/em28xx/em28xx.h | 1 + 5 files changed, 181 insertions(+), 11 deletions(-) commit 5113bfdbc63845402eec7f419204d22283c9cd4c Author: Jiri Pirko <jiri@mellanox.com> Date: Fri May 6 22:20:59 2016 +0200 mlxsw: spectrum: Fix ordering in mlxsw_sp_fini Fixes: 0f433fa0ec ("mlxsw: spectrum_buffers: Implement shared buffer configuration") Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d3da3eaef7f4d0317d01c08824b65e5aee1315ef Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Thu Apr 14 17:33:33 2016 +0200 clk: mvebu: new driver for Armada CP110 system controller The Armada CP110 system controller provides, amongst other things, a number of clocks for the platform: a small number of core clocks, and then a number of gatable clocks, derived from some of the core clocks. Those clocks are configured via registers of the CP110 System Controller. The CP110 is the other core HW block (next to the AP806) used in the Marvel Armada 7K and 8K SoCs. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> [sboyd@codeaurora.org: Silence some checkpatch noise] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mvebu/Kconfig | 3 + drivers/clk/mvebu/Makefile | 1 + drivers/clk/mvebu/cp110-system-controller.c | 406 ++++++++++++++++++++++++++++ 3 files changed, 410 insertions(+) commit 17af2bce88d31e65ed73d638bb752d2e13c66ced Author: Marc Angel <marc@arista.com> Date: Thu May 5 12:14:26 2016 +0200 macvtap: add namespace support to the sysfs device class When creating macvtaps that are expected to have the same ifindex in different network namespaces, only the first one will succeed. The others will fail with a sysfs_warn_dup warning due to them trying to create the following sysfs link (with 'NN' the ifindex of macvtapX): /sys/class/macvtap/tapNN -> /sys/devices/virtual/net/macvtapX/tapNN This is reproducible by running the following commands: ip netns add ns1 ip netns add ns2 ip link add veth0 type veth peer name veth1 ip link set veth0 netns ns1 ip link set veth1 netns ns2 ip netns exec ns1 ip l add link veth0 macvtap0 type macvtap ip netns exec ns2 ip l add link veth1 macvtap1 type macvtap The last command will fail with "RTNETLINK answers: File exists" (along with the kernel warning) but retrying it will work because the ifindex was incremented. The 'net' device class is isolated between network namespaces so each one has its own hierarchy of net devices. This isn't the case for the 'macvtap' device class. The problem occurs half-way through the netdev registration, when `macvtap_device_event` is called-back to create the 'tapNN' macvtap class device under the 'macvtapX' net class device. This patch adds namespace support to the 'macvtap' device class so that /sys/class/macvtap is no longer shared between net namespaces. However, making the macvtap sysfs class namespace-aware has the side effect of changing /sys/devices/virtual/net/macvtapX/tapNN into /sys/devices/virtual/net/macvtapX/macvtap/tapNN. This is due to Commit 24b1442 ("Driver-core: Always create class directories for classses that support namespaces") and the fact that class devices supporting namespaces are really not supposed to be placed directly under other class devices. To avoid breaking userland, a tapNN symlink pointing to macvtap/tapNN is created inside the macvtapX directory. Signed-off-by: Marc Angel <marc@arista.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macvtap.c | 36 ++++++++++++++++++++++++++---------- 1 file changed, 26 insertions(+), 10 deletions(-) commit 6e660e5cd0709f0f8f1e2cf375d204db645b1a51 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Thu Apr 14 17:33:32 2016 +0200 dt-bindings: arm: add DT binding for Marvell CP110 system controller This commit adds the DT binding documentation for the Marvell CP110 system controller, which is part of the CP110 HW block, itself used in the Marvell Armada 7K and 8K SoCs. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Acked-by: Rob Herring <rob@kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../arm/marvell/cp110-system-controller0.txt | 83 ++++++++++++++++++++++ 1 file changed, 83 insertions(+) commit 89a426b1966588eb215ec08530054016ee10b0cc Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Thu Apr 14 17:33:31 2016 +0200 clk: mvebu: new driver for Armada AP806 system controller The Armada AP806 system controller, amongst other things, provides a number of clocks for the platform: the CPU cluster clocks, whose frequencies are found by reading the Sample At Reset register, one fixed clock, and another clock derived from the fixed clock, which is the one used by most peripherals in AP806. The AP806 is one of the two core HW blocks used in the Marvell 7K/8K SoCs. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> [sboyd@codeaurora.org: Silence some checkpatch noise] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mvebu/Kconfig | 3 + drivers/clk/mvebu/Makefile | 1 + drivers/clk/mvebu/ap806-system-controller.c | 168 ++++++++++++++++++++++++++++ 3 files changed, 172 insertions(+) commit bf7cdff19429a72c32257da70d5345ffca66d861 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 15:00:38 2016 +0200 cpufreq: schedutil: Make it depend on CONFIG_SMP Make the schedutil cpufreq governor depend on CONFIG_SMP, because the scheduler-provided utilization numbers used by it are only available with CONFIG_SMP set. Fixes: 9bdcb44e391d (cpufreq: schedutil: New governor based on scheduler utilization data) Reported-by: Steve Muckle <steve.muckle@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fd7c3c29f9abab50a84fd4fd6811129641c53b2f Merge: 625fe4f e93e59c Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 22:08:46 2016 +0200 Merge back new cpuidle material for v4.7. commit dab2e29402f40431d2199e6faff48174204d2d06 Merge: 0224a4a f4d0526 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 22:07:33 2016 +0200 Merge back new device properties material for v4.7. commit c8541203a680a63ba7dcc4e50cd25d40e9a13dff Merge: 21f8a99 f47b72a Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 22:05:16 2016 +0200 Merge back new material for v4.7. commit 47dcc20a39d06585bf3cb9fb381f0e81c20002c3 Author: Eric Dumazet <edumazet@google.com> Date: Fri May 6 09:46:18 2016 -0700 ipv4: tcp: ip_send_unicast_reply() is not BH safe I forgot that ip_send_unicast_reply() is not BH safe (yet). Disabling preemption before calling it was not a good move. Fixes: c10d9310edf5 ("tcp: do not assume TCP code is non preemptible") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Andres Lagar-Cavilla <andreslc@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_ipv4.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4b307a8edb6b6f59b6f2bfe9f36fcec6e43ec911 Merge: 95aef7c 883e44e Author: David S. Miller <davem@davemloft.net> Date: Fri May 6 16:01:55 2016 -0400 Merge branch 'bpf-direct-pkt-access' Alexei Starovoitov says: ==================== bpf: introduce direct packet access This set of patches introduce 'direct packet access' from cls_bpf and act_bpf programs (which are root only). Current bpf programs use LD_ABS, LD_INS instructions which have to do 'if (off < skb_headlen)' for every packet access. It's ok for socket filters, but too slow for XDP, since single LD_ABS insn consumes 3% of cpu. Therefore we have to amortize the cost of length check over multiple packet accesses via direct access to skb->data, data_end pointers. The existing packet parser typically look like: if (load_half(skb, offsetof(struct ethhdr, h_proto)) != ETH_P_IP) return 0; if (load_byte(skb, ETH_HLEN + offsetof(struct iphdr, protocol)) != IPPROTO_UDP || load_byte(skb, ETH_HLEN) != 0x45) return 0; ... with 'direct packet access' the bpf program becomes: void *data = (void *)(long)skb->data; void *data_end = (void *)(long)skb->data_end; struct eth_hdr *eth = data; struct iphdr *iph = data + sizeof(*eth); if (data + sizeof(*eth) + sizeof(*iph) + sizeof(*udp) > data_end) return 0; if (eth->h_proto != htons(ETH_P_IP)) return 0; if (iph->protocol != IPPROTO_UDP || iph->ihl != 5) return 0; ... which is more natural to write and significantly faster. See patch 6 for performance tests: 21Mpps(old) vs 24Mpps(new) with just 5 loads. For more complex parsers the performance gain is higher. The other approach implemented in [1] was adding two new instructions to interpreter and JITs and was too hard to use from llvm side. The approach presented here doesn't need any instruction changes, but the verifier has to work harder to check safety of the packet access. Patch 1 prepares the code and Patch 2 adds new checks for direct packet access and all of them are gated with 'env->allow_ptr_leaks' which is true for root only. Patch 3 improves search pruning for large programs. Patch 4 wires in verifier's changes with net/core/filter side. Patch 5 updates docs Patches 6 and 7 add tests. [1] https://git.kernel.org/cgit/linux/kernel/git/ast/bpf.git/?h=ld_abs_dw ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 883e44e4de71c023d3d74e02f35ca462c67d07dc Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:15 2016 -0700 samples/bpf: add verifier tests add few tests for "pointer to packet" logic of the verifier Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/test_verifier.c | 80 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) commit 65d472fb007dd73ef28f70078f43f86bb6cc67d0 Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:14 2016 -0700 samples/bpf: add 'pointer to packet' tests parse_simple.c - packet parser exapmle with single length check that filters out udp packets for port 9 parse_varlen.c - variable length parser that understand multiple vlan headers, ipip, ipip6 and ip options to filter out udp or tcp packets on port 9. The packet is parsed layer by layer with multitple length checks. parse_ldabs.c - classic style of packet parsing using LD_ABS instruction. Same functionality as parse_simple. simple = 24.1Mpps per core varlen = 22.7Mpps ldabs = 21.4Mpps Parser with LD_ABS instructions is slower than full direct access parser which does more packet accesses and checks. These examples demonstrate the choice bpf program authors can make between flexibility of the parser vs speed. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 2 + samples/bpf/parse_ldabs.c | 41 ++++++++++++ samples/bpf/parse_simple.c | 48 ++++++++++++++ samples/bpf/parse_varlen.c | 153 ++++++++++++++++++++++++++++++++++++++++++++ samples/bpf/test_cls_bpf.sh | 37 +++++++++++ 5 files changed, 281 insertions(+) commit f9c8d19d6c7c15a59963f80ec47e68808914abd4 Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:13 2016 -0700 bpf: add documentation for 'direct packet access' explain how verifier checks safety of packet access and update email addresses. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/filter.txt | 85 ++++++++++++++++++++++++++++++++++++- 1 file changed, 83 insertions(+), 2 deletions(-) commit db58ba45920255e967cc1d62a430cebd634b5046 Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:12 2016 -0700 bpf: wire in data and data_end for cls_act_bpf allow cls_bpf and act_bpf programs access skb->data and skb->data_end pointers. The bpf helpers that change skb->data need to update data_end pointer as well. The verifier checks that programs always reload data, data_end pointers after calls to such bpf helpers. We cannot add 'data_end' pointer to struct qdisc_skb_cb directly, since it's embedded as-is by infiniband ipoib, so wrapper struct is needed. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/filter.h | 16 ++++++++++++++++ net/core/filter.c | 51 ++++++++++++++++++++++++++++++++++++++++++++------ net/sched/act_bpf.c | 2 ++ net/sched/cls_bpf.c | 2 ++ 4 files changed, 65 insertions(+), 6 deletions(-) commit 735b433397ea2f97d59240cbe4ea770aa7c88eef Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:11 2016 -0700 bpf: improve verifier state equivalence since UNKNOWN_VALUE type is weaker than CONST_IMM we can un-teach verifier its recognition of constants in conditional branches without affecting safety. Ex: if (reg == 123) { .. here verifier was marking reg->type as CONST_IMM instead keep reg as UNKNOWN_VALUE } Two verifier states with UNKNOWN_VALUE are equivalent, whereas CONST_IMM_X != CONST_IMM_Y, since CONST_IMM is used for stack range verification and other cases. So help search pruning by marking registers as UNKNOWN_VALUE where possible instead of CONST_IMM. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) commit 969bf05eb3cedd5a8d4b7c346a85c2ede87a6d6d Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:10 2016 -0700 bpf: direct packet access Extended BPF carried over two instructions from classic to access packet data: LD_ABS and LD_IND. They're highly optimized in JITs, but due to their design they have to do length check for every access. When BPF is processing 20M packets per second single LD_ABS after JIT is consuming 3% cpu. Hence the need to optimize it further by amortizing the cost of 'off < skb_headlen' over multiple packet accesses. One option is to introduce two new eBPF instructions LD_ABS_DW and LD_IND_DW with similar usage as skb_header_pointer(). The kernel part for interpreter and x64 JIT was implemented in [1], but such new insns behave like old ld_abs and abort the program with 'return 0' if access is beyond linear data. Such hidden control flow is hard to workaround plus changing JITs and rolling out new llvm is incovenient. Therefore allow cls_bpf/act_bpf program access skb->data directly: int bpf_prog(struct __sk_buff *skb) { struct iphdr *ip; if (skb->data + sizeof(struct iphdr) + ETH_HLEN > skb->data_end) /* packet too small */ return 0; ip = skb->data + ETH_HLEN; /* access IP header fields with direct loads */ if (ip->version != 4 || ip->saddr == 0x7f000001) return 1; [...] } This solution avoids introduction of new instructions. llvm stays the same and all JITs stay the same, but verifier has to work extra hard to prove safety of the above program. For XDP the direct store instructions can be allowed as well. The skb->data is NET_IP_ALIGNED, so for common cases the verifier can check the alignment. The complex packet parsers where packet pointer is adjusted incrementally cannot be tracked for alignment, so allow byte access in such cases and misaligned access on architectures that define efficient_unaligned_access [1] https://git.kernel.org/cgit/linux/kernel/git/ast/bpf.git/?h=ld_abs_dw Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/bpf.h | 2 + kernel/bpf/core.c | 5 + kernel/bpf/verifier.c | 441 ++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 440 insertions(+), 8 deletions(-) commit 1a0dc1ac1d2928e25739ee82d7e04423b01da563 Author: Alexei Starovoitov <ast@fb.com> Date: Thu May 5 19:49:09 2016 -0700 bpf: cleanup verifier code cleanup verifier code and prepare it for addition of "pointer to packet" logic Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 100 ++++++++++++++++++++++++++------------------------ 1 file changed, 53 insertions(+), 47 deletions(-) commit da43af961b50f1b6367660c0dba0b5fd205c4217 Merge: 9485e4c 6d45b71 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 22:01:14 2016 +0200 Merge cpufreq fixes going into v4.6. * pm-cpufreq-fixes: intel_pstate: Fix intel_pstate_get() cpufreq: intel_pstate: Fix HWP on boot CPU after system resume cpufreq: st: enable selective initialization based on the platform cpufreq: intel_pstate: Fix processing for turbo activation ratio commit 95aef7cecbc229e7d6dc26780a7d39e864dc1ed8 Merge: b3b4663 3949c4a Author: David S. Miller <davem@davemloft.net> Date: Fri May 6 15:55:30 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-05-05 This series contains updates to i40e and i40evf. The theme behind this series is code reduction, yeah! Jesse provides most of the changes starting with a refactor of the interpretation of a tunnel which lets us start using the hardware's parsing. Removed the packet split receive routine and ancillary code in preparation for the Rx-refactor. The refactor of the receive routine, aligns the receive routine with the one in ixgbe which was highly optimized. The hardware supports a 16 byte descriptor for receive, but the driver was never using it in production. There was no performance benefit to the real driver of 16 byte descriptors, so drop a whole lot of complexity while getting rid of the code. Fixed a bug where while changing the number of descriptors using ethtool, the driver did not test the limits of the system memory before permanently assuming it would be able to get receive buffer memory. Mitch fixes a memory leak of one page each time the driver is opened by allocating the correct number of receive buffers and do not fiddle with next_to_use in the VF driver. Arnd Bergmann fixed a indentation issue by adding the appropriate curly braces in i40e_vc_config_promiscuous_mode_msg(). Julia Lawall fixed an issue found by Coccinelle, where i40e_client_ops structure can be const since it is never modified. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a0af53b511423cca93900066512379e21586d7dd Author: Tedd Ho-Jeong An <tedd.an@intel.com> Date: Fri May 6 11:53:46 2016 -0700 Bluetooth: Add support for Intel Bluetooth device 8265 [8087:0a2b] This patch adds support for Intel Bluetooth device 8265 also known as Windstorm Peak (WsP). T: Bus=01 Lev=01 Prnt=01 Port=01 Cnt=02 Dev#= 6 Spd=12 MxCh= 0 D: Ver= 2.00 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=64 #Cfgs= 1 P: Vendor=8087 ProdID=0a2b Rev= 0.10 C:* #Ifs= 2 Cfg#= 1 Atr=e0 MxPwr=100mA I:* If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=81(I) Atr=03(Int.) MxPS= 64 Ivl=1ms E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms I: If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms I: If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms I: If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms I: If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms I: If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms Signed-off-by: Tedd Ho-Jeong An <tedd.an@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/btusb.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit b3b4663c973bf11ef19243fa4f1a544cbdc2fa8e Author: David Ahern <dsa@cumulusnetworks.com> Date: Wed May 4 21:46:12 2016 -0700 net: vrf: Create FIB tables on link create Tables have to exist for VRFs to function. Ensure they exist when VRF device is created. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vrf.c | 13 +++++++++++-- net/ipv4/fib_frontend.c | 1 + net/ipv6/ip6_fib.c | 1 + 3 files changed, 13 insertions(+), 2 deletions(-) commit f37bd0cced37189fc5dd34a85c90710700fd38d5 Author: Jon Maxwell <jmaxwell37@gmail.com> Date: Thu May 5 09:55:51 2016 +1000 cnic: call cp->stop_hw() in cnic_start_hw() on allocation failure We recently had a system crash in the cnic module. Vmcore analysis confirmed that "ip link up" was executed which failed due to an allocation failure because of memory fragmentation. Futher analysis revealed that the cnic irq vector was still allocated after the "ip link up" that failed. When "ip link down" was executed it called free_msi_irqs() which crashed the system because the cnic irq was still inuse. PANIC: "kernel BUG at drivers/pci/msi.c:411!" The code execution was: cnic_netdev_event() if (event == NETDEV_UP) { . . ▹ if (!cnic_start_hw(dev)) cnic_start_hw() calls cnic_cm_open() which failed with -ENOMEM cnic_start_hw() then took the err1 path: err1:↩ cp->free_resc(dev);↩ <---- frees resources but not irq vector pci_dev_put(dev->pcidev);↩ return err;↩ }↩ This returns control back to cnic_netdev_event() but now the cnic irq vector is still allocated even although cnic_cm_open() failed. The next "ip link down" while trigger the crash. The cnic_start_hw() routine is not handling the allocation failure correctly. Fix this by checking whether CNIC_DRV_STATE_HANDLES_IRQ flag is set indicating that the hardware has been started in cnic_start_hw(). If it has then call cp->stop_hw() which frees the cnic irq vector and cnic resources. Otherwise just maintain the previous behaviour and free cnic resources. I reproduced this by injecting an ENOMEM error into cnic_cm_alloc_mem()s return code. # ip link set dev enpX down # ip link set dev enpX up <--- hit's allocation failure # ip link set dev enpX down <--- crashes here With this patch I confirmed there was no crash in the reproducer. Signed-off-by: Jon Maxwell <jmaxwell37@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/cnic.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 7977a15ede1d2d95446ff26a9e34a7b16c0fd12f Author: Olli Salonen <olli.salonen@iki.fi> Date: Wed Mar 16 08:56:30 2016 -0300 [media] az6027: Add support for Elgato EyeTV Sat v3 Another version of Elgato EyeTV Sat USB DVB-S2 adapter needs just a USB ID addition. Signed-off-by: Christian Knippel <namerp@gmail.com> Reported-by: Olli Salonen <olli.salonen@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-core/dvb-usb-ids.h | 1 + drivers/media/usb/dvb-usb/az6027.c | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) commit 7e31223ff0196dc5c5e8124b3c05ab4a25847c59 Author: Kevin Fitch <kfitch42@gmail.com> Date: Wed Mar 23 01:23:32 2016 -0300 [media] i2c: saa7115: Support CJC7113 detection It's been reported that CJC7113 devices are returning all 1s when reading register 0: "1111111111111111" found @ 0x4a (stk1160) This new device is apparently compatible with SA7113, so let's add a quirk to allow its autodetection. Given there isn't any known differences with SAA7113, this commit does not introduces a new saa711x_model value. Reported-by: Philippe Desrochers <desrochers.philippe@gmail.com> Signed-off-by: Kevin Fitch <kfitch42@gmail.com> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/saa7115.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 116f7d4a21fe450efc652c4850eb27cda36c9db0 Author: Javier González <jg@lightnvm.io> Date: Fri May 6 20:03:21 2016 +0200 lightnvm: reserved space calculation incorrect The nvm_dev->max_pages_per_blk variable was removed in favor of the new nvm->sec_per_blk variable. The ->max_pages_per_blk variable was still used in rrpc_capacity, reporting the reserved capacity to zero. Replace with ->sec_per_blk to calculate the reserved area again. Signed-off-by: Javier González <javier@cnexlabs.com> Updated patch description. Was "lightnvm: eliminate redundant variable" Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/rrpc.c | 2 +- include/linux/lightnvm.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) commit 6d5be9590b5e15124e3c8b319c8d7ce01abcf07d Author: Javier González <jg@lightnvm.io> Date: Fri May 6 20:03:20 2016 +0200 lightnvm: rename nr_pages to nr_ppas on nvm_rq The number of ppas contained on a request is not necessarily the number of pages that it maps to neither on the target nor on the device side. In order to avoid confusion, rename nr_pages to nr_ppas since it is what the variable actually contains. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 16 ++++++++-------- drivers/lightnvm/gennvm.c | 2 +- drivers/lightnvm/rrpc.c | 6 +++--- drivers/lightnvm/rrpc.h | 2 +- drivers/lightnvm/sysblk.c | 2 +- drivers/nvme/host/lightnvm.c | 4 ++-- include/linux/lightnvm.h | 2 +- 7 files changed, 17 insertions(+), 17 deletions(-) commit df414b33bb1eb3a0ae52ccd4ecfec9323a4f89dc Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:19 2016 +0200 lightnvm: add is_cached entry to struct ppa_addr A target requires a method to identify PPAs that are either cached in memory or on disk. This can efficiently be maintained within the PPA. The target host-side translation table can then lookup a PPA and know from the PPA if it is cached or on disk. In the case it is cached, it is the responsibility of the target to maintain this cache. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> include/linux/lightnvm.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 04a8aa173bd9410849526a80dcf733da9c3e142d Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:18 2016 +0200 lightnvm: expose gennvm_mark_blk to targets Targets can update a block state when having a reference to an in-memory virtual block. In the case that a target does not keep the block metadata in memory, it does not have a way to update this structure. Therefore, expose gennvm_mark_blk() through the media managers ->mark_blk() callback and let targets update the state structure through this callback. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/gennvm.c | 27 ++++++++++++++------------- include/linux/lightnvm.h | 4 ++++ 2 files changed, 18 insertions(+), 13 deletions(-) commit 976bdfcae32ea10c2c8c2ecaeb0d85873f634dad Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:17 2016 +0200 lightnvm: remove mgt targets on mgt removal Targets associated with a device manager are not freed on device removal. They have to be manually removed before shutdown. Make sure any outstanding targets are freed upon shutdown. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 69 ++++++++++++++++++++++++++++++------------------ include/linux/lightnvm.h | 1 + 2 files changed, 44 insertions(+), 26 deletions(-) commit 45bbd0529e5d50aa91a4bb5fffffc5e24df3ef7e Author: Arnd Bergmann <arnd@arndb.de> Date: Fri May 6 20:03:16 2016 +0200 lightnvm: pass dma address to hardware rather than pointer A recent change to lightnvm added code to pass a kernel pointer to the hardware, which gcc complained about: drivers/nvme/host/lightnvm.c: In function 'nvme_nvm_rqtocmd': drivers/nvme/host/lightnvm.c:472:32: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast] c->ph_rw.metadata = cpu_to_le64(rqd->meta_list); It looks like this has no way of working anyway, so this changes the code to pass the dma_address instead. This was most likely what was intended here. Neither of the two are currently ever written to, so the effect is the same for now. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: a34b1eb78e21 ("lightnvm: enable metadata to be sent to device") Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/lightnvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cca87bc9d359f1a03ac34ca095343d1bfa2e6b15 Author: Javier González <jg@lightnvm.io> Date: Fri May 6 20:03:15 2016 +0200 lightnvm: do not assume sequential lun alloc. When doing GC, rrpc calculates the physical LUN to which the rrpc block belongs too. This calculation is based on the assumption that LUNs are assigned sequentially to the LUN list. Use the reference to the LUN instead. This saves us the calculation and allows us to align LUNs in a different manner to, for example, take advantage of devide parallelism. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/rrpc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit b86d8d363ece8fb9a7ec7e951c7f041f47f0f552 Author: Sagi Grimberg <sagi@grimberg.me> Date: Fri May 6 20:03:14 2016 +0200 nvme/lightnvm: Log using the ctrl named device Align with the rest of the nvme subsystem. Signed-off-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/lightnvm.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 75b8564932ef646e8620deffacbe134846333948 Author: Javier González <javier@cnexlabs.com> Date: Fri May 6 20:03:13 2016 +0200 lightnvm: rename dma helper functions Until now, the dma pool have been exclusively used to allocate the ppa list being sent to the device. In pblk (upcoming), we use these pools to allocate metadata too. Thus, we generalize the names of some variables on the dma helper functions to make the code more readable. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 16 ++++++++-------- drivers/nvme/host/lightnvm.c | 4 ++-- include/linux/lightnvm.h | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) commit 003fad376b924fc3a61c659f38da70356ec144fa Author: Javier González <javier@cnexlabs.com> Date: Fri May 6 20:03:12 2016 +0200 lightnvm: enable metadata to be sent to device Enable metadata buffer to be sent to the device through the metadata field on the physical rw nvme command. The size of the metadata buffer must follow dev->oob_size * # of PPAs. Signed-off-by: Javier González <javier@cnexlabs.com> Updated description. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/lightnvm.c | 1 + include/linux/lightnvm.h | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) commit 57682b49154921306a5e7b79c883781230698878 Author: Javier González <javier@cnexlabs.com> Date: Fri May 6 20:03:11 2016 +0200 lightnvm: do not free unused metadata on rrpc rrpc does not save any metadata on a given request. Thus, do not attempt to free the metadata dma region. Signed-off-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/rrpc.c | 2 -- 1 file changed, 2 deletions(-) commit 293a6e8e270f19f676ac4cbe6c653aaf27146ca6 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:10 2016 +0200 lightnvm: fix out of bound ppa lun id on bb tbl The ppa configured for retrieving the bad block table uses the internal lun id to setup the get bad block ppa. This increases monotonically with the number luns available. When configuring a ppa, the channel and lun must be specified separately, leading to an out of bound memory access in gennvm_block_bb when lun id goes beyond the luns available within a channel. Additional, remove out of bound check in gennvm_block_bb(), as it was a buggy to begin with. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/gennvm.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 00ee6cc3b74bdb4dfb71838046517beb6839647c Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:09 2016 +0200 lightnvm: refactor set_bb_tbl for accepting ppa list The set_bb_tbl takes struct nvm_rq and only uses its ppa_list and nr_pages internally. Instead, make these two variables explicit. This allows a user to call it without initializing a struct nvm_rq first. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/sysblk.c | 2 +- drivers/nvme/host/lightnvm.c | 8 ++++---- include/linux/lightnvm.h | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) commit a63d5cf2031cc84443440caf32c175b3548ac6b8 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:08 2016 +0200 lightnvm: move responsibility for bad blk mgmt to target We move the responsibility of managing the persistent bad block table to the target. The target may choose to mark a block bad or retry writing to it. Never the less, it should be the target that makes the decision and not the media manager. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/gennvm.c | 35 ++++++++++++++++------------------- 1 file changed, 16 insertions(+), 19 deletions(-) commit 5ebc7d9fe13ff9bd3622d0be3cd39c8751459be6 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:07 2016 +0200 lightnvm: make nvm_set_rqd_ppalist() aware of vblks A virtual block enables a block to identify multiple physical blocks. This is useful for metadata where a device media supports multiple planes. In that case, a block, with multiple planes can be managed as a single vblk. Reducing the metadata required by one forth. nvm_set_rqd_ppalist() takes care of expanding a ppa_list with vblks automatically. However, for some use-cases, where only a single physical block is required, the ppa_list should not be expanded. Therefore, add a vblk parameter to nvm_set_rqd_ppalist(), and only expand the ppa_list if vblk is set. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 31 +++++++++++++++++-------------- drivers/lightnvm/sysblk.c | 2 +- include/linux/lightnvm.h | 2 +- 3 files changed, 19 insertions(+), 16 deletions(-) commit 6659d4d80c6fc6b4b5bc2e99988f32b1b3865f1d Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:06 2016 +0200 lightnvm: remove struct factory_blks Now that device ops->get_bb_table no longer uses a callback, the struct factory_blks can be removed. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/sysblk.c | 62 +++++++++++++++++++++-------------------------- 1 file changed, 28 insertions(+), 34 deletions(-) commit e11903f5dfeb4f59fe93316d47f2ee5982e91e60 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:05 2016 +0200 lightnvm: refactor device ops->get_bb_tbl() The device ops->get_bb_tbl() takes a callback, that allows the caller to use its own callback function to update its data structures in the returning function. This makes it difficult to send parameters to the callback, and usually is circumvented by small private structures, that both carry the callers state and any flags needed to fulfill the update. Refactor ops->get_bb_tbl() to fill a data buffer with the status of the blocks returned, and let the user call the callback function manually. That will provide the necessary flags and data structures and simplify the logic around ops->get_bb_tbl(). Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 8 +++ drivers/lightnvm/gennvm.c | 29 ++++++--- drivers/lightnvm/sysblk.c | 146 +++++++++++++++++++++++-------------------- drivers/nvme/host/lightnvm.c | 6 +- include/linux/lightnvm.h | 6 +- 5 files changed, 111 insertions(+), 84 deletions(-) commit 5136061ce705210b501ed9ecd673a67b74ebe017 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:03:04 2016 +0200 lightnvm: introduce nvm_for_each_lun_ppa() macro Users that wish to iterate all luns on a device. Must create a struct ppa_addr and separate iterators for channels and luns. To set the iterators, two loops are required, one to iterate channels, and another to iterate luns. This leads to decrease in readability. Introduce nvm_for_each_lun_ppa, which implements the nested loop and sets ppa, channel, and lun variable for each loop body, eliminating the boilerplate code. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/sysblk.c | 64 +++++++++++++++++++---------------------------- include/linux/lightnvm.h | 7 ++++++ 2 files changed, 33 insertions(+), 38 deletions(-) commit 6f8645cba54a4b2983bbd46f462b5891ffbd72fc Author: Simon A. F. Lund <slund@cnexlabs.com> Date: Fri May 6 20:03:03 2016 +0200 lightnvm: refactor dev->online_target to global nvm_targets A target name must be unique. However, a per-device registration of targets is maintained on a dev->online_targets list, with a per-device search for targets upon registration. This results in a name collision when two targets, with the same name, are created on two different targets, where the per-device list is not shared. Signed-off-by: Simon A. F. Lund <slund@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 47 +++++++++++++++++++++++++---------------------- include/linux/lightnvm.h | 1 - 2 files changed, 25 insertions(+), 23 deletions(-) commit 6063fe399d0913e7bd4462650cd4f31b479a83c9 Author: Simon A. F. Lund <slund@cnexlabs.com> Date: Fri May 6 20:03:02 2016 +0200 lightnvm: rename nvm_targets to nvm_tgt_type The functions nvm_register_target(), nvm_unregister_target() and associated list refers to a target type that is being registered by a target type module. Rename nvm_*_targets() to nvm_*_tgt_type(), so that the intension is clear. This enables target instances to use the _nvm_*_targets() naming. Signed-off-by: Simon A. F. Lund <slund@cnexlabs.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 16 ++++++++-------- drivers/lightnvm/rrpc.c | 4 ++-- include/linux/lightnvm.h | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) commit 909049a7199947abbc6a923e4cf5cff1857d4205 Author: Wenwei Tao <ww.tao0320@gmail.com> Date: Fri May 6 20:03:01 2016 +0200 lightnvm: store rrpc->soffset in device sector size Since we mainly use soffset in device sector size, we therefore store this value in rrpc->soffset, instead of the offset in 512byte sector size. This eliminates the "(ilog2(dev->sec_size) - 9)" calculation on each I/O. Signed-off-by: Wenwei Tao <ww.tao0320@gmail.com> Updated patch description. Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/rrpc.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 66e3d07f75c6472d7198920488330634c118b255 Author: Wenwei Tao <ww.tao0320@gmail.com> Date: Fri May 6 20:03:00 2016 +0200 lightnvm: calculate rrpc total blocks and sectors up front Calculate rrpc total blocks and sectors up front, make sense to use them. For example, we use rrpc->nr_sects to calculate rrpc area size, but it makes no sense if we don't initialize it up front, since it would be zero until we finish rrpc luns init. Signed-off-by: Wenwei Tao <ww.tao0320@gmail.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/rrpc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 7f7c5d03c0e8e177d1ed1c6412ae035e8eff35de Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:02:59 2016 +0200 lightnvm: avoid memory leak when lun_map kcalloc fails A memory leak occurs if the lower page table is initialized and the following dev->lun_map fails on allocation. Rearrange the initialization of lower page table to allow dev->lun_map to fail gracefully without memory leak. Reviewed by: Johannes Thumshirn <jthumshirn@suse.de> Move kfree of dev->lun_map to nvm_free() Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 53 ++++++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 23 deletions(-) commit 22e8c9766a669d49cf3749d397082a5cd93374a9 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:02:58 2016 +0200 lightnvm: move block fold outside of get_bb_tbl() The get block table command returns a list of blocks and planes with their associated state. Users, such as gennvm and sysblk, manages all planes as a single virtual block. It was therefore natural to fold the bad block list before it is returned. However, to allow users, which manages on a per-plane block level, to also use the interface, the get_bb_tbl interface is changed to not fold by default and instead let the caller fold if necessary. Reviewed by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 35 +++++++++++++++++++++++++++++++++ drivers/lightnvm/gennvm.c | 14 +++++++------ drivers/lightnvm/sysblk.c | 29 ++++++++++++++++++--------- drivers/nvme/host/lightnvm.c | 47 ++++++-------------------------------------- include/linux/lightnvm.h | 6 ++++-- 5 files changed, 73 insertions(+), 58 deletions(-) commit 4891d120b9cd419f4350b11e1231083745dcdc8b Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:02:57 2016 +0200 lightnvm: add fpg_size and pfpg_size to struct nvm_dev The flash page size (fpg) and size across planes (pfpg) are convenient to know when allocating buffer sizes. This has previously been a calculated in various places. Replace with the pre-calculated values. Reviewed by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 2 ++ drivers/lightnvm/sysblk.c | 17 +++++++---------- include/linux/lightnvm.h | 2 ++ 3 files changed, 11 insertions(+), 10 deletions(-) commit 1145e6351a9fefe0965df4c6dba2a04156dc47d2 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:02:56 2016 +0200 lightnvm: implement nvm_submit_ppa_list The nvm_submit_ppa function assumes that users manage all plane blocks as a single block. Extend the API with nvm_submit_ppa_list to allow the user to send its own ppa list. If the user submits more than a single PPA, the user must take care to allocate and free the corresponding ppa list. Reviewed by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 88 +++++++++++++++++++++++++++++++++++++----------- include/linux/lightnvm.h | 2 ++ 2 files changed, 71 insertions(+), 19 deletions(-) commit ecfb40c6aa5691257054eac81bc8bdfd5442e8e5 Author: Matias Bjørling <m@bjorling.me> Date: Fri May 6 20:02:55 2016 +0200 lightnvm: handle submit_io failure The device ->submit_io() callback might fail to submit I/O to device. In that case, the nvm_submit_ppa function should not wait for completion. Instead return the ->submit_io() error. Reviewed by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/core.c | 5 +++++ 1 file changed, 5 insertions(+) commit 57aac2f1be4a0711b7f24f7d367e8672ebaa3844 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri May 6 20:02:54 2016 +0200 lightnvm: fix "warning: ‘ret’ may be used uninitialized" This fixes the following warnings: drivers/lightnvm/sysblk.c:125:9: warning: ‘ret’ may be used uninitialized in this function drivers/lightnvm/sysblk.c:275:15: warning: ‘ret’ may be used uninitialized in this function In both cases, ret is only set from within a loop that may not be entered. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/lightnvm/sysblk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3d87fa1d47c10c71684e1eca15cb051746ab1d56 Author: Lee Jones <lee.jones@linaro.org> Date: Thu May 5 14:29:39 2016 +0100 remoteproc: core: Task sync during rproc_fw_boot() By default, rproc_fw_boot() needs to wait for rproc to be configured, but a race may occur when using rpmsg/virtio. In this case, it can be called locally in a safe manor. This patch represents two usecases: - External call (via exported rproc_boot()), which waits - Internal call can use 'nowait' version of rproc_boot() Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> drivers/remoteproc/remoteproc_core.c | 29 +++++++++++++++++++++++++++-- drivers/remoteproc/remoteproc_internal.h | 1 + drivers/remoteproc/remoteproc_virtio.c | 2 +- 3 files changed, 29 insertions(+), 3 deletions(-) commit 95dd7b7e30f385c1c2d5e41457c082c5f6c535b3 Author: Hans Verkuil <hverkuil@xs4all.nl> Date: Fri Apr 15 06:27:28 2016 -0300 [media] v4l2-ioctl.c: improve cropcap compatibility code - Add a check for the case that both the cropcap and g_selection ops are NULL. This shouldn't happen, but I feel happier if the code guards against this. - If g_selection exists, then ignore ENOTTY and ENOIOCTLCMD error codes from cropcap. Just assume square pixelaspect ratio in that case. This situation can happen if the bridge driver's cropcap op calls the corresponding subdev's op. So the cropcap ioctl is set, but it might return ENOIOCTLCMD anyway. In the past this would just return an error which is wrong. - Call cropcap first and let g_selection overwrite the bounds and defrect. This safeguards against subdev cropcap implementations that set those rectangles as well. What g_selection returns has priority over what such cropcap implementations return. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-ioctl.c | 70 ++++++++++++++++++++++-------------- 1 file changed, 43 insertions(+), 27 deletions(-) commit 92021e074afe25a607e24ec8f28d3daebca5d434 Author: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Date: Sat Apr 16 05:12:20 2016 -0300 [media] smiapp: provide g_skip_top_lines method in sensor ops Some sensors (like the one in Nokia N900) provide metadata in the first couple of lines. Make that information information available to the pipeline. Use u16 instead, this is a 16-bit value. Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/smiapp/smiapp-core.c | 12 ++++++++++++ drivers/media/i2c/smiapp/smiapp.h | 1 + 2 files changed, 13 insertions(+) commit 806f8ffa8a0fa9a6f0481c5648c27aa51d10fdc6 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Mar 7 15:39:32 2016 -0300 [media] media: i2c/adp1653: fix check of devm_gpiod_get() error code The devm_gpiod_get() function returns either a valid pointer to struct gpio_desc or ERR_PTR() error value, check for NULL is bogus. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/adp1653.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f3bf9841b837cba56d1e42d510c59623f14de3e4 Merge: 4087a5f 6c9da38 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri May 6 11:21:23 2016 -0700 Merge branch 'clk-hi3519' into clk-next * clk-hi3519: clk: hisilicon: add CRG driver for hi3519 soc clk: hisilicon: export some hisilicon APIs to modules reset: hisilicon: add reset controller driver for hisilicon SOCs commit 6c9da387c8d5c5254857d2782bd6c314226f4f27 Author: Jiancheng Xue <xuejiancheng@hisilicon.com> Date: Sat Apr 23 15:40:30 2016 +0800 clk: hisilicon: add CRG driver for hi3519 soc The CRG(Clock and Reset Generator) block provides clock and reset signals for other modules in hi3519 soc. Signed-off-by: Jiancheng Xue <xuejiancheng@hisilicon.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../devicetree/bindings/clock/hi3519-crg.txt | 46 ++++++++ drivers/clk/hisilicon/Kconfig | 8 ++ drivers/clk/hisilicon/Makefile | 1 + drivers/clk/hisilicon/clk-hi3519.c | 131 +++++++++++++++++++++ include/dt-bindings/clock/hi3519-clock.h | 40 +++++++ 5 files changed, 226 insertions(+) commit f6ff57c8abde68c0bb8e0d4539f4204fc5ba45ae Author: Jiancheng Xue <xuejiancheng@huawei.com> Date: Sat Apr 23 15:40:29 2016 +0800 clk: hisilicon: export some hisilicon APIs to modules Change some arguments to constant type. Export some hisilicon APIs to modules. Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/hisilicon/clk.c | 23 +++++++++++++++-------- drivers/clk/hisilicon/clk.h | 14 +++++++------- 2 files changed, 22 insertions(+), 15 deletions(-) commit 25824d52caa8e614b695a7197a8edde19f5b02ad Author: Jiancheng Xue <xuejiancheng@hisilicon.com> Date: Sat Apr 23 15:40:28 2016 +0800 reset: hisilicon: add reset controller driver for hisilicon SOCs In most of hisilicon SOCs, reset controller and clock provider are combined together as a block named CRG (Clock and Reset Generator). This patch mainly implements the reset function. Signed-off-by: Jiancheng Xue <xuejiancheng@hisilicon.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/hisilicon/Kconfig | 7 +++ drivers/clk/hisilicon/Makefile | 1 + drivers/clk/hisilicon/reset.c | 134 +++++++++++++++++++++++++++++++++++++++++ drivers/clk/hisilicon/reset.h | 36 +++++++++++ 4 files changed, 178 insertions(+) commit b4f78259d593858feb85e02c195cf374f932feef Author: Andrew F. Davis <afd@ti.com> Date: Wed May 4 17:01:39 2016 -0500 rpmsg: use module_rpmsg_driver in existing drivers and examples Existing drivers and examples are updated to use the module_rpmsg_driver helper macro. Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Documentation/rpmsg.txt | 13 +------------ samples/rpmsg/rpmsg_client_sample.c | 13 +------------ 2 files changed, 2 insertions(+), 24 deletions(-) commit f3d9f1ce079370d19b34fc9927b8b1355ac98503 Author: Andrew F. Davis <afd@ti.com> Date: Wed May 4 17:01:38 2016 -0500 rpmsg: add helper macro module_rpmsg_driver This patch introduces the module_rpmsg_driver macro which is a convenience macro for rpmsg driver modules similar to module_platform_driver. It is intended to be used by drivers which init/exit section does nothing but register/unregister the rpmsg driver. By using this macro it is possible to eliminate a few lines of boilerplate code per rpmsg driver. Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> include/linux/rpmsg.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 9122bf1839c039a0052c0a75a3c4daf9277b5dd5 Author: Andrew F. Davis <afd@ti.com> Date: Wed May 4 17:01:37 2016 -0500 rpmsg: drop owner assignment from rpmsg_drivers An rpmsg_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Documentation/rpmsg.txt | 1 - samples/rpmsg/rpmsg_client_sample.c | 1 - 2 files changed, 2 deletions(-) commit bc3c57c13256c748a4e71d2ea7481d0c953e88e1 Author: Andrew F. Davis <afd@ti.com> Date: Wed May 4 17:01:36 2016 -0500 rpmsg: add THIS_MODULE to rpmsg_driver in rpmsg core Add register_rpmsg_driver helper macro that adds THIS_MODULE to rpmsg_driver for the registering driver. We rename and modify the existing register_rpmsg_driver to enable this. Signed-off-by: Andrew F. Davis <afd@ti.com> Acked-by: Suman Anna <s-anna@ti.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> drivers/rpmsg/virtio_rpmsg_bus.c | 8 +++++--- include/linux/rpmsg.h | 6 +++++- 2 files changed, 10 insertions(+), 4 deletions(-) commit 4087a5f2e5e75a6d0231d1318bada1a12972a5fd Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu Apr 28 19:20:33 2016 +0530 clk: bcm/kona: Do not use sizeof on pointer type When sizeof is applied to a pointer typed expression, it gives the size of the pointer. So, here do not use sizeof on pointer type. Also, silent checkpatch.pl by using kmalloc_array over kmalloc. Note that this has no effect on runtime because 'parent_names' is a pointer to a pointer. Problem found using Coccinelle. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/bcm/clk-kona-setup.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 2a0974aa1a0b40a92387ea03dbfeacfbc9ba182c Author: Andy Gross <andy.gross@linaro.org> Date: Tue May 3 15:24:11 2016 -0500 clk: qcom: msm8916: Fix crypto clock flags This patch adds the CLK_SET_RATE_PARENT flag for the crypto core and ahb blocks. Without this flag, clk_set_rate can fail for certain frequency requests. Signed-off-by: Andy Gross <andy.gross@linaro.org> Fixes: 3966fab8b6ab ("clk: qcom: Add MSM8916 Global Clock Controller support") Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/qcom/gcc-msm8916.c | 2 ++ 1 file changed, 2 insertions(+) commit 3cdaeb7d8bd872926cbc0d194a0386e07ce3facb Merge: a444723 92a847e Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri May 6 11:02:35 2016 -0700 Merge tag 'imx-clk-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into clk-next Pull i.MX clk updates from Shawn Guo: - Update clk-pllv3 driver to get it return correct frequency for Ethernet PLL on i.MX7D. - Correct ahb clock mux settings for i.MX7D per latest hardware document. * tag 'imx-clk-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: clk: imx7d: fix ahb clock mux 1 clk: imx: return correct frequency for Ethernet PLL commit a444723569b48bc49e3175930eb9777582f48f44 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri May 6 10:55:11 2016 -0700 clk: nxp: lpc18xx: Initialize clk_init_data::flags to 0 Failure to initialize this flag to 0 by default can result in stack junk filling the clk_init_data structure and weird things happen. Joachim noticed that the critical clk feature started triggering for these clks causing boot failures, when it really shouldn't have happened: BUG: scheduling while atomic: swapper/0/0x00000002 CPU: 0 PID: 0 Comm: swapper Not tainted 4.6.0-rc6-next-20160505-00001-g5c8320450d1c #826 Hardware name: NXP LPC18xx/43xx (Device Tree) [<2800be81>] (unwind_backtrace) from [<2800b22f>] (show_stack+0xb/0xc) [<2800b22f>] (show_stack) from [<2801ea21>] (__schedule_bug+0x2d/0x44) [<2801ea21>] (__schedule_bug) from [<281dc937>] (__schedule+0x3b/0x268) [<281dc937>] (__schedule) from [<281dcbbb>] (schedule+0x57/0x64) [<281dcbbb>] (schedule) from [<281de8ef>] (schedule_timeout+0xfb/0x120) [<281de8ef>] (schedule_timeout) from [<28030fcd>] (msleep+0xf/0x12) [<28030fcd>] (msleep) from [<28165a6d>] (clk_creg_32k_prepare+0x1f/0x24) [<28165a6d>] (clk_creg_32k_prepare) from [<281620d5>] (clk_core_prepare+0x1d/0x36) [<281620d5>] (clk_core_prepare) from [<2816340b>] (clk_register+0x22f/0x318) [<2816340b>] (clk_register) from [<282b06c9>] (lpc18xx_creg_clk_init+0x55/0x84) [<282b06c9>] (lpc18xx_creg_clk_init) from [<282b0149>] (of_clk_init+0xc1/0x12c) [<282b0149>] (of_clk_init) from [<282a665d>] (time_init+0x15/0x20) [<282a665d>] (time_init) from [<282a457d>] (start_kernel+0x169/0x274) [<282a457d>] (start_kernel) from [<28008025>] (0x28008025) bad: scheduling from the idle thread! CPU: 0 PID: 0 Comm: swapper Tainted: G W 4.6.0-rc6-next-20160505-00001-g5c8320450d1c #826 Fix this by initializing the flags member to 0. Acked-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/nxp/clk-lpc18xx-creg.c | 1 + 1 file changed, 1 insertion(+) commit 923587aafc2c41ed516d39651d5750ea402cfc06 Author: Jose Abreu <Jose.Abreu@synopsys.com> Date: Mon May 2 10:39:05 2016 +0100 clk/axs10x: Add I2S PLL clock driver The ARC SDP I2S clock can be programmed using a specific PLL. This patch has the goal of adding a clock driver that programs this PLL. At this moment the rate values are hardcoded in a table but in the future it would be ideal to use a function which determines the PLL values given the desired rate. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../bindings/clock/axs10x-i2s-pll-clock.txt | 25 +++ drivers/clk/Makefile | 1 + drivers/clk/axs10x/Makefile | 1 + drivers/clk/axs10x/i2s_pll_clock.c | 228 +++++++++++++++++++++ 4 files changed, 255 insertions(+) commit 191ec113487e7e7adc4b890c290f63e9155264ad Author: Axel Lin <axel.lin@ingics.com> Date: Sun Apr 24 14:59:20 2016 +0800 spi: pic32-sqi: Remove pic32_sqi_setup and pic32_sqi_cleanup Current code does not use ctldata at all, so remove spi_set_ctldata call. spi_setup() will set spi->bits_per_word = 8 if it was not set, so remove !spi->max_speed_hz checking. The spi core allows absent of spi->max_speed_hz setting, if it was not set spi_setup() assigns spi->master->max_speed_hz to it. spi core allows spi->max_speed_hz > spi->master->max_speed_hz, in this case spi core will limit the transfer speed to ensure xfer->speed_hz won't greater than spi->master->max_speed_hz so remove checking if spi->max_speed_hz is higher than spi->master->max_speed_hz. As a result, both pic32_sqi_setup() and pic32_sqi_cleanup() can be removed. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pic32-sqi.c | 41 ----------------------------------------- 1 file changed, 41 deletions(-) commit 6c7d614fa22d32d038b5a6e88d71acb2711e7035 Author: Nishanth Menon <nm@ti.com> Date: Thu May 5 19:29:52 2016 -0500 regulator: tps65917/palmas: Simplify multiple dereference of match->of_node Just dereference match->of_node once instead of using match->of_node. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/palmas-regulator.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit 7f091e53c9efc52b2b3a03a8a1d479a47956fecd Author: Nishanth Menon <nm@ti.com> Date: Thu May 5 19:29:51 2016 -0500 regulator: tps65917/palmas: Handle possible memory allocation failure Stop the palmas regulator driver from imagining that the allocations will always succeed. Since regulator dt nodes are optional in nature and can be described in downstream drivers via platform data, continue to maintain code flow as prior when of node is not found. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/palmas-regulator.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) commit 1b42443db670dde5e3cb4261f77b29010b163fc6 Author: Nishanth Menon <nm@ti.com> Date: Thu May 5 19:29:50 2016 -0500 regulator: tps65917/palmas: Simplify multiple dereference of pdata->reg_init[idx] Converting dt to platform data logic involves picking up information that is unique per regulator, however we can improve readability of the code by allocating and referencing pdata->reg_init[idx] once in the loop. While at it, use sizeof(*pointer) when allocating pointer. This allows for structure name changes with minimal code change. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/palmas-regulator.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit 036d193d3337365e0d69cff9bb2593bfc1210e7b Author: Nishanth Menon <nm@ti.com> Date: Thu May 5 19:29:49 2016 -0500 regulator: tps65917/palmas: Simplify multiple dereference of ddata->palmas_matches[idx] Converting dt to platform data logic involves picking up information that is unique per regulator, however we can improve readability of the code by dereferencing ddata->palmas_matches[idx] once in the loop. While at it fix reuse of generic palmas_matches common variable while reporting error for a specific regulator (which may be from 65917/palmas list). Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/palmas-regulator.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) commit b58cea7355875d6ae7aacb66c105f5c99f489909 Author: Mark Brown <broonie@kernel.org> Date: Fri May 6 18:13:17 2016 +0100 ASoC: da7129: Add missing include of acpi.h Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7219.c | 1 + 1 file changed, 1 insertion(+) commit 953dee9bbd245f5515173126b9cc8b1a2c340797 Author: Jason Baron <jbaron@akamai.com> Date: Fri May 6 11:18:47 2016 -0400 EDAC, ie31200_edac: Add Skylake support Skylake adjusts some register locations, but otherwise follows the existing model quite closely. I was able to verify that the 'ce_count' increments when 'bad dimms' are used. The accounting of 'ce_count' and 'ue_count' is the primary functionality of interest for us. Tested on Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz. Signed-off-by: Jason Baron <jbaron@akamai.com> Acked-by: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462547927-22679-1-git-send-email-jbaron@akamai.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/ie31200_edac.c | 121 ++++++++++++++++++++++++++++++++------------ 1 file changed, 90 insertions(+), 31 deletions(-) commit 3603ea0aeed7dc2b54144b5913eb303173361123 Author: Brian Norris <computersforpeace@gmail.com> Date: Fri May 6 09:31:18 2016 -0700 mtd: nand_bch: fix spelling of "probably" Signed-off-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_bch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e5b7d71aa5b32180adec49a17c752e577c68f740 Author: Andrea Adami <andrea.adami@gmail.com> Date: Fri May 6 17:27:34 2016 +0200 ASoC: pxa: Fix module autoload for platform drivers These platform drivers are lacking MODULE_ALIAS so module autoloading doesn't work. Tested on corgi and poodle with kernel 4.4. Signed-off-by: Andrea Adami <andrea.adami@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/pxa/brownstone.c | 1 + sound/soc/pxa/mioa701_wm9713.c | 1 + sound/soc/pxa/mmp-pcm.c | 1 + sound/soc/pxa/mmp-sspa.c | 1 + sound/soc/pxa/palm27x.c | 1 + sound/soc/pxa/pxa-ssp.c | 1 + sound/soc/pxa/pxa2xx-ac97.c | 1 + sound/soc/pxa/pxa2xx-pcm.c | 1 + 8 files changed, 8 insertions(+) commit 68cd4ce2caf22a81833eb1abfa075eb1cc39bfe2 Author: Bob Peterson <rpeterso@redhat.com> Date: Mon May 2 11:53:35 2016 -0500 GFS2: Refactor gfs2_remove_from_journal This patch makes two simple changes to function gfs2_remove_from_journal. First, it removes the parameter that specifies the transaction. Since it's always passed in as current->journal_info, we might as well set that in the function rather than passing it in. Second, it changes the meta parameter to use an enum to make the code more clear. Signed-off-by: Bob Peterson <rpeterso@redhat.com> Acked-by: Steven Whitehouse <swhiteho@redhat.com> fs/gfs2/aops.c | 2 +- fs/gfs2/meta_io.c | 7 ++++--- fs/gfs2/meta_io.h | 8 ++++++-- 3 files changed, 11 insertions(+), 6 deletions(-) commit d5d71e86d226abe7e08df5763127ed2bd07649a1 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri May 6 12:45:25 2016 -0300 perf trace: Move futex_op beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-vb8dpy7bptkf219q5c25ulfp@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 47 ++------------------------------------ tools/perf/trace/beauty/futex_op.c | 44 +++++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 45 deletions(-) commit 8f48df69b4add63527cae646f2e40cf83c6ec0a0 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri May 6 10:02:32 2016 -0300 perf trace: Move open_flags beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-jt293541hv9od7gqw6lilioh@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 57 +----------------------------------- tools/perf/trace/beauty/open_flags.c | 56 +++++++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+), 56 deletions(-) commit 12199d8e20bb4a2ad164d2600bf199557d55c35c Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri May 6 09:58:02 2016 -0300 perf trace: Move signum beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-qecqxwwtreio6eaatfv58yq5@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 54 +--------------------------------------- tools/perf/trace/beauty/signum.c | 53 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+), 53 deletions(-) commit 0b1abbf4a7d273a13065534d718661fc904703b9 Author: Andi Kleen <ak@linux.intel.com> Date: Wed Apr 27 13:00:51 2016 -0700 perf stat: Add extra output of counter values with -vv Add debug output of raw counter values per CPU when perf stat -v is specified, together with their cpu numbers. This is very useful to debug problems with per core counters, where we can normally only see aggregated values. v2: Make it depend on -vv, not -v Signed-off-by: Andi Kleen <ak@linux.intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461787251-6702-12-git-send-email-andi@firstfloor.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-stat.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 3521f3bc9dae4a79cfb9cc9ffcf6d961bbb7cbac Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:11 2016 -0700 perf script: Update export-to-postgresql to support callchain export Update the export-to-postgresql.py to support the newly introduced callchain export. callchains are added into the existing call_paths table and can now be associated with samples when the "callpaths" commandline option is used with the script. Ex.: $ perf script -s export-to-postgresql.py example_db all callchains Includes the following changes to enable callchain export via the python export APIs: - Add the "callchains" commandline option, which is used to enable callchain export by setting the perf_db_export_callchains global - Add perf_db_export_callchains checks for call_path table creation and population. - Add call_path_id to samples_table to conform with the new API example usage and output using a small test app: test_app.c: volatile int x = 0; void inc_x_loop() { int i; for(i=0; i<100000000; i++) x++; } void a() { inc_x_loop(); } void b() { inc_x_loop(); } int main() { a(); b(); return 0; } example usage: $ gcc -g -O0 test_app.c $ perf record --call-graph=dwarf ./a.out [ perf record: Woken up 77 times to write data ] [ perf record: Captured and wrote 19.373 MB perf.data (2404 samples) ] $ perf script -s scripts/python/export-to-postgresql.py example_db all callchains $ psql example_db example_db=# SELECT (SELECT name FROM symbols WHERE id = cps.symbol_id) as symbol, (SELECT name FROM symbols WHERE id = (SELECT symbol_id from call_paths where id = cps.parent_id)) as parent_symbol, sum(period) as event_count FROM samples join call_paths as cps on call_path_id = cps.id GROUP BY cps.id,evsel_id ORDER BY event_count DESC LIMIT 5; symbol | parent_symbol | event_count ------------------+--------------------------+------------- inc_x_loop | a | 734250982 inc_x_loop | b | 731028057 unknown | unknown | 1335858 task_tick_fair | scheduler_tick | 1238842 update_wall_time | tick_do_update_jiffies64 | 650373 (5 rows) The above data shows total "self time" in cycles for each call path that was sampled. It is intended to demonstrate how it accounts separately for the two ways to reach the "inc_x_loop" function(via "a" and "b"). Recursive common table expressions can be used as well to get cumulative time spent in a function as well, but that is beyond the scope of this basic example. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-7-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/scripts/python/export-to-postgresql.py | 47 +++++++++++++++-------- 1 file changed, 30 insertions(+), 17 deletions(-) commit 2c15f5eb04e9e7e19a2c8be6b50c63a4c6062a44 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:10 2016 -0700 perf script: Expose usage of the callchain db export via the python api This change allows python scripts to be able to utilize the recent changes to the db export api allowing the export of call_paths derived from sampled callchains. These call paths are also now associated with the samples from which they were derived. - This feature is enabled by setting "perf_db_export_callchains" to true - When enabled, samples that have callchain information will have the callchains exported via call_path_table - The call_path_id field is added to sample_table to enable association of samples with the corresponding callchain stored in the call paths table. A call_path_id of 0 will be exported if there is no corresponding callchain. - When "perf_db_export_callchains" and "perf_db_export_calls" are both set to True, the call path root data structure will be shared. This prevents duplicating of data and call path ids that would result from building two separate call path trees in memory. - The call_return_processor structure definition was relocated to the header file to make its contents visible to db-export.c. This enables the sharing of call path trees between the two features, as mentioned above. This change is visible to python scripts using the python db export api. The change is backwards compatible with scripts written against the previous API, assuming that the scripts model the sample_table function after the one in export-to-postgresql.py script by allowing for additional arguments to be added in the future. ie. using *x as the final argument of the sample_table function. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-6-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> .../util/scripting-engines/trace-event-python.c | 35 ++++++++++++++++++++-- tools/perf/util/thread-stack.c | 13 -------- tools/perf/util/thread-stack.h | 14 ++++++++- 3 files changed, 46 insertions(+), 16 deletions(-) commit 568850eaad8cdd3783c3347623dfcad4f043cf1c Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:09 2016 -0700 perf script: Add call path id to exported sample in db export The exported sample now contains a reference to the call_path_id that represents its callchain. While callchains themselves are nice to have, being able to associate them with samples makes them much more useful, and can allow for such things as determining how much cumulative time is spent in a particular function. This information is normally possible to get from the call return processor. However, when doing normal sampling, call/return information is not available, thus necessitating the need for associating samples directly with call paths. This commit include changes to db-export layer to make this information available for subsequent patches in this change set, but by itself, does not make any changes visible to the user. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-5-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/db-export.c | 4 +++- tools/perf/util/db-export.h | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) commit 0a3eba3ad613fa9d5af754f7ae8c4b46047cb2a7 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:08 2016 -0700 perf script: Enable db export to output sampled callchains This change enables the db export api to export callchains. This is accomplished by adding callchains obtained from samples to the call_path_root structure and exporting them via the current call path export API. While the current API does support exporting call paths, this is not supported when sampling. This commit addresses that missing feature by allowing the export of call paths when callchains are present in samples. Summary: - This feature is activated by initializing the call_path_root member inside the db_export structure to a non-null value. - Callchains are resolved with thread__resolve_callchain() and then stored and exported by adding a call path under call path root. - Symbol and DSO for each callchain node are exported via db_ids_from_al() This commit puts in place infrastructure to be used by subsequent commits, and by itself, does not introduce any user-visible changes. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-4-git-send-email-cphlipot0@gmail.com [ Made adjustments suggested by Adrian Hunter, see thread via this cset's Link: tag ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/db-export.c | 82 +++++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/db-export.h | 2 ++ 2 files changed, 84 insertions(+) commit 451db12617bc6ff1bb8ed456ed4f257594134255 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:07 2016 -0700 perf tools: Refactor code to move call path handling out of thread-stack Move the call path handling code out of thread-stack.c and thread-stack.h to allow other components that are not part of thread-stack to create call paths. Summary: - Create call-path.c and call-path.h and add them to the build. - Move all call path related code out of thread-stack.c and thread-stack.h and into call-path.c and call-path.h. - A small subset of structures and functions are now visible through call-path.h, which is required for thread-stack.c to continue to compile. This change is a prerequisite for subsequent patches in this change set and by itself contains no user-visible changes. Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-3-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/Build | 1 + tools/perf/util/call-path.c | 122 ++++++++++++++++++++ tools/perf/util/call-path.h | 77 +++++++++++++ tools/perf/util/db-export.c | 1 + .../util/scripting-engines/trace-event-python.c | 1 + tools/perf/util/thread-stack.c | 126 +-------------------- tools/perf/util/thread-stack.h | 25 +--- 7 files changed, 204 insertions(+), 149 deletions(-) commit 9a5f91a1d63f3e1fbd2148ffdce5b9ba98cbd88c Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Apr 27 16:26:26 2016 +0530 ath10k: release pre_cal_file while unloading driver Failing to release pre_cal_file caldata on deinit causes memory leak. Fixes: b131129d9657 ("ath10k: fix calibration init sequence of qca99x0") Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 4 ++++ 1 file changed, 4 insertions(+) commit fa7937e3d5c293a3b1aceafbaa60ed0a60f4b319 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Apr 27 16:23:22 2016 +0530 ath10k: update bss channel survey information During hw scan, firmware sends two channel information events (pre- complete, complete) to host for each channel change. The snap shot of cycle counters (rx_clear and total) between these two events are given for survey dump. In order to get latest survey statistics of all channels, a scan request has to be issued. In general, an AP DUT is brought up, it won't leave BSS channel except few cases like overlapping bss or radar detection. So survey statistics of bss channel is always referring to older data that are collected before starting AP (either ACS/OBSS scan). To collect latest survey information from target, firmware provides WMI interface to read cycle counters from hardware. For each survey dump request, BSS channel cycle counters are read and cleared in hardware. This makes sure that behavior is in align with ath9k survey report. So survey dump always gives snap shot of cycle counters b/w two survey requests. Signed-off-by: Yanbo Li <yanbol@qca.qualcomm.com> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 5 +++++ drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/mac.c | 35 ++++++++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi.c | 29 ++++++++++++++++++++++++++++ 4 files changed, 70 insertions(+) commit 89d2d183bb0139ee3944c94001821d30be644130 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Apr 27 16:23:21 2016 +0530 ath10k: handle pdev_chan_info wmi event Add handler to process bss channel information wmi event that will be received upon sending pdev_chan_info_request wmi command. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 32 ++++++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi.h | 11 +++++++++++ 2 files changed, 43 insertions(+) commit 8a0b459e36cf33dd96893de02a2d2b4990cbb143 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Apr 27 16:23:20 2016 +0530 ath10k: implement wmi_pdev_bss_chan_info_request Add WMI ops to send pdev_bss_chan_info_request command to target. This command will be used to retrieve updated cycle counters and noise floor value of current operating channel (bss channel). Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi-ops.h | 21 +++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi.c | 25 ++++++++++++++++++++++++- drivers/net/wireless/ath/ath10k/wmi.h | 10 ++++++++++ 3 files changed, 55 insertions(+), 1 deletion(-) commit dd2c5fcb9f515964a6eed528a621f2b93e4a14ce Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Apr 27 16:23:19 2016 +0530 ath10k: add pdev bss channel info wmi definitions Add WMI definitions for pdev bss channel information request and event. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.h | 4 ++++ 1 file changed, 4 insertions(+) commit 4ad24a9d83bd4bf0a85e95bf144e18d3fda4fbf1 Author: Anilkumar Kolli <akolli@qti.qualcomm.com> Date: Tue Apr 26 21:35:48 2016 +0530 ath10k: fix kernel panic, move arvifs list head init before htt init It is observed that while loading and unloading ath10k modules in an infinite loop, before ath10k_core_start() completion HTT rx frames are received, while processing these frames, dereferencing the arvifs list code is getting hit before initilizing the arvifs list, causing a kernel panic. This patch initilizes the arvifs list before initilizing htt. Fixes the below issue: [<bf88b058>] (ath10k_htt_rx_pktlog_completion_handler+0x278/0xd08 [ath10k_core]) [<bf88b058>] (ath10k_htt_rx_pktlog_completion_handler [ath10k_core]) [<bf88c0dc>] (ath10k_htt_txrx_compl_task+0x5f4/0xeb0 [ath10k_core]) [<bf88c0dc>] (ath10k_htt_txrx_compl_task [ath10k_core]) [<c0234100>] (tasklet_action+0x8c/0xec) [<c0234100>] (tasklet_action) [<c02337c0>] (__do_softirq+0xf8/0x228) [<c02337c0>] (__do_softirq) [<c0233920>] (run_ksoftirqd+0x30/0x90) Code: e5954ad8 e2899008 e1540009 0a00000d (e5943008) ---[ end trace 71de5c2e011dbf56 ]--- Kernel panic - not syncing: Fatal exception in interrupt Fixes: 500ff9f9389d ("ath10k: implement chanctx API") Cc: <stable@vger.kernel.org> Signed-off-by: Anilkumar Kolli <akolli@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit de46d165658fbfcec8d083513fb96dec6d28d454 Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Tue Apr 26 20:54:36 2016 +0530 ath10k: move spectral related structures under ath10k debugfs Spectral related structures are accessed / modified only if ath10k debugfs is enabled, so it makes more sense to move them under ATH10K_DEBUGFS Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 94ee3f19b15e6193cddab8f7a82af0023efff101 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Apr 21 16:17:49 2016 +0300 ath10k: remove VHT capabilities from 2.4GHz According to the spec, VHT doesn't exist in 2.4GHz. There are vendor extensions to allow a subset of VHT to work (notably 256-QAM), but since mac80211 doesn't support those advertising VHT capability on 2.4GHz leads to the behaviour of reporting VHT capabilities but not being able to use any of them due to mac80211's code requiring 80 MHz support. Remove the VHT capabilities from 2.4GHz for now. If mac80211 gets extended to use the (likely Broadcom) vendor IEs for it and handles the lack of 80 MHz support, it can be added back. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 3 --- 1 file changed, 3 deletions(-) commit ac4b1280319c3032787ac95bfeff14a425c417bf Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Mon Jan 4 18:36:45 2016 +0100 clk: mediatek: remove hdmitx_dig_cts from TOP clocks The hdmitx_dig_cts clock signal is not a child of tvdpll_445p5m, but is routed out of the HDMI PHY module. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mediatek/clk-mt8173.c | 1 - 1 file changed, 1 deletion(-) commit 4585945bf1d348d006f7270beea3dae09fee3413 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Mon Nov 30 22:07:53 2015 +0100 clk: mediatek: Add hdmi_ref HDMI PHY PLL reference clock output The configurable hdmi_ref output of the PLL block is derived from the tvdpll_594m clock signal via a configurable PLL post-divider. It is used as the PLL reference input to the HDMI PHY module. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: James Liao <jamesjj.liao@mediatek.com> Acked-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mediatek/clk-mt8173.c | 5 +++++ include/dt-bindings/clock/mt8173-clk.h | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) commit 06445994fece2ae458419fbadc1b2107336615d6 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Mon Jan 4 18:36:42 2016 +0100 clk: mediatek: make dpi0_sel propagate rate changes This mux is supposed to select a fitting divider after the PLL is already set to the correct rate. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: James Liao <jamesjj.liao@mediatek.com> Acked-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mediatek/clk-mt8173.c | 6 +++++- drivers/clk/mediatek/clk-mtk.h | 15 +++++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) commit 9e629c17aa8d7a75b8c1d99ed42892cd8ba7cdc4 Author: Jie Qiu <jie.qiu@mediatek.com> Date: Mon Jan 4 18:36:36 2016 +0100 drm/mediatek: Add DPI sub driver Add DPI connector/encoder to support HDMI output via the attached HDMI bridge. Signed-off-by: Jie Qiu <jie.qiu@mediatek.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/mediatek/Makefile | 3 +- drivers/gpu/drm/mediatek/mtk_dpi.c | 769 ++++++++++++++++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_dpi_regs.h | 228 ++++++++++ drivers/gpu/drm/mediatek/mtk_drm_drv.c | 1 + drivers/gpu/drm/mediatek/mtk_drm_drv.h | 1 + 5 files changed, 1001 insertions(+), 1 deletion(-) commit 2e54c14e310f655bb0915413e8e4a3da67c78a66 Author: CK Hu <ck.hu@mediatek.com> Date: Mon Jan 4 18:36:35 2016 +0100 drm/mediatek: Add DSI sub driver This patch add a drm encoder/connector driver for the MIPI DSI function block of the Mediatek display subsystem and a phy driver for the MIPI TX D-PHY control module. Signed-off-by: Jitao Shi <jitao.shi@mediatek.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/mediatek/Kconfig | 2 + drivers/gpu/drm/mediatek/Makefile | 4 +- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 2 + drivers/gpu/drm/mediatek/mtk_drm_drv.h | 2 + drivers/gpu/drm/mediatek/mtk_dsi.c | 913 +++++++++++++++++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_mipi_tx.c | 463 +++++++++++++++++ 6 files changed, 1385 insertions(+), 1 deletion(-) commit 119f5173628aa7a0c3cf9db83460d40709e8241d Author: CK Hu <ck.hu@mediatek.com> Date: Mon Jan 4 18:36:34 2016 +0100 drm/mediatek: Add DRM Driver for Mediatek SoC MT8173. This patch adds an initial DRM driver for the Mediatek MT8173 DISP subsystem. It currently supports two fixed output streams from the OVL0/OVL1 sources to the DSI0/DPI0 sinks, respectively. Signed-off-by: CK Hu <ck.hu@mediatek.com> Signed-off-by: YT Shen <yt.shen@mediatek.com> Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Signed-off-by: Bibby Hsieh <bibby.hsieh@mediatek.com> Signed-off-by: Mao Huang <littlecvr@chromium.org> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/Makefile | 1 + drivers/gpu/drm/mediatek/Kconfig | 14 + drivers/gpu/drm/mediatek/Makefile | 11 + drivers/gpu/drm/mediatek/mtk_disp_ovl.c | 302 +++++++++++++++ drivers/gpu/drm/mediatek/mtk_disp_rdma.c | 240 ++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_crtc.c | 582 ++++++++++++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_crtc.h | 32 ++ drivers/gpu/drm/mediatek/mtk_drm_ddp.c | 353 +++++++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_ddp.h | 41 ++ drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 225 +++++++++++ drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.h | 150 +++++++ drivers/gpu/drm/mediatek/mtk_drm_drv.c | 564 +++++++++++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_drv.h | 57 +++ drivers/gpu/drm/mediatek/mtk_drm_fb.c | 165 ++++++++ drivers/gpu/drm/mediatek/mtk_drm_fb.h | 23 ++ drivers/gpu/drm/mediatek/mtk_drm_gem.c | 269 +++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_gem.h | 59 +++ drivers/gpu/drm/mediatek/mtk_drm_plane.c | 240 ++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_plane.h | 59 +++ 20 files changed, 3389 insertions(+) commit 8863dc7f5642737e49ff681cbb842d2c614bdcf4 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri May 6 15:39:03 2016 +0200 drm/i915: Correctly refcount connectors in hw state readou This was forgotten when adding the the refcounting to drm_connector_state. v2: Don't forget to unreference existing connectors. This isn't relevant on driver load, but this code also runs on resume, and there we already have an atomic state. Spotted by Chris Wilson. Cc: Gabriel Feceoru <gabriel.feceoru@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Marius Vlad <marius.c.vlad@intel.com> Cc: Dave Airlie <airlied@redhat.com> Fixes: d2307dea14a4 ("drm/atomic: use connector references (v3)") Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462541943-19620-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/i915/intel_display.c | 5 +++++ 1 file changed, 5 insertions(+) commit 83127f67e450a9a0882da495d59c88a71da25389 Author: Thierry Reding <thierry.reding@gmail.com> Date: Fri May 6 16:01:37 2016 +0200 drm/panel: Flesh out kerneldoc Write more complete kerneldoc comments for the DRM panel API and integrate the helpers in the DRM DocBook reference. Signed-off-by: Thierry Reding <treding@nvidia.com>drm/panel: Add helper for simple panel connector Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/20160506140137.GA4641@ulmo.ba.sec Documentation/DocBook/gpu.tmpl | 12 ++++++--- drivers/gpu/drm/drm_panel.c | 61 ++++++++++++++++++++++++++++++++++++++++++ include/drm/drm_panel.h | 59 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 129 insertions(+), 3 deletions(-) commit 330d12764e15f6e3e94ff34cda29db96d2589c24 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri May 6 09:27:16 2016 +0200 ARM: dts: exynos: Add interrupt line to MAX8997 PMIC on exynos4210-trats MAX8997 PMIC requires interrupt and fails probing without it. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Fixes: d105f0b1215d ("ARM: dts: Add basic dts file for Samsung Trats board") Cc: <stable@vger.kernel.org> [k.kozlowski: Write commit message, add CC-stable] Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4210-trats.dts | 2 ++ 1 file changed, 2 insertions(+) commit 44ad5e1fd15261f6c475413e3359047648507158 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri May 6 09:27:15 2016 +0200 ARM: dts: exynos: Fix regulator name to avoid forbidden character on exynos4210-trats The usage of slash character causes failure when creating regulator debugfs entry. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> [k.kozlowski: Write commit message] Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4210-trats.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7c44e9117fa47982d13483a2dd40f8e4645eeefd Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Thu Apr 28 15:21:50 2016 -0400 ARM: dts: exynos: Add MFC memory banks for Peach boards The MFC nodes with the memory regions reserved for memory allocations are missing in the Exynos5420 Peach Pit and Exynos5800 Peach Pi DTS. This causes the s5p-mfc driver probe to fail with the following error: [ 4.140647] s5p_mfc_alloc_memdevs:1072: Failed to declare coherent memory for MFC device [ 4.216163] s5p-mfc: probe of 11000000.codec failed with error -12 Add the missing nodes so the driver probes and the {en,de}coder video nodes are registered correctly: [ 4.096277] s5p-mfc 11000000.codec: decoder registered as /dev/video4 [ 4.102282] s5p-mfc 11000000.codec: encoder registered as /dev/video5 Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5420-peach-pit.dts | 5 +++++ arch/arm/boot/dts/exynos5800-peach-pi.dts | 5 +++++ 2 files changed, 10 insertions(+) commit c047baadb0592a283789f996cc3a2a7b33f0f04e Author: Marek Vasut <marex@denx.de> Date: Thu May 5 22:31:35 2016 +0200 ARM: at91: sama5: Update defconfig Enable CGROUPS support, so we can boot userspace that uses systemd on top of kernel configured using this defconfig. The systemd userspace depends on cgroups and without them, it dies in mysterious ways. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Ludovic Desroches <ludovic.desroches@atmel.com> Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/sama5_defconfig | 1 + 1 file changed, 1 insertion(+) commit 00bf4f78b56f7d86dff5ee6242f46ef6de84f8b0 Author: Mike Williams <mike@mikebwilliams.com> Date: Tue May 3 12:44:24 2016 -0400 ARM: dts: at91: sama5d4: add trng node Add node to support SAMA5D4 hardware random number generator. Signed-off-by: Mike Williams <mike@mikebwilliams.com> [nicolas.ferre@atmel.com: reduce the register map size] Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d4.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 206d6c5dfc5764fd6849b0ca276424ad2f624740 Author: Mike Williams <mike@mikebwilliams.com> Date: Tue May 3 12:44:23 2016 -0400 ARM: dts: at91: sama5d3: add trng node Add node to support SAMA5D3 hardware random number generator. Signed-off-by: Mike Williams <mike@mikebwilliams.com> [nicolas.ferre@atmel.com: reduce the register map size] Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d3.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 02eb8d6827662a5091ae7e4df2a0a6f2219b7725 Author: Mike Williams <mike@mikebwilliams.com> Date: Fri May 6 15:31:25 2016 +0200 ARM: dts: at91: sama5d2: add trng node Add node to support SAMA5D2 hardware random number generator. Signed-off-by: Mike Williams <mike@mikebwilliams.com> [nicolas.ferre@atmel.com: reduce the register map size] Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d2.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 0e230593b889c59b8bb4577ef3ae49ced395305b Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Fri May 6 15:34:40 2016 +0200 ARM: dts: at91: at91sam9g45 family: reduce the trng register map size No need to map 0x4000 bytes for the TRNG device: reduce it to 0x100. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/at91sam9g45.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2f3165ecf103599f82bf0ea254039db335fb5005 Author: Zygo Blaxell <ce3g8jdj@umail.furryterror.org> Date: Thu May 5 00:23:49 2016 -0400 btrfs: don't force mounts to wait for cleaner_kthread to delete one or more subvolumes During a mount, we start the cleaner kthread first because the transaction kthread wants to wake up the cleaner kthread. We start the transaction kthread next because everything in btrfs wants transactions. We do reloc recovery in the thread that was doing the original mount call once the transaction kthread is running. This means that the cleaner kthread could already be running when reloc recovery happens (e.g. if a snapshot delete was started before a crash). Relocation does not play well with the cleaner kthread, so a mutex was added in commit 5f3164813b90f7dbcb5c3ab9006906222ce471b7 "Btrfs: fix race between balance recovery and root deletion" to prevent both from being active at the same time. If the cleaner kthread is already holding the mutex by the time we get to btrfs_recover_relocation, the mount will be blocked until at least one deleted subvolume is cleaned (possibly more if the mount process doesn't get the lock right away). During this time (which could be an arbitrarily long time on a large/slow filesystem), the mount process is stuck and the filesystem is unnecessarily inaccessible. Fix this by locking cleaner_mutex before we start cleaner_kthread, and unlocking the mutex after mount no longer requires it. This ensures that the mounting process will not be blocked by the cleaner kthread. The cleaner kthread is already prepared for mutex contention and will just go to sleep until the mutex is available. Signed-off-by: Zygo Blaxell <ce3g8jdj@umail.furryterror.org> Reviewed-by: Filipe Manana <fdmanana@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/disk-io.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) commit 58d7bbf81f54667e36940d5f4b5609606efa597b Author: David Sterba <dsterba@suse.cz> Date: Wed May 4 14:10:47 2016 +0200 btrfs: ioctl: reorder exclusive op check in RM_DEV Move the op exclusivity check before the other code (same as in ADD_DEV). Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) commit 7ab19625a911f7568ec85302e3aa7a64186006c8 Author: David Sterba <dsterba@suse.cz> Date: Wed May 4 11:32:00 2016 +0200 btrfs: add write protection to SET_FEATURES ioctl Perform the want_write check if we get far enough to do any writes. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 48b3b9d401ec86899a52003b37331190a35a81a6 Author: Anand Jain <anand.jain@oracle.com> Date: Tue Apr 12 21:36:16 2016 +0800 btrfs: fix lock dep warning move scratch super outside of chunk_mutex Move scratch super outside of the chunk lock to avoid below lockdep warning. The better place to scratch super is in the function btrfs_rm_dev_replace_free_srcdev() just before free_device, which is outside of the chunk lock as well. To reproduce: (fresh boot) mkfs.btrfs -f -draid5 -mraid5 /dev/sdc /dev/sdd /dev/sde mount /dev/sdc /btrfs dd if=/dev/zero of=/btrfs/tf1 bs=4096 count=100 (get devmgt from https://github.com/asj/devmgt.git) devmgt detach /dev/sde dd if=/dev/zero of=/btrfs/tf1 bs=4096 count=100 sync btrfs replace start -Brf 3 /dev/sdf /btrfs <-- devmgt attach host7 ====================================================== [ INFO: possible circular locking dependency detected ] 4.6.0-rc2asj+ #1 Not tainted --------------------------------------------------- btrfs/2174 is trying to acquire lock: (sb_writers){.+.+.+}, at: [<ffffffff812449b4>] __sb_start_write+0xb4/0xf0 but task is already holding lock: (&fs_info->chunk_mutex){+.+.+.}, at: [<ffffffffa05c5f55>] btrfs_dev_replace_finishing+0x145/0x980 [btrfs] which lock already depends on the new lock. Chain exists of: sb_writers --> &fs_devs->device_list_mutex --> &fs_info->chunk_mutex Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&fs_info->chunk_mutex); lock(&fs_devs->device_list_mutex); lock(&fs_info->chunk_mutex); lock(sb_writers); *** DEADLOCK *** -> #0 (sb_writers){.+.+.+}: [<ffffffff810e6415>] __lock_acquire+0x1bc5/0x1ee0 [<ffffffff810e707e>] lock_acquire+0xbe/0x210 [<ffffffff810df49a>] percpu_down_read+0x4a/0xa0 [<ffffffff812449b4>] __sb_start_write+0xb4/0xf0 [<ffffffff81265534>] mnt_want_write+0x24/0x50 [<ffffffff812508a2>] path_openat+0x952/0x1190 [<ffffffff81252451>] do_filp_open+0x91/0x100 [<ffffffff8123f5cc>] file_open_name+0xfc/0x140 [<ffffffff8123f643>] filp_open+0x33/0x60 [<ffffffffa0572bb6>] update_dev_time+0x16/0x40 [btrfs] [<ffffffffa057f60d>] btrfs_scratch_superblocks+0x5d/0xb0 [btrfs] [<ffffffffa057f70e>] btrfs_rm_dev_replace_remove_srcdev+0xae/0xd0 [btrfs] [<ffffffffa05c62c5>] btrfs_dev_replace_finishing+0x4b5/0x980 [btrfs] [<ffffffffa05c6ae8>] btrfs_dev_replace_start+0x358/0x530 [btrfs] Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 2473114981a36b4f0f57cf6e9548037d547a71b7 Author: Ashish Samant <ashish.samant@oracle.com> Date: Fri Apr 29 18:33:59 2016 -0700 btrfs: Fix BUG_ON condition in scrub_setup_recheck_block() pagev array in scrub_block{} is of size SCRUB_MAX_PAGES_PER_BLOCK. page_index should be checked with the same to trigger BUG_ON(). Signed-off-by: Ashish Samant <ashish.samant@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/scrub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e042d1ec4417981dfe9331e47b76f17929bc2ffe Author: Josef Bacik <jbacik@fb.com> Date: Tue Apr 12 12:54:40 2016 -0400 Btrfs: remove BUG_ON()'s in btrfs_map_block btrfs_map_block can go horribly wrong in the face of fs corruption, lets agree to not be assholes and panic at any possible chance things are all fucked up. Signed-off-by: Josef Bacik <jbacik@fb.com> [ removed type casts ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit 3d8da67817606380fdadfa483d4dba5c3a5446c6 Author: Liu Bo <bo.li.liu@oracle.com> Date: Tue Apr 26 17:53:31 2016 -0700 Btrfs: fix divide error upon chunk's stripe_len The struct 'map_lookup' uses type int for @stripe_len, while btrfs_chunk_stripe_len() can return a u64 value, and it may end up with @stripe_len being undefined value and it can lead to 'divide error' in __btrfs_map_block(). This changes 'map_lookup' to use type u64 for stripe_len, also right now we only use BTRFS_STRIPE_LEN for stripe_len, so this adds a valid checker for BTRFS_STRIPE_LEN. Reported-by: Vegard Nossum <vegard.nossum@oracle.com> Reported-by: Quentin Casasnovas <quentin.casasnovas@oracle.com> Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> [ folded division fix to scrub_raid56_parity ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/scrub.c | 2 +- fs/btrfs/volumes.c | 2 +- fs/btrfs/volumes.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit ee17fc8005287d2d6ca7cab6e814e5043d773735 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 16:22:06 2016 +0200 btrfs: sysfs: protect reading label by lock If the label setting ioctl races with sysfs label handler, we could get mixed result in the output, part old part new. We should either get the old or new label. The chances to hit this race are low. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/sysfs.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 66ac9fe7bacf9fa76c472efc7a7aaa590c7bce6a Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 16:03:57 2016 +0200 btrfs: add check to sysfs handler of label Add a sanity check for the fs_info as we will dereference it, similar to what the 'store features' handler does. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/sysfs.c | 3 +++ 1 file changed, 3 insertions(+) commit ee6111386a1b304f8bf589d36810d53e3b27ee20 Author: David Sterba <dsterba@suse.cz> Date: Fri Jan 23 18:43:31 2015 +0100 btrfs: add read-only check to sysfs handler of features We don't want to trigger the change on a read-only filesystem, similar to what the label handler does. Signed-off-by: David Sterba <dsterba@suse.cz> fs/btrfs/sysfs.c | 3 +++ 1 file changed, 3 insertions(+) commit e6c11f9a462e9ef4876d5e1539a6c06eded4c793 Author: David Sterba <dsterba@suse.com> Date: Thu Mar 24 18:00:53 2016 +0100 btrfs: reuse existing variable in scrub_stripe, reduce stack usage The key variable occupies 17 bytes, the key_start is used once, we can simply reuse existing 'key' for that purpose. As the key is not a simple type, compiler doest not do it on itself. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/scrub.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) commit 49a3c4d9b64d2e5d6fd268d53153945d04cb5559 Author: David Sterba <dsterba@suse.com> Date: Thu Mar 24 17:49:22 2016 +0100 btrfs: use dynamic allocation for root item in create_subvol The size of root item is more than 400 bytes, which is quite a lot of stack space. As we do IO from inside the subvolume ioctls, we should keep the stack usage low in case the filesystem is on top of other layers (NFS, device mapper, iscsi, etc). Reviewed-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 65 ++++++++++++++++++++++++++++++++------------------------ 1 file changed, 37 insertions(+), 28 deletions(-) commit 153519559a39725c5a45269256fec0efb81bcd1f Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:40:08 2016 +0200 btrfs: clone: use vmalloc only as fallback for nodesize bufer Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 2f91306a37809907474a06c1defdb1ff50be06f0 Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:40:08 2016 +0200 btrfs: send: use vmalloc only as fallback for clone_sources_tmp Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit c03d01f3404282712b9fd280297f133860c91c93 Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:40:08 2016 +0200 btrfs: send: use vmalloc only as fallback for clone_roots Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit e55d1153dbf48485a74eb4bf4eefeaedcf1486a9 Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:52:02 2016 +0200 btrfs: send: use temporary variable to store allocation size We're going to use the argument multiple times later. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit eb5b75fe2e61a9ba907785b70318736112b0cf93 Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:40:08 2016 +0200 btrfs: send: use vmalloc only as fallback for read_buf Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit 6ff48ce06b07255a6459cd8b816a110971a81f00 Author: David Sterba <dsterba@suse.com> Date: Mon Apr 11 18:40:08 2016 +0200 btrfs: send: use vmalloc only as fallback for send_buf Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit 779bf3fefa835cb52a07457c8acac6f2f66f2493 Author: Anand Jain <anand.jain@oracle.com> Date: Mon Apr 18 16:51:23 2016 +0800 btrfs: fix lock dep warning, move scratch dev out of device_list_mutex and uuid_mutex When the replace target fails, the target device will be taken out of fs device list, scratch + update_dev_time and freed. However we could do the scratch + update_dev_time and free part after the device has been taken out of device list, so that we don't have to hold the device_list_mutex and uuid_mutex locks. Reported issue: [ 5375.718845] ====================================================== [ 5375.718846] [ INFO: possible circular locking dependency detected ] [ 5375.718849] 4.4.5-scst31x-debug-11+ #40 Not tainted [ 5375.718849] ------------------------------------------------------- [ 5375.718851] btrfs-health/4662 is trying to acquire lock: [ 5375.718861] (sb_writers){.+.+.+}, at: [<ffffffff812214f7>] __sb_start_write+0xb7/0xf0 [ 5375.718862] [ 5375.718862] but task is already holding lock: [ 5375.718907] (&fs_devs->device_list_mutex){+.+.+.}, at: [<ffffffffa028263c>] btrfs_destroy_dev_replace_tgtdev+0x3c/0x150 [btrfs] [ 5375.718907] [ 5375.718907] which lock already depends on the new lock. [ 5375.718907] [ 5375.718908] [ 5375.718908] the existing dependency chain (in reverse order) is: [ 5375.718911] [ 5375.718911] -> #3 (&fs_devs->device_list_mutex){+.+.+.}: [ 5375.718917] [<ffffffff810da4be>] lock_acquire+0xce/0x1e0 [ 5375.718921] [<ffffffff81633949>] mutex_lock_nested+0x69/0x3c0 [ 5375.718940] [<ffffffffa0219bf6>] btrfs_show_devname+0x36/0x210 [btrfs] [ 5375.718945] [<ffffffff81267079>] show_vfsmnt+0x49/0x150 [ 5375.718948] [<ffffffff81240b07>] m_show+0x17/0x20 [ 5375.718951] [<ffffffff81246868>] seq_read+0x2d8/0x3b0 [ 5375.718955] [<ffffffff8121df28>] __vfs_read+0x28/0xd0 [ 5375.718959] [<ffffffff8121e806>] vfs_read+0x86/0x130 [ 5375.718962] [<ffffffff8121f4c9>] SyS_read+0x49/0xa0 [ 5375.718966] [<ffffffff81637976>] entry_SYSCALL_64_fastpath+0x16/0x7a [ 5375.718968] [ 5375.718968] -> #2 (namespace_sem){+++++.}: [ 5375.718971] [<ffffffff810da4be>] lock_acquire+0xce/0x1e0 [ 5375.718974] [<ffffffff81635199>] down_write+0x49/0x80 [ 5375.718977] [<ffffffff81243593>] lock_mount+0x43/0x1c0 [ 5375.718979] [<ffffffff81243c13>] do_add_mount+0x23/0xd0 [ 5375.718982] [<ffffffff81244afb>] do_mount+0x27b/0xe30 [ 5375.718985] [<ffffffff812459dc>] SyS_mount+0x8c/0xd0 [ 5375.718988] [<ffffffff81637976>] entry_SYSCALL_64_fastpath+0x16/0x7a [ 5375.718991] [ 5375.718991] -> #1 (&sb->s_type->i_mutex_key#5){+.+.+.}: [ 5375.718994] [<ffffffff810da4be>] lock_acquire+0xce/0x1e0 [ 5375.718996] [<ffffffff81633949>] mutex_lock_nested+0x69/0x3c0 [ 5375.719001] [<ffffffff8122d608>] path_openat+0x468/0x1360 [ 5375.719004] [<ffffffff8122f86e>] do_filp_open+0x7e/0xe0 [ 5375.719007] [<ffffffff8121da7b>] do_sys_open+0x12b/0x210 [ 5375.719010] [<ffffffff8121db7e>] SyS_open+0x1e/0x20 [ 5375.719013] [<ffffffff81637976>] entry_SYSCALL_64_fastpath+0x16/0x7a [ 5375.719015] [ 5375.719015] -> #0 (sb_writers){.+.+.+}: [ 5375.719018] [<ffffffff810d97ca>] __lock_acquire+0x17ba/0x1ae0 [ 5375.719021] [<ffffffff810da4be>] lock_acquire+0xce/0x1e0 [ 5375.719026] [<ffffffff810d3bef>] percpu_down_read+0x4f/0xa0 [ 5375.719028] [<ffffffff812214f7>] __sb_start_write+0xb7/0xf0 [ 5375.719031] [<ffffffff81242eb4>] mnt_want_write+0x24/0x50 [ 5375.719035] [<ffffffff8122ded2>] path_openat+0xd32/0x1360 [ 5375.719037] [<ffffffff8122f86e>] do_filp_open+0x7e/0xe0 [ 5375.719040] [<ffffffff8121d8a4>] file_open_name+0xe4/0x130 [ 5375.719043] [<ffffffff8121d923>] filp_open+0x33/0x60 [ 5375.719073] [<ffffffffa02776a6>] update_dev_time+0x16/0x40 [btrfs] [ 5375.719099] [<ffffffffa02825be>] btrfs_scratch_superblocks+0x4e/0x90 [btrfs] [ 5375.719123] [<ffffffffa0282665>] btrfs_destroy_dev_replace_tgtdev+0x65/0x150 [btrfs] [ 5375.719150] [<ffffffffa02c6c80>] btrfs_dev_replace_finishing+0x6b0/0x990 [btrfs] [ 5375.719175] [<ffffffffa02c729e>] btrfs_dev_replace_start+0x33e/0x540 [btrfs] [ 5375.719199] [<ffffffffa02c7f58>] btrfs_auto_replace_start+0xf8/0x140 [btrfs] [ 5375.719222] [<ffffffffa02464e6>] health_kthread+0x246/0x490 [btrfs] [ 5375.719225] [<ffffffff810a70df>] kthread+0xef/0x110 [ 5375.719229] [<ffffffff81637d2f>] ret_from_fork+0x3f/0x70 [ 5375.719230] [ 5375.719230] other info that might help us debug this: [ 5375.719230] [ 5375.719233] Chain exists of: [ 5375.719233] sb_writers --> namespace_sem --> &fs_devs->device_list_mutex [ 5375.719233] [ 5375.719234] Possible unsafe locking scenario: [ 5375.719234] [ 5375.719234] CPU0 CPU1 [ 5375.719235] ---- ---- [ 5375.719236] lock(&fs_devs->device_list_mutex); [ 5375.719238] lock(namespace_sem); [ 5375.719239] lock(&fs_devs->device_list_mutex); [ 5375.719241] lock(sb_writers); [ 5375.719241] [ 5375.719241] *** DEADLOCK *** [ 5375.719241] [ 5375.719243] 4 locks held by btrfs-health/4662: [ 5375.719266] #0: (&fs_info->health_mutex){+.+.+.}, at: [<ffffffffa0246303>] health_kthread+0x63/0x490 [btrfs] [ 5375.719293] #1: (&fs_info->dev_replace.lock_finishing_cancel_unmount){+.+.+.}, at: [<ffffffffa02c6611>] btrfs_dev_replace_finishing+0x41/0x990 [btrfs] [ 5375.719319] #2: (uuid_mutex){+.+.+.}, at: [<ffffffffa0282620>] btrfs_destroy_dev_replace_tgtdev+0x20/0x150 [btrfs] [ 5375.719343] #3: (&fs_devs->device_list_mutex){+.+.+.}, at: [<ffffffffa028263c>] btrfs_destroy_dev_replace_tgtdev+0x3c/0x150 [btrfs] [ 5375.719343] [ 5375.719343] stack backtrace: [ 5375.719347] CPU: 2 PID: 4662 Comm: btrfs-health Not tainted 4.4.5-scst31x-debug-11+ #40 [ 5375.719348] Hardware name: Supermicro SYS-6018R-WTRT/X10DRW-iT, BIOS 1.0c 01/07/2015 [ 5375.719352] 0000000000000000 ffff880856f73880 ffffffff813529e3 ffffffff826182a0 [ 5375.719354] ffffffff8260c090 ffff880856f738c0 ffffffff810d667c ffff880856f73930 [ 5375.719357] ffff880861f32b40 ffff880861f32b68 0000000000000003 0000000000000004 [ 5375.719357] Call Trace: [ 5375.719363] [<ffffffff813529e3>] dump_stack+0x85/0xc2 [ 5375.719366] [<ffffffff810d667c>] print_circular_bug+0x1ec/0x260 [ 5375.719369] [<ffffffff810d97ca>] __lock_acquire+0x17ba/0x1ae0 [ 5375.719373] [<ffffffff810f606d>] ? debug_lockdep_rcu_enabled+0x1d/0x20 [ 5375.719376] [<ffffffff810da4be>] lock_acquire+0xce/0x1e0 [ 5375.719378] [<ffffffff812214f7>] ? __sb_start_write+0xb7/0xf0 [ 5375.719383] [<ffffffff810d3bef>] percpu_down_read+0x4f/0xa0 [ 5375.719385] [<ffffffff812214f7>] ? __sb_start_write+0xb7/0xf0 [ 5375.719387] [<ffffffff812214f7>] __sb_start_write+0xb7/0xf0 [ 5375.719389] [<ffffffff81242eb4>] mnt_want_write+0x24/0x50 [ 5375.719393] [<ffffffff8122ded2>] path_openat+0xd32/0x1360 [ 5375.719415] [<ffffffffa02462a0>] ? btrfs_congested_fn+0x180/0x180 [btrfs] [ 5375.719418] [<ffffffff810f606d>] ? debug_lockdep_rcu_enabled+0x1d/0x20 [ 5375.719420] [<ffffffff8122f86e>] do_filp_open+0x7e/0xe0 [ 5375.719423] [<ffffffff810f615d>] ? rcu_read_lock_sched_held+0x6d/0x80 [ 5375.719426] [<ffffffff81201a9b>] ? kmem_cache_alloc+0x26b/0x5d0 [ 5375.719430] [<ffffffff8122e7d4>] ? getname_kernel+0x34/0x120 [ 5375.719433] [<ffffffff8121d8a4>] file_open_name+0xe4/0x130 [ 5375.719436] [<ffffffff8121d923>] filp_open+0x33/0x60 [ 5375.719462] [<ffffffffa02776a6>] update_dev_time+0x16/0x40 [btrfs] [ 5375.719485] [<ffffffffa02825be>] btrfs_scratch_superblocks+0x4e/0x90 [btrfs] [ 5375.719506] [<ffffffffa0282665>] btrfs_destroy_dev_replace_tgtdev+0x65/0x150 [btrfs] [ 5375.719530] [<ffffffffa02c6c80>] btrfs_dev_replace_finishing+0x6b0/0x990 [btrfs] [ 5375.719554] [<ffffffffa02c6b23>] ? btrfs_dev_replace_finishing+0x553/0x990 [btrfs] [ 5375.719576] [<ffffffffa02c729e>] btrfs_dev_replace_start+0x33e/0x540 [btrfs] [ 5375.719598] [<ffffffffa02c7f58>] btrfs_auto_replace_start+0xf8/0x140 [btrfs] [ 5375.719621] [<ffffffffa02464e6>] health_kthread+0x246/0x490 [btrfs] [ 5375.719641] [<ffffffffa02463d8>] ? health_kthread+0x138/0x490 [btrfs] [ 5375.719661] [<ffffffffa02462a0>] ? btrfs_congested_fn+0x180/0x180 [btrfs] [ 5375.719663] [<ffffffff810a70df>] kthread+0xef/0x110 [ 5375.719666] [<ffffffff810a6ff0>] ? kthread_create_on_node+0x200/0x200 [ 5375.719669] [<ffffffff81637d2f>] ret_from_fork+0x3f/0x70 [ 5375.719672] [<ffffffff810a6ff0>] ? kthread_create_on_node+0x200/0x200 [ 5375.719697] ------------[ cut here ]------------ Signed-off-by: Anand Jain <anand.jain@oracle.com> Reported-by: Yauhen Kharuzhy <yauhen.kharuzhy@zavadatar.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit f5ecec3ce21f706e9e7a330b2e8e5a2941927b46 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:40:59 2016 +0300 btrfs: send: silence an integer overflow warning The "sizeof(*arg->clone_sources) * arg->clone_sources_count" expression can overflow. It causes several static checker warnings. It's all under CAP_SYS_ADMIN so it's not that serious but lets silence the warnings. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/send.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 41b34accb265e3a20211a7a8ef3625678f1c6ec7 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Wed Mar 30 23:18:14 2016 +0100 btrfs: avoid overflowing f_bfree Since mixed block groups accounting isn't byte-accurate and f_bree is an unsigned integer, it could overflow. Avoid this. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Suggested-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/super.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit ae02d1bd070767e109f4a6f1bb1f466e9698a355 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Wed Mar 30 21:53:38 2016 +0100 btrfs: fix mixed block count of available space Metadata for mixed block is already accounted in total data and should not be counted as part of the free metadata space. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Link: https://bugzilla.kernel.org/show_bug.cgi?id=114281 Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/super.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 88be159c905a2b4f6d59afa352bef410afb6af02 Author: Austin S. Hemmelgarn <ahferroin7@gmail.com> Date: Wed Mar 23 14:22:59 2016 -0400 btrfs: allow balancing to dup with multi-device Currently, we don't allow the user to try and rebalance to a dup profile on a multi-device filesystem. In most cases, this is a perfectly sensible restriction as raid1 uses the same amount of space and provides better protection. However, when reshaping a multi-device filesystem down to a single device filesystem, this requires the user to convert metadata and system chunks to single profile before deleting devices, and then convert again to dup, which leaves a period of time where metadata integrity is reduced. This patch removes the single-device-only restriction from converting to dup profile to remove this potential data integrity reduction. Signed-off-by: Austin S. Hemmelgarn <ahferroin7@gmail.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit e8364275f9a34481c9a38be757b675f8d1689d46 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Thu Mar 3 14:50:17 2016 -0300 [media] dw2102: move USB IDs to dvb-usb-ids.h Right now, dw2102 assumes that the USB IDs will be either at an external header or defined internally. That doesn't sound right. So, let's move the definitions to just one place. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-core/dvb-usb-ids.h | 13 ++++++++ drivers/media/usb/dvb-usb/dw2102.c | 60 ++---------------------------------- 2 files changed, 16 insertions(+), 57 deletions(-) commit bf14e74cef06efc18fc769cbc331c6612dca214b Author: Julian Scheel <julian@jusst.de> Date: Tue Feb 23 18:11:21 2016 -0300 [media] media: adv7180: Add of compatible strings for full family Add entries for all supported chip variants into the of_match list, so that the matching driver_info can be selected when using dt. Signed-off-by: Julian Scheel <julian@jusst.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/devicetree/bindings/media/i2c/adv7180.txt | 13 +++++++++++-- drivers/media/i2c/adv7180.c | 8 ++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) commit b9894728c2de35bab54f0f47b92b43a927ad7b37 Author: Julian Scheel <julian@jusst.de> Date: Tue Feb 23 18:11:20 2016 -0300 [media] media: adv7180: Add device tree binding document Add device tree binding documentation for the adv7180 video decoder family. Signed-off-by: Julian Scheel <julian@jusst.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> .../devicetree/bindings/media/i2c/adv7180.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 78bab93026ab95b6c8b9e8770ef7089f7d40b2d5 Author: Antti Palosaari <crope@iki.fi> Date: Mon Feb 8 09:51:16 2016 -0200 [media] si2157: detect if firmware is running Detect if firmware is running run-time and download / start it only when needed. Detection is done by reading IF frequency value. Garbage value is returned by firmware when it is not running, otherwise correct value is returned. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/tuners/si2157.c | 19 +++++++++++++------ drivers/media/tuners/si2157_priv.h | 1 - 2 files changed, 13 insertions(+), 7 deletions(-) commit e5ef27d0f5acf9f1db2882d7546a41c021f66820 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:21 2016 +0100 sched: Make hrtick_notifier an explicit call No need for an extra notifier. We don't need to handle all these states. It's sufficient to kill the timer when the cpu dies. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.770528462@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 34 +--------------------------------- 1 file changed, 1 insertion(+), 33 deletions(-) commit 20a5c8cc74ade5027c2b0e2bc724278afd6054f3 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:20 2016 +0100 sched/fair: Make ilb_notifier an explicit call No need for an extra notifier. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.693720241@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 1 + kernel/sched/fair.c | 15 +-------------- kernel/sched/sched.h | 4 ++++ 3 files changed, 6 insertions(+), 14 deletions(-) commit aaddd7d1c740ab3c5efaad7a34650b6dc680c21c Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:19 2016 +0100 sched/hotplug: Make activate() the last hotplug step The scheduler can handle per cpu threads before the cpu is set to active and it does not allow user space threads on the cpu before active is set. Attaching to the scheduling domains is also not required before user space threads can be handled. Move the activation to the end of the hotplug state space. That also means that deactivation is the first action when a cpu is shut down. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.597477199@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/cpuhotplug.h | 2 +- kernel/cpu.c | 15 +++++++++------ 2 files changed, 10 insertions(+), 7 deletions(-) commit f2785ddb5367e217365099294b89d6a84668069e Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:18 2016 +0100 sched/hotplug: Move migration CPU_DYING to sched_cpu_dying() Remove the hotplug notifier and make it an explicit state. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.502222097@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/cpu.h | 2 -- include/linux/sched.h | 6 +++++ kernel/cpu.c | 2 +- kernel/sched/core.c | 72 ++++++++++++++++----------------------------------- 4 files changed, 29 insertions(+), 53 deletions(-) commit 7d97669933eb94245ec9b715753753ec5ca8f646 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:17 2016 +0100 sched/migration: Move CPU_ONLINE into scheduler state The alleged requirement that the migration notifier has a lower priority than perf is completely undocumented and there is no indication at all that this is true. perf does not even handle the CPU_ONLINE notification and perf really has nothing to do with migration. Move the CPU_ONLINE code into the sched_activate_cpu() state callback. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.421743581@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 33 ++++++++++++++++++++++----------- 1 file changed, 22 insertions(+), 11 deletions(-) commit e9cd8fa4fcfd67c95db9b87c0fff88fa23cb00e5 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:16 2016 +0100 sched/migration: Move calc_load_migrate() into CPU_DYING It really does not matter when we fold the load for the outgoing cpu. It's almost dead anyway, so there is no harm if we fail to fold the few microseconds which are required for going fully away. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.328739226@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 3 --- 1 file changed, 3 deletions(-) commit 94baf7a5d882cde0b4d591f4ab89cc32ee39ac6a Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:15 2016 +0100 sched/migration: Move prepare transition to SCHED_STARTING state We can piggy pack that on the SCHED_STARTING state. It's not required before the cpu actually comes online. Name the function proper as it has nothing to do with migration. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.248226511@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit b2454caa8977ade27292a71f2def5e403e24b4d5 Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Mar 10 12:54:14 2016 +0100 sched/hotplug: Move sync_rcu to be with set_cpu_active(false) The sync_rcu stuff is specificically for clearing bits in the active mask, such that everybody will observe the bit cleared and will not consider the cleared CPU for load-balancing etc. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160310120025.169219710@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/cpu.c | 15 --------------- kernel/sched/core.c | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 15 deletions(-) commit 40190a78f85fec29f0fdd21f6b4415712085711e Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:13 2016 +0100 sched/hotplug: Convert cpu_[in]active notifiers to state machine Now that we reduced everything into single notifiers, it's simple to move them into the hotplug state machine space. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/cpu.h | 12 --------- include/linux/cpuhotplug.h | 1 + include/linux/sched.h | 2 ++ kernel/cpu.c | 8 ++++-- kernel/sched/core.c | 67 +++++++++++++++------------------------------- 5 files changed, 30 insertions(+), 60 deletions(-) commit c6d2c7475ced868cfc636cd5a55a428da94537c3 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:12 2016 +0100 sched: Move sched_domains_numa_masks_clear() to DOWN_PREPARE This is the last operation on the cpu before vanishing. No point in calling that on CPU_DEAD. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 3 --- 1 file changed, 3 deletions(-) commit 135fb3e19773e66f56b60e3b9fdda6166e77c55d Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:11 2016 +0100 sched: Consolidate the notifier maze We can maintain the ordering of the scheduler cpu hotplug functionality nicely in one notifer. Get rid of the maze. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/cpu.h | 12 ++-- kernel/sched/core.c | 174 +++++++++++++++++++++------------------------------- 2 files changed, 73 insertions(+), 113 deletions(-) commit e26fbffd32c28107d9d268b432706ccf84fb6411 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:10 2016 +0100 sched: Allow hotplug notifiers to be setup early Prevent the SMP scheduler related notifiers to be executed before the smp scheduler is initialized and install them early. This is a preparatory change for further consolidation of the hotplug notifier maze. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> kernel/sched/core.c | 59 ++++++++++++++++++++++++++++++++--------------------- 1 file changed, 36 insertions(+), 23 deletions(-) commit 9cf7243d5d83d27aca47f842107bfa02b5f11d16 Author: Thomas Gleixner <tglx@linutronix.de> Date: Thu Mar 10 12:54:09 2016 +0100 sched: Make set_cpu_rq_start_time() a built in hotplug state Start distangling the maze of hotplug notifiers in the scheduler. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: rt@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/cpuhotplug.h | 1 + include/linux/sched.h | 1 + kernel/cpu.c | 6 ++++++ kernel/sched/core.c | 16 +++++++++------- 4 files changed, 17 insertions(+), 7 deletions(-) commit e9d867a67fd03ccc07248ca4e9c2f74fed494d5b Author: Peter Zijlstra (Intel) <peterz@infradead.org> Date: Thu Mar 10 12:54:08 2016 +0100 sched: Allow per-cpu kernel threads to run on online && !active In order to enable symmetric hotplug, we must mirror the online && !active state of cpu-down on the cpu-up side. However, to retain sanity, limit this state to per-cpu kthreads. Aside from the change to set_cpus_allowed_ptr(), which allow moving the per-cpu kthreads on, the other critical piece is the cpu selection for pinned tasks in select_task_rq(). This avoids dropping into select_fallback_rq(). select_fallback_rq() cannot be allowed to select !active cpus because its used to migrate user tasks away. And we do not want to move user tasks onto cpus that are in transition. Requested-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Tested-by: Thomas Gleixner <tglx@linutronix.de> Cc: Lai Jiangshan <laijs@cn.fujitsu.com> Cc: Jan H. Schönherr <jschoenh@amazon.de> Cc: Oleg Nesterov <oleg@redhat.com> Cc: rt@linutronix.de Link: http://lkml.kernel.org/r/20160301152303.GV6356@twins.programming.kicks-ass.net Signed-off-by: Thomas Gleixner <tglx@linutronix.de> arch/powerpc/kernel/smp.c | 2 +- arch/s390/kernel/smp.c | 2 +- include/linux/cpumask.h | 6 ++---- kernel/sched/core.c | 49 ++++++++++++++++++++++++++++++++++++++++------- 4 files changed, 46 insertions(+), 13 deletions(-) commit 2355ac8495c1fb8ae58bdfe191489682538c697d Author: David Sterba <dsterba@suse.cz> Date: Thu Apr 28 11:59:34 2016 +0200 btrfs: ioctl: reorder exclusive op check in RM_DEV Move the op exclusivity check before the other code (same as in ADD_DEV). Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) commit 58409edd2d5cc24716cb9ce690803696c5118503 Author: David Sterba <dsterba@suse.com> Date: Wed May 4 11:46:10 2016 +0200 btrfs: kill unused writepage_io_hook callback It seems to be long time unused, since 2008 and 6885f308b5570 ("Btrfs: Misc 2.6.25 updates"). Propagating the removal touches some code but has no functional effect. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 39 ++++++++++++++++----------------------- fs/btrfs/extent_io.h | 1 - 2 files changed, 16 insertions(+), 24 deletions(-) commit 9485e4ca0b486248ce07d7dd1411a1080d24ed0d Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 01:30:37 2016 +0200 cpufreq: governor: Fix handling of special cases in dbs_update() As reported in KBZ 69821: "With CONFIG_HZ_PERIODIC=y cpu stays at the lowest frequcency 800MHz even if usage goes to 100%, frequency does not scale up, the governor in use is ondemand. Neither works conservative. Performance and userspace governors work as expected. With CONFIG_NO_HZ_IDLE or CONFIG_NO_HZ_FULL cpu scales up with ondemand as expected." Analysis carried out by Chen Yu leads to the conclusion that the observed issue is due to idle_time in dbs_update() representing a negative number in which case the function will return 0 as the load (unless load is greater than 0 for another CPU sharing the policy), although that need not be the right choice. Indeed, idle_time representing a negative number means that during the last sampling interval the CPU was almost 100% busy on the rough average, so 100 should be returned as the load in that case. Modify the code accordingly and rearrange it to clarify the handling of all of the special cases in it. While at it, also avoid returning zero as the load if time_elapsed is 0 (it doesn't really make sense to return 0 then). Link: https://bugzilla.kernel.org/show_bug.cgi?id=69821 Tested-by: Chen Yu <yu.c.chen@intel.com> Tested-by: Timo Valtoaho <timo.valtoaho@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq_governor.c | 87 ++++++++++++++++++++++---------------- 1 file changed, 51 insertions(+), 36 deletions(-) commit 923dd88d3cf87ed3751d3ce8a8abc43fdbb4632b Author: CK Hu <ck.hu@mediatek.com> Date: Mon Jan 4 18:36:33 2016 +0100 dt-bindings: drm/mediatek: Add Mediatek display subsystem dts binding Add device tree binding documentation for the display subsystem in Mediatek MT8173 SoCs. Signed-off-by: CK Hu <ck.hu@mediatek.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Rob Herring <robh@kernel.org> .../bindings/display/mediatek/mediatek,disp.txt | 203 +++++++++++++++++++++ .../bindings/display/mediatek/mediatek,dpi.txt | 35 ++++ .../bindings/display/mediatek/mediatek,dsi.txt | 60 ++++++ 3 files changed, 298 insertions(+) commit cb1b5dff49a16433063eb94022b4182af56aedd9 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Wed Apr 27 10:48:00 2016 +0200 memory: mtk-smi: export mtk_smi_larb_get/put To allow building mediatek-drm.ko as a module, the mtk_smi_larb_get and mtk_smi_larb_put symbols have to be exported. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/memory/mtk-smi.c | 2 ++ 1 file changed, 2 insertions(+) commit 9919a65ec532799544dfdfd6df6f994b74c12b42 Author: Chris Phlipot <cphlipot0@gmail.com> Date: Thu Apr 28 01:19:06 2016 -0700 perf callchain: Fix incorrect ordering of entries The existing implementation of thread__resolve_callchain, under certain circumstances, can assemble callchain entries in the incorrect order. The callchain entries are resolved incorrectly for a sample when all of the following conditions are met: 1. callchain_param.order is set to ORDER_CALLER 2. thread__resolve_callchain_sample is able to resolve callchain entries for the sample. 3. unwind__get_entries is also able to resolve callchain entries for the sample. The fix is accomplished by reversing the order in which thread__resolve_callchain_sample and unwind__get_entries are called when callchain_param.order is set to ORDER_CALLER. Unwind specific code from thread__resolve_callchain is also moved into a new static function to improve readability of the fix. How to Reproduce the Existing Bug: Modifying perf script to print call trees in the opposite order or applying the remaining patches from this series and comparing the results output from export-to-postgtresql.py are the easiest ways to see the bug, however it can still be seen in current builds using perf report. Here is how i can reproduce the bug using perf report: # perf record --call-graph=dwarf stress -c 1 -t 5 when i run this command: # perf report --call-graph=flat,0,0,callee This callchain, containing kernel (handle_irq_event, etc) and userspace samples (__libc_start_main, etc) is contained in the output, which looks correct (callee order): gen8_irq_handler handle_irq_event_percpu handle_irq_event handle_edge_irq handle_irq do_IRQ ret_from_intr __random rand 0x558f2a04dded 0x558f2a04c774 __libc_start_main 0x558f2a04dcd9 Now run this command using caller order: # perf report --call-graph=flat,0,0,caller It is expected to see the exact reverse of the above when using caller order (with "0x558f2a04dcd9" at the top and "gen8_irq_handler" at the bottom) in the output, but it is nowhere to be found. instead you see this: ret_from_intr do_IRQ handle_irq handle_edge_irq handle_irq_event handle_irq_event_percpu gen8_irq_handler 0x558f2a04dcd9 __libc_start_main 0x558f2a04c774 0x558f2a04dded rand __random Notice how internally the kernel symbols are reversed and the user space symbols are reversed, but the kernel symbols still appear above the user space symbols. if this patch is applied and perf script is re-run, you will see the expected output (with "0x558f2a04dcd9" at the top and "gen8_irq_handler" at the bottom): 0x558f2a04dcd9 __libc_start_main 0x558f2a04c774 0x558f2a04dded rand __random ret_from_intr do_IRQ handle_irq handle_edge_irq handle_irq_event handle_irq_event_percpu gen8_irq_handler Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461831551-12213-2-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/machine.c | 56 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 41 insertions(+), 15 deletions(-) commit 5bb1cc0ff9a6b68871970737e6c4c16919928d8b Author: Catalin Marinas <catalin.marinas@arm.com> Date: Thu May 5 10:44:02 2016 +0100 arm64: Ensure pmd_present() returns false after pmd_mknotpresent() Currently, pmd_present() only checks for a non-zero value, returning true even after pmd_mknotpresent() (which only clears the type bits). This patch converts pmd_present() to using pte_present(), similar to the other pmd_*() checks. As a side effect, it will return true for PROT_NONE mappings, though they are not yet used by the kernel with transparent huge pages. For consistency, also change pmd_mknotpresent() to only clear the PMD_SECT_VALID bit, even though the PMD_TABLE_BIT is already 0 for block mappings (no functional change). The unused PMD_SECT_PROT_NONE definition is removed as transparent huge pages use the pte page prot values. Fixes: 9c7e535fcc17 ("arm64: mm: Route pmd thp functions through pte equivalents") Cc: <stable@vger.kernel.org> # 3.15+ Reviewed-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable-hwdef.h | 1 - arch/arm64/include/asm/pgtable.h | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) commit ab4db1f2244dfc5ecd7adf9927c29cd654cc14c6 Author: Catalin Marinas <catalin.marinas@arm.com> Date: Thu May 5 10:44:01 2016 +0100 arm64: Replace hard-coded values in the pmd/pud_bad() macros This patch replaces the hard-coded value 2 with PMD_TABLE_BIT in the pmd/pud_bad() macros. Note that using these macros on pmd_trans_huge() entries is giving incorrect results (pmd_none_or_trans_huge_or_clear_bad() correctly checks for pmd_trans_huge before pmd_bad). Additionally, white-space clean-up for pmd_mkclean(). Reviewed-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 282aa7051b0169991b34716f0f22d9c2f59c46c4 Author: Catalin Marinas <catalin.marinas@arm.com> Date: Thu May 5 10:44:00 2016 +0100 arm64: Implement pmdp_set_access_flags() for hardware AF/DBM The update to the accessed or dirty states for block mappings must be done atomically on hardware with support for automatic AF/DBM. The ptep_set_access_flags() function has been fixed as part of commit 66dbd6e61a52 ("arm64: Implement ptep_set_access_flags() for hardware AF/DBM"). This patch brings pmdp_set_access_flags() in line with the pte counterpart. Fixes: 2f4b829c625e ("arm64: Add support for hardware updates of the access and dirty pte bits") Cc: <stable@vger.kernel.org> # 4.4.x: 66dbd6e61a52: arm64: Implement ptep_set_access_flags() for hardware AF/DBM Cc: <stable@vger.kernel.org> # 4.3+ Reviewed-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 911f56eeb87ee378f5e215469268a7a2f68a5a8a Author: Catalin Marinas <catalin.marinas@arm.com> Date: Thu May 5 10:43:59 2016 +0100 arm64: Fix typo in the pmdp_huge_get_and_clear() definition With hardware AF/DBM support, pmd modifications (transparent huge pages) should be performed atomically using load/store exclusive. The initial patches defined the get-and-clear function and __HAVE_ARCH_* macro without the "huge" word, leaving the pmdp_huge_get_and_clear() to the default, non-atomic implementation. Fixes: 2f4b829c625e ("arm64: Add support for hardware updates of the access and dirty pte bits") Cc: <stable@vger.kernel.org> # 4.3+ Reviewed-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 4c4d6e519091a3551a0ad2e2e8423d77f3000400 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 5 23:38:05 2016 -0300 perf trace: Do not print raw args list for syscalls with no args The test to check if the arg format had been read from the syscall:sys_enter_name/format file was looking at the list of non-commom fields, and if that is empty, it would think it had failed to read it, because it doesn't exist, for instance, for the clone() syscall. So instead before dumping the raw syscall args list check IS_ERR(sc->tp_format), if that is true, then an attempt was made to read the format file and failed, in which case dump the raw arg list values. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ls7pmdqb2xy9339vdburwvnk@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 8a73faab0a6b6c620c62f24fc991d0ad653b848b Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Feb 12 12:27:18 2016 -0200 [media] zl10353: use div_u64 instead of do_div Using div_u64() instead of do_div() makes the code slightly more readable by humans. [mchehab@osg.samsung.org: originally, this patch was proposed as a bug fix for a gcc bug. This was solved already, but it is still better to use div_u64, instead of do_div, so I'm applying it, removing the comments about the gcc bug] Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-frontends/zl10353.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit f47b72a15a9679dd4dc1af681d4d2f1ca2815552 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu May 5 16:20:33 2016 +0530 PM / OPP: Move CONFIG_OF dependent code in a separate file Recently, a few issues were noticed in the code where CONFIG_OF wasn't consistently used for many routines. The core file is big enough now and ifdef hackery makes it less readable. Move OF-specific code to another file and compile that only if CONFIG_OF is enabled. Compile-tested: - For ARM (exynos) with CONFIG_OF enabled - For X86 with CONFIG_OF disabled (have to enable CONFIG_PM_OPP separately) No functional changes. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Tested-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/Makefile | 1 + drivers/base/power/opp/core.c | 448 +----------------------------- drivers/base/power/opp/cpu.c | 143 +--------- drivers/base/power/opp/of.c | 591 ++++++++++++++++++++++++++++++++++++++++ drivers/base/power/opp/opp.h | 14 + 5 files changed, 618 insertions(+), 579 deletions(-) commit 74216699ddcca13541e8494cb2b995e6a44a04d9 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 01:27:09 2016 +0200 ACPI / tables: Fix DSDT override mechanism Commit 5ae74f2cc2f1 (ACPI / tables: Move table override mechanisms to tables.c) forgot to move the CONFIG_ACPI_CUSTOM_DSDT_FILE inclusion directive from osl.c to tables.c. Fix that. Fixes: 5ae74f2cc2f1 (ACPI / tables: Move table override mechanisms to tables.c) Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Lv Zheng <lv.zheng@intel.com> drivers/acpi/osl.c | 4 ---- drivers/acpi/tables.c | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-) commit bbe848ec1a77dd2f9e739a7d5dca11d2ea11c09d Merge: 0a93aae 698e2a8 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Fri May 6 11:50:52 2016 +0200 Merge tag 'ipvs2-for-v4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs-next Simon Horman says: ==================== Second Round of IPVS Updates for v4.7 please consider these enhancements to the IPVS. They allow its DoS mitigation strategy effective in conjunction with the SIP persistence engine. ==================== Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> commit 0a93aaedc46af2c5feecfb1066d98bfb491ec0b8 Author: Florian Westphal <fw@strlen.de> Date: Fri May 6 00:51:49 2016 +0200 netfilter: conntrack: use a single expectation table for all namespaces We already include netns address in the hash and compare the netns pointers during lookup, so even if namespaces have overlapping addresses entries will be spread across the expectation table. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_expect.h | 1 + include/net/netns/conntrack.h | 1 - .../netfilter/nf_conntrack_l3proto_ipv4_compat.c | 6 ++-- net/netfilter/nf_conntrack_expect.c | 42 ++++++++++------------ net/netfilter/nf_conntrack_helper.c | 2 +- net/netfilter/nf_conntrack_netlink.c | 6 ++-- 6 files changed, 25 insertions(+), 33 deletions(-) commit a9a083c3878f28e9d368f6dfb1a79a6f04ad8123 Author: Florian Westphal <fw@strlen.de> Date: Fri May 6 00:51:48 2016 +0200 netfilter: conntrack: make netns address part of expect hash Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_expect.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 03d7dc5cdfe6fd4e5bd04cfc2be7ae259f956428 Author: Florian Westphal <fw@strlen.de> Date: Fri May 6 00:51:47 2016 +0200 netfilter: conntrack: check netns when walking expect hash Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c | 3 +++ net/netfilter/nf_conntrack_expect.c | 19 +++++++++++++++---- net/netfilter/nf_conntrack_netlink.c | 12 ++++++++++++ 3 files changed, 30 insertions(+), 4 deletions(-) commit a10e2bde5d9173570d97a4d7cdf038232baaf47e Author: Lucas Stach <l.stach@pengutronix.de> Date: Wed Apr 27 12:27:02 2016 +0200 drm/etnaviv: fix mmap operations for userptr and dma-buf objects Add an indirect object operations call to allow distinct implementations of the mmap operation based on the type of the object. This ensures that the exporter is called to set up the mmap for imported dma-bufs and disallows mapping of userptr objects through the DRM file, as this might lead to serious corruption of kernel internal state. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> drivers/gpu/drm/etnaviv/etnaviv_gem.c | 10 +++++++++- drivers/gpu/drm/etnaviv/etnaviv_gem.h | 1 + drivers/gpu/drm/etnaviv/etnaviv_gem_prime.c | 7 +++++++ 3 files changed, 17 insertions(+), 1 deletion(-) commit 0e7f26e6b950fe586c8aa6ff6f87b9936ae32ebb Author: Lucas Stach <l.stach@pengutronix.de> Date: Wed Apr 27 12:12:00 2016 +0200 drm/etnaviv: take etnaviv_gem_obj in etnaviv_gem_mmap_obj This function will be changed to be called indirectly and this prototype change brings it in line with all the other indirect object calls. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> drivers/gpu/drm/etnaviv/etnaviv_gem.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 946dd8d5ec680c0831ed27a9bab8afa424f2c5a8 Author: Lucas Stach <l.stach@pengutronix.de> Date: Wed Mar 23 18:24:45 2016 +0100 drm/etnaviv: use deferrable timer for hangcheck handler The hangcheck handler is already running with very coarse timeouts, so it doesn't hurt to combine this timer with other wakeups in the system. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6f3ffc19157a14b182d9d0c449cd613cef421fe1 Author: Lucas Stach <l.stach@pengutronix.de> Date: Tue Jan 12 18:17:19 2016 +0100 timer: add setup_deferrable_timer macro Add the trivial missing macro to setup a deferrable timer. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Acked-by: Thomas Gleixner <tglx@linutronix.de> include/linux/timer.h | 2 ++ 1 file changed, 2 insertions(+) commit 80d6737b27bbdf645a815c136606836b435f0268 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Thu Apr 28 19:03:40 2016 -0300 leds: gpio: Support the "panic-indicator" firmware property Calling a GPIO LEDs is quite likely to work even if the kernel has paniced, so they are ideal to blink in this situation. This commit adds support for the new "panic-indicator" firmware property, allowing to mark a given LED to blink on a kernel panic. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Matthias Brugger <mbrugger@suse.com> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> Documentation/devicetree/bindings/leds/leds-gpio.txt | 2 ++ drivers/leds/leds-gpio.c | 4 ++++ include/linux/leds.h | 1 + 3 files changed, 7 insertions(+) commit e4f4f7091ee6d085c4a84b4023a61483d71bc777 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Thu Apr 28 19:03:39 2016 -0300 devicetree: leds: Introduce "panic-indicator" optional property It's desirable to specify which LEDs are to be blinked on a kernel panic. Therefore, introduce a devicetree boolean property to mark which LEDs should be treated this way, if possible. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Matthias Brugger <mbrugger@suse.com> Acked-by: Rob Herring <rob@kernel.org> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> Documentation/devicetree/bindings/leds/common.txt | 3 +++ 1 file changed, 3 insertions(+) commit ba93cdce5bbe6929fd7486f87c985598ded8f451 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Thu Apr 28 19:03:38 2016 -0300 leds: triggers: Allow to switch the trigger to "panic" on a kernel panic This commit adds a new led_cdev flag LED_PANIC_INDICATOR, which allows to mark a specific LED to be switched to the "panic" trigger, on a kernel panic. This is useful to allow the user to assign a regular trigger to a given LED, and still blink that LED on a kernel panic. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Matthias Brugger <mbrugger@suse.com> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/led-triggers.c | 2 +- drivers/leds/leds.h | 1 + drivers/leds/trigger/Kconfig | 3 +++ drivers/leds/trigger/ledtrig-panic.c | 47 ++++++++++++++++++++++++++++++++++++ include/linux/leds.h | 1 + 5 files changed, 53 insertions(+), 1 deletion(-) commit 698e2a8dca98e4de32f3f630e6d9cd93753c52e1 Author: Marco Angaroni <marcoangaroni@gmail.com> Date: Tue Apr 26 21:20:22 2016 +0200 ipvs: make drop_entry protection effective for SIP-pe DoS protection policy that deletes connections to avoid out of memory is currently not effective for SIP-pe plus OPS-mode for two reasons: 1) connection templates (holding SIP call-id) are always skipped in ip_vs_random_dropentry() 2) in_pkts counter (used by drop_entry algorithm) is not incremented for connection templates This patch addresses such problems with the following changes: a) connection templates associated (via their dest) to virtual-services configured in OPS mode are included in ip_vs_random_dropentry() monitoring. This applies to SIP-pe over UDP (which requires OPS mode), but is more general principle: when OPS is controlled by templates memory can be used only by templates themselves, since OPS conns are deleted after packet is forwarded. b) OPS connections, if controlled by a template, cause increment of in_pkts counter of their template. This is already happening but only in case director is in master-slave mode (see ip_vs_sync_conn()). Signed-off-by: Marco Angaroni <marcoangaroni@gmail.com> Acked-by: Julian Anastasov <ja@ssi.bg> Signed-off-by: Simon Horman <horms@verge.net.au> net/netfilter/ipvs/ip_vs_conn.c | 22 +++++++++++++++++++--- net/netfilter/ipvs/ip_vs_core.c | 8 +++++++- 2 files changed, 26 insertions(+), 4 deletions(-) commit 9dc1969c24eff8b7d7a9a565d1047b624921ba06 Author: Yinghai Lu <yinghai@kernel.org> Date: Thu May 5 15:13:47 2016 -0700 x86/KASLR: Consolidate mem_avoid[] entries The mem_avoid[] array is used to track positions that should be avoided (like the compressed kernel, decompression code, etc) when selecting a memory position for the randomly relocated kernel. Since ZO is now at the end of the decompression buffer and the decompression code (and its heap and stack) are at the front, we can safely consolidate the decompression entry, the heap entry, and the stack entry. The boot_params memory, however, could be elsewhere, so it should be explicitly included. Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Baoquan He <bhe@redhat.com> [ Rwrote changelog, cleaned up code comments. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462486436-3707-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 77 +++++++++++++++++++++++++++++++--------- 1 file changed, 61 insertions(+), 16 deletions(-) commit 2bc1cd39fa9f659956b25e500422e700a6cd4ec3 Author: Kees Cook <keescook@chromium.org> Date: Thu May 5 15:13:46 2016 -0700 x86/boot: Clean up pointer casting Currently extract_kernel() defines the input and output buffer pointers as "unsigned char *" since that's effectively what they are. It passes these to the decompressor routine and to the ELF parser, which both logically deal with buffer pointers too. There is some casting ("unsigned long") done to validate the numerical value of the pointers, but it is relatively limited. However, choose_random_location() operates almost exclusively on the numerical representation of these pointers, so it ended up carrying a lot of "unsigned long" casts. With the future physical/virtual split these casts were going to multiply, so this attempts to solve the problem by doing all the casting in choose_random_location()'s entry and return instead of through-out the code. Adjusts argument names to be more meaningful, and changes one us of "choice" to "output" to make the future physical/virtual split more clear (i.e. "choice" should be strictly a function return value and not used as an intermediate). Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: kernel-hardening@lists.openwall.com Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1462486436-3707-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 20 ++++++++++++++------ arch/x86/boot/compressed/misc.h | 10 +++++----- 2 files changed, 19 insertions(+), 11 deletions(-) commit c0edb7467c3d21b213ff734bfe810d81d2c6ed61 Merge: 1b6de59 b6b85da Author: Ingo Molnar <mingo@kernel.org> Date: Fri May 6 08:35:14 2016 +0200 Merge tag 'perf-core-for-mingo-20160505' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Order output of 'perf trace --summary' better, now the threads will appear ascending order of number of events, and then, for each, in descending order of syscalls by the time spent in the syscalls, so that the last page produced can be the one about the most interesting thread straced, suggested by Milian Wolff (Arnaldo Carvalho de Melo) - Do not show the runtime_ms for a thread when not collecting it, that is done so far only with 'perf trace --sched' (Arnaldo Carvalho de Melo) - Fix kallsyms perf test on ppc64le (Naveen N. Rao) Infrastructure changes: - Move global variables related to presence of some keys in the sort order to a per hist struct, to allow code like the hists browser to work with multiple hists with different lists of columns (Jiri Olsa) - Add support for generating bpf prologue in powerpc (Naveen N. Rao) - Fix kprobe and kretprobe handling with kallsyms on ppc64le (Naveen N. Rao) - evlist mmap changes, prep work for supporting reading backwards (Wang Nan) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 3949c4ac8cfa8ab3518a326c72eff1a2ff489bb9 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sun May 1 14:07:23 2016 +0200 i40e: constify i40e_client_ops structure The i40e_client_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 2 +- drivers/net/ethernet/intel/i40e/i40e_client.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit ce927db48721235b3a08142b6d9f9a906e4e626f Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Apr 29 19:44:05 2016 +0200 i40e: fix misleading indentation Newly added code in i40e_vc_config_promiscuous_mode_msg() is indented in a way that gcc rightly complains about: drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c: In function 'i40e_vc_config_promiscuous_mode_msg': drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c:1543:4: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if (f->vlan >= 0 && f->vlan <= I40E_MAX_VLANID) ^~ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c:1550:5: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' aq_err = pf->hw.aq.asq_last_status; From the context, it looks like the aq_err assignment was meant to be inside of the conditional expression, so I'm adding the appropriate curly braces now. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 5676a8b9cd9a ("i40e: Add VF promiscuous mode driver support") Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 147e81ec7568933a51fe58b64244383e929870fb Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:49 2016 -0700 i40e: Test memory before ethtool alloc succeeds When testing on systems with very limited amounts of RAM, a bug was found where, while changing the number of descriptors using ethtool, the driver didn't test the limits of system memory before permanently assuming it would be able to get receive buffer memory. Work around this issue by pre-allocation of the receive buffer memory, in the "ghost" ring, which is then used during reinit using the new ring length. Change-Id: I92d7a5fb59a6c884b2efdd1ec652845f101c3359 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 34 +++++++++++++++++++++++--- 1 file changed, 31 insertions(+), 3 deletions(-) commit b163098ea1eece88a8834952dcbade1f17378731 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Mon Apr 18 11:33:48 2016 -0700 i40evf: Allocate Rx buffers properly Allocate the correct number of RX buffers, and don't fiddle with next_to_use. The common RX code handles all of this. This fixes a memory leak of one page each time the driver is opened. Change-Id: Id06eca353086e084921f047acad28c14745684ee Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit bec60fc42b285344b027c87444c7fd6caade0ceb Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:47 2016 -0700 i40e/i40evf: Remove unused hardware receive descriptor code The hardware supports a 16 byte descriptor for receive, but the driver was never using it in production. There was no performance benefit to the real driver of 16 byte descriptors, so drop a whole lot of complexity while getting rid of the code. Also since the previous patch made us use no-split mode all the time, drop any support in the driver for any other value in dtype and assume it is always zero (aka no-split). Hooray for code removal! Change-ID: I2257e902e4dad84a07b94db6d2e6f4ce69b27bc0 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 7 +------ drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 16 +--------------- drivers/net/ethernet/intel/i40e/i40e_main.c | 18 +++++------------- drivers/net/ethernet/intel/i40e/i40e_txrx.h | 24 ++++++++++-------------- drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 24 ++++++++++-------------- 5 files changed, 27 insertions(+), 62 deletions(-) commit ab9ad98eb5f95b86490cc4c2ddbde5a0bc9bd5c6 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:46 2016 -0700 i40evf: refactor receive routine This is part 2 of the Rx refactor series, just including changes to i40evf. This refactor aligns the receive routine with the one in ixgbe which was highly optimized. This reduces the code we have to maintain and allows for (hopefully) more readable and maintainable RX hot path. In order to do this: - consolidate the receive path into a single function that doesn't use packet split but *does* use pages for Rx buffers. - remove the old _1buf routine - consolidate several routines into helper functions - remove VF ethtool control over packet split - remove priv_flags interface since it is unused Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 898 +++++++++++---------- drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 37 +- drivers/net/ethernet/intel/i40evf/i40evf.h | 5 - drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 51 -- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 3 +- 5 files changed, 481 insertions(+), 513 deletions(-) commit 19b85e677df44b954c23a47395edf5a6c379771b Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:45 2016 -0700 i40evf: Drop packet split receive routine As part of preparation for the rx-refactor, remove the packet split receive routine and ancillary code. Some of the split related context set up code stays in i40e_virtchnl_pf.c in case an older VF driver tries to load and still wants to use packet split. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 2 +- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 21 +--------------- drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 7 ------ drivers/net/ethernet/intel/i40evf/i40evf.h | 2 -- drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 14 ----------- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 28 +--------------------- .../net/ethernet/intel/i40evf/i40evf_virtchnl.c | 4 ---- 7 files changed, 3 insertions(+), 75 deletions(-) commit 1a557afc4dd59b85a5cae2be6d351eaeb31d2664 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Wed Apr 20 19:43:37 2016 -0700 i40e: Refactor receive routine This is part 1 of the Rx refactor series, just including changes to i40e. This refactor aligns the receive routine with the one in ixgbe which was highly optimized. This reduces the code we have to maintain and allows for (hopefully) more readable and maintainable RX hot path. In order to do this: - consolidate the receive path into a single function that doesn't use packet split but *does* use pages for Rx buffers. - remove the old _1buf routine - consolidate several routines into helper functions - remove ethtool control over packet split Change-ID: I5ca100721de65992aa0114f8b4bac844b84758e0 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 1 - drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 9 +- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 1 - drivers/net/ethernet/intel/i40e/i40e_main.c | 16 +- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 770 ++++++++++++++++--------- drivers/net/ethernet/intel/i40e/i40e_txrx.h | 37 +- 6 files changed, 531 insertions(+), 303 deletions(-) commit fd50c3a0326152d97ef02f0d55ee48d7ae66d73f Merge: a64424d 2c80661 Author: Dave Airlie <airlied@redhat.com> Date: Fri May 6 14:17:43 2016 +1000 Merge branch 'for-next' of http://git.agner.ch/git/linux-drm-fsl-dcu into drm-next fsl-dcu pixel clock polarity support * 'for-next' of http://git.agner.ch/git/linux-drm-fsl-dcu: drm/fsl-dcu: use bus_flags for pixel clock polarity drm: introduce bus_flags in drm_display_info commit a64424d722504926f3375bc4887976e3bfe3a01d Merge: 0552f76 84fae13 Author: Dave Airlie <airlied@redhat.com> Date: Fri May 6 14:17:22 2016 +1000 Merge branch 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux into drm-next This is the first big radeon/amdgpu pull request for 4.7. Highlights: - Polaris support in amdgpu Current display stack on par with other asics, for advanced features DAL is required Power management support Support for GFX, Compute, SDMA, UVD, VCE - VCE and UVD init/fini cleanup in radeon - GPUVM improvements - Scheduler improvements - Clockgating improvements - Powerplay improvements - TTM changes to support driver specific LRU update mechanism - Radeon support for new Mesa features - ASYNC pageflip support for radeon - Lots of bug fixes and code cleanups * 'drm-next-4.7' of git://people.freedesktop.org/~agd5f/linux: (180 commits) drm/amdgpu: Replace rcu_assign_pointer() with RCU_INIT_POINTER() drm/amdgpu: use drm_mode_vrefresh() rather than mode->vrefresh drm/amdgpu/uvd6: add bypass support for fiji (v3) drm/amdgpu/fiji: set UVD CG state when enabling UVD DPM (v2) drm/powerplay: add missing clockgating callback for tonga drm/amdgpu: Constify some tables drm/amd/powerplay: Delete dead struct declaration drm/amd/powerplay/hwmgr: don't add invalid voltage drm/amd/powerplay/hwmgr: prevent VDDC from exceeding 2V MAINTAINERS: Remove unneded wildcard for the Radeon/AMDGPU drivers drm/radeon: add cayman VM support for append packet. drm/amd/amdgpu: Add debugfs entries for smc/didt/pcie drm/amd/amdgpu: Drop print_status callbacks. drm/amd/powerplay: revise reading/writing pptable on Polaris10 drm/amd/powerplay: revise reading/writing pptable on Tonga drm/amd/powerplay: revise reading/writing pptable on Fiji drm/amd/powerplay: revise caching the soft pptable and add it's size drm/amd/powerplay: add dpm force multiple levels on cz/tonga/fiji/polaris (v2) drm/amd/powerplay: fix fan speed percent setting error on Polaris10 drm/amd/powerplay: fix bug dpm can't work when resume back on Polaris ... commit 73898db0430125606c86c798c0627aefef9af9ed Author: Haggai Abramovsky <hagaya@mellanox.com> Date: Wed May 4 14:50:15 2016 +0300 net/mlx4: Avoid wrong virtual mappings The dma_alloc_coherent() function returns a virtual address which can be used for coherent access to the underlying memory. On some architectures, like arm64, undefined behavior results if this memory is also accessed via virtual mappings that are not coherent. Because of their undefined nature, operations like virt_to_page() return garbage when passed virtual addresses obtained from dma_alloc_coherent(). Any subsequent mappings via vmap() of the garbage page values are unusable and result in bad things like bus errors (synchronous aborts in ARM64 speak). The mlx4 driver contains code that does the equivalent of: vmap(virt_to_page(dma_alloc_coherent)), this results in an OOPs when the device is opened. Prevent Ethernet driver to run this problematic code by forcing it to allocate contiguous memory. As for the Infiniband driver, at first we are trying to allocate contiguous memory, but in case of failure roll back to work with fragmented memory. Signed-off-by: Haggai Abramovsky <hagaya@mellanox.com> Signed-off-by: Yishai Hadas <yishaih@mellanox.com> Reported-by: David Daney <david.daney@cavium.com> Tested-by: Sinan Kaya <okaya@codeaurora.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/infiniband/hw/mlx4/qp.c | 27 +++++-- drivers/net/ethernet/mellanox/mlx4/alloc.c | 93 ++++++++++------------- drivers/net/ethernet/mellanox/mlx4/en_cq.c | 9 +-- drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 2 +- drivers/net/ethernet/mellanox/mlx4/en_resources.c | 31 -------- drivers/net/ethernet/mellanox/mlx4/en_rx.c | 11 +-- drivers/net/ethernet/mellanox/mlx4/en_tx.c | 14 +--- drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 2 - include/linux/mlx4/device.h | 4 +- 9 files changed, 68 insertions(+), 125 deletions(-) commit 816cd71b0c723a7296d14aadb8ff1ba42f6181d2 Author: Nicolai Stange <nicstange@gmail.com> Date: Thu May 5 22:43:04 2016 -0400 ext4: remove unmeetable inconsisteny check from ext4_find_extent() ext4_find_extent(), stripped down to the parts relevant to this patch, reads as ppos = 0; i = depth; while (i) { --i; ++ppos; if (unlikely(ppos > depth)) { ... ret = -EFSCORRUPTED; goto err; } } Due to the loop's bounds, the condition ppos > depth can never be met. Remove this dead code. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/extents.c | 7 ------- 1 file changed, 7 deletions(-) commit 466c3fb618b8520b75be37fcb115e9610663b945 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Thu May 5 22:35:54 2016 -0400 jbd2: remove excess descriptions for handle_s Commit bf6993276f74 ("jbd2: Use tracepoints for history file") removed the members j_history, j_history_max and j_history_cur from struct handle_s but the descriptions stayed lingering. Removing them. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Jan Kara <jack@suse.cz> include/linux/jbd2.h | 3 --- 1 file changed, 3 deletions(-) commit 32157de29a3140bfaa74c6e0fae18c78fe84a5df Author: Jens Axboe <axboe@fb.com> Date: Thu May 5 22:09:49 2016 -0400 ext4: remove unnecessary bio get/put ext4_io_submit() used to check for EOPNOTSUPP after bio submission, which is why it had to get an extra reference to the bio before submitting it. But since we no longer touch the bio after submission, get rid of the redundant get/put of the bio. If we do get the extra reference, we enter the slower path of having to flag this bio as now having external references. Signed-off-by: Jens Axboe <axboe@fb.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/page-io.c | 2 -- 1 file changed, 2 deletions(-) commit a94e3fbe4d53d4e512c4ea88a475e605b8d8dccb Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Apr 28 18:18:05 2016 -0700 nfit: add sysfs dimm 'family' and 'dsm_mask' attributes Communicate the command format and supported functions to userspace tooling. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 6634fb06906f52a3a3125e88681a7fa6e353f31d Author: Dan Williams <dan.j.williams@intel.com> Date: Wed Apr 27 16:46:15 2016 -0600 tools/testing/nvdimm: ND_CMD_CALL support Enable nfit_test to use nd_cmd_pkg marshaling. Signed-off-by: Dan Williams <dan.j.williams@intel.com> tools/testing/nvdimm/test/nfit.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) commit 87554098fec74a6c4a8cbea0d9adea2e8868e9e4 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Apr 28 18:01:20 2016 -0700 nfit: disable vendor specific commands Module option to limit userspace to the publicly defined command set. For cases where private DIMM commands may be interfering with the kernel's handling of DIMM state this option can be set to block vendor specific commands. Cc: Jerry Hoemann <jerry.hoemann@hpe.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit 04b3b779816502549e5f4bfaf5df90204ce2fe0e Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:43 2016 -0700 i40e/i40evf: Remove reference to ring->dtype As part of the rx-refactor, the dtype variable in the i40e_ring struct is no longer used, so remove it. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 8 ++------ drivers/net/ethernet/intel/i40e/i40e_txrx.h | 1 - drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 1 - 3 files changed, 2 insertions(+), 8 deletions(-) commit b32bfa17246d836125958e39996a674653e899a5 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:42 2016 -0700 i40e: Drop packet split receive routine As part of preparation for the rx-refactor, remove the packet split receive routine and ancillary code. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 3 - drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 4 +- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 19 -- drivers/net/ethernet/intel/i40e/i40e_main.c | 49 +---- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 245 +------------------------ drivers/net/ethernet/intel/i40e/i40e_txrx.h | 7 - 6 files changed, 10 insertions(+), 317 deletions(-) commit f8a952cb40407f3c127cab8ec77f1261f1e424b4 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Mon Apr 18 11:33:41 2016 -0700 i40e/i40evf: Refactor tunnel interpretation Refactor the interpretation of a tunnel. This removes some code and lets us start using the hardware's parsing. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 13 ++++++------- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 13 ++++++------- 2 files changed, 12 insertions(+), 14 deletions(-) commit 2cbaf5491cb7095252c72e74e79863b75ad2d8d0 Merge: abbbc60 666b656 Author: Brian Norris <computersforpeace@gmail.com> Date: Thu May 5 18:04:53 2016 -0700 Merge tag 'nand/for-4.7' of github.com:linux-nand/linux Updates from Boris Brezillon: This pull request contains the following infrastructure changes: * introduction of the ECC algo concept to extend the ECC mode one * replacement of the nand_ecclayout infrastructure by something more future-proof. * addition of an mtd-activity led trigger to replace the nand-activity one And a bunch of specific NAND driver improvements/fixes. Here are the changes that are worth mentioning: * rework of the OMAP GPMC and NAND drivers * prepare the sunxi NAND driver to receive DMA support * handle bitflips in erased pages on GPMI revisions that do not support this in hardware. * tag 'nand/for-4.7' of github.com:linux-nand/linux: (152 commits) mtd: brcmnand: respect ECC algorithm set by NAND subsystem gpmi-nand: Handle ECC Errors in erased pages Documentation: devicetree: deprecate "soft_bch" nand-ecc-mode value mtd: nand: add support for "nand-ecc-algo" DT property mtd: mtd: drop NAND_ECC_SOFT_BCH enum value mtd: drop support for NAND_ECC_SOFT_BCH as "soft_bch" mapping mtd: nand: read ECC algorithm from the new field mtd: nand: fsmc: validate ECC setup by checking algorithm directly mtd: nand: set ECC algorithm to Hamming on fallback staging: mt29f_spinand: set ECC algorithm explicitly CRIS v32: nand: set ECC algorithm explicitly mtd: nand: atmel: set ECC algorithm explicitly mtd: nand: davinci: set ECC algorithm explicitly mtd: nand: bf5xx: set ECC algorithm explicitly mtd: nand: omap2: Fix high memory dma prefetch transfer mtd: nand: omap2: Start dma request before enabling prefetch mtd: nandsim: add __init attribute mtd: nand: move of_get_nand_xxx() helpers into nand_base.c mtd: nand: sh_flctl: rely on generic DT parsing done in nand_scan_ident() mtd: nand: mxc: rely on generic DT parsing done in nand_scan_ident() ... commit 13f307711b127d30fcf333a04365a217baf9ca2b Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 3 10:24:31 2016 -0700 megaraid_sas: Downgrade two success messages to info I actually read the error messages in my logs, and successful initialization is not an error. Arguably these log lines could be deleted entirely. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Hannes Reinicke <hare@suse.de> Acked-by: Sumit Saxena <sumit.saxena@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/megaraid/megaraid_sas_base.c | 2 +- drivers/scsi/megaraid/megaraid_sas_fusion.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 635f6b0893cff193a1774881ebb1e4a4b9a7fead Author: Manoj N. Kumar <manoj@linux.vnet.ibm.com> Date: Tue May 3 11:27:34 2016 -0500 cxlflash: Fix to resolve dead-lock during EEH recovery When a cxlflash adapter goes into EEH recovery and multiple processes (each having established its own context) are active, the EEH recovery can hang if the processes attempt to recover in parallel. The symptom logged after a couple of minutes is: INFO: task eehd:48 blocked for more than 120 seconds. Not tainted 4.5.0-491-26f710d+ #1 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. eehd 0 48 2 Call Trace: __switch_to+0x2f0/0x410 __schedule+0x300/0x980 schedule+0x48/0xc0 rwsem_down_write_failed+0x294/0x410 down_write+0x88/0xb0 cxlflash_pci_error_detected+0x100/0x1c0 [cxlflash] cxl_vphb_error_detected+0x88/0x110 [cxl] cxl_pci_error_detected+0xb0/0x1d0 [cxl] eeh_report_error+0xbc/0x130 eeh_pe_dev_traverse+0x94/0x160 eeh_handle_normal_event+0x17c/0x450 eeh_handle_event+0x184/0x370 eeh_event_handler+0x1c8/0x1d0 kthread+0x110/0x130 ret_from_kernel_thread+0x5c/0xa4 INFO: task blockio:33215 blocked for more than 120 seconds. Not tainted 4.5.0-491-26f710d+ #1 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. blockio 0 33215 33213 Call Trace: 0x1 (unreliable) __switch_to+0x2f0/0x410 __schedule+0x300/0x980 schedule+0x48/0xc0 rwsem_down_read_failed+0x124/0x1d0 down_read+0x68/0x80 cxlflash_ioctl+0x70/0x6f0 [cxlflash] scsi_ioctl+0x3b0/0x4c0 sg_ioctl+0x960/0x1010 do_vfs_ioctl+0xd8/0x8c0 SyS_ioctl+0xd4/0xf0 system_call+0x38/0xb4 INFO: task eehd:48 blocked for more than 120 seconds. The hang is because of a 3 way dead-lock: Process A holds the recovery mutex, and waits for eehd to complete. Process B holds the semaphore and waits for the recovery mutex. eehd waits for semaphore. The fix is to have Process B above release the semaphore before attempting to acquire the recovery mutex. This will allow eehd to proceed to completion. Signed-off-by: Manoj N. Kumar <manoj@linux.vnet.ibm.com> Reviewed-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/cxlflash/superpipe.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit b6b85dad30ad7e7394990e2317a780577974a4e6 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 27 02:19:21 2016 +0000 perf evlist: Rename variable in perf_mmap__read() In perf_mmap__read(), give better names to pointers. Original name 'old' and 'head' directly related to pointers in ring buffer control page. For backward ring buffer, the meaning of 'head' point is not 'the first byte of free space', but 'the first byte of the last record'. To reduce confusion, rename 'old' to 'start', 'head' to 'end'. 'start' -> 'end' is the direction the records should be read from. Change parameter order. Change 'overwrite' to 'check_messup'. When reading from 'head', no need to check messup for for backward ring buffer. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461723563-67451-3-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) commit 0f4ccd11813f59d766039dfdd13aa98245a67294 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 27 02:19:20 2016 +0000 perf evlist: Extract perf_mmap__read() Extract event reader from perf_evlist__mmap_read() to perf__mmap_read(). Future commit will feed it with manually computed 'head' and 'old' pointers. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461723563-67451-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 39 ++++++++++++++++++++++++--------------- 1 file changed, 24 insertions(+), 15 deletions(-) commit 0b3c2264ae30ed692fd1ffd2b84c5fbdf737cb0d Author: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Date: Tue Apr 12 14:40:50 2016 +0530 perf symbols: Fix kallsyms perf test on ppc64le ppc64le functions have a Global Entry Point (GEP) and a Local Entry Point (LEP). While placing a probe, we always prefer the LEP since it catches function calls through both the GEP and the LEP. In order to do this, we fixup the function entry points during elf symbol table lookup to point to the LEPs. This works, but breaks 'perf test kallsyms' since the symbols loaded from the symbol table (pointing to the LEP) do not match the symbols in kallsyms. To fix this, we do not adjust all the symbols during symbol table load. Instead, we note down st_other in a newly introduced arch-specific member of perf symbol structure, and later use this to adjust the probe trace point. Reported-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Acked-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Cc: Mark Wielaard <mjw@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> Cc: linuxppc-dev@lists.ozlabs.org Link: http://lkml.kernel.org/r/6be7c2b17e370100c2f79dd444509df7929bdd3e.1460451721.git.naveen.n.rao@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/powerpc/util/sym-handling.c | 28 ++++++++++++++++++++-------- tools/perf/util/probe-event.c | 5 +++-- tools/perf/util/probe-event.h | 3 ++- tools/perf/util/symbol-elf.c | 7 ++++--- tools/perf/util/symbol.h | 3 ++- 5 files changed, 31 insertions(+), 15 deletions(-) commit 239aeba764092b29dd7cab177cd47f472390622e Author: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Date: Tue Apr 12 14:40:49 2016 +0530 perf powerpc: Fix kprobe and kretprobe handling with kallsyms on ppc64le So far, we used to treat probe point offsets as being offset from the LEP. However, userspace applications (objdump/readelf) always show disassembly and offsets from the function GEP. This is confusing to the user as we will end up probing at an address different from what the user expects when looking at the function disassembly with readelf/objdump. Fix this by changing how we modify probe address with perf. If only the function name is provided, we assume the user needs the LEP. Otherwise, if an offset is specified, we assume that the user knows the exact address to probe based on function disassembly, and so we just place the probe from the GEP offset. Finally, kretprobe was also broken with kallsyms as we were trying to specify an offset. This patch also fixes that issue. Reported-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Cc: Mark Wielaard <mjw@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> Cc: linuxppc-dev@lists.ozlabs.org Link: http://lkml.kernel.org/r/75df860aad8216bf4b9bcd10c6351ecc0e3dee54.1460451721.git.naveen.n.rao@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/powerpc/util/sym-handling.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) commit 7cecb7fe8388d5c39708d7f07e642ed31bb9d4fe Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:48 2016 +0200 perf hists: Move sort__has_comm into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_comm into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-8-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/ui/browsers/hists.c | 6 ++++-- tools/perf/util/hist.h | 1 + tools/perf/util/sort.c | 3 +-- tools/perf/util/sort.h | 1 - 4 files changed, 6 insertions(+), 5 deletions(-) commit fa82911a1bdf4f9870ffca097d7fe21128b5639c Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:47 2016 +0200 perf hists: Move sort__has_thread into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_thread into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-7-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/ui/browsers/hists.c | 12 ++++++------ tools/perf/util/hist.h | 1 + tools/perf/util/sort.c | 3 +-- tools/perf/util/sort.h | 1 - 4 files changed, 8 insertions(+), 9 deletions(-) commit 35a634f76c02b98d31397a589544022b478c0e12 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:46 2016 +0200 perf hists: Move sort__has_socket into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_socket into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-6-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-top.c | 2 +- tools/perf/ui/browsers/hists.c | 4 ++-- tools/perf/util/hist.h | 1 + tools/perf/util/sort.c | 3 +-- tools/perf/util/sort.h | 1 - 5 files changed, 5 insertions(+), 6 deletions(-) commit 69849fc5d2119799509026df7a6fd5ffe5a578b3 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:45 2016 +0200 perf hists: Move sort__has_dso into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_dso into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-5-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/ui/browsers/hists.c | 8 ++++---- tools/perf/util/hist.h | 1 + tools/perf/util/sort.c | 7 +++---- tools/perf/util/sort.h | 1 - 4 files changed, 8 insertions(+), 9 deletions(-) commit 2e0453af4e16e97268b9e66aad37beb607ed7c0f Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:44 2016 +0200 perf hists: Move sort__has_sym into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_sym into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-4-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-top.c | 4 ++-- tools/perf/ui/browsers/hists.c | 6 +++--- tools/perf/ui/gtk/hists.c | 2 +- tools/perf/ui/hist.c | 2 +- tools/perf/util/annotate.c | 2 +- tools/perf/util/hist.h | 1 + tools/perf/util/sort.c | 9 ++++----- tools/perf/util/sort.h | 1 - 8 files changed, 13 insertions(+), 14 deletions(-) commit de7e6a7c8bf9ee46dcbee749bc3cdd0d9c21998a Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:43 2016 +0200 perf hists: Move sort__has_parent into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__has_parent into struct perf_hpp_list. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-3-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-report.c | 2 +- tools/perf/util/callchain.c | 2 +- tools/perf/util/hist.h | 1 + tools/perf/util/machine.c | 2 +- tools/perf/util/sort.c | 5 ++--- tools/perf/util/sort.h | 1 - 6 files changed, 6 insertions(+), 7 deletions(-) commit 52225036fa8f5aca4c1b7b4f12742f72a1bf9d73 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue May 3 13:54:42 2016 +0200 perf hists: Move sort__need_collapse into struct perf_hpp_list Now we have sort dimensions private for struct hists, we need to make dimension booleans hists specific as well. Moving sort__need_collapse into struct perf_hpp_list. Adding hists__has macro to easily access this info perf struct hists object. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1462276488-26683-2-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-diff.c | 4 ++-- tools/perf/builtin-report.c | 2 +- tools/perf/builtin-top.c | 2 +- tools/perf/tests/hists_common.c | 2 +- tools/perf/tests/hists_cumulate.c | 2 +- tools/perf/tests/hists_link.c | 4 ++-- tools/perf/tests/hists_output.c | 2 +- tools/perf/util/hist.c | 14 +++++++------- tools/perf/util/hist.h | 4 ++++ tools/perf/util/sort.c | 5 ++--- tools/perf/util/sort.h | 1 - 11 files changed, 22 insertions(+), 20 deletions(-) commit 4679bccaa30893ccc5be35c5c5d44f5ab60c0a08 Author: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Date: Thu May 5 20:53:19 2016 +0530 perf tools powerpc: Add support for generating bpf prologue Generalize existing macros to serve the purpose. Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Cc: Ian Munsie <imunsie@au1.ibm.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Wang Nan <wangnan0@huawei.com> Cc: linuxppc-dev@lists.ozlabs.org Link: http://lkml.kernel.org/r/1462461799-17518-1-git-send-email-naveen.n.rao@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/powerpc/Makefile | 1 + tools/perf/arch/powerpc/util/dwarf-regs.c | 40 +++++++++++++++++++++---------- 2 files changed, 29 insertions(+), 12 deletions(-) commit 03548ebf6d8cc8a3a782121cf3e54ea41230e227 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 5 15:46:50 2016 -0300 perf trace: Do not show the runtime_ms for a thread when not collecting it That field is only updated when we use the "sched:sched_stat_runtime" tracepoint, and that is only done so far when we use the '--stat' command line option, without it we get just zeros, confusing the users: Without this patch: # trace -a -s sleep 1 <SNIP> qemu-system-x86 (9931), 468 events, 9.6%, 0.000 msec syscall calls total min avg max stddev (msec) (msec) (msec) (msec) (%) ---------- ------ --------- --------- --------- --------- ------ ppoll 98 982.374 0.000 10.024 29.983 12.65% write 34 0.401 0.005 0.012 0.027 5.49% ioctl 102 0.347 0.002 0.003 0.007 3.08% firefox (10871), 1856 events, 38.2%, 0.000 msec (msec) (msec) (msec) (msec) (%) ---------- ------ --------- --------- --------- --------- ------ poll 395 934.873 0.000 2.367 17.120 11.51% recvmsg 395 0.988 0.001 0.003 0.021 4.20% read 106 0.460 0.002 0.004 0.007 3.17% futex 24 0.108 0.001 0.004 0.010 10.05% mmap 2 0.041 0.016 0.021 0.026 23.92% write 6 0.027 0.004 0.004 0.005 2.52% After this patch that ', 0.000 msecs' gets suppressed when --stat is not in use. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-p7emqrsw7900tdkg43v9l1e1@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit b535d523dce58e8e94f7dbf741f1e9b5479e61d4 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed May 4 16:06:26 2016 -0300 perf trace: Sort syscalls stats by msecs in --summary # trace -a -s sleep 1 <SNIP> Xorg (1965), 788 events, 19.0%, 0.000 msec syscall calls total min avg max stddev (msec) (msec) (msec) (msec) (%) --------------- -------- --------- --------- --------- --------- ------ select 89 731.038 0.000 8.214 175.218 36.71% ioctl 22 0.661 0.010 0.030 0.072 10.43% writev 42 0.253 0.002 0.006 0.011 5.94% recvmsg 60 0.185 0.001 0.003 0.009 5.90% setitimer 60 0.127 0.001 0.002 0.006 6.14% read 52 0.102 0.001 0.002 0.005 8.55% rt_sigprocmask 45 0.092 0.001 0.002 0.023 23.65% poll 12 0.021 0.001 0.002 0.003 7.21% epoll_wait 12 0.019 0.001 0.002 0.002 2.71% firefox (10871), 1080 events, 26.1%, 0.000 msec syscall calls total min avg max stddev (msec) (msec) (msec) (msec) (%) --------------- -------- --------- --------- --------- --------- ------ poll 240 979.562 0.000 4.082 17.132 11.33% recvmsg 240 0.532 0.001 0.002 0.007 3.69% read 60 0.303 0.003 0.005 0.029 8.50% Suggested-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-52kdkuyxihq0kvc0n2aalhay@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) commit 96c144512263906cc41a25524fa114c90acd3a01 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed May 4 12:47:16 2016 -0300 perf trace: Sort summary output by number of events # trace -a -s sleep 1 |& grep events | tail gmain (1733), 34 events, 1.0%, 0.000 msec hexchat (9765), 46 events, 1.4%, 0.000 msec ssh (11109), 80 events, 2.4%, 0.000 msec sleep (32631), 81 events, 2.4%, 0.000 msec qemu-system-x86 (10021), 272 events, 8.2%, 0.000 msec Xorg (1965), 322 events, 9.7%, 0.000 msec SoftwareVsyncTh (10922), 366 events, 11.1%, 0.000 msec gnome-shell (2231), 446 events, 13.5%, 0.000 msec qemu-system-x86 (9931), 468 events, 14.1%, 0.000 msec firefox (10871), 1098 events, 33.2%, 0.000 msec [root@jouet ~]# Suggested-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ye4cnprhfeiq32ar4lt60dqs@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 49 ++++++++++++++++++++++++++-------------------- 1 file changed, 28 insertions(+), 21 deletions(-) commit f58c253564815db541e93b5411c2b47dbcb2f0ea Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu May 5 11:44:28 2016 -0300 perf tools: Add template for generating rbtree resort class Sometimes we want to sort an existing rbtree by a different key, introduce a template for that, that needs only to be provided the rbtree root and the number of entries in it. To do that a new rbtree will be created with extra space for each entry, where possibly pre-calculated keys will be stored to be used in the resort process and also later, when using the newly sorted rbtree. Please check the following two changesets to see it in use for resorting stats for threads and its syscalls in 'perf trace --summary'. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-9l6e1q34lmf3wwdeewstyakg@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/rb_resort.h | 149 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) commit d2c11034406733374d1cdc588c53bb076d95a4e2 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed May 4 10:09:33 2016 -0300 perf machine: Introduce number of threads member To be used, for instance, for pre-allocating an rb_tree array for sorting by other keys besides the current pid one. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ja0ifkwue7ttjhbwijn6g6eu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/machine.c | 7 ++++++- tools/perf/util/machine.h | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) commit 935244cd54b86ca46e69bc6604d2adfb1aec2d42 Author: Nicolai Stange <nicstange@gmail.com> Date: Thu May 5 19:46:19 2016 -0400 ext4: silence UBSAN in ext4_mb_init() Currently, in ext4_mb_init(), there's a loop like the following: do { ... offset += 1 << (sb->s_blocksize_bits - i); i++; } while (i <= sb->s_blocksize_bits + 1); Note that the updated offset is used in the loop's next iteration only. However, at the last iteration, that is at i == sb->s_blocksize_bits + 1, the shift count becomes equal to (unsigned)-1 > 31 (c.f. C99 6.5.7(3)) and UBSAN reports UBSAN: Undefined behaviour in fs/ext4/mballoc.c:2621:15 shift exponent 4294967295 is too large for 32-bit type 'int' [...] Call Trace: [<ffffffff818c4d25>] dump_stack+0xbc/0x117 [<ffffffff818c4c69>] ? _atomic_dec_and_lock+0x169/0x169 [<ffffffff819411ab>] ubsan_epilogue+0xd/0x4e [<ffffffff81941cac>] __ubsan_handle_shift_out_of_bounds+0x1fb/0x254 [<ffffffff81941ab1>] ? __ubsan_handle_load_invalid_value+0x158/0x158 [<ffffffff814b6dc1>] ? kmem_cache_alloc+0x101/0x390 [<ffffffff816fc13b>] ? ext4_mb_init+0x13b/0xfd0 [<ffffffff814293c7>] ? create_cache+0x57/0x1f0 [<ffffffff8142948a>] ? create_cache+0x11a/0x1f0 [<ffffffff821c2168>] ? mutex_lock+0x38/0x60 [<ffffffff821c23ab>] ? mutex_unlock+0x1b/0x50 [<ffffffff814c26ab>] ? put_online_mems+0x5b/0xc0 [<ffffffff81429677>] ? kmem_cache_create+0x117/0x2c0 [<ffffffff816fcc49>] ext4_mb_init+0xc49/0xfd0 [...] Observe that the mentioned shift exponent, 4294967295, equals (unsigned)-1. Unless compilers start to do some fancy transformations (which at least GCC 6.0.0 doesn't currently do), the issue is of cosmetic nature only: the such calculated value of offset is never used again. Silence UBSAN by introducing another variable, offset_incr, holding the next increment to apply to offset and adjust that one by right shifting it by one position per loop iteration. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=114701 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=112161 Cc: stable@vger.kernel.org Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/mballoc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit d1ce3bb95511dacf8b9eea899c421f1b18a3ef6a Merge: 93d6884 878a872 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Fri May 6 01:41:06 2016 +0200 Merge back new ACPICA material for v4.7. commit ddd9357f6017a8c61a20685feab5ce9eee635f6c Author: Lawrence Yiu <lawyiu.dev@gmail.com> Date: Mon Mar 21 01:44:22 2016 -0700 sony-laptop: Avoid oops on module unload for older laptops Older VAIO laptops without the SN00 ACPI method will have the "handles" variable unset. Return early from sony_nc_function_cleanup when "handles" is null. Signed-off-by: Lawrence Yiu <lawyiu.dev@gmail.com> Acked-by: Mattia Dongili <malattia@linux.it> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/sony-laptop.c | 3 +++ 1 file changed, 3 insertions(+) commit a6926cc989eb8e3349ae9b858177608e86f7257c Merge: 0250abc c2316db Author: James Morris <james.l.morris@oracle.com> Date: Fri May 6 09:31:34 2016 +1000 Merge branch 'stable-4.7' of git://git.infradead.org/users/pcmoore/selinux into next commit 0250abcd726b4eba8a6175f09656fe544ed6491a Merge: 74f430c d55201c Author: James Morris <james.l.morris@oracle.com> Date: Fri May 6 09:29:00 2016 +1000 Merge tag 'keys-next-20160505' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs into next commit 6b4e941875ca464e0bf737d7cdc9b72b008df6eb Author: Nishanth Menon <nm@ti.com> Date: Thu May 5 15:33:37 2016 -0700 ARM: dts: omap5-board-common: Describe the voltage supply mapping accurately OMAP5uEVM based platforms share a similar voltage rail map. This should be properly described in device tree, without this regulator core will be unable to determine the source voltage of LDOs such as LDO9 and SMPS10 which could be configured for bypass depending on the voltage requested of them. This results in conditions such as: ldo9: bypassed regulator has no supply! ldo9: failed to get the current voltage(-517) palmas-pmic 48070000.i2c:palmas@48:palmas_pmic: failed to register 48070000.i2c:palmas@48:palmas_pmic regulator Cc: Agustí Fontquerni <af@iseebcn.com> Cc: Eduard Gavin <egavin@iseebcn.com> Cc: Enric Balletbo i Serra <eballetbo@iseebcn.com> Cc: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> [tony@atomide.com: fixed to use palmas style in-supply] Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-board-common.dtsi | 43 +++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 666b65683dad9aa90efaa4aad24ef3710101e3aa Author: Brian Norris <computersforpeace@gmail.com> Date: Mon Apr 25 22:53:55 2016 -0700 mtd: brcmnand: respect ECC algorithm set by NAND subsystem This is more obvious than guessing based on ECC strength. It allows using NAND on devices with BCH-1 (e.g. D-Link DIR-885L). This maintains DT backward compatibility by defaulting to Hamming if a 1-bit ECC algorithm is specified without a corresponding algorithm selection. i.e., to use BCH-1, you must specify: nand-ecc-strength = <1>; nand-ecc-step-size = <512>; nand-ecc-algo = "bch"; Also adds a check to ensure we haven't allowed someone to get by with SW ECC. If we want to support SW ECC, we need to refactor some other pieces of this driver. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Tested-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/brcmnand/brcmnand.c | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) commit bd2e778c9ee361c23ccb2b10591712e129d97893 Author: Markus Pargmann <mpa@pengutronix.de> Date: Mon Apr 25 14:35:12 2016 +0200 gpmi-nand: Handle ECC Errors in erased pages ECC is only calculated for written pages. As erased pages are not actively written the ECC is always invalid. For this purpose the Hardware BCH unit is able to check for erased pages and does not raise an ECC error in this case. This behaviour can be influenced using the BCH_MODE register which sets the number of allowed bitflips in an erased page. Unfortunately the unit is not capable of fixing the bitflips in memory. To avoid complete software checks for erased pages, we can simply check buffers with uncorrectable ECC errors because we know that any erased page with errors is uncorrectable by the BCH unit. This patch adds the generic nand_check_erased_ecc_chunk() to gpmi-nand to correct erased pages. To have the valid data in the buffer before using them, this patch moves the read_page_swap_end() call before the ECC status checking for-loop. Signed-off-by: Markus Pargmann <mpa@pengutronix.de> [Squashed patches by Stefan and Boris to check ECC area] Tested-by: Stefan Christ <s.christ@phytec.de> Acked-by: Han xu <han.xu@nxp.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 78 +++++++++++++++++++++++++++++++--- 1 file changed, 73 insertions(+), 5 deletions(-) commit 32698aafc9f0c6373b240f15a91fefb65c55907c Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 22 13:23:14 2016 +0200 Documentation: devicetree: deprecate "soft_bch" nand-ecc-mode value Now that we support nand-ecc-algo property it should be used together with "soft" to specify software BCH ECC. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Documentation/devicetree/bindings/mtd/nand.txt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit ba4f46b28f87396d3270d05d8d0e08467471b7fb Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 22 13:23:13 2016 +0200 mtd: nand: add support for "nand-ecc-algo" DT property So far it was only possible to specify ECC algorithm using "soft" and "soft_bch" values of nand-ecc-mode prop. There wasn't a way to specify it for a hardware ECC mode. Now that we have independent field in NAND subsystem for storing info about ECC algorithm we may also add support for this new DT property. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Documentation/devicetree/bindings/mtd/nand.txt | 2 ++ drivers/mtd/nand/nand_base.c | 20 +++++++++++++------- 2 files changed, 15 insertions(+), 7 deletions(-) commit e4225ae8234cf5548c38dc887b233ad1d45b4d53 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:07 2016 +0200 mtd: mtd: drop NAND_ECC_SOFT_BCH enum value This value should not be part of nand_ecc_modes_t as it specifies algorithm not a mode. We successfully managed to introduce new "algo" field which is respected now. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsmc_nand.c | 3 +-- drivers/mtd/nand/jz4780_nand.c | 1 - drivers/mtd/nand/mxc_nand.c | 1 - drivers/mtd/nand/nand_base.c | 11 +++-------- drivers/mtd/nand/nandsim.c | 2 +- drivers/mtd/nand/sunxi_nand.c | 2 -- include/linux/mtd/nand.h | 1 - 7 files changed, 5 insertions(+), 16 deletions(-) commit ae211bcfa1d013bea16912e7caebb1367740d4b4 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:06 2016 +0200 mtd: drop support for NAND_ECC_SOFT_BCH as "soft_bch" mapping There isn't any difference between handling NAND_ECC_SOFT and NAND_ECC_SOFT_BCH now. What matters is the new field called "algo". Please note we're keeping backward DT compatibility. We are still treating "soft_bch" value as the one setting Hamming algorithm, it's just handled in of_get_nand_ecc_algo now. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 06f384c9010ea7fa1146b9dfdd419d99c9b8a962 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:05 2016 +0200 mtd: nand: read ECC algorithm from the new field Now we have all drivers properly setting this new field we can start using it. For a very short period of time we should support both values: NAND_ECC_SOFT and NAND_ECC_SOFT_BCH treating them the same. It's because of_get_nand_ecc_mode may still be setting NAND_ECC_SOFT_BCH. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 146 +++++++++++++++++++++++++------------------ 1 file changed, 85 insertions(+), 61 deletions(-) commit ef296dc947f6a9300a7fb5b696d1e1f543479e18 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:04 2016 +0200 mtd: nand: fsmc: validate ECC setup by checking algorithm directly NAND core sets ECC algorithm in algo field now and it should be preferred over the mode field. This also prepares driver for dropping NAND_ECC_SOFT_BCH. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsmc_nand.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit e9d4faed71d5a63fa0ef8fcfef559f67f8b85a22 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:02 2016 +0200 mtd: nand: set ECC algorithm to Hamming on fallback This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 1 + 1 file changed, 1 insertion(+) commit cc71538fab2f5470775b060c59eddafe8ffa2674 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:01 2016 +0200 staging: mt29f_spinand: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/staging/mt29f_spinand/mt29f_spinand.c | 1 + 1 file changed, 1 insertion(+) commit 40438a1ea7fb8326daffa692dbf41a5c60bbf3da Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:53:00 2016 +0200 CRIS v32: nand: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Mikael Starvik <starvik@axis.com> Acked-by: Jesper Nilsson <jesper.nilsson@axis.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> arch/cris/arch-v32/drivers/mach-a3/nandflash.c | 1 + arch/cris/arch-v32/drivers/mach-fs/nandflash.c | 1 + 2 files changed, 2 insertions(+) commit d5f304ac6aff1462ddf3c14f48e2b849ab68d5a3 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:52:59 2016 +0200 mtd: nand: atmel: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/atmel_nand.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 867f9873fef69414355e2e1ef547f9b080c3fd69 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:52:58 2016 +0200 mtd: nand: davinci: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/davinci_nand.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 04dae62c89bd6e754518f9dcffac480e39f28758 Author: Rafał Miłecki <zajec5@gmail.com> Date: Sun Apr 17 22:52:57 2016 +0200 mtd: nand: bf5xx: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/bf5xx_nand.c | 1 + 1 file changed, 1 insertion(+) commit 8c6f0fc4d2d505b17fc67675f0797fe3fc6e6c26 Author: Cooper Jr., Franklin <fcooper@ti.com> Date: Fri Apr 15 15:28:59 2016 -0500 mtd: nand: omap2: Fix high memory dma prefetch transfer Based on DMA documentation and testing using high memory buffer when doing dma transfers can lead to various issues including kernel panics. To workaround this simply use cpu copy. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit 03d3a1df6da660999d8f14552ac4d875e94090a3 Author: Cooper Jr., Franklin <fcooper@ti.com> Date: Fri Apr 15 15:28:58 2016 -0500 mtd: nand: omap2: Start dma request before enabling prefetch The prefetch engine sends a dma request once a FIFO threshold has been met. No other requests are received until the previous request is handled. Starting a dma transfer (dma_async_issue_pending) results in any previous event for the dma channel to be cleared. Therefore, starting the prefetch engine before initiating the dma transfer may result in the prefetch triggering a dma request but instead of it being handled it can end up being cleared. This will result in a hang since the code will continue to wait for the dma request to complete. By initiating the dma request before enabling the prefetch engine this race condition is avoided and no dma request are missed/cleared. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 7778478501938e071d40eeadb5d7d01770ce799f Author: Julia Lawall <julia.lawall@lip6.fr> Date: Tue Apr 19 14:33:35 2016 +0200 mtd: nandsim: add __init attribute Add __init attribute on functions that are only called from other __init functions and that are not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the functions are put in the .text.unlikely segment. Declaring them as __init will cause them to be put in the .init.text and to disappear after initialization. The result of objdump -x on the functions before the change is as follows: 000000000000059a l F .text.unlikely 0000000000000239 alloc_device 000000000000034e l F .text.unlikely 000000000000002e get_partition_name 00000000000007d3 l F .text.unlikely 00000000000005da init_nandsim And after the change it is as follows: 0000000000000029 l F .init.text 0000000000000234 alloc_device 0000000000000000 l F .init.text 0000000000000029 get_partition_name 000000000000025d l F .init.text 00000000000005d5 init_nandsim Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nandsim.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d48f62b9a0a035d6c16de4a4dae315f7332a8939 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:32 2016 +0200 mtd: nand: move of_get_nand_xxx() helpers into nand_base.c Now that all drivers go through nand_set_flash_node() to parse the generic NAND properties, we can move all of_get_nand_xxx() helpers in to nand_base.c, make them static and remove of_mtd.c and of_mtd.h. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 94 +++++++++++++++++++++++++- drivers/of/Makefile | 1 - drivers/of/of_mtd.c | 155 ------------------------------------------- include/linux/of_mtd.h | 56 ---------------- 4 files changed, 93 insertions(+), 213 deletions(-) commit 14667d8d586f93cd1514dfcfe85aeda41dc47142 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:31 2016 +0200 mtd: nand: sh_flctl: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sh_flctl.c | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) commit 609468f94883c7840b9b22ec0ee9674513363d9e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:29 2016 +0200 mtd: nand: mxc: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/mxc_nand.c | 45 +++++++++++++++++++++++---------------------- 1 file changed, 23 insertions(+), 22 deletions(-) commit f6c36aaa3b6828fe2720fbdae70b58e6c0cccae6 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:28 2016 +0200 mtd: nand: lpc32xx: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/lpc32xx_slc.c | 25 +++++++++---------------- 1 file changed, 9 insertions(+), 16 deletions(-) commit 2d01922c11601bed642e5a3d1c7051685218d0fc Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:27 2016 +0200 mtd: nand: hisi504: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/hisi504_nand.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 363b5db21284b3f44866eaee5d2d34c3c9963f7d Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:25 2016 +0200 mtd: nand: davinci: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/davinci_nand.c | 83 +++++++++++++++++++---------------------- 1 file changed, 38 insertions(+), 45 deletions(-) commit f05f6a10fb2ef4aa7ebec75696a162f3110861a0 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:26 2016 +0200 mtd: nand: gpmi: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Han xu <han.xu@nxp.com> drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit 57a605b101bbdff6a388e8dcb4853db9ffe947f7 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Thu Apr 14 08:54:30 2016 +0200 mtd: nand: omap2: fix compare_const_fl.cocci warnings Move constants to the right of binary operators. Generated by: scripts/coccinelle/misc/compare_const_fl.cocci CC: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 99fec60aad7a5520effbaadd3bbbe8001e9242eb Author: Maarten ter Huurne <maarten@treewalker.org> Date: Mon Apr 18 18:04:56 2016 +0200 mtd: nand: jz4740: Remove unused local variable Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Acked-by: Harvey Hunt <harvey.hunt@imgtec.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/jz4740_nand.c | 1 - 1 file changed, 1 deletion(-) commit e99b0d9865949e1bb41d1462427e200a6f9eb973 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:07:02 2016 +0200 mtd: nand: fsl_elbc: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_elbc_nand.c | 1 + 1 file changed, 1 insertion(+) commit ff1ef3501fae2fd92f4f1132fd27182507a749ec Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:07:01 2016 +0200 mtd: nand: fsl_ifc: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_ifc_nand.c | 1 + 1 file changed, 1 insertion(+) commit ab2f5a809871dead7237a86c962d83e2f7b12e8d Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:07:00 2016 +0200 mtd: nand: fsl_upm: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_upm.c | 1 + 1 file changed, 1 insertion(+) commit d9944e1fdcd6c363a24577ac64c6d1128152ff6d Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:59 2016 +0200 mtd: nand: cmx270: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/cmx270_nand.c | 1 + 1 file changed, 1 insertion(+) commit 7079e7ed4a4e8b74a7dc3feafc0e70cc027cab32 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:58 2016 +0200 mtd: nand: mpc5121_nfc: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/mpc5121_nfc.c | 1 + 1 file changed, 1 insertion(+) commit c2ec6b30a521691b752ac61ee05267133a389834 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:57 2016 +0200 mtd: nand: au1550nd: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/au1550nd.c | 1 + 1 file changed, 1 insertion(+) commit e020cc05915e11bad3a923b52458baa2daac53cc Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:56 2016 +0200 mtd: nand: sh_flctl: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sh_flctl.c | 1 + 1 file changed, 1 insertion(+) commit c4fe72a733c7749ab2c05e51bd37393525a86e2c Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:55 2016 +0200 mtd: nand: s3c2410: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/s3c2410.c | 1 + 1 file changed, 1 insertion(+) commit d7b83b8a6dda3edada04f9395e2ef6463e099277 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 14:06:54 2016 +0200 mtd: nand: omap2: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 1 + 1 file changed, 1 insertion(+) commit aab616e31d1c7ec3726f7f5cbdaaec98759ebe93 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Feb 4 10:16:18 2016 +0100 mtd: kill the nand_ecclayout struct Now that all MTD drivers have moved to the mtd_ooblayout_ops model we can safely remove the struct nand_ecclayout definition, and all the remaining places where it was still used. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/mtdchar.c | 12 ++--- drivers/mtd/mtdcore.c | 117 --------------------------------------------- include/linux/mtd/mtd.h | 20 -------- include/uapi/mtd/mtd-abi.h | 2 +- 4 files changed, 7 insertions(+), 144 deletions(-) commit 7f2b092c9eeda055ae60af194a8edacaea5f7a10 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:24:10 2016 +0100 mtd: nand: kill the ecc->layout field Now that all NAND drivers have switched to mtd_ooblayout_ops, we can kill the ecc->layout field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 7 ------- drivers/mtd/nand/nand_bch.c | 8 -------- include/linux/mtd/nand.h | 2 -- 3 files changed, 17 deletions(-) commit e1d132b4ae3b5dfc897cf117419404b22caf6892 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:13:39 2016 +0100 staging: mt29f_spinand: switch to mtd_ooblayout_ops Replace the nand_ecclayout definition by the equivalent mtd_ooblayout_ops definition. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/staging/mt29f_spinand/mt29f_spinand.c | 48 +++++++++++++++++---------- 1 file changed, 30 insertions(+), 18 deletions(-) commit a411679fb5fd7ee2df64a55c23c81538ceeb6d06 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Mon Dec 7 22:46:45 2015 +0100 mtd: onenand: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Modify the onenand drivers to switch to this approach. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/onenand/onenand_base.c | 162 ++++++++++++++++++++++--------------- include/linux/mtd/onenand.h | 2 - 2 files changed, 97 insertions(+), 67 deletions(-) commit 421e81c4c6c03a5f6cbc40ea208fb07ad5797e09 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 18 17:54:27 2016 +0100 mtd: nand: qcom: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Archit Taneja <architt@codeaurora.org> drivers/mtd/nand/qcom_nandc.c | 79 +++++++++++++++++++------------------------ 1 file changed, 34 insertions(+), 45 deletions(-) commit 3cf32d180227c1a1f5e017c997085d52a10a106f Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:05:45 2016 +0100 mtd: nand: vf610: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Stefan Agner <stefan@agner.ch> Acked-by: Stefan Agner <stefan@agner.ch> drivers/mtd/nand/vf610_nfc.c | 34 ++++------------------------------ 1 file changed, 4 insertions(+), 30 deletions(-) commit c66811e6d350dda53624d1bb4a15698a375b9e79 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:05:13 2016 +0100 mtd: nand: sunxi: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 114 +++++++++++++++++++----------------------- 1 file changed, 52 insertions(+), 62 deletions(-) commit 987b913c2b7e440e9784724d138cdaf8440f34c6 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:04:59 2016 +0100 mtd: nand: sm_common: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sm_common.c | 93 ++++++++++++++++++++++++++++++++++++-------- 1 file changed, 77 insertions(+), 16 deletions(-) commit e7049f298ecc39f6917d72542effabab64c2bce8 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:03:47 2016 +0100 mtd: nand: sh_flctl: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sh_flctl.c | 87 ++++++++++++++++++++++++++++++++++----------- 1 file changed, 67 insertions(+), 20 deletions(-) commit bf01e06b32c6cb4b1a08d03434b4559974656669 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:03:30 2016 +0100 mtd: nand: s3c2410: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/s3c2410.c | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) commit 39980c5616d6a4723143e258550f2844e0138d36 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:03:18 2016 +0100 mtd: nand: pxa3xx: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/pxa3xx_nand.c | 104 +++++++++++++++++++++++++---------------- 1 file changed, 64 insertions(+), 40 deletions(-) commit e04dbf352820245b54f74200ac97327959f02c56 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:03:04 2016 +0100 mtd: nand: omap2: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 202 ++++++++++++++++++++++++++++------------------- 1 file changed, 121 insertions(+), 81 deletions(-) commit a894cf6c5a82c7ddcb1bad82d1e0af3d0ead9a41 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:02:54 2016 +0100 mtd: nand: mxc: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/mxc_nand.c | 212 ++++++++++++++++++++++---------------------- 1 file changed, 105 insertions(+), 107 deletions(-) commit d50b5239867f02627fc24c4450a87bd9c3267c0a Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:02:41 2016 +0100 mtd: nand: lpc32xx: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/lpc32xx_mlc.c | 50 ++++++++++++++++++++++++++++-------------- drivers/mtd/nand/lpc32xx_slc.c | 41 +++++++++++++++++++++++++++------- 2 files changed, 66 insertions(+), 25 deletions(-) commit 36886be7dd3b48f593d9da21c631d06d5bfae55d Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:02:22 2016 +0100 mtd: nand: jz4780: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Harvey Hunt <harvey.hunt@imgtec.com> drivers/mtd/nand/jz4780_nand.c | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) commit 2ca9ec9acd3bea9f3160e0e0975c06914da3ae4e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:02:09 2016 +0100 mtd: nand: hisi504: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/hisi504_nand.c | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) commit 3f158e47dfe92ee53f1e09c5fa76a07116100f02 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:01:54 2016 +0100 mtd: nand: gpmi: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Han Xu <han.xu@nxp.com> Tested-by: Han Xu <han.xu@nxp.com> drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 52 ++++++++++++++++++++++++++-------- 1 file changed, 40 insertions(+), 12 deletions(-) commit 04a123a99f089773fc6ee6e21af5f831d87fe362 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Feb 9 15:01:21 2016 +0100 mtd: nand: fsmc: get rid of the fsmc_nand_eccplace struct Now that mtd_ooblayout_ecc() returns the ECC byte position using the OOB free method, we can get rid of the fsmc_nand_eccplace struct. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsmc_nand.c | 60 +++++++++++--------------------------------- include/linux/mtd/fsmc.h | 18 ------------- 2 files changed, 15 insertions(+), 63 deletions(-) commit 22b469577625056e76b7ddb670eea3dc69210eb6 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:01:42 2016 +0100 mtd: nand: fsmc: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsmc_nand.c | 298 ++++++++++++------------------------------- 1 file changed, 82 insertions(+), 216 deletions(-) commit caf5129e93c510d8f3306f894988e52a8369c766 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Feb 9 17:01:57 2016 +0100 mtd: nand: fsl_ifc: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_ifc_nand.c | 230 ++++++++++++---------------------------- 1 file changed, 66 insertions(+), 164 deletions(-) commit c2e197b0198c753e9a17557d16be79bf910525a2 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:01:04 2016 +0100 mtd: nand: fsl_elbc: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_elbc_nand.c | 83 +++++++++++++++++++++++----------------- 1 file changed, 47 insertions(+), 36 deletions(-) commit 6b75065e0d8ca46f98984b5dc30e9a07e7c9a475 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:00:35 2016 +0100 mtd: nand: docg4: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/docg4.c | 33 ++++++++++++++++++++++++++++----- 1 file changed, 28 insertions(+), 5 deletions(-) commit 68c1b754822b01153359d77bcee94b9a423d5bb8 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:00:23 2016 +0100 mtd: nand: diskonchip: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/diskonchip.c | 60 ++++++++++++++++++++++++++++++++----------- 1 file changed, 45 insertions(+), 15 deletions(-) commit 14fad62b688fefd2dc032e98968d4f4a69adefe9 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:00:11 2016 +0100 mtd: nand: denali: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/denali.c | 50 +++++++++++++++++++++++++++++++++-------------- 1 file changed, 35 insertions(+), 15 deletions(-) commit e4aacaa1b175cd53db0c6c7f033bb0fe02df6ea5 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:59:58 2016 +0100 mtd: nand: davinci: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/davinci_nand.c | 118 +++++++++++++++------------------------- 1 file changed, 44 insertions(+), 74 deletions(-) commit a8ed6e66f3b04d804fae425023aa4e7615dadab7 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:59:47 2016 +0100 mtd: nand: cafe: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/cafe_nand.c | 44 ++++++++++++++++++++++++++++++++------------ 1 file changed, 32 insertions(+), 12 deletions(-) commit ef5eeea6e911540bbf51a283fe0ffb7389cbe66a Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:59:36 2016 +0100 mtd: nand: brcm: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/brcmnand/brcmnand.c | 258 +++++++++++++++++++++-------------- 1 file changed, 157 insertions(+), 101 deletions(-) commit c8766e81ca3a224b092d087f6e1d77bf2c3d665d Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:59:25 2016 +0100 mtd: nand: bf5xx: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/bf5xx_nand.c | 51 ++++++++++++++++++++++++------------------- 1 file changed, 28 insertions(+), 23 deletions(-) commit cc00383722db7a4b75e005f5bb8b08b4d874ed00 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:59:11 2016 +0100 mtd: nand: atmel: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/mtd/nand/atmel_nand.c | 84 ++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 46 deletions(-) commit 50533187eed5ace8d06e0e04aeea8fea1b70b8d7 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:58:55 2016 +0100 mtd: nand: jz4740: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Lars-Peter Clausen <lars@metafoo.de> arch/mips/include/asm/mach-jz4740/jz4740_nand.h | 2 +- arch/mips/jz4740/board-qi_lb60.c | 87 +++++++++++++++---------- drivers/mtd/nand/jz4740_nand.c | 2 +- 3 files changed, 53 insertions(+), 38 deletions(-) commit e5b2d30e42e66122c9b1b17529df743bc938c041 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:58:11 2016 +0100 mtd: nand: sharpsl: switch to mtd_ooblayout_ops Implementing the mtd_ooblayout_ops interface is the new way of exposing ECC/OOB layout to MTD users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> arch/arm/mach-pxa/spitz.c | 55 ++++++++++++++++++++++++++++++++++++--------- drivers/mtd/nand/sharpsl.c | 2 +- include/linux/mtd/sharpsl.h | 2 +- 3 files changed, 47 insertions(+), 12 deletions(-) commit 7cf9c19a836a79c60deef63714cb2880246d9a85 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:53:40 2016 +0100 mtd: nand: bch: switch to mtd_ooblayout_ops Replace the nand_ecclayout definition by the equivalent mtd_ooblayout_ops definition. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 15 +++++++++++++++ drivers/mtd/nand/nand_bch.c | 41 +++++++++++------------------------------ 2 files changed, 26 insertions(+), 30 deletions(-) commit b5cb316cdf3a3f5f6125412b0f6065185240cfdc Author: Nicolai Stange <nicstange@gmail.com> Date: Thu May 5 17:38:03 2016 -0400 ext4: address UBSAN warning in mb_find_order_for_block() Currently, in mb_find_order_for_block(), there's a loop like the following: while (order <= e4b->bd_blkbits + 1) { ... bb += 1 << (e4b->bd_blkbits - order); } Note that the updated bb is used in the loop's next iteration only. However, at the last iteration, that is at order == e4b->bd_blkbits + 1, the shift count becomes negative (c.f. C99 6.5.7(3)) and UBSAN reports UBSAN: Undefined behaviour in fs/ext4/mballoc.c:1281:11 shift exponent -1 is negative [...] Call Trace: [<ffffffff818c4d35>] dump_stack+0xbc/0x117 [<ffffffff818c4c79>] ? _atomic_dec_and_lock+0x169/0x169 [<ffffffff819411bb>] ubsan_epilogue+0xd/0x4e [<ffffffff81941cbc>] __ubsan_handle_shift_out_of_bounds+0x1fb/0x254 [<ffffffff81941ac1>] ? __ubsan_handle_load_invalid_value+0x158/0x158 [<ffffffff816e93a0>] ? ext4_mb_generate_from_pa+0x590/0x590 [<ffffffff816502c8>] ? ext4_read_block_bitmap_nowait+0x598/0xe80 [<ffffffff816e7b7e>] mb_find_order_for_block+0x1ce/0x240 [...] Unless compilers start to do some fancy transformations (which at least GCC 6.0.0 doesn't currently do), the issue is of cosmetic nature only: the such calculated value of bb is never used again. Silence UBSAN by introducing another variable, bb_incr, holding the next increment to apply to bb and adjust that one by right shifting it by one position per loop iteration. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=114701 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=112161 Cc: stable@vger.kernel.org Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/mballoc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 775d054aba90a2c787d4c081d6369f1fddaae0f4 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 22:11:59 2016 +0200 intel_telemetry: Constify telemetry_core_ops structures The telemetry_core_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Darren Hart <dvhart@linux.intel.com> arch/x86/include/asm/intel_telemetry.h | 2 +- drivers/platform/x86/intel_telemetry_core.c | 6 +++--- drivers/platform/x86/intel_telemetry_pltdrv.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) commit 575b245d9047d190c8cbc44e2f0ef14897836292 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Tue Apr 26 18:28:17 2016 -0400 fujitsu-laptop: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/fujitsu-laptop.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 94d7f1a255db84233a2da70b27d9abf9c0a57135 Merge: ccea5f0 d35cf74 6973627 Author: Doug Ledford <dledford@redhat.com> Date: Thu May 5 16:42:09 2016 -0400 Merge branches 'hfi1' and 'iw_cxgb4' into k.o/for-4.7 commit 6973627968acbdf7d6f45a4c4813d46bf8e2a66a Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:37 2016 +0530 RDMA/iw_cxgb4: remove abort_connection() usage from ep_timeout() Use c4iw_ep_disconnect() instead. This is part of getting rid of abort_connection() altogether so we properly clean up on send_abort() failures. This is the last user of abort_connection(), so remove it too. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit c00dcbafac39760f567350ce0c1cef1e4bb28a64 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:36 2016 +0530 RDMA/iw_cxgb4: move QP -> ERROR on fatal disconnect errors In c4iw_ep_disconnect(), if we fail to initiate a close operation, then move the qp to ERROR to disassociate the ep from the qp. Failure to do this will leak the ep resources. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit fd6aabe48c8f76d31aacb55fc6c90af770632ae2 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:35 2016 +0530 RDMA/iw_cxgb4: don't use abort_connection in process_mpa_request() Instead return whether the caller needs to disconnect. This is part of getting rid of abort_connection() altogether so we properly clean up on send_abort() failures. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 64 ++++++++++++++++++++++------------------ 1 file changed, 35 insertions(+), 29 deletions(-) commit eaf4c6d46a6948302b64be2b7149cce22131ee0d Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:34 2016 +0530 RDMA/iw_cxgb4: remove abort_connection() usage from accept/reject Use c4iw_ep_disconnect() instead. This is part of getting rid of abort_connection() altogether so we properly clean up on send_abort() failures. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) commit fef4422d00c135da4300d7d58e62cd0afe2af730 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:33 2016 +0530 RDMA/iw_cxgb4: free resources when send_flowc() fails Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) commit f8e1e1d13773e1bcad127cbb5be964d00ee1f682 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:32 2016 +0530 RDMA/iw_cxgb4: remove connection abort from process_mpa_reply Instead, have the caller, rx_data() handle the close/abort like it does for process_mpa_request(). This is part of getting rid of abort_connection() altogether so we properly clean up on send_abort() failures. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit 6e410d8f7175caf2316c515f1ea0bf80d33b3158 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:31 2016 +0530 RDMA/iw_cxgb4: ensure eps don't get freed while the mutex is held In rx_data(), with the ep in FPDU_MODE, refcnt=2, if we get unexpected streaming data, we call c4iw_modify_rc_qp() and move the qp from RTS -> TERMINATE. In c4iw_modify_rc_qp(), if rdma_fini() returns an error, the ep will be dereferenced (refcnt=1). Then rx_data() calls c4iw_ep_disconnect() which starts the close operation. But if send_halfclose() fails in c4iw_ep_disconnect(), we will call release_ep_resources() derefing the ep which reduces the refcnt to 0 and and frees the ep. However we still has the ep mutex at that point, so we have a touch-after-free bug. There is a similar issue where peer_close() calls c4iw_ep_disconnect(). The solution is to add a reference to the ep in c4iw_ep_disconnect() after acquiring the mutex, and release it after releasing the mutex. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 88bc230dc614b8e19000022d0ae2c1dfd578a0b0 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:30 2016 +0530 RDMA/iw_cxgb4: stop ep timer on close failure In c4iw_ep_disconnect(), if we start the ep timer to begin a close, but send_halfclose() fails, we need to stop the timer and send a CLOSE event up to the IWCM before releasing the resources. Otherwise, we can crash when the ep timer fires if the ep is referencing a previous instance of the device. This can happen as part of adapter reset/recovery, for instance. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 9dec900c20d95ef1f3c40bc5d5901499f5d63381 Author: Hariprasad S <hariprasad@chelsio.com> Date: Thu May 5 01:27:29 2016 +0530 RDMA/iw_cxgb4: release ep resources on accept arp failure If ARP fails before the CPL_PASS_ACCEPT_RPL is seen by hardware, the tid will be stuck in SYN_PEND and never released. So create an arp failure handler specifically for this message to release the endpoint resources. In pass_accept_rpl_arp_failure(), put the parent endpoint so it will be freed when destroyed. Also we don't need to call release_tid() here because _c4iw_free_ep() calls cxgb4_remove_tid() which releases the hwtid. If we get an ABORT_REQ_RSS instead of a PASS_ESTABLISH (because the peer's ACK to our SYN is never received), then put the parent as well in peer_abort(). Treat accept_cr() failures just like arp failures: put the parent ep and release the ep resources destroying the tid The ARP failure handlers are called in an atomic context, so we need to schedule some of the processing which might block. Namely _c4iw_free_ep() which needs a mutex. So create a "special" CPL opcode and handler and schedule it via sched() to be run by process_work() in a blockable context. Also rework the active open arp failure handler to make use of release_ep_resources(). This allows both the active and passive arp failure handlers to use the same deferred cleanup function. Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/cxgb4/cm.c | 82 ++++++++++++++++++++++++++++++++-------- 1 file changed, 66 insertions(+), 16 deletions(-) commit 72f6d8d8c9b3592da7109cad3415559864ee9f2d Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 28 15:24:03 2016 +0200 dm ioctl: drop use of __GFP_REPEAT in copy_params()'s __vmalloc() call copy_params()'s use of __GFP_REPEAT for the __vmalloc() call doesn't make much sense because vmalloc doesn't rely on costly high order allocations. Signed-off-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 52813d4046851ceab56ad6d09291e4fce00d1a0c Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:03 2016 +0100 dm stats: fix spelling mistake in Documentation Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Mike Snitzer <snitzer@redhat.com> Documentation/device-mapper/statistics.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 492d48db8db0f89fb8f2cf7d31d22221cd9194e7 Author: Mike Snitzer <snitzer@redhat.com> Date: Wed Apr 20 21:11:25 2016 -0400 dm cache: update cache-policies.txt now that mq is an alias for smq Also fix some typos and make all "smq" and "mq" references consistently lowercase. Signed-off-by: Mike Snitzer <snitzer@redhat.com> Documentation/device-mapper/cache-policies.txt | 34 ++++++++++++-------------- 1 file changed, 16 insertions(+), 18 deletions(-) commit 2da1610ae20e995e53658c3b10166d2ad74e30bd Author: Mike Snitzer <snitzer@redhat.com> Date: Thu Mar 17 18:38:17 2016 -0400 dm mpath: eliminate use of spinlock in IO fast-paths The primary motivation of this commit is to improve the scalability of DM multipath on large NUMA systems where m->lock spinlock contention has been proven to be a serious bottleneck on really fast storage. The ability to atomically read a pointer, using lockless_dereference(), is leveraged in this commit. But all pointer writes are still protected by the m->lock spinlock (which is fine since these all now occur in the slow-path). The following functions no longer require the m->lock spinlock in their fast-path: multipath_busy(), __multipath_map(), and do_end_io() And choose_pgpath() is modified to _not_ update m->current_pgpath unless it also switches the path-group. This is done to avoid needing to take the m->lock everytime __multipath_map() calls choose_pgpath(). But m->current_pgpath will be reset if it is failed via fail_path(). Suggested-by: Jeff Moyer <jmoyer@redhat.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-mpath.c | 170 +++++++++++++++++++++++++++----------------------- 1 file changed, 93 insertions(+), 77 deletions(-) commit 20800cb3450ee44ec1827d7e8bbfd5a9dc02e6cd Author: Mike Snitzer <snitzer@redhat.com> Date: Thu Mar 17 17:13:10 2016 -0400 dm mpath: move trigger_event member to the end of 'struct multipath' Allows the 'work_mutex' member to no longer cross a cacheline. Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-mpath.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 91e968aa6015d7366281b532dad2e48855b91fe3 Author: Mike Snitzer <snitzer@redhat.com> Date: Thu Mar 17 17:10:15 2016 -0400 dm mpath: use atomic_t for counting members of 'struct multipath' The use of atomic_t for nr_valid_paths, pg_init_in_progress and pg_init_count will allow relaxing the use of the m->lock spinlock. Suggested-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-mpath.c | 61 ++++++++++++++++++++++++++++----------------------- 1 file changed, 33 insertions(+), 28 deletions(-) commit 518257b13276d07a19e6ae0608b8e5ee73383ce4 Author: Mike Snitzer <snitzer@redhat.com> Date: Thu Mar 17 16:32:10 2016 -0400 dm mpath: switch to using bitops for state flags Mechanical change that doesn't make any real effort to reduce the use of m->lock; that will come later (once atomics are used for counters, etc). Suggested-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-mpath.c | 131 +++++++++++++++++++++++++++++--------------------- 1 file changed, 75 insertions(+), 56 deletions(-) commit 813923b1a21b73f3068d89b817a86bea5371108c Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Mon Apr 11 11:37:08 2016 +0530 dm thin: Remove return statement from void function Return statement at the end of a void function is useless. The Coccinelle semantic patch used to make this change is as follows: //<smpl> @@ identifier f; expression e; @@ void f(...) { <... - return e; ...> } //</smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm-thin.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cfae7529b525c3fa86deb71cf2036659240a865e Author: Mike Snitzer <snitzer@redhat.com> Date: Mon Apr 11 12:05:38 2016 -0400 dm: remove unused mapped_device argument from free_tio() Signed-off-by: Mike Snitzer <snitzer@redhat.com> drivers/md/dm.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit ef1d88ced108df7d652cf3f514b920e661826b71 Merge: 04974df 0ef5a50 Author: Mike Snitzer <snitzer@redhat.com> Date: Thu May 5 15:21:14 2016 -0400 Merge remote-tracking branch 'jens/for-4.7/core' into dm-4.7 Needed in order to update the DM thinp code to use the new async __blkdev_issue_discard() interface. commit 0ef5a50c1658d4d96a44f145bcb92ff3310c75b1 Author: Mike Snitzer <snitzer@redhat.com> Date: Thu May 5 11:54:22 2016 -0400 block: make bio_inc_remaining() interface accessible again Commit 326e1dbb57 ("block: remove management of bi_remaining when restoring original bi_end_io") made bio_inc_remaining() private to bio.c because the only use-case that made sense was confined to the bio_chain() interface. Since that time DM thinp went on to use bio_chain() in its relatively complex implementation of async discard support. That implementation, even when converted over to use the new async __blkdev_issue_discard() interface, depends on deferred completion of the original discard bio -- which is most appropriately implemented using bio_inc_remaining(). DM thinp foolishly duplicated bio_inc_remaining(), local to dm-thin.c as __bio_inc_remaining(), so re-exporting bio_inc_remaining() allows us to put an end to that foolishness. All said, bio_inc_remaining() should really only be used in conjunction with bio_chain(). It isn't intended for generic bio reference counting. Signed-off-by: Mike Snitzer <snitzer@redhat.com> Acked-by: Joe Thornber <ejt@redhat.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/bio.c | 11 ----------- include/linux/bio.h | 11 +++++++++++ 2 files changed, 11 insertions(+), 11 deletions(-) commit bbd848e0fade51ae51dab86a0683069cef89953f Author: Mike Snitzer <snitzer@redhat.com> Date: Thu May 5 11:54:21 2016 -0400 block: reinstate early return of -EOPNOTSUPP from blkdev_issue_discard Commit 38f25255330 ("block: add __blkdev_issue_discard") incorrectly disallowed the early return of -EOPNOTSUPP if the device doesn't support discard (or secure discard). This early return of -EOPNOTSUPP has always been part of blkdev_issue_discard() interface so there isn't a good reason to break that behaviour -- especially when it can be easily reinstated. The nuance of allowing early return of -EOPNOTSUPP vs disallowing late return of -EOPNOTSUPP is: if the overall device never advertised support for discards and one is issued to the device it is beneficial to inform the caller that discards are not supported via -EOPNOTSUPP. But if a device advertises discard support it means that at least a subset of the device does have discard support -- but it could be that discards issued to some regions of a stacked device will not be supported. In that case the late return of -EOPNOTSUPP must be disallowed. Fixes: 38f25255330 ("block: add __blkdev_issue_discard") Signed-off-by: Mike Snitzer <snitzer@redhat.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-lib.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 6427a840ff6aeaac36c59872b0b4b2040ed26c9b Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Tue Apr 26 09:11:13 2016 +0100 ARM: 8567/1: cache-uniphier: activate ways for secondary CPUs This outer cache allows to control active ways independently for each CPU, but currently nothing is done for secondary CPUs. In other words, all the ways are locked for secondary CPUs by default. This commit fixes it to fully bring out the performance of this outer cache. There would be two possible ways to achieve this: [1] Each CPU initializes active ways for itself. This can be done via the SSCLPDAWCR register. This is a banked register, so each CPU sees a different instance of the register for its own. [2] The master CPU initializes active ways for all the CPUs. This is available via SSCDAWCARMR(N) registers, where all instances of SSCLPDAWCR are mirrored. They are mapped at the address SSCDAWCARMR + 4 * N, where N is the CPU number. The outer cache frame work does not support a per-CPU init callback. So this commit adopts [2]; the master CPU iterates over possible CPUs setting up SSCDAWCARMR(N) registers. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/mm/cache-uniphier.c | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) commit 7274a69cd86f61602a49a3d0b64d29b465f46a15 Author: Brad Mouring <brad.mouring@ni.com> Date: Wed May 4 19:35:25 2016 +0100 ARM: 8570/2: Documentation: devicetree: Add PL310 PM bindings Document the DT bindings for controlling ARM PL310 Power Control settings. Discussion on the binding wording: http://archive.arm.linux.org.uk/lurker/message/20160427.143444.5141d302.en.html Signed-off-by: Brad Mouring <brad.mouring@ni.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Documentation/devicetree/bindings/arm/l2c2x0.txt | 6 ++++++ 1 file changed, 6 insertions(+) commit 204932dfc87c236fc4fea8e6e4f03123853ea633 Author: Brad Mouring <brad.mouring@ni.com> Date: Thu Apr 28 17:00:52 2016 +0100 ARM: 8569/1: pl2x0: Add OF control of cache power management Add ability to override power management bits of 310 controllers (dynamic clock gating and standby mode) through OF entries. As the saved register is only applied when working on a supported controller, it is safe to save the settings. In order to maintain existing behavior, if the settings are not found in the DT, the corresponding feature will be enabled. Signed-off-by: Brad Mouring <brad.mouring@ni.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/mm/cache-l2x0.c | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) commit 953efb2b86cfdad340965222389122cc81cba76e Author: Jisheng Zhang <jszhang@marvell.com> Date: Thu Apr 28 09:52:44 2016 +0100 ARM: 8568/1: reboot: remove duplicated local_irq_disable() Once entering machine_halt() and machine_restart(), local_irq_disable() is called, and local irq is kept disabled, so the local_irq_disable() at the end of these two functions are not necessary, remove it. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/kernel/reboot.c | 3 --- 1 file changed, 3 deletions(-) commit a41980f2a3eb33ed7a2636e83498b47e95ceb05b Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Thu Apr 21 07:58:35 2016 +0100 ARM: 8566/1: drivers: amba: properly handle devices with power domains To read pid/cid registers, the probed device need to be properly turned on. When it is inside a power domain, the bus code should ensure that the given power domain is enabled before trying to access device's registers. However in some cases power domain (or clocks) might not be yet available. Returning -EPROBE_DEFER is not a solution in such case, because callers don't handle this special error code. Instead such devices are added to the special list and their registration is retried from periodic worker until all resources are available. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> drivers/amba/bus.c | 100 +++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 90 insertions(+), 10 deletions(-) commit 787ca32dc704bde981760de01a3a7e6ce9835fdb Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Wed May 4 12:17:50 2016 +0100 ia64/unaligned: Silence another GCC warning about an uninitialised variable arch/ia64/kernel/unaligned.c: In function 'ia64_handle_unaligned': arch/ia64/kernel/unaligned.c:1385:16: warning: 'u.l' may be used uninitialized in this function [-Wmaybe-uninitialized] opcode = (u.l >> IA64_OPCODE_SHIFT) & IA64_OPCODE_MASK; ^ Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/kernel/unaligned.c | 1 + 1 file changed, 1 insertion(+) commit f6184df02067afb366a543a19a03bec42223afb3 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Wed May 4 12:17:49 2016 +0100 ia64/traps: Silence GCC warning about uninitialised variable arch/ia64/kernel/traps.c: In function 'ia64_fault': arch/ia64/kernel/traps.c:433:17: warning: 'siginfo.si_code' may be used uninitialized in this function [-Wmaybe-uninitialized] struct siginfo siginfo; Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Bjorn Helgaas <helgaas@kernel.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/kernel/traps.c | 1 + 1 file changed, 1 insertion(+) commit 0b184a30d0df12f8366ce74bb9a5af2cff1fd3e3 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Wed May 4 12:17:48 2016 +0100 ia64: Reduce stack usage by iterating over nodemask GCC complains about sn2_global_tlb_purge() because of the large stack required by the function, arch/ia64/sn/kernel/sn2/sn2_smp.c: In function 'sn2_global_tlb_purge': arch/ia64/sn/kernel/sn2/sn2_smp.c:319:1: warning: the frame size of 2176 bytes is larger than 2048 bytes [-Wframe-larger-than=] 2048 bytes of the stack are consumed by the node ID array 'nasids[]'. But we don't actually need to put the ID array on the stack and can use nodemask operations. Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Bjorn Helgaas <helgaas@kernel.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/sn/kernel/sn2/sn2_smp.c | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) commit 1bba3ff90842cf55313a64a8a22e6cca0b3fdcb7 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Wed May 4 12:17:47 2016 +0100 ia64/PCI: Remove unused 'addr' and fix build warning Ever since commit 240504adaf07 ("ia64/PCI: Keep CPU physical (not virtual) addresses in shadow ROM resource") 'addr' has been unused, resulting in the following compiler warning, arch/ia64/sn/kernel/io_acpi_init.c: In function 'sn_acpi_slot_fixup': arch/ia64/sn/kernel/io_acpi_init.c:429:16: warning: unused variable 'addr' [-Wunused-variable] void __iomem *addr; ^ Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Bjorn Helgaas <helgaas@kernel.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/sn/kernel/io_acpi_init.c | 1 - 1 file changed, 1 deletion(-) commit 18c25526c9cd4041e8e5acba811cffa606c175b7 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Wed May 4 12:17:46 2016 +0100 ia64/PCI: Fix incorrect PCI resource end address commit f976721e826e ("ia64/PCI: Use ioremap() instead of open-coded equivalent") introduced the following compiler warning, arch/ia64/sn/kernel/io_init.c: In function 'sn_io_slot_fixup': arch/ia64/sn/kernel/io_init.c:189:19: warning: 'addr' may be used uninitialized in this function [-Wmaybe-uninitialized] res->end = addr + size; ^ 'addr' is indeed uninitialised and the correct value to use is res->start. Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Bjorn Helgaas <helgaas@kernel.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/sn/kernel/io_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2c80661d2ea9bac9bc7ba519097745829add1871 Author: Stefan Agner <stefan@agner.ch> Date: Mon Feb 8 12:50:13 2016 -0800 drm/fsl-dcu: use bus_flags for pixel clock polarity The drivers current default configuration drives the pixel data on rising edge of the pixel clock. However, most display sample data on rising edge... This leads to color shift artefacts visible especially at edges. This patch changes the relevant defines to be useful and actually set the bits, and changes pixel clock polarity to drive the pixel data on falling edge by default. The patch also adds an explicit pixel clock polarity flag to the display introduced with the driver (NEC WQVGA "nec,nl4827hc19-05b") using the new bus_flags field to retain the initial behavior. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_crtc.c | 5 +++++ drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.h | 4 ++-- drivers/gpu/drm/panel/panel-simple.c | 3 ++- 3 files changed, 9 insertions(+), 3 deletions(-) commit f0aa08387b92e432166d7143993da2635c8821e8 Author: Stefan Agner <stefan@agner.ch> Date: Mon Feb 8 11:38:14 2016 -0800 drm: introduce bus_flags in drm_display_info Introduce bus_flags to specify display bus properties like signal polarities. This is useful for parallel display buses, e.g. to specify the pixel clock or data enable polarity. Suggested-by: Thierry Reding <thierry.reding@gmail.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Manfred Schlaegl <manfred.schlaegl@gmx.at> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/panel/panel-simple.c | 2 ++ include/drm/drm_crtc.h | 9 +++++++++ 2 files changed, 11 insertions(+) commit c286b3f9600b2ddc573208792d947e1a251c6b15 Author: Jeeja KP <jeeja.kp@intel.com> Date: Thu May 5 11:19:19 2016 +0530 ASoC: Intel: Skylake: Fix memory leak in nhlt init During skl_nhlt_init(), acpi obj pointer is allocated and never freed and remap address is not unmapped. To fix this we should release the ACPI obj and also unmap the nhlt address during cleanup of driver. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-nhlt.c | 15 +++++++++------ sound/soc/intel/skylake/skl.c | 5 ++++- sound/soc/intel/skylake/skl.h | 6 +++--- 3 files changed, 16 insertions(+), 10 deletions(-) commit 8ea416748bb04b7a778cb8d2fd5ec7fa51b9d521 Author: Jeeja KP <jeeja.kp@intel.com> Date: Thu May 5 11:19:18 2016 +0530 ASoC: topology: Fix memory leak in widget creation name and sname allocated in widget create are not freed when creation is successful, so free them. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/soc-topology.c | 2 ++ 1 file changed, 2 insertions(+) commit 4d2458507d0b465c62ae80f3e81b8c008ec96b05 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed May 4 19:33:59 2016 -0300 ASoC: fsl_sai: Allow setting the SAI MCLK direction On mx6ul the General Purpose Register 1 (GPR1) contains the following bits for configuring the direction of the SAI MCLKs: SAI1_MCLK_DIR, SAI2_MCLK_DIR, SAI3_MCLK_DIR Introduce the "fsl,sai-mclk-direction-output" optional property to allow configuring the SAI_MCLK outputs. Tested on a imx6ul-evk board. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Nicolin Chen <nicoleotsuka@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/sound/fsl-sai.txt | 5 +++++ include/linux/mfd/syscon/imx6q-iomuxc-gpr.h | 6 ++++++ sound/soc/fsl/fsl_sai.c | 20 ++++++++++++++++++++ 3 files changed, 31 insertions(+) commit 1593af62b694b3638edf577e3b763fa1a4ca3d76 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed May 4 19:33:58 2016 -0300 ASoC: fsl_sai: Introduce a compatible string for MX6UL MX6UL may need to configure the General Purpose Register 1 (GPR1), so it is better to add a new compatible string to differentiate. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Nicolin Chen <nicoleotsuka@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/sound/fsl-sai.txt | 4 ++-- sound/soc/fsl/fsl_sai.c | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) commit 9d9b7eed59eb847c229225e6465fc2ead9971902 Author: Christoph Hellwig <hch@lst.de> Date: Thu May 5 16:41:05 2016 +0200 irqchip/alpine-msi: Don't use <asm-generic/msi.h> Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: marc.zyngier@arm.com Cc: antoine.tenart@free-electrons.com Cc: jason@lakedaemon.net Cc: tsahee@annapurnalabs.com Link: http://lkml.kernel.org/r/1462459265-20974-1-git-send-email-hch@lst.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de> drivers/irqchip/irq-alpine-msi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 74177f55b70e2f2be770dd28684dd6d17106a4ba Author: Jan Kara <jack@suse.cz> Date: Thu May 5 11:10:15 2016 -0400 ext4: fix oops on corrupted filesystem When filesystem is corrupted in the right way, it can happen ext4_mark_iloc_dirty() in ext4_orphan_add() returns error and we subsequently remove inode from the in-memory orphan list. However this deletion is done with list_del(&EXT4_I(inode)->i_orphan) and thus we leave i_orphan list_head with a stale content. Later we can look at this content causing list corruption, oops, or other issues. The reported trace looked like: WARNING: CPU: 0 PID: 46 at lib/list_debug.c:53 __list_del_entry+0x6b/0x100() list_del corruption, 0000000061c1d6e0->next is LIST_POISON1 0000000000100100) CPU: 0 PID: 46 Comm: ext4.exe Not tainted 4.1.0-rc4+ #250 Stack: 60462947 62219960 602ede24 62219960 602ede24 603ca293 622198f0 602f02eb 62219950 6002c12c 62219900 601b4d6b Call Trace: [<6005769c>] ? vprintk_emit+0x2dc/0x5c0 [<602ede24>] ? printk+0x0/0x94 [<600190bc>] show_stack+0xdc/0x1a0 [<602ede24>] ? printk+0x0/0x94 [<602ede24>] ? printk+0x0/0x94 [<602f02eb>] dump_stack+0x2a/0x2c [<6002c12c>] warn_slowpath_common+0x9c/0xf0 [<601b4d6b>] ? __list_del_entry+0x6b/0x100 [<6002c254>] warn_slowpath_fmt+0x94/0xa0 [<602f4d09>] ? __mutex_lock_slowpath+0x239/0x3a0 [<6002c1c0>] ? warn_slowpath_fmt+0x0/0xa0 [<60023ebf>] ? set_signals+0x3f/0x50 [<600a205a>] ? kmem_cache_free+0x10a/0x180 [<602f4e88>] ? mutex_lock+0x18/0x30 [<601b4d6b>] __list_del_entry+0x6b/0x100 [<601177ec>] ext4_orphan_del+0x22c/0x2f0 [<6012f27c>] ? __ext4_journal_start_sb+0x2c/0xa0 [<6010b973>] ? ext4_truncate+0x383/0x390 [<6010bc8b>] ext4_write_begin+0x30b/0x4b0 [<6001bb50>] ? copy_from_user+0x0/0xb0 [<601aa840>] ? iov_iter_fault_in_readable+0xa0/0xc0 [<60072c4f>] generic_perform_write+0xaf/0x1e0 [<600c4166>] ? file_update_time+0x46/0x110 [<60072f0f>] __generic_file_write_iter+0x18f/0x1b0 [<6010030f>] ext4_file_write_iter+0x15f/0x470 [<60094e10>] ? unlink_file_vma+0x0/0x70 [<6009b180>] ? unlink_anon_vmas+0x0/0x260 [<6008f169>] ? free_pgtables+0xb9/0x100 [<600a6030>] __vfs_write+0xb0/0x130 [<600a61d5>] vfs_write+0xa5/0x170 [<600a63d6>] SyS_write+0x56/0xe0 [<6029fcb0>] ? __libc_waitpid+0x0/0xa0 [<6001b698>] handle_syscall+0x68/0x90 [<6002633d>] userspace+0x4fd/0x600 [<6002274f>] ? save_registers+0x1f/0x40 [<60028bd7>] ? arch_prctl+0x177/0x1b0 [<60017bd5>] fork_handler+0x85/0x90 Fix the problem by using list_del_init() as we always should with i_orphan list. CC: stable@vger.kernel.org Reported-by: Vegard Nossum <vegard.nossum@oracle.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/namei.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ff0bc08454917964291f72ee5b8eca66de4bc250 Author: Seth Forshee <seth.forshee@canonical.com> Date: Thu May 5 10:52:38 2016 -0400 ext4: fix check of dqget() return value in ext4_ioctl_setproject() A failed call to dqget() returns an ERR_PTR() and not null. Fix the check in ext4_ioctl_setproject() to handle this correctly. Fixes: 9b7365fc1c82 ("ext4: add FS_IOC_FSSETXATTR/FS_IOC_FSGETXATTR interface support") Cc: stable@vger.kernel.org # v4.5 Signed-off-by: Seth Forshee <seth.forshee@canonical.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Jan Kara <jack@suse.cz> fs/ext4/ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cb39ad8b8ef224c544074962780bf763077d6141 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Wed May 4 17:49:53 2016 +0200 netfilter: nf_tables: allow set names up to 32 bytes Currently, we support set names of up to 16 bytes, get this aligned with the maximum length we can use in ipset to make it easier when considering migration to nf_tables. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_tables.h | 2 +- include/uapi/linux/netfilter/nf_tables.h | 1 + net/netfilter/nf_tables_api.c | 6 +++--- 3 files changed, 5 insertions(+), 4 deletions(-) commit d7cdf81657776ca1aa8377fd84d02fd8774db483 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue May 3 13:54:23 2016 +0200 netfilter: x_tables: get rid of old and inconsistent debugging The dprintf() and duprintf() functions are enabled at compile time, these days we have better runtime debugging through pr_debug() and static keys. On top of this, this debugging is so old that I don't expect anyone using this anymore, so let's get rid of this. IP_NF_ASSERT() is still left in place, although this needs that NETFILTER_DEBUG is enabled, I think these assertions provide useful context information when reading the code. Note that ARP_NF_ASSERT() has been removed as there is no user of this. Kill also DEBUG_ALLOW_ALL and a couple of pr_error() and pr_debug() spots that are inconsistently placed in the code. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 217 ++++++----------------------------- net/ipv4/netfilter/ip_tables.c | 244 +++++++--------------------------------- net/ipv6/netfilter/ip6_tables.c | 229 +++++++------------------------------ 3 files changed, 117 insertions(+), 573 deletions(-) commit 3b78155b1b3688dbe910fecdc3e003f431b46630 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue May 3 11:13:29 2016 +0200 openvswitch: __nf_ct_l{3,4}proto_find() always return a valid pointer If the protocol is not natively supported, this assigns generic protocol tracker so we can always assume a valid pointer after these calls. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Acked-by: Jarno Rajahalme <jrajahalme@nicira.com> Acked-by: Joe Stringer <joe@ovn.org> net/openvswitch/conntrack.c | 8 -------- 1 file changed, 8 deletions(-) commit 71d8c47fc653711c41bc3282e5b0e605b3727956 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Sun May 1 00:28:40 2016 +0200 netfilter: conntrack: introduce clash resolution on insertion race This patch introduces nf_ct_resolve_clash() to resolve race condition on conntrack insertions. This is particularly a problem for connection-less protocols such as UDP, with no initial handshake. Two or more packets may race to insert the entry resulting in packet drops. Another problematic scenario are packets enqueued to userspace via NFQUEUE after the raw table, that make it easier to trigger this race. To resolve this, the idea is to reset the conntrack entry to the one that won race. Packet and bytes counters are also merged. The 'insert_failed' stats still accounts for this situation, after this patch, the drop counter is bumped whenever we drop packets, so we can watch for unresolved clashes. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_l4proto.h | 3 ++ net/netfilter/nf_conntrack_core.c | 53 ++++++++++++++++++++++++++-- net/netfilter/nf_conntrack_proto_udp.c | 2 ++ net/netfilter/nf_conntrack_proto_udplite.c | 2 ++ 4 files changed, 57 insertions(+), 3 deletions(-) commit ba76738c032ec0af3acbecd85c429c6a5c9e5e5e Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Mon May 2 21:28:57 2016 +0200 netfilter: conntrack: introduce nf_ct_acct_update() Introduce a helper function to update conntrack counters. __nf_ct_kill_acct() was unnecessarily subtracting skb_network_offset() that is expected to be zero from the ipv4/ipv6 hooks. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 42 ++++++++++++++++++--------------------- 1 file changed, 19 insertions(+), 23 deletions(-) commit 4b4ceb9dbf6a549682edff9fc5f04c204da50ab9 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Sun May 1 00:34:37 2016 +0200 netfilter: conntrack: __nf_ct_l4proto_find() always returns valid pointer Remove unnecessary check for non-nul pointer in destroy_conntrack() given that __nf_ct_l4proto_find() returns the generic protocol tracker if the protocol is not supported. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3e86638e9a0be8bcf7db007909d8307b8b9f8e3b Author: Florian Westphal <fw@strlen.de> Date: Mon May 2 18:40:14 2016 +0200 netfilter: conntrack: consider ct netns in early_drop logic When iterating, skip conntrack entries living in a different netns. We could ignore netns and kill some other non-assured one, but it has two problems: - a netns can kill non-assured conntracks in other namespace - we would start to 'over-subscribe' the affected/overlimit netns. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 43 +++++++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 18 deletions(-) commit 56d52d4892d0e478a005b99ed10d0a7f488ea8c1 Author: Florian Westphal <fw@strlen.de> Date: Mon May 2 18:39:55 2016 +0200 netfilter: conntrack: use a single hashtable for all namespaces We already include netns address in the hash and compare the netns pointers during lookup, so even if namespaces have overlapping addresses entries will be spread across the table. Assuming 64k bucket size, this change saves 0.5 mbyte per namespace on a 64bit system. NAT bysrc and expectation hash is still per namespace, those will changed too soon. Future patch will also make conntrack object slab cache global again. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_core.h | 1 + include/net/netns/conntrack.h | 2 - net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c | 2 +- .../netfilter/nf_conntrack_l3proto_ipv4_compat.c | 10 ++- net/netfilter/nf_conntrack_core.c | 80 +++++++++++----------- net/netfilter/nf_conntrack_helper.c | 6 +- net/netfilter/nf_conntrack_netlink.c | 8 +-- net/netfilter/nf_conntrack_standalone.c | 13 ++-- net/netfilter/nf_nat_core.c | 2 +- net/netfilter/nfnetlink_cttimeout.c | 6 +- 10 files changed, 62 insertions(+), 68 deletions(-) commit 1b8c8a9f648c809c01a44114d7535ac8ca4c5ba3 Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 00:25:58 2016 +0200 netfilter: conntrack: make netns address part of hash Once we place all conntracks into a global hash table we want them to be spread across entire hash table, even if namespaces have overlapping ip addresses. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) commit e0c7d47221883966d930fa7335b3ca295bc316b2 Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:45 2016 +0200 netfilter: conntrack: check netns when comparing conntrack objects Once we place all conntracks in the same hash table we must also compare the netns pointer to skip conntracks that belong to a different namespace. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> .../netfilter/nf_conntrack_l3proto_ipv4_compat.c | 8 ++++++-- net/netfilter/nf_conntrack_core.c | 23 ++++++++++++---------- net/netfilter/nf_conntrack_netlink.c | 3 +++ 3 files changed, 22 insertions(+), 12 deletions(-) commit 245cfdcaba2e7e4ee16b12af547ead37f9c501cd Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:44 2016 +0200 netfilter: conntrack: small refactoring of conntrack seq_printf The iteration process is lockless, so we test if the conntrack object is eligible for printing (e.g. is AF_INET) after obtaining the reference count. Once we put all conntracks into same hash table we might see more entries that need to be skipped. So add a helper and first perform the test in a lockless fashion for fast skip. Once we obtain the reference count, just repeat the check. Note that this refactoring also includes a missing check for unconfirmed conntrack entries due to slab rcu object re-usage, so they need to be skipped since they are not part of the listing. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> .../netfilter/nf_conntrack_l3proto_ipv4_compat.c | 24 +++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) commit 868043485ecb7cda503af0dfb9e2804e0260196a Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:43 2016 +0200 netfilter: conntrack: use nf_ct_key_equal() in more places This prepares for upcoming change that places all conntracks into a single, global table. For this to work we will need to also compare net pointer during lookup. To avoid open-coding such check use the nf_ct_key_equal helper and then later extend it to also consider net_eq. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 29 +++++++++++------------------ 1 file changed, 11 insertions(+), 18 deletions(-) commit 88b68bc5237c84c6ff6f78568653780869a94a95 Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:42 2016 +0200 netfilter: conntrack: don't attempt to iterate over empty table Once we place all conntracks into same table iteration becomes more costly because the table contains conntracks that we are not interested in (belonging to other netns). So don't bother scanning if the current namespace has no entries. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 3 +++ 1 file changed, 3 insertions(+) commit 5e3c61f981756361e7dc74e2c673121028449e35 Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:41 2016 +0200 netfilter: conntrack: fix lookup race during hash resize When resizing the conntrack hash table at runtime via echo 42 > /sys/module/nf_conntrack/parameters/hashsize, we are racing with the conntrack lookup path -- reads can happen in parallel and nothing prevents readers from observing a the newly allocated hash but the old size (or vice versa). So access to hash[bucket] can trigger OOB read access in case the table got expanded and we saw the new size but the old hash pointer (or it got shrunk and we got new hash ptr but the size of the old and larger table): kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#1] SMP KASAN CPU: 0 PID: 3 Comm: ksoftirqd/0 Not tainted 4.6.0-rc2+ #107 [..] Call Trace: [<ffffffff822c3d6a>] ? nf_conntrack_tuple_taken+0x12a/0xe90 [<ffffffff822c3ac1>] ? nf_ct_invert_tuplepr+0x221/0x3a0 [<ffffffff8230e703>] get_unique_tuple+0xfb3/0x2760 Use generation counter to obtain the address/length of the same table. Also add a synchronize_net before freeing the old hash. AFAICS, without it we might access ct_hash[bucket] after ct_hash has been freed, provided that lockless reader got delayed by another event: CPU1 CPU2 seq_begin seq_retry <delay> resize occurs free oldhash for_each(oldhash[size]) Note that resize is only supported in init_netns, it took over 2 minutes of constant resizing+flooding to produce the warning, so this isn't a big problem in practice. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) commit 2cf1234807bdd4ae5d3096a63c8fd5d4d5cad0ef Author: Florian Westphal <fw@strlen.de> Date: Thu Apr 28 19:13:40 2016 +0200 netfilter: conntrack: keep BH enabled during lookup No need to disable BH here anymore: stats are switched to _ATOMIC variant (== this_cpu_inc()), which nowadays generates same code as the non _ATOMIC NF_STAT, at least on x86. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-) commit 1ad8f48df6f683f186b03b51381419ac4aec73d3 Author: Florian Westphal <fw@strlen.de> Date: Tue Apr 26 11:59:53 2016 +0200 netfilter: nftables: add connlabel set support Conntrack labels are currently sized depending on the iptables ruleset, i.e. if we're asked to test or set bits 1, 2, and 65 then we would allocate enough room to store at least bit 65. However, with nft, the input is just a register with arbitrary runtime content. We therefore ask for the upper ceiling we currently have, which is enough room to store 128 bits. Alternatively, we could alter nf_connlabel_replace to increase net->ct.label_words at run time, but since 128 bits is not that big we'd only save sizeof(long) so it doesn't seem worth it for now. This follows a similar approach that xtables 'connlabel' match uses, so when user inputs ct label set bar then we will set the bit used by the 'bar' label and leave the rest alone. This is done by passing the sreg content to nf_connlabels_replace as both value and mask argument. Labels (bits) already set thus cannot be re-set to zero, but this is not supported by xtables connlabel match either. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nft_ct.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit f18ebc211e259d4f591e39e74b2aa2de226c9a1d Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu May 5 16:23:04 2016 +0300 ACPI / sysfs: fix error code in get_status() The problem with ornamental, do-nothing gotos is that they lead to "forgot to set the error code" bugs. We should be returning -EINVAL here but we don't. It leads to an uninitalized variable in counter_show(): drivers/acpi/sysfs.c:603 counter_show() error: uninitialized symbol 'status'. Fixes: 1c8fce27e275 (ACPI: introduce drivers/acpi/sysfs.c) Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/sysfs.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 878a872ead5d178b1947b480990de186529ff0b9 Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 13:00:42 2016 +0800 ACPICA: Update version to 20160422 ACPICA commit a2327ba410e19c2aabaf34b711dbadf7d1dcf346 Version 20160422. Link: https://github.com/acpica/acpica/commit/a2327ba4 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/acpixf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6a0df32c22fdfc414e6613c1bc911f19f39df01b Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 13:00:36 2016 +0800 ACPICA: Move all ASCII utilities to a common file ACPICA commit ba60e4500053010bf775d58f6f61febbdb94d817 New file is utascii.c Link: https://github.com/acpica/acpica/commit/ba60e450 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/Makefile | 1 + drivers/acpi/acpica/actables.h | 2 - drivers/acpi/acpica/acutils.h | 13 ++- drivers/acpi/acpica/dbnames.c | 2 +- drivers/acpi/acpica/exnames.c | 2 +- drivers/acpi/acpica/tbdata.c | 6 +- drivers/acpi/acpica/tbfind.c | 2 +- drivers/acpi/acpica/tbinstal.c | 6 +- drivers/acpi/acpica/tbutils.c | 27 ------ drivers/acpi/acpica/utascii.c | 140 +++++++++++++++++++++++++++++++ drivers/acpi/acpica/utstring.c | 69 +-------------- tools/power/acpi/tools/acpidump/Makefile | 1 + tools/power/acpi/tools/acpidump/apdump.c | 8 +- 13 files changed, 168 insertions(+), 111 deletions(-) commit 66b1ed5aa8dd253a734bf6ca4e5390385724f99c Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 13:00:29 2016 +0800 ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support for acpi_hw_write() ACPICA commit 48eea5e7993ccb7189bd63cd726e02adafee6057 This patch adds access_width/bit_offset support in acpi_hw_write(). Lv Zheng. Link: https://github.com/acpica/acpica/commit/48eea5e7 Link: https://bugs.acpica.org/show_bug.cgi?id=1240 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/hwregs.c | 146 ++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 137 insertions(+), 9 deletions(-) commit c3bc26d4b4e36f0dc458eea8b1f722d8a8d9addd Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 12:58:52 2016 +0800 ACPICA: ACPI 2.0, Hardware: Add access_width/bit_offset support in acpi_hw_read() ACPICA commit 96ece052d4d073aae4f935f0ff0746646aea1174 ACPICA commit 3d8583a054e410f2ea4d73b48986facad9cfc0d4 This patch adds access_width/bit_offset support in acpi_hw_read(). This also enables GAS definition where bit_width is not a power of two. Lv Zheng. Link: https://github.com/acpica/acpica/commit/96ece052 Link: https://github.com/acpica/acpica/commit/3d8583a0 Link: https://bugs.acpica.org/show_bug.cgi?id=1240 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/hwregs.c | 75 ++++++++++++++++++++++++++++++++++++-------- 1 file changed, 62 insertions(+), 13 deletions(-) commit 9222aa8234d9f07a70e815ddd3b44a97d673aff5 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 12:58:45 2016 +0800 ACPICA: Executer: Introduce a set of macros to handle bit width mask generation ACPICA commit c23034a3a09d5ed79f1827d51f43cfbccf68ab64 A regression was reported to the shift offset >= width of type. This patch fixes this issue. BZ 1270. This is a part of the fix because the order of the patches are modified for Linux upstream, containing the cleanups for the old code. Lv Zheng. Link: https://github.com/acpica/acpica/commit/c23034a3 Link: https://bugs.acpica.org/show_bug.cgi?id=1270 Reported-by: Sascha Wildner <swildner@gmail.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acmacros.h | 12 ++++++++++++ drivers/acpi/acpica/exfldio.c | 12 ++---------- 2 files changed, 14 insertions(+), 10 deletions(-) commit b314a172ee968d45f72dffea68ab8af38aa80ded Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 12:58:39 2016 +0800 ACPICA: Hardware: Add optimized access bit width support ACPICA commit c49a751b4dae7baec1790748a2b4b6e8ab599f51 For Access Size = 0, it actually can use user expected access bit width. This patch implements this. Besides of the ACPICA upstream commit, this patch also includes a fix fixing the issue reported by the FreeBSD community. The old register descriptors are translated in acpi_tb_init_generic_address() with access_width being filled with 0. This breaks code in acpi_hw_get_access_bit_width() when the registers are 16-bit IO ports and their bit_width fields are filled with 16. The rapid fix is meant to make code written for acpi_hw_get_access_bit_width() regression safer before the issue is correctly fixed from acpi_tb_init_generic_address(). Reported by John Baldwin <jhb@freebsd.org>, fixed by Lv Zheng <lv.zheng@intel.com>, tested by Jung-uk Kim <jkim@freebsd.org>. Link: https://github.com/acpica/acpica/commit/c49a751b Reported-by: John Baldwin <jhb@freebsd.org> Tested-by Jung-uk Kim <jkim@freebsd.org>. Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/hwregs.c | 49 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 47 insertions(+), 2 deletions(-) commit e35d75024b28083b0a84cdb73b826f8450b29d49 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 12:58:32 2016 +0800 ACPICA: Utilities: Add ACPI_IS_ALIGNED() macro This patch introduces ACPI_IS_ALIGNED() macro. Lv Zheng. Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acmacros.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5391abfdae7fc61556af4dd115e7522985fc9998 Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 12:58:25 2016 +0800 ACPICA: Renamed some #defined flag constants for clarity ACPICA commit 438905b205e64e742f9670a0970419c426264831 Expanded a couple of cryptic names. Link: https://github.com/acpica/acpica/commit/438905b2 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/aclocal.h | 30 +++++++++++++++--------------- drivers/acpi/acpica/psutils.c | 2 +- 2 files changed, 16 insertions(+), 16 deletions(-) commit 14f98579095af5697564276159e07aee1379582d Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 12:58:19 2016 +0800 ACPICA: ACPI 6.0, tools/iasl: Add support for new resource descriptors ACPICA commit 5a0555ece4ba9917e5842b21d88469ae06b4e815 Adds full support for: i2c_serial_bus_v2 spi_serial_bus_v2 uart_serial_bus_v2 Compiler, Disassembler, Resource Manager, acpi_help. Link: https://github.com/acpica/acpica/commit/5a0555ec Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/rsdumpinfo.c | 9 +++++---- drivers/acpi/acpica/rsserial.c | 21 ++++++++++++++++++--- include/acpi/acrestyp.h | 1 + 3 files changed, 24 insertions(+), 7 deletions(-) commit 7952d40240855932de01bbe81c02bf1416ec91d8 Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 12:58:12 2016 +0800 ACPICA: ACPI 6.0: Update _BIX support for new package element ACPICA commit 3451e6d49d37919c13ec2c0019a31534b0dfc0c0 One integer was added at the end of the _BIX method, and the version number was incremented. Link: https://github.com/acpica/acpica/commit/3451e6d4 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acpredef.h | 5 ++- drivers/acpi/acpica/nsprepkg.c | 86 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 89 insertions(+), 2 deletions(-) commit 2a397a390a90ff84cd17a6cd2275c2f19478a948 Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 12:58:05 2016 +0800 ACPICA: ACPI 6.1: Support for new PCCT subtable ACPICA commit de3ea7c322b9b6bdb09aa90c2e1d420cd4dce47c Additional subspace structure was added. Link: https://github.com/acpica/acpica/commit/de3ea7c3 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl3.h | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) commit 7dbec55350cea5fff97162ed2663741a48893f6f Author: Bob Moore <robert.moore@intel.com> Date: Thu May 5 12:58:00 2016 +0800 ACPICA: Refactor evaluate_object to reduce nesting ACPICA commit 599e9159f53565e4a3f3e67f6a03f81fcb10a4cf Original patch from hanjun.guo@linaro.org ACPICA BZ 1072. Link: https://github.com/acpica/acpica/commit/599e9159 Link: https://bugs.acpica.org/show_bug.cgi?id=1072 Original-by: Hanjun Guo <hanjun.guo@linaro.org> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/nsxfeval.c | 111 ++++++++++++++++++++--------------------- 1 file changed, 55 insertions(+), 56 deletions(-) commit f5c1e1c5a652e4b43eb9b571577ef72731f3fa8b Author: Lv Zheng <lv.zheng@intel.com> Date: Thu May 5 12:57:53 2016 +0800 ACPICA: Divergence: remove unwanted spaces for typedef ACPICA commit b2294cae776f5a66a7697414b21949d307e6856f This patch removes unwanted spaces for typedef. This solution doesn't cover function types. Note that the linuxize result of this commit is very giant and should have many conflicts against the current Linux upstream. Thus it is required to modify the linuxize result of this commit and the commits around it manually in order to have them merged to the Linux upstream. Since this is very costy, we should do this only once, and if we can't ensure to do this only once, we need to revert the Linux code to the wrong indentation result before merging the linuxize result of this commit. Lv Zheng. Link: https://github.com/acpica/acpica/commit/b2294cae Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acdebug.h | 6 +- drivers/acpi/acpica/acevents.h | 1 + drivers/acpi/acpica/acinterp.h | 2 +- drivers/acpi/acpica/aclocal.h | 31 ++++---- drivers/acpi/acpica/acresrc.h | 8 +- drivers/acpi/acpica/acutils.h | 22 +++--- drivers/acpi/acpica/dbcmds.c | 4 +- drivers/acpi/acpica/dbconvert.c | 4 +- drivers/acpi/acpica/dbexec.c | 2 +- drivers/acpi/acpica/dbinput.c | 6 +- drivers/acpi/acpica/dbnames.c | 2 +- drivers/acpi/acpica/dbxface.c | 4 +- drivers/acpi/acpica/dscontrol.c | 4 +- drivers/acpi/acpica/dsinit.c | 2 +- drivers/acpi/acpica/dsmethod.c | 2 +- drivers/acpi/acpica/dsutils.c | 2 +- drivers/acpi/acpica/dswload.c | 4 +- drivers/acpi/acpica/dswload2.c | 4 +- drivers/acpi/acpica/dswstate.c | 10 +-- drivers/acpi/acpica/evgpe.c | 4 +- drivers/acpi/acpica/evgpeblk.c | 4 +- drivers/acpi/acpica/evgpeutil.c | 4 +- drivers/acpi/acpica/evhandler.c | 2 +- drivers/acpi/acpica/evmisc.c | 3 +- drivers/acpi/acpica/evrgnini.c | 2 +- drivers/acpi/acpica/evxfgpe.c | 2 +- drivers/acpi/acpica/exconcat.c | 4 +- drivers/acpi/acpica/exconvrt.c | 4 +- drivers/acpi/acpica/excreate.c | 2 +- drivers/acpi/acpica/exfield.c | 4 +- drivers/acpi/acpica/exfldio.c | 2 +- drivers/acpi/acpica/exoparg3.c | 8 +- drivers/acpi/acpica/exoparg6.c | 2 +- drivers/acpi/acpica/exregion.c | 6 +- drivers/acpi/acpica/exresnte.c | 4 +- drivers/acpi/acpica/exresolv.c | 2 +- drivers/acpi/acpica/exresop.c | 4 +- drivers/acpi/acpica/exstorob.c | 4 +- drivers/acpi/acpica/hwgpe.c | 6 +- drivers/acpi/acpica/hwxface.c | 7 +- drivers/acpi/acpica/nsconvert.c | 6 +- drivers/acpi/acpica/nsnames.c | 2 +- drivers/acpi/acpica/nsobject.c | 4 +- drivers/acpi/acpica/nsrepair.c | 2 +- drivers/acpi/acpica/nsrepair2.c | 6 +- drivers/acpi/acpica/nsutils.c | 8 +- drivers/acpi/acpica/nsxfeval.c | 2 +- drivers/acpi/acpica/nsxfname.c | 6 +- drivers/acpi/acpica/nsxfobj.c | 6 +- drivers/acpi/acpica/psargs.c | 2 +- drivers/acpi/acpica/psparse.c | 4 +- drivers/acpi/acpica/psxface.c | 2 +- drivers/acpi/acpica/rscalc.c | 90 +++++++++++----------- drivers/acpi/acpica/rscreate.c | 2 +- drivers/acpi/acpica/rsmisc.c | 2 +- drivers/acpi/acpica/rsutils.c | 12 +-- drivers/acpi/acpica/rsxface.c | 6 +- drivers/acpi/acpica/tbdata.c | 9 +-- drivers/acpi/acpica/tbfadt.c | 2 +- drivers/acpi/acpica/tbutils.c | 6 +- drivers/acpi/acpica/tbxface.c | 6 +- drivers/acpi/acpica/tbxfroot.c | 8 +- drivers/acpi/acpica/utalloc.c | 5 +- drivers/acpi/acpica/utbuffer.c | 24 +++--- drivers/acpi/acpica/utcache.c | 7 +- drivers/acpi/acpica/utcopy.c | 16 ++-- drivers/acpi/acpica/utids.c | 8 +- drivers/acpi/acpica/utmath.c | 4 +- drivers/acpi/acpica/utobject.c | 18 ++--- drivers/acpi/acpica/utosi.c | 4 +- drivers/acpi/acpica/utownerid.c | 6 +- drivers/acpi/acpica/utprint.c | 14 ++-- drivers/acpi/acpica/utstring.c | 2 +- drivers/acpi/acpica/utxface.c | 4 +- include/acpi/acpiosxf.h | 8 +- include/acpi/acpixf.h | 21 ++--- include/acpi/actypes.h | 41 +++++----- .../acpi/os_specific/service_layers/oslinuxtbl.c | 47 ++++++----- .../acpi/os_specific/service_layers/osunixxf.c | 24 +++--- tools/power/acpi/tools/acpidump/apdump.c | 2 +- 80 files changed, 324 insertions(+), 324 deletions(-) commit 5181365f5312d67dcdc9e4bc22516c48a83c8754 Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Thu May 5 11:53:06 2016 +0100 ASoC: da7219: Add initial ACPI id for device This adds "DLGS7219" ACPI id for the codec. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Tested-by: Sathyanarayana Nujella <sathyanarayana.nujella@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7219.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 381437dd0bd590902320b97e6512792b075becd4 Author: Bard Liao <bardliao@realtek.com> Date: Thu May 5 11:13:31 2016 +0800 ASoC: rt5645: polling jd status in all conditions We only polling jd status when rt5645->pdata.jd_invert is true. However, it should be done at all time since there will be no interrupt for jd if we press a headset button and remove the headset at the same time. Signed-off-by: Bard Liao <bardliao@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt5645.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 445d84a42bf17128e22101a04cde17b9a7c2e235 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon May 2 23:49:40 2016 +0200 drm: Add gpu.tmpl docbook to MAINTAINERS entry Patches get misrouted and lost otherwise. And use * to future-proof for sphinx (or whatever the documentation nirvana toolchain will be). Cc: Jonathan Corbet <corbet@lwn.net> Cc: David Airlie <airlied@linux.ie> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462225780-3663-1-git-send-email-daniel.vetter@ffwll.ch MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit f2d580b9a8149735cbc4b59c4a8df60173658140 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed May 4 14:38:26 2016 +0200 drm/core: Do not preserve framebuffer on rmfb, v4. It turns out that preserving framebuffers after the rmfb call breaks vmwgfx userspace. This was originally introduced because it was thought nobody relied on the behavior, but unfortunately it seems there are exceptions. drm_framebuffer_remove may fail with -EINTR now, so a straight revert is impossible. There is no way to remove the framebuffer from the lists and active planes without introducing a race because of the different locking requirements. Instead call drm_framebuffer_remove from a workqueue, which is unaffected by signals. Changes since v1: - Add comment. Changes since v2: - Add fastpath for refcount = 1. (danvet) Changes since v3: - Rebased. - Restore lastclose framebuffer removal too. Cc: stable@vger.kernel.org #v4.4+ Fixes: 13803132818c ("drm/core: Preserve the framebuffer after removing it.") Testcase: kms_rmfb_basic References: https://lists.freedesktop.org/archives/dri-devel/2016-March/102876.html Cc: Thomas Hellstrom <thellstrom@vmware.com> Cc: David Herrmann <dh.herrmann@gmail.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Tested-by: Thomas Hellstrom <thellstrom@vmware.com> #v3 Tested-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/6c63ca37-0e7e-ac7f-a6d2-c7822e3d611f@linux.intel.com drivers/gpu/drm/drm_crtc.c | 63 ++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 56 insertions(+), 7 deletions(-) commit ab5701ada2473b111c24ca7f4360b0cdb5badb60 Author: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Date: Wed May 4 16:57:11 2016 -0500 USB: serial: cp210x: clean up CRTSCTS flag code The CRTSCTS flag code cleared (and inconsistently) bits unrelated to CRTSCTS functionality. It was also harder than necessary to read. Signed-off-by: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/cp210x.c | 32 ++++++++++---------------------- 1 file changed, 10 insertions(+), 22 deletions(-) commit 9034389cd81681b4f0123173eb836624199209c7 Author: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Date: Wed May 4 16:57:02 2016 -0500 USB: serial: cp210x: get rid of magic numbers in CRTSCTS flag code Replaced magic numbers used in the CRTSCTS flag code with symbolic names from the chip specification. Signed-off-by: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/cp210x.c | 109 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 84 insertions(+), 25 deletions(-) commit a377f9e906af4df9071ba8ddba60188cb4013d93 Author: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Date: Wed May 4 16:56:52 2016 -0500 USB: serial: cp210x: fix hardware flow-control disable A bug in the CRTSCTS handling caused RTS to alternate between CRTSCTS=0 => "RTS is transmit active signal" and CRTSCTS=1 => "RTS is used for receive flow control" instead of CRTSCTS=0 => "RTS is statically active" and CRTSCTS=1 => "RTS is used for receive flow control" This only happened after first having enabled CRTSCTS. Signed-off-by: Konstantin Shkolnyy <konstantin.shkolnyy@gmail.com> Fixes: 39a66b8d22a3 ("[PATCH] USB: CP2101 Add support for flow control") Cc: stable <stable@vger.kernel.org> [johan: reword commit message ] Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/cp210x.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 394bf2f24834352f461cb139eb8e00af26d5f51a Author: Yang Shi <yang.shi@linaro.org> Date: Wed May 4 11:14:27 2016 -0700 arm64: mm: remove unnecessary EXPORT_SYMBOL_GPL arch_pick_mmap_layout is only called by fs/exec.c which is always built into kernel, it looks the EXPORT_SYMBOL_GPL is pointless and no architectures export it other than ARM64. Signed-off-by: Yang Shi <yang.shi@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/mmap.c | 2 -- 1 file changed, 2 deletions(-) commit 1b6de5917172967acd8db4d222df4225d23a8a60 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Thu Apr 28 18:35:44 2016 +0300 perf/x86/intel/pt: Convert ACCESS_ONCE()s This patch converts remaining ACCESS_ONCE() instances into READ_ONCE() and WRITE_ONCE() as appropriate. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461857746-31346-2-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 65c7e6f1c4810e9bce935520f44f6d2613cd1b40 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Aug 19 17:02:10 2015 +0300 perf/x86/intel/pt: Export CPU frequency ratios needed by PT decoders Intel PT decoders need access to various bits of timing related information to be able to correctly decode timing packets from a PT stream (MTC and CBR packets). This patch exports all the necessary bits as sysfs attributes for the sake of consistency: * max_nonturbo_ratio: ratio between the invariant TSC and base clock; * tsc_art_ratio: TSC to core crystal clock ratio (also available as CPUID.15H). Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/87zisdvibe.fsf@ashishki-desk.ger.corp.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 54 ++++++++++++++++++++++++++++++++++++++++++++++ arch/x86/events/intel/pt.h | 6 ++++++ 2 files changed, 60 insertions(+) commit ccbebba4c6bfda8e3ef9e431ce2c3d91c5fc5a63 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Thu Apr 28 18:35:46 2016 +0300 perf/x86/intel/pt: Bypass PT vs. LBR exclusivity if the core supports it Not all cores prevent using Intel PT and LBRs simultaneously, although most of them still do as of today. This patch adds an opt-in flag for such cores to disable mutual exclusivity between PT and LBR; also flip it on for Goldmont. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461857746-31346-4-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/core.c | 6 ++++++ arch/x86/events/intel/core.c | 1 + arch/x86/events/perf_event.h | 1 + 3 files changed, 8 insertions(+) commit 5101ef20f0ef1de79091a1fdb6b1a7f07565545a Author: Mark Rutland <mark.rutland@arm.com> Date: Tue Apr 26 11:33:46 2016 +0100 perf/arm: Special-case hetereogeneous CPUs Commit: 26657848502b7847 ("perf/core: Verify we have a single perf_hw_context PMU") forcefully prevents multiple PMUs from sharing perf_hw_context, as this generally doesn't make sense. It is a common bug for uncore PMUs to use perf_hw_context rather than perf_invalid_context, which this detects. However, systems exist with heterogeneous CPUs (and hence heterogeneous HW PMUs), for which sharing perf_hw_context is necessary, and possible in some limited cases. To make this work we have to perform some gymnastics, as we did in these commits: 66eb579e66ecfea5 ("perf: allow for PMU-specific event filtering") c904e32a69b7c779 ("arm: perf: filter unschedulable events") To allow those systems to work, we must allow PMUs for heterogeneous CPUs to share perf_hw_context, though we must still disallow sharing otherwise to detect the common misuse of perf_hw_context. This patch adds a new PERF_PMU_CAP_HETEROGENEOUS_CPUS for this, updates the core logic to account for this, and makes use of it in the arm_pmu code that is used for systems with heterogeneous CPUs. Comments are added to make the rationale clear and hopefully avoid accidental abuse. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Link: http://lkml.kernel.org/r/20160426103346.GA20836@leverpostej Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/perf/arm_pmu.c | 8 ++++++++ include/linux/perf_event.h | 1 + kernel/events/core.c | 8 +++++++- 3 files changed, 16 insertions(+), 1 deletion(-) commit 6e855cd4f4b5258016cf707f94f96bfa51c32f32 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:48 2016 +0300 perf/core: Let userspace know if the PMU supports address filters Export an additional common attribute for PMUs that support address range filtering to let the perf userspace identify such PMUs in a uniform way. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-8-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/core.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit eadf48cab4b6b0ab8bcd53feb7d52a71e72debd0 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:47 2016 +0300 perf/x86/intel/pt: Add support for address range filtering in PT Newer versions of Intel PT support address ranges, which can be used to define IP address range-based filters or TraceSTOP regions. Number of ranges in enumerated via cpuid. This patch implements PMU callbacks and related low-level code to allow filter validation, configuration and programming into the hardware. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-7-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 179 ++++++++++++++++++++++++++++++++++++++++++--- arch/x86/events/intel/pt.h | 26 +++++++ 2 files changed, 194 insertions(+), 11 deletions(-) commit 375637bc524952f1122ea22caf5a8f1fecad8228 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:46 2016 +0300 perf/core: Introduce address range filtering Many instruction tracing PMUs out there support address range-based filtering, which would, for example, generate trace data only for a given range of instruction addresses, which is useful for tracing individual functions, modules or libraries. Other PMUs may also utilize this functionality to allow filtering to or filtering out code at certain address ranges. This patch introduces the interface for userspace to specify these filters and for the PMU drivers to apply these filters to hardware configuration. The user interface is an ASCII string that is passed via an ioctl() and specifies (in the form of an ASCII string) address ranges within certain object files or within kernel. There is no special treatment for kernel modules yet, but it might be a worthy pursuit. The PMU driver interface basically adds two extra callbacks to the PMU driver structure, one of which validates the filter configuration proposed by the user against what the hardware is actually capable of doing and the other one translates hardware-independent filter configuration into something that can be programmed into the hardware. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-6-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/perf_event.h | 98 +++++++ kernel/events/core.c | 623 +++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 705 insertions(+), 16 deletions(-) commit b73e4fefc18adbe4d12ffb746fb16306674c1ac6 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:45 2016 +0300 perf/core: Extend perf_event_aux_ctx() to optionally iterate through more events Trace filtering code needs an iterator that can go through all events in a context, including inactive and filtered, to be able to update their filters' address ranges based on mmap or exec events. This patch changes perf_event_aux_ctx() to optionally do this. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-5-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/core.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) commit f127fa098d76444c7a47b2f009356979492d77cd Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:44 2016 +0300 perf/x86/intel/pt: Add IP filtering register/CPUID bits New versions of Intel PT support address range-based filtering. Add the new registers, bit definitions and relevant CPUID bits. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-4-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 2 ++ arch/x86/events/intel/pt.h | 12 ++++++++++++ arch/x86/include/asm/msr-index.h | 9 +++++++++ 3 files changed, 23 insertions(+) commit 0dd28e2cdaff5319c86cc3ed11d1ca4cf1554046 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:43 2016 +0300 perf/x86/intel/pt: Move PT specific MSR bit definitions to a private header Nothing outside of the Intel PT driver should ever care about its MSR bits, so there is no reason to keep them in msr-index.h. This patch moves them to a pt-local header. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-3-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.h | 24 ++++++++++++++++++++++++ arch/x86/include/asm/msr-index.h | 20 -------------------- 2 files changed, 24 insertions(+), 20 deletions(-) commit c796bbbe8dccd9c91ebbb99ffef33e0f73ced7bf Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 27 18:44:42 2016 +0300 perf/core: Move set_filter() out of CONFIG_EVENT_TRACING For instruction trace filtering, namely, for communicating filter definitions from userspace, I'd like to re-use the SET_FILTER code that the tracepoints are using currently. To that end, move the relevant code out from behind the CONFIG_EVENT_TRACING dependency. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1461771888-10409-2-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/core.c | 45 ++++++++++++++++++++++----------------------- 1 file changed, 22 insertions(+), 23 deletions(-) commit 1a618c2cfe4c02190d8d1f9c5052f0defc58de20 Merge: 03d85a6 8482716 Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 5 10:12:37 2016 +0200 Merge branch 'perf/urgent' into perf/core, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit a1cc5bcfcfca0b99f009b117785142dbdc3b87a3 Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Apr 21 20:35:25 2016 +0200 locking/atomics: Flip atomic_fetch_or() arguments All the atomic operations have their arguments the wrong way around; make atomic_fetch_or() consistent and flip them. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/atomic.h | 4 ++-- kernel/time/tick-sched.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit b96bbdde19cc56f288372d25fd5ea7af04fc1271 Author: Davidlohr Bueso <dave@stgolabs.net> Date: Tue Apr 19 21:17:25 2016 -0700 locking/pvqspinlock: Robustify init_qspinlock_stat() Specifically around the debugfs file creation calls, I have no idea if they could ever possibly fail, but this is core code (debug aside) so lets at least check the return value and inform anything fishy. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Waiman Long <Waiman.Long@hpe.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160420041725.GC3472@linux-uzut.site Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/qspinlock_stat.h | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit dc209a3fd73ec96d4491bcc128c3b50b0a8e8017 Author: Davidlohr Bueso <dave@stgolabs.net> Date: Sun Apr 17 23:31:42 2016 -0700 locking/pvqspinlock: Avoid double resetting of stats ... remove the redundant second iteration, this is most likely a copy/past buglet. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: dave@stgolabs.net Cc: waiman.long@hpe.com Link: http://lkml.kernel.org/r/1460961103-24953-2-git-send-email-dave@stgolabs.net Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/qspinlock_stat.h | 2 -- 1 file changed, 2 deletions(-) commit e8c8ce54807b19e90ac84e609b13f7d4e337eab1 Merge: 5db4298 04974df Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 5 09:57:27 2016 +0200 Merge tag 'v4.6-rc6' into locking/core, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 3cd0b53553ce28da6fc828c601041c974e1c4dde Merge: f68376f 08914f4 Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 5 09:56:10 2016 +0200 Merge branch 'x86/urgent' into x86/platform, to resolve conflict Conflicts: arch/x86/kernel/apic/x2apic_uv_x.c Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 885e542ce827f5f102fe9628d63c6430c8b7ab2c Author: Dietmar Eggemann <dietmar.eggemann@arm.com> Date: Fri Apr 29 20:32:39 2016 +0100 sched/fair: Fix comment in calculate_imbalance() The comment in calculate_imbalance() was introduced in commit: 2dd73a4f09be ("[PATCH] sched: implement smpnice") which described the logic as it was then, but a later commit: b18855500fc4 ("sched/balancing: Fix 'local->avg_load > sds->avg_load' case in calculate_imbalance()") .. complicated this logic some more so that the comment does not match anymore. Update the comment to match the code. Signed-off-by: Dietmar Eggemann <dietmar.eggemann@arm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461958364-675-3-git-send-email-dietmar.eggemann@arm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 0a9b23ce46cd5d3a360fbefca8ffce441c55046e Author: Dietmar Eggemann <dietmar.eggemann@arm.com> Date: Fri Apr 29 20:32:38 2016 +0100 sched/fair: Remove stale power aware scheduling comments Commit 8e7fbcbc22c1 ("sched: Remove stale power aware scheduling remnants and dysfunctional knobs") deleted the power aware scheduling support. This patch gets rid of the remaining power aware scheduling related comments in the code as well. Signed-off-by: Dietmar Eggemann <dietmar.eggemann@arm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461958364-675-2-git-send-email-dietmar.eggemann@arm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit b52fad2db5d792d89975cebf2fe1646a7af28ed0 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Tue May 3 20:46:54 2016 +0100 sched/fair: Update rq clock before updating nohz CPU load If we're accessing rq_clock() (e.g. in sched_avg_update()) we should update the rq clock before calling cpu_load_update(), otherwise any time calculations will be stale. All other paths currently call update_rq_clock(). Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Wanpeng Li <wanpeng.li@hotmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Mike Galbraith <efault@gmx.de> Cc: Mike Galbraith <umgwanakikbuti@gmail.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462304814-11715-1-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 1 + 1 file changed, 1 insertion(+) commit db6ea2fb094fb3a6afc36d3e4229bc162638ad24 Author: Wanpeng Li <wanpeng.li@hotmail.com> Date: Tue May 3 12:38:25 2016 +0800 sched/debug: Print out idle balance values even on !CONFIG_SCHEDSTATS kernels The max_idle_balance_cost and avg_idle values which are tracked and ar used to capture short idle incidents, are not associated with schedstats, however the information of these two values isn't printed out on !CONFIG_SCHEDSTATS kernels. Fix this by moving the value printout out of the CONFIG_SCHEDSTATS section. Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462250305-4523-1-git-send-email-wanpeng.li@hotmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/debug.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 7b20b916e953cabef569541f991a0a583bc344cb Author: Yuyang Du <yuyang.du@intel.com> Date: Tue May 3 05:54:27 2016 +0800 sched/fair: Optimize sum computation with a lookup table __compute_runnable_contrib() uses a loop to compute sum, whereas a table lookup can do it faster in a constant amount of time. The program to generate the constants is located at: Documentation/scheduler/sched-avg.txt Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Morten Rasmussen <morten.rasmussen@arm.com> Acked-by: Vincent Guittot <vincent.guittot@linaro.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bsegall@google.com Cc: dietmar.eggemann@arm.com Cc: juri.lelli@arm.com Cc: pjt@google.com Link: http://lkml.kernel.org/r/1462226078-31904-2-git-send-email-yuyang.du@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 7b5953345efe4f226bb52cbea04558d16ec7ebfa Author: Yuyang Du <yuyang.du@intel.com> Date: Tue Apr 5 12:12:28 2016 +0800 sched/fair: Add detailed description to the sched load avg metrics These sched metrics have become complex enough, so describe them in detail at their definition. Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> [ Fixed the text to improve its spelling and typography. ] Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bsegall@google.com Cc: dietmar.eggemann@arm.com Cc: lizefan@huawei.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: umgwanakikbuti@gmail.com Cc: vincent.guittot@linaro.org Link: http://lkml.kernel.org/r/1459829551-21625-4-git-send-email-yuyang.du@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 60 +++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 49 insertions(+), 11 deletions(-) commit 172895e6b5216eba3e0880460829a8baeefd55f3 Author: Yuyang Du <yuyang.du@intel.com> Date: Tue Apr 5 12:12:27 2016 +0800 sched/fair: Rename SCHED_LOAD_SHIFT to NICE_0_LOAD_SHIFT and remove SCHED_LOAD_SCALE After cleaning up the sched metrics, there are two definitions that are ambiguous and confusing: SCHED_LOAD_SHIFT and SCHED_LOAD_SHIFT. Resolve this: - Rename SCHED_LOAD_SHIFT to NICE_0_LOAD_SHIFT, which better reflects what it is. - Replace SCHED_LOAD_SCALE use with SCHED_CAPACITY_SCALE and remove SCHED_LOAD_SCALE. Suggested-by: Ben Segall <bsegall@google.com> Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: dietmar.eggemann@arm.com Cc: lizefan@huawei.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: umgwanakikbuti@gmail.com Cc: vincent.guittot@linaro.org Link: http://lkml.kernel.org/r/1459829551-21625-3-git-send-email-yuyang.du@intel.com [ Rewrote the changelog and fixed the build on 32-bit kernels. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 4 ++-- kernel/sched/sched.h | 22 +++++++++++----------- 2 files changed, 13 insertions(+), 13 deletions(-) commit 6ecdd74962f246dfe8750b7bea481a1c0816315d Author: Yuyang Du <yuyang.du@intel.com> Date: Tue Apr 5 12:12:26 2016 +0800 sched/fair: Generalize the load/util averages resolution definition Integer metric needs fixed point arithmetic. In sched/fair, a few metrics, e.g., weight, load, load_avg, util_avg, freq, and capacity, may have different fixed point ranges, which makes their update and usage error-prone. In order to avoid the errors relating to the fixed point range, we definie a basic fixed point range, and then formalize all metrics to base on the basic range. The basic range is 1024 or (1 << 10). Further, one can recursively apply the basic range to have larger range. Pointed out by Ben Segall, weight (visible to user, e.g., NICE-0 has 1024) and load (e.g., NICE_0_LOAD) have independent ranges, but they must be well calibrated. Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bsegall@google.com Cc: dietmar.eggemann@arm.com Cc: lizefan@huawei.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: umgwanakikbuti@gmail.com Cc: vincent.guittot@linaro.org Link: http://lkml.kernel.org/r/1459829551-21625-2-git-send-email-yuyang.du@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 16 +++++++++++++--- kernel/sched/fair.c | 4 ---- kernel/sched/sched.h | 15 ++++++++++----- 3 files changed, 23 insertions(+), 12 deletions(-) commit 2159197d66770ec01f75c93fb11dc66df81fd45b Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Apr 28 12:49:38 2016 +0200 sched/core: Enable increased load resolution on 64-bit kernels Mike ran into the low load resolution limitation on his big machine. So reenable these bits; nobody could ever reproduce/analyze the reported power usage claim and Google has been running with this for years as well. Reported-by: Mike Galbraith <umgwanakikbuti@gmail.com> Tested-by: Mike Galbraith <umgwanakikbuti@gmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/sched.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit e7904a28f5331c21d17af638cb477c83662e3cb6 Author: Peter Zijlstra <peterz@infradead.org> Date: Sat Aug 1 19:25:08 2015 +0200 locking/lockdep, sched/core: Implement a better lock pinning scheme The problem with the existing lock pinning is that each pin is of value 1; this mean you can simply unpin if you know its pinned, without having any extra information. This scheme generates a random (16 bit) cookie for each pin and requires this same cookie to unpin. This means you have to keep the cookie in context. No objsize difference for !LOCKDEP kernels. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/lockdep.h | 23 ++++++++++---- kernel/locking/lockdep.c | 71 +++++++++++++++++++++++++++++++++++++------ kernel/sched/core.c | 79 +++++++++++++++++++++++++----------------------- kernel/sched/deadline.c | 11 ++++--- kernel/sched/fair.c | 6 ++-- kernel/sched/idle_task.c | 2 +- kernel/sched/rt.c | 6 ++-- kernel/sched/sched.h | 8 +++-- kernel/sched/stop_task.c | 2 +- 9 files changed, 140 insertions(+), 68 deletions(-) commit eb58075149b7f0300ff19142e6245fe75db2a081 Author: Peter Zijlstra <peterz@infradead.org> Date: Fri Jul 31 21:28:18 2015 +0200 sched/core: Introduce 'struct rq_flags' In order to be able to pass around more than just the IRQ flags in the future, add a rq_flags structure. No difference in code generation for the x86_64-defconfig build I tested. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 98 +++++++++++++++++++++++++------------------------ kernel/sched/deadline.c | 6 +-- kernel/sched/sched.h | 14 ++++--- 3 files changed, 62 insertions(+), 56 deletions(-) commit 3e71a462dd483ce508a723356b293731e7d788ea Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Apr 28 16:16:33 2016 +0200 sched/core: Move task_rq_lock() out of line Its a rather large function, inline doesn't seems to make much sense: $ size defconfig-build/kernel/sched/core.o{.orig,} text data bss dec hex filename 56533 21037 2320 79890 13812 defconfig-build/kernel/sched/core.o.orig 55733 21037 2320 79090 134f2 defconfig-build/kernel/sched/core.o The 'perf bench sched messaging' micro-benchmark shows a visible improvement of 4-5%: $ for i in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor ; do echo performance > $i ; done $ perf stat --null --repeat 25 -- perf bench sched messaging -g 40 -l 5000 pre: 4.582798193 seconds time elapsed ( +- 1.41% ) 4.733374877 seconds time elapsed ( +- 2.10% ) 4.560955136 seconds time elapsed ( +- 1.43% ) 4.631062303 seconds time elapsed ( +- 1.40% ) post: 4.364765213 seconds time elapsed ( +- 0.91% ) 4.454442734 seconds time elapsed ( +- 1.18% ) 4.448893817 seconds time elapsed ( +- 1.41% ) 4.424346872 seconds time elapsed ( +- 0.97% ) Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 65 ++++++++++++++++++++++++++++++++++++++++++++++++++ kernel/sched/sched.h | 67 ++++------------------------------------------------ 2 files changed, 69 insertions(+), 63 deletions(-) commit 0e1a485b275a0f1900bbd1a6d23b31bcc3d3f992 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed May 4 15:42:07 2016 +0200 drm: Fix up markup fumble It's & for struct references, not #. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Jani Nikula <jani.nikula@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462369327-26659-1-git-send-email-daniel.vetter@ffwll.ch include/drm/drm_modeset_helper_vtables.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit af509d38bbbcf1b6a731389632ad367db7bc4ef5 Author: Lyude <cpaul@redhat.com> Date: Wed May 4 11:28:53 2016 -0400 drm/fb_helper: Fix a few typos s/modest/modeset/ s/aftert/after/ Signed-off-by: Lyude <cpaul@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462375734-8213-3-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_fb_helper.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 64b7aad5798478ffff52e110878ccaae4c3aaa34 Merge: 078194f 2548d54 Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 5 09:01:49 2016 +0200 Merge branch 'sched/urgent' into sched/core, to pick up fixes before applying new changes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 0676b4e0a1940a6b7ae3156bd212ca9032a29c30 Author: Brian Gerst <brgerst@gmail.com> Date: Wed May 4 22:44:38 2016 -0400 x86/entry/32: Remove asmlinkage_protect() Now that syscalls are called from C code, which copies the args to new stack slots instead of overlaying pt_regs, asmlinkage_protect() is no longer needed. Signed-off-by: Brian Gerst <brgerst@gmail.com> Acked-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462416278-11974-4-git-send-email-brgerst@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/linkage.h | 34 ---------------------------------- 1 file changed, 34 deletions(-) commit 1e17880371f85d3d866962e04ba3567c0654a125 Author: Brian Gerst <brgerst@gmail.com> Date: Wed May 4 22:44:37 2016 -0400 x86/entry/32: Remove GET_THREAD_INFO() from entry code The entry code used to cache the thread_info pointer in the EBP register, but all the code that used it has been moved to C. Remove the unused code to get the pointer. Signed-off-by: Brian Gerst <brgerst@gmail.com> Acked-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462416278-11974-3-git-send-email-brgerst@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_32.S | 3 --- 1 file changed, 3 deletions(-) commit 092c74e420952c7cb68141731f2b562245b51eeb Author: Brian Gerst <brgerst@gmail.com> Date: Wed May 4 22:44:36 2016 -0400 x86/entry, sched/x86: Don't save/restore EFLAGS on task switch Now that NT is filtered by the SYSENTER entry code, it is safe to skip saving and restoring flags on task switch. Also remove a leftover reset of flags on 64-bit fork. Signed-off-by: Brian Gerst <brgerst@gmail.com> Acked-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1462416278-11974-2-git-send-email-brgerst@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_32.S | 4 ---- arch/x86/entry/entry_64.S | 3 --- arch/x86/include/asm/switch_to.h | 4 +--- 3 files changed, 1 insertion(+), 10 deletions(-) commit 9e5c9fe4cbb89b9af1fcf317f7b39d993bb47a71 Author: Richard W.M. Jones <rjones@redhat.com> Date: Tue May 3 10:00:17 2016 +0100 crypto: testmgr - Add a flag allowing the self-tests to be disabled at runtime. Running self-tests for a short-lived KVM VM takes 28ms on my laptop. This commit adds a flag 'cryptomgr.notests' which allows them to be disabled. However if fips=1 as well, we ignore this flag as FIPS mode mandates that the self-tests are run. Signed-off-by: Richard W.M. Jones <rjones@redhat.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Documentation/kernel-parameters.txt | 3 +++ crypto/testmgr.c | 9 +++++++++ 2 files changed, 12 insertions(+) commit 1fb48f8e54e5ed4d3d8599ba7e83f1f60530c81c Merge: 778843f 04974df Author: Ingo Molnar <mingo@kernel.org> Date: Thu May 5 08:35:00 2016 +0200 Merge tag 'v4.6-rc6' into x86/asm, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 035cd6ba53eff060760c4f4d11339fcc916a967c Author: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Date: Wed May 4 15:49:39 2016 -0700 MAINTAINERS: Cleanup Intel Wired LAN maintainers list With the recent "retirements" and other changes, make the maintainers list a lot less confusing and a bit more straight forward. Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Acked-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Acked-by: Shannon Nelson <sln@onemain.com> Signed-off-by: David S. Miller <davem@davemloft.net> MAINTAINERS | 7 ------- 1 file changed, 7 deletions(-) commit 777c6ae57ebd432b59950b3e28bf01676018d1b2 Author: Eric Dumazet <edumazet@google.com> Date: Wed May 4 15:27:29 2016 -0700 tcp: two more missing bh disable percpu_counter only have protection against preemption. TCP stack uses them possibly from BH, so we need BH protection in contexts that could be run in process context Fixes: c10d9310edf5 ("tcp: do not assume TCP code is non preemptible") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_connection_sock.c | 2 ++ net/ipv4/tcp_ipv4.c | 2 ++ 2 files changed, 4 insertions(+) commit 0552f7651bc233e5407ab06ba97a9d7c25e19580 Author: Dave Airlie <airlied@redhat.com> Date: Wed Mar 9 11:14:38 2016 +1000 drm/i915/mst: use reference counted connectors. (v3) Don't just free the connector when we get the destroy callback. Drop a reference to it, and set it's mst_port to NULL so no more mst work is done on it. v2: core mst accepts NULLs fine. Cleanup EDID code properly. v3: drop the extra reference we were taking. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/i915/intel_dp_mst.c | 43 +++++++++++++++++-------------------- drivers/gpu/drm/i915/intel_drv.h | 2 +- 2 files changed, 21 insertions(+), 24 deletions(-) commit d2307dea14a4f14a4b5db01b6d40a30fa6117e6c Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 11:27:39 2016 +1000 drm/atomic: use connector references (v3) Take a reference when setting a crtc on a connecter, also take one when duplicating if a crtc is set, and drop one on destroy if a crtc is set. v2: take Daniel Stone's advice and simplify the ref/unref dances, also take care of NULL as connector to state reset. v3: remove need for connector NULL check. Reviewed-by: Daniel Stone <daniels@collabora.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_atomic.c | 14 +++++--------- drivers/gpu/drm/drm_atomic_helper.c | 4 ++++ 2 files changed, 9 insertions(+), 9 deletions(-) commit 0955c1250e9699b3bdc633d778710d219c61df66 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 11:27:54 2016 +1000 drm/crtc: take references to connectors used in a modeset. (v2) This just takes a reference on the connector when we set a mode in the non-atomic paths. v2: Follow Daniel Stone's suggestions on when to take/drop references. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc_helper.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 6e86d58be3d175ca950eb0dde05f175debc10ef3 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 11:24:51 2016 +1000 drm/fb_helper: add connector reference counting. (v2) This takes a reference count when fbdev adds the connector, and drops it when it removes the connector. It also drops the now unneeded code to find connectors and remove the from the modeset as they are reference counted. v2: drop references when removing all connectors at end. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_fb_helper.c | 38 +++++--------------------------------- 1 file changed, 5 insertions(+), 33 deletions(-) commit b164d31f50b2923a7a92c2a40cb46973a6ba8c36 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 11:10:09 2016 +1000 drm/modes: add connector reference counting. (v2) This uses the previous changes to add reference counts to drm connector objects. v2: move fbdev changes to their own patch. add some kerneldoc Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_atomic.c | 19 +++++++++++++++++-- drivers/gpu/drm/drm_crtc.c | 28 ++++++++++++++++++++++++---- include/drm/drm_crtc.h | 32 +++++++++++++++++++++++++++++++- 3 files changed, 72 insertions(+), 7 deletions(-) commit e76d399f21f3fd20c470233af73cab2e5307d566 Author: Dave Airlie <airlied@redhat.com> Date: Tue May 3 10:17:52 2016 +1000 drm/fb: fix missing /** in kerneldoc comment. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Dave Airlie <airlied@redhat.com> include/drm/drm_crtc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 84fae133f0ccc974a425eee21101f5644bd8d14d Author: Muhammad Falak R Wani <falakreyaz@gmail.com> Date: Sun May 1 00:30:24 2016 +0530 drm/amdgpu: Replace rcu_assign_pointer() with RCU_INIT_POINTER() The rcu_assign_pointer() ensures that the initialization of a structure is carried out before storing a pointer to that structre. It is always safe to use RCU_INIT_POINTER() to NULL a pointer, instead of rcu_assign_pointer(). This results in slightly smaller/faster code. The following semantic patch was used: <smpl> @@ @@ - rcu_assign_pointer + RCU_INIT_POINTER (..., NULL) </smpl> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6b8812eb004ee2b24aac8b1a711a0e8e797df3ce Author: Alex Deucher <alexander.deucher@amd.com> Date: Mon May 2 10:24:41 2016 -0400 drm/amdgpu: use drm_mode_vrefresh() rather than mode->vrefresh This is a port of radeon commit: 3d2d98ee1af0cf6eebfbd6bff4c17d3601ac1284 drm/radeon: use drm_mode_vrefresh() rather than mode->vrefresh to amdgpu. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/amdgpu_dpm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a0cdef9e8234cd501d1ad1ea8517136087b3e60f Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 29 11:44:32 2016 -0400 drm/amdgpu/uvd6: add bypass support for fiji (v3) Handle uvd clock bypass settings as part of clockgating setup. v2: fix gate logic v3: fix header include Reviewed-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit bdf1ecea3c656acab45976ff7a6ba53b37cd7a1d Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 29 11:20:32 2016 -0400 drm/amdgpu/fiji: set UVD CG state when enabling UVD DPM (v2) Need to call the IP cg callbacks. v2: fix gate logic Reviewed-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_clockpowergating.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit ce90dbd9b844212a9326cbeed8013abee5ac46d2 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 28 17:19:41 2016 -0400 drm/powerplay: add missing clockgating callback for tonga Without this clockgating is not enabled. Reviewed-by: Ken Wang <Qingqing.Wang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 1 + 1 file changed, 1 insertion(+) commit 909a0631b1e64428a98002ad1ea470fa83d95843 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Mon Apr 25 21:31:34 2016 +0200 drm/amdgpu: Constify some tables Some more tables with constant data were added with the polaris support v2: missed a few Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 32 ++++++++++++---------- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.h | 2 +- .../drm/amd/powerplay/hwmgr/polaris10_powertune.c | 14 +++++----- .../drm/amd/powerplay/hwmgr/polaris10_thermal.c | 8 +++--- .../gpu/drm/amd/powerplay/inc/polaris10_pwrvirus.h | 2 +- .../drm/amd/powerplay/smumgr/polaris10_smumgr.c | 11 ++++---- 6 files changed, 36 insertions(+), 33 deletions(-) commit 58174c2787c8fe7f36b195fbacf4ac174341d889 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 24 13:21:27 2016 +0200 drm/amd/powerplay: Delete dead struct declaration Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/cz_clockpowergating.h | 1 - 1 file changed, 1 deletion(-) commit ac0cc35008d570f5338b72f48960467c764b0f36 Author: Moritz Kühner <kuehner.moritz@gmail.com> Date: Sun Apr 17 16:15:24 2016 +0200 drm/amd/powerplay/hwmgr: don't add invalid voltage if atomctrl_get_voltage_evv_on_sclk returns non zero (fail) in the expansion of the PP_ASSERT_WITH_CODE macro the continue will actually do nothing (The macro uses a do ... while(0) as scope, which eats the continue). Based on the code I don't think this was the intent. Unfortunately fixing this requires rewriting the control flow and removing the macros. v2: added signed of by fixed error message print v3: agd: drop DRM_ERROR Signed-off-by: Moritz Kühner <kuehner.moritz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 54 ++++++++++++----------- 1 file changed, 28 insertions(+), 26 deletions(-) commit c790f87318337738208b0a32697d88312a26086c Author: Moritz Kühner <kuehner.moritz@gmail.com> Date: Sun Apr 17 16:15:23 2016 +0200 drm/amd/powerplay/hwmgr: prevent VDDC from exceeding 2V If the tonga gpu is controlled by SVID2 tonga_get_evv_voltage will only print an error if the voltage exceeds 2V although a comment clearly states that it needs be less than 2V. v2: added signed of by Signed-off-by: Moritz Kühner <kuehner.moritz@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 74c97375e53736ca3b615be43696a8507062970f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:49 2016 +0100 MAINTAINERS: Remove unneded wildcard for the Radeon/AMDGPU drivers There are no other files but the UAPI headers, thus we can drop the wildcard. Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 84ef4c12ee7b7a080364ad9168ffcf5fa6df4ecf Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 10:06:23 2016 +1000 drm/radeon: add cayman VM support for append packet. This adds support for SET_APPEND_CNT packet3 to the VM paths. Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/evergreen_cs.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit adcec288bc066065310a6668755c673264ee12d9 Author: Tom St Denis <tom.stdenis@amd.com> Date: Fri Apr 15 13:08:44 2016 -0400 drm/amd/amdgpu: Add debugfs entries for smc/didt/pcie This adds 3 new files that can be read/written to access indirect GPU registers. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 230 ++++++++++++++++++++++++++++- 2 files changed, 223 insertions(+), 9 deletions(-) commit 16a7989ac62a4d491d44a295577a7e75b7e3b0bb Author: Tom St Denis <tom.stdenis@amd.com> Date: Mon Mar 28 08:21:52 2016 -0400 drm/amd/amdgpu: Drop print_status callbacks. First patch in series to move to user mode debug tools we're removing the print_status callbacks. These functions were unused at the moment anyway. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_acp.c | 8 - drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 10 - drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 210 --------------------- drivers/gpu/drm/amd/amdgpu/cik.c | 6 - drivers/gpu/drm/amd/amdgpu/cik_ih.c | 34 ---- drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 56 ------ drivers/gpu/drm/amd/amdgpu/cz_dpm.c | 1 - drivers/gpu/drm/amd/amdgpu/cz_ih.c | 34 ---- drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 12 -- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 12 -- drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 12 -- drivers/gpu/drm/amd/amdgpu/fiji_dpm.c | 1 - drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 253 -------------------------- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 182 ------------------ drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c | 113 ------------ drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 110 ----------- drivers/gpu/drm/amd/amdgpu/iceland_dpm.c | 1 - drivers/gpu/drm/amd/amdgpu/iceland_ih.c | 34 ---- drivers/gpu/drm/amd/amdgpu/kv_dpm.c | 57 ------ drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 54 ------ drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 56 ------ drivers/gpu/drm/amd/amdgpu/tonga_dpm.c | 1 - drivers/gpu/drm/amd/amdgpu/tonga_ih.c | 34 ---- drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 112 ------------ drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 115 ------------ drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 107 ----------- drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 70 ------- drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 68 ------- drivers/gpu/drm/amd/amdgpu/vi.c | 6 - drivers/gpu/drm/amd/include/amd_shared.h | 2 - drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 5 - 31 files changed, 1776 deletions(-) commit a72d5604ead32d282fefbc018ca63a3bf878e2c2 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Apr 15 17:23:14 2016 -0400 drm/amd/powerplay: revise reading/writing pptable on Polaris10 Change the way we store pptables in the driver to better facilitate eventual runtime updates for debugging. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 31 +++++++++++++++++++--- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.h | 3 +++ 2 files changed, 30 insertions(+), 4 deletions(-) commit 92dea67dd682e56c7a5deebeb7d99de5f4ffcedf Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Apr 15 17:14:53 2016 -0400 drm/amd/powerplay: revise reading/writing pptable on Tonga Change the way we store pptables in the driver to better facilitate eventual runtime updates for debugging. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 37 +++++++++++++++-------- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.h | 2 ++ 2 files changed, 27 insertions(+), 12 deletions(-) commit 65ba4f227c2f9318551b0faad5c08e31b55ba598 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Apr 15 16:33:20 2016 -0400 drm/amd/powerplay: revise reading/writing pptable on Fiji Change the way we store pptables in the driver to better facilitate eventual runtime updates for debugging. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 40 ++++++++++++++++++++---- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.h | 4 ++- 2 files changed, 37 insertions(+), 7 deletions(-) commit 1551019523a01f477888835b9ed363d3a2e73d7b Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Apr 15 15:02:54 2016 -0400 drm/amd/powerplay: revise caching the soft pptable and add it's size This fixes a bug in the pptable access interface that could lead to a crash. Check the pointer before using it. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/hwmgr/tonga_processpptables.c | 15 +++++++++------ drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 1 + 2 files changed, 10 insertions(+), 6 deletions(-) commit 5632708f4452eb9afb985b245b98dac9a5feeac2 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Tue Apr 12 14:57:23 2016 -0400 drm/amd/powerplay: add dpm force multiple levels on cz/tonga/fiji/polaris (v2) Allows you to force multiple levels rather than just one via the new sysfs interrface. v2: squash in: drm/amd/powerplay: ensure clock level set by user is valid. From Rex. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 51 +++++++++++++++------- drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 4 +- drivers/gpu/drm/amd/powerplay/hwmgr/cz_hwmgr.c | 6 +-- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 18 ++++++-- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 16 +++++-- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 16 +++++-- drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h | 2 +- drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 2 +- 8 files changed, 81 insertions(+), 34 deletions(-) commit 51224389543ebd7307e09f0f46e5c5cac417d940 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Mon Apr 11 14:26:12 2016 -0400 drm/amd/powerplay: fix fan speed percent setting error on Polaris10 The logic was reversed. Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_thermal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 681ed01c62915656b9807f25e23f18c0d77ad786 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Mon Apr 4 11:52:56 2016 -0400 drm/amd/powerplay: fix bug dpm can't work when resume back on Polaris Need to initialize the values to 0 since they get or'ed with additional values. If the initialization is missing, on resume, they may end up with a combination of stale data and new data. Fixes dpm on resume. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 5 +++++ 1 file changed, 5 insertions(+) commit 7d367c2aeaf6058e9c55c1d6bff4f5174b65854c Author: Rex Zhu <Rex.Zhu@amd.com> Date: Fri Apr 1 19:56:07 2016 +0800 drm/amd/powerplay: fix some initialize error on polaris10. 1. don't enable SclkThrottleLowNotification, it's not supported. 2. Set missing mclk_dpm0_activity_target Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 7383bcb94a19349263c7b64f4272d0ca9c94e615 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 30 11:35:50 2016 +0800 drm/amd/powerplay: return 0 when interface not implement on some asic. Don't fail if certain optional interface callbacks are missing. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 169 +++++++++++++++++--------- 1 file changed, 113 insertions(+), 56 deletions(-) commit 0b45541df37295e97216f8d45ae583a78ea31416 Author: Mykola Lysenko <Mykola.Lysenko@amd.com> Date: Wed Mar 30 05:50:11 2016 -0400 drm/amdgpu: fix memory leak in CGS (FW info) Previously requested FW pointer should not be overwritten on a subsequent call. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Mykola Lysenko <Mykola.Lysenko@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 70 +++++++++++++++++---------------- 1 file changed, 36 insertions(+), 34 deletions(-) commit b0d113453a1dfb6d514dc62e976c51e9a63d3bb6 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Fri Mar 25 13:08:46 2016 +0800 drm/amd/powerplay: update vce power gate state for baffin. Forgot to save the current gate state so we don't know what the current state is if we try and gate/ungate the block. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_clockpowergating.c | 2 ++ 1 file changed, 2 insertions(+) commit c8c67448b798e4bf5b320c7a15373b10e2d25523 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu Mar 24 16:44:18 2016 -0400 drm/amd/powerplay: Fix a bug for enabling ACDC gpio interrupt Only enable it if it's supported rather than unconitionally. Signed-off-by: Eric Yang <eric.yang2@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit dcf799e54b4633c04b3f9d91ee2980b920916b13 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 23 15:12:48 2016 +0800 drm/amd/powerplay: fix issue that get wrong reference clock value. use wrong parameter to compute the reference clock. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e16ff21d2a694a317b62318822090c5350e58088 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 23 15:04:23 2016 +0800 drm/amd/powerplay: parameter updates according to SMC. Update to latest changes for SMC team. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../drm/amd/powerplay/hwmgr/polaris10_powertune.c | 32 ++++++++++++---------- drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 10 +++---- 2 files changed, 22 insertions(+), 20 deletions(-) commit 9e26bbb36ad6cac78accf959271604449d9ee887 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 23 18:47:29 2016 +0800 drm/amd/powerplay: add fan control mode interface for baffin Add interface for manual fan control. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit f0911de82cc8a809d037c7c1c2df248a4b5f1f8b Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 23 14:50:22 2016 +0800 drm/amd/powerplay: enable some feature for baffin/ellesmere. (v2) Sync up with internal updates. v2: squash in: drm/amd/powerplay: set revert flag for enable thermal protect. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 2 +- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 94 +++++++++++++++++++--- 2 files changed, 83 insertions(+), 13 deletions(-) commit 925a51c442fc2d15da99730d3bc35b3b2cae21b2 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 23 14:48:03 2016 +0800 drm/amdgpu: code style refine. Whitespace fix. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5f88567c625023e85f772481f16b18e9102c6996 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Mar 25 12:23:49 2016 -0400 drm/amd/powerplay: fix copy paste error in error message Noticed-by: Vasily Anonimov <vasily.anonimov@googlemail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ae17c999f0a679aa71577e1a0f488c680aae316c Author: Slava Grigorev <slava.grigorev@amd.com> Date: Tue Mar 22 23:34:29 2016 -0400 drm/amd/amdgpu: fix 64-bit division Signed-off-by: Slava Grigorev <slava.grigorev@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 ++-- drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) commit f89510686c0df375a1116b73c3f24dfbe880a6bc Author: Flora Cui <Flora.Cui@amd.com> Date: Fri Mar 18 19:07:55 2016 +0800 drm/amdgpu: add polaris10/11 smc fw declaration Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 5 +++++ 1 file changed, 5 insertions(+) commit 5de95e55de7ede7a6afd015dc07549be382f9931 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 22 14:21:18 2016 +0800 drm/amd/powerplay: Disable Spread Spectrum on DPM 0 on baffin as SPLL Shut Down feature is enabled. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Acked-by: Flora Cui <Flora.Cui@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 6 ++++++ drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h | 1 + 2 files changed, 7 insertions(+) commit 2043f43e4b176de5c67ee25f863db7fd3835b968 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 15 19:30:00 2016 +0800 drm/amd/powerplay: enable set lowest mclk clock on baffin. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 971f8daafabaca0e06be19c19070c9152cafe0b1 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 15 17:42:47 2016 +0800 drm/amd/powrplay: fix issue that get wrong enable flag. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 3 --- 1 file changed, 3 deletions(-) commit b4c6f99ee7dd12b33a3077d031c1e10c98825f8d Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 15 14:39:12 2016 +0800 drm/amd/powerplay: fix mclk in high clock for baffin Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit b2d96143188cd316035aa83877a75ef433ff7908 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 1 17:01:30 2016 +0800 drm/amd/powerplay: print gpu loading and uvd/vce power gate enablement for polaris10/11. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit 2cc0c0b5cd4d07a65267c28a4f7b68134abff472 Author: Flora Cui <Flora.Cui@amd.com> Date: Mon Mar 14 18:33:29 2016 -0400 drm/amdgpu: change ELM/BAF to Polaris10/Polaris11 Adjust to preferred code names. Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 16 +- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 8 +- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 20 +- drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 6 +- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 16 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 16 +- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 36 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 116 +- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 28 +- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 32 +- drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 6 +- drivers/gpu/drm/amd/amdgpu/vi.c | 22 +- drivers/gpu/drm/amd/include/amd_shared.h | 4 +- drivers/gpu/drm/amd/include/atombios.h | 6 +- drivers/gpu/drm/amd/powerplay/hwmgr/Makefile | 4 +- .../powerplay/hwmgr/ellesmere_clockpowergating.c | 428 - .../powerplay/hwmgr/ellesmere_clockpowergating.h | 40 - .../amd/powerplay/hwmgr/ellesmere_dyn_defaults.h | 62 - .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 4711 --------- .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.h | 354 - .../drm/amd/powerplay/hwmgr/ellesmere_powertune.c | 396 - .../drm/amd/powerplay/hwmgr/ellesmere_powertune.h | 70 - .../drm/amd/powerplay/hwmgr/ellesmere_thermal.c | 711 -- .../drm/amd/powerplay/hwmgr/ellesmere_thermal.h | 62 - drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 8 +- .../powerplay/hwmgr/polaris10_clockpowergating.c | 428 + .../powerplay/hwmgr/polaris10_clockpowergating.h | 40 + .../amd/powerplay/hwmgr/polaris10_dyn_defaults.h | 62 + .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 4844 +++++++++ .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.h | 354 + .../drm/amd/powerplay/hwmgr/polaris10_powertune.c | 396 + .../drm/amd/powerplay/hwmgr/polaris10_powertune.h | 70 + .../drm/amd/powerplay/hwmgr/polaris10_thermal.c | 711 ++ .../drm/amd/powerplay/hwmgr/polaris10_thermal.h | 62 + .../gpu/drm/amd/powerplay/hwmgr/tonga_pptable.h | 10 +- .../amd/powerplay/hwmgr/tonga_processpptables.c | 4 +- .../gpu/drm/amd/powerplay/inc/ellesmere_ppsmc.h | 401 - .../gpu/drm/amd/powerplay/inc/ellesmere_pwrvirus.h | 10088 ------------------- .../gpu/drm/amd/powerplay/inc/polaris10_ppsmc.h | 409 + .../gpu/drm/amd/powerplay/inc/polaris10_pwrvirus.h | 10088 +++++++++++++++++++ drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 42 + drivers/gpu/drm/amd/powerplay/smumgr/Makefile | 2 +- .../drm/amd/powerplay/smumgr/ellesmere_smumgr.c | 983 -- .../drm/amd/powerplay/smumgr/ellesmere_smumgr.h | 68 - .../drm/amd/powerplay/smumgr/polaris10_smumgr.c | 983 ++ .../drm/amd/powerplay/smumgr/polaris10_smumgr.h | 68 + drivers/gpu/drm/amd/powerplay/smumgr/smumgr.c | 8 +- 47 files changed, 18742 insertions(+), 18557 deletions(-) commit a3ad7a9ad8ef2e87ffa7e65d6ce0e9928b4134e9 Author: Flora Cui <Flora.Cui@amd.com> Date: Thu Oct 29 17:32:11 2015 +0800 drm/amdgpu: add ELM/BAF pci ids Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit c0c1f579e6b370b677e529bfc2bb6e310cc6e932 Author: Flora Cui <Flora.Cui@amd.com> Date: Mon Dec 7 18:33:10 2015 +0800 drm/amdgpu: update the core VI support for ELM/BAF Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 + drivers/gpu/drm/amd/amdgpu/vi.c | 87 ++++++++++++++++++++++++++++++ 2 files changed, 89 insertions(+) commit c5a93a282f09a79d86f4299c03fdf032abec7252 Author: Flora Cui <Flora.Cui@amd.com> Date: Fri Feb 26 10:45:25 2016 +0800 drm/amdgpu: ungate SMC clockgating first before suspend 46c34bcb6a15dd85329a39a5e72c62108626acdc put all block’s clockgating support in SMC. The sequence in suspend routine should be adjusted accordingly, otherwise it causes asic hang. Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit f4bfffddd705bc57f92bdd6c96dd04dbe16a90a8 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Tue Feb 16 17:33:14 2016 -0500 drm/amd/amdgpu: add power gating init for Baffin Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 39 +++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) commit 2b6cd9779707f1f7974205320a058ef80aa2cdd4 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu Apr 14 17:26:07 2016 -0400 drm/amd/amdgpu: add power gating initialization support for GFX8.0 Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 14 ++ drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 353 +++++++++++++++++++++++++++++++++- 2 files changed, 364 insertions(+), 3 deletions(-) commit 538333f0dcc00e24ca4bd63905fa75aa41b4c665 Author: Flora Cui <Flora.Cui@amd.com> Date: Mon Feb 15 15:45:59 2016 +0800 drm/amd/powerplay: add default clockgating handling This is to workaround regression introduced in 46c34bcb6a15dd85329a39a5e72c62108626acdc. It should be reverted with a final fix. Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 62a86fc2349b7ae318e91a55aa306a120d233a21 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Feb 12 10:58:51 2016 -0500 drm/amd/amdgpu: add medium grain powergating support for Baffin Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 95 +++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) commit 7df48927b2b804c08022a05ded545b073ba00da7 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Mar 11 14:53:39 2016 -0500 drm/amd/powerplay: add GFX per cu powergating for Baffin Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../powerplay/hwmgr/ellesmere_clockpowergating.c | 28 ++++++++++++++++++++++ .../powerplay/hwmgr/ellesmere_clockpowergating.h | 1 + .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 5 ++++ 3 files changed, 34 insertions(+) commit 65f85e7d8216afe458e7d798ad12e7a82a55162f Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu Feb 11 15:54:45 2016 -0500 drm/amd/powerplay: add GFX per cu powergating support through SMU/powerplay Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 15 ++++++++++++++- drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 1 + 2 files changed, 15 insertions(+), 1 deletion(-) commit bacec8985f596a6c6fadb63966f52501d2ed2367 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu Mar 17 18:29:08 2016 -0400 drm/amd/amdgpu: add query GFX cu info in CGS query system info Needed for per CU powergating. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 5 +++++ drivers/gpu/drm/amd/include/cgs_common.h | 1 + 2 files changed, 6 insertions(+) commit 8fe3d333074911c98877c06233c3e0474866fb63 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Thu Feb 11 11:09:09 2016 -0500 drm/amd/powerplay: add GFX/SYS clockgating support for ELM/BAF Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../powerplay/hwmgr/ellesmere_clockpowergating.c | 247 +++++++++++++++++++++ .../powerplay/hwmgr/ellesmere_clockpowergating.h | 2 + .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 1 + 3 files changed, 250 insertions(+) commit 03e3905f21c03beea8f68f2c4cf94cf36e53b160 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Tue Feb 9 16:26:00 2016 -0500 drm/amd/powerplay: add all blocks clockgating support through SMU/powerplay Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 81 +++++++++++++++++++++++ drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h | 3 + 2 files changed, 84 insertions(+) commit e85c7d664dbf2324990ceb3cd47eaaa4ea8f61fc Author: yanyang1 <Young.Yang@amd.com> Date: Sat Feb 6 13:28:47 2016 +0800 drm/amd/powerplay: update baffin & ellesmere smc_sk firmware. sync the code form catalyst CL:#1230866. Signed-off-by: yanyang1 <Young.Yang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 51 ++++++++++- .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.h | 1 + drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr_ppt.h | 2 + .../gpu/drm/amd/powerplay/hwmgr/tonga_pptable.h | 14 +++ .../amd/powerplay/hwmgr/tonga_processpptables.c | 101 +++++++++++++++------ .../drm/amd/powerplay/smumgr/ellesmere_smumgr.c | 28 ++++-- .../drm/amd/powerplay/smumgr/ellesmere_smumgr.h | 2 + 7 files changed, 162 insertions(+), 37 deletions(-) commit a6ece7ffd9a1de64e7a515552c986468cd569a96 Author: yanyang1 <Young.Yang@amd.com> Date: Fri Feb 5 17:43:17 2016 +0800 drm/amd/powerplay: Add smc_sk firmware to baffin & ellesmere. update relational h files. Signed-off-by: yanyang1 <Young.Yang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/smu_ucode_xfer_vi.h | 1 + drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 10 ++++++++-- drivers/gpu/drm/amd/powerplay/inc/smu_ucode_xfer_vi.h | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) commit 735f002b14b4f532348cabddddc003c7858e8f30 Author: yanyang1 <Young.Yang@amd.com> Date: Fri Feb 5 17:39:37 2016 +0800 drm/amd/amdgpu: Add smc_sk firmware in baffin & ellesmere. add CGS_UCODE_ID_SMU_SK. Signed-off-by: yanyang1 <Young.Yang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 12 +++++++++--- drivers/gpu/drm/amd/include/cgs_common.h | 1 + 2 files changed, 10 insertions(+), 3 deletions(-) commit 92c6d645ee19819dd5b63a171ac7ef7abeb3d21b Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Fri Feb 5 14:47:06 2016 -0500 drm/amd/powerplay: add UVD&VCE DPM and powergating support for elm/baf Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/Makefile | 3 +- .../powerplay/hwmgr/ellesmere_clockpowergating.c | 153 +++++++++++++++++++++ .../powerplay/hwmgr/ellesmere_clockpowergating.h | 37 +++++ .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 91 +++++++++++- .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.h | 4 + 5 files changed, 282 insertions(+), 6 deletions(-) commit eede52627ba1e029f6542fcdf176d7983264d127 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Tue Feb 2 16:09:24 2016 -0500 drm/amd/powerplay: add thermal control for elm/baf Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/Makefile | 2 +- .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 39 +- .../drm/amd/powerplay/hwmgr/ellesmere_thermal.c | 711 +++++++++++++++++++++ .../drm/amd/powerplay/hwmgr/ellesmere_thermal.h | 62 ++ 4 files changed, 801 insertions(+), 13 deletions(-) commit 0ff71753ef91d8dd18c7ccc2a540dd13e36b16aa Author: Rex Zhu <Rex.Zhu@amd.com> Date: Fri Mar 11 14:43:13 2016 -0500 drm/amd/powerplay: enable powerplay for baffin. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c | 2 ++ 1 file changed, 2 insertions(+) commit b83c4ab9caf001a0cefe9f9226a501a9e8ae3f08 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Fri Mar 11 14:39:31 2016 -0500 drm/amd/powerplay: init hwmgr for ELM/BAF Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 5 +++++ 1 file changed, 5 insertions(+) commit a23eefa2f4615af91ea496ca5b55c9e7c6fa934c Author: Rex Zhu <Rex.Zhu@amd.com> Date: Thu Nov 19 18:23:32 2015 +0800 drm/amd/powerplay: enable dpm for baffin. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/Makefile | 3 +- .../amd/powerplay/hwmgr/ellesmere_dyn_defaults.h | 62 + .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.c | 4560 ++++++++++++++++++++ .../gpu/drm/amd/powerplay/hwmgr/ellesmere_hwmgr.h | 349 ++ .../drm/amd/powerplay/hwmgr/ellesmere_powertune.c | 396 ++ .../drm/amd/powerplay/hwmgr/ellesmere_powertune.h | 70 + drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.c | 111 +- drivers/gpu/drm/amd/powerplay/hwmgr/ppatomctrl.h | 40 +- 8 files changed, 5581 insertions(+), 10 deletions(-) commit c81726252ec99f375a226005b4e0277df3601d66 Author: rezhu <Rex.Zhu@amd.com> Date: Tue Nov 10 10:26:39 2015 +0800 drm/amd/powerplay: add smu support for ellesmere/baffin Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 11 +- drivers/gpu/drm/amd/powerplay/smumgr/Makefile | 2 +- .../drm/amd/powerplay/smumgr/ellesmere_smumgr.c | 969 +++++++++++++++++++++ .../drm/amd/powerplay/smumgr/ellesmere_smumgr.h | 66 ++ drivers/gpu/drm/amd/powerplay/smumgr/smumgr.c | 5 + 5 files changed, 1050 insertions(+), 3 deletions(-) commit b304ac83eee5569997ae83e090fd980ca8e24cba Author: rezhu <Rex.Zhu@amd.com> Date: Mon Nov 16 10:33:31 2015 +0800 drm/amd/powerplay: add header files for ellesmere smu manager. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/powerplay/inc/ellesmere_ppsmc.h | 401 + .../gpu/drm/amd/powerplay/inc/ellesmere_pwrvirus.h | 10088 +++++++++++++++++++ drivers/gpu/drm/amd/powerplay/inc/smu74.h | 774 ++ drivers/gpu/drm/amd/powerplay/inc/smu74_discrete.h | 780 ++ 4 files changed, 12043 insertions(+) commit 1b4eeea5f79d276e41355f3860052b046cb55f2a Author: Sonny Jiang <sonny.jiang@amd.com> Date: Fri Mar 11 14:33:40 2016 -0500 drm/amdgpu: add VCE support to ELM/BAF Ellesmere and Baffin are VCE 3.4 Signed-off-by: Sonny Jiang <sonny.jiang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 10 ++++++++++ drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 6 ++++-- 2 files changed, 14 insertions(+), 2 deletions(-) commit 38d7581764950831818b2a3b28d2e70f98d364f2 Author: Sonny Jiang <sonny.jiang@amd.com> Date: Thu Nov 5 15:17:18 2015 -0500 drm/amdgpu: add UVD support for ELM/BAF Ellesmere and Baffin are UVD 6.3 Signed-off-by: Sonny Jiang <sonny.jiang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 68182d909b78a0e628eb6e05218fa6db585e7b1d Author: Flora Cui <Flora.Cui@amd.com> Date: Thu Oct 29 17:26:56 2015 +0800 drm/amdgpu: add GFX support for ELM/BAF V2: use gfx_8_0_*.h instead of gfx_8_1_*.h v3: agd: integrate support for gfx info table Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 555 +++++++++++++++++++++++++++++++++- 1 file changed, 551 insertions(+), 4 deletions(-) commit d7120b8f227bd0aaa87f10861848faff47eed7af Author: Flora Cui <Flora.Cui@amd.com> Date: Thu Nov 5 12:42:59 2015 +0800 drm/amdgpu: add mmRLC_CGCG_CGLS_CTRL_3D & mmRLC_CGCG_RAMP_CTRL_3D Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/include/asic_reg/gca/gfx_8_0_d.h | 2 ++ 1 file changed, 2 insertions(+) commit 397a270effb01ee938a441327ae6dee732e8f653 Author: Alex Deucher <alexander.deucher@amd.com> Date: Mon Mar 14 16:51:24 2016 -0400 drm/amdgpu: add an interface to get gfx constants from atombios Fetch the values from atom rather than hardcoding them in the driver. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_atombios.c | 30 ++++++++++++++++++++++++++++ drivers/gpu/drm/amd/amdgpu/amdgpu_atombios.h | 2 ++ 2 files changed, 32 insertions(+) commit 2cea03de1040a749b2868a8a2b0c0636281c166b Author: Flora Cui <Flora.Cui@amd.com> Date: Thu Oct 29 17:26:22 2015 +0800 drm/amdgpu: add SDMA support for ELM/BAF V2: seperate baffin & ellesmere settings instead of using fiji ones. Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 47 ++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) commit 60909285ef3fc62984cdcdb8e34e88fcf43c5aba Author: Flora Cui <Flora.Cui@amd.com> Date: Thu Oct 29 17:25:48 2015 +0800 drm/amdgpu: add DCE golden setting for ELM/BAF Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit c9778572e9544b798281d57fcc92cc6a76f6a399 Author: Flora Cui <Flora.Cui@amd.com> Date: Fri Mar 11 14:28:53 2016 -0500 drm/amdgpu: add GMC support for ELM/BAF V2: add golden_settings_baffin_a11 instead of reuse golden_settings_fiji_a10 Signed-off-by: Flora Cui <Flora.Cui@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit b18e6ad7816f340cfa001a5ca26fecc6ba5dac54 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 17:14:31 2015 -0400 drm/amdgpu/dce11: add dce clock setting for ELM/BAF Setup the disp clock and dp reference clock. This is now a separate command table on elm/baf compared to older asics. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 22f0c5bd14f6cc8d60dbfc736f632fc891f1b0f9 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 16:35:33 2015 -0400 drm/amdgpu/dce11: update pll programming for ELM/BAF SetPixelClock table handles pll divider calculation and spread spectrum setup, so no need to use calculate the dividers and call the ss enable cmd table. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) commit 927a81c98eb69d5330c9e42ae9cacdc9d8b96afb Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 15:21:09 2015 -0400 drm/amdgpu: add ELM/BAF support to dce_v11_0_pick_pll (v2) New PLL scheme on ELM/BAF. v2: squash in pll fix. Plls are part of the phys. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 38 ++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit d031287a43937bdde9d74c657b78edf1c66e286e Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 15:08:30 2015 -0400 drm/amdgpu/atom: add support for new UNIPHYTransmitterContol cmd table New uniphy transmitter setup table for elm/baf. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/atombios_encoders.c | 51 +++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) commit 4b5844e8bf7a791682ce650d55d2fef6a69ce10d Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 14:49:53 2015 -0400 drm/amdgpu/atom: add support for new DIGxEncoderControl cmd table New digital encoder setup table for elm/baf. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/atombios_encoders.c | 42 ++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit ee681c9aa21dea6729871cc55ff1514f2185600b Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 02:05:31 2015 -0400 drm/amdgpu/atom: add support for new SetPixelClock table New version of the SetPixelClock table for elm/baf. The new table calculates the pll dividers and handles spread spectrum calculations and setup. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/atombios_crtc.c | 53 +++++++++++++++++++++++------- 1 file changed, 41 insertions(+), 12 deletions(-) commit 541cd55557a669b8cebcfd4e1393adde645b5890 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 01:24:49 2015 -0400 drm/amdgpu/atom: add SetDCEClock helper New cmd table for ELM/BAF for setting the dispclock or dprefclock. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/atombios_crtc.c | 45 +++++++++++++++++++++++++++++- drivers/gpu/drm/amd/amdgpu/atombios_crtc.h | 2 ++ 2 files changed, 46 insertions(+), 1 deletion(-) commit 6e14e92b3d419a00be6cafa53b0939c7b347c46a Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Oct 15 00:43:41 2015 -0400 drm/amdgpu: update atombios.h (v2) update to internal version 893 v2: Pull in gfx_info changes from 898 Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/include/atombios.h | 663 ++++++++++++++++++++++++++++++--- 1 file changed, 619 insertions(+), 44 deletions(-) commit 2238445925467024de1306500de00b3c0eb1ac1f Author: Alex Deucher <alexander.deucher@amd.com> Date: Mon Apr 18 18:25:34 2016 -0400 drm/amdgpu: bump the afmt limit for CZ, ST, Polaris Fixes array overflow on these chips. Reviewed-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f195038c7ea5ae161652701de6ad7416fbe44d50 Author: Alex Deucher <alexander.deucher@amd.com> Date: Mon Apr 18 18:09:57 2016 -0400 drm/amdgpu: use defines for CRTCs and AMFT blocks Prerequiste for the next patch which ups the limits. Reviewed-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d525eb8d2e678b1a9735d01241fd1bc8feb836b9 Author: Alex Deucher <alexander.deucher@amd.com> Date: Wed Oct 14 17:17:15 2015 -0400 drm/amdgpu: add ELM/BAF DCE11 configs (v2) Add support for the display configuration on elm/baf. v2: add missing Stoney case Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) commit b81223001f686a537c3f6e26c83037b365046612 Author: Alex Deucher <alexander.deucher@amd.com> Date: Wed Oct 14 17:14:16 2015 -0400 drm/amdgpu: add ELM/BAF asic types New asic types for ellesmere and baffin. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++ drivers/gpu/drm/amd/include/amd_shared.h | 2 ++ 2 files changed, 4 insertions(+) commit 7edbb0d389ccad68a75a2dcdbeb682014f1ccffe Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Mar 11 14:46:46 2016 -0500 drm/amd: add DCE 11.2 register headers Add register headers for DCE (Display and Composition Engine) 11.2. Reviewed-by: Ken Wang <Qingqing.Wang@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../gpu/drm/amd/include/asic_reg/dce/dce_11_2_d.h | 10075 ++++++++++ .../drm/amd/include/asic_reg/dce/dce_11_2_enum.h | 6813 +++++++ .../amd/include/asic_reg/dce/dce_11_2_sh_mask.h | 18687 +++++++++++++++++++ 3 files changed, 35575 insertions(+) commit 3d02b7fee9c3ece1746f5b06c4143b511383fc6b Author: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Date: Fri Apr 15 02:47:49 2016 +0200 drm/radeon: Allow setting shader registers using DMA/COPY packet3 on SI. Mesa uses a COPY_DATA packet to copy the grid size for indirect dispatches into COMPUTE_USER_DATA_*. Setting those registers with a SET_SH_REG packet is allowed, not allowing them with other packets seems like an oversight. v2: Clarify commit message. Signed-off-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon_drv.c | 3 ++- drivers/gpu/drm/radeon/si.c | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) commit b76af4a41927994e130500659866efbd992deb9d Author: Christian König <christian.koenig@amd.com> Date: Fri Apr 15 17:19:17 2016 +0200 drm/amdgpu: remove sorting of CS BOs Not needed any more. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 23 ----------------------- 1 file changed, 23 deletions(-) commit 29b3259a3ab98f4823f3227de1ae695f3f7bc751 Author: Christian König <christian.koenig@amd.com> Date: Fri Apr 15 17:19:16 2016 +0200 drm/amdgpu: group BOs by log2 of the size on the LRU v2 This allows us to have small BOs on the LRU before big ones. v2: fix of by one and list corruption bug Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 11 ++++++ drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 61 +++++++++++++++++++++++++++++++-- 2 files changed, 70 insertions(+), 2 deletions(-) commit 1359d6e494455d9314a3c59f5d5d459c13e11ef0 Author: Dave Airlie <airlied@redhat.com> Date: Thu Apr 14 09:49:16 2016 +1000 drm/amdgpu: drop apply quirks for now. This isn't being used so drop it. Reviewed-by: Harry Wentland <harry.wentland@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_atombios.c | 15 --------------- 1 file changed, 15 deletions(-) commit 178d7cb8d576ff837fea8e1b6460c769297615ec Author: Chunming Zhou <David1.Zhou@amd.com> Date: Thu Apr 14 15:53:55 2016 +0800 drm/amdgpu: fix error checking when reuse vmid on same ring Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 68befebee4927036b0f350825a20d46104f375b5 Author: Chunming Zhou <David1.Zhou@amd.com> Date: Thu Apr 14 13:42:32 2016 +0800 drm/amdgpu: only update last_flush when vmid doesn't have other new owner Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 15 ++++++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) commit 66067ad73c384a1780421e48a72a69b393359aa7 Author: Chunming Zhou <David1.Zhou@amd.com> Date: Thu Apr 14 10:27:28 2016 +0800 drm/amdgpu: double fence slot we introduced vmid fence, so one hw submission could produce two fences. Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1bf912ffa611bc91522f6e524568b747db6f4c9c Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:40:49 2016 -0400 drm/amdgpu: enable sdma clockgating on ST Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6f17a257d3936c728cffde46e4a1f17bb9a59ab6 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:39:54 2016 -0400 drm/amdgpu: enable sdma clockgating on CZ Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit ce22362b79acd5483082cab477db288925aac51f Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:19:39 2016 -0400 drm/amdgpu/sdma: rename fiji cg functions They care common for all sdma 3.0 parts Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 104 +++++++++++++-------------------- 1 file changed, 39 insertions(+), 65 deletions(-) commit b6711d1b88fea8ea663172d1d0d6721f48a846bf Author: Alex Deucher <alexander.deucher@amd.com> Date: Wed Apr 13 12:41:50 2016 -0400 drm/amdgpu: enable gmc clockgating for ST Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 03c335d3d505b77bac5cba37d49d4a098a383563 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:26:46 2016 -0400 drm/amdgpu: enable gmc clockgating for CZ Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 76f10b9adae111d98ee1161d37e97651cef9d825 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 01:37:44 2016 -0400 drm/amdgpu/vi: rename fiji cg functions They can be used for other VI parts. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 33 +++++++++++++++++++++------------ 1 file changed, 21 insertions(+), 12 deletions(-) commit 64694905675e9c8b47ae8ade60b8fd4177a61956 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 7 23:17:15 2016 -0400 drm/amdgpu: enable gfx clockgating for ST (v2) v2: just enable MGCG for now since CGCG causes hangs Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 70eced9b2e05f38274ebe8ad91c472bb684fa82a Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 7 23:01:48 2016 -0400 drm/amdgpu: enable gfx clockgating for CZ Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit dbff57bc7b6f80e95458a913441e24741e659abc Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 7 22:57:39 2016 -0400 drm/amdgpu/gfx: rework fiji cg functions so they can be shared They can be shared with other asics with minor modifications. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 218 +++++++++++++++++++++++++++++++--- 1 file changed, 202 insertions(+), 16 deletions(-) commit 79e5412c58ef7bfdc54d1bb85b63c6c8e6d2c3f7 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 15:45:13 2016 -0400 drm/amdgpu: add a new set of rlc function pointers Different asics tend to have different ways to interact with the RLC. This just covers enter/exit of safe mode for updating CG and PG state, but could be extended to cover other RLC operations in the future if necessary. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit 146f256faea7762d42c1b2aae14b816a92f2eb10 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 7 23:16:00 2016 -0400 drm/amdgpu/gfx: adjust gfx_v8_0_send_serdes_cmd for ST Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) commit 79deaaf4a9eb3fd2ba92616a5212564fd6ae06a1 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 01:12:20 2016 -0400 drm/amdgpu/gfx8: rename send_serdes_cmd So it can be shared with CZ/ST. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 3fde56b8dbed354c54651d0566c9719106d024f7 Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 01:01:18 2016 -0400 drm/amdgpu/gmc: add proper CG flags for fiji We were already enabling these CG features, this uses the standard interface for doing so. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 8 ++++---- drivers/gpu/drm/amd/amdgpu/vi.c | 4 +++- 2 files changed, 7 insertions(+), 5 deletions(-) commit c90766cf4e78e4708111afe5011a00288e60c66e Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:52:58 2016 -0400 drm/amdgpu/common: add proper CG flags for fiji We were already enabling these CG features, this uses the standard interface for doing so. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) commit e08d53cb6943b9b263021320523629005c1f512f Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:42:51 2016 -0400 drm/amdgpu/sdma: add proper CG flags for fiji We were already enabling these CG features, this uses the standard interface for doing so. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/vi.c | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) commit 14698b6c7987bafff1d8942a820c1b569fbb7444 Author: Alex Deucher <alexander.deucher@amd.com> Date: Thu Apr 7 18:38:00 2016 -0400 drm/amdgpu/gfx: add proper CG flags for fiji We were already enabling these CG features, this uses the standard interface for doing so. Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 82 ++++++++++++++++++++--------------- drivers/gpu/drm/amd/amdgpu/vi.c | 9 +++- 2 files changed, 56 insertions(+), 35 deletions(-) commit 4fae91c5e29b920a37afab3e432c4b72a9fbe90d Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 00:52:24 2016 -0400 drm/amdgpu: add new CG flag for ROM clockgating Acked-by: Tom St Denis <tom.stdenis@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/include/amd_shared.h | 1 + 1 file changed, 1 insertion(+) commit 98c2872ae99bb7c9e8e4369cf48154f41dd6a109 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:07 2016 +0200 drm/ttm: implement LRU add callbacks v2 This allows fine grained control for the driver where to add a BO into the LRU. v2: fix typo in comment Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 2 ++ drivers/gpu/drm/ast/ast_ttm.c | 2 ++ drivers/gpu/drm/bochs/bochs_mm.c | 2 ++ drivers/gpu/drm/cirrus/cirrus_ttm.c | 2 ++ drivers/gpu/drm/mgag200/mgag200_ttm.c | 2 ++ drivers/gpu/drm/nouveau/nouveau_bo.c | 2 ++ drivers/gpu/drm/qxl/qxl_ttm.c | 2 ++ drivers/gpu/drm/radeon/radeon_ttm.c | 2 ++ drivers/gpu/drm/ttm/ttm_bo.c | 29 ++++++++++++++++++++--------- drivers/gpu/drm/virtio/virtgpu_ttm.c | 2 ++ drivers/gpu/drm/vmwgfx/vmwgfx_buffer.c | 2 ++ include/drm/ttm/ttm_bo_driver.h | 9 +++++++++ 12 files changed, 49 insertions(+), 9 deletions(-) commit c3ea576e0583bb0537cdd66b704e49d380427721 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:06 2016 +0200 drm/ttm: add optional LRU removal callback v2 Useful for driver specific LRU handling. v2: fix typo in comment Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/ttm/ttm_bo.c | 12 +++++++----- include/drm/ttm/ttm_bo_driver.h | 6 ++++++ 2 files changed, 13 insertions(+), 5 deletions(-) commit 00cfd664f6dc197d86051e3db95c3609ef38394f Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:05 2016 +0200 drm/ttm: remove unused validation sequence Not used any more. Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/ttm/ttm_bo.c | 1 - include/drm/ttm/ttm_bo_driver.h | 2 -- 2 files changed, 3 deletions(-) commit 8aa6d4fc5f470c5e4363c705bbae96ccb1b033b0 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:04 2016 +0200 drm/ttm: remove lazy parameter from ttm_bo_wait Not used any more. Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/nouveau/nouveau_bo.c | 2 +- drivers/gpu/drm/nouveau/nouveau_gem.c | 4 ++-- drivers/gpu/drm/qxl/qxl_cmd.c | 2 +- drivers/gpu/drm/qxl/qxl_object.h | 2 +- drivers/gpu/drm/radeon/radeon_object.c | 2 +- drivers/gpu/drm/ttm/ttm_bo.c | 16 ++++++++-------- drivers/gpu/drm/ttm/ttm_bo_util.c | 2 +- drivers/gpu/drm/ttm/ttm_bo_vm.c | 6 +++--- drivers/gpu/drm/virtio/virtgpu_object.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_buffer.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_cotable.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_resource.c | 4 ++-- include/drm/ttm/ttm_bo_api.h | 2 +- 13 files changed, 24 insertions(+), 24 deletions(-) commit dfd5e50ea43ca4a89de061fb69618299760eb682 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:03 2016 +0200 drm/ttm: remove use_ticket parameter from ttm_bo_reserve Not used any more. Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_object.h | 2 +- drivers/gpu/drm/ast/ast_drv.h | 2 +- drivers/gpu/drm/bochs/bochs_fbdev.c | 2 +- drivers/gpu/drm/bochs/bochs_kms.c | 4 ++-- drivers/gpu/drm/cirrus/cirrus_drv.h | 2 +- drivers/gpu/drm/mgag200/mgag200_drv.h | 2 +- drivers/gpu/drm/nouveau/nouveau_bo.c | 6 +++--- drivers/gpu/drm/nouveau/nouveau_display.c | 4 ++-- drivers/gpu/drm/nouveau/nouveau_gem.c | 6 +++--- drivers/gpu/drm/qxl/qxl_object.h | 4 ++-- drivers/gpu/drm/radeon/radeon_object.c | 2 +- drivers/gpu/drm/radeon/radeon_object.h | 2 +- drivers/gpu/drm/ttm/ttm_bo.c | 17 ++++++++--------- drivers/gpu/drm/ttm/ttm_bo_vm.c | 2 +- drivers/gpu/drm/ttm/ttm_execbuf_util.c | 3 +-- drivers/gpu/drm/virtio/virtgpu_drv.h | 2 +- drivers/gpu/drm/virtio/virtgpu_object.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_cotable.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_dmabuf.c | 8 ++++---- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 6 +++--- drivers/gpu/drm/vmwgfx/vmwgfx_mob.c | 12 ++++++------ drivers/gpu/drm/vmwgfx/vmwgfx_resource.c | 7 +++---- drivers/gpu/drm/vmwgfx/vmwgfx_shader.c | 2 +- include/drm/ttm/ttm_bo_driver.h | 14 +++++--------- 25 files changed, 55 insertions(+), 62 deletions(-) commit 5ee7b41a8b83e5d73d8b0725561ba43de5cb9443 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 6 11:12:02 2016 +0200 drm/ttm: don't wait for BO on initial allocation When we use an extern reservation object that otherwise waits for every fence registered with it. Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/ttm/ttm_bo.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) commit eb4309690061abe21bb37b09692e57ca4fca0968 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 13 11:36:00 2016 +0200 drm/amdgpu: fix the coding style in amdgpu_ring.c No functional change. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 771c8ec1775774a05f8e5e456bd4848d845543de Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 13 11:34:44 2016 +0200 drm/amdgpu: use the ring name for debugfs (v2) Instead of hard coding just another name in the ring code. v2: squash in Tom's rebase fix Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 56 +++++++++++++------------------- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 2 +- 3 files changed, 25 insertions(+), 35 deletions(-) commit b38d99c4f46128c97b523f04a3a5fb705a5c55e1 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 13 10:30:13 2016 +0200 drm/amdgpu: reduce the ring size for SDMA Those are way too large. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 +- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 +- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 2800de2e9edc5a7f012300945b534b3b57710778 Author: Christian König <christian.koenig@amd.com> Date: Wed Apr 13 10:27:35 2016 +0200 drm/amdgpu: reduce the ring size for GFX Those are way too large. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit a3f1cf355e90e144f012cbb0472a6701dd832841 Author: Christian König <christian.koenig@amd.com> Date: Tue Apr 12 16:26:34 2016 +0200 drm/amdgpu: use max_dw in ring_init Instead of specifying the total ring size calculate that from the maximum number of dw a submission can have and the number of concurrent submissions. This fixes UVD with 8 concurrent submissions or more. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 14 +++++--------- drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 +- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 4 ++-- 10 files changed, 18 insertions(+), 22 deletions(-) commit 9331b9ca813960ed05004821a771aa3a82db187c Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Mon Apr 11 14:28:55 2016 -0400 drm/amd/powerplay: fix fan speed percent setting error on Fiji Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_thermal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d9624f8c68845112007da4aa6492120ce25b89ba Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Mon Apr 11 14:27:51 2016 -0400 drm/amd/powerplay: fix fan speed percent setting error on Tonga Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_thermal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 85621630f1cdc4ee50fca0bb2eddfd44208d9a45 Author: Felix Kuehling <Felix.Kuehling@amd.com> Date: Thu Apr 7 21:42:17 2016 -0400 drm/ttm: Fix TTM BO accounting TTM BO accounting is out of sync with how memory is really allocated in ttm[_dma]_tt_alloc_page_directory. This resulted in excessive estimated overhead with many small allocations. ttm_dma_tt_alloc_page_directory makes a single allocation for three arrays: pages, DMA and CPU addresses. It uses drm_calloc_large, which uses kmalloc internally for allocations smaller than PAGE_SIZE. ttm_round_pot should be a good approximation of its memory usage both above and below PAGE_SIZE. Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com> Reviewed-by: Monk Liu <monk.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/ttm/ttm_bo.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 110e6f26af80dfd90b6e5c645b1aed7228aa580d Author: Dave Airlie <airlied@redhat.com> Date: Tue Apr 12 13:25:48 2016 +1000 drm/amd: make a type-safe cgs_device struct. (v2) This is just a type-safety things to avoid everyone taking void *, it doesn't change anything. v2: agd5f: split out the dal changes into a separate patch. Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/acp/acp_hw.c | 2 +- drivers/gpu/drm/amd/acp/include/acp_gfx_if.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 11 +--- drivers/gpu/drm/amd/amdgpu/amdgpu_acp.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 92 ++++++++++++++-------------- drivers/gpu/drm/amd/include/cgs_common.h | 76 ++++++++++++----------- drivers/gpu/drm/amd/include/cgs_linux.h | 6 +- 7 files changed, 93 insertions(+), 98 deletions(-) commit c036554170fcc2238c32a7edd72c1b61b886428a Author: Arindam Nath <arindam.nath@amd.com> Date: Tue Apr 12 13:46:15 2016 +0200 drm/amdgpu: handle more than 10 UVD sessions (v2) Change History -------------- v2: - Make firmware version check correctly. Firmware versions >= 1.80 should all support 40 UVD instances. - Replace AMDGPU_MAX_UVD_HANDLES with max_handles variable. v1: - The firmware can handle upto 40 UVD sessions. Signed-off-by: Arindam Nath <arindam.nath@amd.com> Signed-off-by: Ayyappa Chandolu <ayyappa.chandolu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 11 +++++--- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 30 ++++++++++++++++------ drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 5 ++-- drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 5 ++-- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 7 +++-- .../gpu/drm/amd/include/asic_reg/uvd/uvd_6_0_d.h | 1 + 6 files changed, 41 insertions(+), 18 deletions(-) commit aeba709a15ad66d3f8a2b38bada9f643ebe3dc04 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 10 16:30:04 2016 +0200 drm/amd: make some function-local tables static const These tables were initialized on stack on each call, avoid that and save a little bit of text size. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_benchmark.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_connectors.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/ppevvmath.h | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) commit e90b62277b17207fa3854c4d8c3763d9974e7f47 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 10 16:30:03 2016 +0200 drm/amd/powerplay: mark phm_master_table_* structs as const Also adjust phm_construct_table to take a const pointer Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../drm/amd/powerplay/hwmgr/cz_clockpowergating.c | 4 ++-- .../drm/amd/powerplay/hwmgr/cz_clockpowergating.h | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/cz_hwmgr.c | 20 ++++++++++---------- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_thermal.c | 8 ++++---- drivers/gpu/drm/amd/powerplay/hwmgr/functiontables.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_thermal.c | 8 ++++---- drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 4 ++-- 7 files changed, 24 insertions(+), 24 deletions(-) commit d3a84aa07445d7edb7f496cd41fdb27ed2653fad Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 10 16:30:02 2016 +0200 drm/amd/powerplay: Mark pem_event_action chains as const As these arrays were of pointer to pointer type, they were pointer to pointer to const. Make them pointer to const pointer to const. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> .../drm/amd/powerplay/eventmgr/eventactionchains.c | 34 +++++++++++----------- .../drm/amd/powerplay/eventmgr/eventmanagement.c | 2 +- drivers/gpu/drm/amd/powerplay/inc/eventmgr.h | 2 +- 3 files changed, 19 insertions(+), 19 deletions(-) commit 06ab6832ac06c77332e3b0415977acf68ea364cf Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Mon May 2 12:46:15 2016 -0400 drm/amdgpu: Mark all instances of struct drm_info_list as const All these are compile time constand and the drm_debugfs_create/remove_files functions take a const pointer argument. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) commit 62250a910a4090f88b729e04baf4369d78ba5bdc Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 10 16:30:00 2016 +0200 drm/amd/scheduler: Mark amdgpu_sched_ops const This marks the struct amdgpu_sched_ops const and adjusts amd_sched_init to take a const pointer for the ops param. The ops member of struct amd_gpu_scheduler is also changed to const. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 2 +- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 2 +- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) commit f498d9ed26fdfa2694ef3d892f032c7dc6feba14 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sun Apr 10 16:29:59 2016 +0200 drm/amd: Mark some tables as const This patch marks some compile-time constant tables 'const'. The tables marked in this patch are the low hanging fruit where little other changes were necesary to avoid casting away constness etc. Also mark some tables that are private to a file as static. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 12 ++++++------ drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.h | 2 +- drivers/gpu/drm/amd/powerplay/hwmgr/fiji_powertune.c | 10 +++++----- drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 8 ++++---- drivers/gpu/drm/amd/powerplay/inc/fiji_pwrvirus.h | 2 +- drivers/gpu/drm/amd/powerplay/smumgr/cz_smumgr.c | 2 +- drivers/gpu/drm/amd/powerplay/smumgr/fiji_smumgr.c | 6 +++--- drivers/gpu/drm/amd/powerplay/smumgr/tonga_smumgr.c | 2 +- 13 files changed, 29 insertions(+), 29 deletions(-) commit 7e8d1fbdc09925db416f7ea8650ee05e7909e3fa Author: Alex Deucher <alexander.deucher@amd.com> Date: Fri Apr 8 16:42:38 2016 -0400 drm/amd/powerplay: fix stutter setup in mclk level init Stale ifdef. Reviewed-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 8c4f2bbd66784f00a509bf0787aa16b19ceaa6c7 Author: Dave Airlie <airlied@redhat.com> Date: Thu Apr 7 06:50:25 2016 +1000 drm/radeon: add support for SET_APPEND_CNT packet3 (v2) This adds support to the command parser for the set append counter packet3, this is required to support atomic counters on evergreen/cayman GPUs. v2: fixup some of the hardcoded numbers with real register names (Christian) Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/evergreen_cs.c | 45 +++++++++++++++++++++++++++++++++++ drivers/gpu/drm/radeon/evergreend.h | 43 +++++++++++++++++++++++++++++++++ drivers/gpu/drm/radeon/radeon_drv.c | 3 ++- 3 files changed, 90 insertions(+), 1 deletion(-) commit 8b2cf4f5758f172d0980688383cea83241dc59e6 Author: Arindam Nath <arindam.nath@amd.com> Date: Wed Apr 6 15:33:52 2016 -0400 drm/radeon: handle more than 10 UVD sessions Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Arindam Nath <arindam.nath@amd.com> Reviewed-by: Leo Liu <leo.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/cikd.h | 1 + drivers/gpu/drm/radeon/radeon.h | 9 ++++++--- drivers/gpu/drm/radeon/radeon_uvd.c | 33 +++++++++++++++++++++++++-------- drivers/gpu/drm/radeon/uvd_v1_0.c | 5 +++-- drivers/gpu/drm/radeon/uvd_v2_2.c | 5 +++-- drivers/gpu/drm/radeon/uvd_v4_2.c | 8 ++++++-- 6 files changed, 44 insertions(+), 17 deletions(-) commit 7050c6ef5f0e9bc5e6bf9eb035320b70f731b919 Author: Arindam Nath <arindam.nath@amd.com> Date: Wed Apr 6 15:33:51 2016 -0400 drm/radeon: add support for loading new UVD fw Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Arindam Nath <arindam.nath@amd.com> Reviewed-by: Leo Liu <leo.liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 1 + drivers/gpu/drm/radeon/radeon_uvd.c | 55 +++++++++++++++++++++++++++---------- drivers/gpu/drm/radeon/uvd_v4_2.c | 8 +++++- 3 files changed, 49 insertions(+), 15 deletions(-) commit 794f50b95d40bbde905c3c4c514a33fdda54f497 Author: Christian König <christian.koenig@amd.com> Date: Wed Mar 9 22:11:53 2016 +0100 drm/amdgpu: reuse VMIDs already assigned to a process If we don't need to flush we can easily use another VMID already assigned to the process. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 77 ++++++++++++++++++++-------------- 1 file changed, 46 insertions(+), 31 deletions(-) commit 41d9eb2c5a2a21c9120e906d077e77562883510e Author: Christian König <christian.koenig@amd.com> Date: Tue Mar 1 16:46:18 2016 +0100 drm/amdgpu: add a fence after the VM flush This way we can track when the flush is done. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 11 ++++++----- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 12 ++++++++---- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 26 +++++++++++++++++++++----- 3 files changed, 35 insertions(+), 14 deletions(-) commit 832a902f9433b812f829e9f2257daf5d518cf0de Author: Christian König <christian.koenig@amd.com> Date: Mon Feb 15 12:33:02 2016 +0100 drm/amdgpu: use a sync object for VMID fences v2 v2: rebase & cleanup This way we can store more than one fence as user for each VMID. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> (v1) Reviewed-by: Chunming Zhou <david1.zhou@amd.com> (v1) Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 6 +- drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c | 105 +++++++++++++++++++++++++++++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 53 ++++++++-------- 3 files changed, 132 insertions(+), 32 deletions(-) commit bcb1ba35a87be34d1312f6e050f1b5cc4d32f096 Author: Christian König <christian.koenig@amd.com> Date: Tue Mar 8 15:40:11 2016 +0100 drm/amdgpu: merge VM manager and VM context ID structure No need to have two of them any more. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 17 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 139 +++++++++++++++++---------------- 2 files changed, 78 insertions(+), 78 deletions(-) commit bd4c72d1e9dd7efdb9a990225f32e0130c0884af Author: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com> Date: Wed Mar 30 17:34:27 2016 -0400 drm/amdgpu: Set PFLIP_SUBMITTED for crtc after address update Also add some pflip debug prints. This change allows us to wait on pflip status until the new surface address is actually submitted to the register. This reverts ed3020e923240829dcdfd3343f6e91dc02c63775 drm/amdgpu: Move MMIO flip out of spinlocked region The original change assumed DAL will aquire locks inside DAL implemetion of page_flip callback which eventaully didn't happen. This moves the flip before status update which makes sense for the non-DAL code pathes as well. Signed-off-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit c63dd758589b1f7e8398841d1f443f06ebfbcefc Author: Michel Dänzer <michel.daenzer@amd.com> Date: Fri Apr 1 18:51:34 2016 +0900 drm/radeon: Support DRM_MODE_PAGE_FLIP_ASYNC When this flag is set, we program the hardware to execute the flip during horizontal blank (i.e. for the next scanline) instead of during vertical blank (i.e. for the next frame). Currently this is only supported on ASICs which have a page flip completion interrupt (>= R600), and only if the use_pflipirq parameter has value 2 (the default). Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/atombios_crtc.c | 24 +++++++++++------------- drivers/gpu/drm/radeon/evergreen.c | 5 ++++- drivers/gpu/drm/radeon/r100.c | 2 +- drivers/gpu/drm/radeon/radeon.h | 5 +++-- drivers/gpu/drm/radeon/radeon_asic.h | 9 +++++---- drivers/gpu/drm/radeon/radeon_display.c | 6 +++++- drivers/gpu/drm/radeon/rs600.c | 4 +++- drivers/gpu/drm/radeon/rv770.c | 4 +++- 8 files changed, 35 insertions(+), 24 deletions(-) commit a4333b4c9960a8f8d699910d4ae11c5eaefd8c25 Author: Eric Huang <JinHuiEric.Huang@amd.com> Date: Wed Mar 30 16:30:12 2016 -0400 drm/amd/powerplay: add deep sleep divider id into DPM table on Tonga Add a proper implementation for setting the deep sleep divider. Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/tonga_hwmgr.c | 29 +++++++++++++++++++---- 1 file changed, 24 insertions(+), 5 deletions(-) commit 21daaeee9f55ee407422ad225790dee57f0d5171 Merge: 4946dd2 6d3e7fd Author: Dave Airlie <airlied@redhat.com> Date: Thu May 5 09:56:30 2016 +1000 Merge tag 'topic/drm-misc-2016-05-04' of git://anongit.freedesktop.org/drm-intel into drm-next Ofc I promise just a few leftovers for drm-misc and somehow it's the biggest pull. But really mostly trivial stuff: - MAINTAINERS updates from Emil - rename async to nonblock in atomic_commit to avoid the confusion between nonblocking ioctl and async flip (= not vblank synced), from Maarten. Needs to be regened with newer drivers, but probably only after -rc1 to catch them all. - actually lockless gem_object_free, plus acked driver conversion patches. All the trickier prep stuff already is in drm-next. - Noralf's nice work for generic defio support in our fbdev emulation. Keeps the udl hack, and qxl is tested by Gerd. * tag 'topic/drm-misc-2016-05-04' of git://anongit.freedesktop.org/drm-intel: (47 commits) drm: Fixup locking WARN_ON mistake around gem_object_free_unlocked drm/etnaviv: Use lockless gem BO free callback drm/imx: Use lockless gem BO free callback drm/radeon: Use lockless gem BO free callback drm/amdgpu: Use lockless gem BO free callback drm/gem: support BO freeing without dev->struct_mutex MAINTAINERS: Add myself for the new VC4 (RPi GPU) graphics driver. MAINTAINERS: Add a bunch of legacy (UMS) DRM drivers MAINTAINERS: Add a few DRM drivers by Dave Airlie MAINTAINERS: List the correct git repo for the Renesas DRM drivers MAINTAINERS: Update the files list for the Renesas DRM drivers MAINTAINERS: Update the files list for the Armada DRM driver MAINTAINERS: Update the files list for the Rockchip DRM driver MAINTAINERS: Update the files list for the Exynos DRM driver MAINTAINERS: Add maintainer entry for the VMWGFX DRM driver MAINTAINERS: Add maintainer entry for the MSM DRM driver MAINTAINERS: Add maintainer entry for the Nouveau DRM driver MAINTAINERS: Update the files list for the Etnaviv DRM driver MAINTAINERS: Remove unneded wildcard for the i915 DRM driver drm/atomic: Add WARN_ON when state->acquire_ctx is not set. ... commit e59a8f7ff4573fd54f1acec0e29280a6556fdde9 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Wed May 4 15:07:34 2016 -0700 cpufreq: intel_pstate: Ignore _PPC processing under HWP When HWP (hardware P states) feature is active, the ACPI _PSS and _PPC is not used. So ignore processing for _PPC limits. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 3 +++ 1 file changed, 3 insertions(+) commit d9975b0b079c2708d39c01dad882c91a7a5a348f Author: Sudeep Holla <Sudeep.Holla@arm.com> Date: Tue May 3 15:05:05 2016 +0100 cpufreq: arm_big_little: use generic OPP functions for {init, free}_opp_table Currently when performing random CPU hot-plugs and suspend-to-ram(S2R) on systems using arm_big_little cpufreq driver, we get warnings similar to something like below: cpu cpu1: _opp_add: duplicate OPPs detected. Existing: freq: 600000000, volt: 800000, enabled: 1. New: freq: 600000000, volt: 800000, enabled: 1 This is mainly because the OPPs for the shared cpus are not set. We can just use dev_pm_opp_of_cpumask_add_table in case the OPPs are obtained from DT(arm_big_little_dt.c) or use dev_pm_opp_set_sharing_cpus if the OPPs are obtained by other means like firmware(e.g. scpi-cpufreq.c) Also now that the generic dev_pm_opp{,_of}_cpumask_remove_table can handle removal of opp table and entries for all associated CPUs, we can re-use dev_pm_opp{,_of}_cpumask_remove_table as free_opp_table in cpufreq_arm_bL_ops. This patch makes necessary changes to reuse the generic OPP functions for {init,free}_opp_table and thereby eliminating the warnings. Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/arm_big_little.c | 54 ++++++++++++++++++---------------- drivers/cpufreq/arm_big_little.h | 4 +-- drivers/cpufreq/arm_big_little_dt.c | 21 ++----------- drivers/cpufreq/scpi-cpufreq.c | 47 +++++++++++++---------------- drivers/cpufreq/vexpress-spc-cpufreq.c | 4 ++- 5 files changed, 56 insertions(+), 74 deletions(-) commit 28ed05732a8fdd9cd17c0c46fc407c737f45aa5b Merge: d9c99ac 411466c Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu May 5 01:38:56 2016 +0200 Merge branch 'pm-opp' into pm-cpufreq commit 411466c5081d2f649b3583cae0f6c9ad5edec636 Author: Sudeep Holla <Sudeep.Holla@arm.com> Date: Tue May 3 15:05:04 2016 +0100 PM / OPP: add non-OF versions of dev_pm_opp_{cpumask_, }remove_table Functions dev_pm_opp_of_{cpumask_,}remove_table removes/frees all the static OPP entries associated with the device and/or all cpus(in case of cpumask) that are created from DT. However the OPP entries are populated reading from the firmware or some different method using dev_pm_opp_add are marked dynamic and can't be removed using above functions. This patch adds non DT/OF versions of dev_pm_opp_{cpumask_,}remove_table to support the above mentioned usecase. This is in preparation to make use of the same in scpi-cpufreq.c Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/core.c | 58 ++++++++++++++++++++++++++++++----------- drivers/base/power/opp/cpu.c | 60 ++++++++++++++++++++++++++++++++----------- include/linux/pm_opp.h | 10 ++++++++ 3 files changed, 98 insertions(+), 30 deletions(-) commit d9c99acb630de767a295c37cd704d08f8237e3f8 Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Mon May 2 15:39:25 2016 +0200 cpufreq: tango: Use generic platdev driver Add tango4 compatible string to the list. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq-dt-platdev.c | 2 ++ 1 file changed, 2 insertions(+) commit ddbb74bc70c0dbaab85d1aa2564b0b3217267454 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 30 13:33:29 2016 +0200 PM / OPP: pass cpumask by reference The new use of dev_pm_opp_set_sharing_cpus resulted in a harmless compiler warning with CONFIG_CPUMASK_OFFSTACK=y: drivers/cpufreq/mvebu-cpufreq.c: In function 'armada_xp_pmsu_cpufreq_init': include/linux/cpumask.h:550:25: error: passing argument 2 of 'dev_pm_opp_set_sharing_cpus' discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers] The problem here is that cpumask_var_t gets passed by reference, but by declaring a 'const cpumask_var_t' argument, only the pointer is constant, not the actual mask. This is harmless because the function does not actually modify the mask. This patch changes the function prototypes for all of the related functions to pass a 'struct cpumask *' instead of 'cpumask_var_t', matching what most other such functions do in the kernel. This lets us mark all the other similar functions as taking a 'const' mask where possible, and it avoids the warning without any change in object code. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 947bd567f7a5 (mvebu: Use dev_pm_opp_set_sharing_cpus() to mark OPP tables as shared) Acked-by: Pavel Machek <pavel@ucw.cz> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 10 +++++----- include/linux/pm_opp.h | 20 ++++++++++---------- 2 files changed, 15 insertions(+), 15 deletions(-) commit e43e94c1eda76dabd686ddf6f7825f54d747b310 Author: Sai Gurrappadi <sgurrappadi@nvidia.com> Date: Fri Apr 29 14:44:37 2016 -0700 cpufreq: Fix GOV_LIMITS handling for the userspace governor Currently, the userspace governor only updates frequency on GOV_LIMITS if policy->cur falls outside policy->{min/max}. However, it is also necessary to update current frequency on GOV_LIMITS to match the user requested value if it can be achieved within the new policy->{max/min}. This was previously the behaviour in the governor until commit d1922f0 ("cpufreq: Simplify userspace governor") which incorrectly assumed that policy->cur == user requested frequency via scaling_setspeed. This won't be true if the user requested frequency falls outside policy->{min/max}. Ex: a temporary thermal cap throttled the user requested frequency. Fix this by storing the user requested frequency in a seperate variable. The governor will then try to achieve this request on every GOV_LIMITS change. Fixes: d1922f02562f (cpufreq: Simplify userspace governor) Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq_userspace.c | 43 ++++++++++++++++++++++++++++++++----- 1 file changed, 38 insertions(+), 5 deletions(-) commit 0b81561c1d30bb44e65d3725042e27b548bb1a86 Author: Arjun Sreedharan <arjun024@gmail.com> Date: Fri Apr 29 09:00:14 2016 +0200 cpupower: fix potential memory leak Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/bench/parse.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 9e5ed6d1fb87dc3ff0c2a94ed75fe82027a9f597 Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun Apr 17 13:36:56 2016 -0400 ACPI,PCI,IRQ: remove SCI penalize function Removing the SCI penalize function as the penalty is now calculated on the fly. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/kernel/acpi/boot.c | 1 - drivers/acpi/pci_link.c | 4 ---- include/linux/acpi.h | 1 - 3 files changed, 6 deletions(-) commit 1fcb6a813c4f67a0ba189b0d057b70ba084f6e1a Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun Apr 17 13:36:55 2016 -0400 ACPI,PCI,IRQ: remove redundant code in acpi_irq_penalty_init() acpi_irq_get_penalty is now calculating the penalty on the fly now. No need to maintain global list of penalties or calculate them at the init time. Removing duplicate code in acpi_irq_penalty_init. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/pci/acpi.c | 1 - drivers/acpi/pci_link.c | 36 ------------------------------------ include/acpi/acpi_drivers.h | 1 - 3 files changed, 38 deletions(-) commit 5c5087a5539083305f1199f09ac2e7f14d855ff3 Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun Apr 17 13:36:54 2016 -0400 ACPI,PCI,IRQ: reduce static IRQ array size to 16 Now that the supported number of PCI IRQs are no longer capped with 256, renaming the static array to support ISA IRQs only and removing the MAX_IRQS constant. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/pci_link.c | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit 103544d86976338057d6a91f721b49d3acc7df7f Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun Apr 17 13:36:53 2016 -0400 ACPI,PCI,IRQ: reduce resource requirements Code has been redesigned to calculate penalty requirements on the fly. This significantly simplifies the implementation and removes some of the init calls from x86 architecture. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/pci_link.c | 97 ++++++++++++++++++++++++++++++++++--------------- 1 file changed, 68 insertions(+), 29 deletions(-) commit d144cf42eee0eabdb2e76ea67a9b0437c5070751 Author: Ming Lei <ming.lei@canonical.com> Date: Mon May 2 11:15:01 2016 -0700 Input: cm109 - spin_lock in complete() cleanup Complete() will be run with interrupt enabled, so change to spin_lock_irqsave(). Signed-off-by: Ming Lei <ming.lei@canonical.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/cm109.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit c90a0f08fedc57e2b8ff871cc036cdbdde683de4 Author: Florian Euchner <florian.euchner@gmail.com> Date: Wed May 4 15:59:18 2016 -0700 Input: cm109 - fix handling of volume and mute buttons The CM109 driver reported key press events of volume up / down and record / playback mute buttons, but no release events. Report those events properly by handling volume and mute keys seperately. For the record and playback mute buttons, only presses are registered by the CM109, therefore simulate press-n-release. This fixes the volume control buttons of various USB headsets. Signed-off-by: Florian Euchner <florian.euchner@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/cm109.c | 37 ++++++++++++++++++++++++++++++------- 1 file changed, 30 insertions(+), 7 deletions(-) commit b0da6d44157aa6e652de7634343708251ba64146 Author: James Hogan <james.hogan@imgtec.com> Date: Fri Apr 29 22:29:26 2016 +0100 asm-generic: Drop renameat syscall from default list The newer renameat2 syscall provides all the functionality provided by the renameat syscall and adds flags, so future architectures won't need to include renameat. Therefore drop the renameat syscall from the generic syscall list unless __ARCH_WANT_RENAMEAT is defined by the architecture's unistd.h prior to including asm-generic/unistd.h, and adjust all architectures using the generic syscall list to define it so that no in-tree architectures are affected. Signed-off-by: James Hogan <james.hogan@imgtec.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> Cc: linux-arch@vger.kernel.org Cc: linux-snps-arc@lists.infradead.org Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Cc: Mark Salter <msalter@redhat.com> Cc: Aurelien Jacquiot <a-jacquiot@ti.com> Cc: linux-c6x-dev@linux-c6x.org Cc: Richard Kuo <rkuo@codeaurora.org> Cc: linux-hexagon@vger.kernel.org Cc: linux-metag@vger.kernel.org Cc: Jonas Bonn <jonas@southpole.se> Cc: linux@lists.openrisc.net Cc: Chen Liqin <liqin.linux@gmail.com> Cc: Lennox Wu <lennox.wu@gmail.com> Cc: Chris Metcalf <cmetcalf@mellanox.com> Cc: Guan Xuetao <gxt@mprc.pku.edu.cn> Cc: Ley Foon Tan <lftan@altera.com> Cc: nios2-dev@lists.rocketboards.org Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: uclinux-h8-devel@lists.sourceforge.jp Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arc/include/uapi/asm/unistd.h | 1 + arch/arm64/include/uapi/asm/unistd.h | 3 +++ arch/c6x/include/uapi/asm/unistd.h | 1 + arch/h8300/include/uapi/asm/unistd.h | 2 ++ arch/hexagon/include/uapi/asm/unistd.h | 1 + arch/metag/include/uapi/asm/unistd.h | 2 ++ arch/nios2/include/uapi/asm/unistd.h | 2 ++ arch/openrisc/include/uapi/asm/unistd.h | 1 + arch/score/include/uapi/asm/unistd.h | 1 + arch/tile/include/uapi/asm/unistd.h | 1 + arch/unicore32/include/uapi/asm/unistd.h | 2 ++ include/uapi/asm-generic/unistd.h | 3 +++ 12 files changed, 20 insertions(+) commit e5f660ebef68e3ed1a988ad06ba23562153cee5c Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:49:01 2016 +0800 ACPI / osi: Collect _OSI handling into one single file _OSI handling code grows giant and it's time to move them into one file. This patch collects all _OSI handling code into one single file. So that we only have the following functions to be used externally: early_acpi_osi_init(): Used by DMI detections; acpi_osi_init(): Used to initialize OSI command line settings and install Linux specific _OSI handler; acpi_osi_setup(): The API that should be used by the external quirks. acpi_osi_is_win8(): The API is used by the external drivers to determine if BIOS supports Win8. CONFIG_DMI is not useful as stub dmi_check_system() can make everything stub because of strip. No functional changes. Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/Makefile | 2 +- drivers/acpi/blacklist.c | 219 +------------------- drivers/acpi/internal.h | 2 + drivers/acpi/osi.c | 522 +++++++++++++++++++++++++++++++++++++++++++++++ drivers/acpi/osl.c | 256 +---------------------- include/linux/acpi.h | 2 - 6 files changed, 531 insertions(+), 472 deletions(-) commit d5a91d74c6d7da2cebadbb9f2d03e56f84d7be62 Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:48:53 2016 +0800 ACPI / osi: Cleanup coding style issues before creating a separate OSI source file This patch performs necessary cleanups before moving OSI support to another file. 1. Change printk into pr_xxx 2. Do not initialize values to 0 3. Do not append additional "return" at the end of the function 4. Remove useless comments which may easily break line breaking rule After fixing the coding style issues, rename functions to make them looking like acpi_osi_xxx. No functional changes. Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/blacklist.c | 10 +++---- drivers/acpi/osl.c | 76 ++++++++++++++++++++---------------------------- include/linux/acpi.h | 4 +-- 3 files changed, 38 insertions(+), 52 deletions(-) commit dc45eb20a83d11ed649169fbe9159ed6bf586c88 Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:48:46 2016 +0800 ACPI / osi: Cleanup OSI handling code to use bool This patch changes "int/unsigned int" to "bool" to simplify the code. Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/blacklist.c | 4 ++-- drivers/acpi/osl.c | 36 +++++++++++++----------------------- include/linux/acpi.h | 4 ++-- 3 files changed, 17 insertions(+), 27 deletions(-) commit e10cfdc33a0f23dc8449be7267f0a642e96a2a24 Author: Chen Yu <yu.c.chen@intel.com> Date: Tue May 3 16:48:39 2016 +0800 ACPI / osi: Fix default _OSI(Darwin) support The following commit always reports positive value when Apple hardware queries _OSI("Darwin"): Commit: 7bc5a2bad0b8d9d1ac9f7b8b33150e4ddf197334 Subject: ACPI: Support _OSI("Darwin") correctly However since this implementation places the judgement in runtime, it breaks acpi_osi=!Darwin and cannot return unsupported for _OSI("WinXXX") invoked before invoking _OSI("Darwin"). This patch fixes the issues by reverting the wrong support and implementing the default behavior of _OSI("Darwin")/_OSI("WinXXX") on Apple hardware via DMI matching. Fixes: 7bc5a2bad0b8 (ACPI: Support _OSI("Darwin") correctly) Link: https://bugzilla.kernel.org/show_bug.cgi?id=92111 Reported-and-tested-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/blacklist.c | 23 +++++++++++++++++++ drivers/acpi/osl.c | 58 ++++++++++++++++++++++++++++++++++++++++++------ include/linux/acpi.h | 1 + 3 files changed, 75 insertions(+), 7 deletions(-) commit a707edebadf1230f202000f29b28b7586ada4aa3 Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:48:32 2016 +0800 ACPI / osi: Add acpi_osi=!! to allow reverting acpi_osi=! This patch introduces acpi_osi=!! so that quirks may use it to revert acpi_osi=!. Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Documentation/kernel-parameters.txt | 2 ++ drivers/acpi/osl.c | 3 +++ 2 files changed, 5 insertions(+) commit dbee890bf69ad62c021e299e24881fdcd1f2c481 Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:48:27 2016 +0800 ACPI / osi: Cleanup _OSI("Linux") related code before introducing new support This patch cleans up OSI code in osl.c to make osi_linux work for OSI strings other than "Linux", so it can be re-used for other purposes. Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/osl.c | 42 ++++++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 20 deletions(-) commit 30c9bb0d7603e7b3f4d6a0ea231e1cddae020c32 Author: Lv Zheng <lv.zheng@intel.com> Date: Tue May 3 16:48:20 2016 +0800 ACPI / osi: Fix an issue that acpi_osi=!* cannot disable ACPICA internal strings The order of the _OSI related functionalities is as follows: acpi_blacklisted() acpi_dmi_osi_linux() acpi_osi_setup() acpi_osi_setup() acpi_update_interfaces() if "!*" <<<<<<<<<<<<<<<<<<<<<<<< parse_args() __setup("acpi_osi=") acpi_osi_setup_linux() acpi_update_interfaces() if "!*" <<<<<<<<<<<<<<<<<<<<<<<< acpi_early_init() acpi_initialize_subsystem() acpi_ut_initialize_interfaces() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ acpi_bus_init() acpi_os_initialize1() acpi_install_interface_handler(acpi_osi_handler) acpi_osi_setup_late() acpi_update_interfaces() for "!" >>>>>>>>>>>>>>>>>>>>>>>> acpi_osi_handler() Since acpi_osi_setup_linux() can override acpi_dmi_osi_linux(), the command line setting can override the DMI detection. That's why acpi_blacklisted() is put before __setup("acpi_osi="). Then we can notice the following wrong invocation order. There are acpi_update_interfaces() (marked by <<<<) calls invoked before acpi_ut_initialize_interfaces() (marked by ^^^^). This makes it impossible to use acpi_osi=!* correctly from OSI DMI table or from the command line. The use of acpi_osi=!* is meant to disable both ACPICA (acpi_gbl_supported_interfaces) and Linux specific strings (osi_setup_entries) while the ACPICA part should have stopped working because of the order issue. This patch fixes this issue by moving acpi_update_interfaces() to where it is invoked for acpi_osi=! (marked by >>>>) as this is ensured to be invoked after acpi_ut_initialize_interfaces() (marked by ^^^^). Linux specific strings are still handled in the original place in order to make the following command line working: acpi_osi=!* acpi_osi="Module Device". Note that since acpi_osi=!* is meant to further disable linux specific string comparing to the acpi_osi=!, there is no such use case in our bug fixing work and hence there is no one using acpi_osi=!* either from the command line or from the DMI quirks, this issue is just a theoretical issue. Fixes: 741d81280ad2 (ACPI: Add facility to remove all _OSI strings) Cc: 3.12+ <stable@vger.kernel.org> # 3.12+ Tested-by: Lukas Wunner <lukas@wunner.de> Tested-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/osl.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) commit bdd74440d9e887b1fa648eefa17421def5f5243c Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Tue May 3 14:22:00 2016 +0200 PCI: hv: Add explicit barriers to config space access I'm trying to pass-through Broadcom BCM5720 NIC (Dell device 1f5b) on a Dell R720 server. Everything works fine when the target VM has only one CPU, but SMP guests reboot when the NIC driver accesses PCI config space with hv_pcifront_read_config()/hv_pcifront_write_config(). The reboot appears to be induced by the hypervisor and no crash is observed. Windows event logs are not helpful at all ('Virtual machine ... has quit unexpectedly'). The particular access point is always different and putting debug between them (printk/mdelay/...) moves the issue further away. The server model affects the issue as well: on Dell R420 I'm able to pass-through BCM5720 NIC to SMP guests without issues. While I'm obviously failing to reveal the essence of the issue I was able to come up with a (possible) solution: if explicit barriers are added to hv_pcifront_read_config()/hv_pcifront_write_config() the issue goes away. The essential minimum is rmb() at the end on _hv_pcifront_read_config() and wmb() at the end of _hv_pcifront_write_config() but I'm not confident it will be sufficient for all hardware. I suggest the following barriers: 1) wmb()/mb() between choosing the function and writing to its space. 2) mb() before releasing the spinlock in both _hv_pcifront_read_config()/ _hv_pcifront_write_config() to ensure that consecutive reads/writes to the space won't get re-ordered as drivers may count on that. Config space access is not supposed to be performance-critical so these explicit barriers should not cause any slowdown. [bhelgaas: use Linux "barriers" terminology] Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Jake Oshins <jakeo@microsoft.com> drivers/pci/host/pci-hyperv.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit f8415222837b651902661f12f5760169690f6696 Author: Lukas Wunner <lukas@wunner.de> Date: Wed May 4 16:58:11 2016 -0500 PCI: Use cached copy of PCI_EXP_SLTCAP_HPC bit We cache the PCI_EXP_SLTCAP_HPC bit in pci_dev->is_hotplug_bridge on device probe, so there's no need to read it again on allocation of port service devices. No functional change intended. Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pcie/portdrv_core.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit a508d954af748bc1f5f1d9174f167a8650fca923 Author: Betty Dall <betty.dall@hpe.com> Date: Sat Apr 30 10:03:39 2016 -0600 ACPI / device_sysfs: Clean up checkpatch errors Cleaning up two existing checkpatch errors (and 2 warnings) in device_sysfs.c since the file is being changed. The change in acpi_device_setup_files() is changing spaces to a tab. Signed-off-by: Betty Dall <betty.dall@hpe.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/device_sysfs.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 6c0244091e8aa98e7977bdddeab2bb864cff9d91 Author: Betty Dall <betty.dall@hpe.com> Date: Sat Apr 30 10:03:38 2016 -0600 ACPI / device_sysfs: Change _SUN and _STA show functions error return to EIO The error return from a sysfs show function is passed up through the call chain and visible as the return from the read system call. The show functions for the _STA and _SUN object currently return -ENODEV. This patch changes the return to -EIO. ENODEV makes less sense since the "device' exists or there wouldn't be a sysfs file. Signed-off-by: Betty Dall <betty.dall@hpe.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/device_sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6283f97d5fbfdd1e31694d7f6000eb728cdfba77 Author: Betty Dall <betty.dall@hpe.com> Date: Sat Apr 30 10:03:37 2016 -0600 ACPI / device_sysfs: Add sysfs support for _HRV hardware revision The ACPI _HRV object on the device is used to supply Linux with the device's hardware revision. This is an optional object. Add sysfs support for the _HRV object if it exists on the device. This change allows users to easily find the hardware version of non-PCI hardware by looking at the sysfs 'hrv' file. It is most useful for non-PCI devices because lspci can list the hardware version for PCI devices. Signed-off-by: Betty Dall <betty.dall@hpe.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/device_sysfs.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 059500940defe285222d3b189b366dfe7f299cae Author: Aaron Lu <aaron.lu@intel.com> Date: Wed Apr 27 20:45:04 2016 +0800 ACPI/video: export acpi_video_get_levels The acpi_video_get_levels is useful for other drivers, i.e. the to-be-added int3406 thermal driver, so export it. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpi_video.c | 83 +++++++++++++++++++++++++---------------------- include/acpi/video.h | 20 ++++++++++++ 2 files changed, 65 insertions(+), 38 deletions(-) commit 01c3664de62f89f6777e59173ad8e20b5a4c267f Author: Aaron Lu <aaron.lu@intel.com> Date: Wed Apr 27 20:45:03 2016 +0800 video / backlight: remove the backlight_device_registered API Since we will need the backlight_device_get_by_type API, we can use it instead of the backlight_device_registered API whenever necessary so remove the backlight_device_registered API. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Acked-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/video_detect.c | 2 +- drivers/video/backlight/backlight.c | 6 ------ include/linux/backlight.h | 1 - 3 files changed, 1 insertion(+), 8 deletions(-) commit f6a4790a5471d7cba406d87f6b41323f40bb93d2 Author: Aaron Lu <aaron.lu@intel.com> Date: Wed Apr 27 20:45:02 2016 +0800 video / backlight: add two APIs for drivers to use It is useful to get the backlight device's pointer and use it to set backlight in some cases(the following patch will make use of it) so add the two APIs and export them. Signed-off-by: Aaron Lu <aaron.lu@intel.com> Acked-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/video/backlight/backlight.c | 43 +++++++++++++++++++++++++------------ include/linux/backlight.h | 2 ++ 2 files changed, 31 insertions(+), 14 deletions(-) commit aa8a8b05adfc72e562abe7ae5c6933906e0ed2e9 Merge: 3e66bab 8b44a8a Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 17:13:34 2016 -0400 Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 10GbE Intel Wired LAN Driver Updates 2016-05-04 This series contains updates to ixgbe, ixgbevf and traffic class helpers. Sridhar adds helper functions to the tc_mirred header to access tcf_mirred information and then implements them for ixgbe to enable redirection to a SRIOV VF or an offloaded MACVLAN device queue via tc 'mirred' action. Amritha adds support to set filters with multiple header fields (L3,L4) to match on. KY Srinivasan from Microsoft add Hyper-V support into ixgbevf. Emil adds 82599 sub-device IDs that were missing from the list of parts that support WoL. Then simplified the logic we use to determine WoL support by reading the EEPROM bits for MACs X540 and newer. Preethi cleaned up duplicate and unused device IDs. Fixed our ethtool stat reporting where we were ignoring higher 32 bits of stats registers, so fill out 64 bit stat values into two 32 bit words. Babu Moger from Oracle improves VF performance issues on SPARC. Alex Duyck cleans up some of the Hyper-V implementation from KY so that we can just use function pointers instead of having to identify if a given VF is running on a Linux or Windows PF. Usha makes sure that DCB and FCoE is disabled for X550EM_x/a MACs and cleans up the DCB initialization in the process. Tony cleans up the API for ixgbevf_update_xcast_mode() so we do not have to pass in the netdev parameter, since it was never used in the function. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3e66bab33f2a32630616d335dbf4965896eb159f Author: Florian Westphal <fw@strlen.de> Date: Wed May 4 22:56:07 2016 +0200 drivers: fix dev->trans_start removal fallout kbuild test robot reported a build failure on s390. While at it, also fix missing conversion in the tilera driver. Fixes: 9b36627acecd5792 ("net: remove dev->trans_start") Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/tile/tilepro.c | 2 +- drivers/s390/net/qeth_core_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 5c2a9644d05e98b3c06b073351cd363ff91b22e8 Author: Florian Westphal <fw@strlen.de> Date: Wed May 4 22:51:47 2016 +0200 bonding: update documentation section after dev->trans_start removal Drivers that use LLTX need to update trans_start of the netdev_queue. (Most drivers don't use LLTX; stack does this update if .ndo_start_xmit returned TX_OK). Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/bonding.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5a36b68b670ebdf19eaedd4f859810293a3d1dc1 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:22:01 2016 +0300 usbnet: smsc95xx: silence an uninitialized variable warning If the call to fn() fails then "buf" is uninitialized. Just return the error code in that case. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/smsc95xx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 58ef6a3f64bd837e107a2bbf0571574850a32b8c Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:21:02 2016 +0300 usbnet/smsc75xx: silence uninitialized variable warning If the fn() calls fail then "buf" is uninitialized. Just return early in that situation. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/smsc75xx.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 614bdd4d6e61d260d82945f5f52a5dc288f64783 Author: Eric Dumazet <edumazet@google.com> Date: Tue May 3 17:10:50 2016 -0700 tcp: must block bh in __inet_twsk_hashdance() __inet_twsk_hashdance() might be called from process context, better block BH before acquiring bind hash and established locks Fixes: c10d9310edf5 ("tcp: do not assume TCP code is non preemptible") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_timewait_sock.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 46cc6e4976e3d9058490f20d93bc7805f7f2d81e Author: Eric Dumazet <edumazet@google.com> Date: Tue May 3 16:56:03 2016 -0700 tcp: fix lockdep splat in tcp_snd_una_update() tcp_snd_una_update() and tcp_rcv_nxt_update() call u64_stats_update_begin() either from process context or BH handler. This triggers a lockdep splat on 32bit & SMP builds. We could add u64_stats_update_begin_bh() variant but this would slow down 32bit builds with useless local_disable_bh() and local_enable_bh() pairs, since we own the socket lock at this point. I add sock_owned_by_me() helper to have proper lockdep support even on 64bit builds, and new u64_stats_update_begin_raw() and u64_stats_update_end_raw methods. Fixes: c10d9310edf5 ("tcp: do not assume TCP code is non preemptible") Reported-by: Fabio Estevam <festevam@gmail.com> Diagnosed-by: Francois Romieu <romieu@fr.zoreil.com> Signed-off-by: Eric Dumazet <edumazet@google.com> Tested-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/u64_stats_sync.h | 14 ++++++++++++++ include/net/sock.h | 7 ++++++- net/ipv4/tcp_input.c | 10 ++++++---- 3 files changed, 26 insertions(+), 5 deletions(-) commit 512eae392abe7b5be3c1fe69b3d8cf54bb0ff3f2 Merge: 04974df 83cb0e4 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed May 4 22:50:47 2016 +0200 Merge tag 'PR_4.7_20160503' of https://git.kernel.org/pub/scm/linux/kernel/git/mzx/devfreq into pm-devfreq Pull devfreq material for v4.7 from MyungJoo Ham. "Updates: - Passive governor: for SoC subsystems that may either have an independent voltage rail or have a parent subsystem or collegue subsystem sharing a voltage rail, when there is a parent of a collegue that is going to be the owner of the voltage rail, the dependent subsystem may use the passive governor. - Consolidated exynos bus/mem-if driver: now we have a single driver that supports (almost) all Exynos SoC's bus/mem-if subsystems. - New devfreq drivers included: Exynos NoC probe" * tag 'PR_4.7_20160503' of https://git.kernel.org/pub/scm/linux/kernel/git/mzx/devfreq: PM / devfreq: style/typo fixes PM / devfreq: exynos: Add the detailed correlation for Exynos5422 bus PM / devfreq: event: Find the instance of devfreq-event device by using phandle PM / devfreq: event: Add new Exynos NoC probe driver MAINTAINERS: Add samsung bus frequency driver entry PM / devfreq: exynos: Remove unused exynos4/5 busfreq driver PM / devfreq: exynos: Add the detailed correlation between sub-blocks and power line PM / devfreq: exynos: Update documentation for bus devices using passive governor PM / devfreq: exynos: Add support of bus frequency of sub-blocks using passive governor PM / devfreq: Add new passive governor PM / devfreq: Add new DEVFREQ_TRANSITION_NOTIFIER notifier PM / devfreq: Add devfreq_get_devfreq_by_phandle() PM / devfreq: exynos: Add documentation for generic exynos bus frequency driver PM / devfreq: exynos: Add generic exynos bus frequency driver commit 3f30e40b96b085ff25babaa8d6bc0b75c8fb32b2 Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:35 2016 +0200 [media] rtl2832: regmap is aware of lockdep, drop local locking hack Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/rtl2832.c | 30 ------------------------------ drivers/media/dvb-frontends/rtl2832_priv.h | 1 - 2 files changed, 31 deletions(-) commit e01fc42d78ab953f6de4ff9273cb9d6d9ed3dd37 Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:34 2016 +0200 [media] rtl2832_sdr: get rid of empty regmap wrappers Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/rtl2832_sdr.c | 302 +++++++++++++----------------- 1 file changed, 132 insertions(+), 170 deletions(-) commit 1cf79db28ef53aeaa66a825e8f788d19fdd8648f Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:33 2016 +0200 [media] rtl2832: change the i2c gate to be mux-locked The root i2c adapter lock is then no longer held by the i2c mux during accesses behind the i2c gate, and such accesses need to take that lock just like any other ordinary i2c accesses do. So, declare the i2c gate mux-locked, and zap the regmap overrides that makes the i2c accesses unlocked and use plain old regmap accesses. This also removes the need for the regmap wrappers used by rtl2832_sdr, so deconvolute the code further and provide the regmap handle directly instead of the wrapper functions. Tested-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Documentation/i2c/i2c-topology | 2 +- drivers/media/dvb-frontends/rtl2832.c | 190 ++++-------------------------- drivers/media/dvb-frontends/rtl2832.h | 4 +- drivers/media/dvb-frontends/rtl2832_sdr.c | 13 +- drivers/media/dvb-frontends/rtl2832_sdr.h | 5 +- drivers/media/usb/dvb-usb-v2/rtl28xxu.c | 5 +- 6 files changed, 37 insertions(+), 182 deletions(-) commit e6d7ffcdf15f40fc1cff7a3c2fd2720ce3d53e49 Author: Antti Palosaari <crope@iki.fi> Date: Wed May 4 22:15:32 2016 +0200 [media] si2168: change the i2c gate to be mux-locked The root i2c adapter lock is then no longer held by the i2c mux during accesses behind the i2c gate, and such accesses need to take that lock just like any other ordinary i2c accesses do. So, declare the i2c gate mux-locked, and zap the code that makes the i2c accesses unlocked. But add a mutex so that firmware commands are still serialized. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Documentation/i2c/i2c-topology | 2 +- drivers/media/dvb-frontends/si2168.c | 83 ++++++++----------------------- drivers/media/dvb-frontends/si2168_priv.h | 1 + 3 files changed, 22 insertions(+), 64 deletions(-) commit 1ffcfaf19597ad26797aac3ab42d8ba6e548ef0a Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:31 2016 +0200 iio: imu: inv_mpu6050: change the i2c gate to be mux-locked The root i2c adapter lock is then no longer held by the i2c mux during accesses behind the i2c gate, and such accesses need to take that lock just like any other ordinary i2c accesses do. So, declare the i2c gate mux-locked, and zap the code that makes the unlocked i2c accesses and just use ordinary regmap_write accesses. This also happens to fix the deadlock described in http://patchwork.ozlabs.org/patch/584776/ authored by Adriana Reus <adriana.reus@intel.com> and submitted by Daniel Baluta <daniel.baluta@intel.com> ----------8<---------- iio: imu: inv_mpu6050: Fix deadlock between i2c adapter lock and mpu lock This deadlock occurs if the accel/gyro and the sensor on the auxiliary I2C (in my setup it's an ak8975) are working at the same time. Scenario: T1 T2 ==== ==== inv_mpu6050_read_fifo aux sensor op (eg. ak8975_read_raw) | | mutex_lock(&indio_dev->mlock) i2c_transfer | | i2c transaction i2c adapter lock | | i2c adapter lock i2c_mux_master_xfer | inv_mpu6050_select_bypass | mutex_lock(&indio_dev->mlock) When we operate on an mpu sensor the order of locking is mpu lock followed by the i2c adapter lock. However, when we operate the auxiliary sensor the order of locking is the other way around. ... ----------8<---------- The reason this patch fixes the deadlock is that T2 does not grab the i2c adapter lock until the very end (and grabs the newfangled i2c mux lock where it previously grabbed the i2c adapter lock). Acked-by: Jonathan Cameron <jic23@kernel.org> Acked-by: Daniel Baluta <daniel.baluta@intel.com> Tested-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Documentation/i2c/i2c-topology | 2 +- drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 52 ++++++------------------------- 2 files changed, 11 insertions(+), 43 deletions(-) commit 2254d24aff3ab472dca287aef0123e8f0e06a14a Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:30 2016 +0200 i2c: mux: document i2c muxes and elaborate on parent-/mux-locked muxes Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Documentation/i2c/i2c-topology | 370 +++++++++++++++++++++++++++++++++++++++++ MAINTAINERS | 1 + 2 files changed, 371 insertions(+) commit 6ef91fcca8a8ba3df9810a4cc6cd6a9d3f21bf45 Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:29 2016 +0200 i2c: mux: relax locking of the top i2c adapter during mux-locked muxing With a i2c topology like the following GPIO ---| ------ BAT1 | v / I2C -----+----------+---- MUX | \ EEPROM ------ BAT2 there is a locking problem with the GPIO controller since it is a client on the same i2c bus that it muxes. Transfers to the mux clients (e.g. BAT1) will lock the whole i2c bus prior to attempting to switch the mux to the correct i2c segment. In the above case, the GPIO device is an I/O expander with an i2c interface, and since the GPIO subsystem knows nothing (and rightfully so) about the lockless needs of the i2c mux code, this results in a deadlock when the GPIO driver issues i2c transfers to modify the mux. So, observing that while it is needed to have the i2c bus locked during the actual MUX update in order to avoid random garbage on the slave side, it is not strictly a must to have it locked over the whole sequence of a full select-transfer-deselect mux client operation. The mux itself needs to be locked, so transfers to clients behind the mux are serialized, and the mux needs to be stable during all i2c traffic (otherwise individual mux slave segments might see garbage, or worse). Introduce this new locking concept as "mux-locked" muxes, and call the pre-existing mux locking scheme "parent-locked". Modify the i2c mux locking so that muxes that are "mux-locked" locks only the muxes on the parent adapter instead of the whole i2c bus when there is a transfer to the slave side of the mux. This lock serializes transfers to the slave side of the muxes on the parent adapter. Add code to i2c-mux-gpio and i2c-mux-pinctrl that checks if all involved gpio/pinctrl devices have a parent that is an i2c adapter in the same adapter tree that is muxed, and request a "mux-locked mux" if that is the case. Modify the select-transfer-deselect code for "mux-locked" muxes so that each of the select-transfer-deselect ops locks the mux parent adapter individually. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-core.c | 1 + drivers/i2c/i2c-mux.c | 152 +++++++++++++++++++++++++++++++++--- drivers/i2c/muxes/i2c-mux-gpio.c | 18 +++++ drivers/i2c/muxes/i2c-mux-pinctrl.c | 38 +++++++++ include/linux/i2c-mux.h | 8 ++ include/linux/i2c.h | 1 + 6 files changed, 205 insertions(+), 13 deletions(-) commit fa96f0cb9b37a1a296d18f7bde63b0910852303e Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:28 2016 +0200 i2c: muxes always lock the parent adapter Instead of checking for i2c parent adapters for every lock/unlock, simply override the locking for muxes to always lock/unlock the parent adapter directly. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-core.c | 21 +++------------------ drivers/i2c/i2c-mux.c | 30 ++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 18 deletions(-) commit 8320f495cf441d593f7cd4f30e6b63455be71a2c Author: Peter Rosin <peda@axentia.se> Date: Wed May 4 22:15:27 2016 +0200 i2c: allow adapter drivers to override the adapter locking Add i2c_lock_bus() and i2c_unlock_bus(), which call the new lock_bus and unlock_bus ops in the adapter. These funcs/ops take an additional flags argument that indicates for what purpose the adapter is locked. There are two flags, I2C_LOCK_ROOT_ADAPTER and I2C_LOCK_SEGMENT, but they are both implemented the same. For now. Locking the root adapter means that the whole bus is locked, locking the segment means that only the current bus segment is locked (i.e. i2c traffic on the parent side of a mux is still allowed even if the child side of the mux is locked). Also support a trylock_bus op (but no function to call it, as it is not expected to be needed outside of the i2c core). Implement i2c_lock_adapter/i2c_unlock_adapter in terms of the new locking scheme (i.e. lock with the I2C_LOCK_ROOT_ADAPTER flag). Locking the root adapter and locking the segment is the same thing for all root adapters (e.g. in the normal case of a simple topology with no i2c muxes). The two locking variants are also the same for traditional muxes (aka parent-locked muxes). These muxes traverse the tree, locking each level as they go until they reach the root. This patch is preparatory for a later patch in the series introducing mux-locked muxes, which behave differently depending on the requested locking. Since all current users are using i2c_lock_adapter, which is a wrapper for I2C_LOCK_ROOT_ADAPTER, we only need to annotate the calls that will not need to lock the root adapter for mux-locked muxes. I.e. the instances that needs to use I2C_LOCK_SEGMENT instead of i2c_lock_adapter/I2C_LOCK_ROOT_ADAPTER. Those instances are in the i2c_transfer and i2c_smbus_xfer functions, so that mux-locked muxes can single out normal i2c accesses to its slave side and adjust the locking for those accesses. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-core.c | 41 +++++++++++++++++++++++++++-------------- include/linux/i2c.h | 44 ++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 69 insertions(+), 16 deletions(-) commit 5332174a83720921a5ef6db8080a8691f7ccbc27 Merge: e98a3aa 64ae744 Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 16:21:08 2016 -0400 Merge tag 'batman-adv-for-davem' of git://git.open-mesh.org/linux-merge Antonio Quartulli says: ==================== pull request: batman-adv 20160504 In this pull request you have: - two changes to the MAINTAINERS file where one marks our mailing list as moderated and the other adds a missing documentation file - kernel-doc fixes - code refactoring and various cleanups ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit e98a3aabf85f60b80c6ef93e509d38144ca434b1 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Tue May 3 23:14:41 2016 +0300 mdio_bus: don't return NULL from mdiobus_scan() I've finally noticed that mdiobus_scan() also returns either NULL or error value on failure. Return ERR_PTR(-ENODEV) instead of NULL since this is the error value already filtered out by the callers that want to ignore the MDIO address scan failure... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/mdio_bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc47e84258be3e49c14be65a111f2117ecc986f6 Author: kbuild test robot <lkp@intel.com> Date: Mon May 2 11:50:16 2016 -0400 md-cluster: fix ifnullfree.cocci warnings drivers/md/bitmap.c:2049:6-11: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. NULL check before some freeing functions is not needed. Based on checkpatch warning "kfree(NULL) is safe this check is probably not required" and kfreeaddr.cocci by Julia Lawall. Generated by: scripts/coccinelle/free/ifnullfree.cocci Acked-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit c84400c89f0f98ae4a73ed89886239b67d1dcd31 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:50:15 2016 -0400 md-cluster/bitmap: unplug bitmap to sync dirty pages to disk This patch is doing two distinct but related things. 1. It adds bitmap_unplug() for the main bitmap (mddev->bitmap). As bit have been set, BITMAP_PAGE_DIRTY is set so bitmap_deamon_work() will not write those pages out in its regular scans, only bitmap_unplug() will. If there are no writes to the array, bitmap_unplug() won't be called, so we need to call it explicitly here. 2. bitmap_write_all() is a bit of a confusing interface as it doesn't actually write anything. The current code for writing "bitmap" works but this change makes it a bit clearer. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 23cea66a37c76dc6554b862b179a654db24fa83d Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:50:14 2016 -0400 md-cluster/bitmap: fix wrong page num in bitmap_file_clear_bit and bitmap_file_set_bit The pnum passed to set_page_attr and test_page_attr should from 0 to storage.file_pages - 1, but bitmap_file_set_bit and bitmap_file_clear_bit call set_page_attr and test_page_attr with page->index parameter while page->index has already added node_offset before. So we need to minus node_offset in both bitmap_file_clear_bit and bitmap_file_set_bit. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 7f86ffed9b5f3f0b1a29108c5e965942b935ec98 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:50:13 2016 -0400 md-cluster/bitmap: fix wrong calcuation of offset The offset is wrong in bitmap_storage_alloc, we should set it like below in bitmap_init_from_disk(). node_offset = bitmap->cluster_slot * (DIV_ROUND_UP(store->bytes, PAGE_SIZE)); Because 'offset' is only assigned to 'page->index' and that is usually over-written by read_sb_page. So it does not cause problem in general, but it still need to be fixed. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 18c9ff7f487efa8e88886bee21bd3516dde05bc5 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:50:12 2016 -0400 md-cluster: sync bitmap when node received RESYNCING msg If the node received RESYNCING message which means another node will perform resync with the area, then we don't want to do it again in another node. Let's set RESYNC_MASK and clear NEEDED_MASK for the region from old-low to new-low which has finished syncing, and the region from old-hi to new-hi is about to syncing, bitmap_sync_with_cluste is introduced for the purpose. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 21 +++++++++++++++++++++ drivers/md/bitmap.h | 3 +++ drivers/md/md-cluster.c | 27 +++++++++++++++++++++++++++ 3 files changed, 51 insertions(+) commit c9d65032282943d11b2773ed6f0279ba4820fed1 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:50:11 2016 -0400 md-cluster: always setup in-memory bitmap The in-memory bitmap for raid is allocated on demand, then for cluster scenario, it is possible that slave node which received RESYNCING message doesn't have the in-memory bitmap when master node is perform resyncing, so we can't make bitmap is match up well among each nodes. So for cluster scenario, we need always preserve the bitmap, and ensure the page will not be freed. And a no_hijack flag is introduced to both bitmap_checkpage and bitmap_get_counter, which makes cluster raid returns fail once allocate failed. And the next patch is relied on this change since it keeps sync bitmap among each nodes during resyncing stage. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/bitmap.c | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) commit a578183ed9dff915878ec6c2b3bf729bf72b9bd1 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:14 2016 -0400 md-cluster: wakeup thread if activated a spare disk When a device is re-added, it will ultimately need to be activated and that happens in md_check_recovery, so we need to set MD_RECOVERY_NEEDED right after remove_and_add_spares. A specifical issue without the change is that when one node perform fail/remove/readd on a disk, but slave nodes could not add the disk back to array as expected (added as missed instead of in sync). So give slave nodes a chance to do resync. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md.c | 5 +++++ 1 file changed, 5 insertions(+) commit ab5a98b132fd1a08ca35e95498fb45f4a8f3b0c4 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:13 2016 -0400 md-cluster: change array_sectors and update size are not supported Currently, some features are not supported yet, such as change array_sectors and update size, so return EINVAL for them and listed it in document. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> Documentation/md-cluster.txt | 6 ++++++ drivers/md/md.c | 8 ++++++++ 2 files changed, 14 insertions(+) commit 1535212c542285e430d44a75bfc0a99df610f598 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:12 2016 -0400 md-cluster: fix locking when node joins cluster during message broadcast If a node joins the cluster while a message broadcast is under way, a lock issue could happen as follows. For a cluster which included two nodes, if node A is calling __sendmsg before up-convert CR to EX on ack, and node B released CR on ack. But if a new node C joins the cluster and it doesn't receive the message which A sent before, so it could hold CR on ack before A up-convert CR to EX on ack. So a node joining the cluster should get an EX lock on the "token" first to ensure no broadcast is ongoing, then release it after held CR on ack. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md-cluster.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 5b0fb33e8aa1c8a94f763d1025445146412ca766 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:11 2016 -0400 md-cluster: unregister thread if err happened The two threads need to be unregistered if a node can't join cluster successfully. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md-cluster.c | 2 ++ 1 file changed, 2 insertions(+) commit eb315cd0933b903126996e79c12cb1eae617a036 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:10 2016 -0400 md-cluster: wake up thread to continue recovery In recovery case, we need to set MD_RECOVERY_NEEDED and wake up thread only if recover is not finished. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md-cluster.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 2c97cf138527a0f0283fcca9acf4a06216bec7da Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:09 2016 -0400 md-cluser: make resync_finish only called after pers->sync_request It is not reasonable that cluster raid to release resync lock before the last pers->sync_request has finished. As the metadata will be changed when node performs resync, we need to inform other nodes to update metadata, so the MD_CHANGE_PENDING flag is set before finish resync. Then metadata_update_finish is move ahead to ensure that METADATA_UPDATED msg is sent before finish resync, and metadata_update_start need to be run after "repeat:" label accordingly. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md.c | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) commit 41a9a0dcf8954654467f979838938e39ef4da590 Author: Guoqing Jiang <gqjiang@suse.com> Date: Mon May 2 11:33:08 2016 -0400 md-cluster: change resync lock from asynchronous to synchronous If multiple nodes choose to attempt do resync at the same time they need to be serialized so they don't duplicate effort. This serialization is done by locking the 'resync' DLM lock. Currently if a node cannot get the lock immediately it doesn't request notification when the lock becomes available (i.e. DLM_LKF_NOQUEUE is set), so it may not reliably find out when it is safe to try again. Rather than trying to arrange an async wake-up when the lock becomes available, switch to using synchronous locking - this is a lot easier to think about. As it is not permitted to block in the 'raid1d' thread, move the locking to the resync thread. So the rsync thread is forked immediately, but it blocks until the resync lock is available. Once the lock is locked it checks again if any resync action is needed. A particular symptom of the current problem is that a node can get stuck with "resync=pending" indefinitely. Reviewed-by: NeilBrown <neilb@suse.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: Shaohua Li <shli@fb.com> drivers/md/md-cluster.c | 2 -- drivers/md/md.c | 23 ++++++++++++++--------- 2 files changed, 14 insertions(+), 11 deletions(-) commit be5f83ffa042d599f6716d99e79d4538c57e5739 Author: Priit Laes <plaes@plaes.org> Date: Tue May 3 20:14:18 2016 +0300 ARM: sun4i: dt: Add pll3 and pll7 clocks Enable pll3 and pll7 clocks that are needed to drive display clocks. Signed-off-by: Priit Laes <plaes@plaes.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10.dtsi | 43 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 4d659fcb20d3d3302b429c889a73a92ff2804b9a Merge: a6e5472 9b36627 Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 14:16:51 2016 -0400 Merge branch 'kill_trans_start' Florian Westphal says: ==================== net: remove trans_start from struct net_device We currently have two instances for trans_start, once in net_device and once in netdev_queue. This series removes trans_start from net_device. Updates to dev->trans_start are replaced with updates to netdev queue 0. This series is compile-tested only. Replacement is done in 3 steps: 1. Replace read-accesses: x = dev->trans_start gets replaced by x = dev_trans_start(dev) 2. Replace write accesses: dev->trans_start = jiffies; gets replaced with new helper: netif_trans_update(dev); 3. This helper is then changed to set netdev_get_tx_queue(dev, 0)->trans_start instead of dev->trans_start. After this dev->trans_start can be removed. It should be noted that after this series several instances of netif_trans_update() are useless (if they occur in .ndo_start_xmit and driver doesn't set LLTX flag -- stack already did an update). Comments welcome. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 9b36627acecd5792e81daf1a3bff8eab39ed45fb Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 16:33:14 2016 +0200 net: remove dev->trans_start previous patches removed all direct accesses to dev->trans_start, so change the netif_trans_update helper to update trans_start of netdev queue 0 instead and then remove trans_start from struct net_device. AFAICS a lot of the netif_trans_update() invocations are now useless because they occur in ndo_start_xmit and driver doesn't set LLTX (i.e. stack already took care of the update). As I can't test any of them it seems better to just leave them alone. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- include/linux/netdevice.h | 15 +++++---------- net/sched/sch_generic.c | 10 +++------- 3 files changed, 9 insertions(+), 18 deletions(-) commit 860e9538a9482bb84589f7d0718a7e6d0a944d58 Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 16:33:13 2016 +0200 treewide: replace dev->trans_start update with helper Replace all trans_start updates with netif_trans_update helper. change was done via spatch: struct net_device *d; @@ - d->trans_start = jiffies + netif_trans_update(d) Compile tested only. Cc: user-mode-linux-devel@lists.sourceforge.net Cc: linux-xtensa@linux-xtensa.org Cc: linux1394-devel@lists.sourceforge.net Cc: linux-rdma@vger.kernel.org Cc: netdev@vger.kernel.org Cc: MPT-FusionLinux.pdl@broadcom.com Cc: linux-scsi@vger.kernel.org Cc: linux-can@vger.kernel.org Cc: linux-parisc@vger.kernel.org Cc: linux-omap@vger.kernel.org Cc: linux-hams@vger.kernel.org Cc: linux-usb@vger.kernel.org Cc: linux-wireless@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: devel@driverdev.osuosl.org Cc: b.a.t.m.a.n@lists.open-mesh.org Cc: linux-bluetooth@vger.kernel.org Signed-off-by: Florian Westphal <fw@strlen.de> Acked-by: Felipe Balbi <felipe.balbi@linux.intel.com> Acked-by: Mugunthan V N <mugunthanvnm@ti.com> Acked-by: Antonio Quartulli <a@unstable.cc> Signed-off-by: David S. Miller <davem@davemloft.net> arch/um/drivers/net_kern.c | 4 ++-- arch/xtensa/platforms/iss/network.c | 2 +- drivers/char/pcmcia/synclink_cs.c | 4 ++-- drivers/firewire/net.c | 2 +- drivers/infiniband/hw/nes/nes_nic.c | 2 +- drivers/infiniband/ulp/ipoib/ipoib_cm.c | 2 +- drivers/infiniband/ulp/ipoib/ipoib_ib.c | 2 +- drivers/isdn/hysdn/hysdn_net.c | 2 +- drivers/isdn/i4l/isdn_net.c | 4 ++-- drivers/isdn/i4l/isdn_x25iface.c | 2 +- drivers/message/fusion/mptlan.c | 2 +- drivers/net/appletalk/cops.c | 2 +- drivers/net/can/mscan/mscan.c | 4 ++-- drivers/net/can/usb/ems_usb.c | 4 ++-- drivers/net/can/usb/esd_usb2.c | 4 ++-- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 4 ++-- drivers/net/cris/eth_v10.c | 2 +- drivers/net/ethernet/3com/3c509.c | 2 +- drivers/net/ethernet/3com/3c515.c | 2 +- drivers/net/ethernet/3com/3c574_cs.c | 2 +- drivers/net/ethernet/3com/3c589_cs.c | 2 +- drivers/net/ethernet/3com/3c59x.c | 2 +- drivers/net/ethernet/8390/axnet_cs.c | 6 +++--- drivers/net/ethernet/8390/lib8390.c | 4 ++-- drivers/net/ethernet/adaptec/starfire.c | 2 +- drivers/net/ethernet/adi/bfin_mac.c | 2 +- drivers/net/ethernet/agere/et131x.c | 4 ++-- drivers/net/ethernet/allwinner/sun4i-emac.c | 6 +++--- drivers/net/ethernet/amd/7990.c | 4 ++-- drivers/net/ethernet/amd/a2065.c | 2 +- drivers/net/ethernet/amd/atarilance.c | 2 +- drivers/net/ethernet/amd/au1000_eth.c | 2 +- drivers/net/ethernet/amd/declance.c | 2 +- drivers/net/ethernet/amd/lance.c | 2 +- drivers/net/ethernet/amd/ni65.c | 4 ++-- drivers/net/ethernet/amd/nmclan_cs.c | 2 +- drivers/net/ethernet/amd/pcnet32.c | 4 ++-- drivers/net/ethernet/amd/sunlance.c | 2 +- drivers/net/ethernet/atheros/alx/main.c | 2 +- drivers/net/ethernet/broadcom/bcmsysport.c | 2 +- drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +- drivers/net/ethernet/broadcom/sb1250-mac.c | 2 +- drivers/net/ethernet/broadcom/tg3.c | 2 +- drivers/net/ethernet/cavium/liquidio/lio_main.c | 4 ++-- drivers/net/ethernet/cavium/octeon/octeon_mgmt.c | 2 +- drivers/net/ethernet/cavium/thunder/nicvf_main.c | 2 +- drivers/net/ethernet/chelsio/cxgb4vf/sge.c | 2 +- drivers/net/ethernet/davicom/dm9000.c | 4 ++-- drivers/net/ethernet/dec/tulip/de4x5.c | 4 ++-- drivers/net/ethernet/dec/tulip/dmfe.c | 6 +++--- drivers/net/ethernet/dec/tulip/pnic.c | 6 +++--- drivers/net/ethernet/dec/tulip/tulip_core.c | 2 +- drivers/net/ethernet/dec/tulip/uli526x.c | 4 ++-- drivers/net/ethernet/dec/tulip/winbond-840.c | 2 +- drivers/net/ethernet/dlink/dl2k.c | 2 +- drivers/net/ethernet/dlink/sundance.c | 2 +- drivers/net/ethernet/fealnx.c | 2 +- drivers/net/ethernet/freescale/gianfar.c | 2 +- drivers/net/ethernet/fujitsu/fmvj18x_cs.c | 2 +- drivers/net/ethernet/hisilicon/hix5hd2_gmac.c | 2 +- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 6 +++--- drivers/net/ethernet/hp/hp100.c | 2 +- drivers/net/ethernet/i825xx/82596.c | 2 +- drivers/net/ethernet/i825xx/lib82596.c | 2 +- drivers/net/ethernet/i825xx/sun3_82586.c | 4 ++-- drivers/net/ethernet/ibm/emac/core.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +- drivers/net/ethernet/korina.c | 8 ++++---- drivers/net/ethernet/lantiq_etop.c | 4 ++-- drivers/net/ethernet/marvell/pxa168_eth.c | 2 +- drivers/net/ethernet/marvell/sky2.c | 2 +- drivers/net/ethernet/micrel/ksz884x.c | 4 ++-- drivers/net/ethernet/microchip/encx24j600.c | 2 +- drivers/net/ethernet/moxa/moxart_ether.c | 2 +- drivers/net/ethernet/natsemi/natsemi.c | 2 +- drivers/net/ethernet/natsemi/sonic.c | 2 +- drivers/net/ethernet/nuvoton/w90p910_ether.c | 4 ++-- drivers/net/ethernet/packetengines/hamachi.c | 2 +- drivers/net/ethernet/packetengines/yellowfin.c | 2 +- drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c | 2 +- drivers/net/ethernet/qualcomm/qca_spi.c | 2 +- drivers/net/ethernet/realtek/atp.c | 2 +- drivers/net/ethernet/seeq/sgiseeq.c | 4 ++-- drivers/net/ethernet/sgi/meth.c | 4 ++-- drivers/net/ethernet/sis/sis900.c | 2 +- drivers/net/ethernet/smsc/epic100.c | 2 +- drivers/net/ethernet/smsc/smc911x.c | 6 +++--- drivers/net/ethernet/smsc/smc9194.c | 4 ++-- drivers/net/ethernet/smsc/smc91c92_cs.c | 4 ++-- drivers/net/ethernet/smsc/smc91x.c | 4 ++-- drivers/net/ethernet/sun/niu.c | 2 +- drivers/net/ethernet/sun/sungem.c | 2 +- drivers/net/ethernet/synopsys/dwc_eth_qos.c | 4 ++-- drivers/net/ethernet/tehuti/tehuti.c | 2 +- drivers/net/ethernet/ti/cpsw.c | 2 +- drivers/net/ethernet/ti/netcp_core.c | 4 ++-- drivers/net/ethernet/ti/tlan.c | 2 +- drivers/net/ethernet/tile/tilepro.c | 2 +- drivers/net/ethernet/toshiba/spider_net.c | 2 +- drivers/net/ethernet/via/via-rhine.c | 2 +- drivers/net/ethernet/wiznet/w5100.c | 2 +- drivers/net/ethernet/wiznet/w5300.c | 2 +- drivers/net/ethernet/xilinx/ll_temac_main.c | 2 +- drivers/net/ethernet/xilinx/xilinx_axienet_main.c | 2 +- drivers/net/ethernet/xilinx/xilinx_emaclite.c | 4 ++-- drivers/net/ethernet/xircom/xirc2ps_cs.c | 2 +- drivers/net/fjes/fjes_main.c | 2 +- drivers/net/hamradio/mkiss.c | 2 +- drivers/net/hamradio/scc.c | 2 +- drivers/net/hamradio/yam.c | 2 +- drivers/net/irda/ali-ircc.c | 8 ++++---- drivers/net/irda/bfin_sir.c | 2 +- drivers/net/irda/irda-usb.c | 4 ++-- drivers/net/irda/nsc-ircc.c | 8 ++++---- drivers/net/irda/smsc-ircc2.c | 2 +- drivers/net/irda/stir4200.c | 2 +- drivers/net/irda/via-ircc.c | 8 ++++---- drivers/net/slip/slip.c | 2 +- drivers/net/usb/catc.c | 4 ++-- drivers/net/usb/kaweth.c | 2 +- drivers/net/usb/lan78xx.c | 4 ++-- drivers/net/usb/pegasus.c | 2 +- drivers/net/usb/rtl8150.c | 4 ++-- drivers/net/usb/usbnet.c | 4 ++-- drivers/net/wan/cosa.c | 2 +- drivers/net/wan/farsync.c | 6 +++--- drivers/net/wan/lmc/lmc_main.c | 2 +- drivers/net/wan/sbni.c | 8 ++++---- drivers/net/wimax/i2400m/netdev.c | 2 +- drivers/net/wireless/cisco/airo.c | 6 +++--- drivers/net/wireless/intel/ipw2x00/ipw2100.c | 2 +- drivers/net/wireless/intel/ipw2x00/ipw2200.c | 6 +++--- drivers/net/wireless/intersil/hostap/hostap_hw.c | 2 +- drivers/net/wireless/intersil/orinoco/main.c | 2 +- drivers/net/wireless/intersil/orinoco/orinoco_usb.c | 2 +- drivers/net/wireless/marvell/mwifiex/init.c | 2 +- drivers/net/wireless/wl3501_cs.c | 2 +- drivers/net/wireless/zydas/zd1201.c | 2 +- drivers/s390/net/ctcm_main.c | 6 +++--- drivers/s390/net/ctcm_mpc.c | 2 +- drivers/s390/net/netiucv.c | 2 +- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 2 +- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 6 +++--- drivers/staging/rtl8192u/r8192U_core.c | 4 ++-- drivers/staging/wlan-ng/p80211netdev.c | 2 +- drivers/tty/n_gsm.c | 2 +- drivers/tty/synclink.c | 4 ++-- drivers/tty/synclink_gt.c | 4 ++-- drivers/tty/synclinkmp.c | 4 ++-- drivers/usb/gadget/function/u_ether.c | 2 +- net/atm/lec.c | 4 ++-- net/batman-adv/soft-interface.c | 2 +- net/bluetooth/bnep/netdev.c | 2 +- net/irda/irlan/irlan_eth.c | 2 +- net/sched/sch_generic.c | 2 +- 156 files changed, 232 insertions(+), 232 deletions(-) commit ba162f8eed61a7e71e26455ce1cff5b5898a3579 Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 16:31:00 2016 +0200 netdevice: add helper to update trans_start trans_start exists twice: - as member of net_device (legacy) - as member of netdev_queue In order to get rid of the legacy case, add a helper for the dev->trans_update (this patch), then convert spots that do dev->trans_start = jiffies to use this helper (next patch). This would then allow us to change the helper so that it updates the trans_stamp of netdev queue 0 instead. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 4d0e965732db6f7cce78e6b8f5d3073249004c3a Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 16:30:59 2016 +0200 drivers: replace dev->trans_start accesses with dev_trans_start a trans_start struct member exists twice: - in struct net_device (legacy) - in struct netdev_queue Instead of open-coding dev->trans_start usage to obtain the current trans_start value, use dev_trans_start() instead. This is not exactly the same, as dev_trans_start also considers the trans_start values of the netdev queues owned by the device and provides the most recent one. For legacy devices this doesn't matter as dev_trans_start can cope with netdev trans_start values of 0 (they are ignored). This is a prerequisite to eventual removal of dev->trans_start. Cc: linux-rdma@vger.kernel.org Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/infiniband/ulp/ipoib/ipoib_main.c | 2 +- drivers/net/ethernet/intel/e1000e/netdev.c | 2 +- drivers/net/ethernet/intel/igb/igb_main.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +- drivers/net/ethernet/microchip/encx24j600.c | 2 +- drivers/net/ethernet/qualcomm/qca_spi.c | 2 +- drivers/net/fjes/fjes_main.c | 2 +- drivers/net/hamradio/mkiss.c | 2 +- drivers/staging/rtl8192e/rtllib_softmac.c | 2 +- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) commit a6e5472dc3d99201d0f59dd4d1faf0dcf7d978c3 Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 18:53:15 2016 +0200 dmfe: kill DEVICE define use net_device directly. Compile tested, objdiff shows no changes. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/dec/tulip/dmfe.c | 39 ++++++++++++++++------------------- 1 file changed, 18 insertions(+), 21 deletions(-) commit 8bf42e9e51cce73874252e5b8fb938bb09bf0ce4 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue May 3 17:19:57 2016 +0200 gre6: add Kconfig dependency for NET_IPGRE_DEMUX The ipv6 gre implementation was cleaned up to share more code with the ipv4 version, but it can be enabled even when NET_IPGRE_DEMUX is disabled, resulting in a link error: net/built-in.o: In function `gre_rcv': :(.text+0x17f5d0): undefined reference to `gre_parse_header' ERROR: "gre_parse_header" [net/ipv6/ip6_gre.ko] undefined! This adds a Kconfig dependency to prevent that now invalid configuration. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 308edfdf1563 ("gre6: Cleanup GREv6 receive path, call common GRE functions") Acked-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/Kconfig | 1 + 1 file changed, 1 insertion(+) commit b8223bd1c49423a39a7da7e73cad8bf0e02bb032 Merge: 3f7496a 125372f Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 14:11:32 2016 -0400 Merge branch 'gre-teb' Jiri Benc says: ==================== gre: receive also TEB packets for lwtunnels NOTE: this patchset needs net merged to net-next. This allows lwtunnel users to get also packets with ETH_P_TEB protocol specified in GRE header through an ipgre interface. There's really nothing special about these packets in the case of lwtunnels - it's just an inner protocol like any other. The only complications stem from keeping compatibility with other uses of GRE. This will be used by openvswitch to support eth_push and eth_pop actions. I'd also like to see tc support for lwtunnels (this feature included) in the future. The first patch is not directly related and can be submitted standalone if needed. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 125372faa4feb15e86f410c1adabbca9186d9c4a Author: Jiri Benc <jbenc@redhat.com> Date: Tue May 3 17:10:08 2016 +0200 gre: receive also TEB packets for lwtunnels For ipgre interfaces in collect metadata mode, receive also traffic with encapsulated Ethernet headers. The lwtunnel users are supposed to sort this out correctly. This allows to have mixed Ethernet + L3-only traffic on the same lwtunnel interface. This is the same way as VXLAN-GPE behaves. To keep backwards compatibility and prevent any surprises, gretap interfaces have priority in receiving packets with Ethernet headers. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip_tunnels.h | 1 + net/ipv4/ip_gre.c | 39 ++++++++++++++++++++++++++++----------- 2 files changed, 29 insertions(+), 11 deletions(-) commit 244a797bdcf1b74567fa59d7e72d89ed0ee1ffd9 Author: Jiri Benc <jbenc@redhat.com> Date: Tue May 3 17:10:07 2016 +0200 gre: move iptunnel_pull_header down to ipgre_rcv This will allow to make the pull dependent on the tunnel type. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/ip_gre.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 00b2034029840ddad255352c46db0ae21342ce56 Author: Jiri Benc <jbenc@redhat.com> Date: Tue May 3 17:10:06 2016 +0200 gre: remove superfluous pskb_may_pull The call to gre_parse_header is either followed by iptunnel_pull_header, or in the case of ICMP error path, the actual header is not accessed at all. In the first case, iptunnel_pull_header will call pskb_may_pull anyway and it's pointless to do it twice. The only difference is what call will fail with what error code but the net effect is still the same in all call sites. In the second case, pskb_may_pull is pointless, as skb->data is at the outer IP header and not at the GRE header. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/gre_demux.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 3f7496aa72d3411579f996eb3998d1441906e99d Merge: 2754024 1edc57e Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 14:04:49 2016 -0400 Merge branch 'mlx5-sriov-updates' Saeed Mahameed says: ==================== Mellanox 100G ethernet SRIOV Upgrades This series introduces new features and upgrades for mlx5 etherenet SRIOV, while the first patch provides a bug fixes for a compilation issue introduced buy the previous aRFS series for when CONFIG_RFS_ACCEL=y and CONFIG_MLX5_CORE_EN=n. Changes from V0: - 1st patch: Don't add a new Kconfig flag. Instead, compile out en_arfs.c \ contents when CONFIG_RFS_ACCEL=n SRIOV upgrades: - Use synchronize_irq instead of the vport events spin_lock - Fix memory leak in error flow - Added full VST support - Spoofcheck support - Trusted VF promiscuous and allmulti support VST and Spoofcheck in details: - Adding Low level firmware commands support for creating ACLs (Access Control Lists) Flow tables. ACLs are regular flow tables with the only exception that they are bound to a specific e-Switch vport (VF) and they can be one of two types > egress ACL: filters traffic going from e-Switch to VF. > ingress ACL: filters traffic going from VF to e-Switch. - Ingress/Egress ACLs (per vport) for VF VST mode filtering. - Ingress/Egress ACLs (per vport) for VF spoofcheck filtering. - Ingress/Egress ACLs (per vport) configuration: > Created only when at least one of (VST, spoofcheck) is configured. > if (!spoofchk && !vst) allow all traffic. i.e. no ACLs. > if (spoofchk && vst) allow only untagged traffic with smac=original mac \ sent from the VF. > if (spoofchk && !vst) allow only traffic with smac=original mac sent from \ the VF. > if (!spoofchk && vst) allow only untagged traffic. Trusted VF promiscuous and allmulti support in details: - Added two flow groups for allmulti and promisc VFs to the e-Switch FDB table > Allmulti group: One rule that forwards any mcast traffic coming from either uplink or VFs/PF vports. > Promisc group: One rule that forwards all unmatched traffic coming from \ uplink. - Add vport context change event handling for promisc and allmulti If VF is trusted respect the request and: > if allmulti request: add the vport to the allmulti group. and to all other L2 mcast address in the FDB table. > if promisc request: add the vport to the promisc group. > Note: A promisc VF can only see traffic that was not explicitly matched to or requested by any other VF. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 1edc57e2b3d3bf8672bb1553dbd541cc94f54937 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:14:04 2016 +0300 net/mlx5: E-Switch, Implement trust vf ndo - Add support to configure trusted vf attribute through trust_vf_ndo. - Upon VF trust setting change we update vport context to refresh allmulti/promisc or any trusted vf attributes that we didn't trust the VF for before. - Lock the eswitch state lock on vport event in order to synchronise the vport context updates , this will prevent contention with vport trust setting change which will trigger vport mac list update. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 8 +++++ drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 40 ++++++++++++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 2 ++ 3 files changed, 45 insertions(+), 5 deletions(-) commit a35f71f27a614aff106cc89b86168962bce2725f Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:14:03 2016 +0300 net/mlx5: E-Switch, Implement promiscuous rx modes vf request handling Add promisc_change as a trigger to vport context change event. Add set vport promisc/allmulti functions to add vport to promiscuous flowtable rules. Upon promisc/allmulti rx mode vf request add the vport to the relevant promiscuous group (Allmulti/Promisc group) so the relevant traffic will be forwarded to it. Upon allmulti vf request add the vport to each existing multicast fdb rule. Upon adding/removing mcast address from a vport, update all other allmulti vports. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 269 +++++++++++++++++++++- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 4 + 2 files changed, 267 insertions(+), 6 deletions(-) commit 78a9199b7105fa0e843065fed0cca05a998a129b Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:14:02 2016 +0300 net/mlx5: E-Switch, Add promiscuous and allmulti FDB flowtable groups Add promiscuous and allmulti steering groups in FDB table. Besides the full match L2 steering rules group, we added two more groups to catch the "miss" rules traffic: * Allmulti group: One rule that forwards any mcast traffic coming from either uplink or VFs/PF vports * Promisc group: One rule that forwards all unmatched traffic coming from uplink. Needed for downstream privileged VF promisc and allmulti support. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 91 +++++++++++++++++++---- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 2 + 2 files changed, 79 insertions(+), 14 deletions(-) commit 586cfa7f1d58a7d480e548d4a9bef7f542a03257 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:14:01 2016 +0300 net/mlx5: E-Switch, Use vport event handler for vport cleanup Remove the usage of explicit cleanup function and use existing vport change handler. Calling vport change handler while vport is disabled will cleanup the vport resources. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 33 +++++++---------------- 1 file changed, 9 insertions(+), 24 deletions(-) commit 01f51f2247250eb69d2fd345c498eedbb078bb56 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:14:00 2016 +0300 net/mlx5: E-Switch, Enable/disable ACL tables on demand Enable ingress/egress ACL tables only when we need to configure ACL rules. Disable ingress/egress ACL tables once all ACL rules are removed. All VF outgoing/incoming traffic need to go through the ingress/egress ACL tables. Adding/Removing these tables on demand will save unnecessary hops in the flow steering when the ACL tables are empty. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 33 ++++++++++------------- 1 file changed, 14 insertions(+), 19 deletions(-) commit f942380c12394002efe0ca0be023e0f6fafbf29b Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:59 2016 +0300 net/mlx5: E-Switch, Vport ingress/egress ACLs rules for spoofchk Configure ingress and egress vport ACL rules according to spoofchk admin parameters. Ingress ACL flow table rules: if (!spoofchk && !vst) allow all traffic. else : 1) one of the following rules : * if (spoofchk && vst) allow only untagged traffic with smac=original mac sent from the VF. * if (spoofchk && !vst) allow only traffic with smac=original mac sent from the VF. * if (!spoofchk && vst) allow only untagged traffic. 2) drop all traffic that didn't hit #1. Add support for set vf spoofchk ndo. Add non zero mac validation in case of spoofchk to set mac ndo: when setting new mac we need to validate that the new mac is not zero while the spoofchk is on because it is illegal combination. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 9 ++ drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 112 ++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 3 + 3 files changed, 118 insertions(+), 6 deletions(-) commit dfcb1ed3c3315902e33da0fc5b0ae4c6d5086a23 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:58 2016 +0300 net/mlx5: E-Switch, Vport ingress/egress ACLs rules for VST mode Configure ingress and egress vport ACL rules according to vlan and qos admin parameters. Ingress ACL flow table rules: 1) drop any tagged packet sent from the VF 2) allow other traffic (default behavior) Egress ACL flow table rules: 1) allow only tagged traffic with vlan_tag=vst_vid. 2) drop other traffic. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 180 +++++++++++++++++++++- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 11 +- 2 files changed, 189 insertions(+), 2 deletions(-) commit 5742df0f7dbe54728145bf1136540c09c7fcb0d1 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:57 2016 +0300 net/mlx5: E-Switch, Introduce VST vport ingress/egress ACLs Create egress/ingress ACLs per VF vport at vport enable. Ingress ACL: - one flow group to drop all tagged traffic in VST mode. Egress ACL: - one flow group that allows only untagged traffic with smac that is equals to the original mac (anti-spoofing). - one flow group that allows only untagged traffic. - one flow group that allows only smac that is equals to the original mac (anti-spoofing). (note: only one of the above group has active rule) - star rule will be used to drop all other traffic. By default no rules are generated, unless VST is explicitly requested. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 258 ++++++++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 18 ++ 2 files changed, 276 insertions(+) commit 761e205b559be52852d85e0db4a034c9f57965f9 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:56 2016 +0300 net/mlx5: E-Switch, Fix error flow memory leak Fix memory leak in case query nic vport command failed. Fixes: 81848731ff40 ('net/mlx5: E-Switch, Add SR-IOV (FDB) support') Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 831cae1daead92c4b9c3e149c6bc14853902c204 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:55 2016 +0300 net/mlx5: E-Switch, Replace vport spin lock with synchronize_irq() Vport spin lock can be replaced with synchronize_irq() in the right place, this will remove the need of locking inside irq context. Locking in esw_enable_vport is not required since vport events are yet to be enabled, and at esw_disable_vport it is sufficient to synchronize_irq() to guarantee no further vport events handlers will be scheduled. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 11 ++--------- drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 5 ----- 2 files changed, 2 insertions(+), 14 deletions(-) commit efdc810ba39dae0ccce9cb9c1c84ff9b0157ca43 Author: Mohamad Haj Yahia <mohamad@mellanox.com> Date: Tue May 3 17:13:54 2016 +0300 net/mlx5: Flow steering, Add vport ACL support Update the relevant flow steering device structs and commands to support vport. Update the flow steering core API to receive vport number. Add ingress and egress ACL flow table name spaces. Add ACL flow table support: * ACL (Access Control List) flow table is a table that contains only allow/drop steering rules. * We have two types of ACL flow tables - ingress and egress. * ACLs handle traffic sent from/to E-Switch FDB table, Ingress refers to traffic sent from Vport to E-Switch and Egress refers to traffic sent from E-Switch to vport. * Ingress ACL flow table allow/drop rules is checked against traffic sent from VF. * Egress ACL flow table allow/drop rules is checked against traffic sent to VF. Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c | 33 +++++++++ drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.h | 1 + drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 85 ++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlx5/core/fs_core.h | 7 +- .../net/ethernet/mellanox/mlx5/core/mlx5_core.h | 2 + include/linux/mlx5/device.h | 12 +++ include/linux/mlx5/driver.h | 2 + include/linux/mlx5/fs.h | 7 ++ 9 files changed, 142 insertions(+), 9 deletions(-) commit fbc4a69b562e38d6946bc8bd7e97d30fe0acd5d0 Author: Maor Gottlieb <maorg@mellanox.com> Date: Tue May 3 17:13:53 2016 +0300 net/mlx5e: Fix aRFS compilation dependency en_arfs.o should be compiled only if both CONFIG_MLX5_CORE_EN and CONFIG_RFS_ACCEL are enabled. en_arfs calls to rps_may_expire_flow which is compiled only if CONFIG_RFS_ACCEL is defined. Move en_arfs.o compilation dependency to be under CONFIG_MLX5_CORE_EN and wrap the en_arfs.c content with ifdef of CONFIG_RFS_ACCEL. Fixes: 1cabe6b0965e ('net/mlx5e: Create aRFS flow tables') Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Reported-by: Alexei Starovoitov <alexei.starovoitov@gmail.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/Makefile | 3 +-- drivers/net/ethernet/mellanox/mlx5/core/en_arfs.c | 3 +++ 2 files changed, 4 insertions(+), 2 deletions(-) commit 8be0fca6ddb026c0eed8f67f97537742c68a906a Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Mon Apr 25 15:22:52 2016 +0200 ARM: sun5i: chip: Enable the TV Encoder The CHIP has a composite output available muxed with the microphone in the micro-jack plug. Enable the composite output in its DTS. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-r8-chip.dts | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 00e1d6d0c0ce5f7ebc9fa3912e0d54c13b89a561 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Mon Apr 25 15:22:51 2016 +0200 ARM: sun5i: r8: Add display blocks to the DTSI The TCON, tv-encoder and display engine backends and frontends are combined to create our display pipeline. Add them to the R8 DTSI. It's supposed to be perfectly compatible with the A10s and A13, but since we haven't tested it on them yet, it's safer to just enable it on the R8. Eventually, it should be moved to sun5i.dtsi Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-r8.dtsi | 137 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) commit 6b70991043b37ebd2c6e814d120d84f45dc4cc69 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Mon Apr 25 15:22:43 2016 +0200 ARM: sun5i: a13: Add display and TCON clocks Enable the display and TCON (channel 0 and channel 1) clocks that are going to be needed to drive the display engine, tcon and TV encoders. Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-a13.dtsi | 39 +++++++++++++++++++++++++++++++++++++-- arch/arm/boot/dts/sun5i-r8.dtsi | 5 +++-- 2 files changed, 40 insertions(+), 4 deletions(-) commit 27540247c595b0244b96d4f65c8a09db3f2c1aa8 Merge: ecc9120 f358738 Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 13:59:28 2016 -0400 Merge branch 'cxgb4-mbox' Hariprasad Shenai says: ==================== cxgb4: mbox enhancements for cxgb4 This patch series checks for firmware errors when we are waiting for mbox response in a loop and breaks out. When negative timeout is passed to mailbox code, don't sleep. Negative timeout is passed only from interrupt context. This patch series has been created against net-next tree and includes patches on cxgb4 driver. We have included all the maintainers of respective drivers. Kindly review the change and let us know in case of any review comments. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f358738b1d64935b54430613691a6ef8c1f6d450 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue May 3 18:58:02 2016 +0530 cxgb4: Check for firmware errors in the mailbox command loop Check for firmware errors in the mailbox command loop and report them differently rather than simply timing out when the firmware goes belly up. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 5a20f5cfd7276862a8d21d75f83359840ed6e662 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue May 3 18:58:01 2016 +0530 cxgb4: Don't sleep when mbox cmd is issued from interrupt context When link goes down, from the interrupt handler DCB priority for the Tx queues needs to be unset. We issue mbox command to unset the Tx queue priority with negative timeout. In t4_wr_mbox_meat_timeout() do not sleep when negative timeout is passed, since it is called from interrupt context. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 6 ++++++ 1 file changed, 6 insertions(+) commit ecc9120e054b08024b096d8a3a96f81df5fc906c Author: Christian Lamparter <chunkeey@googlemail.com> Date: Tue May 3 14:08:30 2016 +0200 drivers: net: emac: add Atheros AR8035 phy initialization code This patch adds the phy initialization code for Qualcomm Atheros AR8035 phy. This configuration is found in the Cisco Meraki MR24. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ibm/emac/phy.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 74f430cd0fdee1bdfb25708ee1e52fc860535a89 Author: Sasha Levin <sasha.levin@oracle.com> Date: Wed May 4 10:18:15 2016 -0400 Yama: use atomic allocations when reporting Access reporting often happens from atomic contexes. Avoid lockups when allocating memory for command lines. Fixes: 8a56038c2ae ("Yama: consolidate error reporting") Signed-off-by: Sasha Levin <sasha.levin@oracle.com> security/yama/yama_lsm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 470bf1f27a1472264d18c84b324389509f0e30b3 Author: Mickaël Salaün <mic@digikod.net> Date: Thu Mar 24 02:46:33 2016 +0100 seccomp: Fix comment typo Drop accidentally repeated word in comment. Signed-off-by: Mickaël Salaün <mic@digikod.net> Cc: Kees Cook <keescook@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Will Drewry <wad@chromium.org> kernel/seccomp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 53da5b47cb6eeaa9aa80772219eadb4cce1abcb6 Merge: f132ae7 152971e Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 13:32:29 2016 -0400 Merge branch 'tunnel-features-and-gso-partial' Alexander Duyck says: ==================== Fix Tunnel features and enable GSO partial for several drivers This patch series is meant to allow us to get the best performance possible for Mellanox ConnectX-3/4 and Broadcom NetXtreme-C/E adapters in terms of VXLAN and GRE tunnels. The first 3 patches address issues I found in regards to GSO_PARTIAL and TSO_MANGLEID. The next 4 patches go through and enable GSO_PARTIAL for VXLAN tunnels that have an outer checksum enabled, and then enable IPv6 support where I can. One outstanding issue is that I wasn't able to get offloads working with outer IPv6 headers on mlx4. However that wasn't a feature that was enabled before so it isn't technically a regression, however I believe Engineers from Mellanox said they would look into it since they thought it should be supported. The last patch enables GSO_PARTIAL for VXLAN and GRE tunnels on the bnxt driver. One piece of feedback I received on the patch was that the hardware has globally set IPv6 UDP tunnels to always have the checksum field computed. I plan to work with Broadcom to get that addressed so that we only populate the checksum field if it was requested by the network stack. v2: Rebased patches off of latest changes to the mlx4/mlx5 drivers. Added bnxt driver patch as I received feedback on the RFC. v3: Moved 2 patches into series for net as they were generic fixes. Added patch to disable GSO partial if frame is less than 2x size of MSS There are outstanding issues as called out above that need to be addressed, however they were present before these patches so it isn't as if they introduce a regression. In addition gains can be easily seen so there should be no issue with applying the driver patches while the IPv6 mlx4_en and bnxt issues are being researched. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 152971ee75fddbc43fb6cf7e3ada96c1324df2af Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:55 2016 -0700 bnxt: Add support for segmentation of tunnels with outer checksums This patch assumes that the bnxt hardware will ignore existing IPv4/v6 header fields for length and checksum as well as the length and checksum fields for outer UDP and GRE headers. I have been told by Michael Chan that this is working. Though this might be somewhat redundant for IPv6 as they are forcing the checksum to be computed for all IPv6 frames that are offloaded. A follow-up patch may be necessary in order to fix this as it is essentially mangling the outer IPv6 headers to add a checksum where none was requested. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit f3ed653cd4191ce42b27b2fb524418832f7d6c2d Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:49 2016 -0700 net/mlx5e: Fix IPv6 tunnel checksum offload The mlx5 driver exposes support for TSO6 but not IPv6 csum for hardware encapsulated tunnels. This leads to issues as it triggers warnings in skb_checksum_help as it ends up being called as we report supporting the segmentation but not the checksumming for IPv6 frames. This patch corrects that and drops 2 features that don't actually need to be supported in hw_enc_features since they are Rx features and don't actually impact anything by being present in hw_enc_features. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit b49663c8fb4908cc548afd27aa950c07f4e421d5 Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:43 2016 -0700 net/mlx5e: Add support for UDP tunnel segmentation with outer checksum offload This patch assumes that the mlx5 hardware will ignore existing IPv4/v6 header fields for length and checksum as well as the length and checksum fields for outer UDP headers. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 09067122db3b7fb9cd329fcc16cee12e8f6babcf Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:37 2016 -0700 net/mlx4_en: Add support for inner IPv6 checksum offloads and TSO >From what I can tell the ConnectX-3 will support an inner IPv6 checksum and segmentation offload, however it cannot support outer IPv6 headers. This assumption is based on the fact that I could see the checksum being offloaded for inner header on IPv4 tunnels, but not on IPv6 tunnels. For this reason I am adding the feature to the hw_enc_features and adding an extra check to the features_check call that will disable GSO and checksum offload in the case that the encapsulated frame has an outer IP version of that is not 4. The check in mlx4_en_features_check could be removed if at some point in the future a fix is found that allows the hardware to offload segmentation/checksum on tunnels with an outer IPv6 header. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 25 ++++++++++++++++++++----- drivers/net/ethernet/mellanox/mlx4/en_tx.c | 15 +++++++++++++-- 2 files changed, 33 insertions(+), 7 deletions(-) commit 3c9346b24001523a763c28478b49064589d1c8ab Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:30 2016 -0700 net/mlx4_en: Add support for UDP tunnel segmentation with outer checksum offload This patch assumes that the mlx4 hardware will ignore existing IPv4/v6 header fields for length and checksum as well as the length and checksum fields for outer UDP headers. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit b1dc497b28ad053d1f6d5b5cb186af9564e4d7f1 Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:24 2016 -0700 net: Fix netdev_fix_features so that TSO_MANGLEID is only available with TSO This change makes it so that we will strip the TSO_MANGLEID bit if TSO is not present. This way we will also handle ECN correctly of TSO is not present. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 4 ++++ 1 file changed, 4 insertions(+) commit 36c983824b6f17b93258153ff5b05c33c34e44ba Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:18 2016 -0700 gso: Only allow GSO_PARTIAL if we can checksum the inner protocol This patch addresses a possible issue that can occur if we get into any odd corner cases where we support TSO for a given protocol but not the checksum or scatter-gather offload. There are few drivers floating around that setup their tunnels this way and by enforcing the checksum piece we can avoid mangling any frames. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/skbuff.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d7fb5a80492169cd737d51042f4ee03b09be0ef6 Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon May 2 09:38:12 2016 -0700 gso: Do not perform partial GSO if number of partial segments is 1 or less In the event that the number of partial segments is equal to 1 we don't really need to perform partial segmentation offload. As such we should skip multiplying the MSS and instead just clear the partial_segs value since it will not provide any gain to advertise the frame as being GSO when it is a single frame. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/skbuff.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 792f7525ac8b9f13df8a4849b25fa4d4a2ac3400 Merge: e6c037b 764763f Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Wed May 4 10:25:58 2016 -0700 Merge tag 'usb-ci-v4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/peter.chen/usb into usb-next Hi Greg, below are changes for chipidea and OTG FSM, no major changes. Some for documentation, some for tiny changes, thanks. commit 7e885d211f023dfd201fad8246bbf3c3bd126c61 Author: John Keeping <john@metanate.com> Date: Wed May 4 17:21:57 2016 +0100 ASoC: rockchip: Revert "ASoC: rockchip: i2s: separate capture and playback" This reverts commit eba65d179c1149cf79e68608d452631f33d7f017. This broke audio on Veyron Jerry Chromebooks and I now cannot reproduce the problem I was trying to fix even with this commit reverted, so it seems that this was completely the wrong thing to do. Reported-by: Enric Balletbo Serra <eballetbo@gmail.com> Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/rockchip/rockchip_i2s.c | 72 ++++++++++++++++++++++----------------- 1 file changed, 40 insertions(+), 32 deletions(-) commit a6e806c49e3265494ac6fe6ec88ed5c010652e0d Author: John Keeping <john@metanate.com> Date: Wed May 4 17:21:56 2016 +0100 ASoC: rockchip: Revert "ASoC: rockchip: i2s: remove unused variables" This reverts commit 5938448b99275cba95167c3f9d39ca9225fdad38. It turns out that the commit that made these variables unused is wrong so we're about to revert it. Bring back the variables in prepration. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/rockchip/rockchip_i2s.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 721be3be2f75c69cf0f2d7826007a6eefee7dac3 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 17:11:56 2016 +0100 ASoC: wm_adsp: Detach compressed stream on free If someone powers down the DSP core (through routing changes say) whilst a compressed record is in progress we can end up using a freed pointer to the buffer object. When a compressed audio stream is triggered we attach it to a buffer on a physical DSP. This patch adds a detach of the buffer from the stream when the stream is freed or when the DSP is powered down which avoids the situation where we use a buffer when it is no longer valid. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit edd713509ae46ffcf178e3b1431af1ca202be8ba Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed May 4 17:11:55 2016 +0100 ASoC: wm_adsp: Move compr_attach/attached functions Move wm_adsp_compr_attach and wm_adsp_compr_attached functions so they will stay logically grouped with similar functions after some additional changes. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) commit 0023f8a6d5c22b2bed0f21d79805c6baee397620 Merge: 9ee7875 56574d5 Author: Mark Brown <broonie@kernel.org> Date: Wed May 4 17:51:26 2016 +0100 Merge branch 'topic/arizona' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-adsp commit f132ae7c46370c981412a68ccec9f2145812a9b6 Author: Jiri Benc <jbenc@redhat.com> Date: Tue May 3 15:00:21 2016 +0200 gre: change gre_parse_header to return the header length It's easier for gre_parse_header to return the header length instead of filing it into a parameter. That way, the callers that don't care about the header length can just check whether the returned value is lower than zero. In gre_err, the tunnel header must not be pulled. See commit b7f8fe251e46 ("gre: do not pull header in ICMP error processing") for details. This patch reduces the conflict between the mentioned commit and commit 95f5c64c3c13 ("gre: Move utility functions to common headers"). Signed-off-by: Jiri Benc <jbenc@redhat.com> Acked-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/gre.h | 2 +- net/ipv4/gre_demux.c | 6 +++--- net/ipv4/ip_gre.c | 9 +++------ net/ipv6/ip6_gre.c | 3 ++- 4 files changed, 9 insertions(+), 11 deletions(-) commit d4011239f46ac6e407af61e3f74d1e3874fc9394 Author: Eric Dumazet <edumazet@google.com> Date: Mon May 2 21:49:25 2016 -0700 tcp: guarantee forward progress in tcp_sendmsg() Under high rx pressure, it is possible tcp_sendmsg() never has a chance to allocate an skb and loop forever as sk_flush_backlog() would always return true. Fix this by calling sk_flush_backlog() only if one skb had been allocated and filled before last backlog check. Fixes: d41a69f1d390 ("tcp: make tcp_sendmsg() aware of socket backlog") Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit d55201ce08bfae40ae0062be126f49471a55bcad Merge: b6e17c1 56104cf Author: David Howells <dhowells@redhat.com> Date: Wed May 4 17:20:20 2016 +0100 Merge branch 'keys-trust' into keys-next Here's a set of patches that changes how certificates/keys are determined to be trusted. That's currently a two-step process: (1) Up until recently, when an X.509 certificate was parsed - no matter the source - it was judged against the keys in .system_keyring, assuming those keys to be trusted if they have KEY_FLAG_TRUSTED set upon them. This has just been changed such that any key in the .ima_mok keyring, if configured, may also be used to judge the trustworthiness of a new certificate, whether or not the .ima_mok keyring is meant to be consulted for whatever process is being undertaken. If a certificate is determined to be trustworthy, KEY_FLAG_TRUSTED will be set upon a key it is loaded into (if it is loaded into one), no matter what the key is going to be loaded for. (2) If an X.509 certificate is loaded into a key, then that key - if KEY_FLAG_TRUSTED gets set upon it - can be linked into any keyring with KEY_FLAG_TRUSTED_ONLY set upon it. This was meant to be the system keyring only, but has been extended to various IMA keyrings. A user can at will link any key marked KEY_FLAG_TRUSTED into any keyring marked KEY_FLAG_TRUSTED_ONLY if the relevant permissions masks permit it. These patches change that: (1) Trust becomes a matter of consulting the ring of trusted keys supplied when the trust is evaluated only. (2) Every keyring can be supplied with its own manager function to restrict what may be added to that keyring. This is called whenever a key is to be linked into the keyring to guard against a key being created in one keyring and then linked across. This function is supplied with the keyring and the key type and payload[*] of the key being linked in for use in its evaluation. It is permitted to use other data also, such as the contents of other keyrings such as the system keyrings. [*] The type and payload are supplied instead of a key because as an optimisation this function may be called whilst creating a key and so may reject the proposed key between preparse and allocation. (3) A default manager function is provided that permits keys to be restricted to only asymmetric keys that are vouched for by the contents of the system keyring. A second manager function is provided that just rejects with EPERM. (4) A key allocation flag, KEY_ALLOC_BYPASS_RESTRICTION, is made available so that the kernel can initialise keyrings with keys that form the root of the trust relationship. (5) KEY_FLAG_TRUSTED and KEY_FLAG_TRUSTED_ONLY are removed, along with key_preparsed_payload::trusted. This change also makes it possible in future for userspace to create a private set of trusted keys and then to have it sealed by setting a manager function where the private set is wholly independent of the kernel's trust relationships. Further changes in the set involve extracting certain IMA special keyrings and making them generally global: (*) .system_keyring is renamed to .builtin_trusted_keys and remains read only. It carries only keys built in to the kernel. It may be where UEFI keys should be loaded - though that could better be the new secondary keyring (see below) or a separate UEFI keyring. (*) An optional secondary system keyring (called .secondary_trusted_keys) is added to replace the IMA MOK keyring. (*) Keys can be added to the secondary keyring by root if the keys can be vouched for by either ring of system keys. (*) Module signing and kexec only use .builtin_trusted_keys and do not use the new secondary keyring. (*) Config option SYSTEM_TRUSTED_KEYS now depends on ASYMMETRIC_KEY_TYPE as that's the only type currently permitted on the system keyrings. (*) A new config option, IMA_KEYRINGS_PERMIT_SIGNED_BY_BUILTIN_OR_SECONDARY, is provided to allow keys to be added to IMA keyrings, subject to the restriction that such keys are validly signed by a key already in the system keyrings. If this option is enabled, but secondary keyrings aren't, additions to the IMA keyrings will be restricted to signatures verifiable by keys in the builtin system keyring only. Signed-off-by: David Howells <dhowells@redhat.com> commit 8340ab60b3624386eaa24fa21bdb4e6775066ccf Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon May 2 14:53:29 2016 +0200 s390/3270: avoid endless I/O loop with disconnected 3270 terminals If a 3270 terminal is disconnected while the tty view is active the 3270 driver goes into an endless loop of failed I/O requests until the terminal is connected again. Add code to the raw3270 interrupt handler to check for unit checks due to failed I/O requests and put the device to sleep with the RAW3270_FLAGS_BUSY flag until a unsolicited device end interrupt indicates that the device can be used again. while we are at it simplify the 3270 irq handling and remove unnecessary code. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/con3270.c | 3 +- drivers/s390/char/fs3270.c | 3 +- drivers/s390/char/raw3270.c | 101 +++++++++----------------------------------- drivers/s390/char/raw3270.h | 8 +--- drivers/s390/char/tty3270.c | 3 +- 5 files changed, 23 insertions(+), 95 deletions(-) commit 2e63a3a66655d5fe5d85c090b009979870436c00 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Thu Apr 28 16:32:13 2016 +0200 s390/3270: fix garbled output on 3270 tty view The tty3270_update function tries to optimize the output stream by skipping the TO_SBA command to position the output offset if the TO_RA command of the previous line ended at the same offset. But some lines do not have the TO_RA at the end, namely those with a length equal to the number of columns. Make sure there is a TO_RA at the end of the previous line to avoid funny looking output. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/tty3270.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit b512353c15fe7665893e92e0c989c088505a37b8 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon May 2 13:49:28 2016 +0200 s390/3270: fix view reference counting The tty3270_close function set tty->driver_data to NULL after the open count dropped to zero but tty3270_cleanup still needs the pointer to the tty3270 view to drop the reference count. Move the clearing of tty->driver_data to tty3270_cleanup and drop the unnecessary tty_port_tty_set calls in tty3270_install. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/tty3270.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit 5ff04fe5659f78c0450cc6858b12bba9e4049578 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Wed Apr 27 14:32:06 2016 +0200 s390/3270: add missing tty_kref_put The tty3270_resize_work functions acquires a reference to the tty to call tty_do_resize but fails to release the reference again. Add the missing tty_kref_put. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/tty3270.c | 1 + 1 file changed, 1 insertion(+) commit 5606330627ab680f5e6b7549d14ec3ffdae58c15 Author: Heiko Carstens <heiko.carstens@de.ibm.com> Date: Mon May 2 14:38:29 2016 +0200 s390/dumpstack: implement and use return_address() Implement return_address() and use it instead of __builtin_return_address(n). __builtin_return_address(n) is not guaranteed to work for n > 0, therefore implement a private return_address() function which walks the stack frames and returns the proper return address. This way we get also rid of a compile warning which gcc 6.1 emits and look like all other architectures. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/include/asm/ftrace.h | 4 +++- arch/s390/kernel/dumpstack.c | 24 ++++++++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) commit 8ba811a7d2f0f86a37bd8aaaff35ce1004633430 Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue May 3 11:59:30 2016 -0700 spi: Fix simple typo s/impelment/implement This fixes a simple typo in one of the comments. Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5de7ed0c980c4bcfd8ea5c0b84a61b76df7d6c08 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed May 4 09:25:46 2016 +0300 spi: rockchip: potential NULL dereference on error We were calling dma_release_channel(rs->dma_tx.ch) when "rs->dma_tx.ch" is potentially NULL. There is actually a call to that in the unwind code at the bottom of the function so we can just re-arrange this a bit and remove the call. Also there is no need to set rs->dma_tx.ch to NULL on this error path. Fixes: e4c0e06f949b ('spi: rockchip: fix probe deferral handling') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-rockchip.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 3d277b177918cd26215732fc23af0783ab4b37dd Merge: f55532a 02da2d7 Author: Mark Brown <broonie@kernel.org> Date: Wed May 4 14:41:51 2016 +0100 Merge tag 'v4.6-rc5' into spi-rockchip Linux 4.6-rc5 commit 6d3e7fddb39a4f0a47c8042df11554bb61d7a4aa Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed May 4 14:10:44 2016 +0200 drm: Fixup locking WARN_ON mistake around gem_object_free_unlocked Embarrassingly while fixing up the old paths for i915 I managed to misplace a locking check for the new _unlocked paths. That's what I get for not retesting on radeon. Fixes: 9f0ba539d13a ("drm/gem: support BO freeing without dev->struct_mutex") Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Alex Deucher <alexdeucher@gmail.com> Cc: Lucas Stach <l.stach@pengutronix.de> Tested-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> drivers/gpu/drm/drm_gem.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit ba412e343d8bd628c1568a9b130210cc7d55e01c Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Wed May 4 17:27:50 2016 +0530 spi: zynqmp: disable clocks in error paths The if pclk enable fails the refclk is not disabled. Fix the same. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-zynqmp-gqspi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 74d2a91aec97ab832790c9398d320413ad185321 Author: Lei Liu <lei35151@163.com> Date: Wed May 4 16:34:22 2016 +0800 USB: serial: option: add even more ZTE device ids Add even more ZTE device ids. Signed-off-by: lei liu <liu.lei78@zte.com.cn> Cc: stable <stable@vger.kernel.org> [johan: rebase and replace commit message ] Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/option.c | 54 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) commit 802ac39a55664b15dd162e3444d5be34045abeeb Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed May 4 09:43:24 2016 +0800 mmc: sdhci-of-arasan: fix set_clock when a phy is supported commit 61b914eb81f8 ("mmc: sdhci-of-arasan: add phy support for sdhci-of-arasan") introduce phy support for arasan. According to the vendor's databook, we should make sure the phy is in poweroff status before we configure the clk stuff. Otherwise it may cause some IO sample timing issues from the test. And we don't need this extra operation while running in low performance mode since phy doesn't trigger sampling block. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-of-arasan.c | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) commit d15b08fb2246fa28b4cf01337951026177641af4 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Wed May 4 11:23:08 2016 +0300 mmc: omap: Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> CC: Ulf Hansson <ulf.hansson@linaro.org> CC: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/omap.c | 48 +++++++++++++++++++++++++----------------------- 1 file changed, 25 insertions(+), 23 deletions(-) commit 437db4c6e79881d33aca521987188c728df350a8 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Wed May 4 10:38:21 2016 +0300 mmc: mmc: Attempt to flush cache before reset CMD0 or hardware reset may invalidate the cache, so it needs to be flushed before reset. In the case of recovery, we can't expect flushing the cache to work always, but have a go and ignore errors. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 1d657c58dd16ed8fad938f3662774de15d35ce0a Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:49 2016 +0200 drm/etnaviv: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Christian Gmeiner <christian.gmeiner@gmail.com> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Lucas Stach <l.stach@pengutronix.de> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Lucas Stach <l.stach@pengutronix.de> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-17-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/etnaviv/etnaviv_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4b193663dbc915a1f9c61d1785d3f0b4d98cfafd Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:52 2016 +0200 drm/imx: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-20-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/imx/imx-drm-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71cbf451eb2715865e3dbd0ec55837dac1148d23 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:56 2016 +0200 drm/radeon: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-24-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/radeon/radeon_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e7294dee52cccb8d7119998817a1bc51eb2273d3 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:43 2016 +0200 drm/amdgpu: Use lockless gem BO free callback No dev->struct_mutex anywhere to be seen. Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-11-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9f0ba539d13aebacb05dda542df7ef80684b2c70 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon May 2 10:40:51 2016 +0200 drm/gem: support BO freeing without dev->struct_mutex Finally all the core gem and a lot of drivers are entirely free of dev->struct_mutex depencies, and we can start to have an entirely lockless unref path. To make sure that no one who touches the core code accidentally breaks existing drivers which still require dev->struct_mutex I've made the might_lock check unconditional. While at it de-inline the ref/unref functions, they've become a bit too big. v2: Make it not leak like a sieve. v3: Review from Lucas: - drop != NULL in pointer checks. - fixup copypasted kerneldoc to actually match the functions. v4: Add __drm_gem_object_unreference as a fastpath helper for drivers who abolished dev->struct_mutex, requested by Chris. v5: Fix silly mistake in drm_gem_object_unreference_unlocked caught by intel-gfx CI - I checked for gem_free_object instead of gem_free_object_unlocked ... Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Alex Deucher <alexdeucher@gmail.com> Cc: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Lucas Stach <l.stach@pengutronix.de> (v3) Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (v4) Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462178451-1765-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_gem.c | 54 ++++++++++++++++++++++++++++++++++++++++++++++- include/drm/drmP.h | 15 ++++++++++--- include/drm/drm_gem.h | 48 +++++++++++++---------------------------- 3 files changed, 80 insertions(+), 37 deletions(-) commit 53dfc3b9e6c54d077f578f9016b6c8ab5f891e10 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 14:02:41 2016 +0200 iio: light: bh1780: return after write When writing a value using direct reg access from debugfs we need to return and not fall through to reading the value, lest we'll dereference a NULL pointer. Cc: Dan Carpenter <dan.carpenter@oracle.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/bh1780.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4946dd2e14d252cd04e188ed6a4b794541d1c3ce Merge: 090e1a7 c84ffde Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 19:53:15 2016 +1000 Merge tag 'drm-hisilicon-next-2016-04-29' of github.com:xin3liang/linux into drm-next drm-hisilicon-next for 4.7 Add new hisilicon kirin drm driver: - Add maintainer for hisilicon DRM driver - Add support for external bridge - Add designware dsi host driver - Add designware dsi encoder driver - Add cma fbdev and hotplug - Add vblank driver for ADE - Add plane driver for ADE - Add crtc driver for ADE - Add hisilicon kirin drm master driver - Add device tree binding for hi6220 display subsystem * tag 'drm-hisilicon-next-2016-04-29' of github.com:xin3liang/linux: MAINTAINERS: Add maintainer for hisilicon DRM driver drm/hisilicon: Add support for external bridge drm/hisilicon: Add designware dsi host driver drm/hisilicon: Add designware dsi encoder driver drm/hisilicon: Add cma fbdev and hotplug drm/hisilicon: Add vblank driver for ADE drm/hisilicon: Add plane driver for ADE drm/hisilicon: Add crtc driver for ADE drm/hisilicon: Add hisilicon kirin drm master driver drm/hisilicon: Add device tree binding for hi6220 display subsystem commit 04bf02175fe9577875fb8285cc2d08169fef613a Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 29 12:03:31 2016 +0300 iio: dac: ad5592r: Off by one bug in ad5592r_alloc_channels() The > here should be >= or we go beyond the end for the array. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/dac/ad5592r-base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c25d3f37be016b301f446a5257645c4845daf53c Author: Daniel Baluta <daniel.baluta@intel.com> Date: Fri Apr 29 14:42:34 2016 +0300 iio: bmi160: Fix ODR setting mask and val parameters of regmap_update_bits were reveresed. Fixes: 77c4ad2d6a9 ("iio: imu: Add initial support for Bosch BMI160") Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/bmi160/bmi160_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5ec97ba0713d118a1cd03ccc7677a13769253bbd Author: Daniel Baluta <daniel.baluta@intel.com> Date: Fri Apr 29 14:42:33 2016 +0300 iio: bmi160: Fix output data rate for accel Format is INT_PLUS_MICRO and micro odr part of ODR should be parts of a micro. Also s/8000/800 this is obviously a typo. Fixes: 77c4ad2d6a9 ("iio: imu: Add initial support for Bosch BMI160") Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/bmi160/bmi160_core.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit b8f3ebe630a4f1b4ff9340103d3b565ad5d78d43 Author: Minghuan Lian <Minghuan.Lian@nxp.com> Date: Wed Mar 23 19:08:20 2016 +0800 irqchip: Add Layerscape SCFG MSI controller support Some kind of Freescale Layerscape SoC provides a MSI implementation which uses two SCFG registers MSIIR and MSIR to support 32 MSI interrupts for each PCIe controller. The patch is to support it. Signed-off-by: Minghuan Lian <Minghuan.Lian@nxp.com> Tested-by: Alexander Stein <alexander.stein@systec-electronic.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> drivers/irqchip/Kconfig | 5 + drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-ls-scfg-msi.c | 240 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 246 insertions(+) commit edc5b05566dfc9b213604c09f25aa3abf8cb0ab9 Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Fri Mar 4 11:08:09 2016 +0100 KVM: s390: support NQ only if the facility is enabled for the guest While we can not fully fence of the Nonquiescing Key-Setting facility, we should as try our best to hide it. Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/priv.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 4a5e7e381f9d7ab92fd8f9280683dae11698292e Author: David Hildenbrand <dahi@linux.vnet.ibm.com> Date: Tue Apr 12 13:32:25 2016 +0200 KVM: s390: cmma: don't check entry content We should never inject an exception after we manually rewound the PSW (to retry the ESSA instruction in this case). This will mess up the PSW. So this never worked and therefore never really triggered. Looking at the details, we don't even have to perform any validity checks. 1. Bits 52-63 of an entry are stored as 0 by the hardware. 2. We are dealing with absolute addresses but only check for the prefix starting at address 0. This isn't correct and doesn't make much sense, cpus could still zap the prefix of other cpus. But as prefix pages cannot be swapped out without a notifier being called for the affected VCPU, a zap can never remove a protected prefix. Reviewed-by: Dominik Dingel <dingel@linux.vnet.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> arch/s390/kvm/priv.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 5e79cb29ddbd1d354398308309337ba013245469 Author: Minghuan Lian <Minghuan.Lian@nxp.com> Date: Wed Mar 23 19:08:19 2016 +0800 dt/bindings: Add bindings for Layerscape SCFG MSI Some Layerscape SoCs use a simple MSI controller implementation. It contains only two SCFG register to trigger and describe a group 32 MSI interrupts. The patch adds bindings to describe the controller. Signed-off-by: Minghuan Lian <Minghuan.Lian@nxp.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> .../interrupt-controller/fsl,ls-scfg-msi.txt | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit 88acff64c621aaeee2a4fe0ed124c77358069bce Author: Anand Jain <anand.jain@oracle.com> Date: Tue May 3 17:44:43 2016 +0800 btrfs: cleanup assigning next active device with a check Creates helper fucntion as needed by the device delete and replace operations. Also now it checks if the next device being assigned is an active device. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 8 +++---- fs/btrfs/volumes.c | 60 ++++++++++++++++++++++++++++++++++++-------------- fs/btrfs/volumes.h | 2 ++ 3 files changed, 48 insertions(+), 22 deletions(-) commit 8ed01abe7da6af62f2089da9a4c1fe839dc638f5 Author: Anand Jain <anand.jain@oracle.com> Date: Thu Apr 14 18:24:10 2016 +0800 btrfs: s_bdev is not null after missing replace Yauhen reported in the ML that s_bdev is null at mount, and s_bdev gets updated to some device when missing device is replaced, as because bdev is null for missing device, things gets matched up. Fix this by checking if s_bdev is set. I didn't want to completely remove updating s_bdev because the future multi device support at vfs layer may need it. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reported-by: Yauhen Kharuzhy <yauhen.kharuzhy@zavadatar.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 3 ++- fs/btrfs/volumes.c | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) commit 090e1a7f5ce139ab4246fcaafaac0415008b7dfa Merge: 84c8a2d eb02602 Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:43:23 2016 +1000 Merge tag 'drm-amdkfd-next-2016-05-04' of git://people.freedesktop.org/~gabbayo/linux into drm-next Here are a few amdkfd patches for 4.7, all of them fixes according to the Coccinelle tool. * tag 'drm-amdkfd-next-2016-05-04' of git://people.freedesktop.org/~gabbayo/linux: amdkfd: Trim unnescessary intermediate err var in kfd_chardev.c amdkfd: Trim off unnescessary semicolon from kfd_packet_manager.c amdkfd: Use the canonical form in branch predicates commit 84c8a2de49560a65f10ec975b3281303a5ef0533 Merge: 00c1bea 2db00cf Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:39:45 2016 +1000 Merge branch 'drm-rockchip-next-fixes-05-03' of https://github.com/markyzq/kernel-drm-rockchip into drm-next Here are some little fixes for rockchip drm, looks good for me, and seems there is no doubt on them, So I'd like you can land them. * 'drm-rockchip-next-fixes-05-03' of https://github.com/markyzq/kernel-drm-rockchip: drm/rockchip: vop: Initialize vskiplines to zero drm/rockchip: vop: fix iommu crash with async atomic drm/rockchip: support non-iommu buffer path drm/rockchip: get rid of rockchip_drm_crtc_mode_config drm/rockchip: inno_hdmi: fix an error code drm/rockchip: don't leak iommu mapping drm/rockchip: remove redundant statement commit 00c1beab15df9216cf39818a437b34f296423ac4 Merge: acff058 b5bf0f1 Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:37:20 2016 +1000 Merge branch 'exynos-drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-next Summary: - Support for pipeline clock between KMS drivers. . Exynos SoC is required to control clocks across KMS drivers according to Exynos SoC version. So this patch refactos some relevant codes and provides generic solution for it. - Add Exynos5433 SoC support to HDMI parts - HDMI and DECON-TV. - Add HW trigger mode support to CRTC drivers. . In case of using i80 Panel, some Exynos SoC supports HW trigger mode so this patch makes trigger mode - HW or SW trigger - to be set according to SoC version properly. - And some cleanups and regression fixups. * 'exynos-drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: (39 commits) drm/exynos: clean up register definions for fimd and decon drm/exynos: decon: clean up interface type drm/exynos: fimd: add HW trigger support drm/exynos: clean up wait_for_vblank drm/exynos: mixer: use generic of_device_get_match_data helper drm/exynos: mixer: remove support for non-dt platforms drm/exynos: hdmi: use generic of_device_get_match_data helper drm/exynos: rotator: use generic of_device_get_match_data helper drm/exynos: fimd: use generic of_device_get_match_data helper drm/exynos: dsi: use generic of_device_get_match_data helper drm/exynos: exynos5433_decon: use generic of_device_get_match_data helper drm/exynos: convert clock_enable crtc callback to pipeline clock drm/exynos/mixer: enable HDMI-PHY before configuring MIXER drm/exynos/decon5433: enable HDMI-PHY before configuring DECON drm/exynos: add support for pipeline clock to the framework drm/exynos: add helper to get crtc from pipe drm/exynos/decon5433: do not protect window in plane disable drm/exynos/decon5433: reset decon on start drm/exynos/decon5433: fix DECON standalone update drm/exynos/hdmi: remove registry dump ... commit 7ba5dd530072d383f713a0fe1e4ffcdc5523ae37 Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri Feb 5 14:00:00 2016 +0100 ARM: dts: ux500: configure the accelerometers open drain Configure the two accelerometers sharing GPIO line 82 as: - Open drain so that they can share the same interrupt line. Configure the corresponding interrupt pin: - Trigger on the falling edge since open drain implies that we do not actively drive the line high, but we will actively drive it low to generate interrupts and then it moves from high to low i.e. a falling edge. - Pulled up so the line will be biased to high unless an IRQ is active on any device on the line, and thus it goes high again after the interrupt is deasserted. Cc: linux-iio@vger.kernel.org Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/ste-href-tvk1281618.dtsi | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit acff058f8625022bbc37a3521f8208810a42c4ef Merge: 2b8f01f 0cd3e27 Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:30:53 2016 +1000 Merge tag 'drm-vc4-next-2016-05-02' of https://github.com/anholt/linux into drm-next This pull request brings in DPI panel support, gamma ramp support, and render nodes for vc4. * tag 'drm-vc4-next-2016-05-02' of https://github.com/anholt/linux: drm/vc4: Add missing render node support drm/vc4: Add support for gamma ramps. drm/vc4: Fix NULL deref in HDMI init error path drm/vc4: Add DPI driver drm: Add an encoder and connector type enum for DPI. commit 2b8f01f178fdae58372f4a0d4bc45f3e5b43fe2d Merge: fffb675 be35f94 Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:28:09 2016 +1000 Merge tag 'topic/drm-misc-2016-04-29' of git://anongit.freedesktop.org/drm-intel into drm-next - prep work for struct_mutex-less gem_free_object - more invasive/tricky mst fixes from Lyude for broken hw. I discussed this with Ville/Jani and we all agreed more soaking in -next would be real good this late in the -rc cycle. They're cc: stable too to make sure they're not getting lost. Feel free to cherry-pick those four if you disagree. - few small things all over * tag 'topic/drm-misc-2016-04-29' of git://anongit.freedesktop.org/drm-intel: drm/atomic: Add missing drm_crtc_internal.h include drm/dp: Allow signals to interrupt drm_aux-dev reads/writes drm: Quiet down drm_mode_getresources drm: Quiet down drm_mode_getconnector drm: Protect dev->filelist with its own mutex drm: Make drm_vm_open/close_locked private to drm_vm.c drm: Hide master MAP cleanup in drm_bufs.c drm: Forbid legacy MAP functions for DRIVER_MODESET drm: Push struct_mutex into ->master_destroy drm: Move drm_getmap into drm_bufs.c and give it a legacy prefix drm: Put legacy lastclose work into drm_legacy_dev_reinit drm: Give drm_agp_clear drm_legacy_ prefix drm/sysfs: Annote lockless show functions with READ_ONCE MAINTAINERS: Update the files list for the GMA500 DRM driver drm: rcar-du: Fix compilation warning drm/i915: Get rid of intel_dp_dpcd_read_wake() drm/dp_helper: Perform throw-away read before actual read in drm_dp_dpcd_read() drm/dp_helper: Retry aux transactions on all errors drm/dp_helper: Always wait before retrying native aux transactions commit f3f44d512cafef7e3d2cb140f642786dd6ec8818 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 2 22:25:42 2016 +0200 mmc: sh_mobile_sdhi: check return value when changing clk And return the old clock rate if something went wrong. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8fc009986471729533fb1246c7ea9395635dac26 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 2 22:25:41 2016 +0200 mmc: sh_mobile_sdhi: only change the clock on RCar Gen2+ We had a regression on r8a7740 where the SDHI clock was a generic peripheral clock, so changing its rate was not desired. This should be fixed in the clock driver. However, it also shows that the new clock calculation should only be used on tested systems. Add a check for that. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 4 ++++ 1 file changed, 4 insertions(+) commit 3d376fb2ea907f0c1bbccf87125456439feb4ed4 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 2 22:25:40 2016 +0200 mmc: tmio/sdhi: introduce flag for RCar 2+ specific features RCar Gen2 and later implementations of TMIO/SDHI have their own set of features and additions. FAST_CLK_CHG is just one of them and I see a few others being added soon. Some may work on older chipsets but this needs to be tested case by case. Instead of adding a bunch of flags for each feature, add a global RCar2+ one for now. We can still break out features if the need arises. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 4 ++-- drivers/mmc/host/tmio_mmc_pio.c | 6 +++--- include/linux/mfd/tmio.h | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) commit 3072ba8cd95bd0e7fbe9a3a1c9b61fb190257855 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon May 2 22:25:39 2016 +0200 mmc: sh_mobile_sdhi: make clk_update function more compact Save a few lines, the codebase is large enough. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 81eef6ca92014845d40e3f1310e42b7010303acc Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:06:18 2016 +0300 mmc: omap_hsmmc: Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/omap_hsmmc.c | 50 +++++++++---------------------------------- 1 file changed, 10 insertions(+), 40 deletions(-) commit 4406433dec687c54be48a18a71dd28acb319137e Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Apr 28 14:59:26 2016 +0200 mmc: sdhci-of-at91: add presets setup The controller claims to support SDR104. In fact, it only supports a degraded SDR104 since the maximum frequency of the SD clock is 120 MHz instead of 208 MHz. The sdhci core is unaware of it and will compute a wrong clock divider. We can deal with this specific case by using presets. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-of-at91.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit fffb675106aef326bbd837612ad74c31ab060b93 Merge: b89359b 5b4fd5b Author: Dave Airlie <airlied@redhat.com> Date: Wed May 4 17:25:30 2016 +1000 Merge tag 'drm-intel-next-2016-04-25' of git://anongit.freedesktop.org/drm-intel into drm-next - more userptr cornercase fixes from Chris - clean up and tune forcewake handling (Tvrtko) - more underrun fixes from Ville, mostly for ilk to appeas CI - fix unclaimed register warnings on vlv/chv and enable the debug code to catch them by default (Ville) - skl gpu hang fixes for gt3/4 (Mika Kuoppala) - edram improvements for gen9+ (Mika again) - clean up gpu reset corner cases (Chris) - fix ctx/ring machine deaths on snb/ilk (Chris) - MOCS programming for all engines (Peter Antoine) - robustify/clean up vlv/chv irq handler (Ville) - split gen8+ irq handlers into ack/handle phase (Ville) - tons of bxt rpm fixes (mostly around firmware interactions), from Imre - hook up panel fitting for dsi panels (Ville) - more runtime PM fixes all over from Imre - shrinker polish (Chris) - more guc fixes from Alex Dai and Dave Gordon - tons of bugfixes and small polish all over (but with a big focus on bxt) * tag 'drm-intel-next-2016-04-25' of git://anongit.freedesktop.org/drm-intel: (142 commits) drm/i915: Update DRIVER_DATE to 20160425 drm/i915/bxt: Explicitly clear the Turbo control register drm/i915: Correct the i915_frequency_info debugfs output drm/i915: Macros to convert PM time interval values to microseconds drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW drm/i915: Fake HDMI live status drm/i915/bxt: Force reprogramming a PHY with invalid HW state drm/i915/bxt: Wait for PHY1 GRC done if PHY0 was already enabled drm/i915/bxt: Use PHY0 GRC value for HW state verification drm/i915: use dev_priv directly in gen8_ppgtt_notify_vgt drm/i915/bxt: Enable DC5 during runtime resume drm/i915/bxt: Sanitize DC state tracking during system resume drm/i915/bxt: Don't uninit/init display core twice during system suspend/resume drm/i915: Inline intel_suspend_complete drm/i915/kbl: Don't WARN for expected secondary MISC IO power well request drm/i915: Fix eDP low vswing for Broadwell drm/i915: check for ERR_PTR from i915_gem_object_pin_map() drm/i915/guc: local optimisations and updating comments drm/i915/guc: drop cached copy of 'wq_head' drm/i915/guc: keep GuC doorbell & process descriptor mapped in kernel ... commit 8b44a8a09de335a2fa7e39bb27e9fb50ff6d52ba Author: Tony Nguyen <anthony.l.nguyen@intel.com> Date: Wed Apr 27 14:14:14 2016 -0700 ixgbevf: Remove unused parameter ixgbevf_update_xcast_mode() is not using the netdev parameter; removing it since it's unnecessary. Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 2 +- drivers/net/ethernet/intel/ixgbevf/vf.c | 8 ++------ drivers/net/ethernet/intel/ixgbevf/vf.h | 2 +- 3 files changed, 4 insertions(+), 8 deletions(-) commit 8829009d2fd5683ed29418420b4883cf4782c85c Author: Usha Ketineni <usha.k.ketineni@intel.com> Date: Tue Apr 26 05:00:26 2016 -0700 ixgbe: Disable DCB and FCoE for X550EM_x and x550em_a This patch adds IXGBE_FLAG_DCB_CAPABLE flag that is set for all MACs other than X550EM_x and x550em_a. DCB and FCoE is disabled for these MACS. DCB initialization code is moved to a separate function. Signed-off-by: Usha Ketineni <usha.k.ketineni@intel.com> Tested-by: Ronald Bynoe <ronald.j.bynoe@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 111 ++++++++++++++++---------- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 1 + 3 files changed, 71 insertions(+), 42 deletions(-) commit 2f8214fe6811a246265629d81af2313695c63f4d Author: Alexander Duyck <aduyck@mirantis.com> Date: Fri Apr 22 13:18:26 2016 -0400 ixgbevf: Use mac_ops instead of trying to identify NIC type This change makes it so that we can just use function pointers instead of having to identify if a given VF is running on a Linux or Windows PF. By doing this we can avoid having to pull too much information out of the lower layers and can instead just make use of the mac_ops pointers since they should differ between the two types of VFs anyway. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 1 - drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 15 +++------------ drivers/net/ethernet/intel/ixgbevf/vf.c | 20 +++++++++----------- drivers/net/ethernet/intel/ixgbevf/vf.h | 4 +--- 4 files changed, 13 insertions(+), 27 deletions(-) commit 33b0eb15961393d8c60e7c4bddd23da53cd1c2e4 Author: Babu Moger <babu.moger@oracle.com> Date: Thu Apr 21 15:56:49 2016 -0700 ixgbevf: Change the relaxed order settings in VF driver for sparc We noticed performance issues with VF interface on sparc compared to PF. Setting the RX to IXGBE_DCA_RXCTRL_DATA_WRO_EN brings it on far with PF. Also this matches to the default sparc setting in PF driver. Signed-off-by: Babu Moger <babu.moger@oracle.com> Acked-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 45a88dfcd806ca8774180026891b136ef10fd844 Author: Preethi Banala <preethi.banala@intel.com> Date: Thu Apr 21 11:40:35 2016 -0700 ixgbe: Revise populating few registers and macro definitions Revise populating few registers in ixgbe_get_regs() and macro definitions. Before applying patch: $ du -k objs/drivers/net/ethernet/intel/ixgbe/ixgbe.ko 8572 objs/drivers/net/ethernet/intel/ixgbe/ixgbe.ko After applying patch: $ du -k objs/drivers/net/ethernet/intel/ixgbe/ixgbe.ko 8568 objs/drivers/net/ethernet/intel/ixgbe/ixgbe.ko Signed-off-by: Preethi Banala <preethi.banala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 18 ++++++------------ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 10 ++-------- 2 files changed, 8 insertions(+), 20 deletions(-) commit 4c4f8023be8c8f900e79a622b92bfc778db1f2ec Author: Preethi Banala <preethi.banala@intel.com> Date: Thu Apr 21 11:40:24 2016 -0700 ixgbe: Return 64 bit stats values The code was ignoring higher 32 bits of stats registers. This patch correctly fills out 64 bit value in two 32 bit words. Signed-off-by: Preethi Banala <preethi.banala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 61ff59d81c3cf9c346a008032ad974d6e79ae1d9 Author: Preethi Banala <preethi.banala@intel.com> Date: Thu Apr 21 11:39:29 2016 -0700 ixgbe: Remove duplicate and unused device ID definitions Remove duplicate and unused device ID definitions. Signed-off-by: Preethi Banala <preethi.banala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 740234f070eadd010f7b129c6592767db68f16ba Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Apr 21 11:37:12 2016 -0700 ixgbe: check EEPROM for WOL support for X540 and above This change aims to simplify the logic we use to determine WOL support by reading the EEPROM bits for MACs X540 and newer. Also some cleanups in ixgbe_wol_supported() - changed return type to bool and removed redundant return variable by simply using return after the checks. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 4 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 49 +++++++++++++-------------- 2 files changed, 25 insertions(+), 28 deletions(-) commit 00103a6ce31624cb91cba9d1f991409f67453d73 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Apr 21 11:37:06 2016 -0700 ixgbe: add WoL support for some 82599 subdevice IDs We had some 82599 subdevice IDs missing from the list of parts that support WoL. Reported-by: Neil Horman <nhorman@redhat.com> Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 8 ++++++-- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 6 +++++- 2 files changed, 11 insertions(+), 3 deletions(-) commit c6d45171d706c2b5efa3d5ee7a8260c14b6367c0 Author: KY Srinivasan <kys@microsoft.com> Date: Tue Apr 19 19:17:57 2016 -0700 ixgbevf: Support Windows hosts (Hyper-V) On Hyper-V, the VF/PF communication is a via software mediated path as opposed to the hardware mailbox. Make the necessary adjustments to support Hyper-V. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 11 ++ drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 31 +++- drivers/net/ethernet/intel/ixgbevf/mbx.c | 11 ++ drivers/net/ethernet/intel/ixgbevf/vf.c | 215 ++++++++++++++++++++++ drivers/net/ethernet/intel/ixgbevf/vf.h | 2 + 5 files changed, 263 insertions(+), 7 deletions(-) commit b4363fbd8df2be23439e15a53b4040897228c481 Author: KY Srinivasan <kys@microsoft.com> Date: Tue Apr 19 19:17:56 2016 -0700 ixgbevf: Add the device ID's presented while running on Hyper-V Intel SR-IOV cards present different ID when running on Hyper-V. Add the device IDs presented while running on Hyper-V. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/defines.h | 5 +++++ 1 file changed, 5 insertions(+) commit 1cdaaf5405ba910275fca720cab7f24a48fbdb14 Author: Amritha Nambiar <amritha.nambiar@intel.com> Date: Thu Apr 14 19:08:53 2016 -0400 ixgbe: Match on multiple headers for cls_u32 offloads Adds support to set filters with multiple header fields (L3,L4)to match on. This is achieved in the following order: 1. Create a leaf hash table for the next header. 2. Create a link to the leaf hash table from the base hash table with matches on next header type and current header fields. 3. Add filter in leaf hash table with match on next header fields and action. Verified with the following filters : Match TCP and DIP: handle 1: u32 divisor 1 u32 ht 800: order 1 link 1: \ offset at 0 mask 0f00 shift 6 plus 0 eat \ match ip protocol 6 ff match ip dst 10.0.0.1/32 match tcp src 28 ffff action drop Delete the filter: Match on DIP, SIP, UDP (SPort, DPort): handle 2: u32 divisor 1 u32 ht 800: order 2 link 2: \ offset at 0 mask 0f00 shift 6 plus 0 eat \ match ip dst 15.0.0.2/32 match ip protocol 17 ff \ match ip src 15.0.0.1/32 match udp src 30 ffff match udp dst 32 ffff action drop Signed-off-by: Amritha Nambiar <amritha.nambiar@intel.com> Acked-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 216 +++++++++++++++++-------- drivers/net/ethernet/intel/ixgbe/ixgbe_model.h | 6 + 3 files changed, 156 insertions(+), 68 deletions(-) commit 947f8a4552325458b9cda200238292a6930828a8 Author: Sridhar Samudrala <sridhar.samudrala@intel.com> Date: Tue Apr 5 10:39:07 2016 -0700 ixgbe: Add support for redirect action to cls_u32 offloads This patch enables 'redirect' to a SRIOV VF or a offloaded macvlan device queue via tc 'mirred' action. Verified with the following script that creates SRIOV VFs, offloaded macvlan and adds tc u32 filters with redirect action to the associated netdevs. # add ingress qdisc. tc qdisc add dev p4p1 ingress # enable hw tc offload. ethtool -K p4p1 hw-tc-offload on # create 4 sriov VFs and bring up the first one. echo 4 > /sys/class/net/p4p1/device/sriov_numvfs sleep 1 ip link set p4p1 up ip link set p4p1_0 up # create a offloaded macvlan device and bring it up. ethtool -K p4p1 l2-fwd-offload on ip link add link p4p1 name mvlan_1 type macvlan ip link set mvlan_1 up # add u32 filter with action to redirect to VF netdev tc filter add dev p4p1 parent ffff: protocol ip prio 99 \ handle 800:0:1 u32 ht 800: \ match ip src 192.168.1.3/32 \ action mirred egress redirect dev p4p1_0 # add u32 filter with action to redirect to macvlan netdev tc filter add dev p4p1 parent ffff: protocol ip prio 99 \ handle 800:0:2 u32 ht 800: \ match ip src 192.168.2.3/32 \ action mirred egress redirect dev mvlan_1 Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 96 +++++++++++++++++++++++---- 1 file changed, 83 insertions(+), 13 deletions(-) commit 229d2850815fd64b4e084fbf4c40218301fffc9c Author: Sridhar Samudrala <sridhar.samudrala@intel.com> Date: Mon May 2 03:33:42 2016 -0700 net_sched: act_mirred: add helper inlines to access tcf_mirred info Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> include/net/tc_act/tc_mirred.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit f0d09463c59c2d764a6c6d492cbe6d2c77f27153 Author: lei liu <liu.lei78@zte.com.cn> Date: Tue May 3 14:44:19 2016 -0700 USB: serial: option: add more ZTE device ids More ZTE device ids. Signed-off-by: lei liu <liu.lei78@zte.com.cn> Cc: stable <stable@vger.kernel.org> [properly sort them - gregkh] Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/option.c | 75 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 74 insertions(+), 1 deletion(-) commit f68376fc9e6dc15a08e16f08c95e503f19ad8e34 Author: Dimitri Sivanich <sivanich@sgi.com> Date: Fri Apr 29 16:54:23 2016 -0500 x86/platform/UV: Fix incorrect nodes and pnodes for cpuless and memoryless nodes This patch fixes the problem of incorrect nodes and pnodes being returned when referring to nodes that either have no cpus (AKA "headless") or no memory. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Dimitri Sivanich <sivanich@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215406.192644884@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apic/x2apic_uv_x.c | 58 ++++++++++++++++++-------------------- 1 file changed, 28 insertions(+), 30 deletions(-) commit 40bfb8eedf1e7fa0535c685ff1000c05bcf7a637 Author: Dimitri Sivanich <sivanich@sgi.com> Date: Fri Apr 29 16:54:22 2016 -0500 x86/platform/UV: Remove Obsolete GRU MMR address translation Use no-op messages in place of cross-partition interrupts when nacking a put message in the GRU. This allows us to remove MMR's as a destination from the GRU driver. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Dimitri Sivanich <sivanich@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215406.012228480@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 10 ---------- drivers/misc/sgi-gru/grukservices.c | 38 +++++++++++++++++++++---------------- 2 files changed, 22 insertions(+), 26 deletions(-) commit c85375cd19966d5dd854cd8b8eada9be8f21fac1 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:21 2016 -0500 x86/platform/UV: Update physical address conversions for UV4 This patch builds support for the new conversions of physical addresses to and from sockets, pnodes and nodes in UV4. It is designed to be as efficient as possible as lookups are done inside an interrupt context in some cases. It will be further optimized when physical hardware is available to measure execution time. Tested-by: Dimitri Sivanich <sivanich@sgi.com> Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215405.841051741@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 131 ++++++++++++++++++++++++++++++++----- arch/x86/kernel/apic/x2apic_uv_x.c | 96 ++++++++++++++++++++++++++- 2 files changed, 209 insertions(+), 18 deletions(-) commit 6e27b91cf46834391c59062d3f26d277cc299f4b Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:20 2016 -0500 x86/platform/UV: Build GAM reference tables An aspect of the UV4 system architecture changes involve changing the way sockets, nodes, and pnodes are translated between one another. Decode the information from the BIOS provided EFI system table to build the needed conversion tables. Tested-by: Dimitri Sivanich <sivanich@sgi.com> Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215405.673495324@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 18 ++++- arch/x86/kernel/apic/x2apic_uv_x.c | 139 +++++++++++++++++++++++++++++++++++++ 2 files changed, 155 insertions(+), 2 deletions(-) commit 1de329c10d9fbac4031f8eb30c4921c6efbf9faa Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:19 2016 -0500 x86/platform/UV: Support UV4 socket address changes With the UV4 system architecture addressing changes, BIOS now provides this information via an EFI system table. This is the initial decoding of that system table. It also collects the sizing information for later allocation of dynamic conversion tables. Tested-by: Dimitri Sivanich <sivanich@sgi.com> Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215405.503022681@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 11 +++- arch/x86/kernel/apic/x2apic_uv_x.c | 128 ++++++++++++++++++++++++++++++++++--- 2 files changed, 129 insertions(+), 10 deletions(-) commit ef93bf803999445985acb25f4ed8772e1aa81221 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:18 2016 -0500 x86/platform/UV: Add obtaining GAM Range Table from UV BIOS UV4 uses a GAM (globally addressed memory) architecture that supports variable sized memory per node. This replaces the old "M" value (number of address bits per node) with a range table for conversions between addresses and physical node (pnode) id's. This table is obtained from UV BIOS via the EFI UVsystab table. Support for older EFI UVsystab tables is maintained. Tested-by: Dimitri Sivanich <sivanich@sgi.com> Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215405.329827545@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/bios.h | 59 +++++++++++++++++++++++++++++++++++++++-- arch/x86/platform/uv/bios_uv.c | 48 ++++++++++++++++----------------- arch/x86/platform/uv/uv_sysfs.c | 2 +- 3 files changed, 81 insertions(+), 28 deletions(-) commit 405422d88c686e88b4241c0201fd96b61ab8bd77 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:17 2016 -0500 x86/platform/UV: Add UV4 addressing discovery function UV4 requires early system wide addressing values. This involves the use of the CPUID instruction to obtain these values. The current function (detect_extended_topology()) in the kernel has been copied and streamlined, with the limitation that only CPU's used by UV architectures are supported. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215405.155660884@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apic/x2apic_uv_x.c | 85 ++++++++++++++++++++++++++++++++------ 1 file changed, 72 insertions(+), 13 deletions(-) commit 906f3b20da8c6ec3eeef81753b4af9b6780e2edc Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:16 2016 -0500 x86/platform/UV: Fold blade info into per node hub info structs Migrate references from the blade info structs to the per node hub info structs. This phases out the allocation of the list of per blade info structs on node 0, in favor of a per node hub info struct allocated on the node's local memory. There are also some minor cosemetic changes in the comments and whitespace to clean things up a bit. Tested-by: Dimitri Sivanich <sivanich@sgi.com> Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.987204515@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 71 ++++++------- arch/x86/kernel/apic/x2apic_uv_x.c | 212 ++++++++++++++++++------------------- 2 files changed, 133 insertions(+), 150 deletions(-) commit 3edcf2ff7ae50d1096030fab9a1bafb421e07d4c Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:15 2016 -0500 x86/platform/UV: Allocate common per node hub info structs on local node Allocate and setup per node hub info structs. CPU 0/Node 0 hub info is statically allocated to be accessible early in system startup. The remaining hub info structs are allocated on the node's local memory, and shared among the CPU's on that node. This leaves the small amount of info unique to each CPU in the per CPU info struct. Memory is saved by combining the common per node info fields to common node local structs. In addtion, since the info is read only only after setup, it should stay in the L3 cache of the local processor socket. This should therefore improve the cache hit rate when a group of cpus on a node are all interrupted for a common task. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Reviewed-by: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.813051625@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 36 ++++++++++++++++++++--- arch/x86/kernel/apic/x2apic_uv_x.c | 59 ++++++++++++++++++++++++++++---------- 2 files changed, 76 insertions(+), 19 deletions(-) commit 5627a8251f7861175b193a44dc3d8cb478d1135a Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:14 2016 -0500 x86/platform/UV: Move blade local processor ID to the per cpu info struct Move references to blade local processor ID to the new per cpu info structs. Create an access function that makes this move, and other potential moves opaque to callers of this function. Define a flag that indicates to callers in external GPL modules that this function replaces any local definition. This allows calling source code to be built for both pre-UV4 kernels as well as post-UV4 kernels. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.644173122@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 10 ++++++++-- arch/x86/kernel/apic/x2apic_uv_x.c | 2 +- arch/x86/platform/uv/tlb_uv.c | 3 ++- arch/x86/platform/uv/uv_time.c | 6 +++--- 4 files changed, 14 insertions(+), 7 deletions(-) commit d38bb135d814e96811e1a0778564d7a2df922e28 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:13 2016 -0500 x86/platform/UV: Move scir info to the per cpu info struct Change the references to the SCIR fields to the new per cpu info structs. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.452538234@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 17 ++++++++++------- arch/x86/kernel/apic/x2apic_uv_x.c | 18 +++++++++--------- 2 files changed, 19 insertions(+), 16 deletions(-) commit 0045ddd23f21ad1964c01228257bc6c692e1c2f9 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:12 2016 -0500 x86/platform/UV: Create per cpu info structs to replace per hub info structs The major portion of the hub info is common to all cpus on that hub. This is step one of moving the per cpu hub info to a per node hub info struct. This patch creates the small per cpu info struct that will contain only information specific to each CPU. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.282265563@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 19 +++++++++++++++---- arch/x86/kernel/apic/x2apic_uv_x.c | 15 ++++++++++----- 2 files changed, 25 insertions(+), 9 deletions(-) commit a2f28e6950cec75320a8c3c8747a6e3ad08cfd2b Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:11 2016 -0500 x86/platform/UV: Update MMIOH setup function to work for both UV3 and UV4 Since UV3 and UV4 MMIOH regions are setup the same, we can use a common function to setup both. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215404.100504077@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apic/x2apic_uv_x.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b608f87fe886d3ef7f9f8eb8ba58f45beb61c286 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:10 2016 -0500 x86/platform/UV: Clean up redunduncies after merge of UV4 MMR definitions Clean up any redundancies caused by new UV4 MMR definitions superseding any previously definitions local to functions. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Reviewed-by: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215403.934728974@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 9 --------- arch/x86/kernel/apic/x2apic_uv_x.c | 1 - 2 files changed, 10 deletions(-) commit 0f0d84c08d38cc4c61fc04f94db0713aa82a39bc Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:08 2016 -0500 x86/platform/UV: Add UV4 Specific MMR definitions This adds the MMR definitions for UV4 via an automated script that uses the output from a hardware verilog code to symbol converter. The large number of insertions is caused by the UV4 design changing many similarly named fields in MMR's that are named the same. This prompted the extra production of architecture dependent field defines. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dimitri Sivanich <sivanich@sgi.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215403.580158916@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_mmrs.h | 2191 ++++++++++++++++++++++++++++++------- 1 file changed, 1769 insertions(+), 422 deletions(-) commit c443c03dd0d97620022483be6705ff611695a29c Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:07 2016 -0500 x86/platform/UV: Prep for UV4 MMR updates Cleanup patch to rearrange code and modify some defines so the next patch, the new UV4 MMR definitions can be merged cleanly. * Clean up the M/N related address constants (M is # of address bits per blade, N is the # of blade selection bits per SSI/partition). * Fix the lookup of the alias overlay addresses and NMI definitions to allow for flexibility in newer UV architecture types. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215403.401604203@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 5 + arch/x86/kernel/apic/x2apic_uv_x.c | 208 ++++++++++++++++++++++--------------- 2 files changed, 129 insertions(+), 84 deletions(-) commit 7563421b13da21dd7a947f658b5299e65ed95cbe Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:06 2016 -0500 x86/platform/UV: Add UV MMR Illegal Access Function This new function is generated by the UV MMR generation script to identify MMR registers and fields that are not defined for a specific UV architecture. With this switch, the immediate panic can be replaced with a message and a bad return value allowing either hardware or the emulator to diagnose the problem. It allows functions common to some UV arches to use common defines that might not be fully defined for all arches, as long as they do not reference them on the unsupported arches. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215403.231926687@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apic/x2apic_uv_x.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit a0ec83f316e1d933d8c820d249972574324c2d25 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:05 2016 -0500 x86/platform/UV: Add UV4 Specific Defines Add UV4 specific defines to determine if current system type is a UV4 system. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215403.072323684@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apic/x2apic_uv_x.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit e0ee1c97c3b1cabc3651d7bcf39c1f54d736fd20 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:04 2016 -0500 x86/platform/UV: Add UV Architecture Defines Add defines to control which UV architectures are supported, and modify the 'if (is_uvX_*)' functions to return constant 0 for those not supported. This will help optimize code paths when support for specific UV arches is removed. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Reviewed-by: Dimitri Sivanich <sivanich@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215402.897143440@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 36 +++++++++++++++++++++++++++++++----- 1 file changed, 31 insertions(+), 5 deletions(-) commit eb1e3461b8912ce4794fd2b7b414338a59461601 Author: Mike Travis <travis@sgi.com> Date: Fri Apr 29 16:54:03 2016 -0500 x86/platform/UV: Add Initial UV4 definitions Add preliminary UV4 defines. Tested-by: John Estabrook <estabrook@sgi.com> Tested-by: Gary Kroening <gfk@sgi.com> Tested-by: Nathan Zimmer <nzimmer@sgi.com> Signed-off-by: Mike Travis <travis@sgi.com> Cc: Andrew Banman <abanman@sgi.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dimitri Sivanich <sivanich@sgi.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Len Brown <len.brown@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russ Anderson <rja@sgi.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160429215402.703593187@asylum.americas.sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uv/uv_hub.h | 64 ++++++++++++++++++++++++++++----------- arch/x86/include/asm/uv/uv_mmrs.h | 22 ++++++++++---- 2 files changed, 62 insertions(+), 24 deletions(-) commit d63c214b0a39e7e92fbae2a47b66e8145c3c9c81 Merge: 47a541c 04974df Author: Ingo Molnar <mingo@kernel.org> Date: Wed May 4 08:48:26 2016 +0200 Merge tag 'v4.6-rc6' into x86/platform, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 91c6180572e2fec71701d646ffc40ad30986275c Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 3 10:31:52 2016 -0700 signals/sigaltstack: Change SS_AUTODISARM to (1U << 31) Using bit 4 divides the space of available bits strangely. Use bit 31 instead so that we have a better chance of keeping flag and mode bits separate in the long run. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Aleksa Sarai <cyphar@cyphar.com> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Eric W. Biederman <ebiederm@xmission.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Heinrich Schuchardt <xypron.glpk@gmx.de> Cc: Jason Low <jason.low2@hp.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Paul Moore <pmoore@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Stas Sergeev <stsp@list.ru> Cc: Tejun Heo <tj@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vladimir Davydov <vdavydov@parallels.com> Cc: linux-api@vger.kernel.org Link: http://lkml.kernel.org/r/bb996508a600af14b406810c3d58fe0e0d0afe0d.1462296606.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/uapi/linux/signal.h | 2 +- tools/testing/selftests/sigaltstack/sas.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 0318bc8a919ded355eaa5078689924a15c1bf52a Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 3 10:31:51 2016 -0700 signals/sigaltstack: Report current flag bits in sigaltstack() sigaltstack()'s reported previous state uses a somewhat odd convention, but the concept of flag bits is new, and we can do the flag bits sensibly. Specifically, let's just report them directly. This will allow saving and restoring the sigaltstack state using sigaltstack() to work correctly. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Michal Hocko <mhocko@suse.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Stas Sergeev <stsp@list.ru> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vladimir Davydov <vdavydov@parallels.com> Cc: linux-api@vger.kernel.org Link: http://lkml.kernel.org/r/94b291ec9fd47741a9264851e316e158ded0b00d.1462296606.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/signal.c | 3 ++- tools/testing/selftests/sigaltstack/sas.c | 19 ++++++++++++++++--- 2 files changed, 18 insertions(+), 4 deletions(-) commit 158b67b5c5ccda9b909f18028a3cd17185ca1efd Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 3 10:31:50 2016 -0700 selftests/sigaltstack: Fix the sigaltstack test on old kernels The handling for old kernels was wrong, resulting in a segfault. Fix it. Reported-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Stas Sergeev <stsp@list.ru> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-api@vger.kernel.org Link: http://lkml.kernel.org/r/f3e739bf435beeaecbd5f038f1359d2eac6d1e63.1462296606.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/testing/selftests/sigaltstack/sas.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) commit c876eeab6432687846d4cd5fe1e43dbc348de134 Author: Andy Lutomirski <luto@kernel.org> Date: Tue May 3 10:31:49 2016 -0700 signals/sigaltstack: If SS_AUTODISARM, bypass on_sig_stack() If a signal stack is set up with SS_AUTODISARM, then the kernel inherently avoids incorrectly resetting the signal stack if signals recurse: the signal stack will be reset on the first signal delivery. This means that we don't need check the stack pointer when delivering signals if SS_AUTODISARM is set. This will make segmented x86 programs more robust: currently there's a hole that could be triggered if ESP/RSP appears to point to the signal stack but actually doesn't due to a nonzero SS base. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Aleksa Sarai <cyphar@cyphar.com> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Eric W. Biederman <ebiederm@xmission.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Heinrich Schuchardt <xypron.glpk@gmx.de> Cc: Jason Low <jason.low2@hp.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Paul Moore <pmoore@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Stas Sergeev <stsp@list.ru> Cc: Tejun Heo <tj@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vladimir Davydov <vdavydov@parallels.com> Cc: linux-api@vger.kernel.org Link: http://lkml.kernel.org/r/c46bee4654ca9e68c498462fd11746e2bd0d98c8.1462296606.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit a0ca97b808c06793fd9dfb69243ce945c9fff501 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Wed May 4 14:41:22 2016 +0900 staging: dgnc: Fix a NULL pointer dereference The error handling for print_drive after calling tty_alloc_driver() was needed. But there was error handling but too late for this. Error handling code moved after tty_alloc_driver() call. Fixes: 60b3109e5e2d ("staging: dgnc: use tty_alloc_driver instead of kcalloc") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit d13829686bba3e06e2217f044beb8fd5a9abf792 Author: Kangjie Lu <kangjielu@gmail.com> Date: Tue May 3 21:36:11 2016 -0400 staging: wilc1000: fix infoleak in wilc_wfi_cfgoperations "mac" is an array allocated in stack without being initialized, and will be sent out via "nla_put". The dump_station() is supposed to initialize the mac address; otherwise, sensitive data in kernel stack will be leaked. To fix this, copy the mac address to it. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 1 + 1 file changed, 1 insertion(+) commit 764763f0a0c81cbed4d2c7dc2b05e7173ff85b5b Author: Peter Chen <peter.chen@nxp.com> Date: Wed Apr 13 15:16:52 2016 +0800 doc: usb: chipidea: update the doc for OTG FSM Since we have added otg version and HNP polling support, update related documentation. Signed-off-by: Peter Chen <peter.chen@nxp.com> Documentation/usb/chipidea.txt | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit cba653210056cf47cc1969f831f05ddfb99ee2bd Merge: 26879da 7391daf Author: David S. Miller <davem@davemloft.net> Date: Wed May 4 00:52:29 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Conflicts: net/ipv4/ip_gre.c Minor conflicts between tunnel bug fixes in net and ipv6 tunnel cleanups in net-next. Signed-off-by: David S. Miller <davem@davemloft.net> commit 8d039e22b516c4c0ecaeb91f7566b5860fda14e7 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Sat Apr 30 22:44:43 2016 -0400 scsi_debug: rework resp_report_luns Based on "[PATH V2] scsi_debug: rework resp_report_luns" patch sent by Tomas Winkler on Thursday, 26 Feb 2015. His notes: 1. Remove duplicated boundary checks which simplify the fill-in loop 2. Use more of scsi generic API Replace fixed length response array a with heap allocation allowing up to 256 normal LUNs per target. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Reviewed-by: Tomas Winkler <tomas.winkler@intel.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 135 +++++++++++++++++++++++++++++----------------- 1 file changed, 87 insertions(+), 48 deletions(-) commit b01f6f8316af5226b0cada03e3b121e72dd4c17f Author: Douglas Gilbert <dgilbert@interlog.com> Date: Sat Apr 30 22:44:42 2016 -0400 scsi_debug: use pdt constants Use TYPE_* constants for SCSI peripheral device types instead of numbers. Further cleanups requested by checkpatch.pl. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 86 +++++++++++++++++++++++++---------------------- 1 file changed, 45 insertions(+), 41 deletions(-) commit 7da4b8b7378790dd1e4af1bb7522863127fa1438 Author: Peter Hurley <peter@hurleysoftware.com> Date: Tue May 3 14:01:51 2016 -0700 serial: core: Fix port mutex assert if lockdep disabled commit 4047b37122d1 ("serial: core: Prevent unsafe uart port access, part 1") added lockdep assertion for port mutex but fails to check if debug_locks has disabled lockdep (so lock state is no longer reliable). Use lockdep_assert_held() instead, which properly checks lockdep state as well. Reported-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Tested-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_core.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 3aacd7fe552b093fc24a8082e16467eb26c2fa32 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:53 2016 +0200 nfc: st-nci: Move loopback usage from HCI to NCI NCI provides possible way to run loopback testing has done over HCI. For us it offers many advantages: - It simplifies the code: No more need for a vendor_cmds structure - Loopback over HCI may not be supported in future st-nci firmware Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/se.c | 5 ---- drivers/nfc/st-nci/st-nci.h | 13 ++------- drivers/nfc/st-nci/vendor_cmds.c | 62 ++++++++-------------------------------- 3 files changed, 14 insertions(+), 66 deletions(-) commit 1c53855f6be2e7da270e86cae381745ee6105eab Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:52 2016 +0200 nfc: nci: Add nci_nfcc_loopback to the nci core For test purpose, provide the generic nci loopback function. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> include/net/nfc/nci_core.h | 2 ++ net/nfc/nci/core.c | 77 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+) commit 9b8d1a4cf2aa819d606b4e423a6523fc0d4460a2 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:51 2016 +0200 nfc: nci: Add an additional parameter to identify a connection id According to NCI specification, destination type and destination specific parameters shall uniquely identify a single destination for the Logical Connection. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/fdp/fdp.c | 3 ++- drivers/nfc/st-nci/se.c | 6 ++++-- include/net/nfc/nci_core.h | 15 ++++++++++++--- net/nfc/nci/core.c | 25 ++++++++++++++++++------- net/nfc/nci/ntf.c | 2 +- net/nfc/nci/rsp.c | 20 +++++++++++++++++--- 6 files changed, 54 insertions(+), 17 deletions(-) commit de5ea8517c2ae40785fe5d0a2d02fc71bef1761b Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:50 2016 +0200 nfc: nci: Fix nci_core_conn_close nci_core_conn_close was not retrieving a conn_info using the correct connection id. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> net/nfc/nci/core.c | 1 + net/nfc/nci/rsp.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit 18836029d8c074ac1846167ba702ac528e0a0ad7 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:49 2016 +0200 nfc: nci: Fix nci_core_conn_create to allowing empty destination NCI_CORE_CONN_CREATE may not have any destination type parameter. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> net/nfc/nci/core.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 99adc394f2a4a16763bccbaa150b9d598b18c58f Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:48 2016 +0200 nfc: st21nfca: Remove duplicated ST21NFCA_ESE_HOST_ID from se.c ST21NFCA_ESE_HOST_ID is already defined in st21nfca.h. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/se.c | 2 -- 1 file changed, 2 deletions(-) commit c50e8fef7bb5e4a77609e4120940458e419d463f Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:47 2016 +0200 nfc: st-nci: Remove redundant ST_NCI_HCI_HOST_ID_ESE from st-nci.h ST_NCI_HCI_HOST_ID_ESE is already having an equivalent in se.c (ST_NCI_ESE_HOST_ID). Remove and replace where relevant. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/se.c | 4 ++-- drivers/nfc/st-nci/st-nci.h | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) commit 1f34b20404443717a7ec77b447d86578f0478550 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:46 2016 +0200 NFC: st-nci: spi: Drop two useless checks in ACPI probe path When st_nci_spi_acpi_request_resources() gets called we already know that the entries in ->acpi_match_table have matched ACPI ID of the device. In addition spi_device pointer cannot be NULL in any case (otherwise SPI core would not call ->probe() for the driver in the first place). Drop the two useless checks from the driver. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/spi.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 4ac52a0fd066cd33b12d79b09e30fd8bdb52f8d8 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:45 2016 +0200 NFC: st-nci: i2c: Drop two useless checks in ACPI probe path When st_nci_i2c_acpi_request_resources() gets called we already know that the entries in ->acpi_match_table have matched ACPI ID of the device. In addition I2C client pointer cannot be NULL in any case (otherwise I2C core would not call ->probe() for the driver in the first place). Drop the two useless checks from the driver. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/i2c.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 070718a499cea9e6d7e6404788490574dfb71388 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:44 2016 +0200 NFC: st21nfca: Drop two useless checks in ACPI probe path When st21nfca_hci_i2c_acpi_request_resources() gets called we already know that the entries in ->acpi_match_table have matched ACPI ID of the device. In addition I2C client pointer cannot be NULL in any case (otherwise I2C core would not call ->probe() for the driver in the first place). Drop the two useless checks from the driver. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/i2c.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 7cb6ab590d7d203b53284f4f211d4a8a89a125fc Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:43 2016 +0200 nfc: st21nfca: A APDU_READER_GATE pipe is unexpected on a UICC An APDU_READER_GATE pipe is not expected on a UICC. Be more explicit so that an other secure element form factor (SD card) does not prompt this message. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0209e79d540440962913054fae499ad1892a4f15 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:42 2016 +0200 nfc: st-nci: A APDU_READER_GATE pipe is unexpected on a UICC An APDU_READER_GATE pipe is not expected on a UICC. Be more explicit so that an other secure element form factor (SD card) does not prompt this message. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/se.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cde4856e612111ce91258b947051a08703cd1499 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:41 2016 +0200 nfc: st-nci: Simplify white list building Simplify white list Building Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/se.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit d35cb20b411673820219e08c57392d18668f6217 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:40 2016 +0200 nfc: st21nfca: Simplify white list building Simplify white list Building Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/core.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 27420fec40e22cb3ff04bcef654110eb2ef37620 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:39 2016 +0200 nfc: st-nci: set is_ese_present and is_uicc_present properly When they're present, set is_ese_present and set is_uicc_present to the value describe in their package description. So far is_ese_present and is_uicc_present was set to true if their property was present. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/i2c.c | 17 +++++++++++++---- drivers/nfc/st-nci/spi.c | 17 +++++++++++++---- 2 files changed, 26 insertions(+), 8 deletions(-) commit bd9d523257832ecf999acb0c312f1ee1a22ed4b0 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:38 2016 +0200 nfc: st21nfca: set is_ese_present and is_uicc_present properly When they're present, set is_ese_present and set is_uicc_present to the value describe in their package description. So far is_ese_present and is_uicc_present was set to true if their property was present. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/i2c.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit 2a196975058f94e184464b13b52d86752bccbbd4 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:37 2016 +0200 nfc: st21nfca: i2c: Change ST21NFCA_GPIO_NAME_RESET to match DT Since commit 10cf4899f8af ("gpiolib: tighten up ACPI legacy gpio lookups") If _DSD properties are available in an ACPI node, we are not allowed to fallback to _CRS data to retrieve gpio properties. This was causing us to fail if uicc-present and/or ese-present are defined. To be consistent with devicetree change ST_NCI_GPIO_NAME_RESET content to reset so that acpi_find_gpio in drivers/gpio/gpiolib.c will look for reset-gpios. In the mean time the ACPI table needs to be fixed as follow: Device (NFC1) { Name (_ADR, Zero) // _ADR: Address Name (_HID, "SMO2100") // _HID: Hardware ID Name (_CID, "SMO2100") // _CID: Compatible ID Name (_DDN, "SMO NFC") // _DDN: DOS Device Name Name (_UID, One) // _UID: Unique ID Method (_CRS, 0, NotSerialized) // _CRS: Current Resource Settings { Name (SBUF, ResourceTemplate () { I2cSerialBus (0x0008, ControllerInitiated, 400000, AddressingMode7Bit, "\\_SB.I2C7", 0x00, ResourceConsumer, ,) GpioInt (Edge, ActiveHigh, ExclusiveAndWake, PullNone, 0x0000, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0001 } GpioIo (Exclusive, PullDefault, 0x0000, 0x0000, IoRestrictionOutputOnly, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0002, } }) Name (_DSD, Package (0x02) { ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301") /* Device Properties for _DSD */, Package (0x03) { Package (0x02) { "uicc-present", 1 }, Package (0x02) { "ese-present", 1 }, Package (0x02) { "enable-gpios", Package(0x04) { ^NFC1, 1, 0, 0} }, } }) Return (SBUF) /* \_SB_.I2C7.NFC1._CRS.SBUF */ } Method (_STA, 0, NotSerialized) // _STA: Status { Return (0x0F) } } Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de72dbc52c4141a6e3f31796499908d00816ad2e Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:36 2016 +0200 nfc: st-nci: spi: Change ST_NCI_GPIO_NAME_RESET to match DT Since commit 10cf4899f8af ("gpiolib: tighten up ACPI legacy gpio lookups") If _DSD properties are available in an ACPI node, we are not allowed to fallback to _CRS data to retrieve gpio properties. This was causing us to fail if uicc-present and/or ese-present are defined. To be consistent with devicetree change ST_NCI_GPIO_NAME_RESET content to reset so that acpi_find_gpio in drivers/gpio/gpiolib.c will look for reset-gpios. In the mean time the ACPI table needs to be fixed as follow (Tested on Minnowboard Max): Device (NFC1) { Name (_ADR, Zero) // _ADR: Address Name (_HID, "SMO2101") // _HID: Hardware ID Name (_CID, "SMO2101") // _CID: Compatible ID Name (_DDN, "SMO NFC") // _DDN: DOS Device Name Name (_UID, One) // _UID: Unique ID Method (_CRS, 0, NotSerialized) // _CRS: Current Resource Settings { Name (SBUF, ResourceTemplate () { SpiSerialBus (0, PolarityLow, FourWireMode, 8, ControllerInitiated, 4000000, ClockPolarityLow, ClockPhaseFirst, "\\_SB.SPI1", 0x00, ResourceConsumer, ,) GpioInt (Edge, ActiveHigh, ExclusiveAndWake, PullNone, 0x0000, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0001 } GpioIo (Exclusive, PullDefault, 0x0000, 0x0000, IoRestrictionOutputOnly, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0002, } }) Name (_DSD, Package (0x02) { ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301") /* Device Properties for _DSD */, Package (0x03) { Package (0x02) { "uicc-present", 1 }, Package (0x02) { "ese-present", 1 }, Package (0x02) { "reset-gpios", Package(0x04) { ^NFC1, 1, 0, 0} }, } }) Return (SBUF) /* \_SB_.SPI1.NFC1._CRS.SBUF */ } Method (_STA, 0, NotSerialized) // _STA: Status { Return (0x0F) } } Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c1fc9136c8b353e853065c2a8a736cdcf6081dcd Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:35 2016 +0200 nfc: st-nci: i2c: Change ST_NCI_GPIO_NAME_RESET to match DT Since commit 10cf4899f8af ("gpiolib: tighten up ACPI legacy gpio lookups") If _DSD properties are available in an ACPI node, we are not allowed to fallback to _CRS data to retrieve gpio properties. This was causing us to fail if uicc-present and/or ese-present are defined. To be consistent with devicetree change ST_NCI_GPIO_NAME_RESET content to reset so that acpi_find_gpio in drivers/gpio/gpiolib.c will look for reset-gpios. In the mean time the ACPI table needs to be fixed as follow: Device (NFC1) { Name (_ADR, Zero) // _ADR: Address Name (_HID, "SMO2101") // _HID: Hardware ID Name (_CID, "SMO2101") // _CID: Compatible ID Name (_DDN, "SMO NFC") // _DDN: DOS Device Name Name (_UID, One) // _UID: Unique ID Method (_CRS, 0, NotSerialized) // _CRS: Current Resource Settings { Name (SBUF, ResourceTemplate () { I2cSerialBus (0x0008, ControllerInitiated, 400000, AddressingMode7Bit, "\\_SB.I2C7", 0x00, ResourceConsumer, ,) GpioInt (Edge, ActiveHigh, ExclusiveAndWake, PullNone, 0x0000, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0001 } GpioIo (Exclusive, PullDefault, 0x0000, 0x0000, IoRestrictionOutputOnly, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0002, } }) Name (_DSD, Package (0x02) { ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301") /* Device Properties for _DSD */, Package (0x03) { Package (0x02) { "uicc-present", 1 }, Package (0x02) { "ese-present", 1 }, Package (0x02) { "reset-gpios", Package(0x04) { ^NFC1, 1, 0, 0} }, } }) Return (SBUF) /* \_SB_.I2C7.NFC1._CRS.SBUF */ } Method (_STA, 0, NotSerialized) // _STA: Status { Return (0x0F) } } Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st-nci/i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b58afe6d6d3a53af165d5946f12c4b08c95acd58 Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sat Apr 30 09:12:34 2016 +0200 nfc: st21nfca: Fix static checker warning Fix static checker warning: drivers/nfc/st21nfca/i2c.c:530 st21nfca_hci_i2c_acpi_request_resources() error: 'gpiod_ena' dereferencing possible ERR_PTR() Fix so that if no enable gpio can be retrieved an -ENODEV is returned. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Fixes: dfa8070d7f64 ("nfc: st21nfca: Add support for acpi probing for i2c device.") Cc: stable@vger.kernel.org Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/st21nfca/i2c.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 6550be9f62bfc4dacbdbd8cb7afe0df661da77bf Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Mon May 2 17:19:46 2016 +0800 serial: 8250_dw: fix wrong logic in dw8250_check_lcr() Commit cdcea058e510 ("serial: 8250_dw: Avoid serial_outx code duplicate with new dw8250_check_lcr()") introduce a wrong logic when write val to LCR reg. When CONFIG_64BIT enabled, __raw_writeq is used unconditionally. The __raw_readq/__raw_writeq is introduced by commit bca2092d7897 ("serial: 8250_dw: Use 64-bit access for OCTEON.") for OCTEON. So for 64BIT && !PORT_OCTEON, we better to use coincident write function. Fixes: cdcea058e510("serial: 8250_dw: Avoid serial_outx code duplicate with new dw8250_check_lcr()") Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_dw.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 96317e9e2a12d01eaaebf6b1e92b0f96c121e20a Author: Jiri Slaby <jslaby@suse.cz> Date: Tue May 3 17:05:55 2016 +0200 tty: vt, finish looping on duplicate When the console is already registered, stop crawling the registered_con_driver array and return an error immediatelly. This makes the code more obvious. And we do not need to initialize retval anymore. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 6798df4c5fe0a7e6d2065cf79649a794e5ba7114 Author: Jiri Slaby <jslaby@suse.cz> Date: Tue May 3 17:05:54 2016 +0200 tty: vt, return error when con_startup fails When csw->con_startup() fails in do_register_con_driver, we return no error (i.e. 0). This was changed back in 2006 by commit 3e795de763. Before that we used to return -ENODEV. So fix the return value to be -ENODEV in that case again. Fixes: 3e795de763 ("VT binding: Add binding/unbinding support for the VT console") Signed-off-by: Jiri Slaby <jslaby@suse.cz> Reported-by: "Dan Carpenter" <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 8cd1f9d01cbf4f46eace90d9792e65a209c37d31 Author: Andreas Werner <andreas.werner@men.de> Date: Tue May 3 12:42:02 2016 +0200 mcb: Delete num_cells variable which is not required The num_cells variable is only used in the dev_dbg print, but we can directly use the ret variable which also includes the same value. Signed-off-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/mcb/mcb-pci.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit f75564d343010b025301d9548f2304f48eb25f01 Author: Andreas Werner <andreas.werner@men.de> Date: Tue May 3 12:42:00 2016 +0200 mcb: Fixed bar number assignment for the gdd The bar number is found in reg2 within the gdd. Therefore we need to change the assigment from reg1 to reg2 which is the correct location. Signed-off-by: Andreas Werner <andreas.werner@men.de> Fixes: '3764e82e5' drivers: Introduce MEN Chameleon Bus Cc: stable@vger.kernel.org # v3.15+ Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/mcb/mcb-parse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d19366f1d66705d9b07e9beff9c50896606b8e44 Author: Andreas Werner <andreas.werner@men.de> Date: Tue May 3 12:42:01 2016 +0200 mcb: Replace ioremap and request_region with the devm version Replaced ioremap with devm_ioremap and request_mem_region with devm_request_mem_region. This makes the code much more cleaner. Signed-off-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/mcb/mcb-pci.c | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) commit 5d9e2ab9fea4cdf0a2522f5cbed2e7fbb220d757 Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Tue May 3 12:42:03 2016 +0200 mcb: Implement bus->dev.release callback The mcb_bus structure previously was released in mcb_release_bus. This lead to the following warning on module unload: ------------[ cut here ]------------ WARNING: CPU: 1 PID: 2032 at drivers/base/core.c:251 device_release+0x73/0x90 Device 'mcb:0' does not have a release() function, it is broken and must be fixed. Modules linked in: men_z135_uart mcb_pci(-) mcb CPU: 1 PID: 2032 Comm: rmmod Not tainted 4.6.0-rc4+ #3 Hardware name: N/A N/A/COMe-mBTi10, BIOS MVV1R921 X64 10/14/2015 00000286 00000286 c0117de4 c12d6f16 c0117e2c c18be0d3 c0117dfc c104f6e1 000000fb f5ccbe08 f5ccbe00 f5c64600 c0117e18 c104f728 00000009 00000000 c0117e10 c18db674 c0117e2c c0117e3c c13ce5c3 c18be0d3 000000fb c18db674 Call Trace: [<c12d6f16>] dump_stack+0x47/0x61 [<c104f6e1>] __warn+0xc1/0xe0 [<c104f728>] warn_slowpath_fmt+0x28/0x30 [<c13ce5c3>] device_release+0x73/0x90 [<c12d92e4>] kobject_release+0x34/0x80 [<c12d929d>] ? kobject_del+0x2d/0x40 [<c12d9205>] kobject_put+0x25/0x50 [<c13ce77f>] put_device+0xf/0x20 [<c13d114b>] klist_devices_put+0xb/0x10 [<c1752673>] klist_next+0x73/0xf0 [<c13d1140>] ? unbind_store+0x100/0x100 [<f8a23370>] ? mcb_bus_add_devices+0x30/0x30 [mcb] [<c13d0a81>] bus_for_each_dev+0x51/0x80 [<f8a23319>] mcb_release_bus+0x19/0x40 [mcb] [<f8a23370>] ? mcb_bus_add_devices+0x30/0x30 [mcb] [<f8a2b033>] mcb_pci_remove+0x13/0x20 [mcb_pci] [<c130d358>] pci_device_remove+0x28/0xb0 [<c13d201b>] __device_release_driver+0x7b/0x110 [<c13d2847>] driver_detach+0x87/0x90 [<c13d1b9b>] bus_remove_driver+0x3b/0x80 [<c13d2ed0>] driver_unregister+0x20/0x50 [<c130be53>] pci_unregister_driver+0x13/0x60 [<f8a2b1f4>] mcb_pci_driver_exit+0xd/0xf [mcb_pci] [<c10be588>] SyS_delete_module+0x138/0x200 [<c1159208>] ? ____fput+0x8/0x10 [<c1068054>] ? task_work_run+0x74/0x90 [<c1001879>] do_fast_syscall_32+0x69/0x120 [<c1757597>] sysenter_past_esp+0x40/0x6a ---[ end trace 1ed34c2aa3019875 ]--- Release a mcb_bus' memory on the device's release callback, to avoid above warning. Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reported-by: Andreas Werner <andreas.werner@men.de> Tested-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/mcb/mcb-core.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) commit 803f1ca60d5c0107adfbce4e2d70488598b03a80 Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Tue May 3 09:46:23 2016 +0200 mcb: export bus information via sysfs Export information about the bus stored in the FPGA's header to userspace via sysfs, instead of hiding it in pr_debug()s from everyone. Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Andreas Werner <andreas.werner@men.de> Tested-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/ABI/testing/sysfs-bus-mcb | 29 ++++++++++++++++ drivers/mcb/mcb-core.c | 60 +++++++++++++++++++++++++++++++++ drivers/mcb/mcb-internal.h | 1 - drivers/mcb/mcb-parse.c | 15 +++------ include/linux/mcb.h | 9 +++++ 5 files changed, 103 insertions(+), 11 deletions(-) commit 18d28819809909c3f24bb72183a901c5e332a63d Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Tue May 3 09:46:22 2016 +0200 mcb: Correctly initialize the bus's device The mcb bus' device member wasn't correctly initialized and thus wasn't placed correctly into the driver model. Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Andreas Werner <andreas.werner@men.de> Tested-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/mcb/mcb-core.c | 19 ++++++++++++++++--- include/linux/mcb.h | 5 ++--- 2 files changed, 18 insertions(+), 6 deletions(-) commit bc46b45a421a64a0895dd41a34d3d2086e1ac7f6 Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Tue May 3 18:54:21 2016 -0400 mei: bus: call mei_cl_read_start under device lock Ensure that mei_cl_read_start is called under the device lock also in the bus layer. The function updates global ctrl_wr_list which should be locked. Cc: <stable@vger.kernel.org> #4.4+ Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/bus.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit bedffda8cad46bedb6880bb98c23c51c715216c3 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:34:01 2016 -0600 coresight: etb10: adjust read pointer only when needed The read pointer (read_ptr) needs to be adjusted only if its value has gone beyond the length of the memory buffer. Reported-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etb10.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit dc2c4ef141c5c14cb8d968ba16c74b4f3c373e2c Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:34:00 2016 -0600 coresight: configuring ETF in FIFO mode when acting as link When part of a path but not identified as a sink, the EFT has to be configured as a link and placed in HW FIFO mode. As such when enabling a path, call the right configuration function based on the role the ETF if playing in this trace run. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight.c | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) commit 2e499bbc1a929ac87dcb9832d11000fc055f8bc6 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:59 2016 -0600 coresight: tmc: implementing TMC-ETF AUX space API This patch implement the AUX area interfaces required to use the TMC (configured as an ETF) from the Perf sub-system. The heuristic is heavily borrowed from the ETB10 implementation. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 199 ++++++++++++++++++++++++ drivers/hwtracing/coresight/coresight-tmc.h | 1 + 2 files changed, 200 insertions(+) commit a02e81f7a32b49f3cb70c5ebd2eab5608a088514 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:58 2016 -0600 coresight: moving struct cs_buffers to header file That way we can re-use the structure in other drivers. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etb10.c | 20 -------------------- drivers/hwtracing/coresight/coresight-priv.h | 20 ++++++++++++++++++++ 2 files changed, 20 insertions(+), 20 deletions(-) commit 4f1ff3de925d741b0b77c59bc1387cb940ad7c73 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:57 2016 -0600 coresight: tmc: keep track of memory width Accessing the HW configuration register each time the memory width is needed simply doesn't make sense. It is much more efficient to read the value once and keep a reference for later use. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 14 +--------- drivers/hwtracing/coresight/coresight-tmc.c | 34 +++++++++++++++++++++++++ drivers/hwtracing/coresight/coresight-tmc.h | 10 +++++--- 3 files changed, 41 insertions(+), 17 deletions(-) commit b217601e9adce4d2dccc95a9e6814bdbf5a4a815 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:56 2016 -0600 coresight: tmc: make sysFS and Perf mode mutually exclusive The sysFS and Perf access methods can't be allowed to interfere with one another. As such introducing guards to access functions that prevents moving forward if a TMC is already being used. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 60 +++++++++++++++++++++++- drivers/hwtracing/coresight/coresight-tmc-etr.c | 62 +++++++++++++++++++++++-- 2 files changed, 117 insertions(+), 5 deletions(-) commit a40318fb01e98e72175bd9891208541148633d42 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:55 2016 -0600 coresight: tmc: dump system memory content only when needed Calling tmc_etf/etr_dump_hw() is required only when operating from sysFS. When working from Perf, the system memory is harvested from the AUX trace API. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 7 ++++++- drivers/hwtracing/coresight/coresight-tmc-etr.c | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) commit f2facc3366d77e78dbc8bf865f1e4a6227a7f0e5 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:54 2016 -0600 coresight: tmc: adding mode of operation for link/sinks Moving tmc_drvdata::enable to a local_t mode. That way the sink interface is aware of it's orgin and the foundation for mutual exclusion between the sysFS and Perf interface can be laid out. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 27 ++++++++++++++++++------- drivers/hwtracing/coresight/coresight-tmc-etr.c | 23 ++++++++++++++++----- drivers/hwtracing/coresight/coresight-tmc.h | 4 ++-- 3 files changed, 40 insertions(+), 14 deletions(-) commit f74debbea0885ebb65fb3fa4e598323f40b03f5f Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:53 2016 -0600 coresight: tmc: getting rid of multiple read access Allowing multiple readers to access the trace data simultaniously via sysFS provides no shortage of opportunity for race condition, mandates two variable to be maintained (drvdata::read_count and drvdata::reading), makes the code complex and provide little advantages, if any. This patch streamlines the read process by restricting trace data access to a single user. That way drvdata::read_count can be eliminated and race conditions (along with faulty error handling) in function tmc_open() and tmc_release() eliminated. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 5 +++++ drivers/hwtracing/coresight/coresight-tmc-etr.c | 4 ++++ drivers/hwtracing/coresight/coresight-tmc.c | 24 +++++++++--------------- drivers/hwtracing/coresight/coresight-tmc.h | 2 -- 4 files changed, 18 insertions(+), 17 deletions(-) commit de5461970b3e9e19470b821f5feaa3235ceb35f5 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:52 2016 -0600 coresight: tmc: allocating memory when needed In it's current form the TMC probe() function allocates trace buffer memory at boot time, event if coresight isn't used. This is highly inefficient since trace buffers can occupy a lot of memory that could be used otherwised. This patch allocates trace buffers on the fly, when the coresight subsystem is solicited. Allocated buffers are released when traces are read using the device descriptors under /dev. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 90 +++++++++++++++++++++--- drivers/hwtracing/coresight/coresight-tmc-etr.c | 93 +++++++++++++++++++++++-- drivers/hwtracing/coresight/coresight-tmc.c | 14 ---- 3 files changed, 170 insertions(+), 27 deletions(-) commit 4525412a5046692abb7a0588589d8ed2c20585e0 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:51 2016 -0600 coresight: tmc: making prepare/unprepare functions generic Dealing with HW related matters in tmc_read_prepare/unprepare becomes convoluted when many cases need to be handled distinctively. As such moving processing related to HW setup to individual driver files and keep the core driver generic. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc-etf.c | 62 ++++++++++++++++++++++++- drivers/hwtracing/coresight/coresight-tmc-etr.c | 42 ++++++++++++++++- drivers/hwtracing/coresight/coresight-tmc.c | 55 +++++----------------- drivers/hwtracing/coresight/coresight-tmc.h | 8 ++-- 4 files changed, 117 insertions(+), 50 deletions(-) commit 6c6ed1e244c0530fb76a8b52024f199f398ef100 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:50 2016 -0600 coresight: tmc: splitting driver in ETB/ETF and ETR components The TMC block can operate in 3 modes (ETB, ETF and ETR) and accessed via two interfaces (sysFS and Perf). That makes 6 mode to cover, which is way too much coupling for a single file. This patch splits the original TMC driver in 2 halves, one for ETB/ETF and another one for ETR mode. A common core is kept for functionality common to all 3 modes. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/Makefile | 4 +- drivers/hwtracing/coresight/coresight-tmc-etf.c | 204 ++++++++++++++++++ drivers/hwtracing/coresight/coresight-tmc-etr.c | 128 ++++++++++++ drivers/hwtracing/coresight/coresight-tmc.c | 264 +----------------------- drivers/hwtracing/coresight/coresight-tmc.h | 18 ++ 5 files changed, 357 insertions(+), 261 deletions(-) commit a8ab4268e0db93c564ee6ccb770bb3d53af24be9 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:49 2016 -0600 coresight: tmc: cleaning up header file This patch first move the TMC_STS_TMCREADY_BIT and TMC_FFCR_FLUSHMAN_BIT defines to their respective section. It also removes TMC_FFCR_FLUSHMAN, since the same result can easily be obtained using the BIT() macro. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 2 +- drivers/hwtracing/coresight/coresight-tmc.h | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) commit 4c324b5f0e8a692c8d077da9d18533820c2ab636 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:48 2016 -0600 coresight: tmc: introducing new header file The amount of #define, enumeration and structure definition is big enough to justify moving them to a new header file. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 102 +---------------------- drivers/hwtracing/coresight/coresight-tmc.h | 122 ++++++++++++++++++++++++++++ 2 files changed, 123 insertions(+), 101 deletions(-) commit ebba56e7b2bd2c9c2bbe02fad8808feef18e1519 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:47 2016 -0600 coresight: tmc: clearly define number of transfers per burst This patch makes the name of the define reflect the amount of data tranfers per burst, in this case 16. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b1789b793eb4627928f55a6acea8da7c25e5c6b4 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:46 2016 -0600 coresight: tmc: re-implementing tmc_read_prepare/unprepare() functions In their current implementation the tmc_read_prepare/unprepare() are a lump of if/else that is difficult to read. This patch is alleviating that by using a switch statement. The latter also allows for a better control on the error path. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 56 ++++++++++++++++++----------- 1 file changed, 36 insertions(+), 20 deletions(-) commit 358f42184e97f9a216b927a5a744597b98e0eee1 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:45 2016 -0600 coresight: tmc: waiting for TMCReady bit before programming According to the TRM before programming the TMC in circular buffer mode (and that for any configuration, ETB, ETR, ETF), the TMCReady bit in the status register has to be set. This patch adds a check to make sure the state machine is in a state where it can be configured, and complains otherwise. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 580ff804ecaf5bc59835fec26e17325bcd53fc91 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:44 2016 -0600 coresight: tmc: modifying naming convention According to the TMC architectural state machine, the 'stopped' state is reached when bit 2 (TMCReady) of the TMC Status register turns to '1'. The code is correct but the naming convention isn't. The 'Triggered' bit occupies position '1' of the TMC Status register and has nothing to do with the indication of the TMC entering the stopped state. As such renaming function "tmc_wait_for_triggered()" and changing the #define to reflect what the code is really doing. This patch has no effect other than clarifying the semantic. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-tmc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 7d83d17795efce95def54a13ccd6c3f80de6e8f0 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:43 2016 -0600 coresight: tmc: adding sysFS management entries Adding management registers that convey implementation specific characteristics. Those are useful for trace configuration and collection along with general trouble shooting. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../ABI/testing/sysfs-bus-coresight-devices-tmc | 77 +++++++++++++++ drivers/hwtracing/coresight/coresight-tmc.c | 107 +++++++++------------ 2 files changed, 120 insertions(+), 64 deletions(-) commit 960e30959988e0f37e0eeb22b6cdb65b94d5d2e7 Author: Li Pengcheng <lipengcheng8@huawei.com> Date: Tue May 3 11:33:42 2016 -0600 coresight: etm4x: add tracer ID for A72 Maia processor. This patch adds a cellID for the ETMv4 tracer found on HiSillicon's A72 Maia processor. Signed-off-by: Li Pengcheng <lipengcheng8@huawei.com> Signed-off-by: Li Zhong <lizhong11@hisilicon.com> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etm4x.c | 5 +++++ 1 file changed, 5 insertions(+) commit b5af0a26da84b75376706a92c7a58036a0bf3541 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:41 2016 -0600 coresight: etb10: fixing the right amount of words to read This patch rectifies the amount of words to read when the internal buffer is deemed bigger than the amount of space available in the perf ring buffer. The amount to read is set to the amount of space in the perf ring buffer rather than being subtracted by it. Reported-by: Suzuki K Poulose <Suzuki.Poulose@arm.com> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etb10.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 237483aa5cf43105d148d3f03b29eed47c3e6cf9 Author: Pratik Patel <pratikp@codeaurora.org> Date: Tue May 3 11:33:40 2016 -0600 coresight: stm: adding driver for CoreSight STM component This driver adds support for the STM CoreSight IP block, allowing any system compoment (HW or SW) to log and aggregate messages via a single entity. The CoreSight STM exposes an application defined number of channels called stimulus port. Configuration is done using entries in sysfs and channels made available to userspace via configfs. Signed-off-by: Pratik Patel <pratikp@codeaurora.org> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: Michael Williams <michael.williams@arm.com> Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../ABI/testing/sysfs-bus-coresight-devices-stm | 53 ++ Documentation/trace/coresight.txt | 37 +- drivers/hwtracing/coresight/Kconfig | 11 + drivers/hwtracing/coresight/Makefile | 1 + drivers/hwtracing/coresight/coresight-stm.c | 920 +++++++++++++++++++++ include/linux/coresight-stm.h | 6 + include/uapi/linux/coresight-stm.h | 21 + 7 files changed, 1047 insertions(+), 2 deletions(-) commit 9eb933130df2f8e67aba4f76565fe6604150a542 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:39 2016 -0600 coresight: stm: Bindings for System Trace Macrocell The System Trace Macrocell (STM) is an IP block falling under the CoreSight umbrella. It's main purpose it so expose stimulus channels to any system component for the purpose of information logging. Bindings for this IP block adds a couple of items to the current mandatory definition for CoreSight components. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../devicetree/bindings/arm/coresight.txt | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit a685d68328f14579b2e68d6a3a2066089cffbf98 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue May 3 11:33:38 2016 -0600 coresight: adding path for STM device >From a core framework point of view an STM device is a source that is treated the same way as any other tracers. Unlike tracers though STM devices are not associated with a CPU. As such it doesn't make sense to associate the path from an STM device to its sink with a per-cpu variable as it is done for tracers. This patch simply adds another global variable to keep STM paths and the processing in coresight_enable/disable() is updated to deal with STM devices properly. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight.c | 106 ++++++++++++++++++++++++-------- 1 file changed, 82 insertions(+), 24 deletions(-) commit 8e996a2874bbbed30e8dfe881453825fc6b7654e Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Tue May 3 11:33:37 2016 -0600 stm class: Support devices that override software assigned masters Some STM devices adjust software assigned master numbers depending on the trace source and its runtime state and whatnot. This patch adds a sysfs attribute to inform the trace-side software that master numbers assigned to software sources will not match those in the STP stream, so that, for example, master/channel allocation policy can be adjusted accordingly. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/ABI/testing/sysfs-class-stm | 10 ++++++++++ drivers/hwtracing/stm/core.c | 15 +++++++++++++++ include/linux/stm.h | 3 +++ 3 files changed, 28 insertions(+) commit 6327a454a8ab0dcab24a647367d216c1b84020c6 Author: Li Pengcheng <lipengcheng8@huawei.com> Date: Tue May 3 11:33:36 2016 -0600 coresight: etm4x: modify q_support type Because this operation exceed the range of boolean, so we should modify q_support to unit8 bit. drvdata->q_support = BMVAL(etmidr0, 15, 16) Signed-off-by: Li Pengcheng <lipengcheng8@huawei.com> Signed-off-by: Li Zhong <lizhong11@hisilicon.com> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etm4x.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e8dc27d0ee458f9622b50e2d9476719b3a0e686b Author: Li Pengcheng <lipengcheng8@huawei.com> Date: Tue May 3 11:33:35 2016 -0600 coresight: no need to do the forced type conversion activated and enable are already unsigned type, no need to change them to unsigned. Signed-off-by: Li Pengcheng <lipengcheng8@huawei.com> Signed-off-by: Li Zhong <lizhong11@hisilicon.com> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0fc1b09ff1ff404ddf753f5ffa5cd0adc8fdcdc9 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Tue May 3 17:15:43 2016 -0400 tracing: Use temp buffer when filtering events Filtering of events requires the data to be written to the ring buffer before it can be decided to filter or not. This is because the parameters of the filter are based on the result that is written to the ring buffer and not on the parameters that are passed into the trace functions. The ftrace ring buffer is optimized for writing into the ring buffer and committing. The discard procedure used when filtering decides the event should be discarded is much more heavy weight. Thus, using a temporary filter when filtering events can speed things up drastically. Without a temp buffer we have: # trace-cmd start -p nop # perf stat -r 10 hackbench 50 0.790706626 seconds time elapsed ( +- 0.71% ) # trace-cmd start -e all # perf stat -r 10 hackbench 50 1.566904059 seconds time elapsed ( +- 0.27% ) # trace-cmd start -e all -f 'common_preempt_count==20' # perf stat -r 10 hackbench 50 1.690598511 seconds time elapsed ( +- 0.19% ) # trace-cmd start -e all -f 'common_preempt_count!=20' # perf stat -r 10 hackbench 50 1.707486364 seconds time elapsed ( +- 0.30% ) The first run above is without any tracing, just to get a based figure. hackbench takes ~0.79 seconds to run on the system. The second run enables tracing all events where nothing is filtered. This increases the time by 100% and hackbench takes 1.57 seconds to run. The third run filters all events where the preempt count will equal "20" (this should never happen) thus all events are discarded. This takes 1.69 seconds to run. This is 10% slower than just committing the events! The last run enables all events and filters where the filter will commit all events, and this takes 1.70 seconds to run. The filtering overhead is approximately 10%. Thus, the discard and commit of an event from the ring buffer may be about the same time. With this patch, the numbers change: # trace-cmd start -p nop # perf stat -r 10 hackbench 50 0.778233033 seconds time elapsed ( +- 0.38% ) # trace-cmd start -e all # perf stat -r 10 hackbench 50 1.582102692 seconds time elapsed ( +- 0.28% ) # trace-cmd start -e all -f 'common_preempt_count==20' # perf stat -r 10 hackbench 50 1.309230710 seconds time elapsed ( +- 0.22% ) # trace-cmd start -e all -f 'common_preempt_count!=20' # perf stat -r 10 hackbench 50 1.786001924 seconds time elapsed ( +- 0.20% ) The first run is again the base with no tracing. The second run is all tracing with no filtering. It is a little slower, but that may be well within the noise. The third run shows that discarding all events only took 1.3 seconds. This is a speed up of 23%! The discard is much faster than even the commit. The one downside is shown in the last run. Events that are not discarded by the filter will take longer to add, this is due to the extra copy of the event. Cc: Alexei Starovoitov <ast@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 154 +++++++++++++++++++++++++++++++++++-- kernel/trace/trace.h | 19 ++++- kernel/trace/trace_events.c | 10 +++ kernel/trace/trace_events_filter.c | 10 +++ 4 files changed, 185 insertions(+), 8 deletions(-) commit e6c037bfcafad1b401a6c02ba05a3f1b87925860 Merge: 681fef8 71f5c63 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue May 3 14:49:46 2016 -0700 Merge tag 'phy-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy into usb-testing Kishon writes: phy: for 4.7 *) Add a new PHY driver for USB2 PHY on Northstar SoC *) Add support for Broadcom NS2 SATA3 PHY in existing Broadcom SATA3 PHY driver *) Add support for MIPI DPHYs in Exynos5420-compatible (5420, 5422 and 5800) and Exynos5433 SoCs *) Add support for USB3 PHY on mt2701 *) Add extcon support for Renesas R-car USB2 PHY driver *) Misc cleanups Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> commit 681fef8380eb818c0b845fca5d2ab1dcbab114ee Author: Kangjie Lu <kangjielu@gmail.com> Date: Tue May 3 16:32:16 2016 -0400 USB: usbfs: fix potential infoleak in devio The stack object “ci” has a total size of 8 bytes. Its last 3 bytes are padding bytes which are not initialized and leaked to userland via “copy_to_user”. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/devio.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 973986126a4152ab83d09263a02bf7d2d1bf3b6e Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 3 10:49:00 2016 +0300 usb: dwc3: gadget: fix mask and shift order in DWC3_DCFG_NUMP() In the original DWC3_DCFG_NUMP() was always zero. It looks like the intent was to shift first and then do the mask. Fixes: 2a58f9c12bb3 ('usb: dwc3: gadget: disable automatic calculation of ACK TP NUMP') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Felipe Balbi <balbi@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/dwc3/core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 88a0044e6c99a2182e46d56fb8613716b2dc8f3d Author: Oliver Neukum <oneukum@suse.com> Date: Mon May 2 13:09:30 2016 +0200 sisusbvga: correct speed testing Allow for SS+ Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/misc/sisusbvga/sisusb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cdc77c82a8286b1181b81b6e5ef60c8e83ded7bc Author: Mathias Nyman <mathias.nyman@linux.intel.com> Date: Mon May 2 11:39:03 2016 +0300 usb: misc: usbtest: fix pattern tests for scatterlists. The current implemenentation restart the sent pattern for each entry in the sg list. The receiving end expects a continuous pattern, and test will fail unless scatterilst entries happen to be aligned with the pattern Fix this by calculating the pattern byte based on total sent size instead of just the current sg entry. Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Fixes: 8b5249019352 ("[PATCH] USB: usbtest: scatterlist OUT data pattern testing") Cc: <stable@vger.kernel.org> # v2.6.18+ Acked-by: Felipe Balbi <felipe.balbi@linux.intel.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/misc/usbtest.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 72f595f3b5cef2c36beb1d07409de58d9e503428 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 19:29:40 2016 +0100 usb: renesas_usbhs: fix signed-unsigned return The return type of usbhsp_setup_pipecfg() was u16 but it was returning a negative value (-EINVAL). Lets have an additional argument which will have pipecfg and just return the status (success or error) as the return from the function. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/renesas_usbhs/pipe.c | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) commit 6fb650d43da3e7054984dc548eaa88765a94d49f Author: Alan Stern <stern@rowland.harvard.edu> Date: Fri Apr 29 15:25:17 2016 -0400 USB: leave LPM alone if possible when binding/unbinding interface drivers When a USB driver is bound to an interface (either through probing or by claiming it) or is unbound from an interface, the USB core always disables Link Power Management during the transition and then re-enables it afterward. The reason is because the driver might want to prevent hub-initiated link power transitions, in which case the HCD would have to recalculate the various LPM parameters. This recalculation takes place when LPM is re-enabled and the new parameters are sent to the device and its parent hub. However, if the driver does not want to prevent hub-initiated link power transitions then none of this work is necessary. The parameters don't need to be recalculated, and LPM doesn't need to be disabled and re-enabled. It turns out that disabling and enabling LPM can be time-consuming, enough so that it interferes with user programs that want to claim and release interfaces rapidly via usbfs. Since the usbfs kernel driver doesn't set the disable_hub_initiated_lpm flag, we can speed things up and get the user programs to work by leaving LPM alone whenever the flag isn't set. And while we're improving the way disable_hub_initiated_lpm gets used, let's also fix its kerneldoc. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Tested-by: Matthew Giassa <matthew@giassa.net> CC: Mathias Nyman <mathias.nyman@intel.com> CC: <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/driver.c | 40 +++++++++++++++++++++++----------------- include/linux/usb.h | 2 +- 2 files changed, 24 insertions(+), 18 deletions(-) commit e66fa8b08fbd87f375f964f1eaa1f5dfab9dc0c4 Author: Nobuo Iwata <nobuo.iwata@fujixerox.co.jp> Date: Tue Mar 22 16:31:03 2016 +0900 usbip: adding names db to port operation Adding names database to port command. BEFORE) 'unknown' for vendor and product string. Imported USB devices ==================== Port 00: <Port in Use> at Low Speed(1.5Mbps) unknown vendor : unknown product (03f0:0224) 3-1 -> usbip://10.0.2.15:3240/5-1 -> remote bus/dev 005/002 AFTER) Most vendor string will be converted. Imported USB devices ==================== Port 00: <Port in Use> at Low Speed(1.5Mbps) Hewlett-Packard : unknown product (03f0:0224) 3-1 -> usbip://10.0.2.15:3240/5-1 -> remote bus/dev 005/002 Signed-off-by: Nobuo Iwata <nobuo.iwata@fujixerox.co.jp> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> tools/usb/usbip/src/usbip_port.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 5c69585837686e127762bd20658b18c14dfaf57c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:52 2016 -0700 staging: comedi: mite: tidy up module init/exit Move the module_init()/module_exit() so they are in the prefered spot on the line after the function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit b21f1fc84cb6ad217e5d450e217767f37ca1dee5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:51 2016 -0700 staging: comedi: mite: document the remaining exported functions For aesthetics, add docbook comments for the exported functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 23 +++++++++++++++++++++++ drivers/staging/comedi/drivers/mite.h | 9 +++++---- 2 files changed, 28 insertions(+), 4 deletions(-) commit f5f4f0c7c8c66bac165e6a16d77dc26fbeb4967e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:50 2016 -0700 staging: comedi: mite: move the mite dma arm/disarm/reset functions For aesthetics, move these functions to a more logical spot in the code and add docbook comments for the exported functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 76 +++++++++++++++++++---------------- drivers/staging/comedi/drivers/mite.h | 5 ++- 2 files changed, 45 insertions(+), 36 deletions(-) commit 71f53ea4ba9d2d8a563ad553439a545612ff2f2c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:49 2016 -0700 staging: comedi: mite: move mite_prep_dma() For aesthetics, move this functions to a more logical spot in the code and add a docbook comment for the exported function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 176 ++++++++++++++++++---------------- drivers/staging/comedi/drivers/mite.h | 2 +- 2 files changed, 92 insertions(+), 86 deletions(-) commit c3c860b395c7ca18bd30917b1cdbde66b7e090e0 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:48 2016 -0700 staging: comedi: mite: tidy up mite dma channel request/release For aesthetics, make the actual "request" function static and change mite_request_channel_in_range() into a wrapper that calls the internal function. Change the inline function that requests any free channel into an export that also calls the internal function. Move the functions to a more logical spot in the code and add docbook comments for the exported functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 137 +++++++++++++++++++++------------- drivers/staging/comedi/drivers/mite.h | 21 ++---- 2 files changed, 91 insertions(+), 67 deletions(-) commit fc53242394d3a5f73cae507361b9768243b2d5a2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:47 2016 -0700 staging: comedi: mite: move the mite ring functions For aesthetics, move the functions that allocate/free and initialize the mite dma ring. They are currently kind of scattered around the code. Add docbook comments for the exported functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 274 ++++++++++++++++++---------------- drivers/staging/comedi/drivers/mite.h | 8 +- 2 files changed, 150 insertions(+), 132 deletions(-) commit a2163cc35a6fb8852ad7ce1fa4eb90bad0674bbd Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:46 2016 -0700 staging: comedi: mite: tidy up kernel messages in mite_steup() The dev_err() messages with pci_ioremap_bar() fails are just noise. Remove them. The 'use_win1' and 'fifo_size' dev_info() messages are also noise but they may be useful when debugging. Change them to dev_dbg(). Absorb dump_chip_signnature() and change the pr_info() messages to dev_dbg(). These also might be useful when debugging. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 50 +++++++++++++++-------------------- 1 file changed, 21 insertions(+), 29 deletions(-) commit 48f2c1aecfbcfe5ab4b2a003dee1a469e7c32214 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:45 2016 -0700 staging: comedi: mite: do mite_steup() as part of mite_attach() Currently all the drivers that use the mite driver have to call mite_setup() after allocating and initializing the mite device with mite_attach(). Move the mite_setup() call into mite_attach() to simplify the drivers a bit and remove the need for the additional inline and exported functions. For aesthetics, move mite_setup2(), and rename it to mite_setup(), so it's near mite_attach(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 183 +++++++++++++++-------------- drivers/staging/comedi/drivers/mite.h | 10 +- drivers/staging/comedi/drivers/ni_660x.c | 6 +- drivers/staging/comedi/drivers/ni_pcidio.c | 6 +- drivers/staging/comedi/drivers/ni_pcimio.c | 6 +- 5 files changed, 101 insertions(+), 110 deletions(-) commit 5b329305d252834fa2a40fcb318743bcc18c8a98 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:44 2016 -0700 staging: comedi: mite: document mite_alloc()/mite_detach() These functions are basically the comedi_driver (*attach)/(*detach) for this driver. For aesthetics, rename mite_alloc() to mite_attach() and pass the comedi_device pointer to it instead of the pci_dev pointer. Move the functions to the end of the file. This is typically where a comedi_drivers (*attach)/(*detach) are located. Add some docbook comments for these exported functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 78 ++++++++++++++++++------------ drivers/staging/comedi/drivers/mite.h | 6 +-- drivers/staging/comedi/drivers/ni_660x.c | 2 +- drivers/staging/comedi/drivers/ni_pcidio.c | 2 +- drivers/staging/comedi/drivers/ni_pcimio.c | 2 +- 5 files changed, 53 insertions(+), 37 deletions(-) commit 0bdb1288fae54833367f00a1c76244a30731b8c9 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:43 2016 -0700 staging: comedi: mite: use prefered form for passing a struct size Add a local variable to mite_buf_change() so that the prefered form of passing a struct size, sizeof(*p), can be used. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 9ec148da5fcb04456e883cb243fa1e872d47d385 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:42 2016 -0700 staging: comedi: mite: introduce mite_free_dma_descs() Introduce a helper function to handle the dma_free_coherent() of the mite dma descriptors. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 33 ++++++++++++++++----------------- 1 file changed, 16 insertions(+), 17 deletions(-) commit 48a73aedd7e47140bec5ccab17d4aa8604f76000 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:41 2016 -0700 staging: comedi: mite: remove mite member 'channel_allocated' An allocated mite_channel will have its 'ring' member initialized to point to the mite_ring that will be used for DMA. A non-allocated mite_channel will have a 'ring' member set to NULL, either by a channel release or due to the initial kzalloc of the 'mite' struct. Refactor the code to use the mite_chan->ring to detect in a channel is allocated and remove the unnecessary member. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 17 ++++++++--------- drivers/staging/comedi/drivers/mite.h | 1 - 2 files changed, 8 insertions(+), 10 deletions(-) commit ab55b5c9f225d32a5355f7c799ab09c7fae5456d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:40 2016 -0700 staging: comedi: mite: rename mite member 'mite_io_addr' Rename this member of struct mite to 'mmio' to help shorten the long lines. Add a local variable for the mite pointer in the ni_pcimio driver to clarify and shorten the long lines. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 69 +++++++++++++----------------- drivers/staging/comedi/drivers/mite.h | 2 +- drivers/staging/comedi/drivers/ni_pcimio.c | 26 +++++------ 3 files changed, 44 insertions(+), 53 deletions(-) commit 3303410d04f28fa70d19adc9de2ae15a0909aff5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:39 2016 -0700 staging: comedi: mite: tidy up mite_init_ring_descriptors() Use a local variable for the mite_dma_desc pointer to help clarify this function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) commit b0af848ca3d4f1f234828ea92feb08667ff8c81e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:38 2016 -0700 staging: comedi: mite: rename mite_ring member 'descriptors' Rename this member of struct mite_ring to 'descs' to help shorten the long lines. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 28 ++++++++++++++-------------- drivers/staging/comedi/drivers/mite.h | 2 +- 2 files changed, 15 insertions(+), 15 deletions(-) commit a8b559275e479f1f18b40e7ddac79e4bd436bb24 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:37 2016 -0700 staging: comedi: mite: rename mite_ring member 'descriptors_dma_addr' Rename this member of struct mite_ring to 'dma_addr' to help shorten the long lines. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 16 ++++++++-------- drivers/staging/comedi/drivers/mite.h | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) commit 19d9212ef93fca5be07e6b8554a00dcb82124c7d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:36 2016 -0700 staging: comedi: mite: rename 'struct mite_dma_descriptor_ring' Rename this name to 'mite_ring' to help shorten the long lines. In the ni_660x driver, also shorten the private data member 'mite_rings' to simply 'ring'. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 21 +++++++++---------- drivers/staging/comedi/drivers/mite.h | 29 ++++++++++++-------------- drivers/staging/comedi/drivers/ni_660x.c | 18 +++++++--------- drivers/staging/comedi/drivers/ni_mio_common.c | 2 +- drivers/staging/comedi/drivers/ni_pcidio.c | 2 +- drivers/staging/comedi/drivers/ni_stc.h | 8 +++---- 6 files changed, 37 insertions(+), 43 deletions(-) commit f5d077cd207155b3bbd66e7765d24732591a392b Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:35 2016 -0700 staging: comedi: mite: rename 'struct mite_dma_descriptor' Rename this struct to 'mite_dma_desc' to help shorten the long lines. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 8 ++++---- drivers/staging/comedi/drivers/mite.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) commit 1a8da31b6cbca7cd0a6b6ca738fa420eb2ee899a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon May 2 10:11:34 2016 -0700 staging: comedi: mite: rename 'struct mite_struct' Rename this struct to simply 'mite'. The current name is a bit redundant. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 33 +++++++++++++++--------------- drivers/staging/comedi/drivers/mite.h | 18 ++++++++-------- drivers/staging/comedi/drivers/ni_660x.c | 2 +- drivers/staging/comedi/drivers/ni_pcidio.c | 2 +- drivers/staging/comedi/drivers/ni_stc.h | 2 +- 5 files changed, 28 insertions(+), 29 deletions(-) commit 43bb50ec36519f9b21d4f55da0154b00e9fe06b7 Author: Manu Kumar <maraku@gmx.com> Date: Sun May 1 16:38:35 2016 -0700 staging: skein: cleanup: align code to parentheses Align wrapped lines to parentheses (if applicable). Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_base.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit e602a80822a111b6a476ec14e6d1065ac27f11c1 Author: Manu Kumar <maraku@gmx.com> Date: Sun May 1 16:38:34 2016 -0700 staging: skein: cleanup: removed unnecessary cast spaces Spaces after casts are removed Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_api.c | 2 +- drivers/staging/skein/skein_base.c | 12 ++++++------ drivers/staging/skein/skein_base.h | 12 ++++++------ drivers/staging/skein/skein_block.c | 12 ++++++------ 4 files changed, 19 insertions(+), 19 deletions(-) commit 5b05c1e243d594860350657988d735522f0321f4 Author: Manu Kumar <maraku@gmx.com> Date: Sun May 1 16:38:33 2016 -0700 staging: skein: cleanup: Fixed operator whitespace added operator white space and parentheses for readability Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_base.c | 24 ++++++++++++------------ drivers/staging/skein/skein_block.c | 8 ++++---- 2 files changed, 16 insertions(+), 16 deletions(-) commit a28e32e061ac8786898c9499bd14bc074d8a0e6c Author: Manu Kumar <maraku@gmx.com> Date: Sun May 1 16:38:32 2016 -0700 staging: skein: cleanup: fixed new lines Added lines between functions in skein_block.c and removed unneeded lines in skein_block.c Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_api.c | 1 - drivers/staging/skein/skein_block.c | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) commit beba2ab84e60a548e6e53f692cb011c58f255707 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:55 2016 +0900 staging: wilc1000: rename result in handle_get_mac_address This patch renames result to ret that is used to get return value from wilc_send_config_pkt. Some handle_*() functions are used as result, others are used as ret. It will be changed as ret in all handle_*() functions to match variable name. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 098bd3fd065390f0ea1323a7049b3e291e3aefca Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:54 2016 +0900 staging: wilc1000: change data type of result in handle_get_mac_address This patch changes data type of result variable from s32 to int. result is used to get return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 93dc5d5583e58e8cfa0355826396ac757e93f468 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:53 2016 +0900 staging: wilc1000: change handle_get_mac_address's return type to void When handle_get_mac_address is called in hostIFthread that is a kernel thread, it is not checked return type of this function. This patch changes return type to void and removes braces if statement due to have a single statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit abfaf5fcd8be6c014d773139390d54d4611ef596 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:52 2016 +0900 staging: wilc1000: fix comparison style of if statement in handle_get_ip_address This patch changes conditional comparison of if statement as if (ret) instead of using if (ret != 0) Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6f2f5d5ec1091bb54e913c3c26bad5ff6e8f9dd0 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:51 2016 +0900 staging: wilc1000: rename result in handle_get_ip_address This patch renames result to ret that is used to get return value from wilc_send_config_pkt. Some handle_*() functions are used as result, others are used as ret. It will be changed as ret in all handle_*() functions to match variable name. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit cdc339a29f8ea0cf82390823e9297404699a7a07 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:50 2016 +0900 staging: wilc1000: change data type of result in handle_get_ip_address This patch changes data type of result variable from s32 to int. result is used to get return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f9d9e0041e8f665b45ab1b25dc34faac01e22b7 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon May 2 19:47:49 2016 +0900 staging: wilc1000: change handle_get_ip_address's return type to void When handle_get_ip_address is called in hostIFthread that is a kernel thread, it is not checked return type of this function. This patch changes return type to void and removes braces if statement due to have a single statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 26879da58711aa604a1b866cbeedd7e0f78f90ad Author: Wei Wang <weiwan@google.com> Date: Mon May 2 21:40:07 2016 -0700 ipv6: add new struct ipcm6_cookie In the sendmsg function of UDP, raw, ICMP and l2tp sockets, we use local variables like hlimits, tclass, opt and dontfrag and pass them to corresponding functions like ip6_make_skb, ip6_append_data and xxx_push_pending_frames. This is not a good practice and makes it hard to add new parameters. This fix introduces a new struct ipcm6_cookie similar to ipcm_cookie in ipv4 and include the above mentioned variables. And we only pass the pointer to this structure to corresponding functions. This makes it easier to add new parameters in the future and makes the function cleaner. Signed-off-by: Wei Wang <weiwan@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ipv6.h | 18 ++++++++++++------ include/net/transp_v6.h | 3 +-- net/ipv6/datagram.c | 13 ++++++------- net/ipv6/icmp.c | 28 ++++++++++++++++------------ net/ipv6/ip6_flowlabel.c | 6 +++--- net/ipv6/ip6_output.c | 42 ++++++++++++++++++++---------------------- net/ipv6/ipv6_sockglue.c | 6 +++--- net/ipv6/ping.c | 12 +++++++----- net/ipv6/raw.c | 33 ++++++++++++++++++--------------- net/ipv6/udp.c | 38 +++++++++++++++++++------------------- net/l2tp/l2tp_ip6.c | 33 ++++++++++++++++++--------------- 11 files changed, 123 insertions(+), 109 deletions(-) commit 1d2077ac0165c0d173a2255e37cf4dc5033d92c7 Author: Eric Dumazet <edumazet@google.com> Date: Mon May 2 10:56:27 2016 -0700 net: add __sock_wfree() helper Hosts sending lot of ACK packets exhibit high sock_wfree() cost because of cache line miss to test SOCK_USE_WRITE_QUEUE We could move this flag close to sk_wmem_alloc but it is better to perform the atomic_sub_and_test() on a clean cache line, as it avoid one extra bus transaction. skb_orphan_partial() can also have a fast track for packets that either are TCP acks, or already went through another skb_orphan_partial() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 1 + net/core/sock.c | 24 ++++++++++++++++++++++++ net/ipv4/tcp_output.c | 2 +- 3 files changed, 26 insertions(+), 1 deletion(-) commit 87c32077819c695cbc5ab00226a28010cd5806c3 Author: Keith Busch <keith.busch@intel.com> Date: Fri Apr 8 16:11:02 2016 -0600 NVMe: Fix reset/remove race This fixes a scenario where device is present and being reset, but a request to unbind the driver occurs. A previous patch series addressing a device failure removal scenario flushed reset_work after controller disable to unblock reset_work waiting on a completion that wouldn't occur. This isn't safe as-is. The broken scenario can potentially be induced with: modprobe nvme && modprobe -r nvme To fix, the reset work is flushed immediately after setting the controller removing flag, and any subsequent reset will not proceed with controller initialization if the flag is set. The controller status must be polled while active, so the watchdog timer is also left active until the controller is disabled to cleanup requests that may be stuck during namespace removal. [Fixes: ff23a2a15a2117245b4599c1352343c8b8fb4c43] Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit e34b1638d02bef8c3278af30ee73077c5babc082 Merge: 2b84af94a 10724cc Author: David S. Miller <davem@davemloft.net> Date: Tue May 3 15:51:17 2016 -0400 Merge branch 'tipc-next' Jon Maloy says: ==================== tipc: redesign socket-level flow control The socket-level flow control in TIPC has long been due for a major overhaul. This series fixes this. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 10724cc7bb7832b482df049c20fd824d928c5eaa Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Mon May 2 11:58:47 2016 -0400 tipc: redesign connection-level flow control There are two flow control mechanisms in TIPC; one at link level that handles network congestion, burst control, and retransmission, and one at connection level which' only remaining task is to prevent overflow in the receiving socket buffer. In TIPC, the latter task has to be solved end-to-end because messages can not be thrown away once they have been accepted and delivered upwards from the link layer, i.e, we can never permit the receive buffer to overflow. Currently, this algorithm is message based. A counter in the receiving socket keeps track of number of consumed messages, and sends a dedicated acknowledge message back to the sender for each 256 consumed message. A counter at the sending end keeps track of the sent, not yet acknowledged messages, and blocks the sender if this number ever reaches 512 unacknowledged messages. When the missing acknowledge arrives, the socket is then woken up for renewed transmission. This works well for keeping the message flow running, as it almost never happens that a sender socket is blocked this way. A problem with the current mechanism is that it potentially is very memory consuming. Since we don't distinguish between small and large messages, we have to dimension the socket receive buffer according to a worst-case of both. I.e., the window size must be chosen large enough to sustain a reasonable throughput even for the smallest messages, while we must still consider a scenario where all messages are of maximum size. Hence, the current fix window size of 512 messages and a maximum message size of 66k results in a receive buffer of 66 MB when truesize(66k) = 131k is taken into account. It is possible to do much better. This commit introduces an algorithm where we instead use 1024-byte blocks as base unit. This unit, always rounded upwards from the actual message size, is used when we advertise windows as well as when we count and acknowledge transmitted data. The advertised window is based on the configured receive buffer size in such a way that even the worst-case truesize/msgsize ratio always is covered. Since the smallest possible message size (from a flow control viewpoint) now is 1024 bytes, we can safely assume this ratio to be less than four, which is the value we are now using. This way, we have been able to reduce the default receive buffer size from 66 MB to 2 MB with maintained performance. In order to keep this solution backwards compatible, we introduce a new capability bit in the discovery protocol, and use this throughout the message sending/reception path to always select the right unit. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/core.c | 8 ++-- net/tipc/msg.h | 14 +++++- net/tipc/node.h | 5 +- net/tipc/socket.c | 140 +++++++++++++++++++++++++++++++++++------------------- net/tipc/socket.h | 17 +++++-- 5 files changed, 122 insertions(+), 62 deletions(-) commit 60020e1857042387cdcd4cd6680a9e5496213379 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Mon May 2 11:58:46 2016 -0400 tipc: propagate peer node capabilities to socket layer During neighbor discovery, nodes advertise their capabilities as a bit map in a dedicated 16-bit field in the discovery message header. This bit map has so far only be stored in the node structure on the peer nodes, but we now see the need to keep a copy even in the socket structure. This commit adds this functionality. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/node.c | 21 +++++++++++++++++++-- net/tipc/node.h | 1 + net/tipc/socket.c | 2 ++ 3 files changed, 22 insertions(+), 2 deletions(-) commit 7c8bcfb1255fe9d929c227d67bdcd84430fd200b Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Mon May 2 11:58:45 2016 -0400 tipc: re-enable compensation for socket receive buffer double counting In the refactoring commit d570d86497ee ("tipc: enqueue arrived buffers in socket in separate function") we did by accident replace the test if (sk->sk_backlog.len == 0) atomic_set(&tsk->dupl_rcvcnt, 0); with if (sk->sk_backlog.len) atomic_set(&tsk->dupl_rcvcnt, 0); This effectively disables the compensation we have for the double receive buffer accounting that occurs temporarily when buffers are moved from the backlog to the socket receive queue. Until now, this has gone unnoticed because of the large receive buffer limits we are applying, but becomes indispensable when we reduce this buffer limit later in this series. We now fix this by inverting the mentioned condition. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2b84af94a3932b1dcb716d1898edb18b7325dbea Author: Oliver Neukum <oneukum@suse.com> Date: Mon May 2 13:06:14 2016 +0200 rtl8152: correct speed testing Allow for SS+ USB Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/r8152.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ea0798423c60a1d34c75e5fedae009aee0a8de5f Author: Oliver Neukum <oneukum@suse.com> Date: Mon May 2 13:06:13 2016 +0200 usbnet: correct speed testing Allow for SS+ USB Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/usb/usbnet.c | 1 + 1 file changed, 1 insertion(+) commit 8caf115c726e87526c4a1cbd8ba616d6a022ccd8 Author: Oliver Neukum <oneukum@suse.com> Date: Mon May 2 13:06:12 2016 +0200 brcm80211: correct speed testing Allow for SS+ USB Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit c0f31a05f5b405b67e08079d218ac42b3f0a1786 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Mon May 2 06:16:04 2016 -0400 qed: Apply tunnel configurations after PF start Configure and enable various tunnels on the adapter after PF start. This change was missed as a part of 'commit 464f664501816ef5fbbc00b8de96f4ae5a1c9325 ("qed: Add infrastructure support for tunneling")' Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <yuval.mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 64c59a3726f2dfa71680f9f3c34359e10e3ed7ab Author: J. Bruce Fields <bfields@redhat.com> Date: Fri Apr 29 11:35:45 2016 -0400 Remove unnecessary allocation Reported-by: Benjamin Coddington <bcodding@redhat.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com> net/sunrpc/auth_gss/svcauth_gss.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit da7daf5b76a0e067887567267ba020599e9c13b2 Merge: e03179f 0f400a8 Author: David S. Miller <davem@davemloft.net> Date: Tue May 3 15:22:21 2016 -0400 Merge branch 'stmmac-dwmac-socfpga-cleanup' Joachim Eastwood says: ==================== stmmac: dwmac-socfpga refactor+cleanup This patch aims to remove the init/exit callbacks from the dwmac- socfpga driver and instead use standard PM callbacks. Doing this will also allow us to cleanup the driver. Eventually the init/exit callbacks will be deprecated and removed from all drivers dwmac-* except for dwmac-generic. Drivers will be refactored to use standard PM and remove callbacks. This patch set should not change the behavior of the driver itself, it only moves code around. The only exception to this is patch number 4 which restores the resume callback behavior which was changed in the "net: stmmac: socfpga: Remove re-registration of reset controller" patch. I belive calling phy_resume() only from the resume callback and not probe is the right thing to do. Changes from v1: - Rebase on net-next One heads-up here: The first patch changes the prototype of a couple of functions used in Alexandre's "add Ethernet glue logic for stm32 chip" patch [1] and will cause build failures for dwmac-stm32.c if not fixed up! If Alexandre's patch set is applied first I will gladly rebase my patch set to account for his driver as well. [1] https://patchwork.ozlabs.org/patch/614405/ ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0f400a87dc59be9b485ffa820ca9ed904cacfcbb Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 1 22:58:23 2016 +0200 stmmac: dwmac-socfpga: kill init() and rename setup() to set_phy_mode() Remove old init callback which now contains only a call to socfpga_dwmac_setup(). Also rename socfpga_dwmac_setup() to indicate what the function really does. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) commit 537372472415b7b75856561d23891a0bf3477ea4 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 1 22:58:22 2016 +0200 stmmac: dwmac-socfpga: call phy_resume() only in resume callback Calling phy_resume() should only be need during driver resume to workaround a hardware errata. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 50 ++++++++-------------- 1 file changed, 19 insertions(+), 31 deletions(-) commit 70cb136f7730830aa1134925a941e3ad96e3a846 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 1 22:58:21 2016 +0200 stmmac: dwmac-socfpga: keep a copy of stmmac_rst in driver priv data The dwmac-socfpga driver needs to control the reset usually managed by the core driver to set the PHY mode. Take a copy of the reset handle from core priv data so it can be used by the driver later. This also allow us to move reset handling into socfpga_dwmac_setup() where the code that needs it is located. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 33 ++++++++++++++-------- 1 file changed, 22 insertions(+), 11 deletions(-) commit 56868deece922283b367d08f1d647726d5b307d9 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 1 22:58:20 2016 +0200 stmmac: dwmac-socfpga: add PM ops and resume function Implement the needed PM callbacks in the driver instead of relying on the init/exit hooks in stmmac_platform. This gives the driver more flexibility in how the code is organized. Eventually the init/exit callbacks will be deprecated in favor of the standard PM callbacks and driver remove function. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit f4e7bd81b1630018952187e5bd731755a6536a61 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun May 1 22:58:19 2016 +0200 stmmac: let remove/resume/suspend functions take device pointer Change stmmac_remove/resume/suspend to take a device pointer so they can be used directly by drivers that doesn't need to perform anything device specific. This lets us remove the PCI pm functions and later simplifiy the platform drivers. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac.h | 6 +++--- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 15 ++++++++------ drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c | 24 ++-------------------- .../net/ethernet/stmicro/stmmac/stmmac_platform.c | 6 +++--- 4 files changed, 17 insertions(+), 34 deletions(-) commit 64ae74455371a40bc9f9c8325eb4c37f2978c95f Author: Sven Eckelmann <sven@narfation.org> Date: Mon Feb 22 22:56:34 2016 +0100 batman-adv: Split batadv_iv_ogm_orig_del_if function batadv_iv_ogm_orig_del_if handles two different buffers bcast_own and bcast_own_sum which should be resized. The error handling two for allocating these buffers causes the complexity of this function. This can be avoided completely when the function is split into a main function handling the locking, freeing and call of the subfunctions. The subfunction can then independently handle the resize of the buffers. This also allows to easily reuse the old buffer (which always is larger) in case a smaller buffer could not be allocated without increasing the code complexity. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_iv_ogm.c | 115 +++++++++++++++++++++++++++++--------------- 1 file changed, 76 insertions(+), 39 deletions(-) commit 86de37c1fb16d71402773a3da05abe6cc7346f94 Author: Simon Wunderlich <simon@open-mesh.com> Date: Mon Feb 1 15:21:38 2016 +0100 batman-adv: Merge batadv_v_ogm_orig_update into batadv_v_ogm_route_update Since batadv_v_ogm_orig_update() was only called from one place and the calling function became very short, merge these two functions together. This should also reflect the protocol description of B.A.T.M.A.N. V better. Signed-off-by: Simon Wunderlich <simon@open-mesh.com> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v_ogm.c | 117 ++++++++++++++++++--------------------------- 1 file changed, 46 insertions(+), 71 deletions(-) commit efcc9d3069c982786f380bca8480a1aa2fd2721d Author: Simon Wunderlich <simon@open-mesh.com> Date: Mon Feb 1 15:21:37 2016 +0100 batman-adv: move and restructure batadv_v_ogm_forward To match our code better to the protocol description of B.A.T.M.A.N. V, move batadv_v_ogm_forward() out into batadv_v_ogm_process_per_outif() and move all checks directly deciding whether the OGM should be forwarded into batadv_v_ogm_forward(). Signed-off-by: Simon Wunderlich <simon@open-mesh.com> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bat_v_ogm.c | 110 ++++++++++++++++++++++++++------------------- 1 file changed, 63 insertions(+), 47 deletions(-) commit 121bdca0d476c1018fa4b3c06ac008b7979acbd3 Author: Simon Wunderlich <simon.wunderlich@open-mesh.com> Date: Fri Mar 11 14:01:11 2016 +0100 batman-adv: fix debuginfo macro style issue Structure initialization within the macros should follow the general coding style used in the kernel: put the initialization of the first variable and the closing brace on a separate line. Reported-by: Antonio Quartulli <a@unstable.cc> Signed-off-by: Simon Wunderlich <simon.wunderlich@open-mesh.com> [sven@narfation.org: fix conflicts with current version] Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/debugfs.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit 6fc77a548679c6736909da0636da0cf4d759ed64 Author: Sven Eckelmann <sven@narfation.org> Date: Sat Mar 5 15:56:01 2016 +0100 batman-adv: Fix function names on new line starting with '*' Some really long function names in batman-adv require a newline between return type and the function name. This has lead to some lines starting with *batadv_... This * belongs to the return type and thus should be on the same line as the return type. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bridge_loop_avoidance.c | 6 +++--- net/batman-adv/main.c | 8 ++++---- net/batman-adv/network-coding.c | 18 +++++++++--------- 3 files changed, 16 insertions(+), 16 deletions(-) commit f298cb94d6cb9c103c377a370d78dc51689819f6 Author: Sven Eckelmann <sven@narfation.org> Date: Sun Feb 28 11:38:50 2016 +0100 batman-adv: Add kernel-doc for batadv_interface_rx Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/soft-interface.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 98a5b1d88c2b03be3ce8c0c0034523779dcc384f Author: Sven Eckelmann <sven@narfation.org> Date: Mon Feb 22 18:55:32 2016 +0100 batman-adv: Fix kerneldoc for batadv_compare_claim Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bridge_loop_avoidance.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d3abce780dbb731ddb918bf3ba8bb60681f19e42 Author: Sven Eckelmann <sven@narfation.org> Date: Wed Mar 9 22:22:51 2016 +0100 batman-adv: Fix checkpatch warning about 'unsigned' type checkpatch.pl warns about the use of 'unsigned' as a short form for 'unsigned int'. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/fragmentation.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 6d030de89f1beb85ce8e6b71f4fbfef8cabe37cf Author: Antonio Quartulli <a@unstable.cc> Date: Fri Mar 11 16:36:19 2016 +0100 batman-adv: fix wrong names in kerneldoc Signed-off-by: Antonio Quartulli <a@unstable.cc> [sven@narfation.org: Fix additional names] Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> net/batman-adv/bridge_loop_avoidance.c | 2 +- net/batman-adv/distributed-arp-table.c | 2 +- net/batman-adv/icmp_socket.c | 2 +- net/batman-adv/main.h | 3 ++- net/batman-adv/multicast.c | 11 ++++++----- net/batman-adv/originator.c | 2 +- net/batman-adv/packet.h | 2 +- net/batman-adv/soft-interface.c | 2 +- 8 files changed, 14 insertions(+), 12 deletions(-) commit 4ba4bc0f74d32b201cecc33e153a4a18d5c5db1d Author: Geliang Tang <geliangtang@163.com> Date: Mon Dec 28 23:43:37 2015 +0800 batman-adv: use to_delayed_work Use to_delayed_work() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> Reviewed-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/bridge_loop_avoidance.c | 2 +- net/batman-adv/distributed-arp-table.c | 2 +- net/batman-adv/network-coding.c | 2 +- net/batman-adv/originator.c | 2 +- net/batman-adv/send.c | 4 ++-- net/batman-adv/translation-table.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) commit fb1f23eab6a9cd7d94d47b66f56df77b370a3954 Author: Geliang Tang <geliangtang@163.com> Date: Fri Dec 18 23:33:31 2015 +0800 batman-adv: use list_for_each_entry_safe Use list_for_each_entry_safe() instead of list_for_each_safe() to simplify the code. Signed-off-by: Geliang Tang <geliangtang@163.com> Acked-by: Antonio Quartulli <a@unstable.cc> Reviewed-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/icmp_socket.c | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) commit 925a6f379036c58cd62a1492f83263ebe021a49d Author: Antonio Quartulli <a@unstable.cc> Date: Sat Mar 12 10:30:18 2016 +0100 batman-adv: use static string for table headers Use a static string when showing table headers rather then a nonsense parametric one with fixed arguments. It is easier to grep and it does not need to be recomputed at runtime each time. Reported-by: Joe Perches <joe@perches.com> Signed-off-by: Antonio Quartulli <a@unstable.cc> [sven@narfation.org: fix conflicts with current version] Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> net/batman-adv/bat_iv_ogm.c | 8 +++----- net/batman-adv/bat_v.c | 9 ++++----- net/batman-adv/bridge_loop_avoidance.c | 7 +++---- net/batman-adv/distributed-arp-table.c | 4 ++-- net/batman-adv/translation-table.c | 9 ++++----- 5 files changed, 16 insertions(+), 21 deletions(-) commit 565489df244626c7c1a07a5e093d7f2b20b550cc Author: Simon Wunderlich <sw@simonwunderlich.de> Date: Fri Apr 15 12:14:39 2016 +0200 batman-adv: Start new development cycle Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de> Signed-off-by: Antonio Quartulli <a@unstable.cc> net/batman-adv/main.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 286ddfb03dc04f0afa254b51c30d5a7392dc920f Author: Sven Eckelmann <sven@narfation.org> Date: Fri Apr 1 15:17:36 2016 +0200 MAINTAINERS: Add BATMAN ADVANCED documentation files The sysfs ABI documentation files and the batman-adv.txt are maintained by the BATMAN ADVANCED maintainers and patches for them should therefore be sent to them. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Antonio Quartulli <a@unstable.cc> MAINTAINERS | 3 +++ 1 file changed, 3 insertions(+) commit 1584f41f66ff32db40be3814f16ab305128b7194 Author: Sven Eckelmann <sven@narfation.org> Date: Fri Apr 1 15:17:35 2016 +0200 MAINTAINERS: Mark BATMAN ADVANCED mailing list as moderated The mailing list of b.a.t.m.a.n@lists.open-mesh.org is moderated for non-subscribers and non-whitelisted addresses. Such mails will be delayed but the sender will not be informed about the moderation. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Antonio Quartulli <a@unstable.cc> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3f8ab270855b0b461995da5dc48dce9461c85d94 Author: Chao Yu <yuchao0@huawei.com> Date: Fri Apr 29 20:13:37 2016 +0800 f2fs: factor out fsync inode entry operations Factor out fsync inode entry operations into {add,del}_fsync_inode. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/recovery.c | 59 +++++++++++++++++++++++++++++++++++------------------- 1 file changed, 38 insertions(+), 21 deletions(-) commit c81ced05b2c7fc3c1d6db753a55b55733ffb1524 Author: Chao Yu <yuchao0@huawei.com> Date: Fri Apr 29 20:13:36 2016 +0800 f2fs: fix to clear page private flag Commit 28bc106b2346 ("f2fs: support revoking atomic written pages") forgot to clear page private flag correctly, fix it. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/segment.c | 1 + 1 file changed, 1 insertion(+) commit 23dc974eed576b2464b222a892272073adf6a92c Author: Chao Yu <yuchao0@huawei.com> Date: Fri Apr 29 20:09:15 2016 +0800 f2fs: fix to clear private data in page Private data in page should be removed during ->releasepage or ->invalidatepage, otherwise garbage data would be remained in that page. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 2 ++ 1 file changed, 2 insertions(+) commit 3ca3712a42f9e632eb41da94ca4eab4f1fb06fcb Author: Peng Fan <van.freenix@gmail.com> Date: Tue May 3 21:50:30 2016 +0800 iommu/arm-smmu: Clear cache lock bit of ACR According MMU-500r2 TRM, section 3.7.1 Auxiliary Control registers, You can modify ACTLR only when the ACR.CACHE_LOCK bit is 0. So before clearing ARM_MMU500_ACTLR_CPRE of each context bank, need clear CACHE_LOCK bit of ACR register first. Since CACHE_LOCK bit is only present in MMU-500r2 onwards, need to check the major number of IDR7. Reviewed-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Peng Fan <van.freenix@gmail.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) commit b7862e3559f9ab4aaa258dcb846986601a7ca0b8 Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 18:13:03 2016 +0100 iommu/arm-smmu: Support SMMUv1 64KB supplement The 64KB Translation Granule Supplement to the SMMUv1 architecture allows an SMMUv1 implementation to support 64KB pages for stage 2 translations, using a constrained VMSAv8 descriptor format limited to 40-bit addresses. Now that we can freely mix and match context formats, we can actually handle having 4KB pages via an AArch32 context but 64KB pages via an AArch64 context, so plumb it in. It is assumed that any implementations will have hardware capabilities matching the format constraints, thus obviating the need for excessive sanity-checking; this is the case for MMU-401, the only ARM Ltd. implementation. CC: Eric Auger <eric.auger@linaro.org> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit 7602b8710645da48b2937f05fa41d627a0e73dad Author: Robin Murphy <robin.murphy@arm.com> Date: Thu Apr 28 17:12:09 2016 +0100 iommu/arm-smmu: Decouple context format from kernel config The way the driver currently forces an AArch32 or AArch64 context format based on the kernel config and SMMU architecture version is suboptimal, in that it makes it very hard to support oddball mix-and-match cases like the SMMUv1 64KB supplement, or situations where the reduced table depth of an AArch32 short descriptor context may be desirable under an AArch64 kernel. It also only happens to work on current implementations which do support all the relevant formats. Introduce an explicit notion of context format, so we can manage that independently and get rid of the inflexible #ifdeffery. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 94 ++++++++++++++++++++++++++++++++++++------------ 1 file changed, 72 insertions(+), 22 deletions(-) commit f9a05f05b12a42f2c52f3d3b8cc71fe2a6e60bce Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 18:13:01 2016 +0100 iommu/arm-smmu: Tidy up 64-bit/atomic I/O accesses With {read,write}q_relaxed now able to fall back to the common nonatomic-hi-lo helper, make use of that so that we don't have to open-code our own. In the process, also convert the other remaining split accesses, and repurpose the custom accessor to smooth out the couple of troublesome instances where we really want to avoid nonatomic writes (and a 64-bit access is unnecessary in the 32-bit context formats we would use on a 32-bit CPU). This paves the way for getting rid of some of the assumptions currently baked into the driver which make it really awkward to use 32-bit context formats with SMMUv2 under a 64-bit kernel. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 48 +++++++++++++++++++----------------------------- 1 file changed, 19 insertions(+), 29 deletions(-) commit e511267bc25e18926826e7cccdf7872bcbb4776a Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 26 11:38:20 2016 +0100 io-64-nonatomic: Add relaxed accessor variants Whilst commit 9439eb3ab9d1 ("asm-generic: io: implement relaxed accessor macros as conditional wrappers") makes the *_relaxed forms of I/O accessors universally available to drivers, in cases where writeq() is implemented via the io-64-nonatomic helpers, writeq_relaxed() will end up falling back to writel() regardless of whether writel_relaxed() is available (identically for s/write/read/). Add corresponding relaxed forms of the nonatomic helpers to delegate to the equivalent 32-bit accessors as appropriate. We also need to fix io.h to avoid defining default relaxed variants if the basic accessors themselves don't exist. CC: Christoph Hellwig <hch@lst.de> CC: Darren Hart <dvhart@linux.intel.com> CC: Hitoshi Mitake <mitake.hitoshi@lab.ntt.co.jp> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> include/asm-generic/io.h | 4 ++-- include/linux/io-64-nonatomic-hi-lo.h | 25 +++++++++++++++++++++++++ include/linux/io-64-nonatomic-lo-hi.h | 25 +++++++++++++++++++++++++ 3 files changed, 52 insertions(+), 2 deletions(-) commit f0cfffc48cac516e37711786227f6808491913a5 Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 18:12:59 2016 +0100 iommu/arm-smmu: Work around MMU-500 prefetch errata MMU-500 erratum #841119 is tickled by a particular set of circumstances interacting with the next-page prefetcher. Since said prefetcher is quite dumb and actually detrimental to performance in some cases (by causing unwanted TLB evictions for non-sequential access patterns), we lose very little by turning it off, and what we gain is a guarantee that the erratum is never hit. As a bonus, the same workaround will also prevent erratum #826419 once v7 short descriptor support is implemented. CC: Catalin Marinas <catalin.marinas@arm.com> CC: Will Deacon <will.deacon@arm.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/arm64/silicon-errata.txt | 1 + drivers/iommu/arm-smmu.c | 16 +++++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) commit e086d912d4d78781652669618e7fb01a4d466703 Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 18:12:58 2016 +0100 iommu/arm-smmu: Convert ThunderX workaround to new method With a framework for implementation-specific funtionality in place, the currently-FDT-dependent ThunderX workaround gets to be the first user. Acked-by: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) commit 67b65a3fb8e658d00ad1bb06e341f09b1f93a25c Author: Robin Murphy <robin.murphy@arm.com> Date: Wed Apr 13 18:12:57 2016 +0100 iommu/arm-smmu: Differentiate specific implementations As the inevitable reality of implementation-specific errata workarounds begin to accrue alongside our integration quirk handling, it's about time the driver had a decent way of keeping track. Extend the per-SMMU data so we can identify specific implementations in an efficient and firmware-agnostic manner. Acked-by: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) commit 1bd37a6835bef0ecd2138cb42f9088fd890f9939 Author: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> Date: Fri Mar 4 13:56:09 2016 -0800 iommu/arm-smmu: Workaround for ThunderX erratum #27704 Due to erratum #27704, the CN88xx SMMUv2 implementation supports only shared ASID and VMID numberspaces. This patch ensures that ASID and VMIDs are unique across all SMMU instances on affected Cavium systems. Signed-off-by: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> Signed-off-by: Akula Geethasowjanya <Geethasowjanya.Akula@caviumnetworks.com> [will: commit message, comments and formatting] Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/arm64/silicon-errata.txt | 1 + .../devicetree/bindings/iommu/arm,smmu.txt | 1 + drivers/iommu/arm-smmu.c | 39 ++++++++++++++++------ 3 files changed, 30 insertions(+), 11 deletions(-) commit 4e3e9b6997b24383264031198bf8905b3746221e Author: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> Date: Tue Feb 23 10:19:00 2016 -0800 iommu/arm-smmu: Add support for 16 bit VMID This patch adds support for 16-bit VMIDs on implementations of SMMUv2 that support it. Signed-off-by: Tirumalesh Chalamarla <tchalamarla@caviumnetworks.com> [will: commit messsage and comments] Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/iommu/arm-smmu.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) commit e03179fe78d5b39dbf3e8b0b50f7c406514b15c7 Author: Philippe Reynes <tremyfr@gmail.com> Date: Sun May 1 17:08:11 2016 +0200 net: ethernet: fec_mpc52xx: move to new ethtool api {get|set}_link_ksettings The ethtool api {get|set}_settings is deprecated. We move the fec_mpc52xx driver to new api {get|set}_link_ksettings. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_mpc52xx.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit a10cdae0a6ff400c5724967753ec02ef6291ffad Author: Philippe Reynes <tremyfr@gmail.com> Date: Sun May 1 17:08:10 2016 +0200 net: ethernet: fs-enet: move to new ethtool api {get|set}_link_ksettings The ethtool api {get|set}_settings is deprecated. We move the fs-enet driver to new api {get|set}_link_ksettings. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit 5e74bf2d9529e4a272f745d5f3e8f88113a987a0 Author: Philippe Reynes <tremyfr@gmail.com> Date: Sun May 1 17:08:09 2016 +0200 net: ethernet: ucc: move to new ethtool api {get|set}_link_ksettings The ethtool api {get|set}_settings is deprecated. We move the ucc driver to new api {get|set}_link_ksettings. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/ucc_geth_ethtool.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) commit 0d1bcdc74fb9cefcdc74e9d4579e63bd0fa5dc9a Author: Philippe Reynes <tremyfr@gmail.com> Date: Sun May 1 17:08:08 2016 +0200 net: ethernet: gianfar: move to new ethtool api {get|set}_link_ksettings The ethtool api {get|set}_settings is deprecated. We move the gianfar driver to new api {get|set}_link_ksettings. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/gianfar_ethtool.c | 25 ++++++++---------------- 1 file changed, 8 insertions(+), 17 deletions(-) commit 56130915bbe31656c80f7493d28536693f8de0e2 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sun May 1 14:49:15 2016 +0200 VSOCK: constify vsock_transport structure The vsock_transport structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: David S. Miller <davem@davemloft.net> net/vmw_vsock/vmci_transport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b555a3d1e91cfa75eb37680c0c86a32d18215729 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sun May 1 14:36:28 2016 +0200 drivers: net: xgene: constify xgene_cle_ops structure The xgene_cle_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Iyappan Subramanian <isubramanian@apm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/apm/xgene/xgene_enet_cle.c | 2 +- drivers/net/ethernet/apm/xgene/xgene_enet_cle.h | 2 +- drivers/net/ethernet/apm/xgene/xgene_enet_main.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit d9322d226f91ad95825ab68f3e5cfeda7b9c4553 Merge: 58f8b09 26e5157 c20e128 2ffa9a5 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Tue May 3 11:49:21 2016 -0500 Merge branches 'pci/dpc', 'pci/resource' and 'pci/thunderbolt' into next * pci/dpc: PCI: Add Downstream Port Containment driver PCI: Add Downstream Port Containment portdrv service type PCI: Widen portdrv service type from 4 bits to 8 bits * pci/resource: alpha/PCI: Call iomem_is_exclusive() for IORESOURCE_MEM, but not IORESOURCE_IO PCI: Supply CPU physical address (not bus address) to iomem_is_exclusive() * pci/thunderbolt: thunderbolt: Fix double free of drom buffer commit 9d18562a227874289fda8ca5d117d8f503f1dcca Author: Eric Dumazet <edumazet@google.com> Date: Sun May 1 16:47:26 2016 -0700 fq_codel: add batch ability to fq_codel_drop() In presence of inelastic flows and stress, we can call fq_codel_drop() for every packet entering fq_codel qdisc. fq_codel_drop() is quite expensive, as it does a linear scan of 4 KB of memory to find a fat flow. Once found, it drops the oldest packet of this flow. Instead of dropping a single packet, try to drop 50% of the backlog of this fat flow, with a configurable limit of 64 packets per round. TCA_FQ_CODEL_DROP_BATCH_SIZE is the new attribute to make this limit configurable. With this strategy the 4 KB search is amortized to a single cache line per drop [1], so fq_codel_drop() no longer appears at the top of kernel profile in presence of few inelastic flows. [1] Assuming a 64byte cache line, and 1024 buckets Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Dave Taht <dave.taht@gmail.com> Cc: Jonathan Morton <chromatix99@gmail.com> Acked-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Dave Taht Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/pkt_sched.h | 1 + net/sched/sch_fq_codel.c | 64 +++++++++++++++++++++++++++++------------- 2 files changed, 46 insertions(+), 19 deletions(-) commit 094e43d50d7e421e9036d72a5a1d93c250cdbf0a Author: Kazuya Mizuguchi <kazuya.mizuguchi.ks@renesas.com> Date: Mon May 2 00:19:51 2016 +0900 ravb: Remove rx buffer ALIGN Aligning the reception data size is not required. Signed-off-by: Kazuya Mizuguchi <kazuya.mizuguchi.ks@renesas.com> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com> Tested-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/ravb_main.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 58f8b094e96f12e899bf767fc658c165908065d4 Merge: 7f76854 1c52a51 a5cb903 deb22e5 b410f3b 1e9f8dc dfc6535 76ba8c1 93bf907 88a97da Author: Bjorn Helgaas <bhelgaas@google.com> Date: Tue May 3 11:42:30 2016 -0500 Merge branches 'pci/host-armada', 'pci/host-designware', 'pci/host-hv', 'pci/host-imx6', 'pci/host-keystone', 'pci/host-mvebu', 'pci/host-rcar', 'pci/host-thunder' and 'pci/host-vmd' into next * pci/host-armada: PCI: armada: Add driver for Marvell Armada 7K/8K PCIe controller dt-bindings: pci: add DT binding for Marvell Armada 7K/8K PCIe controller * pci/host-designware: PCI: designware: Remove incorrect RC memory base/limit configuration PCI: designware: Move Root Complex setup code to dw_pcie_setup_rc() * pci/host-hv: PCI: hv: Report resources release after stopping the bus * pci/host-imx6: ARM: dts: imx6qp: Specify imx6qp version of PCIe core PCI: imx6: Implement reset sequence for i.MX6+ PCI: imx6: Use enum instead of bool for variant indicator PCI: imx6: Add DT property for link gen, default to Gen1 PCI: imx6: Add reset-gpio-active-high boolean property to DT ARM: dts: imx6: Fix PCIe reset GPIO polarity on Toradex Apalis Ixora PCI: imx6: Add initial imx6sx support PCI: imx6: Factor out ref clock enable Revert "PCI: imx6: Add support for active-low reset GPIO" * pci/host-keystone: PCI: keystone: Remove unnecessary goto statement PCI: keystone: Add error IRQ handler * pci/host-mvebu: PCI: mvebu: Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS for mvebu_pcie_pm_ops PCI: mvebu: Constify mvebu_pcie_pm_ops structure * pci/host-rcar: PCI: rcar: Select PCI_MSI_IRQ_DOMAIN * pci/host-thunder: PCI: thunder: Don't clobber read-only bits in bridge config registers * pci/host-vmd: PCI: Remove return values from pcie_port_platform_notify() and relatives PCI/ACPI: Allow all PCIe services on non-ACPI host bridges commit 8f658815da156a9239b98b34e5ba1d3db71a2f6e Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue May 3 10:42:58 2016 +0300 ASoC: hdac_hdmi: Potential NULL deref in hdac_hdmi_get_spk_alloc() We intended || here instead of &&. The original code potentially leads to a NULL dereference. Fixes: 2889099eb8cd ('ASoC: hdac_hdmi: Register chmap controls and ops') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewd-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Acked-by: Vinod Koul <vinod.koul@intel.com> Tested-by: Sachin Mokashi <sachinx.mokashi@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8636d45249ce1d121a4c56e9d970087d7ab267b3 Author: Eric Anholt <eric@anholt.net> Date: Tue May 3 14:54:19 2016 +0100 MAINTAINERS: Add myself for the new VC4 (RPi GPU) graphics driver. Signed-off-by: Eric Anholt <eric@anholt.net> [Emil Velikov: drop wildcard, add UAPI and Documentation files] Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462283659-1314-1-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 8 ++++++++ 1 file changed, 8 insertions(+) commit 399516ab0fee5c0f5fc4e246879a283d9c26f689 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:04:02 2016 +0100 MAINTAINERS: Add a bunch of legacy (UMS) DRM drivers Pretty much all of these hasn't seen any action singe 2008 at the very least. Barring the occasional buildfix and DRM-wide refactoring of course. Note: some distributions have stopped shipping their userspace counterparts for a while. Although some still do. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> MAINTAINERS | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit c842b69345ae860735e2cc5c64cb2d4298c1fc6f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:04:01 2016 +0100 MAINTAINERS: Add a few DRM drivers by Dave Airlie Almost exclusively done by Dave Airlie. Explicitly list him as a maintainer and classify them as "Odd Fixes" as I doubt he's got much time for them these days. Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-14-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 2392ccd4f8520638c9e1b0e06d12fb2f6d343593 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:57 2016 +0100 MAINTAINERS: List the correct git repo for the Renesas DRM drivers Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: dri-devel@lists.freedesktop.org Cc: linux-renesas-soc@vger.kernel.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-10-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 33be436da13f9e7a9c4736b8038b443c1adae5fe Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:56 2016 +0100 MAINTAINERS: Update the files list for the Renesas DRM drivers Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: dri-devel@lists.freedesktop.org Cc: linux-renesas-soc@vger.kernel.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-9-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 4418833ecefa564cafe841a62c95f13543c7404f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:55 2016 +0100 MAINTAINERS: Update the files list for the Armada DRM driver Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-8-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 2 ++ 1 file changed, 2 insertions(+) commit f253f7eb8bf8eff6fde00ea31b21de0627a1dc9a Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:53 2016 +0100 MAINTAINERS: Update the files list for the Rockchip DRM driver The location listed is a folder - swap the wildcard with '/' Cc: Mark Yao <mark.yao@rock-chips.com> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-6-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8fb9b15be3a3d2ce8ce43c4f3f9391166692e454 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:51 2016 +0100 MAINTAINERS: Update the files list for the Exynos DRM driver Cc: Inki Dae <inki.dae@samsung.com> Cc: Joonyoung Shim <jy0922.shim@samsung.com> Cc: Seung-Woo Kim <sw0312.kim@samsung.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-4-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c42917021ba84e07c13c1c2e42221c4f77a167e3 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Tue May 3 00:15:39 2016 +0100 MAINTAINERS: Add maintainer entry for the VMWGFX DRM driver Thomas is one of the original authors of the driver, with recent contributions from Sinclair and Brian. v2: Add Sinclair as maintainer. Add Sinclair+Thomas's tree, use Supported as status. Cc: Sinclair Yeh <syeh@vmware.com> Cc: Thomas Hellstrom <thellstrom@vmware.com> Cc: Brian Paul <brianp@vmware.com> Cc: "VMware Graphics" <linux-graphics-maintainer@vmware.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Sinclair Yeh <syeh@vmware.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462230939-26389-1-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 0634645173754c8d9b49ff133085eb2edd7e202f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Tue May 3 00:14:48 2016 +0100 MAINTAINERS: Add maintainer entry for the MSM DRM driver Rob and Archit are the main developers behind the driver. v2: Removing Archit for now, correcting the status and adding linux-arm-msm@ mailing list. Cc: Rob Clark <robdclark@gmail.com> Cc: Archit Taneja <architt@codeaurora.org> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462230888-26319-1-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 11 +++++++++++ 1 file changed, 11 insertions(+) commit fad89bb310f76768918e657aaa3a4c5e4e83634f Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:58 2016 +0100 MAINTAINERS: Add maintainer entry for the Nouveau DRM driver Ben has been the maintainer of the driver even before it got included in the kernel. Cc: Ben Skeggs <bskeggs@redhat.com> Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-11-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+) commit 8a9257a0078c070f23065968f9b12af46921052e Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:54 2016 +0100 MAINTAINERS: Update the files list for the Etnaviv DRM driver Cc: Lucas Stach <l.stach@pengutronix.de> Cc: Russell King <linux+etnaviv@arm.linux.org.uk> Cc: Christian Gmeiner <christian.gmeiner@gmail.com> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-7-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit baceac3ad93a4182f0397bcc97e13ba8fd4be6e4 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:50 2016 +0100 MAINTAINERS: Remove unneded wildcard for the i915 DRM driver There is no other file but the UAPI header, thus we can drop the wildcard. Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Jani Nikula <jani.nikula@linux.intel.com> Cc: intel-gfx@lists.freedesktop.org Cc: dri-devel@lists.freedesktop.org Acked-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-3-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 26e515713342b6f7c553aa3c66b21c6ab7cf82af Author: Keith Busch <keith.busch@intel.com> Date: Thu Apr 28 16:24:48 2016 -0600 PCI: Add Downstream Port Containment driver Add driver for the PCI Express Downstream Port Containment extended capability. DPC is an optional capability to contain uncorrectable errors below a port. For more information on DPC, please see PCI Express Base Specification Revision 4, section 7.31, or view the PCI-SIG DPC ECN here: https://pcisig.com/sites/default/files/specification_documents/ECN_DPC_2012-02-09_finalized.pdf When a DPC event is triggered, the hardware disables downstream links, so the DPC driver schedules removal for all devices below this port. This may happen concurrently with a PCIe hotplug driver if enabled. When all downstream devices are removed and the link state transitions to disabled, the DPC driver clears the DPC status and interrupt bits so the link may retrain for a newly connected device. [bhelgaas: clear (not set) DPC_CTL bits on remove, whitespace cleanup] Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Cc: Lukas Wunner <lukas@wunner.de> drivers/pci/pcie/Kconfig | 14 ++++ drivers/pci/pcie/Makefile | 2 + drivers/pci/pcie/pcie-dpc.c | 163 ++++++++++++++++++++++++++++++++++++++++++ include/uapi/linux/pci_regs.h | 17 +++++ 4 files changed, 196 insertions(+) commit 10126ac14d36e74b2705802dc915b0b18463a51f Author: Keith Busch <keith.busch@intel.com> Date: Mon May 2 15:10:31 2016 -0500 PCI: Add Downstream Port Containment portdrv service type Add the Downstream Port Containment (PCIE_PORT_SERVICE_DPC) portdrv service type, available if the device has the DPC extended capability. [bhelgaas: split to separate patch, changelog] Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pcie/portdrv.h | 2 +- drivers/pci/pcie/portdrv_acpi.c | 2 +- drivers/pci/pcie/portdrv_core.c | 4 +++- include/linux/pcieport_if.h | 2 ++ include/uapi/linux/pci_regs.h | 3 ++- 5 files changed, 9 insertions(+), 4 deletions(-) commit a21f2a3ec62abe2e06500d6550659a0ff5624fbb Author: Michael Callahan <michaelcallahan@fb.com> Date: Tue May 3 11:12:49 2016 -0400 block: Minor blk_account_io_start usage cleanup blk_account_io_start does not need to be wrapped with blk_do_io_stat ais it already checks for that condition. Signed-off-by: Michael Callahan <michaelcallahan@fb.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 35f3fae17849793c7c031b00ec972f3d9057744b Author: Wanpeng Li <wanpeng.li@hotmail.com> Date: Tue May 3 11:43:10 2016 +0800 kvm: robustify steal time record Guest should only trust data to be valid when version haven't changed before and after reads of steal time. Besides not changing, it has to be an even number. Hypervisor may write an odd number to version field to indicate that an update is in progress. kvm_steal_clock() in guest has already done the read side, make write side in hypervisor more robust by following the above rule. Reviewed-by: Wincy Van <fanwenyi0529@gmail.com> Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/x86.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit c6e360a0d9d282e9c8688dcdabdc3669912b66ef Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue May 3 08:06:06 2016 -0700 Revert "base: dd: don't remove driver_data in -EPROBE_DEFER case" This reverts commit ded9db380d34344ee5263002570b9b8b705f7830. Thierry Reding writes: This causes a boot regression on at least one board, caused by one of the drivers looking at driver data to check whether or not the driver has properly loaded. If the code encounters a non-NULL pointer it tries to dereference it, but because it's already been freed there is no memory backing it and things crash. I don't think keeping stale pointers around is a good idea. The whole point of setting this to NULL in the core is so that probe failures result in the same starting conditions no matter what. Can we please get this reverted? Reported-by: Thierry Reding <thierry.reding@gmail.com> Cc: Yi Zhang <yizhang_hust@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/base/dd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 6d81417da8720b393f670de9cce03a3642ea9a30 Author: Keith Busch <keith.busch@intel.com> Date: Tue May 3 09:58:11 2016 -0500 PCI: Widen portdrv service type from 4 bits to 8 bits The names of port service devices previously used one nibble to encode the port type and another nibble to encode the service type. We're about to add a fifth service type, so change device names to use one *byte* to encode the service type. For example, a hotplug port service on a downstream bridge was previously called "pcie24" and is now called "pcie204". The "2" encodes the device type (PCI_EXP_TYPE_DOWNSTREAM - 4), and the "4" (now "04") encodes the service (PCIE_PORT_SERVICE_HP). Based on Lukas Wunner's patch: https://github.com/l1k/linux/commit/b688d6e4873ab082e5916b1a993bc1d38c6f4178 [bhelgaas: split to separate patch, expand changelog] Based-on-patch-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pcie/portdrv.h | 2 +- drivers/pci/pcie/portdrv_core.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit bc0868c62bb13834b20a864f684cced1f84a2412 Merge: fd786fb 8c12ad8 Author: Mark Brown <broonie@kernel.org> Date: Tue May 3 15:09:56 2016 +0100 Merge branch 'for-4.7/pwm-regulator' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm into regulator-pwm commit 9a6462763b170bd22be707d5d9e2b8ba8cc4028e Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Mon May 2 10:32:24 2016 +0200 m68k/mvme16x: Include generic <linux/rtc.h> The MVME16x RTC driver doesn't use any MC146818-specific definitions, hence include the generic <linux/rtc.h> instead of <linux/mc146818rtc.h>. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> arch/m68k/mvme16x/rtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8c66854b688aa077d127a39a64c71db42d0cf3dd Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Mon May 2 10:31:19 2016 +0200 m68k/bvme6000: Include generic <linux/rtc.h> The BVME6000 RTC driver doesn't use any MC146818-specific definitions, hence include the generic <linux/rtc.h> instead of <linux/mc146818rtc.h>. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> arch/m68k/bvme6000/rtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 194521f72380d0e78caa71013e9e7de1703d8c85 Author: Marek Vasut <marex@denx.de> Date: Wed Apr 20 00:36:01 2016 +0200 ARM: mx5: dts: Enable USB OTG on M53EVK Add USB OTG support to M53EVK instead of just USB gadget. Signed-off-by: Marek Vasut <marex@denx.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx53-m53evk.dts | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) commit 2ead04d9d69ebded61da063cb5a8ade72da6c8f5 Author: Marcel Ziswiler <marcel.ziswiler@toradex.com> Date: Fri Apr 29 22:40:19 2016 +0200 ARM: imx_v6_v7_defconfig: add CONFIG_MICREL_PHY The driver for Micrel PHYs is required for the Apalis iMX6 module plugged into a Ixora carrier board featuring an on-module Micrel KSZ9031 Gigabit PHY. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/imx_v6_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 154e80e21b764117ea19de74bc97863efabe192e Author: Marcel Ziswiler <marcel.ziswiler@toradex.com> Date: Fri Apr 29 22:40:18 2016 +0200 ARM: imx_v6_v7_defconfig: add CONFIG_I2C_GPIO The GPIO-based bitbanging I2C driver is required to make HDMI work on the Apalis iMX6 module plugged into a Ixora carrier board featuring a DDC channel to read a screen's EDID being hooked up to regular GPIOs. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/imx_v6_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit bf3251e112a0139c8dec796c9f12f2e8f01a73ca Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon May 2 20:56:26 2016 -0300 ARM: dts: imx6ul-14x14-evk: Add audio support imx6ul-14x14-evk has a wm8960 codec connected via SAI2 port. Add support for it. Thanks to Petr Kulhavy <brain@jikos.cz> for the hint on initializing the PLL4 frequency to get a correct MCLK. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6ul-14x14-evk.dts | 74 ++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) commit c77ebb4534aa8f1d74d62c4604cc8ac1bf40f5ec Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Fri Apr 29 19:39:45 2016 -0300 ARM: dts: imx6qdl: Remove unneeded unit-addresses The following build warnings are seen when building with 'W=1' option: Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-1p1@110 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-3p0@120 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-2p5@130 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-vddcore@140 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-vddpu@140 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@02000000/anatop@020c8000/regulator-vddsoc@140 has a unit name, but no reg property Fix them by removing the unneeded unit-addresses. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl.dtsi | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 7f4eaa89fb20d9fd178d2f9db5aa2df5af358dcd Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue May 3 11:12:31 2016 +0200 drm/atomic: Add WARN_ON when state->acquire_ctx is not set. When I was writing an atomic wrapper for rmfb, I ran into the following backtrace from lockdep: ============================================= [ INFO: possible recursive locking detected ] 4.5.0-patser+ #4696 Tainted: G U --------------------------------------------- kworker/2:2/2608 is trying to acquire lock: (crtc_ww_class_mutex){+.+.+.}, at: [<ffffffffc00c9ddc>] drm_modeset_lock+0x7c/0x120 [drm] but task is already holding lock: (crtc_ww_class_mutex){+.+.+.}, at: [<ffffffffc00c98cd>] modeset_backoff+0x8d/0x220 [drm] other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(crtc_ww_class_mutex); lock(crtc_ww_class_mutex); *** DEADLOCK *** May be due to missing lock nesting notation 4 locks held by kworker/2:2/2608: #0: ("events"){.+.+.+}, at: [<ffffffff810a5eea>] process_one_work+0x15a/0x6c0 #1: ((&arg.work)){+.+.+.}, at: [<ffffffff810a5eea>] process_one_work+0x15a/0x6c0 #2: (crtc_ww_class_acquire){+.+.+.}, at: [<ffffffffc004532a>] drm_atomic_helper_remove_fb+0x4a/0x1d0 [drm_kms_helper] #3: (crtc_ww_class_mutex){+.+.+.}, at: [<ffffffffc00c98cd>] modeset_backoff+0x8d/0x220 [drm] While lockdep probably catches this bug when it happens, it's better to explicitly warn when state->acquire_ctx is not set. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462266751-29123-1-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/drm_atomic.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 92a847e3609a8d00bcbe8bdfacbcbbca03135410 Author: Stefan Agner <stefan@agner.ch> Date: Thu Apr 28 14:07:03 2016 -0700 clk: imx7d: fix ahb clock mux 1 The clock parent of the AHB root clock when using mux option 1 is the SYS PLL 270MHz clock. This is specified in Table 5-11 Clock Root Table of the i.MX 7Dual Applications Processor Reference Manual. While it could be a documentation error, the 270MHz parent is also mentioned in the boot ROM configuration in Table 6-28: The clock is by default at 135MHz due to a POST_PODF value of 1 (=> divider of 2). Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-imx7d.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2907f8abb7ec3aec85ceaaf03dfbc16cca0018dc Author: Thierry Reding <thierry.reding@gmail.com> Date: Mon May 2 12:07:34 2016 +0200 pwm: Use kcalloc() instead of kzalloc() kcalloc() should be preferred for allocations of arrays over kzalloc() with multiplication. Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 83a98864ff62b23dfa93baeaaf340741e263c02b Author: Thierry Reding <thierry.reding@gmail.com> Date: Mon May 2 12:05:55 2016 +0200 pwm: Add missing newline checkpatch requires that declarations be separated from code by a blank line. Add one for readability and to silence the warning. Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 1 + 1 file changed, 1 insertion(+) commit 8c12ad8e916ee0477f7a0a0f00b0a87b9a21ebf7 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:27 2016 +0200 regulator: pwm: Use pwm_get_args() where appropriate The PWM framework has clarified the concept of reference PWM config (the platform dependent config retrieved from the DT or the PWM lookup table) and real PWM state. Use pwm_get_args() when the PWM user wants to retrieve this reference config and not the current state. This is part of the rework allowing the PWM framework to support hardware readout and expose real PWM state even when the PWM has just been requested (before the user calls pwm_config/enable/disable()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/regulator/pwm-regulator.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) commit 1591196ebdec9202b44d35b5a000910fd7a1898a Merge: f55532a e39c0df Author: Thierry Reding <thierry.reding@gmail.com> Date: Tue May 3 13:45:33 2016 +0200 Merge branch 'for-4.7/pwm-args' into for-4.7/pwm-regulator commit e39c0df1be5a97e0910b09af1530bdf3de057a06 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Apr 14 21:17:21 2016 +0200 pwm: Introduce the pwm_args concept Currently the PWM core mixes the current PWM state with the per-platform reference config (specified through the PWM lookup table, DT definition or directly hardcoded in PWM drivers). Create a struct pwm_args to store this reference configuration, so that PWM users can differentiate between the current and reference configurations. Patch all places where pwm->args should be initialized. We keep the pwm_set_polarity/period() calls until all PWM users are patched to use pwm_args instead of pwm_get_period/polarity(). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> [thierry.reding@gmail.com: reword kerneldoc comments] Signed-off-by: Thierry Reding <thierry.reding@gmail.com> drivers/pwm/core.c | 21 ++++++++++++++------- drivers/pwm/pwm-clps711x.c | 2 +- drivers/pwm/pwm-pxa.c | 2 +- include/linux/pwm.h | 33 +++++++++++++++++++++++++++++++++ 4 files changed, 49 insertions(+), 9 deletions(-) commit a53d892dfb6f14f77c508e1027f5e1bdb400fd23 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:33:00 2016 +0100 clocksource: arm_arch_timer: Remove arch_timer_get_timecounter The only call of arch_timer_get_timecounter (in KVM) has been removed. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/clocksource/arm_arch_timer.c | 5 ----- include/clocksource/arm_arch_timer.h | 6 ------ 2 files changed, 11 deletions(-) commit 503a62862e8fc08b2d4c0db06ba3adae3bbd61bc Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:59 2016 +0100 KVM: arm/arm64: vgic: Rely on the GIC driver to parse the firmware tables Currently, the firmware tables are parsed 2 times: once in the GIC drivers, the other time when initializing the vGIC. It means code duplication and make more tedious to add the support for another firmware table (like ACPI). Use the recently introduced helper gic_get_kvm_info() to get information about the virtual GIC. With this change, the virtual GIC becomes agnostic to the firmware table and KVM will be able to initialize the vGIC on ACPI. Signed-off-by: Julien Grall <julien.grall@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> include/kvm/arm_vgic.h | 7 +++--- virt/kvm/arm/vgic-v2.c | 61 +++++++++++++++++++++----------------------------- virt/kvm/arm/vgic-v3.c | 47 +++++++++++++------------------------- virt/kvm/arm/vgic.c | 50 ++++++++++++++++++++++------------------- 4 files changed, 73 insertions(+), 92 deletions(-) commit 29c2d6ff4cf9af6bcbba3a76aae1d5cacd5da16b Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:58 2016 +0100 KVM: arm/arm64: arch_timer: Rely on the arch timer to parse the firmware tables The firmware table is currently parsed by the virtual timer code in order to retrieve the virtual timer interrupt. However, this is already done by the arch timer driver. To avoid code duplication, use the newly function arch_timer_get_kvm_info() which return all the information required by the virtual timer code. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> virt/kvm/arm/arch_timer.c | 40 +++++++++++----------------------------- 1 file changed, 11 insertions(+), 29 deletions(-) commit 1839e576968f34b9a31da9f0033f8de12a1c9de6 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:57 2016 +0100 irqchip/gic-v3: Parse and export virtual GIC information Fill up the recently introduced gic_kvm_info with the hardware information used for virtualization. Signed-off-by: Julien Grall <julien.grall@arm.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/irqchip/irq-gic-v3.c | 114 ++++++++++++++++++++++++++++++++- include/linux/irqchip/arm-gic-common.h | 1 + 2 files changed, 114 insertions(+), 1 deletion(-) commit 611f039f5ee4f18a2941574857390cf8765184d5 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:56 2016 +0100 irqchip/gic-v3: Gather all ACPI specific data in a single structure The ACPI code requires to use global variables in order to collect information from the tables. To make clear those variables are ACPI specific, gather all of them in a single structure. Furthermore, even if some of the variables are not marked with __initdata, they are all only used during the initialization. Therefore, the new variable, which hold the structure, can be marked with __initdata. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Reviewed-by: Hanjun Guo <hanjun.guo@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/irqchip/irq-gic-v3.c | 60 ++++++++++++++++++++++++-------------------- 1 file changed, 33 insertions(+), 27 deletions(-) commit 68628bb87fe559969b92c8d5c5fd78d8dea5676b Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:55 2016 +0100 irqchip/gic-v3: Prefix all pr_* messages by "GICv3: " Currently, most of the pr_* messages in the GICv3 driver don't have a prefix. Add one to make clear where the messages come from. Signed-off-by: Julien Grall <julien.grall@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/irqchip/irq-gic-v3.c | 2 ++ 1 file changed, 2 insertions(+) commit 502d6df11ae394301470703fa6e485a0dc133401 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:54 2016 +0100 irqchip/gic-v2: Parse and export virtual GIC information For now, the firmware tables are parsed 2 times: once in the GIC drivers, the other timer when initializing the vGIC. It means code duplication and make more tedious to add the support for another firmware table (like ACPI). Introduce a new structure and set of helpers to get/set the virtual GIC information. Also fill up the structure for GICv2. Signed-off-by: Julien Grall <julien.grall@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/irqchip/irq-gic-common.c | 13 ++++++ drivers/irqchip/irq-gic-common.h | 3 ++ drivers/irqchip/irq-gic.c | 76 +++++++++++++++++++++++++++++++++- include/linux/irqchip/arm-gic-common.h | 33 +++++++++++++++ 4 files changed, 124 insertions(+), 1 deletion(-) commit bafa9193d00c7bfff4c4aea0d48cd2b55a6378c2 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:53 2016 +0100 irqchip/gic-v2: Gather ACPI specific data in a single structure The ACPI code requires to use global variables in order to collect information from the tables. For now, a single global variable is used, but more will be added in a subsequent patch. To make clear they are ACPI specific, gather all the information in a single structure. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christofer Dall <christoffer.dall@linaro.org> Acked-by: Hanjun Guo <hanjun.guo@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/irqchip/irq-gic.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit d9b5e41591ca6bc6678e287b5ffe7fac2e07436e Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:52 2016 +0100 clocksource: arm_arch_timer: Extend arch_timer_kvm_info to get the virtual IRQ Currently, the firmware table is parsed by the virtual timer code in order to retrieve the virtual timer interrupt. However, this is already done by the arch timer driver. To avoid code duplication, extend arch_timer_kvm_info to get the virtual IRQ. Note that the KVM code will be modified in a subsequent patch. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/clocksource/arm_arch_timer.c | 2 ++ include/clocksource/arm_arch_timer.h | 1 + 2 files changed, 3 insertions(+) commit b4d6ce9776e0fb773418efe8bc81d8c5ccca3493 Author: Julien Grall <julien.grall@arm.com> Date: Mon Apr 11 16:32:51 2016 +0100 clocksource: arm_arch_timer: Gather KVM specific information in a structure Introduce a structure which are filled up by the arch timer driver and used by the virtual timer in KVM. The first member of this structure will be the timecounter. More members will be added later. A stub for the new helper isn't introduced because KVM requires the arch timer for both ARM64 and ARM32. The function arch_timer_get_timecounter is kept for the time being and will be dropped in a subsequent patch. Signed-off-by: Julien Grall <julien.grall@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> drivers/clocksource/arm_arch_timer.c | 12 +++++++++--- include/clocksource/arm_arch_timer.h | 5 +++++ 2 files changed, 14 insertions(+), 3 deletions(-) commit 3f2129fd0daeaf9e60a51f9ebd2d9faabb437308 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Apr 15 15:32:55 2016 +0900 ARM: dts: exynos: Add support of Bus frequency using VDD_INT for exynos5422-odroidxu3 This patch adds the bus device tree nodes for INT (Internal) block to enable the AMBA bus frequency scaling and add the NoC (Network on Chip) Probe Device Tree node to measure the bandwidth for AMBA AXI bus. The WCORE bus bus is parent device in INT block using VDD_INT. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi | 99 ++++++++++++++++++++++ 1 file changed, 99 insertions(+) commit b04a62d3ade3591a70d161455fb132a410313cd2 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Apr 15 15:32:54 2016 +0900 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos542x SoC This patch adds the AMBA bus nodes using VDD_INT for Exynos542x SoC. Exynos542x has the following AMBA buses to translate data between DRAM and sub-blocks. Following list specifies the detailed correlation between sub-block and clock: - CLK_DOUT_ACLK400_WCORE clock for WCORE's AXI - CLK_DOUT_ACLK100_NOC for NoC (Network on Chip)'s AXI - CLK_DOUT_PCLK200_FSYS for FSYS's APB - CLK_DOUT_ACLK200_FSYS for FSYS's AXI - CLK_DOUT_ACLK200_FSYS2 for FSYS2's AXI - CLK_DOUT_ACLK333 for MFC's AXI - CLK_DOUT_ACLK266 for GEN's AXI - CLK_DOUT_ACLK66 for PERIC/PERIR's AXI - CLK_DOUT_ACLK333_G2D for G2D's AXI - CLK_DOUT_ACLK266_G2D for ACP's AXI - CLK_DOUT_ACLK300_JPEG for JPEG's AXI - CLK_DOUT_ACLK166 for JPEG's APB - CLK_DOUT_ACLK300_DISP1 for FIMD's AXI - CLK_DOUT_ACLK400_DISP1 for DISP1's AXI - CLK_DOUT_ACLK300_GSCL for GSCL Scaler's AXI - CLK_DOUT_ACLK400_MSCL for MSCL's AXI Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5420.dtsi | 371 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 371 insertions(+) commit f018c987ddac3873cdf11837498305ed8591382d Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Apr 15 15:32:51 2016 +0900 ARM: dts: exynos: Add NoC Probe dt node for Exynos542x SoC This patch adds the NoCP (Network on Chip Probe) Device Tree node to measure the bandwidth of memory and g3d in Exynos542x SoC. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5420.dtsi | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) commit 4f20aa0eebe0d66f89b39cbd741632ff7be7f6be Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:58 2016 +0900 ARM: dts: exynos: Add support of bus frequency for exynos4412-trats/odroidu3 This patch adds the bus device tree nodes for both MIF (Memory) and INT (Internal) block to enable the bus frequency. The DMC bus is parent device in MIF block using VDD_MIF and the LEFTBUS bus is parent device in INT block using VDD_INT. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 47 +++++++++++++++++++++++++ arch/arm/boot/dts/exynos4412-trats2.dts | 47 +++++++++++++++++++++++++ 2 files changed, 94 insertions(+) commit 918f7c2d5095e4067eb77a54425fd6e1bab5787f Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:57 2016 +0900 ARM: dts: exynos: Expand the voltage range of buck1/3 regulator for exynos4412-odroidu3 This patch expands the voltage range of buck1/3 regulator due to as following: - MIF (Memory Interface) bus frequency needs the range of '900 - 1100 mV'. - INT (Internal) bus frequency needs the range of '900 - 1050 mV'. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 691d010e5d5f9582b5976d5f8cfb9ac9ce4b5008 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:56 2016 +0900 ARM: dts: exynos: Add support of bus frequency using VDD_INT for exynos3250-rinato This patch adds the bus device-tree nodes of INT (internal) block to enable the bus frequency scaling. The following sub-blocks share the VDD_INT power source: - LEFTBUS (parent device) - RIGHTBUS - PERIL - LCD0 - FSYS - MCUISP / ISP - MFC The LEFTBUS is parent device with devfreq ondemand governor and the rest of devices depend on the LEFTBUS device. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-rinato.dts | 41 +++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit 4a80467a7cc0e038c241578faafbd1fee0c5b570 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:55 2016 +0900 ARM: dts: exynos: Add exynos4412-ppmu-common dtsi to delete duplicate PPMU nodes This patch adds the exynos4412-ppmu-common.dtsi to remove duplicate PPMU nodes because exynos3250-rinato/monk, exynos4412-trats2/odroidu3 has the same PPMU device tree node. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-monk.dts | 41 +------------------- arch/arm/boot/dts/exynos3250-rinato.dts | 41 +------------------- arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 1 + arch/arm/boot/dts/exynos4412-ppmu-common.dtsi | 50 +++++++++++++++++++++++++ arch/arm/boot/dts/exynos4412-trats2.dts | 41 +------------------- 5 files changed, 54 insertions(+), 120 deletions(-) commit f0ba9eaa9129043ce12cf97b1f8d6fad33934a40 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:54 2016 +0900 ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4210 This patch adds the bus nodes for Exynos4210 SoC. Exynos4210 SoC has one power line for all buses to translate data between DRAM and sub-blocks. Following list specifies the detailed relation between DRAM and sub-blocks: - DMC/ACP clock for DMC (Dynamic Memory Controller) - ACLK200 clock for LCD0 - ACLK100 clock for PERIL/PERIR/MFC(PCLK) - ACLK160 clock for CAM/TV/LCD0/LCD1 - ACLK133 clock for FSYS/GPS - GDL/GDR clock for LEFTBUS/RIGHTBUS - SCLK_MFC clock for MFC Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4210.dtsi | 159 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) commit aa99564d91a577538c1c6b9aea1fbc32769b38cd Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:53 2016 +0900 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos4x12 This patch adds the bus nodes using VDD_INT for Exynos4x12 SoC. Exynos4x12 has the following AXI buses to translate data between DRAM and sub-blocks. Following list specifies the detailed relation between DRAM and sub-blocks: - ACLK100 clock for PERIL/PERIR/MFC(PCLK) - ACLK160 clock for CAM/TV/LCD : The minimum clock of ACLK160 should be over 160MHz. When drop the clock under 160MHz, show the broken image. - ACLK133 clock for FSYS - GDL clock for LEFTBUS - GDR clock for RIGHTBUS - SCLK_MFC clock for MFC Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4x12.dtsi | 106 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) commit 266bdc5d61ea79357a7c55b51bf6697a82c5b44c Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:52 2016 +0900 ARM: dts: exynos: Add bus nodes using VDD_MIF for Exynos4x12 This patch adds the bus nodes using VDD_MIF for Exynos4x12 SoC. Exynos4x12 has the following AXI buses to translate data between DRAM and DMC/ACP/C2C. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4x12.dtsi | 68 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) commit 304d10abb6803ab990c9879912bda5c42899be25 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:51 2016 +0900 ARM: dts: exynos: Add bus nodes using VDD_INT for Exynos3250 This patch adds the bus nodes using VDD_INT for Exynos3250 SoC. Exynos3250 has following AXI buses to translate data between DRAM and sub-blocks. Following list specifies the detailed relation between DRAM and sub-blocks: - ACLK400 clock for MCUISP - ACLK266 clock for ISP - ACLK200 clock for FSYS - ACLK160 clock for LCD0 - ACLK100 clock for PERIL - GDL clock for LEFTBUS - GDR clock for RIGHTBUS - SCLK_MFC clock for MFC Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250.dtsi | 147 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 147 insertions(+) commit e9a53680de225a9df146a90e90b2284a68c727c5 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:50 2016 +0900 ARM: dts: exynos: Add DMC bus frequency for exynos3250-rinato/monk This patch adds the DMC (Dynamic Memory Controller) bus frequency node which includes the devfreq-events and regulator properties. The bus frequency support the DVFS (Dynamic Voltage Frequency Scaling) feature with ondemand governor. The devfreq-events (ppmu_dmc0*) can monitor the utilization of DMC bus on runtime and the buck1_reg (VDD_MIF power line) supplies the power to the DMC block. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-monk.dts | 6 ++++++ arch/arm/boot/dts/exynos3250-rinato.dts | 6 ++++++ 2 files changed, 12 insertions(+) commit 6b088a62ebc327a204bd102233515d2b67235285 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Apr 11 12:57:49 2016 +0900 ARM: dts: exynos: Add DMC bus node for Exynos3250 This patch adds the DMC (Dynamic Memory Controller) bus node for Exynos3250 SoC. The DMC is an AMBA AXI-compliant slave to interface external JEDEC standard SDRAM devices. The bus includes the OPP tables and the source clock for DMC block. Following list specifies the detailed relation between the clock and DMC block: - The source clock of DMC block : div_dmc Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250.dtsi | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit 483997a761c003257eb0606bce8d408743ffd8c5 Merge: f55532a 81fed6e Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue May 3 12:21:50 2016 +0200 Merge tag 'clk-v4.7-exynos542x' of git://linuxtv.org/snawrocki/samsung into for-v4.7-late/dts-exynos-devfreq Addition of IDs for Exynos542x SoC AMBA AXI bus clocks. These IDs are needed before we start using them in DTS. commit 07a7056ccce3ffdb65908bf502aeb2503714da46 Author: Russell King <rmk+kernel@arm.linux.org.uk> Date: Tue Mar 15 15:00:30 2016 +0000 ARM: provide arm_has_idmap_alias() helper Provide a helper to indicate whether we need to perform special handling for boot identity mapping aliases or not. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Reviewed-by: Pratyush Anand <panand@redhat.com> arch/arm/include/asm/memory.h | 5 +++++ 1 file changed, 5 insertions(+) commit d0506a2395eb07bef248de95016d9a8cf8a465ea Author: Russell King <rmk+kernel@arm.linux.org.uk> Date: Fri Apr 1 14:47:36 2016 +0100 ARM: kexec: remove 512MB restriction on kexec crashdump The real limit is the top of the visible physical address space with the MMU turned off. Hence, we need to limit the crash kernel allocation running-view physical address of the top of the boot-view physical address space. Reviewed-by: Pratyush Anand <panand@redhat.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/kernel/setup.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 981b6714dbd26609212536b9fed43e49db1459cf Author: Russell King <rmk+kernel@arm.linux.org.uk> Date: Tue Mar 15 14:55:03 2016 +0000 ARM: provide improved virt_to_idmap() functionality For kexec, we need more functionality from the IDMAP system. We need to be able to convert physical addresses to their identity mappped versions as well as virtual addresses. Convert the existing arch_virt_to_idmap() to deal with physical addresses instead. Acked-by: Santosh Shilimkar <ssantosh@kernel.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/include/asm/memory.h | 33 ++++++++++++++++++++++++++------- arch/arm/mach-keystone/keystone.c | 7 +------ arch/arm/mm/idmap.c | 2 +- 3 files changed, 28 insertions(+), 14 deletions(-) commit 61603016e2122bf95328321b2f1a64277202b6e3 Author: Russell King <rmk+kernel@arm.linux.org.uk> Date: Mon Mar 14 19:34:37 2016 +0000 ARM: kexec: fix crashkernel= handling When the kernel crashkernel parameter is specified with just a size, we are supposed to allocate a region from RAM to store the crashkernel. However, ARM merely reserves physical address zero with no checking that there is even RAM there. Fix this by lifting similar code from x86, importing it to ARM with the ARM specific parameters added. In the absence of any platform specific information, we allocate the crashkernel region from the first 512MB of physical memory. Update the kdump documentation to reflect this change. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Reviewed-by: Pratyush Anand <panand@redhat.com> Documentation/kdump/kdump.txt | 13 +++---------- arch/arm/kernel/setup.c | 29 +++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 10 deletions(-) commit e1ca790c8a32c0c77b9d89089ac7e73b72c2adfc Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:15 2016 -0400 rtl8xxxu: Remove the now obsolete mbox_ext_reg info from rtl8xxxu_fileops With two different h2c_cmd() functions, mbox_ext_reg and mbox_ext_width are no longer needed. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 -- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192c.c | 2 -- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192e.c | 2 -- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723a.c | 2 -- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723b.c | 2 -- 5 files changed, 10 deletions(-) commit 27c7e89ea77bf550935acab13b2419e0ace83af2 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:14 2016 -0400 rtl8xxxu: rtl8xxxu_prepare_calibrate() is never used on gen1 Rename it to rtl8xxxu_gen2_prepare_calibrate() and remove the calls to it from rtl8xxxu_gen1_phy_iq_calibrate() Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723b.c | 4 ++-- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 9 +-------- 3 files changed, 4 insertions(+), 11 deletions(-) commit 9c0343d4f48bc7734e7945b8c50c2f95d9c38244 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:13 2016 -0400 rtl8xxxu: Split rtl8723a_h2c_cmd() into a gen1 and a gen2 version The H2C API is completely different between gen1 and gen2 parts, so there is little point trying to treat this as a generic function. All calls to *_h2c_cmd() will always come from a gen1 or a gen2 specific function. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 3 +- .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723b.c | 12 +-- .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 86 ++++++++++++++++------ 3 files changed, 72 insertions(+), 29 deletions(-) commit 993dd9b425f548105679b8de310869fef2475c65 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:12 2016 -0400 rtl8xxxu: Rename rtl8723a_disabled_to_emu() to rtl8xxxu_disabled_to_emu() This function is generic to most of the chips, so change the name to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723a.c | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723b.c | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit a46b099ca730e0069128b6a5491b171c92306c82 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:11 2016 -0400 rtl8xxxu: rename rtl8723a_channel_group() to rtl8xxxu_gen1_channel_to_group() This function is generic for most (if not all) gen1 parts, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 97db5a87b0f0376f3814082d5a5b67e0b661a3df Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:10 2016 -0400 rtl8xxxu: Rename rtl8723a_stop_tx_beacon() to rtl8xxxu_stop_tx_beacon() There is nothing 8723au specific about this function, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 181725dd4f33df45b6efd5d74e55798343338875 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:09 2016 -0400 rtl8xxxu: move rtl8188[cr] and rtl8192c related code into rtl8xxxu_8192c.c This moves the code for rtl8188c, rtl8188r, and rtl8192c into it's own file. This is purely a code moving exercise, there is no change to the code itself. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/Makefile | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192c.c | 588 +++++++++++++++++++++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 567 -------------------- 4 files changed, 590 insertions(+), 568 deletions(-) commit 20e3b2e97eddad364e2d68dfecf47a17ae2f4d40 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:08 2016 -0400 rtl8xxxu: move rtl8723a related code into rtl8xxxu_8723a.c This moves the rtl8723a code into it's own file. This is purely a code moving exercise, no code changes. This device specific file is a lot smaller since the gen1 chips (8723a, 8188c, 8188r, 8192c) share a lot more common code than the gen2 chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/Makefile | 3 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 17 + .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723a.c | 399 +++++++++++++++++++++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 388 +------------------- 4 files changed, 432 insertions(+), 375 deletions(-) commit 6c46ca3b5f3b7baeb0385e31cd86a0826ae7b80a Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:07 2016 -0400 rtl8xxxu: move rtl8723b related code into rtl8xxxu_8723b.c This moves the rtl8723b code into it's own file. This is purely a code moving exercise, no functional changes. This did expose rtl723a_h2c_cmd() as a function that should be refactored into a gen1 and a gen2 version. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/Makefile | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 7 + .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_8723b.c | 1684 +++++++++++++++++++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 1754 +------------------- 4 files changed, 1747 insertions(+), 1700 deletions(-) commit 599119f683e623ff2517c318ac20655e8c135574 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:06 2016 -0400 rtl8xxxu: move rtl8192e related code into rtl8xxxu_8192e.c This moves the rtl8192e code into it's own file. This is purely a code moving exercise, no code changes. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/Makefile | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 53 + .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192e.c | 1527 ++++++++++++++++++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 1677 ++------------------ 4 files changed, 1675 insertions(+), 1584 deletions(-) commit 6c60e65cd0929f7ea853eb3e6de898c8d493655c Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 28 15:19:05 2016 -0400 rtl8xxxu: Rename rtl8xxxu.c to rtl8xxxu_core.c This renames the core file to rtl8xxxu_core.c in order to allow us to keep the module nake rtl8xxxu.ko when refactoring the code into multiple files. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/Makefile | 2 + drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 10213 ------------------- .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 10213 +++++++++++++++++++ 3 files changed, 10215 insertions(+), 10213 deletions(-) commit aae555d3026abcf6b7e4d29be2252dcc9ba10f49 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Mon Apr 25 16:17:52 2016 +0200 rtlwifi: rtl818x: Deinline indexed IO functions, save 21568 bytes rtl818x_ioread8_idx: 151 bytes, 29 calls rtl818x_ioread16_idx: 151 bytes, 11 calls rtl818x_ioread32_idx: 151 bytes, 5 calls rtl818x_iowrite8_idx: 157 bytes, 117 calls rtl818x_iowrite16_idx: 158 bytes, 74 calls rtl818x_iowrite32_idx: 157 bytes, 22 calls Each of these functions has a pair of mutex lock/unlock ops, both of these ops perform atomic updates of memory (on x86, it boils down to "lock cmpxchg %reg,mem" insn), which are 4-8 times more expensive than call+return. text data bss dec hex filename 95894242 20860288 35991552 152746082 91ab862 vmlinux_before 95872674 20860320 35991552 152724546 91a6442 vmlinux Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: Larry Finger <Larry.Finger@lwfinger.net> CC: Chaoming Li <chaoming_li@realsil.com.cn> CC: linux-wireless@vger.kernel.org CC: linux-kernel@vger.kernel.org Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/realtek/rtl818x/rtl8187/rtl8187.h | 99 +++------------------- .../net/wireless/realtek/rtl818x/rtl8187/rtl8225.c | 93 ++++++++++++++++++++ 2 files changed, 105 insertions(+), 87 deletions(-) commit bef7e200065086e2ceef091f6853f3b053ad2ba9 Author: Jason Gerecke <killertofu@gmail.com> Date: Fri Apr 22 14:30:53 2016 -0700 HID: wacom: Add fuzz factor to distance and tilt axes The fuzz present on the distance and tilt axes is noticable when a puck is present, and userspace (specifically libinput) would like the ability to filter out the noise. To facilitate this, we assign a fuzz value of '1' for the distance and tilt axes. This is large enough to cover most of the natural variation in distance value as the puck is moved around, and enough to cover the jitter in rotation (reported through tilt axes) when the puck is left alone. Signed-off-by: Jason Gerecke <jason.gerecke@wacom.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/wacom_sys.c | 3 ++- drivers/hid/wacom_wac.c | 13 +++++++------ drivers/hid/wacom_wac.h | 1 + 3 files changed, 10 insertions(+), 7 deletions(-) commit 2326df551b137dd88652b54016905e13579b7a25 Author: Yang Shi <yang.shi@linaro.org> Date: Fri Apr 29 14:07:54 2016 -0700 arm64: always use STRICT_MM_TYPECHECKS Inspired by the counterpart of powerpc [1], which shows there is no negative effect on code generation from enabling STRICT_MM_TYPECHECKS with a modern compiler. And, Arnd's comment [2] about that patch says STRICT_MM_TYPECHECKS could be default as long as the architecture can pass structures in registers as function arguments. ARM64 can do it as long as the size of structure <= 16 bytes. All the page table value types are u64 on ARM64. The below disassembly demonstrates it, entry is pte_t type: entry = arch_make_huge_pte(entry, vma, page, writable); 0xffff00000826fc38 <+80>: and x0, x0, #0xfffffffffffffffd 0xffff00000826fc3c <+84>: mov w3, w21 0xffff00000826fc40 <+88>: mov x2, x20 0xffff00000826fc44 <+92>: mov x1, x19 0xffff00000826fc48 <+96>: orr x0, x0, #0x400 0xffff00000826fc4c <+100>: bl 0xffff00000809bcc0 <arch_make_huge_pte> [1] http://www.spinics.net/lists/linux-mm/msg105951.html [2] http://www.spinics.net/lists/linux-mm/msg105969.html Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Yang Shi <yang.shi@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable-types.h | 32 -------------------------------- 1 file changed, 32 deletions(-) commit 444f94e9e625f6ec6bbe2cb232a6451c637f35a3 Author: Schemmel Hans-Christoph <Hans-Christoph.Schemmel@gemalto.com> Date: Fri Apr 29 08:51:06 2016 +0000 USB: serial: option: add support for Cinterion PH8 and AHxx Added support for Gemalto's Cinterion PH8 and AHxx products with 2 RmNet Interfaces and products with 1 RmNet + 1 USB Audio interface. In addition some minor renaming and formatting. Signed-off-by: Hans-Christoph Schemmel <hans-christoph.schemmel@gemalto.com> [johan: sort current entries and trim trailing whitespace ] Cc: stable <stable@vger.kernel.org> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/option.c | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) commit c612505f860c6d4fac03924879982adcd042e239 Author: James Morse <james.morse@arm.com> Date: Fri Apr 29 18:27:03 2016 +0100 arm64: kvm: Fix kvm teardown for systems using the extended idmap If memory is located above 1<<VA_BITS, kvm adds an extra level to its page tables, merging the runtime tables and boot tables that contain the idmap. This lets us avoid the trampoline dance during initialisation. This also means there is no trampoline page mapped, so __cpu_reset_hyp_mode() can't call __kvm_hyp_reset() in this page. The good news is the idmap is still mapped, so we don't need the trampoline page. The bad news is we can't call it directly as the idmap is above HYP_PAGE_OFFSET, so its address is masked by kvm_call_hyp. Add a function __extended_idmap_trampoline which will branch into __kvm_hyp_reset in the idmap, change kvm_hyp_reset_entry() to return this address if __kvm_cpu_uses_extended_idmap(). In this case __kvm_hyp_reset() will still switch to the boot tables (which are the merged tables that were already in use), and branch into the idmap (where it already was). This fixes boot failures on these systems, where we fail to execute the missing trampoline page when tearing down kvm in init_subsystems(): [ 2.508922] kvm [1]: 8-bit VMID [ 2.512057] kvm [1]: Hyp mode initialized successfully [ 2.517242] kvm [1]: interrupt-controller@e1140000 IRQ13 [ 2.522622] kvm [1]: timer IRQ3 [ 2.525783] Kernel panic - not syncing: HYP panic: [ 2.525783] PS:200003c9 PC:0000007ffffff820 ESR:86000005 [ 2.525783] FAR:0000007ffffff820 HPFAR:00000000003ffff0 PAR:0000000000000000 [ 2.525783] VCPU: (null) [ 2.525783] [ 2.547667] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G W 4.6.0-rc5+ #1 [ 2.555137] Hardware name: Default string Default string/Default string, BIOS ROD0084E 09/03/2015 [ 2.563994] Call trace: [ 2.566432] [<ffffff80080888d0>] dump_backtrace+0x0/0x240 [ 2.571818] [<ffffff8008088b24>] show_stack+0x14/0x20 [ 2.576858] [<ffffff80083423ac>] dump_stack+0x94/0xb8 [ 2.581899] [<ffffff8008152130>] panic+0x10c/0x250 [ 2.586677] [<ffffff8008152024>] panic+0x0/0x250 [ 2.591281] SMP: stopping secondary CPUs [ 3.649692] SMP: failed to stop secondary CPUs 0-2,4-7 [ 3.654818] Kernel Offset: disabled [ 3.658293] Memory Limit: none [ 3.661337] ---[ end Kernel panic - not syncing: HYP panic: [ 3.661337] PS:200003c9 PC:0000007ffffff820 ESR:86000005 [ 3.661337] FAR:0000007ffffff820 HPFAR:00000000003ffff0 PAR:0000000000000000 [ 3.661337] VCPU: (null) [ 3.661337] Reported-by: Will Deacon <will.deacon@arm.com> Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: James Morse <james.morse@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/kvm_host.h | 3 ++- arch/arm64/kvm/hyp-init.S | 5 +++++ arch/arm64/kvm/hyp/entry.S | 19 +++++++++++++++++++ arch/arm64/kvm/reset.c | 30 +++++++++++++++++++++++------- 4 files changed, 49 insertions(+), 8 deletions(-) commit 975f0d100ee5f28547783d2cfb0d578fb50ed61a Author: Marcel Ziswiler <marcel.ziswiler@toradex.com> Date: Fri Apr 29 22:20:49 2016 +0200 ARM: dts: imx6: apalis: parallel lcd display support on ixora Add parallel LCD display support for the EDT ET057090DHU 5.7" LCD TFT panel. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-apalis-ixora.dts | 45 ++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) commit 1dd58e12dfd037edfa75825bb719031dec822a73 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Thu Apr 28 23:34:27 2016 -0300 ARM: dts: imx6sx-sdb: Add 198MHz operational point imx6sx-sdb has custom operating points entries because it has one power supply that drives both VDDARM_IN and VDDSOC_IN. As per the MX6UL datasheet we have the following minimum voltages for 198 MHz operation (after adding the 25mV margin value): VDDARM_IN = 0.975 V VDDSOC_IN = 1.175 V So use 1.175V for the 198MHz operation. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6sx-sdb.dts | 2 ++ 1 file changed, 2 insertions(+) commit 96466f0478ae3b33826555de4675785fc6efc306 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed Apr 27 12:27:52 2016 -0300 ARM: dts: imx28-m28: Remove unneeded partition nodes mtdparts is passed from command line, so there is no need to have a default partitioning in device-tree. Suggested-by: Marek Vasut <marex@denx.de> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Marek Vasut <marex@denx.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx28-m28.dtsi | 26 -------------------------- 1 file changed, 26 deletions(-) commit 096a8b6d5e7ab9f8ca3d2474b3ca6a1fe79e0371 Author: James Hogan <james.hogan@imgtec.com> Date: Tue May 3 09:11:21 2016 +0100 metag: Fix atomic_*_return inline asm constraints The argument i of atomic_*_return() operations is given to inline asm with the "bd" constraint, which means "An Op2 register where Op1 is a data unit register and the instruction supports O2R", however Op1 is constrained by "da" which allows an address unit register to be used. Fix the constraint to use "br", meaning "An Op2 register and the instruction supports O2R", i.e. not requiring Op1 to be a data unit register. Fixes: d6dfe2509da9 ("locking,arch,metag: Fold atomic_ops") Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: linux-metag@vger.kernel.org arch/metag/include/asm/atomic_lnkget.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f5d163aad31e4ec30f7258e655503824a2b03d45 Author: James Hogan <james.hogan@imgtec.com> Date: Mon Jul 22 15:18:34 2013 +0100 metag: perf: fix build on Meta1 Meta1 doesn't support PERF_ICORE or PERF_CHAN registers resulting in build errors due to missing definitions. Fix this with an ifdef matching the one in asm/metag_mem.h. The build errors (found by a randconfig): arch/metag/kernel/perf/perf_event.c: In function 'metag_pmu_enable_counter': arch/metag/kernel/perf/perf_event.c:639: error: 'PERF_ICORE0' undeclared (first use in this function) arch/metag/kernel/perf/perf_event.c:639: error: (Each undeclared identifier is reported only once arch/metag/kernel/perf/perf_event.c:639: error: for each function it appears in.) arch/metag/kernel/perf/perf_event.c:643: error: 'PERF_CHAN0' undeclared (first use in this function) Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-metag@vger.kernel.org arch/metag/kernel/perf/perf_event.c | 3 +++ 1 file changed, 3 insertions(+) commit 76396df228db0d259fe8e1046fc9a1c3794f7379 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 2 13:00:26 2016 +0200 drm/fsl-dcu: add COMMON_CLK dependency The fsl dcu now uses the clk-provider interfaces, which are not available when CONFIG_COMMON_CLK is disabled: drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c: In function 'fsl_dcu_drm_probe': drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c:362:20: error: implicit declaration of function '__clk_get_name' [-Werror=implicit-function-declaration] pix_clk_in_name = __clk_get_name(pix_clk_in); This adds a Kconfig dependency to prevent the driver from being enabled in this case. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 2d701449bce1 ("drm/fsl-dcu: use common clock framework for pixel clock divider") Acked-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462186839-2224021-1-git-send-email-arnd@arndb.de drivers/gpu/drm/fsl-dcu/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc197b2a9c7e0129fa0ec1961881e2a0b3bef967 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun May 1 13:52:55 2016 +0200 crypto: ccp - constify ccp_actions structure The ccp_actions structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Gary Hook <gary.hook@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/ccp/ccp-dev-v3.c | 2 +- drivers/crypto/ccp/ccp-dev.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 472d640bd0fe5b28332b277316cff1dadf40d083 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri Apr 29 22:09:11 2016 +0200 crypto: marvell/cesa - Use dma_pool_zalloc Dma_pool_zalloc combines dma_pool_alloc and memset 0. The semantic patch that makes this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression d,e; statement S; @@ d = - dma_pool_alloc + dma_pool_zalloc (...); if (!d) S - memset(d, 0, sizeof(*d)); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/marvell/tdma.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit d0c15bd5067ec75d8738f4d4ba1e5e3ab0ea6f2d Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 29 11:00:00 2016 -0700 crypto: qat - make adf_vf_isr.c dependant on IOV config The adf_vf_isr.c should only be build if CONFIG_PCI_IOV is enabled Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/Makefile | 4 ++-- drivers/crypto/qat/qat_common/adf_common_drv.h | 14 ++++++++++++-- 2 files changed, 14 insertions(+), 4 deletions(-) commit cca0a7b0ac7fd905a9db6c724dab87e6e6bbee00 Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 29 10:59:59 2016 -0700 crypto: qat - Fix typo in comments Fix copy and paste typo adf_isr.c Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_isr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ccab6058daa4933def4194b8ff6a4bb33c7f2a97 Author: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Date: Fri Apr 29 17:48:08 2016 +0300 lib: asn1_decoder - add MODULE_LICENSE("GPL") A kernel taint results when loading the rsa_generic module: root@(none):~# modprobe rsa_generic asn1_decoder: module license 'unspecified' taints kernel. Disabling lock debugging due to kernel taint "Tainting" of the kernel is (usually) a way of indicating that a proprietary module has been inserted, which is not the case here. Signed-off-by: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/asn1_decoder.c | 3 +++ 1 file changed, 3 insertions(+) commit dbe246209bc1a2a870250499b8f584251838d5b4 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:03:41 2016 +0300 crypto: omap-sham - Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> CC: Herbert Xu <herbert@gondor.apana.org.au> CC: David S. Miller <davem@davemloft.net> CC: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/omap-sham.c | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-) commit 2f6f0680c78e2bc35f576ea956b284aa45cef0d1 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:02:56 2016 +0300 crypto: omap-des - Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> CC: Herbert Xu <herbert@gondor.apana.org.au> CC: David S. Miller <davem@davemloft.net> CC: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/omap-des.c | 68 ++++++++++++----------------------------------- 1 file changed, 17 insertions(+), 51 deletions(-) commit da8b29a6c1894874b681f42186c61c58c09e0b56 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:02:18 2016 +0300 crypto: omap-aes - Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> CC: Herbert Xu <herbert@gondor.apana.org.au> CC: David S. Miller <davem@davemloft.net> CC: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/omap-aes.c | 62 ++++++++++++----------------------------------- 1 file changed, 16 insertions(+), 46 deletions(-) commit f1b77aaca85a610948f02d11288845f4cfe7d3eb Author: Baolin Wang <baolin.wang@linaro.org> Date: Thu Apr 28 14:11:51 2016 +0800 crypto: omap-des - Integrate with the crypto engine framework Since the crypto engine framework had been merged, thus this patch integrates with the newly added crypto engine framework to make the crypto hardware engine under utilized as each block needs to be processed before the crypto hardware can start working on the next block. The crypto engine framework can manage and process the requests automatically, so remove the 'queue' and 'queue_task' things in omap des driver. Signed-off-by: Baolin <baolin.wang@linaro.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/Kconfig | 1 + drivers/crypto/omap-des.c | 97 +++++++++++++++++++++-------------------------- 2 files changed, 44 insertions(+), 54 deletions(-) commit 6dd4c83ed7e28309c03b0c267f1473fc3e7db9f1 Merge: d149797 6dc5df7 Author: Herbert Xu <herbert@gondor.apana.org.au> Date: Tue May 3 16:01:52 2016 +0800 Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Merge the crypto tree to pull in the qat adf_init_pf_wq fix. commit e18eb2d1eb03fa06ccb7823a44d7ceea621e2bbb Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Mon May 2 11:00:12 2016 +0200 s390/cpum_sf: Remove superfluous SMP function call Since commit 3b9d6da67e11 ("cpu/hotplug: Fix rollback during error-out in __cpu_disable()") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this SMP function calls are no longer required. Replace smp_call_function_single() with a direct call of setup_pmc_cpu(). To keep the calling convention, interrupts are explicitly disabled around the call. Cc: linux-s390@vger.kernel.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/perf_cpum_sf.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 5bc73539013e93fc44e4d8b1d3557d0ec78df704 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Mon May 2 10:59:32 2016 +0200 s390/cpum_cf: Remove superfluous SMP function call Since commit 3b9d6da67e11 ("cpu/hotplug: Fix rollback during error-out in __cpu_disable()") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this SMP function calls are no longer required. Replace smp_call_function_single() with a direct call of setup_pmc_cpu(). To keep the calling convention, interrupts are explicitly disabled around the call. Cc: linux-s390@vger.kernel.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/kernel/perf_cpum_cf.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit c39290a1f3caad4a82bbf1bed0e3db7bcc06b54c Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Fri Apr 29 09:49:08 2016 +0200 dmaengine: mv_xor: Allow selecting mv_xor for mvebu only compatible SoC Armada 3700 SoC uses the mv_xor driver but don't select anymore the PLAT_ORION symbol. This commit extends the dependency of the mv_xor driver to the more modern SoCs only compatible with ARCH_MVEBU, which allows using it with the Armada 3700 SoC. In the same time it also add the COMPILE_TEST dependency allowing a wider test coverage. Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ac5f0f3f863e9e6703a3038aa72814d2d0e8a056 Author: Marcin Wojtas <mw@semihalf.com> Date: Fri Apr 29 09:49:07 2016 +0200 dmaengine: mv_xor: add support for Armada 3700 SoC Armada 3700 SoC comprise a single XOR engine compliant with the ones used in older Marvell SoC's like Armada XP or 38x. The only thing that needs modification is the Mbus configuration, which has to be done on two levels: global and in device. The first one is inherited from the bootloader. The latter can be opened in a default way, leaving arbitration to the bus controller. Hence filled mbus_dram_target_info structure is not needed. Patch "dmaengine: mv_xor: optimize performance by using a subset of the XOR channels" introduced limitation for using XOR engines and channels vs number of available CPU's. Those constraints do not however fit Armada 3700 architecture with two possible CPU's and single, dual-channel engine. Hence in this commit an adjustment for setting maximum available channels is added. This patch enables XOR access to DRAM by opening default window to 4GB space with specific attribute. Signed-off-by: Marcin Wojtas <mw@semihalf.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/devicetree/bindings/dma/mv-xor.txt | 5 ++- drivers/dma/mv_xor.c | 56 +++++++++++++++++++++--- 2 files changed, 53 insertions(+), 8 deletions(-) commit dd130c652cb745e82b70cb71a3cf2dd876295e96 Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Fri Apr 29 09:49:06 2016 +0200 dmaengine: mv_xor: use SoC type instead of directly the operation mode Currently the main difference between legacy XOR engine and newer one, is the way the engine modes are setup (either in the descriptor or through the controller registers). In order to be able to take into account new generation of the XOR engine for the ARM64 SoC, we need to identify them by type, and then depending to the type the engine setup will be selected. Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mv_xor.c | 40 ++++++++++++++++++++++++++++------------ drivers/dma/mv_xor.h | 1 + 2 files changed, 29 insertions(+), 12 deletions(-) commit bc822e1251f908ab2560365d388f36afb9da255a Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Fri Apr 29 09:49:05 2016 +0200 dmaengine: mv_xor: make the code 64 bits compliant Fix two warnings which appear when building for 64 bits target: drivers/dma/mv_xor.c: In function ‘mv_xor_prep_dma_xor’: drivers/dma/mv_xor.c:480:3: warning: format ‘%u’ expects argument of type ‘unsigned int’, but argument 6 has type ‘size_t {aka long unsigned int}’ [-Wformat=] "%s src_cnt: %d len: %u dest %pad flags: %ld\n", ^ drivers/dma/mv_xor.c: In function ‘mv_xor_probe’: drivers/dma/mv_xor.c:1223:17: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] op_in_desc = (int)of_id->data; ^ Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mv_xor.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2ba4f8abfe450ddf55bf6c79b4650525b37f6962 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri Apr 29 22:09:09 2016 +0200 dmaengine: vdma: Use dma_pool_zalloc Dma_pool_zalloc combines dma_pool_alloc and memset 0. The semantic patch that makes this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression d,e; statement S; @@ d = - dma_pool_alloc + dma_pool_zalloc (...); if (!d) S - memset(d, 0, sizeof(*d)); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 4376455727dcf627f12c3d209410ac576c0e8f0e Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri Apr 29 22:09:12 2016 +0200 dmaengine: fsldma: Use dma_pool_zalloc Dma_pool_zalloc combines dma_pool_alloc and memset 0. The semantic patch that makes this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression d,e; statement S; @@ d = - dma_pool_alloc + dma_pool_zalloc (...); if (!d) S - memset(d, 0, sizeof(*d)); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Li Yang <leoyang.li@nxp.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/fsldma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 305697facd1b6d1ce41eaffb1fbe2bf5950334eb Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri Apr 29 22:09:10 2016 +0200 dmaengine: ioatdma: Use dma_pool_zalloc Dma_pool_zalloc combines dma_pool_alloc and memset 0. The semantic patch that makes this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression d,e; statement S; @@ d = - dma_pool_alloc + dma_pool_zalloc (...); if (!d) S - memset(d, 0, sizeof(*d)); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/ioat/init.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 1c85a8440f0cd19e7c1235c8abfc3e07b2226691 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Fri Apr 29 22:09:08 2016 +0200 dmaengine: mmp_pdma: Use dma_pool_zalloc Dma_pool_zalloc combines dma_pool_alloc and memset 0. The semantic patch that makes this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression d,e; statement S; @@ d = - dma_pool_alloc + dma_pool_zalloc (...); if (!d) S - memset(d, 0, sizeof(*d)); // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mmp_pdma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 19fd2868e3671b446b13d135a44363182bbd319a Author: Stas Sergeev <stsp@list.ru> Date: Thu Apr 14 23:20:05 2016 +0300 selftests/sigaltstack: Add new testcase for sigaltstack(SS_ONSTACK|SS_AUTODISARM) This patch adds the test case for SS_AUTODISARM flag. The test-case tries to set SS_AUTODISARM flag and checks if the nested signal corrupts the stack after swapcontext(). Signed-off-by: Stas Sergeev <stsp@list.ru> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-api@vger.kernel.org Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460665206-13646-5-git-send-email-stsp@list.ru Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/testing/selftests/Makefile | 1 + tools/testing/selftests/sigaltstack/Makefile | 8 ++ tools/testing/selftests/sigaltstack/sas.c | 156 +++++++++++++++++++++++++++ 3 files changed, 165 insertions(+) commit 2a74213838104a41588d86fd5e8d344972891ace Author: Stas Sergeev <stsp@list.ru> Date: Thu Apr 14 23:20:04 2016 +0300 signals/sigaltstack: Implement SS_AUTODISARM flag This patch implements the SS_AUTODISARM flag that can be OR-ed with SS_ONSTACK when forming ss_flags. When this flag is set, sigaltstack will be disabled when entering the signal handler; more precisely, after saving sas to uc_stack. When leaving the signal handler, the sigaltstack is restored by uc_stack. When this flag is used, it is safe to switch from sighandler with swapcontext(). Without this flag, the subsequent signal will corrupt the state of the switched-away sighandler. To detect the support of this functionality, one can do: err = sigaltstack(SS_DISABLE | SS_AUTODISARM); if (err && errno == EINVAL) unsupported(); Signed-off-by: Stas Sergeev <stsp@list.ru> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Aleksa Sarai <cyphar@cyphar.com> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Eric W. Biederman <ebiederm@xmission.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Heinrich Schuchardt <xypron.glpk@gmx.de> Cc: Jason Low <jason.low2@hp.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Paul Moore <pmoore@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Tejun Heo <tj@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vladimir Davydov <vdavydov@parallels.com> Cc: linux-api@vger.kernel.org Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460665206-13646-4-git-send-email-stsp@list.ru Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 8 ++++++++ include/linux/signal.h | 4 +++- include/uapi/linux/signal.h | 4 +++- kernel/fork.c | 2 +- kernel/signal.c | 10 ++++++++-- 5 files changed, 23 insertions(+), 5 deletions(-) commit 407bc16ad1769f5cb8ad9555611cb198187ef4cd Author: Stas Sergeev <stsp@list.ru> Date: Thu Apr 14 23:20:03 2016 +0300 signals/sigaltstack: Prepare to add new SS_xxx flags This patch adds SS_FLAG_BITS - the mask that splits sigaltstack mode values and bit-flags. Since there is no bit-flags yet, the mask is defined to 0. The flags are added by subsequent patches. With every new flag, the mask should have the appropriate bit cleared. This makes sure if some flag is tried on a kernel that doesn't support it, the -EINVAL error will be returned, because such a flag will be treated as an invalid mode rather than the bit-flag. That way the existence of the particular features can be probed at run-time. This change was suggested by Andy Lutomirski: https://lkml.org/lkml/2016/3/6/158 Signed-off-by: Stas Sergeev <stsp@list.ru> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Amanieu d'Antras <amanieu@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Michal Hocko <mhocko@suse.com> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vladimir Davydov <vdavydov@parallels.com> Cc: linux-api@vger.kernel.org Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460665206-13646-3-git-send-email-stsp@list.ru Signed-off-by: Ingo Molnar <mingo@kernel.org> include/uapi/linux/signal.h | 3 +++ kernel/signal.c | 16 ++++++---------- 2 files changed, 9 insertions(+), 10 deletions(-) commit 0b4521e8cf1f582da3045ea460427ac2f741578f Author: Stas Sergeev <stsp@list.ru> Date: Thu Apr 14 23:20:02 2016 +0300 signals/sigaltstack, x86/signals: Unify the x86 sigaltstack check with other architectures Currently x86's get_sigframe() checks for "current->sas_ss_size" to determine whether there is a need to switch to sigaltstack. The common practice used by all other arches is to check for sas_ss_flags(sp) == 0 This patch makes the code consistent with other architectures. The slight complexity of the patch is added by the optimization on !sigstack check that was requested by Andy Lutomirski: sas_ss_flags(sp)==0 already implies that we are not on a sigstack, so the code is shuffled to avoid the duplicate checking. This patch should have no user-visible impact. Signed-off-by: Stas Sergeev <stsp@list.ru> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Pavel Emelyanov <xemul@parallels.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Richard Weinberger <richard@nod.at> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-api@vger.kernel.org Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460665206-13646-2-git-send-email-stsp@list.ru Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/signal.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) commit fead35c68926682c90c995f22b48f1c8d78865c1 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Sat Apr 30 14:33:57 2016 +0200 x86/mce: Detect local MCEs properly Check the MCG_STATUS_LMCES bit on Intel to verify that current MCE is local. It is always local on AMD. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Massaged it a bit. Reflowed comments. Shut up -Wmaybe-uninitialized. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462019637-16474-8-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) commit 5541c93cdf0cc0bb7f6065b43509171838665ea1 Author: Tony Luck <tony.luck@intel.com> Date: Sat Apr 30 14:33:56 2016 +0200 x86/mce: Look in genpool instead of mcelog for pending error records A couple of issues here: 1) MCE_LOG_LEN is only 32 - so we may have more pending records than will fit in the buffer on high core count CPUs. 2) During a panic we may have a lot of duplicate records because multiple logical CPUs may have seen and logged the same error because some banks are shared. Switch to using the genpool to look for the pending records. Squeeze out duplicated records. Signed-off-by: Tony Luck <tony.luck@intel.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ashok Raj <ashok.raj@intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462019637-16474-7-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce-genpool.c | 46 +++++++++++++++++++++++++++++++ arch/x86/kernel/cpu/mcheck/mce-internal.h | 15 ++++++++++ arch/x86/kernel/cpu/mcheck/mce.c | 21 ++++++-------- 3 files changed, 70 insertions(+), 12 deletions(-) commit d9d73fcc878469d209d7a7030726f20dd10841a7 Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Sat Apr 30 14:33:55 2016 +0200 x86/mce: Detect and use SMCA-specific msr_ops Replace all calls to MCx_IA32_{CTL,ADDR,MISC,STATUS} with the appropriate msr_ops. Use SMCA-specific msr_ops when on an SMCA-enabled processor. Carved out from a patch by Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com>. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462019637-16474-6-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 38 +++++++++++++++++++++++------------- arch/x86/kernel/cpu/mcheck/mce_amd.c | 10 +++++----- 2 files changed, 29 insertions(+), 19 deletions(-) commit a9750a31efdee79bea4ad1db93cf98a5db6e07ac Author: Yazen Ghannam <Yazen.Ghannam@amd.com> Date: Sat Apr 30 14:33:54 2016 +0200 x86/mce: Define vendor-specific MSR accessors Scalable MCA processors have a whole new range of MSR addresses to obtain bank related info such as CTL, MISC, ADDR, STATUS. Therefore, we need a way to abstract the MSR addresses per vendor. Carved out from a patch by Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com>. Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Ashok Raj <ashok.raj@intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462019637-16474-5-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/mce.h | 15 +++++++++++++ arch/x86/kernel/cpu/mcheck/mce.c | 47 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) commit bb91f8c0176b072aeb6b84cfd7e04084025121e0 Author: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Date: Sat Apr 30 14:33:53 2016 +0200 x86/mce: Carve out writes to MCx_STATUS and MCx_CTL We need to do this after __mcheck_cpu_init_vendor() as for ScalableMCA processors, there are going to be new MSR write handlers if the feature is detected using CPUID bit (which happens in __mcheck_cpu_init_vendor()). No functional change is introduced here. Signed-off-by: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1462019637-16474-4-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 6bda529ec42e1cd4dde1c3d0a1a18000ffd3d419 Author: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Date: Sat Apr 30 14:33:52 2016 +0200 x86/mce: Grade uncorrected errors for SMCA-enabled systems For upcoming processors with Scalable MCA feature, we need to check the "succor" CPUID bit and the TCC bit in the MCx_STATUS register in order to grade an MCE's severity. Signed-off-by: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> [ Simplified code flow, shortened comments. ] Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459886686-13977-3-git-send-email-Yazen.Ghannam@amd.com Link: http://lkml.kernel.org/r/1462019637-16474-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce-severity.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit 10001d91aa0efc793952051f9070a569cc388ebc Author: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Date: Sat Apr 30 14:33:51 2016 +0200 x86/mce: Log MCEs after a warm rest on AMD, Fam17h and later For Fam17h, we want to report errors that persist across reboots. Error persistence is dependent on HW and no BIOS currently fiddles with values here. So allow reporting of errors upon boot until something goes wrong. Logging is disabled on older families because BIOS didn't clear the MCA banks after a cold reset. Signed-off-by: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Signed-off-by: Yazen Ghannam <Yazen.Ghannam@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <aravindksg.lkml@gmail.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459886686-13977-2-git-send-email-Yazen.Ghannam@amd.com Link: http://lkml.kernel.org/r/1462019637-16474-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b33f39e9d17dd7d636ebb38f9ce248f8a085ff49 Merge: bf92b1f 04974df Author: Ingo Molnar <mingo@kernel.org> Date: Tue May 3 08:23:58 2016 +0200 Merge tag 'v4.6-rc6' into ras/core, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 778843f934e362ed4ed734520f60a44a78a074b4 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Mon May 2 16:56:50 2016 +0200 x86/asm/entry/32: Simplify pushes of zeroed pt_regs->REGs Use of a temporary R8 register here seems to be unnecessary. "push %r8" is a two-byte insn (it needs REX prefix to specify R8), "push $0" is two-byte too. It seems just using the latter would be no worse. Thus, code had an unnecessary "xorq %r8,%r8" insn. It probably costs nothing in execution time here since we are probably limited by store bandwidth at this point, but still. Run-tested under QEMU: 32-bit calls still work: / # ./test_syscall_vdso32 [RUN] Executing 6-argument 32-bit syscall via VDSO [OK] Arguments are preserved across syscall [NOTE] R11 has changed:0000000000200ed7 - assuming clobbered by SYSRET insn [OK] R8..R15 did not leak kernel data [RUN] Executing 6-argument 32-bit syscall via INT 80 [OK] Arguments are preserved across syscall [OK] R8..R15 did not leak kernel data [RUN] Running tests under ptrace [RUN] Executing 6-argument 32-bit syscall via VDSO [OK] Arguments are preserved across syscall [NOTE] R11 has changed:0000000000200ed7 - assuming clobbered by SYSRET insn [OK] R8..R15 did not leak kernel data [RUN] Executing 6-argument 32-bit syscall via INT 80 [OK] Arguments are preserved across syscall [OK] R8..R15 did not leak kernel data Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Acked-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Kees Cook <keescook@chromium.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Drewry <wad@chromium.org> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1462201010-16846-1-git-send-email-dvlasenk@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_64_compat.S | 45 +++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 24 deletions(-) commit 00ec2c37031eb1b1feda006c84748d126dc2ef27 Author: Kees Cook <keescook@chromium.org> Date: Mon May 2 15:51:01 2016 -0700 x86/boot: Warn on future overlapping memcpy() use If an overlapping memcpy() is ever attempted, we should at least report it, in case it might lead to problems, so it could be changed to a memmove() call instead. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Lasse Collin <lasse.collin@tukaani.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1462229461-3370-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/string.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit dc425a6e140bca99bdb4823e9909c9d9b8ba36b6 Author: Kees Cook <keescook@chromium.org> Date: Mon May 2 15:51:00 2016 -0700 x86/boot: Extract error reporting functions Currently to use warn(), a caller would need to include misc.h. However, this means they would get the (unavailable during compressed boot) gcc built-in memcpy family of functions. But since string.c is defining these memcpy functions for use by misc.c, we end up in a weird circular dependency. To break this loop, move the error reporting functions outside of misc.c with their own header so that they can be independently included by other sources. Since the screen-writing routines use memmove(), keep the low-level *_putstr() functions in misc.c. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Lasse Collin <lasse.collin@tukaani.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1462229461-3370-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/Makefile | 2 +- arch/x86/boot/compressed/error.c | 22 ++++++++++++++++++++++ arch/x86/boot/compressed/error.h | 7 +++++++ arch/x86/boot/compressed/kaslr.c | 1 + arch/x86/boot/compressed/misc.c | 18 +----------------- arch/x86/boot/compressed/misc.h | 1 - arch/x86/boot/compressed/string.c | 2 ++ 7 files changed, 34 insertions(+), 19 deletions(-) commit 2db00cf5a07b7c543392ff88163428509cda38ae Author: Mark Yao <mark.yao@rock-chips.com> Date: Fri Apr 29 15:39:53 2016 +0800 drm/rockchip: vop: Initialize vskiplines to zero There is a path that use vskiplines with non-initialize. That would cause vop abnormal behavior. Signed-off-by: Mark Yao <mark.yao@rock-chips.com> drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44d0237a26395ac94160cf23f32769013b365590 Author: Mark Yao <mark.yao@rock-chips.com> Date: Fri Apr 29 11:37:20 2016 +0800 drm/rockchip: vop: fix iommu crash with async atomic After async atomic_commit callback, drm_atomic_clean_old_fb will clean all old fb, but because async, the old fb may be also on the vop hardware, dma will access the old fb buffer, clean old fb will cause iommu page fault. Reference the fb and unreference it when the fb actuall swap out from vop hardware. Signed-off-by: Mark Yao <mark.yao@rock-chips.com> drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 2d90d477430d3a20df74f2d11c21378e64e1d508 Author: Mark Yao <mark.yao@rock-chips.com> Date: Tue Apr 19 10:13:27 2016 +0800 drm/rockchip: support non-iommu buffer path Some rockchip vop not support iommu, need use non-iommu buffer for it. And if we get iommu issues, we can compare the issues with non-iommu path, that would help the debug. Signed-off-by: Mark Yao <mark.yao@rock-chips.com> drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 66 ++++++++++++++++++++--------- 1 file changed, 47 insertions(+), 19 deletions(-) commit 4e257d9eee23582e36637ce7ea6b14f6f56b1839 Author: Mark Yao <mark.yao@rock-chips.com> Date: Wed Apr 20 10:41:42 2016 +0800 drm/rockchip: get rid of rockchip_drm_crtc_mode_config We need to take care of the vop status when use rockchip_drm_crtc_mode_config, if vop is disabled, the function would failed, that is terrible. Save output_type and output_mode into rockchip_crtc_state, it's nice to make them into atomic. Signed-off-by: Mark Yao <mark.yao@rock-chips.com> Tested-by: John Keeping <john@metanate.com> drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 48 +++++++++------- drivers/gpu/drm/rockchip/dw-mipi-dsi.c | 38 ++++++++----- drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c | 17 +++++- drivers/gpu/drm/rockchip/inno_hdmi.c | 17 +++++- drivers/gpu/drm/rockchip/rockchip_drm_drv.h | 10 +++- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 75 ++++++++++++++----------- 6 files changed, 128 insertions(+), 77 deletions(-) commit 2743becb3338cf012dbe7b70c6c39bbac81cc101 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Feb 26 00:30:29 2016 +0300 drm/rockchip: inno_hdmi: fix an error code We were accidentally returning PTR_ERR(NULL) which means success when we wanted to return a negative error code. Fixes: 412d4ae6b7a5 ('drm/rockchip: hdmi: add Innosilicon HDMI support') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/rockchip/inno_hdmi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 69b007968e7519cf1e44920f4578054c9e0fbdc3 Author: John Keeping <john@metanate.com> Date: Tue Apr 5 14:50:32 2016 +0100 drm/rockchip: don't leak iommu mapping arm_iommu_attach_device() takes its own reference to the mapping we give it. Since we do not keep a reference to the mapping ourselves, we must release it before returning. Also fix the error path, which fails to release the mapping if it has called arm_iommu_detach_device() since that clears archdata.mapping. Signed-off-by: John Keeping <john@metanate.com> drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit aa1ac27f48de0ed94d5a104e15b5ab62b5deb236 Author: John Keeping <john@metanate.com> Date: Tue Apr 5 14:50:31 2016 +0100 drm/rockchip: remove redundant statement The call to arm_iommu_detach_device() on the previous line sets dev->archdata.mapping to NULL so this call is always a no-op. Signed-off-by: John Keeping <john@metanate.com> drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 1 - 1 file changed, 1 deletion(-) commit ede00a5ceb4d903a8c137a52bb77d574baaef8bd Merge: 9580bf2 9d3f65b Author: David S. Miller <davem@davemloft.net> Date: Tue May 3 00:35:16 2016 -0400 Merge tag 'wireless-drivers-next-for-davem-2016-05-02' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== wireless-drivers patches for 4.7 Major changes: brcmfmac * add support for nl80211 BSS_SELECT feature mwifiex * add platform specific wakeup interrupt support ath10k * implement set_tsf() for 10.2.4 branch * remove rare MSI range support * remove deprecated firmware API 1 support ath9k * add module parameter to invert LED polarity wcn36xx * fixes to get the driver properly working on Dragonboard 410c ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 9580bf2edb402b3afaf9c5a4efb6953f993ef52e Author: Eric Dumazet <edumazet@google.com> Date: Sat Apr 30 10:19:29 2016 -0700 net: relax expensive skb_unclone() in iptunnel_handle_offloads() Locally generated TCP GSO packets having to go through a GRE/SIT/IPIP tunnel have to go through an expensive skb_unclone() Reallocating skb->head is a lot of work. Test should really check if a 'real clone' of the packet was done. TCP does not care if the original gso_type is changed while the packet travels in the stack. This adds skb_header_unclone() which is a variant of skb_clone() using skb_header_cloned() check instead of skb_cloned(). This variant can probably be used from other points. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/skbuff.h | 10 ++++++++++ net/ipv4/ip_tunnel_core.c | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) commit 714c29edf9518a147ab558e2988313d630e061a8 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Wed Apr 27 01:00:21 2016 -0300 ARM: dts: imx6ul-pico-hobbit: Add initial support Add initial support for imx6ul pico hobbit board. For information about this board, please visit: http://www.wandboard.org/images/hobbit/hobbitboard-imx6ul-reva1.pdf Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 516 +++++++++++++++++++++++++++++++ 2 files changed, 517 insertions(+) commit c0ef079ca791ef9e057ac748051425a768c9e192 Author: Florian Westphal <fw@strlen.de> Date: Tue May 3 03:29:09 2016 +0200 netdevice: shrink size of struct netdev_queue - trans_timeout is incremented when tx queue timed out (tx watchdog). - tx_maxrate is set via sysfs Moving tx_maxrate to read-mostly part shrinks the struct by 64 bytes. While at it, also move trans_timeout (it is out-of-place in the 'write-mostly' part). Signed-off-by: Florian Westphal <fw@strlen.de> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit e8194d4fa00dae2ff24983b82780ed0949eaf2fd Merge: d1ac3b1 a60c090 Author: David S. Miller <davem@davemloft.net> Date: Mon May 2 22:27:06 2016 -0400 Merge branch 'bridge-per-vlan-stats' Nikolay Aleksandrov says: ==================== bridge: per-vlan stats This set adds support for bridge per-vlan statistics. In order to be able to dump statistics for many vlans we need a way to continue dumping after reaching maximum size, thus patches 01 and 02 extend the new stats API with a per-device extended link stats attribute and callback which can save its local state and continue where it left off afterwards. I considered using the already existing "fill_xstats" callback but it gets confusing since we need to separate the linkinfo dump from the new stats api dump and adding a flag/argument to do that just looks messy. I don't think the rtnl_link_ops size is an issue, so adding these seemed like the cleaner approach. Patches 03 and 04 add the stats support and netlink dump support respectively. The stats accounting is controlled via a bridge option which is default off, thus the performance impact is kept minimal. I've tested this set with both old and modified iproute2, kmemleak on and some traffic stress tests while adding/removing vlans and ports. v3: - drop the RCU pvid patch and remove one pointer fetch as requested - make stats accounting optional with default to off, the option is in the same cache line as vlan_proto and vlan_enabled, so it is already fetched before the fast path check thus the performance impact is minimal, this also allows us to avoid one vlan lookup and return early when using pvid - rebased and retested v2: - Improve the error checking, rename lidx to prividx and save the current idx user instead of restricting it to one in patch 01 - squash patch 02 into 01 and remove the restriction - add callback descriptions, improve the size calculation and change the xstats message structure to have an embedding level per rtnl link type so we can avoid one call to get the link type (and thus filter on it) and also each link type can now have any number of private attributes inside - fix a problem where the vlan stats are not dumped if the bridge has 0 vlans on it but has vlans on the ports, add bridge link type private attributes and also add paddings for future extensions to avoid at least a few netlink attributes and improve struct alignment - drop the is_skb_forwardable argument constifying patch as it's not needed anymore, but it's a nice cleanup which I'll send separately ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a60c090361ea211625c27052dbbc11c5222e20e4 Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Date: Sat Apr 30 10:25:29 2016 +0200 bridge: netlink: export per-vlan stats Add a new LINK_XSTATS_TYPE_BRIDGE attribute and implement the RTM_GETSTATS callbacks for IFLA_STATS_LINK_XSTATS (fill_linkxstats and get_linkxstats_size) in order to export the per-vlan stats. The paddings were added because soon these fields will be needed for per-port per-vlan stats (or something else if someone beats me to it) so avoiding at least a few more netlink attributes. Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_bridge.h | 18 ++++++++++++ include/uapi/linux/if_link.h | 1 + net/bridge/br_netlink.c | 65 ++++++++++++++++++++++++++++++++++++++++++ net/bridge/br_private.h | 7 +++++ net/bridge/br_vlan.c | 27 ++++++++++++++++++ 5 files changed, 118 insertions(+) commit 6dada9b10a0818ba72c249526a742c8c41274a73 Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Date: Sat Apr 30 10:25:28 2016 +0200 bridge: vlan: learn to count Add support for per-VLAN Tx/Rx statistics. Every global vlan context gets allocated a per-cpu stats which is then set in each per-port vlan context for quick access. The br_allowed_ingress() common function is used to account for Rx packets and the br_handle_vlan() common function is used to account for Tx packets. Stats accounting is performed only if the bridge-wide vlan_stats_enabled option is set either via sysfs or netlink. A struct hole between vlan_enabled and vlan_proto is used for the new option so it is in the same cache line. Currently it is binary (on/off) but it is intentionally restricted to exactly 0 and 1 since other values will be used in the future for different purposes (e.g. per-port stats). Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 1 + net/bridge/br_netlink.c | 13 ++++++- net/bridge/br_private.h | 13 ++++++- net/bridge/br_sysfs_br.c | 17 +++++++++ net/bridge/br_vlan.c | 82 ++++++++++++++++++++++++++++++++++++-------- 5 files changed, 110 insertions(+), 16 deletions(-) commit 97a47facf3468fb6ebd697324fc2a7245755c417 Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Date: Sat Apr 30 10:25:27 2016 +0200 net: rtnetlink: add linkxstats callbacks and attribute Add callbacks to calculate the size and fill link extended statistics which can be split into multiple messages and are dumped via the new rtnl stats API (RTM_GETSTATS) with the IFLA_STATS_LINK_XSTATS attribute. Also add that attribute to the idx mask check since it is expected to be able to save state and resume dumping (e.g. future bridge per-vlan stats will be dumped via this attribute and callbacks). Each link type should nest its private attributes under the per-link type attribute. This allows to have any number of separated private attributes and to avoid one call to get the dev link type. Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/rtnetlink.h | 7 +++++++ include/uapi/linux/if_link.h | 12 ++++++++++++ net/core/rtnetlink.c | 30 ++++++++++++++++++++++++++++++ 3 files changed, 49 insertions(+) commit e8872a25a05efcf0a133ca7ed6511fe9f908dc41 Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Date: Sat Apr 30 10:25:26 2016 +0200 net: rtnetlink: allow rtnl_fill_statsinfo to save private state counter The new prividx argument allows the current dumping device to save a private state counter which would enable it to continue dumping from where it left off. And the idxattr is used to save the current idx user so multiple prividx using attributes can be requested at the same time as suggested by Roopa Prabhu. Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/rtnetlink.c | 44 +++++++++++++++++++++++++++++++------------- 1 file changed, 31 insertions(+), 13 deletions(-) commit 83cb0e4d837af4348cc218638e9d6daddd21d260 Author: MyungJoo Ham <myungjoo.ham@samsung.com> Date: Fri Apr 29 16:13:03 2016 +0900 PM / devfreq: style/typo fixes - Typo in comments fixed - Unnecessary return statement removed Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> drivers/devfreq/exynos-bus.c | 4 ++-- drivers/devfreq/governor_passive.c | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) commit a9d1f4e0cb80b917f68e5b007436d50797c4eeab Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Nov 27 13:03:59 2015 +0900 PM / devfreq: exynos: Add the detailed correlation for Exynos5422 bus This patch adds the detailed corrleation between sub-blocks and power line for Exynos5422. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> .../devicetree/bindings/devfreq/exynos-bus.txt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 19cf91d0f9ddc494217a0abaed91dfbddea7c958 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Apr 14 14:37:12 2016 +0900 PM / devfreq: event: Find the instance of devfreq-event device by using phandle This patch use the phandle to find the instance of devfreq-event device in Device Tree when calling the devfreq_event_get_edev_by_phandle() because there is two type devfreq-event devices as following: First case, exynos-ppmu.c driver provides the maximum four event of each PPMU. So, when getting the instance of devfreq-event device, using the unique name of struct devfreq_event_desc. Second case, exynos-nocp.c driver provide the only one event of each NoC Probe device. So, when getting the instance of devfreq-event device, using the phandle of each NoC probe device. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> drivers/devfreq/devfreq-event.c | 5 +++++ 1 file changed, 5 insertions(+) commit 0179a913875a8b39eaf5b848c876439a3a4650af Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Apr 7 11:29:11 2016 +0900 PM / devfreq: event: Add new Exynos NoC probe driver This patch adds NoC (Network on Chip) Probe driver which provides the primitive values to get the performance data. The packets that the Network on Chip (NoC) probes detects are transported over the network infrastructure. Exynos542x bus has multiple NoC probes to provide bandwidth information about behavior of the SoC that you can use while analyzing system performance. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../bindings/devfreq/event/exynos-nocp.txt | 26 ++ drivers/devfreq/event/Kconfig | 8 + drivers/devfreq/event/Makefile | 2 + drivers/devfreq/event/exynos-nocp.c | 304 +++++++++++++++++++++ drivers/devfreq/event/exynos-nocp.h | 78 ++++++ 5 files changed, 418 insertions(+) commit 490b864ba0724ac464234d6a326b0aa40b75afc7 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Dec 10 11:18:32 2015 +0900 MAINTAINERS: Add samsung bus frequency driver entry This patch adds the 'BUS FREQUENCY DRIVER FOR SAMSUNG EXYNOS' entry to review the patches as maintainer. I can access the all datasheet of Exynos SoC and test it on some Exynos-based board. Patches will be picked up by DEVFREQ maintainer on devfreq git repository. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+) commit bfcd6204871cf63e6833b87cdcfe47d7d2da8a29 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Nov 23 23:58:17 2015 +0900 PM / devfreq: exynos: Remove unused exynos4/5 busfreq driver This patch removes the unused exynos4/5 busfreq driver. Instead, generic exynos-bus frequency driver support the all Exynos SoCs. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/Kconfig | 22 - drivers/devfreq/Makefile | 2 - drivers/devfreq/exynos/Makefile | 3 - drivers/devfreq/exynos/exynos4_bus.c | 1055 ---------------------------------- drivers/devfreq/exynos/exynos4_bus.h | 110 ---- drivers/devfreq/exynos/exynos5_bus.c | 431 -------------- drivers/devfreq/exynos/exynos_ppmu.c | 119 ---- drivers/devfreq/exynos/exynos_ppmu.h | 86 --- 8 files changed, 1828 deletions(-) commit 38279cac36397477d14edf84eff77c8454bc259a Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Nov 27 12:55:23 2015 +0900 PM / devfreq: exynos: Add the detailed correlation between sub-blocks and power line This patch adds the detailed correlation between sub-blocks and power line for Exynos3250, Exynos4210 and Exynos4x12. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../devicetree/bindings/devfreq/exynos-bus.txt | 51 ++++++++++++++++++++++ 1 file changed, 51 insertions(+) commit a296cb5c35ce5429415043a22a385c24673e4aeb Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Mon Nov 23 23:18:52 2015 +0900 PM / devfreq: exynos: Update documentation for bus devices using passive governor This patch updates the documentation for passive bus devices and adds the detailed example of Exynos3250. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../devicetree/bindings/devfreq/exynos-bus.txt | 250 ++++++++++++++++++++- 1 file changed, 247 insertions(+), 3 deletions(-) commit 403e0689d2a9eb33d9281db4079e964eb65ba9ef Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Nov 5 18:29:27 2015 +0900 PM / devfreq: exynos: Add support of bus frequency of sub-blocks using passive governor This patch adds the support of bus frequency feature for sub-blocks which share the one power line. If each bus depends on the power line, each bus is not able to change the voltage by oneself. To optimize the power-consumption on runtime, some buses using the same power line should change the source clock and regulator at the same time. So, this patch uses the passive governor to support the bus frequency for all buses which sharing the one power line. For example, Exynos3250 include the two power line for AXI buses as following: : VDD_MIF : MIF (Memory Interface) provide the DMC (Dynamic Memory Controller) with the power (regulator). : VDD_INT : INT (Internal) provide the various sub-blocks with the power (regulator). Each bus is included in as follwoing block. In the case of VDD_MIF, only DMC bus use the power line. So, there is no any depencency between buese. But, in the case of VDD_INT, various buses share the one power line of VDD_INT. We need to make the depenency between buses. When using passive governor, there is no problem to support the bus frequency as DVFS for all buses. One bus should be operated as the parent bus device which gathering the current load of INT block and then decides the new frequency with some governors except of passive governor. After deciding the new frequency by the parent bus device, the rest bus devices will change the each source clock according to new frequency of the parent bus device. - MIF (Memory Interface) block : VDD_MIF |--- DMC - INT (Internal) block : VDD_INT |--- LEFTBUS (parent) |--- PERIL |--- MFC |--- G3D |--- RIGHTBUS |--- FSYS |--- LCD0 |--- PERIR |--- ISP |--- CAM Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> [tjakobi: Reported debugfs error during booting and cw00.choi fix it.] Reported-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/Kconfig | 1 + drivers/devfreq/exynos-bus.c | 219 ++++++++++++++++++++++++++++++++++--------- 2 files changed, 174 insertions(+), 46 deletions(-) commit 996133119f57334c38b020dbfaaac5b5eb127e29 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Tue Mar 22 13:44:03 2016 +0900 PM / devfreq: Add new passive governor This patch adds the new passive governor for DEVFREQ framework. The following governors are already present and used for DVFS (Dynamic Voltage and Frequency Scaling) drivers. The following governors are independently used for one device driver which don't give the influence to other device drviers and also don't receive the effect from other device drivers. - ondemand / performance / powersave / userspace The passive governor depends on operation of parent driver with specific governos extremely and is not able to decide the new frequency by oneself. According to the decided new frequency of parent driver with governor, the passive governor uses it to decide the appropriate frequency for own device driver. The passive governor must need the following information from device tree: - the source clock and OPP tables - the instance of parent device For exameple, there are one more devfreq device drivers which need to change their source clock according to their utilization on runtime. But, they share the same power line (e.g., regulator). So, specific device driver is operated as parent with ondemand governor and then the rest device driver with passive governor is influenced by parent device. Suggested-by: Myungjoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> [tjakobi: Reported RCU locking issue and cw00.choi fix it] Reported-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> [linux.amoon: Reported possible recursive locking and cw00.choi fix it] Reported-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/Kconfig | 8 ++ drivers/devfreq/Makefile | 1 + drivers/devfreq/governor_passive.c | 207 +++++++++++++++++++++++++++++++++++++ include/linux/devfreq.h | 33 ++++++ 4 files changed, 249 insertions(+) commit 0fe3a66410a3ba96679be903f1e287d7a0a264a9 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Tue Jan 26 13:21:26 2016 +0900 PM / devfreq: Add new DEVFREQ_TRANSITION_NOTIFIER notifier This patch adds the new DEVFREQ_TRANSITION_NOTIFIER notifier to send the notification when the frequency of device is changed. This notifier has two state as following: - DEVFREQ_PRECHANGE : Notify it before chaning the frequency of device - DEVFREQ_POSTCHANGE : Notify it after changed the frequency of device And this patch adds the resourced-managed function to release the resource automatically when error happen. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/devfreq.c | 163 +++++++++++++++++++++++++++++++++++++++++++++- include/linux/devfreq.h | 59 ++++++++++++++++- 2 files changed, 220 insertions(+), 2 deletions(-) commit 8f510aeb223b26c4ffbece9fa92e4befea470f57 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Tue Nov 10 20:31:07 2015 +0900 PM / devfreq: Add devfreq_get_devfreq_by_phandle() This patch adds the new devfreq_get_devfreq_by_phandle() OF helper function which can find the instance of devfreq device by using phandle ("devfreq"). Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/devfreq.c | 44 ++++++++++++++++++++++++++++++++++++++++++++ include/linux/devfreq.h | 9 +++++++++ 2 files changed, 53 insertions(+) commit 72c160bda1dbe75d532502374a6cb6be28990093 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Wed Nov 4 10:52:45 2015 +0900 PM / devfreq: exynos: Add documentation for generic exynos bus frequency driver This patch adds the documentation for generic exynos bus frequency driver. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> .../devicetree/bindings/devfreq/exynos-bus.txt | 95 ++++++++++++++++++++++ 1 file changed, 95 insertions(+) commit 0722249ac1f3dcc3af9e9d7ed89792a68f066660 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Tue Nov 3 19:04:16 2015 +0900 PM / devfreq: exynos: Add generic exynos bus frequency driver This patch adds the generic exynos bus frequency driver for AMBA AXI bus of sub-blocks in exynos SoC with DEVFREQ framework. The Samsung Exynos SoC have the common architecture for bus between DRAM and sub-blocks in SoC. This driver can support the generic bus frequency driver for Exynos SoCs. In devicetree, Each bus block has a bus clock, regulator, operation-point and devfreq-event devices which measure the utilization of each bus block. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> [m.reichl and linux.amoon: Tested it on exynos4412-odroidu3 board] Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/devfreq/Kconfig | 15 ++ drivers/devfreq/Makefile | 1 + drivers/devfreq/exynos-bus.c | 443 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 459 insertions(+) commit dcb0b5575d24a32f51a3f1003312fb94ed4e214a Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Mon May 2 21:30:04 2016 -0400 tracing: Remove TRACE_EVENT_FL_USE_CALL_FILTER logic Nothing sets TRACE_EVENT_FL_USE_CALL_FILTER anymore. Remove it. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 3 -- kernel/trace/trace_events_filter.c | 71 ++++++-------------------------------- 2 files changed, 10 insertions(+), 64 deletions(-) commit c47265ad64fa793657ce7ecf1a8f636c794e9f40 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sun May 1 19:56:08 2016 +0900 clk: fix comment of devm_clk_hw_register() Unlike devm_clk_register(), devm_clk_hw_register() returns integer. So, the statement "Clocks returned from this function ..." sounds odd. Adjust the comment for this new API. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71a553cfa6325f82bf69d5626cdabd628ac05247 Merge: 51de876 d04a75a Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon May 2 17:05:23 2016 -0700 Merge tag 'clk-renesas-for-v4.7-tag3' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into clk-next Pull Renesas clk driver updates from Geert Uytterhoeven: - Support for CSI2 and VIN module clocks on R-Car H3, - Renesas CPG/MSTP and CPG/MSSR Clock Domain fixes. * tag 'clk-renesas-for-v4.7-tag3' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers: clk: renesas: cpg-mssr: Use always-on governor for Clock Domain clk: renesas: cpg-mssr: Postpone call to pm_genpd_init() clk: renesas: mstp: Use always-on governor for Clock Domain clk: renesas: mstp: Postpone call to pm_genpd_init() clk: renesas: r8a7795: Add VIN clocks clk: renesas: r8a7795: Add CSI2 clocks commit 51de8760fb1d4dcfb52dec5aa85b2eb6471808a3 Merge: 5bc7532 ff2bb89 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon May 2 17:03:08 2016 -0700 Merge tag 'sunxi-clocks-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into clk-next Pull Allwinner clock driver updates from Maxime Ripard: As usual, a bunch of clocks patches for 4.7, mostly fixes and cleanups, and display-related clocks. * tag 'sunxi-clocks-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: clk: sunxi: Let divs clocks read the base factor clock name from devicetree clk: sunxi: Add TCON channel1 clock clk: sunxi: Add PLL3 clock dt-bindings: clk: sun5i: add DRAM gates compatible clk: sunxi: Use resource_size clk: sunxi: Add sun6i/8i display support clk: sunxi: mod1 clock should modify it's parent commit 5bc753249719e88c195e84bbf8eca6530507d403 Merge: 5569aed 2690e91 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon May 2 16:53:02 2016 -0700 Merge tag 'tegra-for-4.7-clk' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into clk-next Pull tegra clk driver changes from Thierry Reding: This set of changes contains a bunch of cleanups and minor fixes along with some new clocks, mainly on Tegra210, in preparation for supporting DisplayPort and HDMI 2.0. * tag 'tegra-for-4.7-clk' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: clk: tegra: dfll: Reformat CVB frequency table clk: tegra: dfll: Properly clean up on failure and removal clk: tegra: dfll: Make code more comprehensible clk: tegra: dfll: Reference CVB table instead of copying data clk: tegra: dfll: Update kerneldoc clk: tegra: Fix PLL_U post divider and initial rate on Tegra30 clk: tegra: Initialize PLL_C to sane rate on Tegra30 clk: tegra: Fix pllre Tegra210 and add pll_re_out1 clk: tegra: Add sor_safe clock clk: tegra: dpaux and dpaux1 are fixed factor clocks clk: tegra: Add dpaux1 clock clk: tegra: Use correct parent for dpaux clock clk: tegra: Add fixed factor peripheral clock type clk: tegra: Special-case mipi-cal parent on Tegra114 clk: tegra: Remove trailing blank line clk: tegra: Constify peripheral clock registers clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs commit 9ac3d3e8460e3fa6f3a9a39c2049904005016db6 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 19:52:56 2016 -0400 nfs: switch to ->iterate_shared() aside of the usual care about seeding dcache from readdir, we need to be careful about the pagecache evictions here. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/nfs/dir.c | 71 ++++++++++++++++++++++++++++++++++++------------------------ 1 file changed, 43 insertions(+), 28 deletions(-) commit 9cf843e3f47c41440367062e92ab32e59ecb6a87 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 19:35:16 2016 -0400 lookup_open(): lock the parent shared unless O_CREAT is given Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 3 +++ fs/namei.c | 12 +++++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) commit 6fbd07146d99239547cd4970622c96e9cb0f3213 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 11:50:59 2016 -0400 lookup_open(): put the dentry fed to ->lookup() or ->atomic_open() into in-lookup hash Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 37 ++++++++++++++++++++++++++----------- 1 file changed, 26 insertions(+), 11 deletions(-) commit 12fa5e240419237d848abe3d40809eabe9e8f4ca Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 11:19:43 2016 -0400 lookup_open(): expand the call of real_lookup() ... and lose the duplicate IS_DEADDIR() - we'd already checked that. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 384f26e28fe4ddc75e7cf8e0e21595964d03d8eb Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 28 02:03:55 2016 -0400 atomic_open(): reorder and clean up a bit Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 61 +++++++++++++++++++++++++++---------------------------------- 1 file changed, 27 insertions(+), 34 deletions(-) commit 1643b43fbd0524e7da7259075032936c8fb68a05 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 19:14:10 2016 -0400 lookup_open(): lift the "fallback to !O_CREAT" logics from atomic_open() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 144 +++++++++++++++++++++++-------------------------------------- 1 file changed, 55 insertions(+), 89 deletions(-) commit b3d58eaffb98e1b5bbf2d6756c59398213caba57 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 15:47:45 2016 -0400 atomic_open(): be paranoid about may_open() return value It should never return positives; however, with Linux S&M crowd involved, no bogosity is impossible. Results would be unpleasant... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 2 ++ 1 file changed, 2 insertions(+) commit 0fb1ea0933153180df666f6694855ddfe9408e4a Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 14:13:10 2016 -0400 atomic_open(): delay open_to_namei_flags() until the method call nobody else needs that transformation. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit fe9ec8291fcaa74badf0a67e3a82741b3ee40a9e Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 03:14:20 2016 -0400 do_last(): take fput() on error after opening to out: make it conditional on *opened & FILE_OPENED; in addition to getting rid of exit_fput: thing, it simplifies atomic_open() cleanup on may_open() failure. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) commit 47f9dbd3877d9d9757366278a65d9fb3de5c1c4e Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 02:52:55 2016 -0400 do_last(): get rid of duplicate ELOOP check may_open() will catch it Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 4 ---- 1 file changed, 4 deletions(-) commit 55db2fd9361424a6a5815e7796bcf03b19df437c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 02:36:39 2016 -0400 atomic_open(): massage the create_error logics a bit Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 43 ++++++++++++++++++++----------------------- 1 file changed, 20 insertions(+), 23 deletions(-) commit 9d0728e16e9269f368a6217b34166999c8ba2f3e Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 16:52:17 2016 -0400 atomic_open(): consolidate "overridden ENOENT" in open-yourself cases Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit 5249e411b4d456762641d98eb6aad22da4e0a30d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 27 13:25:33 2016 -0400 atomic_open(): don't bother with EEXIST check - it's done in do_last() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 5 ----- 1 file changed, 5 deletions(-) commit df889b363198d946c0286b3fb2cfcca18d08a029 Merge: ce8644f 10c64ce Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon May 2 19:49:46 2016 -0400 Merge branch 'for-linus' into work.lookups commit ce8644fcadc52da72e19ae9f0866fb3eb15d3df4 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue Apr 26 14:17:56 2016 -0400 lookup_open(): expand the call of vfs_create() Lift IS_DEADDIR handling up into the part common with atomic_open(), remove it from the latter. Collapse permission checks into the call of may_o_create(), getting it closer to atomic_open() case. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) commit 6ac087099edf09ca357e2f765e3e24677543897c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue Apr 26 00:02:50 2016 -0400 path_openat(): take O_PATH handling out of do_last() do_last() and lookup_open() simpler that way and so does O_PATH itself. As it bloody well should: we find what the pathname resolves to, same way as in stat() et.al. and associate it with FMODE_PATH struct file. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) commit 3b0a3c1ac1598722fc289da19219d14f2a37b31f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 23:42:46 2016 -0400 simple local filesystems: switch to ->iterate_shared() no changes needed (XFS isn't simple, but it has the same parallelism in the interesting parts exercised from CXFS). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/affs/dir.c | 2 +- fs/ext2/dir.c | 2 +- fs/minix/dir.c | 2 +- fs/sysv/dir.c | 2 +- fs/ufs/dir.c | 2 +- fs/xfs/xfs_file.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) commit 4e82901cd6d1af21ae232ae835c36d8230c809e8 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 19:52:15 2016 -0400 dcache_{readdir,dir_lseek}() users: switch to ->iterate_shared no need to lock directory in dcache_dir_lseek(), while we are at it - per-struct file exclusion is enough. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> arch/powerpc/platforms/cell/spufs/inode.c | 2 +- fs/autofs4/root.c | 4 ++-- fs/libfs.c | 5 +---- 3 files changed, 4 insertions(+), 7 deletions(-) commit 3125d2650cae97d8f313ab696cd0ed66916e767a Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 17:40:47 2016 -0400 cifs: switch to ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifsfs.c | 2 +- fs/cifs/readdir.c | 55 +++++++++++++++++++++++++++++-------------------------- 2 files changed, 30 insertions(+), 27 deletions(-) commit d9b3dbdcfd6213731c3eb985a3a83537e3894e12 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 17:30:32 2016 -0400 fuse: switch to ->iterate_shared() Switch dcache pre-seeding on readdir to d_alloc_parallel(); nothing else is needed. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/fuse/dir.c | 94 ++++++++++++++++++++++++++++------------------------------- 1 file changed, 45 insertions(+), 49 deletions(-) commit f50752eaa0b0be05431897a973b2ab05229cc2f5 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 17:13:54 2016 -0400 switch all procfs directories ->iterate_shared() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/proc/base.c | 20 ++++++++++---------- fs/proc/fd.c | 8 ++++---- fs/proc/generic.c | 2 +- fs/proc/namespaces.c | 3 ++- fs/proc/proc_net.c | 2 +- fs/proc/proc_sysctl.c | 2 +- fs/proc/root.c | 4 ++-- 7 files changed, 21 insertions(+), 20 deletions(-) commit 76aab3ab61f3051362f20fc26e2c50a65d6ba904 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 16:36:09 2016 -0400 proc_sys_fill_cache(): switch to d_alloc_parallel() make it usable with directory locked shared Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/proc/proc_sysctl.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 3781764b5cb109152af180a4f17cd3a24d5bc51f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 16:31:31 2016 -0400 proc_fill_cache(): switch to d_alloc_parallel() ... making it usable with directory locked shared Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/proc/base.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 6192269444ebfbfb42e23c7a6a93c76ffe4b5e51 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 23:08:32 2016 -0400 introduce a parallel variant of ->iterate() New method: ->iterate_shared(). Same arguments as in ->iterate(), called with the directory locked only shared. Once all filesystems switch, the old one will be gone. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 18 ++++++++++++++++++ fs/coda/dir.c | 18 ++++++++++++------ fs/exportfs/expfs.c | 2 +- fs/readdir.c | 20 ++++++++++++++++---- include/linux/fs.h | 1 + 5 files changed, 48 insertions(+), 11 deletions(-) commit 63b6df14134ddd048984c8afadb46e721815bfc6 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Wed Apr 20 17:08:21 2016 -0400 give readdir(2)/getdents(2)/etc. uniform exclusion with lseek() same as read() on regular files has, and for the same reason. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> arch/alpha/kernel/osf_sys.c | 4 ++-- fs/compat.c | 12 ++++++------ fs/file.c | 5 +++++ fs/open.c | 2 +- fs/read_write.c | 12 ------------ fs/readdir.c | 12 ++++++------ include/linux/file.h | 13 +++++++++++++ 7 files changed, 33 insertions(+), 27 deletions(-) commit 9902af79c01a8e39bb99b922fa3eef6d4ea23d69 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 15 15:08:36 2016 -0400 parallel lookups: actual switch to rwsem ta-da! The main issue is the lack of down_write_killable(), so the places like readdir.c switched to plain inode_lock(); once killable variants of rwsem primitives appear, that'll be dealt with. lockdep side also might need more work Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 18 ++++++++++++++++++ fs/btrfs/ioctl.c | 18 +++++++++++------- fs/configfs/inode.c | 2 +- fs/dcache.c | 9 +++++---- fs/gfs2/ops_fstype.c | 2 +- fs/inode.c | 12 ++++++------ fs/namei.c | 4 ++-- fs/ocfs2/inode.c | 2 +- fs/overlayfs/readdir.c | 4 +++- fs/readdir.c | 7 ++++--- include/linux/fs.h | 27 +++++++++++++++++++++------ 11 files changed, 73 insertions(+), 32 deletions(-) commit d9171b9345261e0d941d92fdda5672b5db67f968 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 15 03:33:13 2016 -0400 parallel lookups machinery, part 4 (and last) If we *do* run into an in-lookup match, we need to wait for it to cease being in-lookup. Fortunately, we do have unused space in in-lookup dentries - d_lru is never looked at until it stops being in-lookup. So we can stash a pointer to wait_queue_head from stack frame of the caller of ->lookup(). Some precautions are needed while waiting, but it's not that hard - we do hold a reference to dentry we are waiting for, so it can't go away. If it's found to be in-lookup the wait_queue_head is still alive and will remain so at least while ->d_lock is held. Moreover, the condition we are waiting for becomes true at the same point where everything on that wq gets woken up, so we can just add ourselves to the queue once. d_alloc_parallel() gets a pointer to wait_queue_head_t from its caller; lookup_slow() adjusted, d_add_ci() taught to use d_alloc_parallel() if the dentry passed to it happens to be in-lookup one (i.e. if it's been called from the parallel lookup). That's pretty much it - all that remains is to switch ->i_mutex to rwsem and have lookup_slow() take it shared. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 94 +++++++++++++++++++++++++++++++++++++++----------- fs/namei.c | 3 +- include/linux/dcache.h | 8 +++-- 3 files changed, 82 insertions(+), 23 deletions(-) commit 94bdd655caba2080ae81d83d756d325abdffcb9f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 15 02:42:04 2016 -0400 parallel lookups machinery, part 3 We will need to be able to check if there is an in-lookup dentry with matching parent/name. Right now it's impossible, but as soon as start locking directories shared such beasts will appear. Add a secondary hash for locating those. Hash chains go through the same space where d_alias will be once it's not in-lookup anymore. Search is done under the same bitlock we use for modifications - with the primary hash we can rely on d_rehash() into the wrong chain being the worst that could happen, but here the pointers are buggered once it's removed from the chain. On the other hand, the chains are not going to be long and normally we'll end up adding to the chain anyway. That allows us to avoid bothering with ->d_lock when doing the comparisons - everything is stable until removed from chain. New helper: d_alloc_parallel(). Right now it allocates, verifies that no hashed and in-lookup matches exist and adds to in-lookup hash. Returns ERR_PTR() for error, hashed match (in the unlikely case it's been found) or new dentry. In-lookup matches trigger BUG() for now; that will change in the next commit when we introduce waiting for ongoing lookup to finish. Note that in-lookup matches won't be possible until we actually go for shared locking. lookup_slow() switched to use of d_alloc_parallel(). Again, these commits are separated only for making it easier to review. All this machinery will start doing something useful only when we go for shared locking; it's just that the combination is too large for my taste. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 104 +++++++++++++++++++++++++++++++++++++++++++++++++ fs/namei.c | 44 +++++++++------------ include/linux/dcache.h | 2 + 3 files changed, 125 insertions(+), 25 deletions(-) commit 84e710da2a1dfacfc87f604869a4d22df91ce6cd Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 15 00:58:55 2016 -0400 parallel lookups machinery, part 2 We'll need to verify that there's neither a hashed nor in-lookup dentry with desired parent/name before adding to in-lookup set. One possible solution would be to hold the parent's ->d_lock through both checks, but while the in-lookup set is relatively small at any time, dcache is not. And holding the parent's ->d_lock through something like __d_lookup_rcu() would suck too badly. So we leave the parent's ->d_lock alone, which means that we watch out for the following scenario: * we verify that there's no hashed match * existing in-lookup match gets hashed by another process * we verify that there's no in-lookup matches and decide that everything's fine. Solution: per-directory kinda-sorta seqlock, bumped around the times we hash something that used to be in-lookup or move (and hash) something in place of in-lookup. Then the above would turn into * read the counter * do dcache lookup * if no matches found, check for in-lookup matches * if there had been none of those either, check if the counter has changed; repeat if it has. The "kinda-sorta" part is due to the fact that we don't have much spare space in inode. There is a spare word (shared with i_bdev/i_cdev/i_pipe), so the counter part is not a problem, but spinlock is a different story. We could use the parent's ->d_lock, and it would be less painful in terms of contention, for __d_add() it would be rather inconvenient to grab; we could do that (using lock_parent()), but... Fortunately, we can get serialization on the counter itself, and it might be a good idea in general; we can use cmpxchg() in a loop to get from even to odd and smp_store_release() from odd to even. This commit adds the counter and updating logics; the readers will be added in the next commit. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 8 ++++++++ fs/dcache.c | 34 ++++++++++++++++++++++++++++++++-- fs/inode.c | 1 + include/linux/fs.h | 1 + mm/shmem.c | 3 ++- 5 files changed, 44 insertions(+), 3 deletions(-) commit 85c7f81041d57cfe9dc97f4680d5586b54534a39 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 14 19:52:13 2016 -0400 beginning of transition to parallel lookups - marking in-lookup dentries marked as such when (would be) parallel lookup is about to pass them to actual ->lookup(); unmarked when * __d_add() is about to make it hashed, positive or not. * __d_move() (from d_splice_alias(), directly or via __d_unalias()) puts a preexisting dentry in its place * in caller of ->lookup() if it has escaped all of the above. Bug (WARN_ON, actually) if it reaches the final dput() or d_instantiate() while still marked such. As the result, we are guaranteed that for as long as the flag is set, dentry will * remain negative unhashed with positive refcount * never have its ->d_alias looked at * never have its ->d_lru looked at * never have its ->d_parent and ->d_name changed Right now we have at most one such for any given parent directory. With parallel lookups that restriction will weaken to * only exist when parent is locked shared * at most one with given (parent,name) pair (comparison of names is according to ->d_compare()) * only exist when there's no hashed dentry with the same (parent,name) Transition will take the next several commits; unfortunately, we'll only be able to switch to rwsem at the end of this series. The reason for not making it a single patch is to simplify review. New primitives: d_in_lookup() (a predicate checking if dentry is in the in-lookup state) and d_lookup_done() (tells the system that we are done with lookup and if it's still marked as in-lookup, it should cease to be such). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 13 +++++++++++++ fs/namei.c | 4 ++++ include/linux/dcache.h | 18 ++++++++++++++++++ 3 files changed, 35 insertions(+) commit 0568d705b0087751f0c085c0a665aa3e954c810d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 14 19:40:56 2016 -0400 __d_add(): don't drop/regain ->d_lock Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 1936386ea96591c27ae4b70caef9591c41e6290f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 14 19:33:34 2016 -0400 lookup_slow(): bugger off on IS_DEADDIR() from the very beginning Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) commit d2caaa0a7745eed3a827e919a37470d34b8fc20d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Apr 30 16:38:39 2016 -0400 nfs: missing wakeup in nfs_unblock_sillyrename() will be needed as soon as lookups are not serialized by ->i_mutex Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/nfs/unlink.c | 1 + 1 file changed, 1 insertion(+) commit be5b82dbfec2a900925da4437af3c60b61f4c53d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 22 15:06:44 2016 -0400 make ext2_get_page() and friends work without external serialization Right now ext2_get_page() (and its analogues in a bunch of other filesystems) relies upon the directory being locked - the way it sets and tests Checked and Error bits would be racy without that. Switch to a slightly different scheme, _not_ setting Checked in case of failure. That way the logics becomes if Checked => OK else if Error => fail else if !validate => fail else => OK with validation setting Checked or Error on success and failure resp. and returning which one had happened. Equivalent to the current logics, but unlike the current logics not sensitive to the order of set_bit, test_bit getting reordered by CPU, etc. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/afs/dir.c | 14 +++++++------- fs/exofs/dir.c | 14 +++++++------- fs/ext2/dir.c | 14 +++++++------- fs/nilfs2/dir.c | 14 +++++++------- fs/ufs/dir.c | 14 +++++++------- 5 files changed, 35 insertions(+), 35 deletions(-) commit b9e1d435fdf4ae0b925070d44b65d608f2707688 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 14 19:20:29 2016 -0400 ovl_lookup_real(): use lookup_one_len_unlocked() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/overlayfs/super.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 383d4e8ab02c02f7b31f90174c644d935c223c85 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Apr 14 19:12:42 2016 -0400 reconnect_one(): use lookup_one_len_unlocked() ... and explain the non-obvious logics in case when lookup yields a different dentry. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/exportfs/expfs.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 1ae1f3f64735905d1751a64ae4b05b9509486612 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Apr 15 14:44:31 2016 -0400 reiserfs: open-code reiserfs_mutex_lock_safe() in reiserfs_unpack() ... and have it use inode_lock() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/reiserfs/ioctl.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 5ecfcb265f1e77d5de0140d21de3f8ab25441df7 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue Apr 12 00:43:20 2016 -0400 orangefs: don't open-code inode_lock/inode_unlock Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/orangefs/file.c | 4 ++-- fs/orangefs/orangefs-kernel.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7b9743eb8932cee1bc646725a6364ccb29d86a2c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue Apr 12 00:41:01 2016 -0400 ocfs2: don't open-code inode_lock/inode_unlock Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ocfs2/aops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 48f35b7b7367c6c2594f9c209ee2e1362519a899 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Tue Apr 12 00:37:59 2016 -0400 configfs_detach_prep(): make sure that wait_mutex won't go away grab a reference to dentry we'd got the sucker from, and return that dentry via *wait, rather than just returning the address of ->i_mutex. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/configfs/dir.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 779b839133d7ab23229be7e601cabab7678ceab1 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon Apr 11 08:42:55 2016 -0400 kernfs: use lookup_one_len_unlocked() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/kernfs/mount.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit b96809173e94ea2fa8c19c2e40e8545a1821bf57 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon Apr 11 00:53:26 2016 -0400 security_d_instantiate(): move to the point prior to attaching dentry to inode Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit 84695ffee7987ee1e581be4c4696e47e1a29403b Merge: bf16200 ce23e64 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon May 2 19:45:47 2016 -0400 Merge getxattr prototype change into work.lookups The rest of work.xattr stuff isn't needed for this branch commit 5569aedf1dd82cc1e4d8d19f4424c2034583cb2a Merge: 58657d1 fd8bc82 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon May 2 16:43:03 2016 -0700 Merge tag 'v4.7-rockchip-clk3' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-next Pull rockchip clk updates from Heiko Stuebner: A spelling fix and a bunch of rk3399 clock fixes. * tag 'v4.7-rockchip-clk3' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: fix the rk3399 cifout clock clk: rockchip: drop unnecessary CLK_IGNORE_UNUSED flags from rk3399 clk: rockchip: add some frequencies on the rk3399 PLL table clk: rockchip: assign more necessary rk3399 clock ids clk: rockchip: export some necessary rk3399 clock ids clk: rockchip: rename rga clock-id on rk3399 clk: rockchip: add general gpu soft-reset on rk3399 clk: rockchip: fix the gate bit for i2c4 and i2c8 on rk3399 clk: rockchip: fix of spelling mistake on unsuccessful in pll clock type commit d1ac3b16d535019b7da6fd81d81a469e72d5c3dd Merge: 570d632 b05229f Author: David S. Miller <davem@davemloft.net> Date: Mon May 2 19:23:32 2016 -0400 Merge branch 'ipv6-tunnel-cleanups' Tom Herbert says: ==================== net: Cleanup IPv6 ip tunnels The IPv6 tunnel code is very different from IPv4 code. There is a lot of redundancy with the IPv4 code, particularly in the GRE tunneling. This patch set cleans up the tunnel code to make the IPv6 code look more like the IPv4 code and use common functions between the two stacks where possible. This work should make it easier to maintain and extend the IPv6 ip tunnels. Items in this patch set: - Cleanup IPv6 tunnel receive path (ip6_tnl_rcv). Includes using gro_cells and exporting ip6_tnl_rcv so the ip6_gre can call it - Move GRE functions to common header file (tx functions) or gre_demux.c (rx functions like gre_parse_header) - Call common GRE functions from IPv6 GRE - Create ip6_tnl_xmit (to be like ip_tunnel_xmit) Tested: Ran super_netperf tests for TCP_RR and TCP_STREAM for: - IPv4 over gre, gretap, gre6, gre6tap - IPv6 over gre, gretap, gre6, gre6tap - ipip - ip6ip6 - ipip/gue - IPv6 over gre/gue - IPv4 over gre/gue ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b05229f442288210f2b1f5b4b2a9d71836e90686 Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:21 2016 -0700 gre6: Cleanup GREv6 transmit path, call common GRE functions Changes in GREv6 transmit path: - Call gre_checksum, remove gre6_checksum - Rename ip6gre_xmit2 to __gre6_xmit - Call gre_build_header utility function - Call ip6_tnl_xmit common function - Call ip6_tnl_change_mtu, eliminate ip6gre_tunnel_change_mtu Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 252 +++++++++++------------------------------------------ 1 file changed, 50 insertions(+), 202 deletions(-) commit 79ecb90e65f33d1941ac1f8e43eec34ec3bdbad8 Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:20 2016 -0700 ipv6: Generic tunnel cleanup A few generic changes to generalize tunnels in IPv6: - Export ip6_tnl_change_mtu so that it can be called by ip6_gre - Add tun_hlen to ip6_tnl structure. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip6_tunnel.h | 5 ++++- net/ipv6/ip6_tunnel.c | 7 +++++-- 2 files changed, 9 insertions(+), 3 deletions(-) commit 182a352d2d5e0b435f7856c0cc23d467dcec55ef Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:19 2016 -0700 gre: Create common functions for transmit Create common functions for both IPv4 and IPv6 GRE in transmit. These are put into gre.h. Common functions are for: - GRE checksum calculation. Move gre_checksum to gre.h. - Building a GRE header. Move GRE build_header and rename gre_build_header. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/gre.h | 44 ++++++++++++++++++++++++++++++++++++++++++++ net/ipv4/ip_gre.c | 52 +++++----------------------------------------------- 2 files changed, 49 insertions(+), 47 deletions(-) commit 8eb30be0352d09165e94a41fef1c7b994dca0714 Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:18 2016 -0700 ipv6: Create ip6_tnl_xmit This patch renames ip6_tnl_xmit2 to ip6_tnl_xmit and exports it. Other users like GRE will be able to call this. The original ip6_tnl_xmit function is renamed to ip6_tnl_start_xmit (this is an ndo_start_xmit function). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip6_tunnel.h | 2 ++ net/ipv6/ip6_tunnel.c | 47 ++++++++++++++++++++++++++++++----------------- 2 files changed, 32 insertions(+), 17 deletions(-) commit 308edfdf1563f78e93ebda9aee608279de1c5898 Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:17 2016 -0700 gre6: Cleanup GREv6 receive path, call common GRE functions - Create gre_rcv function. This calls gre_parse_header and ip6gre_rcv. - Call ip6_tnl_rcv. Doing this and using gre_parse_header eliminates most of the code in ip6gre_rcv. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 140 +++++++++-------------------------------------------- 1 file changed, 23 insertions(+), 117 deletions(-) commit 95f5c64c3c13a609e137d35c4b452519e0b954df Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:16 2016 -0700 gre: Move utility functions to common headers Several of the GRE functions defined in net/ipv4/ip_gre.c are usable for IPv6 GRE implementation (that is they are protocol agnostic). These include: - GRE flag handling functions are move to gre.h - GRE build_header is moved to gre.h and renamed gre_build_header - parse_gre_header is moved to gre_demux.c and renamed gre_parse_header - iptunnel_pull_header is taken out of gre_parse_header. This is now done by caller. The header length is returned from gre_parse_header in an int* argument. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/gre.h | 60 +++++++++++++++++++++ net/ipv4/gre_demux.c | 64 ++++++++++++++++++++++ net/ipv4/ip_gre.c | 149 +++++++-------------------------------------------- 3 files changed, 144 insertions(+), 129 deletions(-) commit 0d3c703a9d1723c7707e0680019ac8ff5922db42 Author: Tom Herbert <tom@herbertland.com> Date: Fri Apr 29 17:12:15 2016 -0700 ipv6: Cleanup IPv6 tunnel receive path Some basic changes to make IPv6 tunnel receive path look more like IPv4 path: - Make ip6_tnl_rcv non-static so that GREv6 and others can call it - Make ip6_tnl_rcv look like ip_tunnel_rcv - Switch to gro_cells_receive - Make ip6_tnl_rcv non-static and export it Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip6_tunnel.h | 4 + net/ipv6/ip6_tunnel.c | 212 +++++++++++++++++++++++++++++++---------------- 2 files changed, 146 insertions(+), 70 deletions(-) commit 0cd3e27476620176c19e346f82576c6e139b85a9 Author: Eric Anholt <eric@anholt.net> Date: Thu Apr 14 23:16:05 2016 -0700 drm/vc4: Add missing render node support There shouldn't be any other driver support necessary, since none of the driver-specific ioctls ever required auth, and none of them deal with modesetting. Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/vc4/vc4_drv.c | 1 + 1 file changed, 1 insertion(+) commit e582b6c7e7f9d0b1e30e8017e4082d3a9ede3310 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 18:38:20 2016 -0700 drm/vc4: Add support for gamma ramps. We could possibly save a bit of power by not requesting gamma conversion when the ramp happens to be 1:1, but at least if all the CRTCs are off the SRAM will be disabled. This should fix brightness sliders in a lot of fullscreen games. Signed-off-by: Eric Anholt <eric@anholt.net> drivers/gpu/drm/vc4/vc4_crtc.c | 58 ++++++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/vc4/vc4_regs.h | 6 +++++ 2 files changed, 64 insertions(+) commit fcbcb3b0cf9f73742426877ff56d63f12fd92c12 Author: Robert Foss <robert.foss@collabora.com> Date: Mon May 2 15:13:01 2016 -0400 drm/docs: Move "scaling mode" property. The "scaling mode" property has been moved to the DRM->Generic. It has also had a list of supported drivers added to it. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Robert Foss <robert.foss@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1462216381-10160-1-git-send-email-robert.foss@collabora.com Documentation/DocBook/gpu.tmpl | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) commit a5cb903aef8c642e6f0f6810d46dacedf666b54a Author: Gabriele Paoloni <gabriele.paoloni@huawei.com> Date: Sat Apr 16 12:03:39 2016 +0100 PCI: designware: Remove incorrect RC memory base/limit configuration Currently dw_pcie_setup_rc() configures memory base and memory limit in the type1 configuration header for the root complex. In doing so it uses the CPU address (pp->mem_base) rather than the bus address (pp->mem_bus_addr). This is wrong and it is useless since the configuration is overwritten later on when pci_bus_assign_resources() is called. Remove this configuration from dw_pcie_setup_rc(). Signed-off-by: Gabriele Paoloni <gabriele.paoloni@huawei.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Pratyush Anand <pratyush.anand@gmail.com> drivers/pci/host/pcie-designware.c | 8 -------- 1 file changed, 8 deletions(-) commit 570d632008fc2c7b17f55db44179fb9a03d107c4 Merge: 5e59c83 d41a69f Author: David S. Miller <davem@davemloft.net> Date: Mon May 2 17:02:26 2016 -0400 Merge branch 'tcp-preempt' Eric Dumazet says: ==================== net: make TCP preemptible Most of TCP stack assumed it was running from BH handler. This is great for most things, as TCP behavior is very sensitive to scheduling artifacts. However, the prequeue and backlog processing are problematic, as they need to be flushed with BH being blocked. To cope with modern needs, TCP sockets have big sk_rcvbuf values, in the order of 16 MB, and soon 32 MB. This means that backlog can hold thousands of packets, and things like TCP coalescing or collapsing on this amount of packets can lead to insane latency spikes, since BH are blocked for too long. It is time to make UDP/TCP stacks preemptible. Note that fast path still runs from BH handler. v2: Added "tcp: make tcp_sendmsg() aware of socket backlog" to reduce latency problems of large sends. v3: Fixed a typo in tcp_cdg.c ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d41a69f1d390fa3f2546498103cdcd78b30676ff Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:53 2016 -0700 tcp: make tcp_sendmsg() aware of socket backlog Large sendmsg()/write() hold socket lock for the duration of the call, unless sk->sk_sndbuf limit is hit. This is bad because incoming packets are parked into socket backlog for a long time. Critical decisions like fast retransmit might be delayed. Receivers have to maintain a big out of order queue with additional cpu overhead, and also possible stalls in TX once windows are full. Bidirectional flows are particularly hurt since the backlog can become quite big if the copy from user space triggers IO (page faults) Some applications learnt to use sendmsg() (or sendmmsg()) with small chunks to avoid this issue. Kernel should know better, right ? Add a generic sk_flush_backlog() helper and use it right before a new skb is allocated. Typically we put 64KB of payload per skb (unless MSG_EOR is requested) and checking socket backlog every 64KB gives good results. As a matter of fact, tests with TSO/GSO disabled give very nice results, as we manage to keep a small write queue and smaller perceived rtt. Note that sk_flush_backlog() maintains socket ownership, so is not equivalent to a {release_sock(sk); lock_sock(sk);}, to ensure implicit atomicity rules that sendmsg() was giving to (possibly buggy) applications. In this simple implementation, I chose to not call tcp_release_cb(), but we might consider this later. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Alexei Starovoitov <ast@fb.com> Cc: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 11 +++++++++++ net/core/sock.c | 7 +++++++ net/ipv4/tcp.c | 8 ++++++-- 3 files changed, 24 insertions(+), 2 deletions(-) commit 5413d1babe8f10de13d72496c12b862eef8ba613 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:52 2016 -0700 net: do not block BH while processing socket backlog Socket backlog processing is a major latency source. With current TCP socket sk_rcvbuf limits, I have sampled __release_sock() holding cpu for more than 5 ms, and packets being dropped by the NIC once ring buffer is filled. All users are now ready to be called from process context, we can unblock BH and let interrupts be serviced faster. cond_resched_softirq() could be removed, as it has no more user. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/sock.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit 860fbbc343bf05a71b31555579ff4878194be01b Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:51 2016 -0700 sctp: prepare for socket backlog behavior change sctp_inq_push() will soon be called without BH being blocked when generic socket code flushes the socket backlog. It is very possible SCTP can be converted to not rely on BH, but this needs to be done by SCTP experts. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/inqueue.c | 2 ++ 1 file changed, 2 insertions(+) commit e61da9e259ef887bd516ab08dfdf1c1261017e8e Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:50 2016 -0700 udp: prepare for non BH masking at backlog processing UDP uses the generic socket backlog code, and this will soon be changed to not disable BH when protocol is called back. We need to use appropriate SNMP accessors. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/udp.c | 4 ++-- net/ipv6/udp.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7309f8821fd65e8272ce82e852532b02967812da Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:49 2016 -0700 dccp: do not assume DCCP code is non preemptible DCCP uses the generic backlog code, and this will soon be changed to not disable BH when protocol is called back. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/dccp/input.c | 2 +- net/dccp/ipv4.c | 4 ++-- net/dccp/ipv6.c | 4 ++-- net/dccp/options.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) commit fb3477c0f45aad5dfb2de559949872770e6cd431 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:48 2016 -0700 tcp: do not block bh during prequeue processing AFAIK, nothing in current TCP stack absolutely wants BH being disabled once socket is owned by a thread running in process context. As mentioned in my prior patch ("tcp: give prequeue mode some care"), processing a batch of packets might take time, better not block BH at all. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp.c | 4 ---- net/ipv4/tcp_input.c | 30 ++---------------------------- 2 files changed, 2 insertions(+), 32 deletions(-) commit c10d9310edf5aa4a676991139d1a43ec7d87e56b Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 29 14:16:47 2016 -0700 tcp: do not assume TCP code is non preemptible We want to to make TCP stack preemptible, as draining prequeue and backlog queues can take lot of time. Many SNMP updates were assuming that BH (and preemption) was disabled. Need to convert some __NET_INC_STATS() calls to NET_INC_STATS() and some __TCP_INC_STATS() to TCP_INC_STATS() Before using this_cpu_ptr(net->ipv4.tcp_sk) in tcp_v4_send_reset() and tcp_v4_send_ack(), we add an explicit preempt disabled section. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp.c | 2 +- net/ipv4/tcp_cdg.c | 20 +++++----- net/ipv4/tcp_cubic.c | 20 +++++----- net/ipv4/tcp_fastopen.c | 12 +++--- net/ipv4/tcp_input.c | 96 ++++++++++++++++++++++++------------------------ net/ipv4/tcp_ipv4.c | 14 ++++--- net/ipv4/tcp_minisocks.c | 2 +- net/ipv4/tcp_output.c | 11 +++--- net/ipv4/tcp_recovery.c | 4 +- net/ipv4/tcp_timer.c | 10 +++-- net/ipv6/tcp_ipv6.c | 12 +++--- 11 files changed, 104 insertions(+), 99 deletions(-) commit 866daf6eaae36b414764c4830ed197da9801a361 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 26 09:35:42 2016 +0200 wext: remove a/b/g/n from SIOCGIWNAME Since a/b/g/n no longer exist as spec amendements and VHT (ex 802.11ac) wasn't handled at all, it's better to just remove the amendment strings to avoid confusion. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Reviewed-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/wireless/wext-compat.c | 35 ----------------------------------- 1 file changed, 35 deletions(-) commit 5e59c83f2335d634946e1a4fe7bc1e921930f132 Merge: 582a1db 6619ac5 Author: David S. Miller <davem@davemloft.net> Date: Mon May 2 16:47:55 2016 -0400 Merge branch 'xgene-channel-number' Iyappan Subramanian says: ==================== drivers: net: xgene: fix: Get channel number from device binding This patch set adds 'channel' property to get ethernet to CPU channel number, thus decoupling the Linux driver from static resource selection. v2: Address review comments from v1 - removed irq reference from Linux driver - added 'channel' property to get ethernet to CPU channel number v1: - Initial version ==================== Signed-off-by: Iyappan Subramanian <isubramanian@apm.com> Signed-off-by: David S. Miller <davem@davemloft.net> commit 6619ac5a440961536c167dbc10596a26e9288915 Author: Iyappan Subramanian <isubramanian@apm.com> Date: Fri Apr 29 11:10:15 2016 -0700 dtb: xgene: Add channel property Added 'channel' property, describing ethernet to CPU channel number. Signed-off-by: Iyappan Subramanian <isubramanian@apm.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/boot/dts/apm/apm-shadowcat.dtsi | 1 + arch/arm64/boot/dts/apm/apm-storm.dtsi | 1 + 2 files changed, 2 insertions(+) commit 4cac949f59a133df11d88bc3d1512786507b02bf Author: Iyappan Subramanian <isubramanian@apm.com> Date: Fri Apr 29 11:10:14 2016 -0700 Documentation: dtb: xgene: Add channel property Signed-off-by: Iyappan Subramanian <isubramanian@apm.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/devicetree/bindings/net/apm-xgene-enet.txt | 2 ++ 1 file changed, 2 insertions(+) commit 2a37daa634416a617bb8e9032626ab491004e7da Author: Iyappan Subramanian <isubramanian@apm.com> Date: Fri Apr 29 11:10:13 2016 -0700 drivers: net: xgene: Get channel number from device binding This patch gets ethernet to CPU channel (prefetch buffer number) from the newly added 'channel' property, thus decoupling Linux driver from resource management. Signed-off-by: Iyappan Subramanian <isubramanian@apm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/apm/xgene/xgene_enet_main.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit deb22e5c84c884a129d801cf3bfde7411536998d Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Fri Apr 29 11:39:10 2016 +0200 PCI: hv: Report resources release after stopping the bus Kernel hang is observed when pci-hyperv module is release with device drivers still attached. E.g., when I do 'rmmod pci_hyperv' with BCM5720 device pass-through-ed (tg3 module) I see the following: NMI watchdog: BUG: soft lockup - CPU#1 stuck for 22s! [rmmod:2104] ... Call Trace: [<ffffffffa0641487>] tg3_read_mem+0x87/0x100 [tg3] [<ffffffffa063f000>] ? 0xffffffffa063f000 [<ffffffffa0644375>] tg3_poll_fw+0x85/0x150 [tg3] [<ffffffffa0649877>] tg3_chip_reset+0x357/0x8c0 [tg3] [<ffffffffa064ca8b>] tg3_halt+0x3b/0x190 [tg3] [<ffffffffa0657611>] tg3_stop+0x171/0x230 [tg3] ... [<ffffffffa064c550>] tg3_remove_one+0x90/0x140 [tg3] [<ffffffff813bee59>] pci_device_remove+0x39/0xc0 [<ffffffff814a3201>] __device_release_driver+0xa1/0x160 [<ffffffff814a32e3>] device_release_driver+0x23/0x30 [<ffffffff813b794a>] pci_stop_bus_device+0x8a/0xa0 [<ffffffff813b7ab6>] pci_stop_root_bus+0x36/0x60 [<ffffffffa02c3f38>] hv_pci_remove+0x238/0x260 [pci_hyperv] The problem seems to be that we report local resources release before stopping the bus and removing devices from it and device drivers may try to perform some operations with these resources on shutdown. Move resources release report after we do pci_stop_root_bus(). Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Jake Oshins <jakeo@microsoft.com> drivers/pci/host/pci-hyperv.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit e298c499cac1f175694f4ccfe5b532e5098b4716 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Mon May 2 13:49:14 2016 +0200 ia64: Remove superfluous SMP function call Since commit 3b9d6da67e11 ("cpu/hotplug: Fix rollback during error-out in __cpu_disable()") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this SMP function calls are no longer required. Replace smp_call_function_single() with a direct call to ia64_mca_cmc_vector_adjust(). The function itselfs handles disable and enable interrupts, therefore the smp_call_function_single() calling convention is not preserved. Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: linux-ia64@vger.kernel.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Signed-off-by: Tony Luck <tony.luck@intel.com> arch/ia64/kernel/mca.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 4bcf7414528a6b7ca52d28953a732a4cf36063e8 Author: Sebastian Reichel <sre@kernel.org> Date: Sun Jan 31 01:52:38 2016 +0100 HSI: omap-ssi: add clk change support This adds support for frequency changes of the SSI functional clock, which may occur due to DVFS. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-By: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi.h | 6 ++++ drivers/hsi/controllers/omap_ssi_core.c | 63 +++++++++++++++++++++++++++++++++ drivers/hsi/controllers/omap_ssi_port.c | 20 +++++++++++ 3 files changed, 89 insertions(+) commit 0fae198988b873d30fe9ecb6a6271afb36df97e9 Author: Sebastian Reichel <sre@kernel.org> Date: Sat Apr 30 03:24:09 2016 +0200 HSI: omap_ssi: built omap_ssi and omap_ssi_port into one module Merge omap_ssi and omap_ssi_port into one module. This fixes problems with module cycle dependencies introduced by future patches. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/Kconfig | 5 - drivers/hsi/controllers/Makefile | 4 +- drivers/hsi/controllers/omap_ssi.c | 614 ------------------------------- drivers/hsi/controllers/omap_ssi.h | 2 + drivers/hsi/controllers/omap_ssi_core.c | 629 ++++++++++++++++++++++++++++++++ drivers/hsi/controllers/omap_ssi_port.c | 16 +- 6 files changed, 634 insertions(+), 636 deletions(-) commit 2a57aba8503d5694ee113016cb1a107831b8236f Author: Sebastian Reichel <sre@kernel.org> Date: Sat Apr 30 03:23:27 2016 +0200 HSI: omap_ssi: fix removal of port platform device This avoids removal of the HSI port device when only the platform port device should be removed and clears the POPULATED bit in the DT node, so that a new platform device is created when the driver is probed again. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi.c | 4 ++++ 1 file changed, 4 insertions(+) commit 0845e1f20af100d1d4ac7cc111a8dfb790f94a16 Author: Sebastian Reichel <sre@kernel.org> Date: Sat Apr 30 01:01:06 2016 +0200 HSI: omap_ssi: make sure probe stays available device can be unbind/rebind, so probe should stay available. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi.c | 17 +++++++++-------- drivers/hsi/controllers/omap_ssi_port.c | 19 ++++++++++--------- 2 files changed, 19 insertions(+), 17 deletions(-) commit f704e1103e05a65c83b85c66d947e57bc20d6edd Author: Sebastian Reichel <sre@kernel.org> Date: Sat Apr 30 00:07:35 2016 +0200 HSI: omap_ssi: fix module unloading Removal of ssi controller debugfs directory must happen after the clients have been removed from it. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 73e6ce09c068d42d627874019899f1138740a6c5 Author: Sebastian Reichel <sre@kernel.org> Date: Sat Apr 30 00:04:29 2016 +0200 HSI: omap_ssi_port: switch to gpiod API Simplify driver by switching to new gpio descriptor based API. Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/hsi/controllers/omap_ssi.c | 1 - drivers/hsi/controllers/omap_ssi.h | 4 ++-- drivers/hsi/controllers/omap_ssi_port.c | 31 ++++++++++--------------------- 3 files changed, 12 insertions(+), 24 deletions(-) commit b410f3b68d7ea8ca93abeb3420684c0378b7e134 Author: Andrey Smirnov <andrew.smirnov@gmail.com> Date: Wed Apr 20 08:45:31 2016 -0700 ARM: dts: imx6qp: Specify imx6qp version of PCIe core I.MX6Quad Plus has a slightly different version of PCIe core than reqular i.MX6Quad. Tested-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> arch/arm/boot/dts/imx6qp.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit 4d31c6109a24892df461b6a98842935e80159a5e Author: Andrey Smirnov <andrew.smirnov@gmail.com> Date: Mon May 2 14:09:10 2016 -0500 PCI: imx6: Implement reset sequence for i.MX6+ I.MX6+ has a dedicated bit for resetting PCIe core, which should be used instead of a regular reset sequence since using the latter will hang the SoC. This commit is based on c34068d48273e24d392d9a49a38be807954420ed from http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git Tested-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> .../devicetree/bindings/pci/fsl,imx6q-pcie.txt | 2 +- drivers/pci/host/pci-imx6.c | 23 ++++++++++++++++++++-- include/linux/mfd/syscon/imx6q-iomuxc-gpr.h | 1 + 3 files changed, 23 insertions(+), 3 deletions(-) commit a1d29476d666f5972f200c49e76df339ced6b07a Author: Christian König <christian.koenig@amd.com> Date: Wed Mar 30 14:42:57 2016 +0200 drm/amdgpu: optionally enable GART debugfs file Keeping the pages array around can use a lot of system memory when you want a large GART. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/Kconfig | 10 +++++++++ drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_gart.c | 35 +++++++++++++++++++------------- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 9 ++++++++ 4 files changed, 42 insertions(+), 14 deletions(-) commit 4325198180e5aeff21f44ba32c9ec18d9dd3ba72 Author: Christian König <christian.koenig@amd.com> Date: Wed Mar 30 10:54:16 2016 +0200 drm/amdgpu: remove GART page addr array Not needed any more. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_gart.c | 22 ++++------------------ 2 files changed, 4 insertions(+), 19 deletions(-) commit 8358dceed981cf389778fba217288da8dadbe103 Author: Christian König <christian.koenig@amd.com> Date: Wed Mar 30 10:50:25 2016 +0200 drm/amdgpu: use BO pages instead of GART array Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) commit fa3ab3c7babf3c2c8a4a174a532732739a304885 Author: Christian König <christian.koenig@amd.com> Date: Fri Mar 18 21:00:35 2016 +0100 drm/amdgpu: change parameter passing in the VM code Make it more flexible by passing src and page addresses directly instead of the structures they contain. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 100 ++++++++++++++++++--------------- 1 file changed, 54 insertions(+), 46 deletions(-) commit c4e1a13a24c3e9e6b881508e4f1c88bad0f46d2c Author: Christian König <christian.koenig@amd.com> Date: Thu Mar 17 16:25:15 2016 +0100 drm/amdgpu: drop the GTT power of two limit As far as I can see that isn't neccessary any more. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 0eadeab4afb7134b84a3479a9f5ad9fcd229db70 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Tue Mar 29 19:32:37 2016 +0800 drm/amd/powerplay: use min_clock_in_sr for deep sleep feature. This comes from the display handling code. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/powerplay/hwmgr/fiji_hwmgr.c | 50 ++++++++++++++---------- 1 file changed, 30 insertions(+), 20 deletions(-) commit cde6493928c15f2936b2b4096be36aa677aa6664 Author: Tom St Denis <tom.stdenis@amd.com> Date: Wed Mar 23 13:17:04 2016 -0400 drm/amd/amdgpu: Enable clockgating in UVD6 for Stoney This patch enables clockgating for the UVD6 block in Stoney. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 5f64e77e47c3b19fc14ea5231b59d6aecfecb787 Author: Tom St Denis <tom.stdenis@amd.com> Date: Wed Mar 23 13:16:13 2016 -0400 drm/amd/amdgpu: Enable clockgating for UVD5 on Tonga This patch enables clock gating for the UVD5 block with Tonga. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit be3ecca7fe157aa0eadf4ada8bee2d3e47e83c76 Author: Tom St Denis <tom.stdenis@amd.com> Date: Wed Mar 23 13:14:31 2016 -0400 drm/amd/amdgpu: Add SW clock gating support to UVD 5 and 6 This patch adds support for software clock gating to UVD 5 and UVD 6 blocks with a preliminary commented out hardware gating routine. Currently hardware gating does not work so it's not activated. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/uvd_v5_0.c | 115 ++++++++++++++ drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 281 ++++++++++++++-------------------- 2 files changed, 232 insertions(+), 164 deletions(-) commit b2c0cbd657173f024138d6421774007690ceeffd Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 22:05:27 2016 +0100 drm/radeon: don't include RADEON_HPD_NONE in HPD IRQ enable bitsets The values of all but the RADEON_HPD_NONE members of the radeon_hpd_id enum transform 1:1 into bit positions within the 'enabled' bitset as assembled by evergreen_hpd_init(): enabled |= 1 << radeon_connector->hpd.hpd; However, if ->hpd.hpd happens to equal RADEON_HPD_NONE == 0xff, UBSAN reports UBSAN: Undefined behaviour in drivers/gpu/drm/radeon/evergreen.c:1867:16 shift exponent 255 is too large for 32-bit type 'int' [...] Call Trace: [<ffffffff818c4d35>] dump_stack+0xbc/0x117 [<ffffffff818c4c79>] ? _atomic_dec_and_lock+0x169/0x169 [<ffffffff819411bb>] ubsan_epilogue+0xd/0x4e [<ffffffff81941cbc>] __ubsan_handle_shift_out_of_bounds+0x1fb/0x254 [<ffffffffa0ba7f2e>] ? atom_execute_table+0x3e/0x50 [radeon] [<ffffffff81941ac1>] ? __ubsan_handle_load_invalid_value+0x158/0x158 [<ffffffffa0b87700>] ? radeon_get_pll_use_mask+0x130/0x130 [radeon] [<ffffffff81219930>] ? wake_up_klogd_work_func+0x60/0x60 [<ffffffff8121a35e>] ? vprintk_default+0x3e/0x60 [<ffffffffa0c603c4>] evergreen_hpd_init+0x274/0x2d0 [radeon] [<ffffffffa0c603c4>] ? evergreen_hpd_init+0x274/0x2d0 [radeon] [<ffffffffa0bd196e>] radeon_modeset_init+0x8ce/0x18d0 [radeon] [<ffffffffa0b71d86>] radeon_driver_load_kms+0x186/0x350 [radeon] [<ffffffffa03b6b16>] drm_dev_register+0xc6/0x100 [drm] [<ffffffffa03bc8c4>] drm_get_pci_dev+0xe4/0x490 [drm] [<ffffffff814b83f0>] ? kfree+0x220/0x370 [<ffffffffa0b687c2>] radeon_pci_probe+0x112/0x140 [radeon] [...] ===================================================================== radeon 0000:01:00.0: No connectors reported connected with modes At least on x86, there should be no user-visible impact as there 1 << 0xff == 1 << (0xff & 31) == 1 << 31 holds and 31 > RADEON_MAX_HPD_PINS. Thus, this patch is a cosmetic one. All of the above applies analogously to evergreen_hpd_fini(), r100_hpd_init(), r100_hpd_fini(), r600_hpd_init(), r600_hpd_fini(), rs600_hpd_init() and rs600_hpd_fini() Silence UBSAN by checking ->hpd.hpd for RADEON_HPD_NONE before oring it into the 'enabled' bitset in the *_init()- or the 'disabled' bitset in the *_fini()-functions respectively. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/evergreen.c | 6 ++++-- drivers/gpu/drm/radeon/r100.c | 6 ++++-- drivers/gpu/drm/radeon/r600.c | 6 ++++-- drivers/gpu/drm/radeon/rs600.c | 6 ++++-- 4 files changed, 16 insertions(+), 8 deletions(-) commit 70f0f5fbcfbe26246ac2f0687d6fb1ac9dd95f44 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 16 15:17:18 2016 +0800 drm/amdgpu: refine code for code style. White space fix. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 976accc1148becb5a0560236c53e2f68cb2d5494 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 16 14:48:18 2016 +0800 drm/amdgpu: No need to stop hw init although vce's state was not true. This is not a fatal error. v2: add comment why ignore the error here. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit cb48a13ef994fcc4d1813c5c3241d4e4496c2199 Author: Rex Zhu <Rex.Zhu@amd.com> Date: Wed Mar 16 14:45:40 2016 +0800 drm/amdgpu: fix issue that can't set vce clock gate. Need to soft reset VCE as part of the clockgating sequence. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/vce_v2_0.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit b6723c8da55af5309cf06e71a5228f3c02846c5a Author: Monk Liu <Monk.Liu@amd.com> Date: Thu Mar 10 12:14:44 2016 +0800 drm/amdgpu: use ref to keep job alive this is to fix fatal page fault error that occured if: job is signaled/released after its timeout work is already put to the global queue (in this case the cancel_delayed_work will return false), which will lead to NX-protection error page fault during job_timeout_func. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 15 ++++++++++++--- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 8 +++++++- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 13 +++++++++++++ 5 files changed, 35 insertions(+), 4 deletions(-) commit 0de2479c953ae07fd11e7b1bc8d4fc831e6842bb Author: Monk Liu <Monk.Liu@amd.com> Date: Fri Mar 4 18:51:02 2016 +0800 drm/amdgpu: rework TDR in scheduler (v2) Add two callbacks to scheduler to maintain jobs, and invoked for job timeout calculations. Now TDR measures time gap from job is processed by hw. v2: fix typo Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 16 +++++++++++- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 37 +++++++++++++++++++++++++++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 7 +++++ drivers/gpu/drm/amd/scheduler/sched_fence.c | 1 + 6 files changed, 62 insertions(+), 1 deletion(-) commit cccd9bce978a6644bae75304a05db4faa36faec7 Author: Monk Liu <Monk.Liu@amd.com> Date: Fri Mar 4 14:42:26 2016 +0800 drm/amdgpu: get rid of incorrect TDR original time out detect routine is incorrect, cuz it measures the gap from job scheduled, but we should only measure the gap from processed by hw. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 39 +-------------------------- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 4 --- 2 files changed, 1 insertion(+), 42 deletions(-) commit 4835096b07420c1d74cc5711c461830016e6cb03 Author: Monk Liu <Monk.Liu@amd.com> Date: Fri Mar 4 14:33:44 2016 +0800 drm/amdgpu: put job to list before done the mirror_list will be used for later time out detect feature. This is needed to properly detect a GPU timeout with the scheduler. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 12 ++++++++++++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 6 ++++++ drivers/gpu/drm/amd/scheduler/sched_fence.c | 9 +++++++++ 3 files changed, 27 insertions(+) commit e472d2588eef38c2f16f71d6160e58fb5948e84f Author: Monk Liu <Monk.Liu@amd.com> Date: Thu Mar 3 19:00:50 2016 +0800 drm/amdgpu: delay job free to when it's finished (v2) for those jobs submitted through scheduler, do not free it immediately after scheduled, instead free it in global workqueue by its sched fence signaling callback function. v2: call uf's bo_undef after job_run() call job's sync free after job_run() no static inline __amdgpu_job_free() anymore, just use kfree(job) to replace it. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 11 ++++++++++- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 8 ++++++++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++++- 4 files changed, 22 insertions(+), 3 deletions(-) commit 01c02a8b193d63d77e0b45886efa71c9983af446 Author: Vitaly Prosyak <vitaly.prosyak@amd.com> Date: Fri Mar 18 15:49:41 2016 -0400 drm/amdgpu/dce11: fix vertical bars appear on monitor Fixed mc stop and resume hardware programming sequence. Signed-off-by: Vitaly Prosyak <vitaly.prosyak@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 65 +++------------------------------- 1 file changed, 5 insertions(+), 60 deletions(-) commit e686941a32d31d22ce7c8b7faf9cce17816f7c4d Author: Monk Liu <Monk.Liu@amd.com> Date: Mon Mar 7 12:49:55 2016 +0800 drm/amdgpu: use sched_job_init to initialize sched_job Consolidate job initialization in one place rather than duplicating it in multiple places. Signed-off-by: Monk Liu <Monk.Liu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 23 ++++++++++------------- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 15 +++++++++------ drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 17 +++++++++++++++++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++++- 4 files changed, 40 insertions(+), 20 deletions(-) commit 03ccf481980f8d3363263e73c64473d8f2779dc0 Author: Monk Liu <monk.liu@amd.com> Date: Thu Jan 14 19:07:38 2016 +0800 drm/amdgpu: patch cond exec for SDMA More ground work for conditional execution on SDMA necessary for preemption. Signed-off-by: Monk Liu <monk.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++++ drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 9 ++++++++- drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 25 +++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 1 deletion(-) commit 128cff1af68689cf4d85d3ba948c86a194dee30f Author: Monk Liu <monk.liu@amd.com> Date: Thu Jan 14 18:08:16 2016 +0800 drm/amdgpu: support cond exec This adds the groundwork for conditional execution on SDMA which is necessary for preemption. Signed-off-by: Monk Liu <monk.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 3 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 3 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 9 +++++++++ 3 files changed, 15 insertions(+) commit e6f1fef04c253955004efea35aea2e4bc59f49b6 Author: Andrey Smirnov <andrew.smirnov@gmail.com> Date: Mon May 2 14:08:21 2016 -0500 PCI: imx6: Use enum instead of bool for variant indicator Use enumerated type instead of a boolean flag to specify the variant of the PCIe IP block (6Q, 6SX, etc). This patch has zero functional impact, however it makes the code easier to extend for the case of more than 2 possible variants of an IP block (of which there are). [bhelgaas: rewrap comment, remove extra blank line] Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> drivers/pci/host/pci-imx6.c | 127 ++++++++++++++++++++++++-------------------- 1 file changed, 69 insertions(+), 58 deletions(-) commit 8e9fbeb522fa3043dc65ef0e383af28843950799 Author: Chunming Zhou <David1.Zhou@amd.com> Date: Thu Mar 17 11:41:37 2016 +0800 drm/amdgpu: improve vmid assigment V2 V2: the signaled items on the LRU maintain their order Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 2c1ea4c700af3dcfc8eabd94c91d1830b42c5461 Author: Tony Luck <tony.luck@intel.com> Date: Thu Apr 28 15:40:00 2016 -0700 EDAC, sb_edac: Use cpu family/model in driver detection Instead of picking a random PCI ID from the dozen or so we need to access, just use x86_match_cpu() to pick based on CPU model number. The choosing of PCI devices has been problematic in the past, see 11249e739929 ("sb_edac: Fix detection on SNB machines") which fixed problems introduced by d0585cd815fa ("sb_edac: Claim a different PCI device"). This is especially ugly if future hardware might not even have EDAC-relevant registers in PCI config space and we would still be required to choose some "random" PCI devices to scan for just so our driver loads. Is this cleaner/clearer? It deletes much more code than it adds. Only tested on Broadwell. The driver loads/unloads and loads again. Still decodes errors too. Signed-off-by: Tony Luck <tony.luck@intel.com> Suggested-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/sb_edac.c | 134 +++++++++++++------------------------------------ 1 file changed, 36 insertions(+), 98 deletions(-) commit 93bf9073a8a7e844b27327b05ab4dc608354d6fd Author: David Daney <david.daney@cavium.com> Date: Mon Apr 11 16:29:32 2016 -0700 PCI: thunder: Don't clobber read-only bits in bridge config registers The 32-bit addressing modes in the I/O and Prefetchable Memory registers are required to be read-only. Since the underlying access method allows them to be set, emulate their read-only nature and always set them. Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/host/pci-thunder-pem.c | 42 ++++++++++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 8 deletions(-) commit 32b9ccbc3522811c0e483637b85ae25f5491296f Author: Loic Poulain <loic.poulain@intel.com> Date: Thu Apr 28 18:48:25 2016 +0200 Bluetooth: hci_intel: Fix null gpio desc pointer dereference gpiod_get_optional can return either ERR_PTR or NULL pointer. NULL case is not tested and then dereferenced later in desc_to_gpio. Fix this by using non optional version which returns ERR_PTR in any error case (this is not an optional gpio). Use the same non optional version for the host-wake gpio. Fixes: 765ea3abd116 ("Bluetooth: hci_intel: Retrieve host-wake IRQ") Signed-off-by: Loic Poulain <loic.poulain@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/hci_intel.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit bb7f4f0bcee6844632d7366d6abff4b9996ad454 Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 26 06:57:27 2016 -0700 btmrvl: add platform specific wakeup interrupt support On some arm-based platforms, we need to configure platform specific parameters by device tree node and also define our node as a child node of parent SDIO host controller. This patch parses these parameters from device tree. It includes calibration data download to firmware, wakeup pin configured to firmware, and soc specific wake up gpio, which will be set as wakeup interrupt pin. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/btmrvl_drv.h | 11 ++++++ drivers/bluetooth/btmrvl_main.c | 35 ++++++++++-------- drivers/bluetooth/btmrvl_sdio.c | 79 +++++++++++++++++++++++++++++++++++++++++ drivers/bluetooth/btmrvl_sdio.h | 6 ++++ 4 files changed, 116 insertions(+), 15 deletions(-) commit 0065d1c5acdb60ee2c0e54585a29243718465bb7 Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 26 06:57:26 2016 -0700 dt: bindings: add MARVELL's bt-sd8xxx wireless device Add device tree binding documentation for MARVELL's bluetooth sdio (sd8897 and sd8997) chip. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Documentation/devicetree/bindings/btmrvl.txt | 29 ----------- .../devicetree/bindings/net/marvell-bt-sd8xxx.txt | 56 ++++++++++++++++++++++ 2 files changed, 56 insertions(+), 29 deletions(-) commit 2ffa9a5d76a75abbc1f95c17959fced666095bdd Author: Andreas Noever <andreas.noever@gmail.com> Date: Sun Apr 10 12:48:27 2016 +0200 thunderbolt: Fix double free of drom buffer If tb_drom_read() fails, sw->drom is freed but not set to NULL. sw->drom is then freed again in the error path of tb_switch_alloc(). The bug can be triggered by unplugging a thunderbolt device shortly after it is detected by the thunderbolt driver. Clear sw->drom if tb_drom_read() fails. [bhelgaas: add Fixes:, stable versions of interest] Fixes: 343fcb8c70d7 ("thunderbolt: Fix nontrivial endpoint devices.") Signed-off-by: Andreas Noever <andreas.noever@gmail.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: stable@vger.kernel.org # v3.17+ CC: Lukas Wunner <lukas@wunner.de> drivers/thunderbolt/eeprom.c | 1 + 1 file changed, 1 insertion(+) commit eca2240fb044e30276ecbb43eab47a46f96c05c4 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sat Mar 19 16:12:17 2016 +0100 drm/amdgpu: mark amdgpu_allowed_register_entry tables as 'const' Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/cik.c | 2 +- drivers/gpu/drm/amd/amdgpu/vi.c | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) commit 379548f509b5d4bdfcf252dd33093a45c01ce0d8 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sat Mar 19 16:12:13 2016 +0100 drm/amdgpu: do not store bios_header_start in amdgpu_device It is only used locally in amdgpu_get_bios Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 8 ++++---- 2 files changed, 4 insertions(+), 5 deletions(-) commit 16fae6502d797a95cd40a21664b5715ecacef599 Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sat Mar 19 16:12:12 2016 +0100 drm/radeon: delete unused struct member suspend from radeon_device Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 1 - 1 file changed, 1 deletion(-) commit 139768ff9266d9e58a29e9636d91cc649f6030ee Author: Nils Wallménius <nils.wallmenius@gmail.com> Date: Sat Mar 19 16:12:11 2016 +0100 drm/amdgpu: delete unused struct member suspend from amdgpu_device Signed-off-by: Nils Wallménius <nils.wallmenius@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - 1 file changed, 1 deletion(-) commit 274ad65c9d02bdcbee9bae045517864c3521d530 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:39 2016 +0100 drm/radeon: hard reset r600 and newer GPU when hibernating. Some GPU block like UVD and VCE require hard reset to be properly resume if there is no real powerdown of the asic like during various hibernation step. This patch perform such hard reset. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 3 ++- drivers/gpu/drm/radeon/radeon_device.c | 10 +++++++--- drivers/gpu/drm/radeon/radeon_drv.c | 9 +++++---- 3 files changed, 14 insertions(+), 8 deletions(-) commit 71fe289970430fca85c7c8da5a829e65764e081b Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:38 2016 +0100 drm/radeon: allow to force hard GPU reset. In some cases, like when freezing for hibernation, we need to be able to force hard reset even if no engine are stuck. This patch add a bool option to current asic reset callback to allow to force hard reset on asic that supports it. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/cik.c | 8 +++++++- drivers/gpu/drm/radeon/evergreen.c | 7 ++++++- drivers/gpu/drm/radeon/ni.c | 7 ++++++- drivers/gpu/drm/radeon/r100.c | 2 +- drivers/gpu/drm/radeon/r300.c | 2 +- drivers/gpu/drm/radeon/r600.c | 7 ++++++- drivers/gpu/drm/radeon/radeon.h | 4 ++-- drivers/gpu/drm/radeon/radeon_asic.h | 16 ++++++++-------- drivers/gpu/drm/radeon/rs600.c | 2 +- drivers/gpu/drm/radeon/si.c | 7 ++++++- 10 files changed, 44 insertions(+), 18 deletions(-) commit fabb5935871db1f31fcd2684fd154e24de04d917 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:37 2016 +0100 drm/radeon: add driver option to disable vce block. Quite few suspend/hibernation bugs are related to this block. Add an option to disable those as a work around. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 1 + drivers/gpu/drm/radeon/radeon_asic.c | 2 ++ drivers/gpu/drm/radeon/radeon_drv.c | 4 ++++ 3 files changed, 7 insertions(+) commit f1a0a67a8aca257fc6d4a2d1753556a91f2186a7 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:36 2016 +0100 drm/radeon: add driver option to disable uvd block. Quite few suspend/hibernation bugs are related to this block. Add an option to disable those as a work around. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 1 + drivers/gpu/drm/radeon/radeon_asic.c | 3 +++ drivers/gpu/drm/radeon/radeon_drv.c | 4 ++++ 3 files changed, 8 insertions(+) commit cb25f7e022b0fb1caf1bc50e5f85b3d31043b997 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:35 2016 +0100 drm/radeon: consolidate cik vce initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_vce doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/cik.c | 136 +++++++++++++++++++++++++++++-------------- 1 file changed, 91 insertions(+), 45 deletions(-) commit d18dd7598fc7f5221e835bccfe3b266a2dc53077 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:34 2016 +0100 drm/radeon: consolidate si vce initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_vce doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/si.c | 139 +++++++++++++++++++++++++++++--------------- 1 file changed, 93 insertions(+), 46 deletions(-) commit 6c0b1204f34fdc897502c97d03c1a4dfabeb7fdf Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:33 2016 +0100 drm/radeon: consolidate ni vce initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_vce doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/ni.c | 139 +++++++++++++++++++++++++++++--------------- 1 file changed, 91 insertions(+), 48 deletions(-) commit e3ebfcfa84fa895bb2d583189c239dc9afc9e0d1 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:32 2016 +0100 drm/radeon: add a vce flag to know if need to initialize vce or not. This will later on serve for module option to disable vce. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/radeon.h | 1 + drivers/gpu/drm/radeon/radeon_asic.c | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) commit bc48a15a550d32376f7f42b81901588d09bed7af Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:31 2016 +0100 drm/radeon: consolidate cik uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/cik.c | 108 +++++++++++++++++++++++++++++++------------ 1 file changed, 79 insertions(+), 29 deletions(-) commit fa25c22e8fd52dbf97552ab4cdfe30206d9948dd Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:30 2016 +0100 drm/radeon: consolidate si uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/si.c | 100 +++++++++++++++++++++++++++++++------------- 1 file changed, 70 insertions(+), 30 deletions(-) commit bd42210d4b2006382f54a57eb20a1527f532c516 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:29 2016 +0100 drm/radeon: consolidate ni uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/ni.c | 100 ++++++++++++++++++++++++++++++++------------ 1 file changed, 74 insertions(+), 26 deletions(-) commit d78d6f3978ef5f8c365627e2ca2e87583cb74f1e Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:28 2016 +0100 drm/radeon: consolidate evergreen uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/evergreen.c | 102 +++++++++++++++++++++++++++---------- 1 file changed, 74 insertions(+), 28 deletions(-) commit 66ecfcec6b65f3dccaa249ac2a8c0e8673effa05 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:27 2016 +0100 drm/radeon: consolidate rv770 uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/rv770.c | 102 ++++++++++++++++++++++++++++++----------- 1 file changed, 74 insertions(+), 28 deletions(-) commit c91f93683b4eeb5bd2488947c6c581c8cf638650 Author: Jérome Glisse <jglisse@redhat.com> Date: Fri Mar 18 16:58:26 2016 +0100 drm/radeon: consolidate r600 uvd initialization and startup code. This match the exact same control flow as existing code. It just use goto instead of multiple levels of if/else. It also clarify early initialization failures by clearing rdev->has_uvd doing so does not change end result from hardware point of view, it only avoids printing more error messages down the line and thus only the original error is reported. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> drivers/gpu/drm/radeon/r600.c | 99 ++++++++++++++++++++++++++++++------------- 1 file changed, 70 insertions(+), 29 deletions(-) commit 76ba8c1f2312e5128ef33e00a29c72c85bb80068 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:15:46 2016 +0200 PCI: rcar: Select PCI_MSI_IRQ_DOMAIN The R-Car PCIe driver requires the use of IRQ domains for its MSI code: drivers/pci/host/pcie-rcar.c:635:9: error: implicit declaration of function 'irq_find_mapping' [-Werror=implicit-function-declaration] drivers/pci/host/pcie-rcar.c:666:8: error: implicit declaration of function 'irq_create_mapping' [-Werror=implicit-function-declaration] ... Add a Kconfig select to ensure that the feature is always enabled. This is not consistent with what the other drivers do at the moment, but I have another patch that changes them to do it like this one, which is more logical. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Simon Horman <horms+renesas@verge.net.au> drivers/pci/host/Kconfig | 2 ++ 1 file changed, 2 insertions(+) commit cc736607c86d39ea078519af0de6ee0fbf3096a6 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:45:24 2016 -0400 gpio: ws16c48: Utilize the ISA bus driver The WinSystems WS16C48 communicates via the ISA bus. As such, it is more appropriate to use the ISA bus driver over the platform driver to control the WinSystems WS16C48 GPIO driver. This patch also adds support for multiple devices via the base and irq module array parameters. Each element of the base array corresponds to a discrete device; each element of the irq array corresponds to the respective device addressed in the respective base array element. Acked-by: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/gpio/Kconfig | 9 ++--- drivers/gpio/gpio-ws16c48.c | 88 +++++++++++++++------------------------------ 2 files changed, 33 insertions(+), 64 deletions(-) commit 86ea8a95a42f752fe0aa1c7ad1bfe8ce9be5d30e Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:45:11 2016 -0400 gpio: 104-idio-16: Utilize the ISA bus driver The ACCES 104-IDIO-16 series communicates via the ISA bus. As such, it is more appropriate to use the ISA bus driver over the platform driver to control the ACCES 104-IDIO-16 GPIO driver. This patch also adds support for multiple devices via the base and irq module array parameters. Each element of the base array corresponds to a discrete device; each element of the irq array corresponds to the respective device addressed in the respective base array element. Acked-by: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/gpio/Kconfig | 10 +++-- drivers/gpio/gpio-104-idio-16.c | 85 ++++++++++++++--------------------------- 2 files changed, 34 insertions(+), 61 deletions(-) commit 72bf7443ba618b9f7a3167c1f591a0dc00faeb2d Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:44:55 2016 -0400 gpio: 104-idi-48: Utilize the ISA bus driver The ACCES 104-IDI-48 series communicates via the ISA bus. As such, it is more appropriate to use the ISA bus driver over the platform driver to control the ACCES 104-IDI-48 GPIO driver. This patch also adds support for multiple devices via the base and irq module array parameters. Each element of the base array corresponds to a discrete device; each element of the irq array corresponds to the respective device addressed in the respective base array element. Acked-by: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/gpio/Kconfig | 10 +++-- drivers/gpio/gpio-104-idi-48.c | 86 ++++++++++++++---------------------------- 2 files changed, 34 insertions(+), 62 deletions(-) commit 4c23db0f9f7f5e554837f69a849de75777f3fefc Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:44:39 2016 -0400 gpio: 104-dio-48e: Utilize the ISA bus driver The ACCES 104-DIO-48E series communicates via the ISA bus. As such, it is more appropriate to use the ISA bus driver over the platform driver to control the ACCES 104-DIO-48E GPIO driver. This patch also adds support for multiple devices via the base and irq module array parameters. Each element of the base array corresponds to a discrete device; each element of the irq array corresponds to the respective device addressed in the respective base array element. Acked-by: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/gpio/Kconfig | 9 ++-- drivers/gpio/gpio-104-dio-48e.c | 106 ++++++++++++++-------------------------- 2 files changed, 43 insertions(+), 72 deletions(-) commit 4ef1bec4e4f393aa96d2b5345bb08baabaec8ee1 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:44:26 2016 -0400 watchdog: ebc-c384_wdt: Utilize the ISA bus driver The WinSystems EBC-C384 watchdog timer is controlled via ISA bus communication. As such, the ISA bus driver is more appropriate than the platform driver for the WinSystems EBC-C384 watchdog timer driver. Cc: Wim Van Sebroeck <wim@iguana.be> Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/watchdog/Kconfig | 2 +- drivers/watchdog/ebc-c384_wdt.c | 43 ++++++++++------------------------------- 2 files changed, 11 insertions(+), 34 deletions(-) commit 9c2cfc19e64a513a1b9e55f78e38661a1b97b91e Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:44:11 2016 -0400 iio: stx104: Utilize the module_isa_driver and max_num_isa_dev macros The Apex Embedded Systems STX104 DAC drivers does not do anything special in module init/exit. This patch eliminates the module init/exit boilerplate code by utilizing the module_isa_driver macro. Additionally, the max_num_isa_dev macro is utilized to simplify the determination of maximum possible STX104 devices in the system. Cc: Jonathan Cameron <jic23@kernel.org> Cc: Hartmut Knaack <knaack.h@gmx.de> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/iio/dac/stx104.c | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) commit 136c9568457d7747f63c23f9acb01a0e831f351a Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:43:54 2016 -0400 iio: stx104: Add X86 dependency to STX104 Kconfig option The Apex Embedded Systems STX104 DAC driver expects the STX104 device to be I/O port-mapped addressable on an X86 platform. This patch adds an explicit X86 dependency to the STX104 configuration option to prevent building on non-X86 architectures. Cc: Jonathan Cameron <jic23@kernel.org> Cc: Hartmut Knaack <knaack.h@gmx.de> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/iio/dac/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ad7afc38eab37c8a71f10ad6246df6ba7d7e5bb3 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:43:35 2016 -0400 Documentation: Add ISA bus driver documentation This is a verbatim copy of the original commit message of the initial commit of the ISA bus driver authored by Rene Herman. Descriptions of the module_isa_driver macro and max_num_isa_dev macro are provided at the end. Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/isa.txt | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++ MAINTAINERS | 7 +++ 2 files changed, 128 insertions(+) commit d9a9c6172d1cec51851e9015b6c4379635c31f1a Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:43:10 2016 -0400 isa: Implement the max_num_isa_dev macro max_num_isa_dev is a macro to determine the maximum possible number of ISA devices which may be registered in the I/O port address space given the address extent of the ISA devices. The highest base address possible for an ISA device is 0x3FF; this results in 1024 possible base addresses. Dividing the number of possible base addresses by the address extent taken by each device results in the maximum number of devices on a system. Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/isa.h | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 339e6e31d2bfb40354cbfe672b357b88a88223f2 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 18:42:47 2016 -0400 isa: Implement the module_isa_driver macro The module_isa_driver macro is a helper macro for ISA drivers which do not do anything special in module init/exit. This eliminates a lot of boilerplate code. Each module may only use this macro once, and calling it replaces module_init and module_exit. Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/isa.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit ad8403df054c9b5dc3175a26c6179571b9cafa4e Author: Anand Jain <anand.jain@oracle.com> Date: Thu Mar 10 12:22:15 2016 +0800 btrfs: pass the right error code to the btrfs_std_error Also drop the newline from the message. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 46cb41534a1a1d1f75aae5eab0dd8c06a9461e6b Author: Axel Lin <axel.lin@ingics.com> Date: Sat Apr 30 15:01:08 2016 +0800 spi: Drop unnecessary dependencies on relaxed I/O accessors The relaxed I/O accessors are available on all architectures now. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 2 -- 1 file changed, 2 deletions(-) commit 38f252553300ee1d3346a5273e95fe1dd60ca50a Author: Christoph Hellwig <hch@lst.de> Date: Sat Apr 16 14:55:28 2016 -0400 block: add __blkdev_issue_discard This is a version of blkdev_issue_discard which doesn't wait for the I/O to complete, but instead allows the caller to submit the final bio and/or chain it to others. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Signed-off-by: Sagi Grimberg <sagig@grimberg.me> Reviewed-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-lib.c | 63 +++++++++++++++++++++++++++++--------------------- include/linux/blkdev.h | 2 ++ 2 files changed, 39 insertions(+), 26 deletions(-) commit 9082e87bfbf83579b97e3bfc45d81f3e50da2177 Author: Christoph Hellwig <hch@lst.de> Date: Sat Apr 16 14:55:27 2016 -0400 block: remove struct bio_batch It can be replaced with a combination of bio_chain and submit_bio_wait. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Signed-off-by: Sagi Grimberg <sagig@grimberg.me> Reviewed-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-lib.c | 118 +++++++++++++------------------------------------------- 1 file changed, 27 insertions(+), 91 deletions(-) commit b7b9c2278752e37dc7ae918cda823aa2a078e03b Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 25 14:20:19 2016 -0700 nvme: fix nvme_ns_remove() deadlock On receipt of a namespace attribute changed AER, we acquire the namespace mutex lock before proceeding to scan and validate the namespace list. In case of namespace detach/delete command, nvme_ns_remove function deadlocks trying to acquire the already held lock. All callers, except nvme_remove_namespaces(), of nvme_ns_remove() already held namespaces_mutex. So we can simply fix the deadlock by not acquiring the mutex in nvme_ns_remove() and acquiring it in nvme_remove_namespaces(). Reported-by: Sunad Bhandary S <sunad.s@samsung.com> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Sagi Grimerg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 0bf77e9dbb5247ae159342db6f8fdb48aba24b56 Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 25 14:20:18 2016 -0700 nvme: switch to RCU freeing the namespace Switch to RCU freeing the namespace structure so that nvme_start_queues, nvme_stop_queues and nvme_kill_queues would be able to get away with only a RCU read side critical section. Suggested-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Sagi Grimerg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit a5b714ad395803a6aa91793b9e52a81b176b8ba9 Author: Wang Sheng-Hui <shhuiw@foxmail.com> Date: Wed Apr 27 20:10:16 2016 +0800 NVMe: correct comment for offset enum of controller registers in nvme.h Section 3.1 gives the comment for the offset of controller registers in the specification 1.2a. Some are mis-copied in the header file nvme.h. Correct them. Signed-off-by: Wang Sheng-Hui <shhuiw@foxmail.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> include/linux/nvme.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6904242db1ac07403c331b18796f6c2bf5382aec Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 25 14:33:20 2016 -0700 nvme: add helper nvme_cleanup_cmd() This hides command cleanup into nvme.h and fabrics drivers will also use it. Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/nvme.h | 6 ++++++ drivers/nvme/host/pci.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-) commit f866fc4282a81673ef973ad54c68235a3263b42e Author: Christoph Hellwig <hch@lst.de> Date: Tue Apr 26 13:52:00 2016 +0200 nvme: move AER handling to common code The transport driver still needs to do the actual submission, but all the higher level code can be shared. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ drivers/nvme/host/nvme.h | 7 +++++++ drivers/nvme/host/pci.c | 49 +++++++++-------------------------------------- 3 files changed, 66 insertions(+), 40 deletions(-) commit 5955be2144b3b56182e2175e7e3d2ddf27fb485d Author: Christoph Hellwig <hch@lst.de> Date: Tue Apr 26 13:51:59 2016 +0200 nvme: move namespace scanning to core Move the scan work item and surrounding code to the common code. For now we need a new finish_scan method to allow the PCI driver to set the irq affinity hints, but I have plans in the works to obsolete this as well. Note that this moves the namespace scanning from nvme_wq to the system workqueue, but as we don't rely on namespace scanning to finish from reset or I/O this should be fine. Signed-off-by: Christoph Hellwig <hch@lst.de> Acked-by Jon Derrick: <jonathan.derrick@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 30 ++++++++++++++++++++++++++---- drivers/nvme/host/nvme.h | 4 +++- drivers/nvme/host/pci.c | 32 +++++--------------------------- 3 files changed, 34 insertions(+), 32 deletions(-) commit 92911a55d42084cd285250c275d9f238783638c2 Author: Christoph Hellwig <hch@lst.de> Date: Tue Apr 26 13:51:58 2016 +0200 nvme: tighten up state check for namespace scanning We only should be scanning namespaces if the controller is live. Currently we call the function just before setting it live, so fix the code up to move the call to nvme_queue_scan to just below the state change. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Acked-by Jon Derrick: <jonathan.derrick@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit bb8d261e088811ef2b564d745afcd1633428010a Author: Christoph Hellwig <hch@lst.de> Date: Tue Apr 26 13:51:57 2016 +0200 nvme: introduce a controller state machine Replace the adhoc flags in the PCI driver with a state machine in the core code. Based on code from Sagi Grimberg for the Fabrics driver. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Acked-by Jon Derrick: <jonathan.derrick@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 51 ++++++++++++++++++++++++++++++++++++++++++++++++ drivers/nvme/host/nvme.h | 11 +++++++++++ drivers/nvme/host/pci.c | 25 ++++++++++++------------ 3 files changed, 74 insertions(+), 13 deletions(-) commit 04a934d4c7251e6458a7898c2b4d6c2da29b132c Author: Christoph Hellwig <hch@lst.de> Date: Tue Apr 26 13:51:56 2016 +0200 nvme: remove the io_incapable method It's unused since "NVMe: Move error handling to failed reset handler". Signed-off-by: Christoph Hellwig <hch@lst.de> Acked-by: Jon Derrick <jonathan.derrick@intel.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/nvme.h | 12 ------------ drivers/nvme/host/pci.c | 8 -------- 2 files changed, 20 deletions(-) commit 23bd63ceea30878758c303baaf9f8e28f299c578 Author: Wang Sheng-Hui <shhuiw@foxmail.com> Date: Thu Apr 28 16:19:31 2016 +0800 NVMe: nvme_core_exit() should do cleanup in the reverse order as nvme_core_init does nvme_core_init does: 1) register_blkdev 2) __register_chrdev 3) class_create nvme_core_exit should do cleanup in the reverse order. Signed-off-by: Wang Sheng-Hui <shhuiw@foxmail.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dfebc152b7570df7df76ed31eeb3c81cf84ecb54 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:22 2016 -0700 drm/tilcdc: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Jyri Sarha <jsarha@ti.com> Tested-by: Jyri Sarha <jsarha@ti.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-11-git-send-email-gustavo@padovan.org drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c05d3d73dbd39b0b88cea62657307bedd5efc9f0 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:21 2016 -0700 drm/shmobile: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-10-git-send-email-gustavo@padovan.org drivers/gpu/drm/shmobile/shmob_drm_crtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 444435bb54699843f73ed2b97cba0d71c2e097bc Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:20 2016 -0700 drm/rcar-du: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-9-git-send-email-gustavo@padovan.org drivers/gpu/drm/rcar-du/rcar_du_crtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6118faea2bc541426c171dbea701d000eb1265fe Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:16 2016 -0700 drm/msm: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-5-git-send-email-gustavo@padovan.org drivers/gpu/drm/msm/mdp/mdp4/mdp4_crtc.c | 2 +- drivers/gpu/drm/msm/mdp/mdp5/mdp5_crtc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 3b24774e1fb90a40836e96e39a851a774679efff Author: Keith Busch <keith.busch@intel.com> Date: Wed Apr 27 15:51:18 2016 -0600 NVMe: Fix check_flush_dependency warning If the controller fails and is degraded after a reset, we need to kill off all requests queues before removing the inaccessble namespaces. This will prevent del_gendisk from syncing dirty data, which we can't due from a WQ_MEM_RECLAIM work queue. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 1 + 1 file changed, 1 insertion(+) commit eba92811f5c7ad9fadf40f021c1b85ad0de3bcc4 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:19 2016 -0700 drm/radeon: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-8-git-send-email-gustavo@padovan.org drivers/gpu/drm/radeon/radeon_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 56286769667c72322d18e9acca3a639213bd4a00 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:12 2016 -0700 drm/amdgpu: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-1-git-send-email-gustavo@padovan.org drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 2 +- drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 8381e6022755863258a352128a55e375a766f50d Author: Bob Peterson <rpeterso@redhat.com> Date: Mon May 2 09:42:49 2016 -0500 GFS2: Remove allocation parms from gfs2_rbm_find Struct gfs2_alloc_parms ap is never referenced in function gfs2_rbm_find, so this patch removes it. Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/rgrp.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit 0619f39474b991244d0a2cbd323915c0e6167b5a Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 11:46:17 2016 -0400 pnp: pnpbios: Add explicit X86_32 dependency to PNPBIOS The PNPBIOS driver requires preprocessor defines (located in include/asm/segment.h) only declared if the architecture is set to X86_32. If the architecture is set to X86_64, the PNPBIOS driver will not build properly. The X86 dependecy for the PNPBIOS configuration option is changed to an explicit X86_32 dependency in order to prevent an attempt to build for an unsupported architecture. Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/pnp/pnpbios/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 81072bfd13f23079417259f8973532ae21716225 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:45 2016 +0200 drm/i915: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-13-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit eb63961ba52ba545f5b7ebeeeefe1c98704e1a79 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:44 2016 +0200 drm/vc4: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Eric Anholt <eric@anholt.net> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-12-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/vc4/vc4_kms.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8beafe025497746c1168faa12e56d7cdad6b509e Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:43 2016 +0200 drm/rockchip: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Mark Yao <mark.yao@rock-chips.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-11-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/rockchip/rockchip_drm_fb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 2dacdd70a7f366e30d197b059bbfbf3d05efc831 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:42 2016 +0200 drm/tegra: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Thierry Reding <thierry.reding@gmail.com> Cc: "Terje Bergström" <tbergstrom@nvidia.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-10-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/tegra/drm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit ab575184254c113fa1a8e8653619ec2f08747bbd Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:41 2016 +0200 drm/sti: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org> Cc: Vincent Abriou <vincent.abriou@st.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Vincent Abriou <vincent.abriou@st.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-9-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/sti/sti_drv.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 3302f3586fe0ff7659ebeb4fed9d9a458131354f Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:40 2016 +0200 drm/rcar-du: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-8-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/rcar-du/rcar_du_kms.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 6fc17fb21e527d61f1a1e1834241ee3dc10db865 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:39 2016 +0200 drm/omapdrm: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-7-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/omapdrm/omap_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a3ccfb9feb4649180774ee832c5f355f4586acc3 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:38 2016 +0200 drm/msm: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Also comments seem to be a bit outdated, as it looks like nonblocking commit is supported by msm. Cc: Rob Clark <robdclark@gmail.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-6-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/msm/msm_atomic.c | 9 ++++----- drivers/gpu/drm/msm/msm_drv.h | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) commit 1b3f09d8ca06588b5fd95e235c2bb3fc5131782f Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:37 2016 +0200 drm/exynos: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-5-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ++-- drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 51b6beff6e13bf188fdb62926efaac7cf24b59bb Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:36 2016 +0200 drm/arm/hdlcd: Rename async to nonblock. The async name is deprecated and should be changed to nonblocking. Cc: Liviu Dudau <liviu.dudau@arm.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Liviu Dudau <liviu.dudau@arm.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-4-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/arm/hdlcd_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b837ba0ad95bb5c08626a49321f07f271bdaf512 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:35 2016 +0200 drm/atomic: Rename drm_atomic_async_commit to nonblocking. Another step in renaming async to nonblocking for atomic commit. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-3-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/drm_atomic.c | 12 ++++++------ drivers/gpu/drm/drm_atomic_helper.c | 4 ++-- include/drm/drm_atomic.h | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) commit 286dbb8d5d800dcca23d43bb62d9f3cd96fe479c Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Apr 26 16:11:34 2016 +0200 drm/atomic: Rename async parameter to nonblocking. This is the first step of renaming async commit to nonblocking commit. The flag passed by userspace is NONBLOCKING, and async has a different meaning for page flips, where it means as soon as possible. Fixing up comments in drm core is done manually, to make sure I didn't miss anything. For drivers, the following cocci script is used to rename bool async to bool nonblock: @@ identifier I =~ "^async"; identifier func; @@ func(..., bool - I + nonblock , ...) { <... - I + nonblock ...> } @@ identifier func; type T; identifier I =~ "^async"; @@ T func(..., bool - I + nonblock , ...); Thanks to Tvrtko Ursulin for the cocci script. Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461679905-30177-2-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/drm_atomic_helper.c | 30 +++++++++++++++--------------- include/drm/drm_atomic_helper.h | 2 +- include/drm/drm_crtc.h | 8 ++++---- 3 files changed, 20 insertions(+), 20 deletions(-) commit d2442287e77926ee3552acf3bf31a6047ecb0ac1 Author: Pramod Gurav <pramod.gurav@linaro.org> Date: Mon May 2 17:44:04 2016 +0530 spi: qup: Add spi_master_put in remove function Release memory allocated for spi master by calling spi_master_put in .remove function. Signed-off-by: Pramod Gurav <pramod.gurav@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-qup.c | 2 ++ 1 file changed, 2 insertions(+) commit dae1a7700b34eceae049cf8f1567a640528ca4c1 Author: Pramod Gurav <pramod.gurav@linaro.org> Date: Mon May 2 17:44:03 2016 +0530 spi: qup: Handle clocks in pm_runtime suspend and resume Clocks must ne disabled in pm_runtime to achieve some power saving. Enable the clocks when the device is runtime resumed during a transfer. Signed-off-by: Pramod Gurav <pramod.gurav@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-qup.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit e375882406d0cc24030746638592004755ed4ae0 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:37 2016 +0200 drm/udl: Use drm_fb_helper deferred_io support Use the fbdev deferred io support in drm_fb_helper. The (struct fb_ops *)->fb_{fillrect,copyarea,imageblit} functions will now schedule a worker instead of being flushed directly like it was previously (recorded when in atomic). This patch has only been compile tested. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Tested-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-8-git-send-email-noralf@tronnes.org drivers/gpu/drm/udl/udl_drv.h | 2 - drivers/gpu/drm/udl/udl_fb.c | 140 ++---------------------------------------- 2 files changed, 6 insertions(+), 136 deletions(-) commit 9ee78757d5dae51decc881b293a39a605c9a6df2 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon May 2 13:57:36 2016 +0100 ASoC: wm_adsp: Add support for TLV based binary controls This patch adds support for the arbitrary length TLV based binary controls. This allows users to properly access controls that are more than 512 bytes in length. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 128 ++++++++++++++++++++++++++++++++++++++------- 1 file changed, 108 insertions(+), 20 deletions(-) commit 6819c3c2517604f979da3de773f2420e07dd4f4b Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:36 2016 +0200 drm/qxl: Use drm_fb_helper deferred_io support Use the fbdev deferred io support in drm_fb_helper which mirrors the one qxl has had. This patch has only been compile tested. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Tested-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-7-git-send-email-noralf@tronnes.org drivers/gpu/drm/qxl/qxl_display.c | 9 +- drivers/gpu/drm/qxl/qxl_drv.h | 7 +- drivers/gpu/drm/qxl/qxl_fb.c | 223 ++++++++++---------------------------- drivers/gpu/drm/qxl/qxl_kms.c | 4 - 4 files changed, 65 insertions(+), 178 deletions(-) commit 199c77179c879e6cbca178bf67e9153dc89fb3d1 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:35 2016 +0200 drm/fb-cma-helper: Add fb_deferred_io support This adds fbdev deferred io support if CONFIG_FB_DEFERRED_IO is enabled. The driver has to provide a (struct drm_framebuffer_funcs *)->dirty() callback to get notification of fbdev framebuffer changes. If the dirty() hook is set, then fb_deferred_io is set up automatically by the helper. Two functions have been added so that the driver can provide a dirty() function: - drm_fbdev_cma_init_with_funcs() This makes it possible for the driver to provided a custom (struct drm_fb_helper_funcs *)->fb_probe() function. - drm_fbdev_cma_create_with_funcs() This is used by the .fb_probe hook to set a driver provided (struct drm_framebuffer_funcs *)->dirty() function. Cc: laurent.pinchart@ideasonboard.com Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-6-git-send-email-noralf@tronnes.org drivers/gpu/drm/drm_fb_cma_helper.c | 178 +++++++++++++++++++++++++++++++++--- include/drm/drm_fb_cma_helper.h | 14 +++ 2 files changed, 180 insertions(+), 12 deletions(-) commit ba0263340a2aeaf5f08e4f2b0f4c29e300828b06 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:34 2016 +0200 fbdev: fb_defio: Export fb_deferred_io_mmap Export fb_deferred_io_mmap so drivers can change vma->vm_page_prot. When the framebuffer memory is allocated using dma_alloc_writecombine() instead of vmalloc(), I get cache syncing problems on ARM. This solves it: static int drm_fbdev_cma_deferred_io_mmap(struct fb_info *info, struct vm_area_struct *vma) { fb_deferred_io_mmap(info, vma); vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot); return 0; } Could this have been done in the core? Drivers that don't set (struct fb_ops *)->fb_mmap, gets a call to fb_pgprotect() at the end of the default fb_mmap implementation (drivers/video/fbdev/core/fbmem.c). This is an architecture specific function that on many platforms uses pgprot_writecombine(), but not on all. And looking at some of the fb_mmap implementations, some of them sets vm_page_prot to nocache for instance, so I think the safest bet is to do this in the driver and not in the fbdev core. And we can't call fb_pgprotect() from fb_deferred_io_mmap() either because we don't have access to the file pointer that powerpc needs. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-5-git-send-email-noralf@tronnes.org drivers/video/fbdev/core/fb_defio.c | 3 ++- include/linux/fb.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) commit eaa434defaca1781fb2932c685289b610aeb8b4b Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:33 2016 +0200 drm/fb-helper: Add fb_deferred_io support This adds deferred io support to drm_fb_helper. The fbdev framebuffer changes are flushed using the callback (struct drm_framebuffer *)->funcs->dirty() by a dedicated worker ensuring that it always runs in process context. For those wondering why we need to be able to handle atomic calling contexts: Both panic paths and cursor code and fbcon blanking can run from atomic. See commit bcb39af4486be07e896fc374a2336bad3104ae0a Author: Dave Airlie <airlied@redhat.com> Date: Thu Feb 7 11:19:15 2013 +1000 drm/udl: make usage as a console safer for where this was originally discovered. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> [danvet: Augment commit message with why we need to handle atomic contexts.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-4-git-send-email-noralf@tronnes.org drivers/gpu/drm/Kconfig | 1 + drivers/gpu/drm/drm_fb_helper.c | 103 +++++++++++++++++++++++++++++++++++++++- include/drm/drm_fb_helper.h | 15 ++++++ 3 files changed, 118 insertions(+), 1 deletion(-) commit 2b5e8e579be4ce3b576e419b3eb2bc06d8f41389 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:32 2016 +0200 drm/qxl: Change drm_fb_helper_sys_*() calls to sys_*() Now that drm_fb_helper gets deferred io support, the drm_fb_helper_sys_{fillrect,copyarea,imageblit} functions will schedule a worker that will call the (struct drm_framebuffer *)->funcs->dirty() function. This will break this driver so use the sys_{fillrect,copyarea,imageblit} functions directly. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-3-git-send-email-noralf@tronnes.org drivers/gpu/drm/qxl/qxl_fb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 302f0e266e3260d2b3594990a857cc26ce2c74e7 Author: Noralf Trønnes <noralf@tronnes.org> Date: Thu Apr 28 17:18:31 2016 +0200 drm/udl: Change drm_fb_helper_sys_*() calls to sys_*() Now that drm_fb_helper gets deferred io support, the drm_fb_helper_sys_{fillrect,copyarea,imageblit} functions will schedule a worker that will call the (struct drm_framebuffer *)->funcs->dirty() function. This will break this driver so use the sys_{fillrect,copyarea,imageblit} functions directly. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461856717-6476-2-git-send-email-noralf@tronnes.org drivers/gpu/drm/udl/udl_fb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 011d6f5c3e5f38a767c8f4c7e2de73dc91959cb0 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon May 2 12:59:19 2016 +0200 of: include errno.h in of_graph.h When CONFIG_OF is disabled, we have to include linux/errno.h before including of_graph.h, or get build errors like in the newly added sun4i drm driver: In file included from ../drivers/gpu/drm/sun4i/sun4i_drv.c:14:0: include/linux/of_graph.h: In function 'of_graph_parse_endpoint': include/linux/of_graph.h:58:10: error: 'ENOSYS' undeclared (first use in this function) A better solution is to ensure that the header can be included by itself, so let's include linux/errno.h here to fix the error we just got, and any similar future error. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support") Signed-off-by: Rob Herring <robh@kernel.org> include/linux/of_graph.h | 1 + 1 file changed, 1 insertion(+) commit 80f4781d2c0ba63bf9ab4de90a6829a1368b80a3 Author: Abhi Das <adas@redhat.com> Date: Mon May 2 07:07:01 2016 -0500 gfs2: use inode_lock/unlock instead of accessing i_mutex directly i_mutex has been replaced by i_rwsem and directly accessing the non-existent i_mutex breaks the kernel build. Signed-off-by: Abhi Das <adas@redhat.com> Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/file.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7d3a3fe6488a62ff9aed27fc2128d35c1ba99c30 Author: Alexander Stein <alexanders83@web.de> Date: Fri Apr 29 14:50:03 2016 +0200 pinctrl: at91: Merge clk_prepare and clk_enable into clk_prepare_enable This simplifies the normal as well as the error path. Signed-off-by: Alexander Stein <alexanders83@web.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-at91.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit 234b6513fcb9d98adf71fcb6110be4e719632988 Author: Alexander Stein <alexanders83@web.de> Date: Fri Apr 29 14:50:02 2016 +0200 pinctrl: at91: Make at91_gpio_template const This template is only assigned, so make it const. Signed-off-by: Alexander Stein <alexanders83@web.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-at91.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2bd07177213b2a7a7db49f4cebf9ddd1b7c17184 Merge: 22bbd21 56ed4bb Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 2 13:50:47 2016 +0200 Merge tag 'sh-pfc-for-v4.7-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into devel pinctrl: sh-pfc: Updates for v4.7 (take two) - Support for the Display Unit on R-Car E2. commit 287e9357abcc0ef079bf4e439e098a3bd6246a05 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Apr 11 09:57:55 2016 +0100 DT/arm,gic-v3: Documment PPI partition support Add a decription of the PPI partitioning support. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Rob Herring <robh+dt@kernel.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: devicetree@vger.kernel.org Cc: Jason Cooper <jason@lakedaemon.net> Cc: Will Deacon <will.deacon@arm.com> Link: http://lkml.kernel.org/r/1460365075-7316-6-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> .../bindings/interrupt-controller/arm,gic-v3.txt | 34 ++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) commit e3825ba1af3a27d7522c9f5f929f5a13b8b138ae Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Apr 11 09:57:54 2016 +0100 irqchip/gic-v3: Add support for partitioned PPIs Plug the partitioning layer into the GICv3 PPI code, parsing the DT and building the partition affinities and providing the generic code with partition data and callbacks. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: devicetree@vger.kernel.org Cc: Jason Cooper <jason@lakedaemon.net> Cc: Will Deacon <will.deacon@arm.com> Cc: Rob Herring <robh+dt@kernel.org> Link: http://lkml.kernel.org/r/1460365075-7316-5-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> drivers/irqchip/Kconfig | 1 + drivers/irqchip/irq-gic-v3.c | 176 ++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 175 insertions(+), 2 deletions(-) commit 9e2c986cb460bf97154f18e85aa833739a1e8dc7 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Apr 11 09:57:53 2016 +0100 irqchip: Add per-cpu interrupt partitioning library We've unfortunately started seeing a situation where percpu interrupts are partitioned in the system: one arbitrary set of CPUs has an interrupt connected to a type of device, while another disjoint set of CPUs has the same interrupt connected to another type of device. This makes it impossible to have a device driver requesting this interrupt using the current percpu-interrupt abstraction, as the same interrupt number is now potentially claimed by at least two drivers, and we forbid interrupt sharing on per-cpu interrupt. A solution to this is to turn things upside down. Let's assume that our system describes all the possible partitions for a given interrupt, and give each of them a unique identifier. It is then possible to create a namespace where the affinity identifier itself is a form of interrupt number. At this point, it becomes easy to implement a set of partitions as a cascaded irqchip, each affinity identifier being the HW irq. This allows us to keep a number of nice properties: - Each partition results in a separate percpu-interrupt (with a restrictied affinity), which keeps drivers happy. - Because the underlying interrupt is still per-cpu, the overhead of the indirection can be kept pretty minimal. - The core code can ignore most of that crap. For that purpose, we implement a small library that deals with some of the boilerplate code, relying on platform-specific drivers to provide a description of the affinity sets and a set of callbacks. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: devicetree@vger.kernel.org Cc: Jason Cooper <jason@lakedaemon.net> Cc: Will Deacon <will.deacon@arm.com> Cc: Rob Herring <robh+dt@kernel.org> Link: http://lkml.kernel.org/r/1460365075-7316-4-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> drivers/irqchip/Kconfig | 3 + drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-partition-percpu.c | 256 +++++++++++++++++++++++++++ include/linux/irqchip/irq-partition-percpu.h | 59 ++++++ 4 files changed, 319 insertions(+) commit 222df54fd8b7641dcc81476f157806bb3144ee1d Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Apr 11 09:57:52 2016 +0100 genirq: Allow the affinity of a percpu interrupt to be set/retrieved In order to prepare the genirq layer for the concept of partitionned percpu interrupts, let's allow an affinity to be associated with such an interrupt. We introduce: - irq_set_percpu_devid_partition: flag an interrupt as a percpu-devid interrupt, and associate it with an affinity - irq_get_percpu_devid_partition: allow the affinity of that interrupt to be retrieved. This will allow a driver to discover which CPUs the per-cpu interrupt can actually fire on. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: devicetree@vger.kernel.org Cc: Jason Cooper <jason@lakedaemon.net> Cc: Will Deacon <will.deacon@arm.com> Cc: Rob Herring <robh+dt@kernel.org> Link: http://lkml.kernel.org/r/1460365075-7316-3-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/irq.h | 4 ++++ include/linux/irqdesc.h | 1 + kernel/irq/irqdesc.c | 26 +++++++++++++++++++++++++- 3 files changed, 30 insertions(+), 1 deletion(-) commit 651e8b54abdeeaa36f5f54ffa05c18707a3cc1d0 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Mon Apr 11 09:57:51 2016 +0100 irqdomain: Allow domain matching on irq_fwspec When iterating over the irq domain list, we try to match a domain either by calling a match() function or by comparing a number of fields passed as parameters. Both approaches are a bit restrictive: - match() is DT specific and only takes a device node - the fallback case only deals with the fwnode_handle It would be useful if we had a per-domain function that would actually perform the matching check on the whole of the irq_fwspec structure. This would allow for a domain to triage matching attempts that need to extend beyond the fwnode. Let's introduce irq_find_matching_fwspec(), which takes a full blown irq_fwspec structure, and call into a select() function implemented by the irqdomain. irq_find_matching_fwnode() is made a wrapper around irq_find_matching_fwspec in order to preserve compatibility. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: devicetree@vger.kernel.org Cc: Jason Cooper <jason@lakedaemon.net> Cc: Will Deacon <will.deacon@arm.com> Cc: Rob Herring <robh+dt@kernel.org> Link: http://lkml.kernel.org/r/1460365075-7316-2-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/irqdomain.h | 15 ++++++++++++++- kernel/irq/irqdomain.c | 19 ++++++++++--------- 2 files changed, 24 insertions(+), 10 deletions(-) commit 7cec18a3906b52e855c9386650c0226bbe594a4c Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Mon Apr 25 08:14:24 2016 +0100 genirq: Add error code reporting to irq_{reserve,destroy}_ipi Make these functions return appropriate error codes when something goes wrong. Previously irq_destroy_ipi returned void making it impossible to notify the caller if the request could not be fulfilled. Patch 1 in the series added another condition in which this could fail in addition to the existing ones. irq_reserve_ipi returned an unsigned int meaning it could only return 0 on failure and give the caller no indication as to why the request failed. As time goes on there are likely to be further conditions added in which these functions can fail. These APIs and the IPI IRQ domain are new in 4.6 and the number of existing call sites are low, changing the API now has little impact on the code, while making it easier for these functions to grow over time. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: jason@lakedaemon.net Cc: marc.zyngier@arm.com Cc: ralf@linux-mips.org Cc: Qais Yousef <qsyousef@gmail.com> Cc: lisa.parratt@imgtec.com Cc: jiang.liu@linux.intel.com Link: http://lkml.kernel.org/r/1461568464-31701-2-git-send-email-matt.redfearn@imgtec.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/irqdomain.h | 5 ++--- kernel/irq/ipi.c | 31 +++++++++++++++++-------------- 2 files changed, 19 insertions(+), 17 deletions(-) commit 01292cea0df86ed4a1eb6450d6eda375ef925716 Author: Matt Redfearn <matt.redfearn@imgtec.com> Date: Mon Apr 25 08:14:23 2016 +0100 genirq: Make irq_destroy_ipi take a cpumask of IPIs to destroy Previously irq_destroy_ipi() would destroy IPIs to all CPUs that were configured by irq_reserve_ipi(). This change makes it possible to destroy just a subset of the IPIs. This may be useful to remove IPIs to CPUs that have been hot removed so that the IRQ numbers allocated within the IPI domain can be re-used. The original behaviour is restored by passing the complete mask that the IPI was created with. There are currently no users of this function that would break from the API change. Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com> Cc: linux-mips@linux-mips.org Cc: jason@lakedaemon.net Cc: marc.zyngier@arm.com Cc: ralf@linux-mips.org Cc: Qais Yousef <qsyousef@gmail.com> Cc: lisa.parratt@imgtec.com Cc: jiang.liu@linux.intel.com Link: http://lkml.kernel.org/r/1461568464-31701-1-git-send-email-matt.redfearn@imgtec.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de> include/linux/irqdomain.h | 2 +- kernel/irq/ipi.c | 18 ++++++++++++++---- 2 files changed, 15 insertions(+), 5 deletions(-) commit 4c37ce8608a8c6521726d4cd1d4f54424e8d095f Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon May 2 13:13:10 2016 +0200 gpio: make gpiod_to_irq() return negative for NO_IRQ If a translation returns zero, that means NO_IRQ, so we should return an error since the function is documented to return a negative code on error. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 551f4bc86807637098786c78afb78418ada4aa1f Author: Jeeja KP <jeeja.kp@intel.com> Date: Thu Apr 28 18:45:29 2016 +0530 ASoC: Intel: Boards: remove ignore_suspend for WoV streams On WoV we can suspend the DMA and keep the DSP pipelines only On, so remove the ignore_suspend for WoV streams but keep them for WoV endpoints. This helps in achieving better power by suspending DMAs Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/boards/skl_nau88l25_max98357a.c | 1 - sound/soc/intel/boards/skl_nau88l25_ssm4567.c | 1 - sound/soc/intel/boards/skl_rt286.c | 1 - 3 files changed, 3 deletions(-) commit 9a655db0201ef523683d700cb3f4508c08bc9d8c Author: Jeeja KP <jeeja.kp@intel.com> Date: Thu Apr 28 18:45:28 2016 +0530 ASoC: Intel: Skylake: Suspend PCMs when marked as active suspend For 'ignore_suspend' cases we need to keep DSP and pipes On, but can suspend the stream and pause the DMA as we are not rendering data during the suspended time. For this we can check the dai widget ignore_suspend flag in trigger suspend/resume, and start and stop the host DMA and host copier pipelines. Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-pcm.c | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) commit 1a13b1fafffd41c12a7068c4aa74f5a1d2210a07 Author: Dharageswari.R <dharageswari.r@intel.com> Date: Thu Apr 28 18:45:27 2016 +0530 ASoC: Intel: Skylake: Prevent sending Set DMA Control IPC if the widget is "On" If widget of a playback or capture DAI is already On, then no need not send the Set DMA Control IPC message to firmware. Signed-off-by: Dharageswari R <dharageswari.r@intel.com> Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-pcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 76222d6dd2e64c895735ab271ecc8b0df568981d Author: Mousumi Jana <mousumix.jana@intel.com> Date: Thu Apr 28 18:45:26 2016 +0530 ASoC: Intel: Skylake: Fix memory leak during init instance param_data variable is allocated during set module format of init instance is not getting freed and hence can cause a memory leak. So free it up. Signed-off-by: Mousumi Jana <mousumix.jana@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-messages.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 95536d8c29985167e745ff0d8c7cd7dcf4318e6b Author: Dharageswari.R <dharageswari.r@intel.com> Date: Thu Apr 28 18:45:25 2016 +0530 ASoC: Intel: Skylake: Fix the NULL pointer exception in dsp_clean up If request firmware fails at init, the code loader DMA allocation can be NULL, so check for boot complete before freeing up these resources Signed-off-by: Dharageswari R <dharageswari.r@intel.com> Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-sst-dsp.c | 2 -- sound/soc/intel/skylake/skl-sst.c | 4 ++++ 2 files changed, 4 insertions(+), 2 deletions(-) commit 0ce8428ba9ea13098b828d0881e28368a108709c Merge: fba0d70 8c0f551 Author: Mark Brown <broonie@kernel.org> Date: Mon May 2 12:02:09 2016 +0100 Merge tag 'asoc-fix-v4.6-rc5' into asoc-intel ASoC: Fixes for v4.6 This is a fairly large collection of fixes but almost all driver specific ones, especially to the new Intel drivers which have had a lot of recent development. The one core fix is a change to the debugfs code to avoid crashes in some relatively unusual configurations. commit 68af062b5f38510dc96635314461c6bbe1dbf2fe Merge: 1e166c7 04974df Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon May 2 07:48:23 2016 -0300 Merge tag 'v4.6-rc6' into patchwork Linux 4.6-rc6 * tag 'v4.6-rc6': (762 commits) Linux 4.6-rc6 EDAC: i7core, sb_edac: Don't return NOTIFY_BAD from mce_decoder callback Documentation/sysctl/vm.txt: update numa_zonelist_order description lib/stackdepot.c: allow the stack trace hash to be zero rapidio: fix potential NULL pointer dereference mm/memory-failure: fix race with compound page split/merge ocfs2/dlm: return zero if deref_done message is successfully handled Ananth has moved kcov: don't profile branches in kcov kcov: don't trace the code coverage code mm: wake kcompactd before kswapd's short sleep .mailmap: add Frank Rowand mm/hwpoison: fix wrong num_poisoned_pages accounting mm: call swap_slot_free_notify() with page lock held mm: vmscan: reclaim highmem zone if buffer_heads is over limit numa: fix /proc/<pid>/numa_maps for THP mm/huge_memory: replace VM_NO_THP VM_BUG_ON with actual VMA check mailmap: fix Krzysztof Kozlowski's misspelled name thp: keep huge zero page pinned until tlb flush mm: exclude HugeTLB pages from THP page_mapped() logic ... commit a90e173f3faf29d290bc72b957d94765a163b470 Author: Jean-Francois Moine <moinejf@free.fr> Date: Thu Apr 28 17:13:46 2016 +0200 dmaengine: sun6i: Add cyclic capability DMA cyclic transfers are required by audio streaming. Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 129 +++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 122 insertions(+), 7 deletions(-) commit 3435fb18533c27b288c19cfb7fe783e5433e36aa Author: Jean-Francois Moine <moinejf@free.fr> Date: Thu Apr 28 17:09:14 2016 +0200 dmaengine: sun6i: Remove useless check The transfer direction is now checked in set_config. There is no need to check it twice. Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 5 ----- 1 file changed, 5 deletions(-) commit a4eb36b02c596b9b91b22c6ef83f92397feb9250 Author: Jean-Francois Moine <moinejf@free.fr> Date: Thu Apr 28 17:07:02 2016 +0200 dmaengine: sun6i: Set default maxburst size and bus width Some DMA clients, as audio, don't set the maxburst size and bus width on the memory side when starting DMA transfers. This patch prevents such transfers to be aborted by providing system default values to the lacking ones. Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) commit 3a14c66d43d018baed96ceb74f9ab548878c09b8 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Wed Apr 27 14:15:40 2016 +0300 dmaengine: dw: pass platform data via struct dw_dma_chip We pass struct dw_dma_chip to dw_dma_probe() anyway, thus we may use it to pass a platform data as well. While here, constify the source of the platform data. Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/ata/sata_dwc_460ex.c | 2 +- drivers/dma/dw/core.c | 9 +++++---- drivers/dma/dw/pci.c | 5 +++-- drivers/dma/dw/platform.c | 5 +++-- include/linux/dma/dw.h | 5 ++++- sound/soc/intel/common/sst-firmware.c | 2 +- 6 files changed, 17 insertions(+), 11 deletions(-) commit 161c3d04aeca8a5bfffe3902786bdf0ccd8575c0 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Wed Apr 27 14:15:39 2016 +0300 dmaengine: dw: keep entire platform data in struct dw_dma Keep the entire platform data in the struct dw_dma. It makes the driver a bit cleaner. Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 30 +++++++++++++++--------------- drivers/dma/dw/platform.c | 4 ++-- drivers/dma/dw/regs.h | 5 ++--- include/linux/platform_data/dma-dw.h | 2 +- 4 files changed, 20 insertions(+), 21 deletions(-) commit 2e65060e803e046fc9b5ed0107494a452424845e Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Wed Apr 27 14:15:38 2016 +0300 dmaengine: dw: revisit data_width property There several changes are done here: - Convert the property to be in bytes Besides that this is a common practice for such property, the use of a value in bytes much more convenient than handling the encoded one. - Rename data_width to data-width in the device tree bindings The change leaves the support for the old format as well just in case someone will use a newer kernel with an old device tree blob. - While here, replace dwc_fast_ffs() by __ffs() Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/devicetree/bindings/dma/snps-dma.txt | 7 +++- arch/arc/boot/dts/abilis_tb10x.dtsi | 2 +- arch/arm/boot/dts/spear13xx.dtsi | 4 +-- drivers/dma/dw/core.c | 42 ++++++---------------- drivers/dma/dw/platform.c | 5 ++- include/linux/platform_data/dma-dw.h | 2 +- 6 files changed, 24 insertions(+), 38 deletions(-) commit 969f750fc63d3fd2f26eceedcdeca5878b785b2e Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Wed Apr 27 14:15:37 2016 +0300 dmaengine: dw: platform: check nr_masters to be non-zero The value of nr_masters equal to 0 is invalid since this DMA controller has to have at least one master. Check this before we proceed with the rest of properties. Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/platform.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 00ef4490ebfa417094014d19b1e56fde0b6c1685 Author: Shardar Shariff Md <smohammed@nvidia.com> Date: Sat Apr 23 15:06:00 2016 +0530 dmaengine: tegra-apb: proper default init of channel slave_id Initialize default channel slave_id(req_sel) to invalid id (i.e max supported slave id + 1) to avoid overwriting of slave_id during tegra_dma_slave_config() with client data if slave_id is not initialized through DT Signed-off-by: Shardar Shariff Md <smohammed@nvidia.com> Reviewed-by: Jon Hunter <jonathanh@nvidia.com> Tested-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/tegra20-apb-dma.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) commit 0eef727a47c5ead7d8cf3373bdd81f280303e056 Author: Martin Sperl <kernel@martin.sperl.org> Date: Fri Apr 22 07:12:48 2016 +0000 dmaengine: bcm2835: fix typo/added newline in legacy-mode warning message Fix typo in warning message that there is no "interrupt-names" property defined in the device-tree and legacy-mode is used. Also added newline to end of message. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 488aab3d0c02b77d8d8f63a6abddb9d8beeea11a Author: Lars Persson <lars.persson@axis.com> Date: Wed Apr 27 17:21:29 2016 +0200 mmc: usdhi6rol0: add pinctrl to set pin drive strength Some boards need different pin drive strength for the UHS mode. Add an optional pinctrl setting with two pin states covering UHS speeds and other speeds. Signed-off-by: Lars Persson <larper@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/usdhi6rol0.c | 48 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) commit 0cd59df9f028319e193113280d51c9d87b0b36ad Author: Lars Persson <lars.persson@axis.com> Date: Wed Apr 27 17:21:28 2016 +0200 mmc: usdhi6rol0: add support for UHS modes Add a start_signal_voltage_switch() operation to support enabling of UHS modes. Signed-off-by: Lars Persson <larper@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/usdhi6rol0.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 701dcef72f45edf942cb06284c37b4fdbd4cd77b Author: Lars Persson <lars.persson@axis.com> Date: Wed Apr 27 17:21:27 2016 +0200 mmc: usdhi6rol0: do not announce UHS capabilities The driver in its current form does not support UHS at all due to a missing start_signal_voltage_switch callback. Also when this callback is added we should let the device tree control UHS capabilities using the standard mmc bindings. Signed-off-by: Lars Persson <larper@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/usdhi6rol0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f0be051e5be1ddad4f4bc53ca3eb438e0ca2895f Author: Lars Persson <lars.persson@axis.com> Date: Wed Apr 27 17:21:26 2016 +0200 mmc: dt: usdhi6rol0: add optional pinctrl binding Add a pinctrl binding to specify different pin settings for high speed modes and UHS modes. Signed-off-by: Lars Persson <larper@axis.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Documentation/devicetree/bindings/mmc/usdhi6rol0.txt | 6 ++++++ 1 file changed, 6 insertions(+) commit 010629436d83dc6a5c489847b0a1b8d5449a962f Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Thu Apr 28 08:18:11 2016 +0200 mmc: sh_mobile_sdhi: remove obsolete include file A few SH boards include the file but don't make use of it (no named interrupts). The SDHI code removed support for this feature as well. So, drop the references and ultimately remove the unneeded file. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Rich Felker <dalias@libc.org> Acked-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> arch/sh/boards/board-sh7757lcr.c | 1 - arch/sh/boards/mach-ap325rxa/setup.c | 1 - arch/sh/boards/mach-ecovec24/setup.c | 1 - arch/sh/boards/mach-kfr2r09/setup.c | 1 - arch/sh/boards/mach-migor/setup.c | 1 - arch/sh/boards/mach-se/7724/setup.c | 1 - include/linux/mmc/sh_mobile_sdhi.h | 10 ---------- 7 files changed, 16 deletions(-) commit 184adf202bca05ca34380cb53b349307aede7ef3 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Apr 27 18:51:27 2016 +0200 mmc: tmio: document CTL_STATUS handling Now that reading CTL_STATUS is consistent, we can remove CTL_STATUS2 and document how this is handled internally. Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit a21553c9e0c236ae241d9f4333aafae24ae19dfc Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Apr 27 18:51:26 2016 +0200 mmc: tmio/sdhi: distinguish between SCLKDIVEN and ILL_FUNC This bit has a different meaning in SDHI and original TMIO. Document that and use the proper naming. Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 3 ++- drivers/mmc/host/tmio_mmc.h | 3 ++- drivers/mmc/host/tmio_mmc_pio.c | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) commit 83e95351d49f60d6cf37706bf94529116d03e648 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Apr 27 18:51:25 2016 +0200 mmc: tmio: use CTL_STATUS consistently To prevent confusion, use the virtual u32 CTL_STATUS in card_busy() the same way as in other parts of this driver. Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 3 +-- drivers/mmc/host/tmio_mmc_pio.c | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) commit 2cafc5cb4fcbe648d0d16ec5039ee292d85d7bfa Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Apr 27 18:51:24 2016 +0200 mmc: tmio: use BIT() within defines BIT() makes it easier to match the bits to the datasheet. This is especially important here, since some variants have different names in their datasheets (like with Renesas R-Car). Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 44 +++++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 21 deletions(-) commit 2c54506b769d0633aac8f0511ef23f76bedeec9e Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Apr 27 18:51:23 2016 +0200 mmc: tmio: give read32/write32 functions more descriptive names Looking at the backlogs, I am not the only one who missed that the above functions do not read u32 from one register, but create a virtual u32 from reading to adjacent u16 registers (which depending on 'bus_shift' can be up to 8 byte apart). Because this driver supports old hardware for which we don't have documentation, I first wrongly assumed there was a variant which had a few u32 registers. Let's give the functions more descriptive names to make it more obvious what is happening. Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 5 ++--- drivers/mmc/host/tmio_mmc_pio.c | 22 +++++++++++----------- 2 files changed, 13 insertions(+), 14 deletions(-) commit db863d8966818d3af3e415b5f60fcfeceba803c6 Author: Tony Lindgren <tony@atomide.com> Date: Tue Apr 26 16:46:23 2016 -0700 mmc: omap_hsmmc: Check if MMC slot name is passed in pdata The legacy user space for n900 relies on the MMC slot names. Let's check if those are passed in pdata and use them. As this makes the DT booting compatible with legacy booting, we should be able to start dropping omap3 legacy booting support in v4.8. Cc: Ulf Hansson <ulf.hansson@linaro.org> Cc: Kishon Vijay Abraham I <kishon@ti.com> Cc: linux-mmc@vger.kernel.org Signed-off-by: Tony Lindgren <tony@atomide.com> Tested-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/omap_hsmmc.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit ab22f516715086760cd01862d60afc0dd3ff30b3 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 22:29:10 2016 +0200 mmc: sh_mobile_sdhi: remove obsolete support for sh7372 There is no support for this platform in the kernel anymore. Reported-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 1 - 1 file changed, 1 deletion(-) commit ba9e91577843ad394a4908ea3acbbe4c78293557 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 22:34:46 2016 +0200 mmc: sh_mmcif: remove obsolete support for sh7372 There is no support for this platform in the kernel anymore. Make the Kconfig text more generic, so it won't get stale anymore. Reported-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2272c841ee301402ea7a01fc727619af1f97f0cc Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:27 2016 +0200 mmc: sh_mobile_sdhi: simplify code for voltage switching A last minute fix applied by Ulf made room for some simplification. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit ac86045ee9cd89774030ff1c21c7ff35f1c1eeaa Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:26 2016 +0200 mmc: tmio: merge distributed include files There is no reason to have a public and private header file. Merge them into a private one, so looking up symbols is less confusing. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 56 ++++++++++++++++++++++++++++++- drivers/mmc/host/tmio_mmc_dma.c | 1 - drivers/mmc/host/tmio_mmc_pio.c | 1 - include/linux/mmc/tmio.h | 73 ----------------------------------------- 4 files changed, 55 insertions(+), 76 deletions(-) commit 958401266e5812619b04765bef23712a72badd55 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:25 2016 +0200 mmc: tmio: simplify irq handler Having just one irq handler again, let's include the 'card_status' function in the main handler which is way more readable. Drop a useless debug output while here. It should be a dev_dbg in case we ever need it again. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc_pio.c | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) commit 4da986703882b2987b5731e8b31b88eece8c2fbb Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:24 2016 +0200 mmc: tmio: remove now unneeded seperate irq handlers We removed installation of separate handlers previously, so we can also remove the separate handlers. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 3 --- drivers/mmc/host/tmio_mmc_pio.c | 31 ++----------------------------- 2 files changed, 2 insertions(+), 32 deletions(-) commit adcbc949046366edb46e44f72ac9197c32675cfd Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:23 2016 +0200 mmc: sh_mobile_sdhi: remove obsolete irq_by_name registration There is no user left in the kernel, so this code can be removed. (Legacy, non-DT sh_mobile boards have been removed a while ago.) The diff looks more complicated than it is: The if-block for multiplexed isr is now the main code path, the rest is removed. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 57 ++++++--------------------------------- 1 file changed, 8 insertions(+), 49 deletions(-) commit 13bbd8af65895c524c27850495fadf23449f9f3d Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 26 17:55:22 2016 +0200 mmc: sh_mobile_sdhi: don't use array for DT configs We won't access an index based array to get our DT config, but create separate structs instead. So, remove the array which only wastes memory. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit b10fa99e9a5f8b37a4eae1522048a327fe7ce480 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Apr 7 14:36:46 2016 +0200 mmc: block: Convert to IDA for partition device indexes Instead of using an mmc specific implementation to deal with indexes through a BITMAP, let's convert to use the IDA library. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 36 +++++++++++++++++++++++++++--------- 1 file changed, 27 insertions(+), 9 deletions(-) commit 06b5cca5e7f797b8fffa269fa6298a84256c3295 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Apr 7 14:23:23 2016 +0200 mmc: block: Release index in partition allocation error path If the allocation of a new partition fails, let's make sure to also release the previously picked device index. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/card/block.c | 1 + 1 file changed, 1 insertion(+) commit 5674a9baba32dfff9585bd50e604a06bc9b1c2b8 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Apr 7 11:40:59 2016 +0200 mmc: core: Convert from IDR to IDA for host indexes As IDA is more lightweight than IDR, let's convert to use that instead. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/host.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit 74479c5d5009ebe28de69dd67b769c05ad953a5c Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 14 13:19:40 2016 +0900 mmc: sdhci: use IS_ENABLE(CONFIG_LEDS_CLASS) to enable LED struct members defined(CONFIG_LEDS_CLASS) || defined(CONFIG_LEDS_CLASS_MODULE) is equivalent to: IS_ENABLED(CONFIG_LEDS_CLASS) Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4f78230fd79d6f9e659f205b4ab0799e1635554d Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 14 13:19:39 2016 +0900 mmc: sdhci: use IS_REACHABLE(CONFIG_LEDS_CLASS) to enable LED code defined(CONFIG_LEDS_CLASS) || (defined(CONFIG_LEDS_CLASS_MODULE) && \ defined(CONFIG_MMC_SDHCI_MODULE)) is equivalent to: defined(CONFIG_LEDS_CLASS) || (defined(CONFIG_LEDS_CLASS_MODULE) && \ defined(MODULE)) and it can also be written shortly as: IS_REACHABLE(CONFIG_LEDS_CLASS) Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 4228b21390f55616e50d2cfa3a374489b930a130 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Wed Apr 20 09:24:03 2016 +0300 mmc: sdhci: Remove SDHCI_SDR104_NEEDS_TUNING SDHCI_SDR104_NEEDS_TUNING was originally named SDHCI_HS200_NEEDS_TUNING and was added in commit 069c9f142822 ("mmc: host: Adds support for eMMC 4.5 HS200 mode"). That commit conflated SDHCI_SDR50_NEEDS_TUNING and SDHCI_HS200_NEEDS_TUNING due to what appears to be misplaced parentheses. Commit 156e14b126ff ("mmc: sdhci: fix caps2 for HS200") made HS200 configuration equivalent to SDR104 configuration, renaming SDHCI_HS200_NEEDS_TUNING to SDHCI_SDR104_NEEDS_TUNING despite tuning for HS200 now being non-optional. The mix-up with SDHCI_SDR50_NEEDS_TUNING remained and became more obvious after commit 4b6f37d3a379 ("mmc: sdhci: clean up sdhci_execute_tuning() decision") where the author noted the patch was "reflecting what the original code was doing, it shows that it may not be what the author actually intended." The way the code is currently written, SDHCI_SDR104_NEEDS_TUNING causes tuning to be done always for SDR50 mode if SDR104 mode is also supported by the host controller. That makes no sense because we already have capabilities bit SDHCI_USE_SDR50_TUNING and corresponding flag SDHCI_SDR50_NEEDS_TUNING for that purpose. Given the dubious origins of SDHCI_SDR104_NEEDS_TUNING, it seems reasonable to remove it. The benefit being SDR50 mode will now not un-nessessarily do tuning. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 7 +------ drivers/mmc/host/sdhci.h | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) commit 5c59065be5a1b347e06d1ad57e017ae2992e606a Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:31 2016 +0900 mmc: sdhci-pltfm: call platform_get_irq() before sdhci_alloc_host() Swap the call order of sdhci_alloc_host() and platform_get_irq(). It makes sdhci_alloc_host() the last function that can fail in the sdhci_pltfm_init(). So, we can drop the sdhci_free_host() call from the failure path. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) commit 378382b8d09d43371872103a58e4d4a7ff14b556 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:30 2016 +0900 mmc: sdhci-pltfm: move devm_ioremap_resource() up Call devm_ioremap_resource() right after platform_get_resource(). This saves the error check of platform_get_resource() because devm_ioremap_resource() checks if the given resource is NULL. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit e30568d43f5ea63e61906d2a90c9b981ef829ff7 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:29 2016 +0900 mmc: sdhci-pltfm: use devm_ioremap_resource() The chain of devm_request_mem_region() and devm_ioremap() can be replaced with devm_ioremap_resource(). Also, we can drop the error messages because devm_ioremap_resource() displays similar messages on error. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) commit 6113d8123624210fbc9412a1959d230fbd6ccf0d Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:28 2016 +0900 mmc: sdhci-pltfm: use devm_ioremap() Use the managed variant of ioremap(). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e95f644d8b112647a8da5314e5e93b59ac8d3f08 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:27 2016 +0900 mmc: sdhci-pltfm: use devm_request_mem_region() Use the managed variant of request_mem_region(). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit 0a782cb1fc2407163123fccd01f65da70d4d2cd8 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:26 2016 +0900 mmc: sdhci-pltfm: check return value of platform_get_irq() The function platform_get_irq() can fail; it returns a negative error code on failure. A negative IRQ number will make sdhci_add_host() fail to request IRQ anyway, but it makes sense to let it fail earlier here. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 5 +++++ 1 file changed, 5 insertions(+) commit 0b2ed795e1f49dace195f3a4d35eee281b6cfbbf Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 11:16:25 2016 +0900 mmc: sdhci-pltfm: drop error message for too small MMIO resource size The requirement resource_size >= 0x100 may not necessarily be reasonable; for example, sdhci-dove appears to sidestep some registers in sdhci_dove_readw(). Moreover, current code displays an error message for too small resource size, but still moves forward. Every DT should be responsible for describing its properties correctly, so lets's remove this error message from the common framework. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pltfm.c | 3 --- 1 file changed, 3 deletions(-) commit 87e88659afd1dc17d123f5759184254897494579 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 15 20:16:12 2016 +0900 mmc: core: drop unnecessary bit checking This if-block is going to call mmc_card_set_blockaddr(), so mmc_card_blockaddr() right before it is redundant. I am fixing the block comment style while I am here. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/mmc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit d97a1e5d7cd2b5b0edc02a40fe6897b710c9e10f Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Apr 14 14:02:16 2016 +0100 mmc: pwrseq: convert to proper platform device simple-pwrseq and emmc-pwrseq drivers rely on platform_device structure from of_find_device_by_node(), this works mostly. But, as there is no driver associated with this devices, cases like default/init pinctrl setup would never be performed by pwrseq. This becomes problem when the gpios used in pwrseq require pinctrl setup. Currently most of the common pinctrl setup is done in drivers/base/pinctrl.c by pinctrl_bind_pins(). There are two ways to solve this issue on either convert pwrseq drivers to a proper platform drivers or copy the exact code from pcintrl_bind_pins(). I prefer converting pwrseq to proper drivers so that other cases like setting up clks/parents from dt would also be possible. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/Kconfig | 21 ++++++++ drivers/mmc/core/Makefile | 4 +- drivers/mmc/core/pwrseq.c | 108 ++++++++++++++++++--------------------- drivers/mmc/core/pwrseq.h | 19 ++++--- drivers/mmc/core/pwrseq_emmc.c | 75 +++++++++++++++++---------- drivers/mmc/core/pwrseq_simple.c | 79 +++++++++++++++------------- 6 files changed, 177 insertions(+), 129 deletions(-) commit f01b72d0fd53b61cafd25b16d15e18b1ef8ae065 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Apr 14 14:02:15 2016 +0100 mmc: pwrseq_emmc: add to_pwrseq_emmc() macro This patch adds to_pwrseq_emmc() macro to make the code more readable. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/pwrseq_emmc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 5b96fea730ab79bdf6f8071cadf8208296bf5e8d Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Apr 14 14:02:14 2016 +0100 mmc: pwrseq_simple: add to_pwrseq_simple() macro This patch adds to_pwrseq_simple() macro to make the code more readable. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/pwrseq_simple.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit 061d17a6664ec3e8c358e086c5c1ef26c943bff6 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Apr 12 14:25:09 2016 +0300 mmc: sdhci: Tidy together LED code ifdef's make the code more complicated and harder to read. Move all the LED code together to reduce the ifdef's to one place. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 96 +++++++++++++++++++++++++++++++----------------- 1 file changed, 63 insertions(+), 33 deletions(-) commit eb5c20de351867120c8dfb6d523d5795a3125b02 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Apr 12 14:25:08 2016 +0300 mmc: sdhci: Fix error paths in sdhci_add_host() Some error paths in sdhci_add_host() simply returned without cleaning up. Also the return value from mmc_add_host() was not being checked. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 36 +++++++++++++++++++++++++++--------- 1 file changed, 27 insertions(+), 9 deletions(-) commit d310ae4936ccf1186851692c511483c794dd7701 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Apr 12 14:25:07 2016 +0300 mmc: sdhci: Remove redundant condition The logic '!mmc.f_max || (mmc.f_max && mmc.f_max > max_clk)' is equivalent to '!mmc.f_max || mmc.f_max > max_clk'. Reported-by: David Binderman <dcb314@hotmail.com> Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 706e86e9de7cfd5220784f6329d92f65de883d71 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Apr 12 14:25:06 2016 +0300 mmc: sdhci-acpi: Set MMC_CAP_AGGRESSIVE_PM for Broxton controllers Set MMC_CAP_AGGRESSIVE_PM for Broxton host controllers. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-acpi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e8ef51763106dc40037c9ae207acf505bb4b71b1 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Apr 12 14:25:05 2016 +0300 mmc: sdhci-pci: Set MMC_CAP_AGGRESSIVE_PM for Broxton controllers Set MMC_CAP_AGGRESSIVE_PM for Broxton host controllers. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pci-core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 7758229135e30d3f58378969eefb41aecc620a9d Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Apr 7 11:13:10 2016 +0200 mmc: sdhci: Remove SDHCI_QUIRK2_NEED_DELAY_AFTER_INT_CLK_RST SDHCI_QUIRK2_NEED_DELAY_AFTER_INT_CLK_RST quirk is not used anymore so remove it. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 2 -- drivers/mmc/host/sdhci.h | 5 ----- 2 files changed, 7 deletions(-) commit 4e289a7d2f55253c1f86bfab5d9187ea97daee44 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Apr 7 11:13:09 2016 +0200 mmc: sdhci-of-at91: Implement specific ->set_clock() function Disabling the internal clock while configuring the SD card clock can lead to internal clock stabilization issue and/or unexpected switch to the base clock when using presets. A quirk SDHCI_QUIRK2_NEED_DELAY_AFTER_INT_CLK_RST was introduced to fix these bugs. The cause was assumed to be a too long internal re-synchronisation but it seems in some cases the delay (even if longer) doesn't fix this bug. The safest workaround is to not disable/enable the internal clock during the SD card clock configuration. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-of-at91.c | 48 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) commit fb9ee04779cf34a10ef7afaabf4e8055688777c4 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Apr 7 11:13:08 2016 +0200 mmc: sdhci: Introduce sdhci_calc_clk() In order to remove the SDHCI_QUIRK2_NEED_DELAY_AFTER_INT_CLK_RST and to reduce code duplication, put the code relative to the SD clock configuration in a function which can be used by hosts for the implementation of the ->set_clock() callback. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci.c | 36 ++++++++++++++++++++++++------------ drivers/mmc/host/sdhci.h | 2 ++ 2 files changed, 26 insertions(+), 12 deletions(-) commit 02d0b68524c0848f5de89a0ecd1e97790018d7d3 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Apr 11 15:32:41 2016 +0200 mmc: sdhci: Move sdhci_runtime_pm_bus_off|on() to avoid pre-definition There are no need to have two versions of sdhci_runtime_pm_bus_off|on(), depending on whether CONFIG_PM is set or unset. Thus it's easy to move the implementation of these functions a bit earlier to avoid the unnecessary pre-definition of them, so let's do that. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Adrian Hunter <adrian.hunter@intel.com> drivers/mmc/host/sdhci.c | 44 ++++++++++++++++---------------------------- 1 file changed, 16 insertions(+), 28 deletions(-) commit dc4c90fa6510ab8d5eb5e06fd7546c9cb00932c5 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 8 14:22:37 2016 +0900 mmc: sdhci-pic32: remove owner assignment A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pic32.c | 1 - 1 file changed, 1 deletion(-) commit 15e82076a0edbebedbe12652b4ad8f1d93bcb7fe Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Apr 7 10:56:39 2016 +0200 mmc: sdhci: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Moreover as SDHCI have its own wrapper functions for runtime PM these becomes superfluous, so let's remove them as well. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Adrian Hunter <adrian.hunter@intel.com> drivers/mmc/host/sdhci.c | 55 ++++-------------------------------------------- 1 file changed, 4 insertions(+), 51 deletions(-) commit 4e6c71788d6bb0e5438fc9211fa6e52dcca01474 Author: Gwendal Grignou <gwendal@chromium.org> Date: Fri Apr 1 16:04:22 2016 -0700 mmc: core: Do regular power cycle when lacking eMMC HW reset support The eMMC HW reset may be implemented either via the host ops ->hw_reset() callback or through DT and the eMMC pwrseq. Additionally some eMMC cards don't support HW reset. To allow a reset to be done for the different combinations of mmc hosts and eMMC/MMC cards, let's implement a fallback via trying a regular power cycle. This improves the mmc block layer retry mechanism of failing I/O requests. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> [Ulf: Rewrote changelog] Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/core.c | 5 +++-- drivers/mmc/core/mmc.c | 24 +++++++++++------------- 2 files changed, 14 insertions(+), 15 deletions(-) commit 6aef2eecc4d4c9edb8c8d3e3a7f6af3cee42b2ec Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 15:43:41 2016 +0100 mmc: tmio: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Ian Molton <ian@mnementh.co.uk> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc_pio.c | 19 ------------------- 1 file changed, 19 deletions(-) commit c8037e799b412562e906a2e95feaf177ba8c5df2 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:40:07 2016 +0100 mmc: sdhci-pci: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-pci-core.c | 5 ----- 1 file changed, 5 deletions(-) commit 4d56e9ae6b0cb227e1064be514b47ea477a38108 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:33:35 2016 +0100 mmc: sdhci-acpi: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sdhci-acpi.c | 5 ----- 1 file changed, 5 deletions(-) commit 5d7435f5cc2a3a214f3b9c4fb8bbd3cae9304e4c Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:28:36 2016 +0100 mmc: omap_hsmmc: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/omap_hsmmc.c | 15 --------------- 1 file changed, 15 deletions(-) commit 567979fba16ab3b9803f456a653bfe19e891cd3c Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:21:25 2016 +0100 mmc: mediatek: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Chaotian Jing <chaotian.jing@mediatek.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/mtk-sd.c | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) commit d8b7d6b7f956eac49e9753ac6786ac4e53e075c3 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:17:00 2016 +0100 mmc: mmci: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/mmci.c | 20 -------------------- 1 file changed, 20 deletions(-) commit bc94440d4e1c26cf5a147f0193d824c752faebd6 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Mon Mar 21 14:09:07 2016 +0100 mmc: atmel-mci: Remove redundant runtime PM calls Commit 9250aea76bfc ("mmc: core: Enable runtime PM management of host devices"), made some calls to the runtime PM API from the driver redundant. Especially those which deals with runtime PM reference counting, so let's remove them. Cc: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Ludovic Desroches <ludovic.desroches@atmel.com> Tested-by: Ludovic Desroches <ludovic.desroches@atmel.com> drivers/mmc/host/atmel-mci.c | 9 --------- 1 file changed, 9 deletions(-) commit d0071281cfb7195af3fa087815cdee26ddfb4b7f Author: David Lechner <david@lechnology.com> Date: Tue Apr 5 12:31:51 2016 -0500 ARM: davinci: remove mmc dma resources The davinci_mmc driver no longer uses platform resources for getting dma channels. Instead lookup is now done using dma_slave_map. Signed-off-by: David Lechner <david@lechnology.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> arch/arm/mach-davinci/devices-da8xx.c | 20 -------------------- arch/arm/mach-davinci/devices.c | 16 ---------------- 2 files changed, 36 deletions(-) commit e2f3bfbdc9f4929d767bc0d8033322a72d51193e Author: David Lechner <david@lechnology.com> Date: Tue Apr 5 12:31:50 2016 -0500 mmc: davinci: prepare clock When trying to use this driver with the common clock framework, enabling the clock fails because it was not prepared. This fixes the problem by calling clk_prepare and clk_enable in a single function. Ditto for clk_disable_unprepare. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/davinci_mmc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 62ac52b2fbcc8036d1fd4860b232fef2d554fa4d Author: David Lechner <david@lechnology.com> Date: Tue Apr 5 12:31:49 2016 -0500 mmc: davinci: fix unwinding in probe Unwiding from an error in davinci_mmcsd_probe was a mess. Some errors were not handled and not all paths unwound correctly. Also using devm_ where possible to simplify things. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/davinci_mmc.c | 100 +++++++++++++++++------------------------ 1 file changed, 40 insertions(+), 60 deletions(-) commit 2edeb8540bc21247906e13ad2a08317d6fa410e7 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Thu Mar 31 15:34:10 2016 +0800 mmc: dw_mmc: remove setup_clock callback Now, no dw_mmc variant drivers use this callback, let's remove it. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc.c | 9 --------- drivers/mmc/host/dw_mmc.h | 2 -- 2 files changed, 11 deletions(-) commit 7c2c2cc8f909f76965c0d79b04a111ee2b01d63f Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Thu Mar 31 15:34:02 2016 +0800 mmc: dw_mmc-exynos: remove dw_mci_exynos_setup_clock We combine what dw_mci_exynos_setup_clock does with init hook to simplify the code Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-exynos.c | 8 -------- 1 file changed, 8 deletions(-) commit 1975676080c9fe225015f42801a6c8d5e1e5f97b Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Thu Mar 31 15:33:53 2016 +0800 mmc: dw_mmc-rockchip: remove setup_clock for rockchip We remove setup_clock hook and combine it into init hook to simplify the code Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-rockchip.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 5659eeaddd47982d03a19c651384456cc3164acc Author: Jaehoon Chung <jh80.chung@samsung.com> Date: Thu Mar 31 14:53:18 2016 +0900 mmc: dw_mmc: exynos: add the function for controlling SMU Some of Exynos has the Security management Unit(SMU). This patch adds the function for controlling SMU. In future, if exynos needs to control SMU, it can be implemented in "config_smu" function, not "init" function. Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-exynos.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit 6929eeec2a7c5fe29d8d5cd0873089fc733943b0 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed Feb 3 11:26:04 2016 +0800 mmc: dw_mmc: remove unused EVENT_XFER_ERROR EVENT_XFER_ERROR isn't been used now, so it can be removed. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> include/linux/mmc/dw_mmc.h | 1 - 1 file changed, 1 deletion(-) commit ab925a315eb3c6cd9fe25ff0ca5babb94a98b55c Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed Mar 9 10:34:46 2016 +0800 mmc: dw_mmc: avoid using dmaengine_terminate_all dmaengine_terminate_all is deprecated and should be replaced by more explicit synchronous and asynchronous terminate functions. This change is based on the commit b36f09c3c441 ("dmaengine: Add transfer termination synchronization support"). Currently dw_mci_stop_dma may be called under the spinlock, let's migrate dmaengine_terminate_all to async terminate. This could avoid the race condition of use-after-free resouce of dmaengine once slave-dma driver implement the synchronize method. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 49b17858c19b94d46e3d872f85eccba45fff21f4 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed Mar 9 10:33:55 2016 +0800 mmc: dw_mmc: fix warning reported by kernel-doc Try to fix the warning reported by: scripts/kernel-doc -man -v include/linux/mmc/dw_mmc.h > /dev/null warning: No description found for parameter 'irq_lock' warning: No description found for parameter 'stop_abort' warning: No description found for parameter 'prev_blksz' warning: No description found for parameter 'timing' warning: No description found for parameter 'ring_size' warning: No description found for parameter 'dms' warning: No description found for parameter 'phy_regs' warning: No description found for parameter 'fifoth_val' warning: No description found for parameter 'vqmmc_enabled' warning: No description found for parameter 'cmd11_timer' warning: Excess struct/union/enum/typedef member 'card_tasklet' description in 'dw_mci' Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> include/linux/mmc/dw_mmc.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit c6a9bf99dd458147241ef93817d18e92c3650530 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Tue Mar 1 15:12:53 2016 +0800 mmc: dw_mmc-rockchip: fix failing to mount partition with "discard" Without MMC_CAP_ERASE support, we fail to mount partition with "discard" option since mmc_queue_setup_discard is limited for checking mmc_can_erase. Without doing mmc_queue_setup_discard, blk_queue_discard fails to test QUEUE_FLAG_DISCARD flag, so we get the following log from f2fs(actually similar to other file system): mounting with "discard" option, but the device does not support discard Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-rockchip.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 31fa83539fd7a8411b9bc9da77826835d2502886 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed Feb 3 11:26:44 2016 +0800 mmc: dw_mmc-rockchip: remove dw_mci_rockchip_pmops dw_mci_rockchip_pmops just copy-paste what dw_mci_pltfm_pmops have done. Let's remove it. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/dw_mmc-rockchip.c | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) commit 057a4592e6dbad0e571628968f3e20a3706e4701 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:37 2016 +0200 mmc: sh_mobile_sdhi: Add UHS-I mode support Implement voltage switch, supporting modes up to SDR-50. Based on work by Shinobu Uehara, Rob Taylor, William Towle and Ian Molton. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Documentation/devicetree/bindings/mmc/tmio_mmc.txt | 3 ++ drivers/mmc/host/sh_mobile_sdhi.c | 52 ++++++++++++++++++++++ 2 files changed, 55 insertions(+) commit 93b6911ac1ffc1fc9aba92c9e19063d47e7cf236 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:36 2016 +0200 mmc: host: add note that set_ios needs to handle 0Hz properly While here, refactor the comments so that they are before the declaration they are referring to. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> include/linux/mmc/host.h | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) commit 148634d24d4a7dc82a49efcf1a215e1d0695f62c Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:35 2016 +0200 mmc: tmio: stop clock when 0Hz is requested Setting frequency to 0 is not enough, the clock explicitly has to be disabled. Otherwise voltage switching (which needs SDCLK to be quiet) fails for various cards. Because we now do the 'new_clock == 0' check right at the beginning, the indentation level of the rest of the code can be decreased a little. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc_pio.c | 50 +++++++++++++++++++++-------------------- 1 file changed, 26 insertions(+), 24 deletions(-) commit 7fbc030da800d07193da4a4355ca2e197cf00cfb Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:34 2016 +0200 mmc: tmio: always start clock after frequency calculation Starting the clock is always done after frequency change anyhow, so we can do it directly after the clock calculation and remove the specific calls. This is the first part of doing proper clock de-/activation at calculation time. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc_pio.c | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) commit 452e5eef6d311e52f657b34d999758107ec3dd4a Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:33 2016 +0200 mmc: tmio: Add UHS-I mode support Based on work by Shinobu Uehara and Ben Dooks. This adds the voltage switch operation needed for all UHS-I modes, but not the tuning needed for SDR-104 which will come later. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/tmio_mmc.h | 2 ++ drivers/mmc/host/tmio_mmc_pio.c | 12 +++++++++++- include/linux/mmc/tmio.h | 2 ++ 3 files changed, 15 insertions(+), 1 deletion(-) commit 2fb55956ce4db259a5d6ce41cc32368b5055575e Author: Ben Hutchings <ben.hutchings@codethink.co.uk> Date: Fri Apr 1 17:44:32 2016 +0200 mmc: tmio, sh_mobile_sdhi: Add support for variable input clock frequency Currently tmio_mmc assumes that the input clock frequency is fixed and only its own clock divider can be changed. This is not true in the case of sh_mobile_sdhi; we can use the clock API to change it. In tmio_mmc: - Delegate setting of f_min from tmio to the clk_enable operation (if implemented), as it can be smaller than f_max / 512 - Add an optional clk_update operation called from tmio_mmc_set_clock() that updates the input clock frequency - Rename tmio_mmc_clk_update() to tmio_mmc_clk_enable(), to avoid confusion with the clk_update operation In sh_mobile_sdhi: - Make the setting of f_max conditional; it should be set through the max-frequency property in the device tree in future - Set f_min based on the input clock's minimum frequency - Implement the clk_update operation, selecting the best input clock frequency for the bus frequency that's wanted sh_mobile_sdhi_clk_update() is loosely based on Kuninori Morimoto's work in sh_mmcif. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 56 +++++++++++++++++++++++++++++++++++++-- drivers/mmc/host/tmio_mmc.h | 2 ++ drivers/mmc/host/tmio_mmc_pio.c | 24 +++++++---------- 3 files changed, 66 insertions(+), 16 deletions(-) commit 0ea28210c15680bbabc3d6079f771f1a1e69509a Author: Ben Hutchings <ben.hutchings@codethink.co.uk> Date: Fri Apr 1 17:44:31 2016 +0200 mmc: tmio, sh_mobile_sdhi: Pass tmio_mmc_host ptr to clk_{enable, disable} ops Change the clk_enable operation to take a pointer to the struct tmio_mmc_host and have it set f_max. For consistency, also change the clk_disable operation to take a pointer to struct tmio_mmc_host. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mobile_sdhi.c | 12 +++++------- drivers/mmc/host/tmio_mmc.h | 4 ++-- drivers/mmc/host/tmio_mmc_pio.c | 4 ++-- 3 files changed, 9 insertions(+), 11 deletions(-) commit 7962fc376f603547b130c0fd7932ac6e9df4ee8b Author: Baolin Wang <baolin.wang@linaro.org> Date: Thu Mar 31 11:16:27 2016 +0800 mmc: core: Provide tracepoints for request processing This patch provides some tracepoints for the lifecycle of a mmc request from starting to completion to help with performance analysis of MMC subsystem. Signed-off-by: Baolin Wang <baolin.wang@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/core/core.c | 7 ++ include/trace/events/mmc.h | 182 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 189 insertions(+) commit 1ca4d3596e419d65bbc6a1276b3f569c6c83510c Author: Andreas Fenkart <afenkart@gmail.com> Date: Mon Mar 21 00:58:08 2016 +0100 mmc: omap_hsmmc: pass omap_hsmmc_host pointer directly unnecessary indirection via 'struct device' back to omap_hsmmc_host Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/omap_hsmmc.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) commit 673267f0bd606057bbc897aa7691e1eede8d3a58 Author: David Lechner <david@lechnology.com> Date: Wed Mar 16 22:45:32 2016 -0500 mmc: davinci: remove matching string The string "MMCSDCLK" is not actually used for clock lookup, so can be removed. Signed-off-by: David Lechner <david@lechnology.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/davinci_mmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0a4d7236c5852f1643dad3ea89002ab2620302c6 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Wed Mar 16 22:45:31 2016 -0500 mmc: davinci_mmc: Use dma_request_chan() to requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/davinci_mmc.c | 53 +++++++++++------------------------------- 1 file changed, 14 insertions(+), 39 deletions(-) commit 33a31ceaf064cd62bf08e437b5849684da2ffe71 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Feb 11 13:59:55 2016 +0100 mmc: sh_mmci: Get rid of wrapper function for regulators As there are two callers of sh_mmcif_set_power() and because its only additional action is to check for a valid regulator, let's just remove it. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mmcif.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) commit 4caf653a55210dfc1c024d88e5148148f64802ad Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Feb 11 13:59:54 2016 +0100 mmc: sh_mmcif: Restructure ->set_ios() Both from a runtime PM and clock management point of view, the ->set_ios() code is unnecessary complex. A suboptimal path is also executed when the mmc core requests a clock rate of zero. As that happens during the card initialization phase, trying to save power by decreasing the runtime PM usage count and gating the clock via clk_disable_unprepare() is just superfluous. Moreover, from a runtime PM point of view the core will anyway keep the device active during the entire card initialization phase. Restructure the code to rely on the ios->power_mode to understand when the runtime PM usage count needs to be increased. Let's also deal with clock rate changes by simply applying the rate. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mmcif.c | 45 ++++++++++++++++----------------------------- 1 file changed, 16 insertions(+), 29 deletions(-) commit 88ac2a2c30468bb9f750170d92f7dd1ab91ddcbb Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Feb 11 13:59:53 2016 +0100 mmc: sh_mmcif: Make sure the device stays active when needed in ->probe() While accessing the device, make sure it stays active by increasing the runtime PM usage count for it. Let's also defer to enable runtime PM until we really need access to the device. This also enables the error path in ->probe() to become simpler. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/mmc/host/sh_mmcif.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 582a1db98892ef4c1f34c7338b272331994d44ab Merge: 158bc06 16f46bf Author: David S. Miller <davem@davemloft.net> Date: Mon May 2 00:16:45 2016 -0400 Merge branch 'qed-selftests' Sudarsana Reddy Kalluru says: ==================== qed/qede: ethtool selftests support. This series adds the driver support for following selftests: 1. Register test 2. Memory test 3. Clock test 4. Interrupt test 5. Internal loopback test Patch (1) adds the qed driver infrastructure for selftests. Patches (2) and (3) add qede driver support for ethtool selftests. Please consider applying this series to "net-next". ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 16f46bf054f8bb12c002c0ba64fc9ff17a61bf8f Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Thu Apr 28 20:20:54 2016 -0400 qede: add implementation for internal loopback test. This patch adds the qede implementation for internal loopback test. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede.h | 4 + drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 234 ++++++++++++++++++++++++ drivers/net/ethernet/qlogic/qede/qede_main.c | 8 +- 3 files changed, 242 insertions(+), 4 deletions(-) commit 3044a02eeb61d6fde77ea5140651bfc54afe524c Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Thu Apr 28 20:20:53 2016 -0400 qede: add support for selftests. This patch adds the qede ethtool support for the following tests: - interrupt test - memory test - register test - clock test Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 56 ++++++++++++++++++++++++- 1 file changed, 55 insertions(+), 1 deletion(-) commit 03dc76ca1ee5d02401d5a22ed7ddf15b5e9dfe76 Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Thu Apr 28 20:20:52 2016 -0400 qed: add infrastructure for device self tests. This patch adds the functionality and APIs needed for selftests. It adds the ability to configure the link-mode which is required for the implementation of loopback tests. It adds the APIs for clock test, register test, interrupt test and memory test. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/Makefile | 3 +- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 13 ++++ drivers/net/ethernet/qlogic/qed/qed_main.c | 28 +++++++++ drivers/net/ethernet/qlogic/qed/qed_mcp.c | 42 +++++++++++++ drivers/net/ethernet/qlogic/qed/qed_mcp.h | 22 +++++++ drivers/net/ethernet/qlogic/qed/qed_selftest.c | 76 +++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_selftest.h | 40 ++++++++++++ drivers/net/ethernet/qlogic/qed/qed_sp.h | 10 +++ drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 21 +++++++ include/linux/qed/qed_if.h | 47 ++++++++++++++ 10 files changed, 301 insertions(+), 1 deletion(-) commit 158bc065f29c9be0919d18aefab320161936b3a8 Author: Andrew Lunn <andrew@lunn.ch> Date: Thu Apr 28 21:24:06 2016 -0400 net: dsa: mv88e6xxx: replace ds with ps where possible The dsa_switch structure ds is actually needed in very few places, mostly during setup of the switch. The private structure ps is however needed nearly everywhere. Pass ps, not ds internally. [vd: rebased Andrew's patch.] Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 14 +- drivers/net/dsa/mv88e6131.c | 22 +- drivers/net/dsa/mv88e6171.c | 14 +- drivers/net/dsa/mv88e6352.c | 24 +- drivers/net/dsa/mv88e6xxx.c | 917 ++++++++++++++++++++++---------------------- drivers/net/dsa/mv88e6xxx.h | 14 +- 6 files changed, 511 insertions(+), 494 deletions(-) commit 8cd14ccbfdba76d0eae13414a85865294fb98df8 Merge: 0970f5b 1c7b4a2 Author: David S. Miller <davem@davemloft.net> Date: Sun May 1 23:38:49 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-05-01 This series contains updates to i40e and i40evf. The theme of this series is code reduction, with several code cleanups in this series. Starting with Neerav's removal of the code that implemented the HMC AQ APIs and calls, since they are now obsolete and not supported by firmware. Anjali changes the default of VFs to make sure they are not trusted or privileged until its explicitly set for trust through the new NDO op interface. Also limited the number of MAC and VLAN addresses a VF can add if it is untrusted/privileged. Carolyn syncs the VF code for the changes made to the PF for the RSS hash tuple settings, which ends up cleaning up much of the existing code. Jesse cleans up compiler warnings which were found with gcc's W=2 option. Then removed duplicate code, especially since only one copy was actually being used. Jacob addresses an issue which was found when testing GCC 6's which happens to produce new warnings when you left shift a signed value beyond the storage sizeof the type. The converts i40e & i40evf to use the BIT() macro more consistently. Alex actually bucks the trend of code removal by adding support for both drivers to use GSO_PARTIAL so that segmentation of frames with checksums enabled in outer headers is supported. Fortunately it does not take much to add this support! ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8ac0fba2da41620f4931a1007c71b0d4723eb02a Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Sun May 1 17:50:29 2016 -0400 isa: Decouple X86_32 dependency from the ISA Kconfig option The introduction of the ISA_BUS option blocks the compilation of ISA drivers on non-x86 platforms. The ISA_BUS configuration option should not be necessary if the X86_32 dependency can be decoupled from the ISA configuration option. This patch both removes the ISA_BUS configuration option entirely and removes the X86_32 dependency from the ISA configuration option. Acked-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> arch/x86/Kconfig | 10 ++-------- drivers/base/Makefile | 2 +- include/linux/isa.h | 2 +- 3 files changed, 4 insertions(+), 10 deletions(-) commit 0970f5b3665933f5f0d069607c78fb10bd918b62 Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Date: Fri Apr 29 14:17:08 2016 -0300 sctp: signal sk_data_ready earlier on data chunks reception Dave Miller pointed out that fb586f25300f ("sctp: delay calls to sk_data_ready() as much as possible") may insert latency specially if the receiving application is running on another CPU and that it would be better if we signalled as early as possible. This patch thus basically inverts the logic on fb586f25300f and signals it as early as possible, similar to what we had before. Fixes: fb586f25300f ("sctp: delay calls to sk_data_ready() as much as possible") Reported-by: Dave Miller <davem@davemloft.net> Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/structs.h | 2 +- net/sctp/sm_sideeffect.c | 7 +++---- net/sctp/ulpqueue.c | 25 ++++++++++++++++--------- 3 files changed, 20 insertions(+), 14 deletions(-) commit 70e927b98bb632e0c987818835aacd6787ebe107 Author: Marek Vasut <marex@denx.de> Date: Mon May 2 02:47:31 2016 +0200 mdio_bus: Fix MDIO bus scanning in __mdiobus_register() Since commit b74766a0a0fe ("phylib: don't return NULL from get_phy_device()") in linux-next, phy_get_device() will return ERR_PTR(-ENODEV) instead of NULL if the PHY device ID is all ones. This causes problem with stmmac driver and likely some other drivers which call mdiobus_register(). I triggered this bug on SoCFPGA MCVEVK board with linux-next 20160427 and 20160428. In case of the stmmac, if there is no PHY node specified in the DT for the stmmac block, the stmmac driver ( drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c function stmmac_mdio_register() ) will call mdiobus_register() , which will register the MDIO bus and probe for the PHY. The mdiobus_register() resp. __mdiobus_register() iterates over all of the addresses on the MDIO bus and calls mdiobus_scan() for each of them, which invokes get_phy_device(). Before the aforementioned patch, the mdiobus_scan() would return NULL if no PHY was found on a given address and mdiobus_register() would continue and try the next PHY address. Now, mdiobus_scan() returns ERR_PTR(-ENODEV), which is caught by the 'if (IS_ERR(phydev))' condition and the loop exits immediately if the PHY address does not contain PHY. Repair this by explicitly checking for the ERR_PTR(-ENODEV) and if this error comes around, continue with the next PHY address. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Arnd Bergmann <arnd@arndb.de> Cc: David S. Miller <davem@davemloft.net> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/mdio_bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1c7b4a23d12f63a2864c2a67ad96e74d0dbbf39c Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 17:19:25 2016 -0400 i40e/i40evf: Add support for GSO partial with UDP_TUNNEL_CSUM and GRE_CSUM This patch makes it so that i40e and i40evf can use GSO_PARTIAL to support segmentation for frames with checksums enabled in outer headers. As a result we can now send data over these types of tunnels at over 20Gb/s versus the 12Gb/s that was previously possible on my system. The advantage with the i40e parts is that this offload is mostly transparent as the hardware still deals with the inner and/or outer IPv4 headers so the IP ID is still incrementing for both when this offload is performed. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 10 ++++++++-- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 7 ++++++- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 7 ++++++- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 10 ++++++++-- 4 files changed, 28 insertions(+), 6 deletions(-) commit ae63bff0d7f333677e7ec532e9c315c74a510403 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:27 2016 -0700 i40evf: make use of BIT() macro to avoid signed left shift Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> .../net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 44 +++++++++++----------- 1 file changed, 22 insertions(+), 22 deletions(-) commit 2101bac2d4c26208fa0d1d9ffd8b83ad0199d61a Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:26 2016 -0700 i40e: make use of BIT() macro to prevent left shift of signed values Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 53 +++++++++++------------ 1 file changed, 25 insertions(+), 28 deletions(-) commit dcb57456e73f204beff12e4532aaf573d1115114 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:25 2016 -0700 i40e/i40evf: fix I40E_MASK signed shift overflow warnings GCC 6 has a new warning which will display when you attempt to left shift a signed value beyond the storage size of the type. I40E_MASK generates a mask value for 32bit registers. Properly typecast the mask value and place the values in parenthesis to prevent macro expansion issues. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_type.h | 2 +- drivers/net/ethernet/intel/i40evf/i40e_type.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 5a6fc256e7b64b3073688cc72fae357612cf31c6 Author: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com> Date: Wed Apr 13 03:08:32 2016 -0700 i40e/i40evf : Bump driver version from 1.5.5 to 1.5.10 Signed-off-by: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit a3aa5036cf3798c18fe22041fbfbac01642657e0 Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Wed Apr 13 03:08:31 2016 -0700 i40e: Update device ids for X722 Add a device ID for X722. Change-Id: I574f2345ab341de98a6a1c212d0603af853e48b0 Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + 1 file changed, 1 insertion(+) commit de38fef610f4e72fdf506bb84ddb05b46f4bf653 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Wed Apr 13 03:08:30 2016 -0700 i40e: Drop extra copy of function i40e_release_rx_desc was in two files, but was only used and needed in txrx.c. Get rid of the extra copy. Change-Id: I86e18239aa03531fc198b6c052847475084a9200 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 18 ------------------ 1 file changed, 18 deletions(-) commit a1b5a24fccc83430bb1fa6e0f9925fb8328abd34 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Wed Apr 13 03:08:29 2016 -0700 i40e: Use consistent type for vf_id The driver was all over the place using signed or unsigned types for vf_id, when it should always be signed. This fixes warnings of type unsafe comparisons from gcc with W=2. Change-Id: I2cb681f83d0f68ca124d2e4131e4ac0d9f8a6b22 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 2 +- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 13 +++++++------ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.h | 4 ++-- 3 files changed, 10 insertions(+), 9 deletions(-) commit cdc3d93257e162dd12906a6e0207436c2d5c6873 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Wed Apr 13 03:08:28 2016 -0700 i40e: PTP - avoid aggregate return warnings Aggregate return warnings are when struct types are returned and must be copied to the lvalue with a struct copy by the compiler. This fixes warnings of type aggregate-return from gcc with W=2. Change-Id: I896b1bf514544bf0faeb458869d79914b9f1b168 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ptp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 3ed439c56e0d82fd08275fff2c21278f92ed8ec5 Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Wed Apr 13 03:08:27 2016 -0700 i40e: Fix uninitialized variable We have an uninitialized variable warning for valid_len for one case in validate_vf_mesg. To fix this, just initialize it to 0 at the top of the function and remove all of the now redundant assignments to 0 in the individual cases. Change-Id: Iacbd97f4c521ed8d662eef803a598d8707708cfd Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit b29699b39924db73993734a605665cf4bebef9ea Author: Carolyn Wyborny <carolyn.wyborny@intel.com> Date: Wed Apr 13 03:08:26 2016 -0700 i40evf: RSS Hash Option parameters This patch syncs the VF code for the changes made to the PF for the RSS hash tuple settings. Since the VF still cannot change the RSS hash settings, change the code to make this clear to the user. Previously, the default settings were returned in this function. However, the default can be changed by the PF so this does not make sense anymore. Change-Id: I085eaf005fc7978b440d2a1bf2b2dd7cadaff39b Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 201 +-------------------- 1 file changed, 2 insertions(+), 199 deletions(-) commit 2b79c58d80921acb7f784c340fd7532c4a8b8d95 Author: Neerav Parikh <neerav.parikh@intel.com> Date: Sun May 1 14:29:53 2016 -0700 i40e: Remove HMC AQ API implementation Remove the code that implements the HMC AQ APIs and call these APIs. This is done because these are obsolete APIs and are not supported by firmware. Change-ID: I5d771d8f37c3e16e7b0a972ff9b27e75aa2d05d4 Signed-off-by: Neerav Parikh <neerav.parikh@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_adminq.c | 4 --- drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 25 ------------------ drivers/net/ethernet/intel/i40e/i40e_common.c | 30 ---------------------- drivers/net/ethernet/intel/i40e/i40e_prototype.h | 4 --- .../net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 25 ------------------ 5 files changed, 88 deletions(-) commit a856b5cb83fea40f28634a0220d7587d42e529d2 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Wed Apr 13 03:08:23 2016 -0700 i40e: Prevent falling to promiscuous if the VF is not trusted With this change a non trusted VF can never fall to promiscuous mode when there is no room for a MAC/VLAN filter. Change-Id: I8a155aa25c0bcdc6093414920c9ade4ee0bd20e8 Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 5f527ba962e277963b08f4c7f12fbeeac3f34e3c Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Wed Apr 13 03:08:22 2016 -0700 i40e: Limit the number of MAC and VLAN addresses that can be added for VFs If the VF is privileged/trusted it can do as it may please including but not limited to hogging resources and playing unfair. But if the VF is not privileged/trusted it still can add some number (8) of MAC and VLAN addresses. Other restrictions with respect to Port VLAN and normal VLAN still apply to not privileged/trusted VF. Change-Id: I3a9529201b184c8873e1ad2e300aff468c9e6296 Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 25 ++++++++++++++++++++-- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.h | 3 +++ 2 files changed, 26 insertions(+), 2 deletions(-) commit 24368aad47dc65b45040d6a31bfd6df1d6f3ec97 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:52:04 2016 -0700 nfsd: use RWF_SYNC Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/nfsd/vfs.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) commit e864f39569f4092c2b2bc72c773b6e486c7e3bd9 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:52:03 2016 -0700 fs: add RWF_DSYNC aand RWF_SYNC This is the per-I/O equivalent of O_DSYNC and O_SYNC, and very useful for all kinds of file servers and storage targets. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/read_write.c | 6 +++++- include/uapi/linux/fs.h | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) commit 6aa657c8526b8bbab6287f02dd91ac6d0c392d19 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:52:02 2016 -0700 ceph: use generic_write_sync Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ceph/file.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit e259221763a40403d5bb232209998e8c45804ab8 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:52:01 2016 -0700 fs: simplify the generic_write_sync prototype The kiocb already has the new position, so use that. The only interesting case is AIO, where we currently don't bother updating ki_pos. We're about to free the kiocb after we're done, so we might as well update it to make everyone's life simpler. While we're at it also return the bytes written argument passed in if we were successful so that the boilerplate error switch code in the callers can go away. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/block_dev.c | 8 ++------ fs/btrfs/file.c | 7 ++----- fs/cifs/file.c | 7 ++----- fs/direct-io.c | 17 +++++++++-------- fs/ext4/file.c | 9 ++------- fs/f2fs/file.c | 9 ++------- fs/nfs/direct.c | 4 +++- fs/ntfs/file.c | 7 ++----- fs/udf/file.c | 4 +--- fs/xfs/xfs_file.c | 6 +----- include/linux/fs.h | 24 ++++++++++++++++++------ mm/filemap.c | 9 ++------- 12 files changed, 46 insertions(+), 65 deletions(-) commit dde0c2e79848298cc25621ad080d47f94dbd7cce Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:52:00 2016 -0700 fs: add IOCB_SYNC and IOCB_DSYNC This will allow us to do per-I/O sync file writes, as required by a lot of fileservers or storage targets. XXX: Will need a few additional audits for O_DSYNC Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/block_dev.c | 2 +- fs/btrfs/file.c | 2 +- fs/cifs/file.c | 2 +- fs/direct-io.c | 2 +- fs/ext4/file.c | 2 +- fs/f2fs/file.c | 2 +- fs/gfs2/file.c | 5 ++++- fs/nfs/direct.c | 2 +- fs/ntfs/file.c | 2 +- fs/udf/file.c | 2 +- fs/xfs/xfs_file.c | 2 +- include/linux/fs.h | 14 ++++++++++---- mm/filemap.c | 2 +- 13 files changed, 25 insertions(+), 16 deletions(-) commit 716b9bc0cb50b1c2c15ef6a255c88508350e3462 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:51:59 2016 -0700 direct-io: remove the offset argument to dio_complete It has to be identical to ki_pos of the iocb, so use that instead. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/direct-io.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit c8b8e32d700fe943a935e435ae251364d016c497 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:51:58 2016 -0700 direct-io: eliminate the offset argument to ->direct_IO Including blkdev_direct_IO and dax_do_io. It has to be ki_pos to actually work, so eliminate the superflous argument. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/Locking | 2 +- Documentation/filesystems/vfs.txt | 2 +- drivers/staging/lustre/lustre/llite/rw26.c | 4 ++-- fs/9p/vfs_addr.c | 3 ++- fs/affs/file.c | 5 +++-- fs/block_dev.c | 6 +++--- fs/btrfs/inode.c | 6 +++--- fs/ceph/addr.c | 3 +-- fs/cifs/file.c | 2 +- fs/dax.c | 4 ++-- fs/direct-io.c | 7 ++++--- fs/exofs/inode.c | 3 +-- fs/ext2/inode.c | 8 ++++---- fs/ext4/ext4.h | 3 +-- fs/ext4/indirect.c | 12 ++++++------ fs/ext4/inode.c | 18 +++++++++--------- fs/f2fs/data.c | 6 +++--- fs/fat/inode.c | 6 +++--- fs/fuse/file.c | 3 ++- fs/gfs2/aops.c | 6 +++--- fs/hfs/inode.c | 7 +++---- fs/hfsplus/inode.c | 7 +++---- fs/jfs/inode.c | 7 +++---- fs/nfs/direct.c | 17 +++++++---------- fs/nfs/file.c | 2 +- fs/nilfs2/inode.c | 4 ++-- fs/ocfs2/aops.c | 9 ++++----- fs/reiserfs/inode.c | 7 +++---- fs/udf/file.c | 3 +-- fs/udf/inode.c | 7 +++---- fs/xfs/xfs_aops.c | 7 +++---- fs/xfs/xfs_file.c | 2 +- include/linux/dax.h | 2 +- include/linux/fs.h | 9 ++++----- include/linux/nfs_fs.h | 5 ++--- mm/filemap.c | 5 ++--- mm/page_io.c | 2 +- 37 files changed, 99 insertions(+), 112 deletions(-) commit 13712713caba0c1b8c2c0070a4c1f4487def8dee Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:51:57 2016 -0700 xfs: eliminate the pos variable in xfs_file_dio_aio_write Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/xfs/xfs_file.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit 1af5bb491fbb41c8dab9d728a92758dd6a28afd4 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:51:56 2016 -0700 filemap: remove the pos argument to generic_file_direct_write Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/btrfs/file.c | 9 ++++----- fs/fuse/file.c | 2 +- include/linux/fs.h | 2 +- mm/filemap.c | 5 +++-- 4 files changed, 9 insertions(+), 9 deletions(-) commit c64fb5c7448c1a0cfa163f126df3c112b6ca3e97 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 08:51:55 2016 -0700 filemap: remove pos variables in generic_file_read_iter Just use ki_pos directly to make everyones life easier. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> mm/filemap.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit def22c47d749c5ff8011831a8232b951f223963e Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Thu Apr 28 20:16:08 2016 -0400 tipc: set 'active' state correctly for first established link When we are displaying statistics for the first link established between two peers, it will always be presented as STANDBY although it in reality is ACTIVE. This happens because we forget to set the 'active' flag in the link instance at the moment it is established. Although this is a bug, it only has impact on the presentation view of the link, not on its actual functionality. Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/node.c | 1 + 1 file changed, 1 insertion(+) commit a77f4f70fd34ac7b67581fe5b89ddc1c9ac20d39 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Thu Apr 28 16:24:12 2016 -0700 of: of_mdio: Check if MDIO bus controller is available Add a check whether the 'struct device_node' pointer passed to of_mdiobus_register() is an available (aka enabled) node in the Device Tree. Rationale for doing this are cases where an Ethernet MAC provides a MDIO bus controller and node, and an additional Ethernet MAC might be connecting its PHY/switches to that first MDIO bus controller, while still embedding one internally which is therefore marked as "disabled". Instead of sprinkling checks like these in callers of of_mdiobus_register(), do this in a central location. Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/of/of_mdio.c | 4 ++++ 1 file changed, 4 insertions(+) commit dfeb87df484d609aadef810dbb819830f5f9052a Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Mar 30 09:51:04 2016 +0900 nfc: Drop owner assignment from i2c_driver i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/nxp-nci/i2c.c | 1 - drivers/nfc/pn544/i2c.c | 1 - drivers/nfc/st-nci/i2c.c | 1 - drivers/nfc/st21nfca/i2c.c | 1 - 4 files changed, 4 deletions(-) commit 0a19f129d71f18e73249d54de96c835186b8607e Author: Ben Sen <0.x29a.0@gmail.com> Date: Sun May 1 23:23:33 2016 +0200 w1: add ability to set (SRAM) and store (EEPROM) configuration for temp sensors like DS18B20 Since many temperature sensors come "preconfigured" with a lower precision, people are stuck at that precision when running on a kernel based device (unlike the Dallas 1Wire library for e.g. Arduino, which supports writing the configuration/scratchpad). This patch adds write support for the scratchpad/precision registers via w1_slave sysfs. Signed-off-by: Ben Sen <0.x29a.0@gmail.com> Acked-by: Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/w1/slaves/w1_therm | 10 +- drivers/w1/slaves/w1_therm.c | 218 +++++++++++++++++++++++++++++++++++++-- drivers/w1/w1.h | 2 + 3 files changed, 222 insertions(+), 8 deletions(-) commit 99aded71b52cfdfa22721c42e42efdd13a02f0a6 Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:39 2016 +0800 Staging: drivers: rtl8188eu: use sizeof(*ptr) instead of sizeof(struct) Fix coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 9cb2dbf316d9a020fa4a042958930b85f24f2a6f Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:37 2016 +0800 Staging: drivers: rtl8188eu: fixed extraneous spaces Fix coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d5fdbca6745e476f8029fad4ee5a6612b4951dbb Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:36 2016 +0800 Staging: drivers: rtl8188eu: fixed extraneous parentheses Fix coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 30 ++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit a305990d387f908d9b61368304a94efb5c5af8d9 Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:35 2016 +0800 Staging: drivers: rtl8188eu: fixed extraneous indentation Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a634696eb4421d09f69c46659fb3fb0aec4e91ad Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:34 2016 +0800 Staging: drivers: rtl8188eu: fixed unnecessary else branch Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit a48d498b153bf7dcf2572ad4e82e2049082bb928 Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:33 2016 +0800 Staging: drivers: rtl8188eu: fixed brace style Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 99f8adc450198d9794c6ce6450888832b1105554 Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:32 2016 +0800 Staging: drivers: rtl8188eu: fixed newlines style Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 637642e2a34f083336753b0a367f1f42efec5e6e Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:31 2016 +0800 Staging: drivers: rtl8188eu: fixed block comments style Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit f43534b97ac76cdde24908182f4cf2e2dd906264 Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:30 2016 +0800 Staging: drivers: rtl8188eu: fixed typo Fixed typo Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ffc9b27571c0add3cdaef2a7ea8e19209fe1259a Author: Jacky Boen <aqiank@gmail.com> Date: Sun May 1 23:50:29 2016 +0800 Staging: drivers: rtl8188eu: move constants to the right in comparisons Fixed coding style issue Signed-off-by: Jacky Boen <aqiank@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 78481742be52577fd31670034b13b9b85e120d96 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 22:33:05 2016 +0100 staging: i4l: act2000: remove extra space It is not kernel coding style to give an extra space after a cast. We get warned about it by checkpatch. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/act2000/act2000_isa.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit fdf94a00e3f8d9f81a062907ec1cd6083d659cf2 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 22:33:04 2016 +0100 staging: i4l: act2000: remove blank line after brace checkpatch complains about an extra blank line after an opening brace. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/act2000/act2000_isa.c | 1 - 1 file changed, 1 deletion(-) commit 360a63c850e61f4415036ade414479c4ad204764 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 22:33:03 2016 +0100 staging: i4l: act2000: do not assign in if It is not the kernel coding style to assign values to some variable in if statement. Split them up into different statements. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/act2000/act2000_isa.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 2c78f701a4bb61ec3495cccf445ef9282e115927 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 22:33:02 2016 +0100 staging: i4l: act2000: fix use of return checkpatch warns that return is not a function and as such the brace after it is not required. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/act2000/act2000_isa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71c08eac2e88b01ecbfba1b1a485a748a4632727 Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Mon Apr 11 16:36:02 2016 +0200 nfc: pn533: Add device tree documentation for i2c phy Add pn533-i2c phy devicetree documentation Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> .../devicetree/bindings/net/nfc/pn533-i2c.txt | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 1f62ff34a90471d1b735bac2c79e894afc7c59bc Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Mar 24 22:19:40 2016 +0100 driver-core: use 'dev' argument in dev_dbg_ratelimited stub dev_dbg_ratelimited() is a macro that ignores its first argument when DEBUG is not set, which can lead to unused variable warnings: ethernet/mellanox/mlxsw/pci.c: In function 'mlxsw_pci_cqe_sdq_handle': ethernet/mellanox/mlxsw/pci.c:646:18: warning: unused variable 'pdev' [-Wunused-variable] ethernet/mellanox/mlxsw/pci.c: In function 'mlxsw_pci_cqe_rdq_handle': ethernet/mellanox/mlxsw/pci.c:671:18: warning: unused variable 'pdev' [-Wunused-variable] The macro already ensures that all its other arguments are silently ignored by the compiler without triggering a warning, through the use of the no_printk() macro, but the dev argument is not passed into that. This changes the definition to use the same trick as no_printk() with an if(0) that leads the compiler to not evaluate the side-effects but still see that 'dev' might not be unused. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Suggested-by: Andrew Lunn <andrew@lunn.ch> Fixes: 6f586e663e3b ("driver-core: Shut up dev_dbg_reatelimited() without DEBUG") Reviewed-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/device.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit ded9db380d34344ee5263002570b9b8b705f7830 Author: Yi Zhang <yizhang_hust@163.com> Date: Tue Mar 8 23:15:22 2016 +0800 base: dd: don't remove driver_data in -EPROBE_DEFER case the driver_data may be used for sanity check, it fails the probe() if driver_data is NULL after it is re-triggered. for example, soc_probe() in sound/soc/soc-core.c Signed-off-by: Yi Zhang <yizhang_hust@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/base/dd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ae53e3740036b5350c4a10dc6fd00fbe3f5134ff Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 15 17:50:32 2016 +0300 memory: of_memory: Silence uninitialized variable warning Presumably we never use the default: case statement which prints a warning message. But my static checker complains that if we do, we will hit an uninitialized variable warning. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/memory/of_memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3385af8c9d63be16295ae625d1ed81052167efb3 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 15 11:13:32 2016 +0200 drivers: amba: properly handle devices with power domains To read pid/cid registers, the probed device need to be properly turned on. When it is inside a power domain, the bus code should ensure that the given power domain is enabled before trying to access device's registers. However in some cases power domain (or clocks) might not be yet available. Returning -EPROBE_DEFER is not a solution in such case, because callers don't handle this special error code. Instead such devices are added to the special list and their registration is retried from periodic worker until all resources are available. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/amba/bus.c | 100 +++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 90 insertions(+), 10 deletions(-) commit 8d026465ecf68823c633f7b60d39a8a17dd3bc27 Author: Daniel Wagner <daniel.wagner@bmw-carit.de> Date: Fri Apr 15 10:22:27 2016 +0200 ti-st: Fix complete_all() wrong usage complete_all() should only be called once, doing it twice is a clear bug. 8565adbc8214 ("drivers/misc/ti-st: fix read fw version cmd") added the additional complete_all() call. Since we call complete_all() when leaving the function we can drop the complete_all() call inside true branch of the if statement. Signed-off-by: Daniel Wagner <daniel.wagner@bmw-carit.de> Cc: Pavan Savoy <pavan_savoy@ti.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/ti-st/st_kim.c | 1 - 1 file changed, 1 deletion(-) commit 66b58edf592fd7a6fc0f106e0809e52b52d4722f Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:45:11 2016 +0300 ARM: qcom: silence an uninitialized variable warning It's harmless but, if "enable" isn't set, then we pass uninitialized values to qcom_coincell_chgr_config(). The values aren't used, but let's silence the warning anyway. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Tim Bird <tim.bird@sonymobile.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/qcom-coincell.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 309124e2648d668a0c23539c5078815660a4a850 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Mon Apr 11 10:40:55 2016 +0200 char: Drop bogus dependency of DEVPORT on !M68K According to full-history-linux commit d3794f4fa7c3edc3 ("[PATCH] M68k update (part 25)"), port operations are allowed on m68k if CONFIG_ISA is defined. However, commit 153dcc54df826d2f ("[PATCH] mem driver: fix conditional on isa i/o support") accidentally changed an "||" into an "&&", disabling it completely on m68k. This logic was retained when introducing the DEVPORT symbol in commit 4f911d64e04a44c4 ("Make /dev/port conditional on config symbol"). Drop the bogus dependency on !M68K to fix this. Fixes: 153dcc54df826d2f ("[PATCH] mem driver: fix conditional on isa i/o support") Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Tested-by: Al Stone <ahs3@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/Kconfig | 1 - 1 file changed, 1 deletion(-) commit ef0fd640e3312b8164ec43e1eff24769a7c08b7f Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:52 2016 -0600 coresight: removing gratuitous boot time log messages Removing boot time log for drivers that don't report useful information other than they came up properly. The same information can be found in sysFS once the system has booted and as such doesn't provide any value in the boot log. Reported-by: Mark Brown <broonie@linaro.org> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etb10.c | 1 - drivers/hwtracing/coresight/coresight-funnel.c | 1 - drivers/hwtracing/coresight/coresight-replicator.c | 1 - drivers/hwtracing/coresight/coresight-tmc.c | 1 - drivers/hwtracing/coresight/coresight-tpiu.c | 1 - 5 files changed, 5 deletions(-) commit ad352acbb9d606a5facff31fd96b05d0346726b1 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:51 2016 -0600 coresight: etb10: splitting sysFS "status" entry The sysFS "status" entry conveys a wealth of information about the status of the HW but goes agains the sysFS rule of one topic per file. This patch rectify the situation by adding read-only entries for each of the field formaly displayed by "status". The ABI documentation is kept up to date. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../ABI/testing/sysfs-bus-coresight-devices-etb10 | 69 ++++++++++++++++-- drivers/hwtracing/coresight/coresight-etb10.c | 81 ++++++++++------------ 2 files changed, 100 insertions(+), 50 deletions(-) commit 154f3520fe1cdef9009909dc62828eb2d7635631 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:50 2016 -0600 coresight: moving coresight_simple_func() to header file Macro "coresight_simple_func()" can be used by several drivers. As such making the structure type generic and moving to a globally available header file. That way individual drivers can use the functionality by simply specifying the structure they need to work with. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../hwtracing/coresight/coresight-etm3x-sysfs.c | 33 +++++------- .../hwtracing/coresight/coresight-etm4x-sysfs.c | 63 ++++++++++------------ drivers/hwtracing/coresight/coresight-priv.h | 10 ++++ 3 files changed, 51 insertions(+), 55 deletions(-) commit 37fbbdbde9ad3722a7a18beab936825a6ff322bf Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:49 2016 -0600 coresight: etm4x: implementing the perf PMU API Adding a set of API allowing the Perf core to treat ETMv4 tracers like other PMUs. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/Makefile | 5 +- drivers/hwtracing/coresight/coresight-etm4x.c | 85 +++++++++++++++++++++++++-- 2 files changed, 82 insertions(+), 8 deletions(-) commit 4f6fce54528e0382281cf199635d098e4b108357 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:48 2016 -0600 coresight: etm4x: implementing user/kernel mode tracing Adding new mode to limit tracing to kernel or user space. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../hwtracing/coresight/coresight-etm4x-sysfs.c | 3 ++ drivers/hwtracing/coresight/coresight-etm4x.c | 35 ++++++++++++++++++++++ drivers/hwtracing/coresight/coresight-etm4x.h | 5 +++- 3 files changed, 42 insertions(+), 1 deletion(-) commit c38a9ec2b2c12c38abca0b7954ed793f26969835 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:47 2016 -0600 coresight: etm4x: moving etm_drvdata::enable to atomic field Similarly to ETMv3, moving etmv4_drvdata::enable to an atomic type that gives the 'mode' of a tracer and prevents multiple, simultanious access by different subsystems. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etm4x.c | 69 +++++++++++++++++++++++---- drivers/hwtracing/coresight/coresight-etm4x.h | 5 +- 2 files changed, 63 insertions(+), 11 deletions(-) commit 66bbbb77540e846b9aac4c9467aca936128951bf Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:46 2016 -0600 coresight: etm4x: unlocking tracers in default arch init As with the ETMv3.x driver, calling 'smp_call_function_single()' twice in a row is highly ineffective. As such moving function 'etm4_os_unlock()' before the default initialisation takes place, which results in the same outcome. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etm4x.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit fc208abef39279903887bea955139f64bf0bbb12 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:45 2016 -0600 coresight: etm4x: splitting etmv4 default configuration Splitting and updating the default initialisation for each etmv4 configuration so that it can be called at the beginning of each session rather than initialisation time only. Since the trace ID isn't expected to change with every session, moving it with the default tracer initialisation. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/coresight-etm4x.c | 128 ++++++++++++-------------- drivers/hwtracing/coresight/coresight-etm4x.h | 12 +++ 2 files changed, 73 insertions(+), 67 deletions(-) commit 54ff892b76c68ea3fa0ba53a0cdc4508b35aee6f Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:44 2016 -0600 coresight: etm4x: splitting struct etmv4_drvdata Similar to what was done on etm3x, splitting driver structure etmv4_drvdata in two. One half is concerned with the HW characteristics that are generally static in nature. The other half deals with user configuration and will change from one trace session to another. No gain/loss of functionality is incurred from this patch. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../hwtracing/coresight/coresight-etm4x-sysfs.c | 642 ++++++++++++--------- drivers/hwtracing/coresight/coresight-etm4x.c | 134 ++--- drivers/hwtracing/coresight/coresight-etm4x.h | 202 +++---- 3 files changed, 533 insertions(+), 445 deletions(-) commit 7c38aa4b03b3fc6ce17e5a00327f8c0be18daf8a Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:43 2016 -0600 coresight: etm4x: adding config and traceid registers Adding new sysFS management interface to query the configuration and the traceid registers. Both are required to convey information to the perf cmd line tools when using ETMv4 tracers as PMU. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/ABI/testing/sysfs-bus-coresight-devices-etm4x | 13 +++++++++++++ drivers/hwtracing/coresight/coresight-etm4x-sysfs.c | 4 ++++ 2 files changed, 17 insertions(+) commit a77de2637c9eb4794c6234b40cee2a243c548875 Author: Mathieu Poirier <mathieu.poirier@linaro.org> Date: Tue Apr 5 11:53:42 2016 -0600 coresight: etm4x: moving sysFS entries to a dedicated file As with the etm3x driver, sysFS entries are big enough to justify their own file. As such moving all sysFS related declarations to a dedicated location. No gain/loss of functionality is incurred from this patch. Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hwtracing/coresight/Makefile | 3 +- .../hwtracing/coresight/coresight-etm4x-sysfs.c | 2048 ++++++++++++++++++++ drivers/hwtracing/coresight/coresight-etm4x.c | 2029 ------------------- drivers/hwtracing/coresight/coresight-etm4x.h | 2 + 4 files changed, 2052 insertions(+), 2030 deletions(-) commit 38cbfe4fe807121d23826115db224c1b79f0aa36 Author: Andreas Ziegler <andreas.ziegler@fau.de> Date: Thu Mar 31 09:24:29 2016 +0200 checkkconfigsymbols.py: Fix typo in help message Fix a typo in the help message for the -d parameter by removing one 'm'. Signed-off-by: Andreas Ziegler <andreas.ziegler@fau.de> Acked-by: Valentin Rothberg <valentinrothberg@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> scripts/checkkconfigsymbols.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0320a278b9ef80cfa44f74b7f9bb36781695f3ee Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 1 14:04:23 2016 +0300 uio: add missing error codes My static checker complains that "ret" could be uninitialized at the end, which is true but it's more likely that it would be set to zero. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/uio/uio.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit 2fad622483707825222d2c38acb368681c75bbaa Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Apr 27 21:45:01 2016 +0200 char/rtc: replace blacklist with whitelist Every new architecture has to add itself to the growing list of those that do not support the legacy PC RTC driver. This replaces the long list of architectures that don't support it with a shorter list of those that do. The list is taken from those architectures that have a non-empty asm/mc146818rtc.h header file and were not explicitly blacklisted or select RTC_LIB. Alpha and Loongson64 can already choose between this driver and an rtc-class based one. mn10300 is actually the only architecture now that still requires this driver, and that should be fairly easy to change to use rtc-cmos if we want to kill off rtc.ko for good. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 692fb0a75e816d2676f222c9db33e91f46ea1e03 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Wed Apr 13 03:08:21 2016 -0700 i40e: Change the default for VFs to be not privileged Make sure a VF is not trusted/privileged until its explicitly set for trust through the new NDO op interface. Change-Id: I476385c290d2b4901d8fceb29de43546accdc499 Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit b9c11a2333db7215876eca4ff5a39ee4f94909f2 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:35:48 2016 +0300 w1: silence an uninitialized variable warning If kstrtoint() returns -ERANGE then "tmp" is uninitialized. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Evgeniy Polaykov <zbr@ioremap.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/w1/w1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dd69a18ae71070ffd8805fcdfed6404762eaffa2 Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 20 10:16:36 2016 +0100 eeprom: 93xx46: Fix SPI device leak The 93xx46 driver is using spi_dev_get() apparently just to take a copy of the SPI device used to instantiate it but never calls spi_dev_put() to free it. Since the device is guaranteed to exist between probe() and remove() there should be no need for the driver to take an extra reference to it so fix the leak by just using a straight assignment. Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/eeprom/eeprom_93xx46.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 96b2a45c66fdca543cd94da3aa2c2542b11b9188 Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 20 10:16:35 2016 +0100 eeprom: at25: Fix SPI device leak The at25 driver is using spi_dev_get() apparently just to take a copy of the SPI device used to instantiate it but never calls spi_dev_put() to free it. Since the device is guaranteed to exist between probe() and remove() there should be no need for the driver to take an extra reference to it so fix the leak by just using a straight assignment. Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/eeprom/at25.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f8f41d160747fda572eed785a5aa022f59f21ca Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:31:37 2016 +0100 w1: Spelling s/minmum/minimum/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/w1/w1_io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f704938c0ef1e3224e66b16d5b358f02cd351240 Author: Mariusz Bialonczyk <manio@skyboo.net> Date: Tue Mar 29 18:41:38 2016 +0200 w1: enable active pullup for DS2482 by default This commit enables the active pullup (APU bit) by default for the DS2482 1-Wire master. >From the DS2482 datasheet: "The APU bit controls whether an active pullup (controlled slew-rate transistor) or a passive pullup (Rwpu resistor) will be used to drive a 1-Wire line from low to high. When APU = 0, active pullup is disabled (resistor mode). Active Pullup should always be selected unless there is only a single slave on the 1-Wire line." According to the module author, Ben Gardner: "It doesn't look like active pullup would cause any hurt if there is only a single slave." And my tests with multiple and single slaves on 1-Wire bus confirms that. This active pullup can be manually disabled using the introduced module parameter: active_pullup = 0 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/w1/masters/ds2482.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit a8ab316ab12501908cc355fee6aff7065609f4e2 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:16 2016 +0100 nvmem: 93xx46: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/eeprom/eeprom_93xx46.c | 90 ++++++++----------------------------- 1 file changed, 18 insertions(+), 72 deletions(-) commit 2e8d0733f306a8129a0bcbdd5f1df3dcfcbe4069 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:14 2016 +0100 nvmem: lpc18xx-eeprom: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/lpc18xx_eeprom.c | 94 ++++++++++++------------------------------ 1 file changed, 26 insertions(+), 68 deletions(-) commit 33e5e29cbbde92615fc80be5a0e4d41346478f19 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:13 2016 +0100 nvmem: imx-ocotp: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/imx-ocotp.c | 55 ++++++++++------------------------------------- 1 file changed, 11 insertions(+), 44 deletions(-) commit cc907553ff55dda59c67e09706d3b734d67d0242 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:11 2016 +0100 nvmem: rockchip-efuse: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/rockchip-efuse.c | 49 ++++++++---------------------------------- 1 file changed, 9 insertions(+), 40 deletions(-) commit 9c7b16eb35d283f00ba278b62b5115dacdf12dd7 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:10 2016 +0100 nvmem: sunxi-sid: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/Kconfig | 1 - drivers/nvmem/sunxi_sid.c | 54 ++++++++--------------------------------------- 2 files changed, 9 insertions(+), 46 deletions(-) commit 2c0235c6041857b45f4d2f368efb9866420b6ff2 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:09 2016 +0100 nvmem: vif610-ocotp: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Sanchayan Maity <maitysanchayan@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/vf610-ocotp.c | 44 ++++++++++---------------------------------- 1 file changed, 10 insertions(+), 34 deletions(-) commit 382c62f74f4a50c5e2a85980599dbc76d63c6120 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:08 2016 +0100 nvmem: qfprom: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Reported-by: Rajendra Nayak <rjendra@qti.qualcomm.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/Kconfig | 1 - drivers/nvmem/qfprom.c | 56 +++++++++++++++++++++++++++++++++----------------- 2 files changed, 37 insertions(+), 20 deletions(-) commit 01973a01f9ec34b706bf474dc4fb8c2bd9741d2b Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:07 2016 +0100 eeprom: at25: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/eeprom/Kconfig | 1 - drivers/misc/eeprom/at25.c | 89 ++++++++++----------------------------------- 2 files changed, 19 insertions(+), 71 deletions(-) commit cf0361a2d2b809c6f5b73313544711648fd7afdd Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:06 2016 +0100 eeprom: at24: remove nvmem regmap dependency This patch moves to nvmem support in the driver to use callback instead of regmap. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/eeprom/Kconfig | 1 - drivers/misc/eeprom/at24.c | 103 ++++++++++---------------------------------- 2 files changed, 22 insertions(+), 82 deletions(-) commit 795ddd18d38f9762fbfefceab9aa16caef0cf431 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Sun Apr 24 20:28:05 2016 +0100 nvmem: core: remove regmap dependency nvmem uses regmap_raw_read/write apis to read/write data from providers, regmap raw apis stopped working with recent kernels which removed raw accessors on mmio bus. This resulted in broken nvmem for providers which are based on regmap mmio bus. This issue can be fixed temporarly by moving to other regmap apis, but we might hit same issue in future. Moving to interfaces based on read/write callbacks from providers would be more robust. This patch removes regmap dependency from nvmem and introduces read/write callbacks from the providers. Without this patch nvmem providers like qfprom based on regmap mmio bus would not work. Reported-by: Rajendra Nayak <rjendra@qti.qualcomm.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/Kconfig | 1 - drivers/nvmem/core.c | 67 +++++++++++++++++++++++++----------------- include/linux/nvmem-provider.h | 10 +++++++ 3 files changed, 50 insertions(+), 28 deletions(-) commit 326071b3c985683f8a18417bed3ea2ab930a7ba1 Author: Aaron Sierra <asierra@xes-inc.com> Date: Sun Apr 24 15:11:38 2016 -0500 vme: add vme_init_bridge for common bridge init Consolidate vme_bridge structure setup that every bridge was required to do itself. This came about because .irq_mtx is only used within the VME core, but was required to be setup externally. This returns the structure passed in to support shorthand like this: bridge = vme_init_bridge(&priv->bridge); Signed-off-by: Aaron Sierra <asierra@xes-inc.com> Acked-by: Martyn Welch <martyn@welchs.me.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/vme/bridges/vme_ca91cx42.c | 9 +-------- drivers/vme/bridges/vme_tsi148.c | 9 +-------- drivers/vme/vme.c | 14 ++++++++++++++ drivers/vme/vme_bridge.h | 1 + 4 files changed, 17 insertions(+), 16 deletions(-) commit 2ce7aed6a4da8ffa35f0232573a6901c0369720d Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Thu Mar 31 11:07:03 2016 +0100 nvmem: Fix build error of missing devm_ioremap_resource on UM The devres.o gets linked if HAS_IOMEM is present so on ARCH=um allyesconfig (COMPILE_TEST) failed on many files with: drivers/built-in.o: In function `mtk_thermal_probe': mtk_thermal.c:(.text+0x394618): undefined reference to `devm_ioremap_resource' The users of devm_ioremap_resource() which are compile-testable should depend on HAS_IOMEM. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/nvmem/Kconfig | 2 ++ 1 file changed, 2 insertions(+) commit f56c3d4f54bb2e6d542547876e3d596ef7e5fa20 Author: Aaron Sierra <asierra@xes-inc.com> Date: Thu Apr 21 11:18:22 2016 -0500 vme: trivial spelling and capitalization fixes Fix a typo in the spurious interrupt warning and consistently capitalize VME, PCI, and DMA acronyms. Signed-off-by: Aaron Sierra <asierra@xes-inc.com> Acked-by: Martyn Welch <martyn@welchs.me.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/vme/vme.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit e7d992d8b6224aaf0ee69c8403681bcb70d425b6 Author: Parth Sane <laerdevstudios@gmail.com> Date: Mon Apr 25 21:13:18 2016 +0530 rtl8712: Fixed alignment to match open parenthesis Fixed alignment to match open parenthesis. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/hal_init.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 11ca2b7ab432eb90906168c327733575e68d388f Author: Zhao Qiang <qiang.zhao@nxp.com> Date: Wed Mar 9 09:48:11 2016 +0800 QE-UART: add "fsl,t1040-ucc-uart" to of_device_id New bindings use "fsl,t1040-ucc-uart" as the compatible for qe-uart. So add it. Signed-off-by: Zhao Qiang <qiang.zhao@nxp.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/ucc_uart.c | 3 +++ 1 file changed, 3 insertions(+) commit b67fcbdc5618d9a3a2b7bb22f7299556852e851f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 29 13:40:26 2016 +0200 serial: mctrl_gpio: Drop support for out1-gpios and out2-gpios The OUT1 and OUT2 pins present on some legacy UARTs are basically GPIOs. It doesn't make much sense to emulate GPIOs using other GPIOs, hence drop support for that. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Richard Genoud <richard.genoud@gmail.com> Reviewed-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_mctrl_gpio.c | 2 -- drivers/tty/serial/serial_mctrl_gpio.h | 2 -- 2 files changed, 4 deletions(-) commit 204e986d917cfa9364f05c5e7e42394a80788115 Author: Wang Hongcheng <annie.wang@amd.com> Date: Fri Mar 11 09:40:11 2016 +0800 serial: 8250dw: Add device HID for future AMD UART controller Add device HID AMDI0020 to match the AMD ACPI Vendor ID (AMDI) as registered in http://www.uefi.org/acpi_id_list, and the UART controller on future AMD paltform will use the HID instead of AMD0020. Signed-off-by: Wang Hongcheng <annie.wang@amd.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_dw.c | 1 + 1 file changed, 1 insertion(+) commit 0f40fbbcc34e093255a2b2d70b6b0fb48c3f39aa Author: Brian Bloniarz <brian.bloniarz@gmail.com> Date: Sun Mar 6 13:16:30 2016 -0800 Fix OpenSSH pty regression on close OpenSSH expects the (non-blocking) read() of pty master to return EAGAIN only if it has received all of the slave-side output after it has received SIGCHLD. This used to work on pre-3.12 kernels. This fix effectively forces non-blocking read() and poll() to block for parallel i/o to complete for all ttys. It also unwinds these changes: 1) f8747d4a466ab2cafe56112c51b3379f9fdb7a12 tty: Fix pty master read() after slave closes 2) 52bce7f8d4fc633c9a9d0646eef58ba6ae9a3b73 pty, n_tty: Simplify input processing on final close 3) 1a48632ffed61352a7810ce089dc5a8bcd505a60 pty: Fix input race when closing Inspired by analysis and patch from Marc Aurele La France <tsi@tuyoix.net> Reported-by: Volth <openssh@volth.com> Reported-by: Marc Aurele La France <tsi@tuyoix.net> BugLink: https://bugzilla.mindrot.org/show_bug.cgi?id=52 BugLink: https://bugzilla.mindrot.org/show_bug.cgi?id=2492 Signed-off-by: Brian Bloniarz <brian.bloniarz@gmail.com> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/serial/tty.txt | 3 -- drivers/tty/n_hdlc.c | 4 +-- drivers/tty/n_tty.c | 70 +++++++++++++++++++++----------------------- drivers/tty/pty.c | 4 +-- drivers/tty/tty_buffer.c | 34 ++++----------------- include/linux/tty.h | 2 +- 6 files changed, 43 insertions(+), 74 deletions(-) commit d11df61853f1d45035b7f5a6702c9b48d5f09a49 Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Fri Apr 29 10:45:07 2016 +0200 serial: mctrl_gpio: add IRQ locking uart_handle_cts_change should be called with port->lock held. And for this to be save you must also disable irqs. Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_mctrl_gpio.c | 5 +++++ 1 file changed, 5 insertions(+) commit 552beb4930ef3889d42a049eb9ba3533b4cbe0f6 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Sat Apr 30 19:21:37 2016 -0700 tools: hv: lsvmbus: add pci pass-through UUID lsvmbus keeps its own copy of all VMBus UUIDs, add PCIe pass-through device there to not report 'Unknown' for such devices. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> tools/hv/lsvmbus | 1 + 1 file changed, 1 insertion(+) commit d19a55d6ed5bf0ffe553df2d8bf91d054ddf2d76 Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Sat Apr 30 19:21:36 2016 -0700 Drivers: hv: balloon: reset host_specified_ha_region We set host_specified_ha_region = true on certain request but this is a global state which stays 'true' forever. We need to reset it when we receive a request where ha_region is not specified. I did not see any real issues, the bug was found by code inspection. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/hv_balloon.c | 1 + 1 file changed, 1 insertion(+) commit 77c0c9735bc0ba5898e637a3a20d6bcb50e3f67d Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Sat Apr 30 19:21:35 2016 -0700 Drivers: hv: balloon: don't crash when memory is added in non-sorted order When we iterate through all HA regions in handle_pg_range() we have an assumption that all these regions are sorted in the list and the 'start_pfn >= has->end_pfn' check is enough to find the proper region. Unfortunately it's not the case with WS2016 where host can hot-add regions in a different order. We end up modifying the wrong HA region and crashing later on pages online. Modify the check to make sure we found the region we were searching for while iterating. Fix the same check in pfn_covered() as well. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/hv_balloon.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cd95aad5579371ac332507fc946008217fc37e6c Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Sat Apr 30 19:21:34 2016 -0700 Drivers: hv: vmbus: handle various crash scenarios Kdump keeps biting. Turns out CHANNELMSG_UNLOAD_RESPONSE is always delivered to the CPU which was used for initial contact or to CPU0 depending on host version. vmbus_wait_for_unload() doesn't account for the fact that in case we're crashing on some other CPU we won't get the CHANNELMSG_UNLOAD_RESPONSE message and our wait on the current CPU will never end. Do the following: 1) Check for completion_done() in the loop. In case interrupt handler is still alive we'll get the confirmation we need. 2) Read message pages for all CPUs message page as we're unsure where CHANNELMSG_UNLOAD_RESPONSE is going to be delivered to. We can race with still-alive interrupt handler doing the same, add cmpxchg() to vmbus_signal_eom() to not lose CHANNELMSG_UNLOAD_RESPONSE message. 3) Cleanup message pages on all CPUs. This is required (at least for the current CPU as we're clearing CPU0 messages now but we may want to bring up additional CPUs on crash) as new messages won't be delivered till we consume what's pending. On boot we'll place message pages somewhere else and we won't be able to read stale messages. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/channel_mgmt.c | 58 +++++++++++++++++++++++++++++++++++------------ drivers/hv/hyperv_vmbus.h | 16 +++++++++++-- drivers/hv/vmbus_drv.c | 7 +++--- 3 files changed, 61 insertions(+), 20 deletions(-) commit 4dbfc2e68004c60edab7e8fd26784383dd3ee9bc Author: Vitaly Kuznetsov <vkuznets@redhat.com> Date: Sat Apr 30 19:21:33 2016 -0700 Drivers: hv: kvp: fix IP Failover Hyper-V VMs can be replicated to another hosts and there is a feature to set different IP for replicas, it is called 'Failover TCP/IP'. When such guest starts Hyper-V host sends it KVP_OP_SET_IP_INFO message as soon as we finish negotiation procedure. The problem is that it can happen (and it actually happens) before userspace daemon connects and we reply with HV_E_FAIL to the message. As there are no repetitions we fail to set the requested IP. Solve the issue by postponing our reply to the negotiation message till userspace daemon is connected. We can't wait too long as there is a host-side timeout (cca. 75 seconds) and if we fail to reply in this time frame the whole KVP service will become inactive. The solution is not ideal - if it takes userspace daemon more than 60 seconds to connect IP Failover will still fail but I don't see a solution with our current separation between kernel and userspace parts. Other two modules (VSS and FCOPY) don't require such delay, leave them untouched. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/hv_kvp.c | 31 +++++++++++++++++++++++++++++++ drivers/hv/hyperv_vmbus.h | 5 +++++ 2 files changed, 36 insertions(+) commit 05d1a717ec0430c916a749b94eb90ab74bbfa356 Author: Mimi Zohar <zohar@linux.vnet.ibm.com> Date: Mon Feb 29 19:52:05 2016 -0500 ima: add support for creating files using the mknodat syscall Commit 3034a14 "ima: pass 'opened' flag to identify newly created files" stopped identifying empty files as new files. However new empty files can be created using the mknodat syscall. On systems with IMA-appraisal enabled, these empty files are not labeled with security.ima extended attributes properly, preventing them from subsequently being opened in order to write the file data contents. This patch defines a new hook named ima_post_path_mknod() to mark these empty files, created using mknodat, as new in order to allow the file data contents to be written. In addition, files with security.ima xattrs containing a file signature are considered "immutable" and can not be modified. The file contents need to be written, before signing the file. This patch relaxes this requirement for new files, allowing the file signature to be written before the file contents. Changelog: - defer identifying files with signatures stored as security.ima (based on Dmitry Rozhkov's comments) - removing tests (eg. dentry, dentry->d_inode, inode->i_size == 0) (based on Al's review) Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com> Cc: Al Viro <<viro@zeniv.linux.org.uk> Tested-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com> fs/namei.c | 2 ++ include/linux/ima.h | 6 ++++++ security/integrity/ima/ima_appraise.c | 5 +++++ security/integrity/ima/ima_main.c | 25 ++++++++++++++++++++++++- 4 files changed, 37 insertions(+), 1 deletion(-) commit 42a4c603198f0d45b7aa936d3ac6ba1b8bd14a1b Author: Mimi Zohar <zohar@linux.vnet.ibm.com> Date: Mon Feb 29 08:30:12 2016 -0500 ima: fix ima_inode_post_setattr Changing file metadata (eg. uid, guid) could result in having to re-appraise a file's integrity, but does not change the "new file" status nor the security.ima xattr. The IMA_PERMIT_DIRECTIO and IMA_DIGSIG_REQUIRED flags are policy rule specific. This patch only resets these flags, not the IMA_NEW_FILE or IMA_DIGSIG flags. With this patch, changing the file timestamp will not remove the file signature on new files. Reported-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com> Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com> Tested-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com> security/integrity/ima/ima_appraise.c | 2 +- security/integrity/integrity.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) commit 39d637af5aa7577f655c58b9e55587566c63a0af Author: Dmitry Kasatkin <dmitry.kasatkin@huawei.com> Date: Sun Oct 26 12:42:07 2014 +0200 vfs: forbid write access when reading a file into memory This patch is based on top of the "vfs: support for a common kernel file loader" patch set. In general when the kernel is reading a file into memory it does not want anything else writing to it. The kernel currently only forbids write access to a file being executed. This patch extends this locking to files being read by the kernel. Changelog: - moved function to kernel_read_file() - Mimi - updated patch description - Mimi Signed-off-by: Dmitry Kasatkin <dmitry.kasatkin@huawei.com> Cc: Al Viro <viro@ZenIV.linux.org.uk> Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com> Reviewed-by: Luis R. Rodriguez <mcgrof@kernel.org> Acked-by: Kees Cook <keescook@chromium.org> fs/exec.c | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) commit 1a472c9dba6b9646fd36717968f6a531b4441c7d Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:05 2016 +1000 powerpc/mm/radix: Add tlbflush routines Core kernel doesn't track the page size of the VA range that we are invalidating. Hence we end up flushing TLB for the entire mm here. Later patches will improve this. We also don't flush page walk cache separetly instead use RIC=2 when flushing TLB, because we do a MMU gather flush after freeing page table. MMU_NO_CONTEXT is updated for hash. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu-hash.h | 1 + arch/powerpc/include/asm/book3s/64/tlbflush-hash.h | 13 +- .../powerpc/include/asm/book3s/64/tlbflush-radix.h | 33 +++ arch/powerpc/include/asm/book3s/64/tlbflush.h | 20 ++ arch/powerpc/include/asm/tlbflush.h | 1 + arch/powerpc/kernel/mce_power.c | 3 + arch/powerpc/mm/Makefile | 2 +- arch/powerpc/mm/tlb-radix.c | 242 +++++++++++++++++++++ 8 files changed, 310 insertions(+), 5 deletions(-) commit 676012a66f651a98808459bc8ab75661828ed96f Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:04 2016 +1000 powerpc/mm: Hash abstraction for tlbflush routines Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/tlbflush-hash.h | 28 ++++++----- arch/powerpc/include/asm/book3s/64/tlbflush.h | 56 ++++++++++++++++++++++ arch/powerpc/include/asm/tlbflush.h | 2 +- arch/powerpc/mm/tlb_hash64.c | 2 +- 4 files changed, 73 insertions(+), 15 deletions(-) commit f5df4b4be9ae5abf748065d7f40d6027bf9af148 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:03 2016 +1000 powerpc/mm: Rename mmu_context_hash64.c to mmu_context_book3s64.c This file now contains both hash and radix specific code. Rename it to indicate this better. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/Makefile | 7 +- arch/powerpc/mm/mmu_context_book3s64.c | 178 +++++++++++++++++++++++++++++++++ arch/powerpc/mm/mmu_context_hash64.c | 178 --------------------------------- 3 files changed, 181 insertions(+), 182 deletions(-) commit 7e381c0ff618cab3e687e953b72f59ef2a891ba9 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:02 2016 +1000 powerpc/mm/radix: Add mmu context handling callback for radix Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/mmu_context.h | 4 ++++ arch/powerpc/mm/mmu_context_hash64.c | 43 +++++++++++++++++++++++++++------- 2 files changed, 39 insertions(+), 8 deletions(-) commit d2adba3fd137b46903dad813e2a4777b96c85e0f Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:01 2016 +1000 powerpc/mm: Abstraction for switch_mmu_context() How we switch MMU context differs between hash and radix. For hash we need to switch the SLB details and for radix we need to switch the PID SPR. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/mmu_context.h | 25 +++++++++++++------------ arch/powerpc/kernel/swsusp.c | 2 +- arch/powerpc/mm/mmu_context_nohash.c | 3 ++- drivers/cpufreq/pmac32-cpufreq.c | 2 +- drivers/macintosh/via-pmu.c | 4 ++-- 5 files changed, 19 insertions(+), 17 deletions(-) commit d9225ad923514252ec8d10dac67e5a7a2f0aa345 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:26:00 2016 +1000 powerpc/mm/radix: Add radix callbacks for vmemmap and map_kernel page() Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 12 ++++++++++++ arch/powerpc/include/asm/book3s/64/radix.h | 6 ++++++ arch/powerpc/mm/pgtable-radix.c | 20 ++++++++++++++++++++ 3 files changed, 38 insertions(+) commit 31a14fae92b29b7a7fcc65600f072bf448d3b0eb Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:59 2016 +1000 powerpc/mm: Abstraction for vmemmap and map_kernel_page() For hash we create vmemmap mapping using bolted hash page table entries. For radix we fill the radix page table. The next patch will add the radix details for creating vmemmap mappings. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 8 ++++++++ arch/powerpc/include/asm/book3s/64/pgtable.h | 20 ++++++++++++++++++++ arch/powerpc/include/asm/nohash/64/pgtable.h | 7 +++++++ arch/powerpc/mm/init_64.c | 5 ----- arch/powerpc/mm/mmu_decl.h | 5 ----- arch/powerpc/mm/pgtable-hash64.c | 12 ++++++------ 6 files changed, 41 insertions(+), 16 deletions(-) commit 2bfd65e45e877fb5704730244da67c748d28a1b8 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:58 2016 +1000 powerpc/mm/radix: Add radix callbacks for early init routines This adds routines for early setup for radix. We use device tree property "ibm,processor-radix-AP-encodings" to find supported page sizes. If we don't find the above we consider 64K and 4K as supported page sizes. We do map vmemap using 2M page size if we can. The linear mapping is done such that we use required page size for that range. For example memory of 3.5G is mapped such that we use 1G mapping till 3G range and use 2M mapping for the rest. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu.h | 17 +- arch/powerpc/include/asm/book3s/64/radix.h | 2 + arch/powerpc/include/asm/reg.h | 1 + arch/powerpc/mm/Makefile | 1 + arch/powerpc/mm/pgtable-radix.c | 356 +++++++++++++++++++++++++++++ arch/powerpc/platforms/powernv/setup.c | 5 +- 6 files changed, 380 insertions(+), 2 deletions(-) commit 756d08d1ba169ed9eae4d48e9a0af014e86593fc Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:57 2016 +1000 powerpc/mm: Abstract early MMU init in preparation for radix Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu.h | 20 ++++++++++++++++++++ arch/powerpc/include/asm/mmu.h | 14 +++++++------- arch/powerpc/mm/hash_utils_64.c | 6 +++--- 3 files changed, 30 insertions(+), 10 deletions(-) commit 6cc1a0ee4ce29ad1cbdc622db6f9bc16d3056067 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:56 2016 +1000 powerpc/mm/radix: Add radix callback for pmd accessors This only does 64K Linux page support for now. 64K hash Linux config THP needs to differentiate it from hugetlb huge page because with THP we need to track hash pte slot information with respect to each subpage. This is not needed with hugetlb hugepage, because we don't do MPSS with hugetlb. Radix doesn't have any such restrictions. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-64k.h | 9 ++++----- arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 23 +++++++++++++++++++++++ arch/powerpc/include/asm/book3s/64/radix.h | 9 +++++++++ 3 files changed, 36 insertions(+), 5 deletions(-) commit a9252aaefe7e72133e7a37e0eff4e950a4f33af1 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:55 2016 +1000 powerpc/mm: Move hugetlb and THP related pmd accessors to pgtable.h Here we create pgtable-64/4k.h and move pmd accessors that are common between hash and radix there. We can't do much sharing with 4K Linux page size because 4K Linux page size with hash config doesn't support THP. So for now it is empty. In later patches we will add functions that does conditional hash/radix accessors there. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-64k.h | 83 --------------------- arch/powerpc/include/asm/book3s/64/pgtable-4k.h | 7 ++ arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 94 ++++++++++++++++++++++++ arch/powerpc/include/asm/book3s/64/pgtable.h | 7 ++ 4 files changed, 108 insertions(+), 83 deletions(-) commit ac94ac79dc0fc473aebcbe2ba4c26a5341b866be Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:54 2016 +1000 powerpc/mm: Add radix callbacks to pte accessors For those pte accessors, that operate on a different set of pte bits between hash/radix, we add a generic variant that does a conditional to hash linux or radix variant. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 41 +++++++++--------- arch/powerpc/include/asm/book3s/64/pgtable.h | 64 ++++++++++++++++++++++++++++ 2 files changed, 84 insertions(+), 21 deletions(-) commit 566ca99af026d43c7cf7ab72f78463dbcc7e6ac2 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:53 2016 +1000 powerpc/mm/radix: Add dummy radix_enabled() In this patch we add the radix Kconfig and conditional check. radix_enabled() is written to always return 0 here. Once we have all needed radix changes added, we will update this to an mmu_feature check. We need to add this early so that we can get it all build in the early stage. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu.h | 2 ++ arch/powerpc/include/asm/mmu.h | 3 +++ arch/powerpc/platforms/Kconfig.cputype | 9 +++++++++ 3 files changed, 14 insertions(+) commit b0b5e9b1304765d079c71373df236733765f42ac Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:52 2016 +1000 powerpc/mm/radix: Add radix pte #defines This adds Power ISA 3.0 specific pte defines. We share most of the details with hash Linux page table format. This patch indicates only things where we differ. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 1 + arch/powerpc/include/asm/book3s/64/radix-4k.h | 12 +++ arch/powerpc/include/asm/book3s/64/radix-64k.h | 12 +++ arch/powerpc/include/asm/book3s/64/radix.h | 125 +++++++++++++++++++++++++ 4 files changed, 150 insertions(+) commit 34fbadd8e98bbd85f503298152654f677db47ae3 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:51 2016 +1000 powerpc/mm: Move pte related functions together Only code movement. No functionality change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 142 +++++++++++++-------------- 1 file changed, 71 insertions(+), 71 deletions(-) commit aba480e1371358b419b2b680cc632f3210280b03 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:50 2016 +1000 powerpc/mm: Move page table index and and vaddr to pgtable.h Now that the page table size is a variable, we can move these to generic pgtable.h. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 16 ---------------- arch/powerpc/include/asm/book3s/64/pgtable.h | 12 ++++++++++++ 2 files changed, 12 insertions(+), 16 deletions(-) commit dd1842a2a448bb66d74aa02a550df6be8c25f20b Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:49 2016 +1000 powerpc/mm: Make page table size a variable Radix and hash MMU models support different page table sizes. Make the #defines a variable so that existing code can work with variable sizes. Slice related code is only used by hash, so use hash constants there. We will replicate some of the boundary conditions with resepct to TASK_SIZE using radix values too. Right now we do boundary condition check using hash constants. Swapper pgdir size is initialized in asm code. We select the max pgd size to keep it simple. For now we select hash pgdir. When adding radix we will switch that to radix pgdir which is 64K. BUILD_BUG_ON check which is removed is already done in hugepage_init() using MAYBE_BUILD_BUG_ON(). Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 45 ++++---------------- arch/powerpc/include/asm/book3s/64/hash-64k.h | 46 +++++--------------- arch/powerpc/include/asm/book3s/64/hash.h | 14 ++++--- arch/powerpc/include/asm/book3s/64/mmu-hash.h | 4 +- arch/powerpc/include/asm/book3s/64/pgtable.h | 60 +++++++++++++++++++++++++++ arch/powerpc/include/asm/page_64.h | 2 +- arch/powerpc/kernel/asm-offsets.c | 4 ++ arch/powerpc/mm/hash_utils_64.c | 12 ++++++ arch/powerpc/mm/init_64.c | 4 +- arch/powerpc/mm/pgtable-book3e.c | 1 + arch/powerpc/mm/pgtable-hash64.c | 1 + arch/powerpc/mm/pgtable_64.c | 33 ++++++++++----- arch/powerpc/mm/slb_low.S | 2 +- arch/powerpc/mm/slice.c | 4 +- 14 files changed, 135 insertions(+), 97 deletions(-) commit 13f829a5a1032ff1b96c727429bf461f7a8ad3f2 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:48 2016 +1000 powerpc/mm: Move pte accessors that operate on common pte bits to pgtable.h These pte functions will remain the same between radix and hash. Move them to pgtable.h. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 205 -------------------------- arch/powerpc/include/asm/book3s/64/pgtable.h | 209 +++++++++++++++++++++++++++ 2 files changed, 209 insertions(+), 205 deletions(-) commit 2e8735198af0392d9032a356ee6c82686afca779 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:47 2016 +1000 powerpc/mm: Move common pte bits and accessors to book3s/64/pgtable.h Now that we have moved book3s hash64 Linux pte bits to match Power ISA 3.0 radix pte bit positions, we move the matching pte bits to a common header. Only code movement in this patch. No functionality change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 136 ------------------------- arch/powerpc/include/asm/book3s/64/pgtable.h | 143 ++++++++++++++++++++++++++- 2 files changed, 141 insertions(+), 138 deletions(-) commit d2cf005038104cf383db1469a7f0bbb5b0368f33 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:46 2016 +1000 powerpc/mm: Handle _PTE_NONE_MASK I am splitting this as a separate patch to get better review. If ok we should merge this with previous patch. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 945537df7a107e0dad7b0d3d14df46cfba46f4c5 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:45 2016 +1000 powerpc/mm/book3s: Rename hash specific PTE bits to carry H_ prefix This helps to make following hash only pte bits easier. We have kept _PAGE_CHG_MASK, _HPAGE_CHG_MASK and _PAGE_PROT_BITS as it is in this patch eventhough they use hash specific bits. Using them in radix as it is should be ok, because with radix we expect those bit positions to be zero. Only renames in this patch, no change in functionality. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 12 ++++-- arch/powerpc/include/asm/book3s/64/hash-64k.h | 38 +++++++++++-------- arch/powerpc/include/asm/book3s/64/hash.h | 38 +++++++++---------- arch/powerpc/include/asm/book3s/64/pgtable.h | 4 +- arch/powerpc/include/asm/kvm_book3s_64.h | 4 +- arch/powerpc/include/asm/pte-common.h | 4 ++ arch/powerpc/mm/hash64_4k.c | 21 ++++++----- arch/powerpc/mm/hash64_64k.c | 53 ++++++++++++++------------- arch/powerpc/mm/hash_utils_64.c | 8 ++-- arch/powerpc/mm/hugepage-hash64.c | 14 +++---- arch/powerpc/mm/hugetlbpage-hash64.c | 20 +++++----- arch/powerpc/mm/pgtable_64.c | 8 ++-- arch/powerpc/mm/tlb_hash64.c | 4 +- 13 files changed, 121 insertions(+), 107 deletions(-) commit eee24b5aafe87f3591990528eae2ad22e2c1d50c Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:44 2016 +1000 powerpc/mm: Move hash and no hash code to separate files This patch reduces the number of #ifdefs in C code and will also help in adding radix changes later. Only code movement in this patch. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> [mpe: Propagate copyrights and update GPL text] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/Makefile | 3 +- arch/powerpc/mm/init_64.c | 74 ++---------------------- arch/powerpc/mm/pgtable-book3e.c | 121 +++++++++++++++++++++++++++++++++++++++ arch/powerpc/mm/pgtable-hash64.c | 94 ++++++++++++++++++++++++++++++ arch/powerpc/mm/pgtable_64.c | 83 --------------------------- 5 files changed, 222 insertions(+), 153 deletions(-) commit 50de596de8be6de75401a2190b90a822e8a1bab2 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:43 2016 +1000 powerpc/mm/hash: Add support for Power9 Hash PowerISA 3.0 adds a parition table indexed by LPID. Parition table allows us to specify the MMU model that will be used for guest and host translation. This patch adds support with SLB based hash model (UPRT = 0). What is required with this model is to support the new hash page table entry format and also setup partition table such that we use hash table for address translation. We don't have segment table support yet. In order to make sure we don't load KVM module on Power9 (since we don't have kvm support yet) this patch also disables KVM on Power9. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu-hash.h | 13 +++++++-- arch/powerpc/kvm/book3s_hv.c | 6 ++++ arch/powerpc/kvm/book3s_pr.c | 6 +++- arch/powerpc/mm/hash_native_64.c | 11 ++++++- arch/powerpc/mm/hash_utils_64.c | 42 +++++++++++++++++++++++++-- arch/powerpc/mm/pgtable_64.c | 7 +++++ arch/powerpc/platforms/ps3/htab.c | 2 +- arch/powerpc/platforms/pseries/lpar.c | 2 +- 8 files changed, 81 insertions(+), 8 deletions(-) commit e99833448c5fa198a120db6d7087dd17149dc273 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:42 2016 +1000 powerpc/mm/radix: Add partition table format & callback Add structs and #defines related to the radix MMU partition table format. We also add a ppc_md callback for updating a partition table entry. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/mmu.h | 31 +++++++++++++++++++++++++++++-- arch/powerpc/include/asm/machdep.h | 1 + arch/powerpc/include/asm/reg.h | 1 + 3 files changed, 31 insertions(+), 2 deletions(-) commit 11a6f6abd74ab80865023200ca33515f6db43d63 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:41 2016 +1000 powerpc/mm: Move radix/hash common data structures to book3s64 headers Start moving code that is generic between radix and hash to book3s64 specific headers from the book3s64 hash specific one. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/32/mmu-hash.h | 6 +-- arch/powerpc/include/asm/book3s/64/mmu-hash.h | 61 ++--------------------- arch/powerpc/include/asm/book3s/64/mmu.h | 72 +++++++++++++++++++++++++++ arch/powerpc/include/asm/mmu.h | 11 ++-- 4 files changed, 85 insertions(+), 65 deletions(-) commit 33d336d986edc544cd153e31a28a515d5648721b Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:40 2016 +1000 powerpc/mm: Use generic version of ptep_clear_flush_young() The radix variant is going to require a flush_tlb_range(). With flush_tlb_range() added, ptep_clear_flush_young() is the same as the generic version. So drop the powerpc specific variant. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) commit ff844b741e1db87a72aabb5f61f6e0ca82bfe100 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:39 2016 +1000 powerpc/mm: Use generic version of pmdp_clear_flush_young() The radix variant is going to require a flush_pmd_tlb_range(). With flush_pmd_tlb_range() added, pmdp_clear_flush_young() is the same as the generic version. So drop the powerpc specific variant. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 3 --- arch/powerpc/mm/pgtable_64.c | 13 +++---------- 2 files changed, 3 insertions(+), 13 deletions(-) commit 30bda41aba4efb2370c97e2cbe7385de93ccc372 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:38 2016 +1000 powerpc/mm: Drop WIMG in favour of new constants PowerISA 3.0 introduces two pte bits with the below meaning for radix: 00 -> Normal Memory 01 -> Strong Access Order (SAO) 10 -> Non idempotent I/O (Cache inhibited and guarded) 11 -> Tolerant I/O (Cache inhibited) We drop the existing WIMG bits in the Linux page table in favour of the above constants. We loose _PAGE_WRITETHRU with this conversion. We only use writethru via pgprot_cached_wthru() which is used by fbdev/controlfb.c which is Apple control display and also PPC32. With respect to _PAGE_COHERENCE, we have been marking hpte always coherent for some time now. htab_convert_pte_flags() always added HPTE_R_M. NOTE: KVM changes need closer review. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 70 ++++++++++++++----------------- arch/powerpc/include/asm/kvm_book3s_64.h | 27 +++++------- arch/powerpc/kvm/book3s_64_mmu_hv.c | 11 +++-- arch/powerpc/kvm/book3s_hv_rm_mmu.c | 12 +++--- arch/powerpc/mm/hash64_64k.c | 2 +- arch/powerpc/mm/hash_utils_64.c | 18 ++++---- arch/powerpc/mm/pgtable.c | 8 ++-- arch/powerpc/mm/pgtable_64.c | 4 -- arch/powerpc/platforms/pseries/lpar.c | 4 -- 9 files changed, 66 insertions(+), 90 deletions(-) commit 72176dd0ad36c6d8e13515d085f7a229a55a2985 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:37 2016 +1000 powerpc/mm: Use a helper for finding pte bits mapping I/O area Use a helper instead of open coding with constants. A later patch will drop the WIMG bits and use PowerISA 3.0 defines. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/btext.c | 2 +- arch/powerpc/kernel/isa-bridge.c | 4 ++-- arch/powerpc/kernel/pci_64.c | 2 +- arch/powerpc/mm/pgtable_64.c | 4 ++-- arch/powerpc/platforms/ps3/spu.c | 2 +- drivers/pcmcia/electra_cf.c | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) commit e58e87adc8bf92e9c6abb1dc1f4af2500aa07ff3 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:36 2016 +1000 powerpc/mm: Update _PAGE_KERNEL_RO PS3 had used a PPP bit hack to implement a read only mapping in the kernel area. Since we are bolting the ioremap area, it used the pte flags _PAGE_PRESENT | _PAGE_USER to get a PPP value of 0x3 there by resulting in a read only mapping. This means the area can be accessed by user space, but kernel will never return such an address to user space. But we can do better by implementing a read only kernel mapping using PPP bits 0b110. This also allows us to do read only kernel mapping for radix in later patches. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 4 ++-- arch/powerpc/mm/hash_utils_64.c | 17 +++++++++++------ arch/powerpc/platforms/ps3/spu.c | 2 +- 3 files changed, 14 insertions(+), 9 deletions(-) commit 96270b1fc25d527b015c73533119f6c85df2e0ff Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:35 2016 +1000 powerpc/mm: Remove RPN_SHIFT and RPN_SIZE PTE_RPN_SHIFT is actually page size dependent. Even though PowerISA 3.0 expects only the lower 12 bits to be zero, we will always find the pages to be PAGE_SHIFT aligned. In case of hash config, this also allows us to use the additional 3 bits to track pte specific information. We need to make sure we use these bits only for hash specific pte flags. For both 4K and 64K config, pte now can hold 57 bits address. Inorder to keep things simpler, drop PTE_RPN_SHIFT and PTE_RPN_SIZE and specify the 57 bit detail explicitly. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-4k.h | 4 ---- arch/powerpc/include/asm/book3s/64/hash-64k.h | 26 +++++++++++++------------- arch/powerpc/include/asm/book3s/64/hash.h | 15 +++++++-------- arch/powerpc/include/asm/book3s/64/pgtable.h | 4 ++-- arch/powerpc/mm/pgtable_64.c | 2 +- 5 files changed, 23 insertions(+), 28 deletions(-) commit ac29c64089b74d107edb90879e63a2f7a03cd66b Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:34 2016 +1000 powerpc/mm: Replace _PAGE_USER with _PAGE_PRIVILEGED _PAGE_PRIVILEGED means the page can be accessed only by the kernel. This is done to keep pte bits similar to PowerISA 3.0 Radix PTE format. User pages are now marked by clearing _PAGE_PRIVILEGED bit. Previously we allowed the kernel to have a privileged page in the lower address range (USER_REGION). With this patch such access is denied. We also prevent a kernel access to a non-privileged page in higher address range (ie, REGION_ID != 0). Both the above access scenarios should never happen. Cc: Arnd Bergmann <arnd@arndb.de> Cc: Jeremy Kerr <jk@ozlabs.org> Cc: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 34 ++++++++++++++-------------- arch/powerpc/include/asm/book3s/64/pgtable.h | 18 ++++++++++++++- arch/powerpc/mm/hash64_4k.c | 2 +- arch/powerpc/mm/hash64_64k.c | 4 ++-- arch/powerpc/mm/hash_utils_64.c | 16 ++++++++----- arch/powerpc/mm/hugepage-hash64.c | 2 +- arch/powerpc/mm/hugetlbpage-hash64.c | 3 ++- arch/powerpc/mm/hugetlbpage.c | 2 +- arch/powerpc/mm/pgtable.c | 15 ++++++++++-- arch/powerpc/mm/pgtable_64.c | 15 +++++++++--- arch/powerpc/platforms/cell/spufs/fault.c | 2 +- drivers/misc/cxl/fault.c | 4 +++- 12 files changed, 80 insertions(+), 37 deletions(-) commit e7bfc462d32fc417d3fea8ad07b62b59f000e925 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:33 2016 +1000 powerpc/mm: Use pte_user() instead of open coding We have a common declaration in pte-common.h Add a book3s specific one and switch to pte_user() in callchain.c. In a subsequent patch we will switch _PAGE_USER to _PAGE_PRIVILEGED in the book3s version only. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/pgtable.h | 5 +++++ arch/powerpc/perf/callchain.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) commit 7e1e63c5e9d694c1198d410a6c7b2d0fa06da355 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri Apr 29 23:25:32 2016 +1000 powerpc/mm: Convert pte_user() to static inline In a subsequent patch we want to add a second definition of pte_user(). Before we do that, make the signature clear, ie. it takes a pte_t and returns bool. We move it up inside the existing #ifndef __ASSEMBLY__ block, but otherwise it's a straight conversion. Convert the call in settlbcam(), which passes an unsigned long, to pass a pte_t. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/pte-common.h | 17 ++++++++++------- arch/powerpc/mm/fsl_booke_mmu.c | 2 +- 2 files changed, 11 insertions(+), 8 deletions(-) commit 73a1441a9b2ae05c15eb7cc90d4de379b44249bf Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:31 2016 +1000 powerpc/mm/subpage: Clear RWX bit to indicate no access Subpage protection used to depend on the _PAGE_USER bit to implement no access mode. This patch switches that to use _PAGE_RWX. We clear Read, Write and Execute access from the pte instead of clearing _PAGE_USER now. This was done so that we can switch to _PAGE_PRIVILEGED in a later patch. subpage_protection() returns pte bits that need to be cleared. Instead of updating the interface to handle no-access in a separate way, it appears simpler to clear RWX acecss to indicate no access. We still don't insert hash ptes for no access implied by !_PAGE_RWX. Hence we should not get PROT_FAULT with change. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/mm/hash_utils_64.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit c7d54842deb1fa357cff75b988275a1c9f259140 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:30 2016 +1000 powerpc/mm: Use _PAGE_READ to indicate Read access This splits the _PAGE_RW bit into _PAGE_READ and _PAGE_WRITE. It also removes the dependency on _PAGE_USER for implying read only. Few things to note here is that, we have read implied with write and execute permission. Hence we should always find _PAGE_READ set on hash pte fault. We still can't switch PROT_NONE to !(_PAGE_RWX). Auto numa depends on marking a prot none pte _PAGE_WRITE. (For more details look at b191f9b106ea "mm: numa: preserve PTE write permissions across a NUMA hinting fault") Cc: Arnd Bergmann <arnd@arndb.de> Cc: Jeremy Kerr <jk@ozlabs.org> Cc: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-64k.h | 4 +-- arch/powerpc/include/asm/book3s/64/hash.h | 35 ++++++++++++++++----------- arch/powerpc/include/asm/pte-common.h | 5 ++++ arch/powerpc/mm/hash64_4k.c | 2 +- arch/powerpc/mm/hash64_64k.c | 4 +-- arch/powerpc/mm/hash_utils_64.c | 9 ++++--- arch/powerpc/mm/hugepage-hash64.c | 2 +- arch/powerpc/mm/hugetlbpage-hash64.c | 2 +- arch/powerpc/mm/hugetlbpage.c | 4 +-- arch/powerpc/mm/pgtable.c | 4 +-- arch/powerpc/mm/pgtable_64.c | 5 ++-- arch/powerpc/platforms/cell/spu_base.c | 2 +- arch/powerpc/platforms/cell/spufs/fault.c | 4 +-- drivers/misc/cxl/fault.c | 4 +-- 14 files changed, 49 insertions(+), 37 deletions(-) commit ee3caed37d763ab28f8ac55563f38fb7530c6252 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri Apr 29 23:25:29 2016 +1000 powerpc/mm: Use pte_raw() in pte_same()/pmd_same() We can avoid doing endian conversions by using pte_raw() in pxx_same(). The swap of the constant (_PAGE_HPTEFLAGS) should be done at compile time by the compiler. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash-64k.h | 2 +- arch/powerpc/include/asm/book3s/64/hash.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) commit 5dc1ef858c12f865e3676727e03519bece4ce6c1 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:28 2016 +1000 powerpc/mm: Use big endian Linux page tables for book3s 64 Traditionally Power server machines have used the Hashed Page Table MMU mode. In this mode Linux manages its own tree of nested page tables, aka. "the Linux page tables", which are not used by the hardware directly, and software loads translations into the hash page table for use by the hardware. Power ISA 3.0 defines a new MMU mode, known as Radix Tree Translation, where the hardware can directly operate on the Linux page tables. However the hardware requires that the page tables be in big endian format. To accommodate this, switch the pgtable types to __be64 and add appropriate endian conversions. Because we will be supporting a single kernel binary that boots using either radix or hash mode, we always store the Linux page tables big endian, even in hash mode where they are not actually used by the hardware. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> [mpe: Fix sparse errors, flesh out change log] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/64/hash.h | 24 ++++---- arch/powerpc/include/asm/page.h | 4 ++ arch/powerpc/include/asm/pgtable-be-types.h | 92 +++++++++++++++++++++++++++++ arch/powerpc/mm/hash64_64k.c | 1 - arch/powerpc/mm/hugepage-hash64.c | 4 +- arch/powerpc/mm/pgtable_64.c | 12 ++-- 6 files changed, 120 insertions(+), 17 deletions(-) commit 3910a7f485e1222de2176ef5bf3a1d8de3152920 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri Apr 29 23:25:27 2016 +1000 powerpc/mm: Add pte_xchg() helper We have five locations in 64-bit hash MMU code that do a cmpxchg() of a PTE. Currently doing it inline OK, but in a future patch we will be converting the PTEs to __be64 in some configs. In that case we will need casts at every cmpxchg() site in order to keep sparse happy. So move the logic into a helper, this is a reasonably nice cleanup on its own. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/kvm_book3s_64.h | 5 +---- arch/powerpc/include/asm/pgtable-types.h | 12 ++++++++++++ arch/powerpc/mm/hash64_4k.c | 4 ++-- arch/powerpc/mm/hash64_64k.c | 7 +++---- arch/powerpc/mm/hugetlbpage-hash64.c | 4 ++-- 5 files changed, 20 insertions(+), 12 deletions(-) commit 4bece39b503c2340de154c82bf6d928e72d74d4e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:26 2016 +1000 powerpc/mm: Drop PTE_ATOMIC_UPDATES from pmd_hugepage_update() pmd_hugepage_update() is inside #ifdef CONFIG_TRANSPARENT_HUGEPAGE. THP can only be enabled if PPC_BOOK3S_64=y && PPC_64K_PAGES=y, aka. hash64. On hash64 we always define PTE_ATOMIC_UPDATES to 1, meaning the #ifdef in pmd_hugepage_update() is unnecessary, so drop it. That is also the only use of PTE_ATOMIC_UPDATES in any of the hash code, meaning we no longer need to #define it at all in the hash headers. Note it's still #defined and used in the nohash code. Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/book3s/32/hash.h | 3 --- arch/powerpc/include/asm/book3s/64/hash.h | 2 -- arch/powerpc/mm/pgtable_64.c | 6 +----- 3 files changed, 1 insertion(+), 10 deletions(-) commit 670eea924198456873f3346bb247b662d7ddffd7 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Fri Apr 29 23:25:25 2016 +1000 powerpc/mm: Always use STRICT_MM_TYPECHECKS Testing done by Paul Mackerras has shown that with a modern compiler there is no negative effect on code generation from enabling STRICT_MM_TYPECHECKS. So remove the option, and always use the strict type definitions. Acked-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/Kconfig.debug | 8 ------ arch/powerpc/include/asm/pgtable-types.h | 46 -------------------------------- 2 files changed, 54 deletions(-) commit 8ffb4103f5e28d7e7890ed4774d8e009f253f56e Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Fri Apr 29 23:25:24 2016 +1000 IB/qib: Use cache inhibitted and guarded mapping on powerpc The driver was requesting for a writethrough mapping. But with those flags we will end up with an SAO mapping because we now have memory conherence always enabled. ie, the existing mapping will end up with a WIMG value 0b1110 which is Strong Access Order. Update this to use cache inhibitted guarded mapping. Cc: Doug Ledford <dledford@redhat.com> Cc: Sean Hefty <sean.hefty@intel.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Cc: linux-rdma@vger.kernel.org Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Acked-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/infiniband/hw/qib/qib_file_ops.c | 5 +---- drivers/infiniband/hw/qib/qib_pcie.c | 6 ------ 2 files changed, 1 insertion(+), 10 deletions(-) commit 3b711e0781f34400326f911c15784e84deca84b6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sun May 1 10:29:10 2016 +0200 gpio: xgene: implement .get_direction() This implements the .get_direction() callback for the xgene GPIO controller. Cc: Duc Dang <dhdang@apm.com> Cc: Feng Kan <fkan@apm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-xgene.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 0c60de3f73cddde6a83979c64f63cb1101f5326c Author: Duc Dang <dhdang@apm.com> Date: Sat Apr 30 13:49:27 2016 -0700 gpio: xgene: Enable ACPI support for X-Gene GFC GPIO driver This patch enables ACPI support for X-Gene GFC GPIO driver. Signed-off-by: Duc Dang <dhdang@apm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-xgene.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit d449d69d216854a8cab049fe035ffefbf383a2e1 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Mar 23 04:52:45 2016 +0200 misc: sram: fix check of devm_ioremap*() return value Both devm_ioremap() and devm_ioremap_wc() functions return either a pointer to valid iomem region or NULL, check for IS_ERR() is improper and may result in oops on error path. Now on error -ENOMEM is returned. Fixes: 0ab163ad1ea0 ("misc: sram: switch to ioremap_wc from ioremap") Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/sram.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 47f55b74cfb28cbd3328ffd5c4c0f7a14da36498 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Mon Mar 7 17:05:50 2016 +0530 spmi: do not use bus internal data The variable p is a data structure which is used by the driver core internally and it is not expected that busses will be directly accessing these driver core internal only data. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/spmi/spmi.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 7ff4bdd45448936363dc6dc6c851112b5c08e209 Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Wed Apr 20 11:03:55 2016 -0400 mei: fix waiting for wr_ctrl for corner cases. A control message reply may not be received if either a link reset has occurred or disconnection is initiated by the FW. In the both cases the client state will be set straight to DISCONNECTED and the driver will wait till timeout. Adding DISCONNECTED state in the waiting condition will release the client from the stall. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/client.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) commit 4a8eaa96d8eebf5818ddf1aca92e775a2c2d3f7e Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Wed Apr 20 11:03:54 2016 -0400 mei: don't clean control queues on notify request timeout Timeout on notify request is not a fatal condition, and actually cleaning control queues will disrupt other control flows of the same client. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/client.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 9d04ee11db7bf0d848266cbfd7db336097a0e239 Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Sun Apr 17 12:16:04 2016 -0400 mei: amthif: discard not read messages When a message is received and amthif client is not in reading state the message is ignored and left dangling in the queue. This may happen after one of the amthif host connections is closed w/o completing the reading. Another client will pick up a wrong message on next read attempt which will lead to link reset. To prevent this the driver has to properly discard the message when amthif client is not in reading state. Cc: <stable@vger.kernel.org> #4.2+ Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/amthif.c | 4 +++- drivers/misc/mei/interrupt.c | 1 - drivers/misc/mei/mei_dev.h | 2 ++ 3 files changed, 5 insertions(+), 2 deletions(-) commit 6a8d648c8d1824117a9e9edb948ed1611fb013c0 Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Sun Apr 17 12:16:03 2016 -0400 mei: fix NULL dereferencing during FW initiated disconnection In the case when disconnection is initiated from the FW the driver is flushing items from the write control list while iterating over it: mei_irq_write_handler() list_for_each_entry_safe(ctrl_wr_list) <-- outer loop mei_cl_irq_disconnect_rsp() mei_cl_set_disconnected() mei_io_list_flush(ctrl_wr_list) <-- destorying list We move the list flushing to the completion routine. Cc: <stable@vger.kernel.org> #4.2+ Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/client.c | 4 ++++ drivers/misc/mei/hbm.c | 3 +-- drivers/misc/mei/interrupt.c | 5 +---- 3 files changed, 6 insertions(+), 6 deletions(-) commit cc25aa94e43779b86300c443acb6947dd739fdd1 Author: Alexander Usyskin <alexander.usyskin@intel.com> Date: Sun Apr 17 12:16:02 2016 -0400 mei: drop global me_client_index Global me_client_index is used only during the enumeration process and can be effectively replaced by me_addr data from the last enumeration response as we always enumerate clients in the increasing order. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/hbm.c | 23 ++++++++--------------- drivers/misc/mei/mei_dev.h | 2 -- 2 files changed, 8 insertions(+), 17 deletions(-) commit b9c79543efcd0235d2fc1485c31ec9e9584f3ad7 Author: Alexey Khoroshilov <khoroshilov@ispras.ru> Date: Fri Apr 1 23:53:01 2016 +0300 mei: do not pin module if cldrv->probe() failed If cldrv->probe() failed in mei_cl_device_probe(), the mei module is left pinned. The patch moves __module_get(THIS_MODULE) after cldrv->probe(). Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/bus.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit bd83a4ab569ddfc71a82fb0dd002f353b67df7df Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Sat Apr 30 17:13:20 2016 +0100 char: xillybus: use devm_add_action_or_reset If devm_add_action() fails we are explicitly calling dma_unmap_single(), pci_unmap_single() and kfree(). Lets use the helper devm_add_action_or_reset() and return directly in case of error, as we know that the cleanup function has been already called by the helper if there was any error. At that same time remove the variable rc which becomes unused now. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/xillybus/xillybus_of.c | 11 +---------- drivers/char/xillybus/xillybus_pcie.c | 10 +--------- 2 files changed, 2 insertions(+), 19 deletions(-) commit ea37a6b8a0b9fbe3f85b4b9da3206c28f1de6f8e Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:56 2016 -0700 drivers:hv: Separate out frame buffer logic when picking MMIO range Simplify the logic that picks MMIO ranges by pulling out the logic related to trying to lay frame buffer claim on top of where the firmware placed the frame buffer. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 80 ++++++++++++++++++++++---------------------------- 1 file changed, 35 insertions(+), 45 deletions(-) commit 6d146aefbaa5c5dff0c2e9d81e90e5112ded284e Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:55 2016 -0700 drivers:hv: Record MMIO range in use by frame buffer Later in the boot sequence, we need to figure out which memory ranges can be given out to various paravirtual drivers. The hyperv_fb driver should, ideally, be placed right on top of the frame buffer, without some other device getting plopped on top of this range in the meantime. Recording this now allows that to be guaranteed. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 37 ++++++++++++++++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) commit be000f93e5d71f5d43dd722f8eb110b069f9d8a2 Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:54 2016 -0700 drivers:hv: Track allocations of children of hv_vmbus in private resource tree This patch changes vmbus_allocate_mmio() and vmbus_free_mmio() so that when child paravirtual devices allocate memory-mapped I/O space, they allocate it privately from a resource tree pointed at by hyperv_mmio and also by the public resource tree iomem_resource. This allows the region to be marked as "busy" in the private tree, but a "bridge window" in the public tree, guaranteeing that no two bridge windows will overlap each other but while also allowing the PCI device children of the bridge windows to overlap that window. One might conclude that this belongs in the pnp layer, rather than in this driver. Rafael Wysocki, the maintainter of the pnp layer, has previously asked that we not modify the pnp layer as it is considered deprecated. This patch is thus essentially a workaround. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) commit 23a0683186b7ca0083bfc76b410497f39a9d0351 Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:53 2016 -0700 drivers:hv: Reverse order of resources in hyperv_mmio A patch later in this series allocates child nodes in this resource tree. For that to work, this tree needs to be sorted in ascending order. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 696ca5e82c057a272381ae6064d59eb97a578397 Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:52 2016 -0700 drivers:hv: Use new vmbus_mmio_free() from client drivers. This patch modifies all the callers of vmbus_mmio_allocate() to call vmbus_mmio_free() instead of release_mem_region(). Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/pci/host/pci-hyperv.c | 14 +++++++------- drivers/video/fbdev/hyperv_fb.c | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) commit 97fb77dc87582300fa3c141b63699f853576cab1 Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:51 2016 -0700 drivers:hv: Make a function to free mmio regions through vmbus This patch introduces a function that reverses everything done by vmbus_allocate_mmio(). Existing code just called release_mem_region(). Future patches in this series require a more complex sequence of actions, so this function is introduced to wrap those actions. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 15 +++++++++++++++ include/linux/hyperv.h | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) commit e16dad6bfe1437aaee565f875a6713ca7ce81bdf Author: Jake Oshins <jakeo@microsoft.com> Date: Tue Apr 5 10:22:50 2016 -0700 drivers:hv: Lock access to hyperv_mmio resource tree In existing code, this tree of resources is created in single-threaded code and never modified after it is created, and thus needs no locking. This patch introduces a semaphore for tree access, as other patches in this series introduce run-time modifications of this resource tree which can happen on multiple threads. Signed-off-by: Jake Oshins <jakeo@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/vmbus_drv.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit ab028db41ca9174caab7f9e3fc0a2e7f4a418410 Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:51 2016 -0700 Drivers: hv: vmbus: Implement APIs to support "in place" consumption of vmbus packets Implement APIs for in-place consumption of vmbus packets. Currently, each packet is copied and processed one at a time and as part of processing each packet we potentially may signal the host (if it is waiting for room to produce a packet). These APIs help batched in-place processing of vmbus packets. We also optimize host signaling by having a separate API to signal the end of in-place consumption. With netvsc using these APIs, on an iperf run on average I see about 20X reduction in checks to signal the host. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 1 + include/linux/hyperv.h | 86 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 87 insertions(+) commit 687f32e6d9bd1d63c5e557e877809eb446f1a6e8 Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:50 2016 -0700 Drivers: hv: vmbus: Move some ring buffer functions to hyperv.h In preparation for implementing APIs for in-place consumption of VMBUS packets, movve some ring buffer functionality into hyperv.h Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 55 ------------------------------------------------ include/linux/hyperv.h | 54 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+), 55 deletions(-) commit 5cc472477f928fb8584eb8e08245c9cf9002d74a Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:49 2016 -0700 Drivers: hv: vmbus: Export the vmbus_set_event() API In preparation for moving some ring buffer functionality out of the vmbus driver, export the API for signaling the host. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/connection.c | 1 + drivers/hv/hyperv_vmbus.h | 2 -- include/linux/hyperv.h | 1 + 3 files changed, 2 insertions(+), 2 deletions(-) commit dcd0eeca4454d5c5a60aa3467581e0c6d7461b96 Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:48 2016 -0700 Drivers: hv: vmbus: Use the new virt_xx barrier code Use the virt_xx barriers that have been defined for use in virtual machines. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit d45faaeedb762a3965a0246cf831e55045dd6ef8 Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:47 2016 -0700 Drivers: hv: vmbus: Use READ_ONCE() to read variables that are volatile Use the READ_ONCE macro to access variabes that can change asynchronously. This is the recommended mechanism for dealing with "unsafe" compiler optimizations. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit a6341f000024cdf1ec14dc26743a409a17378db5 Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 17:59:46 2016 -0700 Drivers: hv: vmbus: Introduce functions for estimating room in the ring buffer Introduce separate functions for estimating how much can be read from and written to the ring buffer. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 25 ++++--------------------- include/linux/hyperv.h | 27 +++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 21 deletions(-) commit a389fcfd2cb57793931a9fb98fed076aae50bb6c Author: K. Y. Srinivasan <kys@microsoft.com> Date: Sat Apr 2 16:17:38 2016 -0700 Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read() On the consumer side, we have interrupt driven flow management of the producer. It is sufficient to base the signaling decision on the amount of space that is available to write after the read is complete. The current code samples the previous available space and uses this in making the signaling decision. This state can be stale and is unnecessary. Since the state can be stale, we end up not signaling the host (when we should) and this can result in a hang. Fix this problem by removing the unnecessary check. I would like to thank Arseney Romanenko <arseneyr@microsoft.com> for pointing out this issue. Also, issue a full memory barrier before making the signaling descision to correctly deal with potential reordering of the write (read index) followed by the read of pending_sz. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Tested-by: Dexuan Cui <decui@microsoft.com> Cc: <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/hv/ring_buffer.c | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) commit bbca503b2ee000b5743a49c4995316cc499f44c6 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Tue Apr 12 20:56:10 2016 +0530 parport: use subsys_initcall The drivers which depends on parport may sometimes try to iniitialize and register with parport bus even before parport has actually registered with the device layer. The simplest solution is to mark the init function as subsys_initcall() and load the parport before the other drivers loads. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/parport/procfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fee268767ce8bfdb5389b84cd02ba7837b5350d5 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Sat Mar 19 00:40:58 2016 +0530 misc: mic: Remove return statements from void functions Return statements at the end of void functions are useless. The Coccinelle semantic patch used to make this change is as follows: //<smpl> @@ identifier f; expression e; @@ void f(...) { <... - return e; ...> } //</smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mic/host/mic_boot.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 05c4569b7f74889ac206fcdc0ac50afa24aca0fc Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:47:42 2016 +0300 misc: mic: silence uninitialized variable warning My static checker complains that we still use "mark" even when the _scif_fence_mark() call fails so it can be uninitialized. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mic/scif/scif_fence.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9c88345e68922a72060317af2b5dc678915ab6d6 Author: Sudeep Dutt <sudeep.dutt@intel.com> Date: Mon Apr 4 21:32:30 2016 -0700 misc: mic: Fix randconfig build error Fixes randconfig build error reported at https://lkml.org/lkml/2016/4/3/135 by ensuring that the VOP driver selects VIRTIO. Reported-by: Fengguang Wu <fengguang.wu@intel.com> Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com> Signed-off-by: Sudeep Dutt <sudeep.dutt@intel.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mic/Kconfig | 1 + 1 file changed, 1 insertion(+) commit cb18d3a2f62ddb280e363f607ad0e20a01a6f63d Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:50:48 2016 -0500 MAINTAINERS: fsl-mc: Add second maintainer Add Stuart Yoder as additional maintainer of fsl-mc bus driver. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit e4234a1fc343ca35f852bc527fae56fade879d4a Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Mar 31 11:45:06 2016 +0100 kernfs: Move faulting copy_user operations outside of the mutex A fault in a user provided buffer may lead anywhere, and lockdep warns that we have a potential deadlock between the mm->mmap_sem and the kernfs file mutex: [ 82.811702] ====================================================== [ 82.811705] [ INFO: possible circular locking dependency detected ] [ 82.811709] 4.5.0-rc4-gfxbench+ #1 Not tainted [ 82.811711] ------------------------------------------------------- [ 82.811714] kms_setmode/5859 is trying to acquire lock: [ 82.811717] (&dev->struct_mutex){+.+.+.}, at: [<ffffffff8150d9c1>] drm_gem_mmap+0x1a1/0x270 [ 82.811731] but task is already holding lock: [ 82.811734] (&mm->mmap_sem){++++++}, at: [<ffffffff8117b364>] vm_mmap_pgoff+0x44/0xa0 [ 82.811745] which lock already depends on the new lock. [ 82.811749] the existing dependency chain (in reverse order) is: [ 82.811752] -> #3 (&mm->mmap_sem){++++++}: [ 82.811761] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0 [ 82.811766] [<ffffffff8118bc65>] __might_fault+0x75/0xa0 [ 82.811771] [<ffffffff8124da4a>] kernfs_fop_write+0x8a/0x180 [ 82.811787] [<ffffffff811d1023>] __vfs_write+0x23/0xe0 [ 82.811792] [<ffffffff811d1d74>] vfs_write+0xa4/0x190 [ 82.811797] [<ffffffff811d2c14>] SyS_write+0x44/0xb0 [ 82.811801] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73 [ 82.811807] -> #2 (s_active#6){++++.+}: [ 82.811814] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0 [ 82.811819] [<ffffffff8124c070>] __kernfs_remove+0x210/0x2f0 [ 82.811823] [<ffffffff8124d040>] kernfs_remove_by_name_ns+0x40/0xa0 [ 82.811828] [<ffffffff8124e9e0>] sysfs_remove_file_ns+0x10/0x20 [ 82.811832] [<ffffffff815318d4>] device_del+0x124/0x250 [ 82.811837] [<ffffffff81531a19>] device_unregister+0x19/0x60 [ 82.811841] [<ffffffff8153c051>] cpu_cache_sysfs_exit+0x51/0xb0 [ 82.811846] [<ffffffff8153c628>] cacheinfo_cpu_callback+0x38/0x70 [ 82.811851] [<ffffffff8109ae89>] notifier_call_chain+0x39/0xa0 [ 82.811856] [<ffffffff8109aef9>] __raw_notifier_call_chain+0x9/0x10 [ 82.811860] [<ffffffff810786de>] cpu_notify+0x1e/0x40 [ 82.811865] [<ffffffff81078779>] cpu_notify_nofail+0x9/0x20 [ 82.811869] [<ffffffff81078ac3>] _cpu_down+0x233/0x340 [ 82.811874] [<ffffffff81079019>] disable_nonboot_cpus+0xc9/0x350 [ 82.811878] [<ffffffff810d2e11>] suspend_devices_and_enter+0x5a1/0xb50 [ 82.811883] [<ffffffff810d3903>] pm_suspend+0x543/0x8d0 [ 82.811888] [<ffffffff810d1b77>] state_store+0x77/0xe0 [ 82.811892] [<ffffffff813fa68f>] kobj_attr_store+0xf/0x20 [ 82.811897] [<ffffffff8124e740>] sysfs_kf_write+0x40/0x50 [ 82.811902] [<ffffffff8124dafc>] kernfs_fop_write+0x13c/0x180 [ 82.811906] [<ffffffff811d1023>] __vfs_write+0x23/0xe0 [ 82.811910] [<ffffffff811d1d74>] vfs_write+0xa4/0x190 [ 82.811914] [<ffffffff811d2c14>] SyS_write+0x44/0xb0 [ 82.811918] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73 [ 82.811923] -> #1 (cpu_hotplug.lock){+.+.+.}: [ 82.811929] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0 [ 82.811933] [<ffffffff817b6f72>] mutex_lock_nested+0x62/0x3b0 [ 82.811940] [<ffffffff810784c1>] get_online_cpus+0x61/0x80 [ 82.811944] [<ffffffff811170eb>] stop_machine+0x1b/0xe0 [ 82.811949] [<ffffffffa0178edd>] gen8_ggtt_insert_entries__BKL+0x2d/0x30 [i915] [ 82.812009] [<ffffffffa017d3a6>] ggtt_bind_vma+0x46/0x70 [i915] [ 82.812045] [<ffffffffa017eb70>] i915_vma_bind+0x140/0x290 [i915] [ 82.812081] [<ffffffffa01862b9>] i915_gem_object_do_pin+0x899/0xb00 [i915] [ 82.812117] [<ffffffffa0186555>] i915_gem_object_pin+0x35/0x40 [i915] [ 82.812154] [<ffffffffa019a23e>] intel_init_pipe_control+0xbe/0x210 [i915] [ 82.812192] [<ffffffffa0197312>] intel_logical_rings_init+0xe2/0xde0 [i915] [ 82.812232] [<ffffffffa0186fe3>] i915_gem_init+0xf3/0x130 [i915] [ 82.812278] [<ffffffffa02097ed>] i915_driver_load+0xf2d/0x1770 [i915] [ 82.812318] [<ffffffff81512474>] drm_dev_register+0xa4/0xb0 [ 82.812323] [<ffffffff8151467e>] drm_get_pci_dev+0xce/0x1e0 [ 82.812328] [<ffffffffa01472cf>] i915_pci_probe+0x2f/0x50 [i915] [ 82.812360] [<ffffffff8143f907>] pci_device_probe+0x87/0xf0 [ 82.812366] [<ffffffff81535f89>] driver_probe_device+0x229/0x450 [ 82.812371] [<ffffffff81536233>] __driver_attach+0x83/0x90 [ 82.812375] [<ffffffff81533c61>] bus_for_each_dev+0x61/0xa0 [ 82.812380] [<ffffffff81535879>] driver_attach+0x19/0x20 [ 82.812384] [<ffffffff8153535f>] bus_add_driver+0x1ef/0x290 [ 82.812388] [<ffffffff81536e9b>] driver_register+0x5b/0xe0 [ 82.812393] [<ffffffff8143e83b>] __pci_register_driver+0x5b/0x60 [ 82.812398] [<ffffffff81514866>] drm_pci_init+0xd6/0x100 [ 82.812402] [<ffffffffa027c094>] 0xffffffffa027c094 [ 82.812406] [<ffffffff810003de>] do_one_initcall+0xae/0x1d0 [ 82.812412] [<ffffffff811595a0>] do_init_module+0x5b/0x1cb [ 82.812417] [<ffffffff81106160>] load_module+0x1c20/0x2480 [ 82.812422] [<ffffffff81106bae>] SyS_finit_module+0x7e/0xa0 [ 82.812428] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73 [ 82.812433] -> #0 (&dev->struct_mutex){+.+.+.}: [ 82.812439] [<ffffffff810cbe59>] __lock_acquire+0x1fc9/0x20f0 [ 82.812443] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0 [ 82.812456] [<ffffffff8150d9e7>] drm_gem_mmap+0x1c7/0x270 [ 82.812460] [<ffffffff81196a14>] mmap_region+0x334/0x580 [ 82.812466] [<ffffffff81196fc4>] do_mmap+0x364/0x410 [ 82.812470] [<ffffffff8117b38d>] vm_mmap_pgoff+0x6d/0xa0 [ 82.812474] [<ffffffff811950f4>] SyS_mmap_pgoff+0x184/0x220 [ 82.812479] [<ffffffff8100a0fd>] SyS_mmap+0x1d/0x20 [ 82.812484] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73 [ 82.812489] other info that might help us debug this: [ 82.812493] Chain exists of: &dev->struct_mutex --> s_active#6 --> &mm->mmap_sem [ 82.812502] Possible unsafe locking scenario: [ 82.812506] CPU0 CPU1 [ 82.812508] ---- ---- [ 82.812510] lock(&mm->mmap_sem); [ 82.812514] lock(s_active#6); [ 82.812519] lock(&mm->mmap_sem); [ 82.812522] lock(&dev->struct_mutex); [ 82.812526] *** DEADLOCK *** [ 82.812531] 1 lock held by kms_setmode/5859: [ 82.812533] #0: (&mm->mmap_sem){++++++}, at: [<ffffffff8117b364>] vm_mmap_pgoff+0x44/0xa0 [ 82.812541] stack backtrace: [ 82.812547] CPU: 0 PID: 5859 Comm: kms_setmode Not tainted 4.5.0-rc4-gfxbench+ #1 [ 82.812550] Hardware name: /NUC5CPYB, BIOS PYBSWCEL.86A.0040.2015.0814.1353 08/14/2015 [ 82.812553] 0000000000000000 ffff880079407bf0 ffffffff813f8505 ffffffff825fb270 [ 82.812560] ffffffff825c4190 ffff880079407c30 ffffffff810c84ac ffff880079407c90 [ 82.812566] ffff8800797ed328 ffff8800797ecb00 0000000000000001 ffff8800797ed350 [ 82.812573] Call Trace: [ 82.812578] [<ffffffff813f8505>] dump_stack+0x67/0x92 [ 82.812582] [<ffffffff810c84ac>] print_circular_bug+0x1fc/0x310 [ 82.812586] [<ffffffff810cbe59>] __lock_acquire+0x1fc9/0x20f0 [ 82.812590] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0 [ 82.812594] [<ffffffff8150d9c1>] ? drm_gem_mmap+0x1a1/0x270 [ 82.812599] [<ffffffff8150d9e7>] drm_gem_mmap+0x1c7/0x270 [ 82.812603] [<ffffffff8150d9c1>] ? drm_gem_mmap+0x1a1/0x270 [ 82.812608] [<ffffffff81196a14>] mmap_region+0x334/0x580 [ 82.812612] [<ffffffff81196fc4>] do_mmap+0x364/0x410 [ 82.812616] [<ffffffff8117b38d>] vm_mmap_pgoff+0x6d/0xa0 [ 82.812629] [<ffffffff811950f4>] SyS_mmap_pgoff+0x184/0x220 [ 82.812633] [<ffffffff8100a0fd>] SyS_mmap+0x1d/0x20 [ 82.812637] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73 Highly unlikely though this scenario is, we can avoid the issue entirely by moving the copy operation from out under the kernfs_get_active() tracking by assigning the preallocated buffer its own mutex. The temporary buffer allocation doesn't require mutex locking as it is entirely local. The locked section was extended by the addition of the preallocated buf to speed up md user operations in commit 2b75869bba676c248d8d25ae6d2bd9221dfffdb6 Author: NeilBrown <neilb@suse.de> Date: Mon Oct 13 16:41:28 2014 +1100 sysfs/kernfs: allow attributes to request write buffer be pre-allocated. Reported-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94350 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: NeilBrown <neilb@suse.de> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/kernfs/file.c | 51 ++++++++++++++++++++++++++++---------------------- include/linux/kernfs.h | 1 + 2 files changed, 30 insertions(+), 22 deletions(-) commit fa01e2ca9f531b4a5693469a196eb1574b8d7d8a Author: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> Date: Wed Apr 27 10:40:10 2016 +0200 serial: 8250: Integrate Fintek into 8250_base The 8250_fintek driver advertises as the PNP0501 driver; however this conflicts with the standard 16550A uart PNP0501. The conflict causes the 8250_fintek driver to load with _every_ PNP0501, but never probe, and causing the entire 8250 driver stack to unload if the 8250_fintek driver is unloaded (modprobe doesn't know that 8250_pnp rather than 8250_fintek claimed the resource). This patch merges the Fintek driver into 8250_base. On autoconfig_16550 the device is probed to verify if it is a FINTEK device or not. This custom probing can be disabled completely via configuration. When a Fintek device is not probed it will behave as a standard 16550A device, with no RS485 capabilities. Reported-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250.h | 6 ++ drivers/tty/serial/8250/8250_fintek.c | 118 +++++----------------------------- drivers/tty/serial/8250/8250_port.c | 7 ++ drivers/tty/serial/8250/Kconfig | 20 +++--- drivers/tty/serial/8250/Makefile | 2 +- 5 files changed, 42 insertions(+), 111 deletions(-) commit bd8d257fa3371a284568b8ee04c2bcf4757238ed Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:47:48 2016 +0100 serial: mps2-uart: add support for early console This adds support early console for MPS2 UART which can be enabled via earlycon=mps2,0x40004000 Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/Kconfig | 1 + drivers/tty/serial/mps2-uart.c | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+) commit 041f031def330582108bc37f97525d9e7c0e2b2f Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:47:47 2016 +0100 serial: mps2-uart: add MPS2 UART driver This driver adds support to the UART controller found on ARM MPS2 platform. Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/Kconfig | 12 + drivers/tty/serial/Makefile | 1 + drivers/tty/serial/mps2-uart.c | 597 +++++++++++++++++++++++++++++++++++++++ include/uapi/linux/serial_core.h | 3 + 4 files changed, 613 insertions(+) commit 8a872e770f86568bd45e90bbdce24dead4ee844d Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:47:46 2016 +0100 dt-bindings: document the MPS2 UART bindings This adds documentation of device tree bindings for the UART found on ARM MPS2 platform Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../devicetree/bindings/serial/arm,mps2-uart.txt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 7f60830ab1511d9449ac60ba4591fe3730445587 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:22:24 2016 +0200 serial: sirf: Use generic uart-has-rtscts DT property Convert the SiRF UART driver from using the vendor-specific "sirf,uart-has-rtscts" to the generic "uart-has-rtscts" DT property, as documented by the Generic Serial DT Bindings. The old vendor-specific property is still recognized by the driver for backwards compatibility, but deprecated. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/devicetree/bindings/serial/sirf-uart.txt | 8 ++++---- drivers/tty/serial/sirfsoc_uart.c | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) commit af99c187f167a9498fd548b81ec78890ef86c170 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:22:23 2016 +0200 serial: sirf: Introduce helper variable struct device_node *np Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/sirfsoc_uart.c | 38 ++++++++++++++++++-------------------- 1 file changed, 18 insertions(+), 20 deletions(-) commit 182cdcb8bb16e687dae9b03ac9ca9d80e873c076 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:22:22 2016 +0200 serial: mxs-auart: Use generic uart-has-rtscts DT property Convert the Freescale MXS AUART driver from using the vendor-specific "fsl,uart-has-rtscts" to the generic "uart-has-rtscts" DT property, as documented by the Generic Serial DT Bindings. The old vendor-specific property is still recognized by the driver for backwards compatibility, but it is deprecated. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/devicetree/bindings/serial/fsl-mxs-auart.txt | 2 +- drivers/tty/serial/mxs-auart.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) commit 1006ed7e1b258dac3e85c9fafe9d38b6020c917f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:22:21 2016 +0200 serial: imx: Use generic uart-has-rtscts DT property Convert the Freescale IMX UART driver from using the vendor-specific "fsl,uart-has-rtscts" to the generic "uart-has-rtscts" DT property, as documented by the Generic Serial DT Bindings. The old vendor-specific property is still recognized by the driver for backwards compatibility, but deprecated. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/devicetree/bindings/serial/fsl-imx-uart.txt | 4 ++-- drivers/tty/serial/imx.c | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) commit 8d21f24416719198c860009210a5fa9b33487211 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:22:20 2016 +0200 doc: DT: Add Generic Serial Device Tree Bindings Document a set of generic properties for describing UARTs in a device tree: 1. The GPIO modem control properties are currently duplicated across hardware-specific binding documentation, 2. The property for dedicated RTS/CTS hardware flow control lines is already supported by several drivers, albeit with a vendor-specific prefix, hence make it generic. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <rob@kernel.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../devicetree/bindings/serial/serial.txt | 57 ++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit 28264eb6c36e267aad0e6cfb353ad1e7920ac87b Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 14:47:24 2016 +0200 serial: 8250: of: Make tegra_serial_handle_break() static This function is not used outside the file, so it can be static. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_of.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d1f981506b38933e9ba4cfe01ae98bcd5d3792f9 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:37 2016 -0700 serial: omap8250: Terminate rx dma only for flushes DMA completed normally does not require termination; only terminate paused rx dma stemming from rx dma flush. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_omap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 33d9b8b23a73d5d8609a740d0adeea8235c2ae52 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:36 2016 -0700 serial: 8250: Extract IIR logic steering from rx dma Using fake IIR values to perform rx dma operations unnecessarily conflates separate operations, stopping in-progress dma with starting new dma. Introduce serial8250_rx_dma_flush() to handle stopping in-progress dma [omap8250 already has equivalent omap_8250_rx_dma_flush()]. Replace rx_dma(UART_IIR_RX_TIMEOUT) with the equivalent *_rx_dma_flush(), and rx_dma(0) with the equivalent *_rx_dma(). Handle IIR steering in the irq handler with handle_rx_dma() helper. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250.h | 8 +++-- drivers/tty/serial/8250/8250_dma.c | 32 +++++++----------- drivers/tty/serial/8250/8250_omap.c | 67 ++++++++++++++++--------------------- drivers/tty/serial/8250/8250_port.c | 14 +++++++- 4 files changed, 58 insertions(+), 63 deletions(-) commit b74fdd23d8fb4e349185ed9d963da8fc2b6eb34c Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:35 2016 -0700 serial: omap8250: Simplify rx dma completion interface Extract the operation (restarting new rx dma) performed when error argument is true. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_omap.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit ed183ee689058775b24021272c3a01d356fe8e2e Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:34 2016 -0700 serial: omap8250: Drop rx buffer sync commit 27c310c5c312 ("serial: 8250_dma: no need to sync RX buffer") notes the RX DMA buffer is allocated from DMA coherent memory, and thus does not need sync'd for each transaction. The same is true for OMAP RX DMA. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_omap.c | 6 ------ 1 file changed, 6 deletions(-) commit ddedfd82bc61c8d8d4d0eb754a9bcebb2e84de75 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:33 2016 -0700 serial: 8250: Validate dmaengine tx chan meets requirements 8250 dma support requires the dmaegine driver support terminate. Query slave caps to determine if necessary commands/properties are supported; disable dma if not. Note this means dmaengine driver must support slave caps reporting as well. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_dma.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit ec5a11a91eecd81ef19b8044a243b4ea56c809e6 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 22:14:32 2016 -0700 serial: 8250: Validate dmaengine rx chan meets requirements 8250 dma support requires the dmaengine driver support error-free pause/terminate and better-than-descriptor residue granularity. Query slave caps to determine if necessary commands/properties are supported; disable dma if not. Note this means dmaengine driver must support slave caps reporting as well. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_dma.c | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) commit 06c5e362ce1fbb29cb9505b4a1191d9489d8bdd2 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 14:48:05 2016 +0200 serial: tegra: Remove unused variable The local mcr variable is never used in the tegra_uart_set_mctrl() function, so it should be removed. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial-tegra.c | 2 -- 1 file changed, 2 deletions(-) commit 78bca84b95d65fb1407de418d0ed2203736dee1a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:29:16 2016 +0200 serial: Move Marvell UART DT bindings to correct location All other UART DT binding documentation is under Documentation/devicetree/bindings/serial/. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/devicetree/bindings/serial/mvebu-uart.txt | 13 +++++++++++++ Documentation/devicetree/bindings/tty/serial/mvebu-uart.txt | 13 ------------- 2 files changed, 13 insertions(+), 13 deletions(-) commit 973ea59e8c466c54b6d1f0a080f3efda418cdc18 Author: Maarten Brock <m.brock@vanmierlo.com> Date: Fri Apr 22 18:19:33 2016 +0200 serial-uartlite: Constify uartlite_be/uartlite_le Made uartlite_be and uartlite_le constants. Signed-off-by: Maarten Brock <m.brock@vanmierlo.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/uartlite.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 1681d2116c96d07b69bf2730271f3161153a6670 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 21 15:13:19 2016 +0900 serial: 8250_uniphier: add "\n" at the end of error log Just in case. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_uniphier.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fab794aeb60f5069a026fad8a4ff7c1cdf5b8713 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 13 09:44:31 2016 +0300 tty: hvc_console: silence unintialized variable warning If ->get_char() returns a negative error code and that can mean that "ch" is uninitialized. The callers of this function expect NO_POLL_CHAR on error so let's return that. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/hvc/hvc_console.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 423314337acde8ddda6324f0917b306642b3ef6c Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Wed Apr 6 11:44:04 2016 +0100 tty: synclink: remove unneeded test We reach this point of code after a test of 'info->port.tty->hw_stopped', we do not need to test for 'info->port.tty' as it is obvious that info->port.tty is not NULL now, we have already dereferenced it. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/synclink.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 76bbdcb35ebb0e9c5315c4b249cd883cca9e065d Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Wed Apr 6 12:25:39 2016 +0100 tty: ipwireless: fix possible NULL dereference The function alloc_ctrl_packet() can fail and return NULL. Incase it fails print an error message and exit. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Reviewed-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/ipwireless/hardware.c | 5 +++++ 1 file changed, 5 insertions(+) commit 9c5895057bfe5d033c65e15d13c7eee4a78cc837 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:49:44 2016 -0700 serial: 8250: Remove unused define HIGH_BITS_OFFSET is only used in the serial core; remove from 8250- specific header. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250.h | 1 - 1 file changed, 1 deletion(-) commit f56f0a54b013ae03a9f9b7701e2ce65aea674889 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:49:43 2016 -0700 serial: omap8250: Eliminate local in omap8250_runtime_resume() Eliminate 'loss_cntx' local variable. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_omap.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit d601744dc145a27945e97d643d2f5d298ab40627 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:49:42 2016 -0700 serial: 8250: Reduce expr in 8250 irq handler If !up->dma == F, then up->dma == T and can be elided from the (up->dma && up->dma->tx_err) sub-expression. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_port.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit a86f50ed35a8854f964393e60526c16744e2ed2c Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:49:41 2016 -0700 serial: 8250: Eliminate needless local in irq handlers dma_err is not used other than for boolean evaluation; substitute the actual operation directly. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_omap.c | 8 ++------ drivers/tty/serial/8250/8250_port.c | 6 +----- 2 files changed, 3 insertions(+), 11 deletions(-) commit ceeafb8e222f4ea73981ca0bf9f29882cb0c34b2 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon Apr 4 17:35:13 2016 +0300 serial: 8250_mid: correct comment regarding Tangier HSU On Intel Penwell and Tangier the HSU block (3 HSU ports) has a global register set which is currently not used by the driver. On Tangier it has it's own PCI device and thus available for enumeration. Since it's not a real HSU port we just skip it and therefore put a comment in the code why we do so. Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_mid.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 1fc969c759861ac491b6c93116aa497f774b00dc Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon Apr 4 17:35:12 2016 +0300 serial: 8250_mid: make module available only on X86 There is no reason to compile module on non-X86 platforms, though COMPILE_TEST is provided for sake of what it does. While here, set default to SERIAL_8250 that user doesn't need an explicit option to be set and hide it from non-expert. Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/Kconfig | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit dea5ac3ae44f46a4ce3558cb4f48fa7b0a598d46 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon Apr 4 17:35:11 2016 +0300 serial: 8250_mid: include missed linux/bitops.h The BIT() macro, that is definded in bitops.h, is used in the driver. Include necessary header for that. While here, reorder included headers alphabetically. Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_mid.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit c42850f1ae7e70056f852e67bb9dddf927853b47 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon Apr 4 17:35:10 2016 +0300 serial: 8250_mid: recognize interrupt source in handler There is a special register that shows interrupt status by source. In particular case the source can be a combination of DMA Tx, DMA Rx, and UART. Read the register and call the handlers only for sources that request an interrupt. Fixes: 6ede6dcd87aa ("serial: 8250_mid: add support for DMA engine handling from UART MMIO") Cc: stable@vger.kernel.org Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_mid.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit 107e15fc1f8d6ef69eac5f175971252f76e82f0d Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Mon Apr 4 17:35:09 2016 +0300 serial: 8250_mid: use proper bar for DNV platform Unlike Intel Medfield and Tangier platforms DNV uses PCI BAR0 for IO compatible resources and BAR1 for MMIO. We need latter in a way to support DMA. Introduce an additional field in the internal structure and pass PCI BAR based on device ID. Reported-by: "Lai, Poey Seng" <poey.seng.lai@intel.com> Fixes: 6ede6dcd87aa ("serial: 8250_mid: add support for DMA engine handling from UART MMIO") Cc: stable@vger.kernel.org Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_mid.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit c2684ed7d0e908e7c8dad7f199922d342ea55c66 Author: Wan Ahmad Zainie <wan.ahmad.zainie.wan.mohamad@intel.com> Date: Wed Apr 6 12:06:52 2016 +0800 serial: 8250_pci: report DCD and DSR signals as active for Bay Trail Bay Trail UART port does not support DCD and DSR lines. The driver shall report that these signals are permanently active. This patch is for HSUART enumerated via PCI. For ACPI, see commit dfd37668ea6d ("serial: 8250_dw: Fix get_mctrl behaviour"). The commit also describes the possible issue if these signals are enabled on a port without these pins. Signed-off-by: Wan Ahmad Zainie <wan.ahmad.zainie.wan.mohamad@intel.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_pci.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 144ef5c2df9b473dad7eab375adcf5b11d0b1e47 Author: Wan Ahmad Zainie <wan.ahmad.zainie.wan.mohamad@intel.com> Date: Wed Apr 6 12:06:51 2016 +0800 serial: 8250: export get_mctrl function Exposes get_mctrl() function so that it can be overriden with platform specific implementation. Signed-off-by: Wan Ahmad Zainie <wan.ahmad.zainie.wan.mohamad@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_core.c | 3 +++ drivers/tty/serial/8250/8250_port.c | 10 +++++++++- include/linux/serial_8250.h | 2 ++ include/linux/serial_core.h | 1 + 4 files changed, 15 insertions(+), 1 deletion(-) commit eeeabba024191c810b83592578cfc6183c4059fa Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:23:34 2016 +0200 TTY: serial/ifx6x60, initialize more In ifx_spi_complete, 'more' is not initialized. It is set only if the status is clear and only if the header is parsed OK. If any of those is not true, 'more' can be used uninitialized in that function later. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/ifx6x60.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 91e74ca5e7ac4ec6c61b84d6618eb5e401f852f0 Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:08:17 2016 +0200 tty: vt, use proper type for default colors Every user of default_red, default_grn, and default_blu treats them as unsigned char. So make it really unsigned char. And indent the initializers and module_param properly. This saves ~ 100 bytes of data. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 27 +++++++++++++++++---------- include/linux/selection.h | 6 +++--- 2 files changed, 20 insertions(+), 13 deletions(-) commit 8ede5cce4f0baff77ef63aa3cb3afc65d0317e0b Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:08:16 2016 +0200 tty: vt, make color_table const This means all ->con_set_palette have to have the second parameter const too now. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 2 +- drivers/usb/misc/sisusbvga/sisusb_con.c | 2 +- drivers/video/console/fbcon.c | 4 ++-- drivers/video/console/mdacon.c | 2 +- drivers/video/console/newport_con.c | 2 +- drivers/video/console/sticon.c | 2 +- drivers/video/console/vgacon.c | 5 ++--- include/linux/console.h | 2 +- include/linux/selection.h | 2 +- 9 files changed, 11 insertions(+), 12 deletions(-) commit 34902b7f2754e6d890feb0cee34187f1bc75c930 Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:08:15 2016 +0200 tty: vt, get rid of weird source code flow Some code in vc_allocate is indented by 4 spaces. It is inside a condition. Invert the condition and move the code to the first indentation level (using \tab). And insert some empty lines to have logical code blocks separated. Then, instead of freeing in an 'if' false branch, use goto-error label as fail path. Maybe better to look at this patch with diff -w -b. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 70 +++++++++++++++++++++++++++++------------------------ 1 file changed, 39 insertions(+), 31 deletions(-) commit 182846a00f489849c55d113954f0c4a8a286ca39 Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:08:14 2016 +0200 tty: vt, remove reduntant check MAX_NR_CONSOLES and MAX_NR_USER_CONSOLES are both 63 since they were introduced in 1.1.54. And since vc_allocate does: if (currcons >= MAX_NR_CONSOLES) return -ENXIO; if (!vc_cons[currcons].d) { if (currcons >= MAX_NR_USER_CONSOLES && !capable(CAP_SYS_RESOURCE)) return -EPERM; } the second check is pointless. Remove both the check and the macro MAX_NR_USER_CONSOLES. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Reported-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/vt/vt.c | 4 ---- include/uapi/linux/vt.h | 1 - 2 files changed, 5 deletions(-) commit b8995f527aac143e83d3900ff39357651ea4e0f6 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Apr 21 18:58:31 2016 +0900 serial: samsung: Reorder the sequence of clock control when call s3c24xx_serial_set_termios() This patch fixes the broken serial log when changing the clock source of uart device. Before disabling the original clock source, this patch enables the new clock source to protect the clock off state for a split second. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/samsung.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f5b556c94c8490d42fea79d7b4ae0ecbc291e69d Author: Matthias Schiffer <mschiffer@universe-factory.net> Date: Thu Mar 24 16:02:52 2016 +0100 MIPS: ath79: make bootconsole wait for both THRE and TEMT This makes the ath79 bootconsole behave the same way as the generic 8250 bootconsole. Also waiting for TEMT (transmit buffer is empty) instead of just THRE (transmit buffer is not full) ensures that all characters have been transmitted before the real serial driver starts reconfiguring the serial controller (which would sometimes result in garbage being transmitted.) This change does not cause a visible performance loss. In addition, this seems to fix a hang observed in certain configurations on many AR7xxx/AR9xxx SoCs during autoconfig of the real serial driver. A more complete follow-up patch will disable 8250 autoconfig for ath79 altogether (the serial controller is detected as a 16550A, which is not fully compatible with the ath79 serial, and the autoconfig may lead to undefined behavior on ath79.) Cc: <stable@vger.kernel.org> Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> arch/mips/ath79/early_printk.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 98952bf510d0c7cdfc284f098bbf4682dc47bc61 Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Fri Mar 25 14:35:49 2016 -0700 tty: serial: msm: Support more bauds The msm_find_best_baud() function is written with the assumption that the port->uartclk rate is fixed to a particular rate at boot time, but now this driver changes that clk rate at runtime when the baud is changed. The way the hardware works is that an input clk rate comes from the clk controller into the uart hw block. That rate is typically 1843200 or 3686400 Hz. That rate can then be divided by an internal divider in the hw block to achieve a particular baud on the serial wire. msm_find_best_baud() is looking for that divider value. A few things are wrong with the way the code is written. First, it assumes that the maximum baud that the uart can support if the clk rate is fixed at boot is 460800, which would correspond to an input clk rate of 230400 * 16 == 3686400 Hz. Except some devices have a boot rate of 1843200 Hz or max baud of 115200, so achieving 230400 on those devices doesn't work at all because we don't increase the clk rate unless max baud is 460800. Second, we can't achieve bauds higher than 460800 that require anything besides a divisor of 1, because we always call msm_find_best_baud() with a fixed port->uartclk rate that will eventually be changed after we calculate the divisor. So if we need to get a baud of 500000, we'll just multiply that by 16 and hope that the clk can give us 500000 * 16 == 8000000 Hz, which it typically can't do. To really achieve 500000 baud, we need to get an input clk rate of 24000000 Hz and then divide that by 3 inside the uart hardware. Finally, we return success for bauds even when we can't actually achieve them. This means that when the user asks for 500000 baud, we actually get 921600 right now, but the user doesn't know that. Fix all of this by searching through the divisor and clk rate space with a combination of clk_round_rate() and baud calculations, keeping track of the best clk rate and divisor we find if we can't get an exact match. Typically we can get an exact match with a divisor of 1, but sometimes we need to keep track and try more frequencies. On my msm8916 device, this results in all standard bauds in baud_table being supported except for 1800, 576000, 1152000, and 4000000. Fixes: 850b37a71bde ("tty: serial: msm: Remove 115.2 Kbps maximum baud rate limitation") Cc: "Ivan T. Ivanov" <iivanov.xz@gmail.com> Cc: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Andy Gross <andy.gross@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Tested-by: Cristian Prundeanu <cprundea@codeaurora.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/msm_serial.c | 99 +++++++++++++++++++++++++++-------------- 1 file changed, 66 insertions(+), 33 deletions(-) commit 27e16501052e5341934d3d327d580dc9a90f1212 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:25 2016 +0100 serial: imx: implement DSR irq handling for DTE mode Enable reporting of DSR events (which is named DTR in the registers because Freescale uses the names as seem from a DCE). Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) commit 66f95884928bd1b4114531b7a472601acf285130 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:24 2016 +0100 serial: imx: reorder functions to simplify next patch Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 98 ++++++++++++++++++++++++------------------------ 1 file changed, 49 insertions(+), 49 deletions(-) commit 9ec8efe94b5c6a797aa5bceca337373d310f9c2c Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:23 2016 +0100 serial: imx: only count 0->1 transitions for RNG According to tty_ioctl(4) (from man-pages 4.04) the rng member only counts 0->1 transitions. For the other signals (DSR, CD, CTS) both edges are supposed to be counted. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 16804d68bfaa7f5f5a73ab4a016ffeba33e87770 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:22 2016 +0100 serial: imx: make sure unhandled irqs are disabled Make sure that events that are not handled in the irq function don't trigger an interrupt. When the serial port is operated in DTE mode, the events for DCD and RI events are enabled after a system reset by default. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) commit 4d845a62b3f5672a813777b8dbebca0bad456bac Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:21 2016 +0100 serial: imx: let irq handler return IRQ_NONE if no event was handled This gives the irq core a chance to disable the serial interrupt in case an event isn't cleared in the handler. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit e881d3f3fafc849356ecd1e3a2f3bf669476ed2d Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu Mar 24 14:24:20 2016 +0100 serial: imx: fix polarity of RI When in DTE mode, the bit USR2_RIIN is active low. So invert the logic accordingly. Fixes: 90ebc4838666 ("serial: imx: repair and complete handshaking") Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 06ed48b7ee0c1b3c1dee6f2c90333109cf7db6ac Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Mon Apr 18 16:55:37 2016 +0200 TTY: add __init attribute Add __init attribute on a function that is only called from other __init functions and that is not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the function is put in the .text.unlikely segment. Declaring it as __init will cause it to be put in the .init.text and to disappear after initialization. The result of objdump -x on the function before the change is as follows: 000000000000014c l F .text.unlikely 0000000000000a2e init_r_port And after the change it is as follows: 0000000000000000 l F .init.text 0000000000000a29 init_r_port Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/rocket.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 254da0d753fbebb6f4604bc266acd5f4c84bf6f5 Author: Oleksij Rempel <linux@rempel-privat.de> Date: Wed Mar 16 14:05:52 2016 +0100 serial: mxs-auart: add Alphascale ASM9260 support Alphascale ASM9260 uart IP has some common registers with Freescale STMP37XX. This patch provide changes which allow to reuse mxs-auart.c code for ASM9260. Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../devicetree/bindings/serial/fsl-mxs-auart.txt | 14 +- drivers/tty/serial/Kconfig | 5 +- drivers/tty/serial/mxs-auart.c | 641 +++++++++++++++++---- 3 files changed, 531 insertions(+), 129 deletions(-) commit e69ef01ff0580b106e5b93a09c0c3fcd01fdb84f Author: Wills Wang <wills.wang@live.com> Date: Sat Mar 5 22:09:05 2016 +0800 sc16is7xx: remove useless "uart_handle_cts_change" SC16is7xx has feature for auto hardware flow control using RTS/CTS, so we don't need "uart_handle_cts_change" to invoke "start_tx/stop_tx" for flow control. In addition, for software CTS, interrupt "SC16IS7XX_IIR_CTSRTS_SRC" just report the nCTS change of state from active(low) to inactive(high), driver don't know when the state of nCTS change from incactive to active, so can't resume the transmission when a peer device is again ready and re-assert nRTS signal. Signed-off-by: Wills Wang <wills.wang@live.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/sc16is7xx.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit 03e970bba4376f7de9d1c97f2c830fac0b4e5a08 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 12:01:32 2016 +0200 serial: mctrl_gpio: Grammar s/lines GPIOs/line GPIOs/, /sets/set/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_mctrl_gpio.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7d1cadca957d3c586fe71054ed843565013236d9 Author: Baruch Siach <baruch@tkos.co.il> Date: Mon Feb 29 14:34:10 2016 +0200 serial: imx: support RS-485 Rx disable on Tx Some RS-232 to RS-485 transceivers require Rx to be disabled on Tx to avoid echo of Tx data into the Rx buffer. Specifically, the XR3160E RS-232/RS-485/RS-422 transceiver behaves this way. This commit disables Rx on active Tx when SER_RS485_ENABLED is active and SER_RS485_RX_DURING_TX is disabled. Note that this is a change in behavior of the driver. Until now SER_RS485_RX_DURING_TX was enabled unconditionally even when disabled in the TIOCSRS485 ioctl serial_rs485 flags field. Cc: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/imx.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 3d23b4c364e6fca720bf68655248c16c498e36f3 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Fri Mar 18 13:45:51 2016 +0100 serial: Make SERIAL_MVEBU_UART depend on ARCH_MVEBU Enabling support for the UART on Marvell EBU SoCs only make sense when compiling for Marvell EBU SoCs, unless compile-testing. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 89ebc27427695bfc1e769f1dd99bd243d332ac7a Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 13 19:48:52 2016 -0400 drivers/tty: make serial/mvebu-uart.c explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/tty/serial/Kconfig:config SERIAL_MVEBU_UART drivers/tty/serial/Kconfig: bool "Marvell EBU serial port support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. We explicitly disallow a driver unbind, since that doesn't have a sensible use case anyway, and it allows us to drop the ".remove" code for non-modular drivers. Since the code wasn't using module_init to begin with, the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Wilson Ding <dingwei@marvell.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jiri Slaby <jslaby@suse.com> Cc: linux-serial@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/mvebu-uart.c | 28 +++------------------------- 1 file changed, 3 insertions(+), 25 deletions(-) commit e31efceed2bf4a0a911bfe53d84098bec7085abe Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sun Mar 6 12:20:12 2016 +0900 serial: mvebu-uart: fix platform_no_drv_owner.cocci warnings No need to set .owner here. The core will do it. Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci CC: Wilson Ding <dingwei@marvell.com> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/mvebu-uart.c | 1 - 1 file changed, 1 deletion(-) commit 736d553886a72274e58ff8a0e8a2899978042b8f Author: Andreas Färber <afaerber@suse.de> Date: Sun Mar 6 12:21:24 2016 +0100 tty: serial: meson: Implement earlycon support Split off the bulk of the existing meson_serial_console_write() implementation into meson_serial_port_write() for implementing meson_serial_early_console_write(). Use "meson" as the earlycon driver name, courtesy of Nicolas. Signed-off-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Acked-by: Carlo Caione <carlo@endlessm.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/kernel-parameters.txt | 6 ++++++ drivers/tty/serial/Kconfig | 1 + drivers/tty/serial/meson_uart.c | 42 ++++++++++++++++++++++++++++++------- 3 files changed, 42 insertions(+), 7 deletions(-) commit 79c9473f115f99906b6ae443708b8ece480e2e88 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Mon Mar 7 02:46:40 2016 +0000 tty: msm_serial: remove static clk rate setting in probe The issue with setting up a fixed clock rate at probe is that it would overwrite the console rate set by the bootloader for its console device. This would result in serial out corruption or missing log when we system is booted with earlycon. This is not a issue if we boot system without earlycon. This setup is at least not required with the mainline driver, this code used to be required because the clk_enable() call would fail if clk_set_rate() wasn't called first. Originally the issue was noticed on DB410c which is based on APQ8016 chipset. Without this patch the console log with earlycon would look like: ... [ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=64, nr_cpu_ids=1 [ 0.000000] NR_IRQS:64 nr_irqs:64 0 ����+HH��0.699378] console [ttyMSM0] enabled [ 0.699378] console [ttyMSM0] enabled [ 0.702003] bootconsole [uart0] disabled [ 0.702003] bootconsole [uart0] disabled ... with this patch I can see all the skipped lines on the console Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Andy Gross <andy.gross@linaro.org> Tested-by: Pramod Gurav <gpramod@codeaurora.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/msm_serial.c | 2 -- 1 file changed, 2 deletions(-) commit 25f3ecc28b431d6befcea0a4bafe8fe74c5a3988 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:36:39 2016 -0700 tty: Remove stale parameter comment noctty was removed as a parameter by commit 11e1d4aa4da ("tty: Consolidate noctty check in tty_open()"). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/tty_io.c | 1 - 1 file changed, 1 deletion(-) commit 0f0380b6177ab628b9e7c5a566dcdb3889e38dcb Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 20:36:38 2016 -0700 tty: Remove unused TTY_NUMBER() macro TTY_NUMBER() has been unused since v2.5.71; removed by "[PATCH] callout removal: callout is gone". Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/tty_io.c | 3 --- 1 file changed, 3 deletions(-) commit af224ca2df297440448b9d407d21b50982c6d532 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 18:56:35 2016 -0700 serial: core: Prevent unsafe uart port access, part 3 For tty operations which may expect uart port to have been removed but still have other necessary work to accomplish, check for NULL uart port; specifically uart_close(), uart_hangup() and sub-functions (uart_shutdown() and uart_port_shutdown()). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_core.c | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) commit 9ed19428a51d53477e2b79be3303fa08f8575749 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 18:56:34 2016 -0700 serial: core: Prevent unsafe uart port access, part 2 For serial core operations not already excluded by holding port->mutex, use reference counting to protect deferencing the state->uart_port. Introduce helper functions, uart_port_ref() and uart_port_deref(), to wrap uart_port access, and helper macros, uart_port_lock() and uart_port_unlock(), to wrap combination uart_port access with uart port lock sections. Port removal in uart_remove_one_port() waits for reference count to drop to zero before detaching the uart port from struct uart_state. For functions only reading the tx circular buffer indexes (where the uart port lock is claimed to prevent concurrent users), a NULL uart port is simply ignored and the operation completes normally. For functions change the tx circular buffer indexes (where the uart port lock is claimed to prevent concurrent users), the operation is aborted if the uart port is NULL (ie., has been detached). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_core.c | 171 +++++++++++++++++++++++++++++---------- include/linux/serial_core.h | 2 + 2 files changed, 130 insertions(+), 43 deletions(-) commit 4047b37122d1be8dd8e8c504f6f596930b660188 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 18:56:33 2016 -0700 serial: core: Prevent unsafe uart port access, part 1 uart_remove_one_port() may race with every serial core operation requiring a valid dereference of state->uart_port. In particular, uart_remove_one_port() may unlink the uart port concurrently with any serial core operation that may dereference same. Ensure safe dereference for those operations that already claim the port->mutex, and extend that guarantee for trivial cases, such as the ioctl handlers. Introduce the uart_port_check() helper which asserts port->mutex is held (only when lockdep is on). For ioctls, return -EIO as if the port has been hung up (since it has). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_core.c | 157 ++++++++++++++++++++++++++------------- 1 file changed, 104 insertions(+), 53 deletions(-) commit 49c02304fe97f88ee65f92368fe3f473201a7976 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 18:56:32 2016 -0700 serial: core: Expand port mutex section in uart_poll_init() Prepare uart_poll_init() to safely dereference uart port; expand the port mutex section to guarantee uart port remains valid until uart_poll_init() completes. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/serial_core.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit 5c0517fefc92d636e409141ed75c29c3f1969107 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:27 2016 -0700 tty: core: Undefine ASYNC_* flags superceded by TTY_PORT* flags Purposefully break out-of-tree driver compiles using kernel ASYNC_* bits which have been superceded by TTY_PORT* flags and their respective helper functions. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/uapi/linux/tty_flags.h | 4 ++++ 1 file changed, 4 insertions(+) commit 03fe27675e498796f9e7c9b500d667000928bc1c Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:26 2016 -0700 tty: mxser: Remove unused ASYNC_SHARE_IRQ flag ASYNC*_SHARE_IRQ is no longer used; remove. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/mxser.c | 1 - 1 file changed, 1 deletion(-) commit d41861ca19c9e96f12a4f1ebbc8255d00909a232 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:25 2016 -0700 tty: Replace ASYNC_INITIALIZED bit and update atomically Replace ASYNC_INITIALIZED bit in the tty_port::flags field with TTY_PORT_INITIALIZED bit in the tty_port::iflags field. Introduce helpers tty_port_set_initialized() and tty_port_initialized() to abstract atomic bit ops. Note: the transforms for test_and_set_bit() and test_and_clear_bit() are unnecessary as the state transitions are already mutually exclusive; the tty lock prevents concurrent open/close/hangup. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/pcmcia/synclink_cs.c | 12 +++++----- drivers/ipack/devices/ipoctal.c | 5 ++--- drivers/isdn/i4l/isdn_tty.c | 10 ++++----- drivers/s390/char/con3215.c | 12 +++++----- drivers/tty/amiserial.c | 14 ++++++------ drivers/tty/cyclades.c | 14 ++++++------ drivers/tty/isicom.c | 6 ++--- drivers/tty/moxa.c | 10 ++++----- drivers/tty/mxser.c | 14 +++++------- drivers/tty/n_gsm.c | 8 +++---- drivers/tty/rocket.c | 10 ++++----- drivers/tty/serial/crisv10.c | 17 +++++++------- drivers/tty/serial/serial_core.c | 24 +++++++++++--------- drivers/tty/synclink.c | 46 ++++++++++++++++++-------------------- drivers/tty/synclink_gt.c | 16 ++++++------- drivers/tty/synclinkmp.c | 16 ++++++------- drivers/tty/tty_port.c | 13 ++++++----- drivers/usb/class/cdc-acm.c | 4 ++-- drivers/usb/serial/console.c | 4 ++-- drivers/usb/serial/generic.c | 6 ++--- drivers/usb/serial/mxuport.c | 6 ++--- drivers/usb/serial/sierra.c | 4 ++-- drivers/usb/serial/usb-serial.c | 2 +- drivers/usb/serial/usb_wwan.c | 4 ++-- include/linux/tty.h | 13 +++++++++++ net/irda/ircomm/ircomm_tty.c | 15 +++++++------ net/irda/ircomm/ircomm_tty_ioctl.c | 2 +- 27 files changed, 157 insertions(+), 150 deletions(-) commit 80f02d5424301bf4df195d09b1a664f394435851 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:24 2016 -0700 tty: Replace ASYNC_SUSPENDED bit and update atomically Replace ASYNC_SUSPENDED bit in the tty_port::flags field with TTY_PORT_SUSPENDED bit in the tty_port::iflags field. Introduce helpers tty_port_set_suspended() and tty_port_suspended() to abstract atomic bit ops. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/s390/char/con3215.c | 12 ++++++------ drivers/tty/serial/serial_core.c | 8 ++++---- include/linux/tty.h | 13 +++++++++++++ 3 files changed, 23 insertions(+), 10 deletions(-) commit 2d68655d15bc99981394f7caa769a14b03cac131 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:23 2016 -0700 tty: Replace ASYNC_CHECK_CD and update atomically Replace ASYNC_CHECK_CD bit in the tty_port::flags field with TTY_PORT_CHECK_CD bit in the tty_port::iflags field. Introduce helpers tty_port_set_check_carrier() and tty_port_check_carrier() to abstract the atomic bit ops. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/pcmcia/synclink_cs.c | 8 ++------ drivers/isdn/i4l/isdn_tty.c | 8 ++------ drivers/tty/amiserial.c | 9 +++------ drivers/tty/cyclades.c | 14 ++++---------- drivers/tty/isicom.c | 7 ++----- drivers/tty/mxser.c | 9 +++------ drivers/tty/synclink.c | 8 ++------ drivers/tty/synclink_gt.c | 8 ++------ drivers/tty/synclinkmp.c | 8 ++------ include/linux/tty.h | 13 +++++++++++++ net/irda/ircomm/ircomm_tty.c | 4 ++-- net/irda/ircomm/ircomm_tty_attach.c | 2 +- net/irda/ircomm/ircomm_tty_ioctl.c | 5 +---- 13 files changed, 39 insertions(+), 64 deletions(-) commit 807c8d81f4ec441241cafa3034c58df721fee869 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:22 2016 -0700 tty: Replace ASYNC_NORMAL_ACTIVE bit and update atomically Replace ASYNC_NORMAL_ACTIVE bit in the tty_port::flags field with TTY_PORT_ACTIVE bit in the tty_port::iflags field. Introduce helpers tty_port_set_active() and tty_port_active() to abstract atomic bit ops. Extract state changes from port lock sections, as this usage is broken and confused; the state transitions are protected by the tty lock (which mutually excludes parallel open/close/hangup), and no user tests the active state while holding the port lock. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/isdn/i4l/isdn_tty.c | 20 +++++++++----------- drivers/tty/amiserial.c | 2 +- drivers/tty/rocket.c | 5 +++-- drivers/tty/serial/crisv10.c | 8 ++++---- drivers/tty/serial/serial_core.c | 8 ++++---- drivers/tty/synclink.c | 6 +++--- drivers/tty/synclink_gt.c | 6 +++--- drivers/tty/synclinkmp.c | 6 +++--- drivers/tty/tty_port.c | 12 ++++++------ include/linux/tty.h | 12 ++++++++++++ net/irda/ircomm/ircomm_tty.c | 10 +++++----- 11 files changed, 53 insertions(+), 42 deletions(-) commit 5604a98e2f95d6221852960a3363588f40d78e22 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:21 2016 -0700 tty: Replace ASYNC_CTS_FLOW bit and update atomically Replace ASYNC_CTS_FLOW bit in the tty_port::flags field with TTY_PORT_CTS_FLOW bit in the tty_port::iflags field. Add tty_port_set_cts_flow() helper to abstract the atomic bit ops. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/pcmcia/synclink_cs.c | 5 +---- drivers/tty/amiserial.c | 6 ++---- drivers/tty/cyclades.c | 10 ++++------ drivers/tty/isicom.c | 6 ++---- drivers/tty/mxser.c | 4 +--- drivers/tty/synclink.c | 7 ++----- drivers/tty/synclink_gt.c | 5 +---- drivers/tty/synclinkmp.c | 5 +---- include/linux/tty.h | 12 ++++++++++-- net/irda/ircomm/ircomm_tty_ioctl.c | 3 +-- 10 files changed, 25 insertions(+), 38 deletions(-) commit e4d38f334ad24f80229a8ebab26950de8e8f34d7 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:53:20 2016 -0700 tty: Define ASYNC_ replacement bits Prepare for relocating kernel private state bits out of tty_port::flags field; tty_port::flags field is not atomic and can become corrupted by concurrent updates. It also suffers from the complication of sharing in a userspace-visible field which must be masked. Define new tty_port::iflags field and new, substitute bit definitions for the former ASYNC_* flags. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/tty.h | 16 +++++++++++++++- include/uapi/linux/tty_flags.h | 9 ++++++++- 2 files changed, 23 insertions(+), 2 deletions(-) commit 97ef38b8210d7459d4cb51668cdf3983772ac6b7 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:11:36 2016 -0700 tty: Replace TTY_THROTTLED bit tests with tty_throttled() Abstract TTY_THROTTLED bit tests with tty_throttled(). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/char/pcmcia/synclink_cs.c | 2 +- drivers/mmc/card/sdio_uart.c | 2 +- drivers/net/usb/hso.c | 2 +- drivers/staging/fwserial/fwserial.c | 2 +- drivers/staging/speakup/selection.c | 2 +- drivers/tty/amiserial.c | 2 +- drivers/tty/hvc/hvc_console.c | 2 +- drivers/tty/hvc/hvcs.c | 2 +- drivers/tty/hvc/hvsi.c | 2 +- drivers/tty/moxa.c | 2 +- drivers/tty/nozomi.c | 2 +- drivers/tty/serial/serial_core.c | 2 +- drivers/tty/synclink.c | 2 +- drivers/tty/synclink_gt.c | 2 +- drivers/tty/synclinkmp.c | 2 +- drivers/tty/tty_ioctl.c | 4 ++-- drivers/tty/vt/selection.c | 2 +- drivers/usb/gadget/function/u_serial.c | 4 ++-- drivers/usb/serial/digi_acceleport.c | 3 +-- include/linux/tty.h | 5 +++++ net/irda/ircomm/ircomm_tty_ioctl.c | 2 +- 21 files changed, 27 insertions(+), 23 deletions(-) commit 18900ca65a8553edc608b6c9d518eb31e6c09ba1 Author: Peter Hurley <peter@hurleysoftware.com> Date: Sat Apr 9 17:06:48 2016 -0700 tty: Replace TTY_IO_ERROR bit tests with tty_io_error() Abstract TTY_IO_ERROR status test treewide with tty_io_error(). NB: tty->flags uses atomic bit ops; replace non-atomic bit test with test_bit(). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> arch/ia64/hp/sim/simserial.c | 2 +- drivers/char/pcmcia/synclink_cs.c | 2 +- drivers/isdn/i4l/isdn_tty.c | 6 +++--- drivers/s390/char/tty3270.c | 4 ++-- drivers/staging/dgnc/dgnc_tty.c | 2 +- drivers/tty/amiserial.c | 6 +++--- drivers/tty/mxser.c | 7 +++---- drivers/tty/pty.c | 2 +- drivers/tty/serial/crisv10.c | 5 ++--- drivers/tty/serial/serial_core.c | 8 ++++---- drivers/tty/synclink.c | 4 ++-- drivers/tty/synclink_gt.c | 4 ++-- drivers/tty/synclinkmp.c | 4 ++-- drivers/tty/tty_io.c | 5 ++--- drivers/tty/tty_port.c | 2 +- include/linux/tty.h | 5 +++++ net/irda/ircomm/ircomm_tty.c | 2 +- net/irda/ircomm/ircomm_tty_ioctl.c | 6 +++--- 18 files changed, 39 insertions(+), 37 deletions(-) commit 1aabf523a288b09d660992c22e307110c70f746d Author: Christopher Covington <cov@codeaurora.org> Date: Fri Apr 1 17:23:58 2016 -0400 tty: amba-pl011: Use 32-bit accesses for SBSA UART Version 2 of the Server Base System Architecture (SBSAv2) describes UART hardware registers as 32 bits wide, giving no guidance on access sizes. The SBSA UART driver previously assumed partial-length 16 and 8 bit accesses would work. But the SBSAv2 UART hardware on the Qualcomm Technologies QDF2432 only supports full-length 32 bit register accesses, so use those exclusively. This is compatible with SBSAv3, which explicitly requires UART hardware support 32 (and 16 and sometimes 8) bit accesses. Tested on Juno, Midway, QDF2432, Seattle, and X-Gene 1. Tested-by: Mark Langsdorf <mlangsdo@redhat.com> Tested-by: Andre Przywara <andre.przywara@arm.com> Acked-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Christopher Covington <cov@codeaurora.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/amba-pl011.c | 1 + 1 file changed, 1 insertion(+) commit 71f5c63c07e5be7abdce40891778ffbf3cec04f0 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Mar 23 12:09:18 2016 +0100 phy: exynos-mipi-video: Add support for Exynos 5420 and 5433 SoCs This patch adds support for MIPI DPHYs found in Exynos5420-compatible (5420, 5422 and 5800) and Exynos5433 SoCs. Those SoCs differs from earlier by different offset of MIPI DPHY registers in PMU controllers (Exynos 5420-compatible case) or by moving MIPI DPHY reset registers to separate system register controllers (Exynos 5433 case). In both case also additional 5th PHY (MIPI CSIS 2) has been added. Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> .../devicetree/bindings/phy/samsung-phy.txt | 18 ++- drivers/phy/phy-exynos-mipi-video.c | 129 ++++++++++++++++++++- include/linux/mfd/syscon/exynos5-pmu.h | 3 + 3 files changed, 147 insertions(+), 3 deletions(-) commit 97a3042f76164330f7ac5dbe7434f63f92d6f09d Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Mar 23 12:09:17 2016 +0100 phy: exynos-mipi-video: Rewrite handling of phy registers Controlling Exynos MIPI DPHY is done by handling 2 registers: one for phy reset and one for enabling it. This patch moves definitions of those 2 registers to speparate exynos_mipi_phy_desc structure, which can be defined separately for each PHY for each supported hardware variant. This code rewrite is needed to add support for newer Exynos SoCs, which have MIPI PHY related registers at different offsets or even different register regions. Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-exynos-mipi-video.c | 165 ++++++++++++++++++++++++++++-------- 1 file changed, 130 insertions(+), 35 deletions(-) commit 26dbadba495fa69b041a7f1ceaa8c48c26178e34 Author: Sylwester Nawrocki <s.nawrocki@samsung.com> Date: Wed Mar 23 12:09:16 2016 +0100 phy: exynos-mipi-video: Drop support for direct access to PMU There is no need to support access to the PMU through memory ioresource as now access through PMU regmap should only be used. Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-exynos-mipi-video.c | 57 +++++++++---------------------------- 1 file changed, 13 insertions(+), 44 deletions(-) commit d3feb406733544dbf0e239ef945a09decdceac88 Author: Rafał Miłecki <zajec5@gmail.com> Date: Thu Apr 14 11:37:43 2016 +0200 phy: bcm-ns-usb2: new driver for USB 2.0 PHY on Northstar Northstar is a family of SoCs used in home routers. They have USB 2.0 and 3.0 controllers with PHYs that need to be properly initialized. This driver provides PHY init support in a generic way and can be bound with an EHCI controller driver. There are (just a few) registers being defined in bcma header. It's because DMU/CRU registers will be also needed in other drivers. We will need them e.g. in PCIe controller/PHY driver and at some point probably in clock driver for BCM53573 chipset. By using include/linux/bcma/ we avoid code duplication. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> .../devicetree/bindings/phy/bcm-ns-usb2-phy.txt | 21 ++++ drivers/phy/Kconfig | 9 ++ drivers/phy/Makefile | 1 + drivers/phy/phy-bcm-ns-usb2.c | 137 +++++++++++++++++++++ include/linux/bcma/bcma.h | 1 + include/linux/bcma/bcma_driver_arm_c9.h | 15 +++ 6 files changed, 184 insertions(+) commit 444525d4f5dd272f695379f5d22660c96ad4fc23 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:17:26 2016 -0700 phy: rockhip-usb: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-rockchip-usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e1d76530d7f8f67d0b2a020a2453bed4e8e27b1a Author: Chunfeng Yun <chunfeng.yun@mediatek.com> Date: Wed Apr 20 08:14:02 2016 +0800 phy: phy-mt65xx-usb3: add support for mt2701 platform Add a new OF device ID for mt2701 Some register settings to avoid RX sensitivity level degradation which may arise on mt8173 platform are separated from other platforms. Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/Kconfig | 5 ++- drivers/phy/phy-mt65xx-usb3.c | 77 +++++++++++++++++++++++++++++-------------- 2 files changed, 54 insertions(+), 28 deletions(-) commit 931b119e9432f48e2b384e4d59c33490c5567353 Author: Chunfeng Yun <chunfeng.yun@mediatek.com> Date: Wed Apr 20 08:14:01 2016 +0800 dt-bindings: phy-mt65xx-usb: add support for mt2701 platform Add a new compatible string for "mt2701" Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Documentation/devicetree/bindings/phy/phy-mt65xx-usb.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 2b38543c8db1c7dff48aa767fcbfba13f50514ca Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Fri Apr 29 14:22:25 2016 +0530 phy: rcar-gen3-usb2: add extcon support This patch adds extcon support for otg related channel. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Reviewed-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/Kconfig | 1 + drivers/phy/phy-rcar-gen3-usb2.c | 26 ++++++++++++++++++++++++++ 2 files changed, 27 insertions(+) commit 6dcfd7c300bf3588d4f2500e14d90ffea5595e84 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Thu Mar 3 19:09:05 2016 +0900 phy: rcar-gen3-usb2: Add vbus-supply to handle VBUS on/off To handle the VBUS on/off by a regulator driver, this patch adds regulator APIs calling in the driver and description about vbus-supply in the rcar-gen3-phy-usb2.txt. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> .../devicetree/bindings/phy/rcar-gen3-phy-usb2.txt | 2 ++ drivers/phy/phy-rcar-gen3-usb2.c | 28 ++++++++++++++++++++++ 2 files changed, 30 insertions(+) commit 801a69c787812f987f38feb2f54782bcf2a4a007 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Thu Mar 3 19:09:04 2016 +0900 phy: rcar-gen3-usb2: remove unnecesary struct rcar_gen3_data Since this driver uses the struct rcar_gen3_data in struct rcar_gen3_chan only, we can remove the rcar_gen3_data. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/phy-rcar-gen3-usb2.c | 33 ++++++++++++++------------------- 1 file changed, 14 insertions(+), 19 deletions(-) commit 2bcdf18189632fb67d10d8e5b07fba36ad594227 Author: Anup Patel <anup.patel@broadcom.com> Date: Mon Mar 28 10:18:28 2016 +0530 dt-bindings: phy: bindings document for common Broadcom SATA3 PHY driver This patch: 1. Renames DT bindings document of Broadcom STB SATA3 PHY driver to common Broadcom SATA3 PHY driver bindings document 2. Adds bindings info for NS2 SATA3 PHY Signed-off-by: Anup Patel <anup.patel@broadcom.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> .../bindings/phy/brcm,brcmstb-sata-phy.txt | 41 -------------------- .../devicetree/bindings/phy/brcm-sata-phy.txt | 44 ++++++++++++++++++++++ 2 files changed, 44 insertions(+), 41 deletions(-) commit 4faee9a43d0af2943195cdbde93c59d03984b749 Author: Anup Patel <anup.patel@broadcom.com> Date: Mon Mar 28 10:18:27 2016 +0530 phy: Add support for NS2 SATA3 PHY in Broadcom SATA3 PHY driver This patch adds support for Broadcom NS2 SATA3 PHY in existing Broadcom SATA3 PHY driver. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/Kconfig | 19 ++-- drivers/phy/Makefile | 2 +- drivers/phy/phy-brcm-sata.c | 238 +++++++++++++++++++++++++++++++++++++------- 3 files changed, 211 insertions(+), 48 deletions(-) commit eb026024c24bbeb18e08d973e950f76c0d97a3c0 Author: Edward O'Callaghan <eocallaghan@alterapraxis.com> Date: Sun May 1 00:06:29 2016 +1000 amdkfd: Trim unnescessary intermediate err var in kfd_chardev.c Found-By: Coccinelle Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 371d5b653f2005267cc482477bcab21cd155aacf Author: Edward O'Callaghan <eocallaghan@alterapraxis.com> Date: Sun May 1 00:06:28 2016 +1000 amdkfd: Trim off unnescessary semicolon from kfd_packet_manager.c Found-By: Coccinelle Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> drivers/gpu/drm/amd/amdkfd/kfd_packet_manager.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 991ca8eee2c13e39b8c53def35249ff9cb4e93fe Author: Edward O'Callaghan <eocallaghan@alterapraxis.com> Date: Sun May 1 00:06:27 2016 +1000 amdkfd: Use the canonical form in branch predicates Found-By: Coccinelle Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c | 10 +++++----- drivers/gpu/drm/amd/amdkfd/kfd_events.c | 4 ++-- drivers/gpu/drm/amd/amdkfd/kfd_kernel_queue.c | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_packet_manager.c | 10 +++++----- 5 files changed, 14 insertions(+), 14 deletions(-) commit 22bbd21b81189942688db5aafe4a72074f38561b Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 27 11:08:35 2016 +0300 pinctrl: baytrail: fix some error handling in debugfs We need to unlock before continuing. Also the continue was accidentally left out on one error path which would lead to a NULL dereference. Fixes: 86e3ef812fe3 ('pinctrl: baytrail: Update gpio chip operations') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 3 +++ 1 file changed, 3 insertions(+) commit f002d07c56c7b7007328e8fff2adf04db1c81e90 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 29 21:55:23 2016 +0530 gpio: tegra: Implement gpio_get_direction callback Implement gpio_get_direction() callback for Tegra GPIO. The direction is only valid if the pin is configured as GPIO. If pin is not configured in GPIO mode then this function return error. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Acked-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tegra.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit b5aa1006e4a93ebb402490b4536a7d8866d967dc Author: Yendapally Reddy Dhananjaya Reddy <yendapally.reddy@broadcom.com> Date: Fri Apr 29 08:51:38 2016 -0400 pinctrl: ns2: add pinmux driver support for Broadcom NS2 SoC This adds the initial support of the Broadcom NS2 pinmux driver Signed-off-by: Yendapally Reddy Dhananjaya Reddy <yendapally.reddy@broadcom.com> Reviewed-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/Kconfig | 13 + drivers/pinctrl/bcm/Makefile | 1 + drivers/pinctrl/bcm/pinctrl-ns2-mux.c | 1117 +++++++++++++++++++++++++++++++++ 3 files changed, 1131 insertions(+) commit 72d3200061776264941be1b5a9bb8e926b3b30a5 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 13:33:59 2016 +0200 gpio: set up initial state from .get_direction() If the gpiochip supports the .get_direction() callback, then the initial state of the descriptor flags should be set up as output accordingly. Also put in comments explaining what is going on. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) commit e4c740e23969470f779a4c67861be4f09f87d8a0 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:37:49 2016 -0700 ARM: pxa: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> arch/arm/mach-pxa/eseries.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f806dac5938b56274b04637b2dced7c2ddb0012d Author: Robert Jarzmik <robert.jarzmik@free.fr> Date: Sat Apr 2 20:56:02 2016 +0200 ARM: pxa: activate pinctrl for device-tree machines Pincontrol is not yet ready for all PXA platforms. For example, a legacy platform, if PINCTRL was activated, will fail its calls to gpio_request() or gpio_direction_output(), as the pinctrl driver might not be available, such as for pxa25x and pxa3xx. As a step forward, activate pincontrol for all device-tree available machines, ie. pxa27x device-tree based and pxa3xx device-tree based. If it appears later that pincontrol is also required for legacy platforms and if the mfp->pinctrl conversion can be achieved, then PINCTRL will be activated for the whole PXA architecture. Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr> Acked-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/mach-pxa/Kconfig | 2 ++ 1 file changed, 2 insertions(+) commit 7827a7f6ebfcb7f388dc47fddd48567a314701ba Author: Theodore Ts'o <tytso@mit.edu> Date: Sat Apr 30 00:49:54 2016 -0400 ext4: clean up error handling when orphan list is corrupted Instead of just printing warning messages, if the orphan list is corrupted, declare the file system is corrupted. If there are any reserved inodes in the orphaned inode list, declare the file system corrupted and stop right away to avoid doing more potential damage to the file system. Cc: stable@vger.kernel.org Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ialloc.c | 49 ++++++++++++++++++++++--------------------------- 1 file changed, 22 insertions(+), 27 deletions(-) commit c9eb13a9105e2e418f72e46a2b6da3f49e696902 Author: Theodore Ts'o <tytso@mit.edu> Date: Sat Apr 30 00:48:54 2016 -0400 ext4: fix hang when processing corrupted orphaned inode list If the orphaned inode list contains inode #5, ext4_iget() returns a bad inode (since the bootloader inode should never be referenced directly). Because of the bad inode, we end up processing the inode repeatedly and this hangs the machine. This can be reproduced via: mke2fs -t ext4 /tmp/foo.img 100 debugfs -w -R "ssv last_orphan 5" /tmp/foo.img mount -o loop /tmp/foo.img /mnt (But don't do this if you are using an unpatched kernel if you care about the system staying functional. :-) This bug was found by the port of American Fuzzy Lop into the kernel to find file system problems[1]. (Since it *only* happens if inode #5 shows up on the orphan list --- 3, 7, 8, etc. won't do it, it's not surprising that AFL needed two hours before it found it.) [1] http://events.linuxfoundation.org/sites/events/files/slides/AFL%20filesystem%20fuzzing%2C%20Vault%202016_0.pdf Cc: stable@vger.kernel.org Reported by: Vegard Nossum <vegard.nossum@oracle.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ialloc.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit b5bf0f1ea3658254bd72ef64abc97786e8a32255 Author: Inki Dae <inki.dae@samsung.com> Date: Tue Apr 12 09:59:11 2016 +0900 drm/exynos: clean up register definions for fimd and decon This patch removes suffixes from I80 relevant register definitions, which are misleading. This is based on top of below patch set, http://www.spinics.net/lists/dri-devel/msg104057.html Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 2 +- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 23 +++++++++++------------ include/video/exynos5433_decon.h | 6 +++--- 3 files changed, 15 insertions(+), 16 deletions(-) commit 9ac26de835b9c1865837bce1f4fb837b2a19532e Author: Inki Dae <inki.dae@samsung.com> Date: Mon Apr 18 17:59:01 2016 +0900 drm/exynos: decon: clean up interface type This patch cleans up interface type relevant codes. Trigger mode is determinded only by i80 mode, which isn't related to Display types - HDMI or Display controller. So this patch makes the trigger mode to be set only in case of i80 mode - For DECON-TV, HW Trigger mode is flaged mandatorily because HDMI Timing Generator generates VSYNC signal which works as a hardware trigger. Changelog v2. - If interface type is HDMI then set out_type to I80. - fix compile warning. Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 55 ++++++++++++++------------- 1 file changed, 29 insertions(+), 26 deletions(-) commit a6f75aa161c5a50bb025580e4d1509729deef36d Author: Inki Dae <inki.dae@samsung.com> Date: Mon Apr 18 17:54:39 2016 +0900 drm/exynos: fimd: add HW trigger support This patch adds HW trigger support on i80 mode. Until now, Exynos DRM only supported SW trigger which was set SWTRGCMD bit of TRIGCON register by CPU to transfer scanout buffer to Display bus device or panel. With this patch, the transmission to Display bus device or panel will be initiated by FIMD controller. Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_fimd.c | 47 ++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) commit 4f452c01f5e630f1d124526a89b685b20381ef83 Author: Inki Dae <inki.dae@samsung.com> Date: Tue Apr 5 17:27:42 2016 +0900 drm/exynos: clean up wait_for_vblank This patch cleans up wait_for_vblank relevant codes. wait_for_vblank callback isn't used anymore in Exynos drm driver so it removes relevant codes. However, display controllers - FIMD and DECON - still use this function driver internally to ensure shadow registers to be updated, which resolves page fault issue so keep it. Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos7_drm_decon.c | 1 - drivers/gpu/drm/exynos/exynos_drm_drv.h | 3 --- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 1 - drivers/gpu/drm/exynos/exynos_mixer.c | 39 ------------------------------ 4 files changed, 44 deletions(-) commit 48f6155a137828ab4d570650c5aaa0a897f825be Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 1 15:17:46 2016 +0200 drm/exynos: mixer: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_mixer.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 8dfae156480719dda046916850d3ee3b255a48c3 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 1 15:17:45 2016 +0200 drm/exynos: mixer: remove support for non-dt platforms There are no non-devicetree based Exynos platforms in mainline, so there no point keeping old platform driver data for them. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_mixer.c | 16 ---------------- 1 file changed, 16 deletions(-) commit 57a64122b6f9987c0dbe7af632e1857d33fb2469 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 1 15:17:44 2016 +0200 drm/exynos: hdmi: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit f295df175ad5e3086ac7dd52f15d583e80b90f9b Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 1 15:17:43 2016 +0200 drm/exynos: rotator: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_rotator.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) commit e1a7b9b40d1c0c2fa5b6fd53424f00d968a67299 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Mon Apr 18 17:38:27 2016 +0900 drm/exynos: fimd: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_fimd.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) commit 2154ac9229c10ff91bf61da5861473f113a9e255 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Tue Apr 19 09:37:10 2016 +0200 drm/exynos: dsi: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper and add missing const qualifier to driver data structures. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_dsi.c | 27 +++++++++------------------ 1 file changed, 9 insertions(+), 18 deletions(-) commit 217afc1ee43eccb09a2905aac442d7bc20efc810 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Apr 1 15:17:40 2016 +0200 drm/exynos: exynos5433_decon: use generic of_device_get_match_data helper Simplify code by replacing custom code by generic helper. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 196e059a8a6a23dc099d4c3f2fccdda7775ddc16 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Sat Apr 30 01:39:08 2016 +0900 drm/exynos: convert clock_enable crtc callback to pipeline clock clock_enable callback is used only by FIMD->DP pipeline. Similar but more universal functionality provides pipeline clock. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <daeinki@gmail.com> drivers/gpu/drm/exynos/exynos_dp.c | 9 +++------ drivers/gpu/drm/exynos/exynos_drm_drv.h | 5 ----- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 27 +++++++++++++-------------- 3 files changed, 16 insertions(+), 25 deletions(-) commit 33ea58a9102361eff6461a31a4900dcdf0966a60 Author: Matthias Brugger <mbrugger@suse.com> Date: Thu Apr 14 23:24:26 2016 +0200 staging: fsl-mc: bus: Drop warning When updating the irq_chip and msi_domain_ops, the code checkes for already present functions. When more then one ITS controller are present in the system, irq_chip and msi_domain_ops got already set and a warning is invoked. This patch deletes the warning, as the funtions are just already set to the needed callbacks. Signed-off-by: Matthias Brugger <mbrugger@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-msi.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 633440505f16f645d22f2d7f8367125ab89123f8 Author: Horia Geantă <horia.geanta@nxp.com> Date: Mon Apr 11 11:56:16 2016 -0500 staging: fsl-mc: return -EINVAL for all fsl_mc_portal_allocate() failures There are some error paths that allow for a NULL new_mc_io and err = 0 return code. Return -EINVAL instead. Signed-off-by: Horia Geantă <horia.geanta@nxp.com> Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-allocator.c | 1 + 1 file changed, 1 insertion(+) commit 01f9330846a3aa314a4b784499724b05803f24e6 Author: Itai Katz <itai.katz@nxp.com> Date: Mon Apr 11 11:56:11 2016 -0500 staging: fsl-mc: add dpmcp version check The dpmcp driver supports dpmcp version 3.0 and above. This patch adds the code to check the version. Signed-off-by: Itai Katz <itai.katz@nxp.com> Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> drivers/staging/fsl-mc/bus/dpmcp-cmd.h | 6 +++--- drivers/staging/fsl-mc/bus/mc-allocator.c | 11 +++++++++++ 2 files changed, 14 insertions(+), 3 deletions(-) Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dpmcp-cmd.h | 6 +++--- drivers/staging/fsl-mc/bus/mc-allocator.c | 11 +++++++++++ 2 files changed, 14 insertions(+), 3 deletions(-) commit ae014c23d5267e1bd2bbafab0e1c741c202496a5 Author: Horia Geanta <horia.geanta@nxp.com> Date: Mon Apr 11 11:50:26 2016 -0500 staging: fsl-mc: add quirk handling for dpseci objects < 4.0 dpseci objects < 4.0 are not coherent-- in spite of the fact that the MC reports them to be coherent in certain versions. Add a special case to set the no shareability flag for dpseci objects < 4.0. Signed-off-by: Horia Geanta <horia.geanta@nxp.com> (Stuart: reworded commit message, updated comment in patch) Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dprc-driver.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 1716cb4c65d2ca4e18110b345b11b285d89d346f Author: Itai Katz <itai.katz@nxp.com> Date: Mon Apr 11 11:56:05 2016 -0500 staging: fsl-mc: add dprc version check The dprc driver supports dprc version 5.0 and above. This patch adds the code to check the version. Signed-off-by: Itai Katz <itai.katz@nxp.com> (Stuart: resolved merge conflicts, split dpseci quirk into separate patch) Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dprc-cmd.h | 6 +++--- drivers/staging/fsl-mc/bus/dprc-driver.c | 19 +++++++++++++++++++ drivers/staging/fsl-mc/bus/mc-bus.c | 1 + drivers/staging/fsl-mc/include/mc-private.h | 2 ++ 4 files changed, 25 insertions(+), 3 deletions(-) commit 9529d166f32a2364fa644f8431ba508443953d64 Author: Itai Katz <itai.katz@nxp.com> Date: Mon Apr 11 11:55:55 2016 -0500 staging: fsl-mc: get version of root dprc from MC hardware The root dprc is discovered as a platform device in the device tree. The version of that dprc was previously set using hardcoded values from the API header in the kernel). This patch removes the use of the hardcoded version numbers and instead reads the actual dprc version from the hardware. Signed-off-by: Itai Katz <itai.katz@nxp.com> (Stuart: resolved merge conflict, updated commit subject/log) Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-bus.c | 45 ++++++++++++++++++++++++++++++------- 1 file changed, 37 insertions(+), 8 deletions(-) commit b3721fc1e0cb2f2e1e4732ab4c9bf72363a6b5ed Author: Itai Katz <itai.katz@nxp.com> Date: Mon Apr 11 11:55:48 2016 -0500 staging: fsl-mc: set cacheable flag for added devices if applicable Some DPAA2 devices have mmio regions that should be mapped as cacheable by drivers. Set IORESOURCE_CACHEABLE in the region's flags if applicable. Signed-off-by: Itai Katz <itai.katz@nxp.com> [Stuart: update subject and commit message] Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-bus.c | 2 ++ 1 file changed, 2 insertions(+) commit 0f90f25b8f83f5185c0fea8fa02b6bb77917f916 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:49:13 2016 -0500 staging: fsl-mc: set up coherent dma ops for added devices Unless discovered devices have the no shareability flag set, set up coherent dma ops for them. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-bus.c | 4 ++++ 1 file changed, 4 insertions(+) commit 9787d4e05e022de73eafdf70319ae26a4978a7b9 Author: Itai Katz <itai.katz@nxp.com> Date: Mon Apr 11 11:55:40 2016 -0500 staging: fsl-mc: don't use object versions to make binding decisions Up until now if the object version expected by a driver (in the API header file) did not match the actual object version in the MC hardware the bus driver refused to bind the object to the driver or printed out WARN_ON dumps. This patch removes those checks, and the responsibility of object version checking should now be done in the object drivers themselves. If the actual version discovered is not supported, the driver's probe function should fail. Drivers should use version checks to support new features and provide backwards compatibility if at all possible. This patch also removes the checks that caused bus driver probing to fail if the overall MC version discovered did not match the firmware version from the API header...this was too strict. The overall MC version is informational like a release number, and continues to be printed in the boot log. Signed-off-by: Itai Katz <itai.katz@nxp.com> (Stuart: reworded commit log) Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dprc-driver.c | 4 +--- drivers/staging/fsl-mc/bus/mc-allocator.c | 6 ----- drivers/staging/fsl-mc/bus/mc-bus.c | 38 +------------------------------ 3 files changed, 2 insertions(+), 46 deletions(-) commit ac0619981d0e2e2bd9022b035cb8affef1325998 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:48:59 2016 -0500 staging: fsl-mc: update dprc binary interface to v5.1 The meaning of the "status" parameter in dprc_get_irq_status has changed, and this patch updates the flib and caller of the API. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dprc-cmd.h | 4 ++-- drivers/staging/fsl-mc/bus/dprc-driver.c | 1 + drivers/staging/fsl-mc/bus/dprc.c | 26 +++++++++++++------------- drivers/staging/fsl-mc/bus/mc-msi.c | 2 +- drivers/staging/fsl-mc/include/dprc.h | 19 ++++++++++++------- 5 files changed, 29 insertions(+), 23 deletions(-) commit 6606c073a5695ef566bea3b0f3af979395a64e17 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:48:54 2016 -0500 staging: fsl-mc: update dpbp binary interface to v2.2 Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dpbp.c | 77 ++++++++++++++++++++++++++++++- drivers/staging/fsl-mc/include/dpbp-cmd.h | 4 +- drivers/staging/fsl-mc/include/dpbp.h | 51 +++++++++++++++++++- 3 files changed, 127 insertions(+), 5 deletions(-) commit f8274454bcdac834baf2afe9b5543e088c029a73 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:48:48 2016 -0500 staging: fsl-mc: update dpmcp binary interface to v3.0 Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/dpmcp-cmd.h | 5 ++--- drivers/staging/fsl-mc/bus/dpmcp.c | 35 ++-------------------------------- drivers/staging/fsl-mc/bus/dpmcp.h | 10 ++-------- 3 files changed, 6 insertions(+), 44 deletions(-) commit 7dc0818367418e7fa9085ebdddc435f6b1ca4941 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:48:42 2016 -0500 staging: fsl-mc: DPAA2 overview readme update incorporated feedback from review comments, other misc cleanup/tweaks Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/README.txt | 138 ++++++++++++++++++++++---------------- 1 file changed, 80 insertions(+), 58 deletions(-) commit 71bd14e3ec654442c1fdddf6a54ed94b83436feb Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Mon Apr 11 11:48:37 2016 -0500 staging: fsl-mc: TODO updates remove 3 of the remaining TODO items: -multiple root fsl-mc buses-- done in patch series starting with commit 14f928054a05 ("staging: fsl-mc: abstract test for existence of fsl-mc bus") -interrupt support-- done in patch series starting with commit 9b1b282ccd81 ("irqdomain: Added domain bus token DOMAIN_BUS_FSL_MC_MSI") -MC command serialization-- done in commit 63f2be5c3b358 ("staging: fsl-mc: Added serialization to mc_send_command()") Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: German Rivera <german.rivera@nxp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/TODO | 13 ------------- 1 file changed, 13 deletions(-) commit d6a1b8d9db3a51f72cdd078ffe48ebcc90fcdd24 Author: Nikita Eshkeev <kastolom@gmail.com> Date: Tue Apr 26 02:15:09 2016 +0300 staging: board: line over 80 characters This patch fixes the checkpatch.pl warning: WARNING: line over 80 characters + .domain = "/system-controller@e6180000/pm-domains/c5/a4lc@1" Signed-off-by: Nikita Eshkeev <kastolom@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/board/armadillo800eva.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 5678824069d599f8cc3fed8b0dadce0f670fabc3 Author: han tai <hantai1248@hotmail.com> Date: Wed Apr 20 07:23:03 2016 +0000 staging: vt6656: Add space to align functions Issue found by checkpatch.pl CHECK: Alignment should match open parenthesis Signed-off-by: han tai <hantai1248@hotmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vt6656/baseband.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit d37912dd298eb7d2c3c85daeb605066236c8ac4b Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Tue Apr 5 17:37:38 2016 -0400 staging: slicoss: fix missing blank line fix checkpatch.pl warning about 'Missing a blank line after declarations' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/slicoss/slicoss.c | 1 + 1 file changed, 1 insertion(+) commit f2fe1bc90016966ca2423e2bd84e37c753b852e6 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Tue Apr 5 17:37:37 2016 -0400 staging: slicoss: fix bare use of 'unsigned' fix checkpatch.pl warning about 'Prefer 'unsigned int' to bare use of 'unsigned'' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/slicoss/slicoss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e0ab2c8ef52cdfc69cabd6aa2140a28c1f404f99 Author: Manav Batra <batmanav10@gmail.com> Date: Wed Apr 6 20:22:52 2016 -0700 staging: rts5208: alignment to match open paranthesis Fixes CHECK: Alignment should match open parenthesis Signed-off-by: Manav Batra <batmanav10@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rts5208/ms.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 649b55b4260fa84f362f6143f6ae0508eb355ff9 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 17:47:35 2016 +0100 staging: rts5208: ensure braces on all arms of if stmt Added braces on if arm of if statement where else arm already needs braces as suggested for clarity in Documentation/CodingStyle (several) Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rts5208/sd.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit ae25d43c5910ab58bfc6e66a6e9a90d853c5b1cf Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 8 16:02:35 2016 +0300 staging: lowmemorykiller: remove bogus NULL check The NULL checking here doesn't make sense, so it causes a static checker warning. It turns out that p->mm can't be NULL so the inconsistency is harmless and we should just remove the check. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/lowmemorykiller.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6ffdc7b95474d572f67b0c198cd7a08d8f5e5ff6 Author: Cihangir Akturk <cakturk@gmail.com> Date: Sat Apr 9 21:45:18 2016 +0300 staging: fsl-mc: get rid of mutex_locked variables Remove mutex_locked variables which are used to determine whether mutex is locked, instead add another label to unlock mutex on premature exits due to an error. This patch also addresses the folowing warnings reported by coccinelle: drivers/staging/fsl-mc/bus/mc-allocator.c:237:1-7: preceding lock on line 204 drivers/staging/fsl-mc/bus/mc-allocator.c:89:1-7: preceding lock on line 57 drivers/staging/fsl-mc/bus/mc-allocator.c:157:1-7: preceding lock on line 124 Signed-off-by: Cihangir Akturk <cakturk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fsl-mc/bus/mc-allocator.c | 61 ++++++++++++------------------- 1 file changed, 24 insertions(+), 37 deletions(-) commit c3f463484bdd0acd15abd5f92399041f79592d06 Author: Ben Hutchings <ben@decadent.org.uk> Date: Thu Apr 21 00:19:25 2016 +0100 staging: rtl8192u: Fix crash due to pointers being "confusing" There's no net_device stashed in skb->cb, there's a net_device * there. To make it *really* clear, also change the write of the dev pointer into skb->cb from a memcpy() to an assignment. Fixes: 3fe563249374 ("staging: rtl8192u: r8192U_core.c: Cleaning up ...") Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b8a99fb513a63397b43f63f4825371f64a79e821 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 17:21:32 2016 +0100 staging: rtl8192u: rewrite NULL comparison for pointers When testing pointers, it is not necessary to explicitly compare to NULL. Rewrite if condition as (!ptr) or (ptr) as suggested in Documentation/CodingStyle Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b7141cbaf9cb6361c97d34ed17989af01e77f437 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 17:13:34 2016 +0100 staging: rtl8192u: add blank line after declarations Add a blank line after function/struct/union/enum declarations for readability, as suggested in Documentation/CodingStyle Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_core.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 345c32ab9beed825a05af374f12256fabc5104be Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 17:07:47 2016 +0100 staging: rtl8192u: remove blank lines after braces (opening) Remove unneeded blank lines appearing after opening braces as suggested by checkpatch.pl Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_core.c | 14 -------------- 1 file changed, 14 deletions(-) commit 708075cf1b3218e262502ce27d81a4bcceccaa81 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 16:59:58 2016 +0100 staging: rtl8192u: remove blank lines before braces (closing) Remove unneeded blank lines occuring before closing braces Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_core.c | 35 ---------------------------------- 1 file changed, 35 deletions(-) commit fcc2cf12a3192dc2b4181f06f088fa2b983794a9 Author: Geliang Tang <geliangtang@163.com> Date: Tue Apr 5 09:58:04 2016 +0800 staging: rtl8712: use container_of() instead of LIST_CONTAINOR() This patch drops the local definition of LIST_CONTAINOR(), and uses container_of() instead of it. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/osdep_service.h | 3 --- drivers/staging/rtl8712/rtl8712_recv.c | 10 +++++----- drivers/staging/rtl8712/rtl8712_xmit.c | 8 ++++---- drivers/staging/rtl8712/rtl871x_ioctl_linux.c | 12 ++++++------ drivers/staging/rtl8712/rtl871x_mlme.c | 12 ++++++------ drivers/staging/rtl8712/rtl871x_recv.c | 2 +- drivers/staging/rtl8712/rtl871x_sta_mgt.c | 6 +++--- drivers/staging/rtl8712/rtl871x_xmit.c | 2 +- 8 files changed, 26 insertions(+), 29 deletions(-) commit 3faa966bfbd8a6059a7fd6e4f0ea37c47f0e4d74 Author: Manu Kumar <maraku@gmx.com> Date: Mon Apr 4 20:09:12 2016 -0700 staging: skein: cleanup: align parentheses Aligned parentheses to conform to the coding style. Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_base.c | 14 +++++++------- drivers/staging/skein/skein_generic.c | 6 +++--- 2 files changed, 10 insertions(+), 10 deletions(-) commit 78930e7c3c114e473d0116c18dbf3894ec4c005d Author: Manu Kumar <maraku@gmx.com> Date: Mon Apr 4 16:53:01 2016 -0700 staging: skein: cleanup: add operator white space Added white space between operators and operands. Because this sometimes maxed out the column width, some expressions were broken up into multiple lines, and comments were moved appropriately. Signed-off-by: Manu Kumar <maraku@gmx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_base.c | 66 +++++++++++++++++------------------ drivers/staging/skein/skein_base.h | 28 +++++++-------- drivers/staging/skein/skein_block.c | 46 +++++++++++++----------- drivers/staging/skein/threefish_api.h | 2 +- 4 files changed, 73 insertions(+), 69 deletions(-) commit 60b3109e5e2d93af6a61c7caf10f1009584cee30 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Thu Apr 14 12:30:13 2016 +0900 staging: dgnc: use tty_alloc_driver instead of kcalloc The tty_alloc_driver() can allocate memory for ttys and termios. And also allocated memory will be released easily with put_tty_driver() call. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.h | 4 +- drivers/staging/dgnc/dgnc_tty.c | 144 ++++++++++++++++--------------------- 2 files changed, 62 insertions(+), 86 deletions(-) commit e47e7379ce3e03018619e994976b4059b790c955 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Apr 5 18:30:02 2016 +0900 staging: dgnc: remove redundant NULL check in There were already checking NULL about channel_t / un_t before calling dgnc_maxcps_room(). Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) commit 16f10a825da5b9361ef8e8da76720c37f0116da4 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Apr 5 18:29:43 2016 +0900 staging: dgnc: return -ENOMEM when kzalloc failed The kzalloc can be failed when memory is not enough to allocate. When kzalloc failed, it need to return error code with ENOMEM Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 6b3752d8ce67dc62150db9d153e72c7a98db4007 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon Apr 4 18:52:30 2016 +0900 staging: dgnc: remove blank line fix checkpatch.pl warning: Blank lines aren't necessary after an open brace '{' Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 1 - 1 file changed, 1 deletion(-) commit ea753f2a5976570db67a4f8fbd54607652c621cc Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon Apr 4 18:52:03 2016 +0900 staging: dgnc: remove parenthesis around the CONST | remove parenthesis around the CONST | CONST. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_cls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 24039c589b8d11584ab882597fb566df2636bd73 Author: Juanma de Hoyos <juanmahv@gmail.com> Date: Sun Apr 3 22:01:36 2016 +0200 drivers/staging/dgnc: Added spaces around a bitwise OR. Coding rules request placing bitwise OR operators between empty spaces for better readibility. This patch applies this format to a line in dgnc_tty.c file. Signed-off-by: Juanma de Hoyos <juanmahv@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e26eaf457989326a41eb58754f18333308cab321 Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Sun Apr 24 19:40:13 2016 +0300 Staging: wlan-ng: memory allocated inside mkimage() is not freed if subsequent calls fails. This patch frees memory allocated inside mkimage() in case mkimage() or any other subsequent calls inside prism2_fwapply() from prism2fw.c file fails. To fix this I introduces goto labels where the free operation is done in case some operations fails. After the introduction of goto labels has been done, in order to use the same return path, "return x" instuctions were replaced with "goto" instuctions. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/prism2fw.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) commit 02e020480daf3a7726db493ff28f9391ff6bb9c4 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Tue Apr 5 17:37:12 2016 +0100 staging: wlan-ng: rewrite NULL comparison It is not necessary to compare explicitly to NULL. Rewrite if condition as (!dev) or (dev) as suggested in Documentation/CodingStyle Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/hfa384x_usb.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 9f563f1a2a4b448393159b3d526a6657dc4c0fce Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Thu Apr 7 22:02:25 2016 +0530 staging: android: ion: dummy: fix dereference of ERR_PTR ion_device_create() can fail and if it fails then it returns the error value in ERR_PTR. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Reviewed-by: Laura Abbott <labbott@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/ion/ion_dummy_driver.c | 2 ++ 1 file changed, 2 insertions(+) commit 3229ff343c70163b5425e54cce1f313a9be6b85e Author: Ben Marsh <bmarsh94@gmail.com> Date: Thu Apr 7 21:26:34 2016 +0200 Staging: android: modify memory allocation style in ion_chunk_heap.c Modify memory allocation style in order to silence a checkpatch.pl warning. Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/ion/ion_chunk_heap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9fea19a9a4bb22a237972d50e41219ddd479ea22 Author: Ben Marsh <bmarsh94@gmail.com> Date: Sun Apr 24 20:16:02 2016 +0200 Staging: android: modify memory allocation style in ion_test.c Modifies the memory allocation style ion_test.c in order to remove a checkpatch.pl warning Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/ion/ion_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0045c8ddd6965e15f638788e7180abe8765f6cbb Author: Markus Böhme <markus.boehme@mailbox.org> Date: Wed Apr 6 23:53:39 2016 +0200 staging: android: ion: make locally used functions static Functions ion_handle_put and ion_handle_get_by_id are only used locally in ion.c, so they should be made static as they used to be before 9590232b ("staging/android/ion : fix a race condition in the ion driver"). Signed-off-by: Markus Böhme <markus.boehme@mailbox.org> Reviewed-by: Sumit Semwal <sumit.semwal@linaro.org> Reviewed-by: Laura Abbott <labbott@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/ion/ion.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c784c82a3fd64b322015b92016fc980be705c176 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:47:00 2016 -0300 Documentation: add Sync File doc Add sync_file documentation on dma-buf-sync_file.txt Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/sync_file.txt | 69 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) commit 5b996e93aac3d9a26e077df1c9bb581427b216fe Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:59 2016 -0300 Documentation: include sync_file into DocBook Add entry in device-drivers.tmpl for sync_file documentation. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/DocBook/device-drivers.tmpl | 2 ++ 1 file changed, 2 insertions(+) commit 62304fb1fc0801925568e191261b650e1546ce8c Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:58 2016 -0300 dma-buf/sync_file: de-stage sync_file sync_file is useful to connect one or more fences to the file. The file is used by userspace to track fences between drivers that share DMA bufs. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/Kconfig | 2 + drivers/dma-buf/Kconfig | 11 + drivers/dma-buf/Makefile | 1 + drivers/dma-buf/sync_file.c | 395 ++++++++++++++++++++++++++++++++++++ drivers/staging/android/Kconfig | 1 + drivers/staging/android/Makefile | 2 +- drivers/staging/android/sync_file.c | 395 ------------------------------------ 7 files changed, 411 insertions(+), 396 deletions(-) commit 460bfc41fd52959311ed0328163f785e023857af Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:57 2016 -0300 dma-buf/sync_file: de-stage sync_file headers Move sync_file headers file to include/ dir. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.h | 4 +- drivers/staging/android/sync_debug.c | 2 +- drivers/staging/android/sync_file.c | 4 +- drivers/staging/android/sync_file.h | 57 ------------------ drivers/staging/android/uapi/sync_file.h | 100 ------------------------------- include/linux/sync_file.h | 57 ++++++++++++++++++ include/uapi/linux/sync_file.h | 100 +++++++++++++++++++++++++++++++ 7 files changed, 162 insertions(+), 162 deletions(-) commit 92e06213f11a87effad8bdd4d910958b89eec044 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:56 2016 -0300 staging/android: style fix: alignment to match the open parenthesis Fix checks reported by checkpatch.pl. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync_file.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c240a714a6ad68458c3caf61ab6216184e52b631 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:55 2016 -0300 staging/android: improve documentation for sync_file num_fences was missing a colon mark and sync_file_create() now have better description. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync_file.c | 5 +++-- drivers/staging/android/sync_file.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) commit d4cab38e153d62ecd502645390c0289c1b8337df Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:54 2016 -0300 staging/android: prepare sync_file for de-staging Move its functions and structs to their own file. Also moves function's docs to the .c file. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/Makefile | 2 +- drivers/staging/android/sync.c | 374 ----------------------------- drivers/staging/android/sync.h | 38 +-- drivers/staging/android/sync_debug.c | 1 + drivers/staging/android/sync_file.c | 394 +++++++++++++++++++++++++++++++ drivers/staging/android/sync_file.h | 57 +++++ drivers/staging/android/uapi/sync.h | 100 -------- drivers/staging/android/uapi/sync_file.h | 100 ++++++++ 8 files changed, 555 insertions(+), 511 deletions(-) commit d7c3110c28dee67f6766ae26cac629358233a6b4 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:53 2016 -0300 staging/android: remove name arg from sync_file_create() Simplifies the API to only receive the fence it needs to add to the sync and create a name for the sync_file based on the fence context and seqno. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 16 +++++++++------- drivers/staging/android/sync.h | 2 +- drivers/staging/android/sync_debug.c | 3 +-- 3 files changed, 11 insertions(+), 10 deletions(-) commit 10e362c387e45f01cc38f62dec8f0bc3f1d676b5 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:52 2016 -0300 staging/android: make sync_file_fdget() static There is no plan in the near future to use this function outside of this file so keep it as static. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 3 +-- drivers/staging/android/sync.h | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) commit 4dff14e88ea928eacaa5faacd05d966c04bcecac Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:51 2016 -0300 staging/android: make sync_file_merge() static There is no plan in the near future to use this function outside of this file so keep it as static. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 5 ++--- drivers/staging/android/sync.h | 2 -- 2 files changed, 2 insertions(+), 5 deletions(-) commit 696f74cf543997732d87956c5a88de6e9bd42605 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:50 2016 -0300 staging/android: move sync_file functions comments to sync.c To keep comments in line with drivers/dma-buf/ move all sync_file comments to sync.c. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 26 +++++++++++++++++++++++++- drivers/staging/android/sync.h | 31 ------------------------------- 2 files changed, 25 insertions(+), 32 deletions(-) commit 2a7c1db557e111eaeb967baf2d39ecd6e593b767 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:49 2016 -0300 staging/android: drop sync_file_install() and sync_file_put() These two functions are just wrappers for one line functions, they call fd_install() and fput() respectively, so just get rid of them and use fd_install() and fput() directly for more simplicity. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 20 ++++---------------- drivers/staging/android/sync.h | 19 ------------------- drivers/staging/android/sync_debug.c | 4 ++-- 3 files changed, 6 insertions(+), 37 deletions(-) commit a64d6a68667e61f34b27df294e25da6a45f31ff2 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 28 10:46:48 2016 -0300 staging/android: remove redundant comments on sync_merge_data struct sync_merge_data already have documentation on top of the struct definition. No need to duplicate it. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/uapi/sync.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 2d75c88fefb228aedfb135228acb6620db8f0e40 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Tue Apr 26 12:32:28 2016 -0300 staging/android: refactor SYNC IOCTLs Change SYNC_IOC_FILE_INFO (former SYNC_IOC_FENCE_INFO) behaviour to avoid future API breaks and optimize buffer allocation. Now num_fences can be filled by the caller to inform how many fences it wants to retrieve from the kernel. If the num_fences passed is greater than zero info->sync_fence_info should point to a buffer with enough space to fit all fences. However if num_fences passed to the kernel is 0, the kernel will reply with number of fences of the sync_file. Sending first an ioctl with num_fences = 0 can optimize buffer allocation, in a first call with num_fences = 0 userspace will receive the actual number of fences in the num_fences filed. Then it can allocate a buffer with the correct size on sync_fence_info and call SYNC_IOC_FILE_INFO again, but now with the actual value of num_fences in the sync_file. info->sync_fence_info was converted to __u64 pointer to prevent 32bit compatibility issues. And a flags member was added. An example userspace code for the later would be: struct sync_file_info *info; int err, size, num_fences; info = malloc(sizeof(*info)); info.flags = 0; err = ioctl(fd, SYNC_IOC_FILE_INFO, info); num_fences = info->num_fences; if (num_fences) { info.flags = 0; size = sizeof(struct sync_fence_info) * num_fences; info->num_fences = num_fences; info->sync_fence_info = (uint64_t) calloc(num_fences, sizeof(struct sync_fence_info)); err = ioctl(fd, SYNC_IOC_FILE_INFO, info); } Finally the IOCTLs numbers were changed to avoid any potential old userspace running the old API to get weird errors. Changing the opcodes will make them fail right away. This is just a precaution, there no upstream users of these interfaces yet and the only user is Android, but we don't expect anyone trying to run android userspace and all it dependencies on top of upstream kernels. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Acked-by: Greg Hackmann <ghackmann@google.com> Acked-by: Rob Clark <robdclark@gmail.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/sync.c | 76 ++++++++++++++++++++----------------- drivers/staging/android/uapi/sync.h | 36 +++++++++++++----- 2 files changed, 67 insertions(+), 45 deletions(-) commit 3ed605bc8a0a688d8750a1e2eff39c854418c5cf Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Tue Apr 26 12:32:27 2016 -0300 kernel.h: add u64_to_user_ptr() This function had copies in 3 different files. Unify them in kernel.h. Cc: Joe Perches <joe@perches.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: David Airlie <airlied@linux.ie> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Rob Clark <robdclark@gmail.com> Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Acked-by: Daniel Vetter <daniel.vetter@intel.com> [drm/i915/] Acked-by: Rob Clark <robdclark@gmail.com> [drm/msm/] Acked-by: Lucas Stach <l.stach@pengutronix.de> [drm/etinav/] Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/gpu/drm/etnaviv/etnaviv_gem_submit.c | 11 +++-------- drivers/gpu/drm/i915/i915_drv.h | 5 ----- drivers/gpu/drm/i915/i915_gem.c | 14 +++++++------- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 14 +++++++------- drivers/gpu/drm/msm/msm_gem_submit.c | 11 +++-------- include/linux/kernel.h | 7 +++++++ 6 files changed, 27 insertions(+), 35 deletions(-) commit b5b7fe86668b4606ccd878a6c8a57f96247c5705 Author: Leo Sperling <leosperling97@gmx.de> Date: Thu Apr 14 13:25:26 2016 +0200 staging: android: Fix grammar error in Kconfig file Remove the "s" from kills so that the help message is easier to understand Signed-off-by: Leo Sperling <leosperling97@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d03c023e1ea6c67f63a71ce642ac0a7873a55e69 Author: Laura Abbott <labbott@redhat.com> Date: Mon Apr 11 10:51:11 2016 -0700 MAINTAINERS: Add Android Ion as a separate entry The android drivers have a few other people reviewing patches. Add a separate entry to ensure patches go to the right people. Signed-off-by: Laura Abbott <labbott@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+) commit f46eb0e9fc763b7b66c325eb94e6aefa960146d2 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:34 2016 -0400 scsi_debug: use likely hints on fast path The most common commands in normal use are the READ and WRITE SCSI commands. Use likely and unlikely hints along the path taken by these commands. Rename check_readiness() to make_ua() and remove associated dead code. Rename devInfoReg() to find_build_dev_info(). Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 219 ++++++++++++++++++++++------------------------ 1 file changed, 105 insertions(+), 114 deletions(-) commit fd32119b0deac1af90ca3bed145f17d5ad68d5a7 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:33 2016 -0400 scsi_debug: re-order file scope declarations Group most defines together first; followed by struct definitions and then table and variable definitions. Normalize all function headers. [mkp: Corrected hex value in WP/DPOFUA MODE SENSE comment] Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 314 ++++++++++++++++++++++------------------------ 1 file changed, 151 insertions(+), 163 deletions(-) commit 6ca7208569550de43d64db6cf873706c371284a5 Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Apr 29 10:33:23 2016 -0700 nfit: export subsystem ids as attributes Similar to pci-sysfs export the subsystem information available in the NFIT. ACPI 6.1 clarifies that this data is copied as an array of bytes from the DIMM SPD data. Reported-by: Ryon Jensen <ryon.jensen@intel.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) commit a10bc12af6347d2aa3a2ffbd5f8b7be260c12b85 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:32 2016 -0400 scsi_debug: replace tasklet with work queue When a negative value was placed in the delay parameter, a tasklet was scheduled. Change the tasklet to a work queue. Previously a delay of -1 scheduled a high priority tasklet; since there are no high priority work queues, treat -1 like other negative values in delay and schedule a work item. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 230 +++++++++++++++++++--------------------------- 1 file changed, 95 insertions(+), 135 deletions(-) commit c2206098972e8ca464040897c95bdf5b2f45ac32 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:31 2016 -0400 scsi_debug: make jiffy delay name clearer Add 'j' to delay names to make it clearer that its unit is jiffies and to differentiate it from sdebug_ndelay whose unit is nanoseconds. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 46 +++++++++++++++++++++++----------------------- 1 file changed, 23 insertions(+), 23 deletions(-) commit b333a819813c756804034c93b05e43ccdd4025a5 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:30 2016 -0400 scsi_debug: replace jiffy timers with hr timers The driver supports two command delay interfaces, the original one whose unit is a jiffy, and a newer one whose unit is a nanosecond. Each had different implementations. Keep both interfaces but simplify the implemenation to use a single delay mechanism based on high resolution timers. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 56 ++++++++++++++++++----------------------------- 1 file changed, 21 insertions(+), 35 deletions(-) commit 185dd2329785981d458690c78fd56b320fef4ea7 Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:29 2016 -0400 scsi_debug: ignore host lock option Remove logic to optionally hold host_lock while each command is queued. Keep module and sysfs host_lock parameters for backward compatibility. Note in module parameter description that host_lock is ignored. Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 44 +++++++------------------------------------- 1 file changed, 7 insertions(+), 37 deletions(-) commit 773642d95b8220502555122578694deeee8af4af Author: Douglas Gilbert <dgilbert@interlog.com> Date: Mon Apr 25 12:16:28 2016 -0400 scsi_debug: cleanup naming and bit crunching Shorten file scope static and constant names. Use more get/put_unaligned calls to hide bit banging. Introduce sdebug_verbose boolean to replace frequent masking of option bit flags. Add GPL and bump version. [mkp: Use logical instead of bitwise OR for LBP VPD flags] Signed-off-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_debug.c | 1162 ++++++++++++++++++++------------------------- 1 file changed, 525 insertions(+), 637 deletions(-) commit ff54aee466e3ad3f5aad76c629a8bcb88fc9b348 Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:14:26 2016 -0500 hpsa: update driver version Reviewed-by: Gerry Morong <gerry.morong@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ba74fdc411b84064d7abe4b10d0708f6dad03eb2 Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:14:17 2016 -0500 hpsa: correct handling of HBA device removal Need to report HBA device removal faster than the event handler polling interval. Stop I/O to the removed disk and wait for all I/O operations to flush before removing the device. Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++--- drivers/scsi/hpsa.h | 1 + 2 files changed, 85 insertions(+), 5 deletions(-) commit 064d1b1d2d8e0b90f1a0a49112eca0d5c2a09b16 Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:14:07 2016 -0500 hpsa: correct ioaccel2 error procecssing. set offload_to_be_enabled to 0 when an ioaccel2 error is processed. Before, an ioaccel completion error would turn of ioaccel but a rescan would turn it back on again. Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 5323ed74bdf1274caabea6bfc94eef32b89c72fe Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:13:59 2016 -0500 hpsa: correct ioaccel state change operation offload_to_be_enabled also needs to be set to 0 during a state change. Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit c448ecfa0b2e648a668a1c62286e989ab1dbf6c8 Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:13:51 2016 -0500 hpsa: add timeouts for driver initiated commands faulty drives can cause the driver to hang during a scan operation. Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) commit ded1be4ae6b8e279ab43a5fe2069dd60bb836d30 Author: Joseph T Handzik <joseph.t.handzik@hpe.com> Date: Wed Apr 27 17:13:33 2016 -0500 hpsa: add sas_address to sysfs device attibute There have been companies requesting a sysfs entry to obtain the sas address of device. Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) commit cf47723763a72354f90cd0b3e527704f4e2f7eb7 Author: Don Brace <don.brace@microsemi.com> Date: Wed Apr 27 17:13:26 2016 -0500 hpsa: correct initialization order issue The driver was calling scsi_scan_host before enabling interrupts. This has gone unnoticed except for customers running in intx mode. Calling scsi_scan_host before interrupts are enabled causes "irq XX: nobody cared" messages and the driver to hang. This patch enables interrupts before the call to scsi_scan_host. Reported-by: Piotr Karbowski <piotr.karbowski@gmail.com> Reviewed-by: Scott Teel <scott.teel@microsemi.com> Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com> Signed-off-by: Don Brace <don.brace@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 139112fb34db6361082b992d7b5fbb9d223c2c33 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:32:44 2016 -0700 aacraid: Update driver version Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aacraid.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 78cbccd3bd683c295a44af8050797dc4a41376ff Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:32:37 2016 -0700 aacraid: Fix for KDUMP driver hang When KDUMP is triggered the driver first talks to the firmware in INTX mode, but the adapter firmware is still in MSIX mode. Therefore the first driver command hangs since the driver is waiting for an INTX response and firmware gives a MSIX response. If when the OS is installed on a RAID drive created by the adapter KDUMP will hang since the driver does not receive a response in sync mode. Fixed by: Change the firmware to INTX mode if it is in MSIX mode before sending the first sync command. Cc: stable@vger.kernel.org Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aacraid.h | 1 + drivers/scsi/aacraid/comminit.c | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) commit eef76f16295d34d7fab6994b82dda60ce002f91d Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:32:26 2016 -0700 aacraid: Remove code to needlessly complete fib Currently driver completes double completed or spurious interrupted fibs. This is not necessary and causes the SCSI mid layer to issue aborts and resets, since completing a fib prematurely might trigger a race condition resulting in the driver not calling the scsi_done callback. Fixed by removing the call to fib complete. Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/dpcsup.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 9cb62fa24e0d22dbe991c315d6c454a341ea3f76 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:32:09 2016 -0700 aacraid: Log firmware AIF messages Firmware AIF messages about cache loss and data recovery are being missed by the driver since currently they are not captured but rather let go. This patch to capture those messages and log them for the user. Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aacraid.h | 4 ++++ drivers/scsi/aacraid/commsup.c | 27 +++++++++++++++++++++++++++ drivers/scsi/aacraid/linit.c | 2 ++ drivers/scsi/aacraid/src.c | 3 ++- 4 files changed, 35 insertions(+), 1 deletion(-) commit fc4bf75ea300a5e62a2419f89dd0e22189dd7ab7 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:31:57 2016 -0700 aacraid: Fix for aac_command_thread hang Typically under error conditions, it is possible for aac_command_thread() to miss the wakeup from kthread_stop() and go back to sleep, causing it to hang aac_shutdown. In the observed scenario, the adapter is not functioning correctly and so aac_fib_send() never completes (or time-outs depending on how it was called). Shortly after aac_command_thread() starts it performs aac_fib_send(SendHostTime) which hangs. When aac_probe_one /aac_get_adapter_info send time outs, kthread_stop is called which breaks the command thread out of it's hang. The code will still go back to sleep in schedule_timeout() without checking kthread_should_stop() so it causes aac_probe_one to hang until the schedule_timeout() which is 30 minutes. Fixed by: Adding another kthread_should_stop() before schedule_timeout() Cc: stable@vger.kernel.org Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/commsup.c | 4 ++++ 1 file changed, 4 insertions(+) commit e4d5c4e238999ba0b68618a91eec33e7079cdbd4 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:31:43 2016 -0700 aacraid: Disable MSI mode for series 6, 7, 8 cards As the firmware for series 6, 7, 8 cards does not support msi, remove it in the driver Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/comminit.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) commit 07beca2be24cc710461c0b131832524c9ee08910 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:31:26 2016 -0700 aacraid: Relinquish CPU during timeout wait aac_fib_send has a special function case for initial commands during driver initialization using wait < 0(pseudo sync mode). In this case, the command does not sleep but rather spins checking for timeout.This loop is calls cpu_relax() in an attempt to allow other processes/threads to use the CPU, but this function does not relinquish the CPU and so the command will hog the processor. This was observed in a KDUMP "crashkernel" and that prevented the "command thread" (which is responsible for completing the command from being timed out) from starting because it could not get the CPU. Fixed by replacing "cpu_relax()" call with "schedule()" Cc: stable@vger.kernel.org Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/commsup.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 116d77fea02e2a5aded7d29ba4c692774cb339f1 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:31:12 2016 -0700 aacraid: Start adapter after updating number of MSIX vectors The adapter has to be started after updating the number of MSIX Vectors Fixes: ecc479e00db8 (aacraid: Set correct MSIX count for EEH recovery) Cc: stable@vger.kernel.org Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/linit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a6cd4549af54ee1ba70a77661499828ea5a2bb3c Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:31:03 2016 -0700 aacraid: Fix incorrectly named MACRO Suggested-by: Seymour, Shane M <shane.seymour@hpe.com> Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aacraid.h | 2 +- drivers/scsi/aacraid/comminit.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit da31df8c7285910ee8c8629d901b34a480ab0005 Author: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Date: Mon Apr 25 23:30:55 2016 -0700 aacraid: Removed unnecessary checks for NULL Current driver checks for NULL return from aac_fib_alloc_tag, but it not possible for it to return NULL. Fixed by: Remove all the checks for NULL returns from aac_fib_alloc_tag Suggested-by: Tomas Henzl <thenzl@redhat.com> Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/aacraid/aachba.c | 22 ---------------------- 1 file changed, 22 deletions(-) commit 1354379b13f190ae5da21c26836a16ba56566ab3 Author: Alexey Khoroshilov <khoroshilov@ispras.ru> Date: Sat Apr 16 02:12:29 2016 +0300 mptsas: fix checks for dma mapping errors mptsas_smp_handler() checks for dma mapping errors by comparison returned address with zero, while pci_dma_mapping_error() should be used. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Acked-by: Sathya Prakash Veerichetty <sathya.prakash@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/message/fusion/mptsas.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 128f8b3d77149e9f38fb6f52931cf791155d277a Author: Alan Stern <stern@rowland.harvard.edu> Date: Fri Apr 29 15:19:56 2016 -0400 USB: EHCI: make all debugging depend on CONFIG_DYNAMIC_DEBUG The debugging facilities in ehci-dbg.c follow an uneven pattern. Some of them are protected by "#ifdef CONFIG_DYNAMIC_DEBUG" and some aren't, presumably in the hope of having some of the debugging output available in any configuration. This leads to build problems when dynamic debugging isn't configured. Rather than try to keep this complicated state of affairs, let's just make everything dependent on CONFIG_DYNAMIC_DEBUG. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Tested-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/ehci-dbg.c | 86 ++++++++++++++++++--------------------------- 1 file changed, 34 insertions(+), 52 deletions(-) commit 442ee366bec3cbdaf5794e80f803d87c5787c5d8 Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Fri Apr 29 12:34:13 2016 +0200 usb: usbip: Avoid NULL pointer dereference in case of error One line above we have checked that udc is NULL so we shouldn't dereference it while printing error message. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2a7a10b86c125fd3410bb975e8515ac5dddc3238 Author: Igor Kotrasinski <i.kotrasinsk@gmail.com> Date: Fri Apr 29 13:41:24 2016 +0200 usbip: vudc: make dev_desc attribute binary We read a struct usb_device_descriptor from it, so make it an actual binary attribute. Signed-off-by: Igor Kotrasinski <i.kotrasinsk@gmail.com> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Tested-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_sysfs.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) commit 0c1849a8c7af652c92ad0265a7ca5934fd773c69 Author: Heikki Krogerus <heikki.krogerus@linux.intel.com> Date: Thu Apr 21 15:43:40 2016 +0300 usb: Add driver for UCSI USB Type-C Connector System Software Interface (UCSI) is specification that defines the registers and data structures that can be used to control USB Type-C ports on a system. UCSI is used on several Intel Broxton SoC based platforms. Things that UCSI can be used to control include at least USB Data Role swapping, Power Role swapping and controlling of Alternate Modes on top of providing general details about the port and the partners that are attached to it. The initial purpose of the UCSI driver is to make sure USB is in host mode on desktop and server systems that are USB dual role capable, and provide UCSI interface. The goal is to integrate the driver later to an USB Type-C framework for Linux kernel, and at the same time add support for more extensive USB Type-C port control that UCSI offers, for example data role swapping, power role swapping, Alternate Mode control etc. The UCSI specification is public can be obtained from here: http://www.intel.com/content/www/us/en/io/universal-serial-bus/usb-type-c-ucsi-spec.html Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/misc/Kconfig | 26 +++ drivers/usb/misc/Makefile | 1 + drivers/usb/misc/ucsi.c | 478 ++++++++++++++++++++++++++++++++++++++++++++++ drivers/usb/misc/ucsi.h | 215 +++++++++++++++++++++ 4 files changed, 720 insertions(+) commit 904d1857ad09b43f514897dd42daffe200d1ca50 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri Apr 29 18:11:54 2016 -0400 tracing: Remove unused function trace_current_buffer_lock_reserve() trace_current_buffer_lock_reserve() has no more users. Remove it. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 4 ---- kernel/trace/trace.c | 10 ---------- 2 files changed, 14 deletions(-) commit 9b9db275051cd9191e7776c4fd79ccd4318aa2dc Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri Apr 29 18:10:21 2016 -0400 tracing: Remove one use of trace_current_buffer_lock_reserve() The only user of trace_current_buffer_lock_reserve() is in the boot up self tests. Restructure the code a little to have that code use what everything else uses: trace_event_buffer_lock_reserve(). Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit f09d90864eb7cc00cadbbfd083b4eff84c167981 Author: Miroslav Benes <mbenes@suse.cz> Date: Thu Apr 28 16:34:08 2016 +0200 livepatch: make object/func-walking helpers more robust Current object-walking helper checks the presence of obj->funcs to determine the end of objs array in klp_object structure. This is somewhat fragile because one can easily forget about funcs definition during livepatch creation. In such a case the livepatch module is successfully loaded and all objects after the incorrect one are omitted. This is very confusing. Let's make the helper more robust and check also for the other external member, name. Thus the helper correctly stops on an empty item of the array. We need to have a check for obj->funcs in klp_init_object() to make it work. The same applies to a func-walking helper. As a benefit we'll check for new_func member definition during the livepatch initialization. There is no such check anywhere in the code now. [jkosina@suse.cz: fix shortlog] Signed-off-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Jessica Yu <jeyu@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> include/linux/livepatch.h | 6 ++++-- kernel/livepatch/core.c | 3 +++ 2 files changed, 7 insertions(+), 2 deletions(-) commit 33fddff24d05d71f97722cb7deec4964d39d10dc Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri Apr 29 17:44:01 2016 -0400 tracing: Have trace_buffer_unlock_commit() call the _regs version with NULL There's no real difference between trace_buffer_unlock_commit() and trace_buffer_unlock_commit_regs() except that the former passes NULL to ftrace_stack_trace() instead of regs. Have the former be a static inline of the latter which passes NULL for regs. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 11 ----------- kernel/trace/trace.h | 13 +++++++++---- 2 files changed, 9 insertions(+), 15 deletions(-) commit 879d08ec30586ade3e785fe993ba50b8c89d05ef Author: Li Bin <huawei.libin@huawei.com> Date: Mon Dec 28 16:34:07 2015 +0800 metag: ftrace: remove the misleading comment for ftrace_dyn_arch_init ftrace_dyn_arch_init no longer in kstop_machine, so remove the corresponding comment. Signed-off-by: Li Bin <huawei.libin@huawei.com> Signed-off-by: James Hogan <james.hogan@imgtec.com> arch/metag/kernel/ftrace.c | 1 - 1 file changed, 1 deletion(-) commit 5ad629a82de37cbcaffc17861e07b5ec68ab75f4 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Tue Apr 26 09:50:31 2016 -0700 Input: byd - don't wipe dynamically allocated memory twice Since memory for a private data is allocated by kzalloc() there is no need to fill it with zeroes immediately after the allocation. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/mouse/byd.c | 1 - 1 file changed, 1 deletion(-) commit 82ba0d8ba48df5442ff31ee6f62b594f062bc162 Author: Rui Teng <rui.teng@linux.vnet.ibm.com> Date: Tue Apr 26 09:45:13 2016 -0700 Input: twl4030 - fix unsafe macro definition The bitwise shift operator has lower priority than plus operator. So the values on macros should be enclosed in parentheses. For example, "(1 << 4 + 1)" means "(1 << (4 + 1))", but it is not expected by the macros. And also fix other two coding style problems reported by scripts/checkpatch.pl. Signed-off-by: Rui Teng <rui.teng@linux.vnet.ibm.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/keyboard/twl4030_keypad.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) commit 3cfef195212976032ce7bcd6b4d0b9f1e4741725 Merge: 4b2523c 45bf454 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 16:29:12 2016 -0400 Merge branch 'mlx5-aRFS' Saeed Mahameed says: ==================== Mellanox 100G mlx5 ethernet aRFS support This series adds accelerated RFS support for the mlx5e driver. I have added one patch non-related to aRFS that fixes the rtnl_lock warning mlx5 driver been getting since b7aade15485a ('vxlan: break dependency with netdev drivers') aRFS support in details: A direct TIR per RQ is now required in order to have the essential building blocks for aRFS. Today the driver has one direct TIR that forwards traffic to RQ[0] (core 0), and one indirect TIR for RSS indirection table. For that we've added one direct TIR per RQ, e.g.: TIR[i] -> RQ[i] (core i). Publicize Modify flow rule destination and reveal it in flow steering API, to have the ability to dynamically modify the destination TIR(core) for aRFS rules from the ethernet driver. Initializing CPU reverse mapping to notify upper layer on internal receive queue cpu mappings. Some design refactoring for mlx5e ethernet driver flow tables and flow steering API. Now the caller of create_flow_table can choose the level of the flow table, this way we will create the mlx5e flow tables in a reversed order and connect them as we go, we create flow table[i+1] before flow table[i] to be able to set flow table[i + 1] as a destination of flow table[i] once flow table[i] is created. also we have split the main flow table in the following manner: - From before: RX packet had to visit two flow tables until it is delivered to its receive queue: RX packet -> vlan filter flow table -> main flow table. > vlan filter will check the packet vlan field is allowed. > main flow will check if the dest mac is allowed and will check the l3/l4 headers to retrieve the RSS hash for steering the packet into its final receive queue. - Now main flow table is split into l2 dst mac steering table and ttc (traffic type classifier) table: RX packet -> vlan filter -> l2 table -> ttc table > vlan filter - same as before > L2 filter - filter packets according their destination mac address > ttc table - classify packet headers for RSS steering - L3/L4 classification rules to steer the packet according to thier headers hash - in case of none of the rules applies the packet is steered to RQ[0] After the above refactoring all left to-do is to create aRFS flow table which will manage aRFS steering rules to forward traffic to the desired RQ (core) and just connect the ttc table rules destinations to aRFS flow table. aRFS flow table in case of a miss will deliver the traffic to the core where the original ttc hash would have chosen. TTC table is not initialized and enabled until the user explicitly asks to, i.e. setting the NETIF_F_NTUPLE to ON. This way there is no need for ttc table to forward traffic to aRFS table unless required. When setting back to OFF aRFS flow table is disabled and disconnected. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 45bf454ae88414e80b80979ebb2c22bd66ea7d1b Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:42 2016 +0300 net/mlx5e: Enabling aRFS mechanism Accelerated RFS requires that ntuple filtering is enabled via ethtool and driver supports ndo_rx_flow_steer. When the ntuple filtering is enabled, we modify the l3_l4 ttc rules to point on the aRFS flow tables and when the filtering is disabled, we modify the l3_l4 ttc rules to point on the RSS TIRs. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 12 ++++ drivers/net/ethernet/mellanox/mlx5/core/en_arfs.c | 77 +++++++++++++++++++++- .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 15 +++++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 25 +++++++ 4 files changed, 127 insertions(+), 2 deletions(-) commit 18c908e477dcc94ede69323a6b876b5d8cfb40ff Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:41 2016 +0300 net/mlx5e: Add accelerated RFS support Implement ndo_rx_flow_steer ndo. A new flow steering rule will be composed from the skb 4-tuple and added to the hardware aRFS flow table. Each rule is stored in an internal hash table, if such skb 4-tuple rule already exists we update the corresponding hardware steering rule with the new destination. For garbage collection rps_may_expire_flow will be invoked for a limited amount of old rules upon any ndo_rx_flow_steer invocation. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 10 + drivers/net/ethernet/mellanox/mlx5/core/en_arfs.c | 427 +++++++++++++++++++++- 2 files changed, 436 insertions(+), 1 deletion(-) commit 1cabe6b0965ec067ac60e8f182f16d479a3b9a5c Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:40 2016 +0300 net/mlx5e: Create aRFS flow tables Create the following four flow tables for aRFS usage: 1. IPv4 TCP - filtering 4-tuple of IPv4 TCP packets. 2. IPv6 TCP - filtering 4-tuple of IPv6 TCP packets. 3. IPv4 UDP - filtering 4-tuple of IPv4 UDP packets. 4. IPv6 UDP - filtering 4-tuple of IPv6 UDP packets. Each flow table has two flow groups: one for the 4-tuple filtering (full match) and the other contains * rule for miss rule. Full match rule means a hit for aRFS and packet will be forwarded to the dedicated RQ/Core, miss rule packets will be forwarded to default RSS hashing. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/Makefile | 1 + drivers/net/ethernet/mellanox/mlx5/core/en.h | 41 ++++ drivers/net/ethernet/mellanox/mlx5/core/en_arfs.c | 251 ++++++++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/en_fs.c | 23 +- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 8 +- drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 3 +- 6 files changed, 313 insertions(+), 14 deletions(-) commit 5a7b27eb9cf3986f487469b57a3a41286d2e7100 Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:39 2016 +0300 net/mlx5: Initializing CPU reverse mapping Allocating CPU rmap and add entry for each IRQ. CPU rmap is used in aRFS to get the RX queue number of the RX completion interrupts. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 3 +++ drivers/net/ethernet/mellanox/mlx5/core/main.c | 18 ++++++++++++++++++ include/linux/mlx5/driver.h | 3 +++ 3 files changed, 24 insertions(+) commit 33cfaaa8f36ffbee9ad259264334325b5449f5fe Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:38 2016 +0300 net/mlx5e: Split the main flow steering table Currently, the main flow table is used for two purposes: One is to do mac filtering and the other is to classify the packet l3-l4 header in order to steer the packet to the right RSS TIR. This design is very complex, for each configured mac address we have to add eleven rules (rule for each traffic type), the same if the device is put to promiscuous/allmulti mode. This scheme isn't scalable for future features like aRFS. In order to simplify it, the main flow table is split to two flow tables: 1. l2 table - filter the packet dmac address, if there is a match we forward to the ttc flow table. 2. TTC (Traffic Type Classifier) table - classify the traffic type of the packet and steer the packet to the right TIR. In this new design, when new mac address is added, the driver adds only one flow rule instead of eleven. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 42 +- drivers/net/ethernet/mellanox/mlx5/core/en_fs.c | 979 ++++++++++------------ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 2 +- 4 files changed, 462 insertions(+), 563 deletions(-) commit acff797cd187402d73cf9f290531a41250613294 Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:37 2016 +0300 net/mlx5e: Refactor mlx5e flow steering structs Slightly refactor and re-order the flow steering structs, tables and data-bases for better self-containment and flexibility to add more future steering phases (tables/rules/data bases) e.g: aRFS. Changes: 1. Move the vlan DB and address DB into their table structs. 2. Rename steering table structs to unique format: mlx5e_*_table, e.g: mlx5e_vlan_table. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 73 +++++---- drivers/net/ethernet/mellanox/mlx5/core/en_fs.c | 186 +++++++++++----------- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 8 +- drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 45 +++--- drivers/net/ethernet/mellanox/mlx5/core/en_tc.h | 2 +- 5 files changed, 160 insertions(+), 154 deletions(-) commit 13de6c106cdd68e43b6c282c17c110e8f7905872 Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:36 2016 +0300 net/mlx5: Support different attributes for priorities in namespace Currently, namespace could be initialized only with priorities with the same attributes. Add support to initialize namespace with priorities with different attributes(e.g. different number of levels). Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 31 ++++++++++++++--------- 1 file changed, 19 insertions(+), 12 deletions(-) commit d63cd28608bb563d52e62990fa01c016e8dbdb75 Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:35 2016 +0300 net/mlx5: Add user chosen levels when allocating flow tables Currently, consumers of the flow steering infrastructure can't choose their own flow table levels and are limited to one flow table per level. This just waste levels. Instead, we introduce here the possibility to use multiple flow tables in a level. The user is free to connect these flow tables, while following the rule (FTEs in FT of level x could only point to FTs of level y where y > x). In addition this patch switch the order of the create/destroy flow tables of the NIC(vlan and main). Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/infiniband/hw/mlx5/main.c | 3 +- drivers/net/ethernet/mellanox/mlx5/core/en_fs.c | 30 ++++++----- drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 3 +- drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 66 +++++++++++++++-------- include/linux/mlx5/fs.h | 6 ++- 6 files changed, 70 insertions(+), 40 deletions(-) commit a257b94a18f7eb60bbe9b5fd415d208ac71d49ea Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:34 2016 +0300 net/mlx5: Set number of allowed levels in priority Refactors the flow steering namespace creation, by changing the name num_fts to num_levels. When new flow table is created, the driver assign new level to this flow table therefore the meaning is equivalent. Since downstream patches will introduce the ability to create more than one flow table per level, the name num_fts is no longer accurate. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 61 ++++++++++++----------- drivers/net/ethernet/mellanox/mlx5/core/fs_core.h | 2 +- 2 files changed, 33 insertions(+), 30 deletions(-) commit d745098cedb3f5c6a554796d4a3a505abd4ebaa6 Author: Maor Gottlieb <maorg@mellanox.com> Date: Fri Apr 29 01:36:33 2016 +0300 net/mlx5: Introduce modify flow rule destination This API is used for modifying the flow rule destination. This is needed for modifying the pointed flow table by the traffic type classifier rules to point on the aRFS tables. Signed-off-by: Maor Gottlieb <maorg@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 4 ++-- include/linux/mlx5/fs.h | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) commit 1da366964ec907fccdea0339d81c2e9ef3d803f8 Author: Tariq Toukan <tariqt@mellanox.com> Date: Fri Apr 29 01:36:32 2016 +0300 net/mlx5e: Direct TIR per RQ Introduce new TIRs for direct access per RQ. Now we have 2 available kinds of TIRs: - indirect TIR per traffic type, each points to one RQT (RSS RQT) same as before. - New direct TIR per RQ, each points to RQT with a size of one that forwards packets to that RQ only. Driver will open max channels (num cores) direct TIRs by default, they will be filled with the actual RQs once channels are allocated. Needed for downstream aRFS and ethtool direct steering functionalities. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 21 +- .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 9 +- drivers/net/ethernet/mellanox/mlx5/core/en_fs.c | 4 +- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 295 ++++++++++++--------- 4 files changed, 191 insertions(+), 138 deletions(-) commit 01a14098d3374e1b931d605da666300ee248d3d9 Author: Matthew Finlay <matt@mellanox.com> Date: Fri Apr 29 01:36:31 2016 +0300 net/mlx5e: Call vxlan_get_rx_port() with rtnl lock Hold the rtnl lock when calling vxlan_get_rx_port(). Fixes: b7aade15485a ("vxlan: break dependency with netdev drivers") Signed-off-by: Matthew Finlay <matt@mellanox.com> Reported-by: Alexander Duyck <alexander.duyck@gmail.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 0b9a29add43273e64ef45472e08d38116fee1d82 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sun Apr 24 14:30:16 2016 -0700 arm: Use _rcuidle tracepoint to allow use from idle Testing on ARM encountered the following pair of lockdep-RCU splats: ------------------------------------------------------------------------ =============================== [ INFO: suspicious RCU usage. ] 4.6.0-rc4-next-20160422 #1 Not tainted ------------------------------- include/trace/events/power.h:328 suspicious rcu_dereference_check() usage! other info that might help us debug this: RCU used illegally from idle CPU! rcu_scheduler_active = 1, debug_locks = 0 RCU used illegally from extended quiescent state! no locks held by swapper/0/0. stack backtrace: CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.6.0-rc4-next-20160422 #1 Hardware name: Generic OMAP3-GP (Flattened Device Tree) [<c010f55c>] (unwind_backtrace) from [<c010b64c>] (show_stack+0x10/0x14) [<c010b64c>] (show_stack) from [<c047acbc>] (dump_stack+0xa8/0xe0) [<c047acbc>] (dump_stack) from [<c012bc10>] (pwrdm_set_next_pwrst+0xf8/0x1cc) [<c012bc10>] (pwrdm_set_next_pwrst) from [<c01269fc>] (omap3_enter_idle_bm+0x1b8/0x1e8) [<c01269fc>] (omap3_enter_idle_bm) from [<c05fa0b8>] (cpuidle_enter_state+0x84/0x408) [<c05fa0b8>] (cpuidle_enter_state) from [<c0182c1c>] (cpu_startup_entry+0x1c8/0x3f0) [<c0182c1c>] (cpu_startup_entry) from [<c0b00c20>] (start_kernel+0x354/0x3cc) ------------------------------------------------------------------------ [<c010f55c>] (unwind_backtrace) from [<c010b64c>] (show_stack+0x10/0x14) [<c010b64c>] (show_stack) from [<c047ac3c>] (dump_stack+0xa8/0xe0) [<c047ac3c>] (dump_stack) from [<c012c340>] (_pwrdm_state_switch+0x188/0x32c) [<c012c340>] (_pwrdm_state_switch) from [<c012c4f0>] (_pwrdm_post_transition_cb+0xc/0x14) [<c012c4f0>] (_pwrdm_post_transition_cb) from [<c012ba74>] (pwrdm_for_each+0x30/0x5c) [<c012ba74>] (pwrdm_for_each) from [<c012c72c>] (pwrdm_post_transition+0x24/0x30) [<c012c72c>] (pwrdm_post_transition) from [<c012548c>] (omap_sram_idle+0xfc/0x240) [<c012548c>] (omap_sram_idle) from [<c0126934>] (omap3_enter_idle_bm+0xf0/0x1e8) [<c0126934>] (omap3_enter_idle_bm) from [<c05fa038>] (cpuidle_enter_state+0x84/0x408) [<c05fa038>] (cpuidle_enter_state) from [<c0182b90>] (cpu_startup_entry+0x1c8/0x3f0) [<c0182b90>] (cpu_startup_entry) from [<c0b00c20>] (start_kernel+0x354/0x3cc) ------------------------------------------------------------------------ These are caused by event tracing from the idle loop, and they were exposed by commit 293e2421fe25 ("rcu: Remove superfluous versions of rcu_read_lock_sched_held()"), which suppressed some false negatives. The current commit therefore adds the _rcuidle suffix to make RCU aware of this implicit use of RCU by event tracing, thus preventing both splats. Reported-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Tested-by: Guenter Roeck <linux@roeck-us.net> Tested-by: Tony Lindgren <tony@atomide.com> Cc: Russell King <linux@arm.linux.org.uk> Reviewed-by: Steven Rostedt <rostedt@goodmis.org> Cc: <linux-omap@vger.kernel.org> Cc: <linux-arm-kernel@lists.infradead.org> arch/arm/mach-omap2/powerdomain.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 4b2523c180c8e5e8e02b2d518d7b1dcb4c9d98de Merge: f4b05d2 2dd355a Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 16:23:03 2016 -0400 Merge branch 'enc28j60-small-improvements' Michael Heimpold says: ==================== net: ethernet: enc28j60: small improvements This series of two patches adds the following improvements to the driver: 1) Rework the central SPI read function so that it is compatible with SPI masters which only support half duplex transfers. 2) Add a device tree binding for the driver. Changelog: v3: * renamed and improved binding documentation as suggested by Rob Herring v2: * took care of Arnd Bergmann's review comments - allow to specify MAC address via DT - unconditionally define DT id table * increased the driver version minor number * driver author's email address bounces, removed from address list v1: * Initial submission ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 2dd355a007e44960ec049c75920ddb6778fec9ee Author: Michael Heimpold <mhei@heimpold.de> Date: Thu Apr 28 22:06:15 2016 +0200 net: ethernet: enc28j60: add device tree support The following patch adds the required match table for device tree support (and while at, fix the indent). It's also possible to specify the MAC address in the DT blob. Also add the corresponding binding documentation file. Signed-off-by: Michael Heimpold <mhei@heimpold.de> Signed-off-by: David S. Miller <davem@davemloft.net> .../devicetree/bindings/net/microchip,enc28j60.txt | 59 ++++++++++++++++++++++ drivers/net/ethernet/microchip/enc28j60.c | 20 ++++++-- 2 files changed, 76 insertions(+), 3 deletions(-) commit 2957a28a0e874aea0f734e2897b27f669502a970 Author: Michael Heimpold <mhei@heimpold.de> Date: Thu Apr 28 22:06:14 2016 +0200 net: ethernet: enc28j60: support half-duplex SPI controllers The current spi_read_buf function fails on SPI host masters which are only half-duplex capable. Splitting the Tx and Rx part solves this issue. Tested on Raspberry Pi (full duplex) and I2SE Duckbill (half duplex). Signed-off-by: Michael Heimpold <mhei@heimpold.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/microchip/enc28j60.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit a9fe48dcde88fd48e210e4280f19cb9300ec9112 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri Apr 29 16:12:39 2016 -0400 tracing: Remove unused function trace_current_buffer_discard_commit() The function trace_current_buffer_discard_commit() has no callers, remove it. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 2 -- kernel/trace/trace.c | 8 -------- 2 files changed, 10 deletions(-) commit fa66ddb870ca022342fe6d1312ef76d2f7233a1d Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Thu Apr 28 12:04:13 2016 -0400 tracing: Move trace_buffer_unlock_commit{_regs}() to local header The functions trace_buffer_unlock_commit() and the _regs() version are only used within the kernel/trace directory. Move them to the local header and remove the export as well. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 9 --------- kernel/trace/trace.c | 2 -- kernel/trace/trace.h | 10 ++++++++++ 3 files changed, 10 insertions(+), 11 deletions(-) commit 9cbb1506ab2db987c160e7fc50665bf47b5b6fa1 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Wed Apr 27 11:09:42 2016 -0400 tracing: Fold filter_check_discard() into its only user The function filter_check_discard() is small and only called by one user, its code can be folded into that one caller and make the code a bit less comlplex. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 13 ------------- kernel/trace/trace.h | 13 ++++++------- 2 files changed, 6 insertions(+), 20 deletions(-) commit f4b05d27ec6b032ca504591e2a157b058b6f172f Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Date: Thu Apr 28 17:59:28 2016 +0200 net: constify is_skb_forwardable's arguments is_skb_forwardable is not supposed to change anything so constify its arguments Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 3 ++- net/core/dev.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) commit 92aff96ac315a713b14c7e4f7b2e84fb3dc9ce16 Merge: ac1f74a 96d934c Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 16:09:45 2016 -0400 Merge branch 'ppp-rtnetlink' Guillaume Nault says: ==================== ppp: add rtnetlink support PPP devices lack the ability to be customised at creation time. In particular they can't be created in a given netns or with a particular name. Moving or renaming the device after creation is possible, but creates undesirable transient effects on servers where PPP devices are constantly created and removed, as users connect and disconnect. Implementing rtnetlink support solves this problem. The rtnetlink handlers implemented in this series are minimal, and can only replace the PPPIOCNEWUNIT ioctl. The rest of PPP ioctls remains necessary for any other operation on channels and units. It is perfectly possible to mix PPP devices created by rtnl and by ioctl(PPPIOCNEWUNIT). Devices will behave in the same way. mutex_trylock() is used to resolve the locking issue wrt. locking dependency between rtnl_lock() and ppp_mutex (see ppp_nl_newlink() in patch #2). A user visible difference brought by this series is that old PPP interfaces (those created with ioctl(PPPIOCNEWUNIT)), can now be removed by "ip link del", just like new rtnl based PPP devices. Changes since v3: - Rebase on net-next. - Not an RFC anymore. Changes since v2: - Define ->rtnl_link_ops for ioctl based PPP devices, so they can handle rtnl messages just like rtnl based ones (suggested by Stephen Hemminger). - Move back to original lock ordering between ppp_mutex and rtnl_lock to simplify patch series. Handle lock inversion issue using mutex_trylock() (suggested by Stephen Hemminger). - Do file descriptor lookup directly in ppp_nl_newlink(), to simplify ppp_dev_configure(). Changes since v1: - Rebase on net-next. - Invert locking order wrt. ppp_mutex and rtnl_lock and protect file->private_data with ppp_mutex. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 96d934c70db6e1bc135600c57da1285eaf7efb26 Author: Guillaume Nault <g.nault@alphalink.fr> Date: Thu Apr 28 17:55:30 2016 +0200 ppp: add rtnetlink device creation support Define PPP device handler for use with rtnetlink. The only PPP specific attribute is IFLA_PPP_DEV_FD. It is mandatory and contains the file descriptor of the associated /dev/ppp instance (the file descriptor which would have been used for ioctl(PPPIOCNEWUNIT) in the ioctl-based API). The PPP device is removed when this file descriptor is released (same behaviour as with ioctl based PPP devices). PPP devices created with the rtnetlink API behave like the ones created with ioctl(PPPIOCNEWUNIT). In particular existing ioctls work the same way, no matter how the PPP device was created. The rtnl callbacks are also assigned to ioctl based PPP devices. This way, rtnl messages have the same effect on any PPP devices. The immediate effect is that all PPP devices, even ioctl-based ones, can now be removed with "ip link del". A minor difference still exists between ioctl and rtnl based PPP interfaces: in the device name, the number following the "ppp" prefix corresponds to the PPP unit number for ioctl based devices, while it is just an unrelated incrementing index for rtnl ones. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ppp/ppp_generic.c | 115 ++++++++++++++++++++++++++++++++++++++++-- include/uapi/linux/if_link.h | 8 +++ 2 files changed, 120 insertions(+), 3 deletions(-) commit 7d9f0b48746d37e4381efc02da27535a0a1bac43 Author: Guillaume Nault <g.nault@alphalink.fr> Date: Thu Apr 28 17:55:28 2016 +0200 ppp: define reusable device creation functions Move PPP device initialisation and registration out of ppp_create_interface(). This prepares code for device registration with rtnetlink. While there, simplify the prototype of ppp_create_interface(): * Since ppp_dev_configure() takes care of setting file->private_data, there's no need to return a ppp structure to ppp_unattached_ioctl() anymore. * The unit parameter is made read/write so that ppp_create_interface() can tell which unit number has been assigned. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ppp/ppp_generic.c | 206 ++++++++++++++++++++++++------------------ 1 file changed, 118 insertions(+), 88 deletions(-) commit 03d85a63ee3e2d3a43460f936b86334b32f88c89 Merge: 3521ba1 ca7ce82 Author: Ingo Molnar <mingo@kernel.org> Date: Fri Apr 29 21:37:40 2016 +0200 Merge tag 'perf-core-for-mingo-20160429' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Allow generate timestamped suffixed multiple perf.data files upon receiving SIGUSR2 in 'perf record', to slice a long running monitoring session, allowing to dump uninteresting sessions (Wang Nan) - Handle ENOMEM for perf_event_max_stack + PERF_SAMPLE_CALLCHAIN in perf_evsel__open_strerror(), showing a more informative message when the request call stack depth can't be allocated by the kernel (Arnaldo Carvalho de Melo) Infrastructure changes: - Use strbuf for making strings in 'perf probe' (Masami Hiramatsu) - Do not use sizeof on pointer type, not a problem since its a pointer to pointer, fix none the less. Found by Coccinelle (Vaishali Thakkar) Cleanups: - Fix for Coverity found issues in the bpf feature build test (Florian Fainelli) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit ac1f74a7fc197660f26b59395b3fd2468f59f5dc Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Thu Apr 28 15:56:45 2016 +0200 net: ethernet: stmmac: update MDIO support for GMAC4 On new GMAC4 IP, MAC_MDIO_address register has been updated, and bitmaps changed. This patch takes into account those changes. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 102 +++++++++++++++++++++- 1 file changed, 98 insertions(+), 4 deletions(-) commit 65226ef8ea167c773de4c5b31a0fd3cb3a08f5b4 Author: Jiri Benc <jbenc@redhat.com> Date: Thu Apr 28 16:36:30 2016 +0200 vxlan: fix initialization with custom link parameters Commit 0c867c9bf84c ("vxlan: move Ethernet initialization to a separate function") changed initialization order and as an unintended result, when the user specifies additional link parameters (such as IFLA_ADDRESS) while creating vxlan interface, those are overwritten by vxlan_ether_setup later. It's necessary to call ether_setup from withing the ->setup callback. That way, the correct parameters are set by rtnl_create_link later. This is done also for VXLAN-GPE, as we don't know the interface type yet at that point, and changed to the correct interface type later. Fixes: 0c867c9bf84c ("vxlan: move Ethernet initialization to a separate function") Reported-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: Jiri Benc <jbenc@redhat.com> Tested-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 638af1787357f2f8bbb5006d4df0693afd3b805b Merge: c23846c bdefbbf Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 14:26:32 2016 -0400 Merge branch 'samples-bpf-user-experience' Jesper Dangaard Brouer says: ==================== samples/bpf: Improve user experience It is a steep learning curve getting started with using the eBPF examples in samples/bpf/. There are several dependencies, and specific versions of these dependencies. Invoking make in the correct manor is also slightly obscure. This patchset cleanup, document and hopefully improves the first time user experience with the eBPF samples directory by auto-detecting certain scenarios. V4: - Address Naveen's nitpicks - Handle/fail if extra args are passed in LLC or CLANG (David Laight) V3: - Add Alexei's ACKs - Remove README paragraph about LLVM experimental BPF target as it only existed between LLVM version 3.6 to 3.7. V2: - Adjusted recommend minimum versions to 3.7.1 - Included clang build instructions - New patch adding CLANG variable and validation of command ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bdefbbf2ecff6efcd253767179a60961aebed9dc Author: Jesper Dangaard Brouer <brouer@redhat.com> Date: Thu Apr 28 14:21:14 2016 +0200 samples/bpf: like LLC also verify and allow redefining CLANG command Users are likely to manually compile both LLVM 'llc' and 'clang' tools. Thus, also allow redefining CLANG and verify command exist. Makefile implementation wise, the target that verify the command have been generalized. Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 25 ++++++++++++++----------- samples/bpf/README.rst | 6 +++--- 2 files changed, 17 insertions(+), 14 deletions(-) commit b62a796c109ca0be3e49de620a8ea8248412446d Author: Jesper Dangaard Brouer <brouer@redhat.com> Date: Thu Apr 28 14:21:09 2016 +0200 samples/bpf: allow make to be run from samples/bpf/ directory It is not intuitive that 'make' must be run from the top level directory with argument "samples/bpf/" to compile these eBPF samples. Introduce a kbuild make file trick that allow make to be run from the "samples/bpf/" directory itself. It basically change to the top level directory and call "make samples/bpf/" with the "/" slash after the directory name. Also add a clean target that only cleans this directory, by taking advantage of the kbuild external module setting M=$PWD. Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 8 ++++++++ samples/bpf/README.rst | 3 +++ 2 files changed, 11 insertions(+) commit 1c97566d515de2ef66873e30288b150f0154f3b3 Author: Jesper Dangaard Brouer <brouer@redhat.com> Date: Thu Apr 28 14:21:04 2016 +0200 samples/bpf: add a README file to get users started Getting started with using examples in samples/bpf/ is not straightforward. There are several dependencies, and specific versions of these dependencies. Just compiling the example tool is also slightly obscure, e.g. one need to call make like: make samples/bpf/ Do notice the "/" slash after the directory name. Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/README.rst | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) commit 7b01dd5793394ee2ef47c328b28c30f5c01107c9 Author: Jesper Dangaard Brouer <brouer@redhat.com> Date: Thu Apr 28 14:20:58 2016 +0200 samples/bpf: Makefile verify LLVM compiler avail and bpf target is supported Make compiling samples/bpf more user friendly, by detecting if LLVM compiler tool 'llc' is available, and also detect if the 'bpf' target is available in this version of LLVM. Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 6ccfba75d3137efc3b665a337b946fd6df1162b9 Author: Jesper Dangaard Brouer <brouer@redhat.com> Date: Thu Apr 28 14:20:53 2016 +0200 samples/bpf: add back functionality to redefine LLC command It is practical to be-able-to redefine the location of the LLVM command 'llc', because not all distros have a LLVM version with bpf target support. Thus, it is sometimes required to compile LLVM from source, and sometimes it is not desired to overwrite the distros default LLVM version. This feature was removed with 128d1514be35 ("samples/bpf: Use llc in PATH, rather than a hardcoded value"). Add this features back. Note that it is possible to redefine the LLC on the make command like: make samples/bpf/ LLC=~/git/llvm/build/bin/llc Fixes: 128d1514be35 ("samples/bpf: Use llc in PATH, rather than a hardcoded value") Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit c23846c143e81963096e922d91b7b00284c22bed Merge: 482f13a ae7b757 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 13:41:47 2016 -0400 Merge branch 'cxgb4-mbox-cmd-logging' Hariprasad Shenai says: ==================== cxgb4/cxgb4vf: add support for mbox cmd logging This patch series adds support for logging mailbox commands and replies for debugging purpose for both PF and VF driver. This patch series has been created against net-next tree and includes patches on cxgb4 and cxgb4vf driver. We have included all the maintainers of respective drivers. Kindly review the change and let us know in case of any review comments. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit ae7b7576220560617e903910c6307e13ec93b279 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Thu Apr 28 13:23:19 2016 +0530 cxgb4vf: Add support to enable logging of firmware mailbox commands for VF Add new /sys/kernel/debug/ support to dump firmware mailbox commands and replies for debugging purpose. Based on original work by Casey Leedom <leedom@chelsio.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4vf/adapter.h | 4 + .../net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c | 112 +++++++++++++++++++++ drivers/net/ethernet/chelsio/cxgb4vf/t4vf_common.h | 29 ++++++ drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c | 72 ++++++++----- 4 files changed, 192 insertions(+), 25 deletions(-) commit 7f080c3f2ff091c095248f670bb34308f141ff7a Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Thu Apr 28 13:23:18 2016 +0530 cxgb4: Add support to enable logging of firmware mailbox commands Add new /sys/kernel/debug/ support to dump a firmware mailbox command issued and replies for debugging purpose. Based on original work by Casey Leedom <leedom@chelsio.com> Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 32 +++++++ drivers/net/ethernet/chelsio/cxgb4/cxgb4_debugfs.c | 99 ++++++++++++++++++++++ drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 12 +++ drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 69 ++++++++++----- 4 files changed, 192 insertions(+), 20 deletions(-) commit 482f13aa5e13819acad0ff4fb94f6fb0364522f0 Merge: 494e848 ea99102 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 29 13:39:04 2016 -0400 Merge branch 'hns-props' Yisen Zhuang says: ==================== net: hns: update DT properties according to Rob's comments There are some inappropriate properties definition in hns DT. We update the definition according to Rob's review comments and fix some typos in binding. For more details, please see individual patches. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit ea991027efcb2acf801633190bc2f35ad1eb78c2 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Thu Apr 28 15:09:04 2016 +0800 dts: hisi: update hns dst for changing property port-id to reg Indexes should generally be avoided. This patch changes property port-id to reg in dsaf port node. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/boot/dts/hisilicon/hip05_hns.dtsi | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit a1ecde2c6f00825e3a6d90dc774cddc18cb0e247 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Thu Apr 28 15:09:03 2016 +0800 Documentation: Bindings: Update DT binding for hns dsaf node This patch changes property port-id to reg in dsaf port node, removes property cpld-ctrl-reg, and fixes some typos. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../devicetree/bindings/net/hisilicon-hns-dsaf.txt | 28 ++++++++++------------ 1 file changed, 13 insertions(+), 15 deletions(-) commit 0211b8fb5dd750357b3113a7c40b879c4a055a98 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Thu Apr 28 15:09:02 2016 +0800 net: hns: change port-id property to reg property in dsaf port node Indexes should generally be avoided. So we use reg rather than port-id to index ports. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 1ffdfac99f36555b66c5b9d979c855a9c1a4503b Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Thu Apr 28 15:09:01 2016 +0800 net: hns: remove cpld-ctrl-reg and add cell in the cpld-syscon property Because cpld-ctrl-reg property is offset base on cpld-syscon property, we make it as a cell in the cpld-syscon property. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 26 ++++++++++++----------- 1 file changed, 14 insertions(+), 12 deletions(-) commit af4981fc59a6e1cee542d21e339176e6a5b74757 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Fri Apr 15 15:01:46 2016 -0400 staging: rtl8723au: Add warning about this driver being deprecated This driver is deprecated and superseded by rtl8xxxu. It will be removed in a future kernel release. Add a warning to Kconfig and at device init time to notify users and allow them time to switch over. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/Kconfig | 7 +++++-- drivers/staging/rtl8723au/os_dep/usb_intf.c | 5 +++++ 2 files changed, 10 insertions(+), 2 deletions(-) commit 823ecdd684e28d4e71686fc8787b6d31b1223382 Author: Jim Lodes <jim.lodes@garmin.com> Date: Mon Apr 25 11:08:10 2016 -0500 ASoC: davinci-mcasp: Fix overwriting of ahclkx The mcasp davinci_mcasp_set_dai_fmt function was overriding ahclkx input/output status that had already been set by the davinci_mcasp_set_sysclk function. This commit removes clearing of the ahclkx input/output status from davinci_mcasp_set_dai_fmt. Signed-off-by: Jim Lodes <jim.lodes@garmin.com> Signed-off-by: J.D. Schroeder <jay.schroeder@garmin.com> Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/davinci-mcasp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1051550e9d2d3550e7c17cd563b908638833979d Author: Axel Lin <axel.lin@ingics.com> Date: Fri Apr 29 13:39:38 2016 +0800 spi: st-ssc4: Fix missing spi_master_put in spi_st_probe error paths Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-st-ssc4.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 83fefd2d5bec94de765305d44633c42371360a2a Author: Axel Lin <axel.lin@ingics.com> Date: Fri Apr 29 13:38:41 2016 +0800 spi: st-ssc4: Allow compile test build There is no build dependency for this driver, so enable COMPILE_TEST to get better build coverage. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b085c6129a8cabdad9c625fae56d9d3f2977808e Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:11:56 2016 +0300 spi: omap2-mcspi: Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-omap2-mcspi.c | 83 ++++++++++--------------------------------- 1 file changed, 18 insertions(+), 65 deletions(-) commit fe5fd2540947a6c584e70f1249007dd636e62d78 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Apr 29 16:10:22 2016 +0300 spi: davinci: Use dma_request_chan() for requesting DMA channel With the new dma_request_chan() the client driver does not need to look for the DMA resource and it does not need to pass filter_fn anymore. By switching to the new API the driver can now support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-davinci.c | 76 +++++++++++++++-------------------------------- 1 file changed, 24 insertions(+), 52 deletions(-) commit fe42f031765e2cfaf5363b52664a634a4fe19c1a Author: Thierry Reding <treding@nvidia.com> Date: Tue Apr 26 19:01:45 2016 +0200 ARM: multi_v7: Enable Tegra XUSB controller in defconfig Enable the XUSB pad controller and XUSB controller (implementing an XHCI interface) in the multi_v7 default configuration. The XUSB pad controller is built-in because it is needed by PCIe, which in turn provides the onboard ethernet used for network boot on a Jetson TK1. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/configs/multi_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 62a4e6824e35fcebf19937319305cb8474b4d857 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 21 11:52:14 2016 +0200 ARM: tegra: Enable XUSB controller in defconfig Enable the XUSB pad controller and XUSB controller (implementing an XHCI interface) in the Tegra default configuration. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/configs/tegra_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit a121d179563e773e682448bf06a1842662e6440f Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:26:01 2016 +0100 drm/exynos/mixer: enable HDMI-PHY before configuring MIXER According to documentation HDMI-PHY must be on prior to MIXER configuration. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_mixer.c | 4 ++++ 1 file changed, 4 insertions(+) commit c60230eba23552bc9caadc0ef42bde27b8a5e169 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:26:00 2016 +0100 drm/exynos/decon5433: enable HDMI-PHY before configuring DECON According to documentation and tests HDMI-PHY must be on prior to MIXER configuration. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 4 ++++ 1 file changed, 4 insertions(+) commit f26b9343f582f44ec920474d71b4b2220b1ed9a8 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:25:58 2016 +0100 drm/exynos: add support for pipeline clock to the framework Components belonging to the same pipeline often requires synchronized clocks. Such clocks are sometimes provided by external clock controller, but they can be also provided by pipeline components. In latter case there should be a way to access them from another component belonging to the same pipeline. This is the case of: - DECON,FIMD -> HDMI and HDMI-PHY clock, - FIMD -> DP and DP clock in FIMD. The latter case has been solved by clock_enable callback in exynos_drm_crtc_ops. This solutin will not work with HDMI path as in this case clock is provided by encoder. This patch provides more generic solution allowing to register pipeline clock during initialization in exynos_drm_crtc structure. This way the clock will be easily accessible from both components. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_drv.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 2701932899e91d92fcc41111b6eb6d37cc09e825 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:25:57 2016 +0100 drm/exynos: add helper to get crtc from pipe The helper abstracts out conversion from pipeline to crtc. Currently it is used in two places, but there will be more uses in next patches. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_crtc.c | 10 ++++------ drivers/gpu/drm/exynos/exynos_drm_drv.h | 8 ++++++++ 2 files changed, 12 insertions(+), 6 deletions(-) commit 3d30ec54c928c5920ddf13fbbd677d7c76b8cb53 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:18 2016 +0100 drm/exynos/decon5433: do not protect window in plane disable decon_atomic_begin and decon_atomic_flush protects all windows already. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 5 ----- 1 file changed, 5 deletions(-) commit e87b3c6248071d99a48377a4c70932a035bf84f9 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:17 2016 +0100 drm/exynos/decon5433: reset decon on start Resetting IP at starting ensures that DECON will be in known state regardless of changes by bootloader. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 2 ++ 1 file changed, 2 insertions(+) commit 92ead494f629f2902ad420ea2aa991542509b4e3 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:16 2016 +0100 drm/exynos/decon5433: fix DECON standalone update DECON should be updated after un-protecting windows and after changing output parameters, otherwise image is not displayed in case of HDMI path. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 11f3022e3b9535b5d4ada29467ee6b2bcbaffc10 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:15 2016 +0100 drm/exynos/hdmi: remove registry dump HDMI registry dump unnecessary spoils console and is not very helpful. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 263 ----------------------------------- 1 file changed, 263 deletions(-) commit 69f88877c3817b712f0d63721a4c1fa9d5678388 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:14 2016 +0100 drm/exynos/hdmi: add core reset code To ensure HDMI-PHY reprogramming will not affect HDMI the latter should be reset. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 4 ++++ 1 file changed, 4 insertions(+) commit 5dd45e2cd2470dc91c1af8548eaa266796d9cf8c Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:13 2016 +0100 drm/exynos/hdmi: add PHY power off signal handling HDMI-PHY power off bit defaults to 0 in older HDMI versions. In case of Exynos5433 it defaults to 1. To make code consistent across all versions this bit is always unset/set in power on/off sequences. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 4 ++++ 1 file changed, 4 insertions(+) commit 4677f51ade432987f01062abad9e4cf60fd33f7d Author: Andrzej Hajda <a.hajda@samsung.com> Date: Wed Mar 23 14:15:12 2016 +0100 drm/exynos/hdmi: fix PHY configuration sequence Proper PHY configuration should be as follow: 1. set HDMI clock parents to OSCCLK. 2. reconfigure PHY. 3. set HDMI clock parents to PHY. 4. wait for PLL stabilization. The patch fixes it and consolidates the code. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 50ec220eb4e3c90b3d7d40c679e19a0b61de162c Author: Andrzej Hajda <a.hajda@samsung.com> Date: Mon Oct 26 12:59:56 2015 +0100 dt-bindings: video: exynos5433-decon: add bindings for DECON-TV DECON-TV(Display and Enhancement Controller for TV) is a variation of DECON IP. Its main purpose is to produce video stream for HDMI IP. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Inki Dae <inki.dae@samsung.com> Documentation/devicetree/bindings/display/exynos/exynos5433-decon.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7a35c0ee170b71a0cd3e278e560c4fd0dd84f3ca Author: Andrzej Hajda <a.hajda@samsung.com> Date: Tue Oct 20 11:22:35 2015 +0200 dt-bindings: video: add PCLK clock entry to exynos5433-decon DECON IP requires this clock to access configuration registers. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> Documentation/devicetree/bindings/display/exynos/exynos5433-decon.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 68cd004e54716b94e2c3c6abaca883861f4417b1 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Thu Jan 14 14:40:07 2016 +0900 drm/exynos/hdmi: add Exynos5433 support HDMI on Exynos5433 differs from previous versions: - different HDMI-PHY settings, - different clocks, - SYSREG registers for enabling reference clock, - MODE_SET register in HDMI-PHY. It is distinguished from other variants by different compatible string. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 142 +++++++++++++++++++++++++++++++++++ drivers/gpu/drm/exynos/regs-hdmi.h | 9 ++- 2 files changed, 149 insertions(+), 2 deletions(-) commit 2f1cad0d2de6a8319df8192da2bfc63cec53514d Author: Andrzej Hajda <a.hajda@samsung.com> Date: Thu Mar 24 10:36:28 2016 +0900 dt-bindings: exynos_hdmi: add bindings for Exynos5433 variant Exynos5433 variant of HDMI requires different set of clocks and sysreg phandle to system registers. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> .../bindings/display/exynos/exynos_hdmi.txt | 27 +++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) commit fec81a3c81f664fcb218d32265ff49666451f987 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Mon Nov 2 14:16:43 2015 +0100 drm/exynos/hdmi: stop programming registers with default values There is no point in rewriting default values, as the IP is reset anyway. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 19 ------------------- 1 file changed, 19 deletions(-) commit 5eefadb54ca36007b1c40bfd895695d7ab056fe1 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Thu Jan 14 14:28:20 2016 +0900 drm/exynos/hdmi: code cleanup The patch performs following clean-ups: - remove unnecessary white spaces, - remove obvious comments, - fix tabulations, - remove NULL initializators, - re-order driver data. The patch does not change driver's behavior. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 79 ++++++++++++------------------------ 1 file changed, 26 insertions(+), 53 deletions(-) commit 65e9803091c90fdc3551eac78a087f42d727f50f Author: Andrzej Hajda <a.hajda@samsung.com> Date: Mon Nov 2 14:16:41 2015 +0100 drm/exynos/hdmi: use array specifier for HDMI-PHY configurations HDMI-PHY configurations are stored as array pointer and count pair, we can re-use existing helpers to simplify their initialization. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) commit 190a3c619d86c10746dfbd39dec3095ce60f5d29 Author: Andrzej Hajda <a.hajda@samsung.com> Date: Mon Nov 2 14:16:40 2015 +0100 drm/exynos/hdmi: constify global variables These variables should not be modified. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 9be7e9898444f74e6fd90eb2773e28105163915a Author: Andrzej Hajda <a.hajda@samsung.com> Date: Thu Jan 14 14:22:47 2016 +0900 drm/exynos/hdmi: clock code re-factoring With incoming support for newer SoCs different set of clocks will be required, depending on IP version. The patch prepares the driver for it. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_hdmi.c | 194 +++++++++++++++++++++++++---------- 1 file changed, 140 insertions(+), 54 deletions(-) commit 12867e4e6bf0f55b977261f955a70977f622bf61 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Tue Mar 29 10:28:55 2016 +0900 drm/exynos: Use VIDEO_SAMSUNG_S5P_G2D=n as G2D Kconfig dependency Commit 254d4d111ee1 ("drm/exynos: Add dependency for G2D in Kconfig") made the DRM_EXYNOS_G2D symbol to only be selectable if the s5p-g2d V4L2 driver is not enabled, since both use the same HW IP block. But added the dependency as depends on !VIDEO_SAMSUNG_S5P_G2D which isn't correct since Kconfig expressions are not boolean but tristate. So it will only evaluate to 'n' if VIDEO_SAMSUNG_S5P_G2D=y but it will evaluate to m if VIDEO_SAMSUNG_S5P_G2D=m. This means that both the V4L2 and DRM drivers can be enabled if the former is enabled as a module, which is not what we want. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9e3fe3508fe6c46f1a393ee15397221241bcf981 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Mar 25 23:05:59 2016 +0300 drm/exynos: fix a warning message The "ret = regmap_write()" assignment was missing so this error message is never printed. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_mic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 943491af107474a1aa7137528b982adebc8f3626 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Mar 17 13:32:15 2016 +0300 drm/exynos: mic: fix an error code We accidentally return success instead of a negative error code here. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_mic.c | 1 + 1 file changed, 1 insertion(+) commit 4f93eed7761b582ba608e29522d69c8afe1f0812 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Thu Mar 17 07:53:12 2016 +0100 drm/exynos: fimd: fix broken dp_clock control Commit 1feafd3afd294b03dbbedb8e8f94e0c4db526f10 ("drm/exynos: add exynos5420 support for fimd") add support for Exynos 5420 SoC, but it broke enabling display clock feature because of incorrect condition check. This patch fixes it, so display is working again on platforms requiring display clock control (i.e. Exynos5250-based SNOW platform). Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_fimd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 25c6a853fcea78443d6545dbce48b6e899aae85b Author: Andrzej Hajda <a.hajda@samsung.com> Date: Tue Mar 15 12:43:21 2016 +0100 drm/exynos: build fbdev code conditionally Fbdev code should be compiled only if CONFIG_DRM_FBDEV_EMULATION option is enabled. The patch fixes exynos-drm code trying to manipulate fbdev data which is not initialized in case CONFIG_DRM_FBDEV_EMULATION is disabled. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/Makefile | 6 +++--- drivers/gpu/drm/exynos/exynos_drm_fb.c | 11 ----------- drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 11 +++++++++++ drivers/gpu/drm/exynos/exynos_drm_fbdev.h | 23 ++++++++++++++++++++++- 4 files changed, 36 insertions(+), 15 deletions(-) commit 81e50bcd1b2198d76739a9ee3279ac9a61209dfb Author: Andrzej Hajda <a.hajda@samsung.com> Date: Tue Mar 15 12:38:02 2016 +0100 drm/exynos: fix adjusted_mode pointer in exynos_plane_mode_set exynos_plane_mode_set should use adjusted_mode from the same atomic state as plane state. Otherwise it will result in incorrect behavior in case crtc mode changes. The patch fixes bug with black console framebuffer in case of command mode panels. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_plane.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 0a938697d7fb8d729afb1ec028566e08854d17f6 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Mar 14 15:22:25 2016 +0100 drm/exynos: fix error handling in exynos_drm_subdrv_open gcc-6 warns about a pointless loop in exynos_drm_subdrv_open: drivers/gpu/drm/exynos/exynos_drm_core.c: In function 'exynos_drm_subdrv_open': drivers/gpu/drm/exynos/exynos_drm_core.c:104:199: error: self-comparison always evaluates to false [-Werror=tautological-compare] list_for_each_entry_reverse(subdrv, &subdrv->list, list) { Here, the list_for_each_entry_reverse immediately terminates because the subdrv pointer is compared to itself as the loop end condition. If we were to take the current subdrv pointer as the start of the list (as we would do if list_for_each_entry_reverse() was not a macro), we would iterate backwards over the &exynos_drm_subdrv_list anchor, which would be even worse. Instead, we need to use list_for_each_entry_continue_reverse() to go back over each subdrv that was successfully opened until the first entry. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Inki Dae <inki.dae@samsung.com> drivers/gpu/drm/exynos/exynos_drm_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a38045121bf42110e6043d07315a7626b021a0db Author: Jon Hunter <jonathanh@nvidia.com> Date: Wed Mar 30 10:15:15 2016 +0100 soc/tegra: pmc: Add generic PM domain support Adds generic PM domain support to the PMC driver where the PM domains are populated from device-tree and the PM domain consumer devices are bound to their relevant PM domains via device-tree as well. Update the tegra_powergate_sequence_power_up() API so that internally it calls the same tegra_powergate_xxx functions that are used by the Tegra generic PM domain code for consistency. To ensure that the Tegra power domains (a.k.a. powergates) cannot be controlled via both the legacy tegra_powergate_xxx functions as well as the generic PM domain framework, add a bit map for available powergates that can be controlled via the legacy powergate functions. Move the majority of the tegra_powergate_remove_clamping() function to a sub-function, so that this can be used by both the legacy and generic power domain code. This is based upon work by Thierry Reding <treding@nvidia.com> and Vince Hsu <vinceh@nvidia.com>. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 485 ++++++++++++++++++++++++++++++++++++++++++------ include/soc/tegra/pmc.h | 1 + 2 files changed, 425 insertions(+), 61 deletions(-) commit 1333ce4defc5829d920472005c105eb0e0a1825a Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 4 16:54:18 2016 +0100 ARM: tegra: Enable XUSB on Nyan Add XUSB pad controller and XUSB controller device tree nodes and enable them with a configuration for the Nyan boards. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124-nyan.dtsi | 122 +++++++++++++++++++++++++++-------- 1 file changed, 94 insertions(+), 28 deletions(-) commit 87c68119f5bb75199a361f66b0a88c6093cea6d5 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 11 18:22:27 2015 +0100 ARM: tegra: Enable XUSB on Jetson TK1 Add XUSB pad controller and XUSB controller device tree nodes and enable them with a configuration for the Jetson TK1 board. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124-jetson-tk1.dts | 116 ++++++++++++++++++++++++++---- 1 file changed, 102 insertions(+), 14 deletions(-) commit 4da6b31fdcc889e5eaea000560dafec07de251ab Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 4 16:54:30 2016 +0100 ARM: tegra: Enable XUSB on Venice2 Add XUSB pad controller and XUSB controller device tree nodes and enable them with a configuration for the Venice2 board. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124-venice2.dts | 101 ++++++++++++++++++++++++++++++++- 1 file changed, 100 insertions(+), 1 deletion(-) commit 2d8a9c9c0a73c1c2c1fe8b970c11fc8f67bca005 Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 11 18:12:22 2016 +0100 ARM: tegra: Add Tegra124 XUSB controller Add a device tree node for the Tegra XUSB controller. It contains a phandle to the XUSB pad controller for control of the PHYs assigned to the USB ports. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124.dtsi | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 50623c5915100686f8ec2306562f2df1db2ac082 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 11 18:22:55 2015 +0100 ARM: tegra: Move Tegra124 to the new XUSB pad controller binding Use the new XUSB pad controller binding on Tegra124. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124.dtsi | 132 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 125 insertions(+), 7 deletions(-) commit 3227bf16ece8b57fb11a4246add9a41f6ebea50f Merge: 525243e ab065e9 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 29 16:49:47 2016 +0200 Merge branch 'for-4.7/xhci' into for-4.7/xusb commit 525243e4c5159af2f1c72992fe65d5254627f5fe Merge: 10fef6e 6fe7c18 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 29 16:49:44 2016 +0200 Merge branch 'for-4.7/pci' into for-4.7/xusb commit 10fef6e44c6c868655a03ed61b1033ee177f903c Merge: f55532a 87d66f2 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 29 16:49:34 2016 +0200 Merge branch 'for-4.7/phy' into for-4.7/xusb commit ab065e969640d9afd3967266eb3193fb3ac298bd Author: Thierry Reding <treding@nvidia.com> Date: Mon Feb 8 19:34:16 2016 +0100 usb: xhci: tegra: Add Tegra210 support Parameterize more parts of the driver and add support for Tegra210. Acked-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/usb/host/xhci-tegra.c | 59 +++++++++++++++++++++++++++++++++++++------ 1 file changed, 51 insertions(+), 8 deletions(-) commit e84fce0f8837496a48d11086829bdbe170358b7a Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 11 18:10:48 2016 +0100 usb: xhci: Add NVIDIA Tegra XUSB controller driver Add support for the on-chip XUSB controller present on Tegra SoCs. This controller, when loaded with external firmware, exposes an interface compliant with xHCI. This driver loads the firmware, starts the controller, and is able to service host-specific messages sent by the controller's firmware. The controller also supports USB device mode as well as powergating of the SuperSpeed and host-controller logic when not in use, but support for these is not yet implemented. Based on work by: Ajay Gupta <ajayg@nvidia.com> Bharath Yadav <byadav@nvidia.com> Andrew Bresticker <abrestic@chromium.org> Cc: Mathias Nyman <mathias.nyman@intel.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/usb/host/Kconfig | 9 + drivers/usb/host/Makefile | 1 + drivers/usb/host/xhci-tegra.c | 1288 +++++++++++++++++++++++++++++++++++++++++ 3 files changed, 1298 insertions(+) commit 16108f04799d24b6f2e1a8500db9f7df824f616e Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 4 16:20:38 2016 +0100 dt-bindings: usb: xhci-tegra: Add Tegra210 XUSB controller support Extend the Tegra XUSB controller device tree binding with Tegra210 support. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../devicetree/bindings/usb/nvidia,tegra124-xusb.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 5053dcb75bbb4293e9c8b07140bcb43ea8075dde Author: Thierry Reding <treding@nvidia.com> Date: Thu Feb 11 18:10:22 2016 +0100 dt-bindings: usb: Add NVIDIA Tegra XUSB controller binding Add device-tree binding documentation for the XUSB controller present on Tegra124 and later SoCs. This controller supports USB 3.0 via an xHCI compliant interface. Based on work by Andrew Bresticker <abrestic@chromium.org>. Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Mathias Nyman <mathias.nyman@intel.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/usb/nvidia,tegra124-xusb.txt | 108 +++++++++++++++++++++ 1 file changed, 108 insertions(+) commit 11adbfa0b9a3922ee66ee69d3b969a0f389acbd6 Merge: f55532a 87d66f2 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 29 16:48:51 2016 +0200 Merge branch 'for-4.7/phy' into for-4.7/xhci commit 6fe7c187e026c8b610df9dda7d9befc70cbfd169 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 11 18:25:59 2015 +0100 PCI: tegra: Support per-lane PHYs The current XUSB pad controller bindings are insufficient to describe PHY devices attached to USB controllers. New bindings have been created to overcome these restrictions. As a side-effect each root port now is assigned a set of PHY devices, one for each lane associated with the root port. This has the benefit of allowing fine-grained control of the power management for each lane. Acked-by: Stephen Warren <swarren@nvidia.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/pci/host/pci-tegra.c | 244 ++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 227 insertions(+), 17 deletions(-) commit 13541cc3d42faef262cbae21331128c065d7dc5d Author: Thierry Reding <treding@nvidia.com> Date: Fri Mar 4 16:50:50 2016 +0100 dt-bindings: pci: tegra: Update for per-lane PHYs The XUSB pad controller allows PCIe lanes to be controlled individually, providing fine-grained control over their power state. Previous attempts at describing the XUSB pad controller in DT had erroneously assumed that all PCIe lanes were driven by the same PHY, and hence the PCI host controller would reference only a single PHY. Moving to a representation of per-lane PHYs requires that the operating system driver for the PCI host controller have access to the set of PHY devices that make up the connection of each root port in order to power up and down all of the lanes as necessary. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/pci/nvidia,tegra20-pcie.txt | 224 ++++++++++++++++++++- 1 file changed, 219 insertions(+), 5 deletions(-) commit 4000b00f3ca0be65ea947610f7eb8a09f6052756 Merge: f55532a 87d66f2 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 29 16:47:22 2016 +0200 Merge branch 'for-4.7/phy' into for-4.7/pci commit 87d66f280672800c9c2ad1ce3b7a993ce1e04769 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 11 18:25:02 2015 +0100 phy: tegra: Add Tegra210 support Add support for the XUSB pad controller found on Tegra210 SoCs. The hardware is roughly the same, but some of the registers have been moved around and the number and type of supported pads has changed. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/phy/tegra/Makefile | 1 + drivers/phy/tegra/xusb-tegra210.c | 2045 +++++++++++++++++++++++++++++++++++++ include/soc/tegra/fuse.h | 1 + 3 files changed, 2047 insertions(+) commit 53d2a715c24034ee4017f3c15c82bb4a53a07da5 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 11 18:24:21 2015 +0100 phy: Add Tegra XUSB pad controller support Add a new driver for the XUSB pad controller found on NVIDIA Tegra SoCs. This hardware block used to be exposed as a pin controller, but it turns out that this isn't a good fit. The new driver and DT binding much more accurately describe the hardware and are more flexible in supporting new SoC generations. Acked-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/phy/Kconfig | 2 + drivers/phy/Makefile | 2 + drivers/phy/tegra/Kconfig | 8 + drivers/phy/tegra/Makefile | 5 + drivers/phy/tegra/xusb-tegra124.c | 1752 ++++++++++++++++++++++++++++ drivers/phy/tegra/xusb.c | 1021 ++++++++++++++++ drivers/phy/tegra/xusb.h | 421 +++++++ drivers/pinctrl/tegra/pinctrl-tegra-xusb.c | 20 +- include/linux/phy/tegra/xusb.h | 30 + 9 files changed, 3245 insertions(+), 16 deletions(-) commit d6f83c1b1dcac39729f48fe1c2d426b9c135df41 Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 4 17:35:01 2015 +0100 dt-bindings: phy: tegra-xusb-padctl: Add Tegra210 support Extend the binding to cover the set of feature found in Tegra210. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/phy/nvidia,tegra124-xusb-padctl.txt | 341 +++++++++++++++++++++ 1 file changed, 341 insertions(+) commit b1accd107b7a5db06d2c5a303cb5d419f788392d Author: Thierry Reding <treding@nvidia.com> Date: Wed Nov 4 16:53:36 2015 +0100 dt-bindings: phy: Add NVIDIA Tegra XUSB pad controller binding The NVIDIA Tegra XUSB pad controller provides a set of pads, each with a set of lanes that are used for PCIe, SATA and USB. A binding exists for the XUSB pad controller already, but it turned out not to be flexible enough to describe all aspects of the controller. In particular, the addition of XUSB support (for SuperSpeed USB) has shown that the existing binding is no longer suitable. Mark the old binding as deprecated and link to the new binding. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/phy/nvidia,tegra124-xusb-padctl.txt | 392 +++++++++++++++++++++ .../pinctrl/nvidia,tegra124-xusb-padctl.txt | 6 + 2 files changed, 398 insertions(+) commit 5359534505c74841dbb2c6baf41db1a395acd34d Author: Tony Luck <tony.luck@intel.com> Date: Thu Apr 28 07:52:11 2016 -0700 EDAC, i7core: Remove double buffering of error records In the bad old days the functions from x86_mce_decoder_chain could be called in machine check context. So we used to carefully copy them and defer processing until later. But in f29a7aff4bd60 ("x86/mce: Avoid potential deadlock due to printk() in MCE context") we switched the logging code to save the record in a genpool, and call the functions that registered to be notified later from a work queue. So drop all the double buffering and do all the work we want to do as soon as i7core_mce_check_error() is called. Signed-off-by: Tony Luck <tony.luck@intel.com> Acked-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/29ab2c370915c6e132fc5d88e7b72cb834bedbfe.1461855008.git.tony.luck@intel.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/i7core_edac.c | 81 +++------------------------------------------- 1 file changed, 5 insertions(+), 76 deletions(-) commit 1140f7c8994a3a2a0d7c4972509d98b792617d39 Author: Thierry Reding <treding@nvidia.com> Date: Tue Apr 5 17:17:34 2016 +0200 phy: core: Allow children node to be overridden In order to more flexibly support device tree bindings, allow drivers to override the container of the child nodes. By default the device node of the PHY provider is assumed to be the parent for children, but bindings may decide to add additional levels for better organization. Acked-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Thierry Reding <treding@nvidia.com> Documentation/phy.txt | 16 ++++++++++++++-- drivers/phy/phy-core.c | 50 +++++++++++++++++++++++++++++++++++++++++++------ include/linux/phy/phy.h | 31 ++++++++++++++++++++---------- 3 files changed, 79 insertions(+), 18 deletions(-) commit e9f4d569fb897e77200cd431f3aab138c3c733e6 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Thu Apr 28 11:05:12 2016 +0200 gpio: rename gpio-generic.c into gpio-mmio.c This patch renames the gpio-generic.c into gpio-mmio.c. This is because currently the file only contains code for a memory-mapped GPIO driver. There isn't any support for ioports or other resource type. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Makefile | 3 + drivers/gpio/gpio-generic.c | 660 -------------------------------------------- drivers/gpio/gpio-mmio.c | 660 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 663 insertions(+), 660 deletions(-) commit 8f01c9d05733db0071884b4af0003f8ac10513ae Author: Christian Lamparter <chunkeey@googlemail.com> Date: Fri Apr 29 02:53:14 2016 +0200 gpio: generic: fix GPIO_GENERIC_PLATFORM is set to module case GPIO_GENERIC_PLATFORM is a tristate. If the module option is selected the resulting gpio-generic.ko will lack most of the module initialzation and probe code. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-generic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 19b67d5c8b2dbef9a10bc1aeb96a861c57a0bdf8 Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Fri Apr 29 09:49:09 2016 +0200 arm64: dts: marvell: add XOR node for Armada 3700 SoC Armada 3700 SoC comprise one dual-channel XOR engine and this patch adds its according representation. Signed-off-by: Marcin Wojtas <mw@semihalf.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit f24632475d4ffed5626abbfab7ef30a128dd1474 Author: Bruce Rogers <brogers@suse.com> Date: Thu Apr 28 14:49:21 2016 -0600 KVM: x86: fix ordering of cr0 initialization code in vmx_cpu_reset Commit d28bc9dd25ce reversed the order of two lines which initialize cr0, allowing the current (old) cr0 value to mess up vcpu initialization. This was observed in the checks for cr0 X86_CR0_WP bit in the context of kvm_mmu_reset_context(). Besides, setting vcpu->arch.cr0 after vmx_set_cr0() is completely redundant. Change the order back to ensure proper vcpu initialization. The combination of booting with ovmf firmware when guest vcpus > 1 and kvm's ept=N option being set results in a VM-entry failure. This patch fixes that. Fixes: d28bc9dd25ce ("KVM: x86: INIT and reset sequences are different") Cc: stable@vger.kernel.org Signed-off-by: Bruce Rogers <brogers@suse.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> arch/x86/kvm/vmx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 057eab2013ecbba2e772293acc177e2e3210f05d Author: Thierry Reding <treding@nvidia.com> Date: Fri Mar 4 12:58:07 2016 +0100 MAINTAINERS: Remove Terje Bergström as Tegra DRM maintainer Terje doesn't work on host1x anymore and doesn't have the time to help maintain the host1x and related drivers. Acked-by: Terje Bergstrom <tbergstrom@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> MAINTAINERS | 1 - 1 file changed, 1 deletion(-) commit 210aa27768bec4297a9d6ad0e5cab45935c775e9 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to convert_extent_bit Single caller passes GFP_NOFS. We can get rid of the gfpflags_allow_blocking checks as NOFS can block but does not recurse to filesystem through reclaim. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 12 ++++++------ fs/btrfs/extent_io.h | 2 +- fs/btrfs/transaction.c | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) commit d4b9e0790aa764c0b01e18d4e8d33e93ba36d51f Author: Marc Zyngier <marc.zyngier@arm.com> Date: Thu Apr 28 16:16:31 2016 +0100 arm/arm64: KVM: Enforce Break-Before-Make on Stage-2 page tables The ARM architecture mandates that when changing a page table entry from a valid entry to another valid entry, an invalid entry is first written, TLB invalidated, and only then the new entry being written. The current code doesn't respect this, directly writing the new entry and only then invalidating TLBs. Let's fix it up. Cc: <stable@vger.kernel.org> Reported-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/kvm/mmu.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit 866e48b0994c6338e6aa4ae7c413b5888ab432d1 Author: Axel Lin <axel.lin@ingics.com> Date: Wed Apr 27 16:19:26 2016 +0800 spi: pic32: Fix checking return value of devm_ioremap_resource devm_ioremap_resource() returns ERR_PTR on error. Also remove the redundant dev_err message, the implementation of devm_ioremap_resource() already print error messages on error paths. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pic32.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit cb2ad5e5339c5122166265cea579cc6a356d46de Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Wed Apr 27 16:59:50 2016 +0300 ARC: [axs10x] Specify reserved memory for frame buffer Allocation of a frame buffer memory in a special memory region allows bypassing of so-called IO Coherency aperture which is typically set as a range 0x8z-0xAz. I.e. all data traffic to PGU bypasses IO Coherency block and saves its bandwidth for other peripherals. Even though for AXS101 (which sorts ARC770 CPU) IOC is not an option for a sake of keeping one DT description for the base-board (axs10x_mb.dtsi) we're still defining reserved memory location in the very end of DDR. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Acked-by: Vineet Gupta <vgupta@synopsys.com> Cc: devicetree@vger.kernel.org arch/arc/boot/dts/axc001.dtsi | 22 ++++++++++++++++++++-- arch/arc/boot/dts/axc003.dtsi | 14 ++++++++++++++ arch/arc/boot/dts/axc003_idu.dtsi | 14 ++++++++++++++ arch/arc/boot/dts/axs10x_mb.dtsi | 2 +- 4 files changed, 49 insertions(+), 3 deletions(-) commit a9597305d97f6cf7c9e89dc1461e834c446d91fd Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Fri Apr 29 12:59:51 2016 +0200 regulator: max77686: Configure enable time to properly handle regulator enable The enable time for buck regulators was not configured but actually is essential: consumers, like usb3503, doing hard reset (regulator off/on) should wait for the regulator to settle. Configure the enable time according to datasheet. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/max77686-regulator.c | 5 +++++ 1 file changed, 5 insertions(+) commit 8aeab995fa142523f376369e4ce0608df6727706 Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Wed Apr 27 16:02:39 2016 +0300 drm/arcpgu: use dedicated memory area for frame buffer Now when ARC supports reserved memory areas and per-device coherent DMA allocations we may switch ARC PGU to use of those dedicated areas. One of the benefits we may move frame-buffer area out from IO Coherency aperture and so significantly reduce IOC utilization allowing less demanding peripherals to use all perks of IOC. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Dave Airlie <airlied@gmail.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: linux-kernel@vger.kernel.org Cc: linux-snps-arc@lists.infradead.org drivers/gpu/drm/arc/arcpgu_drv.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 1e166c77fdbc71bd237a3d1ac27abef6221e3a5e Author: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Date: Wed Mar 30 12:40:58 2016 -0300 [media] DocBook: update error code in videoc-streamon Add description of ENOLINK error Signed-off-by: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/v4l/vidioc-streamon.xml | 8 ++++++++ 1 file changed, 8 insertions(+) commit 47dfdb3a888733ab76702fc2801b6715c9d77937 Author: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Date: Sun Jun 28 16:14:10 2015 -0300 [media] media: change pipeline validation return error According to the V4L2 API, the VIDIOC_STREAMON ioctl should return EPIPE if there is a format mismatch in the pipeline configuration. As the .vidioc_streamon in the v4l2_ioctl_ops usually forwards the error caused by the v4l2_subdev_link_validate_default (if it is in use), it should return -EPIPE when it detect the mismatch. When an entity is connected to a non enabled link, media_entity_pipeline_start should return -ENOLINK, as the link does not exist. Signed-off-by: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-entity.c | 2 +- drivers/media/v4l2-core/v4l2-subdev.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 9b4639bb6a637770fec6b95bb5d9f751e403e8cb Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Thu Apr 28 15:56:23 2016 +0300 video: fbdev: omap2: Remove deprecated regulator_can_change_voltage() usage regulator_can_change_voltage() is deprecated and it's use is not necessary as commit: 6a0028b3dd67b regulator: Deprecate regulator_can_change_voltage() describers it clearly. As there is no practical use of it it can be removed. At this point the regulator_set_voltage() calls can not be removed as the DT data need to be fixed first. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> drivers/video/fbdev/omap2/omapfb/dss/dsi.c | 12 +++++------- drivers/video/fbdev/omap2/omapfb/dss/hdmi4.c | 12 +++++------- drivers/video/fbdev/omap2/omapfb/dss/hdmi5.c | 12 +++++------- 3 files changed, 15 insertions(+), 21 deletions(-) commit f2e6721af4466f1a53f16ccb8f1df57b3a0cd18e Merge: 05195ed f40d489 Author: Mark Brown <broonie@kernel.org> Date: Fri Apr 29 11:51:22 2016 +0100 Merge branch 'fix/axp20x' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator into regulator-axp20x commit 3cc6185bcccff32df41faa97d592a99d258db185 Author: Caleb Crome <caleb@crome.org> Date: Mon Apr 25 11:36:18 2016 -0700 ASoC: fsl_ssi: add CCSR_SSI_SOR to volatile register list The CCSR_SSI_SOR is a register that clears the TX and/or the RX fifo on the i.MX SSI port. The fsl_ssi_trigger writes this register in order to clear the fifo at trigger time. However, since the CCSR_SSI_SOR register is not in the volatile list, the caching mechanism prevented the register write in the trigger function. This caused the fifo to not be cleared (because the value was unchanged from the last time the register was written), and thus causes the channels in both TDM or simple I2S mode to slip and be in the wrong time slots on SSI restart. This has gone unnoticed for so long because with simple stereo mode, the consequence is that left and right are swapped, which isn't that noticeable. However, it's catestrophic in some systems that require the channels to be in the right slots. Signed-off-by: Caleb Crome <caleb@crome.org> Suggested-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Nicolin Chen <nicoleotsuka@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/fsl_ssi.c | 1 + 1 file changed, 1 insertion(+) commit d63f4b5269e93759d3036932890c96d7a8639e5b Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:31 2016 -0700 selftests/x86/ldt_gdt: Test set_thread_area() deletion of an active segment Now that set_thread_area() is supposed to give deterministic behavior when it modifies in-use segments, test it. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/f2bc11af1ee1a0f815ed910840cbdba06b640a20.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/testing/selftests/x86/ldt_gdt.c | 250 ++++++++++++++++++++++++++++++++++ 1 file changed, 250 insertions(+) commit c9867f863e19dd07c6085b457f6775047924c3b5 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:30 2016 -0700 x86/tls: Synchronize segment registers in set_thread_area() The current behavior of set_thread_area() when it modifies a segment that is currently loaded is a bit confused. If CS [1] or SS is modified, the change will take effect on return to userspace because CS and SS are fundamentally always reloaded on return to userspace. Similarly, on 32-bit kernels, if DS, ES, FS, or (depending on configuration) GS refers to a modified segment, the change will take effect immediately on return to user mode because the entry code reloads these registers. If set_thread_area() modifies DS, ES [2], FS, or GS on 64-bit kernels or GS on 32-bit lazy-GS [3] kernels, however, the segment registers will be left alone until something (most likely a context switch) causes them to be reloaded. This means that behavior visible to user space is inconsistent. If set_thread_area() is implicitly called via CLONE_SETTLS, then all segment registers will be reloaded before the thread starts because CLONE_SETTLS happens before the initial context switch into the newly created thread. Empirically, glibc requires the immediate reload on CLONE_SETTLS -- 32-bit glibc on my system does *not* manually reload GS when creating a new thread. Before enabling FSGSBASE, we need to figure out what the behavior will be, as FSGSBASE requires that we reconsider our behavior when, e.g., GS and GSBASE are out of sync in user mode. Given that we must preserve the existing behavior of CLONE_SETTLS, it makes sense to me that we simply extend similar behavior to all invocations of set_thread_area(). This patch explicitly updates any segment register referring to a segment that is targetted by set_thread_area(). If set_thread_area() deletes the segment, then the segment register will be nulled out. [1] This can't actually happen since 0e58af4e1d21 ("x86/tls: Disallow unusual TLS segments") but, if it did, this is how it would behave. [2] I strongly doubt that any existing non-malicious program loads a TLS segment into DS or ES on a 64-bit kernel because the context switch code was badly broken until recently, but that's not an excuse to leave the current code alone. [3] One way or another, that config option should to go away. Yuck! Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/27d119b0d396e9b82009e40dff8333a249038225.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/tls.c | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit 296f781a4b7801ad9c1c0219f9e87b6c25e196fe Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:29 2016 -0700 x86/asm/64: Rename thread_struct's fs and gs to fsbase and gsbase Unlike ds and es, these are base addresses, not selectors. Rename them so their meaning is more obvious. On x86_32, the field is still called fs. Fixing that could make sense as a future cleanup. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/69a18a51c4cba0ce29a241e570fc618ad721d908.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/elf.h | 6 +++--- arch/x86/include/asm/processor.h | 11 +++++++++-- arch/x86/kernel/process_64.c | 30 +++++++++++++++--------------- arch/x86/kernel/ptrace.c | 8 ++++---- arch/x86/kvm/svm.c | 2 +- 5 files changed, 32 insertions(+), 25 deletions(-) commit 731e33e39a5b95ad77017811b3ced32ecf9dc666 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:28 2016 -0700 x86/arch_prctl/64: Remove FSBASE/GSBASE < 4G optimization As far as I know, the optimization doesn't work on any modern distro because modern distros use high addresses for ASLR. Remove it. The ptrace code was either wrong or very strange, but the behavior with this patch should be essentially identical to the behavior without this patch unless user code goes out of its way to mislead ptrace. On newer CPUs, once the FSGSBASE instructions are enabled, we won't want to use the optimized variant anyway. This isn't actually much of a performance regression, it has no effect on normal dynamically linked programs, and it's a considerably simplification. It also removes some nasty special cases from code that is already way too full of special cases for comfort. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/dd1599b08866961dba9d2458faa6bbd7fba471d7.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/segment.h | 7 ----- arch/x86/kernel/process_64.c | 71 +++++++----------------------------------- arch/x86/kernel/ptrace.c | 44 ++++---------------------- 3 files changed, 17 insertions(+), 105 deletions(-) commit b038c842b385f1470f991078e71b7c5b084a7341 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:27 2016 -0700 x86/segments/64: When load_gs_index fails, clear the base On AMD CPUs, a failed load_gs_base currently may not clear the FS base. Fix it. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1a6c4d3a8a4e7be79ba448b42685e0321d50c14c.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_64.S | 6 ++++++ 1 file changed, 6 insertions(+) commit 45e876f794e8e566bf827c25ef0791875081724f Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:26 2016 -0700 x86/segments/64: When loadsegment(fs, ...) fails, clear the base On AMD CPUs, a failed loadsegment currently may not clear the FS base. Fix it. While we're at it, prevent loadsegment(gs, xyz) from even compiling on 64-bit kernels. It shouldn't be used. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/a084c1b93b7b1408b58d3fd0b5d6e47da8e7d7cf.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/segment.h | 42 +++++++++++++++++++++++++++++++++++++++--- arch/x86/kernel/cpu/common.c | 2 +- arch/x86/mm/extable.c | 10 ++++++++++ 3 files changed, 50 insertions(+), 4 deletions(-) commit f005f5d860e0231fe212cfda8c1a3148b99609f4 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:25 2016 -0700 x86/asm: Make asm/alternative.h safe from assembly asm/alternative.h isn't directly useful from assembly, but it shouldn't break the build. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/e5b693fcef99fe6e80341c9e97a002fb23871e91.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/alternative.h | 4 ++++ 1 file changed, 4 insertions(+) commit 35de5b0692aaa1f99803044526f2cc00ff864426 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 12:23:24 2016 -0700 x86/asm: Stop depending on ptrace.h in alternative.h alternative.h pulls in ptrace.h, which means that alternatives can't be used in anything referenced from ptrace.h, which is a mess. Break the dependency by pulling text patching helpers into their own header. Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/99b93b13f2c9eb671f5c98bba4c2cbdc061293a2.1461698311.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/alternative.h | 33 ----------------------------- arch/x86/include/asm/kgdb.h | 2 ++ arch/x86/include/asm/setup.h | 1 + arch/x86/include/asm/text-patching.h | 40 ++++++++++++++++++++++++++++++++++++ arch/x86/kernel/alternative.c | 1 + arch/x86/kernel/jump_label.c | 1 + arch/x86/kernel/kgdb.c | 1 + arch/x86/kernel/kprobes/core.c | 1 + arch/x86/kernel/kprobes/opt.c | 1 + arch/x86/kernel/module.c | 1 + arch/x86/kernel/traps.c | 1 + 11 files changed, 50 insertions(+), 33 deletions(-) commit ffc5fce9a96303c3e16232a6bdf8827af6adb604 Merge: b2eafe8 1bdb897 Author: Ingo Molnar <mingo@kernel.org> Date: Fri Apr 29 11:55:04 2016 +0200 Merge branch 'x86/urgent' into x86/asm, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 57dd5414a087991d427067b32dc3324af61b1c8b Author: Takashi Iwai <tiwai@suse.de> Date: Fri Apr 29 11:49:04 2016 +0200 ALSA: usb-audio: Limit retrying sample rate reads There are many USB audio devices with buggy firmware that don't react with the sample rate reading properly. This often results in the flood of error messages and slowing down the operation. The sample rate read back is basically only for confirming the sample rate setup, and it's not critically important. As a compromise, in this patch, we stop the sample rate read back once when the device gives errors more than tolerance (twice, as of now). This should improve most of error cases while we still can catch the firmware bugginess. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/usb/clock.c | 4 ++++ sound/usb/usbaudio.h | 1 + 2 files changed, 5 insertions(+) commit df408e9cd04a1dd15a46e40d8de346fa1f3564d2 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 23:02:09 2016 +0100 pinctrl: sirf/atlas7: trivial fix of spelling mistake on flagged fix spelling mistake, flaged -> flagged Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/sirf/pinctrl-atlas7.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e6cb3486f5a1bd55240e8326691dbfb86564f8c6 Author: Jiang Qiu <qiujiang@huawei.com> Date: Thu Apr 28 17:32:03 2016 +0800 gpio: dwapb: add gpio-signaled acpi event support This patch adds gpio-signaled acpi event support. It is used for power button on hisilicon D02 board, an arm64 platform. The corresponding DSDT file is defined as follows: Device(GPI0) { Name(_HID, "HISI0181") Name(_ADR, 0) Name(_UID, 0) Name (_CRS, ResourceTemplate () { Memory32Fixed (ReadWrite, 0x802e0000, 0x10000) Interrupt (ResourceConsumer, Level, ActiveHigh, Exclusive,,,) {344} }) Device(PRTa) { Name (_DSD, Package () { Package () { Package () {"reg",0}, Package () {"snps,nr-gpios",32}, } }) } Name (_AEI, ResourceTemplate () { GpioInt(Edge, ActiveLow, ExclusiveAndWake, PullUp, , " \\_SB.GPI0") {8} }) Method (_E08, 0x0, NotSerialized) { Notify (\_SB.PWRB, 0x80) } } Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jiang Qiu <qiujiang@huawei.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-dwapb.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 4ba8cfa79f44a9489b1d562430cb70fb53200adb Author: Jiang Qiu <qiujiang@huawei.com> Date: Thu Apr 28 17:32:02 2016 +0800 gpio: dwapb: convert device node to fwnode This patch converts device node to fwnode for dwapb driver, so as to provide a unified fwnode for DT and ACPI bindings. Tested-by: Alan Tull <delicious.quinoa@gmail.com> Acked-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jiang Qiu <qiujiang@huawei.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-dwapb.c | 36 +++++++++++++++----------------- drivers/mfd/intel_quark_i2c_gpio.c | 2 +- include/linux/platform_data/gpio-dwapb.h | 2 +- 3 files changed, 19 insertions(+), 21 deletions(-) commit e81591815de05572ed28cbdca631d4d97f0bd059 Author: Jiang Qiu <qiujiang@huawei.com> Date: Thu Apr 28 17:32:01 2016 +0800 gpio: dwapb: remove name from dwapb_port_property This patch removed the name property from dwapb_port_property. The name property is redundant, since we can get this info from dwapb_gpio dev node. Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jiang Qiu <qiujiang@huawei.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-dwapb.c | 24 +++++++++++------------- drivers/mfd/intel_quark_i2c_gpio.c | 1 - include/linux/platform_data/gpio-dwapb.h | 1 - 3 files changed, 11 insertions(+), 15 deletions(-) commit a8fa91a74fc385da5d52fd1008c8fd322154cad8 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 19 14:10:08 2016 +0200 gpio/qoriq: select IRQ_DOMAIN The gpio-mpc8xxx driver requires IRQ domains but can be built without them, resulting on a failure to build certain randconfigs on ARM: drivers/gpio/gpio-mpc8xxx.c: In function 'mpc8xxx_gpio_to_irq': drivers/gpio/gpio-mpc8xxx.c:92:10: error: implicit declaration of function 'irq_create_mapping' [-Werror=implicit-function-declaration] return irq_create_mapping(mpc8xxx_gc->irq, offset); This selects IRQ_DOMAIN from the driver to ensure we can build it. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 5df7fd46b70b ("gpio/qoriq: Add qoriq platforms support") Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 037c418945edb9eb2006abe273910212af85629e Author: Anup Patel <anup.patel@broadcom.com> Date: Mon Mar 28 10:18:26 2016 +0530 phy: Rename phy-brcmstb-sata driver to phy-brcm-sata driver Currently, we have a common SATA3 PHY driver for all Broadcom STB SoCs. This driver can be extended and re-used for Broadcom iProc SoCs having same SATA3 PHY. This patch renames existing Broadcom STB SATA3 PHY driver to common Broadcom SATA3 PHY driver to share this PHY driver across Broadcom SoCs. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/Kconfig | 18 +-- drivers/phy/Makefile | 2 +- drivers/phy/phy-brcm-sata.c | 250 +++++++++++++++++++++++++++++++++++++++++ drivers/phy/phy-brcmstb-sata.c | 250 ----------------------------------------- 4 files changed, 260 insertions(+), 260 deletions(-) commit ec9e80527621f8944aefbe870958c168bf47d09d Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 7 10:14:24 2016 +0900 phy: rcar-gen3-usb2, rcar-gen2: Use ARCH_RENESAS Make use of ARCH_RENESAS in place of ARCH_SHMOBILE. A now redundant dependency on OF is also dropped. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> drivers/phy/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cde7bc367f09e97deef143ebab3271153d87df00 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 7 10:58:41 2016 +0900 phy: rcar-gen3-usb2: add fallback binding In the case of Renesas R-Car hardware we know that there are generations of SoCs, e.g. Gen 2 and Gen 3. But beyond that its not clear what the relationship between IP blocks might be. For example, I believe that r8a7790 is older than r8a7791 but that doesn't imply that the latter is a descendant of the former or vice versa. We can, however, by examining the documentation and behaviour of the hardware at run-time observe that the current driver implementation appears to be compatible with the IP blocks on SoCs within a given generation. For the above reasons and convenience when enabling new SoCs a per-generation fallback compatibility string scheme being adopted for drivers for Renesas SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Documentation/devicetree/bindings/phy/rcar-gen3-phy-usb2.txt | 10 ++++++++-- drivers/phy/phy-rcar-gen3-usb2.c | 1 + 2 files changed, 9 insertions(+), 2 deletions(-) commit 7777cb8ba08dabcab8dc0e91ac0a26dde675edb6 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 7 10:58:40 2016 +0900 phy: rcar-gen2: add fallback binding In the case of Renesas R-Car hardware we know that there are generations of SoCs, e.g. Gen 2 and Gen 3. But beyond that its not clear what the relationship between IP blocks might be. For example, I believe that r8a7790 is older than r8a7791 but that doesn't imply that the latter is a descendant of the former or vice versa. We can, however, by examining the documentation and behaviour of the hardware at run-time observe that the current driver implementation appears to be compatible with the IP blocks on SoCs within a given generation. For the above reasons and convenience when enabling new SoCs a per-generation fallback compatibility string scheme being adopted for drivers for Renesas SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Documentation/devicetree/bindings/phy/rcar-gen2-phy.txt | 8 +++++++- drivers/phy/phy-rcar-gen2.c | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) commit 1acd010152138644f63d743e165161edc780fc32 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Apr 26 12:30:26 2016 +0200 pinctrl: sh-pfc: Kill unused variable in sh_pfc_remove() If CONFIG_PINCTRL_SH_PFC_GPIO=n: drivers/pinctrl/sh-pfc/core.c: In function 'sh_pfc_remove': drivers/pinctrl/sh-pfc/core.c:649:17: warning: unused variable 'pfc' [-Wunused-variable] Fixes: 67ec8d7b48463904 ("pinctrl: ish-pfc: Use devm_pinctrl_register() for pinctrl registration") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/sh-pfc/core.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 0ec7ae928a9c19c2b7b8054507d5694a2597065e Author: Ingo Molnar <mingo@kernel.org> Date: Fri Apr 29 10:31:28 2016 +0200 efi: Remove unnecessary (and buggy) .memmap initialization from the Xen EFI driver So the following commit: 884f4f66ffd6 ("efi: Remove global 'memmap' EFI memory map") ... triggered the following build warning on x86 64-bit allyesconfig: drivers/xen/efi.c:290:47: warning: missing braces around initializer [-Wmissing-braces] It's this initialization in drivers/xen/efi.c: static const struct efi efi_xen __initconst = { ... .memmap = NULL, /* Not used under Xen. */ ... which was forgotten about, as .memmap now is an embedded struct: struct efi_memory_map memmap; We can remove this initialization - it's an EFI core internal data structure plus it's not used in the Xen driver anyway. Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: ard.biesheuvel@linaro.org Cc: bp@alien8.de Cc: linux-tip-commits@vger.kernel.org Cc: tony.luck@intel.com Link: http://lkml.kernel.org/r/20160429083128.GA4925@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/xen/efi.c | 1 - 1 file changed, 1 deletion(-) commit 4abf061bf87bbd856c8d60199b2fba8b8f9b9fd6 Author: Yinghai Lu <yinghai@kernel.org> Date: Thu Apr 28 17:09:08 2016 -0700 x86/boot: Correctly bounds-check relocations Relocation handling performs bounds checking on the resulting calculated addresses. The existing code uses output_len (VO size plus relocs size) as the max address. This is not right since the max_addr check should stop at the end of VO and exclude bss, brk, etc, which follows. The valid range should be VO [_text, __bss_start] in the loaded physical address space. This patch adds an export for __bss_start in voffset.h and uses it to set the correct limit for max_addr. Signed-off-by: Yinghai Lu <yinghai@kernel.org> [ Rewrote the changelog. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1461888548-32439-7-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/Makefile | 2 +- arch/x86/boot/compressed/misc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 4d2d542482205d3df1a0852751f5b004cc6390cc Author: Yinghai Lu <yinghai@kernel.org> Date: Thu Apr 28 17:09:07 2016 -0700 x86/KASLR: Clean up unused code from old 'run_size' and rename it to 'kernel_total_size' Since 'run_size' is now calculated in misc.c, the old script and associated argument passing is no longer needed. This patch removes them, and renames 'run_size' to the more descriptive 'kernel_total_size'. Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote the changelog, renamed 'run_size' to 'kernel_total_size' ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Junjie Mao <eternal.n08@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1461888548-32439-6-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/Makefile | 4 +--- arch/x86/boot/compressed/head_32.S | 3 +-- arch/x86/boot/compressed/head_64.S | 3 --- arch/x86/boot/compressed/misc.c | 11 ++++------ arch/x86/boot/compressed/mkpiggy.c | 10 ++------- arch/x86/tools/calc_run_size.sh | 42 -------------------------------------- 6 files changed, 8 insertions(+), 65 deletions(-) commit 67b6662559f7f77bcbd3ac67d09aaac11785f3c1 Author: Yinghai Lu <yinghai@kernel.org> Date: Thu Apr 28 17:09:06 2016 -0700 x86/boot: Fix "run_size" calculation Currently, the "run_size" variable holds the total kernel size (size of code plus brk and bss) and is calculated via the shell script arch/x86/tools/calc_run_size.sh. It gets the file offset and mem size of the .bss and .brk sections from the vmlinux, and adds them as follows: run_size = $(( $offsetA + $sizeA + $sizeB )) However, this is not correct (it is too large). To illustrate, here's a walk-through of the script's calculation, compared to the correct way to find it. First, offsetA is found as the starting address of the first .bss or .brk section seen in the ELF file. The sizeA and sizeB values are the respective section sizes. [bhe@x1 linux]$ objdump -h vmlinux vmlinux: file format elf64-x86-64 Sections: Idx Name Size VMA LMA File off Algn 27 .bss 00170000 ffffffff81ec8000 0000000001ec8000 012c8000 2**12 ALLOC 28 .brk 00027000 ffffffff82038000 0000000002038000 012c8000 2**0 ALLOC Here, offsetA is 0x012c8000, with sizeA at 0x00170000 and sizeB at 0x00027000. The resulting run_size is 0x145f000: 0x012c8000 + 0x00170000 + 0x00027000 = 0x145f000 However, if we instead examine the ELF LOAD program headers, we see a different picture. [bhe@x1 linux]$ readelf -l vmlinux Elf file type is EXEC (Executable file) Entry point 0x1000000 There are 5 program headers, starting at offset 64 Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flags Align LOAD 0x0000000000200000 0xffffffff81000000 0x0000000001000000 0x0000000000b5e000 0x0000000000b5e000 R E 200000 LOAD 0x0000000000e00000 0xffffffff81c00000 0x0000000001c00000 0x0000000000145000 0x0000000000145000 RW 200000 LOAD 0x0000000001000000 0x0000000000000000 0x0000000001d45000 0x0000000000018158 0x0000000000018158 RW 200000 LOAD 0x000000000115e000 0xffffffff81d5e000 0x0000000001d5e000 0x000000000016a000 0x0000000000301000 RWE 200000 NOTE 0x000000000099bcac 0xffffffff8179bcac 0x000000000179bcac 0x00000000000001bc 0x00000000000001bc 4 Section to Segment mapping: Segment Sections... 00 .text .notes __ex_table .rodata __bug_table .pci_fixup .tracedata __ksymtab __ksymtab_gpl __ksymtab_strings __init_rodata __param __modver 01 .data .vvar 02 .data..percpu 03 .init.text .init.data .x86_cpu_dev.init .parainstructions .altinstructions .altinstr_replacement .iommu_table .apicdrivers .exit.text .smp_locks .bss .brk 04 .notes As mentioned, run_size needs to be the size of the running kernel including .bss and .brk. We can see from the Section/Segment mapping above that .bss and .brk are included in segment 03 (which corresponds to the final LOAD program header). To find the run_size, we calculate the end of the LOAD segment from its PhysAddr start (0x0000000001d5e000) and its MemSiz (0x0000000000301000), minus the physical load address of the kernel (the first LOAD segment's PhysAddr: 0x0000000001000000). The resulting run_size is 0x105f000: 0x0000000001d5e000 + 0x0000000000301000 - 0x0000000001000000 = 0x105f000 So, from this we can see that the existing run_size calculation is 0x400000 too high. And, as it turns out, the correct run_size is actually equal to VO_end - VO_text, which is certainly easier to calculate. _end: 0xffffffff8205f000 _text:0xffffffff81000000 0xffffffff8205f000 - 0xffffffff81000000 = 0x105f000 As a result, run_size is a simple constant, so we don't need to pass it around; we already have voffset.h for such things. We can share voffset.h between misc.c and header.S instead of getting run_size in other ways. This patch moves voffset.h creation code to boot/compressed/Makefile, and switches misc.c to use the VO_end - VO_text calculation for run_size. Dependence before: boot/header.S ==> boot/voffset.h ==> vmlinux boot/header.S ==> compressed/vmlinux ==> compressed/misc.c Dependence after: boot/header.S ==> compressed/vmlinux ==> compressed/misc.c ==> boot/voffset.h ==> vmlinux Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote the changelog. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Josh Triplett <josh@joshtriplett.org> Cc: Junjie Mao <eternal.n08@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: lasse.collin@tukaani.org Fixes: e6023367d779 ("x86, kaslr: Prevent .bss from overlaping initrd") Link: http://lkml.kernel.org/r/1461888548-32439-5-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/Makefile | 11 +---------- arch/x86/boot/compressed/Makefile | 12 ++++++++++++ arch/x86/boot/compressed/misc.c | 3 +++ 3 files changed, 16 insertions(+), 10 deletions(-) commit d607251ba9acc0b5faeaa08818f60d041dd19472 Author: Yinghai Lu <yinghai@kernel.org> Date: Thu Apr 28 17:09:05 2016 -0700 x86/boot: Calculate decompression size during boot not build Currently z_extract_offset is calculated in boot/compressed/mkpiggy.c. This doesn't work well because mkpiggy.c doesn't know the details of the decompressor in use. As a result, it can only make an estimation, which has risks: - output + output_len (VO) could be much bigger than input + input_len (ZO). In this case, the decompressed kernel plus relocs could overwrite the decompression code while it is running. - The head code of ZO could be bigger than z_extract_offset. In this case an overwrite could happen when the head code is running to move ZO to the end of buffer. Though currently the size of the head code is very small it's still a potential risk. Since there is no rule to limit the size of the head code of ZO, it runs the risk of suddenly becoming a (hard to find) bug. Instead, this moves the z_extract_offset calculation into header.S, and makes adjustments to be sure that the above two cases can never happen, and further corrects the comments describing the calculations. Since we have (in the previous patch) made ZO always be located against the end of decompression buffer, z_extract_offset is only used here to calculate an appropriate buffer size (INIT_SIZE), and is not longer used elsewhere. As such, it can be removed from voffset.h. Additionally clean up #if/#else #define to improve readability. Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote the changelog and comments. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1461888548-32439-4-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/Makefile | 2 +- arch/x86/boot/compressed/mkpiggy.c | 21 ++++----------------- arch/x86/boot/header.S | 35 +++++++++++++++++++++++++---------- 3 files changed, 30 insertions(+), 28 deletions(-) commit 974f221c84b05b1dc2f5ea50dc16d2a9d1e95eda Author: Yinghai Lu <yinghai@kernel.org> Date: Thu Apr 28 17:09:04 2016 -0700 x86/boot: Move compressed kernel to the end of the decompression buffer This change makes later calculations about where the kernel is located easier to reason about. To better understand this change, we must first clarify what 'VO' and 'ZO' are. These values were introduced in commits by hpa: 77d1a4999502 ("x86, boot: make symbols from the main vmlinux available") 37ba7ab5e33c ("x86, boot: make kernel_alignment adjustable; new bzImage fields") Specifically: All names prefixed with 'VO_': - relate to the uncompressed kernel image - the size of the VO image is: VO__end-VO__text ("VO_INIT_SIZE" define) All names prefixed with 'ZO_': - relate to the bootable compressed kernel image (boot/compressed/vmlinux), which is composed of the following memory areas: - head text - compressed kernel (VO image and relocs table) - decompressor code - the size of the ZO image is: ZO__end - ZO_startup_32 ("ZO_INIT_SIZE" define, though see below) The 'INIT_SIZE' value is used to find the larger of the two image sizes: #define ZO_INIT_SIZE (ZO__end - ZO_startup_32 + ZO_z_extract_offset) #define VO_INIT_SIZE (VO__end - VO__text) #if ZO_INIT_SIZE > VO_INIT_SIZE # define INIT_SIZE ZO_INIT_SIZE #else # define INIT_SIZE VO_INIT_SIZE #endif The current code uses extract_offset to decide where to position the copied ZO (i.e. ZO starts at extract_offset). (This is why ZO_INIT_SIZE currently includes the extract_offset.) Why does z_extract_offset exist? It's needed because we are trying to minimize the amount of RAM used for the whole act of creating an uncompressed, executable, properly relocation-linked kernel image in system memory. We do this so that kernels can be booted on even very small systems. To achieve the goal of minimal memory consumption we have implemented an in-place decompression strategy: instead of cleanly separating the VO and ZO images and also allocating some memory for the decompression code's runtime needs, we instead create this elaborate layout of memory buffers where the output (decompressed) stream, as it progresses, overlaps with and destroys the input (compressed) stream. This can only be done safely if the ZO image is placed to the end of the VO range, plus a certain amount of safety distance to make sure that when the last bytes of the VO range are decompressed, the compressed stream pointer is safely beyond the end of the VO range. z_extract_offset is calculated in arch/x86/boot/compressed/mkpiggy.c during the build process, at a point when we know the exact compressed and uncompressed size of the kernel images and can calculate this safe minimum offset value. (Note that the mkpiggy.c calculation is not perfect, because we don't know the decompressor used at that stage, so the z_extract_offset calculation is necessarily imprecise and is mostly based on gzip internals - we'll improve that in the next patch.) When INIT_SIZE is bigger than VO_INIT_SIZE (uncommon but possible), the copied ZO occupies the memory from extract_offset to the end of decompression buffer. It overlaps with the soon-to-be-uncompressed kernel like this: |-----compressed kernel image------| V V 0 extract_offset +INIT_SIZE |-----------|---------------|-------------------------|--------| | | | | VO__text startup_32 of ZO VO__end ZO__end ^ ^ |-------uncompressed kernel image---------| When INIT_SIZE is equal to VO_INIT_SIZE (likely) there's still space left from end of ZO to the end of decompressing buffer, like below. |-compressed kernel image-| V V 0 extract_offset +INIT_SIZE |-----------|---------------|-------------------------|--------| | | | | VO__text startup_32 of ZO ZO__end VO__end ^ ^ |------------uncompressed kernel image-------------| To simplify calculations and avoid special cases, it is cleaner to always place the compressed kernel image in memory so that ZO__end is at the end of the decompression buffer, instead of placing t at the start of extract_offset as is currently done. This patch adds BP_init_size (which is the INIT_SIZE as passed in from the boot_params) into asm-offsets.c to make it visible to the assembly code. Then when moving the ZO, it calculates the starting position of the copied ZO (via BP_init_size and the ZO run size) so that the VO__end will be at the end of the decompression buffer. To make the position calculation safe, the end of ZO is page aligned (and a comment is added to the existing VO alignment for good measure). Signed-off-by: Yinghai Lu <yinghai@kernel.org> [ Rewrote changelog and comments. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1461888548-32439-3-git-send-email-keescook@chromium.org [ Rewrote the changelog some more. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/head_32.S | 11 +++++++++-- arch/x86/boot/compressed/head_64.S | 8 ++++++-- arch/x86/boot/compressed/misc.c | 17 +++++++++++++++++ arch/x86/boot/compressed/mkpiggy.c | 3 --- arch/x86/boot/compressed/vmlinux.lds.S | 1 + arch/x86/kernel/asm-offsets.c | 1 + arch/x86/kernel/vmlinux.lds.S | 2 +- 7 files changed, 35 insertions(+), 8 deletions(-) commit 3737de42afb8d76f405689a4699e8e5dd5e2ef96 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Apr 25 16:08:34 2016 +0530 gpio: tegra: Add support for gpio debounce NVIDIA's Tegra210 support the HW debounce in the GPIO controller for all its GPIO pins. Add support for setting debounce timing by implementing the set_debounce callback of gpiochip. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tegra.c | 69 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 68 insertions(+), 1 deletion(-) commit 92b4423e3a0bc5d43ecde4bcad871f8b5ba04efd Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Fri Apr 29 10:39:34 2016 +0200 netfilter: fix IS_ERR_VALUE usage This is a forward-port of the original patch from Andrzej Hajda, he said: "IS_ERR_VALUE should be used only with unsigned long type. Otherwise it can work incorrectly. To achieve this function xt_percpu_counter_alloc is modified to return unsigned long, and its result is assigned to temporary variable to perform error checking, before assigning to .pcnt field. The patch follows conclusion from discussion on LKML [1][2]. [1]: http://permalink.gmane.org/gmane.linux.kernel/2120927 [2]: http://permalink.gmane.org/gmane.linux.kernel/2150581" Original patch from Andrzej is here: http://patchwork.ozlabs.org/patch/582970/ This patch has clashed with input validation fixes for x_tables. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 6 +++--- net/ipv4/netfilter/arp_tables.c | 6 ++++-- net/ipv4/netfilter/ip_tables.c | 6 ++++-- net/ipv6/netfilter/ip6_tables.c | 6 ++++-- 4 files changed, 15 insertions(+), 9 deletions(-) commit 059f791c6bbaba72dc3c1bd6e2657aacc8552849 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 01:03:45 2016 +0200 btrfs: make state preallocation more speculative in __set_extent_bit Similar to __clear_extent_bit, do not fail if the state preallocation fails as we might not need it. One less BUG_ON. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 03bf5387708069194fbe5072fb57f9542e7a8b82 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 01:02:15 2016 +0200 btrfs: untangle gotos a bit in convert_extent_bit Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) commit 7ab5cb2a9e3161de3a288bafd100515b5f44f27e Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 01:02:15 2016 +0200 btrfs: untangle gotos a bit in __clear_extent_bit Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit b5a4ba14e0caa9da1b3b98939274bdeda71859e3 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 01:02:15 2016 +0200 btrfs: untangle gotos a bit in __set_extent_bit Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit 2c53b912ae317e560bce1fc446e76915a5b30587 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to set_record_extent_bits Single caller passes GFP_NOFS. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 5 ++--- fs/btrfs/extent_io.h | 3 +-- fs/btrfs/qgroup.c | 3 +-- 3 files changed, 4 insertions(+), 7 deletions(-) commit 3744dbeb7033825e53b919ae0887e08e924841a9 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to set_extent_new Single caller passes GFP_NOFS. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent-tree.c | 2 +- fs/btrfs/extent_io.h | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) commit 018ed4f788870fdf6e625d04aa287080bdc8a54f Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to set_extent_defrag Single caller passes GFP_NOFS. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.h | 4 ++-- fs/btrfs/ioctl.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 7cd8c7527cb3ad3b397fecfa1bdc8eec9fa33dd8 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to set_extent_delalloc Callers pass GFP_NOFS and tests pass GFP_KERNEL, but using NOFS there does not hurt. No need to pass the flags around. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.h | 4 ++-- fs/btrfs/inode.c | 2 +- fs/btrfs/tests/extent-io-tests.c | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) commit af6f8f604d44e05f98ed45a69830547ed133adf8 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to clear_extent_dirty Callers pass GFP_NOFS. No need to pass the flags around. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/disk-io.c | 2 +- fs/btrfs/extent-tree.c | 2 +- fs/btrfs/extent_io.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) commit f734c44a1bfffd762f6f5829cb41224d267b80d9 Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to clear_record_extent_bits Callers pass GFP_NOFS. No need to pass the flags around. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 5 ++--- fs/btrfs/extent_io.h | 3 +-- fs/btrfs/qgroup.c | 5 ++--- 3 files changed, 5 insertions(+), 8 deletions(-) commit 91166212e0ffbb4db50aa8a238548e967008b33d Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to clear_extent_bits Callers pass GFP_NOFS and GFP_KERNEL. No need to pass the flags around. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/disk-io.c | 2 +- fs/btrfs/extent-tree.c | 8 ++++---- fs/btrfs/extent_io.c | 4 ++-- fs/btrfs/extent_io.h | 5 +++-- fs/btrfs/inode.c | 3 +-- fs/btrfs/relocation.c | 3 +-- fs/btrfs/scrub.c | 2 +- fs/btrfs/tests/extent-io-tests.c | 2 +- fs/btrfs/tree-log.c | 2 +- 9 files changed, 15 insertions(+), 16 deletions(-) commit ceeb0ae7bf42a3deaaaee981d2da02e5d3ad2b0f Author: David Sterba <dsterba@suse.com> Date: Tue Apr 26 23:54:39 2016 +0200 btrfs: sink gfp parameter to set_extent_bits All callers pass GFP_NOFS. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent-tree.c | 4 ++-- fs/btrfs/extent_io.c | 5 ++--- fs/btrfs/extent_io.h | 4 ++-- fs/btrfs/file-item.c | 2 +- fs/btrfs/relocation.c | 4 ++-- fs/btrfs/scrub.c | 2 +- 6 files changed, 10 insertions(+), 11 deletions(-) commit b546be0db955840e2c14aae5d8e5f93a456f9982 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Apr 25 16:08:33 2016 +0530 gpio: tegra: Get rid of all file scoped global variables Move the file scoped multiple global variable from Tegra GPIO driver to the structure and make this as gpiochip data which can be referred from GPIO chip callbacks. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tegra.c | 350 ++++++++++++++++++++++++++-------------------- 1 file changed, 198 insertions(+), 152 deletions(-) commit 804f56804d480edc3463a91bbcb39e3b4abd2ac6 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Apr 25 16:08:32 2016 +0530 gpio: tegra: Make of_device_id compatible data to constant The data member of the of_device_id is the constant type and hence all static structure which is used for this initialisation as static. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Suggested-by: Thierry Reding <treding@nvidia.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tegra.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 171b92c830f48bd546e2d68d6f511b3d87e0544e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Apr 25 16:08:31 2016 +0530 gpio: tegra: Don't open code of_device_get_match_data() Use of_device_get_match_data() for getting matched data instead of implementing this locally. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tegra.c | 50 +++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 26 deletions(-) commit c84ffde963e227bf68efb12315bd39c75e00ff05 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sat Jan 30 14:42:36 2016 +0800 MAINTAINERS: Add maintainer for hisilicon DRM driver Add maintainer and reviewer for hisilicon DRM driver. v8: - Append "/" to directory patterns. v7: None. v6: None. v5: None. v4: - Add Chen Feng <puck.chen@hisilicon.com> as Designated reviewer. v3: First version. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> MAINTAINERS | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 40ed27b886eaad923910ed63865dac0e9b3553f2 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Mon Nov 23 10:57:04 2015 +0800 drm/hisilicon: Add support for external bridge Add support for external HDMI bridge. v8: None. v7: None. v6: None. v5: None. v4: None. v3: - Fix a typo: s/exteranl/external. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Reviewed-by: Archit Taneja <architt@codeaurora.org> drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 52 ++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) commit 834480d23398b8f8d54c795e8ae8aea740106835 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Mon Nov 23 10:43:36 2015 +0800 drm/hisilicon: Add designware dsi host driver Add DesignWare dsi host driver for hi6220 SoC. v8: None. v7: None. v6: None. v5: None. v4: None. v3: None. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Reviewed-by: Archit Taneja <architt@codeaurora.org> drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 50 ++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) commit f819b0d4a91344c1bd0ec931f16faf491e867e59 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Mon Nov 23 09:32:26 2015 +0800 drm/hisilicon: Add designware dsi encoder driver Add DesignWare MIPI DSI Host Controller v1.02 encoder driver for hi6220 SoC. v9: Fix module compile error. v8: None. v7: - A few regs define clean up. v6: - Change "pclk_dsi" to "pclk". v5: None. v4: None. v3: - Rename file name to dw_drm_dsi.c - Make encoder type as DRM_MODE_ENCODER_DSI. - A few cleanup. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Signed-off-by: Andy Green <andy.green@linaro.org> drivers/gpu/drm/hisilicon/kirin/Kconfig | 9 + drivers/gpu/drm/hisilicon/kirin/Makefile | 2 + drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 755 +++++++++++++++++++++++++++ drivers/gpu/drm/hisilicon/kirin/dw_dsi_reg.h | 103 ++++ 4 files changed, 869 insertions(+) commit 6b7a5965489c64dfc90ea650abbe9295e519753c Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sat Oct 10 14:54:14 2015 +0800 drm/hisilicon: Add cma fbdev and hotplug Add cma Fbdev, Fbdev is legency and optional, you can enable/disable it by configuring DRM_FBDEV_EMULATION. Add hotplug. v8: None. v7: None. v6: None. v5: None. v4: None. v3: None. v2: - Use CONFIG_DRM_FBDEV_EMULATION instead of CONFIG_DRM_HISI_FBDEV. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 34 +++++++++++++++++++++++++ drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.h | 3 +++ 2 files changed, 37 insertions(+) commit bc4611e8048306da2a7015f023be1994b330e883 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sat Oct 10 11:25:06 2015 +0800 drm/hisilicon: Add vblank driver for ADE Add vblank irq handle. v8: None. v7: - Fix irq flag "DRIVER_IRQF_SHARED" to "IRQF_SHARED". v6: None. v5: None. v4: None. v3: - Remove hisi_get_crtc_from_index func. - A few cleanup. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c | 62 +++++++++++++++++++++++++ drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 14 +++++- 2 files changed, 75 insertions(+), 1 deletion(-) commit d3c9a7385f1924cb80f17cc81188749386933a0f Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sat Oct 10 11:04:24 2015 +0800 drm/hisilicon: Add plane driver for ADE Add plane funcs and helper funcs for ADE. v8: None. v7: None. v6: None. v5: None. v4: None. v3: - A few cleanup. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c | 535 +++++++++++++++++++++++- 1 file changed, 534 insertions(+), 1 deletion(-) commit 783ad972c9a0e4690fa9a1580d16b64f389bc068 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Sat Oct 10 10:16:22 2015 +0800 drm/hisilicon: Add crtc driver for ADE Add crtc funcs and helper funcs for ADE. v8: None. v7: - A few Regs define clean up and typo fixs. v6: - Cleanup reg-names dt parsing. v5: - Use syscon to access ADE media NOC QoS registers instread of directly writing registers. - Use reset controller to reset ADE instead of directly writing registers. v4: None. v3: - Make ade as the master driver. - Use port to connect with encoder. - A few cleanup. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Reviewed-by: Archit Taneja <architt@codeaurora.org> drivers/gpu/drm/hisilicon/kirin/Makefile | 3 +- drivers/gpu/drm/hisilicon/kirin/kirin_ade_reg.h | 230 ++++++++++++ drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c | 462 ++++++++++++++++++++++++ drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 12 + drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.h | 8 + 5 files changed, 714 insertions(+), 1 deletion(-) commit 23e7b2ab9a8ff5653e8140248a494c3f3171dce3 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Fri Oct 9 18:00:56 2015 +0800 drm/hisilicon: Add hisilicon kirin drm master driver Add kirin DRM master driver for hi6220 SoC which used in HiKey board. Add dumb buffer feature. Add prime dmabuf feature. v9: Add OF and ARM64 depends on in Kconfig v8: None. v7: - Add config.mutex protection when accessing mode_config.connector_list. - Clean up match data getting. v6: None. v5: None. v4: None. v3: - Move and rename all the files to kirin sub-directory. So that we could separate different seires SoCs' driver. - Replace drm_platform_init, load, unload implementation. v2: - Remove abtraction layer. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/Makefile | 1 + drivers/gpu/drm/hisilicon/Kconfig | 5 + drivers/gpu/drm/hisilicon/Makefile | 5 + drivers/gpu/drm/hisilicon/kirin/Kconfig | 9 + drivers/gpu/drm/hisilicon/kirin/Makefile | 3 + drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 309 ++++++++++++++++++++++++ drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.h | 20 ++ 8 files changed, 354 insertions(+) commit 284aabb0e8c87f24922bd39f11a39f353c02d276 Author: Xinliang Liu <xinliang.liu@linaro.org> Date: Fri Oct 9 17:00:29 2015 +0800 drm/hisilicon: Add device tree binding for hi6220 display subsystem Add ADE display controller binding doc. Add DesignWare DSI Host Controller v1.20a binding doc. v8: None. v7: Acked by Rob Herring. v6: - Cleanup values part of reg and clocks properties. - Change "pclk_dsi" clock name to "pclk". v5: - Remove endpoint unit address of dsi output port. - Add "hisilicon,noc-syscon" property for ADE NOC QoS syscon. - Add "resets" property for ADE reset. v4: - Describe more specific of clocks and ports. - Fix indentation. v3: - Make ade as the drm master node. - Use assigned-clocks to set clock rate. - Use ports to connect display relavant nodes. v2: - Move dt binding docs to bindings/display/hisilicon directory. Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Acked-by: Rob Herring <robh@kernel.org> .../bindings/display/hisilicon/dw-dsi.txt | 72 ++++++++++++++++++++++ .../bindings/display/hisilicon/hisi-ade.txt | 64 +++++++++++++++++++ 2 files changed, 136 insertions(+) commit 6f9af75faa1df61e1ee5bea8a787a90605bb528d Author: Baoquan He <bhe@redhat.com> Date: Thu Apr 28 17:09:03 2016 -0700 x86/KASLR: Handle kernel relocations above 2G correctly When processing the relocation table, the offset used to calculate the relocation is an 'int'. This is sufficient for calculating the physical address of the relocs entry on 32-bit systems and on 64-bit systems when the relocation is under 2G. To handle relocations above 2G (seen in situations like kexec, netboot, etc), this offset needs to be calculated using a 'long' to avoid wrapping and miscalculating the relocation. Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote the changelog. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Young <dyoung@redhat.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vivek Goyal <vgoyal@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: lasse.collin@tukaani.org Link: http://lkml.kernel.org/r/1461888548-32439-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/misc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6c3b78aa6e46addbbf6fba590b7af4ecbe45d459 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:46 2016 -0700 staging: comedi: mite: don't expose CHSR_* bit defines These bit defines are only used in the mite driver. Move them so they are not needlessly exposed. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 36 ++++++++++++++++++++++++++++++++++ drivers/staging/comedi/drivers/mite.h | 37 ----------------------------------- 2 files changed, 36 insertions(+), 37 deletions(-) commit 0c912e5c9cbaaaa6e1d5a81f42ea3d2eb6ce7a10 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:45 2016 -0700 staging: comedi: mite: return void from mite_ack_linkc() Currently this function returns the value read from the mite channel status register. None of the callers use, or need, the returned value. For aesthetics, change the return to void. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 8 +++----- drivers/staging/comedi/drivers/mite.h | 4 ++-- 2 files changed, 5 insertions(+), 7 deletions(-) commit f7d005c33c109ef034c9480334d3d25d91aa2d6d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:44 2016 -0700 staging: comedi: mite: make mite_ack_linkc() handle mite_sync_dma() The mite dma is always synced on a LINKC status. Some of the mite users sync the dma regadless of the status. Add a 'sync' parameter to mite_ack_linkc() to force a dma sync. Then do the dma sync as needed. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 10 ++++++++-- drivers/staging/comedi/drivers/mite.h | 4 ++-- drivers/staging/comedi/drivers/ni_mio_common.c | 23 ++++++----------------- drivers/staging/comedi/drivers/ni_pcidio.c | 9 ++------- drivers/staging/comedi/drivers/ni_tiocmd.c | 6 ++---- 5 files changed, 20 insertions(+), 32 deletions(-) commit 3da088cae2a5f2ae6e8192db4b6e36496fd81514 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:43 2016 -0700 staging: comedi: ni_mio_common: handle_a_interrupt() does not need ai_mite_status This function only handles the analog input interrupts, the dma was already handled. Remove the unecessary parameter and fix ni_E_interrupts() so that the comedi events are properly handled. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) commit 7101711ee4706915380bdd103902e864380a6987 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:42 2016 -0700 staging: comedi: ni_mio_common: simplify AI LINKC handling Simplfy the LINKC handing for the analog input dma by moving it into the main interrupt handler. This function already hold the spinlock mite_channel_lock so call mite_sync_dma() directly instead of using the helper function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit ba5c0da886c5f75f3bf7cab2f1f23a9ba05e04a5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:41 2016 -0700 staging: comedi: ni_mio_common: fix interrupt handler for dev->read_subdev There may not be a dev->read_subdev, i.e. an analog input subdevice, that supports async commands. If it doesn't exist the interrupt/dma will never be enabled. Fix ni_E_interrupt() so that the analog input subdevice is only handled if it exists. This also fixes minor NULL dereference issue in handle_a_interrupt(). If the dev->read_subdev is NULL the comedi_async pointer (s->async) will not be allocated by the device postconfig so there is no way to get a valid comedi_cmd (&s->async->cmd). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) commit 4b2d73898fdd75cc841a2a6fc978fdc7b5f5247a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:40 2016 -0700 staging: comedi: ni_mio_common: handle_b_interrupt() does not need ao_mite_status This function only handles the analog input interrupts, the dma was already handled. Remove the unecessary parameter and fix ni_E_interrupts() so that the comedi events are properly handled. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit 7ef1745f29d12b31361d0cf3a2bc259a396aac10 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:39 2016 -0700 staging: comedi: ni_mio_common: fix interrupt handler for dev->write_subdev There may not be a dev->write_subdev, i.e. an analog output subdevice, that supports async commands. If it doesn't exist the interrupt/dma will never be enabled. Fix ni_E_interrupt() so that the analog output subdevice is only handled if it exists. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 72639a16704b10cf5fffaa52715929dc8f081528 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:38 2016 -0700 staging: comedi: ni_mio_common: absorb mite_handle_b_linkc() Simplfy the LINKC handing by removing the helper function and moving the mite_sync_dma() into the main interrupt handler. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 31 ++++++-------------------- 1 file changed, 7 insertions(+), 24 deletions(-) commit cc38da7287ed4f0f08956351167c31e4e6abc427 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 21 12:04:37 2016 -0700 staging: comedi: mite: check for transfer errors in mite_ack_linkc() Currently only some of the users of mite dma check for transfer errors. The ni_mio_common code does the check for the analog input and analog output subdevices. The m-series digital I/O subdevice and the counter subdevices (handled by ni_tiocmd) do not check. The ni_pcidio driver checks for the digital input subdevice. The ni_660x driver counter subdevices (handled by ni_tiocmd) also do not check. Move the transfer error checking into mite_ack_linkc() so that the drivers that use mite don't have to deal with it. This also makes sure that all the subdevices that use mite for dma will cancel the async command if a transfer error is detected. Simplfy the transfer error check by just checking the CHSR_XFERR bit. This bit will be set if one or more transfer processes terminated with an error. The actual error is determined by the LERR, MERR, and DERR bits. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 8 +++++++- drivers/staging/comedi/drivers/mite.h | 3 ++- drivers/staging/comedi/drivers/ni_mio_common.c | 27 +++++--------------------- drivers/staging/comedi/drivers/ni_pcidio.c | 10 ++-------- drivers/staging/comedi/drivers/ni_tiocmd.c | 2 +- 5 files changed, 17 insertions(+), 33 deletions(-) commit 21e871fef7a681826c661332c285be95f0204aca Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:43 2016 -0700 staging: comedi: mite: cleanup remaining mite register/bits For aesthetics, convert the register/bit enums into defines and use the BIT() macro to define the bits. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.h | 88 +++++++++++++++++------------------ 1 file changed, 44 insertions(+), 44 deletions(-) commit 7024cc88bf80644c50d125a47ae5ab6b7f675216 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:42 2016 -0700 staging: comedi: mite: remove BUG_ON() in MITE_IODWBSR_1_WSIZE_bits() Prior to calling this function pci_ioremap_bar() is called. If the pci_resource_len(), i.e. the 'size', was 0 the ioremap would fail so this function would never be called. So the first BUG_ON() can never occur. The 'order' returned by ilog2() will always be > 0 so the second BUG_ON() will also never occur. Remove the unnecessary BUG_ON() checks and tidy up the function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 43d667243c734fe7de39a586a095ea8fec9a873a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:41 2016 -0700 staging: comedi: mite: document the mite_struct spinlock_t Add a comment to fix the checkpatch.pl issue: CHECK: spinlock_t definition without comment Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.h | 1 + 1 file changed, 1 insertion(+) commit 268bc9cd3a3cfb0cafaa484f463084ccb1abf9f7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:40 2016 -0700 staging: comedi: mite: rename CamelCase CHSR bit enums Rename the CamelCase symbols to fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 51d430056c2a695ff7ffc62ae917c413616ec6b2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:39 2016 -0700 staging: comedi: mite: introduce mite_sync_dma() The struct mite_channel 'dir' member specifies if the dma is input or output. Wrap the mite_sync_input_dma() and mite_sync_output_dma() functions with a single mite_sync_dma() so that the drivers don't have to worry about the sync direction. The functions that actually sync the input/output dma currently return -1 if an overflow/underrun is detected otherwise they return 0. If an overflow/underrun is detected the async->event COMEDI_CB_OVERFLOW is also set. The callers never check the return value anyway so just make the functions return void. The async->event can be checked if necessary to detect any errors. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 43 +++++++++++++------------- drivers/staging/comedi/drivers/mite.h | 5 +-- drivers/staging/comedi/drivers/ni_660x.c | 2 +- drivers/staging/comedi/drivers/ni_mio_common.c | 6 ++-- drivers/staging/comedi/drivers/ni_pcidio.c | 4 +-- drivers/staging/comedi/drivers/ni_tiocmd.c | 2 +- 6 files changed, 30 insertions(+), 32 deletions(-) commit 33b0b6913d1304407f71a6a92ef1ad9e064cdf01 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:38 2016 -0700 staging: comedi: mite: don't expose unnecessary register/bit info Most of the mite registers are only accessed by the mite driver. There is no reason to expose the register/bit info. Remove this info from the header. For aesthetics, convert the bit info enums into defines and use the BIT() macro to define them. Tidy up the inline functions for the retry limit and drq reqs bits in the config registers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 160 +++++++++++++++++++++++++++-- drivers/staging/comedi/drivers/mite.h | 186 ---------------------------------- 2 files changed, 151 insertions(+), 195 deletions(-) commit 4d88096df9ca49b71381eda90aa770c6db237f54 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:37 2016 -0700 staging: comedi: mite: introduce mite_ack_linkc() Introduce a helper function to handle the ack of a LINKC interrupt. Tidy up the drivers that use the new helper. The extra check for CHSR_INT in the ni_pcidio driver is not necessary. This bit will be set if any of the interrupt sources, including CHSR_LINKC, have generated an interrupt. Remove the extra check. The mite_get_status() function is now only used by the mite driver. Make it static and remove the export. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 17 ++++++++++++++-- drivers/staging/comedi/drivers/mite.h | 2 +- drivers/staging/comedi/drivers/ni_mio_common.c | 28 +++++--------------------- drivers/staging/comedi/drivers/ni_pcidio.c | 10 ++------- drivers/staging/comedi/drivers/ni_tiocmd.c | 13 +++--------- 5 files changed, 26 insertions(+), 44 deletions(-) commit 96f31530006492b2c753311431acf71df88b0cdd Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:36 2016 -0700 staging: comedi: mite: don't expose mite_dma_reset() This function is only called by the mite driver. Remove the inline function from the header and make it static in the driver. Use the function in mite_prep_dma() instead of duplicating the code. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 12 ++++++++---- drivers/staging/comedi/drivers/mite.h | 6 ------ 2 files changed, 8 insertions(+), 10 deletions(-) commit eecbadef12d1e9781d48f31875fa9f5f79194a65 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:35 2016 -0700 staging: comedi: ni_pcidio: remove redundant mite disarm/reset The mite_release_channel() will disarm and reset the mite channel. Remove the redundant calls in ni_pcidio_release_di_mite_channel(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_pcidio.c | 2 -- 1 file changed, 2 deletions(-) commit ef81f55b07c2efe80d0ea80527426ef319a4a5e7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:34 2016 -0700 staging: comedi: mite: remove mite_struct member 'daq_phys_addr' This member of mite_struct is only used to map the mite I/O window. For aesthetics, remove it and use a local variable instead. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 7 ++++--- drivers/staging/comedi/drivers/mite.h | 1 - drivers/staging/comedi/drivers/ni_pcimio.c | 6 +++++- 3 files changed, 9 insertions(+), 5 deletions(-) commit 0db6624ae0d6aa30c6ed2fee262edf04bba3962e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:33 2016 -0700 staging: comedi: mite: remove mite_struct member 'mite_phys_addr' This member of mite_struct is set but never used. Just remove it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 1 - drivers/staging/comedi/drivers/mite.h | 1 - 2 files changed, 2 deletions(-) commit 0d9bfc24125267a41912e337c1471fc2d5a17611 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:32 2016 -0700 staging: comedi: mite: don't export internal functions The functions that get the number of bytes written to and read from memory are only used internally by the mite driver when syncing the dma channel. Make them static and remove the exports. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 12 ++++-------- drivers/staging/comedi/drivers/mite.h | 4 ---- 2 files changed, 4 insertions(+), 12 deletions(-) commit a2a9d1b4c5c4e7b420a50e263ed202d1648458f8 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:31 2016 -0700 staging: comedi: mite: remove mite_dma_tcr() This exported function is not used by any of the comedi drivers. The only call point in mite.c is commented out. Remove the unused function and the export. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 9 --------- drivers/staging/comedi/drivers/mite.h | 1 - 2 files changed, 10 deletions(-) commit ace613ee7ca711b5ad8e239679755b74af4f5e38 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:30 2016 -0700 staging: comedi: mite: remove TOP_OF_PAGE() macro This macro is not used. Remove it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 2 -- 1 file changed, 2 deletions(-) commit aac00ea22cd4116959ea297a80ac815f4db0219f Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Apr 20 10:36:29 2016 -0700 staging: comedi: mite: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.c | 29 +++++++++++++++-------------- drivers/staging/comedi/drivers/mite.h | 17 +++++++++-------- 2 files changed, 24 insertions(+), 22 deletions(-) commit 6f7fa704648e69a295f6b8bcf35538692258fbb3 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:07 2016 -0700 staging: comedi: ni_mio_common: introduce NI_STC_DMA_CHAN_SEL() The inline helper ni_stc_dma_channel_select_bitfield() returns the bits needed to select a MITE channel to use for DMA. The MITE code is setup to handle up to 8 channels but in reality only channels 0 to 3 are used by most of the drivers. The PCI-6032E and PCI-6033E boards can also use channels 4 and 5. For aesthetics, convert this inline function into a macro and remove the BUG() which will never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 29 ++++++++++---------------- 1 file changed, 11 insertions(+), 18 deletions(-) commit bbd962206c6002005a827d34d91005cbfbf9dddc Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:06 2016 -0700 staging: comedi: mite.h: rename CHSR_LxERR_mask Fix the checkpatch.pl issue: CHECK: Avoid CamelCase: <CHSR_LxERR_mask> Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/mite.h | 2 +- drivers/staging/comedi/drivers/ni_mio_common.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit b24a3ecd460689b08c5ffd3f735d4228f8bfffc7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:05 2016 -0700 staging: comedi: ni_mio_common: fix CamelCase in ni_serial_hw_readwrite8() Fix the checkpatch.pl issue: CHECK: Avoid CamelCase: <Error> Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 68556ffc95771c55843f1be459d13938fac83f77 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:04 2016 -0700 staging: comedi: ni_mio_common: remove 'fudge_factor_80_to_20Mhz' For aesthetics, remove this local variable to fix the checkpatch.pl issue: CHECK: Avoid CamelCase: <fudge_factor_80_to_20Mhz> Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 8a5b817ff7f6c902b478bae1b58c41b4298ae62e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:03 2016 -0700 staging: comedi: ni_mio_common: usleep_range is preferred over udelay Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2e2f7b70374bc420d4695675ccc5b35756badef6 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:02 2016 -0700 staging: comedi: ni_mio_common: tidy up ni_gpct_write_register() The 'bits' value passed to this function is properly set by the callers so the BUG_ON() can never occur when writing to the NITIO_G[01]_INT_ENA and NITIO_G01_RESET registers. Remove the BUG_ON() checks. For aesthetic, also remove the static const variables. They don't add any additional clarity. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) commit 1392dccbbd70a064864ac698e2897a22a8ce370c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:01 2016 -0700 staging: comedi: ni_mio_common: tidy up AO scan begin The (*do_cmdtest) validates that the cmd->scan_begin_src will only be TRIG_TIMER or TRIG_EXT. Refactor ni_ao_cmd_set_update() and remove the BUG() which can never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 39 ++++++++++---------------- 1 file changed, 15 insertions(+), 24 deletions(-) commit 55f9e7d9d35ac681dc899c9874dec35976c27dda Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:58:00 2016 -0700 staging: comedi: ni_mio_common: tidy up AO trigger selection The AO subdevice (*cancel), ni_ao_reset(), always sets the private data 'ao_trigger_select' to 0. So when a command is started the 'trigsel' value in ni_ao_cmd_set_trigger() will always start as 0. Remove the unnecessary member from the private data. The (*do_cmdtest) validates that the cmd->start_src will only be TRIG_INT or TRIG_EXT. Refactor ni_ao_cmd_set_trigger() and remove the BUG() which can never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 47 ++++++++------------------ drivers/staging/comedi/drivers/ni_stc.h | 1 - 2 files changed, 14 insertions(+), 34 deletions(-) commit 0b235d5ce4e084535e27e0416449d3c3b0d133ea Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:59 2016 -0700 staging: comedi: ni_mio_common: convert NI_GPCT_SUBDEV to a macro The 'counter_index' is always in range (0 to < NUM_GPCT, which is 2). For aesthetics, convert this inline function into a macro and remove the BUG() which can never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) commit 73894987d6747f39fe7a08b5b25d33a2883d09e2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:58 2016 -0700 staging: comedi: ni_mio_common: fix logical continuations Fix the checkpatch.pl issues: CHECK: Logical continuations should be on the previous line Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit beb1cc1b020e32261fc6c45020501b507ae54d65 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:57 2016 -0700 staging: comedi: ni_mio_common: multiple assignments should be avoided Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b6a0e5b32a206507b21474ad04a4854fbbda2e69 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:56 2016 -0700 staging: comedi: ni_mio_common: fix lines over 80 characters Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 78 ++++++++++++++++---------- 1 file changed, 49 insertions(+), 29 deletions(-) commit bd474a02d3a3cce9086b85d038fc0f37e4b74cef Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:55 2016 -0700 staging: comedi: ni_mio_common: tidy up block comments Fix the checkpatch.pl issues. WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 211 ++++++++++++++----------- 1 file changed, 117 insertions(+), 94 deletions(-) commit 546615f9f9c6458b6a2dcdef5f64038858719136 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:54 2016 -0700 staging: comedi: ni_mio_common: use 'unsigned int' instead of kernel types Generally comedi drivers use 'unsigned int' types instead of the kernel type 'u32' for unsigned 32-bit values. For aesthetics, change all the 'u32' and 'uin32_t' types and fix the checkpatch.pl issues about: CHECK: Prefer kernel type 'u32' over 'uint32_t' The various i/o helpers use for reading and writing the 32/16/8-bit registers all start with an 'unsigned int' value for writing and finally return an 'unsigned int' value. For aesthetics, change all the 'uint16_t' and 'uint8_t' types for insigned int and fix the checkpatch.pl issues about: CHECK: Prefer kernel type 'u16' over 'uint16_t' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 46 ++++++++++++++------------ 1 file changed, 24 insertions(+), 22 deletions(-) commit fe20a34aff061814da31fa7e2ac5bd4e62c2c328 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:53 2016 -0700 staging: comedi: ni_mio_common: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 172 +++++++++++++------------ 1 file changed, 90 insertions(+), 82 deletions(-) commit cf122bb4a641e091b6b5322c907ea3853eef6566 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:52 2016 -0700 staging: comedi: ni_mio_common: tidy up DIO subdevice ifdef'ery This file is is bit of a mess. It's included by the ni_atmio, ni_mio_cs, and ni_pcimio drivers. The ni_pcimio driver is the only one that uses DMA. It defines PCIDMA so that the dma code is compiled it. This causes a bunch of ifdef'ery in the file. The DIO subdevice for the ni_pcidio "is_m_series" boards is quite different from the standard e-series DIO. Mainly it supports async commands that use DMA. Tidy up some of the ifdef'ery by adding ifdef to the subdevice init. Move the is_m_series check to the main interrupt handler so that the unneded handle_cdio_interrupt() can be blocked out for the ni_atmio and ni_mio_cs drivers. Consolidate the other ifdef's to block out the affected code. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 29 +++++++++----------------- 1 file changed, 10 insertions(+), 19 deletions(-) commit b7cd3f604954cac03717b522d0ef02cc7c01f257 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:51 2016 -0700 staging: comedi: ni_mio_common: tidy up mite dma channel releases Absorb the inline helper functions that call ni_set_bitfield() to clear the dma channel selection bits. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 35 ++++++-------------------- 1 file changed, 8 insertions(+), 27 deletions(-) commit 38b81a7a41d48e84d71f0b65fa15a684c9ae81da Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:50 2016 -0700 staging: comedi: ni_mio_common: tidy up mite dma channel requests Tidy up the functions that request the mite dma channels by absorbing the inline helper functions that call ni_set_bitfield() to set the channel selection bits. Add support for the NI_M_CDIO_DMA_SEL_REG register to ni_set_bitfield() so that all the soft_reg_copy_lock spinlocking is done in one place. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 140 +++++++++++-------------- 1 file changed, 59 insertions(+), 81 deletions(-) commit bf2388b1eab18018cb469c7c55b837b1da911043 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Apr 14 09:57:49 2016 -0700 staging: comedi: ni_mio_common: remove some unnecessary BUG_ON() The mite dma channels are only requested by a subdevice with a (*do_cmd) and they are released by a (*cancel). The comedi core will only call the (*do_cmd) if the subdevice is not already running a command and all commands are terminated by the core with a (*cancel). Remove the BUG_ON() checks in the request functions which can never happen. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 4 ---- 1 file changed, 4 deletions(-) commit 098353038bedf133860c5457488a895bd1de00c1 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:06 2016 -0700 staging: comedi: das1800: update the MODULE_DESCRIPTION Change the MODULE_DESCRIPTION to something more usefull than the generic "Comedi low-level driver". Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a6b7dbb2be27636e80e4124f157e08b33e451b80 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:05 2016 -0700 staging: comedi: das1800: allow setting the external trigger polarity The external pin TGIN can be used to start and/or stop the analog input command. Currently the driver only supports negative edge polarity for this signal. Add support to allow the user to select positive edge polarity using the CR_INVERT flag. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) commit a2706b094353b6210446af3be174c9eddfd7ce01 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:04 2016 -0700 staging: comedi: das1800: clarify the analog input cmd triggers Clarify the documentation in the comedi driver comment block to better explain the cmd triggert. Add a comment to step 2b of the (*do_cmdtest) to clarify the trigger check. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 36 ++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 11 deletions(-) commit 5f657f8bf3fd4a238239264dc56b2edd6bee9e07 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:03 2016 -0700 staging: comedi: das1800: fix comments about the 'ao' board range The waveform analog outputs on the 'ao' boards are not currently supported. Modify the comment about the analog output range on these boards so that the information is saved but fixes the checkpatch.pl issues: WARNING: Block comments use a trailing */ on a separate line Move the comment so it's grouped with the comedi_lrange info. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit 6d8c9a9e88ae4d4f0fb9970cb3757eaefe4370fd Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:02 2016 -0700 staging: comedi: das1800: fix lines over 80 characters These comments are just extra cruft. Remove them to fix the checkpatch.pl issues: WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit b52fd5f08ea6949a0855fb180641257160bbec76 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:01 2016 -0700 staging: comedi: das1800: fix comments in das1800_ai_handler() Fix the checkpatch.pl issues: WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 99ad808faf61cb884c3e6e5643114f8e3326c7e8 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:42:00 2016 -0700 staging: comedi: das1800: fix comments in das1800_ai_cmd() Fix the checkpatch.pl issues: WARNING: Block comments use a trailing */ on a separate line WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 18092f4486138195cc49d2ced17e0a4f38b4718a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:59 2016 -0700 staging: comedi: das1800: remove the function comments These comments are just added cruft. Remove them. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 4 ---- 1 file changed, 4 deletions(-) commit 7d5fa05cc41bba07908661de9790ad9291777ba6 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:58 2016 -0700 staging: comedi: das1800: clarify step 4 of the ai (*do_cmdtest) This step of the (*do_cmdtest) fixes the timing arguments when the cmd->convert_src is TRIG_TIMER. The code is compact but it's a bit hard to understand the "burst mode" vs. "non burst mode" (i.e. paced) timing. Clarify the fixup by splitting it into separate functions to check the arguments based on if the command is doing 'paced' or 'burst' timing. Add some comments to clarify the fixups. This also fixes a minor issue with the 'burst' timing. When the cmd->scan_begin_src is also TRIG_TIMER the pacer clock is used to start each scan. The cmd->scan_begin_arg specifies the scan time. The minimum (not maximum) value for this time must be large enough for the 'burst' conversion time to sample all the channels. The current 'max' check limits the scan time to the minimum time (i.e. the max conversion speed). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 101 +++++++++++++++++++------------ 1 file changed, 61 insertions(+), 40 deletions(-) commit cf9eaee0edaf77d46be528f6293c08deb7b646e8 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:57 2016 -0700 staging: comedi: das1800: remove the private data member comments The comments about the members of the private data are not really necessary and removing them fixes a couple checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 5b28b8c45979e78e91773ec93a33c5dbafb737f7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:56 2016 -0700 staging: comedi: das1800: move comment about max conversion speeds For aesthetics, move this information into the comedi comment block. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit cc3ddba2c5ca09f477b072286d7d43493d347188 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:55 2016 -0700 staging: comedi: das1800: change type of private data 'fifo_buf' Fix the checkpatch.pl issue: CHECK: Prefer kernel type 'u16' over 'uint16_t' Change the type to 'unsigned short' as that is more typical in comedi drivers. Use sizeof(*p) instead of sizeof(type) when allocation the buffer. Also fix the checkpatch.pl issue: WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit bface0f3233043bcd50a29f35496ff8ceefd5b90 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:54 2016 -0700 staging: comedi: das1800: cleanup copyright and comedi comment blocks Tidy up these multi-line comments to fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 150 ++++++++++++------------------- 1 file changed, 58 insertions(+), 92 deletions(-) commit 983330210fe138e1194e0b2ccca02400ae41c0be Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:53 2016 -0700 staging: comedi: das1800: document the spinlock The comedi_device spinlock is used to protect the indirect addressing selected by the DAS1800_SELECT register. It also prevents races between the interrupt handler and the analog input (*poll). Update the comments to make this clear. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) commit fb90ec01bc8364a6ae7b8436c759f7541ebfd37f Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:52 2016 -0700 staging: comedi: das1800: absorb control_a_bits() Absorb this helper function into the analog input (*do_cmd). For aesthetics, convert the switch code into if/else. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 31 +++++++------------------------ 1 file changed, 7 insertions(+), 24 deletions(-) commit cfc2236bbce6f0e21e2618c02d750a5239d45352 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:51 2016 -0700 staging: comedi: das1800: use comedi_timeout() Use the helper function to handle the busywaiting for the analog input conversion to complete. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 34 ++++++++++++++++++++------------ 1 file changed, 21 insertions(+), 13 deletions(-) commit 7b1924b6fc8a9dbf602458bfba45065301fada48 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:50 2016 -0700 staging: comedi: das1800: refactor program_chanlist() Refactor this function so it can be used to program the chanlist for the analog input (*do_cmd) and (*insn_read). Rename the function so it has namespace associated with the driver. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 68 ++++++++++++++++---------------- 1 file changed, 34 insertions(+), 34 deletions(-) commit ceba8220df4705e61f7a7c519e2f73e67dd05528 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:49 2016 -0700 staging: comedi: das1800: absorb control_c_bits() Absorb this helper function into the analog input (*do_cmd). For aesthetics, convert the switch code into if/else. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 58 +++++++++++--------------------- 1 file changed, 19 insertions(+), 39 deletions(-) commit 843681c8835bcf4e02f993beae65e356a01d0111 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:48 2016 -0700 staging: comedi: das1800: introduce das1800_ai_chanspec_bits() Introduce a helper function for the common code needed to set the control c register bits for a channel specification. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 47 +++++++++++++++----------------- 1 file changed, 22 insertions(+), 25 deletions(-) commit 750bca653d0efae236b07988c013485ccd0a5f22 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:47 2016 -0700 staging: comedi: das1800: add analog output readback Use the core provided readback support to allow reading back the last value written to the analog output channels. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit a5405cfa1b37ea2156abdbb589e06e29140844f4 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:46 2016 -0700 staging: comedi: das1800: change type of 'ai_speed' boardinfo This value is compared against the unsigned int cmd->convert_arg to check the minimum value (max speed) for the analog input conversion timing. For aesthetics, change the type to match the cmd->convert_arg type. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ac8ebf8a8ff5b9e80b35b380ddcafd54bf6b5c8e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:45 2016 -0700 staging: comedi: das1800: remove 'qram_len' boardinfo The "hc" type boards have 64 analog input channels with a 64 entry queue. All the others have 16 channels and a 256 entry queue. EXP-1800 expansion boards can be used to increase the number of analog inputs on the 16 channel boards, 16 channels per EXP-1800, for a total of 256 channels. Remove the 'qram_len' member of the boardinfo and use the 'id' member to determine the number of channels. Add a comment about the number of channels and the unclear mapping of the channels when EXP-1800 boards are used. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 36 +++++++++++++------------------- 1 file changed, 15 insertions(+), 21 deletions(-) commit 5068827a7818cb54763975a34a0e59f1d1827ad8 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:44 2016 -0700 staging: comedi: das1800: refactor 'range_ai' boardinfo The boards supported by this driver have analog inputs with gains of 1, 10, 50, and 250 ("01" type) or 1, 2, 4, and 8 ("02" type). Unfortunately, the "01"/"02" type cannot be determined from the boards id or by probing. Replace the 'range_ai' member of the boardinfo with a bit-field flag, 'is_01_series' and only set it for the "01" type boards. Remove the unnecessary initialization for the "02" type boards. For aesthetics, rename the comedi_lrange arrays and document the gain. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 67 +++++++++++++------------------- 1 file changed, 28 insertions(+), 39 deletions(-) commit 8114b5ecb8dc9d2b79b9cba12c4edb737da80575 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:43 2016 -0700 staging: comedi: das1800: remove 'ao_ability' boardinfo The "da" and "hc" type boards have normal analog outputs. The "ao" type boards have move advanced analog outputs with waveform generation capability. Remove the 'ao_ability' member of the boardinfo and use the 'id' member to determine if the subdevice should be initialized. The "ao" waveform analog outputs are not currently supported. For aesthetics, add an else if for the initialization of the subdevice for these boards. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 31 +++++++++---------------------- 1 file changed, 9 insertions(+), 22 deletions(-) commit 1322f148983dfc91f2f011043bcdbc6de4a9df33 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:42 2016 -0700 staging: comedi: das1800: remove 'ao_n_chan' boardinfo The "st-da" board types have 4 analog output channels. All other board types, with analog outputs, only have 2 channels. Remove the 'ao_n_chan' member of the boardinfo and use the 'id' member to determine the subdevice 'n_chan'. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) commit 4c6f738e0f15a8d7a264f49f3d4f42a458edf773 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:41 2016 -0700 staging: comedi: das1800: tidy up das1800_ao_insn_write() The (*insn_write) functions are supposed to write insn->n values to the specified channel. Tidy up this function and make it work like the core expects. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 46 ++++++++++++++++++-------------- 1 file changed, 26 insertions(+), 20 deletions(-) commit 605b670e9b0ca1036dee636701af0dd220927e67 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:40 2016 -0700 staging: comedi: das1800: initialize all analog outputs The current code used to initialize the analog outputs only sets the last channel. The other channels will be reloaded with the last value that was written to them. Move the code into the subdevice init and properly initialize all the channels to 0V. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit bc524200ed26d173c78be46e4753c6f7754dc84e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:39 2016 -0700 staging: comedi: das1800: remove 'do_n_chan' boardinfo The "hc" type boards have 8 digtial outputs. All other board types have 4. Remove the 'do_n_chan' member of the boardinfo and use the 'id' member to determine the subdevice 'n_chan'. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) commit dad1e30fde3c4c9c9f8f24afa5a5c3404d19213f Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:38 2016 -0700 staging: comedi: das1800: remove 'resolution' boardinfo The "hr" type boards have 16-bit analog inputs and outputs. All other board types have 12-bit. Remove the 'resolution' member of the boardinfo and use the 'id' member to determine the subdevices 'maxdata'. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 26 +++++--------------------- 1 file changed, 5 insertions(+), 21 deletions(-) commit 90f39b9f996a6de8da850a71502ab2bef24cfe9b Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:37 2016 -0700 staging: comedi: das1800: use comedi_offset_munge() for analog output The analog outputs expect 2's complement data. For aesthetics, use the helper function to handle the munging instead of depending on the boardinfo 'resolution'. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 7a9254962bf3b636a3c04da69e94bc00da7d5935 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:36 2016 -0700 staging: comedi: das1800: remove 'common' boardinfo member The "hc" type boards do not support common mode analog inputs all the other board types do. Remove the unnecessary member from the boardinfo and use the 'id' member to determine if the SDF_COMMON flag should be set for the subdevice. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) commit fa33428fe00743dd11965f6276a994f3088f551d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:35 2016 -0700 staging: comedi: das1800: tidy up das1800_probe() Refactor das1800_probe() to return an errno instead of the boardinfo pointer. Add the board 'id' to the boardinfo to tidy up this function to clarify the sanity check when the user provided a board name when trying to attach to the driver. Currently when this function probes for a boardinfo based on the board id it returns the wrong boardinfo for the "st-da" and "hr-da" types. This causes the analog input subdevice for those boards to not be available. Fix the probe so that a proper boardinfo is used. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 207 +++++++++++++++++++------------ 1 file changed, 131 insertions(+), 76 deletions(-) commit 1e436ce3ffc26230f3e422eed8db557ba7471a07 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:34 2016 -0700 staging: comedi: das1800: tidy up boardinfo For aesthetics, add some whitespace to the boardinfo array. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 377 +++++++++++++++---------------- 1 file changed, 180 insertions(+), 197 deletions(-) commit 768417450edf0592c032895854a6bf0ce37263c7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:33 2016 -0700 staging: comedi: das1800: tidy up analog input subdevice init For aesthetics, add some whitespace to the subdevice init and rename the subdevice support functions. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 57 ++++++++++++++++---------------- 1 file changed, 28 insertions(+), 29 deletions(-) commit f4c96e0120cf8fe75ce2706eb8de8dc1e9fd17ef Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:32 2016 -0700 staging: comedi: das1800: tidy up analog output subdevice init For aesthetics, add some whitespace to the subdevice init and rename the (*insn_write) function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit 92a3b54bd20eb15b5b7c6b70ba3423776ebcd2f0 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:31 2016 -0700 staging: comedi: das1800: tidy up digital input subdevice init For aesthetics, add some whitespace to the subdevice init and rename the (*insn_bits) function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 5934ff9e7b5d584bf54cc47caab174f11364a45a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 12:41:30 2016 -0700 staging: comedi: das1800: tidy up digital output subdevice init For aesthetics, add some whitespace to the subdevice init and rename the (*insn_bits) function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit a512f530f6046dd84f190c67cdf768865eddd53b Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:18:21 2016 -0700 staging: comedi: plx9080.h: rename CamelCase enum value Rename the enum value to fix the checkpatch.pl issue: CHECK: Avoid CamelCase: <MARB_PCIv21_MODE> Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/plx9080.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a104336d0eb929c589af841185c9aa7b5e03f81c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:32:18 2016 -0700 staging: comedi: comedi_8254.h: tidy up the register map defines Tidy up the defines to fix the checkpatch.pl issues: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/comedi_8254.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit d074aeb888d412424d9951c8f28dab53f2b54729 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:23:25 2016 -0700 staging: comedi: amcc_s5933.h: tidy up comment issues Tidy up the comments to fix the checkpatch.pl isses: WARNING: Block comments use * on subsequent lines WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amcc_s5933.h | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit c0cb87af51ffef22250f4aa760f80c6667b12933 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:12:57 2016 -0700 staging: comedi: ni_stc.h: tidy up block comments Tidy up the block comments to fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_stc.h | 35 ++++++++++++++++----------------- 1 file changed, 17 insertions(+), 18 deletions(-) commit fb82926f24bb244f902903cd03b345b9b7545737 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:12:56 2016 -0700 staging: comedi: ni_stc.h: Prefer kernel type 'u8' over 'uint8_t' Change the type to fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_stc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fd46fe738165a63302b081c4ed48b1c6cfa2bdbb Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Mon Apr 11 11:12:55 2016 -0700 staging: comedi: ni_stc.h: Prefer 'unsigned int' to bare use of 'unsigned' Change the types to fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_stc.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 30539a115564ab0fda5e9e2af469273bf4b9236a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 10:15:00 2016 -0700 staging: comedi: das1800: fix das-1801st-da boardinfo The "da" type boards all have 4 analog outputs. Fix the boardinfo for the das-1801st-da. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit afd055838cfb6f387e8b6d1f884a7ff529524e06 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 10:14:59 2016 -0700 staging: comedi: das1800: fix analog input sample munging The analog input samples are 2's complement when the inputs are configured for bipolar ranges and offset binary when they are unipolar ranges. For bipolar ranges the sample needs to be munged to the offset binary format that comedi uses. The (*insn_read) does the munging correctly but the async command support incorrectly munges the data for both bipolar and unipolar ranges when reading the remaining samples from the fifo in das1800_handle_fifo_not_empty(). Add a (*munge) function to the analog input subdevice so that the samples are correctly munged when they are added to the async buffer by comedi_buf_write_samples(). Add a flag to the private data and set it in the (*do_cmd) so that the munging is only done for bipolar ranges. Clarify the code by using the core helper functions to check the range and do the munging. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 84 ++++++++++++++------------------ 1 file changed, 36 insertions(+), 48 deletions(-) commit d375278d666760e195693b57415ba0a125cadd55 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Fri Apr 8 10:14:58 2016 -0700 staging: comedi: das1800: fix possible NULL dereference DMA is optional with this driver. If it was not enabled the devpriv->dma pointer will be NULL. Fix the possible NULL pointer dereference when trying to disable the DMA channels in das1800_ai_cancel() and tidy up the comments to fix the checkpatch.pl issues: WARNING: line over 80 characters It's probably harmless in das1800_ai_setup_dma() because the 'desc' pointer will not be used if DMA is disabled but fix it there also. Fixes: 99dfc3357e98 ("staging: comedi: das1800: remove depends on ISA_DMA_API limitation") Cc: <stable@vger.kernel.org> # 4.0+ Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/das1800.c | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) commit 3a56d700f60cd3cdc2c1429d107f0818555a5b22 Author: David Binder <david.binder@unisys.com> Date: Mon Apr 18 23:40:09 2016 -0400 staging: unisys: visorbus: initialize variables Initializes previously uninitialized variables that were flagged as being problematic by Smatch. Signed-off-by: David Binder <david.binder@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 260d89929c2f45b4b46180e58798bcdee53e0c07 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Tue Apr 19 08:11:52 2016 -0400 staging: unisys: visorbus: remove unused chipsetready information Chipsetready sysfs entry is not used by any guests or service partitions. remove unused g_chipset_msg_hdr our service partition remove unused chipsetready_store and driver attributes: chipsetready_store() visorchipset_guest_attrs visorchipset_guest_groupw remove unused chipsets_events: check_chipset_events() clear_chipset_events() visorchipset_holdchipsetready remove sysfs documentation dealing with chipsetready Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../Documentation/ABI/sysfs-platform-visorchipset | 14 ---- drivers/staging/unisys/visorbus/visorchipset.c | 89 +--------------------- 2 files changed, 1 insertion(+), 102 deletions(-) commit 39b92809830b1c0b4d00e934d39a5815c85fd956 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Mon Apr 18 23:22:02 2016 -0400 staging: unisys: include: Added kerneldoc comments to visor_device The visor_device struct is used between multiple drivers, so this adds kerneldoc comments to the fields. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 45 +++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 11 deletions(-) commit b9edaf7cebb4ab1e8bef797e89617fa5f113041a Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Mon Apr 18 23:22:01 2016 -0400 staging: unisys: include: Added kernel-doc for struct visor_driver This adds kerneldoc style comments to the visor_driver struct since it's shared between multiple modules. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 65 ++++++++++++++++--------------- 1 file changed, 34 insertions(+), 31 deletions(-) commit 6d24b4b10e8a5a299fe0c85060e41a367727efb3 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Mon Apr 18 23:22:00 2016 -0400 staging: unisys: include: remove unused fields from struct visor_driver The build_date and build_time fields are not used, and have been removed. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 2 -- 1 file changed, 2 deletions(-) commit 538b387234563e030cd9ad8983ad3de8eaf03e13 Author: David Binder <david.binder@unisys.com> Date: Wed Apr 13 16:08:41 2016 -0400 staging: unisys: Documentation: Remove proc-entries.txt Unisys drivers no longer utilize procfs. Therefore, the documentation for our procfs entries is no longer needed. Signed-off-by: David Binder <david.binder@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/unisys/Documentation/proc-entries.txt | 93 ---------------------- drivers/staging/unisys/MAINTAINERS | 1 - 2 files changed, 94 deletions(-) commit 38d56c2fad91a02d289df40b029300310fb6c75a Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Wed Apr 13 12:07:07 2016 -0400 staging: unisys: added display string size define Display string size that is guaranteed to be no longer the 99 characters. Don't use a magic number throughout the code, define it once and use it throughout. Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 6a957193ba83e5487705f63011307d202fff69f8 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Wed Apr 13 11:56:36 2016 -0400 staging: unisys: visornic: convert BUG_ON to dev_err() message The caller of visor_copy_fragsinfo_from_skb() is prepared to log a dev_err() message if it fails (by returning a negative value), so we now just fail in the one occasion where visor_copy_fragsinfo_from_skb() was doing a BUG_ON. There was also a problem before where visor_copy_fragsinfo_from_skb() was returning a negative to indicate error, yet it was declared to return an unsigned value! So obviously that needed correcting too. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visornic/visornic_main.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 853adce6fd9a3caec583e115cd9f5def6f67daf7 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Thu Apr 14 20:48:49 2016 +0530 staging: wilc1000: remove unused variables These variables were havnig the pointer returned by wiphy_priv() but they were never used. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 8 -------- 1 file changed, 8 deletions(-) commit 245b431b76ada80aa2a3ea36e46ab5a45b84e0ee Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Mon Apr 25 02:07:18 2016 +0300 Staging: wilc1000: Freed memory in case of error This patch frees memory allocated inside wilc_wlan_txq_add_cfg_pkt() in case wilc_wlan_txq_add_to_head() fails. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 8958f5811ca5f602cfb2987f7977744a458421af Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 19 09:35:31 2016 +0900 staging: wilc1000: rename result in handle_set_ip_address This patch renames result to ret that is used to get return value from wilc_send_config_pkt. Some handle_*() functions are used as result, others are used as ret. It will be changed as ret in all handle_*() functions to match variable name. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit cd7293ef3939d1220c280b9e11a520ce4ba57d56 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 19 09:35:30 2016 +0900 staging: wilc1000: change data type of result in handle_set_ip_address This patch changes data type of result variable from s32 to int. result is used to get return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fc6138b6cfc0319791ff860aecd06126b0c6e578 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 19 09:35:29 2016 +0900 staging: wilc1000: change handle_set_ip_address's return type to void When handle_set_ip_address is called in hostIFthread that is a kernel thread, it is not checked return type of this function. This patch changes return type to void and removes braces if statement due to have a single statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 14f3b086fc8225f60b0efaafec2a7bca443f8171 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:43 2016 +0900 staging: wilc1000: rename result in handle_set_operation_mode This patch renames result to ret that is used to get return value from wilc_send_config_pkt. Some handle_*() functions are used as result, others are used as ret. It will be changed as ret in all handle_*() functions to match variable name. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 197b053d9c83999d6b93b01bb355e3cac4474779 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:42 2016 +0900 staging: wilc1000: change data type of result in handle_set_operation_mode This patch changes data type of result variable from s32 to int. result is used to get return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b093d4fe608c5f7d795d0c516baff495f9651525 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:41 2016 +0900 staging: wilc1000: change handle_set_operation_mode's return type to void When handle_set_operation_mode is called in hostIFthread that is a kernel thread, it is not checked return type of this function. This patch changes return type to void and removes braces if statement due to have a single statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit fdcc285b77a115f7207321ce1cf749f0ea6c0b92 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:40 2016 +0900 staging: wilc1000: rename result in handle_set_wfi_drv_handler This patch renames result to ret that is used to get return value from wilc_send_config_pkt. Some handle_*() function are used as result, others are used as ret. It will be changed as ret in all handle_*() function to match variable name. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit d22002338f74bad5f86a206fadc1832543c59187 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:39 2016 +0900 staging: wilc1000: change data type of result in handle_set_wfi_drv_handler This patch changes data type of result variable from s32 to int. result is used to get return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 62a0d45af67896f2ca4a53a07fa89b7788db8a72 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:38 2016 +0900 staging: wilc1000: change handle_set_wfi_drv_handler's return type to void When handle_set_wfi_drv_handler is called in hostIFthread that is a kernel thread, it is not checked return type of this function. This patch changes return type to void and removes braces if statement due to have a single statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 12915c51e99249aa360e9006e591ebce676c23af Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Thu Apr 7 08:10:37 2016 +0900 staging: wilc1000: change return type of ret variable in handle_get_tx_pwr This patch changes return type of ret variable from s32 to int. ret has return value from wilc_send_config_pkt that has return type of int. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 31aab0e0abdde4680b88242e99beb1d0c7a173ed Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:32 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_add_beacon This patch removes unused hif_drv in wilc_add_beacon. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit d5dc9402894eefb54548ca532fe3cd358373dcbd Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:31 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_del_beacon This patch removes unused hif_drv in wilc_del_beacon. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 4965c4dcdd696d699be1460b1010d9be18979122 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:30 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_set_pmkid_info This patch removes unused hif_drv in wilc_set_pmkid_info. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 11d9e460ccb93742bfdc6ec2369a154eb2126e5a Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:29 2016 +0900 staging: wilc1000: remove unused hif_drv in host_int_get_assoc_res_info This patch removes unused hif_drv in host_int_get_assoc_res_info. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit a61c42319bc3be9451d7169d4c068bc9fac24942 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:28 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_set_mac_chnl_num This patch removes unused hif_drv in wilc_set_mac_chnl_num. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 1f4b12f08939d160cbb8d619a67b05ed96435f36 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:27 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_remain_on_channel This patch removes unused hif_drv in wilc_remain_on_channel. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit b0474e9eb9621bb1f9243fb0c9571dec150163a9 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:26 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_add_station This patch removes unused hif_drv in wilc_add_station. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit d5db44143584d665f7308bfb6182b50930afdd2c Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:25 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_del_station This patch removes unused hif_drv in wilc_del_station. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit d9a90eea69a0345427aace679b024f8022cc21c9 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:24 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_del_allstation This patch removes unused hif_drv in wilc_del_allstation. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit f2b01d04e8f807379666ca500232239d3e272332 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:23 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_edit_station This patch removes unused hif_drv in wilc_edit_station. There is no need to checku null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 3cf996d4280578a1c6fea17d26cb38d9966065cf Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:22 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_set_power_mgmt This patch removes unused hif_drv in wilc_set_power_mgmt. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 8bf4d84dca744853fa53b96b4b4b5fbfa73d0cc0 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:21 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_setup_multicast_filter This patch removes unused hif_drv in wilc_setup_multicast_filter. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit cc1aa4c8e92b95e61309f563bbd41336553eae7f Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:20 2016 +0900 staging: wilc1000: remove unused hif_drv in wilc_setup_ipaddress This patch removes unused hif_drv in wilc_setup_ipaddress. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 3de8fbac6a8ac40f373e9bdb6b7ce7528070079a Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Apr 5 15:38:19 2016 +0900 staging: wilc1000: remove unused hif_drv in host_int_get_ipaddress This patch removes unused hif_drv in host_int_get_ipaddress. There is no need to check null and print debug log. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 2f27ad12ab9aa9793824353443cc982da9502d65 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:50 2016 +0900 staging: wilc1000: rename pu8Buffer in handle_scan This patch renames pu8Buffer to buffer to avoid camelcase. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 87b16cbf17bdd5aefdfba14893311cd16f4f5689 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:49 2016 +0900 staging: wilc1000: rename u32WidsCount in handle_scan This patch renames u32WidsCount to index to avoid camelcase. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 58 +++++++++++++++---------------- 1 file changed, 29 insertions(+), 29 deletions(-) commit bbff83dbb717dca6248615d82cc00fb3466fb805 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:48 2016 +0900 staging: wilc1000: rename strWIDList in handle_scan This patch renames strWIDList to wid_list to avoid camelcase. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 48 +++++++++++++++---------------- 1 file changed, 24 insertions(+), 24 deletions(-) commit 34b107eded72b671457a561861c71a82bf12d1c0 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:47 2016 +0900 staging: wilc1000: rename pstrHostIFscanAttr in handle_scan This patch renames pstrHostIFscanAttr to scan_info to avoid camelcase. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 55 +++++++++++++++---------------- 1 file changed, 27 insertions(+), 28 deletions(-) commit ba7eac31a129de13a1d6a7fb45da4fe7c090ce7c Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:46 2016 +0900 staging: wilc1000: rename Handle_Scan This patch renames Handle_Scan to handle_scan to avoid camelcase. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 03f00ac788cfbedef98e03b2c7af59125e4d5f0d Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:45 2016 +0900 staging: wilc1000: remove block scope braces and fix indentation This patch removes unnecessary block scope braces and fix indentation of the codes. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 4aa3387bc2d56459fdb7da9e47f39d56b46db3a3 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:44 2016 +0900 staging: wilc1000: move Handle_ScanDone function declaration Handle_ScanDone function declaration is moved to front of host_interface.c file. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 960efe0f89f90c1742728aeaca2de1ca7e0ce42b Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Apr 4 20:04:43 2016 +0900 staging: wilc1000: rename goto label in handle_cfg_param This patch changes goto label from ERRORHANDLER to unlock. unlock is a more meaningful name than ERRORHANDLER. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 38 +++++++++++++++---------------- 1 file changed, 19 insertions(+), 19 deletions(-) commit b0f1836fadc89dd5629021cfc4ab72ef9f2bfcb3 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:19 2016 +0900 staging: wilc1000: adds a check routine when performed del_key() This patch is adds a check routine when performed del_key(). We was find this situation while test the 'rmmod sdio'. That is received inform a .del_key cmd from cfg80211. If is not exist wep keys, must be ignore a wilc_remove_wep_key() function. Thus, adds a check routine that key length of wep. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 8006109ba0f9b85407ce41c86e7a9a059d08b90c Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:18 2016 +0900 staging: wilc1000: adds a cfg80211_disconnected() function This patch is adds a cfg80211_disconnected() when connection is lost already. We was find this situation while test the 'rmmod sdio'. SDIO remove function are include both remove mac_close and unregister net_device. That is received one more a disconnect cmd from cfg80211. Driver was already performed disconnect. If wilc->close value was set to true, adds a call to cfg80211_disconnected(). Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 3f626cf4a8445015296bb2cc2c98aa9ed619d7cc Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:17 2016 +0900 staging: wilc1000: add set to null after release firmware This patch add set to null after release firmware. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit a2c28de5c09b29854abe5fd7448695d4da0bdb33 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:16 2016 +0900 staging: wilc1000: removes unnecessary test code This patch removes unnecessary test code that mac address hardcoding setting. This test code is support to old firmware. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 9 --------- 1 file changed, 9 deletions(-) commit 11a54b3f9932efb7d2c07350834bb37ea0ba7cf9 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:15 2016 +0900 staging: wilc1000: txq_thread_started: replaces a semaphore with a completion This patch replaces a semaphore(txq_thread_started) with a completion. Struct semaphore txq_thread_started is used to signal completion of txq thread. It is better to use completion than semaphore for this case. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 10 +++++----- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 3 +-- 2 files changed, 6 insertions(+), 7 deletions(-) commit 01c7cee913e431e88159c70dae330dd40aa72677 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:14 2016 +0900 staging: wilc1000: removes duplicate del_timer_sync This patch removes del_timer_sync(&periodic_rssi) which was already performed this action. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 1 - 1 file changed, 1 deletion(-) commit 27e1f1396465944d9f78ad4ee26e596c2e260092 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Apr 1 17:44:13 2016 +0900 staging: wilc1000: changes logic when happened mq_send fail This patch changes logic when happened mq_send fail. The check as a result value that mq_send fail. But, regardless of the result value then perform a semaphore up. That is an occur that semaphore locking. Add to 'else' routine and move to 'else' position a semaphore up. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 33 +++++++++++++++++-------------- 1 file changed, 18 insertions(+), 15 deletions(-) commit b89359bdf0f1e95a4c5f92300594ba9dde323fc4 Merge: d3a8f67 0449eef Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 29 14:57:51 2016 +1000 Merge branch 'for-next' of http://git.agner.ch/git/linux-drm-fsl-dcu into drm-next This adds very rudimentary TCON (timing controller for raw LCD displays) support to enable the bypass mode in order to use the DCU controller on Freescale/NXP Vybrid SoC's. Additionally the register clock and pixel clock has been separated, but are currently still enabled and disabled pairwise. Other than that, fixes and cleanups accross the driver. * 'for-next' of http://git.agner.ch/git/linux-drm-fsl-dcu: drm/fsl-dcu: increment version and date drm/fsl-dcu: implement lastclose callback drm/fsl-dcu: disable output polling on driver unload drm/fsl-dcu: deallocate fbdev CMA on unload drm/fsl-dcu: use variable name dev for struct drm_device drm/fsl-dcu: handle missing panel gracefully drm/fsl-dcu: detach panel on destroy drm/layerscape: reduce excessive stack usage drm/fsl-dcu: add TCON driver drm/fsl-dcu: use common clock framework for pixel clock divider drm/fsl-dcu: add extra clock for pixel clock drm/fsl-dcu: disable clock on initialization failure and remove commit ae33a836df17456aa80eff664a070592e2482ea2 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Thu Apr 28 12:07:38 2016 -0400 staging: lustre: llite: quiet overly verbose info message The client doesn't need to print a message for every client mount that the layout lock feature is enabled. This can be found at runtime via the "import" proc file. I also noticed that deleting OST objects logs into the debug log with D_HA status, which is enabled by default. Move this over to D_INODE so it doesn't fill the OST debug logs. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1095 Reviewed-on: http://review.whamcloud.com/7918 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Emoly Liu <emoly.liu@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_lib.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 69daf080b7fea2bc6780238ad55983934e43c441 Author: Emoly Liu <emoly.liu@intel.com> Date: Thu Apr 28 12:07:37 2016 -0400 staging: lustre: debugfs: improve osc/mdc "imports" connect data Improve /sys/debug/fs/lustre/{osc,mdc}/*/import files to print the struct obd_connect_data data fields as "connect_data:" in addition to the "connect_flags:" field. Signed-off-by: Emoly Liu <emoly.liu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3386 Reviewed-on: http://review.whamcloud.com/6588 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/obdclass/lprocfs_status.c | 63 +++++++++++++++++++--- 1 file changed, 57 insertions(+), 6 deletions(-) commit 882b0a1359cbfec69185facdff613322358ba470 Author: Emoly Liu <emoly.liu@intel.com> Date: Thu Apr 28 12:07:36 2016 -0400 staging: lustre: obd: add case LCFG_PARAM to osd_process_config Some proc parameters were moved from ofd to osd module and only their symlinks were kept in ofd for interoperability/compatibility. To process this kind of config params passed by ofd, this patch is to do the following fixes: - since these parameters are not included by the static lprocfs var list, a pre-check is added for them to avoid "unknown param" error message confuses the uses. If they are matched in this check, they will be passed to the osd directly. - improve the error messages in class_process_proc_param() and class_process_proc_seq_param() a little. Signed-off-by: Emoly Liu <emoly.liu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4221 Reviewed-on: http://review.whamcloud.com/8238 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_param.h | 1 + drivers/staging/lustre/lustre/obdclass/obd_config.c | 20 +++++++++++--------- 2 files changed, 12 insertions(+), 9 deletions(-) commit 6f6c8e7c754a0e17be680f80dfceafe02f0e8932 Author: Sebastien Buisson <sbuisson@ddn.com> Date: Thu Apr 28 12:07:35 2016 -0400 staging: lustre: ldlm: dont always check max_pages_per_rpc alignement If connection is not established yet, cli->cl_chunkbits is uninitilized so we cannot use it to check max_pages_per_rpc alignment. Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4379 Reviewed-on: http://review.whamcloud.com/8558 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Emoly Liu <emoly.liu@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 6 ++++++ 1 file changed, 6 insertions(+) commit b78c2b9b3e4af47ca96cd848f21b989ee0e86ea5 Author: wang di <di.wang@intel.com> Date: Thu Apr 28 12:07:34 2016 -0400 staging: lustre: fld: add local fldb to each target Add local FLDB to each MDT, so OSD/OUT can check whether FID is remote by looking up local FLDB, i.e. no need send RPC to MDT0. This is just the client part of the work. Signed-off-by: wang di <di.wang@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4076 Reviewed-on: http://review.whamcloud.com/7884 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/fid/fid_request.c | 5 +- drivers/staging/lustre/lustre/fld/fld_internal.h | 9 +-- drivers/staging/lustre/lustre/fld/fld_request.c | 79 +++++++++++++++------- .../lustre/lustre/include/lustre/lustre_idl.h | 19 +++++- .../lustre/lustre/include/lustre_req_layout.h | 1 + .../staging/lustre/lustre/include/obd_support.h | 1 + drivers/staging/lustre/lustre/ptlrpc/layout.c | 15 ++++ .../staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c | 1 + drivers/staging/lustre/lustre/ptlrpc/wiretest.c | 4 +- 9 files changed, 95 insertions(+), 39 deletions(-) commit 8bd3efb755baabd1d7e78f1ed2eab1317959c022 Author: Alexander Boyko <alexander_boyko@xyratex.com> Date: Thu Apr 28 12:07:33 2016 -0400 staging: lustre: brw: added OBDO short io flag To prevent collisions with any future flags needed in features written against this branch. Signed-off-by: Alexander Boyko <alexander_boyko@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1757 Xyratex-bug-id: MRP-1460 Reviewed-on: http://review.whamcloud.com/8182 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Vitaly Fertman <vitaly_fertman@xyratex.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre/lustre_idl.h | 1 + 1 file changed, 1 insertion(+) commit b201c2476503f52d549b35f5557d67702a26c29c Author: John L. Hammond <john.hammond@intel.com> Date: Thu Apr 28 12:07:32 2016 -0400 staging: lustre: echo: remove echo_env_info() regions from echo_client.c This function declartion is not needed so remove it. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-on: http://review.whamcloud.com/5580 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdecho/echo_client.c | 2 -- 1 file changed, 2 deletions(-) commit 83e8d02ce7a72bd2710b94edc005474066588d2a Author: Oleg Drokin <green@linuxhacker.ru> Date: Thu Apr 28 12:07:31 2016 -0400 staging: lustre: debug: initialize debug_msg_data if needed initialize the libcfs_debug_msg_data only if needed Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1408 Reviewed-on: http://review.whamcloud.com/8338 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 6 ++---- drivers/staging/lustre/lustre/include/lu_object.h | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) commit 1b3f4f90c4fe0205e10d0d703ee599f726cd96b6 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Wed Apr 27 21:37:21 2016 -0400 staging: lustre: llite: fixup return value ll_direct_IO_26 Return the correct values from ll_direct_IO_26. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4069 Reviewed-on: http://review.whamcloud.com/8080 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-Off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/rw26.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 70187506215e40d16a89c9f91f4d36f0f487b3e8 Author: Mikhail Pershin <mike.pershin@intel.com> Date: Wed Apr 27 21:37:20 2016 -0400 staging: lustre: ptlrpc: initialize request session early Initialize request session early to make it available in high-priority handlers Signed-off-by: Mikhail Pershin <mike.pershin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3467 Reviewed-on: http://review.whamcloud.com/7350 Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ptlrpc/service.c | 53 +++++++++++++++----------- 1 file changed, 31 insertions(+), 22 deletions(-) commit 8fb2990eb7e57a886791af6d99720ca38f535496 Author: Lai Siyao <lai.siyao@intel.com> Date: Wed Apr 27 21:37:19 2016 -0400 staging: lustre: llog: we don't need vfsmount The patch for LU-3286 removed vfsmount instances used on the server side. Since this is server side only we can remove it from the upstream client. Signed-off-by: Lai Siyao <lai.siyao@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3286 Reviewed-on: http://review.whamcloud.com/8286 Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Mike Pershin <mike.pershin@intel.com> Reviewed-by: Jian Yu <jian.yu@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_disk.h | 2 -- 1 file changed, 2 deletions(-) commit fe956e728ade07f10a8a6594b787cab087a00be6 Author: Swapnil Pimpale <spimpale@ddn.com> Date: Wed Apr 27 21:37:18 2016 -0400 staging: lustre: llite: check ret of ll_prep_md_op_data in ll_dir_filler ll_dir_filler() now checks the returned pointer from ll_prep_md_op_data() using IS_ERR() Signed-off-by: Swapnil Pimpale <spimpale@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4082 Reviewed-on: http://review.whamcloud.com/8073 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 5787be94725c2229ca9188ce189f872c01c9841f Author: Andreas Dilger <andreas.dilger@intel.com> Date: Wed Apr 27 21:37:17 2016 -0400 staging: lustre: llite: debugging for ll_file_open LASSERT Add debugging for LASSERTF(it_disposition(it, DISP_ENQ_OPEN_REF) in ll_file_open(), since this is a rarely hit failure under racer, and it would be useful to get more information if this is hit again. Print the full intent disposition, as well as the status, in case Oleg's earlier comment about bailing out on any error is actually the case here. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1993 Reviewed-on: http://review.whamcloud.com/6250 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 9ebd48965864093b2616cab2df2ea9a73f3aab53 Author: Andriy Skulysh <Andriy_Skulysh@xyratex.com> Date: Wed Apr 27 21:37:16 2016 -0400 staging: lustre: libcfs: Fix NUMA emulated mode Kernel commit c1c3443c9c5e9be92641029ed229a41563e44506 assigns all allowed cpus to emulated node. End cpt initialization loop when all CPUs are assigned. Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3992 Reviewed-on: http://review.whamcloud.com/7724 Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-cpu.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 98f2ec61203ff300465d9e44c5657ebf9c870ef6 Author: Lai Siyao <lai.siyao@intel.com> Date: Wed Apr 27 21:37:15 2016 -0400 staging: lustre: fid: add a connect flag for open by FID Add OBD_CONNECT_OPEN_BY_FID for open by FID, if MDS supports this, for open by FID, it won't retry with name if object with the FID doesn't exist; while if client supports this, client won't pack name in open request if FID is known. Signed-off-by: Lai Siyao <lai.siyao@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3544 Reviewed-on: http://review.whamcloud.com/8093 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre/lustre_idl.h | 3 +++ drivers/staging/lustre/lustre/ptlrpc/wiretest.c | 2 ++ 2 files changed, 5 insertions(+) commit d8555069e259a7fd8096527cab5b9e3dbf185225 Author: Swapnil Pimpale <spimpale@ddn.com> Date: Wed Apr 27 21:37:14 2016 -0400 staging: lustre: obd: cleanup client import if client_obd_setup fails client_obd_setup() allocates an obd_import which should be cleaned up if there is any failure afterwards in callers of client_obd_setup(). This patch fixes the bug in osc_setup(), mgc_setup(), mdc_setup() and lwp_setup(). The fix is to call obd_cleanup_client_import() before calling client_obd_cleanup() in case of an error. Signed-off-by: Swapnil Pimpale <spimpale@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3810 Reviewed-on: http://review.whamcloud.com/7561 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 1 + 1 file changed, 1 insertion(+) commit 6956583961fbd837b381d64e48e67c64b147989a Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Wed Apr 27 21:37:13 2016 -0400 staging: lustre: ldlm: check all errors during ldlm_debugfs_setup() Fix ignoring errors from ldebugfs_add_vars() function. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3885 Reviewed-on: http://review.whamcloud.com/8115 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 45fe5b139c46deb2bdd2752b7a42ce93fd56efc0 Author: Mikhail Pershin <mike.pershin@intel.com> Date: Wed Apr 27 21:37:12 2016 -0400 staging: lustre: ptlrpc: use unified handler for OST requests Switch OST/OFD request processing to the unified request handle. Signed-off-by: Mikhail Pershin <mike.pershin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3467 Reviewed-on: http://review.whamcloud.com/7130 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lustre/include/lustre_req_layout.h | 2 +- drivers/staging/lustre/lustre/include/obd_support.h | 1 + drivers/staging/lustre/lustre/ptlrpc/layout.c | 16 +++++++++++----- 3 files changed, 13 insertions(+), 6 deletions(-) commit c4ab96e7ca43461dc535b0d22fd578e2c0a16aab Author: Amir Shehata <amir.shehata@intel.com> Date: Wed Apr 27 21:37:11 2016 -0400 staging: lustre: obd: add newline for dumped config record The function class_config_parse_rec() parses the llog record and places it into a buffer to be returned. That buffer needs to end with a newline which is currently missing. Signed-off-by: Amir Shehata <amir.shehata@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2149 Reviewed-on: http://review.whamcloud.com/4254 Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/obd_config.c | 1 + 1 file changed, 1 insertion(+) commit b828b9cac7479b2fd38a6c47143abf281e487e7d Author: Amir Shehata <amir.shehata@intel.com> Date: Wed Apr 27 21:37:10 2016 -0400 staging: lustre: obd: remove newline from LCONSOLE string Remove the newline from the LCONSOLE debug macro in the function class_config_dump_handler(). Signed-off-by: Amir Shehata <amir.shehata@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2149 Reviewed-on: http://review.whamcloud.com/4254 Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/obd_config.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d3a8f6784a9cb47c344073624491e571ff1616ec Merge: 152ef5f bf1139d Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 29 14:52:41 2016 +1000 Merge tag 'sun4i-drm-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into drm-next Allwinner DRM driver for 4.7 This pull request introduces the sun4i driver, meant to be used on the older Allwinner SoCs (A10, A13, A20, A23, A31 and A33). It currently supports only the A13, which has one of the simplest video pipeline. Support for other video components and SoCs will be added eventually. It supports only a RGB or composite output. It doesn't do HDMI, VGA, LVDS or power management yet, but that will come in time as well. * tag 'sun4i-drm-for-4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: MAINTAINERS: Add a maintainer for the Allwinner DRM driver drm: sun4i: tv: Add NTSC output standard drm: sun4i: tv: Add PAL output standard drm: sun4i: Add composite output drm: sun4i: Add RGB output drm: Add Allwinner A10 Display Engine support drm: sun4i: Add DT bindings documentation drm: fb: Add seq_file definition commit 35e458160d17a1382a476e3366b117d10ef1a59b Author: Andreas Dilger <andreas.dilger@intel.com> Date: Wed Apr 27 18:21:07 2016 -0400 staging: lustre: ptlrpc: quiet warning for 2.1/2.5 connections The Lustre 2.5.4 client will print a warning about connections with 2.1.3 servers, yet they are still supposed to be interoperable. Increase the window of warning to be up to Lustre 2.5.50, since we do not intend to allow interoperability between 2.1 and 2.6 systems. This was from the time when major releases like Lustre 1.4 and 1.8 were many years apart would have no chance for interoperation. Only print this message once per client, to avoid flooding the console for connections to many servers or frequent network reconnections. Server versions should all be nearly the same in any case. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2528 Reviewed-on: http://review.whamcloud.com/7916 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Jian Yu <jian.yu@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ptlrpc/import.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit ad479287b4e637ac098e5ebd5dabfa2826e27d4c Author: Prakash Surya <surya1@llnl.gov> Date: Wed Apr 27 18:21:06 2016 -0400 staging: lustre: osc: Use SOFT_SYNC to urge server commit This change adds a BRW page flag, OBD_BRW_SOFT_SYNC. This flag is intended to urge a server to commit a client's unstable pages to stable storage. A client will add this flag to any BRW requests while it is in a state where it has "many" unstable pages pinned in its cache. The server, upon receiving a page with this flag set, *should* begin an async commit. The idea being that, with the proactive async commit, the client's pinned unstable pages will transition into a stable state faster than they would have otherwise. Although, the server side portion of this agreement is still unimplemented, so the OBD_BRW_SOFT_SYNC flag will currently fall on deaf ears. Signed-off-by: Prakash Surya <surya1@llnl.gov> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2139 Reviewed-on: http://review.whamcloud.com/4375 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/include/lustre/lustre_idl.h | 5 ++++ drivers/staging/lustre/lustre/osc/osc_cache.c | 3 +++ drivers/staging/lustre/lustre/osc/osc_internal.h | 1 + drivers/staging/lustre/lustre/osc/osc_page.c | 29 ++++++++++++++++++++++ drivers/staging/lustre/lustre/osc/osc_request.c | 3 ++- drivers/staging/lustre/lustre/ptlrpc/wiretest.c | 6 +++++ 6 files changed, 46 insertions(+), 1 deletion(-) commit dece0b95dd358de8f5e36c605f079ce8e1aab23d Author: Prakash Surya <surya1@llnl.gov> Date: Wed Apr 27 18:21:05 2016 -0400 staging: lustre: osc: Track number of "unstable" pages per osc This change adds simple accounting hooks for "unstable" pages on a per OSC basis. Now, in addition to the per filesystem tracking, each OSC will maintain a running total of its unstable pages. These counters are exported through the proc interface, and can be read using the lctl command. For example: # Read number of unstable pages contained by each OSC lctl get_param osc.*.unstable_stats The motivation for this change is in anticipation of implementing a "soft sync" functionality, urging servers to commit these unstable pages to stable storage. The per OSC accounting allows a client to limit the soft sync request to only the OSCs which have outstanding unstable pages. Signed-off-by: Prakash Surya <surya1@llnl.gov> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2139 Reviewed-on: http://review.whamcloud.com/4374 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/obd.h | 1 + drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 1 + drivers/staging/lustre/lustre/osc/lproc_osc.c | 18 ++++++++++++++++++ drivers/staging/lustre/lustre/osc/osc_cache.c | 6 ++++++ 4 files changed, 26 insertions(+) commit ac5b14810952b659438c015478348c93eda91c25 Author: Prakash Surya <surya1@llnl.gov> Date: Wed Apr 27 18:21:04 2016 -0400 staging: lustre: osc: Track and limit "unstable" pages This change adds a global counter to track the number of "unstable" pages held by a given client, along with per file system counters. An "unstable" page is defined as a page which has been sent to the server as part of a bulk request, but is uncommitted to stable storage. In addition to simply tracking the unstable pages, they now also count towards the maximum number of "pinned" pages on the system at any given time. Thus, a client will now be bound on the number of dirty and unstable pages it can pin in memory. Previously only dirty pages were accounted for in this limit. In addition to tracking the number of unstable pages in Lustre, the NR_UNSTABLE_NFS memory zone is also incremented and decremented for easy monitoring using the "NFS_Unstable:" field in /proc/meminfo. This field is also used internally by the kernel to limit the total amount of unstable pages on the system. The motivation for this change is twofold. First, the client must not allow itself to disconnect from an OST while still holding unstable pages. Otherwise, these unstable pages can get lost due to an OST failure, and replay is not possible due to the disconnect via unmount. Secondly, the client needs a mechanism to prevent it from allocating too much of its available RAM to unreclaimable pages pinned by the ptlrpc layer. If this case occurs, out of memory events can trigger as a side effect, which we need to avoid. The current number of unstable pages accounted for on a per file system granularity is exported by the unstable_stats proc file, contained under each file system's llite namespace. An example of retrieving this information is below: $ lctl get_param llite.*.unstable_stats Signed-off-by: Prakash Surya <surya1@llnl.gov> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2139 Reviewed-on: http://review.whamcloud.com/6284 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 10 +++ drivers/staging/lustre/lustre/include/lustre_net.h | 4 +- drivers/staging/lustre/lustre/include/obd.h | 2 +- .../staging/lustre/lustre/include/obd_support.h | 1 + .../staging/lustre/lustre/llite/llite_internal.h | 6 ++ drivers/staging/lustre/lustre/llite/llite_lib.c | 20 ++++- drivers/staging/lustre/lustre/llite/lproc_llite.c | 18 ++++ drivers/staging/lustre/lustre/obdclass/class_obd.c | 2 + drivers/staging/lustre/lustre/osc/osc_cache.c | 99 ++++++++++++++++++++-- drivers/staging/lustre/lustre/osc/osc_internal.h | 3 + drivers/staging/lustre/lustre/osc/osc_request.c | 28 +++++- 11 files changed, 182 insertions(+), 11 deletions(-) commit 7bbe9f838e17a1abcfc74c874739e2b0418899b0 Author: Sebastien Buisson <sbuisson@ddn.com> Date: Wed Apr 27 18:21:03 2016 -0400 staging: lustre: mgc: fix 'error handling' issues Fix 'error handling' issues found by Coverity version 6.6.1: Unchecked return value (CHECKED_RETURN) Calling function without checking return value. Argument cannot be negative (NEGATIVE_RETURNS) Negative value used as argument to a function expecting a positive value. Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4055 Reviewed-on: http://review.whamcloud.com/7842 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: James Nunez <james.a.nunez@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/mgc/mgc_request.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 72a50e4f303f051761612436e7ad75562abe0113 Author: Niu Yawei <yawei.niu@intel.com> Date: Wed Apr 27 18:21:02 2016 -0400 staging: lustre: clio: add debug message in osc_completion() Replace LASSERT with LASSERTF in osc_completion, thus we can get more info when the LASSERT is triggered. Signed-off-by: Niu Yawei <yawei.niu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3843 Reviewed-on: http://review.whamcloud.com/7494 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/osc/osc_cache.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 97a075cddb81894dd3788e8901b40c5bedcc6871 Author: James Nunez <james.a.nunez@intel.com> Date: Wed Apr 27 18:21:01 2016 -0400 staging: lustre: llite: Replace printing of i_ino with ll_inode2fid() The printing of i_ino/i_generation in llite messages is not nearly so useful as printing the full inode FID, since i_ino is a "compressed" version of the FID and there may be duplicate values for i_ino in some cases (especially if running on a 32-bit client). All instances of printing i_ino/i_generation are replaced with the FID using ll_inode2fid(). All instances, except for one, of printing just i_ino was replaced by printing the FID. In all CERROR lines touched by the i_ino replacements, the device name or fsname was added at the beginning of the message if it did not already exist. Signed-off-by: James Nunez <james.a.nunez@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3491 Reviewed-on: http://review.whamcloud.com/6848 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dcache.c | 8 +-- drivers/staging/lustre/lustre/llite/dir.c | 23 ++++--- drivers/staging/lustre/lustre/llite/file.c | 70 ++++++++++---------- drivers/staging/lustre/lustre/llite/llite_close.c | 40 ++++++------ .../staging/lustre/lustre/llite/llite_internal.h | 10 ++- drivers/staging/lustre/lustre/llite/llite_lib.c | 40 ++++++------ drivers/staging/lustre/lustre/llite/llite_mmap.c | 6 +- drivers/staging/lustre/lustre/llite/llite_nfs.c | 14 ++-- drivers/staging/lustre/lustre/llite/namei.c | 76 ++++++++++------------ drivers/staging/lustre/lustre/llite/rw26.c | 5 +- drivers/staging/lustre/lustre/llite/statahead.c | 17 +++-- drivers/staging/lustre/lustre/llite/symlink.c | 10 ++- drivers/staging/lustre/lustre/llite/vvp_dev.c | 5 +- drivers/staging/lustre/lustre/llite/xattr.c | 20 +++--- 14 files changed, 174 insertions(+), 170 deletions(-) commit b97fa87f8003fc9b577026b07e465f48939922f8 Author: Bruce Korb <bruce.korb@gmail.com> Date: Wed Apr 27 18:21:00 2016 -0400 staging: lustre: ldlm: update comments about ldlm l_flags Add and update documentation about some of the ldlm l_flags. Signed-off-by: Bruce Korb <bruce.korb@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2906 Reviewed-by: Keith Mannthey <Keith.Mannthey@intel.com> Reviewed-on: http://review.whamcloud.com/7963 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_dlm_flags.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit efceaf7cdb6007bbac9e9d6466e36dcf9ccc62d7 Author: Bruce Korb <bruce.korb@gmail.com> Date: Wed Apr 27 18:20:59 2016 -0400 staging: lustre: ldlm: remove code wireshark handling Wireshark output moved to userland file "lustre_dlm_flags_wshark.c" and only bits that can actually appear "on the wire" are emitted. The user land "packet-lustre.c" code that references these bits now gets emitted into that file. e.g. the "local_only" bit is never put on the wire, so references to it in wireshark are gone. Signed-off-by: Bruce Korb <bruce.korb@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2906 Reviewed-by: Keith Mannthey <Keith.Mannthey@intel.com> Reviewed-on: http://review.whamcloud.com/7963 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/include/lustre_dlm_flags.h | 87 +--------------------- 1 file changed, 1 insertion(+), 86 deletions(-) commit d76964056ad518982891e1c0ebfbb0b114a7b63a Author: Bruce Korb <bruce.korb@gmail.com> Date: Wed Apr 27 18:20:58 2016 -0400 staging: lustre: ldlm: clean up l_flags Remove the now obsolete LDLM_AST_FLAGS and LDLM_INHERIT_FLAGS defines. Remove the obsolete LDLM_FL_HIDE_LOCK_MASK define. Rename "local_only" mask to "off_wire" since it is confusingly similar to a flag that (I think) means, "do not copy this lock over the wire." Signed-off-by: Bruce Korb <bruce.korb@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2906 Reviewed-by: Keith Mannthey <Keith.Mannthey@intel.com> Reviewed-on: http://review.whamcloud.com/7963 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_dlm_flags.h | 16 ++-------------- drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c | 2 +- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 2 +- 3 files changed, 4 insertions(+), 16 deletions(-) commit 5a9a80baa78e730a27ea68e9ac8adbd86a23ec22 Author: Bruce Korb <bruce.korb@gmail.com> Date: Wed Apr 27 18:20:57 2016 -0400 staging: lustre: ldlm: use accessor macros for l_flags Convert most of the ldlm lock's l_flags references from direct bit twiddling to using bit specific macros. A few multi-bit operations are left as an exercise for the reader. The changes are mostly in ldlm, but also in llite, osc and quota. Also add a multi-bit (mask) test. Signed-off-by: Bruce Korb <bruce.korb@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2906 Reviewed-by: Keith Mannthey <Keith.Mannthey@intel.com> Reviewed-on: http://review.whamcloud.com/7963 Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/include/lustre_dlm_flags.h | 3 + drivers/staging/lustre/lustre/ldlm/l_lock.c | 4 +- drivers/staging/lustre/lustre/ldlm/ldlm_extent.c | 4 +- drivers/staging/lustre/lustre/ldlm/ldlm_flock.c | 11 ++- drivers/staging/lustre/lustre/ldlm/ldlm_internal.h | 7 +- drivers/staging/lustre/lustre/ldlm/ldlm_lock.c | 95 +++++++++++----------- drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c | 26 +++--- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 32 ++++---- drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 12 +-- drivers/staging/lustre/lustre/llite/dcache.c | 7 +- drivers/staging/lustre/lustre/llite/file.c | 6 +- drivers/staging/lustre/lustre/llite/namei.c | 2 +- drivers/staging/lustre/lustre/osc/osc_lock.c | 2 +- 13 files changed, 102 insertions(+), 109 deletions(-) commit 0fdd2b8d7cec9fc4e4b6d0e7db2de98148ca37ba Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Wed Apr 27 18:20:56 2016 -0400 staging: lustre: lmv: kernel crash due to misconfigured MDT There are few places with access to lmv->tgts[] without check for NULL. Usually it may happens when MDT configured starting from index 1 instead of 0. For example: mkfs.lustre --reformat --mgs --mdt --index=1 /dev/sdd1 Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4098 Reviewed-on: http://review.whamcloud.com/7941 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lmv/lmv_obd.c | 151 +++++++++++++++++----------- 1 file changed, 93 insertions(+), 58 deletions(-) commit 7f937beb0ad24bd3e14dd943c04130a60ffcd0b9 Author: Wang Di <di.wang@intel.com> Date: Wed Apr 27 18:20:55 2016 -0400 staging: lustre: obdclass: add LCT_SERVER_SESSION for server session Add LCT_SERVER_SESSION for server session, and separate the server session flag from LCT_SESSION, so to avoid allocating session info for client stack for each server request, if client and server are on the same node. Signed-off-by: Wang Di <di.wang@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3806 Reviewed-on: http://review.whamcloud.com/7412 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Mike Pershin <mike.pershin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lu_object.h | 4 ++++ drivers/staging/lustre/lustre/include/obd_class.h | 2 +- drivers/staging/lustre/lustre/ptlrpc/service.c | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) commit ac7af34e6776c09fda26bc224c53a3870cd6af89 Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Wed Apr 27 18:20:54 2016 -0400 staging: lustre: llite: NFS reexport issue Suppress erroneous/confusing messages when NFS is out of sync and requests old data. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4050 Reviewed-on: http://review.whamcloud.com/7850 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Bob Glossman <bob.glossman@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_nfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c3558553597fb946e9192e13ca23b352f90133ae Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Apr 27 18:20:53 2016 -0400 staging: lustre: llite: reset writeback index in ll_writepages Otherwise after one round the writeback index will become beyond the file size and ->writepages() turns into an empty operation. Also, a safety guard is added to limit the wait time for grant to 10 minutes(take recovery into consideration) at maximum in the osc_enter_cache() function. Otherwise, EDQUOT will be returned to the applications to start sync write. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3416 Reviewed-on: http://review.whamcloud.com/6554 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Niu Yawei <yawei.niu@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/rw.c | 5 +++-- drivers/staging/lustre/lustre/osc/osc_cache.c | 32 ++++++++++++++++++--------- 2 files changed, 25 insertions(+), 12 deletions(-) commit 5be605ac9af979265d7b64c160ad9928088a78be Author: Alexandre Belloni <alexandre.belloni@free-electrons.com> Date: Tue Apr 12 14:51:40 2016 +0200 tty/serial: atmel: fix hardware handshake selection Commit 1cf6e8fc8341 ("tty/serial: at91: fix RTS line management when hardware handshake is enabled") actually allowed to enable hardware handshaking. Before, the CRTSCTS flags was silently ignored. As the DMA controller can't drive RTS (as explain in the commit message). Ensure that hardware flow control stays disabled when DMA is used and FIFOs are not available. Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Fixes: 1cf6e8fc8341 ("tty/serial: at91: fix RTS line management when hardware handshake is enabled") Cc: stable <stable@vger.kernel.org> # v4.0+ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/atmel_serial.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit d175feca89a1c162f60f4e3560ca7bc9437c65eb Author: Jiri Slaby <jslaby@suse.cz> Date: Tue Mar 22 18:09:51 2016 +0100 TTY: n_gsm, fix false positive WARN_ON Dmitry reported, that the current cleanup code in n_gsm can trigger a warning: WARNING: CPU: 2 PID: 24238 at drivers/tty/n_gsm.c:2048 gsm_cleanup_mux+0x166/0x6b0() ... Call Trace: ... [<ffffffff81247ab9>] warn_slowpath_null+0x29/0x30 kernel/panic.c:490 [<ffffffff828d0456>] gsm_cleanup_mux+0x166/0x6b0 drivers/tty/n_gsm.c:2048 [<ffffffff828d4d87>] gsmld_open+0x5b7/0x7a0 drivers/tty/n_gsm.c:2386 [<ffffffff828b9078>] tty_ldisc_open.isra.2+0x78/0xd0 drivers/tty/tty_ldisc.c:447 [<ffffffff828b973a>] tty_set_ldisc+0x1ca/0xa70 drivers/tty/tty_ldisc.c:567 [< inline >] tiocsetd drivers/tty/tty_io.c:2650 [<ffffffff828a14ea>] tty_ioctl+0xb2a/0x2140 drivers/tty/tty_io.c:2883 ... But this is a legal path when open fails to find a space in the gsm_mux array and tries to clean up. So make it a standard test instead of a warning. Reported-by: "Dmitry Vyukov" <dvyukov@google.com> Cc: Alan Cox <alan@linux.intel.com> Link: http://lkml.kernel.org/r/CACT4Y+bHQbAB68VFi7Romcs-Z9ZW3kQRvcq+BvHH1oa5NcAdLA@mail.gmail.com Fixes: 5a640967 ("tty/n_gsm.c: fix a memory leak in gsmld_open()") Cc: stable <stable@vger.kernel.org> Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/n_gsm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6f210c18c1c0f016772c8cd51ae12a02bfb9e7ef Author: David Müller <d.mueller@elsoft.ch> Date: Wed Apr 27 11:58:32 2016 +0200 serial: 8250_pci: fix divide error bug if baud rate is 0 Since commit 21947ba654a6 ("serial: 8250_pci: replace switch-case by formula"), the 8250 driver crashes in the byt_set_termios() function with a divide error. This is caused by the fact that a baud rate of 0 (B0) is not handled properly. Fix it by falling back to B9600 in this case. Signed-off-by: David Müller <d.mueller@elsoft.ch> Fixes: 21947ba654a6 ("serial: 8250_pci: replace switch-case by formula") Cc: stable@vger.kernel.org Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/tty/serial/8250/8250_pci.c | 3 +++ 1 file changed, 3 insertions(+) commit 30ec5fd464d51876247302da276db082e5675c35 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Apr 28 18:35:23 2016 -0700 nfit: fix format interface code byte order per ACPI6.1 ACPI6.1 clarifies that DCR fields are stored as an array of bytes, update the format interface code constants to match. Reviewed-by: Toshi Kani <toshi.kani@hpe.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 31eca76ba2fc988bf88f16fcf763a0ec4068cd30 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Apr 28 16:23:43 2016 -0700 nfit, libnvdimm: limited/whitelisted dimm command marshaling mechanism There are currently 4 known similar but incompatible definitions of the command sets that can be sent to an NVDIMM through ACPI. It is also clear that future platform generations (ACPI or not) will continue to revise and extend the DIMM command set as new devices and use cases arrive. It is obviously untenable to continue to proliferate divergence of these command definitions, and to that end a standardization process has begun to provide for a unified specification. However, that leaves a problem about what to do with this first generation where vendors are already shipping divergence. The Linux kernel can support these initial diverged platforms without giving platform-firmware free reign to continue to diverge and compound kernel maintenance overhead. The kernel implementation can encourage standardization in two ways: 1/ Require that any function code that userspace wants to send be explicitly white-listed in the implementation. For ACPI this means function codes marked as supported by acpi_check_dsm() may only be invoked if they appear in the white-list. A function must be publicly documented before it is added to the white-list. 2/ The above restrictions can be trivially bypassed by using the "vendor-specific" payload command. However, since vendor-specific commands are by definition not publicly documented and have the potential to corrupt the kernel's view of the dimm state, we provide a toggle to disable vendor-specific operations. Enabling undefined behavior is a policy decision that can be made by the platform owner and encourages firmware implementations to choose public over private command implementations. Based on an initial patch from Jerry Hoemann Cc: Jerry Hoemann <jerry.hoemann@hpe.com> Cc: Christoph Hellwig <hch@infradead.org> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 101 ++++++++++++++++++++++++++++++++++++++------- drivers/acpi/nfit.h | 14 ++++++- drivers/nvdimm/bus.c | 39 +++++++++++++++++ include/uapi/linux/ndctl.h | 42 +++++++++++++++++++ 4 files changed, 179 insertions(+), 17 deletions(-) commit e3654eca70d63704c94a60a2aafc0b3c7b46a00b Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Apr 28 16:17:07 2016 -0700 nfit, libnvdimm: clarify "commands" vs "_DSMs" Clarify the distinction between "commands", the ioctls userspace calls to request the kernel take some action on a given dimm device, and "_DSMs", the actual function numbers used in the firmware interface to the DIMM. _DSMs are ACPI specific whereas commands are Linux kernel generic. This is in preparation for breaking the 1:1 implicit relationship between the kernel ioctl number space and the firmware specific function numbers. Cc: Jerry Hoemann <jerry.hoemann@hpe.com> Cc: Christoph Hellwig <hch@infradead.org> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 21 +++++++++++++-------- drivers/acpi/nfit.h | 4 ++-- drivers/nvdimm/bus.c | 8 ++++---- drivers/nvdimm/core.c | 2 +- drivers/nvdimm/dimm_devs.c | 18 ++++++++++++------ drivers/nvdimm/nd-core.h | 2 +- include/linux/libnvdimm.h | 5 +++-- tools/testing/nvdimm/test/nfit.c | 27 ++++++++++++++------------- 8 files changed, 50 insertions(+), 37 deletions(-) commit 40abf9be8f52d440e442206182916e3dcc68f722 Author: Jerry Hoemann <jerry.hoemann@hpe.com> Date: Mon Apr 11 15:02:28 2016 -0700 libnvdimm: increase max envelope size for ioctl nd_ioctl() must first read in the fixed sized portion of an ioctl so that it can then determine the size of the variable part. Prepare for ND_CMD_CALL calls which have larger fixed portion envelope. Signed-off-by: Jerry Hoemann <jerry.hoemann@hpe.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> include/linux/libnvdimm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 48ea582f3dc00174cd4f6d4fb8b62883bc432b3f Merge: 2c69599 5b60422 Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Apr 29 00:09:04 2016 +0200 Merge tag 'omap-for-v4.7/dt-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/dt Merge "Part two of device tree changes for omaps for v4.7 merge window" from Tony Lindgren: - Fix few typos for address-cells and interrupt-names - Update dra7 voltage rail limits - Update compatible string for pcf8575 for both nxp and ti prefix - Add omap5 configuration for gpadc - Update dra7 for qspi to remove pinmux as it needs to be done by the bootloader in isolation. Also update the qspi for 64MHz frequency. - Add support for Baltos ir2110 and ir3220 - Add industrial and commercial grade thermal thresholds for am57xx * tag 'omap-for-v4.7/dt-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: dts: am57xx-idk: Include Industrial grade thermal thresholds ARM: dts: am57xx-beagle-x15: Include the commercial grade thresholds ARM: dts: am57xx: Introduce industrial grade thermal thresholds ARM: dts: am57xx: Introduce commercial grade thermal thresholds ARM: dts: add DTS for Baltos IR2110 ARM: dts: add DTS for Baltos IR3220 ARM: dts: split am335x-baltos-ir5221 into dts and dtsi files ARM: dts: dra7x: Support QSPI MODE-0 operation at 64MHz ARM: dts: dra7x: Remove QSPI pinmux ARM: dts: omap5-board-common: describe gpadc for Palmas ARM: dts: twl6030: describe gpadc ARM: dts: dra7xx: Fix compatible string for PCF8575 chip ARM: dts: AM57xx/DRA7: Update SoC voltage rail limits to match data sheet ARM: dts: OMAP36xx: : DT spelling s/#address-cell/#address-cells/ ARM: dts: omap5-cm-t54: DT spelling s/interrupt-name/interrupt-names/ ARM: dts: omap5-board-common: DT spelling s/interrupt-name/interrupt-names/ commit a651b61b8721b517044bb62de88de35924e7ffa1 Merge: 98c67e7 7147493 Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Apr 29 00:07:48 2016 +0200 Merge tag 'omap-for-v4.7/defconfig-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/defconfig Merge "Defconfig changes for omap2plus_defconfig for v4.7 merge window" from Tony Lindgren: Mostly enable drivers used on various boards as loadable modules where possible. Also one warning fix related to RXKAD changes heading to v4.7. And run make save_defconfig to shrink down the size a bit. * tag 'omap-for-v4.7/defconfig-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: omap2plus_defconfig: Enable PWM and ir-rx51 as loadable modules ARM: omap2plus_defconfig: Enable twl6030 USB phy as loadable module ARM: omap2plus_defconfig: Fix warning due invalid RXKAD symbol value ARM: omap2plus_defconfig: Update with make savedefconfig ARM: omap2plus_defconfig: Enable MDIO Bus/PHY emulation support ARM: omap2plus_defconfig: Enable DP83867 support ARM: omap2plus_defconfig: Enable GPIO_TPIC2810 commit 94a92cca9bf3db9d6ddd4557477e4e197cafe568 Merge: 0d922f4 22292b9 Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Apr 29 00:05:07 2016 +0200 Merge tag 'omap-for-v4.7/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/soc Merge "SoC related changes for omaps for v4.7 merge window" from Tony Lindgren: - Remove now unnecessary multi vs single SoC compile time optimizations as we are now using multiarch - Configure dra7 powerdomains - Clarify why omap-wakeupgen does not need to handle FROZEN transitions - Add dra7 module configuration for MaASP, PWMSS and timer 12 - Add RTC module configuration unlock and lock functions - Fix hwmod idle state sanity check sequence * tag 'omap-for-v4.7/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: OMAP2+: wakeupgen: Add comment for unhandled FROZEN transitions ARM: OMAP: DRA7: powerdomain data: Remove wrong OSWR capability ARM: OMAP: DRA7: powerdomain data: Fix "ON" state for memories ARM: OMAP: DRA7: powerdomain data: Erratum i892 workaround: Disable core INA ARM: OMAP2+: remove redundant multiplatform checks ARM: OMAP2+: hwmod: fix _idle() hwmod state sanity check sequence ARM: DRA7: hwmod: Add data for GPTimer 12 ARM: AMx3xx: RTC: Add lock and unlock functions ARM: DRA7: RTC: Add lock and unlock functions ARM: OMAP2+: hwmod: RTC: Add lock and unlock functions ARM: OMAP2+: DRA7: Add hwmod entries for PWMSS ARM: DRA7: hwmod: Add data for McASP1/2/4/5/6/7/8 ARM: DRA7: clockdomain: Implement timer workaround for errata i874 ARM: OMAP2+: hwmod: Fix updating of sysconfig register commit 10c1f7d32bf451d4309850c15ab1fdadccf92620 Author: Tony Lindgren <tony@atomide.com> Date: Thu Apr 28 08:20:53 2016 -0700 ARM: OMAP2+: n900 needs MMC slot names for legacy user space Let's pass the slot names in pdata like the legacy code does. Once we have a generic DT binding for the slot names we can switch to that. Tested-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/pdata-quirks.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 8453c5cafd32c4d6bd13ec4a62d4b639f4edb222 Author: Tony Lindgren <tony@atomide.com> Date: Thu Apr 28 08:21:03 2016 -0700 ARM: OMAP2+: Add more functions to pwm pdata for ir-rx51 Before we start removing omap3 legacy booting support, let's make n900 DT booting behave the same way for ir-rx51 as the legacy booting does. For now, we need to pass pdata to the ir-rx51 driver. This means that the n900 tree can move to using DT based booting without having to carry all the legacy platform data with it when it gets dropped from the mainline tree. Note that the ir-rx51 driver is currently disabled because of the dependency to !ARCH_MULTIPLATFORM. This will get sorted out later with the help of drivers/pwm/pwm-omap-dmtimer.c. But first we need to add chained IRQ support to dmtimer code to avoid introducing new custom frameworks. So let's just pass the necessary dmtimer functions to ir-rx51 so we can get it working in the following patch. Cc: Neil Armstrong <narmstrong@baylibre.com> Tested-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/board-rx51-peripherals.c | 35 ++++++++++++++++++++++++-- arch/arm/mach-omap2/pdata-quirks.c | 33 +++++++++++++++++++++++- include/linux/platform_data/media/ir-rx51.h | 1 + include/linux/platform_data/pwm_omap_dmtimer.h | 21 ++++++++++++++++ 4 files changed, 87 insertions(+), 3 deletions(-) commit 494e8489db50157637d146ee377991ed6f0018f1 Author: Mahesh Bandewar <maheshb@google.com> Date: Wed Apr 27 14:59:27 2016 -0700 ipvlan: Fix failure path in dev registration during link creation When newlink creation fails at device-registration, the port->count is decremented twice. Francesco Ruggeri (fruggeri@arista.com) found this issue in Macvlan and the same exists in IPvlan driver too. While fixing this issue I noticed another issue of missing unregister in case of failure, so adding it to the fix which is similar to the macvlan fix by Francesco in commit 308379607548 ("macvlan: fix failure during registration v3") Reported-by: Francesco Ruggeri <fruggeri@arista.com> Signed-off-by: Mahesh Bandewar <maheshb@google.com> CC: Eric Dumazet <edumazet@google.com> CC: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ipvlan/ipvlan_main.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit 222e4d0b13c674b28a562d67c270367d45d0a53d Author: françois romieu <romieu@fr.zoreil.com> Date: Wed Apr 27 23:29:44 2016 +0200 pch_gbe: replace private tx ring lock with common netif_tx_lock pch_gbe_tx_ring.tx_lock is only used in the hard_xmit handler and in the transmit completion reaper called from NAPI context. Compile-tested only. Potential victims Cced. Someone more knowledgeable may check if pch_gbe_tx_queue could have some use for a mmiowb. Signed-off-by: Francois Romieu <romieu@fr.zoreil.com> Cc: Darren Hart <dvhart@infradead.org> Cc: Andy Cress <andy.cress@us.kontron.com> Cc: bryan@fossetcon.org Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h | 2 -- drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c | 10 ++-------- 2 files changed, 2 insertions(+), 10 deletions(-) commit badf3ada60ab8f76f9488dc8f5c0c57f70682f5a Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Apr 27 11:45:14 2016 -0700 net: dsa: Provide CPU port statistics to master netdev This patch overloads the DSA master netdev, aka CPU Ethernet MAC to also include switch-side statistics, which is useful for debugging purposes, when the switch is not properly connected to the Ethernet MAC (duplex mismatch, (RG)MII electrical issues etc.). We accomplish this by retaining the original copy of the master netdev's ethtool_ops, and just overload the 3 operations we care about: get_sset_count, get_strings and get_ethtool_stats so as to intercept these calls and call into the original master_netdev ethtool_ops, plus our own. We take this approach as opposed to providing a set of DSA helper functions that would retrive the CPU port's statistics, because the entire purpose of DSA is to allow unmodified Ethernet MAC drivers to be used as CPU conduit interfaces, therefore, statistics overlay in such drivers would simply not scale. The new ethtool -S <iface> output would therefore look like this now: <iface> statistics p<2 digits cpu port number>_<switch MIB counter names> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/dsa.h | 5 ++++ net/dsa/slave.c | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 93 insertions(+) commit 0cef6a4c34b56a9a6894f2dad2fad4be789990e1 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 10:12:25 2016 -0700 tcp: give prequeue mode some care TCP prequeue goal is to defer processing of incoming packets to user space thread currently blocked in a recvmsg() system call. Intent is to spend less time processing these packets on behalf of softirq handler, as softirq handler is unfair to normal process scheduler decisions, as it might interrupt threads that do not even use networking. Current prequeue implementation has following issues : 1) It only checks size of the prequeue against sk_rcvbuf It was fine 15 years ago when sk_rcvbuf was in the 64KB vicinity. But we now have ~8MB values to cope with modern networking needs. We have to add sk_rmem_alloc in the equation, since out of order packets can definitely use up to sk_rcvbuf memory themselves. 2) Even with a fixed memory truesize check, prequeue can be filled by thousands of packets. When prequeue needs to be flushed, either from sofirq context (in tcp_prequeue() or timer code), or process context (in tcp_prequeue_process()), this adds a latency spike which is often not desirable. I added a fixed limit of 32 packets, as this translated to a max flush time of 60 us on my test hosts. Also note that all packets in prequeue are not accounted for tcp_mem, since they are not charged against sk_forward_alloc at this point. This is probably not a big deal. Note that this might increase LINUX_MIB_TCPPREQUEUEDROPPED counts, which is misnamed, as packets are not dropped at all, but rather pushed to the stack (where they can be either consumed or dropped) Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_ipv4.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit b43e7199a9061562e28c72192a1d07e00ec4e97f Author: Michal Kazior <michal.kazior@tieto.com> Date: Wed Apr 27 12:59:13 2016 +0200 fq: split out backlog update logic mac80211 (which will be the first user of the fq.h) recently started to support software A-MSDU aggregation. It glues skbuffs together into a single one so the backlog accounting needs to be more fine-grained. To avoid backlog sorting logic duplication split it up for re-use. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/fq_impl.h | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) commit b43586576e54609f7970096478cf4113de18a4db Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Wed Apr 27 11:05:28 2016 +0300 tipc: remove an unnecessary NULL check This is never called with a NULL "buf" and anyway, we dereference 's' on the lines before so it would Oops before we reach the check. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/subscr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 6b87663fbe4a366e558d6566b3e6b6bc227da5a1 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 17:52:33 2016 +0200 net/mlx5e: avoid stack overflow in mlx5e_open_channels struct mlx5e_channel_param is a large structure that is allocated on the stack of mlx5e_open_channels, and with a recent change it has grown beyond the warning size for the maximum stack that a single function should use: mellanox/mlx5/core/en_main.c: In function 'mlx5e_open_channels': mellanox/mlx5/core/en_main.c:1325:1: error: the frame size of 1072 bytes is larger than 1024 bytes [-Werror=frame-larger-than=] The function is already using dynamic allocation and is not in a fast path, so the easiest workaround is to use another kzalloc for allocating the channel parameters. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: d3c9bc2743dc ("net/mlx5e: Added ICO SQs") Acked-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 3df97ba83019d524c012fd43d3216d4cc3005955 Author: Jason Wang <jasowang@redhat.com> Date: Mon Apr 25 23:13:42 2016 -0400 tuntap: calculate rps hash only when needed There's no need to calculate rps hash if it was not enabled. So this patch export rps_needed and check it before trying to get rps hash. Tests (using pktgen to inject packets to guest) shows this can improve pps about 13% (when rps is disabled). Before: ~1150000 pps After: ~1300000 pps Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com> ---- Changes from V1: - Fix build when CONFIG_RPS is not set Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 4 +++- net/core/dev.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) commit ccea5f0f01797a0c0b6cba8176ecda3b10ca8534 Author: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Date: Fri Apr 22 14:14:29 2016 -0500 RDMA/i40iw: Fix for removing quad hash entries Fix for removing a quad hash entry when the corresponding quad hash entry hasn't been added, which is the case in loopback connections Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_cm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit f8a4e76c75e572a8503410b8f863e7fa420236ba Author: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Date: Fri Apr 22 14:14:28 2016 -0500 RDMA/i40iw: Fix for checking if the QP is destroyed Fix for checking if the QP associated with a completion has been destroyed while processing CQ elements. If that is the case, move the CQ head to the next element and continue completion processing. Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_status.h | 1 + drivers/infiniband/hw/i40iw/i40iw_uk.c | 5 +++++ drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 ++ 3 files changed, 8 insertions(+) commit 6c2f76197db63e337fb60b16800f234f6428c32d Author: Shiraz Saleem <shiraz.saleem@intel.com> Date: Fri Apr 22 14:14:27 2016 -0500 RDMA/i40iw: Fix for using one sge for RDMA READ A check is added to validate the requested sge number. iWARP doesn't support multiple sg elements for RDMA READ work requests. Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit df2d96c3d00413cbdd0d5e391aeba6eef806b88d Author: Shiraz Saleem <shiraz.saleem@intel.com> Date: Fri Apr 22 14:14:26 2016 -0500 RDMA/i40iw: Fix for the size of kernel mode SQ Fix to calculate the SQ size based on the max frag_count, requested by the application instead of overwriting it with the max supported frag_count Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 -- 1 file changed, 2 deletions(-) commit 84a4c246639aab8cb4c28b4313a3c676fe5ea263 Author: Mohammad Khan <mohammad.a.khan@intel.com> Date: Fri Apr 22 14:14:25 2016 -0500 RDMA/i40iw: Fix for a NOP WQE size Fix for filling in the WQE size for NOP Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_uk.c | 3 +++ 1 file changed, 3 insertions(+) commit 8e9f04a7c744bb18c193779d04cc5d8d4c21dd11 Author: Chien Tin Tung <Chien.Tin.Tung@intel.com> Date: Fri Apr 22 14:14:24 2016 -0500 RDMA/i40iw: Correct STag mask to min of 14 bits STag index mask is calculated incorrectly, missing the 14 bits minimum requirement. Add max macro to use either # of MRs or 14 bits in the mask size calculation. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_hw.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9510b0666eaeda032de89a54f112cb3e9f41b2c5 Author: Shiraz Saleem <shiraz.saleem@intel.com> Date: Fri Apr 22 14:14:23 2016 -0500 RDMA/i40iw: Fixes for WQE alignment Invalidation after every WQE write is changed to invalidate only if required. NOPs are padded so that WQE writes are aligned to 64B boundary. Signed-off-by: Tatyana Nikolova <tatyana.e.nikolova@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_d.h | 2 ++ drivers/infiniband/hw/i40iw/i40iw_uk.c | 18 ++++++++++++++++-- 2 files changed, 18 insertions(+), 2 deletions(-) commit c2b75ef7dcb9cf5e237955b0d0fa48918978493d Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:09 2016 -0500 RDMA/i40iw: Adding queue drain functions Adding sq and rq drain functions, which block until all previously posted wr-s in the specified queue have completed. A completion object is signaled to unblock the thread, when the last cqe for the corresponding queue is processed. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 38 +++++++++++++++++++++++++++++++ drivers/infiniband/hw/i40iw/i40iw_verbs.h | 2 ++ 2 files changed, 40 insertions(+) commit fa4153796121e573be7f9b8f59ac7eb0694d1ac0 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:08 2016 -0500 RDMA/i40iw: Fix SD calculation for initial HMC creation Correct SD calculation by using base address returned from commit FPM. This alleviates any assumptions on resource ordering and alignment requirement. Also consolidate SD estimation code into i40iw_est_sd(). Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_ctrl.c | 93 +++++++++++++++++++++----------- drivers/infiniband/hw/i40iw/i40iw_type.h | 2 +- 2 files changed, 62 insertions(+), 33 deletions(-) commit 20c61f7e88a02366dc94d77179cf005eec6162e6 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:07 2016 -0500 RDMA/i40iw: Fix endian issues and warnings Fix endian warnings and errors due to u32 stored to u16. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw.h | 4 +-- drivers/infiniband/hw/i40iw/i40iw_cm.c | 57 ++++++++++++++++--------------- drivers/infiniband/hw/i40iw/i40iw_ctrl.c | 10 +++--- drivers/infiniband/hw/i40iw/i40iw_hw.c | 4 +-- drivers/infiniband/hw/i40iw/i40iw_main.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_puda.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_type.h | 4 +-- drivers/infiniband/hw/i40iw/i40iw_utils.c | 27 +++++++-------- 8 files changed, 54 insertions(+), 56 deletions(-) commit b7aee855d3b93f31ea692ea5c7565318372d1042 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:06 2016 -0500 RDMA/i40iw: Add base memory management extensions Implement fast register mr, Local invalidate, send with invalidate and RDMA read with invalidate. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_ctrl.c | 82 ++++++++++-- drivers/infiniband/hw/i40iw/i40iw_type.h | 3 + drivers/infiniband/hw/i40iw/i40iw_verbs.c | 204 ++++++++++++++++++++++++++++-- drivers/infiniband/hw/i40iw/i40iw_verbs.h | 1 + 4 files changed, 271 insertions(+), 19 deletions(-) commit eb9b0379f8215345c78a5e105af2f029b3a84095 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:05 2016 -0500 RDMA/i40iw: Initialize max enabled vfs variable Initialize max enabled vfs to max rdma vfs instead of 0. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 1 + 1 file changed, 1 insertion(+) commit 5c1c1908c124b0be65432177cfcba99a5044fe79 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:04 2016 -0500 RDMA/i40iw: Correct return code check in add_pble_pool Move return code check to immediately after i40iw_hmc_sd_one call where it is set instead of outside the then statement. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_pble.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit f69c3331624438321877083e27f5aa09eab3b863 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:03 2016 -0500 RDMA/i40iw: Add virtual channel message queue Queue users of virtual channel on a waitqueue until the channel is clear instead of failing the call when the channel is occupied. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_main.c | 47 +++++++++++--- drivers/infiniband/hw/i40iw/i40iw_osdep.h | 1 + drivers/infiniband/hw/i40iw/i40iw_type.h | 3 +- drivers/infiniband/hw/i40iw/i40iw_utils.c | 11 ++-- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 8 +-- drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 96 +++++++++++++++------------- 6 files changed, 103 insertions(+), 63 deletions(-) commit f606d8933004716877eedd73ab609fb92deef84d Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:02 2016 -0500 RDMA/i40iw: Remove unused code and fix warning Remove unused code and fix warning. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw.h | 2 -- drivers/infiniband/hw/i40iw/i40iw_cm.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_cm.h | 10 +--------- drivers/infiniband/hw/i40iw/i40iw_main.c | 5 +---- 4 files changed, 3 insertions(+), 16 deletions(-) commit 4920dc311c77779fbbd71621ecbb9f03f296d72d Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:01 2016 -0500 RDMA/i40iw: Populate vendor_id and vendor_part_id fields Populate PCI info fields from PCI device structure. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit df35630af33fb8f470b6739eced5a2ad3a7cb55d Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:33:00 2016 -0500 RDMA/i40iw: Set vendor_err only if there is an actual error Add a check for cq_poll_info.error before setting vendor_err instead of always setting it. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 996abf0a52e62e844b50344157060bb6ec609bc7 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:59 2016 -0500 RDMA/i40iw: Add qp table lock around AE processing QP may be freed during Async Event processing. Add a lock around QP table to prevent it. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw.h | 1 + drivers/infiniband/hw/i40iw/i40iw_hw.c | 7 +++++++ drivers/infiniband/hw/i40iw/i40iw_utils.c | 9 +++++++-- 3 files changed, 15 insertions(+), 2 deletions(-) commit 36a479335051ea5ad552f8234722a908179fc8f0 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:58 2016 -0500 RDMA/i40iw: Do not set self-referencing pointer to NULL after free iwqp->allocated_buffer is a self-referencing pointer to iwqp. Do not set iwqp->allocated_buffer to NULL after freeing it. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 1 - 1 file changed, 1 deletion(-) commit bd57aeae563c8f032d6eee1c151f12b03191f053 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:57 2016 -0500 RDMA/i40iw: Correct max message size in query port Fix to correct max reported message size in query port. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3437e0d5ab56d0439ff0ac50e190cfbb6711096 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:56 2016 -0500 RDMA/i40iw: Fix refused connections Make sure cm_node is setup before sending SYN packet and ORD/IRD negotiation. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_cm.c | 85 ++++++++++++++++++---------------- 1 file changed, 44 insertions(+), 41 deletions(-) commit 23ef48ad6cfb981f6a1a605306d87c5ad0d1e1ac Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:55 2016 -0500 RDMA/i40iw: Correct QP size calculation Include inline data size as part of SQ size calculation. RQ size calculation uses only number of SGEs and does not support 96 byte WQE size. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_d.h | 2 +- drivers/infiniband/hw/i40iw/i40iw_uk.c | 80 ++++++++++++------------------- drivers/infiniband/hw/i40iw/i40iw_user.h | 34 +++++++------ drivers/infiniband/hw/i40iw/i40iw_verbs.c | 8 +++- 4 files changed, 58 insertions(+), 66 deletions(-) commit 6b90036587508675b9ef73181c9f0f02894d1588 Author: Ismail, Mustafa <mustafa.ismail@intel.com> Date: Mon Apr 18 10:32:54 2016 -0500 RDMA/i40iw: Fix overflow of region length Change region_length to u64 as a region can be > 4GB. Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/i40iw/i40iw_user.h | 2 ++ drivers/infiniband/hw/i40iw/i40iw_verbs.c | 8 +++++--- 2 files changed, 7 insertions(+), 3 deletions(-) commit d35cf74492c5ba0d8e1c08755c78be4ef3af650e Author: Jubin John <jubin.john@intel.com> Date: Thu Apr 14 08:31:53 2016 -0700 IB/hfi1: Serialize hrtimer function calls hrtimer functions do not guarantee serialization, so we extend the cca_timer_lock to cover the hrtimer_forward_now() in the hrtimer callback handler and the hrtimer_start() in process_becn(). This prevents races between these 2 functions to update the hrtimer state leading to problems such as: kernel BUG at kernel/hrtimer.c:1282! encountered during validation of the CCA feature. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/init.c | 20 +++++++++----------- drivers/staging/rdma/hfi1/rc.c | 7 +++---- 2 files changed, 12 insertions(+), 15 deletions(-) commit 1cbaa670355e4a4e339ac97167fb8ecf536045d3 Author: Dean Luick <dean.luick@intel.com> Date: Thu Apr 14 08:31:48 2016 -0700 IB/hfi1: Fix MAD port poll for active cables A MAD directive to start polling must go through the normal link tuning and start steps in order to correctly handle active cables. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mad.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) commit 015e91fbc9c6ab48596aa38fc0f8c8aab44036f9 Author: Dean Luick <dean.luick@intel.com> Date: Thu Apr 14 08:31:42 2016 -0700 IB/hfi1: Correctly report neighbor link down reason The code to save the link down reason for reporting to the SMA was in a location before the actual reason was read. Move the SMA link down reason assignment to a better location. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) commit feb831ddf2f2cfbc4d26d9df3a982790f6fbbf6a Author: Dean Luick <dean.luick@intel.com> Date: Thu Apr 14 08:31:36 2016 -0700 IB/hfi1: Use the neighbor link down reason only when valid The 8051 uses a link down reason to inform the driver why the link went down. The neighbor planned link down reason code is only valid when a link down idle message is received by the 8051. Enhance the explanation on why the link went down. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 133 ++++++++++++++++++++++++++++++++++++--- drivers/staging/rdma/hfi1/chip.h | 6 ++ 2 files changed, 130 insertions(+), 9 deletions(-) commit f9b5635cbe7bcacb94870e44387df133dd851b10 Author: Dean Luick <dean.luick@intel.com> Date: Thu Apr 14 08:31:30 2016 -0700 IB/hfi1: Ignore link downgrade with 0 lanes Versions of the 8051 firmware < 0.38 may report a link failure as a link downgrade with a width of 0 followed by a link down notification. Ignore the zero width downgrade notification - the driver should follow the link down path. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 8f000f7f6e0ad8973f76cc64ecbc4d84099ff959 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:32:06 2016 -0700 IB/hfi1: Add RSM rule for user FECN handling Add a receive side mapping rule to extract expected user packets with the FECN bit set and place them in an eager buffer. This will allow user libraries to recognize that a FECN was sent when using header suppression and respond appropriately. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 84 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) commit b12349ae13e13b9d07dfda4c1484f91c44c4b469 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:31:33 2016 -0700 IB/hfi1: Create a routine to set a receive side mapping rule Move the rule setting code into its own routine for improved searchability and reuse. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 75 ++++++++++++++++++++++++++++++---------- 1 file changed, 57 insertions(+), 18 deletions(-) commit 4a818bedf7b6087f4bbf875847b11f1946775934 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:31:11 2016 -0700 IB/hfi1: Move QOS decision logic into its own function The decision to use QOS affects other resource allocation. Move the QOS decision logic into its own function so it can be called by other interested parties. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 67 ++++++++++++++++++++++++++++++---------- 1 file changed, 50 insertions(+), 17 deletions(-) commit 372cc85a13c97d6c743cb8df25b52fa5e93d73f6 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:30:51 2016 -0700 IB/hfi1: Extract RSM map table init from QOS Refactor the allocation, tracking, and writing of the RSM map table into its own set of routines. This will allow the map table to be passed to multiple users to fill in as needed. Start with the original user, QOS. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 91 +++++++++++++++++++++++------- drivers/staging/rdma/hfi1/chip_registers.h | 1 + 2 files changed, 71 insertions(+), 21 deletions(-) commit 44306f15f0575bff67a923c28aff6e7b2d33021f Author: Jianxin Xiong <jianxin.xiong@intel.com> Date: Tue Apr 12 11:30:28 2016 -0700 IB/hfi1: Reduce kernel context pio buffer allocation The pio buffers were pooled evenly among all kernel contexts and user contexts. However, the demand from kernel contexts is much lower than user contexts. This patch reduces the allocation for kernel contexts and thus makes more credits available for PSM, helping performance. This is especially useful on high core-count systems where large numbers of contexts are used. A new context type SC_VL15 is added to distinguish the context used for VL15 from other kernel contexts. The reason is that VL15 needs to support 2KB sized packet while other kernel contexts need only support packets up to the size determined by "piothreshold", which has a default value of 256. The new allocation method allows triple buffering of largest pio packets configured for these contexts. This is sufficient to maintain verbs performance. The largest pio packet size is 2048B for VL15 and "piothreshold" for other kernel contexts. A cap is applied to "piothreshold" to avoid excessive buffer allocation. The special case that SDMA is disable is handled differently. In that case, the original pooling allocation is used to better support the much higher pio traffic. Notice that if adaptive pio is disabled (piothreshold==0), the pio buffer size doesn't matter for non-VL15 kernel send contexts when SDMA is enabled because pio is not used at all on these contexts and thus the new allocation is still valid. If SDMA is disabled then pooling allocation is used as mentioned in previous paragraph. Adjustment is also made to the calculation of the credit return threshold for the kernel contexts. Instead of purely based on the MTU size, a percentage based threshold is also considered and the smaller one of the two is chosen. This is necessary to ensure that with the reduced buffer allocation credits are returned in time to avoid unnecessary stall in the send path. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mark Debbage <mark.debbage@intel.com> Reviewed-by: Jubin John <jubin.john@intel.com> Signed-off-by: Jianxin Xiong <jianxin.xiong@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 27 +++++++++++---------- drivers/staging/rdma/hfi1/diag.c | 3 ++- drivers/staging/rdma/hfi1/pio.c | 52 +++++++++++++++++++++++++++++++--------- drivers/staging/rdma/hfi1/pio.h | 4 +++- 4 files changed, 61 insertions(+), 25 deletions(-) commit 0852d241f48463d80764f841f2e06c0f3c4da923 Author: Jubin John <jubin.john@intel.com> Date: Tue Apr 12 11:30:08 2016 -0700 IB/hfi1: Change default number of user contexts Change the default number of user contexts to the number of real (non-HT) cpu cores in order to reduce the division of hfi1 hardware contexts in the case of high core counts with hyper-threading enabled. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/affinity.c | 93 ++++++++++++++++++------------------ drivers/staging/rdma/hfi1/affinity.h | 19 +++++++- drivers/staging/rdma/hfi1/chip.c | 26 +++++++--- 3 files changed, 84 insertions(+), 54 deletions(-) commit b218f786adc215509e806fe4eb98725e33e8d784 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue Apr 12 11:29:20 2016 -0700 IB/hfi1: Use global defines for upper bits in opcode The awkward coding for setting the allowed_ops field was tripping an smatch warning. This patch uses the more appropriate defines from include/rdma to avoid the issue. As part of the patch remove a mask that was duplicated in rdmavt include files and use that mask as appropriate. Fixes: 8bea6b1cfe6f ("IB/rdmavt: Add create queue pair functionality") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/sw/rdmavt/qp.c | 6 +++--- drivers/staging/rdma/hfi1/verbs.c | 2 +- drivers/staging/rdma/hfi1/verbs.h | 3 --- 3 files changed, 4 insertions(+), 7 deletions(-) commit 87717f0a75432e078bb894ba230dd236be7a31a7 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue Apr 12 11:28:56 2016 -0700 IB/hfi1: Remove unreachable code Remove unreachable code from RC ack handling to fix an smatch error. Fixes: 633d27399514 ("staging/rdma/hfi1: use mod_timer when appropriate") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/rc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e4e0e39c8d41d5f6cb664a34ac7b2c6388b1b523 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:28:36 2016 -0700 IB/hfi1: Fix double QSFP resource acquire on cache refresh The function refresh_qsfp_cache() acquires the i2c chain resource, but one caller already holds the resource. Change the acquire so all calls to refresh_qsfp_cache() are covered by the acquire and remove the acquire within refresh_qsfp_cache(). Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/platform.c | 40 ++++++++++++++++++------------------ drivers/staging/rdma/hfi1/qsfp.c | 12 +++-------- 2 files changed, 23 insertions(+), 29 deletions(-) commit 90315ad86abfe2fe43a564d705a342d823c1589c Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 11:26:21 2016 -0700 IB/hfi1: Guard against concurrent I2C access across all chains The discrete ASIC board design makes the two I2C chains not independent of each other. That is, only one chain can safely be accessed at a time. For discrete ASIC devices, adjust the resource locking so that access to one I2C chain will lock both of the chains. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/firmware.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 623bba2d92a32572e21758a17718eeec65594f7d Author: Easwar Hariharan <easwar.hariharan@intel.com> Date: Tue Apr 12 11:25:57 2016 -0700 IB/hfi1: Remove module presence check outside pre-LNI checks The pre-LNI SerDes and channel tuning algorithm already checks for module presence assertion for the relevant port types. The extraneous check removed in this patch blocks link up for port types for which the module presence assertion is not relevant. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 20 ++++++-------------- drivers/staging/rdma/hfi1/platform.c | 8 ++++++-- 2 files changed, 12 insertions(+), 16 deletions(-) commit 145dd2b3995830ab4bf14f1dc7d44dc5d2b7cb10 Author: Easwar Hariharan <easwar.hariharan@intel.com> Date: Tue Apr 12 11:25:31 2016 -0700 IB/hfi1: Always turn on CDRs for low power QSFP modules Clock and data recovery mechanisms (CDRs) in active QSFP modules can be turned on or off to improve the bit error rate observed on the channel. Signal integrity and bit error rate requirements require us to always turn on any CDRs present in low power cables (power dissipation 2.5W or lower). However, we adhere to the platform designer's settings (provided in the platform configuration) for higher power cables (dissipation 3.5W or higher) if the platform designer has determined that the platform requires the CDRs to be turned on (or off) and is capable of supplying and cooling the higher power modules. This patch also introduces the get_qsfp_power_class function to centralize the bit twiddling required to determine the QSFP power class across the code. Reusing this function improves the readability of code that depends on knowing the power class of the cable, such as the active and optical channel tuning algorithm. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 49 +++------------------------------- drivers/staging/rdma/hfi1/chip.h | 1 - drivers/staging/rdma/hfi1/hfi.h | 1 - drivers/staging/rdma/hfi1/init.c | 1 - drivers/staging/rdma/hfi1/platform.c | 51 ++++++++++++++++++++---------------- drivers/staging/rdma/hfi1/qsfp.c | 38 ++++++++++++++++++++++++--- drivers/staging/rdma/hfi1/qsfp.h | 15 +++++------ 7 files changed, 74 insertions(+), 82 deletions(-) commit e38d1e4f5099d533a833afee89f439853c94f272 Author: Sebastian Sanchez <sebastian.sanchez@intel.com> Date: Tue Apr 12 11:22:21 2016 -0700 IB/hfi1: Check P_KEY for all sent packets from user mode Add the P_KEY check for user-context mechanism for both PIO and SDMA. For PIO, the SendCtxtCheckEnable.DisallowKDETHPackets is set by default. When the P_KEY is set, SendCtxtCheckEnable.DisallowKDETHPackets is cleared. For SDMA, a software check was included. This change requires user processes to set the P_KEY before sending any packets, otherwise, the sent packet will fail. The original submission didn't have this check but it's required. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mikto Haralanov <mitko.haralanov@intel.com> Signed-off-by: Sebastian Sanchez <sebastian.sanchez@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 1 + drivers/staging/rdma/hfi1/hfi.h | 4 ++ drivers/staging/rdma/hfi1/user_sdma.c | 7 +++ drivers/staging/rdma/hfi1/verbs.c | 106 +++++++++++++++++++++------------- 4 files changed, 77 insertions(+), 41 deletions(-) commit ef699e849c081d8123d574b3aa279f4e550de4ad Author: Sebastian Sanchez <sebastian.sanchez@intel.com> Date: Tue Apr 12 11:17:09 2016 -0700 IB/hfi1: Adjust default MTU to be 10KB Increasing the default MTU size to 10KB improves performance for PSM. Change the default MTU to 10KB but constrain Verbs MTU to 8KB. Also update default MTU module parameter description to be HFI1_DEFAULT_MAX_MTU. Reviewed-by: Dean Luick <dean.luick@intel.com> Reviewed-by: Mitko Haralanov <mitko.haralanov@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Reviewed-by: Jubin John <jubin.john@intel.com> Signed-off-by: Sebastian Sanchez <sebastian.sanchez@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/driver.c | 3 ++- drivers/staging/rdma/hfi1/hfi.h | 4 ++-- drivers/staging/rdma/hfi1/qp.c | 6 +++++- 3 files changed, 9 insertions(+), 4 deletions(-) commit 60d585ad6e64bac87a676df4d941c823360f6ae1 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:35 2016 -0700 IB/hfi1: Simplify init_qpmap_table() Make init_qpmap_table() easier to understand by simplifying the loop indexing and writing each register when it is "full", removing the need for a follow-on register write. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit de882ff5b8640c34d5f1d5dfd2f22f405465aa19 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:28 2016 -0700 IB/hfi1: Correctly obtain the full service class The function hdr2sc was using an unshifted mask to obtain the 5th bit of the service class. Correct the issue by using the shifted mask. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/hfi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 33a9eb527172cb46711705c858ccd605e32c82f9 Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:22 2016 -0700 IB/hfi1: Fix QOS rule mappings The QOS RSM rule mappings are off by one, referencing a kernel receive context that does not exist. Correctly start the QOS RSM map entries at FIRST_KERNEL_CONTEXT rather than MIN_KERNEL_KCTXTS. Remove the cruft that hid this. Change the QP map table so all traffic not caught by QOS RSM goes to the control context rather than the first QOS context. Correct comments to match the actual code operation and intent. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 48 ++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 27 deletions(-) commit 35969d9b949a479bebc72cf8049425cd05b3b28e Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:16 2016 -0700 IB/hfi1: Remove invalid QOS check Remove an invalid compare of the number of QOS RSM map table entries against the number of physical receive contexts. The RSM map table has its own size and has no relation to the number of physical receive contexts. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 2 -- 1 file changed, 2 deletions(-) commit 153d58cd8e2871ec99d3a6570dd26b6f569a8b5e Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:10 2016 -0700 IB/hfi1: Fix QOS num_vl bit width The bit width for num_vls, n, needs to be calculated based on the pow2 rounded up of the number of vls. Otherwise num_vls of 3, 5, 6, and 7 will have misplaced QOS RSM map entries. Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/chip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f9c82a0b75a120ca3e9542a7a6e60244d04c915a Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:50:04 2016 -0700 IB/hfi1: Fix i2c resource reservation checks The i2c and qsfp read/write routines should check for the resource reservation of the incoming argument target rather than the implicit target of the hardware HFI. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/qsfp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4ee1585972c0772a5126d7242a906b18acee7b0f Author: Dean Luick <dean.luick@intel.com> Date: Tue Apr 12 10:49:58 2016 -0700 IB/hfi1: Fix sysfs file offset usage Two sysfs files do not pay attention to the file offset when reading data. Fix that. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ea0e4ce3bcccef360e1aa69d17a210d1221ab80c Author: Jubin John <jubin.john@intel.com> Date: Wed Apr 20 06:05:24 2016 -0700 IB/rdmavt,hfi1,qib: Fix memory leak rdi->ports has memory allocated in rvt_alloc_device(), but does not get freed because the hfi1 and qib drivers drivers call ib_dealloc_device() directly instead of going through rdmavt. Add a rvt_dealloc_device() that frees rdi->ports and then calls ib_dealloc_device(). Switch hfi1 and qib drivers to calling rvt_dealloc_device() instead of ib_dealloc_device() directly. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Reviewed-by: Brian Welty <brian.welty@intel.com> Signed-off-by: Jubin John <jubin.john@intel.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/qib/qib_init.c | 4 ++-- drivers/infiniband/sw/rdmavt/vt.c | 13 +++++++++++++ drivers/staging/rdma/hfi1/init.c | 4 ++-- include/rdma/rdma_vt.h | 1 + 4 files changed, 18 insertions(+), 4 deletions(-) commit e88c9271d9f8db79d8104f7f7bd14cb8d88cc187 Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:53 2016 -0700 IB/hfi1: Fix buffer cache races which may cause corruption There are two possible causes for node/memory corruption both of which are related to the cache eviction algorithm. One way to cause corruption is due to the asynchronous nature of the MMU invalidation and the locking used when invalidating node. The MMU invalidation routine would temporarily release the RB tree lock to avoid a deadlock. However, this would allow the eviction function to take the lock resulting in the removal of cache nodes. If the node being removed by the eviction code is the same as the node being invalidated, the result is use after free. The same is true in the other direction due to the temporary release of the eviction list lock in the eviction loop. Another corner case exists when dealing with the SDMA buffer cache that could cause memory corruption of kernel memory. The most common way, in which this corruption exhibits itself is a linked list node corruption. In that case, the kernel will complain that a node with poisoned pointers is being removed. The fact that the pointers are already poisoned means that the node has already been removed from the list. To root cause of this corruption was a mishandling of the eviction list maintained by the driver. In order for this to happen four conditions need to be satisfied: 1. A node describing a user buffer already exists in the interval RB tree, 2. The beginning of the current user buffer matches that node but is bigger. This will cause the node to be extended. 3. The amount of cached buffers is close or at the limit of the buffer cache size. 4. The node has dropped close to the end of the eviction list. This will cause the node to be considered for eviction. If all of the above conditions have been satisfied, it is possible for the eviction algorithm to evict the current node, which will free the node without the driver knowing. To solve both issues described above: - the locking around the MMU invalidation loop and cache eviction loop has been improved so locks are not released in the loop body, - a new RB function is introduced which will "atomically" find and remove the matching node from the RB tree, preventing the MMU invalidation loop from touching it, and - the node being extended by the pin_vector_pages() function is removed from the eviction list prior to calling the eviction function. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mmu_rb.c | 6 ++-- drivers/staging/rdma/hfi1/user_sdma.c | 56 ++++++++++++++++++++++++++--------- 2 files changed, 45 insertions(+), 17 deletions(-) commit f53af85e4735514a572996fb551968da78657639 Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:47 2016 -0700 IB/hfi1: Extract and reinsert MMU RB node on lookup The page pinning function, which also maintains the pin cache, behaves one of two ways when an exact buffer match is not found: 1. If no node is not found (a buffer with the same starting address is not found in the cache), a new node is created, the buffer pages are pinned, and the node is inserted into the RB tree, or 2. If a node is found but the buffer in that node is a subset of the new user buffer, the node is extended with the new buffer pages. Both modes of operation require (re-)insertion into the interval RB tree. When the node being inserted is a new node, the operations are pretty simple. However, when the node is already existing and is being extended, special care must be taken. First, we want to guard against an asynchronous attempt to delete the node by the MMU invalidation notifier. The simplest way to do this is to remove the node from the RB tree, preventing the search algorithm from finding it. Second, the node needs to be re-inserted so it lands in the proper place in the tree and the tree is correctly re-balanced. This also requires the node to be removed from the RB tree. This commit adds the hfi1_mmu_rb_extract() function, which will search for a node in the interval RB tree matching an address and length and remove it from the RB tree if found. This allows for both of the above special cases be handled in a single step. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mmu_rb.c | 19 +++++++++++++++++++ drivers/staging/rdma/hfi1/mmu_rb.h | 2 ++ drivers/staging/rdma/hfi1/user_sdma.c | 33 ++++++++++++++------------------- 3 files changed, 35 insertions(+), 19 deletions(-) commit de79093b284888faedb826d8ecd326e5b6843d88 Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:41 2016 -0700 IB/hfi1: Correctly compute node interval The computation of the interval of an interval RB node was incorrect leading to data corruption due to the RB search algorithm not properly finding the all RB nodes in an MMU invalidation interval. The problem stemmed from the fact that the beginning address of the node's range was being aligned to a page boundary. For certain buffer sizes, this would lead to a end address calculation that was off by 1 page. An important aspect of keeping the RB same is also updating the node's range in the case it's being extended. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mmu_rb.c | 2 +- drivers/staging/rdma/hfi1/user_sdma.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 782f6697d20d180843565ac93726f5ec6c7ec8ce Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:35 2016 -0700 IB/hfi1: Protect the interval RB tree when cleaning up The current implementation of the clean up function for the interval RB trees has two flaws which may cause problems in cases of concurrent executing of the function and MMU notifier. The flaws were due to the fact that deregistration of the MMU callbacks was done after the tree was emptied and, furthermore, the tree was not being locked. This commit fixes both of these flaws by, first, switch the order of operations, and, second, locking the tree while traversing it to prevent any other operations. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/mmu_rb.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 0ad2d3d05b4a597d1f2e239dcc6ab537cc3eeacb Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:29 2016 -0700 IB/hfi1: Fix memory leak in user ExpRcv and SDMA The driver had two memory leaks - one in the user expected receive code and one in SDMA buffer cache. The leak in the expected receive code only showed up when the user/admin had set ulimit sufficiently low and the driver did not have enough room in the cache before hitting the limit of allowed cachable memory. When this condition occurred, the driver returned early signaling userland that it needed to free some buffers to free up room in the cache. The bug was that the driver was not cleaning up allocated memory prior to returning early. The leak in the SDMA buffer cache could occur (even though it never did), when the insertion of a buffer node in the interval RB tree failed. In this case, the driver failed to unpin the pages of the node instead erroneously returning success. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/user_exp_rcv.c | 7 +++++-- drivers/staging/rdma/hfi1/user_sdma.c | 3 ++- 2 files changed, 7 insertions(+), 3 deletions(-) commit 4787bc5e1783e94f6b9518664609f3034dc799eb Author: Mitko Haralanov <mitko.haralanov@intel.com> Date: Tue Apr 12 10:46:23 2016 -0700 IB/hfi1: Don't remove list entries if they are not in a list The SDMA cache logic maintains an eviction list which is ordered by most recently used user buffers. Upon errors or buffer freeing, the list nodes were unconditionally being deleted. This would lead to list corruption warnings if the nodes were never inserted in the eviction list to begin with. This commit prevents this by checking that the nodes are already part of the eviction list. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mitko Haralanov <mitko.haralanov@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/staging/rdma/hfi1/user_sdma.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 747f4d7a9d1bc07e3f9f22c84201ffb0abee1634 Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue Apr 12 10:46:10 2016 -0700 IB/qib, IB/hfi1: Fix up UD loopback use of irq flags The dual lock patch moved locking around and missed an issue with handling irq flags when processing UD loopback packets. This issue was revealed by smatch. Fix for both qib and hfi1 to pass the saved flags to the UD request builder and handle the changes correctly. Fixes: 46a80d62e6e0 ("IB/qib, staging/rdma/hfi1: add s_hlock for use in post send") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/hw/qib/qib_rc.c | 2 +- drivers/infiniband/hw/qib/qib_ruc.c | 4 ++-- drivers/infiniband/hw/qib/qib_uc.c | 2 +- drivers/infiniband/hw/qib/qib_ud.c | 10 +++++----- drivers/infiniband/hw/qib/qib_verbs.h | 6 +++--- drivers/staging/rdma/hfi1/ruc.c | 20 +++++++++++--------- drivers/staging/rdma/hfi1/ud.c | 8 ++++---- drivers/staging/rdma/hfi1/verbs.h | 1 + 8 files changed, 28 insertions(+), 25 deletions(-) commit f39cc34df7ed919c5c7630a8a7a701939356c37c Author: Mike Marciniszyn <mike.marciniszyn@intel.com> Date: Tue Apr 12 10:45:51 2016 -0700 IB/rdmavt: Fix adaptive pio hang The RVT_S_WAIT_PIO_DRAIN flag was missing from the set of flags indicating a qp is waiting on a resource. This caused the sleep/wakeup for adaptive pio drain to lose a wakeup "hanging" a QP. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com> include/rdma/rdmavt_qp.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 51c454d2610571404917fa027c73048599dc6c3d Author: Jianqun Xu <jay.xu@rock-chips.com> Date: Wed Apr 27 15:54:52 2016 +0800 dt-bindings: document rockchip rk3399-evb board Use "rockchip,rk3399-evb" compatible string for Rockchip RK3399 evaluation board. Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Documentation/devicetree/bindings/arm/rockchip.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit cc7364fbda0fc1c6c8a36f0890edd3a2a5764248 Author: Jianqun Xu <jay.xu@rock-chips.com> Date: Wed Apr 27 15:54:53 2016 +0800 arm64: dts: rockchip: add dts file for RK3399 evaluation board This patch add rk3399-evb.dts for RK3399 evaluation board. Tested on RK3399 evb. Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/Makefile | 1 + arch/arm64/boot/dts/rockchip/rk3399-evb.dts | 124 ++++++++++++++++++++++++++++ 2 files changed, 125 insertions(+) commit f048b9a4d4fb02f6708ce9b3a2b32cb7a2f11da0 Author: Jianqun Xu <jay.xu@rock-chips.com> Date: Wed Apr 27 15:54:51 2016 +0800 arm64: dts: rockchip: add core dtsi file for RK3399 SoCs This patch adds core dtsi file for Rockchip RK3399 SoCs. The RK3399 has big/little architecture, which needs a separate node for the PMU of each microarchitecture, for now it missing the pmu node since the old one could not work well. Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Tested-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3399.dtsi | 1013 ++++++++++++++++++++++++++++++ 1 file changed, 1013 insertions(+) commit f345c9a5726d10cc3613d17ae75dcb1ab0986ba1 Merge: 2a9e843 a166140 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 28 16:14:20 2016 -0400 Merge branch 'tcp-eor' Martin KaFai Lau says: ==================== tcp: Make use of MSG_EOR in tcp_sendmsg v4: ~ Do not set eor bit in do_tcp_sendpages() since there is no way to pass MSG_EOR from the userland now. ~ Avoid rmw by testing MSG_EOR first in tcp_sendmsg(). ~ Move TCP_SKB_CB(skb)->eor test to a new helper tcp_skb_can_collapse_to() (suggested by Soheil). ~ Add some packetdrill tests. v3: ~ Separate EOR marking from the SKBTX_ANY_TSTAMP logic. ~ Move the eor bit test back to the loop in tcp_sendmsg and tcp_sendpage because there could be >1 threads doing sendmsg. ~ Thanks to Eric Dumazet's suggestions on v2. ~ The TCP timestamp bug fixes are separated into other threads. v2: ~ Rework based on the recent work "add TX timestamping via cmsg" by Soheil Hassas Yeganeh <soheil.kdev@gmail.com> ~ This version takes the MSG_EOR bit as a signal of end-of-response-message and leave the selective timestamping job to the cmsg ~ Changes based on the v1 feedback (like avoid unlikely check in a loop and adding tcp_sendpage support) ~ The first 3 patches are bug fixes. The fixes in this series depend on the newly introduced txstamp_ack in net-next. I will make relevant patches against net after getting some feedback. ~ The test results are based on the recently posted net fix: "tcp: Fix SOF_TIMESTAMPING_TX_ACK when handling dup acks" One potential use case is to use MSG_EOR with SOF_TIMESTAMPING_TX_ACK to get a more accurate TCP ack timestamping on application protocol with multiple outgoing response messages (e.g. HTTP2). One of our use case is at the webserver. The webserver tracks the HTTP2 response latency by measuring when the webserver sends the first byte to the socket till the TCP ACK of the last byte is received. In the cases where we don't have client side measurement, measuring from the server side is the only option. In the cases we have the client side measurement, the server side data can also be used to justify/cross-check-with the client side data. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a166140e810e74682f3ca248ef3879177b5c1315 Author: Martin KaFai Lau <kafai@fb.com> Date: Mon Apr 25 14:44:50 2016 -0700 tcp: Handle eor bit when fragmenting a skb When fragmenting a skb, the next_skb should carry the eor from prev_skb. The eor of prev_skb should also be reset. Packetdrill script for testing: ~~~~~~ +0 `sysctl -q -w net.ipv4.tcp_min_tso_segs=10` +0 `sysctl -q -w net.ipv4.tcp_no_metrics_save=1` +0 socket(..., SOCK_STREAM, IPPROTO_TCP) = 3 +0 setsockopt(3, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0 +0 bind(3, ..., ...) = 0 +0 listen(3, 1) = 0 0.100 < S 0:0(0) win 32792 <mss 1460,sackOK,nop,nop,nop,wscale 7> 0.100 > S. 0:0(0) ack 1 <mss 1460,nop,nop,sackOK,nop,wscale 7> 0.200 < . 1:1(0) ack 1 win 257 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 0.200 sendto(4, ..., 15330, MSG_EOR, ..., ...) = 15330 0.200 sendto(4, ..., 730, 0, ..., ...) = 730 0.200 > . 1:7301(7300) ack 1 0.200 > . 7301:14601(7300) ack 1 0.300 < . 1:1(0) ack 14601 win 257 0.300 > P. 14601:15331(730) ack 1 0.300 > P. 15331:16061(730) ack 1 0.400 < . 1:1(0) ack 16061 win 257 0.400 close(4) = 0 0.400 > F. 16061:16061(0) ack 1 0.400 < F. 1:1(0) ack 16062 win 257 0.400 > . 16062:16062(0) ack 2 Signed-off-by: Martin KaFai Lau <kafai@fb.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Yuchung Cheng <ycheng@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_output.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit a643b5d41c95164c14b111d19c05d6913bedb80b Author: Martin KaFai Lau <kafai@fb.com> Date: Mon Apr 25 14:44:49 2016 -0700 tcp: Handle eor bit when coalescing skb This patch: 1. Prevent next_skb from coalescing to the prev_skb if TCP_SKB_CB(prev_skb)->eor is set 2. Update the TCP_SKB_CB(prev_skb)->eor if coalescing is allowed Packetdrill script for testing: ~~~~~~ +0 `sysctl -q -w net.ipv4.tcp_min_tso_segs=10` +0 `sysctl -q -w net.ipv4.tcp_no_metrics_save=1` +0 socket(..., SOCK_STREAM, IPPROTO_TCP) = 3 +0 setsockopt(3, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0 +0 bind(3, ..., ...) = 0 +0 listen(3, 1) = 0 0.100 < S 0:0(0) win 32792 <mss 1460,sackOK,nop,nop,nop,wscale 7> 0.100 > S. 0:0(0) ack 1 <mss 1460,nop,nop,sackOK,nop,wscale 7> 0.200 < . 1:1(0) ack 1 win 257 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 0.200 sendto(4, ..., 730, MSG_EOR, ..., ...) = 730 0.200 sendto(4, ..., 730, MSG_EOR, ..., ...) = 730 0.200 write(4, ..., 11680) = 11680 0.200 > P. 1:731(730) ack 1 0.200 > P. 731:1461(730) ack 1 0.200 > . 1461:8761(7300) ack 1 0.200 > P. 8761:13141(4380) ack 1 0.300 < . 1:1(0) ack 1 win 257 <sack 1461:13141,nop,nop> 0.300 > P. 1:731(730) ack 1 0.300 > P. 731:1461(730) ack 1 0.400 < . 1:1(0) ack 13141 win 257 0.400 close(4) = 0 0.400 > F. 13141:13141(0) ack 1 0.500 < F. 1:1(0) ack 13142 win 257 0.500 > . 13142:13142(0) ack 2 Signed-off-by: Martin KaFai Lau <kafai@fb.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Yuchung Cheng <ycheng@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_input.c | 4 ++++ net/ipv4/tcp_output.c | 4 ++++ 2 files changed, 8 insertions(+) commit c134ecb87817ce70fd62b2dc48bb079c44fc08df Author: Martin KaFai Lau <kafai@fb.com> Date: Mon Apr 25 14:44:48 2016 -0700 tcp: Make use of MSG_EOR in tcp_sendmsg This patch adds an eor bit to the TCP_SKB_CB. When MSG_EOR is passed to tcp_sendmsg, the eor bit will be set at the skb containing the last byte of the userland's msg. The eor bit will prevent data from appending to that skb in the future. The change in do_tcp_sendpages is to honor the eor set during the previous tcp_sendmsg(MSG_EOR) call. This patch handles the tcp_sendmsg case. The followup patches will handle other skb coalescing and fragment cases. One potential use case is to use MSG_EOR with SOF_TIMESTAMPING_TX_ACK to get a more accurate TCP ack timestamping on application protocol with multiple outgoing response messages (e.g. HTTP2). Packetdrill script for testing: ~~~~~~ +0 `sysctl -q -w net.ipv4.tcp_min_tso_segs=10` +0 `sysctl -q -w net.ipv4.tcp_no_metrics_save=1` +0 socket(..., SOCK_STREAM, IPPROTO_TCP) = 3 +0 setsockopt(3, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0 +0 bind(3, ..., ...) = 0 +0 listen(3, 1) = 0 0.100 < S 0:0(0) win 32792 <mss 1460,sackOK,nop,nop,nop,wscale 7> 0.100 > S. 0:0(0) ack 1 <mss 1460,nop,nop,sackOK,nop,wscale 7> 0.200 < . 1:1(0) ack 1 win 257 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 0.200 write(4, ..., 14600) = 14600 0.200 sendto(4, ..., 730, MSG_EOR, ..., ...) = 730 0.200 sendto(4, ..., 730, MSG_EOR, ..., ...) = 730 0.200 > . 1:7301(7300) ack 1 0.200 > P. 7301:14601(7300) ack 1 0.300 < . 1:1(0) ack 14601 win 257 0.300 > P. 14601:15331(730) ack 1 0.300 > P. 15331:16061(730) ack 1 0.400 < . 1:1(0) ack 16061 win 257 0.400 close(4) = 0 0.400 > F. 16061:16061(0) ack 1 0.400 < F. 1:1(0) ack 16062 win 257 0.400 > . 16062:16062(0) ack 2 Signed-off-by: Martin KaFai Lau <kafai@fb.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Yuchung Cheng <ycheng@google.com> Suggested-by: Eric Dumazet <edumazet@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 8 +++++++- net/ipv4/tcp.c | 7 +++++-- 2 files changed, 12 insertions(+), 3 deletions(-) commit 2a9e8438a29c00432ae14eaceb088b965f8ac290 Merge: ba7863f 0a2cf20 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 28 16:06:11 2016 -0400 Merge branch 'tcp-redundant-checks' Soheil Hassas Yeganeh says: ==================== tcp: simplify ack tx timestamps v2: - Fully remove SKBTX_ACK_TSTAMP, as suggested by Willem de Bruijn. This patch series aims at removing redundant checks and fields for ack timestamps for TCP. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0a2cf20c3fb62ad4717276b5303bf831f7b29d54 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Wed Apr 27 23:39:01 2016 -0400 tcp: remove SKBTX_ACK_TSTAMP since it is redundant The SKBTX_ACK_TSTAMP flag is set in skb_shinfo->tx_flags when the timestamp of the TCP acknowledgement should be reported on error queue. Since accessing skb_shinfo is likely to incur a cache-line miss at the time of receiving the ack, the txstamp_ack bit was added in tcp_skb_cb, which is set iff the SKBTX_ACK_TSTAMP flag is set for an skb. This makes SKBTX_ACK_TSTAMP flag redundant. Remove the SKBTX_ACK_TSTAMP and instead use the txstamp_ack bit everywhere. Note that this frees one bit in shinfo->tx_flags. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Martin KaFai Lau <kafai@fb.com> Suggested-by: Willem de Bruijn <willemb@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/skbuff.h | 6 +----- net/ipv4/tcp.c | 5 +++-- net/ipv4/tcp_input.c | 3 +-- net/ipv4/tcp_output.c | 17 +++++++++++------ net/socket.c | 3 --- 5 files changed, 16 insertions(+), 18 deletions(-) commit 863c1fd9814618eefba02218f8fadf8a430c2a17 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Wed Apr 27 23:39:00 2016 -0400 tcp: remove an unnecessary check in tcp_tx_timestamp Remove the redundant check for sk->sk_tsflags in tcp_tx_timestamp. tcp_tx_timestamp() receives the tsflags as a parameter. As a result the "sk->sk_tsflags || tsflags" is redundant, since tsflags already includes sk->sk_tsflags plus overrides from control messages. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc5878abf49c06b9c1d3d161760957a98ab970bf Author: Peter Chen <peter.chen@nxp.com> Date: Mon Apr 25 09:57:18 2016 +0800 usb: core: move root hub's device node assignment after it is added to bus When the root hub device is added to the bus, it tries to get pins information from pinctrl (see pinctrl_bind_pins, at really_probe), if the pin information is described at DT, it will show below error since the root hub's device node is the same with controller's, but controller's pin has already been requested when it is added to platform bus. imx6q-pinctrl 20e0000.iomuxc: pin MX6Q_PAD_GPIO_1 already requested by 2184000.usb; cannot claim for usb1 imx6q-pinctrl 20e0000.iomuxc: pin-137 (usb1) status -22 imx6q-pinctrl 20e0000.iomuxc: could not request pin 137 (MX6Q_PAD_GPIO_1) from group usbotggrp-3 on device 20e0000.iomuxc usb usb1: Error applying setting, reverse things back To fix this issue, we move the root hub's device node assignment (equals to contrller's) after device is added to bus, we only need to know root hub's device node information after the device under root hub is created, so this movement will not affect current function. Signed-off-by: Peter Chen <peter.chen@nxp.com> Reported-by: Lars Steubesand <lars.steubesand@philips.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/hcd.c | 1 + drivers/usb/core/usb.c | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) commit 49e8eccf370d9fd916f6fc21b44ae8d3361e2c9f Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Apr 24 09:25:40 2016 +0530 Use "foo *bar" instead of "foo * bar". Use "foo *bar" instead of "foo * bar". Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/atm/ueagle-atm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 62b5c80afc4ee008e3d4aae0024197437278f753 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Apr 24 12:00:40 2016 +0530 usb: Remove unnecessary space before function pointer arguments. Remove unnecessary space before function pointer arguments. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/atm/ueagle-atm.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit feb26ac31a2a5cb88d86680d9a94916a6343e9e6 Author: Chris Bainbridge <chris.bainbridge@gmail.com> Date: Mon Apr 25 13:48:38 2016 +0100 usb: core: hub: hub_port_init lock controller instead of bus The XHCI controller presents two USB buses to the system - one for USB2 and one for USB3. The hub init code (hub_port_init) is reentrant but only locks one bus per thread, leading to a race condition failure when two threads attempt to simultaneously initialise a USB2 and USB3 device: [ 8.034843] xhci_hcd 0000:00:14.0: Timeout while waiting for setup device command [ 13.183701] usb 3-3: device descriptor read/all, error -110 On a test system this failure occurred on 6% of all boots. The call traces at the point of failure are: Call Trace: [<ffffffff81b9bab7>] schedule+0x37/0x90 [<ffffffff817da7cd>] usb_kill_urb+0x8d/0xd0 [<ffffffff8111e5e0>] ? wake_up_atomic_t+0x30/0x30 [<ffffffff817dafbe>] usb_start_wait_urb+0xbe/0x150 [<ffffffff817db10c>] usb_control_msg+0xbc/0xf0 [<ffffffff817d07de>] hub_port_init+0x51e/0xb70 [<ffffffff817d4697>] hub_event+0x817/0x1570 [<ffffffff810f3e6f>] process_one_work+0x1ff/0x620 [<ffffffff810f3dcf>] ? process_one_work+0x15f/0x620 [<ffffffff810f4684>] worker_thread+0x64/0x4b0 [<ffffffff810f4620>] ? rescuer_thread+0x390/0x390 [<ffffffff810fa7f5>] kthread+0x105/0x120 [<ffffffff810fa6f0>] ? kthread_create_on_node+0x200/0x200 [<ffffffff81ba183f>] ret_from_fork+0x3f/0x70 [<ffffffff810fa6f0>] ? kthread_create_on_node+0x200/0x200 Call Trace: [<ffffffff817fd36d>] xhci_setup_device+0x53d/0xa40 [<ffffffff817fd87e>] xhci_address_device+0xe/0x10 [<ffffffff817d047f>] hub_port_init+0x1bf/0xb70 [<ffffffff811247ed>] ? trace_hardirqs_on+0xd/0x10 [<ffffffff817d4697>] hub_event+0x817/0x1570 [<ffffffff810f3e6f>] process_one_work+0x1ff/0x620 [<ffffffff810f3dcf>] ? process_one_work+0x15f/0x620 [<ffffffff810f4684>] worker_thread+0x64/0x4b0 [<ffffffff810f4620>] ? rescuer_thread+0x390/0x390 [<ffffffff810fa7f5>] kthread+0x105/0x120 [<ffffffff810fa6f0>] ? kthread_create_on_node+0x200/0x200 [<ffffffff81ba183f>] ret_from_fork+0x3f/0x70 [<ffffffff810fa6f0>] ? kthread_create_on_node+0x200/0x200 Which results from the two call chains: hub_port_init usb_get_device_descriptor usb_get_descriptor usb_control_msg usb_internal_control_msg usb_start_wait_urb usb_submit_urb / wait_for_completion_timeout / usb_kill_urb hub_port_init hub_set_address xhci_address_device xhci_setup_device Mathias Nyman explains the current behaviour violates the XHCI spec: hub_port_reset() will end up moving the corresponding xhci device slot to default state. As hub_port_reset() is called several times in hub_port_init() it sounds reasonable that we could end up with two threads having their xhci device slots in default state at the same time, which according to xhci 4.5.3 specs still is a big no no: "Note: Software shall not transition more than one Device Slot to the Default State at a time" So both threads fail at their next task after this. One fails to read the descriptor, and the other fails addressing the device. Fix this in hub_port_init by locking the USB controller (instead of an individual bus) to prevent simultaneous initialisation of both buses. Fixes: 638139eb95d2 ("usb: hub: allow to process more usb hub events in parallel") Link: https://lkml.org/lkml/2016/2/8/312 Link: https://lkml.org/lkml/2016/2/4/748 Signed-off-by: Chris Bainbridge <chris.bainbridge@gmail.com> Cc: stable <stable@vger.kernel.org> Acked-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/hcd.c | 15 +++++++++++++-- drivers/usb/core/hub.c | 8 ++++---- include/linux/usb.h | 3 +-- include/linux/usb/hcd.h | 1 + 4 files changed, 19 insertions(+), 8 deletions(-) commit edc8c54bf454e6ba4f4631db1603f2297e4d4b67 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Wed Apr 27 13:28:32 2016 -0400 usb/host/: const data must use __initconst not __initdata Init data marked const should be annotated with __initconst for correctness and not __initdata. This also fixes LTO builds that otherwise fail with section mismatch errors. Signed-off-by: Nicolas Pitre <nico@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/ehci-exynos.c | 2 +- drivers/usb/host/ehci-msm.c | 2 +- drivers/usb/host/ehci-omap.c | 2 +- drivers/usb/host/ehci-spear.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 10871c13608a624562e082196148f1dc4e37005e Author: Michele Curti <michele.curti@gmail.com> Date: Wed Apr 27 21:23:07 2016 +0200 usb: devio: declare usbdev_vm_ops as static usbdev_vm_ops is used in devio.c only, so declare it as static Signed-off-by: Michele Curti <michele.curti@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/devio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 26186e5f2c1a6d1c244a3052f02e46ae29d823f2 Author: Chunfeng Yun <chunfeng.yun@mediatek.com> Date: Thu Apr 28 11:42:21 2016 +0800 usb: misc: usbtest: fix error of urb allocation urb allocation will fail when usbtest_alloc_urb() tries to allocate zero length buffer, but it doesn't need it in fact, so just skips buffer allocation in the case. Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/misc/usbtest.c | 3 +++ 1 file changed, 3 insertions(+) commit f5e6253fe6de35fc2fa059974dbd9d61f32e4cd0 Author: Chunfeng Yun <chunfeng.yun@mediatek.com> Date: Thu Apr 28 11:42:20 2016 +0800 usb: core: buffer: avoid NULL pointer dereferrence NULL pointer dereferrence will happen when class driver wants to allocate zero length buffer and pool_max[0] can't be used, so simply returns NULL in the case. Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/buffer.c | 3 +++ 1 file changed, 3 insertions(+) commit b5a2a8ecb204c821f47b43ab7e93f408b0d085b1 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 14:42:50 2016 +0200 usbip: vudc: fix Kconfig dependencies With the addition of VUDC, the USBIP stack can now be used on configurations without USB host support, but trying to build it with USB gadget support disabled fails with drivers/usb/built-in.o: In function `vep_dequeue': vudc_main.c:(.text+0xa6ddc): undefined reference to `usb_gadget_giveback_request' drivers/usb/built-in.o: In function `nuke': vudc_main.c:(.text+0xa6ea8): undefined reference to `usb_gadget_giveback_request' drivers/usb/built-in.o: In function `vudc_device_reset': vudc_main.c:(.text+0xa720c): undefined reference to `usb_gadget_udc_reset' drivers/usb/built-in.o: In function `vudc_probe': This addresses both issues, by changing the dependency for USBIP_CORE to USB_COMMON, and adding additional dependencies on USB or USB_GADGET for the individual portions as needed. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 9360575c5837 ("usbip: vudc: Add vudc to Kconfig") Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/Kconfig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 6dc38da4a53837835e2c3d9fec5d793ea9374a94 Author: Nobuo Iwata <nobuo.iwata@fujixerox.co.jp> Date: Wed Apr 27 15:35:53 2016 +0900 usbip: safe completion against unbind operation This patch adds a code fragment to ignore completing URBs in closing connection. Regarding this patch, 2 execution contexts are related. 1) stub_tx.c: stub_complete() which is called from USB core 1-1) add to unlink list and free URB or 1-2) move to tx list 2) stub_dev.c: stub_shutdown_connection() which is invoked by unbind operation through sysfs. 2-1) stop TX/RX threads 2-2) close TCP connection and set ud.tcp_socket to NULL 2-3) cleanup pending URBs by stub_device_cleanup_urbs(sdev) 2-4) free unlink list (no lock) In the race condition, URBs which will be cleared in 2-3) may be handled in 1). In case 1-1), it will not be transferred bcause tx threads are stooped in 2-1). In case 1-2), may be freed in 2-4). With this patch, after 2-2), completing URBs in 1) will not be handled and cleared in 2-3). The kernel log with this patch is as below. kernel: usbip_core: usbip_kernel_unlink:792: shutting down tcp_socket ef61d980 kernel: usbip-host 1-3: free sdev f5df6180 kernel: usbip-host 1-3: free urb f5df6700 kernel: usbip-host 1-3: Enter kernel: usbip_core: usbip_stop_eh:132: usbip_eh waiting completion 5 kernel: usbip_host: stub_complete:71: complete! status 0 kernel: usbip_host: stub_complete:102: ignore urb for closed connection e725fc00 (*) kernel: usbip_host: stub_complete:71: complete! status -2 kernel: usbip-host 1-3: stopped by a call to usb_kill_urb() because of cleaning up a virtual connection kernel: usbip-host 1-3: free urb e725fc00 (**) kernel: usbip-host 1-3: free urb e725e000 kernel: usbip_host: stub_complete:71: complete! status -2 kernel: usbip-host 1-3: stopped by a call to usb_kill_urb() because of cleaning up a virtual connection kernel: usbip-host 1-3: free urb e725f800 kernel: usbip_host: stub_complete:71: complete! status -2 kernel: usbip-host 1-3: stopped by a call to usb_kill_urb() because of cleaning up a virtual connection kernel: usbip-host 1-3: free urb e725e800 kernel: usbip_host: stub_complete:71: complete! status -2 kernel: usbip-host 1-3: stopped by a call to usb_kill_urb() because of cleaning up a virtual connection kernel: usbip-host 1-3: device reset kernel: usbip-host 1-3: lock for reset kernel: usbip_host: store_match_busid:178: del busid 1-3 kernel: uvcvideo: Found UVC 1.00 device Venus USB2.0 Camera (056e:700a) kernel: input: Venus USB2.0 Camera as /devices/pci0000:00/0000:00:1a.7/usb1/1-3/1-3:1.0/input/input22 (*) skipped with this patch in completion (**) released in 2-3 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/stub_tx.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 0255cf9e52a73ba0d5ca393c93c5fb458fea4532 Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Wed Apr 27 20:02:07 2016 +0200 usb: usbip: vudc: Rename find_endpoint() to vudc_find_endpoint() As find_endpoint() is a global funcion rename it to vudc_find_endpoint() to clearly mark where does it come from. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc.h | 2 +- drivers/usb/usbip/vudc_dev.c | 2 +- drivers/usb/usbip/vudc_rx.c | 2 +- drivers/usb/usbip/vudc_transfer.c | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) commit 8c7003a3b4b4afd3734cdcc39217ef22d78a4a16 Author: Alexander Popov <alpopov@ptsecurity.com> Date: Thu Apr 28 13:07:22 2016 +0300 usbip: fix NULL pointer dereference on errors Fix NULL pointer dereference and obsolete comments forgotten when usbip server was converted from an interface driver to a device driver. Signed-off-by: Alexander Popov <alpopov@ptsecurity.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/stub.h | 1 - drivers/usb/usbip/stub_dev.c | 4 ++-- drivers/usb/usbip/stub_rx.c | 19 +++++++------------ drivers/usb/usbip/stub_tx.c | 6 +++--- 4 files changed, 12 insertions(+), 18 deletions(-) commit 2bdf6ea51ce8dcd98f4f394d7203dbace01f5cbc Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Wed Apr 27 20:00:26 2016 +0200 usb: usbip: vudc: Fix WARN_ON() usage pattern Fix WARN_ON() macro usage as suggested by Felipe. Instead of using: if (cond) { WARN_ON(1); do_stuff(); } Use a better pattern with WARN_ON() placed in if condition: if (WARN_ON(cond)) do_stuff(); Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_dev.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit f945c546656e4330665a69aa35ae6491025128fc Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Wed Apr 27 19:59:21 2016 +0200 Documentation: ABI: Add doc for usbip-vudc attributes As vudc provides some new attributes using sysfs infrastructure, add a suitable documentation file for those attributes. Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../ABI/testing/sysfs-platform-usbip-vudc | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit e29bff46b9b8663e1789fbcd65d0ba05a52f08af Merge: d53e181 e6bd18f Author: Doug Ledford <dledford@redhat.com> Date: Thu Apr 28 15:16:32 2016 -0400 Merge branch 'k.o/for-4.6-rc' into testing/4.6 commit d53e181c85effdfdec97a760622330626c922d81 Merge: d29c9ab b75a2bf Author: Doug Ledford <dledford@redhat.com> Date: Thu Apr 28 15:16:21 2016 -0400 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux into testing/4.6 commit 6f26b3671184c36d07eb5d61ba9a6d0aeb583c5d Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:48 2016 +0200 arm64: kaslr: increase randomization granularity Currently, our KASLR implementation randomizes the placement of the core kernel at 2 MB granularity. This is based on the arm64 kernel boot protocol, which mandates that the kernel is loaded TEXT_OFFSET bytes above a 2 MB aligned base address. This requirement is a result of the fact that the block size used by the early mapping code may be 2 MB at the most (for a 4 KB granule kernel) But we can do better than that: since a KASLR kernel needs to be relocated in any case, we can tolerate a physical misalignment as long as the virtual misalignment relative to this 2 MB block size is equal in size, and code to deal with this is already in place. Since we align the kernel segments to 64 KB, let's randomize the physical offset at 64 KB granularity as well (unless CONFIG_DEBUG_ALIGN_RODATA is enabled). This way, the page table and TLB footprint is not affected. The higher granularity allows for 5 bits of additional entropy to be used. Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/firmware/efi/libstub/arm64-stub.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 99a507771fa57238dc7ffe674ae06090333d02c9 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Wed Apr 27 13:55:28 2016 -0300 arm64: kconfig: drop CONFIG_RTC_LIB dependency The rtc-lib dependency is not required, and seems it was just copy-pasted from ARM's Kconfig. If platform requires rtc-lib, they should select it individually. Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 1 - 1 file changed, 1 deletion(-) commit da24eb1f3f9e2c7b75c5f8c40d8e48e2c4789596 Author: Will Deacon <will.deacon@arm.com> Date: Thu Apr 28 19:38:16 2016 +0100 arm64: make ARCH_SUPPORTS_DEBUG_PAGEALLOC depend on !HIBERNATION Selecting both DEBUG_PAGEALLOC and HIBERNATION results in a build failure: | kernel/built-in.o: In function `saveable_page': | memremap.c:(.text+0x100f90): undefined reference to `kernel_page_present' | kernel/built-in.o: In function `swsusp_save': | memremap.c:(.text+0x1026f0): undefined reference to `kernel_page_present' | make: *** [vmlinux] Error 1 James sayeth: "This is caused by DEBUG_PAGEALLOC, which clears the PTE_VALID bit from 'free' pages. Hibernate uses it as a hint that it shouldn't save/access that page. This function is used to test whether the PTE_VALID bit has been cleared by kernel_map_pages(), hibernate is the only user. Fixing this exposes a bigger problem with that configuration though: if the resume kernel has cut free pages out of the linear map, we copy this swiss-cheese view of memory, and try to use it to restore... We can fixup the copy of the linear map, but it then explodes in my lazy 'clean the whole kernel to PoC' after resume, as now both the kernel and linear map have holes in them." On closer inspection, the whole Kconfig machinery around DEBUG_PAGEALLOC, HIBERNATION, ARCH_SUPPORTS_DEBUG_PAGEALLOC and PAGE_POISONING looks like it might need some affection. In particular, DEBUG_ALLOC has: > depends on !HIBERNATION || ARCH_SUPPORTS_DEBUG_PAGEALLOC && !PPC && !SPARC which looks pretty fishy. For the moment, require ARCH_SUPPORTS_DEBUG_PAGEALLOC to depend on !HIBERNATION on arm64 and get allmodconfig building again. Signed-off-by: James Morse <james.morse@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 1 + 1 file changed, 1 insertion(+) commit ca7ce82a280a65c377c24c95c29b1dec6e80b428 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Thu Apr 28 22:16:57 2016 +0530 perf tests: Do not use sizeof on pointer type Using sizeof on a malloced pointer type will return the wordsize which can often cause one to allocate a buffer much smaller than it is needed. So, here do not use sizeof on pointer type. Note that this has no effect on runtime because 'dsos' is a pointer to a pointer. Problem found using Coccinelle. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461862017-23358-1-git-send-email-vaishali.thakkar@oracle.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/dso-data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ea5a137d0fe263854ae6267a0fa208c544d83452 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:36 2016 +0530 ASoC: Intel: Skylake: Update channel map based on runtime params Default channel map is set for 2 channels. Fix the channel map based on runtime params to support multichannel. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-topology.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) commit 7e12dc87ac59963cf1765fb8272412db19004987 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:35 2016 +0530 ASoC: Intel: Skylake: Add multichannel support for HDMI Channel max is changed to 8 from stereo to support multichannel capability for HDMI devices. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-pcm.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 2889099eb8cd0811dc2986643d46c0b62b90eeb4 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:34 2016 +0530 ASoC: hdac_hdmi: Register chmap controls and ops With this patch, chmap controls are created and user space can set the channel map. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 100 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) commit 46ed1a27fb44febb2c362fc30fcb51e8eed06e3a Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:33 2016 +0530 ASoC: Intel: boards: Update skl_nau88l25_ssm4567 driver to support chmap HDMI registers channel map controls per PCM. As PCMs are not registered during dai_link init callback, store the pcm ids and codec DAIs during this init callback. Register for late probe and call the jack_init API which also registers channel map in the late probe callback handler. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/boards/skl_nau88l25_ssm4567.c | 73 +++++++++++++++++++++++++-- 1 file changed, 70 insertions(+), 3 deletions(-) commit 0d425b4f900e4dc65bd186387dae32dbbb186e77 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:32 2016 +0530 ASoC: Intel: boards: Update skl_nau88l25_max98357a driver to support chmap HDMI registers channel map controls per PCM. As PCMs are not registered during dai_link init callback, store the pcm ids and codec DAIs during this init callback. Register for late probe and call the jack_init API which also registers channel map in the late probe callback handler. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/boards/skl_nau88l25_max98357a.c | 74 ++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 3 deletions(-) commit 1a10612fc3f5eb5cfa89af3f6b8181d69f79a371 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:31 2016 +0530 ASoC: skl_rt286: Fix to support hdmi channel map support HDMI registers channel map controls per PCM. As PCMs are not registered during dai_link init callback, store the pcm ids and codec DAIs during this init callback. Register for late probe and call the jack_init API which also registers channel map in the late probe callback handler. The patch following the machine driver changes adds the channel map control in the hdac_hdmi codec driver. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/boards/skl_rt286.c | 48 +++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) commit bcced704788312360c0413d13b11611ae00a91c8 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:30 2016 +0530 ASoC: hdac_hdmi: Add multichannel support To support multichannel hdac hdmi driver registers with HDA channel map framework. Channel count and channel slot verbs are programmed by using the chmap helpers/ops. The channel allocation is then programmed in the audio infoframe as per CEA spec. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 50 ++++++++++++++++++++++++++++++++++++-------- 1 file changed, 41 insertions(+), 9 deletions(-) commit b7756edeb7d03b675e10b4862dccc8deb4b0ca17 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:28 2016 +0530 ASoC: hdac_hdmi: parse eld for channel map capability This patch parses ELD speaker allocation data block to find sink's chmap capability. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdac_hdmi.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 6a5ea5c5d1d35e9b81fca88535cd584d9332961d Merge: db71336 9fc7c86 Author: Mark Brown <broonie@kernel.org> Date: Thu Apr 28 18:49:06 2016 +0100 Merge branch 'topic/hda' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-hdmi commit 9fc7c862e78ba8bec142935673227f2463aa05a5 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Thu Apr 14 10:07:29 2016 +0530 ALSA: hda - add helper to get channels from cap bits This helper is copied from legacy hda driver. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Acked-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Mark Brown <broonie@kernel.org> sound/hda/local.h | 10 ++++++++++ 1 file changed, 10 insertions(+) commit ca2cd6bc6663314ba7fbf66ba7b14e099671420e Author: anish kumar <yesanishhere@gmail.com> Date: Wed Apr 27 15:39:05 2016 -0700 ASoC: Add max98371 codec driver Signed-off-by: anish kumar <yesanishhere@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/max98371.txt | 17 + sound/soc/codecs/Kconfig | 4 + sound/soc/codecs/Makefile | 1 + sound/soc/codecs/max98371.c | 442 +++++++++++++++++++++ sound/soc/codecs/max98371.h | 67 ++++ 5 files changed, 531 insertions(+) commit 5ed4aba1265f3c7532bf4ae1f25a277568b86871 Author: Alexey Kardashevskiy <aik@ozlabs.ru> Date: Fri Apr 8 14:54:41 2016 +1000 vfio_iommu_spapr_tce: Remove unneeded iommu_group_get_iommudata This removes iommu_group_get_iommudata() as the result is never used. As this is a minor cleanup, no change in behavior is expected. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/vfio_iommu_spapr_tce.c | 2 -- 1 file changed, 2 deletions(-) commit dc928109973336fd4d572d460cf3964d56aa087f Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 24 13:06:16 2016 -0600 vfio/pci: Add test for BAR restore If a device is reset without the memory or i/o bits enabled in the command register we may not detect it, potentially leaving the device without valid BAR programming. Add an additional test to check the BARs on each write to the command register. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> drivers/vfio/pci/vfio_pci_config.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit 450744051d201c4d72436ebf5b04b9a06ba2cf30 Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 24 13:05:18 2016 -0600 vfio/pci: Hide broken INTx support from user INTx masking has two components, the first is that we need the ability to prevent the device from continuing to assert INTx. This is provided via the DisINTx bit in the command register and is the only thing we can really probe for when testing if INTx masking is supported. The second component is that the device needs to indicate if INTx is asserted via the interrupt status bit in the device status register. With these two features we can generically determine if one of the devices we own is asserting INTx, signal the user, and mask the interrupt while the user services the device. Generally if one or both of these components is broken we resort to APIC level interrupt masking, which requires an exclusive interrupt since we have no way to determine the source of the interrupt in a shared configuration. This often makes it difficult or impossible to configure the system for userspace use of the device, for an interrupt mode that the user may not need. One possible configuration of broken INTx masking is that the DisINTx support is fully functional, but the interrupt status bit never signals interrupt assertion. In this case we do have the ability to prevent the device from asserting INTx, but lack the ability to identify the interrupt source. For this case we can simply pretend that the device lacks INTx support entirely, keeping DisINTx set on the physical device, virtualizing this bit for the user, and virtualizing the interrupt pin register to indicate no INTx support. We already support virtualization of the DisINTx bit and already virtualize the interrupt pin for platforms without INTx support. By tying these components together, setting DisINTx on open and reset, and identifying devices broken in this particular way, we can provide support for them w/o the handicap of APIC level INTx masking. Intel i40e (XL710/X710) 10/20/40GbE NICs have been identified as being broken in this specific way. We leave the vfio-pci.nointxmask option as a mechanism to bypass this support, enabling INTx on the device with all the requirements of APIC level masking. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Cc: John Ronciak <john.ronciak@intel.com> Cc: Jesse Brandeburg <jesse.brandeburg@intel.com> drivers/vfio/pci/vfio_pci.c | 55 ++++++++++++++++++++++++++++++------- drivers/vfio/pci/vfio_pci_config.c | 9 +++++- drivers/vfio/pci/vfio_pci_private.h | 1 + 3 files changed, 54 insertions(+), 11 deletions(-) commit 036dae83b9e0ec355a5b9341dec06214bff5b472 Merge: a183d7f 8ac2266 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 18:40:05 2016 +0200 Merge tag 'samsung-drivers-exynos-srom-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/drivers Merge "Samsung soc/drivers update for v4.7" from Krzysztof Kozłowski: This moves Samsung SROM controller code from arm/mach-exynos into to separate driver under drivers/memory/samsung. In the future this driver will be re-used on ARM64 Exynos platform. * tag 'samsung-drivers-exynos-srom-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: memory: samsung: exynos-srom: Add support for bank configuration ARM: EXYNOS: Remove SROM related register settings from mach-exynos MAINTAINERS: Add maintainers entry for drivers/memory/samsung memory: Add support for Exynos SROM driver dt-bindings: EXYNOS: Add exynos-srom device tree binding ARM: dts: change SROM node compatible from generic to model specific commit ce15bda101211dd0d42d6745f3998f87096b6f7c Merge: 328fafb 2a58f9c Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Thu Apr 28 09:32:39 2016 -0700 Merge tag 'usb-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next Felipe writes: usb: changes for v4.7 merge window Here's the big USB Gadget pull request. This time not as large as usual with only 57 non-merge commits. The most important part here is, again, all the work on dwc3. This time around we're treating all endpoints (except for control endpoint) exactly the same. They all have the same amount of TRBs on the ring, they all treat the ring as an actual ring with a link TRB pointing to the head, etc. We're also helping the host side burst (on SuperSpeed GEN1 or GEN2 at least) for as long as possible until the endpoint returns NRDY. Other than this big TRB ring rework on dwc3, we also have a dwc3-omap DMA initialization fix, some extra debugfs files to aid in some odd debug sessions and a complete removal of our FIFO resizing logic. We have a new quirk for some dwc3 P3 quirk in some implementations. The rest is basically non-critical fixes and the usual cleanups. commit 1cf257ab03373cb60572fb9f7a08ec83838f6232 Merge: bf16200 25611e4 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 17:52:18 2016 +0200 Merge tag 'renesas-dt-pm-domain-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/late Merge "Renesas ARM Based SoC DT PM Domain Updates for v4.7" into next/late * Add SYSC PM Domains to DT for R-Car Gen 1 and 2 SoCs This pull requests is based on a merge of: * "[GIT PULL] Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.7", tagged as renesas-rcar-sysc2-for-v4.7, which you have already pulled. * "[GIT PULL v2] Renesas ARM Based SoC DT Updates for v4.7", tagged as renesas-dt-for-v4.7, which you have also already pulled. The reason for the somewhat tedious base on renesas-rcar-sysc2-for-v4.7, which provides driver changes, is a hard run-time dependency. I also have a similar set of changes for arm64 which I will send separately. * tag 'renesas-dt-pm-domain-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: (88 commits) ARM: dts: r8a7794: Use SYSC "always-on" PM Domain ARM: dts: r8a7793: Use SYSC "always-on" PM Domain ARM: dts: r8a7791: Use SYSC "always-on" PM Domain ARM: dts: r8a7790: Use SYSC "always-on" PM Domain ARM: dts: r8a7779: Use SYSC "always-on" PM Domain ARM: dts: r8a7794: Add SYSC PM Domains ARM: dts: r8a7793: Add SYSC PM Domains ARM: dts: r8a7791: Add SYSC PM Domains ARM: dts: r8a7790: Add SYSC PM Domains ARM: dts: r8a7779: Add SYSC PM Domains soc: renesas: rcar-sysc: Add support for R-Car H3 power areas soc: renesas: rcar-sysc: Add support for R-Car E2 power areas soc: renesas: rcar-sysc: Add support for R-Car M2-N power areas soc: renesas: rcar-sysc: Add support for R-Car M2-W power areas soc: renesas: rcar-sysc: Add support for R-Car H2 power areas soc: renesas: rcar-sysc: Add support for R-Car H1 power areas soc: renesas: rcar-sysc: Enable Clock Domain for I/O devices ARM: dts: gose: Enable SDHI controllers ARM: dts: r8a7793: Add SDHI controllers ARM: dts: r8a7790: fix max-frequency for SDHI ... commit ba7863f4d3bfe1698e0a92934cbc9c3021f4448d Author: Eric Dumazet <edumazet@google.com> Date: Thu Apr 28 06:33:24 2016 -0700 net: snmp: fix 64bit stats on 32bit arches I accidentally replaced BH disabling by preemption disabling in SNMP_ADD_STATS64() and SNMP_UPD_PO_STATS64() on 32bit builds. For 64bit stats on 32bit arch, we really need to disable BH, since the "struct u64_stats_sync syncp" might be manipulated both from process and BH contexts. Fixes: 6aef70a851ac ("net: snmp: kill various STATS_USER() helpers") Reported-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Tested-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/snmp.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 98c67e7e4ce083f1d73cfb14578be1f2639386a5 Merge: d528c74 3b3c6ad Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 17:49:39 2016 +0200 Merge tag 'lpc32xx-defconfig-4.7' of git://github.com/vzapolskiy/linux-lpc32xx into next/defconfig Merge "NXP LPC32xx defconfig updates for v4.7" from Vladimir Zapolskiy: This includes savedefconfig update of lpc32xx_defconfig, which removes a number of outdated config options, plus ARM PrimeCell PL17x memory controller driver is enabled by default now, on LPC32xx boards the controller is commonly used to access SDRAM and NOR. * tag 'lpc32xx-defconfig-4.7' of git://github.com/vzapolskiy/linux-lpc32xx: ARM: LPC32xx: add PL175 memory controller driver to defconfig ARM: LPC32xx: defconfig update commit e45a70be69b352f2fd3c90c4bd33479242f20591 Merge: 8f8aab6 a03bd57 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 17:42:35 2016 +0200 Merge tag 'renesas-arm64-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/arm64 Merge "Renesas ARM64 Based SoC Defconfig Updates for v4.7" from Simon Horman: * Add Renesas R-Car USB 3.0 driver support * tag 'renesas-arm64-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: arm64: defconfig: Add Renesas R-Car USB 3.0 driver support commit 2c695998678d26b701fae9eafeac464822227103 Merge: 816a1b1 4d7820b Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 17:40:37 2016 +0200 Merge tag 'samsung-dt-exynos-srom-fixup-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/dt Merge "ARM: dts: exynos: Fixup for SROM controller (v4.7)" from Krzysztof Kozlowski: DeviceTree changes for new SROM controller driver reached mainline some time ago, before the driver was accepted (due to very late comments). However, after these late comments, the driver expects different bindings so we need to fix the DTS. * tag 'samsung-dt-exynos-srom-fixup-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: change SROM node compatible from generic to model specific commit 816a1b15efa9ec4d36c570f635ee6a3e5b1ac06d Merge: da3a6c4 6b12624 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 17:35:04 2016 +0200 Merge tag 'socfpga_dts_for_v4.7_part_2' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux into next/dt Merge "SoCFPGA DTS update for v4.7, part 2" from Dinh Nguyen: - Add samtec VIN|ING board * tag 'socfpga_dts_for_v4.7_part_2' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux: ARM: dts: socfpga: Add samtec VIN|ING board commit 5b6042237dc85b7e2dc26806957ebf95d205e864 Author: Keerthy <j-keerthy@ti.com> Date: Thu Apr 28 15:35:49 2016 +0530 ARM: dts: am57xx-idk: Include Industrial grade thermal thresholds am57xx-idk have Industrial grade samples whose thermal thresholds are different as compared with dra7. Hence correcting the same. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-idk-common.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 266e62f9753951e040192dccae2f505e34dd8278 Author: Keerthy <j-keerthy@ti.com> Date: Thu Apr 28 15:35:48 2016 +0530 ARM: dts: am57xx-beagle-x15: Include the commercial grade thresholds am57xx-beagle-x15 have commercial grade samples whose thermal thresholds lower than dra7. Hence correcting the same. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-beagle-x15.dts | 1 + 1 file changed, 1 insertion(+) commit cf9b7d5e9cfd36d7efab52e9cc74589c6eae4974 Author: Keerthy <j-keerthy@ti.com> Date: Thu Apr 28 15:35:47 2016 +0530 ARM: dts: am57xx: Introduce industrial grade thermal thresholds The silicon version ES2.0 onwards are industrial grade samples and have higher thermal thresholds than commecial grade samples. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-industrial-grade.dtsi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 286db0a516e0a64797d2ac900fe91ab65b87d555 Author: Keerthy <j-keerthy@ti.com> Date: Thu Apr 28 15:35:46 2016 +0530 ARM: dts: am57xx: Introduce commercial grade thermal thresholds The silicon versions which are non ES2.0 are commercial grade silicon and have lower thermal thresholds. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-commercial-grade.dtsi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit be35f94f5c83bfed9ded918162c9b622743ef520 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 15:19:56 2016 +0200 drm/atomic: Add missing drm_crtc_internal.h include Some of the functions implemented are flagged as not having a prototype defined when building with W=1. Include the header to avoid these build warnings. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461849596-12819-1-git-send-email-thierry.reding@gmail.com drivers/gpu/drm/drm_atomic.c | 2 ++ 1 file changed, 2 insertions(+) commit 4ef00aa30a3f382de9530df8f4083da316d95fb6 Author: Chris Metcalf <cmetcalf@mellanox.com> Date: Thu Apr 28 10:19:41 2016 -0400 tile: sort the "select" lines in the TILE/TILEGX configs Also remove the stale "FIXME: investigate these options" language. Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/Kconfig | 67 +++++++++++++++++++++++-------------------------------- 1 file changed, 28 insertions(+), 39 deletions(-) commit d6a58a5cc17a0f215bf80862b59ba82be5a2181f Merge: bf6fc0a 4cfcb35 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 16:16:00 2016 +0200 Merge tag 'hip0x-dt-for-4.7' of git://github.com/hisilicon/linux-hisi into next/dt64 Merge "ARM64: DT: Hisilicon hip05 and hip06 updates for 4.7" Wei Xu: - Fix its node without msi-cells for hip05 - Add nor flash node for hip05 D02 board - Add initial dts for hip06 D03 board - Reorder and add the hip06 D03 binding in the binding document * tag 'hip0x-dt-for-4.7' of git://github.com/hisilicon/linux-hisi: Documentation: arm64: Add Hisilicon Hip06 D03 dts binding arm64: dts: Add initial dts for Hisilicon Hip06 D03 board arm64: dts: hip05: Add nor flash support arm64: dts: hip05: fix its node without msi-cells commit bf6fc0a2494df5a5750ff7afe071eaf8f127c242 Merge: fb89cf3 9f33a8a Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 16:11:54 2016 +0200 Merge tag 'renesas-arm64-dt2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt64 Merge "Second Round of Renesas ARM64 Based SoC DT Updates for v4.7" from Simon Horman: * Don't disable referenced optional clocks in DT of r8a7795 SoC * Populate EXTALR in DT of salvator-x board * Enable PCIe in DT of salvator-x board * tag 'renesas-arm64-dt2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: arm64: dts: r8a7795: Don't disable referenced optional clocks arm64: dts: salvator-x: populate EXTALR arm64: dts: r8a7795: enable PCIe on Salvator-X arm64: dts: r8a7795: Add PCIe nodes arm64: dts: r8a7795: Use USB3.0 fallback compatibility string arm64: dts: r8a7795: Add CAN support arm64: dts: r8a7795: Add CAN external clock support commit da3a6c4787a8eb89f0c308defb382ffee50646c0 Merge: a050ebb 8691f91 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 16:05:46 2016 +0200 Merge tag 'samsung-dt-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/dt Merge "Secound round of Samsung Device Tree updates and improvements for v4.7" from Krzysztof Kozlowski: 1. Cleanup regulator bindings on Exynos5420 boards. 2. Support MIC bypass in display path for Exynos5420. 3. Enable PRNG and SSS for all Exynos4 devices. * tag 'samsung-dt-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: exynos: Enable PRNG and SSS for all Exynos4 devices ARM: dts: exynos: Add exynos5420-fimd compatible ARM: dts: exynos: Remove unsupported s2mps11 regulator bindings from Exynos5420 boards commit 2fd872bd84b3aa1a177a66a8d14bd25f68f373f0 Author: René Nyffenegger <mail@renenyffenegger.ch> Date: Thu Apr 28 10:15:24 2016 +0200 Doc: correct the location of sysrq.c sysrq.c moved to drivers/tty in 2010; update the documentation to match. Signed-off-by: René Nyffenegger <mail@renenyffenegger.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/sysrq.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ac5a181d065d74fb6b213d538f743392f27bcdbd Author: Thomas Renninger <trenn@suse.com> Date: Thu Apr 28 15:24:40 2016 +0200 cpupower: Add cpuidle parts into library This more or less is a renaming and moving of functions and should not introduce any functional change. cpupower was built from cpufrequtils (which had a C library providing easy access to cpu frequency platform info). In the meantime it got enhanced by quite some neat cpuidle userspace tools. Now the cpu idle functions have been separated and added to the cpupower.so library. So beside an already existing public header file: cpufreq.h cpupower now also exports these cpu idle functions in: cpuidle.h Here again pasted for better review of the interfaces: ====================================== int cpuidle_is_state_disabled(unsigned int cpu, unsigned int idlestate); int cpuidle_state_disable(unsigned int cpu, unsigned int idlestate, unsigned int disable); unsigned long cpuidle_state_latency(unsigned int cpu, unsigned int idlestate); unsigned long cpuidle_state_usage(unsigned int cpu, unsigned int idlestate); unsigned long long cpuidle_state_time(unsigned int cpu, unsigned int idlestate); char *cpuidle_state_name(unsigned int cpu, unsigned int idlestate); char *cpuidle_state_desc(unsigned int cpu, unsigned int idlestate); unsigned int cpuidle_state_count(unsigned int cpu); char *cpuidle_get_governor(void); char *cpuidle_get_driver(void); ====================================== Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/Makefile | 12 +- tools/power/cpupower/bench/system.c | 3 +- tools/power/cpupower/lib/cpufreq.c | 550 ++++++++++++++++- tools/power/cpupower/lib/cpufreq.h | 59 +- tools/power/cpupower/lib/cpuidle.c | 380 ++++++++++++ tools/power/cpupower/lib/cpuidle.h | 23 + tools/power/cpupower/lib/cpupower.c | 192 ++++++ tools/power/cpupower/lib/cpupower.h | 35 ++ tools/power/cpupower/lib/cpupower_intern.h | 5 + tools/power/cpupower/lib/sysfs.c | 672 --------------------- tools/power/cpupower/lib/sysfs.h | 31 - tools/power/cpupower/utils/cpufreq-set.c | 8 +- tools/power/cpupower/utils/cpuidle-info.c | 32 +- tools/power/cpupower/utils/cpuidle-set.c | 26 +- tools/power/cpupower/utils/helpers/helpers.h | 26 +- tools/power/cpupower/utils/helpers/topology.c | 107 +--- .../cpupower/utils/idle_monitor/cpuidle_sysfs.c | 12 +- 17 files changed, 1242 insertions(+), 931 deletions(-) commit fe7656a8e8fcb3a0151b36b2f4c66763fa9553ea Author: Colin Ian King <colin.king@canonical.com> Date: Thu Apr 28 15:24:39 2016 +0200 cpupowerutils: bench: trivial fix of spelling mistake on "average" fix spelling mistake, avarage -> average Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/bench/README-BENCH | 2 +- tools/power/cpupower/bench/benchmark.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 938bb850d525199c2c3619800ef97186cfccc8eb Author: Mattia Dongili <malattia@linux.it> Date: Thu Apr 28 15:24:38 2016 +0200 Fix cpupower manpages "NAME" section The token before "-" should be the program name, no spaces allowed. See man(7) and lexgrog(1). Signed-off-by: Mattia Dongili <malattia@linux.it> Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/man/cpupower-frequency-info.1 | 2 +- tools/power/cpupower/man/cpupower-frequency-set.1 | 2 +- tools/power/cpupower/man/cpupower-idle-info.1 | 2 +- tools/power/cpupower/man/cpupower-idle-set.1 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 983d9e065b37dac5aaa2d5a819bdd5b5a0b78c8c Author: Colin Ian King <colin.king@canonical.com> Date: Thu Apr 28 15:24:37 2016 +0200 cpupower: bench: parse.c: fix several resource leaks The error handling in prepare_output has several issues with resource leaks. Ensure that filename is free'd and the directory stream DIR is closed before returning. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/bench/parse.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 04b03594c73c1877a98c7a657cc45bf5e9d89f7c Author: Mattia Dongili <malattia@linux.it> Date: Thu Apr 28 15:24:36 2016 +0200 Honour user's LDFLAGS Signed-off-by: Mattia Dongili <malattia@linux.it> Signed-off-by: Thomas Renninger <trenn@suse.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/cpupower/bench/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 08559657b21522d642331f9dc455a3917d85ab00 Author: Kees Cook <keescook@chromium.org> Date: Tue Apr 26 16:41:21 2016 -0700 Documentation: fix common spelling mistakes This fixes several spelling mistakes in the Documentation/ tree, which are caught by checkpatch.pl's spell checking. Signed-off-by: Kees Cook <keescook@chromium.org> Reviewed-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/ABI/obsolete/sysfs-driver-hid-roccat-savu | 11 ++++++----- .../ABI/testing/sysfs-bus-event_source-devices-hv_24x7 | 2 +- Documentation/ABI/testing/sysfs-driver-hid-picolcd | 2 +- Documentation/ABI/testing/sysfs-firmware-acpi | 2 +- Documentation/DocBook/media/v4l/controls.xml | 2 +- Documentation/DocBook/media/v4l/dev-raw-vbi.xml | 2 +- Documentation/DocBook/media/v4l/vidioc-g-selection.xml | 2 +- Documentation/RCU/RTFP.txt | 6 +++--- Documentation/arm/SA1100/Assabet | 2 +- Documentation/devicetree/bindings/mfd/arizona.txt | 2 +- Documentation/filesystems/cifs/README | 2 +- Documentation/filesystems/pohmelfs/design_notes.txt | 2 +- Documentation/filesystems/qnx6.txt | 2 +- Documentation/firmware_class/README | 2 +- Documentation/hwmon/abituguru | 2 +- Documentation/infiniband/ipoib.txt | 2 +- Documentation/networking/altera_tse.txt | 2 +- Documentation/networking/can.txt | 2 +- Documentation/scsi/bfa.txt | 2 +- Documentation/timers/hrtimers.txt | 2 +- Documentation/video4linux/README.cx88 | 2 +- Documentation/video4linux/bttv/Sound-FAQ | 2 +- Documentation/vm/hugetlbpage.txt | 2 +- 23 files changed, 30 insertions(+), 29 deletions(-) commit a050ebb01443d1f4f6502bb49cd1cbe769c8fa6f Merge: 0d6cde5 c9006ac Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 15:50:31 2016 +0200 Merge tag 'renesas-dt2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Merge "Second Round of Renesas ARM Based SoC DT Updates for v4.7" from Simon Horman * Don't disable referenced optional clocks in DT of R-Car Gen 1 & 2 SoCs * tag 'renesas-dt2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: ARM: dts: r8a7794: Don't disable referenced optional clocks ARM: dts: r8a7793: Don't disable referenced optional clocks ARM: dts: r8a7790: Don't disable referenced optional clocks ARM: dts: r8a7779: Don't disable referenced optional clocks ARM: dts: r8a7778: Don't disable referenced optional clocks commit 934275c4805ce0bbb0df633bd6015dd455ff6cad Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 18:03:09 2016 +0200 samples: v4l: from Documentation to samples directory A small bug with the new autoksyms support showed that there are two kernel modules in the Documentation directory that qualify as samples, while all other samples are in the samples/ directory. This patch was originally meant as a workaround for that bug, but it has now been solved in a different way. However, I still think it makes sense as a cleanup to consolidate all sample code in one place. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/Makefile | 3 +- Documentation/video4linux/Makefile | 1 - Documentation/video4linux/v4l2-framework.txt | 2 +- Documentation/video4linux/v4l2-pci-skeleton.c | 923 -------------------------- samples/Makefile | 2 +- samples/v4l/Makefile | 1 + samples/v4l/v4l2-pci-skeleton.c | 923 ++++++++++++++++++++++++++ 7 files changed, 927 insertions(+), 928 deletions(-) commit 14fbff6b4e48a529c90e771598ac12bffd445ff4 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 18:03:08 2016 +0200 samples: connector: from Documentation to samples directory A small bug with the new autoksyms support showed that there are two kernel modules in the Documentation directory that qualify as samples, while all other samples are in the samples/ directory. This patch was originally meant as a workaround for that bug, but it has now been solved in a different way. However, I still think it makes sense as a cleanup to consolidate all sample code in one place. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/Makefile | 2 +- Documentation/connector/.gitignore | 1 - Documentation/connector/Makefile | 16 --- Documentation/connector/cn_test.c | 201 --------------------------- Documentation/connector/connector.txt | 8 ++ Documentation/connector/ucon.c | 250 ---------------------------------- samples/Kconfig | 9 ++ samples/Makefile | 2 +- samples/connector/.gitignore | 1 + samples/connector/Makefile | 16 +++ samples/connector/cn_test.c | 201 +++++++++++++++++++++++++++ samples/connector/ucon.c | 250 ++++++++++++++++++++++++++++++++++ 12 files changed, 487 insertions(+), 470 deletions(-) commit 0d6cde5093288749be2981cbdebb0125db572e2f Merge: ff83b37 3ff11fe Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 15:45:24 2016 +0200 Merge tag 'lpc32xx-dt-4.7' of git://github.com/vzapolskiy/linux-lpc32xx into next/dt Merge "NXP LPC32xx device tree updates for v4.7" from Vladimir Zapolskiy: This includes a few functional changes: * new representation of MIC, SIC1 and SIC2 interrupt controllers, * disabled by default SPI1, SPI2, SSP0 and SSP1 SPI controllers in shared lpc32xx.dtsi file, * added clock sources for SPI1 and SPI2, * set default clock rate of HCLK PLL to main osc rate multiplied by 16. Also there are some non-functional changes: * flatten board DTS files by exploiting device node labels, * add 'partitions' device node for NAND SLC / MTD OF, * correct Atmel vendor prefix to describe on board AT24 EEPROMs, * rename board DTS files by adding SoC name prefix. Since now DTS files of LPC32xx boards match "^lpc32[2345]0-" pattern. * tag 'lpc32xx-dt-4.7' of git://github.com/vzapolskiy/linux-lpc32xx: ARM: dts: lpc32xx: phy3250: add SoC name prefix to board dts file ARM: dts: lpc32xx: phy3250: add NAND partitions device node ARM: dts: lpc32xx: phy3250: avoid extension of device nodes by absolute path ARM: dts: lpc32xx: ea3250: add SoC name prefix to board dts file ARM: dts: lpc32xx: ea3250: fix Atmel at24 eeprom vendor ARM: dts: lpc32xx: ea3250: add NAND partitions device node ARM: dts: lpc32xx: ea3250: avoid extension of device nodes by absolute path ARM: dts: lpc32xx: reparent SIC1 and SIC2 interrupts from MIC dt-bindings: interrupt-controllers: add description of SIC1 and SIC2 ARM: dts: lpc32xx: disabled ssp0/spi1 & ssp1/spi2 by default ARM: dts: phy3250: enable ssp0 ARM: dts: lpc32xx: add clock properties to spi nodes ARM: dts: lpc32xx: set default clock rate of HCLK PLL commit 715cda787c47458c94b2d012e6e9ab0988409f22 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:07 2016 +0100 Documentation: xillybus: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/xillybus.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c8e84d2f9bc0021200a11721df0dc987d6191193 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:06 2016 +0100 Documentation: x86: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/x86/intel_mpx.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ff83b377cb56875fb4daba63e2595d8c27d9204d Merge: b48e5aa 5175500 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 15:44:04 2016 +0200 Merge tag 'at91-dt2' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91 into next/dt Merge "Second batch of DT changes for 4.7" from Nicolas Ferre: - three low priority fixes: - sama5d2: one pin definition and dependency with the slow clock for watchdog - sama5d4: definition of watchdog IRQ property - addition of the new shutdown controller to sama5d2 & sama5d2 Xplained * tag 'at91-dt2' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91: ARM: dts: at91: sama5d2: add slow clock to watchdog node ARM: dts: at91: sama5d2: add shutdown controller node ARM: dts: at91: sama5d4: add watchdog interrupt property ARM: dts: at91: fix typo in sama5d2 PIN_PD24 description commit b48e5aa6bc2eacf1f1b54bb6845963c8731f450f Merge: 6945248 3d90bc0 Author: Arnd Bergmann <arnd@arndb.de> Date: Thu Apr 28 15:41:28 2016 +0200 Merge tag 'sti-dt-for-v4.7b-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti into next/dt Merge "STi DT updates for v4.7 #1" from Maxime Coquelin: Highlights: ----------- - Add CPUFreq support to STiH407 family - Add Mailbox nodes to STiH407 family - Add RemoteProc nodes to STiH407 family - Use 'reserved-memory' for DMA memory on STiH407 - Use the LPC timer as a clocksource * tag 'sti-dt-for-v4.7b-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti: ARM: dts: STi: STih407: Switch LPC mode from RTC to Clocksource ARM: dts: STiH407: Move over to using the 'reserved-memory' API for obtaining DMA memory ARM: dts: STiH407: Add nodes for RemoteProc ARM: dts: STi: stih407-family: Add nodes for Mailbox ARM: dts: STi: STiH407: Provide CPU with a means to look-up Major number ARM: dts: STi: STiH407: Link CPU with its voltage supply ARM: dts: STi: STiH407: Provide CPU with clocking information ARM: dts: STi: STiH407: Provide generic (safe) DVFS configuration commit 1248562b8cd8d6cc2950e165cb426b4f36d29f64 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:01 2016 +0100 Documentation: scsi: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> [jc: fixed trailing whitespace errors] Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/scsi/ChangeLog.megaraid_sas | 48 +++++++++++++++---------------- 1 file changed, 24 insertions(+), 24 deletions(-) commit 86cbbe24b4120aa4813c8519eb2b1506147fe0a0 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:00 2016 +0100 Documentation: robust-futexes: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/robust-futexes.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c0270efc510e53afd99f35aff0d0251672ae07c3 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:36:58 2016 +0100 Documentation: pps: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/pps/pps.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 62e153c46f699efa13f5fa4445c2ecc4c5de1ec1 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:36:55 2016 +0100 Documentation: lzo: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/lzo.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9f123def55d3fd0d76d49e0009419bcb994f6f1f Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:27 2016 +0530 cpufreq: mvebu: Move cpufreq code into drivers/cpufreq/ Move cpufreq bits for mvebu into drivers/cpufreq/ directory, that's where they really belong to. Compiled tested only. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> MAINTAINERS | 1 + arch/arm/mach-mvebu/pmsu.c | 85 ------------------------------- drivers/cpufreq/Makefile | 1 + drivers/cpufreq/mvebu-cpufreq.c | 107 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 109 insertions(+), 85 deletions(-) commit eb96924acddc709db58221c210ca05cd9effb1df Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:26 2016 +0530 cpufreq: dt: Kill platform-data There are no more users of platform-data for cpufreq-dt driver, get rid of it. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq-dt.c | 6 +----- include/linux/cpufreq-dt.h | 24 ------------------------ 2 files changed, 1 insertion(+), 29 deletions(-) commit 947bd567f7a5185325a8f85e5235cf1145bd4417 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:25 2016 +0530 mvebu: Use dev_pm_opp_set_sharing_cpus() to mark OPP tables as shared That will allow us to avoid using cpufreq-dt platform data. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-mvebu/pmsu.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 1530b9963eeb5304d9aec48ee0e7ea966d7cf3d9 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:24 2016 +0530 cpufreq: dt: Identify cpu-sharing for platforms without operating-points-v2 Existing platforms, which do not support operating-points-v2, can explicitly tell the opp core that some of the CPUs share opp tables, with help of dev_pm_opp_set_sharing_cpus(). For such platforms, explicitly ask the opp core to provide list of CPUs sharing the opp table with current cpu device, before falling back to platform data. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq-dt.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 2b4f4f3da6a04ba0f7a4e132a7e646aac3346dbc Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:36:53 2016 +0100 Documentation: laptops: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/laptops/toshiba_haps.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 29c5e7b2bc875c4ad5d3fd9e3c4ed2702e705bba Merge: 6f707da b4f4b4b Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Apr 28 15:19:31 2016 +0200 Merge back earlier cpufreq material for v4.7. commit 6f707daa3833761110a03478cba5cc4b708ec77d Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:23 2016 +0530 PM / OPP: Add dev_pm_opp_get_sharing_cpus() OPP core allows a platform to mark OPP table as shared, when the platform isn't using operating-points-v2 bindings. And, so there should be a non DT way of finding out if the OPP table is shared or not. This patch adds dev_pm_opp_get_sharing_cpus(), which first tries to get OPP sharing information from the opp-table (in case it is already marked as shared), otherwise it uses the existing DT way of finding sharing information. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 45 ++++++++++++++++++++++++++++++++++++++++++++ include/linux/pm_opp.h | 6 ++++++ 2 files changed, 51 insertions(+) commit dde370b23c1787a9c723ac049d56a3014937f889 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:22 2016 +0530 PM / OPP: Mark cpumask as const in dev_pm_opp_set_sharing_cpus() dev_pm_opp_set_sharing_cpus() isn't supposed to update the cpumask passed as its parameter, and so it should always have been marked 'const'. Do it now. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 3 ++- include/linux/pm_opp.h | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) commit d708b384c06dddeb35d46a6127c08a7403fa2faf Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Apr 27 08:52:21 2016 +0530 PM / OPP: -ENOSYS is applicable only to syscalls Some of the routines have used -ENOSYS for the cases where the functionality isn't implemented in the kernel. But ENOSYS is supposed to be used only for syscalls. Replace that with -ENOTSUPP, which specifically means that the operation isn't supported. While at it, replace exiting -EINVAL errors for similar cases to -ENOTSUPP. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/linux/pm_opp.h | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 2ea2dc87feb5778f6a4f58dec4ddce695e58e482 Author: Alexander Kurz <akurz@blala.de> Date: Thu Apr 21 19:02:04 2016 +0200 Documentation: devres: Add missing INPUT function devm_input_allocate_device() got introduced with commit 2be975c6d920 ("Input: introduce managed input devices (add devres support)"). Add this function to the list of managed interfaces within the devres documentation. Signed-off-by: Alexander Kurz <akurz@blala.de> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/driver-model/devres.txt | 3 +++ 1 file changed, 3 insertions(+) commit e0a37712819cb0e942f165a3f88d85f7c6388219 Author: Fu Wei <wefu@redhat.com> Date: Thu Apr 21 21:45:40 2016 +0800 Documentation:Update Documentation/zh_CN/arm64/booting.txt This is a update of Chinese documentation: Documentation/zh_CN/arm64/booting.txt It is based on the modifications of Documentation/arm64/booting.txt in submission: "a7f8de16". Signed-off-by: Fu Wei <wefu@redhat.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/zh_CN/arm64/booting.txt | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit ac86db349e2df2e2d6b786cbacefa3037126f3bc Author: Cao jin <caoj.fnst@cn.fujitsu.com> Date: Thu Apr 21 21:39:15 2016 +0800 hrtimers: doc cleanup It has: a tense correction(led->leads); a typo(unevitably->inevitably); Signed-off-by: Cao jin <caoj.fnst@cn.fujitsu.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/timers/hrtimers.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fba1fbf56383073d286e6e3657bff36ee0f410e8 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 14:42:34 2016 +0200 PM / sleep: Drop unused `info' variable Commit 32e8d689dc12 (PM / sleep: trace_device_pm_callback coverage in dpm_prepare/complete) removed all users of this variable but forgot to remove the variable itself. Signed-off-by: Thierry Reding <treding@nvidia.com> [ rjw: Subject ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/main.c | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) commit b4f4b4b37133340befa354fbaa54d8e84ea86103 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Apr 28 01:19:03 2016 +0200 cpufreq: governor: Change confusing struct field and variable names The name of the prev_cpu_wall field in struct cpu_dbs_info is confusing, because it doesn't represent wall time, but the previous update time as returned by get_cpu_idle_time() (that may be the current value of jiffies_64 in some cases, for example). Moreover, the names of some related variables in dbs_update() take that confusion further. Rename all of those things to make their names reflect the purpose more accurately. While at it, drop unnecessary parens from one of the updated expressions. No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Chen Yu <yu.c.chen@intel.com> drivers/cpufreq/cpufreq_governor.c | 22 +++++++++++----------- drivers/cpufreq/cpufreq_governor.h | 2 +- 2 files changed, 12 insertions(+), 12 deletions(-) commit 9999c5fc014adcc4278adddb73888c301be7b9f7 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 14:45:28 2016 +0200 clocksource/drivers/tegra: Remove unused suspend/resume code The tegra_timer_suspend() and tegra_timer_resume() functions are never used, so they can be removed. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> drivers/clocksource/tegra20_timer.c | 14 -------------- 1 file changed, 14 deletions(-) commit 0302637f1860400cfe0895e4355a5fecb89e0347 Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:45:44 2016 +0100 clockevents/driversi/mps2: add MPS2 Timer driver MPS2 platform has simple 32 bits general purpose countdown timers. The driver uses the first detected timer as a clocksource and the rest of the timers as a clockevent Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> drivers/clocksource/Kconfig | 6 + drivers/clocksource/Makefile | 1 + drivers/clocksource/mps2-timer.c | 275 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 282 insertions(+) commit 96669fa43ccaf4131183d4a3b0f159ce9ecaf2ff Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:45:43 2016 +0100 dt-bindings: document the MPS2 timer bindings This adds documentation of device tree bindings for the timers found on ARM MPS2 platform. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> .../devicetree/bindings/timer/arm,mps2-timer.txt | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit d98eddf849df7ad71b375464fd02f81f1ae4de20 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Mon Apr 18 16:55:36 2016 +0200 clocksource/drivers/mtk_timer: Add __init attribute Add __init attribute on a function that is only called from other __init functions and that is not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the function is put in the .text.unlikely segment. Declaring it as __init will cause it to be put in the .init.text and to disappear after initialization. The result of objdump -x on the function before the change is as follows: 0000000000000000 l F .text.unlikely 000000000000006f mtk_timer_setup.isra.4 And after the change it is as follows: 0000000000000000 l F .init.text 000000000000006a mtk_timer_setup.isra.4 Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Acked-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/clocksource/mtk_timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 457353260d9ff4b89bcf21c9142b2f54ed75699e Author: Jisheng Zhang <jszhang@marvell.com> Date: Fri Feb 26 17:45:57 2016 +0800 clockevents/drivers/dw_apb_timer: Implement ->set_state_oneshot_stopped() The dw_apb_timer only "supports PERIODIC mode and their drivers emulate ONESHOT over that" as described in commit 8fff52fd5093 ("clockevents: Introduce CLOCK_EVT_STATE_ONESHOT_STOPPED state"). Inspired by Viresh, I think the dw_apb_timer also needs to implement the set_state_oneshot_stopped() which is called by the clkevt core, when the next event is required at an expiry time of 'KTIME_MAX'. This normally happens with NO_HZ_{IDLE|FULL} in both LOWRES/HIGHRES modes. This patch makes the clockevent device to stop on such an event, to avoid spurious interrupts, as explained by the above commit. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/clocksource/dw_apb_timer.c | 1 + 1 file changed, 1 insertion(+) commit a30e6259b5e31e8d2b40f3b0099d98a6ebe0e360 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 27 19:01:52 2016 -0300 perf trace: Move msg_flags beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-11zxg3qitk6bw2x30135k9z4@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 62 +------------------------------------ tools/perf/trace/beauty/msg_flags.c | 62 +++++++++++++++++++++++++++++++++++++ 2 files changed, 63 insertions(+), 61 deletions(-) commit be7b0c9e376e93a00b6c8631e2721e9dc7c6a1fa Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:54 2016 +0000 perf record: Generate tracking events for process forked by perf With 'perf record --switch-output' without -a, record__synthesize() in record__switch_output() won't generate tracking events because there's no thread_map in evlist. Which causes newly created perf.data doesn't contain map and comm information. This patch creates a fake thread_map and directly call perf_event__synthesize_thread_map() for those events. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-8-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) commit 0c1d46a8796e8309f1ca693e5cad6f318e4b8159 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:52 2016 +0000 perf record: Disable buildid cache options by default in switch output mode The cost of buildid cache processing is high: reading all events in output perf.data, opening each elf file to read buildids then copying them into ~/.debug directory. In switch output mode, these heavy works block perf from receiving perf events for too long. Enable no-buildid and no-buildid-cache by default if --switch-output is provided. Still allow user use --no-no-buildid to explicitly enable buildid in this case. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-6-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Updated man page ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-record.txt | 2 +- tools/perf/builtin-record.c | 30 +++++++++++++++++++++++++++++- 2 files changed, 30 insertions(+), 2 deletions(-) commit eca857ab381858450ec2f91f5aaae7f2f7a7a180 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:51 2016 +0000 perf record: Force enable --timestamp-filename when --switch-output is provided Without this patch, the last output doesn't have timestamp appended if --timestamp-filename is not explicitly provided. For example: # perf record -a --switch-output & [1] 11224 # kill -s SIGUSR2 11224 [ perf record: dump data: Woken up 1 times ] # [ perf record: Dump perf.data.2015122622372823 ] # fg perf record -a --switch-output ^C[ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.027 MB perf.data (540 samples) ] # ls -l total 836 -rw------- 1 root root 33256 Dec 26 22:37 perf.data <---- *Odd* -rw------- 1 root root 817156 Dec 26 22:37 perf.data.2015122622372823 Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-5-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Updated man page, that also got an entry for --timestamp-filename ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-record.txt | 5 +++++ tools/perf/builtin-record.c | 3 +++ 2 files changed, 8 insertions(+) commit 3c1cb7e3723caad9b4c1b2f816d86d8605296a4b Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:50 2016 +0000 perf record: Split output into multiple files via '--switch-output' Allow 'perf record' to split its output into multiple files. For example: # ~/perf record -a --timestamp-filename --switch-output & [1] 10763 # kill -s SIGUSR2 10763 [ perf record: dump data: Woken up 1 times ] # [ perf record: Dump perf.data.2015122622314468 ] # kill -s SIGUSR2 10763 [ perf record: dump data: Woken up 1 times ] # [ perf record: Dump perf.data.2015122622314762 ] # kill -s SIGUSR2 10763 [ perf record: dump data: Woken up 1 times ] #[ perf record: Dump perf.data.2015122622315171 ] # fg perf record -a --timestamp-filename --switch-output ^C[ perf record: Woken up 1 times to write data ] [ perf record: Dump perf.data.2015122622315513 ] [ perf record: Captured and wrote 0.014 MB perf.data.<timestamp> (296 samples) ] # ls -l total 920 -rw------- 1 root root 797692 Dec 26 22:31 perf.data.2015122622314468 -rw------- 1 root root 59960 Dec 26 22:31 perf.data.2015122622314762 -rw------- 1 root root 59912 Dec 26 22:31 perf.data.2015122622315171 -rw------- 1 root root 19220 Dec 26 22:31 perf.data.2015122622315513 Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-4-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Added man page entry, used the re-synthesize patch in this series as a fixup ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-record.txt | 8 +++++++ tools/perf/builtin-record.c | 40 ++++++++++++++++++++++++++++++-- 2 files changed, 46 insertions(+), 2 deletions(-) commit 5f9cf5992cfb9d9763fb92f755642dda8f9e844f Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:49 2016 +0000 perf tools: Derive trigger class from auxtrace_snapshot auxtrace_snapshot_state matches the trigger model. Use trigger to implement it. auxtrace_snapshot_state and auxtrace_snapshot_err are absorbed. Signed-off-by: Wang Nan <wangnan0@huawei.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-3-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 73 +++++++++++++-------------------------------- 1 file changed, 20 insertions(+), 53 deletions(-) commit 3dcc4436fa6f09ce093ff59bf8477c3059dc46df Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 20 18:59:48 2016 +0000 perf tools: Introduce trigger class Use 'trigger' to model operations which need to be executed when an event (a signal, for example) is observed. States and transits: OFF--(on)--> READY --(hit)--> HIT ^ | | (ready) | | \_____________/ is_hit and is_ready are two key functions to query the state of a trigger. is_hit means the event already happen; is_ready means the trigger is waiting for the event. Signed-off-by: Wang Nan <wangnan0@huawei.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461178794-40467-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/trigger.h | 94 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) commit 909b0360ae358f212f526e171ea4ef433b1b4103 Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Thu Apr 28 03:37:14 2016 +0900 perf probe: Use strbuf for making strings Replace many fixed-length char array with strbuf to stringify perf_probe_event and probe_trace_event etc. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160427183713.23446.97377.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-event.c | 246 ++++++++++++++--------------------------- tools/perf/util/probe-event.h | 2 +- tools/perf/util/probe-finder.c | 14 +-- 3 files changed, 93 insertions(+), 169 deletions(-) commit 81d64f46d41c428474c64e5c59e5458b7f50d9fd Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 27 17:56:53 2016 -0300 perf evsel: Remove two extraneous ending newlines in open_strerror() The error messages returned by this method should not have an ending newline, fix the two cases where it was. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-8af0pazzhzl3dluuh8p7ar7p@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit de46d5268c4ec5c5b473c96fbf56ece188a6ba85 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 27 17:51:45 2016 -0300 perf evsel: Handle ENOMEM for perf_event_max_stack + PERF_SAMPLE_CALLCHAIN When the kernel allows tweaking perf_event_max_stack and the event being setup has PERF_SAMPLE_CALLCHAIN in its perf_event_attr.sample_type, tell the user that tweaking /proc/sys/kernel/perf_event_max_stack may solve the problem. Before: # echo 32000 > /proc/sys/kernel/perf_event_max_stack # perf record -g usleep 1 Error: The sys_perf_event_open() syscall returned with 12 (Cannot allocate memory) for event (cycles:ppp). /bin/dmesg may provide additional information. No CONFIG_PERF_EVENTS=y kernel support configured? # After: # echo 64000 > /proc/sys/kernel/perf_event_max_stack # perf record -g usleep 1 Error: Not enough memory to setup event with callchain. Hint: Try tweaking /proc/sys/kernel/perf_event_max_stack Hint: Current value: 64000 # Suggested-by: David Ahern <dsahern@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ebv0orelj1s1ye857vhb82ov@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 1a71476e4f2693ed93523c80ff1e2d4a8634717c Author: Florian Fainelli <f.fainelli@gmail.com> Date: Sun Apr 24 19:34:54 2016 -0700 bpf tools: Fix syscall argument Coverity flagged this under CID 1354884 as a sizeof mismatch, it turns out that the argument "attr" passed to syscall should have been a pointer to attr in the first place. Reported-by: coverity (CID 1354884) Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Fixes: 8f9e05fb298f ("perf tools: Fix PowerPC native building") Link: http://lkml.kernel.org/r/1461551694-5512-3-git-send-email-f.fainelli@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/build/feature/test-bpf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a431d67934dfe9ffbe65972b0dbe576331595186 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Sun Apr 24 19:34:53 2016 -0700 bpf tools: Remove expression with no effect Assigning "attr" to "attr" does not have any effect, but was caught by Coverity, so let's remove this. Reported-by: coverity (CID 1354720) Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Wang Nan <wangnan0@huawei.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Cc: Jiri Olsa <jolsa@kernel.org> Fixes: 1b76c13e4b36 ("bpf tools: Introduce 'bpf' library and add bpf feature check") Link: http://lkml.kernel.org/r/1461551694-5512-2-git-send-email-f.fainelli@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/build/feature/test-bpf.c | 1 - 1 file changed, 1 deletion(-) commit 3484f1be2dbf520ad150a0be11f04464b930a4e6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 13:18:59 2016 +0200 gpio: pl061: implement .get_direction() Implement this callback so that the driver reports correctly the direction setting of each line. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-pl061.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 682366d5c93340b751bc547779209f502a80762e Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 13:18:11 2016 +0200 gpio: pl061: remove range check The gpiochip calls are already checking that the GPIO line offsets are in range. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-pl061.c | 6 ------ 1 file changed, 6 deletions(-) commit 1fe492ce6482b77807b25d29690a48c46456beee Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:13 2016 +0100 arm64: hibernate: Refuse to hibernate if the boot cpu is offline Hibernation represents a system state save/restore through a system reboot; this implies that the logical cpus carrying out hibernation/thawing must be the same, so that the context saved in the snapshot image on hibernation is consistent with the state of the system on resume. If resume from hibernation is driven through kernel command line parameter, the cpu responsible for thawing the system will be whatever CPU firmware boots the system on upon cold-boot (ie logical cpu 0); this means that in order to keep system context consistent between the hibernate snapshot image and system state on kernel resume from hibernate, logical cpu 0 must be online on hibernation and must be the logical cpu that creates the snapshot image. This patch adds a PM notifier that enforces logical cpu 0 is online when the hibernation is started (and prevents hibernation if it is not), which is sufficient to guarantee it will be the one creating the snapshot image therefore providing the resume cpu a consistent snapshot of the system to resume to. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/hibernate.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 82869ac57b5d3b550446932c918dbf2caf020c9e Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:12 2016 +0100 arm64: kernel: Add support for hibernate/suspend-to-disk Add support for hibernate/suspend-to-disk. Suspend borrows code from cpu_suspend() to write cpu state onto the stack, before calling swsusp_save() to save the memory image. Restore creates a set of temporary page tables, covering only the linear map, copies the restore code to a 'safe' page, then uses the copy to restore the memory image. The copied code executes in the lower half of the address space, and once complete, restores the original kernel's page tables. It then calls into cpu_resume(), and follows the normal cpu_suspend() path back into the suspend code. To restore a kernel using KASLR, the address of the page tables, and cpu_resume() are stored in the hibernate arch-header and the el2 vectors are pivotted via the 'safe' page in low memory. Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Tested-by: Kevin Hilman <khilman@baylibre.com> # Tested on Juno R2 Signed-off-by: James Morse <james.morse@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 8 + arch/arm64/include/asm/suspend.h | 7 + arch/arm64/kernel/Makefile | 1 + arch/arm64/kernel/asm-offsets.c | 5 + arch/arm64/kernel/hibernate-asm.S | 176 +++++++++++++++ arch/arm64/kernel/hibernate.c | 461 ++++++++++++++++++++++++++++++++++++++ arch/arm64/kernel/vmlinux.lds.S | 15 ++ 7 files changed, 673 insertions(+) commit f6cf0545ec697ddc278b7457b7d0c0d86a2ea88e Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:11 2016 +0100 PM / Hibernate: Call flush_icache_range() on pages restored in-place Some architectures require code written to memory as if it were data to be 'cleaned' from any data caches before the processor can fetch them as new instructions. During resume from hibernate, the snapshot code copies some pages directly, meaning these architectures do not get a chance to perform their cache maintenance. Modify the read and decompress code to call flush_icache_range() on all pages that are restored, so that the restored in-place pages are guaranteed to be executable on these architectures. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Pavel Machek <pavel@ucw.cz> Acked-by: Rafael J. Wysocki <rjw@rjwysocki.net> Acked-by: Catalin Marinas <catalin.marinas@arm.com> [will: make clean_pages_on_* static and remove initialisers] Signed-off-by: Will Deacon <will.deacon@arm.com> kernel/power/swap.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 67668a57b351df66cd8c94cd84f2a382e440e8ed Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 14:33:17 2016 +0200 pinctrl: nomadik: implement .get_direction() This makes the Nomadik gpiochip support the .get_direction() callback. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/nomadik/pinctrl-nomadik.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 5e81e0a0913c609ce18709a0a4c8fb54344aaca1 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 28 14:31:32 2016 +0200 pinctrl: nomadik: use BIT() with offsets consequently This driver is confusing in referencing/dereferencing the global GPIO number scope in some places and using local offsets in other places. Remove some of the confusion by removing local "bit" and "bitmask" definitions and just use BIT(offset) directly. Also unexport a function only used in this file. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/nomadik/pinctrl-nomadik.c | 128 ++++++++++++------------------ 1 file changed, 51 insertions(+), 77 deletions(-) commit 5003dbde45961dd7ab3d8a09ab9ad8bcb604db40 Author: Geoff Levand <geoff@infradead.org> Date: Wed Apr 27 17:47:10 2016 +0100 arm64: Add new asm macro copy_page Kexec and hibernate need to copy pages of memory, but may not have all of the kernel mapped, and are unable to call copy_page(). Add a simplistic copy_page() macro, that can be inlined in these situations. lib/copy_page.S provides a bigger better version, but uses more registers. Signed-off-by: Geoff Levand <geoff@infradead.org> [Changed asm label to 9998, added commit message] Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/assembler.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 28c7258330ee4ce701a4da7af96d6605d1a0b3bd Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:09 2016 +0100 arm64: Promote KERNEL_START/KERNEL_END definitions to a header file KERNEL_START and KERNEL_END are useful outside head.S, move them to a header file. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/memory.h | 3 +++ arch/arm64/kernel/head.S | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) commit 812264550dcba6cdbe84bfac2f27e7d23b5b8733 Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:08 2016 +0100 arm64: kernel: Include _AC definition in page.h page.h uses '_AC' in the definition of PAGE_SIZE, but doesn't include linux/const.h where this is defined. This produces build warnings when only asm/page.h is included by asm code. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/page.h | 2 ++ 1 file changed, 2 insertions(+) commit cabe1c81ea5be983425d117912d7883e252a3b09 Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:07 2016 +0100 arm64: Change cpu_resume() to enable mmu early then access sleep_sp by va By enabling the MMU early in cpu_resume(), the sleep_save_sp and stack can be accessed by VA, which avoids the need to convert-addresses and clean to PoC on the suspend path. MMU setup is shared with the boot path, meaning the swapper_pg_dir is restored directly: ttbr1_el1 is no longer saved/restored. struct sleep_save_sp is removed, replacing it with a single array of pointers. cpu_do_{suspend,resume} could be further reduced to not restore: cpacr_el1, mdscr_el1, tcr_el1, vbar_el1 and sctlr_el1, all of which are set by __cpu_setup(). However these values all contain res0 bits that may be used to enable future features. Signed-off-by: James Morse <james.morse@arm.com> Reviewed-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/suspend.h | 9 ++---- arch/arm64/kernel/asm-offsets.c | 3 -- arch/arm64/kernel/head.S | 2 +- arch/arm64/kernel/setup.c | 1 - arch/arm64/kernel/sleep.S | 66 ++++++++++++++++------------------------ arch/arm64/kernel/suspend.c | 38 ++++------------------- arch/arm64/mm/proc.S | 53 +++++++++++++------------------- 7 files changed, 57 insertions(+), 115 deletions(-) commit adc9b2dfd00924e9e9b98613f36a6cb8c51f0dc6 Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:06 2016 +0100 arm64: kernel: Rework finisher callback out of __cpu_suspend_enter() Hibernate could make use of the cpu_suspend() code to save/restore cpu state, however it needs to be able to return '0' from the 'finisher'. Rework cpu_suspend() so that the finisher is called from C code, independently from the save/restore of cpu state. Space to save the context in is allocated in the caller's stack frame, and passed into __cpu_suspend_enter(). Hibernate's use of this API will look like a copy of the cpu_suspend() function. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/suspend.h | 20 +++++++++ arch/arm64/kernel/asm-offsets.c | 2 + arch/arm64/kernel/sleep.S | 93 ++++++++++++++-------------------------- arch/arm64/kernel/suspend.c | 72 ++++++++++++++++++------------- 4 files changed, 97 insertions(+), 90 deletions(-) commit 67f6919766620e7ea7aab11a6a3470dc7b451359 Author: AKASHI Takahiro <takahiro.akashi@linaro.org> Date: Wed Apr 27 17:47:05 2016 +0100 arm64: kvm: allows kvm cpu hotplug The current kvm implementation on arm64 does cpu-specific initialization at system boot, and has no way to gracefully shutdown a core in terms of kvm. This prevents kexec from rebooting the system at EL2. This patch adds a cpu tear-down function and also puts an existing cpu-init code into a separate function, kvm_arch_hardware_disable() and kvm_arch_hardware_enable() respectively. We don't need the arm64 specific cpu hotplug hook any more. Since this patch modifies common code between arm and arm64, one stub definition, __cpu_reset_hyp_mode(), is added on arm side to avoid compilation errors. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org> [Rebase, added separate VHE init/exit path, changed resets use of kvm_call_hyp() to the __version, en/disabled hardware in init_subsystems(), added icache maintenance to __kvm_hyp_reset() and removed lr restore, removed guest-enter after teardown handling] Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm/include/asm/kvm_host.h | 10 +++- arch/arm/include/asm/kvm_mmu.h | 1 + arch/arm/kvm/arm.c | 119 +++++++++++++++++++++++--------------- arch/arm/kvm/mmu.c | 5 ++ arch/arm64/include/asm/kvm_asm.h | 1 + arch/arm64/include/asm/kvm_host.h | 13 ++++- arch/arm64/include/asm/kvm_mmu.h | 1 + arch/arm64/kvm/hyp-init.S | 38 ++++++++++++ arch/arm64/kvm/reset.c | 14 +++++ 9 files changed, 152 insertions(+), 50 deletions(-) commit c94b0cf28281d483c8b43b4874fcb7ab14ade1b1 Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:04 2016 +0100 arm64: hyp/kvm: Make hyp-stub reject kvm_call_hyp() A later patch implements kvm_arch_hardware_disable(), to remove kvm from el2, and re-instate the hyp-stub. This can happen while guests are running, particularly when kvm_reboot() calls kvm_arch_hardware_disable() on each cpu. This can interrupt a guest, remove kvm, then allow the guest to be scheduled again. This causes kvm_call_hyp() to be run against the hyp-stub. Change the hyp-stub to return a new exception type when this happens, and add code to kvm's handle_exit() to tell userspace we failed to enter the guest. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/kvm_asm.h | 2 ++ arch/arm64/kernel/hyp-stub.S | 5 +++-- arch/arm64/kvm/handle_exit.c | 7 +++++++ 3 files changed, 12 insertions(+), 2 deletions(-) commit ad72e59ff2bad55f6b9e7ac1fe5d824831ea2550 Author: Geoff Levand <geoff@infradead.org> Date: Wed Apr 27 17:47:03 2016 +0100 arm64: hyp/kvm: Make hyp-stub extensible The existing arm64 hcall implementations are limited in that they only allow for two distinct hcalls; with the x0 register either zero or not zero. Also, the API of the hyp-stub exception vector routines and the KVM exception vector routines differ; hyp-stub uses a non-zero value in x0 to implement __hyp_set_vectors, whereas KVM uses it to implement kvm_call_hyp. To allow for additional hcalls to be defined and to make the arm64 hcall API more consistent across exception vector routines, change the hcall implementations to reserve all x0 values below 0xfff for hcalls such as {s,g}et_vectors(). Define two new preprocessor macros HVC_GET_VECTORS, and HVC_SET_VECTORS to be used as hcall type specifiers and convert the existing __hyp_get_vectors() and __hyp_set_vectors() routines to use these new macros when executing an HVC call. Also, change the corresponding hyp-stub and KVM el1_sync exception vector routines to use these new macros. Signed-off-by: Geoff Levand <geoff@infradead.org> [Merged two hcall patches, moved immediate value from esr to x0, use lr as a scratch register, changed limit to 0xfff] Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/virt.h | 16 ++++++++++++++++ arch/arm64/kernel/hyp-stub.S | 34 ++++++++++++++++++++++++---------- arch/arm64/kvm/hyp.S | 4 ++-- arch/arm64/kvm/hyp/hyp-entry.S | 4 ++-- 4 files changed, 44 insertions(+), 14 deletions(-) commit 00a44cdaba0900c63a003e0c431f506f49376a90 Author: James Morse <james.morse@arm.com> Date: Wed Apr 27 17:47:02 2016 +0100 arm64: kvm: Move lr save/restore from do_el2_call into EL1 Today the 'hvc' calling KVM or the hyp-stub is expected to preserve all registers. KVM saves/restores the registers it needs on the EL2 stack using do_el2_call(). The hyp-stub has no stack, later patches need to be able to be able to clobber the link register. Move the link register save/restore to the the call sites. Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/hyp-stub.S | 10 ++++++++-- arch/arm64/kvm/hyp.S | 7 ++++++- arch/arm64/kvm/hyp/hyp-entry.S | 6 ++---- 3 files changed, 16 insertions(+), 7 deletions(-) commit e7227d0e528f9a96d4a866f43e20dd9b33f0e782 Author: Geoff Levand <geoff@infradead.org> Date: Wed Apr 27 17:47:01 2016 +0100 arm64: Cleanup SCTLR flags We currently have macros defining flags for the arm64 sctlr registers in both kvm_arm.h and sysreg.h. To clean things up and simplify move the definitions of the SCTLR_EL2 flags from kvm_arm.h to sysreg.h, rename any SCTLR_EL1 or SCTLR_EL2 flags that are common to both registers to be SCTLR_ELx, with 'x' indicating a common flag, and fixup all files to include the proper header or to use the new macro names. Signed-off-by: Geoff Levand <geoff@infradead.org> [Restored pgtable-hwdef.h include] Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/kvm_arm.h | 11 ----------- arch/arm64/include/asm/sysreg.h | 19 +++++++++++++++---- arch/arm64/kvm/hyp-init.S | 5 +++-- 3 files changed, 18 insertions(+), 17 deletions(-) commit 7b7293ae3dbd0a1965bf310b77fed5f9bb37bb93 Author: Geoff Levand <geoff@infradead.org> Date: Wed Apr 27 17:47:00 2016 +0100 arm64: Fold proc-macros.S into assembler.h To allow the assembler macros defined in arch/arm64/mm/proc-macros.S to be used outside the mm code move the contents of proc-macros.S to asm/assembler.h. Also, delete proc-macros.S, and fix up all references to proc-macros.S. Signed-off-by: Geoff Levand <geoff@infradead.org> Acked-by: Pavel Machek <pavel@ucw.cz> [rebased, included dcache_by_line_op] Signed-off-by: James Morse <james.morse@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/assembler.h | 82 ++++++++++++++++++++++++++++++- arch/arm64/mm/cache.S | 2 - arch/arm64/mm/proc-macros.S | 98 -------------------------------------- arch/arm64/mm/proc.S | 3 -- 4 files changed, 81 insertions(+), 104 deletions(-) commit 0e55714902857f71ce3f9144f6a73fb8321229ef Merge: f55532a 3358d2d Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 28 12:43:15 2016 +0200 Merge branch 'for-4.7/clk' into for-4.7/phy commit 2690e912644e610854c4c3b23d0a0daec9d030ca Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 8 15:17:27 2016 +0200 clk: tegra: dfll: Reformat CVB frequency table Increase the readability of the CVB frequency table by reformatting it a little. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra124-dfll-fcpu.c | 50 +++++++++++++++--------------- 1 file changed, 25 insertions(+), 25 deletions(-) commit f7c42d98621739d416cc4a739b721574fcbe910c Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 8 15:16:28 2016 +0200 clk: tegra: dfll: Properly clean up on failure and removal Upon failure to probe the DFLL, the OPP table will not be cleaned up properly. Fix this and while at it make sure the OPP table will also be cleared upon driver removal. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-dfll.h | 2 ++ drivers/clk/tegra/clk-tegra124-dfll-fcpu.c | 31 ++++++++++++++++++++++++++---- drivers/clk/tegra/cvb.c | 16 +++++++++++++++ drivers/clk/tegra/cvb.h | 3 +++ 4 files changed, 48 insertions(+), 4 deletions(-) commit e8f6a68c508b5d1cc4612ada028d87c74ab279d5 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 8 15:09:56 2016 +0200 clk: tegra: dfll: Make code more comprehensible Rename some variables and structure fields to make the code more comprehensible. Also change the prototype of internal functions to be more in line with the OPP core functions. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra124-dfll-fcpu.c | 11 +++--- drivers/clk/tegra/cvb.c | 55 +++++++++++++++--------------- drivers/clk/tegra/cvb.h | 12 +++---- 3 files changed, 37 insertions(+), 41 deletions(-) commit 27ed2f7e7ca5c38a8ce695e58e6cf270c26f370b Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 8 15:02:06 2016 +0200 clk: tegra: dfll: Reference CVB table instead of copying data Instead of copying parts of the CVB table into a separate structure, keep track of the selected CVB table and directly reference data from it. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-dfll.c | 11 ++++++----- drivers/clk/tegra/clk-dfll.h | 10 ++-------- drivers/clk/tegra/clk-tegra124-dfll-fcpu.c | 23 +++++++++-------------- 3 files changed, 17 insertions(+), 27 deletions(-) commit 8eaaae9937649f54beac7da582fa6cc6c79ae936 Author: Thierry Reding <treding@nvidia.com> Date: Fri Apr 8 14:57:09 2016 +0200 clk: tegra: dfll: Update kerneldoc The kerneldoc for struct tegra_dfll_soc_data is stale. Update it to match the current structure definition. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-dfll.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 797097301860c64b63346d068ba4fe4992bd5021 Author: Lucas Stach <dev@lynxeye.de> Date: Mon Feb 29 21:46:07 2016 +0100 clk: tegra: Fix PLL_U post divider and initial rate on Tegra30 The post divider value in the frequency table is wrong as it would lead to the PLL producing an output rate of 960 MHz instead of the desired 480 MHz. This wasn't a problem as nothing used the table to actually initialize the PLL rate, but the bootloader configuration was used unaltered. If the bootloader does not set up the PLL it will fail to come when used under Linux. To fix this don't rely on the bootloader, but set the correct rate in the clock driver. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra30.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit a02cc84a31d3bd46a10546ff7024e7b5a186d339 Author: Lucas Stach <dev@lynxeye.de> Date: Mon Feb 29 21:46:06 2016 +0100 clk: tegra: Initialize PLL_C to sane rate on Tegra30 If the bootloader does not touch PLL_C it will stay in its reset state, failing to lock when enabled. This leads to consumers of this clock to fail probing. Fix this by always programming the PLL with a sane rate, which allows it to lock, at startup. Signed-off-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra30.c | 1 + 1 file changed, 1 insertion(+) commit 926655f929063619b13db8b4f2ef8c9a08605492 Author: Rhyland Klein <rklein@nvidia.com> Date: Mon Mar 21 15:58:52 2016 -0400 clk: tegra: Fix pllre Tegra210 and add pll_re_out1 Use a new Tegra210 version of the pll_register_pllre function to allow setting the proper settings for the m and n div fields. Additionally define PLL_RE_OUT1 on Tegra210. Signed-off-by: Rhyland Klein <rklein@nvidia.com> [treding@nvidia.com: define PLLRE_OUT1 register offset] Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-pll.c | 46 ++++++++++++++++++++++++++++++++ drivers/clk/tegra/clk-tegra210.c | 16 +++++++++-- drivers/clk/tegra/clk.h | 6 +++++ include/dt-bindings/clock/tegra210-car.h | 2 +- 4 files changed, 67 insertions(+), 3 deletions(-) commit a91bb605ec5f93676e503267c89469d02c5b4cbc Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 15:13:36 2015 +0200 clk: tegra: Add sor_safe clock The sor_safe clock is a fixed factor (1:17) clock derived from pll_p. It has a gate bit in the peripheral clock registers. While the SOR is being powered up, sor_safe can be used as the source until the SOR brick can generate its own clock. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-id.h | 1 + drivers/clk/tegra/clk-tegra210.c | 4 ++++ 2 files changed, 5 insertions(+) commit eede7113aabd3f40f8d9c32b1690f2859fcb101a Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 15:10:43 2015 +0200 clk: tegra: dpaux and dpaux1 are fixed factor clocks The dpaux (on Tegra124 and Tegra210) and dpaux1 (on Tegra210) are fixed factor clocks (1:17) and derived from pll_p_out0 (pll_p). They also have a gate bit in the peripheral clock registers. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra-periph.c | 2 -- drivers/clk/tegra/clk-tegra124.c | 4 ++++ drivers/clk/tegra/clk-tegra210.c | 8 ++++++++ 3 files changed, 12 insertions(+), 2 deletions(-) commit 98c4b3661b5aee0e583d17d6304f6489c0f41155 Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 15:05:33 2015 +0200 clk: tegra: Add dpaux1 clock This clock is of the same type as dpaux and is added to feed into the second DPAUX block used in conjunction with SOR1. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-id.h | 1 + drivers/clk/tegra/clk-tegra-periph.c | 1 + drivers/clk/tegra/clk-tegra210.c | 1 + 3 files changed, 3 insertions(+) commit 3d0f4e5f7a7c9ef2d8504f2b42f9c4d3233ba707 Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 14:47:25 2015 +0200 clk: tegra: Use correct parent for dpaux clock The dpaux clock is derived from pll_p_out0 (pll_p), not clk_m. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra-periph.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1ec7032ad517714108cc53a6ee7067276ca21e80 Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 14:34:57 2015 +0200 clk: tegra: Add fixed factor peripheral clock type Some of the peripheral clocks on Tegra are derived from one of the top- level PLLs with a fixed factor. Support these clocks by implementing the ->enable() and ->disable() callbacks using the peripheral clock register banks and the ->recalc_rate() by dividing the parent rate by the fixed factor. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/Makefile | 1 + drivers/clk/tegra/clk-periph-fixed.c | 120 +++++++++++++++++++++++++++++++++++ drivers/clk/tegra/clk.h | 17 +++++ 3 files changed, 138 insertions(+) commit 07314fc108e195044c074f4b443974b5aaa2d5d7 Author: Thierry Reding <treding@nvidia.com> Date: Wed Apr 8 16:48:26 2015 +0200 clk: tegra: Special-case mipi-cal parent on Tegra114 Starting with Tegra124, the mipi-cal clock uses the 72 MHz clock as its source. On Tegra114 this clock's parent was clk_m, so it is the one-off chip. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra-periph.c | 2 +- drivers/clk/tegra/clk-tegra114.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) commit a9caa8481258576b59b46067dfd8fd6fbd72f3e3 Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 15:26:42 2015 +0200 clk: tegra: Remove trailing blank line Trailing blank lines are undesirable (several tools, such as git, complain about them), so remove it. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra-fixed.c | 1 - 1 file changed, 1 deletion(-) commit 7e14f22305b09bd57fc2da3bf2fd3bfd53dc285b Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 20 14:38:39 2015 +0200 clk: tegra: Constify peripheral clock registers The peripheral clock registers are defined in static tables. These tables never need to be modified at runtime, so they can reside in read-only memory. Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-periph-gate.c | 2 +- drivers/clk/tegra/clk-periph.c | 2 +- drivers/clk/tegra/clk-tegra-periph.c | 2 +- drivers/clk/tegra/clk.c | 4 ++-- drivers/clk/tegra/clk.h | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) commit 3358d2d9f47af86bdd71edb24b361f72a54ec04e Author: Andrew Bresticker <abrestic@chromium.org> Date: Thu Jun 18 17:28:40 2015 -0400 clk: tegra: Add interface to enable hardware control of SATA/XUSB PLLs On Tegra210, hardware control of the SATA and XUSB pad PLLs must be done during the UPHY enable sequence rather than the PLLE enable sequence. Export functions to do this so that hardware control can be enabled from the XUSB padctl driver. Signed-off-by: Andrew Bresticker <abrestic@chromium.org> Signed-off-by: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/clk/tegra/clk-tegra210.c | 58 ++++++++++++++++++++++++++++++++++++++++ include/linux/clk/tegra.h | 5 ++++ 2 files changed, 63 insertions(+) commit 36230cb5668c2633bee4ec87b58983eac3a5cb4c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 27 22:43:45 2016 +0300 drm/dp: Allow signals to interrupt drm_aux-dev reads/writes Let's be nice and interrupt the dpcd aux-dev reads/writes when there's a signal pending. Much nicer if the user can hit ^C instead of having to sit around waiting for the read/write to finish. time dd if=/dev/drm_dp_aux0 bs=$((1024*1024)) ^C before: real 0m34.681s user 0m0.003s sys 0m6.880s after: real 0m0.222s user 0m0.006s sys 0m0.057s Cc: Rafael Antognolli <rafael.antognolli@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461786225-7790-1-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/drm_dp_aux_dev.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 1a5658c213116d56a1a38e83588f6636a57d6374 Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Thu Apr 28 01:49:48 2016 +0000 ASoC: rsnd: count .probe/.remove for rsnd_mod_call() Current rsnd_mod_call is counting its calling count to avoid unbalanced function pair calling for error cases (ex init <-> quit). SSI parent is now controlled as "mod" on current rsnd driver. Because of this reason, SSI .remove function will be called twice if it was used as SSI parent when user tried unbind. But probe/remove pair were not counted. This patch counts probe/remove functions to avoid it. Special thans Hiep Reported-by: Hiep Cao Minh <cm-hiep@jinso.co.jp> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sh/rcar/rsnd.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit 078194f8e9fe3cf54c8fd8bded48a1db5bd8eb8a Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 09:39:09 2016 -0700 x86/mm, sched/core: Turn off IRQs in switch_mm() Potential races between switch_mm() and TLB-flush or LDT-flush IPIs could be very messy. AFAICT the code is currently okay, whether by accident or by careful design, but enabling PCID will make it considerably more complicated and will no longer be obviously safe. Fix it with a big hammer: run switch_mm() with IRQs off. To avoid a performance hit in the scheduler, we take advantage of our knowledge that the scheduler already has IRQs disabled when it calls switch_mm(). Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/f19baf759693c9dcae64bbff76189db77cb13398.1461688545.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/mmu_context.h | 3 +++ arch/x86/mm/tlb.c | 10 ++++++++++ 2 files changed, 13 insertions(+) commit 69c0319aabba45bcf33178916a2f06967b4adede Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 09:39:08 2016 -0700 x86/mm, sched/core: Uninline switch_mm() It's fairly large and it has quite a few callers. This may also help untangle some headers down the road. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/54f3367803e7f80b2be62c8a21879aa74b1a5f57.1461688545.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/mmu_context.h | 98 +---------------------------------- arch/x86/mm/tlb.c | 102 +++++++++++++++++++++++++++++++++++++ 2 files changed, 104 insertions(+), 96 deletions(-) commit e1074888c326038340a1ada9129d679e661f2ea6 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 09:39:07 2016 -0700 x86/mm: Build arch/x86/mm/tlb.c even on !SMP Currently all of the functions that live in tlb.c are inlined on !SMP builds. One can debate whether this is a good idea (in many respects the code in tlb.c is better than the inlined UP code). Regardless, I want to add code that needs to be built on UP and SMP kernels and relates to tlb flushing, so arrange for tlb.c to be compiled unconditionally. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/f0d778f0d828fc46e5d1946bca80f0aaf9abf032.1461688545.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/Makefile | 3 +-- arch/x86/mm/tlb.c | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-) commit f98db6013c557c216da5038d9c52045be55cd039 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 09:39:06 2016 -0700 sched/core: Add switch_mm_irqs_off() and use it in the scheduler By default, this is the same thing as switch_mm(). x86 will override it as an optimization. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/df401df47bdd6be3e389c6f1e3f5310d70e81b2c.1461688545.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/mmu_context.h | 7 +++++++ kernel/sched/core.c | 6 +++--- 2 files changed, 10 insertions(+), 3 deletions(-) commit 8efd755ac2fe262d4c8d5c9bbe054bb67dae93da Author: Ingo Molnar <mingo@kernel.org> Date: Thu Apr 28 11:39:12 2016 +0200 mm/mmu_context, sched/core: Fix mmu_context.h assumption Some architectures (such as Alpha) rely on include/linux/sched.h definitions in their mmu_context.h files. So include sched.h before mmu_context.h. Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: linux-kernel@vger.kernel.org Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@kernel.org> mm/mmu_context.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0cf0223c8370af0fcedb15a408d3c17bb4b9e21d Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:12 2016 +0100 efi/runtime-wrappers: Remove ARCH_EFI_IRQ_FLAGS_MASK #ifdef Now that arm, arm64, and x86 all provide ARCH_EFI_IRQ_FLAGS_MASK, we can get rid of the trivial and now unused implementation of efi_call_virt_check_flags(). Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-41-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/runtime-wrappers.c | 7 ------- 1 file changed, 7 deletions(-) commit 9788375dc4cdc9c00645028384fb40402eab774f Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:11 2016 +0100 x86/efi: Enable runtime call flag checking Define ARCH_EFI_IRQ_FLAGS_MASK for x86, which will enable the generic runtime wrapper code to detect when firmware erroneously modifies flags over a runtime services function call. For x86 (both 32-bit and 64-bit), we only need check the interrupt flag. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Ben Hutchings <ben@decadent.org.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Darren Hart <dvhart@infradead.org> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: David Howells <dhowells@redhat.com> Cc: Greg KH <gregkh@linuxfoundation.org> Cc: Hannes Reinecke <hare@suse.de> Cc: Harald Hoyer harald@redhat.com Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Raphael Hertzog <hertzog@debian.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-40-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/efi.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 207a90e5cbcdb0674c8a4b499c1407962c46f6d3 Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:10 2016 +0100 arm/efi: Enable runtime call flag checking Define ARCH_EFI_IRQ_FLAGS_MASK for arm, which will enable the generic runtime wrapper code to detect when firmware erroneously modifies flags over a runtime services function call. We check all allocated flags, barring those which firmware has legitimate reason to modify (condition flags and IT state). While in practice corruption of some flags (e.g. J) would already be fatal, we include these for consistency and documentation purposes. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Colin Ian King <colin.king@canonical.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-39-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 5 +++++ 1 file changed, 5 insertions(+) commit ee6cab5d4aba1df12e0386d22c5a1c4e71d34b31 Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:09 2016 +0100 arm64/efi: Enable runtime call flag checking Define ARCH_EFI_IRQ_FLAGS_MASK for arm64, which will enable the generic runtime wrapper code to detect when firmware erroneously modifies flags over a runtime services function call. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Will Deacon <will.deacon@arm.com> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-38-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm64/include/asm/efi.h | 3 +++ 1 file changed, 3 insertions(+) commit 1d04ba1796936244a514db320976f65e2605640d Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:08 2016 +0100 efi/runtime-wrappers: Detect firmware IRQ flag corruption The UEFI spec allows runtime services to be called with interrupts masked or unmasked, and if a runtime service function needs to mask interrupts, it must restore the mask to its original state before returning (i.e. from the PoV of the OS, this does not change across a call). Firmware should never unmask exceptions, as these may then be taken by the OS unexpectedly. Unfortunately, some firmware has been seen to unmask IRQs (and potentially other maskable exceptions) across runtime services calls, leaving IRQ flags corrupted after returning from a runtime services function call. This may be detected by the IRQ tracing code, but often goes unnoticed, leaving a potentially disastrous bug hidden. This patch detects when the IRQ flags are corrupted by an EFI runtime services call, logging the call and specific corruption to the console. While restoring the expected value of the flags is insufficient to avoid problems, we do so to avoid redundant warnings from elsewhere (e.g. IRQ tracing). The set of bits in flags which we want to check is architecture-specific (e.g. we want to check FIQ on arm64, but not the zero flag on x86), so each arch must provide ARCH_EFI_IRQ_FLAGS_MASK to describe those. In the absence of this mask, the check is a no-op, and we redundantly save the flags twice, but that will be short-lived as subsequent patches will implement this and remove the scaffolding. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-37-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/runtime-wrappers.c | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit d9c6e1d0faec6d750b5cc08d036e9c3da6e8e50c Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:07 2016 +0100 efi/runtime-wrappers: Remove redundant #ifdefs Now that all users of the EFI runtime wrappers (arm,arm64,x86) have been migrated to the new setup/teardown macros, we don't need to support overridden {__,}efi_call_virt() implementations. This patch removes the unnecessary #ifdefs. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-36-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/runtime-wrappers.c | 4 ---- 1 file changed, 4 deletions(-) commit bc25f9dba149a1392b016a6d35300c8d79177298 Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:06 2016 +0100 x86/efi: Move to generic {__,}efi_call_virt() Now there's a common template for {__,}efi_call_virt(), remove the duplicate logic from the x86 EFI code. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ricardo Neri <ricardo.neri-calderon@linux.intel.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-35-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/efi.h | 41 ++++++++++++----------------------------- 1 file changed, 12 insertions(+), 29 deletions(-) commit 819fc126edcb458f26e9a7fda54bfdd36dfbce06 Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:05 2016 +0100 arm/efi: Move to generic {__,}efi_call_virt() Now there's a common template for {__,}efi_call_virt(), remove the duplicate logic from the ARM EFI code. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Colin Ian King <colin.king@canonical.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-34-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) commit 489f80f72f7528d2a1b10346657a1a1a42533cea Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:04 2016 +0100 arm64/efi: Move to generic {__,}efi_call_virt() Now there's a common template for {__,}efi_call_virt(), remove the duplicate logic from the arm64 EFI code. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Will Deacon <will.deacon@arm.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-33-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm64/include/asm/efi.h | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) commit f51c35f291062df14a3e9cc5779e417fe662e50e Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 21:07:03 2016 +0100 efi/runtime-wrappers: Add {__,}efi_call_virt() templates Currently each architecture must implement two macros, efi_call_virt() and __efi_call_virt(), which only differ by the presence or absence of a return type. Otherwise, the logic surrounding the call is identical. As each architecture must define the entire body of each, we can't place any generic manipulation (e.g. irq flag validation) in the middle. This patch adds template implementations of these macros. With these, arch code can implement three template macros, avoiding reptition for the void/non-void return cases: * arch_efi_call_virt_setup() Sets up the environment for the call (e.g. switching page tables, allowing kernel-mode use of floating point, if required). * arch_efi_call_virt() Performs the call. The last expression in the macro must be the call itself, allowing the logic to be shared by the void and non-void cases. * arch_efi_call_virt_teardown() Restores the usual kernel environment once the call has returned. While the savings from repition are minimal, we additionally gain the ability to add common code around the call with the call environment set up. This can be used to detect common firmware issues (e.g. bad irq mask management). Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-32-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/runtime-wrappers.c | 40 +++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 249f7632162980b286f30166436471f8ba81fc1e Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:07:02 2016 +0100 efi/arm-init: Reserve rather than unmap the memory map for ARM as well Now that ARM has a fully functional memremap() implementation, there is no longer a need to remove the UEFI memory map from the linear mapping in order to be able to create a permanent mapping for it using generic code. So remove the 'IS_ENABLED(CONFIG_ARM)' conditional we added in: 7cc8cbcf82d1 ("efi/arm64: Don't apply MEMBLOCK_NOMAP to UEFI memory map mapping") ... and revert to using memblock_reserve() for both ARM and arm64. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-31-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/arm-init.c | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) commit 65117f1aa1b2d145fd5ca376bde642794d0aae1b Author: Kweh, Hock Leong <hock.leong.kweh@intel.com> Date: Mon Apr 25 21:07:01 2016 +0100 efi: Add misc char driver interface to update EFI firmware This patch introduces a kernel module to expose a capsule loader interface (misc char device file note) for users to upload capsule binaries. Example: cat firmware.bin > /dev/efi_capsule_loader Any upload error will be returned while doing "cat" through file operation write() function call. Signed-off-by: Kweh, Hock Leong <hock.leong.kweh@intel.com> [ Update comments and Kconfig text ] Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Bryan O'Donoghue <pure.logic@nexus-software.ie> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sam Protsenko <semen.protsenko@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-30-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/Kconfig | 10 + drivers/firmware/efi/Makefile | 1 + drivers/firmware/efi/capsule-loader.c | 343 ++++++++++++++++++++++++++++++++++ 3 files changed, 354 insertions(+) commit 87615a34d561ef59bd0cffc73256a21220dfdffd Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:07:00 2016 +0100 x86/efi: Force EFI reboot to process pending capsules If an EFI capsule has been sent to the firmware we must match the type of EFI reset against that required by the capsule to ensure it is processed correctly. Force an EFI reboot if a capsule is pending for the next reset. Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-29-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/reboot.c | 9 +++++++++ include/linux/efi.h | 6 ++++++ 2 files changed, 15 insertions(+) commit f0133f3c5b8bb34ec4dec50c27e7a655aeee8935 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:59 2016 +0100 efi: Add 'capsule' update support The EFI capsule mechanism allows data blobs to be passed to the EFI firmware. A common use case is performing firmware updates. This patch just introduces the main infrastructure for interacting with the firmware, and a driver that allows users to upload capsules will come in a later patch. Once a capsule has been passed to the firmware, the next reboot must be performed using the ResetSystem() EFI runtime service, which may involve overriding the reboot type specified by reboot=. This ensures the reset value returned by QueryCapsuleCapabilities() is used to reset the system, which is required for the capsule to be processed. efi_capsule_pending() is provided for this purpose. At the moment we only allow a single capsule blob to be sent to the firmware despite the fact that UpdateCapsule() takes a 'CapsuleCount' parameter. This simplifies the API and shouldn't result in any downside since it is still possible to send multiple capsules by repeatedly calling UpdateCapsule(). Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Bryan O'Donoghue <pure.logic@nexus-software.ie> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Mark Salter <msalter@redhat.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-28-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/Makefile | 1 + drivers/firmware/efi/capsule.c | 300 +++++++++++++++++++++++++++++++++++++++++ drivers/firmware/efi/reboot.c | 12 +- include/linux/efi.h | 14 ++ 4 files changed, 326 insertions(+), 1 deletion(-) commit 806b0351c9ff9890c1ef0ba2c46237baef49ac79 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:58 2016 +0100 efi: Move efi_status_to_err() to drivers/firmware/efi/ Move efi_status_to_err() to the architecture independent code as it's generally useful in all bits of EFI code where there is a need to convert an efi_status_t to a kernel error value. Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Kweh Hock Leong <hock.leong.kweh@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: joeyli <jlee@suse.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-27-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/efi.c | 33 +++++++++++++++++++++++++++++++++ drivers/firmware/efi/vars.c | 33 --------------------------------- include/linux/efi.h | 2 ++ 3 files changed, 35 insertions(+), 33 deletions(-) commit 06f7d4a1618dbb086e738c93cd1ef416ab01027d Author: Compostella, Jeremy <jeremy.compostella@intel.com> Date: Mon Apr 25 21:06:57 2016 +0100 efibc: Add EFI Bootloader Control module This module installs a reboot callback, such that if reboot() is invoked with a string argument NNN, "NNN" is copied to the "LoaderEntryOneShot" EFI variable, to be read by the bootloader. If the string matches one of the boot labels defined in its configuration, the bootloader will boot once to that label. The "LoaderEntryRebootReason" EFI variable is set with the reboot reason: "reboot", "shutdown". The bootloader reads this reboot reason and takes particular action according to its policy. There are reboot implementations that do "reboot <reason>", such as Android's reboot command and Upstart's reboot replacement, which pass the reason as an argument to the reboot syscall. There is no platform-agnostic way how those could be modified to pass the reason to the bootloader, regardless of platform or bootloader. Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stefan Stanacar <stefan.stanacar@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-26-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/Kconfig | 15 +++++++ drivers/firmware/efi/Makefile | 1 + drivers/firmware/efi/efibc.c | 101 ++++++++++++++++++++++++++++++++++++++++++ include/linux/efi.h | 4 ++ 4 files changed, 121 insertions(+) commit 9822504c1fa5c557ea8776765f03fd16eb4de4c9 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:56 2016 +0100 efifb: Enable the efi-framebuffer platform driver for ARM and arm64 Allows the efifb driver to be built for ARM and arm64. This simply involves updating the Kconfig dependency expression, and supplying dummy versions of efifb_setup_from_dmi(). Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-25-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 4 ++++ arch/arm64/include/asm/efi.h | 4 ++++ drivers/video/fbdev/Kconfig | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) commit e3271c96ca7d01957b03b5f1e2bdc00e08fd7160 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:55 2016 +0100 efi/arm*: Wire up 'struct screen_info' to efi-framebuffer platform device This adds code to the ARM and arm64 EFI init routines to expose a platform device of type 'efi-framebuffer' if 'struct screen_info' has been populated appropriately from the GOP protocol by the stub. Since the framebuffer may potentially be located in system RAM, make sure that the region is reserved and marked MEMBLOCK_NOMAP. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-24-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/arm-init.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit f0827e18a7a1da574ba8201a8b18f63778451aae Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:54 2016 +0100 efi/arm*/libstub: Wire up GOP protocol to 'struct screen_info' This adds the code to the ARM and arm64 versions of the UEFI stub to populate struct screen_info based on the information received from the firmware via the GOP protocol. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-23-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/libstub/arm-stub.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 801820bee9bccb7c156af2b95c7208f428a06ae7 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:53 2016 +0100 efi/arm/libstub: Make screen_info accessible to the UEFI stub In order to hand over the framebuffer described by the GOP protocol and discovered by the UEFI stub, make struct screen_info accessible by the stub. This involves allocating a loader data buffer and passing it to the kernel proper via a UEFI Configuration Table, since the UEFI stub executes in the context of the decompressor, and cannot access the kernel's copy of struct screen_info directly. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-22-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 3 +++ arch/arm/kernel/setup.c | 3 ++- drivers/firmware/efi/arm-init.c | 34 +++++++++++++++++++++++++++- drivers/firmware/efi/efi.c | 5 +++-- drivers/firmware/efi/libstub/arm32-stub.c | 37 +++++++++++++++++++++++++++++++ include/linux/efi.h | 11 ++++++++- 6 files changed, 88 insertions(+), 5 deletions(-) commit 57fdb89aeb7b0e3aab19847ab7399e5d76f11e6f Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:52 2016 +0100 arm64/efi/libstub: Make screen_info accessible to the UEFI stub Unlike on 32-bit ARM, where we need to pass the stub's version of struct screen_info to the kernel proper via a configuration table, on 64-bit ARM it simply involves making the core kernel's copy of struct screen_info visible to the stub by exposing an __efistub_ alias for it. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Will Deacon <will.deacon@arm.com> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-21-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm64/include/asm/efi.h | 3 +++ arch/arm64/kernel/efi.c | 3 +++ arch/arm64/kernel/image.h | 1 + 3 files changed, 7 insertions(+) commit 07ea7ec5df3ee4a9fedb3d81dc69c2f8d07d44c0 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:51 2016 +0100 efifb: Use builtin_platform_driver and drop unused includes Since efifb can only be built directly into the kernel, drop the module specific includes and definitions. Drop some other includes we don't need as well. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Peter Jones <pjones@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-20-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/video/fbdev/efifb.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 21289ec02b41c4b928a0b3de1778b325d714eea3 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:50 2016 +0100 x86/efi/efifb: Move DMI based quirks handling out of generic code The efifb quirks handling based on DMI identification of the platform is specific to x86, so move it to x86 arch code. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: David Herrmann <dh.herrmann@gmail.com> Acked-by: Peter Jones <pjones@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-19-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/efi.h | 2 ++ arch/x86/kernel/sysfb_efi.c | 15 +++++++++++++++ drivers/video/fbdev/efifb.c | 15 ++++----------- 3 files changed, 21 insertions(+), 11 deletions(-) commit fc37206427ce38eafbeff48099d873235e878450 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:49 2016 +0100 efi/libstub: Move Graphics Output Protocol handling to generic code The Graphics Output Protocol code executes in the stub, so create a generic version based on the x86 version in libstub so that we can move other archs to it in subsequent patches. The new source file gop.c is added to the libstub build for all architectures, but only wired up for x86. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-18-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 4 +- arch/arm64/include/asm/efi.h | 4 +- arch/x86/boot/compressed/eboot.c | 318 ------------------------------ arch/x86/boot/compressed/eboot.h | 78 -------- drivers/firmware/efi/libstub/Makefile | 2 +- drivers/firmware/efi/libstub/gop.c | 354 ++++++++++++++++++++++++++++++++++ include/linux/efi.h | 81 +++++++- 7 files changed, 441 insertions(+), 400 deletions(-) commit 2c23b73c2d0249c499c4784b6db08dcfc6b7b3b0 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:48 2016 +0100 x86/efi: Prepare GOP handling code for reuse as generic code In preparation of moving this code to drivers/firmware/efi and reusing it on ARM and arm64, apply any changes that will be required to make this code build for other architectures. This should make it easier to track down problems that this move may cause to its operation on x86. Note that the generic version uses slightly different ways of casting the protocol methods and some other variables to the correct types, since such method calls are not loosely typed on ARM and arm64 as they are on x86. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-17-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/eboot.c | 58 ++++++++++++++++++++++++---------------- arch/x86/boot/compressed/eboot.h | 4 +++ arch/x86/include/asm/efi.h | 5 ++++ include/linux/efi.h | 5 ++++ 4 files changed, 49 insertions(+), 23 deletions(-) commit c3c1c47f15b37a8492e630d1e9ab8ad576ee10e5 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:47 2016 +0100 x86/efi: Remove the always true EFI_DEBUG symbol This symbol is always set which makes it useless. Additionally we have a kernel command-line switch, efi=debug, which actually controls the printing of the memory map. Reported-by: Robert Elliott <elliott@hpe.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Borislav Petkov <bp@suse.de> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-16-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/platform/efi/efi.c | 4 ---- 1 file changed, 4 deletions(-) commit 789957ef72f976cb325e9057225fc4e9c4513060 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:46 2016 +0100 efi/arm*: Take the Memory Attributes table into account Call into the generic memory attributes table support code at the appropriate times during the init sequence so that the UEFI Runtime Services region are mapped according to the strict permissions it specifies. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-15-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm64/include/asm/efi.h | 2 ++ drivers/firmware/efi/arm-init.c | 1 + drivers/firmware/efi/arm-runtime.c | 10 ++++++++-- 3 files changed, 11 insertions(+), 2 deletions(-) commit 10f0d2f57705350bbbe5f28e9292ae3905823c3c Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:45 2016 +0100 efi: Implement generic support for the Memory Attributes table This implements shared support for discovering the presence of the Memory Attributes table, and for parsing and validating its contents. The table is validated against the construction rules in the UEFI spec. Since this is a new table, it makes sense to complain if we encounter a table that does not follow those rules. The parsing and validation routine takes a callback that can be specified per architecture, that gets passed each unique validated region, with the virtual address retrieved from the ordinary memory map. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> [ Trim pr_*() strings to 80 cols and use EFI consistently. ] Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-14-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/Makefile | 2 +- drivers/firmware/efi/memattr.c | 182 +++++++++++++++++++++++++++++++++++++++++ include/linux/efi.h | 13 +++ 3 files changed, 196 insertions(+), 1 deletion(-) commit a604af075a3226adaff84b7026876f0c6dfe9f52 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:44 2016 +0100 efi: Add support for the EFI_MEMORY_ATTRIBUTES_TABLE config table This declares the GUID and struct typedef for the new memory attributes table which contains the permissions that can be used to apply stricter permissions to UEFI Runtime Services memory regions. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-13-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/efi.c | 2 ++ include/linux/efi.h | 13 +++++++++++++ 2 files changed, 15 insertions(+) commit 1fd55a9a09b0293af95ab4299b108f030fef4464 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:43 2016 +0100 arm64/efi: Apply strict permissions to UEFI Runtime Services regions Recent UEFI versions expose permission attributes for runtime services memory regions, either in the UEFI memory map or in the separate memory attributes table. This allows the kernel to map these regions with stricter permissions, rather than the RWX permissions that are used by default. So wire this up in our mapping routine. Note that in the absence of permission attributes, we still only map regions of type EFI_RUNTIME_SERVICE_CODE with the executable bit set. Also, we base the mapping attributes of EFI_MEMORY_MAPPED_IO on the type directly rather than on the absence of the EFI_MEMORY_WB attribute. This is more correct, but is also required for compatibility with the upcoming support for the Memory Attributes Table, which only carries permission attributes, not memory type attributes. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-12-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm64/kernel/efi.c | 54 ++++++++++++++++++++++++++++++++++++------------- 1 file changed, 40 insertions(+), 14 deletions(-) commit 9fc68b717c24a215a32c1b4e05b30433cafb2599 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:42 2016 +0100 ARM/efi: Apply strict permissions for UEFI Runtime Services regions Recent UEFI versions expose permission attributes for runtime services memory regions, either in the UEFI memory map or in the separate memory attributes table. This allows the kernel to map these regions with stricter permissions, rather than the RWX permissions that are used by default. So wire this up in our mapping routine. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Jones <pjones@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-11-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/efi.h | 1 + arch/arm/kernel/efi.c | 41 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+) commit 24d45d1dc275b818093fe1d0055a230ce5e8c4c7 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:41 2016 +0100 efi/arm*: Use memremap() to create the persistent memmap mapping Instead of using ioremap_cache(), which is slightly inappropriate for mapping firmware tables, and is not even allowed on ARM for mapping regions that are covered by a struct page, use memremap(), which was invented for this purpose, and will also reuse the existing kernel direct mapping if the requested region is covered by it. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-10-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/arm-runtime.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 0d054ad96e97dcd8966e9333eabcc7a466672f70 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:40 2016 +0100 efi: Check EFI_MEMORY_DESCRIPTOR version explicitly Our efi_memory_desc_t type is based on EFI_MEMORY_DESCRIPTOR version 1 in the UEFI spec. No version updates are expected, but since we are about to introduce support for new firmware tables that use the same descriptor type, it makes sense to at least warn if we encounter other versions. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-9-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/platform/efi/efi.c | 4 ++++ drivers/firmware/efi/arm-init.c | 4 ++++ 2 files changed, 8 insertions(+) commit 884f4f66ffd6ffe632f3a8be4e6d10a858afdc37 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:39 2016 +0100 efi: Remove global 'memmap' EFI memory map Abolish the poorly named EFI memory map, 'memmap'. It is shadowed by a bunch of local definitions in various files and having two ways to access the EFI memory map ('efi.memmap' vs. 'memmap') is rather confusing. Furthermore, IA64 doesn't even provide this global object, which has caused issues when trying to write generic EFI memmap code. Replace all occurrences with efi.memmap, and convert the remaining iterator code to use for_each_efi_mem_desc(). Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Luck, Tony <tony.luck@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-8-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/platform/efi/efi.c | 84 +++++++++++++++++++++----------------- drivers/firmware/efi/arm-init.c | 20 ++++----- drivers/firmware/efi/arm-runtime.c | 12 +++--- drivers/firmware/efi/efi.c | 2 +- drivers/firmware/efi/fake_mem.c | 40 +++++++++--------- include/linux/efi.h | 5 +-- 6 files changed, 85 insertions(+), 78 deletions(-) commit 78ce248faa3c46e24e9bd42db3ab3650659f16dd Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:38 2016 +0100 efi: Iterate over efi.memmap in for_each_efi_memory_desc() Most of the users of for_each_efi_memory_desc() are equally happy iterating over the EFI memory map in efi.memmap instead of 'memmap', since the former is usually a pointer to the latter. For those users that want to specify an EFI memory map other than efi.memmap, that can be done using for_each_efi_memory_desc_in_map(). One such example is in the libstub code where the firmware is queried directly for the memory map, it gets iterated over, and then freed. This change goes part of the way toward deleting the global 'memmap' variable, which is not universally available on all architectures (notably IA64) and is rather poorly named. Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Salter <msalter@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-7-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/platform/efi/efi.c | 43 ++++++++------------------ arch/x86/platform/efi/efi_64.c | 10 ++---- arch/x86/platform/efi/quirks.c | 10 +++--- drivers/firmware/efi/arm-init.c | 4 +-- drivers/firmware/efi/arm-runtime.c | 2 +- drivers/firmware/efi/efi.c | 6 +--- drivers/firmware/efi/fake_mem.c | 3 +- drivers/firmware/efi/libstub/efi-stub-helper.c | 6 ++-- include/linux/efi.h | 11 ++++++- 9 files changed, 39 insertions(+), 56 deletions(-) commit 30d7bf034c034995f34dae265d96247f7f12044e Author: Linn Crosetto <linn@hpe.com> Date: Mon Apr 25 21:06:37 2016 +0100 efi/arm64: Check SetupMode when determining Secure Boot status According to the UEFI specification (version 2.5 Errata A, page 87): The platform firmware is operating in secure boot mode if the value of the SetupMode variable is 0 and the SecureBoot variable is set to 1. A platform cannot operate in secure boot mode if the SetupMode variable is set to 1. Check the value of the SetupMode variable when determining the state of Secure Boot. Plus also do minor cleanup, change sizeof() use to match kernel style guidelines. Signed-off-by: Linn Crosetto <linn@hpe.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Roy Franz <roy.franz@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-6-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/libstub/arm-stub.c | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) commit 73a6492589c87cd56707c8ac19eec78236c2d576 Author: Linn Crosetto <linn@hpe.com> Date: Mon Apr 25 21:06:36 2016 +0100 efi/arm64: Report unexpected errors when determining Secure Boot status Certain code in the boot path may require the ability to determine whether UEFI Secure Boot is definitely enabled, for example printing status to the console. Other code may need to know when UEFI Secure Boot is definitely disabled, for example restricting use of kernel parameters. If an unexpected error is returned from GetVariable() when querying the status of UEFI Secure Boot, return an error to the caller. This allows the caller to determine the definite state, and to take appropriate action if an expected error is returned. Signed-off-by: Linn Crosetto <linn@hpe.com> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Roy Franz <roy.franz@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-5-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/libstub/arm-stub.c | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit 7fc8442f2a8a77f40565b42c41e4f2d48b179a56 Author: Matt Fleming <matt@codeblueprint.co.uk> Date: Mon Apr 25 21:06:35 2016 +0100 x86/mm/pat: Document the (currently) EFI-only code path It's not at all obvious that populate_pgd() and friends are only executed when mapping EFI virtual memory regions or that no other pageattr callers pass a ->pgd value. Reported-by: Andy Lutomirski <luto@amacapital.net> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-4-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/pageattr.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 14c43be60166981f0b1f034ad9c59252c6f99e0d Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:34 2016 +0100 efi/arm*: Drop writable mapping of the UEFI System table Commit: 2eec5dedf770 ("efi/arm-init: Use read-only early mappings") updated the early ARM UEFI init code to create the temporary, early mapping of the UEFI System table using read-only attributes, as a hardening measure against inadvertent modification. However, this still leaves the permanent, writable mapping of the UEFI System table, which is only ever referenced during invocations of UEFI Runtime Services, at which time the UEFI virtual mapping is available, which also covers the system table. (This is guaranteed by the fact that SetVirtualAddressMap(), which is a runtime service itself, converts various entries in the table to their virtual equivalents, which implies that the table must be covered by a RuntimeServicesData region that has the EFI_MEMORY_RUNTIME attribute.) So instead of creating this permanent mapping, record the virtual address of the system table inside the UEFI virtual mapping, and dereference that when accessing the table. This protects the contents of the system table from inadvertent (or deliberate) modification when no UEFI Runtime Services calls are in progress. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-3-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/firmware/efi/arm-init.c | 2 ++ drivers/firmware/efi/arm-runtime.c | 27 ++++++++++++++++----------- 2 files changed, 18 insertions(+), 11 deletions(-) commit c5b591e96db9d99d0126acf93f24e1fb8b368343 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 25 21:06:33 2016 +0100 efi: Get rid of the EFI_SYSTEM_TABLES status bit The EFI_SYSTEM_TABLES status bit is set by all EFI supporting architectures upon discovery of the EFI system table, but the bit is never tested in any code we have in the tree. So remove it. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk> Cc: Borislav Petkov <bp@alien8.de> Cc: Leif Lindholm <leif.lindholm@linaro.org> Cc: Luck, Tony <tony.luck@intel.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-2-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/ia64/kernel/efi.c | 2 -- arch/x86/platform/efi/efi.c | 2 -- drivers/firmware/efi/arm-runtime.c | 1 - include/linux/efi.h | 1 - 4 files changed, 6 deletions(-) commit 88f10e37e150569a390be7a6161fa0f26b7372e9 Author: Andy Lutomirski <luto@kernel.org> Date: Tue Apr 26 09:39:05 2016 -0700 sched/core, ARM: Include linux/preempt.h from asm/mmu_context.h arm's mmu_context.h uses preempt_enable_no_resched and but doesn't include anything that would pull in the declaration. If I start including <asm/mmu_context.h> from <linux/mmu_context.h> without this, the build breaks. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Borislav Petkov <bp@alien8.de> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/5b95730a70f2dafe12d4fbf38d20eb7330d67ba3.1461688545.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/include/asm/mmu_context.h | 1 + 1 file changed, 1 insertion(+) commit 14b05c5106312744badb463e7fb9a78811e44fc0 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:30 2016 -0400 btrfs: uapi/linux/btrfs_tree.h, use __u8 and __u64 u8 and u64 aren't exported to userspace, while __u8 and __u64 are. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> include/uapi/linux/btrfs_tree.h | 52 ++++++++++++++++++++--------------------- 1 file changed, 26 insertions(+), 26 deletions(-) commit db6711600e27c885aed89751f04e727f3af26715 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:29 2016 -0400 btrfs: uapi/linux/btrfs_tree.h migration, item types and defines The BTRFS_IOC_SEARCH_TREE ioctl returns file system items directly to userspace. In order to decode them, full type information is required. Create a new header, btrfs_tree to contain these since most users won't need them. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 949 +-------------------------------------- include/uapi/linux/btrfs_tree.h | 966 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 967 insertions(+), 948 deletions(-) commit 33ca913349962208e13e894ada99b9ae6e0080ee Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:28 2016 -0400 btrfs: uapi/linux/btrfs.h migration, move struct btrfs_ioctl_defrag_range_args struct btrfs_ioctl_defrag_range_args is used by the BTRFS_IOC_DEFRAG_RANGE ioctl. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 31 ------------------------------- include/uapi/linux/btrfs.h | 38 +++++++++++++++++++++++++++++++++++++- 2 files changed, 37 insertions(+), 32 deletions(-) commit 04cd01dffbf9be14ccc51595280c8dc8c318a9c9 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:27 2016 -0400 btrfs: uapi/linux/btrfs.h migration, move balance flags The BTRFS_BALANCE_* flags are used by struct btrfs_ioctl_balance_args.flags and btrfs_ioctl_balance_args.{data,meta,sys}.flags in the BTRFS_IOC_BALANCE ioctl. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.h | 46 --------------------------------- include/uapi/linux/btrfs.h | 64 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 64 insertions(+), 46 deletions(-) commit 18db9ac644badcb948a623791e599672edade6dd Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:26 2016 -0400 btrfs: uapi/linux/btrfs.h migration, move feature flags The compat/compat_ro/incompat feature flags are used by the feature set/get ioctls. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 25 ------------------------- include/uapi/linux/btrfs.h | 31 +++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 25 deletions(-) commit 884f6eca59475bc3cad5c22360523a1261bd5597 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:25 2016 -0400 btrfs: uapi/linux/btrfs.h migration, document subvol flags Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> include/uapi/linux/btrfs.h | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) commit 83288b60bf6668933689078973136e0c9d387b38 Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:24 2016 -0400 btrfs: uapi/linux/btrfs.h migration, qgroup limit flags The BTRFS_QGROUP_LIMIT_* flags are required to tell the kernel which fields are valid when using the BTRFS_IOC_QGROUP_LIMIT ioctl. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 8 -------- include/uapi/linux/btrfs.h | 22 +++++++++++++++++++++- 2 files changed, 21 insertions(+), 9 deletions(-) commit d4ae133b2d195d88cf5394072724adfa6ccdd64b Author: Jeff Mahoney <jeffm@suse.com> Date: Fri Apr 1 16:14:23 2016 -0400 btrfs: uapi/linux/btrfs.h migration, move BTRFS_LABEL_SIZE BTRFS_LABEL_SIZE is required to define the BTRFS_IOC_GET_FSLABEL and BTRFS_IOC_SET_FSLABEL ioctls. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Reviewed-by: Liu Bo <bo.li.liu@oracle.com> Reviewed-by: Josef Bacik <jbacik@fb.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 1 - include/uapi/linux/btrfs.h | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) commit 81b785f3e4114ed74fceb48a54e7de2f797a2ba1 Author: Kees Cook <keescook@chromium.org> Date: Tue Apr 26 14:46:06 2016 -0700 x86/boot: Rename overlapping memcpy() to memmove() Instead of having non-standard memcpy() behavior, explicitly call the new function memmove(), make it available to the decompressors, and switch the two overlap cases (screen scrolling and ELF parsing) to use memmove(). Additionally documents the purpose of compressed/string.c. Suggested-by: Lasse Collin <lasse.collin@tukaani.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/20160426214606.GA5758@www.outflux.net Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/misc.c | 6 ++++-- arch/x86/boot/compressed/string.c | 19 +++++++++++-------- 2 files changed, 15 insertions(+), 10 deletions(-) commit 52bbe141f37f093e2c612e97c40d27422e5a1fdf Author: Kyeongmin Cho <korea.drzix@gmail.com> Date: Thu Apr 28 02:06:49 2016 +0900 gitignore: fix wording Git files are the files that we don't want to ignore even if they are dot-files. It must be "even if" but it says "even it". Signed-off-by: Kyeongmin Cho <korea.drzix@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c094cf13e5e6c1b9b52c079804c947d3c1b57b86 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Apr 25 22:42:25 2016 +0100 mfd: ab8500-debugfs: fix "between" in printk fix spelling mistake, beetween -> between Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/mfd/ab8500-debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b5255456c529155730c837f8cfcea47e8feb85ca Author: Anand Jain <anand.jain@oracle.com> Date: Thu Mar 24 18:48:14 2016 +0800 btrfs: refactor btrfs_dev_replace_start for reuse A refactor patch, and avoids user input verification in the btrfs_dev_replace_start(), and so this function can be reused. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 58 ++++++++++++++++++++++++++++++++------------------ fs/btrfs/dev-replace.h | 4 +++- fs/btrfs/ioctl.c | 2 +- 3 files changed, 41 insertions(+), 23 deletions(-) commit fc23c246d72d21385be115305d1cb85fcc34acad Author: Anand Jain <anand.jain@oracle.com> Date: Thu Mar 24 18:48:12 2016 +0800 btrfs: use fs_info directly Local variable fs_info, contains root->fs_info, use it. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 735654ea91a06a30bfe05fdfd09c8895abf6c1bf Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 18:15:21 2016 +0100 btrfs: rename flags for vol args v2 Rename BTRFS_DEVICE_BY_ID so it's more descriptive that we specify the device by id, it'll be part of the public API. The mask of supported flags is also renamed, only for internal use. The error code for unknown flags is EOPNOTSUPP, fixed. Reviewed-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 8 ++++---- include/uapi/linux/btrfs.h | 7 ++++--- 2 files changed, 8 insertions(+), 7 deletions(-) commit 5c5c0df05deaebcdcc9bb31bdca3812a7c22230f Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 16:39:55 2016 +0100 btrfs: rename btrfs_find_device_by_user_input For clarity how we are going to find the device, let's call it a device specifier, devspec for short. Also rename the arguments that are a leftover from previous function purpose. Reviewed-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 2 +- fs/btrfs/volumes.c | 17 ++++++++++------- fs/btrfs/volumes.h | 4 ++-- 3 files changed, 13 insertions(+), 10 deletions(-) commit 418775a22b4c67bd15915e043c3a8f29816799bd Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 16:28:14 2016 +0100 btrfs: use existing device constraints table btrfs_raid_array We should avoid duplicating the device constraints, let's use the btrfs_raid_array in btrfs_check_raid_min_devices. Reviewed-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) commit 621292bae6ae3b25cd3124b63603d01df4cccfb6 Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 16:28:03 2016 +0100 btrfs: introduce raid-type to error-code table, for minimum device constraint Reviewed-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 15 +++++++++++++++ fs/btrfs/volumes.h | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) commit 3cc31a0d5bc77e35229671307eba5ea5c4c4cb9d Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 16:00:26 2016 +0100 btrfs: pass number of devices to btrfs_check_raid_min_devices Before this patch, btrfs_check_raid_min_devices would do an off-by-one check of the constraints and not the miminmum check, as its name suggests. This is not a problem if the only caller is device remove, but would be confusing for others. Add an argument with the exact number and let the caller(s) decide if this needs any adjustments, like when device replace is running. Reviewed-by: Anand Jain <anand.jain@oracle.com> Tested-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 35 ++++++++++++++++++++--------------- 1 file changed, 20 insertions(+), 15 deletions(-) commit f47ab2588e424cb4898b75ace1e2323ddd18b990 Author: David Sterba <dsterba@suse.com> Date: Mon Feb 15 15:28:48 2016 +0100 btrfs: rename __check_raid_min_devices Underscores are for special functions, use the full prefix for better stacktrace recognition. Reviewed-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 02feae3c5525771878461b90edd2ba38fd3f5359 Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:40 2016 +0800 btrfs: optimize check for stale device Optimize check for stale device to only be checked when there is device added or changed. If there is no update to the device, there is no need to call btrfs_free_stale_device(). Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 6b526ed70cf189660d009ea6f17af77a9cca0f38 Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:39 2016 +0800 btrfs: introduce device delete by devid This introduces new ioctl BTRFS_IOC_RM_DEV_V2, which uses enhanced struct btrfs_ioctl_vol_args_v2 to carry devid as an user argument. The patch won't delete the old ioctl interface and so kernel remains backward compatible with user land progs. Test case/script: echo "0 $(blockdev --getsz /dev/sdf) linear /dev/sdf 0" | dmsetup create bad_disk mkfs.btrfs -f -d raid1 -m raid1 /dev/sdd /dev/sde /dev/mapper/bad_disk mount /dev/sdd /btrfs dmsetup suspend bad_disk echo "0 $(blockdev --getsz /dev/sdf) error /dev/sdf 0" | dmsetup load bad_disk dmsetup resume bad_disk echo "bad disk failed. now deleting/replacing" btrfs dev del 3 /btrfs echo $? btrfs fi show /btrfs umount /btrfs btrfs-show-super /dev/sdd | egrep num_device dmsetup remove bad_disk wipefs -a /dev/sdf Signed-off-by: Anand Jain <anand.jain@oracle.com> Reported-by: Martin <m_btrfs@ml1.co.uk> [ adjust messages, s/disk/device/ ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 58 +++++++++++++++++++++++++++++++++++++++++++++- fs/btrfs/volumes.c | 4 ++-- fs/btrfs/volumes.h | 2 +- include/uapi/linux/btrfs.h | 14 ++++++++++- 4 files changed, 73 insertions(+), 5 deletions(-) commit 42b674271566c26692c32f4ec1f4b4cf14d5046f Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:38 2016 +0800 btrfs: make use of btrfs_scratch_superblocks() in btrfs_rm_device() With the previous patches now the btrfs_scratch_superblocks() is ready to be used in btrfs_rm_device() so use it. Signed-off-by: Anand Jain <anand.jain@oracle.com> [ use GFP_KERNEL ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 77 +++++++++--------------------------------------------- 1 file changed, 13 insertions(+), 64 deletions(-) commit b3d1b1532ff9620ff5dba891a96f3e912005eb10 Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:37 2016 +0800 btrfs: enhance btrfs_find_device_by_user_input() to check device path The operation of device replace and device delete follows same steps upto some depth with in btrfs kernel, however they don't share codes. This enhancement will help replace and delete to share codes. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 4 ---- fs/btrfs/volumes.c | 3 +++ 2 files changed, 3 insertions(+), 4 deletions(-) commit 24fc572fe456c02ff4136c07861a3edd4b8de683 Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:36 2016 +0800 btrfs: make use of btrfs_find_device_by_user_input() btrfs_rm_device() has a section of the code which can be replaced btrfs_find_device_by_user_input() Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 100 ++++++++++++++++++++--------------------------------- 1 file changed, 37 insertions(+), 63 deletions(-) commit 24e0474b59538cdb9d2b7318ec7c7ae9f6faf85d Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:35 2016 +0800 btrfs: create helper btrfs_find_device_by_user_input() The patch renames btrfs_dev_replace_find_srcdev() to btrfs_find_device_by_user_input() and moves it to volumes.c, so that delete device can use it. Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/dev-replace.c | 24 +----------------------- fs/btrfs/volumes.c | 19 +++++++++++++++++++ fs/btrfs/volumes.h | 3 +++ 3 files changed, 23 insertions(+), 23 deletions(-) commit bd45ffbcb1f082e3c5a0bd56b1d7310d8b707ffb Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:34 2016 +0800 btrfs: clean up and optimize __check_raid_min_device() __check_raid_min_device() which was pealed from btrfs_rm_device() maintianed its original code to show the block move. This patch cleans up __check_raid_min_device(). Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 43 +++++++++++++++++++------------------------ 1 file changed, 19 insertions(+), 24 deletions(-) commit f1fa7f264250f2cb60119aca3fd114c3f47070c2 Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:33 2016 +0800 btrfs: create helper function __check_raid_min_devices() move a section of btrfs_rm_device() code to check for min number of the devices into the function __check_raid_min_devices() Signed-off-by: Anand Jain <anand.jain@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 51 ++++++++++++++++++++++++++++++++------------------- 1 file changed, 32 insertions(+), 19 deletions(-) commit 6cf86a006be9f2a77434d5a06ea289719815ad7c Author: Anand Jain <anand.jain@oracle.com> Date: Sat Feb 13 10:01:29 2016 +0800 btrfs: create a helper function to read the disk super A part of code from btrfs_scan_one_device() is moved to a new function btrfs_read_disk_super(), so that former function looks cleaner. (In this process it also moves the code which ensures null terminating label). So this creates easy opportunity to merge various duplicate codes on read disk super. Earlier attempt to merge duplicate codes highlighted that there were some issues for which there are duplicate codes (to read disk super), however it was not clear what was the issue. So until we figure that out, its better to keep them in a separate functions. Signed-off-by: Anand Jain <anand.jain@oracle.com> [ use GFP_KERNEL, PAGE_CACHE_ removal related fixups ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 87 ++++++++++++++++++++++++++++++++---------------------- 1 file changed, 52 insertions(+), 35 deletions(-) commit 6951c585228112a299e8d2b023ee4953831bd6b4 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 23:28:48 2016 +0100 memstick: trivial fix of spelling mistake on management fix spelling mistake, managment -> management in literal strings, in a variable and a macro. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/memstick/core/ms_block.c | 16 ++++++++-------- drivers/memstick/core/ms_block.h | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) commit 5db4298133d99b3dfc60d6899ac9df169769c899 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Apr 26 10:22:08 2016 -0700 lcoking/locktorture: Simplify the torture_runnable computation This commit replaces an #ifdef with IS_ENABLED(), saving five lines. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: corbet@lwn.net Cc: dave@stgolabs.net Cc: dhowells@redhat.com Cc: linux-doc@vger.kernel.org Cc: will.deacon@arm.com Link: http://lkml.kernel.org/r/1461691328-5429-4-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/locktorture.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 3cfe2e8bc1cf74d78df6fe5ca3a1e1805472a004 Author: Will Deacon <will.deacon@arm.com> Date: Tue Apr 26 10:22:07 2016 -0700 locking/Documentation: Clarify that ACQUIRE applies to loads, RELEASE applies to stores For compound atomics performing both a load and a store operation, make it clear that _acquire and _release variants refer only to the load and store portions of compound atomic. For example, xchg_acquire is an xchg operation where the load takes on ACQUIRE semantics. Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: corbet@lwn.net Cc: dave@stgolabs.net Cc: dhowells@redhat.com Cc: linux-doc@vger.kernel.org Link: http://lkml.kernel.org/r/1461691328-5429-3-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 5 +++++ 1 file changed, 5 insertions(+) commit 8d4840e84871847ee1bae56a776907d08a9265f7 Author: David Howells <dhowells@redhat.com> Date: Tue Apr 26 10:22:06 2016 -0700 locking/Documentation: State purpose of memory-barriers.txt There has been some confusion about the purpose of memory-barriers.txt, so this commit adds a statement of purpose. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: corbet@lwn.net Cc: dave@stgolabs.net Cc: linux-doc@vger.kernel.org Cc: will.deacon@arm.com Link: http://lkml.kernel.org/r/1461691328-5429-2-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit e7720af5f9ac914577e2b810d5c004cdf395fd82 Author: Peter Zijlstra <peterz@infradead.org> Date: Tue Apr 26 10:22:05 2016 -0700 locking/Documentation: Add disclaimer It appears people are reading this document as a requirements list for building hardware. This is not the intent of this document. Nor is it particularly suited for this purpose. The primary purpose of this document is our collective attempt to define a set of primitives that (hopefully) allow us to write correct code on the myriad of SMP platforms Linux supports. Its a definite work in progress as our understanding of these platforms, and memory ordering in general, progresses. Nor does being mentioned in this document mean we think its a particularly good idea; the data dependency barrier required by Alpha being a prime example. Yes we have it, no you're insane to require it when building new hardware. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: corbet@lwn.net Cc: dave@stgolabs.net Cc: dhowells@redhat.com Cc: linux-doc@vger.kernel.org Cc: will.deacon@arm.com Link: http://lkml.kernel.org/r/1461691328-5429-1-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit 676fb3240df3e12d55bbf29bff032bf9494bca28 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Apr 27 12:11:47 2016 +0100 drm: Quiet down drm_mode_getresources The debug logging here can be very verbose in the kernel logs and provides no information which userspace doesn't have the access to already. Turn it off so kernel logs become more manageable. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461755507-30453-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/drm_crtc.c | 10 ---------- 1 file changed, 10 deletions(-) commit e4cef28bff0dce91136c01e86463b780498cf30f Author: Colin Ian King <colin.king@canonical.com> Date: Mon Apr 25 22:37:16 2016 +0100 cpupowerutils: bench: fix "average" fix spelling mistake, avarage -> average Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> tools/power/cpupower/bench/README-BENCH | 2 +- tools/power/cpupower/bench/benchmark.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 3849bef34d1a88e0775925f2d11d79717f4b082e Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Apr 27 11:07:02 2016 +0100 drm: Quiet down drm_mode_getconnector Debug logging in this function does not provide any information apart that the userspace is calling an ioctl on the connector. There is not any info on the connector provided at all and since there are other ioctls userspace typically calls which do log useful things about the same connectors, remove this one to make things a little bit more readable when KMS debugging is turned on. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461751622-26927-10-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/drm_crtc.c | 2 -- 1 file changed, 2 deletions(-) commit c01e01597cbd0cf0571c2b05bf9e2245afb4478d Author: Masanari Iida <standby24x7@gmail.com> Date: Wed Apr 20 00:27:33 2016 +0900 treewide: Fix typos in printk This patch fix spelling typos in printk from various part of the codes. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/powerpc/kernel/mce.c | 2 +- drivers/clk/tegra/clk-tegra20.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 4 ++-- drivers/infiniband/hw/cxgb3/iwch_cm.c | 2 +- drivers/input/touchscreen/cyttsp4_core.c | 2 +- drivers/net/ethernet/broadcom/bgmac.c | 2 +- drivers/net/ethernet/freescale/fman/fman.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/health.c | 4 ++-- drivers/platform/mips/cpu_hwmon.c | 6 +++--- drivers/scsi/qla2xxx/qla_sup.c | 2 +- drivers/target/iscsi/iscsi_target_auth.c | 2 +- drivers/watchdog/watchdog_core.c | 2 +- 12 files changed, 16 insertions(+), 16 deletions(-) commit 35fc7b7dacc1f9bd6bdb5190cd6d355b7c5414d2 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Apr 25 20:26:50 2016 +0100 IB/mlx4: printk fix fix spelling mistake, argumant -> argument Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/infiniband/hw/mlx4/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5e0ec14e2f84b62182d9be00f2595302424a7e03 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 23:02:09 2016 +0100 pinctrl: sirf/atlas7: fix printk spelling fix spelling mistake, flaged -> flagged Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/pinctrl/sirf/pinctrl-atlas7.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2a28900be20640fcd1e548b1e3bad79e8221fcf9 Author: Jan Kara <jack@suse.cz> Date: Thu Apr 28 10:40:09 2016 +0200 udf: Export superblock magic to userspace Currently UDF superblock magic doesn't appear in any userspace header files and thus userspace apps have hard time checking for this fs. Let's export the magic to userspace as with any other filesystem. Signed-off-by: Jan Kara <jack@suse.cz> fs/udf/udf_sb.h | 4 +--- include/uapi/linux/magic.h | 2 ++ 2 files changed, 3 insertions(+), 3 deletions(-) commit cf25ce518e8ef9d59b292e51193bed2b023a32da Author: Liu Bo <bo.li.liu@oracle.com> Date: Mon Dec 14 18:29:32 2015 -0800 Btrfs: do not create empty block group if we have allocated data Now we force to create empty block group to keep data profile alive, however, in the below example, we eventually get an empty block group while we're trying to get more space for other types (metadata/system), - Before, block group "A": size=2G, used=1.2G block group "B": size=2G, used=512M - After "btrfs balance start -dusage=50 mount_point", block group "A": size=2G, used=(1.2+0.5)G block group "C": size=2G, used=0 Since there is no data in block group C, it won't be deleted automatically and we have to get the unused 2G until the next mount. Balance itself just moves data and doesn't remove data, so it's safe to not create such a empty block group if we already have data allocated in other block groups. Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/volumes.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit a2af23b7d7cb0de89570e97da84f6fb642e990a4 Author: Chandan Rajendra <chandan@linux.vnet.ibm.com> Date: Mon Apr 4 02:53:06 2016 +0530 Btrfs: __btrfs_buffered_write: Pass valid file offset when releasing delalloc space The delalloc reserved space is calculated in terms of number of bytes used by an integral number of blocks. This is done by rounding down the value of 'pos' to the nearest multiple of sectorsize. The file offset value held by 'pos' variable may not be aligned to sectorsize and hence when passing it as an argument to btrfs_delalloc_release_space(), we may end up releasing larger delalloc space than we originally had reserved. Signed-off-by: Chandan Rajendra <chandan@linux.vnet.ibm.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/file.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 894b36e35ae01186b77b083f3f67569a349062a6 Author: Liu Bo <bo.li.liu@oracle.com> Date: Mon Mar 7 16:56:22 2016 -0800 Btrfs: cleanup error handling in extent_write_cached_pages Now that we bail out immediately if ->writepage() returns an error, we don't need an extra error to retain the error code. Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit a91326679f2a0a4c239cd643674fdcda28ee86be Author: Liu Bo <bo.li.liu@oracle.com> Date: Mon Mar 7 16:56:21 2016 -0800 Btrfs: make mapping->writeback_index point to the last written page If sequential writer is writing in the middle of the page and it just redirties the last written page by continuing from it. In the above case this can end up with seeking back to that firstly redirtied page after writing all the pages at the end of file because btrfs updates mapping->writeback_index to 1 past the current one. For non-cow filesystems, the cost is only about extra seek, while for cow filesystems such as btrfs, it means unnecessary fragments. To avoid it, we just need to continue writeback from the last written page. This also updates btrfs to behave like what write_cache_pages() does, ie, bail out immediately if there is an error in writepage(). <Ref: https://www.spinics.net/lists/linux-btrfs/msg52628.html> Reported-by: Holger Hoffstätte <holger.hoffstaette@googlemail.com> Signed-off-by: Liu Bo <bo.li.liu@oracle.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent_io.c | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) commit 1d4093d3b3a70b947822cca76d6e4132767ce089 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:36:54 2016 +0100 locking/Documentation/lockdep: Fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461566229-4717-2-git-send-email-eric@engestrom.ch Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/locking/lockdep-design.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4c63c2454eff996c5e27991221106eb511f7db38 Author: Luke Dashjr <luke@dashjr.org> Date: Thu Oct 29 08:22:21 2015 +0000 btrfs: bugfix: handle FS_IOC32_{GETFLAGS,SETFLAGS,GETVERSION} in btrfs_ioctl 32-bit ioctl uses these rather than the regular FS_IOC_* versions. They can be handled in btrfs using the same code. Without this, 32-bit {ch,ls}attr fail. Signed-off-by: Luke Dashjr <luke-jr+git@utopios.org> Cc: stable@vger.kernel.org Reviewed-by: Josef Bacik <jbacik@fb.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 1 + fs/btrfs/file.c | 2 +- fs/btrfs/inode.c | 2 +- fs/btrfs/ioctl.c | 21 +++++++++++++++++++++ 4 files changed, 24 insertions(+), 2 deletions(-) commit 594dd290cf5403a9a5818619dfff42d8e8e0518e Author: Wanpeng Li <wanpeng.li@hotmail.com> Date: Fri Apr 22 17:07:24 2016 +0800 sched/cpufreq: Optimize cpufreq update kicker to avoid update multiple times Sometimes delta_exec is 0 due to update_curr() is called multiple times, this is captured by: u64 delta_exec = rq_clock_task(rq) - curr->se.exec_start; This patch optimizes the cpufreq update kicker by bailing out when nothing changed, it will benefit the upcoming schedutil, since otherwise it will (over)react to the special util/max combination. Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461316044-9520-1-git-send-email-wanpeng.li@hotmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/deadline.c | 8 ++++---- kernel/sched/rt.c | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) commit 3521ba1cc351e80488c3f85748c92c3853b75818 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Sun Apr 17 15:03:01 2016 -0700 powercap, perf/x86/intel/rapl: Add PSys support Skylake processor supports a new set of RAPL registers for controlling entire SoC instead of just CPU package. This is useful for thermal and power control when source of power/thermal is not just CPU/GPU. This change adds a new platform domain (AKA PSys) to the current power capping Intel RAPL driver. PSys also supports PL1 (long term) and PL2 (short term) control like package domain. This also follows same MSRs for energy and time units as package domain. Unlike package domain, PSys support requires more than just processor level implementation. The other parts in the system need additional implementation, which OEMs needs to support. So not all Skylake systems will support PSys. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: bp@alien8.de Cc: hpa@zytor.com Cc: jacob.jun.pan@linux.intel.com Cc: rjw@rjwysocki.net Link: http://lkml.kernel.org/r/1460930581-29748-3-git-send-email-srinivas.pandruvada@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> drivers/powercap/intel_rapl.c | 69 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) commit 180e4d4700b1b7bfdffd9e58ae95220ae9482d17 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Mon Apr 4 15:31:22 2016 +0100 btrfs: fix typos in comments Correct a typo in the chunk_mutex name to make it grepable. Since it is better to fix several typos at once, fixing the 2 more in the same file. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/super.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 6719afdcf808b38145095b2e485c0f90bfc29722 Author: Geert Uytterhoeven <geert@linux-m68k.org> Date: Sun Jun 22 14:30:09 2014 +0200 Btrfs: Refactor btrfs_lock_cluster() to kill compiler warning fs/btrfs/extent-tree.c: In function ‘btrfs_lock_cluster’: fs/btrfs/extent-tree.c:6399: warning: ‘used_bg’ may be used uninitialized in this function - Replace "again: ... goto again;" by standard C "while (1) { ... }", - Move block not processed during the first iteration of the loop to the end of the loop, which allows to kill the "locked" variable, Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Reviewed-and-Tested-by: Miao Xie <miaox@cn.fujitsu.com> [ the compilation warning has been fixed by other patch, now we want to clean up the function ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/extent-tree.c | 41 ++++++++++++++++++++--------------------- 1 file changed, 20 insertions(+), 21 deletions(-) commit 0713d90c75745dc6148f6346d490e9ef63a4e8b4 Author: Anand Jain <anand.jain@oracle.com> Date: Thu Mar 17 10:38:57 2016 +0800 btrfs: remove save_error_info() Actually save_error_info() sets the FS state to error and nothing else. Further the word save doesn't induce caffeine when compared to the word set in what actually it does. So to make it better understandable move save_error_info() code to its only consumer itself. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/super.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit 13f48dc9094b56c5bffd8d57349a0a01a1926b2d Author: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Date: Tue Mar 15 09:09:59 2016 +0900 btrfs: Simplify conditions about compress while mapping btrfs flags to inode flags Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ioctl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c5f4ccb2f77355ac44433feb362fecd7f1a7d03e Author: Anand Jain <anand.jain@oracle.com> Date: Wed Mar 16 16:43:08 2016 +0800 btrfs: move error handling code together in ctree.h Looks like we added the incompatible defines in between the error handling defines in the file ctree.h. Now group them back. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 78 +++++++++++++++++++++++++++++--------------------------- 1 file changed, 40 insertions(+), 38 deletions(-) commit 2351d743f6b69d289f04246127c9d92516621974 Author: Anand Jain <anand.jain@oracle.com> Date: Wed Mar 16 16:43:07 2016 +0800 btrfs: remove unused function btrfs_assert() Apparently looks like ASSERT does the same intended job, as intended btrfs_assert(). Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.h | 1 - 1 file changed, 1 deletion(-) commit 34d9700702f4042ce10d68a092ab7f79575e7a3b Author: Anand Jain <anand.jain@oracle.com> Date: Wed Mar 16 16:43:06 2016 +0800 btrfs: rename btrfs_std_error to btrfs_handle_fs_error btrfs_std_error() handles errors, puts FS into readonly mode (as of now). So its good idea to rename it to btrfs_handle_fs_error(). Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> [ edit changelog ] Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/ctree.c | 6 +++--- fs/btrfs/ctree.h | 6 +++--- fs/btrfs/disk-io.c | 8 ++++---- fs/btrfs/extent-tree.c | 2 +- fs/btrfs/inode-item.c | 2 +- fs/btrfs/ioctl.c | 2 +- fs/btrfs/relocation.c | 2 +- fs/btrfs/root-tree.c | 4 ++-- fs/btrfs/super.c | 6 +++--- fs/btrfs/transaction.c | 2 +- fs/btrfs/tree-log.c | 8 ++++---- fs/btrfs/volumes.c | 14 +++++++------- 12 files changed, 31 insertions(+), 31 deletions(-) commit 0b20e59cef927b030c2e626f40fc4965bacec847 Merge: a8944c5 cf3beb7 Author: Ingo Molnar <mingo@kernel.org> Date: Thu Apr 28 10:35:17 2016 +0200 Merge branch 'perf/urgent' into perf/core, to resolve conflict Conflicts: arch/x86/events/intel/pt.c Signed-off-by: Ingo Molnar <mingo@kernel.org> commit d04a75af450782db2937603bb6706bf6fa7c6f37 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 14:59:10 2016 +0200 clk: renesas: cpg-mssr: Use always-on governor for Clock Domain As a pure Clock Domain does not have the concept of powering the domain itself, the CPG/MSTP driver does not provide power_off() and power_on() callbacks. However, the genpd core may still perform a dummy power down, causing /sys/kernel/debug/pm_genpd/pm_genpd_summary to report the domain's status being "off-0". Use the always-on governor to make sure the domain is never powered down, and always shows up as "on" in pm_genpd_summary. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/clk/renesas/renesas-cpg-mssr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 93662500a1fcc9c8085ac3f056b537d093fd4d20 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 14:46:51 2016 +0200 clk: renesas: cpg-mssr: Postpone call to pm_genpd_init() All local setup of the generic_pm_domain structure should have been completed before calling pm_genpd_init(). Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/clk/renesas/renesas-cpg-mssr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 20729300cabdad60333e52278bd2dd25e5d85518 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 14:57:29 2016 +0200 clk: renesas: mstp: Use always-on governor for Clock Domain As a pure Clock Domain does not have the concept of powering the domain itself, the CPG/MSTP driver does not provide power_off() and power_on() callbacks. However, the genpd core may still perform a dummy power down, causing /sys/kernel/debug/pm_genpd/pm_genpd_summary to report the domain's status being "off-0". Use the always-on governor to make sure the domain is never powered down, and always shows up as "on" in pm_genpd_summary. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/clk/renesas/clk-mstp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3a52d75bc91d2c7299e721c0fb41c33859c2cdf Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 14:45:45 2016 +0200 clk: renesas: mstp: Postpone call to pm_genpd_init() All local setup of the generic_pm_domain structure should have been completed before calling pm_genpd_init(). Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> drivers/clk/renesas/clk-mstp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit bf1139dfe797c0d6037dd689219a431516490544 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Apr 28 10:12:33 2016 +0200 MAINTAINERS: Add a maintainer for the Allwinner DRM driver Add myself as the maintainer of the new Allwinner DRM driver. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> MAINTAINERS | 7 +++++++ 1 file changed, 7 insertions(+) commit 2ff77b1659b9a61ecbd88c07edcd04f04b79776b Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Oct 29 09:39:56 2015 +0100 drm: sun4i: tv: Add NTSC output standard Add the settings to support the NTSC standard. Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_tv.c | 45 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) commit 154f69500781c6cd09ce6ab93a009a6458b9b685 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Oct 29 09:39:41 2015 +0100 drm: sun4i: tv: Add PAL output standard Now that we have support for the composite output, we can start adding new supported standards. Start with PAL, and we will add other eventually. Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/sun4i_tv.c | 42 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit 03c4c71d25b4868818deebeaa8943b75aa539512 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Oct 29 09:39:01 2015 +0100 drm: sun4i: Add composite output Some Allwinner SoCs have an IP called the TV encoder that is used to output composite and VGA signals. In such a case, we need to use the second TCON channel. Add support for that TV encoder. Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/Makefile | 2 + drivers/gpu/drm/sun4i/sun4i_tv.c | 621 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 623 insertions(+) commit 29e57fab97fcdac9bf04db5f8f59ee63ab11b866 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Oct 29 09:37:32 2015 +0100 drm: sun4i: Add RGB output One of the A10 display pipeline possible output is an RGB interface to drive LCD panels directly. This is done through the first channel of the TCON that will output our video signals directly. Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/sun4i/Makefile | 1 + drivers/gpu/drm/sun4i/sun4i_drv.c | 24 ++++ drivers/gpu/drm/sun4i/sun4i_rgb.c | 250 +++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/sun4i/sun4i_rgb.h | 18 +++ drivers/gpu/drm/sun4i/sun4i_tcon.c | 61 ++++++++- drivers/gpu/drm/sun4i/sun4i_tcon.h | 2 + 6 files changed, 355 insertions(+), 1 deletion(-) commit 9026e0d122ac87d329b76a9b631622b03941af64 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Thu Oct 29 09:36:23 2015 +0100 drm: Add Allwinner A10 Display Engine support The Allwinner A10 and subsequent SoCs share the same display pipeline, with variations in the number of controllers (1 or 2), or the presence or not of some output (HDMI, TV, VGA) or not. Add a driver with a limited set of features for now, and we will hopefully support all of them eventually Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/Makefile | 3 +- drivers/gpu/drm/sun4i/Kconfig | 14 + drivers/gpu/drm/sun4i/Makefile | 10 + drivers/gpu/drm/sun4i/sun4i_backend.c | 364 ++++++++++++++++++++++ drivers/gpu/drm/sun4i/sun4i_backend.h | 165 ++++++++++ drivers/gpu/drm/sun4i/sun4i_crtc.c | 120 +++++++ drivers/gpu/drm/sun4i/sun4i_crtc.h | 30 ++ drivers/gpu/drm/sun4i/sun4i_dotclock.c | 160 ++++++++++ drivers/gpu/drm/sun4i/sun4i_dotclock.h | 21 ++ drivers/gpu/drm/sun4i/sun4i_drv.c | 334 ++++++++++++++++++++ drivers/gpu/drm/sun4i/sun4i_drv.h | 30 ++ drivers/gpu/drm/sun4i/sun4i_framebuffer.c | 54 ++++ drivers/gpu/drm/sun4i/sun4i_framebuffer.h | 19 ++ drivers/gpu/drm/sun4i/sun4i_layer.c | 161 ++++++++++ drivers/gpu/drm/sun4i/sun4i_layer.h | 30 ++ drivers/gpu/drm/sun4i/sun4i_tcon.c | 502 ++++++++++++++++++++++++++++++ drivers/gpu/drm/sun4i/sun4i_tcon.h | 184 +++++++++++ 18 files changed, 2202 insertions(+), 1 deletion(-) commit 21a454fd361416489f222f1947e7a5bebfde5cc6 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Fri Oct 30 14:25:05 2015 +0100 drm: sun4i: Add DT bindings documentation The display pipeline of the Allwinner A10 is involving several loosely coupled components. Add a documentation for the bindings. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> .../bindings/display/sunxi/sun4i-drm.txt | 258 +++++++++++++++++++++ 1 file changed, 258 insertions(+) commit 80588a86afd09c3c132ef7dc2a1ab2fe4c5f9d55 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Mon Feb 8 13:58:56 2016 +0100 drm: fb: Add seq_file definition Otherwise, building with DEBUG_FS enabled will trigger a build warning because we're using a structure that has not been declared. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> include/drm/drm_fb_cma_helper.h | 2 ++ 1 file changed, 2 insertions(+) commit 2a58f9c12bb360f38fb39e470bb5ff94014356e6 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Apr 28 10:56:28 2016 +0300 usb: dwc3: gadget: disable automatic calculation of ACK TP NUMP Now that we calculate DCFG.NUMP, we can disable dwc3's automatic calculation so we maximize our chances of very high throughtput through the use of bursts. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 5 +++++ drivers/usb/dwc3/gadget.c | 11 +++++++++++ 2 files changed, 16 insertions(+) commit 676e3497448177bdb1934cbc4402f921730a5864 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 26 10:49:07 2016 +0300 usb: dwc3: gadget: update DCFG.NumP to max burst size NumP field of DCFG register is used on NumP field of ACK TP header and it tells the host how many packets an endpoint can receive before waiting for synchronization. Documentation says it should be set to anything <=bMaxBurst. Interestingly, however, this setting is not per-endpoint how it should be (different endpoints could have different burst sizes), but things seem to work okay right now. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 3 +++ drivers/usb/dwc3/gadget.c | 14 ++++++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) commit a6ef3e02542a33fb705e6977221deb0292b27398 Author: John Youn <johnyoun@synopsys.com> Date: Wed Apr 27 20:20:56 2016 -0700 usb: dwc2: Proper cleanup on dr_mode failure Cleanup in probe if we fail to get dr_mode. Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 907a444718b8f93956acac1c944d880c54ab900d Author: Sevak Arakelyan <sevaka@synopsys.com> Date: Wed Apr 27 20:20:53 2016 -0700 usb: dwc2: Fixed SOF interrupt enabling/disabling In case of DDMA mode we don't need to get an SOF interrupt so disable the unmasking of SOF interrupt in DDMA mode. Signed-off-by: Sevak Arakelyan <sevaka@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/hcd_queue.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b0d659022e5c96ee5c4bd62d22d3da2d66de306b Author: Vardan Mikayelyan <mvardan@synopsys.com> Date: Wed Apr 27 20:20:51 2016 -0700 usb: dwc2: host: Setting qtd to NULL after freeing it This is safety change added while doing slub debugging. Affected functions: dwc2_hcd_qtd_unlink_and_free() _dwc2_hcd_urb_enqueue() Signed-off-by: Vardan Mikayelyan <mvardan@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/hcd.c | 1 + drivers/usb/dwc2/hcd.h | 1 + 2 files changed, 2 insertions(+) commit ee3de8d750134703c702534173cd8623d1b32c38 Author: Vardan Mikayelyan <mvardan@synopsys.com> Date: Wed Apr 27 20:20:48 2016 -0700 usb: dwc2: gadget: Prevent handling of host interrupts In host slave mode, the core asserts the rxready, txfifoempty interrupts that get serviced in the gadget irq handler. Prevent servicing of these when not in the gadget mode of operation. Signed-off-by: Vardan Mikayelyan <mvardan@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/gadget.c | 3 +++ 1 file changed, 3 insertions(+) commit 8c3d609275f7f39d308e5c40a6220c67454f7a28 Author: Vahram Aharonyan <vahrama@synopsys.com> Date: Wed Apr 27 20:20:46 2016 -0700 usb: dwc2: gadget: Check for ep0 in enable Replaced the WARN_ON with a check and return of -EINVAL in the dwc2_hsotg_ep_enable function if ep0 is passed in. Signed-off-by: Vahram Aharonyan <vahrama@synopsys.com> Signed-off-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc2/gadget.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 7b9cc7a2b101cc73f6abe3468441381c98817e54 Author: Konrad Leszczynski <konrad.leszczynski@intel.com> Date: Fri Feb 12 15:21:46 2016 +0000 usb: dwc3: gadget: give better command return code if Start Transfer command fails, let's try a little harder to figure out why the command failed and give slightly better return codes. This will be usefulf or isochronous endpoints, at least, which could decide to retry a given request. Signed-off-by: Konrad Leszczynski <konrad.leszczynski@intel.com> Signed-off-by: Rafal Redzimski <rafal.f.redzimski@intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 4 ++++ drivers/usb/dwc3/gadget.c | 33 ++++++++++++++++++++++++++++++--- 2 files changed, 34 insertions(+), 3 deletions(-) commit 0878263b68df372e6389b050fc2bd4f6d5b9f332 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 14:53:47 2016 +0300 usb: gadget: composite: avoid kernel oops with bad gadgets If a gadget driver loaded to a Superspeed-capable peripheral controller, using a Superspeed cable, doesn't provide Superspeed descriptors, we will get a NULL pointer dereference. In order to avoid that situation, we will try to find any valid descriptors we can. If no set of descriptors is passed in, then we'll let that gadget oops anyhow. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/composite.c | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) commit ce046d323d74ee9d280688a2cb499716f555a89f Author: Heikki Krogerus <heikki.krogerus@linux.intel.com> Date: Fri Apr 22 11:17:38 2016 +0300 usb: dwc3: pci: pass the platform device as a parameter to dwc3_pci_quirks() For convenience, passing the dwc3 platform device as a parameter to dwc3_pci_quirks() function. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-pci.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit 474799f073763b868e158b04b74f8ddd1da38da2 Author: Heikki Krogerus <heikki.krogerus@linux.intel.com> Date: Fri Apr 22 11:17:37 2016 +0300 usb: dwc3: pci: make build-in device properties available Setting the ACPI companion before calling dwc3_pci_quirks. The ACPI companion will be set unconditionally as the primary fwnode, overriding any previously set primary fwnode. This will make sure that any build-in properties added to the platform device will be added as the secondary fwnode in cases where also ACPI companion exists. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-pci.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit ae411413760785a0a2ce6cb44d5afe95115aa24d Author: Fei Yang <fei.yang@intel.com> Date: Wed Apr 20 09:08:43 2016 +0300 usb: dwc3: ep0: sanity check test mode selector In case host sends us an unsupported test mode, we *must* stall this request. This will tell the host that the selector is invalid and we won't put the controller in unsupported test modes which could have undetermined side-effects. Signed-off-by: Fei Yang <fei.yang@intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/ep0.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 8be2748a40cb84c2ac5085e7e6bccb5a5fcc6235 Merge: 210732d 4be7352 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 27 23:08:41 2016 -0400 Merge branch 'socket-space-optimizations' Eric Dumazet says: ==================== net: avoid some atomic ops when FASYNC is not used We can avoid some atomic operations on sockets not using FASYNC ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 4be735225f7cd040ca81c18740e7b672021bafeb Author: Eric Dumazet <edumazet@google.com> Date: Mon Apr 25 10:39:34 2016 -0700 net: SOCKWQ_ASYNC_WAITDATA optimizations SOCKWQ_ASYNC_WAITDATA is set/cleared in sk_wait_data() and equivalent functions, so that sock_wake_async() can send a SIGIO only when necessary. Since these atomic operations are really not needed unless socket expressed interest in FASYNC, we can omit them in most cases. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 9317bb69824ec8d078b0b786b6971aedb0af3d4f Author: Eric Dumazet <edumazet@google.com> Date: Mon Apr 25 10:39:32 2016 -0700 net: SOCKWQ_ASYNC_NOSPACE optimizations SOCKWQ_ASYNC_NOSPACE is tested in sock_wake_async() so that a SIGIO signal is sent when needed. tcp_sendmsg() clears the bit. tcp_poll() sets the bit when stream is not writeable. We can avoid two atomic operations by first checking if socket is actually interested in the FASYNC business (most sockets in real applications do not use AIO, but select()/poll()/epoll()) This also removes one cache line miss to access sk->sk_wq->flags in tcp_sendmsg() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 210732d16d20f0c18fc5e5dcdf726c8b02b81957 Merge: 2995aea 13415e4 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 27 22:48:25 2016 -0400 Merge branch 'snmp-stats-update' Eric Dumazet says: ==================== net: snmp: update SNMP methods In the old days (before linux-3.0), SNMP counters were duplicated, one set for user context, and anther one for BH context. After commit 8f0ea0fe3a03 ("snmp: reduce percpu needs by 50%") we have a single copy, and what really matters is preemption being enabled or disabled, since we use this_cpu_inc() or __this_cpu_inc() respectively. This patch series kills the obsolete STATS_USER() helpers, and rename all XXX_BH() helpers to __XXX() ones, to more closely match conventions used to update per cpu variables. This is probably going to hurt maintainers job for a while, since cherry-picks will not be clean, but this had to be cleaned at one point. I am so sorry guys. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 13415e46c5915e2dac089de516369005fbc045f9 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:43 2016 -0700 net: snmp: kill STATS_BH macros There is nothing related to BH in SNMP counters anymore, since linux-3.0. Rename helpers to use __ prefix instead of _BH prefix, for contexts where preemption is disabled. This more closely matches convention used to update percpu variables. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/icmp.h | 2 +- include/net/ip.h | 10 +++++----- include/net/ipv6.h | 36 ++++++++++++++++++------------------ include/net/sctp/sctp.h | 6 +++--- include/net/snmp.h | 24 ++++++++++++------------ include/net/tcp.h | 2 +- include/net/udp.h | 8 ++++---- net/dccp/dccp.h | 2 +- 8 files changed, 45 insertions(+), 45 deletions(-) commit f3832ed2c27e7ad13300791db4089a7d4304f500 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:42 2016 -0700 ipv6: kill ICMP6MSGIN_INC_STATS_BH() IPv6 ICMP stats are atomics anyway. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ipv6.h | 4 +--- net/ipv6/icmp.c | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) commit c2005eb01044e82498209ee4ee43be604da3ef2a Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:41 2016 -0700 ipv6: rename IP6_UPD_PO_STATS_BH() Rename IP6_UPD_PO_STATS_BH() to __IP6_UPD_PO_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ipv6.h | 2 +- net/ipv6/ip6_input.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 1d0155035918aa44e634941ac05721536b461d7c Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:40 2016 -0700 ipv6: rename IP6_INC_STATS_BH() Rename IP6_INC_STATS_BH() to __IP6_INC_STATS() and IP6_ADD_STATS_BH() to __IP6_ADD_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ipv6.h | 4 +-- net/bridge/br_netfilter_ipv6.c | 10 +++---- net/ipv6/exthdrs.c | 66 +++++++++++++++++++++--------------------- net/ipv6/ip6_input.c | 28 +++++++++--------- net/ipv6/ip6_output.c | 34 +++++++++++----------- net/ipv6/ip6mr.c | 8 ++--- net/ipv6/reassembly.c | 32 ++++++++++---------- 7 files changed, 91 insertions(+), 91 deletions(-) commit 02a1d6e7a6bb025a77da77012190e1efc1970f1c Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:39 2016 -0700 net: rename NET_{ADD|INC}_STATS_BH() Rename NET_INC_STATS_BH() to __NET_INC_STATS() and NET_ADD_STATS_BH() to __NET_ADD_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 4 +- include/net/tcp.h | 4 +- net/core/dev.c | 4 +- net/dccp/ipv4.c | 10 ++--- net/dccp/ipv6.c | 8 ++-- net/dccp/timer.c | 4 +- net/ipv4/arp.c | 2 +- net/ipv4/inet_hashtables.c | 2 +- net/ipv4/inet_timewait_sock.c | 4 +- net/ipv4/ip_input.c | 2 +- net/ipv4/syncookies.c | 4 +- net/ipv4/tcp.c | 4 +- net/ipv4/tcp_cdg.c | 20 ++++----- net/ipv4/tcp_cubic.c | 20 ++++----- net/ipv4/tcp_fastopen.c | 14 +++--- net/ipv4/tcp_input.c | 100 ++++++++++++++++++++++-------------------- net/ipv4/tcp_ipv4.c | 22 +++++----- net/ipv4/tcp_minisocks.c | 10 ++--- net/ipv4/tcp_output.c | 14 +++--- net/ipv4/tcp_recovery.c | 4 +- net/ipv4/tcp_timer.c | 22 +++++----- net/ipv6/inet6_hashtables.c | 2 +- net/ipv6/syncookies.c | 4 +- net/ipv6/tcp_ipv6.c | 16 +++---- net/sctp/input.c | 2 +- 25 files changed, 153 insertions(+), 149 deletions(-) commit b15084ec7d4c89000242d69b5f57b4d138bad1b9 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:38 2016 -0700 net: rename IP_UPD_PO_STATS_BH() Rename IP_UPD_PO_STATS_BH() to __IP_UPD_PO_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 2 +- net/ipv4/ip_input.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) commit 98f619957ec2717fea09b398957e130e4bf4b30c Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:37 2016 -0700 net: rename IP_ADD_STATS_BH() Rename IP_ADD_STATS_BH() to __IP_ADD_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 2 +- net/ipv4/ip_forward.c | 2 +- net/ipv4/ip_input.c | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) commit a16292a0f0e0cef40ed51685dfde12b3002959b5 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:36 2016 -0700 net: rename ICMP6_INC_STATS_BH() Rename ICMP6_INC_STATS_BH() to __ICMP6_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ipv6.h | 2 +- net/dccp/ipv6.c | 8 ++++---- net/ipv6/icmp.c | 10 +++++----- net/ipv6/tcp_ipv6.c | 4 ++-- net/ipv6/udp.c | 4 ++-- net/sctp/ipv6.c | 2 +- 6 files changed, 15 insertions(+), 15 deletions(-) commit b45386efa2ec4533196a24d397ec5f9f0a42abc4 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:35 2016 -0700 net: rename IP_INC_STATS_BH() Rename IP_INC_STATS_BH() to __IP_INC_STATS(), to better express this is used in non preemptible context. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 2 +- net/bridge/br_netfilter_hooks.c | 6 +++--- net/dccp/ipv4.c | 2 +- net/ipv4/inet_connection_sock.c | 4 ++-- net/ipv4/ip_forward.c | 4 ++-- net/ipv4/ip_fragment.c | 14 +++++++------- net/ipv4/ip_input.c | 20 ++++++++++---------- net/ipv4/route.c | 6 +++--- 8 files changed, 29 insertions(+), 29 deletions(-) commit 08e3baef65e2e9481637a1e8fb06089ca70be707 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:34 2016 -0700 net: sctp: rename SCTP_INC_STATS_BH() Rename SCTP_INC_STATS_BH() to __SCTP_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/sctp.h | 2 +- net/sctp/input.c | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) commit 214d3f1f87e17357c422dad844f03be7b9d65ce7 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:33 2016 -0700 net: icmp: rename ICMPMSGIN_INC_STATS_BH() Remove misleading _BH suffix. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/icmp.h | 2 +- net/ipv4/icmp.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 90bbcc608369a1b46089b0f5aa22b8ea31ffa12e Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:32 2016 -0700 net: tcp: rename TCP_INC_STATS_BH Rename TCP_INC_STATS_BH() to __TCP_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 2 +- net/ipv4/tcp.c | 2 +- net/ipv4/tcp_input.c | 8 ++++---- net/ipv4/tcp_ipv4.c | 16 ++++++++-------- net/ipv4/tcp_minisocks.c | 4 ++-- net/ipv4/tcp_output.c | 4 ++-- net/ipv6/tcp_ipv6.c | 14 +++++++------- 7 files changed, 25 insertions(+), 25 deletions(-) commit b540f9d702f0eedf4f2dc49472f4cf40d053d5b1 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:31 2016 -0700 net: xfrm: kill XFRM_INC_STATS_BH() Not used anymore. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/xfrm.h | 2 -- 1 file changed, 2 deletions(-) commit 02c223470c3cc30e5ff90217abea761679553ac3 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:30 2016 -0700 net: udp: rename UDP_INC_STATS_BH() Rename UDP_INC_STATS_BH() to __UDP_INC_STATS(), and UDP6_INC_STATS_BH() to __UDP6_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/udp.h | 12 ++++++------ net/ipv4/udp.c | 46 +++++++++++++++++++++++----------------------- net/ipv6/udp.c | 38 +++++++++++++++++++------------------- net/rxrpc/ar-input.c | 4 ++-- net/sunrpc/xprtsock.c | 4 ++-- 5 files changed, 52 insertions(+), 52 deletions(-) commit 5d3848bc33b7d13fc97b5b6e0dccde2d0755bfd5 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:29 2016 -0700 net: rename ICMP_INC_STATS_BH() Rename ICMP_INC_STATS_BH() to __ICMP_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/icmp.h | 2 +- net/dccp/ipv4.c | 4 ++-- net/ipv4/icmp.c | 16 ++++++++-------- net/ipv4/tcp_ipv4.c | 2 +- net/ipv4/udp.c | 2 +- net/sctp/input.c | 2 +- 6 files changed, 14 insertions(+), 14 deletions(-) commit aa62d76b6e1a7c927a9e0ca39de8a93b751f3b8c Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:28 2016 -0700 dccp: rename DCCP_INC_STATS_BH() Rename DCCP_INC_STATS_BH() to __DCCP_INC_STATS() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/dccp/dccp.h | 6 +++--- net/dccp/input.c | 2 +- net/dccp/ipv4.c | 8 ++++---- net/dccp/ipv6.c | 8 ++++---- net/dccp/minisocks.c | 2 +- net/dccp/options.c | 2 +- net/dccp/timer.c | 4 ++-- 7 files changed, 16 insertions(+), 16 deletions(-) commit 6aef70a851ac77967992340faaff33f44598f60a Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 27 16:44:27 2016 -0700 net: snmp: kill various STATS_USER() helpers In the old days (before linux-3.0), SNMP counters were duplicated, one for user context, and one for BH context. After commit 8f0ea0fe3a03 ("snmp: reduce percpu needs by 50%") we have a single copy, and what really matters is preemption being enabled or disabled, since we use this_cpu_inc() or __this_cpu_inc() respectively. We therefore kill SNMP_INC_STATS_USER(), SNMP_ADD_STATS_USER(), NET_INC_STATS_USER(), NET_ADD_STATS_USER(), SCTP_INC_STATS_USER(), SNMP_INC_STATS64_USER(), SNMP_ADD_STATS64_USER(), TCP_ADD_STATS_USER(), UDP_INC_STATS_USER(), UDP6_INC_STATS_USER(), and XFRM_INC_STATS_USER() Following patches will rename __BH helpers to make clear their usage is not tied to BH being disabled. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 2 -- include/net/sctp/sctp.h | 1 - include/net/snmp.h | 22 +++++----------------- include/net/tcp.h | 9 ++++----- include/net/udp.h | 14 +++++++------- include/net/xfrm.h | 2 -- net/ipv4/tcp.c | 12 ++++++------ net/ipv4/udp.c | 24 ++++++++++++------------ net/ipv6/udp.c | 49 ++++++++++++++++++++++++------------------------- net/sctp/chunk.c | 2 +- 10 files changed, 59 insertions(+), 78 deletions(-) commit 2995aea5b68b6850e76aadd95be777cb36949e62 Merge: 501e7ef 47d3483 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 27 21:59:08 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-04-27 This series contains updates to i40e and i40evf. Alex Duyck cleans up the feature flags since they are becoming pretty "massive", the primary change being that we now build our features list around hw_encap_features. Added support for IPIP and SIT offloads, which should improvement in throughput for IPIP and SIT tunnels with the offload enabled. Mitch adds support for configuring RSS on behalf of the VFs, which removes the burden of dealing with different hardware interfaces from the VF drivers and improves future compatibility. Fix to ensure that we do not panic by checking that the vsi_res pointer is valid before dereferencing it, after which we can drink beer and eat peanuts. Shannon does come housekeeping in i40e_add_fdir_ethtool() in preparation for more cloud filter work. Added flexibility to the nvmupdate facility by adding the ability to specify an AQ event opcode to wait on after Exec_AQ request. Michal adds device capability which defines if an update is available and if a security check is needed during the update process. Kamil just adds a device id to support X722 QSFP+ device. Greg fixes an issue where a mirror rule ID may be zero, so do not return invalid parameter when the user passes in a zero for a rule ID. Adds support to steer packets to VSIs by VLAN tag alone while being in promiscuous mode for multicast and unicast MAC addresses. Jesse fixes the driver from offloading the VLAN tag into the skb any time there was a VLAN tag and the hardware stripping was enabled, to making sure it is enabled before put_tag. v2: Dropped patch 8 ("i40e: Allow user to change input set mask for flow director") while Kiran reworks a more generalized solution based on feedback from David Miller. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 501e7ef569f4ea2dc7e50773cf6a5d757c94f9b4 Author: Eric Dumazet <edumazet@google.com> Date: Tue Apr 26 15:30:07 2016 -0700 net-rfs: fix false sharing accessing sd->input_queue_head sd->input_queue_head is incremented for each processed packet in process_backlog(), and read from other cpus performing Out Of Order avoidance in get_rps_cpu() Moving this field in a separate cache line keeps it mostly hot for the cpu in process_backlog(), as other cpus will only read it. In a stress test, process_backlog() was consuming 6.80 % of cpu cycles, and the patch reduced the cost to 0.65 % Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 35ef7d689d7d54ab345b179e50c749fe3a2529eb Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Wed Apr 27 05:43:48 2016 +0900 net: w5100: support W5500 This adds support for W5500 chip. W5500 has similar register and memory organization with W5100 and W5200. There are a few important differences listed below but it is still possible to share common code with W5100 and W5200. * W5500 register and memory are organized by multiple blocks. Each one is selected by 16bits offset address and 5bits block select bits. But the existing register access operations take u16 address. This change extends the addess by u32 address and put offset address to lower 16bits and block select bits to upper 16bits. This change also adds the offset addresses for socket register and TX/RX memory blocks to the driver private data structure in order to reduce conditional switches for each chip. * W5500 has the different register offset for socket interrupt mask register. Newly added internal functions w5100_enable_intr() and w5100_disable_intr() take care of the diffrence. * W5500 has the different register offset for retry time-value register. But this register is only used to verify that the reset value is correctly read at initialization. So move the verification to w5100_hw_reset() which already does different things for different chips. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/Kconfig | 2 +- drivers/net/ethernet/wiznet/w5100-spi.c | 192 +++++++++++++++++++++++-- drivers/net/ethernet/wiznet/w5100.c | 243 +++++++++++++++++++++++--------- drivers/net/ethernet/wiznet/w5100.h | 13 +- 4 files changed, 365 insertions(+), 85 deletions(-) commit d1497977fecb9acce05988d6322ad415ef93bb39 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Tue Apr 26 09:29:26 2016 +0200 crypto: s5p-sss - fix incorrect usage of scatterlists api sg_dma_len() macro can be used only on scattelists which are mapped, so all calls to it before dma_map_sg() are invalid. Replace them by proper check for direct sg segment length read. Fixes: a49e490c7a8a ("crypto: s5p-sss - add S5PV210 advanced crypto engine support") Fixes: 9e4a1100a445 ("crypto: s5p-sss - Handle unaligned buffers") Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6f6438975d6a1afb0f0ac18176ede4e667020db0 Merge: 79152e8 9e209fc Author: Herbert Xu <herbert@gondor.apana.org.au> Date: Thu Apr 28 09:13:03 2016 +0800 Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Merge the crypto tree to pull in the qat adf_init_pf_wq change. commit 2b3ec765058449caa27e2806a939a4bffcbeba64 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Wed Apr 27 15:48:08 2016 -0700 cpufreq: intel_pstate: Enable PPC enforcement for servers For platforms which are controlled via remove node manager, enable _PPC by default. These platforms are mostly categorized as enterprise server or performance servers. These platforms needs to go through some certifications tests, which tests control via _PPC. The relative risk of enabling by default is low as this is is less likely that these systems have broken _PSS table. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Documentation/kernel-parameters.txt | 5 ++++- drivers/cpufreq/intel_pstate.c | 12 +++++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) commit 3be9200d512bfa8d6292f5dce6c02aa151821e09 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Wed Apr 27 15:48:07 2016 -0700 cpufreq: intel_pstate: Adjust policy->max When policy->max is changed via _PPC or sysfs and is more than the max non turbo frequency, it does not really change resulting performance in some processors. When policy->max results in a P-State ratio more than the turbo activation ratio, then processor can choose any P-State up to max turbo. So the user or _PPC setting has no value, but this can cause undesirable side effects like: - Showing reduced max percentage in Intel P-State sysfs - It can cause reduced max performance under certain boundary conditions: The requested max scaling frequency either via _PPC or via cpufreq-sysfs, will be converted into a fixed floating point max percent scale. In majority of the cases this will result in correct max. But not 100% of the time. If the _PPC is requested at a point where the calculation lead to a lower max, this can result in a lower P-State then expected and it will impact performance. Example of this condition using a Broadwell laptop with config TDP. ACPI _PSS table from a Broadwell laptop 2301000 2300000 2200000 2000000 1900000 1800000 1700000 1500000 1400000 1300000 1100000 1000000 900000 800000 600000 500000 The actual results by disabling config TDP so that we can get what is requested on or below 2300000Khz. scaling_max_freq Max Requested P-State Resultant scaling max ---------------------------------------- ---------------------- 2400000 18 2900000 (max turbo) 2300000 17 2300000 (max physical non turbo) 2200000 15 2100000 2100000 15 2100000 2000000 13 1900000 1900000 13 1900000 1800000 12 1800000 1700000 11 1700000 1600000 10 1600000 1500000 f 1500000 1400000 e 1400000 1300000 d 1300000 1200000 c 1200000 1100000 a 1000000 1000000 a 1000000 900000 9 900000 800000 8 800000 700000 7 700000 600000 6 600000 500000 5 500000 ------------------------------------------------------------------ Now set the config TDP level 1 ratio as 0x0b (equivalent to 1100000KHz) in BIOS (not every system will let you adjust this). The turbo activation ratio will be set to one less than that, which will be 0x0a (So any request above 1000000KHz should result in turbo region assuming no thermal limits). Here _PPC will request max to 1100000KHz (which basically should still result in turbo as this is more than the turbo activation ratio up to max allowable turbo frequency), but actual calculation resulted in a max ceiling P-State which is 0x0a. So under any load condition, this driver will not request turbo P-States. This will be a huge performance hit. When config TDP feature is ON, if the _PPC points to a frequency above turbo activation ratio, the performance can still reach max turbo. In this case we don't need to treat this as the reduced frequency in set_policy callback. In this change when config TDP is active (by checking if the physical max non turbo ratio is more than the current max non turbo ratio), any request above current max non turbo is treated as full performance. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> [ rjw : Minor cleanups ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 9522a2ff9cde26ef48c30e0c9ca9ae4dfb669764 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Wed Apr 27 15:48:06 2016 -0700 cpufreq: intel_pstate: Enforce _PPC limits Use ACPI _PPC notification to limit max P state driver will request. ACPI _PPC change notification is sent by BIOS to limit max P state in several cases: - Reduce impact of platform thermal condition - When Config TDP feature is used, a changed _PPC is sent to follow TDP change - Remote node managers in server want to control platform power via baseboard management controller (BMC) This change registers with ACPI processor performance lib so that _PPC changes are notified to cpufreq core, which in turns will result in call to .setpolicy() callback. Also the way _PSS table identifies a turbo frequency is not compatible to max turbo frequency in intel_pstate, so the very first entry in _PSS needs to be adjusted. This feature can be turned on by using kernel parameters: intel_pstate=support_acpi_ppc Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> [ rjw: Minor cleanups ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Documentation/kernel-parameters.txt | 2 + drivers/cpufreq/Kconfig.x86 | 1 + drivers/cpufreq/intel_pstate.c | 136 +++++++++++++++++++++++++++++++++++- 3 files changed, 137 insertions(+), 2 deletions(-) commit 9bf292bfca94694a721449e3fd752493856710f6 Author: Ashutosh Dixit <ashutosh.dixit@intel.com> Date: Wed Apr 27 14:36:05 2016 -0700 misc: mic: Fix for double fetch security bug in VOP driver The MIC VOP driver does two successive reads from user space to read a variable length data structure. Kernel memory corruption can result if the data structure changes between the two reads. This patch disallows the chance of this happening. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=116651 Reported by: Pengfei Wang <wpengfeinudt@gmail.com> Reviewed-by: Sudeep Dutt <sudeep.dutt@intel.com> Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mic/vop/vop_vringh.c | 5 +++++ 1 file changed, 5 insertions(+) commit eaa2c3aeef83f096cd1ec73df1310712e423337b Author: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Date: Tue Apr 19 15:28:01 2016 +0530 cpufreq: powernv: Ramp-down global pstate slower than local-pstate The frequency transition latency from pmin to pmax is observed to be in few millisecond granurality. And it usually happens to take a performance penalty during sudden frequency rampup requests. This patch set solves this problem by using an entity called "global pstates". The global pstate is a Chip-level entity, so the global entitiy (Voltage) is managed across the cores. The local pstate is a Core-level entity, so the local entity (frequency) is managed across threads. This patch brings down global pstate at a slower rate than the local pstate. Hence by holding global pstates higher than local pstate makes the subsequent rampups faster. A per policy structure is maintained to keep track of the global and local pstate changes. The global pstate is brought down using a parabolic equation. The ramp down time to pmin is set to ~5 seconds. To make sure that the global pstates are dropped at regular interval , a timer is queued for every 2 seconds during ramp-down phase, which eventually brings the pstate down to local pstate. Iozone results show fairly consistent performance boost. YCSB on redis shows improved Max latencies in most cases. Iozone write/rewite test were made with filesizes 200704Kb and 401408Kb with different record sizes . The following table shows IOoperations/sec with and without patch. Iozone Results ( in op/sec) ( mean over 3 iterations ) --------------------------------------------------------------------- file size- with without % recordsize-IOtype patch patch change ---------------------------------------------------------------------- 200704-1-SeqWrite 1616532 1615425 0.06 200704-1-Rewrite 2423195 2303130 5.21 200704-2-SeqWrite 1628577 1602620 1.61 200704-2-Rewrite 2428264 2312154 5.02 200704-4-SeqWrite 1617605 1617182 0.02 200704-4-Rewrite 2430524 2351238 3.37 200704-8-SeqWrite 1629478 1600436 1.81 200704-8-Rewrite 2415308 2298136 5.09 200704-16-SeqWrite 1619632 1618250 0.08 200704-16-Rewrite 2396650 2352591 1.87 200704-32-SeqWrite 1632544 1598083 2.15 200704-32-Rewrite 2425119 2329743 4.09 200704-64-SeqWrite 1617812 1617235 0.03 200704-64-Rewrite 2402021 2321080 3.48 200704-128-SeqWrite 1631998 1600256 1.98 200704-128-Rewrite 2422389 2304954 5.09 200704-256 SeqWrite 1617065 1616962 0.00 200704-256-Rewrite 2432539 2301980 5.67 200704-512-SeqWrite 1632599 1598656 2.12 200704-512-Rewrite 2429270 2323676 4.54 200704-1024-SeqWrite 1618758 1616156 0.16 200704-1024-Rewrite 2431631 2315889 4.99 401408-1-SeqWrite 1631479 1608132 1.45 401408-1-Rewrite 2501550 2459409 1.71 401408-2-SeqWrite 1617095 1626069 -0.55 401408-2-Rewrite 2507557 2443621 2.61 401408-4-SeqWrite 1629601 1611869 1.10 401408-4-Rewrite 2505909 2462098 1.77 401408-8-SeqWrite 1617110 1626968 -0.60 401408-8-Rewrite 2512244 2456827 2.25 401408-16-SeqWrite 1632609 1609603 1.42 401408-16-Rewrite 2500792 2451405 2.01 401408-32-SeqWrite 1619294 1628167 -0.54 401408-32-Rewrite 2510115 2451292 2.39 401408-64-SeqWrite 1632709 1603746 1.80 401408-64-Rewrite 2506692 2433186 3.02 401408-128-SeqWrite 1619284 1627461 -0.50 401408-128-Rewrite 2518698 2453361 2.66 401408-256-SeqWrite 1634022 1610681 1.44 401408-256-Rewrite 2509987 2446328 2.60 401408-512-SeqWrite 1617524 1628016 -0.64 401408-512-Rewrite 2504409 2442899 2.51 401408-1024-SeqWrite 1629812 1611566 1.13 401408-1024-Rewrite 2507620 2442968 2.64 Tested with YCSB workload (50% update + 50% read) over redis for 1 million records and 1 million operation. Each test was carried out with target operations per second and persistence disabled. Max-latency (in us)( mean over 5 iterations ) --------------------------------------------------------------- op/s Operation with patch without patch %change --------------------------------------------------------------- 15000 Read 61480.6 50261.4 22.32 15000 cleanup 215.2 293.6 -26.70 15000 update 25666.2 25163.8 2.00 25000 Read 32626.2 89525.4 -63.56 25000 cleanup 292.2 263.0 11.10 25000 update 32293.4 90255.0 -64.22 35000 Read 34783.0 33119.0 5.02 35000 cleanup 321.2 395.8 -18.8 35000 update 36047.0 38747.8 -6.97 40000 Read 38562.2 42357.4 -8.96 40000 cleanup 371.8 384.6 -3.33 40000 update 27861.4 41547.8 -32.94 45000 Read 42271.0 88120.6 -52.03 45000 cleanup 263.6 383.0 -31.17 45000 update 29755.8 81359.0 -63.43 (test without target op/s) 47659 Read 83061.4 136440.6 -39.12 47659 cleanup 195.8 193.8 1.03 47659 update 73429.4 124971.8 -41.24 Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Reviewed-by: Gautham R. Shenoy <ego@linux.vnet.ibm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/powernv-cpufreq.c | 258 ++++++++++++++++++++++++++++++++++++-- 1 file changed, 251 insertions(+), 7 deletions(-) commit 2920e9ce8f43a946e3c257a7c0ee35b02149fca7 Author: Shilpasri G Bhat <shilpa.bhat@linux.vnet.ibm.com> Date: Tue Apr 19 15:28:00 2016 +0530 cpufreq: powernv: Remove flag use-case of policy->driver_data commit 1b0289848d5d ("cpufreq: powernv: Add sysfs attributes to show throttle stats") used policy->driver_data as a flag for one-time creation of throttle sysfs files. Instead of this use 'kernfs_find_and_get()' to check if the attribute already exists. This is required as policy->driver_data is used for other purposes in the later patch. Signed-off-by: Shilpasri G Bhat <shilpa.bhat@linux.vnet.ibm.com> Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/powernv-cpufreq.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 71d42e9c71d7fca2eca98eac315cb485b5d2314d Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 18 04:37:38 2016 +0300 ARM: lpc32xx: remove duplicate const on lpc32xx_auxdata_lookup Remove redundant duplicate const, which is found by smatch: arch/arm/mach-lpc32xx/phy3250.c:162:42: warning: duplicate const Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/mach-lpc32xx/phy3250.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d82b4b0a5ebeb55c3b88e49b38135a847736e6b5 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 18 04:05:25 2016 +0300 ARM: lpc32xx: remove leftovers of legacy clock source and provider drivers After switching the platform to common clock framework there is no more need to keep dead code in arch/arm/mach-lpc32xx, which glued legacy clock source and clock provider drivers, remove the leftovers. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/mach-lpc32xx/common.c | 95 ------------------------------------------ arch/arm/mach-lpc32xx/common.h | 23 +--------- 2 files changed, 1 insertion(+), 117 deletions(-) commit 715552aa30ffe3bd776bb7635056f6622a29133d Author: Sylvain Lemieux <slemieux@tycoint.com> Date: Mon Apr 4 15:48:34 2016 -0400 ARM: lpc32xx: remove reboot header file The header file "reboot.h" is no longer needed, following the migration of the restart code into the pnx4008 watchdog. Signed-off-by: Sylvain Lemieux <slemieux@tycoint.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/mach-lpc32xx/common.h | 1 - 1 file changed, 1 deletion(-) commit 628e35baa8e1e19217eb11b6ccfa96c273757d18 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:28:38 2016 -0700 ACPI / amba: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Graeme Gregory <graeme.gregory@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpi_amba.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit cdd9a6b2a7461021a5ee24bc130592c1bdc54cd8 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:27:46 2016 -0700 ACPI / APD: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpi_apd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 3ff11fe8e8195d87090df9ffabfc85b4d35054c2 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:34 2016 +0300 ARM: dts: lpc32xx: phy3250: add SoC name prefix to board dts file To simplify matching of DTS files of all NXP LPC32xx powered boards by a file name add 'lpc3250' prefix to PHYTEC PHYCORE-LPC3250 board dts file. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/Makefile | 2 +- arch/arm/boot/dts/lpc3250-phy3250.dts | 226 ++++++++++++++++++++++++++++++++++ arch/arm/boot/dts/phy3250.dts | 226 ---------------------------------- 3 files changed, 227 insertions(+), 227 deletions(-) commit 9cfde0a1fede26cbeff0b6eba48bf7fd375e5c8c Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:33 2016 +0300 ARM: dts: lpc32xx: phy3250: add NAND partitions device node To declare MTD OF partitions NAND controller device node should have a special 'partitions' subnode, the change removes a debug message from mtd/ofpart on boot: nxp_lpc3220_slc: 'partitions' subnode not found on /ahb/flash@20020000. Trying to parse direct subnodes as partitions. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/phy3250.dts | 50 +++++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 23 deletions(-) commit 6101f4bcb3d087b39a1d105d07bc72c9bd1194cb Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:32 2016 +0300 ARM: dts: lpc32xx: phy3250: avoid extension of device nodes by absolute path The change simplifies layout of PHY3250 board description by referencing device nodes of LPC32xx controllers by label. No functional change intended. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/phy3250.dts | 282 +++++++++++++++++++++--------------------- 1 file changed, 138 insertions(+), 144 deletions(-) commit d9a95d57647bc93f41f13a4ec6eafc1ebef7b533 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:31 2016 +0300 ARM: dts: lpc32xx: ea3250: add SoC name prefix to board dts file To simplify matching of DTS files of all NXP LPC32xx powered boards by a file name add 'lpc3250' prefix to Embedded Artists LPC3250 board dts file. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/ea3250.dts | 272 ----------------------------------- arch/arm/boot/dts/lpc3250-ea3250.dts | 272 +++++++++++++++++++++++++++++++++++ 3 files changed, 274 insertions(+), 273 deletions(-) commit 118e24cd626b8857b94eefec6f1108fef4017e51 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:30 2016 +0300 ARM: dts: lpc32xx: ea3250: fix Atmel at24 eeprom vendor There is no 'at' hardware vendor defined yet, correct vendor prefix for Atmel is 'atmel'. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/ea3250.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 72fa28e266317488738cded858c18c67488c2c04 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:29 2016 +0300 ARM: dts: lpc32xx: ea3250: add NAND partitions device node To declare MTD OF partitions NAND controller device node should have a special 'partitions' subnode, the change removes a debug message from mtd/ofpart on boot: nxp_lpc3220_slc: 'partitions' subnode not found on /ahb/flash@20020000. Trying to parse direct subnodes as partitions. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/ea3250.dts | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) commit 1a096afc7c27f059ebec0805bd1f52a0152e6cbf Author: Vladimir Zapolskiy <vz@mleia.com> Date: Wed Apr 27 00:10:28 2016 +0300 ARM: dts: lpc32xx: ea3250: avoid extension of device nodes by absolute path The change simplifies layout of EA3250 board description by referencing device nodes of LPC32xx controllers by label. No functional change intended. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/ea3250.dts | 226 +++++++++++++++++++++---------------------- 1 file changed, 110 insertions(+), 116 deletions(-) commit 9b8ad3fb81ae198ac669a61717d3a55af1f06bf2 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Tue Apr 26 00:02:23 2016 +0300 ARM: dts: lpc32xx: reparent SIC1 and SIC2 interrupts from MIC The change adds separate device nodes for SIC1 and SIC2 interrupt controllers and reparents all defined SIC1 and SIC2 interrupt producers to the correspondent interrupt controller, this is needed to perform switching to a new LPC32xx MIC/SIC interrupt controller driver. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/lpc32xx.dtsi | 60 +++++++++++++++++++++++++++++------------- 1 file changed, 42 insertions(+), 18 deletions(-) commit d839e821efc06031c927cabbbc1e976bc71f5d4f Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 25 04:00:23 2016 +0300 dt-bindings: interrupt-controllers: add description of SIC1 and SIC2 NXP LPC32xx has three interrupt controllers, namely root Main Interrupt Controller (MIC) and two supplementary Sub Interrupt Controllers (SIC1 and SIC2), four interrupt outputs from SIC1 and SIC2 are connected to MIC. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> .../interrupt-controller/nxp,lpc3220-mic.txt | 70 ++++++++++++++-------- 1 file changed, 46 insertions(+), 24 deletions(-) commit 4566be1603639aaa9bfea1989611a892d6e517ab Merge: 411963a 55df458 Author: Heiko Stuebner <heiko@sntech.de> Date: Wed Apr 27 23:22:04 2016 +0200 Merge branch 'v4.7-shared/clkids' into v4.7-armsoc/dts64 commit 188e3c5cd2b672620291e64a21f1598fe91e40b6 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Apr 27 11:56:04 2016 +0200 tty: provide tty_name() even without CONFIG_TTY The audit subsystem just started printing the name of the tty, but that causes a build failure when CONFIG_TTY is disabled: kernel/built-in.o: In function `audit_log_task_info': memremap.c:(.text+0x5e34c): undefined reference to `tty_name' kernel/built-in.o: In function `audit_set_loginuid': memremap.c:(.text+0x63b34): undefined reference to `tty_name' This adds tty_name() to the list of functions that are provided as trivial stubs in that configuration. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: db0a6fb5d97a ("audit: add tty field to LOGIN event") Signed-off-by: Paul Moore <paul@paul-moore.com> include/linux/tty.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit fe216c7a0ff993cdac885109d8544ba02e6f9127 Author: Yunlong Song <yunlong.song@huawei.com> Date: Wed Apr 27 20:32:37 2016 +0800 f2fs: fix to return 0 if err == -ENOENT in f2fs_readdir Commit 57b62d29ad5b384775974973087d47755a8c6fcc ("f2fs: fix to report error in f2fs_readdir") causes f2fs_readdir to return -ENOENT when get_lock_data_page returns -ENOENT. However, the original logic is to continue when get_lock_data_page returns -ENOENT, but it forgets to reset err to 0. This will cause getdents64 incorretly return -ENOENT when lastdirent is NULL in getdents64. This will lead to a wrong return value for syscall caller. Signed-off-by: Yunlong Song <yunlong.song@huawei.com> Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/dir.c | 1 + 1 file changed, 1 insertion(+) commit da011cc0da8cf4a60ddf4d2ae8b42902a3d71e5f Author: Chao Yu <yuchao0@huawei.com> Date: Wed Apr 27 21:40:15 2016 +0800 f2fs: move node pages only in victim section during GC For foreground GC, we cache node blocks in victim section and set them dirty, then we call sync_node_pages to flush these node pages, but meanwhile, those node pages which does not locate in victim section will be flushed together, so more bandwidth and continuous free space would be occupied. So for this condition, it's better to leave those unrelated node page in cache for further write hit, and let CP or VM to flush them afterward. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 1 + fs/f2fs/gc.c | 25 ++++--------------------- fs/f2fs/node.c | 31 +++++++++++++++++++++++++++++++ 3 files changed, 36 insertions(+), 21 deletions(-) commit a4a13f582c6d36b78b1c0459ee0b28f17bb2fb06 Author: Chao Yu <chao@kernel.org> Date: Wed Apr 27 22:22:20 2016 +0800 f2fs: be aware of invalid filename length The filename length in dirent of may become zero-sized after random junk data injection, once encounter such dirent, find_target_dentry or f2fs_add_inline_entries will run into an infinite loop. So let f2fs being aware of that to avoid deadloop. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/dir.c | 14 +++++--------- fs/f2fs/inline.c | 14 ++++++-------- 2 files changed, 11 insertions(+), 17 deletions(-) commit 6de0dc4b536110d63a83021b7e6dce3e1955297b Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Tue Apr 26 20:14:13 2016 -0400 cpufreq: e_powersaver: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/e_powersaver.c | 14 +++++++------- drivers/cpufreq/ppc_cbe_cpufreq.h | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) commit 47d3483988f649739ad8d6462eaa1723e5d077c3 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Tue Apr 12 08:30:52 2016 -0700 i40evf: Add driver support for promiscuous mode Add necessary Linux Ethernet driver support for promiscuous mode operation. Add a flag so the VF knows it is in promiscuous mode and two state flags to discreetly track multicast and unicast promiscuous states. Change-Id: Ib2f2dc7a7582304fec90fc917ebb7ded21ba1de4 Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 14 +++++++------- drivers/net/ethernet/intel/i40evf/i40evf.h | 3 +++ drivers/net/ethernet/intel/i40evf/i40evf_main.c | 19 +++++++++++++++++++ drivers/net/ethernet/intel/i40evf/i40evf_virtchnl.c | 11 +++++++++++ 4 files changed, 40 insertions(+), 7 deletions(-) commit 5676a8b9cd9a1c9822cdb3d88109f449eb2126c1 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Tue Apr 12 08:30:51 2016 -0700 i40e: Add VF promiscuous mode driver support Add infrastructure for Network Function Virtualization VLAN tagged packet steering feature. Change-Id: I9b873d8fcc253858e6baba65ac68ec5b9363944e Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 153 ++++++++++++++++++++- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.h | 2 + 2 files changed, 149 insertions(+), 6 deletions(-) commit 6c41a7606967803702d0b5c2ba57acce71ec8d9d Author: Greg Rose <gregory.v.rose@intel.com> Date: Tue Apr 12 08:30:50 2016 -0700 i40e: Add promiscuous on VLAN support NFV use cases require the ability to steer packets to VSIs by VLAN tag alone while being in promiscuous mode for multicast and unicast MAC addresses. These two new functions support that ability. Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 70 ++++++++++++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_prototype.h | 8 +++ 2 files changed, 78 insertions(+) commit a149f2c323b62bc6cff91d874d853250250e8497 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Tue Apr 12 08:30:49 2016 -0700 i40e/i40evf: Only offload VLAN tag if enabled The driver was offloading the VLAN tag into the skb any time there was a VLAN tag and the hardware stripping was enabled. Just check to make sure it's enabled before put_tag. Change-Id: Ife95290c06edd9a616393b38679923938b382241 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 3 ++- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit db0772782f6b99adbd8548e1d3830fe019c9f250 Author: Greg Rose <gregory.v.rose@intel.com> Date: Tue Apr 12 08:30:48 2016 -0700 i40e: Remove zero check A mirror rule ID may be zero so do not return invalid parameter when the user passes in a zero value for a rule ID. Change-ID: I261b8c24725ce2c6ed32f859da81093dfcbe2970 Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit bccf474435b668312e9fc8bd9586c2e256b66841 Author: Kamil Krawczyk <kamil.krawczyk@intel.com> Date: Tue Apr 12 08:30:47 2016 -0700 i40e: Add DeviceID for X722 QSFP+ Change-ID: I1370fbc7774e815ac1ad56561e97488e829592fc Signed-off-by: Kamil Krawczyk <kamil.krawczyk@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 1 + drivers/net/ethernet/intel/i40e/i40e_devids.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_common.c | 1 + drivers/net/ethernet/intel/i40evf/i40e_devids.h | 1 + 4 files changed, 4 insertions(+) commit 68a1c5a777f8e94d3bb0b0e287443492316ea5b5 Author: Michal Kosiarz <michal.kosiarz@intel.com> Date: Tue Apr 12 08:30:46 2016 -0700 i40e: Add device capability which defines if update is available Add device capability which defines if update is available and security check is needed during update process. Change-ID: I380787c878275e1df18b39198df3ee3666342282 Signed-off-by: Michal Kosiarz <michal.kosiarz@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 1 + drivers/net/ethernet/intel/i40e/i40e_common.c | 6 ++++++ drivers/net/ethernet/intel/i40e/i40e_type.h | 5 +++++ drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_type.h | 5 +++++ 5 files changed, 18 insertions(+) commit 5e4e38446a62a4f50d77b0dd11d4b379dee08988 Author: Petr Mladek <pmladek@suse.com> Date: Mon Apr 25 17:14:35 2016 +0200 livepatch: Add some basic livepatch documentation livepatch framework deserves some documentation, definitely. This is an attempt to provide some basic info. I hope that it will be useful for both LivePatch producers and also potential developers of the framework itself. [jkosina@suse.cz: - incorporated feedback (grammar fixes) from Chris J Arges <chris.j.arges@canonical.com> - s/LivePatch/livepatch in changelog as pointed out by Josh Poimboeuf <jpoimboe@redhat.com> - incorporated part of feedback (grammar fixes / reformulations) from Balbir Singh <bsingharora@gmail.com> ] Acked-by: Jessica Yu <jeyu@redhat.com> Signed-off-by: Petr Mladek <pmladek@suse.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Documentation/livepatch/livepatch.txt | 394 ++++++++++++++++++++++++++++++++++ MAINTAINERS | 1 + 2 files changed, 395 insertions(+) commit c0cc53162a0644dd57dce5e2fbb9bbafdc57d183 Merge: 8c14586 f28f20d Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 27 15:43:10 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Minor overlapping changes in the conflicts. In the macsec case, the change of the default ID macro name overlapped with the 64-bit netlink attribute alignment fixes in net-next. Signed-off-by: David S. Miller <davem@davemloft.net> commit 8c14586fc320acfed8a0048eb21d1f2e2856fc36 Author: David Ahern <dsa@cumulusnetworks.com> Date: Sun Apr 24 21:26:04 2016 -0700 net: ipv6: Use passed in table for nexthop lookups Similar to 3bfd847203c6 ("net: Use passed in table for nexthop lookups") for IPv4, if the route spec contains a table id use that to lookup the next hop first and fall back to a full lookup if it fails (per the fix 4c9bcd117918b ("net: Fix nexthop lookups")). Example: root@kenny:~# ip -6 ro ls table red local 2100:1::1 dev lo proto none metric 0 pref medium 2100:1::/120 dev eth1 proto kernel metric 256 pref medium local 2100:2::1 dev lo proto none metric 0 pref medium 2100:2::/120 dev eth2 proto kernel metric 256 pref medium local fe80::e0:f9ff:fe09:3cac dev lo proto none metric 0 pref medium local fe80::e0:f9ff:fe1c:b974 dev lo proto none metric 0 pref medium fe80::/64 dev eth1 proto kernel metric 256 pref medium fe80::/64 dev eth2 proto kernel metric 256 pref medium ff00::/8 dev red metric 256 pref medium ff00::/8 dev eth1 metric 256 pref medium ff00::/8 dev eth2 metric 256 pref medium unreachable default dev lo metric 240 error -113 pref medium root@kenny:~# ip -6 ro add table red 2100:3::/64 via 2100:1::64 RTNETLINK answers: No route to host Route add fails even though 2100:1::64 is a reachable next hop: root@kenny:~# ping6 -I red 2100:1::64 ping6: Warning: source address might be selected on device other than red. PING 2100:1::64(2100:1::64) from 2100:1::1 red: 56 data bytes 64 bytes from 2100:1::64: icmp_seq=1 ttl=64 time=1.33 ms With this patch: root@kenny:~# ip -6 ro add table red 2100:3::/64 via 2100:1::64 root@kenny:~# ip -6 ro ls table red local 2100:1::1 dev lo proto none metric 0 pref medium 2100:1::/120 dev eth1 proto kernel metric 256 pref medium local 2100:2::1 dev lo proto none metric 0 pref medium 2100:2::/120 dev eth2 proto kernel metric 256 pref medium 2100:3::/64 via 2100:1::64 dev eth1 metric 1024 pref medium local fe80::e0:f9ff:fe09:3cac dev lo proto none metric 0 pref medium local fe80::e0:f9ff:fe1c:b974 dev lo proto none metric 0 pref medium fe80::/64 dev eth1 proto kernel metric 256 pref medium fe80::/64 dev eth2 proto kernel metric 256 pref medium ff00::/8 dev red metric 256 pref medium ff00::/8 dev eth1 metric 256 pref medium ff00::/8 dev eth2 metric 256 pref medium unreachable default dev lo metric 240 error -113 pref medium Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/route.c | 40 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 38 insertions(+), 2 deletions(-) commit 411963a6eb6258e3ee8a52bcb5b80af1be14f197 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Wed Apr 27 15:54:50 2016 +0800 dt-bindings: rockchip-dw-mshc: add description for rk3399 Add "rockchip,rk3399-dw-mshc", "rockchip,rk3288-dw-mshc" for dwmmc on rk3399 platform. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Documentation/devicetree/bindings/mmc/rockchip-dw-mshc.txt | 1 + 1 file changed, 1 insertion(+) commit ae9b9a9d3c480376b8225c212735fb298d7c799f Author: Chao Yu <yuchao0@huawei.com> Date: Sun Apr 24 21:54:51 2016 +0800 MAINTAINERS: update my email address I've changed employer, update my email address to the new one. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8a350183010a5557287a10c2a13b1a4cbaa7b130 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 21 15:12:44 2016 +0900 i2c: uniphier: add "\n" at the end of error log Just in case. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-uniphier-f.c | 2 +- drivers/i2c/busses/i2c-uniphier.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit f3a36fbdd359608bf73d674533cc419bf7e65aae Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Fri Apr 22 15:19:54 2016 +0200 i2c: mv64xxx: remove CONFIG_HAVE_CLK conditionals When clock support was added to the i2c-mv64xxx, not all clk functions had stubs when for !CONFIG_HAVE_CLK configurations. However, nowadays, both "struct clk" and all the clock framework functions have stubs when CONFIG_HAVE_CLK is not enabled, so it no longer makes sense to carry such compile-time conditionals in the driver. This commit was compile tested on both ARM64 (which has both CONFIG_OF=y and CONFIG_HAVE_CLK=y) and PowerPC c2k_defconfig (which has CONFIG_OF=y, CONFIG_HAVE_CLK disabled, and the i2c-mv64xxx driver enabled). The only non-trivial change is in the mv64xxx_of_config() function, which was returning -ENODEV unconditionally if CONFIG_HAVE_CLK was disabled. Simply removing this condition works fine because the first test done by the function is to verify if drv_data->clk points to a valid clock, and if it doesn't, we return -ENODEV. When CONFIG_HAVE_CLK is disabled, devm_clk_get() unconditionally returns NULL, so mv64xxx_of_config() will return -ENODEV when no clock is provided, which is the intended behavior. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-mv64xxx.c | 25 ++++++------------------- 1 file changed, 6 insertions(+), 19 deletions(-) commit 70719350ca250a8397b74f416a45df3d1868a1d2 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Fri Apr 22 15:19:53 2016 +0200 i2c: mv64xxx: use clk_{prepare_enable,disable_unprepare} Instead of separately calling clk_prepare()/clk_enable(), use clk_prepare_enable(), and instead of calling clk_disable()/clk_unprepare(), use clk_disable_unprepare(). Those handy shortcuts have been introduced specifically to simplify the numerous call sites were both functions were called in sequence. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-mv64xxx.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) commit 9f4d6f164229d4221272186597d9393f654adbb9 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Fri Apr 22 15:19:52 2016 +0200 i2c: mv64xxx: handle probe deferral for the clock If a clock is registered by a platform driver and not by the OF_CLK_DECLARE() mechanism, it might show up after the first attempt to probe i2c-mv64xxx. In order to solve this, we need to handle -EPROBE_PREFER as a special return value of devm_clk_get(), and return the same error code from probe(). This gives us three situations: - There is no reference to a clock in the DT. In this case, devm_clk_get() returns an error that is not -EPROBE_DEFER (something like -ENODEV), and we continue the probing without enabling the clock. - There is a reference to the clock in the DT, and the clock is ready. devm_clk_get() returns a valid reference to the clock, and we prepare/enable it. - There is a reference to the clock in the DT, but the clock is not ready. devm_clk_get() returns -EPROBE_DEFER, and we exit from probe() with the same error code so that probe() is tried again later. This is needed for Marvell Armada 7K/8K, where the clock driver is a platform driver. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-mv64xxx.c | 2 ++ 1 file changed, 2 insertions(+) commit 05872b8039101867e7312c6c3a560b887b2d9079 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Fri Apr 22 15:19:51 2016 +0200 i2c: mv64xxx: enable the driver on ARCH_MVEBU The new ARM64 Marvell Armada 7K/8K SoC family is using the same I2C controller as the 32-bits Marvell EBU SoCs, so this commit allows mv64xxx to be enabled when ARCH_MVEBU=y. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe600cf6424ff45712a175351b11c3ff1206ff2c Author: David Daney <david.daney@cavium.com> Date: Wed Apr 27 11:44:39 2016 +0200 i2c: octeon: Add workaround for broken irqs on CN3860 CN3860 does not interrupt the CPU when the i2c status changes. If we get a timeout, and see the status has in fact changed, we know we have this problem, and drop back to polling. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 53 +++++++++++++++++++++++++++++++++++++++-- 1 file changed, 51 insertions(+), 2 deletions(-) commit 570d8e9398011a63590c281a36cdce311196608e Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Wed Apr 27 17:53:08 2016 +0200 taskstats: fix nl parsing in accounting/getdelays.c The type TASKSTATS_TYPE_NULL should always be ignored. When jumping to the next attribute, only the length of the current attribute should be added, not the length of all nested attributes. This last bug was not visible before commit 80df554275c2, because the kernel didn't put more than two nested attributes. Fixes: a3baf649ca9c ("[PATCH] per-task-delay-accounting: documentation") Fixes: 80df554275c2 ("taskstats: use the libnl API to align nlattr on 64-bit") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/accounting/getdelays.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 714749313da9800ecc10bfc2bfab87540a349e97 Author: Tony Lindgren <tony@atomide.com> Date: Wed Apr 27 09:40:09 2016 -0700 ARM: omap2plus_defconfig: Enable PWM and ir-rx51 as loadable modules These are available on n900. Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 5 +++++ 1 file changed, 5 insertions(+) commit beff053c0ef6983897e3481169292e6435ef0a2d Author: Matthias Reichl <hias@horus.com> Date: Wed Apr 27 15:26:52 2016 +0200 ASoC: bcm2835: Add S16_LE support via packed DMA transfers The bcm2835-i2s driver already has support for the S16_LE format but that format hasn't been made available because dmaengine_pcm didn't support packed data transfers. bcm2835-i2s needs 16-bit left+right channel data to be packed into a 32-bit word, the FIFO register is 32-bit only and doesn't support 16-bit access. Now that dmaengine_pcm supports packed transfers the format can be made available by setting the SND_DMAENGINE_PCM_DAI_FLAG_PACK flag. No further configuration is necessary: - snd_dmaengine_dai_dma_data.addr_width is already set to DMA_SLAVE_BUSWIDTH_4_BYTES to force 32-bit DMA transfers - dmaengine_pcm will pick up the S16_LE format from the DAI configuration and make it available since it's no longer masked out due to the PACK flag. - there are no further corner cases to catch in hw_params, since the channel count is fixed at 2 we always have two 16-bit stereo samples that can be transferred via 32-bit DMA Signed-off-by: Matthias Reichl <hias@horus.com> Tested-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/bcm/bcm2835-i2s.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit cc70666c252ce43fface105a44b6e178831660cd Merge: 60507fe 73fe01c Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 27 17:35:42 2016 +0100 Merge branch 'topic/dmaengine' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-bcm2835 commit 73fe01cfb3babff01748a9fbc95cc3ea2079cc7f Author: Matthias Reichl <hias@horus.com> Date: Wed Apr 27 15:26:51 2016 +0200 ASoC: dmaengine_pcm: Add support for packed transfers dmaengine_pcm currently only supports setups where FIFO reads/writes correspond to exactly one sample, eg 16-bit sample data is transferred via 16-bit FIFO accesses, 32-bit data via 32-bit accesses. This patch adds support for setups with fixed width FIFOs where multiple samples are packed into a larger word. For example setups with a 32-bit wide FIFO register that expect 16-bit sample transfers to be done with the left+right sample data packed into a 32-bit word. Support for packed transfers is controlled via the SND_DMAENGINE_PCM_DAI_FLAG_PACK flag in snd_dmaengine_dai_dma_data.flags If this flag is set dmaengine_pcm doesn't put any restriction on the supported formats and sets the DMA transfer width to undefined. This means control over the constraints is now transferred to the DAI driver and it's responsible to provide proper configuration and check for possible corner cases that aren't handled by the ALSA core. Signed-off-by: Matthias Reichl <hias@horus.com> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/dmaengine_pcm.h | 12 ++++++++ sound/core/pcm_dmaengine.c | 11 +++++-- sound/soc/soc-generic-dmaengine-pcm.c | 57 +++++++++++++++++++++-------------- 3 files changed, 55 insertions(+), 25 deletions(-) commit 06eb49f72fa57f5a49acdf9f4af84d2d326513b3 Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Wed Apr 27 14:52:56 2016 +0800 ASoC: topology: Check size mismatch of ABI objects before parsing If size mismatch of manifest, ABI headers or elements is found, stop parsing topology info and return the error. New fields may be append to the tail of ABI objects which will cause object size to increase. If user space and kernel use different versions of ABI, size mismatch will be detected here. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/soc-topology.c | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) commit 7de76b621f77aba456f594e4621eca2e94a146f3 Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Wed Apr 27 14:52:38 2016 +0800 ASoC: topology: Check failure to create a widget Stop loading topology info if error happens when creating a widget. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/soc-topology.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 129d7cf98f5c739014ae5aa0311e48f6a64b0758 Author: Wadim Egorov <w.egorov@phytec.de> Date: Tue Apr 26 16:54:04 2016 +0200 regulator: rk808: Add rk808_reg_ops_ranges for LDO3 LDO_REG3 descriptor is using linear_ranges. Add and use proper ops for LDO_REG3. Signed-off-by: Wadim Egorov <w.egorov@phytec.de> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/rk808-regulator.c | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) commit 150fa1128438746280d9d9b403f0a42883a0e70c Author: Gregory CLEMENT <gregory.clement@free-electrons.com> Date: Wed Apr 27 15:36:42 2016 +0200 arm64: dts: marvell: Use a SoC-specific compatible for xHCI on Armada37xx Even if the Armada 37xx does not any specific setup, the device tree binding documentation requires to use a SoC-specific version corresponding to the platform first followed by the generic version. This patch introduce this new compatible string and updates the documentation accordingly. Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Documentation/devicetree/bindings/usb/usb-xhci.txt | 1 + arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit cc2684c449a4f637cb9f978f66747e5dc8ae9f49 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 23 23:24:19 2016 +0100 arm64: dts: marvell: Rename armada-37xx USB node No need to reflect the USB version in the node name. Cc: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> [gregory.clement@free-electrons.com: drop Fixes tag as it is not a bug fix.] arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7b01cff5ccc3cd6c366ab9040d789e3e5e2debb4 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 23 23:24:18 2016 +0100 arm64: dts: marvell: Clean up armada-3720-db Instead of duplicating the SoC's node hierarchy, including a bus node named "internal-regs", reference the actually desired nodes by label, like Berlin already does. Add labels where necessary. Drop an inconsistent white line while at it. Cc: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> [gregory.clement@free-electrons.com: drop Fixes tag as it is not a bug fix.] arch/arm64/boot/dts/marvell/armada-3720-db.dts | 32 ++++++++++---------------- arch/arm64/boot/dts/marvell/armada-372x.dtsi | 1 - arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 4 ++-- 3 files changed, 14 insertions(+), 23 deletions(-) commit bd023ada36a66fe3d2fde619926b49b9a0428133 Author: Andreas Dannenberg <dannenberg@ti.com> Date: Tue Apr 26 17:15:57 2016 -0500 ASoC: add support for TAS5720 digital amplifier The Texas Instruments TAS5720L/M device is a high-efficiency mono Class-D audio power amplifier optimized for high transient power capability to use the dynamic power headroom of small loudspeakers. Its digital time division multiplexed (TDM) interface enables up to 16 devices to share the same bus. Signed-off-by: Andreas Dannenberg <dannenberg@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 8 + sound/soc/codecs/Makefile | 2 + sound/soc/codecs/tas5720.c | 620 +++++++++++++++++++++++++++++++++++++++++++++ sound/soc/codecs/tas5720.h | 90 +++++++ 4 files changed, 720 insertions(+) commit 4e2f17be8f63a6ad9ebd4cdfce627e3dd25d80bb Author: Andreas Dannenberg <dannenberg@ti.com> Date: Tue Apr 26 17:15:56 2016 -0500 ASoC: add TA5720 digital amplifier DT bindings The Texas Instruments TAS5720L/M device is a high-efficiency mono Class-D audio power amplifier optimized for high transient power capability to use the dynamic power headroom of small loudspeakers. Its digital time division multiplexed (TDM) interface enables up to 16 devices to share the same bus. Signed-off-by: Andreas Dannenberg <dannenberg@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/tas5720.txt | 25 ++++++++++++++++++++++ 1 file changed, 25 insertions(+) commit 45389c47526d1eca70f96872c172aea0941e8520 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue Apr 26 11:29:45 2016 +0100 regulator: core: Add early supply resolution for regulators The call to set_machine_constraints() in regulator_register(), will attempt to get the voltage for the regulator. If a regulator is in bypass will fail to get the voltage (ie. it's bypass voltage) and hence register the regulator, because the supply for the regulator has not been resolved yet. To fix this, add a call to regulator_resolve_supply() before we call set_machine_constraints(). If the call to regulator_resolve_supply() fails, rather than returning an error at this point, allow the registration of the regulator to continue because for some regulators resolving the supply at this point may not be necessary and it will be resolved later as more regulators are added. Furthermore, if the supply is still not resolved for a bypassed regulator, this will be detected when we attempt to get the voltage for the regulator and an error will be propagated at this point. If a bypassed regulator does not have a supply when we attempt to get the voltage, rather than returing -EINVAL, return -EPROBE_DEFER instead to allow the registration of the regulator to be deferred and tried again later. Please note that regulator_resolve_supply() will call regulator_dev_lookup() which may acquire the regulator_list_mutex. To avoid any deadlocks we cannot hold the regulator_list_mutex when calling regulator_resolve_supply(). Therefore, rather than holding the lock around a large portion of the registration code, just hold the lock when aquiring any GPIOs and setting up supplies because these sections may add entries to the regulator_map_list and regulator_ena_gpio_list, respectively. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 37 ++++++++++++++++++++++++++----------- 1 file changed, 26 insertions(+), 11 deletions(-) commit cbc13a66fdd89ac5e360af32fec0a1a4fcd4d2f1 Merge: c438b9d fef9501 Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 27 16:32:14 2016 +0100 Merge branch 'topic/bypass' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator into regulator-supply commit c145344763192042135ef6172b779baaf4a16c1e Author: Yuan Yao <yao.yuan@nxp.com> Date: Wed Apr 27 16:12:36 2016 +0800 spi: spi-fsl-dspi: Update DT binding documentation DSPI driver support the register on the controller with big endian mode R/W. But not use the regmap API. So update the binding documentation for "big-endian". Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 56574d541f93cf8c9449f9ecadc83d97323cfcec Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Wed Apr 27 14:58:29 2016 +0100 ASoC: wm_adsp: factor out freeing of alg regions Add a function to delete and free the contents of the alg_regions list. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) commit 401cf1466a59139ec1805e2171d43a32be92f89c Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Wed Apr 27 14:58:28 2016 +0100 ASoC: arizona: call wm_adsp2_remove when codec driver is removed Ensure that the wm_adsp driver cleans up when the codec driver is removed. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/cs47l24.c | 5 +++++ sound/soc/codecs/wm5102.c | 4 ++++ sound/soc/codecs/wm5110.c | 6 ++++++ 3 files changed, 15 insertions(+) commit 66225e98b985047ef214632413cc404a6341c960 Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Wed Apr 27 14:58:27 2016 +0100 ASoC: wm_adsp: free memory when unloaded or closed The patch adds a wm_adsp2_remove() function to ensure that memory is freed when the driver is unloaded or shut down. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 20 ++++++++++++++++++++ sound/soc/codecs/wm_adsp.h | 1 + 2 files changed, 21 insertions(+) commit 05195ed3ec96926388d253608a40d7f2b4b07413 Author: Hans de Goede <hdegoede@redhat.com> Date: Wed Apr 27 15:59:27 2016 +0200 regulator: axp20x: Fix axp22x ldo_io voltage ranges The minium voltage of 1800mV is a copy and paste error from the axp20x regulator info. The correct minimum voltage for the ldo_io regulators on the axp22x is 700mV. Fixes: 1b82b4e4f954 ("regulator: axp20x: Add support for AXP22X regulators") Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/axp20x-regulator.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a8944c5bf86dc6c153a71f2a386738c0d3f5ff9c Merge: 67d6129 4cb9344 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 27 17:02:24 2016 +0200 Merge tag 'perf-core-for-mingo-20160427' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - perf trace --pf maj/min/all works with --call-graph: (Arnaldo Carvalho de Melo) Tracing write syscalls and major page faults with callchains while starting firefox, limiting the stack to 5 frames: # perf trace -e write --pf maj --max-stack 5 firefox 589.549 ( 0.014 ms): firefox/15377 write(fd: 4, buf: 0x7fff80acc898, count: 151) = 151 [0xfaed] (/usr/lib64/libpthread-2.22.so) fire_glxtest_process+0x5c (/usr/lib64/firefox/libxul.so) InstallGdkErrorHandler+0x41 (/usr/lib64/firefox/libxul.so) XREMain::XRE_mainInit+0x12c (/usr/lib64/firefox/libxul.so) XREMain::XRE_main+0x1e4 (/usr/lib64/firefox/libxul.so) 760.704 ( 0.000 ms): firefox/15332 majfault [gtk_tree_view_accessible_get_type+0x0] => /usr/lib64/libgtk-3.so.0.1800.9@0xa0850 (x.) gtk_tree_view_accessible_get_type+0x0 (/usr/lib64/libgtk-3.so.0.1800.9) gtk_tree_view_class_intern_init+0x1a54 (/usr/lib64/libgtk-3.so.0.1800.9) g_type_class_ref+0x6dd (/usr/lib64/libgobject-2.0.so.0.4600.2) [0x115378] (/usr/lib64/libgnutls.so.30.6.3) This automagically selects "--call-graph dwarf", use "--call-graph fp" on systems where -fno-omit-frame-pointer was used to built the components of interest, to incur in less overhead, or tune "--call-graph dwarf" appropriately, see 'perf record --help'. - Allow /proc/sys/kernel/perf_event_max_stack, that defaults to the old hard coded value of PERF_MAX_STACK_DEPTH (127), useful for huge callstacks for things like Groovy, Ruby, etc, and also to reduce overhead by limiting it to a smaller value, upcoming work will allow this to be done per-event (Arnaldo Carvalho de Melo) - Make 'perf trace --min-stack' be honoured by --pf and --event (Arnaldo Carvalho de Melo) - Make 'perf evlist -v' decode perf_event_attr->branch_sample_type (Arnaldo Carvalho de Melo) # perf record --call lbr usleep 1 # perf evlist -v cycles:ppp: ... sample_type: IP|TID|TIME|CALLCHAIN|PERIOD|BRANCH_STACK, ... branch_sample_type: USER|CALL_STACK|NO_FLAGS|NO_CYCLES # - Clear dummy entry accumulated period, fixing such 'perf top/report' output as: (Kan Liang) 4769.98% 0.01% 0.00% 0.01% tchain_edit [kernel] [k] update_fast_timekeeper - System calls with pid_t arguments gets them augmented with the COMM event more thoroughly: # trace -e perf_event_open perf stat -e cycles -p 15608 6.876 ( 0.014 ms): perf_event_open(attr_uptr: 0x2ae20d8, pid: 15608 (hexchat), cpu: -1, group_fd: -1, flags: FD_CLOEXEC) = 3 6.882 ( 0.005 ms): perf_event_open(attr_uptr: 0x2ae20d8, pid: 15639 (gmain), cpu: -1, group_fd: -1, flags: FD_CLOEXEC) = 4 6.889 ( 0.005 ms): perf_event_open(attr_uptr: 0x2ae20d8, pid: 15640 (gdbus), cpu: -1, group_fd: -1, flags: FD_CLOEXEC) = 5 ^^^^^^^^^^^^^^^^^^ ^C - Fix offline module name mismatch issue in 'perf probe' (Ravi Bangoria) - Fix module probe issue if no dwarf support in (Ravi Bangoria) Assorted fixes: - Fix off-by-one in write_buildid() (Andrey Ryabinin) - Fix segfault when printing callchains in 'perf script' (Chris Phlipot) - Replace assignment with comparison on assert check in 'perf test' entry (Colin Ian King) - Fix off-by-one comparison in intel-pt code (Colin Ian King) - Close target file on error path in 'perf probe' (Masami Hiramatsu) - Set default kprobe group name if not given in 'perf probe' (Masami Hiramatsu) - Avoid partial perf_event_header reads (Wang Nan) Infrastructure changes: - Update x86's syscall_64.tbl copy, adding preadv2 & pwritev2 (Arnaldo Carvalho de Melo) - Make the x86 clean quiet wrt syscall table removal (Jiri Olsa) Cleanups: - Simplify wrapper for LOCK_PI in 'perf bench futex' (Davidlohr Bueso) - Remove duplicate const qualifier (Eric Engestrom) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 41ed943d855c3fa2bf6fecc33250b294bd568b7a Merge: f28f20d dcd36d0 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 27 16:57:36 2016 +0200 Merge branch 'for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu into core/rcu Pull RCU updates from Paul E. McKenney: * Documentation updates, including fixes to the design-level requirements documentation and a fixed version of the design-level data-structure documentation. These fixes include removing cartoons and getting rid of the html/htmlx duplication. * Further improvements to the new-age expedited grace periods. * Miscellaneous fixes. * Torture-test changes, including a new rcuperf module for measuring RCU grace-period performance and scalability, which is useful for the expedited-grace-period changes. Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 4cfcb35189f62ae351194827fca1787053a66235 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Fri Apr 8 15:27:12 2016 +0800 Documentation: arm64: Add Hisilicon Hip06 D03 dts binding This patch adds documentation for the devicetree bindings used by the DT files of Hisilicon Hip06 D03 board. Meanwhile, reorder the soc/board name alphabetically. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> .../devicetree/bindings/arm/hisilicon/hisilicon.txt | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit aa8d3e74f54d0af737c46c77de35b39d9a44592b Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Fri Apr 8 15:27:11 2016 +0800 arm64: dts: Add initial dts for Hisilicon Hip06 D03 board The Hip06 soc has same cpu topology compared with Hip05, four clusters and each cluster has quard Cortex-A57, but with different IO part, like HNS, SAS and PCI, they are all upgraded. There are also not same in ITS, MBIGEN and SMMU, etc. This patch adds the initial dts for hip06 d03 board. Note, there is no serial, because the soc use LPC uart, the serial node is not needed. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/Makefile | 4 +- arch/arm64/boot/dts/hisilicon/hip06-d03.dts | 34 +++ arch/arm64/boot/dts/hisilicon/hip06.dtsi | 307 ++++++++++++++++++++++++++++ 3 files changed, 344 insertions(+), 1 deletion(-) commit 162d23bfd18cec10bd5940ff264debf3c6121f34 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Fri Apr 8 15:31:51 2016 +0800 arm64: dts: hip05: Add nor flash support This patch is to add support nor-flash. Notice, the pre-defined partitions may not be used. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hip05-d02.dts | 34 +++++++++++++++++++++++++++++ arch/arm64/boot/dts/hisilicon/hip05.dtsi | 6 +++++ 2 files changed, 40 insertions(+) commit 70896650732afd64c410f85c819281dbce8a0974 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Fri Apr 8 15:31:50 2016 +0800 arm64: dts: hip05: fix its node without msi-cells Fix commit abf9c25d55e8 ("arm64: dts: hip05: Append all gicv3 ITS entries"), it forgets the property msi-cell, see arm,gic-v3.txt. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hip05.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit 65da9a0a3bf2202c2432f42d41eb908f2fa30579 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Wed Apr 27 10:13:46 2016 -0400 tracing: Make filter_check_discard() local Nothing outside of the tracing directory calls filter_check_discard() or check_filter_check_discard(). They should not be called by modules. Move their prototypes into the local tracing header and remove their EXPORT_SYMBOL() macros. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 6 ------ kernel/trace/trace.c | 2 -- kernel/trace/trace.h | 6 ++++++ 3 files changed, 6 insertions(+), 8 deletions(-) commit 9d3f65b0c2ddb926340af96eb89ad9be589865c0 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Sun Apr 24 23:49:52 2016 -0700 mwifiex: increase dwell time for active scan It's been observed that sometimes AP's probe response is received after scan duration gets completed for the channel. This happens especially when wildcard scan is performed along with specific SSID scan. We will increase the time from 30 msecs to 40 msecs. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/main.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1b499cb72f26bbf44f2fa158c2d1487730aae96a Author: Amitkumar Karwar <akarwar@marvell.com> Date: Sun Apr 24 23:49:51 2016 -0700 mwifiex: disable channel filtering feature in firmware As 2.4Ghz channels are overlapping, sometimes AP responds to probe request even if it's operating on neighbouring channel. Currently firmware drops those scan entries, as current channel doesn't match with APs channel. This patch enables MWIFIEX_DISABLE_CHAN_FILT flag in scan command to disable the feature so that better scan results will be received in 2.4Ghz band. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit d286af9bf40ab88f2035aef293f6ecae4187c6bb Author: Amitkumar Karwar <akarwar@marvell.com> Date: Thu Apr 21 08:07:56 2016 -0700 mwifiex: avoid querying wakeup reason when wowlan is disabled In cfg80211 resume handler, we query wakeup reason from firmware and report to cfg80211. if wowlan is disabled, connection is already terminated during suspend. We don't need to query wakeup reason in this case. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 4 ++++ 1 file changed, 4 insertions(+) commit df2288623ee0ce77743d76ed8ca816e92246e77b Author: Amitkumar Karwar <akarwar@marvell.com> Date: Thu Apr 21 08:07:55 2016 -0700 mwifiex: report wowlan wakeup reasons correctly It's been observed that wakeup on GTK rekey failure wasn't reported to cfg80211. This patch corrects the check so that all valid wakeup reasons are reported. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 3f210e2f1269ffe83188db2f1f5839da907fc722 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Thu Apr 21 08:07:54 2016 -0700 mwifiex: fix coding style Redundant space in case statement is removed. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8d666302df95ab585f5cc7b2fb779991f8797eb5 Author: Marty Faltesek <mfaltesek@google.com> Date: Wed Apr 20 00:22:01 2016 -0400 mwifiex: transmit packet stats incorrect. tx_packets counter is incremented for aggregated packets, when it had already been incremented for the aggregated packet's constituent parts. Removing the extra count. Signed-off-by: Marty Faltesek <mfaltesek@google.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/txrx.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit b977d305ad20e05212c0ded2a7ef90e411edc1b3 Author: Marty Faltesek <mfaltesek@google.com> Date: Wed Apr 20 00:20:52 2016 -0400 mwifiex: fw download does not release sdio bus during failure Signed-off-by: Marty Faltesek <mfaltesek@google.com> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/sdio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit bb28c28ee10559c5bc5b5f48c2d6f6f2f6bd5586 Author: Marty Faltesek <mfaltesek@google.com> Date: Wed Apr 20 00:19:35 2016 -0400 mwifiex: bridged packets cause wmm_tx_pending counter to go negative When a packet is queued from the bridge, wmm_tx_pending is not incremented, but when the packet is dequeued the counter is decremented. Signed-off-by: Marty Faltesek <mfaltesek@google.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/uap_txrx.c | 4 ++++ 1 file changed, 4 insertions(+) commit 80833ff0eea693d8e0c3305a869159a64141fdad Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 27 09:06:49 2016 +0200 ASoC: atmel_ssc_dai: read DSP mode A data on rising edges of bclk Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/atmel/atmel_ssc_dai.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4cb93446c587d56e2a54f4f83113daba2c0b6dee Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 27 10:16:24 2016 -0300 perf tools: Set the maximum allowed stack from /proc/sys/kernel/perf_event_max_stack There is an upper limit to what tooling considers a valid callchain, and it was tied to the hardcoded value in the kernel, PERF_MAX_STACK_DEPTH (127), now that this can be tuned via a sysctl, make it read it and use that as the upper limit, falling back to PERF_MAX_STACK_DEPTH for kernels where this sysctl isn't present. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-yjqsd30nnkogvj5oyx9ghir9@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-report.txt | 2 +- tools/perf/Documentation/perf-script.txt | 2 +- tools/perf/Documentation/perf-top.txt | 2 +- tools/perf/Documentation/perf-trace.txt | 2 +- tools/perf/builtin-report.c | 4 ++-- tools/perf/builtin-script.c | 4 +++- tools/perf/builtin-top.c | 4 ++-- tools/perf/builtin-trace.c | 4 ++-- tools/perf/perf.c | 5 +++++ tools/perf/tests/hists_cumulate.c | 2 +- tools/perf/tests/hists_filter.c | 2 +- tools/perf/tests/hists_output.c | 2 +- tools/perf/util/machine.c | 6 +++--- tools/perf/util/scripting-engines/trace-event-perl.c | 2 +- tools/perf/util/util.c | 2 ++ tools/perf/util/util.h | 1 + 16 files changed, 28 insertions(+), 18 deletions(-) commit c5dfd78eb79851e278b7973031b9ca363da87a7e Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 21 12:28:50 2016 -0300 perf core: Allow setting up max frame stack depth via sysctl The default remains 127, which is good for most cases, and not even hit most of the time, but then for some cases, as reported by Brendan, 1024+ deep frames are appearing on the radar for things like groovy, ruby. And in some workloads putting a _lower_ cap on this may make sense. One that is per event still needs to be put in place tho. The new file is: # cat /proc/sys/kernel/perf_event_max_stack 127 Chaging it: # echo 256 > /proc/sys/kernel/perf_event_max_stack # cat /proc/sys/kernel/perf_event_max_stack 256 But as soon as there is some event using callchains we get: # echo 512 > /proc/sys/kernel/perf_event_max_stack -bash: echo: write error: Device or resource busy # Because we only allocate the callchain percpu data structures when there is a user, which allows for changing the max easily, its just a matter of having no callchain users at that point. Reported-and-Tested-by: Brendan Gregg <brendan.d.gregg@gmail.com> Reviewed-by: Frederic Weisbecker <fweisbec@gmail.com> Acked-by: Alexei Starovoitov <ast@kernel.org> Acked-by: David Ahern <dsahern@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Wang Nan <wangnan0@huawei.com> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/r/20160426002928.GB16708@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Documentation/sysctl/kernel.txt | 14 ++++++++++++++ arch/arm/kernel/perf_callchain.c | 2 +- arch/arm64/kernel/perf_callchain.c | 4 ++-- arch/metag/kernel/perf_callchain.c | 2 +- arch/mips/kernel/perf_event.c | 4 ++-- arch/powerpc/perf/callchain.c | 4 ++-- arch/sparc/kernel/perf_event.c | 6 +++--- arch/x86/events/core.c | 4 ++-- arch/xtensa/kernel/perf_event.c | 4 ++-- include/linux/perf_event.h | 8 ++++++-- kernel/bpf/stackmap.c | 8 ++++---- kernel/events/callchain.c | 35 +++++++++++++++++++++++++++++++++-- kernel/sysctl.c | 12 ++++++++++++ 13 files changed, 84 insertions(+), 23 deletions(-) commit 88677db54dba68ce19952d5bcdf0fda43094b31f Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 12:11:28 2016 +0200 ARM: dts: at91: VInCo: fix phy reset gpio flag Fix gpio active flag for the phy reset-gpios property. The line is active low instead of active high. Actually, this flags was never used by the macb driver. Reported-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Cc: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/at91-vinco.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 517550075c31917dc729d7cec0b4a0ca65294f14 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 15:08:47 2016 +0200 ARM: dts: at91: sama5d2: add slow clock to watchdog node As the watchdog timer needs the slow clock, add it to the currently defined wdt node. Reported-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> arch/arm/boot/dts/sama5d2.dtsi | 1 + 1 file changed, 1 insertion(+) commit e4b9a21b25f0ca087cbe00d2ee183a5a28f12ea3 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 14:19:25 2016 +0200 ARM: dts: at91: sama5d2: add shutdown controller node Add the SAMA5D2-Compatible Shutdown Controller node to sama5d2.dtsi and the use of it in the sama5d2 Xplained board dts file. Enable the RTC wakeup event and the "wake up" button support through the input "0" that is present on the board. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/at91-sama5d2_xplained.dts | 9 +++++++++ arch/arm/boot/dts/sama5d2.dtsi | 9 +++++++++ 2 files changed, 18 insertions(+) commit 20ce85130df56ceb2cfaa11743e5a0fe0265ebde Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 13:32:47 2016 +0200 ARM: dts: at91: sama5d4: add watchdog interrupt property The "interrupts" property is missing from the watchdog node. Add it with highest priority value of 7. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d4.dtsi | 1 + 1 file changed, 1 insertion(+) commit ed87957b18f238516e578e5dbd44a5db11300831 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 18:04:36 2016 +0200 ARM: multi_v7_defconfig: add the Atmel sama5d2-compatible ADC driver Add the new sama5d2-compatible ADC driver as a module. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 49518015fc53a33df0baa432d7fcf7ece33e9a04 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 18:02:22 2016 +0200 ARM: multi_v7_defconfig: add the Atmel Audio microphone interface PDMIC Add the Atmel Pulse Density Modulation Interface Controller (PDMIC) driver as a module. It's used by sama5d2 SoC for instance. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 955c1129ae8c0ff8b97d16fdd4787b1d820b837a Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 18:00:24 2016 +0200 ARM: multi_v7_defconfig: add Atmel ISI (Image Sensor Interface) driver Add the Atmel Image Sensor Interface (ISI) VIDEO driver as a module. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 54b31de0be58d9a9704f91930af0e7a15866de99 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 17:59:18 2016 +0200 ARM: multi_v7_defconfig: add Atmel watchdog timers Add both Atmel watchdog timers to the multi_v7_defconfig. They are added as part of the kernel because it's a core piece of the system. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/multi_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit a95c630724e368e97e7e38b84f4036f9eed49c08 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Mar 30 16:19:37 2016 +0200 ARM: multi_v7_defconfig: add HLCDC drivers as modules Add the HLCDC drivers to multi_v7_defconfig. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/configs/multi_v7_defconfig | 3 +++ 1 file changed, 3 insertions(+) commit 35f110ec54e7683d7850f1897a00a7e5cf4190b0 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 17:36:31 2016 +0200 ARM: at91/defconfig: add PDMIC driver to sama5_defconfig Add Pulse Density Modulation Interface Controller (PDMIC) driver compilation for sama5 default configuration. Is used by sama5d2 SoC for instance. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> arch/arm/configs/sama5_defconfig | 1 + 1 file changed, 1 insertion(+) commit a331acbd553f37c15eba9be342766b01ae527be2 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 16:20:07 2016 +0200 ARM: at91/defconfig: add HLCDC driver to sama5_defconfig Add the LCD DRM driver with all its dependencies: - the MFD driver - the backlight PWM - the simple panel driver Remove the CONFIG_FB as it is not needed on any sama5 device. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> arch/arm/configs/sama5_defconfig | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 2b1b2f0e764d349f7455aaca9c17d4b0c2f1ee1b Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Tue Apr 26 15:44:30 2016 +0200 ARM: at91/defconfig: add the HDMA controller to sama5_defconfig Selection of the HDMAC option is now needed to allow some sama5 devices to have the DMA driver compiled and available. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> arch/arm/configs/sama5_defconfig | 1 + 1 file changed, 1 insertion(+) commit 8527f68849caadd0b7c560c613f2e18c9e1f8d47 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Thu Apr 21 14:09:42 2016 -0700 wcn36xx: Set SMD timeout to 10 seconds After booting the wireless subsystem and uploading the NV blob to the WCNSS_CTRL service the remote continues to do things and will not start servicing wlan-requests for another 2-5 seconds (measured). The downstream code does not have any special handling for this case, but has a timeout of 10 seconds for the communication layer. By extending the wcn36xx timeout to match this we follows the same flow for the boot procedure and can successfully configure WiFi as wlan0 is registered. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3a1a4559624a51e1f4ed8954d546ccc7367bb8d4 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:45:48 2016 -0700 ARM: dove: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/mach-dove/common.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit cc1e18967c540c9a3ffc30ea63e500ecaa61812a Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:38:50 2016 -0700 ARM: orion5x: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/mach-orion5x/common.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 313a98faf1e33945c59872da5a0425260ffb39b5 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:40:04 2016 -0700 ARM: mv78xx0: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Andrew Lunn <andrew@lunn.ch> Cc: Jason Cooper <jason@lakedaemon.net> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/mach-mv78xx0/common.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 3f2a09d57bb12ca55f92209b3ef0c0684cdb20b0 Author: David Lechner <david@lechnology.com> Date: Thu Apr 14 14:13:36 2016 -0500 ARM: davinci: da850: use clk->set_parent for async3 The da850 family of processors has an async3 clock domain that can be muxed to either pll0_sysclk2 or pll1_sysclk2. Now that the davinci clocks have a set_parent callback, we can use this to control the async3 mux instead of a stand-alone function. This adds a new async3_clk and sets the appropriate child clocks. The default is use to pll1_sysclk2 since it is not affected by processor frequency scaling. Signed-off-by: David Lechner <david@lechnology.com> [nsekhar@ti.com: drop unnecessary comment] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/da850.c | 81 ++++++++++++++++++------------------------- 1 file changed, 33 insertions(+), 48 deletions(-) commit 6fc9ebbdeb75197df780c52f5ebcc3eeffb9cd91 Author: David Lechner <david@lechnology.com> Date: Thu Apr 14 14:13:35 2016 -0500 ARM: davinci: Move clock init after ioremap. Some clocks (such as the USB PHY clocks in DA8xx) will need to use iomem. The davinci_common_init() function must be called before the ioremap, so the clock init is now split out as separate function. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/clock.c | 2 +- arch/arm/mach-davinci/common.c | 6 ------ arch/arm/mach-davinci/da830.c | 2 ++ arch/arm/mach-davinci/da850.c | 2 ++ arch/arm/mach-davinci/dm355.c | 1 + arch/arm/mach-davinci/dm365.c | 1 + arch/arm/mach-davinci/dm644x.c | 1 + arch/arm/mach-davinci/dm646x.c | 1 + 8 files changed, 9 insertions(+), 7 deletions(-) commit de0336b30de1b3e3ad6b76b5ccf0b4920d328313 Author: Borislav Petkov <bp@suse.de> Date: Wed Apr 27 12:21:21 2016 +0200 EDAC, amd64_edac: Issue driver banner only on success ... and don't mislead users into thinking that the driver has loaded successfully. Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/amd64_edac.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 282bf1fe6dca4b768d6bedc14aea1b82c36241c1 Author: Trent Lloyd <trent@lloyd.id.au> Date: Thu Jul 9 13:38:50 2015 +0800 HID: usbhid: quirks for Corsair RGB keyboard & mice (K70R, K95RGB, M65RGB, K70RGB, K65RGB) These devices feature multiple interfaces/endpoints: a legacy BIOS/boot interface (endpoint 0x81), as well as 2 corsair-specific keyboard interfaces (endpoint 0x82, 0x83 IN/0x03 OUT) and an RGB LED control interface (endpoint 0x84 IN/0x04 OUT) Because the extra 3 interfaces are not of subclass USB_INTERFACE_SUBCLASS_BOOT, HID_QUIRK_NOGET is not automatically set on them and a 10s timeout per-endpoint (30s per device) occurs initialising reports on boot. We configure HID_QUIRK_NO_INIT_REPORTS for these devices. Additionally the left-side G1-G18 macro keys on the K95RGB generate output on the un-opened 0x82/0x83 endpoints which causes the keyboard to stop responding waiting for this event to be collected. We enable HID_QUIRK_ALWAYS_POLL to prevent this situation from occurring. Signed-off-by: Trent Lloyd <trent@lloyd.id.au> Tested-by: SUGNIAUX Wilfried <wsu@ppharm2k20.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-ids.h | 7 +++++++ drivers/hid/usbhid/hid-quirks.c | 5 +++++ 2 files changed, 12 insertions(+) commit d686b920abb7136e0575ec974cd5a24f51a7a549 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 26 09:54:11 2016 +0200 nl80211: use nla_put_u64_64bit() for the remaining u64 attributes Nicolas converted most users, but didn't realize some were generated by macros. Convert those over as well. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Acked-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/uapi/linux/nl80211.h | 4 ++++ net/wireless/nl80211.c | 36 ++++++++++++++++++++++-------------- 2 files changed, 26 insertions(+), 14 deletions(-) commit 366f4856f0ef1f3dbdb85b0cc57bef2a77c08b86 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Tue Apr 26 11:21:34 2016 -0400 kbuild: adjust ksym_dep_filter for some cmd_* renames The following renames occurred recently: cmd_cc_i_c --> cmd_cpp_i_c cmd_as_s_S --> cmd_cpp_s_S The respective cc_*_c and as_*_S patterns no longer match the above therefore additional patterns are needed. Signed-off-by: Nicolas Pitre <nico@linaro.org> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Kbuild.include | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit edf69470f9ccd08cf799a5909b6de47d969ca29a Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Tue Apr 26 16:48:44 2016 -0400 kbuild: Fix dependencies for final vmlinux link The if_changed directive is useless against phony targets. Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Fixes: 2441e78b1919 ("kbuild: better abstract vmlinux sequential prerequisites") Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> Signed-off-by: Michal Marek <mmarek@suse.cz> Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 451938d52fe838c766687484fd9a69e35d8a68bc Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Apr 27 10:23:44 2016 +0200 gpio: clarify open drain/source docs Make the text clearer, remove reference to confusing "positive" and "negative" and elaborate a bit. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/gpio/driver.txt | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) commit 1d2ac403ae3bfde7c50328ee0d39d3fb3d8d9823 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:41 2016 +0200 drm: Protect dev->filelist with its own mutex amdgpu gained dev->struct_mutex usage, and that's because it's walking the dev->filelist list. Protect that list with it's own lock to take one more step towards getting rid of struct_mutex usage in drivers once and for all. While doing the conversion I noticed that 2 debugfs files in i915 completely lacked appropriate locking. Fix that up too. v2: don't forget to switch to drm_gem_object_unreference_unlocked. Cc: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-9-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 10 +++++----- drivers/gpu/drm/drm_drv.c | 1 + drivers/gpu/drm/drm_fops.c | 9 ++++++--- drivers/gpu/drm/drm_info.c | 4 ++-- drivers/gpu/drm/i915/i915_debugfs.c | 12 ++++++++++-- include/drm/drmP.h | 1 + 6 files changed, 25 insertions(+), 12 deletions(-) commit f47dbdd75bf3388ce8107c2e7e5a1eebd3700dd5 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:40 2016 +0200 drm: Make drm_vm_open/close_locked private to drm_vm.c It's only used for legacy mmaping support now. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-8-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_internal.h | 2 -- drivers/gpu/drm/drm_vm.c | 16 ++++------------ 2 files changed, 4 insertions(+), 14 deletions(-) commit 40647e45b92b1da599048332ec8fbd40d8d29457 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Apr 27 09:20:18 2016 +0200 drm: Hide master MAP cleanup in drm_bufs.c And again make sure it's a no-op for modern drivers. Another case of dev->struct_mutex gone for modern drivers! Note that the entirety of the legacy addmap interface is now protected by DRIVER_MODESET. Note that just auditing kernel code is not enough, since userspace loves to set up legacy maps on it's own for various things - with ums userspace and kernel space share control over resources. v2: Also add a DRIVER_* check like for all other maps functions to really short-circuit the code. And give drm_legacy_rmmap used by the dev unregister code the same treatment. v3: - remove redundant return; (Alex, Chris) - don't special case nouveau with DRIVER_KMS_LEGACY_CONTEXT. v4: Again special case nouveau. The problem is not directly in the ddx, but that it calls dri1 functions from the X server. And those do call drmAddMap. Fixed only in commit b1a630b48210d6a3c44994fce1b73273000ace5c Author: Dave Airlie <airlied@redhat.com> Date: Wed Nov 7 14:45:14 2012 +1000 nouveau: drop DRI1 device open interface. Acked-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461741618-12679-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_bufs.c | 27 ++++++++++++++++++++++----- drivers/gpu/drm/drm_drv.c | 10 +--------- include/drm/drm_legacy.h | 4 +++- 3 files changed, 26 insertions(+), 15 deletions(-) commit 8691f91b5f5b8687515654b065ebca447ba8b13a Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 25 11:29:56 2016 +0200 ARM: dts: exynos: Enable PRNG and SSS for all Exynos4 devices There is no external dependency for Security SubSystem (SSS) block so the nodes for Pseudo Random Number Generator and AES hardware acceleration can be enabled always for all Exynos4 devices. Suggested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4.dtsi | 2 -- arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 4 ---- arch/arm/boot/dts/exynos4412-trats2.dts | 8 -------- 3 files changed, 14 deletions(-) commit 6dc62f12630a9ecf0c5427c5e25df759729ebe73 Author: Chanho Park <parkch98@gmail.com> Date: Fri Feb 12 22:31:40 2016 +0900 ARM: dts: exynos: Add exynos5420-fimd compatible This patch changes the compatible of Exynos5420 fimd to "exynos5420-fimd". To support MIC bypass from display path, the new compatible is introduced for Exynos5420. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Chanho Park <chanho61.park@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5420.dtsi | 1 + 1 file changed, 1 insertion(+) commit c769c43f858a356010061694d99dd4c8c7de8ad7 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 18 09:44:13 2016 +0200 ARM: dts: exynos: Remove unsupported s2mps11 regulator bindings from Exynos5420 boards The bindings like s2mps11,buck6-ramp-enable or s2mps11,buck2-ramp-delay were ignored. They were never parsed by s2mps11 regulator driver. Also the values used in these bindings were equal to default reset values of S2MPS11 device. It is safe to remove them. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5420-arndale-octa.dts | 7 ------- arch/arm/boot/dts/exynos5420-smdk5420.dts | 7 ------- arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi | 7 ------- 3 files changed, 21 deletions(-) commit e975eef07cbca53691f504318609bb95c7e5f1ac Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:37 2016 +0200 drm: Forbid legacy MAP functions for DRIVER_MODESET Like in commit 0e975980d435d58df2d430d688b8c18778b42218 Author: Peter Antoine <peter.antoine@intel.com> Date: Tue Jun 23 08:18:49 2015 +0100 drm: Turn off Legacy Context Functions we need to again make an exception for nouveau, but everyone else really doesn't need this. Dave Airlie dug out again why we need this: The problem is the legacy dri1 open function the nouveau ddx called, and the problematic code is actually in the X server itself. It was only fixed in commit b1a630b48210d6a3c44994fce1b73273000ace5c Author: Dave Airlie <airlied@redhat.com> Date: Wed Nov 7 14:45:14 2012 +1000 nouveau: drop DRI1 device open interface. Cc: Peter Antoine <peter.antoine@intel.com> Cc: Ben Skeggs <bskeggs@redhat.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-5-git-send-email-daniel.vetter@ffwll.ch Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-6-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_bufs.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit da20dfe6b50ea4c1a82797b7ee8655a370535d73 Author: Kees Cook <keescook@chromium.org> Date: Thu Apr 21 12:53:29 2016 -0700 fs: fix over-zealous use of "const" When I was fixing up const recommendations from checkpatch.pl, I went overboard. This fixes the warning (during a W=1 build): include/linux/fs.h:2627:74: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] static inline const char * const kernel_read_file_id_str(enum kernel_read_file_id id) Reported-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/fs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0d787b143d83de94decb801701a005ffd3ec6823 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:38 2016 +0200 drm: Push struct_mutex into ->master_destroy Only two drivers implement this hook. vmwgfx (which doesn't need it really) and legacy radeon (which since v1 has been nuked, yay). v1: Rebase over radeon ums removal. Cc: Thomas Hellstrom <thellstrom@vmware.com> Cc: Alex Deucher <alexdeucher@gmail.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-6-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ec1f52efc0406a72870a1fcb859f18dea24bcd8b Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:36 2016 +0200 drm: Move drm_getmap into drm_bufs.c and give it a legacy prefix It belongs right next to the addmap and rmmap functions really. And for OCD consistency name it drm_legacy_getmap_ioctl. Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-4-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_bufs.c | 52 ++++++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/drm_ioctl.c | 54 +------------------------------------------- drivers/gpu/drm/drm_legacy.h | 2 ++ 3 files changed, 55 insertions(+), 53 deletions(-) commit 68dfbebab131146b460550cebf8c38667c490a04 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:35 2016 +0200 drm: Put legacy lastclose work into drm_legacy_dev_reinit Except for the ->lasclose driver callback evrything in drm_lastclose() is all legacy cruft and can be hidden. Which means another dev->struct_mutex site disappears entirely for modern drivers! Also while at it change the return value of drm_lastclose to void since it will always succeed. No one checks the return value of close() anyway, ever. v2: Move misplaced hunk, spotted by 0day. Cc: Thierry Reding <thierry.reding@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-3-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_fops.c | 42 +++++++++++++++++++----------------------- drivers/gpu/drm/drm_internal.h | 2 +- 2 files changed, 20 insertions(+), 24 deletions(-) commit 366884b17fae7d2a7517eea60e64d6d6754fa9db Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Apr 26 19:29:34 2016 +0200 drm: Give drm_agp_clear drm_legacy_ prefix It has a DRIVER_MODESET check to sure make it's not creating havoc for drm drivers. Make that clear in the name too. v2: Move misplaced hunk, spotted by 0day and Thierry. Cc: Thierry Reding <thierry.reding@gmail.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461691808-12414-2-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_agpsupport.c | 4 ++-- drivers/gpu/drm/drm_fops.c | 2 +- drivers/gpu/drm/drm_pci.c | 2 +- include/drm/drm_agpsupport.h | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) commit 5bcca743cb6e3ab97ff400ef92c7f57c787020f6 Author: Madhavan Srinivasan <maddy@linux.vnet.ibm.com> Date: Thu Apr 21 15:46:34 2016 +0530 powerpc/perf: Replace raw event hex values with #defines Minor cleanup patch to replace the raw event hex values in power8-pmu.c with #defines. Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/perf/power8-events-list.h | 40 +++++++++++++++++++++++++++++++++ arch/powerpc/perf/power8-pmu.c | 41 +++++++++++++++++----------------- 2 files changed, 61 insertions(+), 20 deletions(-) commit 2fc5ddaa3f1f1d7a1f7f455e287e97bf298ab8d7 Merge: 7553c7e aaa3ca8 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue Apr 26 23:24:39 2016 -0700 Merge tag 'stm-for-greg-20160420' of git://git.kernel.org/pub/scm/linux/kernel/git/ash/stm into char-misc-next Alexander writes: stm class/intel_th: Updates for 4.7 These are: * Intel TH/MSU: improved resource handling and releasing * Intel TH/MSU: rehashed locking around buffer accesses * Intel TH/outputs: better sysfs group handling * Intel TH, STM: various bugfixes and smaller improvements * Intel TH: added a PCI ID for Broxton-M SOC commit 8d2ae1cbe8a984d7a755755fb53955de2f60a2f9 Author: Jakub Wilk <jwilk@jwilk.net> Date: Wed Apr 27 01:11:21 2016 -0400 ext4: remove trailing \n from ext4_warning/ext4_error calls Messages passed to ext4_warning() or ext4_error() don't need trailing newlines, because these function add the newlines themselves. Signed-off-by: Jakub Wilk <jwilk@jwilk.net> fs/ext4/extents.c | 4 ++-- fs/ext4/extents_status.c | 2 +- fs/ext4/file.c | 2 +- fs/ext4/inline.c | 2 +- fs/ext4/mballoc.c | 2 +- fs/ext4/mmp.c | 4 ++-- fs/ext4/namei.c | 2 +- fs/ext4/resize.c | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) commit 25611e4ef5bb290805305d499715a840826462f3 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7794: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSTP Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7794.dtsi | 106 ++++++++++++++++++++--------------------- 1 file changed, 53 insertions(+), 53 deletions(-) commit f1ba73eae71fde882dcb6ca5fa61f1b3bffb7e3e Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Jun 3 10:43:13 2015 +0200 ARM: dts: r8a7793: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSTP Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793.dtsi | 102 ++++++++++++++++++++--------------------- 1 file changed, 51 insertions(+), 51 deletions(-) commit 5aa806503b48367e2e6e5ae2a6890805e40c4776 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7791: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSTP Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7791.dtsi | 146 ++++++++++++++++++++--------------------- 1 file changed, 73 insertions(+), 73 deletions(-) commit 36ee3c277e018f71d456e3d7eac2c2887128a4db Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7790: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSTP Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 138 ++++++++++++++++++++--------------------- 1 file changed, 69 insertions(+), 69 deletions(-) commit 751e29bbb64ad091c6f51704f31224aaec560f69 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Jun 3 10:14:01 2015 +0200 ARM: dts: r8a7779: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSTP Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7779.dtsi | 44 +++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 22 deletions(-) commit 0761ff2ad0c581f37067eff8c4bde65f07029fc8 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7794: Add SYSC PM Domains Add a device node for the System Controller. Hook up the Cortex-A7 CPU cores and the Cortex-A7 L2 cache/SCU to their respective PM Domains. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7794.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit a7ede1abeefd69330c5dd45b335d22af1e2baf2e Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Jun 3 10:43:13 2015 +0200 ARM: dts: r8a7793: Add SYSC PM Domains Add a device node for the System Controller. Hook up the first Cortex-A15 CPU core and the Cortex-A15 L2 cache/SCU to their respective PM Domains. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit 8574de861978d5187da4f2b7dcf127a5795e967f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7791: Add SYSC PM Domains Add a device node for the System Controller. Hook up the Cortex-A15 CPU cores and the Cortex-A15 L2 cache/SCU to their respective PM Domains. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7791.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 4c8eb3c8896d842d3fb4802dc6e5f39733596733 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Tue Jan 20 14:44:58 2015 +0100 ARM: dts: r8a7790: Add SYSC PM Domains Add a device node for the System Controller. Hook up the Cortex-A15 and Cortex-A7 CPU cores and L2 caches/SCUs to their respective PM Domains. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit b2df3aa487395a1b7170b719569769bc78939dd1 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Jun 3 10:14:01 2015 +0200 ARM: dts: r8a7779: Add SYSC PM Domains Add a device node for the System Controller. Hook up ARM CPU cores 1-3 to their respective PM Domains. Note that ARM CPU core 0 cannot be shut off. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7779.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 38dbb45ee4bc7dda4aabba2178eebff2f93380d1 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Aug 10 13:47:07 2015 +0200 arm64: dts: r8a7795: Use SYSC "always-on" PM Domain Hook up all devices that are part of the CPG/MSSR Clock Domain to the SYSC "always-on" PM Domain, for a more consistent device-power-area description in DT. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 110 +++++++++++++++---------------- 1 file changed, 55 insertions(+), 55 deletions(-) commit abbecab1a0b8c2cc07edc30c8bced855ca4e239d Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Aug 10 13:47:07 2015 +0200 arm64: dts: r8a7795: Add SYSC PM Domains Add a device node for the System Controller. Hook up the Cortex-A57 CPU cores and the Cortex-A57 and Cortex A53 L2 caches/SCUs to their respective PM Domains. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit b26a68c1fbdf34d5fcc49f9208b2bb114839a2d0 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Tue Apr 26 22:28:29 2016 -0300 ARM: dts: imx6: Do not hardcode the CLKO clock Using "IMX6QDL_CLK_CKO" for the clock is easier to read instead of the hardcoded clock number. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6dl-riotboard.dts | 2 +- arch/arm/boot/dts/imx6q-gw5400-a.dts | 2 +- arch/arm/boot/dts/imx6q-tbs2910.dts | 2 +- arch/arm/boot/dts/imx6qdl-apalis.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-apf6dev.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-gw52xx.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-gw53xx.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-gw54xx.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-nit6xlite.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-nitrogen6_max.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-rex.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-sabrelite.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-udoo.dtsi | 2 +- arch/arm/boot/dts/imx6qdl-wandboard.dtsi | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) commit b18f909376352aa1c1e755aed87f8061d9e14510 Author: Sergio Prado <sergio.prado@e-labworks.com> Date: Tue Apr 26 20:38:22 2016 -0300 ARM: dts: imx6: Add dts for Embest MarS Board Embest MarS Board [1] is a multi-core platform based on Freescale i.MX6 Cortex-A9 Dual Core, running up to 1GHz with 1 GB of RAM, 4GB of eMMC and with a 4MB SPI flash. [1] http://www.embest-tech.com/shop/star/marsboard.html Signed-off-by: Sergio Prado <sergio.prado@e-labworks.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx6q-marsboard.dts | 403 ++++++++++++++++++++++++++++++++++ 2 files changed, 404 insertions(+) commit 3892132c2716e2747e562dd9a4c025387c19c329 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Wed Apr 20 10:57:40 2016 -0500 arm64: defconfig: enable freescale/nxp config options enable standard drivers for the NXP/Freescale ls2080a and ls1043a SoCs: -system clock driver -sata (AHCI) -sd/mmc (ESDHC) -i2c support and i2c mux -i2c rtc clock -i2c sensors (as modules) Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/configs/defconfig | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit 211102d85f71dc5a01dde771e3f833f60b494661 Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Wed Apr 20 10:57:34 2016 -0500 arm64: defconfig: enable 48-bit virtual addresses Some armv8 SoCs (e.g. ls2080a) have physical memory maps with discontiguous DDR regions that require 48-bit VA to have the linear map cover the entire range of DDR. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit 7bd2c71bbd76683a110d8c37bc8828becb2846cc Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Wed Apr 20 10:57:28 2016 -0500 arm64: defconfig: cleanup the defconfig When doing: make defconfig make savedefconfig ...without making any changes, the newly saved defconfig does not match arch/arm64/configs/defconfig, and the diff looks like: $ diff defconfig arch/arm64/configs/defconfig 3a4 > CONFIG_FHANDLE=y Clean that up by committing the output of savedefconfig. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/configs/defconfig | 1 - 1 file changed, 1 deletion(-) commit 585a60f24bf86671b17ca7420e82b9404ff18502 Author: Stefan Agner <stefan@agner.ch> Date: Fri Jan 29 14:49:24 2016 -0800 clk: imx: return correct frequency for Ethernet PLL The i.MX 7 designs Ethernet PLL provides a 1000MHz reference clock. Store the reference clock in the clk_pllv3 structure according to the PLL type. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-pllv3.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 3238ec7c0a821915f38095752de97a424fd1d6ce Merge: 9f33a8a 23f1e2e Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Apr 27 11:49:19 2016 +1000 Merge tag 'renesas-rcar-sysc2-for-v4.7' into arm64-dt-pm-domain-for-v4.7 Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.7 Introduce a DT-based driver for the R-Car System Controller, as found on Renesas R-Car H1, R-Car Gen2, and R-Car Gen3 SoCs. commit 9f33a8a9e1b7dbb0b91a58af958d1c301a6fab1a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:30 2016 +0200 arm64: dts: r8a7795: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Reported-by: Jürg Billeter <j@bitron.ch> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 1 + arch/arm64/boot/dts/renesas/r8a7795.dtsi | 5 +---- 2 files changed, 2 insertions(+), 4 deletions(-) commit de5a79f125dd8c260d8c39b2bdced2a8fa957518 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Mar 30 16:58:22 2016 +0200 arm64: dts: salvator-x: populate EXTALR It can be used for the watchdog. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 4 ++++ 1 file changed, 4 insertions(+) commit bbd273047b765b431411103c2f7a2688b7288c85 Author: Phil Edworthy <Phil.Edworthy@renesas.com> Date: Tue Apr 5 11:51:27 2016 +0100 arm64: dts: r8a7795: enable PCIe on Salvator-X Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 9251024a6a148abd628785d53e3b7a42e8217cc9 Author: Phil Edworthy <Phil.Edworthy@renesas.com> Date: Tue Apr 5 11:51:26 2016 +0100 arm64: dts: r8a7795: Add PCIe nodes Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 57 ++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit c9006ac628ca30dd0d06dad47677d338e243bb95 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:35 2016 +0200 ARM: dts: r8a7794: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7794.dtsi | 2 -- 1 file changed, 2 deletions(-) commit 15bb4bfa3a788be349ab8f8cd1e356b7925be5eb Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:34 2016 +0200 ARM: dts: r8a7793: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793.dtsi | 2 -- 1 file changed, 2 deletions(-) commit 03adc1811cefae9494deb2002c7ab44f31d782d7 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:33 2016 +0200 ARM: dts: r8a7790: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 55ee434728ebf0a0087bbe749d6be7d7170a514c Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:32 2016 +0200 ARM: dts: r8a7779: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7779.dtsi | 1 - 1 file changed, 1 deletion(-) commit 7d698272f10cadcdb73f744b8642d70db1ca8fe8 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Apr 25 16:08:31 2016 +0200 ARM: dts: r8a7778: Don't disable referenced optional clocks clk_get() on a disabled clock node will return -EPROBE_DEFER, which can cause drivers to be deferred forever if such clocks are referenced in their devices' clocks properties. Update the various disabled external clock nodes to default to a frequency of 0, but don't disable them, to prevent this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7778.dtsi | 1 - 1 file changed, 1 deletion(-) commit 03ef285fd75f0a47461048832367ea71ec1bc65b Merge: 6f92cb2 23f1e2e Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Apr 27 11:35:26 2016 +1000 Merge tag 'renesas-rcar-sysc2-for-v4.7' into dt-pm-domain-for-v4.7 Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.7 Introduce a DT-based driver for the R-Car System Controller, as found on Renesas R-Car H1, R-Car Gen2, and R-Car Gen3 SoCs. commit dad56ee742a3abbb5d9e8108f8537d412bff3f57 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Tue Apr 26 21:22:22 2016 -0400 tracing: Move event_trigger_unlock_commit{_regs}() to local header The functions event_trigger_unlock_commit() and event_trigger_unlock_commit_regs() are no longer used outside the tracing system. Move them out of the generic headers and into the local one. Along with __event_trigger_test_discard() that is only used by them. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 94 -------------------------------------------- kernel/trace/trace.h | 94 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 94 insertions(+), 94 deletions(-) commit ae55b9ec7ac117c05ff866500425fe8b4accfebe Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 03:07:39 2016 +0200 btrfs: make find_workspace warn if there are no workspaces Be verbose if there are no workspaces at all, ie. the module init time preallocation failed. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 3b501d18aa4f75fe23af5b0bf592d62fd82cca5b Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:41:17 2016 +0200 btrfs: make find_workspace always succeed With just one preallocated workspace we can guarantee forward progress even if there's no memory available for new workspaces. The cost is more waiting but we also get rid of several error paths. On average, there will be several idle workspaces, so the waiting penalty won't be so bad. In the worst case, all cpus will compete for one workspace until there's some memory. Attempts to allocate a new one are done each time the waiters are woken up. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit 3853368b95f27d9bdaf9e15bc1e11753f11e3c43 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:55:15 2016 +0200 btrfs: preallocate compression workspaces Preallocate one workspace for each compression type so we can guarantee forward progress in the worst case. A failure cannot be a hard error as we might not use compression at all on the filesystem. If we can't allocate the workspaces later when need them, it might actually deadlock, but in such situation the system has effectively not enough memory to operate properly. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit b7bde4178a61a6855e1afebb60db4358dbbb6830 Author: David Sterba <dsterba@suse.com> Date: Wed Apr 27 02:15:15 2016 +0200 btrfs: rename and document compression workspace members The names are confusing, pick more fitting names and add comments. Signed-off-by: David Sterba <dsterba@suse.com> fs/btrfs/compression.c | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) commit 152ef5fa9e14e93e7efc43adad7dbcf35d7780f5 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri Apr 22 22:10:30 2016 +0200 drm: Switch blobs to the new generic modeset obj refcounting Need to move the free function around a bit, but otherwise mostly just removing code. Specifically we can nuke all the _locked variants since the weak idr reference is now protected by the idr_mutex, which we never hold anywhere expect in the lookup/reg/unreg functions. And those never call anything else. Another benefit of this is that this patch switches the weak reference logic from kref_put_mutex to kref_get_unless_zero. And the later is in general more flexible wrt accomodating multiple weak references protected by different locks, which might or might not come handy eventually. But one consequence of that switch is that we need to acquire the blob_lock from the free function for the list_del calls. That's a bit tricky to pull off, but works well if we pick the exact same scheme as is already used for framebuffers. Most important changes: - filp list is maintainer by create/destroy_blob ioctls directly (already the case, so we can just remove the redundant list_del from the free function). - filp close handler walks the filp-private list lockless - works because we know no one else can access it. I copied the same comment from the fb code over to explain this. - Otherwise we need to sufficiently restrict blob_lock critical sections to avoid all the unreference calls. Easy to do once the blob_lock only protects the list, and no longer the weak reference. Cc: Dave Airlie <airlied@gmail.com> Cc: Daniel Stone <daniels@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 164 +++++++++++++-------------------------------- include/drm/drm_crtc.h | 1 - 2 files changed, 45 insertions(+), 120 deletions(-) commit b0b5511bdff86244da09665f4eb4968842199322 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri Apr 22 22:10:29 2016 +0200 drm/atomic-helpers: Don't duplicate code in destroy helpers Random drive-by refactoring I spotted. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_atomic_helper.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 1649c33ba34299f66d4f5b5a86964897a2923851 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri Apr 22 22:10:28 2016 +0200 drm: Fix fb leaks and WARN spew in get/set_prop ioctls Dave Airlie had at least the refcount leak fixed in a later patch (but that patch does other things which need a bit more work). But we still have the trouble that silly userspace could hit the WARN_ON in drm_mode_object_find. Fix this all up to make sure we don't leak objects, and don't spew into demsg. Fixes: d0f37cf62979 ("drm/mode: move framebuffer reference into object.") Testcase: igt/kms_addfb_basic/invalid-*-prop* Cc: Dave Airlie <airlied@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 05981422ea178c908e451a97ac71dad886c27691 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Fri Apr 22 22:10:27 2016 +0200 drm: Improve kerneldoc for new mode object refcounting Slipped through the cracks in my review. The one issue I spotted is that drm_mode_object_find now acquires references and can be used on FB objects, which caused follow-on bugs in get/set_prop ioctls. Follow-up patches will fix that. [airlied: fixup some incr fb/decr object mixups] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit 7132e2d669bd42c3783327f301aaac5f4463299b Author: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> Date: Mon Apr 25 18:56:14 2016 -0300 ftrace: Match dot symbols when searching functions on ppc64 In the ppc64 big endian ABI, function symbols point to function descriptors. The symbols which point to the function entry points have a dot in front of the function name. Consequently, when the ftrace filter mechanism searches for the symbol corresponding to an entry point address, it gets the dot symbol. As a result, ftrace filter users have to be aware of this ABI detail on ppc64 and prepend a dot to the function name when setting the filter. The perf probe command insulates the user from this by ignoring the dot in front of the symbol name when matching function names to symbols, but the sysfs interface does not. This patch makes the ftrace filter mechanism do the same when searching symbols. Fixes the following failure in ftracetest's kprobe_ftrace.tc: .../kprobe_ftrace.tc: line 9: echo: write error: Invalid argument That failure is on this line of kprobe_ftrace.tc: echo _do_fork > set_ftrace_filter This is because there's no _do_fork entry in the functions list: # cat available_filter_functions | grep _do_fork ._do_fork This change introduces no regressions on the perf and ftracetest testsuite results. Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/ftrace.c | 10 ++++++++++ kernel/trace/ftrace.c | 12 ++++++++++++ 2 files changed, 22 insertions(+) commit 944a3f323ba087ddd096cf3d1ac74759cfa22358 Merge: 33f0fca b8c1eca Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 09:38:42 2016 +1000 Merge branch 'topic-arcpgu-v6' of https://github.com/foss-for-synopsys-dwc-arc-processors/linux into drm-next This is DRM driver for ARC PGU - simple bitstreamer used on Synopsys ARC SDP boards (both AXS101 and AXS103). * 'topic-arcpgu-v6' of https://github.com/foss-for-synopsys-dwc-arc-processors/linux: arc: axs10x - add support of ARC PGU MAINTAINERS: Add maintainer for ARC PGU display controller drm: Add DT bindings documentation for ARC PGU display controller drm: Add support of ARC PGU display controller commit 33f0fca6b4277eafe4d5dec2e5806c9a91074909 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 21 21:17:32 2016 +0100 drm/sis: add missing include drm.h for the UAPI header Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com> include/uapi/drm/sis_drm.h | 2 ++ 1 file changed, 2 insertions(+) commit f7a3e1dc8f2d800c0c796d0704cd6570e583e8e0 Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Thu Apr 21 21:17:27 2016 +0100 drm/qxl: remove XXX comment from the UAPI header One cannot rename the struct at this point, so might as well remove the comment. Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com> include/uapi/drm/qxl_drm.h | 1 - 1 file changed, 1 deletion(-) commit 8fe088850f13eabf8197df5b0bf38668fa6c1294 Author: Daniel Axtens <dja@axtens.net> Date: Tue Apr 26 23:49:09 2016 +1000 powerpc: rework sparse for lib/xor_vmx.c Sparse doesn't seem to be passing -maltivec around properly, leading to lots of errors: .../include/altivec.h:34:2: error: Use the "-maltivec" flag to enable PowerPC AltiVec support arch/powerpc/lib/xor_vmx.c:27:16: error: Expected ; at end of declaration arch/powerpc/lib/xor_vmx.c:27:16: error: got signed arch/powerpc/lib/xor_vmx.c:60:9: error: No right hand side of '*'-expression arch/powerpc/lib/xor_vmx.c:60:9: error: Expected ; at end of statement arch/powerpc/lib/xor_vmx.c:60:9: error: got v1_in ... arch/powerpc/lib/xor_vmx.c:87:9: error: too many errors Only include the altivec.h header for non-__CHECKER__ builds. For builds with __CHECKER__, make up some stubs instead, as suggested by Balbir. (The vector size of 16 is arbitrary.) Suggested-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Daniel Axtens <dja@axtens.net> Tested-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/lib/xor_vmx.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 8a649045e75a4b9091ea9d041f5bb599f8ec1f8a Author: Chris Smart <chris@distroguy.com> Date: Tue Apr 26 10:28:50 2016 +1000 powerpc: Add support for userspace P9 copy paste The copy paste facility introduced in POWER9 provides an optimised mechanism for a userspace application to copy a cacheline. This is provided by a pair of instructions, copy and paste, while a third, cp_abort (copy paste abort), provides a clean up of the state in case of a failure. The copy instruction will read a 128 byte cacheline and store it in an internal buffer. The subsequent paste instruction will store this internal buffer to memory and set a CR field if the paste succeeds. Since the state of the copy paste buffer is internal (and not architecturally visible), in the unlikely event of a context switch, the state cannot be stored and the paste should therefore fail. The cp_abort instruction exists to fail and clean up any such interrupted copy paste sequence and is to be called by the kernel as part of the context switch. Doing so prevents data from a preceding copy in one process leaking into the paste of another. This code enables use of the cp_abort instruction if a supported processor is detected. NOTE: this is for userspace only, not in kernel, and does not deal with KVM guests. Patch created with much assistance from Michael Neuling <mikey@neuling.org> Signed-off-by: Chris Smart <chris@distroguy.com> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/ppc-opcode.h | 2 ++ arch/powerpc/kernel/entry_64.S | 9 +++++++++ 2 files changed, 11 insertions(+) commit 4ad5e8831e1cb663f17112e44406b5ca9649ba1f Author: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Date: Tue Apr 26 17:55:04 2016 +1000 powerpc/mpic: handle subsys_system_register() failure mpic_init_sys() currently doesn't check whether subsys_system_register() succeeded or not. Check the return code of subsys_system_register() and clean up if there's an error. Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/sysdev/mpic.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 69056e9a43765f5ef7cbf3b9d3ffd4e597271956 Merge: 027b3f8b 077d673 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 27 09:19:50 2016 +1000 Merge branch 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev into drm-next misc rcar changes. * 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev: drm: rcar-du: Fix compilation warning drm: rcar-du: Use ARCH_RENESAS drm: rcar-du: Clarify vsp dependency commit 2d5217840ff1d0cf0f88201a922ab35bd083f7fb Author: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Date: Tue Apr 26 15:02:50 2016 +1000 powerpc/eeh: fix misleading indentation Found by smatch. Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Acked-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh_pe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 328fafb94fa136bfa19b4ebc54d1f8cfcad13801 Author: Colin Ian King <colin.king@canonical.com> Date: Sat Mar 26 21:03:53 2016 +0000 usb: hcd: do not call whc_clean_up on wch_init call failure whc_init already calls whc_clean_up if an error occurs during the initialization, so calling it again if whc_init fails at the end of wch_probe will cause double free errors. Fix this by bailing out on an whc_init failure to a new label that avoids doing the duplicated whc_clean_up. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/whci/hcd.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 1507372b97a098fd51b92c4dbdbbcd65cba26939 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 12:37:11 2016 +0100 USB: bcma: use simpler devm helper for getting vcc GPIO Thanks to switching to devm_gpiod_get: 1) We don't have to pass fwnode pointer 2) We can request initial GPIO value at getting call This was successfully tested on Netgear R6250 (BCM4708). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/bcma-hcd.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit c06fac7fa0a09a791b01f2cd963cbacdc878d69f Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:17 2016 +0300 usb: host: xhci: plat: finally get rid of xhci_plat_type_is() Now that there are no more users for xhci_plat_type_is(), we can safely remove it. Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-plat.c | 3 --- drivers/usb/host/xhci-plat.h | 18 ------------------ 2 files changed, 21 deletions(-) commit b1c127ae990bccf0187d741c1695a61e54de1943 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:16 2016 +0300 usb: host: xhci: plat: make use of new methods in xhci_plat_priv Now that the code has been refactored enough, switching over to using ->plat_start() and ->init_quirk() becomes a very simple patch. After this patch, there are no further uses for xhci_plat_type_is() which will be removed in a follow-up patch. Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-plat.c | 55 ++++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 28 deletions(-) commit 72d4b2847d3d31fcc3910e18b72d026987626c8d Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:15 2016 +0300 usb: host: xhci: plat: change type of mvebu init_quirk() Just like RCAR's init_quirk() we want mvebu's to use struct usb_hcd * as argument too. This is another step towards removing xhci_plat_type_is(). Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-mvebu.c | 7 ++++++- drivers/usb/host/xhci-mvebu.h | 7 +++++-- drivers/usb/host/xhci-plat.c | 5 +---- 3 files changed, 12 insertions(+), 7 deletions(-) commit 3bdb263d6b3c2384d98745897ba9db676806ed04 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:14 2016 +0300 usb: host: xhci: plat: move mvebu init_quirk() to xhci_plat_setup() xhci_plat_setup() is the rightful place for xhci_mvebu_mbus_init_quirk(), so let's move it there in order to make it simpler to get rid of xhci_plat_type_is() later on. Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-plat.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 7eca937ec8b9a2e9c495ea9232ffe2b71d036bb1 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:13 2016 +0300 usb: xhci: plat: add ->plat_start() and ->init_quirk() methods these two methods will be used to hide platform-specific details so we can get rid of xhci_plat_type_is() in a later patch. Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-plat.h | 2 ++ 1 file changed, 2 insertions(+) commit 2dc240a3308b269ac344036e2f41fc48532c2f04 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Fri Apr 22 13:17:12 2016 +0300 usb: host: xhci: rcar: retire use of xhci_plat_type_is() We're preparing to remove xhci_plat_type_is() in favor of a better approach where we define function pointers ahead of time. This will let us make assumptions about which platforms we're running on and which platform-specific functions we should call. Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> [delete extra comma in function parameters -Mathias] Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-rcar.c | 34 +++++++++++++++++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) commit 78140156f47ed8a9b07fd6a5766d03d3d837aaca Author: Alexandr Ivanov <alexandr.sky@gmail.com> Date: Fri Apr 22 13:17:11 2016 +0300 usb: xhci: remove duplicate code of interval checking Move duplicate code from xhci_queue_intr_tx() and xhci_queue_isoc_tx_prepare() to the check_interval() function. Signed-off-by: Alexandr Ivanov <alexandr.sky@gmail.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 53 ++++++++++++++++++-------------------------- 1 file changed, 21 insertions(+), 32 deletions(-) commit 75b040ec60a8bf0ef7f69fcfc8dd81c8f75eabc7 Author: Alexandr Ivanov <alexandr.sky@gmail.com> Date: Fri Apr 22 13:17:10 2016 +0300 usb: xhci: remove duplicate function xhci_urb_to_transfer_ring Remove duplicate function xhci_urb_to_transfer_ring from xhci.c. We have same function in xhci-ring.c. Signed-off-by: Alexandr Ivanov <alexandr.sky@gmail.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 17 +++++------------ drivers/usb/host/xhci.c | 41 ----------------------------------------- drivers/usb/host/xhci.h | 11 +++++++++++ 3 files changed, 16 insertions(+), 53 deletions(-) commit d2510342fe93d5ac8b807bc1d44b613eb5d9c64d Author: Alexandr Ivanov <alexandr.sky@gmail.com> Date: Fri Apr 22 13:17:09 2016 +0300 usb: xhci: merge xhci_queue_bulk_tx and queue_bulk_sg_tx functions In drivers/usb/host/xhci-ring.c there are two functions (xhci_queue_bulk_tx and queue_bulk_sg_tx) that are very similar, so a lot of code duplication. This patch merges these functions into to one xhci_queue_bulk_tx. Also counting the needed TRBs is merged and refactored. Signed-off-by: Alexandr Ivanov <alexandr.sky@gmail.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 406 +++++++++++++------------------------------ drivers/usb/host/xhci.h | 3 + 2 files changed, 121 insertions(+), 288 deletions(-) commit 5bcba792bb304e8341217d759ec486969a3b4258 Author: Benjamin Poirier <bpoirier@suse.com> Date: Tue Apr 26 11:56:38 2016 -0700 localmodconfig: Fix whitespace repeat count after "tristate" Also recognize standalone "prompt". Before this patch we incorrectly identified some symbols as not having a prompt and potentially needing to be selected by something else. Note that this patch could theoretically change the resulting .config, causing it to have fewer symbols turned on. However, given the current set of Kconfig files, this situation does not occur because the symbols newly added to %prompts are absent from %selects. Link: http://lkml.kernel.org/r/1461696998-3953-1-git-send-email-bpoirier@suse.com Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5f2e5fb873e269fcb806165715d237f0de4ecf1d Author: David Mosberger <davidm@egauge.net> Date: Tue Mar 8 14:42:49 2016 -0700 drivers: usb: core: Minimize irq disabling in usb_sg_cancel() Restructure usb_sg_cancel() so we don't have to disable interrupts while cancelling the URBs. Suggested-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: David Mosberger <davidm@egauge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/message.c | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) commit 98b74b0ee57af1bcb6e8b2e76e707a71c5ef8ec9 Author: David Mosberger <davidm@egauge.net> Date: Tue Mar 8 14:42:48 2016 -0700 drivers: usb: core: Don't disable irqs in usb_sg_wait() during URB submit. usb_submit_urb() may take quite long to execute. For example, a single sg list may have 30 or more entries, possibly leading to that many calls to DMA-map pages. This can cause interrupt latency of several hundred micro-seconds. Avoid the problem by releasing the io->lock spinlock and re-enabling interrupts before calling usb_submit_urb(). This opens races with usb_sg_cancel() and sg_complete(). Handle those races by using usb_block_urb() to stop URBs from being submitted after usb_sg_cancel() or sg_complete() with error. Note that usb_unlink_urb() is guaranteed to return -ENODEV if !io->urbs[i]->dev and since the -ENODEV case is already handled, we don't have to check for !io->urbs[i]->dev explicitly. Before this change, reading 512MB from an ext3 filesystem on a USB memory stick showed a throughput of 12 MB/s with about 500 missed deadlines. With this change, reading the same file gave the same throughput but only one or two missed deadlines. Signed-off-by: David Mosberger <davidm@egauge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/message.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit 9360575c5837cfee841ad350de5be830b840d972 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:07 2016 +0100 usbip: vudc: Add vudc to Kconfig Add the driver to Kconfig to make it visible in menuconfig and allow people to compile it. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/Kconfig | 11 +++++++++++ drivers/usb/usbip/Makefile | 3 +++ 2 files changed, 14 insertions(+) commit e0546fd8b748b19d8edd1550530da8ebad6e4b31 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:06 2016 +0100 usbip: tools: Start using VUDC backend in usbip tools Modify userspace tools to allow exporting and connecting to vudc. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Ewelina Kosmider <3w3lfin@gmail.com> [Various bug fixes and improvements] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> tools/usb/usbip/src/usbip_attach.c | 10 +++- tools/usb/usbip/src/usbip_list.c | 96 ++++++++++++++++++++++++++++++++++++-- tools/usb/usbip/src/usbipd.c | 12 ++++- 3 files changed, 112 insertions(+), 6 deletions(-) commit 7b3f74f7e0601b2767aee7e188b1e3a912c082a2 Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Tue Mar 8 21:49:05 2016 +0100 usbip: tools: Add vudc backend to usbip tools Adds an equivalent of usbip_host_driver for the vudc. Most of the code is already shared, but this adds some vudc specific code for getting information about devices. Based on code created in cooperation with Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> tools/usb/usbip/libsrc/Makefile.am | 1 + tools/usb/usbip/libsrc/usbip_common.h | 3 + tools/usb/usbip/libsrc/usbip_device_driver.c | 163 +++++++++++++++++++++++++++ tools/usb/usbip/libsrc/usbip_device_driver.h | 34 ++++++ 4 files changed, 201 insertions(+) commit 3391ba0e2792411dc3372b76a4662971d6eaa405 Author: Krzysztof Opasiak <k.opasiak@samsung.com> Date: Tue Mar 8 21:49:04 2016 +0100 usbip: tools: Extract generic code to be shared with vudc backend Extract the code from current stub driver backend and a common interface for both stub driver and vudc. This allows to share most of the usbipd code for both of them. Based on code created in cooperation with Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> tools/usb/usbip/libsrc/Makefile.am | 3 +- tools/usb/usbip/libsrc/usbip_host_common.c | 273 +++++++++++++++++++++++++++++ tools/usb/usbip/libsrc/usbip_host_common.h | 104 +++++++++++ tools/usb/usbip/libsrc/usbip_host_driver.c | 269 +++------------------------- tools/usb/usbip/libsrc/usbip_host_driver.h | 27 +-- tools/usb/usbip/src/usbipd.c | 30 ++-- 6 files changed, 428 insertions(+), 278 deletions(-) commit ea6873a45a22f35c8ab0f9c025df6a6c6dd532f3 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:03 2016 +0100 usbip: vudc: Add SysFS infrastructure for VUDC Add sysfs attributes to allow controlling vudc from usbip tools. dev_desc - device descriptor of current gadget. This is required to be consisten with current usbip protocol and allow to list exportable devices on given machine. usbip_sockfd - allows to pass socket to kernel to start usbip transfer. usbip_status - currnent status of device This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> [Various bug fixes, improvements and commit msg update] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_sysfs.c | 221 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 221 insertions(+) commit b6a0ca11186759ad7045d68a5447b1e89f658384 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:02 2016 +0100 usbip: vudc: Add UDC specific ops Add endpoints definitions and ops for both endpoints and gadget. Add also a suitable platform driver and functions for handling usbip events. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> [Various bug fixes, improvements and commit msg update] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_dev.c | 662 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 662 insertions(+) commit d62ba981a9de7e2999b850fb8ff274da2a9387c5 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:01 2016 +0100 usbip: vudc: Add vudc_tx This file contains functions for returning requests to the client. It also has functions that add requests completed in vudc_rx and vudc_transfer to the return queue. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_tx.c | 289 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 289 insertions(+) commit abdb2957432242de09ad52d044b5221a4b56c15a Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:49:00 2016 +0100 usbip: vudc: Add vudc_transfer This file contains a function that simulates USB traffic, based on the one in dummy_hcd. Is also handles udc-directed control requests, and contains functions for setting up and controlling a timer for the emulation. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_transfer.c | 506 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 506 insertions(+) commit 79c02cb1fd5c1fc8af16d18294804acc5dbfdee2 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:48:59 2016 +0100 usbip: vudc: Add vudc_rx Add functions which allows to receive urbs from the client. It receives traffic in a loop in a separate thread. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_rx.c | 234 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 234 insertions(+) commit 80fd9cd52de6a5fb263b3bdcb8bd8982dc50a070 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:48:58 2016 +0100 usbip: vudc: Add VUDC main file Add main vudc module file. This allows us to register suitable platform device and driver (just like dummy_hcd does). Currently number of vudc instances is determined using module parameter but whole infrastructure is suitable to make vudc creation dynamic (for example via configfs). This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> [Various bug fixes and commit message update] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc_main.c | 113 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 113 insertions(+) commit c7af4c221878ad684f0412eba2a1f18fa126c6d5 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:48:57 2016 +0100 usbip: vudc: Make usbip_common vudc-aware Add constants for VUDC events in usbip_common.h and make use of them in usbip_common.c. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> [Small fixes and commit message update] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/usbip_common.c | 10 ++++++---- drivers/usb/usbip/usbip_common.h | 10 ++++++++++ 2 files changed, 16 insertions(+), 4 deletions(-) commit 602364fdaaa6e7d78eac18332d3aca554190fdf4 Author: Igor Kotrasinski <i.kotrasinsk@samsung.com> Date: Tue Mar 8 21:48:56 2016 +0100 usbip: vudc: Add header for USB/IP UDC Add header with definitions needed by vudc driver. This commit is a result of cooperation between Samsung R&D Institute Poland and Open Operating Systems Student Society at University of Warsaw (O2S3@UW) consisting of: Igor Kotrasinski <ikotrasinsk@gmail.com> Karol Kosik <karo9@interia.eu> Ewelina Kosmider <3w3lfin@gmail.com> Dawid Lazarczyk <lazarczyk.dawid@gmail.com> Piotr Szulc <ps347277@students.mimuw.edu.pl> Tutor and project owner: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Igor Kotrasinski <i.kotrasinsk@samsung.com> Signed-off-by: Karol Kosik <karo9@interia.eu> [Some small improvements] Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/vudc.h | 190 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 190 insertions(+) commit 610cc3a49fdc563395bc3e65fa4a6aa8f97651eb Author: Iban Rodriguez <iban.rodriguez@ono.com> Date: Tue Apr 12 23:08:34 2016 +0200 Staging: lustre: Make lustre_profile_list static Variable lustre_profile_list is only used inside obd_config.c, better make it static Signed-off-by: Iban Rodriguez <iban.rodriguez@ono.com> Acked-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/obd_config.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit abe958236ff9f1a68becf4e1d27a6ceb8e10e2b7 Author: John L. Hammond <john.hammond@intel.com> Date: Tue Apr 12 16:14:16 2016 -0400 staging: lustre: hsm: don't use real suppgid In the MDC HSM handlers that do not pack a real suppgid, use -1 rather than 0 for the suppgid in mdt_body. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3866 Reviewed-on: http://review.whamcloud.com/7565 Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr> Reviewed-by: Faccini Bruno <bruno.faccini@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/mdc/mdc_request.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 1cc28b77798d48e31e5dc16cea4274eb52972fd4 Author: John L. Hammond <john.hammond@intel.com> Date: Tue Apr 12 16:14:15 2016 -0400 staging: lustre: hsm: permission checks for HSM ioctl operations In the LL_IOC_HSM_CT_START case of ll_dir_ioctl() require CAP_SYS_ADMIN, since the local handler for this ioctl may modify the global KUC table. Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3866 Reviewed-on: http://review.whamcloud.com/7565 Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr> Reviewed-by: Faccini Bruno <bruno.faccini@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 3 +++ 1 file changed, 3 insertions(+) commit 554f0724af5bab4b263ff3c2f0324db79e868aae Author: Andriy Skulysh <Andriy_Skulysh@xyratex.com> Date: Tue Apr 12 16:14:14 2016 -0400 staging: lustre: lov: Don't wait for active target with OBD_STATFS_NODELAY Patch for LU-631 which was landed before the upstream merge broke OBD_STATFS_NODELAY behaviour. It adds unnecessary delay while running df command with inactive OSTs. We shouldn't try to recover connection to OST in this case. Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4010 Reviewed-on: http://review.whamcloud.com/7762 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lov/lov_request.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit ad1daf47c98f524ed6a517486a10e4114b450ff8 Author: Bruno Faccini <bruno.faccini@intel.com> Date: Tue Apr 12 16:14:13 2016 -0400 staging: lustre: lov: return minimal FIEMAP for released files Since st_blocks = NULL is returned for released files, FIEMAP should at least return a minimal mapping to make users aware that file contains data but it is not immediately available. This will make coreutils and tools such tar happy and have them presume file is sparse. Also, add a new test_228 in sanity-hsm to verify it works for "[cp,tar] --sparse" commands. Also fix a LBUG ("lov_fiemap()) ASSERTION( fm_local ) failed") likely to occur when no-object/ENOMEM conditions and also now when released. Signed-off-by: Bruno Faccini <bruno.faccini@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3864 Reviewed-on: http://review.whamcloud.com/7584 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lov/lov_obd.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit b3ffe666ca1a747ce399d7d0966a132235e40e66 Author: Andrew Perepechko <andrew_perepechko@xyratex.com> Date: Tue Apr 12 16:14:12 2016 -0400 staging: lustre: lprocfs: implement log2 using bitops This patch implements log2 using fls. Signed-off-by: Andrew Perepechko <andrew_perepechko@xyratex.com> Reviewed-by: Alexander Boyko <Alexander_Boyko@xyratex.com> Reviewed-by: alexander_zarochentsev@xyratex.com Reviewed-by: Vitaly Fertman <Vitaly_Fertman@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3496 Xyratex-bug-id: MRP-999 Reviewed-on: http://review.whamcloud.com/6757 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/lprocfs_status.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b59d812d0021b4f76adb05452a382898a6e225dc Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Tue Apr 12 16:14:11 2016 -0400 staging: lustre: osc: osc_extent_wait() shouldn't be interruptible Otherwise it will hit the assertion at cl_lock.c: cl_lock.c:1967:discard_cb()) ASSERTION( (!(page->cp_type == CPT_CACHEABLE) || (!PageWriteback(cl_page_vmpage(env, page)))) ) failed: This is because in osc_lock_flush() we have to make sure the IO is finished before discarding the pages. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2779 Reviewed-on: http://review.whamcloud.com/5419 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/osc/osc_cache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1b1594da71c4286ce52009073ef0d7b6edc80ec5 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Tue Apr 12 16:14:10 2016 -0400 staging: lustre: llite: Truncate to restore file Truncate up is safe so it won't trigger restore. Copy optimization for truncate down - only copy the part under truncate length. If a file is truncated to zero usually it'll be followed by write so I choose to restore the file and set correct stripe information. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3817 Reviewed-on: http://review.whamcloud.com/7505 Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr> Reviewed-by: Henri Doreau <henri.doreau@cea.fr> Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 5 +- .../staging/lustre/lustre/llite/llite_internal.h | 2 +- drivers/staging/lustre/lustre/llite/llite_lib.c | 60 ++++++++++------------ drivers/staging/lustre/lustre/llite/vvp_io.c | 5 +- 4 files changed, 35 insertions(+), 37 deletions(-) commit cc3b77589617b32c4fe610d9d6302a159f1fde13 Author: Swapnil Pimpale <spimpale@ddn.com> Date: Tue Apr 12 16:14:09 2016 -0400 staging: lustre: ptlrpc: return a meaningful status from ptlrpcd_init() This patch has the following: 1) Fix for the return value from ptlrpcd_init(). It will now return a correct status instead of returning zero always. 2) ptlrpcd_addref() should not increment ptlrpcd_users on error. 3) Added code in a mdc_setup() and mgc_setup() to test the return value of ptlrpcd_addref() and return on error. Signed-off-by: Swapnil Pimpale <spimpale@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3808 Reviewed-on: http://review.whamcloud.com/7522 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/mdc/mdc_request.c | 9 ++++++--- drivers/staging/lustre/lustre/mgc/mgc_request.c | 5 ++++- drivers/staging/lustre/lustre/ptlrpc/ptlrpcd.c | 5 ++++- 3 files changed, 14 insertions(+), 5 deletions(-) commit 489d82fcd8f39ad43a65d72abe9bf835a5af3f63 Author: Bobi Jam <bobijam.xu@intel.com> Date: Tue Apr 12 16:14:08 2016 -0400 staging: lustre: obd: MDT mount fails on MDS w/o MGS on it If we specify multiple --mgsnode for a MDT, when we start MDS upon it while MGS is no the other node, the MGC import connection will always select the local nid (which is one of the candidate mgsnode) since it think its the closest connection. This patch treats further --mgsnode nids as failover nids, so that multiple import connections are added for the MGC import. Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3829 Reviewed-on: http://review.whamcloud.com/7509 Reviewed-by: Liang Zhen <liang.zhen@intel.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/obd_mount.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 32cc01c42fc0fefaed58d22b4b1657f56e11f0fb Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Tue Apr 12 16:14:07 2016 -0400 staging: lustre: llite: error setting max_cache_mb at mount time The root cause is that when max_cache_mb conf parameter is applied, the client isn't connected to the OST yet so that sbi->ll_dt_exp is NULL. However, it's not necessary to shrink the cache memory in this case so success should be returned. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3676 Reviewed-on: http://review.whamcloud.com/7194 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Bobi Jam <bobijam@gmail.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/lproc_llite.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3c4b9d09729cb04070edb167c813884507f4e433 Author: Andrew Perepechko <andrew_perepechko@xyratex.com> Date: Tue Apr 12 16:14:06 2016 -0400 staging: lustre: llite: speedup in unlink/rmdir Assume dchild argument is fully initialized in ->unlink and ->rmdir callbacks, so additional lookup for ELC is not needed. Signed-off-by: Andrew Perepechko <andrew_perepechko@xyratex.com> Reviewed-by: Alexander Boyko <Alexander_Boyko@xyratex.com> Reviewed-by: Vitaly Fertman <Vitaly_Fertman@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3473 Xyratex-bug-id: MRP-1027 Reviewed-on: http://review.whamcloud.com/6648 Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/namei.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit 96d61c247ec02518ba2ff453f71ee15feb522456 Author: Andrew Perepechko <andrew_perepechko@xyratex.com> Date: Tue Apr 12 16:14:05 2016 -0400 staging: lustre: llite: variable rename in namei.c With the patch 6648 a fee variables were renamed. We do these renames in broken out patch to the fix obvious. Signed-off-by: Andrew Perepechko <andrew_perepechko@xyratex.com> Reviewed-by: Alexander Boyko <Alexander_Boyko@xyratex.com> Reviewed-by: Vitaly Fertman <Vitaly_Fertman@xyratex.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3473 Xyratex-bug-id: MRP-1027 Reviewed-on: http://review.whamcloud.com/6648 Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/namei.c | 52 ++++++++++++++--------------- 1 file changed, 26 insertions(+), 26 deletions(-) commit e9ada6fa3c9e3dbd02eda3da4179b4d1417ef171 Author: Bruno Faccini <bruno.faccini@intel.com> Date: Tue Apr 12 16:14:04 2016 -0400 staging: lustre: ldlm: refine LU-2665 patch for POSIX compliance Follow-on to patch introduced to fix LU-2665 ticket (Gerrit Change at http://review.whamcloud.com/6415 with Change-Id: I8faa331712abeadee46eabe111ee1c23a05840d5). Original patch introduced regressions against POSIX test suite (fcntl.18/fcntl.35 tests in LSB-VSX POSIX test suite at http://www.opengroup.org/testing/linux-test/lsb-vsx.html), so the idea is to only resend F_UNLCKs to have both LU-2665 bug and POSIX test suite happy. Signed-off-by: Bruno Faccini <bruno.faccini@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3701 Reviewed-on: http://review.whamcloud.com/7453 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/mdc/mdc_locks.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 7e74e54f08294a81b82b686e86b9d784ad65a5f9 Author: Bruno Faccini <bruno.faccini@intel.com> Date: Tue Apr 12 16:14:03 2016 -0400 staging: lustre: ldlm: Fix a race during FLock handling Protect against race where lock could have been just destroyed due to overlap, in ldlm_process_flock_lock(). Easy reproducer is BULL's NFS Locktests in pthread mode. (http://nfsv4.bullopensource.org/tools/tests/locktest.php) Signed-off-by: Bruno Faccini <bruno.faccini@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1126 Reviewed-on: http://review.whamcloud.com/7134 Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_flock.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 800548b1b1a71bb12e74bedae7a575b155ced851 Author: Niu Yawei <yawei.niu@intel.com> Date: Tue Apr 12 16:14:02 2016 -0400 staging: lustre: clio: incorrect assertions in 'enable-invariants' Fixed several incorrect assumptions in 'enable-invariants'. Signed-off-by: Niu Yawei <yawei.niu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3521 Reviewed-on: http://review.whamcloud.com/6832 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/cl_page.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 82281bc0c31ccd3a0733c678ad0f0a19ca59246d Author: Sebastien Buisson <sbuisson@ddn.com> Date: Tue Apr 12 16:14:01 2016 -0400 staging: lustre: osc: fix race issues thanks to oap_lock Fix 'data race condition' defects found by Coverity version 6.5.0: Data race condition (MISSING_LOCK) Accessing variable without holding lock. Elsewhere, this variable is accessed with lock held. This patch is dedicated to code fragments involving oap_lock. Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2744 Reviewed-on: http://review.whamcloud.com/6572 Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/osc/osc_cache.c | 8 ++++++++ drivers/staging/lustre/lustre/osc/osc_io.c | 2 ++ 2 files changed, 10 insertions(+) commit 06d2fccd6b551be8c1efb8b37d01c511d2b3e905 Author: Bobi Jam <bobijam.xu@intel.com> Date: Tue Apr 12 21:11:09 2016 -0400 staging/lustre/llite: suppress non active IO error message Current CLIO does not support fadvise, suppress the error message. Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Reviewed-on: http://review.whamcloud.com/9658 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4717 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/rw.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 6a6514719455fd114a17c0e8c6ffff0f8c5151d6 Author: Oleg Drokin <green@linuxhacker.ru> Date: Tue Apr 12 21:11:08 2016 -0400 staging/lustre: Fix blank line after/before {/} style This patch fixes all checkpatch occurences of CHECK: Blank lines aren't necessary after an open brace '{' CHECK: Blank lines aren't necessary before a close brace '}' in Lustre code. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/fld/fld_request.c | 1 - drivers/staging/lustre/lustre/include/lu_object.h | 1 - drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 1 - drivers/staging/lustre/lustre/ldlm/ldlm_lock.c | 1 - drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 1 - drivers/staging/lustre/lustre/llite/dir.c | 2 -- drivers/staging/lustre/lustre/llite/lproc_llite.c | 1 - drivers/staging/lustre/lustre/llite/xattr.c | 1 - drivers/staging/lustre/lustre/llite/xattr_cache.c | 1 - drivers/staging/lustre/lustre/lov/lov_io.c | 1 - drivers/staging/lustre/lustre/lov/lov_obd.c | 1 - drivers/staging/lustre/lustre/lov/lov_pack.c | 1 - drivers/staging/lustre/lustre/lov/lov_request.c | 1 - drivers/staging/lustre/lustre/lov/lovsub_object.c | 1 - drivers/staging/lustre/lustre/mdc/mdc_lib.c | 1 - drivers/staging/lustre/lustre/mdc/mdc_locks.c | 1 - drivers/staging/lustre/lustre/mgc/mgc_request.c | 1 - drivers/staging/lustre/lustre/obdclass/class_obd.c | 1 - drivers/staging/lustre/lustre/obdclass/genops.c | 1 - drivers/staging/lustre/lustre/obdclass/llog.c | 1 - drivers/staging/lustre/lustre/obdclass/lu_object.c | 2 -- drivers/staging/lustre/lustre/obdclass/obd_config.c | 1 - drivers/staging/lustre/lustre/obdecho/echo_client.c | 2 -- drivers/staging/lustre/lustre/osc/osc_cache.c | 1 - drivers/staging/lustre/lustre/osc/osc_io.c | 1 - drivers/staging/lustre/lustre/osc/osc_page.c | 1 - drivers/staging/lustre/lustre/osc/osc_request.c | 1 - drivers/staging/lustre/lustre/ptlrpc/client.c | 1 - drivers/staging/lustre/lustre/ptlrpc/events.c | 1 - drivers/staging/lustre/lustre/ptlrpc/import.c | 3 --- drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c | 1 - drivers/staging/lustre/lustre/ptlrpc/nrs.c | 1 - drivers/staging/lustre/lustre/ptlrpc/pack_generic.c | 3 --- 33 files changed, 40 deletions(-) commit abcdb1e471e2adbe036123d12d625d65bb2ba8ef Author: Aleksei Fedotov <lexa@cfotr.com> Date: Tue Apr 12 14:05:49 2016 +0300 staging: lustre: libcfs: Fix libcfs_ioctl() prototype. Fix libcfs_ioctl() prototype according to its definition in libcfs/module.c. Signed-off-by: Aleksei Fedotov <lexa@cfotr.com> Acked-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 45d2f4fb5a19d4aa5d7d81796081aa6cba9e4e70 Author: James Simmons <jsimmons@infradead.org> Date: Tue Apr 12 12:16:02 2016 -0400 staging: lustre: selftest: convert wire protocol to use struct Change all the wire protocol typedefs to proper structures Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 22 ++-- drivers/staging/lustre/lnet/selftest/conrpc.c | 44 +++---- drivers/staging/lustre/lnet/selftest/console.c | 10 +- drivers/staging/lustre/lnet/selftest/framework.c | 54 ++++---- drivers/staging/lustre/lnet/selftest/ping_test.c | 10 +- drivers/staging/lustre/lnet/selftest/rpc.c | 6 +- drivers/staging/lustre/lnet/selftest/rpc.h | 150 +++++++++++------------ drivers/staging/lustre/lnet/selftest/selftest.h | 13 +- 8 files changed, 155 insertions(+), 154 deletions(-) commit ee3b6f1e6de5e93856fce5c87d53e26b078b254c Author: James Simmons <jsimmons@infradead.org> Date: Tue Apr 12 12:16:01 2016 -0400 staging: lustre: selftest: convert lstcon_test_t to proper struct Turn typedef lstcon_test_t to proper structure Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conctl.c | 2 +- drivers/staging/lustre/lnet/selftest/conrpc.c | 5 +++-- drivers/staging/lustre/lnet/selftest/console.c | 26 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/console.h | 7 ++++--- 4 files changed, 21 insertions(+), 19 deletions(-) commit 5a45e01d414636e144ab28b62089d0eb97f43ec2 Merge: 4145ba7 fbced0e Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue Apr 26 15:07:23 2016 -0700 Merge tag 'iio-for-4.7b' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-testing Jonathan writes: 2nd set of new device support, features and cleanup for IIO in the 4.7 cycle. Bit of a bumper set for new drivers but plenty of other stuff here as well! New device support * ad5592R ADC/DAC - new driver supporting ad5592r and ad5593r combined ADC/DAC and gpio chips. * Aosong am2315 relative humidity - new driver with triggered buffer support in follow up patch. * bmi160 imu - new driver * bmp280 - bmp180 support - note there is support in the misc/bmp085 driver. Intent is to remove that driver long term. * invensense mpu6050 - cleanup leading to explicit support of mpu9150 with a good few cleanups along the way. * Hope RF hp03 pressure and temperature sensor. - new driver * maxim DS1803 potentiometer - new driver * maxim max44000 light and proximity sensor - new driver built in a series of steps to support pretty much everything. * ROHM BH1780 light sensor - new driver. There is an existing driver in misc that this is pretty much intended to replace. The discussion on whether to support the non standard interface of that driver is some way is continuing. * st-gyro - lsm9ds0-gyro. The accel/magn side of this will take a while longer as extensions to the st library are needed for cases where two types of sensor share a single i2c address. * ti-adc081c - support the adc101c and adc121c * Vishay VEML6070 UV sensor - new driver. New features * core - devm_ APIs for channel_get and channel_get_all. The first user of these is the generic ADC based thermal driver. As it is going through the thermal tree these will be picked up as a patch to that next cycle as that is how the author preferred to do it. - mounting matrix support. This new core support allows devices to provide to userspace (typically from the device tree) allowing compensation for how the sensor is mounted on the device. First examples are on UAVs but it has a more mundane use on typical phone where the chip may be on the front or the back of the circuit board and soldered at any angle. Includes support for this ABI in ak8975 (which has an older interface, now deprecated) and mpu6050. * tools - add a -a option to enable all available channels in generic_buffer sample. Makes it somewhat easier to use. * adis library and drivers - support manual self test flag clearing. This has technically been broken for a very long time - result is an offset on readings as the applied field is on all the time. * ak8975 - triggered buffer support * bmc150 - spi support (including splitting the driver into core and i2c parts) * bmp280 - oversampling support. * dht11 - improved logging - useful to debug timing issues on this quirky device. * st-sensors - read each channel invidivually as not all support the optimization of reading in bulk. This is technically a fix, but will need to be backported if desired. - support open drain and shared interrupts. * ti-adc081c - triggered buffer support. Cleanups * inkern - white space fix. * ad7606 - use the iio_device_claim_direct_mode call rather than open coding equiv. * ad799x - white space fix. * ad9523 - unsigned -> unsigned int * apds9660 - brace location tidying up. - silence an uninitialized variable warning. * ak8975 - else and brace on same line fix. * at91_adc - white space fixes. * bmc150 - use regmap stored copy of the device pointer rather than having an additional copy. * bmg160 - use regmap stored copy of the device pointer rather than having an additional copy. * hid-sensors - white space fixes. * mcp3422 - white space fix. * mma7455 - use regmap to retrieve the device struct rather than carrying another copy in the private data. * ms_sensors - white space fix. * mxs-lradc - move current bindings out of staging - some will be shortly deprecated but the reality is that we have device trees out there using them so they will need to be supported for some time. They accidentally got left behind when the driver graduated from staging. - white space cleanup. - set INPUT_PROP_DIRECT. - move ts config into a better function. - move the STMP reset out of the ADC init. * vf610_adc - case label indenting fix. commit f0183a338e4f90e59a4b4daa10cba0fae8e3fca7 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 18 13:09:11 2016 +0300 usb: storage: fix multi-line comment style No functional changes here, just making sure our storage driver uses a consistent multi-line comment style. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/storage/alauda.c | 22 ++- drivers/usb/storage/cypress_atacb.c | 34 ++-- drivers/usb/storage/datafab.c | 22 ++- drivers/usb/storage/debug.c | 3 +- drivers/usb/storage/debug.h | 3 +- drivers/usb/storage/ene_ub6250.c | 25 +-- drivers/usb/storage/freecom.c | 75 +++++--- drivers/usb/storage/initializers.c | 15 +- drivers/usb/storage/initializers.h | 15 +- drivers/usb/storage/isd200.c | 51 ++--- drivers/usb/storage/jumpshot.c | 22 ++- drivers/usb/storage/karma.c | 3 +- drivers/usb/storage/option_ms.c | 6 +- drivers/usb/storage/protocol.c | 12 +- drivers/usb/storage/protocol.h | 3 +- drivers/usb/storage/realtek_cr.c | 12 +- drivers/usb/storage/scsiglue.c | 147 ++++++++++----- drivers/usb/storage/scsiglue.h | 3 +- drivers/usb/storage/sddr09.c | 82 +++++--- drivers/usb/storage/sddr55.c | 45 +++-- drivers/usb/storage/shuttle_usbat.c | 16 +- drivers/usb/storage/sierra_ms.c | 3 +- drivers/usb/storage/transport.c | 165 ++++++++++------ drivers/usb/storage/transport.h | 3 +- drivers/usb/storage/uas.c | 3 +- drivers/usb/storage/unusual_alauda.h | 3 +- drivers/usb/storage/unusual_cypress.h | 3 +- drivers/usb/storage/unusual_datafab.h | 6 +- drivers/usb/storage/unusual_devs.h | 334 ++++++++++++++++++++++----------- drivers/usb/storage/unusual_freecom.h | 3 +- drivers/usb/storage/unusual_isd200.h | 3 +- drivers/usb/storage/unusual_jumpshot.h | 3 +- drivers/usb/storage/unusual_karma.h | 3 +- drivers/usb/storage/unusual_onetouch.h | 6 +- drivers/usb/storage/unusual_realtek.h | 3 +- drivers/usb/storage/unusual_sddr09.h | 3 +- drivers/usb/storage/unusual_sddr55.h | 3 +- drivers/usb/storage/unusual_uas.h | 3 +- drivers/usb/storage/unusual_usbat.h | 3 +- drivers/usb/storage/usb.c | 98 ++++++---- drivers/usb/storage/usb.h | 14 +- drivers/usb/storage/usual-tables.c | 3 +- 42 files changed, 829 insertions(+), 455 deletions(-) commit 5b91dfe187bbe3a8116432016375f39fff91a237 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 18 13:09:10 2016 +0300 usb: storage: scsiglue: limit USB3 devices to 2048 sectors USB3 devices, because they are much newer, have much less chance of having issues with larger transfers. We still keep a limit because anything above 2048 sectors really rendered negligible speed improvements, so we will simply ignore that. Transferring 1MiB should already give us pretty good performance. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/storage/scsiglue.c | 5 +++++ 1 file changed, 5 insertions(+) commit 779b457f66e10de3471479373463b27fd308dc85 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 18 13:09:09 2016 +0300 usb: storage: scsiglue: further describe our 240 sector limit Just so we have some sort of documentation as to why we limit our Mass Storage transfers to 240 sectors, let's update the comment to make clearer that devices were found that would choke with larger transfers. While at that, also make sure to clarify that other operating systems have similar, albeit different, limits on mass storage transfers. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/storage/scsiglue.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) commit d64aab0c6fdc67113f2332a295d244b53bf694d6 Author: Oliver Neukum <oneukum@suse.com> Date: Wed Apr 20 16:28:09 2016 +0200 hub: admit devices are SS+ If a port can do 10 Gb/s the kernel should say so. The corresponding check needs to be added. Signed-off.by: Oliver Neukum <ONeukum@suse.com>> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/core/hub.c | 2 ++ 1 file changed, 2 insertions(+) commit fca504f6054f2a62d966afde23a0cfbf9e3dc32f Author: Oliver Neukum <oneukum@suse.com> Date: Wed Apr 20 15:39:12 2016 +0200 USB: correct intervals for SS+ SS+ also expresses intervals in units of 125ms. Testing must be for SS or faster, not SS exactly. Signed-off-by: Oliver neukum <oneukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/usb.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit dd80b54b18db3d76a43558daaa6ea3aa67f5aacd Author: Oliver Neukum <oneukum@suse.com> Date: Wed Apr 20 15:39:11 2016 +0200 USB: LTM also for USB 3.1 LTM is also defined for SS+. The correct test is to check for anything slower than SS not exactly SS. Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/linux/usb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 38a879ba9c0a6849fe26c36e325f754a89848da7 Author: Toshi Kani <toshi.kani@hpe.com> Date: Mon Apr 25 15:34:59 2016 -0600 acpi/nfit: Add sysfs "id" for NVDIMM ID ACPI 6.1, section 5.2.25.9, defines an identifier for an NVDIMM. Change the NFIT driver to add a new sysfs file "id" under nfit directory. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Robert Moore <robert.moore@intel.com> Cc: Robert Elliott <elliott@hpe.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 5ad9a7fde07a95b326da9e650b4f0a41b85e47b5 Author: Toshi Kani <toshi.kani@hpe.com> Date: Mon Apr 25 15:34:58 2016 -0600 acpi/nfit: Update nfit driver to comply with ACPI 6.1 ACPI 6.1, Table 5-133, updates NVDIMM Control Region Structure as follows. - Valid Fields, Manufacturing Location, and Manufacturing Date are added from reserved range. No change in the structure size. - IDs (SPD values) are stored as arrays of bytes (i.e. big-endian format). The spec clarifies that they need to be represented as arrays of bytes as well. This patch makes the following changes to support this update. - Change the NFIT driver to show SPD ID values in big-endian format. - Change sprintf format to use "0x" instead of "#" since "%#02x" does not prepend '0'. link: http://www.uefi.org/sites/default/files/resources/ACPI_6_1.pdf Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Robert Moore <robert.moore@intel.com> Cc: Robert Elliott <elliott@hpe.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit dd485951e79a6dcbf18ba1612ad91d45e4cfa9a7 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Tue Apr 26 13:22:33 2016 -0400 i2c: nforce2: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-nforce2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0e7dd0c9c3cde901f79f04260aa706bbfdc0c67e Author: Florian Westphal <fw@strlen.de> Date: Tue Apr 26 23:14:30 2016 +0200 pch_gbe: fix bogus trylock conversion Should have converted 'if (trylock)' to 'lock'. Fixes: a6086a893718db ("drivers: net: remove NETDEV_TX_LOCKED") Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2b899f34e1db9adef8716d07e872a800dfa60790 Author: Oleksij Rempel <linux@rempel-privat.de> Date: Tue Apr 26 08:27:46 2016 +0200 i2c: imx: reduce load by using usleep_range instead of udelay Documentation/timers/timers-howto.txt recommends to use usleep_range on delays > 10usec. According to my test results with Neonode zForce touchscreen driver, usleep_range indeed reduces CPU load. Stats collected with "./perf record -a -g -F 1000 sleep 10" i2c-imx with udelay(50): 34.19% 0.00% irq/220-Neonode [kernel.kallsyms] [k] irq_thread ---irq_thread |--33.75%--irq_thread_fn | |--19.27%--0x7f08a878 | | i2c_master_recv | | i2c_transfer | | __i2c_transfer | | i2c_imx_xfer | | |--11.71%--i2c_imx_trx_complete | | |--5.70%--i2c_imx_start <<<<---------------- | | | |--5.38%--__timer_const_udelay | | | | __timer_delay | | | | --5.07%--read_current_timer i2c-imx with usleep_range(50,100) 29.08% 0.00% irq/220-Neonode [kernel.kallsyms] [k] irq_thread ---irq_thread |--28.89%--irq_thread_fn | |--17.21%--0x7f08a878 | | i2c_master_recv | | |--17.14%--i2c_transfer | | | __i2c_transfer | | | i2c_imx_xfer | | | |--14.29%--i2c_imx_trx_complete | | | |--1.42%--i2c_imx_start <<<<---------- | | | | |--0.71%--usleep_range | | | | |--0.53%--i2c_imx_bus_busy Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: Dirk Behme <dirk.behme@de.bosch.com> Reviewed-by: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-imx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6bfc49197eba070b799ab4ca8755d3a9fd1700da Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon Apr 18 17:07:44 2016 -0400 f2fs: issue cache flush on direct IO Under direct IO path with O_(D)SYNC, it needs to set proper APPEND or UPDATE flags, so taht f2fs_sync_file can make its data safe. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 608514deba38c8611ad330d6a3c8e2b9a1f68e4b Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 15 09:43:17 2016 -0700 f2fs: set fsync mark only for the last dnode In order to give atomic writes, we should consider power failure during sync_node_pages in fsync. So, this patch marks fsync flag only in the last dnode block. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 4 +- fs/f2fs/file.c | 14 +++++-- fs/f2fs/node.c | 106 +++++++++++++++++++++++++++++++++++++++++++++++++---- fs/f2fs/recovery.c | 9 ++--- 4 files changed, 113 insertions(+), 20 deletions(-) commit c267ec1526da2d3b12c80a89ebd8eb9b6a01d636 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Apr 15 09:25:04 2016 -0700 f2fs: report unwritten status in fsync_node_pages The fsync_node_pages should return pass or failure so that user could know fsync is completed or not. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 4 +++- fs/f2fs/node.c | 13 ++++++------- 2 files changed, 9 insertions(+), 8 deletions(-) commit 5268137564920843e581304d9bfb06fb9502cf24 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Apr 13 16:24:44 2016 -0700 f2fs: split sync_node_pages with fsync_node_pages This patch splits the existing sync_node_pages into (f)sync_node_pages. The fsync_node_pages is used for f2fs_sync_file only. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 2 +- fs/f2fs/f2fs.h | 3 +- fs/f2fs/file.c | 2 +- fs/f2fs/gc.c | 2 +- fs/f2fs/node.c | 108 +++++++++++++++++++++++++++++++++++++-------------- 5 files changed, 84 insertions(+), 33 deletions(-) commit e6e5f5610d585551785ec654b6db9277b19a0664 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Thu Apr 14 16:48:52 2016 -0700 f2fs: avoid writing 0'th page in volatile writes The first page of volatile writes usually contains a sort of header information which will be used for recovery. (e.g., journal header of sqlite) If this is written without other journal data, user needs to handle the stale journal information. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/data.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit eca76e783cf5970db36edfda7e66487d897ea222 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Apr 13 16:14:38 2016 -0700 f2fs: avoid needless lock for node pages when fsyncing a file When fsync is called, sync_node_pages finds a proper direct node pages to flush. But, it locks unrelated direct node pages together unnecessarily. Acked-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/node.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 1bb1ff3e7c74f4569dddf7bda8054a0bb6ed0073 Author: Peter Swain <pswain@cavium.com> Date: Mon Apr 25 16:33:37 2016 +0200 i2c: octeon: Improve performance if interrupt is early There is a race between the TWSI interrupt and the condition that is required before proceeding: Low-level: interrupt flag bit must be set High-level controller: valid bit must be clear If the interrupt comes too early and the condition is not met the wait will time out, and the transfer is aborted leading to very poor performance. To avoid this race retry for the condition ~80 µs later. The retry is avoided on the very first invocation of wait_event_timeout() (which tests the condition before entering the wait and is therefore always wrong in this case). EEPROM reads on 100kHz i2c now measure ~5.2kB/s, about 1/2 what's achievable, and much better than the worst-case 100 bytes/sec before. While at it remove the debug print from the low-level wait function. Signed-off-by: Peter Swain <pswain@cavium.com> Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 55 ++++++++++++++++++++++++++++++++++------- 1 file changed, 46 insertions(+), 9 deletions(-) commit db0a6fb5d97afe01fd9c47d37c6daa82d4d4001d Author: Richard Guy Briggs <rgb@redhat.com> Date: Thu Apr 21 14:14:01 2016 -0400 audit: add tty field to LOGIN event The tty field was missing from AUDIT_LOGIN events. Refactor code to create a new function audit_get_tty(), using it to replace the call in audit_log_task_info() and to add it to audit_log_set_loginuid(). Lock and bump the kref to protect it, adding audit_put_tty() alias to decrement it. Signed-off-by: Richard Guy Briggs <rgb@redhat.com> Signed-off-by: Paul Moore <paul@paul-moore.com> include/linux/audit.h | 24 ++++++++++++++++++++++++ kernel/audit.c | 18 +++++------------- kernel/auditsc.c | 8 ++++++-- 3 files changed, 35 insertions(+), 15 deletions(-) commit 392d01de2d2476e8a50cf30f049e369deaaea127 Author: Jan Glauber <jglauber@cavium.com> Date: Tue Apr 26 16:26:52 2016 +0200 i2c: octeon: Remove zero-length message support Zero-length message support (SMBUS QUICK or i2c) never worked with the Octeon hardware. Disable SMBUS QUICK support and bail out in case of a zero-length i2c request. After this change 'i2c-detect -q' will return an error on Octeon but the previously reported results were wrong anyway. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit 2b13f01b90fc07334911b424709901bb88517746 Author: Mark Brown <broonie@kernel.org> Date: Fri Apr 15 08:53:43 2016 +0100 arm64: defconfig: Enable ACPI Enable ACPI by default to support testing of ACPI only systems and ensure that defconfig will boot on anything, for arm64 this is not done in Kconfig since a very large proportion of arm64 systems have no ACPI at all. Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Hanjun Guo <hanjun.guo@linaro.org> Acked-by: Roy Franz <roy.franz@hpe.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit 46bcc6b1f3f77ff0a5b88b87a6be5954ed0c3ce6 Author: Mark Brown <broonie@kernel.org> Date: Fri Apr 15 08:53:42 2016 +0100 ACPI / ARM64: Remove EXPERT dependency for ACPI on ARM64 When ACPI was originally merged for arm64 it had only been tested on emulators and not on real physical platforms and no platforms were relying on it. This meant that there were concerns that there might be serious issues attempting to use it on practical systems so it had a dependency on EXPERT added to warn people that it was in an early stage of development with very little practical testing. Since then things have moved on a bit. We have seen people testing on real hardware and now have people starting to produce some platforms (the most prominent being the 96boards Cello) which only have ACPI support and which build and run to some useful extent with mainline. This is not to say that ACPI support or support for these systems is completely done, there are still areas being worked on such as PCI, but at this point it seems that we can be reasonably sure that ACPI will be viable for use on ARM64 and that the already merged support works for the cases it handles. For the AMD Seattle based platforms support outside of PCI has been fairly complete in mainline a few releases now. This is also not to say that we don't have vendors working with ACPI who are trying do things that we would not consider optimal but it does not appear that the EXPERT dependency is having a substantial impact on these vendors. Given all this it seems that at this point the EXPERT dependency mainly creates inconvenience for users with systems that are doing the right thing and gets in the way of including the ACPI code in the testing that people are doing on mainline. Removing it should help our ongoing testing cover those platforms with only ACPI support and help ensure that when ACPI code is merged any problems it causes for other users are more easily discovered. Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Graeme Gregory <graeme.gregory@linaro.org> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Al Stone <ahs3@redhat.com> Acked-by: Hanjun Guo <hanjun.guo@linaro.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Roy Franz <roy.franz@hpe.com> Acked-by: Olof Johansson <olof@lixom.net> Acked-by: Timur Tabi <timur@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6df795ff139a85eba8767a1504414c41e8814a1a Author: Mark Brown <broonie@kernel.org> Date: Fri Apr 15 08:53:41 2016 +0100 ACPI / ARM64: Don't enable ACPI by default on ARM64 If ACPI is selectable it is enabled by default. This is a good choice for architectures where the overwhelming majority of systems use ACPI like x86 and IA-64 but is less clear for architectures where it's less common like ARM64. Change the default selection so that it's only done explicitly on those architectures where ACPI is universally used. Signed-off-by: Mark Brown <broonie@kernel.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Hanjun Guo <hanjun.guo@linaro.org> Acked-by: Olof Johansson <olof@lixom.net> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 164a2159a2d6789bc7e3c4b126dde7f3ce865992 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Tue Apr 26 08:47:18 2016 +0200 PM / Domains: Drop unnecessary wakeup code from pm_genpd_prepare() As the PM core already have wakeup management during the system PM phase, it seems reasonable that genpd and its users should be able to rely on that. Therefore let's remove this from pm_genpd_prepare(). Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/domain.c | 6 ------ 1 file changed, 6 deletions(-) commit 624c8df7d2823ec0df9609025480309322886ed3 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Tue Apr 26 08:47:17 2016 +0200 PM / Domains: Remove redundant pm_runtime_get|put*() in pm_genpd_prepare() The PM core increases and decreases the runtime PM usage count in the system PM prepare phase. This makes some of the pm_runtime_get|put*() calls in pm_genpd_prepare() redundant, so let's remove them. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/domain.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit 50d5d2bd1d4273f1417135965a151e13f1f061c4 Merge: 3ccec4b ec65cfc Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 16:07:21 2016 -0400 Merge branch 'sh_eth-next' Sergei Shtylyov says: ==================== sh_eth: couple of software reset bit cleanups Here's a set of 2 patches against DaveM's 'net-next.git' repo. We clean up the use of the software reset bits... ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit ec65cfce508885e433445036ab46f4ec91d32c5c Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 23:46:15 2016 +0300 sh_eth: rename ARSTR register bit The Renesas RZ/A1H manual names the software reset bit in the software reset register (ARSTR) ARST which makes a bit more sense than the ARSTR_ARSTR name used now by the driver -- rename the latter to ARSTR_ARST. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/sh_eth.c | 6 +++--- drivers/net/ethernet/renesas/sh_eth.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit 97717edc69eabdcc8b1859af75a363790c3e9cb6 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 23:45:23 2016 +0300 sh_eth: use EDMR_SRST_GETHER in sh_eth_check_reset() sh_eth_check_reset() uses a bare number where EDMR_SRST_GETHER would fit, i.e. the receive/trasmit software reset bits that comprise EDMR_SRST_GETHER read as 1 while the corresponding reset is in progress and thus, when both are 0, the reset is complete. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/sh_eth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3ccec4bd10c95bbd8729b1edebef887b666905bf Merge: 4e095a9 1b223dd Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 15:58:03 2016 -0400 Merge branch 'mlx5-next' Saeed Mahameed says: ==================== Mellanox 100G extending mlx5 ethtool support Changes from V0: - Dropped: net/mlx5e: Disable link up on INIT HCA command Due to Ido's and Or's requests we will submit this patch to net and will need it for -stable. - Rebased to: 11afbff86168 ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next") This series is centralized around extending and improving mlx5 ethernet driver ethtool support. We've done some code refactoring for ethtool statistics reporting, making it more scalable and robust, now each reported ethtool counter belongs to a group and has its own descriptor within that group, the descriptor holds the counter name and offset in memory in that group memory block. Added new counters: - Reporting more error and drop counter in ifconig/ip tool. - Per priority pause and traffic counter in ethtool. - link down events counter in ethtool. Set features handling was also refactored a little bit to be more resilient and generic, now setting more than one feature will not stop on the first failed one, but instead it will try to continue setting others. We made it generic to make it simpler for adding more features support, it is now done easily by only introducing a handler function of the new supported netdev feature, and let the generic handler do the job. New netdev features and ethtool support: - Netdev feature RXALL, set on/off FCS check offload. - Netdev feature HW_VLAN_CTAG_RX, set on/off rx-vlan stripping offload. - Ethtool interface identify. - Ethtool dump module EEPROM. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 1b223dd391622fde05e03829d813c3c6cc998685 Author: Saeed Mahameed <saeedm@mellanox.com> Date: Sun Apr 24 22:51:56 2016 +0300 net/mlx5e: Fix checksum handling for non-stripped vlan packets Now as rx-vlan offload can be disabled, packets can be received with vlan tag not stripped, which means is_first_ethertype_ip will return false, for that we need to check if the hardware reported csum OK so we will report CHECKSUM_UNNECESSARY for those packets. Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 1 + drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 20 +++++++++++++++----- drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 8 ++++++-- include/linux/mlx5/device.h | 21 ++++++++++++++++----- 4 files changed, 38 insertions(+), 12 deletions(-) commit 363501145e3faa650193722fe7047b767ed87172 Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:55 2016 +0300 net/mlx5e: Add ethtool support for rxvlan-offload (vlan stripping) Use ethtool -K <interface> rxvlan <on/off> to enable/disable C-TAG vlan stripping by hardware. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 3 + drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 74 ++++++++++++++++++++++- include/linux/mlx5/driver.h | 4 ++ 3 files changed, 78 insertions(+), 3 deletions(-) commit bb64143eee8c036a89b31daa4e9bf8360a8bded1 Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:54 2016 +0300 net/mlx5e: Add ethtool support for dump module EEPROM Add query MCIA, PMLP registers infrastructure and commands. Add ethtool support for get_module_info() and get_module_eeprom() callbacks. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 80 ++++++++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/port.c | 76 ++++++++++++++++++++ include/linux/mlx5/driver.h | 3 +- include/linux/mlx5/port.h | 15 ++++ 4 files changed, 173 insertions(+), 1 deletion(-) commit da54d24ec3ef736de04c61a01653776a9750334f Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:53 2016 +0300 net/mlx5e: Add ethtool support for interface identify (LED blinking) Add the needed hardware command and mlx5_ifc structs for managing LED control. Add set_phys_id ethtool callback to support ethtool -p flag. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Eugenia Emantayev <eugenia@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 25 ++++++++++++++++++++++ drivers/net/ethernet/mellanox/mlx5/core/port.c | 13 +++++++++++ include/linux/mlx5/driver.h | 1 + include/linux/mlx5/port.h | 6 ++++++ 4 files changed, 45 insertions(+) commit 94cb1ebbafd509210887eea6ced55c40da7b4baa Author: Eran Ben Elisha <eranbe@mellanox.com> Date: Sun Apr 24 22:51:52 2016 +0300 net/mlx5e: Add support for RXALL netdev feature Introduce new access register named Ports Check Mask Register (PCMR) to control all HW checks on port. With this register, the driver can enable/disable Hardware FCS validation. When RXALL is enabled/disabled using ndo_set_features, enable/disable fcs check at HW. User can change HW configuration using rx-all flag at ethtool. Signed-off-by: Eran Ben Elisha <eranbe@mellanox.com> Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 20 +++++++++ drivers/net/ethernet/mellanox/mlx5/core/port.c | 49 +++++++++++++++++++++++ include/linux/mlx5/driver.h | 1 + include/linux/mlx5/port.h | 4 ++ 4 files changed, 74 insertions(+) commit 0e405443e803a3ce9ba22f11be37e2a74f3fb9ad Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:51 2016 +0300 net/mlx5e: Improve set features ndo resiliency In current mlx5e ndo_set_features implementation, setting some features can success while others can fail. Today, we return one error code which doesn't reflect the current features status of the netdev at the end of the ndo callback. Set netdev->features with features which were successfully set in order to keep the current status in case of failure. For this purpose, define new Macro to set/unset specific feature in netdev->features. This patch introduces a mechanism that uses feature handlers for each feature. Set features will call a generic handler, which will then call a specific handler in his turn and update netdev->features according to it's return value. Each specific handler is responsible to perform driver specific actions, and updating params if needed. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 110 ++++++++++++++++------ 1 file changed, 82 insertions(+), 28 deletions(-) commit 121fcdc84d8240d4dfe1f737befd5814b12623ee Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:50 2016 +0300 net/mlx5e: Add link down events counter Expose link_down_events counter through ethtool -S. This counter is read from PPort statistics, then proccessed and stored as a special handling software counter. This counter is stored along software counters since it is the only PPort counter that it's size is not 64 bits. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 10 +++++++++- drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 5 +++++ include/linux/mlx5/device.h | 1 + 3 files changed, 15 insertions(+), 1 deletion(-) commit cf678570d5a1022c4c4dbda7792f2a36f0b9fec0 Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:49 2016 +0300 net/mlx5e: Add per priority group to PPort counters Expose counters providing information for each priority level (PCP) through ethtool -S option and DCBNL. This includes rx/tx bytes, frames, and pause counters. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_dcbnl.c | 6 +++ .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 51 ++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 9 ++++ drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 31 ++++++++++++- 4 files changed, 93 insertions(+), 4 deletions(-) commit 8075cb72382bf854a3a95f74ea4f9d19ebe29fd5 Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:48 2016 +0300 net/mlx5e: Rename VPort counters VPort and software counters names are confusing and may be unclear, all VPort counters now have a prefix of rx/tx_vport_*. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 35 ++++++++++++---------- 1 file changed, 19 insertions(+), 16 deletions(-) commit 9218b44dcc059e08e249f6f7614b8e391eb041d8 Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:47 2016 +0300 net/mlx5e: Statistics handling refactoring Redesign ethtool statistics handling and reporting in the driver: 1. Move counters to a separate file (en_stats.h). 2. Remove unnecessary dependencies between stats and strings. 3. Use counter descriptors which hold a name and offset for each counter, and will be used to decide which counters will be exposed. For example when adding a new software counter to ethtool, instead of: 1. Add to stats struct. 2. Add to strings struct in the same order. 3. Change macro defining number of software counters. The only thing needed is to link the new counter to a counter descriptor. VPort counters are a set of hardware traffic counters created automatically for each virtual port opened. PPort counters are a set of counters describing per physical port performance statistics. These counters are gathered from hardware register and divided to groups according to different protocols. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 240 +--------------- .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 132 ++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 232 +++++---------- drivers/net/ethernet/mellanox/mlx5/core/en_stats.h | 318 +++++++++++++++++++++ include/linux/mlx5/device.h | 1 + 5 files changed, 483 insertions(+), 440 deletions(-) commit 269e6b3af3bfbc4e50b497924c2abb1c4cf3364e Author: Gal Pressman <galp@mellanox.com> Date: Sun Apr 24 22:51:46 2016 +0300 net/mlx5e: Report additional error statistics in get stats ndo Provide rtnl_link_stats64 with information regarding physical errors to be seen in ifconfig and ip tool. Signed-off-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 39 +++++++++++++++++++---- 1 file changed, 33 insertions(+), 6 deletions(-) commit 4e095a9a6ee50ba8a9820a4991b6a2a27c67bdb4 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 15:57:19 2016 -0400 infiniband: nes: Kill unused variable in nes_netdev_start_xmit() Signed-off-by: David S. Miller <davem@davemloft.net> drivers/infiniband/hw/nes/nes_nic.c | 1 - 1 file changed, 1 deletion(-) commit c578e9ab4cd467bd7b9e1ea391b5376894c56d0d Merge: c971c0e f0cdf76 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 15:53:06 2016 -0400 Merge branch 'netdev_tx_locked-removal' Florian Westphal says: ==================== net: core: remove TX_LOCKED support Not that many users left, lets kill it. TX_LOCKED was meant to be used by LLTX drivers when spin_trylock() failed. Stack then re-queued if collisions happened on different cpus or free'd the skb to prevent deadlocks. Most of the driver removal patches fall into one of three categories: 1. remove the driver-private tx lock (and LLTX flag), or... 2. convert spin_trylock to plain spin_lock, or... 3. convert TX_LOCKED to free+TX_OK Patches are grouped by these categories, last patch is the actual removal. All driver changes were compile tested only with exception of atl1e. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f0cdf76c103ffa34ca5ac87dcdef7edffc722cbf Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:14 2016 +0200 net: remove NETDEV_TX_LOCKED support No more users in the tree, remove NETDEV_TX_LOCKED support. Adds another hole in softnet_stats struct, but better than keeping the unused collision counter around. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/netdev-features.txt | 10 ++++----- Documentation/networking/netdevices.txt | 9 +++----- include/linux/netdevice.h | 3 --- net/core/net-procfs.c | 3 ++- net/core/pktgen.c | 1 - net/sched/sch_generic.c | 32 ---------------------------- 6 files changed, 9 insertions(+), 49 deletions(-) commit a6086a893718db07ef9e7af5624ec27cb376ef0a Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:13 2016 +0200 drivers: net: remove NETDEV_TX_LOCKED replace the trylock by a full spin_lock and remove TX_LOCKED return value. Followup patch will remove TX_LOCKED from the kernel. Cc: Jon Mason <jdmason@kudzu.us> Cc: Andy Gospodarek <andy@greyhouse.net> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb/sge.c | 3 +-- drivers/net/ethernet/neterion/s2io.c | 9 +-------- drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c | 6 ++---- drivers/net/ethernet/tehuti/tehuti.c | 8 +------- drivers/net/rionet.c | 6 +----- 5 files changed, 6 insertions(+), 26 deletions(-) commit 926f27300100f4233c7665649f68fcf615f58d68 Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:12 2016 +0200 drivers: net: use NETDEV_TX_OK instead of NETDEV_TX_LOCKED These drivers already call netif_stop_queue() so we should not be called unless tx space is available. Just free the skb and return TX_OK. Followup patch will remove NETDEV_TX_LOCKED from the kernel. Cc: linux-parisc@vger.kernel.org Cc: linux-hams@vger.kernel.org Cc: Thomas Sailer <t.sailer@alumni.ethz.ch> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/amd/7990.c | 8 +++++--- drivers/net/ethernet/amd/a2065.c | 7 +++---- drivers/net/ethernet/dec/tulip/de4x5.c | 7 +++++-- drivers/net/hamradio/baycom_epp.c | 6 ++++-- drivers/net/hamradio/hdlcdrv.c | 6 ++++-- 5 files changed, 21 insertions(+), 13 deletions(-) commit 4acff371f2e3f386422253c7fce0092a793ec1a4 Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:11 2016 +0200 atle1: remove LLTX support and TX_UNLOCKED similar to atl1c: lock is only used in ndo_start_xmit, but we also advertised LLTX, so remove that as well and let core stack handle tx locking. Allows to remove the TX_LOCKED return value from the driver. Cc: Jay Cliburn <jcliburn@gmail.com> Cc: Chris Snook <chris.snook@gmail.com> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/atheros/atl1e/atl1e.h | 1 - drivers/net/ethernet/atheros/atl1e/atl1e_main.c | 12 +----------- 2 files changed, 1 insertion(+), 12 deletions(-) commit 353e3bd5a7081f23a9f015cbf172ec25b1412b93 Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:10 2016 +0200 atl1c: remove private tx lock AFAICS this is safe: the lock is only used in the .ndo_start_xmit function and this driver does not set LLTX. Gets rid of TX_LOCKED return value, followup patches will remove it. Cc: Jay Cliburn <jcliburn@gmail.com> Cc: Chris Snook <chris.snook@gmail.com> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/atheros/atl1c/atl1c.h | 3 +-- drivers/net/ethernet/atheros/atl1c/atl1c_main.c | 11 ----------- 2 files changed, 1 insertion(+), 13 deletions(-) commit 47975cd1022d12735f02046ef8ada83f8ad24087 Author: Florian Westphal <fw@strlen.de> Date: Sun Apr 24 21:38:09 2016 +0200 RDMA/nes: remove use of NETDEV_TX_LOCKED ndo_start_xmit never returns it to stack, but nes_nic_send helper used it if skb could not be queued to hardware. Switch to bool instead. Cc: <linux-rdma@vger.kernel.org> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/infiniband/hw/nes/nes_nic.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit 96bab35d1c4ab706922abd7cef8262fdca07664a Author: Benjamin Poirier <bpoirier@suse.com> Date: Tue Apr 26 11:52:01 2016 -0700 localmodconfig: Reset certificate paths When using `make localmodconfig` and friends, if the input config comes from a kernel that was built in a different environment (for example, the canonical case of using localmodconfig to trim a distribution kernel config) the key files for module signature checking will not be available and should be regenerated or omitted. Otherwise, the user will be faced with annoying errors when trying to build with the generated .config: make[1]: *** No rule to make target 'keyring.crt', needed by 'certs/x509_certificate_list'. Stop. Makefile:1576: recipe for target 'certs/' failed Link: http://lkml.kernel.org/r/1461696721-3001-1-git-send-email-bpoirier@suse.com Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit c2316dbf124257ae19fd2e29cb5ec51060649d38 Author: Stephen Smalley <sds@tycho.nsa.gov> Date: Fri Apr 8 13:55:03 2016 -0400 selinux: apply execstack check on thread stacks The execstack check was only being applied on the main process stack. Thread stacks allocated via mmap were only subject to the execmem permission check. Augment the check to apply to the current thread stack as well. Note that this does NOT prevent making a different thread's stack executable. Suggested-by: Nick Kralevich <nnk@google.com> Acked-by: Nick Kralevich <nnk@google.com> Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 8e4ff6f228e4722cac74db716e308d1da33d744f Author: Stephen Smalley <sds@tycho.nsa.gov> Date: Fri Apr 8 13:52:00 2016 -0400 selinux: distinguish non-init user namespace capability checks Distinguish capability checks against a target associated with the init user namespace versus capability checks against a target associated with a non-init user namespace by defining and using separate security classes for the latter. This is needed to support e.g. Chrome usage of user namespaces for the Chrome sandbox without needing to allow Chrome to also exercise capabilities on targets in the init user namespace. Suggested-by: Dan Walsh <dwalsh@redhat.com> Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 14 +++++++------- security/selinux/include/classmap.h | 28 ++++++++++++++++++---------- 2 files changed, 25 insertions(+), 17 deletions(-) commit c971c0e580a6478c75339e45300e8ae3d167c0e9 Merge: f796721 af5840a Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 15:41:21 2016 -0400 Merge branch 'get_phy_device-retval' Sergei Shtylyov says: ==================== Don't return NULL from get_phy_device() anymore Here's the set of 5 patches against DaveM's 'net-next.git' repo. The first patch makes get_phy_device() return only error values on error, the rest of the patches clean up the callers of that function... ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit af5840a968fcb175900e5b821f37363a089f5b75 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 20:31:42 2016 +0300 of_mdio: get_phy_device() doesn't return NULL anymore Now that get_phy_device() no longer returns NULL on error, we don't need to check for it... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/of/of_mdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 66c239e71adee694bc35f44387fb373942cfd957 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 20:30:53 2016 +0300 mdio_bus: get_phy_device() doesn't return NULL anymore Now that get_phy_device() no longer returns NULL on error, we don't need to check for it... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/mdio_bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4914a584b1d66680532b20898cba1cf7d5ae63e4 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 20:29:23 2016 +0300 fixed_phy: get_phy_device() doesn't return NULL anymore Now that get_phy_device() no longer returns NULL on error, we don't need to check for it... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/fixed_phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fb1116ab7cf55f9b022c2a2d40a0f0c4464eb201 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 20:27:49 2016 +0300 xgene: get_phy_device() doesn't return NULL anymore Now that get_phy_device() no longer returns NULL on error, we don't need to check for it... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/apm/xgene/xgene_enet_hw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b74766a0a0feeef5c779709cc5d109451c0d5b17 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 20:25:23 2016 +0300 phylib: don't return NULL from get_phy_device() Arnd Bergmann asked that get_phy_device() returns either NULL or the error value, not both on error. Do as he said, return ERR_PTR(-ENODEV) instead of NULL when the PHY ID registers read as all ones. Suggested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/phy_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f796721040f933bb51b33f53899a382b4872b3e6 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 24 19:11:07 2016 +0300 sh_eth: get rid of the 2nd parameter to sh_eth_dev_init() sh_eth_dev_init() is now always called with 'true' as the 2nd argument, so that there's no more sense in having 2 parameters to this function... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Reviewed-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/sh_eth.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) commit 6c51cc0203de25aeaff9d0236d6c2b497be93e3b Author: Jacob Pan <jacob.jun.pan@linux.intel.com> Date: Fri Apr 22 10:17:19 2016 -0700 powercap/intel_rapl: Add support for Kabylake Kabylake is similar to Skylake in terms of RAPL. Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/powercap/intel_rapl.c | 2 ++ 1 file changed, 2 insertions(+) commit f052f20a825a80c4662dafd3899dddafd4c8f036 Author: Xin Long <lucien.xin@gmail.com> Date: Sun Apr 24 23:21:22 2016 +0800 sctp: sctp_diag should fill RMEM_ALLOC with asoc->rmem_alloc when rcvbuf_policy is set For sctp assoc, when rcvbuf_policy is set, it will has it's own rmem_alloc, when we dump asoc info in sctp_diag, we should use that value on RMEM_ALLOC as well, just like WMEM_ALLOC. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/sctp_diag.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit e96c37f185529d1db4ebc021e4f56822d43945bb Author: Francesco Ruggeri <fruggeri@arista.com> Date: Sat Apr 23 15:04:31 2016 -0700 macvtap: check minor when unregistering macvtap_device_event(NETDEV_UNREGISTER) should check vlan->minor to determine if it is being invoked in the context of a macvtap_newlink that failed, for example in this code sequence: macvtap_newlink macvlan_common_newlink register_netdevice call_netdevice_notifiers(NETDEV_REGISTER, dev) macvtap_device_event(NETDEV_REGISTER) <fail here, vlan->minor = 0> rollback_registered(dev); rollback_registered_many call_netdevice_notifiers(NETDEV_UNREGISTER, dev); macvtap_device_event(NETDEV_UNREGISTER) <nothing to clean up here> Signed-off-by: Francesco Ruggeri <fruggeri@arista.com> Acked-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macvtap.c | 3 +++ 1 file changed, 3 insertions(+) commit 308379607548524b8d86dbf20134681024935e0b Author: Francesco Ruggeri <fruggeri@arista.com> Date: Sat Apr 23 15:03:32 2016 -0700 macvlan: fix failure during registration v3 If macvlan_common_newlink fails in register_netdevice after macvlan_init then it decrements port->count twice, first in macvlan_uninit (from register_netdevice or rollback_registered) and then again in macvlan_common_newlink. A similar problem may exist in the ipvlan driver. This patch consolidates modifications to port->count into macvlan_init and macvlan_uninit (thanks to Eric Biederman for suggesting this approach). v3: remove macvtap specific bits. Signed-off-by: Francesco Ruggeri <fruggeri@arista.com> Acked-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macvlan.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 0b26985a7d76645598d98fec6922ddd1ec8cbc55 Author: Colin Ian King <colin.king@canonical.com> Date: Sat Apr 16 13:50:03 2016 +0100 PM / clk: ensure we don't allocate a -ve size of count clks It is entirely possible for of_count_phandle_wit_args to return a -ve error return value so we need to check for this otherwise we end up allocating a negative number of clk objects. Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/clock_ops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4afe6495e5cb3c352d95f07512cbb227e607e2ce Author: Wang Xiaoqiang <wangxq10@lzu.edu.cn> Date: Mon Apr 18 15:23:29 2016 +0800 tracing: Don't use the address of the buffer array name in copy_from_user With the following code snippet: ... char buf[64]; ... if (copy_from_user(&buf, ubuf, cnt)) ... Even though the value of "&buf" equals "buf", but there is no need to get the address of the "buf" again. Use "buf" instead of "&buf". Link: http://lkml.kernel.org/r/20160418152329.18b72bea@debian Signed-off-by: Wang Xiaoqiang <wangxq10@lzu.edu.cn> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c2fc0ad945d0cdb97a871046dc4ff1096e3ce266 Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Tue Apr 26 15:00:26 2016 +0200 ARM: dts: add DTS for Baltos IR2110 Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/am335x-baltos-ir2110.dts | 71 ++++++++++++++++++++++++++++++ 2 files changed, 72 insertions(+) commit d78b610eea83ba3e6a7810e07ac8f6e9859da493 Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Tue Apr 26 15:00:25 2016 +0200 ARM: dts: add DTS for Baltos IR3220 Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/am335x-baltos-ir3220.dts | 119 +++++++++++++++++++++++++++++ 2 files changed, 120 insertions(+) commit 262178b6b8e500bdd07c6f369dffa6eeecf015b8 Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Tue Apr 26 15:00:24 2016 +0200 ARM: dts: split am335x-baltos-ir5221 into dts and dtsi files Introduce am335x-baltos.dtsi, that provides common configuration for the whole device family based on the same SODIMM module. Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-baltos-ir5221.dts | 387 +-------------------------- arch/arm/boot/dts/am335x-baltos.dtsi | 408 +++++++++++++++++++++++++++++ 2 files changed, 409 insertions(+), 386 deletions(-) commit 713d4ddc99677499281fbacdfc8519b9d22513fa Merge: 101e63b a64b02d Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 13:56:27 2016 -0400 Merge branch 'qed-bandwidth-config' Manish Chopra says: ==================== qed: Bandwidth configuration support This series adds support in driver for min/max bandwidth configuration for the PF on the link change notification or on explicit request of bandwidth update from the MFW [management firmware]. The same infrastructure would later be used by user based flows [for example, rate shaping for the VFs] Please consider applying this series to "net-next" ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a64b02d5301cc7da7ac33ae3b3531ab1262d196e Author: Manish Chopra <manish.chopra@qlogic.com> Date: Tue Apr 26 10:56:10 2016 -0400 qed: Add PF min bandwidth configuration support This patch adds support for PF minimum bandwidth update or configuration notified by management firmware. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 71 ++++++++++++++++++++++ drivers/net/ethernet/qlogic/qed/qed_hsi.h | 2 + .../net/ethernet/qlogic/qed/qed_init_fw_funcs.c | 15 +++++ drivers/net/ethernet/qlogic/qed/qed_mcp.c | 10 ++- drivers/net/ethernet/qlogic/qed/qed_mcp.h | 7 +++ drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 1 + 6 files changed, 104 insertions(+), 2 deletions(-) commit 4b01e5192bd26ed4d0c3c271611cc74ae2c164f2 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Tue Apr 26 10:56:09 2016 -0400 qed: Add PF max bandwidth configuration support This patch adds support for PF maximum bandwidth update or configuration notified by management firmware. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_dev.c | 68 ++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 2 +- drivers/net/ethernet/qlogic/qed/qed_mcp.c | 138 ++++++++++++++++++------------ drivers/net/ethernet/qlogic/qed/qed_mcp.h | 14 ++- 4 files changed, 165 insertions(+), 57 deletions(-) commit bcd197c81f63afa4610e481ed353d1507ba401d0 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Tue Apr 26 10:56:08 2016 -0400 qed: Add vport WFQ configuration APIs This patch adds relevant APIs needed to configure WFQ (Weighted fair queueing) values for the vports. WFQ configuration is used per vport basis when minimum bandwidth update/configuration is notified to the PF by the management firmware. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 11 ++ drivers/net/ethernet/qlogic/qed/qed_dev.c | 188 ++++++++++++++++++++- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 2 + .../net/ethernet/qlogic/qed/qed_init_fw_funcs.c | 25 +++ drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 1 + 5 files changed, 223 insertions(+), 4 deletions(-) commit b7a1922814c617884a3fee9b107ffb784fa4cf94 Author: Vignesh R <vigneshr@ti.com> Date: Wed Apr 20 17:03:00 2016 +0530 ARM: dts: dra7x: Support QSPI MODE-0 operation at 64MHz According to Data Manual(SPRS915P) of AM57x, TI QSPI controller on DRA74(rev 1.1+)/DRA72 EVM can support up to 64MHz in MODE-0, whereas MODE-3 is limited to 48MHz. Hence, switch to MODE-0 for better throughput. Signed-off-by: Vignesh R <vigneshr@ti.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> Documentation/devicetree/bindings/spi/ti_qspi.txt | 7 +++++++ arch/arm/boot/dts/dra7-evm.dts | 6 ++---- arch/arm/boot/dts/dra72-evm-common.dtsi | 6 ++---- 3 files changed, 11 insertions(+), 8 deletions(-) commit 626180785f5d9443c475d2b2760f64bb510f2b66 Author: Vignesh R <vigneshr@ti.com> Date: Wed Apr 20 17:02:59 2016 +0530 ARM: dts: dra7x: Remove QSPI pinmux DRA7 family of processors from Texas Instruments, have a hardware module called IODELAYCONFIG Module which is expected to be configured. This block allows very specific custom fine tuning for electrical characteristics of IO pins that are necessary for functionality and device lifetime requirements. IODelay module has it's own register space with registers to configure various pins. According to AM572x TRM SPRUHZ6E October 2014–Revised January 2016[1] section 18.4.6.1 Pad Configuration, in addition to pinmuxing(MUXMODE), when operating a pad in certain mode, Virtual/Manual IO Timing Mode must also be configured to ensure that IO timings are met (DELAYMODE and MODESELECT fields of pad's IODELAYCONFIG module register). According to section 18.4.6.1.7 Isolation Requirements of above TRM, when reprogramming MUXMODE, DELAYMODE, and MODESELECT fields, there is a potential for a significant glitch on the corresponding IO. It is hence recommended to do this with I/O isolation (which can only be done in initial stages of bootloader). QSPI is one such module that requires IODELAY configuration. So, this patch removes the pinmux for QSPI for DRA74/DRA72 EVM as it needs to be done in bootloader (U-Boot) and cannot be done in kernel. Users should migrate to U-Boot v2016.05-rc1 or higher. [1] http://www.ti.com/lit/ug/spruhz6e/spruhz6e.pdf Signed-off-by: Vignesh R <vigneshr@ti.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 17 ----------------- arch/arm/boot/dts/dra72-evm-common.dtsi | 14 -------------- 2 files changed, 31 deletions(-) commit f309f549243fc2813099622df5b17e1b9f1f8aea Author: Tony Lindgren <tony@atomide.com> Date: Tue Apr 26 10:31:23 2016 -0700 ARM: omap2plus_defconfig: Enable twl6030 USB phy as loadable module This is in use on omap4 boards. Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 1 + 1 file changed, 1 insertion(+) commit 5da86baf694c5aca752b30b076d4789e05947add Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 22 13:53:19 2016 -0400 ARM: omap2plus_defconfig: Fix warning due invalid RXKAD symbol value Commit 648af7fca159 ("rxrpc: Absorb the rxkad security module") changed the RXKAD Kconfig symbol from tristate to boolean but the commit didn't update the omap2plus_defconfig that was enabling CONFIG_RXKAD as module. This leads to the following warning when using the omap2plus_defconfig: arch/arm/configs/omap2plus_defconfig:112:warning: symbol value 'm' invalid for RXKAD Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cecc77c8e54ac6874e4f92cae47cc3f2f5df3f74 Author: H. Nikolaus Schaller <hns@goldelico.com> Date: Mon Apr 18 20:20:58 2016 +0200 ARM: dts: omap5-board-common: describe gpadc for Palmas tested on OMP5432 EVM Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-board-common.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit bcb0bcd9c893dd97005a1d2dfd08abbbe1909050 Author: H. Nikolaus Schaller <hns@goldelico.com> Date: Mon Apr 18 20:20:57 2016 +0200 ARM: dts: twl6030: describe gpadc tested on Pandaboard ES. Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/twl6030.dtsi | 6 ++++++ 1 file changed, 6 insertions(+) commit 101e63b454ccd48120e4b39ae12ff2faec790acf Merge: c0b0479 ddc7740 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 13:23:58 2016 -0400 Merge branch 'cxgb4-next' Hariprasad Shenai says: ==================== cxgb4: minor fixes, decode msgs and code refactor for few functions This patch series adds new routine to get adapter information and removes some redundant messages logged in dmesg. Fixes race while freeing tx descriptors. Decodes module type and link down reason codes obtained from firmware. Refactor port initialization and FW_PORT_CMD handling. Pass correct port id in DCB message handler to obtain netdev associated. This patch series has been created against net-next tree and includes patches on cxgb4 driver. We have included all the maintainers of respective drivers. Kindly review the change and let us know in case of any review comments. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit ddc7740d9a7c7e61650309a81037f12d5cfad88e Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:29 2016 +0530 cxgb4: Decode link down reason code obtained from firmware Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 1 + drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 34 +++++++++++++++++++++++++++ drivers/net/ethernet/chelsio/cxgb4/t4fw_api.h | 5 ++++ 3 files changed, 40 insertions(+) commit 23853a0a9a7621922a21759eeed8c5bc09c71c54 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:28 2016 +0530 cxgb4: Don't assume FW_PORT_CMD reply is always port info msg The firmware can send a set of asynchronous replies through FW_PORT_CMD with DCBX information when that's negotiated with the Link Peer. The old code always assumed that a FW_PORT_CMD reply was always a Get Port Information message. This change conditionalizes the code to only handle the Get Port Information messages and throws a warning if we don't understand what we've been given. Also refactor t4_handle_fw_rpl() so that core functionality performed by t4_handle_get_port_info() for a specified port. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 1 + drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 110 +++++++++++++++++++---------- 2 files changed, 74 insertions(+), 37 deletions(-) commit 134491fdc319037f37adc5f8ec51093e5cd5ada1 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:27 2016 +0530 cxgb4: DCB message handler needs to use correct portid to netdev mapping Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4_dcb.c | 2 +- drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) commit c3e324e3d0662661f53c80fee28d70b6713f9dc8 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:26 2016 +0530 cxgb4: Refactor t4_port_init function Refactor t4_port_init() so that the core functionality is done by t4_init_portinfo() for a particular port. Also rename variables to sensible ones. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 2 + drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 93 +++++++++++++++++------------- 2 files changed, 55 insertions(+), 40 deletions(-) commit be81a2deb1134c47fadb10cb0bd6540caf6f32d7 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:25 2016 +0530 cxgb4: Properly decode port module type Decode and log port module error, unknown modules and unsupported modules. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit fbe8077687330a55e87bc26745d4992991c101ec Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:24 2016 +0530 cxgb4: Avoids race and deadlock while freeing tx descriptor There could be race between t4_eth_xmit() and t4_free_sge_resources() while freeing tx descriptors, take txq lock in t4_free_sge_resources(). We need to stop the xmit frame path which runs in bottom half context while unloading the driver using _bh variant of the lock. This is to prevent the deadlock between xmit and driver unload. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/sge.c | 2 ++ 1 file changed, 2 insertions(+) commit ed98c85ee9a16373f73afeb5bcd7b37b65c2a62f Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:23 2016 +0530 cxgb4: Add llseek operation for flash debugfs entry Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4_debugfs.c | 1 + 1 file changed, 1 insertion(+) commit 0de727383c46510f12932d32e4b66292854be508 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 26 20:10:22 2016 +0530 cxgb4: add new routine to get adapter info Add new routine to print out general adapter information (various version numbers, adapter name, part number, serial number, etc.) and remove redundant information dumped in the Port Information. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 4 ++ drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 78 ++++++++++++++++++++++--- drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 14 +++++ drivers/net/ethernet/chelsio/cxgb4/t4_hw.h | 7 +++ 4 files changed, 95 insertions(+), 8 deletions(-) commit c0b04793076167c8d8aade4c31fe06a4cc45b626 Merge: 9c9f261 5544107 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 13:15:56 2016 -0400 Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next Johan Hedberg says: ==================== pull request: bluetooth-next 2016-04-26 Here's another set of Bluetooth & 802.15.4 patches for the 4.7 kernel: - Cleanups & refactoring of ieee802154 & 6lowpan code - Security related additions to ieee802154 and mrf24j40 driver - Memory corruption fix to Bluetooth 6lowpan code - Race condition fix in vhci driver - Enhancements to the atusb 802.15.4 driver Please let me know if there are any issues pulling. Thanks. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bc19b9a81da009fd1d797d756d41b518ac7e5f14 Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 15:48:42 2016 +0200 PM / AVS: rockchip-io: make io-domains a child of the GRF IO-domain handling is part of the general register files, so should live under the grf directly. This change allows the grf to be a simple-mfd and the io-domains fetching the syscon regmap from that parent-node. The old binding is of course preserved, though deprecated. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@baylibre.com> Tested-by: David Wu <david.wu@rock-chips.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Documentation/devicetree/bindings/power/rockchip-io-domain.txt | 4 +++- drivers/power/avs/rockchip-io-domain.c | 10 +++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) commit 1c52a5139fcf3cebfd61be9293bc0da529968c0d Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 10:31:46 2016 +0200 PCI: armada: Add driver for Marvell Armada 7K/8K PCIe controller The Marvell Armada 7K/8K SoCs integrate a PCIe controller from Synopsys. Add a new driver that provides the small glue needed to use the existing Designware driver to make it work on Marvell Armada 7K/8K SoCs. The MSI support will be enabled at a later point. [bhelgaas: use dev_dbg(), dw_pcie_wait_for_link()] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/host/Kconfig | 11 ++ drivers/pci/host/Makefile | 1 + drivers/pci/host/pcie-armada8k.c | 262 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 274 insertions(+) commit 80014ad5d59cc5a141b21f46371b81736de1c44a Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 10:31:45 2016 +0200 dt-bindings: pci: add DT binding for Marvell Armada 7K/8K PCIe controller This commit adds the Device Tree binding documentation that allows to describe the PCIe controller found in Marvell Armada 7K/8K SoCs. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Acked-by: Rob Herring <rob@kernel.org> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> .../devicetree/bindings/pci/pci-armada8k.txt | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit 86f196f87fbd549a3114c81a95ba49d7daeab845 Author: Roger Quadros <rogerq@ti.com> Date: Mon Apr 25 15:53:54 2016 +0300 ARM: dts: dra7xx: Fix compatible string for PCF8575 chip The boards use a TI variant of the PCF8575 so specify that in the compatible string. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 6 +++--- arch/arm/boot/dts/dra72-evm-common.dtsi | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) commit 54d03c5d8b2a8af15b25e748fa9bc6e572060125 Author: Nishanth Menon <nm@ti.com> Date: Wed Apr 20 03:18:39 2016 -0500 ARM: dts: AM57xx/DRA7: Update SoC voltage rail limits to match data sheet As per the data sheet starting from SPRUHQ0H (Nov 2015 - Latest[1]), VDD_CORE can vary from 0.85v to 1.15v for AVS class0. VDD GPU/DSP et.al. can range from 0.85v to 1.25V with AVS class0 Since dynamic voltage scaling is disabled for DRA7/AM57xx SoCs for all SoC rails other than MPU, the bootloader is responsible for setting up the AVS class0 voltage, however, with wrong voltage machine constraints in dtb, regulator framework will lower the voltage below the required voltage levels for certain samples in production flow. This can cause catastrophic failures which can be pretty hard to identify. Update board files which don't match required specification. [1] http://www.ti.com/product/AM5728/datasheet/specifications#SPRT637-7340 Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-beagle-x15.dts | 4 ++-- arch/arm/boot/dts/dra7-evm.dts | 4 ++-- arch/arm/boot/dts/dra72-evm-common.dtsi | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) commit 30f949bc6682d4912dbc74e7e757c66b3e3a6469 Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 28 18:23:04 2016 +0900 arm64: tegra: Add IOMMU node to GM20B on Tegra210 The operating system driver can take advantage of the IOMMU to remove the need for physically contiguous memory buffers. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit e0341f1732237777d65bdda7184ea4b11fb31d53 Author: Nishanth Menon <nm@ti.com> Date: Tue Apr 26 11:36:42 2016 -0500 regulator: tps65917/palmas: Add bypass "On" value When commit b554e1450658 ("regulator: tps65917/palmas: Add bypass ops for LDOs with bypass capability") introduced bypass capability to palmas regulator, it went with the assumption that regulator regmap helpers just check val against the bypass_mask. Unfortunately, this ignored the explicit "on" and "off" values when the register value is masked with bypass_mask in commit ca5d1b3524b4 ("regulator: helpers: Modify helpers enabling multi-bit control"). With the recent commit dd1a571daee7 ("regulator: helpers: Ensure bypass register field matches ON value"), this issue gets highlighted and fails tps65917/palmas based platforms which need regulators/ldos that have bypass capability. Introduce the bypass_on value appropriately for tps65917/palmas regulator. Fixes: b554e1450658 ("regulator: tps65917/palmas: Add bypass ops for LDOs with bypass capability") Cc: Keerthy <j-keerthy@ti.com> Cc: Mark Brown <broonie@kernel.org> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/palmas-regulator.c | 5 +++++ 1 file changed, 5 insertions(+) commit 4a0778e98f31709ab3c2dcb19b56a6dc7f44241a Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 28 18:23:03 2016 +0900 arm64: tegra: Add reference clock to GM20B on Tegra210 This clock is required for the GPU to operate. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 53cafb93da6fdafc5904c27a3da83123e72e7c13 Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 28 18:23:02 2016 +0900 dt-bindings: Add documentation for GM20B GPU GM20B's definition is mostly similar to GK20A's, but requires an additional clock. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../devicetree/bindings/gpu/nvidia,gk20a.txt | 29 +++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) commit 375d2447029fc6092ca6d08329c1af61901dd8b6 Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 28 18:23:01 2016 +0900 dt-bindings: gk20a: Document iommus property GK20A can optionally make use of an IOMMU. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> Documentation/devicetree/bindings/gpu/nvidia,gk20a.txt | 4 ++++ 1 file changed, 4 insertions(+) commit 358158014f3b20c68e5f33caa032cfdb58a06bcf Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 28 18:23:00 2016 +0900 dt-bindings: gk20a: Fix typo in compatible name The correct compatible name is "nvidia,gk20a". Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> Documentation/devicetree/bindings/gpu/nvidia,gk20a.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2ab8e744a437d39619b323d7303fa2e6513274b2 Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Tue Apr 26 17:06:20 2016 +0100 ASoC: arizona: No need to update_bits when writing AEC clock control The bits in the ARIZONA_CLOCK_CONTROL register only respond to writes of a '1', a write of '0' is ignored. So there's no need to use update_bits. We can do a simple write to set bits. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/arizona.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 4e0def887d717598ae8062b46e55f9e00d3a5783 Author: Eric Engestrom <eric.engestrom@imgtec.com> Date: Mon Apr 25 10:47:56 2016 +0100 dmaengine: pxa_dma: remove duplicate const qualifier Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/pxa_dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c2a218c63ba36946aca5943c0c8ebd3a42e3dc4b Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 13:27:23 2016 -0300 perf bench: Remove one more die() call Propagate the error instead. Cc: David Ahern <dsahern@gmail.com> Cc: Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-z6erjg35d1gekevwujoa0223@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/bench/mem-functions.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit 43a3d9ba34c9ca313573201d3f45de5ab3494cec Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue Apr 12 08:30:44 2016 -0700 i40evf: Allow PF driver to configure RSS If the PF driver reports proper support, allow the PF driver to configure RSS on the behalf of the VF driver. This will allow for RSS support on future hardware without changes to the VF driver. Unfortunately, the old RSS code still needs to stay as the driver needs to be compatible with PF drivers that don't support this interface. But this change still simplifies the data structures a bunch and makes this code simpler to read and maintain. Change-ID: I0375aad40788ecdc0cb24d5cfeccf07804e69771 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf.h | 30 +- drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 121 ++++---- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 308 +++++++-------------- .../net/ethernet/intel/i40evf/i40evf_virtchnl.c | 119 ++++++++ 4 files changed, 294 insertions(+), 284 deletions(-) commit fed2db99824334b3a7219da6b45d70f448449d7d Author: Shannon Nelson <shannon.nelson@intel.com> Date: Tue Apr 12 08:30:43 2016 -0700 i40e: Specify AQ event opcode to wait for To add a little flexibility to the nvmupdate facility, this code adds the ability to specify an AQ event opcode to wait on after the Exec_AQ request. Change-ID: Iddbfd63c3de8df3edb9d3e90678b08989bc4946e Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_nvm.c | 49 +++++++++++++++++++++++---- drivers/net/ethernet/intel/i40e/i40e_type.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_type.h | 1 + 3 files changed, 44 insertions(+), 7 deletions(-) commit 042a181086077bdb83e38626b35fb96adbe45039 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 12:58:45 2016 -0300 perf tools: Update x86's syscall_64.tbl, adding preadv2 & pwritev2 Introduced in commit 4babf2c5efb7 ("x86: wire up preadv2 and pwritev2"). This will make 'perf trace' aware of them. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-vojoylgce2cetsy36446s5ny@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/entry/syscalls/syscall_64.tbl | 2 ++ 1 file changed, 2 insertions(+) commit c61fb959df898b994382d586046d7704476ff503 Author: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com> Date: Tue Apr 26 19:55:40 2016 +0530 perf probe: Fix module probe issue if no dwarf support Perf is not able to register probe in kernel module when dwarf supprt is not there(and so it goes for symtab). Perf passes full path of module where only module name is required which is causing the problem. This patch fixes this issue. Before applying patch: $ dpkg -s libdw-dev dpkg-query: package 'libdw-dev' is not installed and no information is... $ sudo ./perf probe -m /linux/samples/kprobes/kprobe_example.ko kprobe_init Added new event: probe:kprobe_init (on kprobe_init in /linux/samples/kprobes/kprobe_example.ko) You can now use it in all perf tools, such as: perf record -e probe:kprobe_init -aR sleep 1 $ sudo cat /sys/kernel/debug/tracing/kprobe_events p:probe/kprobe_init /linux/samples/kprobes/kprobe_example.ko:kprobe_init $ sudo ./perf record -a -e probe:kprobe_init [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.105 MB perf.data ] $ sudo ./perf script # No output here After applying patch: $ sudo ./perf probe -m /linux/samples/kprobes/kprobe_example.ko kprobe_init Added new event: probe:kprobe_init (on kprobe_init in kprobe_example) You can now use it in all perf tools, such as: perf record -e probe:kprobe_init -aR sleep 1 $ sudo cat /sys/kernel/debug/tracing/kprobe_events p:probe/kprobe_init kprobe_example:kprobe_init $ sudo ./perf record -a -e probe:kprobe_init [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.105 MB perf.data (2 samples) ] $ sudo ./perf script insmod 13990 [002] 5961.216833: probe:kprobe_init: ... insmod 13995 [002] 5962.889384: probe:kprobe_init: ... Signed-off-by: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com> Acked-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1461680741-12517-1-git-send-email-ravi.bangoria@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-event.c | 76 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 73 insertions(+), 3 deletions(-) commit 63a29613d7c69f17b6a3266bfc338986698b2546 Author: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com> Date: Tue Apr 26 19:55:41 2016 +0530 perf probe: Fix offline module name missmatch issue Perf can add a probe on kernel module which has not been loaded yet. The current implementation finds the module name from path. But if the filename is different from the actual module name then perf fails to register a probe while loading module because of mismatch in the names. For example, samples/kobject/kobject-example.ko is loaded as kobject_example. Before applying patch: $ sudo ./perf probe -m /linux/samples/kobject/kobject-example.ko foo_show Added new event: probe:foo_show (on foo_show in kobject-example) You can now use it in all perf tools, such as: perf record -e probe:foo_show -aR sleep 1 $ cat /sys/kernel/debug/tracing/kprobe_events p:probe/foo_show kobject-example:foo_show $ insmod kobject-example.ko $ lsmod Module Size Used by kobject_example 16384 0 Generate read to /sys/kernel/kobject_example/foo while recording data with below command $ sudo ./perf record -e probe:foo_show -a [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.093 MB perf.data ] $./perf report --stdio -F overhead,comm,dso,sym Error: The perf.data.old file has no samples! After applying patch: $ sudo ./perf probe -m /linux/samples/kobject/kobject-example.ko foo_show Added new event: probe:foo_show (on foo_show in kobject_example) You can now use it in all perf tools, such as: perf record -e probe:foo_show -aR sleep 1 $ sudo cat /sys/kernel/debug/tracing/kprobe_events p:probe/foo_show kobject_example:foo_show $ insmod kobject-example.ko $ lsmod Module Size Used by kobject_example 16384 0 Generate read to /sys/kernel/kobject_example/foo while recording data with below command $ sudo ./perf record -e probe:foo_show -a [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.097 MB perf.data (8 samples) ] $ sudo ./perf report --stdio -F overhead,comm,dso,sym ... # Samples: 8 of event 'probe:foo_show' # Event count (approx.): 8 # # Overhead Command Shared Object Symbol # ........ ....... ................. ............ # 100.00% cat [kobject_example] [k] foo_show Signed-off-by: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com> Acked-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1461680741-12517-2-git-send-email-ravi.bangoria@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-event.c | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) commit 073e5fca53d30ffe9e2fc637a001c78b2cdca7dd Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 12:33:46 2016 -0300 perf trace: Read thread's COMM from /proc when not set We get notifications for threads that gets created while we're tracing, but for preexisting threads we may end not having synthesized them, like when tracing a 'perf trace' session that will use '--pid' to trace some other thread. And besides we should probably stop synthesizing those records and instead read thread information in a lazy way, i.e. just when we need, like done in this patch: Now the 'pid_t' argument in 'perf_event_open' gets translated to a COMM: # perf trace -e perf_event_open perf stat -e cycles -p 31601 0.027 ( 0.027 ms): perf/23393 perf_event_open(attr_uptr: 0x2fdd0d8, pid: 31601 (abrt-dump-journ), cpu: -1, group_fd: -1, flags: FD_CLOEXEC) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = 3 ^C And in other syscalls containing pid_t without thread->comm_set at the time of the formatting. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Borislav Petkov <bp@suse.de> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ioeps6dlwst17d6oozc9shtk@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/trace/beauty/pid.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 2f3027ac28bf6bc3ac7eb851eab06f2a38af5caa Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 12:32:50 2016 -0300 perf thread: Introduce method to set comm from /proc/pid/self Will be used for lazy comm loading in 'perf trace'. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Borislav Petkov <bp@suse.de> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-7ogbkuoka1y2qsmcckqxvl5m@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread.c | 19 +++++++++++++++++++ tools/perf/util/thread.h | 2 ++ 2 files changed, 21 insertions(+) commit 4bd112df3eea4db63fe90fb4e83c48d3f3bd6512 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 12:31:16 2016 -0300 tools lib api fs: Add helper to read string from procfs file To read things like /proc/self/comm. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Borislav Petkov <bp@suse.de> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ztpkbmseidt0hq2psr46o0h9@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/lib/api/fs/fs.c | 13 +++++++++++++ tools/lib/api/fs/fs.h | 2 ++ 2 files changed, 15 insertions(+) commit ccd9b2a7f82b069b8e8ac892fd9c1c22e7b11eba Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 11:40:17 2016 -0300 perf trace: Do not beautify the 'pid' parameter as a simple integer Leave it alone so that it ends up assigned to SCA_PID via its type, 'pid_t', that will look up the pid on the machine thread rb_tree and possibly find its COMM. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-r7dujgmhtxxfajuunpt1bkuo@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 62de344e4fed23a42048c02dfa841f7d7ce9e88e Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 26 11:03:03 2016 -0300 perf trace: Move perf_flags beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-8r3gmymyn3r0ynt4yuzspp9g@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 45 +------------------------------ tools/perf/trace/beauty/perf_event_open.c | 43 +++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 44 deletions(-) commit 2a12ec13cc4ca8690ad2690c09bf8bff17c228d9 Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Tue Apr 26 18:04:13 2016 +0900 perf probe: Set default kprobe group name if it is not given Set kprobe group name as "probe" if it is not given. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160426090413.11891.95640.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-event.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit 6ed0720a74d90eea51284c07592369d45d56f1f7 Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue Apr 26 18:03:04 2016 +0900 perf probe: Let probe_file__add_event return 0 if succeeded Since other methods return 0 if succeeded (or filedesc), let probe_file__add_event() return 0 instead of the length of written bytes. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160426090303.11891.18232.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-file.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit e1ce726e1db2522b4848b3acffb7ece12439517c Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Tue Apr 26 18:02:42 2016 +0900 perf tools: Add lsdir() helper to read a directory As a utility function, add lsdir() which reads given directory and store entry name into a strlist. lsdir accepts a filter function so that user can filter out unneeded entries. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com> Cc: Hemant Kumar <hemant@linux.vnet.ibm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160426090242.11891.79014.stgit@devbox [ Do not use the 'dirname' it is used in some distros ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/util.c | 34 ++++++++++++++++++++++++++++++++++ tools/perf/util/util.h | 3 +++ 2 files changed, 37 insertions(+) commit 3023aa4ad8138066a69e25cf4d1b6880204e5e05 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:09 2016 +0200 ARM: dts: OMAP36xx: : DT spelling s/#address-cell/#address-cells/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap36xx.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ed53f623476f3f3b46340d75b415205c79c72681 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:08 2016 +0200 ARM: dts: omap5-cm-t54: DT spelling s/interrupt-name/interrupt-names/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-cm-t54.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e640bc306ab4bfd416668a1c0a59c1fd9937b678 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:07 2016 +0200 ARM: dts: omap5-board-common: DT spelling s/interrupt-name/interrupt-names/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5-board-common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9c9f261d6e3b1084816e9e2df794a55df16e7387 Merge: fab7b62 9854518 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 12:00:50 2016 -0400 Merge branch 'nla_align-set-4' Nicolas Dichtel says: ==================== netlink: align attributes when needed (patchset #3) This is the continuation (series #3) of the work done to align netlink attributes when these attributes contain some 64-bit fields. It's the last patchset from what I've seen. The last user of nla_put_u64() is block/drbd. This module does not use standard netlink API (see all the stuff in include/linux/genl_magic_struct.h and include/linux/genl_magic_func.h). I didn't modify it because it's seems hard to do it whithout testing and fully understanding the context (for example, why include/linux/drbd_genl.h is not part of uapi?). Any thoughts? ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 9854518ea04db33738602d45ebc96a200e6f5198 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:18 2016 +0200 sched: align nlattr properly when needed Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/gen_stats.txt | 6 ++++-- include/net/gen_stats.h | 6 ++++-- include/uapi/linux/gen_stats.h | 1 + include/uapi/linux/pkt_cls.h | 2 ++ include/uapi/linux/rtnetlink.h | 1 + include/uapi/linux/tc_act/tc_bpf.h | 1 + include/uapi/linux/tc_act/tc_connmark.h | 1 + include/uapi/linux/tc_act/tc_csum.h | 1 + include/uapi/linux/tc_act/tc_defact.h | 1 + include/uapi/linux/tc_act/tc_gact.h | 1 + include/uapi/linux/tc_act/tc_ife.h | 1 + include/uapi/linux/tc_act/tc_ipt.h | 1 + include/uapi/linux/tc_act/tc_mirred.h | 1 + include/uapi/linux/tc_act/tc_nat.h | 1 + include/uapi/linux/tc_act/tc_pedit.h | 1 + include/uapi/linux/tc_act/tc_skbedit.h | 1 + include/uapi/linux/tc_act/tc_vlan.h | 1 + net/core/gen_stats.c | 35 ++++++++++++++++++++------------- net/sched/act_api.c | 7 +++++-- net/sched/act_bpf.c | 3 ++- net/sched/act_connmark.c | 3 ++- net/sched/act_csum.c | 2 +- net/sched/act_gact.c | 2 +- net/sched/act_ife.c | 2 +- net/sched/act_ipt.c | 2 +- net/sched/act_mirred.c | 2 +- net/sched/act_nat.c | 2 +- net/sched/act_pedit.c | 2 +- net/sched/act_simple.c | 2 +- net/sched/act_skbedit.c | 2 +- net/sched/act_vlan.c | 2 +- net/sched/cls_u32.c | 7 ++++--- net/sched/sch_api.c | 6 ++++-- 33 files changed, 72 insertions(+), 37 deletions(-) commit b676338fb3aab0b63b4a2489feb8f35003db22e8 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:17 2016 +0200 neigh: align nlattr properly when needed Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/neighbour.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 270cb4d05b2923a4a4d712276e61f64c82567138 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:16 2016 +0200 rtnl: align nlattr properly when needed Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/rtnetlink.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 66c7a5ee1a6b7c69d41dfd68d207fdd54efba56a Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:15 2016 +0200 ovs: align nlattr properly when needed I also fix commit 8b32ab9e6ef1: use nla_total_size_64bit() for OVS_FLOW_ATTR_USED in ovs_flow_cmd_msg_size(). Fixes: 8b32ab9e6ef1 ("ovs: use nla_put_u64_64bit()") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/openvswitch.h | 2 ++ net/openvswitch/datapath.c | 27 +++++++++++++++------------ 2 files changed, 17 insertions(+), 12 deletions(-) commit 6ed46d1247a595c58b6c04481fa77cf532f45de0 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:14 2016 +0200 sock_diag: align nlattr properly when needed I also fix the value of INET_DIAG_MAX. It's wrong since commit 8f840e47f190 which is only in net-next right now, thus I didn't make a separate patch. Fixes: 8f840e47f190 ("sctp: add the sctp_diag.c file") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/inet_diag.h | 4 +++- net/core/sock_diag.c | 2 +- net/ipv4/inet_diag.c | 9 ++++++--- net/sctp/sctp_diag.c | 5 +++-- 4 files changed, 13 insertions(+), 7 deletions(-) commit 3c6f3714d6a9e051eb84759e4fa5a2f4a3e730c6 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:13 2016 +0200 fs/quota: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Acked-by: Jan Kara <jack@suse.cz> Signed-off-by: David S. Miller <davem@davemloft.net> fs/quota/netlink.c | 12 +++++++----- include/uapi/linux/quota.h | 1 + 2 files changed, 8 insertions(+), 5 deletions(-) commit 08f4cbb8f207e2b8f40e8acc2a4e3a7df642b095 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:12 2016 +0200 drivers/wireless: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/wireless/mac80211_hwsim.c | 2 +- drivers/net/wireless/mac80211_hwsim.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) commit f60d94c009685da0632d93297cae971c5898a04b Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Tue Apr 26 10:06:11 2016 +0200 macsec: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macsec.c | 121 ++++++++++++++++++++++++++++++----------- include/uapi/linux/if_link.h | 1 + include/uapi/linux/if_macsec.h | 6 ++ 3 files changed, 95 insertions(+), 33 deletions(-) commit 989ff7754a27a1fcc0c3b2794c985b31811871a0 Author: Jim Lodes <jim.lodes@garmin.com> Date: Mon Apr 25 11:10:07 2016 -0500 ASoC: omap-pcm: Initialize DMA configuration Initialize the dma_slave_config for PCM DMA transfers, instead of leaving it uninitialized. Keeps previous data on the stack from giving us invalid values in uninitialized members of the config structure. Signed-off-by: Jim Lodes <jim.lodes@garmin.com> Signed-off-by: J.D. Schroeder <jay.schroeder@garmin.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Reviewed-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/omap/omap-pcm.c | 2 ++ 1 file changed, 2 insertions(+) commit b8c1eca1e089e8f4247b19b73955c875bf7b18ae Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Fri Feb 19 15:19:43 2016 +0300 arc: axs10x - add support of ARC PGU Synopsys DesignWare ARC SDP boards sport ARC SDP display controller attached to ADV7511 HDMI encoder. That change adds desctiption of both ARC PGU and ADV7511 in ARC SDP'd base-board Device Tree. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: devicetree@vger.kernel.org Cc: linux-snps-arc@lists.infradead.org arch/arc/boot/dts/axs10x_mb.dtsi | 61 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) commit 71d298ceff37620af92ed98230cf5058d5fb6a2f Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Fri Feb 19 15:34:30 2016 +0300 MAINTAINERS: Add maintainer for ARC PGU display controller This updates MAINTEINERS file with information about maintainer of ARC PGU display controller driver. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: linux-snps-arc@lists.infradead.org MAINTAINERS | 6 ++++++ 1 file changed, 6 insertions(+) commit a1f8ebe5cf8421460ea5bdb6a9cc53ab50a35b50 Author: Alexey Brodkin <abrodkin@synopsys.com> Date: Fri Feb 19 15:35:52 2016 +0300 drm: Add DT bindings documentation for ARC PGU display controller This add DT bindings documentation for ARC PGU display controller. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: devicetree@vger.kernel.org Cc: linux-snps-arc@lists.infradead.org Acked-by: Rob Herring <robh@kernel.org> .../devicetree/bindings/display/snps,arcpgu.txt | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 51dacf208988e5a2561d9b4b560cacc8a7f025e7 Author: Carlos Palminha <palminha@synopsys.com> Date: Fri Feb 19 15:30:26 2016 +0300 drm: Add support of ARC PGU display controller ARC PGU could be found on some development boards from Synopsys. This is a simple byte streamer that reads data from a framebuffer and sends data to the single encoder. Signed-off-by: Carlos Palminha <palminha@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: David Airlie <airlied@linux.ie> Cc: dri-devel@lists.freedesktop.org Cc: linux-snps-arc@lists.infradead.org drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/Makefile | 1 + drivers/gpu/drm/arc/Kconfig | 10 ++ drivers/gpu/drm/arc/Makefile | 2 + drivers/gpu/drm/arc/arcpgu.h | 50 +++++++ drivers/gpu/drm/arc/arcpgu_crtc.c | 257 ++++++++++++++++++++++++++++++++++ drivers/gpu/drm/arc/arcpgu_drv.c | 282 ++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/arc/arcpgu_hdmi.c | 201 +++++++++++++++++++++++++++ drivers/gpu/drm/arc/arcpgu_regs.h | 40 ++++++ 9 files changed, 845 insertions(+) commit b31356dfde571d925768783f1bb63ca8e156d0b3 Author: Wang Sheng-Hui <shhuiw@foxmail.com> Date: Wed Apr 20 10:04:32 2016 +0800 NVMe: small typo in section BLK_DEV_NVME_SCSI of host/Kconfig "as well as " is miss typed "as well a " in section "config BLK_DEV_NVME_SCSI" Signed-off-by: Wang Sheng-Hui <shhuiw@foxmail.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 76e3914ae51714b0535c38d9472d89124e0b6b96 Author: Christoph Hellwig <hch@lst.de> Date: Sat Apr 16 14:57:58 2016 -0400 nvme: fix cntlid type Controller IDs in NVMe are unsigned 16-bit types. In the Fabrics driver we actually pass ctrl->id by reference, so we need it to have the correct type. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/nvme.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3d90bc051361c6f867df494d838d4fe1215d475a Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: STih407: Switch LPC mode from RTC to Clocksource This aligns with the internal configuration. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe135c636a5e3c2eb2856366ad3e54849bf06e64 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STiH407: Move over to using the 'reserved-memory' API for obtaining DMA memory Doing so saves quite a bit of code in the driver. For more information on the 'reserved-memory' bindings see: Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt Suggested-by: Suman Anna <s-anna@ti.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 47 +++++++++++++++++++++++++++++------ 1 file changed, 39 insertions(+), 8 deletions(-) commit 3ff0a019d7f2e3c600d5aab935a059454060fe4c Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STiH407: Add nodes for RemoteProc Signed-off-by: Ludovic Barre <ludovic.barre@st.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 40 +++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 6e966f13dc7b01e0134e6c8d72e23625b7be8b94 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: stih407-family: Add nodes for Mailbox This patch supplies the Mailbox Controller nodes. In order to request channels, these nodes will be referenced by Mailbox Client nodes. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 5609263014c452f4c5f5a470b13e226f2fb0e578 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: STiH407: Provide CPU with a means to look-up Major number This is used for CPU Frequency Scaling. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 1 + 1 file changed, 1 insertion(+) commit fe7de3c3c6f3cbd715e8bcf6fbcb6dc01f2a7aad Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: STiH407: Link CPU with its voltage supply Used for Voltage Scaling using CPUFreq. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 1 + 1 file changed, 1 insertion(+) commit 4ad8f3ac12dc7a1420d7b995c007255c73740113 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: STiH407: Provide CPU with clocking information Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit 5169192bc1d51cac1ccd57757a849657fb3bdf93 Author: Benjamin Poirier <bpoirier@suse.com> Date: Sun Apr 10 17:06:32 2016 -0700 localmodconfig: Add missing $ to reference a variable That is clearly what the original intention was. This does not change the output .config but it prevents some useless processing. ! eq "m" is changed to the simpler eq "y"; symbols with values other than m|y are not included in %orig_configs. Link: http://lkml.kernel.org/r/1460333193-16361-3-git-send-email-bpoirier@suse.com Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6fef79536505be6bf3b0b4ebac70a20f24cffebb Author: Lee Jones <lee.jones@linaro.org> Date: Thu Apr 21 17:07:00 2016 +0200 ARM: dts: STi: STiH407: Provide generic (safe) DVFS configuration You'll notice that the voltage cell is populated with 0's. Voltage information is very platform specific, even depends on 'cut' and 'substrate' versions. Thus it is left blank for a generic (safe) implementation. If other nodes/properties are provided by the bootloader, the ST CPUFreq driver will over-ride these generic values. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/boot/dts/stih407-family.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit a77ed525d0120e244937eaa74c6086da1dab283a Author: Benjamin Poirier <bpoirier@suse.com> Date: Sun Apr 10 17:06:31 2016 -0700 localmodconfig: Fix parsing of "help" text Help text may start with "help" or "---help---". This patch fixes read_kconfig() to recognize the second variant. This removes useless junk from %depends and %selects. That junk is due to help text that contains the words "selects" and "depends". Link: http://lkml.kernel.org/r/1460333193-16361-2-git-send-email-bpoirier@suse.com Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 27b7156886d875f2f54fab8790144e1fa80b7160 Author: Benjamin Poirier <bpoirier@suse.com> Date: Sun Apr 10 17:06:30 2016 -0700 localmodconfig: Recognize more keywords that end a menu entry Based on the list in Documentation/kbuild/kconfig-language.txt This removes junk from %depends because parsing of a menu entry spilled over to another menu entry. Link: http://lkml.kernel.org/r/1460333193-16361-1-git-send-email-bpoirier@suse.com Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 296471ad51780996d3b1f2dfb65bc4dbdea69a1e Author: Benjamin Poirier <bpoirier@suse.com> Date: Sat Apr 2 10:55:21 2016 -0700 localmodconfig: Fix parsing of Kconfig "source" statements The parameter of Kconfig "source" statements does not need to be quoted. The current regex causes many kconfig files to be skipped and hence, dependencies to be missed. Also fix the whitespace repeat count. Link: http://lkml.kernel.org/r/1459619722-13695-1-git-send-email-bpoirier@suse.com Tested-by: Lee, Chun-Yi <jlee@suse.com> Signed-off-by: Benjamin Poirier <bpoirier@suse.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> scripts/kconfig/streamline_config.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0c0451e7634564052a045d4398a91ea4ef1f755b Author: Grygorii Strashko <grygorii.strashko@ti.com> Date: Tue Apr 12 13:52:31 2016 +0300 gpio: omap: fix irq triggering in smart-idle wakeup mode Now GPIO IRQ loss is observed on dra7-evm after suspend/resume cycle in the following case: extcon_usb1(id_irq) -> pcf8575.gpio1 -> omapgpio6.gpio11 -> gic the extcon_usb1 is wake up source and it enables IRQ wake up for id_irq by calling enable/disable_irq_wake() during suspend/resume which, in turn, causes execution of omap_gpio_wake_enable(). And omap_gpio_wake_enable() will set/clear corresponding bit in GPIO_IRQWAKEN_x register. omapgpio6 configuration after boot - wakeup is enabled for GPIO IRQs by default from omap_gpio_irq_type: GPIO_IRQSTATUS_SET_0 | 0x00000400 GPIO_IRQSTATUS_CLR_0 | 0x00000400 GPIO_IRQWAKEN_0 | 0x00000400 GPIO_RISINGDETECT | 0x00000000 GPIO_FALLINGDETECT | 0x00000400 omapgpio6 configuration after after suspend/resume cycle: GPIO_IRQSTATUS_SET_0 | 0x00000400 GPIO_IRQSTATUS_CLR_0 | 0x00000400 GPIO_IRQWAKEN_0 | 0x00000000 <--- GPIO_RISINGDETECT | 0x00000000 GPIO_FALLINGDETECT | 0x00000400 As result, system will start to lose interrupts from pcf8575 GPIO expander, because when OMAP GPIO IP is in smart-idle wakeup mode, there is no guarantee that transition(s) on input non wake up GPIO pin will trigger asynchronous wake-up request to PRCM and then IRQ generation. IRQ will be generated when GPIO is in active mode - for example, some time after accessing GPIO bank registers IRQs will be generated normally, but issue will happen again once PRCM will put GPIO in low power smart-idle wakeup mode. Note 1. Issue is not reproduced if debounce clk is enabled for GPIO bank. Note 2. Issue hardly reproducible if GPIO pins group contains both wakeup/non-wakeup gpios - for example, it will be hard to reproduce issue with pin2 if GPIO_IRQWAKEN_0=0x1 GPIO_IRQSTATUS_SET_0=0x3 GPIO_FALLINGDETECT = 0x3 (TRM "Power Saving by Grouping the Edge/Level Detection"). Note 3. There nothing common bitween System wake up and OMAP GPIO bank IP wake up logic - the last one defines how the GPIO bank ON-IDLE-ON transition will happen inside SoC under control of PRCM. Hence, fix the problem by removing omap_set_gpio_wakeup() function completely and so keeping always in sync GPIO IRQ mask/unmask (IRQSTATUS_SET) and wake up enable (GPIO_IRQWAKEN) bits; and adding IRQCHIP_MASK_ON_SUSPEND flag in OMAP GPIO irqchip. That way non wakeup GPIO IRQs will be properly masked/unmask by IRQ PM core during suspend/resume cycle. Cc: Roger Quadros <rogerq@ti.com> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-omap.c | 42 ++---------------------------------------- 1 file changed, 2 insertions(+), 40 deletions(-) commit 062d6c2aec0e087be956494a73221c04eca115fe Author: Masami Hiramatsu <mhiramat@kernel.org> Date: Tue Apr 26 15:47:37 2016 +0900 perf probe: Close target file on error path Fix a bug to close target elf file in get_text_start_address(). Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20160426064737.1443.44093.stgit@devbox Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/probe-event.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit b04b7023751bf6519eee64467b6477f0e7fb82a1 Author: Wang Nan <wangnan0@huawei.com> Date: Tue Apr 26 02:28:54 2016 +0000 perf evlist: Enforce ring buffer reading Don't read broken data after 'head' pointer. Following commits will feed perf_evlist__mmap_read() with some 'head' pointers not maintained by kernel. If 'head' pointer breaks an event, we should avoid reading from the broken event. This can happen in backward ring buffer. For example: old head | | V V +---+------+----------+----+-----+--+ |..E|D....D|C........C|B..B|A....|E.| +---+------+----------+----+-----+--+ 'old' pointer points to the beginning of 'A' and trying read from it, but 'A' has been overwritten. In this case, don't try to read from 'A', simply return NULL. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1461637738-62722-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 153847586b0aaa9482e42bc7e95b24adb87a1859 Author: Chris Metcalf <cmetcalf@mellanox.com> Date: Tue Apr 26 09:54:56 2016 -0400 tile: clarify barrier semantics of atomic_add_return A recent discussion on LKML made it clear that the one-line comment previously in atomic_add_return() was not clear enough: https://lkml.kernel.org/r/571E87E2.3010306@mellanox.com Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/include/asm/atomic_64.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) commit 71324fdc72ef0163e57631aa814a9a81e9e4770b Author: Andrew Jeffery <andrew@aj.id.au> Date: Wed Apr 20 11:24:17 2016 +0930 pinctrl: exynos5440: Use off-stack memory for pinctrl_gpio_range The range is registered into a linked list which can be referenced throughout the lifetime of the driver. Ensure the range's memory is useful for the same lifetime by adding it to the driver's private data structure. The bug was introduced in the driver's initial commit, which was present in v3.10. Fixes: f0b9a7e521fa ("pinctrl: exynos5440: add pinctrl driver for Samsung EXYNOS5440 SoC") Cc: stable@vger.kernel.org Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Acked-by: Tomasz Figa <tomasz.figa@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/samsung/pinctrl-exynos5440.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 85f5251792abcd6dae897df8eb4ca0e890bc5882 Author: Borislav Petkov <bp@suse.de> Date: Wed Mar 30 13:42:48 2016 +0200 tile/defconfigs: Remove CONFIG_IPV6_PRIVACY Option is long gone, see 5d9efa7ee99e ("ipv6: Remove privacy config option.") Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Chris Metcalf <cmetcalf@ezchip.com> Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com> arch/tile/configs/tilegx_defconfig | 1 - arch/tile/configs/tilepro_defconfig | 1 - 2 files changed, 2 deletions(-) commit 6e4cf657defa8fb06dbf9ed91adb78414758f259 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Mon Apr 25 14:01:28 2016 -0500 tracing: Handle tracing_map_alloc_elts() error path correctly If tracing_map_elt_alloc() fails, it will return ERR_PTR() instead of NULL, so change the check to IS_ERROR(). We also need to set the failed entry in the map->elts array to NULL instead of ERR_PTR() so tracing_map_free_elts() doesn't try freeing an ERR_PTR(). tracing_map_free_elts() should also zero out what it frees so a reentrant call won't find previously freed elements. Link: http://lkml.kernel.org/r/f29d03b00bce3aac8cf151a8a30e6c83e5fee66d.1461610073.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/tracing_map.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 432480c58219eff32904b879eb3fcc1d268a3b06 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Mon Apr 25 14:01:27 2016 -0500 tracing: Add check for NULL event field when creating hist field Smatch flagged create_hist_field() as possibly being able to dereference a NULL pointer, although the current code exits in all cases where the event field could be NULL, so it's not actually a problem. Still, to prevent future changes to the code from overlooking new cases, make the NULL pointer check explicit and warn once in that case. Link: http://lkml.kernel.org/r/cfbc003f534a3e441b4313272fd412310aba6336.1461610073.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events_hist.c | 3 +++ 1 file changed, 3 insertions(+) commit 4812952f9c94f67b3cc78ad0a6482bf182aa5a44 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Sat Apr 23 13:23:47 2016 +0300 tracing: checking for NULL instead of IS_ERR() tracing_map_elt_alloc() returns ERR_PTRs on error, never NULL. Fixes: 08d43a5fa063 ('tracing: Add lock-free tracing_map') Link: http://lkml.kernel.org/r/20160423102347.GA11136@mwanda Acked-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/tracing_map.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6a1f5471144754f165427a93f35c897f85680594 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Tue Apr 12 16:09:11 2016 +0200 arm64: acpi: add acpi=on cmdline option to prefer ACPI boot over DT If both ACPI and DT platform descriptions are available, and the kernel was configured at build time to support both flavours, the default policy is to prefer DT over ACPI, and preferring ACPI over DT while still allowing DT as a fallback is not possible. Since some enterprise features (such as RAS) depend on ACPI, it may be desirable for, e.g., distro installers to prefer ACPI boot but fall back to DT rather than failing completely if no ACPI tables are available. So introduce the 'acpi=on' kernel command line parameter for arm64, which signifies that ACPI should be used if available, and DT should only be used as a fallback. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/kernel-parameters.txt | 6 ++++-- arch/arm64/kernel/acpi.c | 8 ++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) commit f7cb5120c4e0de10c3e069f5318417da0326fb45 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:48:29 2015 +0100 ASoC: ac97: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/soc-ac97.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit c2aea142af6179d757424a21110da3fc90127e02 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:44:39 2015 +0100 ASoC: wm8996: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/codecs/wm8996.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit f42b6f5800b6d06442c193d4beb423b0186e7b6a Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:41:55 2015 +0100 ASoC: wm8962: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/codecs/wm8962.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 8f4160661fd251e651f24f61b7ba4c36898e2621 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:38:20 2015 +0100 ASoC: wm8903: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/codecs/wm8903.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit db1d127053c4c525086673e39691d274668a458d Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:31:28 2015 +0100 ASoC: wm5100: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/codecs/wm5100.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit 14900363454b8244b41f77f42013a22db20bb2e2 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:27:09 2015 +0100 ASoC: rt5677: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Bard Liao <bardliao@realtek.com> Cc: Oder Chiou <oder_chiou@realtek.com> Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: alsa-devel@alsa-project.org Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> sound/soc/codecs/rt5677.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit dee07cea5452a5d50c6273f7a0d3c1aaa7ce9508 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:15:53 2015 +0100 serial: sc16is7xx: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Jiri Slaby <jslaby@suse.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/tty/serial/sc16is7xx.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) commit a00d60a0a2896bced073810fc86ea0764ac54939 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:11:05 2015 +0100 serial: max310x: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Jiri Slaby <jslaby@suse.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/tty/serial/max310x.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit cbc3f10f9ead9c9f664a9dc6697c31312e36d50e Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:06:50 2015 +0100 staging: vme: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Manohar Vanga <manohar.vanga@gmail.com> Cc: devel@driverdev.osuosl.org Acked-by: Martyn Welch <martyn@welchs.me.uk> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/staging/vme/devices/vme_pio2_gpio.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit 2d4443be10a70100cfdc1abcf1475a86bc62534b Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 23:00:46 2015 +0100 ssb: gpio_driver: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Hauke Mehrtens <hauke@hauke-m.de> Cc: Michael Buesch <m@bues.ch> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/ssb/driver_gpio.c | 33 ++++++++++++++------------------- 1 file changed, 14 insertions(+), 19 deletions(-) commit 3769a895b4a61b66085f97f8124df4833ee6e577 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 22:54:20 2015 +0100 platform: x86: intel-pmic: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Feng Tang <feng.tang@intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/platform/x86/intel_pmic_gpio.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d3baee37f1488b0dea726597bb12a0086b233f8b Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 16:29:50 2015 +0100 input: adp5588-keys: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Michael Hennerich <michael.hennerich@analog.com> Acked-by: Michael Hennerich <michael.hennerich@analog.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/input/keyboard/adp5588-keys.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 1f664ab7d9d46abdcde294e3e6e9d5d98a2e6f73 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:39 2016 +0200 MAINTAINERS: update entry for Marvell ARM platform maintainers The Marvell platform support is no longer limited to Armada 370, 375, 38x and XP, but now also includes the 32-bits Armada 39x and the 64-bits Armada 3700 and 7K/8K. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ad87c0f6692ecfe975b9c4f53bde9b24aa0b5173 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:29 2016 +0200 arm64: marvell: enable AP806 and CP110 syscon driver The Marvell Armada 7K/8K support needs the AP806 and CP110 syscon drivers to be enabled, as they provide amongst other things, the main clocks for those platforms. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/Kconfig.platforms | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fea144987932dbc88b3051c6d258ffdcace7f1fa Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:37 2016 +0200 arm64: dts: marvell: enable several CP interfaces on Armada 7040-DB This commit enables several interfaces of the CP side of the Armada 7040 for the Armada 7040 DB board: - one PCIe interface - one SPI controller with an attached SPI flash - one I2C controller - one SATA controller - two USB3 controllers Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-7040-db.dts | 50 ++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) commit 728dacc7f4dd5d99b2a7e127b969165f54b6eece Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:36 2016 +0200 arm64: dts: marvell: initial DT description of Armada 7K/8K CP110 master This commit adds an initial Device Tree description for the CP110 master that is found in the Armada 7K and 8K SoCs. This initial description describes: - the system controller (to provide clocks) - three PCIe interfaces - the SATA interface - the I2C controllers - the SPI controllers For the record, the organization of the SoCs is as follows: - 7020: dual-core AP, one CP110 (master) - 7040: quad-core AP, one CP110 (master) - 8020: dual-core AP, two CP110s (master and slave) - 8040: quad-core AP, two CP110s (master and slave) For this reason, all of the 7020, 7040, 8020 and 8040 include armada-cp110-master.dtsi. When support for the second CP110 (slave) used in 8020 and 8040 will be added, the .dtsi files for those SoCs will in addition include armada-cp110-slave.dtsi. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-7020.dtsi | 1 + arch/arm64/boot/dts/marvell/armada-7040.dtsi | 1 + arch/arm64/boot/dts/marvell/armada-8020.dtsi | 1 + arch/arm64/boot/dts/marvell/armada-8040.dtsi | 1 + .../boot/dts/marvell/armada-cp110-master.dtsi | 228 +++++++++++++++++++++ 5 files changed, 232 insertions(+) commit d8b330a3e3135ed4cbc23c672deb7c978a686375 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:35 2016 +0200 arm64: dts: marvell: use the proper I2C controller compatible string for 7K/8K The I2C controller found in the Marvell Armada 7K/8K provides the bridge/offloading features, so the Device Tree should use the marvell,mv78230-i2c compatible string instead of marvell,mv64xxx-i2c. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-ap806.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe85e20e970041e9540820964926dc01a0a0f7f2 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:34 2016 +0200 arm64: dts: marvell: improve SPI flash description on Armada 7040-DB This commit slightly improves the description of the SPI flash connected to the SPI controller of the Armada 7040, by: - Using the more generic "jedec,spi-nor" compatible string, which lets the driver auto-detect the exact SPI flash type. - Removing the silly comment about the Chip Select, since reg = <0> is explicit enough. - Switching to the new Device Tree binding to describe flash partitions. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-7040-db.dts | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) commit bb233a9319ea1999d637a9c7e6c3c4a578a1fc94 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:33 2016 +0200 arm64: dts: marvell: use new clock binding on Armada AP806 This commit updates the Marvell AP806 Device Tree description to make use of the accepted clock Device Tree binding. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-ap806.dtsi | 34 ++++++++++----------------- 1 file changed, 12 insertions(+), 22 deletions(-) commit bf151162162b21e27fd9e94776aac67f648c0c4c Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Apr 26 09:58:32 2016 +0200 arm64: dts: marvell: add UART aliases and define stdout-path This commit adds the necessary UART aliases to the main Armada 7K/8K .dtsi file, and uses them to define the /chosen/stdout-path property on the Armada 7040 DB board. Suggested-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-7040-db.dts | 4 ++++ arch/arm64/boot/dts/marvell/armada-ap806.dtsi | 5 +++++ 2 files changed, 9 insertions(+) commit 1093e5f6fc398eaab21bb9182806854fbde4edc9 Author: Andreas Färber <afaerber@suse.de> Date: Tue Apr 26 09:58:31 2016 +0200 arm64: dts: marvell: rename armada-ap806 XOR nodes Node names should not contain an instance number, the unit address serves to distinguish nodes of the same name. So rename the XOR nodes to just xor@<address>. Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Andreas Färber <afaerber@suse.de> [Thomas: - remove labels, they are really not needed for XOR engines. - remove the Fixes: tag, as this is not a fix.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-ap806.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 037ad463ba408d76d85f377d258d135062bab658 Author: Andreas Färber <afaerber@suse.de> Date: Tue Apr 26 09:58:30 2016 +0200 arm64: dts: marvell: clean up armada-7040-db Instead of duplicating the node hierarchy, reference the nodes by label, adding labels where necessary. Drop some trailing or inconsistent white lines while at it. Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Andreas Färber <afaerber@suse.de> [Thomas: drop Fixes tag as it is not a bug fix.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm64/boot/dts/marvell/armada-7040-db.dts | 52 ++++++++++------------ arch/arm64/boot/dts/marvell/armada-ap806-dual.dtsi | 1 - arch/arm64/boot/dts/marvell/armada-ap806-quad.dtsi | 2 - arch/arm64/boot/dts/marvell/armada-ap806.dtsi | 7 +-- 4 files changed, 26 insertions(+), 36 deletions(-) commit 59851aa87c2ca92a1fd6b73e78a254242306b116 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 10:45:14 2016 +0200 arc: select GPIOLIB directly Instead of indirectly selecting GPIOLIB via the ARCH_REQUIRE_GPIOLIB symbol, just select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: linux-snps-arc@lists.infradead.org Acked-by: Vineet Gupta <vgupt@synopsys.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arc/plat-axs10x/Kconfig | 2 +- arch/arc/plat-tb10x/Kconfig | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 30d473d4db623a84b3e8d708d332934ed2537fd8 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 13:34:34 2016 +0200 sparc: remove ARCH_WANT_OPTIONAL_GPIOLIB This symbols is not needed to get access to selecting the GPIOLIB anymore: any arch can select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: sparclinux@vger.kernel.org Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/sparc/Kconfig | 1 - 1 file changed, 1 deletion(-) commit f518abf00d503dc2cc330d189229fed926c424d8 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 11:13:38 2016 +0200 cris: do away with ARCH_REQUIRE_GPIOLIB Replace "select ARCH_REQUIRE_GPIOLIB" with "select GPIOLIB" as this can now be selected directly. Cc: Michael Büsch <m@bues.ch> Cc: Mikael Starvik <starvik@axis.com> Cc: linux-cris-kernel@axis.com Acked-by: Jesper Nilsson <jesper.nilsson@axis.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/cris/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2735e4c305be13b38680c5e2ddce131da2755ad5 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 13:33:48 2016 +0200 nios2: remove ARCH_WANT_OPTIONAL_GPIOLIB This symbols is not needed to get access to selecting the GPIOLIB anymore: any arch can select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: nios2-dev@lists.rocketboards.org Acked-by: Ley Foon Tan <lftan@altera.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/nios2/Kconfig | 1 - 1 file changed, 1 deletion(-) commit e05f2e187814b7b102c0f54c9a72c01e6bdb5360 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 11:17:49 2016 +0200 m68k: do away with ARCH_REQUIRE_GPIOLIB Replace "select ARCH_REQUIRE_GPIOLIB" with "select GPIOLIB" as this can now be selected directly. Cc: Michael Büsch <m@bues.ch> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: linux-m68k@lists.linux-m68k.org Acked-by: Greg Ungerer <gerg@linux-m68k.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/m68k/Kconfig.cpu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e944b10ab03568e821145e38198197da2913af54 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 13:35:14 2016 +0200 xtensa: remove ARCH_WANT_OPTIONAL_GPIOLIB This symbols is not needed to get access to selecting the GPIOLIB anymore: any arch can select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: Chris Zankel <chris@zankel.net> Cc: linux-xtensa@linux-xtensa.org Acked-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/xtensa/Kconfig | 1 - 1 file changed, 1 deletion(-) commit 92cd663e4cd02c10f321ec2cf3c417b29fe8b387 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 13:30:21 2016 +0200 alpha: remove ARCH_WANT_OPTIONAL_GPIOLIB This symbols is not needed to get access to selecting the GPIOLIB anymore: any arch can select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: Richard Henderson <rth@twiddle.net> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: linux-alpha@vger.kernel.org Acked-by: Matt Turner <mattst88@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/alpha/Kconfig | 1 - 1 file changed, 1 deletion(-) commit 349214c1e7d718684e19dc3559dffe4e62f55296 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Apr 26 14:41:41 2016 +0300 wil6210: prevent deep sleep of 60G device in critical paths In idle times 60G device can enter deep sleep and turn off its XTAL clock. Host access triggers the device power-up flow which will hold the AHB during XTAL stabilization until device switches from slow-clock to XTAL clock. This behavior can stall the PCIe bus for some arbitrary period of time. In order to prevent this stall, host can vote for High Latency Access Policy (HALP) before reading from PCIe bus. This vote will wakeup the device from deep sleep and prevent deep sleep until unvote is done. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/debugfs.c | 22 +++++--- drivers/net/wireless/ath/wil6210/interrupt.c | 80 ++++++++++++++++++++++------ drivers/net/wireless/ath/wil6210/main.c | 75 ++++++++++++++++++++++++-- drivers/net/wireless/ath/wil6210/wil6210.h | 29 +++++++++- drivers/net/wireless/ath/wil6210/wmi.c | 20 +++++-- 5 files changed, 194 insertions(+), 32 deletions(-) commit 54eaa8c69e72dca4c824cd390b616cb48b2c4e30 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Apr 26 14:41:40 2016 +0300 wil6210: unmask RX_HTRSH interrupt only when connected RX_HTRSH interrupt sometimes triggered during device reset procedure. To prevent handling this interrupt when not required, unmask this interrupt only if we are connected and mask it when disconnected. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/interrupt.c | 6 +++++- drivers/net/wireless/ath/wil6210/main.c | 17 +++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) commit d8ed043accdee611bce8be7c4224b4e26bdc2ab5 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Apr 26 14:41:39 2016 +0300 wil6210: print debug message when transmitting while disconnected Network stack can try to transmit data while AP / STA is disconnected. Change this print-out to debug level as this should not be handled as error. This patch also adds wil_dbg_ratelimited, used to limit the above print-out. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/debug.c | 16 ++++++++++++++++ drivers/net/wireless/ath/wil6210/txrx.c | 2 +- drivers/net/wireless/ath/wil6210/wil6210.h | 2 ++ 3 files changed, 19 insertions(+), 1 deletion(-) commit b523d35b5bffda70bf149cb6ae87c7eb1013dcdd Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Apr 26 14:41:39 2016 +0300 wil6210: change RX_HTRSH interrupt print level to debug When using interrupt moderation RX_HTRSH interrupt can occur frequently during high throughput and should not be considered as error. Such print-outs can degrade the performance hence should be printed in debug print level. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/interrupt.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 321a000bfadd5535089a198b42d714a8bf8469b7 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Apr 26 14:41:38 2016 +0300 wil6210: support regular scan on P2P_DEVICE interface P2P search can only run on the social channel (channel 2). When issuing a scan request on the P2P_DEVICE interface, driver ignored the channels argument and always performed a P2P search. Fix this by checking the channels argument, if it is not specified (meaning full scan) or if a non-social channel was specified, perform a regular scan and not a P2P search. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 5 +++-- drivers/net/wireless/ath/wil6210/p2p.c | 6 ++++++ drivers/net/wireless/ath/wil6210/wil6210.h | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) commit 290206fa7e04ea4c1620aea2624e4d998bc27a0a Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Apr 26 14:41:38 2016 +0300 wil6210: add function name to wil log macros Add __func__ to wil_err and wil_info for easier debugging. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/debug.c | 6 +++--- drivers/net/wireless/ath/wil6210/wil6210.h | 10 +++++++--- 2 files changed, 10 insertions(+), 6 deletions(-) commit f8a68c9668a63249d0105444101a99d9eccd7cc2 Author: Steve deRosier <derosier@gmail.com> Date: Tue Apr 26 14:41:37 2016 +0300 ath6kl: add ability to set debug uart baud rate It's useful to permit the customization of the debug uart baud rate. Enable this and send down the value to the chip if we're enabling debug. Signed-off-by: Steve deRosier <steve.derosier@lairdtech.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath6kl/core.c | 3 +++ drivers/net/wireless/ath/ath6kl/core.h | 1 + drivers/net/wireless/ath/ath6kl/init.c | 8 ++++++++ 3 files changed, 12 insertions(+) commit 907ec43a486df72891e79e1f47a718ee17e36ee2 Author: Steve deRosier <derosier@gmail.com> Date: Tue Apr 26 14:41:37 2016 +0300 ath6kl: fix missing uart debug pin for 6004 HW 3.0 For some reason, the 6004 HW 3.0 definition was missing the value for the uarttx_pin (used for firmware debug). This corrects this situation. Signed-off-by: Steve deRosier <steve.derosier@lairdtech.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath6kl/init.c | 1 + 1 file changed, 1 insertion(+) commit 6dfdbfc78a2fb1a59680e9a1ee2f462cc768f386 Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Tue Apr 26 14:41:36 2016 +0300 ath10k: fix a typo in ath10k_start() fix a typo (spelling mistake) in 'ath10k_start' Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 416196cd90999c29b04ca04cfbd713c73784a4ef Author: Joshua Clayton <stillcompiling@gmail.com> Date: Mon Apr 25 18:09:33 2016 -0700 ARM: dts: imx6: fix dtc warnings for ipu endpoints When compiled with "W=1", dtc complains: e.g. "Warning (unit_address_vs_reg): Node /soc/ipu@02800000/port@2/endpoint@0 has a unit name, but no reg property" Endpoint nodes don't have a reg property, and the addresses in their node names are ordinals without any special meaning so remove them and swap them for semantic node names. Signed-off-by: Joshua Clayton <stillcompiling@gmail.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q.dtsi | 18 +++++++++--------- arch/arm/boot/dts/imx6qdl.dtsi | 20 ++++++++++---------- 2 files changed, 19 insertions(+), 19 deletions(-) commit 46350b71a09ccf3573649e03db55d4b61d5da231 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Apr 25 17:37:17 2016 -0300 ARM: dts: imx6dl: Fix the VDD_ARM_CAP voltage for 396MHz operation Table 8 from MX6DL datasheet (IMX6SDLCEC Rev. 5, 06/2015): http://cache.nxp.com/files/32bit/doc/data_sheet/IMX6SDLCEC.pdf states the following: "LDO Output Set Point (VDD_ARM_CAP) = 1.125 V minimum for operation up to 396 MHz." So fix the entry by adding the 25mV margin value as done in the other entries of the table, which results in 1.15V for 396MHz operation. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6dl.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe4266baba600218e076e01bc446e36f30e85d29 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Apr 25 16:38:48 2016 -0300 ARM: dts: imx6sx: Add 198MHz operating point 198MHz is a valid operating point for mx6sx. Add entries for VDD_ARM_CAP and VDD_SOC_CAP voltages for 198MHz according to the imx6sx datahseet: http://cache.nxp.com/files/32bit/doc/data_sheet/IMX6SXIEC.pdf (a 25mV offset is added to the minimum allowed values for safety). These values also match the ones from the NXP kernel. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6sx.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit f70844460f03e6ad6cfb148f4c394fdda1b50363 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Apr 25 16:38:47 2016 -0300 ARM: dts: imx6ul: Fix operating points Adjust the VDD_ARM_CAP and VDD_SOC_CAP voltages according to Table-11 from MX6UL datasheet: http://cache.nxp.com/files/32bit/doc/data_sheet/IMX6ULCEC.pdf (a 25mV offset is added to the minimum allowed values for safety). Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6ul.dtsi | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 6945248f34b95330700f3d2632608457abaddb18 Merge: 1fb7586 0767a5c Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 13:41:51 2016 +0200 Merge tag 'ox810se-arm-dt-v4.6-rc3' of https://github.com/superna9999/linux into next/dt Merge "ARM: dts: Add OXNAS Platform Bindings" from Neil Armstrong: * tag 'ox810se-arm-dt-v4.6-rc3' of https://github.com/superna9999/linux: ARM: boot: dts: Add Western Digital My Book World Edition device tree dt-bindings: Add Western Digital to vendor prefixes dt-bindings: Add OXNAS bindings ARM: boot: dts: Add Oxford Semiconductor OX810SE dtsi dt-bindings: Add Oxford Semiconductor to vendor prefixes dt-bindings: irq: arm,versatile-fpga: add compatible string for OX810SE SoC commit 513527c87a7feab2a5b31db07e5b07864d3c08f7 Author: Alan Liu <alanliu@qca.qualcomm.com> Date: Tue Apr 26 14:41:33 2016 +0300 ath10k: add max_tx_power for QCA6174 WLAN.RM.2.0 firmware QCA6174 WLAN.RM.2.0 firmware uses max_tx_power instead of using max_reg_power to set transmission power. The tx power was about -50dbm, after applying this change, it become -32dbm. Signed-off-by: Alan Liu <alanliu@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 1 + drivers/net/wireless/ath/ath10k/wmi.h | 1 + 2 files changed, 2 insertions(+) commit 769e4b8a3d84712db667a0fe55f6bdd4e1cfce8d Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 13:32:21 2016 +0200 metag: remove ARCH_WANT_OPTIONAL_GPIOLIB This symbols is not needed to get access to selecting the GPIOLIB anymore: any arch can select GPIOLIB. Cc: Michael Büsch <m@bues.ch> Cc: linux-metag@vger.kernel.org Acked-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/metag/Kconfig.soc | 1 - 1 file changed, 1 deletion(-) commit 5a161394aeb0b36c1be7ef6f54103cd13c95b8a1 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 11:10:42 2016 +0200 avr32: do away with ARCH_REQUIRE_GPIOLIB Replace "select ARCH_REQUIRE_GPIOLIB" with "select GPIOLIB" as this can now be selected directly. Cc: Michael Büsch <m@bues.ch> Cc: Haavard Skinnemoen <hskinnemoen@gmail.com> Acked-by: Acked-by: Hans-Christian Noren Egtvedt <egtvedt@samfundet.no> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/avr32/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 296ad4acb8efeffa456e344c73dc9459f4e9e1a0 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 10:39:21 2016 +0200 gpio: remove deps on ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB The GPIOLIB symbol currently require that ARCH_WANT_OPTIONAL_GPIOLIB or ARCH_REQUIRE_GPIOLIB is selected to be selectable. The ARCH_REQUIRE_GPIOLIB does only one thing: select GPIOLIB. This is just confusing: architectures that want GPIOLIB should be able to configure it in no matter what, and those who require it should just select GPIOLIB. It also creates problems for drivers that need to state "select GPIOLIB" to get dependencies: those depend on the selected architecture to select ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB first, and will cause compile errors for the few archs that state neither. These intermediary symbols need to go. As a first step, remove the dependencies so that: - ARCH_WANT_OPTIONAL_GPIOLIB becomes a noop (GPIOLIB will be available for everyone) and - "select ARCH_REQUIRE_GPIOLIB" can be replaced by just "select GPIOLIB" After this patch we can follow up with patches cleaning up the architectures one-by one and eventually remove the ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB symbols altogether. Reported-by: Michael Hennerich <michael.hennerich@analog.com> Cc: Michael Büsch <m@bues.ch> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 1 - 1 file changed, 1 deletion(-) commit 08cdac619c81b3fa8cd73aeed2330ffe0a0b73ca Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:47 2016 +0200 arm64: relocatable: deal with physically misaligned kernel images When booting a relocatable kernel image, there is no practical reason to refuse an image whose load address is not exactly TEXT_OFFSET bytes above a 2 MB aligned base address, as long as the physical and virtual misalignment with respect to the swapper block size are equal, and are both aligned to THREAD_SIZE. Since the virtual misalignment is under our control when we first enter the kernel proper, we can simply choose its value to be equal to the physical misalignment. So treat the misalignment of the physical load address as the initial KASLR offset, and fix up the remaining code to deal with that. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 9 ++++++--- arch/arm64/kernel/kaslr.c | 6 +++--- 2 files changed, 9 insertions(+), 6 deletions(-) commit 18b9c0d641938242d8bcdba3c14a8f2beec2a97e Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:46 2016 +0200 arm64: don't map TEXT_OFFSET bytes below the kernel if we can avoid it For historical reasons, the kernel Image must be loaded into physical memory at a 512 KB offset above a 2 MB aligned base address. The region between the base address and the start of the kernel Image has no significance to the kernel itself, but it is currently mapped explicitly into the early kernel VMA range for all translation granules. In some cases (i.e., 4 KB granule), this is unavoidable, due to the 2 MB granularity of the early kernel mappings. However, in other cases, e.g., when running with larger page sizes, or in the future, with more granular KASLR, there is no reason to map it explicitly like we do currently. So update the logic so that the region is mapped only if that happens as a side effect of rounding the start address of the kernel to swapper block size, and leave it unmapped otherwise. Since the symbol kernel_img_size now simply resolves to the memory footprint of the kernel Image, we can drop its definition from image.h and opencode its calculation. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 9 +++++---- arch/arm64/kernel/image.h | 2 -- 2 files changed, 5 insertions(+), 6 deletions(-) commit 4eb9b945c69fe1ccd6235e21c52627e1b741474a Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:45:13 2016 +0200 drm/sysfs: Annote lockless show functions with READ_ONCE For documentation and paranoia. Acked-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459331120-27864-4-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_sysfs.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit b03cc885328e3c0de61843737d42eb0a0f112aab Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:45 2016 +0200 arm64: kernel: replace early 64-bit literal loads with move-immediates When building a relocatable kernel, we currently rely on the fact that early 64-bit literal loads need to be deferred to after the relocation has been performed only if they involve symbol references, and not if they involve assemble time constants. While this is not an unreasonable assumption to make, it is better to switch to movk/movz sequences, since these are guaranteed to be resolved at link time, simply because there are no dynamic relocation types to describe them. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 30b5ba5cf333cc650e474eaf2cc1ae91bc7cf89f Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:44 2016 +0200 arm64: introduce mov_q macro to move a constant into a 64-bit register Implement a macro mov_q that can be used to move an immediate constant into a 64-bit register, using between 2 and 4 movz/movk instructions (depending on the operand) Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/assembler.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 0cd3defe0af4153ffc5fe39bcfa4abfc301984e9 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:43 2016 +0200 arm64: kernel: perform relocation processing from ID map Refactor the relocation processing so that the code executes from the ID map while accessing the relocation tables via the virtual mapping. This way, we can use literals containing virtual addresses as before, instead of having to use convoluted absolute expressions. For symmetry with the secondary code path, the relocation code and the subsequent jump to the virtual entry point are implemented in a function called __primary_switch(), and __mmap_switched() is renamed to __primary_switched(). Also, the call sequence in stext() is aligned with the one in secondary_startup(), by replacing the awkward 'adr_l lr' and 'b cpu_setup' sequence with a simple branch and link. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 96 ++++++++++++++++++++++------------------- arch/arm64/kernel/vmlinux.lds.S | 7 +-- 2 files changed, 55 insertions(+), 48 deletions(-) commit e5ebeec879b726c755af0c1c15f3699b53268cd5 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:42 2016 +0200 arm64: kernel: use literal for relocated address of __secondary_switched We can simply use a relocated 64-bit literal to store the address of __secondary_switched(), and the relocation code will ensure that it holds the correct value at secondary entry time, as long as we make sure that the literal is not dereferenced until after we have enabled the MMU. So jump via a small __secondary_switch() function covered by the ID map that performs the literal load and branch-to-register. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 190c056fc32a528979807cb5d5a0d68285933073 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 17:09:41 2016 +0200 arm64: kernel: don't export local symbols from head.S This unexports some symbols from head.S that are only used locally. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/head.S | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit efd7cef3100b2683ba4ff48943215b9537e9a37c Merge: f0d8f38 ffc03c3 Author: Kalle Valo <kvalo@codeaurora.org> Date: Tue Apr 26 14:13:59 2016 +0300 Merge ath-next from ath.git ath.git patches for 4.7. Major changes: ath10k * implement set_tsf() for 10.2.4 branch * remove rare MSI range support * remove deprecated firmware API 1 support ath9k * add module parameter to invert LED polarity wcn36xx * fixes to get the driver properly working on Dragonboard 410c commit 0d922f441dadf054ad707c6000ce0797d291fb52 Merge: 46a600e e557959 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 13:13:34 2016 +0200 Merge tag 'ox810se-arm-v4.6-rc3' of https://github.com/superna9999/linux into next/soc Merge "ARM: Add OXNAS Platform Support" from Neil Armstrong This is for the ARM926 based ox810 chip used in some older NAS appliances. There is another related ox820 chip based on ARM11 that might get added here later. * tag 'ox810se-arm-v4.6-rc3' of https://github.com/superna9999/linux: MAINTAINERS: add maintainer entry for ARM/OXNAS platform ARM: Add new mach-oxnas irqchip: versatile-fpga: add new compatible for OX810SE SoC commit d528c74e69b517c578fd021062ac7868e1ad5921 Merge: 58e696d 350a73b Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 13:11:15 2016 +0200 Merge tag 'renesas-pci-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/defconfig Merge "Renesas ARM Based SoC Pci Defconfig Updates for v4.7" from Simon Horman: * Remove Gen2 designation from Kconfig for R-Car PCIE driver * tag 'renesas-pci-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: PCI: rcar-pcie: Remove Gen2 designation from Kconfig commit de06f22f717b30641229036439b804ae79a7ad4d Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Mon Apr 25 19:30:39 2016 -0400 ASoC: cs42l56: Use IS_ENABLED() instead of checking for built-in or module The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/cs42l56.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3b1dbfa14f97188ec33fdfc7acb66bea59a3bb21 Author: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Date: Wed Apr 20 03:59:47 2016 -0400 cxl: Fix DAR check & use REGION_ID instead of opencoding The current code will set _PAGE_USER to the access flags for any fault address, because the ~ operation will be true for all address we take a fault on. But setting _PAGE_USER also means that the fault will be handled only if the page table have _PAGE_USER set. Hence there is no security hole with the current code. Now if it is an user space access, then the change in this patch really don't have an impact because we have (!ctx->kernel) set true and we take the if condition true. Now kernel context created fault on an address in the kernel range will result in a fault loop because we will not insert the hash pte due to access and pte permission mismatch. This patch fix the above issue. Fixes: f204e0b8cedd ("cxl: Driver code for powernv PCIe based cards for userspace access") Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f8aab65459e46f3300f66335b6d001389883597 Merge: 87411bb 2b905d3 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 13:02:24 2016 +0200 Merge tag 'hi6220-config-for-4.7v3' of git://github.com/hisilicon/linux-hisi into next/arm64 Merge "ARM64: Hi6220: configure updates for 4.7 based on rc3" from Wei Xu: - Enable Hi655x PMIC and regulator - Enable SPI_SPIDEV as module - Enable several common USB-Ethernet dongles - Enable configs for WLAN and TI WL1835 as modules - Enable ARM SP804 for ARCH_HISI * tag 'hi6220-config-for-4.7v3' of git://github.com/hisilicon/linux-hisi: arm64: Kconfig: select sp804 timer for ARCH_HISI arm64: defconfig: enable configs for WLAN and TI WL1835 as modules arm64: defconfig: enable several common USB network adapters arm64: defconfig: add CONFIG_SPI_SPIDEV as module arm64: defconfig: Enable the PMIC and regulator for Hi6220 and 96boards HiKey commit 3b9d78a4f3886f84db0a58dc986fbabb937799c6 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 15:13:10 2016 +0200 ARM: debug: remove extraneous DEBUG_HI3716_UART option DEBUG_HI3716_UART was supposed to be renamed to DEBUG_HIX5HD2_UART, but accidentally both got left in place, which results in a build error when CONFIG_DEBUG_UART_PHYS is not set as it should be. This removes the old symbol. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 12aae3097454 ("ARM: debug: Rename Hi3716 to HIX5HD2") Acked-by: Wei Xu <xuwei5@hisilicon.com> arch/arm/Kconfig.debug | 8 -------- 1 file changed, 8 deletions(-) commit bab3a34bb5f0b4056e37edf1bf6d097b147de453 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Tue Apr 12 08:30:42 2016 -0700 i40e: Code cleanup in i40e_add_fdir_ethtool A little bit of code cleanup in prep for more cloud filter work. Change-ID: I0dc33ce0d4c207944336a07437640fef920c100c Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 71c5e53b42f3641f6066c34b2c060dfe64d0ac2e Author: Axel Lin <axel.lin@ingics.com> Date: Tue Apr 26 18:53:12 2016 +0800 spi: Drop duplicate code to set master->dev.parent It's done by spi_alloc_master(). Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-axi-spi-engine.c | 1 - drivers/spi/spi-dln2.c | 1 - drivers/spi/spi-pxa2xx.c | 1 - 3 files changed, 3 deletions(-) commit 58e696d111ff3c111118126d9ffd790517acb131 Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:49:14 2016 +0100 ARM: configs: add MPS2 defconfig This patch adds a new config for MPS2 platform. Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/configs/mps2_defconfig | 109 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) commit 1fb75865d8b80b216a6f540b32f6cd1480f8c843 Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:49:16 2016 +0100 ARM: dts: introduce MPS2 AN399/AN400 Application Notes 399 and 400 shares the same memory map and features. Both are shipped with Cortex-M7 and have the same peripheral as AN385/AN386, but with different location of PSRAM and Ethernet controller. Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/boot/dts/Makefile | 4 +- arch/arm/boot/dts/mps2-an399.dts | 92 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 95 insertions(+), 1 deletion(-) commit f915ea5e7fd99861385b203e5a8582fdaa3a9b7c Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:49:15 2016 +0100 ARM: dts: introduce MPS2 AN385/AN386 Application Notes 385 and 386 shares the same memory map and features except the CPU is used. AN385 is supplied with Cortex-M3 CPU and AN386 is supplied with Cortex-M4. Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/mps2-an385.dts | 92 +++++++++++++++ arch/arm/boot/dts/mps2.dtsi | 241 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 334 insertions(+) commit 46a600eac9984037e027da4225f9b36d3f106da5 Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:49:17 2016 +0100 MAINTAINERS: Update ARM Versatile Express platform entry This patch update ARM Versatile Express entry to cover bits needed for Cortex-M Prototyping System (MPS2 platform). So patches for the latter are collected by existing Vexpress and Juno maintainers (Liviu, Sudeep, Lorenzo) and find their way upstream via Vexpess and/or Juno trees. Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 1847119dcc9841120dbdc45c0d049f37beed7a71 Author: Vladimir Murzin <vladimir.murzin@arm.com> Date: Mon Apr 25 09:49:13 2016 +0100 ARM: vexpress/mps2: introduce MPS2 platform The Cortex-M Prototyping System (or V2M-MPS2) is designed for prototyping and evaluation Cortex-M family of processors including the latest Cortex-M7 It comes with a range of useful peripherals including 8MB single cycle SRAM, 16MB PSRAM, Ethernet, QSVGA touch screen panel, 4bit RGB VGA connector, Audio, SPI and GPIO. Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/Kconfig | 12 ++++++++++++ arch/arm/Makefile | 1 + arch/arm/mach-vexpress/Makefile | 4 +++- arch/arm/mach-vexpress/Makefile.boot | 3 +++ arch/arm/mach-vexpress/v2m-mps2.c | 21 +++++++++++++++++++++ 5 files changed, 40 insertions(+), 1 deletion(-) commit c0913c2e431c86026acba667f8655d90979bb79c Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue Apr 12 08:30:41 2016 -0700 i40evf: Don't Panic Under some circumstances the driver remove function may be called before the driver is fully initialized. So we can't assume that we know where our towel is at, or that all of the data structures are initialized. To ensure that we don't panic, check that the vsi_res pointer is valid before dereferencing it. Then drink beer and eat peanuts. Change-ID: If697b4db57348e39f9538793e16aa755e3e1af03 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit c4e1868c3aa1992de1cba600e7083fcd49bd20b8 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Tue Apr 12 08:30:40 2016 -0700 i40e: Add support for configuring VF RSS Add support for configuring RSS on behalf of the VFs. This removes the burden of dealing with different hardware interfaces from the VF drivers, allowing for better future compatibility. Change-ID: Icea75d3f37241ee8e447be5779e5abb53ddf04c0 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 1 + drivers/net/ethernet/intel/i40e/i40e_main.c | 35 +++- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 193 ++++++++++++++++++++- 3 files changed, 217 insertions(+), 12 deletions(-) commit 20bef320366f13b81a21c198dd33c14084ee6cc3 Merge: d81e72c c531fb2 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 10:02:03 2016 +0200 Merge tag 'renesas-fixes-for-v4.6' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Renesas ARM Based SoC Fixes for v4.6 * Correct preset_lpj calculation which may lead to too short delays * Correct handling of optional clocks on r8a7791 to restore access to the serial port the porter board This is a backmerge of v4.6 fixes, to avoid a merge conflict between 4.6 and our next/dt branch. * tag 'renesas-fixes-for-v4.6' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: ARM: shmobile: timer: Fix preset_lpj leading to too short delays Revert "ARM: dts: porter: Enable SCIF_CLK frequency and pins" ARM: dts: r8a7791: Don't disable referenced optional clocks commit 577389a5db766c44400e75e6a79f39d9b0d585f8 Author: Alexander Duyck <aduyck@mirantis.com> Date: Sat Apr 2 00:06:56 2016 -0700 i40e/i40evf: Add support for IPIP and SIT offloads Looking over the documentation it turns out enabling IPIP and SIT offloads for i40e is pretty straightforward. As such I decided to enable them with this patch. In my testing I am seeing an improvement of 8 to 10 Gb/s for IPIP and SIT tunnels with this offload enabled. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 ++ drivers/net/ethernet/intel/i40e/i40e_txrx.c | 24 ++++++++++++++++-------- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 24 ++++++++++++++++-------- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 ++ 4 files changed, 36 insertions(+), 16 deletions(-) commit 27becea06e73c96b825ecddd8b3a59642364514a Author: PC Liao <pc.liao@mediatek.com> Date: Tue Apr 26 14:30:18 2016 +0800 ASoC: mediatek: HDMI audio LR channel swapped Because LRCK of TDM use High to Low as default setting, this patch changes the TDM setting to inverse LRCK. Signed-off-by: PC Liao <pc.liao@mediatek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/mediatek/mtk-afe-pcm.c | 2 ++ 1 file changed, 2 insertions(+) commit b0fe3306432796c8f7adbede8ccd479bb7b53d0a Author: Alexander Duyck <aduyck@mirantis.com> Date: Sat Apr 2 00:05:14 2016 -0700 i40e/i40evf: Clean up feature flags The feature flags list for i40e and i40evf is beginning to become pretty massive. I plan to add another 4 or so features to these drivers and duplicating the flags for each and every flags list is becoming a bit repetitive. The primary change here is that we now build our features list around hw_encap_features. After that we assign that to vlan_features, hw_features, and finally map that onto features. In addition we end up throwing features onto hw_encap_features that end up having no effect such as the Rx offloads and SCTP_CRC. However that should have no impact and makes things a bit easier for us as hw_encap_features is one of the less updated features maps available. For i40evf I went through and sanity checked a few features as well. Specifically RXCSUM was being set as a read-only feature which didn't make much sense. I have updated things so we can clear the NETIF_F_RXCSUM flag since that is really a software feature and not a hardware one anyway so disabling it is just a matter of ignoring the result from the hardware. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 61 ++++++++++------------- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 66 ++++++++++++------------- 2 files changed, 58 insertions(+), 69 deletions(-) commit 2452ee25255af95d122ff66ea390facb67a61fc3 Author: Axel Lin <axel.lin@ingics.com> Date: Tue Apr 26 07:31:15 2016 +0800 spi: pic32: Set proper bits_per_word_mask This driver only supports 8/16/32 bits_per_word, so set master->bits_per_word_mask accordingly. With this change, we can remove the spi->bits_per_word checking in pic32_spi_setup as it's done by spi core. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pic32.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit 4a5ed8c1adc39f86a2887183c71b007bc962fdce Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 11:19:26 2016 +0200 regulator: rk808: remove unused rk808_reg_ops_ranges After removing all uses of the range operations in a recent patch, we get a warning about the symbol not being referenced anywhere: drivers/regulator/rk808-regulator.c:306:29: 'rk808_reg_ops_ranges' defined but not used This removes the now-unused structure along with the rk808_set_suspend_voltage_range function that is only referenced from rk808_reg_ops_ranges. Fixes: afcd666d9db0 ("regulator: rk808: remove linear range definitions with a single range") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/rk808-regulator.c | 28 ---------------------------- 1 file changed, 28 deletions(-) commit 9ff49ce475cfeaf486321a2db8132a9500740faa Author: Bard Liao <bardliao@realtek.com> Date: Tue Apr 26 18:07:11 2016 +0800 ASoC: rt298: fix capture doesn't work at some cases RT298_CBJ_CTRL1(0x4f) bit 10 is needed for headset capture. It will be turned off when "VREF" widget is on and be turned on when bias level is ON. It is odd. And if "VREF" is turned on in bias level is ON, RT298_CBJ_CTRL1(0x4f) bit 10 will be turned off. This patch move the bit control from rt298_set_bias_level and rt298_vref_event to rt298_jack_detect. So it will be turned on once a jack is plugged in. Signed-off-by: Bard Liao <bardliao@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt298.c | 31 +++---------------------------- 1 file changed, 3 insertions(+), 28 deletions(-) commit 3c9e014c442caefa14c71494ca4473121007f60f Author: Bard Liao <bardliao@realtek.com> Date: Tue Apr 26 18:07:10 2016 +0800 ASoC: rt298: reset AD dilter is there is no MCLK rt298 need to reset AD filter and the ADC settings will take effort. Signed-off-by: Bard Liao <bardliao@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt298.c | 20 ++++++++++++++++++++ sound/soc/codecs/rt298.h | 2 ++ 2 files changed, 22 insertions(+) commit b1f3a3b03eb5f61b4051e2da9aa15653e705e111 Author: Florian Vallee <fvallee@eukrea.fr> Date: Tue Apr 19 17:50:05 2016 +0200 ARM: dts: at91: fix typo in sama5d2 PIN_PD24 description Fix a typo on PIN_PD24 for UTXD2 and FLEXCOM4_IO3 which were wrongly linked to PIN_PD23). Signed-off-by: Florian Vallee <fvallee@eukrea.fr> Fixes: 7f16cb676c00 ("ARM: at91/dt: add sama5d2 pinmux") Cc: stable@vger.kernel.org # v4.4+ [nicolas.ferre@atmel.com: add commit message, changed subject] Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d2-pinfunc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2b905d3a8d7e40c3486abbf585419fafa220a8f8 Author: Leo Yan <leo.yan@linaro.org> Date: Thu Jan 21 18:53:48 2016 +0800 arm64: Kconfig: select sp804 timer for ARCH_HISI Select sp804 timer for ARCH_HISI, which is used as broadcast timer. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/Kconfig.platforms | 1 + 1 file changed, 1 insertion(+) commit 45c175c4ae9695d6d2f30a45ab7f3866cfac184b Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Tue Apr 26 06:33:06 2016 -0300 [media] tw686x: avoid going past array Fix those two warnings: drivers/media/pci/tw686x/tw686x-video.c:69 tw686x_fields_map() error: buffer overflow 'std_525_60' 31 <= 31 drivers/media/pci/tw686x/tw686x-video.c:73 tw686x_fields_map() error: buffer overflow 'std_625_50' 26 <= 26 I had those changes at the last version of my patch, but I ended by merging the previous version by mistake. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/tw686x/tw686x-video.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d1b4cad61ba1273755c41fa40ae0feb53c3e49b2 Author: Guodong Xu <guodong.xu@linaro.org> Date: Sat Apr 2 19:47:54 2016 +0800 arm64: defconfig: enable configs for WLAN and TI WL1835 as modules This patch enables TI WL1835 and builds as module. It also enables CFG80211, MAC80211, RFKILL and several CRYPTOs which are required by WLAN. 96boards HiKey uses TI WLAN/BT combo module WL1835MOD. Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/configs/defconfig | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit f0d8f38cd909e072833a06b79939256c4aebe3a0 Author: Luca Coelho <luciano.coelho@intel.com> Date: Mon Apr 25 20:02:09 2016 +0300 iwlwifi: fix fw version reading for DVM devices In commit 97f95c93c8ed ("iwlwifi: remove support for fw older than -16.ucode") we accidentally changed the fw version reading code for DVM devices. The code intended to remove the old fw version API, because all MVM firmwares version 16 and above that we support don't use it anymore. But DVM devices still use the old FW API. Fix that by bringing the code back in. Reported-by: Pat Erley <pat-lkml@erley.org> Tested-by: Kalle Valo <kvalo@codeaurora.org> Fixes: 97f95c93c8ed ("iwlwifi: remove support for fw older than-16.ucode") Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 5 ++++- drivers/net/wireless/intel/iwlwifi/iwl-fw-file.h | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) commit 2557654df14b95141f1410127c33ed1661a8abbb Author: Chun-Yeow Yeoh <yeohchunyeow@gmail.com> Date: Thu Apr 21 00:41:34 2016 +0800 rt2800lib: enable MFP if hw crypt is disabled If rt2800usb is loaded with nohwcrypt=1, mac80211 takes care of the crypto with software encryption/decryption and thus, MFP can be used. Tested for secured mesh using ath9k_htc and ath9k. Signed-off-by: Chun-Yeow Yeoh <yeohchunyeow@gmail.com> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ralink/rt2x00/rt2800lib.c | 4 ++++ 1 file changed, 4 insertions(+) commit 3cf5d6c046cfbae007d7b60f41888a3687435c25 Author: Akira Tsukamoto <akira.tsukamoto@linaro.org> Date: Sat Apr 2 19:47:53 2016 +0800 arm64: defconfig: enable several common USB network adapters The arm64 system is likely to be used as a host computer instead of embedded devices and adding USB-Ethernet dongles to make it behave as host PC is mandatory. Changelog: v2: Changed drivers to be as modules instead of built-in. Signed-off-by: Akira Tsukamoto <akira.tsukamoto@linaro.org> Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/configs/defconfig | 10 ++++++++++ 1 file changed, 10 insertions(+) commit d3098f224fd3492f4234ab2014c8579425b1d6fc Author: Guodong Xu <guodong.xu@linaro.org> Date: Sat Apr 2 19:47:52 2016 +0800 arm64: defconfig: add CONFIG_SPI_SPIDEV as module add CONFIG_SPI_SPIDEV as module, for arm64. Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit 81542fac6eae586e0d6fd502618342e8e20b4c5a Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Apr 19 07:25:43 2016 -0700 brcmfmac: testing the wrong variable in brcmf_rx_hdrpull() Smatch complains about this code: drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c:335 brcmf_rx_hdrpull() error: we previously assumed '*ifp' could be null (see line 333) The problem is that we recently changed these from "ifp" to "*ifp" but there was one that we didn't update. - if (ret || !ifp || !ifp->ndev) { + if (ret || !(*ifp) || !(*ifp)->ndev) { if (ret != -ENODATA && ifp) ^^^ - ifp->stats.rx_errors++; + (*ifp)->stats.rx_errors++; I have updated it to *ifp as well. We always call this function is a non-NULL "ifp" pointer, btw. Fixes: c462ebcdfe42 ('brcmfmac: create common function for handling brcmf_proto_hdrpull()') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d7e182a10903e34da9eb79e5c99f0b28432d00be Author: Guodong Xu <guodong.xu@linaro.org> Date: Sat Apr 2 19:47:51 2016 +0800 arm64: defconfig: Enable the PMIC and regulator for Hi6220 and 96boards HiKey This patch enables a number of devices currently supported by the Hi6220 and 96boards HiKey. These include a) Hi655x PMIC and regulator b) Hi6220 I2C, USB, MMC, mailbox, and reset c) CONFIG_PINCTRL_SINGLE, and CONFIG_LEDS_GPIO Since b) and c) are already in the 4.6-rc3, so kept a) only in this patch and updated subject as well. v2: - rebase to next-20160310, CONFIG_MMC_BLOCK_MINORS=16 is already in. - set CONFIG_I2C_DESIGNWARE_PLATFORM to be build as module Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/configs/defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 394f0ed53108d5e038910e3eb733ccd3f0d9c464 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Apr 19 07:23:44 2016 -0700 mwifiex: fix loop timeout in mwifiex_prog_fw_w_helper() USB8XXX_FW_MAX_RETRY is 3. We were using a post-op loop "while (retries--) {" but then the lines after that assume the loop exits with retries set to zero. I've fixed this by changing to a pre-op loop. I started with retries set to 4 instead of 3 so that we still go through the loop the same number of times. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/usb.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit e0bdef0f75f0ee0d4747b72fa75310da78dbfa56 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Apr 19 07:21:58 2016 -0700 mwifiex: missing error code on allocation failure We accidentally return success instead of -ENOMEM. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/usb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 04a74a9f8af0cd61598e886c260ad0644b1dd5c0 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:36 2016 -0400 rtl8xxxu: Rename rtl8723au_iqk_phy_iq_bb_reg There is nothing 8723au specific about rtl8723au_iqk_phy_iq_bb_reg so rename the array to rtl8xxxu_iqk_phy_iq_bb_reg. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 85f466350abf3a7eeb579a3abd75f85e36d591fa Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:35 2016 -0400 rtl8xxxu: Rename rtl8723bu_simularity_compare() This renames rtl8723bu_simularity_compare() to rtl8xxxu_gen2_simularity_compare() to reflect it is used for all gen2 parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) commit 5ac74145487dbf93a109a06c8aec0da1395c35f5 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:34 2016 -0400 rtl8xxxu: Rename rtl8723b_channel_to_group() This renames rtl8723b_channel_to_group() to rtl8xxxu_gen2_channel_to_group() to reflect it is used by all currently supported gen2 parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8db71451e5c4ab5813e70b22a876e67a29a57a3f Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:33 2016 -0400 rtl8xxxu: Rename rtl8723a_mac_init_table to rtl8xxxu_gen1_mac_init_table All currently supported gen1 parts use the same mac_init_table, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8396a41cf7478f950f4682c1333771e1e4cf0b36 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:32 2016 -0400 rtl8xxxu: Rename rtl8723a_enable_rf() to rtl8xxxu_gen1_enable_rf() All gen1 parts use the same enable_rf() function, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 42a3bc7a2a8525f9a3679e5dad19866ef34e2c09 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:31 2016 -0400 rtl8xxxu: Rename rtl8723a_set_tx_power() to rtl8xxxu_gen1_set_tx_power() All gen1 parts use the same interface for setting TX power, so rename the function to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit de7c189c342da635d8b17460b851fbe9b7f1e898 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:30 2016 -0400 rtl8xxxu: Rename rtl8723au_init_phy_bb() to rtl8xxxu_gen1_init_phy_bb() All gen1 parts use the same init_phy_bb() function, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 28466e9214029ef0978acfbaae0f02f78caa4ae9 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:29 2016 -0400 rtl8xxxu: Rename rtl8723au_phy_iq_calibrate() to rtl8xxxu_gen1_phy_iq_calibrate() All supported gen1 parts use the same phy_iq_calibrate() function (unlike their gen2 counterparts). Rename the function to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c6e39da02e17bf3521f1c08df1555b6ffa77dee4 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:28 2016 -0400 rtl8xxxu: Rename rtl8723au_update_rate_mask() to rtl8xxxu_update_rate_mask() All currently supported gen1 parts use the same function for updating the rate mask, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e09718c2fddfc68a14503ea2016970e48872e722 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:27 2016 -0400 rtl8xxxu: Rename rtl8723au_config_channel() to rtl8xxxu_gen1_config_channel() All supported gen1 parts use the same config_channel() function, so rename it to reflect this. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7eb1400c247934dc485817a2c2b62540121a6e55 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:26 2016 -0400 rtl8xxxu: Rename rtl8723a_disable_rf() to rtl8xxxu_gen1_disable_rf() All currently supported gen1 parts use the same disable_rf() routine, so rename the function to reflect that. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 6a07b7915afe876195f8c8715ebc438c0b1d1348 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:25 2016 -0400 rtl8xxxu: Rename rtl8723b_disable_rf() to rtl8xxxu_gen2_disable_rf() At least for now, all gen2 parts use the same disable_rf() function Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 3a56bf6aa13c1bb6e4012824e0897f32acbb1f04 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:24 2016 -0400 rtl8xxxu: Rename rtl8723bu_config_channel() to rtl8xxxu_gen2_config_channel() Rename the function to indicate it is applicable to most/all gen2 parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit beb5531619c615f9b1d204d6d300dfe9e2fd454e Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:23 2016 -0400 rtl8xxxu: Rename rtl8723au_report_connect() to rtl8xxxu_gen1_report_connect() Rename the function to reflect it is for all/most gen1 parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 32353a784f431185690919049b6951d309dc186e Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:22 2016 -0400 rtl8xxxu: Rename rtl8723bu_report_connect() to rtl8xxxu_gen2_report_connect() Make the name reflect this is for most/all gen2 parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a8c8dfa5931970a31794eeb65ced790fcff099d0 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Mon Apr 18 11:49:21 2016 -0400 rtl8xxxu: Rename rtl8723bu_update_rate_mask() to rtl8xxxu_gen2_update_rate_mask() Update the name of rtl8723bu_update_rate_mask() to make it reflect it's applicable for all/most gen2 N parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit eaf46b5fda3acd75df68f02d25754dccb446ec2d Author: Xinming Hu <huxm@marvell.com> Date: Mon Apr 18 06:42:55 2016 -0700 mwifiex: stop background scan when net device closed Transmit data path should not touch background scan. We will stop background scan when net device is closed. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/main.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit ce4f6f0c353b7bfd7b527667287a87fd83aea119 Author: Xinming Hu <huxm@marvell.com> Date: Mon Apr 18 05:22:23 2016 -0700 mwifiex: add platform specific wakeup interrupt support On some arm-based platforms, we need to configure platform specific parameters by device tree node and also define our node as a child node of parent SDIO host controller. This patch parses these parameters from device tree. It includes calibration data dowoload to firmware, wakeup pin configured to firmware, and soc specific wake up gpio, which will be set as wakeup interrupt pin. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/main.h | 11 ++++ drivers/net/wireless/marvell/mwifiex/sdio.c | 77 ++++++++++++++++++++++++++ drivers/net/wireless/marvell/mwifiex/sdio.h | 7 +++ drivers/net/wireless/marvell/mwifiex/sta_cmd.c | 14 ++++- 4 files changed, 106 insertions(+), 3 deletions(-) commit 84039920bdff60030b2b79e50e4c9d230ae00dad Author: Xinming Hu <huxm@marvell.com> Date: Mon Apr 18 05:22:22 2016 -0700 dt: bindings: add MARVELL's sd8xxx wireless device Add device tree binding documentation for MARVELL's sd8xxx (sd8897 and sd8997) wlan chip. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../bindings/net/wireless/marvell-sd8xxx.txt | 63 ++++++++++++++++++++++ 1 file changed, 63 insertions(+) commit 53985dccb1c98b7af080e2314bff0c5024e781b0 Author: Per Forlin <per.forlin@gmail.com> Date: Sun Apr 17 15:25:03 2016 +0200 brcmf: Fix null pointer exception in bcdc_hdrpull In fwsignal.c: brcmf_fws_commit_skb() ... if (rc < 0) { entry->transit_count--; if (entry->suppressed) entry->suppr_transit_count--; (void)brcmf_proto_hdrpull(fws->drvr, false, skb, NULL); ^^^^^^^ goto rollback; } ... The call to hdrpull will trigger a null pointer exception unless a null check is made in the method implementation. Signed-off-by: Per Forlin <per.forlin@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcdc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7705ba6f7badb8cf38a0a19dad71e11a77ecb9cd Author: Arend van Spriel <arend@broadcom.com> Date: Sun Apr 17 16:44:58 2016 +0200 brcmfmac: add support for nl80211 BSS_SELECT feature Announce support for nl80211 feature BSS_SELECT and process BSS selection behaviour provided in .connect() callback. Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Reviewed-by: Lei Zhang <leizh@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../broadcom/brcm80211/brcmfmac/cfg80211.c | 64 ++++++++++++++++++++++ .../wireless/broadcom/brcm80211/brcmfmac/common.c | 38 ++++++++----- .../wireless/broadcom/brcm80211/brcmfmac/core.h | 1 + .../wireless/broadcom/brcm80211/brcmfmac/fwil.h | 1 + 4 files changed, 89 insertions(+), 15 deletions(-) commit 005a425b24e101d312eca669b96a6b71d75e97fc Author: David Müller <d.mueller@elsoft.ch> Date: Fri Apr 15 08:50:25 2016 +0200 rtlwifi: rtl8821ae: Make sure loop counter is signed on all architectures The for-loop condition does not work correctly on architectures where "char" is unsigned. Fix it by using an "int", which may also result in more efficient code. Signed-off-by: David Müller <d.mueller@elsoft.ch> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 706a527ca32b3bf950754631fa42982c0f1c060b Author: Tina Ruchandani <ruchandani.tina@gmail.com> Date: Tue Apr 12 23:09:16 2016 -0700 prism54: isl_38xx: Replace 'struct timeval' 'struct timeval' uses a 32-bit seconds field which will overflow in year 2038 and beyond. This patch is part of a larger effort to remove all instances of 'struct timeval' from the kernel and replace them with 64-bit timekeeping variables. The patch also fixes the debug printf specifier to avoid the seconds value being truncated. The patch was build-tested / debugged by removing the "if VERBOSE > SHOW_ERROR_MESSAGES" guards. Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Suggested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intersil/prism54/isl_38xx.c | 35 ++++++++++++------------ 1 file changed, 18 insertions(+), 17 deletions(-) commit e4c8b456c53d4beee5adaf5768c762171e2244f3 Author: Jia-Ju Bai <baijiaju1990@163.com> Date: Fri Mar 18 13:27:09 2016 +1100 rtl818x_pci: Fix a memory leak in rtl8180_init_rx_ring When dev_alloc_skb or pci_dma_mapping_error in rtl8180_init_rx_ring fails, the memory allocated by pci_zalloc_consistent is not freed. This patch fixes the bug by adding pci_free_consistent in error handling code. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl818x/rtl8180/dev.c | 4 ++++ 1 file changed, 4 insertions(+) commit a89d6cb3b3c3226dfd8118eea7ec2b19635738f6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 19 14:47:50 2016 +0200 gpio: revert bank bindings Keep the words talking about what a GPIO bank is, but remove the binding. We have not agreed that this is something we want to have. Acked-by: Rob Herring <robh+dt@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/devicetree/bindings/gpio/gpio.txt | 7 ------- 1 file changed, 7 deletions(-) commit 44c7288f791fa804a88f97496291ecf698fb3887 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sun Apr 24 11:36:59 2016 +0200 gpio: move gpiod_set_array_value_priv() This renames gpiod_set_array_value_priv() to gpiod_set_array_value_complex() and moves it to the gpiolib.h private header file so we can reuse it in the subsystem. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 24 ++++++++++++------------ drivers/gpio/gpiolib.h | 4 ++++ 2 files changed, 16 insertions(+), 12 deletions(-) commit 2441e78b19192cd9ea1ce93027a5732a2117f026 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Fri Apr 22 15:25:00 2016 -0400 kbuild: better abstract vmlinux sequential prerequisites When CONFIG_TRIM_UNUSED_KSYMS=y and CONFIG_BUILD_DOCSRC=y it is possible to get the following error: ERROR: "cn_del_callback" [Documentation/connector/cn_test.ko] undefined! ERROR: "cn_add_callback" [Documentation/connector/cn_test.ko] undefined! ERROR: "cn_netlink_send" [Documentation/connector/cn_test.ko] undefined! ../scripts/Makefile.modpost:91: recipe for target '__modpost' failed It is not sufficient to do "vmlinux-dirs += Documentation" as this also depends on the headers_check target, and all of this needs to be done before adjust_autoksyms.sh is executed. Let's sort this out by gathering those sequential prerequisites in a make target of their own, separate from the vmlinux target. And by doing so, the special autoksyms_recursive target is no longer needed. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Randy Dunlap <rdunlap@infradead.org> Tested-by: Randy Dunlap <rdunlap@infradead.org> Makefile | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) commit ba79d401f1aee52186ff09607e9405cfb805307d Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Mon Apr 25 17:55:08 2016 +0200 kbuild: fix call to adjust_autoksyms.sh when output directory specified When a different output directory is specified during the build process (with O= or KBUILD_OUTPUT), the call to adjust_autoksyms.sh script fails with the following error: /bin/sh scripts/adjust_autoksyms.sh \ "make KBUILD_MODULES=1 -f ../Makefile autoksyms_recursive" /bin/sh: scripts/adjust_autoksyms.sh: No such file or directory make[2]: *** [vmlinux] Error 127 make[1]: *** [sub-make] Error 2 make: *** [__sub-make] Error 2 Using the absolute path with $(srctree) variable solves the problem. This is in case the CONFIG_TRIM_UNUSED_KSYMS option is specified. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Fixes: 23121ca2b56b ("kbuild: create/adjust generated/autoksyms.h") Cc: Nicolas Pitre <nico@linaro.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit a183d7f846de1ea87b9010f0aab77d2f4915e064 Merge: 2b9cf18 23f1e2e Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 10:21:57 2016 +0200 Merge tag 'renesas-rcar-sysc2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/drivers Merge "Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.7" from Simon Horman: Introduce a DT-based driver for the R-Car System Controller, as found on Renesas R-Car H1, R-Car Gen2, and R-Car Gen3 SoCs. * tag 'renesas-rcar-sysc2-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: (30 commits) soc: renesas: rcar-sysc: Add support for R-Car H3 power areas soc: renesas: rcar-sysc: Add support for R-Car E2 power areas soc: renesas: rcar-sysc: Add support for R-Car M2-N power areas soc: renesas: rcar-sysc: Add support for R-Car M2-W power areas soc: renesas: rcar-sysc: Add support for R-Car H2 power areas soc: renesas: rcar-sysc: Add support for R-Car H1 power areas soc: renesas: rcar-sysc: Enable Clock Domain for I/O devices soc: renesas: rcar-sysc: Make rcar_sysc_power_is_off() static soc: renesas: rcar-sysc: Add DT support for SYSC PM domains soc: renesas: rcar-sysc: Improve rcar_sysc_power() debug info soc: renesas: Move pm-rcar to drivers/soc/renesas/rcar-sysc clk: renesas: cpg-mssr: Export cpg_mssr_{at,de}tach_dev() clk: renesas: mstp: Provide dummy attach/detach_dev callbacks clk: renesas: Provide Kconfig symbols for CPG/MSSR and CPG/MSTP support soc: renesas: Add r8a7795 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7794 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7793 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7791 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7790 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7779 SYSC PM Domain Binding Definitions ... commit a33d59599653edc6469c582f0ffd99c5fc58af04 Merge: 58a8738 bb03ed2 Author: Takashi Iwai <tiwai@suse.de> Date: Tue Apr 26 10:04:19 2016 +0200 Merge branch 'for-linus' into for-next For taking back the recent change of HDA HDMI fixes for i915 HSW/BDW. Signed-off-by: Takashi Iwai <tiwai@suse.de> commit 58a8738cfcdec389b3764a636303f97b57f85193 Author: Takashi Iwai <tiwai@suse.de> Date: Thu Mar 10 21:03:09 2016 +0100 ALSA: au88x0: Fix overlapped PCM pointer au88x0 hardware seems returning the current pointer at the buffer boundary instead of going back to zero. This results in spewing warnings from PCM core. This patch corrects the return value from the pointer callback within the proper value range, just returning zero if the position is equal or above the buffer size. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/au88x0/au88x0_pcm.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 0767a5cb425374aafa89d33d6b1190a01d7f6b0e Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 10:53:57 2016 +0100 ARM: boot: dts: Add Western Digital My Book World Edition device tree Add Western Digital My Book World Edition device tree based on Oxford Semiconductor OX810SE SoC. Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/wd-mbwe.dts | 112 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 114 insertions(+) commit f85d8ffbecadf72d2d80077f5fabba820ea4c55b Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 10:53:31 2016 +0100 dt-bindings: Add Western Digital to vendor prefixes Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 07609675add33ef34e880db05aaeef3c93d1aab2 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 10:45:50 2016 +0100 dt-bindings: Add OXNAS bindings Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Documentation/devicetree/bindings/arm/oxnas.txt | 9 +++++++++ 1 file changed, 9 insertions(+) commit 84316f4ef141cfee1e8ccd1b5749998eba2496ee Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 10:52:58 2016 +0100 ARM: boot: dts: Add Oxford Semiconductor OX810SE dtsi Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> arch/arm/boot/dts/ox810se.dtsi | 336 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 336 insertions(+) commit cc86e3e2a3ff19c86a3c4a979d7da5a92e41c9cc Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 14:34:14 2016 +0100 dt-bindings: Add Oxford Semiconductor to vendor prefixes Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 145f8a155c3e8e6c7a4cf8ddb4c5be7b53d6adf1 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Mon Mar 7 15:50:52 2016 +0100 dt-bindings: irq: arm,versatile-fpga: add compatible string for OX810SE SoC Under the OX810SE, this same controller is used as "Reference Peripheral Specification" Interrupt Controller, so add new compatible string to support the Oxford Semiconductor OX810SE SoC Interrupt Controller. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> .../devicetree/bindings/interrupt-controller/arm,versatile-fpga-irq.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e557959d5599037899dd974f4a79419c664dcf79 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Fri Apr 1 14:56:16 2016 +0200 MAINTAINERS: add maintainer entry for ARM/OXNAS platform Add a maintainer entry for ARM/OXNAS platform and add myself as a maintainer. Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> MAINTAINERS | 9 +++++++++ 1 file changed, 9 insertions(+) commit 8c9184b7d95859b24bba1201780886aabdab8ce1 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Thu Mar 3 10:42:15 2016 +0100 ARM: Add new mach-oxnas Add mach-oxnas directory containing Kconfig. Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> arch/arm/Kconfig | 2 ++ arch/arm/mach-oxnas/Kconfig | 24 ++++++++++++++++++++++++ 2 files changed, 26 insertions(+) commit 1adea8b8bd1d12aef0a2f2baf7ed7a0ffbb1c505 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Mon Mar 7 15:49:08 2016 +0100 irqchip: versatile-fpga: add new compatible for OX810SE SoC Under the OX810SE, this exact same interface is used as "Reference Peripheral Specification" Interrupt Controller, so add a new compatible string in order to support the Oxford Semiconductor OX810SE SoC interrupt controller. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> drivers/irqchip/irq-versatile-fpga.c | 1 + 1 file changed, 1 insertion(+) commit 9b95fe59b18bcc891a6c60ae11d725c9c679574b Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 26 09:42:39 2016 +0200 nl80211: add missing kerneldoc for new *_PAD attributes Nicolas's patch missed this, now generating docbook warnings. Add the missing descriptions to address that. Fixes: 2dad624e6dd6 ("wireless: use nla_put_u64_64bit()") Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/uapi/linux/nl80211.h | 4 ++++ 1 file changed, 4 insertions(+) commit e705498945ad3a3b945771c5d683df064bb9819c Author: Kanchanapally, Vidyullatha <vkanchan@qti.qualcomm.com> Date: Mon Apr 11 15:16:01 2016 +0530 cfg80211: Add option to report the bss entry in connect result Since cfg80211 maintains separate BSS table entries for APs if the same BSSID, SSID pair is seen on multiple channels, it is possible that it can map the current_bss to a BSS entry on the wrong channel. This current_bss will not get flushed unless disconnected and cfg80211 reports a wrong channel as the associated channel. Fix this by introducing a new cfg80211_connect_bss() function which is similar to cfg80211_connect_result(), but it includes an additional parameter: the bss the STA is connected to. This allows drivers to provide the exact bss entry that matches the BSS to which the connection was completed. Reviewed-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Vidyullatha Kanchanapally <vkanchan@qti.qualcomm.com> Signed-off-by: Sunil Dutt <usdutt@qti.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Documentation/DocBook/80211.tmpl | 1 + include/net/cfg80211.h | 39 +++++++++++++++++++++++++++++++++++---- net/wireless/core.h | 1 + net/wireless/sme.c | 28 ++++++++++++++++++++++------ net/wireless/util.c | 2 +- 5 files changed, 60 insertions(+), 11 deletions(-) commit 739960f128e5a1f251659a4430a8898087701099 Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Thu Apr 7 19:59:34 2016 +0530 cfg80211/nl80211: Add support for NL80211_STA_INFO_RX_DURATION Add support for the a station statistics netlink attribute: NL80211_STA_INFO_RX_DURATION. If present, this attribute contains the aggregate PPDU duration (in microseconds) for all the frames from the peer. This is useful to help understand the total time spent transmitting to us by all of the connected peers. Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 4 +++- include/uapi/linux/nl80211.h | 3 +++ net/wireless/nl80211.c | 3 ++- 3 files changed, 8 insertions(+), 2 deletions(-) commit d2c5cf88d5282de258f4eb6ab40040b80a075cd8 Author: Takashi Iwai <tiwai@suse.de> Date: Sun Apr 24 22:52:18 2016 +0200 ALSA: hrtimer: Handle start/stop more properly This patch tries to address the still remaining issues in ALSA hrtimer driver: - Spurious use-after-free was detected in hrtimer callback - Incorrect rescheduling due to delayed start - WARN_ON() is triggered in hrtimer_forward() invoked in hrtimer callback The first issue happens only when the new timer is scheduled even while hrtimer is being closed. It's related with the second and third items; since ALSA timer core invokes hw.start callback during hrtimer interrupt, this may result in the explicit call of hrtimer_start(). Also, the similar problem is seen for the stop; ALSA timer core invokes hw.stop callback even in the hrtimer handler, too. Since we must not call the synced hrtimer_cancel() in such a context, it's just a hrtimer_try_to_cancel() call that doesn't properly work. Another culprit of the second and third items is the call of hrtimer_forward_now() before snd_timer_interrupt(). The timer->stick value may change during snd_timer_interrupt() call, but this possibility is ignored completely. For covering these subtle and messy issues, the following changes have been done in this patch: - A new flag, in_callback, is introduced in the private data to indicate that the hrtimer handler is being processed. - Both start and stop callbacks skip when called from (during) in_callback flag. - The hrtimer handler returns properly HRTIMER_RESTART and NORESTART depending on the running state now. - The hrtimer handler reprograms the expiry properly after snd_timer_interrupt() call, instead of before. - The close callback clears running flag and sets in_callback flag to block any further start/stop calls. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/hrtimer.c | 56 ++++++++++++++++++++++++++++++++++++---------------- 1 file changed, 39 insertions(+), 17 deletions(-) commit ccce262de1c5035513d7974ab1550dd757d25bf4 Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Mon Apr 25 13:39:20 2016 +0200 clk: renesas: r8a7795: Add VIN clocks Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 0187d321a5092fe09687f69ee29ebe8ab75544c2 Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Mon Apr 25 13:39:19 2016 +0200 clk: renesas: r8a7795: Add CSI2 clocks Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 5 +++++ 1 file changed, 5 insertions(+) commit 0449eefe2db1038a327db45d5428c196f63c0cb9 Author: Stefan Agner <stefan@agner.ch> Date: Mon Apr 25 20:47:57 2016 -0700 drm/fsl-dcu: increment version and date The driver supports now a second platform and received several fixes, hence a version increment is justified. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a47241cdeee2689ee7089ec95cadfcf66588fbdb Author: Alden Tondettar <alden.tondettar@gmail.com> Date: Mon Apr 25 19:27:56 2016 -0700 udf: Prevent stack overflow on corrupted filesystem mount Presently, a corrupted or malicious UDF filesystem containing a very large number (or cycle) of Logical Volume Integrity Descriptor extent indirections may trigger a stack overflow and kernel panic in udf_load_logicalvolint() on mount. Replace the unnecessary recursion in udf_load_logicalvolint() with simple iteration. Set an arbitrary limit of 1000 indirections (which would have almost certainly overflowed the stack without this fix), and treat such cases as if there were no LVID. Signed-off-by: Alden Tondettar <alden.tondettar@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz> fs/udf/super.c | 67 +++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 43 insertions(+), 24 deletions(-) commit abbbc60a0c69e05c965ce51cb75c0bee56dc0025 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Tue Apr 19 14:33:34 2016 +0200 mtd: pmc551: add __init attribute Add __init attribute on a function that is only called from other __init functions and that is not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the function is put in the .text.unlikely segment. Declaring it as __init will cause it to be put in the .init.text and to disappear after initialization. The result of objdump -x on the function before the change is as follows: 00000000000000c6 l F .text.unlikely 000000000000091c fixup_pmc551 And after the change it is as follows: 0000000000000000 l F .init.text 0000000000000917 fixup_pmc551 Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/devices/pmc551.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e4106a7c8236eb7b91686d36f3bf33ee43db94b4 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Tue Apr 19 14:33:33 2016 +0200 mtd: maps: add __init attribute Add __init attribute on functions that are only called from other __init functions and that are not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the functions are put in the .text.unlikely segment. Declaring them as __init will cause them to be put in the .init.text and to disappear after initialization. The result of objdump -x on the functions before the change is as follows: 00000000000001bc l F .text.unlikely 00000000000006a2 ck804xrom_init_one.isra.1 00000000000001aa l F .text.unlikely 0000000000000764 esb2rom_init_one.isra.1 00000000000001db l F .text.unlikely 0000000000000716 ichxrom_init_one.isra.1 And after the change it is as follows: 0000000000000000 l F .init.text 000000000000069d ck804xrom_init_one.isra.1 0000000000000000 l F .init.text 000000000000075f esb2rom_init_one.isra.1 0000000000000000 l F .init.text 0000000000000711 ichxrom_init_one.isra.1 Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Note that in each case, the function is stored in the probe field of a pci_driver structure, but this code is under an #if 0. The #if 0s have been unchanged since 2009 at the latest. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/maps/ck804xrom.c | 4 ++-- drivers/mtd/maps/esb2rom.c | 4 ++-- drivers/mtd/maps/ichxrom.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) commit fab7b629a82da1b59620470d13152aff975239f6 Merge: a843311 90bfe66 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 01:32:01 2016 -0400 Merge branch 'ila-csum-neutral' Tom Herbert says: ==================== ila: Support for checksum neutral translations This patch set updates ILA to support draft-herbert-nvo3-ila-02. The primary addition is support checksum neutral ILA translation. This allows address to be performed and still keep any transport layer checksums that include the addresses in their pseudo header to still be correct without the translator needing to parse L4. Other items are: - Structures for ILA addresses, identifiers, locators - Disallow translation on non-ILA addresses (check by type in identifier). - Change xlat (nf_input) to translates solely based on matching locators not identifiers (since identifiers are not obfuscated by checksum neutral). - Side effect if above is that multiple ILA domains are supported. Each local locator can map to a different SIR address (ILA domain), and each domain defines its own identifier space. Tested: Ran TCP_RR with 200 cnxs. ILA performance is slightly better than previously since we are not longer parsing L4 for checksum handling. I amd seeing about 1% performance overhead. Also ran TCP_STREAM and tested non-ILA address (type=0) are not translated. v2: Fix compilation errors ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 90bfe662db13d49cadc6714b0b8ed7e2d0535c5c Author: Tom Herbert <tom@herbertland.com> Date: Sat Apr 23 11:46:57 2016 -0700 ila: add checksum neutral ILA translations Support checksum neutral ILA as described in the ILA draft. The low order 16 bits of the identifier are used to contain the checksum adjustment value. The csum-mode parameter is added to described checksum processing. There are three values: - adjust transport checksum (previous behavior) - do checksum neutral mapping - do nothing On output the csum-mode in the ila_params is checked and acted on. If mode is checksum neutral mapping then to mapping and set C-bit. On input, C-bit is checked. If it is set checksum-netural mapping is done (regardless of csum-mode in ila params) and C-bit will be cleared. If it is not set then action in csum-mode is taken. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/ila.h | 7 +++++ net/ipv6/ila/ila.h | 16 ++++++++-- net/ipv6/ila/ila_common.c | 74 +++++++++++++++++++++++++++++++++++++++++++++-- net/ipv6/ila/ila_lwt.c | 14 +++++++-- net/ipv6/ila/ila_xlat.c | 16 +++++----- 5 files changed, 112 insertions(+), 15 deletions(-) commit 642c2c95585dac4ea977140dbb1149fd1e2e7f7f Author: Tom Herbert <tom@herbertland.com> Date: Sat Apr 23 11:46:56 2016 -0700 ila: xlat changes Change model of xlat to be used only for input where lookup is done on the locator part of an address (comparing to locator_match as key in rhashtable). This is needed for checksum neutral translation which obfuscates the low order 16 bits of the identifier. It also permits hosts to be in muliple ILA domains (each locator can map to a different SIR address). A check is also added to disallow translating non-ILA addresses (check of type in identifier). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ila/ila_xlat.c | 103 ++++++++++++++++-------------------------------- 1 file changed, 34 insertions(+), 69 deletions(-) commit 351596aad54a7e07de63fde38496656514661b07 Author: Tom Herbert <tom@herbertland.com> Date: Sat Apr 23 11:46:55 2016 -0700 ila: Add struct definitions and helpers Add structures for identifiers, locators, and an ila address which is composed of a locator and identifier and in6_addr can be cast to it. This includes a three bit type field and enums for the types defined in ILA I-D. In ILA lwt don't allow user to set a translation for a non-ILA address (type of identifier is zero meaning it is an IID). This also requires that the destination prefix is at least 65 bytes (64 bit locator and first byte of identifier). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ila/ila.h | 67 ++++++++++++++++++++++-- net/ipv6/ila/ila_common.c | 11 ++-- net/ipv6/ila/ila_lwt.c | 39 +++++++++----- net/ipv6/ila/ila_xlat.c | 126 +++++++++++++++++++++++----------------------- 4 files changed, 161 insertions(+), 82 deletions(-) commit a843311d87b69540641d491b97b328309d3a28a1 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sat Apr 23 11:07:02 2016 +0200 net: tsi108: use NULL for pointer-typed argument The first argument of pci_free_consistent has type struct pci_dev *, so use NULL instead of 0. The semantic patch that performs this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ @@ pci_free_consistent( - 0 + NULL , ...) // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/tundra/tsi108_eth.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 218afa10d82d7809c9a7d14f1c769be8d7d6e2b8 Merge: 5a5f079 218afd6 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 26 01:09:18 2016 -0400 Merge branch 'hns-debug-dsaf' Yisen Zhuang says: ==================== net: hns: add support of debug dsaf device There are two kinds of dsaf device in hns, one is for service ports, contains crossbar in it, can work under different mode. Another is for debug port, only can work under single port mode. The current code only declares a dsaf device for both service ports and debug ports.It is not so readability. This patch separates it to three platform devices to make the code more simple and readability. The diagram of all port in one platform device(old): CPU | | DSAF(one platform device) -------------------------------------------------------------- / | | | | | / | PPE PPE PPE | / | | | | | / | | | | | / | crossbar | | | / | | | | |/ | ----------------------------------- | | | | | | | | | | | | | | | | | | | | | | | | MAC MAC MAC MAC MAC MAC MAC MAC | | | | | | | | | | | -------------------------------------------------------------- | | | | | | | | PHY PHY PHY PHY PHY PHY PHY PHY The diagram of separating ports to three platform(new): CPU | ----------------------------------- | | | ---------------------------------------------- --------- --------- | | | | | | | | | PPE | | PPE | | PPE | | | | | | | | | | | | | | | | | | | | crossbar | | | | | | | | | | | | | | | | | ---------------------------------- | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MAC MAC MAC MAC MAC MAC | | MAC | | MAC | | | | | | | | | | | | | | | ---------------------------------------------- --------- --------- | | | | | | \ / | / | PHY PHY PHY PHY PHY PHY \ / PHY / PHY \ / / \ / / DSAF(three platform device) We take the compatibility into consideration, and it works well by using the old dts file(tested on d02 board). For more details, please see individual patches. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 218afd68a2e6de8226c4048e4dd051075648a9c6 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:17 2016 +0800 dts: hisi: update hns dst for separating dsaf dev support Because debug dsaf port was separated from service dsaf port, this patch updates the related configurations of hns dts, changes it to match with the new binding files. This also removes enet nodes which don't exist in d02 board. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> arch/arm64/boot/dts/hisilicon/hip05_hns.dtsi | 72 ++++++++++++---------------- 1 file changed, 30 insertions(+), 42 deletions(-) commit c132cdccb71ee000d6456ec63acdf0535b5f35da Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:16 2016 +0800 Documentation: Bindings: add port-idx-in-ae for enet node This patch adds description for port-idx-in-ae attribute. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../devicetree/bindings/net/hisilicon-hns-nic.txt | 30 +++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) commit 2fc695a1bb00141a0f5df74e7a19e125f4babaa5 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:15 2016 +0800 Documentation: Bindings: Update DT binding for separating dsaf dev support Because debug dsaf port was separated from service dsaf port, this patch updates the related information of DT binding. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../devicetree/bindings/net/hisilicon-hns-dsaf.txt | 59 ++++++++++++++++++---- 1 file changed, 49 insertions(+), 10 deletions(-) commit 0d768fc62def08628affa4a2abe4f319926027a9 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:14 2016 +0800 net: hns: add attribute port-mode-offset for dsaf port node Port mode offset for each dsaf port is different. The current code is not so readability. This patch adds configuration named port-mode-offset to make the code simple and more readability. If port-mode-offset isn't exists, default value 0 will be used. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <Yisen.Zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 10 +++++ drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.h | 1 + drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 44 ++++++++++------------ 3 files changed, 30 insertions(+), 25 deletions(-) commit 850bfa3b78ea8849fef78ed74f5f2ccf947db0ca Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:13 2016 +0800 net: hns: add attribute port-rst-offset for dsaf port node The reset offset for each port in a dsaf is different. The current code is not so readability. This patch adds configuration named port-rst-offset to make the code simple and more readability. If this attribute doesn't exist, default value of this attribute is equal to its port index. Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 10 +++++++++ drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.h | 1 + drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 25 +++++++--------------- 3 files changed, 19 insertions(+), 17 deletions(-) commit 31d4446dca9112ce7b9eada8e6d631a7580e2feb Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:12 2016 +0800 net: hns: add attribute cpld_ctrl for dsaf port node This patch adds attribute cpld_ctrl for dsaf port node, parses the syscon for mac_cb from dts, and changes the method of access the cpld related registers through syscon. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 2 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 38 ++++++++++++---------- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.h | 3 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 5 --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h | 1 - drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 36 +++++++++++++++----- 6 files changed, 51 insertions(+), 34 deletions(-) commit 831d828bf2cc8535b74fa33c705a6f83e2e34eec Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:11 2016 +0800 net: hns: separate debug dsaf device from service dsaf device There are two kinds of dsaf device in hns, one is for service ports, contains crossbar in it, can work under different mode. Another is for debug port, only can work under "single-port" mode. The current code only declared a dsaf device for both service ports and debug ports. This patch separate it to three platform devices. Here is the diagram of all port in one platform device(old): CPU | | DSAF(one platform device) -------------------------------------------------------------- / | | | | | / | PPE PPE PPE | / | | | | | / | | | | | / | crossbar | | | / | | | | |/ | ----------------------------------- | | | | | | | | | | | | | | | | | | | | | | | | MAC MAC MAC MAC MAC MAC MAC MAC | | | | | | | | | | | -------------------------------------------------------------- | | | | | | | | PHY PHY PHY PHY PHY PHY PHY PHY Here is the diagram of separate all ports to three platform(new): CPU | ----------------------------------- | | | ---------------------------------------------- --------- --------- | | | | | | | | | PPE | | PPE | | PPE | | | | | | | | | | | | | | | | | | | | crossbar | | | | | | | | | | | | | | | | | ---------------------------------- | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MAC MAC MAC MAC MAC MAC | | MAC | | MAC | | | | | | | | | | | | | | | ---------------------------------------------- --------- --------- | | | | | | \ / | / | PHY PHY PHY PHY PHY PHY \ / PHY / PHY \ / / \ / / DSAF(three platform device) Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 40 ++---- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 152 +++++++++++++++------ drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.h | 7 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 93 ++++++++----- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h | 12 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 72 ++++++---- drivers/net/ethernet/hisilicon/hns/hns_dsaf_ppe.c | 57 ++------ drivers/net/ethernet/hisilicon/hns/hns_dsaf_ppe.h | 1 - drivers/net/ethernet/hisilicon/hns/hns_dsaf_rcb.c | 53 ++----- drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 15 +- 10 files changed, 261 insertions(+), 241 deletions(-) commit 2e2591b130c43dd241e7aa8b0f2d74dbf3cc334b Author: Daode Huang <huangdaode@hisilicon.com> Date: Sat Apr 23 17:05:10 2016 +0800 net: hns: sort the header file by alphabetical order This patch tunes the header file by the alphabetical order. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 12 ++++++------ drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 12 ++++++------ drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 4 ++-- 3 files changed, 14 insertions(+), 14 deletions(-) commit 86897c960b490e62714f4b123b7d20b04945d773 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:09 2016 +0800 net: hns: add syscon operation for dsaf This patch provides the read/write function for dsaf to access the registers through syscon methods. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 422c3107ed2cc6297f051109f3d4b6d855eaae14 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:08 2016 +0800 net: hns: add attribute reset-field-offset for dsaf node Add the subctrl reset offset for dsaf, this property is used to reset xge/ge ports for different dsaf. If this attribute is not present, default value 0 will be used. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 8 +++++ drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h | 1 + drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 40 +++++++++++++++------- 3 files changed, 37 insertions(+), 12 deletions(-) commit 406adee9a9fc38c11671f26180e694976f45237c Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:07 2016 +0800 net: hns: add attribute port-idx-in-ae in enet node. This patch parse port-idx-in-ae in enet node. In NIC mode of DSAF, all 6 PHYs of service DSAF are taken as ethernet ports to the CPU. The port-idx-in-ae can be 0 to 5. Here is the diagram: +-----+---------------+ | CPU | +-+-+-+---+-+-+-+-+-+-+ | | | | | | | | debug debug service port port port (0) (0) (0-5) In Switch mode of DSAF, all 6 PHYs of service DSAF are taken as physical ports connect to a LAN Switch while the CPU side assume itself have one single NIC connect to this switch. In this case, the port-idx-in-ae will be 0 only. +-----+-----+------+------+ | CPU | +-+-+-+-+-+-+-+-+-+-+-+-+-+ | | service| port(0) debug debug +------------+ port port | switch | (0) (0) +-+-+-+-+-+-++ | | | | | | external port when port-idx-in-ae is not exists, old attribute port-id will be used (only for compatible purpose, not recommended to use port-id in new code). Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 33 +++++------------------ drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 1 - drivers/net/ethernet/hisilicon/hns/hns_enet.c | 17 +++++++++--- drivers/net/ethernet/hisilicon/hns/hns_enet.h | 3 +++ 4 files changed, 22 insertions(+), 32 deletions(-) commit a542458cb7211a5e092c6a3cd6150404a5b1aa46 Author: Daode Huang <huangdaode@hisilicon.com> Date: Sat Apr 23 17:05:06 2016 +0800 net: hns: set debug port irq index to 0 As debug ports are moved from service dsaf to debug dsaf, the interrupts offset should start from 0, So this patch re-defines the offset index of debug ports. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_dsaf_rcb.c | 8 +------- drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 5 +---- 2 files changed, 2 insertions(+), 11 deletions(-) commit 89a440932b6f2eb7fee78dbde05870e2b95e6151 Author: Yisen.Zhuang\(Zhuangyuzeng\) <Yisen.Zhuang@huawei.com> Date: Sat Apr 23 17:05:05 2016 +0800 net: hns: add a new dsaf mode for debug port This patch adds a new dsaf mode named "single-port" mode for debug port. This mode only contains one debug port. This patch also changes the method of distinguishing the port type. Signed-off-by: Daode Huang <huangdaode@hisilicon.com> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 2 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 8 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 16 +-- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h | 2 + drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 4 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_ppe.c | 6 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_rcb.c | 132 ++++++++++----------- drivers/net/ethernet/hisilicon/hns/hns_dsaf_rcb.h | 2 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 1 - 9 files changed, 84 insertions(+), 89 deletions(-) commit dd28216528cf67339cd4f5854166fbd4eefd7fa8 Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 18:37:20 2016 -0500 mailbox/omap: kill omap_mbox_{save/restore}_ctx() functions The omap_mbox_save_ctx() and omap_mbox_restore_ctx() API were previously provided to OMAP mailbox clients to save and restore the mailbox context during system suspend/resume. The save and restore functionality is now implemented through System PM driver callbacks, and there is no need for these functions, so kill these API. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 51 ------------------------------------------ include/linux/omap-mailbox.h | 2 -- 2 files changed, 53 deletions(-) commit 9f0cee984a25a34c169dac67a11d9c951727e47a Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 18:37:19 2016 -0500 mailbox/omap: check for any unread messages during suspend The OMAP mailbox driver is used by clients to communicate with remote processors in general. The mailbox clients are expected to have stopped communicating with these remote processors during a system suspend. The OMAP mailbox fifos are expected to not have any messages as such. Add a check for any pending unprocessed messages in the suspend callback, to detect any communication protocol issues of the mailbox clients. The system suspend is aborted if any messages are found. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit af1d2f5cb9d24f0e477158dada6baf893a32ee04 Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 18:37:18 2016 -0500 mailbox/omap: add support for suspend/resume Support has been added to the OMAP mailbox driver to allow it to work across a system suspend/resume. The OMAP mailbox driver requires only the interrupt configuration registers to be saved and restored, and this is done in the suspend/resume callbacks. The registers need to be saved only if there are active clients at the time of suspend. The enabling and disabling of the mailbox clocks is done automatically by the omap_device layer. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 45 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) commit 2240f8aefcaea151653e70fbf3eef09650fa027c Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 18:37:17 2016 -0500 mailbox/omap: store mailbox interrupt type in omap_mbox_device The interrupt type used for identifying the layout of the interrupt configuration registers between OMAP4+ SoCs and older SoCs is stored only in the sub-mailbox structures for easier access. Store this type in the the omap_mbox_device structure as well along with the other global variables. This is being done to facilitate the context save and restore of appropriate registers during system suspend/resume. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 2 ++ 1 file changed, 2 insertions(+) commit 2665a4c1d456460aea7a2f2bf7113ffdc63077bf Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 12:37:40 2016 -0500 mailbox/omap: add blank lines after declarations Fix couple of checkpatch warnings of the type, "WARNING: Missing a blank line after declarations" Also, fixed a warning about a space after a typecast while at this. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 0196fa3945970170d8c00684b2a7a32d304a66fb Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 12:37:39 2016 -0500 mailbox/omap: remove FSF mailing address paragraph Remove the paragraph about writing to the Free Software Foundation's mailing address from the GPL license header as this address can change. This fixes the corresponding checkpatch warning. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 6 ------ 1 file changed, 6 deletions(-) commit 86f6f5e2e2c0c520dfb0bea336cbda1f190c0357 Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 12:37:38 2016 -0500 mailbox/omap: use variable name for sizeof() operator Fix the code formatting to use the kernel preferred style of using the actual variables to determize the size using the sizeof() operator. This fixes the corresponding checkpatch warning as well. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4899f78a3dccda41ffdaa1a2cbf78209753e0f70 Author: Suman Anna <s-anna@ti.com> Date: Wed Apr 6 12:37:37 2016 -0500 mailbox/omap: drop legacy platform device support OMAP mailbox devices can no longer be created in legacy non-DT mode, all the relevant code has been cleaned up. The OMAP mailbox driver will only support devices created from DT going forward, so drop the legacy platform device support from the driver. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org> drivers/mailbox/omap-mailbox.c | 101 ++++++++++++----------------- include/linux/platform_data/mailbox-omap.h | 58 ----------------- 2 files changed, 41 insertions(+), 118 deletions(-) commit 52c871798ff84b6bfb095c3d3cc69af517f72396 Author: Jean-Francois Moine <moinejf@free.fr> Date: Fri Apr 22 08:47:29 2016 +0200 dmaengine: sun6i: Simplify lli setting Checking the DMA config before setting the lli list avoids to do tests inside the setting loop. Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 102 ++++++++++++++++++++++-------------------------- 1 file changed, 47 insertions(+), 55 deletions(-) commit 9a15da173554f7951812d44179e924b07c4a0f92 Author: Stefan Agner <stefan@agner.ch> Date: Sat Apr 16 21:18:54 2016 -0700 drm/fsl-dcu: implement lastclose callback Use CMA helper drm_fbdev_cma_restore_mode to restore fbdev mode in process which uses drm/kms dies. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 7d17a6264c0cf0ffacfc420553b494376cd93d36 Author: Stefan Agner <stefan@agner.ch> Date: Sat Apr 16 21:17:12 2016 -0700 drm/fsl-dcu: disable output polling on driver unload Disabling output polling before unloading the driver. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 4 ++++ 1 file changed, 4 insertions(+) commit afb49e4d38e7541968de34b73e98d46c841546e1 Author: Stefan Agner <stefan@agner.ch> Date: Sat Apr 16 22:02:49 2016 -0700 drm/fsl-dcu: deallocate fbdev CMA on unload Free fbdev CMA using drm_fbdev_cma_fini on unload. This fixes a warning when unloading the driver: WARNING: CPU: 0 PID: 164 at drivers/gpu/drm/drm_crtc.c:5930 drm_mode_config_cleanup+0x204/0x208 Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit b617966c08a1606bed2f4dc5019ffac7f66e9467 Author: Stefan Agner <stefan@agner.ch> Date: Wed Apr 13 00:14:18 2016 -0700 drm/fsl-dcu: use variable name dev for struct drm_device The driver uses different variable names for struct drm_device across functions which is confusing. Stick to the more common variable name dev. While at it, remove unnecessary if statement in error handling. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) commit b7d11305b89a0d3d13d6087505daed94dde08574 Author: Stefan Agner <stefan@agner.ch> Date: Wed Dec 2 18:03:50 2015 -0800 drm/fsl-dcu: handle missing panel gracefully If the device tree property fsl,panel is missing, drm_panel_attach is called with a NULL pointer as first argument. Having a panel is basically mandatory since RGB is the only supported connector. Check if a panel node has been found, return -ENODEV and cleanup otherwise. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) commit a109f66f4be771eba8df241f22da58323273c635 Author: Stefan Agner <stefan@agner.ch> Date: Wed Mar 23 23:27:11 2016 -0700 drm/fsl-dcu: detach panel on destroy Disable the earlier attached panel on connector destroy. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c | 3 +++ 1 file changed, 3 insertions(+) commit dc6a58c17cd443bfdd2e05c45aec80106d59fdb2 Author: Jean-Francois Moine <moinejf@free.fr> Date: Fri Apr 22 08:17:14 2016 +0200 dmaengine: sun6i: Fix impossible settings of burst and bus width In the commit 1f9cd915b64bb95f ("dmaengine: sun6i: Fix memcpy operation"), the signed values returned by convert_burst() and convert_buswidth() were stored in an unsigned value. Then, these values were considered as errors when non null. As a result, DMA transfers were rejected when the burst or buswidth had values different from 1, as 8 for the burst or 4 for the bus width. Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 128fe7e9a0b99da1d7346528526bd424f705774b Author: Jean-Francois Moine <moinejf@free.fr> Date: Fri Apr 22 08:14:33 2016 +0200 dmaengine: sun6i: Fix the access of the IRQ register The IRQ register number is computed, but this number was not used and the register was the one indexed by the channel index instead. Then, only the first DMA channel was working. Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/sun6i-dma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e093bf60ca498a03b4ea8f5d6cf1d520a68e5d2e Author: Robert Jarzmik <robert.jarzmik@free.fr> Date: Mon Mar 28 23:32:24 2016 +0200 dmaengine: pxa: handle bus errors In the current state, upon bus error the driver will spin endlessly, relaunching the last tx, which will fail again and again : - a bus error happens - pxad_chan_handler() is called - as PXA_DCSR_STOPSTATE is true, the last non-terminated transaction is lauched, which is the one triggering the bus error, as it didn't terminate - moreover, the STOP interrupt fires a new, as the STOPIRQEN is still active Break this logic by stopping the automatic relaunch of a dma channel upon a bus error, even if there are still pending issued requests on it. As dma_cookie_status() seems unable to return DMA_ERROR in its current form, ie. there seems no way to mark a DMA_ERROR on a per-async-tx basis, it is chosen in this patch to remember on the channel which transaction failed, and report it in pxad_tx_status(). It's a bit misleading because if T1, T2, T3 and T4 were queued, and T1 was completed while T2 causes a bus error, the status of T3 and T4 will be reported as DMA_IN_PROGRESS, while the channel is actually stopped. Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/pxa_dma.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit a5dab991398996aaef658641a707ae09e002db6b Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Feb 22 22:33:31 2016 +0100 drm/layerscape: reduce excessive stack usage The fsl-dcu driver copies a drm_mode_config object to its stack but then only accesses a single member (dpms_property) once. The data structure is large enough to trigger a warning about the amount of kernel stack being used: drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c: In function 'fsl_dcu_drm_connector_create': drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c:182:1: error: the frame size of 1040 bytes is larger than 1024 bytes [-Werror=frame-larger-than=] This changes the fsl_dcu_drm_connector_create() function to only access the drm_mode_config by reference, which is also more efficient. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 109eee2f2a18 ("drm/layerscape: Add Freescale DCU DRM driver") Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fb127b7943c9262f5d95f402922d92b9d6c1dad2 Author: Stefan Agner <stefan@agner.ch> Date: Wed Dec 2 14:39:40 2015 -0800 drm/fsl-dcu: add TCON driver Add driver for the TCON (timing controller) module. The TCON module is a separate module attached after the DCU (display controller unit). Each DCU instance has its own, directly connected TCON instance. The DCU's RGB and timing signals are passing through the TCON module. TCON can provide timing signals for raw TFT panels or operate in a bypass mode which leaves all signals unaltered. The driver currently only supports the bypass mode. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Stefan Agner <stefan@agner.ch> .../devicetree/bindings/display/fsl,dcu.txt | 4 + .../devicetree/bindings/display/fsl,tcon.txt | 18 ++++ MAINTAINERS | 1 + drivers/gpu/drm/fsl-dcu/Makefile | 3 +- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 3 + drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.h | 1 + drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_rgb.c | 11 ++ drivers/gpu/drm/fsl-dcu/fsl_tcon.c | 111 +++++++++++++++++++++ drivers/gpu/drm/fsl-dcu/fsl_tcon.h | 33 ++++++ 9 files changed, 184 insertions(+), 1 deletion(-) commit 2d701449bce1b7ddb0a7d85de7479c7422ee0e42 Author: Stefan Agner <stefan@agner.ch> Date: Tue Mar 22 18:06:08 2016 -0700 drm/fsl-dcu: use common clock framework for pixel clock divider Use the common clock framework to calculate the pixel clock dividier. The previous implementation rounded down the calculated factor. Thanks to the CLK_DIVIDER_ROUND_CLOSEST flag using the common clock framework divider implementation improves the pixel clock accuracy in some cases. Ontop of that it also allows to see the actual pixel clock in the sysfs clock summary. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_crtc.c | 7 ++----- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 26 ++++++++++++++++++++++---- 2 files changed, 24 insertions(+), 9 deletions(-) commit f93500f430733178dfd8f9c80e52b13d0f273dd3 Author: Stefan Agner <stefan@agner.ch> Date: Tue Mar 22 15:45:29 2016 -0700 drm/fsl-dcu: add extra clock for pixel clock The Vybrid DCU variant has two independent clock inputs, one for the registers (IPG bus clock) and one for the pixel clock. Support this distinction in the DCU DRM driver while staying backward compatible for old device trees. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Stefan Agner <stefan@agner.ch> Documentation/devicetree/bindings/display/fsl,dcu.txt | 11 +++++++---- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_crtc.c | 2 +- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 16 +++++++++++++++- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.h | 1 + 4 files changed, 24 insertions(+), 6 deletions(-) commit 73fa30337a936695eeebecfa2c48ff567361c793 Author: Stefan Agner <stefan@agner.ch> Date: Tue Mar 22 15:13:05 2016 -0700 drm/fsl-dcu: disable clock on initialization failure and remove Fix error handling during probe by reordering initialization and adding a error path which disables clock again. Also disable the clock on remove. Signed-off-by: Stefan Agner <stefan@agner.ch> drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 44 +++++++++++++++---------------- 1 file changed, 21 insertions(+), 23 deletions(-) commit bb4b4e93febc139003e2af2f36e438df58b4803c Author: Stuart Yoder <stuart.yoder@nxp.com> Date: Tue Apr 19 16:53:17 2016 -0500 arm64: dts: ls2080a: fsl-mc dt node updates updates to the fsl-mc node for full functionality: -msi-parent is needed for interrupt support -ranges is needed to enable the bus driver to translate bus addresses -dpmac nodes provide a basis for relating dpmac objects to PHYs Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi | 98 ++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) commit 852224038560768f919af83ca2015f0d31be82c1 Author: Stuart Yoder <stuart.yoder@freescale.com> Date: Tue Apr 19 16:53:08 2016 -0500 Documentation: fsl-mc: binding updates for MSIs, ranges, PHYs -The Freescale Management Complex and all associated objects use message interrupts, and thus an msi-parent is required. -Define a ranges property to specify the mapping between the MC address space and the system address space. -The fsl-mc node may optionally have dpmac sub-nodes that describe the relationship between the Ethernet MACs which belong to the MC and the Ethernet PHYs on the system board. Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com> Acked-by: J. German Rivera <German.Rivera@nxp.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> .../devicetree/bindings/misc/fsl,qoriq-mc.txt | 81 +++++++++++++++++++++- 1 file changed, 80 insertions(+), 1 deletion(-) commit c8585c6fcaf2011de54c3592e80a634a2b9e1a7f Author: Daeho Jeong <daeho.jeong@samsung.com> Date: Mon Apr 25 23:22:35 2016 -0400 ext4: fix races between changing inode journal mode and ext4_writepages In ext4, there is a race condition between changing inode journal mode and ext4_writepages(). While ext4_writepages() is executed on a non-journalled mode inode, the inode's journal mode could be enabled by ioctl() and then, some pages dirtied after switching the journal mode will be still exposed to ext4_writepages() in non-journaled mode. To resolve this problem, we use fs-wide per-cpu rw semaphore by Jan Kara's suggestion because we don't want to waste ext4_inode_info's space for this extra rare case. Signed-off-by: Daeho Jeong <daeho.jeong@samsung.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Jan Kara <jack@suse.cz> fs/ext4/ext4.h | 4 ++++ fs/ext4/inode.c | 15 ++++++++++++--- fs/ext4/super.c | 4 ++++ kernel/locking/percpu-rwsem.c | 1 + 4 files changed, 21 insertions(+), 3 deletions(-) commit c0b20d6f4113313d8cd0566aa30f337d3697ac75 Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Tue Apr 19 12:30:01 2016 -0400 ARM: dts: imx6q-ba16: use wdog external reset The BA16 module has a PMIC that uses the WDOG_B output from iMX6 to reset the system on a watchdog timeout. Configure the watchdog to assert the external reset signal (WDOG_B) using fsl,ext-reset-output property. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-ba16.dtsi | 1 + 1 file changed, 1 insertion(+) commit 4c54659269ecb799133758330e7ea2a6fa4c65ca Author: Daeho Jeong <daeho.jeong@samsung.com> Date: Mon Apr 25 23:21:00 2016 -0400 ext4: handle unwritten or delalloc buffers before enabling data journaling We already allocate delalloc blocks before changing the inode mode into "per-file data journal" mode to prevent delalloc blocks from remaining not allocated, but another issue concerned with "BH_Unwritten" status still exists. For example, by fallocate(), several buffers' status change into "BH_Unwritten", but these buffers cannot be processed by ext4_alloc_da_blocks(). So, they still remain in unwritten status after per-file data journaling is enabled and they cannot be changed into written status any more and, if they are journaled and eventually checkpointed, these unwritten buffer will cause a kernel panic by the below BUG_ON() function of submit_bh_wbc() when they are submitted during checkpointing. static int submit_bh_wbc(int rw, struct buffer_head *bh,... { ... BUG_ON(buffer_unwritten(bh)); Moreover, when "dioread_nolock" option is enabled, the status of a buffer is changed into "BH_Unwritten" after write_begin() completes and the "BH_Unwritten" status will be cleared after I/O is done. Therefore, if a buffer's status is changed into unwrutten but the buffer's I/O is not submitted and completed, it can cause the same problem after enabling per-file data journaling. You can easily generate this bug by executing the following command. ./kvm-xfstests -C 10000 -m nodelalloc,dioread_nolock generic/269 To resolve these problems and define a boundary between the previous mode and per-file data journaling mode, we need to flush and wait all the I/O of buffers of a file before enabling per-file data journaling of the file. Signed-off-by: Daeho Jeong <daeho.jeong@samsung.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Jan Kara <jack@suse.cz> fs/ext4/inode.c | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) commit 025ce02d92b67d6c702676c11f7f1f5e8f0a81fa Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 12:13:54 2016 -0400 mtd: maps: make uclinux.c driver more explicitly non-modular The Kconfig for this support is currently declared with: config MTD_UCLINUX bool "Generic uClinux RAM/ROM filesystem support" ...meaning that it currently is not being built as a module by anyone. Lets remove as much of the modular evidence that we can, so that when reading the driver there is less doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also replace module.h with moduleparam.h since the file does use a module_param, and leaving it as such is currently the easiest way to remain compatible with existing boot arg use cases. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: David Woodhouse <dwmw2@infradead.org> Cc: Greg Ungerer <gerg@snapgear.com> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/maps/uclinux.c | 27 ++++----------------------- 1 file changed, 4 insertions(+), 23 deletions(-) commit 7b8081912d75df1d910d6969f0a374b66ef242bf Author: Theodore Ts'o <tytso@mit.edu> Date: Mon Apr 25 23:13:17 2016 -0400 ext4: fix jbd2 handle extension in ext4_ext_truncate_extend_restart() The function jbd2_journal_extend() takes as its argument the number of new credits to be added to the handle. We weren't taking into account the currently unused handle credits; worse, we would try to extend the handle by N credits when it had N credits available. In the case where jbd2_journal_extend() fails because the transaction is too large, when jbd2_journal_restart() gets called, the N credits owned by the handle gets returned to the transaction, and the transaction commit is asynchronously requested, and then start_this_handle() will be able to successfully attach the handle to the current transaction since the required credits are now available. This is mostly harmless, but since ext4_ext_truncate_extend_restart() returns EAGAIN, the truncate machinery will once again try to call ext4_ext_truncate_extend_restart(), which will do the above sequence over and over again until the transaction has committed. This was found while I was debugging a lockup in caused by running xfstests generic/074 in the data=journal case. I'm still not sure why we ended up looping forever, which suggests there may still be another bug hiding in the transaction accounting machinery, but this commit prevents us from looping in the first place. Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/extents.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 15ef03b8624724ed1b7e660e14d310fa54be393f Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Mon Apr 18 17:19:45 2016 -0400 ARM: dts: imx: b450/b650v3: Move ldb_di clk assignment Previously the LDB_DIx clocks could be specified in the ldb node. With the ERR009219 errata fix applied, the ldb_di clocks now needs to be specified in the clks node to ensure the clocks are setup early in the boot process. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-b450v3.dts | 5 ++++- arch/arm/boot/dts/imx6q-b650v3.dts | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) commit b492b8744da9b205b9b303b111a138b16d56e712 Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Mon Apr 18 17:19:44 2016 -0400 ARM: dts: imx6q-b850v3: Update display clock source The default monitor that ships with B850v3 requires a 65MHz pixel clock. 65MHz can not be achieved using PLL3 (480MHz/7=68.5MHz). Hence set the LDB_DIx clock source to PLL5. Since PLL5 is already in use by IPU1_DIx, set the clock source for IPU1_DIx to PLL2_PFD2 to allow simultaneous display on both LVDS and HDMI interface. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-b850v3.dts | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) commit 7532c98f3ac212ca1f19be7e628356247b616c74 Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Mon Apr 18 17:19:43 2016 -0400 ARM: dts: imx6q-b850v3: Remove ldb panel Remove ldb panel entry for the following reasons: - The b850v3 has an onboard LVDS to DisplayPort converter (STDP4028). So we should not limit the monitors that can be connected by hardcoding the auo,b133htn01 1080p panel. - The default resolution on the LVDS interface needs to be WXGA or less. Otherwise when a 1080p monitor is connected to the HDMI port there is no output on both the LVDS and HDMI ports since a single IPU on i.MX6 can not handle two 1080p displays. With the panel entry removed from the devicetree, drm driver defaults the resolution on LVDS interface to XGA. Once in userspace, applications can set the desired resolution on LVDS interface over IPU2 CRTC. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-b850v3.dts | 20 -------------------- 1 file changed, 20 deletions(-) commit 205506228b69be4efbb3809957a69420f26a8d9f Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Mon Apr 25 22:40:12 2016 -0400 tracing: Do not inherit event-fork option for instances As the event-fork option requires doing work when enabled and disabled, it can not be passed down to created instances. The instance must clear this flag when it is created, and must clear it when its removed. As more options may be created with this need, a macro ZEROED_TRACE_FLAGS is created that holds the flags that must not be inherited by the top level instance, and must be cleared on removal of instances. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 71d397581d52c24c9903d9729aae09828f956801 Author: Finn Thain <fthain@telegraphics.com.au> Date: Sat Apr 23 12:20:07 2016 +1000 MAINTAINERS: Update the file list for the NCR 5380 entry The file atari_NCR5380.c has been removed from the tree so remove it from the MAINTAINERS file as well. While we are here, add the file dtc3x80.txt as it is only relevant to the dtc driver. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5e4fabb6eb058f6d473e22b6db3ef299acf00f1c Author: Kai Makisara <Kai.Makisara@kolumbus.fi> Date: Mon Apr 18 08:47:18 2016 +0300 st: clear ILI if Medium Error Some drives set the ILI flag together with MEDIUM ERROR sense code. Clear the ILI flag in this case so that the medium error will be handled. The problem was reported by Maurizio Lombardi. Signed-off-by: Kai Mäkisara <kai.makisara@kolumbus.fi> Reviewed-by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/st.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 718924180a6a79afa558bd978c8a3436c39691ff Author: Sebastian Herbszt <herbszt@gmx.de> Date: Sun Apr 17 13:27:27 2016 +0200 lpfc: remove incorrect lockdep assertion Remove incorrect lockdep assertion from lpfc_sli_hbqbuf_find() which acquires the hbalock itself. Fix the comment which resulted in this mistake. Fixes: 1c2ba475eb0e ("lpfc: Add lockdep assertions") Signed-off-by: Sebastian Herbszt <herbszt@gmx.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_sli.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 9c8a76d5f00dbfd1da6ea242a9263a47133e4053 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:40:06 2016 +0300 bnx2i: silence uninitialized variable warnings Presumably it isn't possible to have empty lists here, but my static checker doesn't know that and complains that "ep" can be used uninitialized. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Nilesh Javali <nilesh.javali@qlogic.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2i/bnx2i_iscsi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit aa105695732daa6604cb017ceb59a05ef34956bd Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:37:44 2016 +0300 hpsa: set the enclosure identifier to zero This has only called from show_sas_rphy_enclosure_identifier(). The caller expects that we set an identifier, otherwise it uses an uninitialized variable. [mkp: fixed typo] Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Don Brace <don.brace@microsemi.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hpsa.c | 1 + 1 file changed, 1 insertion(+) commit b8ac0cc78b56e798851f1435bc673761d3fb877e Author: Joe Lawrence <joe.lawrence@stratus.com> Date: Mon Apr 18 10:50:12 2016 -0400 mpt3sas - remove unused fw_event_work elements Firmware events are queued up using the fw_event_work's struct work, not its delayed_work member. The initial driver for SAS2 controllers had handled firmware reset using the rescan barrier and was later redesigned through "mpt2sas: [Resend] Host Reset code cleanup". The delayed_work variables are now unused and may provoke CONFIG_DEBUG_OBJECTS_TIMERS "assert_init not available" false warnings in _scsih_fw_event_cleanup_queue. Cleanup fw_event_work's unused entries, update its kerneldoc, and update _scsih_fw_event_cleanup_queue accordingly. Fixes: 146b16c8071f (mpt3sas: Refcount fw_events and fix unsafe list usage) Signed-off-by: Joe Lawrence <joe.lawrence@stratus.com> Acked-by: Chaitra P B <chaitra.basappa@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_scsih.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 1fcbcc333f1fae6e11cc0839a6e72bc1a3e830bf Author: Shaohua Li <shli@fb.com> Date: Mon Apr 25 16:50:14 2016 -0700 block: copy NOMERGE flag from bio to request bio might have NOMERGE flag set, for example blk_queue_split sets it. When we initiate request, copy this flag too. Signed-off-by: Shaohua Li <shli@fb.com> Signed-off-by: Jens Axboe <axboe@fb.com> include/linux/blk_types.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 49bdedb36271fe6259dd251bb63c5879fa7834e1 Author: Jeff Moyer <jmoyer@redhat.com> Date: Mon Apr 25 19:12:38 2016 -0600 skd: remove broken discard support Simply creating a file system on an skd device, followed by mount and fstrim will result in errors in the logs and then a BUG(). Let's remove discard support from that driver. As far as I can tell, it hasn't worked right since it was merged. This patch also has a side-effect of cleaning up an unintentional shadowed declaration inside of skd_end_request. I tested to ensure that I can still do I/O to the device using xfstests ./check -g quick. I didn't do anything more extensive than that, though. Signed-off-by: Jeff Moyer <jmoyer@redhat.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/block/skd_main.c | 59 +----------------------------------------------- 1 file changed, 1 insertion(+), 58 deletions(-) commit e93e59ce5b85e6c2b444f09fd1f707274ec066dc Author: Daniel Lezcano <daniel.lezcano@linaro.org> Date: Thu Apr 21 10:56:30 2016 +0200 cpuidle: Replace ktime_get() with local_clock() The ktime_get() can have a non negligeable overhead, use local_clock() instead. In order to test the difference between ktime_get() and local_clock(), a quick hack has been added to trigger, via debugfs, 10000 times a call to ktime_get() and local_clock() and measure the elapsed time. Then the average value, the min and max is computed for each call. From userspace, the test above was called 100 times every 2 seconds. So, ktime_get() and local_clock() have been called 1000000 times in total. The results are: ktime_get(): ============ * average: 101 ns (stddev: 27.4) * maximum: 38313 ns * minimum: 65 ns local_clock(): ============== * average: 60 ns (stddev: 9.8) * maximum: 13487 ns * minimum: 46 ns The local_clock() is faster and more stable. Even if it is a drop in the ocean, changing the ktime_get() by the local_clock() allows to save 80ns at idle time (entry + exit). And in some circumstances, especially when there are several CPUs racing for the clock access, we save tens of microseconds. The idle duration resulting from a diff is converted from nanosec to microsec. This could be done with integer division (div 1000) - which is an expensive operation or by 10 bits shifting (div 1024) - which is fast but unprecise. The following table gives some results at the limits. ------------------------------------------ | nsec | div(1000) | div(1024) | ------------------------------------------ | 1e3 | 1 usec | 976 nsec | ------------------------------------------ | 1e6 | 1000 usec | 976 usec | ------------------------------------------ | 1e9 | 1000000 usec | 976562 usec | ------------------------------------------ There is a linear deviation of 2.34%. This loss of precision is acceptable in the context of the resulting diff which is used for statistics. These ones are processed to guess estimate an approximation of the duration of the next idle period which ends up into an idle state selection. The selection criteria takes into account the next duration based on large intervals, represented by the idle state's target residency. The 2^10 division is enough because the approximation regarding the 1e3 division is lost in all the approximations done for the next idle duration computation. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> [ rjw: Subject ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpuidle/cpuidle.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit f0fb0dd0a715bd29caf9c55cf4a2a52a14a8fd61 Merge: b5ebbcd 5dcef69 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Apr 26 02:30:00 2016 +0200 Merge back earlier cpuidle changes for v4.7. commit b5ebbcdb53260991a82a8800480dcb06dcffeef9 Merge: 02da2d7 5e7c17d Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Apr 26 02:28:57 2016 +0200 Merge branch 'cpuidle/4.7' of http://git.linaro.org/people/daniel.lezcano/linux into tmp Pull ARM cpuidle changes for v4.7 from Daniel Lezcano. * 'cpuidle/4.7' of http://git.linaro.org/people/daniel.lezcano/linux: drivers: firmware: psci: use const and __initconst for psci_cpuidle_ops soc: qcom: spm: Use const and __initconst for qcom_cpuidle_ops ARM: cpuidle: constify return value of arm_cpuidle_get_ops() ARM: cpuidle: add const qualifier to cpuidle_ops member in structures commit 2b9cf18982b0ba7317f258663560e181594a9bf8 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 02:13:30 2016 +0200 drivers: firmware: psci: make two helper functions inline The previous patch marked these two as 'static' which showed that they are sometimes unused: drivers/firmware/psci.c:103:13: error: 'psci_power_state_is_valid' defined but not used [-Werror=unused-function] static bool psci_power_state_is_valid(u32 state) drivers/firmware/psci.c:94:13: error: 'psci_power_state_loses_context' defined but not used [-Werror=unused-function] static bool psci_power_state_loses_context(u32 state) This also marks the functions 'inline', which has the main effect of silently ignoring them when they are unused. The compiler will typically inline small static functions anyway, so this seems more appropriate than using __maybe_unused, which would have the same result otherwise. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 21e8868 ("drivers: firmware: psci: make two helper functions static") drivers/firmware/psci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 23f1e2ecdecee9f2ec45de0a468b82bb1f7f3ca2 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:46 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car H3 power areas Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 1 + drivers/soc/renesas/r8a7795-sysc.c | 56 ++++++++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 ++ drivers/soc/renesas/rcar-sysc.h | 1 + 4 files changed, 61 insertions(+) commit 9af1dbcc3028e1de8cac2d7e32345965353edde0 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:45 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car E2 power areas Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 2 +- drivers/soc/renesas/r8a7794-sysc.c | 33 +++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 +++ drivers/soc/renesas/rcar-sysc.h | 1 + 4 files changed, 38 insertions(+), 1 deletion(-) commit a247eb93ef73b56aab68c47608245e2b4a713585 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:44 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car M2-N power areas R-Car M2-N is identical to R-Car M2-W w.r.t. power domains, so reuse the definitions from the latter. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 3 ++- drivers/soc/renesas/rcar-sysc.c | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) commit c5fbb3c08897c8941852e9096f8507785d8a18f2 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:43 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car M2-W power areas Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 2 +- drivers/soc/renesas/r8a7791-sysc.c | 33 +++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 +++ drivers/soc/renesas/rcar-sysc.h | 1 + 4 files changed, 38 insertions(+), 1 deletion(-) commit ad7c9dbc25d19c2fbf4414a8cb4f02f7933611d6 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:42 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car H2 power areas Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 2 +- drivers/soc/renesas/r8a7790-sysc.c | 48 ++++++++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 +++ drivers/soc/renesas/rcar-sysc.h | 1 + 4 files changed, 53 insertions(+), 1 deletion(-) commit 9b83ea17b0d9b5461ee46a2f5a668e6b10743f1a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:41 2016 +0200 soc: renesas: rcar-sysc: Add support for R-Car H1 power areas Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/Makefile | 2 +- drivers/soc/renesas/r8a7779-sysc.c | 34 ++++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 +++ drivers/soc/renesas/rcar-sysc.h | 1 + 4 files changed, 39 insertions(+), 1 deletion(-) commit 1c8c77f52d1037c61468539e1d68c44f9e710536 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:40 2016 +0200 soc: renesas: rcar-sysc: Enable Clock Domain for I/O devices On R-Car H3, some power areas (e.g. A3VP) contain I/O devices, which are also part of the CPG/MSSR Clock Domain. On all R-Car SoCs, devices in the "always-on" PM Domain are part of the Clock Domain served by the CPG/MSSR or CPG/MSTP driver. Hook up the CPG/MSTP or CPG/MSSR Clock Domain attach/detach callbacks to enable power management using module clocks. Which callback to hook up depends on the presence of device nodes compatible with "renesas,cpg-mstp-clocks". This clears the path for a future migration from the CPG/MSTP to the CPG/MSSR driver on R-Car H1 and Gen2. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/rcar-sysc.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 09623d79466e996f5dc2753e16f04fda6f078041 Author: Kan Liang <kan.liang@intel.com> Date: Sun Apr 24 23:28:09 2016 -0700 perf hists: Clear dummy entry accumulated period The accumulated period for dummy entry should also be 0. Otherwise, the total overhead could be overcounted. $ perf record -e '{LLC-load-misses,cpu/instructions/}' --call-graph=lbr ./tchain $ perf report --stdio # To display the perf.data header info, please use --header/--header-only options. # # Total Lost Samples: 0 # # Samples: 21K of event 'anon group { LLC-load-misses, cpu/instructions/ }' # Event count (approx.): 16313667937 # # Children Self Command Shared Object Symbol # ................ ................ ........... ................ ............................ # 4769.98% 0.01% 0.00% 0.01% tchain_edit [kernel.vmlinux] [k] update_fast_timekeeper 4356.18% 0.01% 0.00% 0.01% tchain_edit [kernel.vmlinux] [k] trigger_load_balance 3181.12% 0.01% 0.00% 0.01% tchain_edit [kernel.vmlinux] [k] irq_work_tick 1592.37% 0.00% 0.00% 0.00% tchain_edit [kernel.vmlinux] [k] cpu_needs_another_gp Signed-off-by: Kan Liang <kan.liang@intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/r/1461565689-5862-1-git-send-email-kan.liang@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/hist.c | 2 ++ 1 file changed, 2 insertions(+) commit c0664893050cc6b2d8b02d3e035f82fbfd0cd4cf Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 19:56:43 2016 +0100 perf intel-pt: Fix off-by-one comparison on maximum code The check for the maximum code is off-by-one; the current comparison of a code that is INTEL_PT_ERR_MAX will cause the strlcpy to perform an out of bounds array access on the intel_pt_err_msgs array. Fix this with a >= comparison. Signed-off-by: Colin Ian King <colin.king@canonical.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461524203-10224-1-git-send-email-colin.king@canonical.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/intel-pt-decoder/intel-pt-decoder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 73b1794e252b0476cc6e46461c7612cbaa88be45 Author: Davidlohr Bueso <dave@stgolabs.net> Date: Wed Apr 20 20:14:07 2016 -0700 perf bench futex: Simplify wrapper for LOCK_PI Given that the 'val' parameter is ignored for FUTEX_LOCK_PI, get rid of the bogus deadlock detection flag in the wrapper code and avoid the extra argument, making it resemble its unlock counterpart. And if nothing else, we already only pass 0 anyway. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Davidlohr Bueso <dbueso@suse.de> Link: http://lkml.kernel.org/r/1461208447-29328-1-git-send-email-dave@stgolabs.net Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/bench/futex-lock-pi.c | 2 +- tools/perf/bench/futex.h | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) commit 8daef508b0a144970e5cbc587525c351663fec63 Author: Colin Ian King <colin.king@canonical.com> Date: Sat Apr 23 14:45:54 2016 +0100 perf tests: Replace assignment with comparison on assert check The current assert check is checking an assignment, which will always be true. Instead, the assert should be checking if scale is equal to 0.122 Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461419154-16918-1-git-send-email-colin.king@canonical.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/event_update.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c5f9d6b1379a4584b47dd80271ab3a6883f979a9 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 01:01:40 2016 +0200 physmap_of: ensure versatile code is reachable With the newly added physmap_of_versatile code, we get a build error when physmap_of is in a module, because of_flash_probe_versatile is not exported: ERROR: "of_flash_probe_versatile" [drivers/mtd/maps/physmap_of.ko] undefined! This adds the export, and changes the Makefile so that the code is also put into a loadable module rather than built-in when physmap_of itself is a module. Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/mtd/maps/Makefile | 4 +++- drivers/mtd/maps/physmap_of_versatile.c | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) commit 8d3fd357a28e420b1e154daf1cabdaa103911c08 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Mon Apr 25 16:08:09 2016 -0700 soc: brcmstb: Unmap sun_top_ctrl_base on errors Do not leak a ioremap()'d cookie around, unmaping it in case of errors Fixes: cef4bafcea2c ("soc: brcmstb: add SoC driver to brcmstb") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/soc/brcmstb/common.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit d3829c1b8443a83324419eb129c7e4c780bf435f Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 00:53:40 2016 +0200 soc: brcmstb: select SOC_BUS The newly added code for the SoC bus fails to link if the bus is not built: drivers/soc/built-in.o: In function `brcmstb_soc_device_init': :(.init.text+0x110): undefined reference to `soc_device_register' This adds a 'select' statement to avoid the error. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: cef4bafcea2c ("soc: brcmstb: add SoC driver to brcmstb") Acked-by: Florian Fainelli <f.fainelli@gmail.com> drivers/soc/brcmstb/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 55441070ca1cbd47ce1ad2959bbf4b47aed9b83b Author: Glenn Ruben Bakke <glennrubenbakke@nordicsemi.no> Date: Fri Apr 22 18:06:11 2016 +0200 Bluetooth: 6lowpan: Fix memory corruption of ipv6 destination address The memcpy of ipv6 header destination address to the skb control block (sbk->cb) in header_create() results in currupted memory when bt_xmit() is issued. The skb->cb is "released" in the return of header_create() making room for lower layer to minipulate the skb->cb. The value retrieved in bt_xmit is not persistent across header creation and sending, and the lower layer will overwrite portions of skb->cb, making the copied destination address wrong. The memory corruption will lead to non-working multicast as the first 4 bytes of the copied destination address is replaced by a value that resolves into a non-multicast prefix. This fix removes the dependency on the skb control block between header creation and send, by moving the destination address memcpy to the send function path (setup_create, which is called from bt_xmit). Signed-off-by: Glenn Ruben Bakke <glenn.ruben.bakke@nordicsemi.no> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Cc: stable@vger.kernel.org # 4.5+ net/bluetooth/6lowpan.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit d16415b2627e91a45778e1888bfdd5c6744294bf Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 10:37:56 2016 -0400 i2c: s3c2410: Check clk_prepare_enable() return value The clk_prepare_enable() function can fail so check the return value and propagate the error in case of a failure. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 8f8edd491ac64c3cfe4e8ffff2b7385df5c02860 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 10:37:55 2016 -0400 i2c: s3c2410: Print errno code in error logs The driver not always prints the error code in case of a failure but this information can be very useful for debugging. So let's print if available. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 0915833bd5f9987fdcdb491da1e75026bae05683 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Thu Apr 21 09:04:51 2016 +0200 i2c: s3c2410: Cleanup indentation and comment style Improve the readability by: - fixing indentation, - switching to proper block comments, - removing spurious blank lines, - checkpatch: void function return statements are not generally useful, - checkpatch: braces {} are not necessary for any arm of this statement, - checkpatch: missing a blank line after declarations. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 113 ++++++++++++++++++++------------------- 1 file changed, 57 insertions(+), 56 deletions(-) commit ec7c34a4c6c71487a5de4c1b2d47beb2c334aa0d Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Thu Apr 21 09:04:50 2016 +0200 i2c: s3c2410: Minor function-level comment cleanup Cleanup the weird function-level comments and remove obvious documentation for probe/remove. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 110 ++++++++++++--------------------------- 1 file changed, 32 insertions(+), 78 deletions(-) commit b1b3df2fc808187e3c9e50162b55fb458035b0ab Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Thu Apr 21 09:04:49 2016 +0200 i2c: s3c2410: Add missing clock unprepare on probe() error path If during probe() the s3c24xx_i2c_init() failed, the clock was left in disabled but prepared state. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 1 + 1 file changed, 1 insertion(+) commit d81e72c521d46ca43c1afd2e2577d5a09279196f Merge: d9e742f 5d7e23a Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 00:22:44 2016 +0200 Merge tag 'omap-for-v4.6/dt-ti81xx-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/dt Enable dm814x and dra62x clock driver. This branch has a dependency to the clk-ti branch from the Linux clk tree for the ADPLL clock driver. Otherwise things won't keep booting properly when we flip over to use the clock driver instead of fixed clocks set up by the bootloader. * tag 'omap-for-v4.6/dt-ti81xx-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: dts: Add clocks for dm814x ADPLL Signed-off-by: Arnd Bergmann <arnd@arndb.de> commit 01bbcdffa90d13f61d8034ef82a68484edbc2f5c Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 15 19:48:29 2016 +0900 ARM: uniphier: correct the call order of of_node_put() Put nodes after of_address_to_resource() in case the nodes might be released while parsing in them. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/mach-uniphier/platsmp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a3003158b14d0d7eccbb957a1a449d80bcf05f93 Merge: 7d912ba2 a4b8c18 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 00:10:37 2016 +0200 Merge tag 'renesas-soc-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/soc Merge "Renesas ARM Based SoC Updates for v4.7" from Simon Horman: Drop support for Cortex A8 in timer code * tag 'renesas-soc-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: ARM: shmobile: timer: Drop support for Cortex A8 ARM: shmobile: timer: Fix preset_lpj leading to too short delays Revert "ARM: dts: porter: Enable SCIF_CLK frequency and pins" ARM: dts: r8a7791: Don't disable referenced optional clocks commit 7d912ba2948a60d5f334b74d6485a1e57fd0ecf2 Merge: c323061 8a9d088 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 00:09:21 2016 +0200 Merge tag 'davinci-for-v4.7/soc' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/soc Merge "DaVinci SoC updates for v4.7" from Sekhar Nori: These are preparatory patches to support a USB PHY driver for USB on DA850 SoC. This should eventually lead to USB working again on this device. * tag 'davinci-for-v4.7/soc' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: davinci: clk: add set_parent callback for mux clocks ARM: davinci: da8xx: move usb code to new file ARM: davinci: use IRQCHIP_DECLARE for cp_intc ARM: davinci: remove unused DA8XX_NUM_UARTS ARM: davinci: simplify call to of populate ARM: DaVinci USB: removed deprecated properties from MUSB config commit d8fa1c73c27ccc5129b2096f173febca3cf80a0f Merge: f8433ac 9a7f2fc Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Apr 26 00:00:25 2016 +0200 Merge tag 'davinci-for-v4.7/cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/cleanup Merge "DaVinci cleanups for v4.7" from Sekhar Nori: It includes removal of some unused macros and data- -structures and use of helper macros to reduce code. * tag 'davinci-for-v4.7/cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: davinci: use IRQCHIP_DECLARE for cp_intc ARM: davinci: remove unused DA8XX_NUM_UARTS ARM: davinci: simplify call to of populate ARM: DaVinci USB: removed deprecated properties from MUSB config commit d3e2442b51c33c77a7d409ddcec4805b7ad991c4 Merge: c6ba3f6 b853cb9 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:50:41 2016 +0200 Merge tag 'qcom-soc-for-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux into next/drivers Merge "Qualcomm ARM Based SoC Updates for v4.7 part 2" from Andy Gross: * Change SMD callback parameters * Use writecombine mapping for SMEM * tag 'qcom-soc-for-4.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux: soc: qcom: smd: Make callback pass channel reference soc: qcom: smem: Use write-combine remap for SMEM commit 4729cbe038fdd321839d7780ee93ce1ccf1e7b29 Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 25 16:33:35 2016 +0200 i2c: octeon: Add support for cn78xx chips cn78xx has a different interrupt architecture, so we have to manage the interrupts differently. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> .../devicetree/bindings/i2c/i2c-octeon.txt | 6 + drivers/i2c/busses/i2c-octeon.c | 129 +++++++++++++++++++-- 2 files changed, 125 insertions(+), 10 deletions(-) commit c6ba3f693297fb900ad7435cc963abd2582b1176 Merge: 21e8868 b0ec633 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:48:29 2016 +0200 Merge tag 'arm-soc/for-4.7/drivers' of http://github.com/Broadcom/stblinux into next/drivers Merge "Broadcom ARM-based SoCs drivers changes" from Florian Fainelli: - Justin adds a soc_dev driver to properly report to user-space the Broadcom STB SoC family, product and revision - Florian reworks how the brcmstb_gisb driver dependency is done to enable it on Broadcom STB MIPS-based SoCs and remove a select in arch/arm/mach-bcm/Kconfig * tag 'arm-soc/for-4.7/drivers' of http://github.com/Broadcom/stblinux: bus: brcmstb_gisb: Rework dependencies soc: brcmstb: add SoC driver to brcmstb commit 21e8868e661ededd2c45c8ec27f6fd5354b88b71 Author: Jisheng Zhang <jszhang@marvell.com> Date: Wed Apr 20 11:20:28 2016 +0100 drivers: firmware: psci: make two helper functions static psci_power_state_loses_context() and psci_power_state_is_valid are only used internally now, so make them static. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/firmware/psci.c | 4 ++-- include/linux/psci.h | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) commit 1d2d8de44a6c20af262b4c3d3b93ef7ec3c5488e Author: Jisheng Zhang <jszhang@marvell.com> Date: Wed Apr 20 11:20:27 2016 +0100 drivers: firmware: psci: drop duplicate const from psci_of_match This is to fix below sparse warning: drivers/firmware/psci.c:mmm:nn: warning: duplicate const Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> drivers/firmware/psci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c8f7341b29126486476dfc669f8f00ebefbe1709 Merge: 26a8eb5 605aa5e Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:46:15 2016 +0200 Merge tag 'tegra-for-4.7-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers Merge "soc/tegra: Changes for v4.7-rc1" from Thierry Reding: This contains a bunch of preparatory patches to the PMC driver which are a prerequisite to moving the driver to generic power domains. * tag 'tegra-for-4.7-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: dt-bindings: Update NVIDIA PMC for Tegra soc/tegra: pmc: Wait for powergate state to change soc/tegra: pmc: Ensure GPU partition can be toggled on/off by PMC soc/tegra: pmc: Remove additional check for a valid partition soc/tegra: pmc: Fix verification of valid partitions soc/tegra: pmc: Fix testing of powergate state soc/tegra: pmc: Change powergate and rail IDs to be an unsigned type soc/tegra: pmc: Protect public functions from potential race conditions soc/tegra: pmc: Restore base address on probe failure soc/tegra: pmc: Remove non-existing L2 partition for Tegra124 soc/tegra: pmc: Remove non-existing power partitions for Tegra210 soc/tegra: pmc: Remove debugfs entry on probe failure soc/tegra: pmc: Fix sparse warning for tegra_pmc_init_tsense_reset() soc/tegra: pmc: Add missing structure members to kernel-doc commit 26a8eb59e0a8da5a662d7c22334af9952edbf6ab Merge: a961bf2 91011a7 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:41:01 2016 +0200 Merge tag 'versatile-flash-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator into next/drivers Merge "move Versatile flash protection to the device tree" from Linus Walleij: This is a set of patches removing the board file code for Versatile flash handling and instead moving it over to the device tree and a special add-on file. * tag 'versatile-flash-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator: ARM: integrator: move flash registration to device tree ARM: versatile: move flash registration to the device tree mtd: augment the "arm,versatile-flash" bindings mtd: physmap_of: add a hook for Versatile write protection Acked-by: Brian Norris <computersforpeace@gmail.com> commit d1fbff8944bf88e449ae387abd498e5220a2ee10 Author: David Daney <ddaney@caviumnetworks.com> Date: Mon Apr 25 16:33:34 2016 +0200 i2c: octeon: Enable High-Level Controller Use High-Level Controller (HLC) when possible. The HLC can read/write up to 8 bytes and is completely optional. The most important difference of the HLC is that it only requires one interrupt for a transfer (up to 8 bytes) where the low-level read/write requires 2 interrupts plus one interrupt per transferred byte. Since the interrupts are costly using the HLC improves the performance. Also, the HLC provides improved error handling. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Signed-off-by: Jan Glauber <jglauber@cavium.com> [wsa: fixed trivial checkpatch warnings] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 347 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 337 insertions(+), 10 deletions(-) commit 30c24b25142a9171d38e8074758b3a370906fc7d Author: Peter Swain <pswain@cavium.com> Date: Mon Apr 25 16:33:33 2016 +0200 i2c: octeon: Add flush writeq helper function Add helper function that reads back a value after writing to make sure the write is finished and use it in octeon_i2c_write_int(). Signed-off-by: Peter Swain <pswain@cavium.com> Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit c981e34eee146fe560c46704396342ff979346d7 Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 25 16:33:31 2016 +0200 i2c: octeon: Use i2c recovery framework Switch to the i2c bus recovery framework using generic SCL recovery. If this fails try to reset the hardware. The recovery is triggered during START on timeout of the interrupt or failure to reach the START / repeated-START condition. The START function is moved to xfer and while at it remove the xfer debug message (i2c core already provides a debug message for this). Signed-off-by: Jan Glauber <jglauber@cavium.com> [wsa: removed one empty line] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 159 ++++++++++++++++++++++++---------------- 1 file changed, 96 insertions(+), 63 deletions(-) commit b4c715d04006ccc17d9ae0cf673b2f65267c042b Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 25 16:33:30 2016 +0200 i2c: octeon: Improve error status checking Introduce a function that checks for valid status codes depending on the phase of a transmit or receive. Also add all existing status codes and improve error handling for various states. The Octeon TWSI has an "assert acknowledge" bit (TWSI_CTL_AAK) that is required to be set in master receive mode until the last byte is requested. The state check needs to consider if this bit was set. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 129 +++++++++++++++++++++++++++++++++------- 1 file changed, 106 insertions(+), 23 deletions(-) commit 3b556bced46aa6b1873da7faa18eff235e896adc Author: Eric Engestrom <eric.engestrom@imgtec.com> Date: Mon Apr 25 10:47:54 2016 +0100 perf tools: Remove duplicate const qualifier Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461577678-29517-1-git-send-email-eric.engestrom@imgtec.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d9e742f5591e06d2d5a9251c9d14ac754da1e53a Merge: f598f17 14de48a Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:08:45 2016 +0200 Merge tag 'keystone_dts_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone into next/dt Merge "ARM: Keystone DTS for 4.7" from Santosh Shilimkar: - Remainder k2-* rename to keystone-* - PSCI node info - SPI alias nodes for bootloaders * tag 'keystone_dts_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone: ARM: keystone: dts: add psci command definition ARM: dts: keystone: Add aliases for SPI nodes ARM: dts: k2*: Rename the k2* files to keystone-k2* files commit 9e4cc255e6e18418ddbeea447efa506bb43d57a2 Author: H. Nikolaus Schaller <hns@goldelico.com> Date: Mon Apr 25 14:02:16 2016 -0700 Input: twl6040-vibra - remove mutex The mutex does not seem to be needed. twl4030-vibra doesn't use one either. Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/misc/twl6040-vibra.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) commit f598f176fd84068beca7a7219f26f8d5ff59a6f6 Merge: 05ad9c3 2b4e38f Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:03:15 2016 +0200 Merge tag 'vexpress-for-v4.7/updates' of git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux into next/dt Merge "ARMv7 Vexpress updates/fixes for v4.7" from Sudeep Holla: 1. Support for external expansion bus useful for additional hardware e.g. LogicTile Express daughterboards (Brian Starkey) 2. Fix for device node name unit-address presence/absence warnings enabled in recently update DTC (Sudeep Holla) * tag 'vexpress-for-v4.7/updates' of git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux: ARM: dts: vexpress: Add external expansion bus to DT ARM: dts: vexpress: fix node name unit-address presence warnings commit 05ad9c3e77885e89accb104ab42c48ff9b31d133 Merge: 9b61aef 6f92cb2 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 23:01:39 2016 +0200 Merge tag 'renesas-dt-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Merge "Renesas ARM Based SoC DT Updates for v4.7" from Simon Horman: * Configure NMI key as wakeup source in DT of kzm9g board * Add SDHI support to DT of gose board * Add support of UHS-I SDR-50 for SDHI to DT of r8a7790 SoC * Correct interrupt type for ARM TWD in DT of r8a7779 and sh73a0 SoCs * Add IIC support to DT of r8a7794 SoC * Add CAN support to DT of r8a7793 and r8a7794 SoCs * Add SCIF2 support to r8a7790 device tree * Use CAN, JPU and USB3.0 fallback compatibility string in DT of r8a7791 and r8a7790 SoCs * tag 'renesas-dt-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: (22 commits) ARM: dts: gose: Enable SDHI controllers ARM: dts: r8a7793: Add SDHI controllers ARM: dts: r8a7790: fix max-frequency for SDHI ARM: dts: kzm9g: Configure NMI key as wake-up source ARM: dts: r8a7790: lager: Enable UHS-I SDR-50 ARM: dts: r8a7790: Set maximum frequencies for SDHI clocks ARM: dts: r8a7791: Use USB3.0 fallback compatibility string ARM: dts: r8a7790: Use USB3.0 fallback compatibility string ARM: dts: r8a7779: Correct interrupt type for ARM TWD ARM: dts: sh73a0: Correct interrupt type for ARM TWD ARM: dts: r8a7794: Add IIC nodes ARM: dts: r8a7794: add IIC clocks ARM: dts: r8a7793: add CAN nodes to device tree ARM: dts: r8a7793: add CAN clocks to device tree ARM: dts: r8a7794: add CAN nodes to device tree ARM: dts: r8a7794: add CAN clocks to device tree ARM: dts: r8a7790: use fallback can compatibility string ARM: dts: r8a7791: use fallback can compatibility string ARM: dts: r8a7790: Add SCIF2 device node ARM: dts: r8a7790: Add SCIF2 clock ... commit c20e128030caf0537d5e906753eac1c28fefdb75 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Mon Apr 25 15:59:50 2016 -0500 alpha/PCI: Call iomem_is_exclusive() for IORESOURCE_MEM, but not IORESOURCE_IO The alpha pci_mmap_resource() is used for both IORESOURCE_MEM and IORESOURCE_IO resources, but iomem_is_exclusive() is only applicable for IORESOURCE_MEM. Call iomem_is_exclusive() only for IORESOURCE_MEM resources, and do it earlier to match the generic version of pci_mmap_resource(). Fixes: 10a0ef39fbd1 ("PCI/alpha: pci sysfs resources") Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: Ivan Kokshaysky <ink@jurassic.park.msu.ru> arch/alpha/kernel/pci-sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ab362f5a95ff72a895c446e9d5ef548cac2fea07 Author: Jiri Olsa <jolsa@kernel.org> Date: Mon Apr 25 22:17:18 2016 +0200 tools build: Fix perf_clean target Fix perf_clean target to follow the same logic as perf target. Fixes the following make invokation: $ cd <kernelsrc> && make tools/perf_clean Reported-by: TJ <linux@iam.tj> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=116411 Link: http://lkml.kernel.org/r/1461615438-27894-2-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ca620723d4ff9ea7ed484eab46264c3af871b9ae Author: Bjorn Helgaas <bhelgaas@google.com> Date: Thu Apr 7 17:15:14 2016 -0700 PCI: Supply CPU physical address (not bus address) to iomem_is_exclusive() iomem_is_exclusive() requires a CPU physical address, but on some arches we supplied a PCI bus address instead. On most arches, pci_resource_to_user(res) returns "res->start", which is a CPU physical address. But on microblaze, mips, powerpc, and sparc, it returns the PCI bus address corresponding to "res->start". The result is that pci_mmap_resource() may fail when it shouldn't (if the bus address happens to match an existing resource), or it may succeed when it should fail (if the resource is exclusive but the bus address doesn't match it). Call iomem_is_exclusive() with "res->start", which is always a CPU physical address, not the result of pci_resource_to_user(). Fixes: e8de1481fd71 ("resource: allow MMIO exclusivity for device drivers") Suggested-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: Arjan van de Ven <arjan@linux.intel.com> drivers/pci/pci-sysfs.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit fb89cf36b6041ac87ad75ad0f5f23b2643fc6f97 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 21 15:01:09 2016 +0900 arm64: dts: uniphier: add reference clock node for PH1-LD20 Add a master clock node generated by a 25MHz crystal oscillator. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/boot/dts/socionext/uniphier-ph1-ld20.dtsi | 6 ++++++ 1 file changed, 6 insertions(+) commit b455f0a1cc51f35a9e714554c6e3234fd806ce02 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 21 14:58:41 2016 +0900 arm64: dts: uniphier: use Daughter board on PH1-LD20 reference board Include the development base board, which is equipped with some devices such as EEPROM. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/boot/dts/socionext/uniphier-ph1-ld20-ref.dts | 1 + arch/arm64/boot/dts/socionext/uniphier-ref-daughter.dtsi | 1 + 2 files changed, 2 insertions(+) commit 6404436a63a463d03ef9b5d7cd5edd371e711a95 Author: Jiri Olsa <jolsa@kernel.org> Date: Mon Apr 25 22:17:17 2016 +0200 perf tools: Make the x86 clean quiet Turn current clean output: $ make clean rm -f arch/x86/include/generated/asm/syscalls_64.c CLEAN libbpf CLEAN libapi into: $ make clean CLEAN x86 CLEAN libapi CLEAN libbpf Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: TJ <linux@iam.tj> Link: http://lkml.kernel.org/r/1461615438-27894-1-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fd8bc829336a24b770247eb893111bcb8f1ddedb Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:11:32 2016 +0800 clk: rockchip: fix the rk3399 cifout clock The cifout clock is incorrect due to the manual error, we need to fix it. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 0a45e16a545b42c5d8439bb56a15cf8fbc7af441 Merge: 11a138e a9abb47 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:54:20 2016 +0200 Merge tag 'arm-soc/for-4.7/devicetree-arm64' of http://github.com/Broadcom/stblinux into next/dt64 Pull "Broadcom ARM64-based SoC Device Tree changes" from Florian Fainelli: - Anup enables a bunch of standard peripherals in the Northstar 2 DTS: PL330 DMA, GIC maintenance interrupt, PL022 SPI controller - Anup also re-orgnanizes the clock Device Tree fragments into a separate file for consistency with how other Broadcom SoCs are doing this - Luke switches the SMP enable-method and reboot from a spin-table + syscon to the standard PSCI 1.0 firmware interface * tag 'arm-soc/for-4.7/devicetree-arm64' of http://github.com/Broadcom/stblinux: arm64: dts: NS2 secondary core enablement via PSCI arm64: dts: Add ARM PL022 SPI DT nodes for NS2 arm64: dts: Move NS2 clock DT nodes to separate DT file arm64: dts: Add maintenance interrupt for GIC in NS2 DT arm64: dts: Add ARM PL330 DMA DT node for NS2 commit 5a5f0792e98bdc8d2db89d1d49cb078fd836c1fa Merge: 557fc4a 947d275 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 25 16:54:15 2016 -0400 Merge branch 'pskb_extract' Sowmini Varadhan says: ==================== pskb_extract() helper function. This patchset follows up on the discussion in https://www.mail-archive.com/netdev@vger.kernel.org/msg105090.html For RDS-TCP, we have to deal with the full gamut of nonlinear sk_buffs, including all the frag_list variants. Also, the parent skb has to remain unchanged, while the clone is queued for Rx on the PF_RDS socket. Patch 1 of this patchset adds a pskb_extract() function that does all this without the redundant memcpy's in pskb_expand_head() and __pskb_pull_tail(). v2: Marcelo Leitner review comments ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 947d2756cddec83c72af99b02010002ddc57aeb3 Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Fri Apr 22 18:36:36 2016 -0700 RDS: TCP: Call pskb_extract() helper function rds-stress experiments with request size 256 bytes, 8K acks, using 16 threads show a 40% improvment when pskb_extract() replaces the {skb_clone(..); pskb_pull(..); pskb_trim(..);} pattern in the Rx path, so we leverage the perf gain with this commit. Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rds/tcp_recv.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 6fa01ccd883021105e9f8af7d04b9f156fa3494a Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Fri Apr 22 18:36:35 2016 -0700 skbuff: Add pskb_extract() helper function A pattern of skb usage seen in modules such as RDS-TCP is to extract `to_copy' bytes from the received TCP segment, starting at some offset `off' into a new skb `clone'. This is done in the ->data_ready callback, where the clone skb is queued up for rx on the PF_RDS socket, while the parent TCP segment is returned unchanged back to the TCP engine. The existing code uses the sequence clone = skb_clone(..); pskb_pull(clone, off, ..); pskb_trim(clone, to_copy, ..); with the intention of discarding the first `off' bytes. However, skb_clone() + pskb_pull() implies pksb_expand_head(), which ends up doing a redundant memcpy of bytes that will then get discarded in __pskb_pull_tail(). To avoid this inefficiency, this commit adds pskb_extract() that creates the clone, and memcpy's only the relevant header/frag/frag_list to the start of `clone'. pskb_trim() is then invoked to trim clone down to the requested to_copy bytes. Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/skbuff.h | 2 + net/core/skbuff.c | 242 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 244 insertions(+) commit 11a138e479425e02787f0512be3d0386c17dca73 Merge: 0413630 01d1b6e Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:53:01 2016 +0200 Merge tag 'xgene-dts-for-v4.7-part1' of https://github.com/AppliedMicro/xgene-next into next/dt64 Merge "First part of X-Gene DTS changes queued for v4.7" from Duc Dang: This patch set only includes a single change to fix the compatible string for SATA controllers on X-Gene v2 SOC platforms. * tag 'xgene-dts-for-v4.7-part1' of https://github.com/AppliedMicro/xgene-next: arm64: dts: apm: Fix compatible string for X-Gene 2 SATA controller DTS node commit 50961e8314babfac525be4d00f3e1f65091251a4 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:51 2016 +0800 clk: rockchip: drop unnecessary CLK_IGNORE_UNUSED flags from rk3399 We don't need to many clocks enable after startup, to reduce some power consumption. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 314 +++++++++++++++++++------------------- 1 file changed, 157 insertions(+), 157 deletions(-) commit 04136309a2398ce132ba38cd0f2c88c6aea2cca1 Merge: 408e8fc 6485160 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:51:50 2016 +0200 Merge tag 'hi6220-dt-for-4.7' of git://github.com/hisilicon/linux-hisi into next/dt64 Pull "ARM64: DT: Hisilicon Hi6220 soc and hikey board updates for 4.7" from Wei Xu - Reserve memory regions for Hi6220 - Add sp804 timer node for Hi6220 - Add cpu and cluster level's low power state for Hi6220 - Add gpio configuration nodes for Hi6220 - Add pinctrl configuration nodes for Hi6220 - Add spi related nodes for Hi6220 - Add i2c nodes for Hi6220 - Add i2c nodes to work with mezzanine boards - Add usb nodes for Hi6220 - Add mailobx node for Hi6220 - Add SRAM node and stub clock node for Hi6220 - Add pinctrl nodes for uarts and enable them - Add LED nodes for hi6220-hikey board - Add hi655x pmic node for Hi6220 - Add dwmmc nodes for Hi6220 - Add wifi nodes support for Hi6220-Hikey board - Register thermal sensor for Hi6220 - Register Hi6220's thermal zone for power allocator - Add L2 cache topology for Hi6220 * tag 'hi6220-dt-for-4.7' of git://github.com/hisilicon/linux-hisi: arm64: dts: Add L2 cache topology to Hi6220 arm64: dts: register Hi6220's thermal zone for power allocator arm64: dts: register Hi6220's thermal sensor arm64: dts: add wifi nodes support for hi6220-hikey arm64: dts: add dwmmc nodes for hi6220 arm64: dts: hikey: Add hi655x pmic dts node arm64: dts: add LED nodes for hi6220-hikey arm64: dts: hi6220: add pinctrl for uarts and enable them arm64: dts: add Hi6220's stub clock node arm64: dts: add mailbox node for Hi6220 arm64: dts: Add hi6220 usb node arm64: dts: hikey: enable i2c0 and i2c1 for working with mezzanine boards arm64: dts: add all hi6220 i2c nodes arm64: dts: add Hi6220 spi configuration nodes arm64: dts: add Hi6220 pinctrl configuration nodes arm64: dts: Add Hi6220 gpio configuration nodes arm64: dts: enable idle states for Hi6220 arm64: dts: add sp804 timer node for Hi6220 arm64: dts: Reserve memory regions for hi6220 commit aa2897ceb7dc01b8e081eaf4d2f7e54cbd495834 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:50 2016 +0800 clk: rockchip: add some frequencies on the rk3399 PLL table This patch add some necessary frequencies for the RK3399 clock. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 408e8fc8fc89d4e9c32cb17fcfbcf8bca22f0dba Merge: a845167 f5f7e45 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:50:23 2016 +0200 Merge tag 'juno-for-v4.7/dt-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux into next/dt64 Pull "ARMv8 Juno DT updates for v4.7" from Sudeep Holla: Just one update: Support for external expansion bus useful for additional hardware e.g.LogicTile Express daughterboards (Brian Starkey) * tag 'juno-for-v4.7/dt-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux: arm64: dts: juno: Add external expansion bus to DT commit 3f92a05440f92f2734c9b754af39afa3244dfb5b Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:49 2016 +0800 clk: rockchip: assign more necessary rk3399 clock ids Assign newly added clock ids. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit a845167df00c10bf3e3d1a1a48472d83475e63d1 Merge: 318085c 8d53957 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:48:51 2016 +0200 Merge tag 'tegra-for-4.7-arm64' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/dt64 Merge "arm64: tegra: Changes for v4.7-rc1" from Thierry Reding A couple of cleanups and fixes to various device trees, enable power and volume keys on Jetson TX1, use stdout-path to define the serial port (so it doesn't have to be specified on the kernel command-line) and add Google Pixel C (a.k.a. Smaug) support. * tag 'tegra-for-4.7-arm64' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: arm64: tegra: Enable cros-ec and charger on Smaug arm64: tegra: Add pinmux for Smaug board arm64: tegra: Add stdout-path for various boards arm64: tegra: Remove unused #power-domain-cells property arm64: tegra: Add gpio-keys nodes for Smaug arm64: tegra: Enable power and volume keys on Jetson TX1 arm64: tegra: Add support for Google Pixel C arm64: tegra: Replace legacy *,wakeup property with wakeup-source arm64: tegra: Fix copy/paste typo in several DTS includes arm64: tegra: Remove 0, prefix from unit-addresses commit de87985e42c48063a81a583883e3e4c8e945e3a8 Merge: f3d4091 55df458 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Apr 25 22:48:19 2016 +0200 Merge branch 'v4.7-shared/clkids' into v4.7-clk/next commit 318085c748d46888415ceb20f9c64d9e1b58c3c7 Merge: e24f89e afa05e5 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 22:47:43 2016 +0200 Merge tag 'samsung-dt64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/dt64 Merge "Samsung Device Tree ARM64 updates and improvements for v4.7" from Krzysztof Kozlowski: 1. Add PL330 DMA controller and Thermal Management Unit to Exynos 7. * tag 'samsung-dt64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: arm64: dts: Add nodes for pdma0 and pdma1 for exynos7 arm64: dts: exynos: Add TMU node for exynos7 commit 55df45843901847f33816f8246ca2538aadd339a Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:49 2016 +0800 clk: rockchip: export some necessary rk3399 clock ids We export some clock IDs for the reference drivers need them. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/clock/rk3399-cru.h | 2 ++ 1 file changed, 2 insertions(+) commit 003e6eb71ed3c884d55443cdb95b909374ade7bc Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:49 2016 +0800 clk: rockchip: rename rga clock-id on rk3399 The rga clock supplying the working clock on the rk3399 is actually called rga-core in the manual. As the clock id has neither been assigned nor released with a full kernel release, we can still change the id to the more appropriate naming. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/clock/rk3399-cru.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f73b5042b9a9c45477246acd478bf49487197a31 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:06:49 2016 +0800 clk: rockchip: add general gpu soft-reset on rk3399 Add the id for the general gpu soft-reset, that got documented only in newer TRM versions. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/clock/rk3399-cru.h | 1 + 1 file changed, 1 insertion(+) commit 557fc4a098039cf296fe33f118bab99a925fd881 Author: Michal Kazior <michal.kazior@tieto.com> Date: Fri Apr 22 14:20:13 2016 +0200 fq: add fair queuing framework This works on the same implementation principle as codel*.h, i.e. there's a generic header with structures and macros and a implementation header carrying function definitions to include in given, e.g. driver or module. The fairness logic comes from net/sched/sch_fq_codel.c but is generalized so it is more flexible and easier to re-use. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/fq.h | 95 ++++++++++++++++++ include/net/fq_impl.h | 269 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 364 insertions(+) commit 05d82c42509c2936e328a6b8b1e1cd5684f427ac Merge: e425974 d068ca2 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 25 16:44:28 2016 -0400 Merge branch 'reusable-codel' Michal Kazior says: ==================== codel: make it reuseable beyond qdiscs There's an ongoing effort in fixing wireless bufferbloat. As part of that fq_codel is being ported into mac80211. To prevent code duplication codel.h needs to be slightly modified before it can be used in mac80211 (or other drivers FWIW). For more background please see: https://www.spinics.net/lists/linux-wireless/msg149976.html ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d068ca2ae2e614b9a418fb3b5f1fd4cf996ff032 Author: Michal Kazior <michal.kazior@tieto.com> Date: Fri Apr 22 14:15:59 2016 +0200 codel: split into multiple files It was impossible to include codel.h for the purpose of having access to codel_params or codel_vars structure definitions and using them for embedding in other more complex structures. This splits allows codel.h itself to be treated like any other header file while codel_qdisc.h and codel_impl.h contain function definitions with logic that was previously in codel.h. This copies over copyrights and doesn't involve code changes other than adding a few additional include directives to net/sched/sch*codel.c. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/codel.h | 223 ---------------------------------------- include/net/codel_impl.h | 255 ++++++++++++++++++++++++++++++++++++++++++++++ include/net/codel_qdisc.h | 73 +++++++++++++ net/sched/sch_codel.c | 2 + net/sched/sch_fq_codel.c | 2 + 5 files changed, 332 insertions(+), 223 deletions(-) commit 79bdc4c862af7cf11a135a6fdf8093622043c862 Author: Michal Kazior <michal.kazior@tieto.com> Date: Fri Apr 22 14:15:58 2016 +0200 codel: generalize the implementation This strips out qdisc specific bits from the code and makes it slightly more reusable. Codel will be used by wireless/mac80211 in the future. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/codel.h | 64 +++++++++++++++++++++++++++++------------------- net/sched/sch_codel.c | 20 ++++++++++++--- net/sched/sch_fq_codel.c | 19 +++++++++++--- 3 files changed, 71 insertions(+), 32 deletions(-) commit e425974feaa545575135f04e646f0495439b4c54 Author: Phil Sutter <phil@nwl.cc> Date: Fri Apr 22 14:02:42 2016 +0200 macsec: Convert to using IFF_NO_QUEUE Signed-off-by: Phil Sutter <phil@nwl.cc> Acked-by: Sabrina Dubroca <sd@queasysnail.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/macsec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0868e2538e45a9ed68e2b14adc42b020a36aae1d Author: Jiri Benc <jbenc@redhat.com> Date: Fri Apr 22 12:40:02 2016 +0200 route: move lwtunnel state to a single place Commit 751a587ac9f9 ("route: fix breakage after moving lwtunnel state") moved lwtstate to the end of dst_entry for 32bit archs. This makes it share the cacheline with __refcnt which had an unkown effect on performance. For this reason, the pointer was kept in place for 64bit archs. However, later performance measurements showed this is of no concern. It turns out that every performance sensitive path that accesses lwtstate accesses also struct rtable or struct rt6_info which share the same cache line. Thus, to get rid of a few #ifdefs, move the field to the end of the struct also for 64bit. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/dst.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 6a025a50b523478b7c8112643cc94f5fd3d312ce Merge: 960a262 a43f235 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 25 15:59:17 2016 -0400 Merge branch 'qed-next' Yuval Mintz says: ==================== qed*: driver updates [Was previous termed 'eeprom access et al.', but seemed a bit inappropriate given we've dropped the eeprom patch for now. Still waiting for some inputs on that one, BTW] This patch series contains some ethtool-related enhancements. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit a43f235f12e9da60a7e181f6a9524ea1e212e39d Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Fri Apr 22 08:41:04 2016 +0300 qed: add support for link pause configuration. The APIs for making this sort of configuration [e.g., via ethtool] are already present in qede, but the current configuration flow in qed doesn't respect it. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit fe7cd2bfdac4d8739bc8665eef040e668e6b428f Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Fri Apr 22 08:41:03 2016 +0300 qed*: Conditions for changing link There's some inconsistency in current logic determining whether the link settings of a given interface can be changed; I.e., in all modes other than the so-called `deault' mode the interfaces are forbidden from changing the configuration - but even this rule is not applied to all user APIs that may change the configuration. Instead, let the core-module [qed] decide whether an interface can change the configuration by supporting a new API function. We also revise the current rule, allowing all interfaces to change their configurations while laying the infrastructure for future modes where an interface would be blocked from making such a configuration. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 6 ++++++ drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 14 ++++++++++---- include/linux/qed/qed_if.h | 10 ++++++++++ 3 files changed, 26 insertions(+), 4 deletions(-) commit f3e72109f04c36ee45e62c0e6e1323179287c3e4 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Fri Apr 22 08:41:02 2016 +0300 qede: Add support for ethtool private flags Adds a getter for the interfaces private flags. The only parameter currently supported is whether the interface is a coupled function [required for supporting 100g]. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit d4967cf38fbd62467b8fb5cab63d7da1f5907ed7 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Fri Apr 22 08:41:01 2016 +0300 qed*: Align statistics names There's a difference in statsitics' names starting at qed and propagating to qede, where egress counters indicate ranges while ingress counters indiciate high-end. Align all statistcs to follow the same conventions - name indicates range. Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_l2.c | 20 ++++++++--------- drivers/net/ethernet/qlogic/qede/qede.h | 20 ++++++++--------- drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 20 ++++++++--------- drivers/net/ethernet/qlogic/qede/qede_main.c | 29 ++++++++++++++++--------- include/linux/qed/qed_if.h | 20 ++++++++--------- 5 files changed, 59 insertions(+), 50 deletions(-) commit f3d40914d3d52e2f155c4e65bc2ab5f5d1efb0ab Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Apr 20 19:12:10 2016 +0800 clk: rockchip: fix the gate bit for i2c4 and i2c8 on rk3399 The gate bits of the i2c4 and i2c8 are incorrect due to the manual error, we need to fix them. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 960a26282f5b1f084313c59d22f76026e6637995 Author: Eric Dumazet <edumazet@google.com> Date: Thu Apr 21 22:27:32 2016 -0700 net: better drop monitoring in ip{6}_recv_error() We should call consume_skb(skb) when skb is properly consumed, or kfree_skb(skb) when skb must be dropped in error case. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/ip_sockglue.c | 10 +++++----- net/ipv6/datagram.c | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) commit 0aea76d35c9651d55bbaf746e7914e5f9ae5a25d Author: Eric Dumazet <edumazet@google.com> Date: Thu Apr 21 22:13:01 2016 -0700 tcp: SYN packets are now simply consumed We now have proper per-listener but also per network namespace counters for SYN packets that might be dropped. We replace the kfree_skb() by consume_skb() to be drop monitor [1] friendly, and remove an obsolete comment. FastOpen SYN packets can carry payload in them just fine. [1] perf record -a -g -e skb:kfree_skb sleep 1; perf report Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_input.c | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) commit a213b92e15cc5019156594c8f3ae9170915aac9f Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 25 16:45:29 2016 -0300 perf evlist: Decode perf_event_attr->branch_sample_type While trying to use --call-graph lbr in 'perf trace', since we only are interested in the callchain for userspace, up to the callchain, I found that 'perf evlist' is not decoding the branch_sample_type field, fix it. Before: # perf record --call-graph lbr usleep 1 # perf evlist -v cycles:ppp: size: 112, { sample_period, sample_freq }: 4000, sample_type: IP|TID|TIME|CALLCHAIN|CPU|PERIOD|BRANCH_STACK, disabled: 1, inherit: 1, mmap: 1, comm: 1, freq: 1, task: 1, precise_ip: 3, sample_id_all: 1, exclude_guest: 1, mmap2: 1, comm_exec: 1, branch_sample_type: 51201 ^^^^^^^^^^^^^^^^^^^^^^^^^ After: # perf evlist -v cycles:ppp: size: 112, { sample_period, sample_freq }: 4000, sample_type: IP|TID|TIME|CALLCHAIN|CPU|PERIOD|BRANCH_STACK, disabled: 1, inherit: 1, mmap: 1, comm: 1, freq: 1, task: 1, precise_ip: 3, sample_id_all: 1, exclude_guest: 1, mmap2: 1, comm_exec: 1, branch_sample_type: USER|CALL_STACK|NO_FLAGS|NO_CYCLES ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-hozai7974u0ulgx13k96fcaw@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) commit 7f768544c2421c399c0909ad9d5a9f916cd96de3 Merge: 9735a22 35a6ae0 4d88d5a dcbb408 b1a928c 19bf4d4 1bf2bf2 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Mon Apr 25 14:35:26 2016 -0500 Merge branches 'pci/enumeration', 'pci/hotplug', 'pci/misc', 'pci/ntb', 'pci/thunderbolt' and 'pci/virtualization' into next * pci/enumeration: x86/PCI: Refine PCI support check in pcibios_init() * pci/hotplug: PCI: acpiphp_ibm: Avoid uninitialized variable reference * pci/misc: PCI: Fix spelling errors * pci/ntb: PCI: Add DMA alias quirk for mic_x200_dma PCI: Add support for multiple DMA aliases PCI: Move informational printk to pci_add_dma_alias() PCI: Add pci_add_dma_alias() to abstract implementation * pci/thunderbolt: thunderbolt: Support 1st gen Light Ridge controller thunderbolt: Fix typos and magic number PCI: Add Intel Thunderbolt device IDs * pci/virtualization: PCI: Work around Intel Sunrise Point PCH incorrect ACS capability PCI: Reverse standard ACS vs device-specific ACS enabling PCI: Mark Intel i40e NIC INTx masking as broken commit 1e9f8dcf892ddb183405cb2414bfc37b40300693 Author: Murali Karicheri <m-karicheri2@ti.com> Date: Mon Apr 11 10:50:31 2016 -0400 PCI: keystone: Remove unnecessary goto statement Fix the misuse of goto statement in ks_pcie_get_irq_controller_info() as simple return is more appropriate for this function. While at it add an error log for absence of interrupt controller node. [bhelgaas: drop "ret" altogether since we always know the return value] Signed-off-by: Murali Karicheri <m-karicheri2@ti.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: Rob Herring <robh+dt@kernel.org> CC: Pawel Moll <pawel.moll@arm.com> CC: Mark Rutland <mark.rutland@arm.com> CC: Ian Campbell <ijc+devicetree@hellion.org.uk> CC: Kumar Gala <galak@codeaurora.org> drivers/pci/host/pci-keystone.c | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) commit fbced0e9465152d628ece5fd0d11de4e7a1f5ce5 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Wed Apr 20 16:15:13 2016 +0300 iio: inv_mpu6050: Add explicit support for MPU9150 This device is a package containing a MPU6050-like sensor and an AK8975 magnetometer. The magnetometer component is supported by the existing ak8975 driver. This patch also rephrases the Kconfig descriptions. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Acked-by: Ge Gao <ggao@invensense.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/Kconfig | 10 ++++------ drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 6 ++++++ drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 1 + drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h | 2 ++ drivers/iio/imu/inv_mpu6050/inv_mpu_spi.c | 1 + 5 files changed, 14 insertions(+), 6 deletions(-) commit bf1eb91274157ac521fd6f3712dac8be90bddca7 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Wed Apr 20 16:15:12 2016 +0300 iio: inv_mpu6050: Add spi_device_id for INV_MPU6500 Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Acked-by: Ge Gao <ggao@invensense.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_spi.c | 1 + 1 file changed, 1 insertion(+) commit cec0154556f8fe6d3a7f5d370f715283888d1c02 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Wed Apr 20 16:15:11 2016 +0300 iio: inv_mpu6050: Check WHO_AM_I register on probe This can be used to distinguish mpu6500. This is a warning rather than an error because the differences are mostly irrelevant and it's nice to avoid breaking users with slightly incorrect ACPI/DT. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Acked-by: Ge Gao <ggao@invensense.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 15 +++++++++++++++ drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h | 8 ++++++++ 2 files changed, 23 insertions(+) commit 87411bbcb44ebf4d1de041ae35c60e8ce1470b79 Merge: 8cb555b 371feaf Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 21:17:59 2016 +0200 Merge tag 'samsung-defconfig64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/arm64 Merge "Defconfig ARM64 changes for Exynos based boards for v4.7" from Krzysztof Kozlowski: 1. Enable the PL330 DMA driver. * tag 'samsung-defconfig64-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: arm64: defconfig: Enable PL330 DMA controller commit be36ad26b4d140895e425f86e484de912595829c Merge: ccb0f68 9120abd Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 21:12:32 2016 +0200 Merge tag 'keystone_config_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone into next/defconfig Merge "ARM: Keystone HOTPLUG and PSCI config update for 4.7" from Santosh Shilimkar * tag 'keystone_config_for_4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone: ARM: configs: keystone: Add CPU Hotplug related options commit 1bc7fe64b60b40d50e42ba4bb870bbfb95d64e21 Merge: e7157f2 d4f90d9 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 25 15:12:06 2016 -0400 Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 10GbE Intel Wired LAN Driver Updates 2016-04-25 This series contains updates to ixgbe and ixgbevf. Emil provides several patches, starting with the consolidation of the logic behind configuring spoof checking. Fixed an issue which was causing link issues for backplane devices because x550em_a/x devices did not have a default value for mac->ops.setup_link. Refactored the ethtool stats to bring the logic closer to how ixgbe handles stats and sets up per-queue stats for ixgbevf. Mark adds a new register to wait for previous register writes to complete before issuing a register read, which is needed when slower links are in use. Fixed the flow control setup for x550em_a, the incorrect fc_setup function was being used. Don added a workaround for empty SFP+ cage crosstalk, since on some systems the crosstalk could lead to link flap on empty SFP+ cages. Jake converts ixgbe and ixgbevf to use the BIT() macro. Alex Duyck adds support for partial GSO segmentation in the case of tunnels for ixgbe and ixgbevf. Then preps for HyperV by moving the API negotiation into mac_ops. Arnd Bergmann provides a fix for the ARM compile warnings in linux-next by converting the use of a udelay() to msleep(). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit ccb0f688ea60b0b0128f3796f58879954c260f2f Merge: dbb2bc9 b72541b Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 21:11:13 2016 +0200 Merge tag 'arm-soc/for-4.7/defconfig' of http://github.com/Broadcom/stblinux into next/defconfig Merge "This pull request contains defconfig changes for Broadcom ARM-based SoCs" from Florian Fainelli: - Eric enables more BCM2835 peripherals in multi_v7_defconfig: watchdog, I2S, switches from the sdhci-bcm2835 to the sdhci-iproc driver, DWC2 USB controller - Eric also enables more BCM2835 peripherals in bcm2835_defconfig: VC4, NFS root Power Management support, switching sdhci-bcm2835 for sdhci-iproc * tag 'arm-soc/for-4.7/defconfig' of http://github.com/Broadcom/stblinux: ARM: bcm2835: Enable NFS root support. ARM: bcm2835: Enable the VC4 graphics driver in the defconfig ARM: bcm2835: Enable CONFIG_PM. ARM: bcm2835: Switch BCM2835 to sdhci-iproc.c for MMC ARM: multi_v7_defconfig: Build in DWC2 USB support ARM: multi_v7_defconfig: Switch BCM2835 to sdhci-iproc.c for MMC ARM: multi_v7_defconfig: Add more BCM2835 support commit dbb2bc9118da94ba261278068af300ad3e71efc8 Merge: f429ff1 23d2af6 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 21:10:07 2016 +0200 Merge tag 'mvebu-defconfig-4.7-1' of git://git.infradead.org/linux-mvebu into next/defconfig Merge "mvebu defconfig for 4.7 (part 1)" from Gregory CLEMENT - Use the new cryto engine(mv_cesa) in the mvebu and multi-arm defcongig files - Attach mvebu_*_defconfig to the mvebu maintainers * tag 'mvebu-defconfig-4.7-1' of git://git.infradead.org/linux-mvebu: ARM: mvebu_v5_defconfig: Switching to the new Marvell's cryptographic engine driver ARM: multi_v7_defconfig: Enabling the new Marvell's cryptographic engine driver MAINTAINERS: attach arch/arm/configs/mvebu_*_defconfig to relevant maintainers ARM: mvebu_v7_defconfig: Enabling the new Marvell's cryptographic engine driver commit e7157f28ced492accf6e665ba0f748162757779f Merge: d296ba6 2dad624 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 25 15:09:12 2016 -0400 Merge branch 'nla_align-set-2' Nicolas Dichtel says: ==================== netlink: align attributes when needed (patchset #2) This is the continuation (series #2) of the work done to align netlink attributes when these attributes contain some 64-bit fields. In patch #3, I didn't modify the function ila_encap_nlsize(). I was waiting feedback for this patch: http://patchwork.ozlabs.org/patch/613766/ If it's approved, there will be an update to switch nla_total_size() to nla_total_size_64bit() after the merge of net in net-next. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 2dad624e6dd65c6048a9bbe0e16559fce182c87c Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:22 2016 +0200 wireless: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/nl80211.h | 4 ++ net/wireless/nl80211.c | 91 ++++++++++++++++++++++++++------------------ 2 files changed, 59 insertions(+), 36 deletions(-) commit cbdeafd7e18b77d147fc1f6c000d4126e53d48bb Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:21 2016 +0200 netfilter/ipvs: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/ip_vs.h | 1 + net/netfilter/ipvs/ip_vs_ctl.c | 36 ++++++++++++++++++++++++------------ 2 files changed, 25 insertions(+), 12 deletions(-) commit a558da0916b90c330940a106105d0a6a67cb77f7 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:20 2016 +0200 ieee802154: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/nl802154.h | 2 ++ net/ieee802154/nl-mac.c | 17 +++++++++++------ net/ieee802154/nl802154.c | 3 ++- 3 files changed, 15 insertions(+), 7 deletions(-) commit 1c714a92833674c040e03be067accfb2b322221e Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:19 2016 +0200 l2tp: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/l2tp.h | 1 + net/l2tp/l2tp_netlink.c | 80 ++++++++++++++++++++++++++++------------------- 2 files changed, 49 insertions(+), 32 deletions(-) commit 12a0faa3bd76157b9dc096758d6818ff535e4586 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:18 2016 +0200 bridge: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 2 ++ net/bridge/br_netlink.c | 62 +++++++++++++++++++++++++------------------- 2 files changed, 38 insertions(+), 26 deletions(-) commit 0238b7204b7ff1bad1d2d4489f010d670cbd89f2 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:17 2016 +0200 ovs: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/openvswitch.h | 1 + net/openvswitch/datapath.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit f13a82d87b21a3b7c2c3e3c75fe9cf810c332a09 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:16 2016 +0200 ipv6: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/ila.h | 1 + net/ipv6/ila/ila_lwt.c | 3 ++- net/ipv6/ila/ila_xlat.c | 15 +++++++++------ 3 files changed, 12 insertions(+), 7 deletions(-) commit 2a51c1e8ecdcedfcb6f84efb3756822d0d0dfb36 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:15 2016 +0200 sched: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/pkt_sched.h | 3 +++ net/sched/sch_htb.c | 6 ++++-- net/sched/sch_netem.c | 3 ++- net/sched/sch_tbf.c | 6 ++++-- 4 files changed, 13 insertions(+), 5 deletions(-) commit 343a6d8e4955f298206d83ae764acf60d146b898 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Mon Apr 25 10:25:14 2016 +0200 rtnl: use nla_put_u64_64bit() Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 1 + net/core/rtnetlink.c | 36 ++++++++++++++++++------------------ 2 files changed, 19 insertions(+), 18 deletions(-) commit f429ff10e691438c66d8f5dab9541d145b47ab60 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 14 16:54:24 2016 +0900 ARM: multi_v7_defconfig: enable Denali NAND controller This NAND controller device is used on UniPhier SoCs (and I know it is also used on SoC FPGA). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 28363d9357f0ad73644f613202880849ebba6acb Merge: 7d7bca8 0fe3ff4 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 25 21:05:37 2016 +0200 Merge tag 'samsung-defconfig-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/defconfig Merge "Defconfig (exynos and multi_v7) changes for Exynos based boards for v4.7" from Krzysztof Kozłowski: 1. Enable additional drivers for Trats2 board (Exynos4412). 2. Enable CPUFreq governors as modules. * tag 'samsung-defconfig-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: multi_v7_defconfig: Enable CPUFreq governors as modules ARM: exynos_defconfig: Enable CPUFreq governors as modules ARM: exynos_defconfig: Enable Trats2 audio codec, touchscreen and sensors commit 7bdd3181596d3d95ef39849bc3ef8e5b91cb6ae1 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Wed Apr 20 16:15:10 2016 +0300 iio: inv_mpu6050: Remove inv_mpu6050_hw.num_reg This field was unused and incorrect for mpu6500. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 3 --- drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h | 2 -- 2 files changed, 5 deletions(-) commit aadd3076db9d37a593dca1f16b35a87e0bd59005 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Wed Apr 20 16:15:09 2016 +0300 iio: inv_mpu6050: Cleanup hw_info mapping The hw_info array was indexed by enum inv_devices chip_type despite the fact that the enumeration had more members than the array and was ordered differently. The patch cleans this up and adds explicit chip_types to i2c/spi/acpi IDs. It also adds some stricter checks inside the driver core. This happened to work so far because the differences between the supported models are very minor. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Acked-by: Ge Gao <ggao@invensense.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 15 ++++++++++++++- drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 2 +- drivers/iio/imu/inv_mpu6050/inv_mpu_spi.c | 18 ++++++++++++++---- 3 files changed, 29 insertions(+), 6 deletions(-) commit 62979904b0037430ecc7d8b682f684adced1340f Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sun Apr 24 22:52:11 2016 +0900 iio: pressure: bmp280: add ability to control oversampling rate This adds ability to control the oversampling ratio of the temperature and pressure measurement for both bmp180 and bmp280. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Acked-by: Vlad Dogaru <vlad.dogaru@intel.com> Cc: Christoph Mair <christoph.mair@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/bmp280.c | 203 ++++++++++++++++++++++++++++++++++++++---- 1 file changed, 185 insertions(+), 18 deletions(-) commit 6dba72eca7fb879bf2e0c8fdc784fb974cb4f9d5 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Sun Apr 24 22:52:10 2016 +0900 iio: pressure: bmp280: add support for BMP180 This adds support for the BMP180 to the bmp280 iio driver. The BMP180 has already been supported by misc/bmp085 driver but it doesn't use iio framework. This change adds the kconfig dependency not to be selected both of them in order to avoid any issues. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Acked-by: Vlad Dogaru <vlad.dogaru@intel.com> Cc: Christoph Mair <christoph.mair@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/Kconfig | 7 +- drivers/iio/pressure/bmp280.c | 367 ++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 357 insertions(+), 17 deletions(-) commit 0569a88f3d1ffed94b15569d53872f16e2351099 Author: Vignesh R <vigneshr@ti.com> Date: Mon Apr 25 15:14:00 2016 +0530 spi: return error if kmap'd buffers passed to spi_map_buf() Current spi_map_buf() implementation supports creates sg_table for vmalloc'd and kmalloc'd buffers. Therefore return error if kmap'd buffer (or any other buffer) is passed to spi_map_buf(). Signed-off-by: Vignesh R <vigneshr@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 8a34e979f684aa13e6c4bf23b394cca9dfabf4a9 Author: WEN Pingbo <pingbo.wen@linaro.org> Date: Sat Apr 23 15:11:05 2016 +0800 regulator: refactor valid_ops_mask checking code To make the code more compat and centralized, this patch add a unified function - regulator_ops_is_valid. So we can add some extra checking code easily later. Signed-off-by: WEN Pingbo <pingbo.wen@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 88 ++++++++++++++++-------------------------------- 1 file changed, 29 insertions(+), 59 deletions(-) commit 7ba2f2757d84eae533679306f03c93c118437a87 Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Sat Apr 23 22:47:08 2016 +0200 spi: core: add hook flash_read_supported to spi_master If hook spi_flash_read is implemented the fast flash read feature is enabled for all devices attached to the respective master. In most cases there is just one flash chip, however there are also devices with more than one flash chip, namely some WiFi routers. Then the fast flash read feature can be used for the first chip only. OpenWRT implemented an own handling of this case, using controller_data element of spi_device to hold the information whether fast flash read can be used for a device. This patch adds hook flash_read_supported to spi_master which is used to extend spi_flash_read_supported() by checking whether the fast flash read feature can be used for a specific spi_device. If the hook is not implemented the default behavior is to allow fast flash read for all devices (if spi_flash_read is implemented). Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/spi/spi.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 69b4269eff5fa75b781ca65cd9c5b699027bf766 Merge: 02da2d7 7ce04cf Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon Apr 25 10:50:11 2016 -0700 Merge 4.6-rc5 into usb-next We want the USB fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit 19d46ee1aec06de3dc1137c76c29e07bfd96d99d Author: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Date: Sat Apr 16 03:01:57 2016 +0300 asus-laptop: correct error handling in sysfs_acpi_set Properly return rv back to the caller in the case of an error in parse_arg. In the process remove a unused variable 'out'. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/asus-laptop.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 2ce6d9932db55cfc09dd6362d6d0d47a361f5f02 Author: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Date: Sat Apr 16 03:01:56 2016 +0300 asus-laptop: remove redundant initializers Initializing rv to AE_OK is pointless because later function results are assigned to them and only then the variable is used Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Acked-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/asus-laptop.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 198b618ab118c7d856278a985de1ed0eff77c02f Author: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Date: Sat Apr 16 03:27:12 2016 +0300 asus-laptop: correct error handling in asus_read_brightness() It is possible that acpi_evaluate_integer might fail and value would not be set to any value so correct this defect by returning 0 in case of an error. This is also the correct thing to return because the backlight subsystem will print the old value of brightness in this case. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@gmail.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/asus-laptop.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit afcd666d9db0ebfbf2751cce1e07b548547ca82e Author: Wadim Egorov <w.egorov@phytec.de> Date: Mon Apr 25 15:20:43 2016 +0200 regulator: rk808: remove linear range definitions with a single range The driver was using only linear ranges. Now we remove linear range definitions with a single range. So we have to add an ops struct for ranges and adjust all other ops functions accordingly. Signed-off-by: Wadim Egorov <w.egorov@phytec.de> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/rk808-regulator.c | 90 +++++++++++++++++++++---------------- 1 file changed, 51 insertions(+), 39 deletions(-) commit ffc03c331a1e7cafac3beb4f89c40fa7d6213d6e Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Apr 18 22:00:56 2016 -0700 wcn36xx: Fill in capability list Fill in the capability list with more values from the downstream driver. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/hal.h | 39 ++++++++++++++++++++++++++++++++ drivers/net/wireless/ath/wcn36xx/main.c | 40 ++++++++++++++++++++++++++++++++- 2 files changed, 78 insertions(+), 1 deletion(-) commit 23c2aabb93c9c8efb7b8991707e2db59f7346783 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Apr 18 22:00:55 2016 -0700 wcn36xx: Correct remove bss key response encoding The WCN36XX_HAL_RMV_BSSKEY_RSP carries a single u32 with "status", so we can use the standard status check function for decoding the result. This is the last user of the v2 status checker, so remove the struct and helper function. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 19 +------------------ drivers/net/wireless/ath/wcn36xx/smd.h | 9 --------- 2 files changed, 1 insertion(+), 27 deletions(-) commit 5443918d050a1a1e5766544e3b895e98671adeef Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Apr 18 22:00:54 2016 -0700 wcn36xx: Delete BSS before idling link When disabling the beacon we must delete the bss before idling the link. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6770559b8f614d3569ced7a7e3a8e846115e77af Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:53 2016 -0700 wcn36xx: Use correct command struct for EXIT_BMPS_REQ EXIT_BMPS_REQ was using the command struct for ENTER_BMPS_REQ. I spotted this when looking at command dumps. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 20a779ede344a0b9778b7d5d9af76453d14474fc Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:52 2016 -0700 wcn36xx: Implement multicast filtering Pass the multicast list to FW. This patch also adds a way to build the smd command in place. This is needed because the MC list command is too big for the stack. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> [bjorn: dropped FIF_PROMISC_IN_BSS usage] Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/hal.h | 6 ++-- drivers/net/wireless/ath/wcn36xx/main.c | 50 ++++++++++++++++++++++++++++++-- drivers/net/wireless/ath/wcn36xx/smd.c | 51 +++++++++++++++++++++++++++++++++ drivers/net/wireless/ath/wcn36xx/smd.h | 3 ++ 4 files changed, 104 insertions(+), 6 deletions(-) commit 043ce546190243bd9de05dbb6c82c9099b01a3a2 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:51 2016 -0700 wcn36xx: Track association state Knowing the association state is needed for mc filtering. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 2 ++ drivers/net/wireless/ath/wcn36xx/wcn36xx.h | 1 + 2 files changed, 3 insertions(+) commit 2716a8ac655f17d17a7040f99f306a6244b08802 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:50 2016 -0700 wcn36xx: Clear encrypt_type when deleting bss key This fixes a problem connecting to an open network after being connected to an encrypted network. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 2 ++ 1 file changed, 2 insertions(+) commit 6d9cf123cd79277c65605faff8d25dbdd1b6ca64 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:49 2016 -0700 wcn36xx: Use allocated self sta index instead of hard coded Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit df98c3294bdf1fc3094f5466accf6423ce968a74 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:48 2016 -0700 wcn36xx: Copy all members in config_sta v1 conversion When converting to version 1 of the config_sta struct not all members where copied. This fixes the problem of multicast frames not being delivered on an encrypted network. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) commit 16be1ac55944412e8d132b1db26f994b368c5742 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:47 2016 -0700 wcn36xx: Parse trigger_ba response properly This message does not follow the canonical format and needs it's own parser. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 25a44da26f2901308440a047b27a3a0054ea4a71 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:46 2016 -0700 wcn36xx: Remove sta pointer in private vif struct This does not work with multiple sta's in a vif. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 3 --- drivers/net/wireless/ath/wcn36xx/smd.c | 28 +++++++++++++++------------- drivers/net/wireless/ath/wcn36xx/wcn36xx.h | 1 - 3 files changed, 15 insertions(+), 17 deletions(-) commit 81c69263757788d77537fefdd9a55b05ed83c87b Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:45 2016 -0700 wcn36xx: Fetch private sta data from sta entry instead of from vif For consistency with other code. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a92e4696292199714d47d8e52c4bf0318324f77f Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:44 2016 -0700 wcn36xx: Add helper macros to cast sta to priv While poking at this I also change two related things. I rename one variable to make the names consistent. I also move one assignment of priv_sta to the declaration to save a few lines. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/main.c | 14 ++++++-------- drivers/net/wireless/ath/wcn36xx/smd.c | 12 ++++++------ drivers/net/wireless/ath/wcn36xx/wcn36xx.h | 6 ++++++ 3 files changed, 18 insertions(+), 14 deletions(-) commit 90023c034fefe51cf67c719065434b0e43e9baf9 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:43 2016 -0700 wcn36xx: Use define for invalid index and fix typo Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/hal.h | 2 +- drivers/net/wireless/ath/wcn36xx/main.c | 4 ++-- drivers/net/wireless/ath/wcn36xx/smd.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit 657a49be13eda5a3befc161d1d499d413c348762 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:42 2016 -0700 wcn36xx: Use consistent name for private vif Some code used priv_vif and some used vif_priv. Convert all to vif_priv for consistency. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/smd.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) commit ce75877f6c3da01cd5efe41683dd32beee1b4b33 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:41 2016 -0700 wcn36xx: Add helper macros to cast vif to private vif and vice versa Makes the code a little easier to read. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/debug.c | 12 +++--------- drivers/net/wireless/ath/wcn36xx/main.c | 16 +++++++--------- drivers/net/wireless/ath/wcn36xx/pmc.c | 4 ++-- drivers/net/wireless/ath/wcn36xx/smd.c | 24 ++++++++++-------------- drivers/net/wireless/ath/wcn36xx/txrx.c | 8 ++------ drivers/net/wireless/ath/wcn36xx/wcn36xx.h | 12 ++++++++++++ 6 files changed, 36 insertions(+), 40 deletions(-) commit 91c3eeba45e13ab7edfb50610df8672d52809394 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:40 2016 -0700 wcn36xx: Pad TIM PVM if needed The wcn36xx FW expects a fixed size TIM PVM in the beacon template. If supplied with a shorter than expected PVM it will overwrite the IE following the TIM. Squashed with fix from Jason Mobarak <jam@cozybit.com>: Patch "wcn36xx: Pad TIM PVM if needed" has caused a regression in mesh beaconing. The field tim_off is always 0 for mesh mode, and thus pvm_len (referring to the TIM length field) and pad are both incorrectly calculated. Thus, msg_body.beacon_length is incorrectly calculated for mesh mode. Fix this. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Jason Mobarak <jam@cozybit.com> [bjorn: squashed in Jason's fixup] Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/hal.h | 3 +++ drivers/net/wireless/ath/wcn36xx/smd.c | 27 +++++++++++++++++++++++++-- 2 files changed, 28 insertions(+), 2 deletions(-) commit 25d217d6e0723481bf90db1d8be02ab475d16002 Author: Pontus Fuchs <pontus.fuchs@gmail.com> Date: Mon Apr 18 22:00:39 2016 -0700 wcn36xx: Clean up wcn36xx_smd_send_beacon Needed for coming improvements. No functional changes. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> [bjorn: restored BEACON_TEMPLATE_SIZE define to 0x180] Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wcn36xx/hal.h | 5 ++++- drivers/net/wireless/ath/wcn36xx/smd.c | 12 +++++------- 2 files changed, 9 insertions(+), 8 deletions(-) commit 0f9edcdd88a993914fa1d1dc369b35dc503979db Author: Vittorio Gambaletta (VittGam) <linux-wireless@vittgam.net> Date: Mon Apr 11 04:48:55 2016 +0200 ath9k: Fix LED polarity for some Mini PCI AR9220 MB92 cards. The Wistron DNMA-92 and Compex WLM200NX have inverted LED polarity (active high instead of active low). The same PCI Subsystem ID is used by both cards, which are based on the same Atheros MB92 design. Cc: <linux-wireless@vger.kernel.org> Cc: <ath9k-devel@qca.qualcomm.com> Cc: <ath9k-devel@lists.ath9k.org> Cc: <stable@vger.kernel.org> Signed-off-by: Vittorio Gambaletta <linuxbugs@vittgam.net> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/pci.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit cd84042ce9040ad038e958bc67a46fcfc015c736 Author: Vittorio Gambaletta (VittGam) <linux-wireless@vittgam.net> Date: Mon Apr 11 04:48:54 2016 +0200 ath9k: Add a module parameter to invert LED polarity. The LED can be active high instead of active low on some hardware. Add the led_active_high module parameter. It defaults to -1 to obey platform data as before. Setting the parameter to 1 or 0 will force the LED respectively active high or active low. Cc: <linux-wireless@vger.kernel.org> Cc: <ath9k-devel@qca.qualcomm.com> Cc: <ath9k-devel@lists.ath9k.org> Cc: <stable@vger.kernel.org> Signed-off-by: Vittorio Gambaletta <linuxbugs@vittgam.net> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/init.c | 7 +++++++ 1 file changed, 7 insertions(+) commit d296ba60d8e2de23a350796a567a3aa90fe1cb6e Author: Craig Gallek <kraig@google.com> Date: Mon Apr 25 10:42:12 2016 -0400 soreuseport: Resolve merge conflict for v4/v6 ordering fix d894ba18d4e4 ("soreuseport: fix ordering for mixed v4/v6 sockets") was merged as a bug fix to the net tree. Two conflicting changes were committed to net-next before the above fix was merged back to net-next: ca065d0cf80f ("udp: no longer use SLAB_DESTROY_BY_RCU") 3b24d854cb35 ("tcp/dccp: do not touch listener sk_refcnt under synflood") These changes switched the datastructure used for TCP and UDP sockets from hlist_nulls to hlist. This patch applies the necessary parts of the net tree fix to net-next which were not automatic as part of the merge. Fixes: 1602f49b58ab ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net") Signed-off-by: Craig Gallek <kraig@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 6 +++++- net/ipv4/inet_hashtables.c | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) commit 60507fe191f524e82986fa737e5b27b4d3ad9289 Author: Matthias Reichl <hias@horus.com> Date: Mon Apr 25 13:39:39 2016 +0000 ASoC: bcm2835: setup clock only if CPU is clock master We only need to enable the clock if we are a clock master. Code ported from bcm2708-i2s driver in Raspberry Pi tree. Original work by Zoltan Szenczi. Signed-off-by: Matthias Reichl <hias@horus.com> Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/bcm/bcm2835-i2s.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit a34b027dca5ea840fbc84121db66488375acfdea Author: Matthias Reichl <hias@horus.com> Date: Mon Apr 25 13:39:38 2016 +0000 ASoC: bcm2835: add 24bit support This adds 24 bit support to the I2S driver of the BCM2835 Code ported from bcm2708-i2s driver in Raspberry Pi tree. Signed-off-by: Florian Meier <florian.meier@koalo.de> Signed-off-by: Matthias Reichl <hias@horus.com> Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/bcm/bcm2835-i2s.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 5e91f6ce4c584d231763437a3ea3aded8e672363 Author: Eric Dumazet <edumazet@google.com> Date: Mon Apr 25 06:34:09 2016 -0700 sock: relax WARN_ON() in sock_owned_by_user() Valdis reported tons of stack dumps caused by WARN_ON() in sock_owned_by_user() This test needs to be relaxed if/when lockdep disables itself. Note that other lockdep_sock_is_held() callers are all from rcu_dereference_protected() sections which already are disabled if/when lockdep has been disabled. Fixes: fafc4e1ea1a4 ("sock: tigthen lockdep checks for sock_owned_by_user") Reported-by: Valdis Kletnieks <Valdis.Kletnieks@vt.edu> Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1df54290463e84b7b5eb26e5e6472167c3749901 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 20 20:06:02 2016 -0300 perf trace: Make --pf honour --min-stack too To check deeply nested page fault callchains. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-wuji34xx003kr88nmqt6jkgf@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) commit 7ad356159542e1f0dd4703ff3604f67390657f57 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 20 19:55:48 2016 -0300 perf trace: Make --event honour --min-stack too Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-shj0fazntmskhjild5i6x73l@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) commit e557b674a9470dae99916be6105e6780b3a072ca Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue Apr 19 19:32:11 2016 -0700 perf script: Fix segfault when printing callchains This fixes a bug caused by an unitialized callchain cursor. The crash frist appeared in: 6f736735e30f ("perf evsel: Require that callchains be resolved before calling fprintf_{sym,callchain}") The callchain cursor is a struct that contains pointers, that when uninitialized will cause unpredictable behavior (usually a crash) when trying to append to the callchain. The existing implementation has the following issues: 1. The callchain cursor used is not initialized, resulting in unpredictable behavior when used. 2. The cursor is declared on the stack. Even if it is properly initalized, the implmentation will leak memory when the function returns, since all the references to the callchain_nodes allocated by callchain_cursor_append will be lost when the cursor goes out of scope. 3. Storing the cursor on the stack is inefficient. Even if memory is properly freed when it goes out of scope, a performance penalty will be incurred due to reallocation of callchain nodes. callchain_cursor_append is designed to avoid these reallocations when an existing cursor is reused. This patch fixes the crash by replacing cursor_callchain with a reference to the global callchain_cursor which also resolves all 3 issues mentioned above. How to reproduce the crash: $ perf record --call-graph=dwarf stress -t 1 -c 1 $ perf script > /dev/null Segfault Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Fixes: 6f736735e30f ("perf evsel: Require that callchains be resolved before calling fprintf_{sym,callchain}") Link: http://lkml.kernel.org/r/1461119531-2529-1-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 0c3a6ef4ea54a179328734a45b7f7698e44ad805 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 16:31:12 2016 -0300 perf trace: Make --pf maj/min/all use callchains too Forgot about page faults, a software event, when adding support for callchains, fix it: # trace --no-syscalls --pf maj --call dwarf 0.000 ( 0.000 ms): Xorg/2068 majfault [sfbSegment1+0x0] => /usr/lib64/xorg/modules/drivers/intel_drv.so@0x11b490 (x.) sfbSegment1+0x0 (/usr/lib64/xorg/modules/drivers/intel_drv.so) fbPolySegment32+0x361 (/usr/lib64/xorg/modules/drivers/intel_drv.so) sna_poly_segment+0x743 (/usr/lib64/xorg/modules/drivers/intel_drv.so) damagePolySegment+0x77 (/usr/libexec/Xorg) ProcPolySegment+0xe7 (/usr/libexec/Xorg) Dispatch+0x25f (/usr/libexec/Xorg) dix_main+0x3c3 (/usr/libexec/Xorg) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) _start+0x29 (/usr/libexec/Xorg) 0.257 ( 0.000 ms): Xorg/2068 majfault [miZeroClipLine+0x0] => /usr/libexec/Xorg@0x18e830 (x.) miZeroClipLine+0x0 (/usr/libexec/Xorg) _fbSegment+0x2c0 (/usr/lib64/xorg/modules/drivers/intel_drv.so) sfbSegment1+0x67 (/usr/lib64/xorg/modules/drivers/intel_drv.so) fbPolySegment32+0x361 (/usr/lib64/xorg/modules/drivers/intel_drv.so) sna_poly_segment+0x743 (/usr/lib64/xorg/modules/drivers/intel_drv.so) damagePolySegment+0x77 (/usr/libexec/Xorg) ProcPolySegment+0xe7 (/usr/libexec/Xorg) Dispatch+0x25f (/usr/libexec/Xorg) dix_main+0x3c3 (/usr/libexec/Xorg) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) _start+0x29 (/usr/libexec/Xorg) ^C# Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-8h6ssirw5z15qyhy2lwd6f89@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 59 ++++++++++++++++++++++++++++++++-------------- 1 file changed, 41 insertions(+), 18 deletions(-) commit 0ae537cb35e63f6a61013e736a0557b83a0336ea Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 16:00:01 2016 -0300 perf trace: Extract evsel contructor from perf_evlist__add_pgfault Prep work for next patches, where we'll need access to the created evsels, to possibly configure callchains. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-2pcgsgnkgellhlcao4aub8tu@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) commit 70a2cba972e5e4a5d850e4179381f1cd344c6828 Author: Andrey Ryabinin <aryabinin@virtuozzo.com> Date: Tue Apr 19 11:17:27 2016 +0300 perf buildid: Fix off-by-one in write_buildid() write_buildid() increments 'name_len' with intention to take into account trailing zero byte. However, 'name_len' was already incremented in machine__write_buildid_table() before. So this leads to out-of-bounds read in do_write(): $ ./perf record sleep 0 [ perf record: Woken up 1 times to write data ] ================================================================= ==15899==ERROR: AddressSanitizer: global-buffer-overflow on address 0x00000099fc92 at pc 0x7f1aa9c7eab5 bp 0x7fff940f84d0 sp 0x7fff940f7c78 READ of size 19 at 0x00000099fc92 thread T0 #0 0x7f1aa9c7eab4 (/usr/lib/gcc/x86_64-pc-linux-gnu/5.3.0/libasan.so.2+0x44ab4) #1 0x649c5b in do_write util/header.c:67 #2 0x649c5b in write_padded util/header.c:82 #3 0x57e8bc in write_buildid util/build-id.c:239 #4 0x57e8bc in machine__write_buildid_table util/build-id.c:278 ... 0x00000099fc92 is located 0 bytes to the right of global variable '*.LC99' defined in 'util/symbol.c' (0x99fc80) of size 18 '*.LC99' is ascii string '[kernel.kallsyms]' ... Shadow bytes around the buggy address: 0x00008012bf80: f9 f9 f9 f9 00 00 00 00 00 00 03 f9 f9 f9 f9 f9 =>0x00008012bf90: 00 00[02]f9 f9 f9 f9 f9 00 00 00 00 00 05 f9 f9 0x00008012bfa0: f9 f9 f9 f9 00 03 f9 f9 f9 f9 f9 f9 00 00 00 00 Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461053847-5633-1-git-send-email-aryabinin@virtuozzo.com [ Remove the off-by one at the origin, to keep len(s) == strlen(s) assumption ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/build-id.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 1c986e3643d278d93e9ca67b3c752f486cc32318 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Wed Apr 20 10:18:46 2016 +0900 of: document refcount incrementation of of_get_cpu_node() This function increments refcount. This is worth noting. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Frank Rowand <frank.rowand@am.sony.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1f644a737340592a7c20a7c525e8d279e9a4f119 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:04 2016 +0100 Documentation: virtual: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> Documentation/virtual/kvm/devices/s390_flic.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d6a442df63b2f0043c0b4fc05504ac4ded96ae80 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 22:55:47 2016 +0100 hwmon: (sch5636) trivial fix of spelling mistake on revision fix spelling mistake, revison -> revision Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/sch5636.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ba1ca654f30ddca8f208f43ebbf27cb933a97982 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon Apr 25 16:21:34 2016 +0200 cpufreq: governor: Fix prev_load initialization in cpufreq_governor_start() The way cpufreq_governor_start() initializes j_cdbs->prev_load is questionable. First off, j_cdbs->prev_cpu_wall used as a denominator in the computation may be zero. The case this happens is when get_cpu_idle_time_us() returns -1 and get_cpu_idle_time_jiffy() used to return that number is called exactly at the jiffies_64 wrap time. It is rather hard to trigger that error, but it is not impossible and it will just crash the kernel then. Second, j_cdbs->prev_load is computed as the average load during the entire time since the system started and it may not reflect the load in the previous sampling period (as it is expected to). That doesn't play well with the way dbs_update() uses that value. Namely, if the update time delta (wall_time) happens do be greater than twice the sampling rate on the first invocation of it, the initial value of j_cdbs->prev_load (which may be completely off) will be returned to the caller as the current load (unless it is equal to zero and unless another CPU sharing the same policy object has a greater load value). For this reason, notice that the prev_load field of struct cpu_dbs_info is only used by dbs_update() and only in that one place, so if cpufreq_governor_start() is modified to always initialize it to 0, it will make dbs_update() always compute the actual load first time it checks the update time delta against the doubled sampling rate (after initialization) and there won't be any side effects of it. Consequently, modify cpufreq_governor_start() as described. Fixes: 18b46abd0009 (cpufreq: governor: Be friendly towards latency-sensitive bursty workloads) Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq_governor.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3920be471ce7f66c05e6e0cd251a332b84520ef8 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:47 2016 +0530 cpufreq: hisilicon: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/Kconfig.arm | 9 -------- drivers/cpufreq/Makefile | 1 - drivers/cpufreq/cpufreq-dt-platdev.c | 2 ++ drivers/cpufreq/hisi-acpu-cpufreq.c | 42 ------------------------------------ 4 files changed, 2 insertions(+), 52 deletions(-) commit 5e4249c6d9e596fdb26357997236a01b96c8902d Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:46 2016 +0530 cpufreq: zynq: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-zynq/common.c | 2 -- drivers/cpufreq/cpufreq-dt-platdev.c | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) commit 117d4f59affa869f819ec53ed0cd54aedfdeffa0 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:45 2016 +0530 cpufreq: sunxi: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-sunxi/sunxi.c | 9 --------- drivers/cpufreq/cpufreq-dt-platdev.c | 12 ++++++++++++ 2 files changed, 12 insertions(+), 9 deletions(-) commit a399dc9fc5005321cebee6589d6bca780ed99c18 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:44 2016 +0530 cpufreq: shmobile: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-shmobile/Makefile | 1 - arch/arm/mach-shmobile/common.h | 7 ------- arch/arm/mach-shmobile/cpufreq.c | 19 ------------------- drivers/cpufreq/cpufreq-dt-platdev.c | 12 ++++++++++++ 4 files changed, 12 insertions(+), 27 deletions(-) commit 014400c127be352a0a129aaa8a9ac870a310c76c Author: Finley Xiao <finley.xiao@rock-chips.com> Date: Fri Apr 22 16:58:43 2016 +0530 cpufreq: rockchip: Use generic platdev driver This patch add rockchip's compatible string to the compat list and remove similar code from platform code for supporting generic platdev driver. Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-rockchip/rockchip.c | 1 - drivers/cpufreq/cpufreq-dt-platdev.c | 11 +++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) commit 7694ca6e1d6f01122f05039b81f70f64b1ec4063 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:42 2016 +0530 cpufreq: omap: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-omap2/pm.c | 7 ++----- drivers/cpufreq/cpufreq-dt-platdev.c | 5 +++++ 2 files changed, 7 insertions(+), 5 deletions(-) commit 7ead83f6df2b105e4973140fe323a93ccfd4f8f9 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:41 2016 +0530 cpufreq: imx: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Note that the complete routine imx27_dt_init() is removed as of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); has same effect as a NULL .init_machine machine callback pointer. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Lucas Stach <l.stach@pengutronix.de> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-imx/imx27-dt.c | 10 ---------- arch/arm/mach-imx/mach-imx51.c | 3 --- arch/arm/mach-imx/mach-imx53.c | 2 -- arch/arm/mach-imx/mach-imx7d.c | 6 ------ drivers/cpufreq/cpufreq-dt-platdev.c | 5 +++++ 5 files changed, 5 insertions(+), 21 deletions(-) commit a59511d1daa6406eede58a79f99250ffcd9a3566 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:40 2016 +0530 cpufreq: berlin: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Antoine Tenart <antoine.tenart@free-electrons.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-berlin/berlin.c | 6 ------ drivers/cpufreq/cpufreq-dt-platdev.c | 2 ++ 2 files changed, 2 insertions(+), 6 deletions(-) commit e92bb16674c5156ea9230ba7a3ab6d490750888f Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Fri Apr 22 16:58:39 2016 +0530 cpufreq: dt: Mark platdev machines array as __initconst The machines array in cpufreq-dt-platdev is used only once at boot time and so should be marked with __initconst, so that kernel can free up memory used for it, if required. Suggested-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cpufreq-dt-platdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44dbcc93ab67145bf8ebe3e91123303443c4a3bf Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Fri Apr 22 12:25:35 2016 +0100 arm64: Fix behavior of maxcpus=N maxcpu=n sets the number of CPUs activated at boot time to a max of n, but allowing the remaining CPUs to be brought up later if the user decides to do so. However, on arm64 due to various reasons, we disallowed hotplugging CPUs beyond n, by marking them not present. Now that we have checks in place to make sure the hotplugged CPUs have compatible features with system and requires no new errata, relax the restriction. Cc: Will Deacon <will.deacon@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: James Morse <james.morse@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/smp.c | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) commit 6a6efbb45b7d95c84840010095367eb06a64f342 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Fri Apr 22 12:25:34 2016 +0100 arm64: Verify CPU errata work arounds on hotplugged CPU CPU Errata work arounds are detected and applied to the kernel code at boot time and the data is then freed up. If a new hotplugged CPU requires a work around which was not applied at boot time, there is nothing we can do but simply fail the booting. Cc: Will Deacon <will.deacon@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Andre Przywara <andre.przywara@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/cpufeature.h | 1 + arch/arm64/kernel/cpu_errata.c | 20 ++++++++++++++++++++ arch/arm64/kernel/cpufeature.c | 1 + 3 files changed, 22 insertions(+) commit 25fc11aead380501d70b701e136e89d321277177 Author: Marc Zyngier <marc.zyngier@arm.com> Date: Fri Apr 22 12:25:33 2016 +0100 irqchip/gic: Restore CPU interface checking When introducing the whole CPU feature detection framework, we lost the capability to detect a mismatched GIC configuration (using the GICv2 MMIO interface, but having the system register interface enabled). In order to solve this, use the new this_cpu_has_cap() helper. Also move the check to the CPU interface path in order to catch systems where the first CPU has been correctly configured, but the secondaries are not. Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/irqchip/irq-gic.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit e3661b128e53ee281e1e7c589a5b647890bd6d7c Author: Marc Zyngier <marc.zyngier@arm.com> Date: Fri Apr 22 12:25:32 2016 +0100 arm64: Allow a capability to be checked on a single CPU Now that the capabilities are only available once all the CPUs have booted, we're unable to check for a particular feature in any subsystem that gets initialized before then. In order to support this, introduce a local_cpu_has_cap() function that tests for the presence of a given capability independently of the whole framework. Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> [ Added preemptible() check ] Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> [will: remove duplicate initialisation of caps in this_cpu_has_cap] Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/cpufeature.h | 2 ++ arch/arm64/kernel/cpufeature.c | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+) commit 92406f0cc9e3d5cc77bf3de6d68c9c2373dcd701 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Fri Apr 22 12:25:31 2016 +0100 arm64: cpufeature: Add scope for capability check Add scope parameter to the arm64_cpu_capabilities::matches(), so that this can be reused for checking the capability on a given CPU vs the system wide. The system uses the default scope associated with the capability for initialising the CPU_HWCAPs and ELF_HWCAPs. Cc: James Morse <james.morse@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Andre Przywara <andre.przywara@arm.com> Cc: Will Deacon <will.deacon@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/cpufeature.h | 9 ++- arch/arm64/kernel/cpu_errata.c | 4 +- arch/arm64/kernel/cpufeature.c | 131 ++++++++++++++++++++---------------- 3 files changed, 83 insertions(+), 61 deletions(-) commit 46e7a4e18397649fe1b9007ad99707d960eb138e Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 21 14:28:57 2016 +0530 PM / OPP: Mark shared-opp for non-dt case opp core allows OPPs to be explicitly marked as shared from platform code, in case of operating-point v1 bindings. Though we do everything fine in that case, we don't set the flag in the opp-table to indicate that the OPPs are shared. It works fine today as the flag isn't used anywhere else in the core, but we should be doing the right thing by marking it set. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 3 +++ 1 file changed, 3 insertions(+) commit 2c93104ff2d678b22bb8d5ca502ac5df21a68f69 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 21 14:28:56 2016 +0530 PM / OPP: Relocate dev_pm_opp_set_sharing_cpus() Move dev_pm_opp_set_sharing_cpus() towards the end of the file. This is required for better readability after the next patch is applied, which adds dev_pm_opp_get_sharing_cpus(). Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 112 +++++++++++++++++++++---------------------- 1 file changed, 56 insertions(+), 56 deletions(-) commit 642aa8cee7b84eee1dc4897e301611cffa6d5775 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 21 14:28:55 2016 +0530 PM / OPP: dev_pm_opp_set_sharing_cpus() doesn't depend on CONFIG_OF dev_pm_opp_set_sharing_cpus() doesn't do any DT specific stuff and its declarations are added within the CONFIG_OF ifdef by mistake. Take them out of that. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/linux/pm_opp.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 45ca36ad7cd5784c6326504a8f54df4cccaa8852 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 21 14:28:54 2016 +0530 PM / OPP: Add missing doc style comments Few of the routines in cpu.c were missing these, add them. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 59 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 58 insertions(+), 1 deletion(-) commit 2d74c6d565567e72c6ea303a452473c8fa7141e4 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 21 14:28:53 2016 +0530 PM / OPP: Propagate the error returned by _find_opp_table() Don't send -EINVAL and propagate what's received from _find_opp_table(). Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/opp/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 394cb8316b44e86f64c39ee943bc9bc4f813283b Author: Jia Hongtao <hongtao.jia@nxp.com> Date: Tue Apr 19 17:00:07 2016 +0800 cpufreq: qoriq: Fix cooling device registration issue during suspend Cooling device is registered by ready callback. It's also invoked while system resuming from sleep (Enabling non-boot cpus). Thus cooling device may be multiple registered. Matchable unregistration is added to exit callback to fix this issue. Signed-off-by: Jia Hongtao <hongtao.jia@nxp.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/qoriq-cpufreq.c | 1 + 1 file changed, 1 insertion(+) commit 495c716f177ed8fb3eb6334e4d08c409a9a0bd0f Author: Jia Hongtao <hongtao.jia@nxp.com> Date: Tue Apr 19 17:00:06 2016 +0800 cpufreq: qoriq: Remove __exit macro from .exit callback .exit callback (qoriq_cpufreq_cpu_exit()) is also used during suspend. So __exit macro should be removed or the function will be discarded. Signed-off-by: Jia Hongtao <hongtao.jia@nxp.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/qoriq-cpufreq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4ba2578fa7b557012b8f59ad7a9284ff15394338 Author: Will Deacon <will.deacon@arm.com> Date: Mon Apr 25 15:05:24 2016 +0100 arm64: perf: don't expose CHAIN event in sysfs The CHAIN event allows two 32-bit counters to be treated as a single 64-bit counter, under certain allocation restrictions on the PMU. Whilst userspace could theoretically create CHAIN events using the raw event syntax, we don't really want to advertise this in sysfs, since it's useless in isolation. This patch removes the event from our /sys entries. Reported-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 27b8fe8daf39c8a028d377a878b1405b73f5a10f Author: Jia Hongtao <hongtao.jia@nxp.com> Date: Mon Apr 18 15:59:32 2016 +0800 cpufreq: qoriq: Don't show cooling device messages if THERMAL_OF undefined When THERMAL_OF is undefined the cooling device messages should not be shown. -ENOSYS is returned from of_cpufreq_cooling_register() when THERMAL_OF is undefined. Signed-off-by: Jia Hongtao <hongtao.jia@nxp.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/qoriq-cpufreq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a29a1e76781d112014761ba106ab03e097cc4492 Author: Ashwin Chaugule <ashwin.chaugule@linaro.org> Date: Thu Apr 14 20:45:53 2016 -0400 cpufreq: ACPI / CPPC: Add module support for cppc_cpufreq driver Add a function to cleanup at module exit and export appropriate GPL string to enable moduler support for the cppc_cpufreq driver. Reported-by: Srinivas Pandruvada <srinivas.pandruvada@intel.com> Signed-off-by: Ashwin Chaugule <ashwin.chaugule@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/cppc_cpufreq.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit bdcaa23fb87260c8314f538f444ee845ea51e15d Author: Philippe Longepe <philippe.longepe@linux.intel.com> Date: Fri Apr 22 11:46:09 2016 -0700 cpufreq: intel_pstate: Use average P-State instead of current P-State The result returned by pid_calc() is subtracted from current_pstate (which is the P-State requested during the last period) in order to obtain the target P-State for the current iteration. However, current_pstate may not reflect the real current P-State of the CPU. In particular, that P-State may be higher because of the frequency sharing per module. The theory is: - The load is the percentage of time spent in C0 and is related to the average P-State during the same period. - The last requested P-State can be completely different than the average P-State (because of frequency sharing or throttling). - The P-State shift computed by the pid_calc is based on the load computed at average P-State, so the shift must be relative to this average P-State. Using the average P-State instead of current P-State improves power without significant performance penalty in cases when a task migrates from one core to other core sharing frequency and voltage. Performance and power comparison with this patch on Cherry Trail platform using Android: Benchmark ?Perf ?Power FishTank 10.45% 3.1% SmartBench-Gaming -0.1% -10.4% SmartBench-Productivity -0.8% -10.4% CandyCrush n/a -17.4% AngryBirds n/a -5.9% videoPlayback n/a -13.9% audioPlayback n/a -4.9% IcyRocks-20-50 0.0% -38.4% iozone RR -0.16% -1.3% iozone RW 0.74% -1.3% Signed-off-by: Philippe Longepe <philippe.longepe@linux.intel.com> Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 1cbc99dfe5d7d686fd022647f4e489b5eb8e9068 Merge: 94862a6 8cee1ee Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Mon Apr 25 15:44:01 2016 +0200 Merge back cpufreq changes for v4.7. commit 718756b5033f6f75562aab17601326df104527e8 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:19 2016 +0100 Documentation: dt: soc: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> .../devicetree/bindings/soc/ti/keystone-navigator-qmss.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b7f97b3a21582c88a9bc441db0bd9ad6cc2c0e37 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:18 2016 +0100 Documentation: dt: power: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/power/qcom,coincell-charger.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4e99a3bd49e4701f81ad0fd7c0ca3b67c6b0fc8b Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:17 2016 +0100 Documentation: dt: pinctrl: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/pinctrl/qcom,pmic-gpio.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit baec7f1f5a67f4879a215d466f7b088aff9823d5 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:16 2016 +0100 Documentation: dt: opp: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/opp/opp.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dd346f2728bc2fc4121288d5dbe8ed58f4d6005e Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:15 2016 +0100 Documentation: dt: net: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/net/hisilicon-hns-nic.txt | 2 +- Documentation/devicetree/bindings/net/stmmac.txt | 4 ++-- Documentation/devicetree/bindings/net/ti,dp83867.txt | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit c7292b471bc9198f865d7bed56996648208e60c6 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:14 2016 +0100 Documentation: dt: mtd: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/mtd/brcm,brcmnand.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c312c2ec866e319a49249b0597f53c5271c7cb3e Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:13 2016 +0100 Documentation: dt: mmc: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/mmc/mmc-pwrseq-emmc.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc5b5140af500e9a8f022fede6bab5823cb7f43e Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:12 2016 +0100 Documentation: dt: mfd: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/mfd/qcom-rpm.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 70e044ba1e1bafbe28adf54beab6059690bdc90a Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:11 2016 +0100 Documentation: dt: media: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/media/xilinx/video.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f97c2814b5448d91a3c67081f7d978c097feabe Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:10 2016 +0100 Documentation: dt: interrupt-controller: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> .../devicetree/bindings/interrupt-controller/ti,omap4-wugen-mpu | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 25da0af697aa9b9e683bb94b10ffe6c994b06f4c Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:09 2016 +0100 Documentation: dt: input: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/input/ads7846.txt | 2 +- Documentation/devicetree/bindings/input/touchscreen/fsl-mx25-tcq.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 30729ab58609dbb727c33d504652955dfd0ac3f2 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:08 2016 +0100 Documentation: dt: dma: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/dma/xilinx/xilinx_dma.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bfcfb84a4d7988d28e81638d7fbd2e26c02f44ce Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:07 2016 +0100 Documentation: dt: display: fix spelling mistake Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/display/exynos/exynos_dsim.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d7fb8300d732a999c034ef4707d150d5579c27a8 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:06 2016 +0100 Documentation: dt: clock: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Reviewed-by: Heiko Stuebner <heiko@sntech.de> [robh: s/describe/described/] Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/clock/rockchip,rk3188-cru.txt | 2 +- Documentation/devicetree/bindings/clock/rockchip,rk3288-cru.txt | 2 +- Documentation/devicetree/bindings/clock/st/st,clkgen.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit d6cf8337c5b536eaa86068f14f6eef4f904e2218 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 01:24:05 2016 +0100 Documentation: dt: arm: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/arm/cci.txt | 2 +- Documentation/devicetree/bindings/arm/spear-misc.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 8b4958573f8215ca052b2c084100ebbcd28be904 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Apr 22 17:29:16 2016 +0200 serial: Move Marvell UART DT bindings to correct location All other UART DT binding documentation is under Documentation/devicetree/bindings/serial/. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/serial/mvebu-uart.txt | 13 +++++++++++++ Documentation/devicetree/bindings/tty/serial/mvebu-uart.txt | 13 ------------- 2 files changed, 13 insertions(+), 13 deletions(-) commit 3b56727105a2605240a62acfc4033ee12fb938d8 Author: Dr. H. Nikolaus Schaller <hns@goldelico.com> Date: Thu Apr 21 18:03:15 2016 +0200 Documentation: bindings: fix palmas-rtc documentation change 100mA -> 100uA Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/rtc/rtc-palmas.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 109a553d7553997efd69be60818c1a79a6cb172c Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:17 2016 +0200 phy: phy-stih41x-usb: DT spelling s/#phy-cell/#phy-cells/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/phy/phy-stih41x-usb.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 332bea1a26b90ccbe34a6fd3ce2baddabad9fdb3 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:16 2016 +0200 PCI: hisi: DT spelling s/interrupts-*/interrupt-*/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/pci/hisilicon-pcie.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 2366b80f9122ab5100ad738f726a3c7539c1d1df Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:15 2016 +0200 misc: sram: DT spelling s/#adress-cells/#address-cells/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/sram/sram.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6cd54fc60cc9d307c09bd2675f410c1086050e7d Merge: d2b484b 8fb04d9 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Mon Apr 25 15:35:53 2016 +0200 Merge tag 'ipvs-for-v4.7' of https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs-next Simon Horman says: ==================== IPVS Updates for v4.7 please consider these enhancements to the IPVS. They allow SIP connections originating from real-servers to be load balanced by the SIP psersitence engine as is already implemented in the other direction. And for better one packet scheduling (OPS) performance. ==================== Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> commit d2b484b577776f3c6f4d52505b27bad27ea1fe00 Author: Liping Zhang <liping.zhang@spreadtrum.com> Date: Fri Apr 22 02:56:57 2016 -0700 netfilter: ip6t_SYNPROXY: unnecessary to check whether ip6_route_output returns NULL ip6_route_output() will never return a NULL pointer, so there's no need to check it. Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv6/netfilter/ip6t_SYNPROXY.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3bb398d925ec73e42b778cf823c8f4aecae359ea Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Thu Apr 14 17:13:41 2016 +0200 netfilter: nf_ct_helper: disable automatic helper assignment Four years ago we introduced a new sysctl knob to disable automatic helper assignment in 72110dfaa907 ("netfilter: nf_ct_helper: disable automatic helper assignment"). This knob kept this behaviour enabled by default to remain conservative. This measure was introduced to provide a secure way to configure iptables and connection tracking helpers through explicit rules. Give the time we have waited for this, let's turn off this by default now, worse case users still have a chance to recover the former behaviour by explicitly enabling this back through sysctl. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_helper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e701001e7cbe88cdc937037f6f398669eef7e7ff Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue Apr 12 23:50:37 2016 +0200 netfilter: nft_rbtree: allow adjacent intervals with dynamic updates This patch fixes dynamic element updates for adjacent intervals in the rb-tree representation. Since elements are sorted in the rb-tree, in case of adjacent nodes with the same key, the assumption is that an interval end node must be placed before an interval opening. In tree lookup operations, the idea is to search for the closer element that is smaller than the one we're searching for. Given that we'll have two possible matchings, we have to take the opening interval in case of adjacent nodes. Range merges are not trivial with the current representation, specifically we have to check if node extensions are equal and make sure we keep the existing internal states around. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nft_rbtree.c | 40 +++++++++++++++++++++++++++++++++++----- 1 file changed, 35 insertions(+), 5 deletions(-) commit c6d3b5dd8e6fd802a354590314df28d6024906d8 Author: David Lechner <david@lechnology.com> Date: Sat Apr 16 12:00:20 2016 -0500 ARM: dts: da850: There are 101 interrupts. Fix off by one error in da850 device tree in the number of INTC interrupts. Signed-off-by: David Lechner <david@lechnology.com> Tested-by: Kevin Hilman <khilman@baylibre.com> [nsekhar@ti.com: commit message update] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5209a8f19e9aa9aac26c4f53c868a13005dd2444 Author: David Lechner <david@lechnology.com> Date: Sat Apr 16 12:00:19 2016 -0500 ARM: dts: da850: disable mdio and eth0 in da850.dtsi Disable mdio and eth0 in da850.dtsi file. All other devices are disabled by default and not all boards will use these devices, so these should be disabled too. da850-evm.dtb already had status = "okay" for these devices. da850-enbw-cmc.dts did not, so they were added. Signed-off-by: David Lechner <david@lechnology.com> Tested-by: Kevin Hilman <khilman@baylibre.com> [nsekhar@ti.com: commit description updates] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850-enbw-cmc.dts | 6 ++++++ arch/arm/boot/dts/da850.dtsi | 2 ++ 2 files changed, 8 insertions(+) commit 801a6aa9aabf5d8e1323dd8bbb748589e4706d44 Author: David Lechner <david@lechnology.com> Date: Sat Apr 16 12:00:18 2016 -0500 ARM: davinci: da8xx-dt: Add spi0 lookup for clock matching Add AUXDATA needed to match the device-tree node for spi0 to the non-device-tree clock. Signed-off-by: David Lechner <david@lechnology.com> Tested-by: Kevin Hilman <khilman@baylibre.com> [nsekhar@ti.com: commit description updates] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/da8xx-dt.c | 1 + 1 file changed, 1 insertion(+) commit 4be4b28a404e431660d8188f175c02dfee961399 Author: David Lechner <david@lechnology.com> Date: Sat Apr 16 12:00:17 2016 -0500 ARM: dts: da850: add spi0 to device tree Add device node and pinmux for SoC spi0. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850.dtsi | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) commit 201a72b2829fa6d58443fb9857db944b52d77062 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:45 2016 -0700 arm64/perf: Add Broadcom Vulcan PMU support Broadcom Vulcan uses ARMv8 PMUv3 and supports most of the ARMv8 recommended implementation defined events. Added Vulcan events mapping for perf and perf_cache map. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 60 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) commit 4b1a9e6934ec6e38138c66c2f73cf6f3695a9c6c Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:44 2016 -0700 arm64/perf: Filter common events based on PMCEIDn_EL0 The complete common architectural and micro-architectural event number structure is filtered based on PMCEIDn_EL0 and exposed to /sys using is_visibile function pointer in events attribute_group. To filter the events in is_visible function, pmceid based bitmap is stored in arm_pmu structure and the id field from perf_pmu_events_attr is used to check against the bitmap. The function which derives event bitmap from PMCEIDn_EL0 is executed in the cpus, which has the pmu being initialized, for heterogeneous pmu support. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 70 +++++++++++++++++++++++++++++++++--------- include/linux/perf/arm_pmu.h | 2 ++ 2 files changed, 57 insertions(+), 15 deletions(-) commit bf2d4782e7500b6e3e6f606b17b596751bc14013 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:43 2016 -0700 arm64/perf: Access pmu register using <read/write>_sys_reg changed pmu register access to make use of <read/write>_sys_reg from sysreg.h instead of accessing them directly. Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 33 ++++++++++++++++----------------- 1 file changed, 16 insertions(+), 17 deletions(-) commit 0893f74545e615eda796c8d443cafee1959f3a73 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:42 2016 -0700 arm64/perf: Define complete ARMv8 recommended implementation defined events Defined all the ARMv8 recommended implementation defined events from J3 - "ARM recommendations for IMPLEMENTATION DEFINED event numbers" in ARM DDI 0487A.g. Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 79 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) commit 03598fdbc9deaecde3d981d42cd36f108fab4aa2 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:41 2016 -0700 arm64/perf: Changed events naming as per the ARM ARM changed all the common events name definition as per the document ARM DDI 0487A.g SoC specific event names follow the general naming style in the file and doesn't reflect any document. changed ARMV8_A53_PERFCTR_PREFETCH_LINEFILL to ARMV8_A53_PERFCTR_PREF_LINEFILL to match with other SoC specific event names which use _PREF_ style. corrected typo l21 to l2i. Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/perf_event.c | 306 ++++++++++++++++++++--------------------- 1 file changed, 153 insertions(+), 153 deletions(-) commit 713755d724065d0b191fc42fda2890a1430c5038 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:40 2016 -0700 arm64: dts: Add Broadcom Vulcan PMU in dts Add "brcm,vulcan-pmu" compatible string for Broadcom Vulcan PMU. Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/boot/dts/broadcom/vulcan.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ce29daf53e513e1e0c8797b647f8833526ed8f10 Author: Ashok Kumar <ashoks@broadcom.com> Date: Thu Apr 21 05:58:39 2016 -0700 Documentation: arm64: pmu: Add Broadcom Vulcan PMU binding Document the compatible string for Broadcom Vulcan PMU. Also arranged the list in alphabetical order. Signed-off-by: Ashok Kumar <ashoks@broadcom.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/devicetree/bindings/arm/pmu.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8b182f395aa6e41973eff14619f3cdd36a6c67de Author: Kevin Hilman <khilman@baylibre.com> Date: Thu Apr 14 17:49:53 2016 -0700 ARM: davinci_all_defconfig: enable SPI and NOR as modules Enable SPI driver and SPI NOR flash support as modules. Tested with SPI NOR flash on DA850-EVM. Basic boot test only to confirm NOR flash device detection. Signed-off-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/configs/davinci_all_defconfig | 4 ++++ 1 file changed, 4 insertions(+) commit 9981293fb0f02e6127d6ab00218bf091f9f6c89b Author: Mark Rutland <mark.rutland@arm.com> Date: Mon Apr 25 11:25:11 2016 +0100 arm64: make dt_scan_depth1_nodes more readable Improve the readability of dt_scan_depth1_nodes by removing the nested conditionals. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Stefano Stabellini <sstabellini@kernel.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/acpi.c | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) commit 2366c7fdb59812bbd1382afed69e250582c64187 Author: Shannon Zhao <shannon.zhao@linaro.org> Date: Thu Apr 7 20:03:29 2016 +0800 ARM64: ACPI: Check if it runs on Xen to enable or disable ACPI When it's a Xen domain0 booting with ACPI, it will supply a /chosen and a /hypervisor node in DT. So check if it needs to enable ACPI. Signed-off-by: Shannon Zhao <shannon.zhao@linaro.org> Reviewed-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Acked-by: Hanjun Guo <hanjun.guo@linaro.org> Tested-by: Julien Grall <julien.grall@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/acpi.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) commit ef1d20e0f8a80ba2942a59331d472322794d6748 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue Apr 12 23:50:36 2016 +0200 netfilter: nft_rbtree: introduce nft_rbtree_interval_end() helper Add this new nft_rbtree_interval_end() helper function to check in the end interval is set. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nft_rbtree.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 3971ca14350062fc30b2dd3ca182234f17d268c2 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue Apr 12 23:50:35 2016 +0200 netfilter: nf_tables: parse element flags from nft_del_setelem() Parse flags and pass them to the set via ->deactivate() to check if we remove the right element from the intervals. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_tables_api.c | 38 +++++++++++++++++++++++++++++++++----- 1 file changed, 33 insertions(+), 5 deletions(-) commit 0e9091d6862f60499fa3faec7c2060c1929d0763 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue Apr 12 23:50:34 2016 +0200 netfilter: nf_tables: introduce nft_setelem_parse_flags() helper This function parses the set element flags, thus, we can reuse the same handling when deleting elements. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_tables_api.c | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) commit 141658fb02c248e6243d619cb7d48a76158a66ac Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 18 16:17:01 2016 +0200 netfilter: conntrack: use get_random_once for conntrack hash seed As earlier commit removed accessed to the hash from other files we can also make it static. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack.h | 2 -- net/netfilter/nf_conntrack_core.c | 26 +++----------------------- 2 files changed, 3 insertions(+), 25 deletions(-) commit 7001c6d109ea41a88e7156f467cf9fb5f37f5036 Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 18 16:17:00 2016 +0200 netfilter: conntrack: use get_random_once for nat and expectations Use a private seed and init it using get_random_once. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_expect.c | 7 +++---- net/netfilter/nf_nat_core.c | 6 ++++-- 2 files changed, 7 insertions(+), 6 deletions(-) commit a3efd81205b128a802025abb689925177a4607ed Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 18 16:16:59 2016 +0200 netfilter: conntrack: move generation seqcnt out of netns_ct We only allow rehash in init namespace, so we only use init_ns.generation. And even if we would allow it, it makes no sense as the conntrack locks are global; any ongoing rehash prevents insert/ delete. So make this private to nf_conntrack_core instead. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netns/conntrack.h | 1 - net/netfilter/nf_conntrack_core.c | 20 +++++++++++--------- 2 files changed, 11 insertions(+), 10 deletions(-) commit 1e3404131bcee7e24fc441bb48defb12880f4b4c Author: Sekhar Nori <nsekhar@ti.com> Date: Fri Apr 15 14:19:26 2016 +0530 ARM: davinci_all_defconfig: support systemd CONFIG_FHANDLE is required by systemd[1], which is the default init system in more and more distributions. So lets enable it for DaVinci platforms as well. While at it, remove stale entry CONFIG_INOTIFY=y [1] https://github.com/systemd/systemd/blob/master/README#L37 Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/configs/davinci_all_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 42c031dfaaadc48d0e7a8484b5ea383fe6054de0 Author: Sekhar Nori <nsekhar@ti.com> Date: Fri Apr 15 14:00:34 2016 +0530 MAINTAINERS: fix stale TI DaVinci entries Fix stale git tree entry. Patchwork project has not been updated since TI DaVinci lost its dedicated mailing list. Remove that entry. Update mailing list to point to LAKML. Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 363d79f1d5bd09158cc28db543ca18549a5d7e52 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Sat Apr 23 06:21:09 2016 -0300 [media] tw686x: Don't go past array Depending on the compiler version, currently it produces the following warnings: tw686x-video.c: In function 'tw686x_video_init': tw686x-video.c:65:543: warning: array subscript is above array bounds [-Warray-bounds] This is actually bogus with the current code, as it currently hardcodes the framerate to 30 frames/sec, however a potential use after the array size could happen when the driver adds support for setting the framerate. So, fix it. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/tw686x/tw686x-video.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 1a2b2c708c5f7187c4c33d002bed6130381a6698 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 03:37:03 2016 -0300 [media] Documentation: video4linux: fix spelling mistakes Fix spelling mistakes. Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/video4linux/vivid.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d4f90d9dca26efef7a1112a8f4258c90b73bb37f Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:35:08 2016 +0200 ixgbe: use msleep for long delays The newly added x550em_a support causes a link failure on ARM because of an overly long time passed into udelay(): ERROR: "__bad_udelay" [drivers/net/ethernet/intel/ixgbe/ixgbe.ko] undefined! There are multiple variants of the ixgbe_acquire_swfw_sync_*() function, and the other ones all use msleep(), so we can safely assume that all callers are allowed to sleep, which makes msleep() a better replacement than mdelay(). Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 49425dfc7451 ("ixgbe: Add support for x550em_a 10G MAC type") Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7921f4dc4c36e736d7a5b45dfa7b6a755a4fc012 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 20:37:15 2016 -0400 ixgbevf: Move API negotiation function into mac_ops This patch moves API negotiation into mac_ops. The general idea here is that with HyperV on the way we need to make certain that anything that will have different versions between HyperV and a standard VF needs to be abstracted enough so that we can have a separate function between the two so we can avoid changes in one breaking something in the other. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 2 +- drivers/net/ethernet/intel/ixgbevf/vf.c | 5 +++-- drivers/net/ethernet/intel/ixgbevf/vf.h | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) commit b83e30104bd9635765c562bd46b2e436350bd652 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 17:19:31 2016 -0400 ixgbe/ixgbevf: Add support for GSO partial This patch adds support for partial GSO segmentation in the case of tunnels. Specifically with this change the driver an perform segmentation as long as the frame either has IPv6 inner headers, or we are allowed to mangle the IP IDs on the inner header. This is needed because we will not be modifying any fields from the start of the start of the outer transport header to the start of the inner transport header as we are treating them like they are just a block of IP options. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 133 ++++++++++++++-------- drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 129 +++++++++++++++------ 2 files changed, 180 insertions(+), 82 deletions(-) commit 8d055cc0c8be92cd6a77193460117f0ab0a05286 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:24 2016 -0700 ixgbevf: make use of BIT() macro to avoid shift of signed values Also cleanup a case where we're bit shifting a value into place, and use an unsigned constant. Make use of the unsigned postfix in places where BIT() macro is not appropriate. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/defines.h | 24 +++++++++++------------ drivers/net/ethernet/intel/ixgbevf/ethtool.c | 3 ++- drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 8 ++++---- drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 18 ++++++++--------- 4 files changed, 27 insertions(+), 26 deletions(-) commit 3e973dc4b93da06e38b263c9bd7e239d8f3f251f Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:23 2016 -0700 ixgbe: resolve shift of negative value warning Make use of GENMASK instead of open coding the equivalent operation incorrectly. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0ba20cdcc51b1acb6ba5387ccae47ef5ef620a5b Author: Eric Engestrom <eric@engestrom.ch> Date: Sun Apr 24 21:24:20 2016 -0300 [media] Documentation: DocBook: fix spelling mistake Fix spelling mistake. Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/dvb/net.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 511257e6ae1fb87a2d0ad59ccdd61d1d4a0b9384 Author: Eric Engestrom <eric@engestrom.ch> Date: Sun Apr 24 21:24:11 2016 -0300 [media] Documentation: dt: media: fix spelling mistake Fix spelling mistake. Signed-off-by: Eric Engestrom <eric@engestrom.ch> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/devicetree/bindings/media/xilinx/video.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b4f47a483045a6e6b31be8ade76cdfef7091f18b Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Apr 13 16:08:22 2016 -0700 ixgbe: use BIT() macro Several areas of ixgbe were written before widespread usage of the BIT(n) macro. With the impending release of GCC 6 and its associated new warnings, some usages such as (1 << 31) have been noted within the ixgbe driver source. Fix these wholesale and prevent future issues by simply using BIT macro instead of hand coded bit shifts. Also fix a few shifts that are shifting values into place by using the 'u' prefix to indicate unsigned. It doesn't strictly matter in these cases because we're not shifting by too large a value, but these are all unsigned values and should be indicated as such. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 68 ++++----- drivers/net/ethernet/intel/ixgbe/ixgbe_82598.c | 6 +- drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 16 +- drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 30 ++-- drivers/net/ethernet/intel/ixgbe/ixgbe_dcb.c | 4 +- drivers/net/ethernet/intel/ixgbe/ixgbe_dcb_82598.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_dcb_82599.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_dcb_nl.c | 6 +- drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 14 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 32 ++-- drivers/net/ethernet/intel/ixgbe/ixgbe_mbx.c | 4 +- drivers/net/ethernet/intel/ixgbe/ixgbe_phy.h | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c | 4 +- drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 22 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 166 ++++++++++----------- drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c | 4 +- drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 8 +- 17 files changed, 195 insertions(+), 195 deletions(-) commit 79152e8d085fd64484afd473ef6830b45518acba Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Fri Apr 22 14:15:23 2016 +0200 crypto: s5p-sss - Fix missed interrupts when working with 8 kB blocks The tcrypt testing module on Exynos5422-based Odroid XU3/4 board failed on testing 8 kB size blocks: $ sudo modprobe tcrypt sec=1 mode=500 testing speed of async ecb(aes) (ecb-aes-s5p) encryption test 0 (128 bit key, 16 byte blocks): 21971 operations in 1 seconds (351536 bytes) test 1 (128 bit key, 64 byte blocks): 21731 operations in 1 seconds (1390784 bytes) test 2 (128 bit key, 256 byte blocks): 21932 operations in 1 seconds (5614592 bytes) test 3 (128 bit key, 1024 byte blocks): 21685 operations in 1 seconds (22205440 bytes) test 4 (128 bit key, 8192 byte blocks): This was caused by a race issue of missed BRDMA_DONE ("Block cipher Receiving DMA") interrupt. Device starts processing the data in DMA mode immediately after setting length of DMA block: receiving (FCBRDMAL) or transmitting (FCBTDMAL). The driver sets these lengths from interrupt handler through s5p_set_dma_indata() function (or xxx_setdata()). However the interrupt handler was first dealing with receive buffer (dma-unmap old, dma-map new, set receive block length which starts the operation), then with transmit buffer and finally was clearing pending interrupts (FCINTPEND). Because of the time window between setting receive buffer length and clearing pending interrupts, the operation on receive buffer could end already and driver would miss new interrupt. User manual for Exynos5422 confirms in example code that setting DMA block lengths should be the last operation. The tcrypt hang could be also observed in following blocked-task dmesg: INFO: task modprobe:258 blocked for more than 120 seconds. Not tainted 4.6.0-rc4-next-20160419-00005-g9eac8b7b7753-dirty #42 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. modprobe D c06b09d8 0 258 256 0x00000000 [<c06b09d8>] (__schedule) from [<c06b0f24>] (schedule+0x40/0xac) [<c06b0f24>] (schedule) from [<c06b49f8>] (schedule_timeout+0x124/0x178) [<c06b49f8>] (schedule_timeout) from [<c06b17fc>] (wait_for_common+0xb8/0x144) [<c06b17fc>] (wait_for_common) from [<bf0013b8>] (test_acipher_speed+0x49c/0x740 [tcrypt]) [<bf0013b8>] (test_acipher_speed [tcrypt]) from [<bf003e8c>] (do_test+0x2240/0x30ec [tcrypt]) [<bf003e8c>] (do_test [tcrypt]) from [<bf008048>] (tcrypt_mod_init+0x48/0xa4 [tcrypt]) [<bf008048>] (tcrypt_mod_init [tcrypt]) from [<c010177c>] (do_one_initcall+0x3c/0x16c) [<c010177c>] (do_one_initcall) from [<c0191ff0>] (do_init_module+0x5c/0x1ac) [<c0191ff0>] (do_init_module) from [<c0185610>] (load_module+0x1a30/0x1d08) [<c0185610>] (load_module) from [<c0185ab0>] (SyS_finit_module+0x8c/0x98) [<c0185ab0>] (SyS_finit_module) from [<c01078c0>] (ret_fast_syscall+0x0/0x3c) Fixes: a49e490c7a8a ("crypto: s5p-sss - add S5PV210 advanced crypto engine support") Cc: <stable@vger.kernel.org> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 53 +++++++++++++++++++++++++++++++++++------------- 1 file changed, 39 insertions(+), 14 deletions(-) commit 5e00c6040dfd367e35bdc7b8ef28861ff8b1dd64 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Fri Apr 22 14:15:22 2016 +0200 crypto: s5p-sss - Use common BIT macro The BIT() macro is obvious and well known, so prefer to use it instead of crafted own macro. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 95 ++++++++++++++++++++++++------------------------ 1 file changed, 47 insertions(+), 48 deletions(-) commit 4c048af708a8d562d02c5a2c8f46e01de6d81e34 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 13:01:39 2016 +0300 crypto: mxc-scc - fix unwinding in mxc_scc_crypto_register() There are two issues here: 1) We need to decrement "i" otherwise we unregister something that was not successfully registered. 2) The original code did not unregister the first element in the array where i is zero. Fixes: d293b640ebd5 ('crypto: mxc-scc - add basic driver for the MXC SCC') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/mxc-scc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b908bd3d4c4110a8a2ed84e2b6ab56fa7201db25 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 12:56:31 2016 +0300 crypto: mxc-scc - signedness bugs in mxc_scc_ablkcipher_req_init() ->src_nents and ->dst_nents are unsigned so they can't be less than zero. I fixed this by introducing a temporary "nents" variable. Fixes: d293b640ebd5 ('crypto: mxc-scc - add basic driver for the MXC SCC') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/mxc-scc.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 3639ca840df953f9af6f15fc8a6bf77f19075ab1 Author: Horia Geant? <horia.geanta@nxp.com> Date: Thu Apr 21 19:24:55 2016 +0300 crypto: talitos - fix ahash algorithms registration Provide hardware state import/export functionality, as mandated by commit 8996eafdcbad ("crypto: ahash - ensure statesize is non-zero") Cc: <stable@vger.kernel.org> # 4.3+ Reported-by: Jonas Eymann <J.Eymann@gmx.net> Signed-off-by: Horia Geant? <horia.geanta@nxp.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/talitos.c | 64 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) commit b3c2fee5d66b0d1e977de1a56243002e532da6a5 Author: Gary R Hook <gary.hook@amd.com> Date: Wed Apr 20 09:55:12 2016 -0500 crypto: ccp - Ensure all dependencies are specified A DMA_ENGINE requires DMADEVICES in Kconfig Signed-off-by: Gary R Hook <gary.hook@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/ccp/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 035677761fec4a472491d53f4dfa5dbc8edd2f7a Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 10:03:41 2016 -0300 [media] media/i2c/adv*: make controls inheritable instead of private Marking these controls as private seemed a good idea at one time, but in practice it makes no sense. So drop this. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/ad9389b.c | 8 -------- drivers/media/i2c/adv7511.c | 6 ------ drivers/media/i2c/adv7604.c | 8 -------- drivers/media/i2c/adv7842.c | 6 ------ 4 files changed, 28 deletions(-) commit c040a71f1a79caa132f718ef533d47ec63a0efd2 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 10:03:40 2016 -0300 [media] tc358743: drop bogus comment The control in question is not a private control, so drop that comment. Copy-and-paste left-over. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/tc358743.c | 1 - 1 file changed, 1 deletion(-) commit dc96208582156fafd946368853bc108096dee9f9 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Mon Apr 25 08:11:41 2016 -0300 [media] sta2x11: remove unused vars Changeset 7b9f31f3b3ca ("[media] sta2x11_vip: fix s_std") removed autodetect code, but it kept two vars unused: drivers/media/pci/sta2x11/sta2x11_vip.c: In function 'vidioc_s_std': drivers/media/pci/sta2x11/sta2x11_vip.c:448:6: warning: unused variable 'status' [-Wunused-variable] int status; ^ drivers/media/pci/sta2x11/sta2x11_vip.c:447:14: warning: unused variable 'oldstd' [-Wunused-variable] v4l2_std_id oldstd = vip->std; ^ Remove them. Fixes: 7b9f31f3b3ca ("[media] sta2x11_vip: fix s_std") Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/sta2x11/sta2x11_vip.c | 2 -- 1 file changed, 2 deletions(-) commit 4319a7976722f6925b5bbbdac417d87a0cbde859 Author: Don Skidmore <donald.c.skidmore@intel.com> Date: Tue Apr 12 19:25:10 2016 -0400 ixgbe: Add work around for empty SFP+ cage crosstalk It is possible on some systems that crosstalk could lead to link flap on empty SFP+ cages. A new NVM bit was defined to let SW know it needs to implement the work around which consists of verifying that there is a module in the cage before acting on the LSC. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 39 +++++++++++++++++++++++++++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 1 + 3 files changed, 42 insertions(+) commit 7b9f31f3b3cab9bc367ba4da45af129ff858ce52 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 10:03:38 2016 -0300 [media] sta2x11_vip: fix s_std The s_std ioctl was broken in this driver, partially due to the changes to the adv7180 driver (this affected the handling of V4L2_STD_ALL) and partially because the new standard was never stored in vip->std. The handling of V4L2_STD_ALL has been rewritten to just call querystd and the new standard is now stored correctly. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Federico Vaga <federico.vaga@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/sta2x11/sta2x11_vip.c | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) commit 937feeed3f0ae8a0389d5732f6db63dd912acd99 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 10:03:37 2016 -0300 [media] adv7180: fix broken standards handling The adv7180 attempts to autodetect the standard. Unfortunately this is seriously broken. This patch removes the autodetect completely. Only the querystd op will detect the standard. Since the design of the adv7180 requires that you switch to a special autodetect mode you cannot call querystd when you are streaming. So the s_stream op has been added so we know whether we are streaming or not, and if we are, then querystd returns EBUSY. After testing this with a signal generator is became obvious that a sleep is needed between changing the standard to autodetect and reading the status. So the autodetect can never have worked well. The s_std call now just sets the new standard without any querying. If the driver supports the interrupt, then when it detects a standard change it will signal that by sending the V4L2_EVENT_SOURCE_CHANGE event. With these changes this driver now behaves like all other video receivers. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Federico Vaga <federico.vaga@gmail.com> Tested-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/adv7180.c | 118 ++++++++++++++++++++++++++++++-------------- 1 file changed, 80 insertions(+), 38 deletions(-) commit a0254a70b4f91396ad04b1225dd7c10a680d38ff Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 8 16:19:29 2016 -0700 ixgbe: Use correct FC setup function for x550em_a Somehow the wrong fc_setup function was used for x550em_a, so correct that. Also set setup_link to NULL as its value is determined later, just like it is with X550EM_x. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 20e01b264cc8557def19671defbad275828132f1 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 07:03:30 2016 -0300 [media] cx231xx: silence uninitialized variable warning We print an uninitialized "actlen" variable on the error path. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/cx231xx/cx231xx-core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 079dda54fe6e43b3db919e3ac3838a1355464c78 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 06:06:59 2016 -0300 [media] DocBook media: drop 'experimental' annotations Drop the 'experimental' annotations. The only remaining part of the API that is still marked 'experimental' are the debug ioctls/structs, and that is intentional. Only the v4l2-dbg application should use those. All others have been around for years, so it is time to drop the 'experimental' designation. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/v4l/compat.xml | 38 ---------------------- Documentation/DocBook/media/v4l/controls.xml | 31 ------------------ Documentation/DocBook/media/v4l/dev-sdr.xml | 6 ---- Documentation/DocBook/media/v4l/dev-subdev.xml | 6 ---- Documentation/DocBook/media/v4l/io.xml | 6 ---- Documentation/DocBook/media/v4l/selection-api.xml | 9 +---- Documentation/DocBook/media/v4l/subdev-formats.xml | 6 ---- .../DocBook/media/v4l/vidioc-create-bufs.xml | 6 ---- .../DocBook/media/v4l/vidioc-dv-timings-cap.xml | 6 ---- .../DocBook/media/v4l/vidioc-enum-dv-timings.xml | 6 ---- .../DocBook/media/v4l/vidioc-enum-freq-bands.xml | 6 ---- Documentation/DocBook/media/v4l/vidioc-expbuf.xml | 6 ---- .../DocBook/media/v4l/vidioc-g-selection.xml | 6 ---- .../DocBook/media/v4l/vidioc-prepare-buf.xml | 6 ---- .../DocBook/media/v4l/vidioc-query-dv-timings.xml | 6 ---- .../v4l/vidioc-subdev-enum-frame-interval.xml | 6 ---- .../media/v4l/vidioc-subdev-enum-frame-size.xml | 6 ---- .../media/v4l/vidioc-subdev-enum-mbus-code.xml | 6 ---- .../DocBook/media/v4l/vidioc-subdev-g-fmt.xml | 6 ---- .../media/v4l/vidioc-subdev-g-frame-interval.xml | 6 ---- .../media/v4l/vidioc-subdev-g-selection.xml | 6 ---- 21 files changed, 1 insertion(+), 185 deletions(-) commit d8fc68a04d2ffa7327a5fd89d4cd9f2fe24659d3 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Fri Apr 22 18:48:04 2016 +0200 arm64: ptdump: add region marker for kasan shadow region Annotate the KASAN shadow region with boundary markers, so that its mappings stand out in the page table dumper output. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/dump.c | 5 +++++ 1 file changed, 5 insertions(+) commit c8f8cca483aa3ec1beb63ee8633de9c76bb3fe6f Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Fri Apr 22 18:48:03 2016 +0200 arm64: ptdump: use static initializers for vmemmap region boundaries There is no need to initialize the vmemmap region boundaries dynamically, since they are compile time constants. So just add these constants to the global struct initializer, and drop the dynamic assignment and related code. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/dump.c | 49 +++++++++++++------------------------------------ 1 file changed, 13 insertions(+), 36 deletions(-) commit 57c7598711b820b4253bcee94ec750ebc1c63af6 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 22 06:06:58 2016 -0300 [media] videodev2.h: remove 'experimental' annotations Most of what is marked as 'experimental' has been around for years. Time to drop that annotation. The only remaining 'experimental' bits of the API are the debug ioctls and structs: these should remain experimental since the only application that should use this is v4l2-dbg. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/uapi/linux/videodev2.h | 38 ++++++++++---------------------------- 1 file changed, 10 insertions(+), 28 deletions(-) commit bde569874b2afa6571eee6c373b236a8cd292115 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Thu Apr 21 03:23:58 2016 -0300 [media] tw686x-video: test for 60Hz instead of 50Hz When determining if the standard is 50 or 60 Hz it is standard practice to test for 60 Hz instead of 50 Hz. This doesn't matter normally, except if the user specifies both 60 and 50 Hz standards. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/tw686x/tw686x-video.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a02a5a53418a6039893f5d5a9373cf18080fded2 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Apr 7 15:58:44 2016 -0700 ixgbevf: add support for per-queue ethtool stats Implement per-queue statistics for packets, bytes and busy poll specific counters. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ethtool.c | 127 +++++++++++++++++++-------- drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 10 --- 2 files changed, 91 insertions(+), 46 deletions(-) commit d72d6c19b583afc09ace22baf80b29b11139a8f3 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Apr 7 15:58:39 2016 -0700 ixgbevf: refactor ethtool stats handling This brings the logic closer to how we handle the stats in ixgbe and it sets us up for introducing per-queue stats. Use IXGBEVF_STAT and IXGBEVF_NETDEV_STAT for accessing the driver and netdev stats respectively. This way we don't have to calculate the stats based on register values which could lead to the counters not being initialized properly when the interface is down. IXGBEVF_QUEUE_STATS_LEN is set to include the number of queues. Also some defines were renamed to use the IXGBEVF prefix. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ethtool.c | 126 ++++++++++++++------------- 1 file changed, 64 insertions(+), 62 deletions(-) commit 2f2219bea21118511c23d24dba5f2145f870a7db Author: Mark Rustad <mark.d.rustad@intel.com> Date: Thu Apr 7 10:43:50 2016 -0700 ixgbe: Add register wait for slow links Use a new register to wait for previous register writes to complete before issuing a register read. This is needed when slower links are in use. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 21 +++++++++++++++++++++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 1 + 2 files changed, 22 insertions(+) commit 8c34d82e9dc67bb06e20e015ec677f82b72a26b3 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 20 14:26:58 2016 -0400 USB: serial: use IS_ENABLED() instead of checking for FOO || FOO_MODULE The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/usb-serial.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3c77f7c9e96bc40ac6985dd595cdd551afd34f2e Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sat Apr 9 13:02:28 2016 +0200 USB: serial: ftdi_sio: constify ftdi_sio_quirk structures The ftdi_sio_quirk structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Johan Hovold <johan@kernel.org> drivers/usb/serial/ftdi_sio.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 2b4e38fd7c12d37ee1887834eb45ae30b5e8f4e3 Author: Brian Starkey <brian.starkey@arm.com> Date: Thu Apr 14 16:39:18 2016 +0100 ARM: dts: vexpress: Add external expansion bus to DT The VExpress development platform has an external expansion bus which can be used for additional hardware (e.g. LogicTile Express daughter boards). Add this bus to the VExpress CoreTile device-trees.The bus is described for a CoreTile occupying site 1. Acked-by: Liviu Dudau <Liviu.Dudau@arm.com> Signed-off-by: Brian Starkey <brian.starkey@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/boot/dts/vexpress-v2p-ca15-tc1.dts | 13 +++++++++++++ arch/arm/boot/dts/vexpress-v2p-ca15_a7.dts | 13 +++++++++++++ arch/arm/boot/dts/vexpress-v2p-ca5s.dts | 13 +++++++++++++ arch/arm/boot/dts/vexpress-v2p-ca9.dts | 13 +++++++++++++ 4 files changed, 52 insertions(+) commit 2cff6dba57b74129e0fd6f201cedf236f49f97e9 Author: Sudeep Holla <sudeep.holla@arm.com> Date: Mon Mar 7 11:54:45 2016 +0000 ARM: dts: vexpress: fix node name unit-address presence warnings Commit b993734718c0 ("scripts/dtc: Update to upstream version 53bf130b1cdd") added warnings on node name unit-address presence/absence mismatch in the device trees. This patch fixes those warning on all the vexpress platforms where unit-address is present in node name while the reg/ranges property is not present. Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm/boot/dts/vexpress-v2m-rs1.dtsi | 44 ++++++++++++++--------------- arch/arm/boot/dts/vexpress-v2m.dtsi | 44 ++++++++++++++--------------- arch/arm/boot/dts/vexpress-v2p-ca15-tc1.dts | 34 +++++++++++----------- arch/arm/boot/dts/vexpress-v2p-ca15_a7.dts | 44 ++++++++++++++--------------- arch/arm/boot/dts/vexpress-v2p-ca5s.dts | 24 ++++++++-------- arch/arm/boot/dts/vexpress-v2p-ca9.dts | 28 +++++++++--------- 6 files changed, 109 insertions(+), 109 deletions(-) commit bbf4ac9cfa9b681e3b657699f39fc855408904b8 Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Wed Apr 20 20:33:05 2016 +0200 HID: thingm: remove not needed error message LED core takes care of handling failed calls to thingm_let_set. - print error message in set_brightness_delayed or - pass error to caller in led_set_brightness_sync Also the error message here doesn't provide any hint what actually went wrong. Therefore remove it. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@rehat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-thingm.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 8d84c1973b69621bcb89d5d8a69699e8347a3d90 Author: Eric Engestrom <eric@engestrom.ch> Date: Mon Apr 25 07:37:02 2016 +0100 ALSA: doc: fix spelling mistakes Signed-off-by: Eric Engestrom <eric@engestrom.ch> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Documentation/sound/alsa/compress_offload.txt | 2 +- Documentation/sound/alsa/soc/dapm.txt | 2 +- Documentation/sound/alsa/soc/overview.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit ff2bb89335daec6053b5ac778369f7f72b931142 Author: Jens Kuske <jenskuske@gmail.com> Date: Fri Mar 18 09:44:15 2016 +0000 clk: sunxi: Let divs clocks read the base factor clock name from devicetree Currently, the sunxi clock driver gets the name for the base factor clock of divs clocks from the name field in factors_data. This prevents reusing of the factor clock for clocks with same properties, but different name. This commit makes the divs setup function try to get a name from clock-output-names in the devicetree. It also removes the name field where possible and merges the sun4i PLL5 and PLL6 clocks. [Andre: Make temporary name allocation dynamic.] Signed-off-by: Jens Kuske <jenskuske@gmail.com> Signed-off-by: Andre Przywara <andre.przywara@arm.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/clk/sunxi/clk-sunxi.c | 41 ++++++++++++++++++++++++++++++----------- 1 file changed, 30 insertions(+), 11 deletions(-) commit 34ce71a96dcba24c71b07f1b087bd179b885784d Author: Alexandre Belloni <alexandre.belloni@free-electrons.com> Date: Sat Apr 23 02:58:05 2016 +0200 ALSA: timer: remove legacy rtctimer There are no users of rtctimer left. Remove its code as this is the in-kernel user of the legacy PC RTC driver that will hopefully be removed at some point. Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> include/uapi/sound/asound.h | 2 +- sound/core/Kconfig | 29 ------- sound/core/Makefile | 1 - sound/core/rtctimer.c | 187 -------------------------------------------- sound/core/seq/seq.c | 2 - sound/core/timer.c | 2 - 6 files changed, 1 insertion(+), 222 deletions(-) commit b610386c8afba397238329c50c45a3abc79ba45f Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:09 2016 +0900 ALSA: firewire-tascam: deleyed registration of sound card When some tascam units are connected sequentially, userspace applications are involved at bus-reset state on IEEE 1394 bus. In the state, any communications can be canceled. Therefore, sound card registration should be delayed till the bus gets calm. This commit achieves it. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/tascam/tascam.c | 118 ++++++++++++++++++++++++++++------------- sound/firewire/tascam/tascam.h | 2 + 2 files changed, 84 insertions(+), 36 deletions(-) commit 5ff18e42ddfd9ab67088b2d7081380943b9f0cab Author: Emil Velikov <emil.l.velikov@gmail.com> Date: Fri Apr 22 00:03:52 2016 +0100 MAINTAINERS: Update the files list for the GMA500 DRM driver Cc: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> Cc: dri-devel@lists.freedesktop.org Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461279842-28695-5-git-send-email-emil.l.velikov@gmail.com MAINTAINERS | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit b52e345d43cfe9214fecfa92375525a086d39581 Author: Christopher Spinrath <christopher.spinrath@rwth-aachen.de> Date: Mon Apr 25 01:02:58 2016 +0200 ARM: dts: sun7i: Enable S/PDIF on the Cubietruck Enable the S/PDIF transmitter present on the Cubietruck. Signed-off-by: Christopher Spinrath <christopher.spinrath@rwth-aachen.de> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20-cubietruck.dts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 6ddf93e05e67f81b6a95840c35e1aa6e042196a8 Author: Caesar Wang <wxt@rock-chips.com> Date: Fri Apr 22 18:02:54 2016 +0800 arm64: dts: rockchip: move the rk3368 thermal data into rk3368.dtsi In order to be standard to manage for rockchip SoCs, move the thermal data into rk3368 dtsi, we needn't to add a new file for thermal. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3368-thermal.dtsi | 112 ----------------------- arch/arm64/boot/dts/rockchip/rk3368.dtsi | 66 ++++++++++++- 2 files changed, 65 insertions(+), 113 deletions(-) commit f87305fa00b1d0633d2dc5fd7fb4995bed6a59e8 Author: Caesar Wang <wxt@rock-chips.com> Date: Fri Apr 22 18:02:53 2016 +0800 ARM: dts: rockchip: move the rk3288 thermal data into rk3288.dtsi In order to be standard to manage for rockchip SoCs, move the thermal data into rk3288 dtsi, we needn't to add a new file for thermal. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288-thermal.dtsi | 118 ---------------------------------- arch/arm/boot/dts/rk3288.dtsi | 73 ++++++++++++++++++++- 2 files changed, 72 insertions(+), 119 deletions(-) commit 5b4fd5b1111b1230cd037df3b314e7b36d45d483 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon Apr 25 09:35:38 2016 +0200 drm/i915: Update DRIVER_DATE to 20160425 Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b8199ff31f86ee94fa1166997259b03022ecb4de Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 24 23:44:13 2016 +0100 clk: rockchip: fix of spelling mistake on unsuccessful in pll clock type fix spelling mistake, unsucessful -> unsuccessful Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-pll.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6f92cb2f454c26d9bdada902e22af4bc361a5202 Author: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Date: Mon Apr 18 18:02:57 2016 +0200 ARM: dts: gose: Enable SDHI controllers Includes regulator and pin assignments. Signed-off-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793-gose.dts | 119 +++++++++++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) commit fc9ee228f5005437b9fdb1b85804b6d3f8d497be Author: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Date: Mon Apr 18 18:02:56 2016 +0200 ARM: dts: r8a7793: Add SDHI controllers Same as on r8a7791. Signed-off-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793.dtsi | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 21c7d0fcbe10a1a81fb791a9bdcca2381bc16c15 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon Apr 18 11:41:30 2016 +0200 ARM: dts: r8a7790: fix max-frequency for SDHI The wrong values come from an old datasheet (H2 v0.6). Anything later has the fixed value of 195MHz (H2 v0.7 up to Gen2-common V2.0). Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7e2a1bcd2185c9d7d4c9b2910249a1a8fa841341 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 11:58:42 2016 +0200 ARM: dts: kzm9g: Configure NMI key as wake-up source Add a GPIO key with wake-up capability for the NMI button. This allows to wake up the system from s2ram without relying on the buttons on the optional switch board. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/sh73a0-kzm9g.dts | 7 +++++++ 1 file changed, 7 insertions(+) commit 1ca79699cb958c17b0b08d9f9bd683e5011e7927 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Fri Apr 1 17:44:39 2016 +0200 ARM: dts: r8a7790: lager: Enable UHS-I SDR-50 Add the "1v8" pinctrl state and sd-uhs-sdr50 property to SDHI{0,2}. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790-lager.dts | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) commit 15cfd40771e18a4e9b788c64c9db2606f958b93d Author: Haiyang Zhang <haiyangz@microsoft.com> Date: Thu Apr 21 16:13:01 2016 -0700 hv_netvsc: Fix the list processing for network change event RNDIS_STATUS_NETWORK_CHANGE event is handled as two "half events" -- media disconnect & connect. The second half should be added to the list head, not to the tail. So all events are processed in normal order. Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Reviewed-by: K. Y. Srinivasan <kys@microsoft.com> Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/netvsc_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2a9ed5d1fc5e7e88a22da2d85bbaf6fc5b4c2fb8 Author: Sridhar Samudrala <sridhar.samudrala@intel.com> Date: Fri Apr 1 10:34:38 2016 -0700 ixgbe: make 'action' field in struct ixgbe_fdir_filter a u64 value This field is used to record the RX queue index for a redirect action passed via ring_cookie field in struct ethtool_rx_flow_spec which is a u64 value. For ex: after adding a filter rule to redirect to a VF using ethtool # echo 4 > /sys/class/net/p4p1/device/sriov_numvfs # ethtool -N p4p1 flow-type ip4 src-ip 192.168.0.1 action 0x100000000 querying for the rule shows the Action as 'Direct to queue 0' # ethtool -n p4p1 4 RX rings available Total 1 rules Filter: 2045 Rule Type: Raw IPv4 Src IP addr: 192.168.0.1 mask: 0.0.0.0 Dest IP addr: 0.0.0.0 mask: 255.255.255.255 TOS: 0x0 mask: 0xff Protocol: 0 mask: 0xff L4 bytes: 0x0 mask: 0xffffffff VLAN EtherType: 0x0 mask: 0xffff VLAN: 0x0 mask: 0xffff User-defined: 0x0 mask: 0xffffffffffffffff Action: Direct to queue 0 With this fix, ethtool will report the right queue index even for VFs. Action: Direct to queue 4294967296 Here 4294967296 corresponds to 0x100000000. We need to update 'ethtool' to report the queue index as a Hex value so that it is more user friendly and matches with the 'action' value that is passed when adding the rule. Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4695886c644e48a02ca9d4c146a7ec4de8f2d2d8 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Mar 24 09:58:40 2016 -0700 ixgbe: fix default mac->ops.setup_link for X550EM X550EM_a/x did not have a default value for mac->ops.setup_link which was causing link issues for backplane devices. This patch sets mac->ops.setup_link to ixgbe_setup_mac_link_X540 for X550EM_a/x which is also default for X550. This will result in mac->ops.setup_link calling the link setup function for the respective PHY type in case we do not need a special function to deal with it. Reported-by: Ken Cox <jkc@redhat.com> Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d3dec7c7c03351ae006f698501b523e7b1a38b3d Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Fri Mar 18 16:11:19 2016 -0700 ixgbe: set VLAN spoof checking unconditionally Previously the PF driver would only set VLAN spoof checking if the VF had created VLANs. This was done by setting and checking a counter (vlan_count) whenever a VLAN was created by the VF. However it is possible for the vlan_count to be !=0 while there are no VLANs assigned to the VF due to the count incrementing every time a VLAN 0 is added on ifdown/up, which resulted in VLAN spoofing always being set for those VFs. This patch cleans up the logic by unconditionally setting VLAN based on how the VF is configured (via ip link set ethX vf Y spoofchk on/off). This change also resolves an issue where the VLAN spoofing can remain set even after being disabled by the user due to the driver enabling VLAN spoof checking every time a VLAN is added to the VF, but would only allow changes in the setting if vlan_count != 0. Also default_vf_vlan_id and vlans_enabled were removed from the vf_data_storage structure since they are not being used in the driver. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 3 --- drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 25 ++----------------------- 2 files changed, 2 insertions(+), 26 deletions(-) commit 77f192af721440a9d91365438be6ecb98edd0310 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Fri Mar 18 16:11:14 2016 -0700 ixgbe: consolidate the configuration of spoof checking Consolidate the logic behind configuring spoof checking: Move the setting of the MAC, VLAN and Ethertype spoof checking into ixgbe_ndo_set_vf_spoofchk(). Change ixgbe_set_mac_anti_spoofing() to set MAC spoofing per VF similar to the VLAN and Ethertype functions - this allows us to call the helper functions in ixgbe_ndo_set_vf_spoofchk() for all spoof check types and only disable MAC spoof checking when creating MACVLAN. Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 40 +++++++---------------- drivers/net/ethernet/intel/ixgbe/ixgbe_common.h | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 30 ++--------------- drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 43 ++++++++++++++++--------- 4 files changed, 42 insertions(+), 73 deletions(-) commit 9b61aefce7b41cf3ae1c3c2b205fdfca3a537adc Author: Lars Persson <lars.persson@axis.com> Date: Mon Mar 14 10:01:43 2016 +0100 ARM: dts: artpec: update clock bindings in artpec6.dtsi The clock binding for the main clock controller was changed to an indexed controller style binding on request of the clk maintainers. This updates the dtsi to use the new bindings. Signed-off-by: Lars Persson <larper@axis.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/artpec6.dtsi | 99 +++++++++--------------------------------- 1 file changed, 20 insertions(+), 79 deletions(-) commit fe0082d47380999f5b112cc54bed86c365796b3d Merge: 312ce1d 3db6360 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:58:18 2016 +0200 Merge tag 'qcom-dt-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux into next/dt Merge "Qualcomm Device Tree Changes for v4.7" from Andy Gross: * Add DB600C support * Add IPQ4019 support * Add additional nodes for APQ8064 * Fix APQ8064 pinctrls for i2c/spi * Add MSM8974 nodes for smp2p and smd * Modify MSM8974 memory reserve for rfsa and rmtfs * Add support for BQ27541 on Nexus7 * tag 'qcom-dt-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux: (30 commits) device-tree: nexus7: Add bq27541 battery interface to dts ARM: dts: db600c: add support to magnetometer ARM: dts: db600c: add spi support ARM: dts: db600c: add i2c support ARM: dts: db600c: Add on board leds support ARM: dts: db600c: add on board sata support. ARM: dts: db600c: add pcie support ARM: dts: db600c: add usb support ARM: dts: db600c: Add eMMC and SD card support ARM: dts: db600c: add pmic regulator supplies ARM: dts: db600c: add board support with serial ARM: dts: apq8064: add gsbi7 i2c support ARM: dts: apq8064: add support to gsbi1 uart ARM: dts: apq8064: fix the pinctrls for i2c and spi ARM: dts: qcom: apq8064: Add smd node and all edges ARM: dts: qcom: apq8064: Add complete smsm node ARM: dts: qcom: apq8064: Add syscon for sic-non-secure ARM: dts: msm8974: Add modem smp2p and smd nodes ARM: dts: msm8974: Add node for second i2c from blsp1 ARM: dts: msm8974: Split efs in rfsa and rmtfs ... commit 312ce1d19155a20c6d829b6e9fc028d4b0238c2b Merge: 1ea7c8b 3db62af Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:56:38 2016 +0200 Merge tag 'arm-soc/for-4.7/devicetree' of http://github.com/Broadcom/stblinux into next/dt Merge "Broadcom ARM-based SoC Device Tree changes" from Florian Fainelli: - Rafal adds proper VCC GPIO to be fed to the USB host controllers for known BCM5301x devices needing that, he also enables earlycon, and enables the SPI-NOR flashes on relevant devices - Eric adds the VideoCore 4 Device Tree nodes to the BCM283x Device Tree and provides a DRM patch to kick out the simplefb framebuffer to avoid conflicts - Stephan adds proper CPU nodes for the ARM processor on the BCM2835 SoC Device Tree - Martin provides a binding fix for the DMA channel interrupt numbers and description * tag 'arm-soc/for-4.7/devicetree' of http://github.com/Broadcom/stblinux: ARM: BCM5301X: Add DT entry for SPI controller and NOR flash dt/bindings: bcm2835: correct description for DMA-int ARM: bcm2835: add CPU node for ARM core ARM: bcm2835: Add VC4 to the device tree. drm/vc4: Kick out the simplefb framebuffer before we set up KMS. ARM: BCM5301X: Enable earlycon on tested devices ARM: BCM5301X: Set vcc-gpio for USB controllers of few devices commit 1ea7c8b6fb23f5a8afec7c7ddc5776550331a2bf Merge: c2499d6 a4240d3 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:43:56 2016 +0200 Merge tag 'omap-for-v4.7/dt-part1' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/dt Merge "First set of device tree changes for omaps for v4.7 merge window" from Tony Lindgren: - Two sets of name and unit address check fixes for dts files. - DMA, McASP, and timer and regulator related dts changes for dra7 - Add more devices for Nokia N9/N950 - Initial support for am335x ICEv2 - Initial support for am572x-IDK - Pinctrl changes for am335x-baltos-ir5221 - Initial support for Amazon Kindle Fire (first generation) - A series of changes to add GPIO controller support for the GPMC driver. The driver changes will be merged separately. - Support for am43xx clkout1 - Pinctrl and RTC changes for am335x-chili - Add support for dra72-evm rev C (SR2.0) * tag 'omap-for-v4.7/dt-part1' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: (61 commits) ARM: dts: Add support for dra72-evm rev C (SR2.0) ARM: dts: am335x-chilisom: Enable poweroff PMIC sequence using RTC signal ARM: dts: am335x-chili*: Move Ethernet MAC description from SOM to board ARM: dts: am335x-chili*: Move uart0 description from SOM to board ARM: dts: am43xx: add support for clkout1 clock ARM: dts: omap3-beagle: Provide NAND ready pin ARM: dts: am335x: Provide NAND ready pin ARM: dts: am437x: Provide NAND ready pin ARM: dts: dra7x-evm: Provide NAND ready pin ARM: dts: dm816x: Enable gpio controller for GPMC ARM: dts: dm814x: Enable gpio controller for GPMC ARM: dts: omap3: Enable gpio controller for GPMC ARM: dts: am4372: Enable gpio controller for GPMC ARM: dts: am335x: Enable gpio controller for GPMC ARM: dts: dra7: Enable gpio controller for GPMC ARM: dts: omap5: Enable gpio and interrupt controller for GPMC ARM: dts: omap4: Enable gpio and interrupt controller for GPMC ARM: dts: omap24xx: Enable gpio and interrupt controller for GPMC ARM: dts: omap4-kc1: Power off support ARM: dts: omap4-kc1: LEDs support ... commit c2499d68b162ab50bc40e01ad4c4d908993a0609 Merge: 62547ba 839a04d Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:39:29 2016 +0200 Merge tag 'renesas-rcar-sysc-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Pull "Renesas ARM Based SoC R-Car SYSC Updates for v4.7" from Simon Horman: * Add DT bindings for the R-Car System Controller. An implementation is intended to follow. * tag 'renesas-rcar-sysc-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: soc: renesas: Add r8a7795 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7794 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7793 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7791 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7790 SYSC PM Domain Binding Definitions soc: renesas: Add r8a7779 SYSC PM Domain Binding Definitions PM / Domains: Add DT bindings for the R-Car System Controller commit 62547ba352e9c30912694eac4431ca6018da5ba2 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Apr 21 11:11:23 2016 +0900 ARM: dts: uniphier: add NAND pinmux node This commit adds pin-mux nodes for the NAND controller. Some SoCs support 2 chip selects and the others only support 1 chip select. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> arch/arm/boot/dts/uniphier-pinctrl.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 412252ac8c1fef358286d219faa51cb8607adb98 Merge: a5cc8c3 880e150 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:36:10 2016 +0200 Merge tag 'imx-dt-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into next/dt Merge "The i.MX device tree updates for 4.7" from Shawn Guo: - More i.MX6 System-on-Module board support from Ka-Ro electronics: tx6s-8xxx, tx6u-8xxx, tx6q-1xxx, tx6ul-00xx. - Nitrogen6_MAX QP and Nitrogen6_SoloX board support from Boundary Devices. - VF610 based ZII development board support. - Add SAI interface audio support for i.MX6SX SDB board. - A number of random updates on LS1021A and VF610 dts files. - A couple of pinumx updates on i.MX25 and i.MX28. * tag 'imx-dt-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: (36 commits) ARM: dts: imx6qdl-udoo: add 7 inch LCD touchscreen panel support ARM: dts: i.MX3x: add keypad port devicetree nodes ARM: dts: ls1021a: add pix clock to DCU dts node ARM: dts: ls1021a: DSPI has 6 chip-selects ARM: dts: ls1021a: Add gpio support for ls1021a platform ARM: dts: imx6q-ba16: Remove unused vqmmc-supply ARM: dts: ls1021a: add SCFG MSI dts node ARM: dts: imx28: add alternative pinmuxing for mac0 ARM: dts: imx6q-tbs2910: fix fec reset polarity ARM: dts: vf610-zii-dev: Add ZII development board. ARM: dts: vfxxx: add missing reg properties ARM: dts: vf-colibri: increase NAND clock speed ARM: dts: vf-colibri: alias the primary FEC as ethernet0 ARM: dts: imx6sx-sdb: Add SAI support bindings: fsl-imx-sdma: Document 'fsl,sdma-event-remap' property ARM: dts: imx6sx: Remove unused property ARM: dts: imx6sx: Fix SAI DMA index ARM: dts: imx6q-ba16: Disable pwm2 by default ARM: dts: imx: add Boundary Devices Nitrogen6_SoloX board ARM: dts: imx6qdl-sabresd: Pass the hannstar panel compatible string ... commit a5cc8c3a715caa17e5da7ca795ae38919a5b68a3 Merge: cb3ba4f e7d9b27 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:27:30 2016 +0200 Merge tag 'tegra-for-4.7-arm' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/dt Merge "ARM: tegra: Changes for v4.7-rc1" from Thierry Reding: A couple of patches that cleanup some Kconfig, enable various features, use stdout-path to define the debug serial port (so that it doesn't have to be manually specified on the kernel command-line) and cleanup and fix some minor device trees bugs. * tag 'tegra-for-4.7-arm' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: ARM: tegra: Correct interrupt type for ARM TWD ARM: tegra: Add stdout-path for various boards ARM: tegra: Replace legacy *,wakeup property with wakeup-source ARM: tegra: Enable watchdog support for Tegra114 and Tegra124 ARM: tegra: Add high speed UARTs to Jetson TK1 device tree ARM: tegra: Fix copy/paste typo in several DTS includes ARM: tegra: Remove redundant ARM_L1_CACHE_SHIFT_6 select commit cb3ba4f716e4e41a1a5ecddecaf42ad3ac711506 Merge: bb12fbd 6c8f735 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:25:44 2016 +0200 Merge tag 'davinci-for-v4.7/dt' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into next/dt Merge "Device-Tree updates for DaVinci" from Sekhar Nori: This contains some clean-up and fixes of device-tree data and addition of i2c1 node for DA850. * tag 'davinci-for-v4.7/dt' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci: ARM: davinci: da8xx-dt: add OF_DEV_AUXDATA entry for i2c1 ARM: DTS: da850: add node for i2c1 ARM: dts: davinci: use proper address after @ ARM: DTS: da850: fix missing #gpio-cells in gpio node commit bb12fbd2cc90b22259d8ddd3edc965e2b914f3ff Merge: 6a6e2d6 a22d776 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:23:53 2016 +0200 Merge tag 'nomadik-dts-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-nomadik into next/dt Merge "Nomadik DTS changes for v4.7" from Linus Walleij: - Add accelerometer for NHK15 - Add DMA engine definitions and UART channels * tag 'nomadik-dts-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-nomadik: ARM: dts: nomadik: add DMA engine and some channels ARM: dts: nomadik: add accelerometer IRQ and pin setting commit 6a6e2d6121b17b9a8df98e4dabb45d0476bedd66 Merge: 9744426e c134043 Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:21:34 2016 +0200 Merge tag 'mvebu-dt-4.7-1' of git://git.infradead.org/linux-mvebu into next/dt Merge "mvebu dt for 4.7 (part 1)" from Gregory CLEMENT: - add hardware monitor support in the NSA320 device tree - update makefile with kirkwood-ds112.dtb and kirkwood-nsa320.dtb - fix GPIO config on the Linksys boards - various Kirkwood DT warning fixup from the newer DT compiler * tag 'mvebu-dt-4.7-1' of git://git.infradead.org/linux-mvebu: ARM: dts: kirkwood: Add DTS for Linksys EA4200v2/EA4500 ARM: dts: orion5x: add device tree for kurobox-pro ARM: dts: kirkwood: Add address go regulator unit name ARM: dts: kirkwood: Add address to mbus unit name ARM: dts: kirkwood: Remove address from gpio-i2c unit name ARM: dts: kirkwood: Fixup pcie DT warnings ARM: dts: kirkwood: Add address to ethernet-phy unit name ARM: dts: kirkwood: Remove address from dsa unit name ARM: dts: kirkwood: Remove node address from leds ARM: dts: kirkwood: Remove button address and fixup names ARM: dts: kirkwood: add kirkwood-nsa320.dtb to Makefile ARM: dts: kirkwood: add kirkwood-ds112.dtb to Makefile ARM: mvebu: fix GPIO config on the Linksys boards ARM: dts: kirkwood: Add the hardware monitor to the NSA320 device tree commit 9744426e6d7559671aafcbb36ee3b90dd66a6d2b Merge: 036f8d0 06e520c Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:16:48 2016 +0200 Merge tag 'samsung-dt-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/dt Merge "Samsung Device Tree updates and improvements for v4.7" from Krzysztof Kozlowski: 1. Enable accelerated AES (Security SubSystem) on Exynos4412-based boards. 2. Enable HDMI CEC on Exynos4412-based Odroid. 3. Add regulator supplies for eMMC/SD on Odroid XU3/XU4. 4. Fix DTC unit name warnings. 5. Merge topic branch of new Artik5 board. * tag 'samsung-dt-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: s5p: Fix DTC unit name warnings in SMDKv210 board ARM: dts: exynos: Fix DTC unit name warnings in Exynos5440 ARM: dts: exynos: Fix DTC unit name warnings in SMDK5420 ARM: dts: exynos: Fix DTC unit name warnings in Peach Pit ARM: dts: exynos: Fix DTC unit name warnings in Exynos542x ARM: dts: exynos: Fix DTC unit name warnings in Exynos5250 ARM: dts: exynos: Fix DTC unit name warnings in Exynos4x12 ARM: dts: exynos: Fix DTC unit name warnings in Trats2 board ARM: dts: exynos: Fix DTC unit name warnings in Exynos4 ARM: dts: exynos: Fix DTC unit name warnings in Exynos3250 ARM: dts: exynos: Fix DTC unit name warnings in cros-adc-thermistors ARM: dts: exynos: Add eMMC and SD regulator supplies to Odroid XU3/XU4 ARM: dts: exynos: Enable the HDMI CEC device on Exynos4412 Odroid boards ARM: dts: exynos: Add node for the HDMI CEC device to exynos4 ARM: dts: exynos: Add HDMI CEC pin definition to exynos4 pinctrl ARM: dts: exynos: Enable SSS on Odroid X/X2/U3 family ARM: dts: exynos: Enable SSS on Trats2 ARM: dts: exynos: Add Security SubSystem node to Exynos4 commit f6903783eba49a2cbb6798b35fcf9d2ce61768b9 Author: Axel Lin <axel.lin@ingics.com> Date: Thu Apr 14 09:08:55 2016 +0800 i2c: s3c2410: Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS instead of open-coded Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS to simplify the code. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-s3c2410.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit d4644becf86c710298a4af86f463c79375a21f21 Author: Axel Lin <axel.lin@ingics.com> Date: Thu Apr 14 09:08:04 2016 +0800 i2c: exynos5: Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS instead of open-coded Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS to simplify the code. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-exynos5.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit 036f8d06354014f1754dd59b9aa8b689a69cf1d3 Merge: 8bd641f e70c7ae Author: Arnd Bergmann <arnd@arndb.de> Date: Sun Apr 24 23:12:59 2016 +0200 Merge tag 'samsung-dt-exynos3250-artik5-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/dt Merge "Topic branch for Device Tree changes for Exynos 3250 for v4.7" from Krzysztof Kozlowski: Merge necessary new clocks from Sylwester (used by new board) and add support for Exynos3250-based Artik5 board. * tag 'samsung-dt-exynos3250-artik5-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux: ARM: dts: exynos: Add MSHC2 DT node for SD card for exynos3250-artik5-eval board ARM: dts: exynos: Add exynos3250-artik5 dtsi file for ARTIK5 module ARM: dts: exynos: Add MSHC2 DT node for Exynos3250 SoC ARM: dts: exynos: Add UART2 DT node for Exynos3250 SoC ARM: dts: exynos: Add initial gpio setting of MMC2 device for exynos3250-monk ARM: dts: exynos: Add initial pin configuration for exynos3250-rinato clk: samsung: exynos3250: Add MMC2 clock clk: samsung: exynos3250: Add UART2 clock dt-bindings: Add the clock id of UART2 and MMC2 for Exynos3250 commit 2c89e5d88473429eec62de12f5ae6642cf6a02a5 Author: Wolfram Sang <wsa@the-dreams.de> Date: Fri Apr 22 15:44:07 2016 +0200 i2c: mux: pinctrl: fix indentation for better readability smatch rightfully says: drivers/i2c/muxes/i2c-mux-pinctrl.c:175 i2c_mux_pinctrl_probe() warn: inconsistent indenting Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Acked-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-pinctrl.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 162718cb1a76f75d76e4b335034e341e8b656a5c Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Apr 18 00:44:03 2016 +0200 ARM: dts: rockchip: add MiQi board from mqmaker The MiQi is a rk3288-based devboard from Shenzen based mqmaker, with a footprint the size of a credit card. Main available outside connections are 4 usb ports, hdmi, gigabit ethernet and two expansion headers. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Documentation/devicetree/bindings/arm/rockchip.txt | 4 + arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/rk3288-miqi.dts | 472 +++++++++++++++++++++ 3 files changed, 477 insertions(+) commit 98b32a9b041bff987454db944eb4ece4d780be11 Author: Heiko Stuebner <heiko@sntech.de> Date: Sun Apr 17 08:44:47 2016 +0200 dt-bindings: add vendor-prefix for mqmaker Add vendor-prefix for Shenzen-based mqmaker Inc. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 126a66caec4a00b8d66dbc3174b0efa905cf68c3 Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Date: Mon Apr 4 16:55:23 2016 +0300 i2c: omap: drop the lock hard irq context The lock is taken while reading two registers. On RT the first lock is taken in hard irq where it might sleep and in the threaded irq. The threaded irq runs in oneshot mode so the hard irq does not run until the thread the completes so there is no reason to grab the lock. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> [grygorii.strashko@ti.com: drop locking from isr completely and remove lock field from struct omap_i2c_dev] Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-omap.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit afc34be05331962c2326c24bd0b47baff193b659 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 20:59:16 2016 +0200 i2c: dln2: Pass forward ACPI companion Share the ACPI companion for the platform device with the i2c adapter, so that the adapter has access to the properties defined in ACPI tables. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-dln2.c | 2 ++ 1 file changed, 2 insertions(+) commit 10d3be569243def8d92ac3722395ef5a59c504e6 Author: Eric Dumazet <edumazet@google.com> Date: Thu Apr 21 10:55:23 2016 -0700 tcp-tso: do not split TSO packets at retransmit time Linux TCP stack painfully segments all TSO/GSO packets before retransmits. This was fine back in the days when TSO/GSO were emerging, with their bugs, but we believe the dark age is over. Keeping big packets in write queues, but also in stack traversal has a lot of benefits. - Less memory overhead, because write queues have less skbs - Less cpu overhead at ACK processing. - Better SACK processing, as lot of studies mentioned how awful linux was at this ;) - Less cpu overhead to send the rtx packets (IP stack traversal, netfilter traversal, drivers...) - Better latencies in presence of losses. - Smaller spikes in fq like packet schedulers, as retransmits are not constrained by TCP Small Queues. 1 % packet losses are common today, and at 100Gbit speeds, this translates to ~80,000 losses per second. Losses are often correlated, and we see many retransmit events leading to 1-MSS train of packets, at the time hosts are already under stress. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Yuchung Cheng <ycheng@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 4 ++-- net/ipv4/tcp_input.c | 2 +- net/ipv4/tcp_output.c | 64 +++++++++++++++++++++++---------------------------- net/ipv4/tcp_timer.c | 4 ++-- 4 files changed, 34 insertions(+), 40 deletions(-) commit 8cee83dd29dea4e7d27fda3b170381059f628868 Author: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com> Date: Thu Apr 21 15:51:13 2016 +0200 tipc: fix stale links after re-enabling bearer Commit 42b18f605fea ("tipc: refactor function tipc_link_timeout()"), introduced a bug which prevents sending of probe messages during link synchronization phase. This leads to hanging links, if the bearer is disabled/enabled after links are up. In this commit, we send the probe messages correctly. Fixes: 42b18f605fea ("tipc: refactor function tipc_link_timeout()") Acked-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/link.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 6a74c1965ac8128da5feadccf739456c6586ad91 Merge: 11afbff 2de8023 Author: David S. Miller <davem@davemloft.net> Date: Sun Apr 24 14:06:56 2016 -0400 Merge branch 'tcp-tcstamp_ack-frag-coalesce' Martin KaFai Lau says: ==================== tcp: Handle txstamp_ack when fragmenting/coalescing skbs This patchset is to handle the txstamp-ack bit when fragmenting/coalescing skbs. The second patch depends on the recently posted series for the net branch: "tcp: Merge timestamp info when coalescing skbs" A BPF prog is used to kprobe to sock_queue_err_skb() and print out the value of serr->ee.ee_data. The BPF prog (run-able from bcc) is attached here: BPF prog used for testing: ~~~~~ from __future__ import print_function from bcc import BPF bpf_text = """ int trace_err_skb(struct pt_regs *ctx) { struct sk_buff *skb = (struct sk_buff *)ctx->si; struct sock *sk = (struct sock *)ctx->di; struct sock_exterr_skb *serr; u32 ee_data = 0; if (!sk || !skb) return 0; serr = SKB_EXT_ERR(skb); bpf_probe_read(&ee_data, sizeof(ee_data), &serr->ee.ee_data); bpf_trace_printk("ee_data:%u\\n", ee_data); return 0; }; """ b = BPF(text=bpf_text) b.attach_kprobe(event="sock_queue_err_skb", fn_name="trace_err_skb") print("Attached to kprobe") b.trace_print() ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 2de8023e7bb288e0bfbe0325a7690d32dc670873 Author: Martin KaFai Lau <kafai@fb.com> Date: Tue Apr 19 22:50:48 2016 -0700 tcp: Merge txstamp_ack in tcp_skb_collapse_tstamp When collapsing skbs, txstamp_ack also needs to be merged. Retrans Collapse Test: ~~~~~~ 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 0.200 write(4, ..., 730) = 730 +0 setsockopt(4, SOL_SOCKET, 37, [2688], 4) = 0 0.200 write(4, ..., 730) = 730 +0 setsockopt(4, SOL_SOCKET, 37, [2176], 4) = 0 0.200 write(4, ..., 11680) = 11680 0.200 > P. 1:731(730) ack 1 0.200 > P. 731:1461(730) ack 1 0.200 > . 1461:8761(7300) ack 1 0.200 > P. 8761:13141(4380) ack 1 0.300 < . 1:1(0) ack 1 win 257 <sack 1461:2921,nop,nop> 0.300 < . 1:1(0) ack 1 win 257 <sack 1461:4381,nop,nop> 0.300 < . 1:1(0) ack 1 win 257 <sack 1461:5841,nop,nop> 0.300 > P. 1:1461(1460) ack 1 0.400 < . 1:1(0) ack 13141 win 257 BPF Output Before: ~~~~~ <No output due to missing SCM_TSTAMP_ACK timestamp> BPF Output After: ~~~~~ <...>-2027 [007] d.s. 79.765921: : ee_data:1459 Sacks Collapse Test: ~~~~~ 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 0.200 write(4, ..., 1460) = 1460 +0 setsockopt(4, SOL_SOCKET, 37, [2688], 4) = 0 0.200 write(4, ..., 13140) = 13140 +0 setsockopt(4, SOL_SOCKET, 37, [2176], 4) = 0 0.200 > P. 1:1461(1460) ack 1 0.200 > . 1461:8761(7300) ack 1 0.200 > P. 8761:14601(5840) ack 1 0.300 < . 1:1(0) ack 1 win 257 <sack 1461:14601,nop,nop> 0.300 > P. 1:1461(1460) ack 1 0.400 < . 1:1(0) ack 14601 win 257 BPF Output Before: ~~~~~ <No output due to missing SCM_TSTAMP_ACK timestamp> BPF Output After: ~~~~~ <...>-2049 [007] d.s. 89.185538: : ee_data:14599 Signed-off-by: Martin KaFai Lau <kafai@fb.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Yuchung Cheng <ycheng@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Tested-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_output.c | 2 ++ 1 file changed, 2 insertions(+) commit b51e13faf73fcc799a41ed085069f07203d8e7b7 Author: Martin KaFai Lau <kafai@fb.com> Date: Tue Apr 19 22:50:47 2016 -0700 tcp: Carry txstamp_ack in tcp_fragment_tstamp When a tcp skb is sliced into two smaller skbs (e.g. in tcp_fragment() and tso_fragment()), it does not carry the txstamp_ack bit to the newly created skb if it is needed. The end result is a timestamping event (SCM_TSTAMP_ACK) will be missing from the sk->sk_error_queue. This patch carries this bit to the new skb2 in tcp_fragment_tstamp(). BPF Output Before: ~~~~~~ <No output due to missing SCM_TSTAMP_ACK timestamp> BPF Output After: ~~~~~~ <...>-2050 [000] d.s. 100.928763: : ee_data:14599 Packetdrill Script: ~~~~~~ +0 `sysctl -q -w net.ipv4.tcp_min_tso_segs=10` +0 `sysctl -q -w net.ipv4.tcp_no_metrics_save=1` +0 socket(..., SOCK_STREAM, IPPROTO_TCP) = 3 +0 setsockopt(3, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0 +0 bind(3, ..., ...) = 0 +0 listen(3, 1) = 0 0.100 < S 0:0(0) win 32792 <mss 1460,sackOK,nop,nop,nop,wscale 7> 0.100 > S. 0:0(0) ack 1 <mss 1460,nop,nop,sackOK,nop,wscale 7> 0.200 < . 1:1(0) ack 1 win 257 0.200 accept(3, ..., ...) = 4 +0 setsockopt(4, SOL_TCP, TCP_NODELAY, [1], 4) = 0 +0 setsockopt(4, SOL_SOCKET, 37, [2688], 4) = 0 0.200 write(4, ..., 14600) = 14600 +0 setsockopt(4, SOL_SOCKET, 37, [2176], 4) = 0 0.200 > . 1:7301(7300) ack 1 0.200 > P. 7301:14601(7300) ack 1 0.300 < . 1:1(0) ack 14601 win 257 0.300 close(4) = 0 0.300 > F. 14601:14601(0) ack 1 0.400 < F. 1:1(0) ack 16062 win 257 0.400 > . 14602:14602(0) ack 2 Signed-off-by: Martin KaFai Lau <kafai@fb.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Soheil Hassas Yeganeh <soheil@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Yuchung Cheng <ycheng@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Tested-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_output.c | 2 ++ 1 file changed, 2 insertions(+) commit 2030d684f7b36d739e850482d3b40c919c8919f1 Author: Akash Goel <akash.goel@intel.com> Date: Sat Apr 23 00:05:45 2016 +0530 drm/i915/bxt: Explicitly clear the Turbo control register As a part of WaGsvDisableTurbo, Driver makes an early exit from the Gen9 Turbo enabling function, so doesn't program the Turbo Control register. But BIOS could leave the Hw Turbo as enabled, so need to explicitly clear out the Control register just to avoid inconsitency with debugfs interface, which will show Turbo as enabled only and that is not expected after adding the WaGsvDisableTurbo. Apart from this there is no problem even if the Turbo is left enabled in the Control register, as the Up/Down interrupts would remain masked. v2: Add explicit clearing of Turbo Control register to *_disable_rps() also for the similar consistency (Chris) Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Akash Goel <akash.goel@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1461350146-23454-2-git-send-email-akash.goel@intel.com Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_pm.c | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) commit d6cda9c7f481b90cc644a764aa378a85cddf91ff Author: Akash Goel <akash.goel@intel.com> Date: Sat Apr 23 00:05:46 2016 +0530 drm/i915: Correct the i915_frequency_info debugfs output There are certain registers, which captures the time elapsed in the in current Up/Down EI, for how long GT has been Idle/Busy/Avg in the current Up/Down EI and also in the previous Up/Down EI. These register values are reported by the i915_frequency_info debugfs interface. The Driver prints the 'us' suffix after the values, albeit they are actually in raw form & not in microsecond units. This patch removes the 'us' suffix so that its clear to User that values are indeed in raw form. v2: Present the values in microseconds unit also, after platform specific conversion (Chris) v3: Add a space between raw & microsecond value (Chris) Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Akash Goel <akash.goel@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1461350146-23454-3-git-send-email-akash.goel@intel.com Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) commit 52530cbadcdf786d7eb58365034b01810f52db1f Author: Akash Goel <akash.goel@intel.com> Date: Sat Apr 23 00:05:44 2016 +0530 drm/i915: Macros to convert PM time interval values to microseconds Added a new GT_PM_INTERVAL_TO_US macro to perform the platform specific conversion of PM time interval values to microseconds unit. Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Akash Goel <akash.goel@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1461350146-23454-1-git-send-email-akash.goel@intel.com Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_reg.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit 06ad7ea10e2bcf70a602e504ea32ee6ef6d77aa9 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 18 17:31:57 2016 +0300 max44000: Initial triggered buffer support Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/max44000.c | 62 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) commit d5d8f49b634520a98337fd413eef86da4e63e4fd Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 18 17:31:56 2016 +0300 max44000: Expose ambient sensor scaling This patch exposes ALSTIM as illuminance_integration_time and ALSPGA as illuminance_scale. Changing ALSTIM also changes the number of bits available in the data register. This is handled inside raw value reading because: * It's very easy to shift a few bits * It allows SCALE and INT_TIME to be completely independent controls * Buffer support requires constant scan_type.realbits per-channel Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/max44000.c | 167 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 162 insertions(+), 5 deletions(-) commit 237a378b3bde0b3c1d1c47f7a3982c86a6728cdf Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 18 17:31:55 2016 +0300 max44000: Support controlling LED current output This is exposed as an output channel with "led" as an extend_name. Other sensors also have support for controlling an external LED. It's not clear that simply exposing an undecorated output channel is the correct approach. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/max44000.c | 53 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) commit 35b651f391909c80d705533d3e0f7228d42b98a0 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 18 17:31:54 2016 +0300 max44000: Initial support for proximity reading The proximity sensor relies on sending pulses to an external IR led and it is disabled by default on powerup. The driver will enable it with a default power setting. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/max44000.c | 51 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 47 insertions(+), 4 deletions(-) commit b9567e6664643eb99367fb88d14fdba863b1688a Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 18 17:31:53 2016 +0300 max44000: Initial support This just adds support for reporting illuminance with default settings. Important default registers are written on probe because the device otherwise lacks a reset function. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/Kconfig | 11 ++ drivers/iio/light/Makefile | 1 + drivers/iio/light/max44000.c | 324 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 336 insertions(+) commit 0d96d5ead3f7f1303a6a445051f29bba7c7f4e47 Author: Tiberiu Breana <tiberiu.a.breana@intel.com> Date: Mon Apr 18 17:50:44 2016 +0300 iio: humidity: Add triggered buffer support for AM2315 Signed-off-by: Tiberiu Breana <tiberiu.a.breana@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/am2315.c | 81 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 78 insertions(+), 3 deletions(-) commit 366a3270c1c5ce0a12d1451e2e2e6341385c331d Author: Tiberiu Breana <tiberiu.a.breana@intel.com> Date: Mon Apr 18 17:50:43 2016 +0300 iio: humidity: Add support for AM2315 Add basic support for the Aosong AM2315 relative humidity and ambient temperature sensor. Includes support for raw readings and ACPI detection. Datasheet: http://www.aosong.com/asp_bin/Products/en/AM2315.pdf Signed-off-by: Tiberiu Breana <tiberiu.a.breana@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/Kconfig | 10 ++ drivers/iio/humidity/Makefile | 1 + drivers/iio/humidity/am2315.c | 228 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 239 insertions(+) commit d8469e93a4af82110b15b28bbb003a1dbe4258d2 Author: Marek Vasut <marex@denx.de> Date: Mon Apr 18 16:05:24 2016 +0200 iio: pressure: hp03: Add Hope RF HP03 sensor support Add support for HopeRF pressure and temperature sensor. This device uses two fixed I2C addresses, one for storing calibration coefficients and another for accessing the ADC. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Matt Ranostay <mranostay@gmail.com> Cc: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/pressure/hp03.txt | 17 ++ drivers/iio/pressure/Kconfig | 11 + drivers/iio/pressure/Makefile | 1 + drivers/iio/pressure/hp03.c | 312 +++++++++++++++++++++ 4 files changed, 341 insertions(+) commit ee0876bc69ee8d24d524fb2e9e41e3682aaebb11 Author: Jan Kara <jack@suse.cz> Date: Sun Apr 24 00:56:08 2016 -0400 ext4: do not ask jbd2 to write data for delalloc buffers Currently we ask jbd2 to write all dirty allocated buffers before committing a transaction when doing writeback of delay allocated blocks. However this is unnecessary since we move all pages to writeback state before dropping a transaction handle and then submit all the necessary IO. We still need the transaction commit to wait for all the outstanding writeback before flushing disk caches during transaction commit to avoid data exposure issues though. Use the new jbd2 capability and ask it to only wait for outstanding writeback during transaction commit when writing back data in ext4_writepages(). Tested-by: "HUANG Weller (CM/ESW12-CN)" <Weller.Huang@cn.bosch.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ext4.h | 3 +++ fs/ext4/ext4_jbd2.h | 12 +++++++++++- fs/ext4/inode.c | 10 +++++++--- fs/ext4/move_extent.c | 2 +- 4 files changed, 22 insertions(+), 5 deletions(-) commit 41617e1a8dec9fe082ba5dec26bacb154eb55482 Author: Jan Kara <jack@suse.cz> Date: Sun Apr 24 00:56:07 2016 -0400 jbd2: add support for avoiding data writes during transaction commits Currently when filesystem needs to make sure data is on permanent storage before committing a transaction it adds inode to transaction's inode list. During transaction commit, jbd2 writes back all dirty buffers that have allocated underlying blocks and waits for the IO to finish. However when doing writeback for delayed allocated data, we allocate blocks and immediately submit the data. Thus asking jbd2 to write dirty pages just unnecessarily adds more work to jbd2 possibly writing back other redirtied blocks. Add support to jbd2 to allow filesystem to ask jbd2 to only wait for outstanding data writes before committing a transaction and thus avoid unnecessary writes. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ext4_jbd2.h | 3 ++- fs/jbd2/commit.c | 4 ++++ fs/jbd2/journal.c | 3 ++- fs/jbd2/transaction.c | 22 ++++++++++++++++++---- fs/ocfs2/journal.h | 2 +- include/linux/jbd2.h | 13 +++++++++++-- 6 files changed, 38 insertions(+), 9 deletions(-) commit 3957ef53a5033bd519b19cf375061be1929bdb5f Author: Jan Kara <jack@suse.cz> Date: Sun Apr 24 00:56:05 2016 -0400 ext4: remove EXT4_STATE_ORDERED_MODE This flag is just duplicating what ext4_should_order_data() tells you and is used in a single place. Furthermore it doesn't reflect changes to inode data journalling flag so it may be possibly misleading. Just remove it. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/ext4.h | 1 - fs/ext4/inode.c | 5 +---- 2 files changed, 1 insertion(+), 5 deletions(-) commit 06bd3c36a733ac27962fea7d6f47168841376824 Author: Jan Kara <jack@suse.cz> Date: Sun Apr 24 00:56:03 2016 -0400 ext4: fix data exposure after a crash Huang has reported that in his powerfail testing he is seeing stale block contents in some of recently allocated blocks although he mounts ext4 in data=ordered mode. After some investigation I have found out that indeed when delayed allocation is used, we don't add inode to transaction's list of inodes needing flushing before commit. Originally we were doing that but commit f3b59291a69d removed the logic with a flawed argument that it is not needed. The problem is that although for delayed allocated blocks we write their contents immediately after allocating them, there is no guarantee that the IO scheduler or device doesn't reorder things and thus transaction allocating blocks and attaching them to inode can reach stable storage before actual block contents. Actually whenever we attach freshly allocated blocks to inode using a written extent, we should add inode to transaction's ordered inode list to make sure we properly wait for block contents to be written before committing the transaction. So that is what we do in this patch. This also handles other cases where stale data exposure was possible - like filling hole via mmap in data=ordered,nodelalloc mode. The only exception to the above rule are extending direct IO writes where blkdev_direct_IO() waits for IO to complete before increasing i_size and thus stale data exposure is not possible. For now we don't complicate the code with optimizing this special case since the overhead is pretty low. In case this is observed to be a performance problem we can always handle it using a special flag to ext4_map_blocks(). CC: stable@vger.kernel.org Fixes: f3b59291a69d0b734be1fc8be489fef2dd846d3d Reported-by: "HUANG Weller (CM/ESW12-CN)" <Weller.Huang@cn.bosch.com> Tested-by: "HUANG Weller (CM/ESW12-CN)" <Weller.Huang@cn.bosch.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/ext4/inode.c | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) commit 11afbff86168bc2ce11ae9d64ff687567a2352de Merge: 8d9ea16 a163f2cb Author: David S. Miller <davem@davemloft.net> Date: Sun Apr 24 00:12:08 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next Pablo Neira Ayuso says: ==================== Netfilter updates for net-next The following patchset contains Netfilter updates for your net-next tree, mostly from Florian Westphal to sort out the lack of sufficient validation in x_tables and connlabel preparation patches to add nf_tables support. They are: 1) Ensure we don't go over the ruleset blob boundaries in mark_source_chains(). 2) Validate that target jumps land on an existing xt_entry. This extra sanitization comes with a performance penalty when loading the ruleset. 3) Introduce xt_check_entry_offsets() and use it from {arp,ip,ip6}tables. 4) Get rid of the smallish check_entry() functions in {arp,ip,ip6}tables. 5) Make sure the minimal possible target size in x_tables. 6) Similar to #3, add xt_compat_check_entry_offsets() for compat code. 7) Check that standard target size is valid. 8) More sanitization to ensure that the target_offset field is correct. 9) Add xt_check_entry_match() to validate that matches are well-formed. 10-12) Three patch to reduce the number of parameters in translate_compat_table() for {arp,ip,ip6}tables by using a container structure. 13) No need to return value from xt_compat_match_from_user(), so make it void. 14) Consolidate translate_table() so it can be used by compat code too. 15) Remove obsolete check for compat code, so we keep consistent with what was already removed in the native layout code (back in 2007). 16) Get rid of target jump validation from mark_source_chains(), obsoleted by #2. 17) Introduce xt_copy_counters_from_user() to consolidate counter copying, and use it from {arp,ip,ip6}tables. 18,22) Get rid of unnecessary explicit inlining in ctnetlink for dump functions. 19) Move nf_connlabel_match() to xt_connlabel. 20) Skip event notification if connlabel did not change. 21) Update of nf_connlabels_get() to make the upcoming nft connlabel support easier. 23) Remove spinlock to read protocol state field in conntrack. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 1f60fbe7274918adb8db2f616e321890730ab7e3 Author: Theodore Ts'o <tytso@mit.edu> Date: Sat Apr 23 22:50:07 2016 -0400 ext4: allow readdir()'s of large empty directories to be interrupted If a directory has a large number of empty blocks, iterating over all of them can take a long time, leading to scheduler warnings and users getting irritated when they can't kill a process in the middle of one of these long-running readdir operations. Fix this by adding checks to ext4_readdir() and ext4_htree_fill_tree(). This was reverted earlier due to a typo in the original commit where I experimented with using signal_pending() instead of fatal_signal_pending(). The test was in the wrong place if we were going to return signal_pending() since we would end up returning duplicant entries. See 9f2394c9be47 for a more detailed explanation. Added fix as suggested by Linus to check for signal_pending() in in the filldir() functions. Reported-by: Benjamin LaHaise <bcrl@kvack.org> Google-Bug-Id: 27880676 Signed-off-by: Theodore Ts'o <tytso@mit.edu> fs/compat.c | 4 ++++ fs/ext4/dir.c | 5 +++++ fs/ext4/namei.c | 5 +++++ fs/readdir.c | 4 ++++ 4 files changed, 18 insertions(+) commit 8d9ea1606f6c3a1046abae5c2c85eb0e02e43db3 Merge: 1602f49 80df554 Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 23 20:13:29 2016 -0400 Merge branch 'nla_align-more' Nicolas Dichtel says: ==================== netlink: align attributes when needed (patchset #1) This is the continuation of the work done to align netlink attributes when these attributes contain some 64-bit fields. David, if the third patch is too big (or maybe the series), I can split it. Just tell me what you prefer. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 80df554275c21edca22ece02448bdb378c2ee9f1 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:24 2016 +0200 taskstats: use the libnl API to align nlattr on 64-bit Goal of this patch is to use the new libnl API to align netlink attribute when needed. The layout of the netlink message will be a bit different after the patch, because the padattr (TASKSTATS_TYPE_STATS) will be inside the nested attribute instead of before it. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/taskstats.c | 37 +++++-------------------------------- 1 file changed, 5 insertions(+), 32 deletions(-) commit de95c4a46a6e608444ccaf541087594553c7df11 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:23 2016 +0200 xfrm: align nlattr properly when needed Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/xfrm.h | 1 + net/xfrm/xfrm_user.c | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) commit 73520786b0793c612ef4de3e9addb2ec411bea20 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:22 2016 +0200 libnl: add nla_put_u64_64bit() helper With this function, nla_data() is aligned on a 64-bit area. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 2175d87cc3561c02e605bc8ac81ee5d875a51b9e Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:21 2016 +0200 libnl: nla_put_msecs(): align on a 64-bit area nla_data() is now aligned on a 64-bit area. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 11 +++++++---- include/uapi/linux/l2tp.h | 1 + include/uapi/linux/neighbour.h | 2 ++ include/uapi/linux/tcp_metrics.h | 1 + net/core/neighbour.c | 19 ++++++++++--------- net/ipv4/tcp_metrics.c | 6 ++++-- net/l2tp/l2tp_netlink.c | 3 ++- 7 files changed, 27 insertions(+), 16 deletions(-) commit 756a2f59b73cd6ed8afae3f6e8efb3fb829e4600 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:20 2016 +0200 libnl: nla_put_s64(): align on a 64-bit area nla_data() is now aligned on a 64-bit area. In fact, there is no user of this function. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit e9bbe898cbe89b17ad3993c136aa13d0431cd537 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:19 2016 +0200 libnl: nla_put_net64(): align on a 64-bit area nla_data() is now aligned on a 64-bit area. The temporary function nla_put_be64_32bit() is removed in this patch. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netfilter/ipset/ip_set.h | 9 ++++++--- include/net/netlink.h | 14 ++++++-------- include/uapi/linux/netfilter/ipset/ip_set.h | 1 + 3 files changed, 13 insertions(+), 11 deletions(-) commit b46f6ded906ef0be52a4881ba50a084aeca64d7e Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:18 2016 +0200 libnl: nla_put_be64(): align on a 64-bit area nla_data() is now aligned on a 64-bit area. A temporary version (nla_put_be64_32bit()) is added for nla_put_net64(). This function is removed in the next patch. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 15 ++++++++++---- include/uapi/linux/fib_rules.h | 1 + include/uapi/linux/lwtunnel.h | 2 ++ include/uapi/linux/netfilter/nf_tables.h | 8 ++++++++ include/uapi/linux/netfilter/nfnetlink_acct.h | 1 + include/uapi/linux/netfilter/nfnetlink_conntrack.h | 3 +++ include/uapi/linux/openvswitch.h | 1 + net/core/fib_rules.c | 4 ++-- net/ipv4/ip_tunnel_core.c | 10 +++++---- net/netfilter/nf_conntrack_netlink.c | 18 +++++++++------- net/netfilter/nf_conntrack_proto_dccp.c | 4 +++- net/netfilter/nf_tables_api.c | 24 ++++++++++++++-------- net/netfilter/nf_tables_trace.c | 5 +++-- net/netfilter/nfnetlink_acct.c | 9 +++++--- net/netfilter/nft_counter.c | 6 ++++-- net/netfilter/nft_dynset.c | 3 ++- net/netfilter/nft_limit.c | 6 ++++-- net/openvswitch/flow_netlink.c | 5 +++-- 18 files changed, 87 insertions(+), 38 deletions(-) commit e7479122befd7026cf0fb3b3740f17ebd9c64d35 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:17 2016 +0200 libnl: nla_put_le64(): align on a 64-bit area nla_data() is now aligned on a 64-bit area. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 8 +++++--- include/net/nl802154.h | 6 ++++++ net/ieee802154/nl802154.c | 13 ++++++++----- 3 files changed, 19 insertions(+), 8 deletions(-) commit 11a99573079e15f11499ae8d21b07e3e3257fff1 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Fri Apr 22 17:31:16 2016 +0200 libnl: fix help of _64bit functions Fix typo and describe 'padattr'. Fixes: 089bf1a6a924 ("libnl: add more helpers to align attributes on 64-bit") Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> lib/nlattr.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 077d67374e81c39f3f7b6b57119325f770b810b9 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Apr 22 17:52:45 2016 +0300 drm: rcar-du: Fix compilation warning Commit d63c25e4245a ("drm: rcar-du: Use generic drm_connector_register_all() helper") left an unused local variable behind. Remove it. Fixes: d63c25e4245a ("drm: rcar-du: Use generic drm_connector_register_all() helper") Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> drivers/gpu/drm/rcar-du/rcar_du_drv.c | 1 - 1 file changed, 1 deletion(-) commit a033e6b61d2984a9ab31c607f5b5796cfff049e5 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 25 10:38:28 2016 +0900 drm: rcar-du: Use ARCH_RENESAS Make use of ARCH_RENESAS in place of ARCH_SHMOBILE. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> drivers/gpu/drm/rcar-du/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4f5504cfc6ffcc73926de454f000d0409eed2fcb Author: Arnd Bergmann <arnd@arndb.de> Date: Fri Feb 26 12:52:20 2016 +0100 drm: rcar-du: Clarify vsp dependency The VSP1 compositor code in DRM links against the respective V4L driver, but the dependency is not expressed correctly in Kconfig, which leads to a build error when the DRM driver is built-in and the V4L driver is a module: drivers/gpu/built-in.o: In function `rcar_du_vsp_plane_atomic_update': rcar-du/rcar_du_vsp.c:183: undefined reference to `vsp1_du_atomic_update' This patch avoids the problem by ensuring that the DRM VSP code can only be enabled if the V4L driver is linked into the kernel, or both are loadable modules. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 6d62ef3ac30b ("drm: rcar-du: Expose the VSP1 compositor through KMS planes") Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> drivers/gpu/drm/rcar-du/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1602f49b58abcb0d34a5f0a29d68e7c1769547aa Merge: 22d37b6 5f44abd Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 23 18:26:24 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net Conflicts were two cases of simple overlapping changes, nothing serious. In the UDP case, we need to add a hlist_add_tail_rcu() to linux/rculist.h, because we've moved UDP socket handling away from using nulls lists. Signed-off-by: David S. Miller <davem@davemloft.net> commit 41c128cb25cee72be66397fae8ceb8dc0c2c6984 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Tue Apr 19 15:02:11 2016 +0300 iio: st_gyro: Add lsm9ds0-gyro support This device has an identical interface to other supported sensors and the patch only adds IDs. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/devicetree/bindings/iio/st-sensors.txt | 1 + drivers/iio/gyro/Kconfig | 2 +- drivers/iio/gyro/st_gyro.h | 1 + drivers/iio/gyro/st_gyro_core.c | 1 + drivers/iio/gyro/st_gyro_i2c.c | 5 +++++ drivers/iio/gyro/st_gyro_spi.c | 1 + 6 files changed, 10 insertions(+), 1 deletion(-) commit f21122593d99c7e051891da1b148c771b7d56e07 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 13:04:14 2016 +0300 iio: light: apds9960: silence uninitialized variable warning It causes a static checker warning if we use "buf" on the failure path so move that inside the if statement. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/apds9960.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit eb3798463f71afc77abd25b2f62708be06f7173b Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Wed Apr 20 19:23:45 2016 +0200 iio:imu:mpu6050: enhance mounting matrix support Add a new rotation matrix sysfs attribute compliant with IIO core mounting matrix API. Matrix is retrieved from "in_anglvel_mount_matrix" and "in_accel_mount_matrix" sysfs attributes. It is declared into mpu6050 DTS entry as a "mount-matrix" property. Old interface is kept for backward userspace compatibility and may be retrieved from legacy platform_data mechanism only. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio | 2 ++ .../devicetree/bindings/iio/imu/inv_mpu6050.txt | 13 ++++++++ drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 36 ++++++++++++++++++++-- drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h | 4 ++- include/linux/platform_data/invensense_mpu6050.h | 5 ++- 5 files changed, 55 insertions(+), 5 deletions(-) commit 97eacb9166f4810368e180073dcbceeff0de34df Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Wed Apr 20 19:23:44 2016 +0200 iio:ak8975: add mounting matrix support Expose a rotation matrix to indicate userspace the chip orientation with respect to the overall hardware system. Matrix is retrieved from "in_mount_matrix". It is declared into ak8975 DTS entry as a "mount-matrix" property. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../bindings/iio/magnetometer/ak8975.txt | 10 +++++++ drivers/iio/magnetometer/ak8975.c | 34 +++++++++++++++++++--- include/linux/iio/magnetometer/ak8975.h | 16 ++++++++++ 3 files changed, 56 insertions(+), 4 deletions(-) commit dfc57732ad38f93ae6232a3b4e64fd077383a0f1 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Wed Apr 20 19:23:43 2016 +0200 iio:core: mounting matrix support Expose a rotation matrix to indicate userspace the chip placement with respect to the overall hardware system. This is needed to adjust coordinates sampled from a sensor chip when its position deviates from the main hardware system. Final coordinates computation is delegated to userspace since: * computation may involve floating point arithmetics ; * it allows an application to combine adjustments with arbitrary transformations. This 3 dimentional space rotation matrix is expressed as 3x3 array of strings to support floating point numbers. It may be retrieved from a "[<dir>_][<type>_]mount_matrix" sysfs attribute file. It is declared into a device / driver specific DTS property or platform data. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio | 51 ++++++++++++++++++++ drivers/iio/industrialio-core.c | 82 +++++++++++++++++++++++++++++++++ include/linux/iio/iio.h | 31 +++++++++++++ 3 files changed, 164 insertions(+) commit b971e94e8f4c09ff775cfb2c4f846b4431a00598 Author: Yan, Zheng <zyan@redhat.com> Date: Thu Apr 14 00:30:18 2016 +0200 ceph: kill __ceph_removexattr() when removing a xattr, generic_removexattr() calls __ceph_setxattr() with NULL value and XATTR_REPLACE flag. __ceph_removexattr() is not used any more. Signed-off-by: "Yan, Zheng" <zyan@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ceph/xattr.c | 126 -------------------------------------------------------- 1 file changed, 126 deletions(-) commit 2cdeb1e472cf03dec4dc614623fd2e6bd8e5f271 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Apr 14 00:30:17 2016 +0200 ceph: Switch to generic xattr handlers Add a catch-all xattr handler at the end of ceph_xattr_handlers. Check for valid attribute names there, and remove those checks from __ceph_{get,set,remove}xattr instead. No "system.*" xattrs need to be handled by the catch-all handler anymore. The set xattr handler is called with a NULL value to indicate that the attribute should be removed; __ceph_setxattr already handles that case correctly (ceph_set_acl could already calling __ceph_setxattr with a NULL value). Move the check for snapshots from ceph_{set,remove}xattr into __ceph_{set,remove}xattr. With that, ceph_{get,set,remove}xattr can be replaced with the generic iops. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: "Yan, Zheng" <zyan@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ceph/dir.c | 7 +++--- fs/ceph/inode.c | 13 ++++++------ fs/ceph/super.h | 4 ---- fs/ceph/xattr.c | 66 +++++++++++++++++++++++---------------------------------- 4 files changed, 38 insertions(+), 52 deletions(-) commit a26feccaba296bd0ae410eabce79cb3443c8a701 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Apr 14 00:30:16 2016 +0200 ceph: Get rid of d_find_alias in ceph_set_acl Create a variant of ceph_setattr that takes an inode instead of a dentry. Change __ceph_setxattr (and also __ceph_removexattr) to take an inode instead of a dentry. Use those in ceph_set_acl so that we no longer need a dentry there. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: "Yan, Zheng" <zyan@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ceph/acl.c | 14 +++++--------- fs/ceph/inode.c | 16 ++++++++++------ fs/ceph/super.h | 4 ++-- fs/ceph/xattr.c | 28 ++++++++++++---------------- 4 files changed, 29 insertions(+), 33 deletions(-) commit a9ae008f407b50fc92ef19588d2ea2be13a7f5e2 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Fri Apr 22 12:11:38 2016 +0200 cifs: Switch to generic xattr handlers Use xattr handlers for resolving attribute names. The amount of setup code required on cifs is nontrivial, so use the same get and set functions for all handlers, with switch statements for the different types of attributes in them. The set_EA handler can handle NULL values, so we don't need a separate removexattr function anymore. Remove the cifs_dbg statements related to xattr name resolution; they don't add much. Don't build xattr.o when CONFIG_CIFS_XATTR is not defined. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/Makefile | 3 +- fs/cifs/cifsfs.c | 26 ++--- fs/cifs/cifsfs.h | 12 +- fs/cifs/xattr.c | 342 +++++++++++++++++++++++-------------------------------- 4 files changed, 165 insertions(+), 218 deletions(-) commit 534bb0c7bdaf7377e84e82f0eb4a9992eaa87fbb Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Apr 14 00:30:15 2016 +0200 cifs: Fix removexattr for os2.* xattrs If cifs_removexattr finds a "user." or "os2." xattr name prefix, it skips 5 bytes, one byte too many for "os2.". Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/xattr.c | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) commit 45987e006c49728611e41d1fc04ff7cc803959f5 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Apr 14 00:30:14 2016 +0200 cifs: Check for equality with ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT The two values ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT are meant to be enumerations, not bits in a bit mask. Use '==' instead of '&' to check for these values. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifssmb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d9a15489210f3c25de39dee85861352d5e79e9c5 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Apr 14 00:30:13 2016 +0200 cifs: Fix xattr name checks Use strcmp(str, name) instead of strncmp(str, name, strlen(name)) for checking if str and name are the same (as opposed to name being a prefix of str) in the gexattr and setxattr inode operations. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/xattr.c | 24 ++++++++---------------- 1 file changed, 8 insertions(+), 16 deletions(-) commit c5fb04cc96c1812eb09a3b0f3672f4a00d76730c Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Apr 11 12:01:34 2016 -0500 ARM: socfpga: Initialize Arria10 OCRAM ECC on startup Initialize ECC for Arria10 On-Chip RAM on machine startup. The OCRAM memory must be initialized before data is stored in memory otherwise the ECC will fail on reads. The previous check-in 2364d423a7b3 ("ARM: socfpga: Enable Arria10 OCRAM ECC on startup") added the OCRAM enable and initialization code but was not called on startup. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Acked-by: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1460394094-23326-1-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> arch/arm/mach-socfpga/core.h | 1 + arch/arm/mach-socfpga/socfpga.c | 2 ++ 2 files changed, 3 insertions(+) commit 993f88f1cc7f0879047ff353e824e5cc8f10adfc Author: Emmanouil Maroudas <emmanouil.maroudas@gmail.com> Date: Sat Apr 23 18:33:00 2016 +0300 EDAC: Increment correct counter in edac_inc_ue_error() Fix typo in edac_inc_ue_error() to increment ue_noinfo_count instead of ce_noinfo_count. Signed-off-by: Emmanouil Maroudas <emmanouil.maroudas@gmail.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Fixes: 4275be635597 ("edac: Change internal representation to work with layers") Link: http://lkml.kernel.org/r/1461425580-5898-1-git-send-email-emmanouil.maroudas@gmail.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/edac_mc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 67d61296ffcc850bffdd4466430cb91e5328f39a Merge: 31b8431 6566fea Author: Ingo Molnar <mingo@kernel.org> Date: Tue Apr 19 20:58:22 2016 +0200 Merge tag 'perf-core-for-mingo-20160419' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: Build fixes: - Fix 'perf trace' build when DWARF unwind isn't available (Arnaldo Carvalho de Melo) - Remove x86 references from arch-neutral Build, fixing it in !x86 arches, reported as breaking the build for powerpc64le in linux-next (Arnaldo Carvalho de Melo) Infrastructure changes: - Do memset() variable 'st' using the correct size in the jit code (Colin Ian King) - Fix postgresql ubuntu 'perf script' install instructions (Chris Phlipot) - Use callchain_param more thoroughly when checking how callchains were configured, eventually will be the only way to look for callchain parameters (Arnaldo Carvalho de Melo) - Fix some issues in the 'perf test kallsyms' entry (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit fec148c000d0f9ac21679601722811eb60b4cc52 Author: Xunlei Pang <xlpang@redhat.com> Date: Thu Apr 14 20:19:28 2016 +0800 sched/deadline: Fix a bug in dl_overflow() I got a minus(very big) dl_b->total_bw during my deadline tests. # grep dl /proc/sched_debug dl_rq[0]: .dl_nr_running : 0 .dl_bw->bw : 996147 .dl_bw->total_bw : -222297900 Something unusual must have happened. After some digging, I finally noticed that when changing a deadline task to normal(cfs), and changing it back to deadline immediately, after it died, we will got the wrong dl_bw->total_bw. The root cause is in dl_overflow(), it has: if (new_bw == p->dl.dl_bw) return 0; 1) When a deadline task is changed to !deadline task, it will start dl timer in switched_from_dl(), and retain previous deadline parameter till the timer expires. 2) If we change it back to deadline with the same bandwidth parameter before the timer expires, as it keeps the old bandwidth although it is not a deadline task. dl_overflow() simply returns success without updating the right data, and got the wrong dl_bw->total_bw. The solution is simple, if @p is not deadline, don't return. Signed-off-by: Xunlei Pang <xlpang@redhat.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Juri Lelli <juri.lelli@arm.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460636368-1993-1-git-send-email-xlpang@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9fd81dd5ce0b12341c9f83346f8d32ac68bd3841 Author: Frederic Weisbecker <fweisbec@gmail.com> Date: Tue Apr 19 17:36:51 2016 +0200 sched/fair: Optimize !CONFIG_NO_HZ_COMMON CPU load updates Some code in CPU load update only concern NO_HZ configs but it is built on all configurations. When NO_HZ isn't built, that code is harmless but just happens to take some useless ressources in CPU and memory: 1) one useless field in struct rq 2) jiffies record on every tick that is never used (cpu_load_update_periodic) 3) decay_load_missed is called two times on every tick to eventually return immediately with no action taken. And that function is dead code. For pure optimization purposes, lets conditionally build the NO_HZ related code. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Byungchul Park <byungchul.park@lge.com> Cc: Chris Metcalf <cmetcalf@ezchip.com> Cc: Christoph Lameter <cl@linux.com> Cc: Luiz Capitulino <lcapitulino@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul E . McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461080211-16271-1-git-send-email-fweisbec@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 5 ++--- kernel/sched/fair.c | 9 +++++++-- kernel/sched/sched.h | 6 ++++-- 3 files changed, 13 insertions(+), 7 deletions(-) commit 1f41906a6fda1114debd3898668bd7ab6470ee41 Author: Frederic Weisbecker <fweisbec@gmail.com> Date: Wed Apr 13 15:56:51 2016 +0200 sched/fair: Correctly handle nohz ticks CPU load accounting Ticks can happen while the CPU is in dynticks-idle or dynticks-singletask mode. In fact "nohz" or "dynticks" only mean that we exit the periodic mode and we try to minimize the ticks as much as possible. The nohz subsystem uses a confusing terminology with the internal state "ts->tick_stopped" which is also available through its public interface with tick_nohz_tick_stopped(). This is a misnomer as the tick is instead reduced with the best effort rather than stopped. In the best case the tick can indeed be actually stopped but there is no guarantee about that. If a timer needs to fire one second later, a tick will fire while the CPU is in nohz mode and this is a very common scenario. Now this confusion happens to be a problem with CPU load updates: cpu_load_update_active() doesn't handle nohz ticks correctly because it assumes that ticks are completely stopped in nohz mode and that cpu_load_update_active() can't be called in dynticks mode. When that happens, the whole previous tickless load is ignored and the function just records the load for the current tick, ignoring potentially long idle periods behind. In order to solve this, we could account the current load for the previous nohz time but there is a risk that we account the load of a task that got freshly enqueued for the whole nohz period. So instead, lets record the dynticks load on nohz frame entry so we know what to record in case of nohz ticks, then use this record to account the tickless load on nohz ticks and nohz frame end. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Byungchul Park <byungchul.park@lge.com> Cc: Chris Metcalf <cmetcalf@ezchip.com> Cc: Christoph Lameter <cl@linux.com> Cc: Luiz Capitulino <lcapitulino@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul E . McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460555812-25375-3-git-send-email-fweisbec@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 6 ++- kernel/sched/fair.c | 97 +++++++++++++++++++++++++++++++----------------- kernel/time/tick-sched.c | 9 +++-- 3 files changed, 72 insertions(+), 40 deletions(-) commit cee1afce3053e7aa0793fbd5f2e845fa2cef9e33 Author: Frederic Weisbecker <fweisbec@gmail.com> Date: Wed Apr 13 15:56:50 2016 +0200 sched/fair: Gather CPU load functions under a more conventional namespace The CPU load update related functions have a weak naming convention currently, starting with update_cpu_load_*() which isn't ideal as "update" is a very generic concept. Since two of these functions are public already (and a third is to come) that's enough to introduce a more conventional naming scheme. So let's do the following rename instead: update_cpu_load_*() -> cpu_load_update_*() Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Byungchul Park <byungchul.park@lge.com> Cc: Chris Metcalf <cmetcalf@ezchip.com> Cc: Christoph Lameter <cl@linux.com> Cc: Luiz Capitulino <lcapitulino@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul E . McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460555812-25375-2-git-send-email-fweisbec@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/trace/ftrace.txt | 10 +++++----- include/linux/sched.h | 4 ++-- kernel/sched/core.c | 2 +- kernel/sched/fair.c | 24 ++++++++++++------------ kernel/sched/sched.h | 4 ++-- kernel/time/tick-sched.c | 2 +- 6 files changed, 23 insertions(+), 23 deletions(-) commit a2c6c91f98247fef0fe75216d607812485aeb0df Author: Steve Muckle <steve.muckle@linaro.org> Date: Thu Mar 24 15:26:07 2016 -0700 sched/fair: Call cpufreq hook in additional paths The cpufreq hook should be called any time the root CFS rq utilization changes. This can occur when a task is switched to or from the fair class, or a task moves between groups or CPUs, but these paths currently do not call the cpufreq hook. Fix this by adding the hook to attach_entity_load_avg() and detach_entity_load_avg(). Suggested-by: Vincent Guittot <vincent.guittot@linaro.org> Signed-off-by: Steve Muckle <smuckle@linaro.org> [ Added the .update_freq argument to update_cfs_rq_load_avg() to avoid a double cpufreq call. ] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Byungchul Park <byungchul.park@lge.com> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com> Cc: Juri Lelli <Juri.Lelli@arm.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Patrick Bellasi <patrick.bellasi@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rafael J. Wysocki <rafael@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1458858367-2831-1-git-send-email-smuckle@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 73 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 42 insertions(+), 31 deletions(-) commit 41e0d37f7ac81297c07ba311e4ad39465b8c8295 Author: Steve Muckle <steve.muckle@linaro.org> Date: Mon Mar 21 17:21:08 2016 -0700 sched/fair: Do not call cpufreq hook unless util changed There's no reason to call the cpufreq hook if the root cfs_rq utilization has not been modified. Signed-off-by: Steve Muckle <smuckle@linaro.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com> Cc: Juri Lelli <Juri.Lelli@arm.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Patrick Bellasi <patrick.bellasi@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rafael J. Wysocki <rafael@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vincent Guittot <vincent.guittot@linaro.org> Link: http://lkml.kernel.org/r/1458606068-7476-2-git-send-email-smuckle@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 21e96f88776deead303ecd30a17d1d7c2a1776e3 Author: Steve Muckle <steve.muckle@linaro.org> Date: Mon Mar 21 17:21:07 2016 -0700 sched/fair: Move cpufreq hook to update_cfs_rq_load_avg() The cpufreq hook should be called whenever the root cfs_rq utilization changes so update_cfs_rq_load_avg() is a better place for it. The current location is not invoked in the enqueue_entity() or update_blocked_averages() paths. Suggested-by: Vincent Guittot <vincent.guittot@linaro.org> Signed-off-by: Steve Muckle <smuckle@linaro.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com> Cc: Juri Lelli <Juri.Lelli@arm.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Morten Rasmussen <morten.rasmussen@arm.com> Cc: Patrick Bellasi <patrick.bellasi@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rafael J. Wysocki <rafael@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1458606068-7476-1-git-send-email-smuckle@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 50 ++++++++++++++++++++++++++------------------------ 1 file changed, 26 insertions(+), 24 deletions(-) commit 1f621e028baf391f6684003e32e009bc934b750f Author: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Date: Wed Apr 6 18:47:40 2016 +0530 sched/fair: Fix asym packing to select correct CPU When asymmetric packing is set in the sched_domain and target CPU is busy, update_sd_pick_busiest() may not select the busiest runqueue. When target CPU is busy, find_busiest_group() will ignore checks for asym packing and may continue to load balance using the currently selected not-the-busiest runqueue as source runqueue. Selecting the busiest runqueue as source when the target CPU is busy, should result in achieving much better load balance. Also when target CPU is not busy and asymmetric packing is set in sd, select higher CPU as source CPU for load balancing. While doing this change, move the check to see if target CPU is busy into check_asym_packing(). The extent of performance benefit from this change decreases with the increasing load. However there is benefit in undercommit as well as overcommit conditions. 1. Record per second ebizzy (32 threads) on a 64 CPU power 7 box. (5 iterations) 4.6.0-rc2 Testcase: Min Max Avg StdDev ebizzy: 5223767.00 10368236.00 7946971.00 1753094.76 4.6.0-rc2+asym-changes Testcase: Min Max Avg StdDev %Change ebizzy: 8617191.00 13872356.00 11383980.00 1783400.89 +24.78% 2. Record per second ebizzy (64 threads) on a 64 CPU power 7 box. (5 iterations) 4.6.0-rc2 Testcase: Min Max Avg StdDev ebizzy: 6497666.00 18399783.00 10818093.20 4051452.08 4.6.0-rc2+asym-changes Testcase: Min Max Avg StdDev %Change ebizzy: 7567365.00 19456937.00 11674063.60 4295407.48 +4.40% 3. Record per second ebizzy (128 threads) on a 64 CPU power 7 box. (5 iterations) 4.6.0-rc2 Testcase: Min Max Avg StdDev ebizzy: 37073983.00 40341911.00 38776241.80 1259766.82 4.6.0-rc2+asym-changes Testcase: Min Max Avg StdDev %Change ebizzy: 38030399.00 41333378.00 39827404.40 1255001.86 +2.54% Signed-off-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Gautham R Shenoy <ego@linux.vnet.ibm.com> Cc: Michael Neuling <mikey@neuling.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com> Link: http://lkml.kernel.org/r/1459948660-16073-1-git-send-email-srikar@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 84eaae155a16d7864f0f814934e5062885cb0709 Merge: f454bfd c3b46c7 Author: Ingo Molnar <mingo@kernel.org> Date: Sat Apr 23 14:16:36 2016 +0200 Merge tag 'v4.6-rc4' into sched/core, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 31b84310c79421d726621e800434c66a48a6c959 Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Apr 21 15:15:47 2016 +0200 x86/perf/rapl: Add missing Broadwell model With the array aligned as per events/intel/core.c it was fairly obvious we missed one, add it in. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/rapl.c | 1 + 1 file changed, 1 insertion(+) commit c416e5aa40c51b3e8ae75a3e122dd5eabce078cd Author: Peter Zijlstra <peterz@infradead.org> Date: Thu Apr 21 15:14:17 2016 +0200 x86/perf/rapl: Reorder model numbers Re-order the model array to match the order in events/intel/core.c, to easier spot gaps and such. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/rapl.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) commit dcee75b3b7f025cc6765e6c92ba0a4e59a4d25f4 Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Date: Sun Apr 17 15:03:00 2016 -0700 perf/x86/intel/rapl: Support Skylake RAPL domains Add Skylake client support for RAPL domains. In addition to RAPL domains in Broadwell clients, it has support for platform domain (aka PSys). The PSys domain controls the entire SoC instead of just a CPU package. Unlike package domain, PSys support requires more than just processor level implementation. The other parts in the system need additional HW level signaling, which OEMs need to support. When not supported, the energy counter register in PSys domain returns 0. Also corrected error in comment for GPU counter, which previously was DRAM counter. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com [ Cnverted to model_match stuff. ] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: bp@alien8.de Cc: hpa@zytor.com Cc: jacob.jun.pan@linux.intel.com Cc: rjw@rjwysocki.net Link: http://lkml.kernel.org/r/1460930581-29748-2-git-send-email-srinivas.pandruvada@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/rapl.c | 54 ++++++++++++++++++++++++++++++++++++++-- arch/x86/include/asm/msr-index.h | 2 ++ 2 files changed, 54 insertions(+), 2 deletions(-) commit 9ecda41acb971ebd07c8fb35faf24005c0baea12 Author: Wang Nan <wangnan0@huawei.com> Date: Tue Apr 5 14:11:18 2016 +0000 perf/core: Add ::write_backward attribute to perf event This patch introduces 'write_backward' bit to perf_event_attr, which controls the direction of a ring buffer. After set, the corresponding ring buffer is written from end to beginning. This feature is design to support reading from overwritable ring buffer. Ring buffer can be created by mapping a perf event fd. Kernel puts event records into ring buffer, user tooling like perf fetch them from address returned by mmap(). To prevent racing between kernel and tooling, they communicate to each other through 'head' and 'tail' pointers. Kernel maintains 'head' pointer, points it to the next free area (tail of the last record). Tooling maintains 'tail' pointer, points it to the tail of last consumed record (record has already been fetched). Kernel determines the available space in a ring buffer using these two pointers to avoid overwrite unfetched records. By mapping without 'PROT_WRITE', an overwritable ring buffer is created. Different from normal ring buffer, tooling is unable to maintain 'tail' pointer because writing is forbidden. Therefore, for this type of ring buffers, kernel overwrite old records unconditionally, works like flight recorder. This feature would be useful if reading from overwritable ring buffer were as easy as reading from normal ring buffer. However, there's an obscure problem. The following figure demonstrates a full overwritable ring buffer. In this figure, the 'head' pointer points to the end of last record, and a long record 'E' is pending. For a normal ring buffer, a 'tail' pointer would have pointed to position (X), so kernel knows there's no more space in the ring buffer. However, for an overwritable ring buffer, kernel ignore the 'tail' pointer. (X) head . | . V +------+-------+----------+------+---+ |A....A|B.....B|C........C|D....D| | +------+-------+----------+------+---+ Record 'A' is overwritten by event 'E': head | V +--+---+-------+----------+------+---+ |.E|..A|B.....B|C........C|D....D|E..| +--+---+-------+----------+------+---+ Now tooling decides to read from this ring buffer. However, none of these two natural positions, 'head' and the start of this ring buffer, are pointing to the head of a record. Even the full ring buffer can be accessed by tooling, it is unable to find a position to start decoding. The first attempt tries to solve this problem AFAIK can be found from [1]. It makes kernel to maintain 'tail' pointer: updates it when ring buffer is half full. However, this approach introduces overhead to fast path. Test result shows a 1% overhead [2]. In addition, this method utilizes no more tham 50% records. Another attempt can be found from [3], which allows putting the size of an event at the end of each record. This approach allows tooling to find records in a backward manner from 'head' pointer by reading size of a record from its tail. However, because of alignment requirement, it needs 8 bytes to record the size of a record, which is a huge waste. Its performance is also not good, because more data need to be written. This approach also introduces some extra branch instructions to fast path. 'write_backward' is a better solution to this problem. Following figure demonstrates the state of the overwritable ring buffer when 'write_backward' is set before overwriting: head | V +---+------+----------+-------+------+ | |D....D|C........C|B.....B|A....A| +---+------+----------+-------+------+ and after overwriting: head | V +---+------+----------+-------+---+--+ |..E|D....D|C........C|B.....B|A..|E.| +---+------+----------+-------+---+--+ In each situation, 'head' points to the beginning of the newest record. From this record, tooling can iterate over the full ring buffer and fetch records one by one. The only limitation that needs to be considered is back-to-back reading. Due to the non-deterministic of user programs, it is impossible to ensure the ring buffer keeps stable during reading. Consider an extreme situation: tooling is scheduled out after reading record 'D', then a burst of events come, eat up the whole ring buffer (one or multiple rounds). When the tooling process comes back, reading after 'D' is incorrect now. To prevent this problem, we need to find a way to ensure the ring buffer is stable during reading. ioctl(PERF_EVENT_IOC_PAUSE_OUTPUT) is suggested because its overhead is lower than ioctl(PERF_EVENT_IOC_ENABLE). By carefully verifying 'header' pointer, reader can avoid pausing the ring-buffer. For example: /* A union of all possible events */ union perf_event event; p = head = perf_mmap__read_head(); while (true) { /* copy header of next event */ fetch(&event.header, p, sizeof(event.header)); /* read 'head' pointer */ head = perf_mmap__read_head(); /* check overwritten: is the header good? */ if (!verify(sizeof(event.header), p, head)) break; /* copy the whole event */ fetch(&event, p, event.header.size); /* read 'head' pointer again */ head = perf_mmap__read_head(); /* is the whole event good? */ if (!verify(event.header.size, p, head)) break; p += event.header.size; } However, the overhead is high because: a) In-place decoding is not safe. Copying-verifying-decoding is required. b) Fetching 'head' pointer requires additional synchronization. (From Alexei Starovoitov: Even when this trick works, pause is needed for more than stability of reading. When we collect the events into overwrite buffer we're waiting for some other trigger (like all cpu utilization spike or just one cpu running and all others are idle) and when it happens the buffer has valuable info from the past. At this point new events are no longer interesting and buffer should be paused, events read and unpaused until next trigger comes.) This patch utilizes event's default overflow_handler introduced previously. perf_event_output_backward() is created as the default overflow handler for backward ring buffers. To avoid extra overhead to fast path, original perf_event_output() becomes __perf_event_output() and marked '__always_inline'. In theory, there's no extra overhead introduced to fast path. Performance testing: Calling 3000000 times of 'close(-1)', use gettimeofday() to check duration. Use 'perf record -o /dev/null -e raw_syscalls:*' to capture system calls. In ns. Testing environment: CPU : Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz Kernel : v4.5.0 MEAN STDVAR BASE 800214.950 2853.083 PRE1 2253846.700 9997.014 PRE2 2257495.540 8516.293 POST 2250896.100 8933.921 Where 'BASE' is pure performance without capturing. 'PRE1' is test result of pure 'v4.5.0' kernel. 'PRE2' is test result before this patch. 'POST' is test result after this patch. See [4] for the detailed experimental setup. Considering the stdvar, this patch doesn't introduce performance overhead to the fast path. [1] http://lkml.iu.edu/hypermail/linux/kernel/1304.1/04584.html [2] http://lkml.iu.edu/hypermail/linux/kernel/1307.1/00535.html [3] http://lkml.iu.edu/hypermail/linux/kernel/1512.0/01265.html [4] http://lkml.kernel.org/g/56F89DCD.1040202@huawei.com Signed-off-by: Wang Nan <wangnan0@huawei.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Alexei Starovoitov <ast@kernel.org> Cc: <acme@kernel.org> Cc: <pi3orama@163.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/r/1459865478-53413-1-git-send-email-wangnan0@huawei.com [ Fixed the changelog some more. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/perf_event.h | 28 +++++++++++++++++++++--- include/uapi/linux/perf_event.h | 3 ++- kernel/events/core.c | 48 ++++++++++++++++++++++++++++++++++++----- kernel/events/ring_buffer.c | 16 +++++++++++++- 4 files changed, 85 insertions(+), 10 deletions(-) commit f21d5adceb7f2660e5227569faed278f6fb2072e Author: Kan Liang <kan.liang@intel.com> Date: Fri Apr 15 00:53:45 2016 -0700 perf/x86/intel: Add LBR filter support for Silvermont and Airmont CPUs LBR filtering is also supported on the Silvermont and Airmont microarchitectures. The layout of MSR_LBR_SELECT is the same as Nehalem. Signed-off-by: Kan Liang <kan.liang@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1460706825-46163-1-git-send-email-kan.liang@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/core.c | 2 +- arch/x86/events/intel/lbr.c | 18 ++++++++++++++++++ arch/x86/events/perf_event.h | 2 ++ 3 files changed, 21 insertions(+), 1 deletion(-) commit 8b92c3a78d40fb220dc5ab122e3274d1b126bfbb Author: Kan Liang <kan.liang@intel.com> Date: Fri Apr 15 00:42:47 2016 -0700 perf/x86/intel: Add Goldmont CPU support Add perf core PMU support for Intel Goldmont CPU cores: - The init code is based on Silvermont. - There is a new cache event list, based on the Silvermont cache event list. - Goldmont has 32 LBR entries. It also uses new LBRv6 format, which report the cycle information using upper 16-bit of the LBR_TO. - It's recommended to use CPU_CLK_UNHALTED.CORE_P + NPEBS for precise cycles. For details, please refer to the latest SDM058: http://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-software-developer-vol-3b-part-2-manual.pdf Signed-off-by: Kan Liang <kan.liang@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1460706167-45320-1-git-send-email-kan.liang@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/core.c | 157 +++++++++++++++++++++++++++++++++++++++++++ arch/x86/events/intel/ds.c | 6 ++ arch/x86/events/intel/lbr.c | 13 +++- arch/x86/events/perf_event.h | 2 + 4 files changed, 177 insertions(+), 1 deletion(-) commit 65cbbd037b3d7be0a40bbdb5da9d43b0fccf17ee Merge: 9243ae5 b303e7c Author: Ingo Molnar <mingo@kernel.org> Date: Sat Apr 23 14:12:10 2016 +0200 Merge branch 'perf/urgent' into perf/core, to resolve conflict Signed-off-by: Ingo Molnar <mingo@kernel.org> commit ad08c4e97485694fee5ebb181983514facedbb19 Author: Tony Luck <tony.luck@intel.com> Date: Fri Apr 15 14:50:32 2016 -0700 EDAC, sb_edac: Remove double buffering of error records In the bad old days the functions from x86_mce_decoder_chain could be called in machine check context. So we used to carefully copy them and defer processing until later. But in f29a7aff4bd60 ("x86/mce: Avoid potential deadlock due to printk() in MCE context") we switched the logging code to save the record in a genpool, and call the functions that registered to be notified later from a work queue. So drop all the double buffering and do all the work we want to do as soon as sbridge_mce_check_error() is called. Signed-off-by: Tony Luck <tony.luck@intel.com> Cc: Aristeu Rozanski <arozansk@redhat.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Cc: patrickg@supermicro.com Link: http://lkml.kernel.org/r/100025611cd780d9bca72792b2b2146760da53e0.1460756761.git.tony.luck@intel.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/sb_edac.c | 88 ++------------------------------------------------ 1 file changed, 3 insertions(+), 85 deletions(-) commit ab67b6c22d8506b060a66ed0ce1a3e14e3b075e4 Author: Tony Luck <tony.luck@intel.com> Date: Thu Apr 21 10:34:14 2016 -0700 EDAC: Fix used after kfree() error in edac_unregister_sysfs() Code flow looks like this: device_unregister(&mci->dev); -> kobject_put+0x25/0x50 -> kobject_cleanup+0x77/0x190 -> device_release+0x32/0xa0 -> mci_attr_release+0x36/0x70 -> kfree(mci); bus_unregister(mci->bus); Fix is to grab a local copy of "mci->bus" and use that when we call bus_unregister(). Signed-off-by: Tony Luck <tony.luck@intel.com> Acked-by: Aristeu Rozanski <aris@redhat.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/21d595b0ab3d718d9cb206647f4ec91c05e62ec4.1461261078.git.tony.luck@intel.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/edac_mc_sysfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1aa6eb5c5b35771cfb28265eccd99b4b203b4154 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:13:56 2016 +0200 EDAC, altera: Avoid unused function warnings The recently added Arria10 OCRAM ECC support caused some new harmless warnings about unused functions when it is disabled: drivers/edac/altera_edac.c:1067:20: error: 'altr_edac_a10_ecc_irq' defined but not used [-Werror=unused-function] drivers/edac/altera_edac.c:658:12: error: 'altr_check_ecc_deps' defined but not used [-Werror=unused-function] This rearranges the code slightly to have those two functions inside of the same #ifdef that hides their callers. It also manages to avoid a forward declaration of the IRQ handler in the process. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Thor Thayer <tthayer@opensource.altera.com> Cc: Alan Tull <atull@opensource.altera.com> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: linux-edac <linux-edac@vger.kernel.org> Fixes: c7b4be8db8bc ("EDAC, altera: Add Arria10 OCRAM ECC support") Link: http://lkml.kernel.org/r/1460837650-1237650-2-git-send-email-arnd@arndb.de Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 78 ++++++++++++++++++++++------------------------ 1 file changed, 37 insertions(+), 41 deletions(-) commit 2c911f6cac9388830d2afb350d29f43f115b1a28 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:13:55 2016 +0200 EDAC, altera: Remove useless casts The altera EDAC driver refers to its per-device data using a cast to '(void *)', which makes the pointer non-const, though both the source and destination are actually const. Removing the annotation makes the reference (almost) fit into a single line for improved readability, and ensures that it is actually defined as const. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Thor Thayer <tthayer@opensource.altera.com> Cc: Alan Tull <atull@opensource.altera.com> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1460837650-1237650-1-git-send-email-arnd@arndb.de Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) commit d29c9ab1a2c81ce404883baba91e15ae35411900 Author: Doug Ledford <dledford@redhat.com> Date: Fri Apr 22 20:14:58 2016 -0400 IB/core: Fix oops in ib_cache_gid_set_default_gid When we fail to find the default gid index, we can't continue processing in this routine or else we will pass a negative index to later routines resulting in invalid memory access attempts and a kernel oops. Fixes: 03db3a2d81e6 (IB/core: Add RoCE GID table management) Signed-off-by: Doug Ledford <dledford@redhat.com> drivers/infiniband/core/cache.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 22292b91ee1a72ce744a2bd1b0f490ffc766f0dd Merge: 814a958 c20c8f7 Author: Tony Lindgren <tony@atomide.com> Date: Fri Apr 22 15:15:33 2016 -0700 Merge tag 'for-v4.7/omap-hwmod-a' of git://git.kernel.org/pub/scm/linux/kernel/git/pjw/omap-pending into omap-for-v4.7/soc ARM: OMAP2+: first set of hwmod changes for v4.7 For the DRA7xx platform, add IP block data for the McASP, PWMSS, and GPTimer12 IP blocks. Add lock and unlock functions for the RTC IP blocks on the DRA7xx, AM33xx, and AM43xx devices. And add a fix for the hwmod core for device driver unbind operations for IP blocks with hardreset lines. Basic build, boot, and PM test results are available here: http://www.pwsan.com/omap/testlogs/omap-hwmod-a-for-v4.7/20160410132119/ Note that the testbed here does not have the DRA7xx board included yet. commit 0bfb8dd3edd6e423b5053c86e10c97e92cf205ea Author: Dan Williams <dan.j.williams@intel.com> Date: Wed Apr 13 17:06:48 2016 -0700 libnvdimm: cleanup nvdimm_namespace_common_probe(), kill 'host' The 'host' variable can be killed as it is always the same as the passed in device. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/namespace_devs.c | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) commit 5a92289f41311a54ededb5e4ed474cc38f5d85de Author: Dan Williams <dan.j.williams@intel.com> Date: Mon Mar 21 15:43:53 2016 -0700 libnvdimm, pmem: kill ->pmem_queue and ->pmem_disk The devm conversion obviates the need to continue to remember the queue and disk locally in the driver. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pmem.c | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) commit ac515c084be9b3995f7aef0ae87797e75e0260f0 Author: Dan Williams <dan.j.williams@intel.com> Date: Tue Mar 22 00:29:43 2016 -0700 libnvdimm, pmem, pfn: move pfn setup to the core Now that pmem internals have been disentangled from pfn setup, that code can move to the core. This is in preparation for adding another user of the pfn-device capabilities. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/nd.h | 7 ++ drivers/nvdimm/pfn_devs.c | 181 +++++++++++++++++++++++++++++++++++++++++++++ drivers/nvdimm/pmem.c | 184 ---------------------------------------------- 3 files changed, 188 insertions(+), 184 deletions(-) commit 200c79da824c978fcf6eec1dc9c0a1e521133267 Author: Dan Williams <dan.j.williams@intel.com> Date: Tue Mar 22 00:22:16 2016 -0700 libnvdimm, pmem, pfn: make pmem_rw_bytes generic and refactor pfn setup In preparation for providing an alternative (to block device) access mechanism to persistent memory, convert pmem_rw_bytes() to nsio_rw_bytes(). This allows ->rw_bytes() functionality without requiring a 'struct pmem_device' to be instantiated. In other words, when ->rw_bytes() is in use i/o is driven through 'struct nd_namespace_io', otherwise it is driven through 'struct pmem_device' and the block layer. This consolidates the disjoint calls to devm_exit_badblocks() and devm_memunmap() into a common devm_nsio_disable() and cleans up the init path to use a unified pmem_attach_disk() implementation. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 2 +- drivers/nvdimm/btt_devs.c | 4 +- drivers/nvdimm/claim.c | 61 ++++++++++ drivers/nvdimm/nd.h | 40 +++++-- drivers/nvdimm/pfn_devs.c | 4 +- drivers/nvdimm/pmem.c | 236 ++++++++++++++------------------------ include/linux/nd.h | 9 +- tools/testing/nvdimm/Kbuild | 1 + tools/testing/nvdimm/test/iomap.c | 27 +++-- 9 files changed, 211 insertions(+), 173 deletions(-) commit 947df02d255a6a81a3832e831c5ca02078cfd529 Author: Dan Williams <dan.j.williams@intel.com> Date: Mon Mar 21 22:28:40 2016 -0700 libnvdimm, pmem: clean up resource print / request The leading '0x' in front of %pa is redundant, also we can just use %pR to simplify the print statement. The request parameters can be directly taken from the resource as well. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pmem.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 030b99e39cad33b104474fbe688e0eb23d8209b4 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 17 20:24:31 2016 -0700 libnvdimm, pmem: use devm_add_action to release bdev resources Register a callback to clean up the request_queue and put the gendisk at driver disable time. Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pmem.c | 88 +++++++++++++++++++++++---------------------------- 1 file changed, 39 insertions(+), 49 deletions(-) commit 9d90725ddca347450c4ab177ad680ed76063afd4 Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Mar 18 11:27:36 2016 -0700 libnvdimm, blk: move i/o infrastructure to nd_namespace_blk Consolidate the information for issuing i/o to a blk-namespace, and eliminate some pointer chasing. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 137 ++++++++++++++++++++++++++------------------------- include/linux/nd.h | 2 + 2 files changed, 71 insertions(+), 68 deletions(-) commit 8378af17a4021f01b3bed20c1bd19c3921c1f5ac Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 24 18:06:07 2016 -0700 libnvdimm, blk: quiet i/o error reporting I/O errors events have the potential to be a high frequency and a log message for each event can swamp the system. This message is also redundant with upper layer error reporting. Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bd842b8ca7f207b99a5476a8174e62c29a2ff80e Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Mar 18 23:47:43 2016 -0700 libnvdimm, pmem: use ->queuedata for driver private data Save a pointer chase by storing the driver private data in the request_queue rather than the gendisk. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/pmem.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit d44077a7cddce18fc8d83194bb4c83a0225f0f40 Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Mar 18 23:45:45 2016 -0700 libnvdimm, blk: use ->queuedata for driver private data Save a pointer chase by storing the driver private data in the request_queue rather than the gendisk. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit d29cee120eb890027c69f5fe7cce8bd6a663900a Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 17 20:08:28 2016 -0700 libnvdimm, blk: use devm_add_action to release bdev resources Register a callback to clean up the request_queue and put the gendisk at driver disable time. Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 77 ++++++++++++++++++++++++---------------------------- 1 file changed, 36 insertions(+), 41 deletions(-) commit 9dec4892ca9afd6aad3c9c9e6c17480ecbd04440 Author: Dan Williams <dan.j.williams@intel.com> Date: Fri Apr 22 12:26:05 2016 -0700 libnvdimm, btt: add btt startup debug Report the reason for btt probe failures when debug is enabled. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/btt.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit b72541b33825807d247b6455364db9cd3ca5d6ad Merge: f55532a 3652bb3 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Fri Apr 22 12:25:34 2016 -0700 Merge tag 'bcm2835-defconfig-next-2016-04-20' into defconfig/next This pull request brings in changes for bcm2835_defconfig and multi_v7_defconfig in 4.7. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> commit 3db62afd11738f896ef83132022a40be74961860 Merge: 1b47b98 896ad42 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Fri Apr 22 12:22:04 2016 -0700 Merge tag 'bcm2835-dt-next-2016-04-20' into devicetree/next This pull request brings in VC4 devicetree support and the other minor DT changes for 4.7. Also included is a DRM patch necessary to prevent regressions when simplefb and vc4 drivers are both present. The patch was suggested by the simplefb maintainer as the solution agreed upon at ELCE 2014, and was acked by the DRM maintainer for merging through this tree. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> commit a9abb475a4fd3e23f2de8bf134b71e10b560b910 Author: Luke Starrett <luke.starrett@broadcom.com> Date: Wed Apr 20 13:40:02 2016 -0400 arm64: dts: NS2 secondary core enablement via PSCI Declare PSCI-1.0 node and enable CPU_ON method via PSCI. Spin-table memreserve has been removed as well as syscon based reset, as PSCI-1.0 expects reset implementation in firmware. Signed-off-by: Luke Starrett <luke.starrett@broadcom.com> Acked-by: Scott Branden <scott.branden@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm64/boot/dts/broadcom/ns2.dtsi | 31 +++++++++---------------------- 1 file changed, 9 insertions(+), 22 deletions(-) commit 1b47b98acce2db0da632d056821420b33205b8b2 Author: Rafał Miłecki <zajec5@gmail.com> Date: Tue Apr 19 08:56:46 2016 +0200 ARM: BCM5301X: Add DT entry for SPI controller and NOR flash Controller is present on every BCM4708* board but only few devices have serial flash attached so mark it as disabled by default. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm/boot/dts/bcm4708-luxul-xwc-1000.dts | 4 ++++ arch/arm/boot/dts/bcm4708-smartrg-sr400ac.dts | 4 ++++ arch/arm/boot/dts/bcm5301x.dtsi | 14 ++++++++++++++ 3 files changed, 22 insertions(+) commit 86d3473224b004f920c107206d181d37db735145 Author: Baolin Wang <baolin.wang@linaro.org> Date: Fri Apr 8 14:02:12 2016 +0800 time: Introduce do_sys_settimeofday64() The do_sys_settimeofday() function uses a timespec, which is not year 2038 safe on 32bit systems. Thus this patch introduces do_sys_settimeofday64(), which allows us to transition users of do_sys_settimeofday() to using 64bit time types. Cc: Prarit Bhargava <prarit@redhat.com> Cc: Richard Cochran <richardcochran@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@kernel.org> Signed-off-by: Baolin Wang <baolin.wang@linaro.org> [jstultz: Include errno-base.h to avoid build issue on some arches] Signed-off-by: John Stultz <john.stultz@linaro.org> include/linux/timekeeping.h | 17 +++++++++++++++-- kernel/time/time.c | 8 ++++---- 2 files changed, 19 insertions(+), 6 deletions(-) commit 457db29bfcfd1d9cc717587c446a89d60499d4a9 Author: Baolin Wang <baolin.wang@linaro.org> Date: Fri Apr 8 14:02:11 2016 +0800 security: Introduce security_settime64() security_settime() uses a timespec, which is not year 2038 safe on 32bit systems. Thus this patch introduces the security_settime64() function with timespec64 type. We also convert the cap_settime() helper function to use the 64bit types. This patch then moves security_settime() to the header file as an inline helper function so that existing users can be iteratively converted. None of the existing hooks is using the timespec argument and therefor the patch is not making any functional changes. Cc: Serge Hallyn <serge.hallyn@canonical.com>, Cc: James Morris <james.l.morris@oracle.com>, Cc: "Serge E. Hallyn" <serge@hallyn.com>, Cc: Paul Moore <pmoore@redhat.com> Cc: Stephen Smalley <sds@tycho.nsa.gov> Cc: Kees Cook <keescook@chromium.org> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Richard Cochran <richardcochran@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@kernel.org> Reviewed-by: James Morris <james.l.morris@oracle.com> Signed-off-by: Baolin Wang <baolin.wang@linaro.org> [jstultz: Reworded commit message] Signed-off-by: John Stultz <john.stultz@linaro.org> include/linux/lsm_hooks.h | 5 +++-- include/linux/security.h | 20 +++++++++++++++++--- security/commoncap.c | 2 +- security/security.c | 2 +- 4 files changed, 22 insertions(+), 7 deletions(-) commit 02fad5e9b433da3829d39f0afb3c51b4b6409ed5 Author: David Lechner <david@lechnology.com> Date: Wed Mar 9 18:16:54 2016 -0600 clocksource: Add missing include of of.h. This header uses OF_DELCARE_1 which is defined in linux/of.h. This fixes getting unhelpful compiler error messages about missing ')' before a string constant. Cc: Prarit Bhargava <prarit@redhat.com> Cc: Richard Cochran <richardcochran@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@kernel.org> Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: John Stultz <john.stultz@linaro.org> include/linux/clocksource.h | 1 + 1 file changed, 1 insertion(+) commit e32bc729a3a486e20443db3379ecf67240b20616 Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 17 18:23:09 2016 -0700 libnvdimm, btt, convert nd_btt_probe() to devm Pass the device performing the probe so we can use a devm allocation for the btt superblock. Cc: Vishal Verma <vishal.l.verma@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 2 +- drivers/nvdimm/btt.c | 17 ++++++----------- drivers/nvdimm/btt_devs.c | 26 +++++++++++++------------- drivers/nvdimm/nd.h | 6 ++++-- drivers/nvdimm/pmem.c | 2 +- 5 files changed, 25 insertions(+), 28 deletions(-) commit bd032943b5b2b336994171dcebc11531a38b45ba Author: Dan Williams <dan.j.williams@intel.com> Date: Thu Mar 17 18:16:15 2016 -0700 libnvdimm, pfn, convert nd_pfn_probe() to devm Pass the device performing the probe so we can use a devm allocation for the pfn superblock. Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/nd.h | 6 ++++-- drivers/nvdimm/pfn_devs.c | 27 +++++++++++++-------------- drivers/nvdimm/pmem.c | 30 +++++++++--------------------- 3 files changed, 26 insertions(+), 37 deletions(-) commit 298f2bc5db3851cf2e839a0025425256ef852139 Author: Dan Williams <dan.j.williams@intel.com> Date: Tue Mar 15 16:41:04 2016 -0700 libnvdimm, pmem: kill pmem->ndns We can derive the common namespace from other information. We also do not need to cache it because all the usages are in slow paths. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/blk.c | 2 +- drivers/nvdimm/btt.c | 3 +-- drivers/nvdimm/nd.h | 2 +- drivers/nvdimm/pmem.c | 40 ++++++++++++++++++++++------------------ 4 files changed, 25 insertions(+), 22 deletions(-) commit 8a292d016d1cc4938ff14b4df25328230b08a408 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 20 16:43:56 2016 +0300 drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW Somehow my SNB GT1 (Dell XPS 8300) gets very unhappy around GPU hangs if the RPS EI/thresholds aren't suitably aligned. It seems like scheduling/timer interupts stop working somehow and things get stuck eg. in usleep_range(). I bisected the problem down to commit 8a5864377b12 ("drm/i915/skl: Restructured the gen6_set_rps_thresholds function") I observed that before all the values were at least multiples of 25, but afterwards they are not. And rounding things up to the next multiple of 25 does seem to help, so lets' do that. I also tried roundup(..., 5) but that wasn't sufficient. Also I have no idea if we might need this sort of thing on gen9+ as well. These are the original EI/thresholds: LOW_POWER GEN6_RP_UP_EI 12500 GEN6_RP_UP_THRESHOLD 11800 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 21250 BETWEEN GEN6_RP_UP_EI 10250 GEN6_RP_UP_THRESHOLD 9225 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 18750 HIGH_POWER GEN6_RP_UP_EI 8000 GEN6_RP_UP_THRESHOLD 6800 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 15000 These are after 8a5864377b12: LOW_POWER GEN6_RP_UP_EI 12500 GEN6_RP_UP_THRESHOLD 11875 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 21250 BETWEEN GEN6_RP_UP_EI 10156 GEN6_RP_UP_THRESHOLD 9140 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 18750 HIGH_POWER GEN6_RP_UP_EI 7812 GEN6_RP_UP_THRESHOLD 6640 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 15000 And these are what we have after this patch: LOW_POWER GEN6_RP_UP_EI 12500 GEN6_RP_UP_THRESHOLD 11875 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 21250 BETWEEN GEN6_RP_UP_EI 10175 GEN6_RP_UP_THRESHOLD 9150 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 18750 HIGH_POWER GEN6_RP_UP_EI 7825 GEN6_RP_UP_THRESHOLD 6650 GEN6_RP_DOWN_EI 25000 GEN6_RP_DOWN_THRESHOLD 15000 Cc: stable@vger.kernel.org Cc: Akash Goel <akash.goel@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Testcase: igt/kms_pipe_crc_basic/hang-read-crc-pipe-B Fixes: 8a5864377b12 ("drm/i915/skl: Restructured the gen6_set_rps_thresholds function") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461159836-9108-1-git-send-email-ville.syrjala@linux.intel.com Acked-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> drivers/gpu/drm/i915/i915_reg.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 4f4a8185011773f7520d9916c6857db946e7f9d1 Author: Shashank Sharma <shashank.sharma@intel.com> Date: Thu Apr 21 16:48:32 2016 +0530 drm/i915: Fake HDMI live status This patch does the following: - Fakes live status of HDMI as connected (even if that's not). While testing certain (monitor + cable) combinations with various intel platforms, it seems that live status register doesn't work reliably on some older devices. So limit the live_status check for HDMI detection, only for platforms from gen7 onwards. V2: restrict faking live_status to certain platforms V3: (Ville) - keep the debug message for !live_status case - fix indentation of comment - remove "warning" from the debug message (Jani) - Change format of fix details in the commit message Fixes: 237ed86c693d ("drm/i915: Check live status before reading edid") Cc: stable@vger.kernel.org # v4.4 Suggested-by: Ville Syrjala <ville.syrjala@linux.intel.com> Signed-off-by: Shashank Sharma <shashank.sharma@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461237606-16491-1-git-send-email-shashank.sharma@intel.com Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/intel_hdmi.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit c251d85df1d537511a703feb71c6e7c999a95111 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Apr 22 17:54:39 2016 +0300 drm: rcar-du: Fix compilation warning Commit d63c25e4245a ("drm: rcar-du: Use generic drm_connector_register_all() helper") left an unused local variable behind. Remove it. Fixes: d63c25e4245a ("drm: rcar-du: Use generic drm_connector_register_all() helper") Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461336879-2469-1-git-send-email-laurent.pinchart+renesas@ideasonboard.com drivers/gpu/drm/rcar-du/rcar_du_drv.c | 1 - 1 file changed, 1 deletion(-) commit 9f085ebb1a50f2728946028548c08860a9005c27 Author: Lyude <cpaul@redhat.com> Date: Wed Apr 13 10:58:33 2016 -0400 drm/i915: Get rid of intel_dp_dpcd_read_wake() Since we've fixed up drm_dp_dpcd_read() to allow for retries when things timeout, there's no use for having this function anymore. Good riddens. Signed-off-by: Lyude <cpaul@redhat.com> Tested-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460559513-32280-5-git-send-email-cpaul@redhat.com drivers/gpu/drm/i915/intel_dp.c | 81 ++++++++++++----------------------------- 1 file changed, 23 insertions(+), 58 deletions(-) commit f808f63372cc47119f81d94ec92f9d1b4e21c562 Author: Lyude <cpaul@redhat.com> Date: Fri Apr 15 10:25:35 2016 -0400 drm/dp_helper: Perform throw-away read before actual read in drm_dp_dpcd_read() This is part of a patch series to migrate all of the workarounds for commonly seen behavior from bad sinks in intel_dp_dpcd_read_wake() to drm's DP helper. Some sinks will just return garbage for the first aux tranaction they receive when coming out of sleep mode, so we need to perform an additional read before the actual read to workaround this. Changes since v5 - If the throwaway read in drm_dp_dpcd_read() fails, return the error from that instead of continuing. This follows the same logic we do in drm_dp_dpcd_access() (e.g. the error from the first transaction may differ from the errors that proceeding attempts might return). Signed-off-by: Lyude <cpaul@redhat.com> Tested-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460730335-5012-1-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_dp_helper.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 82922da39190199260a726d7081a8ea4873e5fd6 Author: Lyude <cpaul@redhat.com> Date: Wed Apr 13 10:58:31 2016 -0400 drm/dp_helper: Retry aux transactions on all errors This is part of a patch series to migrate all of the workarounds for commonly seen behavior from bad sinks in intel_dp_dpcd_read_wake() to drm's DP helper. We cannot rely on sinks NACKing or deferring when they can't receive transactions, nor can we rely on any other sort of consistent error to know when we should stop retrying. As such, we need to just retry unconditionally on errors. We also make sure here to return the error we encountered during the first transaction, since it's possible that retrying the transaction might return a different error then we had originally. This, along with the previous patch, work around a weird bug with the ThinkPad T560's and it's dock. When resuming the laptop, it appears that there's a short period of time where we're unable to complete any aux transactions, as they all immediately timeout. The only machine I'm able to reproduce this on is the T560 as other production Skylake models seem to be fine. The period during which AUX transactions fail appears to be around 22ms long. AFAIK, the dock for the T560 never actually turns off, the only difference is that it's in SST mode at the start of the resume process, so it's unclear as to why it would need so much time to come back up. There's been a discussion on this issue going on for a while on the intel-gfx mailing list about this that has, in addition to including developers from Intel, also had the correspondence of one of the hardware engineers for Intel: http://www.spinics.net/lists/intel-gfx/msg88831.html http://www.spinics.net/lists/intel-gfx/msg88410.html We've already looked into a couple of possible explanations for the problem: - Calling intel_dp_mst_resume() before right fix. intel_runtime_pm_enable_interrupts(). This was the first fix I tried, and while it worked it definitely wasn't the right fix. This worked because DP aux transactions don't actually require interrupts to work: static uint32_t intel_dp_aux_wait_done(struct intel_dp *intel_dp, bool has_aux_irq) { struct intel_digital_port *intel_dig_port = dp_to_dig_port(intel_dp); struct drm_device *dev = intel_dig_port->base.base.dev; struct drm_i915_private *dev_priv = dev->dev_private; i915_reg_t ch_ctl = intel_dp->aux_ch_ctl_reg; uint32_t status; bool done; #define C (((status = I915_READ_NOTRACE(ch_ctl)) & DP_AUX_CH_CTL_SEND_BUSY) == 0) if (has_aux_irq) done = wait_event_timeout(dev_priv->gmbus_wait_queue, C, msecs_to_jiffies_timeout(10)); else done = wait_for_atomic(C, 10) == 0; if (!done) DRM_ERROR("dp aux hw did not signal timeout (has irq: %i)!\n", has_aux_irq); #undef C return status; } When there's no interrupts enabled, we end up timing out on the wait_event_timeout() call, which causes us to check the DP status register once to see if the transaction was successful or not. Since this adds a 10ms delay to each aux transaction, it ends up adding a long enough delay to the resume process for aux transactions to become functional again. This gave us the illusion that enabling interrupts had something to do with making things work again, and put me on the wrong track for a while. - Interrupts occurring when we try to perform the aux transactions required to put the dock back into MST mode. This isn't the problem, as the only interrupts I've observed that come during this timeout period are from the snd_hda_intel driver, and disabling that driver doesn't appear to change the behavior at all. - Skylake's PSR block causing issues by performing aux transactions while we try to bring the dock out of MST mode. Disabling PSR through i915's command line options doesn't seem to change the behavior either, nor does preventing the DMC firmware from being loaded. Since this investigation went on for about 2 weeks, we decided it would be better for the time being to just workaround this issue by making sure AUX transactions wait a short period of time before retrying. Signed-off-by: Lyude <cpaul@redhat.com> Tested-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460559513-32280-3-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_dp_helper.c | 42 +++++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 20 deletions(-) commit e1083ff35157185b01bc0a99cb19b7cbae0fc9fa Author: Lyude <cpaul@redhat.com> Date: Wed Apr 13 10:58:30 2016 -0400 drm/dp_helper: Always wait before retrying native aux transactions This is part of a patch series to migrate all of the workarounds for commonly seen behavior from bad sinks in intel_dp_dpcd_read_wake() to drm's DP helper. Some sinks need some time during the process of resuming the system from sleep before they're ready to handle transactions. While it would be nice if they responded with NACKs in these scenarios, this isn't always the case as a few sinks will just timeout on all of the transactions they receive until they're ready. Signed-off-by: Lyude <cpaul@redhat.com> Tested-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460559513-32280-2-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_dp_helper.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 5aa43599daddbe972f955b2357c76866a6f92973 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 22 18:09:41 2016 +0530 regulator: max77620: Add support for device specific ramp rate setting Maxim advertised the ramp rate of the rail with some recommended design specification like output capacitance of rail should be 2.2uF. This make sure that current change in the rail is within maximum current limit and hence meet the advertised ramp rate. If there is variation in design which causes the rail current to change more that maximum current limit then device applies the current limit. In this case, ramp rate is different than advertised ramp rate. Add device specific settings for ramp rate which need to be configure on device register when measure ramp rate on platform is deviated from advertised ramp rate. In this case, all delay time calculation for voltage change is done with measured ramp rate and device ramp rate is used for configuring the device register. If measured ramp rate in the platform is same as advertised ramp rate then regulator-ramp-delay is used for the device register configuration and ramp time calculation for voltage change. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/max77620-regulator.c | 83 +++++++++++++++++++++++----------- 1 file changed, 56 insertions(+), 27 deletions(-) commit e7fc278ceb5725070e4e3ecfc2f259ab2101c30e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 22 18:09:40 2016 +0530 regulator: max77620: Add details of device specific ramp rate setting It is observed that the ramp rate measured on platform is not same as advertised ramp rate due to platform design variation. On this case, measured ramp rate is provided with property regulator-ramp-rate. For such cases, add DT property for device specific configurations. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../bindings/regulator/regulator-max77620.txt | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit ae48a35c408732413880d0ac0d6467baa5b3d68a Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Fri Apr 22 14:16:26 2016 +0100 ASoC: da7218: Update PLL ranges and dividers to improve locking The expected MCLK frequency ranges and the associated dividers are updated to improve PLL locking in a corner scenario, with low MCLK frequency near an input divider change boundary. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7218.c | 32 ++++++++++++++++---------------- sound/soc/codecs/da7218.h | 21 ++++++++++++--------- 2 files changed, 28 insertions(+), 25 deletions(-) commit 989ffc7bd6b0f5ea3423631981f87fde495a8acb Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 12:55:24 2016 +0300 spi: pic32-sqi: silence array overflow warning We read one element beyond the end of the array when we access "rdesc[i + 1]" so it causes a static checker warning. It's harmless because we write over it again on the next line. But let's just silence the warning. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pic32-sqi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6b126245907a77642efe738f81837dc58e3a5d28 Author: Marek Vasut <marex@denx.de> Date: Wed Apr 13 12:24:58 2016 +0000 ARM: dts: socfpga: Add samtec VIN|ING board Add support for board based on the popular Altera Cyclone V SoC. This board has the following properties: - 1 GiB of DRAM - 1 Gigabit ethernet - 1 USB gadget port - 1 USB host port with an on-board hub - 2 QSPI NORs connected to the Cadence QSPI core - Multiple I2C EEPROMs and one I2C temperature sensor Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/socfpga_cyclone5_vining_fpga.dts | 310 +++++++++++++++++++++ 2 files changed, 311 insertions(+) commit 710a1d54452afbc9435bdb3f48f81f6801db14d6 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Fri Apr 22 15:17:28 2016 +0200 spi: spi-orion: enable the driver on ARCH_MVEBU platforms The SPI controller managed by the spi-orion is used on the new ARM64 Marvell Armada 7K/8K SoCs. In order to allow this driver to be built for this platform, we allow it to be selected for ARCH_MVEBU=y configurations. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 47baf2a5332de6cfb21d1e7e0d2e36640362ff48 Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:46:06 2016 +0300 drm/i915/bxt: Force reprogramming a PHY with invalid HW state It's possible that BIOS enables PHY0, but it programmes only the first channel on it. Since we program the PHYs only during driver loading this is an incorrect configuration from the driver's point of view, since we may use both channels eventually. Detect this scenario and force reprogramming the PHY in this case. The actual scenario for me was that the lane optimization for the second channel in PHY0 was not setup by BIOS and so a state verification warning was triggered. Everything else was setup properly. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461174366-16758-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) commit 01a01ef2eaf0eb90f4582f911e9fbce3f79d55e7 Author: Imre Deak <imre.deak@intel.com> Date: Thu Apr 21 19:19:21 2016 +0300 drm/i915/bxt: Wait for PHY1 GRC done if PHY0 was already enabled If we skipped PHY0 initialization because it was already enabled by BIOS, we still have to wait for the PHY1 GRC calibration as that is done as part of the PHY0 init. v2: - Use the actual PHY index in the debug message in broxton_phy_wait_grc_done() (Ville) CC: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461255561-1644-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) commit 67856d4d3ccdd4612bcef3a7b624aa33e5b6828d Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:46:04 2016 +0300 drm/i915/bxt: Use PHY0 GRC value for HW state verification It's possible that BIOS enables PHY1 only to read out the GRC value from it to be used in PHY0 and then disables PHY1. In this case we can't use the PHY1 GRC value for state verification, so use instead the one in PHY0 always. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461174366-16758-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5c0e03cd9f10d541b69b667a2b1b8980f196f432 Author: Johan Hedberg <johan.hedberg@intel.com> Date: Fri Apr 22 15:59:25 2016 +0300 Bluetooth: Add defines for SPI and I2C Extend the set of possible HCI bus types with SPI and I2C. Signed-off-by: Johan Hedberg <johan.hedberg@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/net/bluetooth/hci.h | 2 ++ 1 file changed, 2 insertions(+) commit 23fe440c59b9f08afe108e7ec7b6714cb2a3b955 Author: Peter Rosin <peda@axentia.se> Date: Wed Mar 2 15:14:22 2016 +0100 i2c: mux: drop old unused i2c-mux api All i2c mux users are using an explicit i2c mux core, drop support for implicit i2c mux cores. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-mux.c | 63 ------------------------------------------------- include/linux/i2c-mux.h | 15 ------------ 2 files changed, 78 deletions(-) commit b6e3b7171b1e416963e36bb91ff6cce1caaaf675 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:42:47 2016 +0200 of/unittest: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select op to be in terms of the i2c mux core instead of the child adapter. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/of/unittest.c | 37 ++++++++++++------------------------- 1 file changed, 12 insertions(+), 25 deletions(-) commit 05e0dfd0311bd6dd3cdb6cb32acd1e701c451e9b Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:42:17 2016 +0200 [media] cx231xx: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select op to be in terms of the i2c mux core instead of the child adapter. Tested-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/usb/cx231xx/cx231xx-core.c | 6 ++-- drivers/media/usb/cx231xx/cx231xx-i2c.c | 47 ++++++++++++++++---------------- drivers/media/usb/cx231xx/cx231xx.h | 4 ++- 3 files changed, 31 insertions(+), 26 deletions(-) commit 58d7b541dd96535b03cc9dd13fe9efff2a5402e0 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:41:36 2016 +0200 [media] si2168: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/si2168.c | 25 +++++++++++++++---------- drivers/media/dvb-frontends/si2168_priv.h | 2 +- 2 files changed, 16 insertions(+), 11 deletions(-) commit cddcc40b1b1553010acb89add84c64b5d123ec94 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:41:25 2016 +0200 [media] rtl2832: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/rtl2832.c | 25 ++++++++++++++----------- drivers/media/dvb-frontends/rtl2832_priv.h | 2 +- 2 files changed, 15 insertions(+), 12 deletions(-) commit a0119159e66e2e67154384d7e20a0ebf46cfa32b Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:41:13 2016 +0200 [media] rtl2830: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select op to be in terms of the i2c mux core instead of the child adapter. Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/rtl2830.c | 20 ++++++++++++-------- drivers/media/dvb-frontends/rtl2830_priv.h | 2 +- 2 files changed, 13 insertions(+), 9 deletions(-) commit e00fed40f48e43bdb5e018156d077c65b61f93bf Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:41:02 2016 +0200 [media] m88ds3103: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select op to be in terms of the i2c mux core instead of the child adapter. Tested-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/media/dvb-frontends/m88ds3103.c | 19 +++++++++++-------- drivers/media/dvb-frontends/m88ds3103_priv.h | 2 +- 2 files changed, 12 insertions(+), 9 deletions(-) commit 51f97f6dd73d9349f8e6a1d36ac5f7371d275fb3 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:40:49 2016 +0200 iio: imu: inv_mpu6050: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Acked-by: Jonathan Cameron <jic23@kernel.org> Tested-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c | 2 +- drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 1 - drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 33 +++++++++++++++--------------- drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h | 3 ++- 4 files changed, 19 insertions(+), 20 deletions(-) commit 193304aef8523265884f08144b1f98ad272e2d7e Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:40:27 2016 +0200 i2c: i2c-mux-reg: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-reg.c | 69 +++++++++++++++-------------------------- 1 file changed, 25 insertions(+), 44 deletions(-) commit 7fcac980717532a20762e03f0d228bfc58393ed3 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:40:14 2016 +0200 i2c: i2c-mux-pca954x: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Add a mask to handle the case where not all child adapters should cause a mux deselect to happen, now that there is a common deselect op for all child adapters. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-pca954x.c | 61 ++++++++++++++++++------------------- 1 file changed, 30 insertions(+), 31 deletions(-) commit ab88b97c69ce375ef10c551133d6d19ffd55d763 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:40:02 2016 +0200 i2c: i2c-mux-pca9541: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-pca9541.c | 58 +++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 31 deletions(-) commit 8aacd90166f6b60df83e0907b1e931e3971a92ab Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:39:46 2016 +0200 i2c: i2c-arb-gpio-challenge: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-arb-gpio-challenge.c | 47 +++++++++++++----------------- 1 file changed, 20 insertions(+), 27 deletions(-) commit 4bbe7fb0a23244937be315866ae166ba74e32d06 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:39:31 2016 +0200 i2c: i2c-mux-pinctrl: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-pinctrl.c | 83 ++++++++++++++----------------------- 1 file changed, 30 insertions(+), 53 deletions(-) commit bb44814763ff4f69d83818342c2b4ba09efbab0f Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:39:05 2016 +0200 i2c: i2c-mux-gpio: convert to use an explicit i2c mux core Allocate an explicit i2c mux core to handle parent and child adapters etc. Update the select/deselect ops to be in terms of the i2c mux core instead of the child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/muxes/i2c-mux-gpio.c | 55 ++++++++++++++++------------------------ 1 file changed, 22 insertions(+), 33 deletions(-) commit a7ab72390b77062420fb50e4451f71c9321aae05 Author: Peter Rosin <peda@axentia.se> Date: Wed Apr 20 08:38:50 2016 +0200 i2c: mux: add common data for every i2c-mux instance All i2c-muxes have a parent adapter and one or many child adapters. A mux also has some means of selection. Previously, this was stored per child adapter, but it is only needed to keep track of this per mux. Add an i2c mux core, that keeps track of this consistently. Also add some glue for users of the old interface, which will create one implicit mux core per child adapter. Signed-off-by: Peter Rosin <peda@axentia.se> Tested-by: Antti Palosaari <crope@iki.fi> Tested-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-mux.c | 175 ++++++++++++++++++++++++++++++++++++------------ include/linux/i2c-mux.h | 34 ++++++++++ 2 files changed, 168 insertions(+), 41 deletions(-) commit df28564d9848358c9a4104d2b4a6c44b384fcc9c Author: Matthew Auld <matthew.auld@intel.com> Date: Fri Apr 22 12:09:25 2016 +0100 drm/i915: use dev_priv directly in gen8_ppgtt_notify_vgt Remove dev local and use to_i915() in gen8_ppgtt_notify_vgt. v2: use dev_priv directly for QUESTION_MACROS (Joonas Lahtinen) Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Matthew Auld <matthew.auld@intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461323365-21256-1-git-send-email-matthew.auld@intel.com drivers/gpu/drm/i915/i915_gem_gtt.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit f62c79b33ff150da40fcdfc8cd48d0dd77f62902 Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:27:57 2016 +0300 drm/i915/bxt: Enable DC5 during runtime resume Right after runtime resume we know that we can re-enable DC5, since we just disabled DC9 and power well 2 is disabled. So enable DC5 explicitly instead of delaying this until the next time we disable power well 2. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Bob Paauwe <bob.j.paauwe@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461173277-16090-5-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 3 +++ drivers/gpu/drm/i915/intel_drv.h | 1 + drivers/gpu/drm/i915/intel_runtime_pm.c | 2 +- 3 files changed, 5 insertions(+), 1 deletion(-) commit da2f41d107e57074814ad44f4cea2b7befe3b7c4 Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:27:56 2016 +0300 drm/i915/bxt: Sanitize DC state tracking during system resume After suspend-to-ram or -disk we don't know what power state the display HW will be, DC0 or DC9 are both possible states, so reset the software DC state tracking in these cases. This gets rid of 'DC state mismatch' error messages during resuming from ram or disk where we expected to be in DC9 (as set by the suspend handler) but we are in DC0. v2: - Remove extra WS in gen9_sanitize_dc_state() (Bob) Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Bob Paauwe <bob.j.paauwe@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461173277-16090-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 7 +++++-- drivers/gpu/drm/i915/intel_drv.h | 1 + drivers/gpu/drm/i915/intel_runtime_pm.c | 25 ++++++++++++++++++++++--- 3 files changed, 28 insertions(+), 5 deletions(-) commit b8aea3d1f408445f7683b47de09a8c6209c36409 Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:27:55 2016 +0300 drm/i915/bxt: Don't uninit/init display core twice during system suspend/resume Atm, we run the BSpec display core uninit/init sequences twice during system suspend/resume. While this shouldn't cause any problem, it's redundant, so get rid of the duplicate call. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Bob Paauwe <bob.j.paauwe@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461173277-16090-3-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 507e126e0700a71939935636a4d581a9323c5ec1 Author: Imre Deak <imre.deak@intel.com> Date: Wed Apr 20 20:27:54 2016 +0300 drm/i915: Inline intel_suspend_complete Initially we thought that the platform specific suspend/resume sequences can be shared between the runtime and system suspend/resume handlers. This turned out to be not true, we have quite a few differences on most of the platforms. This was realized already earlier by Paulo who inlined the platform specific resume_prepare handlers. We have the same problem with the corresponding suspend_complete handlers, there are platform differences that make it unfeasible to share the code between the runtime and system suspend paths. Also now we call functions that need to be paired like hsw_enable_pc8()/hsw_disable_pc8() from different levels of the call stack, which is confusing. Fix this by inlining the suspend_complete handlers too. This is also needed by the next patch that removes a redundant uninit/init call during system suspend/resume on BXT. No functional change. CC: Paulo Zanoni <przanoni@gmail.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Bob Paauwe <bob.j.paauwe@intel.com> [s/uninline/inline in the commit message] Link: http://patchwork.freedesktop.org/patch/msgid/1461173277-16090-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 83 ++++++++++++++--------------------------- 1 file changed, 29 insertions(+), 54 deletions(-) commit 4aec6ec0da9c72c0fa1a5b0d1133707481347bb3 Author: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Date: Tue Apr 19 18:34:24 2016 +0200 cxl: Increase timeout for detection of AFU mmio hang PSL designers recommend a larger value for the mmio hang pulse, 256 us instead of 1 us. The CAIA architecture states that it needs to be smaller than 1/2 of the RTOS timeout set in the PHB for outbound non-posted transactions, which is still (easily) the case here. Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Tested-by: Frank Haverkamp <haver@linux.vnet.ibm.com> Tested-by: Manoj Kumar <manoj@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/pci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e009a7e858fed215cb4eed5174a31cadd42d8797 Author: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Date: Mon Mar 21 14:32:48 2016 -0500 cxl: Allow initialization on timebase sync failures Failure to synchronize the PSL timebase currently prevents the initialization of the cxl card, thus rendering the card useless. This is too extreme for a feature which is rarely used, if at all. No hardware AFUs or software is currently using PSL timebase. This patch still tries to synchronize the PSL timebase when the card is initialized, but ignores the error if it can't. Instead, it reports a status via /sys. Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Documentation/ABI/testing/sysfs-class-cxl | 8 ++++++++ drivers/misc/cxl/cxl.h | 1 + drivers/misc/cxl/guest.c | 6 ++++++ drivers/misc/cxl/pci.c | 21 ++++++++++++--------- drivers/misc/cxl/sysfs.c | 10 ++++++++++ 5 files changed, 37 insertions(+), 9 deletions(-) commit ec6b925579b40225d58f0374ada0e40a003cde16 Author: Stephen Warren <swarren@nvidia.com> Date: Tue Apr 12 11:46:37 2016 -0600 ARM: tegra: Add DT binding for Tegra186 GPIO controllers Tegra186 contains two separate but mostly similar GPIO controllers. Register layout differs significantly from previous Tegra generations, and so a new binding is required to describe them in device tree. This patch adds that binding. Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/gpio/nvidia,tegra186-gpio.txt | 161 +++++++++++++++++++++ include/dt-bindings/gpio/tegra186-gpio.h | 56 +++++++ 2 files changed, 217 insertions(+) commit 1e48b695d79f9afb6357fe0217b2829e0faed77d Author: Stephen Warren <swarren@nvidia.com> Date: Tue Apr 5 13:25:07 2016 -0600 ARM: tegra: Fix naming in GPIO DT binding header According to the Tegra TRM, GPIOs are aggregated into /ports/ of 8 GPIOs, not into /banks/. Fix <dt-bindings/gpio/tegra-gpio.h> to correctly reflect this naming convention. While this seems like silly churn, it will become slightly more important once we introduce the GPIO binding for upcoming Tegra chips. Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Thierry Reding <treding@nvidia.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> include/dt-bindings/gpio/tegra-gpio.h | 68 +++++++++++++++++------------------ 1 file changed, 34 insertions(+), 34 deletions(-) commit dd1a571daee7cdd6504a5771721e34f9b118f17a Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Apr 21 17:12:01 2016 +0100 regulator: helpers: Ensure bypass register field matches ON value When checking bypass state for a regulator, we check to see if any bits in the bypass mask are set. For most cases this is fine because there is typically, only a single bit used to determine if the regulator is in bypass. However, for some regulators, such as LDO6 on AS3722, the bypass state is indicate by a value rather than a single bit. Therefore, when checking the bypass state, check that the bypass field matches the ON value. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/helpers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e9fc71649b5361b8ac608898342c8904167cb63d Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 22 13:02:55 2016 +0300 Bluetooth: ath3k: Silence uninitialized variable warning We could print an uninitialized value in the error message. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/ath3k.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit c438b9d017362b65f6b1a9e54f7f35e7f873dc7c Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Apr 21 17:11:59 2016 +0100 regulator: core: Move registration of regulator device The public functions to acquire a regulator, such as regulator_get(), internally look-up the regulator from the list of regulators that have been registered with the regulator device class. The registration of a new regulator with the regulator device class happens before the regulator has been completely setup. Therefore, it is possible that the regulator could be acquired before it has been setup successfully. To avoid this move the device registration of the regulator to the end of the regulator setup and update the error exit path accordingly. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) commit f89ba3383ee69e2e1473e41ed42614fc7c9d9192 Merge: 8e5356a 469b640 Author: Mark Brown <broonie@kernel.org> Date: Fri Apr 22 11:38:42 2016 +0100 Merge branch 'topic/sysfs-init' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator into regulator-supply commit 8e5356a73604f53da6a1e0756727cb8f9f7bba17 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Apr 21 17:11:58 2016 +0100 regulator: core: Clear the supply pointer if enabling fails During the resolution of a regulator's supply, we may attempt to enable the supply if the regulator itself is already enabled. If enabling the supply fails, then we will call _regulator_put() for the supply. However, the pointer to the supply has not been cleared for the regulator and this will cause a crash if we then unregister the regulator and attempt to call regulator_put() a second time for the supply. Fix this by clearing the supply pointer if enabling the supply after fails when resolving the supply for a regulator. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 1 + 1 file changed, 1 insertion(+) commit 7ddede6a58a0bd26efcfd2a5055611195411f514 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Apr 21 17:11:57 2016 +0100 regulator: core: Don't terminate supply resolution early The function regulator_register_resolve_supply() is called from the context of class_for_each_dev() (during the regulator registration) to resolve any supplies added. regulator_register_resolve_supply() will return an error if a regulator's supply cannot be resolved and this will terminate the loop in class_for_each_dev(). This means that we will not attempt to resolve any other supplies after one has failed. Hence, this may delay the resolution of other regulator supplies until the failing one itself can be resolved. Rather than terminating the loop early, don't return an error code and keep attempting to resolve any other supplies for regulators that have been registered. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit fbb88b5ca1dc84416fc1fec34773948b6780492c Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Fri Apr 22 12:25:33 2016 +0800 ASoC: Add kerneldoc comments for snd_soc_find_dai snd_soc_find_dai() has been exported and so add the kerneldoc comments for it. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/soc-core.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 54aba08f13fab00f31938993c9f7a9b0cd54f666 Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Fri Apr 22 09:09:14 2016 +0000 ASoC: tidyup alphabetical order for SND_SOC_Bxx Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 8 ++++---- sound/soc/codecs/Makefile | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) commit fba0d7066524ab7b8ccf60e7e95981d10ed008b0 Author: Vinod Koul <vinod.koul@intel.com> Date: Fri Apr 22 09:03:53 2016 +0530 ASoC: Intel: Atom: fix boot warning Users have reported seeing this false warning on atom driver [ 5.647469] sst-mfld-platform sst-mfld-platform: Slot control: codec_out tx interleaver slot 0 doesn't have DAPM widget!!! [ 5.661612] sst-mfld-platform sst-mfld-platform: Slot control: codec_out tx interleaver slot 1 doesn't have DAPM widget!!! [ 5.661646] sst-mfld-platform sst-mfld-platform: Slot control: codec_out tx interleaver slot 2 doesn't have DAPM widget!!! [ 5.661681] sst-mfld-platform sst-mfld-platform: Slot control: codec_out tx interleaver slot 3 doesn't have DAPM widget!!! [ 5.661708] sst-mfld-platform sst-mfld-platform: Slot control: codec_in rx deinterleaver codec_in0_0 doesn't have DAPM widget!!! [ 5.661738] sst-mfld-platform sst-mfld-platform: Slot control: codec_in rx deinterleaver codec_in0_1 doesn't have DAPM widget!!! [ 5.661771] sst-mfld-platform sst-mfld-platform: Slot control: codec_in rx deinterleaver codec_in1_0 doesn't have DAPM widget!!! [ 5.661807] sst-mfld-platform sst-mfld-platform: Slot control: codec_in rx deinterleaver codec_in1_1 doesn't have DAPM widget!!! This is caused when check for control is not being associated with a dapm widget, but the check is wrong as the else case maybe triggered when widget is not powered up, so we should check if widget is associated before printing this message. Tested-by: Sandeep Tayal <sandeepx.tayal@intel.com> Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/atom/sst-atom-controls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d80a91b2f2a96f38877bc328dac135d69564911 Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Thu Apr 21 17:23:21 2016 +0100 regulator: core: Add debugfs to show constraint flags There are debugfs entries for voltage and current, but not for the constraint flags. It's useful for debugging to be able to see what these flags are so this patch adds a new debugfs file. We can't use debugfs_create_bool for this because the flags are bitfields, so as this needs a special read callback they have been collected into a single file that lists all the flags. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 52 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) commit db71336b9eec22c21cef65c90cea49130c464994 Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Fri Apr 22 10:40:11 2016 +0200 ASoC: hdmi-codec: Add ELD control Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdmi-codec.c | 2 -- 1 file changed, 2 deletions(-) commit 1dff8083a024650c75a9c961c38082473ceae8cf Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 18:04:57 2016 +0200 mm: replace open coded page to virt conversion with page_to_virt() The open coded conversion from struct page address to virtual address in lowmem_page_address() involves an intermediate conversion step to pfn number/physical address. Since the placement of the struct page array relative to the linear mapping may be completely independent from the placement of physical RAM (as is that case for arm64 after commit dfd55ad85e 'arm64: vmemmap: use virtual projection of linear region'), the conversion to physical address and back again should factor out of the equation, but unfortunately, the shifting and pointer arithmetic involved prevent this from happening, and the resulting calculation essentially subtracts the address of the start of physical memory and adds it back again, in a way that prevents the compiler from optimizing it away. Since the start of physical memory is not a build time constant on arm64, the resulting conversion involves an unnecessary memory access, which we would like to get rid of. So replace the open coded conversion with a call to page_to_virt(), and use the open coded conversion as its default definition, to be overriden by the architecture, if desired. The existing arch specific definitions of page_to_virt are all equivalent to this default definition, so by itself this patch is a no-op. Acked-by: Andrew Morton <akpm@linux-foundation.org> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> include/linux/mm.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 86d618cd1d9fdf4b46b68eb014d4fbde08c4ae62 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 18:04:56 2016 +0200 openrisc: drop wrongly typed definition of page_to_virt() To align with generic code and other architectures that expect the macro page_to_virt to produce an expression whose type is 'void*', drop the arch specific definition, which is never referenced anyway. Acked-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/openrisc/include/asm/page.h | 2 -- 1 file changed, 2 deletions(-) commit 046982c760bcbb0d92981a7be577dbc081323a78 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Apr 18 18:04:55 2016 +0200 nios2: use correct void* return type for page_to_virt() To align with other architectures, the expression produced by expanding the macro page_to_virt() should be of type void*, since it returns a virtual address. Fix that, and also fix up an instance where page_to_virt was expected to return 'unsigned long', and drop another instance that was entirely unused (page_to_bus) Acked-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/nios2/include/asm/io.h | 1 - arch/nios2/include/asm/page.h | 2 +- arch/nios2/include/asm/pgtable.h | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) commit a50b22a7a1e60c48ca26cada362076b54823c501 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:46 2016 -0700 x86/init: Disable pnpbios and rtc for X86_SUBARCH_CE4100 As per hpa CE4100 platforms can also disable pnpbios: http://lkml.kernel.org/r/5702B5C2.7070101@zytor.com Then Sebastian also recently noted that CE4100 also disables RTC probe, to do that Sebastian had long ago added the RTC of_have_populated_dt() check, he noted that it was meant to skip the RTC probe on all OF platforms but as of now, CE4100 was the only x86 DT using this. We can just fold this requirement into the platform quirk then. This now means that all of these match platform quirks for pnpbios and RTC preferences: * X86_SUBARCH_XEN * X86_SUBARCH_LGUEST * X86_SUBARCH_INTEL_MID * X86_SUBARCH_CE4100 Also see: http://lkml.kernel.org/r/570B52EA.60300@linutronix.de Suggested-by: H. Peter Anvin <hpa@zytor.com> Suggested-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-17-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/platform-quirks.c | 1 + arch/x86/kernel/rtc.c | 3 --- 2 files changed, 1 insertion(+), 3 deletions(-) commit f6935b7bfbf8345bea05f73dc48ce81b70f016e0 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:45 2016 -0700 x86/init: Disable pnpbios for X86_SUBARCH_INTEL_MID As per hpa Intel MID platforms can also disable pnpbios: ttp://lkml.kernel.org/r/5702B5C2.7070101@zytor.com As per 0-day, this bumps the vmlinux size using i386-tinyconfig as follows: TOTAL TEXT init.text x86_early_init_platform_quirks() -8 -8 -8 -8 Suggested-by: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-16-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/platform-quirks.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 867fe800b4c423bce46e66ccb2ce91bebbd5afc6 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:44 2016 -0700 x86/paravirt: Remove paravirt_enabled() Now that all previous paravirt_enabled() uses were replaced with proper x86 semantics by the previous patches we can remove the unused paravirt_enabled() mechanism. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Acked-by: Juergen Gross <jgross@suse.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-15-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/paravirt.h | 5 ----- arch/x86/include/asm/paravirt_types.h | 1 - arch/x86/include/asm/processor.h | 1 - arch/x86/kernel/kvm.c | 8 -------- arch/x86/kernel/paravirt.c | 1 - arch/x86/lguest/boot.c | 2 -- arch/x86/xen/enlighten.c | 1 - 7 files changed, 19 deletions(-) commit f2d85299b7f11f73cc0a294e396cdae114e75787 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:43 2016 -0700 x86/init: Rename EBDA code file This makes it clearer what this is. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-14-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Makefile | 2 +- arch/x86/kernel/Makefile | 2 +- arch/x86/kernel/ebda.c | 71 ++++++++++++++++++++++++++++++++++++++++++++++++ arch/x86/kernel/head.c | 71 ------------------------------------------------ 4 files changed, 73 insertions(+), 73 deletions(-) commit 7a17b82ccd6671a4bb436df52eedeff906b02735 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:42 2016 -0700 x86/ACPI: Parse ACPI_FADT_LEGACY_DEVICES ACPI 5.2.9.3 IA-PC Boot Architecture flag ACPI_FADT_LEGACY_DEVICES can be used to determine if a system has legacy devices LPC or ISA devices. The x86 platform already has a struct which lists known associated legacy devices, we start off careful only by disabling root devices we should not regress with. The struct and device list can be expanded with time to cover more root legacy components. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-13-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/acpi/boot.c | 5 +++++ 1 file changed, 5 insertions(+) commit 80dfd83dfab6e49a31ab8fc484a801aef1c567bd Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:41 2016 -0700 x86, drivers/pnpbios: Replace paravirt_enabled() check with legacy device check Since we are removing paravirt_enabled() replace it with a logical equivalent. Even though PNPBIOS is x86 specific we add an arch-specific type call, which can be implemented by any architecture to show how other legacy attribute devices can later be also checked for with other ACPI legacy attribute flags. This implicates the first ACPI 5.2.9.3 IA-PC Boot Architecture ACPI_FADT_LEGACY_DEVICES flag device, and shows how to add more. The reason pnpbios gets a defined structure and as such uses a different approach than the RTC legacy quirk is that ACPI has a respective RTC flag, while pnpbios does not. We fold the pnpbios quirk under ACPI_FADT_LEGACY_DEVICES ACPI flag use case, and use a struct of possible devices to enable future extensions of this. As per 0-day, this bumps the vmlinux size using i386-tinyconfig as follows: TOTAL TEXT init.text x86_early_init_platform_quirks() +32 +28 +28 +28 That's 4 byte overhead total, the rest is cleared out on init as its all __init text. v2: split out subarch handlng on switch to make it easier later to add other subarchs. The 'fall-through' switch handling can be confusing and we'll remove it later when we add handling for X86_SUBARCH_CE4100. v3: document vmlinux size impact as per 0-day, and also explain why pnpbios is treated differently than the RTC legacy feature. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-12-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/x86_init.h | 26 ++++++++++++++++++++++++++ arch/x86/kernel/platform-quirks.c | 11 +++++++++++ drivers/pnp/pnpbios/core.c | 3 ++- include/linux/pnp.h | 2 ++ 4 files changed, 41 insertions(+), 1 deletion(-) commit fa392794ed8329379f3f637da7c3c2f078309a77 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:40 2016 -0700 x86/cpu/intel: Remove not needed paravirt_enabled() use for F00F work around The X86_BUG_F00F work around is responsible for fixing up the error generated on attempted F00F exploitation from an OOPS to a SIGILL. There is no reason why this code should not be allowed to run on PV guest on a F00F-affected CPU -- it would simply never trigger. The pv_enabled() check was there only to avoid printing the f00f workaround, so removing the check is purely a cosmetic change. Suggested-by: Andy Lutomirski <luto@amacapital.net> Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-11-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/intel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 44ecf0ef907fe45510566d308d670aa5823a4dd5 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:39 2016 -0700 x86/tboot: Remove paravirt_enabled() use There is already a check for boot_params.tboot_addr prior to paravirt_enabled(). Both Xen and lguest, which are also the only ones that set paravirt_enabled to true, never set the boot_params.tboot_addr. The Xen folks are sure a force disable to 0 is not needed, we recently forced disabled this on lguest. With this in place this check is no longer needed. Xen folks are sure force disable to 0 is not needed because apm_info lives in .bss, we recently forced disabled this on lguest, and on the Xen side just to be sure Boris zeroed out the .bss for PV guests through commit 04b6b4a56884327c1648 ("xen/x86: Zero out .bss for PV guests"). With this care taken into consideration the paravirt_enabled() check is simply not needed anymore. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-10-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/tboot.c | 6 ------ 1 file changed, 6 deletions(-) commit 8bc55f805697ec2a69c6a576fac8ee36ea9772bb Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:38 2016 -0700 x86/apm32: Remove paravirt_enabled() use There is already a check for apm_info.bios == 0, the apm_info.bios is set from the boot_params.apm_bios_info. Both Xen and lguest, which are also the only ones that set paravirt_enabled to true, never set the apm_bios.info. The Xen folks are sure force disable to 0 is not needed because apm_info lives in .bss, we recently forced disabled this on lguest, and on the Xen side just to be sure Boris zeroed out the .bss for PV guests through commit 04b6b4a56884327c1648 ("xen/x86: Zero out .bss for PV guests"). With this care taken into consideration the paravirt_enabled() check is simply not needed anymore. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-9-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/apm_32.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 46504590321dc62a11065f8d00e1b12037c37018 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:37 2016 -0700 tools/lguest: Force disable tboot and APM The paravirt_enabled() check is going away, the area tossed to the kernel on lguest is not zeroed out, so ensure lguest force disables tboot and APM just in case the kernel file being read might have this set for whatever reason. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-8-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/lguest/lguest.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 1330e3bc544a1951d81b7f3c7d4cecf77d906f67 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:36 2016 -0700 x86/init: Use a platform legacy quirk for EBDA This replaces the paravirt_enabled() check with a proper x86 legacy platform quirk. As per 0-day, this bumps the vmlinux size using i386-tinyconfig as follows: TOTAL TEXT init.text x86_early_init_platform_quirks() +39 +35 +35 +25 That's a 4 byte total overhead, the rest is all cleared out upon init as its all __init text. v2: document 0-day vmlinux size impact Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-7-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/x86_init.h | 3 +++ arch/x86/kernel/head.c | 2 +- arch/x86/kernel/platform-quirks.c | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) commit 088a8ef8207f19aadbade0971af21ad89fdc3815 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:35 2016 -0700 x86/ACPI: Move ACPI_FADT_NO_CMOS_RTC check to ACPI boot code This moves the ACPI specific check into the ACPI boot code, it also takes advantage of the x86_platform.legacy.rtc which is checked for already on the RTC initialization code. This lets us remove the nasty #ifdefery and consolidate the checks to use only one toggle to disable the RTC init code. The works as RTC is initialized by device_initcall(add_rtc_cmos), this will run late in boot on start_kernel() during rest_init(), acpi_parse_fadt() gets called earlier during setup_arch(). Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-6-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/acpi/boot.c | 4 ++++ arch/x86/kernel/rtc.c | 8 -------- 2 files changed, 4 insertions(+), 8 deletions(-) commit 8d152e7a5c7537b18b4e9e0eb96f549b016636dc Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:34 2016 -0700 x86/rtc: Replace paravirt rtc check with platform legacy quirk We have 4 types of x86 platforms that disable RTC: * Intel MID * Lguest - uses paravirt * Xen dom-U - uses paravirt * x86 on legacy systems annotated with an ACPI legacy flag We can consolidate all of these into a platform specific legacy quirk set early in boot through i386_start_kernel() and through x86_64_start_reservations(). This deals with the RTC quirks which we can rely on through the hardware subarch, the ACPI check can be dealt with separately. For Xen things are bit more complex given that the @X86_SUBARCH_XEN x86_hardware_subarch is shared on for Xen which uses the PV path for both domU and dom0. Since the semantics for differentiating between the two are Xen specific we provide a platform helper to help override default legacy features -- x86_platform.set_legacy_features(). Use of this helper is highly discouraged, its only purpose should be to account for the lack of semantics available within your given x86_hardware_subarch. As per 0-day, this bumps the vmlinux size using i386-tinyconfig as follows: TOTAL TEXT init.text x86_early_init_platform_quirks() +70 +62 +62 +43 Only 8 bytes overhead total, as the main increase in size is all removed via __init. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Reviewed-by: Juergen Gross <jgross@suse.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-5-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Makefile | 1 + arch/x86/include/asm/paravirt.h | 6 ------ arch/x86/include/asm/paravirt_types.h | 5 ----- arch/x86/include/asm/processor.h | 1 - arch/x86/include/asm/x86_init.h | 21 +++++++++++++++++++++ arch/x86/kernel/Makefile | 6 +++++- arch/x86/kernel/head32.c | 2 ++ arch/x86/kernel/head64.c | 1 + arch/x86/kernel/platform-quirks.c | 21 +++++++++++++++++++++ arch/x86/kernel/rtc.c | 7 ++----- arch/x86/lguest/boot.c | 1 - arch/x86/xen/enlighten.c | 10 +++++++--- 12 files changed, 60 insertions(+), 22 deletions(-) commit 907bb655797427cc6498045d6977e77f8363fff7 Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:33 2016 -0700 tools/lguest: Make lguest launcher use X86_SUBARCH_LGUEST explicitly Be explicit and make use of X86_SUBARCH_LGUEST directly. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-4-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/lguest/lguest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ea1794812410e92c537c839bedeb2d2b2f87c80d Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:32 2016 -0700 x86/xen: Use X86_SUBARCH_XEN for PV guest boots The use of subarch should have no current effect on Xen PV guests, as such this should have no current functional effects. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Reviewed-by: David Vrabel <david.vrabel@citrix.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-3-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/xen/enlighten.c | 1 + 1 file changed, 1 insertion(+) commit 18c78a96239749fc4aaee84ca1eb5a8e81f2601d Author: Luis R. Rodriguez <mcgrof@kernel.org> Date: Wed Apr 13 17:04:31 2016 -0700 x86/boot: Enumerate documentation for the x86 hardware_subarch Although hardware_subarch has been in place since the x86 boot protocol 2.07 it hasn't been used much. Enumerate current possible values to avoid misuses and help with semantics later at boot time should this be used further. These enums should only ever be used by architecture x86 code, and all that code should be well contained and compartamentalized, clarify that as well. Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: andrew.cooper3@citrix.com Cc: andriy.shevchenko@linux.intel.com Cc: bigeasy@linutronix.de Cc: boris.ostrovsky@oracle.com Cc: david.vrabel@citrix.com Cc: ffainelli@freebox.fr Cc: george.dunlap@citrix.com Cc: glin@suse.com Cc: jgross@suse.com Cc: jlee@suse.com Cc: josh@joshtriplett.org Cc: julien.grall@linaro.org Cc: konrad.wilk@oracle.com Cc: kozerkov@parallels.com Cc: lenb@kernel.org Cc: lguest@lists.ozlabs.org Cc: linux-acpi@vger.kernel.org Cc: lv.zheng@intel.com Cc: matt@codeblueprint.co.uk Cc: mbizon@freebox.fr Cc: rjw@rjwysocki.net Cc: robert.moore@intel.com Cc: rusty@rustcorp.com.au Cc: tiwai@suse.de Cc: toshi.kani@hp.com Cc: xen-devel@lists.xensource.com Link: http://lkml.kernel.org/r/1460592286-300-2-git-send-email-mcgrof@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/uapi/asm/bootparam.h | 41 ++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) commit b2eafe890d4a09bfa63ab31ff018d7d6bb8cfefc Merge: abfb949 ea5dfb5 Author: Ingo Molnar <mingo@kernel.org> Date: Fri Apr 22 10:12:19 2016 +0200 Merge branch 'x86/urgent' into x86/asm, to fix semantic conflict 'cpu_has_pse' has changed to boot_cpu_has(X86_FEATURE_PSE), fix this up in the merge commit when merging the x86/urgent tree that includes the following commit: 103f6112f253 ("x86/mm/xen: Suppress hugetlbfs in PV guests") Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 0f8ede1b8c4cb845c53072d7e49d71ca24a61ced Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 13:55:46 2016 -0700 x86/KASLR: Warn when KASLR is disabled If KASLR is built in but not available at run-time (either due to the current conflict with hibernation, command-line request, or e820 parsing failures), announce the state explicitly. To support this, a new "warn" function is created, based on the existing "error" function. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1461185746-8017-6-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 6 +++--- arch/x86/boot/compressed/misc.c | 12 +++++++++--- arch/x86/boot/compressed/misc.h | 1 + 3 files changed, 13 insertions(+), 6 deletions(-) commit bf0118dbba9542ceb5d33d4a86830a6c88b0bbf6 Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 13:55:45 2016 -0700 x86/boot: Make memcpy() handle overlaps Two uses of memcpy() (screen scrolling and ELF parsing) were handling overlapping memory areas. While there were no explicitly noticed bugs here (yet), it is best to fix this so that the copying will always be safe. Instead of making a new memmove() function that might collide with other memmove() definitions in the decompressors, this just makes the compressed boot code's copy of memcpy() overlap-safe. Suggested-by: Lasse Collin <lasse.collin@tukaani.org> Reported-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1461185746-8017-5-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/misc.c | 4 +--- arch/x86/boot/compressed/string.c | 22 ++++++++++++++++++++-- 2 files changed, 21 insertions(+), 5 deletions(-) commit 1f208de37d10bb9067f3b061d281363be0cd1805 Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 13:55:44 2016 -0700 x86/boot: Clean up things used by decompressors This rearranges the pieces needed to include the decompressor code in misc.c. It wasn't obvious why things were there, so a comment was added and definitions consolidated. Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1461185746-8017-4-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/misc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e8581e3d67788b6b29d055fa42c6cb5b258fee64 Author: Baoquan He <bhe@redhat.com> Date: Wed Apr 20 13:55:43 2016 -0700 x86/KASLR: Drop CONFIG_RANDOMIZE_BASE_MAX_OFFSET Currently CONFIG_RANDOMIZE_BASE_MAX_OFFSET is used to limit the maximum offset for kernel randomization. This limit doesn't need to be a CONFIG since it is tied completely to KERNEL_IMAGE_SIZE, and will make no sense once physical and virtual offsets are randomized separately. This patch removes CONFIG_RANDOMIZE_BASE_MAX_OFFSET and consolidates the Kconfig help text. [kees: rewrote changelog, dropped KERNEL_IMAGE_SIZE_DEFAULT, rewrote help] Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1461185746-8017-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Kconfig | 72 ++++++++++++++---------------------- arch/x86/boot/compressed/kaslr.c | 12 +++--- arch/x86/include/asm/page_64_types.h | 8 ++-- arch/x86/mm/init_32.c | 3 -- 4 files changed, 36 insertions(+), 59 deletions(-) commit 4252db10559fc3d1efc1e43613254fdd220b014b Author: Baoquan He <bhe@redhat.com> Date: Wed Apr 20 13:55:42 2016 -0700 x86/KASLR: Update description for decompressor worst case size The comment that describes the analysis for the size of the decompressor code only took gzip into account (there are currently 6 other decompressors that could be used). The actual z_extract_offset calculation in code was already handling the correct maximum size, but this documentation hadn't been updated. This updates the documentation, fixes several typos, moves the comment to header.S, updates references, and adds a note at the end of the decompressor include list to remind us about updating the comment in the future. (Instead of moving the comment to mkpiggy.c, where the calculation is currently happening, it is being moved to header.S because the calculations in mkpiggy.c will be removed in favor of header.S calculations in a following patch, and it seemed like overkill to move the giant comment twice, especially when there's already reference to z_extract_offset in header.S.) Signed-off-by: Baoquan He <bhe@redhat.com> [ Rewrote changelog, cleaned up comment style, moved comments around. ] Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1461185746-8017-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 2 +- arch/x86/boot/compressed/misc.c | 89 ++++------------------------------------ arch/x86/boot/header.S | 88 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 97 insertions(+), 82 deletions(-) commit 2f024cef5b064d5498fe466dfe9492d46b5b12a4 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:39 2016 +0200 soc: renesas: rcar-sysc: Make rcar_sysc_power_is_off() static As of commit b12ff41658171f53 ("ARM: shmobile: r8a7779: Remove legacy PM Domain remainings"), rcar_sysc_power_is_off() is no longer used from SoC-specific code. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/rcar-sysc.c | 2 +- include/linux/soc/renesas/rcar-sysc.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) commit dcc09fd143bb97c2e83e443f7343c07aa0a9a6c0 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:38 2016 +0200 soc: renesas: rcar-sysc: Add DT support for SYSC PM domains Populate the SYSC PM domains from DT, based on the presence of a device node for the System Controller. The actual power area hiearchy, and features of specific areas are obtained from tables in the C code. The SYSCIER and SYSCIMR register values are derived from the power areas present, which will help to get rid of the hardcoded values in R-Car H1 and R-Car Gen2 platform code later. Initialization is done from an early_initcall(), to make sure the PM Domains are initialized before secondary CPU bringup. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/rcar-sysc.c | 202 +++++++++++++++++++++++++++++++++++++++- drivers/soc/renesas/rcar-sysc.h | 53 +++++++++++ 2 files changed, 254 insertions(+), 1 deletion(-) commit 68667cebfc0d27d2153d7a6b489f3231b533d9bc Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:37 2016 +0200 soc: renesas: rcar-sysc: Improve rcar_sysc_power() debug info Print requested power domain state. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/soc/renesas/rcar-sysc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit be32bcbbd18213803ff24e480340d4d2cca1df4f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 14:02:36 2016 +0200 soc: renesas: Move pm-rcar to drivers/soc/renesas/rcar-sysc Move the pm-rcar driver from arch/arm/mach-shmobile/ to drivers/soc/renesas/, and its header file to include/linux/soc/renesas/, so it can be shared between arm32 (R-Car H1 and Gen2) and arm64 (R-Car Gen3). Rename it to rcar-sysc as it's really a driver for the R-Car System Controller (SYSC). Kill the intermediate PM_RCAR config symbol, as it's not user configurable anymore, and to prepare for SoC-specific make rules. Add the missing #include <linux/types.h> to rcar-sysc.h, which was exposed by different include order. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> MAINTAINERS | 4 + arch/arm/mach-shmobile/Kconfig | 11 +-- arch/arm/mach-shmobile/Makefile | 1 - arch/arm/mach-shmobile/pm-r8a7779.c | 3 +- arch/arm/mach-shmobile/pm-rcar-gen2.c | 2 +- arch/arm/mach-shmobile/pm-rcar.c | 164 ---------------------------------- arch/arm/mach-shmobile/pm-rcar.h | 15 ---- arch/arm/mach-shmobile/smp-r8a7779.c | 2 +- arch/arm/mach-shmobile/smp-r8a7790.c | 2 +- drivers/soc/Makefile | 3 +- drivers/soc/renesas/Makefile | 5 ++ drivers/soc/renesas/rcar-sysc.c | 164 ++++++++++++++++++++++++++++++++++ include/linux/soc/renesas/rcar-sysc.h | 17 ++++ 13 files changed, 201 insertions(+), 192 deletions(-) commit a93fed0956bef9e4df420aa181198d86d347895d Merge: 839a04d 2066390 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Apr 22 17:22:21 2016 +1000 Merge tag 'clk-renesas-for-v4.7-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into rcar-sysc-for-v4.7 clk: renesas: R-Car SYSC PM Domain Preparation - Export the CPG/MSSR and CPG/MSTP attach/detach_dev callbacks, so they can be called by the R-Car SYSC PM Domain driver. commit 00fb16e26ac8559e69c3bb14284f4a548d28ee0d Author: Michal Hocko <mhocko@suse.com> Date: Wed Apr 13 11:57:12 2016 +0200 locking/rwsem, x86: Add frame annotation for call_rwsem_down_write_failed_killable() 3387a535ce62 ("x86/asm: Create stack frames in rwsem functions") has added FRAME_{BEGIN,END} annotations to rwsem asm stubs. The patch which has added call_rwsem_down_write_failed_killable() was based on an older tree so it didn't know about annotations. Let's add them. This addresses the following objtool warning: arch/x86/lib/rwsem.o: warning: objtool: call_rwsem_down_write_failed_killable()+0xe: call without frame pointer save/setup Reported-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-arch@vger.kernel.org Cc: linux-mm@kvack.org Link: http://lkml.kernel.org/r/1460541432-21631-1-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/lib/rwsem.S | 2 ++ 1 file changed, 2 insertions(+) commit 916633a403702549d37ea353e63a68e5b0dc27ad Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:31 2016 +0200 locking/rwsem: Provide down_write_killable() Now that all the architectures implement the necessary glue code we can introduce down_write_killable(). The only difference wrt. regular down_write() is that the slow path waits in TASK_KILLABLE state and the interruption by the fatal signal is reported as -EINTR to the caller. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-12-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/rwsem.h | 6 +++--- include/linux/lockdep.h | 15 +++++++++++++++ include/linux/rwsem.h | 1 + kernel/locking/rwsem.c | 19 +++++++++++++++++++ 4 files changed, 38 insertions(+), 3 deletions(-) commit 027b3f8ba9277410c3191d72d1ed2c6146d8a668 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:42 2016 +1000 drm/modes: stop handling framebuffer special Since ref counting is in the object now we can just call the normal interfaces. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) commit 2ddea3fd94889331855ff311ff540e0b182dd216 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:41 2016 +1000 drm/modes: reduce fb_lock to just protecting lists This reduces the fb_lock to just protecting the num_fb/fb_list. "Previously fb refcounting, and especially the weak reference (kref_get_unless_zero) used in fb lookups have been protected by fb_lock. But with the refactoring to share refcounting in the drm_mode_object base class that switched to being protected by idr_mutex, which means fb_lock critical sections can be reduced." Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit 72fe90b8e72e3f759164d2b4b5c60617a8a1a93e Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:40 2016 +1000 drm/modes: move reference taking into object lookup. When we lookup an ref counted object we now take a proper reference using kref_get_unless_zero. Framebuffer lookup no longer needs do this itself. Convert rmfb to using framebuffer lookup and deal with the fact it now gets an extra reference that we have to cleanup. This should mean we can avoid holding fb_lock across rmfb. (if I'm wrong let me know). We also now only hold the fbs_lock around the list manipulation. "Previously fb refcounting, and especially the weak reference (kref_get_unless_zero) used in fb lookups have been protected by fb_lock. But with the refactoring to share refcounting in the drm_mode_object base class that switched to being protected by idr_mutex, which means fb_lock critical sections can be reduced." Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 37 ++++++++++++++++++++----------------- 1 file changed, 20 insertions(+), 17 deletions(-) commit c7e1c59a18ef84df09c06bd484e4ee470f839f92 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:39 2016 +1000 drm/mode: reduce lock hold in addfb2 No need to hold the lock while assigning the variable. Daniel wrote: "Not sure why exactly I put that under the lock, but the only thing that can race here is rmfb while addfb2 is still doing it's thing, with a correctly guess (easy to do since they're fully deterministic) fb_id." Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 9cd47424fb410e478e5a97e83ac10263c13ed65c Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:38 2016 +1000 drm/mode: reduce scope of fb_lock in framebuffer init We don't need to hold the fb lock around the initialisation, only around the list manipulaton. So do the lock hold only around the register for now. From Daniel: Previously fb refcounting, and especially the weak reference (kref_get_unless_zero) used in fb lookups have been protected by fb_lock. But with the refactoring to share refcounting in the drm_mode_object base class that switched to being protected by idr_mutex, which means fb_lock critical sections can be reduced. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit cee26ac47dc2c2846ecd0fc80cf857942c1fcd77 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:37 2016 +1000 drm/mode: use _object_find to find framebuffers. No point have this code dupliated at this point, use the _object_find code instead now. Signed-off-by: Dave Airlie <airlied@redhat.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/drm_crtc.c | 35 ++++++++++------------------------- 1 file changed, 10 insertions(+), 25 deletions(-) commit d0f37cf62979e65558c1b7bd4d4c221c5281bae1 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:36 2016 +1000 drm/mode: move framebuffer reference into object. This is the initial code to add references to some mode objects. In the future we need to start reference counting connectors so firstly I want to reorganise the code so the framebuffer ref counting uses the same paths. This patch shouldn't change any functionality, just moves the kref. [airlied: move kerneldoc as well] Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 72 ++++++++++++++++++++++++---------------------- include/drm/drm_crtc.h | 32 ++++++++++++++++++--- 2 files changed, 66 insertions(+), 38 deletions(-) commit 747a598ffa7dff499ee93d414b74a08af6ec657e Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:35 2016 +1000 drm/mode: introduce wrapper to read framebuffer refcount. Avoids drivers knowing where the kref is stored. [airlied: add kerneldoc] Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 2 +- drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- drivers/gpu/drm/msm/msm_fb.c | 2 +- drivers/gpu/drm/tegra/drm.c | 2 +- include/drm/drm_crtc.h | 11 +++++++++++ 5 files changed, 16 insertions(+), 5 deletions(-) commit 54eeddbf92d0de297d78f7419dde00079d553dec Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Mar 31 11:21:27 2016 +0200 PM / Domains: Remove ->save|restore_state() callbacks As a part of the ongoing consolidation of genpd, it's become questionable whether clients actually needs to be able to assign their own set of ->save|restore_state() callbacks. Currently all users copes fine with the default callbacks, so let's remove the configuration option and stick to the default ones. This enables further clarifications of the related code and let's also rename pm_genpd_default_save|restore_state() into __genpd_runtime_suspend|resume() to apply the rule of static functionnames in genpd. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/domain.c | 113 +++++++++++++++++++------------------------- include/linux/pm_domain.h | 2 - 2 files changed, 49 insertions(+), 66 deletions(-) commit 795bd2e7e86967ced927948eff08fe8201ba5fc3 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Mar 31 11:21:26 2016 +0200 PM / Domains: Rename pm_genpd_runtime_suspend|resume() Follow genpd's rule for names of static functions, by renaming pm_genpd_runtime_suspend|resume() to genpd_runtime_suspend|resume(). Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/domain.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 9df3921e026532eb3bd2904745d990c0a9f0b4e4 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Thu Mar 31 11:21:25 2016 +0200 PM / Domains: Rename stop_ok to suspend_ok for the genpd governor The genpd governor validates the latency constraints to find out whether it's acceptable to runtime suspend a device. Earlier this validation was made to know whether it was okay to invoke the ->stop() callback for the device, hence the governor used the name "stop_ok" for the related variables. To clarify the code around this, let's rename these variables from "stop_ok" to "suspend_ok". Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/domain.c | 6 +++--- drivers/base/power/domain_governor.c | 20 ++++++++++---------- include/linux/pm_domain.h | 4 ++-- 3 files changed, 15 insertions(+), 15 deletions(-) commit 19ab3f8bb4edbc576d4a2cc94a80d0e28296b649 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:34 2016 +1000 drm/modes: drop __drm_framebuffer_unregister. Just use the generic function. The main side effect of this is that the fb->base.id is now protected by the idr mutex as well. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) commit f55f1f91f567ac32cbf04fbdd455fc54661504fb Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:33 2016 +1000 drm/mode: move framebuffer_free up above framebuffer_init A later patch will use it in framebuffer_init, and I want to keep the diff cleaner. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 58 +++++++++++++++++++++++----------------------- 1 file changed, 29 insertions(+), 29 deletions(-) commit 7c8f6d2577c7565f67ba3f6b9b76f7422710d66e Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 15 15:10:32 2016 +1000 drm/mode: rework drm_mode_object_put to drm_mode_object_unregister. This changes the code to handle being called multiple times without side effects. The new names seems more suitable for what it does. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/drm_crtc.c | 37 +++++++++++++++++++++---------------- drivers/gpu/drm/drm_crtc_internal.h | 4 ++-- drivers/gpu/drm/drm_modes.c | 2 +- 3 files changed, 24 insertions(+), 19 deletions(-) commit a03bd5735dfa87a5db585e162eda00794690c534 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Thu Apr 21 20:39:32 2016 +0900 arm64: defconfig: Add Renesas R-Car USB 3.0 driver support Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/configs/defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 350a73b4f896e620216d8e9429bbac16d89da8b0 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Apr 21 13:51:55 2016 +1000 PCI: rcar-pcie: Remove Gen2 designation from Kconfig It appears that Gen2 is a misnomer for the R-Car PCIE driver which also supports Gen 1 and Gen 3 SoCs. Accordingly, drop Gen 2 from the help text and Kconfig symbol. Also, re-arange the Kconfig symbol name to use PCIE as the prefix. This appears to be in keeping with other PCIE Kconfig symbols. Reported-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/configs/multi_v7_defconfig | 2 +- arch/arm/configs/shmobile_defconfig | 2 +- arch/arm64/configs/defconfig | 2 +- drivers/pci/host/Kconfig | 4 ++-- drivers/pci/host/Makefile | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) commit 372a12ed9d99c02f105278a9b75f0cb176d15cc1 Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Fri Apr 8 13:40:53 2016 +0200 PM / Runtime: Move ignore_children flag under CONFIG_PM The ignore_children flag is used only when CONFIG_PM is set, so let's move it into that section within the struct dev_pm_info. Move also the corresponding pm_suspend_ignore_children() API out of device.h into pm_runtime.h, to be consistent with similar APIs. Unfortunate this causes the Toshiba PCI SD mmc host driver to fail to compile as it needs pm_runtime.h, so let's fix this here as well. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/mmc/host/toshsd.c | 1 + include/linux/device.h | 5 ----- include/linux/pm.h | 2 +- include/linux/pm_runtime.h | 6 ++++++ 4 files changed, 8 insertions(+), 6 deletions(-) commit 9a297b36f4bb175ec23054a1182178977cde7859 Merge: 605b28c ebab87a Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 09:06:44 2016 +1000 Merge branch 'drm-atmel-hlcdc-devel' of https://github.com/bbrezillon/linux-at91 into drm-next This PR contains several improvement and cleanup patches for the atmel-hlcdc driver to be applied on drm-next (targeting 4.7). * 'drm-atmel-hlcdc-devel' of https://github.com/bbrezillon/linux-at91: drm: atmel-hlcdc: route DMA accesses through AHB interfaces drm: atmel-hlcdc: check display mode validity in crtc->mode_fixup() drm: atmel-hlcdc: rework the output code to support drm bridges drm: atmel-hlcdc: move output mode selection in CRTC implementation drm: atmel-hlcdc: support extended timing ranges on sama5d4 and sama5d2 drm: atmel-hlcdc: remove leftovers from atomic mode setting migration drm: atmel-hlcdc: fix connector and encoder types drm: atmel-hlcdc: support asynchronous atomic commit operations drm: atmel-hlcdc: add a ->cleanup_fb() operation commit 605b28c8598651d33cb63f40ac6759259d9c216d Merge: 4904796 ba3150a Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 09:03:31 2016 +1000 Merge tag 'drm-intel-next-2016-04-11' of git://anongit.freedesktop.org/drm-intel into drm-next - make modeset hw state checker atomic aware (Maarten) - close races in gpu stuck detection/seqno reading (Chris) - tons&tons of small improvements from Chris Wilson all over the gem code - more dsi/bxt work from Ramalingam&Jani - macro polish from Joonas - guc fw loading fixes (Arun&Dave) - vmap notifier (acked by Andrew) + i915 support by Chris Wilson - create bottom half for execlist irq processing (Chris Wilson) - vlv/chv pll cleanup (Ville) - rework DP detection, especially sink detection (Shubhangi Shrivastava) - make color manager support fully atomic (Maarten) - avoid livelock on chv in execlist irq handler (Chris) * tag 'drm-intel-next-2016-04-11' of git://anongit.freedesktop.org/drm-intel: (82 commits) drm/i915: Update DRIVER_DATE to 20160411 drm/i915: Avoid allocating a vmap arena for a single page drm,i915: Introduce drm_malloc_gfp() drm/i915/shrinker: Restrict vmap purge to objects with vmaps drm/i915: Refactor duplicate object vmap functions drm/i915: Consolidate common error handling in intel_pin_and_map_ringbuffer_obj drm/i915/dmabuf: Tighten struct_mutex for unmap_dma_buf drm/i915: implement WaClearTdlStateAckDirtyBits drm/i915/bxt: Reversed polarity of PORT_PLL_REF_SEL bit drm/i915: Rename hw state checker to hw state verifier. drm/i915: Move modeset state verifier calls. drm/i915: Make modeset state verifier take crtc as argument. drm/i915: Replace manual barrier() with READ_ONCE() in HWS accessor drm/i915: Use simplest form for flushing the single cacheline in the HWS drm/i915: Harden detection of missed interrupts drm/i915: Separate out the seqno-barrier from engine->get_seqno drm/i915: Remove forcewake dance from seqno/irq barrier on legacy gen6+ drm/i915: Fixup the free space logic in ring_prepare drm/i915: Simplify check for idleness in hangcheck drm/i915: Apply a mb between emitting the request and hangcheck ... commit 49047962ecf02d76bdaa378c00a51c9b829ac195 Merge: d57d477 bf16200 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 08:32:51 2016 +1000 Merge tag 'v4.6-rc3' into drm-next Backmerge 4.6-rc3 for i915. Linux 4.6-rc3 commit cc510c736b1b278a9925a4a051ecfa72ef8c21fc Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Jul 1 15:48:37 2015 +0200 clk: sunxi: Add TCON channel1 clock The TCON is a controller generating the timings to output videos signals, acting like both a CRTC and an encoder. It has two channels depending on the output, each channel being driven by its own clock (and own clock controller). Add a driver for the channel 1 clock. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Documentation/devicetree/bindings/clock/sunxi.txt | 1 + drivers/clk/sunxi/Makefile | 1 + drivers/clk/sunxi/clk-sun4i-tcon-ch1.c | 300 ++++++++++++++++++++++ 3 files changed, 302 insertions(+) commit fa4d0ca104bfdcda7b7e2bac855b358f302fd310 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:26 2016 +0100 clk: sunxi: Add PLL3 clock The A10 SoCs and relatives have a PLL controller to drive the PLL3 and PLL7, clocked from a 3MHz oscillator, that drives the display related clocks (GPU, display engine, TCON, etc.) Add a driver for it. Acked-by: Rob Herring <robh@kernel.org> Acked-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Documentation/devicetree/bindings/clock/sunxi.txt | 1 + drivers/clk/sunxi/Makefile | 1 + drivers/clk/sunxi/clk-sun4i-pll3.c | 98 +++++++++++++++++++++++ 3 files changed, 100 insertions(+) commit 7f2ea3847d47d49929d41573a3b26c80ddebbef5 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:28 2016 +0100 dt-bindings: clk: sun5i: add DRAM gates compatible The Allwinner SoCs have a gate controller to gate the access to the DRAM clock to the some devices that need to access the DRAM directly (mostly display / image related IPs). Use a simple gates driver to support the one found in the A13 / R8 SoCs. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Documentation/devicetree/bindings/clock/sunxi.txt | 1 + 1 file changed, 1 insertion(+) commit f4b9ef653c047165f096d32816904be5ee337a63 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Mon Apr 11 10:23:03 2016 +0530 clk: sunxi: Use resource_size Use the function resource_size instaed of explicit computation. Problem found using Coccinelle. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/clk/sunxi/clk-sun9i-mmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5ed400dd96d8222e667ee473c7ebd676f05113f8 Author: Jean-Francois Moine <moinejf@free.fr> Date: Wed Mar 30 18:43:29 2016 +0200 clk: sunxi: Add sun6i/8i display support Add the clock type which is used by the sun6i/8i families for video display. Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Documentation/devicetree/bindings/clock/sunxi.txt | 1 + drivers/clk/sunxi/clk-sunxi.c | 38 +++++++++++++++++++++++ 2 files changed, 39 insertions(+) commit 8f0767611a0ed719caf975d899d8431834ace2d8 Author: Andrea Venturi <ennesimamail.av@gmail.com> Date: Mon Mar 21 17:10:38 2016 +0100 clk: sunxi: mod1 clock should modify it's parent add CLK_SET_RATE_PARENT to modify the rate on clk upstream Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> drivers/clk/sunxi/clk-a10-mod1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 58657d189a2f626a568308f70a6b34255650c87e Merge: e9471c4 26ef56b Author: Stephen Boyd <sboyd@codeaurora.org> Date: Thu Apr 21 14:47:18 2016 -0700 Merge branch 'clk-hw-register' (early part) into clk-next * 'clk-hw-register' (early part): clk: fixed-rate: Add hw based registration APIs clk: gpio: Add hw based registration APIs clk: composite: Add hw based registration APIs clk: fractional-divider: Add hw based registration APIs clk: fixed-factor: Add hw based registration APIs clk: mux: Add hw based registration APIs clk: gate: Add hw based registration APIs clk: divider: Add hw based registration APIs clkdev: Add clk_hw based registration APIs clk: Add clk_hw OF clk providers clk: Add {devm_}clk_hw_{register,unregister}() APIs clkdev: Remove clk_register_clkdevs() commit e9471c4ecf8a50169216e7232e12b23761ce3d15 Merge: 624b5ea 92a39d9 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Thu Apr 21 14:43:56 2016 -0700 Merge branch 'clk-composite-unregister' into clk-next * clk-composite-unregister: clk: composite: Add unregister function commit 92a39d9043ba5ff98adb1c31491f00c7bea5466e Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:24 2016 +0100 clk: composite: Add unregister function The composite clock didn't have any unregistration function, which forced us to use clk_unregister directly on it. While it was already not great from an API point of view, it also meant that we were leaking the clk_composite structure allocated in clk_register_composite. Add a clk_unregister_composite function to fix this. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-composite.c | 15 +++++++++++++++ include/linux/clk-provider.h | 1 + 2 files changed, 16 insertions(+) commit 624b5ea624f368e8755304bc63a5ee5d0a899dcb Author: Neil Armstrong <narmstrong@baylibre.com> Date: Mon Apr 18 12:01:36 2016 +0200 dt-bindings: Add Oxford Semiconductor OXNAS Standard Clocks bindings Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../devicetree/bindings/clock/oxnas,stdclk.txt | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 0bbd72b4c64fc0803a6efd86ea151184bf553f97 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Mon Apr 18 12:01:35 2016 +0200 clk: Add Oxford Semiconductor OXNAS Standard Clocks Add Oxford Semiconductor OXNAS SoC Family Standard Clocks support. Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> [sboyd@codeaurora.org: Drop NULL/continue check in registration loop] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/Kconfig | 6 ++ drivers/clk/Makefile | 1 + drivers/clk/clk-oxnas.c | 195 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 202 insertions(+) commit 074c6a422d86fff76e05cf31be25e0eb752e1bd4 Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Apr 14 14:20:20 2016 +0800 soc: rockchip: power-domain: support qos save and restore support qos save and restore when power domain on/off. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 105 ++++++++++++++++++++++++++++++++++++-- 1 file changed, 102 insertions(+), 3 deletions(-) commit dcd36d01fb3f99d1d5df01714f6ccbe3fbbaf81f Merge: 5c14584 3b5f668 5dffed1 a54062c Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Apr 21 13:48:20 2016 -0700 Merge branches 'doc.2016.04.19a', 'exp.2016.03.31d', 'fixes.2016.03.31d' and 'torture.2016.04.21a' into HEAD doc.2016.04.19a: Documentation updates exp.2016.03.31d: Expedited grace-period updates fixes.2016.03.31d: Miscellaneous fixes torture.2016.004.21a Torture-test updates commit a54062c0d95921d4fb0edc8d268021bf387e6c75 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 30 14:16:22 2016 -0700 rcutorture: Add boot-time adjustment of leaf fanout Currently, the rcutorture scripts do not test boot-time adjustment of leaf fanout (via the rcutree.rcu_fanout_leaf boot parameter), as was noted during testing carried out by Iftekhar Ahmed of Oregon State University. This commit therefore adjusts TREE04's CONFIG_RCU_FANOUT_LEAF from 4 to 3, and also adds rcutree.rcu_fanout_leaf=4 to its boot parameters. This change forces RCU's boot-time geometry-change code to be exercised. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> tools/testing/selftests/rcutorture/configs/rcu/TREE04 | 2 +- tools/testing/selftests/rcutorture/configs/rcu/TREE04.boot | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 0aa67e75b3d59cfe412bfa54ca23797e6c2e3270 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 30 11:40:44 2016 -0700 rcutorture: Add irqs-disabled test for call_rcu() Mutation testing carried out by Iftekhar Ahmed of Oregon State University showed that rcutorture is failing to test invocations of call_rcu() having interrupts disabled. This commit therefore adds interrupt disabling around one of the existing invocations of call_rcu() (and friends). Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcutorture.c | 2 ++ 1 file changed, 2 insertions(+) commit e9fb365a8847dfe8a9fccae0dce77abf7276b5da Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 30 11:20:48 2016 -0700 rcutorture: Dump trace buffer upon shutdown When running from the scripts, rcutorture is completely headless, so there is no way to to manually dump the trace buffer. This commit therefore unconditionally dumps the trace buffer upon timed shutdown. However, if you are using rmmod to end the test, it is still up to you to manually dump the trace buffer. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/torture.c | 1 + 1 file changed, 1 insertion(+) commit acc1adf5572205c5b3fc9e6983ca8dfb06c94520 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 30 10:48:06 2016 -0700 rcutorture: Don't rebuild identical kernel Currently, if the user specifies multiple runs of a given test configuration, the scripting does multiple kernel builds. This wastes both time and disk space, so this commit makes the scripting use the first build for all runs of a given test configuration. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../selftests/rcutorture/bin/kvm-test-1-run.sh | 26 ++++++++++++++++------ 1 file changed, 19 insertions(+), 7 deletions(-) commit 6e524a603f0b72281019e4ec29b1022388f9f231 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 29 14:22:26 2016 -0700 rcutorture: Add OS-jitter capability This commit adds a --jitter OS-jitter capability to expose bugs based on no-delay assumptions. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> tools/testing/selftests/rcutorture/bin/jitter.sh | 90 ++++++++++++++++++++++++ tools/testing/selftests/rcutorture/bin/kvm.sh | 18 +++++ 2 files changed, 108 insertions(+) commit 702b07fcc9b264c9afd372676bbdd50a762dcde0 Author: Lukasz Anaczkowski <lukasz.anaczkowski@intel.com> Date: Thu Apr 21 11:29:00 2016 +0200 ACPI / SRAT: fix SRAT parsing order with both LAPIC and X2APIC present SRAT maps APIC ID to proximity domains ids (PXM). Mapping from PXM to NUMA node ids is based on order of entries in SRAT table. SRAT table has just LAPIC entires or mix of LAPIC and X2APIC entries. As long as there are only LAPIC entires, mapping from proximity domain id to NUMA node id is as assumed by BIOS. However, once APIC entries are mixed, X2APIC entries would be first mapped which causes unexpected NUMA node mapping. To fix that, change parsing to check each entry against both LAPIC and X2APIC so mapping is in the SRAT/PXM order. This is supplemental change to the fix made by commit d81056b5278 (Handle apic/x2apic entries in MADT in correct order) and using the mechanism introduced by 9b3fedd (ACPI / tables: Add acpi_subtable_proc to ACPI table parsers). Fixes: d81056b5278 (Handle apic/x2apic entries in MADT in correct order) Signed-off-by: Lukasz Anaczkowski <lukasz.anaczkowski@intel.com> [ rjw : Subject & changelog ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/numa.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit d57d47735ef5461952ef1dbdd515ebc0ffc5d2cc Merge: f230ffa 6dc3e22 Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 06:06:02 2016 +1000 Merge tag 'topic/drm-misc-2016-04-21' of git://anongit.freedesktop.org/drm-intel into drm-next misc pull req all over. Biggest thing is the drm_connector_(un)register_all cleanup from Alexey for drivers without the load/unload midlayer hooks. I.e. all the new ones, and a bunch of the pending new atomic drivers depend upon this. Or at least I asked them to rebase ;-) * tag 'topic/drm-misc-2016-04-21' of git://anongit.freedesktop.org/drm-intel: drm: Make drm.debug parameter description more helpful drm: Remove warning from drm_connector_unregister_all() drm: probe_helper: Hide ugly ifdef drm: rcar-du: Use generic drm_connector_register_all() helper drm: atmel_hldc: Use generic drm_connector_register_all() helper drm: Introduce drm_connector_register_all() helper drm: fix lut value extraction function drm/atomic-helper: Print an error if vblank wait times out drm/dp/mst: Restore primary hub guid on resume drm: Release driver references to handle before making it available again drm/i915/dp/mst: Add source port info to debugfs output drm/dp/mst: Enhance DP MST debugfs output drm/edid: Add drm_edid_get_monitor_name() include/drm: Reword debug categories comment. drm/crtc_helper: Reset empty plane state in drm_helper_crtc_mode_set_base() drm/virtio: Drop dummy gamma table support drm/bochs: Drop fake gamma support drm/core: Fix ordering in drm_mode_config_cleanup. commit f230ffa1cad66be6c8eb06a0dfe85551a202b4c3 Merge: f9fd2ad f74418a Author: Dave Airlie <airlied@redhat.com> Date: Fri Apr 22 05:58:31 2016 +1000 Merge tag 'topic/struct_mutex-2016-04-21' of git://anongit.freedesktop.org/drm-intel into drm-next struct_mutex cleanups and error paths fixes. Unfortunately I didn't manage to get acks from everyone, but this stuff has been hanging out for months now and imo simple enough to just land the remaining few patches. But separate pull request so that you can take a look yourself. * tag 'topic/struct_mutex-2016-04-21' of git://anongit.freedesktop.org/drm-intel: drm/vma_manage: Drop has_offset drm/vgem: Drop dev->struct_mutex drm/vgem: Move get_pages to gem_create drm/vgem: Simplify dumb_map drm/exynos: drop struct_mutex from fbdev setup drm/exynos: drop struct_mutex from exynos_drm_gem_get_ioctl drm/exynos: drop struct_mutex from exynos_gem_map_sgt_with_dma drm/exynos: Drop dev->struct_mutex from mmap offset function drm/nouveau: Drop dev->struct_mutex from fbdev init drm/qxl: Use unlocked gem unreferencing drm/omapdrm: Use unlocked gem unreferencing drm/nouveau: Use unlocked gem unreferencing commit 22d37b6b0058365a80378ee6198d21e7f6c86327 Merge: 7f348a6 681e683 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 21 15:36:04 2016 -0400 Merge branch 'geneve-vxlan-deps' Hannes Frederic Sowa says: ==================== net: network drivers should not depend on geneve/vxlan This patchset removes the dependency of network drivers on vxlan or geneve, so those don't get autoloaded when the nic driver is loaded. Also audited the code such that vxlan_get_rx_port and geneve_get_rx_port are not called without rtnl lock. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 681e683ff30ada19f73c17c38a528528dd8824f1 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:48 2016 +0200 geneve: break dependency with netdev drivers Equivalent to "vxlan: break dependency with netdev drivers", don't autoload geneve module in case the driver is loaded. Instead make the coupling weaker by using netdevice notifiers as proxy. Cc: Jesse Gross <jesse@kernel.org> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/geneve.c | 31 ++++++++++++++++++++++++++++--- include/linux/netdevice.h | 1 + include/net/geneve.h | 6 ++---- 3 files changed, 31 insertions(+), 7 deletions(-) commit b7aade15485a660cbf5161962c284131324a9534 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:47 2016 +0200 vxlan: break dependency with netdev drivers Currently all drivers depend and autoload the vxlan module because how vxlan_get_rx_port is linked into them. Remove this dependency: By using a new event type in the netdevice notifier call chain we proxy the request from the drivers to flush and resetup the vxlan ports not directly via function call but by the already existing netdevice notifier call chain. I added a separate new event type, NETDEV_OFFLOAD_PUSH_VXLAN, to do so. We don't need to save those ids, as the event type field is an unsigned long and using specialized event types for this purpose seemed to be a more elegant way. This also comes in beneficial if in future we want to add offloading knobs for vxlan. Cc: Jesse Gross <jesse@kernel.org> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 14 +++++++++----- include/linux/netdevice.h | 1 + include/net/vxlan.h | 6 ++---- 3 files changed, 12 insertions(+), 9 deletions(-) commit 50d65d78897ff9785b7debbdca0030967cd5772d Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:46 2016 +0200 qlcnic: protect qlicnic_attach_func with rtnl_lock qlcnic_attach_func requires rtnl_lock to be held. Cc: Dept-GELinuxNICDev@qlogic.com Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit b1f99a787e8239da3ea859709f5fb60b3fd02c13 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:45 2016 +0200 ixgbe: protect vxlan_get_rx_port in ixgbe_service_task with rtnl_lock vxlan_get_rx_port requires rtnl_lock to be held. Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Cc: Jesse Brandeburg <jesse.brandeburg@intel.com> Cc: Shannon Nelson <shannon.nelson@intel.com> Cc: Carolyn Wyborny <carolyn.wyborny@intel.com> Cc: Don Skidmore <donald.c.skidmore@intel.com> Cc: Bruce Allan <bruce.w.allan@intel.com> Cc: John Ronciak <john.ronciak@intel.com> Cc: Mitch Williams <mitch.a.williams@intel.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 ++ 1 file changed, 2 insertions(+) commit 0c5c3252c43cc935bef05c2211fc7cb32facddf7 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:44 2016 +0200 mlx4: protect mlx4_en_start_port in mlx4_en_restart with rtnl_lock mlx4_en_start_port requires rtnl_lock to be held. Cc: Eugenia Emantayev <eugenia@mellanox.com> Cc: Yishai Hadas <yishaih@mellanox.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 2 ++ 1 file changed, 2 insertions(+) commit 41419b9303f085e8912406140355e45230fed22f Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:43 2016 +0200 fm10k: protect fm10k_open in fm10k_io_resume with rtnl_lock fm10k_open requires rtnl_lock to be held. Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Cc: Jesse Brandeburg <jesse.brandeburg@intel.com> Cc: Shannon Nelson <shannon.nelson@intel.com> Cc: Carolyn Wyborny <carolyn.wyborny@intel.com> Cc: Don Skidmore <donald.c.skidmore@intel.com> Cc: Bruce Allan <bruce.w.allan@intel.com> Cc: John Ronciak <john.ronciak@intel.com> Cc: Mitch Williams <mitch.a.williams@intel.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 2 ++ 1 file changed, 2 insertions(+) commit 08d9910c3408531473766ec4d8b288e8ee2fe500 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Mon Apr 18 21:19:42 2016 +0200 benet: be_resume needs to protect be_open with rtnl_lock be_open calls down to functions which expects rtnl lock to be held. Cc: Sathya Perla <sathya.perla@broadcom.com> Cc: Ajit Khaparde <ajit.khaparde@broadcom.com> Cc: Padmanabh Ratnakar <padmanabh.ratnakar@broadcom.com> Cc: Sriharsha Basavapatna <sriharsha.basavapatna@broadcom.com> Cc: Somnath Kotur <somnath.kotur@broadcom.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/emulex/benet/be_main.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 961212e3fd1ee29d31f3c362f0bc854868679f63 Author: Sylvain Lemieux <slemieux@tycoint.com> Date: Wed Apr 20 09:21:00 2016 -0400 ARM: dts: lpc32xx: disabled ssp0/spi1 & ssp1/spi2 by default The SSP0/SPI1 and SSP1/SPI2 shared pinout and should be disable by default. Board specific dts should enable them, as needed. Signed-off-by: Sylvain Lemieux <slemieux@tycoint.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/lpc32xx.dtsi | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 9a96877c2b08865685bb80338db7254cf76af55f Author: Sylvain Lemieux <slemieux@tycoint.com> Date: Wed Apr 20 09:20:59 2016 -0400 ARM: dts: phy3250: enable ssp0 Preparatory change prior to disabling SSPx controllers by default in the shared LPC32xx DTSI file. Signed-off-by: Sylvain Lemieux <slemieux@tycoint.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/phy3250.dts | 1 + 1 file changed, 1 insertion(+) commit 73fdaa0f332fcf301327053cff7e523a85b0e7c7 Author: Sylvain Lemieux <slemieux@tycoint.com> Date: Wed Apr 20 09:20:58 2016 -0400 ARM: dts: lpc32xx: add clock properties to spi nodes The change adds clock properties to spi peripheral devices, clock ids are taken from dt-bindings/clock/lpc32xx-clock.h Signed-off-by: Sylvain Lemieux <slemieux@tycoint.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/lpc32xx.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 3b3c6ad5353951cd01523add5a1930c743d4f807 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 18 06:31:23 2016 +0300 ARM: LPC32xx: add PL175 memory controller driver to defconfig The change enables build of ARM PrimeCell PL17x driver for LPC32xx platform, the memory controller is commonly used to interface NOR flash drives. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/configs/lpc32xx_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit ae35557bb04b3429321ba05442c88c7633713bc6 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 18 06:31:22 2016 +0300 ARM: LPC32xx: defconfig update The change is a result of "make lpc32xx_defconfig; make savedefconfig" run, a number of config options are removed: CONFIG_BINFMT_AOUT=y -- not needed, legacy CONFIG_FPE_NWFPE=y -- not needed, AEABI build CONFIG_IPV6_PRIVACY=y -- removed build option CONFIG_IPV6=y -- selected by default CONFIG_MII=y -- not needed, board phys don't select library CONFIG_MTD_CHAR=y -- removed build option CONFIG_MTD_M25P80=y -- not needed, AT25 EEPROM driver is in use CONFIG_USB_PHY=y -- selected by default Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/configs/lpc32xx_defconfig | 27 +++++++++------------------ 1 file changed, 9 insertions(+), 18 deletions(-) commit 7f348a60762afd4cd0e4e7fa14cfa66331b7c30e Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed Apr 20 16:51:00 2016 -0400 net: Add support for IP ID mangling TSO in cases that require encapsulation This patch adds support for NETIF_F_TSO_MANGLEID if a given tunnel supports NETIF_F_TSO. This way if needed a device can then later enable the TSO with IP ID mangling and the tunnels on top of that device can then also make use of the IP ID mangling as well. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 1df845be658edfaa7ca6c09a43fea551cb0565b9 Merge: b8fd789 5498440 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 21 15:09:06 2016 -0400 Merge branch 'mlx5-next' Saeed Mahameed says: ==================== Mellanox 100G mlx5 driver receive path optimizations Changes from V2: - Rebased to 46e7b8d8d53b ("net: dsa: kill circular reference with slave priv") - Updated: ("net/mlx5e: Support RX multi-packet WQE (Striding RQ)") * Per Eric Dumazet comment we changed the driver memory handling scheme to work with order-0 pages rather than order-5 via split_page(). * This means that now a mlx5e rx skb can hold one or (more in case of HW LRO) skb frag each pointing to a 4K order-0 page rather than one frag with order-5 page. - Updated: ("net/mlx5e: Add fragmented memory support for RX multi packet WQE") * Code refactoring and code reuse due the split_page() mechanism, now the MPWQE and fragmented MPWQE handling almost look the same, and share most of the code. - In some cases we see 2%-3% packet rate degradation in comparison to the order-5 pages approach, due to split_page() cpu consumption, but still we do see 3%-10% improvement in comparison to the current linear SKB approach. - We do believe that now the driver memory scheme is significantly less vulnerable to the memory DOS attack Eric pointed at. Changes from V1: - Rebased to efde611b0afa ("Merge branch 'nfp-next'") - Dropped: ("net/mlx5: Refactor mlx5_core_mr to mkey") Already merged into 4.6 from rdma tree. - Dropped: ("net/mlx5_core: Add ConnectX-5 to list of supported devices") Will be pushed to net as we want it in 4.6 release. - Dropped: ("net/mlx5e: Change RX moderation period to be based on CQE") Will be pushed in a later series with full software based adaptive moderation. - Added: ("net/mlx5e: Delay skb->data access") Small trivial optimization. - Updated: ("net/mlx5e: Support RX multi-packet WQE (Striding RQ)") Changed Striding RQ defaults to: > NUM WQEs = 16 > Strides Per WQE = 1024 > Stride Size = 128 - Updated: ("net/mlx5e: Use napi_alloc_skb for RX SKB allocations") Consider the IP packet alignment already done in napi_alloc_skb. Changes from V0: - Fixed a typo in commit message reported by Sergei - Align SKB fragments truesize to stride size - Use skb_add_rx_frag and remove the use of SKB_TRUESIZE - Fix: # MTTs alignment on Power PC - Fix: Free original (unaligned) pointer of MTT array - Use dev_alloc_pages and dev_alloc_page - Extend the stats.buff_alloc_err counter - Reform the copying of packet header into skb linear data - Add compiler hints for conditional statements - Prefetch skd->data prior to copying packet header into it - Rework: mlx5e_complete_rx_fragmented_mpwqe - Handle SKB fragments before linear data - Dropped ("net/mlx5e: Prefetch next RX CQE") for now - Added a small patch that Adds ConnectX-5 devices to the list of supported devices - Rebased to 1cdba5505555 ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next") This series includes Some RX modifications and optimizations for the mlx5 Ethernet driver. From Rana, we have one patch that adds the support for Connectx-4 queue counters. From Tariq, several patches that are centralized around improving RX path message rate, CPU and Memory utilization, in each patch commit message you will find the performance improvements numbers related to that specific patch. In the 2nd patch we used a queue counter to report "out of buffer" dropped packet count, "Dropped packets due to lack of software resources" 3rd patch modifies the driver's to RSS default value to be spread along the close NUMA node cores only for better out of the box experience. In the 4th and 5th patches we utilized the use of RX multi-packet WQE (Striding RQ) for better memory utilization especially in case of hardware LRO is enabled and for better message rate for small packets. In the 6th and 7th patches we added a fallback mechanism to use fragmented memory when allocating large WQE strides fails, using UMR (User Memory Registration) and ICO (Internal Control Operations) SQs. In the 8th to 11th patches we did some small modification which show some small extra improvements. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 54984407564ef6b35488f52654f828c17b9d6fa8 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:19 2016 +0300 net/mlx5e: Add ethtool counter for RX buffer allocation failures Counts the number of RX buffer allocation failures and shows it in ethtool statistics. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 8 ++++++-- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 ++ drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 11 +++++++++-- 3 files changed, 17 insertions(+), 4 deletions(-) commit e20a0db30454a07f03f3a34a79e9f35881cfaa9d Author: Saeed Mahameed <saeedm@mellanox.com> Date: Wed Apr 20 22:02:18 2016 +0300 net/mlx5e: Delay skb->data access Move mlx5e_handle_csum and eth_type_trans to the end of mlx5e_build_rx_skb to gain some more time before accessing skb->data, to reduce cache misses. Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 1bfec31627bf9b351b93b8cef4520b90f48ca276 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:17 2016 +0300 net/mlx5e: Remove redundant barrier The bit-op operation one line before is an explicit barrier by itself. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c | 1 - 1 file changed, 1 deletion(-) commit c5adb96f6c4a22aceff2e8220612c5b9239ffeb2 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:16 2016 +0300 net/mlx5e: Use napi_alloc_skb for RX SKB allocations Instead of netdev_alloc_skb, we use the napi_alloc_skb function which is designated to allocate skbuff's for RX in a channel-specific NAPI instance, and implies the IP packet alignment. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 1 - drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 4 ++-- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 12 +++++------- 3 files changed, 7 insertions(+), 10 deletions(-) commit bc77b240b3c57236cdcc08d64ca390655d3a16ff Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:15 2016 +0300 net/mlx5e: Add fragmented memory support for RX multi packet WQE If the allocation of a linear (physically continuous) MPWQE fails, we allocate a fragmented MPWQE. This is implemented via device's UMR (User Memory Registration) which allows to register multiple memory fragments into ConnectX hardware as a continuous buffer. UMR registration is an asynchronous operation and is done via ICO SQs. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 84 ++++- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 64 +++- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 427 +++++++++++++++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 4 +- drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c | 3 + 5 files changed, 514 insertions(+), 68 deletions(-) commit d3c9bc2743dc95b273ed0e6a3394a71ca314813c Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:14 2016 +0300 net/mlx5e: Added ICO SQs Added ICO (Internal Control Operations) SQ per channel to be used for driver internal operations such as memory registration for fragmented memory and nop requests upon ifconfig up. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 7 ++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 135 ++++++++++++++++++---- drivers/net/ethernet/mellanox/mlx5/core/en_tx.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c | 55 +++++++++ 4 files changed, 174 insertions(+), 25 deletions(-) commit 461017cb006aa1b39b0f647ae0ee2d9d84eef05b Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:13 2016 +0300 net/mlx5e: Support RX multi-packet WQE (Striding RQ) Introduce the feature of multi-packet WQE (RX Work Queue Element) referred to as (MPWQE or Striding RQ), in which WQEs are larger and serve multiple packets each. Every WQE consists of many strides of the same size, every received packet is aligned to a beginning of a stride and is written to consecutive strides within a WQE. In the regular approach, each regular WQE is big enough to be capable of serving one received packet of any size up to MTU or 64K in case of device LRO is enabled, making it very wasteful when dealing with small packets or device LRO is enabled. For its flexibility, MPWQE allows a better memory utilization (implying improvements in CPU utilization and packet rate) as packets consume strides according to their size, preserving the rest of the WQE to be available for other packets. MPWQE default configuration: Num of WQEs = 16 Strides Per WQE = 2048 Stride Size = 64 byte The default WQEs memory footprint went from 1024*mtu (~1.5MB) to 16 * 2048 * 64 = 2MB per ring. However, HW LRO can now be supported at no additional cost in memory footprint, and hence we turn it on by default and get an even better performance. Performance tested on ConnectX4-Lx 50G. To isolate the feature under test, the numbers below were measured with HW LRO turned off. We verified that the performance just improves when LRO is turned back on. * Netperf single TCP stream: - BW raised by 10-15% for representative packet sizes: default, 64B, 1024B, 1478B, 65536B. * Netperf multi TCP stream: - No degradation, line rate reached. * Pktgen: packet rate raised by 2-10% for traffic of different message sizes: 64B, 128B, 256B, 1024B, and 1500B. * Pktgen: packet loss in bursts of small messages (64byte), single stream: - | num packets | packets loss before | packets loss after | 2K | ~ 1K | 0 | 8K | ~ 6K | 0 | 16K | ~13K | 0 | 32K | ~28K | 0 | 64K | ~57K | ~24K As expected as the driver can receive as many small packets (<=64B) as the number of total strides in the ring (default = 2048 * 16) vs. 1024 (default ring size regardless of packets size) before this feature. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Achiad Shochat <achiad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 77 ++++++++++- .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 15 +- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 109 +++++++++++---- drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 153 +++++++++++++++++++-- include/linux/mlx5/device.h | 39 +++++- 5 files changed, 349 insertions(+), 44 deletions(-) commit 2f48af128d9aa64dd4e8c6fe97491b0bde3681b2 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:12 2016 +0300 net/mlx5e: Use function pointers for RX data path handling In preparation for Striding RQ feature, which will need its own RX handlers. This patch does not change any functionality. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Achiad Shochat <achiad@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 33 ++++++---- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 + drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 74 ++++++++++++----------- 3 files changed, 62 insertions(+), 47 deletions(-) commit d8c9660dac6287490ef450bc892593f05d364531 Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:11 2016 +0300 net/mlx5e: Use only close NUMA node for default RSS Distribute default RSS table uniformly over the rings of the close NUMA node, instead of all available channels. This way we enforce the preference of close rings over far ones. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 3 ++- drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 15 +++++++++++++-- 3 files changed, 16 insertions(+), 4 deletions(-) commit 593cf33829adfd3d5c75d42879cc42afded1b626 Author: Rana Shahout <ranas@mellanox.com> Date: Wed Apr 20 22:02:10 2016 +0300 net/mlx5e: Allocate set of queue counters per netdev Connect all netdev RQs to this set of queue counters. Also, add an "rx_out_of_buffer" counter to ethtool, which indicates RX packet drops due to lack of receive buffers. Signed-off-by: Rana Shahout <ranas@mellanox.com> Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/en.h | 11 ++++++ .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 11 ++++++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 42 ++++++++++++++++++++-- 3 files changed, 62 insertions(+), 2 deletions(-) commit 237cd218099ce96edf2890a49aa191b38b84c2fc Author: Tariq Toukan <tariqt@mellanox.com> Date: Wed Apr 20 22:02:09 2016 +0300 net/mlx5: Introduce device queue counters A queue counter can collect several statistics for one or more hardware queues (QPs, RQs, etc ..) that the counter is attached to. For Ethernet it will provide an "out of buffer" counter which collects the number of all packets that are dropped due to lack of software buffers. Here we add device commands to alloc/query/dealloc queue counters. Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Rana Shahout <ranas@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlx5/core/qp.c | 68 ++++++++++++++++++++++++++++ include/linux/mlx5/qp.h | 6 +++ 2 files changed, 74 insertions(+) commit b8fd789afb293002b11086e6ae417b7c523d2bdc Merge: c57107c c82f47e Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 21 15:06:05 2016 -0400 Merge branch 'bcmsysport-napi-updates' Florian Fainelli says: ==================== net: bcmsysport: utilize newer NAPI APIs These two patches are very analoguous to what was already submitted for BCMGENET and switch the SYSTEMPORT driver to utilizing __napi_schedule_irqoff() and napi_complete_done for the RX NAPI context. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit c82f47efa021697722b1cfc84e48f72d45c9f5b2 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Apr 20 11:37:09 2016 -0700 net: bcmsysport: use napi_complete_done() By using napi_complete_done(), we allow fine tuning of /sys/class/net/ethX/gro_flush_timeout for higher GRO aggregation efficiency for a Gbit NIC. Check commit 24d2e4a50737 ("tg3: use napi_complete_done()") for details. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bcmsysport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ba90950c94713f294e8778e891eef4143183957c Author: Florian Fainelli <f.fainelli@gmail.com> Date: Wed Apr 20 11:37:08 2016 -0700 net: bcmsysport: use __napi_schedule_irqoff() Both bcm_sysport_tx_isr() and bcm_sysport_rx_isr() run in hard irq context, we do not need to block irq again. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bcmsysport.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c57107c7f59fe438f8c5bb0ce50af857505276b8 Merge: 732912d7 3d6b66c Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 21 14:22:14 2016 -0400 Merge branch 'nlattr_align' Nicolas Dichtel says: ==================== libnl: enhance API to ease 64bit alignment for attribute Here is a proposal to add more helpers in the libnetlink to manage 64-bit alignment issues. Note that this series was only tested on x86 by tweeking CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS and adding some traces. The first patch adds helpers for 64bit alignment and other patches use them. We could also add helpers for nla_put_u64() and its variants if needed. v1 -> v2: - remove patch #1 - split patch #2 (now #1 and #2) - add nla_need_padding_for_64bit() ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3d6b66c1d1a8d348928996ca333730f258fbb838 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Thu Apr 21 18:58:27 2016 +0200 ip6mr: align RTA_MFC_STATS on 64-bit Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6mr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a9a080422ef7b0c7e69925e4a1474ad93f0f0117 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Thu Apr 21 18:58:26 2016 +0200 ipmr: align RTA_MFC_STATS on 64-bit Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/rtnetlink.h | 1 + net/ipv4/ipmr.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) commit 58414d32a37e4c2f79da91aebc2d2365918a1562 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Thu Apr 21 18:58:25 2016 +0200 rtnl: use the new API to align IFLA_STATS* Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/rtnetlink.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) commit 089bf1a6a924b97a7e9f920bae6253a8ad581cf3 Author: Nicolas Dichtel <nicolas.dichtel@6wind.com> Date: Thu Apr 21 18:58:24 2016 +0200 libnl: add more helpers to align attributes on 64-bit Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 39 +++++++++++++++----- lib/nlattr.c | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 130 insertions(+), 8 deletions(-) commit 732912d727cd6deb3c1a05a8baa74b8ce8d510ac Author: Alexander Duyck <aduyck@mirantis.com> Date: Tue Apr 19 14:02:26 2016 -0400 veth: Update features to include all tunnel GSO types This patch adds support for the checksum enabled versions of UDP and GRE tunnels. With this change we should be able to send and receive GSO frames of these types over the veth pair without needing to segment the packets. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/veth.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit b1c20f0b97b4e565fa50cde1e6b44c2fd327a1e0 Author: Alexander Duyck <aduyck@mirantis.com> Date: Tue Apr 19 14:02:19 2016 -0400 netdev_features: Fold NETIF_F_ALL_TSO into NETIF_F_GSO_SOFTWARE This patch folds NETIF_F_ALL_TSO into the bitmask for NETIF_F_GSO_SOFTWARE. The idea is to avoid duplication of defines since the only difference between the two was the GSO_UDP bit. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdev_features.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 1ba64facae5739d91884f8f34f25fef1cb66d930 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Apr 19 17:30:56 2016 +0300 geneve: testing the wrong variable in geneve6_build_skb() We intended to test "err" and not "skb". Fixes: aed069df099c ('ip_tunnel_core: iptunnel_handle_offloads returns int and doesn't free skb') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/geneve.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f937572925d8d7beb5aca1cf180e8b9af623a903 Author: Peter Heise <mail@pheise.de> Date: Tue Apr 19 13:34:28 2016 +0200 NLA_BINARY misuse bug in HSR Removed .type field from NLA to do proper length checking. Reported by Daniel Borkmann and Julia Lawall. Signed-off-by: Peter Heise <peter.heise@airbus.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/hsr/hsr_netlink.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit b7de529c793c9131e58ddca37d49fd26866aa867 Author: Xin Long <lucien.xin@gmail.com> Date: Tue Apr 19 15:10:01 2016 +0800 net: use jiffies_to_msecs to replace EXPIRES_IN_MS in inet/sctp_diag EXPIRES_IN_MS macro comes from net/ipv4/inet_diag.c and dates back to before jiffies_to_msecs() has been introduced. Now we can remove it and use jiffies_to_msecs(). Suggested-by: Jakub Sitnicki <jkbs@redhat.com> Signed-off-by: Xin Long <lucien.xin@gmail.com> Acked-by: Jakub Sitnicki <jkbs@redhat.com> Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_diag.c | 12 ++++++------ net/sctp/sctp_diag.c | 6 ++---- 2 files changed, 8 insertions(+), 10 deletions(-) commit 85b67bcb7e4a23ced05e7020bf5843b9857f6881 Author: Alexei Starovoitov <ast@fb.com> Date: Mon Apr 18 20:11:50 2016 -0700 perf, bpf: minimize the size of perf_trace_() tracepoint handler move trace_call_bpf() into helper function to minimize the size of perf_trace_*() tracepoint handlers. text data bss dec hex filename 10541679 5526646 2945024 19013349 1221ee5 vmlinux_before 10509422 5526646 2945024 18981092 121a0e4 vmlinux_after It may seem that perf_fetch_caller_regs() can also be moved, but that is incorrect, since ip/sp will be wrong. bpf+tracepoint performance is not affected, since perf_swevent_put_recursion_context() is now inlined. export_symbol_gpl can also be dropped. No measurable change in normal perf tracepoints. Suggested-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/trace_events.h | 5 +++++ include/trace/perf.h | 13 +++---------- kernel/events/core.c | 20 +++++++++++++++++++- 3 files changed, 27 insertions(+), 11 deletions(-) commit c60c9840423f32117a5422511c53c39df0b4d1dd Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon Apr 18 18:24:04 2016 -0400 net: dsa: remove tag_protocol from dsa_switch Having the tag protocol in dsa_switch_driver for setup time and in dsa_switch_tree for runtime is enough. Remove dsa_switch's one. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/dsa.h | 5 ----- net/dsa/dsa.c | 5 ++--- 2 files changed, 2 insertions(+), 8 deletions(-) commit 0ae3aeefabbeef26294e7a349b51f1c761d46c9f Author: Ulf Hansson <ulf.hansson@linaro.org> Date: Fri Apr 8 13:10:23 2016 +0200 PM / Runtime: Fix error path in pm_runtime_force_resume() As pm_runtime_set_active() may fail because the device's parent isn't active, we can end up executing the ->runtime_resume() callback for the device when it isn't allowed. Fix this by invoking pm_runtime_set_active() before running the callback and let's also deal with the error code. Fixes: 37f204164dfb (PM: Add pm_runtime_suspend|resume_force functions) Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Cc: 3.15+ <stable@vger.kernel.org> # 3.15+ Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/base/power/runtime.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 80dbe9973afc6be722bb6dbc1a303f3a7aaa3e1f Author: Imre Deak <imre.deak@intel.com> Date: Tue Apr 19 13:00:36 2016 +0300 drm/i915/kbl: Don't WARN for expected secondary MISC IO power well request In commit 5f304c873634 ("drm/i915/kbl: Reset secondary power well requests left on by DMC/KVMR") I forgot about the fact that SKL==KBL most of the time and that a secondary MISC IO power well request left on by the DMC is "expected". Tune down the corresponding WARN to be a debug message. This was caught by CI suspend tests. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461060036-19043-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 921b1f52c942ad2da971c38f54a2045ec7cfe9cb Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 19 17:01:32 2016 +0100 arm64/dma-mapping: Remove default domain workaround With the IOMMU core now taking care of default domains for groups regardless of bus type, we can gleefully rip out this stop-gap, as slight recompense for having to expand the other one. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/dma-mapping.c | 52 +++++++-------------------------------------- 1 file changed, 8 insertions(+), 44 deletions(-) commit 226d89cbb242f3fbd3e93367dfd5138f524aae5c Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 19 17:01:31 2016 +0100 arm64/dma-mapping: Extend DMA ops workaround to PCI devices PCI devices now suffer the same hiccup as platform devices, in that they get their DMA ops configured before they have been added to their bus, and thus before we know whether they have successfully registered with an IOMMU or not. Until the necessary driver core changes to reorder calls during device creation have been worked out, extend our delayed notifier trick onto the PCI bus so as to avoid broken DMA ops once IOMMUs get plugged into the PCI code. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/dma-mapping.c | 4 ++++ 1 file changed, 4 insertions(+) commit fd6c50ee3af3935d8dfa38b0a81b2386fd915cfe Author: Joerg Roedel <jroedel@suse.de> Date: Thu Apr 21 18:24:02 2016 +0200 iommu/amd: Move get_device_id() and friends to beginning of file They will be needed there later. Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 108 +++++++++++++++++++++++----------------------- 1 file changed, 54 insertions(+), 54 deletions(-) commit 9ee35e4c6f42e792974872ee1ec4115718ce05bc Author: Joerg Roedel <jroedel@suse.de> Date: Thu Apr 21 18:21:31 2016 +0200 iommu/amd: Don't use IS_ERR_VALUE to check integer values Use the better 'var < 0' check. Fixes: 7aba6cb9ee9d ('iommu/amd: Make call-sites of get_device_id aware of its return value') Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 81151cfb6bfe69f1c5a52b795eb005226a322c9e Author: Philipp Zabel <p.zabel@pengutronix.de> Date: Wed Apr 20 10:59:58 2016 +0200 ASoC: hdmi-codec: Add ELD control ALSA doesn't know about all the different compressed audio formats, so there is no interface to let userspace enumerate the formats that are supported by the connected sink. Exporting the raw ELD bytes to userspace allows an application to select the appropriate audio format depending on the current capabilities of the connected HDMI sink device. Usually userspace then just pretends to ALSA that the data is in one of the raw 16-bit PCM audio formats and relies on the IEC controls to tell the sink how to interpret the data. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Reviewed-by: Jyri Sarha <jsarha@ti.com> Tested-by: Jyri Sarha <jsarha@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/hdmi-codec.c | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit c0133e3b0265341e7d62e150df18709af33c3a30 Author: Koro Chen <koro.chen@mediatek.com> Date: Wed Apr 20 10:59:56 2016 +0200 ASoC: mediatek: Add HDMI dai-links in the mt8173-rt5650-rt5676 machine driver This creates pcmC0D2p for the HDMI playback in the same card. Signed-off-by: Koro Chen <koro.chen@mediatek.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Mark Brown <broonie@kernel.org> .../bindings/sound/mt8173-rt5650-rt5676.txt | 5 ++-- sound/soc/mediatek/Kconfig | 1 + sound/soc/mediatek/mt8173-rt5650-rt5676.c | 27 ++++++++++++++++++++++ 3 files changed, 31 insertions(+), 2 deletions(-) commit 09305da97c7808b900985526aa9198233f32fb37 Author: Shreyas NC <shreyas.nc@intel.com> Date: Thu Apr 21 11:45:22 2016 +0530 ASoC: Intel: Skylake: Use UUID in binary format To avoid complex string manipulations with UUID in canonical form, use UUID in binary format. Signed-off-by: Shreyas NC <shreyas.nc@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/skylake/skl-sst-dsp.h | 2 +- sound/soc/intel/skylake/skl-sst.c | 9 ++++++--- sound/soc/intel/skylake/skl-topology.c | 6 ++---- sound/soc/intel/skylake/skl-topology.h | 2 +- sound/soc/intel/skylake/skl-tplg-interface.h | 2 +- 5 files changed, 11 insertions(+), 10 deletions(-) commit d349caeb05104ef01392abc6c7cfc8ab516c7be4 Author: PC Liao <pc.liao@mediatek.com> Date: Thu Apr 21 19:38:14 2016 +0800 ASoC: mediatek: Add second I2S on mt8173-rt5650 machine driver This patch adds second I2S connection to rt5650 codec for capture path on mt8173-rt5650 machine driver. Signed-off-by: PC Liao <pc.liao@mediatek.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/mt8173-rt5650.txt | 10 +++++ sound/soc/mediatek/mt8173-rt5650.c | 50 ++++++++++++++++++++-- 2 files changed, 57 insertions(+), 3 deletions(-) commit 8e42db1eaab6c2558dbc2e6c1428730df0a295f4 Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Thu Apr 21 14:04:14 2016 +0100 ASoC: arizona: Prefer lower FRATIO in pseudo-fractional mode When setting up an FLL in pseudo-fractional mode it is preferred to use a lower FRATIO if possible to give a higher reference clock frequency. This patch swaps the two loops in arizona_calc_fratio() so that lower FRATIOs are tried first. The decrementing loop is also changed to start from init_ratio because the original settings might already give a fractional value for N.K Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/arizona.c | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) commit 2dabf0c4d0348f6f0b1ce0e0efcbcedef6a72045 Merge: 10c9ead dc1b4c2 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 21 11:52:05 2016 -0400 Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 100GbE Intel Wired LAN Driver Updates 2016-04-20 This series contains updates to fm10k only. Jacob provides majority of the changes in this series, starting with the addition of helper functions to reduce code duplication and the amount of code indentation. Fixed the use or should we say abuse of the ethtool stats API, which could result in corrupt memory or misleading statistic output. Added the appropriate rtnl_lock() and rtnl_unlock() to avoid RCU warnings during AER events. Come to find out, the PTP/1588 support is not working with the current version of switch management software and possibly never worked, so just remove support for PTP/1588 for now. Fixed how error responses from the switch manager after a LPORT_MAP request are handled, originally which were silently being ignored. Fixed up code documentation to hopefully ease the code and comment comprehension. Fixed a possible NULL pointer dereference after a kcalloc(), where when writing a new default redirection table, and we needed to populate a new RSS table using ethtool_rxfh_indir_default(). We populate this table into a region of memory allocated using kcalloc() but never check it for NULL. Alex adds support for bulk transmit cleanup for fm10k, like he did for all of our other drivers. Ngai-Mint fixes a number of issues with the unicast and multicast address syncs. Where an issue would occur when the netdev is pre-configured to either multicast mode and is enabled for the first time. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 962f5143b30568bf67be97365d0616b0050ddaa5 Author: dawei.chien@mediatek.com <dawei.chien@mediatek.com> Date: Tue Mar 15 16:10:36 2016 +0800 arm64: dts: mt8173: Add thermal zone node. This adds thermal zone node to Mediatek MT8173 dtsi file. Signed-off-by: Dawei Chien <dawei.chien@mediatek.com> Acked-by: Eduardo Valentin <edubezval@gmail.com> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> arch/arm64/boot/dts/mediatek/mt8173.dtsi | 43 ++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit bb62bad623deb7952aef13fcbe065fde5d1f03e5 Author: Madhavan Srinivasan <maddy@linux.vnet.ibm.com> Date: Sat Feb 20 10:32:48 2016 +0530 tool/perf: Add sample_reg_mask to include all perf_regs Add sample_reg_mask array with pt_regs registers. This is needed for printing supported regs ( -I? option). Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com> Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/perf/arch/powerpc/util/Build | 1 + tools/perf/arch/powerpc/util/perf_regs.c | 49 ++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+) commit dc642e8388b63a9a221903584bb6b562e5055d0d Author: Anju T <anju@linux.vnet.ibm.com> Date: Sat Feb 20 10:32:47 2016 +0530 tools/perf: Map the ID values with register names Map ID values with corresponding register names. These names are then displayed when user issues perf record with the -I option followed by perf report/script with -D option. To test this patchset, Eg: $ perf record -I ls # record machine state at interrupt $ perf script -D # read the perf.data file Sample output obtained for this patch / output looks like as follows: 496768515470 0x1988 [0x188]: PERF_RECORD_SAMPLE(IP, 0x1): 4522/4522: 0xc0000000001e538c period: 1 addr: 0 ... intr regs: mask 0x7ffffffffff ABI 64-bit .... r0 0xc0000000001e5e34 .... r1 0xc000000fe733f9a0 .... r2 0xc000000001523100 .... r3 0xc000000ffaadeb60 .... r4 0xc000000003456800 .... r5 0x73a9b5e000 .... r6 0x1e000000 .... r7 0x0 .... r8 0x0 .... r9 0x0 .... r10 0x1 .... r11 0x0 .... r12 0x24022822 .... r13 0xc00000000feec180 .... r14 0x0 .... r15 0xc000001e4be18800 .... r16 0x0 .... r17 0xc000000ffaac5000 .... r18 0xc000000fe733f8a0 .... r19 0xc000000001523100 .... r20 0xc00000000009fd1c .... r21 0xc000000fcaa69000 .... r22 0xc0000000001e4968 .... r23 0xc000000001523100 .... r24 0xc000000fe733f850 .... r25 0xc000000fcaa69000 .... r26 0xc000000003b8fcf0 .... r27 0xfffffffffffffead .... r28 0x0 .... r29 0xc000000fcaa69000 .... r30 0x1 .... r31 0x0 .... nip 0xc0000000001dd320 .... msr 0x9000000000009032 .... orig_r3 0xc0000000001e538c .... ctr 0xc00000000009d550 .... link 0xc0000000001e5e34 .... xer 0x0 .... ccr 0x84022882 .... softe 0x0 .... trap 0xf01 .... dar 0x0 .... dsisr 0xf00040060000004 ... thread: :4522:4522 ...... dso: /root/.debug/.build-id/b0/ef11b1a1629e62ac9de75199117ee5ef9469e9 :4522 4522 496.768515: 1 cycles: c0000000001e538c .perf_event_context_sched_in (/boot/vmlinux) Signed-off-by: Anju T <anju@linux.vnet.ibm.com> Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> tools/perf/arch/powerpc/include/perf_regs.h | 69 +++++++++++++++++++++++++++++ tools/perf/config/Makefile | 5 +++ 2 files changed, 74 insertions(+) commit ed4a4ef85cf5b75231079501030db28dd59f920a Author: Anju T <anju@linux.vnet.ibm.com> Date: Sat Feb 20 10:32:46 2016 +0530 powerpc/perf: Add support for sampling interrupt register state The perf infrastructure uses a bit mask to find out valid registers to display. Define a register mask for supported registers defined in uapi/asm/perf_regs.h. The bit positions also correspond to register IDs which is used by perf infrastructure to fetch the register values. CONFIG_HAVE_PERF_REGS enables sampling of the interrupted machine state. Signed-off-by: Anju T <anju@linux.vnet.ibm.com> [mpe: Add license, use CONFIG_PPC64, fix 32-bit build] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/Kconfig | 1 + arch/powerpc/perf/Makefile | 2 +- arch/powerpc/perf/perf_regs.c | 104 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 106 insertions(+), 1 deletion(-) commit 1bfadabfebc671a6af0f5008b524b681ce757dec Author: Anju T <anju@linux.vnet.ibm.com> Date: Sat Feb 20 10:32:45 2016 +0530 powerpc/perf: Assign an id to each powerpc register The enum definition assigns an 'id' to each register in "struct pt_regs" of arch/powerpc. The order of these values in the enum definition are based on the order of members in pt_regs. Signed-off-by: Anju T <anju@linux.vnet.ibm.com> [mpe: Rename LNK to LINK, use _UAPI_ASM for include guards] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/uapi/asm/perf_regs.h | 50 +++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) commit 057b6d7e62ea4e6b1809e2946929d0d586cad142 Author: Hari Bathini <hbathini@linux.vnet.ibm.com> Date: Fri Apr 8 03:30:34 2016 +0530 powerpc/book3s64: Remove __end_handlers marker The __end_handlers marker was intended to mark down upto code that gets called from exception prologs. But that hasn't kept pace with code changes. Case in point, slb_miss_realmode being called from exception prolog code but isn't below __end_handlers marker. So, __end_handlers marker is as good as a comment but could be misleading at times if it isn't in sync with the code, as is the case now. So, let us avoid this confusion by having a better comment and removing __end_handlers marker altogether. Signed-off-by: Hari Bathini <hbathini@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/exceptions-64s.S | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 8ed8ab40047a570fdd8043a40c104a57248dd3fd Author: Hari Bathini <hbathini@linux.vnet.ibm.com> Date: Fri Apr 15 22:48:02 2016 +1000 powerpc/book3s64: Fix branching to OOL handlers in relocatable kernel Some of the interrupt vectors on 64-bit POWER server processors are only 32 bytes long (8 instructions), which is not enough for the full first-level interrupt handler. For these we need to branch to an out-of-line (OOL) handler. But when we are running a relocatable kernel, interrupt vectors till __end_interrupts marker are copied down to real address 0x100. So, branching to labels (ie. OOL handlers) outside this section must be handled differently (see LOAD_HANDLER()), considering relocatable kernel, which would need at least 4 instructions. However, branching from interrupt vector means that we corrupt the CFAR (come-from address register) on POWER7 and later processors as mentioned in commit 1707dd16. So, EXCEPTION_PROLOG_0 (6 instructions) that contains the part up to the point where the CFAR is saved in the PACA should be part of the short interrupt vectors before we branch out to OOL handlers. But as mentioned already, there are interrupt vectors on 64-bit POWER server processors that are only 32 bytes long (like vectors 0x4f00, 0x4f20, etc.), which cannot accomodate the above two cases at the same time owing to space constraint. Currently, in these interrupt vectors, we simply branch out to OOL handlers, without using LOAD_HANDLER(), which leaves us vulnerable when running a relocatable kernel (eg. kdump case). While this has been the case for sometime now and kdump is used widely, we were fortunate not to see any problems so far, for three reasons: 1. In almost all cases, production kernel (relocatable) is used for kdump as well, which would mean that crashed kernel's OOL handler would be at the same place where we end up branching to, from short interrupt vector of kdump kernel. 2. Also, OOL handler was unlikely the reason for crash in almost all the kdump scenarios, which meant we had a sane OOL handler from crashed kernel that we branched to. 3. On most 64-bit POWER server processors, page size is large enough that marking interrupt vector code as executable (see commit 429d2e83) leads to marking OOL handler code from crashed kernel, that sits right below interrupt vector code from kdump kernel, as executable as well. Let us fix this by moving the __end_interrupts marker down past OOL handlers to make sure that we also copy OOL handlers to real address 0x100 when running a relocatable kernel. This fix has been tested successfully in kdump scenario, on an LPAR with 4K page size by using different default/production kernel and kdump kernel. Also tested by manually corrupting the OOL handlers in the first kernel and then kdump'ing, and then causing the OOL handlers to fire - mpe. Fixes: c1fb6816fb1b ("powerpc: Add relocation on exception vector handlers") Cc: stable@vger.kernel.org Signed-off-by: Hari Bathini <hbathini@linux.vnet.ibm.com> Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/exceptions-64s.S | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) commit 02e0b7600f8350078f01328095c20dd715700921 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Thu Mar 17 14:29:24 2016 +0000 arm64: kvm: Add support for 16K pages Now that we can handle stage-2 page tables independent of the host page table levels, wire up the 16K page support. Cc: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_arm.h | 13 +++++++++++-- arch/arm64/kvm/Kconfig | 1 - 2 files changed, 11 insertions(+), 3 deletions(-) commit 9163ee23e72333e4712f7edd1a49aef06eae6304 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 17:01:21 2016 +0000 kvm-arm: Cleanup stage2 pgd handling Now that we don't have any fake page table levels for arm64, cleanup the common code to get rid of the dead code. Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/include/asm/kvm_mmu.h | 19 ------------------- arch/arm/kvm/arm.c | 2 +- arch/arm/kvm/mmu.c | 37 ++++++------------------------------- arch/arm64/include/asm/kvm_mmu.h | 18 ------------------ 4 files changed, 7 insertions(+), 69 deletions(-) commit da04fa04dc91e7dae79629f28804391cbcf6e604 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Wed Mar 23 12:22:33 2016 +0000 kvm: arm64: Get rid of fake page table levels On arm64, the hardware supports concatenation of upto 16 tables, at entry level for stage2 translations and we make use that whenever possible. This could lead to reduced number of translation levels than the normal (stage1 table) table. Also, since the IPA(40bit) is smaller than the some of the supported VA_BITS (e.g, 48bit), there could be different number of levels in stage-1 vs stage-2 tables. To reuse the kernel host page table walker for stage2 we have been using a fake software page table level, not known to the hardware. But with 16K translations, there could be upto 2 fake software levels (with 48bit VA and 40bit IPA), which complicates the code. Hence, we want to get rid of the hack. Now that we have explicit accessors for hyp vs stage2 page tables, define the stage2 walker helpers accordingly based on the actual table used by the hardware. Once we know the number of translation levels used by the hardware, it is merely a job of defining the helpers based on whether a particular level is folded or not, looking at the number of levels. Some facts before we calculate the translation levels: 1) Smallest page size supported by arm64 is 4K. 2) The minimum number of bits resolved at any page table level is (PAGE_SHIFT - 3) at intermediate levels. Both of them implies, minimum number of bits required for a level change is 9. Since we can concatenate upto 16 tables at stage2 entry, the total number of page table levels used by the hardware for resolving N bits is same as that for (N - 4) bits (with concatenation), as there cannot be a level in between (N, N-4) as per the above rules. Hence, we have STAGE2_PGTABLE_LEVELS = PGTABLE_LEVELS(KVM_PHYS_SHIFT - 4) With the current IPA limit (40bit), for all supported translations and VA_BITS, we have the following condition (even for 36bit VA with 16K page size): CONFIG_PGTABLE_LEVELS >= STAGE2_PGTABLE_LEVELS. So, for e.g, if PUD is present in stage2, it is present in the hyp(host). Hence, we fall back to the host definition if we find that a level is not folded. Otherwise we redefine it accordingly. A build time check is added to make sure the above condition holds. If this condition breaks in future, we can rearrange the host level helpers and fix our code easily. Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Christoffer Dall <christoffer.dall@linaro.org> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_mmu.h | 64 +------------- arch/arm64/include/asm/stage2_pgtable-nopmd.h | 42 +++++++++ arch/arm64/include/asm/stage2_pgtable-nopud.h | 39 ++++++++ arch/arm64/include/asm/stage2_pgtable.h | 122 +++++++++++++++++++------- 4 files changed, 172 insertions(+), 95 deletions(-) commit 8684e701df5a3f52e3ff580128cbd5d71fcd5f5c Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 17:14:25 2016 +0000 kvm-arm: Cleanup kvm_* wrappers Now that we have switched to explicit page table routines, get rid of the obsolete kvm_* wrappers. Also, kvm_tlb_flush_vmid_by_ipa is now called only on stage2 page tables, hence get rid of the redundant check. Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/include/asm/kvm_mmu.h | 16 ---------------- arch/arm/kvm/mmu.c | 9 +-------- arch/arm64/include/asm/kvm_mmu.h | 24 ------------------------ 3 files changed, 1 insertion(+), 48 deletions(-) commit 7a1c831ee8553b8199f21183942a46adf808f174 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Wed Mar 23 12:08:02 2016 +0000 kvm-arm: Add stage2 page table modifiers Now that the hyp page table is handled by different set of routines, rename the original shared routines to stage2 handlers. Also make explicit use of the stage2 page table helpers. unmap_range has been merged to existing unmap_stage2_range. Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/kvm/mmu.c | 97 +++++++++++++++++++++++++----------------------------- 1 file changed, 44 insertions(+), 53 deletions(-) commit 64f324979210d4064adf64f19da40c125c9dd137 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 18:56:21 2016 +0000 kvm-arm: Add explicit hyp page table modifiers We have common routines to modify hyp and stage2 page tables based on the 'kvm' parameter. For a smoother transition to using separate routines for each, duplicate the routines and modify the copy to work on hyp. Marks the forked routines with _hyp_ and gets rid of the kvm parameter which is no longer needed and is NULL for hyp. Also, gets rid of calls to kvm_tlb_flush_by_vmid_ipa() calls from the hyp versions. Uses explicit host page table accessors instead of the kvm_* page table helpers. Suggested-by: Christoffer Dall <christoffer.dall@linaro.org> Cc: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/kvm/mmu.c | 104 ++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 99 insertions(+), 5 deletions(-) commit 70fd19068573e449d47eb2daa69cf5db541ef4f5 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 18:33:45 2016 +0000 kvm-arm: Use explicit stage2 helper routines We have stage2 page table helpers for both arm and arm64. Switch to the stage2 helpers for routines that only deal with stage2 page table. Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/kvm/mmu.c | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) commit 66f877faf9cc23232f25b423758eaa167de1ad09 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 17:20:28 2016 +0000 kvm-arm: arm64: Introduce hyp page table empty checks Introduce hyp_pxx_table_empty helpers for checking whether a given table entry is empty. This will be used explicitly once we switch to explicit routines for hyp page table walk. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_mmu.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit c0ef6326dd393d84c9906240164e803536b5f3fc Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 14:16:52 2016 +0000 kvm-arm: arm64: Introduce stage2 page table helpers Introduce stage2 page table helpers for arm64. With the fake page table level still in place, the stage2 table has the same number of levels as that of the host (and hyp), so they all fallback to the host version. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_mmu.h | 29 +---------- arch/arm64/include/asm/stage2_pgtable.h | 86 +++++++++++++++++++++++++++++++++ 2 files changed, 88 insertions(+), 27 deletions(-) commit b1d030a73e9039dcdec951327e9ce9e8d682067f Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 17:15:55 2016 +0000 kvm-arm: arm: Introduce hyp page table empty checks Introduce hyp_pxx_table_empty helpers for checking whether a given table entry is empty. This will be used explicitly once we switch to explicit routines for hyp page table walk. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/include/asm/kvm_mmu.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit b1ae9a30f18d22e1ae544e4c37a032d018ebdac5 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 14:08:17 2016 +0000 kvm-arm: arm32: Introduce stage2 page table helpers Define the page table helpers for walking the stage2 pagetable for arm. Since both hyp and stage2 have the same number of levels, as that of the host we reuse the host helpers. The exceptions are the p.d_addr_end routines which have to deal with IPA > 32bit, hence we use the open coded version of their host helpers which supports 64bit. Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org> arch/arm/include/asm/kvm_mmu.h | 1 + arch/arm/include/asm/stage2_pgtable.h | 61 +++++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) commit 77b5665141a9a7e69d2f685ee2f2a3698fd27397 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 22 14:06:47 2016 +0000 kvm-arm: Remove kvm_pud_huge() Get rid of kvm_pud_huge() which falls back to pud_huge. Use pud_huge instead. Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/kvm/mmu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit bbb3b6b35087539e75792b46e07b7ce5282d0979 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 1 12:00:39 2016 +0000 kvm-arm: Replace kvm_pmd_huge with pmd_thp_or_huge Both arm and arm64 now provides a helper, pmd_thp_or_huge() to check if the given pmd represents a huge page. Use that instead of our own custom check. Suggested-by: Mark Rutland <mark.rutland@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/kvm/mmu.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit 0dbd3b18c63c81dec1a8c47667d89c54ade9b52a Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 15 10:46:34 2016 +0000 arm64: Introduce pmd_thp_or_huge Add a helper to determine if a given pmd represents a huge page either by hugetlb or thp, as we have for arm. This will be used by KVM MMU code. Suggested-by: Mark Rutland <mark.rutland@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Steve Capper <steve.capper@linaro.org> Cc: Will Deacon <will.deacon@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Will Deacon <will.deacon@arm.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/pgtable.h | 2 ++ 1 file changed, 2 insertions(+) commit 120f0779c3ed89c25ef1db943feac8ed73a0d7f9 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Mar 1 10:03:06 2016 +0000 kvm arm: Move fake PGD handling to arch specific files Rearrange the code for fake pgd handling, which is applicable only for arm64. This will later be removed once we introduce the stage2 page table walker macros. Reviewed-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm/include/asm/kvm_mmu.h | 11 ++++++++-- arch/arm/kvm/mmu.c | 47 ++++++---------------------------------- arch/arm64/include/asm/kvm_mmu.h | 43 ++++++++++++++++++++++++++++++++++++ 3 files changed, 59 insertions(+), 42 deletions(-) commit acd05010400215b281a9197a889bec3e67998654 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 4 11:53:52 2016 +0100 arm64: Cleanup VTCR_EL2 and VTTBR field values We share most of the bits for VTCR_EL2 for different page sizes, except for the TG0 value and the entry level value. This patch makes the definitions a bit more cleaner to reflect this fact. Also cleans up the VTTBR_X calculation. No functional changes. Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_arm.h | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) commit a563f7598198b8389e00451ef6f3f1c12efbfb99 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 4 11:43:15 2016 +0100 arm64: Reuse TCR field definitions for EL1 and EL2 TCR_EL1, TCR_EL2 and VTCR_EL2, all share some field positions (TG0, ORGN0, IRGN0 and SH0) and their corresponding value definitions. This patch makes the TCR_EL1 definitions reusable and uses them for TCR_EL2 and VTCR_EL2 fields. This also fixes a bug where we assume TG0 in {V}TCR_EL2 is 1bit field. Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Will Deacon <will.deacon@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> arch/arm64/include/asm/kvm_arm.h | 48 ++++++++++---------- arch/arm64/include/asm/pgtable-hwdef.h | 80 ++++++++++++++++++++++++++-------- 2 files changed, 88 insertions(+), 40 deletions(-) commit 06d05463ee337e85e42c6073b6f2f46fbfb05b96 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 18 23:59:31 2016 +0200 rtl8xxxu: hide unused tables The references to some arrays in the rtl8xxxu driver were moved inside of an #ifdef, but the symbols remain outside, resulting in build warnings: rtl8xxxu/rtl8xxxu.c:1506:33: error: 'rtl8188ru_radioa_1t_highpa_table' defined but not used rtl8xxxu/rtl8xxxu.c:1431:33: error: 'rtl8192cu_radioa_1t_init_table' defined but not used rtl8xxxu/rtl8xxxu.c:1407:33: error: 'rtl8192cu_radiob_2t_init_table' defined but not used rtl8xxxu/rtl8xxxu.c:1332:33: error: 'rtl8192cu_radioa_2t_init_table' defined but not used rtl8xxxu/rtl8xxxu.c:239:35: error: 'rtl8192c_power_base' defined but not used rtl8xxxu/rtl8xxxu.c:217:35: error: 'rtl8188r_power_base' defined but not used This adds an extra #ifdef around them to shut up the warnings. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 2fc0b8e5a17d ("rtl8xxxu: Add TX power base values for gen1 parts") Fixes: 4062b8ffec36 ("rtl8xxxu: Move PHY RF init into device specific functions") Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 4 ++++ 1 file changed, 4 insertions(+) commit 13a06ed55dba0ae3f983ef3c4ea70fc42066e1b5 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Wed Apr 20 11:39:12 2016 -0700 ASoC: tlv320aic32x4: Add additional input pins The input mixers support routing the IN1_R pin to the Left PGA and the IN2_L pin to the Right PGA. This patch allows for those routings. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic32x4.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 20d2cecbb7b9c35235c97f0dfa520525c28f8841 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Wed Apr 20 11:39:11 2016 -0700 ASoC: tlv320aic32x4: Implement resistors on input pins The input pins of the aic3204 have resistors inline with them. The current code assumes that you want a 10k resistor inline with your inputs and implements it as a simple switch. This patch creates an enum for each pin and allows you to switch between not connected, 10k, 20k and 40k ohm values. This more closely models the acutal aic3204 part. These pin settings are documented in TI's SLAA557 pages 135 and 136 (http://www.ti.com/lit/ml/slaa557/slaa557.pdf). Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic32x4.c | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) commit 7072276e6c0eed95b08e8f8d07456112970eac06 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon Apr 18 17:10:16 2016 +0200 s390/Kconfig: make z196 the default processor type The current default processor type is z900. The BPF jit compiler depends on PACK_STACK && HAVE_MARCH_Z196_FEATURES. To have the BPF jit code included in compiles with 'make allmodconfig' set the default processor type to z196. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 99d00a2bd3c4f24ef90960a563f6f190e81e4ed3 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Mon Apr 18 09:52:05 2016 +0200 s390/sclp: avoid compile warning in sclp_pci_report Fix the initialization of a local variable to remove this warning: All warnings (new ones prefixed by >>): drivers/s390/char/sclp_pci.c: In function 'sclp_pci_report': >> drivers/s390/char/sclp_pci.c:127:9: warning: missing braces around initializer [-Wmissing-braces] struct sclp_req req = {0}; ^ drivers/s390/char/sclp_pci.c:127:9: warning: (near initialization for 'req.list') [-Wmissing-braces] Fixes: 12283a4035691697 "s390/sclp: add error notification command" Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/sclp_pci.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 3f6813b9a5e0aaec162a10037c203771a1b2c110 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Fri Apr 1 15:42:15 2016 +0200 s390/fpu: allocate 'struct fpu' with the task_struct Analog to git commit 0c8c0f03e3a292e031596484275c14cf39c0ab7a "x86/fpu, sched: Dynamically allocate 'struct fpu'" move the struct fpu to the end of the struct thread_struct, set CONFIG_ARCH_WANTS_DYNAMIC_TASK_STRUCT and add the setup_task_size() function to calculate the correct size fo the task struct. For the performance_defconfig this increases the size of struct task_struct from 7424 bytes to 7936 bytes (MACHINE_HAS_VX==1) or 7552 bytes (MACHINE_HAS_VX==0). The dynamic allocation of the struct fpu is removed. The slab cache uses an 8KB block for the task struct in all cases, there is enough room for the struct fpu. For MACHINE_HAS_VX==1 each task now needs 512 bytes less memory. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/Kconfig | 1 + arch/s390/include/asm/fpu/types.h | 10 ++++++---- arch/s390/include/asm/processor.h | 9 ++++++--- arch/s390/kernel/process.c | 23 ++--------------------- arch/s390/kernel/setup.c | 17 +++++++++++++++++ 5 files changed, 32 insertions(+), 28 deletions(-) commit 6dc3e22ee197095eb6a6b3119f04f9dc6c2bbf91 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Wed Apr 20 13:45:03 2016 -0300 drm: Make drm.debug parameter description more helpful Let's be user-friendly and print an actually helpful parameter description. This makes modinfo output the debug parameter like this: parm: debug:Enable debug output, where each bit enables a debug category. Bit 0 (0x01) will enable CORE messages (drm core code) Bit 1 (0x02) will enable DRIVER messages (drm controller code) Bit 2 (0x04) will enable KMS messages (modesetting code) Bit 3 (0x08) will enable PRIME messages (prime code) Bit 4 (0x10) will enable ATOMIC messages (atomic code) Bit 5 (0x20) will enable VBL messages (vblank code) (int) Changes from v1: * Fixed s/PRMIE/PRIME typo. * Add ATOMIC and VBL debug parameter documentation. * Prefix the continuation lines with two tabs and removed the last new line. * Remove spurious whitespace. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461170703-11216-1-git-send-email-ezequiel@vanguardiasur.com.ar drivers/gpu/drm/drm_drv.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 3024f920eb5f6e60453d035f26ec963c7126f517 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: zynq: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Michal Simek <michal.simek@xilinx.com> Cc: Sören Brinkmann <soren.brinkmann@xilinx.com> Cc: linux-gpio@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/core.c | 2 +- drivers/pinctrl/pinctrl-zynq.c | 12 +----------- 2 files changed, 2 insertions(+), 12 deletions(-) commit 6ac47fd25a0b83fcea203308a319cb6e98091af1 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: u300: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-u300.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit 265559f7ca7b8b4518c31ece4236e75e32d00bec Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: tz1090 Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-tz1090.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit 00b881b07dee87746dc1363ed9fee96f5b2af8d9 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: tz1090-pdc: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-tz1090-pdc.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit c3a6d9e0a37df77079f55c48901487fa9e731647 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: tb10x: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-tb10x.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit e8e2cb234f55355a75a48eab6ef4a26dfe05558d Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: st: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Srinivas Kandagatla <srinivas.kandagatla@gmail.com> Cc: Maxime Coquelin <maxime.coquelin@st.com> Cc: Patrice Chotard <patrice.chotard@st.com> Cc: kernel@stlinux.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-st.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0085a2b47b5f65cadc2d4146be30c6074fb21b0c Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: rockchip: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Heiko Stuebner <heiko@sntech.de> Cc: linux-rockchip@lists.infradead.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-rockchip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 082ec9063749bd58f557196249eb4b87120ee4a6 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: pistachio: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-pistachio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a0f16cc30e47b878c746f601f415407255420cc5 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: pic32: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Joshua Henderson <joshua.henderson@microchip.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-pic32.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5039d27203aac887fa7bf0110e68aa6581c5a902 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: palmas: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-palmas.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 19ba900bd28422e8a986e3fc2c5dda0a2054315a Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: lpc18xx: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Joachim Eastwood <manabian@gmail.com> Acked-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-lpc18xx.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 280132d19841731964ac33a2d1b5742e1921f500 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: lantiq: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: John Crispin <blogic@openwrt.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-lantiq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f91ed4780d4870c7e442ae37c402864e9370632 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:33:21 2016 +0530 pinctrl: digicolor: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-digicolor.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit 5c67425a46738b6193af28371af6d2ba42e8550c Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:32:19 2016 +0530 pinctrl: at91: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-at91.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit 5d3fc884b2616d0b0b5db4dbd83e9f3bae5d6d3f Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: at91-pio4: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-at91-pio4.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 4d106c2282804e7247e97314d97f8ec5d2d66dab Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: as3722: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-as3722.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 251e22abde21833b3d29577e4d8c7aaccd650eee Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: amd: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-amd.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 12ba40821ad0fd3c202efdb31b0be9b5872cef1c Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: adi2: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove the need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-adi2.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit f3abcb66b55ff30b976f7fd48c84fd3922d95d55 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: vt8500: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Lee Jones <lee.jones@linaro.org> Cc: Heiko Stuebner <heiko@sntech.de> Cc: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Hongzhou Yang <hongzhou.yang@mediatek.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/vt8500/pinctrl-wmt.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 14ba00316543bb67c81202fd475b605bfa410967 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Apr 21 01:21:14 2016 +0300 drm: Remove warning from drm_connector_unregister_all() Commit 6c87e5c3ec6d ("drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all()") replaced a manual connectors list walk in drm_connector_unregister_all() with drm_for_each_connector(). The list was walked without the mode config mutex locked as that ends up in a clash with sysfs, but drm_connector_unregister_all() warns when the mutex isn't locked. The problem is known and doesn't require a large warning every time drm_connector_unregister_all() is called. Fix it by reverting to manual list walk. Fixes: 6c87e5c3ec6d ("drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all()") Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461190874-32674-1-git-send-email-laurent.pinchart+renesas@ideasonboard.com drivers/gpu/drm/drm_crtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc1b4c2b88b976a7882922e55666b20e28477c57 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Apr 7 08:52:53 2016 -0700 fm10k: fix incorrect IPv6 extended header checksum Check for and handle IPv6 extended headers so that Tx checksum offload can be done. Also use skb_checksum_help for unexpected cases. This was originally discovered in ixgbe. Reported-by: Mark Rustad <mark.d.rustad@intel.com> Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) commit 86641094678a90af278d1f44c0e47f817c9ba46e Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Apr 7 08:21:21 2016 -0700 fm10k: consistently use Intel(R) for driver names Update every header file and other locations to consistently use Intel(R) instead of just Intel. Also update copyright year of files which we modified. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/Makefile | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k.h | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_common.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_common.h | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_dcbnl.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_debugfs.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_iov.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_main.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_mbx.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_mbx.h | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_netdev.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_pf.h | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_tlv.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_tlv.h | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_type.h | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_vf.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_vf.h | 2 +- 20 files changed, 30 insertions(+), 30 deletions(-) commit 540a5d859010a239a99aba02a9fed7b255c0033e Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Apr 7 08:21:20 2016 -0700 fm10k: fix possible null pointer deref after kcalloc When writing a new default redirection table, we needed to populate a new RSS table using ethtool_rxfh_indir_default. We populated this table into a region of memory allocated using kcalloc, but never checked this for NULL. Fix this by moving the default table generation into fm10k_write_reta. If this function is passed a table, use it. Otherwise, generate the default table using ethtool_rxfh_indir_default, 4 at at time. Fixes: 0ea7fae44094 ("fm10k: use ethtool_rxfh_indir_default for default redirection table") Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 26 ++++++++++++++++++------ drivers/net/ethernet/intel/fm10k/fm10k_main.c | 14 ++----------- 2 files changed, 22 insertions(+), 18 deletions(-) commit 11ec36a974f59c99e8a4ff7040026569a43ab567 Author: Ngai-Mint Kwan <ngai-mint.kwan@intel.com> Date: Fri Apr 1 16:17:39 2016 -0700 fm10k: Reset multicast mode when deleting lport Deleting lport when multicast mode is configured to FM10K_XCAST_MODE_ALLMULTI or FM10K_XCAST_MODE_PROMISC will result in generating orphaned multicast-group entries in the switch manager. Before deleting the lport, reset multicast mode to FM10K_XCAST_MODE_NONE to flush out these multicast-group entries. Signed-off-by: Ngai-Mint Kwan <ngai-mint.kwan@intel.com> Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 4 ++++ 1 file changed, 4 insertions(+) commit fb6515c8f03bbfdc99cff156becd5e14df1dd601 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:38 2016 -0700 fm10k: update comment regarding reserved bits check The original comment may be read incorrectly as referring to checking the *entire* length is zero. However, it merely checks only the reserved bits of both length and reserved in a small amount of code. Update the comment to indicate this is a clever trick and clearly spell out that it only checks the reserve bits. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_vf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5c69df8a33408c82ac633c521be0acf71a690d43 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:37 2016 -0700 fm10k: use different name than FM10K_VLAN_CLEAR for override bit Use a new #define FM10K_VLAN_OVERRIDE even though we're using the exact same bit. The reason for this is clarity in the code, otherwise you can read FM10K_VLAN_CLEAR and think it should be removed. Also add a comment explaining why the FM10K_VLAN_OVERRIDE bit is set. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 8 ++++++-- drivers/net/ethernet/intel/fm10k/fm10k_type.h | 1 + drivers/net/ethernet/intel/fm10k/fm10k_vf.c | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) commit d057d9a9446636293b4884d1a0da6ad5a7ef4e13 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:36 2016 -0700 fm10k: use 8bit notation instead of 10bit notation for diagram The diagram represents bit layout of the multi-bit VLAN update message format. Typically these diagrams are drawn using some power of 2 as the base, to more easily grasp where fields split. Although the numbers above can make it somewhat easy to understand which bit you're looking at, it makes the break points not line up. Re-draw the numbers using base 8, and mark the bit values every 8 bits at the top. This should make it more easy to grasp the table quickly. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4e160f2a59cec8f705583edfaa11ce5f3b3ef4a6 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:35 2016 -0700 fm10k: fix documentation of fm10k_tlv_parse_attr fm10k_tlv_parse_attr is supposed to return FM10K_NOT_IMPLEMENTED for any TLV who's attribute id lies outside the range of results. It does not do this today. In addition, the documentation does not indicate that other attributes which are not implemented for a given TLV will be silently ignored. Fix this. Clean up the logic so that we don't rely on the fact that FM10K_NOT_IMPLEMENTED is greater than zero, as this can easily cause confusion. A future extension could look into some way of reporting unknown TLVs in order to make issues more easily discoverable. We can't just return FM10K_NOT_IMPLEMENTED here because we don't want to drop the entire message if it has an unknown TLV. While here, update the copyright year. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_tlv.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 3417415c3a86d6bae8bfee495ce634f4d24e16b8 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:34 2016 -0700 fm10k: do not disable PCI device in fm10k_io_error_detected fm10k_io_error_detected() does not need to call pci_disable_device(). In the cases where the reset needs to occur, the stack flow will result in calling fm10k_remove() which already disables the PCI device. If we leave the pci_disable_device(), we result in a warning about disabling an already disabled device. Many PCI drivers do call pci_disable_device() in their .error_detected() routines, but it does not appear to be required. In addition, these drivers have a check "is_pci_enabled()" call in their remove routines, which is how they chose to handle the duplicate device disable. This seems incorrect, since the PCI device structure is reference counted. It is very possible that the reference count for the PCI device could be greater than 1. In this case, you would remove the PCI device within the error_detected routine, reducing count to 1, then remove it again in the remove function, reducing it to zero. This would result in yet another disable somewhere else failing. Thus, we shouldn't be using is_pci_enabled() to check for this issue. Instead, just remove the extraneous pci_device_disable() found within the error_detected routine. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 2 -- 1 file changed, 2 deletions(-) commit a7a7783adabc3cc7599f7dbf97fcc3b0d44087b7 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:33 2016 -0700 fm10k: correctly handle LPORT_MAP error Currently, any error responses from the switch manager after an LPORT_MAP request are silently ignored. At most the mailbox message will be reported as an error. This can result in unexpected behavior when the switch manager has configured a port with zero bandwidth. Add support for reading the fm10k_swapi_error structure from LPORT_MAP responses. If the message contains the necessary TLV and has a non-zero error code, report link down, clear the dglort_map, and delay the next get_host_state call by a reasonable delay. Also log an error message indicating that the LPORT_MAP request failed. The delay ensures preventing an interrupt storm on the switch manager, and reduces the number of mailbox messages we send in this scenario drastically. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k.h | 1 + drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 31 +++++++++++++++++++++++++++- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 2 ++ drivers/net/ethernet/intel/fm10k/fm10k_pf.h | 2 ++ 4 files changed, 35 insertions(+), 1 deletion(-) commit 8998763a7b57583ef2e07f68ea6a7d05bcfc1cfa Author: Ngai-Mint Kwan <ngai-mint.kwan@intel.com> Date: Fri Apr 1 16:17:32 2016 -0700 fm10k: Fix multicast mode sync issues Multicast mode checking is no longer a requirement to perform unicast and multicast address syncs. Specifically, a device operating in promiscuous and/or all multicast mode is not excluded. The issue occurs when the netdev is pre-configured to either multicast mode and is enabled for the first time. The multicast-group table in the Switch Manager will be missing obvious multicast entries associated to this netdev. Changes were also made to disallow unicast and multicast syncs with VLAN 0. The Switch Manager considers VLAN 0 to be an invalid entry. Requests with VLAN 0 by the netdev are only generated when the driver is freshly installed and the default VID is not set. Signed-off-by: Ngai-Mint Kwan <ngai-mint.kwan@intel.com> Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_netdev.c | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) commit 9de6a1a6b8ed889ecd3ae13bb0a2459485d90a24 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 16:17:31 2016 -0700 fm10k: drop 1588 support The 1588 support within fm10k does not work correctly with the current version of the switch management software, and likely never worked correctly to begin with. Remove support for PTP/1588. Update copyright year for all these files while we're touching them. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/Makefile | 3 +- drivers/net/ethernet/intel/fm10k/fm10k.h | 34 +- drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 30 +- drivers/net/ethernet/intel/fm10k/fm10k_main.c | 22 +- drivers/net/ethernet/intel/fm10k/fm10k_netdev.c | 22 +- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 110 +----- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 101 +---- drivers/net/ethernet/intel/fm10k/fm10k_pf.h | 17 +- drivers/net/ethernet/intel/fm10k/fm10k_ptp.c | 462 ----------------------- drivers/net/ethernet/intel/fm10k/fm10k_type.h | 17 +- drivers/net/ethernet/intel/fm10k/fm10k_vf.c | 57 +-- drivers/net/ethernet/intel/fm10k/fm10k_vf.h | 12 +- 12 files changed, 11 insertions(+), 876 deletions(-) commit 1e4c32f3ede19bdb738aec2cc3cf69439d7b9310 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Mar 11 09:52:32 2016 -0800 fm10k: prevent RCU issues during AER events During an AER action response, we were calling fm10k_close without holding the rtnl_lock() which could lead to possible RCU warnings being produced due to 64bit stat updates among other causes. Similarly, we need rtnl_lock() around fm10k_open during fm10k_io_resume. Follow the same pattern elsewhere in the driver and protect the entire open/close sequence. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 2d0f76bedbddaacc465c7a3ebdc9f8c13f68d931 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Mar 9 16:36:08 2016 -0800 fm10k: use DRV_SUMMARY to reduce code duplication Use DRV_SUMMARY, similar to DRV_VERSION so that we don't have to duplicate the driver summary in multiple places. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 144d8305585a00467aaedc86d039a4ab036a9bcc Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon Mar 7 09:30:15 2016 -0800 fm10k: Add support for bulk Tx cleanup & cleanup boolean logic This patch enables bulk free in Tx cleanup for fm10k and cleans up the boolean logic in the polling routines for fm10k in the hopes of avoiding any mix-ups similar to what occurred with i40e and i40evf. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit 3ef2f563267892230681b1b8890d8f759d39e64d Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Mar 4 15:37:48 2016 -0800 fm10k: remove debug-statistics support This change fixes an (ab)use of the ethtool stats API, which could result in corrupt memory or misleading stat output. The ethtool stats API is not robust enough to handle varying number of statistics due to how it requests the size and allocates memory. Remove the poorly conceived support originally added for extra debug statistics. In the future, a new stats API may open up the ability to display these statistics. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 72 +----------------------- 1 file changed, 1 insertion(+), 71 deletions(-) commit 09401ae25191039f4aa45c13718595f550745c68 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Apr 1 11:15:09 2016 -0700 fm10k: add helper functions to set strings and data for ethtool stats Reduce duplicate code and the amount of indentation by adding fm10k_add_stat_strings and fm10k_add_ethtool_stats functions which help add fm10k_stat structures to the ethtool stats callbacks. This helps increase ease of use for future stat additions, and increases code readability. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 59 ++++++++++++++---------- 1 file changed, 34 insertions(+), 25 deletions(-) commit 22f708b057dbe3ab4aa53c76b5f3051743784777 Author: Ben Hutchings <ben.hutchings@codethink.co.uk> Date: Fri Apr 1 17:44:38 2016 +0200 ARM: dts: r8a7790: Set maximum frequencies for SDHI clocks Taken from the datasheet. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit 9b091556a073a9f5f93e2ad23d118f45c4796a84 Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 15:46:28 2016 -0700 LSM: LoadPin for kernel file loading restrictions This LSM enforces that kernel-loaded files (modules, firmware, etc) must all come from the same filesystem, with the expectation that such a filesystem is backed by a read-only device such as dm-verity or CDROM. This allows systems that have a verified and/or unchangeable filesystem to enforce module and firmware loading restrictions without needing to sign the files individually. Signed-off-by: Kees Cook <keescook@chromium.org> Acked-by: Serge Hallyn <serge.hallyn@canonical.com> Signed-off-by: James Morris <james.l.morris@oracle.com> Documentation/security/LoadPin.txt | 17 ++++ MAINTAINERS | 6 ++ include/linux/lsm_hooks.h | 5 + security/Kconfig | 1 + security/Makefile | 2 + security/loadpin/Kconfig | 10 ++ security/loadpin/Makefile | 1 + security/loadpin/loadpin.c | 190 +++++++++++++++++++++++++++++++++++++ security/security.c | 1 + 9 files changed, 233 insertions(+) commit 1284ab5b2dcb927d38e4f3fbc2e307f3d1af9262 Author: Mimi Zohar <zohar@linux.vnet.ibm.com> Date: Wed Apr 20 15:46:27 2016 -0700 fs: define a string representation of the kernel_read_file_id enumeration A string representation of the kernel_read_file_id enumeration is needed for displaying messages (eg. pr_info, auditing) that can be used by multiple LSMs and the integrity subsystem. To simplify keeping the list of strings up to date with the enumeration, this patch defines two new preprocessing macros named __fid_enumify and __fid_stringify to create the enumeration and an array of strings. kernel_read_file_id_str() returns a string based on the enumeration. Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com> [kees: removed removal of my old version, constified pointer values] Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/fs.h | 31 +++++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 6 deletions(-) commit 8a56038c2aef97a9d4b9dd608b912b9d9a4a2d68 Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 15:46:26 2016 -0700 Yama: consolidate error reporting Use a common error reporting function for Yama violation reports, and give more detail into the process command lines. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> security/yama/yama_lsm.c | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) commit 21985319add60b55fc27230d9421a3e5af7e998a Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 15:46:25 2016 -0700 string_helpers: add kstrdup_quotable_file Allocate a NULL-terminated file path with special characters escaped, safe for logging. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/string_helpers.h | 3 +++ lib/string_helpers.c | 30 ++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) commit 0d0443288f2244d7054796086e481ddef6abdbba Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 15:46:24 2016 -0700 string_helpers: add kstrdup_quotable_cmdline Provide an escaped (but readable: no inter-argument NULLs) commandline safe for logging. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/string_helpers.h | 1 + lib/string_helpers.c | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) commit b53f27e4fa0d0e72d897830cc4f3f83d2a25d952 Author: Kees Cook <keescook@chromium.org> Date: Wed Apr 20 15:46:23 2016 -0700 string_helpers: add kstrdup_quotable Handle allocating and escaping a string safe for logging. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/string_helpers.h | 2 ++ lib/string_helpers.c | 28 ++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+) commit 151c37bc29bcbc4b34450c76a8125a5b155520e7 Author: Stefan Schmidt <stefan@osg.samsung.com> Date: Tue Apr 19 16:28:55 2016 +0200 ieee802154: atusb: update my copyright years for this driver Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/atusb.c | 2 ++ 1 file changed, 2 insertions(+) commit 308dbb7afde27f9ba359624e6cc1dcba9c93f49a Author: Stefan Schmidt <stefan@osg.samsung.com> Date: Tue Apr 19 16:28:54 2016 +0200 ieee802154: atusb: implement .set_cca_mode ops callback Catching up with the stack here and implement CCA mode setting. Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/atusb.c | 44 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) commit 0f4715c87031fb6a128103f8e640c4ce4dfdea9a Author: Stefan Schmidt <stefan@osg.samsung.com> Date: Tue Apr 19 16:28:53 2016 +0200 ieee802154: atusb: implement .set_cca_ed_level ops callback Catching up with the stack here and implement CCA ED level setting. Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/atusb.c | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) commit fb7c579ab01f010a353d117e484edb05e6f3745c Author: Stefan Schmidt <stefan@osg.samsung.com> Date: Tue Apr 19 16:28:52 2016 +0200 ieee802154: atusb: implement .set_csma_params ops callback Catching up with the stack here and implement CSMA parameter setting. Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/atusb.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit 1ac471edd909184a94893aac075db8408539178e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: uniphier: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/uniphier/pinctrl-uniphier-core.c | 12 +----------- drivers/pinctrl/uniphier/pinctrl-uniphier-ld4.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier-ld6b.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier-pro4.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier-pro5.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier-pxs2.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier-sld8.c | 1 - drivers/pinctrl/uniphier/pinctrl-uniphier.h | 2 -- 8 files changed, 1 insertion(+), 19 deletions(-) commit e46e3ef3d7472f8bdf8f26801847f375300a666b Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: tegra-xusb: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Stephen Warren <swarren@wwwdotorg.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Jon Hunter <jonathanh@nvidia.com> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/tegra/pinctrl-tegra-xusb.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit f1daa8a1a96812372f3afda90c6dc29d62f7f9b3 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: tegra: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Stephen Warren <swarren@wwwdotorg.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/tegra/pinctrl-tegra.c | 12 +----------- drivers/pinctrl/tegra/pinctrl-tegra.h | 2 -- drivers/pinctrl/tegra/pinctrl-tegra114.c | 1 - drivers/pinctrl/tegra/pinctrl-tegra124.c | 1 - drivers/pinctrl/tegra/pinctrl-tegra20.c | 1 - drivers/pinctrl/tegra/pinctrl-tegra210.c | 1 - drivers/pinctrl/tegra/pinctrl-tegra30.c | 1 - 7 files changed, 1 insertion(+), 18 deletions(-) commit 45078ea03f169ddb1bf13aceba748c4bfca524ac Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: ssbi-mpp: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Cc: Chen-Yu Tsai <wens@csie.org> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/sunxi/pinctrl-sunxi.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 88edad04d9bc0f87e44d5a44f438a399c31432ba Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: stm32: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com> Cc: Patrice Chotard <patrice.chotard@st.com> Acked-by: Maxime Coquelin <mcoquelin.stm32@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/stm32/pinctrl-stm32.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit d39de3139180ff90d43a5f4093ada4b31af40e9d Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: spear: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Viresh Kumar <vireshk@kernel.org> Cc: spear-devel@list.st.com Cc: linux-arm-kernel@lists.infradead.org Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/spear/pinctrl-spear.c | 11 +---------- drivers/pinctrl/spear/pinctrl-spear.h | 1 - drivers/pinctrl/spear/pinctrl-spear1310.c | 6 ------ drivers/pinctrl/spear/pinctrl-spear1340.c | 6 ------ drivers/pinctrl/spear/pinctrl-spear300.c | 6 ------ drivers/pinctrl/spear/pinctrl-spear310.c | 6 ------ drivers/pinctrl/spear/pinctrl-spear320.c | 6 ------ 7 files changed, 1 insertion(+), 41 deletions(-) commit 67ec8d7b484639040b7a75b289a2a1d1763e3430 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:37:47 2016 +0530 pinctrl: ish-pfc: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: Geert Uytterhoeven <geert+renesas@glider.be> Cc: linux-renesas-soc@vger.kernel.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/sh-pfc/core.c | 1 - drivers/pinctrl/sh-pfc/core.h | 2 -- drivers/pinctrl/sh-pfc/pinctrl.c | 13 +------------ 3 files changed, 1 insertion(+), 15 deletions(-) commit 9ed19e06ca4dcc12d621b02ed6150b5ffcf2a249 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:36:42 2016 +0530 pinctrl: samsung: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Tomasz Figa <tomasz.figa@gmail.com> Cc: Kukjin Kim <kgene@kernel.org> Cc: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/samsung/pinctrl-samsung.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 40011bfe15c4c5907391d9d0efa3801a3f28ddc6 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: exynos5440: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Tomasz Figa <tomasz.figa@gmail.com> Cc: Kukjin Kim <kgene@kernel.org> Cc: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/samsung/pinctrl-exynos5440.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6d33ee7a05341f9ddcaa9374d3d6800919e2f150 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: pxa: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Daniel Mack <daniel@zonque.org> Cc: Haojian Zhuang <haojian.zhuang@gmail.com> Cc: Robert Jarzmik <robert.jarzmik@free.fr> Cc: linux-arm-kernel@lists.infradead.org Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pxa/pinctrl-pxa2xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe0267f47a9f32f6e73ce1d3cb97eafc63d9be5c Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: msm: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Bjorn Andersson <bjorn.andersson@sonymobile.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Lee Jones <lee.jones@linaro.org> Cc: Stephen Boyd <sboyd@codeaurora.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/qcom/pinctrl-msm.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 5f5e111af617c2371552af3e516841adb2e25f58 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: ssbi-mpp: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Bjorn Andersson <bjorn.andersson@sonymobile.com> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/qcom/pinctrl-ssbi-mpp.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit 16f3b9c3a5bb5f1d4c73356c93dc0f25a0e97b8f Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: ssbi-gpi: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Bjorn Andersson <bjorn.andersson@sonymobile.com> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/qcom/pinctrl-ssbi-gpio.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit ce18e595b7f9feee947eb4d3ecb1dfdd704f46a4 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: spmi: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Bjorn Andersson <bjorn.andersson@sonymobile.com> Cc: Ivan T. Ivanov <ivan.ivanov@linaro.org> Cc: Lee Jones <lee.jones@linaro.org> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Jonas Gorski <jogo@openwrt.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/qcom/pinctrl-spmi-mpp.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit b46ddfe60ba0a37f7bdfc871ff3802465c92e6d9 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: spmi-gpio: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: "Björn Andersson" <bjorn.andersson@sonymobile.com> Cc: "Ivan T. Ivanov" <ivan.ivanov@linaro.org> Cc: Lee Jones <lee.jones@linaro.org> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Jonas Gorski <jogo@openwrt.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/qcom/pinctrl-spmi-gpio.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 0ee60110ca567b951c4855c12c472dd8f9193589 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: nomadic: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Alessandro Rubini <rubini@unipv.it> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/nomadik/pinctrl-abx500.c | 3 ++- drivers/pinctrl/nomadik/pinctrl-nomadik.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) commit 699097a9b8aeb7ae819dd8fefb7863799cbde98e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: mvebu: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Hongzhou Yang <hongzhou.yang@mediatek.com> Cc: Fabian Frederick <fabf@skynet.be> Cc: Andrew Andrianov <andrew@ncrmnt.org> Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/mvebu/pinctrl-armada-370.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-armada-375.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-armada-38x.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-armada-39x.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-armada-xp.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-dove.c | 5 +---- drivers/pinctrl/mvebu/pinctrl-kirkwood.c | 6 ------ drivers/pinctrl/mvebu/pinctrl-mvebu.c | 9 +-------- drivers/pinctrl/mvebu/pinctrl-mvebu.h | 1 - drivers/pinctrl/mvebu/pinctrl-orion.c | 6 ------ 10 files changed, 2 insertions(+), 55 deletions(-) commit e649f7ec8c5f776dd7e9fbeb18ca5f4e8ce85922 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: meson: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Carlo Caione <carlo@endlessm.com> Cc: Beniamino Galvani <b.galvani@gmail.com> Cc: Lee Jones <lee.jones@linaro.org> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/meson/pinctrl-meson.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 03a3a5587e62079a6e8dc0a269ab5ba2262c0a87 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:43:15 2016 +0530 pinctrl: mtk-common: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Matthias Brugger <matthias.bgg@gmail.com> Cc: Hongzhou Yang <hongzhou.yang@mediatek.com> Cc: Yingjoe Chen <yingjoe.chen@mediatek.com> Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> Acked-by: Hongzhou Yang <hongzhou.yang@mediatek.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit 54d46cd7d236540f881767af366eca9734b7e980 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Sun Feb 28 14:42:47 2016 +0530 pinctrl: intel: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-intel.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 7cf061fadd66511074631acbb95e6f00e4fcc047 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: cherryview: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-cherryview.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit e55e025d16871018ec2fd168e2deaa2a9a0333b5 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: imxl: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Hongzhou Yang <hongzhou.yang@mediatek.com> Cc: Antoine Tenart <antoine.tenart@free-electrons.com> Cc: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/freescale/pinctrl-imx1-core.c | 11 +---------- drivers/pinctrl/freescale/pinctrl-imx1.c | 1 - drivers/pinctrl/freescale/pinctrl-imx1.h | 1 - drivers/pinctrl/freescale/pinctrl-imx21.c | 1 - drivers/pinctrl/freescale/pinctrl-imx27.c | 1 - 5 files changed, 1 insertion(+), 14 deletions(-) commit a4b0f4571c7438cbc11f088d57d6a5ef3e60e3cb Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: imx: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and remove need of .remove callback. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Shawn Guo <shawnguo@kernel.org> Cc: Stefan Agner <stefan@agner.ch> Cc: Adrian Alonso <aalonso@freescale.com> Cc: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/freescale/pinctrl-imx.c | 11 +---------- drivers/pinctrl/freescale/pinctrl-imx.h | 1 - drivers/pinctrl/freescale/pinctrl-imx25.c | 1 - drivers/pinctrl/freescale/pinctrl-imx35.c | 1 - drivers/pinctrl/freescale/pinctrl-imx50.c | 1 - drivers/pinctrl/freescale/pinctrl-imx51.c | 1 - drivers/pinctrl/freescale/pinctrl-imx53.c | 1 - drivers/pinctrl/freescale/pinctrl-imx6dl.c | 1 - drivers/pinctrl/freescale/pinctrl-imx6q.c | 1 - drivers/pinctrl/freescale/pinctrl-imx6sl.c | 1 - drivers/pinctrl/freescale/pinctrl-imx6sx.c | 1 - drivers/pinctrl/freescale/pinctrl-imx6ul.c | 1 - drivers/pinctrl/freescale/pinctrl-imx7d.c | 1 - drivers/pinctrl/freescale/pinctrl-vf610.c | 1 - 14 files changed, 1 insertion(+), 23 deletions(-) commit 7e73f819054c5da0203a4faf446c9776a4ca0f75 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: berlin: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Antoine Ténart <antoine.tenart@free-electrons.com> Acked-by: Antoine Tenart <antoine.tenart@free-electrons.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/berlin/berlin.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 315d118f1ac5b6132b604f69e1281cf7fa83594f Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: nsp-gpio: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Ray Jui <rjui@broadcom.com> Cc: Scott Branden <sbranden@broadcom.com> Cc: Jon Mason <jonmason@broadcom.com> Acked-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-nsp-gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ee17e04102e2483ad61e7f0e704e6d6dc94922d7 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: iproc-gpio: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration and clean the error path. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Ray Jui <rjui@broadcom.com> Cc: Scott Branden <sbranden@broadcom.com> Cc: Jon Mason <jonmason@broadcom.com> Acked-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit ead044eeec3e822f17cdce2a690970b96e289682 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: cygnus-mux: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Ray Jui <rjui@broadcom.com> Cc: Scott Branden <sbranden@broadcom.com> Cc: Jon Mason <jonmason@broadcom.com> Acked-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-cygnus-mux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5f276f679f5a80294c5689b8d900ba3881f2de8f Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: bcm2835: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Ray Jui <rjui@broadcom.com> Cc: linux-rpi-kernel@lists.infradead.org Cc: linux-arm-kernel@lists.infradead.org Cc: bcm-kernel-feedback-list@broadcom.com Acked-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-bcm2835.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 7f5567aa879bac8eec961fa8c82cbacf7f97f288 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:44:07 2016 +0530 pinctrl: bcm281xx: Use devm_pinctrl_register() for pinctrl registration Use devm_pinctrl_register() for pin control registration. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Ray Jui <rjui@broadcom.com> Cc: linux-rpi-kernel@lists.infradead.org Cc: linux-arm-kernel@lists.infradead.org Cc: bcm-kernel-feedback-list@broadcom.com Acked-by: Ray Jui <ray.jui@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-bcm281xx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 1f8dd72fc3f0d371684685a2f9f8c4220ecd3517 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:14:35 2016 +0530 pinctrl: Add resource management devm_pinctrl_{register, unregister} Add new member of devm wrappers for the pinctrl_register and pinctrl_unregister in list of managed interfaces. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/driver-model/devres.txt | 2 ++ 1 file changed, 2 insertions(+) commit 80e0f8d94d3090f0f7bf3faf3e6180e920ee0d22 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Feb 24 14:12:59 2016 +0530 pinctrl: Add devm_ apis for pinctrl_{register, unregister} Add device managed APIs devm_pinctrl_register() and devm_pinctrl_unregister() for the APIs pinctrl_register() and pinctrl_unregister(). This helps in reducing code in error path and sometimes removal of .remove callback for driver unbind. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/core.c | 63 +++++++++++++++++++++++++++++++++++++++++ include/linux/pinctrl/pinctrl.h | 6 ++++ 2 files changed, 69 insertions(+) commit 2d077d9f4e984a5364bf62e719396375b2922d26 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 10:41:10 2016 -0700 Input: bcm_iproc_tsc - DT spelling s/clock-name/clock-names/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> .../devicetree/bindings/input/touchscreen/brcm,iproc-touchscreen.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3db63602505fa30f9d8faa1512fc71dae0cbf71b Author: John Stultz <john.stultz@linaro.org> Date: Thu Apr 14 14:07:11 2016 -0700 device-tree: nexus7: Add bq27541 battery interface to dts Add support for battery level reading on the Nexus7 by enabling the bq27541 driver in the nexus7 dts Cc: Rob Herring <robh+dt@kernel.org> Cc: Arnd Bergmann <arnd.bergmann@linaro.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Kumar Gala <galak@codeaurora.org> Cc: Andy Gross <agross@codeaurora.org> Cc: Vinay Simha BN <simhavcs@gmail.com> Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Cc: Stephen Boyd <stephen.boyd@linaro.org> Cc: linux-arm-msm@vger.kernel.org Cc: devicetree@vger.kernel.org Signed-off-by: John Stultz <john.stultz@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-asus-nexus7-flo.dts | 6 ++++++ 1 file changed, 6 insertions(+) commit 2b9d49d8c749ce3c8f5cb28f54875a6f33fa1f72 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:34:02 2016 +0100 ARM: dts: db600c: add support to magnetometer This patch adds support to on board LIS3MDLTR magnetometer. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c-pins.dtsi | 8 ++++++++ arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 13 +++++++++++++ 2 files changed, 21 insertions(+) commit e0da214a8892d0e36f8575e1c996e78c66e2674c Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:34:01 2016 +0100 ARM: dts: db600c: add spi support This patch adds spi nodes required to provide spi bus support on LS expansion. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 10 ++++++++++ 1 file changed, 10 insertions(+) commit d8aef8720c605600e21f57c412876f60e1721582 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:34:00 2016 +0100 ARM: dts: db600c: add i2c support This patch adds nodes required to enable 4 i2c buses on the board which are connected to various sensors and eeprom. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 46 +++++++++++++++++++++++++ 1 file changed, 46 insertions(+) commit 2f29160fce634cb0e8e1bc493d0e509407ac1e0e Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:59 2016 +0100 ARM: dts: db600c: Add on board leds support This patch adds support to 4 user leds, wlan and bt led on board. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> .../boot/dts/qcom-apq8064-arrow-db600c-pins.dtsi | 23 +++++++++++ arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 47 ++++++++++++++++++++++ 2 files changed, 70 insertions(+) commit 2ce36229a8cab110d50f227dda64850072e74b2d Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:58 2016 +0100 ARM: dts: db600c: add on board sata support. This patch enables sata and regulators required to get on board sata working. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit c22847863a58c42035660ffa7fadbef6459e67bd Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:57 2016 +0100 ARM: dts: db600c: add pcie support This patch adds pcie and regulators required to get on board ATL1C ethernet working. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> .../boot/dts/qcom-apq8064-arrow-db600c-pins.dtsi | 12 +++++++++++ arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 24 ++++++++++++++++++++++ 2 files changed, 36 insertions(+) commit f43a92715d5b71b3524a96bdf3b5ed6c4ce1d6b2 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:56 2016 +0100 ARM: dts: db600c: add usb support This patch adds usb host and otg support on board with required regulators. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 64 +++++++++++++++++++++++++ 1 file changed, 64 insertions(+) commit 226355fb9e486ae472df10e34eb5ac636f196657 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:55 2016 +0100 ARM: dts: db600c: Add eMMC and SD card support This patch adds eMMC and SD card support with card detect and adding required regulators. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> .../boot/dts/qcom-apq8064-arrow-db600c-pins.dtsi | 9 ++++++ arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 34 ++++++++++++++++++++++ 2 files changed, 43 insertions(+) commit 696a8a16f92b83c14c58b7a4d28526aaeeabafe8 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:54 2016 +0100 ARM: dts: db600c: add pmic regulator supplies This patch adds pmic regulator supplies connected on the board. Rest of the invidual regulators would be added as and when required by the devices. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 62 +++++++++++++++++++++++++ 1 file changed, 62 insertions(+) commit 973747fb473474db4ad69900e7af7d4f91e78895 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:53 2016 +0100 ARM: dts: db600c: add board support with serial This patch adds support to DB600c with basic serial ports. DB600c is based on APQ8064. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/qcom-apq8064-arrow-db600c.dts | 36 +++++++++++++++++++++++++ 2 files changed, 37 insertions(+) commit e4b01fda5dca99c227494bd9dc3a9d7628a17c2f Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:52 2016 +0100 ARM: dts: apq8064: add gsbi7 i2c support This patch adds support to gsbi7 i2c which is used in some of the new boards. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-pins.dtsi | 25 +++++++++++++++++++++++++ arch/arm/boot/dts/qcom-apq8064.dtsi | 13 +++++++++++++ 2 files changed, 38 insertions(+) commit 12861674c99100b77dc78ed5037e4e1a5b95b0d5 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:51 2016 +0100 ARM: dts: apq8064: add support to gsbi1 uart This patch adds support to gsbi1 uart and its pinctrls nodes. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064-pins.dtsi | 14 ++++++++++++++ arch/arm/boot/dts/qcom-apq8064.dtsi | 10 ++++++++++ 2 files changed, 24 insertions(+) commit 67b5ad57df3537aa479010af1581e8c4edf580e4 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:33:50 2016 +0100 ARM: dts: apq8064: fix the pinctrls for i2c and spi This patch fixes pinctrls for spi and i2c nodes whose default and sleep states are together, which is incorrect. Without this patch i2c/spi would not be functional. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064.dtsi | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) commit 2afc5287c50e013c46e07413c066920dc7f55a91 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 20:37:04 2016 -0700 ARM: dts: qcom: apq8064: Add smd node and all edges Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064.dtsi | 40 +++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit b4d4582fa6959ee494b2146522f1edd72ba6218d Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 20:37:03 2016 -0700 ARM: dts: qcom: apq8064: Add complete smsm node Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064.dtsi | 49 +++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) commit b9e4c5e6ee26a906fa8514467b5abb9655c3ffdc Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 20:37:02 2016 -0700 ARM: dts: qcom: apq8064: Add syscon for sic-non-secure Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-apq8064.dtsi | 5 +++++ 1 file changed, 5 insertions(+) commit 22e2f9fa63b092923873fc8a52955151f4d83274 Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:34:11 2016 +0300 iommu/vt-d: Use per-cpu IOVA caching Commit 9257b4a2 ('iommu/iova: introduce per-cpu caching to iova allocation') introduced per-CPU IOVA caches to massively improve scalability. Use them. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased, cleaned up and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> [dwmw2: split out VT-d part into a separate patch] Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 47 +++++++++++++++++++++++++++++++++------------ 1 file changed, 35 insertions(+), 12 deletions(-) commit 10c9ead9f3c6bb24bddc9a96681f7d58e6623966 Author: Roopa Prabhu <roopa@cumulusnetworks.com> Date: Wed Apr 20 08:43:43 2016 -0700 rtnetlink: add new RTM_GETSTATS message to dump link stats This patch adds a new RTM_GETSTATS message to query link stats via netlink from the kernel. RTM_NEWLINK also dumps stats today, but RTM_NEWLINK returns a lot more than just stats and is expensive in some cases when frequent polling for stats from userspace is a common operation. RTM_GETSTATS is an attempt to provide a light weight netlink message to explicity query only link stats from the kernel on an interface. The idea is to also keep it extensible so that new kinds of stats can be added to it in the future. This patch adds the following attribute for NETDEV stats: struct nla_policy ifla_stats_policy[IFLA_STATS_MAX + 1] = { [IFLA_STATS_LINK_64] = { .len = sizeof(struct rtnl_link_stats64) }, }; Like any other rtnetlink message, RTM_GETSTATS can be used to get stats of a single interface or all interfaces with NLM_F_DUMP. Future possible new types of stat attributes: link af stats: - IFLA_STATS_LINK_IPV6 (nested. for ipv6 stats) - IFLA_STATS_LINK_MPLS (nested. for mpls/mdev stats) extended stats: - IFLA_STATS_LINK_EXTENDED (nested. extended software netdev stats like bridge, vlan, vxlan etc) - IFLA_STATS_LINK_HW_EXTENDED (nested. extended hardware stats which are available via ethtool today) This patch also declares a filter mask for all stat attributes. User has to provide a mask of stats attributes to query. filter mask can be specified in the new hdr 'struct if_stats_msg' for stats messages. Other important field in the header is the ifindex. This api can also include attributes for global stats (eg tcp) in the future. When global stats are included in a stats msg, the ifindex in the header must be zero. A single stats message cannot contain both global and netdev specific stats. To easily distinguish them, netdev specific stat attributes name are prefixed with IFLA_STATS_LINK_ Without any attributes in the filter_mask, no stats will be returned. This patch has been tested with mofified iproute2 ifstat. Suggested-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 23 ++++++ include/uapi/linux/rtnetlink.h | 5 ++ net/core/rtnetlink.c | 158 +++++++++++++++++++++++++++++++++++++++++ security/selinux/nlmsgtab.c | 4 +- 4 files changed, 189 insertions(+), 1 deletion(-) commit 9257b4a206fc0229dd5f84b78e4d1ebf3f91d270 Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:34:11 2016 +0300 iommu/iova: introduce per-cpu caching to iova allocation IOVA allocation has two problems that impede high-throughput I/O. First, it can do a linear search over the allocated IOVA ranges. Second, the rbtree spinlock that serializes IOVA allocations becomes contended. Address these problems by creating an API for caching allocated IOVA ranges, so that the IOVA allocator isn't accessed frequently. This patch adds a per-CPU cache, from which CPUs can alloc/free IOVAs without taking the rbtree spinlock. The per-CPU caches are backed by a global cache, to avoid invoking the (linear-time) IOVA allocator without needing to make the per-CPU cache size excessive. This design is based on magazines, as described in "Magazines and Vmem: Extending the Slab Allocator to Many CPUs and Arbitrary Resources" (currently available at https://www.usenix.org/legacy/event/usenix01/bonwick.html) Adding caching on top of the existing rbtree allocator maintains the property that IOVAs are densely packed in the IO virtual address space, which is important for keeping IOMMU page table usage low. To keep the cache size reasonable, we bound the IOVA space a CPU can cache by 32 MiB (we cache a bounded number of IOVA ranges, and only ranges of size <= 128 KiB). The shared global cache is bounded at 4 MiB of IOVA space. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased, cleaned up and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> [dwmw2: split out VT-d part into a separate patch] Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/iova.c | 417 ++++++++++++++++++++++++++++++++++++++++++++++++--- include/linux/iova.h | 23 ++- 2 files changed, 414 insertions(+), 26 deletions(-) commit e6f268ef3687862b0e9f01f7b3706b54f75b82ab Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 20 15:32:54 2016 -0400 net: nla_align_64bit() needs to test the right pointer. Netlink messages are appended, one object at a time, to the end of the SKB. Therefore we need to test skb_tail_pointer() not skb->data for alignment. Fixes: 35c5845957c7 ("net: Add helpers for 64-bit aligning netlink attributes.") Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e07d46e7e0da86c146f199dae76f879096bc436a Author: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Date: Fri Apr 8 17:28:58 2016 -0300 [media] tpg: Export the tpg code from vivid as a module The test pattern generator will be used by other drivers as the virtual media controller (vimc) Signed-off-by: Helen Mae Koike Fornazier <helen.koike@collabora.co.uk> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/common/Kconfig | 1 + drivers/media/common/Makefile | 2 +- drivers/media/common/v4l2-tpg/Kconfig | 2 + drivers/media/common/v4l2-tpg/Makefile | 3 + drivers/media/common/v4l2-tpg/v4l2-tpg-colors.c | 1415 ++++++++++++++ drivers/media/common/v4l2-tpg/v4l2-tpg-core.c | 2335 +++++++++++++++++++++++ drivers/media/platform/vivid/Kconfig | 1 + drivers/media/platform/vivid/Makefile | 2 +- drivers/media/platform/vivid/vivid-core.h | 2 +- drivers/media/platform/vivid/vivid-tpg-colors.c | 1416 -------------- drivers/media/platform/vivid/vivid-tpg-colors.h | 68 - drivers/media/platform/vivid/vivid-tpg.c | 2314 ---------------------- drivers/media/platform/vivid/vivid-tpg.h | 598 ------ include/media/v4l2-tpg-colors.h | 68 + include/media/v4l2-tpg.h | 597 ++++++ 15 files changed, 4425 insertions(+), 4399 deletions(-) commit d1e5d8bd49d9a830b6b5f4da906f868b2ceb83a4 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Sun Apr 3 16:42:43 2016 -0300 [media] vivid: use new v4l2-rect.h header The v4l2_rect helper functions have been moved to include/media/v4l2-rect.h. Use this new header, dropping the functions from vivid. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vivid/vivid-kthread-cap.c | 13 +-- drivers/media/platform/vivid/vivid-vid-cap.c | 101 +++++++++++----------- drivers/media/platform/vivid/vivid-vid-common.c | 97 --------------------- drivers/media/platform/vivid/vivid-vid-common.h | 9 -- drivers/media/platform/vivid/vivid-vid-out.c | 103 ++++++++++++----------- 5 files changed, 110 insertions(+), 213 deletions(-) commit ac49de8c49d770b5ded5c717c1eaf339d7649da1 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Sun Apr 3 16:42:42 2016 -0300 [media] v4l2-rect.h: new header with struct v4l2_rect helper functions This makes it easier to share this code with any driver that needs to manipulate the v4l2_rect datastructure. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/device-drivers.tmpl | 1 + include/media/v4l2-rect.h | 173 ++++++++++++++++++++++++++++++ 2 files changed, 174 insertions(+) commit fe29301122902a902c5c323ee14078b1ab3f1ad1 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Sun Apr 3 17:44:17 2016 -0300 [media] ivtv/cx18: use the new mask variants of the v4l2_device_call_* defines Instead of rolling our own define, just use the new mask defines. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/cx18/cx18-driver.h | 13 ++----------- drivers/media/pci/ivtv/ivtv-driver.h | 13 ++----------- 2 files changed, 4 insertions(+), 22 deletions(-) commit 96655553e5f9af6a8d908386685b7c865a138283 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Sun Apr 3 17:44:16 2016 -0300 [media] v4l2-device.h: add v4l2_device_mask_ variants The v4l2_device_call_* defines filter subdevs based on the grp_id value. But some drivers use a bitmask, so instead of filtering by grp_id == value, you want to filter by grp_id & value. Make variants of these defines to do this. The 'has_op' define has been extended to have a grp_id argument as well, and a mask variant has been added. This extra argument required a change to go7007. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/go7007/go7007-v4l2.c | 2 +- include/media/v4l2-device.h | 55 +++++++++++++++++++++++++++++++++- 2 files changed, 55 insertions(+), 2 deletions(-) commit bae4c757a5255a149249294dab3a6ab16e5d598b Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Sat Apr 2 14:42:20 2016 -0300 [media] adv7180: Add g_tvnorms operation The ADV7180 supports NTSC, PAL and SECAM. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/adv7180.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 2aac630429d986a43ac59525a4cff47a624dc58e Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:33:57 2016 +0300 iommu/vt-d: change intel-iommu to use IOVA frame numbers Make intel-iommu map/unmap/invalidate work with IOVA pfns instead of pointers to "struct iova". This avoids using the iova struct from the IOVA red-black tree and the resulting explicit find_iova() on unmap. This patch will allow us to cache IOVAs in the next patch, in order to avoid rbtree operations for the majority of map/unmap operations. Note: In eliminating the find_iova() operation, we have also eliminated the sanity check previously done in the unmap flow. Arguably, this was overhead that is better avoided in production code, but it could be brought back as a debug option for driver development. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased, fixed to not break iova api, and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 61 +++++++++++++++++++++------------------------ 1 file changed, 29 insertions(+), 32 deletions(-) commit 64b3df9223aa4d0e809bbf5a8b006fcc884b7c90 Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Sat Apr 2 14:42:19 2016 -0300 [media] adv7180: Add cropcap operation Add support to get the pixel aspect ratio depending on the current standard (50 vs 60 Hz). Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/adv7180.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 0824c5920b16fe11034f3b5d2d48456d282d83f9 Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 19:03:35 2016 +0300 iommu/vt-d: avoid dev iotlb logic for domains with no dev iotlbs This patch avoids taking the device_domain_lock in iommu_flush_dev_iotlb() for domains with no dev iotlb devices. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [gvdl@google.com: fixed locking issues] Signed-off-by: Godfrey van der Linden <gvdl@google.com> [mad@cs.technion.ac.il: rebased and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit d0fadc869349e0469abc80109d4251be432736bd Author: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Date: Sat Apr 2 14:42:18 2016 -0300 [media] adv7180: Add g_std operation Add support to get the standard to the adv7180 driver. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/adv7180.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 769530e4ba4898748a293592f0920275b40cbb93 Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:33:25 2016 +0300 iommu/vt-d: only unmap mapped entries Current unmap implementation unmaps the entire area covered by the IOVA range, which is a power-of-2 aligned region. The corresponding map, however, only maps those pages originally mapped by the user. This discrepancy can lead to unmapping of already unmapped entries, which is unneeded work. With this patch, only mapped pages are unmapped. This is also a baseline for a map/unmap implementation based on IOVAs and not iova structures, which will allow caching. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 36 +++++++++++++++++++++++++----------- 1 file changed, 25 insertions(+), 11 deletions(-) commit f5c0c08b1e0976cb493d503108f1b897ce58bc5d Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:33:11 2016 +0300 iommu/vt-d: correct flush_unmaps pfn usage Change flush_unmaps() to correctly pass iommu_flush_iotlb_psi() dma addresses. (x86_64 mm and dma have the same size for pages at the moment, but this usage improves consistency.) Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b05a4fa66a8d4589ba9f027db11d383250a4b774 Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Sun Mar 27 18:15:14 2016 -0300 [media] Staging: media: bcm2048: defined region_configs[] array as const array This patch defines region_configs[] array as const array since it is not changed anywhere in code. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/bcm2048/radio-bcm2048.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa4732406e1290dd18a8d2078977996c152a4be7 Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:33:02 2016 +0300 iommu/vt-d: per-cpu deferred invalidation queues The IOMMU's IOTLB invalidation is a costly process. When iommu mode is not set to "strict", it is done asynchronously. Current code amortizes the cost of invalidating IOTLB entries by batching all the invalidations in the system and performing a single global invalidation instead. The code queues pending invalidations in a global queue that is accessed under the global "async_umap_flush_lock" spinlock, which can result is significant spinlock contention. This patch splits this deferred queue into multiple per-cpu deferred queues, and thus gets rid of the "async_umap_flush_lock" and its contention. To keep existing deferred invalidation behavior, it still invalidates the pending invalidations of all CPUs whenever a CPU reaches its watermark or a timeout occurs. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased, cleaned up and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 133 ++++++++++++++++++++++++++++++-------------- 1 file changed, 92 insertions(+), 41 deletions(-) commit 314f1dc140844a73034e285ddac92b9e1ffecb5b Author: Omer Peleg <omer@cs.technion.ac.il> Date: Wed Apr 20 11:32:45 2016 +0300 iommu/vt-d: refactoring of deferred flush entries Currently, deferred flushes' info is striped between several lists in the flush tables. Instead, move all information about a specific flush to a single entry in this table. This patch does not introduce any functional change. Signed-off-by: Omer Peleg <omer@cs.technion.ac.il> [mad@cs.technion.ac.il: rebased and reworded the commit message] Signed-off-by: Adam Morrison <mad@cs.technion.ac.il> Reviewed-by: Shaohua Li <shli@fb.com> Reviewed-by: Ben Serebrin <serebrin@google.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> drivers/iommu/intel-iommu.c | 48 +++++++++++++++++++++++++++------------------ 1 file changed, 29 insertions(+), 19 deletions(-) commit c5c631416789004e7205a56ab1aaab2b3a011b1b Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 22 07:30:29 2016 -0300 [media] vidioc-dv-timings-cap.xml: explicitly state that pad and reserved should be zeroed The DV_TIMINGS_CAP documentation didn't state clearly that the pad and reserved fields should be zeroed by the application. For subdev pad can be other values as well. It also mistakenly said that only drivers would have to zero the reserved field, that's not correct. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/v4l/vidioc-dv-timings-cap.xml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 0c53fee973a9adfa4ad21433d397adae12b2120b Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 22 07:30:28 2016 -0300 [media] vidioc-enum-dv-timings.xml: explicitly state that pad and reserved should be zeroed The ENUM_DV_TIMINGS documentation did not clearly state that the pad and reserved fields should be zeroed (pad only when used with a video device node). Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/v4l/vidioc-enum-dv-timings.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 0be67c40d4e8c5b3d96581680fa797f28a3025ec Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 22 07:30:27 2016 -0300 [media] vidioc-g-edid.xml: be explicit about zeroing the reserved array The G/S_EDID documentation did not explicitly state that the reserved array should be zeroed by the application. Also add the missing VIDIOC_SUBDEV_G/S_EDID ioctl names to the header. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/DocBook/media/v4l/vidioc-g-edid.xml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 72777724881f90c6efa027cc0dde9466371d740c Author: Hans Verkuil <hverkuil@xs4all.nl> Date: Tue Mar 22 06:59:02 2016 -0300 [media] tc358743: zero the reserved array v4l2-compliance complained about this. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/tc358743.c | 4 ++++ 1 file changed, 4 insertions(+) commit 5848adbe43034c8a1a378f9fed9afe501d9a4988 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 15 12:35:33 2016 -0300 [media] dib0090: fix smatch error Fix this smatch error: dib0090.c:1124 dib0090_pwm_gain_reset() error: we previously assumed 'state->rf_ramp' could be null (see line 1086) Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-frontends/dib0090.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 622202938952e43471c31835906c8a4f4e16f050 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 15 12:35:32 2016 -0300 [media] pvrusb2: fix smatch errors These are false positives, but still easy to fix. pvrusb2-hdw.c:3676 pvr2_send_request_ex() error: we previously assumed 'write_data' could be null (see line 3648) pvrusb2-hdw.c:3829 pvr2_send_request_ex() error: we previously assumed 'read_data' could be null (see line 3649) Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/pvrusb2/pvrusb2-hdw.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit 86b2749ba79e78130dd9f678aa52d57992fbdf1c Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Fri Apr 15 12:35:31 2016 -0300 [media] vivid: fix smatch errors The smatch utility got really confused about the grp % 22 code. Rewrote it so it now understands that there really isn't a buffer overwrite. vivid-rds-gen.c:82 vivid_rds_generate() error: buffer overflow 'rds->psname' 9 <= 43 vivid-rds-gen.c:83 vivid_rds_generate() error: buffer overflow 'rds->psname' 9 <= 42 vivid-rds-gen.c:89 vivid_rds_generate() error: buffer overflow 'rds->radiotext' 65 <= 84 vivid-rds-gen.c:90 vivid_rds_generate() error: buffer overflow 'rds->radiotext' 65 <= 85 vivid-rds-gen.c:92 vivid_rds_generate() error: buffer overflow 'rds->radiotext' 65 <= 86 vivid-rds-gen.c:93 vivid_rds_generate() error: buffer overflow 'rds->radiotext' 65 <= 87 Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vivid/vivid-rds-gen.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit 00983519214b61c1b9371ec2ed55a4dde773e384 Author: Mika Kahola <mika.kahola@intel.com> Date: Wed Apr 20 15:39:02 2016 +0300 drm/i915: Fix eDP low vswing for Broadwell It was noticed on bug #94087 that module parameter i915.edp_vswing=2 that should override the VBT setting to use default voltage swing (400 mV) was not applied for Broadwell. This patch provides a fix for this by checking if default i.e. higher voltage swing is requested to be used and applies the DDI translations table for DP instead of eDP (low vswing) table. v2: Combine two if statements into one (Jani) v3: Change dev_priv->edp_low_vswing to use dev_priv->vbt.edp.low_vswing Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94087 Signed-off-by: Mika Kahola <mika.kahola@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461155942-7749-1-git-send-email-mika.kahola@intel.com Cc: stable@vger.kernel.org Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/intel_ddi.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit bb4399b8a5d7d9a8bf9d28b1e78badff1b0e5a5e Merge: 0f05db6 2066390 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed Apr 20 11:44:03 2016 -0700 Merge tag 'clk-renesas-for-v4.7-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into clk-next clk: renesas: R-Car SYSC PM Domain Preparation - Export the CPG/MSSR and CPG/MSTP attach/detach_dev callbacks, so they can be called by the R-Car SYSC PM Domain driver. * tag 'clk-renesas-for-v4.7-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers: clk: renesas: cpg-mssr: Export cpg_mssr_{at,de}tach_dev() clk: renesas: mstp: Provide dummy attach/detach_dev callbacks clk: renesas: Provide Kconfig symbols for CPG/MSSR and CPG/MSTP support commit 0f05db651dc50c2a6f45794de2567fbf64a4df75 Merge: e708b38 03ae174 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Wed Apr 20 11:41:37 2016 -0700 Merge tag 'v4.7-rockchip-clk2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-next Pull some checkpatch silencers from Heiko Stuebner: Fix quite some checkpatch warnings in the newly added rk3399 header and also in the clock code itself. * tag 'v4.7-rockchip-clk2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: fix checkpatch warning in core code clk: rockchip: drop unnecessary header comment clk: rockchip: reign in some overly long lines in the rk3399 controller clk: rockchip: fix checkpatch errors in rk3399 dt-binding header commit 1fe63c9ca8913eb7af6c428cf81abad29e0bc9d6 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:46:16 2016 +0300 ath10k: remove enum ath10k_swap_code_seg_bin_type It's not needed for anything so just get rid of it. Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 3 +-- drivers/net/wireless/ath/ath10k/swap.c | 22 ++++++---------------- drivers/net/wireless/ath/ath10k/swap.h | 9 +-------- 3 files changed, 8 insertions(+), 26 deletions(-) commit 9dfe240b4d684f17efa861e92e45dc949b0049ed Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:46:01 2016 +0300 ath10k: switch testmode to use ath10k_core_fetch_firmware_api_n() Now that all firmware-N.bin related are within struct ath10k_fw_file we can switch to use ath10k_core_fetch_firmware_api_n() and delete almost identical ath10k_tm_fetch_utf_firmware_api_2(). Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 4 +- drivers/net/wireless/ath/ath10k/core.h | 2 + drivers/net/wireless/ath/ath10k/testmode.c | 124 +---------------------------- 3 files changed, 6 insertions(+), 124 deletions(-) commit 77561f9394f8553cce487b12b15b4879ecbaf6d7 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:45:47 2016 +0300 ath10k: move htt_op_version to struct ath10k_fw_file Preparation for testmode.c to use ath10k_core_fetch_board_data_api_n(). Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 12 ++++++------ drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/debug.c | 2 +- drivers/net/wireless/ath/ath10k/htt.c | 2 +- drivers/net/wireless/ath/ath10k/htt.h | 1 - drivers/net/wireless/ath/ath10k/mac.c | 2 +- drivers/net/wireless/ath/ath10k/testmode.c | 1 + 7 files changed, 11 insertions(+), 10 deletions(-) commit bf3c13ab49965f0517b579dc490d612d074d535a Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:45:33 2016 +0300 ath10k: move wmi_op_version to struct ath10k_fw_file Preparation for testmode.c to use ath10k_core_fetch_board_data_api_n(). Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 20 ++++++++++---------- drivers/net/wireless/ath/ath10k/core.h | 5 ++--- drivers/net/wireless/ath/ath10k/debug.c | 2 +- drivers/net/wireless/ath/ath10k/mac.c | 2 +- drivers/net/wireless/ath/ath10k/testmode.c | 17 ++++++----------- drivers/net/wireless/ath/ath10k/wmi.c | 4 ++-- 6 files changed, 22 insertions(+), 28 deletions(-) commit c4cdf753ed4287467248126a4fac072fbba53b31 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:45:18 2016 +0300 ath10k: move fw_features to struct ath10k_fw_file Preparation for testmode.c to use ath10k_core_fetch_board_data_api_n(). Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 28 +++++++++++++++------------- drivers/net/wireless/ath/ath10k/core.h | 5 ++--- drivers/net/wireless/ath/ath10k/htt_rx.c | 2 +- drivers/net/wireless/ath/ath10k/htt_tx.c | 9 ++++++--- drivers/net/wireless/ath/ath10k/mac.c | 14 ++++++++------ drivers/net/wireless/ath/ath10k/testmode.c | 14 -------------- drivers/net/wireless/ath/ath10k/wmi.c | 5 +++-- drivers/net/wireless/ath/ath10k/wow.c | 7 ++++--- 8 files changed, 39 insertions(+), 45 deletions(-) commit 453173550256542c20b24a8d85b806941b77ac76 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:45:05 2016 +0300 ath10k: move fw_version inside struct ath10k_fw_file Preparation for testmode.c to use ath10k_core_fetch_board_data_api_n(). Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 13 +++++++++---- drivers/net/wireless/ath/ath10k/core.h | 3 ++- drivers/net/wireless/ath/ath10k/testmode.c | 12 ++++++------ 3 files changed, 17 insertions(+), 11 deletions(-) commit 7ebf721d0d47150f6e327a6ae2692779495a2c2a Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:44:51 2016 +0300 ath10k: refactor firmware images to struct ath10k_fw_components To make it easier to share ath10k_core_fetch_board_data_api_n() with testmode.c refactor all firmware components to struct ath10k_fw_components. This structure will hold firmware related files, for example firmware-N.bin and board-N.bin. For firmware-N.bin create a new struct ath10k_fw_file which contains the actual firmware image as well as the parsed data from the image. Modify ath10k_core_start() to take struct ath10k_fw_components() as an argument which makes it possible in following patches to drop some ugly hacks from testmode.c. Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 176 +++++++++++++++-------------- drivers/net/wireless/ath/ath10k/core.h | 46 +++++--- drivers/net/wireless/ath/ath10k/debug.c | 28 +++-- drivers/net/wireless/ath/ath10k/mac.c | 3 +- drivers/net/wireless/ath/ath10k/swap.c | 22 ++-- drivers/net/wireless/ath/ath10k/testmode.c | 61 ++++++---- 6 files changed, 199 insertions(+), 137 deletions(-) commit 3fb55c79d092d085bddd4fc94f250acfc1275f3d Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 20 19:44:36 2016 +0300 ath10k: remove deprecated firmware API 1 support This has ben deprecated years ago, I haven't heard anyone using it since and most likely it won't even work anymore. So just remove all of it. Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 73 ---------------------------------- drivers/net/wireless/ath/ath10k/core.h | 3 -- drivers/net/wireless/ath/ath10k/hw.h | 12 ------ drivers/net/wireless/ath/ath10k/pci.c | 1 - drivers/net/wireless/ath/ath10k/wmi.c | 4 -- 5 files changed, 93 deletions(-) commit 1c9f47195ef83ffd59ff665f2006789c0610cff0 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Fri Apr 1 19:38:21 2016 -0300 [media] tw686x: Specify that the DMA is 32 bits Set vb2_queue.gfp_flags to GFP_DMA32. Otherwise it will start to create bounce buffers which is something you want to avoid since those are in limited supply. Without this patch, DMA scatter-gather may not work because machines can ran out of buffers easily. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/tw686x/tw686x-video.c | 1 + 1 file changed, 1 insertion(+) commit e3a900a8fae22949523e0b6c3f0626ce5f3f48c3 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Mon Mar 21 12:10:12 2016 -0300 [media] tw686x-kh: rename three functions to prevent clash with tw686x driver Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/tw686x-kh/tw686x-kh-core.c | 6 +++--- drivers/staging/media/tw686x-kh/tw686x-kh-video.c | 12 ++++++------ drivers/staging/media/tw686x-kh/tw686x-kh.h | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) commit 2e2dedb96ddd9e4f8d8a0330bc31ac56670a36b4 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Mon Mar 21 12:09:59 2016 -0300 [media] tw686x: add missing statics Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/tw686x/tw686x-video.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e4c32b495fd06831e3f1553a6ebac5c68431b2a8 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Mon Mar 21 08:17:14 2016 -0300 [media] tw686x-kh: add audio support to the TODO list The mainline tw686x driver also supports audio, that's missing here as well. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/tw686x-kh/TODO | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 304d2a7fc8acc1bb337596e0fc301092ea079b4d Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Mon Mar 21 08:07:44 2016 -0300 [media] tw686x-kh: specify that the DMA is 32 bits Set vb2_queue.gfp_flags to GFP_DMA32. Otherwise it will start to create bounce buffers which is something you want to avoid since those are in limited supply. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/tw686x-kh/tw686x-kh-video.c | 1 + 1 file changed, 1 insertion(+) commit 13431509a41889a70cc76b31180f63fd10d0a5b3 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 20 13:39:20 2016 -0300 [media] tw686x-kh: use the cached value the dma_requests field is cached, but cache is not used: drivers/staging/media/tw686x-kh/tw686x-kh-video.c: In function 'tw686x_video_irq': drivers/staging/media/tw686x-kh/tw686x-kh-video.c:622:6: warning: variable 'requests' set but not used [-Wunused-but-set-variable] u32 requests; ^ Use the cache instead, as it seems reading it needs to be done with spin lock taken. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/tw686x-kh/tw686x-kh-video.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de4a54c4dfaed0604565c1b27488dce56997acc0 Author: Mark Brown <broonie@kernel.org> Date: Thu Jan 21 20:19:41 2016 +0000 regulator: core: Use a bitfield for continuous_voltage_range Using a bitfield enables the compiler to lay out the structure more efficiently when we have other boolean flags since multiple values can be included in a single byte. Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/regulator/driver.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ae714c3b8e50a64d967188f3bc585bcd6a79539d Author: Mark Brown <broonie@kernel.org> Date: Tue Apr 19 18:19:08 2016 +0100 regulator: tps6524x: Fix broken use of spi_dev_get() The tps6524x driver uses spi_dev_get() to take a copy of the SPI device it uses but has no obvious reason to do so and never calls spi_dev_put() to release the reference. Fix this to just a straight copy. Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/tps6524x-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 704a84ccdbf19fdce9adfda0b936dfdcac52fa49 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Wed Mar 2 11:30:16 2016 -0300 [media] media: Support Intersil/Techwell TW686x-based video capture cards This commit introduces the support for the Techwell TW686x video capture IC. This hardware supports a few DMA modes, including scatter-gather and frame (contiguous). This commit makes little use of the DMA engine and instead has a memcpy based implementation. DMA frame and scatter-gather modes support may be added in the future. Currently supported chips: - TW6864 (4 video channels), - TW6865 (4 video channels, not tested, second generation chip), - TW6868 (8 video channels but only 4 first channels using built-in video decoder are supported, not tested), - TW6869 (8 video channels, second generation chip). [mchehab@osg.samsung.com: make checkpatch happy by using "unsigned int" instead of just "unsigned"] Cc: Krzysztof Halasa <khalasa@piap.pl> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> MAINTAINERS | 8 + drivers/media/pci/Kconfig | 1 + drivers/media/pci/Makefile | 1 + drivers/media/pci/tw686x/Kconfig | 18 + drivers/media/pci/tw686x/Makefile | 3 + drivers/media/pci/tw686x/tw686x-audio.c | 386 +++++++++++++ drivers/media/pci/tw686x/tw686x-core.c | 415 ++++++++++++++ drivers/media/pci/tw686x/tw686x-regs.h | 122 +++++ drivers/media/pci/tw686x/tw686x-video.c | 927 ++++++++++++++++++++++++++++++++ drivers/media/pci/tw686x/tw686x.h | 158 ++++++ 10 files changed, 2039 insertions(+) commit 0ff59f3190ba7b380ca4387dab5eb69d2b8f4d23 Author: Krzysztof Hałasa <khalasa@piap.pl> Date: Fri Mar 11 09:23:16 2016 -0300 [media] TW686x frame grabber driver A driver for Intersil/Techwell TW686x-based PCIe frame grabbers. [hans.verkuil@cisco.com: renamed staging tw686x to tw686x-kh to prevent naming conflicts] [hans.verkuil@cisco.com: don't build tw686x-kh if tw686x is already selected to prevent conflicts] [mchehab@osg.samsung.com: use "unsigned int" instead of just "unsigned" and add some whitespaces to make checkpatch happier] Signed-off-by: Krzysztof Halasa <khalasa@piap.pl> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/staging/media/Kconfig | 2 + drivers/staging/media/Makefile | 1 + drivers/staging/media/tw686x-kh/Kconfig | 17 + drivers/staging/media/tw686x-kh/Makefile | 3 + drivers/staging/media/tw686x-kh/TODO | 3 + drivers/staging/media/tw686x-kh/tw686x-kh-core.c | 140 ++++ drivers/staging/media/tw686x-kh/tw686x-kh-regs.h | 103 +++ drivers/staging/media/tw686x-kh/tw686x-kh-video.c | 820 ++++++++++++++++++++++ drivers/staging/media/tw686x-kh/tw686x-kh.h | 118 ++++ 9 files changed, 1207 insertions(+) commit 67d1c21e37301ca3cea3705951950ce21f2723e1 Author: Guneshwor Singh <guneshwor.o.singh@intel.com> Date: Tue Apr 19 13:12:50 2016 +0800 ASoC: topology: Set CPU DAI name and enable DPCM by default for FE link When creating a FE link, the cpu_dai_name will come from topology and dpcm will be enabled by default. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/soc-topology.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 74dde20c2d6b360e12c17f20db7735bb5e8115ef Merge: b84fff5 2f0ad49 305e902 Author: Mark Brown <broonie@kernel.org> Date: Wed Apr 20 17:21:28 2016 +0100 Merge branches 'topic/dai-link' and 'topic/find-dai' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-topology commit 305e9020f09d28560373c0112682e6fd11e909f6 Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Tue Apr 19 13:12:25 2016 +0800 ASoC: Export snd_soc_find_dai() This API can be used by topology to find an existing BE dai by name and further configure it. Topology will also check DAI ID to avoid wrong match. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/soc.h | 3 +++ sound/soc/soc-core.c | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) commit b84fff5afb16627a8973256992f3951ac3e90d84 Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Tue Apr 19 13:12:43 2016 +0800 ASoC: topology: Set the link ID when creating a FE DAI link Topology will set the link's generic id when creating a FE link. Device drivers can check the id for link specific initialization. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/uapi/sound/asoc.h | 2 +- sound/soc/soc-topology.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) commit 5ed470feb9a121582dbd455c72b133dc1a856a0a Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 6 10:55:25 2016 -0300 [media] media: Improve documentation for link_setup/link_modify Those callbacks are called with the media_device.graph_mutex held. Add a note about that, as the code called by those notifiers should not be touching in the mutex. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/media/media-device.h | 3 ++- include/media/media-entity.h | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) commit 2f0ad49104cbb19db24442af736614659363d2ab Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Tue Apr 19 13:12:35 2016 +0800 ASoC: Change DAI link's be_id to a generic id The generic ID can be used by topology: - Toplogy can create FE links and set their ID, machine drivers will be notified and check this ID for machine-specific init. - Toplogy can use the ID to find existing BE & CC links and further configure them. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/soc.h | 2 +- sound/soc/intel/boards/broadwell.c | 2 +- sound/soc/intel/boards/bytcr_rt5640.c | 2 +- sound/soc/intel/boards/bytcr_rt5651.c | 2 +- sound/soc/intel/boards/cht_bsw_max98090_ti.c | 2 +- sound/soc/intel/boards/cht_bsw_rt5645.c | 2 +- sound/soc/intel/boards/cht_bsw_rt5672.c | 2 +- sound/soc/intel/boards/haswell.c | 2 +- sound/soc/intel/boards/skl_nau88l25_max98357a.c | 12 ++++++------ sound/soc/intel/boards/skl_nau88l25_ssm4567.c | 12 ++++++------ sound/soc/intel/boards/skl_rt286.c | 10 +++++----- 11 files changed, 25 insertions(+), 25 deletions(-) commit e2c91d4d78ee3a69ad634bc7ef90688704baab9d Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 6 10:55:24 2016 -0300 [media] media-device: get rid of the spinlock Right now, the lock schema for media_device struct is messy, since sometimes, it is protected via a spin lock, while, for media graph traversal, it is protected by a mutex. Solve this conflict by always using a mutex. As a side effect, this prevents a bug when the media notifiers is called at atomic context, while running the notifier callback: BUG: sleeping function called from invalid context at mm/slub.c:1289 in_atomic(): 1, irqs_disabled(): 0, pid: 3479, name: modprobe 4 locks held by modprobe/3479: #0: (&dev->mutex){......}, at: [<ffffffff81ce8933>] __driver_attach+0xa3/0x160 #1: (&dev->mutex){......}, at: [<ffffffff81ce8941>] __driver_attach+0xb1/0x160 #2: (register_mutex#5){+.+.+.}, at: [<ffffffffa10596c7>] usb_audio_probe+0x257/0x1c90 [snd_usb_audio] #3: (&(&mdev->lock)->rlock){+.+.+.}, at: [<ffffffffa0e6051b>] media_device_register_entity+0x1cb/0x700 [media] CPU: 2 PID: 3479 Comm: modprobe Not tainted 4.5.0-rc3+ #49 Hardware name: /NUC5i7RYB, BIOS RYBDWi35.86A.0350.2015.0812.1722 08/12/2015 0000000000000000 ffff8803b3f6f288 ffffffff81933901 ffff8803c4bae000 ffff8803c4bae5c8 ffff8803b3f6f2b0 ffffffff811c6af5 ffff8803c4bae000 ffffffff8285d7f6 0000000000000509 ffff8803b3f6f2f0 ffffffff811c6ce5 Call Trace: [<ffffffff81933901>] dump_stack+0x85/0xc4 [<ffffffff811c6af5>] ___might_sleep+0x245/0x3a0 [<ffffffff811c6ce5>] __might_sleep+0x95/0x1a0 [<ffffffff8155aade>] kmem_cache_alloc_trace+0x20e/0x300 [<ffffffffa0e66e3d>] ? media_add_link+0x4d/0x140 [media] [<ffffffffa0e66e3d>] media_add_link+0x4d/0x140 [media] [<ffffffffa0e69931>] media_create_pad_link+0xa1/0x600 [media] [<ffffffffa0fe11b3>] au0828_media_graph_notify+0x173/0x360 [au0828] [<ffffffffa0e68a6a>] ? media_gobj_create+0x1ba/0x480 [media] [<ffffffffa0e606fb>] media_device_register_entity+0x3ab/0x700 [media] Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-device.c | 39 +++++++++++++-------------------------- drivers/media/media-entity.c | 16 ++++++++-------- include/media/media-device.h | 6 +----- 3 files changed, 22 insertions(+), 39 deletions(-) commit 1a4d5a3e2caacd104e82ebd3c4964e681de1aa8a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 20 17:32:19 2016 +0200 regulator: ti-abb: DT spelling s/#{address,size}-cell/#{address,size}-cells/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/regulator/ti-abb-regulator.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 8305216ff831ebc47d6335f577448e6c0453fc82 Author: Dave Gordon <david.s.gordon@intel.com> Date: Tue Apr 12 14:46:16 2016 +0100 drm/i915: check for ERR_PTR from i915_gem_object_pin_map() The newly-introduced function i915_gem_object_pin_map() returns an ERR_PTR (not NULL) if the pin-and-map opertaion fails, so that's what we must check for. And it's nicer not to assign such a pointer-or-error to a structure being filled in until after it's been validated, so we should keep it local and avoid exporting a bogus pointer. Also, for clarity and symmetry, we should clear 'virtual_start' along with 'vma' when unmapping a ringbuffer. Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_drv.h | 6 ++++-- drivers/gpu/drm/i915/intel_ringbuffer.c | 15 +++++++++------ 2 files changed, 13 insertions(+), 8 deletions(-) commit cca1d81574d266d4a3aa33f3947297564525e127 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 20 07:31:31 2016 -0700 net: fix HAVE_EFFICIENT_UNALIGNED_ACCESS typos HAVE_EFFICIENT_UNALIGNED_ACCESS needs CONFIG_ prefix. Also add a comment in nla_align_64bit() explaining we have to add a padding if current skb->data is aligned, as it certainly can be confusing. Fixes: 35c5845957c7 ("net: Add helpers for 64-bit aligning netlink attributes.") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) commit b84e93077fe926bc65e23d887b54fc46be60b76e Author: Peter Heise <mail@pheise.de> Date: Wed Apr 20 09:08:29 2016 +0200 net/hsr: Fixed version field in ENUM New field (IFLA_HSR_VERSION) was added in the middle of an existing ENUM and would break kernel ABI, therefore moved to the end. Reported by Stephen Hemminger. Signed-off-by: Peter Heise <peter.heise@airbus.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c7c999cb18da88a881e10e07f0724ad0bfaff770 Author: Takashi Iwai <tiwai@suse.de> Date: Thu Apr 14 17:32:19 2016 +0200 Bluetooth: vhci: Fix race at creating hci device hci_vhci driver creates a hci device object dynamically upon each HCI_VENDOR_PKT write. Although it checks the already created object and returns an error, it's still racy and may build multiple hci_dev objects concurrently when parallel writes are performed, as the device tracks only a single hci_dev object. This patch introduces a mutex to protect against the concurrent device creations. Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/hci_vhci.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) commit 60f5f5d3a106dc5385b39348d13b20b15ac9cbf9 Author: Alexander Aring <aar@pengutronix.de> Date: Tue Apr 19 15:34:22 2016 +0200 at86rf230: increase sleep to off timings I expierenced when setting channel while sleep mode it didn't changed the channel inside the hardware registers. Then I got another report of an user which has similar issues. I increased the sleep to off state change timing, which is according at86rf233 at maximum 1000 us. After this change I got no similar effects again. I tried another option to wait on AWAKE_END irq, which can be used to wait until the transceiver is awaked. I tested it and the IRQ took 4 seconds after starting state change. I don't believe it takes 4 seconds to go into the TRX_OFF state from SLEEP state. The alternative is to increase the timings which seems to work. Cc: Oleg Hahm <oliver.hahm@inria.fr> Signed-off-by: Alexander Aring <aar@pengutronix.de> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/at86rf230.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 86e06cc0c0ecf3fdfe04ff48fccb34891767d514 Author: Dave Gordon <david.s.gordon@intel.com> Date: Tue Apr 19 16:08:36 2016 +0100 drm/i915/guc: local optimisations and updating comments Tidying up guc_init_proc_desc() and adding commentary to the client structure after the recent change in GuC page mapping strategy. Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461078516-28678-1-git-send-email-david.s.gordon@intel.com Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_guc_submission.c | 38 ++++++++++++++---------------- drivers/gpu/drm/i915/intel_guc.h | 23 ++++++++++++++++++ 2 files changed, 41 insertions(+), 20 deletions(-) commit a5916e8f5406a48597971071b7cd94b688e72a9c Author: Alex Dai <yu.dai@intel.com> Date: Tue Apr 19 16:08:35 2016 +0100 drm/i915/guc: drop cached copy of 'wq_head' Now that we keep the GuC client process descriptor permanently mapped, we don't really need to keep a local copy of the GuC's work-queue-head. So we can simplify the code a little by not doing this. Signed-off-by: Alex Dai <yu.dai@intel.com> Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_guc_submission.c | 16 ++++------------ drivers/gpu/drm/i915/intel_guc.h | 2 +- 2 files changed, 5 insertions(+), 13 deletions(-) commit 0d92a6a4f629c68d5df36c5a84f647312db04e95 Author: Dave Gordon <david.s.gordon@intel.com> Date: Tue Apr 19 16:08:34 2016 +0100 drm/i915/guc: keep GuC doorbell & process descriptor mapped in kernel Don't use kmap_atomic() for doorbell & process descriptor access. This patch fixes the BUG shown below, where the thread could sleep while holding a kmap_atomic mapping. In order not to need to call kmap_atomic() in this code path, we now set up a permanent kernel mapping of the shared doorbell and process-descriptor page, and use that in all doorbell and process-descriptor related code. BUG: scheduling while atomic: gem_close_race/1941/0x00000002 Modules linked in: hid_generic usbhid i915 asix usbnet libphy mii i2c_algo_bit drm_kms_helper cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops cfbcopyarea drm coretemp i2c_hid hid video pinctrl_sunrisepoint pinctrl_intel acpi_pad nls_iso8859_1 e1000e ptp psmouse pps_core ahci libahci CPU: 0 PID: 1941 Comm: gem_close_race Tainted: G U 4.4.0-160121+ #123 Hardware name: Intel Corporation Skylake Client platform/Skylake AIO DDR3L RVP10, BIOS SKLSE2R1.R00.X100.B01.1509220551 09/22/2015 0000000000013e40 ffff880166c27a78 ffffffff81280d02 ffff880172c13e40 ffff880166c27a88 ffffffff810c203a ffff880166c27ac8 ffffffff814ec808 ffff88016b7c6000 ffff880166c28000 00000000000f4240 0000000000000001 Call Trace: [<ffffffff81280d02>] dump_stack+0x4b/0x79 [<ffffffff810c203a>] __schedule_bug+0x41/0x4f [<ffffffff814ec808>] __schedule+0x5a8/0x690 [<ffffffff814ec927>] schedule+0x37/0x80 [<ffffffff814ef3fd>] schedule_hrtimeout_range_clock+0xad/0x130 [<ffffffff81090be0>] ? hrtimer_init+0x10/0x10 [<ffffffff814ef3f1>] ? schedule_hrtimeout_range_clock+0xa1/0x130 [<ffffffff814ef48e>] schedule_hrtimeout_range+0xe/0x10 [<ffffffff814eef9b>] usleep_range+0x3b/0x40 [<ffffffffa01ec109>] i915_guc_wq_check_space+0x119/0x210 [i915] [<ffffffffa01da47c>] intel_logical_ring_alloc_request_extras+0x5c/0x70 [i915] [<ffffffffa01cdbf1>] i915_gem_request_alloc+0x91/0x170 [i915] [<ffffffffa01c1c07>] i915_gem_do_execbuffer.isra.25+0xbc7/0x12a0 [i915] [<ffffffffa01cb785>] ? i915_gem_object_get_pages_gtt+0x225/0x3c0 [i915] [<ffffffffa01d1fb6>] ? i915_gem_pwrite_ioctl+0xd6/0x9f0 [i915] [<ffffffffa01c2e68>] i915_gem_execbuffer2+0xa8/0x250 [i915] [<ffffffffa00f65d8>] drm_ioctl+0x258/0x4f0 [drm] [<ffffffffa01c2dc0>] ? i915_gem_execbuffer+0x340/0x340 [i915] [<ffffffff8111590d>] do_vfs_ioctl+0x2cd/0x4a0 [<ffffffff8111eac2>] ? __fget+0x72/0xb0 [<ffffffff81115b1c>] SyS_ioctl+0x3c/0x70 [<ffffffff814effd7>] entry_SYSCALL_64_fastpath+0x12/0x6a ------------[ cut here ]------------ v4: Only tear down doorbell & kunmap() client object if we actually succeeded in allocating a client object (Tvrtko Ursulin) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93847 Original-version-by: Alex Dai <yu.dai@intel.com> Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Cc: Tvtrko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_guc_submission.c | 66 +++++++++++++----------------- drivers/gpu/drm/i915/intel_guc.h | 2 + 2 files changed, 30 insertions(+), 38 deletions(-) commit 2e4682ba2ed79d8082b78d292b3b80f54d970b7a Author: Paolo Bonzini <pbonzini@redhat.com> Date: Thu Mar 10 16:30:22 2016 +0100 KVM: add missing memory barrier in kvm_{make,check}_request kvm_make_request and kvm_check_request imply a producer-consumer relationship; add implicit memory barriers to them. There was indeed already a place that was adding an explicit smp_mb() to order between kvm_check_request and the processing of the request. That memory barrier can be removed (as an added benefit, kvm_check_request can use smp_mb__after_atomic which is free on x86). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/irq_comm.c | 3 --- include/linux/kvm_host.h | 11 +++++++++++ 2 files changed, 11 insertions(+), 3 deletions(-) commit 46971a2f59f135341f8912f516540fef6890d4df Author: Xiao Guangrong <guangrong.xiao@linux.intel.com> Date: Fri Mar 25 21:19:38 2016 +0800 KVM: MMU: skip obsolete sp in for_each_gfn_*() The obsolete sp should not be used on current vCPUs and should not hurt vCPU's running, so skip it from for_each_gfn_sp() and for_each_gfn_indirect_valid_sp() The side effort is we will double check role.invalid in kvm_mmu_get_page() but i think it is okay as role is well cached Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/kvm/mmu.c | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) commit c54cdf141c40a5115774e91fc947c34e91df0259 Author: Liang Chen <liangchen.linux@gmail.com> Date: Wed Mar 16 19:33:16 2016 +0800 KVM: x86: optimize steal time calculation Since accumulate_steal_time is now only called in record_steal_time, it doesn't quite make sense to put the delta calculation in a separate function. The function could be called thousands of times before guest enables the steal time MSR (though the compiler may optimize out this function call). And after it's enabled, the MSR enable bit is tested twice every time. Removing the accumulate_steal_time function also avoids the necessity of having the accum_steal field. Signed-off-by: Liang Chen <liangchen.linux@gmail.com> Signed-off-by: Gavin Guo <gavin.guo@canonical.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> arch/x86/include/asm/kvm_host.h | 1 - arch/x86/kvm/x86.c | 19 +++---------------- 2 files changed, 3 insertions(+), 17 deletions(-) commit 05b1159e641fa45e885aec8bf8e515117c8977d9 Merge: 5e1b59a 6d28f78 Author: Radim Krčmář <rkrcmar@redhat.com> Date: Wed Apr 20 15:28:51 2016 +0200 Merge tag 'kvms390-20160420' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into next KVM/s390 patches for 4.7: - improve perf output - cleanup and a new feature in the floating interrupt controller (FLIC) commit 71daabca344b503f98c59e4bdd53a818cd01f2af Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Apr 14 14:20:19 2016 +0800 dt-bindings: modify document of Rockchip power domains Rockchip Socs contain quality of service (qos) blocks managing priority, bandwidth, etc of the connection of each domain to the interconnect. These blocks loose state when their domain gets disabled and therefore need to be saved when disabling and restored when enabling a power-domain. These qos blocks also are similar over all currently available Rockchip SoCs. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> .../devicetree/bindings/soc/rockchip/power_domain.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 1bec9b0bda3d570cb7ff3a69e44917facf7e8820 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 20 12:09:52 2016 +0100 drm/i915/shrinker: Only shmemfs objects are backed by swap Since we can only swap out shmemfs objects, those are the only ones that can influence the ability of the shrinker to free pages. Currently, all non-shmemfs objects have a raised pages_pin_count to protect them from the shrinker, so this just makes the logic for can_release_pages() clearer (and safer in future so that we don't over estimate our ability to free up pages from future non-swappable objects). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461150592-27818-3-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> drivers/gpu/drm/i915/i915_gem_shrinker.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 1768d4550c055bfd2d4b44763fcb9230f41e593b Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 20 12:09:51 2016 +0100 drm/i915/shrinker: Report "unevictable" pages Inside the shrinker we call can_release_pages() to indicate whether or not we can make forward progress in freeing up memory by unbinding that object. When adding our report to oom, we should be using the same logic. Whilst here, change the reporting from bytes to pages so that it looks smaller to the user!, is consistent with the neighbouring oom report itself which displays counts in pages, and makes the unsigned long overflow less likely. v2: Split oversized format string into two lines Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461150592-27818-2-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_gem_shrinker.c | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) commit ca61d4a425f2e23e870e027f2450fb126a1f2103 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 20 12:09:50 2016 +0100 drm/i915/shrinker: Only report objects with extra pinned pages as pinned When iterating over the bound list, we expect all objects there to have their pages pinned (by the bound VMA). So only report those objects with additional pin count on their pages as "pinned". These should be those objects used for display and hardware access. Reported-by: Akash Goel <akash.goel@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Akash Goel <akash.goel@intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461150592-27818-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_shrinker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6d28f789bf81540d4069342b1a28bfd41dab38a3 Author: Halil Pasic <pasic@linux.vnet.ibm.com> Date: Mon Jan 25 19:10:40 2016 +0100 KVM: s390: add clear I/O irq operation for FLIC Introduce a FLIC operation for clearing I/O interrupts for a subchannel. Rationale: According to the platform specification, pending I/O interruption requests have to be revoked in certain situations. For instance, according to the Principles of Operation (page 17-27), a subchannel put into the installed parameters initialized state is in the same state as after an I/O system reset (just parameters possibly changed). This implies that any I/O interrupts for that subchannel are no longer pending (as I/O system resets clear I/O interrupts). Therefore, we need an interface to clear pending I/O interrupts. Signed-off-by: Halil Pasic <pasic@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Documentation/virtual/kvm/devices/s390_flic.txt | 6 ++++++ arch/s390/include/uapi/asm/kvm.h | 1 + arch/s390/kvm/interrupt.c | 25 +++++++++++++++++++++++++ 3 files changed, 32 insertions(+) commit dad7eefbd048a2f44c990303751159671e988d13 Author: Halil Pasic <pasic@linux.vnet.ibm.com> Date: Thu Feb 25 13:26:32 2016 +0100 KVM: s390: document FLIC behavior on unsupported FLIC behavior deviates from the API documentation in reporting EINVAL instead of ENXIO for KVM_SET_DEVICE_ATTR/KVM_GET_DEVICE_ATTR when the group or attribute is unknown/unsupported. Unfortunately this can not be fixed for historical reasons. Let us at least have it documented. Signed-off-by: Halil Pasic <pasic@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Documentation/virtual/kvm/devices/s390_flic.txt | 6 ++++++ 1 file changed, 6 insertions(+) commit 4f1298584eb60fc7172851f75e10f7d6c33a2628 Author: Halil Pasic <pasic@linux.vnet.ibm.com> Date: Thu Feb 25 12:44:17 2016 +0100 KVM: s390: implement has_attr for FLIC HAS_ATTR is useful for determining the supported attributes; let's implement it. Signed-off-by: Halil Pasic <pasic@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> arch/s390/kvm/interrupt.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 9f10b79dad6030b71e1f3cb0d7edbe6f4d943d1a Author: Christian Borntraeger <borntraeger@de.ibm.com> Date: Tue Mar 15 14:30:23 2016 +0100 KVM: s390/perf: provide additional sigp events perf kvm stat can decode sigp events, let's make the list complete by adding the missing ones. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> arch/s390/include/uapi/asm/sie.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 601bac7638fa693204dc70035d2651474704967c Author: John Crispin <blogic@openwrt.org> Date: Thu Apr 7 20:18:35 2016 +0200 ARM: mediatek: enable gpt6 on boot up to make arch timer work on mt7623 GPT6 needs to be enabled on MT7623 for the arch timer to work. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> arch/arm/mach-mediatek/mediatek.c | 1 + 1 file changed, 1 insertion(+) commit ba34d58c5e86c27accb3133fa991cfb6c848c58e Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Apr 19 14:40:37 2016 -0300 drm: probe_helper: Hide ugly ifdef Push the ifdef to the drm_edid.h and create a stub, for the DRM_LOAD_EDID_FIRMWARE=n case. This removes some clutter in the code, making it more readable. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461087638-16959-1-git-send-email-ezequiel@vanguardiasur.com.ar drivers/gpu/drm/drm_probe_helper.c | 2 -- include/drm/drm_edid.h | 8 ++++++++ 2 files changed, 8 insertions(+), 2 deletions(-) commit 610175b7972afc78f0e4a622a17a32b1fccad4bf Author: Sascha Hauer <s.hauer@pengutronix.de> Date: Fri Feb 19 08:18:46 2016 +0100 dt-bindings: MediaTek: Add binding document for the AUXADC Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> .../devicetree/bindings/soc/mediatek/auxadc.txt | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit 748c7d4de46a18818b2736dce55becad9ca6c691 Author: Sascha Hauer <s.hauer@pengutronix.de> Date: Mon Nov 30 12:42:33 2015 +0100 ARM64: dts: mt8173: Add thermal/auxadc device nodes This adds the thermal controller and auxadc nodes to the Mediatek MT8173 dtsi file. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Reviewed-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Eduardo Valentin <edubezval@gmail.com> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> arch/arm64/boot/dts/mediatek/mt8173.dtsi | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit d63c25e4245aaf9507bf9484b58910bd89c76ef3 Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Tue Apr 19 15:24:53 2016 +0300 drm: rcar-du: Use generic drm_connector_register_all() helper Now that a generic drm_connector_register_all() helper exists we may safely substitute it for the driver-specific implementation of connectors plugging in sysfs. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: David Airlie <airlied@linux.ie> Cc: linux-renesas-soc@vger.kernel.org Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461068693-11260-4-git-send-email-abrodkin@synopsys.com drivers/gpu/drm/rcar-du/rcar_du_drv.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit b3383f75fc44128ee748938dd70f353aa0001f78 Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Tue Apr 19 15:24:52 2016 +0300 drm: atmel_hldc: Use generic drm_connector_register_all() helper This driver used to have its own implementation of connector_register_all() which actually was taken as a prototype of drm_connector_register_all(). Now when drm_connector_register_all() exists reusing it here. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: David Airlie <airlied@linux.ie> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461068693-11260-3-git-send-email-abrodkin@synopsys.com drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 30 +--------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) commit 54d2c2da0946368b96b63e6daed7920f3681243e Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Tue Apr 19 15:24:51 2016 +0300 drm: Introduce drm_connector_register_all() helper As a pair to already existing drm_connector_unregister_all() we're adding generic implementation of what is already done in some drivers. Once this helper is implemented we'll be ready to switch existing driver-specific implementations with the generic one. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: David Airlie <airlied@linux.ie> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1461068693-11260-2-git-send-email-abrodkin@synopsys.com drivers/gpu/drm/drm_crtc.c | 40 ++++++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/drm_drv.c | 6 +++++- include/drm/drm_crtc.h | 3 ++- 3 files changed, 47 insertions(+), 2 deletions(-) commit 643d703d2d2dbf8e2f16efa0a6a32b1eca101d02 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:37 2016 +0100 arm64: compat: Check for AArch32 state Make sure we have AArch32 state available for running COMPAT binaries and also for switching the personality to PER_LINUX32. Signed-off-by: Yury Norov <ynorov@caviumnetworks.com> [ Added cap bit, checks for HWCAP, personality ] Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/elf.h | 3 ++- arch/arm64/kernel/cpufeature.c | 7 +++++-- arch/arm64/kernel/sys.c | 10 ++++++++++ 3 files changed, 17 insertions(+), 3 deletions(-) commit 042446a31e3803d81c7e618dd80928dc3dce70c5 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:36 2016 +0100 arm64: cpufeature: Track 32bit EL0 support Add cpu_hwcap bit for keeping track of the support for 32bit EL0. Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/cpufeature.h | 8 +++++++- arch/arm64/kernel/cpufeature.c | 9 +++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) commit a6dc3cd718ec2a19b8ca812087666899852af78f Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:35 2016 +0100 arm64: cpufeature: Check availability of AArch32 On ARMv8 support for AArch32 state is optional. Hence it is not safe to check the AArch32 ID registers for sanity, which could lead to false warnings. This patch makes sure that the AArch32 state is implemented before we keep track of the 32bit ID registers. As per ARM ARM (D.1.21.2 - Support for Exception Levels and Execution States, DDI0487A.h), checking the support for AArch32 at EL0 is good enough to check the support for AArch32 (i.e, AArch32 at EL1 => AArch32 at EL0, but not vice versa). Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/cpufeature.c | 86 +++++++++++++++++++++++------------------- arch/arm64/kernel/cpuinfo.c | 37 +++++++++--------- 2 files changed, 67 insertions(+), 56 deletions(-) commit c80aba803a9aa131f997f62a71ab453e456d08a8 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:34 2016 +0100 arm64: Add helpers for detecting AArch32 support at EL0 Adds a helper to extract the support for AArch32 at EL0 Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/cpufeature.h | 7 +++++++ arch/arm64/include/asm/sysreg.h | 1 + 2 files changed, 8 insertions(+) commit 752835019c15f720a51433e6bc1c5c515c01d1a2 Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:33 2016 +0100 arm64: HWCAP: Split COMPAT HWCAP table entries In order to handle systems which do not support 32bit at EL0, split the COMPAT HWCAP entries into a separate table which can be processed, only if the support is available. Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/cpufeature.c | 104 ++++++++++++++++++++++------------------- 1 file changed, 56 insertions(+), 48 deletions(-) commit f3efb67590e8f68918a7a63ab0d2debee04fba9e Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Mon Apr 18 10:28:32 2016 +0100 arm64: hwcaps: Cleanup naming We use hwcaps for referring to ELF hwcaps capability information. However this can be confusing with 'cpu_hwcaps' which stands for the CPU capability bit field. This patch cleans up the names to make it a bit more readable. Tested-by: Yury Norov <ynorov@caviumnetworks.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/cpufeature.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 2ff4936c1d68060b080aac49ec622b047f9e6c45 Author: Mark Rutland <mark.rutland@arm.com> Date: Tue Apr 19 10:31:19 2016 +0100 arm64: asm: remove unused push/pop macros We haven't used the push/pop macros for a while now, as it's typically better to use immediate offsets for batches of accesses to the stack, as we now do in the entry assembly for the kernel and hyp code. Remove the unused macros. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Cc: James Morse <james.morse@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/assembler.h | 12 ------------ 1 file changed, 12 deletions(-) commit 8ee708792e1ccda683ec9cce9fab3b25ece0eb60 Author: Yang Shi <yang.shi@linaro.org> Date: Mon Apr 18 11:16:14 2016 -0700 arm64: Kconfig: remove redundant HAVE_ARCH_TRANSPARENT_HUGEPAGE definition HAVE_ARCH_TRANSPARENT_HUGEPAGE has been defined in arch/Kconfig already, the ARM64 version is identical with it and the default value is Y. So remove the redundant definition and just select it under CONFIG_ARM64. Signed-off-by: Yang Shi <yang.shi@linaro.org> [will: sort into alphabetical order whilst I'm resolving conflicts] Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 060a1d6461ebed23463262365fe41556e8a5cfc7 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:15 2016 +0100 soc: mediatek: PMIC wrap: add MT2701/7623 support Add the registers, callbacks and data structures required to make the wrapper work on MT2701 and MT7623. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 154 +++++++++++++++++++++++++++++++++++ 1 file changed, 154 insertions(+) commit 5ae48040aa479e9bb4f2e4630867725edca1a1c3 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:14 2016 +0100 soc: mediatek: PMIC wrap: add mt6323 slave support Add support for MT6323 slaves. This PMIC can be found on MT2701 and MT7623 EVB. The only function that we need to touch is pwrap_init_cipher(). Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 43 ++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit b28d78cd1812e4c65063ff6db9c7f4ab213e75d8 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:13 2016 +0100 soc: mediatek: PMIC wrap: add a slave specific struct This patch adds a new struct pwrap_slv_type that we use to store the slave specific data. The patch adds 2 new helper functions to access the dew registers. The slave type is looked up via the wrappers child node. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 159 ++++++++++++++++++++++++----------- 1 file changed, 112 insertions(+), 47 deletions(-) commit 25269cefb691d324a3fe2be4d2a7b81f6a733996 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:12 2016 +0100 soc: mediatek: PMIC wrap: remove pwrap_is_mt8135() and pwrap_is_mt8173() With more SoCs being added the list of helper functions like these would grow. To mitigate this problem we remove the existing helpers and change the code to test against the pmic type stored inside the pmic specific datastructure that our context structure points at. There is one usage of pwrap_is_mt8135() that is ambiguous as the test should not be dependent on mt8135, but rather on the existence of a bridge. Add a new element to pmic_wrapper_type to indicate if a bridge is present and use this where appropriate. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) commit 95b25c589158d97fbc6d5504b434aef263798fa7 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:11 2016 +0100 soc: mediatek: PMIC wrap: move wdt_src into the pmic_wrapper_type struct Different SoCs will use different bitmask for the wdt_src. This patch defines the bitmask in the pmic_wrapper_type struct. This allows us to support new SoCs with a different bitmask to the one currently used. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 174f7b4ce15f9edd77caac67a82c686c54788485 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:10 2016 +0100 soc: mediatek: PMIC wrap: SPI_WRITE needs a different bitmask for MT2701/7623 Different SoCs will use different bitmask for the SPI_WRITE command. This patch defines the bitmask in the pmic_wrapper_type struct. This allows us to support new SoCs with a different bitmask to the one currently used. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit e5eef49bc34b2adda3d3d0549d92a7f252130e79 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:09 2016 +0100 soc: mediatek: PMIC wrap: WRAP_INT_EN needs a different bitmask for MT2701/7623 MT2701 and MT7623 use a different bitmask for PWRAP_INT_EN. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 41c11f32d86ac1b64c78b827f977432df4934147 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:08 2016 +0100 soc: mediatek: PMIC wrap: split SoC specific init into callback This patch moves the SoC specific wrapper init code into separate callback to avoid pwrap_init() getting too large. This is done by adding a new element called init_special to pmic_wrapper_type. Each currently supported SoC gets its own version of the callback and we copy the code that was previously inside pwrap_init() to these new callbacks. Finally we point the 2 instances of pmic_wrapper_type at the 2 new functions. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 67 ++++++++++++++++++++++-------------- 1 file changed, 42 insertions(+), 25 deletions(-) commit a397845338af260658f55b2ba73834940244cf6d Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:07 2016 +0100 soc: mediatek: PMIC wrap: add wrapper callbacks for init_reg_clock Split init_reg_clock up into SoC specific callbacks. The patch also reorders the code to avoid the need for callback function prototypes. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 70 +++++++++++++++++++----------------- 1 file changed, 38 insertions(+), 32 deletions(-) commit 9bebedb054f98b70c798423cba6d9ba903b27d63 Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:06 2016 +0100 soc: mediatek: PMIC wrap: don't duplicate the wrapper data As we add support for more devices struct pmic_wrapper_type will grow and we do not really want to start duplicating all the elements in struct pmic_wrapper. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> drivers/soc/mediatek/mtk-pmic-wrap.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit e16cb8c23b51faf23a120feac149e10423b2e37d Author: John Crispin <blogic@openwrt.org> Date: Fri Feb 19 09:44:05 2016 +0100 dt-bindings: ARM: Mediatek: add MT2701/7623 string to the PMIC wrapper doc Signed-off-by: John Crispin <blogic@openwrt.org> Acked-by: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> Documentation/devicetree/bindings/soc/mediatek/pwrap.txt | 1 + 1 file changed, 1 insertion(+) commit f74418a400c62f382228842fd0ce8a05f9069d8c Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:52 2016 +0200 drm/vma_manage: Drop has_offset It's racy, creating mmap offsets is a slowpath, so better to remove it to avoid drivers doing broken things. The only user is i915, and it's ok there because everything (well almost) is protected by dev->struct_mutex in i915-gem. While at it add a note in the create_mmap_offset kerneldoc that drivers must release it again. And then I also noticed that drm_gem_object_release entirely lacks kerneldoc. Cc: David Herrmann <dh.herrmann@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-14-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_gem.c | 17 +++++++++++++++++ drivers/gpu/drm/i915/i915_gem.c | 3 --- include/drm/drm_vma_manager.h | 15 +-------------- 3 files changed, 18 insertions(+), 17 deletions(-) commit 0797ac61810b9b9938516ad9c92701d1639a0867 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:51 2016 +0200 drm/vgem: Drop dev->struct_mutex With the previous two changes it doesn't protect anything any more. v2: Use _unlocked unreference variant. v3: Appease gcc noise. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-13-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/vgem/vgem_drv.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) commit 7f340a26f4769a49fb51bfc023ca651dfe16042e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:50 2016 +0200 drm/vgem: Move get_pages to gem_create vgem doesn't have a shrinker or anything like that and drops backing storage only at object_free time. There's no use in trying to be clever and allocating backing storage delayed, it only causes trouble by requiring locking. Instead grab pages when we allocate the object right away. v2: Fix compiling. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-12-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/vgem/vgem_drv.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit e34274fd2aa84fb4b609e26af18507449e8feaca Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:49 2016 +0200 drm/vgem: Simplify dumb_map The offset manager already checks for existing offsets internally, while holding suitable locks. We can drop this check. v2: Fix title (Emil). Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-11-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/vgem/vgem_drv.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 2f42420084a7f79400700b2362ba802a824b8072 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:48 2016 +0200 drm/exynos: drop struct_mutex from fbdev setup Doesn't protect anything at all, and probably just here because a long time ago dev->struct_mutex was required to allocate gem objects. With this patch exynos is completely struct_mutex free! Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-10-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit 6c991a220873ede48ba735d4fb8e7bc780829f5e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:47 2016 +0200 drm/exynos: drop struct_mutex from exynos_drm_gem_get_ioctl The only things this protects is reading ->flags and ->size, both of which are invariant over the lifetime of an exynos gem bo. So no locking needed at all (besides that, nothing protects the writers anyway). Aside: exynos_gem_obj->size is redundant with exynos_gem_obj->base.size and probably should be removed. v2: Use _unlocked unreference (Daniel Stone). Cc: Daniel Stone <daniel@fooishbar.org> Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-9-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/exynos/exynos_drm_gem.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 8e97d9ef362e65f2533366527cdafa1842dab201 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:46 2016 +0200 drm/exynos: drop struct_mutex from exynos_gem_map_sgt_with_dma The sg table isn't refcounted, there's no corresponding locking for unmapping and drm_map_sg is ok with being called concurrently. So drop the locking since it doesn't protect anything. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-8-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/exynos/exynos_drm_gem.c | 4 ---- 1 file changed, 4 deletions(-) commit 91263622f1184b7650cac10f70b08aa7f142f900 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:45 2016 +0200 drm/exynos: Drop dev->struct_mutex from mmap offset function Simply forgotten about this when I was doing my general cleansing of simple gem mmap offset functions. There's nothing but core functions called here, and they all have their own protection already. Aside: DRM_ERROR for userspace controlled input isn't great, but that's for another patch. v2: Use _unlocked unreference (Daniel Stone). Cc: Daniel Stone <daniel@fooishbar.org> Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-7-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/exynos/exynos_drm_gem.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit ca25d6b08f3351c4e655a6ef70f19da6569312ec Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:44 2016 +0200 drm/nouveau: Drop dev->struct_mutex from fbdev init Doesn't protect anything at all. With this patch nouveau is completely dev->struct_mutex free! Cc: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-6-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/nouveau/nouveau_fbcon.c | 5 ----- 1 file changed, 5 deletions(-) commit 068149ad22efaed34598130aa79140e70bf198d0 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:42 2016 +0200 drm/qxl: Use unlocked gem unreferencing For drm_gem_object_unreference callers are required to hold dev->struct_mutex, which these paths don't. Enforcing this requirement has become a bit more strict with commit ef4c6270bf2867e2f8032e9614d1a8cfc6c71663 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Thu Oct 15 09:36:25 2015 +0200 drm/gem: Check locking in drm_gem_object_unreference Cc: Dave Airlie <airlied@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-4-git-send-email-daniel.vetter@ffwll.ch Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-5-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/qxl/qxl_fb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5bb682c446854572aa42d5a8d8a0fdc1a49219a7 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:41 2016 +0200 drm/omapdrm: Use unlocked gem unreferencing For drm_gem_object_unreference callers are required to hold dev->struct_mutex, which these paths don't. Enforcing this requirement has become a bit more strict with commit ef4c6270bf2867e2f8032e9614d1a8cfc6c71663 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Thu Oct 15 09:36:25 2015 +0200 drm/gem: Check locking in drm_gem_object_unreference Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-3-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/omapdrm/omap_fbdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e889c24490cc59e6b4811ae02d35f00754a24224 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:40:40 2016 +0200 drm/nouveau: Use unlocked gem unreferencing For drm_gem_object_unreference callers are required to hold dev->struct_mutex, which these paths don't. Enforcing this requirement has become a bit more strict with commit ef4c6270bf2867e2f8032e9614d1a8cfc6c71663 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Thu Oct 15 09:36:25 2015 +0200 drm/gem: Check locking in drm_gem_object_unreference Cc: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-2-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/nouveau/nouveau_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 644a80508f918e488aad70814b65b7007438ef4c Author: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Date: Tue Mar 22 14:10:33 2016 +0000 drm: fix lut value extraction function When extracting the value at full precision (16 bits), no need to round the value. This was spotted by Jani when running sparse. Unfortunately this fix doesn't get rid of the warning. Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reported-by: Jani Nikula <jani.nikula@intel.com> Cc: Daniel Stone <daniels@collabora.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Matt Roper <matthew.d.roper@intel.com> Cc: dri-devel@lists.freedesktop.org Fixes: 5488dc16fde7 ("drm: introduce pipe color correction properties") Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458655833-19547-1-git-send-email-lionel.g.landwerlin@intel.com include/drm/drm_crtc.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit e57cbb70b7b3773f78fc6b8b70ab1eb3367e5350 Author: Wadim Egorov <w.egorov@phytec.de> Date: Wed Apr 20 10:01:08 2016 +0200 regulator: fan53555: Add support for FAN53555UC13X type IC type options 00, 13 and 23 are sharing the same DIE_ID 0. Let's differentiate between these revisions. FAN53555UC13X has the ID 0 and REV 0xf, starts at 800mV and increments in 10mV steps. Signed-off-by: Wadim Egorov <w.egorov@phytec.de> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/fan53555.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit 5e39cf49729b910795daa0b86052463d23c0a18d Author: Wadim Egorov <w.egorov@phytec.de> Date: Wed Apr 20 10:01:07 2016 +0200 regulator: fan53555: Add support for FAN53555BUC18X type FAN53555BUC18X has the DIE_ID 8, starts at 600mV and increments in 10mV steps. Signed-off-by: Wadim Egorov <w.egorov@phytec.de> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/fan53555.c | 2 ++ 1 file changed, 2 insertions(+) commit 21ec757d2dd8650f978d27ad53cb1fcca8bb5e2b Author: Romain Perier <romain.perier@free-electrons.com> Date: Tue Apr 19 17:09:20 2016 +0200 crypto: marvell/cesa - Improving code readability When looking for available engines, the variable "engine" is assigned to "&cesa->engines[i]" at the beginning of the for loop. Replacing next occurences of "&cesa->engines[i]" by "engine" and in order to improve readability. Signed-off-by: Romain Perier <romain.perier@free-electrons.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/marvell/cesa.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 5512442553bbe8d4fcdba3e17b30f187706384a7 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Apr 19 15:44:12 2016 +0200 crypto: s5p-sss - Remove useless hash interrupt handler Beside regular feed control interrupt, the driver requires also hash interrupt for older SoCs (samsung,s5pv210-secss). However after requesting it, the interrupt handler isn't doing anything with it, not even clearing the hash interrupt bit. Driver does not provide hash functions so it is safe to remove the hash interrupt related code and to not require the interrupt in Device Tree. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> .../devicetree/bindings/crypto/samsung-sss.txt | 6 ++-- drivers/crypto/s5p-sss.c | 34 ++++------------------ 2 files changed, 8 insertions(+), 32 deletions(-) commit 07c8fccbf7fd6adf896db380c5a32c66a5b32aca Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Apr 19 15:44:11 2016 +0200 crypto: s5p-sss - Fix use after free of copied input buffer in error path The driver makes copies of memory (input or output scatterlists) if they are not aligned. In s5p_aes_crypt_start() error path (on unsuccessful initialization of output scatterlist), if input scatterlist was not aligned, the driver first freed copied input memory and then unmapped it from the device, instead of doing otherwise (unmap and then free). This was wrong in two ways: 1. Freed pages were still mapped to the device. 2. The dma_unmap_sg() iterated over freed scatterlist structure. The call to s5p_free_sg_cpy() in this error path is not needed because the copied scatterlists will be freed by s5p_aes_complete(). Fixes: 9e4a1100a445 ("crypto: s5p-sss - Handle unaligned buffers") Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 1 - 1 file changed, 1 deletion(-) commit 58ea8abf490415c390e0cc671e875510c9b66318 Author: Gary R Hook <gary.hook@amd.com> Date: Mon Apr 18 09:21:44 2016 -0500 crypto: ccp - Register the CCP as a DMA resource The CCP has the ability to provide DMA services to the kernel using pass-through mode of the device. Register these services as general purpose DMA channels. Changes since v2: - Add a Signed-off-by Changes since v1: - Allocate memory for a string in ccp_dmaengine_register - Ensure register/unregister calls are properly ordered - Verified all changed files are listed in the diffstat - Undo some superfluous changes - Added a cc: Signed-off-by: Gary R Hook <gary.hook@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/ccp/Kconfig | 1 + drivers/crypto/ccp/Makefile | 6 +- drivers/crypto/ccp/ccp-dev-v3.c | 11 + drivers/crypto/ccp/ccp-dev.h | 47 +++ drivers/crypto/ccp/ccp-dmaengine.c | 727 +++++++++++++++++++++++++++++++++++++ drivers/crypto/ccp/ccp-ops.c | 69 +++- include/linux/ccp.h | 36 +- 7 files changed, 893 insertions(+), 4 deletions(-) commit 5343e674f32fb82b7a80a24b5a84eee62d3fe624 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Mon Apr 18 12:57:41 2016 +0200 crypto4xx: integrate ppc4xx-rng into crypto4xx This patch integrates the ppc4xx-rng driver into the existing crypto4xx. This is because the true random number generator is controlled and part of the security core. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/Kconfig | 13 --- drivers/char/hw_random/Makefile | 1 - drivers/char/hw_random/ppc4xx-rng.c | 147 -------------------------------- drivers/crypto/Kconfig | 8 ++ drivers/crypto/amcc/Makefile | 1 + drivers/crypto/amcc/crypto4xx_core.c | 7 +- drivers/crypto/amcc/crypto4xx_core.h | 4 + drivers/crypto/amcc/crypto4xx_reg_def.h | 1 + drivers/crypto/amcc/crypto4xx_trng.c | 131 ++++++++++++++++++++++++++++ drivers/crypto/amcc/crypto4xx_trng.h | 34 ++++++++ 10 files changed, 184 insertions(+), 163 deletions(-) commit e81f3340bba2bdcdf021aff511830e718e6e2112 Author: Herbert Xu <herbert@gondor.apana.org.au> Date: Sat Apr 16 15:01:09 2016 +0800 eCryptfs: Do not allocate hash tfm in NORECLAIM context You cannot allocate crypto tfm objects in NORECLAIM or NOFS contexts. The ecryptfs code currently does exactly that for the MD5 tfm. This patch fixes it by preallocating the MD5 tfm in a safe context. The MD5 tfm is also reentrant so this patch removes the superfluous cs_hash_tfm_mutex. Reported-by: Nicolas Boichat <drinkcat@chromium.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> fs/ecryptfs/crypto.c | 32 ++++++++++++++++---------------- fs/ecryptfs/ecryptfs_kernel.h | 3 +-- fs/ecryptfs/inode.c | 7 +++++-- fs/ecryptfs/super.c | 5 ++++- 4 files changed, 26 insertions(+), 21 deletions(-) commit 280af2b8eb3674628223b8d143b5f71cd2a96159 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:10:07 2016 -0700 spi: spi-pxa2xx: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Cc: Daniel Mack <daniel@zonque.org> Cc: Haojian Zhuang <haojian.zhuang@gmail.com> Cc: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pxa2xx-pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2ebdf684082fa9ad924df1b2f80653920c7ca097 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:08:00 2016 -0700 ASoC: rsnd: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sh/rcar/adg.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit b6bf3289bc3c1d8df9f37c2f4f8450cc677fb286 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Apr 19 18:05:04 2016 -0700 ASoC: ak4642: Remove CLK_IS_ROOT This flag is a no-op now (see commit 47b0eeb3dc8a "clk: Deprecate CLK_IS_ROOT", 2016-02-02) so remove it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/ak4642.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 791bee125b42aa0bba3e521f148cfaf38f72a4fd Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 19 16:46:09 2016 +0100 drm/i915: Remove a couple pointless WARN_ONs Just two WARN_ONs followed by pointer dereference I spotted by accident. v2: Remove some more of the same. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1461080770-14693-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_gem.c | 10 ++-------- drivers/gpu/drm/i915/intel_lrc.c | 2 -- drivers/gpu/drm/i915/intel_ringbuffer.c | 7 +------ 3 files changed, 3 insertions(+), 16 deletions(-) commit 98735739cff5cddd28efeb01296f4fc70eaf6c89 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 19 16:46:08 2016 +0100 drm/i915/gen8+: Do not enable DPF interrupt since the handler does not exist Looks like DPF was not implemented for gen8+ but the IER and IMR are still enabled on initialization. Since there is no code to handle this interrupt, gate the irq enablement behind HAS_L3_DPF in case the feature gets enabled in the future. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/i915_irq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit bfd8ad4e4a180b95d500c76280ddc01f23f92b9d Author: Tim Gore <tim.gore@intel.com> Date: Tue Apr 19 15:45:52 2016 +0100 drm/i915/gen9: implement WaEnableSamplerGPGPUPreemptionSupport WaEnableSamplerGPGPUPreemptionSupport fixes a problem related to mid thread pre-emption. Signed-off-by: Tim Gore <tim.gore@intel.com> Reviewed-by: Dave Gordon <david.s.gordon@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461077152-31899-1-git-send-email-tim.gore@intel.com drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.c | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) commit b42841b7bb6286da56b4fa79835c27166b7e228b Author: Michal Marek <mmarek@suse.com> Date: Thu Mar 17 16:32:14 2016 +0100 kbuild: Get rid of KBUILD_STR The compiler can accept -DKBUILD_MODNAME="foo", it's just a matter of quoting. That way, we reduce the gcc command line a bit. Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Makefile.lib | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e0f41e52ddf5dc676577f974c9f0af77732f251a Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 8 11:24:48 2016 +0900 kbuild: rename cmd_as_s_S to cmd_cpp_s_S This command just preprocesses .S files into .s files, so cmd_cpp_s_S seems more suitable. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Makefile.build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 23d43848708afd7aa9a2c8516a3f269a3e71be4f Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 8 11:24:47 2016 +0900 kbuild: rename cmd_cc_i_c to cmd_cpp_i_c This command just preprocesses .c files into .i files, so cmd_cpp_i_c seems more suitable. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/Makefile.build | 6 +++--- tools/build/Makefile.build | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) commit 5e7c17df795e462c70a43f1b3b670e08efefe8fd Author: Jisheng Zhang <jszhang@marvell.com> Date: Tue Mar 22 22:42:43 2016 +0800 drivers: firmware: psci: use const and __initconst for psci_cpuidle_ops The psci_cpuidle_ops structures is not over-written, so add "const" qualifier and replace __initdata with __initconst. Acked-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> drivers/firmware/psci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1c44b28dfe527d70a6451ffb7ee091221be82168 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Fri Apr 8 11:16:10 2016 +0900 kbuild: drop redundant "PHONY += FORCE" "PHONY += FORCE" is already cared by scripts/Makefile.build, which these files are included from. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> arch/arm/boot/bootp/Makefile | 2 +- arch/ia64/Makefile | 2 +- arch/unicore32/boot/Makefile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit be1fb0e8eb0821234a9df2e2938332c1884f7f0f Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Thu Mar 31 20:14:16 2016 +0900 kbuild: delete unnecessary "@:" Since commit 2aedcd098a94 ('kbuild: suppress annoying "... is up to date." message'), $(call if_changed,...) is evaluated to "@:" when there is nothing to do. We no longer need to add "@:" after $(call if_changed,...) to suppress "... is up to date." message. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> arch/arm/boot/Makefile | 1 - arch/arm/boot/bootp/Makefile | 1 - arch/h8300/boot/compressed/Makefile | 1 - arch/m32r/boot/compressed/Makefile | 1 - arch/mn10300/boot/compressed/Makefile | 1 - arch/nios2/boot/compressed/Makefile | 1 - arch/s390/boot/compressed/Makefile | 1 - arch/sh/boot/compressed/Makefile | 1 - arch/sh/boot/romimage/Makefile | 1 - arch/unicore32/boot/compressed/Makefile | 1 - arch/x86/boot/compressed/Makefile | 1 - arch/x86/purgatory/Makefile | 2 -- arch/x86/realmode/rm/Makefile | 1 - 13 files changed, 14 deletions(-) commit fe69b420d39d307cfe2cba875dc1dbf668877198 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sun Mar 13 09:39:55 2016 +0900 kbuild: mark help target as PHONY Obviously, the "help" should be a PHONY target. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 2 ++ 1 file changed, 2 insertions(+) commit 612e47cec4ad6c5e49fe0a248b0c70849c86b0ee Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sun Mar 13 09:39:22 2016 +0900 kbuild: specify modules(_install) as PHONY rather than FORCE As in other places, PHONY is a better fit for "modules" and "modules_install". Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 2e8d696b79e9c68d3005a9b09a8c72625d141ea6 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sun Mar 13 09:13:55 2016 +0900 kbuild: drop FORCE from PHONY targets These targets are marked as PHONY. No need to add FORCE to their dependency. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.com> Makefile | 8 ++++---- arch/arm/vdso/Makefile | 2 +- arch/ia64/Makefile | 4 ++-- arch/x86/entry/vdso/Makefile | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) commit e31db4c756879bcd653ff4f36ee3f179c5e333bf Merge: bf16200 9ab9e4f Author: Russell King <rmk+kernel@arm.linux.org.uk> Date: Mon Apr 18 21:17:23 2016 +0100 Merge tag 'arm-memremap-for-v4.7' of git://git.linaro.org/people/ard.biesheuvel/linux-arm into devel-stable This series wires up the generic memremap() function for ARM in a way that allows it to be used as intended, i.e., without regard for whether the region being mapped is covered by a struct page and/or the linear mapping (lowmem) commit 27c3bffd230abd0a598586aed0fe0ba7b61e0e2e Author: Jiri Kosina <jkosina@suse.cz> Date: Thu Apr 7 15:00:54 2016 +0200 kbuild/mkspec: support 'update-bootloader'-based systems When uninstalling kernel RPM, we're unconditionally calling "new-kernel-pkg --remove". This is useless on systems which are based on 'update-bootloader' script instead. Support update-bootloader removal method as well in case the script is present; contrary to new-kernel-pkg, this needs to be done in %postun, otherwise update-bootloader will refuse to remove entry for kernel for which the binary still exists. Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/package/mkspec | 5 +++++ 1 file changed, 5 insertions(+) commit 03ae1747869437a8e4d0d4e79d4c88c25c6df39c Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Apr 19 21:29:27 2016 +0200 clk: rockchip: fix checkpatch warning in core code We seem to have accumulated a bunch of checkpatch warnings, with mainly overlong lines and two unnecessary allocation error messages. Most were introduced with the recent multi-controller-support but some were quite a bit older. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-mmc-phase.c | 3 ++- drivers/clk/rockchip/clk.c | 44 ++++++++++++++++++++---------------- drivers/clk/rockchip/clk.h | 2 +- 3 files changed, 27 insertions(+), 22 deletions(-) commit f931362b38191016b7a6dc31d90a515b37658e02 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sat Mar 19 18:37:51 2016 +0100 scripts: coccinelle: remove check to move constants to right The header mentions this check depends on personal taste. I agree. Running coccicheck on patches before I apply them, this SmPL produced enough false positives for me that I'd rather see it removed. Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/coccinelle/misc/compare_const_fl.cocci | 171 ------------------------- 1 file changed, 171 deletions(-) commit 531f50388f1b05a297c6eab7a0c1e8e6d997678b Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Sun Mar 20 10:57:32 2016 +0530 Coccinelle: setup_timer: Add space in front of parentheses Add space in front of the offending parentheses to silent the parse error for older Coccinelle versions. This makes the rule usable with all Coccinelle versions. Reported-by: Nishanth Menon <nm@ti.com> Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Fixes: c5eda8fd10c6 ("Coccinelle: Add api/setup_timer.cocci") Signed-off-by: Michal Marek <mmarek@suse.com> scripts/coccinelle/api/setup_timer.cocci | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4deaaa4deb0f9c42452711aa0a4b9c27016ca2f0 Author: Maxim Zhukov <mussitantesmortem@gmail.com> Date: Tue Apr 12 23:54:59 2016 +0300 scripts: genksyms: fix resource leak This commit fixed resource leak at func main Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com> Signed-off-by: Michal Marek <mmarek@suse.com> scripts/genksyms/genksyms.c | 3 +++ 1 file changed, 3 insertions(+) commit 2066390ad47b374f3d35075a32325b47d15bf735 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 4 17:03:46 2016 +0100 clk: renesas: cpg-mssr: Export cpg_mssr_{at,de}tach_dev() The R-Car SYSC PM Domain driver has to power manage devices in power areas using clocks. To reuse code and to share knowledge of clocks suitable for power management, this is ideally done through the existing cpg_mssr_attach_dev() and cpg_mssr_detach_dev() callbacks. Hence these callbacks can no longer rely on their "domain" parameter pointing to the CPG/MSSR Clock Domain. To handle this, keep a pointer to the clock domain in a static variable. cpg_mssr_attach_dev() has to support probe deferral, as the R-Car SYSC PM Domain may be initialized, and devices may be added to it, before the CPG/MSSR Clock Domain is initialized. Dummy callbacks are provided for the case where CPG/MSTP support is not included, so the rcar-sysc driver won't have to care about this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> drivers/clk/renesas/renesas-cpg-mssr.c | 18 ++++++++++++------ include/linux/clk/renesas.h | 7 +++++++ 2 files changed, 19 insertions(+), 6 deletions(-) commit 12524e348bcb2189a8cf43829e90256f7e7d4f3d Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 11:18:06 2016 +0200 clk: renesas: mstp: Provide dummy attach/detach_dev callbacks Provide dummy cpg_mstp_{at,de}tach_dev() PM Domain callbacks if CPG/MSTP support is not included, so the rcar-sysc driver won't have to care about this. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> include/linux/clk/renesas.h | 5 +++++ 1 file changed, 5 insertions(+) commit a5bd7f7a726c97698dacb062e4635da13e5ea8c4 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 11:08:42 2016 +0200 clk: renesas: Provide Kconfig symbols for CPG/MSSR and CPG/MSTP support Currently the decision whether to build the renesas-cpg-mssr and clk-mstp drivers is handled by Makefile logic. However, the rcar-sysc driver will need to know whether CPG/MSSR and/or CPG/MSTP support are available or not. To avoid having to duplicate this logic, move it to Kconfig. Provide non-visible CLK_RENESAS_CPG_MSSR and CLK_RENESAS_CPG_MSTP Kconfig symbols, which can be used by both Makefiles and C code. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> drivers/clk/Kconfig | 1 + drivers/clk/renesas/Kconfig | 16 ++++++++++++++++ drivers/clk/renesas/Makefile | 26 ++++++++++++++------------ 3 files changed, 31 insertions(+), 12 deletions(-) commit 1e712d9be873a44d7f5bc2a11d0ad6573029a67e Author: Jisheng Zhang <jszhang@marvell.com> Date: Tue Mar 22 22:42:42 2016 +0800 soc: qcom: spm: Use const and __initconst for qcom_cpuidle_ops The qcom_cpuidle_ops structures is not over-written, so add "const" qualifier and replace __initdata with __initconst. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Acked-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/spm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4cfd55202cee115a3686d5ad6a0f60d604aca802 Author: Jisheng Zhang <jszhang@marvell.com> Date: Tue Mar 22 22:42:41 2016 +0800 ARM: cpuidle: constify return value of arm_cpuidle_get_ops() arm_cpuidle_read_ops() just copies '*ops' to cpuidle_ops[cpu], so the structure '*ops' is not modified at all. The comment is also updated accordingly. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> arch/arm/kernel/cpuidle.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 33475a8784f4b8f0bff4419569e0dc348b318c99 Author: Jisheng Zhang <jszhang@marvell.com> Date: Tue Mar 22 22:42:40 2016 +0800 ARM: cpuidle: add const qualifier to cpuidle_ops member in structures The core code does not modify smp_operations structures. To clarify it, this patch adds 'const' qualifier to the 'ops' member of struct of_cpuidle_method. This change allows each arm cpuidle code to add 'const' qualifier to its cpuidle_ops structure. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> arch/arm/include/asm/cpuidle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b853cb9628bfbcc4017da46d5f5b46e3eba9d8c6 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 21:35:22 2016 -0700 soc: qcom: smd: Make callback pass channel reference By passing the smd channel reference to the callback, rather than the smd device, we can open additional smd channels from sub-devices of smd devices. Also updates the two smd clients today found in mainline. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd-rpm.c | 9 ++++++--- drivers/soc/qcom/smd.c | 22 ++++++++++++++++++---- drivers/soc/qcom/wcnss_ctrl.c | 8 ++++---- include/linux/soc/qcom/smd.h | 7 +++++-- 4 files changed, 33 insertions(+), 13 deletions(-) commit afd356dfb3a4127b61a3519802a4db9046703724 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 21:35:23 2016 -0700 soc: qcom: smem: Use write-combine remap for SMEM Mapping the SMEM region as write combine makes the contiguous writes in SMD perform better and also allows us to do unaligned read and writes on ARM64. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smem.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 5d3178c82739ae052d442b2fc8c332ce6fb4c7c9 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 18:32:39 2016 -0700 ARM: dts: msm8974: Add modem smp2p and smd nodes Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-msm8974.dtsi | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit 89af1c2d63b0e9785e11e17c1435825c56705052 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 18:32:38 2016 -0700 ARM: dts: msm8974: Add node for second i2c from blsp1 Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-msm8974.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 973111981b2de97c22891f83b76981dc27b42202 Author: Bjorn Andersson <bjorn.andersson@linaro.org> Date: Mon Mar 28 18:32:37 2016 -0700 ARM: dts: msm8974: Split efs in rfsa and rmtfs One part of the efs memory region is used specifically for sharing file system buffers between the apps and modem cpus (aka rmtfs), so better reflect this split. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-msm8974.dtsi | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 9ca595f08e021972e6113dacf06b247a71e09530 Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:12 2016 -0500 qcom: ipq4019: add DMA nodes to ipq4019 SoC and DK01 device tree This adds the blsp_dma node to the device tree and the required properties for using DMA with serial Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1.dtsi | 4 ++++ arch/arm/boot/dts/qcom-ipq4019.dtsi | 15 +++++++++++++++ 2 files changed, 19 insertions(+) commit fd6fd38692171e12aff2ef3ae854de24b1c3a3df Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:11 2016 -0500 qcom: ipq4019: add crypto nodes to ipq4019 SoC and DK01 device tree This adds the crypto nodes to the ipq4019 device tree, it also adds the BAM node used by crypto as well which the driver currently requires to operate properly The crypto driver itself depends on some other patches to qcom_bam_dma to function properly: https://lkml.org/lkml/2015/12/1/113 CC: Stanimir Varbanov <svarbanov@mm-sol.com> Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1.dtsi | 8 ++++++++ arch/arm/boot/dts/qcom-ipq4019.dtsi | 25 +++++++++++++++++++++++++ 2 files changed, 33 insertions(+) commit 15689ec209b2bc9ef0a02a82fdafd6da87dc1021 Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:10 2016 -0500 qcom: ipq4019: add cpu operating points for cpufreq support This adds some operating points for cpu frequeny scaling Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) commit e76b4284b520ba3b83d2f3df1451c0cbb897b85d Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:08 2016 -0500 qcom: ipq4019: add i2c node to ipq4019 SoC and DK01 device tree This will allow boards to enable the I2C bus CC: Sricharan R <srichara@qti.qualcomm.com> Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 13ad4fd36a815f1f4fb96c7308ea104bafc6bdb9 Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:07 2016 -0500 qcom: ipq4019: add spi node to ipq4019 SoC and DK01 device tree This will allow boards to enable the SPI bus Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1.dtsi | 37 +++++++++++++++++++++++++++ arch/arm/boot/dts/qcom-ipq4019.dtsi | 18 +++++++++++++ 2 files changed, 55 insertions(+) commit 8196dd5e5c4c3b623a23e25060588a7129f0574e Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:06 2016 -0500 qcom: ipq4019: add support for reset via qcom,ps-hold This will allow these types of boards to be rebooted. Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019.dtsi | 5 +++++ 1 file changed, 5 insertions(+) commit 40057afdc2a02e488a3556dedd8383f86751d006 Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Wed Mar 23 17:05:05 2016 -0500 qcom: ipq4019: add watchdog node to ipq4019 SoC and DK01 device tree This will allow boards to enable watchdog support Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1.dtsi | 4 ++++ arch/arm/boot/dts/qcom-ipq4019.dtsi | 8 ++++++++ 2 files changed, 12 insertions(+) commit 595b30c716d57cd4b61054de338bf834fc7a351e Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Thu Nov 19 18:29:48 2015 -0600 qcom: ipq4019: add acc and saw nodes to bring up secondary cores This adds the required device tree nodes to bring up the secondary cores on the ipq4019 SoC. Signed-off-by: Matthew McClintock <mmcclint@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019.dtsi | 60 +++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) commit dbe9e6f6451929b5beb7e8ec6a8d4193e698636a Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Thu Nov 19 17:19:32 2015 -0600 dts: ipq4019: Add support for IPQ4019 DK01 board Initial board support dts files for DK01 board. Signed-off-by: Senthilkumar N L <snlakshm@codeaurora.org> Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1-c1.dts | 22 +++++++++ arch/arm/boot/dts/qcom-ipq4019-ap.dk01.1.dtsi | 59 +++++++++++++++++++++++++ 3 files changed, 82 insertions(+) commit bec6ba4cdf2ac918364836c54f7d6deaf280bcb8 Author: Matthew McClintock <mmcclint@codeaurora.org> Date: Thu Nov 19 17:19:31 2015 -0600 qcom: ipq4019: Add basic board/dts support for IPQ4019 SoC Add initial dts files and SoC support for IPQ4019 Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> arch/arm/boot/dts/qcom-ipq4019.dtsi | 115 ++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) commit b55b592ee374d3f04f41c2e6fd259ca2c0f1d333 Merge: f55532a 028021d Author: Andy Gross <andy.gross@linaro.org> Date: Tue Apr 19 21:39:16 2016 -0500 Merge tag 'qcom-soc-for-4.7' into soc-for-4.7-p2 Qualcomm ARM Based SoC Updates for v4.7 * Add stubs for smem_state to fix build issues * Fix module usage in SPM driver * Add i2c and spi entries into QCOM MAINTAINERS entry * Add SMD multi channel support * Add clks to QCOM MAINTAINERS commit 8fb04d9fc70a67ccabf71dbabf92d7f6fca64a16 Author: Marco Angaroni <marcoangaroni@gmail.com> Date: Sat Apr 9 14:14:23 2016 +0200 ipvs: don't alter conntrack in OPS mode When using OPS mode in conjunction with SIP persistent-engine, packets originating from the same ip-address/port could be balanced to different real servers, and (to properly handle SIP responses) OPS connections are created in the in-out direction too, where ip_vs_update_conntrack() is called to modify the reply tuple. As a result, there can be collision of conntrack tuples, causing random packet drops, as explained below: conntrack1: orig=CIP->VIP, reply=RIP1->CIP conntrack2: orig=RIP2->CIP, reply=CIP->VIP Tuple CIP->VIP is both in orig of conntrack1 and reply of conntrack2. The collision triggers packet drop inside nf_conntrack processing. In addition, the current implementation deletes the conntrack object at every expire of an OPS connection (once every forwarded packet), to have it recreated from scratch at next packet traversing IPVS. Since in OPS mode, by definition, we don't expect any associated response, the choices implemented in this patch are: a) don't call nf_conntrack_alter_reply() for OPS connections inside ip_vs_update_conntrack(). b) don't delete the conntrack object at OPS connection expire. The result is that created conntrack objects for each tuple CIP->VIP, RIP-N->CIP, etc. are left in UNREPLIED state and not modified by IPVS OPS connection management. This eliminates packet drops and leaves a single conntrack object for each tuple packets are sent from. Signed-off-by: Marco Angaroni <marcoangaroni@gmail.com> Signed-off-by: Julian Anastasov <ja@ssi.bg> Signed-off-by: Simon Horman <horms@verge.net.au> net/netfilter/ipvs/ip_vs_conn.c | 3 ++- net/netfilter/ipvs/ip_vs_nfct.c | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) commit 013b042465d3fefef84b4b87947747eda08277e2 Author: Marco Angaroni <marcoangaroni@gmail.com> Date: Tue Apr 5 18:26:52 2016 +0200 ipvs: optimize release of connections in OPS mode One-packet-scheduling is the most expensive mode in IPVS from performance point of view: for each packet to be processed a new connection data structure is created and, after packet is sent, deleted by starting a new timer set to expire immediately. SIP persistent-engine needs OPS mode to have Call-ID based load balancing, so OPS mode performance has negative impact in SIP protocol load balancing. This patch aims to improve performance of OPS mode by means of the following changes in the release mechanism of OPS connections: a) call expire callback ip_vs_conn_expire() directly instead of starting a timer programmed to fire immediately. b) avoid call_rcu() overhead inside expire callback, since OPS connection are not inserted in the hash-table and last just the time to process the packet, hence there is no concurrent access to such data structures. Signed-off-by: Marco Angaroni <marcoangaroni@gmail.com> Acked-by: Julian Anastasov <ja@ssi.bg> Signed-off-by: Simon Horman <horms@verge.net.au> net/netfilter/ipvs/ip_vs_conn.c | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) commit 39b9722315364121c6e2524515a6e95d52287549 Author: Marco Angaroni <marcoangaroni@gmail.com> Date: Tue Apr 5 18:26:29 2016 +0200 ipvs: handle connections started by real-servers When using LVS-NAT and SIP persistence-egine over UDP, the following limitations are present with current implementation: 1) To actually have load-balancing based on Call-ID header, you need to use one-packet-scheduling mode. But with one-packet-scheduling the connection is deleted just after packet is forwarded, so SIP responses coming from real-servers do not match any connection and SNAT is not applied. 2) If you do not use "-o" option, IPVS behaves as normal UDP load balancer, so different SIP calls (each one identified by a different Call-ID) coming from the same ip-address/port go to the same real-server. So basically you don’t have load-balancing based on Call-ID as intended. 3) Call-ID is not learned when a new SIP call is started by a real-server (inside-to-outside direction), but only in the outside-to-inside direction. This would be a general problem for all SIP servers acting as Back2BackUserAgent. This patch aims to solve problems 1) and 3) while keeping OPS mode mandatory for SIP-UDP, so that 2) is not a problem anymore. The basic mechanism implemented is to make packets, that do not match any existent connection but come from real-servers, create new connections instead of let them pass without any effect. When such packets pass through ip_vs_out(), if their source ip address and source port match a configured real-server, a new connection is automatically created in the same way as it would have happened if the packet had come from outside-to-inside direction. A new connection template is created too if the virtual-service is persistent and there is no matching connection template found. The new connection automatically created, if the service had "-o" option, is an OPS connection that lasts only the time to forward the packet, just like it happens on the ingress side. The main part of this mechanism is implemented inside a persistent-engine specific callback (at the moment only SIP persistent engine exists) and is triggered only for UDP packets, since connection oriented protocols, by using different set of ports (typically ephemeral ports) to open new outgoing connections, should not need this feature. The following requisites are needed for automatic connection creation; if any is missing the packet simply goes the same way as before. a) virtual-service is not fwmark based (this is because fwmark services do not store address and port of the virtual-service, required to build the connection data). b) virtual-service and real-servers must not have been configured with omitted port (this is again to have all data to create the connection). Signed-off-by: Marco Angaroni <marcoangaroni@gmail.com> Acked-by: Julian Anastasov <ja@ssi.bg> Signed-off-by: Simon Horman <horms@verge.net.au> include/net/ip_vs.h | 17 +++++ net/netfilter/ipvs/ip_vs_core.c | 154 ++++++++++++++++++++++++++++++++++++++ net/netfilter/ipvs/ip_vs_ctl.c | 46 +++++++++++- net/netfilter/ipvs/ip_vs_pe_sip.c | 15 ++++ 4 files changed, 231 insertions(+), 1 deletion(-) commit e708b383f4b94feca2e0d5d06e1cfc13cdfea100 Author: Eric Anholt <eric@anholt.net> Date: Wed Apr 13 13:05:03 2016 -0700 clk: bcm2835: Fix PLL poweron In poweroff, we set the reset bit and the power down bit, but only managed to unset the reset bit for poweron. This meant that if HDMI did -EPROBE_DEFER after it had grabbed its clocks, we'd power down the PLLH (that had been on at boot time) and never recover. Signed-off-by: Eric Anholt <eric@anholt.net> Fixes: 41691b8862e2 ("clk: bcm2835: Add support for programming the audio domain clocks") Cc: stable@vger.kernel.org Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/bcm/clk-bcm2835.c | 4 ++++ 1 file changed, 4 insertions(+) commit 286259ef4b30bff092b223c530c7fa4dc5fd792d Author: Eric Anholt <eric@anholt.net> Date: Wed Apr 13 13:05:02 2016 -0700 clk: bcm2835: Fix compiler warnings on 64-bit builds Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/bcm/clk-bcm2835.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3432a2e39742ebbd8b01890a742bd45b219d5d8f Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Mon Apr 18 16:55:34 2016 +0200 clk: qoriq: add __init attribute Add __init attribute on a function that is only called from other __init functions and that is not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the function is put in the .text.unlikely segment. Declaring it as __init will cause it to be put in the .init.text and to disappear after initialization. The result of objdump -x on the function before the change is as follows: 0000000000000000 l F .text.unlikely 0000000000000071 sysclk_from_fixed.constprop.5 And after the change it is as follows: 0000000000000480 l F .init.text 000000000000006c sysclk_from_fixed.constprop.5 Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-qoriq.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 660e1551939931657808d47838a3f443c0e83fd0 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Mar 11 16:13:32 2016 +0200 clk: ti: dra7-atl-clock: Fix of_node reference counting of_find_node_by_name() will call of_node_put() on the node so we need to get it first to avoid warnings. The cfg_node needs to be put after we have finished processing the properties. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Nishanth Menon <nm@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ti/clk-dra7-atl.c | 2 ++ 1 file changed, 2 insertions(+) commit a5fcec480f25eb5444c0b71ecdf9b18b09236b95 Author: Tim Harvey <tharvey@gateworks.com> Date: Tue Apr 19 19:52:44 2016 -0500 PCI: imx6: Add DT property for link gen, default to Gen1 Freescale has stated [1] that the LVDS clock source of the IMX6 does not pass the PCI Gen2 clock jitter test, therefore unless an external Gen2 compliant external clock source is present and supplied back to the IMX6 PCIe core via LVDS CLK1/CLK2 you can not claim Gen2 compliance. Add a DT property to specify Gen1 vs Gen2 and check this before allowing a Gen2 link. We default to Gen1 if the property is not present because at this time there are no IMX6 boards in mainline that 'input' a clock on LVDS CLK1/CLK2. In order to be Gen2 compliant on IMX6 you need to: - Have a Gen2 compliant external clock generator and route that clock back to either LVDS CLK1 or LVDS CLK2 as an input (see IMX6SX-SabreSD reference design). - Specify this clock in the PCIe node in the DT (i.e., IMX6QDL_CLK_LVDS1_IN or IMX6QDL_CLK_LVDS2_IN instead of IMX6QDL_CLK_LVDS1_GATE which configures it as a CLK output). [1] https://community.freescale.com/message/453209 Signed-off-by: Tim Harvey <tharvey@gateworks.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Lucas Stach <l.stach@pengutronix.de> CC: Fabio Estevam <fabio.estevam@freescale.com> CC: Zhu Richard <Richard.Zhu@freescale.com> CC: Akshay Bhat <akshay.bhat@timesys.com> CC: Rob Herring <robh+dt@kernel.org> CC: Shawn Guo <shawnguo@kernel.org> .../devicetree/bindings/pci/fsl,imx6q-pcie.txt | 4 ++++ drivers/pci/host/pci-imx6.c | 24 +++++++++++++++------- 2 files changed, 21 insertions(+), 7 deletions(-) commit 3ea8529acc30467331b7b1f5da6cf668fac091c7 Author: Petr Štetiar <ynezz@true.cz> Date: Tue Apr 19 19:42:07 2016 -0500 PCI: imx6: Add reset-gpio-active-high boolean property to DT Currently the reset-gpio DT property which controls the PCI bus device reset signal defaults to active-low reset sequence (L=reset state, H=operation state) plus the code in reset function isn't GPIO polarity aware - it doesn't matter if the defined reset-gpio is active-low or active-high, it will always result into active-low reset sequence. I've tried to fix it properly and change the reset-gpio reset sequence to be polarity-aware, but this patch has been accepted and then reverted as it has introduced few backward incompatible issues: 1. Some DTBs, for example, imx6qdl-sabresd, don't define reset-gpio polarity correctly: reset-gpio = <&gpio7 12 0>; which means that it's defined as active-high, but in reality it's active-low; thus it wouldn't work without a DTS fix. 2. The logic in the reset function is inverted: gpio_set_value_cansleep(imx6_pcie->reset_gpio, 0) msleep(100); gpio_set_value_cansleep(imx6_pcie->reset_gpio, 1); so even if some of the i.MX6 boards had reset-gpio polarity defined correctly in their DTSes, they would stop working. As we can't break old DTBs, we can't fix them, so we need to introduce this new DT reset-gpio-active-high boolean property so we can support boards with active-high reset sequence. This active-high reset sequence is for example needed on Apalis SoMs, where GPIO1_IO28, used to PCIe reset is not connected directly to PERST# PCIe signal, but it's ORed with RESETBMCU coming off the PMIC, and thus is inverted, active-high. Tested-by: Tim Harvey <tharvey@gateworks.com> # Gateworks Ventana boards (which have active-low PERST#) Signed-off-by: Petr Štetiar <ynezz@true.cz> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Lucas Stach <l.stach@pengutronix.de> Acked-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/pci/fsl,imx6q-pcie.txt | 6 ++++++ drivers/pci/host/pci-imx6.c | 14 +++++++++++--- 2 files changed, 17 insertions(+), 3 deletions(-) commit 4f6926e9fdf94208dc37da0cd17835328fa4dbba Author: Petr Štetiar <ynezz@true.cz> Date: Fri Apr 1 14:41:47 2016 +0200 ARM: dts: imx6: Fix PCIe reset GPIO polarity on Toradex Apalis Ixora Adding reset-gpio-active-high boolean DT binding property, which we need to make PCIe working on Apalis SoMs and not break old DTBs. While at it, I've fixed comment and GPIO polarity. On Apalis SoMs the GPIO1_IO28 used to PCIe reset is not connected directly to PERST# PCIe signal, but it's ORed with RESETBMCU coming off the PMIC, and thus is inverted, active-high. Signed-off-by: Petr Štetiar <ynezz@true.cz> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> arch/arm/boot/dts/imx6q-apalis-ixora.dts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit e3c06cd063d69df741295a50a691d4a2cad3852a Author: Christoph Fritz <chf.fritz@googlemail.com> Date: Tue Apr 5 16:53:27 2016 -0500 PCI: imx6: Add initial imx6sx support Add initial PCIe support for the imx6 SoC derivate imx6sx. PCI MSI support is untested as the necessary suspend/resume quirk is not included in this patch. This patch is heavily based on patches by Richard Zhu. [bhelgaas: factor out refclk enable, fix adjacent typos in imx6q-pcie.txt] Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com> Acked-by: Richard Zhu <Richard.Zhu@freescale.com> Acked-by: Lucas Stach <l.stach@pengutronix.de> .../devicetree/bindings/pci/fsl,imx6q-pcie.txt | 8 +++- drivers/pci/host/pci-imx6.c | 53 ++++++++++++++++++++++ 2 files changed, 59 insertions(+), 2 deletions(-) commit 4d1821e729b5d2060ef8c9825af1dacc2182da38 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Mon Mar 14 00:30:55 2016 +0100 PCI: imx6: Factor out ref clock enable Factor out ref clock enable to make it cleaner to add imx6sx support. No functional change intended. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Tested-by: Christoph Fritz <chf.fritz@googlemail.com> drivers/pci/host/pci-imx6.c | 36 ++++++++++++++++++++++++------------ 1 file changed, 24 insertions(+), 12 deletions(-) commit 896ad420db8d5ec4cc4727b786d15e28eb59b366 Author: Martin Sperl <kernel@martin.sperl.org> Date: Sat Mar 5 18:02:49 2016 +0000 dt/bindings: bcm2835: correct description for DMA-int Interrupt DMA11 is the shared interrupt for DMA channels 11 to 14 Interrupt DMA12 is the shared interrupt triggering for any DMA channel (this also includes DMA channel 15) Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Acked-by: Rob Herring <robh@kernel.org> .../bindings/interrupt-controller/brcm,bcm2835-armctrl-ic.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1b2f8973c3bda7a100a8f3e1b4bc1c8ea9bf92d8 Author: Stefan Wahren <stefan.wahren@i2se.com> Date: Thu Mar 31 17:25:17 2016 +0000 ARM: bcm2835: add CPU node for ARM core This patch adds the CPU node of the BCM2835 into the DT. Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Reviewed-by: Eric Anholt <eric@anholt.net> arch/arm/boot/dts/bcm2835.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 49ac67e0c39cd268371e63ce0662ecb59a164a20 Author: Eric Anholt <eric@anholt.net> Date: Mon Mar 2 14:36:16 2015 -0800 ARM: bcm2835: Add VC4 to the device tree. VC4 is the GPU (display and 3D) present on the 283x. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/boot/dts/bcm2835-rpi-a-plus.dts | 4 +++ arch/arm/boot/dts/bcm2835-rpi-a.dts | 4 +++ arch/arm/boot/dts/bcm2835-rpi-b-plus.dts | 4 +++ arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts | 4 +++ arch/arm/boot/dts/bcm2835-rpi-b.dts | 4 +++ arch/arm/boot/dts/bcm2835-rpi.dtsi | 9 ++++++ arch/arm/boot/dts/bcm2836-rpi-2-b.dts | 4 +++ arch/arm/boot/dts/bcm283x.dtsi | 47 ++++++++++++++++++++++++++++++++ 8 files changed, 80 insertions(+) commit b3a15f6d55fb584dd4d8baac5d1b6a398720620c Author: Eric Anholt <eric@anholt.net> Date: Tue Apr 19 13:24:14 2016 -0700 drm/vc4: Kick out the simplefb framebuffer before we set up KMS. If we don't, then simplefb stays loaded on /dev/fb0 even though scanout isn't happening from simplefb's memory area any more, and you end up with no console. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Dave Airlie <airlied@redhat.com> drivers/gpu/drm/vc4/vc4_drv.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit 46e7b8d8d53bcde075dca6da3a3816a663073499 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Mon Apr 18 16:10:24 2016 -0400 net: dsa: kill circular reference with slave priv The dsa_slave_priv structure does not need a pointer to its net_device. Kill it. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/dsa/dsa_priv.h | 5 ----- net/dsa/slave.c | 9 ++++----- 2 files changed, 4 insertions(+), 10 deletions(-) commit 9f4ab6ec7ee3b4971231d0b9078062f99decfa13 Merge: 553bc08 bd570ff Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 19 20:26:11 2016 -0400 Merge branch 'bpf_event_output' Daniel Borkmann says: ==================== BPF updates This minor set adds a new helper bpf_event_output() for eBPF cls/act program types which allows to pass events to user space applications. For details, please see individual patches. v1 -> v2: - Address kbuild bot found compile issue in patch 2 - Rest as is ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bd570ff970a54df653b48ed0cfb373f2ebed083d Author: Daniel Borkmann <daniel@iogearbox.net> Date: Mon Apr 18 21:01:24 2016 +0200 bpf: add event output helper for notifications/sampling/logging This patch adds a new helper for cls/act programs that can push events to user space applications. For networking, this can be f.e. for sampling, debugging, logging purposes or pushing of arbitrary wake-up events. The idea is similar to a43eec304259 ("bpf: introduce bpf_perf_event_output() helper") and 39111695b1b8 ("samples: bpf: add bpf_perf_event_output example"). The eBPF program utilizes a perf event array map that user space populates with fds from perf_event_open(), the eBPF program calls into the helper f.e. as skb_event_output(skb, &my_map, BPF_F_CURRENT_CPU, raw, sizeof(raw)) so that the raw data is pushed into the fd f.e. at the map index of the current CPU. User space can poll/mmap/etc on this and has a data channel for receiving events that can be post-processed. The nice thing is that since the eBPF program and user space application making use of it are tightly coupled, they can define their own arbitrary raw data format and what/when they want to push. While f.e. packet headers could be one part of the meta data that is being pushed, this is not a substitute for things like packet sockets as whole packet is not being pushed and push is only done in a single direction. Intention is more of a generically usable, efficient event pipe to applications. Workflow is that tc can pin the map and applications can attach themselves e.g. after cls/act setup to one or multiple map slots, demuxing is done by the eBPF program. Adding this facility is with minimal effort, it reuses the helper introduced in a43eec304259 ("bpf: introduce bpf_perf_event_output() helper") and we get its functionality for free by overloading its BPF_FUNC_ identifier for cls/act programs, ctx is currently unused, but will be made use of in future. Example will be added to iproute2's BPF example files. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/bpf.h | 2 ++ kernel/bpf/core.c | 7 +++++++ kernel/trace/bpf_trace.c | 27 +++++++++++++++++++++++++++ net/core/filter.c | 2 ++ 4 files changed, 38 insertions(+) commit 1e33759c788c78f31d4d6f65bac647b23624734c Author: Daniel Borkmann <daniel@iogearbox.net> Date: Mon Apr 18 21:01:23 2016 +0200 bpf, trace: add BPF_F_CURRENT_CPU flag for bpf_perf_event_output Add a BPF_F_CURRENT_CPU flag to optimize the use-case where user space has per-CPU ring buffers and the eBPF program pushes the data into the current CPU's ring buffer which saves us an extra helper function call in eBPF. Also, make sure to properly reserve the remaining flags which are not used. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/bpf.h | 4 ++++ kernel/trace/bpf_trace.c | 7 ++++++- 2 files changed, 10 insertions(+), 1 deletion(-) commit 553bc087caf052458dc9f92bc42710027740caa9 Author: Julia Lawall <julia.lawall@lip6.fr> Date: Mon Apr 18 16:55:35 2016 +0200 arcnet: com90xx: add __init attribute Add __init attribute on a function that is only called from other __init functions and that is not inlined, at least with gcc version 4.8.4 on an x86 machine with allyesconfig. Currently, the function is put in the .text.unlikely segment. Declaring it as __init will cause it to be put in the .init.text and to disappear after initialization. The result of objdump -x on the function before the change is as follows: 0000000000000000 l F .text.unlikely 00000000000000bf check_mirror And after the change it is as follows: 0000000000000000 l F .init.text 00000000000000ba check_mirror Done with the help of Coccinelle. The semantic patch checks for local static non-init functions that are called from an __init function and are not called from any other function. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Michael Grzeschik <mgr@pengutronix.de> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/arcnet/com90xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5df1f77f65e11f2d7454de70998a68c42293397a Author: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Date: Mon Apr 18 14:41:17 2016 +0300 net/ipv6/addrconf: fix sysctl table indentation Separated from previous patch for readability. Signed-off-by: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/addrconf.c | 616 ++++++++++++++++++++++++++-------------------------- 1 file changed, 307 insertions(+), 309 deletions(-) commit 607ea7cda6315be0ad8be2f98bc9de6f2d656ae6 Author: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Date: Mon Apr 18 14:41:10 2016 +0300 net/ipv6/addrconf: simplify sysctl registration Struct ctl_table_header holds pointer to sysctl table which could be used for freeing it after unregistration. IPv4 sysctls already use that. Remove redundant NULL assignment: ndev allocated using kzalloc. This also saves some bytes: sysctl table could be shorter than DEVCONF_MAX+1 if some options are disable in config. Signed-off-by: Konstantin Khlebnikov <khlebnikov@yandex-team.ru> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/ipv6.h | 3 ++- net/ipv6/addrconf.c | 43 +++++++++++++++++-------------------------- 2 files changed, 19 insertions(+), 27 deletions(-) commit 9c7fe83530a351845719acf1dda0587e8c743588 Author: Daniel DeFreez <dcdefreez@ucdavis.edu> Date: Tue Apr 19 19:57:45 2016 -0400 GFS2: Add calls to gfs2_holder_uninit in two error handlers This patch fixes two locations that do not call gfs2_holder_uninit if gfs2_glock_nq returns an error. Signed-off-by: Daniel DeFreez <dcdefreez@ucdavis.edu> Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/aops.c | 3 ++- fs/gfs2/file.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 26ef56be9e0944a9b136169eb47140f309ce745b Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:34:13 2016 -0800 clk: fixed-rate: Add hw based registration APIs Add registration APIs in the clk fixed-rate code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-fixed-rate.c | 44 ++++++++++++++++++++++++++++++++++++-------- include/linux/clk-provider.h | 7 +++++++ 2 files changed, 43 insertions(+), 8 deletions(-) commit b120743a64a3ec68b8c5310a6009094329b4a33b Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:27:55 2016 -0800 clk: gpio: Add hw based registration APIs Add registration APIs in the clk gpio code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-gpio.c | 52 ++++++++++++++++++++++++++++++++++---------- include/linux/clk-provider.h | 8 +++++++ 2 files changed, 49 insertions(+), 11 deletions(-) commit 49cb392d36397a296dcd51ec57cf83585a89a94a Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:20:31 2016 -0800 clk: composite: Add hw based registration APIs Add registration APIs in the clk composite code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-composite.c | 45 ++++++++++++++++++++++++++++++++------------ include/linux/clk-provider.h | 7 +++++++ 2 files changed, 40 insertions(+), 12 deletions(-) commit 39b44cff4ad4af6d7abd9dd2acb288b005c26503 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:15:09 2016 -0800 clk: fractional-divider: Add hw based registration APIs Add registration APIs in the clk fractional divider code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-fractional-divider.c | 40 +++++++++++++++++++++++++++++++----- include/linux/clk-provider.h | 5 +++++ 2 files changed, 40 insertions(+), 5 deletions(-) commit 0759ac8a73dc2c8cc8ac697fbe5dbd8d67348d37 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:11:06 2016 -0800 clk: fixed-factor: Add hw based registration APIs Add registration APIs in the clk fixed-factor code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-fixed-factor.c | 42 +++++++++++++++++++++++++++++++++++------- include/linux/clk-provider.h | 4 ++++ 2 files changed, 39 insertions(+), 7 deletions(-) commit 264b31719735eb1fcbed47cecdb20f517e804856 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sun Feb 7 00:05:48 2016 -0800 clk: mux: Add hw based registration APIs Add registration APIs in the clk mux code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-mux.c | 57 +++++++++++++++++++++++++++++++++++++++----- include/linux/clk-provider.h | 11 +++++++++ 2 files changed, 62 insertions(+), 6 deletions(-) commit e270d8cb13763f58107198e879cf396511ba2867 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sat Feb 6 23:54:45 2016 -0800 clk: gate: Add hw based registration APIs Add registration APIs in the clk gate code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-gate.c | 43 ++++++++++++++++++++++++++++++++++++------- include/linux/clk-provider.h | 5 +++++ 2 files changed, 41 insertions(+), 7 deletions(-) commit eb7d264f3bf9ca7c093efb77bdde557c6c6e826f Author: Stephen Boyd <sboyd@codeaurora.org> Date: Sat Feb 6 23:26:37 2016 -0800 clk: divider: Add hw based registration APIs Add registration APIs in the clk divider code to return struct clk_hw pointers instead of struct clk pointers. This way we hide the struct clk pointer from providers unless they need to use consumer facing APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-divider.c | 91 ++++++++++++++++++++++++++++++++++++++++---- include/linux/clk-provider.h | 10 +++++ 2 files changed, 93 insertions(+), 8 deletions(-) commit e4f1b49bda6d6aa2e13730ff7eeccbe65a6271f1 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Mon Feb 8 14:59:49 2016 -0800 clkdev: Add clk_hw based registration APIs Now that we have a clk registration API that doesn't return struct clks, we need to have some way to hand out struct clks via the clk_get() APIs that doesn't involve associating struct clk pointers with a struct clk_lookup. Luckily, clkdev already operates on struct clk_hw pointers, except for the registration facing APIs where it converts struct clk pointers into struct clk_hw pointers almost immediately. Let's add clk_hw based registration APIs so that we can skip the conversion step and provide a way for clk provider drivers to operate exclusively on clk_hw structs. This way we clearly split the API between consumers and providers. Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clkdev.c | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/clkdev.h | 6 +++++ 2 files changed, 70 insertions(+) commit 1bf2bf229b64540f91ac6fa3af37c81249037a0b Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 31 16:34:37 2016 -0600 PCI: Work around Intel Sunrise Point PCH incorrect ACS capability Intel Sunrise Point root ports implement ACS but use dwords for the capability and control registers, putting the control register at the wrong offset. Use quirks to enable and test ACS for these devices, which match the standard functions modulo the broken control register offset. Note that lspci assumes devices implement ACS per spec, so it shows invalid ACS data for these devices. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/quirks.c | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) commit 0861e5b8cf80038e91942f1005c8dfce79d18c38 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Feb 5 17:38:26 2016 -0800 clk: Add clk_hw OF clk providers Now that we have a clk registration API that doesn't return struct clks, we need to have some way to hand out struct clks via the clk_get() APIs that doesn't involve associating struct clk pointers with an OF node. Currently we ask the OF provider to give us a struct clk pointer for some clkspec, turn that struct clk into a struct clk_hw and then allocate a new struct clk to return to the caller. Let's add a clk_hw based OF provider hook that returns a struct clk_hw directly, so that we skip the intermediate step of converting from struct clk to struct clk_hw. Eventually when we've converted all OF clk providers to struct clk_hw based APIs we can remove the struct clk based ones. It should also be noted that we change the onecell provider to have a flex array instead of a pointer for the array of clk_hw pointers. This allows providers to allocate one structure of the correct length in one step instead of two. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk.c | 85 +++++++++++++++++++++++++++++++++++++++++--- include/linux/clk-provider.h | 30 ++++++++++++++++ 2 files changed, 111 insertions(+), 4 deletions(-) commit 4143804c4fdef40358c654d1fb2271a1a0f1fedf Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Feb 5 17:02:52 2016 -0800 clk: Add {devm_}clk_hw_{register,unregister}() APIs We've largely split the clk consumer and provider APIs along struct clk and struct clk_hw, but clk_register() still returns a struct clk pointer for each struct clk_hw that's registered. Eventually we'd like to only allocate struct clks when there's a user, because struct clk is per-user now, so clk_register() needs to change. Let's add new APIs to register struct clk_hws, but this time we'll hide the struct clk from the caller by returning an int error code. Also add an unregistration API that takes the clk_hw structure that was passed to the registration API. This way provider drivers never have to deal with a struct clk pointer unless they're using the clk consumer APIs. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Documentation/driver-model/devres.txt | 1 + drivers/clk/clk.c | 86 +++++++++++++++++++++++++++++++++++ include/linux/clk-provider.h | 6 +++ 3 files changed, 93 insertions(+) commit a14b9e0512404ed7d4415b888dc9f1f9785a4fa3 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Feb 5 16:40:47 2016 -0800 clkdev: Remove clk_register_clkdevs() Now that we've converted the only caller over to another clkdev API, remove this one. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clkdev.c | 27 --------------------------- include/linux/clkdev.h | 1 - 2 files changed, 28 deletions(-) commit 35c5845957c7982dac1f525ff3412f8acf0a0385 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 19 19:49:29 2016 -0400 net: Add helpers for 64-bit aligning netlink attributes. Suggested-by: Eric Dumazet <eric.dumazet@gmail.com> Suggested-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/netlink.h | 37 +++++++++++++++++++++++++++++++++++++ net/core/rtnetlink.c | 24 +++++------------------- 2 files changed, 42 insertions(+), 19 deletions(-) commit c1d61c9bb163e696bf06850bcabbd26386554489 Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 31 16:34:32 2016 -0600 PCI: Reverse standard ACS vs device-specific ACS enabling The original thought was that if a device implemented ACS, then surely we want to use that... well, it turns out that devices can make an ACS capability so broken that we still need to fall back to quirks. Reverse the order of ACS enabling to give quirks first shot at it. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pci.c | 10 ++++------ drivers/pci/quirks.c | 6 ++++-- include/linux/pci.h | 7 +++++-- 3 files changed, 13 insertions(+), 10 deletions(-) commit 26dba29689aef1135378ab8783157debe1314bce Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 24 11:01:08 2016 +0900 ARM: dts: r8a7791: Use USB3.0 fallback compatibility string Use recently added fallback compatibility string in r8a7791 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 92cc7798edf105b0684a4a154fc7bac9955a4766 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 24 11:01:07 2016 +0900 ARM: dts: r8a7790: Use USB3.0 fallback compatibility string Use recently added fallback compatibility string in r8a7790 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7790.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e6c2488251b1c7e62f3e43907ca3f6fd016b1353 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 18 11:19:21 2016 +0100 ARM: dts: r8a7779: Correct interrupt type for ARM TWD The ARM TWD interrupt is a private peripheral interrupt (PPI), and per the ARM GIC documentation, whether the type for PPIs can be set is IMPLEMENTATION DEFINED. For R-Car H1 devices the PPI type cannot be set, and so when we attempt to set the type for the ARM TWD interrupt it fails. This has gone unnoticed because it fails silently, and because we cannot re-configure the type it has had no impact. Nevertheless fix the type for the TWD interrupt so that it matches the hardware configuration. Based on patches by Jon Hunter for Tegra20/30 and OMAP4. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7779.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a4a72b473e2897265a0fecbd5f6b5a92ea62585f Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 18 11:19:20 2016 +0100 ARM: dts: sh73a0: Correct interrupt type for ARM TWD The ARM TWD interrupt is a private peripheral interrupt (PPI), and per the ARM GIC documentation, whether the type for PPIs can be set is IMPLEMENTATION DEFINED. For SH-Mobile AG5 devices the PPI type cannot be set, and so when we attempt to set the type for the ARM TWD interrupt it fails. This has gone unnoticed because it fails silently, and because we cannot re-configure the type it has had no impact. Nevertheless fix the type for the TWD interrupt so that it matches the hardware configuration. Based on patches by Jon Hunter for Tegra20/30 and OMAP4. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/sh73a0.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa9b992ea2d3c2cc48712c21d1e680318d4156e2 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 17 16:35:17 2016 +0900 ARM: dts: r8a7794: Add IIC nodes Add IIC nodes to r8a7794 device tree. Based on similar work for the r8a7793 by Laurent Pinchart. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7794.dtsi | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit a856b195d129059c71981b6d069085d611ad8d38 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 17 16:33:10 2016 +0900 ARM: dts: r8a7794: add IIC clocks Add IIC clocks to r8a7794 device tree. Based on similar work for the r8a7790 by Wolfram Sang. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7794.dtsi | 9 ++++++--- include/dt-bindings/clock/r8a7794-clock.h | 2 ++ 2 files changed, 8 insertions(+), 3 deletions(-) commit a0e300ceb5259e8584ff67971981ac22580ef550 Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 16 10:52:56 2016 +0900 ARM: dts: r8a7793: add CAN nodes to device tree Add CAN nodes to r8a7793 device tree. Based on work by Sergei Shtylyov for the r8a7791 SoC. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7793.dtsi | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit 7892e6c1be78a7b008722badd99e5abd0ad6007b Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 16 10:52:55 2016 +0900 ARM: dts: r8a7793: add CAN clocks to device tree The R-Car CAN controllers can derive the CAN bus clock not only from their peripheral clock input (clkp1) but also from the other internal clock (clkp2) and external clock fed on CAN_CLK pin. Describe those clocks in the device tree along with the USB_EXTAL clock from which clkp2 is derived. Based on work by Sergei Shtylyov for the r8a7791 SoC. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7793.dtsi | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) commit 9f1c1a2c784d28d45d0cd18a44e45ddd15d7458f Author: Simon Horman <horms+renesas@verge.net.au> Date: Tue Mar 15 09:26:34 2016 +0900 ARM: dts: r8a7794: add CAN nodes to device tree Add CAN nodes to r8a7794 device tree. Based on work by Sergei Shtylyov for the r8a7791 SoC. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> arch/arm/boot/dts/r8a7794.dtsi | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit e980f9418f45a3c0d53e54bc17bd48406060c2bb Author: Simon Horman <horms+renesas@verge.net.au> Date: Tue Mar 15 09:26:33 2016 +0900 ARM: dts: r8a7794: add CAN clocks to device tree Add CAN nodes to r8a7794 device tree. Based on work by Sergei Shtylyov for the r8a7791 SoC. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> arch/arm/boot/dts/r8a7794.dtsi | 33 ++++++++++++++++++++++++------- include/dt-bindings/clock/r8a7794-clock.h | 3 +++ 2 files changed, 29 insertions(+), 7 deletions(-) commit 28e941de3dc7105ab3c0c261814d4d53a6b8ddf4 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 14 11:13:59 2016 +0900 ARM: dts: r8a7790: use fallback can compatibility string Use recently added fallback compatibility string in r8a7790 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7790.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 73ae9cfecd069060e7bf182250e16ff8c598f997 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 14 11:13:58 2016 +0900 ARM: dts: r8a7791: use fallback can compatibility string Use recently added fallback compatibility string in r8a7791 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 022869a2c4e15c3b615dd278d59e0fa82e5a8449 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Mar 3 10:32:41 2016 +0100 ARM: dts: r8a7790: Add SCIF2 device node Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 38805823377d762ec46f2430f29ef0cb8b3937d4 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Mar 3 10:32:40 2016 +0100 ARM: dts: r8a7790: Add SCIF2 clock Based on Rev. 2.00 of the R-Car Gen2 datasheet. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/boot/dts/r8a7790.dtsi | 6 +++--- include/dt-bindings/clock/r8a7790-clock.h | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) commit 803f7e0b23d3a7cb3f038df786df4faf2e0c752a Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Feb 24 11:29:06 2016 +0900 ARM: dts: r8a7791: use fallback jpu compatibility string Use recently added fallback compatibility string in r8a7791 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1c4b68fdd52e05730591682bc62042cead6f5af3 Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Feb 24 11:29:05 2016 +0900 ARM: dts: r8a7790: use fallback jpu compatibility string Use recently added fallback compatibility string in r8a7790 device trees. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7790.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d50c744ecde7ee3ba4d7ffb0e1c55e7a2f6bbc8e Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Tue Mar 8 17:17:15 2016 -0500 tracing: Fix unsigned comparison to zero in hist trigger code Fengguang Wu's bot found two comparisons of unsigned integers to zero. These were real bugs, as it would miss error conditions returned to zero. trace_events_hist.c:426:6-9: WARNING: Unsigned expression compared with zero: idx < 0 trace_events_hist.c:568:5-14: WARNING: Unsigned expression compared with zero: n_entries < 0 Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events_hist.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 93c5f671f25cb7a73492b7a96b426c4fb1efa715 Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Thu Mar 3 12:55:03 2016 -0600 kselftests/ftrace: Add a test for log2 modifier of hist trigger Add a test for log2 modifier of hist trigger in hist_mod.tc. Here is the test result. ---- # ./ftracetest test.d/trigger/trigger-hist-mod.tc === Ftrace unit tests === [1] event trigger - test histogram modifiers [PASS] # of passed: 1 # of failed: 0 # of unresolved: 0 # of untested: 0 # of unsupported: 0 # of xfailed: 0 # of undefined(test bug): 0 ---- Link: http://lkml.kernel.org/r/3f1ab735c06a50b1b40d3e96b8b6a3e5ea62fd86.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> .../selftests/ftrace/test.d/trigger/trigger-hist-mod.tc | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 4b94f5b7b4a5ffd885609bd033af2ecca0c9cc54 Author: Namhyung Kim <namhyung@kernel.org> Date: Thu Mar 3 12:55:02 2016 -0600 tracing: Add hist trigger 'log2' modifier Allow users to have numeric fields displayed as log2 values in case value range is very wide by appending '.log2' to field names. For example, # echo 'hist:key=bytes_req' > kmalloc/trigger # cat kmalloc/hist { bytes_req: 504 } hitcount: 1 { bytes_req: 11 } hitcount: 1 { bytes_req: 104 } hitcount: 1 { bytes_req: 48 } hitcount: 1 { bytes_req: 2048 } hitcount: 1 { bytes_req: 4096 } hitcount: 1 { bytes_req: 240 } hitcount: 1 { bytes_req: 392 } hitcount: 1 { bytes_req: 13 } hitcount: 1 { bytes_req: 28 } hitcount: 1 { bytes_req: 12 } hitcount: 1 { bytes_req: 64 } hitcount: 2 { bytes_req: 128 } hitcount: 2 { bytes_req: 32 } hitcount: 2 { bytes_req: 8 } hitcount: 11 { bytes_req: 10 } hitcount: 13 { bytes_req: 24 } hitcount: 25 { bytes_req: 160 } hitcount: 29 { bytes_req: 16 } hitcount: 33 { bytes_req: 80 } hitcount: 36 When using '.log2' modifier, the output looks like: # echo 'hist:key=bytes_req.log2' > kmalloc/trigger # cat kmalloc/hist { bytes_req: ~ 2^12 } hitcount: 1 { bytes_req: ~ 2^11 } hitcount: 1 { bytes_req: ~ 2^9 } hitcount: 2 { bytes_req: ~ 2^6 } hitcount: 3 { bytes_req: ~ 2^3 } hitcount: 13 { bytes_req: ~ 2^5 } hitcount: 19 { bytes_req: ~ 2^8 } hitcount: 49 { bytes_req: ~ 2^7 } hitcount: 57 { bytes_req: ~ 2^4 } hitcount: 74 Link: http://lkml.kernel.org/r/7ff396b246c6a881f46b979735fddf05a0d6c71a.1457029949.git.tom.zanussi@linux.intel.com Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Signed-off-by: Namhyung Kim <namhyung@kernel.org> Reviewed-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 1 + kernel/trace/trace_events_hist.c | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) commit 76929ab51f0ee398bcf72286c4b377051f07a31b Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Thu Mar 3 12:55:01 2016 -0600 kselftests/ftrace: Add hist trigger testcases Add the hist trigger testcases for ftracetest. This checks the basic histogram trigger behaviors like as; - Histogram trigger itself - Histogram with string key - Histogram with compound keys - Histogram with sort key - Histogram trigger modifiers (execname, hex, syscall) - Multiple histograms on an event - Named histogram - Named histogram on multi events Here is the test result. ---- # ./ftracetest test.d/trigger/*hist*.tc === Ftrace unit tests === [1] event trigger - test histogram modifiers [PASS] [2] event trigger - test histogram trigger [PASS] [3] event trigger - test multiple histogram triggers [PASS] # of passed: 3 # of failed: 0 # of unresolved: 0 # of untested: 0 # of unsupported: 0 # of xfailed: 0 # of undefined(test bug): 0 ---- Link: http://lkml.kernel.org/r/17cb3a3d9eeadc3282645147905455a298e7fbeb.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> [Tom Zanussi: Change multihist test from truncate ('>') to append ('>>')] Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> .../ftrace/test.d/trigger/trigger-hist-mod.tc | 65 +++++++++++++++++ .../ftrace/test.d/trigger/trigger-hist.tc | 83 ++++++++++++++++++++++ .../ftrace/test.d/trigger/trigger-multihist.tc | 73 +++++++++++++++++++ 3 files changed, 221 insertions(+) commit cfa0963dc474fd098d6a7a722dcecfc143a4b377 Author: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Date: Thu Mar 3 12:55:00 2016 -0600 kselftests/ftrace : Add event trigger testcases This adds simple event trigger testcases for ftracetest, which covers following triggers. - traceon-traceoff trigger - enable/disable_event trigger - snapshot trigger - stacktrace trigger - trigger filters Here is the test result. ---- # ./ftracetest test.d/trigger/ === Ftrace unit tests === [1] event trigger - test event enable/disable trigger [PASS] [2] event trigger - test trigger filter [PASS] [3] event trigger - test snapshot-trigger [PASS] [4] event trigger - test stacktrace-trigger [PASS] [5] event trigger - test traceon/off trigger [PASS] # of passed: 5 # of failed: 0 # of unresolved: 0 # of untested: 0 # of unsupported: 0 # of xfailed: 0 # of undefined(test bug): 0 ---- Link: http://lkml.kernel.org/r/12b9c2b289a0dc1e4386e7b77674611a83abca85.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> tools/testing/selftests/ftrace/test.d/functions | 9 +++ .../ftrace/test.d/trigger/trigger-eventonoff.tc | 64 ++++++++++++++++++++++ .../ftrace/test.d/trigger/trigger-filter.tc | 59 ++++++++++++++++++++ .../ftrace/test.d/trigger/trigger-snapshot.tc | 56 +++++++++++++++++++ .../ftrace/test.d/trigger/trigger-stacktrace.tc | 53 ++++++++++++++++++ .../ftrace/test.d/trigger/trigger-traceonoff.tc | 58 ++++++++++++++++++++ 6 files changed, 299 insertions(+) commit 5463bfda327b1f7310556ef3136533e27c774f13 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:59 2016 -0600 tracing: Add support for named hist triggers Allow users to define 'named' hist triggers. All triggers created with the same 'name=xxx' option will update the same shared histogram data. This expands the hist trigger syntax from this: # echo hist:keys=xxx ... [ if filter] > event/trigger to this: # echo hist:name=xxx:keys=xxx ... [ if filter] > event/trigger Named histograms must use a 'compatible' set of keys and values, which means each event added to a set of named triggers must have the same names and types. Reading the 'hist' file of any of the participating events will produce the same output as any other participating event, which is to be expected since they share the same data. Link: http://lkml.kernel.org/r/1dbc84ee3322a75daaf5b3ef1d0cc0a2fb682fc7.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Documentation/trace/events.txt | 274 +++++++++++++++++++++++++++++++++++++-- kernel/trace/trace.c | 14 +- kernel/trace/trace_events_hist.c | 148 ++++++++++++++++++--- 3 files changed, 407 insertions(+), 29 deletions(-) commit db1388b4ffa9e31e9ff0abacc3bdb121bec8c688 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:58 2016 -0600 tracing: Add support for named triggers Named triggers are sets of triggers that share a common set of trigger data. An example of functionality that could benefit from this type of capability would be a set of inlined probes that would each contribute event counts, for example, to a shared counter data structure. The first named trigger registered with a given name owns the common trigger data that the others subsequently registered with the same name will reference. The functions defined here allow users to add, delete, and find named triggers. It also adds functions to pause and unpause named triggers; since named triggers act upon common data, they should also be paused and unpaused as a group. Link: http://lkml.kernel.org/r/c09ff648360f65b10a3e321eddafe18060b4a04f.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.h | 13 ++++ kernel/trace/trace_events_trigger.c | 143 ++++++++++++++++++++++++++++++++++++ 2 files changed, 156 insertions(+) commit 52a7f16dedff8f23d03df3ea556dec95b92a5801 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:57 2016 -0600 tracing: Add support for multiple hist triggers per event Allow users to define any number of hist triggers per trace event. Any number of hist triggers may be added for a given event, which may differ by key, value, or filter. Reading the event's 'hist' file will display the output of all the hist triggers defined on an event concatenated in the order they were defined. Link: http://lkml.kernel.org/r/48a0c8dd34c344571de880fb35e211c6d9a28961.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Documentation/trace/events.txt | 154 +++++++++++++++++++++++++++++++++-- kernel/trace/trace.c | 8 +- kernel/trace/trace_events_hist.c | 172 +++++++++++++++++++++++++++++++-------- 3 files changed, 293 insertions(+), 41 deletions(-) commit 0fc3813ce1036b57598ee5cdcf891f8a19581654 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:56 2016 -0600 tracing: Add 'hist' trigger Documentation Add documentation and usage examples for 'hist' triggers. Link: http://lkml.kernel.org/r/2e13f35f47fea6d647f0efefccfc9673ea84b29f.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Documentation/trace/events.txt | 1155 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1155 insertions(+) commit d0bad49bb0a094a1beb06640785f95cb256b7272 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:55 2016 -0600 tracing: Add enable_hist/disable_hist triggers Similar to enable_event/disable_event triggers, these triggers enable and disable the aggregation of events into maps rather than enabling and disabling their writing into the trace buffer. They can be used to automatically start and stop hist triggers based on a matching filter condition. If there's a paused hist trigger on system:event, the following would start it when the filter condition was hit: # echo enable_hist:system:event [ if filter] > event/trigger And the following would disable a running system:event hist trigger: # echo disable_hist:system:event [ if filter] > event/trigger See Documentation/trace/events.txt for real examples. Link: http://lkml.kernel.org/r/f812f086e52c8b7c8ad5443487375e03c96a601f.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 1 + kernel/trace/trace.c | 8 +++ kernel/trace/trace.h | 32 ++++++++++ kernel/trace/trace_events_hist.c | 115 ++++++++++++++++++++++++++++++++++++ kernel/trace/trace_events_trigger.c | 71 ++++++++++++---------- 5 files changed, 196 insertions(+), 31 deletions(-) commit 6a475cb17fe161dbde62eca7e4c2cf59edff182f Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:54 2016 -0600 tracing: Remove restriction on string position in hist trigger keys If we assume the maximum size for a string field, we don't have to worry about its position. Since we only allow two keys in a compound key and having more than one string key in a given compound key doesn't make much sense anyway, trading a bit of extra space instead of introducing an arbitrary restriction makes more sense. We also need to use the event field size for static strings when copying the contents, otherwise we get random garbage in the key. Also, cast string return values to avoid warnings on 32-bit compiles. Finally, rearrange the code without changing any functionality by moving the compound key updating code into a separate function. Link: http://lkml.kernel.org/r/8976e1ab04b66bc2700ad1ed0768a2de85ac1983.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events_hist.c | 63 ++++++++++++++++++++++------------------ 1 file changed, 35 insertions(+), 28 deletions(-) commit a4b8c18c40704c28be62af4606cc6758c9ff3dba Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 10:33:16 2016 +0200 ARM: shmobile: timer: Drop support for Cortex A8 Commit edf4100906044225 ("ARM: shmobile: sh7372 dtsi: Remove Legacy file") removed the DTS for the last shmobile SoC with a Cortex A8 CPU core (sh7372 aka SH-Mobile AP4), hence drop support for it in the loops-per-jiffy preset code. As "div" is always 1 for supported contemporary ARM processors, we can simplify the code: - Absorb shmobile_setup_delay_hz(), which was always called with mult = div = 1, - Return earlier if the Cortex A7/A15 arch timer exists and support is enabled. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/mach-shmobile/timer.c | 52 ++++++++++++++++-------------------------- 1 file changed, 20 insertions(+), 32 deletions(-) commit 79e577cbce4c4c2bf0d64ec315adb04eda40736b Author: Namhyung Kim <namhyung@kernel.org> Date: Thu Mar 3 12:54:53 2016 -0600 tracing: Support string type key properly The string in a trace event is usually recorded as dynamic array which is variable length. But current hist code only support fixed length array so it cannot support most strings. This patch fixes it by checking filter_type of the field and get proper pointer with it. With this, it can get a histogram of exec() based on filenames like below: # cd /sys/kernel/tracing/events/sched/sched_process_exec # cat 'hist:key=filename' > trigger # ps PID TTY TIME CMD 1 ? 00:00:00 init 29 ? 00:00:00 sh 38 ? 00:00:00 ps # ls enable filter format hist id trigger # cat hist # trigger info: hist:keys=filename:vals=hitcount:sort=hitcount:size=2048 [active] { filename: /usr/bin/ps } hitcount: 1 { filename: /usr/bin/ls } hitcount: 1 { filename: /usr/bin/cat } hitcount: 1 Totals: Hits: 3 Entries: 3 Dropped: 0 Link: http://lkml.kernel.org/r/610180d6df0cfdf11ee205452f3b241dea657233.1457029949.git.tom.zanussi@linux.intel.com Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Signed-off-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> [ Added (unsigned long) typecast to fix compile warning ] Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events_hist.c | 49 ++++++++++++++++++++++++++++++++++++---- 1 file changed, 45 insertions(+), 4 deletions(-) commit ea9b269fa561c6a4a452e85bc1af7e0288418b53 Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Tue Apr 12 13:01:34 2016 -0700 devicetree: bindings: designware-pcie: Fix unit address Remove the 0x in the unit address because it shouldn't be there. Cc: Joao Pinto <jpinto@synopsys.com> Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/pci/designware-pcie.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a8ca1b28acf543143bb96f62eb1423164accaa53 Author: Thierry Reding <treding@nvidia.com> Date: Tue Apr 12 17:07:36 2016 +0200 dt-bindings: tegra: Rename some bindings for consistency Device tree binding for NVIDIA Tegra have traditionally carried the "nvidia," vendor prefix in the filename. A couple of odd ones don't, so fix them up for consistency. Also rename existing bindings to reflect the first compatible value that they document. This wasn't done consistently either. Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rob Herring <robh@kernel.org> .../bindings/ata/nvidia,tegra124-ahci.txt | 32 ++ .../devicetree/bindings/ata/tegra-sata.txt | 32 -- .../bindings/cpufreq/nvidia,tegra124-cpufreq.txt | 44 +++ .../bindings/cpufreq/tegra124-cpufreq.txt | 44 --- .../bindings/dma/nvidia,tegra20-apbdma.txt | 44 +++ .../devicetree/bindings/dma/tegra20-apbdma.txt | 44 --- .../interrupt-controller/nvidia,tegra-ictlr.txt | 43 --- .../interrupt-controller/nvidia,tegra20-ictlr.txt | 43 +++ .../memory-controllers/nvidia,tegra-mc.txt | 116 ------- .../memory-controllers/nvidia,tegra124-emc.txt | 374 +++++++++++++++++++++ .../memory-controllers/nvidia,tegra30-mc.txt | 116 +++++++ .../bindings/memory-controllers/tegra-emc.txt | 374 --------------------- .../bindings/thermal/nvidia,tegra124-soctherm.txt | 55 +++ .../devicetree/bindings/thermal/tegra-soctherm.txt | 55 --- 14 files changed, 708 insertions(+), 708 deletions(-) commit f43521e9521133c169fe4b9255fb0917baf5ec84 Author: Thierry Reding <treding@nvidia.com> Date: Tue Apr 12 17:07:35 2016 +0200 dt-bindings: tegra: Remove 0, prefix from unit-addresses When Tegra124 support was first merged the unit-addresses of all devices were listed with a "0," prefix to encode the reg property's second cell. It turns out that this notation is not correct, and the "," separator is only used to separate fields in the unit address (such as the device and function number in PCI devices), not individual cells for addresses with more than one cell. Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/clock/nvidia,tegra124-dfll.txt | 2 +- Documentation/devicetree/bindings/gpu/nvidia,gk20a.txt | 2 +- .../devicetree/bindings/memory-controllers/nvidia,tegra-mc.txt | 6 +++--- Documentation/devicetree/bindings/memory-controllers/tegra-emc.txt | 4 ++-- .../devicetree/bindings/pinctrl/nvidia,tegra124-xusb-padctl.txt | 6 +++--- Documentation/devicetree/bindings/sound/nvidia,tegra30-hda.txt | 2 +- Documentation/devicetree/bindings/thermal/tegra-soctherm.txt | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) commit 7aa5d38cfb77d69a349ed47ce26a9d83bd6388d2 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:29:57 2016 +0100 of: Add Inforce Computing to vendor prefix list This patch adds Inforce Computing to vendor prefix list. This vendor makes boards like IFC6410, IFC6540 based on Qualcomm SOCs. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit af6858c3827d6d6aad3ebf2d4762ff1e59d0ed56 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Tue Apr 12 10:29:56 2016 +0100 of: Add Arrow Electronics to vendor prefix list This patch adds Arrow Electronics to vendor perfix list, as this vendor makes some of the Qualcomm SOC based 96boards like DB600c and DB410c. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 0f18d9245fe8b5613980baa8f03ba2e72d9c071b Author: Sergio Prado <sergio.prado@e-labworks.com> Date: Sat Apr 9 15:14:25 2016 -0300 of: Add vendor prefix for Shenzhen Embest Technology Signed-off-by: Sergio Prado <sergio.prado@e-labworks.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit ade50c2dd3f6523f727ed4163a00a5721a602743 Author: Schuyler Patton <spatton@ti.com> Date: Tue Mar 29 18:12:43 2016 +0530 Documentation: devicetree: bindings: regulator: palmas-pmic.txt Adding support for the tps659038 pmic so it doesn't generate a warning when running the patch check script to Documentation/devicetree/bindings/regulator/palmas-pmic.txt Adding a note that the tps659037 device is a OTP spin of the tps659038 pmic and device compatible. Signed-off-by: Schuyler Patton <spatton@ti.com> Signed-off-by: Keerthy <j-keerthy@ti.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/regulator/palmas-pmic.txt | 8 ++++++++ 1 file changed, 8 insertions(+) commit ba1800930d79c287dcef043dfc30486d168e05b8 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Mar 17 14:47:57 2016 +0000 dt-bindings: Correct path for ARM GIC documentation Commit eb3fcf007fff ("dt-bindings: consolidate interrupt controller bindings") moved the binding documentation for the ARM GIC from arm/gic.txt to interrupt-controller/arm,gic.txt. However, there are still some binding documents referring to the old path. Update these binding documents to use the correct location. Fixes: eb3fcf007fff ("dt-bindings: consolidate interrupt controller bindings") Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Matthias Brugger <matthias.bgg@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/arm/omap/crossbar.txt | 3 ++- Documentation/devicetree/bindings/arm/ux500/boards.txt | 2 +- .../devicetree/bindings/interrupt-controller/mediatek,sysirq.txt | 3 +-- 3 files changed, 4 insertions(+), 4 deletions(-) commit f2953a461042721e9a2aca58d2b1cfc67c70d371 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 16 12:53:29 2016 +0100 Documentation: devicetree: Clean up gpio-keys example Drop #address-cells and #size-cells, which are not required by the gpio-keys binding documentation, as button sub-nodes are not devices. Rename sub-nodes to avoid new dtc unit address warnings when copied. While at it, adopt the dashes convention for the node name. Reported-by: Julien Chauveau <chauveau.julien@gmail.com> Cc: Julien Chauveau <chauveau.julien@gmail.com> Cc: Javier Martinez Canillas <javier@dowhile0.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/input/gpio-keys.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit cb6c27bb09122ceb0effda0b15885123870a6af7 Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:22 2016 +0200 iommu/arm-smmu: Make use of phandle iterators in device-tree parsing Remove the usage of of_parse_phandle_with_args() and replace it by the phandle-iterator implementation so that we can parse out all of the potentially present 128 stream-ids. Signed-off-by: Joerg Roedel <jroedel@suse.de> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/iommu/arm-smmu.c | 38 ++++++++++++++++++++++++++++++-------- 1 file changed, 30 insertions(+), 8 deletions(-) commit abdaa77b18480361f3565d958a2acffad268c39c Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:21 2016 +0200 of: Introduce of_phandle_iterator_args() This helper function can be used to copy the arguments of a phandle to an array. Signed-off-by: Joerg Roedel <jroedel@suse.de> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 29 +++++++++++++++++++++++------ include/linux/of.h | 10 ++++++++++ 2 files changed, 33 insertions(+), 6 deletions(-) commit f623ce95a51baee6a6638f0b025efc0229a9ac0d Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:20 2016 +0200 of: Introduce of_for_each_phandle() helper macro With this macro any user can easily iterate over a list of phandles. The patch also converts __of_parse_phandle_with_args() to make use of the macro. The of_count_phandle_with_args() function is not converted, because the macro hides the return value of of_phandle_iterator_init(), which is needed in there. Signed-off-by: Joerg Roedel <jroedel@suse.de> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 7 +------ include/linux/of.h | 6 ++++++ 2 files changed, 7 insertions(+), 6 deletions(-) commit 2021bd01ffccf2728a591070008d7de5bc41306a Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:19 2016 +0200 of: Remove counting special case from __of_parse_phandle_with_args() The index = -1 case in __of_parse_phandle_with_args() is used to just return the number of phandles. That special case needs extra handling, so move it to the place where it is needed: of_count_phandle_with_args(). This allows to further simplify __of_parse_phandle_with_args() later on. Signed-off-by: Joerg Roedel <jroedel@suse.de> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) commit cd209b412c8a5d632b51af1e45576f0d00b8105f Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:18 2016 +0200 of: Move phandle walking to of_phandle_iterator_next() Move the code to walk over the phandles out of the loop in __of_parse_phandle_with_args() to a separate function that just works with the iterator handle: of_phandle_iterator_next(). Signed-off-by: Joerg Roedel <jroedel@suse.de> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 130 ++++++++++++++++++++++++++++++----------------------- include/linux/of.h | 7 +++ 2 files changed, 81 insertions(+), 56 deletions(-) commit 74e1fbb1375a3ede3e17da22911761ce9bc8f53f Author: Joerg Roedel <jroedel@suse.de> Date: Mon Apr 4 17:49:17 2016 +0200 of: Introduce struct of_phandle_iterator This struct carrys all necessary information to iterate over a list of phandles and extract the arguments. Add an init-function for the iterator and make use of it in __of_parse_phandle_with_args(). Signed-off-by: Joerg Roedel <jroedel@suse.de> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/base.c | 99 +++++++++++++++++++++++++++++++++--------------------- include/linux/of.h | 33 ++++++++++++++++++ 2 files changed, 93 insertions(+), 39 deletions(-) commit 34b82026a507ec0092398d9fc7893c00dd11b7da Author: Max Uvarov <muvarov@gmail.com> Date: Wed Apr 13 12:52:16 2016 +0300 fdt: fix extend of cmd line On arm CONFIG_CMDLINE_EXTEND does not append build-in cmdline in kernel to U-boot parameters. Fix it here. Theoretically this patch should repair kdump work where it adds elfcorehdr= and memmap additional parameters to second kernel. Signed-off-by: Max Uvarov <muvarov@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> drivers/of/fdt.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 5c1458478c49b905652fc002708d09369763f58f Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 28 16:49:24 2016 -0800 documentation: Add documentation for RCU's major data structures This commit adds documentation for RCU's major data structures, including rcu_state, rcu_node, rcu_data, rcu_dynticks, and rcu_head. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../Design/Data-Structures/BigTreeClassicRCU.svg | 474 +++++++ .../Design/Data-Structures/BigTreeClassicRCUBH.svg | 499 ++++++++ .../Data-Structures/BigTreeClassicRCUBHdyntick.svg | 695 ++++++++++ .../Data-Structures/BigTreePreemptRCUBHdyntick.svg | 741 +++++++++++ .../BigTreePreemptRCUBHdyntickCB.svg | 858 +++++++++++++ .../Design/Data-Structures/Data-Structures.html | 1333 ++++++++++++++++++++ .../Design/Data-Structures/HugeTreeClassicRCU.svg | 939 ++++++++++++++ .../RCU/Design/Data-Structures/TreeLevel.svg | 828 ++++++++++++ .../RCU/Design/Data-Structures/TreeMapping.svg | 305 +++++ .../Design/Data-Structures/TreeMappingLevel.svg | 380 ++++++ .../RCU/Design/Data-Structures/blkd_task.svg | 843 +++++++++++++ .../RCU/Design/Data-Structures/nxtlist.svg | 396 ++++++ 12 files changed, 8291 insertions(+) commit 8bcf4525c5d43306c5fd07e132bc8650e3491aec Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 24 13:03:49 2016 -0600 PCI: Mark Intel i40e NIC INTx masking as broken All of the i40e (XL710/X710) 10/20/40GbE NICs lack support for indicating INTx is asserted via the interrupt bit in the PCI status register. The DisINTx bit in the command register is functional, causing these devices to be incorrectly detected as supporting INTx masking. Quirk them to properly indicate no INTx masking support. Device IDs copied from i40e_devids.h. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> CC: John Ronciak <john.ronciak@intel.com> CC: Jesse Brandeburg <jesse.brandeburg@intel.com> drivers/pci/quirks.c | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 1ac42476263eec99fb2d3c31ee946cb44e80ddd5 Author: Paul Moore <paul@paul-moore.com> Date: Mon Apr 18 16:41:38 2016 -0400 selinux: check ss_initialized before revalidating an inode label There is no point in trying to revalidate an inode's security label if the security server is not yet initialized. Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 20cdef8d57591ec8674f65ccfe555aca5fd10b64 Author: Paul Moore <paul@paul-moore.com> Date: Mon Apr 4 14:14:42 2016 -0400 selinux: delay inode label lookup as long as possible Since looking up an inode's label can result in revalidation, delay the lookup as long as possible to limit the performance impact. Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 2c97165befb487c0dc8b25d39f457d0d91d22a6f Author: Paul Moore <paul@paul-moore.com> Date: Tue Apr 19 16:36:28 2016 -0400 selinux: don't revalidate an inode's label when explicitly setting it There is no point in attempting to revalidate an inode's security label when we are in the process of setting it. Reported-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 41b207a70d3a86b9e2eede155e87838234c7cbd5 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:06:15 2016 +0100 mtd: nand: implement the default mtd_ooblayout_ops Replace the default nand_ecclayout definitions for large and small page devices with the equivalent mtd_ooblayout_ops. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 142 ++++++++++++++++++++++++++++--------------- include/linux/mtd/nand.h | 3 + 2 files changed, 96 insertions(+), 49 deletions(-) commit 1bd0b24737710697e0a850fb1983dcdce1d01196 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:05:04 2016 +0100 mtd: docg3: switch to mtd_ooblayout_ops Replace the nand_ecclayout definition by the equivalent mtd_ooblayout_ops definition. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> drivers/mtd/devices/docg3.c | 46 ++++++++++++++++++++++++++++++++++----------- 1 file changed, 35 insertions(+), 11 deletions(-) commit adbbc3bc827eb1f43a932d783f09ba55c8ec8379 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 19:01:31 2016 +0100 mtd: create an mtd_ooblayout_ops struct to ease ECC layout definition ECC layout definitions are currently exposed using the nand_ecclayout struct which embeds oobfree and eccpos arrays with predefined size. This approach was acceptable when NAND chips were providing relatively small OOB regions, but MLC and TLC now provide OOB regions of several hundreds of bytes, which implies a non negligible overhead for everybody even those who only need to support legacy NANDs. Create an mtd_ooblayout_ops interface providing the same functionality (expose the ECC and oobfree layout) without the need for this huge structure. The mtd->ecclayout is now deprecated and should be replaced by the equivalent mtd_ooblayout_ops. In the meantime we provide a wrapper around the ->ecclayout field to ease migration to this new model. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/mtdchar.c | 4 +- drivers/mtd/mtdconcat.c | 2 +- drivers/mtd/mtdcore.c | 165 +++++++++++++++++++++++++++++++++++------------- drivers/mtd/mtdpart.c | 23 ++++++- include/linux/mtd/mtd.h | 32 ++++++++-- 5 files changed, 174 insertions(+), 52 deletions(-) commit 06af3b023c016bf97e39fbe22087b1d974f9e474 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:14:14 2016 +0100 mtd: docg3: use mtd_set_ecclayout() where appropriate Use the mtd_set_ecclayout() helper instead of directly assigning the mtd->ecclayout field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> drivers/mtd/devices/docg3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eb8c2be581e0f6c98830bc9eee09905f9fefed32 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:14:03 2016 +0100 mtd: onenand: use mtd_set_ecclayout() where appropriate Use the mtd_set_ecclayout() helper instead of directly assigning the mtd->ecclayout field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/onenand/onenand_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 70d105e4eec233d8f8758d604bfe6c411b6ded5f Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:13:50 2016 +0100 mtd: nand: use mtd_set_ecclayout() where appropriate Use the mtd_set_ecclayout() helper instead of directly assigning the mtd->ecclayout field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6a6da179308356cac0f1dde979b67094437ef16 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:13:26 2016 +0100 mtd: use mtd_set_ecclayout() where appropriate Use the mtd_set_ecclayout() helper instead of directly assigning the mtd->ecclayout field. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/mtdconcat.c | 2 +- drivers/mtd/mtdpart.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 036d6543f85319ffe96afad6de73d3a220917a63 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 18:53:44 2016 +0100 mtd: add mtd_set_ecclayout() helper function Add an mtd_set_ecclayout() helper function to avoid direct accesses to the mtd->ecclayout field. This will ease future reworks of ECC layout definition. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> include/linux/mtd/mtd.h | 6 ++++++ 1 file changed, 6 insertions(+) commit d30aae6d5630c27fa461f9da9ba2f40ae59e3287 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:12:31 2016 +0100 mtd: onenand: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/onenand/onenand_base.c | 75 ++++++++------------------------------ 1 file changed, 15 insertions(+), 60 deletions(-) commit aa02fcf555c8d42836584783288b33a2a0d40481 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 18 17:53:31 2016 +0100 mtd: nand: qcom: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to ecclayout fields, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Archit Taneja <architt@codeaurora.org> drivers/mtd/nand/qcom_nandc.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 8cfc1e8b68f3e0b144f17a94709c757c6db05b82 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:12:19 2016 +0100 mtd: nand: omap2: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/omap2.c | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) commit b9c0f65feab8a6dd4f37fdd8150cf5fe716304f5 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:12:04 2016 +0100 mtd: nand: lpc32xx: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/lpc32xx_slc.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) commit 191a82946a99fe110814860873cdfe64170c660b Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:11:44 2016 +0100 mtd: nand: gpmi: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 9ed92dd29015de67041cf45f364a46f1fa84bf79 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:11:32 2016 +0100 mtd: nand: fsl_ifc: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/fsl_ifc_nand.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit 78d28e8ec4fbd4d1e0c375d7a28f4f23e9e7b15e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:11:14 2016 +0100 mtd: nand: atmel: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/mtd/nand/atmel_nand.c | 50 +++++++++++++++++++++++++++---------------- 1 file changed, 31 insertions(+), 19 deletions(-) commit 846031d3e1837b71e350bd8098f00995069859a8 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:11:00 2016 +0100 mtd: nand: core: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 200 +++++++++++++++++++------------------------ drivers/mtd/nand/nand_bch.c | 13 ++- 2 files changed, 100 insertions(+), 113 deletions(-) commit c2b78452a9db438d592bf72af7bb2ae3062cb922 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Feb 3 20:10:30 2016 +0100 mtd: use mtd_ooblayout_xxx() helpers where appropriate The mtd_ooblayout_xxx() helper functions have been added to avoid direct accesses to the ecclayout field, and thus ease for future reworks. Use these helpers in all places where the oobfree[] and eccpos[] arrays where directly accessed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/mtdchar.c | 107 +++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 88 insertions(+), 19 deletions(-) commit 75eb2cec251fda33c9bb716ecc372819abb9278a Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Feb 4 09:52:30 2016 +0100 mtd: add mtd_ooblayout_xxx() helper functions In order to make the ecclayout definition completely dynamic we need to rework the way the OOB layout are defined and iterated. Create a few mtd_ooblayout_xxx() helpers to ease OOB bytes manipulation and hide ecclayout internals to their users. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/mtdcore.c | 400 ++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/mtd/mtd.h | 33 ++++ 2 files changed, 433 insertions(+) commit c4f3ef2c6c219c3e58e0f5a9589a67685a75d787 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 18:13:10 2016 +0100 mtd: nand: sunxi: make cur_off parameter optional in extra oob helpers Allow for NULL cur_offs values when the caller does not know where the NAND page register pointer points to. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 828dec153044805506cc2b8e39cb3f62d5f76a12 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 18:09:21 2016 +0100 mtd: nand: sunxi: make OOB retrieval optional sunxi_nfc_hw_ecc_read_chunk() always retrieves the ECC and protected free bytes, no matter if the user really asked for it or not. This can take a non negligible amount of time, especially on NAND chips exposing large OOB areas (> 1KB). Make it optional. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) commit cc6822fb756b5080ca127fef1a89f35558bd2610 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 17:56:47 2016 +0100 mtd: nand: sunxi: move some ECC related operations to their own functions In order to support DMA operations in a clean way we need to extract some of the logic coded in sunxi_nfc_hw_ecc_read/write_page() into their own function. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 163 ++++++++++++++++++++++++++++-------------- 1 file changed, 108 insertions(+), 55 deletions(-) commit c0c9dfa8adf09dbbb7dc32c20d9ccb33e19250c0 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Mon Mar 7 15:34:39 2016 +0100 mtd: nand: sunxi: poll for events instead of using interrupts Some NAND operations are so fast that it doesn't make any sense to use interrupt based waits (the scheduling overhead is not worth it). Rename sunxi_nfc_wait_int() into sunxi_nfc_wait_events() and add a parameter to specify whether polling should be used or not. Note that all sunxi_nfc_wait_int() are moved to the polling approach now, but this should change as soon as we have more information about the approximate time we are about to wait (can be extracted from the NAND timings, and the type of operation). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 45 +++++++++++++++++++++++++++++-------------- 1 file changed, 31 insertions(+), 14 deletions(-) commit 166f08c7b6ab2f98eebbb6fc1fdb0be1efe0a566 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Mon Mar 7 15:25:17 2016 +0100 mtd: nand: sunxi: make use of readl_poll_timeout() Replace open coded polling loops by readl_poll_timeout() calls. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) commit a9a416f0c723e10ecccfe7ea30e93dfee0dbf10d Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Mon Mar 7 15:10:28 2016 +0100 mtd: nand: sunxi: fix ->dev_ready() implementation ->dev_ready() is not supposed to wait for busy to ready solution (this is the role of ->waitfunc()). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 7 ------- 1 file changed, 7 deletions(-) commit 336de7b1e07e6c666dbed522120547b852b3fba7 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 17:33:10 2016 +0100 mtd: nand: enable ECC pipelining When the NAND controller operates in DMA mode it can pipeline ECC operations which improves the throughput. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit dd26a4584c37687b8bbe89233bcc23279ca361b1 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 18:26:40 2016 +0100 mtd: nand: sunxi: disable clks on device removal mod and ahb clocks are not disabled when the NAND controller device is removed. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 2 ++ 1 file changed, 2 insertions(+) commit 68ffbf7f9fb11323238cb31c956b4f381e6b05cc Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 17:29:20 2016 +0100 mtd: nand: sunxi: fix NFC_CTL setting NFC_PAGE_SHIFT() already takes the real page_shift value and subtract 10 to it. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f8b04746a4ba389d609b5ddcfbf95835c7dfcb31 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 17:25:08 2016 +0100 mtd: nand: sunxi: fix the NFC_ECC_ERR_CNT() macro NFC_ECC_ERR_CNT() is not taking into account the case when the NAND chip contains more than 4 ECC blocks (NANDs with 4kB+ pages). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ece03cfd5260e0349442dea1d1065f44fbed1ea8 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Mar 4 17:21:35 2016 +0100 mtd: nand: sunxi: let the NAND controller control the CE line We don't need to manually toggle the CE line since the controller handles it for us. Moreover, keeping the CE line low when interacting with a DDR NAND can be problematic (data loss in some corner cases). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 10 ---------- 1 file changed, 10 deletions(-) commit e9aa671f69acb87db4835e4f0b41f5fa16d16562 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Sep 16 09:05:31 2015 +0200 mtd: nand: sunxi: improve ->cmd_ctrl() function Try to pack address and command cycles into a single NAND controller command to avoid polling the status register for each single change on the NAND bus. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 52 ++++++++++++++++++++++++++++++++++++------- 1 file changed, 44 insertions(+), 8 deletions(-) commit fe82ccefc992b255c35e0e56d6aded2ce090e9af Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Sep 16 09:01:45 2015 +0200 mtd: nand: sunxi: implement ->read_subpage() Being able to read subpages can greatly improve read performances if the MTD user is only interested in a small section of a NAND page. This is particularly true with large pages (>= 8k). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) commit 1c1bdd6f866e08b2a34318ce089b678200e8de85 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Sep 2 15:05:52 2015 +0200 mtd: nand: sunxi: implement ->read_oob()/->write_oob() Allwinner's ECC engine is capable of protecting a few bytes of the OOB area. Implement specific OOB functions to benefit from this capability. Also, when in raw mode, the randomizer is disabled, which means you'll only be able to retrieve randomized data, which is not really useful for most applications. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 9d02fc2a5129449581c3108c260e96377cf35f7e Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Aug 26 16:08:12 2015 +0200 mtd: nand: export default read/write oob functions Export the default read/write oob functions (for the standard and syndrome scheme), so that drivers can use them for their raw implementation and implement their own functions for the normal oob operation. This is required if your ECC engine is capable of fixing some of the OOB data. In this case you have to overload the ->read_oob() and ->write_oob(), but if you don't specify the ->read/write_oob_raw() functions they are assigned to the ->read/write_oob() implementation, which is not what you want. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 18 ++++++++++-------- include/linux/mtd/nand.h | 14 ++++++++++++++ 2 files changed, 24 insertions(+), 8 deletions(-) commit 5abcd95d8c69008c72d54d7763e0ee2b5df84ac4 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Nov 11 22:30:30 2015 +0100 mtd: nand: sunxi: adapt clk_rate to tWB, tADL, tWHR and tRHW timings Adapt the NAND controller clk rate to the tWB, tADL, tWHR and tRHW timings instead of returning an error when the maximum clk divisor is not big enough to provide an appropriate timing. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 2d43457f79e48ee427666fdbfe9a53f35d3a1672 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Dec 2 15:57:20 2015 +0100 mtd: nand: sunxi: fix EDO mode selection The ONFI spec says that EDO should be enabled if the host drives tRC less than 30ns, but the code just tests for the tRC_min value extracted from the timings exposed by the NAND chip not the timings actually configured in the NAND controller. Fix that by first rounding down the requested clk_rate with clk_round_rate() and then checking if tRC is actually smaller than 30ns. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) commit 2f9992e080b8892a10d189cbc846c06e6594ad0b Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Dec 2 15:10:40 2015 +0100 mtd: nand: sunxi: fix clk rate calculation Unlike what is specified in the Allwinner datasheets, the NAND clock rate is not equal to 2/T but 1/T. Fix the clock rate selection accordingly. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 9edb47004e2afb5884d0c900cbd1ece8b2d6f403 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Dec 2 16:00:57 2015 +0100 mtd: nand: sunxi: fix call order in sunxi_nand_chip_init() sunxi_nand_chip_set_timings() is extracting a pointer to the nfc from the nand->controller field, but this field is initialized after sunxi_nand_chip_set_timings() call. Reorder the calls to avoid any problem. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/sunxi_nand.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit 44ccb64fa56ad6d6d2d33a8625d9464f54c63eba Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:30 2016 +0200 mtd: nand: pxa3xx: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> drivers/mtd/nand/pxa3xx_nand.c | 28 +++++++++++----------------- 1 file changed, 11 insertions(+), 17 deletions(-) commit 4f3cab9b4457108a8241ec7a66e03fe0b2cb3646 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:22 2016 +0200 mtd: nand: atmel: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/mtd/nand/atmel_nand.c | 133 +++++++++++++++++++++++------------------- 1 file changed, 73 insertions(+), 60 deletions(-) commit ff05fdb187cc25bff3e7ee9f79d94077c8d16a44 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 13 11:48:05 2016 +0200 mtd: nand: pasemi: switch to dev_* printing functions It also contains some minor related changes: 1) Don't warn if kzalloc fails as it dumps stack on its own 2) Use %pR format for displaying whole resource to avoid invalid format warning Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/pasemi_nand.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit ce111afd01bce7c137c92e9ed0dbe294a0f2373a Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:51 2016 +0200 mtd: nand: socrates: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/socrates_nand.c | 1 + 1 file changed, 1 insertion(+) commit 41ccb49e9123e268e8f84d019893cacd6a312c69 Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:50 2016 +0200 mtd: nand: plat: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/plat_nand.c | 1 + 1 file changed, 1 insertion(+) commit a9670a9c7ff9488d66d6fd7593415bb978017509 Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:49 2016 +0200 mtd: nand: pasemi: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/pasemi_nand.c | 1 + 1 file changed, 1 insertion(+) commit ac7efcbe0e3d64565f5b086d231589e3637e9b0b Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:48 2016 +0200 mtd: nand: orion: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/orion_nand.c | 1 + 1 file changed, 1 insertion(+) commit 37afb2034f17c5f17423bfe5a4fc100d6803b554 Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:47 2016 +0200 mtd: nand: nuc900: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nuc900_nand.c | 1 + 1 file changed, 1 insertion(+) commit c1c7040e072caac6445a1e298bd1fc5e8da0a5f5 Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:46 2016 +0200 mtd: nand: mxc: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/mxc_nand.c | 1 + 1 file changed, 1 insertion(+) commit 050658c8f9bd8d7b2addf40f6a5b340d5d4ec21a Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:45 2016 +0200 mtd: nand: gpio: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/gpio.c | 1 + 1 file changed, 1 insertion(+) commit e58dd3c33d3046c3ad3c849cb95365b45b9ecb5f Author: Rafał Miłecki <zajec5@gmail.com> Date: Fri Apr 8 12:23:44 2016 +0200 mtd: nand: ams-delta: set ECC algorithm explicitly This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to enum nand_ecc_algo). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/ams-delta.c | 1 + 1 file changed, 1 insertion(+) commit 541e3c8912fe4257ba0b71908ea8fbf79143f510 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:24 2016 +0200 mtd: nand: brcm: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/nand/brcmnand/brcmnand.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit f679888f29fe5c4a4c44459f2c1fc62b72188773 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Apr 19 20:29:58 2016 +0200 mtd: nand: omap2: rely on generic DT parsing done in nand_scan_ident() The core now takes care of parsing generic DT properties in nand_scan_ident() when nand_set_flash_node() has been called. Rely on this initialization instead of calling of_get_nand_xxx() manually. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Roger Quadros <rogerq@ti.com> Tested-by: Franklin S Cooper Jr. <fcooper@ti.com> drivers/memory/omap-gpmc.c | 4 ++-- drivers/mtd/nand/omap2.c | 18 +++++++----------- 2 files changed, 9 insertions(+), 13 deletions(-) commit 24d990e237d1822fb108ed9be41d1542af001185 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:54:21 2016 +0200 mtd: nand: remove unneeded of_mtd.h inclusions Some drivers are including linux/of_mtd.h even if they don't use any of the of_get_nand_xxx() helpers. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Harvey Hunt <harvey.hunt@imgtec.com> drivers/mtd/nand/jz4780_nand.c | 1 - drivers/mtd/nand/lpc32xx_mlc.c | 1 - drivers/mtd/nand/qcom_nandc.c | 1 - drivers/mtd/nand/sunxi_nand.c | 1 - drivers/mtd/nand/vf610_nfc.c | 1 - 5 files changed, 5 deletions(-) commit 03a97550941d17c7d5b621afde5945bbc0da6546 Author: Zhaoxiu Zeng <zhaoxiu.zeng@gmail.com> Date: Tue Apr 12 15:30:35 2016 +0800 mtd: nand: s3c2410: fix bug in s3c2410_nand_correct_data() If there is only one bit difference in the ECC, the function should return 1. The result of "diff0 & ~(1<<fls(diff0))" is equal to diff0, so the function actually returns -1. Signed-off-by: Zhaoxiu Zeng <zhaoxiu.zeng@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/s3c2410.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7a654172161c8c9c7d59cbd0054d9e63c7411219 Author: Raghav Dogra <raghav.dogra@nxp.com> Date: Wed Feb 17 16:54:18 2016 +0530 mtd/ifc: Add support for IFC controller version 2.0 The new IFC controller version 2.0 has a different memory map page. Upto IFC 1.4 PAGE size is 4 KB and from IFC2.0 PAGE size is 64KB. This patch segregates the IFC global and runtime registers to appropriate PAGE sizes. Signed-off-by: Jaiprakash Singh <b44839@freescale.com> Signed-off-by: Raghav Dogra <raghav@freescale.com> Acked-by: Li Yang <leoyang.li@nxp.com> Signed-off-by: Raghav Dogra <raghav.dogra@nxp.com> Acked-by: Scott Wood <oss@buserror.net> Acked-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/memory/fsl_ifc.c | 36 ++++++++++----------- drivers/mtd/nand/fsl_ifc_nand.c | 72 ++++++++++++++++++++++------------------- include/linux/fsl_ifc.h | 45 +++++++++++++++++--------- 3 files changed, 87 insertions(+), 66 deletions(-) commit 11eaf6df1cce3c5e9f51b422aaedc42dc4aa1d37 Author: Ezequiel García <ezequiel@vanguardiasur.com.ar> Date: Fri Apr 1 18:29:24 2016 -0300 mtd: nand: Remove BUG() abuse in nand_scan_tail There's no reason to BUG() when parameters are being validated. Drivers can get things wrong, and it's much nicer to just throw a noisy warn and fail gracefully, than calling BUG() and throwing the whole system down the drain. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Reviewed-by: Richard Weinberger <richard@nod.at> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 52 ++++++++++++++++++++++++++++---------------- 1 file changed, 33 insertions(+), 19 deletions(-) commit 2cd395d13a104cd96ddae5c5612871dc18553cca Author: Han Xu <han.xu@nxp.com> Date: Mon Apr 4 15:41:29 2016 -0500 mtd: gpmi: fix raw_buffer pointer double free issue fix the raw_buffer pointer double free issue found by coverify. CID 18344 (#2 of 2): Double free (USE_AFTER_FREE) 3. double_free: Calling gpmi_alloc_dma_buffer frees pointer this->raw_buffer which has already been freed Signed-off-by: Han Xu <han.xu@nxp.com> Reviewed-by: Richard Weinberger <richard@nod.at> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 1 + 1 file changed, 1 insertion(+) commit 269ecf03a5b32b0d1de1f60a4b86b75c0521053f Author: Florian Fainelli <f.fainelli@gmail.com> Date: Thu Mar 10 15:34:16 2016 -0800 mtd: brcmnand: Add support for v6.2 controllers Document and match the brcm,brcmnand-v6.2 compatible string, the controller has a register layout identical to the v6.0 version and supports prefetch. Update the command shift logic to account for v6.2 controller which are the first ones to use a shift of 0 (6.1 used a shift of 24). Signed-off-by: Kamal Dasu <kdasu.kdev@gmail.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Documentation/devicetree/bindings/mtd/brcm,brcmnand.txt | 1 + drivers/mtd/nand/brcmnand/brcmnand.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit 2d472aba15ff169a30dc3661f837d8535af9b9ee Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Fri Apr 1 14:26:35 2016 +0200 mtd: nand: document the NAND controller/NAND chip DT representation Standardize the NAND controller/NAND chip DT representation. Now, all new NAND controller drivers should comply with this representation, even if they are only supporting a single NAND chip. Existing drivers can keep support for the old representation (where only the NAND chip was described), but are encouraged to also support the new one. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/mtd/nand.txt | 37 +++++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) commit ce8716e97149d15379603890c4c7a2acfcf4a7ee Author: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org> Date: Wed Mar 23 21:53:27 2016 -0400 mtd: nand: jz4780: fixup, device structure assigned at probe bch->dev is already assigned to &pdev->dev in the probe function. Remove the duplicate assignment done in jz4780_bch_get(). Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Acked-by: Harvey Hunt <harvey.hunt@imgtec.com> drivers/mtd/nand/jz4780_bch.c | 1 - 1 file changed, 1 deletion(-) commit ff6ee101584c17c4f30ca48d75e2910c49d0b0ff Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Mar 1 14:11:52 2016 +0100 mtd: nand: atmel: correct bitflips in erased pages for pre-sama5d4 SoCs New atmel SoCs are able to fix bitflips in erased pages, but old ones are still impacted by this problem. Use nand_check_erased_ecc_chunk() to handle this case. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reported-by: Herve Codina <herve.CODINA@celad.com> Reviewed-by: Herve Codina <herve.CODINA@celad.com> Tested-by: Herve Codina <herve.CODINA@celad.com> drivers/mtd/nand/atmel_nand.c | 37 ++++++++++++++++++++----------------- 1 file changed, 20 insertions(+), 17 deletions(-) commit 8ae6bcd1dcea249591b4165bd7f795c4868bc531 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 11:19:03 2016 +0100 mtd: nand: nandsim: set ECC algorithm explicitly This follows recent work on switching to enum nand_ecc_algo and deprecating NAND_ECC_SOFT_BCH. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nandsim.c | 2 ++ 1 file changed, 2 insertions(+) commit 79082457d71af879922e15f9dedf85384e84c29f Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 11:19:02 2016 +0100 mtd: nand: set ECC algorithm in nand_dt_init Use recently added of_get_nand_ecc_algo for that. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/mtd/nand/nand_base.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit dd2dcc004230b9d8fa809102cd326e3ee4bbdb2a Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 11:19:01 2016 +0100 of: mtd: prepare helper reading NAND ECC algo from DT NAND subsystem is being slightly reworked to store ECC details in separated fields. In future we'll want to add support for more DT properties as specifying every possible setup with a single "nand-ecc-mode" is a pretty bad idea. To allow this let's add a helper that will support something like "nand-ecc-algo" in future. Right now we use it for keeping backward compatibility. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> drivers/of/of_mtd.c | 36 ++++++++++++++++++++++++++++++++++++ include/linux/of_mtd.h | 6 ++++++ 2 files changed, 42 insertions(+) commit b0fcd8ab7b3c89b5da7fff5224d06ed73e7a33cc Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 11:19:00 2016 +0100 mtd: nand: add new enum for storing ECC algorithm Our nand_ecc_modes_t is already a bit abused by value NAND_ECC_SOFT_BCH. This enum should store ECC mode only and putting algorithm details there is a bad idea. It would result in too many values impossible to support in a sane way. To solve this problem let's add a new enum. We'll have to modify all drivers to set it properly but once it's done it'll be possible to drop NAND_ECC_SOFT_BCH. That will result in a cleaner design and more possibilities like setting ECC algorithm for hardware ECC mode. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> include/linux/mtd/nand.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit aaa3ca82286d53c5409d2c22204426c9ca419d8c Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Apr 8 18:26:52 2016 +0300 intel_th: pci: Add Broxton-M SOC support This adds Intel(R) Trace Hub PCI ID for Broxton-M SOC. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/pci.c | 5 +++++ 1 file changed, 5 insertions(+) commit 8de53481b433e45638e8e5252cbfeb78d64ca4d9 Merge: 4217ff3 fea728c Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Apr 19 21:44:11 2016 +0200 Merge branch 'mtd-nand-trigger' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds into nand/next Pull leds-trigger changes from Jacek Anaszewski. Create a generic mtd led-trigger to replace the exisitng nand led-trigger implementation. * 'mtd-nand-trigger' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds: mtd: Hook I/O activity to the MTD LED trigger mtd: nand: Remove the "nand-disk" LED trigger leds: trigger: Introduce a MTD (NAND/NOR) trigger mtd: Uninline mtd_write_oob and move it to mtdcore.c leds: trigger: Introduce a kernel panic LED trigger commit 4217ff3509f95e12d98729a202ae068709226ad5 Merge: f55532a 10f22ee Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Apr 19 21:39:22 2016 +0200 Merge branch 'for-v4.7/gpmc-mtd-common' of github.com:rogerq/linux into nand/next Pull NAND/GPMC updates from Roger Quadros: "We do a couple of things in this series which result in cleaner device tree implementation, faster perfomance and multi-platform support. As an added bonus we get to use the GPMC_WAIT pins as GPI/Interrupts. - Establish a custom interface between NAND and GPMC driver. This is needed because all of the NAND registers sit in the GPMC register space. - Clean up device tree support so that omap-gpmc IP and the omap2 NAND driver can be used on non-OMAP platforms. e.g. Keystone. - Implement GPIOCHIP for the GPMC WAITPINS. SoCs can contain 2 to 4 of these and most of them would be unused otherwise. It also allows a cleaner implementation of NAND Ready pin status for the NAND driver. - Implement GPMC IRQ domain to proivde the 2 NAND events and GPMC WAITPIN edge interrupts. - Implement GPIOlib based NAND ready pin checking for OMAP NAND driver. On dra7-evm, Read speed increases from 13768 KiB/ to 17246 KiB/s. Write speed was unchanged at 7123 KiB/s." * 'for-v4.7/gpmc-mtd-common' of github.com:rogerq/linux: mtd: nand: omap2: Implement NAND ready using gpiolib memory: omap-gpmc: Prevent GPMC_STATUS from being accessed via gpmc_regs memory: omap-gpmc: Support WAIT pin edge interrupts memory: omap-gpmc: Reserve WAITPIN if needed for WAIT monitoring memory: omap-gpmc: Support general purpose input for WAITPINs memory: omap-gpmc: Move device tree binding to correct location memory: omap-gpmc: Prevent mapping into 1st 16MB mtd: nand: omap: Update DT binding documentation mtd: nand: omap: Clean up device tree support mtd: nand: omap: Copy platform data parameters to omap_nand_info data mtd: nand: omap: Switch to using GPMC-NAND ops for writebuffer empty check mtd: nand: omap: Use gpmc_omap_get_nand_ops() to get NAND registers memory: omap-gpmc: Implement IRQ domain for NAND IRQs memory: omap-gpmc: Add GPMC-NAND ops to get writebufferempty status memory: omap-gpmc: Introduce GPMC to NAND interface ARM: OMAP2+: gpmc: Add gpmc timings and settings to platform data ARM: OMAP2+: gpmc: Add platform data commit 2b4e6286484c3eeae2c80063c510166c63d7cb85 Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Apr 19 21:17:55 2016 +0200 clk: rockchip: drop unnecessary header comment The internal clk header did contain a comment indicating that some of the defined registers were shared over multiple clock controller variants. In recent times, it was simply extended all the time and stopped providing any meaningful information, so drop it and it's overlong line. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.h | 1 - 1 file changed, 1 deletion(-) commit 995d3fdeb2f2d362b1b6bf26656c417452939a1a Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Apr 19 21:07:01 2016 +0200 clk: rockchip: reign in some overly long lines in the rk3399 controller We allow overlong lines in the array portitions describing the clock trees to ease readability by having each element always at the same position. But the rest of the code should honor the 80 char limit. Fix the newly added rk3399 clock code to respect that. Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3399.c | 139 ++++++++++++++++++++++---------------- 1 file changed, 81 insertions(+), 58 deletions(-) commit dc2c57153ec5119eae7770042197eff627184d74 Author: Alison Schofield <amsfield22@gmail.com> Date: Sun Apr 10 12:08:14 2016 -0700 iio: gyro: bmg160: use regmap to retrieve struct device Driver includes struct regmap and struct device in its global data. Remove the struct device and use regmap API to retrieve device info. Patch created using Coccinelle plus manual edits. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/gyro/bmg160_core.c | 86 +++++++++++++++++++++--------------------- 1 file changed, 44 insertions(+), 42 deletions(-) commit 0ef4c311abdc821d10e092ae623e022dd4b6a6d4 Author: Alison Schofield <amsfield22@gmail.com> Date: Sun Apr 10 12:05:13 2016 -0700 iio: accel: bmc150: use regmap to retrieve struct device Driver includes struct regmap and struct device in its global data. Remove the struct device and use regmap API to retrieve device info. Patch created using Coccinelle plus manual edits. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Irina Tirdea <irina.tirdea@intel.com> Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/bmc150-accel-core.c | 99 +++++++++++++++++++---------------- 1 file changed, 54 insertions(+), 45 deletions(-) commit dfd2ab8dda719b98203f5b3e940961019d373541 Author: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Date: Sun Mar 20 16:20:24 2016 +0100 iio: Add Vishay VEML6070 UV A light sensor driver ultraviolet (UV) light sensor with I2C interface with a peak sensitivity at 355 nm strangely, chip uses two addresses 0x38 and 0x39 for LSB and MSB data, resp. datasheet: http://www.vishay.com/docs/84277/veml6070.pdf Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/Kconfig | 10 ++ drivers/iio/light/Makefile | 1 + drivers/iio/light/veml6070.c | 218 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 229 insertions(+) commit e21a294d1e35e890c1b5f0a29df15f75c8934a73 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Apr 6 16:01:08 2016 +0530 iio: Add resource managed APIs devm_iio_channel_{get,release) in devres Add following APIs in the list of managed resources of IIO: devm_iio_channel_get() devm_iio_channel_get_all() devm_iio_channel_release() devm_iio_channel_release_all() Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/driver-model/devres.txt | 4 ++++ 1 file changed, 4 insertions(+) commit efc2c0133f198bc65593a67015af358919b0c48f Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Apr 6 16:01:07 2016 +0530 iio: core: Add devm_ APIs for iio_channel_{get,release}_all Some of kernel driver uses the IIO framework to get the sensor value via ADC or IIO HW driver. The client driver get iio channel by iio_channel_get_all() and release it by calling iio_channel_release_all(). Add resource managed version (devm_*) of these APIs so that if client calls the devm_iio_channel_get_all() then it need not to release it explicitly, it can be done by managed device framework when driver get un-binded. This reduces the code in error path and also need of .remove callback in some cases. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/inkern.c | 36 ++++++++++++++++++++++++++++++++++++ include/linux/iio/consumer.h | 26 ++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) commit 8bf872d8d261feefcdf67027522e3f717cad2bfe Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Apr 6 16:01:06 2016 +0530 iio: core: Add devm_ APIs for iio_channel_{get,release} Some of kernel driver uses the IIO framework to get the sensor value via ADC or IIO HW driver. The client driver get iio channel by iio_channel_get() and release it by calling iio_channel_release(). Add resource managed version (devm_*) of these APIs so that if client calls the devm_iio_channel_get() then it need not to release it explicitly, it can be done by managed device framework when driver get un-binded. This reduces the code in error path and also need of .remove callback in some cases. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/inkern.c | 48 ++++++++++++++++++++++++++++++++++++++++++++ include/linux/iio/consumer.h | 27 +++++++++++++++++++++++++ 2 files changed, 75 insertions(+) commit 5f991a921a08279f573fa5ecf84261a3a6fac0cc Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 14 10:26:47 2016 +0200 iio: tools: generic_buffer: auto-enable channels If no channels are enabled when we run generic_buffer on a device, add a command-line option to just enable all of them, run the sampling and disable them all again afterwards. This is extremely useful when I'm low-level testing my sensors with interrupts and triggers, sample session: root@Ux500:/ lsiio Device 000: lsm303dlh_accel Device 001: lis331dl_accel Device 002: l3g4200d Device 003: lsm303dlh_magn Device 004: lps001wp Trigger 000: lsm303dlh_accel-trigger Trigger 001: lis331dl_accel-trigger Trigger 002: l3g4200d-trigger root@Ux500:/ generic_buffer -a -c 10 -n l3g4200d iio device number being used is 2 iio trigger number being used is 2 No channels are enabled, enabling all channels Enabling: in_anglvel_x_en Enabling: in_anglvel_y_en Enabling: in_anglvel_z_en Enabling: in_timestamp_en /sys/bus/iio/devices/iio:device2 l3g4200d-trigger -3.593664 -0.713133 4.870143 946684863662292480 3.225546 0.867357 -4.945878 946684863671875000 -0.676413 0.127296 0.106641 946684863681488037 -0.661113 0.110160 0.128826 946684863690673828 -0.664173 0.113067 0.123471 946684863700683593 -0.664938 0.109395 0.124848 946684863710144042 -0.664173 0.110619 0.130203 946684863719512939 -0.666162 0.111231 0.132651 946684863729125976 -0.668610 0.111690 0.130662 946684863738739013 -0.660501 0.110466 0.131733 946684863748565673 Disabling: in_anglvel_x_en Disabling: in_anglvel_y_en Disabling: in_anglvel_z_en Disabling: in_timestamp_en Pure awesomeness. If some channels have been enabled through scripts or manual interaction, nothing happens. Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Acked-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> tools/iio/generic_buffer.c | 102 +++++++++++++++++++++++++++++++++++++++++++-- tools/iio/iio_utils.h | 7 ++++ 2 files changed, 105 insertions(+), 4 deletions(-) commit 0e6f6871a1591f4bb0971809c45bc91a991f1967 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Apr 14 10:45:21 2016 +0200 iio: st_sensors: support open drain mode Some types of ST Sensors can be connected to the same IRQ line as other peripherals using open drain. Add a device tree binding and a sensor data property to flip the right bit in the interrupt control register to enable open drain mode on the INT line. If the line is set to be open drain, also tag on IRQF_SHARED to the IRQ flags when requesting the interrupt, as the whole point of using open drain interrupt lines is to share them with more than one peripheral (wire-or). Cc: devicetree@vger.kernel.org Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Acked-by: Rob Herring <rob@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/devicetree/bindings/iio/st-sensors.txt | 4 ++++ drivers/iio/accel/st_accel_core.c | 8 ++++++++ drivers/iio/common/st_sensors/st_sensors_core.c | 20 ++++++++++++++++++++ drivers/iio/common/st_sensors/st_sensors_trigger.c | 13 +++++++++++++ drivers/iio/pressure/st_pressure_core.c | 8 ++++++++ include/linux/iio/common/st_sensors.h | 6 ++++++ include/linux/platform_data/st_sensors_pdata.h | 2 ++ 7 files changed, 61 insertions(+) commit 97865fe41322d83dac4373fe0a0de5b1a1b318c5 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 14:18:05 2016 +0100 iio: st_sensors: verify interrupt event to status This makes all ST sensor drivers check that they actually have new data available for the requested channel(s) before claiming an IRQ, by reading the status register (which is conveniently the same for all ST sensors) and check that the channel has new data before proceeding to read it and fill the buffer. This way sensors can share an interrupt line: it can be flaged as shared and then the sensor that did not fire will return NO_IRQ, and the sensor that fired will handle the IRQ and return IRQ_HANDLED. Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/st_accel_core.c | 5 +++++ drivers/iio/common/st_sensors/st_sensors_buffer.c | 18 ++++++++++++++++++ drivers/iio/gyro/st_gyro_core.c | 3 +++ drivers/iio/magnetometer/st_magn_core.c | 1 + drivers/iio/pressure/st_pressure_core.c | 2 ++ include/linux/iio/common/st_sensors.h | 3 +++ 6 files changed, 32 insertions(+) commit 6436db37b4a5da1ae1f381e4791e17e2236fd276 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 14:18:04 2016 +0100 iio: st_sensors: read each channel individually The current buffer read code tries to optimize reads from the sensor data registers by issuing a single read operation across all the indata registers. This doesn't work: when the LIS331DL accelerometer sensor is configured to open drain, active low interrupt mode, this will just clear the XDA (X-axis data available) bit in the STATUS_REG register (0x27), while YDA, ZDA and even ZYXDA remain set to 1, and the internal logic of the sensor holds the DRDY (INT1) line asserted (the value of the status register is 0xee). If we instead issue one read operation per enabled channel (X, Y, Z) things start working and we can use open drain and active low interrupts. Note that a backported patch fixing this issue will be heading via the fixes branch but changes in this file already in staging-next will make that patch 'look' rather different. The code in here is the correct one when that clash hits. Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/st_sensors/st_sensors_buffer.c | 63 +++++------------------ 1 file changed, 13 insertions(+), 50 deletions(-) commit 850c25c857647e4095c4290e32eb62395f9c8117 Author: Stefan Wahren <stefan.wahren@i2se.com> Date: Thu Apr 14 15:48:27 2016 +0000 iio: mxs-lradc: move STMP reset out of ADC init This patch moves the STMP reset out of ADC init function so as to remove the possiblity of an error return which will be necessary for PM ops support patches to follow. Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Tested-by: Marek Vasut <marex@denx.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/mxs-lradc.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 9cf6fcc15aa90bf742fc3d9325992867c130e6ce Author: Stefan Wahren <stefan.wahren@i2se.com> Date: Thu Apr 14 15:48:26 2016 +0000 iio: mxs-lradc: move TS config into suitable function This patch moves the touchscreen type configuration into a more suitable function. Btw this simplifies PM ops later. Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Reviewed-by: Marek Vasut <marex@denx.de> Tested-by: Marek Vasut <marex@denx.de> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/mxs-lradc.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit bc5ce155d9d769f86a63a1301fb295ea3fcf22b2 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Tue Apr 5 03:08:26 2016 +0100 ARM: 8557/1: specify install, zinstall, and uinstall as PHONY targets Obviously, these are PHONY targets. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/boot/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6e8ac724bf45d116195d57fbe3a949f570c35635 Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Tue Apr 19 06:05:09 2016 +0100 ARM: 8562/1: suppress "include/generated/mach-types.h is up to date." For incremental build, "include/generated/mach-types.h is up to date" is every time displayed like follows: $ make ARCH=arm CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h make[1]: `include/generated/mach-types.h' is up to date. CHK include/generated/bounds.h CHK include/generated/timeconst.h CHK include/generated/asm-offsets.h This commit avoids such a clumsy log and introduces Kbuild standard log style: GEN include/generated/mach-types.h Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/tools/Makefile | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit 18402843bf88c2e9674e1a3a05c73b7d9b09ee05 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 19 14:30:10 2016 -0400 net: Align IFLA_STATS64 attributes properly on architectures that need it. Since the nlattr header is 4 bytes in size, it can cause the netlink attribute payload to not be 8-byte aligned. This is particularly troublesome for IFLA_STATS64 which contains 64-bit statistic values. Solve this by creating a dummy IFLA_PAD attribute which has a payload which is zero bytes in size. When HAVE_EFFICIENT_UNALIGNED_ACCESS is false, we insert an IFLA_PAD attribute into the netlink response when necessary such that the IFLA_STATS64 payload will be properly aligned. With help and suggestions from Eric Dumazet. Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_link.h | 1 + net/core/rtnetlink.c | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) commit a163f2cb393d9d71cad57bfe6a8c7f452a478fb4 Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 11 21:14:29 2016 +0200 netfilter: conntrack: don't acquire lock during seq_printf read access doesn't need any lock here. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_proto_sctp.c | 8 +------- net/netfilter/nf_conntrack_proto_tcp.c | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) commit 041f9d336f28d3a45b31799bb8b5b2e1fa322321 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Tue Apr 19 09:59:04 2016 -0700 ASoC: tlv320aic32x4: Add 96k sample rate The TLV320AIC32x4 series supports 96ksps rates in hardware. This patch adds the necessary PLL divider values and clock settings to the table to make 96ksps work. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic32x4.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit f5cc17720b61af382a053d49a4a14c3d14857a5b Author: Bastien Nocera <hadess@hadess.net> Date: Tue Apr 19 18:00:20 2016 +0200 ASoC: tlv320aix31xx: Add ACPI match for Lenovo 100S The Lenovo 100S netbook has a codec controller for which there is a driver, but doesn't know how to access the device. This adds the necessary ACPI table for the driver to find the device. Device (TTLV) { Name (_ADR, Zero) // _ADR: Address Name (_HID, "10TI3100") // _HID: Hardware ID Name (_CID, "10TI3100") // _CID: Compatible ID Name (_DDN, "TI TLV320AIC3100 Codec Controller ") // _DDN: DOS Device Name Name (_UID, One) // _UID: Unique ID Signed-off-by: Bastien Nocera <hadess@hadess.net> Tested-by: Jan Schmidt <jan@centricular.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic31xx.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit fb137ba64a6415ddf231495f6d1a82de1cd69ed0 Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue Apr 19 15:19:03 2016 +0100 ASoC: da7219: Disallow unsupported 32KHz clock setting in set_dai_sysclk() The PLL function was updated to disallow 32KHz in commit 501f72e9c520 ("ASoC: da7219: Remove support for 32KHz PLL mode"), but set_dai_sysclk() was missed and still permits it. This patch resolves that discrepancy. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7219.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 63a450aa4d08ccf4f53e9fa59144e746e2288319 Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Date: Tue Apr 19 15:19:02 2016 +0100 ASoC: da7219: Update PLL ranges and dividers to improve locking The expected MCLK frequency ranges and the associated dividers are updated to improve PLL locking in a corner scenario, with low MCLK frequency near an input divider change boundary. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/da7219.c | 28 ++++++++++++++-------------- sound/soc/codecs/da7219.h | 20 ++++++++++---------- 2 files changed, 24 insertions(+), 24 deletions(-) commit 69a0200c2e25d61c50091549d00cfeb426c258f5 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:52 2016 -0600 tracing: Add hist trigger support for stacktraces as keys It's often useful to be able to use a stacktrace as a hash key, for keeping a count of the number of times a particular call path resulted in a trace event, for instance. Add a special key named 'stacktrace' which can be used as key in a 'keys=' param for this purpose: # echo hist:keys=stacktrace ... \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/87515e90b3785232a874a12156174635a348edb1.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 16 ++--- kernel/trace/trace_events_hist.c | 135 +++++++++++++++++++++++++++++---------- 2 files changed, 109 insertions(+), 42 deletions(-) commit 316961988b5ec71bbf4b2ad447662770349aec13 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:51 2016 -0600 tracing: Add hist trigger 'syscall' modifier Allow users to have syscall id fields displayed as syscall names in the output by appending '.syscall' to field names: # echo hist:keys=aaa.syscall ... \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/2bab1e59933d76a14b545bd2e02f80b8b08ac4d3.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 3 ++- kernel/trace/trace_events_hist.c | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) commit 6b4827ad028a1ab2fc4dcf1f5e6e077018d1b770 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:50 2016 -0600 tracing: Add hist trigger 'execname' modifier Allow users to have common_pid field values displayed as program names in the output by appending '.execname' to a common_pid field name: # echo hist:keys=common_pid.execname ... \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/e172e81f10f5b8d1f08450e3763c850f39fbf698.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 3 +- kernel/trace/trace_events_hist.c | 100 ++++++++++++++++++++++++++++++++++++++- 2 files changed, 101 insertions(+), 2 deletions(-) commit c6afad49d127f6d7c9957319f55173a2198b1ba8 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:49 2016 -0600 tracing: Add hist trigger 'sym' and 'sym-offset' modifiers Allow users to have address fields displayed as symbols in the output by appending '.sym' or 'sym-offset' to field names: # echo hist:keys=aaa.sym,bbb.sym-offset ... \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/87d4935821491c0275513f0fbfb9bab8d3d3f079.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 4 +++- kernel/trace/trace_events_hist.c | 29 +++++++++++++++++++++++++---- 2 files changed, 28 insertions(+), 5 deletions(-) commit 0c4a6b4666e8eb86dead3f09b40bb8ca4f614e4f Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:48 2016 -0600 tracing: Add hist trigger 'hex' modifier for displaying numeric fields Allow users to have numeric fields displayed as hex values in the output by appending '.hex' to field names: # echo hist:keys=aaa,bbb.hex:vals=ccc.hex ... \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/67bd431edda2af5798d7694818f7e8d71b6b3463.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 5 +++- kernel/trace/trace_events_hist.c | 62 ++++++++++++++++++++++++++++++++++++---- 2 files changed, 60 insertions(+), 7 deletions(-) commit e86ae9baacfa9efe957df4fc037f079772636d76 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:47 2016 -0600 tracing: Add hist trigger support for clearing a trace Allow users to append 'clear' to an existing trigger in order to have the hash table cleared. This expands the hist trigger syntax from this: # echo hist:keys=xxx:vals=yyy:sort=zzz.descending:pause/cont \ [ if filter] >> event/trigger to this: # echo hist:keys=xxx:vals=yyy:sort=zzz.descending:pause/cont/clear \ [ if filter] >> event/trigger Link: http://lkml.kernel.org/r/ae15dd0d9b2f7af07a37c1ff682063e2dbcdf160.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 5 ++++- kernel/trace/trace_events_hist.c | 24 ++++++++++++++++++++++-- 2 files changed, 26 insertions(+), 3 deletions(-) commit 83e99914c9e2677d8a80f2a23eca0d215d5bfb0f Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:46 2016 -0600 tracing: Add hist trigger support for pausing and continuing a trace Allow users to append 'pause' or 'continue' to an existing trigger in order to have it paused or to have a paused trace continue. This expands the hist trigger syntax from this: # echo hist:keys=xxx:vals=yyy:sort=zzz.descending \ [ if filter] >> event/trigger to this: # echo hist:keys=xxx:vals=yyy:sort=zzz.descending:pause or cont \ [ if filter] >> event/trigger Link: http://lkml.kernel.org/r/b672a92c14702cb924cdf6fc27ea1809bed04907.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 7 ++++++- kernel/trace/trace_events_hist.c | 31 ++++++++++++++++++++++++++++--- 2 files changed, 34 insertions(+), 4 deletions(-) commit e62347d2453474fa514fbbbc4636313d34d3c850 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:45 2016 -0600 tracing: Add hist trigger support for user-defined sorting ('sort=' param) Allow users to specify keys and/or values to sort on. With this addition, keys and values specified using the 'keys=' and 'vals=' keywords can be used to sort the hist trigger output via a new 'sort=' keyword. If multiple sort keys are specified, the output will be sorted using the second key as a secondary sort key, etc. The default sort order is ascending; if the user wants a different sort order, '.descending' can be appended to the specific sort key. Before this addition, output was always sorted by 'hitcount' in ascending order. This expands the hist trigger syntax from this: # echo hist:keys=xxx:vals=yyy \ [ if filter] > event/trigger to this: # echo hist:keys=xxx:vals=yyy:sort=zzz.descending \ [ if filter] > event/trigger Link: http://lkml.kernel.org/r/b30a41db66ba486979c4f987aff5fab500ea53b3.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 6 ++- kernel/trace/trace_events_hist.c | 112 +++++++++++++++++++++++++++++++++++++-- 2 files changed, 114 insertions(+), 4 deletions(-) commit 76a3b0c8ac344e1d0f436160cbb59b670b086947 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:44 2016 -0600 tracing: Add hist trigger support for compound keys Allow users to specify multiple trace event fields to use in keys by allowing multiple fields in the 'keys=' keyword. With this addition, any unique combination of any of the fields named in the 'keys' keyword will result in a new entry being added to the hash table. Link: http://lkml.kernel.org/r/0cfa24e6ac3b0dcece7737d94aa1f322ae3afc4b.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 10 ++++++---- kernel/trace/trace_events_hist.c | 41 +++++++++++++++++++++++++++++----------- 2 files changed, 36 insertions(+), 15 deletions(-) commit f2606835d70d2a2e6a134f01821da8149e124796 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:43 2016 -0600 tracing: Add hist trigger support for multiple values ('vals=' param) Allow users to specify trace event fields to use in aggregated sums via a new 'vals=' keyword. Before this addition, the only aggregated sum supported was the implied value 'hitcount'. With this addition, 'hitcount' is also supported as an explicit value field, as is any numeric trace event field. This expands the hist trigger syntax from this: # echo hist:keys=xxx [ if filter] > event/trigger to this: # echo hist:keys=xxx:vals=yyy [ if filter] > event/trigger Link: http://lkml.kernel.org/r/2a5d1adb5ba6c65d7bb2148e379f2fed47f29a68.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 12 +++--- kernel/trace/trace_events_hist.c | 79 +++++++++++++++++++++++++++++++++++++++- 2 files changed, 85 insertions(+), 6 deletions(-) commit 7ef224d1d0e3a1ade02d02c01ce1dcffb736d2c3 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:42 2016 -0600 tracing: Add 'hist' event trigger command 'hist' triggers allow users to continually aggregate trace events, which can then be viewed afterwards by simply reading a 'hist' file containing the aggregation in a human-readable format. The basic idea is very simple and boils down to a mechanism whereby trace events, rather than being exhaustively dumped in raw form and viewed directly, are automatically 'compressed' into meaningful tables completely defined by the user. This is done strictly via single-line command-line commands and without the aid of any kind of programming language or interpreter. A surprising number of typical use cases can be accomplished by users via this simple mechanism. In fact, a large number of the tasks that users typically do using the more complicated script-based tracing tools, at least during the initial stages of an investigation, can be accomplished by simply specifying a set of keys and values to be used in the creation of a hash table. The Linux kernel trace event subsystem happens to provide an extensive list of keys and values ready-made for such a purpose in the form of the event format files associated with each trace event. By simply consulting the format file for field names of interest and by plugging them into the hist trigger command, users can create an endless number of useful aggregations to help with investigating various properties of the system. See Documentation/trace/events.txt for examples. hist triggers are implemented on top of the existing event trigger infrastructure, and as such are consistent with the existing triggers from a user's perspective as well. The basic syntax follows the existing trigger syntax. Users start an aggregation by writing a 'hist' trigger to the event of interest's trigger file: # echo hist:keys=xxx [ if filter] > event/trigger Once a hist trigger has been set up, by default it continually aggregates every matching event into a hash table using the event key and a value field named 'hitcount'. To view the aggregation at any point in time, simply read the 'hist' file in the same directory as the 'trigger' file: # cat event/hist The detailed syntax provides additional options for user control, and is described exhaustively in Documentation/trace/events.txt and in the virtual tracing/README file in the tracing subsystem. Link: http://lkml.kernel.org/r/72d263b5e1853fe9c314953b65833c3aa75479f2.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> include/linux/trace_events.h | 1 + kernel/trace/Kconfig | 16 + kernel/trace/Makefile | 1 + kernel/trace/trace.c | 17 + kernel/trace/trace.h | 7 + kernel/trace/trace_events.c | 4 + kernel/trace/trace_events_hist.c | 849 ++++++++++++++++++++++++++++++++++++ kernel/trace/trace_events_trigger.c | 1 + 8 files changed, 896 insertions(+) commit 3b772b96b8338bca2532839b2cd7802800e66037 Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Mar 3 12:54:41 2016 -0600 tracing: Update some tracing_map constants and comments Make it clear exactly how many keys and values are supported through better defines, and add 1 to the vals count, since normally clients want support for at least a hitcount and two other values. Also, note the error return value for tracing_map_add_key/val_field() in the comments. Link: http://lkml.kernel.org/r/6696fa02ebc716aa344c27a571a2afaa25e5b4d4.1457029949.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/tracing_map.c | 4 ++-- kernel/trace/tracing_map.h | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) commit 8d44f2f34fb50f40185ef6404b0047223a27ba82 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Fri Feb 19 14:47:00 2016 -0500 tracing: Fix TRACING_MAP Kconfig The config option for TRACING_MAP has "default n", which is not needed because the default of configs is 'n'. Also, since the TRACING_MAP has no config prompt, there's no reason to include "If in doubt, say N" in the help text. Fixed a typo in the comments of tracing_map.h. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/Kconfig | 3 --- kernel/trace/tracing_map.h | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) commit 08d43a5fa063e03c860f2f391a30c388bcbc948e Author: Tom Zanussi <tom.zanussi@linux.intel.com> Date: Thu Dec 10 12:50:50 2015 -0600 tracing: Add lock-free tracing_map Add tracing_map, a special-purpose lock-free map for tracing. tracing_map is designed to aggregate or 'sum' one or more values associated with a specific object of type tracing_map_elt, which is associated by the map to a given key. It provides various hooks allowing per-tracer customization and is separated out into a separate file in order to allow it to be shared between multiple tracers, but isn't meant to be generally used outside of that context. The tracing_map implementation was inspired by lock-free map algorithms originated by Dr. Cliff Click: http://www.azulsystems.com/blog/cliff/2007-03-26-non-blocking-hashtable http://www.azulsystems.com/events/javaone_2007/2007_LockFreeHash.pdf Link: http://lkml.kernel.org/r/b43d68d1add33582a396f553c8ef705a33a6a748.1449767187.git.tom.zanussi@linux.intel.com Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Reviewed-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/Kconfig | 13 + kernel/trace/Makefile | 1 + kernel/trace/tracing_map.c | 1058 ++++++++++++++++++++++++++++++++++++++++++++ kernel/trace/tracing_map.h | 282 ++++++++++++ 4 files changed, 1354 insertions(+) commit 9974723e31d1fa99e3c0efb2ae6cbbf089c0080c Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Mon Apr 18 11:09:47 2016 +0800 arm64: mm: Show bss segment in kernel memory layout Show the bss segment information as with text and data in Virtual memory kernel layout. Acked-by: James Morse <james.morse@arm.com> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/init.c | 2 ++ 1 file changed, 2 insertions(+) commit d32351c8242b7067b3f3e3a6caf7a387ff43f978 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Mon Apr 18 11:09:46 2016 +0800 arm64: mm: make pr_cont() per line in Virtual kernel memory layout Each line with single pr_cont() in Virtual kernel memory layout, or the dump of the kernel memory layout in dmesg is not aligned when PRINTK_TIME enabled, due to the missing time stamps. Tested-by: James Morse <james.morse@arm.com> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/init.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) commit ab703f818ac36b9e74f61b8890f14e5446b7c012 Author: Christian Lamparter <chunkeey@googlemail.com> Date: Thu Apr 14 18:11:01 2016 +0200 dmaengine: dw: lazy allocation of dma descriptors This patch changes the driver to allocate DMA descriptors when needed. This stops memory resources to be wasted and letting them sit idle in the free_list structure when the device doesn't need it... This also solves the problem, that a driver has to guess the number of how many descriptors it needs to allocate in advance. Currently, the dma engine will just fail when put under load by sata_dwc_460ex. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 166 +++++++++++++++----------------------------------- drivers/dma/dw/regs.h | 1 - 2 files changed, 48 insertions(+), 119 deletions(-) commit 1034ce707b5734d79d1abd39f18d4d46bd9f10ca Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Tue Apr 12 12:23:54 2016 +0530 drm/i915: Fixing eDP detection on certain platforms Since commit 30d9aa4265fe ("drm/i915: Read sink_count dpcd always"), the status of a DP connector depends on its sink count value. However, some eDP panels don't set that value appropriately, causing them to be reported as disconnected. Fix this by ignoring sink count for eDP. v2: Rephrased commit message. (Ander) In case of eDP, returning status as connected if DPCD read succeeds to avoid any further operations. Fixes: 30d9aa4265fe ("drm/i915: Read sink_count dpcd always") Cc: Ander Conselvan De Oliveira <conselvan2@gmail.com> Cc: Jani Nikula <jani.nikula@linux.intel.com> Reported-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Tested-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460444034-22320-1-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 0e505a08b539e55d849345cecd606c85090a660b Author: jim.bride@linux.intel.com <jim.bride@linux.intel.com> Date: Mon Apr 11 10:11:24 2016 -0700 drm/i915/dp/mst: Fix MST logic in intel_dp_long_pulse() In commit 7d23e3c37bb3 ("drm/i915: Cleaning up intel_dp_hpd_pulse") some much needed clean-up was done, but unfortunately part of the change broke DP MST. The real issue was setting the connector state to disconnected in the MST case, which is good, but the code then (after a goto) checks if the connector state is not connected and shuts down MST if this is the case, which is bad. With this change both SST and MST seem to be happy. v2: Add removed check further up in the function to be sure that MST is shut down when we lose the link. (Ander) Fixes: commit 7d23e3c37bb3 ("drm/i915: Cleaning up intel_dp_hpd_pulse") cc: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> cc: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> cc: Ander Conselvan de Oliveira <conselvan2@gmail.com> cc: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Jim Bride <jim.bride@linux.intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Reviewed-by: Lyude <cpaul@redhat.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460394684-7036-1-git-send-email-jim.bride@linux.intel.com drivers/gpu/drm/i915/intel_dp.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit 5ad3f29f6a712c3a37dbda4fba3b6969857d39d9 Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:43 2016 +0300 dmaengine: qcom: bam_dma: rename BAM_MAX_DATA_SIZE define It seems that the define has not been with acurate name and makes confusion while reading the code. The more acurate name should be BAM_FIFO_SIZE. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/bam_dma.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 2a663ed9fe88cb237d72ce869aeadbbf119ad8e4 Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:42 2016 +0300 dmaengine: qcom: bam_dma: use correct pipe FIFO size The pipe fifo size register must instruct the bam hw how many hw descriptors can be pushed to fifo. Currently we instruct the hw with 32KBytes but wrap the tail in bam_start_dma in BAM_P_EVNT_REG on 4095 i.e. 32760. This leads to stalled transactions when the tail wraps. Fix this by use the correct fifo size in BAM_P_FIFO_SIZES register i.e. 32K - 8. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/bam_dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5172c9eb89d4ea41f86ff91b15b2b0dc75ded869 Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:41 2016 +0300 dmaengine: qcom: bam_dma: add controlled-remotely dt property Some of the peripherals has bam which is controlled by remote processor, thus the bam dma driver must avoid register writes which initialise bam hw block. Those registers are protected from xPU block and any writes to them will lead to secure violation and system reboot. Adding the contolled_remotely flag in bam driver to avoid not permitted register writes in bam_init function. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Tested-by: Pramod Gurav <gpramod@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/bam_dma.c | 7 +++++++ 1 file changed, 7 insertions(+) commit c778ed46e6d245186522d2ebe2d39b52bbc4432b Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:40 2016 +0300 dmaengine: qcom: bam_dma: document controlled-remotely dt property Extend BAM dt bindings with controlled-remotely property. The property will be needed to handle cases where we need to skip register writes to initialise BAM hardware block. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/devicetree/bindings/dma/qcom_bam_dma.txt | 2 ++ 1 file changed, 2 insertions(+) commit f89117c0f54c235c149d31174d1dd855e04765b8 Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:39 2016 +0300 dmaengine: qcom: bam_dma: clear BAM interrupt only if it is raised Currently we write BAM_IRQ_CLR register with zero even when no BAM_IRQ occured. This write has some bad side effects when the BAM instance is for the crypto engine. In case of crypto engine some of the BAM registers are xPU protected and they cannot be controlled by the driver. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Tested-by: Pramod Gurav <gpramod@codeaurora.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/bam_dma.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit f139f97878039f9a49db6cb555d95f6b6e9ba0f8 Author: Stanimir Varbanov <stanimir.varbanov@linaro.org> Date: Mon Apr 11 11:38:38 2016 +0300 dmaengine: qcom: bam_dma: fix dma free memory on remove Building the driver as a module and when removing the already inserted module gives below: [ 1389.392788] Unable to handle kernel paging request at virtual address ffffffbdc000001c [ 1389.421321] pgd = ffffffc02fa87000 [ 1389.447899] [ffffffbdc000001c] *pgd=0000000000000000, *pud=0000000000000000 [ 1389.460142] Internal error: Oops: 96000006 [#1] PREEMPT SMP [ 1389.466963] Modules linked in: qcom_bam_dma(-) [ 1389.486608] CPU: 2 PID: 2442 Comm: rmmod Not tainted 4.2.0+ #407 [ 1389.493885] Hardware name: Qualcomm Technologies, Inc. APQ 8016 SBC (DT) [ 1389.501196] task: ffffffc035bae2c0 ti: ffffffc0368a8000 task.ti: ffffffc0368a8000 [ 1389.508566] PC is at __free_pages+0xc/0x40 [ 1389.515893] LR is at free_pages.part.93+0x30/0x38 [ 1389.523141] pc : [<ffffffc00016180c>] lr : [<ffffffc00016197c>] pstate: 80000145 [ 1389.530602] sp : ffffffc0368abc20 [ 1389.537931] x29: ffffffc0368abc20 x28: ffffffc0368a8000 [ 1389.549153] x27: 0000000000000000 x26: 0000000000000000 [ 1389.560412] x25: ffffffc000cb2000 x24: 0000000000000170 [ 1389.571530] x23: 0000000000000004 x22: ffffffc036bc5010 [ 1389.582721] x21: ffffffc036bc5010 x20: 0000000000000000 [ 1389.593981] x19: 0000000000000002 x18: 0000007fcbc8e8b0 [ 1389.605301] x17: 0000007f9b8226ec x16: ffffffc0002089e8 [ 1389.616647] x15: 0000007f9b8a0588 x14: 0ffffffffffffffc [ 1389.628039] x13: 0000000000000030 x12: 0000000000000000 [ 1389.639436] x11: 0000000000000008 x10: ffffffc000ecc000 [ 1389.650872] x9 : ffffffc035bae2c0 x8 : ffffffc035bae9a8 [ 1389.662367] x7 : ffffffc035bae9a0 x6 : 0000000000000000 [ 1389.673906] x5 : ffffffbdc000001c x4 : 0000000080000000 [ 1389.685475] x3 : ffffffbdc0000000 x2 : 0000004080000000 [ 1389.697049] x1 : 0000000000000003 x0 : ffffffbdc0000000 The memory has been already freed by bam_free_chan() so fix this by skiping already freed memory. Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org> Reviewed-by: Andy Gross <andy.gross@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/qcom/bam_dma.c | 3 +++ 1 file changed, 3 insertions(+) commit 6566feafb4dba4eef30a9c0b25e6f49f996178b6 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 12:22:25 2016 -0300 perf test: Add missing verbose output explaining the reason for failure One of the branches leading to an error had no debug message emitted, fix it, the new lines are: # perf test -v kallsyms <SNIP> 0xffffffff81001000: diff name v: xen_hypercall_set_trap_table k: hypercall_page 0xffffffff810691f0: diff name v: try_to_free_pud_page k: try_to_free_pmd_page <SNIP> 0xffffffff8150bb20: diff name v: wakeup_expire_count_show.part.5 k: wakeup_active_count_show.part.7 0xffffffff816bc7f0: diff name v: phys_switch_id_show.part.11 k: phys_port_name_show.part.12 0xffffffff817bbb90: diff name v: __do_softirq k: __softirqentry_text_start <SNIP> This in turn exercises another bug, still under investigation, because those aliases _are_ in kallsyms, with the same name... Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Fixes: ab414dcda8fa ("perf test: Fixup aliases checking in the 'vmlinux matches kallsyms' test") Link: http://lkml.kernel.org/n/tip-5fhea7a54a54gsmagu9obpr4@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/vmlinux-kallsyms.c | 3 +++ 1 file changed, 3 insertions(+) commit 53d0fe68275dbdaf6a532bb4e87f00db5d36c140 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 12:16:55 2016 -0300 perf test: Ignore kcore files in the "vmlinux matches kallsyms" test Before: # perf test -v kallsyms <SNIP> Maps only in vmlinux: ffffffff81d5e000-ffffffff81ec3ac8 115e000 [kernel].init.text ffffffff81ec3ac8-ffffffffa0000000 12c3ac8 [kernel].exit.text ffffffffa0000000-ffffffffa000c000 0 [fjes] ffffffffa000c000-ffffffffa0017000 0 [video] ffffffffa0017000-ffffffffa001c000 0 [grace] <SNIP> ffffffffa0a7f000-ffffffffa0ba5000 0 [xfs] ffffffffa0ba5000-ffffffffffffffff 0 [veth] Maps in vmlinux with a different name in kallsyms: Maps only in kallsyms: ffff880000100000-ffff88001000b000 80000103000 [kernel.kallsyms] ffff88001000b000-ffff880100000000 8001000e000 [kernel.kallsyms] ffff880100000000-ffffc90000000000 80100003000 [kernel.kallsyms] <SNIP> ffffffffa0000000-ffffffffff600000 7fffa0003000 [kernel.kallsyms] ffffffffff600000-ffffffffffffffff 7fffff603000 [kernel.kallsyms] test child finished with -1 ---- end ---- vmlinux symtab matches kallsyms: FAILED! # After: # perf test -v 1 1: vmlinux symtab matches kallsyms : --- start --- test child forked, pid 7058 Looking at the vmlinux_path (8 entries long) Using /lib/modules/4.6.0-rc1+/build/vmlinux for symbols 0xffffffff81076870: diff end addr for aesni_gcm_dec v: 0xffffffff810791f2 k: 0xffffffff81076902 0xffffffff81079200: diff end addr for aesni_gcm_enc v: 0xffffffff8107bb03 k: 0xffffffff81079292 0xffffffff8107e8d0: diff end addr for aesni_gcm_enc_avx_gen2 v: 0xffffffff81083e76 k: 0xffffffff8107e943 0xffffffff81083e80: diff end addr for aesni_gcm_dec_avx_gen2 v: 0xffffffff81089611 k: 0xffffffff81083ef3 0xffffffff81089990: diff end addr for aesni_gcm_enc_avx_gen4 v: 0xffffffff8108e7c4 k: 0xffffffff81089a03 0xffffffff8108e7d0: diff end addr for aesni_gcm_dec_avx_gen4 v: 0xffffffff810937ef k: 0xffffffff8108e843 Maps only in vmlinux: ffffffff81d5e000-ffffffff81ec3ac8 115e000 [kernel].init.text ffffffff81ec3ac8-ffffffffa0000000 12c3ac8 [kernel].exit.text Maps in vmlinux with a different name in kallsyms: Maps only in kallsyms: test child finished with -1 ---- end ---- vmlinux symtab matches kallsyms: FAILED! # Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Fixes: 8e0cf965f95e ("perf symbols: Add support for reading from /proc/kcore") Link: http://lkml.kernel.org/n/tip-n6vrwt9t89w8k769y349govx@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/vmlinux-kallsyms.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit e02092b9a922f17e951b2df5f12f4aafe7383a21 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 12:12:49 2016 -0300 perf symbols: Allow loading kallsyms without considering kcore files Before the support for using /proc/kcore was introduced, the kallsyms routines used /proc/modules and the first 'perf test' entry expected finding maps for each module in the system, which is not the case with the kcore code. Provide a way to ignore kcore files so that the test can have its expectations met. Improving the test to cover kcore files as well needs to be done. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ek5urnu103dlhfk4l6pcw041@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/machine.c | 12 +++++++++--- tools/perf/util/machine.h | 2 ++ tools/perf/util/symbol.c | 12 +++++++++--- tools/perf/util/symbol.h | 2 ++ 4 files changed, 22 insertions(+), 6 deletions(-) commit 2cc4666927402ec748122cac15ceac35a5e298a3 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 19 12:01:51 2016 -0300 perf build: Remove x86 references from arch-neutral Build It will already be dealt with generating the syscalltbl.c file in the x86 arch specific Build files, namely via 'archheaders'. This fixes the build on !x86 arches, as reported for powerpcle Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Tested-by: Jiri Olsa <jolsa@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Wang Nan <wangnan0@huawei.com> Fixes: 1b700c997500 ("perf tools: Build syscall table .c header from kernel's syscall_64.tbl") Link: http://lkml.kernel.org/r/20160415212831.GT9056@kernel.org [ Removed the syscalltbl.o altogether, as per Jiri's suggestion ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/Build | 4 ---- 1 file changed, 4 deletions(-) commit f56ebf20d0f535f5da7cfcf0000ab3e0af133f81 Author: Colin Ian King <colin.king@canonical.com> Date: Tue Apr 19 00:07:18 2016 +0100 perf jit: memset() variable 'st' using the correct size The current code is memsetting the 'struct stat' variable 'st' with the size of 'stat' (which turns out to be 1 byte) rather than the size of variable 'sz'. Committer notes: sizeof(function) isn't valid, the result depends on the compiler used, with gcc, enabling pedantic warnings we get: $ cat sizeof_function.c #include <sys/types.h> #include <sys/stat.h> #include <unistd.h> #include <stdio.h> int main(void) { printf("sizeof(stat)=%zd, stat=%p\n", sizeof(stat), stat); return 0; } $ readelf -sW sizeof_function | grep -w stat 49: 0000000000400630 16 FUNC WEAK HIDDEN 13 stat $ cc -pedantic sizeof_function.c -o sizeof_function sizeof_function.c: In function ‘main’: sizeof_function.c:8:46: warning: invalid application of ‘sizeof’ to a function type [-Wpointer-arith] printf("sizeof(stat)=%zd, stat=%p\n", sizeof(stat), stat); ^ $ ./sizeof_function sizeof(stat)=1, stat=0x400630 $ Standard C, section 6.5.3.4: "The sizeof operator shall not be applied to an expression that has function type or an incomplete type, to the parenthesized name of such a type, or to an expression that designates a bit-field member." http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1256.pdf Signed-off-by: Colin Ian King <colin.king@canonical.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Fixes: 9b07e27f88b9 ("perf inject: Add jitdump mmap injection support") Link: http://lkml.kernel.org/r/1461020838-9260-1-git-send-email-colin.king@canonical.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/jitdump.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d6632dd59b66c89724ef28e2723586d1429382aa Author: Chris Phlipot <cphlipot0@gmail.com> Date: Tue Apr 19 01:56:02 2016 -0700 perf script: Fix postgresql ubuntu install instructions The current instructions for setting up an Ubuntu system for using the export-to-postgresql.py script are incorrect. The instructions in the script have been updated to work on newer versions of ubuntu. -Add missing dependencies to apt-get command: python-pyside.qtsql, libqt4-sql-psql -Add '-s' option to createuser command to force the user to be a superuser since the command doesn't prompt as indicated in the current instructions. Tested on: Ubuntu 14.04, Ubuntu 16.04(beta) Signed-off-by: Chris Phlipot <cphlipot0@gmail.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1461056164-14914-3-git-send-email-cphlipot0@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/scripts/python/export-to-postgresql.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 9bc0fa53692837a6128d2ecc6943e451c7f7c332 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Apr 11 13:29:09 2016 +0000 ARM: bcm2835: add interrupt-names and apply correct mapping Add interrupt-names properties to dt and apply the correct mapping between irq and dma channels. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> arch/arm/boot/dts/bcm283x.dtsi | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) commit e2eca6389b031cdbbc4172eee89ce271c00cb672 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Apr 11 13:29:08 2016 +0000 dmaengine: bcm2835: use platform_get_irq_byname Use platform_get_irq_byname to allow for correct mapping of interrupts to dma channels. The currently implemented device tree is unfortunately implemented with the wrong assumption, that each dma-channel has its own dma channel, but dma-irq 11 is handling dma-channel 11-14 and dma-irq 12 is actually a "catch all" interrupt. So here we use the byname variant and require that interrupts are explicitly named via the interrupts-name property in the device tree. The use of shared interrupts is also implemented. As a side-effect this means we can now use dma channels 12, 13 and 14 in a correct manner - also testing shows that onl using channels 11 to 14 for spi and i2s works perfectly (when playing some video) Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Acked-by: Eric Anholt <eric@anholt.net> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 77 ++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 63 insertions(+), 14 deletions(-) commit e7679db714c356f8e27df2dc3ff721c0d3775448 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Apr 11 13:29:07 2016 +0000 dt/bindings: bcm2835: add interrupt-names property Added standard interrupt-names property so that platform_get_irq_byname() can get used to fetch the interrupt corresponding to each dma_channel instead of the current platform_get_irq() with an assumed ordering of the interrupts. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Eric Anholt <eric@anholt.net> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> .../devicetree/bindings/dma/brcm,bcm2835-dma.txt | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 47f58b1ebe3739dad1ddeb5cd1f1e718648b4d24 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Apr 10 12:25:31 2016 +0100 ath9k: remove duplicate assignment of variable ah ah is written twice with the same value, remove one of the redundant assignments to ah. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71f5137bf010c6faffab50c0ec15374c59c4a411 Author: Zefir Kurtisi <zefir.kurtisi@neratec.com> Date: Fri Apr 1 11:37:08 2016 +0200 ath9k: interpret requested txpower in EIRP domain Tx power limitations at upper layers are interpreted in the EIRP domain. When the user requests a given maximum txpower, e.g. with: 'iw phy0 set txpower fixed 1500', he expects the EIRP to be at or below 15dBm. In ath9k_hw_apply_txpower(), the interpretation is different: the antenna-gain is capped against the current txpower limit in the regulatory, but not against the user set value. It ensures that the resulting EIRP is below the limit defined by the active countrycode, but not below the value the user requested. In a scenario like e.g. a) antenna_gain=6 b) countrycode limits to eirp=18 c) user set txpower=15 this will cause a setting for AR_PHY_POWER_TX_RATE regs resulting in an EIRP > 15. This patch ensures that antenna-gain is considered whenever the txpower limit is adjusted and with that the user set limits are kept. Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/hw.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit f286dd899b4f1445279af6b5965c335ae6f998f7 Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Jan 1 19:09:32 2016 +0100 ath9k_htc: Replace a variable initialisation by an assignment in ath9k_htc_set_channel() Replace an explicit initialisation for one local variable at the beginning by a conditional assignment. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Reviewed-by: Oleksij Rempel <linux@rempel-privat.de> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/htc_drv_main.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 7e247a9e88dc811d0b7b6a70af1d741054772bc4 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Tue Apr 12 20:15:53 2016 +0530 ath10k: add dynamic tx mode switch config support for qca4019 push-pull mode needs certain amount the host driver involvement for managing queues in the host memory and packet delivery to firmware. qca4019 wifi firmware has an option to stay in push mode for less number of active traffic flow and then switch to push-pull mode when the active traffic flow goes beyond the certain limit. The advantage of staying in push mode for less active traffic is, the host cpu consumption is reduced. qca4019 firmware supports this flexibility of the mode switch. It takes the host driver interest (LOW_PERF/HIGH_PERF) via WMI_EXT_RESOURCE_CFG_CMDID, LOW_PERF - fw would stay in push mode and switch to push-pull based on demand. HIGH_PERF - fw would stay in push-pull mode from the boot. To make this configuration generic, new WMI services WMI_SERVICE_TX_MODE_PUSH_ONLY, WMI_SERVICE_TX_MODE_PUSH_PULL, WMI_SERVICE_TX_MODE_DYNAMIC are introduced to take dynamic tx mode switch support availability in firmware. Based on WMI_SERVICE_TX_MODE_DYNAMIC, LOW_PERF or HIGHT_PERF is configured to the firmware. Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Tamizh chelvam <c_traja@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 3 +-- drivers/net/wireless/ath/ath10k/mac.c | 20 ++++++++++++++++++++ drivers/net/wireless/ath/ath10k/mac.h | 1 + drivers/net/wireless/ath/ath10k/wmi.h | 15 +++++++++++++++ 4 files changed, 37 insertions(+), 2 deletions(-) commit de72a20dc3714918b208430dd426c9f6a23ffaec Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Apr 11 11:15:20 2016 +0300 ath10k: add some sanity checks to peer_map_event() functions Smatch complains that since "ev->peer_id" comes from skb->data that means we can't trust it and have to do a bounds check on it to prevent an array overflow. Fixes: 6942726f7f7b ('ath10k: add fast peer_map lookup') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/txrx.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 1ce8c1484e80010a6e4b9611c65668ff77556f45 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Thu Apr 7 12:11:54 2016 +0530 ath10k: fix rx_channel during hw reconfigure Upon firmware assert, restart work will be triggered so that mac80211 will reconfigure the driver. An issue is reported that after restart work, survey dump data do not contain in-use (SURVEY_INFO_IN_USE) info for operating channel. During reconfigure, since mac80211 already has valid channel context for given radio, channel context iteration return num_chanctx > 0. Hence rx_channel is always NULL. Fix this by assigning channel context to rx_channel when driver restart is in progress. Cc: stable@vger.kernel.org Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 87be054a30de1d48a4c9850543080b8cc9854d2c Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Tue Apr 5 20:58:26 2016 +0530 ath10k: fix return value for btcoex and peer stats debugfs Return value is incorrect for btcoex and peer stats debugfs 'write' entries if the user provides a value that matches with the already available debugfs entry, this results in the debugfs entry getting stuck and the operation has to be terminated manually. Fix this by returning the appropriate return 'count' as we do it for other debugfs entries like pktlog etc. Fixes: cc61a1bbbc0e ("ath10k: enable debugfs provision to enable Peer Stats feature") Fixes: c28e6f06ff40 ("ath10k: fix sanity check on enabling btcoex via debugfs") Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/debug.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit e10fa551ae37b796d7ae60e5a951c18d00c2bbf0 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Fri Apr 15 12:03:39 2016 +0300 drm/i915: Clean up PCI config register handling Do not use magic numbers, do not prefix stuff with "PCI_", do not declare registers in implementation files. Also move the PCI registers under correct comment in i915_reg.h. v2: - Consistently use BSM (not BDSM or other variants from PRM) (Chris) - Also include register address to help identify the register (Chris) v3: - Refer to register value as *_val instead of *_reg (Chris) v4: - Make style checker happy Cc: Jani Nikula <jani.nikula@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_dma.c | 32 ++++++++++++++-------------- drivers/gpu/drm/i915/i915_gem_stolen.c | 14 +++++++------ drivers/gpu/drm/i915/i915_reg.h | 38 +++++++++++++++++++++++++--------- drivers/gpu/drm/i915/intel_opregion.c | 24 ++++++++------------- drivers/gpu/drm/i915/intel_panel.c | 4 ++-- 5 files changed, 63 insertions(+), 49 deletions(-) commit b5c46cef6c119aeeab0238dc4722ceea585edf33 Author: Jon Hunter <jonathanh@nvidia.com> Date: Wed Mar 30 10:15:14 2016 +0100 dt-bindings: Add power domain info for NVIDIA PMC Add power-domain binding documentation for the NVIDIA PMC driver in order to support generic power-domains. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../bindings/arm/tegra/nvidia,tegra20-pmc.txt | 80 ++++++++++++++++++++++ 1 file changed, 80 insertions(+) commit 62b40def198c38c1326dd9d86b9f7064289c25d4 Merge: f55532a 605aa5e Author: Thierry Reding <treding@nvidia.com> Date: Tue Apr 19 16:53:24 2016 +0200 Merge branch 'for-4.7/soc' into for-4.7/genpd commit 540b589e6349779c0eeb8de82450b62a4569ffd9 Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org> Date: Tue Apr 19 10:24:38 2016 -0400 tracing: Update the documentation to describe "event-fork" option Add documentation to the ftrace.txt file in Documentation to describe the event-fork option. Also add the missing "display-graph" option now that it shows up in the trace_options file (from a previous commit). Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Documentation/trace/ftrace.txt | 34 ++++++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 10 deletions(-) commit c37775d57830a36382a9774bb84eca4ce3d019cc Author: Steven Rostedt <rostedt@goodmis.org> Date: Wed Apr 13 16:59:18 2016 -0400 tracing: Add infrastructure to allow set_event_pid to follow children Add the infrastructure needed to have the PIDs in set_event_pid to automatically add PIDs of the children of the tasks that have their PIDs in set_event_pid. This will also remove PIDs from set_event_pid when a task exits This is implemented by adding hooks into the fork and exit tracepoints. On fork, the PIDs are added to the list, and on exit, they are removed. Add a new option called event_fork that when set, PIDs in set_event_pid will automatically get their children PIDs added when they fork, as well as any task that exits will have its PID removed from set_event_pid. This works for instances as well. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.c | 3 ++ kernel/trace/trace.h | 2 ++ kernel/trace/trace_events.c | 84 +++++++++++++++++++++++++++++++++++++++------ 3 files changed, 79 insertions(+), 10 deletions(-) commit f4d34a87e9c10f0ffd03d3548db6bfb200d06cdf Author: Steven Rostedt <rostedt@goodmis.org> Date: Wed Apr 13 16:27:49 2016 -0400 tracing: Use pid bitmap instead of a pid array for set_event_pid In order to add the ability to let tasks that are filtered by the events have their children also be traced on fork (and then not traced on exit), convert the array into a pid bitmask. Most of the time the number of pids is only 32768 pids or a 4k bitmask, which is the same size as the default list currently is, and that list could grow if more pids are listed. This also greatly simplifies the code. Suggested-by: "H. Peter Anvin" <hpa@zytor.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace.h | 5 +- kernel/trace/trace_events.c | 221 ++++++++++++++++++++------------------------ 2 files changed, 102 insertions(+), 124 deletions(-) commit 9ebc57cfaad21aacbc363eecead579269a46b493 Author: Steven Rostedt <rostedt@goodmis.org> Date: Tue Apr 12 20:39:55 2016 -0400 tracing: Rename check_ignore_pid() to ignore_this_task() The name "check_ignore_pid" is confusing in trying to figure out if the pid should be ignored or not. Rename it to "ignore_this_task" which is pretty straight forward, as a task (not a pid) is passed in, and should if true should be ignored. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> kernel/trace/trace_events.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 44a7102484db0ddfa6f855b57ffe0566f739b55a Author: Matthew Auld <matthew.auld@intel.com> Date: Tue Apr 12 16:57:42 2016 +0100 drm/i915: call kunmap_px on pt_vaddr We need to kunmap pt_vaddr and not pt itself, otherwise we end up mapping a bunch of pages without ever unmapping them. Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Fixes: d1c54acd67dc ("drm/i915/gtt: Introduce kmap|kunmap for dma page") Signed-off-by: Matthew Auld <matthew.auld@intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460476663-24890-4-git-send-email-matthew.auld@intel.com drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7464b6e3a5fb213e7826d2fde4a2daf05abb6822 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 18 10:34:19 2016 +0200 efi: ARM: avoid warning about phys_addr_t cast memblock_remove() takes a phys_addr_t, which may be narrower than 64 bits, causing a harmless warning: drivers/firmware/efi/arm-init.c: In function 'reserve_regions': include/linux/kernel.h:29:20: error: large integer implicitly truncated to unsigned type [-Werror=overflow] #define ULLONG_MAX (~0ULL) ^ drivers/firmware/efi/arm-init.c:152:21: note: in expansion of macro 'ULLONG_MAX' memblock_remove(0, ULLONG_MAX); This adds an explicit typecast to avoid the warning Fixes: 500899c2cc3e ("efi: ARM/arm64: ignore DT memory nodes instead of removing them") Acked-by Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/firmware/efi/arm-init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71a9c23246fe68954f87787a4e6c1aa22565c326 Author: Guenter Roeck <linux@roeck-us.net> Date: Mon Jan 18 00:35:58 2016 -0800 hwmon: (it87) Add support for IT8628E IT8628E is functionally identical to IT8620E. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Documentation/hwmon/it87 | 15 +++++++++------ drivers/hwmon/Kconfig | 3 ++- drivers/hwmon/it87.c | 18 ++++++++++++++++-- 3 files changed, 27 insertions(+), 9 deletions(-) commit 0624d861983c2cb1884ea3bafc1c534c7d2348b8 Author: Guenter Roeck <linux@roeck-us.net> Date: Mon Apr 6 21:04:18 2015 -0700 hwmon: (it87) Fix pwm_temp_map for system with 6 pwm channels Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) commit 2cbb9c370fe32b5de5243f7338dc6ce8747d495b Author: Guenter Roeck <linux@roeck-us.net> Date: Sun Apr 5 11:53:29 2015 -0700 hwmon: (it87) Support automatic pwm control on newer chips Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 201 +++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 187 insertions(+), 14 deletions(-) commit a0df926d33232f311d6a4d834391fec21b60db30 Author: Guenter Roeck <linux@roeck-us.net> Date: Sun Apr 5 16:51:36 2015 -0700 hwmon: (it87) Enhance validation for fan4 and fan5 Several of the chips supported by this driver have a configuration register to enable fan4 and fan5. Use those registers to determine if fan4 and fan5 tachometers are supported. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit f1bbe618604a4aa833a4af0b1ecdfb47a25455c6 Author: Guenter Roeck <linux@roeck-us.net> Date: Sun Apr 5 13:16:54 2015 -0700 hwmon: (it87) Support disabling fan control for all pwm control and chips On/Off mode is only supported for pwm controls 0-2, and not supported at all for IT8603E/IT8623E. For pwm controls 3-6 and for IT8603E/IT8623E, SmartGuardian mode is always enabled. Use it and set the pwm value to the maximum if fan control is disabled. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 52 +++++++++++++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 21 deletions(-) commit c962024e306ed598600853854a067b521bf5b530 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Apr 4 09:05:57 2015 -0700 hwmon: (it87) Formatting cleanup Fix various checkpatch complaints to clean up the code and make it easier to read. CHECK: Do not include the paragraph about writing to the FSF CHECK: Alignment should match open parenthesis CHECK: Logical continuations should be on the previous line CHECK: No space is necessary after a cast CHECK: Please don't use multiple blank lines CHECK: Please use a blank line after function/struct/union/enum declarations CHECK: spaces preferred around that '+' (ctx:VxV) WARNING: Missing a blank line after declarations No functional change. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 155 ++++++++++++++++++++++++++------------------------- 1 file changed, 80 insertions(+), 75 deletions(-) commit 2310048db70a58ae89b37fded0322b6a5ae6443f Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Apr 2 08:23:45 2015 -0700 hwmon: (it87) Use defines for array sizes and sensor counts Using array size defines makes it much easier to find errors in index values and loop counts. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 58 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 34 insertions(+), 24 deletions(-) commit 48b2ae7fe9d0eba523a3633ff0f939aba9e962e2 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Apr 2 08:06:12 2015 -0700 hwmon: (it87) Use BIT macro Using the BIT macro makes the code a little easier to read and has the added benefit of making checkpatch happy. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 290 ++++++++++++++++++++++++++------------------------- 1 file changed, 146 insertions(+), 144 deletions(-) commit f838aa2611045fb1409c461fdd5102a6d8ae79f2 Author: Guenter Roeck <linux@roeck-us.net> Date: Wed Apr 1 20:09:36 2015 -0700 hwmon: (it87) Add support for VIN7 to VIN10 on IT8620E IT8620E supports three additional voltage sensors. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) commit 559313c4e9b29f5d0ba246f69d1052ef2fd9b423 Author: Guenter Roeck <linux@roeck-us.net> Date: Wed Apr 1 10:15:38 2015 -0700 hwmon: (it87) Simplify reading voltage registers Voltage registers are non-sequential. Use a register array instead of a macro to map sensor index to register to simplify the code and to make it easier to add additional voltage sensors. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) commit cc18da79d9b7faf1ec617e2478d57d25d7b2f93a Author: Guenter Roeck <linux@roeck-us.net> Date: Wed Apr 1 10:03:01 2015 -0700 hwmon: (it87) Support up to 6 temperature sensors on IT8620E Add support for the additional temperature sensors on IT8620E. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 48 ++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 40 insertions(+), 8 deletions(-) commit 8638d0afb4df0d3cebcd10c3056dcb4a52432941 Author: Guenter Roeck <linux@roeck-us.net> Date: Mon Mar 30 11:13:49 2015 -0700 hwmon: (it87) Convert to use new hwmon API Convert to use devm_hwmon_device_register_with_groups to simplify code and reduce code size. This also attaches sysfs attributes to the hwmon device and no longer to the platform device. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 93 +++++++++++----------------------------------------- 1 file changed, 19 insertions(+), 74 deletions(-) commit d376684880beb603a11fb6593489a21398d2a491 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 30 15:47:21 2013 -0700 hwmon: (it87) Use single group and is_visible for miscellaneous attributes Use is_visible to determine if attributes should be generated or not. This simplifies the code and reduces object size by about 120 bytes on x86_64. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 81 +++++++++++++++++++++------------------------------- 1 file changed, 33 insertions(+), 48 deletions(-) commit 5c3912616d37bcc292ae09a8be7f1a58d54f19f9 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 30 15:02:12 2013 -0700 hwmon: (it87) Use is_visible for pwm attributes Simplify code and reduce object size by about 250 bytes on x86_64. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 137 ++++++++++++++++++++++++--------------------------- 1 file changed, 65 insertions(+), 72 deletions(-) commit 9a70ee814d7093a2806e94b99ce12b8d35c6102e Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 30 14:51:20 2013 -0700 hwmon: (it87) Use is_visible for fan attributes Simplify code and reduce object size by almost 500 bytes on x86_64. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 140 ++++++++++++++++++++------------------------------- 1 file changed, 55 insertions(+), 85 deletions(-) commit 87533770be36ecea55b86fa377ba4232d720df23 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 30 14:23:20 2013 -0700 hwmon: (it87) Use is_visible for temperature sensors Simplify code and reduce object size by more than 200 bytes on x86_64. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 87 ++++++++++++++++++++++------------------------------ 1 file changed, 36 insertions(+), 51 deletions(-) commit 52929715634ad36782bd7018ab0bf59a6619c393 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 30 14:00:08 2013 -0700 hwmon: (it87) Use is_visible for voltage sensors Simplify code and reduce object size by more than 300 bytes on x86_64. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 124 +++++++++++++++++++++++---------------------------- 1 file changed, 56 insertions(+), 68 deletions(-) commit c1e7a4ca6d7c58e30185d40e9ba82c7976950f32 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 28 09:27:27 2015 -0700 hwmon: (it87) Rearrange code to avoid forward declarations Cleanup only, no functional change. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 761 +++++++++++++++++++++++++-------------------------- 1 file changed, 376 insertions(+), 385 deletions(-) commit e84bd9535e2bb59624091bc8c1eddae7cc82d260 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 28 08:24:29 2015 -0700 hwmon: (it87) Add support for second Super-IO chip The Super-IO chip can also reside at SIO address 0x4e, and there can be two Super-IO chips in the system. Add support for it. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 49 ++++++++++++++++++++++++++++++++++--------------- 1 file changed, 34 insertions(+), 15 deletions(-) commit 3c2e35126f2821be9b6f11dd5b772c68bcef4475 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 28 08:03:10 2015 -0700 hwmon: (it87) Pass SIO base address as parameter to superio functions This will let us support more than one chip on different SIO addresses with the same driver. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 137 +++++++++++++++++++++++++++------------------------ 1 file changed, 72 insertions(+), 65 deletions(-) commit 8e50e3c3f60c84b96956d37cbbf109b75569c6ba Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 28 07:49:14 2015 -0700 hwmon: (it87) Don't use pdev as static driver variable Using the same varible name for function names and as static variable invites misuse and prevents us from adding support for a second chip. Rename pdev to it87_pdev and limit its use to where it is needed. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 5cae84a58ee60eb54f636133f4f3ede9af93d476 Author: Guenter Roeck <linux@roeck-us.net> Date: Sat Mar 28 07:44:59 2015 -0700 hwmon: (it87) Simplify error return in it87_device_add Return directly on errors if there is no cleanup necessary. Don't create an error message on memory allocation errors. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 60878bcfd3dd2ea146dacf41313f8caa365df9a1 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Mar 26 19:57:42 2015 -0700 hwmon: (it87) Add support for second pwm frequency register Recent chips have a separate register to select the pwm2 frequency. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 100 +++++++++++++++++++++++++++++++++++---------------- 1 file changed, 69 insertions(+), 31 deletions(-) commit 36c4d98a7883d4c51252d0f4ebf2c667fa7f879f Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Mar 26 18:18:19 2015 -0700 hwmon: (it87) Add support for all pwm channels on IT8620E IT8620E supports up to 6 pwm channels. Add support for it. Also check if fan tachometers 4..6 are enabled before instantiating the respective sysfs attributes. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 114 ++++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 94 insertions(+), 20 deletions(-) commit 730554059bf26ab7a4f2cab8ed96e840a03d9b40 Author: Guenter Roeck <linux@roeck-us.net> Date: Thu Mar 26 09:16:32 2015 -0700 hwmon: (it87) Add feature flag for AVCC3 support AVCC3 is supported on IT8620E, similar to IT8603E. Add feature flag to indicate AVCC3 support. Don't enable it for now on IT8620E since it is unclear if this chip supports it correctly. Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/it87.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 11b8360851c22cdc0f939be56e28ce348bc3056f Author: Guenter Roeck <linux@roeck-us.net> Date: Mon Jan 18 00:34:53 2016 -0800 hwmon: (ltc2978) Add missing devicetree binding for LTM4675 Signed-off-by: Guenter Roeck <linux@roeck-us.net> Documentation/devicetree/bindings/hwmon/ltc2978.txt | 1 + 1 file changed, 1 insertion(+) commit 1d28e01628aebab8fe403e7e9d0760f3787763d5 Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:15 2016 +0800 hwmon: (fam15h_power) Add platform check function This patch adds a platform check function to make code more readable. Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/fam15h_power.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit a6e232f78698953e6fd9c2f4c95e16d5f5f9d0c3 Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:14 2016 +0800 hwmon: (fam15h_power) Add documentation for TDP and accumulated power algorithm This patch adds the description to explain the TDP reporting mechanism and accumulated power algorithm. Signed-off-by: Huang Rui <ray.huang@amd.com> Cc: Borislav Petkov <bp@alien8.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Documentation/hwmon/fam15h_power | 65 +++++++++++++++++++++++++++++++++++++++- drivers/hwmon/fam15h_power.c | 2 +- 2 files changed, 65 insertions(+), 2 deletions(-) commit 11bf0d78ccc4b2944aafd22ff05cd7e413ffea57 Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:13 2016 +0800 hwmon: (fam15h_power) Introduce a cpu accumulated power reporting algorithm This patch introduces an algorithm that computes the average power by reading a delta value of “core power accumulator” register during measurement interval, and then dividing delta value by the length of the time interval. User is able to use power1_average entry to measure the processor power consumption and power1_average_interval entry to set the interval. A simple example: ray@hr-ub:~/tip$ sensors fam15h_power-pci-00c4 Adapter: PCI adapter power1: 19.58 mW (avg = 2.55 mW, interval = 0.01 s) (crit = 15.00 W) ... The result is current average processor power consumption in 10 millisecond. The unit of the result is uWatt. Suggested-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Huang Rui <ray.huang@amd.com> Cc: Borislav Petkov <bp@alien8.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/fam15h_power.c | 128 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 124 insertions(+), 4 deletions(-) commit cdb9e110b10a08b7e1371356c2c03c73eb4f93d5 Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:12 2016 +0800 hwmon: (fam15h_power) Add ptsc counter value for accumulated power PTSC is the performance timestamp counter value in a cpu core and the cores in one compute unit have the fixed frequency. So it picks up the performance timestamp counter value of the first core per compute unit to measure the interval for average power per compute unit. Signed-off-by: Huang Rui <ray.huang@amd.com> Cc: Borislav Petkov <bp@alien8.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/fam15h_power.c | 4 ++++ 1 file changed, 4 insertions(+) commit fa7943449943124e40cabcd453b08c3f8221c454 Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:11 2016 +0800 hwmon: (fam15h_power) Add compute unit accumulated power This patch adds a member in fam15h_power_data which specifies the compute unit accumulated power. It adds do_read_registers_on_cu to do all the read to all MSRs and run it on one of the online cores on each compute unit with smp_call_function_many(). This behavior can decrease IPI numbers. Suggested-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/fam15h_power.c | 72 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 1 deletion(-) commit 3ba4e3841530b1565f761778bd0e14e242a4ab9a Author: Huang Rui <ray.huang@amd.com> Date: Wed Apr 6 15:44:10 2016 +0800 hwmon: (fam15h_power) Add CPU_SUP_AMD as the dependence This patch adds CONFIG_CPU_SUP_AMD as the dependence of fam15h_power driver. Because the following patch will use the interface from x86/kernel/cpu/amd.c. Otherwise, the below error might be encountered: All errors (new ones prefixed by >>): drivers/built-in.o: In function `fam15h_power_probe': >> fam15h_power.c:(.text+0x26e3a3): undefined reference to >> `amd_get_cores_per_cu' fam15h_power.c:(.text+0x26e41e): undefined reference to `amd_get_cores_per_cu' Reported-by: build test robot <lkp@intel.com> Acked-by: Borislav Petkov <bp@suse.de> Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 04e1e70afec6bb2940aea0ac2e9cbaf7d643d5f4 Author: Tiberiu Breana <tiberiu.a.breana@intel.com> Date: Wed Mar 30 19:16:24 2016 +0300 hwmon: (max31722) Add support for MAX31722/MAX31723 temperature sensors Add basic support for the Maxim Integrated MAX31722/MAX31723 SPI temperature sensors / thermostats. Includes: - ACPI support; - raw temperature readings; - power management Datasheet: https://datasheets.maximintegrated.com/en/ds/MAX31722-MAX31723.pdf Signed-off-by: Tiberiu Breana <tiberiu.a.breana@intel.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Documentation/hwmon/max31722 | 34 +++++++++ drivers/hwmon/Kconfig | 10 +++ drivers/hwmon/Makefile | 1 + drivers/hwmon/max31722.c | 165 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 210 insertions(+) commit 7a18afe8097731b8ffb6cb5b2b3b418ded77c105 Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Mon Apr 18 15:47:53 2016 -0400 hwmon: (ads7828) Enable internal reference On ads7828 the internal reference defaults to off upon power up. When using internal reference, it needs to be turned on and the voltage needs to settle before normal conversion cycle can be started. Hence perform a dummy read in the probe to enable the internal reference allowing the voltage to settle before performing a normal read. Without this fix, the first read from the ADC when using internal reference always returns incorrect data. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Cc: stable@vger.kernel.org # v4.1+ Signed-off-by: Guenter Roeck <linux@roeck-us.net> drivers/hwmon/ads7828.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit d23f0517357ef48d2845846e899d125b3c1a492e Author: Takashi Iwai <tiwai@suse.de> Date: Tue Apr 19 15:28:39 2016 +0200 ALSA: ens1371: Fix "Line In->Rear Out Switch" control The "Line In->Rear Out Switch" control on ens1371 driver returns a bogus value, always true, as its check is totally broken. Fix it to check the proper GPIO bit mask. Reported-by: David Binderman <dcb314@hotmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/ens1370.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d5c65edd930ff05ef036bbade87275e4b5b7b90 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 19:17:51 2016 +0300 drm/i915: Wait for power cycle delay after turning off DSI panel power The power cycle delay starts _after_ turning off the panel power. Do the msleep after frobbing the pmic panel power gpio. Also toss in a FIXME about optimizing away needless waits. Cc: Shobhit Kumar <shobhit.kumar@intel.com> Cc: Jani Nikula <jani.nikula@intel.com> Fixes: fc45e8219907 ("drm/i915: Use the CRC gpio for panel enable/disable") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460996271-29795-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Shobhit Kumar <shobhit.kumar@intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 9d0996b5903fec7bff64e169b860146a923a6abe Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 14:02:28 2016 +0300 drm/i915: Define HSW/BDW display power domains the right way up Currently we're trying to define HSW/BDW power wells by what's not included. Let's do it the other way around, so that you can actually tell when the power well would get enabled. This will also allow us to add new power domains without accidentally adding it to the HSW/BDW display power domains. The current set of domains looks rather buggy even: - POWER_DOMAIN_MODESET is included in the display power well needlessly - DDI-B to DDI-E were not part of the display power well when they should be So let's fix that up while at it. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460977348-32260-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_runtime_pm.c | 45 +++++++++++++++++++-------------- 1 file changed, 26 insertions(+), 19 deletions(-) commit 465ac0c6b619843f72e36c280cdfa6abf79b7a09 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 14:02:27 2016 +0300 drm/i915: Define VLV/CHV display power well domains properly Currently we're using POWER_DOMAIN_MASK as the power domains for the display power well on VLV/CHV. That includes all power domains even though the disp2d/pipe-a power well is not needed for a lot of things. Let's reduce these to what we actually need. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460977348-32260-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_runtime_pm.c | 42 +++++++++++++++++++++++++++++++-- 1 file changed, 40 insertions(+), 2 deletions(-) commit 998bd66a9dd9e260ad850bb0a9f303e2dd5aa87a Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 14:02:26 2016 +0300 drm/i915: Set .domains=POWER_DOMAIN_MASK for the always-on well The always-on well is the same as runtime PM, so we should just "enable" it for any power domain. Throw out the usless FOO_ALWAYS_ON_DOMAINS defines and just use POWER_DOMAIN_MASK. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460977348-32260-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_runtime_pm.c | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) commit 187a1c07ec3c19d0c965f95741ed260bbc02040e Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 20:34:04 2016 +0300 drm/i915: Fix oops in vlv_force_pll_on() intel_pipe_will_have_type() doesn't just look at the passied in pipe_config, instead it expects there to be a full atomic state behind it. Obviously that won't go so well when vlv_force_pll_on() just uses a temp pipe_config. Fix things by using pipe_config->has_dsi_encoder instead intel_pipe_will_have_type(INTEL_OUTPUT_DSI) to check if we need to actually enable the DPLL. Here's an example oops for reference: BUG: unable to handle kernel NULL pointer dereference at 0000000000000030 IP: [<ffffffffa0389a5b>] intel_pipe_will_have_type+0x15/0x7b [i915] PGD 7acda067 PUD 72696067 PMD 0 Oops: 0000 [#1] PREEMPT SMP Modules linked in: i915 i2c_algo_bit drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm intel_gtt agpgart netconsole psmouse atkbd iTCO_wdt libps2 coretemp hwmon efi_pstore intel_rapl punit_atom_debug efivars pcspkr i2c_i801 r8169 lpc_ich mii processor_thermal_device snd_soc_rt5670 intel_soc_dts_iosf snd_soc_rl6231 i2c_hid hid snd_intel_sst_acpi snd_intel_sst_core snd_soc_sst_mfld_platform snd_soc_sst_match snd_soc_core i8042 serio snd_compress snd_pcm snd_timer snd i2c_designware_platform sdhci_acpi i2c_designware_core soundcore sdhci pwm_lpss_platform mmc_core pwm_lpss spi_pxa2xx_platform evdev int3403_thermal int3400_thermal int340x_thermal_zone acpi_thermal_rel sch_fq_codel ip_tables x_tables ipv6 autofs4 CPU: 3 PID: 290 Comm: Xorg Tainted: G U 4.6.0-rc4-bsw+ #2876 Hardware name: Intel Corporation CHERRYVIEW C0 PLATFORM/Braswell CRB, BIOS BRAS.X64.X088.R00.1510270350 10/27/2015 task: ffff88007a8dd200 ti: ffff880173ac4000 task.ti: ffff880173ac4000 RIP: 0010:[<ffffffffa0389a5b>] [<ffffffffa0389a5b>] intel_pipe_will_have_type+0x15/0x7b [i915] RSP: 0018:ffff880173ac7928 EFLAGS: 00010246 RAX: 0000000000000000 RBX: ffff880176594000 RCX: 0000000000000000 RDX: 0000000000000000 RSI: 0000000000000009 RDI: ffff880176594000 RBP: ffff880173ac7930 R08: 0000000000019290 R09: 0000000000000000 R10: ffff880173ac7890 R11: 00000000000080cf R12: ffff88017fbd4000 R13: ffffffffa03e3c44 R14: ffff88007492c000 R15: ffff88007492c000 FS: 00007ff8936a6940(0000) GS:ffff88017ef80000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000030 CR3: 0000000177e08000 CR4: 00000000001006e0 Stack: ffff880176594000 ffff880173ac7948 ffffffffa0389b42 ffff880176594000 ffff880173ac7978 ffffffffa0396e02 ffff8801765b0000 ffff88007af660d8 0000000000000000 0000000000000004 ffff880173ac79c0 ffffffffa03b6b64 Call Trace: [<ffffffffa0389b42>] chv_compute_dpll.isra.39+0x33/0x55 [i915] [<ffffffffa0396e02>] vlv_force_pll_on+0x80/0xc6 [i915] [<ffffffffa03b6b64>] vlv_power_sequencer_pipe+0x29b/0x3dd [i915] [<ffffffffa03b6cd4>] _pp_stat_reg+0x2e/0x38 [i915] [<ffffffffa03b6dc1>] wait_panel_status+0x4c/0x1ec [i915] [<ffffffffa03b6fcb>] wait_panel_power_cycle+0x6a/0xb4 [i915] [<ffffffffa03b70da>] edp_panel_vdd_on+0xc5/0x1d1 [i915] [<ffffffffa03b861b>] intel_dp_aux_ch+0x55/0x572 [i915] [<ffffffff810af5c8>] ? mark_held_locks+0x5d/0x74 [<ffffffff81518e61>] ? mutex_lock_nested+0x321/0x346 [<ffffffff81094007>] ? preempt_count_sub+0xf2/0x102 [<ffffffffa03b8cb4>] intel_dp_aux_transfer+0x17c/0x1b5 [i915] [<ffffffffa03028ef>] drm_dp_dpcd_access+0x62/0xed [drm_kms_helper] [<ffffffffa0302995>] drm_dp_dpcd_read+0x1b/0x1f [drm_kms_helper] [<ffffffffa03b5147>] intel_dp_dpcd_read_wake+0x31/0x69 [i915] [<ffffffffa03bb36a>] intel_dp_long_pulse+0x15f/0x5ed [i915] [<ffffffffa03bbb09>] intel_dp_detect+0x79/0x95 [i915] [<ffffffffa030340e>] drm_helper_probe_single_connector_modes+0xc7/0x3db [drm_kms_helper] [<ffffffffa029de23>] drm_mode_getconnector+0xe9/0x333 [drm] [<ffffffff810b1cfb>] ? lock_acquire+0x137/0x1df [<ffffffffa0292364>] drm_ioctl+0x266/0x3ae [drm] [<ffffffffa029dd3a>] ? drm_mode_getcrtc+0x126/0x126 [drm] [<ffffffff811af082>] vfs_ioctl+0x18/0x34 [<ffffffff811af682>] do_vfs_ioctl+0x547/0x5fe [<ffffffff811b9acb>] ? __fget_light+0x62/0x71 [<ffffffff811af77c>] SyS_ioctl+0x43/0x61 [<ffffffff81001a82>] do_syscall_64+0x63/0xf8 [<ffffffff8151bc9a>] entry_SYSCALL64_slow_path+0x25/0x25 Code: 35 00 40 a0 e8 97 4b ce e0 b8 17 00 00 00 5d c3 b8 17 00 00 00 c3 0f 1f 44 00 00 55 31 c0 31 d2 48 89 e5 53 48 8b 8f e8 01 00 00 <44> 8b 49 30 41 39 c1 7e 2d 4c 8b 51 38 4c 8b 41 40 49 83 3c c2 RIP [<ffffffffa0389a5b>] intel_pipe_will_have_type+0x15/0x7b [i915] RSP <ffff880173ac7928> CR2: 0000000000000030 The regressing patch wasn't exactly new (as in first posted more than six months ago), so I'm a bit baffled how I didn't manage to hit this myself so far. Cc: Jani Nikula <jani.nikula@intel.com> Cc: Marius Vlad <marius.c.vlad@intel.com> Reported-by: Marius Vlad <marius.c.vlad@intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94995 Fixes: cd2d34d9b61f ("drm/i915: Setup DPLL/DPLLMD for DSI too on VLV/CHV") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1461000844-20543-1-git-send-email-ville.syrjala@linux.intel.com Tested-by: Marius Vlad <marius.c.vlad@intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 541ac1554e1269c4462a2166992d87b752abda64 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:31 2016 +0100 ARM: sun5i: Add DRAM gates The DRAM gates control whether the image / display devices on the SoC have access to the DRAM clock or not. Enable it. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-a13.dtsi | 23 ++++++++++++++++++++++- arch/arm/boot/dts/sun5i-r8.dtsi | 2 +- 2 files changed, 23 insertions(+), 2 deletions(-) commit 15bd920f9670f7fe13cec9148e5c05d160c2f30c Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:32 2016 +0100 ARM: sun5i: Add TV encoder gate to the DTSI It turns out that the A13 / R8 also have a tve encoder block, and a gate for it. Add it to the DT. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-a13.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 096559107bedf337c407be038a1d7926e85d8842 Author: Maxime Ripard <maxime.ripard@free-electrons.com> Date: Wed Mar 23 17:38:29 2016 +0100 ARM: sun5i: dt: Add pll3 and pll7 clocks Enable the pll3 and pll7 clocks in the DT that are used to drive the display-related clocks. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i.dtsi | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 125bc681bc5d8183594e30492f0345a61ab3cc94 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Mon Apr 18 17:24:06 2016 -0700 ASoC: tlv320aic32x4: Add SPI support Add support for running the tlv32x4 control channel over SPI rather than I2C. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 6 +++ sound/soc/codecs/Makefile | 2 + sound/soc/codecs/tlv320aic32x4-spi.c | 76 ++++++++++++++++++++++++++++++++++++ 3 files changed, 84 insertions(+) commit 3bcfd222f6f0c8758f369ce0db23fa3287db59a6 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Mon Apr 18 17:24:05 2016 -0700 ASoC: tlv320aic32x4: Break out I2C support into separate module To prepare for abstracting adding SPI support, the I2C pieces needs to be in its own moudle. This patch moves common probe code into aic32x4_probe and common removal code into aic32x4_remove. It also creates a static regmap config structure to be copied in the I2C specific driver. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 7 +++- sound/soc/codecs/Makefile | 2 + sound/soc/codecs/tlv320aic32x4-i2c.c | 74 +++++++++++++++++++++++++++++++++++ sound/soc/codecs/tlv320aic32x4.c | 76 ++++++++++++------------------------ sound/soc/codecs/tlv320aic32x4.h | 7 ++++ 5 files changed, 113 insertions(+), 53 deletions(-) commit ec513886411e4fc47f98607a1bc79b72899710c4 Author: Jeremy McDermond <nh6z@nh6z.net> Date: Mon Apr 18 17:24:04 2016 -0700 ASoC: tlv320aic32x4: Change name of probe function The codec's probe function is named aic32x4_probe. This is going to conflict with later work to implement SPI support and separate out I2S into its own file. In line with other drivers in the tree, this function is renamed to aic32x4_codec_probe instead. Signed-off-by: Jeremy McDermond <nh6z@nh6z.net> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tlv320aic32x4.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ee4c879b53eb5d757661b9bc8fcdf1a3d2e5fdfb Author: Moise Gergaud <moise.gergaud@st.com> Date: Tue Apr 19 11:24:45 2016 +0200 ASoC: sti-asoc-card: update tdm mode - Add "TDM" in the st,mode property list - st,mode property is also mandatory for reader - add tdm playback dai-link example Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/st,sti-asoc-card.txt | 44 +++++++++++++++++++--- 1 file changed, 39 insertions(+), 5 deletions(-) commit f74ed08d55a059a20dc1e513edc51c18dfaf2add Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 18 14:48:21 2016 +0300 drm/i915/gen9: Fix runtime PM refcounting in case DMC firmware isn't loaded While we disable runtime PM and with that display power well support if the DMC firmware isn't loaded, we still want to disable power wells during system suspend and driver unload. So drop/reacquire the corresponding power refcount during suspend/resume and driver unloading. This also means we have to check if DMC is not loaded and skip enabling DC states in the power well code. v2: - Reuse intel_csr_ucode_suspend() in intel_csr_ucode_fini() instead of opencoding the former. (Chris) - Add docbook comment to the public resume and suspend functions. CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460980101-14713-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 5 ++-- drivers/gpu/drm/i915/intel_csr.c | 44 +++++++++++++++++++++++++++++++-- drivers/gpu/drm/i915/intel_drv.h | 2 ++ drivers/gpu/drm/i915/intel_runtime_pm.c | 3 +++ 4 files changed, 50 insertions(+), 4 deletions(-) commit bf93ba67e9c05882f05b7ca2d773cfc8bf462c2a Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 18 10:04:21 2016 +0300 drm/i915/ddi: Fix eDP VDD handling during booting and suspend/resume The driver's VDD on/off logic assumes that whenever the VDD is on we also hold an AUX power domain reference. Since BIOS can leave the VDD on during booting and resuming and on DDI platforms we won't take a corresponding power reference, the above assumption won't hold on those platforms and an eventual delayed VDD off work will do an extraneous AUX power domain put resulting in a refcount underflow. Fix this the same way we did this for non-DDI DP encoders: commit 6d93c0c41760c0 ("drm/i915: fix VDD state tracking after system resume") At the same time call the DP encoder suspend handler the same way as the non-DDI DP encoders do to flush any pending VDD off work. Leaving the work running may cause a HW access where we don't expect this (at a point where power domains are suspended already). While at it remove an unnecessary function call indirection. This fixed for me AUX refcount underflow problems on BXT during suspend/resume. CC: Ville Syrjälä <ville.syrjala@linux.intel.com> CC: stable@vger.kernel.org Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460963062-13211-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 10 +++------- drivers/gpu/drm/i915/intel_dp.c | 4 ++-- drivers/gpu/drm/i915/intel_drv.h | 2 ++ 3 files changed, 7 insertions(+), 9 deletions(-) commit 44410cd0bfb26bde9288da34c190cc9267d42a20 Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 18 14:45:54 2016 +0300 drm/i915: Fix system resume if PCI device remained enabled During system resume we depended on pci_enable_device() also putting the device into PCI D0 state. This won't work if the PCI device was already enabled but still in D3 state. This is because pci_enable_device() is refcounted and will not change the HW state if called with a non-zero refcount. Leaving the device in D3 will make all subsequent device accesses fail. This didn't cause a problem most of the time, since we resumed with an enable refcount of 0. But it fails at least after module reload because after that we also happen to leak a PCI device enable reference: During probing we call drm_get_pci_dev() which will enable the PCI device, but during device removal drm_put_dev() won't disable it. This is a bug of its own in DRM core, but without much harm as it only leaves the PCI device enabled. Fixing it is also a bit more involved, due to DRM mid-layering and because it affects non-i915 drivers too. The fix in this patch is valid regardless of the problem in DRM core. v2: - Add a code comment about the relation of this fix to the freeze/thaw vs. the suspend/resume phases. (Ville) - Add a code comment about the inconsistent ordering of set power state and device enable calls. (Chris) CC: Ville Syrjälä <ville.syrjala@linux.intel.com> CC: Chris Wilson <chris@chris-wilson.co.uk> CC: stable@vger.kernel.org Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460979954-14503-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) commit 6e35e8ab6f7058cf5a53b30bf0085e0eaf61b4f7 Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 18 10:04:19 2016 +0300 drm/i915: Fix error path in i915_drm_resume_early If system resume fails, this may lead to a runtime PM wake reference underflow used for runtime PM state checking. Fixes: 1f814daca43a ("drm/i915: add support for checking if we hold an RPM reference") Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460963062-13211-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f454bfddf6ba557381d8bf5df50eff778602ff23 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Thu Apr 14 14:59:49 2016 +0300 perf/core, sched: Don't use clock function pointer to determine clock Now that local_clock() is explicitly inlined in sched.h, taking its pointer would uninline it in the compilation unit where it's done, making (among other things) comparing pointers to this function produce different results in different compilation units. Case in point, x86 perf core's user page updating function compares event's clock against &local_clock to see if it needs to set zero time offset related bits in the page. This patch fixes the latter by looking at the "use_clockid" event attribute instead, to determine whether local clock is used. Fixing the uninlined local_clock() in perf core is left as an exercise for the author of the prior work. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: eranian@google.com Cc: vince@deater.net Fixes: http://lkml.kernel.org/r/1459541050-13654-1-git-send-email-daniel.lezcano@linaro.org Link: http://lkml.kernel.org/r/1460635189-2320-1-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 82611c14c4e479715c071fb0f44ddd72dc632037 Author: Jan Glauber <jan.glauber@caviumnetworks.com> Date: Mon Apr 18 09:43:33 2016 +0200 arm64: Reduce verbosity on SMP CPU stop When CPUs are stopped during an abnormal operation like panic for each CPU a line is printed and the stack trace is dumped. This information is only interesting for the aborting CPU and on systems with many CPUs it only makes it harder to debug if after the aborting CPU the log is flooded with data about all other CPUs too. Therefore remove the stack dump and printk of other CPUs and only print a single line that the other CPUs are going to be stopped and, in case any CPUs remain online list them. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/smp.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit 3a72db703cc6965662ff6063befa7d7cf2b49a2e Author: Huang Shijie <shijie.huang@arm.com> Date: Mon Apr 18 09:49:56 2016 +0800 arm64: mm: remove the redundant code We already re-enable interrupts where necessary in the entry code, so there is no need to do it again in do_page fault. This patch removes the redundant code. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Huang Shijie <shijie.huang@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/fault.c | 4 ---- 1 file changed, 4 deletions(-) commit abfb9498ee1327f534df92a7ecaea81a85913bae Author: Dmitry Safonov <dsafonov@virtuozzo.com> Date: Mon Apr 18 16:43:43 2016 +0300 x86/entry: Rename is_{ia32,x32}_task() to in_{ia32,x32}_syscall() The is_ia32_task()/is_x32_task() function names are a big misnomer: they suggests that the compat-ness of a system call is a task property, which is not true, the compatness of a system call purely depends on how it was invoked through the system call layer. A task may call 32-bit and 64-bit and x32 system calls without changing any of its kernel visible state. This specific minomer is also actively dangerous, as it might cause kernel developers to use the wrong kind of security checks within system calls. So rename it to in_{ia32,x32}_syscall(). Suggested-by: Andy Lutomirski <luto@amacapital.net> Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Dmitry Safonov <dsafonov@virtuozzo.com> [ Expanded the changelog. ] Acked-by: Andy Lutomirski <luto@kernel.org> Cc: 0x7f454c46@gmail.com Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: akpm@linux-foundation.org Cc: linux-mm@kvack.org Link: http://lkml.kernel.org/r/1460987025-30360-1-git-send-email-dsafonov@virtuozzo.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/common.c | 2 +- arch/x86/include/asm/compat.h | 4 ++-- arch/x86/include/asm/thread_info.h | 2 +- arch/x86/kernel/process_64.c | 2 +- arch/x86/kernel/ptrace.c | 2 +- arch/x86/kernel/signal.c | 2 +- arch/x86/kernel/uprobes.c | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) commit 6666ea558b1f4134291c15ac59366f69c2d1f321 Merge: 91ed140 c3b46c7 Author: Ingo Molnar <mingo@kernel.org> Date: Tue Apr 19 10:38:52 2016 +0200 Merge tag 'v4.6-rc4' into x86/asm, to pick up fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 7a09b225f31031f8cac9e7801b6004e79f8b0da1 Author: Konstantin Khlebnikov <koct9i@gmail.com> Date: Tue Apr 19 11:21:15 2016 +0300 x86/build/defconfig/64: Enable CONFIG_E1000E=y Very common ethernet. Already enabled in i386_defconfig Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/146105407523.18740.6392078851674393377.stgit@zurg Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/configs/x86_64_defconfig | 1 + 1 file changed, 1 insertion(+) commit 9016875df408fc5db6a94a3c5f5f5503c916cf81 Author: Kees Cook <keescook@chromium.org> Date: Mon Apr 18 09:42:15 2016 -0700 x86/KASLR: Rename "random" to "random_addr" The variable "random" is also the name of a libc function. It's better coding style to avoid overloading such things, so rename it to the more accurate "random_addr". Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1460997735-24785-7-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 7de828dfe607013546ece7ce25aa9839e8f93a66 Author: Kees Cook <keescook@chromium.org> Date: Mon Apr 18 09:42:14 2016 -0700 x86/KASLR: Clarify purpose of kaslr.c The name "choose_kernel_location" isn't specific enough, and doesn't describe the primary thing it does: choosing a random location. This patch renames it to "choose_random_location", and clarifies the what routines are contained in the kaslr.c source file. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1460997735-24785-6-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 13 ++++++++++++- arch/x86/boot/compressed/misc.c | 2 +- arch/x86/boot/compressed/misc.h | 4 ++-- 3 files changed, 15 insertions(+), 4 deletions(-) commit c04028813221c2d39a4f368586795ac4466d311c Author: Kees Cook <keescook@chromium.org> Date: Mon Apr 18 09:42:13 2016 -0700 x86/boot: Clarify purpose of functions in misc.c The function "decompress_kernel" now performs many more duties, so this patch renames it to "extract_kernel" and updates callers and comments. Additionally the file header comment for misc.c is improved to actually describe what is contained. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1460997735-24785-5-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/head_32.S | 8 ++++---- arch/x86/boot/compressed/head_64.S | 4 ++-- arch/x86/boot/compressed/misc.c | 10 ++++++---- 3 files changed, 12 insertions(+), 10 deletions(-) commit 6655e0aaf768c39a62eea739c453b9db1e841cfb Author: Kees Cook <keescook@chromium.org> Date: Mon Apr 18 09:42:12 2016 -0700 x86/boot: Rename "real_mode" to "boot_params" The non-compressed boot code uses the (much more obvious) name "boot_params" for the global pointer to the x86 boot parameters. The compressed kernel loader code, though, was using the legacy name "real_mode". There is no need to have a different name, and changing it improves readability. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1460997735-24785-4-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/cmdline.c | 4 ++-- arch/x86/boot/compressed/kaslr.c | 22 +++++++++++----------- arch/x86/boot/compressed/misc.c | 27 ++++++++++++++------------- arch/x86/boot/compressed/misc.h | 2 +- 4 files changed, 28 insertions(+), 27 deletions(-) commit 206f25a8319b312b9983953a308b0e38e1943c1c Author: Yinghai Lu <yinghai@kernel.org> Date: Mon Apr 18 09:42:11 2016 -0700 x86/KASLR: Remove unneeded boot_params argument Since the boot_params can be found using the real_mode global variable, there is no need to pass around a pointer to it. This slightly simplifies the choose_kernel_location function and its callers. [kees: rewrote changelog, tracked file rename] Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460997735-24785-3-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/kaslr.c | 5 ++--- arch/x86/boot/compressed/misc.c | 2 +- arch/x86/boot/compressed/misc.h | 6 ++---- 3 files changed, 5 insertions(+), 8 deletions(-) commit 9b238748cb6e9fadab0e761f6d30ba311b4ac470 Author: Kees Cook <keescook@chromium.org> Date: Mon Apr 18 09:42:10 2016 -0700 x86/KASLR: Rename aslr.c to kaslr.c In order to avoid confusion over what this file provides, rename it to kaslr.c since it is used exclusively for the kernel ASLR, not userspace ASLR. Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Andy Lutomirski <luto@kernel.org> Cc: Baoquan He <bhe@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: H.J. Lu <hjl.tools@gmail.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Yinghai Lu <yinghai@kernel.org> Link: http://lkml.kernel.org/r/1460997735-24785-2-git-send-email-keescook@chromium.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/boot/compressed/Makefile | 2 +- arch/x86/boot/compressed/aslr.c | 339 -------------------------------------- arch/x86/boot/compressed/kaslr.c | 339 ++++++++++++++++++++++++++++++++++++++ arch/x86/boot/compressed/misc.h | 2 +- 4 files changed, 341 insertions(+), 341 deletions(-) commit 818ec3aba883f58225c9f5a2318cf373263869ed Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Apr 14 14:53:44 2016 +0300 usb: dwc3: debugfs: dump out endpoint details There's a bunch of information in the debug register set from dwc3 which is useful in some debugging scenarios. Let's dump them out in endpoint-specific directories and designated files. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/debugfs.c | 302 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 302 insertions(+) commit b058f3e8a3991ba3ea3504fea1faf81974cf17fa Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Apr 14 16:05:54 2016 +0300 usb: dwc3: core: add helper to extract trb type This helper will be used later to convert trb type into a human-readable string for debugfs. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 1 + 1 file changed, 1 insertion(+) commit cf6d867d3b57d4eca229b3c506216d98d88be49c Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Apr 14 15:03:39 2016 +0300 usb: dwc3: core: add fifo space helper this helper will be used, initially, to dump space of different queues and fifos in dwc3 to debugfs. Later, it'll be used to issue remote wakeup when we want to start a transfer and there's something in a TX FIFO. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.c | 14 ++++++++++++++ drivers/usb/dwc3/core.h | 14 ++++++++++++++ 2 files changed, 28 insertions(+) commit 097aa1975e9a5b189d4c6fbc95c0f97e2c49c01e Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 18 12:57:15 2016 +0300 usb: gadget: pch_udc: don't free devm allocated memory Coccinelle caught this instance of us kfree()ing devm-allocated memory. The solution is just to not do anything in our gadget_release. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) commit f78bbcae86e676fad9e6c6bb6cd9d9868ba23696 Author: Michal Nazarewicz <mina86@mina86.com> Date: Fri Apr 8 10:24:11 2016 +0200 usb: f_mass_storage: test whether thread is running before starting another When binding the function to usb_configuration, check whether the thread is running before starting another one. Without that, when function instance is added to multiple configurations, fsg_bing starts multiple threads with all but the latest one being forgotten by the driver. This leads to obvious thread leaks, possible lockups when trying to halt the machine and possible more issues. This fixes issues with legacy/multi¹ gadget as well as configfs gadgets when mass_storage function is added to multiple configurations. This change also simplifies API since the legacy gadgets no longer need to worry about starting the thread by themselves (which was where bug in legacy/multi was in the first place). N.B., this patch doesn’t address adding single mass_storage function instance to a single configuration twice. Thankfully, there’s no legitimate reason for such setup plus, if I’m not mistaken, configfs gadget doesn’t even allow it to be expressed. ¹ I have no example failure though. Conclusion that legacy/multi has a bug is based purely on me reading the code. Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Tested-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: <stable@vger.kernel.org> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_mass_storage.c | 36 ++++++++++++---------------- drivers/usb/gadget/function/f_mass_storage.h | 2 -- drivers/usb/gadget/legacy/acm_ms.c | 4 ---- drivers/usb/gadget/legacy/mass_storage.c | 4 ---- drivers/usb/gadget/legacy/multi.c | 12 ---------- drivers/usb/gadget/legacy/nokia.c | 7 ------ 6 files changed, 15 insertions(+), 50 deletions(-) commit 332a5b446b7916d272c2a659a3b20909ce34d2c1 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Wed Mar 30 13:49:14 2016 +0200 usb: gadget: f_fs: Fix EFAULT generation for async read operations In the current implementation functionfs generates a EFAULT for async read operations if the read buffer size is larger than the URB data size. Since a application does not necessarily know how much data the host side is going to send it typically supplies a buffer larger than the actual data, which will then result in a EFAULT error. This behaviour was introduced while refactoring the code to use iov_iter interface in commit c993c39b8639 ("gadget/function/f_fs.c: use put iov_iter into io_data"). The original code took the minimum over the URB size and the user buffer size and then attempted to copy that many bytes using copy_to_user(). If copy_to_user() could not copy all data a EFAULT error was generated. Restore the original behaviour by only generating a EFAULT error when the number of bytes copied is not the size of the URB and the target buffer has not been fully filled. Commit 342f39a6c8d3 ("usb: gadget: f_fs: fix check in read operation") already fixed the same problem for the synchronous read path. Fixes: c993c39b8639 ("gadget/function/f_fs.c: use put iov_iter into io_data") Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/function/f_fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9bc07890f891267285716c09bfee58e239137d36 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Mon Apr 11 15:05:12 2016 +0200 usb: gadget: r8a66597-udc: Deinline pipe_change, save 2176 bytes This function compiles to 298 bytes of machine code, has ~10 callsites. This is a USB 2.0 device, USB 2.0 is limited to ~40 MB/s, so should be almost never CPU bound. No need to optimize for speed this agressively. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: Felipe Balbi <balbi@ti.com> CC: linux-usb@vger.kernel.org CC: linux-kernel@vger.kernel.org Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/r8a66597-udc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b41d8a6a014fba420a428244e04699b9c77a44f1 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Mon Apr 18 16:53:42 2016 +0900 usb: renesas_usbhs: use usb_gadget_{un}map_request_by_dev() for IPMMU The previous code could use the first USB-DMAC with IPMMU if iommus property was set into this device node. However, in this case, it could not control the second USB-DMAC with IPMMU because a parameter of IPMMU (micro-TLB id) is different with each USB-DMAC. So, this patch uses the usb_gadget_{un}map_request_by_dev() APIs for IPMMU. (Then, iommus property should be set into USB-DMAC node(s).) Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/renesas_usbhs/mod_gadget.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit c3cdcac786ae8ce9221a05609952d14aa57c27f7 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Mon Apr 18 16:53:41 2016 +0900 usb: renesas_usbhs: change arguments of dma_map_ctrl() Since usbhsg_dma_map_ctrl() needs DMA device structure in the near future, this patch changes arguments of dma_map_ctrl() to give such data. (This patch is only change the argument.) Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/renesas_usbhs/fifo.c | 4 +++- drivers/usb/renesas_usbhs/mod_gadget.c | 3 ++- drivers/usb/renesas_usbhs/mod_host.c | 3 ++- drivers/usb/renesas_usbhs/pipe.c | 3 ++- drivers/usb/renesas_usbhs/pipe.h | 6 ++++-- 5 files changed, 13 insertions(+), 6 deletions(-) commit e789ece1823596f24076aed1b9a2182a81b0a6b7 Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Mon Apr 18 16:53:40 2016 +0900 usb: renesas_usbhs: change function call orfer in usbhsf_dma_prepare_push() Since usbhsf_dma_{un}map() will use the "fifo" data in the near future, this patch changes function call orfer in usbhsf_dma_prepare_push(). Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/renesas_usbhs/fifo.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 679ca39fc670a5a95c2b40d2cc8cf2cee2486f7a Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Mon Apr 18 16:53:39 2016 +0900 usb: gadget: udc: core: add usb_gadget_{un}map_request_by_dev() If the following environment, the first argument of DMA API should be set to a DMAC's device structure, not a udc controller's one. - A udc controller needs an external DMAC device (like a DMA Engine). - The external DMAC enables IOMMU. So, this patch add usb_gadget_{un}map_request_by_dev() API to set a DMAC's device structure by a udc controller driver. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/udc-core.c | 24 ++++++++++++++++++------ include/linux/usb/gadget.h | 4 ++++ 2 files changed, 22 insertions(+), 6 deletions(-) commit 5096c4d3bfa75bdd23c78f799aabd08598afb48f Author: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Date: Mon Apr 18 16:53:38 2016 +0900 usb: gadget: udc: core: Fix argument of dev_err() in usb_gadget_map_request() The argument of dev_err() in usb_gadget_map_request() should be dev instead of &gadget->dev. Fixes: 7ace8fc ("usb: gadget: udc: core: Fix argument of dma_map_single for IOMMU") Cc: <stable@vger.kernel.org> # v4.3+ Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> drivers/usb/gadget/udc/udc-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4e9f311833a946e984c82086b21b128918f4a6a4 Author: Du, Changbin <changbin.du@intel.com> Date: Tue Apr 12 19:10:18 2016 +0800 usb: dwc3: make dwc3_debugfs_init return value be void Debugfs init failure is not so important. We can continue our job on this failure. Also no break need for debugfs_create_file call failure. Signed-off-by: Du, Changbin <changbin.du@intel.com> [felipe.balbi@linux.intel.com : - remove out-of-memory message, we get that from OOM. - switch dev_err() to dev_dbg() ] Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.c | 10 +-------- drivers/usb/dwc3/debug.h | 6 ++--- drivers/usb/dwc3/debugfs.c | 55 ++++++++++++++++------------------------------ 3 files changed, 23 insertions(+), 48 deletions(-) commit af566a0be6e49b946708532a6a7a7ae29ab83aed Author: Roger Quadros <rogerq@ti.com> Date: Mon Apr 11 17:18:25 2016 +0300 usb: dwc3: omap: get rid of dma_status dma_status bit flag is set but never really used so get rid of it. Reported-by: Felipe Balbi <balbi@kernel.org> Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-omap.c | 6 ------ 1 file changed, 6 deletions(-) commit 8e7046b71daeb6dfbf8c6eaa164e55d4e1dcb5c8 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Wed Apr 6 10:01:14 2016 +0300 usb: dwc3: gadget: don't interrupt when chained It makes no sense to interrupt in the middle of chained transfer. This patch just makes sure we don't do that. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 052ba52efa1717651d303a9b88f2e8cbb91702c6 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 15:05:05 2016 +0300 usb: dwc3: gadget: remove newline from trace trace already adds a newline character for us, we don't need to do it ourselves. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 36b68aae8e39ad456eec1ec2073eee388cbcc106 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 13:24:36 2016 +0300 usb: dwc3: gadget: use link TRB for all endpoint types instead of limiting link TRB only to Isoc endpoints, let's use it for all endpoint types, this way we are more likely to transfer more data before a XferComplete event. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 49 ++++++++++------------------------------------- 1 file changed, 10 insertions(+), 39 deletions(-) commit 4faf75504a7db790483aa419d8f61e58cec4934c Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 13:14:31 2016 +0300 usb: dwc3: gadget: move % operation to increment helpers By moving our % DWC3_NUM_TRB operation to the increment helpers, the rest of the driver can be simplified. It's also a good practice to make sure we will have a single place dealing with details about how to increment our enqueue and dequeue pointers. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit ef966b9d33533b0bf01fb8c4d586ac3b20a3bdb5 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 13:09:51 2016 +0300 usb: dwc3: gadget: add trb enqueue/dequeue helpers Add three little helpers which will aid in making the code slightly easier to read. One helper increments enqueue pointer, another increments dequeue pointer and the last one tests if we're dealing with the last TRB. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) commit 70fdb273db37196e9e5d292d5778a99fededb32f Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 12:47:15 2016 +0300 usb: dwc3: get rid of DWC3_TRB_MASK instead of using a bitwise and, let's rely on the % operator since that's a lot more clear. Also, GCC will optimize % 256 to nothing anyway. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 1 - drivers/usb/dwc3/gadget.c | 14 +++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) commit f15c65afddbe16a832cfe3f311588c7e34a4efbf Author: Martin Dummer <martin.dummer@gmx.net> Date: Tue Apr 19 07:51:48 2016 +0200 leds: ss4200: add DMI data for FSC SCALEO Home Server The Intel NAS SS4200 was also sold by Fujitsu Siemens (FSC) under the name "SCALEO Home Server". The hardware is equivalent. This patch adds the DMI data of this rebranded device. Signed-off-by: Martin Dummer <martin.dummer@gmx.net> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/leds-ss4200.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit fe15ee47e48d6d10f60c11ac7a15ecc0d147d9ea Author: Martin Dummer <martin.dummer@gmx.net> Date: Sun Apr 17 13:27:52 2016 +0200 leds: ss4200: Add depend on x86 arch There is only one x86 hardware where the driver leds-ss4200 applies to. Add kconfig dependency to x86 architecture, fix help text whitespace. Signed-off-by: Martin Dummer <martin.dummer@gmx.net> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/Kconfig | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit ba5776ab6f09800dd9ba8442185139661e065529 Author: Brian Norris <briannorris@chromium.org> Date: Mon Apr 11 10:27:32 2016 -0700 mfd: cros_ec: Allow building for ARM64 There are platforms using the ChromeOS embeded controller on ARM64 now, so let's allow using this driver (without having to use COMPILE_TEST). Signed-off-by: Brian Norris <briannorris@chromium.org> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8a0aee4a7c8500278495012d8f4b653033df83a3 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Mon Apr 4 18:46:02 2016 -0400 mfd: max77686: Use module_i2c_driver() instead of subsys initcall The driver's init and exit function don't do anything besides adding and deleting the I2C driver so the module_i2c_driver() macro could be used. Currently is not being used because the driver is initialized at subsys initcall level, claiming that this is done to allow consumers devices to use the resources provided by this driver. But dependencies are in DT so manual ordering of init calls is not necessary any more. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Andi Shyti <andi.shyti@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/max77686.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 630fd98c0a7fcba67d4b33440793b0c9bd1fb440 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Apr 5 11:04:51 2016 +0900 mfd: max77686/max77693: Fix misspelled Samsung address Correct smasung.com into samsung.com. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/max77686.c | 2 +- drivers/mfd/max77693.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 7ad073695dff7b1fc2a6ef2e8112d96a76fc8dc4 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:09 2016 +0200 mfd: vexpress-sysreg: Switch to gpiochip_add_data() We're planning to remove the gpiochip_add() function to swith to gpiochip_add_data() with NULL for data argument. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/vexpress-sysreg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d94352eba4f943734c19d172a834d0b2affec09 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:08 2016 +0200 mfd: ucb1x00: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/ucb1x00-core.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 22e5e747e71f19ac3af60ce648f4c02c63ed3cc1 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:07 2016 +0200 mfd: tps65010: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps65010.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 4e125f62b73dffde17f4c53155654623ab2a9855 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:06 2016 +0200 mfd: tc6393xb: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Dmitry Baryshkov <dbaryshkov@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tc6393xb.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 3a504105f0e4cf32464d596f3b30d23dbfd76520 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:05 2016 +0200 mfd: sm501: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Ben Dooks <ben@fluff.org.uk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/sm501.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit ed1c9b3c18e33a69da0a911eadf4948ea7e5b5b9 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:04 2016 +0200 mfd: htc-i2cpld: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/htc-i2cpld.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 8d5f095fc5f7e36f40a80e87317828be249ee454 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:03 2016 +0200 mfd: htc-egpio: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Acked-by: Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/htc-egpio.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 4363765c851313d460db86f2d41d2eebca0d9c17 Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:02 2016 +0200 mfd: dm355evm_msp: Switch to gpiochip_add_data() We're planning to remove the gpiochip_add() function to swith to gpiochip_add_data() with NULL for data argument. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/dm355evm_msp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 082cc468385dbc7bbdc234bf6f2577e64fc00bbb Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Mar 30 10:48:01 2016 +0200 mfd: asic3: Use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Paul Parsons <lost.distance@yahoo.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/asic3.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit cbdd535d9481025a5a9020f9e9875b68ad86111c Author: Chen Feng <puck.chen@hisilicon.com> Date: Sun Feb 14 14:29:19 2016 +0800 mfd: hi655x: Add document for hi665x PMIC DT bindings for hisilicon HI655x PMIC chip. Signed-off-by: Chen Feng <puck.chen@hisilicon.com> Signed-off-by: Fei Wang <w.f@huawei.com> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Reviewed-by: Haojian Zhuang <haojian.zhuang@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> .../devicetree/bindings/mfd/hisilicon,hi655x.txt | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit cf6fea8cda8ae3b5b7576fa6bd2b35905e155967 Author: Jacek Anaszewski <j.anaszewski@samsung.com> Date: Mon Apr 18 16:09:55 2016 +0200 leds: ledtrig-ide-disk: Move ide_blink_delay to ledtrig_ide_activity() Parameters delay_on and delay_off of led_trigger_blink_oneshot() are pointers, to enable blink interval adjustment by LED class drivers of the controllers that implement hardware blinking. Move ide_blink_delay variable to ledtrig_ide_activity() in order to prevent the situation when adjustment committed by one LED class driver influences blink interval of the software fallback blink feature, that is applied to the drivers that don't implement blink_set op. Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/trigger/ledtrig-ide-disk.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7825dc05601b38f99808830098fd4f512c876b4e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:14 2016 +0530 mfd: wm8400: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Mark Brown <broonie@kernel.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/wm8400-core.c | 25 +++---------------------- 1 file changed, 3 insertions(+), 22 deletions(-) commit f3466e7764783ed4fae91ebe1653b0a08cca22bf Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:13 2016 +0530 mfd: tps65910: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and remove the call of mfd_remove_devices() from .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Tony Lindgren <tony@atomide.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps65910.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit b89b6b6bcd570a0beb1fc6fb8d0ecc20316413ab Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:12 2016 +0530 mfd: tps65217: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Tony Lindgren <tony@atomide.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps65217.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) commit 5635d994fe870a0de2614e83bbf2d70f506651eb Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:11 2016 +0530 mfd: tps6507x: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Todd Fischer <todd.fischer@ridgerun.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/tps6507x.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit e253fb0472e7a892176c7a65cef61a6aa75f8d2e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:10 2016 +0530 mfd: stw481x: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/stw481x.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit 69633beaebf345cde6672a9ac7679c88fc0c3245 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:09 2016 +0530 mfd: sky81452: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Gyungoh Yoo <jack.yoo@skyworksinc.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/sky81452.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit 6b719eba9f01cd65ede04e64f20f648f8dbe6359 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:08 2016 +0530 mfd: rt5033: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Ingi Kim <ingi2.kim@samsung.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/rt5033.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit f41206c9fd5c48becdb0f2f65328c5438f6ea34d Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:07 2016 +0530 mfd: rn5t618: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and remove the call of mfd_remove_devices() from .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Beniamino Galvani <b.galvani@gmail.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/rn5t618.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit d5623161accbc567452700add15d76fc092b07fe Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:06 2016 +0530 mfd: rk808: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and remove the call of mfd_remove_devices() from .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Chris Zhong <zyw@rock-chips.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/rk808.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 7360544c2b91d5689b635b2117f5e85986cf529b Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:05 2016 +0530 mfd: rdc321x: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Florian Fainelli <florian@openwrt.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/rdc321x-southbridge.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 08e380a53a92a445bdfd98e09680237bf0c269aa Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:04 2016 +0530 mfd: mt6397: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: John Crispin <blogic@openwrt.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/mt6397-core.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) commit 7990ad17a9debc2c91ffc1413d01450c982fcb8d Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:03 2016 +0530 mfd: menf21bmc: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Andreas Werner <andreas.werner@men.de> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/menf21bmc.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit c5f244549425c83835759f2d338967d0e798fda3 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:02 2016 +0530 mfd: lp3943: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Milo Kim <milo.kim@ti.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Milo Kim <milo.kim@ti.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/lp3943.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 9c384b0268c69a36e6b5d9c6b336fb81a63d457e Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:01 2016 +0530 mfd: hi6421-pmic: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/hi6421-pmic-core.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 9148f2c01827fe1c8c8d589ac54b0f459759d78b Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:13:00 2016 +0530 mfd: bcm590xx: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Matt Porter <mporter@linaro.org> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/bcm590xx.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit f32fb9a593704a32ddc395686fa00075d10df173 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:12:59 2016 +0530 mfd: atmel-hlcdc: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/atmel-hlcdc.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) commit 9c9983267deab5c268676d8ac15686923b6e5e19 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:12:58 2016 +0530 mfd: as3711: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/as3711.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) commit f9932c6e66c17ca3d84a7c6424c844bea8003ffb Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:12:57 2016 +0530 mfd: act8945a: Use devm_mfd_add_devices() for mfd_device registration Use devm_mfd_add_devices() for MFD devices registration and get rid of .remove callback to remove MFD child-devices. This is done by managed device framework. CC: Wenyou Yang <wenyou.yang@atmel.com> CC: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/act8945a.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit 3698283b101388cb9d992ae4d34329f005aa35e8 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:12:56 2016 +0530 mfd: Add devm_mfd_add_devices() in list of managed interfaces Add devm wrappers for the mfd_add_devices() in the list of managed interfaces. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Documentation/driver-model/devres.txt | 3 +++ 1 file changed, 3 insertions(+) commit a8f447be8056d9ce17bf7757d6de79426700bb8b Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Apr 8 00:12:55 2016 +0530 mfd: Add resource managed APIs for mfd_add_devices Add resource managed API devm_mfd_add_devices() for the mfd_add_devices(). This helps in reducing code in error path as it is not required to call mfd_remove_devices() explicitly to remove all child-devices. In some cases, it also helps not to implement .remove() callback which get called during driver unbind. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/mfd-core.c | 38 ++++++++++++++++++++++++++++++++++++++ include/linux/mfd/core.h | 4 ++++ 2 files changed, 42 insertions(+) commit bd425113a186f6dc104e07cd501916dc51f25e6a Author: Chen-Yu Tsai <wens@csie.org> Date: Tue Mar 29 17:22:25 2016 +0800 mfd: axp20x: Add bindings for AXP809 PMIC This patch adds the basic and regulator bindings for the X-Powers AXP809 PMIC. Also update the DC-DC converter operating frequency for AXP22X/AXP80X. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Documentation/devicetree/bindings/mfd/axp20x.txt | 31 ++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) commit 20147f0d4f50f6f0d1fbe1815fe3d4d0a6444a70 Author: Chen-Yu Tsai <wens@csie.org> Date: Tue Mar 29 17:22:26 2016 +0800 mfd: axp20x: Add support for AXP809 PMIC The X-Powers AXP809 is a new PMIC that is paired with Allwinner's A80 SoC, along with a slave AXP806 PMIC. This PMIC is quite similar to the earlier AXP223, though the interrupts and regulator have changed a bit. This patch adds support for the interrupts and power button of the PMIC. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/axp20x-rsb.c | 1 + drivers/mfd/axp20x.c | 79 ++++++++++++++++++++++++++++++++++++++++++++++ include/linux/mfd/axp20x.h | 59 ++++++++++++++++++++++++++++++++++ 3 files changed, 139 insertions(+) commit dedf24a28da67f6bf814cb5d05a5d12bb39093dc Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Fri Mar 25 14:27:09 2016 +0000 mfd: arizona: Fix lockdep recursion warning on set_irq_wake Avoid a false recursive locking warning from lockdep by adding a lock class for the arizona IRQ chip. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/arizona-irq.c | 3 +++ 1 file changed, 3 insertions(+) commit 073d4aca342029fc62fefa500bb11a556c5f7223 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 4 16:54:18 2016 +0900 mfd: max77693: Allow building as a module The consumer of max77693 regulators on Trats2 board (samsung-usb2-phy driver) supports deferred probing so the max77693 main MFD driver can be built now as a module. This gives more flexibility and removes manual ordering of init calls. Suggested-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/Kconfig | 4 ++-- drivers/mfd/max77693.c | 14 ++------------ 2 files changed, 4 insertions(+), 14 deletions(-) commit c796c50b9c20b586cd8c3e3a57cea4f0762a60fc Author: Steve Twiss <stwiss.opensource@diasemi.com> Date: Tue Apr 5 09:41:47 2016 +0100 mfd: da9063: Remove unused struct da9063_irq_data and define EVENTS_BUF_LEN The structure da9063_irq_data and define EVENTS_BUF_LEN are not used, so remove the redundant entries. Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/da9063-irq.c | 6 ------ 1 file changed, 6 deletions(-) commit b67d1df5ad0c227adc89d2913e933ed4addc5dab Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Apr 18 23:58:30 2016 +0200 net: w5100: don't build spi driver without w5100 The w5100-spi driver front-end only makes sense when the w5100 core driver is enabled, not for a configuration that only has w5300: drivers/net/built-in.o: In function `w5100_spi_remove': drivers/net/ethernet/wiznet/w5100-spi.c:277: undefined reference to `w5100_remove' drivers/net/built-in.o: In function `w5100_spi_probe': drivers/net/ethernet/wiznet/w5100-spi.c:272: undefined reference to `w5100_probe' drivers/net/built-in.o: In function `w5200_spi_init': drivers/net/ethernet/wiznet/w5100-spi.c:125: undefined reference to `w5100_ops_priv' drivers/net/built-in.o: In function `w5200_spi_readbulk': drivers/net/ethernet/wiznet/w5100-spi.c:125: undefined reference to `w5100_ops_priv' drivers/net/built-in.o: In function `w5200_spi_writebulk': drivers/net/ethernet/wiznet/w5100-spi.c:125: undefined reference to `w5100_ops_priv' drivers/net/built-in.o:(.data+0x3ed1c): undefined reference to `w5100_pm_ops' This adds an appropriate Kconfig dependency. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 630cf09751fe ("net: w5100: support SPI interface mode") Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 266a0a790fb545fa1802a899ac44f61b1d6335a7 Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:29:33 2016 +0200 bpf: avoid warning for wrong pointer cast Two new functions in bpf contain a cast from a 'u64' to a pointer. This works on 64-bit architectures but causes a warning on all 32-bit architectures: kernel/trace/bpf_trace.c: In function 'bpf_perf_event_output_tp': kernel/trace/bpf_trace.c:350:13: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] u64 ctx = *(long *)r1; This changes the cast to first convert the u64 argument into a uintptr_t, which is guaranteed to be the same size as a pointer. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 9940d67c93b5 ("bpf: support bpf_get_stackid() and bpf_perf_event_output() in tracepoint programs") Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/trace/bpf_trace.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b520bd07595b117a08871ebc0a16452cc798d35b Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 17 01:05:19 2016 +0300 of_mdio: make of_mdiobus_register_{device|phy}() *void* The results of of_mdiobus_register_{device|phy}() are never checked, so we can make both these functions *void*... Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/of/of_mdio.c | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) commit 5d8813271f8a7c86027afb2ef554f2a5a9ba7c15 Author: Lv Zheng <lv.zheng@intel.com> Date: Mon Apr 11 10:13:33 2016 +0800 ACPI / tables: Convert initrd table override to table upgrade mechanism This patch converts the initrd table override mechanism to the table upgrade mechanism by restricting its usage to the tables released with compatibility and more recent revision. This use case has been encouraged by the ACPI specification: 1. OEMID: An OEM-supplied string that identifies the OEM. 2. OEM Table ID: An OEM-supplied string that the OEM uses to identify the particular data table. This field is particularly useful when defining a definition block to distinguish definition block functions. OEM assigns each dissimilar table a new OEM Table Id. 3. OEM Revision: An OEM-supplied revision number. Larger numbers are assumed to be newer revisions. For OEMs, good practices will ensure consistency when assigning OEMID and OEM Table ID fields in any table. The intent of these fields is to allow for a binary control system that support services can use. Because many support function can be automated, it is useful when a tool can programatically determine which table release is a compatible and more recent revision of a prior table on the same OEMID and OEM Table ID. The facility can now be used by the vendors to upgrade wrong tables for bug fixing purpose, thus lockdep disabling taint is not suitable for it and it should be a default 'y' option to implement the spec encouraged use case. Note that, by implementing table upgrade inside of ACPICA itself, it is possible to remove acpi_table_initrd_override() and tables can be upgraded by acpi_install_table() automatically. Though current ACPICA impelentation hasn't implemented this, this patched changes the table flag setting timing to allow this to be implemented in ACPICA without changing the code here. Documentation of initrd override mechanism is upgraded accordingly. Original-by: Octavian Purdila <octavian.purdila@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Documentation/acpi/initrd_table_override.txt | 65 +++++++++++++++++----------- drivers/acpi/Kconfig | 8 ++-- drivers/acpi/tables.c | 48 ++++++++++++++------ 3 files changed, 77 insertions(+), 44 deletions(-) commit af06f8b7a102417e93dc57ee7affb9fedcf5d83f Author: Lv Zheng <lv.zheng@intel.com> Date: Mon Apr 11 10:13:27 2016 +0800 ACPI / x86: Cleanup initrd related code In arch/x86/kernel/setup.c, the #ifdef kept for CONFIG_ACPI actually is related to the accessibility of initrd_start/initrd_end, so the stub should be provided from this source file and should only be dependent on CONFIG_BLK_DEV_INITRD. Note that when ACPI=n and BLK_DEV_INITRD=y, early_initrd_acpi_init() is still a stub because of the stub prepared for early_acpi_table_init(). Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/kernel/setup.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 5ae74f2cc2f150c1a5cee54cabbd71dd0661285a Author: Lv Zheng <lv.zheng@intel.com> Date: Mon Apr 11 10:13:18 2016 +0800 ACPI / tables: Move table override mechanisms to tables.c This patch moves acpi_os_table_override() and acpi_os_physical_table_override() to tables.c. Along with the mechanisms, acpi_initrd_initialize_tables() is also moved to tables.c to form a static function. The following functions are renamed according to this change: 1. acpi_initrd_override() -> renamed to early_acpi_table_init(), which invokes acpi_table_initrd_init() 2. acpi_os_physical_table_override() -> which invokes acpi_table_initrd_override() 3. acpi_initialize_initrd_tables() -> renamed to acpi_table_initrd_scan() Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/kernel/setup.c | 2 +- drivers/acpi/internal.h | 1 - drivers/acpi/osl.c | 274 --------------------------------------------- drivers/acpi/tables.c | 292 +++++++++++++++++++++++++++++++++++++++++++++++- include/linux/acpi.h | 10 +- 5 files changed, 294 insertions(+), 285 deletions(-) commit b0ec633c28d42281c03b41dbc92a4448a481f2f3 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Sat Apr 16 13:46:14 2016 -0700 bus: brcmstb_gisb: Rework dependencies Do not have the machine Kconfig entry point need to select BRCMSTB_GISB_ARB, instead, just let it be default ARCH_BRCMSTB which is a better way to deal with this. While at it, also make it default BMIPS_GENERIC so the legacy MIPS-based STB platforms can benefit from the same thing. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm/mach-bcm/Kconfig | 1 - drivers/bus/Kconfig | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) commit cef4bafcea2c33b0c296595cebd95f0cfd99f278 Author: Justin Chen <justin.chen@broadcom.com> Date: Wed Mar 23 11:56:50 2016 -0700 soc: brcmstb: add SoC driver to brcmstb Value of soc_dev_attributes: * family = chip family id * soc_id = product id * revision = product revision Signed-off-by: Justin Chen <justin.chen@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm/mach-bcm/Kconfig | 1 + drivers/soc/brcmstb/common.c | 58 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+) commit 4a96300cec88729415683db8a2b909563b09fbaa Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Fri Apr 15 12:24:57 2016 +0200 netfilter: ctnetlink: restore inlining for netlink message size calculation Calm down gcc warnings: net/netfilter/nf_conntrack_netlink.c:529:15: warning: 'ctnetlink_proto_size' defined but not used [-Wunused-function] static size_t ctnetlink_proto_size(const struct nf_conn *ct) ^ net/netfilter/nf_conntrack_netlink.c:546:15: warning: 'ctnetlink_acct_size' defined but not used [-Wunused-function] static size_t ctnetlink_acct_size(const struct nf_conn *ct) ^ net/netfilter/nf_conntrack_netlink.c:556:12: warning: 'ctnetlink_secctx_size' defined but not used [-Wunused-function] static int ctnetlink_secctx_size(const struct nf_conn *ct) ^ net/netfilter/nf_conntrack_netlink.c:572:15: warning: 'ctnetlink_timestamp_size' defined but not used [-Wunused-function] static size_t ctnetlink_timestamp_size(const struct nf_conn *ct) ^ So gcc compiles them out when CONFIG_NF_CONNTRACK_EVENTS and CONFIG_NETFILTER_NETLINK_GLUE_CT are not set. Fixes: 4054ff45454a9a4 ("netfilter: ctnetlink: remove unnecessary inlining") Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Acked-by: Arnd Bergmann <arnd@arndb.de> net/netfilter/nf_conntrack_netlink.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 534536acdb25bae85a5333b7085837b3f1f72b73 Author: Daniel Baluta <daniel.baluta@intel.com> Date: Fri Apr 15 17:13:10 2016 +0300 iio: magn: bmc150: Introduce SPI support Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/Kconfig | 16 +++++++ drivers/iio/magnetometer/Makefile | 1 + drivers/iio/magnetometer/bmc150_magn_spi.c | 68 ++++++++++++++++++++++++++++++ 3 files changed, 85 insertions(+) commit 761b7910d4b4f0e7d283873b701ca83beacd70a5 Author: Daniel Baluta <daniel.baluta@intel.com> Date: Fri Apr 15 17:13:09 2016 +0300 iio: magn: Split bmc150 driver in common/i2c parts This is useful for easily adding SPI support in later patches. Now bmc150_magn exports core functions to be used by I2C/SPI drivers instances. For the moment only I2C driver is supported. Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Acked-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/Kconfig | 17 ++-- drivers/iio/magnetometer/Makefile | 2 + drivers/iio/magnetometer/bmc150_magn.c | 155 ++++++++++++----------------- drivers/iio/magnetometer/bmc150_magn.h | 11 ++ drivers/iio/magnetometer/bmc150_magn_i2c.c | 77 ++++++++++++++ 5 files changed, 163 insertions(+), 99 deletions(-) commit 7ce04cff59d510c88bfa0745202281cf3c6417ae Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Thu Apr 7 21:05:07 2016 +0530 usb: wusbcore: remove unreachable code The call to wusb_dev_sysfs_rm() which is just after return will never be executed. On checking the code, wusb_dev_sysfs_add() is the last one to be executed so even if that fails we do not need wusb_dev_sysfs_rm() in the error path. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/wusbcore/devconnect.c | 1 - 1 file changed, 1 deletion(-) commit bb7871ad99ea814565c3d6b551e039c71f24cbb3 Author: Nobuo Iwata <nobuo.iwata@fujixerox.co.jp> Date: Thu Mar 24 10:50:59 2016 +0900 usbip: event handler as one thread Dear all, 1. Overview In current USB/IP implementation, event kernel threads are created for each port. The functions of the threads are closing connection and error handling so they don't have not so many events to handle. There's no need to have thread for each port. BEFORE) vhci side - VHCI_NPORTS(8) threads are created. $ ps aux | grep usbip root 10059 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10060 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10061 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10062 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10063 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10064 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10065 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] root 10066 0.0 0.0 0 0 ? S 17:06 0:00 [usbip_eh] BEFORE) stub side - threads will be created every bind operation. $ ps aux | grep usbip root 8368 0.0 0.0 0 0 ? S 17:56 0:00 [usbip_eh] root 8399 0.0 0.0 0 0 ? S 17:56 0:00 [usbip_eh] This patch put event threads of stub and vhci driver as one workqueue. AFTER) only one event threads in each vhci and stub side. $ ps aux | grep usbip root 10457 0.0 0.0 0 0 ? S< 17:47 0:00 [usbip_event] 2. Modification to usbip_event.c BEFORE) kernel threads are created in usbip_start_eh(). AFTER) one workqueue is created in new usbip_init_eh(). Event handler which was main loop of kernel thread is modified to workqueue handler. Events themselves are stored in struct usbip_device - same as before. usbip_devices which have event are listed in event_list. The handler picks an element from the list and wakeup usbip_device. The wakeup method is same as before. usbip_in_eh() substitutes statement which checks whether functions are called from eh_ops or not. In this function, the worker context is used for the checking. The context will be set in a variable in the beginning of first event handling. usbip_in_eh() is used in event handler so it works well. 3. Modifications to programs using usbip_event.c Initialization and termination of workqueue are added to init and exit routine of usbip_core respectively. A. version info v2) # Merged 1/2 event handler itself and 2/2 user programs because of auto build fail at 1/2 casued unmodified user programs in 1/2. Signed-off-by: Nobuo Iwata <nobuo.iwata@fujixerox.co.jp> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/usbip/stub_dev.c | 3 +- drivers/usb/usbip/usbip_common.c | 7 ++ drivers/usb/usbip/usbip_common.h | 4 +- drivers/usb/usbip/usbip_event.c | 168 +++++++++++++++++++++++++++++---------- 4 files changed, 137 insertions(+), 45 deletions(-) commit e352506e8a871890278ba66a2d77167193ffbfa9 Author: Alexey Khoroshilov <khoroshilov@ispras.ru> Date: Sat Mar 26 22:42:17 2016 +0300 USB: whci-hcd: add more checks for dma mapping error Fixing checks for dma mapping error in qset_fill_page_list(), I have missed two similar problems in qset_add_urb_sg() and in qset_add_urb_sg_linearize(). v2: check validity of dma_addr with dma_mapping_error() in qset_free_std() as suggested by Vladimir Zapolskiy. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Reviewed-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/whci/qset.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit d4fc8bf59746b6ef9bdbec42a608b89d0221b7df Author: Rajesh Bhagat <rajesh.bhagat@nxp.com> Date: Fri Mar 11 10:27:49 2016 +0530 xhci: fix typo in babble endpoint handling comment The 0.95 xHCI spec says that non-control endpoints will be halted if a babble is detected on a transfer. The 0.96 xHCI spec says all types of endpoints will be halted when a babble is detected. Some hardware that claims to be 0.95 compliant halts the control endpoint anyway. Reference: http://www.spinics.net/lists/linux-usb/msg21755.html Signed-off-by: Rajesh Bhagat <rajesh.bhagat@nxp.com> Reviewed-by: Felipe Balbi <balbi@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/usb/host/xhci-ring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 351e67ab5c0582e833c8d67dccb034348879cf25 Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 10 16:09:10 2016 +0100 USB: PD: additional feature selectors This adds the feature selectors from Table 9-8 Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/uapi/linux/usb/ch9.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit e1669f4a425c92c186e33a101e8fa84195fa2744 Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 10 16:09:09 2016 +0100 USB: PD: define specific requests This takes the definitions of requests from chapter 9.3.1 of the USB Power Delivery spec. Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/uapi/linux/usb/ch9.h | 7 +++++++ 1 file changed, 7 insertions(+) commit e10f9a42e9e822a8439dd4aaaccfd22365ee3975 Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 10 16:09:08 2016 +0100 USB: add descriptors from USB Power Delivery spec Adding the descriptors of chapter 9.2 of the Power Delivery spec. Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> include/uapi/linux/usb/ch9.h | 98 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) commit 5614e7725856ea383f458377980298111439e0fb Merge: 5225663 c3b46c7 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue Apr 19 04:28:28 2016 +0900 Merge 4.6-rc4 into driver-core-next We want those fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit 7553c7e68fd144643e74a279ef51b74a15214071 Merge: 423de92 c3b46c7 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Tue Apr 19 04:24:16 2016 +0900 Merge 4.6-rc4 into char-misc-next We want the fixes in there to build off of for other dependant patches. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit e7600449bef0650ee7818be6de26955e81579d13 Author: Govindarajulu Varadarajan <_govind@gmx.com> Date: Sat Apr 16 00:40:43 2016 +0530 enic: set netdev->vlan_features Driver sets vlan_feature to netdev->features as hardware supports all of them on vlan interface. Signed-off-by: Govindarajulu Varadarajan <_govind@gmx.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cisco/enic/enic_main.c | 1 + 1 file changed, 1 insertion(+) commit 84bf9cefb162b197da20a0f4388929f4b5ba5db4 Author: KY Srinivasan <kys@microsoft.com> Date: Thu Apr 14 16:31:54 2016 -0700 hv_netvsc: Implement support for VF drivers on Hyper-V Support VF drivers on Hyper-V. On Hyper-V, each VF instance presented to the guest has an associated synthetic interface that shares the MAC address with the VF instance. Typically these are bonded together to support live migration. By default, the host delivers all the incoming packets on the synthetic interface. Once the VF is up, we need to explicitly switch the data path on the host to divert traffic onto the VF interface. Even after switching the data path, broadcast and multicast packets are always delivered on the synthetic interface and these will have to be injected back onto the VF interface (if VF is up). This patch implements the necessary support in netvsc to support Linux VF drivers. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/hyperv/hyperv_net.h | 14 ++ drivers/net/hyperv/netvsc.c | 29 ++++ drivers/net/hyperv/netvsc_drv.c | 312 ++++++++++++++++++++++++++++++++++---- drivers/net/hyperv/rndis_filter.c | 6 + 4 files changed, 335 insertions(+), 26 deletions(-) commit 52e36c4da4d863d020df1e989514819349fd73f8 Merge: 2a2bbf1 54846f5 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 18 14:45:09 2016 -0400 Merge branch 'fec-ksettings' Philippe Reynes says: ==================== fec: ethtool: move to new api {get|set}_link_ksettings Ethtool has a new api {get|set}_link_ksettings that deprecate the old api {get|set}_settings. We update the fec driver to use this new ethtool api. For this first version, I've converted old u32 value in phy structure to link_modes structure. Another way would be to replace u32 in phy structure to use DECLARE_LINK_MODE_MASK for advertising, .... ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 54846f5838d871ad69ebe6eb1999cae3867dabc7 Author: Philippe Reynes <tremyfr@gmail.com> Date: Fri Apr 15 00:35:01 2016 +0200 fec: move to new ethtool api {get|set}_link_ksettings The ethtool api {get|set}_settings is deprecated. We move the fec driver to new api {get|set}_link_ksettings. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Acked-by: Fugang Duan <fugang.duan@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/freescale/fec_main.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 2d55173e71b06c5a369489852d972304e14189fd Author: Philippe Reynes <tremyfr@gmail.com> Date: Fri Apr 15 00:35:00 2016 +0200 phy: add generic function to support ksetting support The old ethtool api (get_setting and set_setting) has generic phy functions phy_ethtool_sset and phy_ethtool_gset. To supprt the new ethtool api (get_link_ksettings and set_link_ksettings), we add generic phy function phy_ethtool_ksettings_get and phy_ethtool_ksettings_set. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/phy.c | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/phy.h | 4 +++ 2 files changed, 85 insertions(+) commit 6d62b4d5fac620ee0ca65dc6d99b0306d96bc541 Author: Philippe Reynes <tremyfr@gmail.com> Date: Fri Apr 15 00:34:59 2016 +0200 net: ethtool: export conversion function between u32 and link mode The function convert_legacy_u32_to_link_mode and convert_link_mode_to_legacy_u32 may be used outside of ethtool.c. We rename them to ethtool_convert_... and export them, so we could use them in others drivers and modules. Signed-off-by: Philippe Reynes <tremyfr@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/ethtool.h | 7 +++++++ net/core/ethtool.c | 21 ++++++++++++--------- 2 files changed, 19 insertions(+), 9 deletions(-) commit adff6c65600000ec2bb71840c943ee12668080f5 Author: Florian Westphal <fw@strlen.de> Date: Tue Apr 12 18:14:25 2016 +0200 netfilter: connlabels: change nf_connlabels_get bit arg to 'highest used' nf_connlabel_set() takes the bit number that we would like to set. nf_connlabels_get() however took the number of bits that we want to support. So e.g. nf_connlabels_get(32) support bits 0 to 31, but not 32. This changes nf_connlabels_get() to take the highest bit that we want to set. Callers then don't have to cope with a potential integer wrap when using nf_connlabels_get(bit + 1) anymore. Current callers are fine, this change is only to make folloup nft ct label set support simpler. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_labels.h | 4 ++-- net/netfilter/nf_conntrack_labels.c | 9 +++++---- net/netfilter/nft_ct.c | 2 ++ net/netfilter/xt_connlabel.c | 2 +- net/openvswitch/conntrack.c | 2 +- 5 files changed, 11 insertions(+), 8 deletions(-) commit 5a8145f7b22269adaf9e98b160a20486d1ad5669 Author: Florian Westphal <fw@strlen.de> Date: Tue Apr 12 18:14:24 2016 +0200 netfilter: labels: don't emit ct event if labels were not changed make the replace function only send a ctnetlink event if the contents of the new set is different. Otherwise 'ct label set ct label | bar' will cause netlink event storm since we "replace" labels for each packet. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_labels.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit b4ef159927150bf1d63f36330bbb5239516ceb69 Author: Florian Westphal <fw@strlen.de> Date: Tue Apr 12 18:14:23 2016 +0200 netfilter: connlabels: move helpers to xt_connlabel Currently labels can only be set either by iptables connlabel match or via ctnetlink. Before adding nftables set support, clean up the clabel core and move helpers that nft will not need after all to the xtables module. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_labels.h | 1 - net/netfilter/nf_conntrack_labels.c | 19 +------------------ net/netfilter/xt_connlabel.c | 12 +++++++++++- 3 files changed, 12 insertions(+), 20 deletions(-) commit 2a2bbf170054e2525f11e08bb36d4027d76b7bff Author: Paolo Abeni <pabeni@redhat.com> Date: Thu Apr 14 18:39:39 2016 +0200 tun: don't require serialization lock on tx The current tun_net_xmit() implementation don't need any external lock since it relies on rcu protection for the tun data structure and on socket queue lock for skb queuing. This patch set the NETIF_F_LLTX feature bit in the tun device, so that on xmit, in absence of qdisc, no serialization lock is acquired by the caller. The user space can remove the default tun qdisc with: tc qdisc replace dev <tun device name> root noqueue Signed-off-by: Paolo Abeni <pabeni@redhat.com> Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 110361f41c17d1f565e2fd03a0af044c29e6513a Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Apr 18 11:44:49 2016 +0300 udp: fix if statement in SIOCINQ ioctl We deleted a line of code and accidentally made the "return put_user()" part of the if statement when it's supposed to be unconditional. Fixes: 9f9a45beaa96 ('udp: do not expect udp headers on ioctl SIOCINQ') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Eric Dumazet <edumazet@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/udp.c | 6 ------ 1 file changed, 6 deletions(-) commit 2c30322c4795bf26a74b6049bbea6267a19036a4 Author: Askar Safin <safinaskar@mail.ru> Date: Mon Apr 18 20:30:56 2016 +0300 documentation: trivial typo: adding-syscalls.txt: s/statat/fstatat/ Signed-off-by: Askar Safin <safinaskar@mail.ru> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/adding-syscalls.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5f304c87363401eb85cae304d025e93267353d3a Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 15 22:32:58 2016 +0300 drm/i915/kbl: Reset secondary power well requests left on by DMC/KVMR The workaround added in commit c6782b76d31a ("drm/i915/gen9: Reset secondary power well requests left on by DMC/KVMR") needs to be applied on Kabylake too as shown by the corresponding timeout errors about power well 1 and MISC IO power well disabling in the latest CI run. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460748778-4484-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 07c5c3ad98926dc15d31aa86de62fd4170f2a745 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 18 14:49:53 2016 +0300 regulator: core: remove lockdep assert from suspend_prepare suspend_prepare can be called during regulator init time also, where the mutex is not locked yet. This causes a false lockdep warning. To avoid the problem, remove the lockdep assertion from the function causing the issue. An alternative would be to lock the mutex during init, but this would cause other problems (some APIs used during init will attempt to lock the mutex also, causing deadlock.) Signed-off-by: Tero Kristo <t-kristo@ti.com> Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 2 -- 1 file changed, 2 deletions(-) commit 09184118a8abae030539469848d475adcc0e5839 Author: Jyri Sarha <jsarha@ti.com> Date: Thu Mar 31 16:36:00 2016 +0300 ASoC: hdmi-codec: Add hdmi-codec for external HDMI-encoders The hdmi-codec is a platform device driver to be registered from drivers of external HDMI encoders with I2S and/or spdif interface. The driver in turn registers an ASoC codec for the HDMI encoder's audio functionality. The structures and definitions in the API header are mostly redundant copies of similar structures in ASoC headers. This is on purpose to avoid direct dependencies to ASoC structures in video side driver. Signed-off-by: Jyri Sarha <jsarha@ti.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Acked-by: PC Liao <pc.liao@mediatek.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/hdmi-codec.h | 100 +++++++++++ sound/soc/codecs/Kconfig | 6 + sound/soc/codecs/Makefile | 2 + sound/soc/codecs/hdmi-codec.c | 396 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 504 insertions(+) commit 99cf3af5e2d5c74e016ae9517a4dced3f1dbcf6a Author: James Ban <James.Ban.opensource@diasemi.com> Date: Fri Apr 15 13:34:22 2016 +0900 regulator: pv88080: new regulator driver This is the driver for the Powerventure PV88080 BUCKs regulator. It communicates via an I2C bus to the device. Signed-off-by: James Ban <James.Ban..opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/regulator/pv88080.txt | 49 +++ drivers/regulator/Kconfig | 7 + drivers/regulator/Makefile | 1 + drivers/regulator/pv88080-regulator.c | 419 +++++++++++++++++++++ drivers/regulator/pv88080-regulator.h | 92 +++++ 5 files changed, 568 insertions(+) commit 3270ac230f660843a7f7d631746ee2c8ee63f347 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Apr 15 16:57:19 2016 +0530 spi: pic32-sqi: add SPI driver for PIC32 SQI controller. This driver implements SPI master interface for Quad SPI controller, specifically for accessing quad SPI flash. It uses descriptor-based DMA transfer mode and supports half-duplex communication for single, dual and quad SPI transactions. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Cc: Mark Brown <broonie@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 6 + drivers/spi/Makefile | 1 + drivers/spi/spi-pic32-sqi.c | 768 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 775 insertions(+) commit 0a4afaae989c47fd93b73cc83d2c4a46b55aa1b7 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Apr 15 16:57:18 2016 +0530 spi: pic32-sqi: add binding document for PIC32 Quad-SPI driver. Document Device tree bindings for the quad SPI peripheral found on Microchip PIC32 class devices. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <rob@kernel.org> Cc: Kumar Gala <galak@codeaurora.org> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk> Cc: Rob Herring <robh+dt@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Mark Brown <broonie@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/spi/sqi-pic32.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 550bce59baf3f3059cd4ae1e268f08f2d2cb1d5c Author: Roopa Prabhu <roopa@cumulusnetworks.com> Date: Fri Apr 15 20:36:25 2016 -0700 rtnetlink: rtnl_fill_stats: avoid an unnecssary stats copy This patch passes netlink attr data ptr directly to dev_get_stats thus elimiating a stats copy. Suggested-by: David Miller <davem@davemloft.net> Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/rtnetlink.c | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) commit 5f9a50c3e55ee887b7a0ccb68045b92579972b55 Author: Petr Kulhavy <petr@barix.com> Date: Mon Apr 18 14:32:41 2016 +0200 ASoC: Davinci: McBSP: add device tree support for McBSP This adds DT support for the TI DA8xx/OMAP-L1x/AM17xx/AM18xx McBSP driver. Signed-off-by: Petr Kulhavy <petr@barix.com> Reviewed-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/davinci/Kconfig | 6 +++- sound/soc/davinci/davinci-i2s.c | 80 +++++++++++++++++++++++++++-------------- 2 files changed, 59 insertions(+), 27 deletions(-) commit 22225835e23f7a768e767967004d2f3751c64be5 Author: Petr Kulhavy <petr@barix.com> Date: Mon Apr 18 14:32:40 2016 +0200 ASoC: davinci-mcbsp: add binding for McBSP Add devicetree binding for the TI DA850/OMAP-L138/AM18xx MultiChannel Buffered Serial Port (McBSP) The optional register range "dat" is not implemented at the moment. The current driver supports only DMA into RX/TX registers but no FIFO. Once the FIFO is implemented in the driver the "dat" range will be used. Signed-off-by: Petr Kulhavy <petr@barix.com> Reviewed-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/davinci-mcbsp.txt | 51 ++++++++++++++++++++++ 1 file changed, 51 insertions(+) commit 94be46b9e5e2954b6d5962750f8aae8b5f099baa Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 18 15:33:10 2016 +0200 regulator: s2mps11: Set default ramp delay for S2MPS11 LDOs Driver did not provide default value for ramp delay for LDOs which lead to warning in dmesg, e.g. on Odroid XU4: [ 1.486076] vdd_ldo9: ramp_delay not set [ 1.506875] vddq_mmc2: ramp_delay not set [ 1.523766] vdd_ldo15: ramp_delay not set [ 1.544702] vdd_sd: ramp_delay not set The datasheet for all the S2MPS1x family is inconsistent here and does not specify unambiguously the value of ramp delay for LDO. It mentions 30 mV/us in one timing diagram but then omits it completely in LDO regulator characteristics table (it is specified for bucks). However the vendor kernels for Galaxy S5 and Odroid XU3 use values of 12 mV/us or 24 mV/us. Without the ramp delay value the consumers do not wait for voltage settle after changing it. Although the proper value of ramp delay for LDOs is unknown, it seems safer to use at least some value from reference kernel than to leave it unset. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/s2mps11.c | 1 + include/linux/mfd/samsung/core.h | 3 +++ 2 files changed, 4 insertions(+) commit 8a8dae260f5df805fe062875fef272ffccaf727f Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 14:29:32 2016 +0300 drm/i915: Replace nondescript 'WARN_ON(!lret)' with a sensible error message When a vblank wait times out in intel_atomic_wait_for_vblanks() we just get a cryptic 'WARN_ON(!ret)' backtrace in dmesg. Repace it with something that tells you what actually happened. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460978973-24945-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e3815264a6c57147f8b5639536b1df3c98244642 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 12:30:16 2016 -0300 perf top: Use callchain_param.enabled instead of symbol_conf.use_callchain One more step in the direction of using just callchain_param for callchain parameters. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-3b1o9kb2dc94zldz0klckti6@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-top.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 1b6b678ecfb73724914a8b12d57909a4c514a9bd Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 12:24:41 2016 -0300 perf hists browser: Fold two consecutive symbol_conf.use_callchain ifs Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-u701i6qpecgm9jiat52i8l98@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/ui/browsers/hists.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 2ddd5c049e71dd8551c268e7386fefeb7495e988 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 12:09:08 2016 -0300 perf tools: Ditch record_opts.callgraph_set We have callchain_param.enabled for that. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-silwqjc2t25ls42dsvg28pp5@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 14 ++++++-------- tools/perf/builtin-top.c | 13 ++++++------- tools/perf/builtin-trace.c | 8 ++++---- tools/perf/perf.h | 1 - 4 files changed, 16 insertions(+), 20 deletions(-) commit 1cc83815d5fdb40a7d06c3f9871134a10e5ffa79 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 11:54:31 2016 -0300 perf report: Use callchain_param.enabled instead of tool specific knob We have callchain_param.enabled, so no need to have something just for 'perf report' to do the same thing. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-wbeisubpualwogwi5u8utnt1@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-report.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 30234f0925c1deeb472b579b57a9f50791157c58 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 11:53:07 2016 -0300 perf callchain: Set callchain_param.enabled when parsing --call-graph Trying to move in the direction of using callchain_param for all callchain parameters, eventually ditching them from symbol_conf. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-kixllia6r26mz45ng056zq7z@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/callchain.c | 2 ++ 1 file changed, 2 insertions(+) commit 922315210b8007a26374e30712813b714af71cac Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 11:31:46 2016 -0300 perf script: Check sample->callchain before using it Found by code inspection, while looking at thread__resolve_callchain() callsites, one had it, the other didn't. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-6r8i2afd3523thuuaxl39yhk@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit acf2abbd0b7fcc6325e9690a8a32ee924c827f70 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 18 10:35:03 2016 -0300 perf evsel: Add missign class prefix to has_branch_stack method Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-5i07ivw1yjsweb7gztr255jd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.h | 2 +- tools/perf/util/machine.c | 2 +- tools/perf/util/session.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) commit dc5a533f91305f91645513abde2da52026385a04 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 12:01:32 2016 +0200 serial: mctrl_gpio: Grammar s/lines GPIOs/line GPIOs/, /sets/set/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/tty/serial/serial_mctrl_gpio.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a7b221d8f0d75511c5f959584712a5dd35f88a86 Author: Rafał Miłecki <zajec5@gmail.com> Date: Mon Apr 18 14:39:30 2016 +0200 spi: bcm53xx: add spi_flash_read callback for MMIO-based reads This implements more efficient reads of SPI-attached flash content. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-bcm53xx.c | 78 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 76 insertions(+), 2 deletions(-) commit 8d4d0d700dda04c5095a08e91f59f537995aa024 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 18 14:29:33 2016 +0300 drm/atomic-helper: Print an error if vblank wait times out Vblank waits timing out is no a normal thing to happen, so let's inform people when it happens. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460978973-24945-2-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/drm_atomic_helper.c | 2 ++ 1 file changed, 2 insertions(+) commit 8ac2266d88318d348fa5f1dad5b525e0d2c665ef Author: Pavel Fedin <p.fedin@samsung.com> Date: Mon Apr 11 13:12:27 2016 +0530 memory: samsung: exynos-srom: Add support for bank configuration Implement handling properties in subnodes and adding child devices to the system. Child devices will not be added if configuration fails. Since the driver now does more than suspend-resume support, dependency on CONFIG_PM is removed. Signed-off-by: Pavel Fedin <p.fedin@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/mach-exynos/Kconfig | 2 +- drivers/memory/samsung/Kconfig | 2 +- drivers/memory/samsung/exynos-srom.c | 60 ++++++++++++++++++++++++++++++++++-- 3 files changed, 60 insertions(+), 4 deletions(-) commit 5901f4c279f7ddbd32041ce1166387ffa05b902d Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Mon Apr 11 13:12:26 2016 +0530 ARM: EXYNOS: Remove SROM related register settings from mach-exynos As now we have dedicated driver for SROM controller, it will take care of saving register banks during S2R so we can safely remove these settings from mach-exynos. Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kukjin Kim <kgene@kernel.org> [k.kozlowski: Need to select also SAMSUNG_MC] Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/mach-exynos/Kconfig | 3 ++ arch/arm/mach-exynos/exynos.c | 17 --------- arch/arm/mach-exynos/include/mach/map.h | 3 -- arch/arm/mach-exynos/regs-srom.h | 53 ---------------------------- arch/arm/mach-exynos/suspend.c | 20 ++--------- arch/arm/plat-samsung/include/plat/map-s5p.h | 1 - 6 files changed, 5 insertions(+), 92 deletions(-) commit ffd51977beb3909c4626bab41cc5f405b308fcb2 Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Mon Apr 11 13:12:25 2016 +0530 MAINTAINERS: Add maintainers entry for drivers/memory/samsung Add maintainers entry for new driver folder drivers/memory/samsung. Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit a8aabb91dc5bef0875d93d6a86d01779947604e1 Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Mon Apr 11 13:12:24 2016 +0530 memory: Add support for Exynos SROM driver This patch adds Exynos SROM controller driver which will handle save restore of SROM registers during S2R. Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [p.fedin@samsung.com: tested on SMDK5410] Tested-by: Pavel Fedin <p.fedin@samsung.com> Signed-off-by: Kukjin Kim <kgene@kernel.org> [k.kozlowski: Minor COMPILE_TEST adjustments in Kconfig entries] Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> drivers/memory/Kconfig | 1 + drivers/memory/Makefile | 1 + drivers/memory/samsung/Kconfig | 13 +++ drivers/memory/samsung/Makefile | 1 + drivers/memory/samsung/exynos-srom.c | 175 +++++++++++++++++++++++++++++++++++ drivers/memory/samsung/exynos-srom.h | 51 ++++++++++ 6 files changed, 242 insertions(+) commit 92537d65d58ede86d752d1390cf3b51480ab0179 Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Mon Apr 11 13:12:23 2016 +0530 dt-bindings: EXYNOS: Add exynos-srom device tree binding This patch adds exynos-srom binding information for SROM Controller driver on Exynos SoCs. Documentation for new subnode properties, allowing bank configuration are added based on u-boot implementation, but heavily reworked. CC: Rob Herring <robh+dt@kernel.org> CC: Mark Rutland <mark.rutland@arm.com> CC: Ian Campbell <ijc+devicetree@hellion.org.uk> Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> [p.fedin: Added SROMc configuration description and fixed SROMc mapping] Signed-off-by: Pavel Fedin <p.fedin@samsung.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kukjin Kim <kgene@kernel.org> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../bindings/memory-controllers/exynos-srom.txt | 79 ++++++++++++++++++++++ 1 file changed, 79 insertions(+) commit 3ba9adf019b6a43a6f0327e3c6c6c90a41f8695f Merge: f55532a 4d7820b Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 18 14:25:11 2016 +0200 Merge tag 'samsung-dt-exynos-srom-fixup-4.7' into for-v4.7/drivers-memory-exynos-srom DeviceTree changes for new SROM controller driver reached mainline some time ago, before the driver was accepted (due to very late comments). However, after these late comments, the driver expects different bindings so we need to fix the DTS. commit c28f82595dde97dda0b769f78f0faea78acd993b Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 12:42:15 2016 +0300 usb: dwc3: switch trb enqueue/dequeue and first_trb_index to u8 We *know* that we have 1 PAGE (4096 bytes) for our TRB poll. We also know the size of each TRB and know that we can fit 256 of them in one PAGE. By using a u8 type we can make sure that: enqueue++ % 256; gets optimized to an increment only. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 5ef68c56e169a9249b94645a9ea9ca8d14672d26 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Apr 5 11:33:30 2016 +0300 usb: dwc3: core: document struct dwc3_request No functional changes. Merely adding useful documentation for future readers. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 53fd88189e08c91cb9b43e2d51b4eb314a3d00d7 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 4 15:33:41 2016 +0300 usb: dwc3: gadget: rename busy/free_slot to trb_enqueue/dequeue This makes it clear that we're dealing with a queue of TRBs. No functional changes. While at that, also rename start_slot to first_trb_index for similar reasons. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 10 +++++----- drivers/usb/dwc3/ep0.c | 6 +++--- drivers/usb/dwc3/gadget.c | 30 +++++++++++++++--------------- 3 files changed, 23 insertions(+), 23 deletions(-) commit 495dd5f78145c44274eeb8ec297195ac71a8fed0 Author: Grygorii Strashko <grygorii.strashko@ti.com> Date: Tue Apr 5 15:09:44 2016 +0300 usb: dwc3: omap: drop dma_mask configuration The DWC3 OMAP driver supports DT-boot only, as result dma_mask will be always configured properly from DT - of_platform_device_create_pdata()->of_dma_configure(). More over, dwc3-omap.c can be built as module and in this case it's unsafe to assign local variable as dma_mask. Hence, remove dma_mask configuration code. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/dwc3-omap.c | 3 --- 1 file changed, 3 deletions(-) commit e58dd357741b93f5bc5487aabba968c76bb099ef Author: Rajesh Bhagat <rajesh.bhagat@nxp.com> Date: Mon Mar 14 14:40:50 2016 +0530 usb: dwc3: add disable receiver detection in P3 quirk Some freescale QorIQ platforms require to disable receiver detection in P3 for correct detection of USB devices. If GUSB3PIPECTL(DISRXDETINP3) is set, Core will change PHY power state to P2 and then perform receiver detection. After receiver detection, Core will change PHY power state to P3. Same quirk would be added in dts file in future patches. Signed-off-by: Sriram Dash <sriram.dash@nxp.com> Signed-off-by: Rajesh Bhagat <rajesh.bhagat@nxp.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.c | 6 ++++++ drivers/usb/dwc3/core.h | 2 ++ drivers/usb/dwc3/platform_data.h | 1 + 3 files changed, 9 insertions(+) commit 2c0b98ff29a7452edbbdc503857b74cfaa536808 Author: Rajesh Bhagat <rajesh.bhagat@nxp.com> Date: Mon Mar 14 14:40:51 2016 +0530 Documentation: dt: dwc3: Add snps,dis_rxdet_inp3_quirk property Add snps,dis_rxdet_inp3_quirk property which disables receiver detection in PHY P3 power state. Signed-off-by: Sriram Dash <sriram.dash@nxp.com> Signed-off-by: Rajesh Bhagat <rajesh.bhagat@nxp.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Documentation/devicetree/bindings/usb/dwc3.txt | 2 ++ 1 file changed, 2 insertions(+) commit c36d8e947a56a6e6478fc48152c5f4626462db55 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 4 12:46:33 2016 +0300 usb: dwc3: gadget: put link to U0 before Start Transfer Synopsys Databook says we should move link to U0 before issuing a Start Transfer command. We could require the gadget driver to call usb_gadget_wakeup() however I feel that changing all gadget drivers to keep track of Link State and conditionally call usb_gadget_wakeup() would be far too much work. For now we will handle this at the UDC level, but at some point composite.c should be one handling this. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 218ef7b647e3367c9f81e18f63fbb0066f10b9a5 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 4 11:24:04 2016 +0300 usb: dwc3: gadget: extract unlocked dwc3_gadget_wakeup() we will need this from StartTransfer to make sure link is in U0 before starting a transfer. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) commit 2b0f11df84bb66c9ac71395382c018f33c3ff9a4 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 4 09:19:17 2016 +0300 usb: dwc3: gadget: clear SUSPHY bit before ep cmds Synopsys Databook 2.60a has a note that if we're sending an endpoint command we _must_ make sure that DWC3_GUSB2PHY(n).SUSPHY bit is cleared. This patch implements that particular detail. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit c0ca324d09a041ab56be1aaeb5a7cc64c47f877b Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Apr 4 09:11:51 2016 +0300 usb: dwc3: gadget: combine return points into a single one dwc3_send_gadget_ep_cmd() had three return points. That becomes a pain to track when we need to debug something or if we need to add more code before returning. Let's combine all three return points into a single one just by introducing a local 'ret' variable. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit e4875bd4829c1a945bc4714ca806a823a169f3a1 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:55:38 2016 +0200 usb: gadget: pch_udc: sort IDs Sort IDs in groups to be easily found when needed. There is no functional change. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6b968737c3efe7cdaa5407afec972cd7c7d3ca35 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:55:37 2016 +0200 usb: gadged: pch_udc: get rid of redundant assignments It seems there are leftovers of some assignments which are not used anymore. Compiler even warns us about: drivers/usb/gadget/udc/pch_udc.c:2022:22: warning: variable ‘dev’ set \ but not used [-Wunused-but-set-variable] drivers/usb/gadget/udc/pch_udc.c:2639:9: warning: variable ‘ret’ set \ but not used [-Wunused-but-set-variable] Remove them and shut compiler about. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) commit c7b640d2a21c2dd724cd8aa9f0b78d6a3d61d776 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:55:36 2016 +0200 usb: gadget: pch_udc: enable MSI if hardware supports Try to enable MSI in case hardware supports it. At least Intel Quark is known SoC which indeed does. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 2 ++ 1 file changed, 2 insertions(+) commit 969733f3768528ce7fb435e90adcb5f7984316ec Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:55:35 2016 +0200 usb: gadget: pch_udc: convert to devres API devres API allows to make error paths cleaner and less error prone. Convert the driver to use it. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 98 +++++++++++----------------------------- 1 file changed, 26 insertions(+), 72 deletions(-) commit 5e3bd45f170b43cec3fb85f14ef94f176235c4af Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:55:34 2016 +0200 usb: gadged: pch_udc: PCI core handles power state for us There is no need to repeat the work that is already done in the PCI driver core. The patch removes excerpts from suspend and resume callbacks. Note that there is no more calls performed to enable or disable a PCI device during suspend-resume cycle. Nowadays they seems to be superfluous. Someone can read more in [1]. While here, convert PM ops to use modern API. [1] https://www.kernel.org/doc/ols/2009/ols2009-pages-319-330.pdf Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> [felipe.balbi@linux.intel.com: fixed build break and checkpatch error ] Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/pch_udc.c | 39 ++++++++++++--------------------------- 1 file changed, 12 insertions(+), 27 deletions(-) commit badf6d47f8a93098c6e05fdeb735b44b61877451 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Mar 23 17:45:08 2016 +0100 usb: common: rework CONFIG_USB_COMMON logic The phy-am335x driver selects 'USB_COMMON', but all other drivers use 'depends on' for that symbol, and it depends on USB || USB_GADGET itself, which causes a Kconfig warning: warning: (AM335X_PHY_USB) selects USB_COMMON which has unmet direct dependencies (USB_SUPPORT && (USB || USB_GADGET)) As suggested by Felipe Balbi, this turns the logic around, and makes 'USB_COMMON' selected by everything else that needs it, so we can remove the dependencies. Fixes: 59f042f644c5 ("usb: phy: phy-am335x: bypass first VBUS sensing for host-only mode") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Felipe Balbi <balbi@kernel.org> Reviewed-by: Peter Chen <peter.chen@nxp.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/phy/Kconfig | 3 ++- drivers/usb/Kconfig | 3 +-- drivers/usb/gadget/Kconfig | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) commit dea520a4a28307034b1842adbfde947e1ed385d2 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Wed Mar 30 09:39:34 2016 +0300 usb: dwc3: gadget: pass ev_buff as cookie to irq handler we don't plan on using multiple event buffers, but if we find a good use case for it, this little trick will help us avoid a loop in hardirq handler looping for each and every event buffer. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-) commit 4d7820b0465a78e6c85a74474b89fb4ab84768ba Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Mon Apr 11 13:12:28 2016 +0530 ARM: dts: change SROM node compatible from generic to model specific This patch changes SROM nodes compatible from generic to model specific to match with binding documentation. Also updating property "samsung,srom-page-mode" as it is not defined as bool instead of int Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4.dtsi | 4 ++-- arch/arm/boot/dts/exynos5.dtsi | 4 ++-- arch/arm/boot/dts/exynos5410-smdk5410.dts | 2 +- arch/arm/boot/dts/exynos5410.dtsi | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) commit 327819d1e52434de869aab2ee5183682357d8e6d Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Apr 18 13:30:29 2016 +0200 gpio: f7188x: fix edit mistake Fix a typo causing a build regression. Fixes: f90c6bdb690b ("gpio: f7188x: use the new open drain callback") Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-f7188x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a4362fd6da7ab8b08028734004df486847ea593e Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Sun Apr 17 22:51:46 2016 +0200 HID: thingm: set new flag LED_HW_PLUGGABLE Use recently introduced flag LED_HW_PLUGGABLE to avoid warnings when the device is unplugged. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-thingm.c | 1 + 1 file changed, 1 insertion(+) commit 91540ccc9c4554c8bbb8b8a1be0b255a378b6475 Author: Heiner Kallweit <hkallweit1@gmail.com> Date: Sun Apr 17 22:46:59 2016 +0200 HID: thingm: factor out duplicated code to thingm_init_led Simplify thingm_init_rgb by factoring out duplicated code to thingm_init_led. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-thingm.c | 43 +++++++++++++++---------------------------- 1 file changed, 15 insertions(+), 28 deletions(-) commit 0db71fec8560a7c58c04304fd2e10e9647a205d4 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:31:37 2016 +0100 w1: comment spelling s/minmum/minimum/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/w1/w1_io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bc2d52fe379b445b94cd7ce1de5a8ac4c13a9101 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:29:34 2016 +0100 Blackfin: comment spelling s/divsor/divisor/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/blackfin/lib/udivsi3.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b3ab30a7cbdaf7ba20dddeac252cc0238312fff0 Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 15 10:54:07 2016 -0700 crypto: qat - fix section mismatch warning Fix Section mismatch warinig in adf_exit_vf_wq() Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_vf_isr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 87ba569a398826733b14e77668c8d2630119b0ca Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 15 10:38:00 2016 -0700 crypto: qat - interrupts need to be enabled when VFs are disabled IRQs need to be enabled when VFs go down in case some VF to PF comms happens. Tested-by: Suman Bangalore Sathyanarayana <sumanx.bangalore.sathyanarayana@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 25c6ffb249f612c56a48ce48a3887adf57b8f4bd Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 15 10:37:59 2016 -0700 crypto: qat - check if PF is running Before VF sends a signal to PF it should check if PF is still running. Tested-by: Suman Bangalore Sathyanarayana <sumanx.bangalore.sathyanarayana@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_c3xxxvf/adf_drv.c | 2 ++ drivers/crypto/qat/qat_c62xvf/adf_drv.c | 2 ++ drivers/crypto/qat/qat_common/adf_common_drv.h | 2 +- drivers/crypto/qat/qat_common/adf_vf2pf_msg.c | 8 +++++--- drivers/crypto/qat/qat_common/adf_vf_isr.c | 2 ++ drivers/crypto/qat/qat_dh895xccvf/adf_drv.c | 2 ++ 6 files changed, 14 insertions(+), 4 deletions(-) commit 02dc8d634b4f175d92aa8b0b217eb0e4db1a0c3b Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Apr 15 10:37:58 2016 -0700 crypto: qat - move vf2pf_init and vf2pf_exit to common The vf2pf_init and vf2pf_exit are exactly the same for all VFs so move them to common and reuse. Tested-by: Suman Bangalore Sathyanarayana <sumanx.bangalore.sathyanarayana@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> .../crypto/qat/qat_c3xxxvf/adf_c3xxxvf_hw_data.c | 23 ------ drivers/crypto/qat/qat_c62xvf/adf_c62xvf_hw_data.c | 23 ------ drivers/crypto/qat/qat_common/Makefile | 2 +- drivers/crypto/qat/qat_common/adf_common_drv.h | 12 +++ drivers/crypto/qat/qat_common/adf_vf2pf_msg.c | 90 ++++++++++++++++++++++ .../qat/qat_dh895xccvf/adf_dh895xccvf_hw_data.c | 23 ------ 6 files changed, 103 insertions(+), 70 deletions(-) commit cacd2c41c2349760e834f018951960da84332b56 Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Fri Mar 4 11:20:54 2016 -0800 metag: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/metag/include/asm/metag_regs.h | 2 +- arch/metag/include/asm/tbx.h | 6 +++--- arch/metag/tbx/tbipcx.S | 2 +- arch/metag/tbx/tbisoft.S | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) commit 45b79a291fdd209cf40dfa40f91bf9e31f949b0d Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Wed Feb 24 10:50:29 2016 -0800 ia64: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/ia64/include/asm/sn/ioc3.h | 2 +- arch/ia64/include/asm/sn/shubio.h | 4 ++-- arch/ia64/kernel/efi.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit 238034e3fe3b0d75df0e4c7cbefb3df259ed628a Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Wed Feb 24 10:49:53 2016 -0800 hexagon: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/hexagon/include/asm/hexagon_vm.h | 2 +- arch/hexagon/include/asm/vm_mmu.h | 2 +- arch/hexagon/kernel/kgdb.c | 4 ++-- arch/hexagon/kernel/vm_ops.S | 2 +- arch/hexagon/lib/memcpy.S | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) commit bd1a0be5154788a052c6b851dbfa97bcd71f21d6 Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Wed Feb 24 10:02:25 2016 -0800 tools/perf: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> tools/perf/tests/openat-syscall-all-cpus.c | 2 +- tools/perf/util/evsel.c | 2 +- tools/perf/util/machine.c | 2 +- tools/perf/util/parse-events.c | 2 +- tools/perf/util/session.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) commit 014b38ec694ce3fd11cfedbdee75d1fdcb031839 Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Tue Feb 23 15:30:07 2016 -0800 cris: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/cris/arch-v10/drivers/axisflashmap.c | 2 +- arch/cris/arch-v32/drivers/axisflashmap.c | 2 +- arch/cris/arch-v32/drivers/cryptocop.c | 2 +- arch/cris/arch-v32/mach-a3/dram_init.S | 2 +- arch/cris/arch-v32/mach-fs/dram_init.S | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) commit 0398b95fe4b3c90fbabfb39b77e635ec863ac040 Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Tue Feb 23 15:28:52 2016 -0800 c6x: Fix misspellings in comments. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/c6x/include/asm/clock.h | 2 +- arch/c6x/platforms/cache.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit e0b1c817d85d1611b4f44f9c5b3e6426886206e0 Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Tue Feb 23 15:28:12 2016 -0800 blackfin: Fix misspelling of 'register' in comment. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/blackfin/mach-bf609/include/mach/defBF60x_base.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 133895e9f42afee8ed837cef7e308c97bc708b5b Author: Adam Buchbinder <adam.buchbinder@gmail.com> Date: Tue Feb 23 15:27:23 2016 -0800 avr32: Fix misspelling of 'definitions' in comment. Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/avr32/include/asm/addrspace.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8404410b296095c78ed63f163ac5d417ff0647dd Merge: 1050e68 85baa09 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Mon Apr 18 20:45:32 2016 +1000 Merge branch 'topic/livepatch' into next Merge the support for live patching on ppc64le using mprofile-kernel. This branch has also been merged into the livepatching tree for v4.7. commit acf4e84d6167317ff21be5c03e1ea76ea5783701 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sun Apr 17 20:42:46 2016 +0100 drm/i915: Avoid stalling on pending flips for legacy cursor updates The legacy cursor ioctl expects to be asynchronous with respect to other screen updates, in particular page flips. As X updates the cursor from a signal context, if the cursor blocks then it will stall both the input and output chains causing bad stuttering and horrible UX. Reported-and-tested-by: Rafael Ristovski <rafael.ristovski@gmail.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94980 Fixes: 5008e874edd34 ("drm/i915: Make wait_for_flips interruptible.") Suggested-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Jani Nikula <jani.nikula@intel.com> Cc: stable@vger.kernel.org Link: http://patchwork.freedesktop.org/patch/msgid/1460922166-20292-1-git-send-email-chris@chris-wilson.co.uk Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+) commit b1d21a24df458c897911af51cb637460c1ac5d95 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 10:44:37 2016 -0700 regulator: qcom_spmi: Always return a selector when asked I had a thinko in spmi_regulator_select_voltage_same_range() when converting it to return selectors via the function's return value instead of by modifying a pointer argument. I only tested multi-range regulators so this passed through testing. Fix it by returning the selector here. Fixes: 1b5b19689278 ("regulator: qcom_spmi: Only use selector based regulator ops") Reported-by: Rajendra Nayak <rnayak@codeaurora.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/qcom_spmi-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3ee15cac90e168fdea497a168a2e79acb1c4e612 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 14 15:29:35 2016 +0200 ASoC: sti: select player for I2S/TDM TX bus By default, player#0 is connected to I2S/TDM TX bus. This patch connects player#1 to I2S/TDM TX bus. Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/uniperif.h | 1 + sound/soc/sti/uniperif_player.c | 42 +++++++++++++++++++++++++++-------------- 2 files changed, 29 insertions(+), 14 deletions(-) commit 148b1eb93c9b54e61d7937b5a5760030276240ab Author: Arnd Bergmann <arnd@arndb.de> Date: Sat Apr 16 22:39:21 2016 +0200 spi: cadence: mark pm functions __maybe_unused The newly added runtime PM support for the cadence spi driver causes harmless warnings when PM is disabled: drivers/spi/spi-cadence.c:681:12: warning: 'cnds_runtime_suspend' defined but not used drivers/spi/spi-cadence.c:652:12: warning: 'cnds_runtime_resume' defined but not used This adds __maybe_unused annotations to the respective functions to shut up the warnings, while leaving the code in place for compile testing and avoiding ugly #ifdefs. Fixes: d36ccd9f7ea4 ("spi: cadence: Runtime pm adaptation") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c19ca6cb4c0891049009d48a0da79d9e8c475462 Author: Masanari Iida <standby24x7@gmail.com> Date: Mon Feb 8 20:53:12 2016 +0900 treewide: Fix typos in printk This patch fix spelling typos found in printk within various part of the kernel sources. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/x86/kernel/cpu/microcode/intel.c | 2 +- arch/x86/kvm/iommu.c | 2 +- block/partitions/efi.c | 4 ++-- drivers/edac/amd64_edac.c | 2 +- drivers/mtd/sm_ftl.c | 2 +- drivers/net/ethernet/mellanox/mlx5/core/sriov.c | 2 +- drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c | 4 ++-- drivers/scsi/aic94xx/aic94xx_hwi.c | 2 +- drivers/scsi/aic94xx/aic94xx_seq.c | 2 +- drivers/scsi/isci/port.c | 2 +- fs/exofs/super.c | 2 +- net/tipc/socket.c | 2 +- 12 files changed, 14 insertions(+), 14 deletions(-) commit e6f577893d0a4c1f62585bc426ab32d88593d7da Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Apr 15 15:47:31 2016 +0300 drm/i915/dsi: fix CHV dsi encoder hardware state readout on port C Due to "some hardware limitation" the DPI enable bit in port C control register does not get set on VLV. As a workaround we check the status in pipe B conf register instead. The workaround was added in commit c0beefd29fcb1ca998f0f9ba41be8539f8eeba9b Author: Gaurav K Singh <gaurav.k.singh@intel.com> Date: Tue Dec 9 10:59:20 2014 +0530 drm/i915: Software workaround for getting the HW status of DSI Port C on BYT Empirical evidence (on Surface 3 with DSI on port C per VBT) shows that this is the case also on CHV, so extend the workaround to CHV. We still have the device ready register check in place, so this should not get confused with e.g. HDMI on pipe B. This fixes a number of state checker warnings on CHV DSI port C. Cc: stable@vger.kernel.org Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460724451-13810-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 9938b04472d5c59f8bd8152a548533a8599596a2 Merge: bd7ced9 c3b46c7 Author: Jiri Kosina <jkosina@suse.cz> Date: Mon Apr 18 11:18:55 2016 +0200 Merge branch 'master' into for-next Sync with Linus' tree so that patches against newer codebase can be applied. Signed-off-by: Jiri Kosina <jkosina@suse.cz> commit bd7ced98812dbb906950d8b0ec786f14f631cede Author: Masanari Iida <standby24x7@gmail.com> Date: Tue Feb 2 22:31:06 2016 +0900 Doc: treewide : Fix typos in DocBook/filesystem.xml This patch fix spelling typos found in DocBook/filesystem.xml. It is because the file was generated from comments in code, I have to fix the comments in codes, instead of xml file. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> fs/jbd2/recovery.c | 2 +- fs/jbd2/transaction.c | 6 +++--- fs/super.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) commit a9eb221ab52480e86be60ab4cc3237fa4344b0cc Author: Sina Hamedian <shamedian@gmail.com> Date: Sat Jan 30 22:07:31 2016 -0800 arch/ia64/lib: Fix broken URL in comments The URL to the book IA-64 and Elementary Functions in idiv32.S and idiv64.S just led to a 404 page, so I updated them with a known good link that others can reference. Signed-off-by: Sina Hamedian <shamedian@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/ia64/lib/idiv32.S | 2 +- arch/ia64/lib/idiv64.S | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 880e1509db9732d5696d2a092e9bd61d80ad00be Author: Maciej S. Szmigiero <mail@maciej.szmigiero.name> Date: Sat Apr 16 00:27:23 2016 +0200 ARM: dts: imx6qdl-udoo: add 7 inch LCD touchscreen panel support The official UDOO board kit has 7 and 15.6 inch touchscreen LCD panels as options. This patch adds support for 7 inch panel only, but the 15.6 inch one should be easy to add using the same regulator, backlight device and LVDS channel. Since this panel is an option for UDOO board it is disabled by default and can be enabled (for example) by the following U-Boot commands: fdt set backlight status okay fdt set panelchan status okay fdt set panel7 status okay fdt set touchscreenp7 status okay The LVDS channels is also disabled by default to avoid warning from its driver. Signed-off-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-udoo.dtsi | 96 +++++++++++++++++++++++++++++++++++++ 1 file changed, 96 insertions(+) commit d8c8c70c48d1bc9bca41369836f9a3c781a5cdea Author: Alexander Kurz <akurz@blala.de> Date: Fri Apr 15 09:54:20 2016 +0200 ARM: dts: i.MX3x: add keypad port devicetree nodes Add the Keypad Port (KPP) devicetree nodes for IMX31 and IMX35 SOC. Signed-off-by: Alexander Kurz <akurz@blala.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx31.dtsi | 8 ++++++++ arch/arm/boot/dts/imx35.dtsi | 8 ++++++++ 2 files changed, 16 insertions(+) commit c17e9377aa81664d94b4f2102559fcf2a01ec8e7 Author: Vladimir Zapolskiy <vz@mleia.com> Date: Mon Apr 18 07:12:00 2016 +0300 ARM: dts: lpc32xx: set default clock rate of HCLK PLL Probably most of NXP LPC32xx boards have 13MHz main oscillator and therefore for HCLK PLL and ARM core clock rate default hardware setting is 16 * 13MHz = 208MHz, however a user may vary HCLK PLL/ARM core rate from 156MHz to about 266MHz for 13MHz clock source. The change explicitly defines HCLK PLL output rate to default 208MHz to overwrite any settings done by a bootloader, if needed it can be redefined in a board DTS file. Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> arch/arm/boot/dts/lpc32xx.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit 3397c2c45b1b6f54834dfeae30a73046f33ca943 Author: Alexander Kurz <akurz@blala.de> Date: Thu Apr 14 23:30:49 2016 +0200 ARM: dts: imx35: restore existing used clock enumeration A new element got inserted into enum mx35_clks with commit 3713e3f5e927 ("clk: imx35: define two clocks for rtc"). This insertion shifted most nummerical clock assignments to a new nummerical value which in turn rendered most hardcoded nummeric values in imx35.dtsi incorrect. Restore the existing order by moving the newly introduced clock to the end of the enum. Update the dts documentation accordingly. Signed-off-by: Alexander Kurz <akurz@blala.de> Fixes: 3713e3f5e927 ("clk: imx35: define two clocks for rtc") Cc: <stable@vger.kernel.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> Documentation/devicetree/bindings/clock/imx35-clock.txt | 1 + drivers/clk/imx/clk-imx35.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) commit e26e054ba8a2f9d357cdc874168396ea4ef73c28 Author: Yuan Yao <yao.yuan@nxp.com> Date: Wed Apr 13 18:08:27 2016 +0800 arm64: dts: ls1043a: add the DTS node for QSPI support Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts | 13 +++++++++++++ arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi | 14 ++++++++++++++ 2 files changed, 27 insertions(+) commit 60f9ae0d2b173245ba960b2fcd0fc44e81f92017 Author: Yuan Yao <yao.yuan@nxp.com> Date: Wed Apr 13 18:08:26 2016 +0800 Documentation: fsl-quadspi: Add fsl,ls1043a-qspi compatible string new compatible string: "fsl,ls1043a-qspi". Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> Documentation/devicetree/bindings/mtd/fsl-quadspi.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ccd37cffe39d7d4f1c1efcd42ec829ec16c7db66 Merge: efde611 d967ecb Author: David S. Miller <davem@davemloft.net> Date: Sun Apr 17 18:54:15 2016 -0400 Merge branch 'dsa-mv88e6xxx-switch-factorization' Vivien Didelot says: ==================== net: dsa: mv88e6xxx: factorize switch info This patchset factorizes the mv88e6xxx code by sharing a new extendable info structure to store static data such as switch family, product number, number of ports, number of databases and the name. The next step is to add a "flags" bitmap member to the info structure in order to simplify the shared code with a feature-based logic instead of checking their family/ID. This is a step forward having a single mv88e6xxx driver supporting many similar devices, like any usual Linux driver. Changes v3 -> v4: - constify probed name in DSA - rebase patchset above conflicting commit 48ace4e Changes v2 -> v3: - update commit messages and add Andrew's tags - keep the info lookup code in a separated function - split the single switch ID reading in probe in a new commit Changes v1 -> v2: - define PORT_SWITCH_ID_PROD_NUM_* values - use plain struct mv88e6xxx_info - remove non used yet ps->rev ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d967ecbc0b875081624857f27df4ed23c5eca106 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:24:03 2016 -0400 net: dsa: mv88e6xxx: remove switch ID from ps ps->id is not needed anymore, so remove it as well as the related defined values. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 1 - drivers/net/dsa/mv88e6xxx.h | 32 -------------------------------- 2 files changed, 33 deletions(-) commit cd5a2c82bad9e59f2674befc07c12effa0aea49d Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:24:02 2016 -0400 net: dsa: mv88e6xxx: add number of db to info Add the number of databases to the info structure. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 3 +++ drivers/net/dsa/mv88e6131.c | 4 ++++ drivers/net/dsa/mv88e6171.c | 4 ++++ drivers/net/dsa/mv88e6352.c | 6 ++++++ drivers/net/dsa/mv88e6xxx.c | 19 +------------------ drivers/net/dsa/mv88e6xxx.h | 1 + 6 files changed, 19 insertions(+), 18 deletions(-) commit 009a2b9843bf0b1a85fbf79f76e1de4995de527c Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:24:01 2016 -0400 net: dsa: mv88e6xxx: add number of ports to info Drop the ps->num_ports variable in favor of a new member of the info structure. This removes the need to assign it at setup time. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 16 +++------------- drivers/net/dsa/mv88e6131.c | 22 +++++----------------- drivers/net/dsa/mv88e6171.c | 7 ++++--- drivers/net/dsa/mv88e6352.c | 8 ++++++-- drivers/net/dsa/mv88e6xxx.c | 38 +++++++++++++++++++------------------- drivers/net/dsa/mv88e6xxx.h | 3 +-- 6 files changed, 38 insertions(+), 56 deletions(-) commit 22356476a86fc569c34cbf209d3a247c01e0ef6d Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:24:00 2016 -0400 net: dsa: mv88e6xxx: add family to info Add an mv88e6xxx_family enum to the info structure for better family indentification. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 3 ++ drivers/net/dsa/mv88e6131.c | 4 +++ drivers/net/dsa/mv88e6171.c | 4 +++ drivers/net/dsa/mv88e6352.c | 6 ++++ drivers/net/dsa/mv88e6xxx.c | 71 +++++---------------------------------------- drivers/net/dsa/mv88e6xxx.h | 13 +++++++++ 6 files changed, 38 insertions(+), 63 deletions(-) commit f6271e676b7f62a609f8ee5523a6a8ed47c0f333 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:23:59 2016 -0400 net: dsa: mv88e6xxx: add switch info Add a new switch info structure which is meant to store switch models static information, such as product number, name, number of ports, number of databases, etc. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 15 +++++++++++---- drivers/net/dsa/mv88e6131.c | 19 ++++++++++++++----- drivers/net/dsa/mv88e6171.c | 19 ++++++++++++++----- drivers/net/dsa/mv88e6352.c | 27 ++++++++++++++++++++------- drivers/net/dsa/mv88e6xxx.c | 18 +++++++++++------- drivers/net/dsa/mv88e6xxx.h | 27 +++++++++++++++++++++++---- 6 files changed, 93 insertions(+), 32 deletions(-) commit a439c0612d7bdbd5ce8ea868e6a1084f0d7300dc Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:23:58 2016 -0400 net: dsa: mv88e6xxx: read switch ID in probe Read the switch ID only once, at probe time, to avoid multiple read accesses and MII bus checking. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 57 ++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 27 deletions(-) commit 54c6f4bda7dabab7a7a9eeb8f1ced4b0b5fc4fd0 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:23:57 2016 -0400 net: dsa: mv88e6xxx: drop revision probing There is no point in having a special case for the revision when probing a switch model. The code gets cluttered with unnecessary defines, and leads to errors when code such as mv88e6131_setup compares PORT_SWITCH_ID_6131_B2 to ps->id which masks the revision. Drop every revision definition, and lookup only the product number. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 6 ------ drivers/net/dsa/mv88e6131.c | 2 -- drivers/net/dsa/mv88e6352.c | 6 ------ drivers/net/dsa/mv88e6xxx.c | 14 +------------- drivers/net/dsa/mv88e6xxx.h | 15 --------------- 5 files changed, 1 insertion(+), 42 deletions(-) commit b346204737fafce585f62543ed7691fb4a72789d Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:23:56 2016 -0400 net: dsa: mv88e6xxx: drop double ds assignment Every driver assigns ps->ds even though it gets assigned in the shared mv88e6xxx_setup_common function. Kill redundancy. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 2 -- drivers/net/dsa/mv88e6131.c | 2 -- drivers/net/dsa/mv88e6171.c | 2 -- drivers/net/dsa/mv88e6352.c | 2 -- 4 files changed, 8 deletions(-) commit 0209d144e3097fee1fe5d38532e6f0919c80d1ea Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Sun Apr 17 13:23:55 2016 -0400 net: dsa: constify probed name Change the dsa_switch_driver.probe function to return a const char *. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 6 +++--- drivers/net/dsa/mv88e6060.c | 10 +++++----- drivers/net/dsa/mv88e6123.c | 6 +++--- drivers/net/dsa/mv88e6131.c | 6 +++--- drivers/net/dsa/mv88e6171.c | 6 +++--- drivers/net/dsa/mv88e6352.c | 6 +++--- drivers/net/dsa/mv88e6xxx.c | 17 +++++++++-------- drivers/net/dsa/mv88e6xxx.h | 8 ++++---- include/net/dsa.h | 5 +++-- net/dsa/dsa.c | 6 +++--- 10 files changed, 39 insertions(+), 37 deletions(-) commit 922b3aa6e74e4e1cac95cf4ab88ecc0fd5162c89 Author: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Date: Sun Apr 10 21:22:32 2016 +0200 iio: adc: set INPUT_PROP_DIRECT Set INPUT_PROP_DIRECT to indicate that it is a touchscreen on the device to help userspace classify it. Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/mxs-lradc.c | 1 + 1 file changed, 1 insertion(+) commit 08e05d1fce5c87e5eaf16655c45db6beb4d93701 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 11 17:24:27 2016 +0300 ti-adc081c: Initial triggered buffer support Using this requires software triggers like CONFIG_IIO_HRTIMER_TRIGGER. The device can be configured to do internal periodic sampling but does not offer some sort of interrupt on data ready. Interrupts can only trigger when values get out of a specific range. Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/ti-adc081c.c | 77 ++++++++++++++++++++++++++++++++++++-------- 1 file changed, 64 insertions(+), 13 deletions(-) commit a6b5ec887b85df039055be316420b1520c23eb6b Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Mon Apr 11 17:24:26 2016 +0300 ti-adc081c: Add support for adc101c and adc121c These chips have an almost identical interface but support a different number of value bits. Datasheet links for comparison: * http://www.ti.com/lit/ds/symlink/adc081c021.pdf * http://www.ti.com/lit/ds/symlink/adc101c021.pdf * http://www.ti.com/lit/ds/symlink/adc121c021.pdf Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/Kconfig | 6 +++--- drivers/iio/adc/ti-adc081c.c | 51 ++++++++++++++++++++++++++++++++++++++++---- 2 files changed, 50 insertions(+), 7 deletions(-) commit 98a52530ed51394848079e7952c1145bd49fbe7d Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 17:40:24 2016 +0200 iio: frequency: ad9523: use unsigned int rather then bare unsigned This fix checkpatch warnings: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/frequency/ad9523.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit efde611b0afa47e64f2a329f4430830b91d77ea2 Merge: 7a7c170 3d780b9 Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 16 22:34:40 2016 -0400 Merge branch 'nfp-next' Jakub Kicinski says ==================== nfp: cleanups and improvements Main purpose of this set is to get rid of doing potentially long mdelay()s but it also contains some trivial changes I've accumulated. First two patches fix harmless copy-paste errors, next two clean up the documentation and remove unused defines. Patch 5 clarifies the interpretation of RX descriptor fields. Patch 6, by far the biggest, adds ability to perform FW reconfig asynchronously thanks to which we can stop using mdelay(). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3d780b926a12dd798417446d733d457f1be1cc73 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:54 2016 +0100 nfp: add async reconfiguration mechanism Some callers of nfp_net_reconfig() are in atomic context so we used to busy wait for commands to complete. In worst case scenario that means locking up a core for up to 5 seconds when a command times out. Lets add a timer-based mechanism of asynchronously checking whether reconfiguration completed successfully for atomic callers to use. Non-atomic callers can now just sleep. The approach taken is quite simple because (1) synchronous reconfigurations always happen under RTNL (or before device is registered); (2) we can coalesce pending reconfigs. There is no need for request queues, timer which eventually takes a look at reconfiguration result to report errors is good enough. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net.h | 12 +- .../net/ethernet/netronome/nfp/nfp_net_common.c | 172 ++++++++++++++++++--- 2 files changed, 157 insertions(+), 27 deletions(-) commit 180012dc05e565260a25696767c8f5b2df5fc50e Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:53 2016 +0100 nfp: remove buggy RX buffer length validation Meaning of data_len and meta_len RX WB descriptor fields is slightly confusing. Add a comment with a diagram clarifying the layout. Also remove the buffer length validation: (a) it's imprecise for static rx-offsets; (b) if firmware is buggy enough to DMA past the end of the buffer WARN_ON_ONCE() doesn't seem like a strong enough response. skb_put() will do the checking for us anyway. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 26 ++++++++++++---------- 1 file changed, 14 insertions(+), 12 deletions(-) commit 2db221cd444bf356243c57b653b6bf84c3491806 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:52 2016 +0100 nfp: remove unused suspicious mask defines NFP_NET_RXR_MASK sounds like a mask which could be used on NFP_NET_CFG_RXRS_ENABLE register but its value is quite strange. In fact there are no users of this define so let's just remove it. Same for TX rings. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net_ctrl.h | 4 ---- 1 file changed, 4 deletions(-) commit 6ffa622d8567de1daab2e0ca23b99520ad504215 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:51 2016 +0100 nfp: correct names of constants in comments Documentation in comments lacks CFG in some names. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net_ctrl.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c160692e8665880c844bebdee219ed9cdcb2346b Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:50 2016 +0100 nfp: remove unnecessary static There is no reason for those local variables to be static. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5b161096f0515b61b72156cd0c1e5c72e77cfed8 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Sat Apr 16 11:25:49 2016 +0100 nfp: check the right pointer for errors Correct checking error condition on wrong pointer - copy/paste mistake most likely. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7a7c1705dc6c629e3b1dce1c0c1ecc0af87486ac Merge: 89764d5 4272cc5 Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 16 22:02:14 2016 -0400 Merge branch 'IFF_NO_QUEUE-followups' Phil Sutter says: ==================== Minor IFF_NO_QUEUE conversion follow-up The following series converts two further drivers away from setting 'tx_queue_len = 0' to adding IFF_NO_QUEUE to priv_flags instead. The first one, rtl8188eu in staging didn't exist back when all drivers were converted. The second one, openvswitch seems to have slipped through my grep'ing back then, no idea why. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 4272cc51a6dcf2c086863372fd593809ffced7d5 Author: Phil Sutter <phil@nwl.cc> Date: Fri Apr 15 19:14:20 2016 +0200 openvswitch: Convert to using IFF_NO_QUEUE Cc: Pravin Shelar <pshelar@nicira.com> Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: David S. Miller <davem@davemloft.net> net/openvswitch/vport-internal_dev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 9e7399173200934612edf2153b93a8f232b88e4b Author: Phil Sutter <phil@nwl.cc> Date: Fri Apr 15 19:14:19 2016 +0200 staging: rtl8188eu: Convert to using IFF_NO_QUEUE Cc: Jakub Sitnicki <jsitnicki@gmail.com> Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/staging/rtl8188eu/os_dep/mon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 89764d59d237480ad930866dcf248b5e930454b9 Merge: f66bc94 8f180fa Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 16 21:51:01 2016 -0400 Merge branch 'fjes-next' Taku Izumi says: ==================== FUJITSU Extended Socket driver version 1.1 This patchsets update FUJITSU Extended Socket network driver into version 1.1. This mainly includes some improvements and minor bugfix. v1->v2: - Remove ioctl and debugfs facility according to David comment ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8f180fadb521ce440af82b5fa12ed56845110f15 Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:52 2016 +0900 fjes: Update fjes driver version : 1.1 Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bd5a256991f9a9cc0b7f6385dd1d8cfc90559b12 Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:46 2016 +0900 fjes: Introduce spinlock for rx_status This patch introduces spinlock of rx_status for proper excusive control. Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_hw.c | 22 ++++++++++++++++- drivers/net/fjes/fjes_hw.h | 2 ++ drivers/net/fjes/fjes_main.c | 57 +++++++++++++++++++++++++++++++++++++------- 3 files changed, 72 insertions(+), 9 deletions(-) commit 16bbec3a50efec46b679c3408c8be09f09dbcb7e Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:40 2016 +0900 fjes: Enhance changing MTU related work This patch enhances the fjes_change_mtu() method by introducing new flag named FJES_RX_MTU_CHANGING_DONE in rx_status. At the same time, default MTU value is changed into 65510 bytes. Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_hw.c | 8 +++++- drivers/net/fjes/fjes_hw.h | 1 + drivers/net/fjes/fjes_main.c | 60 ++++++++++++++++++++++++++++++++++++-------- 3 files changed, 58 insertions(+), 11 deletions(-) commit 19a0a7fd55af4658414de955f401cddaffc1f0ba Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:34 2016 +0900 fjes: fix bitwise check bug in fjes_raise_intr_rxdata_task In fjes_raise_intr_rxdata_task(), there's a bug of bitwise check because of missing "& FJES_RX_POLL_WORK". This patch fixes this bug. Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 3c3bd4a91ec12ad7c140bb3fd04b199e411760cb Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:27 2016 +0900 fjes: fix incorrect statistics information in fjes_xmit_frame() There are bugs of acounting statistics in fjes_xmit_frame(). Accounting self stats is wrong. accounting stats of other EPs to be transmitted is right. This patch fixes this bug. Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_main.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit da5a2383c9a2de88550841f6c100f991a6850230 Author: Taku Izumi <izumi.taku@jp.fujitsu.com> Date: Fri Apr 15 11:25:21 2016 +0900 fjes: optimize timeout value This patch optimizes the following timeout value. - FJES_DEVICE_RESET_TIMEOUT - FJES_COMMAND_REQ_TIMEOUT - FJES_COMMAND_REQ_BUFF_TIMEOUT Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_hw.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit f66bc94174e850a4de4adbe7a08fc37507051185 Author: Dinh Nguyen <dinguyen@opensource.altera.com> Date: Thu Apr 14 20:42:29 2016 -0500 stmmac: socfpga: remove extra call to socfpga_dwmac_setup In the socfpga_dwmac_probe function, we have a call to socfpga_dwmac_setup, which is already called from socfpga_dwmac_init later in the probe function. Remove this extra call to socfpga_dwmac_setup. Also we should not be calling socfpga_dwmac_setup() directly without wrapping it around the proper reset assert/deasserts. That is because the socfpga_dwmac_setup() is setting up PHY modes in the system manager, and it is requires the EMAC's to be in reset during the PHY setup. Reported-by: Matthew Gerlach <mgerlach@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 6 ------ 1 file changed, 6 deletions(-) commit 48ace4ef4c3f99ebf6f801c9a8326a4a39f31dbf Author: Andrew Lunn <andrew@lunn.ch> Date: Thu Apr 14 23:47:12 2016 +0200 dsa: mv88e6xxx: Kill the REG_READ and REG_WRITE macros These macros hide a ds variable and a return statement on error, which can lead to locking issues. Kill them off. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6123.c | 13 ++- drivers/net/dsa/mv88e6131.c | 41 ++++---- drivers/net/dsa/mv88e6171.c | 16 +-- drivers/net/dsa/mv88e6352.c | 15 +-- drivers/net/dsa/mv88e6xxx.c | 241 +++++++++++++++++++++++++++++++------------- drivers/net/dsa/mv88e6xxx.h | 21 ---- 6 files changed, 224 insertions(+), 123 deletions(-) commit 756ca874417695f77941948a77e9b8562635cc0a Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 17:04:34 2016 -0400 netdev_features: Add NETIF_F_TSO_MANGLEID to NETIF_F_ALL_TSO I realized that when I added NETIF_F_TSO_MANGLEID as a TSO type I forgot to add it to NETIF_F_ALL_TSO. This patch corrects that so the flag will be included correctly. The result should be minor as it was only used by a few drivers and in a few specific cases such as when NETIF_F_SG was not supported on a device so the TSO flags were cleared. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdev_features.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ac979929eaeaf82c3ba30161320b3f928d136de9 Merge: ec9dcd3 3a80e1f Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 16 19:09:14 2016 -0400 Merge branch 'ipv6-gre-offloads' Alexander Duyck says: ==================== Add support for offloads with IPv6 GRE tunnels This patch series enables the use of segmentation and checksum offloads with IPv6 based GRE tunnels. In order to enable this series I had to make a change to iptunnel_handle_offloads so that it would no longer free the skb. This was necessary as there were multiple paths in the IPv6 GRE code that required the skb to still be present so it could be freed. As it turned out I believe this actually fixes a bug that was present in FOU/GUE based tunnels anyway. Below is a quick breakdown of the performance gains seen with a simple netperf test passing traffic through a ip6gretap tunnel and then an i40e interface: Throughput Throughput Local Local Result Units CPU Service Tag Util Demand % 3544.93 10^6bits/s 6.30 4.656 "before" 13081.75 10^6bits/s 3.75 0.752 "after" ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3a80e1facd3c825c5ac804bc2efe118872832e33 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 15:34:04 2016 -0400 ip6gre: Add support for GSO This patch adds code borrowed from bits and pieces of other protocols to the IPv6 GRE path so that we can support GSO over IPv6 based GRE tunnels. By adding this support we are able to significantly improve the throughput for GRE tunnels as we are able to make use of GSO. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 56 ++++++++++++++++++++++++++++++++---------------------- 1 file changed, 33 insertions(+), 23 deletions(-) commit e0c20967c8a653d0213238621381e224d8f065fc Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 15:33:58 2016 -0400 GRE: Add support for GRO/GSO of IPv6 GRE traffic Since GRE doesn't really care about L3 protocol we can support IPv4 and IPv6 using the same offloads. With that being the case we can add a call to register the offloads for IPv6 as a part of our GRE offload initialization. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/gre_offload.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit ac4eb009e4776e9ef4c0484865c2f5a3786eecae Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 15:33:51 2016 -0400 ip6gre: Add support for basic offloads offloads excluding GSO This patch adds support for the basic offloads we support on most devices. Specifically with this patch set we can support checksum offload, basic scatter-gather, and highdma. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) commit a9e242ca43b13e5a5d176f97dfd2481c339934b7 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 15:33:45 2016 -0400 ip6gretap: Fix MTU to allow for Ethernet header When we were creating an ip6gretap interface the MTU was about 6 bytes short of what was needed. It turns out we were not taking the Ethernet header into account and as a result we were eating into the 8 bytes reserved for the encap limit. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/ip6_gre.c | 2 ++ 1 file changed, 2 insertions(+) commit aed069df099cd1a27900acb56bb892ec24c66ac4 Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Apr 14 15:33:37 2016 -0400 ip_tunnel_core: iptunnel_handle_offloads returns int and doesn't free skb This patch updates the IP tunnel core function iptunnel_handle_offloads so that we return an int and do not free the skb inside the function. This actually allows us to clean up several paths in several tunnels so that we can free the skb at one point in the path without having to have a secondary path if we are supporting tunnel offloads. In addition it should resolve some double-free issues I have found in the tunnels paths as I believe it is possible for us to end up triggering such an event in the case of fou or gue. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/geneve.c | 32 ++++++++++++-------------------- drivers/net/vxlan.c | 6 +++--- include/net/ip_tunnels.h | 2 +- include/net/udp_tunnel.h | 3 +-- net/ipv4/fou.c | 16 ++++++++-------- net/ipv4/ip_gre.c | 20 ++++++-------------- net/ipv4/ip_tunnel_core.c | 13 +++++-------- net/ipv4/ipip.c | 7 +++---- net/ipv6/sit.c | 14 ++++++-------- net/netfilter/ipvs/ip_vs_xmit.c | 6 ++---- 10 files changed, 47 insertions(+), 72 deletions(-) commit ec9dcd3507f055f025a7692a1ff90ce105f84c1b Merge: 544a773 0c165ff Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 16 18:30:27 2016 -0400 Merge branch 'w5100-spi-and-w5200-support' Akinobu Mita says: ==================== net: w5100: add support W5100/W5200 for SPI interface This series add support for Wiznet W5100 and W5200 for SPI interface. We can easily find the ethernet modules and shield for Arduino with these chips for purchase. I've tested them with BeagleBone. Wiznet W5100 for mmio access has already supported by w5100 driver. In order to share the code between mmio mode and SPI mode, this series firstly adds ability to support another register access interface to the existing w5100 driver. This ground work also requires to introduce workqueue and threaded irq because SPI transfers are callable only from contexts that can sleep unlike mmio access. The latter part of this series adds w5100-spi driver which actually support W5100 and W5200 for SPI interface. Supporting W5100 is straight forward because it only required to add a register access interface by the SPI transfer. W5100 and W5200 have similar memory map which justifies adding W5200 support to w5100 driver. * Changes from v2 to v3 - Add comment for reg_lock - Add ability to allocate ops specific data structure - Allocate w5200 ops specific data structure to put DMA-safe buffer - Add missing chip_id assignment for w5100_*_ops * Changes from v1 to v2 - Use a plain single pointer instead of SKB queue, spotted by David S. Miller - Correct timeout period in w5100_command - Use spi_write_then_read instead of spi_write which needs DMA-safe buffer - Support W5200 ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0c165ff2d8db575efa41f2586c2de193850dec48 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Fri Apr 15 00:11:33 2016 +0900 net: w5100: support W5200 This adds support for W5200 chip. W5100 and W5200 have similar memory map although some of their offsets are different. The register access sequences between them are different but w5100 driver has abstraction layer for difference bus interface modes so it is easy to add W5200 support to w5100 and w5100-spi drivers. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/Kconfig | 2 +- drivers/net/ethernet/wiznet/w5100-spi.c | 174 +++++++++++++++++++++++++++++++- drivers/net/ethernet/wiznet/w5100.c | 155 ++++++++++++++++++++-------- drivers/net/ethernet/wiznet/w5100.h | 6 ++ 4 files changed, 289 insertions(+), 48 deletions(-) commit 630cf09751fe166ffc25d1ae35ce804bf58eb3c7 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Fri Apr 15 00:11:32 2016 +0900 net: w5100: support SPI interface mode This adds new w5100-spi driver which shares the bus interface independent code with existing w5100 driver. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/Kconfig | 14 ++++ drivers/net/ethernet/wiznet/Makefile | 1 + drivers/net/ethernet/wiznet/w5100-spi.c | 136 ++++++++++++++++++++++++++++++++ 3 files changed, 151 insertions(+) commit bf2c6b90b385c163ad9c48fe97f5dc6af0091de6 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Fri Apr 15 00:11:31 2016 +0900 net: w5100: enable to support sleepable register access interface SPI transfer routines are callable only from contexts that can sleep. This adds ability to tell the core driver that the interface mode cannot access w5100 register on atomic contexts. In this case, workqueue and threaded irq are required. This also corrects timeout period waiting for command register to be automatically cleared because the latency of the register access with SPI transfer can be interfered by other contexts. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 190 ++++++++++++++++++++++++++++-------- drivers/net/ethernet/wiznet/w5100.h | 1 + 2 files changed, 153 insertions(+), 38 deletions(-) commit 850576cfede986f0683bed25e34bc15712ffb463 Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Fri Apr 15 00:11:30 2016 +0900 net: w5100: add ability to support other bus interface The w5100 driver currently only supports direct and indirect bus interface mode which use MMIO space for accessing w5100 registers. In order to support SPI interface mode which is supported by W5100 chip, this makes the bus interface abstraction layer more generic so that separated w5100-spi driver can use w5100 driver as core module. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 604 ++++++++++++++++++++++++------------ drivers/net/ethernet/wiznet/w5100.h | 28 ++ 2 files changed, 431 insertions(+), 201 deletions(-) commit d6586d2ef4608f113df16ca8ca757563891389ce Author: Akinobu Mita <akinobu.mita@gmail.com> Date: Fri Apr 15 00:11:29 2016 +0900 net: w5100: move mmiowb into register access callbacks Instead of sprinkle mmiowb over the driver code, move it into primary register write callbacks. (w5100_write, w5100_write16, w5100_writebuf) This is a preparation for supporting SPI interface which doesn't use MMIO for accessing w5100 registers. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Mike Sinkovsky <msink@permonline.ru> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/wiznet/w5100.c | 44 +++++++++++++------------------------ 1 file changed, 15 insertions(+), 29 deletions(-) commit 544a773a01828e3cc3b553721f68d880d0d27a97 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Sat Apr 9 12:46:23 2016 +0200 vxlan: reduce usage of synchronize_net in ndo_stop We only need to do the synchronize_net dance once for both, ipv4 and ipv6 sockets, thus removing one synchronize_net in case both sockets get dismantled. Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) commit 0412bd931f5f94d1054e958415c4a945d8ee62f4 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Fri Apr 8 22:55:01 2016 +0200 vxlan: synchronously and race-free destruction of vxlan sockets Due to the fact that the udp socket is destructed asynchronously in a work queue, we have some nondeterministic behavior during shutdown of vxlan tunnels and creating new ones. Fix this by keeping the destruction process synchronous in regards to the user space process so IFF_UP can be reliably set. udp_tunnel_sock_release destroys vs->sock->sk if reference counter indicates so. We expect to have the same lifetime of vxlan_sock and vxlan_sock->sock->sk even in fast paths with only rcu locks held. So only destruct the whole socket after we can be sure it cannot be found by searching vxlan_net->sock_list. Cc: Eric Dumazet <eric.dumazet@gmail.com> Cc: Jiri Benc <jbenc@redhat.com> Cc: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 20 +++----------------- include/net/vxlan.h | 2 -- 2 files changed, 3 insertions(+), 19 deletions(-) commit 1d98d0ec0ef3594901c2356773c191304703f17e Author: Bartosz Golaszewski <bgolaszewski@baylibre.com> Date: Mon Apr 11 11:57:21 2016 -0700 eeprom: at24: replace msleep() with usleep_range() We cannot expect msleep(1) to actually sleep for a period shorter than 20 ms. Replace all calls to msleep() with usleep_range(). Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/misc/eeprom/at24.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 5057e8e07f2521649eb444492433f419f93de37a Author: Bartosz Golaszewski <bgolaszewski@baylibre.com> Date: Mon Apr 11 11:57:17 2016 -0700 eeprom: at24: remove a reduntant if The second check for I2C_FUNC_I2C is reduntant, so remove it. Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com> [wsa: reworded commit message] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/misc/eeprom/at24.c | 3 --- 1 file changed, 3 deletions(-) commit 1f0477f18306c018a954e4f333690a9d0f7efc76 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Apr 11 14:12:04 2016 +0200 iio: light: new driver for the ROHM BH1780 This is a reimplementation of the old misc device driver for the ROHM BH1780 ambient light sensor (drivers/misc/bh1780gli.c). Differences from the old driver: - Uses the IIO framework - Uses runtime PM to idle the hardware after 5 seconds - No weird custom power management from userspace - No homebrewn values in sysfs This uses the same (undocumented) device tree compatible-string as the old driver ("rohm,bh1780gli"). Cc: Arnd Bergmann <arnd@arndb.de> Cc: Ulf Hansson <ulf.hansson@linaro.org> Cc: Daniel Mack <daniel@caiaq.de> Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/Kconfig | 11 ++ drivers/iio/light/Makefile | 1 + drivers/iio/light/bh1780.c | 297 +++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 309 insertions(+) commit aa0eb886be79eb785bf675bd8031ec1611d3295a Author: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Date: Sun Apr 10 21:20:56 2016 +0200 iio: adc: Indent if statement Indent lines inside if statement. Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/mxs-lradc.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 78f3873decadde42da6edf419635b5972ae61e00 Author: SeongJae Park <sj38.park@gmail.com> Date: Sat Apr 16 09:32:30 2016 +0900 Documentation: HOWTO: update git home URL in translations Homepage url of git in HOWTO document was updated by commit e234ebf7881c013b654113f0a208977ac3ce1d01 ("Documentation/HOWTO: update git home URL") but not applied to several translations. This commit updates them. Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/ko_KR/HOWTO | 6 +++--- Documentation/zh_CN/HOWTO | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit ad0de1e3fe9aacbf110052bcc1765c877e69858f Author: SeongJae Park <sj38.park@gmail.com> Date: Sat Apr 16 09:18:46 2016 +0900 Documentatio: HOWTO: remove regression postings info from translations Obsolete info about regression postings were removed by commit 5645a717c6ee61e67d38aa9f15cb9db074e1e99d ("Documentation: HOWTO: remove obsolete info about regression postings") but not applied to translations. This commit applies the change to translations. Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/ja_JP/HOWTO | 6 ------ Documentation/ko_KR/HOWTO | 2 -- Documentation/zh_CN/HOWTO | 2 -- 3 files changed, 10 deletions(-) commit 101ca9ccdd30c46afc5c9a30e7acdcbeaa330fa1 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 11:08:11 2016 +0200 serial: doc: .break_ctl() may sleep break_ctl() is not called from any sort of atomic context, so there is no problem with it sleeping. Reported-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 1 - 1 file changed, 1 deletion(-) commit ccd62a896ffe3dbd60f3b7570a2b74e4fe030ed6 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Sat Apr 16 09:36:32 2016 -0300 perf trace: Fix build when DWARF unwind isn't available The variable is initialized and then conditionally set to a different value, but not used when DWARF unwinding is not available, bummer, write 1000 times: "Run make -C tools/perf build-test"... builtin-trace.c: In function ‘cmd_trace’: builtin-trace.c:3112:6: error: variable ‘max_stack_user_set’ set but not used [-Werror=unused-but-set-variable] bool max_stack_user_set = true; ^ cc1: all warnings being treated as err Fix it by marking it as __maybe_unused. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Fixes: 056149932602 ("perf trace: Make --(min,max}-stack imply "--call-graph dwarf"") Link: http://lkml.kernel.org/n/tip-85r40c5hhv6jnmph77l1hgsr@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 87a048ef959dc72148196141f0b8b6ff71991ac9 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Fri Apr 15 16:59:42 2016 +0200 staging:iio:adis16240: Set self_test_no_autoclear flag The ADIS16201 does not automatically clear the self test flag bit the self test has been, so clear it manually. Otherwise we'll see a offset caused by the self-test bias on the output values during normal operation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/adis16240_core.c | 1 + 1 file changed, 1 insertion(+) commit 5d116edd71f688d0acc442ad8e66903e26d15d0b Author: Lars-Peter Clausen <lars@metafoo.de> Date: Fri Apr 15 16:59:41 2016 +0200 staging:iio:adis16209: Set self_test_no_autoclear flag The ADIS16201 does not automatically clear the self test flag bit the self test has been, so clear it manually. Otherwise we'll see a offset caused by the self-test bias on the output values during normal operation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/adis16209_core.c | 1 + 1 file changed, 1 insertion(+) commit 26d96e8ea9912d9fc7c48339ed6cf5642390ffff Author: Lars-Peter Clausen <lars@metafoo.de> Date: Fri Apr 15 16:59:40 2016 +0200 staging:iio:adis16203: Set self_test_no_autoclear flag The ADIS16201 does not automatically clear the self test flag bit the self test has been, so clear it manually. Otherwise we'll see a offset caused by the self-test bias on the output values during normal operation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/adis16203_core.c | 1 + 1 file changed, 1 insertion(+) commit 24410492868ba816bfd4366b5406d4881b8aee94 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Fri Apr 15 16:59:39 2016 +0200 staging:iio:adis16201: Set self_test_no_autoclear flag The ADIS16201 does not automatically clear the self test flag bit the self test has been, so clear it manually. Otherwise we'll see a offset caused by the self-test bias on the output values during normal operation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/adis16201_core.c | 1 + 1 file changed, 1 insertion(+) commit af8a41271b56f6d79cb4d7c7f3ca688a2d97a801 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Fri Apr 15 16:59:38 2016 +0200 iio:adis: Add support for manual self-test flag clear Some variants of the devices from the ADIS family don't auto-clear the self-test bit after the self-test has completed. Instead we have to manually clear. Add support for this to the ADIS library. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/adis.c | 7 ++++++- include/linux/iio/imu/adis.h | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) commit 964d97bdab7d81bb65453d84ed3a51f4605a7e9c Author: Jonathan Cameron <jic23@kernel.org> Date: Sat Apr 16 13:38:49 2016 +0100 iio: pressure: ms5611: use tab for indention This fixes the errors reported by checkpatch.pl: ERROR: code indent should use tabs where possible Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/ms5611_core.c | 2 +- drivers/iio/pressure/ms5611_spi.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 26b89d7d2b22e3b7ae78dc8e5e17e0e4e9d448ca Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:41 2016 +0200 iio: magnetometer: ak8975: put else and brace at the same line This fixes the error reported by checkpatch.pl: ERROR: else should follow close brace '}' Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/ak8975.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit d23057e0cadc465911968a4d3f8b0b556f545b6e Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:40 2016 +0200 iio: common: hid-sensors: use tab for indention This fixes the error reported by checkpatch.pl: ERROR: code indent should use tabs where possible Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/hid-sensors/hid-sensor-trigger.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6aa8eaf5d301b213f4660d1a37b44b5f1c2c458 Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:39 2016 +0200 iio: common: ms_sensors: use tab for indention This fixes the error reported by checkpatch.pl: ERROR: code indent should use tabs where possible Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/ms_sensors/ms_sensors_i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 102447adfa5a11df57ba1dfeefa250c96bf5e94f Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:38 2016 +0200 iio: adc: ad799x: remove space before comma This fixes the error reported by checkpatch.pl: ERROR: space prohibited before that ',' (ctx:WxW) Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/ad799x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4c79dd006b6489a62516e6db636d91e71fd8bee1 Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:37 2016 +0200 iio: adc: at91_adc: fix errors reported by checkpatch.pl This fixes the errors reported by checkpatch.pl: ERROR: space prohibited before that ',' (ctx:WxW) ERROR: code indent should use tabs where possible Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/at91_adc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 038a8b34d375b31a001198f5405f41cb48a153de Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:36 2016 +0200 iio: adc: mcp3422: remove spaces before comma This fixes the error reported by checkpatch.pl: ERROR: space prohibited before that ',' (ctx:WxW) Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/mcp3422.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 37dd441e4fe2d4b38e88d067175f1fc7d6acdf16 Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:35 2016 +0200 iio: adc: vf610_adc: fix case label indent This fixes the error reported by checkpatch.pl: ERROR: switch and case should be at the same indent Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/vf610_adc.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit fc0b81704f0458c20793e82a3c094a215833dcfe Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:34 2016 +0200 iio: inkern: add a missing space before if This fixes the error reported by checkpatch.pl: ERROR: space required before the open parenthesis '(' Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/inkern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ebe168069324b0a182f74bef593240840e4da97e Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Apr 14 21:36:33 2016 +0200 iio: light apds9960: fix wrong use of brace This fixes the error reported by checkpatch.pl: ERROR: that open brace { should be on the previous line Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/apds9960.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 77c4ad2d6a9bb6c6744f8f3a25d1c62669d6b656 Author: Daniel Baluta <daniel.baluta@intel.com> Date: Fri Apr 15 18:06:56 2016 +0300 iio: imu: Add initial support for Bosch BMI160 BMI160 is an Inertial Measurement Unit (IMU) which provides acceleration and angular rate measurement. It also offers a secondary I2C interface for connecting a magnetometer sensor (usually BMM160). Current driver offers support for accelerometer and gyroscope readings via sysfs or via buffer interface using an external trigger (e.g. hrtimer). Data is retrieved from IMU via I2C or SPI interface. Datasheet is at: http://www.mouser.com/ds/2/783/BST-BMI160-DS000-07-786474.pdf Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/Kconfig | 2 + drivers/iio/imu/Makefile | 1 + drivers/iio/imu/bmi160/Kconfig | 32 ++ drivers/iio/imu/bmi160/Makefile | 6 + drivers/iio/imu/bmi160/bmi160.h | 10 + drivers/iio/imu/bmi160/bmi160_core.c | 596 +++++++++++++++++++++++++++++++++++ drivers/iio/imu/bmi160/bmi160_i2c.c | 72 +++++ drivers/iio/imu/bmi160/bmi160_spi.c | 63 ++++ 8 files changed, 782 insertions(+) commit a3819e3e71d5000c176918309284a1fa2f133fcf Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Fri Apr 15 19:00:26 2016 +0200 x86: Fix non-static inlines Four instances of incorrect usage of non-static "inline" crept up in arch/x86, all trivial; cleaning them up: EVT_TO_HPET_DEV() - made static, it is only used in kernel/hpet.c Debug version of check_iommu_entries() is an __init function. Non-debug dummy empty version of it is declared "inline" instead - which doesn't help to eliminate it (the caller is in a different unit, inlining doesn't happen). Switch to non-inlined __init function, which does eliminate it (by discarding it as part of __init section). crypto/sha-mb/sha1_mb.c: looks like they just forgot to add "static" to their two internal inlines, which emitted two unused functions into vmlinux. text data bss dec hex filename 95903394 20860288 35991552 152755234 91adc22 vmlinux_before 95903266 20860288 35991552 152755106 91adba2 vmlinux Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460739626-12179-1-git-send-email-dvlasenk@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/sha-mb/sha1_mb.c | 4 ++-- arch/x86/kernel/hpet.c | 2 +- arch/x86/kernel/pci-iommu_table.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit 9243ae5b28d02dc7d71a4f00c981ef6feaede3f1 Merge: 0b22cd2 f3e459d Author: Ingo Molnar <mingo@kernel.org> Date: Sat Apr 16 11:09:57 2016 +0200 Merge tag 'perf-core-for-mingo-20160415' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements from Arnaldo Carvalho de Melo: User visible changes: - Wire the callchain unwinding "max-stack" now to 'perf script --max-stack', allowing to limit the depth of callchains, possibly reducing processing time (Arnaldo Carvalho de Melo) - Ditto for 'perf trace --max-stack' (Arnaldo Carvalho de Melo) - Introduce a --min-stack filter for 'perf trace', to show syscalls that had a userspace callchain leading to it at least min-stack deep (Arnaldo Carvalho de Melo) - Make 'perf trace' work with multiple threads and the --duration filter, i.e. do not print the start of an interrupted syscall followed by ... to print interrupts from other threads, as we need to wait the sys_exit syscall tracepoint to calculate the duration, duh. (Arnaldo Carvalho de Melo) System wide --duration now works as expected: [root@jouet ~]# trace --duration 100 152.393 (145.147 ms): Timer/24358 futex(uaddr: 0x7f5ed98e56cc, op: WAIT_BITSET|PRIV|CLKRT, val: 7055125, utime: 0x7f5ecdbfec30, val3: 4294967295) = -1 ETIMEDOUT Connection timed out 152.438 (145.040 ms): firefox/24321 poll(ufds: 0x7f5ec388b460, nfds: 6, timeout_msecs: 4294967295) = 1 358.580 (158.279 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x7ffdcbb63610) = 0 Timeout 358.687 (148.285 ms): gnome-terminal/2711 poll(ufds: 0x55b7e6811ad0, nfds: 15, timeout_msecs: 249) = 1 370.150 (169.569 ms): gnome-shell/2287 poll(ufds: 0x55e623d65490, nfds: 86, timeout_msecs: 4294967295) = 1 - Now 'perf trace's --max-stack and --min-stack will automatically set "--call-graph dwarf", if --call-graph is not present on the command line: [root@jouet ~]# perf trace -e nanosleep --max-stack 3 usleep 1 0.299 ( 0.057 ms): usleep/29658 nanosleep(rqtp: 0x7fff80f3b230) = 0 __nanosleep+0x10 (/usr/lib64/libc-2.22.so) usleep+0x34 (/usr/lib64/libc-2.22.so) main+0x1eb (/usr/bin/usleep) [root@jouet ~]# - Bump 'perf trace --mmap-pages' for root when using callchains and not specifying --mmap-pages explicitely (Arnaldo Carvalho de Melo) Build fixes: - The python binding object had missing symbols, to some refactoring to fix that (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit bdb4da86198ecee79a06c97004ad96ee6aa98f9d Merge: 1155100 6111413 Author: Heiko Stuebner <heiko@sntech.de> Date: Sat Apr 16 03:04:15 2016 +0200 Merge branch 'v4.7-shared/clkids' into v4.7-clk/next commit 6111413be8708a7509fd9c09817a657f6bf8f749 Author: Heiko Stuebner <heiko@sntech.de> Date: Sat Apr 16 02:54:52 2016 +0200 clk: rockchip: fix checkpatch errors in rk3399 dt-binding header Some "please, no space before tabs" checkpatch warnings slipped through the recent addition of the rk3399 dt-binding header, so fix them. Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/clock/rk3399-cru.h | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit d5630b7a557aff4d107e5af2e73fb91ed707f442 Author: Grygorii Strashko <grygorii.strashko@ti.com> Date: Thu Dec 10 19:03:45 2015 +0200 clk: ti: dra7: fix kernel boot with arg 'clocksource=gp_timer' The OMAP Platform code provides possibility to select GP Timer as default clocksource instead of counter_32K by using bootcmd parameter 'clocksource', but the system will crash during early boot when this option is used on dra7 or omap5 platforms, because it will hit BUG() statement: omap2_gptimer_clocksource_init ->BUG_ON(res); This happens because clk_dev alias "sys_clkin_ck" is not registered. Hence, fix it by adding missing "sys_clkin_ck" clk_dev aliases definitions for omap5 and dra7. Acked-by: Tero Kristo <t-kristo@ti.com> Cc: Tony Lindgren <tony@atomide.com> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ti/clk-54xx.c | 1 + drivers/clk/ti/clk-7xx.c | 1 + 2 files changed, 2 insertions(+) commit 3db5ca27c80c15d20d0f1152dc34a5bcfa432ae6 Author: Tero Kristo <t-kristo@ti.com> Date: Wed Mar 16 21:54:56 2016 +0200 clk: ti: amx3xx: limit the maximum frequency of DPLLs based on spec AM33xx/AM43xx devices use the same DPLL IP blocks, which only support maximum rate of 1GHz [1] for the default and 2GHz for the low-jitter type DPLLs [2]. Reflect this limitation in the DPLL init code by adding the max-rate parameter based on the DPLL types. [1] Functional, integration & test specification for GS70 ADPLLS, Rev 1.0-01 [2] Functional, integration & test specification for GS70 ADPLLLJ, Rev 0.8-02 Signed-off-by: Tero Kristo <t-kristo@ti.com> Cc: Nishanth Menon <nm@ti.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ti/dpll.c | 5 +++++ 1 file changed, 5 insertions(+) commit c5cc2a0bc930f1ae00b198aeb752acc3bdd4d5a7 Author: Tero Kristo <t-kristo@ti.com> Date: Wed Mar 16 21:54:55 2016 +0200 clk: ti: dpll: add support for specifying max rate for DPLLs DPLLs typically have a maximum rate they can support, and this varies from DPLL to DPLL. Add support of the maximum rate value to the DPLL data struct, and also add check for this in the DPLL round_rate function. Signed-off-by: Tero Kristo <t-kristo@ti.com> Reviewed-by: Nishanth Menon <nm@ti.com> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ti/clkt_dpll.c | 3 +++ include/linux/clk/ti.h | 2 ++ 2 files changed, 5 insertions(+) commit fefe0535b74f7d577af9310cf3741b4960a6687f Author: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Date: Mon Apr 4 11:21:09 2016 +0200 clk: tango4: improve clkgen driver Add support for USB and SDIO clocks. Report unsupported setups and panic. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-tango4.c | 73 +++++++++++++++++++++++++++++++----------------- 1 file changed, 48 insertions(+), 25 deletions(-) commit f48256efededaa87f475c0d6330d83f853cb064a Author: wangweidong <wangweidong1@huawei.com> Date: Thu Apr 14 15:43:52 2016 +0800 phy: make some bits preserved while setup forced mode When tested the PHY SGMII Loopback: 1.set the LOOPBACK bit, 2.set the autoneg to AUTONEG_DISABLE, it calls the genphy_setup_forced which will clear the bit. The BMCR_LOOPBACK bit should be preserved. As Florian pointed out that other bits should be preserved too. So I make the BMCR_ISOLATE and BMCR_PDOWN as well. Signed-off-by: Weidong Wang <wangweidong1@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/phy_device.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit cb0ceaf77d93964a0d00477c79f4499123f6159c Author: Vladimir Zapolskiy <vz@mleia.com> Date: Tue Mar 8 01:41:29 2016 +0200 clk: at91: fix check of clk_register() returned value The clk_register() function returns a valid pointer to struct clk or ERR_PTR() error code, this makes a check for returned NULL value useless and may lead to oops on error path. Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Fixes: bcc5fd49a0fd ("clk: at91: add a driver for the h32mx clock") Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/at91/clk-h32mx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d31d56ec17431d3883d5f4b60d407fa5e75add06 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:26 2016 -0800 clk: xgene: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Loc Ho <lho@apm.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-xgene.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4c211eaad6202ffae10f4dd476db2f6173f880c7 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:25 2016 -0800 clk: wm831x: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Mark Brown <broonie@kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-wm831x.c | 1 - 1 file changed, 1 deletion(-) commit d4da52c38c38366689db437327fe8385957b970c Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:24 2016 -0800 clk: twl6040: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-twl6040.c | 1 - 1 file changed, 1 deletion(-) commit 7ecf47c2c292e25947c2aa95293c52145997f67f Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:20 2016 -0800 clk: rk808: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Chris Zhong <zyw@rock-chips.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-rk808.c | 1 - 1 file changed, 1 deletion(-) commit ec3f2fcb32060f3f31ffc778879553367e71ceaf Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:19 2016 -0800 clk: qoriq: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Hou Zhiqiang <B48286@freescale.com> Cc: Scott Wood <scottwood@freescale.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-qoriq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1fb4742a268726293f022097f85f13fa3856ea49 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:17 2016 -0800 clk: palmas: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Peter Ujfalusi <peter.ujfalusi@ti.com> Cc: Nishanth Menon <nm@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-palmas.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1efee90d275fe7b22ae0320adb6c9bb49937a9d8 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:16 2016 -0800 clk: nspire: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Daniel Tang <dt.tangr@gmail.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-nspire.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 3be32b79a1c3b99d5f0d266eaa2e727a672f62db Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:13 2016 -0800 clk: ls1x: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Kelvin Cheung <keguang.zhang@gmail.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-ls1x.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 26659ada14cece0d0705f4e020dab634db2f95cc Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:10 2016 -0800 clk: clps711x: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-clps711x.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit c9bb8a4f3db60342ad97f7eb77965a6ae30851bb Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:08 2016 -0800 clk: zte: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Jun Nie <jun.nie@linaro.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/zte/clk-zx296702.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 260c37f92a420958c25ab404e7f03a1cd3b04843 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 11:00:01 2016 -0800 clk: sunxi: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Cc: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/sunxi/clk-a10-hosc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 23ced2711bcdd26163f1188f693d6379ab0c6bf3 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 10:59:59 2016 -0800 clk: sirf: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Guo Zeng <Guo.Zeng@csr.com> Cc: Barry Song <Baohua.Song@csr.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/sirf/clk-atlas6.c | 7 +++---- drivers/clk/sirf/clk-prima2.c | 7 +++---- 2 files changed, 6 insertions(+), 8 deletions(-) commit 536630ddbffb97e5a9de76a2d793ec118413e758 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 10:59:52 2016 -0800 clk: mmp: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Chao Xie <chao.xie@marvell.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/mmp/clk-mmp2.c | 14 +++++--------- drivers/clk/mmp/clk-of-mmp2.c | 10 +++++----- drivers/clk/mmp/clk-of-pxa168.c | 8 ++++---- drivers/clk/mmp/clk-of-pxa1928.c | 12 ++++++------ drivers/clk/mmp/clk-of-pxa910.c | 8 ++++---- drivers/clk/mmp/clk-pxa168.c | 8 +++----- drivers/clk/mmp/clk-pxa910.c | 8 +++----- 7 files changed, 30 insertions(+), 38 deletions(-) commit f2d32b623c774ee63151a308a6bd79b4e543a4ee Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 1 10:59:51 2016 -0800 clk: meson: Remove CLK_IS_ROOT This flag is a no-op now. Remove usage of the flag. Cc: Carlo Caione <carlo@caione.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/meson/meson8b-clkc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 75ff88888093eddca478a8fa1b77b30edb4fa8be Merge: c02b73c 33b8ac9 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 16:02:46 2016 -0700 Merge branch 'clk-artpec6' into clk-next * clk-artpec6: clk: add artpec-6 clock controller clk: add device tree binding for Artpec-6 clock controller commit 33b8ac917a8f7a22fa3d779f875646201d0097a0 Author: Lars Persson <lars.persson@axis.com> Date: Mon Apr 4 11:23:23 2016 +0200 clk: add artpec-6 clock controller Add a driver for the main clock controller of the Artpec-6 Soc. Signed-off-by: Lars Persson <larper@axis.com> [sboyd@codeaurora.org: Reformatted driver structure and of match] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> MAINTAINERS | 2 +- drivers/clk/Makefile | 1 + drivers/clk/axis/Makefile | 1 + drivers/clk/axis/clk-artpec6.c | 242 +++++++++++++++++++++++++++++++++++++++++ 4 files changed, 245 insertions(+), 1 deletion(-) commit 67bad3e5ce82b9eea2428118d909b2c8b80a71cf Author: Lars Persson <lars.persson@axis.com> Date: Mon Apr 4 11:23:22 2016 +0200 clk: add device tree binding for Artpec-6 clock controller Add device tree documentation for the main clock controller in the Artpec-6 SoC. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Lars Persson <larper@axis.com> [sboyd@codeaurora.org: Added unit address to binding example] Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../devicetree/bindings/clock/artpec6.txt | 41 ++++++++++++++++++++++ include/dt-bindings/clock/axis,artpec6-clkctrl.h | 38 ++++++++++++++++++++ 2 files changed, 79 insertions(+) commit c02b73c943d723511abecde7909d0818638d1bc2 Author: Suman Anna <s-anna@ti.com> Date: Tue Apr 5 13:28:57 2016 -0500 clk: ti: dflt: remove redundant unlikely Commit 7aba4f5201d1 ("clk: ti: dflt: fix enable_reg validity check") fixed a validation check by using an IS_ERR() macro within the existing unlikely expression, but IS_ERR() macro already has an unlikely inside it, so get rid of the redundant unlikely macro from the validation check. Reported-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/ti/clkt_dflt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ab98e20af56e54597e87dd694c04088d9c0f5614 Merge: 56ad09e 1155100 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 15:47:54 2016 -0700 Merge tag 'v4.7-rockchip-clk1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-next Pull rockchip clk updates from Heiko Stuebner: This is first big chunk of Rockchip clock-related changes for 4.7. Main change is probably the added support for the new rk3399 soc and necessary infrastructure changes surrounding it. The biggest chunk is probably that clock code is now able to handle multiple clock providers in one system, as the rk3399 has two of those. A general one and another smaller one in a separate power domain. The rk3399 also uses another new pll type. Thankfully it just fits nicely into our current structure. It also needs some parts like the cpuclk mux parameters to be a bit more flexible and an new fractional divider subtype without gate. Apart from this big change we have some more fixes and removal of forgotten variables. * tag 'v4.7-rockchip-clk1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: add clock controller for the RK3399 dt-bindings: add bindings for rk3399 clock controller clk: rockchip: add dt-binding header for rk3399 clk: rockchip: release io resource when failing to init clk clk: rockchip: remove redundant checking of device_node clk: rockchip: fix warning reported by kernel-doc clk: rockchip: remove mux_core_reg from rockchip_cpuclk_reg_data clk: rockchip: add new pll-type for rk3399 and similar socs clk: rockchip: Add support for multiple clock providers clk: rockchip: allow varying mux parameters for cpuclk pll-sources clk: rockchip: add a COMPOSITE_FRACMUX_NOGATE type commit 56ad09e289c58d2e86a8c49b0f6eb2ff070c2fb1 Merge: bf0a976 12a5681 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 15:44:42 2016 -0700 Merge branch 'clk-renesas-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into clk-next Pull renesas clk driver updates from Geert Uytterhoeven: - Support for the PWM module clock and watchdog related clocks on R-Car H3, - Cleanups and clarifications. * 'clk-renesas-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers: clk: renesas: mstp: Clarify cpg_mstp_{at,de}tach_dev() domain parameter clk: renesas: cpg-mssr: Drop check for CONFIG_PM_GENERIC_DOMAINS_OF clk: renesas: mstp: Drop check for CONFIG_PM_GENERIC_DOMAINS_OF clk: renesas: r8a7795: add RWDT clock clk: renesas: r8a7795: add R clk clk: renesas: r8a7795: add OSC and RINT clocks clk: renesas: cpg-mssr: add generic support for read-only DIV6 clocks clk: renesas: r8a7795: make SD clk definition specific for GEN3 clk: renesas: r8a7795: add PWM clock commit bf0a976994bc6265444acc2de3561b94ab73a5ee Merge: 811a087 69c542e Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 15:42:31 2016 -0700 Merge tag 'imx-clk-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into clk-next The i.MX clock update for 4.7: - Register SAI clk as shared clocks to support SAI audio on i.MX6SX - Add the missing ckil clock for i.MX7 - Update clk-gate2 and vf610 clock driver to prepare for suspend support on VF610 - Fix DCU clock configurations and add TCON ipg clock to support DRM display on VF610 * tag 'imx-clk-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: clk: imx: vf610: fix whitespace in vf610-clock.h clk: imx: vf610: add TCON ipg clock clk: imx: vf610: fix DCU clock tree clk: imx: add ckil clock for i.MX7 clk: imx: vf610: add suspend/resume support clk: imx: vf610: add WKPU unit clk: imx: vf610: leave DDR clock on clk: imx: clk-gate2: allow custom gate configuration clk: imx6sx: Register SAI clocks as shared clocks commit 811a087c55dc80e113d91702862fb89eda4716ac Merge: 9e52cec 6466ee3 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Fri Apr 15 15:19:32 2016 -0700 Merge tag 'clk-v4.7-samsung' of git://linuxtv.org/snawrocki/samsung into clk-next Pull samsung clk updates from Sylwester Nawrocki: This includes addition of some missing clock tree definitions (UART, MMC2 clocks) for exynos3250 SoC and exporting of IDs for exynos543x SoC AMBA AXI bus clocks needed for bus frequency scaling. * tag 'clk-v4.7-samsung' of git://linuxtv.org/snawrocki/samsung: clk: samsung: exynos542x: Add the clock id for ACLK dt-bindings: clock: Add the clock id for ACLK clock of Exynos542x SoC clk: samsung: exynos3250: Add MMC2 clock clk: samsung: exynos3250: Add UART2 clock dt-bindings: Add the clock id of UART2 and MMC2 for Exynos3250 commit 9e52cec04fd3b9b686f9256151b47fe61f7c28ef Author: Finley Xiao <finley.xiao@rock-chips.com> Date: Tue Apr 12 16:43:39 2016 +0800 clk: Add clk_composite_set_rate_and_parent When changing the clock-rate, currently a new parent is set first and a divider adapted thereafter. This may result in the clock-rate overflowing its target rate for a short time if the new parent has a higher rate than the old parent. While this often doesn't produce negative effects, it can affect components in a voltage-scaling environment, like the GPU on the rk3399 socs, where the voltage than simply is to low for the temporarily to high clock rate. For general clock hirarchies this may need more extensive adaptions to the common clock-framework, but at least for composite clocks having both parent and rate settings it is easy to create a short-term solution to make sure the clock-rate does not overflow the target. Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/clk-composite.c | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 18717b06ee4897c2cc5e92783386c4b304b9fce9 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 11:08:10 2016 +0200 serial: doc: .(un)throttle() are serialized by the tty layer Document that .(un)throttle() are serialized with each other, and with termios modification by the tty layer. Reported-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit a3bedc3bdc6e640141157636e253d63279860e23 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 11:08:09 2016 +0200 serial: doc: .(un)throttle() depends on hardware assisted flow control Document that .throttle() and .unthrottle() are relevant only if hardware assisted flow control is enabled. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 2 ++ 1 file changed, 2 insertions(+) commit d124fd3bb36ceb40438f10c897ce642386b74b72 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Thu Apr 14 11:08:08 2016 +0200 serial: doc: Re-add paragraph documenting uart_console_write() Commit 834392a7d92677ff ("serial: doc: Un-document non-existing uart_write_console()") removed a paragraph about a helper function that seemed to never exist. Peter Hurley pointed out that the function does exist, but is called differently. Re-add the paragraph, with the function name corrected. Fixes: 834392a7d92677ff ("serial: doc: Un-document non-existing uart_write_console()") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 5 +++++ 1 file changed, 5 insertions(+) commit 63f8e8d2a575ef62e5b705516b491a98a60517ff Author: Doug Hoyte <doug@hcsw.org> Date: Wed Apr 13 11:09:21 2016 -0400 Documentation typo: wrong page flag bit for KPF_HUGE The correct value 17 can be found later in this document and in the kernel-page-flags.h header (KPF_HUGE). I noticed this while implementing vmprobe's kpageflags support. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/vm/pagemap.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2dd723fdbb61fbc4ee0125401f04f5431f61268d Author: Diego Herranz <diegoherranz@diegoherranz.com> Date: Tue Apr 12 18:13:27 2016 +0100 doc: usb: Fix typo in gadget_multi documentation It tries to "match" drivers for each interface (not "much"). Signed-off-by: Diego Herranz <diegoherranz@diegoherranz.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/usb/gadget_multi.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cfaf790f932beae903a5fc5b19039d7b3842a3b3 Author: Diego Viola <diego.viola@gmail.com> Date: Sun Apr 3 04:34:48 2016 -0300 README: remove trailing whitespace Signed-off-by: Diego Viola <diego.viola@gmail.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> README | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 4f2651e1d838c4db656170bddfcabdf67a8d7f9b Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Thu Mar 31 12:10:30 2016 +0100 Documentation: update Michael K. Johnson's work The URL for "Writing Linux Device Drivers" hasn't been available in some time. Updating the entry to Michael K. Johnson's "Linux Kernel Hackers' Guide" Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/kernel-docs.txt | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 4e811b1e11d5bc9e25ca1a30ce6654add2b571e3 Merge: 311b217 53fa103 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 17:29:37 2016 -0400 Merge branch 'sctp-diag' Xin Long says: ==================== sctp: support sctp_diag in kernel This patchset will add sctp_diag module to implement diag interface on sctp in kernel. For a listening sctp endpoint, we will just dump it's ep info. For a sctp connection, we will the assoc info and it's ep info. The ss dump will looks like: [iproute2]# ./misc/ss --sctp -n -l State Recv-Q Send-Q Local Address:Port Peer Address:Port LISTEN 0 128 172.16.254.254:8888 *:* LISTEN 0 5 127.0.0.1:1234 *:* LISTEN 0 5 127.0.0.1:1234 *:* - ESTAB 0 0 127.0.0.1%lo:1234 127.0.0.1:4321 LISTEN 0 128 172.16.254.254:8888 *:* - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.253.253:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.1.1:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.1.2:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.2.1:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.2.2:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.3.1:8888 - ESTAB 0 0 172.16.254.254%eth1:8888 172.16.3.2:8888 LISTEN 0 0 127.0.0.1:4321 *:* - ESTAB 0 0 127.0.0.1%lo:4321 127.0.0.1:1234 The entries with '- ESTAB' are the assocs, some of them may belong to the same endpoint. So we will dump the parent endpoint first, like the entry with 'LISTEN'. then dump the assocs. ep and assocs entries will be dumped in right order so that ss can show them in tree format easily. Besides, this patchset also simplifies sctp proc codes, cause it has some similar codes with sctp diag in sctp transport traversal. v1->v2: 1. inet_diag_get_handler needs to return it as const. 2. merge 5/7 into 2/7 of v1. v2->v3: do some improvements and fixes in patch 1-4, see the details in each patch's comment. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 53fa10369c45a51947f06e8b622d2fa2cc64fda1 Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:35 2016 +0800 sctp: fix some rhashtable functions using in sctp proc/diag When rhashtable_walk_init return err, no release function should be called, and when rhashtable_walk_start return err, we should only invoke rhashtable_walk_exit to release the source. But now when sctp_transport_walk_start return err, we just call rhashtable_walk_stop/exit, and never care about if rhashtable_walk_init or start return err, which is so bad. We will fix it by calling rhashtable_walk_exit if rhashtable_walk_start return err in sctp_transport_walk_start, and if sctp_transport_walk_start return err, we do not need to call sctp_transport_walk_stop any more. For sctp proc, we will use 'iter->start_fail' to decide if we will call rhashtable_walk_stop/exit. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/proc.c | 7 ++++++- net/sctp/socket.c | 15 ++++++++++----- 2 files changed, 16 insertions(+), 6 deletions(-) commit b5e2f4e6998a2b999da8fa0290b692f0bd85c8b7 Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:34 2016 +0800 sctp: merge the seq_start/next/exits in remaddrs and assocs In sctp proc, these three functions in remaddrs and assocs are the same. we should merge them into one. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/proc.c | 45 +++++++++------------------------------------ 1 file changed, 9 insertions(+), 36 deletions(-) commit 8f840e47f190cbe61a96945c13e9551048d42cef Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:33 2016 +0800 sctp: add the sctp_diag.c file This one will implement all the interface of inet_diag, inet_diag_handler. which includes sctp_diag_dump, sctp_diag_dump_one and sctp_diag_get_info. It will work as a module, and register inet_diag_handler when loading. v2->v3: - fix the mistake in inet_assoc_attr_size(). - change inet_diag_msg_laddrs_fill() name to inet_diag_msg_sctpladdrs_fill. - change inet_diag_msg_paddrs_fill() name to inet_diag_msg_sctpaddrs_fill. - add inet_diag_msg_sctpinfo_fill() to make asoc/ep fill code clearer. - add inet_diag_msg_sctpasoc_fill() to make asoc fill code clearer. - merge inet_asoc_diag_fill() and inet_ep_diag_fill() to inet_sctp_diag_fill(). - call sctp_diag_get_info() directly, instead by handler, cause the caller is in the same file with it. - call lock_sock in sctp_tsp_dump_one() to make sure we call get sctp info safely. - after lock_sock(sk), we should check sk != assoc->base.sk. - change mem[SK_MEMINFO_WMEM_ALLOC] to asoc->sndbuf_used for asoc dump when asoc->ep->sndbuf_policy is set. don't use INET_DIAG_MEMINFO attr any more. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/inet_diag.h | 2 + net/sctp/Kconfig | 4 + net/sctp/Makefile | 1 + net/sctp/sctp_diag.c | 497 +++++++++++++++++++++++++++++++++++++++++ 4 files changed, 504 insertions(+) commit cb2050a7b8131a9a9f3f97276df1feaae8987dc8 Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:32 2016 +0800 sctp: export some functions for sctp_diag in inet_diag inet_diag_msg_common_fill is used to fill the diag msg common info, we need to use it in sctp_diag as well, so export it. inet_diag_msg_attrs_fill is used to fill some common attrs info between sctp diag and tcp diag. v2->v3: - do not need to define and export inet_diag_get_handler any more. cause all the functions in it are in sctp_diag.ko, we just call them in sctp_diag.ko. - add inet_diag_msg_attrs_fill to make codes clear. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_diag.c | 67 ++++++++++++++++++++++++++++++++-------------------- 1 file changed, 41 insertions(+), 26 deletions(-) commit 626d16f50f39bb9c44f98fd256cae2b864900a01 Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:31 2016 +0800 sctp: export some apis or variables for sctp_diag and reuse some for proc For some main variables in sctp.ko, we couldn't export it to other modules, so we have to define some api to access them. It will include sctp transport and endpoint's traversal. There are some transport traversal functions for sctp_diag, we can also use it for sctp_proc. cause they have the similar situation to traversal transport. v2->v3: - rhashtable_walk_init need the parameter gfp, because of recent upstrem update Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/sctp.h | 13 +++++ net/sctp/proc.c | 81 +++++++------------------------ net/sctp/socket.c | 125 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 156 insertions(+), 63 deletions(-) commit 52c52a61a39fb319c14a582f8631619e5d5f55bf Author: Xin Long <lucien.xin@gmail.com> Date: Thu Apr 14 15:35:30 2016 +0800 sctp: add sctp_info dump api for sctp_diag sctp_diag will dump some important details of sctp's assoc or ep, we use sctp_info to describe them, sctp_get_sctp_info to get them, and export it to sctp_diag.ko. v2->v3: - we will not use list_for_each_safe in sctp_get_sctp_info, cause all the callers of it will use lock_sock. - fix the holes in struct sctp_info with __reserved* field. because sctp_diag is a new feature, and sctp_info is just for now, it may be changed in the future. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/sctp.h | 67 ++++++++++++++++++++++++++++++++++++++ include/net/sctp/sctp.h | 3 ++ net/sctp/socket.c | 86 +++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 156 insertions(+) commit 4b91545072ad7ca1963d2a89c8b42fc2eb561484 Author: Heiko Stuebner <heiko@sntech.de> Date: Fri Apr 15 23:28:57 2016 +0200 ARM: dts: rockchip: move rk3288 edp phy under the GRF The edp-phy control is a part of the General Register Files and with a recent patch in 4.6 the phy driver can now also handle this correctly, so move the dts node under the GRF as well. Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288.dtsi | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) commit 311b21774f1389f9c34eac4da90c43c95fc2b62b Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Date: Wed Apr 13 19:12:29 2016 -0300 sctp: simplify sk_receive_queue locking SCTP already serializes access to rcvbuf through its sock lock: sctp_recvmsg takes it right in the start and release at the end, while rx path will also take the lock before doing any socket processing. On sctp_rcv() it will check if there is an user using the socket and, if there is, it will queue incoming packets to the backlog. The backlog processing will do the same. Even timers will do such check and re-schedule if an user is using the socket. Simplifying this will allow us to remove sctp_skb_list_tail and get ride of some expensive lockings. The lists that it is used on are also mangled with functions like __skb_queue_tail and __skb_unlink in the same context, like on sctp_ulpq_tail_event() and sctp_clear_pd(). sctp_close() will also purge those while using only the sock lock. Therefore the lockings performed by sctp_skb_list_tail() are not necessary. This patch removes this function and replaces its calls with just skb_queue_splice_tail_init() instead. The biggest gain is at sctp_ulpq_tail_event(), because the events always contain a list, even if it's queueing a single skb and this was triggering expensive calls to spin_lock_irqsave/_irqrestore for every data chunk received. As SCTP will deliver each data chunk on a corresponding recvmsg, the more effective the change will be. Before this patch, with chunks with 30 bytes: netperf -t SCTP_STREAM -H 192.168.1.2 -cC -l 60 -- -m 30 -S 400000 400000 -s 400000 400000 on a 10Gbit link with 1500 MTU: SCTP STREAM TEST from 0.0.0.0 (0.0.0.0) port 0 AF_INET to 192.168.1.1 () port 0 AF_INET Recv Send Send Utilization Service Demand Socket Socket Message Elapsed Send Recv Send Recv Size Size Size Time Throughput local remote local remote bytes bytes bytes secs. 10^6bits/s % S % S us/KB us/KB 425984 425984 30 60.00 137.45 7.34 7.36 52.504 52.608 With it: SCTP STREAM TEST from 0.0.0.0 (0.0.0.0) port 0 AF_INET to 192.168.1.1 () port 0 AF_INET Recv Send Send Utilization Service Demand Socket Socket Message Elapsed Send Recv Send Recv Size Size Size Time Throughput local remote local remote bytes bytes bytes secs. 10^6bits/s % S % S us/KB us/KB 425984 425984 30 60.00 179.10 7.97 6.70 43.740 36.788 Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/sctp.h | 15 --------------- net/sctp/socket.c | 4 +--- net/sctp/ulpqueue.c | 5 +++-- 3 files changed, 4 insertions(+), 20 deletions(-) commit 936d4b41b08f566d0901e81321e4f51ae35c1f45 Merge: 993feee 7d5e142 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 17:21:10 2016 -0400 Merge branch 'mlx5_ifc-updates' Saeed Mahameed says: ==================== mlx5_core: mlx5_ifc updates This series include mlx5_core updates for both net-next and rdma trees for 4.7 kernel cycle. This is the only shared code planned for 4.7 between rdma and net trees. Hopefully, this will prevent future conflicts when merging between ib-next and net-next once 4.7 cycle is over and merge window is opened. Both Mellanox rdma and net submissions will proceed once this series is applied into both trees. Future shared code will be sent to both maintainers as pull requests from Mellanox's kernel.org tree. We have included all the maintainers of respective drivers. Kindly review the change and let us know in case of any review comments. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 7d5e14237a551a5de3d287f2e8db2d044ee81a1a Author: Saeed Mahameed <saeedm@mellanox.com> Date: Mon Apr 11 23:10:22 2016 +0300 net/mlx5: Update mlx5_ifc hardware features Adding the needed mlx5_ifc hardware bits and structs for the following feature: * Add vport to steering commands for SRIOV ACL support * Add mlcr, pcmr and mcia registers for dump module EEPROM * Add support for FCS, baeacon led and disable_link bits to hca caps * Add CQE period mode bit in CQ context for CQE based CQ moderation support * Add umr SQ bit for fragmented memory registration * Add needed bits and caps for Striding RQ support Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/mlx5/mlx5_ifc.h | 146 +++++++++++++++++++++++++++++++++++------- 1 file changed, 124 insertions(+), 22 deletions(-) commit e1c9c62b9a3a761b56359a7437215ae2e9253821 Author: Tariq Toukan <tariqt@mellanox.com> Date: Mon Apr 11 23:10:21 2016 +0300 net/mlx5: Fix mlx5 ifc cmd_hca_cap bad offsets All reserved fields after early_vf_enable are off by 1, since early_vf_enable was not explicitly declared as array of size 1. Reserved field before cqe_zip had a wrong size, it should be 0x80 + 0x3f. Fixes: b0844444590e ("net/mlx5_core: Introduce access function to read internal timer ") Fixes: b4ff3a36d3e4 ("net/mlx5: Use offset based reserved field names in the IFC header file") Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/mlx5/mlx5_ifc.h | 107 ++++++++++++++++++++++-------------------- 1 file changed, 55 insertions(+), 52 deletions(-) commit 6e38e6b26e590b21247c1dd5238be35e7b056ef9 Author: Heiko Stuebner <heiko@sntech.de> Date: Fri Feb 5 20:42:25 2016 +0100 ARM: dts: rockchip: make rk3288-grf a simple-mfd Similar to the pmu, the general register files contain a lot of different setting bits grouped into general registers, but also some somewhat special entities like the controls for some phy-blocks or the io-voltage control. To be able to move these blocks under the grf node where they actually belong, make it a simple-mfd. Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 993feee9795bb8f5368207ce075a9060bcb2c649 Merge: ee1c279 14db81d Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 17:08:09 2016 -0400 Merge branch 'qed-tunneling-offload' Manish Chopra says: ==================== qed/qede: Add tunneling support This patch series adds support for VXLAN, GRE and GENEVE tunnels to be used over this driver. With this support, adapter can perform TSO offload, inner/outer checksums offloads on TX and RX for encapsulated packets. V1->V2 [ Comments from Jesse Gross incorporated ] * Drop general infrastructure change patch. "net: Make vxlan/geneve default udp ports public" * Remove by default Linux default UDP ports configurations in driver. Instead, use general registration APIs for UDP port configurations * Removing .ndo_features_check - we will add it later with proper change. Please consider applying this series to net-next. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 14db81defa1fb6dd2ff154fb9facb4243ad63b95 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Thu Apr 14 01:38:33 2016 -0400 qede: Add fastpath support for tunneling This patch enables netdev tunneling features and adds TX/RX fastpath support for tunneling in driver. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede.h | 1 + drivers/net/ethernet/qlogic/qede/qede_main.c | 101 ++++++++++++++++++++++++--- 2 files changed, 92 insertions(+), 10 deletions(-) commit f7985869209b6d0c71c2cb1fd6fba0522d2c2b61 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Thu Apr 14 01:38:32 2016 -0400 qed: Enable GRE tunnel slowpath configuration Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_main.c | 4 ++++ 1 file changed, 4 insertions(+) commit 9a109dd073582f69eba591888e64aa617340da6f Author: Manish Chopra <manish.chopra@qlogic.com> Date: Thu Apr 14 01:38:31 2016 -0400 qed/qede: Add GENEVE tunnel slowpath configuration support This patch enables GENEVE tunnel on the adapter and add support for driver hooks to configure UDP ports for GENEVE tunnel offload to be performed by the adapter. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/Kconfig | 10 ++++++ drivers/net/ethernet/qlogic/qed/qed_main.c | 5 ++- drivers/net/ethernet/qlogic/qede/qede.h | 2 ++ drivers/net/ethernet/qlogic/qede/qede_main.c | 53 ++++++++++++++++++++++++++++ 4 files changed, 69 insertions(+), 1 deletion(-) commit b18e170cac62cb7c46d6778c50d7335e01ce566f Author: Manish Chopra <manish.chopra@qlogic.com> Date: Thu Apr 14 01:38:30 2016 -0400 qed/qede: Add VXLAN tunnel slowpath configuration support This patch enables VXLAN tunnel on the adapter and add support for driver hooks to configure UDP ports for VXLAN tunnel offload to be performed by the adapter. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/Kconfig | 11 ++++ drivers/net/ethernet/qlogic/qed/qed_main.c | 8 ++- drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 3 +- drivers/net/ethernet/qlogic/qede/qede.h | 4 +- drivers/net/ethernet/qlogic/qede/qede_main.c | 64 ++++++++++++++++++++++- 5 files changed, 86 insertions(+), 4 deletions(-) commit 464f664501816ef5fbbc00b8de96f4ae5a1c9325 Author: Manish Chopra <manish.chopra@qlogic.com> Date: Thu Apr 14 01:38:29 2016 -0400 qed: Add infrastructure support for tunneling This patch adds various structure/APIs needed to configure/enable different tunnel [VXLAN/GRE/GENEVE] parameters on the adapter. Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 46 ++++ drivers/net/ethernet/qlogic/qed/qed_dev.c | 6 +- drivers/net/ethernet/qlogic/qed/qed_dev_api.h | 2 + drivers/net/ethernet/qlogic/qed/qed_hsi.h | 51 ++++- .../net/ethernet/qlogic/qed/qed_init_fw_funcs.c | 127 +++++++++++ drivers/net/ethernet/qlogic/qed/qed_l2.c | 31 +++ drivers/net/ethernet/qlogic/qed/qed_main.c | 2 +- drivers/net/ethernet/qlogic/qed/qed_reg_addr.h | 31 +++ drivers/net/ethernet/qlogic/qed/qed_sp.h | 7 + drivers/net/ethernet/qlogic/qed/qed_sp_commands.c | 254 +++++++++++++++++++++ include/linux/qed/qed_eth_if.h | 10 + 11 files changed, 563 insertions(+), 4 deletions(-) commit ee1c27977284907d40f7f72c2d078d709f15811f Author: Peter Heise <mail@pheise.de> Date: Wed Apr 13 13:52:22 2016 +0200 net/hsr: Added support for HSR v1 This patch adds support for the newer version 1 of the HSR networking standard. Version 0 is still default and the new version has to be selected via iproute2. Main changes are in the supervision frame handling and its ethertype field. Signed-off-by: Peter Heise <peter.heise@airbus.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/if_ether.h | 1 + include/uapi/linux/if_link.h | 1 + net/hsr/Kconfig | 5 +-- net/hsr/hsr_device.c | 80 +++++++++++++++++++++++++------------------ net/hsr/hsr_device.h | 2 +- net/hsr/hsr_forward.c | 43 +++++++++++++++++------ net/hsr/hsr_framereg.c | 30 ++++++++++------ net/hsr/hsr_main.h | 13 ++++++- net/hsr/hsr_netlink.c | 10 ++++-- net/hsr/hsr_slave.c | 4 ++- 10 files changed, 126 insertions(+), 63 deletions(-) commit b2bdaf2bde16537cbdbd5376acecc555f428603f Author: John Garry <john.garry@huawei.com> Date: Fri Apr 15 21:36:38 2016 +0800 hisi_sas: add alloc_dev_quirk_v2_hw() Add custom version of function to allocate device, alloc_dev_quirk_v2_hw(). For sata devices the device id bit0 should be 0. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit 330fa7f3140481463eb4956c38b9a44dfeee52b9 Author: John Garry <john.garry@huawei.com> Date: Fri Apr 15 21:36:37 2016 +0800 hisi_sas: add slot_index_alloc_quirk_v2_hw() Add v2 hw custom function slot_index_alloc_quirk_v2_hw(). SAS devices should have IPTT bit0 equal to 1. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit 685b6d6e678705bf7ff5b7fdd9a904ec7ae9fbe3 Author: John Garry <john.garry@huawei.com> Date: Fri Apr 15 21:36:36 2016 +0800 hisi_sas: add device and slot alloc hw methods Add methods to use HW specific versions of functions to allocate slot and device. HW specific methods are permitted to workaround device id vs IPTT collision issue in v2 hw. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas.h | 3 +++ drivers/scsi/hisi_sas/hisi_sas_main.c | 11 +++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) commit 54c4042852a85713a7bdd8436cc63762049fbb39 Author: Sumit Saxena <sumit.saxena@broadcom.com> Date: Fri Apr 15 00:23:33 2016 -0700 megaraid_sas: driver version upgrade Signed-off-by: Sumit Saxena <sumit.saxena@broadcom.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/megaraid/megaraid_sas.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit bd23d4abe5edf09dfba086d44b7972cf73c14b0b Author: Sumit Saxena <sumit.saxena@broadcom.com> Date: Fri Apr 15 00:23:32 2016 -0700 megaraid_sas: task management code optimizations This patch will do code optmization for task management functions. Below are key changes: 1. Remove reset_device hook as it was not being used and driver was setting this to NULL. 2. Create wrapper functions for task abort and target reset and inside these functions adapter specific calls be made. e.g. fusion adapters support task abort and target reset so task abort and target reset should be issued to fusion adapters only and for MFI adapters, print a message saying feature not supported. Signed-off-by: Sumit Saxena <sumit.saxena@broadcom.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/megaraid/megaraid_sas_base.c | 67 +++++++++++++++++++++---------- 1 file changed, 46 insertions(+), 21 deletions(-) commit 64d0b8e4a6f7e9a3c366c2df93ec1f003d180ca3 Author: Sumit Saxena <sumit.saxena@broadcom.com> Date: Fri Apr 15 00:23:31 2016 -0700 megaraid_sas: call ISR function to clean up pending replies in OCR path In OCR path, before calling chip reset calls function megasas_wait_for_outstanding_fusion to check reason for OCR. In case of firmware FAULT initiated OCR and DCMD timeout initiated timeout, driver will clear any outstanding reply (yet to be processed by driver) in reply queues before going for chip reset. This code is added to handle a scenario when IO timeout initiated adapter reset and management application initiated adapter reset (by sending command to FAULT firmware) happens simultaneously since adapter reset function is safe-guarded by reset_mutex so only thread will be doing controller reset. Consider IO timeout thread gets mutex and proceeds with adapter reset process after disabling interrupts and by the time management application has fired command to firmware to do adapter reset and the same command is completed by firmware but since interrupts are disabled, driver will not get completion and the same command will be in outstanding/pending commands list of driver and refires same command from IO timeout thread after chip reset which will again FAULT firmware and eventually causes kill adapter. Signed-off-by: Sumit Saxena <sumit.saxena@broadcom.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/megaraid/megaraid_sas_fusion.c | 2 ++ 1 file changed, 2 insertions(+) commit c3e385a1b985a9202ba7fbd0bdbdcb909905d00c Author: Sumit Saxena <sumit.saxena@broadcom.com> Date: Fri Apr 15 00:23:30 2016 -0700 megaraid_sas: reduce memory footprints in kdump mode This patch will reduce memory footprints of megaraid_sas driver when booted in kdump mode. Driver will not allocate memory for optional and perfromance oriented features. Below are key changes done in megaraid_sas driver to do this: 1. Limit Controller's queue depth to 100 in kdump mode. 2. Do not allocate memory for system info buffer and PD info buffer. 3. Disable performance oriented features e.g. Disable RDPQ mode, disable dual queue depth, restrict to single MSI-x vector. Signed-off-by: Sumit Saxena <sumit.saxena@broadcom.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/megaraid/megaraid_sas.h | 2 ++ drivers/scsi/megaraid/megaraid_sas_base.c | 48 +++++++++++++++++------------ drivers/scsi/megaraid/megaraid_sas_fusion.c | 3 ++ 3 files changed, 34 insertions(+), 19 deletions(-) commit 1f275f976fdc04bf1bfd06929d10852b1b05decc Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Thu Apr 14 10:27:14 2016 -0700 scsi_dh_alua: Declare local functions static This patch avoids that building with W=1 causes gcc to report the following type of warning: no previous prototype for ... [-Wmissing-prototypes] Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Cc: Hannes Reinecke <hare@suse.de> Cc: Christoph Hellwig <hch@lst.de> Cc: Ewan Milne <emilne@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/device_handler/scsi_dh_alua.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 23409bd4a8b051e28d0106c7a83f362617452098 Author: Tina Ruchandani <ruchandani.tina@gmail.com> Date: Wed Apr 13 00:01:40 2016 -0700 mpt3sas: Remove usage of 'struct timeval' 'struct timeval' will have its tv_sec value overflow on 32-bit systems in year 2038 and beyond. This patch replaces the use of struct timeval for computing mpi_request.TimeStamp, and instead uses ktime_t which provides 64-bit seconds value. The timestamp computed remains unaffected (milliseconds since Unix epoch). Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Acked-by: Sathya Prakash <sathya.prakash@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mpt3sas/mpt3sas_base.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e83596b41cb9729837468a1c14de56a5529a2aa6 Author: David Daney <david.daney@cavium.com> Date: Wed Apr 13 14:26:56 2016 -0700 pm80xx: Remove bogus address masking in pm8001_ioremap() It is unclear what the original intent of the masking was, but it is clearly incorrect to truncate a physical address before calling ioremap(). On systems where there are valid physical address bits above bit-31 (arm64 for example) the result is an eventual OOPs when initializing the driver. Remove the bogus code to fix it. Signed-off-by: David Daney <david.daney@cavium.com> Acked-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/pm8001/pm8001_init.c | 2 -- 1 file changed, 2 deletions(-) commit 5ea33eb573c9858cdebfb69626cc8621c7468f9e Author: Tina Ruchandani <ruchandani.tina@gmail.com> Date: Mon Jan 25 23:00:20 2016 +0100 qla2xxx: Remove use of 'struct timeval' struct register_host_info stores a 64-bit UTC system time timestamp. This patch removes the use of 'struct timeval' to obtain that timestamp as its tv_sec value will overflow on 32-bit systems in year 2038 beyond. The patch uses ktime_get_real_seconds() which returns a 64-bit seconds value. Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Acked-by: Himanshu Madhani <himanshu.madhani@qlogic.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/qla2xxx/qla_mr.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 33e56e48ea3b3f58358d12b28f36474040325f0c Author: John Garry <john.garry@huawei.com> Date: Fri Apr 8 17:23:15 2016 +0800 hisi_sas: update driver version to 1.4 Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Zhangfei Gao <zhangfei.gao@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f76a0b49402b39b2d314ced52aac2f02d6a6c45d Author: John Garry <john.garry@huawei.com> Date: Fri Apr 8 17:23:14 2016 +0800 hisi_sas: for v2 hw only set ITCT qw2 for SAS device This patch fixes the ITCT table setup as it should be configured differently for SAS and SATA devices. For SATA disks there is no need to set qw2 (already zeroed). Also, link parameters for Bus inactive limit, max connection time limit, and reject to open limit timers parameters are changed to match global config register, MAX_CON_TIME_LIMIT_TIME, as recommended by hw team. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Zhangfei Gao <zhangfei.gao@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 11826e5dc7b7297164dd9dd6d735c6ff6acb4b86 Author: John Garry <john.garry@huawei.com> Date: Fri Apr 8 17:23:13 2016 +0800 hisi_sas: add v2 hw support for >4 SATA phys This patch adds support for directly attaching SATA disks to phy 4-8. The problem was that only registers concerned with phy 0-3 were being considered in sata_int_v2_hw(). The issue was not detected previously as the development board only exposed phy 0-3; the new board provides access to 8 phys. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Zhangfei Gao <zhangfei.gao@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 3a429d5ab60966cf75d9b99648700823c514b7ad Author: John Garry <john.garry@huawei.com> Date: Fri Apr 8 17:23:12 2016 +0800 hisi_sas: fix v2 hw multiple SATA disk issue Intermittently it is found that when multiple SATA disks are directly connected to the host that some disks are not detected. The problem is that all set bitfields in ENT_INT_SRC1 are cleared for all phys in sata_int_v2_hw() - it should clear the set bit for the phy being serviced. Also unnecessary double-write to ENT_INT_SRC1 and ENT_INT_SRC_MSK1 is removed (remaining writes are done at end label). Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Zhangfei Gao <zhangfei.gao@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 7524926826104b9e0665eaecd50f76889b89a72e Author: John Garry <john.garry@huawei.com> Date: Fri Apr 8 17:23:11 2016 +0800 hisi_sas: use device linkrate in MCR for v2 hw Contrary to the field name, the MCR (max connection rate) in the ITCT should hold the device linkrate (linkrate of the connected phy), and not the max linkrate. This fixes an issue seen where some SATA drives connected through an expander which would not attach. Signed-off-by: John Garry <john.garry@huawei.com> Reviewed-by: Zhangfei Gao <zhangfei.gao@linaro.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/hisi_sas/hisi_sas_v2_hw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9b1d6c8950021ab007608d455fc9c398ecd25476 Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 4 14:48:11 2016 -0700 lib: scatterlist: move SG pool code from SCSI driver to lib/sg_pool.c Now it's ready to move the mempool based SG chained allocator code from SCSI driver to lib/sg_pool.c, which will be compiled only based on a Kconfig symbol CONFIG_SG_POOL. SCSI selects CONFIG_SG_POOL. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/Kconfig | 1 + drivers/scsi/scsi_lib.c | 137 ----------------------------------- include/linux/scatterlist.h | 25 +++++++ include/scsi/scsi.h | 19 ----- lib/Kconfig | 7 ++ lib/Makefile | 1 + lib/sg_pool.c | 172 ++++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 206 insertions(+), 156 deletions(-) commit 65e8617fba17732b4c68d3369a621725838b6f28 Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 4 14:48:10 2016 -0700 scsi: rename SCSI_MAX_{SG, SG_CHAIN}_SEGMENTS Rename SCSI_MAX_SG_SEGMENTS to SG_CHUNK_SIZE, which means the amount we fit into a single scatterlist chunk. Rename SCSI_MAX_SG_CHAIN_SEGMENTS to SG_MAX_SEGMENTS. Will move these 2 generic definitions to scatterlist.h later. Reviewed-by: Christoph Hellwig <hch@lst.de> Acked-by: Bart Van Assche <bart.vanassche@sandisk.com> (for ib_srp changes) Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Acked-by: Tejun Heo <tj@kernel.org> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/ata/pata_icside.c | 2 +- drivers/infiniband/ulp/srp/ib_srp.c | 4 ++-- drivers/scsi/arm/cumana_2.c | 2 +- drivers/scsi/arm/eesox.c | 2 +- drivers/scsi/arm/powertec.c | 2 +- drivers/scsi/esas2r/esas2r_main.c | 4 ++-- drivers/scsi/hisi_sas/hisi_sas.h | 2 +- drivers/scsi/mpt3sas/mpt3sas_base.c | 4 ++-- drivers/scsi/mpt3sas/mpt3sas_base.h | 2 +- drivers/scsi/scsi_debug.c | 2 +- drivers/scsi/scsi_lib.c | 34 +++++++++++++++++----------------- drivers/usb/storage/scsiglue.c | 2 +- include/scsi/scsi.h | 8 ++++---- include/scsi/scsi_host.h | 2 +- 14 files changed, 36 insertions(+), 36 deletions(-) commit 001d63be61c3b5a0413a46bacafbfc60c353951a Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 4 14:48:09 2016 -0700 scsi: rename SG related struct and functions Rename SCSI specific struct and functions to more genenic names. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Sagi Grimberg <sgi@grimberg.me> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_lib.c | 52 ++++++++++++++++++++++++------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) commit 22cc3d4c6f4c529f4bf17445c60893b13e7611fb Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 4 14:48:08 2016 -0700 scsi: replace "mq" with "first_chunk" in SG functions Parameter "bool mq" is block driver specific. Change it to "first_chunk" to make it more generic. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_lib.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 91dbc08d64fba7c1426a32be4c57ebb63c4be124 Author: Ming Lin <ming.l@ssi.samsung.com> Date: Mon Apr 4 14:48:07 2016 -0700 scsi: replace "scsi_data_buffer" with "sg_table" in SG functions Replace parameter "struct scsi_data_buffer" with "struct sg_table" in SG alloc/free functions to make them generic. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_lib.c | 41 +++++++++++++++++++++++------------------ 1 file changed, 23 insertions(+), 18 deletions(-) commit 98be565f1c19747bfc463f668310ff89beb28696 Author: Hannes Reinecke <hare@suse.de> Date: Fri Apr 8 08:14:54 2016 +0200 zfcp: Revert to original scanning behaviour zfcp has its own mechanism for selective scanning, so revert to the original scanning behaviour to not confuse users. Fixes: 4e91e876e9b8b6eb4255aa0d690778a89d3f1d28 Suggested-by: Benjamin Block <bblock@linux.vnet.ibm.com> Signed-off-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Benjamin Block <bblock@linux.vnet.ibm.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/s390/scsi/zfcp_unit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7517b26c65eb4866ec9a02e9cc2b416c94326313 Author: Leonid Moiseichuk <leonid.moiseichuk@gmail.com> Date: Thu Apr 7 21:52:25 2016 +0300 mvsas: Generalize Marvell 9485 in pci_device_id Claim Marvell 9485 controllers regardless of subdevice ID. Tested on ASUS P9A-I/C2550/SAS/4L which uses vendor-specific 1043:8635. [mkp: Tweaked commit message] Signed-off-by: Leonid Moiseichuk <leonid.moiseichuk@gmail.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/mvsas/mv_init.c | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) commit 63f21677965ab5b888ca15be872fce294c6802d7 Author: Chad Dupuis <chad.dupuis@qlogic.com> Date: Thu Apr 7 09:08:00 2016 -0400 bnx2fc: Update version number to 2.10.3. Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2fc/bnx2fc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d02327a863168647b9e6fde610c4730ff4837f9e Author: Chad Dupuis <chad.dupuis@qlogic.com> Date: Thu Apr 7 09:07:59 2016 -0400 bnx2fc: Check sc_cmd device and host pointer before returning the command to the mid-layer. When we are in connection recovery and the internal command timer on a request pops, either the scsi_cmnd->device or scsi_cmnd->device->host back pointers may be NULL as the device that the command that the request was submitted on may have been subsequently reaped due to the connection recovery. This can cause one or both of the pointers above to be NULL and cause a system crash if we try to return the command to the midlayer. Instead, double check the pointers before the return to the midlayer so as to prevent the crash and let the upper layers finish the session recovery and rediscover the device. Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2fc/bnx2fc_io.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit f72464d128efd22301ce58b204f3f1808013a536 Author: Chad Dupuis <chad.dupuis@qlogic.com> Date: Thu Apr 7 09:07:58 2016 -0400 bnx2fc: Print netdev device name when FCoE is successfully initialized. Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 2 ++ 1 file changed, 2 insertions(+) commit 3f12f76ee83b3388d2e6f97a9e8c4c642656e277 Author: Chad Dupuis <chad.dupuis@qlogic.com> Date: Thu Apr 7 09:07:57 2016 -0400 bnx2fc: Print when we send a fip keep alive. Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 10755d3f47a9b28639f2e3d29a09ff2a0969657d Author: Joe Carnuccio <joe.carnuccio@qlogic.com> Date: Thu Apr 7 09:07:56 2016 -0400 bnx2fc: Add driver tunables. Per customer request, add the following driver tunables: o devloss_tmo o max_luns o queue_depth o tm_timeout tm_timeout is set per scsi_host in /sys/class/scsi_host/hostX/tm_timeout. Signed-off-by: Joe Carnuccio <joe.carnuccio@qlogic.com> Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/bnx2fc/bnx2fc.h | 1 + drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 79 ++++++++++++++++++++++++++++++++++++++- drivers/scsi/bnx2fc/bnx2fc_io.c | 2 +- 3 files changed, 80 insertions(+), 2 deletions(-) commit e4c36ad756ec2de36b05c66bb50ed4ff47b0fdb0 Author: Hannes Reinecke <hare@suse.de> Date: Fri Apr 1 08:57:37 2016 +0200 scsi: vpd pages are mandatory for SPC-2 VPD pages 0x0 and 0x83 are mandatory even for SPC-2, so we should be lowering the restriction to avoid having to whitelist every SPC-2 compliant device. Signed-off-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> include/scsi/scsi_device.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 305c2e71b3d733ec065cb716c76af7d554bd5571 Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Tue Apr 5 11:50:45 2016 +0200 Revert "scsi: fix soft lockup in scsi_remove_target() on module removal" Now that we've done a more comprehensive fix with the intermediate target state we can remove the previous hack introduced with commit 90a88d6ef88e ("scsi: fix soft lockup in scsi_remove_target() on module removal"). Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Cc: stable@vger.kernel.org Reviewed-by: Ewan D. Milne <emilne@redhat.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_sysfs.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit f3e459d16a8493b617ccf2a940330279679e0291 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 17:52:34 2016 -0300 perf trace: Bump --mmap-pages when --call-graph is used by the root user To reduce the chances we'll overflow the mmap buffer, manual fine tuning trumps this. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-wxygbxmp1v9mng1ea28wet02@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 4 ++++ tools/perf/builtin-trace.c | 10 +++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) commit f05795d3d771f30a7bdc3a138bf714b06d42aa95 Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Tue Apr 5 11:50:44 2016 +0200 scsi: Add intermediate STARGET_REMOVE state to scsi_target_state Add intermediate STARGET_REMOVE state to scsi_target_state to avoid running into the BUG_ON() in scsi_target_reap(). The STARGET_REMOVE state is only valid in the path from scsi_remove_target() to scsi_target_destroy() indicating this target is going to be removed. This re-fixes the problem introduced in commits bc3f02a795d3 ("[SCSI] scsi_remove_target: fix softlockup regression on hot remove") and 40998193560d ("scsi: restart list search after unlock in scsi_remove_target") in a more comprehensive way. [mkp: Included James' fix for scsi_target_destroy()] Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Fixes: 40998193560dab6c3ce8d25f4fa58a23e252ef38 Cc: stable@vger.kernel.org Reported-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Tested-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Reviewed-by: Ewan D. Milne <emilne@redhat.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: James Bottomley <jejb@linux.vnet.ibm.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_scan.c | 1 + drivers/scsi/scsi_sysfs.c | 2 ++ include/scsi/scsi_device.h | 1 + 3 files changed, 4 insertions(+) commit f5e7150cd9a7779a54b192d21afb9245384db8bc Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 17:46:31 2016 -0300 perf evlist: Expose perf_event_mlock_kb_in_pages() helper When the user doesn't set --mmap-pages, perf_evlist__mmap() will do it by reading the maximum possible for a non-root user from the /proc/sys/kernel/perf_event_mlock_kb file. Expose that function so that 'perf trace' can, for root users, to bump mmap-pages to a higher value for root, based on the contents of this proc file. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-xay69plylwibpb3l4isrpl1k@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 42 +++++++++++++++++++++++++----------------- tools/perf/util/evlist.h | 2 ++ 2 files changed, 27 insertions(+), 17 deletions(-) commit 125c8d1233b7dd4688f14dd992d724c20d055dee Merge: ac18dd9 8804b27 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 16:45:45 2016 -0400 Merge branch 'tcp-synflood-perf' Eric Dumazet says: ==================== tcp: final work on SYNFLOOD behavior In the first patch, I remove the costly association of SYNACK+COOKIES to a listener. I believe other parts of the stack should be ready. The second patch removes a useless write into listener socket in tcp_rcv_state_process(), incurring false sharing in tcp_conn_request() Performance under SYNFLOOD goes from 3.2 Mpps to 6 Mpps. Test was using a single TCP listener, on a host with 8 RX queues on the NIC, and 24 cores (48 ht) ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8804b2722dc5d6f9b7ba0a9e812eae9ee5ce95bc Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 13 22:05:40 2016 -0700 tcp: remove false sharing in tcp_rcv_state_process() Last known hot point during SYNFLOOD attack is the clearing of rx_opt.saw_tstamp in tcp_rcv_state_process() It is not needed for a listener, so we move it where it matters. Performance while a SYNFLOOD hits a single listener socket went from 5 Mpps to 6 Mpps on my test server (24 cores, 8 NIC RX queues) Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_input.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b3d051477cf94e9d71d6acadb8a90de15237b9c1 Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 13 22:05:39 2016 -0700 tcp: do not mess with listener sk_wmem_alloc When removing sk_refcnt manipulation on synflood, I missed that using skb_set_owner_w() was racy, if sk->sk_wmem_alloc had already transitioned to 0. We should hold sk_refcnt instead, but this is a big deal under attack. (Doing so increase performance from 3.2 Mpps to 3.8 Mpps only) In this patch, I chose to not attach a socket to syncookies skb. Performance is now 5 Mpps instead of 3.2 Mpps. Following patch will remove last known false sharing in tcp_rcv_state_process() Fixes: 3b24d854cb35 ("tcp/dccp: do not touch listener sk_refcnt under synflood") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 9 +++++++-- net/ipv4/tcp_input.c | 7 ++++--- net/ipv4/tcp_ipv4.c | 4 ++-- net/ipv4/tcp_output.c | 16 ++++++++++++---- net/ipv6/tcp_ipv6.c | 4 ++-- 5 files changed, 27 insertions(+), 13 deletions(-) commit ac18dd9e842294377dbaf1e8d169493567a81fa1 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Sat Apr 9 17:27:45 2016 +0530 qlge: Replace create_singlethread_workqueue with alloc_ordered_workqueue Replace deprecated create_singlethread_workqueue with alloc_ordered_workqueue. Work items include getting tx/rx frame sizes, resetting MPI processor, setting asic recovery bit so ordering seems necessary as only one work item should be in queue/executing at any given time, hence the use of alloc_ordered_workqueue. WQ_MEM_RECLAIM flag has been set since ethernet devices seem to sit in memory reclaim path, so to guarantee forward progress regardless of memory pressure. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qlge/qlge_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0818556cd0afe4104139eb094f4112f9781c0f7e Merge: 25fb0b6 34b9cd6 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 16:09:07 2016 -0400 Merge branch 'tipc-link-setup-improvements' Jon Maloy says: ==================== tipc: improvements to the link setup algorithm This series addresses some smaller issues regarding the link setup algorithm. The first commit fixes a rare bug we have discovered during testing; the second one may have some future impact on cluster scalabilty, while remaining ones can be regarded as cosmetic in a wider sense of the word. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 34b9cd64c889d41eb990aec33fc185cab706c9b0 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Fri Apr 15 13:33:07 2016 -0400 tipc: let first message on link be a state message According to the link FSM, a received traffic packet can take a link from state ESTABLISHING to ESTABLISHED, but the link can still not be fully set up in one atomic operation. This means that even if the the very first packet on the link is a traffic packet with sequence number 1 (one), it has to be dropped and retransmitted. This can be avoided if we let the mentioned packet be preceded by a LINK_PROTOCOL/STATE message, which takes up the endpoint before the arrival of the traffic. We add this small feature in this commit. This is a fully compatible change. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/link.c | 6 +++--- net/tipc/link.h | 2 +- net/tipc/node.c | 5 ++++- 3 files changed, 8 insertions(+), 5 deletions(-) commit de7e07f9ee14f47d05aa43046404c2904f0247dc Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Fri Apr 15 13:33:06 2016 -0400 tipc: ensure that first packets on link are sent in order In some link establishment scenarios we see that packet #2 may be sent out before packet #1, forcing the receiver to demand retransmission of the missing packet. This is harmless, but may cause confusion among people tracing the packet flow. Since this is extremely easy to fix, we do so by adding en extra send call to the bearer immediately after the link has come up. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/node.c | 4 ++++ 1 file changed, 4 insertions(+) commit 42b18f605feaf7aa1825b35656bb7d6fdc132b45 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Fri Apr 15 13:33:05 2016 -0400 tipc: refactor function tipc_link_timeout() The function tipc_link_timeout() is unnecessary complex, and can easily be made more readable. We do that with this commit. The only functional change is that we remove a redundant test for whether the broadcast link is up or not. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/link.c | 36 ++++++++++++++++-------------------- 1 file changed, 16 insertions(+), 20 deletions(-) commit 88e8ac7000dc7ccf99975cc4070907e26a1027f9 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Fri Apr 15 13:33:04 2016 -0400 tipc: reduce transmission rate of reset messages when link is down When a link is down, it will continuously try to re-establish contact with the peer by sending out a RESET or an ACTIVATE message at each timeout interval. The default value for this interval is currently 375 ms. This is wasteful, and may become a problem in very large clusters with dozens or hundreds of nodes being down simultaneously. We now introduce a simple backoff algorithm for these cases. The first five messages are sent at default rate; thereafter a message is sent only each 16th timer interval. This will cover the vast majority of link recycling cases, since the endpoint starting last will transmit at the higher speed, and the link should normally be established well be before the rate needs to be reduced. The only case where we will see a degradation of link re-establishment times is when the endpoints remain intact, and a glitch in the transmission media is causing the link reset. We will then experience a worst-case re-establishing time of 6 seconds, something we deem acceptable. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/link.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 634696b197411e7a95b346d6e5c21841f29fcedd Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Fri Apr 15 13:33:03 2016 -0400 tipc: guarantee peer bearer id exchange after reboot When a link endpoint is going down locally, e.g., because its interface is being stopped, it will spontaneously send out a RESET message to its peer, informing it about this fact. This saves the peer from detecting the failure via probing, and hence gives both speedier and less resource consuming failure detection on the peer side. According to the link FSM, a receiver of a RESET message, ignoring the reason for it, must now consider the sender ready to come back up, and starts periodically sending out ACTIVATE messages to the peer in order to re-establish the link. Also, according to the FSM, the receiver of an ACTIVATE message can now go directly to state ESTABLISHED and start sending regular traffic packets. This is a well-proven and robust FSM. However, in the case of a reboot, there is a small possibilty that link endpoint on the rebooted node may have been re-created with a new bearer identity between the moment it sent its (pre-boot) RESET and the moment it receives the ACTIVATE from the peer. The new bearer identity cannot be known by the peer according to this scenario, since traffic headers don't convey such information. This is a problem, because both endpoints need to know the correct value of the peer's bearer id at any moment in time in order to be able to produce correct link events for their users. The only way to guarantee this is to enforce a full setup message exchange (RESET + ACTIVATE) even after the reboot, since those messages carry the bearer idientity in their header. In this commit we do this by introducing and setting a "stopping" bit in the header of the spontaneously generated RESET messages, informing the peer that the sender will not be immediately ready to re-establish the link. A receiver seeing this bit must act as if this were a locally detected connectivity failure, and hence has to go through a full two- way setup message exchange before any link can be re-established. Although never reported, this problem seems to have always been around. This protocol addition is fully backwards compatible. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/link.c | 10 +++++++++- net/tipc/msg.h | 10 ++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) commit 056149932602ef905f1e26fc4fe242ef0533a597 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 16:41:19 2016 -0300 perf trace: Make --(min,max}-stack imply "--call-graph dwarf" If one uses: # perf trace --min-stack 16 Then it implicitly means that callgraphs should be enabled, and the best option in terms of widespread availability is "dwarf". Further work needed to choose a better alternative, LBR, in capable systems. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-xtjmnpkyk42npekxz3kynzmx@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 6 ++++++ tools/perf/builtin-trace.c | 13 ++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) commit 0883e820a0ac18e04f036dbebc3580351d7fd6cf Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 16:37:17 2016 -0300 perf record: Export record_opts based callchain parsing helper To be able to call it outside option parsing, like when setting a default --call-graph parameter in 'perf trace' when just --min-stack is used. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-xay69plylwibpb3l4isrpl1k@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 35 ++++++++++++++++++++--------------- tools/perf/util/callchain.h | 6 ++++++ 2 files changed, 26 insertions(+), 15 deletions(-) commit 171a900c4eb7b34667e64ffed316a50425b45581 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:21 2016 -0400 rtl8xxxu: MAINTAINERS: Update to point to the active devel branch Update the MAINTAINERS info to reflect active development of the rtl8xxxu driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 265697eb2f1b6c472c4b09ff7e008bc8ab145b4f Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:20 2016 -0400 rtl8xxxu: Pause TX before calling disable_rf() All the disable_rf() functions were setting REG_TXPAUSE to 0xff to stop transmission. Do it centrally before calling disable_rf() instead. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit ae5c01fd2fd816486169787440bf900d1b703230 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:19 2016 -0400 rtl8xxxu: Implement rtl8192e_enable_rf() This implements an 8192eu specific enable_rf() function. The 8192eu is not a combo device, so no need for doing the BT specific bits needed by the 8723bu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 39 +++++++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) commit 6a62f9d5273dbc8ec776717a73a8a223b9e5f38e Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:18 2016 -0400 rtl8xxxu: Fix OOPS if user tries to add device via /sys This driver relies on driver_info in struct usb_device_id, so allowing adding a device via /sys/bus/usb/drivers/rtl8xxxu/new_id will cause a NULL pointer dereference. Set .no_dynamic_id = 1 to disable hot add of USB IDs. Reported-by: Xose Vazquez Perez <xose.vazquez@gmail.com> Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 1 + 1 file changed, 1 insertion(+) commit cabb550e2b97b8ea42124a93d4665ca052f3e3ff Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:17 2016 -0400 rtl8xxxu: Fix 8188RU support The 8188RU does not like PAPE to be enabled, while all the other gen1 parts seem to require it. This makes the RTL8188RU able to associate for me. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 21 ++++++++++++++------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 15 insertions(+), 7 deletions(-) commit 2fc0b8e5a17dc415508d918eeeb1aa47443ae642 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:16 2016 -0400 rtl8xxxu: Add TX power base values for gen1 parts Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 118 ++++++++++++++++++++--- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 26 +++++ 2 files changed, 130 insertions(+), 14 deletions(-) commit b9f9d6992f8338e919c977e4e18473f57dcb874d Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:15 2016 -0400 rtl8xxxu: Set register 0xfe10 on rtl8192cu based parts This register is undocumented in the vendor code, but it is set unconditionally for all 8192cu/8188cu/8188ru parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 ++ 1 file changed, 2 insertions(+) commit eb18806261da3de958b5569fb6d93ed0d773028b Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:14 2016 -0400 rtl8xxxu: Update copyright statement to include 2016 Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 8cae2f1da87c82b2a0031f4d19c142e7bc22f1d7 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:13 2016 -0400 rtl8xxxu: Unregister from mac80211 before shutting down the device This fixes a long standing bug where mac80211 would send disconnect packets to the device, after we had shut down the device. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) commit 8e25496090431553ce2200f53bbe194b9e0a19d2 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:12 2016 -0400 rtl8xxxu: Match 8723bu power down sequence to vendor driver In particular set APS_FSMCO_WLON_RESET in the right register, and do not overwrite too much of REG_CR. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit 8d95c8084f5621240006f730986a3346b7794863 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:11 2016 -0400 rtl8xxxu: Use rtl_chip == RTL8188R to identify high PA parts This is simpler than checking for RTL8188C && hi_pa. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 78a8421959af5e13dd96493e3b74d8d7c7406609 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:10 2016 -0400 rtl8xxxu: Apply 8188RU workaround for UMC B cut parts correctly This patch was being missed since rtl_chip will never match RTL8188C if hi_pa is true. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b591e982bc44baf79f6ebb963eb47fe5e223e8e7 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:09 2016 -0400 rtl8xxxu: For devices with external PA (8188RU), limit CCK TX power Per the vendor driver, devices with an external PA needs limiting it's TX power to 0x20. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 4062b8ffec36df80d808d3bc3352e0f9c9abd3de Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:08 2016 -0400 rtl8xxxu: Move PHY RF init into device specific functions Load the RF table in init_phy_rf(), which allows for applying device specific RF hacks in the same place. Getting rid of more ugly if () clutter. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 133 ++++++++++++++--------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 80 insertions(+), 54 deletions(-) commit 37ba4b6265ea0aa6c3369e4cf736ecbac31c40c9 Author: Colin Ian King <colin.king@canonical.com> Date: Thu Apr 14 16:37:07 2016 -0400 rtl8xxxu: fix uninitialized return value in ret several functions are not initializing a return status in ret resulting in garbage to be returned instead of 0 for success. Currently, the calls to these functions are not checking the return, however, it seems prudent to return the correct status in case they are to be checked at a later date. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e1d70c9b04000ee122c450627ed0614c676339a5 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 16:37:06 2016 -0400 rtl8xxxu: Mark 0x050d:0x1004 as tested This dongle was tested successfully by Andrea Merello Reported-by: Andrea Merello <andrea.merello@gmail.com> Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit a39b683966559902dab4ea7d24b3223102d6971f Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:07 2016 -0400 Re-enable 8192eu support Revert "rtl8xxxu: Temporarily disable 8192eu device init" This reverts commit ccfe1e85322090649d2fae599e55300c1512bf15. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 4 ---- 1 file changed, 4 deletions(-) commit 46b378318de9e8e9d3b479e6adb2cec55c01c2ef Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:06 2016 -0400 rtl8xxxu: 8192eu Fix bug in LDPC RX hang fix Write the adjusted value back to the correct register Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 31133da702e4229acbd813350660f3053daa57c6 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:05 2016 -0400 rtl8xxxu: Remove unneeded 8192eu hack This removes an unneeded hack for 8192eu, and allows for initializing REG_FPGA0_XAB_RF_SW_CTRL at the same point as it is done for all other parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) commit 747bf237592cd7237e52692772a3fe3abeca0872 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:04 2016 -0400 rtl8xxxu: Split USB quirks into gen1 and gen2 quirks This removes a bunch of if () spaghetti and re-applies the USB bus quirks for 8188/8192 that had gotten lost. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 95 ++++++++++++++---------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 56 insertions(+), 40 deletions(-) commit 9b323ee97af6e0c982b57ba0a21db14728dd4476 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:03 2016 -0400 rtl8xxxu: Make PBP tuning a fileops parameter Rather than scattering the code with #ifdefs, use the fileops structure to hold device specific PBP values. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 17 ++++++++++------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 ++ 2 files changed, 12 insertions(+), 7 deletions(-) commit a77372069119061313b4815d119b5fbde0676dbb Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:02 2016 -0400 rtl8xxxu: Do not backup RF_MODE_AG when it's never being used This was expired by the vendor driver, but we never ended up using the backed up value. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 3 --- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 - 2 files changed, 4 deletions(-) commit 24e8e7ec331d04c329048d3b85034c54d23f4fab Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:01 2016 -0400 rtl8xxxu: Store device specific TRXFF boundary in the fileops This removes another case of ugly if () clutter Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 11 +++++------ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 6 insertions(+), 6 deletions(-) commit b84cac16f0f42b9b3f6210984c939f712c471026 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:59:00 2016 -0400 rtl8xxxu: REG_LDOA15_CTRL is only used on gen1 parts Move setting it to rtl8723au_init_phy_bb() Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) commit c82f8d113e354588fe3351b10e0c1ea154f5c600 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:59 2016 -0400 rtl8xxxu: Move loading of AGC table to device specific function This moves the loading of the AGC table into init_phy_bb() and reduces the if() clutter. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 26 +++++++++++------------- 1 file changed, 12 insertions(+), 14 deletions(-) commit ade0dedde11923e1d1f17bd81395b627821ad49c Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:58 2016 -0400 rtl8xxxu: Load AGC table before patching for 1T2R parts This should get the order right and avoid patching something that is later overwritten. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 28 ++++++++++++------------ 1 file changed, 14 insertions(+), 14 deletions(-) commit cb8772504a27d7ada67840efe5439f3df3621e13 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:57 2016 -0400 rtl8xxxu: Split rtl8xxxu_init_phy_bb() into device specific functions This reduces the if () clutter. Longer term it probably makes sense to split this between gen1 (8723au/8188cu/8192cu) and gen2 (8192eu/8723bu) devices. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 134 +++++++++++++---------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 77 insertions(+), 58 deletions(-) commit bd8fe40cc4f30f3f0982345135d97a676d1d3652 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:56 2016 -0400 rtl8xxxu: Use descriptive bits for setting RX paths for 1T2R parts This reduce the use of magic values a little. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 4 +++- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 4 ++++ 2 files changed, 7 insertions(+), 1 deletion(-) commit 9068308ad185a3c2c5d7beb77146b6df7b96b9c6 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:55 2016 -0400 rtl8xxxu: Correctly mask what was read from REG_CCK0_AFE_SETTING The old code incorrectly wiped out bits 0-23 by mistake when setting the RX path for 1T parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 15f9dc99237df4b29f000464c35925bb0a56ead7 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:54 2016 -0400 rtl8xxxu: Remove unused 8723bu path B IQ calibration code The 8723bu is a combo WiFi/BT dongle, and path B is not used for WiFi, so no point in calibrating it. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 76 +----------------------- 1 file changed, 3 insertions(+), 73 deletions(-) commit fe62171fb5cac42d0ff665e61b2735965e9efd45 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:53 2016 -0400 rtl8xxxu: Remove misleading warning from rtl8192eu_phy_iqcalibrate() No actual code flow change, but no need to warn about something that isn't a prioblem. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 -- 1 file changed, 2 deletions(-) commit a49c7ce183cd78c9786348f8dea3d8027cee8177 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:52 2016 -0400 rtl8xxxu: Name RX descriptor types rxdesc16/rxdesc24 This caught a bug where too little memory was allocated for RX urbs for parts using 24 byte RX descriptors Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 38 ++++++++++++++---------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 5 ++-- 2 files changed, 25 insertions(+), 18 deletions(-) commit 2cb79eb74f08f0217a6c4f21ddc42627016771ff Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:51 2016 -0400 rtl8xxxu: byteswap the entire RX descriptor for 24 byte RX descriptors This shouldn't affect little endian system, but may have prevented the driver working on big endian systems for devices with the larger 24 byte RX descriptors. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) commit 55c0b6ae1e7b1a402f23ca8fafa1874f854b4834 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:50 2016 -0400 rtl8xxxu: Use has_s0s1 for REG_S0S1 issues only Instead use tx_desc_size() to distinguish between gen1 (8723a/8192c/8188c) and gen2 (8723b/8192e) parts. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 57e42a21a941decc15f1198db64fe3959b066096 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:49 2016 -0400 rtl8xxxu: Implment rtl8192e_set_tx_power() 8192eu is a 2T part, so setting TX power for path A only, as done by rtl8723bu_set_tx_power() is not sufficient. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 78 +++++++++++++++++++++++- 1 file changed, 77 insertions(+), 1 deletion(-) commit 5bdb6b0859887bad5c83639ca9fb2d5fd0d5a8a0 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:48 2016 -0400 rtl8xxxu: Do not try to set REG_LEDCFG2 on 8192eu Presumably 8192eu devices do not have leds, so do not enable them. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit b816901b3d20e9e2941b130139d440953c3b0ba8 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:47 2016 -0400 rtl8xxxu: Do not init FPGA0_TX_INFO on 8192eu Like the 8723bu, the vendor driver does not set FPGA0_TX_INFO for 8192eu in the init sequence. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2e7c7b347d93e41a2c4adf9350da6a351f585810 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:46 2016 -0400 rtl8xxxu: Do not set REG_PBP on 8192eu The vendor driver does not set REG_PBP on 8192eu. Whether this is due to the device not supporting it or simply an oversight in the vendor driver is not clear. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 0486e80b2a447fc94687505ca106091b15e61651 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:45 2016 -0400 rtl8xxxu: Reorder chip quirks to follow flow of 8192eu driver Another flow order change to match the vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 42 ++++++++++++------------ 1 file changed, 21 insertions(+), 21 deletions(-) commit 89c2a097df34362a5e8373749a2f81ca2503b598 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:44 2016 -0400 rtl8xxxu: Implement generic init_queue_reserved_page() function Longer term we should switch all the chips over to use this function instead of the random chip specific ifdef hacks. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 75 ++++++++++++++++++---- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 9 +++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 2 +- 3 files changed, 71 insertions(+), 15 deletions(-) commit 59b24dad20d41c00b51f5ca549a9e83a53671bc9 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:43 2016 -0400 rtl8xxxu: Reorg more code to match the flow of the 8192eu vendor driver This further reorganizes the init code flow to match that of the 8192eu vendor driver. This helps diffing the register write log against that of the vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 109 ++++++++++++----------- 1 file changed, 56 insertions(+), 53 deletions(-) commit c157863d99797f6fed60e6e56d53afeb0bc3b436 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 14 14:58:42 2016 -0400 rtl8xxxu: Reorder parts of init code to match the 8192eu vendor code flow In order to debug 8192eu support, reorder some init code to match the flow of the vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 35 ++++++++++++++---------- 1 file changed, 20 insertions(+), 15 deletions(-) commit 85abfb1239ecda32222c161670667c7b2f6832be Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:11 2016 +0100 mwifiex: make mwifiex_insert_cmd_to_free_q local static after factoring out mwifiex_cancel_pending_scan_cmd the function is not called outside of cmdevt file moved function to head of file to avoid forward declaration, also moved mwifiex_recycle_cmd_node since they are very similar Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cmdevt.c | 82 +++++++++++++-------------- drivers/net/wireless/marvell/mwifiex/main.h | 2 - 2 files changed, 41 insertions(+), 43 deletions(-) commit c70ca8cb9a7c6722d5bb6d428b6571921998c48d Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:10 2016 +0100 mwifiex: factor out mwifiex_cancel_pending_scan_cmd Releasing the scan_pending lock in mwifiex_check_next_scan_command introduces a short window where pending scan commands can be removed or added before removing them all in mwifiex_cancel_pending_scan_cmd. I think this is safe, since the worst thing to happen is that a pending scan cmd is removed by the command handler. Adding new scan commands is not possible while one is pending, see scan_processing flag. Since all commands are removed from the queue anyway, we don't care if some commands are removed by a different code path earlier, the final state remains the same. I assume, that the critical section needed for the check has been extended over clearing the pending scan queue out of convenience. The lock was already held and releasing it and grab it again was just more work. It doesn't seem to be necessary because of concurrency. Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cmdevt.c | 43 ++++++++++------------ drivers/net/wireless/marvell/mwifiex/main.h | 1 + drivers/net/wireless/marvell/mwifiex/scan.c | 23 +++--------- drivers/net/wireless/marvell/mwifiex/sta_cmdresp.c | 13 +------ 4 files changed, 27 insertions(+), 53 deletions(-) commit 948ad6b34943a1247653392d59bcfc9896da8fe7 Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:09 2016 +0100 mwifiex: scan: replace pointer arithmetic with array access improves readability Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) commit 679b687bc96ddf2ef077ca4aa755924032bd18a8 Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:08 2016 +0100 mwifiex: scan: factor out dbg_security_flags merge copy/paste code Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 74 ++++++++++------------------- 1 file changed, 25 insertions(+), 49 deletions(-) commit 2ccf7cef0cf984241d0b6932ed1cfb1e0d6587d5 Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:07 2016 +0100 mwifiex: scan: simplify ternary operators using gnu extension "x ? x : y" can be simplified as "x ? : y" https://gcc.gnu.org/onlinedocs/gcc/Conditionals.html#Conditionals Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 38329568c3f7075c7751984a65e16a9c7fc186bd Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:06 2016 +0100 mwifiex: scan: factor out has_ieee_hdr/has_vendor_hdr Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 52 +++++++++++++---------------- 1 file changed, 23 insertions(+), 29 deletions(-) commit 0a233c98a8e933a65aec07663d3a2953c7642bbc Author: Andreas Fenkart <afenkart@gmail.com> Date: Thu Mar 10 09:44:05 2016 +0100 mwifiex: scan: simplify dereference of bss_desc fields given this structure: struct foo { struct bar { int baz; } } these accesses are equivalent: (*(foo->bar)).baz foo->bar->baz Signed-off-by: Andreas Fenkart <afenkart@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/scan.c | 98 ++++++++++++++--------------- 1 file changed, 46 insertions(+), 52 deletions(-) commit 522566376a3f8373fbd5ff75bb8a7a2da701c1a7 Author: Aviya Erenfeld <aviya.erenfeld@intel.com> Date: Thu Apr 14 11:59:31 2016 +0200 devcoredump: add scatterlist support Add scatterlist support (dev_coredumpsg) to allow drivers to avoid vmalloc() like dev_coredumpm(), while also avoiding the module reference that the latter function requires. This internally uses dev_coredumpm() with function inside the devcoredump module, requiring removing the const (which touches the driver using it.) Signed-off-by: Aviya Erenfeld <aviya.erenfeld@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/base/devcoredump.c | 83 +++++++++++++++++++++--- drivers/net/wireless/intel/iwlwifi/mvm/fw-dbg.c | 4 +- include/linux/devcoredump.h | 86 ++++++++++++++++++++++--- 3 files changed, 154 insertions(+), 19 deletions(-) commit 66dbd6e61a526ae7d11a208238ae2c17e5cacb6b Author: Catalin Marinas <catalin.marinas@arm.com> Date: Wed Apr 13 16:01:22 2016 +0100 arm64: Implement ptep_set_access_flags() for hardware AF/DBM When hardware updates of the access and dirty states are enabled, the default ptep_set_access_flags() implementation based on calling set_pte_at() directly is potentially racy. This triggers the "racy dirty state clearing" warning in set_pte_at() because an existing writable PTE is overridden with a clean entry. There are two main scenarios for this situation: 1. The CPU getting an access fault does not support hardware updates of the access/dirty flags. However, a different agent in the system (e.g. SMMU) can do this, therefore overriding a writable entry with a clean one could potentially lose the automatically updated dirty status 2. A more complex situation is possible when all CPUs support hardware AF/DBM: a) Initial state: shareable + writable vma and pte_none(pte) b) Read fault taken by two threads of the same process on different CPUs c) CPU0 takes the mmap_sem and proceeds to handling the fault. It eventually reaches do_set_pte() which sets a writable + clean pte. CPU0 releases the mmap_sem d) CPU1 acquires the mmap_sem and proceeds to handle_pte_fault(). The pte entry it reads is present, writable and clean and it continues to pte_mkyoung() e) CPU1 calls ptep_set_access_flags() If between (d) and (e) the hardware (another CPU) updates the dirty state (clears PTE_RDONLY), CPU1 will override the PTR_RDONLY bit marking the entry clean again. This patch implements an arm64-specific ptep_set_access_flags() function to perform an atomic update of the PTE flags. Fixes: 2f4b829c625e ("arm64: Add support for hardware updates of the access and dirty pte bits") Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Reported-by: Ming Lei <tom.leiming@gmail.com> Tested-by: Julien Grall <julien.grall@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: <stable@vger.kernel.org> # 4.3+ [will: reworded comment] Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 5 ++++ arch/arm64/mm/fault.c | 50 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 55 insertions(+) commit 561662301eb6a40d569453b3555fc8cfce094b93 Author: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Date: Fri Apr 8 15:50:28 2016 -0700 arm64, mm, numa: Add NUMA balancing support for arm64. Enable NUMA balancing for arm64 platforms. Add pte, pmd protnone helpers for use by automatic NUMA balancing. Reviewed-by: Steve Capper <steve.capper@arm.com> Reviewed-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 1 + arch/arm64/include/asm/pgtable.h | 15 +++++++++++++++ 2 files changed, 16 insertions(+) commit 1a2db300348b799479d2d22b84d51b27ad0458c7 Author: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Date: Fri Apr 8 15:50:27 2016 -0700 arm64, numa: Add NUMA support for arm64 platforms. Attempt to get the memory and CPU NUMA node via of_numa. If that fails, default the dummy NUMA node and map all memory and CPUs to node 0. Tested-by: Shannon Zhao <shannon.zhao@linaro.org> Reviewed-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig | 26 +++ arch/arm64/include/asm/mmzone.h | 12 ++ arch/arm64/include/asm/numa.h | 45 +++++ arch/arm64/include/asm/topology.h | 10 + arch/arm64/kernel/pci.c | 10 + arch/arm64/kernel/setup.c | 4 + arch/arm64/kernel/smp.c | 4 + arch/arm64/mm/Makefile | 1 + arch/arm64/mm/init.c | 35 +++- arch/arm64/mm/numa.c | 396 ++++++++++++++++++++++++++++++++++++++ 10 files changed, 538 insertions(+), 5 deletions(-) commit 3194ac6e66cc7a00c1fa9fecf33a7c376b489497 Author: David Daney <david.daney@cavium.com> Date: Fri Apr 8 15:50:26 2016 -0700 arm64: Move unflatten_device_tree() call earlier. In order to extract NUMA information from the device tree, we need to have the tree in its unflattened form. Move the call to bootmem_init() in the tail of paging_init() into setup_arch, and adjust header files so that its declaration is visible. Move the unflatten_device_tree() call between the calls to paging_init() and bootmem_init(). Follow on patches add NUMA handling to bootmem_init(). Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/mmu.h | 1 + arch/arm64/kernel/setup.c | 12 ++++++++---- arch/arm64/mm/mm.h | 1 - arch/arm64/mm/mmu.c | 2 -- 4 files changed, 9 insertions(+), 7 deletions(-) commit 298535c00a2cbcd59e38f8f1c0c9ae7b9911e946 Author: David Daney <david.daney@cavium.com> Date: Fri Apr 8 15:50:25 2016 -0700 of, numa: Add NUMA of binding implementation. Add device tree parsing for NUMA topology using device "numa-node-id" property in distance-map and cpu nodes. This is a complete rewrite of a previous patch by: Ganapatrao Kulkarni<gkulkarni@caviumnetworks.com> Signed-off-by: David Daney <david.daney@cavium.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/of/Kconfig | 3 + drivers/of/Makefile | 1 + drivers/of/of_numa.c | 211 +++++++++++++++++++++++++++++++++++++++++++++++++++ include/linux/of.h | 9 +++ 4 files changed, 224 insertions(+) commit 2bc4da1d2b4d828cb4e3a5593967556b1bd78898 Author: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Date: Fri Apr 8 15:50:24 2016 -0700 Documentation, dt, numa: dt bindings for NUMA. Add DT bindings for numa mapping of memory, CPUs and IOs. Reviewed-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com> Signed-off-by: David Daney <david.daney@cavium.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/devicetree/bindings/numa.txt | 275 +++++++++++++++++++++++++++++ 1 file changed, 275 insertions(+) commit 500899c2cc3e3f06140373b587a69d30650f2d9d Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Fri Apr 8 15:50:23 2016 -0700 efi: ARM/arm64: ignore DT memory nodes instead of removing them There are two problems with the UEFI stub DT memory node removal routine: - it deletes nodes as it traverses the tree, which happens to work but is not supported, as deletion invalidates the node iterator; - deleting memory nodes entirely may discard annotations in the form of additional properties on the nodes. Since the discovery of DT memory nodes occurs strictly before the UEFI init sequence, we can simply clear the memblock memory table before parsing the UEFI memory map. This way, it is no longer necessary to remove the nodes, so we can remove that logic from the stub as well. Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Acked-by: Steve Capper <steve.capper@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: David Daney <david.daney@cavium.com> Signed-off-by: Will Deacon <will.deacon@arm.com> drivers/firmware/efi/arm-init.c | 8 ++++++++ drivers/firmware/efi/libstub/fdt.c | 24 +----------------------- 2 files changed, 9 insertions(+), 23 deletions(-) commit ac1ad20f9ed73a22b0a72eb83206302f5fbff55c Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Wed Apr 13 14:41:33 2016 +0100 arm64: vhe: Verify CPU Exception Levels With a VHE capable CPU, kernel can run at EL2 and is a decided at early boot. If some of the CPUs didn't start it EL2 or doesn't have VHE, we could have CPUs running at different exception levels, all in the same kernel! This patch adds an early check for the secondary CPUs to detect such situations. For each non-boot CPU add a sanity check to make sure we don't have different run levels w.r.t the boot CPU. We save the information on whether the boot CPU is running in hyp mode or not and ensure the remaining CPUs match it. Cc: Marc Zyngier <marc.zyngier@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> [will: made boot_cpu_hyp_mode static] Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/virt.h | 6 ++++++ arch/arm64/kernel/cpufeature.c | 1 + arch/arm64/kernel/smp.c | 38 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 45 insertions(+) commit 17eebd1a435c8616c47b715e3447f4a9c15b741f Author: Suzuki K Poulose <suzuki.poulose@arm.com> Date: Tue Apr 12 15:46:00 2016 +0100 arm64: Add cpu_panic_kernel helper During the activation of a secondary CPU, we could report serious configuration issues and hence request to crash the kernel. We do this for CPU ASID bit check now. We will need it also for handling mismatched exception levels for the CPUs with VHE. Hence, add a helper to do the same for reusability. Cc: Mark Rutland <mark.rutland@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/smp.h | 11 +++++++++++ arch/arm64/mm/context.c | 3 +-- 2 files changed, 12 insertions(+), 2 deletions(-) commit 83835fb07836eac1b35e98b919bf757ff7f77aad Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Fri Apr 15 15:10:52 2016 +0300 spi: dln2: Pass of_node to spi master This allows defining SPI devices connected to a DLN2 using devicetree. This already works for i2c because of a similar patch: 3b10db23: i2c: dln2: set the device tree node of the adapter Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Acked-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-dln2.c | 3 +++ 1 file changed, 3 insertions(+) commit 25fb0b6c73122a4718cf218a164e468b11449a2d Merge: de33efd b94cdab Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 15 13:02:43 2016 -0400 Merge branch 'mlxsw-next' Jiri Pirko says: ==================== mlxsw: spectrum_buffers: couple of cosmetic patches As suggested by David Laight ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b94cdabbf174a197020632748339392b494494e5 Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 15 15:09:38 2016 +0200 mlxsw: spectrum_buffers: Use MLXSW_SP_PB_UNUSED define for unused pb Suggested-by: David Laight <David.Laight@ACULAB.COM> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ce78f020429c649b206e2fd7d44411fbc1ec920e Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 15 15:09:37 2016 +0200 mlxsw: spectrum_buffers: Use designated initializers for mlxsw_sp_pbs Suggested-by: David Laight <David.Laight@ACULAB.COM> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit de33efd0fb7f923cd41671b1f743c3a0d44dd953 Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 15 09:17:08 2016 +0200 devlink: fix sb register stub in case devlink is disabled Reported-by: kbuild test robot <fengguang.wu@intel.com> Fixes: bf7974710a40 ("devlink: add shared buffer configuration") Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/devlink.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 6466ee322749e7f440764df053ccccb2d15ab4de Merge: f676471 81fed6e Author: Sylwester Nawrocki <s.nawrocki@samsung.com> Date: Fri Apr 15 18:57:00 2016 +0200 Merge branch 'for-v4.7/clk/exynos542x' into for-v4.7/clk/next commit c7d4d259b7477866376435155eb0ccdaee880677 Author: Martin Schwidefsky <schwidefsky@de.ibm.com> Date: Thu Mar 17 15:22:12 2016 +0100 s390/crypto: cleanup and move the header with the cpacf definitions The CPACF instructions are going be used in KVM as well, move the defines and the inline functions from arch/s390/crypt/crypt_s390.h to arch/s390/include/asm. Rename the header to cpacf.h and replace the crypt_s390_xxx names with cpacf_xxx. While we are at it, cleanup the header as well. The encoding for the CPACF operations is odd, there is an enum for each of the CPACF instructions with the hardware function code in the lower 8 bits of each entry and a software defined number for the CPACF instruction in the upper 8 bits. Remove the superfluous software number and replace the enums with simple defines. The crypt_s390_func_available() function tests for the presence of a specific CPACF operations. The new name of the function is cpacf_query and it works slightly different than before. It gets passed an opcode of an CPACF instruction and a function code for this instruction. The facility_mask parameter is gone, the opcode is used to find the correct MSA facility bit to check if the CPACF instruction itself is available. If it is the query function of the given instruction is used to test if the requested CPACF operation is present. Acked-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/crypto/aes_s390.c | 117 +++++----- arch/s390/crypto/crypt_s390.h | 493 ----------------------------------------- arch/s390/crypto/des_s390.c | 72 +++--- arch/s390/crypto/ghash_s390.c | 16 +- arch/s390/crypto/prng.c | 60 +++-- arch/s390/crypto/sha1_s390.c | 10 +- arch/s390/crypto/sha256_s390.c | 14 +- arch/s390/crypto/sha512_s390.c | 14 +- arch/s390/crypto/sha_common.c | 10 +- arch/s390/include/asm/cpacf.h | 410 ++++++++++++++++++++++++++++++++++ 10 files changed, 556 insertions(+), 660 deletions(-) commit f9dc447ec8f1f0a9f2ba4e4d5a61758f8df4acd8 Author: Sebastian Ott <sebott@linux.vnet.ibm.com> Date: Mon Jun 29 18:47:28 2015 +0200 s390/pci: fmb enhancements Implement the function type specific function measurement block used in new machines. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/include/asm/pci.h | 35 ++++++++++++++++++++------ arch/s390/pci/pci_debug.c | 61 ++++++++++++++++++++++++++++++++++----------- 2 files changed, 75 insertions(+), 21 deletions(-) commit 8fd575200db5b53f6ea6818dd017f1b43190db12 Author: Jan Höppner <hoeppner@linux.vnet.ibm.com> Date: Wed Aug 19 13:41:20 2015 +0200 s390/dasd: Add new ioctl BIODASDCHECKFMT Implement new DASD IOCTL BIODASDCHECKFMT to check a range of tracks on a DASD volume for correct formatting. The following characteristics are checked: - Block size - ECKD key length - ECKD record ID - Number of records per track Signed-off-by: Jan Höppner <hoeppner@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/include/uapi/asm/dasd.h | 32 +++ drivers/s390/block/dasd.c | 36 ++- drivers/s390/block/dasd_3990_erp.c | 20 +- drivers/s390/block/dasd_eckd.c | 535 +++++++++++++++++++++++++++++++++++-- drivers/s390/block/dasd_eckd.h | 1 + drivers/s390/block/dasd_int.h | 14 +- drivers/s390/block/dasd_ioctl.c | 61 +++++ 7 files changed, 676 insertions(+), 23 deletions(-) commit 3fa7ee8844c31cb9c78992bb82cfaeb13375345d Author: Sebastian Ott <sebott@linux.vnet.ibm.com> Date: Fri Nov 27 12:33:18 2015 +0100 s390/sclp: event type macro cleanup Sort the sclp event type defines and use a macro to create the corresponding event type masks. In addition to that one unused type/mask pair is removed and another previously unused define is used now (it was probably unused/unknown because it didn't follow the EVTYP_X EVTYP_X_MASK convention). Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/sclp.h | 38 +++++++++++++++++++------------------- drivers/s390/char/sclp_cpi_sys.c | 2 +- 2 files changed, 20 insertions(+), 20 deletions(-) commit 368704a65be8620df795ccbeb44e025dafbc3e1f Author: Sebastian Ott <sebott@linux.vnet.ibm.com> Date: Fri Nov 27 11:22:57 2015 +0100 s390/pci: add report_error attribute Provide an report_error attribute to send an adapter-error notification associated with a PCI function. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/pci/pci_sysfs.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 12283a4035691697977083a5ac1e00ad5cfa6a3d Author: Sebastian Ott <sebott@linux.vnet.ibm.com> Date: Fri Nov 27 11:18:02 2015 +0100 s390/sclp: add error notification command Add SCLP event 24 "Adapter-error notification". Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/include/asm/sclp.h | 13 +++++ drivers/s390/char/sclp.h | 2 + drivers/s390/char/sclp_pci.c | 120 ++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 133 insertions(+), 2 deletions(-) commit 68dd13d6d58c145bbf6d295b8c430b4d38c943d9 Author: Sebastian Ott <sebott@linux.vnet.ibm.com> Date: Fri Nov 27 11:15:36 2015 +0100 s390/sclp: move pci related commands to separate file sclp commands only used by the PCI code shouldn't be build for !CONFIG_PCI. Instead of adding more ifdefs to sclp_cmd.c just move them to a new file. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/char/Makefile | 2 ++ drivers/s390/char/sclp_cmd.c | 61 ----------------------------------- drivers/s390/char/sclp_pci.c | 76 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 78 insertions(+), 61 deletions(-) commit 52c48c51e60c473ccedb4c8f428050041ca7076a Author: Sascha Silbe <silbe@linux.vnet.ibm.com> Date: Tue Apr 5 12:53:38 2016 +0200 Documentation: document the nosmt and smt s390 kernel parameters Commit 6c2ff84e979a ("s390: add SMT support") added the nosmt and smt early kernel parameters for restricting the use of symmetric multithreading (SMT). They are quite useful for debugging and testing, so document them. Signed-off-by: Sascha Silbe <silbe@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> Documentation/kernel-parameters.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 0227f7c42d9e01b00ea8cbd635aaf92a09b54abc Author: Peter Zijlstra <peterz@infradead.org> Date: Tue Mar 22 21:42:53 2016 +0100 s390: Clarify pagefault interrupt While looking at set_task_state() users I stumbled over the s390 pfault interrupt code. Since Heiko provided a great explanation on how it worked, I figured we ought to preserve this. Also make a few little tweaks to the code to aid in readability and explicitly comment the unusual blocking scheme. Based-on-text-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> arch/s390/mm/fault.c | 41 +++++++++++++++++++++++++++++++++-------- 1 file changed, 33 insertions(+), 8 deletions(-) commit 5a3b7b112884f80ff19b18028fabeb4f9c035518 Author: Stefan Haberland <stefan.haberland@de.ibm.com> Date: Fri Mar 18 09:42:13 2016 +0100 s390/dasd: add query host access to volume support With this feature, applications can query if a DASD volume is online to another operating system instances by checking the online status of all attached hosts from the storage server. Reviewed-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Reviewed-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Stefan Haberland <stefan.haberland@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> drivers/s390/block/dasd.c | 56 +++++++++++++ drivers/s390/block/dasd_devmap.c | 27 +++++++ drivers/s390/block/dasd_eckd.c | 164 +++++++++++++++++++++++++++++++++++++++ drivers/s390/block/dasd_eckd.h | 33 +++++++- drivers/s390/block/dasd_int.h | 3 + 5 files changed, 282 insertions(+), 1 deletion(-) commit 5cf9c84e21067ec7a44648aedbc38c197d707258 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 11:10:31 2016 -0300 perf trace: Introduce --min-stack filter Counterpart to --max-stack, to help focusing on deeply nested calls. Can be combined with --duration, etc. E.g.: System wide syscall tracing looking for call stacks longer than 66: # trace --mmap-pages 32768 --filter-pid 2711 --call-graph dwarf,16384 --min-stack 66 Or more compactly: # trace -m 32768 --filt 2711 --call dwarf,16384 --min-st 66 363.027 ( 0.002 ms): gnome-shell/2287 poll(ufds: 0x7ffc5ea24230, nfds: 1, timeout_msecs: 4294967295 ) = 1 [0xf6fdd] (/usr/lib64/libc-2.22.so) _xcb_conn_wait+0x92 (/usr/lib64/libxcb.so.1.1.0) _xcb_out_send+0x4d (/usr/lib64/libxcb.so.1.1.0) xcb_writev+0x45 (/usr/lib64/libxcb.so.1.1.0) _XSend+0x19e (/usr/lib64/libX11.so.6.3.0) _XReply+0x82 (/usr/lib64/libX11.so.6.3.0) XSync+0x4d (/usr/lib64/libX11.so.6.3.0) dri3_bind_tex_image+0x42 (/usr/lib64/libGL.so.1.2.0) _cogl_winsys_texture_pixmap_x11_update+0x117 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_update+0x67 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_pre_paint+0x13 (/usr/lib64/libcogl.so.20.4.1) _cogl_pipeline_layer_pre_paint+0x5e (/usr/lib64/libcogl.so.20.4.1) _cogl_rectangles_validate_layer_cb+0x1b (/usr/lib64/libcogl.so.20.4.1) cogl_pipeline_foreach_layer+0xbe (/usr/lib64/libcogl.so.20.4.1) _cogl_framebuffer_draw_multitextured_rectangles+0x77 (/usr/lib64/libcogl.so.20.4.1) cogl_framebuffer_draw_multitextured_rectangle+0x51 (/usr/lib64/libcogl.so.20.4.1) paint_clipped_rectangle+0xb6 (/usr/lib64/libmutter.so.0.0.0) meta_shaped_texture_paint+0x3e3 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_actor_paint+0x14b (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_group_paint+0x19f (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) [0x3d970] (/usr/lib64/gnome-shell/libgnome-shell.so) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_paint+0x3a (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_stage_paint+0x45 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0x164 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_paint+0x17b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_cogl_redraw+0x496 (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_update+0x117 (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_clock_dispatch+0x169 (/usr/lib64/libclutter-1.0.so.0.2400.2) g_main_context_dispatch+0x15a (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_context_iterate.isra.29+0x1e0 (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_loop_run+0xc2 (/usr/lib64/libglib-2.0.so.0.4600.2) meta_run+0x2c (/usr/lib64/libmutter.so.0.0.0) main+0x3f7 (/usr/bin/gnome-shell) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) [0x2909] (/usr/bin/gnome-shell) 363.038 ( 0.006 ms): gnome-shell/2287 writev(fd: 5<socket:[32540]>, vec: 0x7ffc5ea243a0, vlen: 3 ) = 4 __GI___writev+0x2d (/usr/lib64/libc-2.22.so) _xcb_conn_wait+0x359 (/usr/lib64/libxcb.so.1.1.0) _xcb_out_send+0x4d (/usr/lib64/libxcb.so.1.1.0) xcb_writev+0x45 (/usr/lib64/libxcb.so.1.1.0) _XSend+0x19e (/usr/lib64/libX11.so.6.3.0) _XReply+0x82 (/usr/lib64/libX11.so.6.3.0) XSync+0x4d (/usr/lib64/libX11.so.6.3.0) dri3_bind_tex_image+0x42 (/usr/lib64/libGL.so.1.2.0) _cogl_winsys_texture_pixmap_x11_update+0x117 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_update+0x67 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_pre_paint+0x13 (/usr/lib64/libcogl.so.20.4.1) _cogl_pipeline_layer_pre_paint+0x5e (/usr/lib64/libcogl.so.20.4.1) _cogl_rectangles_validate_layer_cb+0x1b (/usr/lib64/libcogl.so.20.4.1) cogl_pipeline_foreach_layer+0xbe (/usr/lib64/libcogl.so.20.4.1) _cogl_framebuffer_draw_multitextured_rectangles+0x77 (/usr/lib64/libcogl.so.20.4.1) cogl_framebuffer_draw_multitextured_rectangle+0x51 (/usr/lib64/libcogl.so.20.4.1) paint_clipped_rectangle+0xb6 (/usr/lib64/libmutter.so.0.0.0) meta_shaped_texture_paint+0x3e3 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_actor_paint+0x14b (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_group_paint+0x19f (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) [0x3d970] (/usr/lib64/gnome-shell/libgnome-shell.so) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_paint+0x3a (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_stage_paint+0x45 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0x164 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_paint+0x17b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_cogl_redraw+0x496 (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_update+0x117 (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_clock_dispatch+0x169 (/usr/lib64/libclutter-1.0.so.0.2400.2) g_main_context_dispatch+0x15a (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_context_iterate.isra.29+0x1e0 (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_loop_run+0xc2 (/usr/lib64/libglib-2.0.so.0.4600.2) meta_run+0x2c (/usr/lib64/libmutter.so.0.0.0) main+0x3f7 (/usr/bin/gnome-shell) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) [0x2909] (/usr/bin/gnome-shell) 363.086 ( 0.042 ms): gnome-shell/2287 poll(ufds: 0x7ffc5ea24250, nfds: 1, timeout_msecs: 4294967295 ) = 1 [0xf6fdd] (/usr/lib64/libc-2.22.so) _xcb_conn_wait+0x92 (/usr/lib64/libxcb.so.1.1.0) wait_for_reply+0xb7 (/usr/lib64/libxcb.so.1.1.0) xcb_wait_for_reply+0x61 (/usr/lib64/libxcb.so.1.1.0) _XReply+0x127 (/usr/lib64/libX11.so.6.3.0) XSync+0x4d (/usr/lib64/libX11.so.6.3.0) dri3_bind_tex_image+0x42 (/usr/lib64/libGL.so.1.2.0) _cogl_winsys_texture_pixmap_x11_update+0x117 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_update+0x67 (/usr/lib64/libcogl.so.20.4.1) _cogl_texture_pixmap_x11_pre_paint+0x13 (/usr/lib64/libcogl.so.20.4.1) _cogl_pipeline_layer_pre_paint+0x5e (/usr/lib64/libcogl.so.20.4.1) _cogl_rectangles_validate_layer_cb+0x1b (/usr/lib64/libcogl.so.20.4.1) cogl_pipeline_foreach_layer+0xbe (/usr/lib64/libcogl.so.20.4.1) _cogl_framebuffer_draw_multitextured_rectangles+0x77 (/usr/lib64/libcogl.so.20.4.1) cogl_framebuffer_draw_multitextured_rectangle+0x51 (/usr/lib64/libcogl.so.20.4.1) paint_clipped_rectangle+0xb6 (/usr/lib64/libmutter.so.0.0.0) meta_shaped_texture_paint+0x3e3 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_actor_paint+0x14b (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_real_paint+0x20 (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_window_group_paint+0x19f (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) [0x3d970] (/usr/lib64/gnome-shell/libgnome-shell.so) _g_closure_invoke_va+0xb2 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_paint+0x3a (/usr/lib64/libclutter-1.0.so.0.2400.2) meta_stage_paint+0x45 (/usr/lib64/libmutter.so.0.0.0) _g_closure_invoke_va+0x164 (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit_valist+0xc0d (/usr/lib64/libgobject-2.0.so.0.4600.2) g_signal_emit+0x8f (/usr/lib64/libgobject-2.0.so.0.4600.2) clutter_actor_continue_paint+0x2bb (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_actor_paint.part.41+0x47b (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_paint+0x17b (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_stage_cogl_redraw+0x496 (/usr/lib64/libclutter-1.0.so.0.2400.2) _clutter_stage_do_update+0x117 (/usr/lib64/libclutter-1.0.so.0.2400.2) clutter_clock_dispatch+0x169 (/usr/lib64/libclutter-1.0.so.0.2400.2) g_main_context_dispatch+0x15a (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_context_iterate.isra.29+0x1e0 (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_loop_run+0xc2 (/usr/lib64/libglib-2.0.so.0.4600.2) meta_run+0x2c (/usr/lib64/libmutter.so.0.0.0) main+0x3f7 (/usr/bin/gnome-shell) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) [0x2909] (/usr/bin/gnome-shell) Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-jncuxju9fibq2rl6olhqwjw6@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 4 +++ tools/perf/builtin-trace.c | 55 ++++++++++++++++++++++----------- 2 files changed, 41 insertions(+), 18 deletions(-) commit e519bd9a07fe5b13c47b506d0fbadb7498e60607 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 15 10:20:10 2016 -0300 perf trace: Do not print interrupted syscalls when using --duration With multiple threads, e.g. a system wide trace session, and one syscall is midway in a thread and another thread starts another syscall we must print the start of the interrupted syscall followed by ..., but that can't be done that way when we use the --duration filter, as we have to wait for the syscall exit to calculate the duration and decide if it should be filtered, so we have to disable the interrupted logic and only print at syscall exit, duh. Before: # trace --duration 100 <SNIP> 9.248 (0.023 ms): gnome-shell/2287 poll(ufds: 0x7ffc5ea26580, nfds: 1, timeout_msecs: 4294967295) ... 9.296 (0.001 ms): gnome-shell/2287 recvmsg(fd: 11<socket:[35818]>, msg: 0x7ffc5ea264a0 ) ... 9.311 (0.008 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 9.859 (0.023 ms): gnome-shell/2287 poll(ufds: 0x7ffc5ea24250, nfds: 1, timeout_msecs: 4294967295) ... 9.942 (0.051 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 10.467 (0.003 ms): gnome-shell/2287 poll(ufds: 0x55e623431220, nfds: 50, timeout_msecs: 4294967295) ... 11.136 (0.382 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 11.223 (0.023 ms): SoftwareVsyncT/24369 futex(uaddr: 0x7f5ec5df8c14, op: WAIT_BITSET|PRIV, val: 1, utime: 0x7f5ec5df8b68, val3: 4294967295) ... 16.865 (5.501 ms): firefox/24321 poll(ufds: 0x7f5ec388b460, nfds: 6, timeout_msecs: 4294967295 ) ... 22.571 (0.006 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 26.793 (4.063 ms): gnome-shell/2287 poll(ufds: 0x55e623431220, nfds: 50, timeout_msecs: 4294967295) ... 26.917 (0.080 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 27.291 (0.355 ms): qemu-system-x8/10065 ppoll(ufds: 0x55c98b39e400, nfds: 72, tsp: 0x7fffe4e4fe60, sigsetsize: 8) ... 27.336 (0.012 ms): SoftwareVsyncT/24369 futex(uaddr: 0x7f5ec5df8c14, op: WAIT_BITSET|PRIV, val: 1, utime: 0x7f5ec5df8b68, val3: 4294967295) ... 33.370 (5.958 ms): firefox/24321 poll(ufds: 0x7f5ec388b460, nfds: 6, timeout_msecs: 4294967295) ... 33.866 (0.021 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... 35.762 (1.611 ms): gnome-shell/2287 poll(ufds: 0x55e623431220, nfds: 50, timeout_msecs: 8 ) ... 38.765 (2.910 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) ... After: # trace --duration 100 238.292 (153.226 ms): hexchat/2786 poll(ufds: 0x559ea372f370, nfds: 6, timeout_msecs: 153) = 0 Timeout 249.634 (199.433 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x7ffdcbb63610 ) = 1 385.583 (147.257 ms): hexchat/2786 poll(ufds: 0x559ea372f370, nfds: 6, timeout_msecs: 147) = 0 Timeout 397.166 (110.779 ms): gnome-shell/2287 poll(ufds: 0x55e623431220, nfds: 50, timeout_msecs: 4294967295) = 1 601.839 (132.066 ms): Xorg/2025 select(n: 512, inp: 0x83a8e0, tvp: 0x8316a0 ) = 1 602.445 (132.679 ms): gnome-shell/2287 poll(ufds: 0x55e623431220, nfds: 50, timeout_msecs: 4294967295) = 1 686.122 (300.418 ms): hexchat/2786 poll(ufds: 0x559ea372f370, nfds: 6, timeout_msecs: 300) = 0 Timeout 815.033 (184.641 ms): JS Helper/24352 futex(uaddr: 0x7f5ed98e584c, op: WAIT|PRIV, val: 1149859) = 0 825.868 (195.469 ms): JS Helper/24351 futex(uaddr: 0x7f5ed98e584c, op: WAIT|PRIV, val: 1149860) = 0 840.738 (210.335 ms): JS Helper/24350 futex(uaddr: 0x7f5ed98e584c, op: WAIT|PRIV, val: 1149861) = 0 914.898 (158.692 ms): Compositor/24363 futex(uaddr: 0x7f5ec8dfebf4, op: WAIT|PRIV, val: 1) = 0 915.199 (100.747 ms): Timer/24358 futex(uaddr: 0x7f5ed98e56cc, op: WAIT_BITSET|PRIV|CLKRT, val: 2545397, utime: 0x7f5ecdbfec30, val3: 4294967295) = 0 986.639 (247.325 ms): hexchat/2786 poll(ufds: 0x559ea372f370, nfds: 6, timeout_msecs: 247) = 0 Timeout 996.239 (500.591 ms): chrome/16237 poll(ufds: 0x3ecd739bd0, nfds: 5, timeout_msecs: 500) = 0 Timeout 1042.890 (120.076 ms): Timer/24358 futex(uaddr: 0x7f5ed98e56cc, op: WAIT_BITSET|PRIV|CLKRT, val: 2545403, utime: 0x7f5ecdbfec30, val3: 4294967295) = -1 ETIMEDOUT Connection timed out Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-d2nay6kjax5ro991c9kelvi5@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 81fed6e342c04a4ecb0650c914d24bd57c6c168f Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Apr 15 15:32:53 2016 +0900 clk: samsung: exynos542x: Add the clock id for ACLK This patch adds the clock id for ACLK clock which is source clock of AMBA AXI bus. This clock should be handled in the bus frequency scaling driver. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> drivers/clk/samsung/clk-exynos5420.c | 77 ++++++++++++++++++++++-------------- 1 file changed, 47 insertions(+), 30 deletions(-) commit 72b67b3fcb5f500e73dfd42dce3a4749ba84e4bf Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Fri Apr 15 15:32:52 2016 +0900 dt-bindings: clock: Add the clock id for ACLK clock of Exynos542x SoC This patch adds the clock id for ACLK clock of Exynos542x SoC. ACLK clock means the source clock of AMBA AXI bus. This clock id should be used for Bus frequency scaling. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Tested-by: Markus Reichl <m.reichl@fivetechno.de> Tested-by: Anand Moon <linux.amoon@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> include/dt-bindings/clock/exynos5420.h | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) commit 6485160396fcec2fa8a0acfa7c8c090f020db694 Author: Leo Yan <leo.yan@linaro.org> Date: Fri Feb 26 13:28:34 2016 +0800 arm64: dts: Add L2 cache topology to Hi6220 This patch adds the L2 cache topology on Hi6220. Hi6220 has two clusters, every cluster has 512KiB L2 cache (32KiB x 16 ways). Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit cd0b69ec0eb5e489954d7125b934457ac7acf6f7 Author: Leo Yan <leo.yan@linaro.org> Date: Tue Mar 29 19:27:15 2016 +0800 arm64: dts: register Hi6220's thermal zone for power allocator With profiling Hi6220's power modeling so get dynamic coefficient and sustainable power. So pass these parameters from DT. Now enable power allocator with only one actor for CPU part, so directly use cluster0's thermal sensor for monitoring temperature. Reviewed-by: Javi Merino <javi.merino@arm.com> Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 35 +++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 2158ab084b721da7b0e4963ac91fd96775b80916 Author: Leo Yan <leo.yan@linaro.org> Date: Tue Mar 29 19:27:14 2016 +0800 arm64: dts: register Hi6220's thermal sensor Bind thermal sensor driver for Hi6220. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit c27753d675fccd3b15a78621a2a66616507693d4 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue Apr 12 14:36:11 2016 -0700 f2fs: flush dirty pages before starting atomic writes If somebody wrote some data before atomic writes, we should flush them in order to handle atomic data in a right period. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 63c52d7878903a014fa4c9075afd051b1e77597b Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue Apr 12 14:11:03 2016 -0700 f2fs: don't invalidate atomic page if successful If we committed atomic write successfully, we don't need to invalidate pages. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/segment.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 58457f1c355545c468b8aed5c431d8a6bb71d35d Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue Apr 12 11:52:30 2016 -0700 f2fs: give -E2BIG for no space in xattr This patch returns -E2BIG if there is no space to add an xattr entry. This should fix generic/026 in xfstests as well. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/xattr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4da7bf5a4345f3ce9699476a8022f66cfb4a8ce9 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Apr 6 11:27:03 2016 -0700 f2fs: remove redundant condition check This patch resolves the redundant condition check reported by David. Reported-by: David Binderman <dcb314@hotmail.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/checkpoint.c | 2 +- fs/f2fs/data.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 26dc3d4424e9f4764d633bd8f9309a01e6f364dd Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon Apr 11 13:15:10 2016 -0700 f2fs: unset atomic/volatile flag in f2fs_release_file The atomic/volatile operation should be done in pair of start and commit ioctl. For example, if a killed process remains open-ended atomic operation, we should drop its flag as well as its atomic data. Otherwise, if sqlite initiates another operation which doesn't require atomic writes, it will lose every data, since f2fs still treats with them as atomic writes; nobody will trigger its commit. Reported-by: Miao Xie <miaoxie@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 5 ++--- fs/f2fs/segment.c | 2 ++ 2 files changed, 4 insertions(+), 3 deletions(-) commit de5307e46d28aa26ffd6f2048398b6303e134a67 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Mon Apr 11 11:51:51 2016 -0700 f2fs: fix dropping inmemory pages in a wrong time When one reader closes its file while the other writer is doing atomic writes, f2fs_release_file drops atomic data resulting in an empty commit. This patch fixes this wrong commit problem by checking openess of the file. Process0 Process1 open file start atomic write write data read data close file f2fs_release_file() clear atomic data commit atomic write Reported-by: Miao Xie <miaoxie@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/file.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit ff37355886ac2082cee594aa949c08e2cfb33aa0 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Tue Mar 29 16:13:45 2016 -0700 f2fs: add BUG_ON to avoid unnecessary flow This patch adds BUG_ON instead of retrying loop. In the case of node pages, we already got this inode page, but unlocked it. By the fact that we don't truncate any node pages in operations, the page's mapping should be unchangeable. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/node.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 4a6de50d5408cdc699588119e2338e580adc2b73 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Mar 30 11:25:31 2016 -0700 f2fs: use PGP_LOCK to check its truncation Previously, after trylock_page is succeeded, it doesn't check its mapping. In order to fix that, we can just give PGP_LOCK to pagecache_get_page. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/node.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit 675f10bde6cc3874632a8f684df2a8a2a8ace76e Author: Chao Yu <chao2.yu@samsung.com> Date: Mon Feb 22 18:29:18 2016 +0800 f2fs: fix to convert inline directory correctly With below serials, we will lose parts of dirents: 1) mount f2fs with inline_dentry option 2) echo 1 > /sys/fs/f2fs/sdX/dir_level 3) mkdir dir 4) touch 180 files named [1-180] in dir 5) touch 181 in dir 6) echo 3 > /proc/sys/vm/drop_caches 7) ll dir ls: cannot access 2: No such file or directory ls: cannot access 4: No such file or directory ls: cannot access 5: No such file or directory ls: cannot access 6: No such file or directory ls: cannot access 8: No such file or directory ls: cannot access 9: No such file or directory ... total 360 drwxr-xr-x 2 root root 4096 Feb 19 15:12 ./ drwxr-xr-x 3 root root 4096 Feb 19 15:11 ../ -rw-r--r-- 1 root root 0 Feb 19 15:12 1 -rw-r--r-- 1 root root 0 Feb 19 15:12 10 -rw-r--r-- 1 root root 0 Feb 19 15:12 100 -????????? ? ? ? ? ? 101 -????????? ? ? ? ? ? 102 -????????? ? ? ? ? ? 103 ... The reason is: when doing the inline dir conversion, we didn't consider that directory has hierarchical hash structure which can be configured through sysfs interface 'dir_level'. By default, dir_level of directory inode is 0, it means we have one bucket in hash table located in first level, all dirents will be hashed in this bucket, so it has no problem for us to do the duplication simply between inline dentry page and converted normal dentry page. However, if we configured dir_level with the value N (greater than 0), it will expand the bucket number of first level hash table by 2^N - 1, it hashs dirents into different buckets according their hash value, if we still move all dirents to first bucket, it makes incorrent locating for inline dirents, the result is, although we can iterate all dirents through ->readdir, we can't stat some of them in ->lookup which based on hash table searching. This patch fixes this issue by rehashing dirents into correct position when converting inline directory. Signed-off-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/dir.c | 87 ++++++++++++++++++++++++--------------------- fs/f2fs/f2fs.h | 4 ++- fs/f2fs/inline.c | 94 ++++++++++++++++++++++++++++++++++++++++++++++++- include/linux/f2fs_fs.h | 2 ++ 4 files changed, 144 insertions(+), 43 deletions(-) commit 8c11a53fc2557eb247e3eaa4d554d45c1b55fc98 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Fri Mar 18 09:46:10 2016 -0700 f2fs: show current mount status This patch remains the current mount status to f2fs status info. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/debug.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit faa0e55bba54b91c464850dc28376056d26fa310 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Thu Mar 24 10:29:39 2016 -0700 f2fs: treat as a normal umount when remounting ro When user remounts f2fs as read-only, we can mark the checkpoint as umount. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 6781eabba1bdb133eb9125c4acf6704ccbe4df02 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Mar 23 16:12:58 2016 -0700 f2fs: give -EINVAL for norecovery and rw mount Once detecting something to recover, f2fs should stop mounting, given norecovery and rw mount options. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 2 +- fs/f2fs/recovery.c | 11 +++++++---- fs/f2fs/super.c | 14 ++++++++++++-- 3 files changed, 20 insertions(+), 7 deletions(-) commit df728b0f6954c38545f4bf12dedeeb9e07469a94 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Mar 23 17:05:27 2016 -0700 f2fs: recover superblock at RW remounts This patch adds a sbi flag, SBI_NEED_SB_WRITE, which indicates it needs to recover superblock when (re)mounting as RW. This is set only when f2fs is mounted as RO. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/f2fs.h | 1 + fs/f2fs/super.c | 36 +++++++++++++++++++++++++++--------- 2 files changed, 28 insertions(+), 9 deletions(-) commit f2353d7bd4221dfe0e230c5be49038d4a57d97e9 Author: Jaegeuk Kim <jaegeuk@kernel.org> Date: Wed Mar 23 10:42:01 2016 -0700 f2fs: give RO message when recovering superblock When one of superblocks is missing, f2fs recovers it with the valid one. But, even if f2fs is mounted as RO, we'd better notify that too. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> fs/f2fs/super.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit d4f414e559caf36d811213e56b56e9b6957caab1 Author: Tony Lindgren <tony@atomide.com> Date: Fri Apr 15 08:45:33 2016 -0700 ARM: OMAP2+: Simplify auxdata by using the generic match We can now just use the compatible if there's no need to have device instance specific auxdata. Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/pdata-quirks.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) commit fc5cf80ac4e0b2727c7af1a70bca277b82771cf3 Author: Tony Lindgren <tony@atomide.com> Date: Fri Apr 15 08:45:32 2016 -0700 of/platform: Allow secondary compatible match in of_dev_lookup We currently try to match of_dev_auxdata based on compatible, IO address, and device name. But in some cases we have multiple instances of drivers that can use the same auxdata. Let's add an additional secondary lookup for generic compatible match for auxdata if no device specific match is found. This does not change the existing matching, and still allows adding device specific auxdata. This simplifies things as specifying the IO address and device name is prone errors as it requires maintaining an in kernel database for each SoC. To specify a generic match, all that is needed is to add a OF_DEV_AUXDATA entry with no device instance specified: OF_DEV_AUXDATA("pinctrl-single", 0, NULL, &pcs_pdata), As the auxdata is already initialized only for the booted SoC, there's not much of a chance of getting things wrong. Let's also fix two checkpatch warnings while at it to add a space before parenthesis in the for loop, and remove a comparison to NULL by using !auxdata->compatible. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> drivers/of/platform.c | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) commit 841478d4ae2cb7205fc7940e7140ef0efb3fabf7 Author: Guodong Xu <guodong.xu@linaro.org> Date: Wed Apr 13 07:55:52 2016 +0800 arm64: dts: add wifi nodes support for hi6220-hikey Add wifi nodes support for hi6220-hikey Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 29 ++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit d6b259d4faa1670f372969141323c6fe4b3b7db9 Author: Xinwei Kong <kong.kongxinwei@hisilicon.com> Date: Wed Apr 13 07:55:51 2016 +0800 arm64: dts: add dwmmc nodes for hi6220 Add all three dwmmc nodes description for hi6220 Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 52 +++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) commit a817137a6c3079c99954396afe94bb5a7cbfa251 Author: Chen Feng <puck.chen@hisilicon.com> Date: Wed Apr 13 07:55:50 2016 +0800 arm64: dts: hikey: Add hi655x pmic dts node Add the mfd hi655x dts node and regulator support on hi6220 platform. Signed-off-by: Chen Feng <puck.chen@hisilicon.com> Signed-off-by: Fei Wang <w.f@huawei.com> Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Haojian Zhuang <haojian.zhuang@linaro.org> Reviewed-by: Rob Herring <robh@kernel.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 87 +++++++++++++++++++++++++- 1 file changed, 86 insertions(+), 1 deletion(-) commit ad05f38ba98ab01aebf52cc1d788df8272e6daa8 Author: Guodong Xu <guodong.xu@linaro.org> Date: Wed Apr 13 07:55:49 2016 +0800 arm64: dts: add LED nodes for hi6220-hikey Add LED nodes for hi6220-hikey. There are total 6 LEDs on HiKey. Four general purposed, one for WiFi activity, and one for Bluetooth activity. Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 41 ++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit c2aad93200fa2dbbc6c48632e619494080d64796 Author: Guodong Xu <guodong.xu@linaro.org> Date: Wed Apr 13 07:55:48 2016 +0800 arm64: dts: hi6220: add pinctrl for uarts and enable them Add pinctrl for uart2 uart3 and uart4. Enable uart1 uart2 and uart3. Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 12 ++++++++++++ arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 9 +++++++++ 2 files changed, 21 insertions(+) commit 998605407249dd278aef28c1cc2ce00f90c09eaa Author: Leo Yan <leo.yan@linaro.org> Date: Wed Apr 13 07:55:47 2016 +0800 arm64: dts: add Hi6220's stub clock node Enable SRAM node and stub clock node for Hi6220, which uses mailbox channel 1 for CPU's frequency change. Furthermore, add the CPU clock phandle in CPU's node and using operating-points-v2 to register operating points. So can be used by cpufreq-dt driver. Signed-off-by: Leo Yan <leo.yan@linaro.org> Acked-by: Jassi Brar <jassisinghbrar@gmail.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 56 +++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) commit 8607357016f6b643787727cf35ecdcfb49c3cf23 Author: Leo Yan <leo.yan@linaro.org> Date: Wed Apr 13 07:55:46 2016 +0800 arm64: dts: add mailbox node for Hi6220 This patch add device mailbox node for Hi6220 in DT. Signed-off-by: Leo Yan <leo.yan@linaro.org> Acked-by: Jassi Brar <jassisinghbrar@gmail.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) commit b4b31a7cd797dcadba32a2f283923aec7583462e Author: Zhangfei Gao <zhangfei.gao@linaro.org> Date: Wed Apr 13 07:55:45 2016 +0800 arm64: dts: Add hi6220 usb node Add USB nodes for Hi6220 Signed-off-by: Zhangfei Gao <zhangfei.gao@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 32 +++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit 0c2317512d51f62401fdb7dd9d2ab5c932ac0ab9 Author: Guodong Xu <guodong.xu@linaro.org> Date: Wed Apr 13 07:55:44 2016 +0800 arm64: dts: hikey: enable i2c0 and i2c1 for working with mezzanine boards In HiKey board dts file, enable i2c0 and i2c1 for working with 96boards' LS mezzanine. Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 8 ++++++++ 1 file changed, 8 insertions(+) commit 5ff3a4ddd142ac2ac4e6d4aa65cf0f7bf2d9679a Author: Xinwei Kong <kong.kongxinwei@hisilicon.com> Date: Wed Apr 13 07:55:43 2016 +0800 arm64: dts: add all hi6220 i2c nodes This patch adds all I2C nodes for the Hi6220 SoC. This hi6220 Soc use this I2C IP of Synopsys Designware for HiKey board. Signed-off-by: Xinwei Kong <kong.kongxinwei@hisilicon.com> Signed-off-by: Chen Feng <puck.chen@hisilicon.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 33 +++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 60dac1b19b6af6ddc4df68d163e2d7508057c007 Author: Zhong Kaihua <zhongkaihua@huawei.com> Date: Wed Apr 13 07:55:42 2016 +0800 arm64: dts: add Hi6220 spi configuration nodes Add Hi6220 spi configuration nodes. Disable by default in hi6220.dtsi and enable it in board dts for usage of 96boards LS mezzanine board. Signed-off-by: Zhong Kaihua <zhongkaihua@huawei.com> Signed-off-by: Guodong Xu <guodong.xu@linaro.com> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 6 ++++++ arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 15 +++++++++++++++ arch/arm64/boot/dts/hisilicon/hikey-pinctrl.dtsi | 21 +++++++++++++++++++++ 3 files changed, 42 insertions(+) commit 379e9bf52daaaa841ecc4eed3f2c5c86845c45a9 Author: Zhong Kaihua <zhongkaihua@huawei.com> Date: Wed Apr 13 07:55:41 2016 +0800 arm64: dts: add Hi6220 pinctrl configuration nodes Add Hi6220 pinctrl configuration nodes Signed-off-by: Zhong Kaihua <zhongkaihua@huawei.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Haojian Zhuang <haojian.zhuang@linaro.org> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 1 + arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 77 +++ arch/arm64/boot/dts/hisilicon/hikey-pinctrl.dtsi | 684 +++++++++++++++++++++++ include/dt-bindings/pinctrl/hisi.h | 59 ++ 4 files changed, 821 insertions(+) commit f2bfacf9ddcff49103c08ee7e83bf3fffe6e37ba Author: Zhong Kaihua <zhongkaihua@huawei.com> Date: Wed Apr 13 07:55:40 2016 +0800 arm64: dts: Add Hi6220 gpio configuration nodes Add Hi6220 gpio configuration nodes Signed-off-by: Zhong Kaihua <zhongkaihua@huawei.com> Signed-off-by: Kong Xinwei <kong.kongxinwei@hisilicon.com> Signed-off-by: Guodong Xu <guodong.xu@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 239 ++++++++++++++++++++++++++++++ 1 file changed, 239 insertions(+) commit 4d88d5a7bf92e31215543b955b8883dcf6f66c1f Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Apr 15 17:51:06 2016 +0300 PCI: acpiphp_ibm: Avoid uninitialized variable reference If ibm_get_table_from_acpi() fails then "table" isn't initialized. Check for failure so we don't reference "table" unless it's been initialized. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/hotplug/acpiphp_ibm.c | 2 ++ 1 file changed, 2 insertions(+) commit 58fa29bfbe5e908e0f5d2627c5f15001696b1666 Author: Leo Yan <leo.yan@linaro.org> Date: Wed Apr 13 07:55:39 2016 +0800 arm64: dts: enable idle states for Hi6220 Add cpu and cluster level's low power state for Hi6220. Acked-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 9e92703165d982b3df35e551c4d15a93ab9fba3d Author: Leo Yan <leo.yan@linaro.org> Date: Wed Apr 13 07:55:38 2016 +0800 arm64: dts: add sp804 timer node for Hi6220 Add sp804 timer for hi6220, so it can be used as broadcast timer. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 6da3aba6f056b861c9f54ef104425ceb5e9389ad Author: Leo Yan <leo.yan@linaro.org> Date: Wed Apr 13 07:55:37 2016 +0800 arm64: dts: Reserve memory regions for hi6220 On Hi6220, below memory regions in DDR have specific purpose: 0x05e0,0000 - 0x05ef,ffff: For MCU firmware using at runtime; 0x06df,f000 - 0x06df,ffff: For mailbox message data; 0x0740,f000 - 0x0740,ffff: For MCU firmware's section; 0x3e00,0000 - 0x3fff,ffff: For OP-TEE. This patch reserves these memory regions in DT. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Wei Xu <xuwei5@hisilicon.com> arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit 5f575efea79caae69b81f922d99b221302a2c003 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 14 10:51:42 2016 +0200 crypto: lzo - get rid of superfluous __GFP_REPEAT __GFP_REPEAT has a rather weak semantic but since it has been introduced around 2.6.12 it has been ignored for low order allocations. lzo_init uses __GFP_REPEAT to allocate LZO1X_MEM_COMPRESS 16K. This is order 3 allocation request and __GFP_REPEAT is ignored for this size as well as all <= PAGE_ALLOC_COSTLY requests. Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: "David S. Miller" <davem@davemloft.net> Cc: linux-crypto@vger.kernel.org Signed-off-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> crypto/lzo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit afc39d6e89b4f410f511f03dc6de8dc1d4952d42 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Wed Apr 13 18:11:28 2016 +0800 hwrng: hisi - Add support for Hisilicon SoC RNG This adds the Hisilicon Random Number Generator(RNG) support, which is found in Hip04 and Hip05 soc. Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/Kconfig | 13 ++++ drivers/char/hw_random/Makefile | 1 + drivers/char/hw_random/hisi-rng.c | 126 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 140 insertions(+) commit c7995ee7ff60c1973a3a63e35b41c2393f47f760 Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Wed Apr 13 18:11:27 2016 +0800 dt/bindings: Add bindings for hisilicon random number generator Document the devicetree bindings for the random number generator found on Hisilicon Hip04 and Hip05 soc. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Acked-by: Rob Herring <rob@kernel.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Documentation/devicetree/bindings/rng/hisi-rng.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit d293b640ebd532eb9d65bc42d48fb9d2c06e71c9 Author: Steffen Trumtrar <s.trumtrar@pengutronix.de> Date: Tue Apr 12 11:04:26 2016 +0200 crypto: mxc-scc - add basic driver for the MXC SCC According to the Freescale GPL driver code, there are two different Security Controller (SCC) versions: SCC and SCC2. The SCC is found on older i.MX SoCs, e.g. the i.MX25. This is the version implemented and tested here. As there is no publicly available documentation for this IP core, all information about this unit is gathered from the GPL'ed driver from Freescale. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/Kconfig | 9 + drivers/crypto/Makefile | 1 + drivers/crypto/mxc-scc.c | 762 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 772 insertions(+) commit ba97eed2b62e97ab6a96d27ea6a049f3a815237c Author: Steffen Trumtrar <s.trumtrar@pengutronix.de> Date: Tue Apr 12 11:04:25 2016 +0200 ARM: i.MX25: add scc module to dtsi Add the Security Controller (SCC) module to the dtsi. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> arch/arm/boot/dts/imx25.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit ff0078f0b047520405db14ef0deecde5898b50a4 Author: Steffen Trumtrar <s.trumtrar@pengutronix.de> Date: Tue Apr 12 11:04:24 2016 +0200 Documentation: devicetree: add Freescale SCC bindings Add documentation for the Freescale Security Controller (SCC) found on i.MX25 SoCs. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> .../devicetree/bindings/crypto/fsl-imx-scc.txt | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit d6064165ba4449ea085a389724d728258a3180ec Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Wed Apr 6 11:01:54 2016 -0700 crypto: qat - adf_dev_stop should not be called in atomic context VFs call adf_dev_stop() from a PF to VF interrupt bottom half. This causes an oops "scheduling while atomic", because it tries to acquire a mutex to un-register crypto algorithms. This patch fixes the issue by calling adf_dev_stop() asynchronously. Changes in v2: - change kthread to a work queue. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_common_drv.h | 2 + drivers/crypto/qat/qat_common/adf_ctl_drv.c | 6 +++ drivers/crypto/qat/qat_common/adf_vf_isr.c | 59 ++++++++++++++++++++++++-- 3 files changed, 64 insertions(+), 3 deletions(-) commit 7587c407540006e4e8fd5ed33f66ffe6158e830a Author: Mike Galbraith <umgwanakikbuti@gmail.com> Date: Tue Apr 5 15:03:21 2016 +0200 crypto: ccp - Fix RT breaking #include <linux/rwlock_types.h> Direct include of rwlock_types.h breaks RT, use spinlock_types.h instead. Fixes: 553d2374db0b crypto: ccp - Support for multiple CCPs Signed-off-by: Mike Galbraith <umgwanakikbuti@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/ccp/ccp-dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6eae29e7e7144d01a6d6af111d232b36cdd30f51 Author: Eric Biggers <ebiggers3@gmail.com> Date: Sat Apr 2 10:54:56 2016 -0500 crypto: doc - document correct return value for request allocation Signed-off-by: Eric Biggers <ebiggers3@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Documentation/DocBook/crypto-API.tmpl | 6 +++--- include/crypto/aead.h | 3 +-- include/crypto/hash.h | 3 +-- include/crypto/skcipher.h | 3 +-- include/linux/crypto.h | 3 +-- 5 files changed, 7 insertions(+), 11 deletions(-) commit c686090f14e0673f9b1a3aec316098742f8e003c Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 12 18:00:53 2016 +0200 gpio/reset: move gpio-{poweroff|restart} DT doc to proper place I did only find them after a fuzzy search, so let them be where one would expect them. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-By: Sebastian Reichel <sre@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> .../devicetree/bindings/gpio/gpio-poweroff.txt | 36 --------------- .../devicetree/bindings/gpio/gpio-restart.txt | 54 ---------------------- .../bindings/power/reset/gpio-poweroff.txt | 36 +++++++++++++++ .../bindings/power/reset/gpio-restart.txt | 54 ++++++++++++++++++++++ 4 files changed, 90 insertions(+), 90 deletions(-) commit be19b10d24e3c22f6bf58d8211071a09ae23b14f Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Fri Apr 15 11:34:53 2016 +0100 drm/i915: Show pin mapped counts and sizes in debugfs Show a total and purgeable number of pin mapped objects and their total and purgeable size. Example output (new stat prefixed with a star): # cat i915_gem_objects 19920 objects, 289243136 bytes 19920 [18466] objects, 288714752 [267911168] bytes in gtt 0 [0] active objects, 0 [0] bytes 19917 [18466] inactive objects, 288714752 [267911168] bytes 0 unbound objects, 0 bytes 0 purgeable objects, 0 bytes 1 pinned mappable objects, 3145728 bytes 0 fault mappable objects, 0 bytes * 19914 [0] pin mapped objects, 285560832 [0] bytes [purgeable] 4294967296 [268435456] gtt total Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460716493-27826-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_debugfs.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit be12a86b46e8b501611bbf4bf96f83fdd5748252 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Fri Apr 15 11:34:52 2016 +0100 drm/i915: Show pin mapped status in describe_obj Reflect the status of obj->mapping as added with the i915_gem_object_pin_map API. 'M' was chosen to designate the pin mapped status. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) commit 8d53957c66e5cc0f1e8d33807800271d0f4fa009 Author: Rhyland Klein <rklein@nvidia.com> Date: Thu Apr 14 15:57:18 2016 -0400 arm64: tegra: Enable cros-ec and charger on Smaug Add nodes for the ChromeOS Embedded Controller and for the gas gauge connected to the I2C bus that it controls. Signed-off-by: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210-smaug.dts | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit a19c921fca0a865b657d59b2c9a05aa0a2905126 Author: Takashi Iwai <tiwai@suse.de> Date: Fri Apr 15 15:28:52 2016 +0200 ALSA: lx646es: Fix possible uninitialized variable reference lx_pipe_state() checks the return value from lx_message_send_atomic() and breaks the loop only when it's a negative value. However, lx_message_send_atomic() may return a positive error code (as the return code from the hardware), and then lx_pipe_state() tries to compare the uninitialized current_state variable. Fix this behavior by checking the positive non-zero error code as well. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/lx6464es/lx_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 234126c6c957cc3e68dbacd12ab0c14b7e03da86 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 22:14:38 2016 +0300 drm/i915: Reject 'Center' scaling mode for eDP/DSI on GMCH platforms We don't have a LVDS_BORDER_ENABLE type of bit for either eDP or DSI, and just trying to frob the display timings to include borders results in a corrupted picture. So reject the 'Center' scaling mode on GMCH platforms for eDP and DSI. TODO: Should really filter out the unsupported modes from the prop, but that would be fairly invasive since the prop is now created and stored by drm core. So leave it for a rainy day. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460488478-18311-6-git-send-email-ville.syrjala@linux.intel.com Tested-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dp.c | 5 +++++ drivers/gpu/drm/i915/intel_dsi.c | 5 +++++ 2 files changed, 10 insertions(+) commit f4ee265f2f0631883456dbc971b21aa7525c4a77 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 22:14:37 2016 +0300 drm/i915: Hook up pfit for DSI Add the scaling mode property to DSI connectors, handle changes in the property value, and compute the panel fitter state during .compute_config(). v2: Handle BXT as well Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460488478-18311-5-git-send-email-ville.syrjala@linux.intel.com Tested-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi.c | 73 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 68 insertions(+), 5 deletions(-) commit 062efa5d841cca5e0df5b45c624966cb9936438c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 22:14:36 2016 +0300 drm/i915: Eliminate {vlv,bxt}_configure_dsi_pll() Fold the DSI PLL configuration functions into the DSI PLL enable functions since they are small and not called from anywhere else. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460488478-18311-4-git-send-email-ville.syrjala@linux.intel.com Tested-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi_pll.c | 28 ++++++---------------------- 1 file changed, 6 insertions(+), 22 deletions(-) commit 47eacbabcbbe34d12efebae4820ac1613a28bcb7 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 22:14:35 2016 +0300 drm/i915: Compute DSI PLL parameters during .compute_config() Compute the DSI PLL parameters during .compute_config() rather than .pre_pll_enable() so that we can fail gracefully if we can't find suitable parameters. In order to do that we need to store the DSI PLL parameters in pipe_config. v2: Handle BXT too Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460488478-18311-3-git-send-email-ville.syrjala@linux.intel.com Tested-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 3 + drivers/gpu/drm/i915/intel_drv.h | 5 ++ drivers/gpu/drm/i915/intel_dsi.c | 15 ++-- drivers/gpu/drm/i915/intel_dsi.h | 14 ++-- drivers/gpu/drm/i915/intel_dsi_pll.c | 156 +++++++++++++++++++---------------- 5 files changed, 112 insertions(+), 81 deletions(-) commit cd2d34d9b61ff4535eb6c8e49cf26acc0c55c712 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 22:14:34 2016 +0300 drm/i915: Setup DPLL/DPLLMD for DSI too on VLV/CHV Set up DPLL and DPLL_MD even when driving DSI output on VLV/CHV. While the DPLL isn't used to provide the clock we still need the refclock, and it appears that the pixel repeat factor also has an effect on DSI output. So set up eveyrhing in DPLL and DPLL_MD as we would do for DP/HDMI/VGA, but don't actually enable the DPLL or configure the dividers via DPIO. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460488478-18311-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> Tested-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 120 +++++++++++++++++++++-------------- drivers/gpu/drm/i915/intel_dsi.c | 28 ++------ 2 files changed, 80 insertions(+), 68 deletions(-) commit da6110bcbc0837eddf6292a0f8cb72f00507fde8 Author: Dongwon Kim <dongwon.kim@intel.com> Date: Thu Apr 14 15:37:43 2016 -0700 drm/i915/bxt: PORT_PLL_REF_SEL bit should be set for all BXT variations This patch is to correct one thing in this commit: commit 25a56705332add0363e47b3a0eca001d6fbd5bec Author: Dongwon Kim <dongwon.kim@intel.com> Date: Wed Mar 16 18:06:13 2016 -0700 drm/i915/bxt: Reversed polarity of PORT_PLL_REF_SEL bit This reversed bit polarity is actually common for all BXT and APL SoCs. Therefore, revision checking in the original commit should be removed to make the bit set regardless of revision ID of GFX block. Signed-off-by: Dongwon Kim <dongwon.kim@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460673463-14453-1-git-send-email-dongwon.kim@intel.com drivers/gpu/drm/i915/intel_dpll_mgr.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 1652fce65f70f104ffd0df0284b601d9103e1ebf Author: Lyude <cpaul@redhat.com> Date: Wed Apr 13 16:50:18 2016 -0400 drm/dp/mst: Restore primary hub guid on resume Some hubs are forgetful, and end up forgetting whatever GUID we set previously after we do a suspend/resume cycle. This can lead to hotplugging breaking (along with probably other things) since the hub will start sending connection notifications with the wrong GUID. As such, we need to check on resume whether or not the GUID the hub is giving us is valid. Signed-off-by: Lyude <cpaul@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Reviewed-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460580618-7421-1-git-send-email-cpaul@redhat.com drivers/gpu/drm/drm_dp_mst_topology.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit f6cd7daecff558fab2c45d15283d3e52f688342d Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 15 12:55:08 2016 +0100 drm: Release driver references to handle before making it available again When userspace closes a handle, we remove it from the file->object_idr and then tell the driver to drop its references to that file/handle. However, as the file/handle is already available again for reuse, it may be reallocated back to userspace and active on a new object before the driver has had a chance to drop the old file/handle references. Whilst calling back into the driver, we have to drop the file->table_lock spinlock and so to prevent reusing the closed handle we mark that handle as stale in the idr, perform the callback and then remove the handle. We set the stale handle to point to the NULL object, then any idr_find() whilst the driver is removing the handle will return NULL, just as if the handle is already removed from idr. Note: This will be used to have a direct handle -> vma lookup table, instead of first a handle -> obj lookup, and then an (obj, vm) -> vma lookup. v2: Use NULL rather than an ERR_PTR to avoid having to adjust callers. idr_alloc() tracks existing handles using an internal bitmap, so we are free to use the NULL object as our stale identifier. v3: Needed to update the return value check after changing from using the stale error pointer to NULL. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: dri-devel@lists.freedesktop.org Cc: David Airlie <airlied@linux.ie> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Rob Clark <robdclark@gmail.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Thierry Reding <treding@nvidia.com> [danvet: Add note about the use-case.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460721308-32405-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/drm_gem.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 40ae80cc036df1d90d26cd7885d9da1b9d33744b Author: Jim Bride <jim.bride@linux.intel.com> Date: Thu Apr 14 10:18:37 2016 -0700 drm/i915/dp/mst: Add source port info to debugfs output Modify the debugfs output for i915_dp_mst_info to list the source port for the DP MST topology in question. v2: rebase v3: rebase v4: rebase cc: Jani Nikula <jani.nikula@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jim Bride <jim.bride@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460654317-31288-3-git-send-email-jim.bride@linux.intel.com drivers/gpu/drm/i915/i915_debugfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 51108f252b02d3b94527c2416791147b8b8ec939 Author: Jim Bride <jim.bride@linux.intel.com> Date: Thu Apr 14 10:18:36 2016 -0700 drm/dp/mst: Enhance DP MST debugfs output Add some additional information (input vs. output port, sink associated with VC, peer device type, max number of VCs supported) and ensure that any embedded '\0' characters in a branch device's devid string are not written to debugfs. v2: Rebase + change drm_edid_get_monitor_name() call to reflect new signature. v3: Minor changes suggested by Jani + rebase. v4: Rebase cc: dri-devel@lists.freedesktop.org cc: Jani Nikula <jani.nikula@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jim Bride <jim.bride@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460654317-31288-2-git-send-email-jim.bride@linux.intel.com drivers/gpu/drm/drm_dp_mst_topology.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) commit 59f7c0fa325e5661188a174a435ea4925543985b Author: Jim Bride <jim.bride@linux.intel.com> Date: Thu Apr 14 10:18:35 2016 -0700 drm/edid: Add drm_edid_get_monitor_name() In order to include monitor name information in debugfs output we needed to add a function that would extract the monitor name from the EDID, and that function needed to reside in the file where the rest of the EDID helper functions are implemented. v2: Refactor to have drm_edid_get_monitor_name() and drm_edid_to_eld() use a common helper function to extract the monitor name from the edid. [Jani] + rebase. v3: Minor changes suggested by Jani + rebase. v4: Few more minor changes suggested by Jani + rebase. cc: dri-devel@lists.freedesktop.org cc: Jani Nikula <jani.nikula@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Jim Bride <jim.bride@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460654317-31288-1-git-send-email-jim.bride@linux.intel.com drivers/gpu/drm/drm_edid.c | 51 ++++++++++++++++++++++++++++++++++++++-------- include/drm/drm_crtc.h | 2 ++ 2 files changed, 44 insertions(+), 9 deletions(-) commit 8f6d855c4b8a032691816723307d960a5b2c0b6d Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:47 2016 +0300 drm/i915/bxt: Enable runtime PM With the preceding fixes runtime PM should be functional, I could runtime suspend/resume the device without problems. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: David Weinehall <david.weinehall@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-17-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f11f4e952494eca12429763af24b513866a97f61 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:46 2016 +0300 Revert "drm/i915/bxt: Disable power well support" With the preceding fixes power well support should be functional on Broxton, I could enter/exit DC5 without problems. This reverts commit 18024199579882265653bfe9e2b1a3dcb5697cd9. CC: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: David Weinehall <david.weinehall@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-16-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 5 ----- 1 file changed, 5 deletions(-) commit adc7f04bfda9cd0b2b4b84b5e8b72fd4c7b56d0a Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 4 17:27:10 2016 +0300 drm/i915/bxt: Add HW state verification for DDI PHY and CDCLK I caught a few errors in our current PHY/CDCLK programming by sanity checking the actual programmed state, so I thought it would be also useful for the future. In addition to verifying the state after programming it also verify it after exiting DC5, to make sure DMC restored/kept intact everything related. v2: - Inlining __phy_reg_verify_state() doesn't make sense and also incorrect, so don't do it (PW/CI gcc) v3: - Rebase on latest -nightly Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: David Weinehall <david.weinehall@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459780030-15781-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_ddi.c | 124 +++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_display.c | 5 ++ drivers/gpu/drm/i915/intel_drv.h | 2 + drivers/gpu/drm/i915/intel_runtime_pm.c | 8 +++ 5 files changed, 138 insertions(+), 2 deletions(-) commit bd480061788fe2f657daba7e519c9175b7dba968 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:44 2016 +0300 drm/i915/bxt: Don't reprogram an already enabled DDI PHY If BIOS has already programmed and enabled a PHY, don't reprogram it as that may interfere with the currently active outputs. A follow-up patch will add state verification, so we can catch any misconfiguration on BIOS's behalf. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-14-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit c2e001ef84122b2d9c901789463ef79d1b326804 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:43 2016 +0300 drm/i915/bxt: Sanitize the DBUF HW state together with CDCLK When determining whether CDCLK is enabled by BIOS and so we should skip reprogramming it, we didn't check the related DBUF power request and state. In theory BIOS could enable one without the other so check for this case and reprogram things if something is amiss. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-13-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_display.c | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) commit d7d7c9ee699a0b85de0023433cdbd8f965e1ac08 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:42 2016 +0300 drm/i915/bxt: Don't toggle power well 1 on-demand Power well 1 is managed by the DMC firmware so don't toggle it on-demand from the driver. This means we need to follow the BSpec display initialization sequence during driver loading and resuming (both system and runtime) and enable power well 1 only once there. Afterwards DMC will toggle power well 1 whenever entering/exiting DC5. For this to work we also need to do away getting the PLL power domain, since that just kept runtime PM disabled for good. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-12-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 15 +------ drivers/gpu/drm/i915/intel_display.c | 17 -------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 5 +-- drivers/gpu/drm/i915/intel_drv.h | 2 + drivers/gpu/drm/i915/intel_runtime_pm.c | 75 +++++++++++++++++++++++++++------ 5 files changed, 66 insertions(+), 48 deletions(-) commit d7d33fd85a6574ddce4cc0340f1856434b6a38ec Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:41 2016 +0300 drm/i915/bxt: Power down DDI PHYs separately during the per PHY uninit The power-down step logically belongs to the individual PHY uninit sequence so move it there. The only functional change is that we will power down now PHY 1 separately before PHY 0 and preserve the other bits in the register which are defined as reserved. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-11-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit c6c4696fa52323b873e794b3efa88acc7378a78d Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:40 2016 +0300 drm/i915/bxt: Pass drm_i915_private to DDI PHY, CDCLK helpers For internal APIs passing dev_priv is preferred to reduce indirections, so convert over a few DDI PHY, CDCLK helpers. No functional change. Signed-off-by: Imre Deak <imre.deak@intel.com> Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: David Weinehall <david.weinehall@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-10-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 12 ++++-------- drivers/gpu/drm/i915/intel_ddi.c | 10 ++++------ drivers/gpu/drm/i915/intel_display.c | 18 +++++++----------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 4 ++-- drivers/gpu/drm/i915/intel_drv.h | 8 ++++---- 5 files changed, 21 insertions(+), 31 deletions(-) commit 443a93ac89aa112b133dca6a23ca2d315253f6ae Author: Imre Deak <imre.deak@intel.com> Date: Mon Apr 4 15:42:57 2016 +0300 drm/i915/skl: Unexport skl_pw1_misc_io_init On Broxton we need to enable/disable power well 1 during the init/unit display sequence similarly to Skylake/Kabylake. The code for this will be added in a follow-up patch, but to prepare for that unexport skl_pw1_misc_io_init(). It's a simple function called only from a single place and having it inlined in the Skylake display core init/unit functions will make it easier to compare it with its Broxton counterpart. This also flips the order of Misc IO and power well 1 disabling which matches the enabling order. The specification doesn't prescribe the disabling order, so this should be fine. v2: - Fix incorrect enable vs. disable power well call in skl_display_core_uninit() (Patrik) - Add commit comment about chaning the order of PW1 and Misc IO power well disabling (Patrik) CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459773777-10701-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_drv.h | 2 -- drivers/gpu/drm/i915/intel_runtime_pm.c | 49 ++++++++++++--------------------- 2 files changed, 18 insertions(+), 33 deletions(-) commit a7c8125f464ce798fe0962e0fd837802e7bf28cc Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:38 2016 +0300 drm/i915/bxt: Suspend power domains during suspend-to-idle On SKL/KBL suspend-to-idle (aka freeze/s0ix) is performed with DMC firmware assistance where the target display power state is DC6. On Broxton on the other hand we don't use the firmware for this, but rely instead on a manual DC9 flow. For this we have to uninitialize the display following the BSpec display uninit sequence, just as during S3/S4, so make sure we follow this sequence. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-8-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit bfcdabe888af718b917a8b871f3cdce0ebed3c35 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:37 2016 +0300 drm/i915/gen9: Fix DMC/DC state asserts The display power well support and DC state management doesn't depend on runtime PM support, so remove the incorrect asserts about this. Also Broxton does support DC5, so the related assert in assert_can_enable_dc5() is incorrect. There is a more generic and correct assert for this already in gen9_set_dc_state(), so we can remove all the other ones. At the same time convert WARNs to WARN_ONCE for consistency with the other DC state asserts. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-7-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 32 +++++++++++--------------------- 1 file changed, 11 insertions(+), 21 deletions(-) commit 1d963afae1f427c97cbcf22ea905585339951c3b Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:36 2016 +0300 drm/i915/gen9: Make power well disabling synchronous So far we only power well enabling was synchronous not disabling. Since we don't exactly know how the firmware (both DMC and PCU) synchronizes against the actual power well state during DC transitions, make the disabling also synchronous. CC: Mika Kuoppala <mika.kuoppala@linux.intel.com> CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-6-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit c6782b76d31a5ecae8e5da8483fa1811c133458f Author: Imre Deak <imre.deak@intel.com> Date: Tue Apr 5 13:26:05 2016 +0300 drm/i915/gen9: Reset secondary power well requests left on by DMC/KVMR DMC forces on power well 1 and the misc IO power well by setting the corresponding request bits both in the BIOS and the DEBUG power well request registers. This is somewhat unexpected since the firmware should really just save and restore state but not alter it. We also depend on being able to disable power well 1, and the misc IO power well before entering S3/S4 on BXT and SKL or entering DC9 on BXT. To fix this make sure these request bits are cleared whenever we want to disable the given power wells. On SKL there is another twist where the firmware also clears the power well 1 request bit in HSW_POWER_WELL_DRIVER (but not that of the misc IO power well). This happens to not cause a problem due to the forced-on request bits in the other request registers. I've filed a bug about all this, but fixing that may take a while and having this sanity check in place makes sense even for future firmware versions. At the same time also check the KVMR request bits. I haven't seen this being altered, but we don't expect any request bits in here either, so sanitize this register as well. v2: - Apply the workaround on SKL as well. I noticed the related failure from the CI report, later Patrik also reported seeing it on his machine. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459851965-6137-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 41 +++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit 28ca6931f07f83a397e10493a798c1f00c415c40 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:34 2016 +0300 drm/i915/bxt: Add a note about BXT_PORT_CL1CM_DW30 being read-only This register is read-only, so we have never actually set OCL2_LDOFUSE_PWR_DIS in it as specified by the specification. Add a code comment about this. I filed a specification update request to clarify this there. CC: Arthur J Runyan <arthur.j.runyan@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: David Weinehall <david.weinehall@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_ddi.c | 3 +++ 1 file changed, 3 insertions(+) commit d1e082ffb898bd9cf7cb58358917a415d2dd0a13 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:33 2016 +0300 drm/i915/bxt: Fix GRC code register field definitions This has been corrected in BSpec quite some time ago, but we missed it somehow. The wrong field definitions resulted in configuring PHY0 with an incorrect GRC value. v2: - Remove the FIXME comment, we left in the code exactly about this issue. (Ville) CC: Arthur J Runyan <arthur.j.runyan@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-3-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_reg.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit e7968531f86983a8f199818a7ffcaa380d1b4399 Author: Imre Deak <imre.deak@intel.com> Date: Fri Apr 1 16:02:32 2016 +0300 drm/i915/bxt: Reject DMC firmware versions with known bugs DMC version 1.06 has a known bug, where the firmware polls forever for a port PLL to lock, if the PLL was disabled when entering DC5, which locks up the machine. Version 1.07 fixes this, so make that the minimum required version on BXT. CC: Mika Kuoppala <mika.kuoppala@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459515767-29228-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_csr.c | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) commit 56ed4bb984acbba9cfe080e45ac4b50ca63dd188 Author: Koji Matsuoka <koji.matsuoka.xm@renesas.com> Date: Wed Apr 13 21:01:47 2016 +0300 pinctrl: sh-pfc: r8a7794: Add DU pin groups r8a7794 PFC DU support from the R-Car Gen2 v1.9.4 BSP [Magnus: added the description, added missing dot clock output signals, separated CDE and DISP signals, broke out the ODDF signal from the sync group.] [Sergei: resolved rejects, folded in Magnus' patches, killed empty lines, reordered pin/mux arrays and pin groups, fixed up some comments to the pin arrays, removed the "du" function splitting its groups between the "du0" and "du1" functions.] Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com> Signed-off-by: Magnus Damm <damm+renesas@opensource.se> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/pinctrl/sh-pfc/pfc-r8a7794.c | 217 +++++++++++++++++++++++++++++++++++ 1 file changed, 217 insertions(+) commit 2d8e1f039de842701d35a857a7c5d9d47bc1c639 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Apr 11 10:14:46 2016 +0300 iommu/amd: Signedness bug in acpihid_device_group() "devid" needs to be signed for the error handling to work. Fixes: b097d11a0fa3f ('iommu/amd: Manage iommu_group for ACPI HID devices') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4d4fb97a62105c07dcccd350c391a65f576726c4 Merge: 61bf12d 85baa09 Author: Jiri Kosina <jkosina@suse.cz> Date: Fri Apr 15 11:31:51 2016 +0200 Merge branch 'topic/livepatch' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux into for-4.7/livepatching-ppc64le Pull livepatching support for ppc64 architecture from Michael Ellerman. Signed-off-by: Jiri Kosina <jkosina@suse.cz> commit 10f22ee367c4aff7841da6a83c10445d7d6328d9 Author: Roger Quadros <rogerq@ti.com> Date: Thu Aug 6 17:39:35 2015 +0300 mtd: nand: omap2: Implement NAND ready using gpiolib The GPMC WAIT pin status are now available over gpiolib. Update the omap_dev_ready() function to use gpio instead of directly accessing GPMC register space. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Tony Lindgren <tony@atomide.com> .../devicetree/bindings/mtd/gpmc-nand.txt | 2 ++ drivers/mtd/nand/omap2.c | 29 ++++++++++++++-------- include/linux/platform_data/mtd-nand-omap2.h | 2 +- 3 files changed, 21 insertions(+), 12 deletions(-) commit 9e6946215dbd9803e8b511928c9f61f3a49e2c58 Author: Roger Quadros <rogerq@ti.com> Date: Fri Aug 7 10:38:13 2015 +0300 memory: omap-gpmc: Prevent GPMC_STATUS from being accessed via gpmc_regs GPMC_STATUS register is private to the GPMC module and must not be accessed directly by NAND driver through the gpmc_regs. They must use gpmc_omap_get_nand_ops() instead. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/memory/omap-gpmc.c | 2 +- include/linux/platform_data/mtd-nand-omap2.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) commit b2bac25a4d298309bb4b2649bb1107ddaa287c47 Author: Roger Quadros <rogerq@ti.com> Date: Fri Feb 19 11:01:02 2016 +0200 memory: omap-gpmc: Support WAIT pin edge interrupts OMAPs can have 2 to 4 WAITPINs that can be used as edge triggered interrupts if not used for memory wait state insertion. Support these interrupts via the gpmc IRQ domain. The gpmc IRQ domain interrupt map is: 0 - NAND_fifoevent 1 - NAND_termcount 2 - GPMC_WAIT0 edge 3 - GPMC_WAIT1 edge, and so on Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Tony Lindgren <tony@atomide.com> .../bindings/memory-controllers/omap-gpmc.txt | 5 +- drivers/memory/omap-gpmc.c | 106 +++++++++++++++++---- 2 files changed, 92 insertions(+), 19 deletions(-) commit 210325f0f4eb531f83ffb0b0f95612e2a8063983 Author: Roger Quadros <rogerq@ti.com> Date: Thu Aug 6 13:21:40 2015 +0300 memory: omap-gpmc: Reserve WAITPIN if needed for WAIT monitoring If the device attached to GPMC wants to use the WAIT pin for WAIT monitoring then we reserve it internally for exclusive use. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/memory/omap-gpmc.c | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) commit d2d00862dfbbd22d80ee67f816cb7eeaea71f03b Author: Roger Quadros <rogerq@ti.com> Date: Mon Mar 7 12:18:43 2016 +0200 memory: omap-gpmc: Support general purpose input for WAITPINs OMAPs can have 2 to 4 WAITPINs that can be used as general purpose input if not used for memory wait state insertion. The first user will be the OMAP NAND chip to get the NAND read/busy status using gpiolib. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Tony Lindgren <tony@atomide.com> .../bindings/memory-controllers/omap-gpmc.txt | 6 ++ drivers/memory/Kconfig | 1 + drivers/memory/omap-gpmc.c | 117 ++++++++++++++++++--- 3 files changed, 112 insertions(+), 12 deletions(-) commit 3c76f6119a64eb8ff6d088ceb6ca03891e29a7ce Author: Roger Quadros <rogerq@ti.com> Date: Wed Aug 5 17:01:54 2015 +0300 memory: omap-gpmc: Move device tree binding to correct location omap-gpmc.c is a memory controller so move the binding to the right place. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Tony Lindgren <tony@atomide.com> Documentation/devicetree/bindings/bus/ti-gpmc.txt | 143 --------------------- .../bindings/memory-controllers/omap-gpmc.txt | 143 +++++++++++++++++++++ 2 files changed, 143 insertions(+), 143 deletions(-) commit bdd7e033fe4cc3836b141b75119a4a975a64d9bc Author: Roger Quadros <rogerq@ti.com> Date: Thu Jul 9 17:31:45 2015 +0300 memory: omap-gpmc: Prevent mapping into 1st 16MB We have been preventing mapping GPMC children in the first 1MB but really it has to be the first 16MB as the minimum GPMC partition size is 16MB. Also print an error message if CS mapping fails due to DT requesting address outside the GPMC map. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/memory/omap-gpmc.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) commit 51735caad3db6237fa9d31a2ce8b54cbd42ff6f0 Author: Roger Quadros <rogerq@ti.com> Date: Mon May 26 11:54:45 2014 +0300 mtd: nand: omap: Update DT binding documentation Add compatible id and interrupts. The NAND interrupts are provided by the GPMC controller node. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> Documentation/devicetree/bindings/mtd/gpmc-nand.txt | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) commit c9711ec5250b22fd94e9b34c17c095e001a90e66 Author: Roger Quadros <rogerq@ti.com> Date: Wed May 21 07:29:03 2014 +0300 mtd: nand: omap: Clean up device tree support Move NAND specific device tree parsing to NAND driver. The NAND controller node must have a compatible id, register space resource and interrupt resource. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/gpmc-nand.c | 5 +- drivers/memory/omap-gpmc.c | 143 +++++++-------------------- drivers/mtd/nand/omap2.c | 134 +++++++++++++++++++++---- include/linux/platform_data/mtd-nand-omap2.h | 3 +- 4 files changed, 153 insertions(+), 132 deletions(-) commit 01b95fc6b299b99075b8980371fc19b980236c32 Author: Roger Quadros <rogerq@ti.com> Date: Tue May 20 22:29:28 2014 +0300 mtd: nand: omap: Copy platform data parameters to omap_nand_info data Copy all the platform data parameters to the driver's local data structure 'omap_nand_info' and use it in the entire driver. This will make it easer for device tree migration. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/mtd/nand/omap2.c | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) commit d6e552168db59d627fd56074f2c588df1faf0c95 Author: Roger Quadros <rogerq@ti.com> Date: Wed Aug 5 13:36:43 2015 +0300 mtd: nand: omap: Switch to using GPMC-NAND ops for writebuffer empty check Instead of accessing the gpmc_status register directly start using the gpmc_nand_ops->nand_writebuffer_empty() helper to check write buffer empty status. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/mtd/nand/omap2.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit c509aefd75d026f4ef4aa306131d7a780c2eda7b Author: Roger Quadros <rogerq@ti.com> Date: Wed Aug 5 14:01:50 2015 +0300 mtd: nand: omap: Use gpmc_omap_get_nand_ops() to get NAND registers Deprecate nand register passing via platform data and use gpmc_omap_get_nand_ops() instead. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/gpmc-nand.c | 2 -- drivers/mtd/nand/omap2.c | 9 ++++++++- include/linux/platform_data/mtd-nand-omap2.h | 4 +++- 3 files changed, 11 insertions(+), 4 deletions(-) commit 384258f252727c67772bbd48dad3185a30ba50d3 Author: Roger Quadros <rogerq@ti.com> Date: Thu Jul 30 14:49:23 2015 +0300 memory: omap-gpmc: Implement IRQ domain for NAND IRQs GPMC provides 2 interrupts for NAND use. i.e. fifoevent and termcount. Use IRQ domain for this. NAND device tree node can then get the necessary interrupts by using gpmc as the interrupt parent. Legacy boot uses gpmc_get_client_irq to get the NAND interrupts from the GPMC IRQ domain. Get rid of custom bitmasks and use IRQ domain for that as well. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Tony Lindgren <tony@atomide.com> Documentation/devicetree/bindings/bus/ti-gpmc.txt | 8 + drivers/memory/omap-gpmc.c | 246 ++++++++++++---------- include/linux/omap-gpmc.h | 5 +- 3 files changed, 144 insertions(+), 115 deletions(-) commit 512d73d1c64f15da9cdcdcdfba3cd8db0d4d94cc Author: Roger Quadros <rogerq@ti.com> Date: Wed Aug 5 13:34:50 2015 +0300 memory: omap-gpmc: Add GPMC-NAND ops to get writebufferempty status This is needed by OMAP NAND driver to poll the empty status of the writebuffer. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/memory/omap-gpmc.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit f47fcad63f6847ea677c6c7030f30fd6438e0052 Author: Roger Quadros <rogerq@ti.com> Date: Wed Aug 5 13:58:01 2015 +0300 memory: omap-gpmc: Introduce GPMC to NAND interface The OMAP GPMC module has certain registers dedicated for NAND access and some NAND bits mixed with other GPMC functionality. For the NAND dedicated registers we have the struct gpmc_nand_regs. The NAND driver needs to access NAND specific bits from the following non-dedicated registers - EMPTYWRITEBUFFERSTATUS from GPMC_STATUS For accessing these bits we introduce the struct gpmc_nand_ops. Add gpmc_omap_get_nand_ops() that returns the gpmc_nand_ops along with updating the gpmc_nand_regs. This API will be called by the OMAP NAND driver to access the necessary bits in GPMC register space. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> drivers/memory/omap-gpmc.c | 21 +++++++++++++++++++++ include/linux/omap-gpmc.h | 35 +++++++++++++++++++++++++++++++++-- 2 files changed, 54 insertions(+), 2 deletions(-) commit fabe7d7756d17f5da4bd80fa2373c4bd93ed39e5 Author: Roger Quadros <rogerq@ti.com> Date: Fri Jul 10 15:23:29 2015 +0300 ARM: OMAP2+: gpmc: Add gpmc timings and settings to platform data Add device_timings, gpmc_timings and gpmc_setting to gpmc platform data. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> include/linux/omap-gpmc.h | 139 ------------------------------- include/linux/platform_data/gpmc-omap.h | 142 ++++++++++++++++++++++++++++++++ 2 files changed, 142 insertions(+), 139 deletions(-) commit 58bc67fc32b1c67fb045f4828a67134dc8fee631 Author: Roger Quadros <rogerq@ti.com> Date: Fri Jul 10 15:23:28 2015 +0300 ARM: OMAP2+: gpmc: Add platform data Add a platform data structure for GPMC. It contains all the necessary platform information that needs to be passed from platform init code to GPMC driver. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> include/linux/omap-gpmc.h | 3 +-- include/linux/platform_data/gpmc-omap.h | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 2 deletions(-) commit f5f7e45537e4ff534436c00d5671c1df84b0c390 Author: Brian Starkey <brian.starkey@arm.com> Date: Thu Apr 14 16:39:19 2016 +0100 arm64: dts: juno: Add external expansion bus to DT The Juno development platform has an external expansion bus which can be used for additional hardware (e.g. LogicTile Express daughterboards). Add this bus to the Juno base device-tree. Acked-by: Liviu Dudau <Liviu.Dudau@arm.com> Signed-off-by: Brian Starkey <brian.starkey@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> arch/arm64/boot/dts/arm/juno-base.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 1417b35e29367b3ea73f80c564e4ce7a9a09b729 Merge: 1951384 92e6d9a Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri Apr 15 10:25:18 2016 +0200 Merge branch 'sh-pfc-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers into devel commit 35b3fc8876ef927885f68e481efc049285d07e53 Author: Axel Lin <axel.lin@ingics.com> Date: Sun Apr 10 18:15:15 2016 +0800 gpio: brcmstb: Return proper error if bank width is invalid Return proper error in brcmstb_gpio_probe if bank width is invalid. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Gregory Fong <gregory.0xf0@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-brcmstb.c | 1 + 1 file changed, 1 insertion(+) commit 560ce1dc7c87ade27faaf07d381a9a5a2ffc9934 Author: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Date: Thu Apr 14 10:48:15 2016 -0700 drm/i915: use drm_crtc_send_vblank_event() Replace the legacy drm_send_vblank_event() with the new helper function. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460656118-16766-4-git-send-email-gustavo@padovan.org drivers/gpu/drm/i915/intel_display.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 4f62568c1fcf0f7da49e7c22bdd01645aa508e80 Author: Michał Kępień <kernel@kempniu.pl> Date: Tue Apr 12 22:06:34 2016 +0930 fujitsu-laptop: Support radio LED Lifebook E734/E744/E754 has a LED which the manual calls "radio components indicator". It should be lit when any radio transmitter is enabled. Its state can be read and set using ACPI (FUNC interface, RFKILL method). Since the Lifebook E734/E744/E754 only has a button (as compared to a slider) for enabling/disabling radio transmitters, I believe the LED in question is meant to indicate whether all radio transmitters are currently on or off. However, pressing the radio toggle button does not automatically change the hardware state of the transmitters: it looks like this machine relies on soft rfkill. As for detecting whether the LED is present on a given machine, I had to resort to educated guesswork. I assumed this LED is present on all devices which have a radio toggle button instead of a slider. My Lifebook E744 holds 0x01010001 in BTNI. By comparing the bits and buttons with those of a Lifebook E8420 (BTNI=0x000F0101, has a slider), I put my money on bit 24 as the indicator of the radio toggle button being present. Furthermore, bit 24 is also clear on the S7020 which does not have the toggle button or an RF LED. Figuring out how the LED is controlled was more deterministic as all it took was decompiling the DSDT and taking a look at method S000 (the RFKILL method of the FUNC interface). The LED control method implemented here is unsuitable for use with "heavy" LED triggers, like phy0rx. Once blinking frequency achieves a certain level, the system hangs. Signed-off-by: Michał Kępień <kernel@kempniu.pl> [jwoithe: Comment on bit 24 in BTNI, expanded commit msg] Signed-off-by: Jonathan Woithe <jwoithe@just42.net> [dvhart: Minor style and commit log adjustments] Signed-off-by: Darren Hart <dvhart@linux.intel.com> drivers/platform/x86/fujitsu-laptop.c | 51 +++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) commit d9f094a02f30510ec5d394c44d01d2ec187d7e45 Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:25:02 2016 -0700 dmaengine: bcm2835: add dma_memcopy support to bcm2835-dma Also added check for an error condition in bcm2835_dma_create_cb_chain that showed up during development of this patch. Tested using dmatest for all enabled channels. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) commit 388cc7a281c06e484afcc3c5125b3271316209ef Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:25:01 2016 -0700 dmaengine: bcm2835: add slave_sg support to bcm2835-dma Add slave_sg support to bcm2835-dma using shared allocation code for bcm2835_desc and DMA-control blocks already used by dma_cyclic. Note that bcm2835_dma_callback had to get modified to support both modes of operation (cyclic and non-cyclic). Tested using: * Hifiberry I2S card (using cyclic DMA) * fb_st7735r SPI-framebuffer (using slave_sg DMA via spi-bcm2835) playing BigBuckBunny for audio and video. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 113 ++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 108 insertions(+), 5 deletions(-) commit 4087412258276be37c5660fc6caf5d4e08920193 Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:25:00 2016 -0700 dmaengine: bcm2835: limit max length based on channel type The bcm2835 dma system has 2 basic types of dma-channels: * "normal" channels * "light" channels Lite channels are limited in several aspects: * internal data-structure is 128 bit (not 256) * does not support BCM2835_DMA_TDMODE (2D) * DMA length register is limited to 16 bit. so 0-65535 (not 0-65536 as mentioned in the official datasheet) * BCM2835_DMA_S/D_IGNORE are not supported The detection of the type of mode is implemented by looking at the LITE bit in the DEBUG register for each channel. This allows automatic detection. Based on this the maximum block size is set to (64K - 4) or to 1G and this limit is honored during generation of control block chains. The effect is that when a LITE channel is used more control blocks are used to do the same transfer (compared to a normal channel). As there are several sources/target DREQS that are 32 bit wide we need to have the transfer to be a multiple of 4 as this would break the transfer otherwise. This is why the limit of (64K - 4) was chosen over the alternative of (64K - 4K). Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) commit 92153bb534fa4c2f0a1fdc3745cab25edaf10dca Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:24:59 2016 -0700 dmaengine: bcm2835: move controlblock chain generation into separate method In preparation of adding slave_sg functionality this patch moves the generation/allocation of bcm2835_desc and the building of the corresponding DMA-control-block chain from bcm2835_dma_prep_dma_cyclic into the newly created method bcm2835_dma_create_cb_chain. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 294 +++++++++++++++++++++++++++++++--------------- 1 file changed, 198 insertions(+), 96 deletions(-) commit a4dcdd849ef8dbd0811ca8436aecf1c87e09686c Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:24:58 2016 -0700 dmaengine: bcm2835: move cyclic member from bcm2835_chan into bcm2835_desc In preparation to consolidating code we move the cyclic member into the bcm_2835_desc structure. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e42685d7a7d5afa6278561ffd85c475eae246be3 Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:24:57 2016 -0700 dmaengine: bcm2835: add additional defines for DMA-registers Add additional defines describing the DMA registers as well as adding some more documentation to those registers. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 57 ++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 49 insertions(+), 8 deletions(-) commit a1d71ba90c68a5dfd87dd4c1a6386cef017d9ecb Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:24:56 2016 -0700 dmaengine: bcm2835: remove unnecessary masking of dma channels The original patch contained 3 dma channels that were masked out. These - as far as research and discussions show - are a artefacts remaining from the downstream legacy dma-api. Right now down-stream still includes a legacy api used only in a single (downstream only) driver (bcm2708_fb) that requires 2D DMA for speedup (DMA-channel 0). Formerly the sd-card support driver also was using this legacy api (DMA-channel 2), but since has been moved over to use dmaengine directly. The DMA-channel 3 is already masked out in the devicetree in the default property "brcm,dma-channel-mask = <0x7f35>;" So we can remove the whole masking of DMA channels. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 9 --------- 1 file changed, 9 deletions(-) commit 0fa5867e6a2c6119fac35b8b710bec87b4598940 Author: Martin Sperl <kernel@martin.sperl.org> Date: Wed Mar 16 12:24:55 2016 -0700 dmaengine: bcm2835: set residue_granularity field bcm2835-dma supports residue reporting at burst level but didn't report this via the residue_granularity field. See also: https://github.com/raspberrypi/linux/commit/b015555327afa402f70ddc86e3632f59df1cd9d7 for the downstream patch. Signed-off-by: Matthias Reichl <hias@horus.com> Signed-off-by: Noralf Trønnes <noralf@tronnes.org> Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/bcm2835-dma.c | 1 + 1 file changed, 1 insertion(+) commit 608b9977260f67d8b032ea170666a6174a48e2f1 Author: Paolo Abeni <pabeni@redhat.com> Date: Wed Apr 13 10:52:20 2016 +0200 tun: use per cpu variables for stats accounting Currently the tun device accounting uses dev->stats without applying any kind of protection, regardless that accounting happens in preemptible process context. This patch move the tun stats to a per cpu data structure, and protect the updates with u64_stats_update_begin()/u64_stats_update_end() or this_cpu_inc according to the stat type. The per cpu stats are aggregated by the newly added ndo_get_stats64 ops. Signed-off-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 95 ++++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 83 insertions(+), 12 deletions(-) commit 548aacdd742b963983f13c523dad8c169c406a19 Merge: 486bdee 3f2050e Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 14 21:40:53 2016 -0400 Merge branch 'bpf-ARG_PTR_TO_RAW_STACK' Merge branch 'bpf-ARG_PTR_TO_RAW_STACK' Daniel Borkmann says: ==================== BPF updates This series adds a new verifier argument type called ARG_PTR_TO_RAW_STACK and converts related helpers to make use of it. Basic idea is that we can save init of stack memory when the helper function is guaranteed to fully fill out the passed buffer in every path. Series also adds test cases and converts samples. For more details, please see individual patches. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 3f2050e20e6f3a762eb08397db651dcec9498998 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed Apr 13 00:10:54 2016 +0200 bpf, samples: add test cases for raw stack This adds test cases mostly around ARG_PTR_TO_RAW_STACK to check the verifier behaviour. [...] #84 raw_stack: no skb_load_bytes OK #85 raw_stack: skb_load_bytes, no init OK #86 raw_stack: skb_load_bytes, init OK #87 raw_stack: skb_load_bytes, spilled regs around bounds OK #88 raw_stack: skb_load_bytes, spilled regs corruption OK #89 raw_stack: skb_load_bytes, spilled regs corruption 2 OK #90 raw_stack: skb_load_bytes, spilled regs + data OK #91 raw_stack: skb_load_bytes, invalid access 1 OK #92 raw_stack: skb_load_bytes, invalid access 2 OK #93 raw_stack: skb_load_bytes, invalid access 3 OK #94 raw_stack: skb_load_bytes, invalid access 4 OK #95 raw_stack: skb_load_bytes, invalid access 5 OK #96 raw_stack: skb_load_bytes, invalid access 6 OK #97 raw_stack: skb_load_bytes, large access OK Summary: 98 PASSED, 0 FAILED Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/test_verifier.c | 268 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 268 insertions(+) commit 02413cabd6b67f1444f153ea85d44076deae2056 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed Apr 13 00:10:53 2016 +0200 bpf, samples: don't zero data when not needed Remove the zero initialization in the sample programs where appropriate. Note that this is an optimization which is now possible, old programs still doing the zero initialization are just fine as well. Also, make sure we don't have padding issues when we don't memset() the entire struct anymore. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/offwaketime_kern.c | 10 ++++++---- samples/bpf/tracex1_kern.c | 4 +--- samples/bpf/tracex2_kern.c | 4 ++-- samples/bpf/tracex5_kern.c | 6 +++--- 4 files changed, 12 insertions(+), 12 deletions(-) commit 074f528eed408b467516e142fa4c45e5b0d2ba16 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed Apr 13 00:10:52 2016 +0200 bpf: convert relevant helper args to ARG_PTR_TO_RAW_STACK This patch converts all helpers that can use ARG_PTR_TO_RAW_STACK as argument type. For tc programs this is bpf_skb_load_bytes(), bpf_skb_get_tunnel_key(), bpf_skb_get_tunnel_opt(). For tracing, this optimizes bpf_get_current_comm() and bpf_probe_read(). The check in bpf_skb_load_bytes() for MAX_BPF_STACK can also be removed since the verifier already makes sure we stay within bounds on stack buffers. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/helpers.c | 17 +++++++++++---- kernel/trace/bpf_trace.c | 10 ++++++--- net/core/filter.c | 57 +++++++++++++++++++++++++++++++++--------------- 3 files changed, 60 insertions(+), 24 deletions(-) commit 435faee1aae9c1ac231f89e4faf0437bfe29f425 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed Apr 13 00:10:51 2016 +0200 bpf, verifier: add ARG_PTR_TO_RAW_STACK type When passing buffers from eBPF stack space into a helper function, we have ARG_PTR_TO_STACK argument type for helpers available. The verifier makes sure that such buffers are initialized, within boundaries, etc. However, the downside with this is that we have a couple of helper functions such as bpf_skb_load_bytes() that fill out the passed buffer in the expected success case anyway, so zero initializing them prior to the helper call is unneeded/wasted instructions in the eBPF program that can be avoided. Therefore, add a new helper function argument type called ARG_PTR_TO_RAW_STACK. The idea is to skip the STACK_MISC check in check_stack_boundary() and color the related stack slots as STACK_MISC after we checked all call arguments. Helper functions using ARG_PTR_TO_RAW_STACK must make sure that every path of the helper function will fill the provided buffer area, so that we cannot leak any uninitialized stack memory. This f.e. means that error paths need to memset() the buffers, but the expected fast-path doesn't have to do this anymore. Since there's no such helper needing more than at most one ARG_PTR_TO_RAW_STACK argument, we can keep it simple and don't need to check for multiple areas. Should in future such a use-case really appear, we have check_raw_mode() that will make sure we implement support for it first. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/bpf.h | 5 +++++ kernel/bpf/verifier.c | 59 ++++++++++++++++++++++++++++++++++++++++++++++----- 2 files changed, 59 insertions(+), 5 deletions(-) commit 33ff9823c569f3aceb071071914919177a6bed6a Author: Daniel Borkmann <daniel@iogearbox.net> Date: Wed Apr 13 00:10:50 2016 +0200 bpf, verifier: add bpf_call_arg_meta for passing meta data Currently, when the verifier checks calls in check_call() function, we call check_func_arg() for all 5 arguments e.g. to make sure expected types are correct. In some cases, we collect meta data (here: map pointer) to perform additional checks such as checking stack boundary on key/value sizes for subsequent arguments. As we're going to extend the meta data, add a generic struct bpf_call_arg_meta that we can use for passing into check_func_arg(). Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 40 +++++++++++++++++++++++----------------- 1 file changed, 23 insertions(+), 17 deletions(-) commit 486bdee0134cf21c3714ded809d5933d2b8dfb81 Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Date: Tue Apr 12 18:11:31 2016 -0300 sctp: add support for RPS and RFS This patch adds what's missing to properly support RPS and RFS on SCTP, as some of it is already implemented in common calls. Having support for RPS and RFS allows better scaling specially because not all NICs support hashing SCTP headers. Save the hash right when we dequeue a skb from inqueue so we do it only once per skb instead of per chunk. New sockets will then inherit the hash through sctp_copy_sock(). Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sctp/inqueue.c | 3 +++ net/sctp/socket.c | 3 +++ 2 files changed, 6 insertions(+) commit d21fd63ea3856208c3a1cb9b26d81898a2ccf71b Author: Eric Dumazet <edumazet@google.com> Date: Tue Apr 12 21:50:07 2016 -0700 net: validate_xmit_skb() changes skbs given to validate_xmit_skb() should not have a next pointer anymore. Also if a packet is dropped, increment dev->tx_dropped __dev_queue_xmit() no longer has to change tx_dropped in this case. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 839a04d847f5871516f500091519c52dc40fe01d Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:23 2016 +0200 soc: renesas: Add r8a7795 SYSC PM Domain Binding Definitions Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7795-sysc.h | 42 ++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit 353cf9961acf5e0db8a6cb6f24333ad76dacb8fc Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:22 2016 +0200 soc: renesas: Add r8a7794 SYSC PM Domain Binding Definitions Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7794-sysc.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit a6171412725e4e7e510a2b91a1d79dbc2ef0e679 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:21 2016 +0200 soc: renesas: Add r8a7793 SYSC PM Domain Binding Definitions R-Car M2-N is identical to R-Car M2-W w.r.t. power domains, so reuse the definitions from the latter. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7793-sysc.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) commit 434ac75a28d8b2aec08b6b8e080d793857c1b090 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:20 2016 +0200 soc: renesas: Add r8a7791 SYSC PM Domain Binding Definitions Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7791-sysc.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 3dc4c00a33a82824b710892be4b059637c99cabf Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:19 2016 +0200 soc: renesas: Add r8a7790 SYSC PM Domain Binding Definitions Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7790-sysc.h | 34 ++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit 79bca98cfb91d4b8dca6af1e865676f7677ca8f2 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:18 2016 +0200 soc: renesas: Add r8a7779 SYSC PM Domain Binding Definitions Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> include/dt-bindings/power/r8a7779-sysc.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit a85fff3b01ac1d67d9ef15672a9b5b5a4a44204e Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Wed Apr 13 16:44:17 2016 +0200 PM / Domains: Add DT bindings for the R-Car System Controller The Renesas R-Car System Controller provides power management for the CPU cores and various coprocessors, following the generic PM domain bindings in Documentation/devicetree/bindings/power/power_domain.txt. This supports R-Car Gen1 (H1), Gen2, and Gen3. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> .../bindings/power/renesas,rcar-sysc.txt | 48 ++++++++++++++++++++++ 1 file changed, 48 insertions(+) commit 01d1b6e543cfdc0f05027686b35d73de73caec10 Author: Rameshwar Prasad Sahu <rsahu@apm.com> Date: Tue Mar 29 15:24:54 2016 +0530 arm64: dts: apm: Fix compatible string for X-Gene 2 SATA controller DTS node Fix X-Gene SATA controller compatible string for Merlin board. Signed-off-by: Rameshwar Prasad Sahu <rsahu@apm.com> Acked-by: Suman Tripathi <stripathi@apm.com> arch/arm64/boot/dts/apm/apm-shadowcat.dtsi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 25da4fab5f66e659da768cd61dbf8c3861104d7c Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 19:45:01 2016 -0300 perf evsel: Move fprintf methods to separate source file They still use functions that would drag more stuff to the python binding, where these fprintf methods are not used, so separate it. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-xfp0mgq3hh3px61di6ixi1jk@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/Build | 1 + tools/perf/util/evsel.c | 206 -------------------------------------- tools/perf/util/evsel_fprintf.c | 212 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 213 insertions(+), 206 deletions(-) commit c6d4a494a207a336b45e52a44550150964daf1ce Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 18:29:08 2016 -0300 perf trace: Add --max-stack knob Similar to the one in the other tools (report, script, top). Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-lh7kk5a5t3erwxw31ah0cgar@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 9 +++++++++ tools/perf/builtin-trace.c | 9 ++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) commit 6125cc8dac432948a31df4d4ac20dd2d4f8c6c27 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 18:15:18 2016 -0300 perf script: Add --max-stack knob Works just like with 'perf report'. In some cases we may want to have more than 127 entries, the default maximum. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-mqkz2p5ok2978gztb0vsnocc@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-script.txt | 10 ++++++++++ tools/perf/builtin-script.c | 5 +++++ 2 files changed, 15 insertions(+) commit d327e60cfae2201bcdee5aeb9b5a42e3988b184f Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 17:53:49 2016 -0300 perf tools: Remove addr_location argument to sample__fprintf_callchain Not used at all, nuke it. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-jf2w8ce8nl3wso3vuodg5jci@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 3 +-- tools/perf/util/evsel.c | 8 ++------ tools/perf/util/evsel.h | 4 ++-- 3 files changed, 5 insertions(+), 10 deletions(-) commit 6f736735e30f51805f6be31d20a4bf5b0ae91bae Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 17:45:51 2016 -0300 perf evsel: Require that callchains be resolved before calling fprintf_{sym,callchain} This way the print routine merely does printing, not requiring access to the resolving machinery, which helps disentangling the object files and easing creating subsets with a limited functionality set. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-2ti2jbra8fypdfawwwm3aee3@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 36 ++++++++++++++++++++---------------- tools/perf/builtin-trace.c | 8 +++++--- tools/perf/util/evsel.c | 39 ++++++++++++++------------------------- tools/perf/util/evsel.h | 19 +++++++++---------- 4 files changed, 48 insertions(+), 54 deletions(-) commit bfbba189b681c86b9ae380358e5f50ce1e33d240 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 15:54:36 2016 -0300 perf symbols: Move fprintf routines to separate object file To disentangle symbol printing from all the code related to symbol tables, resolution of addresses to symbols, etc. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-eik9g3hbtdc7ddv57f1d4v3p@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/Build | 1 + tools/perf/util/python-ext-sources | 1 + tools/perf/util/symbol.c | 71 -------------------------------------- tools/perf/util/symbol.h | 5 +++ tools/perf/util/symbol_fprintf.c | 71 ++++++++++++++++++++++++++++++++++++++ 5 files changed, 78 insertions(+), 71 deletions(-) commit da37845fdce24e174f44d020bc4085ddd1c8a6bd Author: Weongyo Jeong <weongyo.linux@gmail.com> Date: Thu Apr 14 14:10:04 2016 -0700 packet: uses kfree_skb() for errors. consume_skb() isn't for error cases that kfree_skb() is more proper one. At this patch, it fixed tpacket_rcv() and packet_rcv() to be consistent for error or non-error cases letting perf trace its event properly. Signed-off-by: Weongyo Jeong <weongyo.linux@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/packet/af_packet.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) commit 333f796235a52727db7e0a13888045f3aa3d5335 Author: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com> Date: Tue Apr 12 13:05:21 2016 +0200 tipc: fix a race condition leading to subscriber refcnt bug Until now, the requests sent to topology server are queued to a workqueue by the generic server framework. These messages are processed by worker threads and trigger the registered callbacks. To reduce latency on uniprocessor systems, explicit rescheduling is performed using cond_resched() after MAX_RECV_MSG_COUNT(25) messages. This implementation on SMP systems leads to an subscriber refcnt error as described below: When a worker thread yields by calling cond_resched() in a SMP system, a new worker is created on another CPU to process the pending workitem. Sometimes the sleeping thread wakes up before the new thread finishes execution. This breaks the assumption on ordering and being single threaded. The fault is more frequent when MAX_RECV_MSG_COUNT is lowered. If the first thread was processing subscription create and the second thread processing close(), the close request will free the subscriber and the create request oops as follows: [31.224137] WARNING: CPU: 2 PID: 266 at include/linux/kref.h:46 tipc_subscrb_rcv_cb+0x317/0x380 [tipc] [31.228143] CPU: 2 PID: 266 Comm: kworker/u8:1 Not tainted 4.5.0+ #97 [31.228377] Workqueue: tipc_rcv tipc_recv_work [tipc] [...] [31.228377] Call Trace: [31.228377] [<ffffffff812fbb6b>] dump_stack+0x4d/0x72 [31.228377] [<ffffffff8105a311>] __warn+0xd1/0xf0 [31.228377] [<ffffffff8105a3fd>] warn_slowpath_null+0x1d/0x20 [31.228377] [<ffffffffa0098067>] tipc_subscrb_rcv_cb+0x317/0x380 [tipc] [31.228377] [<ffffffffa00a4984>] tipc_receive_from_sock+0xd4/0x130 [tipc] [31.228377] [<ffffffffa00a439b>] tipc_recv_work+0x2b/0x50 [tipc] [31.228377] [<ffffffff81071925>] process_one_work+0x145/0x3d0 [31.246554] ---[ end trace c3882c9baa05a4fd ]--- [31.248327] BUG: spinlock bad magic on CPU#2, kworker/u8:1/266 [31.249119] BUG: unable to handle kernel NULL pointer dereference at 0000000000000428 [31.249323] IP: [<ffffffff81099d0c>] spin_dump+0x5c/0xe0 [31.249323] PGD 0 [31.249323] Oops: 0000 [#1] SMP In this commit, we - rename tipc_conn_shutdown() to tipc_conn_release(). - move connection release callback execution from tipc_close_conn() to a new function tipc_sock_release(), which is executed before we free the connection. Thus we release the subscriber during connection release procedure rather than connection shutdown procedure. Signed-off-by: Parthasarathy Bhuvaragan <parthasarathy.bhuvaragan@ericsson.com> Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/server.c | 19 +++++++++++++------ net/tipc/server.h | 4 ++-- net/tipc/subscr.c | 4 ++-- 3 files changed, 17 insertions(+), 10 deletions(-) commit a4240d3af6771339c3557afe261a8a89573980a9 Author: Nishanth Menon <nm@ti.com> Date: Thu Apr 14 12:45:58 2016 -0500 ARM: dts: Add support for dra72-evm rev C (SR2.0) DRA72-EVM now has an upgrade to Rev C with SR2.0 silicon. As part of this change, a few updates were factored in that were software incompatible with previous board in few areas: - We now use DP83867 ethernet phy instead of older DP838865 which fails in certain use cases. - Two Ethernet ports now instead of the single one in rev B. - polarities changed for certain pcf gpios - Due to SoC phy current requirements, VDDA supplies are split between ldo3 and ldo2 (ldo2 was previously unused). NOTE: DSS (VDDA_VIDEO) is still supplied by ldo5, HDMI is now supplied by LDO2 instead of using LDO3. NOTE: It does not make much sense to spin off a new board compatible flag since there is no real benefit for the same. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/dra72-evm-common.dtsi | 833 +++++++++++++++++++++++++++++++ arch/arm/boot/dts/dra72-evm-revc.dts | 73 +++ arch/arm/boot/dts/dra72-evm.dts | 838 +------------------------------- 4 files changed, 921 insertions(+), 826 deletions(-) commit 1ae5762dd67710626248097eb89d165535c8cdd5 Author: Marcin Niestroj <m.niestroj@grinn-global.com> Date: Wed Apr 13 10:44:17 2016 +0200 ARM: dts: am335x-chilisom: Enable poweroff PMIC sequence using RTC signal ChiliSOM has TPS65217's PWR_EN pin connected to AM335x PMIC_POWER_EN pin. Processor's PMIC_POWER_EN is controlled by it's internal RTC, hence RTC subsystem is responsible for proper board poweroff sequence. This change enables complete poweroff sequence for ChiliBoard, switching PMIC's state from ACTIVE to SLEEP. Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-chilisom.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit ce07a9bd9c6ade102fc57ec562db8eed7c7db1ad Author: Marcin Niestroj <m.niestroj@grinn-global.com> Date: Wed Apr 13 10:44:16 2016 +0200 ARM: dts: am335x-chili*: Move Ethernet MAC description from SOM to board ChiliSOM has 2 Ethernet subsystems with different types of possibly used PHY interfaces (i.e. MII, RMII, GMII, RGMII). Current code configured pinmux for RMII on 1st Ethernet subsystem and enabled Ethernet MAC with 1 slave for all boards which use ChiliSOM. This change moves pinmux configuration of 1st Ethernet subsystem to ChiliBoard description, as this is board-specific. Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-chiliboard.dts | 61 ++++++++++++++++++++++++++++++++ arch/arm/boot/dts/am335x-chilisom.dtsi | 62 --------------------------------- 2 files changed, 61 insertions(+), 62 deletions(-) commit 71815b1825d64c15ca25d4aa3cbad10b02d3981e Author: Marcin Niestroj <m.niestroj@grinn-global.com> Date: Wed Apr 13 10:44:15 2016 +0200 ARM: dts: am335x-chili*: Move uart0 description from SOM to board uart0 configuration code has been in SOM. However, it is possible to use all (or none) of 6 uart's of AM335x processor present on ChiliSOM. This fix moves declaration of uart0 from ChiliSOM to ChiliBoard, because use of uart is strictly board-specific. Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-chiliboard.dts | 14 ++++++++++++++ arch/arm/boot/dts/am335x-chilisom.dtsi | 14 -------------- 2 files changed, 14 insertions(+), 14 deletions(-) commit edd93cd72741b80633969c247a2f86f177242cfb Merge: cb68926 f7a6272 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 14 16:23:42 2016 -0400 Merge branch 'gro-fixed-id-gso-partial' Alexander Duyck says: ==================== GRO Fixed IPv4 ID support and GSO partial support This patch series sets up a few different things. First it adds support for GRO of frames with a fixed IP ID value. This will allow us to perform GRO for frames that go through things like an IPv6 to IPv4 header translation. The second item we add is support for segmenting frames that are generated this way. Most devices only support an incrementing IP ID value, and in the case of TCP the IP ID can be ignored in many cases since the DF bit should be set. So we can technically segment these frames using existing TSO if we are willing to allow the IP ID to be mangled. As such I have added a matching feature for the new form of GRO/GSO called TCP IPv4 ID mangling. With this enabled we can assemble and disassemble a frame with the sequence number fixed and the only ill effect will be that the IPv4 ID will be altered which may or may not have any noticeable effect. As such I have defaulted the feature to disabled. The third item this patch series adds is support for partial GSO segmentation. Partial GSO segmentation allows us to split a large frame into two pieces. The first piece will have an even multiple of MSS worth of data and the headers before the one pointed to by csum_start will have been updated so that they are correct for if the data payload had already been segmented. By doing this we can do things such as precompute the outer header checksums for a frame to be segmented allowing us to perform TSO on devices that don't support tunneling, or tunneling with outer header checksums. This patch set is based on the net-next tree, but I included "net: remove netdevice gso_min_segs" in my tree as I assume it is likely to be applied before this patch set will and I wanted to avoid a merge conflict. v2: Fixed items reported by Jesse Gross fixed missing GSO flag in MPLS check adding DF check for MANGLEID Moved extra GSO feature checks into gso_features_check Rebased batches to account for "net: remove netdevice gso_min_segs" Driver patches from the first patch set should still be compatible. However I do have a few changes in them so I will submit a v2 of those to Jeff Kirsher once these patches are accepted into net-next. Example driver patches for i40e, ixgbe, and igb: https://patchwork.ozlabs.org/patch/608221/ https://patchwork.ozlabs.org/patch/608224/ https://patchwork.ozlabs.org/patch/608225/ ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f7a6272bf3cbd2576165dba020e0329c9ca67c1f Author: Alexander Duyck <aduyck@mirantis.com> Date: Sun Apr 10 21:45:09 2016 -0400 Documentation: Add documentation for TSO and GSO features This document is a starting point for defining the TSO and GSO features. The whole thing is starting to get a bit messy so I wanted to make sure we have notes somwhere to start describing what does and doesn't work. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/segmentation-offloads.txt | 130 +++++++++++++++++++++ 1 file changed, 130 insertions(+) commit 802ab55adc39a06940a1b384e9fd0387fc762d7e Author: Alexander Duyck <aduyck@mirantis.com> Date: Sun Apr 10 21:45:03 2016 -0400 GSO: Support partial segmentation offload This patch adds support for something I am referring to as GSO partial. The basic idea is that we can support a broader range of devices for segmentation if we use fixed outer headers and have the hardware only really deal with segmenting the inner header. The idea behind the naming is due to the fact that everything before csum_start will be fixed headers, and everything after will be the region that is handled by hardware. With the current implementation it allows us to add support for the following GSO types with an inner TSO_MANGLEID or TSO6 offload: NETIF_F_GSO_GRE NETIF_F_GSO_GRE_CSUM NETIF_F_GSO_IPIP NETIF_F_GSO_SIT NETIF_F_UDP_TUNNEL NETIF_F_UDP_TUNNEL_CSUM In the case of hardware that already supports tunneling we may be able to extend this further to support TSO_TCPV4 without TSO_MANGLEID if the hardware can support updating inner IPv4 headers. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdev_features.h | 5 +++++ include/linux/netdevice.h | 2 ++ include/linux/skbuff.h | 9 +++++++-- net/core/dev.c | 36 +++++++++++++++++++++++++++++++++--- net/core/ethtool.c | 1 + net/core/skbuff.c | 29 ++++++++++++++++++++++++++++- net/ipv4/af_inet.c | 20 ++++++++++++++++---- net/ipv4/gre_offload.c | 26 +++++++++++++++++++++----- net/ipv4/tcp_offload.c | 10 ++++++++-- net/ipv4/udp_offload.c | 27 +++++++++++++++++++++------ net/ipv6/ip6_offload.c | 10 +++++++++- 11 files changed, 151 insertions(+), 24 deletions(-) commit 1530545ed64b42e87acb43c0c16401bd1ebae6bf Author: Alexander Duyck <aduyck@mirantis.com> Date: Sun Apr 10 21:44:57 2016 -0400 GRO: Add support for TCP with fixed IPv4 ID field, limit tunnel IP ID values This patch does two things. First it allows TCP to aggregate TCP frames with a fixed IPv4 ID field. As a result we should now be able to aggregate flows that were converted from IPv6 to IPv4. In addition this allows us more flexibility for future implementations of segmentation as we may be able to use a fixed IP ID when segmenting the flow. The second thing this does is that it places limitations on the outer IPv4 ID header in the case of tunneled frames. Specifically it forces the IP ID to be incrementing by 1 unless the DF bit is set in the outer IPv4 header. This way we can avoid creating overlapping series of IP IDs that could possibly be fragmented if the frame goes through GRO and is then resegmented via GSO. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 5 ++++- net/core/dev.c | 1 + net/ipv4/af_inet.c | 35 ++++++++++++++++++++++++++++------- net/ipv4/tcp_offload.c | 16 +++++++++++++++- net/ipv6/ip6_offload.c | 8 ++++++-- 5 files changed, 54 insertions(+), 11 deletions(-) commit cbc53e08a793b073e79f42ca33f1f3568703540d Author: Alexander Duyck <aduyck@mirantis.com> Date: Sun Apr 10 21:44:51 2016 -0400 GSO: Add GSO type for fixed IPv4 ID This patch adds support for TSO using IPv4 headers with a fixed IP ID field. This is meant to allow us to do a lossless GRO in the case of TCP flows that use a fixed IP ID such as those that convert IPv6 header to IPv4 headers. In addition I am adding a feature that for now I am referring to TSO with IP ID mangling. Basically when this flag is enabled the device has the option to either output the flow with incrementing IP IDs or with a fixed IP ID regardless of what the original IP ID ordering was. This is useful in cases where the DF bit is set and we do not care if the original IP ID value is maintained. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdev_features.h | 3 +++ include/linux/netdevice.h | 1 + include/linux/skbuff.h | 20 +++++++++++--------- net/core/dev.c | 34 +++++++++++++++++++++++++++++----- net/core/ethtool.c | 1 + net/ipv4/af_inet.c | 19 +++++++++++-------- net/ipv4/gre_offload.c | 1 + net/ipv4/tcp_offload.c | 4 +++- net/ipv6/ip6_offload.c | 3 ++- net/mpls/mpls_gso.c | 1 + 10 files changed, 63 insertions(+), 24 deletions(-) commit 518f213dddb3375e8cf0fcb791dda4c7d1ce4c74 Author: Alexander Duyck <aduyck@mirantis.com> Date: Sun Apr 10 21:44:44 2016 -0400 ethtool: Add support for toggling any of the GSO offloads The strings were missing for several of the GSO offloads that are available. This patch provides the missing strings so that we can toggle or query any of them via the ethtool command. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/ethtool.c | 2 ++ 1 file changed, 2 insertions(+) commit cb689269acc8cf911a2b28d22da155ee83f8dbdc Merge: f38ba95 2d0ed39 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 14 16:22:12 2016 -0400 Merge branch 'mlxsw-devlink-shared-buffers' Jiri Pirko says: ==================== devlink + mlxsw: add support for config and control of shared buffers ASICs implement shared buffer for packet forwarding purposes and enable flexible partitioning of the shared buffer for different flows and ports, enabling non-blocking progress of different flows as well as separation of lossy traffic from loss-less traffic when using Per-Priority Flow Control (PFC). The shared buffer optimizes the buffer utilization for better absorption of packet bursts. This patchset implements API which is based on the model SAI uses. That is aligned with multiple ASIC vendors so this API should be vendor neutral. Userspace counterpart patchset for devlink iproute2 tool can be found here: https://github.com/jpirko/iproute2_mlxsw/tree/devlink_sb Couple of examples of usage: switch$ devlink sb help Usage: devlink sb show [ DEV [ sb SB_INDEX ] ] devlink sb pool show [ DEV [ sb SB_INDEX ] pool POOL_INDEX ] devlink sb pool set DEV [ sb SB_INDEX ] pool POOL_INDEX size POOL_SIZE thtype { static | dynamic } devlink sb port pool show [ DEV/PORT_INDEX [ sb SB_INDEX ] pool POOL_INDEX ] devlink sb port pool set DEV/PORT_INDEX [ sb SB_INDEX ] pool POOL_INDEX th THRESHOLD devlink sb tc bind show [ DEV/PORT_INDEX [ sb SB_INDEX ] tc TC_INDEX ] devlink sb tc bind set DEV/PORT_INDEX [ sb SB_INDEX ] tc TC_INDEX type { ingress | egress } pool POOL_INDEX th THRESHOLD devlink sb occupancy show { DEV | DEV/PORT_INDEX } [ sb SB_INDEX ] devlink sb occupancy snapshot DEV [ sb SB_INDEX ] devlink sb occupancy clearmax DEV [ sb SB_INDEX ] switch$ devlink sb show pci/0000:03:00.0: sb 0 size 16777216 ing_pools 4 eg_pools 4 ing_tcs 8 eg_tcs 8 switch$ devlink sb pool show pci/0000:03:00.0: sb 0 pool 0 type ingress size 12400032 thtype dynamic pci/0000:03:00.0: sb 0 pool 1 type ingress size 0 thtype dynamic pci/0000:03:00.0: sb 0 pool 2 type ingress size 0 thtype dynamic pci/0000:03:00.0: sb 0 pool 3 type ingress size 200064 thtype dynamic pci/0000:03:00.0: sb 0 pool 4 type egress size 13220064 thtype dynamic pci/0000:03:00.0: sb 0 pool 5 type egress size 0 thtype dynamic pci/0000:03:00.0: sb 0 pool 6 type egress size 0 thtype dynamic pci/0000:03:00.0: sb 0 pool 7 type egress size 0 thtype dynamic switch$ devlink sb port pool show sw0p7 pool 0 sw0p7: sb 0 pool 0 threshold 16 switch$ sudo devlink sb port pool set sw0p7 pool 0 th 15 switch$ devlink sb port pool show sw0p7 pool 0 sw0p7: sb 0 pool 0 threshold 15 switch$ devlink sb tc bind show sw0p7 tc 0 type ingress sw0p7: sb 0 tc 0 type ingress pool 0 threshold 10 switch$ sudo devlink sb tc bind set sw0p7 tc 0 type ingress pool 0 th 9 switch$ devlink sb tc bind show sw0p7 tc 0 type ingress sw0p7: sb 0 tc 0 type ingress pool 0 threshold 9 switch$ sudo devlink sb occupancy snapshot pci/0000:03:00.0 switch$ devlink sb occupancy show sw0p7 sw0p7: pool: 0: 82944/3217344 1: 0/0 2: 0/0 3: 0/0 4: 0/384 5: 0/0 6: 0/0 7: 0/0 itc: 0(0): 96768/3217344 1(0): 0/0 2(0): 0/0 3(0): 0/0 4(0): 0/0 5(0): 0/0 6(0): 0/0 7(0): 0/0 etc: 0(4): 0/384 1(4): 0/0 2(4): 0/0 3(4): 0/0 4(4): 0/0 5(4): 0/0 6(4): 0/0 7(4): 0/0 switch$ sudo devlink sb occupancy clearmax pci/0000:03:00.0 ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 2d0ed39fbdee64835dc710b4ee3897f2bb9f8cf4 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:30 2016 +0200 mlxsw: spectrum_buffers: Implement occupancy monitoring Implement occupancy API introduced in devlink and mlxsw core. This is done by accessing SBPM register for Port-Pool and SBSR for Port-TC current and max occupancy values. Max clear is implemented using the same registers. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 36 +-- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 18 ++ .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 255 +++++++++++++++++++++ 3 files changed, 293 insertions(+), 16 deletions(-) commit caf7297e7ab5f8aa9d482200748a066adbfa5775 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:29 2016 +0200 mlxsw: core: Introduce support for asynchronous EMAD register access So far it was possible to have one EMAD register access at a time, locked by mutex. This patch extends this interface to allow multiple EMAD register accesses to be in fly at once. That allows faster processing on firmware side avoiding unused time in between EMADs. Measured speedup is ~30% for shared occupancy snapshot operation. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 494 +++++++++++++++++++---------- drivers/net/ethernet/mellanox/mlxsw/core.h | 13 + 2 files changed, 334 insertions(+), 173 deletions(-) commit dd9bdb04d2d7c428b0203b5e4e435abc229fa656 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:28 2016 +0200 mlxsw: core: Add mlxsw specific workqueue and use it for FDB notif. processing Follow-up patch is going to need to use delayed work as well and frequently. The FDB notification processing is already using that and also quite frequently. It makes sense to create separate workqueue just for mlxsw driver in this case and do not pollute system_wq. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 25 ++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlxsw/core.h | 3 +++ .../ethernet/mellanox/mlxsw/spectrum_switchdev.c | 4 ++-- 3 files changed, 28 insertions(+), 4 deletions(-) commit 42a7f1d7747904d89e9831fb85a678add00facf3 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:27 2016 +0200 mlxsw: reg: Extend SBPM register for occupancy control Since it is not possible to get and clear Port-Pool occupancy data using SBSR register, there's a need to implement that using SBPM. Extend pack helper and add unpack helper to get occupancy values. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 31 +++++++++++++++++++++- .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 3 ++- 2 files changed, 32 insertions(+), 2 deletions(-) commit 26176def3c1e7933601d04de3d4980199c1c87d1 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:26 2016 +0200 mlxsw: reg: Add Shared Buffer Status register definition This register allows to query HW for current and maximal buffer usage. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 100 ++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) commit 1ceecc88d29bbbb0f8d0e49e3bf6d020dc582934 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:25 2016 +0200 mlxsw: core: Add devlink shared buffer occupancy callbacks Add middle layer in mlxsw core code to forward shared buffer occupancy calls into specific ASIC drivers. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 74 ++++++++++++++++++++++++++---- drivers/net/ethernet/mellanox/mlxsw/core.h | 11 +++++ 2 files changed, 77 insertions(+), 8 deletions(-) commit 0f433fa0ecc59c1d0792937a26436bec8dd42b6d Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:24 2016 +0200 mlxsw: spectrum_buffers: Implement shared buffer configuration Implement previously introduced mlxsw core shared buffer API. For Spectrum, that is done utilizing registers SBPR, SBCM and SBPM. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 8 + drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 22 +++ .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 187 ++++++++++++++++++++- 3 files changed, 216 insertions(+), 1 deletion(-) commit 325f2f197d730bb7f6f1af2ce93fedfd728e3eed Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:23 2016 +0200 mlxsw: core: Add mlxsw_core_port_driver_priv helper Needed in following patch. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit c30a53c7de5e52249cd5381078f84082449ecc86 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:22 2016 +0200 mlxsw: spectrum_buffers: Get max_buff defaults into limits exposed to user Although the device supports max_buff magic values 0 and 0xff, these are not exposed to the user via devlink. Therefore, adjust the default values to be within configurable range. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 4 ++++ .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 28 +++++++++++----------- 2 files changed, 18 insertions(+), 14 deletions(-) commit bc872506f58c21d1ee44b1303a5f5d00354e72c5 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:21 2016 +0200 mlxsw: spectrum_buffers: Change initialization of PG 9 As explained in commit ff6551ec0c27 ("mlxsw: spectrum: Correctly configure headroom size") control packets are directed to priority group buffer 9 (PG9) in the ports' headroom buffers. Since we don't want to drop control packets in case they can't be admitted to the switch's shared buffer we bind PG9 to a different ingress pool from the one used by all other PGs. Unlike other PGs, we currently don't expose the binding between PG9 to a pool and leave it fixed. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 5408f7cba341b26edf2fa5bcaaa37e52301830e2 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:20 2016 +0200 mlxsw: spectrum_buffers: Remove eg pool 3 default init and CPU port TC binding to it Since there is no congestion control for CPU port traffic, we can change the CPU port TC binding to pool 0 with min_buff and max_buff zeroed. Remove initialization for pool egress pool 3 since it is no longer used by dafault. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 078f9c7132cbbe12c2484a817ca5f477d1641b61 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:19 2016 +0200 mlxsw: spectrum_buffers: Cache shared buffer configuration In order to achieve faster dumping of current setting and also in order to provide possibility to get pool mode without a need to query hardware, do cache the configuration in driver. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 28 +++++++++ .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 73 ++++++++++++++++------ 2 files changed, 82 insertions(+), 19 deletions(-) commit aa99bc70bac1bb6815ad30248d0e34b14cdec575 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:18 2016 +0200 mlxsw: spectrum_buffers: Rename "pool" to "pr" in initialization Be consintent with rest of the registers (pm, cm) and use "pr" here. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 70 +++++++++++----------- 1 file changed, 35 insertions(+), 35 deletions(-) commit b11c3b4018e630dfcbdc2b9fe7aaffce5da8cfd7 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:17 2016 +0200 mlxsw: spectrum_buffers: Push out indexes and direction out of SB structs Structs are in arrays so use array index as pool/tc/prio index. With that, there is need to maintain separate arrays for ingress and egress. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 425 +++++++++++---------- 1 file changed, 221 insertions(+), 204 deletions(-) commit 94266e3278ef862bb422575a31ceb166dab1b406 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:16 2016 +0200 mlxsw: spectrum_buffers: Push out shared buffer register writes Pushed them into helper functions. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 54 ++++++++++++++++------ 1 file changed, 40 insertions(+), 14 deletions(-) commit a6179bf0d17a4d71075bad2a0b17a752fc973b64 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:15 2016 +0200 mlxsw: core: Add devlink shared buffer callbacks Add middle layer in mlxsw core code to forward shared buffer calls into specific ASIC drivers. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 105 ++++++++++++++++++++++++++++- drivers/net/ethernet/mellanox/mlxsw/core.h | 20 ++++++ 2 files changed, 123 insertions(+), 2 deletions(-) commit df38dafd255954ee7012785c62e615f595d5cb3c Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:14 2016 +0200 devlink: implement shared buffer occupancy monitoring interface User needs to monitor shared buffer occupancy. For that, he issues a snapshot command in order to instruct hardware to catch current and maximal occupancy values, and clear command in order to clear the historical maximal values. Also port-pool and tc-pool-bind command response messages are extended to carry occupancy values. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/devlink.h | 12 ++++++ include/uapi/linux/devlink.h | 6 +++ net/core/devlink.c | 98 +++++++++++++++++++++++++++++++++++++++++--- 3 files changed, 110 insertions(+), 6 deletions(-) commit bf7974710a40aaeb69dee7f62d91048bdaf79c76 Author: Jiri Pirko <jiri@mellanox.com> Date: Thu Apr 14 18:19:13 2016 +0200 devlink: add shared buffer configuration Define userspace API and drivers API for configuration of shared buffers. Four basic objects are defined: shared buffer - attributes are size, number of pools and TCs pool - chunk of sharedbuffer definition, it has some size and either static or dynamic threshold port pool threshold - to set per-port threshold for each pool port tc threshold bind - to bind port and TC to specified pool with threshold. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/devlink.h | 47 +++ include/uapi/linux/devlink.h | 57 +++ net/core/devlink.c | 940 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 1044 insertions(+) commit a22d7768860aedcd9c4011075c4d3bc1eaaddd63 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Oct 6 12:03:27 2015 +0200 ARM: dts: nomadik: add DMA engine and some channels This adds the DMA engine to the Nomadik and assigns the UART DMA channels. Both slave DMA for UARTs and the memcpy engine works fine, tested on the Nomadik NHK15. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/ste-nomadik-stn8815.dtsi | 38 ++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) commit e249fc7d9b1cfa046bc448b27c3fde5619442a7a Author: Linus Walleij <linus.walleij@linaro.org> Date: Wed Sep 2 22:30:51 2015 +0200 ARM: dts: nomadik: add accelerometer IRQ and pin setting The LIS3LV02DL accelerometer on the Nomadik NHK15 can generate IRQs by the DRDY line. Map this in the DTS file and set up the pin as input to the SoC. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/ste-nomadik-nhk15.dts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) commit 025dd3daeda77f61a280da87ae7015a6808dfe1f Author: Murali Karicheri <m-karicheri2@ti.com> Date: Mon Apr 11 10:50:30 2016 -0400 PCI: keystone: Add error IRQ handler Keystone PCI hardware generates error interrupts at RC using a platform IRQ instead of a standard MSI or legacy IRQ. Add a simple error handler that logs the fatal interrupt status to the console. [bhelgaas: s/node/dev->of_node/, tidy comments, return irqreturn_t directly] Signed-off-by: Murali Karicheri <m-karicheri2@ti.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Rob Herring <robh@kernel.org> CC: Pawel Moll <pawel.moll@arm.com> CC: Mark Rutland <mark.rutland@arm.com> CC: Ian Campbell <ijc+devicetree@hellion.org.uk> CC: Kumar Gala <galak@codeaurora.org> .../devicetree/bindings/pci/pci-keystone.txt | 1 + drivers/pci/host/pci-keystone-dw.c | 38 ++++++++++++++++++++++ drivers/pci/host/pci-keystone.c | 29 +++++++++++++++++ drivers/pci/host/pci-keystone.h | 6 ++++ 4 files changed, 74 insertions(+) commit 5883980313af70aec0ceebaef6ef0709726e5e63 Author: Eric Anholt <eric@anholt.net> Date: Mon Apr 4 14:25:59 2016 -0700 drm/vc4: Fix NULL deref in HDMI init error path If you make it here other than through err_destroy_encoder, vc4->hdmi is still NULL. Signed-off-by: Eric Anholt <eric@anholt.net> drivers/gpu/drm/vc4/vc4_hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 08302c35b59d306ff37b996e56fb2a488c1d2c2e Author: Eric Anholt <eric@anholt.net> Date: Wed Feb 10 11:42:32 2016 -0800 drm/vc4: Add DPI driver The DPI interface involves taking a ton of our GPIOs to be used as outputs, and routing display signals over them in parallel. v2: Use display_info.bus_formats[] to replace our custom DT properties. v3: Rebase on V3D documentation changes. v4: Fix rebase detritus from V3D documentation changes. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Rob Herring <robh@kernel.org> .../devicetree/bindings/display/brcm,bcm-vc4.txt | 36 ++ drivers/gpu/drm/vc4/Kconfig | 1 + drivers/gpu/drm/vc4/Makefile | 1 + drivers/gpu/drm/vc4/vc4_debugfs.c | 1 + drivers/gpu/drm/vc4/vc4_dpi.c | 520 +++++++++++++++++++++ drivers/gpu/drm/vc4/vc4_drv.c | 1 + drivers/gpu/drm/vc4/vc4_drv.h | 5 + 7 files changed, 565 insertions(+) commit 1ab92956d4aac52d0c59c229a0790a672063ece0 Author: David Wu <david.wu@rock-chips.com> Date: Thu Mar 17 00:57:17 2016 +0800 i2c: rk3x: switch to i2c generic dt parsing Switch to the new generic functions: i2c_parse_fw_timings(). Signed-off-by: David Wu <david.wu@rock-chips.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-rk3x.c | 87 ++++++++++++------------------------------- 1 file changed, 24 insertions(+), 63 deletions(-) commit de446b40d5ddb2c3f1fe453ac405543663f9ac5d Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 14:56:06 2016 -0300 perf evsel: Remove symbol_conf usage # perf test -v python 16: Try 'import perf' in python, checking link problems : --- start --- test child forked, pid 672 Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: /tmp/build/perf/python/perf.so: undefined symbol: symbol_conf test child finished with -1 ---- end ---- Try 'import perf' in python, checking link problems: FAILED! # To fix it just pass a parameter to perf_evsel__fprintf_sym telling if callchains should be printed. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-comrsr20bsnr8bg0n6rfwv12@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 2 ++ tools/perf/util/evsel.c | 6 +++--- tools/perf/util/evsel.h | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) commit 91d7b2de318ff701451dfc7ede1c029b150ef0e9 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 14:48:07 2016 -0300 perf callchain: Start moving away from global per thread cursors The recent perf_evsel__fprintf_callchain() move to evsel.c added several new symbol requirements to the python binding, for instance: # perf test -v python 16: Try 'import perf' in python, checking link problems : --- start --- test child forked, pid 18030 Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: /tmp/build/perf/python/perf.so: undefined symbol: callchain_cursor test child finished with -1 ---- end ---- Try 'import perf' in python, checking link problems: FAILED! # This would require linking against callchain.c to access to the global callchain_cursor variables. Since lots of functions already receive as a parameter a callchain_cursor struct pointer, make that be the case for some more function so that we can start phasing out usage of yet another global variable. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-djko3097eyg2rn66v2qcqfvn@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-kmem.c | 2 +- tools/perf/util/callchain.c | 5 +++-- tools/perf/util/callchain.h | 3 ++- tools/perf/util/evsel.c | 9 ++++---- tools/perf/util/hist.c | 2 +- tools/perf/util/machine.c | 26 +++++++++++++--------- tools/perf/util/machine.h | 4 ++++ .../perf/util/scripting-engines/trace-event-perl.c | 2 +- .../util/scripting-engines/trace-event-python.c | 2 +- 9 files changed, 33 insertions(+), 22 deletions(-) commit 6afedcd23cfd7ac56c011069e4a8db37b46e4623 Author: James Morse <james.morse@arm.com> Date: Wed Apr 13 13:40:00 2016 +0100 arm64: mm: Add trace_irqflags annotations to do_debug_exception() With CONFIG_PROVE_LOCKING, CONFIG_DEBUG_LOCKDEP and CONFIG_TRACE_IRQFLAGS enabled, lockdep will compare current->hardirqs_enabled with the flags from local_irq_save(). When a debug exception occurs, interrupts are disabled in entry.S, but lockdep isn't told, resulting in: DEBUG_LOCKS_WARN_ON(current->hardirqs_enabled) ------------[ cut here ]------------ WARNING: at ../kernel/locking/lockdep.c:3523 Modules linked in: CPU: 3 PID: 1752 Comm: perf Not tainted 4.5.0-rc4+ #2204 Hardware name: ARM Juno development board (r1) (DT) task: ffffffc974868000 ti: ffffffc975f40000 task.ti: ffffffc975f40000 PC is at check_flags.part.35+0x17c/0x184 LR is at check_flags.part.35+0x17c/0x184 pc : [<ffffff80080fc93c>] lr : [<ffffff80080fc93c>] pstate: 600003c5 [...] ---[ end trace 74631f9305ef5020 ]--- Call trace: [<ffffff80080fc93c>] check_flags.part.35+0x17c/0x184 [<ffffff80080ffe30>] lock_acquire+0xa8/0xc4 [<ffffff8008093038>] breakpoint_handler+0x118/0x288 [<ffffff8008082434>] do_debug_exception+0x3c/0xa8 [<ffffff80080854b4>] el1_dbg+0x18/0x6c [<ffffff80081e82f4>] do_filp_open+0x64/0xdc [<ffffff80081d6e60>] do_sys_open+0x140/0x204 [<ffffff80081d6f58>] SyS_openat+0x10/0x18 [<ffffff8008085d30>] el0_svc_naked+0x24/0x28 possible reason: unannotated irqs-off. irq event stamp: 65857 hardirqs last enabled at (65857): [<ffffff80081fb1c0>] lookup_mnt+0xf4/0x1b4 hardirqs last disabled at (65856): [<ffffff80081fb188>] lookup_mnt+0xbc/0x1b4 softirqs last enabled at (65790): [<ffffff80080bdca4>] __do_softirq+0x1f8/0x290 softirqs last disabled at (65757): [<ffffff80080be038>] irq_exit+0x9c/0xd0 This patch adds the annotations to do_debug_exception(), while trying not to call trace_hardirqs_off() if el1_dbg() interrupted a task that already had irqs disabled. Signed-off-by: James Morse <james.morse@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/fault.c | 33 +++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) commit 4bc49274403395db41dc4ae7d2080346b2319d34 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Wed Apr 6 10:42:49 2016 +0200 arm64: hw-breakpoint: Remove superfluous SMP function call Since commit 1cf4f629d9d2 ("cpu/hotplug: Move online calls to hotplugged cpu") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this SMP function calls are no longer required. Replace smp_call_function_single() with a direct call of hw_breakpoint_reset(). To keep the calling convention, interrupts are explicitly disabled around the call. Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/hw_breakpoint.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 499c81507f599d4e753cf6401f921e68efab235a Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Wed Apr 6 10:42:28 2016 +0200 arm64/debug: Remove superfluous SMP function call Since commit 1cf4f629d9d2 ("cpu/hotplug: Move online calls to hotplugged cpu") it is ensured that callbacks of CPU_ONLINE and CPU_DOWN_PREPARE are processed on the hotplugged CPU. Due to this SMP function calls are no longer required. Replace smp_call_function_single() with a direct call to clear_os_lock(). The function writes the OSLAR register to clear OS locking. This does not require to be called with interrupts disabled, therefore the smp_call_function_single() calling convention is not preserved. Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/debug-monitors.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 97740051dd31d200a0efaa84544fe5e4713aac40 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 17:43:09 2016 +0200 arm64: simplify kernel segment mapping granularity The mapping of the kernel consist of four segments, each of which is mapped with different permission attributes and/or lifetimes. To optimize the TLB and translation table footprint, we define various opaque constants in the linker script that resolve to different aligment values depending on the page size and whether CONFIG_DEBUG_ALIGN_RODATA is set. Considering that - a 4 KB granule kernel benefits from a 64 KB segment alignment (due to the fact that it allows the use of the contiguous bit), - the minimum alignment of the .data segment is THREAD_SIZE already, not PAGE_SIZE (i.e., we already have padding between _data and the start of the .data payload in many cases), - 2 MB is a suitable alignment value on all granule sizes, either for mapping directly (level 2 on 4 KB), or via the contiguous bit (level 3 on 16 KB and 64 KB), - anything beyond 2 MB exceeds the minimum alignment mandated by the boot protocol, and can only be mapped efficiently if the physical alignment happens to be the same, we can simplify this by standardizing on 64 KB (or 2 MB) explicitly, i.e., regardless of granule size, all segments are aligned either to 64 KB, or to 2 MB if CONFIG_DEBUG_ALIGN_RODATA=y. This also means we can drop the Kconfig dependency of CONFIG_DEBUG_ALIGN_RODATA on CONFIG_ARM64_4K_PAGES. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/Kconfig.debug | 2 +- arch/arm64/kernel/vmlinux.lds.S | 25 +++++++++++++++---------- 2 files changed, 16 insertions(+), 11 deletions(-) commit 7eb90f2ff7e3ee814ff12f3cd909b965cdd4a869 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 17:43:08 2016 +0200 arm64: cover the .head.text section in the .text segment mapping Keeping .head.text out of the .text mapping buys us very little: its actual payload is only 4 KB, most of which is padding, but the page alignment may add up to 2 MB (in case of CONFIG_DEBUG_ALIGN_RODATA=y) of additional padding to the uncompressed kernel Image. Also, on 4 KB granule kernels, the 4 KB misalignment of .text forces us to map the adjacent 56 KB of code without the PTE_CONT attribute, and since this region contains things like the vector table and the GIC interrupt handling entry point, this region is likely to benefit from the reduced TLB pressure that results from PTE_CONT mappings. So remove the alignment between the .head.text and .text sections, and use the [_text, _etext) rather than the [_stext, _etext) interval for mapping the .text segment. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/vmlinux.lds.S | 1 - arch/arm64/mm/mmu.c | 10 +++++----- 2 files changed, 5 insertions(+), 6 deletions(-) commit 546c8c44f092b2f23291fe499c221efc8cabbb67 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 17:43:07 2016 +0200 arm64: move early boot code to the .init segment Apart from the arm64/linux and EFI header data structures, there is nothing in the .head.text section that must reside at the beginning of the Image. So let's move it to the .init section where it belongs. Note that this involves some minor tweaking of the EFI header, primarily because the address of 'stext' no longer coincides with the start of the .text section. It also requires a couple of relocated symbol references to be slightly rewritten or their definition moved to the linker script. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/efi-entry.S | 2 +- arch/arm64/kernel/head.S | 32 +++++++++++++++----------------- arch/arm64/kernel/image.h | 4 ++++ 3 files changed, 20 insertions(+), 18 deletions(-) commit 2c09ec06bc39fc85a2b3856524348c301def27af Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 17:43:06 2016 +0200 arm64: use 'segment' rather than 'chunk' to describe mapped kernel regions Replace the poorly defined term chunk with segment, which is a term that is already used by the ELF spec to describe contiguous mappings with the same permission attributes of statically allocated ranges of an executable. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/mmu.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit c134043ed396b06addf5866d977fed7ba6a393a9 Author: Bert Vermeulen <bert@biot.com> Date: Mon Apr 4 16:46:07 2016 +0200 ARM: dts: kirkwood: Add DTS for Linksys EA4200v2/EA4500 This platform is based on a Marvell 88E6282 SoC and 88E6171 switch. [gregory.clement@free-electrons.com: fix block comment style] Signed-off-by: Bert Vermeulen <bert@biot.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Imre Kaloz <kaloz@openwrt.org> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/kirkwood-linksys-viper.dts | 240 +++++++++++++++++++++++++++ 2 files changed, 241 insertions(+) commit 864140d981b589c125eebcca3b11d4a7a3d232e6 Author: Roger Shimizu <rogershimizu@gmail.com> Date: Wed Mar 30 01:11:45 2016 +0900 ARM: dts: orion5x: add device tree for kurobox-pro Add dts file to support Buffalo/Revogear Kurobox-Pro, which is marvell orion5x based 3.5" HDD NAS. It's a quite old product and already discontinued. So there's no official website for it. But it was an early product which used marvell orion5x 88F5182 chipset, it's popular in the community. Some unofficial site: - http://buffalo.nas-central.org/wiki/Category:KuroboxPro - http://nice.kaze.com/KUROPRO_ProductSpecifications.pdf This device tree is based on the board file: arch/arm/mach-orion5x/kurobox_pro-setup.c However, the probing order of NAND and JEDEC-Flash are different from the original board file, this results in incompatible minor number for a few /dev/mtdX and /dev/mtdblockX devices. So I still want to keep the board file for the time being. Signed-off-by: Roger Shimizu <rogershimizu@gmail.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/orion5x-kuroboxpro.dts | 127 +++++++++++++++++++++++++++++++ 2 files changed, 128 insertions(+) commit 49ad48c83a016850c754192d2b520e782e91ea20 Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:50 2016 +0200 ARM: dts: kirkwood: Add address go regulator unit name The regulator has a reg property so include it in the unit name. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-netgear_readynas_duo_v2.dts | 2 +- arch/arm/boot/dts/kirkwood-netgear_readynas_nv+_v2.dts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 5d7fd6563348252871db218be438fad05ae3ef7c Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:49 2016 +0200 ARM: dts: kirkwood: Add address to mbus unit name The mbus node has a ranges property. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-6192.dtsi | 2 +- arch/arm/boot/dts/kirkwood-6281.dtsi | 2 +- arch/arm/boot/dts/kirkwood-6282.dtsi | 2 +- arch/arm/boot/dts/kirkwood-98dx4122.dtsi | 2 +- arch/arm/boot/dts/kirkwood.dtsi | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) commit 57910a3e0e4641255624d5e75839ea00a0f2bd96 Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:48 2016 +0200 ARM: dts: kirkwood: Remove address from gpio-i2c unit name gpio-i2c does not have a reg property, just a list of gpios. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-km_common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eb13cf8345e94a02e9872ca3e909596a5ddb5f90 Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:47 2016 +0200 ARM: dts: kirkwood: Fixup pcie DT warnings PCIe has a range property, so the unit name should contain an address. Make use of the label to enable individual PCIe busses. Also, fixup the synology dtsi file which added a label pcie2 rather than using the existing pcie1 label. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-6192.dtsi | 2 +- arch/arm/boot/dts/kirkwood-6281.dtsi | 2 +- arch/arm/boot/dts/kirkwood-6282.dtsi | 2 +- arch/arm/boot/dts/kirkwood-98dx4122.dtsi | 2 +- arch/arm/boot/dts/kirkwood-b3.dts | 19 ++++++++----------- arch/arm/boot/dts/kirkwood-db-88f6281.dts | 14 ++++++-------- arch/arm/boot/dts/kirkwood-db-88f6282.dts | 20 +++++++++----------- arch/arm/boot/dts/kirkwood-dir665.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-ds111.dts | 2 +- arch/arm/boot/dts/kirkwood-ds112.dts | 6 +++++- arch/arm/boot/dts/kirkwood-ds212.dts | 2 +- arch/arm/boot/dts/kirkwood-ds411.dts | 6 +++++- arch/arm/boot/dts/kirkwood-ds411slim.dts | 2 +- arch/arm/boot/dts/kirkwood-iconnect.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-km_common.dtsi | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-laplug.dts | 17 ++++++++--------- arch/arm/boot/dts/kirkwood-linkstation.dtsi | 17 ++++++++--------- arch/arm/boot/dts/kirkwood-mplcec4.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-nas2big.dts | 18 ++++++++---------- .../boot/dts/kirkwood-netgear_readynas_duo_v2.dts | 18 ++++++++---------- .../boot/dts/kirkwood-netgear_readynas_nv+_v2.dts | 21 +++++++++------------ arch/arm/boot/dts/kirkwood-nsa310.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-nsa320.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-nsa325.dts | 17 +++++++---------- arch/arm/boot/dts/kirkwood-nsa3x0-common.dtsi | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-openrd.dtsi | 14 ++++---------- arch/arm/boot/dts/kirkwood-rd88f6192.dts | 20 +++++++++----------- arch/arm/boot/dts/kirkwood-rd88f6281.dtsi | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-rs212.dts | 6 +++++- arch/arm/boot/dts/kirkwood-synology.dtsi | 22 ++++++++-------------- arch/arm/boot/dts/kirkwood-t5325.dts | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-ts219-6282.dts | 12 ++---------- arch/arm/boot/dts/kirkwood-ts219.dtsi | 18 ++++++++---------- arch/arm/boot/dts/kirkwood-ts419-6282.dts | 15 +++------------ 35 files changed, 207 insertions(+), 267 deletions(-) commit 8b1750de6a6a73f5d8796894c8d1858a97f0c77c Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:46 2016 +0200 ARM: dts: kirkwood: Add address to ethernet-phy unit name PHYs have an address on the mdio bus. So the unit name should contain an address. This is complicated in that some .dtsi files contain the node, but the reg is set in the .dts file. In this case, use the abstract address X. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-ns2-common.dtsi | 2 +- arch/arm/boot/dts/kirkwood-t5325.dts | 2 +- arch/arm/boot/dts/kirkwood-ts219.dtsi | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 689168aae9de15706bb9f6fea87dbeaab30f162e Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:45 2016 +0200 ARM: dts: kirkwood: Remove address from dsa unit name The dsa node does not have a reg property, so remove the address from the unit name. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-dir665.dts | 2 +- arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts | 2 +- arch/arm/boot/dts/kirkwood-rd88f6281-a.dts | 2 +- arch/arm/boot/dts/kirkwood-rd88f6281-z0.dts | 2 +- arch/arm/boot/dts/kirkwood-rd88f6281.dtsi | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) commit dab08333993942090b2f0190a83d2de557db2e6c Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:44 2016 +0200 ARM: dts: kirkwood: Remove node address from leds leds don't have a reg property, so remove the address from the unit name. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-lsxl.dtsi | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 395c755fb874e8af1d3f5eff69a954093002c9d8 Author: Andrew Lunn <andrew@lunn.ch> Date: Sun Apr 3 04:03:43 2016 +0200 ARM: dts: kirkwood: Remove button address and fixup names The DT compiler is now warning about unit names with addresses but not reg property. Fix all the gpio-key buttons which causes warnings. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-blackarmor-nas220.dts | 4 ++-- arch/arm/boot/dts/kirkwood-cloudbox.dts | 2 +- arch/arm/boot/dts/kirkwood-dnskw.dtsi | 6 +++--- arch/arm/boot/dts/kirkwood-ib62x0.dts | 4 ++-- arch/arm/boot/dts/kirkwood-iconnect.dts | 4 ++-- arch/arm/boot/dts/kirkwood-laplug.dts | 2 +- arch/arm/boot/dts/kirkwood-lsxl.dtsi | 6 +++--- arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts | 4 ++-- arch/arm/boot/dts/kirkwood-netxbig.dtsi | 8 ++++---- arch/arm/boot/dts/kirkwood-ns2-common.dtsi | 2 +- arch/arm/boot/dts/kirkwood-nsa3x0-common.dtsi | 6 +++--- arch/arm/boot/dts/kirkwood-openblocks_a6.dts | 2 +- arch/arm/boot/dts/kirkwood-openblocks_a7.dts | 2 +- arch/arm/boot/dts/kirkwood-pogoplug-series-4.dts | 2 +- arch/arm/boot/dts/kirkwood-t5325.dts | 2 +- arch/arm/boot/dts/kirkwood-ts219-6281.dts | 4 ++-- arch/arm/boot/dts/kirkwood-ts219-6282.dts | 4 ++-- arch/arm/boot/dts/kirkwood-ts419.dtsi | 4 ++-- 18 files changed, 34 insertions(+), 34 deletions(-) commit 23d2af622de748bf57d31a4125d06d183c29e908 Author: Romain Perier <romain.perier@free-electrons.com> Date: Tue Mar 29 10:02:28 2016 +0200 ARM: mvebu_v5_defconfig: Switching to the new Marvell's cryptographic engine driver This enables the new driver for Marvell CESA crypto engines on all mvebu v5. The old driver is no longer used, but it is still in the tree for fallback. Signed-off-by: Romain Perier <romain.perier@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/configs/mvebu_v5_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f092d438018d60fc2a5b507963ae107041c699ea Author: Romain Perier <romain.perier@free-electrons.com> Date: Fri Mar 18 09:44:54 2016 +0100 ARM: multi_v7_defconfig: Enabling the new Marvell's cryptographic engine driver This enables the new driver for Marvell CESA crypto engines on all ARMv7. Signed-off-by: Romain Perier <romain.perier@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit e269777f72b32db6200f6d925cc40d8613c5c308 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Tue Mar 29 18:17:40 2016 +0200 MAINTAINERS: attach arch/arm/configs/mvebu_*_defconfig to relevant maintainers The arch/arm/configs/mvebu_*_defconfig currently don't belong to any maintainer, so get_maintainer returns only information based on commits, which is not completely accurate. Therefore, this commit replaces a useless empty newline in MAINTAINERS by a line attaching those defconfigs to the appropriate Marvell EBU maintainers. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Acked-by: Jason Cooper <jason@lakedaemon.net> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a354d958d42ae65eca6f5524506e8a9783db198a Author: Romain Perier <romain.perier@free-electrons.com> Date: Sun Mar 20 20:19:16 2016 +0100 ARM: mvebu_v7_defconfig: Enabling the new Marvell's cryptographic engine driver This enables the new driver for Marvell CESA crypto engines on all mvebu v7. Signed-off-by: Romain Perier <romain.perier@free-electrons.com> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/configs/mvebu_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit bbf86c43eace367e805199f94ad8b5a45636f805 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 14 13:53:10 2016 -0300 perf trace: Move socket_type beautifier to tools/perf/trace/beauty/ To reduce the size of builtin-trace.c. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ao91htwxdqwlwxr47gbluou1@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 60 +---------------------------------- tools/perf/trace/beauty/socket_type.c | 60 +++++++++++++++++++++++++++++++++++ 2 files changed, 61 insertions(+), 59 deletions(-) commit 3aa02cb664c5fb1042958c8d1aa8c35055a2ebc4 Author: Takashi Iwai <tiwai@suse.de> Date: Thu Apr 14 18:02:37 2016 +0200 ALSA: pcm : Call kill_fasync() in stream lock Currently kill_fasync() is called outside the stream lock in snd_pcm_period_elapsed(). This is potentially racy, since the stream may get released even during the irq handler is running. Although snd_pcm_release_substream() calls snd_pcm_drop(), this doesn't guarantee that the irq handler finishes, thus the kill_fasync() call outside the stream spin lock may be invoked after the substream is detached, as recently reported by KASAN. As a quick workaround, move kill_fasync() call inside the stream lock. The fasync is rarely used interface, so this shouldn't have a big impact from the performance POV. Ideally, we should implement some sync mechanism for the proper finish of stream and irq handler. But this oneliner should suffice for most cases, so far. Reported-by: Baozeng Ding <sploving1@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/core/pcm_lib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9f2875912dac35d9272a82ea9eec9e5884b42cd2 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:46:01 2016 +0200 arm64: mm: restrict virt_to_page() to the linear mapping Now that the vmemmap region has been redefined to cover the linear region rather than the entire physical address space, we no longer need to perform a virtual-to-physical translation in the implementaion of virt_to_page(). This restricts virt_to_page() translations to the linear region, so redefine virt_addr_valid() as well. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/memory.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 3e1907d5bf5a1e0b182ee599f92586f0165029e2 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:46:00 2016 +0200 arm64: mm: move vmemmap region right below the linear region This moves the vmemmap region right below PAGE_OFFSET, aka the start of the linear region, and redefines its size to be a power of two. Due to the placement of PAGE_OFFSET in the middle of the address space, whose size is a power of two as well, this guarantees that virt to page conversions and vice versa can be implemented efficiently, by masking and shifting rather than ordinary arithmetic. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/memory.h | 18 +++++++++++++++++- arch/arm64/include/asm/pgtable.h | 11 +++-------- arch/arm64/mm/dump.c | 16 ++++++++-------- arch/arm64/mm/init.c | 14 ++++++++++---- 4 files changed, 38 insertions(+), 21 deletions(-) commit e44308e62e19b42810207780a2a32148af0cb5d9 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:45:59 2016 +0200 arm64: insn: avoid virt_to_page() translations on core kernel symbols Before restricting virt_to_page() to the linear mapping, ensure that the text patching code does not use it to resolve references into the core kernel text, which is mapped in the vmalloc area. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/insn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 22b6f3b0549be61a2d5fe8210ff7628e6d2d8185 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:45:58 2016 +0200 arm64: mm: avoid virt_to_page() translation for the zero page The zero page is statically allocated, so grab its struct page pointer without using virt_to_page(), which will be restricted to the linear mapping later. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d386825c959efeaae3315c25dd2d2874c68829c7 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:45:57 2016 +0200 arm64: mm: free __init memory via the linear mapping The implementation of free_initmem_default() expects __init_begin and __init_end to be covered by the linear mapping, which is no longer the case. So open code it instead, using addresses that are explicitly translated from kernel virtual to linear virtual. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 97bbb54e4f27f4c63645f603bf767183ee0dd549 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 16:45:56 2016 +0200 arm64: vdso: avoid virt_to_page() translations on kernel symbols The translation performed by virt_to_page() is only valid for linear addresses, and kernel symbols are no longer in the linear mapping. So perform the __pa() translation explicitly, which does the right thing in either case, and only then translate to a struct page offset. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/vdso.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0fd71a620be8648486a126fccadf9f7c2a818676 Author: Prarit Bhargava <prarit@redhat.com> Date: Thu Apr 14 10:40:57 2016 -0400 selinux: Change bool variable name to index. security_get_bool_value(int bool) argument "bool" conflicts with in-kernel macros such as BUILD_BUG(). This patch changes this to index which isn't a type. Cc: Paul Moore <paul@paul-moore.com> Cc: Stephen Smalley <sds@tycho.nsa.gov> Cc: Eric Paris <eparis@parisplace.org> Cc: James Morris <james.l.morris@oracle.com> Cc: "Serge E. Hallyn" <serge@hallyn.com> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Andrew Perepechko <anserper@ya.ru> Cc: Jeff Vander Stoep <jeffv@google.com> Cc: selinux@tycho.nsa.gov Cc: Eric Paris <eparis@redhat.com> Cc: Paul Moore <pmoore@redhat.com> Cc: David Howells <dhowells@redhat.com> Signed-off-by: Prarit Bhargava <prarit@redhat.com> Acked-by: David Howells <dhowells@redhat.com> [PM: wrapped description for checkpatch.pl, use "selinux:..." as subj] Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/include/conditional.h | 2 +- security/selinux/ss/services.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) commit 8923a16686569375bfa25b877769f9a3093e9f22 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 15:18:43 2016 +0200 arm64: remove the now unneeded relocate_initrd() This removes the relocate_initrd() implementation and invocation, which are no longer needed now that the placement of the initrd is guaranteed to be covered by the linear mapping. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/setup.c | 64 ----------------------------------------------- 1 file changed, 64 deletions(-) commit 177e15f0c1444cd392374ec7175c4787fd911369 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 15:18:42 2016 +0200 arm64: add the initrd region to the linear mapping explicitly Instead of going out of our way to relocate the initrd if it turns out to occupy memory that is not covered by the linear mapping, just add the initrd to the linear mapping. This puts the burden on the bootloader to pass initrd= and mem= options that are mutually consistent. Note that, since the placement of the linear region in the PA space is also dependent on the placement of the kernel Image, which may reside anywhere in memory, we may still end up with a situation where the initrd and the kernel Image are simply too far apart to be covered by the linear region. Since we now leave it up to the bootloader to pass the initrd in memory that is guaranteed to be accessible by the kernel, add a mention of this to the arm64 boot protocol specification as well. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> Documentation/arm64/booting.txt | 4 ++++ arch/arm64/mm/init.c | 29 +++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) commit 3bab79edc67152cb6cadb12773b7c7d05228eb77 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 14:25:48 2016 +0200 Revert "arm64: account for sparsemem section alignment when choosing vmemmap offset" This reverts commit 36e5cd6b897e17d03008f81e075625d8e43e52d0, since the section alignment is now guaranteed by construction when choosing the value of memstart_addr. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/pgtable.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 06e9bf2fd9b372bc1c757995b6ca1cfab0720acb Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 14:25:47 2016 +0200 arm64: choose memstart_addr based on minimum sparsemem section alignment This redefines ARM64_MEMSTART_ALIGN in terms of the minimal alignment required by sparsemem vmemmap. This comes down to using 1 GB for all translation granules if CONFIG_SPARSEMEM_VMEMMAP is enabled. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/kernel-pgtable.h | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) commit 2958987f5da2ebcf6a237c5f154d7e3340e60945 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Wed Mar 30 14:25:46 2016 +0200 arm64/mm: ensure memstart_addr remains sufficiently aligned After choosing memstart_addr to be the highest multiple of ARM64_MEMSTART_ALIGN less than or equal to the first usable physical memory address, we clip the memblocks to the maximum size of the linear region. Since the kernel may be high up in memory, we take care not to clip the kernel itself, which means we have to clip some memory from the bottom if this occurs, to ensure that the distance between the first and the last usable physical memory address can be covered by the linear region. However, we fail to update memstart_addr if this clipping from the bottom occurs, which means that we may still end up with virtual addresses that wrap into the userland range. So increment memstart_addr as appropriate to prevent this from happening. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/mm/init.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 346fea63a8d25644a5ad06ecd98d6a4747c63885 Author: Robert Foss <robert.foss@collabora.com> Date: Thu Apr 14 10:34:16 2016 -0400 include/drm: Reword debug categories comment. The debug category comment mentions 4 categories, but more than 4 categories are listed. Let's change the wording to something a bit more generic. Signed-off-by: Robert Foss <robert.foss@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460644456-9752-1-git-send-email-robert.foss@collabora.com include/drm/drmP.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4d16544d0bde4b19da30789a8715635fd9c3889d Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 13 14:14:16 2016 +0300 ath10k: fix parenthesis alignment Found by checkpatch: drivers/net/wireless/ath/ath10k/mac.c:6800: Alignment should match open parent Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f4ffb7de9630065040e8142d651708e85eeb863 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 13 14:14:02 2016 +0300 ath10k: prefer ether_addr_copy() over memcpy() Fixes checkpatch warning: drivers/net/wireless/ath/ath10k/wmi.c:5800: Prefer ether_addr_copy() over memcpy() if the Ethernet addresses are __aligned(2) Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit c178da58c7aa73d1442ce10cc61df41224115d19 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 13 14:13:49 2016 +0300 ath10k: prefer ether_addr_equal() or ether_addr_equal_unaligned() over memcmp() Fixes checkpatch warnings: drivers/net/wireless/ath/ath10k/mac.c:452: Prefer ether_addr_equal() or ether_addr_equal_unaligned() over memcmp() drivers/net/wireless/ath/ath10k/mac.c:455: Prefer ether_addr_equal() or ether_addr_equal_unaligned() over memcmp() drivers/net/wireless/ath/ath10k/txrx.c:133: Prefer ether_addr_equal() or ether_addr_equal_unaligned() over memcmp() Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 4 ++-- drivers/net/wireless/ath/ath10k/txrx.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit beeb1a302f783b0ddeabafebf03f30d589df15eb Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 13 14:13:35 2016 +0300 ath10k: prefer kernel type 'u64' over 'u_int64_t' Fixes checkpatch warnings: drivers/net/wireless/ath/ath10k/htt.h:1477: Prefer kernel type 'u64' over 'u_int64_t' drivers/net/wireless/ath/ath10k/htt.h:1480: Prefer kernel type 'u64' over 'u_int64_t' Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 14e105cd4085c7bbf42f0eef8c677ad6c7d78a83 Author: Kalle Valo <kvalo@qca.qualcomm.com> Date: Wed Apr 13 14:13:21 2016 +0300 ath10k: fix checkpatch warnings related to spaces Fix checkpatch warnings about use of spaces with operators: spaces preferred around that '*' (ctx:VxV) This has been recently added to checkpatch. Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/ce.c | 6 +++--- drivers/net/wireless/ath/ath10k/ce.h | 2 +- drivers/net/wireless/ath/ath10k/core.h | 6 +++--- drivers/net/wireless/ath/ath10k/debug.h | 2 +- drivers/net/wireless/ath/ath10k/htc.h | 4 ++-- drivers/net/wireless/ath/ath10k/htt.c | 2 +- drivers/net/wireless/ath/ath10k/mac.c | 8 ++++---- drivers/net/wireless/ath/ath10k/targaddrs.h | 2 +- drivers/net/wireless/ath/ath10k/thermal.h | 2 +- drivers/net/wireless/ath/ath10k/txrx.c | 2 +- drivers/net/wireless/ath/ath10k/wmi-tlv.h | 4 ++-- drivers/net/wireless/ath/ath10k/wmi.c | 2 +- drivers/net/wireless/ath/ath10k/wmi.h | 18 +++++++++--------- 13 files changed, 30 insertions(+), 30 deletions(-) commit e97321fa095f1ea7110d4d2ba446bd6141ed9a03 Author: Bob Peterson <rpeterso@redhat.com> Date: Tue Apr 12 16:14:26 2016 -0400 GFS2: Don't dereference inode in gfs2_inode_lookup until it's valid Function gfs2_inode_lookup was dereferencing the inode, and after, it checks for the value being NULL. We need to check that first. Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/inode.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7cb7348f75e442e2ea4bc0b2430a232b13998abf Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:34:07 2016 +0300 regulator: lp3972: Silence uninitialized variable warning This is harmless but my static checker complains that "tmp" is uninitialized if lp3972_i2c_read() fails. I have moved the line of code below the error handling to silence the warning. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/lp3972.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 40e1d79ee16968bff7b3cf12c65d5740c02be1b6 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:34:41 2016 +0300 regulator: lp3971: Silence uninitialized variable warning This is harmless but if lp3971_i2c_read() fails then "tmp" can be uninitialized. Silence the warning by moving the error handling up a line. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/lp3971.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0b22cd276cec21107d9d69453fa58abba73e71df Merge: c5ab6ad 860b8d4 Author: Ingo Molnar <mingo@kernel.org> Date: Thu Apr 14 15:30:59 2016 +0200 Merge tag 'perf-core-for-mingo-20160414' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements from Arnaldo Carvalho de Melo: User visible changes: - Introduce 'perf record --timestamp-filename', to add a timestamp at the end of the 'perf data' file. Will get added value when the patch to make 'perf.data' file snapshots gets merged (Wang Nan) - Fix display of variables present in both --config and --user in 'perf list' (Taeung Song) Build fixes: - Add seccomp and getradom beautifier related defines to fix the build in older systems where those definitions are not available (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 84349698f05dc7ed6df6772d43175eb3703ed8dc Author: Vishal Thanki <vishalthanki@gmail.com> Date: Thu Apr 7 23:37:12 2016 +0200 mwifiex: fix the incorrect WARN_ON during suspend During system suspend, there is a kernel WARNING issued if there is a pending command present. By marking the wait queue disabled after calling the command completion routine fixes it. Signed-off-by: Vishal Thanki <vishalthanki@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cmdevt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bcc920e8f08336cbbdcdba7c4449c27137e6b4b9 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Mon Apr 11 07:52:41 2016 -0700 mwifiex: fix incorrect ht capability problem IEEE80211_CHAN_NO_HT40PLUS and IEEE80211_CHAN_NO_HT40PLUS channel flags tell if HT40 operation is allowed on a channel or not. This patch ensures ht_capability information is modified accordingly so that we don't end up creating a HT40 connection when it's not allowed for current regulatory domain. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Cathy Luo <cluo@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/sta_ioctl.c | 44 +++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) commit c3ec0ff6425b86655aa34b5c6cb0f7b6d559c6b2 Author: Xinming Hu <huxm@marvell.com> Date: Mon Apr 11 07:52:40 2016 -0700 mwifiex: do not wait on semaphore during card removal Host hang is observed if card is removed before firmware download gets completed. In this case, firmware will be failed to download and adapter structure gets freed. In other thread, mwifiex_remove_card() waits on semaphore until the firmware download fails. This wait is not necessary and may result in invalid adapter access. This patch uses down_trylock to return immediately so that hang issue won't occur. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b9db397879333c272f2bc888cd713773e7d2604f Author: Shengzhen Li <szli@marvell.com> Date: Mon Apr 11 07:52:39 2016 -0700 mwifiex: add default setting for pcie firmware download This patch adds default setting for pcie firmware download name in case that there are newer chipset version. Signed-off-by: Shengzhen Li <szli@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.c | 3 +++ drivers/net/wireless/marvell/mwifiex/pcie.h | 2 ++ 2 files changed, 5 insertions(+) commit e87650bce9a5499f133341db99c9293bfb8a0282 Author: Shengzhen Li <szli@marvell.com> Date: Mon Apr 11 07:52:38 2016 -0700 mwifiex: add pcie usb/uart firmware download support This patch adds support for downloading usb/uart firmware for 8997 chipset by reading the chip version. Signed-off-by: Shengzhen Li <szli@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.c | 17 +++++++++++++++-- drivers/net/wireless/marvell/mwifiex/pcie.h | 7 +++++-- 2 files changed, 20 insertions(+), 4 deletions(-) commit c865a70098d9419d154f6d1ad97cd0150af968d1 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Mon Apr 11 07:52:37 2016 -0700 mwifiex: missing break statement This patch adds missing break statement at the end of PCIE_DEVICE_ID_MARVELL_88W8897 switch section. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.c | 1 + 1 file changed, 1 insertion(+) commit c462ebcdfe425a132aaba950d114ac32de3cdf44 Author: Arend van Spriel <arend@broadcom.com> Date: Mon Apr 11 11:35:28 2016 +0200 brcmfmac: create common function for handling brcmf_proto_hdrpull() In receive path brcmf_proto_hdrpull() needs to be called and handled similar in brcmf_rx_frame() and brcmf_rx_event(). Move that duplicated code in separate function. Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by: Franky Lin <franky.lin@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../wireless/broadcom/brcm80211/brcmfmac/core.c | 43 +++++++++++----------- 1 file changed, 21 insertions(+), 22 deletions(-) commit 9c349892ccc90c6de2baaa69cc78449f58082273 Author: Arend van Spriel <arend@broadcom.com> Date: Mon Apr 11 11:35:27 2016 +0200 brcmfmac: revise handling events in receive path Move event handling out of brcmf_netif_rx() avoiding the need to pass a flag. This flag is only ever true for USB hosts as other interface use separate brcmf_rx_event() function. Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by: Franky Lin <franky.lin@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/broadcom/brcm80211/brcmfmac/bus.h | 2 +- .../wireless/broadcom/brcm80211/brcmfmac/core.c | 24 +++++++++++----------- .../wireless/broadcom/brcm80211/brcmfmac/core.h | 3 +-- .../broadcom/brcm80211/brcmfmac/fwsignal.c | 8 ++++---- .../wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 2 +- 5 files changed, 19 insertions(+), 20 deletions(-) commit bbd1f932e7c45ef173468ae2b49edefe52a8c835 Author: Arend van Spriel <arend@broadcom.com> Date: Mon Apr 11 11:35:26 2016 +0200 brcmfmac: cleanup ampdu-rx host reorder code The code for ampdu-rx host reorder is related to the firmware signalling supported in BCDC protocol. This change moves the code to fwsignal module. Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by: Franky Lin <franky.lin@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../wireless/broadcom/brcm80211/brcmfmac/bcdc.c | 7 + .../wireless/broadcom/brcm80211/brcmfmac/core.c | 214 +-------------------- .../wireless/broadcom/brcm80211/brcmfmac/core.h | 4 - .../broadcom/brcm80211/brcmfmac/fwsignal.c | 209 ++++++++++++++++++++ .../broadcom/brcm80211/brcmfmac/fwsignal.h | 1 + .../wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 4 + .../wireless/broadcom/brcm80211/brcmfmac/proto.h | 16 ++ 7 files changed, 239 insertions(+), 216 deletions(-) commit c56caa9db8abbbfb9e31325e0897705aa897db37 Author: Franky Lin <franky.lin@broadcom.com> Date: Mon Apr 11 11:35:25 2016 +0200 brcmfmac: screening firmware event packet Firmware uses asynchronized events as a communication method to the host. The event packets are marked as ETH_P_LINK_CTL protocol type. For SDIO and PCIe bus, this kind of packets are delivered through virtual event channel not data channel. This patch adds a screening logic to make sure the event handler only processes the events coming from the correct channel. Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Signed-off-by: Franky Lin <franky.lin@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/broadcom/brcm80211/brcmfmac/bus.h | 4 +- .../wireless/broadcom/brcm80211/brcmfmac/core.c | 46 +++++++++++++++++----- .../wireless/broadcom/brcm80211/brcmfmac/core.h | 3 +- .../wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 42 +++++++++++--------- .../wireless/broadcom/brcm80211/brcmfmac/sdio.c | 32 +++++++++++---- .../net/wireless/broadcom/brcm80211/brcmfmac/usb.c | 2 +- 6 files changed, 90 insertions(+), 39 deletions(-) commit 2aec2c9d42aa9ac4b31583cf4e1c7774e040e57d Author: Hante Meuleman <hante.meuleman@broadcom.com> Date: Mon Apr 11 11:35:24 2016 +0200 brcmfmac: fix p2p scan abort null pointer exception When p2p connection setup is performed without having ever done an escan a null pointer exception can occur. This is because the ifp to abort scanning is taken from escan struct while it was never initialized. Fix this by using the primary ifp for scan abort. The abort should still be performed and all scan related commands are performed on primary ifp. Reviewed-by: Arend Van Spriel <arend@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Signed-off-by: Hante Meuleman <hante.meuleman@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 46f2b38a91b08ec7faf1839c3cdcec3cfcc6ad50 Author: Hante Meuleman <hante.meuleman@broadcom.com> Date: Mon Apr 11 11:35:23 2016 +0200 brcmfmac: insert default boardrev in nvram data if missing Some nvram files/stores come without the boardrev information, but firmware requires this to be set. When not found in nvram then add a default boardrev string to the nvram data. Reported-by: Rafal Milecki <zajec5@gmail.com> Reviewed-by: Arend Van Spriel <arend@broadcom.com> Reviewed-by: Franky (Zhenhui) Lin <franky.lin@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Signed-off-by: Hante Meuleman <hante.meuleman@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../broadcom/brcm80211/brcmfmac/firmware.c | 30 ++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) commit 28b285a6129d0c19bcf9e40bb7767da0fd62974f Author: Hante Meuleman <hante.meuleman@broadcom.com> Date: Mon Apr 11 11:35:22 2016 +0200 brcmfmac: fix clearing wowl wake indicators Newer firmwares require the usage of the wowl wakeind struct as size for the iovar to clear the wake indicators. Older firmwares do not care, so change the used size. Reviewed-by: Arend Van Spriel <arend@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Signed-off-by: Hante Meuleman <hante.meuleman@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7fde010d473d7eb98a2af3dd91e83838a1f24cdf Author: Hante Meuleman <hante.meuleman@broadcom.com> Date: Mon Apr 11 11:35:21 2016 +0200 brcmfmac: clear eventmask array before using it When the event_msgs iovar is set an array is used to configure the enabled events. This arrays needs to nulled before configuring otherwise unhandled events will be enabled. This solves a problem where in case of wowl the host got woken by an incorrectly enabled event. Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by: Arend Van Spriel <arend@broadcom.com> Signed-off-by: Hante Meuleman <hante.meuleman@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/fweh.c | 1 + 1 file changed, 1 insertion(+) commit c31a571d4360a7765613615709627e83059ce946 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Mar 11 19:13:21 2016 +0530 gpio: gpiolib: Print error number if gpio hog failed Print the error number of GPIO hog failed during its configurations. This helps in identifying the failure without instrumenting the code. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit d1279d94b4e47c3684f936ed6b6c89d3dd2cd5b9 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Mar 11 19:13:20 2016 +0530 gpio: of: Scan available child node for gpio-hog Look for child node which are available when iterating for gpio hog node for request/set GPIO initial configuration during OF gpio chip registration. All it really does is make it possible to set status = "disabled"; in the hog nodes, and then they will not be applied. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib-of.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 28e460b02c66116354ced05b570503d252b996e9 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:33 2016 -0400 rtl8xxxu: Adjust AFE crystal value on 8192eu Adjust AFE before enabling PLL on 8192eu, probably also needed for 8723bu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 39 ++++++++++++++++++++++ .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 4 +++ 2 files changed, 43 insertions(+) commit f991f4e9147b1b7c9546c08f80d8d8f0aa53df2e Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:32 2016 -0400 rtl8xxxu: Implement IQK calibration for 8192eu 8192eu has it's own IQK calibration procedure, and notably uses undocumented RF register 0x56 in the process. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 608 ++++++++++++++++++++- .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 1 + 2 files changed, 608 insertions(+), 1 deletion(-) commit 70bc1e24d9e2df3002d714348ca600db83de4c64 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:31 2016 -0400 rtl8xxxu: Use proper register name for REG_PAD_CTRL1 Fixup another case where the hard coded register value was used instead of the name. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b052b7fc7d25f7c783ffcd87c42b767f6c166724 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:30 2016 -0400 rtl8xxxu: Implement 8192eu device specific quirks Set REG_QUEUE_CTRL and REG_ACLK_MON for 8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 14 ++++++++++++++ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 1 + 2 files changed, 15 insertions(+) commit e1394fe5f98638ac0231063245614bb20e94e57f Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:29 2016 -0400 rtl8xxxu: Fix LDPC RX hang issue on 8192eu Implement workaround for LDPC RX hands on 8192eu. This was inspired by workaround found in the 8192eu vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 3021e51f2b2f62a2fa6f49c2d14d103b5a8c331c Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:28 2016 -0400 rtl8xxxu: Set REG_USB_HRPWM for 8192eu The vendor driver set register 0xfe58 REG_USB_HWPWM in it's init sequence for 8192eu. Do the same here. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 ++ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 1 + 2 files changed, 3 insertions(+) commit 57e5e2e650fb7ad1fe32e1c5e5b1bd01faa238fc Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:27 2016 -0400 rtl8xxxu: Set correct interrupt masking registers on 8192eu Set HIMR[01] on 8192eu instead of HISR/HIMR. It's not obvious this really matters for USB devices, but this matches the register writes performed by the vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 8a59485c8ee911e77ace1622520976321aaf3820 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:26 2016 -0400 rtl8xxxu: Handle XTAL value setting on 8192eu Set REG_AFE_XTAL_CTRL on 8192eu to the vendor driver value, and do not skip setting REG_MAX_AGGR_NUM on 8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 2949b9ee77b819b90d23096ef44744244283e630 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:25 2016 -0400 rtl8xxxu: Provide special handling when writing RF regs on 8192eu The 8192eu requires clearing/restoring bit 17 in REG_FPGA0_POWER_SAVE before/after writing RF registers. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit 444004bd134990456329267ac6365e71d73aeb85 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:24 2016 -0400 rtl8xxxu: Handle BB init for 8192eu The 8192eu does not use REG_AFE_PLL_CTRL in it's BB init sequence, so provide device specific handling. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 5 +++++ 1 file changed, 5 insertions(+) commit 9e24772ae222a867f98efc5502a5a01b3916db83 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:23 2016 -0400 rtl8xxxu: Correctly parse 8192eu efuse The 8192eu efuse only has power data for path A and B. It follows the same layout as 8723bu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 40 ++++++++++++++++++++++++ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 38 ++++++++++------------ 2 files changed, 56 insertions(+), 22 deletions(-) commit abd71bdb94c3c4cd6bf4837ce568cb189fdb7f7a Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:22 2016 -0400 rtl8xxxu: Pick PHY init table based on chip version first Pick PHY init table based on device before distinguishing between 1T/2T/high PA tables. The latter is only currently used for 8188cu/8192cu/8188ru. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit ae14c5d20dc9e5e66681a7e3045b61eb9348d9f4 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:21 2016 -0400 rtl8xxxu: Add 8192eu PHY init table The 8192eu also requires it's own PHY init table. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 140 +++++++++++++++++++++++ 1 file changed, 140 insertions(+) commit e293278debe7c1d3112aa8ec10373d73f171d75d Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:20 2016 -0400 rtl8xxxu: Add 8192eu AGC tables A device specific AGC table is required for the 8192eu as well. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 147 ++++++++++++++++++++++- 1 file changed, 146 insertions(+), 1 deletion(-) commit 19102f8419342a3cdd0efb25539a268f2d095319 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:19 2016 -0400 rtl8xxxu: Add radio init tables for 8192eu Add the required radio init tables for 8192eu devices. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 154 +++++++++++++++++++++++ 1 file changed, 154 insertions(+) commit 80805aa5f33e315df23b6420c64f96a28dfcbb9a Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:18 2016 -0400 rtl8xxxu: Set TX page boundaries for 8192eu The 8192eu also has it's own TRXFF boundary value to set. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 7 ++++++- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) commit 2ca73dc786c4ffb9c618e7b868d69d9faf5a755d Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:17 2016 -0400 rtl8xxxu: Do not mess with AFE_XTAL_CTRL on 8192eu To match the vendor driver, do not mess with AFE_XTAL_CTRL on 8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c606e662a5c8e9caa7183e7d88b7c24dadb3adea Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Apr 7 14:19:16 2016 -0400 rtl8xxxu: Add MAC init table for 8192eu The 8192eu requires a different MAC init table. Add the missing table and specify the table to use in the fileops structure. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 45 ++++++++++++++++++++---- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 + 2 files changed, 40 insertions(+), 6 deletions(-) commit 860b8d4b3f893c97f905b978ecf62f48816dc5de Author: Taeung Song <treeze.taeung@gmail.com> Date: Thu Apr 14 16:53:19 2016 +0900 perf config: Make show_config() use perf_config_set Currently show_config() has a problem when user and system config files have the same config variables i.e.: # cat ~/.perfconfig [top] children = false When $(sysconfdir) is /usr/local/etc # cat /usr/local/etc/perfconfig [top] children = true Before: # perf config --user --list top.children=false # perf config --system --list top.children=true # perf config --list top.children=true top.children=false Because perf_config() can call show_config() each the config file (user and system). Fix it. After: # perf config --user --list top.children=false # perf config --system --list top.children=true # perf config --list top.children=false Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1460620401-23430-3-git-send-email-treeze.taeung@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-config.c | 39 ++++++++++++++++++++++++++++++++------- 1 file changed, 32 insertions(+), 7 deletions(-) commit 1951384cb16e50c40cc714bbaaae3cee364ba763 Author: Robert Jarzmik <robert.jarzmik@free.fr> Date: Sun Apr 10 21:39:51 2016 +0200 pinctrl: pxa: add pxa25x architecture Add the pxa25x architecture, which is a pxa2xx with 85 pins. The registers spacing, and pins logic is common to pxa2xx, only the pins and their alternate function are specific to pxa25x. Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pxa/Kconfig | 10 +- drivers/pinctrl/pxa/Makefile | 1 + drivers/pinctrl/pxa/pinctrl-pxa25x.c | 274 +++++++++++++++++++++++++++++++++++ 3 files changed, 284 insertions(+), 1 deletion(-) commit 4dd4dd1d21206cd05f5da031d709e9de8567957f Author: Alexander Stein <alexanders83@web.de> Date: Wed Feb 24 20:54:32 2016 +0100 gpio: tegra: Allow compile test Allow compile testing this driver by adding a new config option which is enabled by default and depends on the old symbol or COMPILE_TEST. Signed-off-by: Alexander Stein <alexanders83@web.de> drivers/gpio/Kconfig | 5 +++++ drivers/gpio/Makefile | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) commit 1e4a80640338924b9f9fd7a121ac31d08134410a Author: Alexander Stein <alexanders83@web.de> Date: Wed Feb 24 22:05:19 2016 +0100 gpio: gpiolib-of: Allow compile testing Lower dependencies for compile testing. Signed-off-by: Alexander Stein <alexanders83@web.de> drivers/gpio/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 190ea4344bc3fb97c40befd1653a92e9a59fe0f7 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sun Apr 10 15:07:23 2016 +0200 gpio: wm8994: use the new open drain callback The WM8994 GPIOs clearly have a dedicated open drain control register. Implement support for controlling this from GPIO descriptor tables or other hardware descriptions such as device tree by implementing the .set_single_ended() callback. Before this patch, lines requesting open drain will just be switched to input mode by the framework, thus emulating open drain. But the hardware can do the real thing, so let's support that. As part of this, rename the debugfs string for output mode from "CMOS" to "push-pull" because it is the term used in the framework to signify a tomem-pole CMOS output. Cc: patches@opensource.wolfsonmicro.com Cc: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-wm8994.c | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) commit 51c27da19d3dbf3219afb225e1626e193c5e1c72 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sun Apr 10 14:52:33 2016 +0200 gpio: wm831x: use the new open drain callback The WM831x GPIOs clearly have a dedicated open drain control register. Implement support for controlling this from GPIO descriptor tables or other hardware descriptions such as device tree by implementing the .set_single_ended() callback. Before this patch, lines requesting open drain will just be switched to input mode by the framework, thus emulating open drain. But the hardware can do the real thing, so let's support that. As part of this, rename the debugfs string for output mode from "CMOS" to "push-pull" because it is the term used in the framework to signify a tomem-pole CMOS output. Cc: patches@opensource.wolfsonmicro.com Cc: Mark Brown <broonie@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-wm831x.c | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) commit 640b9135c888f02afd058c213303ffbd10d3908d Author: Linus Walleij <linus.walleij@linaro.org> Date: Sun Apr 10 12:26:08 2016 +0200 gpio: vx855: use the new open drain callback The vx855 driver clearly states it has three groups of lines: GPI, GPO and GPIO. The GPO are assumedly push-pull. The GPIO are implicit open drain, but if the GPIO subsystem ask for them to be explicitly open drain (i.e. set the flag on a machine table that we want open drain) it will currently misbehave: it will switch the GPIOs to input mode (emulate open drain). Instead: indicate in the .set_single_ended() callback that we support open drain and open drain only. Cc: Daniel Drake <drake@endlessm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-vx855.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 811a1882b12bbbcbd447ad8c4d16d170e196c58f Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat Apr 9 21:53:39 2016 +0200 gpio: menz127: use the new open drain callback The menz127 driver tries to support open drain by detecting it at request time. However: without the new callbacks from the gpiolib it is not really working: the core will still just emulate the open drain mode by switching the line to an input. By adding a hook into the new .set_single_ended() call rather than trying to autodetect at request() time, proper open drain can be supported. Cc: Andreas Werner <andy@wernerandy.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-menz127.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) commit f90c6bdb690bb12f3dbe8eaa5650a9ce952d0290 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat Apr 9 16:11:37 2016 +0200 gpio: f7188x: use the new open drain callback The F7188x chips supports setting the pins in open drain mode. Activate the new .set_single_ended() callback. Cc: Peter Hung <hpeter@gmail.com> Cc: Andreas Bofjall <andreas@gazonk.org> Cc: Simon Guinot <simon.guinot@sequanux.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-f7188x.c | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) commit 148c864260dad94dd037d342679cd62f664a9b21 Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat Apr 9 15:59:41 2016 +0200 gpio: f7188x: use BIT() macro Align to how we handle bitmasks in most drivers in the subsystem: using the BIT(n) macro over (1 << n). Cc: Peter Hung <hpeter@gmail.com> Cc: Andreas Bofjall <andreas@gazonk.org> Cc: Simon Guinot <simon.guinot@sequanux.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-f7188x.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit 04b8695617fe6efeba5ca20e8be3a5c1879fd74a Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat Apr 9 13:13:36 2016 +0200 gpio: sx150x: use the new open drain callback One variant of the SX150X GPIO chip supports setting the pins in open drain mode. This is currently available to set from platform data, but completely unused in the kernel. Activate the new .set_single_ended() callback so users can set this up from e.g. device tree or board files using the new GPIO descriptors. As part of this, delete the platform data open drain setting method. Cc: Wei Chen <Wei.Chen@csr.com> Cc: Peter Rosin <peda@axentia.se> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-sx150x.c | 41 +++++++++++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 14 deletions(-) commit d17322feecf80152303426dd724577025d1fbd7e Author: Linus Walleij <linus.walleij@linaro.org> Date: Sat Apr 9 10:52:26 2016 +0200 gpio: sx150x: move platform data into driver The sx150x has some platform data definition in <linux/i2c/sx150x.h> but this file is only included from the driver in the whole kernel so move its contents into the driver. Cc: Wei Chen <Wei.Chen@csr.com> Cc: Peter Rosin <peda@axentia.se> Acked-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-sx150x.c | 60 ++++++++++++++++++++++++++++++++- include/linux/i2c/sx150x.h | 82 ---------------------------------------------- 2 files changed, 59 insertions(+), 83 deletions(-) commit f30e49f1291bc309865f88126005d526421d7e3a Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri Apr 8 14:13:53 2016 +0200 gpio: tps65218: use the new open drain callback The TPS65218 supports open drain mode on its three pins, with one of them configurable also as push-pull. Use the new .set_single_ended() callback to set this up properly from the core, so the core actually see it can drive the pin(s) as open drain, and does not attempt to emulate open drain by switching the pin to an input. Acked-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tps65218.c | 45 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 35 insertions(+), 10 deletions(-) commit 3d7d0c85e41afb5a05e98b3a8a72c38357f02594 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Thu Apr 14 14:39:02 2016 +0300 drm/i915: Use fw_domains_put_with_fifo() on HSW HSW still has the wake FIFO, so let's check it. Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Deepak S <deepak.s@linux.intel.com> Fixes: 05a2fb157e44 ("drm/i915: Consolidate forcewake code") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460633942-24013-1-git-send-email-ville.syrjala@linux.intel.com Cc: stable@vger.kernel.org Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> drivers/gpu/drm/i915/intel_uncore.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 26e6aaafc8a1e862437003d6e06ba748e7177ea8 Author: Rhyland Klein <rklein@nvidia.com> Date: Thu Apr 7 17:37:08 2016 -0400 pinctrl: tegra: clear park bit for all pins Parking bits might not be cleared by the bootloader properly (if for instance it doesn't use the device configured by that pin). Clear the park bits for all the pins during pinctrl probe. This is present on T210 platforms but not earlier ones, so for earlier generations, set parked_reg = -1 to disable. The park bit is used to prevent glitching when reprogramming pinctrl registers. Based on work by: Shravani Dingari <shravanid@nvidia.com> Signed-off-by: Rhyland Klein <rklein@nvidia.com> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/tegra/pinctrl-tegra.c | 18 ++++++++++++++++++ drivers/pinctrl/tegra/pinctrl-tegra.h | 6 ++++++ drivers/pinctrl/tegra/pinctrl-tegra114.c | 2 ++ drivers/pinctrl/tegra/pinctrl-tegra124.c | 2 ++ drivers/pinctrl/tegra/pinctrl-tegra20.c | 3 +++ drivers/pinctrl/tegra/pinctrl-tegra210.c | 4 ++++ drivers/pinctrl/tegra/pinctrl-tegra30.c | 2 ++ 7 files changed, 37 insertions(+) commit 20105ca1240c3d3ac8cc79bf195022e5e5c1c3fb Author: Taeung Song <treeze.taeung@gmail.com> Date: Thu Apr 14 16:53:18 2016 +0900 perf config: Introduce perf_config_set class This infrastructure code was designed for upcoming features of 'perf config'. That collect config key-value pairs from user and system config files (i.e. user wide ~/.perfconfig and system wide $(sysconfdir)/perfconfig) to manage perf's configs. Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1460620401-23430-2-git-send-email-treeze.taeung@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/config.c | 173 +++++++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/config.h | 26 +++++++ 2 files changed, 199 insertions(+) commit ecfd7a9c044e98fc3da8937e652080bc5abe7918 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 13 08:21:07 2016 +0000 perf record: Add '--timestamp-filename' option to append timestamp to output file name This option appends current timestamp to the output file name. For example: # perf record -a --timestamp-filename ^C[ perf record: Woken up 1 times to write data ] [ perf record: Dump perf.data.2015122622265847 ] [ perf record: Captured and wrote 0.742 MB perf.data.<timestamp> (90 samples) ] # ls perf.data.201512262226584 The timestamp will be useful for identifying each perf.data after the 'perf record' support for generating multiple output files gets introduced. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460535673-159866-5-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 53 +++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 49 insertions(+), 4 deletions(-) commit c0bdc1c461dd5b2e492c0746708a3e0da6b13515 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 13 08:21:06 2016 +0000 perf record: Turns auxtrace_snapshot_enable into 3 states auxtrace_snapshot_enable has only two states (0/1). Turns it into a triple states enum so SIGUSR2 handler can safely do other works without triggering auxtrace snapshot. Signed-off-by: Wang Nan <wangnan0@huawei.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460535673-159866-4-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 59 +++++++++++++++++++++++++++++++++++++-------- 1 file changed, 49 insertions(+), 10 deletions(-) commit 040f9915e99e604688c2880e0b1e5b59dbfefa54 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 13 08:21:05 2016 +0000 perf data: Add perf_data_file__switch() helper perf_data_file__switch() closes current output file, renames it, then open a new one to continue recording. It will be used by 'perf record' to split output into multiple perf.data files. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460535673-159866-3-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/data.c | 41 +++++++++++++++++++++++++++++++++++++++++ tools/perf/util/data.h | 11 ++++++++++- 2 files changed, 51 insertions(+), 1 deletion(-) commit b26dc73018d2e3a68cad0cf0bad902a8637f9bdf Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 13 08:21:04 2016 +0000 perf session: Make ordered_events reusable ordered_events__free() leaves linked lists and timestamps not cleared, so unable to be reused after ordered_events__free(). Which is inconvenient after 'perf record' supports generating multiple perf.data output and process build-ids for each of them. Use ordered_events__reinit() for this. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460535673-159866-2-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Split from larger patch ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/session.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 4532f642974d871f9a50e9a09bc482eaed5394f6 Author: Wang Nan <wangnan0@huawei.com> Date: Wed Apr 13 08:21:04 2016 +0000 perf ordered_events: Introduce reinit() 'perf record' will use this when outputting multiple perf.data files. Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460535673-159866-2-git-send-email-wangnan0@huawei.com Signed-off-by: He Kuang <hekuang@huawei.com> [ Split from larger patch ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/ordered-events.c | 9 +++++++++ tools/perf/util/ordered-events.h | 1 + 2 files changed, 10 insertions(+) commit ea8dc3cefba0a0decaedc710b218a6ceffe0194a Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 13 12:10:19 2016 -0300 perf trace: Move eventfd beautifiers to trace/beauty/ directory To better organize all these beautifiers. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-zrw5zz7cnrs44o5osouyutvt@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 41 +-------------------------------------- tools/perf/trace/beauty/eventfd.c | 38 ++++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 40 deletions(-) commit df4cb1678e2ea91eb66665f00c4a43d898a12697 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 13 12:05:44 2016 -0300 perf trace: Move mmap beautifiers to trace/beauty/ directory To better organize all these beautifiers. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-zbr27mdy9ssdhux3ib2nfa7j@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 159 +---------------------------------------- tools/perf/trace/beauty/mmap.c | 158 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 159 insertions(+), 158 deletions(-) commit a355a61e43484ac02553b34b5f84ee84ca765fd6 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 13 11:55:18 2016 -0300 perf trace: Add getrandom beautifier related defines for older systems Were the detached tarball (make perf-tar-src-pkg) build was failing because those definitions aren't available in the system headers. On RHEL7, for instance: builtin-trace.c: In function ‘syscall_arg__scnprintf_getrandom_flags’: builtin-trace.c:1113:14: error: ‘GRND_RANDOM’ undeclared (first use in this function) P_FLAG(RANDOM); ^ builtin-trace.c:1114:14: error: ‘GRND_NONBLOCK’ undeclared (first use in this function) P_FLAG(NONBLOCK); ^ Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-r8496g24a3kbqynvk6617b0e@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 6fb35b9515c6300cb25022ac74f5f5617a349e18 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 13 11:50:23 2016 -0300 perf trace: Add seccomp beautifier related defines for older systems Were the detached tarball (make perf-tar-src-pkg) build was failing because those definitions aren't available in the system headers. On RHEL7, for instance: builtin-trace.c: In function ‘syscall_arg__scnprintf_seccomp_op’: builtin-trace.c:1069:7: error: ‘SECCOMP_SET_MODE_STRICT’ undeclared (first use in this function) P_SECCOMP_SET_MODE_OP(STRICT); ^ builtin-trace.c:1069:7: note: each undeclared identifier is reported only once for each function it appears in builtin-trace.c:1070:7: error: ‘SECCOMP_SET_MODE_FILTER’ undeclared (first use in this function) P_SECCOMP_SET_MODE_OP(FILTER); ^ builtin-trace.c: In function ‘syscall_arg__scnprintf_seccomp_flags’: builtin-trace.c:1091:14: error: ‘SECCOMP_FILTER_FLAG_TSYNC’ undeclared (first use in this function) P_FLAG(TSYNC); ^ Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-4f8dzzwd7g6l5dzz693u7kul@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit e30e251acc980d515fe3d3a8dfce37abeb79ed42 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:58 2016 +0300 drm/i915: Split gen8_gt_irq_handler into ack+handle As we did on VLV, split the gt irq handling to ack and handler phases on CHV. Leave the BDW+ codepath mostly intact for now. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-13-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 79 ++++++++++++++++++++++++----------------- 1 file changed, 47 insertions(+), 32 deletions(-) commit 261e40b8b761331e5d97be439f0a0f219469880b Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:57 2016 +0300 drm/i915: Eliminate passing dev+dev_priv to {snb,ilk}_gt_irq_handler() It looks silly to pass both dev and dev_priv to the snb/ilk gt irq handlers. Just pass dev_priv. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-12-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) commit 528948745f6f52f36839b76beeab0632a9f16471 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:56 2016 +0300 drm/i915: Move gt/pm irq handling out from irq disabled section on VLV No need to actually handle the GT/PM interrupt while we have interrupt sources disabled. Move the actual processing to happen after we've restored VLV_IER and master interrupt enable. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-11-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 2ecb8ca4a0190eb27c16e4484a0719cd692bc633 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:55 2016 +0300 drm/i915: Split VLV/CVH PIPESTAT handling into ack+handler Minimize the amount of stuff we do with interrupt sources disabled by splitting the PIPESTAT irq handling into ack+handler phases. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-10-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) commit 1ae3c34c09b1c5c01dc22db4bf5af0efed4752ee Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:54 2016 +0300 drm/i915: Split PORT_HOTPLUG_STAT ack out from i9xx_hpd_irq_handler() Split the VLV/CHV hoplug irq handling to ack and handler phases. This way we can move the actual irq handling outside the section where we have disabled the interrupt sources. For now, we leave things as is for pre-VLV GMCH platforms, but eventually they could get the same treatment. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-9-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 47 ++++++++++++++++++++++++++--------------- 1 file changed, 30 insertions(+), 17 deletions(-) commit 6e814800a232afdee3f8abf5b9d49829015c67a7 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:53 2016 +0300 drm/i915: Move variables to narrower scope in VLV/CHV irq handlers Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-8-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1e1cace942ef67d36828daa2d42559f02271897b Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:52 2016 +0300 drm/i915: Eliminate loop from VLV irq handler Now that we've dealt with the races in clearing IIR bits via VLV_IER and the master interrupt enable, we can go ahead aliminate the loop from the VLV interrupt handler. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-7-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit a5e485a95c9c4cdd93b4c6dc53eee3bd1e50de11 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:51 2016 +0300 drm/i915: Clear VLV_IER around irq processing On VLV/CHV the master interrupt enable bit only affects GT/PM interrupts. Display interrupts are not affected by the master irq control. Also it seems that the CPU interrupt will only be generated when the combined result of all GT/PM/display interrupts has a 0->1 edge. We already use the master interrupt enable bit to make sure GT/PM interrupt can generate such an edge if we don't end up clearing all IIR bits. We must do the same for display interrupts, and for that we can simply clear out VLV_IER, and restore after we've acked all the interrupts we are about to process. So with both master interrupt enable and VLV_IER cleared out, we will guarantee that there will be a 0->1 edge if any IIR bits are still set at the end, and thus another CPU interrupt will be generated. Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Fixes: 579de73b048a ("drm/i915: Exit cherryview_irq_handler() after one pass") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) commit 4a0a0202b0238b652563429c5e13825ec5f83ce4 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:50 2016 +0300 drm/i915: Clear VLV_MASTER_IER around irq processing Like on CHV, let's clear out the master irq enable bit when we ack GT/PM interrupts. This will allow GT/PM interrupts to re-raise the CPU interrupt if we fail to clear all the bits from the IIR(s). Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit 7ce4d1f2730f2bd4320425dd376913c4a12bd3b2 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:49 2016 +0300 drm/i915: Clear VLV_IIR after PIPESTAT On VLV/CHV VLV_IIR is not double double buffered, and it doesn't detect edges from PIPESTAT & co. like it does on gen4. Instead it just directly latches the level from PIPESTAT & co. That means we must clear VLV_IIR after PIPESTAT & co. or else we'll get a spurious bit in VLV_IIR every single time. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 36 +++++++++++++++++++++--------------- 1 file changed, 21 insertions(+), 15 deletions(-) commit 34c7b8a7b8b5a2075b37654aa2d1a46b1cee9ef2 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:48 2016 +0300 drm/i915: Set up VLV_MASTER_IER consistently We're lacking VLV_MASTER_IER setup from valleyview_irq_preinstall(), so add it there. Also cargo cult in some POSTING_READ()s to match the other platforms. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 5 +++++ 1 file changed, 5 insertions(+) commit e5328c43d46e153ca135a0371fbd2295ad037fa5 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:19:47 2016 +0300 drm/i915: Use GEN8_MASTER_IRQ_CONTROL consistently Use GEN8_MASTER_IRQ_CONTROL instead of DE_MASTER_IRQ_CONTROL or MASTER_INTERRUPT_ENABLE with the GEN8_MASTER_IRQ register. They're all bit 31 so there's no actual bug here, but let's be consistent which name we use for the bit. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460571598-24452-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_irq.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 297b32ec7e9a20749cf72e95c648e69ebf9a4d31 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 13 21:09:30 2016 +0300 drm/i915: Ignore GTFIFODBG FIFO free entry fields on CHV On CHV GTFIFODBG has some read-only bits to indicate the number of free FIFO entries. Ignore these when checking to see if any of the sticky error bits are set. This gets rid of these during device resume: [drm:cherryview_enable_rps] GT fifo had a previous error 1080000 While at it, move the assignments out of the if(). Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460570970-14073-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_reg.h | 2 ++ drivers/gpu/drm/i915/intel_pm.c | 9 ++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) commit 4a91c45ea57c4974c797b89dfed19e946a774787 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Thu Apr 14 12:36:16 2016 +0300 leds: tca6507: silence an uninitialized variable warning If choose_times() returns -EINVAL that means "c1" and "c2" haven't been initialized. I've added a check for that. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/leds-tca6507.c | 2 ++ 1 file changed, 2 insertions(+) commit 8a9d088f66f84d7317b4adc64d3d3114f1ee8583 Author: David Lechner <david@lechnology.com> Date: Thu Mar 24 18:51:30 2016 -0500 ARM: davinci: clk: add set_parent callback for mux clocks Introduce a set_parent callback that will be used for mux clocks, such as the USB PHY muxes and the async3 clock domain mux. Signed-off-by: David Lechner <david@lechnology.com> [nsekhar@ti.com: checkpatch fixes] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/clock.c | 19 ++++++++++++++++++- arch/arm/mach-davinci/clock.h | 1 + 2 files changed, 19 insertions(+), 1 deletion(-) commit 86cad16087a8cdad88c1ac124afde4de01500c21 Author: David Lechner <david@lechnology.com> Date: Thu Mar 24 18:51:28 2016 -0500 ARM: davinci: da8xx: move usb code to new file We will be adding more da8xx-specific code for phy and clocks, so it will be better to have this in a separate file. This way we don't have a bunch of #ifdefs for all of the da8xx stuff. While at it, fix some checkpatch warnings coming from existing code. Signed-off-by: David Lechner <david@lechnology.com> [nsekhar@ti.com: typo and checkpatch fixes] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/Makefile | 4 +- arch/arm/mach-davinci/usb-da8xx.c | 107 ++++++++++++++++++++++++++++++++++++++ arch/arm/mach-davinci/usb.c | 73 -------------------------- 3 files changed, 109 insertions(+), 75 deletions(-) commit 0ccdacf694e9e5b77601ac872f38ffba96dc5dac Author: Peter Antoine <peter.antoine@intel.com> Date: Wed Apr 13 15:03:25 2016 +0100 drm/i915/mocs: Program MOCS for all engines on init Allow for the MOCS to be programmed for all engines. Currently we program the MOCS when the first render batch goes through. This works on most platforms but fails on platforms that do not run a render batch early, i.e. headless servers. The patch now programs all initialised engines on init and the RCS is programmed again within the initial batch. This is done for predictable consistency with regards to the hardware context. Hardware context loading sets the values of the MOCS for RCS and L3CC. Programming them from within the batch makes sure that the render context is valid, no matter what the previous state of the saved-context was. v2: posted correct version to the mailing list. v3: moved programming to within engine->init_hw() (Chris Wilson) v4: code formatting and white-space changes. (Chris Wilson) Testcase: igt/gem_mocs_settings Signed-off-by: Peter Antoine <peter.antoine@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460556205-6644-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem.c | 3 + drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_mocs.c | 155 ++++++++++++++++++++++++++++---------- drivers/gpu/drm/i915/intel_mocs.h | 2 + 4 files changed, 122 insertions(+), 40 deletions(-) commit aa9b78104fe3210758fa9e6c644e9a108d371e8b Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:15 2016 +0100 drm/i915: Late request cancellations are harmful Conceptually, each request is a record of a hardware transaction - we build up a list of pending commands and then either commit them to hardware, or cancel them. However, whilst building up the list of pending commands, we may modify state outside of the request and make references to the pending request. If we do so and then cancel that request, external objects then point to the deleted request leading to both graphical and memory corruption. The easiest example is to consider object/VMA tracking. When we mark an object as active in a request, we store a pointer to this, the most recent request, in the object. Then we want to free that object, we wait for the most recent request to be idle before proceeding (otherwise the hardware will write to pages now owned by the system, or we will attempt to read from those pages before the hardware is finished writing). If the request was cancelled instead, that wait completes immediately. As a result, all requests must be committed and not cancelled if the external state is unknown. All that remains of i915_gem_request_cancel() users are just a couple of extremely unlikely allocation failures, so remove the API entirely. A consequence of committing all incomplete requests is that we generate excess breadcrumbs and fill the ring much more often with dummy work. We have completely undone the outstanding_last_seqno optimisation. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93907 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Cc: stable@vger.kernel.org Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-16-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_drv.h | 2 -- drivers/gpu/drm/i915/i915_gem.c | 50 ++++++++++++------------------ drivers/gpu/drm/i915/i915_gem_execbuffer.c | 15 +++------ drivers/gpu/drm/i915/intel_display.c | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 4 +-- drivers/gpu/drm/i915/intel_overlay.c | 8 ++--- 6 files changed, 30 insertions(+), 51 deletions(-) commit fcb5106d665879edbc1ebb6e1f1a67695954b81d Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:14 2016 +0100 drm/i915: Reorganise legacy context switch to cope with late failure After mi_set_context() succeeds, we need to update the state of the engine's last_context. This ensures that we hold a pin on the context whilst the hardware may write to it. However, since we didn't complete the post-switch setup of the context, we need to force the subsequent use of the same context to complete the setup (which means updating should_skip_switch()). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-15-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_context.c | 141 +++++++++++++++----------------- 1 file changed, 67 insertions(+), 74 deletions(-) commit e1a8daa2d159776f01d7129fae053d2d08d6c6df Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:13 2016 +0100 drm/i915: Split out !RCS legacy context switching Having the !RCS legacy context switch threaded through the RCS switching code makes it much harder to follow and understand. In the next patch, I want to fix a bug handling the incomplete switch, this is made much simpler if we segregate the two paths now. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Reviewed-by: Daniel Vetter <daniel@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-14-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_context.c | 74 +++++++++++++++++---------------- 1 file changed, 38 insertions(+), 36 deletions(-) commit 349f2ccff94e835210b253ec9bef1d97d6afb312 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:12 2016 +0100 drm/i915: Move the mb() following release-mmap into release-mmap As paranoia, we want to ensure that the CPU's PTEs have been revoked for the object before we return from i915_gem_release_mmap(). This allows us to rely on there being no outstanding memory accesses from userspace and guarantees serialisation of the code against concurrent access just by calling i915_gem_release_mmap(). v2: Reduce the mb() into a wmb() following the revoke. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Cc: "Goel, Akash" <akash.goel@intel.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-13-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) commit a687a43a48f0f91ba37dce5a14b467258ed6f035 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:11 2016 +0100 drm/i915: Force ringbuffers to not be at offset 0 For reasons unknown Sandybridge GT1 (at least) will eventually hang when it encounters a ring wraparound at offset 0. The test case that reproduces the bug reliably forces a large number of interrupted context switches, thereby causing very frequent ring wraparounds, but there are similar bug reports in the wild with the same symptoms, seqno writes stop just before the wrap and the ringbuffer at address 0. It is also timing crucial, but adding various delays hasn't helped pinpoint where the window lies. Whether the fault is restricted to the ringbuffer itself or the GTT addressing is unclear, but moving the ringbuffer fixes all the hangs I have been able to reproduce. References: (e.g.) https://bugs.freedesktop.org/show_bug.cgi?id=93262 Testcase: igt/gem_exec_whisper/render-contexts-interruptible #snb-gt1 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: stable@vger.kernel.org Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-12-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit e9135c4f08d9acb0f3da3ad2643b669dee3217c2 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:10 2016 +0100 drm/i915: Prevent machine death on Ivybridge context switching Two concurrent writes into the same register cacheline has the chance of killing the machine on Ivybridge and other gen7. This includes LRI emitted from the command parser. The MI_SET_CONTEXT itself serves as serialising barrier and prevents the pair of register writes in the first packet from triggering the fault. However, if a second switch-context immediately occurs then we may have two adjacent blocks of LRI to the same registers which may then trigger the hang. To counteract this we need to insert a delay after the second register write using SRM. This is easiest to reproduce with something like igt/gem_ctx_switch/interruptible that triggers back-to-back context switches (with no operations in between them in the command stream, which requires the execbuf operation to be interrupted after the MI_SET_CONTEXT) but can be observed sporadically elsewhere when running interruptible igt. No reports from the wild though, so it must be of low enough frequency that no one has correlated the random machine freezes with i915.ko The issue was introduced with commit 2c550183476dfa25641309ae9a28d30feed14379 [v3.19] Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Dec 16 10:02:27 2014 +0000 drm/i915: Disable PSMI sleep messages on all rings around context switches Testcase: igt/gem_ctx_switch/render-interruptible #ivb Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: stable@vger.kernel.org Reviewed-by: Daniel Vetter <daniel@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-11-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_context.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 804e59a8300b6943cad60f5032f954bd9c4e87e2 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:09 2016 +0100 drm/i915: Suppress error message when GPU resets are disabled If we do not have lowlevel support for reseting the GPU, or if the user has explicitly disabled reseting the device, the failure is expected. Since it is an expected failure, we should be using a lower priority message than *ERROR*, perhaps NOTICE. In the absence of DRM_NOTICE, just emit the expected failure as a DEBUG message. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-10-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_drv.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit f4457ae71fd6c3bc9ab979839258411a34baa7f6 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:08 2016 +0100 drm/i915: Prevent leaking of -EIO from i915_wait_request() Reporting -EIO from i915_wait_request() has proven very troublematic over the years, with numerous hard-to-reproduce bugs cropping up in the corner case of where a reset occurs and the code wasn't expecting such an error. If the we reset the GPU or have detected a hang and wish to reset the GPU, the request is forcibly complete and the wait broken. Currently, we report either -EAGAIN or -EIO in order for the caller to retreat and restart the wait (if appropriate) after dropping and then reacquiring the struct_mutex (essential to allow the GPU reset to proceed). However, if we take the view that the request is complete (no further work will be done on it by the GPU because it is dead and soon to be reset), then we can proceed with the task at hand and then drop the struct_mutex allowing the reset to occur. This transfers the burden of checking whether it is safe to proceed to the caller, which in all but one instance it is safe - completely eliminating the source of all spurious -EIO. Of note, we only have two API entry points where we expect that userspace can observe an EIO. First is when submitting an execbuf, if the GPU is terminally wedged, then the operation cannot succeed and an -EIO is reported. Secondly, existing userspace uses the throttle ioctl to detect an already wedged GPU before starting using HW acceleration (or to confirm that the GPU is wedged after an error condition). So if the GPU is wedged when the user calls throttle, also report -EIO. v2: Split more carefully the change to i915_wait_request() and assorted ABI from the reset handling. v3: Add a couple of WARN_ON(EIO) to the interruptible modesetting code so that we don't start to leak EIO there in future (and break our hang resistant modesetting). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-9-git-send-email-chris@chris-wilson.co.uk Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_drv.h | 2 -- drivers/gpu/drm/i915/i915_gem.c | 44 ++++++++++++++++----------------- drivers/gpu/drm/i915/i915_gem_userptr.c | 6 ++--- drivers/gpu/drm/i915/intel_display.c | 13 +++++----- drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 3 +-- 6 files changed, 32 insertions(+), 38 deletions(-) commit f7e5838bb37d970e103b1d9af3928f0f471c8a48 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:07 2016 +0100 drm/i915: Simplify reset_counter handling during atomic modesetting Now that the reset_counter is stored on the request, we can rearrange the code to handle reading the counter versus waiting during the atomic modesetting for readibility (by deleting the hairiest of codes). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-8-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_display.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) commit 299259a3a965c0a831e01a5dbfe78729f126a420 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:06 2016 +0100 drm/i915: Store the reset counter when constructing a request As the request is only valid during the same global reset epoch, we can record the current reset_counter when constructing the request and reuse it when waiting upon that request in future. This removes a very hairy atomic check serialised by the struct_mutex at the time of waiting and allows us to transfer those waits to a central dispatcher for all waiters and all requests. PS: With per-engine resets, we obviously cannot assume a global reset epoch for the requests - a per-engine epoch makes the most sense. The challenge then is how to handle checking in the waiter for when to break the wait, as the fine-grained reset may also want to requeue the request (i.e. the assumption that just because the epoch changes the request is completed may be broken - or we just avoid breaking that assumption with the fine-grained resets). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-7-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_drv.h | 2 +- drivers/gpu/drm/i915/i915_gem.c | 40 +++++++++++---------------------- drivers/gpu/drm/i915/i915_gem_userptr.c | 5 +---- drivers/gpu/drm/i915/intel_display.c | 7 +----- drivers/gpu/drm/i915/intel_lrc.c | 7 ------ drivers/gpu/drm/i915/intel_ringbuffer.c | 6 ----- 6 files changed, 16 insertions(+), 51 deletions(-) commit d98c52cf4fa2bb7116a89f1132fc773b1cfa6436 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:05 2016 +0100 drm/i915: Tighten reset_counter for reset status In the reset_counter, we use two bits to track a GPU hang and reset. The low bit is a "reset-in-progress" flag that we set to signal when we need to break waiters in order for the recovery task to grab the mutex. As soon as the recovery task has the mutex, we can clear that flag (which we do by incrementing the reset_counter thereby incrementing the gobal reset epoch). By clearing that flag when the recovery task holds the struct_mutex, we can forgo a second flag that simply tells GEM to ignore the "reset-in-progress" flag. The second flag we store in the reset_counter is whether the reset failed and we consider the GPU terminally wedged. Whilst this flag is set, all access to the GPU (at least through GEM rather than direct mmio access) is verboten. PS: Fun is in store, as in the future we want to move from a global reset epoch to a per-engine reset engine with request recovery. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-6-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- drivers/gpu/drm/i915/i915_drv.c | 39 ++++++++++++++++++++++--------------- drivers/gpu/drm/i915/i915_drv.h | 3 --- drivers/gpu/drm/i915/i915_gem.c | 27 +++++++++---------------- drivers/gpu/drm/i915/i915_irq.c | 21 ++------------------ 5 files changed, 36 insertions(+), 58 deletions(-) commit 7f1847ebf48b2e5753691cc9e2a404c260383933 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:04 2016 +0100 drm/i915: Simplify checking of GPU reset_counter in display pageflips If we, when we store the reset_counter for the operation, we ensure that it is not in a wedged or in the middle of a reset, we can then assert that if any reset occurs the reset_counter must change. Later we can just compare the operation's reset epoch against the current counter to see if we need to abort the operation (to handle the hang). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-5-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_display.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit c19ae989b0245ed011fe403b7c4a216e35765c0f Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:03 2016 +0100 drm/i915: Hide the atomic_read(reset_counter) behind a helper This is principally a little bit of syntatic sugar to hide the atomic_read()s throughout the code to retrieve the current reset_counter. It also provides the other utility functions to check the reset state on the already read reset_counter, so that (in later patches) we can read it once and do multiple tests rather than risk the value changing between tests. v2: Be more strict on converting existing i915_reset_in_progress() over to the more verbose i915_reset_in_progress_or_wedged(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-4-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- drivers/gpu/drm/i915/i915_drv.h | 32 ++++++++++++++++++++++++++++---- drivers/gpu/drm/i915/i915_gem.c | 16 ++++++++-------- drivers/gpu/drm/i915/i915_irq.c | 2 +- drivers/gpu/drm/i915/intel_display.c | 18 +++++++++++------- drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 7 ++++--- 7 files changed, 55 insertions(+), 26 deletions(-) commit d501b1d2b19d87f216510fcf12b1b56b3c4545ef Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:02 2016 +0100 drm/i915: Add GEM debugging Kconfig option Currently there is a #define to enable extra BUG_ON for debugging requests and associated activities. I want to expand its use to cover all of GEM internals (so that we can saturate the code with asserts). We can add a Kconfig option to make it easier to enable - with the usual caveats of not enabling unless explicitly requested. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-3-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/Kconfig.debug | 12 ++++++++++++ drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gem.c | 12 +++++------- drivers/gpu/drm/i915/i915_gem.h | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 52 insertions(+), 7 deletions(-) commit e73bdd206ac53be5517dd1fa00c2528847b97f74 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:01 2016 +0100 drm/i915: Disentangle i915_drv.h includes Separate out the layers of includes (linux, drm, intel, i915) so that it is a little easier to order our definitions between our multiple reentrant headers. A couple of headers needed fixes to make them more standalone (forgotten includes, forward declarations etc). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_drv.h | 29 +++++++++++++++++------------ drivers/gpu/drm/i915/intel_guc.h | 2 ++ drivers/gpu/drm/i915/intel_lrc.h | 2 ++ 3 files changed, 21 insertions(+), 12 deletions(-) commit 0a793ad34f137f146119ec4a4a90694ccab77ea3 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Apr 13 17:35:00 2016 +0100 drm/i915: Force clean compilation with -Werror Our driver compiles clean (nowadays thanks to 0day) but for me, at least, it would be beneficial if the compiler threw an error rather than a warning when it found a piece of suspect code. (I use this to compile-check patch series and want to break on the first compiler error in order to fix the patch.) v2: Kick off a new "Debugging" submenu for i915.ko At this point, we applied it to the kernel and promptly kicked it out again as it broke buildbots (due to a compiler warning on 32bits): commit 908d759b210effb33d927a8cb6603a16448474e4 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue May 26 07:46:21 2015 +0200 Revert "drm/i915: Force clean compilation with -Werror" v3: Avoid enabling -Werror for allyesconfig/allmodconfig builds, using COMPILE_TEST as a suitable proxy suggested by Andrew Morton. (Damien) Only make the option available for EXPERT to reinforce that the option should not be casually enabled. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Jani Nikula <jani.nikula@intel.com> Cc: Damien Lespiau <damien.lespiau@intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1460565315-7748-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/Kconfig.debug | 17 +++++++++++++++++ drivers/gpu/drm/i915/Makefile | 2 ++ 2 files changed, 19 insertions(+) commit 5f1a7ab28e92e082dd8155961a0fe26db04c4f49 Author: Joel Stanley <joel@jms.id.au> Date: Tue Apr 12 14:02:28 2016 +0930 doc/devicetree: Add Aspeed and Tyan to vendor-prefixes ASPEED Technology Inc is a fabless IC-design company. Their web site is http://www.aspeedtech.com/. Tyan is a manufactuer of server and workstation platforms. Signed-off-by: Joel Stanley <joel@jms.id.au> Documentation/devicetree/bindings/vendor-prefixes.txt | 2 ++ 1 file changed, 2 insertions(+) commit c02e85a06e191f9888f3d561a39b1dc55e934b3b Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Apr 13 17:26:44 2016 +0300 drm/i915: Calculate edram size With gen9+ the edram capabilities are defined so that we can calculate the edram (ellc) size accordingly. Note that there are undefined combinations for some subset of edram capability bits. Return the closest size for undefined indexes. Even if we get it wrong with beginning of future gen enabling, the size information is currently only used for boot message and in debugfs entry. v2: Use function instead of hard to read macro (Daniel) v3: s/INTEL_INFO/INTEL_GEN (Matthew) Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Matthew Auld <matthew.auld@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460557604-7126-2-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/i915_reg.h | 3 +++ drivers/gpu/drm/i915/intel_uncore.c | 21 +++++++++++++++++---- 2 files changed, 20 insertions(+), 4 deletions(-) commit 3accaf7e734d691dd8494548da009a646426655c Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Apr 13 17:26:43 2016 +0300 drm/i915: Store and use edram capabilities Store the edram capabilities instead of only the size of edram. This is preparatory patch to allow edram size calculation based on edram capability bits for gen9+. With gen9 the edram is behind llc and is a separate entity. With hsw/bdw it was more of a victim cache for LLC so the name 'eLLC' might be warranted. Regardless, rename all mentions of eLLC to EDRAM to clear the confusion. v2: return bytes for edram size (Chris) s/eLLC/eDRAM in output if we are gen > 8 v3: rebase, INTEL_GEN (Chris) Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 5 +++-- drivers/gpu/drm/i915/i915_drv.h | 7 +++++-- drivers/gpu/drm/i915/i915_gem.c | 2 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 3 ++- drivers/gpu/drm/i915/i915_reg.h | 2 +- drivers/gpu/drm/i915/intel_uncore.c | 39 +++++++++++++++++++++++++------------ 6 files changed, 39 insertions(+), 19 deletions(-) commit 666fbcf5c21d8d8654b00b9c2e21a3caf070e9f8 Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Apr 13 17:26:42 2016 +0300 drm/i915: Don't program eLLC IDI hash mask for gen9+ For gen9 onwards, eDRAM is a true memory side cache. So there is no need to program idi hash mask as it is for eLLC only. v2: INTEL_GEN (Chris), s/has/hash (Matthew) Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Matthew Auld <matthew.auld@intel.com> drivers/gpu/drm/i915/i915_gem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b69e5c672d57fa300fef368106ab61c9214a760d Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 11 17:28:36 2016 +0200 i2c: octeon: Remove superfluous check in octeon_i2c_test_iflg Remove superfluous check and stray newline. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit c57db7098b72f406a4834b4b74268db54eae3fb7 Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 11 17:28:35 2016 +0200 i2c: octeon: Introduce helper functions for register access Add helper functions for control, data and status register access. This simplifies the code and makes the purpose of the register access clearer. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 56 +++++++++++++++++++++++------------------ 1 file changed, 31 insertions(+), 25 deletions(-) commit 9cb9480e473b910e226312574f997bec29f47ae4 Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 11 17:28:34 2016 +0200 i2c: octeon: Rename [read|write]_sw to reg_[read|write] Rename the [read|write]_sw functions to make it clearer they access the TWSI registers. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 52 ++++++++++++++++++++--------------------- 1 file changed, 26 insertions(+), 26 deletions(-) commit ebab87ab7a130c2930b85695e01fc2944fab85c5 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Mar 15 18:01:08 2016 +0100 drm: atmel-hlcdc: route DMA accesses through AHB interfaces In relation with the actuall bandwidth consumed on a DMA Source interface, choose the less used one for a created plane. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 6 +++- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.h | 1 + drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 43 +++++++++++++++++++++++-- 3 files changed, 47 insertions(+), 3 deletions(-) commit 5ac44c8b061653119456921e2e4aa78668b9f3d9 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Jan 5 18:27:49 2016 +0100 drm: atmel-hlcdc: check display mode validity in crtc->mode_fixup() Move the adjusted display mode check into ->mode_fixup(). Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) commit 17a8e03e7e97d3445ec60a16a234149ca51e96fb Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Jan 6 10:16:32 2016 +0100 drm: atmel-hlcdc: rework the output code to support drm bridges The current output code only supports connection to drm panels. First simplify the drm panel code, and then add support for external drm bridges. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 2 +- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 193 +++++++++++++---------- 2 files changed, 113 insertions(+), 82 deletions(-) commit aca63b766140f1abf14cbc22ccc5d7c7599b807c Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Wed Jan 6 11:14:15 2016 +0100 drm: atmel-hlcdc: move output mode selection in CRTC implementation In order to support multiple outputs we need to move the output mode selection to the CRTC object, so that the output validity check can be done against the drm_atomic_state. If the connectors selected by a specific mode setting are requiring incompatible bus format the atomic operation is aborted (->atomic_check() returns -EINVAL). In order to implement that, we need to define our own CRTC state and overload default ->reset(), ->atomic_duplicate_state() and ->atomic_destroy_state() functions. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 140 ++++++++++++++++++++++- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 3 + drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.h | 3 + drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 46 -------- 4 files changed, 142 insertions(+), 50 deletions(-) commit 79a3fc2d98111e371bd4c49e6f2de26ef8deb03f Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Jan 5 18:11:39 2016 +0100 drm: atmel-hlcdc: support extended timing ranges on sama5d4 and sama5d2 The display timings on old SoCs older than the sama5d4 are quite limited and prevent the use of many displays. Add support for extended timing ranges on sama5d2 and sama5d4. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 24 ++++++++++++++++++------ drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.h | 6 ++++++ 2 files changed, 24 insertions(+), 6 deletions(-) commit aab6d08c700ca4c9377e44c66debe89dc690a690 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Mon Jan 4 14:53:35 2016 +0100 drm: atmel-hlcdc: remove leftovers from atomic mode setting migration The ->dpms field is no longer used and can be removed. The same goes for the dummy ->mode_fixup() implementation which always returns true. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 12 ------------ 1 file changed, 12 deletions(-) commit abfc936eefa6ab1b21dd20fdb2d636410205e185 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Thu Dec 31 18:24:09 2015 +0100 drm: atmel-hlcdc: fix connector and encoder types The hlcdc IP keep the pixel stream in raw RGB mode, and does not provide any specific connector. Since DRM_MODE_CONNECTOR_RAW_RGB does not exist, use DRM_MODE_CONNECTOR_Unknown. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9b190610dcb9ed541539bc59d8877e941cf3a809 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Sat Oct 10 08:22:09 2015 +0200 drm: atmel-hlcdc: support asynchronous atomic commit operations drm_atomic_helper_commit() does not support asynchronous commits. Replace it by a specific commit function supporting these kind of requests. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 94 +++++++++++++++++++++++++++- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.h | 5 ++ 2 files changed, 98 insertions(+), 1 deletion(-) commit 1a7b37ca349bbdeb2f208a6a71a9925a716141f4 Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Sat Oct 10 07:55:39 2015 +0200 drm: atmel-hlcdc: add a ->cleanup_fb() operation Add a ->cleanup_fb() operation to avoid memory leaks when the atomic operation is interrupted after the ->prepare_fb() call. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Fixes 2389fc1 ("drm: atmel-hlcdc: Atomic mode-setting conversion") Reviewed-by: Nicolas Ferre <nicolas.ferre@atmel.com> Tested-by: Nicolas Ferre <nicolas.ferre@atmel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 52 +++++++++++++++++++++++-- 1 file changed, 49 insertions(+), 3 deletions(-) commit 9a7f2fc8408fdc0e3b417f670c17ed70d5d1c114 Author: David Lechner <david@lechnology.com> Date: Mon Feb 29 16:33:26 2016 -0600 ARM: davinci: use IRQCHIP_DECLARE for cp_intc Remove boilerplate code by using IRQCHIP_DECLARE macro. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/cp_intc.c | 3 +++ arch/arm/mach-davinci/da8xx-dt.c | 11 ----------- 2 files changed, 3 insertions(+), 11 deletions(-) commit 9fb69a27e938ca1079c16c213f5e8c8d90d6e2f3 Author: David Lechner <david@lechnology.com> Date: Mon Feb 29 16:33:25 2016 -0600 ARM: davinci: remove unused DA8XX_NUM_UARTS DA8X_NUM_UARTS not used in the code anywhere and should be determined by DT anyway. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/da8xx-dt.c | 2 -- 1 file changed, 2 deletions(-) commit 2f44a8d141bcfc866d7f3672563a7da735dacce6 Author: David Lechner <david@lechnology.com> Date: Mon Feb 29 16:33:24 2016 -0600 ARM: davinci: simplify call to of populate Take advantage of of_platoform_default_populate convience function. Signed-off-by: David Lechner <david@lechnology.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/da8xx-dt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 696c8b1282205caa5206264449f80ef756f14ef7 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Wed Mar 30 09:37:03 2016 +0300 usb: dwc3: drop ev_buffs array we will be using a single event buffer and that renders ev_buffs array unnecessary. Let's remove it in favor of a single pointer to a single event buffer. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.c | 13 ++++--------- drivers/usb/dwc3/core.h | 2 +- drivers/usb/dwc3/gadget.c | 4 ++-- 3 files changed, 7 insertions(+), 12 deletions(-) commit 660e9bde74d6915227d7ee3485b11e5f52637b26 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Wed Mar 30 09:26:24 2016 +0300 usb: dwc3: remove num_event_buffers We never, ever route any of the other event buffers so we might as well drop support for them. Until someone has a real, proper benefit for multiple event buffers, we will rely on a single one. This also helps reduce memory footprint of dwc3.ko which won't allocate memory for the extra event buffers. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.c | 81 +++++++++++++++++++---------------------------- drivers/usb/dwc3/core.h | 2 -- drivers/usb/dwc3/gadget.c | 38 +++++++--------------- 3 files changed, 44 insertions(+), 77 deletions(-) commit acd877f4ec69639c825725091eb3749d36fd11b3 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Mar 29 12:27:14 2016 +0300 usb: phy: qcom: use PTR_ERR_OR_ZERO() coccicheck found this pattern which could be converted to PTR_ERR_OR_ZERO(). No functional changes. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/phy/phy-qcom-8x16-usb.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 46cdd1900fa7a1d7afd1f8d051e513105d0cea98 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Tue Mar 29 12:26:06 2016 +0300 usb: gadget: udc: at91: use PTR_ERR_OR_ZERO() coccicheck found this pattern which could be converted to PTR_ERR_OR_ZERO(). No functional changes. Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/gadget/udc/at91_udc.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit aa3342c8bb618ae25beccddacc3efb415c3a987b Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Mon Mar 14 11:01:31 2016 +0200 usb: dwc3: better name for our request management lists request_list and req_queued were, well, weird naming choices. Let's give those better names and call them, respectively, pending_list and started_list. These new names better reflect what these lists are supposed to do. While at that also rename req->queued to req->started. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 10 ++++---- drivers/usb/dwc3/ep0.c | 14 ++++++------ drivers/usb/dwc3/gadget.c | 58 +++++++++++++++++++++++------------------------ drivers/usb/dwc3/gadget.h | 6 ++--- 4 files changed, 44 insertions(+), 44 deletions(-) commit 8495036e986bdc7e82523d47097e7833d2782ff9 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Mar 10 14:40:31 2016 +0200 usb: dwc3: increase maximum number of TRBs per endpoint previously we were using a maximum of 32 TRBs per endpoint. With each TRB being 16 bytes long, we were using 512 bytes of memory for each endpoint. However, SLAB/SLUB will always allocate PAGE_SIZE chunks. In order to better utilize the memory we allocate and to allow deeper queues for gadgets which would benefit from it (g_ether comes to mind), let's increase the maximum to 256 TRBs which rounds up to 4096 bytes for each endpoint. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ca4d44ea2a91b922e1514f5ed77f6bcf3657fd67 Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Mar 10 13:53:27 2016 +0200 usb: dwc3: gadget: always enable CSP CSP bit of TRB Control is useful for protocols such CDC EEM/ECM/NCM where we're transferring in blocks of MTU-sized requests (usually MTU is 1500 bytes). We know we will always have a short packet after two (for HS) wMaxPacketSize packets and, usually, we will have a long(-ish) queue of requests (for our g_ether gadget, we have at least 10 requests). Instead of always stopping the queue processing to interrupt, giveback and restart, let's tell dwc3 to interrupt but continue processing following request if we have anything already pending in the queue. This gave me a considerable improvement of 40% on my test setup. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> drivers/usb/dwc3/gadget.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit bc5081617faeb3b2f0c126dc37264b87af7da47f Author: Felipe Balbi <felipe.balbi@linux.intel.com> Date: Thu Feb 4 14:18:01 2016 +0200 usb: dwc3: drop FIFO resizing logic That FIFO resizing logic was added to support OMAP5 ES1.0 which had a bogus default FIFO size. I can't remember the exact size of default FIFO, but it was less than one bulk superspeed packet (<1024) which would prevent USB3 from ever working on OMAP5 ES1.0. However, OMAP5 ES1.0 support has been dropped by commit aa2f4b16f830 ("ARM: OMAP5: id: Remove ES1.0 support") which renders FIFO resizing unnecessary. Tested-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com> Documentation/devicetree/bindings/usb/dwc3.txt | 4 +- .../devicetree/bindings/usb/qcom,dwc3.txt | 1 - drivers/usb/dwc3/core.c | 4 - drivers/usb/dwc3/core.h | 5 -- drivers/usb/dwc3/ep0.c | 9 --- drivers/usb/dwc3/gadget.c | 86 ---------------------- drivers/usb/dwc3/platform_data.h | 1 - 7 files changed, 2 insertions(+), 108 deletions(-) commit 371a13d41599dd86e74625d542a6dc345ed1f312 Author: Petr Kulhavy <petr@barix.com> Date: Wed Feb 24 16:41:49 2016 +0100 ARM: DaVinci USB: removed deprecated properties from MUSB config The following properties of the musb_hdrc_config structure are deprecated and no longer required/used by the MUSB driver: .dyn_fifo .soft_con .dma .dma_channels .eps_bits Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/usb.c | 16 ---------------- 1 file changed, 16 deletions(-) commit 6c14838057e4bd5d7b65a1e51310abf3c001c466 Author: Liu Ying <gnuiyl@gmail.com> Date: Tue Apr 5 16:50:39 2016 +0800 drm/crtc_helper: Reset empty plane state in drm_helper_crtc_mode_set_base() Transitional drivers might access the NULL pointer plane->state in drm_helper_crtc_mode_set_base(), which causes NULL pointer dereference. So, let's reset it before handing it over to those drivers. commit e4f31ad2b713 ("drm: reset empty state in transitional helpers") did the same thing for other transitional helpers, but it seems this one was missed. Signed-off-by: Liu Ying <gnuiyl@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459846239-8946-1-git-send-email-gnuiyl@gmail.com drivers/gpu/drm/drm_crtc_helper.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit c03225fd6b6467ac027bfdb153e4a3a6d8b2c90e Author: Sekhar Nori <nsekhar@ti.com> Date: Thu Apr 7 16:45:22 2016 +0530 ARM: davinci_all_defconfig: enable GPIO_SYSFS CONFIG_GPIO_SYSFS provides a convenient way to access GPIOs from userspace. Enable it for DaVinci. Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/configs/davinci_all_defconfig | 1 + 1 file changed, 1 insertion(+) commit 6c8f73592203b8611c6ba5d4c670c82a059ecf27 Author: Petr Kulhavy <petr@barix.com> Date: Fri Apr 1 17:42:05 2016 +0200 ARM: davinci: da8xx-dt: add OF_DEV_AUXDATA entry for i2c1 Add OF_DEV_AUXDATA entry for second i2c on the da850 DT board driver to use i2c clock. Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/mach-davinci/da8xx-dt.c | 1 + 1 file changed, 1 insertion(+) commit 92d6464297d5a5f1f403cca5ec17c7427bdf18c3 Author: Petr Kulhavy <petr@barix.com> Date: Fri Apr 1 17:42:04 2016 +0200 ARM: DTS: da850: add node for i2c1 da850 has two I2C controllers, but the node for i2c1 was missing. Add node for i2c1 controller and i2c1 pinmux pins. Signed-off-by: Petr Kulhavy <petr@barix.com> [nsekhar@ti.com: fix indentation] Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit c2a3b4bca53a59f4f1a36233f0f71ad6462678b6 Author: David Lechner <david@lechnology.com> Date: Fri Apr 1 17:42:03 2016 +0200 ARM: dts: davinci: use proper address after @ TI has been using the physical address in DT after the @ in device nodes. The device tree convention is to use the same address that is used for the reg property. This updates all davinci DT files to use the proper convention. Signed-off-by: David Lechner <david@lechnology.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850-enbw-cmc.dts | 8 +++--- arch/arm/boot/dts/da850-evm.dts | 26 +++++++++--------- arch/arm/boot/dts/da850.dtsi | 52 ++++++++++++++++++------------------ 3 files changed, 43 insertions(+), 43 deletions(-) commit 497762b852bd167d56a884bc3259eaf977e3db3f Author: Petr Kulhavy <petr@barix.com> Date: Tue Apr 5 11:31:37 2016 +0200 ARM: DTS: da850: fix missing #gpio-cells in gpio node The gpio node is missing the mandatory property #gpio-cells, which is causing runtime errors when using GPIOs e.g. with gpio-leds or gpio-keys: "could not get #gpio-cells for /soc/gpio@1e26000" This fixes the problem and adds the missing parameter. The value is 2 according to the gpio-davinci.txt binding. Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> arch/arm/boot/dts/da850.dtsi | 1 + 1 file changed, 1 insertion(+) commit 85baa095497f3e590df9f6c8932121f123efca5c Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu Mar 24 22:04:05 2016 +1100 powerpc/livepatch: Add live patching support on ppc64le Add the kconfig logic & assembly support for handling live patched functions. This depends on DYNAMIC_FTRACE_WITH_REGS, which in turn depends on the new -mprofile-kernel ftrace ABI, which is only supported currently on ppc64le. Live patching is handled by a special ftrace handler. This means it runs from ftrace_caller(). The live patch handler modifies the NIP so as to redirect the return from ftrace_caller() to the new patched function. However there is one particularly tricky case we need to handle. If a function A calls another function B, and it is known at link time that they share the same TOC, then A will not save or restore its TOC, and will call the local entry point of B. When we live patch B, we replace it with a new function C, which may not have the same TOC as A. At live patch time it's too late to modify A to do the TOC save/restore, so the live patching code must interpose itself between A and C, and do the TOC save/restore that A omitted. An additionaly complication is that the livepatch code can not create a stack frame in order to save the TOC. That is because if C takes > 8 arguments, or is varargs, A will have written the arguments for C in A's stack frame. To solve this, we introduce a "livepatch stack" which grows upward from the base of the regular stack, and is used to store the TOC & LR when calling a live patched function. When the patched function returns, we retrieve the real LR & TOC from the livepatch stack, restore them, and pop the livepatch "stack frame". Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Reviewed-by: Torsten Duwe <duwe@suse.de> Reviewed-by: Balbir Singh <bsingharora@gmail.com> arch/powerpc/Kconfig | 3 ++ arch/powerpc/kernel/asm-offsets.c | 4 ++ arch/powerpc/kernel/entry_64.S | 97 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 104 insertions(+) commit 5d31a96e6c0187f2c5d7004e005fd094a1277e9e Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu Mar 24 22:04:04 2016 +1100 powerpc/livepatch: Add livepatch stack to struct thread_info In order to support live patching we need to maintain an alternate stack of TOC & LR values. We use the base of the stack for this, and store the "live patch stack pointer" in struct thread_info. Unlike the other fields of thread_info, we can not statically initialise that value, so it must be done at run time. This patch just adds the code to support that, it is not enabled until the next patch which actually adds live patch support. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Acked-by: Balbir Singh <bsingharora@gmail.com> arch/powerpc/include/asm/livepatch.h | 8 ++++++++ arch/powerpc/include/asm/thread_info.h | 4 +++- arch/powerpc/kernel/irq.c | 3 +++ arch/powerpc/kernel/process.c | 6 +++++- arch/powerpc/kernel/setup_64.c | 17 ++++++++++------- 5 files changed, 29 insertions(+), 9 deletions(-) commit f63e6d89876034c21ecd18bb1cd0d6c5b8da11a5 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu Mar 24 22:04:03 2016 +1100 powerpc/livepatch: Add livepatch header Add the powerpc specific livepatch definitions. In particular we provide a non-default implementation of klp_get_ftrace_location(). This is required because the location of the mcount call is not constant when using -mprofile-kernel (which we always do for live patching). Signed-off-by: Torsten Duwe <duwe@suse.de> Signed-off-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/livepatch.h | 54 ++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) commit 28e7cbd3e0f5fefec892842d1391ebd508fdb5ce Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu Mar 24 22:04:02 2016 +1100 livepatch: Allow architectures to specify an alternate ftrace location When livepatch tries to patch a function it takes the function address and asks ftrace to install the livepatch handler at that location. ftrace will look for an mcount call site at that exact address. On powerpc the mcount location is not the first instruction of the function, and in fact it's not at a constant offset from the start of the function. To accommodate this add a hook which arch code can override to customise the behaviour. Signed-off-by: Torsten Duwe <duwe@suse.de> Signed-off-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Petr Mladek <pmladek@suse.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> kernel/livepatch/core.c | 34 +++++++++++++++++++++++++++++++--- 1 file changed, 31 insertions(+), 3 deletions(-) commit 04cf31a759ef575f750a63777cee95500e410994 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Thu Mar 24 22:04:01 2016 +1100 ftrace: Make ftrace_location_range() global In order to support live patching on powerpc we would like to call ftrace_location_range(), so make it global. Signed-off-by: Torsten Duwe <duwe@suse.de> Signed-off-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> include/linux/ftrace.h | 1 + kernel/trace/ftrace.c | 14 +++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) commit f38ba953bee01887d520f7abba536721a1d16477 Author: stephen hemminger <stephen@networkplumber.org> Date: Wed Apr 13 17:02:21 2016 -0700 gre: eliminate holes in ip_tunnel The structure can be packed denser by doing minor rearrangement of existing elements. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip_tunnels.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit d0988a5f77e7a399ac579e629f1dcc23059246e9 Author: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Date: Sun Apr 10 23:55:15 2016 +0300 ravb: make ravb_ptp_interrupt() *void* When we have the ISS.CGIS bit set, we already know that gPTP interrupt has happened, so an extra GIS register check at the end of ravb_ptp_interrupt() seems superfluous. We can model the gPTP interrupt handler like all other dedicated interrupt handlers in the driver and make it *void*. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/ravb.h | 2 +- drivers/net/ethernet/renesas/ravb_main.c | 8 ++++++-- drivers/net/ethernet/renesas/ravb_ptp.c | 9 ++------- 3 files changed, 9 insertions(+), 10 deletions(-) commit b9aa78d4fbf94cbf62954ce164aadda81b16d7d0 Merge: 6c61403d 7c2d7d7 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 14 00:43:21 2016 -0400 Merge branch 'qed-ethtool-rss' Yuval Mintz says: ==================== qed*: [mostly] Ethtool RSS configuration Most of the content [code-wise] in this series is for allowing various RSS-related configuration via ethtool. In addition, this also removed an unnecessary versioning scheme between the drivers and bump the driver version. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 7c2d7d7438c9808cff1c34decc80c49f87a764e7 Author: Yuval Mintz <Yuval.Mintz@qlogic.com> Date: Sun Apr 10 12:43:02 2016 +0300 qed* - bump driver versions to 8.7.1.20 Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 2 +- drivers/net/ethernet/qlogic/qede/qede.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 961acdeafd8f369a9e99b3d08f66eec5d8f93a8e Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Sun Apr 10 12:43:01 2016 +0300 qede: add Rx flow hash/indirection support. Adds support for the following via ethtool: - UDP configuration of RSS based on 2-tuple/4-tuple. - RSS hash key. - RSS indirection table. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qede/qede.h | 4 + drivers/net/ethernet/qlogic/qede/qede_ethtool.c | 237 +++++++++++++++++++++++- drivers/net/ethernet/qlogic/qede/qede_main.c | 52 +++++- 3 files changed, 283 insertions(+), 10 deletions(-) commit 8c5ebd0c792a097fcc0e526debbe0887ee378ae5 Author: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Date: Sun Apr 10 12:43:00 2016 +0300 qed: add Rx flow hash/indirection support. Adds the required API for passing RSS-related configuration from qede. Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed_l2.c | 17 +---------------- include/linux/qed/qed_eth_if.h | 1 + include/linux/qed/qed_if.h | 11 +++++++++++ 3 files changed, 13 insertions(+), 16 deletions(-) commit 95114344ea78649b1797d00ab6e88147bef66fa4 Author: Rahul Verma <rahul.verma@qlogic.com> Date: Sun Apr 10 12:42:59 2016 +0300 qed*: remove version dependency Inbox drivers don't need versioning scheme in order to guarantee compatibility, as both qed and qede are compiled from same codebase. Signed-off-by: Rahul Verma <rahul.verma@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/qlogic/qed/qed.h | 2 -- drivers/net/ethernet/qlogic/qed/qed_l2.c | 8 +------- drivers/net/ethernet/qlogic/qed/qed_main.c | 11 ----------- drivers/net/ethernet/qlogic/qede/qede.h | 2 -- drivers/net/ethernet/qlogic/qede/qede_main.c | 11 +---------- include/linux/qed/qed_eth_if.h | 2 +- include/linux/qed/qed_if.h | 9 --------- 7 files changed, 3 insertions(+), 42 deletions(-) commit 6c61403daea578dcfe84f187c204db1a3fa3d6ae Merge: 743b03a 2da6290 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 14 00:39:15 2016 -0400 Merge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs commit 743b03a83297690f0bd38c452a3bbb47d2be300a Author: Eric Dumazet <edumazet@google.com> Date: Sat Apr 9 11:29:58 2016 -0700 net: remove netdevice gso_min_segs After introduction of ndo_features_check(), we believe that very specific checks for rare features should not be done in core networking stack. No driver uses gso_min_segs yet, so we revert this feature and save few instructions per tx packet in fast path. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 4 +--- net/core/dev.c | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-) commit cfe2f14c72b0266a9f3573427f206a98ad3d409c Author: Julia Lawall <julia.lawall@lip6.fr> Date: Sat Apr 9 10:49:22 2016 +0200 qdisc: constify meta_type_ops structures The meta_type_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: David S. Miller <davem@davemloft.net> net/sched/em_meta.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit e178c8c2306ebff13aee365de703e6b8b2bea066 Author: Petri Gynther <pgynther@google.com> Date: Sat Apr 9 00:20:36 2016 -0700 net: bcmgenet: add BQL support Add Byte Queue Limits (BQL) support to bcmgenet driver. Signed-off-by: Petri Gynther <pgynther@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit dac916f8fbd1ea514a61f4dcecaa97a5e7bac4c0 Author: Florian Fainelli <f.fainelli@gmail.com> Date: Fri Apr 8 22:30:56 2016 -0700 net: bcmgenet: use __napi_schedule_irqoff() bcmgenet_isr1() and bcmgenet_isr0() run in hard irq context, we do not need to block irq again. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Petri Gynther <pgynther@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit eb96ce01bab7af55d983feaae069c18792d427ef Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 8 22:06:40 2016 -0700 net: bcmgenet: use napi_complete_done() By using napi_complete_done(), we allow fine tuning of /sys/class/net/ethX/gro_flush_timeout for higher GRO aggregation efficiency for a Gbit NIC. Check commit 24d2e4a50737 ("tg3: use napi_complete_done()") for details. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Petri Gynther <pgynther@google.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Petri Gynther <pgynther@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f9fd2adaacd8dc0ecbb38d96f3c62f20f0697176 Merge: d00b39c 7d32326 Author: Dave Airlie <airlied@redhat.com> Date: Thu Apr 14 13:07:12 2016 +1000 Merge branch 'gma500-next' of git://github.com/patjak/drm-gma500 into drm-next A few fixes and cleanups for 4.7 that's been collecting dust in my inbox for a while. * 'gma500-next' of git://github.com/patjak/drm-gma500: drm/gma500/mdfld_dsi: remove bogus if check drm/gma500: Fix possible out of bounds read drm/gma500: fix double freeing commit dfb6cbf693536937fc49a7c5822dd39ef9d1a8e5 Merge: ea01964 fb586f2 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 13 23:04:44 2016 -0400 Merge branch 'sctp-delayed-wakeups' Marcelo Ricardo Leitner says: ==================== sctp: delay calls to sk_data_ready() as much as possible 1st patch is a preparation for the 2nd. The idea is to not call ->sk_data_ready() for every data chunk processed while processing packets but only once before releasing the socket. v2: patchset re-checked, small changelog fixes v3: on patch 2, make use of local vars to make it more readable ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit fb586f25300f4587c7ebd097a604bf269b25bfa7 Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Date: Fri Apr 8 16:41:28 2016 -0300 sctp: delay calls to sk_data_ready() as much as possible Currently processing of multiple chunks in a single SCTP packet leads to multiple calls to sk_data_ready, causing multiple wake up signals which are costy and doesn't make it wake up any faster. With this patch it will note that the wake up is pending and will do it before leaving the state machine interpreter, latest place possible to do it realiably and cleanly. Note that sk_data_ready events are not dependent on asocs, unlike waking up writers. v2: series re-checked v3: use local vars to cleanup the code, suggested by Jakub Sitnicki Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/structs.h | 3 ++- net/sctp/sm_sideeffect.c | 7 +++++++ net/sctp/ulpqueue.c | 4 ++-- 3 files changed, 11 insertions(+), 3 deletions(-) commit 250eb1f8815303f71c94a5680f8e4f2dcfa25cf5 Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Date: Fri Apr 8 16:41:27 2016 -0300 sctp: compress bit-wide flags to a bitfield on sctp_sock It wastes space and gets worse as we add new flags, so convert bit-wide flags to a bitfield. Currently it already saves 4 bytes in sctp_sock, which are left as holes in it for now. The whole struct needs packing, which should be done in another patch. Note that do_auto_asconf cannot be merged, as explained in the comment before it. Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Acked-by: Neil Horman <nhorman@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sctp/structs.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit ea019649c37b8aa0d1ac5727d122b2e8ed74f536 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Fri Apr 8 20:39:47 2016 +0200 drivers/net/ethernet/jme.c: Deinline jme_reset_mac_processor, save 2816 bytes This function compiles to 895 bytes of machine code. Clearly, this isn't a time-critical function. For one, it has a number of udelay(1) calls. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: David S. Miller <davem@davemloft.net> CC: linux-kernel@vger.kernel.org CC: netdev@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/jme.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 079adf6c53e8b791ca569314ebee631bb68fbb31 Merge: f9a7cbb bf871ad Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 13 22:42:33 2016 -0400 Merge branch 'bridge-sysfs-rtnl-notifications' Xin Long says: ==================== bridge: support sending rntl info when we set attributes through sysfs/ioctl This patchset is used to support sending rntl info to user in some places, and ensure that whenever those attributes change internally or from sysfs, that a netlink notification is sent out to listeners. It also make some adjustment in bridge sysfs so that we can implement this easily. I've done some tests on this patchset, like: [br_sysfs] 1. change all the attribute values of br or brif: $ echo $value > /sys/class/net/br0/bridge/{*} $ echo $value > /sys/class/net/br0/brif/eth1/{*} 2. meanwhile, on another terminal to observe the msg: $ bridge monitor [br_ioctl] 1. in bridge-utils package, do some changes in br_set, let brctl command use ioctl to set attribute: if ((ret = set_sysfs(path, value)) < 0) { --> if (1) { $ brctl set* 2. meanwhile, on another terminal to observe the msg: $ bridge monitor This test covers all the attributes that brctl and sysfs support to set. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit bf871ad792e3c9f5dda0ef5bd519e0a2f1564001 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:33 2016 +0800 bridge: a netlink notification should be sent when those attributes are changed by ioctl Now when we change the attributes of bridge or br_port by netlink, a relevant netlink notification will be sent, but if we change them by ioctl or sysfs, no notification will be sent. We should ensure that whenever those attributes change internally or from sysfs/ioctl, that a netlink notification is sent out to listeners. Also, NetworkManager will use this in the future to listen for out-of-band bridge master attribute updates and incorporate them into the runtime configuration. This patch is used for ioctl. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_ioctl.c | 40 ++++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 16 deletions(-) commit bdaf0d5d98e1c42d3a48c5ce6db9d013cb882781 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:32 2016 +0800 bridge: a netlink notification should be sent when those attributes are changed by br_sysfs_if Now when we change the attributes of bridge or br_port by netlink, a relevant netlink notification will be sent, but if we change them by ioctl or sysfs, no notification will be sent. We should ensure that whenever those attributes change internally or from sysfs/ioctl, that a netlink notification is sent out to listeners. Also, NetworkManager will use this in the future to listen for out-of-band bridge master attribute updates and incorporate them into the runtime configuration. This patch is used for br_sysfs_if, and we also move br_ifinfo_notify out of store_flag. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_sysfs_if.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 047831a9b9c3e34410025df84f629c005f437e42 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:31 2016 +0800 bridge: a netlink notification should be sent when those attributes are changed by br_sysfs_br Now when we change the attributes of bridge or br_port by netlink, a relevant netlink notification will be sent, but if we change them by ioctl or sysfs, no notification will be sent. We should ensure that whenever those attributes change internally or from sysfs/ioctl, that a netlink notification is sent out to listeners. Also, NetworkManager will use this in the future to listen for out-of-band bridge master attribute updates and incorporate them into the runtime configuration. This patch is used for br_sysfs_br. and we also need to remove some rtnl_trylock in old functions so that we can call it in a common one. For group_addr_store, we cannot make it use store_bridge_parm, because it's not a string-to-long convert, we will add notification on it individually. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_sysfs_br.c | 21 +++++++++------------ net/bridge/br_vlan.c | 30 +++++------------------------- 2 files changed, 14 insertions(+), 37 deletions(-) commit 4436156b6fbec746108d45431a9f1885de810ec1 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:30 2016 +0800 bridge: simplify the stp_state_store by calling store_bridge_parm There are some repetitive codes in stp_state_store, we can remove them by calling store_bridge_parm. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_sysfs_br.c | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) commit 347db6b49ec0ba5ee3c9d946d45b7db59cf40480 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:29 2016 +0800 bridge: simplify the forward_delay_store by calling store_bridge_parm There are some repetitive codes in forward_delay_store, we can remove them by calling store_bridge_parm. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_sysfs_br.c | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) commit 14f31bb39f5d4b69c179d219833d7edb9b36ebd9 Author: Xin Long <lucien.xin@gmail.com> Date: Sat Apr 9 00:03:28 2016 +0800 bridge: simplify the flush_store by calling store_bridge_parm There are some repetitive codes in flush_store, we can remove them by calling store_bridge_parm, also, it would send rtnl notification after we add it in store_bridge_parm in the following patches. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/bridge/br_sysfs_br.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit f9a7cbbf18f1640907d6ca345b8337e4b50ea56f Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Fri Apr 8 17:51:54 2016 +0200 net: force inlining of netif_tx_start/stop_queue, sock_hold, __sock_put Sometimes gcc mysteriously doesn't inline very small functions we expect to be inlined. See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66122 Arguably, gcc should do better, but gcc people aren't willing to invest time into it, asking to use __always_inline instead. With this .config: http://busybox.net/~vda/kernel_config_OPTIMIZE_INLINING_and_Os, the following functions get deinlined many times. netif_tx_stop_queue: 207 copies, 590 calls: 55 push %rbp 48 89 e5 mov %rsp,%rbp f0 80 8f e0 01 00 00 01 lock orb $0x1,0x1e0(%rdi) 5d pop %rbp c3 retq netif_tx_start_queue: 47 copies, 111 calls 55 push %rbp 48 89 e5 mov %rsp,%rbp f0 80 a7 e0 01 00 00 fe lock andb $0xfe,0x1e0(%rdi) 5d pop %rbp c3 retq sock_hold: 39 copies, 124 calls 55 push %rbp 48 89 e5 mov %rsp,%rbp f0 ff 87 80 00 00 00 lock incl 0x80(%rdi) 5d pop %rbp c3 retq __sock_put: 6 copies, 13 calls 55 push %rbp 48 89 e5 mov %rsp,%rbp f0 ff 8f 80 00 00 00 lock decl 0x80(%rdi) 5d pop %rbp c3 retq This patch fixes this via s/inline/__always_inline/. Code size decrease after the patch is ~2.5k: text data bss dec hex filename 56719876 56364551 36196352 149280779 8e5d80b vmlinux_before 56717440 56364551 36196352 149278343 8e5ce87 vmlinux Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> CC: David S. Miller <davem@davemloft.net> CC: linux-kernel@vger.kernel.org CC: netdev@vger.kernel.org CC: netfilter-devel@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 4 ++-- include/net/sock.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit bf91795e4a77eb75602702e4c4d9b98b155039e9 Author: Masanari Iida <standby24x7@gmail.com> Date: Sat Apr 9 00:00:25 2016 +0900 Doc: networking: Fix typo in dsa This patch fix typos in Documentation/networking/dsa. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/bcm_sf2.txt | 2 +- Documentation/networking/dsa/dsa.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 47e27d5e92c46a3a62d4dfd8895b1ddb8613f531 Author: Daniel Borkmann <daniel@iogearbox.net> Date: Fri Apr 8 15:55:00 2016 +0200 ipv6, token: allow for clearing the current device token The original tokenized iid support implemented via f53adae4eae5 ("net: ipv6: add tokenized interface identifier support") didn't allow for clearing a device token as it was intended that this addressing mode was the only one active for globally scoped IPv6 addresses. Later we relaxed that restriction via 617fe29d45bd ("net: ipv6: only invalidate previously tokenized addresses"), and we should also allow for clearing tokens as there's no good reason why it shouldn't be allowed. Fixes: 617fe29d45bd ("net: ipv6: only invalidate previously tokenized addresses") Reported-by: Robin H. Johnson <robbat2@gentoo.org> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Cc: Hannes Frederic Sowa <hannes@stressinduktion.org> Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/addrconf.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit fafc4e1ea1a4c1eb13a30c9426fb799f5efacbc3 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Fri Apr 8 15:11:27 2016 +0200 sock: tigthen lockdep checks for sock_owned_by_user sock_owned_by_user should not be used without socket lock held. It seems to be a common practice to check .owned before lock reclassification, so provide a little help to abstract this check away. Cc: linux-cifs@vger.kernel.org Cc: linux-bluetooth@vger.kernel.org Cc: linux-nfs@vger.kernel.org Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> fs/cifs/connect.c | 4 ++-- include/net/sock.h | 44 +++++++++++++++++++++++++++++--------------- net/bluetooth/af_bluetooth.c | 2 +- net/llc/llc_proc.c | 2 +- net/sunrpc/svcsock.c | 3 +-- net/sunrpc/xprtsock.c | 3 +-- 6 files changed, 35 insertions(+), 23 deletions(-) commit 18b46810eb61f1d1a66c5511d12e84ea8cb7f35c Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 8 11:18:03 2016 +0200 net: ethernet: stmmac: GMAC4.xx: Fix TX descriptor preparation On GMAC4.xx each descriptor contains 2 buffers of 16KB (each). Initially, those 2 buffers was filled in dwmac4_rd_prepare_tx_desc but it is actually not needed. Indeed, stmmac driver supports frame up to 9000 bytes (jumbo). So only one buffer is needed. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac4_descs.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit fbf405e80c8af9ba0a9eb6f52d3bb8cddacd6036 Merge: 99717bd 31c2e49 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 13 22:24:52 2016 -0400 Merge branch 'udp-hdrs-fixes' Willem de Bruijn says: ==================== fix two more udp pull header issues Follow up patches to the fixes to RxRPC and SunRPC. A scan of the code showed two other interfaces that expect UDP packets to have a udphdr when queued: read packet length with ioctl SIOCINQ and receive payload checksum with socket option IP_CHECKSUM. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 31c2e4926fe912f88388bcaa8450fcaa8f2ece47 Author: Willem de Bruijn <willemb@google.com> Date: Thu Apr 7 18:12:59 2016 -0400 udp: do not expect udp headers in recv cmsg IP_CMSG_CHECKSUM On udp sockets, recv cmsg IP_CMSG_CHECKSUM returns a checksum over the packet payload. Since commit e6afc8ace6dd pulled the headers, taking skb->data as the start of transport header is incorrect. Use the transport header pointer. Also, when peeking at an offset from the start of the packet, only return a checksum from the start of the peeked data. Note that the cmsg does not subtract a tail checkum when reading truncated data. Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/ip_sockglue.c | 3 ++- net/ipv4/udp.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) commit 9f9a45beaa96188085d52d273c2ecb052c7d8d27 Author: Willem de Bruijn <willemb@google.com> Date: Thu Apr 7 18:12:58 2016 -0400 udp: do not expect udp headers on ioctl SIOCINQ On udp sockets, ioctl SIOCINQ returns the payload size of the first packet. Since commit e6afc8ace6dd pulled the headers, the result is incorrect when subtracting header length. Remove that operation. Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/udp.c | 2 -- 1 file changed, 2 deletions(-) commit c323061e4201d22bb72d3ed65044751b344a52a7 Merge: 49ad80d 33406c8 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:44:59 2016 -0700 Merge tag 'sti-soc-for-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti into next/soc Highlights: ----------- - Add CPUFreq and RProc drivers to STI maintainers file list - Improve STi's menuconfig help entry * tag 'sti-soc-for-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti: ARM: STi: Update platform level menuconfig 'help' MAINTAINERS: Add ST's Remote Processor Driver to ARM/STI ARCHITECTURE MAINTAINERS: Add ST's CPUFreq driver to the STI file list Signed-off-by: Olof Johansson <olof@lixom.net> commit 7d7bca889f99c4401931e536adb0da1b6c6f48c5 Merge: b6ac00b 6d54fb8 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:43:50 2016 -0700 Merge tag 'sti-defconfig-for-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti into next/defconfig Highlights: ----------- - Enable ST's HW Random number generator in multi_v7 defconfig - Enable PWM regulator support in multi_v7 defconfig - Enable ST's Power and Reset driver in multi_v7 defconfig - Enable ST's PWM in multi_v7 defconfig * tag 'sti-defconfig-for-v4.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mcoquelin/sti: ARM: multi_v7_defconfig: Enable ST's HW Random Number Generator ARM: multi_v7_defconfig: Enable support for PWM Regulators ARM: multi_v7_defconfig: Enable ST's Power Reset driver ARM: multi_v7_defconfig: Enable ST's PWM driver Signed-off-by: Olof Johansson <olof@lixom.net> commit 4054ff45454a9a4652e29ac750a6600f6fdcc216 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Tue Apr 12 23:32:34 2016 +0200 netfilter: ctnetlink: remove unnecessary inlining Many of these functions are called from control plane path. Move ctnetlink_nlmsg_size() under CONFIG_NF_CONNTRACK_EVENTS to avoid a compilation warning when CONFIG_NF_CONNTRACK_EVENTS=n. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_netlink.c | 117 ++++++++++++++--------------------- 1 file changed, 48 insertions(+), 69 deletions(-) commit d7591f0c41ce3e67600a982bab6989ef0f07b3ce Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 15:37:59 2016 +0200 netfilter: x_tables: introduce and use xt_copy_counters_from_user The three variants use same copy&pasted code, condense this into a helper and use that. Make sure info.name is 0-terminated. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 3 ++ net/ipv4/netfilter/arp_tables.c | 48 +++---------------------- net/ipv4/netfilter/ip_tables.c | 48 +++---------------------- net/ipv6/netfilter/ip6_tables.c | 49 +++---------------------- net/netfilter/x_tables.c | 74 ++++++++++++++++++++++++++++++++++++++ 5 files changed, 92 insertions(+), 130 deletions(-) commit aded9f3e9fa8db559c5b7661bbb497754270e754 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:36 2016 +0200 netfilter: x_tables: remove obsolete check Since 'netfilter: x_tables: validate targets of jumps' change we validate that the target aligns exactly with beginning of a rule, so offset test is now redundant. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 8 -------- net/ipv4/netfilter/ip_tables.c | 7 ------- net/ipv6/netfilter/ip6_tables.c | 7 ------- 3 files changed, 22 deletions(-) commit 95609155d7fa08cc2e71d494acad39f72f0b4495 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:35 2016 +0200 netfilter: x_tables: remove obsolete overflow check for compat case too commit 9e67d5a739327c44885adebb4f3a538050be73e4 ("[NETFILTER]: x_tables: remove obsolete overflow check") left the compat parts alone, but we can kill it there as well. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 2 -- net/ipv4/netfilter/ip_tables.c | 2 -- net/ipv6/netfilter/ip6_tables.c | 2 -- 3 files changed, 6 deletions(-) commit 09d9686047dbbe1cf4faa558d3ecc4aae2046054 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:34 2016 +0200 netfilter: x_tables: do compat validation via translate_table This looks like refactoring, but its also a bug fix. Problem is that the compat path (32bit iptables, 64bit kernel) lacks a few sanity tests that are done in the normal path. For example, we do not check for underflows and the base chain policies. While its possible to also add such checks to the compat path, its more copy&pastry, for instance we cannot reuse check_underflow() helper as e->target_offset differs in the compat case. Other problem is that it makes auditing for validation errors harder; two places need to be checked and kept in sync. At a high level 32 bit compat works like this: 1- initial pass over blob: validate match/entry offsets, bounds checking lookup all matches and targets do bookkeeping wrt. size delta of 32/64bit structures assign match/target.u.kernel pointer (points at kernel implementation, needed to access ->compatsize etc.) 2- allocate memory according to the total bookkeeping size to contain the translated ruleset 3- second pass over original blob: for each entry, copy the 32bit representation to the newly allocated memory. This also does any special match translations (e.g. adjust 32bit to 64bit longs, etc). 4- check if ruleset is free of loops (chase all jumps) 5-first pass over translated blob: call the checkentry function of all matches and targets. The alternative implemented by this patch is to drop steps 3&4 from the compat process, the translation is changed into an intermediate step rather than a full 1:1 translate_table replacement. In the 2nd pass (step #3), change the 64bit ruleset back to a kernel representation, i.e. put() the kernel pointer and restore ->u.user.name . This gets us a 64bit ruleset that is in the format generated by a 64bit iptables userspace -- we can then use translate_table() to get the 'native' sanity checks. This has two drawbacks: 1. we re-validate all the match and target entry structure sizes even though compat translation is supposed to never generate bogus offsets. 2. we put and then re-lookup each match and target. THe upside is that we get all sanity tests and ruleset validations provided by the normal path and can remove some duplicated compat code. iptables-restore time of autogenerated ruleset with 300k chains of form -A CHAIN0001 -m limit --limit 1/s -j CHAIN0002 -A CHAIN0002 -m limit --limit 1/s -j CHAIN0003 shows no noticeable differences in restore times: old: 0m30.796s new: 0m31.521s 64bit: 0m25.674s Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 114 ++++++----------------------- net/ipv4/netfilter/ip_tables.c | 155 ++++++++-------------------------------- net/ipv6/netfilter/ip6_tables.c | 148 ++++++-------------------------------- net/netfilter/x_tables.c | 8 +++ 4 files changed, 83 insertions(+), 342 deletions(-) commit 0188346f21e6546498c2a0f84888797ad4063fc5 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:33 2016 +0200 netfilter: x_tables: xt_compat_match_from_user doesn't need a retval Always returned 0. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 2 +- net/ipv4/netfilter/arp_tables.c | 17 +++++------------ net/ipv4/netfilter/ip_tables.c | 26 +++++++++----------------- net/ipv6/netfilter/ip6_tables.c | 27 +++++++++------------------ net/netfilter/x_tables.c | 5 ++--- 5 files changed, 26 insertions(+), 51 deletions(-) commit 8dddd32756f6fe8e4e82a63361119b7e2384e02f Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:32 2016 +0200 netfilter: arp_tables: simplify translate_compat_table args Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 82 ++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 46 deletions(-) commit 329a0807124f12fe1c8032f95d8a8eb47047fb0e Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:31 2016 +0200 netfilter: ip6_tables: simplify translate_compat_table args Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv6/netfilter/ip6_tables.c | 59 +++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 35 deletions(-) commit 7d3f843eed29222254c9feab481f55175a1afcc9 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:30 2016 +0200 netfilter: ip_tables: simplify translate_compat_table args Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/ip_tables.c | 59 +++++++++++++++++------------------------- 1 file changed, 24 insertions(+), 35 deletions(-) commit 13631bfc604161a9d69cd68991dff8603edd66f9 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:29 2016 +0200 netfilter: x_tables: validate all offsets and sizes in a rule Validate that all matches (if any) add up to the beginning of the target and that each match covers at least the base structure size. The compat path should be able to safely re-use the function as the structures only differ in alignment; added a BUILD_BUG_ON just in case we have an arch that adds padding as well. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/x_tables.c | 81 +++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 76 insertions(+), 5 deletions(-) commit ce683e5f9d045e5d67d1312a42b359cb2ab2a13c Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:28 2016 +0200 netfilter: x_tables: check for bogus target offset We're currently asserting that targetoff + targetsize <= nextoff. Extend it to also check that targetoff is >= sizeof(xt_entry). Since this is generic code, add an argument pointing to the start of the match/target, we can then derive the base structure size from the delta. We also need the e->elems pointer in a followup change to validate matches. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 4 ++-- net/ipv4/netfilter/arp_tables.c | 5 +++-- net/ipv4/netfilter/ip_tables.c | 5 +++-- net/ipv6/netfilter/ip6_tables.c | 5 +++-- net/netfilter/x_tables.c | 17 +++++++++++++++-- 5 files changed, 26 insertions(+), 10 deletions(-) commit 7ed2abddd20cf8f6bd27f65bd218f26fa5bf7f44 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:27 2016 +0200 netfilter: x_tables: check standard target size too We have targets and standard targets -- the latter carries a verdict. The ip/ip6tables validation functions will access t->verdict for the standard targets to fetch the jump offset or verdict for chainloop detection, but this happens before the targets get checked/validated. Thus we also need to check for verdict presence here, else t->verdict can point right after a blob. Spotted with UBSAN while testing malformed blobs. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/x_tables.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit fc1221b3a163d1386d1052184202d5dc50d302d1 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:26 2016 +0200 netfilter: x_tables: add compat version of xt_check_entry_offsets 32bit rulesets have different layout and alignment requirements, so once more integrity checks get added to xt_check_entry_offsets it will reject well-formed 32bit rulesets. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 3 +++ net/ipv4/netfilter/arp_tables.c | 3 ++- net/ipv4/netfilter/ip_tables.c | 3 ++- net/ipv6/netfilter/ip6_tables.c | 3 ++- net/netfilter/x_tables.c | 22 ++++++++++++++++++++++ 5 files changed, 31 insertions(+), 3 deletions(-) commit a08e4e190b866579896c09af59b3bdca821da2cd Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:25 2016 +0200 netfilter: x_tables: assert minimum target size The target size includes the size of the xt_entry_target struct. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/x_tables.c | 3 +++ 1 file changed, 3 insertions(+) commit aa412ba225dd3bc36d404c28cdc3d674850d80d0 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:24 2016 +0200 netfilter: x_tables: kill check_entry helper Once we add more sanity testing to xt_check_entry_offsets it becomes relvant if we're expecting a 32bit 'config_compat' blob or a normal one. Since we already have a lot of similar-named functions (check_entry, compat_check_entry, find_and_check_entry, etc.) and the current incarnation is short just fold its contents into the callers. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 19 ++++++++----------- net/ipv4/netfilter/ip_tables.c | 20 ++++++++------------ net/ipv6/netfilter/ip6_tables.c | 20 ++++++++------------ 3 files changed, 24 insertions(+), 35 deletions(-) commit 7d35812c3214afa5b37a675113555259cfd67b98 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:23 2016 +0200 netfilter: x_tables: add and use xt_check_entry_offsets Currently arp/ip and ip6tables each implement a short helper to check that the target offset is large enough to hold one xt_entry_target struct and that t->u.target_size fits within the current rule. Unfortunately these checks are not sufficient. To avoid adding new tests to all of ip/ip6/arptables move the current checks into a helper, then extend this helper in followup patches. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/linux/netfilter/x_tables.h | 4 ++++ net/ipv4/netfilter/arp_tables.c | 11 +---------- net/ipv4/netfilter/ip_tables.c | 12 +----------- net/ipv6/netfilter/ip6_tables.c | 12 +----------- net/netfilter/x_tables.c | 34 ++++++++++++++++++++++++++++++++++ 5 files changed, 41 insertions(+), 32 deletions(-) commit 36472341017529e2b12573093cc0f68719300997 Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:22 2016 +0200 netfilter: x_tables: validate targets of jumps When we see a jump also check that the offset gets us to beginning of a rule (an ipt_entry). The extra overhead is negible, even with absurd cases. 300k custom rules, 300k jumps to 'next' user chain: [ plus one jump from INPUT to first userchain ]: Before: real 0m24.874s user 0m7.532s sys 0m16.076s After: real 0m27.464s user 0m7.436s sys 0m18.840s Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 16 ++++++++++++++++ net/ipv4/netfilter/ip_tables.c | 16 ++++++++++++++++ net/ipv6/netfilter/ip6_tables.c | 16 ++++++++++++++++ 3 files changed, 48 insertions(+) commit f24e230d257af1ad7476c6e81a8dc3127a74204e Author: Florian Westphal <fw@strlen.de> Date: Fri Apr 1 14:17:21 2016 +0200 netfilter: x_tables: don't move to non-existent next rule Ben Hawkes says: In the mark_source_chains function (net/ipv4/netfilter/ip_tables.c) it is possible for a user-supplied ipt_entry structure to have a large next_offset field. This field is not bounds checked prior to writing a counter value at the supplied offset. Base chains enforce absolute verdict. User defined chains are supposed to end with an unconditional return, xtables userspace adds them automatically. But if such return is missing we will move to non-existent next rule. Reported-by: Ben Hawkes <hawkes@google.com> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv4/netfilter/arp_tables.c | 8 +++++--- net/ipv4/netfilter/ip_tables.c | 4 ++++ net/ipv6/netfilter/ip6_tables.c | 4 ++++ 3 files changed, 13 insertions(+), 3 deletions(-) commit e24f89e37bee8a11050ce87293814e2c86e3b330 Merge: 56a0ecc 40ac568 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:30:20 2016 -0700 Merge tag 'v4.7-rockchip-dts64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/dt64 This contains the rk3368-geekbox as new board, mailbox device nodes for the core rk3368 and some cleanups for gpio-keys, mmc and tsadc. * tag 'v4.7-rockchip-dts64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: Documentation: devicetree: rockchip: Document rk3368-GeekBox arm64: dts: rockchip: Add rk3368 GeekBox dts arm64: dts: rockchip: Clean up gpio-keys nodes dt-bindings: Add vendor prefix for GeekBuying.com arm64: dts: rockchip: Add rk3368 mailbox device nodes arm64: dts: rockchip: remove broken-cd from emmc and sdio arm64: dts: rockchip: fix the incorrect otp-out pin on rk3368 Signed-off-by: Olof Johansson <olof@lixom.net> commit 8bd641ff01982d0e985e542183dd195e26686017 Merge: ed53ecb fbf1504 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:27:33 2016 -0700 Merge tag 'v4.7-rockchip-dts32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/dt A lot display-controller nodes for DSI and the Analogix DP on rk3288 as well as general display+hdmi support on rk3036. With the Analogix DP support, Veyron Chromeboks can now finally use their internal display. Other than this big improvement we have thermal support on the rk3228, a long time missing binding document for the General Register Files block, better operating points for Veyron devices and a bunch of fixes with parts stemming from warnings that new dtc version can generate. * tag 'v4.7-rockchip-dts32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: (27 commits) ARM: dts: rockchip: move rk3036 memory definition to board files ARM: dts: rockchip: enable the eDP on rk3288 veyron devices ARM: dts: rockchip: simple panel and backlight supplies on veyron boards ARM: dts: rockchip: override edp hpd handling on veyron-pinky and speedy ARM: dts: rockchip: add rk3288-veyron-minnie backlight and panel settings ARM: dts: rockchip: add rk3288-veyron-jaq backlight and panel overrides ARM: dts: rockchip: add core rk3288-veyron backlight and panel nodes ARM: dts: rockchip: add startup delay to rk3288-veyron panel-regulators ARM: dts: rockchip: move edp-hpd pin definition into common location ARM: dts: rockchip: add rk3288 displayport controller node ARM: dts: rockchip: add rk3288 edp-phy node ARM: dts: rockchip: add missing unitname to cpu_leakage efuse ARM: dts: rockchip: drop unneeded properties from mipi node ARM: dts: rockchip: clean up gpio-keys nodes ARM: dts: rockchip: fix missing usbphy unit-names ARM: dts: rockchip: fix rk3288 power-domain unit names ARM: dts: rockchip: update rk3288-veyron cpu operating points ARM: dts: rockchip: remove broken-cd from emmc and sdio ARM: dts: rockchip: enable the tsadc for rk3228 evb ARM: dts: rockchip: add the thermal main info found on rk3228 ... Signed-off-by: Olof Johansson <olof@lixom.net> commit f8433ac982fa2adb409797b3b8619e5980f6947a Merge: 4b051f9 26d5192 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:27:05 2016 -0700 Merge tag 'v4.7-rockchip-soc32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/cleanup Fix for a sparse build warning in the smp code. * tag 'v4.7-rockchip-soc32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: ARM: rockchip: Fix use of plain integer as NULL pointer Signed-off-by: Olof Johansson <olof@lixom.net> commit a961bf24ba7137a223475c24a5b222112a1f1b88 Merge: 41f81a5 4506697 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:25:31 2016 -0700 Merge tag 'v4.7-rockchip-drivers-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into next/drivers Rockchip soc-specific driver changes containing support for the rk3399 powerdomains and necessary infrastructure changes to accomodate them - like supporting nested powerdomains here. * tag 'v4.7-rockchip-drivers-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: soc: rockchip: power-domain: check the existing of regmap soc: rockchip: power-domain: Modify power domain driver for rk3399 dt-bindings: add binding for rk3399 power domains dt-bindings: add power-domain header for RK3399 SoCs soc: rockchip: power-domain: add support for sub-power domains soc: rockchip: power-domain: allow domains only handling idle requests soc: rockchip: power-domain: make idle handling optional Signed-off-by: Olof Johansson <olof@lixom.net> commit b6ac00bb9fa4f979f40030e8218a3dd03f9260b7 Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Apr 12 03:20:04 2016 +0200 ARM: multi_v7_defconfig: Enable new Rockchip display-controller drivers Three types of display controller-drivers where added recently. The Analogix Displayport variant and Designware MIPI DSI used for example on the rk3288 as well as the Innosilicon HDMI controller used on the rk3036. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm/configs/multi_v7_defconfig | 3 +++ 1 file changed, 3 insertions(+) commit 0d14513bc241e70b4e0fa1b1eb3cf634c4017998 Author: Heiko Stuebner <heiko@sntech.de> Date: Tue Apr 12 03:18:39 2016 +0200 ARM: multi_v7_defconfig: Enable Rockchip displayport phy The displayport phy controls the output of the Analogix displayport controller on Rockchip SoCs and is therefore one component to enable veyron devices to use their internal display. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit ed53ecbea7949efc6efa6dbb6d96ab805b268977 Merge: 60cf1d9 249ff32 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 15:17:42 2016 -0700 Merge tag 'socfpga_dts_for_v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux into next/dt SoCFPGA DTS updates for v4.7 - Update SD/MMC node for Arria10 - Update Arria10 with clock and interrupt fields for DMA - Remove 'phy-addr' from stmmac node - Remove ethernet node from Cyclone5 DTSI - Add LEDs/KEYs/SWs support on Sockit - Add L2 and OCRAM EDAC dts entries - Add reset control for USB * tag 'socfpga_dts_for_v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux: ARM: dts: socfpga: add reset control for USB ARM: dts: socfpga: Add Altera Arria10 OCRAM EDAC devicetree entry ARM: dts: socfpga: Add Altera Arria10 L2 Cache EDAC devicetree entry ARM: dts: socfpga: Add support for HPS KEYs/SWs on SoCKit ARM: dts: socfpga: Add support for HPS LEDs on SoCKit ARM: dts: socfpga: Drop gmac0 from CV dtsi ARM: dts: socfpga: Drop phy-addr OF property from CV dtsi ARM: dts: socfpga: Add missing clock and interrupt fields for Arria10 DMA ARM: dts: socfpga: add the clk-phase property for sd/mmc clock ARM: dts: socfpga: add cap-sd-highspeed for SD/MMC node Signed-off-by: Olof Johansson <olof@lixom.net> commit ecb7b0183a89613c154d1bea48b494907efbf8f9 Author: Peter Rosin <peda@axentia.se> Date: Wed Mar 16 09:14:13 2016 -0300 [media] m88ds3103: fix undefined division s32tmp in the below code may be negative, and dev->mclk_khz is an unsigned type. s32tmp = 0x10000 * (tuner_frequency - c->frequency); s32tmp = DIV_ROUND_CLOSEST(s32tmp, dev->mclk_khz); This is undefined, as DIV_ROUND_CLOSEST is undefined for negative dividends when the divisor is of unsigned type. So, change mclk_khz to be signed (s32). Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/dvb-frontends/m88ds3103_priv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8cb555b603f386cdde77d0377318eb7051918045 Author: Chanho Min <chanho.min@lge.com> Date: Mon Apr 11 20:54:47 2016 +0900 MAINTAINERS: add Chanho Min as ARM/LG1K maintainer Signed-off-by: Chanho Min <chanho.min@lge.com> Signed-off-by: Olof Johansson <olof@lixom.net> MAINTAINERS | 6 ++++++ 1 file changed, 6 insertions(+) commit 71c5daba0546c456c5589bcf52eb2641abf42a85 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 24 22:46:45 2016 -0300 [media] media: platform: rcar_jpu, vsp1: Use ARCH_RENESAS Make use of ARCH_RENESAS in place of ARCH_SHMOBILE. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 0d268dcc693a56efb009316d83e0d732cafb9f9c Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Mar 25 06:51:06 2016 -0300 [media] v4l: vsp1: Update WPF and LIF maximum sizes for Gen3 The maximum image size supported by the WPF is 2048x2048 on Gen2 and 8190x8190 on Gen3. Update the code accordingly, and fix the maximum LIF size for both Gen2 and Gen3. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_lif.c | 2 +- drivers/media/platform/vsp1/vsp1_wpf.c | 15 +++++++++++---- 2 files changed, 12 insertions(+), 5 deletions(-) commit 56a0eccdc0dec223d4625c80de31514f04390159 Author: Chanho Min <chanho.min@lge.com> Date: Mon Apr 11 20:54:46 2016 +0900 arm64: dts: Add dts files for LG Electronics's lg1312 SoC Add initial dtsi file to support lg1312 SoC which based on Cortex-A53. Also add dts file to support lg1312 reference board which based on lg1312 SoC. Signed-off-by: Chanho Min <chanho.min@lge.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm64/boot/dts/Makefile | 1 + arch/arm64/boot/dts/lg/Makefile | 5 + arch/arm64/boot/dts/lg/lg1312-ref.dts | 36 ++++ arch/arm64/boot/dts/lg/lg1312.dtsi | 351 ++++++++++++++++++++++++++++++++++ 4 files changed, 393 insertions(+) commit 2d2f99451d4b32f69abd6ff59e229974e2fbe386 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Mar 25 05:50:02 2016 -0300 [media] v4l: vsp1: Fix V4L2_PIX_FMT_XRGB444 format definition The format is erroneously defined with an alpha channel. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_pipe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 99717bdfdbeaaf387ba6ecbf7eba7fbb7a47e50a Merge: 71bbe25 c156913 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 13 18:15:24 2016 -0400 Merge branch 'dsa-refactoring-set-1' Andrew Lunn says: ==================== DSA refactoring: set 1 There has been a long running effort to refractor DSA probing to make the switches true linux devices. Here are a small collection of patches moving in this direction. Most have been seen before. We take a little step forward by passing the dsa device point to the driver, thus allowing it to perform resource allocations using the normal mechanisms. This device structure will later be replaced by the devices own device structure. Future patches will add a true driver probe function, so we rename the current probe function, cleaning up the namespace. phys_port_mask continually confuses me, thinking it is about PHYs. But it is actually about ports enabled to the outside world. So rename it to enabled_port_mask. Lots more patches yet to follow, this is just doing some ground work. v2: enabled_port_mask instread of user_port_masks Added Tested-by's and Reviewed-by. ==================== Tested-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> commit 04738e7f336376f28adb6c0cad2a5788dcbc8e1d Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 24 05:15:59 2016 -0300 [media] v4l: vsp1: Add global alpha support for DRM pipeline Make the global alpha multiplier of DRM planes configurable. All the necessary infrastructure is there, we just need to store the alpha value passed through the DRM API. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 5 ++++- include/media/vsp1.h | 5 +++-- 2 files changed, 7 insertions(+), 3 deletions(-) commit c156913b5d62cbaa0e3be29409de562b7d2e006e Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:45 2016 +0200 dsa: mv88e6xxx: Use bus in mv88e6xxx_lookup_name() mv88e6xxx_lookup_name() returns the model name of a switch at a given address on an MII bus. Using mii_bus to identify the bus rather than the host device is more logical, so change the parameter. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit 74c3e2a54b7d9eb57f23fb0e157b90bb6dae629f Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:44 2016 +0200 dsa: Rename phys_port_mask to enabled_port_mask The phys in phys_port_mask suggests this mask is about PHYs. In fact, it means physical ports. Rename to enabled_port_mask, indicating external enabled ports of the switch, which is hopefully less confusing. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 19 ++++++++++--------- drivers/net/dsa/mv88e6060.c | 2 +- include/net/dsa.h | 4 ++-- net/dsa/dsa.c | 8 ++++---- 4 files changed, 17 insertions(+), 16 deletions(-) commit e49bad319630dedeeda3a638a707ec7b5d402ad5 Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:43 2016 +0200 net: dsa: Rename DSA probe function. Rename the function called from the DSA to perform a probe for the switch. This makes the normal _probe() name available for a standard Linux device driver probe function. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 7 ++++--- drivers/net/dsa/mv88e6060.c | 7 ++++--- drivers/net/dsa/mv88e6123.c | 7 ++++--- drivers/net/dsa/mv88e6131.c | 7 ++++--- drivers/net/dsa/mv88e6171.c | 7 ++++--- drivers/net/dsa/mv88e6352.c | 7 ++++--- 6 files changed, 24 insertions(+), 18 deletions(-) commit a77d43f1e9d59791b138b9903c58b89fffb0df97 Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:42 2016 +0200 net: dsa: Keep the mii bus and address in the private structure Rather than looking up the mii bus and address every time, do it once at probe, and keep it in the private structure. Centralise this probe code in mv88e6xxx. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6060.c | 44 ++++++++++++++++++++++++++------------------ drivers/net/dsa/mv88e6060.h | 11 +++++++++++ drivers/net/dsa/mv88e6123.c | 15 +++------------ drivers/net/dsa/mv88e6131.c | 15 +++------------ drivers/net/dsa/mv88e6171.c | 15 +++------------ drivers/net/dsa/mv88e6352.c | 15 +++------------ drivers/net/dsa/mv88e6xxx.c | 43 +++++++++++++++++++++++++++++-------------- drivers/net/dsa/mv88e6xxx.h | 14 +++++++++++--- 8 files changed, 89 insertions(+), 83 deletions(-) commit 5feebd0a8a799fe076c606b7c3bc267ae8c4344a Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:41 2016 +0200 net: dsa: Remove allocation of driver private memory The drivers now allocate their own memory for private usage. Remove the allocation from the core code. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/dsa.h | 1 - net/dsa/dsa.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) commit 7543a6d5359e371ce9434955dbe6a79f548ea321 Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:40 2016 +0200 net: dsa: Have the switch driver allocate there own private memory Now the switch devices have a dev pointer, make use of it for allocating the drivers private data structures using a devm_kzalloc(). Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 10 ++++++++-- drivers/net/dsa/mv88e6060.c | 3 ++- drivers/net/dsa/mv88e6123.c | 17 ++++++++++++++--- drivers/net/dsa/mv88e6131.c | 17 ++++++++++++++--- drivers/net/dsa/mv88e6171.c | 17 ++++++++++++++--- drivers/net/dsa/mv88e6352.c | 17 ++++++++++++++--- drivers/net/dsa/mv88e6xxx.c | 6 ++++-- drivers/net/dsa/mv88e6xxx.h | 3 +++ include/net/dsa.h | 10 ++++++++-- net/dsa/dsa.c | 8 +++++--- 10 files changed, 86 insertions(+), 22 deletions(-) commit bbb8d793994c894eef2a48a35fac6de3c6b4fa93 Author: Andrew Lunn <andrew@lunn.ch> Date: Wed Apr 13 02:40:39 2016 +0200 net: dsa: Pass the dsa device to the switch drivers By passing a device structure to the switch devices, it allows them to use devm_* methods for resource management. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 3 ++- drivers/net/dsa/mv88e6060.c | 3 ++- drivers/net/dsa/mv88e6123.c | 3 ++- drivers/net/dsa/mv88e6131.c | 3 ++- drivers/net/dsa/mv88e6171.c | 3 ++- drivers/net/dsa/mv88e6352.c | 3 ++- include/net/dsa.h | 3 ++- net/dsa/dsa.c | 7 ++++--- 8 files changed, 18 insertions(+), 10 deletions(-) commit f5e04e7ea7bebbed77c6438c7f007c354a40ce22 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 24 05:15:59 2016 -0300 [media] v4l: vsp1: Add Z-order support for DRM pipeline Make the Z-order of planes configurable by assigning RPFs to BRU inputs dynamically based on the Z-order position. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 180 +++++++++++++++++++------------- drivers/media/platform/vsp1/vsp1_drm.h | 12 ++- drivers/media/platform/vsp1/vsp1_pipe.c | 1 + include/media/vsp1.h | 18 +++- 4 files changed, 130 insertions(+), 81 deletions(-) commit b824a954814130995df4ca2a3266c1a3ca3de986 Author: Chanho Min <chanho.min@lge.com> Date: Mon Apr 11 20:54:45 2016 +0900 arm64: defconfig: enable ARCH_LG1K Enable building LG1K support in the defconfig. Signed-off-by: Chanho Min <chanho.min@lge.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit 198ed9625a1c8d5a8f43a4888075c048d9488dc8 Author: Chanho Min <chanho.min@lge.com> Date: Mon Apr 11 20:54:44 2016 +0900 arm64: add Kconfig entry for LG1K SoC family This patch introduces ARCH_LG1K to enable LG Electronics's LG1K SoC family in Kconfig. Signed-off-by: Chanho Min <chanho.min@lge.com> Signed-off-by: Olof Johansson <olof@lixom.net> arch/arm64/Kconfig.platforms | 5 +++++ 1 file changed, 5 insertions(+) commit 30276a731a9c14123c95070197a08bafc148f7bc Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Tue Mar 22 11:10:27 2016 -0300 [media] v4l: vsp1: Add support for the RPF alpha multiplier on Gen3 The Gen3 RPF includes an alpha multiplier that can both multiply the alpha channel by a fixed global alpha value, and multiply the pixel components to convert the input to premultiplied alpha. As alpha premultiplication is available in the BRU for both Gen2 and Gen3 we handle it there and use the Gen3 alpha multiplier for global alpha multiplication only. This prevents conversion to premultiplied alpha if no BRU is present in the pipeline, that use case will be implemented later if needed. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1.h | 1 + drivers/media/platform/vsp1/vsp1_drv.c | 8 +++++ drivers/media/platform/vsp1/vsp1_regs.h | 10 ++++++ drivers/media/platform/vsp1/vsp1_rpf.c | 57 +++++++++++++++++++++++++++++++-- 4 files changed, 73 insertions(+), 3 deletions(-) commit 0e6b9c565f33cd8b22879947647abd6c076cd73e Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 3 14:17:11 2016 -0300 [media] v4l: vsp1: lut: Use display list fragments to fill LUT Synchronize the userspace LUT setup with the pipeline operation by using a display list fragment to store LUT data. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_lut.c | 31 ++++++++++++++++++++++++++----- drivers/media/platform/vsp1/vsp1_lut.h | 6 +++++- 2 files changed, 31 insertions(+), 6 deletions(-) commit f81e83c418b0d59c036e071e11a7c143bc507781 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 3 13:36:34 2016 -0300 [media] v4l: vsp1: dl: Add support for multi-body display lists Display lists support up to 8 bodies but we currently use a single one. To support preparing display lists for large look-up tables, add support for multi-body display lists. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 289 ++++++++++++++++++++++++++++------ drivers/media/platform/vsp1/vsp1_dl.h | 8 + 2 files changed, 251 insertions(+), 46 deletions(-) commit d2c1b028db2e0b153f1aff28e3010a494c8aadc1 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 3 09:26:47 2016 -0300 [media] v4l: vsp1: dl: Fix race conditions The vsp1_dl_list_put() function expects to be called with the display list manager lock held. This assumption is correct for calls from within the vsp1_dl.c file, but not for the external calls. Fix it by taking the lock inside the function and providing an unlocked version for the internal callers. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 41 +++++++++++++++++++++++++---------- 1 file changed, 29 insertions(+), 12 deletions(-) commit b25854e134e9a28c600937ac2320d65c1530283e Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Mar 3 09:25:47 2016 -0300 [media] v4l: vsp1: dl: Make reg_count field unsigned The field takes positive values only, make it unsigned. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e2b6d7b38c8d2082bacb72a322db9e6a6216ae15 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Mon Nov 16 02:07:58 2015 -0200 [media] v4l: vsp1: Fix LUT format setting The LUT set format handler overrides the requested format by mistake. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_lut.c | 1 + 1 file changed, 1 insertion(+) commit 076e834fee91db7e9df4fe2d3ecf3ed67eadbe88 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Feb 24 20:25:42 2016 -0300 [media] v4l: vsp1: Factorize frame size enumeration code Most of the entities can't perform scaling and implement the same frame size enumeration function. Factorize the code into a single implementation. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_entity.c | 52 +++++++++++++++++++++++++++++++ drivers/media/platform/vsp1/vsp1_entity.h | 5 +++ drivers/media/platform/vsp1/vsp1_hsit.c | 32 ++----------------- drivers/media/platform/vsp1/vsp1_lif.c | 29 ++--------------- drivers/media/platform/vsp1/vsp1_lut.c | 32 ++----------------- drivers/media/platform/vsp1/vsp1_rwpf.c | 30 ++---------------- 6 files changed, 69 insertions(+), 111 deletions(-) commit c431cbbb446851ecb17095812e049119b2be17ed Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 13 19:08:55 2016 -0300 Revert "[media] v4l2-ioctl: simplify code" There are some issues rised on this patch during patch review. I ended by merging this one by mistake. So, let's revert it. This reverts commit 54ace1cfd4358fd11112f17cc711eea234d5ab9e. Cc: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-ioctl.c | 51 ++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 29 deletions(-) commit 6ad9ba9c14fad546b91d654c5b4e870d009ace28 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Feb 24 20:25:42 2016 -0300 [media] v4l: vsp1: Factorize media bus codes enumeration code Most of the entities can't perform format conversion and implement the same media bus enumeration function. Factorize the code into a single implementation. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 26 ++--------------- drivers/media/platform/vsp1/vsp1_entity.c | 46 +++++++++++++++++++++++++++++++ drivers/media/platform/vsp1/vsp1_entity.h | 4 +++ drivers/media/platform/vsp1/vsp1_lif.c | 29 ++----------------- drivers/media/platform/vsp1/vsp1_lut.c | 29 ++----------------- drivers/media/platform/vsp1/vsp1_sru.c | 29 ++----------------- drivers/media/platform/vsp1/vsp1_uds.c | 29 ++----------------- 7 files changed, 60 insertions(+), 132 deletions(-) commit 3f557220cc29d1961ef9efa2a8db04c7c5f6e6d4 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Feb 24 21:10:13 2016 -0300 [media] v4l: vsp1: Factorize get pad format code All entities implement the same get pad format handler, factorize it into a common function. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_entity.c | 25 +++++++++++++++++++++++++ drivers/media/platform/vsp1/vsp1_entity.h | 4 ++++ drivers/media/platform/vsp1/vsp1_hsit.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_lif.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_lut.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_rwpf.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_sru.c | 19 +------------------ drivers/media/platform/vsp1/vsp1_uds.c | 19 +------------------ 9 files changed, 36 insertions(+), 126 deletions(-) commit 5b22a11e0b21e7da8fcefd913688c4cfcdf08825 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Feb 24 18:40:12 2016 -0300 [media] v4l: vsp1: RPF entities can't be target nodes The RPF entities are located at the very beginning of pipelines, they can't be target nodes in the Data Path Router matrix. Remove their input ID from the routing table. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_entity.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit a0cdac5610ea900dcf6a78d4d0216aef2bca7b80 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Jan 17 19:53:56 2016 -0200 [media] v4l: vsp1: Allocate pipelines on demand Instead of embedding pipelines in the vsp1_video objects allocate them on demand when they are needed. This fixes the streamon race condition where pipelines objects from different video nodes could be used for the same pipeline. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 1 + drivers/media/platform/vsp1/vsp1_drv.c | 1 + drivers/media/platform/vsp1/vsp1_pipe.c | 1 + drivers/media/platform/vsp1/vsp1_pipe.h | 5 +- drivers/media/platform/vsp1/vsp1_rpf.c | 1 + drivers/media/platform/vsp1/vsp1_video.c | 124 +++++++++++++++++-------------- drivers/media/platform/vsp1/vsp1_video.h | 2 - drivers/media/platform/vsp1/vsp1_wpf.c | 1 + 8 files changed, 75 insertions(+), 61 deletions(-) commit 76c29755960c911b4e1bec3da90d4d5f6b44d3f3 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Jan 17 19:55:18 2016 -0200 [media] v4l: vsp1: video: Reorder functions Move the pipeline initialization and cleanup functions to prepare for the next commit. No functional code change is performed here. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_video.c | 266 +++++++++++++++---------------- 1 file changed, 133 insertions(+), 133 deletions(-) commit ff7e97c94d9f7f370fe3ce2a72e85361ca22a605 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Tue Jan 19 19:16:36 2016 -0200 [media] v4l: vsp1: Store pipeline pointer in rwpf This prepares for dynamic pipeline allocation by providing a field that can be used to store the pipeline pointer atomically under driver control. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drv.c | 4 +--- drivers/media/platform/vsp1/vsp1_pipe.c | 14 +++++++++----- drivers/media/platform/vsp1/vsp1_pipe.h | 8 -------- drivers/media/platform/vsp1/vsp1_rwpf.h | 2 ++ drivers/media/platform/vsp1/vsp1_video.c | 13 +++++++------ 5 files changed, 19 insertions(+), 22 deletions(-) commit 83dd019d308d3c1529df1c7da96c3bdb895947e4 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Jan 14 14:17:32 2016 -0200 [media] v4l: vsp1: Pass pipe pointer to entity configure functions Pass the pipe explicitly instead of retrieving it through media entities. This decouples device state stored in the pipeline from the active state stored in entities, preparing for dynamic pipeline creation. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 5 +++-- drivers/media/platform/vsp1/vsp1_drm.c | 2 +- drivers/media/platform/vsp1/vsp1_entity.h | 4 +++- drivers/media/platform/vsp1/vsp1_hsit.c | 4 +++- drivers/media/platform/vsp1/vsp1_lif.c | 4 +++- drivers/media/platform/vsp1/vsp1_lut.c | 4 +++- drivers/media/platform/vsp1/vsp1_rpf.c | 5 +++-- drivers/media/platform/vsp1/vsp1_sru.c | 4 +++- drivers/media/platform/vsp1/vsp1_uds.c | 4 +++- drivers/media/platform/vsp1/vsp1_video.c | 2 +- drivers/media/platform/vsp1/vsp1_wpf.c | 5 +++-- 11 files changed, 29 insertions(+), 14 deletions(-) commit d2219824cb4a41013292590c1b00a047f356afa4 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Tue Jan 19 19:42:56 2016 -0200 [media] v4l: vsp1: Rename pipeline validate functions to pipeline build The primary purpose of those functions is to build the pipeline, rename them to make this clearer. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_video.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 71bbe25d01fa4f35551ff7bffc3e03ddd3e960cd Merge: 7d45a04 57fbcce Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 13 17:58:51 2016 -0400 Merge tag 'mac80211-next-for-davem-2016-04-13' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next Johannes Berg says: ==================== To synchronize with Kalle, here's just a big change that affects all drivers - removing the duplicated enum ieee80211_band and replacing it by enum nl80211_band. On top of that, just a small documentation update. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 5e8dbbf372fc187de564a8aab635e2da2f7c2153 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 22 20:29:25 2015 -0200 [media] v4l: vsp1: Pass display list explicitly to configure functions Modules write register values to the active display list pointed to by the pipeline. In order to support preparing display lists ahead of time, pass them explicitly to all configuration functions. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 22 ++++++++-------- drivers/media/platform/vsp1/vsp1_drm.c | 14 +++++------ drivers/media/platform/vsp1/vsp1_entity.c | 15 +++-------- drivers/media/platform/vsp1/vsp1_entity.h | 14 +++++------ drivers/media/platform/vsp1/vsp1_hsit.c | 12 +++++---- drivers/media/platform/vsp1/vsp1_lif.c | 12 +++++---- drivers/media/platform/vsp1/vsp1_lut.c | 10 +++++--- drivers/media/platform/vsp1/vsp1_pipe.c | 3 ++- drivers/media/platform/vsp1/vsp1_pipe.h | 1 + drivers/media/platform/vsp1/vsp1_rpf.c | 39 ++++++++++++++-------------- drivers/media/platform/vsp1/vsp1_rwpf.h | 8 +++--- drivers/media/platform/vsp1/vsp1_sru.c | 14 ++++++----- drivers/media/platform/vsp1/vsp1_uds.c | 23 +++++++++-------- drivers/media/platform/vsp1/vsp1_uds.h | 3 ++- drivers/media/platform/vsp1/vsp1_video.c | 11 +++----- drivers/media/platform/vsp1/vsp1_wpf.c | 42 +++++++++++++++---------------- 16 files changed, 125 insertions(+), 118 deletions(-) commit b911605dcce9f7ebfea2e8f8833fb73782f55c22 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 22 14:08:18 2015 -0200 [media] v4l: vsp1: Use __vsp1_video_try_format to initialize format at init time Reuse the runtime logic to initialize the default format instead of open-coding it. This ensures coherency between intialization and runtime. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_video.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) commit c6c8efb656ff213a4d32776c12454b9c9f0c14e4 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 22 13:37:45 2015 -0200 [media] v4l: vsp1: Merge RPF and WPF pad ops structures The two structures are identical, merge them and move the result to vsp1_rwpf.c. All rwpf pad operations can now be declared static. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_rpf.c | 12 +------ drivers/media/platform/vsp1/vsp1_rwpf.c | 60 +++++++++++++++++++-------------- drivers/media/platform/vsp1/vsp1_rwpf.h | 19 +---------- drivers/media/platform/vsp1/vsp1_wpf.c | 12 +------ 4 files changed, 38 insertions(+), 65 deletions(-) commit 7b905f0583b2e6fe1494a85303a89aa0cd30b0b3 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Tue Nov 17 13:10:26 2015 -0200 [media] v4l: vsp1: Create a new configure operation to setup modules The subdev s_stream operation is abused as a generic way to setup modules at every frame. Move the code out to a new VSP1 entity configure operation. Most modules now have an empty s_stream operation that can be removed. The only exception is the WPF module that needs to perform hardware configuration when stopping the stream. The code can be simplified accordingly as we know that that operation never fails. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 231 ++++++++++++++---------------- drivers/media/platform/vsp1/vsp1_drm.c | 14 +- drivers/media/platform/vsp1/vsp1_entity.h | 3 + drivers/media/platform/vsp1/vsp1_hsit.c | 50 +++---- drivers/media/platform/vsp1/vsp1_lif.c | 77 +++++----- drivers/media/platform/vsp1/vsp1_lut.c | 41 +++--- drivers/media/platform/vsp1/vsp1_pipe.c | 4 +- drivers/media/platform/vsp1/vsp1_rpf.c | 83 +++++------ drivers/media/platform/vsp1/vsp1_sru.c | 91 ++++++------ drivers/media/platform/vsp1/vsp1_uds.c | 117 ++++++++------- drivers/media/platform/vsp1/vsp1_video.c | 15 +- drivers/media/platform/vsp1/vsp1_wpf.c | 168 +++++++++++----------- 12 files changed, 418 insertions(+), 476 deletions(-) commit b7e5107eebb73d27affed95c20cedbf4784bf17c Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 15 19:14:22 2015 -0200 [media] v4l: vsp1: Store active selection rectangles in a pad config structure Use the pad config structure part of the vsp1_entity to store all active pad selection rectangles. This generalizes the code to operate on pad config structures. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 24 +++++++++++------------- drivers/media/platform/vsp1/vsp1_bru.h | 1 - drivers/media/platform/vsp1/vsp1_drm.c | 5 ++--- drivers/media/platform/vsp1/vsp1_entity.c | 8 ++++++++ drivers/media/platform/vsp1/vsp1_entity.h | 4 ++++ drivers/media/platform/vsp1/vsp1_rpf.c | 20 +++++++++++++++++--- drivers/media/platform/vsp1/vsp1_rwpf.c | 22 +++++++--------------- drivers/media/platform/vsp1/vsp1_rwpf.h | 8 +++----- drivers/media/platform/vsp1/vsp1_video.c | 13 +++---------- drivers/media/platform/vsp1/vsp1_wpf.c | 4 +++- 10 files changed, 58 insertions(+), 51 deletions(-) commit e790c3cb8d904c4bad0d4a37885bece2eb848eeb Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 15 19:14:22 2015 -0200 [media] v4l: vsp1: Store active formats in a pad config structure Add a pad config structure field to the vsp1_entity structure and use it to store all active pad formats. This generalizes the code to operate on pad config structures. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 59 ++++++++++++++++++++---------- drivers/media/platform/vsp1/vsp1_entity.c | 60 ++++++++++++++++++++++-------- drivers/media/platform/vsp1/vsp1_entity.h | 8 +++- drivers/media/platform/vsp1/vsp1_hsit.c | 29 +++++++++++---- drivers/media/platform/vsp1/vsp1_lif.c | 42 +++++++++++++++------ drivers/media/platform/vsp1/vsp1_lut.c | 42 +++++++++++++++------ drivers/media/platform/vsp1/vsp1_rpf.c | 12 +++++- drivers/media/platform/vsp1/vsp1_rwpf.c | 51 +++++++++++++++++++------- drivers/media/platform/vsp1/vsp1_sru.c | 61 +++++++++++++++++++++---------- drivers/media/platform/vsp1/vsp1_uds.c | 59 ++++++++++++++++++++---------- drivers/media/platform/vsp1/vsp1_wpf.c | 12 +++++- 11 files changed, 311 insertions(+), 124 deletions(-) commit 7d45a04cbc2683f9552572850f1c711d9b96dd26 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Wed Apr 13 11:45:47 2016 -0400 tipc: remove remnants of old broadcast code We remove a couple of leftover fields in struct tipc_bearer. Those were used by the old broadcast implementation, and are not needed any longer. There is no functional changes in this commit. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/bearer.h | 15 --------------- 1 file changed, 15 deletions(-) commit 0eafc36b7bb23d8be56b73f91a474028ef3e693d Author: Tony Lindgren <tony@atomide.com> Date: Wed Apr 13 14:39:45 2016 -0700 ARM: omap2plus_defconfig: Update with make savedefconfig This shrinks the defconfig a bit and makes it easier to generate minimal patches against it. Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 61 ++++++++++++++---------------------- 1 file changed, 23 insertions(+), 38 deletions(-) commit df4b461dcce518e39136cdd7ea6d32188c85146a Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Fri Apr 8 12:11:59 2016 +0200 ARM: omap2plus_defconfig: Enable MDIO Bus/PHY emulation support MDIO Bus/PHY emulation with fixed speed/link PHYs will be used in Baltos iR5221 devices to connect to ICPlus IP175D switch IC. Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 1 + 1 file changed, 1 insertion(+) commit 73489eead20520d5de6dee3527b9a6d0435611c1 Author: Nishanth Menon <nm@ti.com> Date: Thu Mar 24 17:52:49 2016 -0500 ARM: omap2plus_defconfig: Enable DP83867 support Enable DP83867 Ethernet phy for supporting networking on DRA72-EVM rev C (SR2.0). Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 1 + 1 file changed, 1 insertion(+) commit 7e09d775e8fd2f08fe6dc92691c3fceab561074d Author: Lokesh Vutla <lokeshvutla@ti.com> Date: Wed Mar 23 09:04:14 2016 +0530 ARM: omap2plus_defconfig: Enable GPIO_TPIC2810 Enable the TI TPIC2810 8-Bit LED Driver with I2C Interface. This is used in AM335x ICEv2 Boards. Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/configs/omap2plus_defconfig | 1 + 1 file changed, 1 insertion(+) commit 814a9586fdeb8cce4f6661288fada4a6ae94a94f Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Mon Apr 4 14:55:17 2016 +0200 ARM: OMAP2+: wakeupgen: Add comment for unhandled FROZEN transitions FROZEN hotplug notifiers are not handled and do not have to be. Insert a comment to remember that the lack of the FROZEN transitions is no accident. Cc: Tony Lindgren <tony@atomide.com> Cc: Santosh Shilimkar <ssantosh@kernel.org> Cc: linux-omap@vger.kernel.org Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Acked-by: Santosh Shilimkar <ssantosh@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/omap-wakeupgen.c | 5 +++++ 1 file changed, 5 insertions(+) commit dac4fba2cd8b34e175e54e4740816a1a4de3dcc9 Author: Nishanth Menon <nm@ti.com> Date: Thu Mar 31 16:58:35 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Remove wrong OSWR capability Open Switch Retention(OSWR) is a retention state which is unsupported in DRA7 SoC. This state is achieved when power state is set to retention and logic power state is set to OFF. Even though DRA7 architecture is a OMAP derivative, none of the powerdomains are actually implemented to achieve OSWR in the SoC. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/powerdomains7xx_data.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 41feb8efd636c99ff73a2e6b8b4a57e2dd569b4b Author: Nishanth Menon <nm@ti.com> Date: Thu Mar 31 16:58:34 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Fix "ON" state for memories When the power domain is in "ON" state, the memories should be always in "ON", even though the hardware register allows other states to be written, wrong states may confuse certain hardware blocks. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/powerdomains7xx_data.c | 66 +++++++++++++++--------------- 1 file changed, 33 insertions(+), 33 deletions(-) commit f971512c78ee675c0308f1cda483a57e5de6769f Author: Nishanth Menon <nm@ti.com> Date: Thu Mar 31 16:58:33 2016 -0500 ARM: OMAP: DRA7: powerdomain data: Erratum i892 workaround: Disable core INA Erratum i892 as will be documented in the upcoming G or later revision of DRA7xx/ AM57xx errata documentation (SPRZ398F) states that L3 clock needs to be kept active all the time to ensure that asymmetric aging degradation is minimal and within the design allowed margin. By allowing core domain to transition to INA and allowing L3 clock to be turned off for extended periods of time, there is a risk of functional issues and device failure as a result. Ref: http://www.ti.com/lit/er/sprz429h/sprz429h.pdf Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/powerdomains7xx_data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60cf1d995769445d372963231ea542953dfb1f46 Merge: 390dc69 1db7f62 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 14:29:51 2016 -0700 Merge tag 'lpc18xx_dts_for_4.7' of https://github.com/manabian/linux-lpc into next/dt Device Tree additions for LPC18xx platform - CREG clock controller - Real Time Clock (RTC) - Analog peripherals (ADC/DAC) - Warning fixes for the new dtc compiler With the CREG clock controller in place it is now possible to enable the internal RTC on LPC18xx/43xx platforms. The analog peripherals (ADC/DAC) has also been added here and enabled on both the EA4357 dev kit and Hitex eval board. In addition to the new entries there are a fixes for the DT warnings generated by the new dtc. * tag 'lpc18xx_dts_for_4.7' of https://github.com/manabian/linux-lpc: dt-bindings: phy-lpc18xx-usb-otg: remove unit address from binding ARM: dts: lpc4350-hitex-eval: fix unit name warnings from dtc ARM: dts: lpc4357-ea4357: fix unit name warnings from dtc ARM: dts: lpc18xx: remove unit addresses from creg childs ARM: dts: armv7-m: add unit name to interrupt-controller ARM: dts: lpc4350-hitex-eval: add adc1 ARM: dts: lpc4357-ea4357: add dac ARM: dts: lpc4357-ea4357: add adc0 ARM: dts: lpc18xx: add dac node ARM: dts: lpc18xx: add adc nodes ARM: dts: lpc18xx: add rtc node ARM: dts: lpc18xx: add creg-clk node Signed-off-by: Olof Johansson <olof@lixom.net> commit 390dc69e225c66e7e4d64599227db43463a023c9 Merge: 16757cb dfc8a11 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 14:12:29 2016 -0700 Merge tag 'versatile-dts-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator into next/dt Versatile DTS changes, baseline for the v4.7 series: - Add CLCD panel nodes to PB1176 and PB11MPCore - Add a DT binding blurb for the Versatile IB2 syscon - Add DTS files for the (QEMU supported) RealView EB boards in all variants. - Add DTS files for the (QEMU supported) RealView PBA8 and PBX-A9 board variants. * tag 'versatile-dts-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator: ARM: dts: realview: DT support for the PBA8 and PBX-A9 ARM: dts: realview: support all the RealView EB board variants ARM: dts: realview: PB1176: define a standard VGA panel ARM: dts: realview: PB11MPCore: define a standard VGA panel Documentation/DT: add blurb for IB2 syscon to Versatile Signed-off-by: Olof Johansson <olof@lixom.net> commit d549df4b225ad2386cbf59254eab2ec116babdca Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Mar 14 11:11:42 2016 +0800 ARM: dts: rockchip: add i2c nodes for RK3228 SoCs This patch add the i2c dt nodes for rk3228 SoCs. Signed-off-by: Yakir Yang <ykk@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3228.dtsi | 80 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) commit 0efdf0f5eaaff6c18d1e645a8e1fdebf73400fe1 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 15 20:09:08 2015 -0200 [media] v4l: vsp1: Implement and use the subdev pad::init_cfg configuration Turn the custom formats initialization function into a standard pad::init_cfg handler and use it in subdevs instead of initializing formats in the subdev open handler. This makes the subdev open handler empty, so remove it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 1 + drivers/media/platform/vsp1/vsp1_entity.c | 24 ++++++------------------ drivers/media/platform/vsp1/vsp1_entity.h | 2 ++ drivers/media/platform/vsp1/vsp1_hsit.c | 1 + drivers/media/platform/vsp1/vsp1_lif.c | 1 + drivers/media/platform/vsp1/vsp1_lut.c | 1 + drivers/media/platform/vsp1/vsp1_rpf.c | 1 + drivers/media/platform/vsp1/vsp1_sru.c | 1 + drivers/media/platform/vsp1/vsp1_uds.c | 1 + drivers/media/platform/vsp1/vsp1_wpf.c | 1 + 10 files changed, 16 insertions(+), 18 deletions(-) commit 613721265ab8d3df784488e3073d92fcb466df34 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Nov 5 10:28:56 2015 -0200 [media] v4l: vsp1: Add race condition FIXME comment Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_video.c | 3 +++ 1 file changed, 3 insertions(+) commit 21b3d7365f4fa7865568823ba844ce056c1fcf9b Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 15 21:51:01 2015 -0200 [media] v4l: vsp1: Fix BRU try compose rectangle storage Fix a typo that stored the try compose rectangle in the crop rectangle. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 5243453472e7bce74764ddf9f206450dcc8769c5 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Tue Nov 17 12:23:23 2015 -0200 [media] v4l: vsp1: Consolidate entity ops in a struct vsp1_entity_operations Entities have two operations, a destroy operation stored directly in vsp1_entity and a set_memory operation stored in a vsp1_rwpf_operations structure. Move the two to a more generic vsp1_entity_operations structure that will serve to implement additional operations. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_entity.c | 4 ++-- drivers/media/platform/vsp1/vsp1_entity.h | 14 +++++++++++++- drivers/media/platform/vsp1/vsp1_rpf.c | 11 ++++++----- drivers/media/platform/vsp1/vsp1_rwpf.h | 18 ++++++------------ drivers/media/platform/vsp1/vsp1_wpf.c | 27 ++++++++++++++------------- 5 files changed, 41 insertions(+), 33 deletions(-) commit 823329dfee7224712569cc4899720bc470a2fe56 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 15 19:42:01 2015 -0200 [media] v4l: vsp1: Move subdev initialization code to vsp1_entity_init() Don't duplicate the code in every module driver, centralize it in a single place. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 18 ++---------------- drivers/media/platform/vsp1/vsp1_entity.c | 30 +++++++++++++++++++++++++----- drivers/media/platform/vsp1/vsp1_entity.h | 5 ++--- drivers/media/platform/vsp1/vsp1_hsit.c | 17 ++--------------- drivers/media/platform/vsp1/vsp1_lif.c | 16 +--------------- drivers/media/platform/vsp1/vsp1_lut.c | 16 +--------------- drivers/media/platform/vsp1/vsp1_rpf.c | 18 +++--------------- drivers/media/platform/vsp1/vsp1_sru.c | 16 +--------------- drivers/media/platform/vsp1/vsp1_uds.c | 18 +++--------------- drivers/media/platform/vsp1/vsp1_wpf.c | 18 +++--------------- 10 files changed, 43 insertions(+), 129 deletions(-) commit 4b051f925c3a924ccb6e56f1768140d7f726db7b Merge: bf16200 7fbbe38 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 13:51:14 2016 -0700 Merge tag 'versatile-cleanup-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator into next/cleanup Versatile cleanups for the v4.7 series: - Dynamically detect and print HBI numbers in SoC sysfs - Hide the unused "pmu_device" * tag 'versatile-cleanup-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator: ARM: realview: hide unused 'pmu_device' object soc: versatile: dynamically detect RealView HBI numbers Signed-off-by: Olof Johansson <olof@lixom.net> commit 351bbf99f245f4bada0edec3b0863146d71f06a9 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 15:18:56 2015 -0200 [media] v4l: vsp1: Use display lists with the userspace API Don't restrict display list usage to the DRM pipeline, use them unconditionally. This prepares the driver to support the request API. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 11 +-- drivers/media/platform/vsp1/vsp1_drm.c | 23 ++--- drivers/media/platform/vsp1/vsp1_entity.c | 5 +- drivers/media/platform/vsp1/vsp1_pipe.c | 33 +------ drivers/media/platform/vsp1/vsp1_rpf.c | 9 +- drivers/media/platform/vsp1/vsp1_rwpf.c | 26 ------ drivers/media/platform/vsp1/vsp1_rwpf.h | 18 ++-- drivers/media/platform/vsp1/vsp1_video.c | 145 +++++++++++++++++++++--------- drivers/media/platform/vsp1/vsp1_wpf.c | 18 ++-- 9 files changed, 142 insertions(+), 146 deletions(-) commit 1216198935d476e33affd104f0b4210c1fcc2477 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sat Nov 14 22:48:27 2015 -0200 [media] v4l: vsp1: Add header display list support Display lists can operate in header or headerless mode. The headerless mode is only available on WPF0, to be used with the display engine. All other WPF instances can only use display lists in header mode. Implement support for header mode to prepare for display list usage on WPFs other than 0. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 72 ++++++++++++++++++++++++++++++++-- drivers/media/platform/vsp1/vsp1_dl.h | 1 + drivers/media/platform/vsp1/vsp1_wpf.c | 2 +- 3 files changed, 70 insertions(+), 5 deletions(-) commit 41f81a5100292fcdef113f54105d0dee01dedf87 Merge: f8ed1e1 41feae7 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 13:47:19 2016 -0700 Merge tag 'renesas-simple-pm-bus-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/drivers Renesas ARM Based SoC Simple PM Bus Updates for v4.7 * Use ARCH_RENESAS in Kconfig * tag 'renesas-simple-pm-bus-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: bus: simple-pm-bus: Use ARCH_RENESAS Signed-off-by: Olof Johansson <olof@lixom.net> commit 1bd0a1bd3462f2b04f969f649875b28eaa85c97d Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 15:18:32 2015 -0200 [media] v4l: vsp1: Fix 80 characters per line violations Commit f7234138f14c ("v4l2-subdev: replace v4l2_subdev_fh by v4l2_subdev_pad_config") introduced lots of 80 characters per line violations. Fix them. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 12 ++++++++---- drivers/media/platform/vsp1/vsp1_lif.c | 6 ++++-- drivers/media/platform/vsp1/vsp1_lut.c | 6 ++++-- drivers/media/platform/vsp1/vsp1_rwpf.c | 12 ++++++++---- drivers/media/platform/vsp1/vsp1_rwpf.h | 6 ++++-- drivers/media/platform/vsp1/vsp1_sru.c | 9 ++++++--- drivers/media/platform/vsp1/vsp1_uds.c | 9 ++++++--- 7 files changed, 40 insertions(+), 20 deletions(-) commit c9e645a534744029d5d465d9b7bfae3de9123031 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 14:01:51 2015 -0200 [media] v4l: vsp1: Document calling context of vsp1_pipeline_propagate_alpha() The function can only be called from a s_stream handler as it requires a valid display list context (due to calling vsp1_uds_set_alpha() which writes to module registers). Document the requirement. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_pipe.c | 3 +++ 1 file changed, 3 insertions(+) commit 2b09ee4093e98e8eaa908554aa36a5b2ceba6e3d Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 13:54:34 2015 -0200 [media] v4l: vsp1: Remove unneeded entity streaming flag The flag is set but never read, remove it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 2 -- drivers/media/platform/vsp1/vsp1_entity.c | 23 ----------------------- drivers/media/platform/vsp1/vsp1_entity.h | 6 ------ drivers/media/platform/vsp1/vsp1_rpf.c | 2 -- drivers/media/platform/vsp1/vsp1_sru.c | 2 -- drivers/media/platform/vsp1/vsp1_wpf.c | 2 -- 6 files changed, 37 deletions(-) commit 4d346be55d415114faf19c0f79c2c15c7cc11242 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 13:48:11 2015 -0200 [media] v4l: vsp1: Don't configure RPF memory buffers before calculating offsets The RPF source memory pointers need to be offset to take the crop rectangle into account. Offsets are computed in the RPF stream start, which can happen (when using the DRM pipeline) after calling the RPF .set_memory() operation that programs the buffer addresses. The .set_memory() operation tries to guard against the problem by skipping programming of the registers when the module isn't streaming. This will however only protect the first use of an RPF in a DRM pipeline, as in all subsequent uses the module streaming flag will be set and the .set_memory() operation will use potentially incorrect offsets. Fix this by allowing the caller to decide whether to program the hardware immediately or just cache the addresses. While at it refactor the memory set code and create a new vsp1_rwpf_set_memory() that cache addresses and calls the .set_memory() operation to apply them to the hardware. As a side effect the driver now writes all three DMA address registers regardless of the number of planes, and initializes unused addresses to zero. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 7 ++++-- drivers/media/platform/vsp1/vsp1_rpf.c | 37 ++++++++++---------------------- drivers/media/platform/vsp1/vsp1_rwpf.c | 26 ++++++++++++++++++++++ drivers/media/platform/vsp1/vsp1_rwpf.h | 11 ++++++++-- drivers/media/platform/vsp1/vsp1_video.c | 9 ++++++-- drivers/media/platform/vsp1/vsp1_wpf.c | 10 ++++----- 6 files changed, 62 insertions(+), 38 deletions(-) commit 773abafe6f7b81f2ff51aaa1d137efdc54c30354 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 12:26:14 2015 -0200 [media] v4l: vsp1: Enable display list support for the HS[IT], LUT, SRU and UDS Those modules were left out of display list integration as they're not used by the DRM pipeline. To prepare for display list support in non-DRM pipelines use the module write API to set registers. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_hsit.c | 2 +- drivers/media/platform/vsp1/vsp1_lut.c | 2 +- drivers/media/platform/vsp1/vsp1_sru.c | 2 +- drivers/media/platform/vsp1/vsp1_uds.c | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) commit 59d0b2bf1d8de62d3ee8cce5c5b9463608095642 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 12:58:29 2015 -0200 [media] v4l: vsp1: Don't setup control handler when starting streaming The control handler set operations don't program the hardware anymore, there's thus no need to call them when starting the stream. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 5 +---- drivers/media/platform/vsp1/vsp1_entity.c | 18 +----------------- drivers/media/platform/vsp1/vsp1_entity.h | 2 +- drivers/media/platform/vsp1/vsp1_rpf.c | 5 +---- drivers/media/platform/vsp1/vsp1_sru.c | 5 +---- drivers/media/platform/vsp1/vsp1_wpf.c | 5 +---- 6 files changed, 6 insertions(+), 34 deletions(-) commit d884a8b2a5dc2fad784a60f356d1d8d90cecb436 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 12:19:42 2015 -0200 [media] v4l: vsp1: sru: Don't program intensity in control set handler The datasheet clearly states that all but a few registers can't be modified when the device is running. Programming the intensity parameters in the control set handler is thus prohibited. Program it when starting the module instead. This requires storing the intensity value internally as the module can be started from the frame completion interrupt handler, and accessing control values requires taking a mutex. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_sru.c | 35 +++++++++------------------------- drivers/media/platform/vsp1/vsp1_sru.h | 2 ++ 2 files changed, 11 insertions(+), 26 deletions(-) commit bd2fdd5aa919e3cb750147c9270034f11d106d94 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 12:19:42 2015 -0200 [media] v4l: vsp1: rwpf: Don't program alpha value in control set handler The datasheet clearly states that all but a few registers can't be modified when the device is running. Programming the alpha value in the control set handler is thus prohibited. Program it when starting the module instead. This requires storing the alpha value internally as the module can be started from the frame completion interrupt handler, and accessing control values requires taking a mutex. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_rpf.c | 51 +++--------------------------- drivers/media/platform/vsp1/vsp1_rwpf.c | 35 +++++++++++++++++++++ drivers/media/platform/vsp1/vsp1_rwpf.h | 5 ++- drivers/media/platform/vsp1/vsp1_wpf.c | 55 ++------------------------------- 4 files changed, 47 insertions(+), 99 deletions(-) commit 5fb2107346cfc6d8fe62117a2cbf91fc1f92cc84 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 13 17:40:48 2016 -0300 [media] vsp1: make vsp1_drm_frame_end static As reported by smatch: drivers/media/platform/vsp1/vsp1_drm.c:39:6: warning: no previous prototype for 'vsp1_drm_frame_end' [-Wmissing-prototypes] void vsp1_drm_frame_end(struct vsp1_pipeline *pipe) Fixes: ef9621bcd664 ("[media] v4l: vsp1: Store the display list manager in the WPF") Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f22af945f79a2bd68941efdb57d52e8d81db4d45 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 12:19:42 2015 -0200 [media] v4l: vsp1: bru: Don't program background color in control set handler The datasheet clearly states that all but a few registers can't be modified when the device is running. Programming the background color in the control set handler is thus prohibited. Program it when starting the module instead. This requires storing the background color value internally as the module can be started from the frame completion interrupt handler, and accessing control values requires taking a mutex. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_bru.c | 15 +++++++++------ drivers/media/platform/vsp1/vsp1_bru.h | 2 ++ 2 files changed, 11 insertions(+), 6 deletions(-) commit ef9621bcd6640d48834ec9315dae06e9d7cb5283 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sat Nov 14 22:27:52 2015 -0200 [media] v4l: vsp1: Store the display list manager in the WPF Each WPF can process display lists independently, move the manager to the WPF to reflect that and prepare for display list support for non-DRM pipelines. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 37 ++++++++++++++++++++++++++----- drivers/media/platform/vsp1/vsp1_dl.h | 26 ++++------------------ drivers/media/platform/vsp1/vsp1_drm.c | 19 +++++++--------- drivers/media/platform/vsp1/vsp1_drm.h | 8 +------ drivers/media/platform/vsp1/vsp1_entity.c | 2 ++ drivers/media/platform/vsp1/vsp1_entity.h | 2 ++ drivers/media/platform/vsp1/vsp1_rwpf.h | 3 +++ drivers/media/platform/vsp1/vsp1_wpf.c | 18 +++++++++++++++ 8 files changed, 70 insertions(+), 45 deletions(-) commit c2dd2513ea7aafe5cca2460aecaf83cb46128faf Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 8 20:06:57 2015 -0200 [media] v4l: vsp1: Split display list manager from display list This clarifies the API and prepares display list support for being used to implement the request API. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1.h | 1 - drivers/media/platform/vsp1/vsp1_dl.c | 263 ++++++++++++++---------------- drivers/media/platform/vsp1/vsp1_dl.h | 40 +++-- drivers/media/platform/vsp1/vsp1_drm.c | 32 ++-- drivers/media/platform/vsp1/vsp1_drm.h | 12 +- drivers/media/platform/vsp1/vsp1_drv.c | 11 +- drivers/media/platform/vsp1/vsp1_entity.c | 2 +- drivers/media/platform/vsp1/vsp1_pipe.c | 13 +- drivers/media/platform/vsp1/vsp1_pipe.h | 5 +- 9 files changed, 193 insertions(+), 186 deletions(-) commit f9df34f8cd0da731f65728480fe2e669391adbd0 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sat Nov 14 16:33:40 2015 -0200 [media] v4l: vsp1: Simplify frame end processing The DRM pipeline, as it runs in automatic restart mode, never sees the pipeline state set to VSP1_PIPELINE_STOPPING or VSP1_PIPELINE_STOPPED when running the frame end interrupt handler. We can thus skip the checks various checks in the handler and return immediately. Similarly the DRM frame end handler calls vsp1_pipeline_run() unnecessarily, as the state there is never VSP1_PIPELINE_STOPPED. Remove the function call and the frame end handler is it's now empty. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 15 --------------- drivers/media/platform/vsp1/vsp1_pipe.c | 9 ++++++--- 2 files changed, 6 insertions(+), 18 deletions(-) commit 7939fef4d3911695c78cb067f1e4c16056a9f113 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 10:53:22 2015 -0200 [media] v4l: vsp1: Always setup the display list Make sure display list usage is correctly disabled by always setting up the corresponding registers, including when the display list feature isn't used. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_dl.c | 7 +++---- drivers/media/platform/vsp1/vsp1_drv.c | 3 +-- 2 files changed, 4 insertions(+), 6 deletions(-) commit aa380ea0c54e491f7f31e8180514766dd3e6cd91 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Nov 1 10:46:25 2015 -0200 [media] v4l: vsp1: Use pipeline display list to decide how to write to modules This allows getting rid of the vsp1_device::use_dl field. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1.h | 12 ------------ drivers/media/platform/vsp1/vsp1_dl.c | 5 +---- drivers/media/platform/vsp1/vsp1_dl.h | 12 ++---------- drivers/media/platform/vsp1/vsp1_drv.c | 9 +++------ drivers/media/platform/vsp1/vsp1_entity.c | 12 ++++++++++++ drivers/media/platform/vsp1/vsp1_entity.h | 2 ++ 6 files changed, 20 insertions(+), 32 deletions(-) commit 94d48e56d388f60d045f41749f89ba385f107d69 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Thu Feb 11 19:32:00 2016 -0200 [media] v4l: vsp1: VSPD instances have no LUT on Gen3 Remove the HAS_LUT flag in the corresponding device information entry. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6b1446bc7c89025e07037f9c238a60b6fbe3c207 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Sun Feb 28 23:28:38 2016 -0300 [media] v4l: vsp1: video: Fix coding style Commit 54b5a749b4f3 ("[media] v4l: vsp1: Use media entity enumeration interface") wasn't aligned with the driver coding style. Fix it by renaming the rval variable to ret. Furthermore shorten lines by accessing the media_device instance in a more straightforward fashion. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_video.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) commit c1741af7d1d0f2f9d748939678c4d4cc33783069 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Feb 19 23:13:45 2016 -0200 [media] v4l: vsp1: drm: Include correct header file The VSP1 DRM API is declared in <media/vsp1.h>, not <linux/vsp1.h>. Fix it. This also reverts commit 18922936dc28 ("[media] vsp1_drm.h: add missing prototypes") that added the same declarations in a different header file. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vsp1/vsp1_drm.c | 2 +- drivers/media/platform/vsp1/vsp1_drm.h | 11 ----------- 2 files changed, 1 insertion(+), 12 deletions(-) commit fa369c9366c1c695a02ccd88abd76d7f68162810 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Feb 19 23:12:26 2016 -0200 [media] v4l: vsp1: Fix vsp1_du_atomic_(begin|flush) declarations The functions are void, make the declaration match the definition. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/media/vsp1.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9b02cbb3ede89b5cd84bbe4ef493bd130d76b070 Author: Laurent Pinchart <laurent.pinchart@linaro.org> Date: Fri Apr 24 20:06:31 2015 -0300 [media] v4l: subdev: Add pad config allocator and init Add a new subdev operation to initialize a subdev pad config array, and a helper function to allocate and initialize the array. This can be used by bridge drivers to implement try format based on subdev pad operations. Signed-off-by: Laurent Pinchart <laurent.pinchart@linaro.org> Acked-by: Vaibhav Hiremath <vaibhav.hiremath@linaro.org> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-subdev.c | 39 +++++++++++++++++++++++++++++++---- include/media/v4l2-subdev.h | 8 +++++++ 2 files changed, 43 insertions(+), 4 deletions(-) commit e60ba933bc94b778425612c039a16b3acd4bf756 Author: Jonas Rabenstein <jonas.rabenstein@studium.uni-erlangen.de> Date: Wed Apr 6 10:14:08 2016 +0200 ARM: OMAP2+: remove redundant multiplatform checks The directory arch/arm/mach-omap2 is only selected for compilation if CONFIG_ARCH_OMAP2PLUS is selected. CONFIG_ARCH_OMAP2PLUS itself is a silent option and all machines selecting this option are multiplatform devices. As a consequence checks for CONFIG_ARCH_MULTIPLATFORM as well as CONFIG_ARCH_OMAP2PLUS within that directory are superfluous and can be removed. Signed-off-by: Jonas Rabenstein <jonas.rabenstein@studium.uni-erlangen.de> Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/mach-omap2/Makefile | 2 +- arch/arm/mach-omap2/soc.h | 140 +++++++------------------------------------ 2 files changed, 22 insertions(+), 120 deletions(-) commit 45b46879a785678e08953c8f97df945bf634e472 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Mon Feb 29 08:45:45 2016 -0300 [media] media: Rename is_media_entity_v4l2_io to is_media_entity_v4l2_video_device All users of is_media_entity_v4l2_io() (the exynos4-is, omap3isp, davince_vpfe and omap4iss drivers and the v4l2-mc power management code) use the function to check whether entities are video_device instances, either to ensure they can cast the entity to a struct video_device, or to count the number of video nodes users. The purpose of the function is thus to identify whether the media entity instance is an instance of the video_device object, not to check whether it can perform I/O. Rename it accordingly, we will introduce a more specific is_media_entity_v4l2_io() check when needed. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos4-is/media-dev.c | 4 ++-- drivers/media/platform/omap3isp/ispvideo.c | 2 +- drivers/media/v4l2-core/v4l2-mc.c | 2 +- drivers/staging/media/davinci_vpfe/vpfe_video.c | 2 +- drivers/staging/media/omap4iss/iss_video.c | 2 +- include/media/media-entity.h | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-) commit b76a2a8cb6f6d9da711305d805156b40c698e94f Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Mon Feb 29 08:45:44 2016 -0300 [media] media: Add obj_type field to struct media_entity Code that processes media entities can require knowledge of the structure type that embeds a particular media entity instance in order to cast the entity to the proper object type. This needs is shown by the presence of the is_media_entity_v4l2_io and is_media_entity_v4l2_subdev functions. The implementation of those two functions relies on the entity function field, which is both a wrong and an inefficient design, without even mentioning the maintenance issue involved in updating the functions every time a new entity function is added. Fix this by adding add an obj_type field to the media entity structure to carry the information. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-dev.c | 1 + drivers/media/v4l2-core/v4l2-subdev.c | 1 + include/media/media-entity.h | 76 ++++++++++++++++++----------------- 3 files changed, 41 insertions(+), 37 deletions(-) commit 1d260123cb5c88574de9b5147eddc243f83b77a8 Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 14 21:40:27 2016 -0300 [media] soc_camera: rcar_vin: add device tree support for r8a7792 Simply document new compatibility string. As a previous patch adds a generic R-Car Gen2 compatibility string there appears to be no need for a driver updates. By documenting this compat string it may be used in DTSs shipped, for example as part of ROMs. It must be used in conjunction with the Gen2 fallback compat string. At this time there are no known differences between the r8a7792 IP block and that implemented by the driver for the Gen2 fallback compat string. Thus there is no need to update the driver as the use of the Gen2 fallback compat string will activate the correct code in the current driver while leaving the option for r8a7792-specific driver code to be activated in an updated driver should the need arise. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/devicetree/bindings/media/rcar_vin.txt | 1 + 1 file changed, 1 insertion(+) commit bd546882ff3476718d6df872c1c95aedcc5ed37d Author: Yoshihiro Kaneko <ykaneko0929@gmail.com> Date: Mon Mar 14 21:40:26 2016 -0300 [media] soc_camera: rcar_vin: add R-Car Gen 2 and 3 fallback compatibility strings Add fallback compatibility string for R-Car Gen 1 and 2. In the case of Renesas R-Car hardware we know that there are generations of SoCs, e.g. Gen 2 and 3. But beyond that it's unclear what the relationship between IP blocks might be. For example, I believe that r8a7790 is older than r8a7791 but that doesn't imply that the latter is a descendant of the former or vice versa. We can, however, by examining the documentation and behaviour of the hardware at run-time observe that the current driver implementation appears to be compatible with the IP blocks on SoCs within a given generation. For the above reasons and convenience when enabling new SoCs a per-generation fallback compatibility string scheme being adopted for drivers for Renesas SoCs. Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/devicetree/bindings/media/rcar_vin.txt | 11 +++++++++-- drivers/media/platform/soc_camera/rcar_vin.c | 2 ++ 2 files changed, 11 insertions(+), 2 deletions(-) commit 345900be580b52d6993d262ca7052cf9d449ba6c Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 7 22:03:58 2016 -0300 [media] sh_mobile_ceu_camera: Remove dependency on SUPERH A dependency on ARCH_SHMOBILE seems to be the best option for sh_mobile_ceu_camera: * For Super H based SoCs: sh_mobile_ceu is used on SH_AP325RXA, SH_ECOVEC, SH_KFR2R09, SH_MIGOR, and SH_7724_SOLUTION_ENGINE which depend on CPU_SUBTYPE_SH7722, CPU_SUBTYPE_SH7723, or CPU_SUBTYPE_SH7724 which all select ARCH_SHMOBILE. * For ARM Based SoCs: Since the removal of legacy (non-multiplatform) support this driver has not been used by any Renesas ARM based SoCs. The Renesas ARM based SoCs currently select ARCH_SHMOBILE, however, it is planned that this will no longer be the case. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Thanks to Geert Uytterhoeven for analysis and portions of the change log text. Cc: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/soc_camera/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f343f8484aa9a925b9536b676633af1b9604553e Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Mar 7 22:03:55 2016 -0300 [media] rcar_vin: Use ARCH_RENESAS Make use of ARCH_RENESAS in place of ARCH_SHMOBILE. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/soc_camera/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 20674818c4a32ad1bfb1ea798e8c1fbed338ad71 Author: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Date: Wed Apr 6 00:26:56 2016 -0300 [media] au0828: remove unused macro An V4L2_CID_PRIVATE_SHARPNESS macro is defined in the au0828 driver, but never used. Remove it. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/au0828/au0828.h | 1 - 1 file changed, 1 deletion(-) commit cc7666a3948c6a554fa4c39b4fb4ccbdbdce1343 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Mar 15 04:07:10 2016 -0300 [media] m5mols: potential uninitialized variable Smatch complains that there are some paths where "status" isn't initialized. The code does assume that m5mols_read_u8() can fail so it seems as if Smatch is correct. Let's initialize it to REG_ISO_AUTO which is zero. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/i2c/m5mols/m5mols_controls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60587bd0680507f48ae3a7360983228fd207de8a Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Mar 15 04:05:20 2016 -0300 [media] cx23885: uninitialized variable in cx23885_av_work_handler() The "handled" variable could be uninitialized if the interrupt_service_routine() call back hasn't been implimented or if it has been implemented but doesn't initialize "handled" to zero at the start. For example, adv76xx_isr() only sets "handled" to true. Fixes: 44b153ca639f ('[media] m5mols: Add ISO sensitivity controls') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/cx23885/cx23885-av.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e4bccada44c177cde31b9a236b7dfd7f76d403ed Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Mar 15 04:04:12 2016 -0300 [media] am437x-vpfe: fix an uninitialized variable bug If we are doing V4L2_FIELD_NONE then "ret" is used uninitialized. Fixes: 417d2e507edc ('[media] media: platform: add VPFE capture driver support for AM437X') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/am437x/am437x-vpfe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0fb504001192c1df62c847a8bb6558753c36ebef Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Mar 14 19:40:08 2016 -0300 [media] am437x-vfpe: fix typo in vpfe_get_app_input_index gcc-6 points out an obviously silly comparison in vpfe_get_app_input_index(): drivers/media/platform/am437x/am437x-vpfe.c: In function 'vpfe_get_app_input_index': drivers/media/platform/am437x/am437x-vpfe.c:1709:27: warning: self-comparison always evaluats to true [-Wtautological-compare] client->adapter->nr == client->adapter->nr) { ^~ This was introduced in a slighly incorrect conversion, and it's clear that the comparison was meant to compare the iterator to the current subdev instead, as we do in the line above. Fixes: d37232390fd4 ("[media] media: am437x-vpfe: match the OF node/i2c addr instead of name") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/am437x/am437x-vpfe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c16352b5b35d8f619028ebf855ce42c1f99649e6 Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Mar 14 19:40:07 2016 -0300 [media] cobalt: add MTD dependency The cobalt driver fails to link when it is built-in and MTD is disabled or a loadable module: drivers/media/built-in.o: In function `cobalt_flash_probe': :(.text+0xb8b46): undefined reference to `mtd_device_parse_register' :(.text+0xb8b88): undefined reference to `do_map_probe' drivers/media/built-in.o: In function `cobalt_flash_remove': :(.text+0xb8bb4): undefined reference to `mtd_device_unregister' :(.text+0xb8bbe): undefined reference to `map_destroy' This adds a Kconfig dependency to ensure we can call the API. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/pci/cobalt/Kconfig | 1 + 1 file changed, 1 insertion(+) commit baf43c6eace43868e490f18560287fa3481b2159 Author: Tiffany Lin <tiffany.lin@mediatek.com> Date: Mon Mar 14 08:16:14 2016 -0300 [media] media: v4l2-compat-ioctl32: fix missing reserved field copy in put_v4l2_create32 In v4l2-compliance utility, test VIDIOC_CREATE_BUFS will check whether reserved filed of v4l2_create_buffers filled with zero Reserved field is filled with zero in v4l_create_bufs. This patch copy reserved field of v4l2_create_buffer from kernel space to user space Signed-off-by: Tiffany Lin <tiffany.lin@mediatek.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Cc: <stable@vger.kernel.org> # for v3.19 and up Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-compat-ioctl32.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 2a518f8e87a718b482a5ac7ffa9590cc7d86004f Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Mon Mar 7 07:26:55 2016 -0300 [media] dw2102: fix unreleased firmware On the particular case when the product id is 0x2101 we have requested for a firmware but after processing it we missed releasing it. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/dvb-usb/dw2102.c | 3 +++ 1 file changed, 3 insertions(+) commit ccc5429f7bf9c78d64f1bb03c578f1641ca72fe4 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 13 17:02:20 2016 -0300 [media] cx231xx: return proper error codes at cx231xx-417.c Instead of returning -1, return valid error codes. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/cx231xx/cx231xx-417.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 1254880834d08ad288b9706b5bd791dc11516e40 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Mon Mar 7 07:22:23 2016 -0300 [media] cx231xx: fix memory leak When we returned on error we missed freeing p_current_fw and p_buffer. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/cx231xx/cx231xx-417.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 54ace1cfd4358fd11112f17cc711eea234d5ab9e Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Mon Feb 29 07:16:39 2016 -0300 [media] v4l2-ioctl: simplify code Instead of a big if at the beginning, just check if g_selection == NULL and call the cropcap op immediately and return the result. No functional changes in this patch. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-ioctl.c | 51 ++++++++++++++++++++---------------- 1 file changed, 29 insertions(+), 22 deletions(-) commit 9765a32cd802709d152a0d73d0cbfd07c9f49808 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 1 11:57:25 2016 -0300 [media] vivid: set device_caps in video_device This simplifies the querycap function. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/vivid/vivid-core.c | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) commit 3e43cb33f637d77405ccddc81a6d76acd57ff71c Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 1 11:57:24 2016 -0300 [media] v4l2-pci-skeleton.c: fill in device_caps in video_device With the new core support for the caps the driver no longer needs to set device_caps and capabilities in the querycap call. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Documentation/video4linux/v4l2-pci-skeleton.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 7bbe7813290df9fda0c175b7a703325720594912 Author: Hans Verkuil <hans.verkuil@cisco.com> Date: Tue Mar 1 11:57:23 2016 -0300 [media] v4l2: add device_caps to struct video_device Instead of letting drivers fill in device_caps at querycap time, let them fill it in when the video device is registered. This has the advantage that in the future the v4l2 core can access the video device's capabilities and take decisions based on that. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/v4l2-core/v4l2-ioctl.c | 3 +++ include/media/v4l2-dev.h | 3 +++ 2 files changed, 6 insertions(+) commit c888a8f95ae5b1067855235b3b71c1ebccf504f5 Author: Jens Axboe <axboe@fb.com> Date: Wed Apr 13 13:33:19 2016 -0600 block: kill off q->flush_flags Now that we converted everything to the newer block write cache interface, kill off the queue flush_flags and queueable flush entries. Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-core.c | 3 ++- block/blk-flush.c | 11 ++++++----- block/blk-settings.c | 18 ++++++++++-------- drivers/block/xen-blkback/xenbus.c | 2 +- drivers/md/dm-table.c | 12 ++++++------ drivers/md/raid5-cache.c | 3 ++- drivers/target/target_core_iblock.c | 6 +++--- include/linux/blkdev.h | 5 ++--- 8 files changed, 32 insertions(+), 28 deletions(-) commit 26a7ed9c18193dc7a3dfba33e3c711822f4bdd29 Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Apr 13 16:29:31 2016 -0300 [media] exynos-gsc: remove an always false condition As reported by smatch: drivers/media/platform/exynos-gsc/gsc-core.c:1073 gsc_probe() warn: impossible condition '(gsc->id < 0) => (0-65535 < 0)' drivers/media/platform/exynos-gsc/gsc-core.c: In function 'gsc_probe': drivers/media/platform/exynos-gsc/gsc-core.c:1073:51: warning: comparison is always false due to limited range of data type [-Wtype-limits] if (gsc->id >= drv_data->num_entities || gsc->id < 0) { ^ gsc->id is an u16, so it can never be a negative number. So, remove the always false condition. Fixes: c1ac057173ba "[media] exynos-gsc: remove non-device-tree init code" Cc: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos-gsc/gsc-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit adbedc29524a31cc6196d991acc04ee797abc11b Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sun Nov 15 18:08:23 2015 -0200 [media] s5p-tv: constify mxr_layer_ops structures The mxr_layer_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/s5p-tv/mixer.h | 2 +- drivers/media/platform/s5p-tv/mixer_grp_layer.c | 2 +- drivers/media/platform/s5p-tv/mixer_video.c | 2 +- drivers/media/platform/s5p-tv/mixer_vp_layer.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 4c9c6d86d190caa00028dcb3e9864e57aa9a1df6 Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Dec 9 12:00:16 2015 -0200 [media] exynos4-is: remove non-device-tree init code Exynos and Samsung S5P platforms has been fully converted to device tree, so old platform device based init data can be now removed. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos4-is/fimc-core.c | 50 --------------------------- 1 file changed, 50 deletions(-) commit ed3e34ed828c00ac7eafd24079d90a8fabcf07cc Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Dec 9 12:00:15 2015 -0200 [media] s5p-mfc: remove non-device-tree init code Exynos and Samsung S5P platforms has been fully converted to device tree, so old platform device based init data can be now removed. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/s5p-mfc/s5p_mfc.c | 37 +++++--------------------------- 1 file changed, 5 insertions(+), 32 deletions(-) commit ef3617c4b887a9b176210b4b80c0fe964cbe8c2a Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Dec 9 12:00:14 2015 -0200 [media] s5p-g2d: remove non-device-tree init code Exynos and Samsung S5P platforms has been fully converted to device tree, so old platform device based init data can be now removed. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/s5p-g2d/g2d.c | 27 +++++---------------------- drivers/media/platform/s5p-g2d/g2d.h | 5 ----- 2 files changed, 5 insertions(+), 27 deletions(-) commit c1ac057173ba674d93afc8ddc5c91da1c61a951a Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Wed Dec 9 12:00:13 2015 -0200 [media] exynos-gsc: remove non-device-tree init code Exynos platform has been fully converted to device tree, so old platform device based init data can be now removed. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos-gsc/gsc-core.c | 33 +++++----------------------- drivers/media/platform/exynos-gsc/gsc-core.h | 1 - 2 files changed, 6 insertions(+), 28 deletions(-) commit 77401dd7394c5d7b593718361ac6bb8f1aa4db62 Author: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Date: Tue Dec 8 12:39:08 2015 -0200 [media] s5p-jpeg: Adjust buffer size for Exynos 4412 Eliminate iommu fault during encoding by adjusting image size used for buffer size computation and ensuring that the buffer is not overrun. Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/s5p-jpeg/jpeg-core.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 5790a1589f746d5648825d3bc8367f0ce7b12784 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Mar 4 17:20:12 2016 -0300 [media] exynos4-is: Put node before s5pcsis_parse_dt() return error The MIPI CSIS DT parse function return an -ENXIO errno if the port # is outside of the supported values. But it doesn't call of_node_put() to decrement the node's reference counter, that's incremented inside the of_graph_get_next_endpoint() function that was called before. Instead of just returning, go to the error path that already does it. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos4-is/mipi-csis.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 7e8da343a31623decc7fd0ee66700ba50260aca7 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Jan 25 22:41:46 2016 -0200 [media] exynos4-is: Add missing port parent of_node_put on error paths In fimc_md_parse_port_node() remote port parent node is acquired with of_graph_get_remote_port_parent() but it is not put on error path. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/platform/exynos4-is/media-dev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 3d217ef6ca4e2afe7384ab7ead10a4f6719abe3c Merge: bf16200 352486b Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 12:17:12 2016 -0700 Merge tag 'renesas-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/defconfig Renesas ARM Based SoC Defconfig Updates for v4.7 * Enable I2C demultiplexer and slave eeprom in shmobile and multi_v7defconfigs * tag 'renesas-defconfig-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: ARM: shmobile: defconfig: enable I2C demultiplexer and slave eeprom ARM: multi_v7_defconfig: enable I2C demultiplexer and slave eeprom Signed-off-by: Olof Johansson <olof@lixom.net> commit 16757cbcd4ab1475bdfecdb4019487c92cc449ce Merge: e43b7be 000025c Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 12:15:09 2016 -0700 Merge tag 'renesas-cleanup-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Renesas ARM Based SoC Cleanup for v4.7 * Remove unnecessary clock-output-names properties from DT * Use generic pinctrl properties in DT * tag 'renesas-cleanup-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: (26 commits) ARM: dts: sh73a0: Remove unnecessary clock-output-names properties ARM: dts: r8a73a4: Remove unnecessary clock-output-names properties ARM: dts: lager: Remove unnecessary clock-output-names properties ARM: dts: porter: Remove unnecessary clock-output-names properties ARM: dts: koelsch: Remove unnecessary clock-output-names properties ARM: dts: gose: Remove unnecessary clock-output-names properties ARM: dts: r8a7794: Remove unnecessary clock-output-names properties ARM: dts: r8a7793: Remove unnecessary clock-output-names properties ARM: dts: r8a7791: Remove unnecessary clock-output-names properties ARM: dts: r8a7779: Remove unnecessary clock-output-names properties ARM: dts: r8a7778: Remove unnecessary clock-output-names properties ARM: dts: r8a7740: Remove unnecessary clock-output-names properties ARM: dts: r7s72100: Remove unnecessary clock-output-names properties ARM: dts: r8a7790: Remove unnecessary clock-output-names properties ARM: dts: kzm9d: use generic pinctrl properties ARM: dts: kzm9g: use generic pinctrl properties ARM: dts: silk: use generic pinctrl properties ARM: dts: alt: use generic pinctrl properties ARM: dts: gose: use generic pinctrl properties ARM: dts: porter: use generic pinctrl properties ... Signed-off-by: Olof Johansson <olof@lixom.net> commit e43b7befc986fbadc84854854f8f22a4bffefb51 Merge: 0bab735 81ae0ac Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 12:13:43 2016 -0700 Merge tag 'renesas-arm64-dt-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt Renesas ARM64 Based SoC DT Updates for v4.7 * Use USB3.0 fallback compatibility string in DT for r8a7795 SoC * Add CAN support to DT for r8a7795 SoC * tag 'renesas-arm64-dt-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: arm64: dts: r8a7795: Use USB3.0 fallback compatibility string arm64: dts: r8a7795: Add CAN support arm64: dts: r8a7795: Add CAN external clock support Signed-off-by: Olof Johansson <olof@lixom.net> commit 8010f13a40d3920d30c824e4b3ee0c6d298a7a8a Author: Tero Kristo <t-kristo@ti.com> Date: Wed Mar 16 21:54:57 2016 +0200 ARM: dts: am43xx: add support for clkout1 clock clkout1 clock node and its generation tree was missing. Add this based on the data on TRM and PRCM functional spec. Signed-off-by: Tero Kristo <t-kristo@ti.com> Tested-by: Benoit Parrot <bparrot@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am43xx-clocks.dtsi | 54 ++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) commit 49695dfac7e3c71d3fa155d07503d3093d930f23 Merge: be0b070 fa3d2ae Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 12:00:41 2016 -0700 Merge tag 'renesas-arm64-cleanup-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/dt64 Renesas ARM64 Based SoC Cleanup for v4.7 * Use generic pinctrl properties in DT for salvator-x board * tag 'renesas-arm64-cleanup-for-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas: arm64: dts: salvator-x: use generic pinctrl properties Signed-off-by: Olof Johansson <olof@lixom.net> commit c5ab6ad7f627f031e2bbde575c7e6e27ea36da55 Merge: 31d50c5 59247e3 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 20:27:58 2016 +0200 Merge tag 'perf-core-for-mingo-20160413' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Print callchains asked for events requested via 'perf trace --event' too: (Arnaldo Carvalho de Melo) # trace -e nanosleep --call dwarf --event sched:sched_switch/call-graph=fp/ usleep 1 0.346 (0.005 ms): usleep/24428 nanosleep(rqtp: 0x7fffa15a0540) ... 0.346 ( ): sched:sched_switch:usleep:24428 [120] S ==> swapper/3:0 [120]) __schedule+0xfe200402 ([kernel.kallsyms]) schedule+0xfe200035 ([kernel.kallsyms]) do_nanosleep+0xfe20006f ([kernel.kallsyms]) hrtimer_nanosleep+0xfe2000dc ([kernel.kallsyms]) sys_nanosleep+0xfe20007a ([kernel.kallsyms]) do_syscall_64+0xfe200062 ([kernel.kallsyms]) return_from_SYSCALL_64+0xfe200000 ([kernel.kallsyms]) __nanosleep+0xffff005b8d602010 (/usr/lib64/libc-2.22.so) 0.400 (0.059 ms): usleep/24428 ... [continued]: nanosleep()) = 0 __nanosleep+0x10 (/usr/lib64/libc-2.22.so) usleep+0x34 (/usr/lib64/libc-2.22.so) main+0x1eb (/usr/bin/usleep) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) _start+0x29 (/usr/bin/usleep) - Allow requesting that some CPUs or PIDs be highlighted in 'perf sched map' (Jiri Olsa) - Compact 'perf sched map' to show just CPUs with activity, improving the output in high core count systems (Jiri Olsa) - Fix segfault with 'perf trace --no-syscalls -e syscall-names' by bailing out such request, doesn't make sense to ask for no syscalls and then specify which ones should be printed (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit f8ed1e1a452645241a7fb6410fb462dcac869311 Merge: f639683 773fe726 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 11:11:11 2016 -0700 Merge tag 'reset-for-4.7' of git://git.pengutronix.de/git/pza/linux into next/drivers Reset controller changes for v4.7 - add support for shared reset controls - remove global variables from the lpc18xx driver * tag 'reset-for-4.7' of git://git.pengutronix.de/git/pza/linux: reset: lpc18xx: get rid of global variables for restart notifier reset: Add support for shared reset controls reset: Share struct reset_control between reset_control_get calls reset: Make [of_]reset_control_get[_foo] functions wrappers Signed-off-by: Olof Johansson <olof@lixom.net> commit f6396838bdb3766d291abd7dd8d2efbaa23c8cf7 Merge: bf16200 028021d Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 10:56:40 2016 -0700 Merge tag 'qcom-soc-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux into next/drivers Qualcomm ARM Based SoC Updates for v4.7 * Add stubs for smem_state to fix build issues * Fix module usage in SPM driver * Add i2c and spi entries into QCOM MAINTAINERS entry * Add SMD multi channel support * Add clks to QCOM MAINTAINERS * tag 'qcom-soc-for-4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux: soc: qcom: smd: Support opening additional channels soc: qcom: smd: Support multiple channels per sdev soc: qcom: smd: Refactor channel open and close handling soc: qcom: smd: Split discovery and state change work soc: qcom: smd: Introduce callback setter drivers: qcom: spm: avoid module usage in non-modular SPM driver soc: qcom: smem_state: Add stubs for disabled smem_state MAINTAINERS: add qcom clocks to the maintainers list MAINTAINERS: add qcom i2c and spi drivers to list Signed-off-by: Olof Johansson <olof@lixom.net> commit c9b5560aac7aa774143ce16c1fe7e0007dea79e2 Author: Masanari Iida <standby24x7@gmail.com> Date: Wed Apr 13 23:36:27 2016 +0900 treewide: Fix typos in libata.xml This patch fix spelling typos found in Documentation/Docbook/libata.xml. It is because the file was generated from comments in source, I had to fix comments in libata-core.c Signed-off-by: Masanari Iida <standby24x7@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 16 ++++++++-------- drivers/ata/libata-scsi.c | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) commit d69dbd9f41a7ca343091d6ba9848a284de6059fa Author: Anup Patel <anup.patel@broadcom.com> Date: Tue Mar 29 12:57:34 2016 +0530 arm64: dts: Add ARM PL022 SPI DT nodes for NS2 We have two ARM PL022 SPI instances in NS2 SoC. On NS2 SVK, one of the ARM PL022 SPI host has Silabs si3226x slic connected to chip-select #0 whereas second ARM PL022 SPI host has Atmel AT25 EEPROM connected to chip-select #0. This patch adds ARM PL022, Silabs si3226x, and Atmel AT25 DT nodes in NS2 DT and NS2 SVK DT respectively. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Reviewed-by: Scott Branden <sbranden@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm64/boot/dts/broadcom/ns2-svk.dts | 45 ++++++++++++++++++++++++++++++++ arch/arm64/boot/dts/broadcom/ns2.dtsi | 22 ++++++++++++++++ 2 files changed, 67 insertions(+) commit 59a5bedead948db8827df865ced3cb3ea2595256 Author: Anup Patel <anup.patel@broadcom.com> Date: Tue Mar 29 12:57:33 2016 +0530 arm64: dts: Move NS2 clock DT nodes to separate DT file For more readabilty and consistency with other Broadcom SoCs, we move all NS2 clock DT nodes from main SoC DT file to a separate DT file. We also update the license header in ns2.dtsi as-per new Broadcom convention. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Reviewed-by: Scott Branden <sbranden@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm64/boot/dts/broadcom/ns2-clock.dtsi | 105 ++++++++++++++++++++++++++++ arch/arm64/boot/dts/broadcom/ns2.dtsi | 81 +-------------------- 2 files changed, 108 insertions(+), 78 deletions(-) commit b2f9cd484513b773b238e3de870912e39a0286ba Author: Anup Patel <anup.patel@broadcom.com> Date: Tue Mar 29 12:57:32 2016 +0530 arm64: dts: Add maintenance interrupt for GIC in NS2 DT The KVM ARM64 requires GIC maintenance interrupt for VGIC emulation so this patch adds the missing "interrupts" attribute to GIC node in NS2 DT. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Reviewed-by: Scott Branden <sbranden@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm64/boot/dts/broadcom/ns2.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 538fb37c1304c0edc14ad19a6b0311d840314c2a Author: Anup Patel <anup.patel@broadcom.com> Date: Tue Mar 29 12:57:31 2016 +0530 arm64: dts: Add ARM PL330 DMA DT node for NS2 We have one ARM PL330 DMA instance with 8 channels in NS2 SoC. Let's enable it for NS2 in NS2 DT. Signed-off-by: Anup Patel <anup.patel@broadcom.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Reviewed-by: Pramod KUMAR <pramodku@broadcom.com> Reviewed-by: Scott Branden <sbranden@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm64/boot/dts/broadcom/ns2.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit be0b0700bac2a0ae6b5f72c3b88c0e5dd8993329 Merge: bf16200 ac40004 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 10:19:35 2016 -0700 Merge tag 'gxbb-dt64' of https://github.com/carlocaione/linux-meson into next/dt64 Add support for a few more Amlogic S905/GXBB based boards: Hardkernel ODROID-C2 and Amlogic P200/P201 boards. We also fix the memory nodes on the Vega S95 DTS. * tag 'gxbb-dt64' of https://github.com/carlocaione/linux-meson: ARM64: dts: amlogic: Add P200/P201 boards ARM64: dts: amlogic: add Hardkernel ODROID-C2 Documentation: devicetree: amlogic: Document P20x and ODROID-C2 boards ARM64: dts: amlogic: update serial aliases ARM64: dts: amlogic: Clean up Vega S95 /memory nodes Signed-off-by: Olof Johansson <olof@lixom.net> commit a2c8eecb36b54458716c3d5f60c05c57c0727f73 Merge: bf16200 97d8eb1 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 10:16:36 2016 -0700 Merge tag 'gxbb-arm64' of https://github.com/carlocaione/linux-meson into next/arm64 Update defconfig to have basic boot for the Amlogic meson boards. * tag 'gxbb-arm64' of https://github.com/carlocaione/linux-meson: arm64: defconfig: enable basic boot for Amlogic meson Signed-off-by: Olof Johansson <olof@lixom.net> commit 0bab7359c0ab1b80f8e2827b0fcc2dc191a5a5d2 Merge: bf16200 fd71862 Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 10:01:15 2016 -0700 Merge tag 'at91-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91 into next/dt First DT batch for 4.7, additions for sama5d2 SoC: - chipid node to identify the SoC - SFR node (Special Function Registers) - LCD controller's node * tag 'at91-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91: ARM: dts: at91: sama5d2: add LCD controller ARM: dts: at91: sama5d2: add chipid node ARM: dts: at91: sama5d2: add SFR node Signed-off-by: Olof Johansson <olof@lixom.net> commit 49ad80df2629a4627d2d8efe544c58ed0798c902 Merge: bf16200 c07f98a Author: Olof Johansson <olof@lixom.net> Date: Wed Apr 13 09:59:50 2016 -0700 Merge tag 'at91-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91 into next/soc First SoC batch for 4.7: - chipid registers reading for SoC detection * tag 'at91-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91: ARM: at91/soc: reference the whole sama5d2 family ARM: at91: use chipid device for soc detection Signed-off-by: Olof Johansson <olof@lixom.net> commit d2d5437bdfdde20a75bdf59db1c1a77721613b22 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Apr 13 15:29:45 2016 +0530 regulator: max8973: add support for junction thermal warning The driver MAX8973 supports the driver for Maxim PMIC MAX77621. MAX77621 supports the junction temp warning at 120 degC and 140 degC which is configurable. It generates alert signal when junction temperature crosses these threshold. MAX77621 does not support the continuous temp monitoring of junction temperature. It just report whether junction temperature crossed the threshold or not. Add support to - Configure junction temp warning threshold via DT property to generate alert when it crosses the threshold. - Add support to interrupt the host from this device when alert occurred. - read the junction temp via thermal framework. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/Kconfig | 1 + drivers/regulator/max8973-regulator.c | 97 +++++++++++++++++++++++++++++ include/linux/regulator/max8973-regulator.h | 5 ++ 3 files changed, 103 insertions(+) commit 19dd159ce8086293b70bd8e1aeebe06aff8d7df8 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Wed Apr 13 15:29:44 2016 +0530 regulator: max8973: add DT binding details for junction warn temp The driver MAX8973 supports the driver for Maxim MAX77621. MAX77621 supports the junction temp warning at 120 degC and 140 degC which is configurable. It generates alert signal when junction temperature crosses these threshold. Add DT properties and its binding details to make this configuration from DT. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/regulator/max8973-regulator.txt | 7 +++++++ 1 file changed, 7 insertions(+) commit 5a6516ff135555aa53c7d156cd3973b826e011f9 Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Apr 6 18:49:55 2016 +0200 ARM: BCM5301X: Enable earlycon on tested devices This allows reporting & debugging problems occurring early in the boot process. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm/boot/dts/bcm4708-buffalo-wzr-1750dhp.dts | 2 +- arch/arm/boot/dts/bcm4708-luxul-xwc-1000.dts | 2 +- arch/arm/boot/dts/bcm4708-netgear-r6250.dts | 2 +- arch/arm/boot/dts/bcm4708-smartrg-sr400ac.dts | 2 +- arch/arm/boot/dts/bcm47081-buffalo-wzr-600dhp2.dts | 2 +- arch/arm/boot/dts/bcm47094-dlink-dir-885l.dts | 2 +- arch/arm/boot/dts/bcm5301x.dtsi | 4 ++++ 7 files changed, 10 insertions(+), 6 deletions(-) commit dd70ccfaa79189feaa78609d44f7c3e7fa1dc6ff Author: Rafał Miłecki <zajec5@gmail.com> Date: Wed Mar 23 16:52:47 2016 +0100 ARM: BCM5301X: Set vcc-gpio for USB controllers of few devices There are few devices that have USB power controlled using GPIO. Linux USB host driver (bcma-hcd) already supports this by reading vcc-gpio from DT. Set it properly for all known devices. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> arch/arm/boot/dts/bcm4708-buffalo-wzr-1750dhp.dts | 8 ++++++++ arch/arm/boot/dts/bcm4708-netgear-r6250.dts | 15 ++++----------- arch/arm/boot/dts/bcm4709-buffalo-wxr-1900dhp.dts | 5 +++++ arch/arm/boot/dts/bcm4709-netgear-r8000.dts | 8 ++++++++ arch/arm/boot/dts/bcm47094-dlink-dir-885l.dts | 4 ++++ arch/arm/boot/dts/bcm5301x.dtsi | 14 ++++++++++++++ 6 files changed, 43 insertions(+), 11 deletions(-) commit 925a7d045e6f0129bc58ccd4c3a8dcef62486345 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:54 2016 +0200 dmaengine: dw: set cdesc to NULL when free cyclic transfers To be sure we have the cyclic transfers already gone we set cdesc to NULL. It will prevent the double free. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 2 ++ 1 file changed, 2 insertions(+) commit b68fd0976286e0cc4e163a83b8b68d6efca814dd Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:53 2016 +0200 dmaengine: dw: move residue to a descriptor Residue is a property of any active descriptor. So, any descriptor may be in different state but residue is a feature of active descriptor. Check if the asked descriptor is active and return proper residue value for it. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 60 ++++++++++++++++++++++++++++++++++----------------- drivers/dma/dw/regs.h | 2 +- 2 files changed, 41 insertions(+), 21 deletions(-) commit 423f9cbf2da8110e01eee56b8f755332432e82c7 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:52 2016 +0200 dmaengine: dw: move dwc->initialized to dwc->flags We have already dedicated variable for flags, therefore no need to create an additional storage for that. Covert dwc->initialized to use dwc->flags. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 8 ++++---- drivers/dma/dw/regs.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) commit 5e09f98e77e9bd500e3d930bfd46b1924cca01ca Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:51 2016 +0200 dmaengine: dw: move dwc->paused to dwc->flags We have already dedicated variable for flags, therefore no need to create an additional storage for that. Convert dwc->paused to use dwc->flags. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 12 +++++------- drivers/dma/dw/regs.h | 2 +- 2 files changed, 6 insertions(+), 8 deletions(-) commit 7794e5b920a2586d7f3258aade0ca90cb01cdbd4 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:48 2016 +0200 dmaengine: dw: define counter variables as unsigned int The code is fixed to satisfy a compiler otherwise we have drivers/dma/dw/core.c: In function ‘dwc_handle_cyclic’: drivers/dma/dw/core.c:568: warning: comparison between signed and unsigned drivers/dma/dw/core.c: In function ‘dw_dma_tasklet’: drivers/dma/dw/core.c:590: warning: comparison between signed and unsigned drivers/dma/dw/core.c: In function ‘dw_dma_off’: drivers/dma/dw/core.c:1103: warning: comparison between signed and unsigned drivers/dma/dw/core.c: In function ‘dw_dma_cyclic_free’: drivers/dma/dw/core.c:1469: warning: comparison between signed and unsigned drivers/dma/dw/core.c: In function ‘dw_dma_probe’: drivers/dma/dw/core.c:1574: warning: comparison between signed and unsigned There is no functional change. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 897e40d3b19c9ea2013aee419302c0f6e9ae287e Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:46 2016 +0200 dmaengine: dw: substitute dma_read_byaddr by dma_readl_native Since struct dw_dma is allocated and regs member is assigned properly we can use standard IO accessors to the DMA registers. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 8 +++----- drivers/dma/dw/regs.h | 4 ---- 2 files changed, 3 insertions(+), 9 deletions(-) commit a3e557999be74810e02be1d0c107096b7aa48ece Author: Mans Rullgard <mans@mansr.com> Date: Fri Mar 18 16:24:45 2016 +0200 dmaengine: dw: clear LLP_[SD]_EN bits in last descriptor of a chain The datasheet requires that the LLP_[SD]_EN bits be cleared whenever LLP.LOC is zero, i.e. in the last descriptor of a multi-block chain. Make the driver do this. Signed-off-by: Mans Rullgard <mans@mansr.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 2 ++ 1 file changed, 2 insertions(+) commit 2a0fae025e56afbe38441d411f57667b08f44d0e Author: Mans Rullgard <mans@mansr.com> Date: Fri Mar 18 16:24:44 2016 +0200 dmaengine: dw: set LMS field in descriptors The LMS field indicates from which master the descriptor is to be read. This patch assumes this is always the same as the memory side in a peripheral transfer which is true for all known systems. Signed-off-by: Mans Rullgard <mans@mansr.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 26 ++++++++++++++------------ drivers/dma/dw/regs.h | 4 ++++ 2 files changed, 18 insertions(+), 12 deletions(-) commit df1f3a2305d72cbf470758999785f08bcd642d5d Author: Mans Rullgard <mans@mansr.com> Date: Fri Mar 18 16:24:43 2016 +0200 dmaengine: dw: fix byte order of hw descriptor fields If the DMA controller uses a different byte order than the host CPU, the hardware linked list descriptor fields need to be byte-swapped. This patch makes the driver write these fields using the same byte order it uses for mmio accesses to the DMA engine. I do not know if this is guaranteed to always be correct. Signed-off-by: Mans Rullgard <mans@mansr.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 123 +++++++++++++++++++++++++------------------------- drivers/dma/dw/regs.h | 32 ++++++++++--- 2 files changed, 87 insertions(+), 68 deletions(-) commit bb3450ad0ed618fda84fbd2e28065bd7791fd7f9 Author: Mans Rullgard <mans@mansr.com> Date: Fri Mar 18 16:24:42 2016 +0200 dmaengine: dw: set src and dst master select according to xfer direction On some architectures the DMA controller can have two masters connected to different buses and thus access to memory is possible only through one and to peripheral through the other. This patch changes the src and dst master setting to match the direction of the transfer. Signed-off-by: Mans Rullgard <mans@mansr.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dw/core.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit c422025c185fb2bb28df65b1bbed7953480c7f87 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 16:24:41 2016 +0200 dmaengine: dw: rename masters to reflect actual topology The source and destination masters are reflecting buses or their layers to where the different devices can be connected. The patch changes the master names to reflect which one is related to which independently on the transfer direction. The outcome of the change is that the memory data width is now always limited by a data width of the master which is dedicated to communicate to memory. The patch will not break anything since all current users have the same data width for all masters. Though it would be nice to revisit avr32 platforms to check what is the actual hardware topology in use there. It seems that it has one bus and two masters on it as stated by Table 8-2, that's why everything works independently on the master in use. The purpose of the sequential patch is to fix the driver for configuration of more than one bus. The change is done in the assumption that src_master and dst_master are reflecting a connection to the memory and peripheral correspondently on avr32 and otherwise on the rest. Acked-by: Hans-Christian Egtvedt <egtvedt@samfundet.no> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Documentation/devicetree/bindings/dma/snps-dma.txt | 4 ++-- arch/avr32/mach-at32ap/at32ap700x.c | 16 ++++++++-------- drivers/ata/sata_dwc_460ex.c | 4 ++-- drivers/dma/dw/core.c | 19 +++++++++---------- drivers/dma/dw/platform.c | 12 ++++++------ drivers/dma/dw/regs.h | 4 ++-- drivers/spi/spi-pxa2xx-pci.c | 8 ++++---- drivers/tty/serial/8250/8250_pci.c | 8 ++++---- include/linux/platform_data/dma-dw.h | 8 ++++---- 9 files changed, 41 insertions(+), 42 deletions(-) commit 9120abdcdb7fd3a51d3135ff37c9dad358dde9ee Author: Keerthy <j-keerthy@ti.com> Date: Wed Apr 13 08:54:52 2016 -0700 ARM: configs: keystone: Add CPU Hotplug related options Add the config options needed to get CPU hotplug functional. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org> arch/arm/configs/keystone_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 14de48a412f00f8e0a5413844d846bc5657db327 Author: Vitaly Andrianov <vitalya@ti.com> Date: Wed Apr 13 08:55:17 2016 -0700 ARM: keystone: dts: add psci command definition This commit adds definition for cpu_on, cpu_off and cpu_suspend commands. These definitions must match the corresponding PSCI definitions in boot monitor. Having those command and corresponding PSCI support in boot monitor allows run time CPU hot plugin. Signed-off-by: Vitaly Andrianov <vitalya@ti.com> Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org> arch/arm/boot/dts/keystone.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) commit 72f7e9596087ecece7e80bb674f7070bef4edc29 Author: Vignesh R <vigneshr@ti.com> Date: Wed Apr 13 08:53:56 2016 -0700 ARM: dts: keystone: Add aliases for SPI nodes Add aliases for SPI nodes, this is required to probe the SPI devices in U-Boot. Signed-off-by: Vignesh R <vigneshr@ti.com> Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org> arch/arm/boot/dts/keystone.dtsi | 3 +++ 1 file changed, 3 insertions(+) commit 5edafc29829bc2a134c22f667c9ac5cb808a1c82 Author: Nishanth Menon <nm@ti.com> Date: Tue Mar 22 09:06:22 2016 -0700 ARM: dts: k2*: Rename the k2* files to keystone-k2* files As reported in [1], rename the k2* dts files to keystone-* files this will force consistency throughout. Script for the same (and hand modified for Makefile and MAINTAINERS files): for i in arch/arm/boot/dts/k2* do b=`basename $i`; git mv $i arch/arm/boot/dts/keystone-$b; sed -i -e "s/$b/keystone-$b/g" arch/arm/boot/dts/*[si] done NOTE: bootloaders that depend on older dtb names will need to be updated as well. [1] http://marc.info/?l=linux-arm-kernel&m=145637407804754&w=2 Reported-by: Olof Johansson <olof@lixom.net> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org> MAINTAINERS | 2 +- arch/arm/boot/dts/Makefile | 6 +- arch/arm/boot/dts/k2e-clocks.dtsi | 77 ----- arch/arm/boot/dts/k2e-evm.dts | 154 ---------- arch/arm/boot/dts/k2e-netcp.dtsi | 229 --------------- arch/arm/boot/dts/k2e.dtsi | 150 ---------- arch/arm/boot/dts/k2hk-clocks.dtsi | 425 ---------------------------- arch/arm/boot/dts/k2hk-evm.dts | 182 ------------ arch/arm/boot/dts/k2hk-netcp.dtsi | 232 --------------- arch/arm/boot/dts/k2hk.dtsi | 117 -------- arch/arm/boot/dts/k2l-clocks.dtsi | 266 ----------------- arch/arm/boot/dts/k2l-evm.dts | 131 --------- arch/arm/boot/dts/k2l-netcp.dtsi | 212 -------------- arch/arm/boot/dts/k2l.dtsi | 111 -------- arch/arm/boot/dts/keystone-k2e-clocks.dtsi | 77 +++++ arch/arm/boot/dts/keystone-k2e-evm.dts | 154 ++++++++++ arch/arm/boot/dts/keystone-k2e-netcp.dtsi | 229 +++++++++++++++ arch/arm/boot/dts/keystone-k2e.dtsi | 150 ++++++++++ arch/arm/boot/dts/keystone-k2hk-clocks.dtsi | 425 ++++++++++++++++++++++++++++ arch/arm/boot/dts/keystone-k2hk-evm.dts | 182 ++++++++++++ arch/arm/boot/dts/keystone-k2hk-netcp.dtsi | 232 +++++++++++++++ arch/arm/boot/dts/keystone-k2hk.dtsi | 117 ++++++++ arch/arm/boot/dts/keystone-k2l-clocks.dtsi | 266 +++++++++++++++++ arch/arm/boot/dts/keystone-k2l-evm.dts | 131 +++++++++ arch/arm/boot/dts/keystone-k2l-netcp.dtsi | 212 ++++++++++++++ arch/arm/boot/dts/keystone-k2l.dtsi | 111 ++++++++ 26 files changed, 2290 insertions(+), 2290 deletions(-) commit 4c4d7f878589585d32b81aab6ed4a5066fae1091 Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Thu Apr 7 16:49:43 2016 +0300 dmaengine: core: Revert back to pr_debug in __dma_request_channel() Commit ef859312c3a1 ("dmaengine: core: Use dev_ functions for debug and error prints") wasn't quite right in __dma_request_channel() by claiming that all pr_ prints have valid DMA channel pointer. Obviously it is not true as __dma_request_channel() is looking for a channel and returns NULL if it does not find it. Prevent this potential NULL pointer dereference by reverting back to pr_debug(). Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dmaengine.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c875a7093f0479215cf9bf51356d7638f2ec5746 Author: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Date: Wed Apr 13 11:08:20 2016 -0300 nvme: Avoid reset work on watchdog timer function during error recovery This patch adds a check on nvme_watchdog_timer() function to avoid the call to reset_work() when an error recovery process is ongoing on controller. The check is made by looking at pci_channel_offline() result. If we don't check for this on nvme_watchdog_timer(), error recovery mechanism can't recover well, because reset_work() won't be able to do its job (since we're in the middle of an error) and so the controller is removed from the system before error recovery mechanism can perform slot reset (which would allow the adapter to recover). In this patch we also have split the huge condition expression on nvme_watchdog_timer() by introducing an auxiliary function to help make the code more readable. Reviewed-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 38 ++++++++++++++++++++++++++++++-------- 1 file changed, 30 insertions(+), 8 deletions(-) commit b5fda7ed5c63297d0f43e608b455d82ceabdebf0 Author: Jisheng Zhang <jszhang@marvell.com> Date: Fri Mar 25 11:08:55 2016 +0800 arm64: cpuidle: make arm_cpuidle_suspend() a bit more efficient Currently, we check two pointers: cpu_ops and cpu_suspend on every idle state entry. These pointers check can be avoided: If cpu_ops has not been registered, arm_cpuidle_init() will return -EOPNOTSUPP, so arm_cpuidle_suspend() will never have chance to run. In other word, the cpu_ops check can be avoid. Similarly, the cpu_suspend check could be avoided in this hot path by moving it into arm_cpuidle_init(). I measured the 4096 * time from arm_cpuidle_suspend entry point to the cpu_psci_cpu_suspend entry point. HW platform is Marvell BG4CT STB board. 1. only one shell, no other process, hot-unplug secondary cpus, execute the following cmd while true do sleep 0.2 done before the patch: 1581220ns after the patch: 1579630ns reduced by 0.1% 2. only one shell, no other process, hot-unplug secondary cpus, execute the following cmd while true do md5sum /tmp/testfile sleep 0.2 done NOTE: the testfile size should be larger than L1+L2 cache size before the patch: 1961960ns after the patch: 1912500ns reduced by 2.5% So the more complex the system load, the bigger the improvement. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Acked-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/kernel/cpuidle.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) commit 7d7b4ae418728916456c6fd03a97ef35345ff30d Author: Kefeng Wang <wangkefeng.wang@huawei.com> Date: Fri Mar 25 17:30:07 2016 +0800 arm64: cpufeature: append additional id_aa64mmfr2 fields to cpufeature There are some new cpu features which can be identified by id_aa64mmfr2, this patch appends all fields of it. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Will Deacon <will.deacon@arm.com> arch/arm64/include/asm/sysreg.h | 4 ++++ arch/arm64/kernel/cpufeature.c | 4 ++++ 2 files changed, 8 insertions(+) commit 6ba20a00a36bb47c64581bfa08f1606d4bf0589f Author: Caesar Wang <wxt@rock-chips.com> Date: Tue Mar 15 15:55:45 2016 +0800 pinctrl: rockchip: add support the get_direction This patch adds the get_direction to support the gpio interface. The gpio direction is not used on rockchip platform when use the gpio debugfs. Tested on kylin board. (RK3036 SoCs) The repro steps: $/sys/class/gpio/ echo 53 > export $/sys/class/gpio/gpio53# cat direction in In general, the gpio53 should be out value, but the direction is the default value 'in', since the get_direction didn't supported in rockchip pinctrl. So, we should add this patch to support it. Cc: linux-gpio@vger.kernel.org Cc: linux-rockchip@lists.infradead.org Reported-by: Jeffy Chen <jeffy.chen@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-rockchip.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 59247e33ff494e3643cdff54b64bf72575052b76 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 12 16:05:02 2016 -0300 perf trace: Do not accept --no-syscalls together with -e Doesn't make sense and was causing a segfault, fix it. # trace -e clone --no-syscalls --event sched:*exec firefox The -e option can't be used with --no-syscalls. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-ccrahezikdk2uebptzr1eyyi@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 7 +++++++ 1 file changed, 7 insertions(+) commit e20ab86e51218f9949f41fb39a6c4f63b662f135 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 12 15:16:15 2016 -0300 perf evsel: Move some methods from session.[ch] to evsel.[ch] Those were converted to be evsel methods long ago, move the source to where it belongs. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-vja8rjmkw3gd5ungaeyb5s2j@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 14 ++--- tools/perf/builtin-trace.c | 6 +- tools/perf/util/evsel.c | 131 ++++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/evsel.h | 13 +++++ tools/perf/util/session.c | 130 ------------------------------------------- tools/perf/util/session.h | 13 ----- 6 files changed, 154 insertions(+), 153 deletions(-) commit 73643bb6a21c85509c7ae4c316f502c5a19cce65 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:31 2016 +0200 perf sched map: Display only given cpus Introducing --cpus option that will display only given cpus. Could be used together with color-cpus option. $ perf sched map --cpus 0,1 *A0 309999.786924 secs A0 => rcu_sched:7 *. 309999.786930 secs *B0 . 309999.786931 secs B0 => rcuos/2:25 B0 *A0 309999.786947 secs Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-9-git-send-email-jolsa@kernel.org [ Added entry to man page ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-sched.txt | 3 +++ tools/perf/builtin-sched.c | 23 +++++++++++++++++++++++ 2 files changed, 26 insertions(+) commit cf294f24f8c83bca6aa8e96b5cc4f78bed887f92 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:30 2016 +0200 perf sched map: Color given cpus Adding --color-cpus option to display selected cpus with background color (red by default). It helps on navigating through the perf sched map output. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-8-git-send-email-jolsa@kernel.org [ Added entry to man page ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-sched.txt | 3 +++ tools/perf/builtin-sched.c | 36 ++++++++++++++++++++++++++++++--- 2 files changed, 36 insertions(+), 3 deletions(-) commit a151a37a760aab41c115af8d5016e449228e8d2e Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:29 2016 +0200 perf sched map: Color given pids Adding --color-pids option to display selected pids in color (blue by default). It helps on navigating through the 'perf sched map' output. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-7-git-send-email-jolsa@kernel.org [ Added entry to man page ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-sched.txt | 3 ++ tools/perf/builtin-sched.c | 77 +++++++++++++++++++++++++++++++-- 2 files changed, 76 insertions(+), 4 deletions(-) commit 097be0f5034fc9edaf84253b773b14bc2af9a708 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:28 2016 +0200 perf thread_map: Make new_by_tid_str constructor public It will be used in following patch. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-6-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread_map.c | 2 +- tools/perf/util/thread_map.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) commit 8cd91195e5efc5166fc48eec6cf83ef93133b7b6 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:27 2016 +0200 perf sched: Use color_fprintf for output As preparation for next patch. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-5-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-sched.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit 99623c628f5425f09b5321cf621af1da29c0c47d Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:26 2016 +0200 perf sched: Add compact display option Add compact map display that does not output the whole cpu matrix, only cpus that got event. $ perf sched map --compact *A0 1082427.094098 secs A0 => perf:19404 (CPU 2) A0 *. 1082427.094127 secs . => swapper:0 (CPU 1) A0 . *B0 1082427.094174 secs B0 => rcuos/2:25 (CPU 3) A0 . *. 1082427.094177 secs *C0 . . 1082427.094187 secs C0 => migration/2:21 C0 *A0 . 1082427.094193 secs *. A0 . 1082427.094195 secs *D0 A0 . 1082427.094402 secs D0 => rngd:968 *. A0 . 1082427.094406 secs . *E0 . 1082427.095221 secs E0 => kworker/1:1:5333 . E0 *F0 1082427.095227 secs F0 => xterm:3342 It helps to display sane output for small thread loads on big cpu servers. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-4-git-send-email-jolsa@kernel.org [ Add entry in 'perf sched' man page ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-sched.txt | 7 ++++ tools/perf/builtin-sched.c | 62 +++++++++++++++++++++++++++++---- 2 files changed, 63 insertions(+), 6 deletions(-) commit e632aa69c919462a7f93c8799b97c8a9ddd48fc2 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:25 2016 +0200 perf cpu_map: Add has() method Adding cpu_map__has() to return bool of cpu presence in cpus map. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-3-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/cpumap.c | 12 ++++++++++++ tools/perf/util/cpumap.h | 2 ++ 2 files changed, 14 insertions(+) commit 3407df8bbc3a91d9aa4910130026ab6b3a261b87 Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 12 15:29:24 2016 +0200 perf thread_map: Add has() method Adding thread_map__has() to return bool of pid presence in threads map. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460467771-26532-2-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread_map.c | 12 ++++++++++++ tools/perf/util/thread_map.h | 1 + 2 files changed, 13 insertions(+) commit 202ff9684a912c96e0f2fac65e34280a97ad3611 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 12 10:11:07 2016 -0300 perf trace: Support callchains for --event too We already were able to ask for callchains for a specific event: # trace -e nanosleep --call dwarf --event sched:sched_switch/call-graph=fp/ usleep 1 This would enable tracing just the "nanosleep" syscall, with callchains at syscall exit and would ask the kernel for frame pointer callchains to be enabled for the "sched:sched_switch" tracepoint event, its just that we were not resolving the callchain and printing it in 'perf trace', do it: # trace -e nanosleep --call dwarf --event sched:sched_switch/call-graph=fp/ usleep 1 0.425 ( 0.013 ms): usleep/6718 nanosleep(rqtp: 0x7ffcc1d16e20) ... 0.425 ( ): sched:sched_switch:usleep:6718 [120] S ==> swapper/2:0 [120]) __schedule+0xfe200402 ([kernel.kallsyms]) schedule+0xfe200035 ([kernel.kallsyms]) do_nanosleep+0xfe20006f ([kernel.kallsyms]) hrtimer_nanosleep+0xfe2000dc ([kernel.kallsyms]) sys_nanosleep+0xfe20007a ([kernel.kallsyms]) do_syscall_64+0xfe200062 ([kernel.kallsyms]) return_from_SYSCALL_64+0xfe200000 ([kernel.kallsyms]) __nanosleep+0xffff008b8cbe2010 (/usr/lib64/libc-2.22.so) 0.486 ( 0.073 ms): usleep/6718 ... [continued]: nanosleep()) = 0 __nanosleep+0x10 (/usr/lib64/libc-2.22.so) usleep+0x34 (/usr/lib64/libc-2.22.so) main+0x1eb (/usr/bin/usleep) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) _start+0x29 (/usr/bin/usleep) # Pretty compact, huh? DWARF callchains for raw_syscalls:sys_exit + frame pointer callchains for a tracepoint, if your hardware supports LBR, go wild with /call-graph=lbr/, guess the next step is to lift this from 'perf script': -F, --fields <str> comma separated output fields prepend with 'type:'. Valid types: hw,sw,trace,raw. Fields: comm,tid,pid,time,cpu,event,trace,ip,sym,dso,addr,symoff,period,iregs,brstack,brstacksym,flags Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-2e7yiv5hqdm8jywlmfivvx2v@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 41 ++++++++++++++++++++++++++--------------- 1 file changed, 26 insertions(+), 15 deletions(-) commit 3cb26e26edd12b11b98bbe2b8c89c3a0da79e390 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Apr 8 17:59:49 2016 +0300 drm/i915/opregion: remove unnecessary ifdefs on CONFIG_ACPI The whole file is ignored on CONFIG_ACPI=n. Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460127589-8357-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_opregion.c | 6 ------ 1 file changed, 6 deletions(-) commit dfbd379ba9b7431eec46f1dbc2603491be98619a Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Fri Mar 11 19:13:22 2016 +0530 gpio: of: Return error if gpio hog configuration failed If GPIO hog configuration failed while adding OF based gpiochip() then return the error instead of ignoring it. This helps of properly handling the gpio driver dependency. When adding the gpio hog nodes for NVIDIA's Tegra210 platforms, the gpio_hogd() fails with EPROBE_DEFER because pinctrl is not ready at this time and gpio_request() for Tegra GPIO driver returns error. The error was not causing the Tegra GPIO driver to fail as the error was getting ignored. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Benoit Parrot <bparrot@ti.com> Cc: Alexandre Courbot <acourbot@nvidia.com> Reviewed-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib-of.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit ce81a65c79d6012a384563caf76d47e28947a347 Author: Michał Winiarski <michal.winiarski@intel.com> Date: Tue Apr 12 15:51:55 2016 +0200 drm/i915: Adjust size of PIPE_CONTROL used for gen8 render seqno write We started to use PIPE_CONTROL to write render ring seqno in order to combat seqno write vs interrupt generation problems. This was introduced by commit 7c17d377374d ("drm/i915: Use ordered seqno write interrupt generation on gen8+ execlists"). On gen8+ size of PIPE_CONTROL with Post Sync Operation should be 6 dwords. When we're using older 5-dword variant it's possible to observe inconsistent values written by PIPE_CONTROL with Post Sync Operation from user batches, resulting in rendering corruptions. v2: Fix BAT failures v3: Comments on alignment and thrashing high dword of seqno (Chris) v4: Updated commit msg (Mika) Testcase: igt/gem_pipe_control_store_loop/*-qword-write Issue: VIZ-7393 Cc: stable@vger.kernel.org Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Cc: Abdiel Janulgue <abdiel.janulgue@linux.intel.com> Signed-off-by: Michał Winiarski <michal.winiarski@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Tested-by: Abdiel Janulgue <abdiel.janulgue@linux.intel.com> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460469115-26002-1-git-send-email-michal.winiarski@intel.com drivers/gpu/drm/i915/intel_lrc.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 97ea6be161c55dec896b65c95157d953c330ae05 Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Tue Apr 5 15:56:17 2016 +0300 drm/i915/skl: Fix spurious gpu hang with gt3/gt4 revs Experiments with heaven 4.0 benchmark and skylake gt3e (rev 0xa) suggest that WaForceContextSaveRestoreNonCoherent is needed for all revs. Extending this to all revs cures a gpu hang with rev 0xa when running heaven4.0 gpu benchmark. We have been here before, with problems enabling gt4e and extending up to revision F0 instead of false claims of bspec of E0 only. See commit <e238659ddd88> ("drm/i915/skl: Default to noncoherent access up to F0"). In retrospect we should have covered this with this big blanket back then already, as E0 vs F0 discrepancy was suspicious enough. Previously the WaForceEnableNonCoherent has been tied to context non-coherence, atleast in relevant hsds. So keep this tie and extended this alongside. Cc: Abdiel Janulgue <abdiel.janulgue@linux.intel.com> Cc: Ben Widawsky <benjamin.widawsky@intel.com> Cc: Timo Aaltonen <tjaalton@ubuntu.com> Cc: stable@vger.kernel.org Reported-by: Mike Lothian <mike@fireburn.co.uk> References: https://bugs.freedesktop.org/show_bug.cgi?id=93491 Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Ben Widawsky <benjamin.widawsky@intel.com> Tested-by: Timo Aaltonen <tjaalton@ubuntu.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459860977-27751-2-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/intel_ringbuffer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 185c66e57ce725afeb58a3cfa48547706af3a7af Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Tue Apr 5 15:56:16 2016 +0300 drm/i915/skl: Fix rc6 based gpu/system hang For all gt3 and gt4 skylake variants, extend the usage of WaRsDisableCoarsePowerGating for all revisions. Without this gt3 and gt4 skylakes up to atleast rev 0xa can gpu hang or system hang. Cc: Abdiel Janulgue <abdiel.janulgue@linux.intel.com> Cc: Ben Widawsky <benjamin.widawsky@intel.com> Cc: Timo Aaltonen <tjaalton@ubuntu.com> Cc: <stable@vger.kernel.org> Reported-by: Mikael Djurfeldt <mikael@djurfeldt.com> References: https://bugs.freedesktop.org/show_bug.cgi?id=94161 Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Ben Widawsky <benjamin.widawsky@intel.com> Tested-by: Timo Aaltonen <tjaalton@ubuntu.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459860977-27751-1-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/i915_drv.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 3f10e82fe10d87d2fd558ef51c34abaf2ee538d2 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Apr 7 12:48:17 2016 +0300 drm/i915: add INTEL_GEN() helper shorthand for INTEL_INFO()->gen Sudden realization: $ grep -ho "INTEL_INFO([^)]*)->[a-zA-Z0-9_]*" *.[ch] | sed 's/.*->//' |\ sort | uniq -c | sort -rn | head -5 446 gen 24 num_pipes 10 ring_mask 9 color 4 subslice_per_slice Acked-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460022497-29304-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + 1 file changed, 1 insertion(+) commit bd92883051a0228cc34996b8e766111ba10c9aac Author: Anton Blanchard <anton@samba.org> Date: Wed Apr 6 21:59:50 2016 +1000 sched/cpuacct: Check for NULL when using task_pt_regs() task_pt_regs() can return NULL for kernel threads, so add a check. This fixes an oops at boot on ppc64. Reported-and-Tested-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Tested-by: Zhao Lei <zhaolei@cn.fujitsu.com> Signed-off-by: Anton Blanchard <anton@samba.org> Acked-by: Zhao Lei <zhaolei@cn.fujitsu.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: efault@gmx.de Cc: htejun@gmail.com Cc: linuxppc-dev@lists.ozlabs.org Cc: tj@kernel.org Cc: yangds.fnst@cn.fujitsu.com Link: http://lkml.kernel.org/r/20160406215950.04bc3f0b@kryten Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/cpuacct.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 2c923e94cd9c6acff3b22f0ae29cfe65e2658b40 Author: Daniel Lezcano <daniel.lezcano@linaro.org> Date: Mon Apr 11 16:38:34 2016 +0200 sched/clock: Make local_clock()/cpu_clock() inline The local_clock/cpu_clock functions were changed to prevent a double identical test with sched_clock_cpu() when HAVE_UNSTABLE_SCHED_CLOCK is set. That resulted in one line functions. As these functions are in all the cases one line functions and in the hot path, it is useful to specify them as static inline in order to give a strong hint to the compiler. After verification, it appears the compiler does not inline them without this hint. Change those functions to static inline. sched_clock_cpu() is called via the inlined local_clock()/cpu_clock() functions from sched.h. So any module code including sched.h will reference sched_clock_cpu(). Thus it must be exported with the EXPORT_SYMBOL_GPL macro. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460385514-14700-2-git-send-email-daniel.lezcano@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/sched.h | 32 ++++++++++++++++++++++++++++++-- kernel/sched/clock.c | 42 +----------------------------------------- 2 files changed, 31 insertions(+), 43 deletions(-) commit c78b17e28cc2c2df74264afc408bdc6aaf3fbcc8 Author: Daniel Lezcano <daniel.lezcano@linaro.org> Date: Mon Apr 11 16:38:33 2016 +0200 sched/clock: Remove pointless test in cpu_clock/local_clock In case the HAVE_UNSTABLE_SCHED_CLOCK config is set, the cpu_clock() version checks if sched_clock_stable() is not set and calls sched_clock_cpu(), otherwise it calls sched_clock(). sched_clock_cpu() checks also if sched_clock_stable() is set and, if true, calls sched_clock(). sched_clock() will be called in sched_clock_cpu() if sched_clock_stable() is true. Remove the duplicate test by directly calling sched_clock_cpu() and let the static key act in this function instead. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1460385514-14700-1-git-send-email-daniel.lezcano@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/clock.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) commit 31d50c551e30923b86a1b5b420920dd1927fa63b Author: Peter Zijlstra <peterz@infradead.org> Date: Mon Apr 4 16:02:08 2016 +0200 perf/x86/amd/uncore: Do not register a task ctx for uncore PMUs The new sanity check introduced by: 26657848502b ("perf/core: Verify we have a single perf_hw_context PMU") ... triggered on the AMD uncore driver. Uncore PMUs are per node, they cannot have per-task counters. Fix it. Reported-by: Borislav Petkov <bp@suse.de> Reported-by: Ingo Molnar <mingo@kernel.org> Tested-by: Borislav Petkov <bp@suse.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: acme@redhat.com Cc: alexander.shishkin@linux.intel.com Cc: eranian@google.com Cc: jolsa@redhat.com Cc: linux-tip-commits@vger.kernel.org Cc: vincent.weaver@maine.edu Link: http://lkml.kernel.org/r/20160404140208.GA3448@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/amd/uncore.c | 2 ++ 1 file changed, 2 insertions(+) commit 91ed140d6c1e168b11bbbddac4f6066f40a0c6b5 Author: Borislav Petkov <bp@suse.de> Date: Thu Mar 31 16:21:02 2016 +0200 x86/asm: Make sure verify_cpu() has a good stack 04633df0c43d ("x86/cpu: Call verify_cpu() after having entered long mode too") added the call to verify_cpu() for sanitizing CPU configuration. The latter uses the stack minimally and it can happen that we land in startup_64() directly from a 64-bit bootloader. Then we want to use our own, known good stack. Do that. APs don't need this as the trampoline sets up a stack for them. Reported-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mika Penttilä <mika.penttila@nextfour.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459434062-31055-1-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/head_64.S | 8 ++++++++ include/asm-generic/vmlinux.lds.h | 4 +++- 2 files changed, 11 insertions(+), 1 deletion(-) commit 5d01e99ebf91ff2b72b2bcb81976eab14addf143 Author: Stefan Agner <stefan@agner.ch> Date: Mon Apr 4 22:28:41 2016 -0700 ARM: dts: ls1021a: add pix clock to DCU dts node The DCU IP has distinct clock inputs for register access and the pixel clocks, at least in some implementations. LS1021a seems to use the same clock, therefore specify the same clock for "dcu" and "pix". Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/ls1021a.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 5b9f967c074007b37874e63dbc56babb8501fb4b Author: Alexander Stein <alexander.stein@systec-electronic.com> Date: Wed Mar 23 10:49:06 2016 +0100 ARM: dts: ls1021a: DSPI has 6 chip-selects Both DSPI have signals SPIn_PCS[0:5] so in summary 6 chip-selects, not 5. Fix that. Signed-off-by: Alexander Stein <alexander.stein@systec-electronic.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/ls1021a.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c54dd442b489116234ec27a1d3575f274060b68f Author: Liu Gang <Gang.Liu@nxp.com> Date: Wed Mar 23 17:47:20 2016 +0800 ARM: dts: ls1021a: Add gpio support for ls1021a platform Add gpio nodes for ls1021a platform dts file. The gpio IP block of the ls1021a can be supported by the code drivers/gpio/gpio-mpc8xxx.c. The compatible "fsl,qoriq-gpio" is used by gpio driver: drivers/gpio/gpio-mpc8xxx.c to implement general gpio functionalities. The chip-specific compatible "fsl,ls1021a-gpio" may be used to fix potential gpio IP block errata or other chip-specific gpio issues. Signed-off-by: Liu Gang <Gang.Liu@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/ls1021a.dtsi | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 027309fc856dd6cb50d890cf65136700f62f991c Author: Akshay Bhat <akshay.bhat@timesys.com> Date: Tue Apr 12 12:01:24 2016 -0400 ARM: dts: imx6q-ba16: Remove unused vqmmc-supply The vqmmc supply is not connected to bio supply on the BA16 module. Hence remove vqmmc-supply property in usdhc3 node. Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-ba16.dtsi | 1 - 1 file changed, 1 deletion(-) commit f4a458fd83246a52e86628cb49dc11de8be823e2 Author: Minghuan Lian <Minghuan.Lian@nxp.com> Date: Wed Apr 6 19:02:07 2016 +0800 ARM: dts: ls1021a: add SCFG MSI dts node Add SCFG MSI dts node and add msi-parent property to PCIe dts node that points to the corresponding MSI node. Signed-off-by: Minghuan Lian <Minghuan.Lian@nxp.com> Tested-by: Alexander Stein <alexander.stein@systec-electronic.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/ls1021a.dtsi | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 9eb7db1c352ad2048c952639aded7f67eec9c7d0 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Wed Apr 6 09:32:59 2016 +0200 ARM: dts: imx28: add alternative pinmuxing for mac0 Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx28.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit cc1fb3e1f291c1fc1784619fbb84efab1d677e6c Author: Soeren Moch <smoch@web.de> Date: Tue Apr 5 16:55:04 2016 +0200 ARM: dts: imx6q-tbs2910: fix fec reset polarity According to Documentation/devicetree/bindings/net/fsl-fec.txt the polarity of "phy-reset-gpios" is assumed to be active-low unless a separate property "phy-reset-active-high" is available. So replace the inconsistent polarity description to make the correct active-low reset behavior more obvious. Signed-off-by: Soeren Moch <smoch@web.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-tbs2910.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1556063fde421ed17b017de3ba5c546f0524a15b Author: Cory Tusar <cory.tusar@pid1solutions.com> Date: Mon Apr 4 23:53:12 2016 +0200 ARM: dts: vf610-zii-dev: Add ZII development board. This commit adds support for Rev. B of a Zodiac Inflight Innovations development board, mainly intended for DSA and ARINC 429 development work. Signed-off-by: Cory Tusar <cory.tusar@pid1solutions.com> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/vf610-zii-dev-rev-b.dts | 734 ++++++++++++++++++++++++++++++ 2 files changed, 736 insertions(+), 1 deletion(-) commit ef4a4e14ceeaec542e71d97e38912cbf83691541 Author: Stefan Agner <stefan@agner.ch> Date: Fri Apr 1 23:13:41 2016 -0700 ARM: dts: vfxxx: add missing reg properties Add missing reg properties to AIPS bus and Cortex-A5's PMU unit. This change avoids the following warnings: Warning (unit_address_vs_reg): Node /soc/aips-bus@40000000 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@40080000 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/aips-bus@40080000/pmu@40089000 has a unit name, but no reg property Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/vf500.dtsi | 1 + arch/arm/boot/dts/vfxxx.dtsi | 2 ++ 2 files changed, 3 insertions(+) commit 6d20b24a2b3edc361e651ab87de5071d4b1b24c3 Author: Stefan Agner <stefan@agner.ch> Date: Fri Apr 1 23:13:40 2016 -0700 ARM: dts: vf-colibri: increase NAND clock speed The NAND flash memory populated on Colibri VF61 allows faster NAND timings than the flash memory on VF50. Additionally, due to divider limitations, VF61 did clock the flash even slower than VF50. Assign the NFC clock in the module specific device trees vf500-colibri.dtsi and vf610-colibri.dtsi respectively. This increases raw read speed on Colibri VF61 by about 20%. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/vf-colibri.dtsi | 2 -- arch/arm/boot/dts/vf500-colibri.dtsi | 5 +++++ arch/arm/boot/dts/vf610-colibri.dtsi | 5 +++++ 3 files changed, 10 insertions(+), 2 deletions(-) commit 9b1a1779e97c8152d52159c4887fdef560c550e1 Author: Stefan Agner <stefan@agner.ch> Date: Fri Apr 1 23:13:39 2016 -0700 ARM: dts: vf-colibri: alias the primary FEC as ethernet0 The Vybrid based Colibri modules provide a on-module PHY which is connected to the second FEC instance FEC1. Since the on-module Ethernet port is considered as primary ethernet interface, alias fec1 as ethernet0. This also makes sure that the first MAC address provided by the boot loader gets assigned to the FEC instance used for the on-module PHY. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/vf-colibri.dtsi | 5 +++++ 1 file changed, 5 insertions(+) commit 29e88b6de00da70eba9b905919427c8e8b9e88d6 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Tue Apr 12 13:43:43 2016 +0800 ARM: dts: imx6sx-sdb: Add SAI support Introduce imx6sx-sdb-sai.dts so that it is possible to use the SAI interface. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx6sx-sdb-sai.dts | 67 ++++++++++++++++++++++++++++++++++++ arch/arm/boot/dts/imx6sx-sdb.dtsi | 16 +++++++++ 3 files changed, 84 insertions(+) commit 3883dd74f0101d3ec94b213456c5965467ac8da9 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Fri Apr 1 20:52:16 2016 -0300 bindings: fsl-imx-sdma: Document 'fsl,sdma-event-remap' property Document the 'fsl,sdma-event-remap' property and provide an example of its usage. Cc: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> .../devicetree/bindings/dma/fsl-imx-sdma.txt | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit 88b53b9c1f2da681a5fb08c79437b8cd17b356ff Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Fri Apr 1 20:52:15 2016 -0300 ARM: dts: imx6sx: Remove unused property Property 'dma-source' is not used anywhere, nor it is documented, so let's just get rid of it. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6sx.dtsi | 2 -- 1 file changed, 2 deletions(-) commit 78f31b0b01aea2d21ad2cc9da4a196c6785b6600 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Fri Apr 1 20:52:14 2016 -0300 ARM: dts: imx6sx: Fix SAI DMA index According to sdma_peripheral_type in include/linux/platform_data/dma-imx.h IMX_DMATYPE_SAI corresponds to index 24, so fix it accordingly. Suggested-by: Zidan Wang <zidan.wang@nxp.com> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6sx.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 890b53ef86da0db030059a04db8b5501ea619dc0 Author: Justin Waters <justin.waters@timesys.com> Date: Fri Apr 1 17:19:30 2016 -0400 ARM: dts: imx6q-ba16: Disable pwm2 by default pwm2 is provided on the BA16 Q7 module, but is not used on any of the current configurations. However, future platforms may utilize this device, so we are simply disabling the node rather than removing it completely. Signed-off-by: Justin Waters <justin.waters@timeys.com> Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-ba16.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 36853f9c6134633a4f4dcbbdeb29e3daf84d2a9f Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Mon Apr 11 23:01:36 2016 +0200 ARM: dts: imx: add Boundary Devices Nitrogen6_SoloX board Based on i.MX6 SoloX with 1GB of RAM. https://boundarydevices.com/product/nit6_solox-imx6/ Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx6sx-nitrogen6sx.dts | 709 +++++++++++++++++++++++++++++++ 2 files changed, 710 insertions(+) commit e0884948a48013bb2097f3e61c4f2122b22f6eb1 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Mar 28 14:10:48 2016 -0300 ARM: dts: imx6qdl-sabresd: Pass the hannstar panel compatible string It is preferred to use the panel compatible string rather than passing the LCD timings in the device tree. So pass the "hannstar,hsd100pxn1" compatible string to describe the LVDS panel on this board. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-sabresd.dtsi | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) commit 8630743bbe05ae8bd37a5396e49c7beb1736a311 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Thu Mar 31 14:33:45 2016 +0200 ARM: dts: imx6: add support for the Ka-Ro electronics 'MB7' baseboard This baseboard can be used with all TX6 SoMs, but only a certain set of combinations can be ordered by default. Add support for these combinations in mainline, so that users can easily adopt their own combination of SoM and baseboard themselves. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/imx6dl-tx6u-81xx-mb7.dts | 255 ++++++++++++++++++++++++++++ arch/arm/boot/dts/imx6q-tx6q-11x0-mb7.dts | 264 +++++++++++++++++++++++++++++ 3 files changed, 521 insertions(+) commit 7d774cacf0b5d9fc4abac00fd25df09d019619f9 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 12 15:40:42 2016 +0100 drm/i915: Use new i915_gem_object_pin_map for LRC We can use the new pin/lazy unpin API for simplicity and more performance in the execlist submission paths. v2: * Fix error handling and convert more users. * Compact some names for readability. v3: * intel_lr_context_free was not unpinning. * Special case for GPU reset which otherwise unbalances the HWS object pages pin count by running the engine initialization only (not destructors). v4: * Rebased on top of hws setup/init split. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460472042-1998-1-git-send-email-tvrtko.ursulin@linux.intel.com [tursulin: renames: s/hwd/hws/, s/obj_addr/vaddr/] Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_gem_context.c | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 82 ++++++++++++++++++--------------- drivers/gpu/drm/i915/intel_lrc.h | 7 ++- 3 files changed, 52 insertions(+), 39 deletions(-) commit 168e0461367b33ebef2a9f0e88014b572ce41cc3 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Thu Mar 31 14:33:44 2016 +0200 ARM: dts: imx6: add support for more Ka-Ro electronics modules Add support for the following i.MX6 based modules from Ka-Ro electronics GmbH: TX6S-8034: Processor Freescale i.MX 6 Solo, 800MHz RAM 256MiB DDR3 SDRAM ROM 128MiB NAND Flash Power supply Single 3.1V to 5.5V Size 31mm SO-DIMM Temp. Range industrial grade (-40°C/-25°C to 105°C Tj) TX6S-8035: Processor Freescale i.MX 6 Solo, 800MHz RAM 512MiB DDR3 SDRAM ROM 4GiB eMMC Power supply Single 3.1V to 5.5V Size 31mm SO-DIMM Temp. Range industrial grade (-40°C/-25°C to 105°C Tj) TX6U-8033: Processor Freescale i.MX 6 Dual Lite, 800MHz RAM 1GiB DDR3 SDRAM ROM 4GiB eMMC Power supply Single 3.1V to 5.5V Size 31mm SO-DIMM Temp. Range industrial grade (-40°C/-25°C to 105°C Tj) TX6Q-1036: Processor Freescale i.MX 6Quad, 1GHz RAM 1GB DDR3 SDRAM 64-bit ROM 8GiB eMMC Power supply Single 3.1V to 5.5V Size 31mm SO-DIMM Temp. Range Extended Consumer Grade (-20°C to 105°C Tj) Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 4 + arch/arm/boot/dts/imx6dl-tx6s-8034.dts | 237 ++++++++++++++++++++++++++++++ arch/arm/boot/dts/imx6dl-tx6s-8035.dts | 253 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/imx6dl-tx6u-8033.dts | 248 ++++++++++++++++++++++++++++++++ arch/arm/boot/dts/imx6q-tx6q-1036.dts | 252 ++++++++++++++++++++++++++++++++ 5 files changed, 994 insertions(+) commit 720f4340e40a03f6f063083e20f90403632ff031 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Thu Mar 31 14:33:43 2016 +0200 ARM: dts: imx6-tx6: enable support for rtscts on UARTs Add missing pinctrl for the RTS/CTS lines to uart1 and set the fsl,uart-has-rtscts property on all UARTs to enable support for HW handshake. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 96de03677f57fa1455d94fa289cfafff58727d0a Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Thu Mar 31 14:33:42 2016 +0200 ARM: dts: imx6-tx6: remove LED pinctrl setting from hoggrp Move the pinctrl setting for the board LED from the hoggrp node to a separate node referenced by the LED driver, so that the pin is free to be used for different purpose when the LED driver is disabled. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit 7281795fa40b92011567592a1c3c54f673a80ada Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Thu Mar 31 14:33:41 2016 +0200 ARM: dts: imx6-tx6: remove regulator bus DT maintainers don't like the 'simple-bus' container around the regulator nodes. So remove it. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 166 +++++++++++++++++-------------------- 1 file changed, 75 insertions(+), 91 deletions(-) commit a7574ab01c4f6954fc9c5bd9d5d5cdd401618c88 Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:47 2016 +0200 ARM: dts: imx: add Boundary Devices Nitrogen6_MAX QP board Based on i.MX6 Quad Plus with 4GB of RAM. https://boundarydevices.com/product/nitrogen6max/ Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx6qp-nitrogen6_max.dts | 59 ++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+) commit 9cbda37b8730c91c5960f333db9ea1bc9813d46d Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue Mar 8 09:04:02 2016 +0100 ARM: dts: imx6qdl-tx6: add mdio node for ethernet phy Add mdio node and an appropriate PHY configuration to enable use of the PHY interrupt for link status changes. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit c4aca663aebf2d1de3e7b6ab15680bf67ad0d678 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue Mar 8 09:04:01 2016 +0100 ARM: dts: imx6-tx6: remove container node around pinctrl nodes Remove the function node around the pinctrl nodes that was obsoleted by commit 5fcdf6a7ed95 ("pinctrl: imx: Allow parsing DT without function nodes"), we can save this container node. Also move the iomux node to the bottom of the file to improve readability of the file. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6dl-tx6u-811x.dts | 18 +- arch/arm/boot/dts/imx6q-tx6q-1020-comtft.dts | 30 +- arch/arm/boot/dts/imx6q-tx6q-1020.dts | 30 +- arch/arm/boot/dts/imx6q-tx6q-1110.dts | 18 +- arch/arm/boot/dts/imx6qdl-tx6.dtsi | 551 ++++++++++++++------------- 5 files changed, 321 insertions(+), 326 deletions(-) commit 0fd646d0e7dff4054cb43f4ac87271da6151a070 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue Mar 8 09:04:00 2016 +0100 ARM: dts: imx6-tx6: disable the spi node by default The spidev driver doesn't like to be instantiated via a naked 'spidev' compatible, though it is very convenient to invoke it this way without a dedicated SPI device for basic functional testing. Disable the spi node by default to silence the WARN_ON() from the spidev driver, but leave the configuration intact otherwise. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit abe3e2b9025068c36b0cf5091464545071c3fcfe Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue Mar 8 09:03:58 2016 +0100 ARM: dts: imx6-tx6: cleanup; no functional change Add an empty line between properties and subnode in the clocks node. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6qdl-tx6.dtsi | 1 + 1 file changed, 1 insertion(+) commit e06dd63024a70316318bc737a601ea0c93d07f05 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Tue Mar 8 09:03:57 2016 +0100 ARM: dts: imx6-tx6: Relicense the Ka-Ro DT files under GPLv2/X11 GPLv2-only devicetrees make reuse difficult for software components licensed under a different license. The consensus is that a GPL/X11 dual-license should allow all necessary uses, so relicense the imx6*-tx6* files to this combination. Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6dl-tx6dl-comtft.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6dl-tx6u-801x.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6dl-tx6u-811x.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6q-tx6q-1010-comtft.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6q-tx6q-1010.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6q-tx6q-1020-comtft.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6q-tx6q-1020.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6q-tx6q-1110.dts | 42 ++++++++++++++++++++++++---- arch/arm/boot/dts/imx6qdl-tx6.dtsi | 42 ++++++++++++++++++++++++---- 9 files changed, 324 insertions(+), 54 deletions(-) commit 78e62436d552c9a3127916efaca185ac3c9bd593 Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Wed Mar 9 20:44:34 2016 +0100 ARM: dts: imx25-pinfunc: remove SION for pins with an UART handshaking input mode With SION set the level on such a pin is reported to the UART. So for example when the CS5 pin is configured for GPIO mode and the level changes this triggers an RTS interrupt on uart5. Adding some severity to this issue: The imx uart driver currently doesn't handle correctly irqs for changes on RI and DCD which are enabled automatically when the respective UART is driven in DTE mode (that is, has the fsl,dte-mode property set in the device tree). This results in a stuck machine because the irq isn't cleared and so stalls the CPU. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx25-pinfunc.h | 118 +++++++++++++++++++------------------- 1 file changed, 59 insertions(+), 59 deletions(-) commit 2fcc786bf545f7218412cdc501b34cb98668df6e Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Wed Mar 9 20:44:33 2016 +0100 ARM: dts: imx25-pinfunc: add all UART mux modes Apart from a few additions this also contains two fixes where the daisy chain input selection register was missing. Moreover dropped _MUX from some pins for consistency. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx25-pinfunc.h | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) commit e85225d70831e5b4c2f0fcc928714da68f9ddac3 Author: Justin Waters <justin.waters@timesys.com> Date: Wed Mar 2 11:29:13 2016 -0500 ARM: dts: imx: ba16: Add correct PCIe Tx Values Utilize the new PCIe Tx configuration to properly support the correct values. Signed-off-by: Justin Waters <justin.waters@timesys.com> Signed-off-by: Akshay Bhat <akshay.bhat@timesys.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx6q-ba16.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit cf4534824f8ddea1ac9535b7a465821cd2fbe933 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Fri Mar 4 13:37:23 2016 +0100 ARM: dts: imx6ul: add support for Ka-Ro electronics TXUL mainboard Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/imx6ul-tx6ul-mainboard.dts | 271 +++++++++++++++++++++++++++ 2 files changed, 273 insertions(+), 1 deletion(-) commit 5434c913b6cc3339b95140eb9075eb1ca4cb6ff9 Author: Lothar Waßmann <LW@KARO-electronics.de> Date: Fri Mar 4 13:37:22 2016 +0100 ARM: dts: imx6ul: add support for Ka-Ro electronics TXUL modules The TXUL-0010/-0011 modules are Computers On Module manufactured by Ka-Ro electronics GmbH with the following characteristics: Processor Freescale i.MX 6UltraLite MCIMX6G2, 528 MHz RAM 256MB 16-bit DDR3 SDRAM ROM 128MB NAND Flash (TXUL-0010) / 4GB eMMC (TXUL-0011) Power supply Single 3.3 to 5V Size 26mm SO-DIMM Temp. Range -40°C to 85°C Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 4 +- arch/arm/boot/dts/imx6ul-tx6ul-0010.dts | 53 ++ arch/arm/boot/dts/imx6ul-tx6ul-0011.dts | 68 +++ arch/arm/boot/dts/imx6ul-tx6ul.dtsi | 973 ++++++++++++++++++++++++++++++++ 4 files changed, 1097 insertions(+), 1 deletion(-) commit 04794adbdde0008215748414e63a5c3734e1f9fc Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 12 15:40:41 2016 +0100 drm/i915: Split execlists hardware status page initialisation from setup Split the hardware status page into setup and initialisation, where setup means setting up the driver state to support the engine, and initialization means programming the hardware with the before set up state. This way the design matches the design of the engine setup/init code which is split in the same fashion and it enables the stages to be used in a balanced fashion (engine setup - hws setup, engine init - hws init). This will enable the upcoming improvements to slot in without any kludges on the GPU reset path. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Suggested-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_lrc.c | 50 ++++++++++++++++++++++------------------ 1 file changed, 27 insertions(+), 23 deletions(-) commit 47a541c3e19374ec9f5d3d96730a922e8480dda5 Author: Guenter Roeck <linux@roeck-us.net> Date: Fri Apr 1 17:51:54 2016 -0700 x86/platform: Remove unused get_bios_ebda_length() function get_bios_ebda_length() uses min_t() without including linux/kernel.h. This may result in build errors with some configurations. Since the function is not used anywhere in the kernel, let's just drop it. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Waychison <mikew@google.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459558314-5625-1-git-send-email-linux@roeck-us.net Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/bios_ebda.h | 21 --------------------- 1 file changed, 21 deletions(-) commit 77f0862d0d6874a73f83032b7ffd6d204fc8646c Author: Stefan Agner <stefan@agner.ch> Date: Mon Apr 4 22:28:40 2016 -0700 ARM: dts: vf610-colibri: enable display controller Enable dcu node which is used by the DCU DRM driver. Assign the 5.7" EDT panel with VGA resolution which Toradex sells often with the evaluation board. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/vf-colibri-eval-v3.dtsi | 16 +++++++++++++++ arch/arm/boot/dts/vf-colibri.dtsi | 33 +++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) commit 1d0fc33f4666f1bd29990f154767aa5d374c9e19 Author: Stefan Agner <stefan@agner.ch> Date: Mon Apr 4 22:28:39 2016 -0700 ARM: dts: vf610: add display nodes Add the dcu and tcon nodes to enable the Display Controller Unit and Timing Controller in Vybrid's SoC level device-tree file. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/vfxxx.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit 56354959cfecd6501cd69c49edca483a7b11d461 Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Thu Apr 7 15:50:57 2016 +0200 ARM: dts: imx: add Boundary Devices Nitrogen7 board Based on i.MX7 Dual with 1GB of RAM. https://boundarydevices.com/product/nitrogen7/ Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/imx7d-nitrogen7.dts | 745 ++++++++++++++++++++++++++++++++++ 2 files changed, 746 insertions(+) commit c147401d45b84a66efa8cea6c74e130dc1ac3e3b Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:44 2016 +0200 ARM: dts: imx7d: add flexcan support Add the device nodes for the i.MX7 FlexCAN buses. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx7d.dtsi | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit e8ed73f691bdbfaed02ad63a42e8332d7cafa8bd Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:43 2016 +0200 ARM: dts: imx7d: add lcdif support Add the device node for the i.MX7 eLCDIF interface. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/boot/dts/imx7d.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 60a0e2039e3df6c0a2b896bd78af36ff36fb629c Author: Andy Lutomirski <luto@kernel.org> Date: Mon Apr 4 08:46:22 2016 -0700 x86/extable: Add a comment about early exception handlers Borislav asked for a comment explaining why all exception handlers are allowed early. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/5f1dcd6919f4a5923959a8065cb2c04d9dac1412.1459784772.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/extable.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit b828b79fcced0e66492590707649dbfaea6435e6 Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:40 2016 -0700 x86/msr: Set the return value to zero when native_rdmsr_safe() fails This will cause unchecked native_rdmsr_safe() failures to return deterministic results. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/515fb611449a755312a476cfe11675906e7ddf6c.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/msr.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 4985ce15a397e9b6541548efe3b9ffac2dda9127 Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:39 2016 -0700 x86/paravirt: Make "unsafe" MSR accesses unsafe even if PARAVIRT=y Enabling CONFIG_PARAVIRT had an unintended side effect: rdmsr() turned into rdmsr_safe() and wrmsr() turned into wrmsr_safe(), even on bare metal. Undo that by using the new unsafe paravirt MSR callbacks. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/414fabd6d3527703077c6c2a797223d0a9c3b081.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/paravirt.h | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit dd2f4a004b016bbfb64f1de49cb45e66232e40a6 Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:38 2016 -0700 x86/paravirt: Add paravirt_{read,write}_msr() This adds paravirt callbacks for unsafe MSR access. On native, they call native_{read,write}_msr(). On Xen, they use xen_{read,write}_msr_safe(). Nothing uses them yet for ease of bisection. The next patch will use them in rdmsrl(), wrmsrl(), etc. I intentionally didn't make them warn on #GP on Xen. I think that should be done separately by the Xen maintainers. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/880eebc5dcd2ad9f310d41345f82061ea500e9fa.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/msr.h | 5 +++-- arch/x86/include/asm/paravirt.h | 11 +++++++++++ arch/x86/include/asm/paravirt_types.h | 10 ++++++++-- arch/x86/kernel/paravirt.c | 2 ++ arch/x86/xen/enlighten.c | 23 +++++++++++++++++++++++ 5 files changed, 47 insertions(+), 4 deletions(-) commit fbd704374d111bed16a19261176fa30e2379c87c Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:37 2016 -0700 x86/msr: Carry on after a non-"safe" MSR access fails This demotes an OOPS and likely panic due to a failed non-"safe" MSR access to a WARN_ONCE() and, for RDMSR, a return value of zero. To be clear, this type of failure should *not* happen. This patch exists to minimize the chance of nasty undebuggable failures happening when a CONFIG_PARAVIRT=y bug in the non-"safe" MSR helpers gets fixed. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/26567b216aae70e795938f4b567eace5a0eb90ba.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/msr.h | 10 ++++++++-- arch/x86/mm/extable.c | 27 +++++++++++++++++++++++++++ 2 files changed, 35 insertions(+), 2 deletions(-) commit c2ee03b2a94d7ba692cf6206bbe069d5bfcc20ed Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:36 2016 -0700 x86/paravirt: Add _safe to the read_ms()r and write_msr() PV callbacks These callbacks match the _safe variants, so name them accordingly. This will make room for unsafe PV callbacks. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/9ee3fb6a196a514c93325bdfa15594beecf04876.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/paravirt.h | 33 +++++++++++++++++---------------- arch/x86/include/asm/paravirt_types.h | 8 ++++---- arch/x86/kernel/paravirt.c | 4 ++-- arch/x86/xen/enlighten.c | 4 ++-- 4 files changed, 25 insertions(+), 24 deletions(-) commit ae7ef45e12354a1e2f6013b46df0c9f5bbb6ffbe Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:35 2016 -0700 x86/traps: Enable all exception handler callbacks early Now that early_fixup_exception() has pt_regs, we can just call fixup_exception() from it. This will make fancy exception handlers work early. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/20fc047d926150cb08cb9b9f2923519b07ec1a15.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/extable.c | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) commit 0e861fbb5bda79b871341ef2a9a8059765cbe8a4 Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:34 2016 -0700 x86/head: Move early exception panic code into early_fixup_exception() This removes a bunch of assembly and adds some C code instead. It changes the actual printouts on both 32-bit and 64-bit kernels, but they still seem okay. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/4085070316fc3ab29538d3fcfe282648d1d4ee2e.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uaccess.h | 2 +- arch/x86/kernel/head_32.S | 49 +++++------------------------------------- arch/x86/kernel/head_64.S | 45 ++------------------------------------ arch/x86/mm/extable.c | 29 ++++++++++++++++++++----- 4 files changed, 32 insertions(+), 93 deletions(-) commit 0d0efc07f3df677d7622bb760f8e2920b5e33f42 Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:33 2016 -0700 x86/head: Move the early NMI fixup into C C is nicer than asm. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/dd068269f8d59fe44e9e43a50d0efd67da65c2b5.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/head_32.S | 7 ------- arch/x86/kernel/head_64.S | 6 ------ arch/x86/mm/extable.c | 5 +++++ 3 files changed, 5 insertions(+), 13 deletions(-) commit 7bbcdb1ca4d2fd69094ee89c18601b396531ca9f Author: Andy Lutomirski <luto@kernel.org> Date: Sat Apr 2 07:01:32 2016 -0700 x86/head: Pass a real pt_regs and trapnr to early_fixup_exception() early_fixup_exception() is limited by the fact that it doesn't have a real struct pt_regs. Change both the 32-bit and 64-bit asm and the C code to pass and accept a real pt_regs. Tested-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: KVM list <kvm@vger.kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel <Xen-devel@lists.xen.org> Link: http://lkml.kernel.org/r/e3fb680fcfd5e23e38237e8328b64a25cc121d37.1459605520.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/uaccess.h | 2 +- arch/x86/kernel/head_32.S | 74 +++++++++++++++++++++++++++++------------- arch/x86/kernel/head_64.S | 68 ++++++++++++++++++++------------------ arch/x86/mm/extable.c | 6 ++-- 4 files changed, 92 insertions(+), 58 deletions(-) commit 6aa6dbfced51dec6cde159c6167ad3dad6add823 Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:55 2016 +0200 x86/fpu: Get rid of x87 math exception helpers ... and integrate their functionality into their single user fpu__exception_code(). No functionality change. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-7-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/fpu/core.c | 44 +++++++++++++------------------------------- 1 file changed, 13 insertions(+), 31 deletions(-) commit de82fbc3823b7b15ee03466ebfb1c5ec7cc1a941 Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:54 2016 +0200 x86/fpu: Remove check_fpu() indirection Rename it to fpu__init_check_bugs() and do the CPU feature check at entry, thus getting rid of the old fpu__init_check_bugs() wrapper. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-6-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/fpu/bugs.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit eff4677e9fb9b680d1d5f6ba079116548d072b7e Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:53 2016 +0200 x86/tsc: Save an indentation level in recalibrate_cpu_khz() ... by flipping the check. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-5-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/tsc.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit a841cca74ea7612508aee161c89987b2646ed769 Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:52 2016 +0200 x86/tsc: Do not check X86_FEATURE_CONSTANT_TSC in notifier call ... because the notifier-registering routine already does that. Also, rename cpufreq_tsc() init call to something more telling. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-4-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/tsc.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 425d8c2fc5e6dddbad083502bb77c7beae545620 Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:51 2016 +0200 x86/cpu: Simplify extended APIC ID detection on AMD Both if-branches are under if (boot_cpu_has(X86_FEATURE_APIC)), unify them. Also, simplify the test for bits: - 17 ("ApicExtBrdCst: APIC extended broadcast enable") and - 18 ("ApicExtId: APIC extended ID enable.") in "D18F0x68 Link Transaction Control." No functionality change. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/amd.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit 78df526c74a4db696e1e058b9869471937d0773b Author: Borislav Petkov <bp@suse.de> Date: Tue Apr 5 08:29:50 2016 +0200 x86/fpu/regset: Replace static_cpu_has() usage with boot_cpu_has() fpregs_{g,s}et() are not sizzling-hot paths to justify the need for static_cpu_has(). Use the normal boot_cpu_has() helper. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459837795-2588-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/fpu/regset.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 782511b00f749cfebc0cb5d6ce960de5410c221d Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:25:03 2016 +0200 x86/cpufeature: Replace cpu_has_xsaves with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: <kvm@vger.kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459801503-15600-11-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 6 ------ arch/x86/kernel/fpu/xstate.c | 10 +++++----- arch/x86/kvm/vmx.c | 2 +- arch/x86/kvm/x86.c | 4 ++-- 4 files changed, 8 insertions(+), 14 deletions(-) commit d366bf7eb99d0644e47ecd52c184d7ad95df02f2 Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:25:02 2016 +0200 x86/cpufeature: Replace cpu_has_xsave with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: kvm@vger.kernel.org Link: http://lkml.kernel.org/r/1459801503-15600-10-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/ia32/ia32_signal.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/fpu/regset.c | 8 ++++---- arch/x86/kernel/fpu/xstate.c | 8 ++++---- arch/x86/kernel/signal.c | 4 ++-- arch/x86/kvm/cpuid.c | 2 +- arch/x86/kvm/x86.c | 12 ++++++------ 7 files changed, 18 insertions(+), 19 deletions(-) commit 01f8fd7379149fb9a4046e76617958bf771f856f Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:25:01 2016 +0200 x86/cpufeature: Replace cpu_has_fxsr with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459801503-15600-9-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/fpu/core.c | 6 +++--- arch/x86/kernel/fpu/init.c | 6 +++--- arch/x86/kernel/fpu/regset.c | 13 ++++++++----- 4 files changed, 14 insertions(+), 12 deletions(-) commit 93984fbd4e33cc861d5b49caed02a02cbfb01340 Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:25:00 2016 +0200 x86/cpufeature: Replace cpu_has_apic with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: iommu@lists.linux-foundation.org Cc: linux-pm@vger.kernel.org Cc: oprofile-list@lists.sf.net Link: http://lkml.kernel.org/r/1459801503-15600-8-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/core.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/irq_work.h | 2 +- arch/x86/kernel/acpi/boot.c | 8 ++++---- arch/x86/kernel/apic/apic.c | 20 ++++++++++---------- arch/x86/kernel/apic/apic_noop.c | 4 ++-- arch/x86/kernel/apic/io_apic.c | 2 +- arch/x86/kernel/apic/ipi.c | 2 +- arch/x86/kernel/apic/vector.c | 2 +- arch/x86/kernel/cpu/amd.c | 4 ++-- arch/x86/kernel/cpu/intel.c | 2 +- arch/x86/kernel/cpu/mcheck/mce_intel.c | 2 +- arch/x86/kernel/cpu/mcheck/therm_throt.c | 2 +- arch/x86/kernel/devicetree.c | 2 +- arch/x86/kernel/smpboot.c | 2 +- arch/x86/oprofile/nmi_int.c | 2 +- arch/x86/pci/xen.c | 2 +- drivers/cpufreq/longhaul.c | 2 +- drivers/iommu/irq_remapping.c | 2 +- 19 files changed, 32 insertions(+), 33 deletions(-) commit 59e21e3d00e6bc23186763c3e0bf11baf8924124 Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:59 2016 +0200 x86/cpufeature: Replace cpu_has_tsc with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Thomas Sailer <t.sailer@alumni.ethz.ch> Link: http://lkml.kernel.org/r/1459801503-15600-7-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/tsc.h | 2 +- arch/x86/kernel/apic/apic.c | 10 +++++----- arch/x86/kernel/cpu/common.c | 2 +- arch/x86/kernel/tsc.c | 12 ++++++------ drivers/input/joystick/analog.c | 6 +++--- drivers/net/hamradio/baycom_epp.c | 8 ++++---- 7 files changed, 20 insertions(+), 21 deletions(-) commit a402a8dffc9f838b413c5ee0317d2d3184968f5b Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:58 2016 +0200 x86/cpufeature: Replace cpu_has_fpu with boot_cpu_has() usage Use static_cpu_has() in the timing-sensitive paths in fpstate_init() and fpu__copy(). While at it, simplify the use in init_cyrix() and get rid of the ternary operator. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459801503-15600-6-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/cpu/cyrix.c | 2 +- arch/x86/kernel/fpu/bugs.c | 2 +- arch/x86/kernel/fpu/core.c | 4 ++-- arch/x86/kernel/fpu/init.c | 8 ++++---- 5 files changed, 8 insertions(+), 9 deletions(-) commit dda9edf7c1fdc0d7a7ed7f46299a26282190fb6d Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:57 2016 +0200 x86/cpufeature: Replace cpu_has_xmm with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459801503-15600-5-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/xor_32.h | 2 +- arch/x86/kernel/fpu/core.c | 2 +- arch/x86/kernel/fpu/init.c | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) commit da154e82af4d0c63e2334d5b3822426600b0490f Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:56 2016 +0200 x86/cpufeature: Replace cpu_has_avx with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-crypto@vger.kernel.org Link: http://lkml.kernel.org/r/1459801503-15600-4-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/aesni-intel_glue.c | 2 +- arch/x86/crypto/camellia_aesni_avx2_glue.c | 3 ++- arch/x86/crypto/camellia_aesni_avx_glue.c | 2 +- arch/x86/crypto/chacha20_glue.c | 3 ++- arch/x86/crypto/poly1305_glue.c | 3 ++- arch/x86/crypto/sha1_ssse3_glue.c | 2 +- arch/x86/crypto/sha256_ssse3_glue.c | 2 +- arch/x86/crypto/sha512_ssse3_glue.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/xor_avx.h | 4 ++-- 10 files changed, 13 insertions(+), 11 deletions(-) commit 1f4dd7938ea575a2d1972e180eaef31e6edb1808 Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:55 2016 +0200 x86/cpufeature: Replace cpu_has_aes with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-crypto@vger.kernel.org Link: http://lkml.kernel.org/r/1459801503-15600-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/camellia_aesni_avx2_glue.c | 3 ++- arch/x86/crypto/camellia_aesni_avx_glue.c | 4 +++- arch/x86/include/asm/cpufeature.h | 1 - 3 files changed, 5 insertions(+), 3 deletions(-) commit abcfdfe07de75f830cbec1aa3eb17833a0166697 Author: Borislav Petkov <bp@suse.de> Date: Mon Apr 4 22:24:54 2016 +0200 x86/cpufeature: Replace cpu_has_avx2 with boot_cpu_has() usage Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-crypto@vger.kernel.org Link: http://lkml.kernel.org/r/1459801503-15600-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/camellia_aesni_avx2_glue.c | 2 +- arch/x86/crypto/chacha20_glue.c | 2 +- arch/x86/crypto/poly1305_glue.c | 2 +- arch/x86/crypto/serpent_avx2_glue.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - 5 files changed, 4 insertions(+), 5 deletions(-) commit 95a8e746f82bdda5d8a443b6557c930782d65b86 Merge: d8d1c35 a312549 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 11:36:44 2016 +0200 Merge branch 'x86/urgent' into x86/asm to pick up dependent fixes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit d8d1c35139481ee8e292d91cd3fd35a6b3a316eb Merge: cb44d0c 1886297 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 11:36:19 2016 +0200 Merge branch 'x86/mm' into x86/asm to resolve conflict and to create common base Conflicts: arch/x86/include/asm/cpufeature.h Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 7b5ca4533f1ac023a16e44a2a1680121272723f9 Merge: f55532a 69c542e Author: Shawn Guo <shawnguo@kernel.org> Date: Wed Apr 13 17:36:03 2016 +0800 Merge tag 'imx-clk-4.7' into imx/dt-clkdep The i.MX clock update for 4.7: - Register SAI clk as shared clocks to support SAI audio on i.MX6SX - Add the missing ckil clock for i.MX7 - Update clk-gate2 and vf610 clock driver to prepare for suspend support on VF610 - Fix DCU clock configurations and add TCON ipg clock to support DRM display on VF610 commit 1886297ce0c8d563a08c8a8c4c0b97743e06cd37 Author: Toshi Kani <toshi.kani@hpe.com> Date: Mon Apr 11 13:36:00 2016 -0600 x86/mm/pat: Fix BUG_ON() in mmap_mem() on QEMU/i386 The following BUG_ON() crash was reported on QEMU/i386: kernel BUG at arch/x86/mm/physaddr.c:79! Call Trace: phys_mem_access_prot_allowed mmap_mem ? mmap_region mmap_region do_mmap vm_mmap_pgoff SyS_mmap_pgoff do_int80_syscall_32 entry_INT80_32 after commit: edfe63ec97ed ("x86/mtrr: Fix Xorg crashes in Qemu sessions") PAT is now set to disabled state when MTRRs are disabled. Thus, reactivating the __pa(high_memory) check in phys_mem_access_prot_allowed(). When CONFIG_DEBUG_VIRTUAL is set, __pa() calls __phys_addr(), which in turn calls slow_virt_to_phys() for 'high_memory'. Because 'high_memory' is set to (the max direct mapped virt addr + 1), it is not a valid virtual address. Hence, slow_virt_to_phys() returns 0 and hit the BUG_ON. Using __pa_nodebug() instead of __pa() will fix this BUG_ON. However, this code block, originally written for Pentiums and earlier, is no longer adequate since a 32-bit Xen guest has MTRRs disabled and supports ZONE_HIGHMEM. In this setup, this code sets UC attribute for accessing RAM in high memory range. Delete this code block as it has been unused for a long time. Reported-by: kernel test robot <ying.huang@linux.intel.com> Reviewed-by: Borislav Petkov <bp@suse.de> Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: David Vrabel <david.vrabel@citrix.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1460403360-25441-1-git-send-email-toshi.kani@hpe.com Link: https://lkml.org/lkml/2016/4/1/608 Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/pat.c | 19 ------------------- 1 file changed, 19 deletions(-) commit d86786474babdf1a2b0dfe245e38f18afc203cc2 Author: Erin Lo <erin.lo@mediatek.com> Date: Wed Apr 13 15:07:43 2016 +0800 ARM: mediatek: Add MT2701 config options for mediatek SoCs. The upcoming MTK pinctrl driver have a big pin table for each SoC and we don't want to bloat the kernel binary if we don't need it. Add config options so we can build for one SoC only. Add MT2701. Signed-off-by: Erin Lo <erin.lo@mediatek.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> arch/arm/mach-mediatek/Kconfig | 4 ++++ 1 file changed, 4 insertions(+) commit afa05e55a047f8aa7c865dde5353d96d136aeab2 Author: Alim Akhtar <alim.akhtar@samsung.com> Date: Wed Apr 13 10:12:03 2016 +0530 arm64: dts: Add nodes for pdma0 and pdma1 for exynos7 This patch adds device tree nodes for pdma0 and pdma1 controllers found on exynos7 SoCs. Signed-off-by: Alim Akhtar <alim.akhtar@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm64/boot/dts/exynos/exynos7.dtsi | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) commit 8369337e5563245307671208ad555ed1e8b4bb5a Author: Biao Huang <biao.huang@mediatek.com> Date: Wed Jan 27 09:24:43 2016 +0800 arm: dts: Add pinctrl/GPIO/EINT node for mt2701 Add pinctrl and GPIO node to mt2701.dtsi Signed-off-by: Biao Huang <biao.huang@mediatek.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> arch/arm/boot/dts/mt2701.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) commit fb90a6e93c0684ab2629a42462400603aa829b9c Author: Rabin Vincent <rabinv@axis.com> Date: Mon Apr 4 15:42:02 2016 +0200 sched/debug: Don't dump sched debug info in SysRq-W sysrq_sched_debug_show() can dump a lot of information. Don't print out all that if we're just trying to get a list of blocked tasks (SysRq-W). The information is still accessible with SysRq-T. Signed-off-by: Rabin Vincent <rabinv@axis.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459777322-30902-1-git-send-email-rabin.vincent@axis.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit cb44d0cfc2969999a4d9e20e4fd8749fec6c5498 Merge: 482dd2e d7847a7 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 11:15:39 2016 +0200 Merge branch 'x86/cpu' into x86/asm, to merge more patches Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 06e520c4f067e7284fded10656acca924123c58e Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:50 2016 +0900 ARM: dts: s5p: Fix DTC unit name warnings in SMDKv210 board Fix following DTC warnings in SMDKv210 board: Warning (unit_address_vs_reg): Node /soc/fimd@f8000000/display-timings/timing@0 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/s5pv210-smdkv210.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4185c53f0127229079303c194fe6a668fc337c8f Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:49 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos5440 Fix following DTC warnings in Exynos5440 boards: Warning (unit_address_vs_reg): Node /pinctrl has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /rtc has a reg or ranges property, but no unit name Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5440.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fed3b4aa0ac5bcb29f844186182d4fca2af460ed Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:48 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in SMDK5420 Fix following DTC warnings in Exynos5420 SMDK5420: Warning (unit_address_vs_reg): Node /dp-controller@145B0000/display-timings/timing@0 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5420-smdk5420.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bea7eef6949ca613b49bddd39d108f90f75c95fd Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:47 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Peach Pit Fix following DTC warnings in Exynos5420 Peach Pit: Warning (unit_address_vs_reg): Node /dp-controller@145B0000/ports/port@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c@12CD0000/lvds-bridge@48/ports/port@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c@12CD0000/lvds-bridge@48/ports/port@1 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5420-peach-pit.dts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 938d02932e95cc900f3c11ba978d16bb8e8a11b6 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:46 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos542x Fix following DTC warnings in all Exynos542x/5800 boards: Warning (unit_address_vs_reg): Node /video-phy@10040728 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /video-phy@10040714 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /usb@12000000 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /usb@12000000/dwc3 has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /usb@12400000 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /usb@12400000/dwc3 has a reg or ranges property, but no unit name Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5420.dtsi | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 5c9cbade0629a7752acb87c16c1f25112aecc69f Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:45 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos5250 Fix following DTC warnings in all Exynos5250 boards: Warning (unit_address_vs_reg): Node /dp-controller@145B0000/display-timings/timing@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /usb@12000000 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /usb@12000000/dwc3 has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /hdmi has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /mixer has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /video-phy@10040720 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /fixed-regulator@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /fixed-regulator@1 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /fixed-regulator@2 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c@12C70000/trackpad has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /i2c@12CD0000/lvds-bridge@20/ports/port@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c@12CD0000/lvds-bridge@20/ports/port@1 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c-arbitrator/i2c@0/embedded-controller has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /i2c-arbitrator/i2c@0/power-regulator has a reg or ranges property, but no unit name Warning (unit_address_vs_reg): Node /i2c@12CA0000/embedded-controller has a reg or ranges property, but no unit name Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos5250-arndale.dts | 2 +- arch/arm/boot/dts/exynos5250-smdk5250.dts | 8 ++++---- arch/arm/boot/dts/exynos5250-snow-common.dtsi | 12 ++++++------ arch/arm/boot/dts/exynos5250-spring.dts | 2 +- arch/arm/boot/dts/exynos5250.dtsi | 10 +++++----- 5 files changed, 17 insertions(+), 17 deletions(-) commit c344c724eb16df5b5d864ce864bc24dc3c7ddd58 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:44 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos4x12 Fix following DTC warnings in Exynos4x12 boards: Warning (unit_address_vs_reg): Node /camera/fimc-is@12000000/pmu has a reg or ranges property, but no unit name Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos4x12.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 26ee29a657aa849da308bda94562c6d6bd398a3f Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:43 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Trats2 board Fix following DTC warnings in Trats2 board: Warning (unit_address_vs_reg): Node /i2c-gpio-1/max77693@66/regulators/ESAFEOUT1@1 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c-gpio-1/max77693@66/regulators/ESAFEOUT2@2 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /i2c-gpio-1/max77693@66/regulators/CHARGER@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /thermistor-ap@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /thermistor-battery@1 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos4412-trats2.dts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 72c4b2b6be454e0be8fbbe3beb55b6dce4c0978f Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:42 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos4 Fix following DTC warnings in all Exynos4 boards: Warning (unit_address_vs_reg): Node /soc/video-phy@10020710 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos4.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bb72cadef952525844bff169ddb4af016666fedc Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:41 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in Exynos3250 Fix following DTC warnings in Exynos3250 boards: Warning (unit_address_vs_reg): Node /soc/video-phy@10020710 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos3250.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 31d3f3241e74e085f4736699b8b10d17f95c1aac Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 6 11:00:40 2016 +0900 ARM: dts: exynos: Fix DTC unit name warnings in cros-adc-thermistors Fix following DTC warnings in cros-adc-thermistors: Warning (unit_address_vs_reg): Node /adc@12D10000/ncp15wb473@3 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /adc@12D10000/ncp15wb473@4 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /adc@12D10000/ncp15wb473@5 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /adc@12D10000/ncp15wb473@6 has a unit name, but no reg property Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/cros-adc-thermistors.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 399fc1847c62b4a4b8f6bc446f1bd352234c64a1 Author: Markus Reichl <m.reichl@fivetechno.de> Date: Mon Apr 4 11:55:13 2016 +0200 ARM: dts: exynos: Add eMMC and SD regulator supplies to Odroid XU3/XU4 Add vmmc and vqmmc supplies from MF circuit sheets for eMMC and SD on odroid XU3 and XU4 to avoid warnings: dwmmc_exynos 12200000.mmc: Looking up vmmc-supply property in node /mmc@12200000 failed Also remove their always_on properties so the regulators could be disabled when not used. Signed-off-by: Markus Reichl <m.reichl@fivetechno.de> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos5422-odroidxu3-common.dtsi | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) commit e94cfa067bf702e97edd0723fed8a4001e2be4e5 Merge: f1be903 e70c7ae Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Apr 13 11:05:00 2016 +0200 Merge tag 'samsung-dt-exynos3250-artik5-4.7' into next/dt Topic branch for Device Tree changes for Exynos 3250 for v4.7: Merge necessary new clocks from Sylwester (used by new board) and add support for Exynos3250-based Artik5 board. commit bf92b1feb658f6a262daf3a87d790997a1dca0ff Author: Davidlohr Bueso <dave@stgolabs.net> Date: Wed Apr 6 10:05:15 2016 +0200 x86/mce: Remove explicit smp_rmb() when starting CPUs sync mce_start() has an explicit smp_wmb() to serialize writes to global_nwo and mce_callin. However, atomic_inc_return() implies barriers on both sides of the call, as such simply rely on this full SMP barrier. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458602396-840-1-git-send-email-dave@stgolabs.net Link: http://lkml.kernel.org/r/1459929916-12852-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mcheck/mce.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 69385f8879344f4a1f078f761bd3523fcf697131 Author: Borislav Petkov <bp@suse.de> Date: Wed Apr 6 10:05:14 2016 +0200 x86/RAS: Rename AMD MCE injector config item ... to be the same like the file name of injection module itself to avoid confusion when grepping. No functionality change. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Link: http://lkml.kernel.org/r/1459929916-12852-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/ras/Kconfig | 2 +- arch/x86/ras/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit e465de1cd5e1759e40f077bac287de60d56ad06c Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Apr 6 17:35:07 2016 +0300 perf/x86/intel/pt: Use boot_cpu_has() because it's there At the moment, initialization path is using test_cpu_cap(&boot_cpu_data), to detect PT, which is just open coding boot_cpu_has(). Use the latter instead. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Acked-by: Borislav Petkov <bp@suse.de> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: eranian@google.com Cc: vince@deater.net Link: http://lkml.kernel.org/r/1459953307-14372-1-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 664b4e24c6145830885e854195376351b0eb3eee Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:30 2016 +0200 locking/rwsem, x86: Provide __down_write_killable() which uses the same fast path as __down_write() except it falls back to call_rwsem_down_write_failed_killable() slow path and return -EINTR if killed. To prevent from code duplication extract the skeleton of __down_write() into a helper macro which just takes the semaphore and the slow path function to be called. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-11-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/rwsem.h | 41 ++++++++++++++++++++++++++++------------- arch/x86/lib/rwsem.S | 8 ++++++++ 2 files changed, 36 insertions(+), 13 deletions(-) commit 4edab14ec66fae5b3c7c4969295facf70365f39d Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:29 2016 +0200 locking/rwsem, s390: Provide __down_write_killable() Introduce ___down_write() for the fast path and reuse it for __down_write() resp. __down_write_killable() each using the respective generic slow path (rwsem_down_write_failed() resp. rwsem_down_write_failed_killable()). Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-10-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/s390/include/asm/rwsem.h | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) commit a02137eb5177e7afc8dfa52a2888c1f2f4840739 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:28 2016 +0200 locking/rwsem, ia64: Provide __down_write_killable() Introduce ___down_write() for the fast path and reuse it for __down_write() resp. __down_write_killable() each using the respective generic slow path (rwsem_down_write_failed() resp. rwsem_down_write_failed_killable()). Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-9-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/ia64/include/asm/rwsem.h | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) commit 7deb5eebc1e61b15c5c7f1ef19f216b20d7f7d00 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:27 2016 +0200 locking/rwsem, alpha: Provide __down_write_killable() Introduce ___down_write() for the fast path and reuse it for __down_write() resp. __down_write_killable() each using the respective generic slow path (rwsem_down_write_failed() resp. rwsem_down_write_failed_killable()). Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-8-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/alpha/include/asm/rwsem.h | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) commit d47996082f52baa0ca8b48d26b3cbef5ede70a73 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:26 2016 +0200 locking/rwsem: Introduce basis for down_write_killable() Introduce a generic implementation necessary for down_write_killable(). This is a trivial extension of the already existing down_write() call which can be interrupted by SIGKILL. This patch doesn't provide down_write_killable() yet because arches have to provide the necessary pieces before. rwsem_down_write_failed() which is a generic slow path for the write lock is extended to take a task state and renamed to __rwsem_down_write_failed_common(). The return value is either a valid semaphore pointer or ERR_PTR(-EINTR). rwsem_down_write_failed_killable() is exported as a new way to wait for the lock and be killable. For rwsem-spinlock implementation the current __down_write() it updated in a similar way as __rwsem_down_write_failed_common() except it doesn't need new exports just visible __down_write_killable(). Architectures which are not using the generic rwsem implementation are supposed to provide their __down_write_killable() implementation and use rwsem_down_write_failed_killable() for the slow path. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-7-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> include/asm-generic/rwsem.h | 12 ++++++++++++ include/linux/rwsem-spinlock.h | 1 + include/linux/rwsem.h | 2 ++ kernel/locking/rwsem-spinlock.c | 22 ++++++++++++++++++++-- kernel/locking/rwsem-xadd.c | 31 +++++++++++++++++++++++++------ 5 files changed, 60 insertions(+), 8 deletions(-) commit 938072e32ce13e5537ef001cdabcb8a6932b09a0 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:25 2016 +0200 locking/rwsem, sparc: Drop superfluous arch specific implementation sparc basically reuses the generic implementation of rwsem so we can reuse the code rather than duplicate it. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-6-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/sparc/include/asm/Kbuild | 1 + arch/sparc/include/asm/rwsem.h | 119 ----------------------------------------- 2 files changed, 1 insertion(+), 119 deletions(-) commit e4a2b01ed3d1591437f93a42f6c4c039b60e0c0a Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:24 2016 +0200 locking/rwsem, sh: Drop superfluous arch specific implementation Since "locking, rwsem: drop explicit memory barriers" the arch specific code is basically same as the the generic one so we can drop the superfluous code. Suggested-by: Davidlohr Bueso <dave@stgolabs.net> Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-5-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/sh/include/asm/Kbuild | 1 + arch/sh/include/asm/rwsem.h | 117 -------------------------------------------- 2 files changed, 1 insertion(+), 117 deletions(-) commit 3aa2591dc2ea292d068dc3a263f1976806c2c281 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:23 2016 +0200 locking/rwsem, xtensa: Drop superfluous arch specific implementation Since "locking, rwsem: drop explicit memory barriers" the arch specific code is basically same as the the generic one so we can drop the superfluous code. Suggested-by: Davidlohr Bueso <dave@stgolabs.net> Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Max Filippov <jcmvbkbc@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-4-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/xtensa/include/asm/Kbuild | 1 + arch/xtensa/include/asm/rwsem.h | 121 ---------------------------------------- 2 files changed, 1 insertion(+), 121 deletions(-) commit 2e927c6422fea5ce36b24b00c2c84f2e9ead31b6 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:22 2016 +0200 locking/rwsem: Drop explicit memory barriers sh and xtensa seem to be the only architectures which use explicit memory barriers for rw_semaphore operations even though they are not really needed because there is the full memory barrier is always implied by atomic_{inc,dec,add,sub}_return() resp. cmpxchg(). Remove them. Signed-off-by: Michal Hocko <mhocko@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-3-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/sh/include/asm/rwsem.h | 14 ++------------ arch/xtensa/include/asm/rwsem.h | 14 ++------------ 2 files changed, 4 insertions(+), 24 deletions(-) commit f8e04d854506ddfeba9cb41b601972b28521f104 Author: Michal Hocko <mhocko@suse.com> Date: Thu Apr 7 17:12:21 2016 +0200 locking/rwsem: Get rid of __down_write_nested() This is no longer used anywhere and all callers (__down_write()) use 0 as a subclass. Ditch __down_write_nested() to make the code easier to follow. This shouldn't introduce any functional change. Signed-off-by: Michal Hocko <mhocko@suse.com> Acked-by: Davidlohr Bueso <dave@stgolabs.net> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Chris Zankel <chris@zankel.net> Cc: David S. Miller <davem@davemloft.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Max Filippov <jcmvbkbc@gmail.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Signed-off-by: Jason Low <jason.low2@hp.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-s390@vger.kernel.org Cc: linux-sh@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org Link: http://lkml.kernel.org/r/1460041951-22347-2-git-send-email-mhocko@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/s390/include/asm/rwsem.h | 7 +------ arch/sh/include/asm/rwsem.h | 5 ----- arch/sparc/include/asm/rwsem.h | 7 +------ arch/x86/include/asm/rwsem.h | 7 +------ include/asm-generic/rwsem.h | 7 +------ include/linux/rwsem-spinlock.h | 1 - kernel/locking/rwsem-spinlock.c | 7 +------ 7 files changed, 5 insertions(+), 36 deletions(-) commit edc73417d8f33a1dd329295275168923298d9a7b Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:24 2016 +0200 6lowpan: move mac802154 header In case of link-layer specific handling for 802.15.4 we need to cast to 802.15.4 sepcific structures. Simple add this header when include the 6lowpan header. Signed-off-by: Alexander Aring <aar@pengutronix.de> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/net/6lowpan.h | 3 +++ net/6lowpan/iphc.c | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) commit 2732363181766533af65e9ced3dc04a30502c5d1 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:23 2016 +0200 6lowpan: add lowpan_is_ll function This patch adds the lowpan_is_ll function, which can be used to make a special 6lowpan linklayer handling for a specific 6lowpan linklayer type. Signed-off-by: Alexander Aring <aar@pengutronix.de> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/6lowpan/6lowpan_i.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit a5862f2aba4ba53d461450685a67ae252935ab94 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:22 2016 +0200 6lowpan: move eui64 uncompress function This function will be use in later functionality in other branches than generic 6lowpan, so we move it to the global 6lowpan header. Signed-off-by: Alexander Aring <aar@pengutronix.de> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/net/6lowpan.h | 16 ++++++++++++++++ net/6lowpan/iphc.c | 16 ---------------- 2 files changed, 16 insertions(+), 16 deletions(-) commit 2bc068c3d6e1212d09c11169c699560747ef8c2b Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:21 2016 +0200 6lowpan: iphc: remove unnecessary zero data This patch removes unnecessary zero data for a stack variable. Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/6lowpan/iphc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7115a968b75e9f81f6f8f45b2f97b1b43e024703 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:20 2016 +0200 6lowpan: iphc: rename add lowpan prefix This patch adds a lowpan prefix to each functions which doesn't have such prefix currently. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/6lowpan/iphc.c | 56 ++++++++++++++++++++++++++++++------------------------ 1 file changed, 31 insertions(+), 25 deletions(-) commit 353c224e28eb73e65720e5b2be224052569c0764 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:19 2016 +0200 6lowpan: move lowpan_802154_dev to 6lowpan This patch moves the 802.15.4 link layer specific structures to generic 6lowpan. This is necessary for special 802.15.4 6lowpan handling in 6lowpan generic layer. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/net/6lowpan.h | 12 ++++++++++++ net/ieee802154/6lowpan/6lowpan_i.h | 12 ------------ 2 files changed, 12 insertions(+), 12 deletions(-) commit 2e4d60cbcfc2d16a2a2efaae3fe08f2e457d59a1 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:18 2016 +0200 6lowpan: change naming for lowpan private data This patch changes the naming for interface private data for lowpan intefaces. The current private data scheme is: ------------------------------------------------- | 6LoWPAN Generic | LinkLayer 6LoWPAN | ------------------------------------------------- the current naming schemes are: - 6LoWPAN Generic: - lowpan_priv - LinkLayer 6LoWPAN: - BTLE - lowpan_dev - 802.15.4: - lowpan_dev_info the new naming scheme with this patch will be: - 6LoWPAN Generic: - lowpan_dev - LinkLayer 6LoWPAN: - BTLE - lowpan_btle_dev - 802.15.4: - lowpan_802154_dev Signed-off-by: Alexander Aring <aar@pengutronix.de> Reviewed-by: Stefan Schmidt<stefan@osg.samsung.com> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/net/6lowpan.h | 6 +-- net/6lowpan/core.c | 8 ++-- net/6lowpan/debugfs.c | 22 +++++----- net/6lowpan/iphc.c | 38 +++++++++--------- net/6lowpan/nhc_udp.c | 2 +- net/bluetooth/6lowpan.c | 82 ++++++++++++++++++++------------------ net/ieee802154/6lowpan/6lowpan_i.h | 6 +-- net/ieee802154/6lowpan/core.c | 6 +-- net/ieee802154/6lowpan/tx.c | 14 +++---- 9 files changed, 94 insertions(+), 90 deletions(-) commit 5a7f97e570fbe0ae7e6fd035f7af0cd6a1a9baa1 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:17 2016 +0200 ieee802154: 6lowpan: fix short addr hash The short address is unique in combination with the panid. This patch will add the panid for generating an ieee802154 address hash. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/ieee802154/6lowpan/6lowpan_i.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9e3b71f3436415f917eb569cde792b223cceebc0 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:16 2016 +0200 nl802154: avoid address change while running lowpan The generation of autoconfigured IPv6 link-local addresses starts with a notification on interface up. To handle autoconfiguration according to RFC 4944 requires pan id and short address to generate an autoconfigured link-local address. This patch will avoid changing of these link-layer address configuration while lowpan interface is up. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/ieee802154/nl802154.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 118a5cf8ae236cdfa1eb4f21530843a8494722ef Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:15 2016 +0200 ieee802154: add short address helpers This patch introduce some short address handling functionality into ieee802154 headers. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/linux/ieee802154.h | 29 +++++++++++++++++++++++++++++ include/net/mac802154.h | 10 ++++++++++ 2 files changed, 39 insertions(+) commit b7594148c73cb506487b5f00a6574beceea0e3a0 Author: Alexander Aring <aar@pengutronix.de> Date: Mon Apr 11 11:04:14 2016 +0200 ieee802154: cleanups for ieee802154.h This patch removes some const from non-pointer types and fixes the function name for the ieee802154_is_valid_extended_unicast_addr comment. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/linux/ieee802154.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 87820441c402f5fde42a84ae96ffb4cbd4109510 Author: Alexandre Macabies <web+oss@zopieux.com> Date: Tue Apr 12 18:53:02 2016 +0200 mrf24j40: apply the security-enabled bit on secured outbound frames We set the TXNSECEN bit of register TXNCON to on when transmitting a security-enabled frame, as described in section 3.12.2 of the MRF datasheet. Signed-off-by: Alexander Aring <aar@pengutronix.de> Signed-off-by: Alexandre Macabies <web+oss@zopieux.com> Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Acked-by: Alan Ott <alan@signal11.us> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/mrf24j40.c | 4 ++++ 1 file changed, 4 insertions(+) commit 5a62f3c6de73bd0b4ac40a33674d20f1bfb586d5 Author: Alexandre Macabies <web+oss@zopieux.com> Date: Tue Apr 12 18:53:01 2016 +0200 mrf24j40: fix security-enabled processing on inbound frames When receiving a security-enabled IEEE 802.15.4 frame, the MRF24J40 triggers a SECIF interrupt that needs to be handled for RX processing to keep functioning properly. This patch enables the SECIF interrupt and makes the MRF ignores all hardware processing of security-enabled frames, that is handled by the ieee802154 stack instead. Signed-off-by: Alexander Aring <aar@pengutronix.de> Signed-off-by: Alexandre Macabies <web+oss@zopieux.com> Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Acked-by: Alan Ott <alan@signal11.us> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/mrf24j40.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit bc405cd69a728d0a82bae8395fe43ec7b0afd1c6 Author: Alexandre Macabies <web+oss@zopieux.com> Date: Tue Apr 12 18:53:00 2016 +0200 ieee802154: add security bit check function ieee802154_is_secen checks if the 802.15.4 security bit is set in the frame control field. Signed-off-by: Alexander Aring <aar@pengutronix.de> Signed-off-by: Alexandre Macabies <web+oss@zopieux.com> Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Acked-by: Alan Ott <alan@signal11.us> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> include/linux/ieee802154.h | 10 ++++++++++ 1 file changed, 10 insertions(+) commit f541bb382fd6b4cd60c9f1fcc2afca1d1d8ab84c Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 11 17:28:33 2016 +0200 i2c: octeon: Move set-clock and init-lowlevel upward No functional change, just moving the functions upward in preparation of improving the recovery. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 126 ++++++++++++++++++++-------------------- 1 file changed, 63 insertions(+), 63 deletions(-) commit 371feaff9980a7060f9fea5c795381aaea5f941d Author: Alim Akhtar <alim.akhtar@samsung.com> Date: Tue Apr 12 18:20:58 2016 +0530 arm64: defconfig: Enable PL330 DMA controller This patch enables PL330 DMA controller found on exynos7 SoCs. Signed-off-by: Alim Akhtar <alim.akhtar@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) commit 482dd2ef124484601adea82e5e806e81e2bc5521 Author: Christoph Hellwig <hch@lst.de> Date: Thu Apr 7 22:43:59 2016 +0200 x86/syscalls: Wire up compat readv2/writev2 syscalls Reported-by: David Smith <dsmith@redhat.com> Tested-by: David Smith <dsmith@redhat.com> Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160407204359.GA3720@lst.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/syscalls/syscall_32.tbl | 4 ++-- arch/x86/entry/syscalls/syscall_64.tbl | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) commit a035d71b1205f880d85752869053b14813366108 Author: Jan Glauber <jglauber@cavium.com> Date: Mon Apr 11 17:28:32 2016 +0200 i2c: octeon: Increase retry default and use fixed timeout value Convert the adapter timeout to 2 ms independently of depending on CONFIG_HZ. CONFIG_HZ is 100 for MIPS Cavium-Octeon so the timeout value is not changed. Also set retries to 5 to improve robustness. Signed-off-by: Jan Glauber <jglauber@cavium.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-octeon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1ed95e52d902035e39a715ff3a314a893a96e5b7 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:16:59 2016 -0700 x86/vdso: Remove direct HPET access through the vDSO Allowing user code to map the HPET is problematic. HPET implementations are notoriously buggy, and there are probably many machines on which even MMIO reads from bogus HPET addresses are problematic. We have a report that the Dell Precision M2800 with: ACPI: HPET 0x00000000C8FE6238 000038 (v01 DELL CBX3 01072009 AMI. 00000005) is either so slow when accessing the HPET or actually hangs in some regard, causing soft lockups to be reported if users do unexpected things to the HPET. The vclock HPET code has also always been a questionable speedup. Accessing an HPET is exceedingly slow (on the order of several microseconds), so the added overhead in requiring a syscall to read the HPET is a small fraction of the total code of accessing it. To avoid future problems, let's just delete the code entirely. In the long run, this could actually be a speedup. Waiman Long as a patch to optimize the case where multiple CPUs contend for the HPET, but that won't help unless all the accesses are mediated by the kernel. Reported-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Borislav Petkov <bp@alien8.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Waiman Long <Waiman.Long@hpe.com> Cc: Waiman Long <waiman.long@hpe.com> Link: http://lkml.kernel.org/r/d2f90bba98db9905041cff294646d290d378f67a.1460074438.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/vdso/vclock_gettime.c | 15 --------------- arch/x86/entry/vdso/vdso-layout.lds.S | 5 ++--- arch/x86/entry/vdso/vma.c | 11 ----------- arch/x86/include/asm/clocksource.h | 9 ++++----- arch/x86/kernel/hpet.c | 1 - arch/x86/kvm/trace.h | 3 +-- 6 files changed, 7 insertions(+), 37 deletions(-) commit fea728c098ee1e6a4a2855962390487ee5d1cdc2 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Apr 12 17:46:42 2016 -0300 mtd: Hook I/O activity to the MTD LED trigger Now that we've added the MTD LED trigger, we need to call each I/O path to ledtrig_mtd_activity. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/mtd/mtdcore.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 4c7e054f08822dc7539d33dbd3e5b9b67297bed5 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Apr 12 17:46:41 2016 -0300 mtd: nand: Remove the "nand-disk" LED trigger This commit removes the "nand-disk" LED trigger from the NAND code. A trigger with the same name is already available selecting LEDS_TRIGGER_MTD. Note that "nand-disk" trigger is being deprecated in favor of the "mtd" trigger. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/mtd/nand/nand_base.c | 29 +---------------------------- 1 file changed, 1 insertion(+), 28 deletions(-) commit 4b721174c7976f26300e39aa42714fb5a54bebb5 Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Apr 12 17:46:40 2016 -0300 leds: trigger: Introduce a MTD (NAND/NOR) trigger This commit introduces a MTD trigger for flash (NAND/NOR) device activity. The implementation is copied from IDE disk. This trigger deprecates the "nand-disk" LED trigger, but for backwards compatibility, we still keep the "nand-disk" trigger around. The motivation for deprecating the "nand-disk" LED trigger is that it only works for NAND drivers, whereas the "mtd" LED trigger is more generic (in fact, "nand-disk" currently only works for certain NAND drivers). Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/trigger/Kconfig | 8 +++++++ drivers/leds/trigger/Makefile | 1 + drivers/leds/trigger/ledtrig-mtd.c | 45 ++++++++++++++++++++++++++++++++++++++ include/linux/leds.h | 6 +++++ 4 files changed, 60 insertions(+) commit 0c034fe37718990e0ffdd9622bd6cc5b4f93111f Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Apr 12 17:46:39 2016 -0300 mtd: Uninline mtd_write_oob and move it to mtdcore.c There's no reason for having mtd_write_oob inlined in mtd.h header. Move it to mtdcore.c where it belongs. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/mtd/mtdcore.c | 12 ++++++++++++ include/linux/mtd/mtd.h | 12 +----------- 2 files changed, 13 insertions(+), 11 deletions(-) commit 42c748bb2544f21c3d115240527fe4478e193641 Author: Borislav Petkov <bp@suse.de> Date: Thu Apr 7 17:31:50 2016 -0700 x86/entry/64: Make gs_change a local label ... so that it doesn't appear in objdump output. Signed-off-by: Borislav Petkov <bp@suse.de> Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/b9c532a0e5f8d56dede2bd59767d40024d5a75e2.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_64.S | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 96e5d28ae7a5250f3deb2434f1895c9daf48b1bd Author: Borislav Petkov <bp@suse.de> Date: Thu Apr 7 17:31:49 2016 -0700 x86/cpu: Add Erratum 88 detection on AMD Erratum 88 affects old AMD K8s, where a SWAPGS fails to cause an input dependency on GS. Therefore, we need to MFENCE before it. But that MFENCE is expensive and unnecessary on the remaining x86 CPUs out there so patch it out on the CPUs which don't require it. Signed-off-by: Borislav Petkov <bp@suse.de> Signed-off-by: Andy Lutomirski <luto@kernel.org Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/aec6b2df1bfc56101d4e9e2e5d5d570bf41663c6.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/entry/entry_64.S | 2 +- arch/x86/include/asm/cpufeatures.h | 2 ++ arch/x86/kernel/cpu/amd.c | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) commit 0230bb038fa99af0c425fc4cffed307e545a9642 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:31:48 2016 -0700 x86/cpu: Move X86_BUG_ESPFIX initialization to generic_identify() It was in detect_nopl(), which was either a mistake by me or some kind of mis-merge. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Fixes: ff236456f072 ("x86/cpu: Move X86_BUG_ESPFIX initialization to generic_identify") Link: http://lkml.kernel.org/r/0949337f13660461edca08ab67d1a841441289c9.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/common.c | 50 ++++++++++++++++++++++---------------------- 1 file changed, 25 insertions(+), 25 deletions(-) commit 3e2b68d752c9e09c40d76442aa94d3b8e421b0f1 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:31:47 2016 -0700 x86/asm, sched/x86: Rewrite the FS and GS context switch code The old code was incomprehensible and was buggy on AMD CPUs. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/5f6bde874c6fe6831c6711b5b1522a238ba035b4.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/process_64.c | 148 +++++++++++++++++++++++++++---------------- 1 file changed, 93 insertions(+), 55 deletions(-) commit 7a5d67048745e3eab62779c6d043a2e3d95dc848 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:31:46 2016 -0700 x86/cpu: Probe the behavior of nulling out a segment at boot time AMD and Intel do different things when writing zero to a segment selector. Since neither vendor documents the behavior well and it's easy to test the behavior, try nulling fs to see what happens. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/61588ba0e0df35beafd363dc8b68a4c5878ef095.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeatures.h | 1 + arch/x86/kernel/cpu/common.c | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) commit d47b50e7a111bb7a56fb1c974728b56209d7f515 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:31:45 2016 -0700 x86/arch_prctl: Fix ARCH_GET_FS and ARCH_GET_GS ARCH_GET_FS and ARCH_GET_GS attempted to figure out the fsbase and gsbase respectively from saved thread state. This was wrong: fsbase and gsbase live in registers while a thread is running, not in memory. For reasons I can't fathom, the fsbase and gsbase code were different. Since neither was correct, I didn't try to figure out what the point of the difference was. Change it to simply read the MSRs. The code for reading the base for a remote thread is also completely wrong if the target thread uses its own descriptors (which is the case for all 32-bit threaded programs), but fixing that is a different story. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/c6e7b507c72ca3bdbf6c7a8a3ceaa0334e873bd9.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/process_64.c | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) commit 0051202f6ad5fd9c04d220343e66d1eb890f7b81 Author: Andy Lutomirski <luto@kernel.org> Date: Thu Apr 7 17:31:44 2016 -0700 selftests/x86: Test the FSBASE/GSBASE API and context switching This catches two distinct bugs in the current code. I'll fix them. Signed-off-by: Andy Lutomirski <luto@kernel.org> Reviewed-by: Borislav Petkov <bp@suse.de> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/7e5941148d1e2199f070dadcdf7355959f5f8e85.1460075211.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> tools/testing/selftests/x86/Makefile | 1 + tools/testing/selftests/x86/fsgsbase.c | 398 +++++++++++++++++++++++++++++++++ 2 files changed, 399 insertions(+) commit c003ed928962a55eb446e78c544b1d7c4f6cb88a Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Fri Apr 8 20:58:46 2016 +0200 locking/lockdep: Deinline register_lock_class(), save 2328 bytes This function compiles to 1328 bytes of machine code. Three callsites. Registering a new lock class is definitely not *that* time-critical to inline it. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Link: http://lkml.kernel.org/r/1460141926-13069-5-git-send-email-dvlasenk@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/lockdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dac429874d8156d97460c61049e202b2dcc15df8 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sat Apr 9 13:17:29 2016 +0200 uprobes/x86: Constify uprobe_xol_ops structures The uprobe_xol_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: kernel-janitors@vger.kernel.org Link: http://lkml.kernel.org/r/1460200649-32526-1-git-send-email-Julia.Lawall@lip6.fr Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/uprobes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit cd97a449a7cedf7d9a61882a672d317429b5d599 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Tue Apr 12 17:57:53 2016 +0200 MAINTAINERS: gpio: add DT bindings directory Helps get_maintainer.pl to find the right people. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit bed9441ba787da1026f95ce6160b38994c510fe3 Merge: aeaae7d 00768a2 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 09:02:07 2016 +0200 Merge tag 'perf-core-for-mingo-20160411' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements from Arnaldo Carvalho de Melo: User visible changes: - Automagically create a 'bpf-output' event, easing the setup of BPF C "scripts" that produce output via the perf ring buffer. Now it is just a matter of calling any perf tool, such as 'trace', with a C source file that references the __bpf_stdout__ output channel and that channel will be created and connected to the script: # trace -e nanosleep --event test_bpf_stdout.c usleep 1 0.013 ( 0.013 ms): usleep/2818 nanosleep(rqtp: 0x7ffcead45f40 ) ... 0.013 ( ): __bpf_stdout__:Raise a BPF event!..) 0.015 ( ): perf_bpf_probe:func_begin:(ffffffff81112460)) 0.261 ( ): __bpf_stdout__:Raise a BPF event!..) 0.262 ( ): perf_bpf_probe:func_end:(ffffffff81112460 <- ffffffff81003d92)) 0.264 ( 0.264 ms): usleep/2818 ... [continued]: nanosleep()) = 0 # Further work is needed to reduce the number of lines in a perf bpf C source file, this being the part where we greatly reduce the command line setup (Wang Nan) - 'perf trace' now supports callchains, with 'trace --call-graph dwarf' using libunwind, just like 'perf top', to ask the kernel for stack dumps for CFI processing. This reduces the overhead by asking just for userspace callchains and also only for the syscall exit tracepoint (raw_syscalls:sys_exit) (Milian Wolff, Arnaldo Carvalho de Melo) Try it with, for instance: # perf trace --call dwarf ping 127.0.0.1 An excerpt of a system wide 'perf trace --call dwarf" session is at: https://fedorapeople.org/~acme/perf/perf-trace--call-graph-dwarf--all-cpus.txt You may need to bump the number of mmap pages, using -m/--mmap-pages, but on a Broadwell machine the defaults allowed system wide tracing to work without losing that many records, experiment with just some syscalls, like: # perf trace --call dwarf -e nanosleep,futex All the targets available for 'perf record', 'perf top' (--pid, --tid, --cpu, etc) should work. Also --duration may be interesting to try. To get filenames from in various syscalls pointer args (open, ettc), add this to the mix: # perf probe 'vfs_getname=getname_flags:72 pathname=filename:string' Making this work is next in line: # trace --call dwarf --ev sched:sched_switch/call-graph=fp/ usleep 1 I.e. honouring per-tracepoint callchains in 'perf trace' in addition to in raw_syscalls:sys_exit. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit aeaae7d612ff2ad647ba422099da56eb3aa89237 Merge: 889fac6 99e87f7 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 08:57:50 2016 +0200 Merge tag 'perf-core-for-mingo-20160408' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Beautify more syscall arguments in 'perf trace', using the type column in tracepoint /format fields to attach, for instance, a pid_t resolver to the thread COMM, also attach a mode_t beautifier in the same fashion (Arnaldo Carvalho de Melo) - Build the syscall table id <-> name resolver using the same .tbl file used in the kernel to generate headers, to avoid the delay in getting new syscalls supported in the audit-libs external dependency, done so far only for x86_64 (Arnaldo Carvalho de Melo) - Improve the documentation of event specifications (Andi Kleen) - Process update events in 'perf script', fixing up this use case: # perf stat -a -I 1000 -e cycles record | perf script -s script.py - Shared object symbol adjustment fixes, fixing symbol resolution in Android (Wang Nan) Infrastructure changes: - Add dedicated unwind addr_space member into thread struct, to allow tools to use thread->priv, noticed while working on having callchains in 'perf trace' (Jiri Olsa) Build fixes: - Fix the build in Ubuntu 12.04 (Arnaldo Carvalho de Melo, Vinson Lee) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 889fac6d67d46a5e781c08fb26fec9016db1c307 Merge: dad38ca bf16200 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 13 08:57:03 2016 +0200 Merge tag 'v4.6-rc3' into perf/core, to refresh the tree Signed-off-by: Ingo Molnar <mingo@kernel.org> commit c1c33b92db4fb274dfbff778ccf2459e4bebd48e Author: Davidlohr Bueso <dave@stgolabs.net> Date: Tue Apr 12 08:47:18 2016 -0700 locking/locktorture: Fix NULL pointer dereference for cleanup paths It has been found that paths that invoke cleanups through lock_torture_cleanup() can trigger NULL pointer dereferencing bugs during the statistics printing phase. This is mainly because we should not be calling into statistics before we are sure things have been set up correctly. Specifically, early checks (and the need for handling this in the cleanup call) only include parameter checks and basic statistics allocation. Once we start write/read kthreads we then consider the test as started. As such, update the function in question to check for cxt.lwsa writer stats, if not set, we either have a bogus parameter or -ENOMEM situation and therefore only need to deal with general torture calls. Reported-and-tested-by: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Davidlohr Bueso <dave@stgolabs.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dhowells@redhat.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476038-27060-2-git-send-email-paulmck@linux.vnet.ibm.com [ Improved the changelog. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/locktorture.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 1f190931893a98ffd5d4cfdfbfc2452ad0ed3e1b Author: Davidlohr Bueso <dave@stgolabs.net> Date: Tue Apr 12 08:47:17 2016 -0700 locking/locktorture: Fix deboosting NULL pointer dereference For the case of rtmutex torturing we will randomly call into the boost() handler, including upon module exiting when the tasks are deboosted before stopping. In such cases the task may or may not have already been boosted, and therefore the NULL being explicitly passed can occur anywhere. Currently we only assume that the task will is at a higher prio, and in consequence, dereference a NULL pointer. This patch fixes the case of a rmmod locktorture exploding while pounding on the rtmutex lock (partial trace): task: ffff88081026cf80 ti: ffff880816120000 task.ti: ffff880816120000 RSP: 0018:ffff880816123eb0 EFLAGS: 00010206 RAX: ffff88081026cf80 RBX: ffff880816bfa630 RCX: 0000000000160d1b RDX: 0000000000000000 RSI: 0000000000000202 RDI: 0000000000000000 RBP: ffff88081026cf80 R08: 000000000000001f R09: ffff88017c20ca80 R10: 0000000000000000 R11: 000000000048c316 R12: ffffffffa05d1840 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 FS: 0000000000000000(0000) GS:ffff88203f880000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000008 CR3: 0000000001c0a000 CR4: 00000000000406e0 Stack: ffffffffa05d141d ffff880816bfa630 ffffffffa05d1922 ffff88081e70c2c0 ffff880816bfa630 ffffffff81095fed 0000000000000000 ffffffff8107bf60 ffff880816bfa630 ffffffff00000000 ffff880800000000 ffff880816123f08 Call Trace: [<ffffffff81095fed>] kthread+0xbd/0xe0 [<ffffffff815cf40f>] ret_from_fork+0x3f/0x70 This patch ensures that if the random state pointer is not NULL and current is not boosted, then do nothing. RIP: 0010:[<ffffffffa05c6185>] [<ffffffffa05c6185>] torture_random+0x5/0x60 [torture] [<ffffffffa05d141d>] torture_rtmutex_boost+0x1d/0x90 [locktorture] [<ffffffffa05d1922>] lock_torture_writer+0xe2/0x170 [locktorture] Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Davidlohr Bueso <dave@stgolabs.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dhowells@redhat.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476038-27060-1-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/locking/locktorture.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 787df6383caa1338a4f6640d71917bc2d8c068b1 Author: Davidlohr Bueso <dave@stgolabs.net> Date: Tue Apr 12 08:52:55 2016 -0700 locking/Documentation: Mention smp_cond_acquire() ... do this next to smp_load_acquire() when first mentioning ACQUIRE. While this call is briefly explained and control dependencies are mentioned later, it does not hurt the reader. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Davidlohr Bueso <dave@stgolabs.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dhowells@redhat.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-7-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 0b6fa347dc08c6f757a35f3a180269b3ffc4cd28 Author: SeongJae Park <sj38.park@gmail.com> Date: Tue Apr 12 08:52:53 2016 -0700 locking/Documentation: Insert white spaces consistently The document uses two newlines between sections, one newline between item and its detailed description, and two spaces between sentences. There are a few places that used these rules inconsistently - fix them. Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: David Howells <dhowells@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-5-git-send-email-paulmck@linux.vnet.ibm.com [ Fixed the changelog. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 43 +++++++++++++++++++++------------------ 1 file changed, 23 insertions(+), 20 deletions(-) commit 3dbf0913f6cac722805a94f16b1e61ffc3483eaf Author: SeongJae Park <sj38.park@gmail.com> Date: Tue Apr 12 08:52:52 2016 -0700 locking/Documentation: Fix formatting inconsistencies Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: David Howells <dhowells@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-4-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 01e1cd6de8e75fa28c268b4dc566bc1a39486e71 Author: SeongJae Park <sj38.park@gmail.com> Date: Tue Apr 12 08:52:51 2016 -0700 locking/Documentation: Add missed subsection in TOC A 'Virtual Machine Guests' subsection was added by this commit: 6a65d26385bf487 ("asm-generic: implement virt_xxx memory barriers") but the TOC was not updated - update it. Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: David Howells <dhowells@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-3-git-send-email-paulmck@linux.vnet.ibm.com [ Rewrote the changelog. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 1 + 1 file changed, 1 insertion(+) commit 166bda7122c8e817f039bf738cf05ab3b7278732 Author: SeongJae Park <sj38.park@gmail.com> Date: Tue Apr 12 08:52:50 2016 -0700 locking/Documentation: Fix missed s/lock/acquire renames The terms 'lock'/'unlock' were changed to 'acquire'/'release' by the following commit: 2e4f5382d12a4 ("locking/doc: Rename LOCK/UNLOCK to ACQUIRE/RELEASE") However, the commit missed to change the table of contents - fix that. Also, the dumb rename changed the section name 'Locking functions' to an actively misleading 'Acquiring functions' section name. Rename it to 'Lock acquisition functions' instead. Suggested-by: David Howells <dhowells@redhat.com> Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: mathieu.desnoyers@efficios.com Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-2-git-send-email-paulmck@linux.vnet.ibm.com [ Rewrote the changelog. ] Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit a5052657c164107032d521f0d9e92703d78845f2 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Apr 12 08:52:49 2016 -0700 locking/Documentation: Clarify relationship of barrier() to control dependencies The current documentation claims that the compiler ignores barrier(), which is not the case. Instead, the compiler carefully pays attention to barrier(), but in a creative way that still manages to destroy the control dependency. This commit sets the story straight. Reported-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bobby.prani@gmail.com Cc: dhowells@redhat.com Cc: dipankar@in.ibm.com Cc: dvhart@linux.intel.com Cc: edumazet@google.com Cc: fweisbec@gmail.com Cc: jiangshanlai@gmail.com Cc: josh@joshtriplett.org Cc: oleg@redhat.com Cc: rostedt@goodmis.org Link: http://lkml.kernel.org/r/1460476375-27803-1-git-send-email-paulmck@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/memory-barriers.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 2c0a303a128cbef54a7b58dc2e413b874d760097 Author: Mark Brown <broonie@kernel.org> Date: Tue Apr 12 08:05:43 2016 +0100 regulator: core: Fix locking of GPIO list on free When we acquire a shareable enable GPIO on probe we do so with the regulator_list_mutex held. However when we release the GPIOs we do this immediately after dropping the mutex meaning that the list could become corrupted. Move the release into the locked region to avoid this. Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 469b640e4f4a28bdd50f0ac1d2b310907afb464c Author: Boris Brezillon <boris.brezillon@free-electrons.com> Date: Tue Apr 12 12:31:00 2016 +0200 regulator: reorder initialization steps in regulator_register() device_register() is calling ->get_voltage() as part of it's sysfs attribute initialization process, and this functions might need to know the regulator constraints to return a valid value. This is at least true for the pwm regulator driver (when operating in continuous mode) which needs to know the minimum and maximum voltage values to calculate the current voltage: min_uV + (((max_uV - min_uV) * dutycycle) / 100); Move device_register() after set_machine_constraints() to make sure those constraints are correctly initialized when ->get_voltage() is called. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reported-by: Stephen Barber <smbarber@chromium.org> Tested-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 896491b304f956d3e87208a242db4fdfa952cdc5 Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Wed Apr 13 01:54:01 2016 +0200 ASoC: au1x: use correct format specifier Documentation/printk-formats.txt has unsigned long: use %lu or %lx size_t: use %zu or %zx runtime->dma_bytes is of type size_t. runtime->min_align is of type unsigned long. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/au1x/dbdma2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e92077c3f45395881ad8c690bb86a85ffe5198ba Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Tue Apr 12 22:51:03 2016 +0200 ASoC: fsl: imx-pcm-fiq: use correct format specifier Documentation/printk-formats.txt has size_t: use %zu or %zx runtime->dma_bytes is of type size_t. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Acked-by: Nicolin Chen <nicoleotsuka@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/fsl/imx-pcm-fiq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 22088b6ac3e5687f766326d4ec8d5c2ea9e903c1 Author: Liu Gang <Gang.Liu@nxp.com> Date: Wed Mar 23 17:47:22 2016 +0800 arm64: dts: ls2080a: Add compatible "fsl,ls2080a-gpio" for ls2080a gpio nodes The compatible "fsl,qoriq-gpio" is used by gpio driver: drivers/gpio/gpio-mpc8xxx.c to implement general gpio functionalities. The chip-specific compatible "fsl,ls2080a-gpio" may be used to fix potential gpio IP block errata or other chip-specific gpio issues. Signed-off-by: Liu Gang <Gang.Liu@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c21de87db05b555a8110c0d8889943c1fe0c6ef1 Author: Liu Gang <Gang.Liu@nxp.com> Date: Wed Mar 23 17:47:21 2016 +0800 arm64: dts: ls1043a: Add compatible "fsl,qoriq-gpio" for ls1043a gpio nodes The compatible "fsl,qoriq-gpio" is used by gpio driver: drivers/gpio/gpio-mpc8xxx.c to implement general gpio functionalities. The chip-specific compatible "fsl,ls1043a-gpio" may be used to fix potential gpio IP block errata or other chip-specific gpio issues. Signed-off-by: Liu Gang <Gang.Liu@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit b30d27f5bba2c65fb571ad7448b18dfee2fd63ae Merge: da0caad 369f045 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 12 22:41:33 2016 -0400 Merge branch 'mediatek-stress-test-fixes' John Crispin says: ==================== net: mediatek: make the driver pass stress tests While testing the driver we managed to get the TX path to stall and fail to recover. When dual MAC support was added to the driver, the whole queue stop/wake code was not properly adapted. There was also a regression in the locking of the xmit function. The fact that watchdog_timeo was not set and that the tx_timeout code failed to properly reset the dma, irq and queue just made the mess complete. This series make the driver pass stress testing. With this series applied the testbed has been running for several days and still has not locked up. We have a second setup that has a small hack patch applied to randomly stop irqs and/or one of the queues and successfully manages to recover from these simulated tx stalls. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 369f04531f80c5e5d194a193a2b9e7676a77328d Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:11 2016 +0200 net: mediatek: do not set the QID field in the TX DMA descriptors The QID field gets set to the mac id. This made the DMA linked list queue the traffic of each MAC on a different internal queue. However during long term testing we found that this will cause traffic stalls as the multi queue setup requires a more complete initialisation which is not part of the upstream driver yet. This patch removes the code setting the QID field, resulting in all traffic ending up in queue 0 which works without any special setup. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 7c78b4ad9bbdbe0bb4fbc98841ad9d904ee116e9 Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:10 2016 +0200 net: mediatek: move the pending_work struct to the device generic struct The worker always touches both netdevs. It is ethernet core and not MAC specific. We only need one worker, which belongs into the ethernets core struct. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 13 +++++-------- drivers/net/ethernet/mediatek/mtk_eth_soc.h | 4 ++-- 2 files changed, 7 insertions(+), 10 deletions(-) commit e7d425dcea032f1d0b44b6fa4c6735f13882de6e Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:09 2016 +0200 net: mediatek: fix mtk_pending_work The driver supports 2 MACs. Both run on the same DMA ring. If we hit a TX timeout we need to stop both netdevs before restarting them again. If we don't do this, mtk_stop() wont shutdown DMA and the consecutive call to mtk_open() wont restart DMA and enable IRQs. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) commit 34c2e4c9e9b3e434a31f67eecf603dc1496c8cc9 Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:08 2016 +0200 net: mediatek: fix TX locking Inside the TX path there is a lock inside the tx_map function. This is however too late. The patch moves the lock to the start of the xmit function right before the free count check of the DMA ring happens. If we do not do this, the code becomes racy leading to TX stalls and dropped packets. This happens as there are 2 netdevs running on the same physical DMA ring. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 13c822f6d468ca5a16da4d9432b067d54245c5b9 Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:07 2016 +0200 net: mediatek: fix stop and wakeup of queue The driver supports 2 MACs. Both run on the same DMA ring. If we go above/below the TX rings threshold value, we always need to wake/stop the queue of both devices. Not doing to can cause TX stalls and packet drops on one of the devices. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 37 +++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 10 deletions(-) commit 13439eec7af24b0800e654ee03c57ab985083ae4 Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:06 2016 +0200 net: mediatek: remove superfluous reset call HW reset is triggered in the mtk_hw_init() function. There is no need to also reset the core during probe. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 4 ---- 1 file changed, 4 deletions(-) commit beeb4ca466fa1c399d69e34c30ddf04e0b7cbefd Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:05 2016 +0200 net: mediatek: mtk_cal_txd_req() returns bad value The code used to also support the PDMA engine, which had 2 packet pointers per descriptor. Because of this we had to divide the result by 2 and round it up. This is no longer needed as the code only supports QDMA. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 82500aa01ad12eff41a9a68ad01f1d40db8921f9 Author: John Crispin <blogic@openwrt.org> Date: Fri Apr 8 00:54:04 2016 +0200 net: mediatek: watchdog_timeo was not set The original commit failed to set watchdog_timeo. This patch sets watchdog_timeo to HZ. Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mediatek/mtk_eth_soc.c | 1 + 1 file changed, 1 insertion(+) commit da0caadf0a05945bf2ef017d43e4eae1e2859b92 Merge: 69fb781 ecdfb48 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 12 22:34:56 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next Pablo Neira Ayuso says: ==================== Netfilter updates for net-next The following patchset contains the first batch of Netfilter updates for your net-next tree. 1) Define pr_fmt() in nf_conntrack, from Weongyo Jeong. 2) Define and register netfilter's afinfo for the bridge family, this comes in preparation for native nfqueue's bridge for nft, from Stephane Bryant. 3) Add new attributes to store layer 2 and VLAN headers to nfqueue, also from Stephane Bryant. 4) Parse new NFQA_VLAN and NFQA_L2HDR nfqueue netlink attributes coming from userspace, from Stephane Bryant. 5) Use net->ipv6.devconf_all->hop_limit instead of hardcoded hop_limit in IPv6 SYNPROXY, from Liping Zhang. 6) Remove unnecessary check for dst == NULL in nf_reject_ipv6, from Haishuang Yan. 7) Deinline ctnetlink event report functions, from Florian Westphal. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit b3f85aba7b87594213e728d13f6c325feea0b66b Author: Yuan Yao <yao.yuan@freescale.com> Date: Wed Mar 9 18:22:06 2016 +0800 arm64: dts: ls2080a: update the DTS for QSPI and DSPI support Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Acked-by: Han xu <han.xu@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls2080a-qds.dts | 9 ++++++++- arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) commit 6f1060e338c2cbaf8df7e5a8609f43dfe497954b Author: Yuan Yao <yao.yuan@freescale.com> Date: Wed Mar 9 18:22:05 2016 +0800 Documentation: fsl: dspi: Add fsl,ls2080a-dspi compatible string new compatible string: "fsl,ls2080a-dspi". Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 730628f00c906cb5a1ba44352bd8095295c74029 Author: Yunhui Cui <B56489@freescale.com> Date: Wed Mar 2 13:52:15 2016 +0800 arm64: dts: ls1043a-rdb: add the DTS for DSPI support This patch adds dts nodes for DSPI on LS1043A-RDB. Signed-off-by: Yunhui Cui <B56489@freescale.com> Signed-off-by: Yuan Yao <yao.yuan@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 7e19793096994d43d213f440f4bbea926828a727 Author: Jens Axboe <axboe@fb.com> Date: Tue Apr 12 16:11:11 2016 -0600 NVMe: silence warning about unused 'dev' Depending on options, we might not be using dev in nvme_cancel_io(): drivers/nvme/host/pci.c: In function ‘nvme_cancel_io’: drivers/nvme/host/pci.c:970:19: warning: unused variable ‘dev’ [-Wunused-variable] struct nvme_dev *dev = data; ^ So get rid of it, and just cast for the dev_dbg_ratelimited() call. Fixes: 82b4552b91c4 ("nvme: Use blk-mq helper for IO termination") Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2245f6de6c68b225986229a2de78c240536f7f38 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:19:30 2016 -0600 block: kill blk_queue_flush() We don't have any drivers left using it, so kill it off. Update documentation to use the newer blk_queue_write_cache(). Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Documentation/block/writeback_cache_control.txt | 4 ++-- block/blk-settings.c | 20 -------------------- include/linux/blkdev.h | 1 - 3 files changed, 2 insertions(+), 23 deletions(-) commit f935a8ce0a60acf0a7fe4da8d2a1e5a70c598e55 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:19:17 2016 -0600 um: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> arch/um/drivers/ubd_kern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fec3ff5d1eef8d81b2922deb4eb5a5e84a93bf4c Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:17:47 2016 -0600 mtd: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/mtd/mtd_blkdevs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e9d5c746246c88a891b0ed21980535909cb39af7 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:17:20 2016 -0600 mmc/block: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/mmc/card/block.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 56883a7ec85f5bc2da7eca67905de54a475daebc Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:16:53 2016 -0600 md: update to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/md/md.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a98239dec6b20cff7b10b670c5d650538f8c3bcb Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:16:25 2016 -0600 ide-disk: update to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/ide/ide-disk.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit bfd230ac4e592f3c03cabdf1e69f170a70aaeef7 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:15:21 2016 -0600 xen-blkfront: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/xen-blkfront.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 519a7e16f9bea99c77fbf549c4b3ef7916199a33 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:14:14 2016 -0600 dm: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/md/dm-table.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 84b4ff9ef22a97231e5d6aeca544a243d0ac5d81 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:13:22 2016 -0600 bcache: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/md/bcache/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ad9126ac723f9e8ed900194d226a0608ffeae45e Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:12:58 2016 -0600 virtio_blk: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/virtio_blk.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 12c95f137d09450b2c2e86fb12da5c7cf585b322 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:12:13 2016 -0600 ps3disk: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/ps3disk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6975f7327f62b7c545aeada57c40ba018d66c93c Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:11:42 2016 -0600 skd_main: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/skd_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 177febc8430e0efa808caca721a59898c5422668 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:11:15 2016 -0600 osdblk: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/osdblk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aafb1eecbb79ac135fa8028f961596333ecbb80b Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:10:53 2016 -0600 nbd: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/nbd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 17fe95f4605c3a2ec3df763876e3abf2eca790a7 Author: Jens Axboe <axboe@fb.com> Date: Tue Apr 12 15:45:39 2016 -0600 mtip32xx: remove call to blk_queue_flush() The driver calls it with 0 for flags, since it doesn't have a writeback cache. Just remove the call, as it's a no-op right now. Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/mtip32xx/mtip32xx.c | 6 ------ 1 file changed, 6 deletions(-) commit 21d0727f639e4ba2bd194b2eb9b38ac840bbbc87 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:09:35 2016 -0600 loop: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/loop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe8fb75e3a1f6f7fac8dc68024eb0062191fe424 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:09:01 2016 -0600 drbd: switch to using blk_queue_write_cache() Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> drivers/block/drbd/drbd_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7c88cb00f2a26637bade6c62a17d17f31a954e30 Author: Jens Axboe <axboe@fb.com> Date: Tue Apr 12 15:43:09 2016 -0600 NVMe: switch to using blk_queue_write_cache() Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit eb310e23dbafa5f4010df37f35999622af2cf795 Author: Jens Axboe <axboe@fb.com> Date: Wed Mar 30 10:06:11 2016 -0600 sd: switch to using blk_queue_write_cache() Switch to the newer interface, instead of using blk_queue_flush() directly. Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Acked-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/sd.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 497fbe24987bd24ee271c67c212ec681995188b6 Author: Shardar Shariff Md <smohammed@nvidia.com> Date: Mon Mar 14 18:52:18 2016 +0530 i2c: tegra: enable multi master mode for tegra210 Enable multi-master mode in I2C_CNFG reg based on hw features. Using single/multi-master mode bit introduced for Tegra210, whereas multi-master mode is enabled by default in HW for T124 and earlier Tegra SOC. Enabling this bit doesn't explicitly start treating the bus has having multiple masters, but will start checking for arbitration lost and reporting when it occurs. The Tegra210 I2C controller supports single/multi master mode. Add chipdata for Tegra210 and its compatibility string so that Tegra210 will select data that enables multi master mode correctly. Do below prerequisites for multi-master bus if "multi-master" dt property entry is added. 1. Enable 1st level clock always set. 2. Disable 2nd level clock gating (slcg which is supported from T124 SOC and later chips) Signed-off-by: Shardar Shariff Md <smohammed@nvidia.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-tegra.c | 74 ++++++++++++++++++++++++++++++++++++++---- 1 file changed, 68 insertions(+), 6 deletions(-) commit 2f9a0b33ac6c4a2accaf787456080af35f1cab0b Merge: e8f1e16 93e9d8e Author: Jens Axboe <axboe@fb.com> Date: Tue Apr 12 15:46:35 2016 -0600 Merge branch 'for-4.7/core' into for-4.7/drivers commit 93e9d8e836cb1a9a58b33eb6643bf061c6119ef2 Author: Jens Axboe <axboe@fb.com> Date: Tue Apr 12 12:32:46 2016 -0600 block: add ability to flag write back caching on a device Add an internal helper and flag for setting whether a queue has write back caching, or write through (or none). Add a sysfs file to show this as well, and make it changeable from user space. This will replace the (awkward) blk_queue_flush() interface that drivers currently use to inform the block layer of write cache state and capabilities. Signed-off-by: Jens Axboe <axboe@fb.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Documentation/block/queue-sysfs.txt | 9 +++++++++ block/blk-settings.c | 26 +++++++++++++++++++++++++ block/blk-sysfs.c | 39 +++++++++++++++++++++++++++++++++++++ include/linux/blkdev.h | 3 +++ 4 files changed, 77 insertions(+) commit 4cb53a2308a96d97854b166780dace58737446ed Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:40 2016 +0300 ARM: dts: omap3-beagle: Provide NAND ready pin On these boards NAND ready pin status is avilable over GPMC_WAIT0 pin. For NAND we don't use GPMC wait pin monitoring but get the NAND Ready/Busy# status using GPIOlib. GPMC driver provides the WAIT0 pin status over GPIOlib. Read speed increases from 13212 KiB/ to 15753 KiB/s and write speed was unchanged at 4404 KiB/s. Measured using mtd_speedtest.ko on omap3-beagle-c4. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-beagle.dts | 1 + 1 file changed, 1 insertion(+) commit 63015d73f345a9196e910b84c3f329a22556bcf4 Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:39 2016 +0300 ARM: dts: am335x: Provide NAND ready pin On these boards NAND ready pin status is avilable over GPMC_WAIT0 pin. For NAND we don't use GPMC wait pin monitoring but get the NAND Ready/Busy# status using GPIOlib. GPMC driver provides the WAIT0 pin status over GPIOlib. Read speed increases from 7869 KiB/ to 8875 KiB/s and write speed was unchanged at 5100 KiB/s. Measured using mtd_speedtest.ko on am335x-evm. Cc: Teresa Remmet <t.remmet@phytec.de> Cc: Ilya Ledvich <ilya@compulab.co.il> Cc: Yegor Yefremov <yegorslists@googlemail.com> Cc: Rostislav Lisovy <lisovy@gmail.com> Cc: Enric Balletbo i Serra <eballetbo@iseebcn.com> Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-baltos-ir5221.dts | 1 + arch/arm/boot/dts/am335x-chilisom.dtsi | 1 + arch/arm/boot/dts/am335x-cm-t335.dts | 1 + arch/arm/boot/dts/am335x-evm.dts | 1 + arch/arm/boot/dts/am335x-igep0033.dtsi | 1 + arch/arm/boot/dts/am335x-phycore-som.dtsi | 1 + 6 files changed, 6 insertions(+) commit 99a4101182d6107af869fb6d41cb375c717c66ad Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:38 2016 +0300 ARM: dts: am437x: Provide NAND ready pin On these boards NAND ready pin status is avilable over GPMC_WAIT0 pin. For NAND we don't use GPMC wait pin monitoring but get the NAND Ready/Busy# status using GPIOlib. GPMC driver provides the WAIT0 pin status over GPIOlib. Read speed increases from 16516 KiB/ to 18813 KiB/s and write speed was unchanged at 9941 KiB/s. Measured using mtd_speedtest.ko. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am437x-gp-evm.dts | 1 + arch/arm/boot/dts/am43x-epos-evm.dts | 1 + 2 files changed, 2 insertions(+) commit a23fc15584871ad5a5b6621768a2b17b645ff22d Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:37 2016 +0300 ARM: dts: dra7x-evm: Provide NAND ready pin On these boards NAND ready pin status is avilable over GPMC_WAIT0 pin. Read speed increases from 13768 KiB/ to 17246 KiB/s. Write speed was unchanged at 7123 KiB/s. Measured using mtd_speedtest.ko. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 1 + arch/arm/boot/dts/dra72-evm.dts | 1 + 2 files changed, 2 insertions(+) commit 8675afe574049ed3f7b0874cd365cc0118a0749a Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:36 2016 +0300 ARM: dts: dm816x: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dm816x.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 0cac398b2b5d4e62b660857e103194bb1cac136c Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:35 2016 +0300 ARM: dts: dm814x: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dm814x.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 94f56c8b82f4c7061f3152617fc8433e6a1b15cb Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:34 2016 +0300 ARM: dts: omap3: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 9e08c2da4234385dd26a567675beaf056b49f4ce Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:33 2016 +0300 ARM: dts: am4372: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am4372.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 4eb4dd570d177e8e17b607241b23a4008bd877e8 Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:32 2016 +0300 ARM: dts: am335x: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am33xx.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit 845b1a260c75285641653aca8d4df0f1c6f3fab4 Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:31 2016 +0300 ARM: dts: dra7: Enable gpio controller for GPMC GPMC driver provides GPI support for the GPMC_WAIT pins. Mark it gpio controller capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 2 ++ 1 file changed, 2 insertions(+) commit e99d413fab9e7d08aa84acfdf1fb456c2a177bc6 Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:30 2016 +0300 ARM: dts: omap5: Enable gpio and interrupt controller for GPMC GPMC driver provides interrupts and gpio for the GPMC_WAIT pins. Mark it as gpio and interrupt capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap5.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit 8c75b766010c6fdca7a213f6b384fdfa02e2636a Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:29 2016 +0300 ARM: dts: omap4: Enable gpio and interrupt controller for GPMC GPMC driver provides interrupts and gpio for the GPMC_WAIT pins. Mark it as gpio and interrupt capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap4.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit ffee5bf3186ef5226d2202c6142c74af74dfa88b Author: Roger Quadros <rogerq@ti.com> Date: Thu Apr 7 13:25:28 2016 +0300 ARM: dts: omap24xx: Enable gpio and interrupt controller for GPMC GPMC driver provides interrupts and gpio for the GPMC_WAIT pins. Mark it as gpio and interrupt capable. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap2420.dtsi | 4 ++++ arch/arm/boot/dts/omap2430.dtsi | 4 ++++ 2 files changed, 8 insertions(+) commit 354fe2e74b3be653f2a0a850a9bce437c5f9bddb Author: Paul Kocialkowski <contact@paulk.fr> Date: Tue Mar 29 21:28:27 2016 +0200 ARM: dts: omap4-kc1: Power off support This adds support for turning off the main power supply via the TWL6030 on the Kindle Fire (first generation). Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap4-kc1.dts | 5 +++++ 1 file changed, 5 insertions(+) commit ab8e2f8c5d15f070a8cba2e0593ede5ef54d25b5 Author: Paul Kocialkowski <contact@paulk.fr> Date: Tue Mar 29 21:28:26 2016 +0200 ARM: dts: omap4-kc1: LEDs support This adds support for the Kindle Fire (first generation) power button LEDs, that are wired to the TWL6030 PWM outputs. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap4-kc1.dts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit abb68f64ce34e7665f88e4c3f0bcd94f3d7a743c Author: Paul Kocialkowski <contact@paulk.fr> Date: Tue Mar 29 21:28:25 2016 +0200 ARM: dts: omap4-kc1: USB OTG support This adds support for USB OTG on the Kindle Fire (first generation). Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap4-kc1.dts | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit f81ad0544749f6c6cfa2fb48b752d5654fe5f5fb Author: Paul Kocialkowski <contact@paulk.fr> Date: Tue Mar 29 21:28:24 2016 +0200 ARM: dts: Amazon Kindle Fire (first generation) codename kc1 basic support The Amazon Kindle Fire (first generation) codename kc1 is a tablet that was released by Amazon back in 2011. It is using an OMAP4430 SoC GP version. This adds devicetree support for the device, with only a few basic features supported, such as debug uart, i2c and internal emmc. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/omap4-kc1.dts | 140 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 141 insertions(+) commit da843ad0f332d42132b64d204bc2b8e03f173107 Author: Paul Kocialkowski <contact@paulk.fr> Date: Tue Mar 29 21:28:23 2016 +0200 devicetree: bindings: Add vendor prefix for Amazon.com, Inc. This adds the amazon vendor prefix for Amazon.com, Inc. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 5e0884a48672616e856ae344fca53174258c6ab7 Author: Yegor Yefremov <yegorslists@googlemail.com> Date: Tue Mar 29 12:08:08 2016 +0200 ARM: dts: am335x-baltos-ir5221: use dedicated RTS/CTS signals Before "tty: Add software emulated RS485 support for 8250" patch Baltos devices relied on MCTRL_GPIO framework to handle both modem signals and RS485 mode. With emulated RS485 support for 8250 we can now use these pins as dedicated RTS/CTS signals taking advantage of hardware flow control etc. when operating in RS232 mode. Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-baltos-ir5221.dts | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit a7cac713f90a7f00601e67d34961c0417783b6db Author: Schuyler Patton <spatton@ti.com> Date: Mon Mar 28 11:35:09 2016 -0500 ARM: dts: AM572x-IDK Initial Support The AM572x-IDK board is a board based on TI's AM5728 SOC which has a dual core 1.5GHz A15 processor. This board is a development platform for the Industrial market with: - 2GB of DDR3L - Dual 1Gbps Ethernet - HDMI, - PRU-ICSS - uSD - 16GB eMMC - CAN - RS-485 - PCIe - USB3.0 - Video Input Port - Industrial IO port and expansion connector The link to the data sheet and TRM can be found here: http://www.ti.com/product/AM5728 This patch creates a common dtsi file that will provide a common board dtsi file to define the nodes that are common to AM57xx (including the upcoming AM5718) IDK boards. Initial support is only for basic peripherals Signed-off-by: Schuyler Patton <spatton@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> .../devicetree/bindings/arm/omap/omap.txt | 3 + arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/am572x-idk.dts | 85 ++++++ arch/arm/boot/dts/am57xx-idk-common.dtsi | 302 +++++++++++++++++++++ 4 files changed, 391 insertions(+) commit 2061d74d38cbc94ebabede7e2ac196afa12ce6c4 Author: Lokesh Vutla <lokeshvutla@ti.com> Date: Wed Mar 23 09:04:13 2016 +0530 ARM: dts: am335x: Add initial support for ICEv2 board TI's Industrial Communication Engine EVM is a low cost hardware mainly developed for industrial communication type applications using serial or Ethernet based interfaces. This platform features TI's AM3359 with 800MHz single core Cortex-A8 processor, 256MB DDR3, 64MB SPI flash, 8MB NOR Flash, mmc, usb, can, dual Ethernet ports. For more information, look at HW user guide[1], Data manual[2]. Just add basic support for the moment. [1] http://processors.wiki.ti.com/index.php/AM335x_Industrial_Communication_Engine_EVM_Rev2_1_HW_User_Guide [2] http://www.ti.com/lit/ds/symlink/am3359.pdf Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Reviewed-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> .../devicetree/bindings/arm/omap/omap.txt | 3 + arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/am335x-icev2.dts | 306 +++++++++++++++++++++ 3 files changed, 310 insertions(+) commit dce2a6524963f58e7fd0b8888b2d3791c150f42c Author: Franklin S Cooper Jr <fcooper@ti.com> Date: Thu Mar 17 20:15:22 2016 -0500 ARM: dts: da850/am4372/am33xx: Use generic node name for ehrpwm When possible generic node names should be used. So change the node name from ehrpwm to pwm. Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am335x-shc.dts | 2 +- arch/arm/boot/dts/am33xx.dtsi | 6 +++--- arch/arm/boot/dts/am4372.dtsi | 12 ++++++------ arch/arm/boot/dts/da850.dtsi | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) commit 3a1de8082405e5c7bd38f4d71605ca85efecf071 Author: Ben Hutchings <ben.hutchings@codethink.co.uk> Date: Wed Mar 16 16:52:30 2016 +0000 ARM: dts: dra7xx: Fix compatible string for PCF8575 chip The binding definition for the PCF857x GPIO expanders doesn't mention a "ti,pcf8575" compatible string. This is apparently because TI is only a second source - there is no functional difference between PCF8575 chips manufactured by TI and NXP, and the same board might be populated with either depending on availability. This is not a problem in practice because the I2C core uses of_modalias_node() before matching drivers and this strips the manufacturer name. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Acked-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 2 +- arch/arm/boot/dts/dra72-evm.dts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 83faf920659386608cc63a7206cd91dba31cd443 Author: Filip Matijević <filip.matijevic.pz@gmail.com> Date: Sun Mar 13 01:06:20 2016 +0100 ARM: dts: N9/N950: Add support for accelerometer Signed-off-by: Filip Matijević <filip.matijevic.pz@gmail.com> Signed-off-by: Sebastian Reichel <sre@kernel.org> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n9.dts | 14 ++++++++++ arch/arm/boot/dts/omap3-n950-n9.dtsi | 54 ++++++++++++++++++++++++++++++++++++ arch/arm/boot/dts/omap3-n950.dts | 14 ++++++++++ 3 files changed, 82 insertions(+) commit 0f4f1542ea0928f4840d308e411797c0dacac239 Author: Filip Matijević <filip.matijevic.pz@gmail.com> Date: Sun Mar 13 01:06:19 2016 +0100 ARM: dts: N9/N950: Add support for 1GHz CPU clock Signed-off-by: Filip Matijević <filip.matijevic.pz@gmail.com> Signed-off-by: Sebastian Reichel <sre@kernel.org> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950-n9.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 8d1ddfce060202cca5a8a7f6c971e41c567edc14 Author: Sebastian Reichel <sre@kernel.org> Date: Sun Mar 13 01:06:18 2016 +0100 ARM: dts: OMAP3-N950: Add Keypad Slide Switch Signed-off-by: Sebastian Reichel <sre@kernel.org> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950.dts | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit d5b0eab7ffaeccc286f791fab252293dc2e8bb90 Author: Sebastian Reichel <sre@kernel.org> Date: Sun Mar 13 01:06:17 2016 +0100 ARM: dts: Enable N950 keyboard sleep leds by default Like the Nokia N900, the N950 has leds to show the state of sys_clkreq and sys_off_mode pins. A detailed description for the LEDs and OMAP's sleep states can be found in Tony's commit for the Nokia N900: c1be2032f66df9e1238bd5bc4ca666de88a62abc Signed-off-by: Sebastian Reichel <sre@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950-n9.dtsi | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit d9546a189cd02b73eb9a8236699ad1a3ca86536b Author: Sebastian Reichel <sre@kernel.org> Date: Sun Mar 13 01:06:16 2016 +0100 ARM: dts: OMAP3-N950: Add Vibrator Signed-off-by: Sebastian Reichel <sre@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950.dts | 7 +++++++ 1 file changed, 7 insertions(+) commit 536b20113f04068386ec247e08a9a1fea994c28b Author: Sebastian Reichel <sre@kernel.org> Date: Sun Mar 13 01:06:15 2016 +0100 ARM: dts: OMAP3-N950: Add Keypad Matrix Add keypad matrix information based on data from Nokia N950 Kernel. Signed-off-by: Sebastian Reichel <sre@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950.dts | 56 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) commit 50413b9d659414d71c0d53d9ac131257326a8528 Author: Sebastian Reichel <sre@kernel.org> Date: Sun Mar 13 01:06:14 2016 +0100 ARM: dts: n9/n950: regulator configuration Add regulator configuration as found in the board files of Nokia's kernel. Signed-off-By: Sebastian Reichel <sre@kernel.org> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3-n950-n9.dtsi | 72 ++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) commit 91d075c7cf2cf621142c0a69f2acc690b81cb8a2 Author: Roger Quadros <rogerq@ti.com> Date: Thu Mar 3 13:28:20 2016 +0200 ARM: dts: dra7-evm: Fix comment about NAND configuration The switch configuration for NAND is actually the other way round. Also mention ON/OFF states as that is more natural to understand (without the help of schematics) when compared to HIGH/LOW. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit a7401ca5596e246f17b087b84fe55a429b666132 Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Thu Mar 10 14:12:22 2016 +0200 i2c: i801: Add runtime PM support with autosuspend Allow runtime PM so that PM and PCI core can put the device into low-power state when idle and resume it back when needed in those platforms that support PM for i801 device. Enable also autosuspend with 1 second delay in order to not needlessly toggle power state on and off if there are multiple transactions during short time. Device is resumed at the beginning of bus access and marked idle ready for autosuspend at the end of it. Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Tested-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-i801.c | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) commit 2ee73c484dc4b8831b745a5feed56382b8741a72 Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Thu Mar 10 14:12:21 2016 +0200 i2c: i801: Convert to struct dev_pm_ops for suspend/resume Stop using legacy PCI PM support and convert to standard dev_pm_ops. This provides more straightforward path to add runtime PM. While at it remove explicit PCI power state control and configuration space save/restore as the PCI core does it. Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Tested-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-i801.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit c4a74f63dfd2e75e7d40a9aaa4052b0ef26e617c Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:20 2016 +0100 debugfs: unproxify files created through debugfs_create_u32_array() The struct file_operations u32_array_fops associated with files created through debugfs_create_u32_array() has been lifetime aware already: everything needed for subsequent operation is copied to a ->f_private buffer at file opening time in u32_array_open(). Now, ->open() is always protected against file removal issues by the debugfs core. There is no need for the debugfs core to wrap the u32_array_fops with a file lifetime managing proxy. Make debugfs_create_u32_array() create its files in non-proxying operation mode by means of debugfs_create_file_unsafe(). Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 83b711cbf4ff42a9996c5f092762b3967d307d73 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:19 2016 +0100 debugfs: unproxify files created through debugfs_create_blob() Currently, the struct file_operations fops_blob associated with files created through the debugfs_create_blob() helpers are not file lifetime aware. Thus, a lifetime managing proxy is created around fops_blob each time such a file is opened which is an unnecessary waste of resources. Implement file lifetime management for the fops_bool file_operations. Namely, make read_file_blob() safe gainst file removals by means of debugfs_use_file_start() and debugfs_use_file_finish(). Make debugfs_create_blob() create its files in non-proxying operation mode by means of debugfs_create_file_unsafe(). Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 4d45f7974ccf0aa783034fef2661573b3a28609e Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:18 2016 +0100 debugfs: unproxify files created through debugfs_create_bool() Currently, the struct file_operations fops_bool associated with files created through the debugfs_create_bool() helpers are not file lifetime aware. Thus, a lifetime managing proxy is created around fops_bool each time such a file is opened which is an unnecessary waste of resources. Implement file lifetime management for the fops_bool file_operations. Namely, make debugfs_read_file_bool() and debugfs_write_file_bool() safe against file removals by means of debugfs_use_file_start() and debugfs_use_file_finish(). Make debugfs_create_bool() create its files in non-proxying operation mode through debugfs_create_mode_unsafe(). Finally, purge debugfs_create_mode() as debugfs_create_bool() had been its last user. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 41 ++++++++++++++++++++--------------------- 1 file changed, 20 insertions(+), 21 deletions(-) commit 4909f168104b24f592fb8d502e2a6520346a3927 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:17 2016 +0100 debugfs: unproxify integer attribute files Currently, the struct file_operations associated with the integer attribute style files created through the debugfs_create_*() helpers are not file lifetime aware as they are defined by means of DEFINE_SIMPLE_ATTRIBUTE(). Thus, a lifetime managing proxy is created around the original fops each time such a file is opened which is an unnecessary waste of resources. Migrate all usages of DEFINE_SIMPLE_ATTRIBUTE() within debugfs itself to DEFINE_DEBUGFS_ATTRIBUTE() in order to implement file lifetime managing within the struct file_operations thus defined. Introduce the debugfs_create_mode_unsafe() helper, analogous to debugfs_create_mode(), but distinct in that it creates the files in non-proxying operation mode through debugfs_create_file_unsafe(). Feed all struct file_operations migrated to DEFINE_DEBUGFS_ATTRIBUTE() into debugfs_create_mode_unsafe() instead of former debugfs_create_mode(). Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 123 +++++++++++++++++++++++++++++++++--------------------- 1 file changed, 75 insertions(+), 48 deletions(-) commit 5103068eaca290f890a30aae70085fac44cecaf6 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:16 2016 +0100 debugfs, coccinelle: check for obsolete DEFINE_SIMPLE_ATTRIBUTE() usage In order to protect against file removal races, debugfs files created via debugfs_create_file() now get wrapped by a struct file_operations at their opening. If the original struct file_operations are known to be safe against removal races by themselves already, the proxy creation may be bypassed by creating the files through debugfs_create_file_unsafe(). In order to help debugfs users who use the common DEFINE_SIMPLE_ATTRIBUTE() + debugfs_create_file() idiom to transition to removal safe struct file_operations, the helper macro DEFINE_DEBUGFS_ATTRIBUTE() has been introduced. Thus, the preferred strategy is to use DEFINE_DEBUGFS_ATTRIBUTE() + debugfs_create_file_unsafe() now. Introduce a Coccinelle script that searches for DEFINE_SIMPLE_ATTRIBUTE()-defined struct file_operations handed into debugfs_create_file(). Suggest to turn these usages into the DEFINE_DEBUGFS_ATTRIBUTE() + debugfs_create_file_unsafe() pattern. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Acked-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../api/debugfs/debugfs_simple_attr.cocci | 67 ++++++++++++++++++++++ 1 file changed, 67 insertions(+) commit c64688081490321f2d23a292ef24e60bb321f3f1 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:15 2016 +0100 debugfs: add support for self-protecting attribute file fops In order to protect them against file removal issues, debugfs_create_file() creates a lifetime managing proxy around each struct file_operations handed in. In cases where this struct file_operations is able to manage file lifetime by itself already, the proxy created by debugfs is a waste of resources. The most common class of struct file_operations given to debugfs are those defined by means of the DEFINE_SIMPLE_ATTRIBUTE() macro. Introduce a DEFINE_DEBUGFS_ATTRIBUTE() macro to allow any struct file_operations of this class to be easily made file lifetime aware and thus, to be operated unproxied. Specifically, introduce debugfs_attr_read() and debugfs_attr_write() which wrap simple_attr_read() and simple_attr_write() under the protection of a debugfs_use_file_start()/debugfs_use_file_finish() pair. Make DEFINE_DEBUGFS_ATTRIBUTE() set the defined struct file_operations' ->read() and ->write() members to these wrappers. Export debugfs_create_file_unsafe() in order to allow debugfs users to create their files in non-proxying operation mode. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 28 ++++++++++++++++++++++++++++ fs/debugfs/inode.c | 28 ++++++++++++++++++++++++++++ include/linux/debugfs.h | 26 ++++++++++++++++++++++++++ 3 files changed, 82 insertions(+) commit 49d200deaa680501f19a247b1fffb29301e51d2b Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:14 2016 +0100 debugfs: prevent access to removed files' private data Upon return of debugfs_remove()/debugfs_remove_recursive(), it might still be attempted to access associated private file data through previously opened struct file objects. If that data has been freed by the caller of debugfs_remove*() in the meanwhile, the reading/writing process would either encounter a fault or, if the memory address in question has been reassigned again, unrelated data structures could get overwritten. However, since debugfs files are seldomly removed, usually from module exit handlers only, the impact is very low. Currently, there are ~1000 call sites of debugfs_create_file() spread throughout the whole tree and touching all of those struct file_operations in order to make them file removal aware by means of checking the result of debugfs_use_file_start() from within their methods is unfeasible. Instead, wrap the struct file_operations by a lifetime managing proxy at file open: - In debugfs_create_file(), the original fops handed in has got stashed away in ->d_fsdata already. - In debugfs_create_file(), install a proxy file_operations factory, debugfs_full_proxy_file_operations, at ->i_fop. This proxy factory has got an ->open() method only. It carries out some lifetime checks and if successful, dynamically allocates and sets up a new struct file_operations proxy at ->f_op. Afterwards, it forwards to the ->open() of the original struct file_operations in ->d_fsdata, if any. The dynamically set up proxy at ->f_op has got a lifetime managing wrapper set for each of the methods defined in the original struct file_operations in ->d_fsdata. Its ->release()er frees the proxy again and forwards to the original ->release(), if any. In order not to mislead the VFS layer, it is strictly necessary to leave those fields blank in the proxy that have been NULL in the original struct file_operations also, i.e. aren't supported. This is why there is a need for dynamically allocated proxies. The choice made not to allocate a proxy instance for every dentry at file creation, but for every struct file object instantiated thereof is justified by the expected usage pattern of debugfs, namely that in general very few files get opened more than once at a time. The wrapper methods set in the struct file_operations implement lifetime managing by means of the SRCU protection facilities already in place for debugfs: They set up a SRCU read side critical section and check whether the dentry is still alive by means of debugfs_use_file_start(). If so, they forward the call to the original struct file_operation stored in ->d_fsdata, still under the protection of the SRCU read side critical section. This SRCU read side critical section prevents any pending debugfs_remove() and friends to return to their callers. Since a file's private data must only be freed after the return of debugfs_remove(), the ongoing proxied call is guarded against any file removal race. If, on the other hand, the initial call to debugfs_use_file_start() detects that the dentry is dead, the wrapper simply returns -EIO and does not forward the call. Note that the ->poll() wrapper is special in that its signature does not allow for the return of arbitrary -EXXX values and thus, POLLHUP is returned here. In order not to pollute debugfs with wrapper definitions that aren't ever needed, I chose not to define a wrapper for every struct file_operations method possible. Instead, a wrapper is defined only for the subset of methods which are actually set by any debugfs users. Currently, these are: ->llseek() ->read() ->write() ->unlocked_ioctl() ->poll() The ->release() wrapper is special in that it does not protect the original ->release() in any way from dead files in order not to leak resources. Thus, any ->release() handed to debugfs must implement file lifetime management manually, if needed. For only 33 out of a total of 434 releasers handed in to debugfs, it could not be verified immediately whether they access data structures that might have been freed upon a debugfs_remove() return in the meanwhile. Export debugfs_use_file_start() and debugfs_use_file_finish() in order to allow any ->release() to manually implement file lifetime management. For a set of common cases of struct file_operations implemented by the debugfs_core itself, future patches will incorporate file lifetime management directly within those in order to allow for their unproxied operation. Rename the original, non-proxying "debugfs_create_file()" to "debugfs_create_file_unsafe()" and keep it for future internal use by debugfs itself. Factor out code common to both into the new __debugfs_create_file(). Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 157 +++++++++++++++++++++++++++++++++++++++++++++++- fs/debugfs/inode.c | 70 ++++++++++++++------- fs/debugfs/internal.h | 6 +- include/linux/debugfs.h | 20 ++++++ 4 files changed, 226 insertions(+), 27 deletions(-) commit 9fd4dcece43a53e5a9e65a973df5693702ee6401 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 14:11:13 2016 +0100 debugfs: prevent access to possibly dead file_operations at file open Nothing prevents a dentry found by path lookup before a return of __debugfs_remove() to actually get opened after that return. Now, after the return of __debugfs_remove(), there are no guarantees whatsoever regarding the memory the corresponding inode's file_operations object had been kept in. Since __debugfs_remove() is seldomly invoked, usually from module exit handlers only, the race is hard to trigger and the impact is very low. A discussion of the problem outlined above as well as a suggested solution can be found in the (sub-)thread rooted at http://lkml.kernel.org/g/20130401203445.GA20862@ZenIV.linux.org.uk ("Yet another pipe related oops.") Basically, Greg KH suggests to introduce an intermediate fops and Al Viro points out that a pointer to the original ones may be stored in ->d_fsdata. Follow this line of reasoning: - Add SRCU as a reverse dependency of DEBUG_FS. - Introduce a srcu_struct object for the debugfs subsystem. - In debugfs_create_file(), store a pointer to the original file_operations object in ->d_fsdata. - Make debugfs_remove() and debugfs_remove_recursive() wait for a SRCU grace period after the dentry has been delete()'d and before they return to their callers. - Introduce an intermediate file_operations object named "debugfs_open_proxy_file_operations". It's ->open() functions checks, under the protection of a SRCU read lock, whether the dentry is still alive, i.e. has not been d_delete()'d and if so, tries to acquire a reference on the owning module. On success, it sets the file object's ->f_op to the original file_operations and forwards the ongoing open() call to the original ->open(). - For clarity, rename the former debugfs_file_operations to debugfs_noop_file_operations -- they are in no way canonical. The choice of SRCU over "normal" RCU is justified by the fact, that the former may also be used to protect ->i_private data from going away during the execution of a file's readers and writers which may (and do) sleep. Finally, introduce the fs/debugfs/internal.h header containing some declarations internal to the debugfs implementation. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/file.c | 91 ++++++++++++++++++++++++++++++++++++++++++++++++- fs/debugfs/inode.c | 13 ++++++- fs/debugfs/internal.h | 24 +++++++++++++ include/linux/debugfs.h | 3 -- lib/Kconfig.debug | 1 + 5 files changed, 127 insertions(+), 5 deletions(-) commit e8f1e1630b0a98685d1a3521e8aba0dc7e68082c Author: Sagi Grimberg <sagig@mellanox.com> Date: Thu Mar 10 13:58:49 2016 +0200 blk-mq: Make blk_mq_all_tag_busy_iter static No caller outside the blk-mq code so we can settle with it static. Signed-off-by: Sagi Grimberg <sagig@mellanox.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq-tag.c | 5 ++--- include/linux/blk-mq.h | 2 -- 2 files changed, 2 insertions(+), 5 deletions(-) commit 6d125de40bbc5b29fd8e6dce74e1a661a085dab1 Author: Keith Busch <keith.busch@intel.com> Date: Thu Mar 10 13:58:48 2016 +0200 mtip32xx: Convert to use blk_mq_tagset_busy_iter Only a single tags array anyway. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Sagi Grimberg <sagig@mellanox.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/block/mtip32xx/mtip32xx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 04f59143b571161d25315dd52d7a2ecc022cb71a Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 12 09:57:35 2016 +0200 i2c: let I2C masters ignore their children for PM When using a certain I2C device with runtime PM enabled on a certain I2C bus adaper the following happens: struct amba_device *foo \ struct i2c_adapter *bar \ struct i2c_client *baz The AMBA device foo has its device PM struct set to ignore children with pm_suspend_ignore_children(&foo->dev, true). This makes runtime PM work just fine locally in the driver: the fact that devices on the bus are suspended or resumed individually does not affect its operation, and the hardware does not power up unless transferring messages. However this child ignorance property is not inherited into the struct i2c_adapter *bar. On system suspend things will work fine. On system resume the following annoying phenomenon occurs: - In the pm_runtime_force_resume() path of struct i2c_client *baz, pm_runtime_set_active(&baz->dev); is eventually called. - This becomes __pm_runtime_set_status(&baz->dev, RPM_ACTIVE); - __pm_runtime_set_status() detects that RPM state is changed, and checks whether the parent is: not active (RPM_ACTIVE) and not ignoring its children If this happens it concludes something is wrong, because a parent that is not ignoring its children must be active before any children activate. - Since the struct i2c_adapter *bar does not ignore its children, the PM core thinks that it must indeed go online before its children, the check bails out with -EBUSY, i.e. the i2c_client *baz thinks it can't work because it's parent is not online, and it respects its parent. - In the driver the .resume() callback returns -EBUSY from the runtime_force_resume() call as per above. This leaves the device in a suspended state, leading to bad behaviour later when the device is used. The following debug print is made with an extra printg patch but illustrates the problem: [ 17.040832] bh1780 2-0029: parent (i2c-2) is not active parent->power.ignore_children = 0 [ 17.040832] bh1780 2-0029: pm_runtime_force_resume: pm_runtime_set_active() failed (-16) [ 17.040863] dpm_run_callback(): pm_runtime_force_resume+0x0/0x88 returns -16 [ 17.040863] PM: Device 2-0029 failed to resume: error -16 Fix this by letting all struct i2c_adapter:s ignore their children: i2c children have no business doing keeping their parents awake: they are completely autonomous devices that just use their parent to talk, a usecase which must be power managed in the host on a per-message basis. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-core.c | 1 + 1 file changed, 1 insertion(+) commit 82b4552b91c40626a90a20291aab1137c638b512 Author: Sagi Grimberg <sagig@mellanox.com> Date: Tue Apr 12 15:07:15 2016 -0600 nvme: Use blk-mq helper for IO termination blk-mq offers a tagset iterator so let's use that instead of using nvme_clear_queues. Note, we changed nvme_queue_cancel_ios name to nvme_cancel_io as there is no concept of a queue now in this function (we also lost the print). Signed-off-by: Sagi Grimberg <sagig@mellanox.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Acked-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) commit ecdfb48cddfd1096343148113d5b1bd789033aa8 Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 11 21:52:36 2016 +0200 netfilter: conntrack: move expectation event helper to ecache.c Not performance critical, it is only invoked when an expectation is added/destroyed. While at it, kill unused nf_ct_expect_event() wrapper. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_ecache.h | 42 +++-------------------------- net/netfilter/nf_conntrack_ecache.c | 30 +++++++++++++++++++++ 2 files changed, 33 insertions(+), 39 deletions(-) commit 3c435e2e414e82ec6c0e96a1dfc2be3ddc3c23b4 Author: Florian Westphal <fw@strlen.de> Date: Mon Apr 11 21:52:35 2016 +0200 netfilter: conntrack: de-inline nf_conntrack_eventmask_report Way too large; move it to nf_conntrack_ecache.c. Reduces total object size by 1216 byte on my machine. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/net/netfilter/nf_conntrack_ecache.h | 66 ++++++----------------------- net/netfilter/nf_conntrack_ecache.c | 54 +++++++++++++++++++++++ 2 files changed, 66 insertions(+), 54 deletions(-) commit 8695add6c3ac272677cd6e4414a4b3ed26f8a1f7 Author: Nishanth Menon <nm@ti.com> Date: Thu Mar 3 08:49:48 2016 +0530 ARM: dts: dra7-evm: Add missing regulators Few regulators information were missing from DT. Add those missing regulators. Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) commit 21f033f7c72e9505c46c6555b019b907dc39dfcd Author: Keith Busch <keith.busch@intel.com> Date: Tue Apr 12 11:13:11 2016 -0600 NVMe: Skip async events for degraded controllers If the controller is degraded, the driver should stay out of the way so the user can recover the drive. This patch skips driver initiated async event requests when the drive is in this state. Signed-off-by: Keith Busch <keith.busch@intel.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) commit 8093f7ca73c1633e458c16a74b51bcc3c94564c4 Author: Ming Lin <mlin@kernel.org> Date: Tue Apr 12 13:10:14 2016 -0600 nvme: add helper nvme_setup_cmd() This moves nvme_setup_{flush,discard,rw} calls into a common nvme_setup_cmd() helper. So we can eventually hide all the command setup in the core module and don't even need to update the fabrics drivers for any specific command type. Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/core.c | 105 +++++++++++++++++++++++++++++++++++++++++++++++ drivers/nvme/host/nvme.h | 53 +----------------------- drivers/nvme/host/pci.c | 47 +-------------------- 3 files changed, 108 insertions(+), 97 deletions(-) commit 03b5929ebb20457e2fd13a701954efa2b2fb7ded Author: Ming Lin <ming.l@ssi.samsung.com> Date: Tue Mar 22 00:24:45 2016 -0700 nvme: rewrite discard support This rewrites nvme_setup_discard() with blk_add_request_payload(). It allocates only the necessary amount(16 bytes) for the payload. Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 68 ++++++++++++++++++++++++++++--------------------- 1 file changed, 39 insertions(+), 29 deletions(-) commit 58b45602751ddf16e57170656670aa5a8f78eeca Author: Ming Lin <ming.l@ssi.samsung.com> Date: Tue Mar 22 00:24:43 2016 -0700 nvme: add helper nvme_map_len() The helper returns the number of bytes that need to be mapped using PRPs/SGL entries. Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/nvme.h | 8 ++++++++ drivers/nvme/host/pci.c | 13 +++++-------- 2 files changed, 13 insertions(+), 8 deletions(-) commit 2e39e0f608c130411f52c9fe5648dbcda5e28528 Author: Ming Lin <ming.l@ssi.samsung.com> Date: Tue Apr 5 10:32:04 2016 -0700 nvme: add missing lock nesting notation When unloading driver, nvme_disable_io_queues() calls nvme_delete_queue() that sends nvme_admin_delete_cq command to admin sq. So when the command completed, the lock acquired by nvme_irq() actually belongs to admin queue. While the lock that nvme_del_cq_end() trying to acquire belongs to io queue. So it will not deadlock. This patch adds lock nesting notation to fix following report. [ 109.840952] ============================================= [ 109.846379] [ INFO: possible recursive locking detected ] [ 109.851806] 4.5.0+ #180 Tainted: G E [ 109.856533] --------------------------------------------- [ 109.861958] swapper/0/0 is trying to acquire lock: [ 109.866771] (&(&nvmeq->q_lock)->rlock){-.....}, at: [<ffffffffc0820bc6>] nvme_del_cq_end+0x26/0x70 [nvme] [ 109.876535] [ 109.876535] but task is already holding lock: [ 109.882398] (&(&nvmeq->q_lock)->rlock){-.....}, at: [<ffffffffc0820c2b>] nvme_irq+0x1b/0x50 [nvme] [ 109.891547] [ 109.891547] other info that might help us debug this: [ 109.898107] Possible unsafe locking scenario: [ 109.898107] [ 109.904056] CPU0 [ 109.906515] ---- [ 109.908974] lock(&(&nvmeq->q_lock)->rlock); [ 109.913381] lock(&(&nvmeq->q_lock)->rlock); [ 109.917787] [ 109.917787] *** DEADLOCK *** [ 109.917787] [ 109.923738] May be due to missing lock nesting notation [ 109.923738] [ 109.930558] 1 lock held by swapper/0/0: [ 109.934413] #0: (&(&nvmeq->q_lock)->rlock){-.....}, at: [<ffffffffc0820c2b>] nvme_irq+0x1b/0x50 [nvme] [ 109.944010] [ 109.944010] stack backtrace: [ 109.948389] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G E 4.5.0+ #180 [ 109.955734] Hardware name: Dell Inc. OptiPlex 7010/0YXT71, BIOS A15 08/12/2013 [ 109.962989] 0000000000000000 ffff88011e203c38 ffffffff81383d9c ffffffff81c13540 [ 109.970478] ffffffff826711d0 ffff88011e203ce8 ffffffff810bb429 0000000000000046 [ 109.977964] 0000000000000046 0000000000000000 0000000000b2e597 ffffffff81f4cb00 [ 109.985453] Call Trace: [ 109.987911] <IRQ> [<ffffffff81383d9c>] dump_stack+0x85/0xc9 [ 109.993711] [<ffffffff810bb429>] __lock_acquire+0x19b9/0x1c60 [ 109.999575] [<ffffffff810b6d1d>] ? trace_hardirqs_off+0xd/0x10 [ 110.005524] [<ffffffff810b386d>] ? complete+0x3d/0x50 [ 110.010688] [<ffffffff810bb760>] lock_acquire+0x90/0xf0 [ 110.016029] [<ffffffffc0820bc6>] ? nvme_del_cq_end+0x26/0x70 [nvme] [ 110.022418] [<ffffffff81772afb>] _raw_spin_lock_irqsave+0x4b/0x60 [ 110.028632] [<ffffffffc0820bc6>] ? nvme_del_cq_end+0x26/0x70 [nvme] [ 110.035019] [<ffffffffc0820bc6>] nvme_del_cq_end+0x26/0x70 [nvme] [ 110.041232] [<ffffffff8135b485>] blk_mq_end_request+0x35/0x60 [ 110.047095] [<ffffffffc0821ad8>] nvme_complete_rq+0x68/0x190 [nvme] [ 110.053481] [<ffffffff8135b53f>] __blk_mq_complete_request+0x8f/0x130 [ 110.060043] [<ffffffff8135b611>] blk_mq_complete_request+0x31/0x40 [ 110.066343] [<ffffffffc08209e3>] __nvme_process_cq+0x83/0x240 [nvme] [ 110.072818] [<ffffffffc0820c35>] nvme_irq+0x25/0x50 [nvme] [ 110.078419] [<ffffffff810cdb66>] handle_irq_event_percpu+0x36/0x110 [ 110.084804] [<ffffffff810cdc77>] handle_irq_event+0x37/0x60 [ 110.090491] [<ffffffff810d0ea3>] handle_edge_irq+0x93/0x150 [ 110.096180] [<ffffffff81012306>] handle_irq+0xa6/0x130 [ 110.101431] [<ffffffff81011abe>] do_IRQ+0x5e/0x120 [ 110.106333] [<ffffffff8177384c>] common_interrupt+0x8c/0x8c Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 788e15abbb9408c9399d7e3445ac9afb3b2fd7d6 Author: Keith Busch <keith.busch@intel.com> Date: Fri Apr 8 16:09:10 2016 -0600 NVMe: Always use MSI/MSI-x interrupts Multiple users have reported device initialization failure due the driver not receiving legacy PCI interrupts. This is not unique to any particular controller, but has been observed on multiple platforms. There have been no issues reported or observed when with message signaled interrupts, so this patch attempts to use MSI-x during initialization, falling back to MSI. If that fails, legacy would become the default. The setup_io_queues error handling had to change as a result: the admin queue's msix_entry used to be initialized to the legacy IRQ. The case where nr_io_queues is 0 would fail request_irq when setting up the admin queue's interrupt since re-enabling MSI-x fails with 0 vectors, leaving the admin queue's msix_entry invalid. Instead, return success immediately. Reported-by: Tim Muhlemmer <muhlemmer@gmail.com> Reported-by: Jon Derrick <jonathan.derrick@intel.com> Signed-off-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com> drivers/nvme/host/pci.c | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) commit e0489487ec9cd79ee1fa0dc5d3789c08b0e51a2c Author: Sagi Grimberg <sagig@mellanox.com> Date: Thu Mar 10 13:58:46 2016 +0200 blk-mq: Export tagset iter function Its useful to iterate on all the active tags in cases where we will need to fail all the queues IO. Signed-off-by: Sagi Grimberg <sagig@mellanox.com> [hch: carefully check for valid tagsets] Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-mq-tag.c | 12 ++++++++++++ include/linux/blk-mq.h | 2 ++ 2 files changed, 14 insertions(+) commit 37e58237a16b94fcd2c2d1b7e9c6e1ca661c231b Author: Ming Lin <ming.l@ssi.samsung.com> Date: Tue Mar 22 00:24:44 2016 -0700 block: add offset in blk_add_request_payload() We could kmalloc() the payload, so need the offset in page. Signed-off-by: Ming Lin <ming.l@ssi.samsung.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com> block/blk-core.c | 5 +++-- drivers/block/skd_main.c | 2 +- drivers/scsi/sd.c | 2 +- include/linux/blkdev.h | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) commit b6e17c1be75c796b37d01d058ae17387f043e495 Merge: 6e007f3 ad3043f Author: David Howells <dhowells@redhat.com> Date: Tue Apr 12 20:10:19 2016 +0100 Merge branch 'keys-sig' into keys-next These commits do the following: (1) Retain a signature in an asymmetric-type key and associate with it the identifiers that will match a key that can be used to verify it. (2) Differentiate an X.509 cert that cannot be used versus one that cannot be verified due to unavailable crypto. This is noted in the structures involved. (3) Determination of the self-signedness of an X.509 cert is improved to include checks on the subject/issuer names and the key algorithm/signature algorithm types. (4) Self-signed X.509 certificates are consistency checked early on if the appropriate crypto is available. Signed-off-by: David Howells <dhowells@redhat.com> commit 6e007f3186e398ec4e3b6d4f1c22740d9dc2715e Merge: 3c9d629 ddbb411 Author: David Howells <dhowells@redhat.com> Date: Tue Apr 12 20:09:34 2016 +0100 Merge branch 'keys-misc' into keys-next Miscellaneous keyrings changes. Signed-off-by: David Howells <dhowells@redhat.com> commit ddbb41148724367394d0880c516bfaeed127b52e Author: Mat Martineau <mathew.j.martineau@linux.intel.com> Date: Tue Apr 12 19:54:58 2016 +0100 KEYS: Add KEYCTL_DH_COMPUTE command This adds userspace access to Diffie-Hellman computations through a new keyctl() syscall command to calculate shared secrets or public keys using input parameters stored in the keyring. Input key ids are provided in a struct due to the current 5-arg limit for the keyctl syscall. Only user keys are supported in order to avoid exposing the content of logon or encrypted keys. The output is written to the provided buffer, based on the assumption that the values are only needed in userspace. Future support for other types of key derivation would involve a new command, like KEYCTL_ECDH_COMPUTE. Once Diffie-Hellman support is included in the crypto API, this code can be converted to use the crypto API to take advantage of possible hardware acceleration and reduce redundant code. Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: David Howells <dhowells@redhat.com> Documentation/security/keys.txt | 30 ++++++++ include/uapi/linux/keyctl.h | 10 +++ security/keys/Kconfig | 11 +++ security/keys/Makefile | 1 + security/keys/compat.c | 4 + security/keys/dh.c | 160 ++++++++++++++++++++++++++++++++++++++++ security/keys/internal.h | 12 +++ security/keys/keyctl.c | 5 ++ 8 files changed, 233 insertions(+) commit 13100a72f40f5748a04017e0ab3df4cf27c809ef Author: Kirill Marinushkin <k.marinushkin@gmail.com> Date: Tue Apr 12 19:54:58 2016 +0100 Security: Keys: Big keys stored encrypted Solved TODO task: big keys saved to shmem file are now stored encrypted. The encryption key is randomly generated and saved to payload[big_key_data]. Signed-off-by: Kirill Marinushkin <k.marinushkin@gmail.com> Signed-off-by: David Howells <dhowells@redhat.com> security/keys/Kconfig | 4 + security/keys/big_key.c | 198 +++++++++++++++++++++++++++++++++++++++++++----- 2 files changed, 184 insertions(+), 18 deletions(-) commit 898de7d0f298e53568891f0ec3547b14fe8bb5d5 Author: David Howells <dhowells@redhat.com> Date: Tue Apr 12 19:54:58 2016 +0100 KEYS: user_update should use copy of payload made during preparsing The payload preparsing routine for user keys makes a copy of the payload provided by the caller and stashes it in the key_preparsed_payload struct for ->instantiate() or ->update() to use. However, ->update() takes another copy of this to attach to the keyring. ->update() should be using this directly and clearing the pointer in the preparse data. Signed-off-by: David Howells <dhowells@redhat.com> security/keys/user_defined.c | 42 +++++++++++------------------------------- 1 file changed, 11 insertions(+), 31 deletions(-) commit 93da17b18539cb021f1075f8620ee8f6da9b42aa Author: Andreas Ziegler <andreas.ziegler@fau.de> Date: Tue Apr 12 19:54:58 2016 +0100 security: integrity: Remove select to deleted option PUBLIC_KEY_ALGO_RSA Commit d43de6c780a8 ("akcipher: Move the RSA DER encoding check to the crypto layer") removed the Kconfig option PUBLIC_KEY_ALGO_RSA, but forgot to remove a 'select' to this option in the definition of INTEGRITY_ASYMMETRIC_KEYS. Let's remove the select, as it's ineffective now. Signed-off-by: Andreas Ziegler <andreas.ziegler@fau.de> Signed-off-by: David Howells <dhowells@redhat.com> security/integrity/Kconfig | 1 - 1 file changed, 1 deletion(-) commit cfe9011a05a8de56f97d15a24977639fe6534e9c Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Thu Apr 7 12:10:58 2016 +0530 ath10k: remove MSI range support MSI-X is never well-tested, might contain bugs and generally isn't really all that useful to maintain. Also ath10k is mainly used with shared/singly-MSI interrupt systems. Hence removing MSI range support. This change will be useful for further cleanup in copy engine lock and to add NAPI support. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/pci.c | 164 ++++------------------------------ drivers/net/wireless/ath/ath10k/pci.h | 17 ++-- 2 files changed, 24 insertions(+), 157 deletions(-) commit a606c0ee9d5c12eb1a0e86837db622969956b825 Author: Peter Oh <poh@qca.qualcomm.com> Date: Mon Apr 4 16:19:16 2016 -0700 ath10k: enable set_tsf vdev command to WMI 10.4 10.4 firmware has addeded set_tsf vdev parameter, hence enable it. set_tsf function can be used to shift TBTT that will help avoid its clockdrift which happens when beacons are collided. Signed-off-by: Peter Oh <poh@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4857dd14ec3720d25c33ea0186c55b849d891b0f Author: Peter Oh <poh@qca.qualcomm.com> Date: Mon Apr 4 16:19:15 2016 -0700 ath10k: update 10.4 WMI vdev parameters Update 10.4 WMI vdev param to sync to current 10.4 firmware as of 2/23/2016. Signed-off-by: Peter Oh <poh@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 9f0b7e7dea7c3cedba315d44816070fcc692c748 Author: Peter Oh <poh@qca.qualcomm.com> Date: Mon Apr 4 16:19:14 2016 -0700 ath10k: add a support of set_tsf on vdev interface 10.2.4.70.24 firmware introduces new feature to set TSF via vdev parameter, hence implement relevant function. set_tsf function can be used to shift TBTT that will help avoid its clockdrift which happens when beacons are collided. Signed-off-by: Peter Oh <poh@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 27 +++++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi-tlv.c | 1 + drivers/net/wireless/ath/ath10k/wmi.c | 4 ++++ drivers/net/wireless/ath/ath10k/wmi.h | 2 ++ 4 files changed, 34 insertions(+) commit 169ff6db3a81fad3011e4c0b0114dbe9de1cd517 Author: Ben Greear <greearb@candelatech.com> Date: Fri Feb 5 15:10:02 2016 -0800 ath10k: Document alloc_frag_desc_for_data_pkt config option. This will help anyone trying to use the ack-rssi reporting feature with the host-specified TX-rate option in 10.4 firmware. Signed-off-by: Ben Greear <greearb@candelatech.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit b521973b45efe496ef7482a1ef98a2986c57839e Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:40:01 2016 +0200 drm/i915: Don't read out port_clock on CHV when DPLL is disabled Check whether the DPLL is even enabled before readoing out the dividers and trying to derive port_clock on CHV. We already did this on VLV. Also remove the comment "MIPI" comment from the VLV code since we call this function whenever the pipe is enabled. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-9-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 7f7d8dd62cb8d7697c58a5b0266b11446d97e12d Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:40:07 2016 +0200 drm/i915: Dump pfit PGM_RATIOS as hex pgm_ratios in stored as a register value in pipe config, so let's dump this one as hex as well. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-15-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ae9ec62bdadc4cd3bf893d6baced80aa3a5dbbd6 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:40:05 2016 +0200 drm/i915: Fix CHV DSI PLL refclk during state readout Use the proper refclock frequency (100MHz) when reading out the current DSI clock on CHV. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-13-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi_pll.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f00b56896ec2443a33277f5411de0cbd13071cec Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:40:03 2016 +0200 drm/i915: Power down the DSI PLL before reconfiguring it On VLV at least, the BIOS may leave the DSI PLL enabled in some wonky state where it just refuses to lock. Simply disabling the PLL before reconfiguring it is not enough to fix it, but power gating the PLL prior to reconfiguring does work. This happens on BYT FFRD8 when booting with HDMI connected so the DSI display will not be lit up by the BIOS. Also we can remove the code for BXT that disables the PLL before enabling it again. v2: s/vlv/intel/ since BXT made thing generic v3: Remove the BXT disable PLL before enable trick Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-11-git-send-email-ville.syrjala@linux.intel.com Acked-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi.c | 6 ++++++ drivers/gpu/drm/i915/intel_dsi_pll.c | 8 -------- 2 files changed, 6 insertions(+), 8 deletions(-) commit 50dd63a27bb0506a63137f38d72dead7dc1db584 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:40:02 2016 +0200 drm/i915: Change lfsr_converts[] to u16 All the values in the DSI PLL LFSR seed table fit into 9bits, so change the type to u16 from u32 to save a bit of space. drivers/gpu/drm/i915/i915.ko: -.rodata 90824 +.rodata 90760 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-10-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_dsi_pll.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a527b38e1475211b67eb59b3fadb40689f035529 Author: Denys Vlasenko <dvlasenk@redhat.com> Date: Tue Apr 12 12:39:12 2016 -0400 GFS2: fs/gfs2/glock.c: Deinline do_error, save 1856 bytes This function compiles to 522 bytes of machine code. Error paths are not very time critical. Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/glock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 522bad5b5e8dc27a245d4b4cd546689b06dc3024 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:32 2016 +0300 Revert "drm/i915: Limit the auto arming of mmio debugs on vlv/chv" Enable the unclaimd register detection stuff on vlv/chv since we've now fixed the known problems during suspend. This reverts commit c81eeea6c14b212016104f4256c65f93ad230a86. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-11-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_uncore.c | 9 --------- 1 file changed, 9 deletions(-) commit 71b8b41d5b3573ba4e669822d5736226e9bbfa5d Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:31 2016 +0300 drm/i915: Move DPINVGTT setup to vlv_display_irq_reset() DPINVGTT lives inside the disp2d power well so we can't frob it unless we know the power well is active. Let's this stuff into vlv_display_irq_reset() which is only called at the right times so that we don't get unclaimed register access errors. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94164 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-10-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 766078df43db7227e6904bb51de636a4abedb01b Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:30 2016 +0300 drm/i915: Move vlv_init_display_clock_gating() to the display power well The registers frobbed by vlv_init_display_clock_gating() libve inside the disp2d power well, so frobbing them while the power well is down results in unclaimed register access warning (and of course the values won't stick). Let's do this setup after we know the power well is enabled. It's also worth noting that DSPCLK_GATE_D and CBR1_VLV lose their state when the power well goes down, but fortunately the values we've been writing are actually the reset defaults. MI_ARB_VLV actually retains its value even if the power well was turned off, we just can't access it while the power well is down. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94164 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-9-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_pm.c | 15 --------------- drivers/gpu/drm/i915/intel_runtime_pm.c | 13 +++++++++++++ 2 files changed, 13 insertions(+), 15 deletions(-) commit 6b7eafc1b43d584081bfa6e8bd758121de18ca04 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:29 2016 +0300 drm/i915: Warn if irq_mask isn't ~0 during vlv/cvh display irq postinstall We expect vlv_display_irq_reset() to have been called prior to vlv_display_irq_postinstall() so let's WARN if that isn't the case. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-8-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 3 +++ 1 file changed, 3 insertions(+) commit 9ab981f22befda5524415db86ba83fd4188ceaee Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:28 2016 +0300 drm/i915: Use GEN5_IRQ_INIT() in vlv_display_irq_postinstall() Replace the hand rolled IMR/IER setup in vlv_display_irq_postinstall() with GEN5_IRQ_INIT(). Also rename the iir_mask to enable_mask to avoid consusion since we no longer deal with IIR here. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-7-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) commit d6c698035892c143e5cff5342477d3fd755b13fe Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:27 2016 +0300 drm/i915: Clear display interrupt before enabling when turning on the power well For a bit of extra paranoia make sure the display irqs are all cleared before we enabled them when turning on the power well. This should really be the case already since the power well was off which resets everything. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) commit 8bb613068a639c35f880198d0dae0bb27a3bfe56 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 18:56:44 2016 +0300 drm/i915: Move vlv/chv display irq code to a more logical place Reshuffle the code a bit to move the vlv/chv display irq functions away from the main irq hooks, next to the other sub (de,gt,etc.) hooks. v2: Rebased due to changes in vlv_display_irq_reset() Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> (v1) Link: http://patchwork.freedesktop.org/patch/msgid/1460476604-2035-1-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/i915_irq.c | 102 ++++++++++++++++++++-------------------- 1 file changed, 51 insertions(+), 51 deletions(-) commit 9918271efc7ab9e5efc9580270f67c126901b06f Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:25 2016 +0300 drm/i915: Skip display irq setup if display irqs aren't flagged as enabled During runtime PM we'll be reinitializing interrupt support from the ground up. However since the display power well will be off at that time, well end up with a ton of unclaimed register accesses from the display irq setup. Since we turned off the power well already before runtime suspend, we've flagged display irqs as disabled during runtime PM transitions. So we can just check that flag to see if we should do skip display irqs during irq setup. During driver load display irqs will be flagged as enabled since we've turned on the power well already, however the power well code will have skipped the display irq setup since irq support as a whole wasn't yet enabled when the power well was enabled. So we'll want to do the display irq setup in that case. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94164 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) commit ad22d10654ea0e5eb46fa46ae3f716bfc1d43ce3 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Apr 12 18:56:14 2016 +0300 drm/i915: Fix up vlv/chv display irq setup The vlv/chv display irq setup was a bit of mess after I ran out of steam when working on it last. Fix it up so that we just have a _reset() and _postinstall() hooks for the display irqs, and use those consistently. v2: Clear out pipestat_irq_mask[] and PIPE_FIFO_UNDERRUN_STATUS in vlv_display_irq_reset() (Imre) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> (v1) Link: http://patchwork.freedesktop.org/patch/msgid/1460476574-1921-1-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/i915_irq.c | 109 +++++++++++----------------------------- 1 file changed, 29 insertions(+), 80 deletions(-) commit 93de68f94081ea2cbc55e47dc84bcd606264050a Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 16:56:23 2016 +0300 drm/i915: Remove "VLV magic" from irq setup No clue what this is supposed to achieve. I think it's been there since the very beginning, so presumably some kind of kludge for very early silicon. Let's just throw it out. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460382992-28728-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_irq.c | 6 ------ 1 file changed, 6 deletions(-) commit 6b23f3e8a601d7d5eaa82cede4b72d68165df566 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Apr 1 21:53:19 2016 +0300 drm/i915: Replace ILK eDP underrun suppression with something better The underruns we were seeing when enabling eDP port A on ILK seem to have been caused by prematurely clearing the LP1+ watermark values when disabling LP1+ watermarks. Now that the watermarks are handled properly, we can rip out the underrun suppression around the port A enable. We still need to worry about the underruns on FDI when enabling the eDP PLL. But as Bspec tells us, we can avoid that by a vblank wait on the pipe driving FDI just prior to enabling the eDP PLL. Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459536799-18109-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> drivers/gpu/drm/i915/intel_dp.c | 36 +++++++++--------------------------- 1 file changed, 9 insertions(+), 27 deletions(-) commit 1204d5baa8781a1bf968244bd2b0f15ed861e573 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Apr 1 21:53:18 2016 +0300 drm/i915: Make sure LP1+ watermarks levels are preserved when going from 1 to 2 pipes Once again ILK is unhappy if we clear out the LP1+ watermark levels outright, and instead we must disable the levels we don't want while still leaving the actual programmed watermark levels intact. Fixes underruns on the already enabled pipe when programming watermarks while enabling the second pipe. Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Matt Roper <matthew.d.roper@intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93787 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459536799-18109-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> drivers/gpu/drm/i915/intel_pm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b2c0593a0c91f7ba76224f6267a3212314cee88d Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Apr 1 21:53:17 2016 +0300 drm/i915: Try to shut up more ILK underruns Take a bigger hammer to the underrun suppression on ILK. Instead of trying to suppress them at specific points in the modeset sequence just silence them across the entire sequence. This gets rid of some underruns at least on my ILK. Note that this changes SNB and IVB to follow the same approach just to keep the code less convoluted. The difference is that on those platforms we won't suppress CPU underruns for port A since it doesn't seem to be necessary. My ILK has port A eDP and two PCH HDMI ports, so I can't be sure this is as effective on other PCH port types. Perhaps we still need some of Daniel's extra vblank waits [2]? I've still been able to trigger an underrun on the other pipe, but fixing that perhaps needs the LP1+ disable trick I implemented here [1] which never got merged. A few details which hamper stress testing on my ILK are that sometimes the PCH transcoder gets messed up and refuses to shut down, and sometimes even the panel power sequencer apparently gets stuck on the always on position. [1] https://lists.freedesktop.org/archives/intel-gfx/2014-March/041317.html [2] https://lists.freedesktop.org/archives/intel-gfx/2016-January/086397.html v2: Add a note that we also get underruns when enabling PCH ports Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> (v1) Link: http://patchwork.freedesktop.org/patch/msgid/1459536799-18109-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 45 ++++++++++++++++++------------------ drivers/gpu/drm/i915/intel_dp.c | 12 ---------- 2 files changed, 23 insertions(+), 34 deletions(-) commit 81b76485afb54e3efeb1de5edbef761f4ad2830e Author: Howard Cochran <hcochran@kernelspring.com> Date: Thu Mar 10 01:12:39 2016 -0500 writeback: Fix performance regression in wb_over_bg_thresh() Commit 947e9762a8dd ("writeback: update wb_over_bg_thresh() to use wb_domain aware operations") unintentionally changed this function's meaning from "are there more dirty pages than the background writeback threshold" to "are there more dirty pages than the writeback threshold". The background writeback threshold is typically half of the writeback threshold, so this had the effect of raising the number of dirty pages required to cause a writeback worker to perform background writeout. This can cause a very severe performance regression when a BDI uses BDI_CAP_STRICTLIMIT because balance_dirty_pages() and the writeback worker can now disagree on whether writeback should be initiated. For example, in a system having 1GB of RAM, a single spinning disk, and a "pass-through" FUSE filesystem mounted over the disk, application code mmapped a 128MB file on the disk and was randomly dirtying pages in that mapping. Because FUSE uses strictlimit and has a default max_ratio of only 1%, in balance_dirty_pages, thresh is ~200, bg_thresh is ~100, and the dirty_freerun_ceiling is the average of those, ~150. So, it pauses the dirtying processes when we have 151 dirty pages and wakes up a background writeback worker. But the worker tests the wrong threshold (200 instead of 100), so it does not initiate writeback and just returns. Thus, balance_dirty_pages keeps looping, sleeping and then waking up the worker who will do nothing. It remains stuck in this state until the few dirty pages that we have finally expire and we write them back for that reason. Then the whole process repeats, resulting in near-zero throughput through the FUSE BDI. The fix is to call the parameterized variant of wb_calc_thresh, so that the worker will do writeback if the bg_thresh is exceeded which was the bahavior before the referenced commit. Fixes: 947e9762a8dd ("writeback: update wb_over_bg_thresh() to use wb_domain aware operations") Signed-off-by: Howard Cochran <hcochran@kernelspring.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jens Axboe <axboe@fb.com> mm/page-writeback.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 69fb78121bf86c87490ea1453e310a39c320a70a Merge: 9a6f2b0 8805eea Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 12 11:57:53 2016 -0400 Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next Johan Hedberg says: ==================== pull request: bluetooth-next 2016-04-12 Here's a set of Bluetooth & 802.15.4 patches intended for the 4.7 kernel: - Fix for race condition in vhci driver - Memory leak fix for ieee802154/adf7242 driver - Improvements to deal with single-mode (LE-only) Bluetooth controllers - Fix for allowing the BT_SECURITY_FIPS security level - New BCM2E71 ACPI ID - NULL pointer dereference fix fox hci_ldisc driver Let me know if there are any issues pulling. Thanks. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 757d12e5849be549076901b0d33c60d5f360269c Author: Vinod Koul <vinod.koul@intel.com> Date: Tue Apr 12 21:07:06 2016 +0530 dmaengine: ensure dmaengine helpers check valid callback dmaengine has various device callbacks and exposes helper functions to invoke these. These helpers should check if channel, device and callback is valid or not before invoking them. Reported-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> include/linux/dmaengine.h | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit c1fd85b445d99236dc174b08b371de1a15a3d337 Author: Rhyland Klein <rklein@nvidia.com> Date: Mon Apr 11 17:53:02 2016 -0400 arm64: tegra: Add pinmux for Smaug board Add pinmux node for Tegra210 Smaug board. Signed-off-by: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210-smaug.dts | 1271 +++++++++++++++++++++++++ 1 file changed, 1271 insertions(+) commit e7d9b2709ab04059b6a5f0ff016826dc4d4f96e4 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Mar 17 14:19:05 2016 +0000 ARM: tegra: Correct interrupt type for ARM TWD The ARM TWD interrupt is a private peripheral interrupt (PPI) and per the ARM GIC documentation, whether the type for PPIs can be set is IMPLEMENTATION DEFINED. For Tegra20/30 devices the PPI type cannot be set and so when we attempt to set the type for the ARM TWD interrupt it fails. This has gone unnoticed because it fails silently and because we cannot re-configure the type it has had no impact. Nevertheless fix the type for the TWD interrupt so that it matches the hardware configuration. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra20.dtsi | 2 +- arch/arm/boot/dts/tegra30.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit f5bbb327a4e896a7f353762068b786852d98187b Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue Feb 9 13:51:59 2016 +0000 ARM: tegra: Add stdout-path for various boards For Tegra boards, the device-tree alias serial0 is used for the console and so add the stdout-path information so that the console no longer needs to be passed via the kernel boot parameters. This has been tested on boards, tegra20-trimslice, tegra30-beaver, tegra114-dalmore and tegra124-jetson-tk1. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra114-dalmore.dts | 4 ++++ arch/arm/boot/dts/tegra124-jetson-tk1.dts | 4 ++++ arch/arm/boot/dts/tegra124-nyan.dtsi | 4 ++++ arch/arm/boot/dts/tegra124-venice2.dts | 4 ++++ arch/arm/boot/dts/tegra20-harmony.dts | 4 ++++ arch/arm/boot/dts/tegra20-iris-512.dts | 4 ++++ arch/arm/boot/dts/tegra20-medcom-wide.dts | 4 ++++ arch/arm/boot/dts/tegra20-paz00.dts | 4 ++++ arch/arm/boot/dts/tegra20-seaboard.dts | 4 ++++ arch/arm/boot/dts/tegra20-tamonten.dtsi | 4 ++++ arch/arm/boot/dts/tegra20-trimslice.dts | 4 ++++ arch/arm/boot/dts/tegra20-ventana.dts | 4 ++++ arch/arm/boot/dts/tegra20-whistler.dts | 4 ++++ arch/arm/boot/dts/tegra30-apalis-eval.dts | 4 ++++ arch/arm/boot/dts/tegra30-beaver.dts | 4 ++++ arch/arm/boot/dts/tegra30-cardhu.dtsi | 4 ++++ arch/arm/boot/dts/tegra30-colibri-eval-v3.dts | 4 ++++ 17 files changed, 68 insertions(+) commit d1c04d30c3973df6ec0933f21ff8a56028e47ce7 Author: Sudeep Holla <Sudeep.Holla@arm.com> Date: Mon Feb 8 21:55:43 2016 +0000 ARM: tegra: Replace legacy *,wakeup property with wakeup-source Though the keyboard and other driver will continue to support the legacy "gpio-key,wakeup", "nvidia,wakeup-source" boolean property to enable the wakeup source, "wakeup-source" is the new standard binding. This patch replaces all the legacy wakeup properties with the unified "wakeup-source" property in order to avoid any further copy-paste duplication. Cc: Stephen Warren <swarren@wwwdotorg.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-tegra@vger.kernel.org Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra114-dalmore.dts | 2 +- arch/arm/boot/dts/tegra114-roth.dts | 2 +- arch/arm/boot/dts/tegra114-tn7.dts | 2 +- arch/arm/boot/dts/tegra124-jetson-tk1.dts | 2 +- arch/arm/boot/dts/tegra124-nyan.dtsi | 4 ++-- arch/arm/boot/dts/tegra124-venice2.dts | 2 +- arch/arm/boot/dts/tegra20-harmony.dts | 2 +- arch/arm/boot/dts/tegra20-paz00.dts | 2 +- arch/arm/boot/dts/tegra20-seaboard.dts | 4 ++-- arch/arm/boot/dts/tegra20-trimslice.dts | 2 +- arch/arm/boot/dts/tegra20-ventana.dts | 2 +- arch/arm/boot/dts/tegra20-whistler.dts | 2 +- arch/arm/boot/dts/tegra30-apalis-eval.dts | 2 +- arch/arm/boot/dts/tegra30-cardhu.dtsi | 2 +- arch/arm/boot/dts/tegra30-colibri-eval-v3.dts | 2 +- 15 files changed, 17 insertions(+), 17 deletions(-) commit b664129459f529d403d05570115254534611b52d Author: Maarten Lankhorst <dev@mblankhorst.nl> Date: Tue Nov 17 11:15:45 2015 +0100 ARM: tegra: Enable watchdog support for Tegra114 and Tegra124 Watchdog support was added to the timer block with Tegra30. Tegra20 did not have this yet. However, the Tegra114 and Tegra124 DTSI files had an entry in the compatible string list for "nvidia,tegra20-timer", but not for "nvidia,tegra30-timer", which is why watchdog support isn't enabled on them. Fix this by adding an entry for "nvidia,tegra30-timer" to the compatible string list of the timer block on Tegra114 and Tegra124. This allows the watchdog to work on Jetson TK1. Signed-off-by: Maarten Lankhorst <dev@mblankhorst.nl> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra114.dtsi | 2 +- arch/arm/boot/dts/tegra124.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit c90bb7b9b968272aa4ee7fed605105b00407395a Author: Ralf Ramsauer <ralf@ramses-pyramidenbau.de> Date: Tue Jan 26 17:59:18 2016 +0100 ARM: tegra: Add high speed UARTs to Jetson TK1 device tree This patch enables the APB DMA high speed UARTs of the Jetson TK1. So far, they were only enabled in NVidia's official BSP. Those additional UARTs are exposed on the expansion connector J3A2: UART1: Pin 41: BR_UART1_TXD Pin 44: BR_UART1_RXD UART2: Pin 65: UART2_RXD Pin 68: UART2_TXD Pin 71: UART2_CTS_L Pin 74: UART2_RTS_L Signed-off-by: Ralf Ramsauer <ralf@ramses-pyramidenbau.de> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra124-jetson-tk1.dts | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit e10982487d3bd84d8a7170a38a8ed07ea431322d Author: Ralf Ramsauer <ralf@ramses-pyramidenbau.de> Date: Tue Jan 26 17:59:17 2016 +0100 ARM: tegra: Fix copy/paste typo in several DTS includes The comment about the 8250 vs. APB DMA-enabled UART devices that was added for Tegra20 and Tegra30 in commit b6551bb933f9 ("ARM: tegra: dts: add aliases and DMA requestor for serial controller") introduced a typo that has since spread to various other DTS include files. Fix all occurrences of this typo. Signed-off-by: Ralf Ramsauer <ralf@ramses-pyramidenbau.de> Acked-by: Stephen Warren <swarren@nvidia.com> [treding@nvidia.com: amend subject, add commit message] Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/boot/dts/tegra114.dtsi | 2 +- arch/arm/boot/dts/tegra124.dtsi | 2 +- arch/arm/boot/dts/tegra20.dtsi | 2 +- arch/arm/boot/dts/tegra30.dtsi | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 955d809bdeaea3663cf6ac1ee72cd50775bbab9d Author: Masahiro Yamada <yamada.masahiro@socionext.com> Date: Sat Jan 23 17:55:30 2016 +0900 ARM: tegra: Remove redundant ARM_L1_CACHE_SHIFT_6 select These two are both ARMv7 SoCs. They need not explicitly select ARM_L1_CACHE_SHIFT_6 because it is enabled along with CPU_V7. Refer to commit a092f2b15399 ("ARM: 7291/1: cache: assume 64-byte L1 cachelines for ARMv7 CPUs"). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/Kconfig | 2 -- 1 file changed, 2 deletions(-) commit 3756685a18e6aa74ca3484192b64f4f8a11c8bb5 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 12 14:37:31 2016 +0100 drm/i915: Only grab correct forcewake for the engine with execlists Rather than blindly waking up all forcewake domains on command submission, we can teach each engine what is (or are) the correct one to take. On platforms with multiple forcewake domains like VLV, CHV, SKL and BXT, this has the potential of lowering the GPU and CPU power use and submission latency. To implement it we add a function named intel_uncore_forcewake_for_reg whose purpose is to query which forcewake domains need to be taken to read or write a specific register with raw mmio accessors. These enables the execlists engine setup to query which forcewake domains are relevant per engine on the currently running platform. v2: * Kerneldoc. * Split from intel_uncore.c macro extraction, WARN_ON, no warns on old platforms. (Chris Wilson) v3: * Single domain per engine, mention all registers, bi-directional function and a new name, fix handling of gen6 and gen7 writes. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460468251-14069-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_drv.h | 7 +++ drivers/gpu/drm/i915/intel_lrc.c | 27 ++++++-- drivers/gpu/drm/i915/intel_lrc.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.h | 1 + drivers/gpu/drm/i915/intel_uncore.c | 108 ++++++++++++++++++++++++++++++++ 5 files changed, 139 insertions(+), 5 deletions(-) commit a70ecc16d01c4fc732b81c6d7a755ef582691731 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 12 14:37:30 2016 +0100 drm/i915: Remove forcewake request registers from the shadowed table Chris Wilson points out that we can remove them from the array since they are always written to with raw accessors. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_uncore.c | 4 ---- 1 file changed, 4 deletions(-) commit 6863b76c6295490183ee198a4db5b2a072a68b4a Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Tue Apr 12 14:37:29 2016 +0100 drm/i915: Extract knowledge of register forcewake domains Knowledge of which register per platform belonds in which forcewake domain was embedded in the MMIO accessors themselves. Extract it into standalone macros so they can be used from new code in the following patches. This causes GCC to compile some of the MMIO accessors slightly differently and grows the code a tiny amount. But none of the growth is on the fast-path so it does not matter hugely. Affected sizes before: 00000000000026f0 00000000000001a5 t gen6_read16 0000000000002390 00000000000001a5 t gen6_read32 00000000000028a0 00000000000001a5 t gen6_read64 00000000000061d0 000000000000019e t gen8_write16 0000000000006510 000000000000019d t gen8_write32 0000000000006370 000000000000019d t gen8_write64 00000000000021f0 000000000000019d t gen8_write8 Affected sizes after: 0000000000002840 00000000000001aa t gen6_read16 00000000000024e0 00000000000001a9 t gen6_read32 00000000000029f0 00000000000001a9 t gen6_read64 0000000000004f20 00000000000001b5 t gen8_write16 0000000000004ba0 00000000000001b4 t gen8_write32 00000000000050e0 00000000000001b4 t gen8_write64 0000000000004d60 00000000000001b4 t gen8_write8 Other MMIO accessors are not affected in size. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Acked-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_uncore.c | 255 ++++++++++++++++++++++-------------- 1 file changed, 155 insertions(+), 100 deletions(-) commit 2556247dea686d6fd21f1b4249ec527b9b285201 Author: Jan Luebbe <jlu@pengutronix.de> Date: Sat Mar 26 12:28:26 2016 +0100 ARM: multi_v5_defconfig: Enable recommended options for systemd Enable FHANDLE, CGROUPS, BLK_DEV_BSG and DEVTMPFS as recommended by systemd (which also matches the multi_v7 defconfig). Also enable IPV6, which defaults to 'y' by now. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/multi_v5_defconfig | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 0fe3ff4454c9ba2c9d6774ecafed799fe009d145 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 8 15:02:10 2016 -0400 ARM: multi_v7_defconfig: Enable CPUFreq governors as modules Currently only the ondemand and performance CPUFreq policy governors are enabled in multi_v7 defconfig. But the other governors are also useful for some cases, enable them to allow users change the default if needed. The options are enabled as module to keep the kernel image size minimal. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/configs/multi_v7_defconfig | 4 ++++ 1 file changed, 4 insertions(+) commit 98d729c4b2e7ecf6ad775b7d1ff4c866e4f01b6c Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 8 15:02:09 2016 -0400 ARM: exynos_defconfig: Enable CPUFreq governors as modules Currently only the ondemand and performance CPUFreq policy governors are enabled in the Exynos defconfig. But the other governors are also useful for some cases, enable them to allow users change the default if needed. The options are enabled as module to keep the kernel image size minimal. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/configs/exynos_defconfig | 4 ++++ 1 file changed, 4 insertions(+) commit e0bef81db1d089c53ba001acac01d0b375078cb7 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Apr 4 16:43:50 2016 +0900 ARM: exynos_defconfig: Enable Trats2 audio codec, touchscreen and sensors The Exynos4412-based Trats2 board has Asahi Kasei AK 3-Axis Magnetometer, CM36651 proximity/ambient light sensor, MMS114 touchscreen and Wolfson Microelectronics WM1811 CODEC. Enable them in defconfig to get some testing coverage and use its features. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/configs/exynos_defconfig | 7 +++++++ 1 file changed, 7 insertions(+) commit 57fbcce37be7c1d2622b56587c10ade00e96afa3 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 12 15:56:15 2016 +0200 cfg80211: remove enum ieee80211_band This enum is already perfectly aliased to enum nl80211_band, and the only reason for it is that we get IEEE80211_NUM_BANDS out of it. There's no really good reason to not declare the number of bands in nl80211 though, so do that and remove the cfg80211 one. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Documentation/DocBook/80211.tmpl | 1 - drivers/net/wireless/admtek/adm8211.c | 4 +- drivers/net/wireless/ath/ar5523/ar5523.c | 4 +- drivers/net/wireless/ath/ath.h | 2 +- drivers/net/wireless/ath/ath10k/core.h | 2 +- drivers/net/wireless/ath/ath10k/htt_rx.c | 8 +- drivers/net/wireless/ath/ath10k/mac.c | 68 ++++---- drivers/net/wireless/ath/ath10k/wmi.c | 8 +- drivers/net/wireless/ath/ath5k/ani.c | 2 +- drivers/net/wireless/ath/ath5k/ath5k.h | 10 +- drivers/net/wireless/ath/ath5k/attach.c | 8 +- drivers/net/wireless/ath/ath5k/base.c | 32 ++-- drivers/net/wireless/ath/ath5k/debug.c | 6 +- drivers/net/wireless/ath/ath5k/pcu.c | 6 +- drivers/net/wireless/ath/ath5k/phy.c | 30 ++-- drivers/net/wireless/ath/ath5k/qcu.c | 8 +- drivers/net/wireless/ath/ath5k/reset.c | 6 +- drivers/net/wireless/ath/ath6kl/cfg80211.c | 22 +-- drivers/net/wireless/ath/ath6kl/core.h | 2 +- drivers/net/wireless/ath/ath6kl/wmi.c | 22 +-- drivers/net/wireless/ath/ath6kl/wmi.h | 2 +- drivers/net/wireless/ath/ath9k/calib.c | 6 +- drivers/net/wireless/ath/ath9k/channel.c | 8 +- drivers/net/wireless/ath/ath9k/common-init.c | 28 ++-- drivers/net/wireless/ath/ath9k/common.c | 4 +- drivers/net/wireless/ath/ath9k/debug_sta.c | 6 +- drivers/net/wireless/ath/ath9k/dynack.c | 2 +- drivers/net/wireless/ath/ath9k/htc_drv_init.c | 8 +- drivers/net/wireless/ath/ath9k/htc_drv_main.c | 12 +- drivers/net/wireless/ath/ath9k/htc_drv_txrx.c | 2 +- drivers/net/wireless/ath/ath9k/init.c | 12 +- drivers/net/wireless/ath/ath9k/main.c | 4 +- drivers/net/wireless/ath/ath9k/xmit.c | 4 +- drivers/net/wireless/ath/carl9170/mac.c | 12 +- drivers/net/wireless/ath/carl9170/main.c | 6 +- drivers/net/wireless/ath/carl9170/phy.c | 18 +-- drivers/net/wireless/ath/carl9170/rx.c | 2 +- drivers/net/wireless/ath/carl9170/tx.c | 8 +- drivers/net/wireless/ath/regd.c | 16 +- drivers/net/wireless/ath/regd.h | 2 +- drivers/net/wireless/ath/wcn36xx/main.c | 12 +- drivers/net/wireless/ath/wcn36xx/smd.c | 4 +- drivers/net/wireless/ath/wcn36xx/txrx.c | 2 +- drivers/net/wireless/ath/wil6210/cfg80211.c | 4 +- drivers/net/wireless/ath/wil6210/netdev.c | 2 +- drivers/net/wireless/ath/wil6210/wmi.c | 2 +- drivers/net/wireless/atmel/at76c50x-usb.c | 6 +- drivers/net/wireless/atmel/atmel.c | 2 +- drivers/net/wireless/broadcom/b43/b43.h | 4 +- drivers/net/wireless/broadcom/b43/main.c | 34 ++-- drivers/net/wireless/broadcom/b43/phy_ac.c | 2 +- drivers/net/wireless/broadcom/b43/phy_common.c | 2 +- drivers/net/wireless/broadcom/b43/phy_ht.c | 16 +- drivers/net/wireless/broadcom/b43/phy_lcn.c | 10 +- drivers/net/wireless/broadcom/b43/phy_lp.c | 30 ++-- drivers/net/wireless/broadcom/b43/phy_n.c | 176 ++++++++++----------- drivers/net/wireless/broadcom/b43/tables_lpphy.c | 14 +- drivers/net/wireless/broadcom/b43/tables_nphy.c | 16 +- drivers/net/wireless/broadcom/b43/tables_phy_lcn.c | 2 +- drivers/net/wireless/broadcom/b43/xmit.c | 8 +- drivers/net/wireless/broadcom/b43legacy/main.c | 12 +- drivers/net/wireless/broadcom/b43legacy/xmit.c | 2 +- .../broadcom/brcm80211/brcmfmac/cfg80211.c | 74 ++++----- .../net/wireless/broadcom/brcm80211/brcmfmac/p2p.c | 8 +- .../wireless/broadcom/brcm80211/brcmsmac/channel.c | 10 +- .../broadcom/brcm80211/brcmsmac/mac80211_if.c | 16 +- .../wireless/broadcom/brcm80211/brcmsmac/main.c | 4 +- drivers/net/wireless/cisco/airo.c | 6 +- drivers/net/wireless/intel/ipw2x00/ipw2100.c | 6 +- drivers/net/wireless/intel/ipw2x00/ipw2200.c | 12 +- drivers/net/wireless/intel/iwlegacy/3945-mac.c | 30 ++-- drivers/net/wireless/intel/iwlegacy/3945-rs.c | 22 +-- drivers/net/wireless/intel/iwlegacy/3945.c | 20 +-- drivers/net/wireless/intel/iwlegacy/4965-mac.c | 38 ++--- drivers/net/wireless/intel/iwlegacy/4965-rs.c | 22 +-- drivers/net/wireless/intel/iwlegacy/4965.c | 6 +- drivers/net/wireless/intel/iwlegacy/4965.h | 2 +- drivers/net/wireless/intel/iwlegacy/common.c | 70 ++++---- drivers/net/wireless/intel/iwlegacy/common.h | 30 ++-- drivers/net/wireless/intel/iwlegacy/debug.c | 4 +- drivers/net/wireless/intel/iwlwifi/dvm/agn.h | 8 +- drivers/net/wireless/intel/iwlwifi/dvm/debugfs.c | 4 +- drivers/net/wireless/intel/iwlwifi/dvm/dev.h | 6 +- drivers/net/wireless/intel/iwlwifi/dvm/devices.c | 4 +- drivers/net/wireless/intel/iwlwifi/dvm/lib.c | 6 +- drivers/net/wireless/intel/iwlwifi/dvm/mac80211.c | 12 +- drivers/net/wireless/intel/iwlwifi/dvm/main.c | 4 +- drivers/net/wireless/intel/iwlwifi/dvm/rs.c | 22 +-- drivers/net/wireless/intel/iwlwifi/dvm/rs.h | 2 +- drivers/net/wireless/intel/iwlwifi/dvm/rx.c | 2 +- drivers/net/wireless/intel/iwlwifi/dvm/rxon.c | 10 +- drivers/net/wireless/intel/iwlwifi/dvm/scan.c | 38 ++--- drivers/net/wireless/intel/iwlwifi/dvm/sta.c | 2 +- drivers/net/wireless/intel/iwlwifi/dvm/tx.c | 4 +- drivers/net/wireless/intel/iwlwifi/iwl-1000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-2000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-5000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-6000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-7000.c | 4 +- drivers/net/wireless/intel/iwlwifi/iwl-8000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 2 +- drivers/net/wireless/intel/iwlwifi/iwl-config.h | 2 +- .../net/wireless/intel/iwlwifi/iwl-eeprom-parse.c | 38 ++--- .../net/wireless/intel/iwlwifi/iwl-eeprom-parse.h | 6 +- drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.c | 26 +-- drivers/net/wireless/intel/iwlwifi/mvm/coex.c | 10 +- .../net/wireless/intel/iwlwifi/mvm/debugfs-vif.c | 6 +- drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 8 +- drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 16 +- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 6 +- drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/rs.c | 28 ++-- drivers/net/wireless/intel/iwlwifi/mvm/rs.h | 4 +- drivers/net/wireless/intel/iwlwifi/mvm/rx.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 4 +- drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 36 ++--- drivers/net/wireless/intel/iwlwifi/mvm/tdls.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 6 +- drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 4 +- drivers/net/wireless/intersil/orinoco/cfg.c | 6 +- drivers/net/wireless/intersil/orinoco/hw.c | 2 +- drivers/net/wireless/intersil/orinoco/scan.c | 4 +- drivers/net/wireless/intersil/p54/eeprom.c | 32 ++-- drivers/net/wireless/intersil/p54/main.c | 4 +- drivers/net/wireless/intersil/p54/p54.h | 2 +- drivers/net/wireless/intersil/p54/txrx.c | 4 +- drivers/net/wireless/mac80211_hwsim.c | 14 +- drivers/net/wireless/marvell/libertas/cfg.c | 10 +- drivers/net/wireless/marvell/libertas/cmd.c | 4 +- drivers/net/wireless/marvell/libertas_tf/main.c | 4 +- drivers/net/wireless/marvell/mwifiex/cfg80211.c | 34 ++-- drivers/net/wireless/marvell/mwifiex/cfp.c | 12 +- drivers/net/wireless/marvell/mwifiex/scan.c | 8 +- drivers/net/wireless/marvell/mwifiex/uap_cmd.c | 2 +- drivers/net/wireless/marvell/mwl8k.c | 88 +++++------ drivers/net/wireless/mediatek/mt7601u/init.c | 4 +- drivers/net/wireless/ralink/rt2x00/rt2800lib.c | 30 ++-- drivers/net/wireless/ralink/rt2x00/rt2x00.h | 4 +- drivers/net/wireless/ralink/rt2x00/rt2x00dev.c | 40 ++--- drivers/net/wireless/ralink/rt2x00/rt61pci.c | 22 +-- drivers/net/wireless/ralink/rt2x00/rt73usb.c | 22 +-- drivers/net/wireless/realtek/rtl818x/rtl8180/dev.c | 8 +- drivers/net/wireless/realtek/rtl818x/rtl8187/dev.c | 4 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 30 ++-- drivers/net/wireless/realtek/rtlwifi/base.c | 44 +++--- drivers/net/wireless/realtek/rtlwifi/regd.c | 16 +- drivers/net/wireless/realtek/rtlwifi/wifi.h | 2 +- drivers/net/wireless/rndis_wlan.c | 4 +- drivers/net/wireless/rsi/rsi_91x_mac80211.c | 100 ++++++------ drivers/net/wireless/rsi/rsi_91x_mgmt.c | 8 +- drivers/net/wireless/rsi/rsi_91x_pkt.c | 2 +- drivers/net/wireless/rsi/rsi_main.h | 2 +- drivers/net/wireless/st/cw1200/main.c | 10 +- drivers/net/wireless/st/cw1200/scan.c | 2 +- drivers/net/wireless/st/cw1200/sta.c | 6 +- drivers/net/wireless/st/cw1200/txrx.c | 2 +- drivers/net/wireless/st/cw1200/wsm.c | 4 +- drivers/net/wireless/ti/wl1251/main.c | 2 +- drivers/net/wireless/ti/wl1251/rx.c | 2 +- drivers/net/wireless/ti/wl12xx/main.c | 8 +- drivers/net/wireless/ti/wl12xx/scan.c | 20 +-- drivers/net/wireless/ti/wl18xx/cmd.c | 6 +- drivers/net/wireless/ti/wl18xx/event.c | 6 +- drivers/net/wireless/ti/wl18xx/main.c | 22 +-- drivers/net/wireless/ti/wl18xx/scan.c | 8 +- drivers/net/wireless/ti/wl18xx/tx.c | 2 +- drivers/net/wireless/ti/wlcore/cmd.c | 36 ++--- drivers/net/wireless/ti/wlcore/cmd.h | 6 +- drivers/net/wireless/ti/wlcore/main.c | 32 ++-- drivers/net/wireless/ti/wlcore/ps.c | 4 +- drivers/net/wireless/ti/wlcore/rx.c | 4 +- drivers/net/wireless/ti/wlcore/rx.h | 2 +- drivers/net/wireless/ti/wlcore/scan.c | 14 +- drivers/net/wireless/ti/wlcore/tx.c | 2 +- drivers/net/wireless/ti/wlcore/tx.h | 4 +- drivers/net/wireless/ti/wlcore/wlcore.h | 4 +- drivers/net/wireless/ti/wlcore/wlcore_i.h | 2 +- drivers/net/wireless/wl3501_cs.c | 2 +- drivers/net/wireless/zydas/zd1211rw/zd_mac.c | 4 +- drivers/staging/rtl8723au/core/rtw_mlme_ext.c | 4 +- drivers/staging/rtl8723au/include/ieee80211.h | 2 +- drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c | 54 +++---- drivers/staging/vt6655/channel.c | 4 +- drivers/staging/vt6655/device_main.c | 4 +- drivers/staging/vt6655/rxtx.c | 2 +- drivers/staging/vt6656/channel.c | 4 +- drivers/staging/vt6656/int.c | 2 +- drivers/staging/vt6656/main_usb.c | 2 +- drivers/staging/vt6656/rxtx.c | 2 +- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 10 +- drivers/staging/wlan-ng/cfg80211.c | 6 +- include/net/cfg80211.h | 44 ++---- include/net/mac80211.h | 12 +- include/uapi/linux/nl80211.h | 4 + net/mac80211/cfg.c | 14 +- net/mac80211/debugfs_netdev.c | 12 +- net/mac80211/ibss.c | 10 +- net/mac80211/ieee80211_i.h | 34 ++-- net/mac80211/iface.c | 2 +- net/mac80211/main.c | 6 +- net/mac80211/mesh.c | 10 +- net/mac80211/mesh_plink.c | 10 +- net/mac80211/mlme.c | 14 +- net/mac80211/rate.c | 2 +- net/mac80211/rc80211_minstrel.c | 6 +- net/mac80211/rc80211_minstrel_ht.c | 4 +- net/mac80211/rx.c | 6 +- net/mac80211/scan.c | 12 +- net/mac80211/spectmgmt.c | 4 +- net/mac80211/tdls.c | 18 +-- net/mac80211/trace.h | 6 +- net/mac80211/tx.c | 14 +- net/mac80211/util.c | 24 +-- net/mac80211/vht.c | 4 +- net/wireless/chan.c | 2 +- net/wireless/core.c | 8 +- net/wireless/debugfs.c | 4 +- net/wireless/ibss.c | 6 +- net/wireless/mesh.c | 4 +- net/wireless/mlme.c | 2 +- net/wireless/nl80211.c | 44 +++--- net/wireless/rdev-ops.h | 2 +- net/wireless/reg.c | 30 ++-- net/wireless/reg.h | 2 +- net/wireless/scan.c | 14 +- net/wireless/sme.c | 6 +- net/wireless/trace.h | 20 +-- net/wireless/util.c | 40 ++--- net/wireless/wext-compat.c | 14 +- 230 files changed, 1420 insertions(+), 1437 deletions(-) commit 35eb8f7b1a37013d7a38466ae58c39fbd2c57faa Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Wed Apr 6 17:38:44 2016 +0300 cfg80211: Improve Connect/Associate command documentation The roaming cases for the Connect command were not fully covered and neither Connect nor Associate command uses of the prev_bssid parameter were very clear. Add details to describe how the prev_bssid argument is supposed to be used and when the driver should use association or reassociation. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 26 +++++++++++++++++++++++--- include/uapi/linux/nl80211.h | 16 +++++++++++++--- 2 files changed, 36 insertions(+), 6 deletions(-) commit 4e1176dd615f11b7cb6791205dfb21647bf4580a Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Apr 7 17:04:34 2016 +0100 drm/i915: Do not serialize forcewake acquire across domains On platforms with multiple forcewake domains it seems more efficient to request all desired ones and then to wait for acks to avoid needlessly serializing on each domain. v2: Rebase. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1460045074-1006-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/intel_uncore.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 33c582c10aea6162711a11c1a7e6f21598fc3033 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Apr 7 17:04:33 2016 +0100 drm/i915: Simplify for_each_fw_domain iterators As the vast majority of users do not use the domain id variable, we can eliminate it from the iterator and also change the latter using the same principle as was recently done for for_each_engine. For a couple of callers which do need the domain mask, store it in the domain array (which already has the domain id), then both can be retrieved thence. Result is clearer code and smaller generated binary, especially in the tight fw get/put loops. Also, relationship between domain id and mask is no longer assumed in the macro. v2: Improve grammar in the commit message and rename the iterator to for_each_fw_domain_masked for consistency. (Dave Gordon) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Dave Gordon <david.s.gordon@intel.com> drivers/gpu/drm/i915/i915_debugfs.c | 5 ++--- drivers/gpu/drm/i915/i915_drv.h | 17 +++++++------- drivers/gpu/drm/i915/intel_uncore.c | 45 +++++++++++++++++-------------------- 3 files changed, 32 insertions(+), 35 deletions(-) commit a57a4a67e5ee1826df0f054ad98f397829e4c573 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Apr 7 17:04:32 2016 +0100 drm/i915: Use consistent forcewake auto-release timeout across kernel configs Because it is based on jiffies, current implementation releases the forcewake at any time between straight away and between 1ms and 10ms, depending on the kernel configuration (CONFIG_HZ). This is probably not what has been desired, since the dynamics of keeping parts of the GPU awake should not be correlated with this kernel configuration parameter. Change the auto-release mechanism to use hrtimers and set the timeout to 1ms with a 1ms of slack. This should make the GPU power consistent across kernel configs, and timer slack should enable some timer coalescing where multiple force-wake domains exist, or with unrelated timers. For GlBench/T-Rex this decreases the number of forcewake releases from ~480 to ~300 per second, and for a heavy combined OGL/OCL test from ~670 to ~360 (HZ=1000 kernel). Even though this reduction can be attributed to the average release period extending from 0-1ms to 1-2ms, as discussed above, it will make the forcewake timeout consistent for different CONFIG_HZ values. Real life measurements with the above workload has shown that, with this patch, both manage to auto-release the forcewake between 2-4 times per 10ms, even though the number of forcewake gets is dramatically different. T-Rex requests between 5-10 explicit gets and 5-10 implict gets in each 10ms period, while the OGL/OCL test requests 250 and 380 times in the same period. The two data points together suggest that the nature of the forwake accesses is bursty and that further changes and potential timeout extensions, or moving the start of timeout from the first to the last automatic forcewake grab, should be carefully measured for power and performance effects. v2: * Commit spelling. (Dave Gordon) * More discussion on numbers in the commit. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Dave Gordon <david.s.gordon@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_drv.h | 2 +- drivers/gpu/drm/i915/intel_uncore.c | 25 ++++++++++++++++--------- 2 files changed, 17 insertions(+), 10 deletions(-) commit fa44b7ec9bc4115513e59f31da1167166bd6346a Author: Takashi Iwai <tiwai@suse.de> Date: Tue Apr 12 15:23:05 2016 +0200 ALSA: hda - Update documentation Update the URLs for alsa-info.sh and hda-emu. Also drop the alsa-driver snapshot URL since it's been discontinued recently. Signed-off-by: Takashi Iwai <tiwai@suse.de> Documentation/sound/alsa/HD-Audio.txt | 26 ++++++++------------------ 1 file changed, 8 insertions(+), 18 deletions(-) commit 4f29efc0ea61de1482a27c580575d860385cd54f Author: Takashi Iwai <tiwai@suse.de> Date: Tue Apr 12 15:16:24 2016 +0200 ALSA: hda - Add missing capture_hook calls for dyn-ADC PCM streams The calls for capture_hook were missing in dyn_adc_capture_pcm_prepare and cleanup callbacks. Luckily there are no users of the capture hooks with dyn-adc PCM, so far, thus this doesn't change the behavior of existing devices, but it's a fix for a future usage. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/hda_generic.c | 2 ++ 1 file changed, 2 insertions(+) commit 1b311124a226f3c2b43a7aca08883b5e5acc720c Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:51:22 2016 +0200 drm/virtio: Drop dummy gamma table support No need to confuse userspace like this. Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Dave Airlie <airlied@redhat.com> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459331485-28376-8-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/virtio/virtgpu_display.c | 9 --------- 1 file changed, 9 deletions(-) commit bd983323e6c0a0c65762064930a11b17f5f93404 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:51:19 2016 +0200 drm/bochs: Drop fake gamma support Only really needed for fbdev emulation at 8bpp. And bochs doesn't do that. And either way bochs only does 32bit rgb, so this is all pretty much wasted dead code. The only consideration is that we need to not set up any gamma size either. Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Dave Airlie <airlied@redhat.com> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459331485-28376-5-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/bochs/bochs_fbdev.c | 15 --------------- drivers/gpu/drm/bochs/bochs_kms.c | 7 ------- 2 files changed, 22 deletions(-) commit 1050e689a63baffdadcd33498c15d859922504c0 Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Nov 6 11:00:23 2015 +0100 cxl: Delete an unnecessary check before the function call "kfree" The kfree() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/context.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 4f7bef7a9f69b1c6fe44b9f249b49056288475a4 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Sun Apr 10 22:53:48 2016 +0300 drivers: macintosh: rack-meter: fix bogus memsets Fix bogus memsets pointed out by sparse: linux-v4.3/drivers/macintosh/rack-meter.c:157:15: warning: memset with byte count of 0 linux-v4.3/drivers/macintosh/rack-meter.c:158:15: warning: memset with byte count of 0 Probably "&" is mistyped "*"; use ARRAY_SIZE to make it more safe. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/macintosh/rack-meter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c796d1d97c3035cf54d4d5a9e75abd094db80e76 Author: Aaro Koskinen <aaro.koskinen@iki.fi> Date: Sun Apr 10 22:53:47 2016 +0300 drivers: macintosh: rack-meter: limit idle ticks to total ticks Limit idle ticks to total ticks. This prevents the annoying rackmeter leds fully ON / OFF blinking state that happens on fully idling G5 Xserve systems. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/macintosh/rack-meter.c | 1 + 1 file changed, 1 insertion(+) commit 7f92bc5694557dee4cefa90df27feec16c7b62da Author: Daniel Axtens <dja@axtens.net> Date: Wed Jan 6 11:45:51 2016 +1100 powerpc: sparse: Include headers for __weak symbols Sometimes when sparse warns about undefined symbols, it isn't because they should have 'static' added, it's because they're overriding __weak symbols defined elsewhere, and the header has been missed. Fix a few of them by adding appropriate headers. Signed-off-by: Daniel Axtens <dja@axtens.net> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/process.c | 2 ++ arch/powerpc/kernel/prom.c | 1 + arch/powerpc/kernel/time.c | 1 + arch/powerpc/mm/mmap.c | 1 + 4 files changed, 5 insertions(+) commit 635218c785bef355bc8266a1fdb28f38cdca365d Author: Daniel Axtens <dja@axtens.net> Date: Wed Jan 6 11:45:50 2016 +1100 powerpc: sparse: static-ify some things As sparse suggests, these should be made static. Signed-off-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Stewart Smith <stewart@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/eeh_event.c | 2 +- arch/powerpc/kernel/ibmebus.c | 2 +- arch/powerpc/kernel/mce.c | 2 +- arch/powerpc/kernel/rtasd.c | 2 +- arch/powerpc/kernel/vio.c | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) commit f35034f8ac72925591ae96841fcbeebad1af1dc8 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Mar 22 15:42:14 2016 +0100 drm/core: Fix ordering in drm_mode_config_cleanup. __drm_atomic_helper_plane_destroy_state calls drm_framebuffer_unreference, which means that if drm_framebuffer_free is called before plane->destroy freed memory will be accessed. A similar case happens for the blob list, which was freed before the crtc state was, resulting in the unreference_blob from crtc_destroy_state pointing to garbage memory causing another opportunity for a GPF. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458657734-21866-1-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/drm_crtc.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit a05628195a0d9f3173dd9aa76f482aef692e46ee Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 10:23:51 2016 +0300 drm/i915: Get panel_type from OpRegion panel details We've had problems on several occasions with using the panel type from the VBT block 40. Usually it seems to be 2, which often doesn't give us the correct timings for the panel. After some more digging I found a way to get a panel type via the OpRegion SWSCI GBDA "Get Panel Details" method. Let's try to use it. The spec has this to say about the output: "Bits [15:8] - Panel Type Bits contain the panel type user setting from CMOS 00h = Not Valid, use default Panel Type & Timings from VBT 01h - 0Fh = Panel Number" Another version of the spec lists the valid range as 1-16, which makes more sense since VBT supports 16 panels. Based on actual results from Rob's G45, 1-16 is what we need to accept. The other bits in the output don't look relevant for the problem at hand. The input is specified as: "Bits [31:4] - Reserved Reserved (must be zero) Bits [3:0] - Panel Number These bits contain the sequential index of Panel, starting at 0 and counting upwards from the first integrated Internal Flat-Panel Display Encoder present, and then from the first external Display Encoder (e.g., S/DVO-B then S/DVO-C) which supports Internal Flat-Panels. 0h - 0Fh = Panel number" For now I've just hardcoded the input panel number as 0. That would seem like a decent choise for LVDS. Not so sure about eDP when port != A. v2: Accept values 1-16 Filter out bogus results in opregion code (Jani) Add debug logging for all the different branches (Jani) Cc: Jani Nikula <jani.nikula@linux.intel.com> Cc: Rob Kramer <rob@solution-space.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94825 Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460359431-11003-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> Tested-by: Rob Kramer <rob@solution-space.com> drivers/gpu/drm/i915/i915_drv.h | 5 +++++ drivers/gpu/drm/i915/intel_bios.c | 20 +++++++++++++++----- drivers/gpu/drm/i915/intel_opregion.c | 28 ++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+), 5 deletions(-) commit 3e845c7a4095b7f051a61c8eb07d6d379c6e014f Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Apr 8 16:28:12 2016 +0300 drm/i915: Replace the static panel_type variable with dev_priv->vbt.panel_type Store the extracted panel_type under dev_priv.vbt instead of keeping around a static variable for it. Cc: Rob Kramer <rob@solution-space.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 13 +++++++++---- 2 files changed, 10 insertions(+), 4 deletions(-) commit eeeebea6cbe0d85817e2fa8eee8a2f5c9d88a44a Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Apr 11 10:22:09 2016 +0300 drm/i915: Reject panel_type > 0xf from VBT VBT can only contain 16 panel entries, indexed with the panel_type. To play it safe we should reject panel_type > 0xf, so that we don't read past the valid data. v2: Add debug logging (Jani) Cc: Jani Nikula <jani.nikula@linux.intel.com> Cc: Rob Kramer <rob@solution-space.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> (v1) Link: http://patchwork.freedesktop.org/patch/msgid/1460359329-10817-1-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_bios.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 706778013bc5ee97970de3a2deee80b007e29c25 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Mar 7 17:57:00 2016 +0200 drm/i915: Make GMBUS timeout message DRM_DEBUG_KMS There's no real reason the user should care that we're about to fall back to bitbanging, so let's change the message from DRM_INFO to DRM_DEBUG_KMS. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457366220-29409-5-git-send-email-ville.syrjala@linux.intel.com Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94890 Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_i2c.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3e4d44e0fabf22d742c9669572653fe3399afec5 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Mar 7 17:56:59 2016 +0200 drm/i915: Restore GMBUS operation after a failed bit-banging fallback When the GMBUS based i2c transfer times out, we try to fall back to bit-banging and retry the operation that way. However if the bit-banging attempt also fails, we should probably go back to the GMBUS method for the next attempt. Maybe there simply wasn't anyone one the bus at this time. There's also a bit of a mess going on with the force_bit handling. It's supposed to be a ref count actually, and it is as far as intel_gmbus_force_bit() is concerned. But it's treated as just a flag by the timeout based bit-banging fallback. I suppose that's fine since we should never end up in the timeout fallback case if force_bit was already non-zero. However now that we want to restore things back to where they were after the bit-banging attempt failed, we're going to have to do things a bit differently to avoid clobbering the force_bit count as set up by intel_gmbus_force_bit(). So let's dedicate the high bit as a flag for the low level timeout based fallback and treat the rest of the bits as a ref count just as before. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457366220-29409-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_i2c.c | 10 +++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) commit ade754ec1143caeada0bae01e4c3ea3188497bfd Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Mar 7 17:56:58 2016 +0200 drm/i915: Protect force_bit with gmbus_mutex Extend the protection of gmbus_mutex around the force_bit RMW in intel_gmbus_force_bit(), in case someone gets the idea of calling it from a separate thread while there's other stuff happening on the same bus. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457366220-29409-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_i2c.c | 5 +++++ 1 file changed, 5 insertions(+) commit acc98009b87a811f9f815650274a1044474cd167 Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Date: Wed Apr 6 17:39:07 2016 +0200 ARM: imx: always use TWD on IMX6Q There is no reason to limit the TWD to be used on SMP kernels only if the hardware has it available. On Wandboard i.MX6SOLO, running PREEMPT-RT and cyclictest I see as max immediately after start in idle: UP : ~90us SMP: ~50us UP + TWD: ~20us. Based on this numbers I prefer the TWD over the slightly slower MXC timer. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/mach-imx/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b1a928cdb477037fb7c10fbf94c47f65f2bcce77 Author: Jacek Lawrynowicz <jacek.lawrynowicz@intel.com> Date: Thu Mar 3 15:53:20 2016 +0100 PCI: Add DMA alias quirk for mic_x200_dma The MIC x200 NTB forwards DMA transactions upstream using multiple alien RIDs. These RIDs have to be added as aliases to the DMA device to allow buffer access when the IOMMU is enabled. Signed-off-by: Jacek Lawrynowicz <jacek.lawrynowicz@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Alex Williamson <alex.williamson@redhat.com> Acked-by: David Woodhouse <David.Woodhouse@intel.com> drivers/pci/quirks.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit fef95019016ac10e250d2c67a3c97af5797e3938 Author: Mark Brown <broonie@kernel.org> Date: Thu Apr 7 16:22:36 2016 +0200 regulator: core: Use parent voltage from the supply when bypassed When a regulator is in bypass mode it is functioning as a switch returning the voltage set in the regulator will not give the voltage being output by the regulator as it's just passing through its supply. This means that when we are getting the voltage from a regulator we should check to see if it is in bypass mode and if it is we should report the voltage from the supply rather than that which is set on the regulator. Reported-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> [treding@nvidia.com: return early for bypass mode] Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 4145ba76b1f7f3296cc673c299084145e1267029 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Fri Apr 8 09:21:10 2016 -0400 staging: unisys: visornic: prevent double-unlock of priv_lock Previously, devdata->priv_lock was being unlocked in visornic_serverdown() both before calling visornic_serverdown_complete(), then again at the end of the function. This bug was corrected. The structure of visornic_serverdown() was also improved to make it easier to follow and to decrease the chance that such bugs will be introduced again. The main-path logic now falls thru down the left-side of the page, with a common error-exit point to handle error conditions. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visornic/visornic_main.c | 40 +++++++++++++++---------- 1 file changed, 25 insertions(+), 15 deletions(-) commit 6fac083b8df8450af4550238faa104396ccecf13 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Fri Apr 8 08:48:05 2016 -0400 staging: unisys: visorinput: remove erroneous 'FIXME' comments These comments were mistakenly carried forward by a previous copy/paste. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorinput/visorinput.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit d2de2ffff5d36a6e38753cf4f9d6bd35b83bd6c5 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Apr 6 11:20:21 2016 -0400 staging: unisys: removed unused 'visor_device.respond_to_device_create' The respond_to_device_create flag was used previously when we used to delay responses to create requests until the drivers were finished loading. This behaviour was removed some time ago, yet the field still existed, while never being referenced or even initialized. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 1 - 1 file changed, 1 deletion(-) commit 4a185e54e15cbde6df85669b0af53db0575e17d0 Author: David Kershner <david.kershner@unisys.com> Date: Mon Apr 4 23:31:39 2016 -0400 staging: unisys: visorbus: make bus_epilog match device_epilog The paths in bus_epilog should match device_epilog. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) commit 3cb3fa3b7914cd1e3e576059d3034db5c8f3c894 Author: David Kershner <david.kershner@unisys.com> Date: Mon Apr 4 23:31:38 2016 -0400 staging: unisys: visorbus: device_epilog: clean up gotos The away flag is ambiguous, rename it to out and appropriately call the correct goto. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 36 ++++++++++---------------- 1 file changed, 13 insertions(+), 23 deletions(-) commit 1366a3db3dcf4d64c5eb0621df79a3d1cf2da5da Author: David Kershner <david.kershner@unisys.com> Date: Mon Apr 4 23:31:37 2016 -0400 staging: unisys: visorbus: visorchipset_init clean up gotos Several error paths were not logging a message to s-Par during failure. Error paths in visorchipset_init() were corrected so that they now all do proper clean-ups. This made it necessary to move the function visorchipset_file_cleanup() above visorchipset_init so it can be referenced. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 68 +++++++++++++++----------- 1 file changed, 40 insertions(+), 28 deletions(-) commit 2b9bcf81d37751ebdae8c1456d14c1462e4e8f61 Author: David Binder <david.binder@unisys.com> Date: Mon Apr 4 23:31:32 2016 -0400 staging: unisys: visorchannel: remove redundant member size Removes size member from the visorchannel struct, since it was a duplicate of the nbytes member. Signed-off-by: David Binder <david.binder@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchannel.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit dc38082f0f0967f8badce0ae5ecf07cd5843d65f Author: Tim Sell <Timothy.Sell@unisys.com> Date: Mon Apr 4 23:31:13 2016 -0400 staging: unisys: visornic: CHECK: Alignment should match open parenthesis Fix 'CHECK: Alignment should match open parenthesis' as recommended by checkpatch. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visornic/visornic_main.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit a07d7c3858aef317495e061ffc93207c89771fe2 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Mon Apr 4 23:31:12 2016 -0400 staging: unisys: visorbus: CHECK: Alignment should match open parenthesis Fix 'CHECK: Alignment should match open parenthesis' as recommended by checkpatch. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 80 +++++++++++++++----------- 1 file changed, 45 insertions(+), 35 deletions(-) commit e4feb2f257955cd9319f38bc935eda99ca6294b6 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Mon Apr 4 23:31:11 2016 -0400 staging: unisys: visorbus: 'unsigned' --> 'unsigned int' Fix as recommended by checkpatch. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3726470610327f353e816e21a86bc432dd929584 Author: Cihangir Akturk <cakturk@gmail.com> Date: Sat Apr 9 21:47:44 2016 +0300 staging: lustre: split error handling code into multiple labels Instead of using a switch-case statement to find out what kind of error has just happened, split error handling logic into multiple labels and jump right into the appropriate label to do the error handling. This way it is easier to follow different code paths. It also looks easy on the eyes. Additionally silences the following coccinelle warning: drivers/staging/lustre/lustre/obdecho/echo_client.c:762:22-27: ERROR: ed is NULL but dereferenced. Signed-off-by: Cihangir Akturk <cakturk@gmail.com> Acked-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lustre/obdecho/echo_client.c | 54 ++++++++-------------- 1 file changed, 20 insertions(+), 34 deletions(-) commit c970b6058b60e57c9b831fd69ded4cafb62fa308 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:50 2016 -0400 staging: lustre: selftest: change srpc_state_t to proper enum Turn typedef srpc_state_t to proper enum Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/rpc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit fd7a1a32514c46c1629290aa03d3e1d91c98dab4 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:48 2016 -0400 staging: lustre: selftest: convert srpc_msg_t to proper struct Turn typedef struct srpc_msg to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/conrpc.c | 14 +++++++------- drivers/staging/lustre/lnet/selftest/conrpc.h | 2 +- drivers/staging/lustre/lnet/selftest/console.c | 10 +++++----- drivers/staging/lustre/lnet/selftest/framework.c | 14 +++++++------- drivers/staging/lustre/lnet/selftest/ping_test.c | 4 ++-- drivers/staging/lustre/lnet/selftest/rpc.c | 11 ++++++----- drivers/staging/lustre/lnet/selftest/rpc.h | 6 +++--- drivers/staging/lustre/lnet/selftest/selftest.h | 10 +++++----- 9 files changed, 40 insertions(+), 39 deletions(-) commit dcdc7c84fbb227f46574a8c656cb4145b744af9c Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:46 2016 -0400 staging: lustre: selftest: convert lstcon_batch_t to proper struct Turn typedef lstcon_batch_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 4 +-- drivers/staging/lustre/lnet/selftest/console.c | 46 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/console.h | 7 ++-- 3 files changed, 29 insertions(+), 28 deletions(-) commit 7299d186046b6cb285951abe75fa691c24c3a1a8 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:45 2016 -0400 staging: lustre: selftest: convert lstcon_tsb_hdr_t to proper struct Turn typedef lstcon_tsb_hdr_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 5 +++-- drivers/staging/lustre/lnet/selftest/console.c | 2 +- drivers/staging/lustre/lnet/selftest/console.h | 8 ++++---- 3 files changed, 8 insertions(+), 7 deletions(-) commit 6bd88c7ad462ed00d63e508832bad5621d091696 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:44 2016 -0400 staging: lustre: selftest: convert lstcon_group_t to proper struct Turn typedef lstcon_group_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 6 +- drivers/staging/lustre/lnet/selftest/console.c | 80 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/console.h | 9 +-- 3 files changed, 48 insertions(+), 47 deletions(-) commit e00f978ef5821c0c607a3002babd3a872149d2d4 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:43 2016 -0400 staging: lustre: selftest: convert lstcon_ndlink_t to proper struct Turn typedef lstcon_ndlink_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 6 +-- drivers/staging/lustre/lnet/selftest/console.c | 64 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/console.h | 7 +-- 3 files changed, 39 insertions(+), 38 deletions(-) commit f1e34162fe284dd414c2a70f5814867b0f3c2b67 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:42 2016 -0400 staging: lustre: selftest: convert lstcon_node_t to proper struct Turn typedef lstcon_node_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 32 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/console.c | 20 ++++++++-------- drivers/staging/lustre/lnet/selftest/console.h | 9 ++++---- 3 files changed, 31 insertions(+), 30 deletions(-) commit d8742c855b69b28bdb7119375549c561728e74b3 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:41 2016 -0400 staging: lustre: selftest: convert lstcon_rpc_trans_t to proper struct Turn typedef lstcon_rpc_trans_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 36 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/conrpc.h | 20 +++++++------- drivers/staging/lustre/lnet/selftest/console.c | 20 +++++++------- drivers/staging/lustre/lnet/selftest/console.h | 2 +- 4 files changed, 39 insertions(+), 39 deletions(-) commit dc4f95fa5998e43df930d8b54807f78fe8cc344b Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:40 2016 -0400 staging: lustre: selftest: convert lstcon_rpc_t to proper struct Turn typedef lstcon_rpc_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/conrpc.c | 50 +++++++++++++------------- drivers/staging/lustre/lnet/selftest/conrpc.h | 18 +++++----- drivers/staging/lustre/lnet/selftest/console.c | 2 +- 3 files changed, 35 insertions(+), 35 deletions(-) commit d6615d143013575012adb0133ec22b07fcce510f Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:39 2016 -0400 staging: lustre: selftest: convert sfw_test_case_t to proper struct Turn typedef sfw_test_case_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/framework.c | 16 ++++++++-------- drivers/staging/lustre/lnet/selftest/selftest.h | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) commit d875b0ce5f218bc9848a93a154b9315c9e5efaf7 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:38 2016 -0400 staging: lustre: selftest: convert sfw_test_unit_t to proper struct Turn typedef sfw_test_unit_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/framework.c | 20 ++++++++++---------- drivers/staging/lustre/lnet/selftest/ping_test.c | 4 ++-- drivers/staging/lustre/lnet/selftest/selftest.h | 6 +++--- 4 files changed, 19 insertions(+), 19 deletions(-) commit 7ca48d8585ee50789e5ae2fa77ffb355ae14cabf Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:37 2016 -0400 staging: lustre: selftest: convert sfw_test_instance_t to proper struct Turn typedef sfw_test_instance_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/framework.c | 26 ++++++++++++------------ drivers/staging/lustre/lnet/selftest/ping_test.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/selftest.h | 6 +++--- 4 files changed, 24 insertions(+), 24 deletions(-) commit d9c460ea761c5be5c5a386416be2517c824bd293 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:36 2016 -0400 staging: lustre: selftest: convert sfw_test_client_ops_t to proper struct Turn typedef sfw_test_client_ops_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 3 ++- drivers/staging/lustre/lnet/selftest/framework.c | 2 +- drivers/staging/lustre/lnet/selftest/ping_test.c | 3 ++- drivers/staging/lustre/lnet/selftest/selftest.h | 14 +++++++------- 4 files changed, 12 insertions(+), 10 deletions(-) commit 074bca96640d91623a6a50d060e05ddd8d7200bc Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:35 2016 -0400 staging: lustre: selftest: convert sfw_batch_t to proper struct Turn typedef sfw_batch_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/framework.c | 38 ++++++++++++------------ drivers/staging/lustre/lnet/selftest/selftest.h | 6 ++-- 2 files changed, 22 insertions(+), 22 deletions(-) commit 693d26648a4dcbb08b8ea77bade6ac02fde8a046 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:34 2016 -0400 staging: lustre: selftest: convert sfw_session_t to proper struct Turn typedef sfw_session_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 6 ++-- drivers/staging/lustre/lnet/selftest/framework.c | 40 ++++++++++++------------ drivers/staging/lustre/lnet/selftest/ping_test.c | 8 ++--- drivers/staging/lustre/lnet/selftest/selftest.h | 6 ++-- 4 files changed, 30 insertions(+), 30 deletions(-) commit 682513b8634f8d5128ec67551d8ff94aaafd1c5c Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:33 2016 -0400 staging: lustre: selftest: convert srpc_service_t to proper struct Turn typedef srpc_service_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 3 ++- drivers/staging/lustre/lnet/selftest/console.c | 3 ++- drivers/staging/lustre/lnet/selftest/framework.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/ping_test.c | 3 ++- drivers/staging/lustre/lnet/selftest/rpc.c | 10 ++++----- drivers/staging/lustre/lnet/selftest/selftest.h | 26 ++++++++++++------------ 6 files changed, 28 insertions(+), 25 deletions(-) commit 20234da54283d138d2aceba0c4e295d8a8eaae46 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:32 2016 -0400 staging: lustre: selftest: convert srpc_client_rpc_t to proper struct Turn typedef srpc_client_rpc_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 6 ++-- drivers/staging/lustre/lnet/selftest/conrpc.c | 8 ++--- drivers/staging/lustre/lnet/selftest/conrpc.h | 2 +- drivers/staging/lustre/lnet/selftest/framework.c | 36 ++++++++++---------- drivers/staging/lustre/lnet/selftest/ping_test.c | 4 +-- drivers/staging/lustre/lnet/selftest/rpc.c | 32 +++++++++--------- drivers/staging/lustre/lnet/selftest/selftest.h | 42 ++++++++++++------------ 7 files changed, 65 insertions(+), 65 deletions(-) commit 25a9ca5202e6f8d1e5c9eafc239788d9ebffb02c Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:31 2016 -0400 staging: lustre: selftest: convert swi_workitem_t to proper struct Turn typedef swi_workitem_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/framework.c | 4 ++-- drivers/staging/lustre/lnet/selftest/rpc.c | 8 ++++---- drivers/staging/lustre/lnet/selftest/selftest.h | 26 +++++++++++++----------- 3 files changed, 20 insertions(+), 18 deletions(-) commit 4b064e95282483f5cebc12a2f242212e42192c48 Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:30 2016 -0400 staging: lustre: selftest: convert srpc_buffer_t to proper struct Turn typedef srpc_buffer_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/rpc.c | 12 ++++++------ drivers/staging/lustre/lnet/selftest/selftest.h | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) commit eb6e1342eea4576627f143da3163865978c72d1e Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:29 2016 -0400 staging: lustre: selftest: convert srpc_bulk_t to proper struct Turn typedef srpc_bulk_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 14 +++++++------- drivers/staging/lustre/lnet/selftest/conrpc.c | 4 ++-- drivers/staging/lustre/lnet/selftest/framework.c | 2 +- drivers/staging/lustre/lnet/selftest/rpc.c | 18 +++++++++--------- drivers/staging/lustre/lnet/selftest/selftest.h | 17 +++++++++-------- 5 files changed, 28 insertions(+), 27 deletions(-) commit 82d4eb91ab1912cb9e8751b9aa0875af2ae36db2 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:36 2016 +0200 ASoC: sti: unip reader tdm mode Here are the changes to enable reader tdm mode: - When TDM_ENABLE is set to 1, the i2s format should be automatically configured. Unfortunately this is not the case (HW bug). Then, we shall force DATA_SIZE setting. - Compute the transfer size for tdm mode: transfer size = user frame size - Manage tdm slots configuration given in DT. - Refine the hw param (channels & format) according to tdm slot config. Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/uniperif_reader.c | 229 +++++++++++++++++++++++++++++----------- 1 file changed, 168 insertions(+), 61 deletions(-) commit 8d8b1e2eddaef25ca0a18500dd9425638f1cfd02 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:35 2016 +0200 ASoC: sti: unip player tdm mode here are the changes to enable player tdm mode: - When TDM_ENABLE is set to 1, the i2s format should be automatically configured. Unfortunately this is not the case (HW bug). Then, we shall force DATA_SIZE setting. - Compute the transfer size for tdm mode: transfer size = user frame size - Manage tdm slots configuration given in DT. - Don't use mclk-fs when unip in tdm mode; use tdm slot config to compute frame size and to set mclk rate. - Refine the hw param (channels & format) according to tdm slot config. Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/sti_uniperif.c | 8 ++- sound/soc/sti/uniperif.h | 11 ++++ sound/soc/sti/uniperif_player.c | 109 +++++++++++++++++++++++++++++++++------- 3 files changed, 110 insertions(+), 18 deletions(-) commit 72199787662612a7747248f8b56bc5d42694538f Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:34 2016 +0200 ASoC: sti: helper functions to fix tdm runtime params Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/sti_uniperif.c | 46 ++++++++++++++++++++++++++++++++++++++++++++ sound/soc/sti/uniperif.h | 6 ++++++ 2 files changed, 52 insertions(+) commit 44f948bdb175bf326911c9ba0e47389918161ce5 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:33 2016 +0200 ASoC: sti: helper functions for unip tdm slots configuration - sti_uniperiph_set_tdm_slot: store tdm slot config in unip context - sti_uniperiph_get_tdm_word_pos: configure unip tdm slots pos regs Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/sti_uniperif.c | 90 ++++++++++++++++++++++++++++++++++++++++++++ sound/soc/sti/uniperif.h | 23 +++++++++++ 2 files changed, 113 insertions(+) commit 8607338f3d9efd7be18b844ac087590e391f653a Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:28 2016 -0400 staging: lustre: selftest: convert srpc_event_t to proper struct Turn typedef srpc_event_t to proper structure Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/rpc.c | 20 ++++++++++---------- drivers/staging/lustre/lnet/selftest/selftest.h | 14 +++++++------- 2 files changed, 17 insertions(+), 17 deletions(-) commit c22594f6b13193c6f00c31eb8bee9ee05cae16da Author: James Simmons <jsimmons@infradead.org> Date: Wed Apr 6 15:25:27 2016 -0400 staging: lustre: selftest: convert srpc_event_type to proper enum Turn tyepdef srpc_event_type to proper enum Signed-off-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/selftest.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 0888f388e6ac44530473a5abc59ecb1efbc3fe23 Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Tue Apr 5 20:15:34 2016 +0530 staging/lustre/obdclass: fix build warning While building with W=1 we were getting the warning: drivers/staging/lustre/lustre/obdclass/cl_object.c:1056:16: warning: old-style function definition struct lu_env *cl_env_percpu_get() ^ Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Acked-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/cl_object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d7e2ee257038baeb03baef602500368a51ee9eef Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Apr 11 13:51:03 2016 +0200 spi: let SPI masters ignore their children for PM Let all SPI masters ignore their children: when it comes to power management: SPI children have no business doing keeping their parents awake: they are completely autonomous devices that just use their parent to talk, and the latter usecase must be power managed by the host itself on a per-message basis. Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi.c | 1 + 1 file changed, 1 insertion(+) commit 19c551482ad620336afb724bb6cfcf1720fa545c Author: Sebastien Buisson <sbuisson@ddn.com> Date: Mon Apr 4 21:37:02 2016 -0400 staging: lustre: fix 'no effect' errors Fix 'no effect' issues found by Coverity version 6.5.1: Unsigned compared against 0 (NO_EFFECT) This greater-than-or-equal-to-zero comparison of an unsigned value is always true. Remove useless cast. Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3907 Reviewed-on: http://review.whamcloud.com/7166 Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/xattr.c | 3 +-- drivers/staging/lustre/lustre/lmv/lmv_obd.c | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) commit e179800665228cc8126ddc8b052a57d0155d09f1 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:37:01 2016 -0400 staging: lustre: hsm: Add support to drop all pages for ll_data_version This will be used by HSM release to get data version and drop all caching pages from all clients, before sending IT_RELEASE close REQ to MDT. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/6794 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lustre/include/lustre/lustre_idl.h | 1 + .../lustre/lustre/include/lustre/lustre_user.h | 5 ++-- drivers/staging/lustre/lustre/llite/dir.c | 5 ++-- drivers/staging/lustre/lustre/llite/file.c | 35 +++++++++++++--------- .../staging/lustre/lustre/llite/llite_internal.h | 2 +- drivers/staging/lustre/lustre/lov/lov_merge.c | 11 +++++++ 6 files changed, 38 insertions(+), 21 deletions(-) commit e55a68b6ea623a501cfe5b74d63f5faa77281701 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:37:00 2016 -0400 staging: lustre: llite: cancel open lock before closing file In error handling path of ll_lease_open(), och has already been freed in ll_close_inode_openhandle() so the sequence of cancel open lock and close open handle need adjusting. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/7346 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 0fcd869f9e0947ddb22ba8ba197cbe43e39f97f3 Author: Sebastien Buisson <sbuisson@ddn.com> Date: Mon Apr 4 21:36:59 2016 -0400 staging: lustre: fix 'NULL pointer dereference' errors Fix 'NULL pointer dereference' defects found by Coverity version 6.5.0: Dereference after null check (FORWARD_NULL) For instance, Passing null pointer to a function which dereferences it. Dereference before null check (REVERSE_INULL) Null-checking variable suggests that it may be null, but it has already been dereferenced on all paths leading to the check. Dereference null return value (NULL_RETURNS) Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Signed-off-by: James Nunez <james.a.nunez@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3042 Reviewed-on: http://review.whamcloud.com/5868 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 10 ++++++---- drivers/staging/lustre/lustre/lov/lov_io.c | 3 ++- 2 files changed, 8 insertions(+), 5 deletions(-) commit a7a9ed4b5d2732f35c54601702d73c1cd1e7ee90 Author: JC Lafoucriere <jacques-charles.lafoucriere@cea.fr> Date: Mon Apr 4 21:36:58 2016 -0400 staging: lustre: hsm: Add CLF_RENAME_LAST flag Create a special flag for the last rename event. Signed-off-by: JC Lafoucriere <jacques-charles.lafoucriere@cea.fr> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3718 Reviewed-on: http://review.whamcloud.com/7260 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre/lustre_user.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 6a1938d95822f7a160100845035bdc19c5c72182 Author: Ned Bass <bass6@llnl.gov> Date: Mon Apr 4 21:36:57 2016 -0400 staging: lustre: mdc: document mdc_rpc_lock As this lock can be a bottleneck, clarifying why it is needed may be helpful to those working on client performance. Signed-off-by: Ned Bass <bass6@llnl.gov> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3443 Reviewed-on: http://review.whamcloud.com/6593 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Keith Mannthey <keith.mannthey@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_mdc.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 46dfb5aa980272230ceee48613aba5bd79951f33 Author: Gaurav Mahajan <gmahajan@ddn.com> Date: Mon Apr 4 21:36:56 2016 -0400 staging: lustre: llite: Delaying creation of client side proc entries. In client_common_fill_super() proc entries are created before before cl_sb_init() and therefore lu_site is not allocated resulting in client crash when tried reading lu_site stats. Delaying creation of proc entries after creation of all required data structures fixed the problem. Signed-off-by: Gaurav Mahajan <gmahajan@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2941 Reviewed-on: http://review.whamcloud.com/6852 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Emoly Liu <emoly.liu@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_lib.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 98b29828b71b19963f3b818bdbc3e8b32ffaa761 Author: Swapnil Pimpale <spimpale@ddn.com> Date: Mon Apr 4 21:36:54 2016 -0400 staging: lustre: lov: Get the correct address of lmm_objects The introduction of lmm_layout_gen makes the assumption that lmm_objects is present after lmm_stripe_count incorrect. Fixed this to get the correct address of lmm_objects when lmmk is cast to lov_mds_md_v1. Signed-off-by: Swapnil Pimpale <spimpale@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3162 Reviewed-on: http://review.whamcloud.com/7258 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lov/lov_pack.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit c5300d55e2d5769ff4cffce3e667d991ed30eac8 Author: Aurelien Degremont <aurelien.degremont@cea.fr> Date: Mon Apr 4 21:36:53 2016 -0400 staging: lustre: hsm: copy start error should set HP_FLAG_COMPLETED If an error occurs when initializing a HSM request, in ll_ioc_copy_start(), the PROGRESS message, sent to coordinator, should carry the error code but also HP_FLAG_COMPLETED to mark the request as finished (with error). If not, the Coordinator will ignore this message and consider the request is still running. Signed-off-by: Aurelien Degremont <aurelien.degremont@cea.fr> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3685 Reviewed-on: http://review.whamcloud.com/7265 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 3 +++ 1 file changed, 3 insertions(+) commit 18ecab0d95b0bb878cc7e22eb615cef21fcdd8eb Author: JC Lafoucriere <jacques-charles.lafoucriere@cea.fr> Date: Mon Apr 4 21:36:52 2016 -0400 staging: lustre: hsm: rename hai_zero() HSM function rename hai_zero() to hai_first(). Use a better name for hai helper Signed-off-by: JC Lafoucriere <jacques-charles.lafoucriere@cea.fr> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3709 Reviewed-on: http://review.whamcloud.com/7254 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre/lustre_user.h | 6 +++--- drivers/staging/lustre/lustre/mdc/mdc_request.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit ead028083510cd42abc9ae4d3847d53b54a19b15 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:36:51 2016 -0400 staging: lustre: hsm: Fix lu_ref for lease handle The lu_ref was not being decremented when releasing the lease handle. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/7243 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 4 ++-- drivers/staging/lustre/lustre/mdc/mdc_lib.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 83c61a5c54b712e0aea9dba556e661575daf3fcc Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:36:50 2016 -0400 staging: lustre: libcfs: make D_HSM a unique value Redefine D_HSM. It was defined to D_TRACE. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/7243 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_debug.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 6f11cd978e59551de52e018c7bf8fc9d6ae6366c Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:36:49 2016 -0400 staging: lustre: libcfs: create array of debug names Instead of a using a growing case statement to handle more debugging options create a array to map debug flags to string names. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/7243 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_debug.h | 13 +++ drivers/staging/lustre/lnet/libcfs/debug.c | 126 ++------------------- 2 files changed, 23 insertions(+), 116 deletions(-) commit 66fbe4ef96790b55b4218b0281cc26157993552b Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Mon Apr 4 21:36:48 2016 -0400 staging: lustre: libcfs: remove userland comments in libcfs_debug.h Remove comments about userland use. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3647 Reviewed-on: http://review.whamcloud.com/7243 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_debug.h | 4 ---- 1 file changed, 4 deletions(-) commit d467220e61294a6e30716c3ea55641d7df8d0440 Author: Niu Yawei <yawei.niu@intel.com> Date: Mon Apr 4 21:36:47 2016 -0400 staging: lustre: llite: use 64bits flags in ll_lov_setea() In ll_lov_setea(), setting MDS_OPEN_HAS_OBJS to an int flags will result in the flags being overflowed. Signed-off-by: Niu Yawei <yawei.niu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3744 Reviewed-on: http://review.whamcloud.com/7312 Reviewed-by: Emoly Liu <emoly.liu@intel.com> Reviewed-by: Jian Yu <jian.yu@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 7 ++++--- drivers/staging/lustre/lustre/llite/llite_internal.h | 2 +- drivers/staging/lustre/lustre/llite/xattr.c | 6 +++--- 3 files changed, 8 insertions(+), 7 deletions(-) commit 0715f9417ad3581e721d4b2ca6d11aa9fb0e598d Author: Sebastien Buisson <sbuisson@ddn.com> Date: Mon Apr 4 21:36:46 2016 -0400 staging: lustre: ldlm: fix 'deadcode' errors Fix 'deadcode' issues found by Coverity version 6.5.1: Logically dead code (DEADCODE) Execution cannot reach this statement. Signed-off-by: Sebastien Buisson <sbuisson@ddn.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3097 Reviewed-on: http://review.whamcloud.com/7167 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_flock.c | 6 ------ 1 file changed, 6 deletions(-) commit 7f2d15bb587a8ed8e2ddebd7ffdfcc94b5113f93 Author: Oleg Drokin <green@linuxhacker.ru> Date: Fri Apr 1 15:18:03 2016 -0400 staging/lustre: Get rid of ldlm_policy_res_t typedef Directly use enum ldlm_policy_res everywhere. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_internal.h | 2 - drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 49 +++++++++++----------- 2 files changed, 24 insertions(+), 27 deletions(-) commit da5ecb4dfd84fa4eaba782fc3fa0aa0f807a5804 Author: Oleg Drokin <green@linuxhacker.ru> Date: Fri Apr 1 15:18:01 2016 -0400 staging/lustre: Fix braces {} style This fixes all checkpatch form of this from the Lustre tree: CHECK: braces {} should be used on all arms of this statement Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/fld/fld_cache.c | 3 ++- .../lustre/lustre/include/lustre/lustre_idl.h | 3 ++- drivers/staging/lustre/lustre/include/obd_class.h | 3 ++- drivers/staging/lustre/lustre/llite/dir.c | 20 +++++++++++--------- drivers/staging/lustre/lustre/llite/llite_close.c | 3 ++- drivers/staging/lustre/lustre/llite/llite_lib.c | 9 +++++---- drivers/staging/lustre/lustre/llite/lloop.c | 3 ++- drivers/staging/lustre/lustre/llite/namei.c | 6 ++++-- drivers/staging/lustre/lustre/llite/rw.c | 6 ++++-- drivers/staging/lustre/lustre/llite/rw26.c | 3 ++- drivers/staging/lustre/lustre/llite/vvp_dev.c | 12 ++++++++---- drivers/staging/lustre/lustre/llite/vvp_io.c | 3 ++- drivers/staging/lustre/lustre/llite/xattr.c | 3 ++- drivers/staging/lustre/lustre/lmv/lmv_obd.c | 3 ++- drivers/staging/lustre/lustre/lov/lov_dev.c | 10 ++++++---- drivers/staging/lustre/lustre/lov/lov_io.c | 9 ++++++--- drivers/staging/lustre/lustre/lov/lov_object.c | 6 ++++-- drivers/staging/lustre/lustre/lov/lov_pack.c | 4 ++-- drivers/staging/lustre/lustre/lov/lovsub_dev.c | 9 ++++++--- drivers/staging/lustre/lustre/lov/lovsub_lock.c | 3 ++- drivers/staging/lustre/lustre/lov/lovsub_object.c | 6 ++++-- drivers/staging/lustre/lustre/obdclass/cl_io.c | 13 ++++++++----- drivers/staging/lustre/lustre/obdclass/cl_object.c | 9 ++++++--- .../staging/lustre/lustre/obdclass/lprocfs_status.c | 3 ++- drivers/staging/lustre/lustre/obdclass/lu_object.c | 3 ++- drivers/staging/lustre/lustre/obdclass/lustre_peer.c | 3 ++- drivers/staging/lustre/lustre/osc/osc_io.c | 3 ++- drivers/staging/lustre/lustre/osc/osc_lock.c | 3 ++- drivers/staging/lustre/lustre/osc/osc_object.c | 3 ++- drivers/staging/lustre/lustre/osc/osc_page.c | 3 ++- drivers/staging/lustre/lustre/osc/osc_request.c | 3 ++- drivers/staging/lustre/lustre/ptlrpc/client.c | 4 ++-- drivers/staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c | 9 +++++---- 33 files changed, 117 insertions(+), 69 deletions(-) commit 9a00a3e9fea1ea5affa7bea971299d3a5832daad Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:32 2016 +0200 ASoC: sti: define tdm type & default tdm hw config Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/uniperif.h | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) commit 5295a0dc31d5261ff64406ece25e8d9e91530d2e Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:31 2016 +0200 ASoC: sti: rename unip player type into common player & reader type Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/uniperif.h | 19 ++++++++++++++----- sound/soc/sti/uniperif_player.c | 31 +++++++++++-------------------- 2 files changed, 25 insertions(+), 25 deletions(-) commit 38535e8e6962405b7d8a365f2f367f62bca98565 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Apr 7 11:25:30 2016 +0200 ASoC: sti: macro for uniperif tdm regs access Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/sti/uniperif.h | 112 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) commit 69c542e8022ca53c5fee664548163809eb1777c3 Author: Shawn Guo <shawnguo@kernel.org> Date: Tue Apr 12 09:22:49 2016 +0800 clk: imx: vf610: fix whitespace in vf610-clock.h There is whitespace in VF610_CLK_OCOTP line. Fix it. Signed-off-by: Shawn Guo <shawnguo@kernel.org> include/dt-bindings/clock/vf610-clock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 26d5192953d88d6231d173281848a1c61f9e5d34 Author: Peter Griffin <peter.griffin@linaro.org> Date: Thu Mar 17 13:43:11 2016 +0000 ARM: rockchip: Fix use of plain integer as NULL pointer This fixes the following sparse build warning: mach-rockchip/platsmp.c:68:43: Using plain integer as NULL pointer Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/mach-rockchip/platsmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4506697d9f8537a8d33e9e002f8efceb32d10757 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Mon Feb 15 11:33:57 2016 +0800 soc: rockchip: power-domain: check the existing of regmap Check return value of syscon_node_to_regmap for rockchip_pm_domain_probe. If err value is returned, probe procedure should abort. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 4 ++++ 1 file changed, 4 insertions(+) commit afd7350a9ac08da87eb9f38a432a05eca99c10f2 Author: Stefan Agner <stefan@agner.ch> Date: Tue Apr 12 08:59:38 2016 +0800 clk: imx: vf610: add TCON ipg clock Add the ipg (bus) clock for the TCON modules (Timing Controller). This module is required by the new DCU DRM driver, since the display signals pass through TCON. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-vf610.c | 3 +++ include/dt-bindings/clock/vf610-clock.h | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) commit 3218b21ab07f066c99537fbbf2b4dc331b842246 Author: Stefan Agner <stefan@agner.ch> Date: Mon Apr 4 22:28:33 2016 -0700 clk: imx: vf610: fix DCU clock tree Similar to an earlier fix for the SAI clocks, the DCU clock hierarchy mixes the bus clock with the display controllers pixel clock. Tests have shown that the gates in CCM_CCGR3/9 registers do not control the DCU pixel clock, but only the register access clock (bus clock). Fix this by defining the parent clock of VF610_CLK_DCUx to be the bus clock (ipg_bus). Since the clock has not been used far, there are no further changes needed. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-vf610.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 00768a2bd3245eace0690fcf2c02776a256b66d7 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 22:08:55 2016 -0300 perf trace: Print unresolved symbol names as addresses Instead of having "[unknown]" as the name used for unresolved symbols, use the address in the callchain, in hexadecimal form: 28.801 ( 0.007 ms): qemu-system-x8/10065 ppoll(ufds: 0x55c98b39e400, nfds: 72, tsp: 0x7fffe4e4fe60, sigsetsize: 8) = 0 Timeout ppoll+0x91 (/usr/lib64/libc-2.22.so) [0x337309] (/usr/bin/qemu-system-x86_64) [0x336ab4] (/usr/bin/qemu-system-x86_64) main+0x1724 (/usr/bin/qemu-system-x86_64) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) [0xc59a9] (/usr/bin/qemu-system-x86_64) 35.265 (14.805 ms): gnome-shell/2287 ... [continued]: poll()) = 1 [0xf6fdd] (/usr/lib64/libc-2.22.so) g_main_context_iterate.isra.29+0x17c (/usr/lib64/libglib-2.0.so.0.4600.2) g_main_loop_run+0xc2 (/usr/lib64/libglib-2.0.so.0.4600.2) meta_run+0x2c (/usr/lib64/libmutter.so.0.0.0) main+0x3f7 (/usr/bin/gnome-shell) __libc_start_main+0xf0 (/usr/lib64/libc-2.22.so) [0x2909] (/usr/bin/gnome-shell) Suggested-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-fja1ods5vqpg42mdz09xcz3r@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit fd4be13067ef65bf33b965a18c717889305d5fea Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 22:03:56 2016 -0300 perf evsel: Allow unresolved symbol names to be printed as addresses The fprintf_sym() and fprintf_callchain() methods now allow users to change the existing behaviour of showing "[unknown]" as the name of unresolved symbols to instead show "[0x123456]", i.e. its address. The current patch doesn't change tools to use this facility, the results from 'perf trace' and 'perf script' cotinue like: 70.109 ( 0.001 ms): qemu-system-x8/10153 poll(ufds: 0x7f2d93ffe870, nfds: 1) = 0 Timeout [unknown] (/usr/lib64/libc-2.22.so) [unknown] (/usr/lib64/libspice-server.so.1.10.0) [unknown] (/usr/lib64/libspice-server.so.1.10.0) [unknown] (/usr/lib64/libspice-server.so.1.10.0) start_thread+0xca (/usr/lib64/libpthread-2.22.so) __clone+0x6d (/usr/lib64/libc-2.22.so) The next patch will make 'perf trace' use the new formatting. Suggested-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-fja1ods5vqpg42mdz09xcz3r@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/session.c | 27 ++++++++++++++++++--------- tools/perf/util/session.h | 1 + tools/perf/util/symbol.c | 25 +++++++++++++++++++++---- tools/perf/util/symbol.h | 6 ++++++ 4 files changed, 46 insertions(+), 13 deletions(-) commit fde54b7860ffff1c93e6b9abb3fbc3b8b95f2695 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 18:42:37 2016 -0300 perf trace: Make "--call-graph" affect just "raw_syscalls:sys_exit" We don't need the callchains at the syscall enter tracepoint, just when finishing it at syscall exit, so reduce the overhead by asking for callchains just at syscall exit. Suggested-by: Milian Wolff <milian.wolff@kdab.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-fja1ods5vqpg42mdz09xcz3r@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) commit 01e0d50c3f95cb1bae2dbfd83173bc2864d6d28c Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 18:39:37 2016 -0300 perf evsel: Rename config_callgraph() to config_callchain() and make it public The rename is for consistency with the parameter name. Make it public for fine grained control of which evsels should have callchains enabled, like, for instance, will be done in the next changesets in 'perf trace', to enable callchains just on the "raw_syscalls:sys_exit" tracepoint. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-og8vup111rn357g4yagus3ao@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 11 +++++------ tools/perf/util/evsel.h | 3 +++ 2 files changed, 8 insertions(+), 6 deletions(-) commit 22c8a376b55f327f7a25a318e87ba9202ba284bf Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 18:37:45 2016 -0300 perf evlist: Add (reset,set)_sample_bit methods For fiddling with sample_type fields in all evsels in an evlist. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-dg6yavctt0hzl2tsgfb43qsr@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evlist.c | 18 ++++++++++++++++++ tools/perf/util/evlist.h | 11 +++++++++++ 2 files changed, 29 insertions(+) commit e68ae9cf7d734e669bc0a981b4154f70d29b5059 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 18:15:29 2016 -0300 perf evsel: Do not use globals in config() Instead receive a callchain_param pointer to configure callchain aspects, not doing so if NULL is passed. This will allow fine grained control over which evsels in an evlist gets callchains enabled. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-2mupip6khc92mh5x4nw9to82@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/tests/perf-time-to-tsc.c | 2 +- tools/perf/builtin-kvm.c | 2 +- tools/perf/builtin-record.c | 2 +- tools/perf/builtin-top.c | 2 +- tools/perf/builtin-trace.c | 2 +- tools/perf/tests/bpf.c | 2 +- tools/perf/tests/code-reading.c | 2 +- tools/perf/tests/keep-tracking.c | 2 +- tools/perf/tests/openat-syscall-tp-fields.c | 2 +- tools/perf/tests/perf-record.c | 2 +- tools/perf/tests/switch-tracking.c | 2 +- tools/perf/util/evlist.h | 5 ++++- tools/perf/util/evsel.c | 7 ++++--- tools/perf/util/evsel.h | 5 ++++- tools/perf/util/record.c | 5 +++-- 15 files changed, 26 insertions(+), 18 deletions(-) commit 44621819ddc9d5d0bfd0b0616c6cf33c94189b67 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 15:49:11 2016 -0300 perf trace: Exclude the kernel part of the callchain leading to a syscall The kernel parts are not that useful: # trace -m 512 -e nanosleep --call dwarf usleep 1 0.065 ( 0.065 ms): usleep/18732 nanosleep(rqtp: 0x7ffc4ee4e200) = 0 syscall_slow_exit_work ([kernel.kallsyms]) do_syscall_64 ([kernel.kallsyms]) return_from_SYSCALL_64 ([kernel.kallsyms]) __nanosleep (/usr/lib64/libc-2.22.so) usleep (/usr/lib64/libc-2.22.so) main (/usr/bin/usleep) __libc_start_main (/usr/lib64/libc-2.22.so) _start (/usr/bin/usleep) # So lets just use perf_event_attr.exclude_callchain_kernel to avoid collecting it in the ring buffer: # trace -m 512 -e nanosleep --call dwarf usleep 1 0.063 ( 0.063 ms): usleep/19212 nanosleep(rqtp: 0x7ffc3df10fb0) = 0 __nanosleep (/usr/lib64/libc-2.22.so) usleep (/usr/lib64/libc-2.22.so) main (/usr/bin/usleep) __libc_start_main (/usr/lib64/libc-2.22.so) _start (/usr/bin/usleep) # Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-qctu3gqhpim0dfbcp9d86c91@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 3 +++ tools/perf/builtin-trace.c | 13 +++++++++++++ 2 files changed, 16 insertions(+) commit ea4539652eccc87b14fbcbc90467ebcb87f02ddb Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 12:15:48 2016 -0300 perf evsel: Introduce fprintf_callchain() method out of fprintf_sym() In 'perf trace' we're just interested in printing callchains, and we don't want to use the symbol_conf.use_callchain, so move the callchain part to a new method. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-kcn3romzivcpxb3u75s9nz33@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 4 ++-- tools/perf/util/evsel.h | 6 ++++++ tools/perf/util/session.c | 29 ++++++++++++++++++++++++----- 3 files changed, 32 insertions(+), 7 deletions(-) commit ff0c107806cf9d237e50e21de66d6909391071cd Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 11:14:06 2016 -0300 perf evsel: Rename print_ip() to fprintf_sym() As it receives a FILE, and its more than just the IP, which can even be requested not to be printed. For consistency with other similar methods in tools/perf/, name it as perf_evsel__fprintf_sym() and make it return the number of bytes printed, just like 'fprintf(3)' Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-84gawlqa3lhk63nf0t9vnqnn@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 10 ++++---- tools/perf/builtin-trace.c | 4 +-- tools/perf/util/session.c | 60 +++++++++++++++++++++------------------------ tools/perf/util/session.h | 8 +++--- 4 files changed, 39 insertions(+), 43 deletions(-) commit 566a08859f63a33746e25246c5cda0f52528d2e4 Author: Milian Wolff <milian.wolff@kdab.com> Date: Fri Apr 8 13:34:15 2016 +0200 perf trace: Add support for printing call chains on sys_exit events. Now, one can print the call chain for every encountered sys_exit event, e.g.: $ perf trace -e nanosleep --call-graph dwarf path/to/ex_sleep 1005.757 (1000.090 ms): ex_sleep/13167 nanosleep(...) = 0 syscall_slow_exit_work ([kernel.kallsyms]) syscall_return_slowpath ([kernel.kallsyms]) int_ret_from_sys_call ([kernel.kallsyms]) __nanosleep (/usr/lib/libc-2.23.so) [unknown] (/usr/lib/libQt5Core.so.5.6.0) QThread::sleep (/usr/lib/libQt5Core.so.5.6.0) main (path/to/ex_sleep) __libc_start_main (/usr/lib/libc-2.23.so) _start (path/to/ex_sleep) Note that it is advised to increase the number of mmap pages to prevent event losses when using this new feature. Often, adding `-m 10M` to the `perf trace` invocation is enough. This feature is also available in strace when built with libunwind via `strace -k`. Performance wise, this solution is much better: $ time find path/to/linux &> /dev/null real 0m0.051s user 0m0.013s sys 0m0.037s $ time perf trace -m 800M --call-graph dwarf find path/to/linux &> /dev/null real 0m2.624s user 0m1.203s sys 0m1.333s $ time strace -k find path/to/linux &> /dev/null real 0m35.398s user 0m10.403s sys 0m23.173s Note that it is currently not possible to configure the print output. Adding such a feature, similar to what is available in `perf script` via its `--fields` knob can be added later on. Signed-off-by: Milian Wolff <milian.wolff@kdab.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> LPU-Reference: 1460115255-17648-1-git-send-email-milian.wolff@kdab.com [ Split from a larger patch, do not print the IP, left align, remove dup call symbol__init(), added man page entry ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-trace.txt | 6 ++++++ tools/perf/builtin-trace.c | 22 ++++++++++++++++++++++ 2 files changed, 28 insertions(+) commit db3617f362d7e205621c1ccc22b77d224a81ee14 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 11 10:53:51 2016 -0300 perf evsel: Allow passing a left alignment when printing a symbol For callchains, etc where we want it to align just below the syscall name, for instance, in 'perf trace' Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-uk9ekchd67651c625ltaur5y@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 4 ++-- tools/perf/util/session.c | 6 +++++- tools/perf/util/session.h | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) commit 6186de9a491af030889b372193fc9f38c248e69a Author: Milian Wolff <milian.wolff@kdab.com> Date: Mon Apr 11 10:18:11 2016 -0300 perf evsel: Allow specifying a file to output in perf_evsel__print_ip As this function will be used in 'perf trace'. Cc: Jiri Olsa <jolsa@kernel.org> Link: http://lkml.kernel.org/n/tip-8x297v9utnxq77onikevvlse@git.kernel.org [ Split from a larger patch ] Signed-off-by: Milian Wolff <milian.wolff@kdab.com> tools/perf/builtin-script.c | 4 ++-- tools/perf/util/session.c | 39 +++++++++++++++++++++------------------ tools/perf/util/session.h | 3 ++- 3 files changed, 25 insertions(+), 21 deletions(-) commit 72c0809856b9174e71eab4e293089f6a114e0d41 Author: Wang Nan <wangnan0@huawei.com> Date: Fri Apr 8 15:07:25 2016 +0000 perf bpf: Automatically create bpf-output event __bpf_stdout__ This patch removes the need to set a bpf-output event in cmdline. By referencing a map named '__bpf_stdout__', perf automatically creates an event for it. For example: # perf record -e ./test_bpf_trace.c usleep 100000 [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.012 MB perf.data (2 samples) ] # perf script usleep 4639 [000] 261895.307826: 0 __bpf_stdout__: ffffffff810eb9a1 ... BPF output: 0000: 52 61 69 73 65 20 61 20 Raise a 0008: 42 50 46 20 65 76 65 6e BPF even 0010: 74 21 00 00 t!.. BPF string: "Raise a BPF event!" usleep 4639 [000] 261895.407883: 0 __bpf_stdout__: ffffffff8105d609 ... BPF output: 0000: 52 61 69 73 65 20 61 20 Raise a 0008: 42 50 46 20 65 76 65 6e BPF even 0010: 74 21 00 00 t!.. BPF string: "Raise a BPF event!" perf record -e ./test_bpf_trace.c usleep 100000 equals to: perf record -e bpf-output/no-inherit=1,name=__bpf_stdout__/ \ -e ./test_bpf_trace.c/map:__bpf_stdout__.event=__bpf_stdout__/ \ usleep 100000 Where test_bpf_trace.c is: /************************ BEGIN **************************/ #include <uapi/linux/bpf.h> struct bpf_map_def { unsigned int type; unsigned int key_size; unsigned int value_size; unsigned int max_entries; }; #define SEC(NAME) __attribute__((section(NAME), used)) static u64 (*ktime_get_ns)(void) = (void *)BPF_FUNC_ktime_get_ns; static int (*trace_printk)(const char *fmt, int fmt_size, ...) = (void *)BPF_FUNC_trace_printk; static int (*get_smp_processor_id)(void) = (void *)BPF_FUNC_get_smp_processor_id; static int (*perf_event_output)(void *, struct bpf_map_def *, int, void *, unsigned long) = (void *)BPF_FUNC_perf_event_output; struct bpf_map_def SEC("maps") __bpf_stdout__ = { .type = BPF_MAP_TYPE_PERF_EVENT_ARRAY, .key_size = sizeof(int), .value_size = sizeof(u32), .max_entries = __NR_CPUS__, }; static inline int __attribute__((always_inline)) func(void *ctx, int type) { char output_str[] = "Raise a BPF event!"; char err_str[] = "BAD %d\n"; int err; err = perf_event_output(ctx, &__bpf_stdout__, get_smp_processor_id(), &output_str, sizeof(output_str)); if (err) trace_printk(err_str, sizeof(err_str), err); return 1; } SEC("func_begin=sys_nanosleep") int func_begin(void *ctx) {return func(ctx, 1);} SEC("func_end=sys_nanosleep%return") int func_end(void *ctx) { return func(ctx, 2);} char _license[] SEC("license") = "GPL"; int _version SEC("version") = LINUX_VERSION_CODE; /************************* END ***************************/ Committer note: Testing with 'perf trace': # trace -e nanosleep --ev test_bpf_stdout.c usleep 1 0.007 ( 0.007 ms): usleep/729 nanosleep(rqtp: 0x7ffc5bbc5fe0) ... 0.007 ( ): __bpf_stdout__:Raise a BPF event!..) 0.008 ( ): perf_bpf_probe:func_begin:(ffffffff81112460)) 0.069 ( ): __bpf_stdout__:Raise a BPF event!..) 0.070 ( ): perf_bpf_probe:func_end:(ffffffff81112460 <- ffffffff81003d92)) 0.072 ( 0.072 ms): usleep/729 ... [continued]: nanosleep()) = 0 # Suggested-and-Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Wang Nan <wangnan0@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460128045-97310-5-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/bpf-loader.c | 37 ++++++++++++++++++++++++++++--------- 1 file changed, 28 insertions(+), 9 deletions(-) commit d78885739a7df111dc7b081f8a09e08a5fcfecc2 Author: Wang Nan <wangnan0@huawei.com> Date: Fri Apr 8 15:07:24 2016 +0000 perf bpf: Clone bpf stdout events in multiple bpf scripts This patch allows cloning bpf-output event configuration among multiple bpf scripts. If there exist a map named '__bpf_output__' and not configured using 'map:__bpf_output__.event=', this patch clones the configuration of another '__bpf_stdout__' map. For example, following command: # perf trace --ev bpf-output/no-inherit,name=evt/ \ --ev ./test_bpf_trace.c/map:__bpf_stdout__.event=evt/ \ --ev ./test_bpf_trace2.c usleep 100000 equals to: # perf trace --ev bpf-output/no-inherit,name=evt/ \ --ev ./test_bpf_trace.c/map:__bpf_stdout__.event=evt/ \ --ev ./test_bpf_trace2.c/map:__bpf_stdout__.event=evt/ \ usleep 100000 Signed-off-by: Wang Nan <wangnan0@huawei.com> Suggested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460128045-97310-4-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-record.c | 8 +++ tools/perf/builtin-trace.c | 7 +++ tools/perf/util/bpf-loader.c | 124 +++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/bpf-loader.h | 19 +++++++ 4 files changed, 158 insertions(+) commit 9a6f2b0113c8fce815db7c9d23754bdea4b428a0 Author: Andrew Lunn <andrew@lunn.ch> Date: Mon Apr 11 21:40:05 2016 +0200 net: mdio: Fix lockdep falls positive splat MDIO devices can be stacked upon each other. The current code supports two levels, which until recently has been enough for a DSA mdio bus on top of another bus. Now we have hardware which has an MDIO mux in the middle. Define an MDIO MUTEX class with three levels. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/phy/mdio-mux.c | 10 ++-------- drivers/net/phy/mdio_bus.c | 4 ++-- include/linux/mdio.h | 11 +++++++++++ 3 files changed, 15 insertions(+), 10 deletions(-) commit 9d2597e8c4e593e4a4dbe70837e9396e53a2665a Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Mon Apr 11 12:30:59 2016 -0400 MAINTAINERS: Add DT bindings to regulator framework entry The regulators DT bindings docs and shared headers used by regulator drivers and DTS are not listed as files for the regulator subsystem. So developers may not know who should receive patches to these dirs unless they rely on the get_maintainer.pl git-fallback option which usually makes more harm than good. This patch makes the correct recipient to be obtained using commands such as scripts/get_maintainer.pl --no-git-fallback. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> MAINTAINERS | 2 ++ 1 file changed, 2 insertions(+) commit c7e16e5257ec46530e3e874af38191746c137c83 Author: Jerry Hoemann <jerry.hoemann@hpe.com> Date: Mon Apr 11 15:02:26 2016 -0700 acpi: widen acpi_evaluate_dsm() revision and function-index arguments The ACPI specification states that arguments "Revision ID" and "Function Index" to a _DSM are type "Integer." Type Integers are 64 bit quantities. The function evaluate_dsm specifies these types as simple "int" which are 32 bits. Widen type passed to acpi_evaluate_dsm and its callers and derived callers to pass correct type. acpi_check_dsm and acpi_evaluate_dsm_typed had similar issue and were corrected as well. This is in preparation for libnvdimm implementing a generic _DSM passthrough facility to have the capacity to pass 64-bit values as the ACPI specification allows. [djbw: clarify the changelog, add rationale] Signed-off-by: Jerry Hoemann <jerry.hoemann@hpe.com> Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/utils.c | 4 ++-- include/acpi/acpi_bus.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) commit 56104cf2b8d20eed32c14eac8ac574c35377ab38 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 09:45:23 2016 +0100 IMA: Use the the system trusted keyrings instead of .ima_mok Add a config option (IMA_KEYRINGS_PERMIT_SIGNED_BY_BUILTIN_OR_SECONDARY) that, when enabled, allows keys to be added to the IMA keyrings by userspace - with the restriction that each must be signed by a key in the system trusted keyrings. EPERM will be returned if this option is disabled, ENOKEY will be returned if no authoritative key can be found and EKEYREJECTED will be returned if the signature doesn't match. Other errors such as ENOPKG may also be returned. If this new option is enabled, the builtin system keyring is searched, as is the secondary system keyring if that is also enabled. Intermediate keys between the builtin system keyring and the key being added can be added to the secondary keyring (which replaces .ima_mok) to form a trust chain - provided they are also validly signed by a key in one of the trusted keyrings. The .ima_mok keyring is then removed and the IMA blacklist keyring gets its own config option (IMA_BLACKLIST_KEYRING). Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com> include/keys/system_keyring.h | 13 ++----------- security/integrity/digsig.c | 30 ++++-------------------------- security/integrity/ima/Kconfig | 36 +++++++++++++++++++++++------------- security/integrity/ima/Makefile | 2 +- security/integrity/ima/ima_mok.c | 17 ++++------------- 5 files changed, 34 insertions(+), 64 deletions(-) commit d3bfe84129f65e0af2450743ebdab33d161d01c9 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:27 2016 +0100 certs: Add a secondary system keyring that can be added to dynamically Add a secondary system keyring that can be added to by root whilst the system is running - provided the key being added is vouched for by a key built into the kernel or already added to the secondary keyring. Rename .system_keyring to .builtin_trusted_keys to distinguish it more obviously from the new keyring (called .secondary_trusted_keys). The new keyring needs to be enabled with CONFIG_SECONDARY_TRUSTED_KEYRING. If the secondary keyring is enabled, a link is created from that to .builtin_trusted_keys so that the the latter will automatically be searched too if the secondary keyring is searched. Signed-off-by: David Howells <dhowells@redhat.com> certs/Kconfig | 8 ++++ certs/system_keyring.c | 87 +++++++++++++++++++++++++++++++++++-------- include/keys/system_keyring.h | 9 +++++ 3 files changed, 88 insertions(+), 16 deletions(-) commit 77f68bac9481ad440f4f34dda3d28c2dce6eb87b Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:26 2016 +0100 KEYS: Remove KEY_FLAG_TRUSTED and KEY_ALLOC_TRUSTED Remove KEY_FLAG_TRUSTED and KEY_ALLOC_TRUSTED as they're no longer meaningful. Also we can drop the trusted flag from the preparse structure. Given this, we no longer need to pass the key flags through to restrict_link(). Further, we can now get rid of keyring_restrict_trusted_only() also. Signed-off-by: David Howells <dhowells@redhat.com> certs/system_keyring.c | 2 -- include/keys/system_keyring.h | 1 - include/linux/key-type.h | 1 - include/linux/key.h | 21 +++++---------------- security/integrity/digsig.c | 3 +-- security/keys/key.c | 11 ++--------- security/keys/keyring.c | 29 +---------------------------- 7 files changed, 9 insertions(+), 59 deletions(-) commit a511e1af8b12f44c6e55786c463c9f093c214fb6 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:26 2016 +0100 KEYS: Move the point of trust determination to __key_link() Move the point at which a key is determined to be trustworthy to __key_link() so that we use the contents of the keyring being linked in to to determine whether the key being linked in is trusted or not. What is 'trusted' then becomes a matter of what's in the keyring. Currently, the test is done when the key is parsed, but given that at that point we can only sensibly refer to the contents of the system trusted keyring, we can only use that as the basis for working out the trustworthiness of a new key. With this change, a trusted keyring is a set of keys that once the trusted-only flag is set cannot be added to except by verification through one of the contained keys. Further, adding a key into a trusted keyring, whilst it might grant trustworthiness in the context of that keyring, does not automatically grant trustworthiness in the context of a second keyring to which it could be secondarily linked. To accomplish this, the authentication data associated with the key source must now be retained. For an X.509 cert, this means the contents of the AuthorityKeyIdentifier and the signature data. If system keyrings are disabled then restrict_link_by_builtin_trusted() resolves to restrict_link_reject(). The integrity digital signature code still works correctly with this as it was previously using KEY_FLAG_TRUSTED_ONLY, which doesn't permit anything to be added if there is no system keyring against which trust can be determined. Signed-off-by: David Howells <dhowells@redhat.com> certs/system_keyring.c | 20 +++++++++-- crypto/asymmetric_keys/restrict.c | 62 ++++++++++++++++---------------- crypto/asymmetric_keys/x509_parser.h | 6 ---- crypto/asymmetric_keys/x509_public_key.c | 21 +---------- include/crypto/public_key.h | 7 ++++ include/keys/system_keyring.h | 19 ++++------ kernel/module_signing.c | 2 +- security/integrity/digsig.c | 33 ++++++++++++++++- security/integrity/ima/ima_mok.c | 6 ++-- 9 files changed, 100 insertions(+), 76 deletions(-) commit 99716b7cae8263e1c7e7c1987e95d8f67071ab3e Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:26 2016 +0100 KEYS: Make the system trusted keyring depend on the asymmetric key type Make the system trusted keyring depend on the asymmetric key type as there's not a lot of point having it if you can't then load asymmetric keys onto it. This requires the ASYMMETRIC_KEY_TYPE to be made a bool, not a tristate, as the Kconfig language doesn't then correctly force ASYMMETRIC_KEY_TYPE to 'y' rather than 'm' if SYSTEM_TRUSTED_KEYRING is 'y'. Making SYSTEM_TRUSTED_KEYRING *select* ASYMMETRIC_KEY_TYPE instead doesn't work as the Kconfig interpreter then wrongly complains about dependency loops. Signed-off-by: David Howells <dhowells@redhat.com> certs/Kconfig | 1 + crypto/asymmetric_keys/Kconfig | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) commit cfb664ff2b71fbbdc438b8e6db2a1412440432a2 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:26 2016 +0100 X.509: Move the trust validation code out to its own file Move the X.509 trust validation code out to its own file so that it can be generalised. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/Makefile | 5 +- crypto/asymmetric_keys/restrict.c | 106 +++++++++++++++++++++++++++++++ crypto/asymmetric_keys/x509_parser.h | 6 ++ crypto/asymmetric_keys/x509_public_key.c | 79 ----------------------- 4 files changed, 116 insertions(+), 80 deletions(-) commit 5f7f5c81e59be5ce262c5b7d0ede9565a2558d80 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:25 2016 +0100 X.509: Use verify_signature() if we have a struct key * to use We should call verify_signature() rather than directly calling public_key_verify_signature() if we have a struct key to use as we shouldn't be poking around in the private data of the key struct as that's subtype dependent. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/x509_public_key.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 9eb029893ad5bf9303ed7f145860b312cbe5f889 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:25 2016 +0100 KEYS: Generalise x509_request_asymmetric_key() Generalise x509_request_asymmetric_key(). It doesn't really have any dependencies on X.509 features as it uses generalised IDs and the public_key structs that contain data extracted from X.509. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/asymmetric_keys.h | 2 ++ crypto/asymmetric_keys/asymmetric_type.c | 42 ++++++++++++++++---------------- crypto/asymmetric_keys/pkcs7_trust.c | 19 ++++++--------- crypto/asymmetric_keys/x509_public_key.c | 5 ++-- include/keys/asymmetric-type.h | 8 +++--- 5 files changed, 37 insertions(+), 39 deletions(-) commit 983023f28bff62b4462fd3575a86a8947ac592d8 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:25 2016 +0100 KEYS: Move x509_request_asymmetric_key() to asymmetric_type.c Move x509_request_asymmetric_key() to asymmetric_type.c so that it can be generalised. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/asymmetric_type.c | 89 ++++++++++++++++++++++++++++++++ crypto/asymmetric_keys/x509_public_key.c | 89 -------------------------------- include/crypto/public_key.h | 6 --- include/keys/asymmetric-type.h | 5 ++ 4 files changed, 94 insertions(+), 95 deletions(-) commit 5ac7eace2d00eab5ae0e9fdee63e38aee6001f7c Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:24 2016 +0100 KEYS: Add a facility to restrict new links into a keyring Add a facility whereby proposed new links to be added to a keyring can be vetted, permitting them to be rejected if necessary. This can be used to block public keys from which the signature cannot be verified or for which the signature verification fails. It could also be used to provide blacklisting. This affects operations like add_key(), KEYCTL_LINK and KEYCTL_INSTANTIATE. To this end: (1) A function pointer is added to the key struct that, if set, points to the vetting function. This is called as: int (*restrict_link)(struct key *keyring, const struct key_type *key_type, unsigned long key_flags, const union key_payload *key_payload), where 'keyring' will be the keyring being added to, key_type and key_payload will describe the key being added and key_flags[*] can be AND'ed with KEY_FLAG_TRUSTED. [*] This parameter will be removed in a later patch when KEY_FLAG_TRUSTED is removed. The function should return 0 to allow the link to take place or an error (typically -ENOKEY, -ENOPKG or -EKEYREJECTED) to reject the link. The pointer should not be set directly, but rather should be set through keyring_alloc(). Note that if called during add_key(), preparse is called before this method, but a key isn't actually allocated until after this function is called. (2) KEY_ALLOC_BYPASS_RESTRICTION is added. This can be passed to key_create_or_update() or key_instantiate_and_link() to bypass the restriction check. (3) KEY_FLAG_TRUSTED_ONLY is removed. The entire contents of a keyring with this restriction emplaced can be considered 'trustworthy' by virtue of being in the keyring when that keyring is consulted. (4) key_alloc() and keyring_alloc() take an extra argument that will be used to set restrict_link in the new key. This ensures that the pointer is set before the key is published, thus preventing a window of unrestrictedness. Normally this argument will be NULL. (5) As a temporary affair, keyring_restrict_trusted_only() is added. It should be passed to keyring_alloc() as the extra argument instead of setting KEY_FLAG_TRUSTED_ONLY on a keyring. This will be replaced in a later patch with functions that look in the appropriate places for authoritative keys. Signed-off-by: David Howells <dhowells@redhat.com> Reviewed-by: Mimi Zohar <zohar@linux.vnet.ibm.com> Documentation/security/keys.txt | 22 ++++++++++++ certs/system_keyring.c | 8 ++--- fs/cifs/cifsacl.c | 2 +- fs/nfs/nfs4idmap.c | 2 +- include/linux/key.h | 53 +++++++++++++++++++++++------ net/dns_resolver/dns_key.c | 2 +- net/rxrpc/ar-key.c | 4 +-- security/integrity/digsig.c | 7 ++-- security/integrity/ima/ima_mok.c | 8 ++--- security/keys/key.c | 43 +++++++++++++++++++---- security/keys/keyring.c | 73 ++++++++++++++++++++++++++++++++++++---- security/keys/persistent.c | 4 +-- security/keys/process_keys.c | 16 +++++---- security/keys/request_key.c | 4 +-- security/keys/request_key_auth.c | 2 +- 15 files changed, 198 insertions(+), 52 deletions(-) commit be2a266d2a163a332666f396ea128a6bcc6882f7 Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:16 2016 -0700 snic: add scsi host after determining max IOs. scsi host is added after negotiating the max number of IOs with Firmware. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic_main.c | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) commit 0da8519b2b1f08113cda65af88a4c9e35157dd53 Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:15 2016 -0700 snic: Fixing race in the hba reset and IO/TM completion While HBA reset is in progress, if IO/TM completion is received for the same IO then IO/TM completion path releases the driver private resources associated with IO. This fix prevents releasing the resources in IO and TM completion path if HBA reset is in progress. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic.h | 5 ++++- drivers/scsi/snic/snic_scsi.c | 11 +++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) commit c9747821f9bbff6c07fa36087b003d89d05245c8 Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:14 2016 -0700 snic: Fix for missing interrupts - On posting an IO to the firmware, adapter generates an interrupt. Due to hardware issues, sometimes the adapter fails to generate the interrupt. This behavior skips updating transmit queue- counters, which in turn causes the queue full condition. The fix addresses the queue full condition. - The fix also reserves a slot in transmit queue for hba reset. when queue full is observed during IO, there will always be room to post hba reset command. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic_fwint.h | 4 ++- drivers/scsi/snic/snic_io.c | 62 ++++++++++++++++++++++++++++++++++++++---- 2 files changed, 59 insertions(+), 7 deletions(-) commit 58fcf92050cdf7b499ba6169459ec43aa0838662 Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:13 2016 -0700 snic: target cleanup in driver unload path Fix deletes the snic targets synchronously prior to deletion of host. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic_disc.c | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) commit 6e0ae74b5ca2826fa6c86a157ed5227c766156b9 Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:12 2016 -0700 snic: Handling control path queue issues Fix handles control path queue issues such as queue full and sudden removal of hardware. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/vnic_dev.c | 44 ++++++++++++++++++++++++++++++-------------- 1 file changed, 30 insertions(+), 14 deletions(-) commit f352a0d5bafa62d1f0b044613ea42483a529f9df Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:11 2016 -0700 snic: LUN goes offline due to scsi cmd timeouts - LUN goes offline if there are at least two scsi command timeouts Completing the IO with scsi_done() fixes the issue. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic_scsi.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 3f5c11a463fd87b912f16976ff0ee3d6bbd1825e Author: Narsimhulu Musini <nmusini@cisco.com> Date: Thu Mar 17 00:51:10 2016 -0700 snic: Added additional stats Adding additional stats, and fixed logging messages. - Added qdepth change stats - Added separate isr stats for each type of interrupt - Fixed race in updating active IOs - Suppressed Link event message for DAS backend. Signed-off-by: Narsimhulu Musini <nmusini@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/snic/snic_ctl.c | 8 +++----- drivers/scsi/snic/snic_debugfs.c | 20 ++++++++++++++++---- drivers/scsi/snic/snic_isr.c | 6 +++--- drivers/scsi/snic/snic_main.c | 9 ++++++++- drivers/scsi/snic/snic_scsi.c | 27 ++++++++++++++++++++------- drivers/scsi/snic/snic_stats.h | 12 +++++++++--- 6 files changed, 59 insertions(+), 23 deletions(-) commit 45cc807291d5fde7a6691a06c0ca9f472fa3fb15 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:35 2016 -0700 lpfc: Update driver version to 11.1.0.0 Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_version.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 506115777af017bfc0968ee1c6aed024cdb6e43b Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:34 2016 -0700 lpfc: Update modified file copyrights Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc.h | 2 +- drivers/scsi/lpfc/lpfc_attr.c | 2 +- drivers/scsi/lpfc/lpfc_ct.c | 2 +- drivers/scsi/lpfc/lpfc_els.c | 2 +- drivers/scsi/lpfc/lpfc_hbadisc.c | 2 +- drivers/scsi/lpfc/lpfc_hw.h | 2 +- drivers/scsi/lpfc/lpfc_hw4.h | 2 +- drivers/scsi/lpfc/lpfc_init.c | 2 +- drivers/scsi/lpfc/lpfc_mbox.c | 2 +- drivers/scsi/lpfc/lpfc_nportdisc.c | 2 +- drivers/scsi/lpfc/lpfc_sli.c | 2 +- drivers/scsi/lpfc/lpfc_version.h | 4 ++-- drivers/scsi/lpfc/lpfc_vport.c | 2 +- 13 files changed, 14 insertions(+), 14 deletions(-) commit 8663cbbe3ba0d8142faec48bbab0dc3482e3007d Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:33 2016 -0700 lpfc: Fix interaction between fdmi_on and enable_SmartSAN Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc.h | 1 - drivers/scsi/lpfc/lpfc_attr.c | 23 +++++++---------------- drivers/scsi/lpfc/lpfc_els.c | 16 +++++++++------- drivers/scsi/lpfc/lpfc_init.c | 5 +++-- drivers/scsi/lpfc/lpfc_vport.c | 3 ++- 5 files changed, 21 insertions(+), 27 deletions(-) commit 56204984761d80b973a0a534c42566ad78303766 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:32 2016 -0700 lpfc: Add support for SmartSAN 2.0 Revise versions to reflect SmartSAN 2.0 support RDP updated to support additional descriptors: Credit descriptor Optical Element Data descriptors for Temperature, Voltage, Bias current, TX power and TX power. Optical Product Data descriptor. Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_ct.c | 4 +- drivers/scsi/lpfc/lpfc_els.c | 153 +++++++++++++++++++++++++++++++++++++++++++ drivers/scsi/lpfc/lpfc_hw.h | 73 +++++++++++++++++++-- drivers/scsi/lpfc/lpfc_hw4.h | 21 +++++- 4 files changed, 243 insertions(+), 8 deletions(-) commit 342b59caa66240b670285d519fdfe2c44289b516 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:31 2016 -0700 lpfc: Fix Device discovery failures during switch reboot test. When the switch is rebooted, the lpfc driver fails to log into the fabric, and Unexpected timeout message is seen. Fix: Do not issue RegVFI if the FLOGI was internally aborted. Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_els.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit b5c539583988b70bddea73f333c640fc93a62e88 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:30 2016 -0700 lpfc: Utilize embedded CDB logic to minimize IO latency Pass cmd iu payloads inline to adapter job structure rather than as separate dma buffers. Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc.h | 1 + drivers/scsi/lpfc/lpfc_attr.c | 1 - drivers/scsi/lpfc/lpfc_hw4.h | 6 ++ drivers/scsi/lpfc/lpfc_init.c | 20 ++++++- drivers/scsi/lpfc/lpfc_sli.c | 128 ++++++++++++++++++++++++++++++++++++------ 5 files changed, 136 insertions(+), 20 deletions(-) commit a6517db9006eb618dfde54f4bf6a9a8bc21e16e7 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:29 2016 -0700 lpfc: Fix crash when unregistering default rpi. The default rpi completion handler does back to back puts to force the removal of the ndlp. This ends up calling lpfc_unreg_rpi after the reference count is at 0. Fix: Check the reference count of the ndlp before getting the ref to make sure we are not getting a reference on a removed object. Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_hbadisc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ae09c765109293b600ba9169aa3d632e1ac1a843 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:28 2016 -0700 lpfc: Fix DMA faults observed upon plugging loopback connector Driver didn't program the REG_VFI mailbox correctly, giving the adapter bad addresses. Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_mbox.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit de96e9c5b82801ea17558c271730fdc2aa5e7e77 Author: James Smart <james.smart@broadcom.com> Date: Thu Mar 31 14:12:27 2016 -0700 lpfc: Correct LOGO handling during login After a link bounce, when a remote port issues a LOGO while a REGLOGIN is pending on that port, the driver does not clean up the ndlp structure. May result in stack traces in the console log. Fix: Clear the NLP_REG_LOGIN_SEND flag on the ndlp in the routine Signed-off-by: Dick Kennedy <dick.kennedy@avagotech.com> Signed-off-by: James Smart <james.smart@avagotech.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/lpfc/lpfc_nportdisc.c | 2 ++ drivers/scsi/lpfc/lpfc_sli.c | 1 + 2 files changed, 3 insertions(+) commit 4c1340af8854836796bc50555de446286dce4625 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 11:28:11 2016 -0700 scsi_transport_iscsi: Declare local symbols static Avoid that building with W=1 causes gcc to report warnings about symbols that have not been declared. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_transport_iscsi.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 7a15fdfab012dddc00ee2c859cf50669e3dae3df Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 11:27:47 2016 -0700 scsi_transport_iscsi: Unexport iscsi_is_flashnode_conn_dev() The output of "git grep -nHw iscsi_is_flashnode_conn_dev" shows that this function is only called from inside source file drivers/scsi/scsi_transport_iscsi.c. Hence unexport this function. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_transport_iscsi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 6fe3ed88fe12aeb4ace4877ce1457993ecc196c3 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 11:27:27 2016 -0700 scsi_transport_iscsi: Remove set-but-not-used variables Avoid that building with W=1 causes gcc to report warnings about set-but-not-used variables. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_transport_iscsi.c | 3 --- 1 file changed, 3 deletions(-) commit e9e410e8e8537b383b0325f3d03c522aba36fa0b Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 11:27:08 2016 -0700 libiscsi: Remove set-but-not-used variables Avoid that building with W=1 causes gcc to report warnings about set-but-not-used variables. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/libiscsi.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 3907adf67a1559d455f90b0de4c977dd456fe311 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 11:26:46 2016 -0700 libiscsi: Unexport iscsi_eh_target_reset() Running "git grep -nHw iscsi_eh_target_reset" shows that this function is only called from inside the drivers/scsi/libiscsi.c source file. Hence unexport this function. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/libiscsi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 5cfe8d5b4c6f359a23738bbdc54a6007c6d6bdb1 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Wed Mar 30 16:25:21 2016 -0700 qla2xxx: Indicate out-of-memory with -ENOMEM In the Linux kernel it is preferred to return a meaningful error code instead of -1. This patch does not change the behavior of the caller of qla82xx_pinit_from_rom(). Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Quinn Tran <quinn.tran@qlogic.com> Cc: Himanshu Madhani <himanshu.madhani@qlogic.com> Cc: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Acked-by: Quinn Tran <quinn.tran@qlogic.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/qla2xxx/qla_nx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 62055172fbcd6055a10b010c6be65088fd7046b3 Author: Bart Van Assche <bart.vanassche@sandisk.com> Date: Mon Mar 28 14:37:28 2016 -0700 scsi_transport_fc: Unexport scsi_is_fc_vport() Running the command "git grep -nHw scsi_is_fc_vport" shows that this function is only called from inside scsi_transport_fc.c. Hence unexport this function. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Cc: Hannes Reinecke <hare@suse.de> Cc: James Smart <james.smart@avagotech.com> Reviewed-by: Hannes Reinicke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_transport_fc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 1b6ac5e3ff354652ca59240e1ba8b2d22539df07 Author: Satish Kharat <satishkh@cisco.com> Date: Fri Mar 18 11:22:50 2016 -0700 fnic: Using rport->dd_data to check rport online instead of rport_lookup. When issuing I/O we check if rport is online through libfc rport_lookup() function which needs to be protected by mutex lock that cannot acquired in I/O context. The change is to use midlayer remote port s dd_data which is preserved until its devloss timeout and no protection is required. The the scsi_cmnd error code is expected to be in the left 16 bits of the result field. Changed to correct this. Fnic driver version changed from 1.6.0.20 to 1.6.0.21 Signed-off-by: Satish Kharat <satishkh@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Reviewed-by: Ewan Milne <emilne@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/fnic/fnic.h | 2 +- drivers/scsi/fnic/fnic_scsi.c | 20 +++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) commit a36f5dd07dd9098d43d1137ec7a2d6b92aa6d591 Author: Satish Kharat <satishkh@cisco.com> Date: Fri Mar 18 11:22:49 2016 -0700 fnic: Cleanup the I/O pending with fw and has timed out and is used to issue LUN reset In case of LUN reset, the device reset command is issued with one of the I/Os that has timed out on that LUN. The change is to also return this I/O with error status set to DID_RESET. In case when the reset is issued using the sg_reset tool (from sg3_utils) it is a new command and new_sc is set to 1. Fnic driver version changed from 1.6.0.19 to 1.6.0.20 [mkp: Fixed checkpatch warning] Signed-off-by: Satish Kharat <satishkh@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Reviewed-by: Ewan Milne <emilne@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/fnic/fnic.h | 2 +- drivers/scsi/fnic/fnic_scsi.c | 38 ++++++++++++++++++++++++++++---------- 2 files changed, 29 insertions(+), 11 deletions(-) commit 691a837c20df0f4eacd49596a4d57fc566a40545 Author: Satish Kharat <satishkh@cisco.com> Date: Fri Mar 18 11:22:48 2016 -0700 fnic: Fix to cleanup aborted IO to avoid device being offlined by mid-layer If an I/O times out and an abort issued by host, if the abort is successful we need to set scsi status as DID_ABORT. Or else the mid-layer error handler which looks for this error code, will offline the device. Also if the original I/O is not found in fnic firmware, we will consider the abort as successful. The start_time assignment is moved because of the new goto. Fnic driver version changed from 1.6.0.17a to 1.6.0.19, version 1.6.0.18 has been skipped [mkp: Fixed checkpatch warning] Signed-off-by: Satish Kharat <satishkh@cisco.com> Signed-off-by: Sesidhar Baddela <sebaddel@cisco.com> Reviewed-by: Ewan D. Milne <emilne@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/fnic/fnic.h | 2 +- drivers/scsi/fnic/fnic_scsi.c | 33 +++++++++++++++++++++++++++------ 2 files changed, 28 insertions(+), 7 deletions(-) commit 0008f1e7230b16989f72042e44bc078e44a69536 Author: Hannes Reinecke <hare@suse.de> Date: Thu Mar 24 17:23:56 2016 +0100 scsi-trace: define ZBC_IN and ZBC_OUT Add new trace functions for ZBC_IN and ZBC_OUT. Reviewed-by: Doug Gilbert <dgilbert@interlog.com> Reviewed-by: Ewan D. Milne <emilne@redhat.com> Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_trace.c | 70 +++++++++++++++++++++++++++++++++++++++++++++ include/scsi/scsi_proto.h | 9 ++++++ include/trace/events/scsi.h | 2 ++ 3 files changed, 81 insertions(+) commit 5141f16a8a944f14e4b0348e8cd9e4dd1acb1a86 Author: Hannes Reinecke <hare@suse.de> Date: Thu Mar 24 15:21:19 2016 +0100 scsi-trace: Decode MAINTENANCE_IN and MAINTENANCE_OUT commands Reviewed-by: Ewan D. Milne <emilne@redhat.com> Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/scsi_trace.c | 91 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) commit b3bc891eab51c98ec83458e2d7f0db629169ad80 Author: Hannes Reinecke <hare@suse.de> Date: Thu Mar 24 15:21:18 2016 +0100 scsi-trace: remove service action definitions scsi_opcode_name() is displaying the opcode, not the service action. Reviewed-by: Ewan D. Milne <emilne@redhat.com> Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> include/trace/events/scsi.h | 4 ---- 1 file changed, 4 deletions(-) commit 1d64508810d8d15867251c75a68d7250278ce2bd Author: Hannes Reinecke <hare@suse.de> Date: Thu Mar 17 08:39:45 2016 +0100 scsi: disable automatic target scan On larger installations it is useful to disable automatic LUN scanning, and only add the required LUNs via udev rules. This can speed up bootup dramatically. This patch introduces a new scan module parameter value 'manual', which works like 'none', but can be overridden by setting the 'rescan' value from scsi_scan_target to 'SCSI_SCAN_MANUAL'. And it updates all relevant callers to set the 'rescan' value to 'SCSI_SCAN_MANUAL' if invoked via the 'scan' option in sysfs. Signed-off-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Ewan D. Milne <emilne@redhat.com> Tested-by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/infiniband/ulp/srp/ib_srp.c | 2 +- drivers/message/fusion/mptspi.c | 2 +- drivers/s390/scsi/zfcp_unit.c | 3 ++- drivers/scsi/scsi_priv.h | 2 +- drivers/scsi/scsi_proc.c | 3 ++- drivers/scsi/scsi_scan.c | 44 +++++++++++++++++++++++++------------ drivers/scsi/scsi_sysfs.c | 3 ++- drivers/scsi/scsi_transport_fc.c | 6 +++-- drivers/scsi/scsi_transport_iscsi.c | 5 ++++- drivers/scsi/scsi_transport_sas.c | 7 +++--- drivers/scsi/snic/snic_disc.c | 2 +- include/scsi/scsi_device.h | 9 +++++++- 12 files changed, 60 insertions(+), 28 deletions(-) commit 216fad91387aab7c9e69fe0854d843f012968748 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:32 2016 +1100 ncr5380: Call complete_cmd() for disconnected commands on bus reset I'm told that some targets are liable to disconnect a REQUEST SENSE command. Theoretically this would cause a command undergoing autosense to be moved onto the disconnected list. The bus reset handler must call complete_cmd() for these commands, otherwise the hostdata->sensing pointer will not get cleared. That would cause autosense processing to stall and a timeout or an incorrect scsi_eh_restore_cmnd() would eventually follow. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reported-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3a0f64bfa90700c4fa9db0ed2d701300edd9a0b3 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:31 2016 +1100 mac_scsi: Fix pseudo DMA implementation Fix various issues: Comments about bus errors are incorrect. The PDMA asm must return the size of the memory access that faulted so the transfer count can be adjusted accordingly. A phase change may cause a bus error but should not be treated as failure. A bus error does not always imply a phase change and generally the transfer may continue. Scatter/gather doesn't seem to work with PDMA due to overruns. This is a pity because peak throughput seems to double with SG_ALL. Tested on a Mac LC III and a PowerBook 520. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.h | 2 + drivers/scsi/mac_scsi.c | 212 ++++++++++++++++++++++++++---------------------- 2 files changed, 119 insertions(+), 95 deletions(-) commit ded155b5e4e735bdd654306145dff6491ce85766 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:30 2016 +1100 atari_scsi: Allow can_queue to be increased for Falcon The benefit of limiting can_queue to 1 is that atari_scsi shares the ST DMA chip more fairly with other drivers (e.g. falcon-ide). Unfortunately, this can limit SCSI bus utilization. On systems without IDE, atari_scsi should issue SCSI commands whenever it can arbitrate for the bus. Make that possible by making can_queue configurable. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/atari_scsi.c | 83 +++++++++++++---------------------------------- 1 file changed, 22 insertions(+), 61 deletions(-) commit a5217a86369083af1f9630d17e9bb9e41ae7405a Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:29 2016 +1100 atari_scsi: Set a reasonable default for cmd_per_lun This setting does not need to be conditional on Atari ST or TT. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/atari_scsi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 9c41ab27e3fe0cfec16d3ac23f2067a516e337a4 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:28 2016 +1100 ncr5380: Update usage documentation Update kernel parameter documentation for atari_scsi, mac_scsi and g_NCR5380 drivers. Remove duplication. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Documentation/scsi/g_NCR5380.txt | 17 +++++++--------- Documentation/scsi/scsi-parameters.txt | 11 ++++++++--- drivers/scsi/g_NCR5380.c | 36 +--------------------------------- 3 files changed, 16 insertions(+), 48 deletions(-) commit a46865dcf1f7166808664ab096678f81d4fbb853 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:27 2016 +1100 ncr5380: Remove DONT_USE_INTR and AUTOPROBE_IRQ macros Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 12 +----------- drivers/scsi/NCR5380.h | 4 ---- drivers/scsi/arm/oak.c | 2 -- drivers/scsi/dmx3191d.c | 2 -- drivers/scsi/dtc.c | 12 +++--------- drivers/scsi/g_NCR5380.c | 2 -- drivers/scsi/pas16.c | 1 - drivers/scsi/t128.c | 1 - 8 files changed, 4 insertions(+), 32 deletions(-) commit f0ea73a4ef4ad86cc8430b6a0463a61b90472718 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:26 2016 +1100 ncr5380: Remove remaining register storage qualifiers Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 12866b99e57cf9eba809503c687fc1a25c529c4a Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:25 2016 +1100 ncr5380: Fix register decoding for debugging Decode all bits in the chip registers. They are all useful at times. Fix printk severity so that this output can be suppressed along with the other debugging output. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 42 +++++++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 17 deletions(-) commit 4712bd8d473da5e99d2328654bdba565de8b43ce Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:24 2016 +1100 dmx3191d: Drop max_sectors limit The dmx3191d driver is not capable of DMA or PDMA so all transfers use PIO. Now that large slow PIO transfers periodically stop and call cond_resched(), the max_sectors limit can go away. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/dmx3191d.c | 1 - 1 file changed, 1 deletion(-) commit ae5e33af42eb1f1262cfc8722072561b908bf914 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:23 2016 +1100 ncr5380: Reduce max_lun limit The driver has a limit of eight LUs because of the byte-sized bitfield that is used for busy flags. That means the maximum LUN is 7. The default is 8. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 2 ++ 1 file changed, 2 insertions(+) commit c4ec6f924f0682e1f40107204152e977d6b1bd07 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:22 2016 +1100 ncr5380: Remove disused atari_NCR5380.c core driver Now that atari_scsi and sun3_scsi have been converted to use the NCR5380.c core driver, remove atari_NCR5380.c. Also remove the last vestiges of its Tagged Command Queueing implementation from the wrapper drivers. The TCQ support in atari_NCR5380.c is abandoned by this patch. It is not merged into the remaining core driver because, 1) atari_scsi defines SUPPORT_TAGS but leaves FLAG_TAGGED_QUEUING disabled by default, which indicates that it is mostly undesirable. 2) I'm told that it doesn't work correctly when enabled. 3) The algorithm does not make use of block layer tags which it will have to do because scmd->tag is deprecated. 4) sun3_scsi doesn't define SUPPORT_TAGS at all, yet the the SUPPORT_TAGS macro interacts with the CONFIG_SUN3 macro in 'interesting' ways. 5) Compile-time configuration with macros like SUPPORT_TAGS caused the configuration space to explode, leading to untestable and unmaintainable code that is too hard to reason about. The merge_contiguous_buffers() code is also abandoned. This was unused by sun3_scsi. Only atari_scsi used it and then only on TT, because only TT supports scatter/gather. I suspect that the TT would work fine with ENABLE_CLUSTERING instead. If someone can benchmark the difference then perhaps the merge_contiguous_buffers() code can be be justified. Until then we are better off without the extra complexity. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 22 +- drivers/scsi/NCR5380.h | 19 - drivers/scsi/atari_NCR5380.c | 2632 ------------------------------------------ drivers/scsi/atari_scsi.c | 11 +- drivers/scsi/mac_scsi.c | 8 +- drivers/scsi/sun3_scsi.c | 11 - 6 files changed, 4 insertions(+), 2699 deletions(-) commit e9db3198e08b6a01e2847f732e595bb8e89153c1 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:21 2016 +1100 sun3_scsi: Adopt NCR5380.c core driver Add support for the custom Sun 3 DMA logic to the NCR5380.c core driver. This code is copied from atari_NCR5380.c. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 131 +++++++++++++++++++++++++++++++++++++++++++---- drivers/scsi/sun3_scsi.c | 8 ++- 2 files changed, 124 insertions(+), 15 deletions(-) commit 52d3e561cb13df431364a69e783469ba8a9ea8eb Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:20 2016 +1100 atari_scsi: Adopt NCR5380.c core driver Add support for the Atari ST DMA chip to the NCR5380.c core driver. This code is copied from atari_NCR5380.c. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 32 ++++++++++++++++++++++++++++++++ drivers/scsi/atari_scsi.c | 6 +++--- 2 files changed, 35 insertions(+), 3 deletions(-) commit 8053b0ee79c0129e827ce8f222398ff4b332dfd7 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:19 2016 +1100 ncr5380: Merge DMA implementation from atari_NCR5380 core driver Adopt the DMA implementation from atari_NCR5380.c. This means that atari_scsi and sun3_scsi can make use of the NCR5380.c core driver and the atari_NCR5380.c driver fork can be made redundant. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 170 +++++++++++++++++++++++++++++++++++--------- drivers/scsi/arm/cumana_1.c | 3 +- drivers/scsi/arm/oak.c | 3 +- drivers/scsi/dmx3191d.c | 1 + drivers/scsi/dtc.c | 2 +- drivers/scsi/dtc.h | 1 + drivers/scsi/g_NCR5380.c | 2 +- drivers/scsi/g_NCR5380.h | 1 + drivers/scsi/mac_scsi.c | 3 +- drivers/scsi/pas16.c | 2 +- drivers/scsi/pas16.h | 1 + drivers/scsi/t128.c | 2 +- drivers/scsi/t128.h | 1 + 13 files changed, 152 insertions(+), 40 deletions(-) commit 438af51c642926f1c1844846bee1c3fb568dcd64 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:18 2016 +1100 ncr5380: Adopt uniform DMA setup convention Standardize the DMA setup hooks so that the DMA implementation in atari_NCR5380.c can be reconciled with pseudo DMA implementation in NCR5380.c. Calls to NCR5380_dma_recv_setup() and NCR5380_dma_send_setup() return a negative value on failure, zero on PDMA transfer success and a positive byte count for DMA setup success. This convention is not entirely new, but is now applied consistently. Also remove a pointless Status Register access: the *phase assignment is redundant because after NCR5380_transfer_dma() returns control to NCR5380_information_transfer(), that routine then returns control to NCR5380_main(), which means *phase is dead. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 21 ++++++++++----------- drivers/scsi/arm/cumana_1.c | 10 ++++++++-- drivers/scsi/arm/oak.c | 4 ++-- drivers/scsi/atari_scsi.c | 3 --- 4 files changed, 20 insertions(+), 18 deletions(-) commit 6c4b88ca59ba1a68f707f19dba1744ed19e89fce Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:17 2016 +1100 ncr5380: Use DMA hooks for PDMA Those wrapper drivers which use DMA define the REAL_DMA macro and those which use pseudo DMA define PSEUDO_DMA. These macros need to be removed for a number of reasons, not least of which is to have drivers share more code. Redefine the PDMA send and receive hooks as DMA setup hooks, so that the DMA code can be shared by all 5380 wrapper drivers. This will help to reunify the forked core driver. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 10 ++-------- drivers/scsi/arm/cumana_1.c | 10 ++++++---- drivers/scsi/arm/oak.c | 10 ++++++---- drivers/scsi/dmx3191d.c | 4 ++-- drivers/scsi/dtc.c | 6 ++++-- drivers/scsi/dtc.h | 2 ++ drivers/scsi/g_NCR5380.c | 10 ++++++---- drivers/scsi/g_NCR5380.h | 4 ++-- drivers/scsi/mac_scsi.c | 5 ++--- drivers/scsi/pas16.c | 14 ++++++++------ drivers/scsi/pas16.h | 2 ++ drivers/scsi/t128.c | 12 ++++++------ drivers/scsi/t128.h | 2 ++ 13 files changed, 50 insertions(+), 41 deletions(-) commit e5d55d1abcef09f7440e6211d5bd673baf547630 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:16 2016 +1100 ncr5380: Remove BOARD_REQUIRES_NO_DELAY macro The io_recovery_delay macro is intended to insert a microsecond delay between the chip register accesses that begin a DMA operation. This is reportedly needed for some ISA boards. Reverse the sense of the macro test so that in the common case, where no delay is required, drivers need not define the macro. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 18 ++++++++---------- drivers/scsi/dtc.h | 2 ++ drivers/scsi/g_NCR5380.h | 2 ++ drivers/scsi/t128.h | 2 ++ 4 files changed, 14 insertions(+), 10 deletions(-) commit f825e40b235f4daf1c9017366809d34c7f5c8c7f Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:15 2016 +1100 ncr5380: Remove PSEUDO_DMA macro For those wrapper drivers which only implement Programmed IO, have NCR5380_dma_xfer_len() evaluate to zero. That allows PDMA to be easily disabled at run-time and so the PSEUDO_DMA macro is no longer needed. Also remove the spin counters used for debugging pseudo DMA drivers. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 32 +------------------------------- drivers/scsi/NCR5380.h | 4 ---- drivers/scsi/arm/cumana_1.c | 2 -- drivers/scsi/arm/oak.c | 3 +-- drivers/scsi/dmx3191d.c | 4 ++++ drivers/scsi/dtc.c | 7 ------- drivers/scsi/dtc.h | 2 -- drivers/scsi/g_NCR5380.c | 1 - drivers/scsi/g_NCR5380.h | 1 - drivers/scsi/mac_scsi.c | 10 ---------- drivers/scsi/pas16.c | 10 ---------- drivers/scsi/pas16.h | 2 -- drivers/scsi/t128.c | 4 ---- drivers/scsi/t128.h | 2 -- 14 files changed, 6 insertions(+), 78 deletions(-) commit 1bb4600245d4d40245dd505ca17528e0b9a9ba8c Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:14 2016 +1100 ncr5380: Disable the DMA errata workaround flag by default The only chip that needs the workarounds enabled is an early NMOS device. That means that the common case is to disable them. Unfortunately the sense of the flag is such that it has to be set for the common case. Rename the flag so that zero can be used to mean "no errata workarounds needed". This simplifies the code. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 14 +++++++------- drivers/scsi/NCR5380.h | 2 +- drivers/scsi/arm/cumana_1.c | 2 +- drivers/scsi/arm/oak.c | 2 +- drivers/scsi/dtc.c | 2 +- drivers/scsi/g_NCR5380.c | 8 +------- drivers/scsi/pas16.c | 2 +- drivers/scsi/t128.c | 2 +- 8 files changed, 14 insertions(+), 20 deletions(-) commit e63449c43a58fc185ff35ace6a842817f57ec6c8 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:13 2016 +1100 atari_NCR5380: Remove DMA_MIN_SIZE macro Only the atari_scsi and sun3_scsi drivers define DMA_MIN_SIZE. Both drivers also define NCR5380_dma_xfer_len, which means DMA_MIN_SIZE can be removed from the core driver. This removes another discrepancy between the two core drivers. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/atari_NCR5380.c | 16 ++++++++-------- drivers/scsi/atari_scsi.c | 6 +++++- drivers/scsi/sun3_scsi.c | 19 +++++++++---------- 3 files changed, 22 insertions(+), 19 deletions(-) commit e4dec6806aceca768b74c1c6402e6d31ecf3c960 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:12 2016 +1100 ncr5380: Remove REAL_DMA and REAL_DMA_POLL macros For the NCR5380.c core driver, these macros are never used. If REAL_DMA were to be defined, compilation would fail. For the atari_NCR5380.c core driver, REAL_DMA is always defined. Hence these macros are pointless. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 218 ++----------------------------------------- drivers/scsi/NCR5380.h | 112 ---------------------- drivers/scsi/atari_NCR5380.c | 62 ++---------- drivers/scsi/atari_scsi.c | 32 +------ drivers/scsi/sun3_scsi.c | 13 +-- 5 files changed, 22 insertions(+), 415 deletions(-) commit 7e9ec8d9cc18a85e8a4c28aef9136867b46aba42 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:11 2016 +1100 ncr5380: Remove FLAG_NO_PSEUDO_DMA where possible Drivers that define PSEUDO_DMA also define NCR5380_dma_xfer_len. The core driver must call NCR5380_dma_xfer_len which means FLAG_NO_PSEUDO_DMA can be eradicated from the core driver. dmx3191d doesn't define PSEUDO_DMA and has no use for FLAG_NO_PSEUDO_DMA, so remove it there also. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Michael Schmitz <schmitzmic@gmail.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/NCR5380.c | 3 +-- drivers/scsi/dmx3191d.c | 2 +- drivers/scsi/g_NCR5380.c | 7 ++++++- drivers/scsi/g_NCR5380.h | 2 +- drivers/scsi/mac_scsi.c | 15 ++++++++++++++- 5 files changed, 23 insertions(+), 6 deletions(-) commit 9d376402c80cfe2356d84577d366ca790e576bd9 Author: Finn Thain <fthain@telegraphics.com.au> Date: Wed Mar 23 21:10:10 2016 +1100 g_ncr5380: Remove CONFIG_SCSI_GENERIC_NCR53C400 This change brings a number of improvements: fewer macros, better test coverage, simpler code and sane Kconfig options. The downside is a small chance of incompatibility (which seems unavoidable). CONFIG_SCSI_GENERIC_NCR53C400 exists to enable or inhibit pseudo DMA transfers when the driver is used with 53C400-compatible cards. Thanks to Ondrej Zary's patches, PDMA now works which means it can be enabled unconditionally. Due to bad design, CONFIG_SCSI_GENERIC_NCR53C400 ties together unrelated functionality as it sets both PSEUDO_DMA and BIOSPARAM macros. This patch effectively enables PSEUDO_DMA and disables BIOSPARAM. The defconfigs and the Kconfig default leave CONFIG_SCSI_GENERIC_NCR53C400 undefined. Red Hat 9 and CentOS 2.1 were the same. This leaves both PSEUDO_DMA and BIOSPARAM disabled. The effect of this patch should be better performance from enabling PSEUDO_DMA. On the other hand, Debian 4 and SLES 10 had CONFIG_SCSI_GENERIC_NCR53C400 enabled, so both PSEUDO_DMA and BIOSPARAM were enabled. This patch might affect configurations like this by disabling BIOSPARAM. My best guess is that this could be a problem only in the vanishingly rare case that 1) the CHS values stored in the boot device partition table are wrong and 2) a 5380 card is in use (because PDMA on 53C400 used to be broken). Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/Kconfig | 11 ------- drivers/scsi/g_NCR5380.c | 75 +++++++++++++++--------------------------------- drivers/scsi/g_NCR5380.h | 16 ++--------- 3 files changed, 25 insertions(+), 77 deletions(-) commit e1f0bce3a0db95007fec756225801e50477f32fd Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Tue Mar 22 20:32:05 2016 +0100 scsi: reduce CONFIG_SCSI_CONSTANTS=y impact by 8k On 64 bit, struct error_info has 6 bytes of padding, which amounts to over 4k of wasted space in the additional[] array. We could easily get rid of that by instead using separate arrays for the codes and the pointers. However, we can do even better than that and save an additional 6 bytes per entry: In the table, just store the sizeof() the corresponding string literal. The cumulative sum of these is then the appropriate offset into additional_text, which is built from the concatenation (with '\0's inbetween) of the strings. $ scripts/bloat-o-meter /tmp/vmlinux vmlinux add/remove: 0/0 grow/shrink: 1/1 up/down: 24/-8488 (-8464) function old new delta scsi_extd_sense_format 136 160 +24 additional 11312 2824 -8488 The Kconfig help text used to say that CONFIG_SCSI_CONSTANTS=y costs around 75 KB, but that was a little exaggerated. The actual number was closer to 44K, and 36K with this patch. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Reviewed-by: Hannes Reinecke <hare@suse.com> Tested-by: Douglas Gilbert <dgilbert@interlog.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/Kconfig | 4 ++-- drivers/scsi/constants.c | 26 +++++++++++++++++++++----- 2 files changed, 23 insertions(+), 7 deletions(-) commit 9d99a2e33a02c3290cb53013150ee06a304588ae Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Tue Mar 22 20:32:04 2016 +0100 scsi: move Additional Sense Codes to separate file This is a purely mechanical move of the list of additional sense codes to a separate file, in preparation for reducing the impact of choosing CONFIG_SCSI_CONSTANTS=y by about 8k. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/constants.c | 830 +-------------------------------------------- drivers/scsi/sense_codes.h | 826 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 829 insertions(+), 827 deletions(-) commit 501280f5a043ec73979b94d4c23e7aae1727f32e Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Tue Mar 22 20:32:03 2016 +0100 scsi: make some Additional Sense strings more grep'able There's little point in breaking these strings over multiple lines. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> drivers/scsi/constants.c | 27 +++++++++------------------ 1 file changed, 9 insertions(+), 18 deletions(-) commit 35a6ae07c663499875309f18730f3440bb59f6fe Author: Adrian-Ken Rueegsegger <ken@codelabs.ch> Date: Wed Mar 23 11:34:29 2016 +0100 x86/PCI: Refine PCI support check in pcibios_init() Also consider raw_pci_ext_ops when validating if a system has PCI support. This leads to proper resource allocation via pcibios_resource_survey() in the case where PCI config space is exclusively accessed through MMCONFIG. Signed-off-by: Adrian-Ken Rueegsegger <ken@codelabs.ch> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> arch/x86/pci/common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d79852a792c971765dd7dfef9a8df883c63937f3 Author: Suman Anna <s-anna@ti.com> Date: Tue Apr 5 16:44:10 2016 -0500 ARM: dts: DRA7: Add timer12 node Add the DT node for Timer12 present on DRA7 family of SoCs. Timer12 is present in PD_WKUPAON power domain, and has the same capabilities as the other timers, except for the fact that it serves as a secure timer on HS devices and is clocked only from the secure 32K clock. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit 722326c49e0dc2f5c0d4ccd7b69174a63a903e7c Author: Suman Anna <s-anna@ti.com> Date: Tue Apr 5 16:44:09 2016 -0500 ARM: dts: DRA7: Enable Timers 13 through 16 The Timers 13 through 16 have been added previously in disabled state. These timers are common timers that are present on all DRA7 family of SoCs, so enable these devices by default like the rest of the DMTimers. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 4 ---- 1 file changed, 4 deletions(-) commit 296ea972dc96a78cc26027e879db91273c91f3c4 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:37 2016 +0200 ARM: dts: dra7: Add nodes for McASP1/2/4/5/6/7/8 Add nodes to represent all McASP ports in the dra7 family. For system consistency use the eDMA for audio operations. sDMA would be fine for 4/5/6/7/8 since their DAT port is not through L3 interconnect. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 114 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) commit e56700b87cb9fe480a4b20b16cf5eb63b49de1e8 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:35 2016 +0200 ARM: dts: dra7xx: Correct mcasp8_ahclkx_mux name rename the mcasp8_ahclk_mux to mcasp8_ahclkx_mux. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> [tony@atomide.com: updated for the unit offsets] Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7xx-clocks.dtsi | 2 +- drivers/clk/ti/clk-7xx.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 42b2274da00d924e04e39f1d5c259f0f4b113de9 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:34 2016 +0200 ARM: dts: am57xx-beagle-x15: Enable AFIFO use for McASP3 Since we switched to use eDMA we can now safely enable the FIFO in McASP. This will reduce the chance of McASP level under/overflow. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-beagle-x15.dts | 2 ++ 1 file changed, 2 insertions(+) commit e80ab5c972797d494d5305e48da6d122a74f747d Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:33 2016 +0200 ARM: dts: am57xx-beagle-x15: Move clkout2 source selection to codec node The assigned-clock* needs to be in the root of the device's node. If it is in the sub-node the CCF will ignore it. Since the clkout2 is used by the codec as MCLK, move the clock parent selection to that node. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am57xx-beagle-x15.dts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 6cfec12f25453ad498a7892764a4fe4fc9d3906e Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:32 2016 +0200 ARM: dts: dra72-evm: Enable AFIFO use for McASP3 Since we switched to use eDMA we can now safely enable the FIFO in McASP. This will reduce the chance of McASP level under/overflow. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra72-evm.dts | 2 ++ 1 file changed, 2 insertions(+) commit 27701fc2517e7653b756d524ec7428e88df0efa3 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:31 2016 +0200 ARM: dts: dra7-evm: Enable AFIFO use for McASP3 Since we switched to use eDMA we can now safely enable the FIFO in McASP. This will reduce the chance of McASP level under/overflow. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7-evm.dts | 2 ++ 1 file changed, 2 insertions(+) commit 0c92de2cd56d856af7ab3c82c8f46bb854b81c13 Author: Misael Lopez Cruz <misael.lopez@ti.com> Date: Mon Mar 7 17:17:30 2016 +0200 ARM: dts: dra7: Use eDMA and add DAT port address for McASP3 McASP3 does not support constant addressing mode on the DAT port, so increment transfers must be used instead. This restriction is also applicable for McASP1 and McASP2. This DMA addressing constraint poses a major problem for sDMA where constant addressing mode is used on the peripheral side. Unfortunately, using increment transfers in sDMA comes with important side effects. The addressing mode used in eDMA is INC, so the silicon limitation described above has no impact and the McASP3 DAT port can be safely added by switching to eDMA instead of sDMA. Signed-off-by: Misael Lopez Cruz <misael.lopez@ti.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 248948fbbd048d1ea75f9bb18979a6f33c4dcd5b Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:29 2016 +0200 ARM: dts: dra7: Enable eDMA DRA7 family has eDMA available along with the sDMA and in some cases it is better suited for servicing peripherals. Add the needed nodes for eDMA to be usable: edma-tpcc, edma-tptc0/1 and the edma-xbar. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 48 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) commit 3d2a58bc574cbd349edded07a5f8e9fe0619efb3 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Mon Mar 7 17:17:28 2016 +0200 ARM: dts: dra7: Move the sDMA crossbar node under l4_cfg/scm Move the sDMA xbar nodes under the L4 interconnect node. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit f470b19095c2cdf11710fde16c1ba7fc01b3c753 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Apr 5 15:00:01 2016 +0100 drm/i915/userptr: Store i915 backpointer for i915_mm_struct Since we only ever use the drm_i915_private from the stored i915_mm_struct->dev, save some electrons by storing the right backpointer. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Michał Winiarski <michal.winiarski@intel.com> Reviewed-by: Michał Winiarski <michal.winiarski@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459864801-28606-3-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_userptr.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 40313f0cd0b711a7a5905e5182422799e157d8aa Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Apr 5 15:00:00 2016 +0100 drm/i915/userptr: Hold mmref whilst calling get-user-pages Holding a reference to the containing task_struct is not sufficient to prevent the mm_struct from being reaped under memory pressure. If this happens whilst we are calling get_user_pages(), explosions erupt - sometimes an immediate GPF, sometimes page flag corruption. To prevent the target mm from being reaped as we are reading from it, acquire a reference before we begin. Testcase: igt/gem_shrink/*userptr Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Michał Winiarski <michal.winiarski@intel.com> Cc: stable@vger.kernel.org Reviewed-by: Michał Winiarski <michal.winiarski@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459864801-28606-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_userptr.c | 29 +++++++++++++++++------------ 1 file changed, 17 insertions(+), 12 deletions(-) commit 393afc2c3fda670ff392725ca618e956d625b964 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Apr 5 14:59:59 2016 +0100 drm/i915/userptr: Flush cancellations before mmu-notifier invalidate returns In order to ensure that all invalidations are completed before the operation returns to userspace (i.e. before the munmap() syscall returns) we need to wait upon the outstanding operations. We are allowed to block inside the invalidate_range_start callback, and as struct_mutex is the inner lock with mmap_sem we can wait upon the struct_mutex without provoking lockdep into warning about a deadlock. However, we don't actually want to wait upon outstanding rendering whilst holding the struct_mutex if we can help it otherwise we also block other processes from submitting work to the GPU. So first we do a wait without the lock and then when we reacquire the lock, we double check that everything is ready for removing the invalidated pages. Finally to wait upon the outstanding unpinning tasks, we create a private workqueue as a means to conveniently wait upon all at once. The drawback is that this workqueue is per-mm, so any threads concurrently invalidating objects will wait upon each other. The advantage of using the workqueue is that we can wait in parallel for completion of rendering and unpinning of several objects (of particular importance if the process terminates with a whole mm full of objects). v2: Apply a cup of tea to the changelog. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94699 Testcase: igt/gem_userptr_blits/sync-unmap-cycles Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Michał Winiarski <michal.winiarski@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459864801-28606-1-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_gem_userptr.c | 48 ++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) commit 7c3da7d0d4f3506ef70d9cf148a22400477854d0 Merge: c64a73d e0e4d82 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 11 15:34:42 2016 -0400 Merge branch 'rprpc-2nd-rewrite-part-1' David Howells says: ==================== RxRPC: 2nd rewrite part 1 Okay, I'm in the process of rewriting the RxRPC rewrite. The primary aim of this second rewrite is to strictly control the number of active connections we know about and to get rid of connections we don't need much more quickly. On top of this, there are fixes to the protocol handling which will all occur in later parts. Here's the first set of patches from the second go, aimed at net-next. These are all fixes and cleanups preparatory to the main event. Notable parts of this set include: (1) A fix for the AFS filesystem to wait for outstanding calls to complete before closing the RxRPC socket. (2) Differentiation of local and remote abort codes. At a future point userspace will get to see this via control message data on recvmsg(). (3) Absorb the rxkad module into the af_rxrpc module to prevent a dependency loop. (4) Create a null security module and unconditionalise calls into the security module that's in force (there will always be a security module applied to a connection, even if it's just the null one). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit e0e4d82f3be60cfe8b10304c6daf3ca5973ae9e3 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:58 2016 +0100 rxrpc: Create a null security type and get rid of conditional calls Create a null security type for security index 0 and get rid of all conditional calls to the security operations. We expect normally to be using security, so this should be of little negative impact. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/Makefile | 1 + net/rxrpc/ar-ack.c | 3 +- net/rxrpc/ar-connection.c | 9 +++-- net/rxrpc/ar-connevent.c | 11 ++----- net/rxrpc/ar-input.c | 2 +- net/rxrpc/ar-internal.h | 10 +++--- net/rxrpc/ar-output.c | 4 +-- net/rxrpc/ar-security.c | 43 ++---------------------- net/rxrpc/insecure.c | 83 +++++++++++++++++++++++++++++++++++++++++++++++ 9 files changed, 105 insertions(+), 61 deletions(-) commit 648af7fca15901740c7aaafd55904ebd54d01860 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:51 2016 +0100 rxrpc: Absorb the rxkad security module Absorb the rxkad security module into the af_rxrpc module so that there's only one module file. This avoids a circular dependency whereby rxkad pins af_rxrpc and cached connections pin rxkad but can't be manually evicted (they will expire eventually and cease pinning). With this change, af_rxrpc can just be unloaded, despite having cached connections. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/Kconfig | 2 +- net/rxrpc/Makefile | 3 +- net/rxrpc/af_rxrpc.c | 9 ++++ net/rxrpc/ar-internal.h | 21 +++++++-- net/rxrpc/ar-security.c | 123 +++++++++++++----------------------------------- net/rxrpc/rxkad.c | 61 ++++++++++-------------- 6 files changed, 85 insertions(+), 134 deletions(-) commit 6dd050f88d702e2718bd856ea014487563207756 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:44 2016 +0100 rxrpc: Don't assume transport address family and size when using it Don't assume transport address family and size when using the peer address to send a packet. Instead, use the start of the transport address rather than any particular element of the union and use the transport address length noted inside the sockaddr_rxrpc struct. This will be necessary when IPv6 support is introduced. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/ar-ack.c | 4 ++-- net/rxrpc/ar-connevent.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 843099cac0dbe421d7c3ea1f8662251fd7065731 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:37 2016 +0100 rxrpc: Don't pass gfp around in incoming call handling functions Don't pass gfp around in incoming call handling functions, but rather hard code it at the points where we actually need it since the value comes from within the rxrpc driver and is always the same. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/ar-accept.c | 4 ++-- net/rxrpc/ar-call.c | 7 +++---- net/rxrpc/ar-connection.c | 5 ++--- net/rxrpc/ar-internal.h | 5 ++--- 4 files changed, 9 insertions(+), 12 deletions(-) commit dc44b3a09aec9ac57c1e7410677c87c0e6453624 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:30 2016 +0100 rxrpc: Differentiate local and remote abort codes in structs In the rxrpc_connection and rxrpc_call structs, there's one field to hold the abort code, no matter whether that value was generated locally to be sent or was received from the peer via an abort packet. Split the abort code fields in two for cleanliness sake and add an error field to hold the Linux error number to the rxrpc_call struct too (sometimes this is generated in a context where we can't return it to userspace directly). Furthermore, add a skb mark to indicate a packet that caused a local abort to be generated so that recvmsg() can pick up the correct abort code. A future addition will need to be to indicate to userspace the difference between aborts via a control message. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> fs/afs/rxrpc.c | 14 +++++++++++--- include/net/af_rxrpc.h | 3 ++- net/rxrpc/ar-ack.c | 4 ++-- net/rxrpc/ar-call.c | 4 ++-- net/rxrpc/ar-connevent.c | 12 +++++++----- net/rxrpc/ar-input.c | 6 +++--- net/rxrpc/ar-internal.h | 10 +++++++--- net/rxrpc/ar-output.c | 2 +- net/rxrpc/ar-proc.c | 2 +- net/rxrpc/ar-recvmsg.c | 18 ++++++++++++++---- 10 files changed, 50 insertions(+), 25 deletions(-) commit 5b3e87f19e71b7a2f789c40de04704886932b5cf Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:23 2016 +0100 rxrpc: Static arrays of strings should be const char *const[] Static arrays of strings should be const char *const[]. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/rxrpc/packet.h | 2 -- net/rxrpc/ar-internal.h | 2 +- net/rxrpc/misc.c | 2 +- 3 files changed, 2 insertions(+), 4 deletions(-) commit 8e688d9c166671bb4a6977384de2fe7f46a31ba4 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:16 2016 +0100 rxrpc: Move some miscellaneous bits out into their own file Move some miscellaneous bits out into their own file to make it easier to split the call handling. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/af_rxrpc.h | 1 + net/rxrpc/Makefile | 3 +- net/rxrpc/ar-ack.c | 68 ------------------------------------- net/rxrpc/ar-input.c | 6 ---- net/rxrpc/ar-internal.h | 24 ++++++++----- net/rxrpc/misc.c | 89 +++++++++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 107 insertions(+), 84 deletions(-) commit 8f7e6e75d3074dd1856a6105f7511249ee2f2ffd Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:09 2016 +0100 rxrpc: Disable a debugging statement that has been left enabled. Disable a debugging statement that has been left enabled Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/ar-ack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2f02f7aea7b6c9a9312846c006e076ae6ad026a4 Author: David Howells <dhowells@redhat.com> Date: Thu Apr 7 17:23:03 2016 +0100 afs: Wait for outstanding async calls before closing rxrpc socket The afs filesystem needs to wait for any outstanding asynchronous calls (such as FS.GiveUpCallBacks cleaning up the callbacks lodged with a server) to complete before closing the AF_RXRPC socket when unloading the module. This may occur if the module is removed too quickly after unmounting all filesystems. This will produce an error report that looks like: AFS: Assertion failed 1 == 0 is false 0x1 == 0x0 is false ------------[ cut here ]------------ kernel BUG at ../fs/afs/rxrpc.c:135! ... RIP: 0010:[<ffffffffa004111c>] afs_close_socket+0xec/0x107 [kafs] ... Call Trace: [<ffffffffa004a160>] afs_exit+0x1f/0x57 [kafs] [<ffffffff810c30a0>] SyS_delete_module+0xec/0x17d [<ffffffff81610417>] entry_SYSCALL_64_fastpath+0x12/0x6b Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> fs/afs/rxrpc.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) commit 338c3149a221527e202ee26b1e35f76c965bb6c0 Author: Jacek Lawrynowicz <jacek.lawrynowicz@intel.com> Date: Thu Mar 3 15:38:02 2016 +0100 PCI: Add support for multiple DMA aliases Solve IOMMU support issues with PCIe non-transparent bridges that use Requester ID look-up tables (RID-LUT), e.g., the PEX8733. The NTB connects devices in two independent PCI domains. Devices separated by the NTB are not able to discover each other. A PCI packet being forwared from one domain to another has to have its RID modified so it appears on correct bus and completions are forwarded back to the original domain through the NTB. The RID is translated using a preprogrammed table (LUT) and the PCI packet propagates upstream away from the NTB. If the destination system has IOMMU enabled, the packet will be discarded because the new RID is unknown to the IOMMU. Adding a DMA alias for the new RID allows IOMMU to properly recognize the packet. Each device behind the NTB has a unique RID assigned in the RID-LUT. The current DMA alias implementation supports only a single alias, so it's not possible to support mutiple devices behind the NTB when IOMMU is enabled. Enable all possible aliases on a given bus (256) that are stored in a bitset. Alias devfn is directly translated to a bit number. The bitset is not allocated for devices that have no need for DMA aliases. More details can be found in the following article: http://www.plxtech.com/files/pdf/technical/expresslane/RTC_Enabling%20MulitHostSystemDesigns.pdf Signed-off-by: Jacek Lawrynowicz <jacek.lawrynowicz@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Alex Williamson <alex.williamson@redhat.com> Acked-by: David Woodhouse <David.Woodhouse@intel.com> Acked-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/iommu.c | 10 +++------- drivers/pci/pci.c | 19 +++++++++++++++++-- drivers/pci/probe.c | 1 + drivers/pci/search.c | 14 +++++++++----- include/linux/pci.h | 5 ++--- 5 files changed, 32 insertions(+), 17 deletions(-) commit 48c830809ce6e143781172c03a9794cb66802b31 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Wed Feb 24 13:43:54 2016 -0600 PCI: Move informational printk to pci_add_dma_alias() One of the quirks that adds DMA aliases logs an informational message in dmesg. Move that to pci_add_dma_alias() so all users log the message consistently. No functional change intended (except extra message). Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Alex Williamson <alex.williamson@redhat.com> drivers/pci/pci.c | 2 ++ drivers/pci/quirks.c | 6 +----- 2 files changed, 3 insertions(+), 5 deletions(-) commit c64a73d584cc344915baee1183c791c0d0c42d79 Merge: a6db449 4d0fc73 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 11 15:31:34 2016 -0400 Merge branch 'udp-pull' Willem de Bruijn says: ==================== net: fix udp pull header breakage Commit e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") modified udp receive processing to pull headers before enqueue and to not expect them on dequeue. The patch missed protocols on top of udp with in-kernel implementations that have their own skb_recv_datagram calls and dequeue logic. Modify these datapaths to also no longer expect a udp header at skb->data. Sunrpc and rxrpc are the only two protocols that call this function and contain references to udphr (some others, like tipc, are based on encap_rcv, which acts before enqueue, before the the header pull). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 4d0fc73ebe94ac984a187f21fbf4f3a1ac846f5a Author: Willem de Bruijn <willemb@google.com> Date: Thu Apr 7 11:44:59 2016 -0400 rxrpc: do not pull udp headers on receive Commit e6afc8ace6dd modified the udp receive path by pulling the udp header before queuing an skbuff onto the receive queue. Rxrpc also calls skb_recv_datagram to dequeue an skb from a udp socket. Modify this receive path to also no longer expect udp headers. Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Signed-off-by: Willem de Bruijn <willemb@google.com> Tested-by: Thierry Reding <treding@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/rxrpc/ar-input.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1da8c681d5c122afe9fbadc02e92a0f9e3f7af44 Author: Willem de Bruijn <willemb@google.com> Date: Thu Apr 7 11:44:58 2016 -0400 sunrpc: do not pull udp headers on receive Commit e6afc8ace6dd modified the udp receive path by pulling the udp header before queuing an skbuff onto the receive queue. Sunrpc also calls skb_recv_datagram to dequeue an skb from a udp socket. Modify this receive path to also no longer expect udp headers. Fixes: e6afc8ace6dd ("udp: remove headers from UDP packets before queueing") Reported-by: Franklin S Cooper Jr. <fcooper@ti.com> Signed-off-by: Willem de Bruijn <willemb@google.com> Tested-by: Thierry Reding <treding@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/sunrpc/socklib.c | 2 +- net/sunrpc/svcsock.c | 5 ++--- net/sunrpc/xprtsock.c | 5 ++--- 3 files changed, 5 insertions(+), 7 deletions(-) commit a6db4494d218c2e559173661ee972e048dc04fdd Author: David Ahern <dsa@cumulusnetworks.com> Date: Thu Apr 7 07:21:00 2016 -0700 net: ipv4: Consider failed nexthops in multipath routes Multipath route lookups should consider knowledge about next hops and not select a hop that is known to be failed. Example: [h2] [h3] 15.0.0.5 | | 3| 3| [SP1] [SP2]--+ 1 2 1 2 | | /-------------+ | | \ / | | X | | / \ | | / \---------------\ | 1 2 1 2 12.0.0.2 [TOR1] 3-----------------3 [TOR2] 12.0.0.3 4 4 \ / \ / \ / -------| |-----/ 1 2 [TOR3] 3| | [h1] 12.0.0.1 host h1 with IP 12.0.0.1 has 2 paths to host h3 at 15.0.0.5: root@h1:~# ip ro ls ... 12.0.0.0/24 dev swp1 proto kernel scope link src 12.0.0.1 15.0.0.0/16 nexthop via 12.0.0.2 dev swp1 weight 1 nexthop via 12.0.0.3 dev swp1 weight 1 ... If the link between tor3 and tor1 is down and the link between tor1 and tor2 then tor1 is effectively cut-off from h1. Yet the route lookups in h1 are alternating between the 2 routes: ping 15.0.0.5 gets one and ssh 15.0.0.5 gets the other. Connections that attempt to use the 12.0.0.2 nexthop fail since that neighbor is not reachable: root@h1:~# ip neigh show ... 12.0.0.3 dev swp1 lladdr 00:02:00:00:00:1b REACHABLE 12.0.0.2 dev swp1 FAILED ... The failed path can be avoided by considering known neighbor information when selecting next hops. If the neighbor lookup fails we have no knowledge about the nexthop, so give it a shot. If there is an entry then only select the nexthop if the state is sane. This is similar to what fib_detect_death does. To maintain backward compatibility use of the neighbor information is based on a new sysctl, fib_multipath_use_neigh. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Reviewed-by: Julian Anastasov <ja@ssi.bg> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/ip-sysctl.txt | 10 ++++++++++ include/net/netns/ipv4.h | 3 +++ net/ipv4/fib_semantics.c | 34 +++++++++++++++++++++++++++++----- net/ipv4/sysctl_net_ipv4.c | 11 +++++++++++ 4 files changed, 53 insertions(+), 5 deletions(-) commit 0b0e30c650e4345a50c417c397c7ecb63206a611 Merge: 61618ee 71a2cbb Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 11 15:12:00 2016 -0400 Merge branch 'cpsw-host_port' Grygorii Strashko says: ==================== drivers: net: cpsw: fix ale calls and drop host_port field from cpsw_priv This clean up series intended to: - fix port_mask parameters in ale calls and drop unnecessary shifts - drop host_port field from struct cpsw_priv ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 71a2cbb72a2bcbf3f1c1b14031870e37ad5e8109 Author: Grygorii Strashko <grygorii.strashko@ti.com> Date: Thu Apr 7 15:16:44 2016 +0300 drivers: net: cpsw: drop host_port field from struct cpsw_priv The host_port field is constantly assigned to 0 and this value has never changed (since time when cpsw driver was introduced. More over, if this field will be assigned to non 0 value it will break current driver functionality. Hence, there are no reasons to continue maintaining this host_port field and it can be removed, and the HOST_PORT_NUM and ALE_PORT_HOST defines can be used instead. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ti/cpsw.c | 30 ++++++++++++------------------ 1 file changed, 12 insertions(+), 18 deletions(-) commit 61f1cef90a18122ff9832a897dc75738c14e710a Author: Grygorii Strashko <grygorii.strashko@ti.com> Date: Thu Apr 7 15:16:43 2016 +0300 drivers: net: cpsw: fix port_mask parameters in ale calls ALE APIs expect to receive port masks as input values for arguments port_mask, untag, reg_mcast, unreg_mcast. But there are few places in code where port masks are passed left-shifted by cpsw_priv->host_port, like below: cpsw_ale_add_vlan(priv->ale, priv->data.default_vlan, ALE_ALL_PORTS << priv->host_port, ALE_ALL_PORTS << priv->host_port, 0, 0); and cpsw is still working just because priv->host_port == 0 and has never ever been changed. Hence, fix port_mask parameters in ALE APIs calls and drop "<< priv->host_port" from all places where it's used to shift valid port mask. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ti/cpsw.c | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) commit f0af9593372abfde34460aa1250e670cc535a7d8 Author: Bjorn Helgaas <bhelgaas@google.com> Date: Wed Feb 24 13:43:45 2016 -0600 PCI: Add pci_add_dma_alias() to abstract implementation Add a pci_add_dma_alias() interface to encapsulate the details of adding an alias. No functional change intended. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Alex Williamson <alex.williamson@redhat.com> drivers/pci/pci.c | 14 ++++++++++++++ drivers/pci/quirks.c | 19 +++++++------------ include/linux/pci.h | 1 + 3 files changed, 22 insertions(+), 12 deletions(-) commit 249ff32e1f8b6ffa92e1390e371702dd8633bcac Author: Dinh Nguyen <dinguyen@opensource.altera.com> Date: Wed Mar 23 15:40:54 2016 -0500 ARM: dts: socfpga: add reset control for USB Add the resets property for the 2 USB controllers. Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga.dtsi | 4 ++++ arch/arm/boot/dts/socfpga_arria10.dtsi | 4 ++++ 2 files changed, 8 insertions(+) commit a44a77115f76a7dd7de4396a7ba159eed1d8be21 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Thu Mar 31 18:48:07 2016 +0000 ARM: dts: socfpga: Add Altera Arria10 OCRAM EDAC devicetree entry Add the device tree entries needed to support the Altera On-Chip RAM EDAC on the Arria10 chip. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_arria10.dtsi | 5 +++++ 1 file changed, 5 insertions(+) commit 64ded09d293932621aad94dddf6d14eb0690246a Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 16:01:46 2016 +0000 ARM: dts: socfpga: Add Altera Arria10 L2 Cache EDAC devicetree entry Add the device tree entries needed to support the Altera L2 cache EDAC on the Arria10 chip. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_arria10.dtsi | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 95c16caaa8c1ffff2b58007da3989d7c470069eb Author: Marek Vasut <marex@denx.de> Date: Sat Mar 19 23:57:46 2016 +0000 ARM: dts: socfpga: Add support for HPS KEYs/SWs on SoCKit Add support for the keys and flip-switches on the SoCFPGA SoCkit board. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_cyclone5_sockit.dts | 62 ++++++++++++++++++++++++++- 1 file changed, 61 insertions(+), 1 deletion(-) commit 61618eeac3e6165684895481c4f58ea879c3d616 Author: Jiri Benc <jbenc@redhat.com> Date: Mon Apr 11 17:06:08 2016 +0200 vxlan: fix incorrect type The protocol is 16bit, not 32bit. Fixes: e1e5314de08ba ("vxlan: implement GPE") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e9f503254a5e0ea6b2b68b4c31491770b47a3ff0 Author: Marek Vasut <marex@denx.de> Date: Sat Mar 19 23:57:45 2016 +0000 ARM: dts: socfpga: Add support for HPS LEDs on SoCKit Add support for the blue LEDs on the SoCFPGA SoCkit board. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_cyclone5_sockit.dts | 32 +++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit 702744ce8b3ef369ed8f8e257cbee4db44beb415 Author: Marek Vasut <marex@denx.de> Date: Sat Mar 19 23:57:05 2016 +0000 ARM: dts: socfpga: Drop gmac0 from CV dtsi The socfpga_cyclone5.dtsi is included by all DTS files which describe boards using the Cyclone V SoC. The Cyclone V SoC has two ethernet controllers and different boards use none, one or both of them. The /soc/ethernet@ff702000/{} node in socfpga_cyclone5.dtsi unconditionaly enabled gmac0 interface, which is clearly wrong for those boards which use gmac1 interface instead. This patch removes the entire /soc/ethernet@ff702000/{} node from the socfpga_cyclone5.dtsi file. This is correct, since all of the board which include this file also have correct gmac0 or gmac1 node present in them. Minor correction had to be done to EBV SoCrates, which didn't define PHY mode explicitly, but inherited it from the socfpga_cyclone5.dtsi . Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_cyclone5.dtsi | 5 ----- arch/arm/boot/dts/socfpga_cyclone5_socrates.dts | 1 + 2 files changed, 1 insertion(+), 5 deletions(-) commit e0897ae3ec720b1653d4ff9aaf48b532c276ab63 Author: Vaishali Thakkar <vaishali.thakkar@oracle.com> Date: Mon Apr 11 15:58:17 2016 +0530 net: fjes: Use resource_size Use the function resource_size instead of explicit computation. Problem found using Coccinelle. Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/fjes/fjes_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ebaea3a7852e19bcffcbc8d7de055f2ebacda7ca Author: Marek Vasut <marex@denx.de> Date: Sat Mar 19 23:57:04 2016 +0000 ARM: dts: socfpga: Drop phy-addr OF property from CV dtsi The phy-addr property of stmmac is deprecated and the stmmac driver does not use it either. On the contrary, the driver will warn if this property is defined. Remove it. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Dinh Nguyen <dinguyen@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_cyclone5.dtsi | 1 - 1 file changed, 1 deletion(-) commit 3484f44c0873652ad16a69a0f20088343a281982 Merge: bddf590 8cbde11 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 11 14:58:45 2016 -0400 Merge branch 'bnxt_en-next' Michael Chan says: ==================== bnxt_en: Update for net-next Misc. changes for link speed and VF MAC address change. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8cbde1175e3c8565edbb777cd09cbfdb93c78397 Author: Michael Chan <michael.chan@broadcom.com> Date: Mon Apr 11 04:11:14 2016 -0400 bnxt_en: Add async event handling for speed config changes. On some dual port cards, link speeds on both ports have to be compatible. Firmware will inform the driver when a certain speed is no longer supported if the other port has linked up at a certain speed. Add logic to handle this event by logging a message and getting the updated list of supported speeds. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 84c33dd342ad596a271a61da0119bf34e80bb1c5 Author: Michael Chan <michael.chan@broadcom.com> Date: Mon Apr 11 04:11:13 2016 -0400 bnxt_en: Call firmware to approve VF MAC address change. Some hypervisors (e.g. ESX) require the VF MAC address to be forwarded to the PF for approval. In Linux PF, the call is not forwarded and the firmware will simply check and approve the MAC address if the PF has not previously administered a valid MAC address for this VF. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 7 +++--- drivers/net/ethernet/broadcom/bnxt/bnxt_sriov.c | 30 +++++++++++++++++++++++++ drivers/net/ethernet/broadcom/bnxt/bnxt_sriov.h | 1 + 3 files changed, 34 insertions(+), 4 deletions(-) commit 33f7d55f07ab964055d73d38774346f8d4821f00 Author: Michael Chan <michael.chan@broadcom.com> Date: Mon Apr 11 04:11:12 2016 -0400 bnxt_en: Shutdown link when device is closed. Let firmware know that the driver is giving up control of the link so that it can be shutdown if no management firmware is running. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 03efbec03198a0f505c2a6c93268c3c5df321c90 Author: Michael Chan <michael.chan@broadcom.com> Date: Mon Apr 11 04:11:11 2016 -0400 bnxt_en: Disallow forced speed for 10GBaseT devices. 10GBaseT devices must autonegotiate to determine master/slave clocking. Disallow forced speed in ethtool .set_settings() for these devices. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 1 + drivers/net/ethernet/broadcom/bnxt/bnxt.h | 1 + drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 8 ++++++++ 3 files changed, 10 insertions(+) commit a1e89630ea8b3797f8ecbdc95e210e29ea461bfa Author: Graham Moore <grmoore@opensource.altera.com> Date: Tue Mar 8 17:02:50 2016 +0000 ARM: dts: socfpga: Add missing clock and interrupt fields for Arria10 DMA The PL330 DMA driver will not load on Arria10 without devicetree entries for clocks and clock_names. This patch adds those entries. It also adds the ninth interrupt, which is required for error detection. Signed-off-by: Graham Moore <grmoore@opensource.altera.com> Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_arria10.dtsi | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit ca6fd1c9cf0320946f3e303dba8e8d19fa6c6659 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:13 2016 +0300 ARM: dts: omap5: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for OMAP5 clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap54xx-clocks.dtsi | 260 ++++++++++++++++----------------- 1 file changed, 130 insertions(+), 130 deletions(-) commit ca8a3d4edcc37d06a3d71645e80923dd9d3c44eb Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:12 2016 +0300 ARM: dts: dra7: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for DRA7 clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7xx-clocks.dtsi | 376 +++++++++++++++++------------------ 1 file changed, 188 insertions(+), 188 deletions(-) commit 5c440a775e5cb5e5de815771589b252a2dd08e70 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:11 2016 +0300 ARM: dts: dm81x: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for DM81x clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dm814x-clocks.dtsi | 10 ++++----- arch/arm/boot/dts/dm816x-clocks.dtsi | 42 ++++++++++++++++++------------------ 2 files changed, 26 insertions(+), 26 deletions(-) commit c567048194b3bb65b9e798cadb9b794e6dc66e05 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:10 2016 +0300 ARM: dts: am43xx: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for AM43xx clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am43xx-clocks.dtsi | 116 +++++++++++++++++------------------ 1 file changed, 58 insertions(+), 58 deletions(-) commit b524cab33198ea3d7a6deadf44ff93e8b195df15 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:09 2016 +0300 ARM: dts: am33xx: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for AM33xx clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am33xx-clocks.dtsi | 90 ++++++++++++++++++------------------ 1 file changed, 45 insertions(+), 45 deletions(-) commit 8f952371accb46d38287956c0f348f205bb7963a Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:08 2016 +0300 ARM: dts: omap4: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for OMAP4 clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap443x-clocks.dtsi | 2 +- arch/arm/boot/dts/omap446x-clocks.dtsi | 4 +- arch/arm/boot/dts/omap44xx-clocks.dtsi | 316 ++++++++++++++++----------------- 3 files changed, 161 insertions(+), 161 deletions(-) commit 1bb5fcb1e2456dc9ae9ffbf82142b3052675b0e9 Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:07 2016 +0300 ARM: dts: omap2: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for OMAP2 clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap2420-clocks.dtsi | 38 +++--- arch/arm/boot/dts/omap2430-clocks.dtsi | 58 ++++----- arch/arm/boot/dts/omap24xx-clocks.dtsi | 228 ++++++++++++++++----------------- 3 files changed, 162 insertions(+), 162 deletions(-) commit b5b5340d6ecc37db230280241cc776bb9556c8df Author: Tero Kristo <t-kristo@ti.com> Date: Mon Apr 4 18:16:06 2016 +0300 ARM: dts: omap3: fix clock node definitions to avoid build warnings Upcoming change to DT compiler is going to complain about nodes which have a reg property, but have not defined the address in their name. This patch fixes following type of warnings for OMAP3 clock nodes: Warning (unit_address_vs_reg): Node /ocp/cm@48004000/clocks/dpll3_m2_ck has a reg or ranges property, but no unit name Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am35xx-clocks.dtsi | 20 +- arch/arm/boot/dts/omap3430es1-clocks.dtsi | 30 +-- arch/arm/boot/dts/omap34xx-omap36xx-clocks.dtsi | 44 ++-- .../omap36xx-am35xx-omap3430es2plus-clocks.dtsi | 32 +-- arch/arm/boot/dts/omap36xx-clocks.dtsi | 14 +- .../boot/dts/omap36xx-omap3430es2plus-clocks.dtsi | 14 +- arch/arm/boot/dts/omap3xxx-clocks.dtsi | 276 ++++++++++----------- 7 files changed, 215 insertions(+), 215 deletions(-) commit 6905e94d4a100c6883849408e8e13acea98f5563 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 1 16:20:22 2016 -0400 ARM: dts: omap: add missing unit names to bandgap nodes This patch fixes the following DTC warnings: "bandgap has a reg or ranges property, but no unit name" Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap34xx.dtsi | 2 +- arch/arm/boot/dts/omap36xx.dtsi | 2 +- arch/arm/boot/dts/omap443x.dtsi | 2 +- arch/arm/boot/dts/omap4460.dtsi | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) commit 4e8603eff519a946d6596ab92c380654cf72fedf Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 1 16:20:21 2016 -0400 ARM: dts: omap: remove unneeded unit name for sound nodes This patch fixes the following DTC warning: "sound@0 has a unit name, but no reg property" Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/am437x-gp-evm.dts | 2 +- arch/arm/boot/dts/am43x-epos-evm.dts | 2 +- arch/arm/boot/dts/am57xx-beagle-x15.dts | 2 +- arch/arm/boot/dts/am57xx-cl-som-am57x.dts | 2 +- arch/arm/boot/dts/dra7-evm.dts | 2 +- arch/arm/boot/dts/dra72-evm.dts | 2 +- arch/arm/boot/dts/omap4-var-som-om44.dtsi | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) commit 2995a9e7094716bba08ca05f7a58e56d03ea4f9a Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 1 16:20:20 2016 -0400 ARM: dts: omap3: add missing unit name to PMU node This patch fixes the following DTC warnings: "pmu has a reg or ranges property, but no unit name" Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap3.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e72c378b8be62e072c067bfcb203dfd20530cd70 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 1 16:20:19 2016 -0400 ARM: dts: n8x0: remove unneeded unit name for i2c node This patch fixes the following DTC warnings: "i2c@0 has a unit name, but no reg property" Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/omap2420-n8x0-common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 308cfdaf9a9120b88c5f523c755daf464959bf16 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Fri Apr 1 16:20:18 2016 -0400 ARM: dts: omap: add missing unit name to pbias regulator nodes This patch fixes the following DTC warnings: "pbias_regulator has a reg or ranges property, but no unit name" Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Tony Lindgren <tony@atomide.com> arch/arm/boot/dts/dra7.dtsi | 2 +- arch/arm/boot/dts/omap2430.dtsi | 2 +- arch/arm/boot/dts/omap3.dtsi | 2 +- arch/arm/boot/dts/omap4.dtsi | 2 +- arch/arm/boot/dts/omap5.dtsi | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) commit faf68cdfdf6c9f0999686802ad066b1378b89413 Author: Dinh Nguyen <dinguyen@opensource.altera.com> Date: Tue Jan 5 14:59:38 2016 -0600 ARM: dts: socfpga: add the clk-phase property for sd/mmc clock The CIU clock for the SD/MMC should be the sdmmc_clk and not the sdmmc_free_clk. Also, add the correct phase shift the sdmmc_clk. Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_arria10.dtsi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit d07e187cf0621891514a47f316597fea8963e5a7 Author: Dinh Nguyen <dinguyen@opensource.altera.com> Date: Tue Jan 5 14:18:16 2016 -0600 ARM: dts: socfpga: add cap-sd-highspeed for SD/MMC node Enable SD highspeed support for the SoCFPGA Arria10 devkit. Signed-off-by: Dinh Nguyen <dinguyen@opensource.altera.com> arch/arm/boot/dts/socfpga_arria10_socdk_sdmmc.dts | 1 + 1 file changed, 1 insertion(+) commit ba3150ac3876acd082307f142597d3482107facc Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon Apr 11 20:20:18 2016 +0200 drm/i915: Update DRIVER_DATE to 20160411 Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8259542348d93da6a04eed979047b1fd1ca72abe Author: Lee, Chun-Yi <joeyli.kernel@gmail.com> Date: Thu Jan 21 20:32:10 2016 +0800 libnvdimm, nfit: Use ACPI_SIG_NFIT instead of hard coded string It's minor but that's still better to use ACPI_SIG_NFIT instead of hard coded string. Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Len Brown <lenb@kernel.org> Signed-off-by: Lee, Chun-Yi <jlee@suse.com> Acked-by: Ross Zwisler <ross.zwisler@linux.intel.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit baa51277cf5dc844089ea2f6e0f78b1c5ca665d8 Author: Dan Williams <dan.j.williams@intel.com> Date: Tue Apr 5 17:40:52 2016 -0700 libnvdimm, test: add mock SMART data payload Provide simulated SMART data to enable the ndctl implementation of SMART data retrieval and parsing. The payload is defined here, "Section 4.1 SMART and Health Info (Function Index 1)": http://pmem.io/documents/NVDIMM_DSM_Interface_Example.pdf Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/nvdimm/bus.c | 3 +++ include/uapi/linux/ndctl.h | 36 +++++++++++++++++++++++++++++++- tools/testing/nvdimm/test/nfit.c | 44 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 82 insertions(+), 1 deletion(-) commit 8cc6ddfcafbb7e32ff025f7d9551ecf9649c12cd Author: Dan Williams <dan.j.williams@intel.com> Date: Tue Apr 5 15:26:50 2016 -0700 libnvdimm, nfit: report multiple interface codes per-dimm Starting with ACPI 6.1 an NFIT table will report multiple 'NVDIMM Control Region Structure' instances per-dimm, one for each supported format interface. Report that code in the following format in sysfs: nmemX/nfit/formats nmemX/nfit/format nmemX/nfit/format1 nmemX/nfit/format2 ... nmemX/nfit/formatN Where format2 - formatN are theoretical as there are no known DIMMs with support for more than two interface formats. This layout is compatible with existing libndctl binaries that only expect one code per-dimm as they will ignore nmemX/nfit/formats and nmemX/nfit/formatN. Signed-off-by: Dan Williams <dan.j.williams@intel.com> drivers/acpi/nfit.c | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++--- drivers/acpi/nfit.h | 1 + 2 files changed, 70 insertions(+), 3 deletions(-) commit 39702853197b191bda32315260255053aa3e57f7 Merge: fb8621d bf16200 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon Apr 11 19:21:06 2016 +0200 Merge tag 'v4.6-rc3' into drm-intel-next-queued Linux 4.6-rc3 Backmerge requested by Chris Wilson to make his patches apply cleanly. Tiny conflict in vmalloc.c with the (properly acked and all) patch in drm-intel-next: commit 4da56b99d99e5a7df2b7f11e87bfea935f909732 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Apr 4 14:46:42 2016 +0100 mm/vmap: Add a notifier for when we run out of vmap address space and Linus' tree. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> commit a51a79d50ebc21d47f73f1e7f695ef2f86ef3417 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:45:01 2016 +0200 i2c: st: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-st.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 5c1274fab5c10aa193f5740dd76780010bda77d7 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:45:00 2016 +0200 i2c: sirf: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-sirf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 3f8a57bb6d5fb37c0b02d091184b01eab9dcf43a Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:59 2016 +0200 i2c: sh_mobile: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-sh_mobile.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit e3c60f3d2d8bc803806262ecb4ec5b2723bcd606 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:58 2016 +0200 i2c: qup: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-qup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7756e1ee78b37ddb98bfcc815002cb885a0449c8 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:57 2016 +0200 i2c: powermac: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-powermac.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 380a295c87a6423390898b98e388e1b0a399bb08 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:56 2016 +0200 i2c: ocores: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-ocores.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 0d47ce210a5d6733d7bc8cb07f158908bb224629 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:55 2016 +0200 i2c: mt65xx: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-mt65xx.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 043f47f49b3646beab84019eefb2c336be87db5f Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:54 2016 +0200 i2c: lpc2k: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-lpc2k.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 515e240bb54c53195fe0c7a9bad92ffb23e8bc54 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:53 2016 +0200 i2c: iop3xx: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-iop3xx.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 9c01cae8dd841a3d7b2f7763affd4e3fd16cebcf Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:52 2016 +0200 i2c: img-scb: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-img-scb.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 73fef2196dd654ffda44486842d336c851d9294d Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:51 2016 +0200 i2c: ibm_iic: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-ibm_iic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 949d0c5b72b94fb58a1d2c48c223658af24f58ee Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:50 2016 +0200 i2c: cpm: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-cpm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit fa5ce47a994867e79bd595ec2eef5178834c2570 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:49 2016 +0200 i2c: brcmstb: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-brcmstb.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 191d738d847e63b24da7cacbdfb179e5b5a9145f Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:48 2016 +0200 i2c: bcm-kona: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-bcm-kona.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 32822bff880bd9c3b55145e258d03dc671f0d2ea Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:47 2016 +0200 i2c: bcm-iproc: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/busses/i2c-bcm-iproc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 041edda8757b5567b4d417e0cc9ade504dd4292f Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:46 2016 +0200 i2c: core: use new 8 bit address helper function Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> drivers/i2c/i2c-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a16d6ebca6efb73f6402f36e5aebf84f61721856 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:45 2016 +0200 i2c: introduce helper function to get 8 bit address from a message Drivers do this in various ways, let's use one standard way of doing it. Note: I2C_M_RD is bit 0, so the code could be simplified. To be extremly robust and to advertise good coding practices, I still use the ternary operator and let the compilers do the optimizing job. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> include/linux/i2c.h | 5 +++++ 1 file changed, 5 insertions(+) commit e28b124564e648d933337a0708dae1323c518af7 Author: Wolfram Sang <wsa@the-dreams.de> Date: Sun Apr 3 20:44:44 2016 +0200 i2c: guarantee that I2C_M_RD will be 0x0001 forever There is code out there in user space and kernel space which relies on I2C_M_RD being bit 0 to simplify their bit operations. Add a comment to make sure this will never break. Do proper sorting of the defines while we are here. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> include/uapi/linux/i2c.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit 5f47992491ffe2d5b2b4ea3556bc0f3c0ec9bc8b Merge: 148e45d bf16200 Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon Apr 11 09:30:50 2016 -0700 Merge 4.6-rc3 into staging-next This resolves a lot of merge issues with PAGE_CACHE_* changes, and an iio driver merge issue. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> commit fb8621d3bee88badeb25dccce0fb59ad145dba9e Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:14 2016 +0100 drm/i915: Avoid allocating a vmap arena for a single page If we want a contiguous mapping of a single page sized object, we can forgo using vmap() and just use a regular kmap(). Note that this is only suitable if the desired pgprot_t is compatible. v2: Use is_vmalloc_addr() Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Cc: Dave Gordon <david.s.gordon@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-7-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> drivers/gpu/drm/i915/i915_gem.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) commit f2a85e1975d80d1b535b4c21517ed15226b96c87 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:13 2016 +0100 drm,i915: Introduce drm_malloc_gfp() I have instances where I want to use drm_malloc_ab() but with a custom gfp mask. And with those, where I want a temporary allocation, I want to try a high-order kmalloc() before using a vmalloc(). So refactor my usage into drm_malloc_gfp(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: dri-devel@lists.freedesktop.org Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Acked-by: Dave Airlie <airlied@redhat.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-6-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem.c | 4 +--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 8 +++----- drivers/gpu/drm/i915/i915_gem_gtt.c | 5 +++-- drivers/gpu/drm/i915/i915_gem_userptr.c | 16 +++++----------- include/drm/drm_mem_util.h | 19 +++++++++++++++++++ 5 files changed, 31 insertions(+), 21 deletions(-) commit eae2c43b1233f81f594d1eb5fd06b897bb18b629 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:12 2016 +0100 drm/i915/shrinker: Restrict vmap purge to objects with vmaps When called because we have run out of vmap address space, we only need to recover objects that have vmappings and not all. v2: Start using is_vmalloc_addr() Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-5-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gem_shrinker.c | 10 +++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) commit 0a798eb92e6dcc1cba45d13d7b75a523e5d0fc4c Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:11 2016 +0100 drm/i915: Refactor duplicate object vmap functions We now have two implementations for vmapping a whole object, one for dma-buf and one for the ringbuffer. If we couple the mapping into the obj->pages lifetime, then we can reuse an obj->mapping for both and at the same time couple it into the shrinker. There is a third vmapping routine in the cmdparser that maps only a range within the object, for the time being that is left alone, but will eventually use these routines in order to cache the mapping between invocations. v2: Mark the failable kmalloc() as __GFP_NOWARN (vsyrjala) v3: Call unpin_vmap from the right dmabuf unmapper v4: Rename vmap to map as we don't wish to imply the type of mapping involved, just that it contiguously maps the object into kernel space. Add kerneldoc and lockdep annotations Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Cc: Dave Gordon <david.s.gordon@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-4-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> drivers/gpu/drm/i915/i915_drv.h | 37 ++++++++++++++++++++++--- drivers/gpu/drm/i915/i915_gem.c | 44 +++++++++++++++++++++++++++++ drivers/gpu/drm/i915/i915_gem_dmabuf.c | 49 ++++----------------------------- drivers/gpu/drm/i915/intel_ringbuffer.c | 26 ++--------------- 4 files changed, 84 insertions(+), 72 deletions(-) commit d2cad5358ba7c6d94343837cd4d367fb6ce2a33c Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:10 2016 +0100 drm/i915: Consolidate common error handling in intel_pin_and_map_ringbuffer_obj After we pin the ringbuffer into the GGTT, all error paths need to unpin it again. Move this common step into one block, and make the unable to iomap error code consistent (i.e. treat it as out of memory to avoid confusing it with a invalid argument). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-3-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) commit 6d19245f187b28541ea9b077f88d8367054823cb Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Apr 8 12:11:09 2016 +0100 drm/i915/dmabuf: Tighten struct_mutex for unmap_dma_buf We only need the struct_mutex to manipulate the pages_pin_count on the object, we do not need to hold our BKL when freeing the exported scatterlist. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460113874-17366-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_dmabuf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit bddf59046d804638d998f9015246d4990f1cab09 Merge: 4923ec0 20ac1b3 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 11 11:58:12 2016 -0400 Merge tag 'wireless-drivers-next-for-davem-2016-04-11' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== wireless-drivers patches for 4.7 Major changes: iwlwifi * support for Link Quality measurement * more work 9000 devices and MSIx * continuation of the Dynamic Queue Allocation work * make the paging less memory hungry * 9000 new Rx path * removal of IWLWIFI_UAPSD Kconfig option ath10k * implement push-pull tx model using mac80211 software queuing support * enable scan in AP mode (NL80211_FEATURE_AP_SCAN) wil6210 * add basic PBSS (Personal Basic Service Set) support * add initial P2P support * add oob_mode module parameter ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 162c5a368fb788f040e9c51a1251ac36d80bff32 Author: Thierry Reding <treding@nvidia.com> Date: Thu Apr 7 16:22:39 2016 +0200 regulator: as3722: Constify regulator ops A const pointer to regulator ops is stored in regulator descriptors. The operations never need to be modified, so define them as const as a hint to the compiler that they can go into .rodata. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/as3722-regulator.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 40a865500c4d408b552cf5899bf091ac72e32bf8 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Apr 7 16:22:38 2016 +0200 regulator: as3722: Add bypass support for LDO6 LD06 on the AS3722 power management IC supports a bypass mode. Bypass is enabled for the LDO by writing the value 0x3F to the voltage select field in the control register for the LDO. Note that this is the same register and field that is used to select the voltage as well for the LDO. Add support for bypass on LDO6 by specifying the various bypass parameters for regulator and adding new function pointer tables for the LDO. Note that the bypass OFF value is the same as the ON value simply because there is no actual OFF value and bypass will be disabled when a new voltage is written to the VSEL field. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/as3722-regulator.c | 43 ++++++++++++++++++++++++++++++++++++ include/linux/mfd/as3722.h | 1 + 2 files changed, 44 insertions(+) commit 69e29bd1a5564d1cc43cd254ecdd1fbf6bcb8de2 Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue Feb 9 13:52:00 2016 +0000 arm64: tegra: Add stdout-path for various boards For Tegra boards, the device-tree alias serial0 is used for the console and so add the stdout-path information so that the console no longer needs to be passed via the kernel boot parameters. For tegra132-norrin the alias serial0 is not defined and so add this. This has been tested on tegra132-norrin and tegra210-p2371-0000. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra132-norrin.dts | 5 ++++- arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 4 ++++ 2 files changed, 8 insertions(+), 1 deletion(-) commit 2c9b050b6c60f3b20303d383eb860b8909ab961e Author: Jon Hunter <jonathanh@nvidia.com> Date: Wed Mar 30 10:15:13 2016 +0100 arm64: tegra: Remove unused #power-domain-cells property Remove the "#power-domain-cells" property which was incorrectly included by commit e53095857166 ("arm64: tegra: Add Tegra210 support"). Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210.dtsi | 2 -- 1 file changed, 2 deletions(-) commit a26f3963d980ff0d5a33a01b9a93c80b9d370835 Author: Rhyland Klein <rklein@nvidia.com> Date: Thu Mar 3 14:54:25 2016 -0500 arm64: tegra: Add gpio-keys nodes for Smaug Add gpio-keys nodes for the volumn controls, lid switch, tablet mode and power button. Signed-off-by: Rhyland Klein <rklein@nvidia.com> Reviewed-by: Andrew Bresticker <abrestic@chromium.org> [treding@nvidia.com: use symbolic names for input types and codes] [treding@nvidia.com: use wakeup-source instead of gpio-key,wakeup] Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210-smaug.dts | 43 +++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 0e91ba42be2a7f264b9b4503b99f93060d62172c Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Feb 29 18:36:50 2016 +0530 arm64: tegra: Enable power and volume keys on Jetson TX1 Add a gpio-keys device tree node to represent the Power, Volume Up and Volume Down keys found on Jetson TX1. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra210-p2597.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 5d17ba6e638e45f737c60eb58ae3a0a46ec1100d Author: Jon Hunter <jonathanh@nvidia.com> Date: Tue Feb 9 12:26:49 2016 +0000 arm64: tegra: Add support for Google Pixel C Add initial device-tree support for Google Pixel C (a.k.a. Smaug) based upon Tegra210 SoC with 3 GiB of LPDDR4 RAM. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Tested-by: Alexandre Courbot <acourbot@nvidia.com> Reviewed-by: Andrew Bresticker <abrestic@chromium.org> Tested-by: Andrew Bresticker <abrestic@chromium.org> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/Makefile | 1 + arch/arm64/boot/dts/nvidia/tegra210-smaug.dts | 83 +++++++++++++++++++++++++++ 2 files changed, 84 insertions(+) commit 81d22e89b42668dccba5393737170ae72ed78ff9 Author: Sudeep Holla <Sudeep.Holla@arm.com> Date: Mon Feb 8 21:55:43 2016 +0000 arm64: tegra: Replace legacy *,wakeup property with wakeup-source Though the keyboard and other driver will continue to support the legacy "gpio-key,wakeup", "nvidia,wakeup-source" boolean property to enable the wakeup source, "wakeup-source" is the new standard binding. This patch replaces all the legacy wakeup properties with the unified "wakeup-source" property in order to avoid any further copy-paste duplication. Cc: Stephen Warren <swarren@wwwdotorg.org> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-tegra@vger.kernel.org Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra132-norrin.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 68cd8b2e271fe9f6b507030eb6831cfa7bb3e40e Author: Thierry Reding <treding@nvidia.com> Date: Wed Jan 27 15:02:20 2016 +0100 arm64: tegra: Fix copy/paste typo in several DTS includes The comment about the 8250 vs. APB DMA-enabled UART devices that was added for Tegra20 and Tegra30 in commit b6551bb933f9 ("ARM: tegra: dts: add aliases and DMA requestor for serial controller") introduced a typo that has since spread to various other DTS include files. Fix all occurrences of this typo. Suggested-by: Ralf Ramsauer <ralf@ramses-pyramidenbau.de> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra132.dtsi | 2 +- arch/arm64/boot/dts/nvidia/tegra210.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit be70771d4cabe0763e7dacd55400abd38910d634 Author: Thierry Reding <treding@nvidia.com> Date: Mon Apr 11 15:35:06 2016 +0200 arm64: tegra: Remove 0, prefix from unit-addresses When Tegra124 support was first merged the unit-addresses of all devices were listed with a "0," prefix to encode the reg property's second cell. It turns out that this notation is not correct, and the "," separator is only used to separate fields in the unit address (such as the device and function number in PCI devices), not individual cells for addresses with more than one cell. Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm64/boot/dts/nvidia/tegra132-norrin.dts | 46 +++++----- arch/arm64/boot/dts/nvidia/tegra132.dtsi | 118 ++++++++++++------------- arch/arm64/boot/dts/nvidia/tegra210-p2180.dtsi | 8 +- arch/arm64/boot/dts/nvidia/tegra210-p2530.dtsi | 10 +-- arch/arm64/boot/dts/nvidia/tegra210-p2571.dts | 2 +- arch/arm64/boot/dts/nvidia/tegra210-p2595.dtsi | 2 +- arch/arm64/boot/dts/nvidia/tegra210-p2597.dtsi | 4 +- arch/arm64/boot/dts/nvidia/tegra210.dtsi | 118 ++++++++++++------------- 8 files changed, 154 insertions(+), 154 deletions(-) commit 22aab38e7b59fd79ce1045006be69a9abab58e5a Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Mar 11 11:11:39 2016 +0300 mfd: lp8788-irq: Uninitialized variable in irq handler Instead to being true/false, the "handled" is true/uninitialized. Presumably this doesn't cause that many problems in real life because normally we handle the IRQ. Fixes: eea6b7cc53aa ('mfd: Add lp8788 mfd driver') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Milo Kim <milo.kim@ti.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/lp8788-irq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit adae28c59a6a71a971ffed713550911546df0e20 Author: Arnd Bergmann <arnd@arndb.de> Date: Wed Mar 23 11:36:53 2016 +0100 mfd: syscon: Include errno.h from header The syscon header uses the ENOTSUPP error constant, but doesn't include the header that defines it. This causes a build error after the imx pinctrl driver started using syscon: include/linux/mfd/syscon.h: In function 'syscon_node_to_regmap': include/linux/mfd/syscon.h:32:18: error: 'ENOTSUPP' undeclared (first use in this function) return ERR_PTR(-ENOTSUPP); ^~~~~~~~ This adds the missing #include. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Fixes: 8626ada871f1 ("pinctrl: imx: attach iomuxc device to gpr syscon") Signed-off-by: Lee Jones <lee.jones@linaro.org> include/linux/mfd/syscon.h | 1 + 1 file changed, 1 insertion(+) commit ee414de525a9abf29e8a1b0c1b6f79f9e875213a Author: Irina Tirdea <irina.tirdea@intel.com> Date: Sun Mar 13 03:02:58 2016 +0200 mfd: core: Fix ACPI child matching by _HID/_CID If MDF child devices have separate ACPI nodes identified by _HID/_CID, they will not be assigned the intended ACPI companion. acpi_match_device_ids will return 0 if a the child device matches the _HID/_CID, so this patch changes the matching condition to check for 0 on success. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Acked-by: Mika Westerberg <mika.westeberg@linux.intel.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/mfd-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9caac886397bdfd6c1a6b48493db6cd95bce313c Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Feb 19 10:42:11 2016 +0200 mfd: intel_quark_i2c_gpio: Switch to use struct device * There is no need to pass struct pci_dev * to intel_quark_register_i2c_clk() and intel_quark_unregister_i2c_clk(). Change the parameter to struct device *. As a result store it in the private struct instead of struct pci_dev *. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel_quark_i2c_gpio.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 7f0c5ae18d649ed2f4978cbf07c02a0ff732f23e Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Feb 19 10:42:10 2016 +0200 mfd: intel_quark_i2c_gpio: Remove clock tree on error path There is a potential resource leak in case when ->probe() fails. We have to unregister and remove clock tree which is done here. This is a follow up to previously pushed commit c4726abce63b ("mfd: intel_quark_i2c_gpio: Use clkdev_create()") that prevents double free() when clkdev_drop() followed by kfree() in devm_kcalloc() release stage. I leave Fixes tag here, but the backporting will require to backport the commit c4726abce63b ("mfd: intel_quark_i2c_gpio: Use clkdev_create()") first. Cc: stable@vger.kernel.org Fixes: 60ae5b9f5cdd (mfd: intel_quark_i2c_gpio: Add Intel Quark X1000 I2C-GPIO MFD Driver) Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/intel_quark_i2c_gpio.c | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) commit 65433fd561f089f232758efc2c6566b6b6febb47 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Mar 20 18:53:57 2016 +0000 mfd: da9063: Remove unused array mask_events_buf mask_events_buf is not used, so remove this redundant array. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> drivers/mfd/da9063-irq.c | 2 -- 1 file changed, 2 deletions(-) commit b1e429fe3ba7b10b8c6875b6dec1d62e1c252729 Author: Tim Gore <tim.gore@intel.com> Date: Mon Mar 21 14:37:29 2016 +0000 drm/i915: implement WaClearTdlStateAckDirtyBits This is to fix a GPU hang seen with mid thread pre-emption and pooled EUs. v2. Use IS_BXT_REVID instead of IS_BROXTON and INTEL_REVID v3. And use correct type for register addresses Signed-off-by: Tim Gore <tim.gore@intel.com> Reviewed-by: Arun Siluvery <arun.siluvery@linux.intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458571049-854-1-git-send-email-tim.gore@intel.com drivers/gpu/drm/i915/i915_reg.h | 12 ++++++++++++ drivers/gpu/drm/i915/intel_lrc.c | 19 +++++++++++++++++++ 2 files changed, 31 insertions(+) commit aa14138a51ca42eada706d4b9635bd32d1e09ced Author: Philippe Bergheaud <felix@linux.vnet.ibm.com> Date: Thu Mar 31 11:19:28 2016 +0200 cxl: Configure the PSL for two CAPI ports on POWER8NVL The POWER8NVL chip has two CAPI ports. Configure the PSL to route data to the port corresponding to the CAPP unit. Signed-off-by: Philippe Bergheaud <felix@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/pci.c | 41 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) commit 86c9ffcc1ed17497a5df473232a7e654fa8cfa1f Author: Philippe Bergheaud <felix@linux.vnet.ibm.com> Date: Thu Mar 31 11:19:27 2016 +0200 powerpc: Define PVR value for POWER8NVL processor Signed-off-by: Philippe Bergheaud <felix@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/reg.h | 1 + 1 file changed, 1 insertion(+) commit b3d79eaa6c97b04965fa479652dd0317253f81d1 Author: Vipin K Parashar <vipin@linux.vnet.ibm.com> Date: Tue Sep 1 04:52:43 2015 +0530 powerpc/opal: Assign numbers to OPAL_MSG macros of enum opal_msg_type This patch assigns numbers to OPAL_MSG macros of enum opal_msg_type to prevent accidental insertion of any new value in between and thus break OPAL API. This is also helpful while backporting mainline kernel changes to distros which run downlevel kernel and thus don't have all OPAL messages defined, avoiding unnecessary bugs due to enum values order mismatch. Signed-off-by: Vipin K Parashar <vipin@linux.vnet.ibm.com> Acked-by: Stewart Smith <stewart@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/opal-api.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit ef69b03dfd321ffa1bcb4248e9b8744f653e3859 Author: Michael Ellerman <mpe@ellerman.id.au> Date: Wed Mar 2 12:36:56 2016 +1100 MAINTAINERS: Add powerpc drivers to the powerpc section We'd like folks working on drivers for powerpc to also Cc linuxppc-dev, so we can be aware of what's going on in drivers and/or review the changes. So add patterns to the powerpc MAINTAINERS section to catch some of the drivers we're interested in. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> MAINTAINERS | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit e3824e4281b8e31d55c08a06b20abb4f677a0baf Author: Russell Currey <ruscur@russell.cc> Date: Wed Mar 2 17:12:45 2016 +1100 powerpc/swsusp: Only use tlbie in POWER4 mode If CONFIG_HIBERNATION and CONFIG_PPC_BOOK3S_64 are set, code in arch/powerpc/kernel/swsusp_amd64.S which uses the tlbia macro is enabled. tlbia in turn uses tlbie, an instruction which takes more than one operand in newer versions of POWER. As such, the kernel fails to build due to the assembler complaining about missing operands. This can be worked around by assembling the instruction as in POWER4. This fixes the build breakage caused by enabling CONFIG_HIBERNATION. Hibernation is currently only tested on G5 PowerMacs, which should be unaffected by this change. For other platforms it may now build, whether or not it works is a different story. Signed-off-by: Russell Currey <ruscur@russell.cc> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/include/asm/ppc_asm.h | 3 +++ 1 file changed, 3 insertions(+) commit a7ee539584acf4a565b7439ceaea8401ec210353 Author: Rashmica Gupta <rashmicy@gmail.com> Date: Fri Feb 19 16:38:47 2016 +1100 powerpc/Kconfig: Update config option based on page size. Currently on PPC64 changing kernel pagesize from 4K to 64K leaves FORCE_MAX_ZONEORDER set to 13 - which produces a compile error. The error occurs because of the following constraint (from include/linux/mmzone.h) being violated: MAX_ORDER -1 + PAGESHIFT <= SECTION_SIZE_BITS. Expanding this out, we get: FORCE_MAX_ZONEBITS <= 25 - PAGESHIFT, which requires, for a 64K page, FORCE_MAX_ZONEBITS <= 9. Thus set max value of FORCE_MAX_ZONEORDER for 64K pages to 9, and 4K pages to 13. Also, check the minimum value: In include/linux/huge_mm.h, we have the constraint HPAGE_PMD_ORDER < MAX_ORDER which expands out to: PTE_INDEX_SIZE < FORCE_MAX_ZONEORDER. PTE_INDEX_SIZE is: 9 (4k hash or no hash 4K pgtable) or 8 (64K hash or no hash 64K pgtable). Thus a min value of 8 for 64K pages and 9 for 4K pages is reasonable. So, update the range of FORCE_MAX_ZONEORDER from 9-64 to 8-9 for 64K pages and from 13-64 to 9-13 for 4K pages. Signed-off-by: Rashmica Gupta <rashmicy@gmail.com> Reviewed-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6a0bcab9c6c337e14689cabd276f00649e980cf1 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 18:08:17 2016 -0400 drivers/cpufreq: make ppc_cbe_cpufreq_pmi driver explicitly non-modular The Kconfig for this driver is currently: config CPU_FREQ_CBE_PMI bool "CBE frequency scaling using PMI interface" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular and unused code here, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: Viresh Kumar <viresh.kumar@linaro.org> Cc: Christian Krafft <krafft@de.ibm.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: linuxppc-dev@lists.ozlabs.org Cc: linux-pm@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/cpufreq/ppc_cbe_cpufreq_pmi.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) commit c0c523897d1f83bc8484cb58d1f51d935b23cee5 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 18:08:16 2016 -0400 powerpc: make kernel/nvram_64.c explicitly non-modular The Makefile/Kconfig currently controlling compilation of this code is: obj-$(CONFIG_PPC64) += setup_64.o sys_ppc32.o \ signal_64.o ptrace32.o \ paca.o nvram_64.o firmware.o arch/powerpc/platforms/Kconfig.cputype:config PPC64 arch/powerpc/platforms/Kconfig.cputype: bool "64-bit kernel" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We don't replace module.h with init.h since the file already has that. We delete the MODULE_LICENSE tag since that information is already contained at the top of the file in the comments. Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Hari Bathini <hbathini@linux.vnet.ibm.com> Cc: Nathan Fontenot <nfont@linux.vnet.ibm.com> Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Anton Blanchard <anton@samba.org> Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Reviewed-by: Nathan Fontenot <nfont@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/nvram_64.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit 8038665fb54f1e54785c63be111647abebfe9f20 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 18:08:15 2016 -0400 powerpc/cell: Make spu_base.c explicitly non-modular The Kconfig currently controlling compilation of this code is: arch/powerpc/platforms/cell/Kconfig:config SPU_BASE arch/powerpc/platforms/cell/Kconfig: bool ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/cell/spu_base.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) commit 8ee26530bb189909cca6f4b1f36a7577c840c526 Author: Russell Currey <ruscur@russell.cc> Date: Tue Feb 16 23:06:05 2016 +1100 powerpc/eeh: rename EEH from "extended" to "enhanced" error handling IBM online documentation for EEH uses "extended error handling" and "enhanced error handling" to refer to the same thing, in different places. The only place mentioning it as "enhanced error handling" in the kernel is the MAINTAINERS file, and it's "extended" in some documentation. IBM originally defined EEH as "enhanced error handling", so standardise all mentions of EEH to use that term. Signed-off-by: Russell Currey <ruscur@russell.cc> Acked-by: Gavin Shan <gwshan@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Documentation/powerpc/eeh-pci-error-recovery.txt | 2 +- arch/powerpc/kernel/eeh.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit b4c6afdc3a1ad73542c8e92220c30b8f953c51de Author: Michael Ellerman <mpe@ellerman.id.au> Date: Wed Mar 16 21:36:06 2016 +1100 powerpc: Make generic_memcpy() private to copy_32.S generic_memcpy() is only called from copy_32.S, so there's no reason for it to be global. Reported-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/lib/copy_32.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b05fac783a75c6e9f3af2ce0824f3a6ff12540ab Author: Michael Ellerman <mpe@ellerman.id.au> Date: Wed Mar 16 21:36:05 2016 +1100 powerpc: Remove orphaned asm implementation of abs() This has been unused since ~2004, remove it. Reported-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/kernel/misc_32.S | 6 ------ 1 file changed, 6 deletions(-) commit 1f4c66e80574e85aff25179fc71bdadfb1a701ef Author: Michael Ellerman <mpe@ellerman.id.au> Date: Wed Mar 16 21:56:20 2016 +1100 powerpc/mm: Remove long disabled SLB code We have a bunch of SLB related code in the tree which is there to handle dynamic VSIDs - but currently it's all disabled at compile time. The comments say "Keep that around for when we re-implement dynamic VSIDs". But that was over 10 years ago (commit 3c726f8dee6f ("[PATCH] ppc64: support 64k pages")). The chance that it would still work unchanged is minimal, and in the meantime it's confusing to folks browsing/grepping the code. If we ever want to re-instate it, it's in the git history. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Acked-by: Balbir Singh <bsingharora@gmail.com> arch/powerpc/kernel/exceptions-64s.S | 102 ----------------------------------- arch/powerpc/mm/slb.c | 1 - arch/powerpc/mm/slb_low.S | 50 ----------------- 3 files changed, 153 deletions(-) commit f8a25db47ebc11fe228735d916e480d4b2ebe611 Author: Russell Currey <ruscur@russell.cc> Date: Tue Mar 15 21:14:12 2016 +1100 powerpc/powernv: Use the "unknown" checkstop type as a fallback The HMI code knows about three types of errors: CORE, NX and UNKNOWN. If OPAL were to add a new type, it would not be handled at all since there is no fallback case. Instead of explicitly checking for UNKNOWN, treat any checkstop type without a handler as unknown. Signed-off-by: Russell Currey <ruscur@russell.cc> Reviewed-by: Daniel Axtens <dja@axtens.net> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/powernv/opal-hmi.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 43b27d7286737d9af9ebeff0219e38560cb31748 Author: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Date: Fri Apr 8 16:50:14 2016 +0100 ASoC: arizona: Do not create OUT4R widget for CS47L24/WM1831 The CS47L24 and WM1831 codecs only use the OUT4L widget so we can skip creation of the OUT4R widget. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/arizona.c | 2 ++ 1 file changed, 2 insertions(+) commit 25a56705332add0363e47b3a0eca001d6fbd5bec Author: Dongwon Kim <dongwon.kim@intel.com> Date: Wed Mar 16 18:06:13 2016 -0700 drm/i915/bxt: Reversed polarity of PORT_PLL_REF_SEL bit For BXT, description of polarities of PORT_PLL_REF_SEL has been reversed for newer Gen9LP steppings according to the recent update in Bspec. This bit now should be set for "Non-SSC" mode for all Gen9LP starting from B0 stepping. v2: Only B0 and newer stepping should be affected by this change. Signed-off-by: Dongwon Kim <dongwon.kim@intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94866 Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458176773-26925-1-git-send-email-dongwon.kim@intel.com drivers/gpu/drm/i915/intel_dpll_mgr.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit c0ead7039affb0f7ce7b734655419d43142e8f5e Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 30 10:00:05 2016 +0200 drm/i915: Rename hw state checker to hw state verifier. Check functions are used by atomic to see if the new state will be allowed. There's also a hw state checker which checks afterwards that the committed state is correct. Rename it to hw state verifier to reduce some confusion. Suggested-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56FB8785.8020506@linux.intel.com Reviewed-by: Matt Roper <matthew.d.roper@intel.com> drivers/gpu/drm/i915/intel_display.c | 60 ++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 30 deletions(-) commit f6d1973db2d216203233b31ee8bc56976c6f78d4 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 23 14:58:07 2016 +0100 drm/i915: Move modeset state verifier calls. The modeset state verifier no longer has full access to the hardware, instead it should only verify affected crtc's. Looking for disabled stuff can be verified immediately after all crtc disables have completed, while each enabled crtc can be verified right after being enabled. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458741487-23801-3-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Matt Roper <matthew.d.roper@intel.com> [mlankhorst: check -> verify] drivers/gpu/drm/i915/intel_display.c | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) commit e7c84544757a405e430779e2ffe13ebe9b048361 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 23 14:58:06 2016 +0100 drm/i915: Make modeset state verifier take crtc as argument. This will make it easier to keep the crtc checker when atomic commit is reworked for asynchronous commits. This prevents checking crtc's that were not part of the state. It's safe to verify disabled encoders, connectors and dpll's that are not part of the state, because during modeset connection_mutex is held. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458741487-23801-2-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Matt Roper <matthew.d.roper@intel.com> [mlankhorst: Extend commit message and rename check to verify.] drivers/gpu/drm/i915/intel_display.c | 316 ++++++++++++++++++++--------------- 1 file changed, 183 insertions(+), 133 deletions(-) commit ce23e640133484eebc20ca7b7668388213e11327 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon Apr 11 00:48:00 2016 -0400 ->getxattr(): pass dentry and inode as separate arguments Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Documentation/filesystems/porting | 6 ++++++ .../staging/lustre/lustre/llite/llite_internal.h | 4 ++-- drivers/staging/lustre/lustre/llite/xattr.c | 6 ++---- fs/bad_inode.c | 4 ++-- fs/ceph/super.h | 2 +- fs/ceph/xattr.c | 8 ++++---- fs/cifs/cifsfs.h | 2 +- fs/cifs/xattr.c | 6 +++--- fs/ecryptfs/crypto.c | 5 ++++- fs/ecryptfs/ecryptfs_kernel.h | 4 ++-- fs/ecryptfs/inode.c | 23 +++++++++++----------- fs/ecryptfs/mmap.c | 3 ++- fs/fuse/dir.c | 5 ++--- fs/gfs2/inode.c | 9 ++++----- fs/hfs/attr.c | 5 ++--- fs/hfs/hfs_fs.h | 4 ++-- fs/jfs/jfs_xattr.h | 2 +- fs/jfs/xattr.c | 8 ++++---- fs/kernfs/inode.c | 6 +++--- fs/kernfs/kernfs-internal.h | 4 ++-- fs/libfs.c | 4 ++-- fs/overlayfs/inode.c | 4 ++-- fs/overlayfs/overlayfs.h | 4 ++-- fs/overlayfs/super.c | 2 +- fs/ubifs/ubifs.h | 4 ++-- fs/ubifs/xattr.c | 6 +++--- fs/xattr.c | 11 ++++++----- include/linux/fs.h | 3 ++- include/linux/xattr.h | 2 +- net/socket.c | 2 +- security/commoncap.c | 6 +++--- security/integrity/evm/evm_main.c | 2 +- security/selinux/hooks.c | 9 +++++---- security/smack/smack_lsm.c | 4 ++-- 34 files changed, 94 insertions(+), 85 deletions(-) commit 4923ec0b10d998349c2ac4b38aa4674e539e6f92 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 19:39:21 2016 -0700 bpf: simplify verifier register state assignments verifier is using the following structure to track the state of registers: struct reg_state { enum bpf_reg_type type; union { int imm; struct bpf_map *map_ptr; }; }; and later on in states_equal() does memcmp(&old->regs[i], &cur->regs[i],..) to find equivalent states. Throughout the code of verifier there are assignements to 'imm' and 'map_ptr' fields and it's not obvious that most of the assignments into 'imm' don't need to clear extra 4 bytes (like mark_reg_unknown_value() does) to make sure that memcmp doesn't go over junk left from 'map_ptr' assignment. Simplify the code by converting 'int' into 'long' Suggested-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 3c9d6296b7aee536a96ea2b53a15d23511738c1c Author: Paolo Abeni <pabeni@redhat.com> Date: Fri Apr 8 12:20:30 2016 +0200 security: drop the unused hook skb_owned_by The skb_owned_by hook was added with the commit ca10b9e9a8ca ("selinux: add a skb_owned_by() hook") and later removed when said commit was reverted. Later on, when switching to list of hooks, a field named 'skb_owned_by' was included into the security_hook_head struct, but without any users nor caller. This commit removes the said left-over field. Fixes: b1d9e6b0646d ("LSM: Switch to lists of hooks") Signed-off-by: Paolo Abeni <pabeni@redhat.com> Acked-by: Casey Schaufler <casey@schaufler-ca.com> Acked-by: Paul Moore <pmoore@paul-moore.com> Signed-off-by: James Morris <james.l.morris@oracle.com> include/linux/lsm_hooks.h | 1 - security/security.c | 1 - 2 files changed, 2 deletions(-) commit d88e397f12ba0c8c672952c4711d7280525c54ed Author: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Date: Wed Mar 9 12:53:13 2016 +0100 cxl: Remove dead code Function cxl_get_phys_dev() was removed from the kernel API by a previous patch, but it's actually dead code. Remove it. Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Acked-by: Ian Munsie <imunsie@au1.ibm.com> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Acked-by: Michael Neuling <mikey@neuling.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> drivers/misc/cxl/api.c | 9 --------- 1 file changed, 9 deletions(-) commit bdf5fc6338047cfeba98d2ab629997f3013e610f Author: Nathan Fontenot <nfont@linux.vnet.ibm.com> Date: Wed Feb 10 11:12:13 2016 -0600 powerpc/pseries: Update LMB associativity index during DLPAR add/remove The associativity array index specified for a LMB in the device tree, /ibm,dynamic-reconfiguration-memory/ibm,dynamic-memory, needs to be updated prior to DLPAR adding a LMB and after DLPAR removing a LMB. Without doing this step in the DLPAR add process a LMB could be configured with the incorrect affinity. For a LMB that was not present at boot the affinity index is set to 0xffffffff, which defaults to adding the LMB to the first online node since the index is not a valid value. Or, the affinity index could contain a stale value if the LMB was present at boot but later DLPAR removed and is being DLPAR added back to the system. This patch adds a step in the DLPAR add flow to look up the associativity index for a LMB prior to adding a LMB and setting the associativity to 0xffffffff when a LMB is removed. This patch also modifies the DLPAR add/remove flow to no longer do a single update of the device tree property after all of the requested DLPAR operations are complete and now does a property update during the add or remove of each LMB. Signed-off-by: Nathan Fontenot <nfont@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/hotplug-memory.c | 193 ++++++++++++++++++++---- 1 file changed, 162 insertions(+), 31 deletions(-) commit 4a4bdfea7cb75b5c8b222932796f64a14027d512 Author: Nathan Fontenot <nfont@linux.vnet.ibm.com> Date: Wed Feb 10 11:10:44 2016 -0600 powerpc/pseries: Refactor dlpar_add_lmb() code Re-factor dlpar_lmb_add() routine by moving the validation of the lmb flags and the acquireing of the DRC to a wrapper around the work to add the memory to the system. This is done to make handling of errors during the addition of the memory easier and to facilitate the upcoming addition of updating the lmb's affinity prior to adding the memory. Signed-off-by: Nathan Fontenot <nfont@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> arch/powerpc/platforms/pseries/hotplug-memory.c | 34 +++++++++++++++---------- 1 file changed, 20 insertions(+), 14 deletions(-) commit b296821a7c42fa58baa17513b2b7b30ae66f3336 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun Apr 10 20:48:24 2016 -0400 xattr_handler: pass dentry and inode as separate arguments of ->get() ... and do not assume they are already attached to each other Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/9p/acl.c | 6 +++--- fs/9p/xattr.c | 4 ++-- fs/btrfs/xattr.c | 6 ++---- fs/ext2/xattr_security.c | 6 +++--- fs/ext2/xattr_trusted.c | 6 +++--- fs/ext2/xattr_user.c | 8 ++++---- fs/ext4/xattr_security.c | 6 +++--- fs/ext4/xattr_trusted.c | 6 +++--- fs/ext4/xattr_user.c | 8 ++++---- fs/f2fs/xattr.c | 14 ++++++-------- fs/gfs2/xattr.c | 6 +++--- fs/hfsplus/xattr.c | 10 +++++----- fs/hfsplus/xattr.h | 2 +- fs/hfsplus/xattr_security.c | 6 +++--- fs/hfsplus/xattr_trusted.c | 6 +++--- fs/hfsplus/xattr_user.c | 6 +++--- fs/jffs2/security.c | 6 +++--- fs/jffs2/xattr_trusted.c | 6 +++--- fs/jffs2/xattr_user.c | 6 +++--- fs/nfs/nfs4proc.c | 12 ++++++------ fs/ocfs2/xattr.c | 20 ++++++++++---------- fs/orangefs/xattr.c | 10 ++++++---- fs/posix_acl.c | 10 +++++----- fs/reiserfs/xattr_security.c | 9 ++++----- fs/reiserfs/xattr_trusted.c | 9 ++++----- fs/reiserfs/xattr_user.c | 9 ++++----- fs/squashfs/xattr.c | 6 ++++-- fs/xattr.c | 3 ++- fs/xfs/xfs_xattr.c | 6 +++--- include/linux/xattr.h | 3 ++- mm/shmem.c | 6 +++--- 31 files changed, 113 insertions(+), 114 deletions(-) commit 79a628d14ec7ee9adfdc3ce04343d5ff7ec20c18 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun Apr 10 18:50:48 2016 -0400 reiserfs: switch to generic_{get,set,remove}xattr() reiserfs_xattr_[sg]et() will fail with -EOPNOTSUPP for V1 inodes anyway, and all reiserfs instances of ->[sg]et() call it and so does ->set_acl(). Checks for name length in the instances had been bogus; they should've been "bugger off if it's _exactly_ the prefix" (as generic would do on its own) and not "bugger off if it's shorter than the prefix" - that can't happen. xattr_full_name() is needed to adjust for the fact that generic instances will skip the prefix in the name passed to ->[gs]et(); reiserfs homegrown analogues didn't. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/reiserfs/file.c | 6 ++--- fs/reiserfs/namei.c | 18 +++++++-------- fs/reiserfs/xattr.c | 54 -------------------------------------------- fs/reiserfs/xattr.h | 9 +------- fs/reiserfs/xattr_security.c | 14 +++++------- fs/reiserfs/xattr_trusted.c | 14 +++++------- fs/reiserfs/xattr_user.c | 14 +++++------- 7 files changed, 31 insertions(+), 98 deletions(-) commit 5fdccfef483d088fcc533b282bf6953579d6d6f4 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun Apr 10 17:07:33 2016 -0400 cifs: kill more bogus checks in ->...xattr() methods none of that stuff can ever be called for NULL or negative dentry. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/xattr.c | 42 ++++++------------------------------------ 1 file changed, 6 insertions(+), 36 deletions(-) commit fc64005c93090c052637f63578d810b037abb1a1 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun Apr 10 01:33:30 2016 -0400 don't bother with ->d_inode->i_sb - it's always equal to ->d_sb ... and neither can ever be NULL Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/9p/vfs_inode.c | 2 +- fs/btrfs/tree-log.c | 6 +++--- fs/cifs/cifs_dfs_ref.c | 2 +- fs/cifs/inode.c | 3 +-- fs/cifs/readdir.c | 2 +- fs/cifs/xattr.c | 16 ++++------------ fs/efs/namei.c | 2 +- fs/exofs/super.c | 2 +- fs/ext2/namei.c | 2 +- fs/ext4/namei.c | 4 ++-- fs/f2fs/namei.c | 2 +- fs/gfs2/ops_fstype.c | 2 +- fs/gfs2/super.c | 2 +- fs/jffs2/dir.c | 2 +- fs/jffs2/super.c | 2 +- fs/jfs/namei.c | 2 +- fs/namei.c | 4 ++-- fs/nfs/direct.c | 2 +- fs/nfsd/nfs3proc.c | 4 ++-- fs/nfsd/nfs3xdr.c | 2 +- fs/nfsd/nfsfh.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/ocfs2/file.c | 2 +- fs/udf/namei.c | 2 +- fs/ufs/super.c | 2 +- include/trace/events/ext4.h | 6 +++--- kernel/audit_watch.c | 2 +- security/integrity/evm/evm_main.c | 4 ++-- security/selinux/hooks.c | 2 +- security/smack/smack_lsm.c | 2 +- 30 files changed, 41 insertions(+), 50 deletions(-) commit c20c8f750d9f8f8617f07ee2352d3ff560e66bc2 Author: Suman Anna <s-anna@ti.com> Date: Sun Apr 10 13:20:11 2016 -0600 ARM: OMAP2+: hwmod: fix _idle() hwmod state sanity check sequence The omap_hwmod _enable() function can return success without setting the hwmod state to _HWMOD_STATE_ENABLED for IPs with reset lines when all of the reset lines are asserted. The omap_hwmod _idle() function also performs a similar check, but after checking for the hwmod state first. This triggers the WARN when pm_runtime_get and pm_runtime_put are invoked on IPs with all reset lines asserted. Reverse the checks for hwmod state and reset lines status to fix this. Issue found during a unbind operation on a device with reset lines still asserted, example backtrace below ------------[ cut here ]------------ WARNING: CPU: 1 PID: 879 at arch/arm/mach-omap2/omap_hwmod.c:2207 _idle+0x1e4/0x240() omap_hwmod: mmu_dsp: idle state can only be entered from enabled state Modules linked in: CPU: 1 PID: 879 Comm: sh Not tainted 4.4.0-00008-ga989d951331a #3 Hardware name: Generic OMAP5 (Flattened Device Tree) [<c0018e60>] (unwind_backtrace) from [<c0014dc4>] (show_stack+0x10/0x14) [<c0014dc4>] (show_stack) from [<c037ac28>] (dump_stack+0x90/0xc0) [<c037ac28>] (dump_stack) from [<c003f420>] (warn_slowpath_common+0x78/0xb4) [<c003f420>] (warn_slowpath_common) from [<c003f48c>] (warn_slowpath_fmt+0x30/0x40) [<c003f48c>] (warn_slowpath_fmt) from [<c0028c20>] (_idle+0x1e4/0x240) [<c0028c20>] (_idle) from [<c0029080>] (omap_hwmod_idle+0x28/0x48) [<c0029080>] (omap_hwmod_idle) from [<c002a5a4>] (omap_device_idle+0x3c/0x90) [<c002a5a4>] (omap_device_idle) from [<c0427a90>] (__rpm_callback+0x2c/0x60) [<c0427a90>] (__rpm_callback) from [<c0427ae4>] (rpm_callback+0x20/0x80) [<c0427ae4>] (rpm_callback) from [<c0427f84>] (rpm_suspend+0x138/0x74c) [<c0427f84>] (rpm_suspend) from [<c0428b78>] (__pm_runtime_idle+0x78/0xa8) [<c0428b78>] (__pm_runtime_idle) from [<c041f514>] (__device_release_driver+0x64/0x100) [<c041f514>] (__device_release_driver) from [<c041f5d0>] (device_release_driver+0x20/0x2c) [<c041f5d0>] (device_release_driver) from [<c041d85c>] (unbind_store+0x78/0xf8) [<c041d85c>] (unbind_store) from [<c0206df8>] (kernfs_fop_write+0xc0/0x1c4) [<c0206df8>] (kernfs_fop_write) from [<c018a120>] (__vfs_write+0x20/0xdc) [<c018a120>] (__vfs_write) from [<c018a9cc>] (vfs_write+0x90/0x164) [<c018a9cc>] (vfs_write) from [<c018b1f0>] (SyS_write+0x44/0x9c) [<c018b1f0>] (SyS_write) from [<c0010420>] (ret_fast_syscall+0x0/0x1c) ---[ end trace a4182013c75a9f50 ]--- While at this, fix the sequence in _shutdown() as well, though there is no easy reproducible scenario. Fixes: 747834ab8347 ("ARM: OMAP2+: hwmod: revise hardreset behavior") Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 22d20cb4876eaee0c64960c69469e3631a61786f Author: Suman Anna <s-anna@ti.com> Date: Sun Apr 10 13:20:11 2016 -0600 ARM: DRA7: hwmod: Add data for GPTimer 12 Add the hwmod data for GPTimer 12. GPTimer 12 is present in WKUPAON power domain and is clocked from a secure 32K clock. GPTimer 12 serves as a secure timer on HS devices, but is available for kernel on regular GP devices. The hwmod link is registered only on GP devices. The hwmod data also reused the existing timer class instead of reintroducing the identical dra7xx_timer_secure_sysc class which was dropped in commit edec17863362 ("ARM: DRA7: hwmod: Fix the hwmod class for GPTimer4"). Cc: Paul Walmsley <paul@pwsan.com> Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod_7xx_data.c | 36 +++++++++++++++++++++++++++++-- 1 file changed, 34 insertions(+), 2 deletions(-) commit b5a553c08bec14a058501df3fa6eb39f63f00a98 Author: Lokesh Vutla <lokeshvutla@ti.com> Date: Sun Apr 10 13:20:10 2016 -0600 ARM: AMx3xx: RTC: Add lock and unlock functions Hook omap_hwmod_rtc_unlock/lock functions into RTC hwmod, so that SYSCONFIG register is updated properly. Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod_33xx_43xx_ipblock_data.c | 2 ++ 1 file changed, 2 insertions(+) commit d7d31b897050ce2c60960ebb6517fc228c52e9bb Author: Lokesh Vutla <lokeshvutla@ti.com> Date: Sun Apr 10 13:20:10 2016 -0600 ARM: DRA7: RTC: Add lock and unlock functions Hook omap_hwmod_rtc_unlock/lock functions into RTC hwmod, so that SYSCONFIG register is updated properly Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod_7xx_data.c | 2 ++ 1 file changed, 2 insertions(+) commit 461932dfb54ebaf7da438fd8b769a01ce97a9360 Author: Lokesh Vutla <lokeshvutla@ti.com> Date: Sun Apr 10 13:20:10 2016 -0600 ARM: OMAP2+: hwmod: RTC: Add lock and unlock functions RTC IP have kicker feature which prevents spurious writes to its registers. In order to write into any of the RTC registers, KICK values has to be written to KICK registers. Also, RTC busy flag needs to be polled for non-TC registers as well, without which update is not proper and confirmed it by testing on DRA7-evm. Introduce omap_hwmod_rtc_unlock/lock functions, which writes into these KICK registers inorder to lock and unlock RTC registers. Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> [paul@pwsan.com: fixed subject line] Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod.h | 2 ++ arch/arm/mach-omap2/omap_hwmod_reset.c | 65 ++++++++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+) commit b05ff3c394bc5dbb1bc88073759f01c0ebdf5de1 Author: Vignesh R <vigneshr@ti.com> Date: Sun Apr 10 13:20:09 2016 -0600 ARM: OMAP2+: DRA7: Add hwmod entries for PWMSS Add hwmod entries for the PWMSS on DRA7. Set l4_root_clk_div as the main_clk of PWMSS. It is fixed-factored clock equal to L4PER2_L3_GICLK/2(l3_iclk_div/2). Signed-off-by: Vignesh R <vigneshr@ti.com> [fcooper@ti.com: Do not add eQEP, ePWM and eCAP hwmod entries] Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com> [paul@pwsan.com: fixed sparse warnings; added missing comments] Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod_7xx_data.c | 89 +++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) commit 9ad4d9a38a7f62a4891124501cdce4e768dbba16 Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Sun Apr 10 13:20:09 2016 -0600 ARM: DRA7: hwmod: Add data for McASP1/2/4/5/6/7/8 Add missing data for all McASP ports for the dra7 family Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Paul Walmsley <paul@pwsan.com> arch/arm/mach-omap2/omap_hwmod_7xx_data.c | 237 ++++++++++++++++++++++++++++++ 1 file changed, 237 insertions(+) commit ab4b6496a26f87ceff95ee6c0449e6ac2de2f2e4 Author: Harald Geyer <harald@ccbib.org> Date: Sun Jan 17 16:13:31 2016 +0000 iio: dht11: Improve logging * Unify log messages * Add more DEBUG messages Apparently this driver is working unreliably on some platforms that I can't test. Therefore I want an easy way for bug reporters to provide useful information without making the driver too chatty by default. Signed-off-by: Harald Geyer <harald@ccbib.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/humidity/dht11.c | 40 ++++++++++++++++++++++++++++++++++------ 1 file changed, 34 insertions(+), 6 deletions(-) commit 4a99fa06a8ca27a5187636e630568658000af575 Author: YH Huang <yh.huang@mediatek.com> Date: Wed Apr 6 10:32:25 2016 +0800 sbs-battery: fix power status when battery charging near dry POWER_SUPPLY_STATUS_NOT_CHARGING is used for AC connected, but battery not charging (e.g. because battery temperature is out of acceptable range). When battery is charging near dry and BATTERY_FULL_DISCHARGED is set, it is wrong to set as POWER_SUPPLY_STATUS_NOT_CHARGING. Just use BATTERY_DISCHARGING to decide the power supply status is discharging or charging. Signed-off-by: YH Huang <yh.huang@mediatek.com> Reviewed-by: Daniel Kurtz <djkurtz@chromium.org> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/power/sbs-battery.c | 4 ---- 1 file changed, 4 deletions(-) commit b9223da41794030a5dfd5106c34ed1b98255e2ae Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Mar 18 12:00:51 2016 +0300 power: ipaq-micro-battery: freeing the wrong variable We accidentally free "micro_ac_power" which is an error pointer and it leads to an oops. We intended to free "micro_batt_power". Fixes: a2c1d531854c ('power_supply: ipaq_micro_battery: Check return values in probe') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/power/ipaq_micro_battery.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1285b0a30d530d0807c229c6aad73ed1966d75ad Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Fri Mar 18 08:40:16 2016 +0300 power/max8925: freeing wrong variable We were freeing "info->battery" instead of "info->usb", which leads to an OOps and a resource leak. The labels were wonky, "out_battery" did release the battery but out_usb did not release usb. I was introducing a call to free usb so it sort conflicted with existing misleading name. I renamed them. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Sebastian Reichel <sre@kernel.org> drivers/power/max8925_power.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit f80cb488439879df6ae3ba32a5dc4e0892fcd3ff Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Wed Mar 16 14:19:50 2016 +0100 power: reset: at91-shdwc: add new shutdown controller driver Sama5d2 SoC has a completely new shutdown controller with new features and register layout. It thus makes sense to add a new driver for this new peripheral. This driver is Device Tree only and handles events from the wake-up pin and the RTC. As the register layout may change in the future, so some values are encoded in a configuration structure. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Sebastian Reichel <sre@kernel.org> MAINTAINERS | 5 + drivers/power/reset/Kconfig | 8 + drivers/power/reset/Makefile | 1 + drivers/power/reset/at91-sama5d2_shdwc.c | 282 +++++++++++++++++++++++++++++++ 4 files changed, 296 insertions(+) commit 0e5f7d0b39e1f184dc25e3adb580c79e85332167 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Wed Mar 16 14:19:49 2016 +0100 ARM: dts: at91: shdwc binding: add new shutdown controller documentation The new shutdown controller compatible with sama5d2 has a new binding documentation and properties. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Sebastian Reichel <sre@kernel.org> .../devicetree/bindings/arm/atmel-at91.txt | 59 ++++++++++++++++++++++ 1 file changed, 59 insertions(+) commit ff5c37e3eae2cdba4aba13dc8c7e840abb41e4bb Author: Alison Schofield <amsfield22@gmail.com> Date: Tue Apr 5 21:11:31 2016 -0700 staging: iio: ad7606: use iio_device_{claim|release}_direct_mode() Replace the code that guarantees the device stays in direct mode with iio_device_{claim|release}_direct_mode() which does same. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/adc/ad7606_core.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit c455e58354adcde7ba1ebf3d753eba9a07cd587d Author: Alison Schofield <amsfield22@gmail.com> Date: Tue Apr 5 22:18:44 2016 -0700 iio: accel: mma7455: use regmap to retrieve struct device Driver includes struct regmap and struct device in its global data. Remove the struct device and use regmap API to retrieve device info. Patch created using Coccinelle plus manual edits. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma7455_core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 56ca9db862bf3d78e279d424b3434d66617c27ae Author: Paul Cercueil <paul.cercueil@analog.com> Date: Tue Apr 5 09:46:19 2016 +0200 iio: dac: Add support for the AD5592R/AD5593R ADCs/DACs This patch adds support for the AD5592R (spi) and AD5593R (i2c) ADC/DAC/GPIO devices. Signed-off-by: Paul Cercueil <paul.cercueil@analog.com> Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/dac/ad5592r.txt | 155 +++++ drivers/iio/dac/Kconfig | 27 + drivers/iio/dac/Makefile | 3 + drivers/iio/dac/ad5592r-base.c | 691 +++++++++++++++++++++ drivers/iio/dac/ad5592r-base.h | 76 +++ drivers/iio/dac/ad5592r.c | 164 +++++ drivers/iio/dac/ad5593r.c | 131 ++++ include/dt-bindings/iio/adi,ad5592r.h | 16 + 8 files changed, 1263 insertions(+) commit 5ea9274b8613f87120bfa6b0c0abc384c26cefb9 Author: Harald Geyer <harald@ccbib.org> Date: Sun Apr 10 13:03:18 2016 +0000 iio: mxs-lradc: Move binding document out of staging as well commit f836c45922446df872250a12dd08e48978aceb2f moved mxs-lradc driver out of staging. However the binding document was left in the old place. Signed-off-by: Harald Geyer <harald@ccbib.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/adc/mxs-lradc.txt | 47 ++++++++++++++++++++++ .../bindings/staging/iio/adc/mxs-lradc.txt | 47 ---------------------- 2 files changed, 47 insertions(+), 47 deletions(-) commit bc11ca4a0b84a2f2ebaca2614b92998738d13b1e Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Fri Apr 8 17:09:08 2016 +0200 iio:magnetometer:ak8975: triggered buffer support This will be used together with an external trigger (e.g hrtimer based software trigger). Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/Kconfig | 2 + drivers/iio/magnetometer/ak8975.c | 135 +++++++++++++++++++++++++++++++------- 2 files changed, 112 insertions(+), 25 deletions(-) commit 332868624c2b863e23bb192b0821605f5d0f084c Author: Hans de Goede <hdegoede@redhat.com> Date: Sat Apr 9 15:22:41 2016 +0200 ARM: dts: sun8i: Add dts file for the Orange Pi One SBC The Orange Pi One SBC, is a stripped down version of the popular Orange Pi PC. The one is a H3 based SBC, with 512M of RAM, micro-sd slot, 1 host usb, 1 otg usb, hdmi and 100Mbit ethernet. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun8i-h3-orangepi-one.dts | 145 ++++++++++++++++++++++++++++ 2 files changed, 146 insertions(+) commit fbbc5e7044f761652e1e83037bd90574976337a3 Author: Slawomir Stepien <sst@poczta.fm> Date: Sun Apr 10 13:23:09 2016 +0200 iio: potentiometer: add driver for Maxim Integrated DS1803 The following functions are supported: - write, read potentiometer value - potentiometer scale Datasheet: https://datasheets.maximintegrated.com/en/ds/DS1803.pdf Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../bindings/iio/potentiometer/ds1803.txt | 21 +++ drivers/iio/potentiometer/Kconfig | 10 ++ drivers/iio/potentiometer/Makefile | 1 + drivers/iio/potentiometer/ds1803.c | 173 +++++++++++++++++++++ 4 files changed, 205 insertions(+) commit dd7bedcd2673e4c8957d15d7e6e649fc6fa40206 Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Fri Mar 25 15:46:54 2016 +0100 NFC: pn533: add I2C phy driver This adds the I2C phy interface for the pn533 driver. This way the driver can be used to interact with I2C connected pn532 devices. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533/Kconfig | 11 ++ drivers/nfc/pn533/Makefile | 2 + drivers/nfc/pn533/i2c.c | 271 +++++++++++++++++++++++++++++++++++++++++++++ drivers/nfc/pn533/pn533.c | 31 ++++++ drivers/nfc/pn533/pn533.h | 2 + 5 files changed, 317 insertions(+) commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Fri Mar 25 15:46:53 2016 +0100 NFC: pn533: Separate physical layer from the core implementation The driver now has all core stuff isolated in one file, and all the hardware link specifics in another. Writing a pn533 driver on top of another hardware link is now just a matter of adding a new file for that new hardware specifics. The first user of this separation will be the i2c based pn532 driver that reuses pn533 core implementation on top of an i2c layer. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/Kconfig | 11 +- drivers/nfc/Makefile | 2 +- drivers/nfc/pn533.c | 3334 -------------------------------------------- drivers/nfc/pn533/Kconfig | 16 + drivers/nfc/pn533/Makefile | 7 + drivers/nfc/pn533/pn533.c | 2644 +++++++++++++++++++++++++++++++++++ drivers/nfc/pn533/pn533.h | 235 ++++ drivers/nfc/pn533/usb.c | 598 ++++++++ 8 files changed, 3502 insertions(+), 3345 deletions(-) commit 37f895d7e85e7d7e23e2395e666ea43001862e5f Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Fri Mar 25 15:46:52 2016 +0100 NFC: pn533: Fix socket deadlock A deadlock can occur when the NFC raw socket is closed while the driver is processing a command. Following is the call graph of the affected situation: send data via raw_sock: ------------- rawsock_tx_work sock_hold => socket refcnt++ nfc_data_exchange => cb = rawsock_data_exchange_complete ops->im_transceive = pn533_transceive => arg->cb = db = rawsock_data_exchange_complete pn533_send_data_async => cb = pn533_data_exchange_complete __pn533_send_async => cmd->complete_cb = cb = pn533_data_exchange_complete if_ops->send_frame_async response: -------- pn533_recv_response queue_work(priv->wq, &priv->cmd_complete_work) pn533_wq_cmd_complete pn533_send_async_complete cmd->complete_cb() = pn533_data_exchange_complete() arg->cb() = rawsock_data_exchange_complete() sock_put => socket refcnt-- => If the corresponding socket gets closed in the meantime socket will be destructed sk_free __sk_free sk->sk_destruct = rawsock_destruct nfc_deactivate_target ops->deactivate_target = pn533_deactivate_target pn533_send_cmd_sync pn533_send_cmd_async __pn533_send_async list_add_tail(&cmd->queue,&dev->cmd_queue) => add to command list because a command is currently processed wait_for_completion => the workqueue thread waits here because it is the one processing the commands => deadlock To fix the deadlock pn533_deactivate_target is changed to issue the PN533_CMD_IN_RELEASE command in async mode. This way nothing blocks and the release command is executed after the current command. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533.c | 40 ++++++++++++++++++++++++++++++---------- 1 file changed, 30 insertions(+), 10 deletions(-) commit e997ebbe46fe46bd4e8d476adca1f9b76779f270 Author: Michael Thalmeier <michael.thalmeier@hale.at> Date: Fri Mar 25 15:46:51 2016 +0100 NFC: pn533: Send ATR_REQ only if NFC_PROTO_NFC_DEP bit is set Currently it is not possible to only poll for passive targets with the pn533 driver. To change this ATR_REQ is only sent when NFC_PROTO_NFC_DEP is explicitly requested in poll_protocols. As most implementations (e.g. neard) poll for all protocols that are reported to be supported by the adapter, this should not have much of an effect on current implementations. Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> drivers/nfc/pn533.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit ae95d7126104591348d37aaf78c8325967e02386 Merge: 03c5b53 183c948 Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 9 17:41:41 2016 -0400 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net commit 03c5b534185f9844c1b5fcfdbae2adc32821ec42 Author: Eric Dumazet <edumazet@google.com> Date: Sat Apr 9 08:01:13 2016 -0700 ipv6: fix inet6_lookup_listener() A stupid refactoring bug in inet6_lookup_listener() needs to be fixed in order to get proper SO_REUSEPORT behavior. Fixes: 3b24d854cb35 ("tcp/dccp: do not touch listener sk_refcnt under synflood") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Maciej Żenczykowski <maze@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv6/inet6_hashtables.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d56f8994b6fb928f59481fabc25bcd1c2f9bd06d Author: Lee Jones <lee.jones@linaro.org> Date: Thu Feb 11 13:19:11 2016 -0800 clk: Provide OF helper to mark clocks as CRITICAL This call matches clocks which have been marked as critical in DT and sets the appropriate flag. These flags can then be used to mark the clock core flags appropriately prior to registration. Legacy bindings requiring this feature must add the clock-critical property to their binding descriptions, as it is not a part of common-clock binding. Cc: devicetree@vger.kernel.org Signed-off-by: Lee Jones <lee.jones@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Michael Turquette <mturquette@baylibre.com> Link: lkml.kernel.org/r/1455225554-13267-4-git-send-email-mturquette@baylibre.com drivers/clk/clk.c | 35 +++++++++++++++++++++++++++++++++++ include/linux/clk-provider.h | 8 +++++++- 2 files changed, 42 insertions(+), 1 deletion(-) commit 2e20fbf592621b2c2aeddd82e0fa3dad053cce03 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Feb 11 13:19:10 2016 -0800 clk: WARN_ON about to disable a critical clock Signed-off-by: Lee Jones <lee.jones@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Michael Turquette <mturquette@baylibre.com> Link: lkml.kernel.org/r/1455225554-13267-3-git-send-email-mturquette@baylibre.com drivers/clk/clk.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 32b9b10961860860268961d9aad0c56a73018c37 Author: Lee Jones <lee.jones@linaro.org> Date: Thu Feb 11 13:19:09 2016 -0800 clk: Allow clocks to be marked as CRITICAL Critical clocks are those which must not be gated, else undefined or catastrophic failure would occur. Here we have chosen to ensure the prepare/enable counts are correctly incremented, so as not to confuse users with enabled clocks with no visible users. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Michael Turquette <mturquette@baylibre.com> Link: lkml.kernel.org/r/1455225554-13267-2-git-send-email-mturquette@baylibre.com drivers/clk/clk.c | 5 +++++ include/linux/clk-provider.h | 1 + 2 files changed, 6 insertions(+) commit 44896beae605b93f2232301befccb7ef42953198 Author: Yong Li <yong.b.li@intel.com> Date: Thu Apr 7 12:56:32 2016 +0800 gpio: pca953x: add PCAL9535 interrupt support for Galileo Gen2 Galileo Gen2 board uses the PCAL9535 as the GPIO expansion, it is different from PCA9535 and includes interrupt mask/status registers, The current driver does not support the interrupt registers configuration, it causes some gpio pins cannot trigger interrupt events, this patch fix this issue. The original patch was submitted by Josef Ahmad <josef.ahmad@linux.intel.com> http://git.yoctoproject.org/cgit/cgit.cgi/meta-intel-quark/tree/recipes-kernel/linux/files/0015-Quark-GPIO-1-2-quark.patch Signed-off-by: Yong Li <yong.b.li@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-pca953x.c | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) commit 615d23f80efc60f8c5146223f305d19207c742e4 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Mon Apr 4 23:44:06 2016 +0530 gpio: zynq: Fix the error path pm_runtime_disable is called only in remove it is missed out in the error path. Fix the same. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-zynq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit bd37c999c7ca76afd4f28987314e98e022875dbc Author: Kelvin Cheung <keguang.zhang@gmail.com> Date: Wed Apr 6 20:34:53 2016 +0800 gpio: Loongson1: add Loongson1 GPIO driver This patch adds GPIO driver for Loongson1B. Signed-off-by: Kelvin Cheung <keguang.zhang@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 7 +++ drivers/gpio/Makefile | 1 + drivers/gpio/gpio-loongson1.c | 102 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 110 insertions(+) commit 6b5029d3ec86ee9558a1ab0b4b41a98e970e2204 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 5 16:49:57 2016 +0200 gpio: document open drain/source behaviour This has been a totally undocumented feature for years so add some generic concepts and documentation about open drain/source, include some facts on how we now support for hardware. Cc: Michael Hennerich <michael.hennerich@analog.com> Cc: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Cc: H. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/gpio/driver.txt | 89 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) commit 191227d99a281333b50aaf82ab4152fbfa249c19 Author: Daniel Mack <daniel@zonque.org> Date: Fri Apr 8 19:52:02 2016 +0200 ALSA: usb-audio: allow clock source validity interrupts miniDSP USBStreamer UAC2 devices send clock validity changes with the control field set to zero. The current interrupt handler ignores all packets if the control field does not match the mixer element's, but it really should only do that in case that field is needed to distinguish multiple elements with the same ID. This patch implements a logic that lets notifications packets pass if the element ID is unique for a given device. Signed-off-by: Daniel Mack <daniel@zonque.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/usb/mixer.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit cddaafb9a4a7b6d19030d2632107ba2aa068474d Author: Daniel Mack <daniel@zonque.org> Date: Sat Apr 9 11:21:46 2016 +0200 ALSA: usb-audio: add UAC2 clock sources as mixer controls UAC2 specifies clock sources that optionally have validity controls. This patch exposes them as mixer controls, so they can be read (and at least in theory even be written) by userspace applications in order to make clock selection policy decisions. This implementation does nothing if the device is not UAC2 compliant, or if the clock source does not define said validity control bits. Tested with a miniDSP USBStreamer (0x2752/0x0016). Signed-off-by: Daniel Mack <daniel@zonque.org> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/usb/mixer.c | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 68 insertions(+), 1 deletion(-) commit 5dd8e50c27cd9294e53fc4c4b25b86abc469a4d4 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sat Apr 9 10:57:57 2016 +0100 drm/i915: Replace manual barrier() with READ_ONCE() in HWS accessor When reading from the HWS page, we use barrier() to prevent the compiler optimising away the read from the volatile (may be updated by the GPU) memory address. This is more suited to READ_ONCE(); make it so. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460195877-20520-5-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 0d317ce99e226a338fe0962e711795c6a8ed2cb2 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sat Apr 9 10:57:56 2016 +0100 drm/i915: Use simplest form for flushing the single cacheline in the HWS Rather than call a function to compute the matching cachelines and clflush them, just call the clflush *instruction* directly. We also know that we can use the unpatched plain clflush rather than the clflushopt alternative. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Cc: Imre Deak <imre.deak@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460195877-20520-4-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 12471ba87a08bd1dd0aac18015d7782e02ea02de Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sat Apr 9 10:57:55 2016 +0100 drm/i915: Harden detection of missed interrupts Only declare a missed interrupt if we find that the GPU is idle with waiters and a hangcheck interval has passed in which no new user interrupts have been raised. v2: Clear the stuck interrupt marker between successful batches Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460195877-20520-3-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 11 ++++++---- drivers/gpu/drm/i915/i915_irq.c | 38 ++++++++++++++++++++++----------- drivers/gpu/drm/i915/intel_ringbuffer.h | 2 ++ 3 files changed, 35 insertions(+), 16 deletions(-) commit c04e0f3b4ea01b3b1d81ccfce0a73bb0b297ba46 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sat Apr 9 10:57:54 2016 +0100 drm/i915: Separate out the seqno-barrier from engine->get_seqno In order to simplify future patches, extract the lazy_coherency optimisation our of the engine->get_seqno() vfunc into its own callback. v2: Rename the barrier to engine->irq_seqno_barrier to try and better reflect that the barrier is only required after the user interrupt before reading the seqno (to ensure that the seqno update lands in time as we do not have strict seqno-irq ordering on all platforms). Reviewed-by: Dave Gordon <david.s.gordon@intel.com> [#v2] v3: Comments for hangcheck paranoia. Mika wanted to keep the extra barrier inside the hangcheck, just in case. I can argue that it doesn't provide a barrier against anything, but the side-effects of applying the barrier may prevent a false declaration of a hung GPU. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Cc: Dave Gordon <david.s.gordon@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460195877-20520-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 6 +++--- drivers/gpu/drm/i915/i915_drv.h | 12 ++++++++---- drivers/gpu/drm/i915/i915_gpu_error.c | 2 +- drivers/gpu/drm/i915/i915_irq.c | 14 ++++++++++++-- drivers/gpu/drm/i915/i915_trace.h | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 19 ++++++------------ drivers/gpu/drm/i915/intel_ringbuffer.c | 34 +++++++++++++++++---------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 4 ++-- 8 files changed, 51 insertions(+), 42 deletions(-) commit 9b9ed3093613288247a27a55a6dd07f1222150f1 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sat Apr 9 10:57:53 2016 +0100 drm/i915: Remove forcewake dance from seqno/irq barrier on legacy gen6+ In order to ensure seqno/irq coherency, we currently read a ring register. The mmio transaction following the interrupt delays the inspection of the seqno long enough for the MI_STORE_DWORD_IMM to update the CPU cache. However, it is only the memory timing that is important for the purposes of the delay, we do not need nor desire the extra forcewake. v3: Update commentary Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> [v2] Link: http://patchwork.freedesktop.org/patch/msgid/1460195877-20520-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 782f6bc0aba037436d6a04d19b23f8b61020a576 Author: Akash Goel <akash.goel@intel.com> Date: Fri Mar 11 14:56:42 2016 +0530 drm/i915: Fixup the free space logic in ring_prepare Currently for the case where there is enough space at the end of Ring buffer for accommodating only the base request, the wrapround is done immediately and as a result the base request gets added at the start of Ring buffer. But there may not be enough free space at the beginning to accommodate the base request, as before the wraparound, the wait was effectively done for the reserved_size free space from the start of Ring buffer. In such a case there is a potential of Ring buffer overflow, the instructions at the head of Ring (ACTHD) can get overwritten. Since the base request can fit in the remaining space, there is no need to wraparound immediately. The wraparound will anyway happen later when the reserved part starts getting used. Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Akash Goel <akash.goel@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1457688402-10411-1-git-send-email-akash.goel@intel.com Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: stable@vger.kernel.org drivers/gpu/drm/i915/intel_lrc.c | 6 +++--- drivers/gpu/drm/i915/intel_ringbuffer.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) commit 5305239312a5fcc50849e157a3178778c6914aa0 Author: Julia Lawall <Julia.Lawall@lip6.fr> Date: Sat Apr 9 10:36:15 2016 +0200 ALSA: constify ct_timer_ops structures The ct_timer_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/ctxfi/cttimer.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 498cd8e49509c761b39dab26be7f739d95940e16 Author: John Allen <jallen@linux.vnet.ibm.com> Date: Wed Apr 6 11:49:55 2016 -0500 ibmvnic: Enable use of multiple tx/rx scrqs Enables the use of multiple transmit and receive scrqs allowing the ibmvnic driver to take advantage of multiqueue functionality. To achieve this, the driver must implement the process of negotiating the maximum number of queues allowed by the server. Initially, the driver will attempt to login with the maximum number of tx and rx queues supported by the server. If the server fails to allocate the requested number of scrqs, it will return partial success in the login response. In this case, we must reinitiate the login process from the request capabilities stage and attempt to login requesting fewer scrqs. Signed-off-by: John Allen <jallen@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ibm/ibmvnic.c | 56 ++++++++++++++++++++++++-------------- drivers/net/ethernet/ibm/ibmvnic.h | 1 + 2 files changed, 37 insertions(+), 20 deletions(-) commit 8c92a75e5086e85000deeb05f6f852446c8f758a Author: Lukas Wunner <lukas@wunner.de> Date: Thu Mar 24 13:15:20 2016 +0100 acer-wmi: Use acpi_dev_found() Use shiny new acpi_dev_found() and remove all the boilerplate to search for a particular ACPI device. No functional change. Signed-off-by: Lukas Wunner <lukas@wunner.de> Reviewed-by: Lee, Chun-Yi <jlee@suse.com> Acked-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/platform/x86/acer-wmi.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) commit 9f9de69d754cc9f8f2d8c21bb92275d95ddb3c77 Author: Lukas Wunner <lukas@wunner.de> Date: Thu Mar 24 13:15:20 2016 +0100 eeepc-wmi: Use acpi_dev_found() Use shiny new acpi_dev_found() and remove all the boilerplate to search for a particular ACPI device. No functional change. Signed-off-by: Lukas Wunner <lukas@wunner.de> Acked-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/platform/x86/eeepc-wmi.c | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) commit c68ae33e7fb4a010f9a48af3e4b87089dca96551 Author: Lukas Wunner <lukas@wunner.de> Date: Thu Mar 24 13:15:20 2016 +0100 ACPI / utils: Rename acpi_dev_present() acpi_dev_present() was originally named after pci_dev_present() to signify the similarity of the two functions. However Rafael J. Wysocki pointed out that the exported function acpi_dev_present() is easily confused with the non-exported acpi_device_is_present(). Additionally in ACPI parlance the term "present" usually refers to the "device is present" bit returned by the _STA control method, yet acpi_dev_present() merely checks presence in the namespace. It does not invoke _STA at all, let alone check the "device is present" bit. As suggested by Rafael, rename the function to acpi_dev_found() and adjust all existing call sites. Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/utils.c | 6 +++--- include/acpi/acpi_bus.h | 2 +- include/linux/apple-gmux.h | 2 +- sound/pci/hda/thinkpad_helper.c | 2 +- sound/soc/intel/boards/cht_bsw_max98090_ti.c | 2 +- sound/soc/intel/boards/cht_bsw_rt5645.c | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) commit f4d05266032346531b9f889e26aa31a0cf2a9822 Author: Heikki Krogerus <heikki.krogerus@linux.intel.com> Date: Tue Mar 29 14:52:23 2016 +0300 device property: don't bother the drivers with struct property_set Since device_add_property_set() now always takes a copy of the property_set, and also since the fwnode type is always hard coded to be FWNODE_PDATA, there is no need for the drivers to deliver the entire struct property_set. The function can just create the instance of it on its own and bind the properties from the drivers to it on the spot. This renames device_add_property_set() to device_add_properties(). The function now takes struct property_entry as its parameter instead of struct property_set. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Thierry Reding <treding@nvidia.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-pxa/raumfeld.c | 12 ++++-------- arch/arm/mach-tegra/board-paz00.c | 6 +----- drivers/base/platform.c | 19 ++++++++++--------- drivers/base/property.c | 34 +++++++++++++++++++++------------- drivers/mfd/intel-lpss-acpi.c | 12 ++---------- drivers/mfd/intel-lpss-pci.c | 20 ++++---------------- drivers/mfd/intel-lpss.c | 2 +- drivers/mfd/intel-lpss.h | 4 ++-- drivers/mfd/mfd-core.c | 4 ++-- include/linux/mfd/core.h | 4 ++-- include/linux/platform_device.h | 6 +++--- include/linux/property.h | 15 +++------------ 12 files changed, 55 insertions(+), 83 deletions(-) commit 60438d9a1ef4176d79739efadee122afe92904b8 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 13:01:28 2016 +0800 tools/power/acpi: close file only if it is open The logic on the test for a valid fd to close is incorrect. This was just a mistake and was pointed out by Colin Ian King. Link: https://patchwork.kernel.org/patch/8620201/ Original-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> tools/power/acpi/tools/acpidbg/acpidbg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 3d4b7ae96d81dc8ed4ecd556118b632c2707ff08 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 10:43:08 2016 +0800 ACPI 2.0 / AML: Improve module level execution by moving the If/Else/While execution to per-table basis This experiment moves module level If/Else/While executions to per-table basis. If regressions are found against the enabling of this experimental improvement, this patch is the only one that should get bisected out. Please report the regressions to the kernel bugzilla for further root causing. Link: https://bugzilla.kernel.org/show_bug.cgi?id=112911 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Tested-by: Chris Bainbridge <chris.bainbridge@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/acpixf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fe6cbea0f096bfdb7eafdc7b937570cea8fca00e Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 10:43:00 2016 +0800 ACPI 2.0 / ECDT: Enable correct ECDT initialization order With wrong ECDT fixes reverted, it is possible to put ECDT probing before acpi_enable_subsystem(). But the ultimate purpose of ECDT re-enabling is to put the ECDT probing before the namespace initialization (acpi_load_tables()). This patch achieves this with protections so that we can enable it later when all necessary corrections are upstreamed. Link 4: https://bugzilla.kernel.org/show_bug.cgi?id=112911 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Tested-by: Chris Bainbridge <chris.bainbridge@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/bus.c | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) commit 59f0aa9480cfef9173a648cec4537addc5f3ad94 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 10:42:53 2016 +0800 ACPI 2.0 / ECDT: Remove early namespace reference from EC All operation region accesses are allowed by AML interpreter when AML is executed, so actually BIOSen are responsible to avoid the operation region accesses in AML before OSPM has prepared an operation region driver. This is done via _REG control method. So AML code normally sets a global named object REGC to 1 when _REG(3, 1) is evaluated. Then what is ECDT? Quoting from ACPI spec 6.0, 5.2.15 Embedded Controller Boot Resources Table (ECDT): "The presence of this table allows OSPM to provide Embedded Controller operation region space access before the namespace has been evaluated." Spec also suggests a compatible mean to indicate the early EC access availability: Device (EC) { Name (REGC, Ones) Method (_REG, 2) { If (LEqual (Arg0, 3)) { Store (Arg1, REGC) } } Method (ECAV) { If (LEqual (REGC, Ones)) { If (LGreaterEqual (_REV, 2)) { Return (One) } Else { Return (Zero) } } Else { Return (REGC) } } } In this way, it allows EC accesses to happen before EC._REG(3, 1) is invoked. But ECAV is not the only way practical BIOSen using to indicate the early EC access availibility, the known variations include: 1. Setting REGC to One in \_SB._INI when _REV >= 2. Since \_SB._INI is the first control method evaluated by OSPM during the enumeration, this allows EC accesses to happen for the entire enumeration process before the namespace EC is enumerated. 2. Initialize REGC to One by default, this even allows EC accesses to happen during the table loading. Linux is now broken around ECDT support during the long term bug fixing work because it has merged many wrong ECDT bug fixes (see details below). Linux currently uses namespace EC's settings instead of ECDT settings when ECDT is detected. This apparently will result in namespace walk and _CRS/_GPE/_REG evaluations. Such stuffs could only happen after namespace is ready, while ECDT is purposely to be used before namespace is ready. The wrong bug fixing story is: 1. Link 1: At Linux ACPI early stages, "no _Lxx/_Exx/_Qxx evaluation can happen before the namespace is ready" are not ensured by ACPICA core and Linux. This is currently ensured by deferred enabling of GPE and defered registering of EC query methods (acpi_ec_register_query_methods). 2. Link 2: Reporters reported buggy ECDTs, expecting quirks for the platform. Originally, the quirk is simple, only doing things with ECDT. Bug 9399 and 12461 are platforms (Asus L4R, Asus M6R, MSI MS-171F) reported to have wrong ECDT IO port addresses, the port addresses are reversed. Bug 11880 is a platform (Asus X50GL) reported to have 0 valued port addresses, we can see that all EC accesses are protected by ECAV on this platform, so actually no early EC accesses is required by this platform. 3. Link 3: But when the bug fixing developer was requested to provide a handy and non-quirk bug fix, he tried to use correct EC settings from namespace and broke the spec purpose. We can even see that the developer was suffered from many regrssions. One interesting one is 14086, where the actual root cause obviously should be: _REG is evaluated too early. But unfortunately, the bug is fixed in a totally wrong way. So everything goes wrong from these commits: Commit: c6cb0e878446c79f42e7833d7bb69ed6bfbb381f Subject: ACPI: EC: Don't trust ECDT tables from ASUS Commit: a5032bfdd9c80e0231a6324661e123818eb46ecd Subject: ACPI: EC: Always parse EC device This patch reverts Linux behavior to simple ECDT quirk support in order to stop early _CRS/_GPE/_REG evaluations. For Bug 9399, 12461, since it is reported that the platforms require early EC accesses, this patch restores the simple ECDT quirks for them. For Bug 11880, since it is not reported that the platform requires early EC accesses and its ACPI tables contain correct ECAV, we choose an ECDT enumeration failure for this platform. Link 1: https://bugzilla.kernel.org/show_bug.cgi?id=9916 http://bugzilla.kernel.org/show_bug.cgi?id=10100 https://lkml.org/lkml/2008/2/25/282 Link 2: https://bugzilla.kernel.org/show_bug.cgi?id=9399 https://bugzilla.kernel.org/show_bug.cgi?id=12461 https://bugzilla.kernel.org/show_bug.cgi?id=11880 Link 3: https://bugzilla.kernel.org/show_bug.cgi?id=11884 https://bugzilla.kernel.org/show_bug.cgi?id=14081 https://bugzilla.kernel.org/show_bug.cgi?id=14086 https://bugzilla.kernel.org/show_bug.cgi?id=14446 Link 4: https://bugzilla.kernel.org/show_bug.cgi?id=112911 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Tested-by: Chris Bainbridge <chris.bainbridge@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/ec.c | 145 ++++++++++++++++++++---------------------------------- 1 file changed, 54 insertions(+), 91 deletions(-) commit 0e1affe41bdd7b1bef64c007d260e142bcaef220 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 10:42:47 2016 +0800 ACPI 2.0 / ECDT: Split EC_FLAGS_HANDLERS_INSTALLED This patch splits EC_FLAGS_HANDLERS_INSTALLED so that address space handler can be installed when it is not possible to install GPE handler during early stage. This patch also tunes address space handler installation, making it happening earlier than GPE handler installation for the same purpose. Since acpi_ec_start()/acpi_ec_stop() will be entered multiple times after applying this change, it is also required to protect acpi_enable_gpe()/ acpi_disable_gpe() invocations. Link: https://bugzilla.kernel.org/show_bug.cgi?id=112911 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Tested-by: Chris Bainbridge <chris.bainbridge@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/ec.c | 96 +++++++++++++++++++++++++++++++------------------------ 1 file changed, 55 insertions(+), 41 deletions(-) commit 5dcef694860100fd16885f052591b1268b764d21 Author: Len Brown <len.brown@intel.com> Date: Wed Apr 6 17:00:47 2016 -0400 intel_idle: add BXT support Broxton has all the HSW C-states, except C3. BXT C-state timing is slightly different. Here we trust the IRTL MSRs as authority on maximum C-state latency, and override the driver's tables with the values found in the associated IRTL MSRs. Further we set the target_residency to 1x maximum latency, trusting the hardware demotion logic. Signed-off-by: Len Brown <len.brown@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/include/asm/msr-index.h | 8 +++ drivers/idle/intel_idle.c | 137 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 145 insertions(+) commit c998c07836f985b24361629dc98506ec7893e7a0 Author: Dave Gerlach <d-gerlach@ti.com> Date: Tue Apr 5 14:05:38 2016 -0500 cpuidle: Indicate when a device has been unregistered Currently the 'registered' member of the cpuidle_device struct is set to 1 during cpuidle_register_device. In this same function there are checks to see if the device is already registered to prevent duplicate calls to register the device, but this value is never set to 0 even on unregister of the device. Because of this, any attempt to call cpuidle_register_device after a call to cpuidle_unregister_device will fail which shouldn't be the case. To prevent this, set registered to 0 when the device is unregistered. Fixes: c878a52d3c7c (cpuidle: Check if device is already registered) Signed-off-by: Dave Gerlach <d-gerlach@ti.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: All applicable <stable@vger.kernel.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpuidle/cpuidle.c | 2 ++ 1 file changed, 2 insertions(+) commit 1373718194ebebc43c00d8f117e03885749495b0 Author: Chen Yu <yu.c.chen@intel.com> Date: Tue Mar 22 08:51:10 2016 +0800 ACPI / PM: Introduce efi poweroff for HW-full platforms without _S5 The problem is Linux registers pm_power_off = efi_power_off only if we are in hardware reduced mode. Actually, what we also want is to do this when ACPI S5 is simply not supported on non-legacy platforms. Since some future Intel platforms are HW-full mode where the DSDT fails to supply an _S5 object(without SLP_TYP), we should let such kind of platform to leverage efi runtime service to poweroff. This patch uses efi power off as first choice when S5 is unavailable, even if there is a customized poweroff(driver provided, eg). Meanwhile, the legacy platforms will not be affected because there is no path for them to overwrite the pm_power_off to efi power off. Suggested-by: Len Brown <len.brown@intel.com> Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> Signed-off-by: Chen Yu <yu.c.chen@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/x86/platform/efi/quirks.c | 2 +- drivers/acpi/sleep.c | 7 +++++++ include/linux/acpi.h | 1 + 3 files changed, 9 insertions(+), 1 deletion(-) commit 3db80c230da15ceb1a526438b458058abcd53800 Author: Sinan Kaya <okaya@codeaurora.org> Date: Sun Feb 7 10:00:31 2016 -0500 ACPI: implement Generic Event Device Generic Event Device described in ACPI 6.1 allows platforms to handle platform interrupts in ACPI ASL statements. It borrows constructs like _EVT from GPIO events. All interrupts are listed in _CRS and the handler is written in _EVT method. Here is an example. Device (GED0) { Name (_HID, "ACPI0013") Name (_UID, 0) Name(_CRS, ResourceTemplate () { Interrupt(ResourceConsumer, Edge, ActiveHigh, Shared, , , ) {123} }) Method (_EVT, 1) { if (Lequal(123, Arg0)) { } } } Wake capability has not been implemented yet. Signed-off-by: Sinan Kaya <okaya@codeaurora.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/Makefile | 1 + drivers/acpi/evged.c | 156 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 157 insertions(+) commit 8cee1eed8e78143aa2ed60308fb88e2d6fa46205 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 7 14:06:57 2016 +0530 cpufreq: ACPI: Remove freq_table from acpi_cpufreq_data The freq-table is stored in struct cpufreq_policy also and there is absolutely no need of keeping a copy of its reference in struct acpi_cpufreq_data. Drop it. Also policy->freq_table can't be NULL in the target() callback, remove the useless check as well. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> [ rjw: Rebase ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/acpi-cpufreq.c | 63 +++++++++++++++++++++++------------------- 1 file changed, 34 insertions(+), 29 deletions(-) commit 9b55f55af8f017fec053c7eb0675241d057936da Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Thu Apr 7 14:06:58 2016 +0530 cpufreq: ACPI: policy->driver_data can't be NULL in ->exit() Its always set by ->init() and so it will always be there in ->exit(). There is no need to have a special check for just that. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> [ rjw: Rebase ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/acpi-cpufreq.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit a794d6138cda391b6a9ba28c4cf27651415669c6 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Apr 7 03:31:57 2016 +0200 cpufreq: Rearrange cpufreq_add_dev() Reorganize the code in cpufreq_add_dev() to avoid using the ret variable and reduce the indentation level in it. No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) commit cd73e9b01f635d25dbd17ed090f9351becf00280 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Apr 7 03:30:40 2016 +0200 cpufreq: Simplify switch () in cpufreq_cpu_callback() Merge two switch entries that do the same thing in cpufreq_cpu_callback(). No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 1c5864e26c99cf32b51e878f3daf73a388d7561a Author: Joe Perches <joe@perches.com> Date: Tue Apr 5 13:28:25 2016 -0700 cpufreq: Use consistent prefixing via pr_fmt Use the more common kernel style adding a define for pr_fmt. Miscellanea: o Remove now unused PFX defines Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/acpi-cpufreq.c | 8 ++--- drivers/cpufreq/cpufreq-nforce2.c | 20 +++++------ drivers/cpufreq/e_powersaver.c | 38 ++++++++++---------- drivers/cpufreq/elanfreq.c | 2 ++ drivers/cpufreq/ia64-acpi-cpufreq.c | 5 +-- drivers/cpufreq/longhaul.c | 60 +++++++++++++++---------------- drivers/cpufreq/loongson2_cpufreq.c | 7 ++-- drivers/cpufreq/maple-cpufreq.c | 6 ++-- drivers/cpufreq/omap-cpufreq.c | 5 ++- drivers/cpufreq/p4-clockmod.c | 10 +++--- drivers/cpufreq/pmac32-cpufreq.c | 8 +++-- drivers/cpufreq/pmac64-cpufreq.c | 28 ++++++++------- drivers/cpufreq/powernow-k6.c | 15 ++++---- drivers/cpufreq/powernow-k7.c | 43 +++++++++++----------- drivers/cpufreq/pxa2xx-cpufreq.c | 13 +++---- drivers/cpufreq/s3c2412-cpufreq.c | 14 ++++---- drivers/cpufreq/s3c2440-cpufreq.c | 2 ++ drivers/cpufreq/s3c24xx-cpufreq-debugfs.c | 2 ++ drivers/cpufreq/s3c24xx-cpufreq.c | 8 +++-- drivers/cpufreq/s5pv210-cpufreq.c | 6 ++-- drivers/cpufreq/sc520_freq.c | 6 ++-- drivers/cpufreq/speedstep-centrino.c | 5 +-- drivers/cpufreq/speedstep-ich.c | 8 +++-- drivers/cpufreq/speedstep-lib.c | 4 ++- drivers/cpufreq/speedstep-smi.c | 4 ++- 25 files changed, 181 insertions(+), 146 deletions(-) commit b49c22a6ca3656c68506fea57caf3d8f08878570 Author: Joe Perches <joe@perches.com> Date: Tue Apr 5 13:28:24 2016 -0700 cpufreq: Convert printk(KERN_<LEVEL> to pr_<level> Use the more common logging style. Miscellanea: o Coalesce formats o Realign arguments o Add a missing space between a coalesced format Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/acpi-cpufreq.c | 10 ++-- drivers/cpufreq/cpufreq-nforce2.c | 24 ++++------ drivers/cpufreq/e_powersaver.c | 60 ++++++++++------------- drivers/cpufreq/elanfreq.c | 2 +- drivers/cpufreq/ia64-acpi-cpufreq.c | 9 ++-- drivers/cpufreq/longhaul.c | 80 +++++++++++++------------------ drivers/cpufreq/loongson2_cpufreq.c | 2 +- drivers/cpufreq/maple-cpufreq.c | 9 ++-- drivers/cpufreq/omap-cpufreq.c | 4 +- drivers/cpufreq/p4-clockmod.c | 15 ++---- drivers/cpufreq/pmac32-cpufreq.c | 12 ++--- drivers/cpufreq/pmac64-cpufreq.c | 43 ++++++++--------- drivers/cpufreq/powernow-k6.c | 13 ++--- drivers/cpufreq/powernow-k7.c | 65 ++++++++++--------------- drivers/cpufreq/pxa2xx-cpufreq.c | 7 ++- drivers/cpufreq/s3c2412-cpufreq.c | 13 +++-- drivers/cpufreq/s3c2440-cpufreq.c | 4 +- drivers/cpufreq/s3c24xx-cpufreq-debugfs.c | 2 +- drivers/cpufreq/s3c24xx-cpufreq.c | 57 +++++++++++----------- drivers/cpufreq/s5pv210-cpufreq.c | 4 +- drivers/cpufreq/sc520_freq.c | 6 +-- drivers/cpufreq/speedstep-centrino.c | 3 +- drivers/cpufreq/speedstep-ich.c | 6 +-- drivers/cpufreq/speedstep-lib.c | 9 ++-- drivers/cpufreq/speedstep-smi.c | 5 +- 25 files changed, 199 insertions(+), 265 deletions(-) commit 4836df173aaed4b93e4d4b5c51e40f12e53ea26f Author: Joe Perches <joe@perches.com> Date: Tue Apr 5 13:28:23 2016 -0700 intel_pstate: Use pr_fmt Prefix the output using the more common kernel style. Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> [ rjw: Rebase ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) commit d2499d05f0f286a754c26e2bda62210d6a65a774 Author: Geliang Tang <geliangtang@163.com> Date: Tue Apr 5 10:38:06 2016 +0800 cpufreq: mt8173: use list_for_each_entry*() Use list_for_each_entry*() instead of list_for_each*() to simplify the code. Signed-off-by: Geliang Tang <geliangtang@163.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/mt8173-cpufreq.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) commit 22590efb98ae0c84f798a9938c0b6d97bc89adf5 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat Apr 9 01:25:58 2016 +0200 intel_pstate: Avoid pointless FRAC_BITS shifts under div_fp() There are multiple places in intel_pstate where int_tofp() is applied to both arguments of div_fp(), but this is pointless, because int_tofp() simply shifts its argument to the left by FRAC_BITS which mathematically is equivalent to multuplication by 2^FRAC_BITS, so if this is done to both arguments of a division, the extra factors will cancel each other during that operation anyway. Drop the pointless int_tofp() applied to div_fp() arguments throughout the driver. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/intel_pstate.c | 31 +++++++++++++------------------ 1 file changed, 13 insertions(+), 18 deletions(-) commit 2249c00a0bf854adf49e8e3c2973feddfbaae71f Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Mar 30 13:45:28 2016 +0530 cpufreq: exynos: Use generic platdev driver The cpufreq-dt-platdev driver supports creation of cpufreq-dt platform device now, reuse that and remove similar code from platform code. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-exynos/exynos.c | 25 ------------------------- drivers/cpufreq/cpufreq-dt-platdev.c | 9 +++++++++ 2 files changed, 9 insertions(+), 25 deletions(-) commit ea3b05e62f097a604f4dbe7d3ab785a148b61e93 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Mar 30 13:45:27 2016 +0530 ARM: exynos: exynos-cpufreq platform device isn't supported anymore The driver is removed long back and we don't support this device anymore. Stop adding it. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> arch/arm/mach-exynos/exynos.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit f56aad1d98f1c0c6df513abcd275a4d914adc1ef Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Mar 30 13:45:26 2016 +0530 cpufreq: dt: Add generic platform-device creation support Multiple platforms are using the generic cpufreq-dt driver now, and all of them are required to create a platform device with name "cpufreq-dt", in order to get the cpufreq-dt probed. Many of them do it from platform code, others have special drivers just to do that. It would be more sensible to do this at a generic place, where all such platform can mark their entries. This patch adds a separate file to get this device created. Currently the compat list of platforms that we support is empty, and will be filled in as and when we move platforms to use it. It always compiles as part of the kernel and so doesn't need a module-exit operation. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/Kconfig | 10 ++++++++++ drivers/cpufreq/Makefile | 1 + drivers/cpufreq/cpufreq-dt-platdev.c | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 43 insertions(+) commit 7e67e239a4f32fa3e2d51dd9a7930018651635b6 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Wed Mar 30 13:45:25 2016 +0530 cpufreq: dt: Include types.h from cpufreq-dt.h cpufreq-dt.h uses 'bool' data type but doesn't include types.h. It works fine for now as the files that include cpufreq-dt.h, also include types.h directly or indirectly. But, when a file includes cpufreq-dt.h without including types.h, we get a build error. Avoid such errors by including types.h in cpufreq-dt itself. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/linux/cpufreq-dt.h | 2 ++ 1 file changed, 2 insertions(+) commit f3f24dea2c7fd949377dc512fe1bfd0b7419afa3 Author: Viresh Kumar <viresh.kumar@linaro.org> Date: Tue Mar 29 19:35:12 2016 +0530 cpufreq: tegra124: No need of setting platform-data All CPUs on Tegra platform share clock/voltage lines and there is absolutely no need of setting platform data for 'cpufreq-dt' platform device, as that's the default case. Stop setting platform data for cpufreq-dt device. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Tested-by: Thierry Reding <treding@nvidia.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/tegra124-cpufreq.c | 7 ------- 1 file changed, 7 deletions(-) commit dbbe972c112838bede8772c2a427c816e9f22839 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 18:08:17 2016 -0400 cpufreq: ppc_cbe_cpufreq_pmi: make the driver explicitly non-modular The Kconfig for this driver is currently: config CPU_FREQ_CBE_PMI bool "CBE frequency scaling using PMI interface" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular and unused code here, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> [ rjw: Changelog ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/cpufreq/ppc_cbe_cpufreq_pmi.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) commit 4b42fafc1cdc4aba38d4f147cb2f3f1a32cd4a15 Merge: b318556 6c9d9c8 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat Apr 9 01:08:02 2016 +0200 Merge branch 'pm-cpufreq-sched' into pm-cpufreq commit 8805eea2494a2837983bc4aaaf6842c89666ec25 Author: Maxim Zhukov <mussitantesmortem@gmail.com> Date: Fri Apr 8 23:54:51 2016 +0300 Bluetooth: hci_bcsp: fix code style This commit fixed: trailing "*/" trailing spaces mixed indent space between ~ and ( Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/hci_bcsp.c | 57 ++++++++++++++++++++++++-------------------- 1 file changed, 31 insertions(+), 26 deletions(-) commit e013b7780c41b471c4269ac9ccafb65ba7c9ec86 Merge: f453939 4d5770b Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 8 16:50:41 2016 -0400 Merge branch 'dsa-voidify-ops' Vivien Didelot says: ==================== net: dsa: voidify STP setter and FDB/VLAN add ops Neither the DSA layer nor the bridge code (see br_set_state) really care about eventual errors from STP state setters, so make it void. The DSA layer separates the prepare and commit phases of switchdev in two different functions. Logical errors must not happen in commit routines, so make them void. Changes v1 -> v2: - rename port_stp_update to port_stp_state_set - don't change code flow of bcm_sf2_sw_br_set_stp_state - prefer netdev_err over netdev_warn ==================== Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> commit 4d5770b39710180644f655b2c6cb0c880d108c63 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Wed Apr 6 11:55:05 2016 -0400 net: dsa: make the VLAN add function return void The switchdev design implies that a software error should not happen in the commit phase since it must have been previously reported in the prepare phase. If an hardware error occurs during the commit phase, there is nothing switchdev can do about it. The DSA layer separates port_vlan_prepare and port_vlan_add for simplicity and convenience. If an hardware error occurs during the commit phase, there is no need to report it outside the driver itself. Make the DSA port_vlan_add routine return void for explicitness. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 26 +++++++++++--------------- drivers/net/dsa/mv88e6xxx.h | 6 +++--- include/net/dsa.h | 2 +- net/dsa/slave.c | 11 +++-------- 4 files changed, 18 insertions(+), 27 deletions(-) commit 8497aa618dd605b084fae86e676ea23ca85558b5 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Wed Apr 6 11:55:04 2016 -0400 net: dsa: make the FDB add function return void The switchdev design implies that a software error should not happen in the commit phase since it must have been previously reported in the prepare phase. If an hardware error occurs during the commit phase, there is nothing switchdev can do about it. The DSA layer separates port_fdb_prepare and port_fdb_add for simplicity and convenience. If an hardware error occurs during the commit phase, there is no need to report it outside the DSA driver itself. Make the DSA port_fdb_add routine return void for explicitness. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/bcm_sf2.c | 9 +++++---- drivers/net/dsa/mv88e6xxx.c | 12 +++++------- drivers/net/dsa/mv88e6xxx.h | 6 +++--- include/net/dsa.h | 2 +- net/dsa/slave.c | 16 ++++++++-------- 5 files changed, 22 insertions(+), 23 deletions(-) commit 43c44a9f655170fb92536167b95b1c6ae8b732cb Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Wed Apr 6 11:55:03 2016 -0400 net: dsa: make the STP state function return void The DSA layer doesn't care about the return code of the port_stp_update routine, so make it void in the layer and the DSA drivers. Replace the useless dsa_slave_stp_update function with a dsa_slave_stp_state function used to reply to the switchdev SWITCHDEV_ATTR_ID_PORT_STP_STATE attribute. In the meantime, rename port_stp_update to port_stp_state_set to explicit the state change. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/dsa.txt | 2 +- drivers/net/dsa/bcm_sf2.c | 16 ++++++---------- drivers/net/dsa/mv88e6171.c | 2 +- drivers/net/dsa/mv88e6352.c | 2 +- drivers/net/dsa/mv88e6xxx.c | 6 ++---- drivers/net/dsa/mv88e6xxx.h | 2 +- include/net/dsa.h | 4 ++-- net/dsa/slave.c | 32 +++++++++++++++----------------- 8 files changed, 29 insertions(+), 37 deletions(-) commit f453939c1a4a758312f799748b344bacd1db701f Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Wed Apr 6 11:06:20 2016 -0400 net: dsa: document missing functions Add description for the missing port_vlan_prepare, port_fdb_prepare, port_fdb_dump functions in the DSA documentation. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/dsa/dsa.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 1089ac69776795074edb48ac15b8f6a36933bc0e Merge: 0701615 4ce2bd9 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 8 16:42:31 2016 -0400 Merge tag 'mac80211-next-for-davem-2016-04-06' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next Johannes Berg says: ==================== For the 4.7 cycle, we have a number of changes: * Bob's mesh mode rhashtable conversion, this includes the rhashtable API change for allocation flags * BSSID scan, connect() command reassoc support (Jouni) * fast (optimised data only) and support for RSS in mac80211 (myself) * various smaller changes ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 6c9d9c81924b4b63c7a487e90fddb3b2d0f7d458 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Thu Apr 7 23:38:46 2016 +0200 cpufreq: Call cpufreq_disable_fast_switch() in sugov_exit() Due to differences in the cpufreq core's handling of runtime CPU offline and nonboot CPUs disabling during system suspend-to-RAM, fast frequency switching gets disabled after a suspend-to-RAM and resume cycle on all of the nonboot CPUs. To prevent that from happening, move the invocation of cpufreq_disable_fast_switch() from cpufreq_exit_governor() to sugov_exit(), as the schedutil governor is the only user of fast frequency switching today anyway. That simply prevents cpufreq_disable_fast_switch() from being called without invoking the ->governor callback for the CPUFREQ_GOV_POLICY_EXIT event (which happens during system suspend now). Fixes: b7898fda5bc7 (cpufreq: Support for fast frequency switching) Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq.c | 19 +++++++++++-------- include/linux/cpufreq.h | 1 + kernel/sched/cpufreq_schedutil.c | 2 ++ 3 files changed, 14 insertions(+), 8 deletions(-) commit 88a97da1eab7587036d8bc937d6bc874b8210df1 Author: Jon Derrick <jonathan.derrick@intel.com> Date: Fri Apr 8 11:35:51 2016 -0600 PCI: Remove return values from pcie_port_platform_notify() and relatives Now that pcie_port_acpi_setup() always returns 0, make it and its callers void functions and stop checking the return values. [bhelgaas: changelog] Signed-off-by: Jon Derrick <jonathan.derrick@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pcie/portdrv.h | 11 ++++------- drivers/pci/pcie/portdrv_acpi.c | 10 ++++------ drivers/pci/pcie/portdrv_core.c | 8 ++------ 3 files changed, 10 insertions(+), 19 deletions(-) commit 07016151a446d25397b24588df4ed5cf777a69bb Author: Daniel Borkmann <daniel@iogearbox.net> Date: Tue Apr 5 22:33:17 2016 +0200 bpf, verifier: further improve search pruning The verifier needs to go through every path of the program in order to check that it terminates safely, which can be quite a lot of instructions that need to be processed f.e. in cases with more branchy programs. With search pruning from f1bca824dabb ("bpf: add search pruning optimization to verifier") the search space can already be reduced significantly when the verifier detects that a previously walked path with same register and stack contents terminated already (see verifier's states_equal()), so the search can skip walking those states. When working with larger programs of > ~2000 (out of max 4096) insns, we found that the current limit of 32k instructions is easily hit. For example, a case we ran into is that the search space cannot be pruned due to branches at the beginning of the program that make use of certain stack space slots (STACK_MISC), which are never used in the remaining program (STACK_INVALID). Therefore, the verifier needs to walk paths for the slots in STACK_INVALID state, but also all remaining paths with a stack structure, where the slots are in STACK_MISC, which can nearly double the search space needed. After various experiments, we find that a limit of 64k processed insns is a more reasonable choice when dealing with larger programs in practice. This still allows to reject extreme crafted cases that can have a much higher complexity (f.e. > ~300k) within the 4096 insns limit due to search pruning not being able to take effect. Furthermore, we found that a lot of states can be pruned after a call instruction, f.e. we were able to reduce the search state by ~35% in some cases with this heuristic, trade-off is to keep a bit more states in env->explored_states. Usually, call instructions have a number of preceding register assignments and/or stack stores, where search pruning has a better chance to suceed in states_equal() test. The current code marks the branch targets with STATE_LIST_MARK in case of conditional jumps, and the next (t + 1) instruction in case of unconditional jump so that f.e. a backjump will walk it. We also did experiments with using t + insns[t].off + 1 as a marker in the unconditionally jump case instead of t + 1 with the rationale that these two branches of execution that converge after the label might have more potential of pruning. We found that it was a bit better, but not necessarily significantly better than the current state, perhaps also due to clang not generating back jumps often. Hence, we left that as is for now. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/bpf/verifier.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 52966bd1c2a09fdd3149f00568cc18f45cc09785 Author: Jon Derrick <jonathan.derrick@intel.com> Date: Fri Apr 8 14:44:24 2016 -0500 PCI/ACPI: Allow all PCIe services on non-ACPI host bridges Host bridges we discover via ACPI, i.e., PNP0A03 and PNP0A08 devices, may have an _OSC method by which the OS can ask the platform for control of PCIe features like native hotplug, power management events, AER, etc. Previously, if we found a bridge without an ACPI device, we assumed we did not have permission to use any of these PCIe features. That seems unreasonably restrictive. If we find no ACPI device, assume we can take control of all PCIe features. The Intel Volume Management Device (VMD) is one such bridge with no ACPI device. Prior to this change, users had to boot with "pcie_ports=native" to get hotplug and other services to work below the VMD Root Port. [bhelgaas: changelog] Suggested-by: Bjorn Helgaas <helgaas@kernel.org> Signed-off-by: Jon Derrick <jonathan.derrick@intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/pcie/portdrv_acpi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1fc2257e837f86c2688fdcc5c8810b73c133794d Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:12:48 2016 +0200 devlink: share user_ptr pointer for both devlink and devlink_port Ptr to devlink structure can be easily obtained from devlink_port->devlink. So share user_ptr[0] pointer for both and leave user_ptr[1] free for other users. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/devlink.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 67b5b21f389502c3fb18b46d4fa9d02c38982fce Merge: 24d390b 9efc8f6 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 8 15:38:43 2016 -0400 Merge branch 'mlxsw-next' Jiri Pirko says: ==================== mlxsw: small driver update + one tiny devlink dependency Cosmetics, in preparation to sharedbuffer patchset. First patch is here to allow patch number two. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 9efc8f655c8488c6ee2f7d5034826880bf5b4bba Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:25 2016 +0200 mlxsw: reg: Fix SBPM register name Fix copy&paste error and state the name of SBPM register correctly. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 497e8592c6d22772d0ad100c1f08e601dc417ed5 Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:24 2016 +0200 mlxsw: reg: Share direction enum between SBPR, SBCM, SBPM Same field, same values, so share the same enum. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 23 +++++++--------------- .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 20 +++++++++---------- 2 files changed, 17 insertions(+), 26 deletions(-) commit b2f10571b96414986f7293b06847d202f2d1d0ca Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:23 2016 +0200 mlxsw: Do not pass around driver_priv directly Instead of that, pass mlxsw_core and use a helper to get driver priv from driver code. Looks much cleaner that way. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 19 +++++++++++-------- drivers/net/ethernet/mellanox/mlxsw/core.h | 11 +++++++---- drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 17 +++++++++-------- drivers/net/ethernet/mellanox/mlxsw/switchx2.c | 8 ++++---- 4 files changed, 31 insertions(+), 24 deletions(-) commit 307c2431abf0974996356c13b67432f4b35e5f2f Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:22 2016 +0200 mlxsw: Pass mlxsw_core as a param of mlxsw_core_skb_transmit* Instead of passing around driver priv, pass struct mlxsw_core * directly. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 15 +++------------ drivers/net/ethernet/mellanox/mlxsw/core.h | 5 ++--- drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 4 ++-- drivers/net/ethernet/mellanox/mlxsw/switchx2.c | 4 ++-- 4 files changed, 9 insertions(+), 19 deletions(-) commit 932762b69a282d3fa12febc1a02628f0fb79a1b8 Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:21 2016 +0200 mlxsw: Move devlink port registration into common core code Remove devlink port reg/unreg from spectrum and switchx2 code and rather do the common work in core. That also ensures code separation where devlink is only used in core.c. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Reviewed-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/core.c | 22 ++++++++++++++++++ drivers/net/ethernet/mellanox/mlxsw/core.h | 10 +++++++++ drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 31 +++++++++----------------- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 3 +-- drivers/net/ethernet/mellanox/mlxsw/switchx2.c | 30 +++++++++---------------- 5 files changed, 55 insertions(+), 41 deletions(-) commit a9844881ba19d15d274bd684d4de0758bbd71c90 Author: Jiri Pirko <jiri@mellanox.com> Date: Fri Apr 8 19:11:20 2016 +0200 devlink: remove implicit type set in port register As we rely on caller zeroing or correctly set the struct before the call, this implicit type set is either no-op (DEVLINK_PORT_TYPE_NOTSET is 0) or it rewrites wanted value. So remove this. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/devlink.c | 1 - 1 file changed, 1 deletion(-) commit 24d390b2acea6c8cd7c95a9204f23eb15cec8269 Merge: 70f767d cc7c033 Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 8 15:26:07 2016 -0400 Merge branch 'nfp-mtu-buffer-reconfig' Jakub Kicinski says: ==================== MTU/buffer reconfig changes I re-discussed MPLS/MTU internally, dropped it from the patch 1, re-tested everything, found out I forgot about debugfs pointers, fixed that as well. v5: - don't reserve space in RX buffers for MPLS label stack (patch 1); - fix debugfs pointers to ring structures (patch 5). v4: - cut down on unrelated patches; - don't "close" the device on error path. --- v4 cover letter Previous series included some not entirely related patches, this one is cut down. Main issue I'm trying to solve here is that .ndo_change_mtu() in nfpvf driver is doing full close/open to reallocate buffers - which if open fails can result in device being basically closed even though the interface is started. As suggested by you I try to move towards a paradigm where the resources are allocated first and the MTU change is only done once I'm certain (almost) nothing can fail. Almost because I need to communicate with FW and that can always time out. Patch 1 fixes small issue. Next 10 patches reorganize things so that I can easily allocate new rings and sets of buffers while the device is running. Patches 13 and 15 reshape the .ndo_change_mtu() and ethtool's ring-resize operation into desired form. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit cc7c033330fd67dd9d66a1ccb8c9d42381107bcd Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:48 2016 +0100 nfp: allow ring size reconfiguration at runtime Since much of the required changes have already been made for changing MTU at runtime let's use it for ring size changes as well. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net.h | 1 + .../net/ethernet/netronome/nfp/nfp_net_common.c | 126 +++++++++++++++++++++ .../net/ethernet/netronome/nfp/nfp_net_ethtool.c | 30 ++--- 3 files changed, 136 insertions(+), 21 deletions(-) commit a98cb2581211023539887a11f8391dd615409ab8 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:47 2016 +0100 nfp: pass ring count as function parameter Soon ring resize will call this functions with values different than the current configuration we need to explicitly pass the ring count as parameter. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 23 +++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) commit 36a857e4f2c9783cd573c948df022011cb386aa4 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:46 2016 +0100 nfp: convert .ndo_change_mtu() to prepare/commit paradigm When changing MTU on running device first allocate new rings and buffers and once it succeeds proceed with changing MTU. Allocation of new rings is not really necessary for this operation - it's done to keep the code simple and because size of the extra ring memory is quite small compared to the size of buffers. Operation can still fail midway through if FW communication times out. In that case we retry with old MTU (rings). Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 108 +++++++++++++++++++-- 1 file changed, 102 insertions(+), 6 deletions(-) commit 30d2117191b7437b5b6ce2f09eddf86f203c7a37 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:45 2016 +0100 nfp: propagate list buffer size in struct rx_ring Free list buffer size needs to be propagated to few functions as a parameter and added to struct nfp_net_rx_ring since soon some of the functions will be reused to manage rings with buffers of size different than nn->fl_bufsz. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net.h | 3 +++ .../net/ethernet/netronome/nfp/nfp_net_common.c | 24 ++++++++++++++-------- 2 files changed, 19 insertions(+), 8 deletions(-) commit aba52df80b1a2d15fe1745dfe187e9823821f5c0 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:44 2016 +0100 nfp: sync ring state during FW reconfiguration FW reconfiguration in .ndo_open()/.ndo_stop() should reset/ restore queue state. Since we need IRQs to be disabled when filling rings on RX path we have to move disable_irq() from .ndo_open() all the way up to IRQ allocation. nfp_net_start_vec() becomes trivial now so it's inlined. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 45 ++++++++-------------- 1 file changed, 16 insertions(+), 29 deletions(-) commit 1cd0cfc498f7e928c5ff8e9ced537d41fa46df50 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:43 2016 +0100 nfp: slice .ndo_open() and .ndo_stop() up Divide .ndo_open() and .ndo_stop() into logical, callable chunks. No functional changes. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 218 +++++++++++++-------- 1 file changed, 136 insertions(+), 82 deletions(-) commit ca40feab8f3d46a69bde7a13d652db2c9246c067 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:42 2016 +0100 nfp: move filling ring information to FW config nfp_net_[rt]x_ring_{alloc,free} should only allocate or free ring resources without touching the device. Move setting parameters in the BAR to separate functions. This will make it possible to reuse alloc/free functions to allocate new rings while the device is running. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 50 ++++++++++++++-------- 1 file changed, 32 insertions(+), 18 deletions(-) commit 114bdef0be28aa9aa71e291d133e79edd514f8dc Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:41 2016 +0100 nfp: preallocate RX buffers early in .ndo_open We want the .ndo_open() to have following structure: - allocate resources; - configure HW/FW; - enable the device from stack perspective. Therefore filling RX rings needs to be moved to the beginning of .ndo_open(). Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 34 +++++++--------------- 1 file changed, 11 insertions(+), 23 deletions(-) commit 1934680f5582b69a708181741cd77473a0d530ed Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:40 2016 +0100 nfp: reorganize initial filling of RX rings Separate allocation of buffers from giving them to FW, thanks to this it will be possible to move allocation earlier on .ndo_open() path and reuse buffers during runtime reconfiguration. Similar to TX side clean up the spill of functionality from flush to freeing the ring. Unlike on TX side, RX ring reset does not free buffers from the ring. Ring reset means only that FW pointers are zeroed and buffers on the ring must be placed in [0, cnt - 1) positions. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 119 ++++++++++++++------- 1 file changed, 78 insertions(+), 41 deletions(-) commit 827deea9bcd8fec3b6c0acf0178a5c508f3dfbe1 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:39 2016 +0100 nfp: cleanup tx ring flush and rename to reset Since we never used flush without freeing the ring later the functionality of the two operations is mixed. Rename flush to ring reset and move there all the things which have to be done after FW ring state is cleared. While at it do some clean-ups. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 81 ++++++++++------------ 1 file changed, 37 insertions(+), 44 deletions(-) commit 73725d9dfd99c5bb1da4d25bbe980231aa48d251 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:38 2016 +0100 nfp: allocate ring SW structs dynamically To be able to switch rings more easily on config changes allocate them dynamically, separately from nfp_net structure. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net.h | 6 ++--- .../net/ethernet/netronome/nfp/nfp_net_common.c | 28 +++++++++++++++++----- .../net/ethernet/netronome/nfp/nfp_net_debugfs.c | 20 +++++++++------- 3 files changed, 37 insertions(+), 17 deletions(-) commit d79737c25e4a170e7cd75866e45042de746934d8 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:37 2016 +0100 nfp: make *x_ring_init do all the init nfp_net_[rt]x_ring_init functions used to be called from probe path only and some of their functionality was spilled to the call site. In order to reuse them for ring reconfiguration we need them to do all the init. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 28 ++++++++++++++-------- 1 file changed, 18 insertions(+), 10 deletions(-) commit 0afbfb183bf5e1029ecc644acbc487d22e095b14 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:36 2016 +0100 nfp: break up nfp_net_{alloc|free}_rings nfp_net_{alloc|free}_rings contained strange mix of allocations and vector initialization. Remove it, declare vector init as a separate function and handle allocations explicitly. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 126 ++++++++------------- 1 file changed, 47 insertions(+), 79 deletions(-) commit 0ba40af963f01b557a4d7a0a6c550a51b0fb8d34 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:35 2016 +0100 nfp: move link state interrupt request/free calls We need to be able to disable the link state interrupt when the device is brought down. We used to just free the IRQ at the beginning of .ndo_stop(). As we now move towards more ordered .ndo_open()/.ndo_stop() paths LSC allocation should be placed in the "allocate resource" section. Since the IRQ can't be freed early in .ndo_stop(), it is disabled instead. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/netronome/nfp/nfp_net_common.c | 23 +++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) commit ff1b68ab2daf292c0f0897f9c155a6ddc8484693 Author: Jakub Kicinski <jakub.kicinski@netronome.com> Date: Thu Apr 7 19:39:34 2016 +0100 nfp: correct RX buffer length calculation When calculating the RX buffer length we need to account for up to 2 VLAN tags. Rounding up to 1k is an relic of a distant past and can be removed. While at it also remove trivial print statement. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/netronome/nfp/nfp_net_common.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit cd9d7213d5f546d9c0795fdcffe4ce5bf63445fd Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Thu Apr 7 16:46:04 2016 +0530 ieee802154/adf7242: fix memory leak of firmware If the firmware upload or the firmware verification fails then we printed the error message and exited but we missed releasing the firmware. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Acked-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/net/ieee802154/adf7242.c | 2 ++ 1 file changed, 2 insertions(+) commit feb2add3235ca81dc5cd5d975490c707a24c9889 Author: Alexander Aring <aar@pengutronix.de> Date: Wed Mar 16 13:52:41 2016 +0100 6lowpan: iphc: fix handling of link-local compression This patch fixes handling in case of link-local address compression. A IPv6 link-local address is defined as fe80::/10 prefix which is also what ipv6_addr_type checks for link-local addresses. But IPHC compression for link-local addresses are for fe80::/64 types only. This patch adds additional checks for zero padded bits in case of link-local address compression to match on a fe80::/64 address only. Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/6lowpan/iphc.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 13407376b255325fa817798800117a839f3aa055 Author: Jiri Slaby <jslaby@suse.cz> Date: Sat Mar 19 11:49:43 2016 +0100 Bluetooth: vhci: purge unhandled skbs The write handler allocates skbs and queues them into data->readq. Read side should read them, if there is any. If there is none, skbs should be dropped by hdev->flush. But this happens only if the device is HCI_UP, i.e. hdev->power_on work was triggered already. When it was not, skbs stay allocated in the queue when /dev/vhci is closed. So purge the queue in ->release. Program to reproduce: #include <err.h> #include <fcntl.h> #include <stdio.h> #include <unistd.h> #include <sys/stat.h> #include <sys/types.h> #include <sys/uio.h> int main() { char buf[] = { 0xff, 0 }; struct iovec iov = { .iov_base = buf, .iov_len = sizeof(buf), }; int fd; while (1) { fd = open("/dev/vhci", O_RDWR); if (fd < 0) err(1, "open"); usleep(50); if (writev(fd, &iov, 1) < 0) err(1, "writev"); usleep(50); close(fd); } return 0; } Result: kmemleak: 4609 new suspected memory leaks unreferenced object 0xffff88059f4d5440 (size 232): comm "vhci", pid 1084, jiffies 4294912542 (age 37569.296s) hex dump (first 32 bytes): 20 f0 23 87 05 88 ff ff 20 f0 23 87 05 88 ff ff .#..... .#..... 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ backtrace: ... [<ffffffff81ece010>] __alloc_skb+0x0/0x5a0 [<ffffffffa021886c>] vhci_create_device+0x5c/0x580 [hci_vhci] [<ffffffffa0219436>] vhci_write+0x306/0x4c8 [hci_vhci] Fixes: 23424c0d31 (Bluetooth: Add support creating virtual AMP controllers) Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Cc: stable 3.13+ <stable@vger.kernel.org> drivers/bluetooth/hci_vhci.c | 1 + 1 file changed, 1 insertion(+) commit 373a32c848ae3a1c03618517cce85f9211a6facf Author: Jiri Slaby <jslaby@suse.cz> Date: Sat Mar 19 11:05:18 2016 +0100 Bluetooth: vhci: fix open_timeout vs. hdev race Both vhci_get_user and vhci_release race with open_timeout work. They both contain cancel_delayed_work_sync, but do not test whether the work actually created hdev or not. Since the work can be in progress and _sync will wait for finishing it, we can have data->hdev allocated when cancel_delayed_work_sync returns. But the call sites do 'if (data->hdev)' *before* cancel_delayed_work_sync. As a result: * vhci_get_user allocates a second hdev and puts it into data->hdev. The former is leaked. * vhci_release does not release data->hdev properly as it thinks there is none. Fix both cases by moving the actual test *after* the call to cancel_delayed_work_sync. This can be hit by this program: #include <err.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <time.h> #include <unistd.h> #include <sys/stat.h> #include <sys/types.h> int main(int argc, char **argv) { int fd; srand(time(NULL)); while (1) { const int delta = (rand() % 200 - 100) * 100; fd = open("/dev/vhci", O_RDWR); if (fd < 0) err(1, "open"); usleep(1000000 + delta); close(fd); } return 0; } And the result is: BUG: KASAN: use-after-free in skb_queue_tail+0x13e/0x150 at addr ffff88006b0c1228 Read of size 8 by task kworker/u13:1/32068 ============================================================================= BUG kmalloc-192 (Tainted: G E ): kasan: bad access detected ----------------------------------------------------------------------------- Disabling lock debugging due to kernel taint INFO: Allocated in vhci_open+0x50/0x330 [hci_vhci] age=260 cpu=3 pid=32040 ... kmem_cache_alloc_trace+0x150/0x190 vhci_open+0x50/0x330 [hci_vhci] misc_open+0x35b/0x4e0 chrdev_open+0x23b/0x510 ... INFO: Freed in vhci_release+0xa4/0xd0 [hci_vhci] age=9 cpu=2 pid=32040 ... __slab_free+0x204/0x310 vhci_release+0xa4/0xd0 [hci_vhci] ... INFO: Slab 0xffffea0001ac3000 objects=16 used=13 fp=0xffff88006b0c1e00 flags=0x5fffff80004080 INFO: Object 0xffff88006b0c1200 @offset=4608 fp=0xffff88006b0c0600 Bytes b4 ffff88006b0c11f0: 09 df 00 00 01 00 00 00 00 00 00 00 00 00 00 00 ................ Object ffff88006b0c1200: 00 06 0c 6b 00 88 ff ff 00 00 00 00 00 00 00 00 ...k............ Object ffff88006b0c1210: 10 12 0c 6b 00 88 ff ff 10 12 0c 6b 00 88 ff ff ...k.......k.... Object ffff88006b0c1220: c0 46 c2 6b 00 88 ff ff c0 46 c2 6b 00 88 ff ff .F.k.....F.k.... Object ffff88006b0c1230: 01 00 00 00 01 00 00 00 e0 ff ff ff 0f 00 00 00 ................ Object ffff88006b0c1240: 40 12 0c 6b 00 88 ff ff 40 12 0c 6b 00 88 ff ff @..k....@..k.... Object ffff88006b0c1250: 50 0d 6e a0 ff ff ff ff 00 02 00 00 00 00 ad de P.n............. Object ffff88006b0c1260: 00 00 00 00 00 00 00 00 ab 62 02 00 01 00 00 00 .........b...... Object ffff88006b0c1270: 90 b9 19 81 ff ff ff ff 38 12 0c 6b 00 88 ff ff ........8..k.... Object ffff88006b0c1280: 03 00 20 00 ff ff ff ff ff ff ff ff 00 00 00 00 .. ............. Object ffff88006b0c1290: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ Object ffff88006b0c12a0: 00 00 00 00 00 00 00 00 00 80 cd 3d 00 88 ff ff ...........=.... Object ffff88006b0c12b0: 00 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 . .............. Redzone ffff88006b0c12c0: bb bb bb bb bb bb bb bb ........ Padding ffff88006b0c13f8: 00 00 00 00 00 00 00 00 ........ CPU: 3 PID: 32068 Comm: kworker/u13:1 Tainted: G B E 4.4.6-0-default #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.8.1-0-g4adadbd-20151112_172657-sheep25 04/01/2014 Workqueue: hci0 hci_cmd_work [bluetooth] 00000000ffffffff ffffffff81926cfa ffff88006be37c68 ffff88006bc27180 ffff88006b0c1200 ffff88006b0c1234 ffffffff81577993 ffffffff82489320 ffff88006bc24240 0000000000000046 ffff88006a100000 000000026e51eb80 Call Trace: ... [<ffffffff81ec8ebe>] ? skb_queue_tail+0x13e/0x150 [<ffffffffa06e027c>] ? vhci_send_frame+0xac/0x100 [hci_vhci] [<ffffffffa0c61268>] ? hci_send_frame+0x188/0x320 [bluetooth] [<ffffffffa0c61515>] ? hci_cmd_work+0x115/0x310 [bluetooth] [<ffffffff811a1375>] ? process_one_work+0x815/0x1340 [<ffffffff811a1f85>] ? worker_thread+0xe5/0x11f0 [<ffffffff811a1ea0>] ? process_one_work+0x1340/0x1340 [<ffffffff811b3c68>] ? kthread+0x1c8/0x230 ... Memory state around the buggy address: ffff88006b0c1100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88006b0c1180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88006b0c1200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88006b0c1280: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff88006b0c1300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc Fixes: 23424c0d31 (Bluetooth: Add support creating virtual AMP controllers) Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: stable 3.13+ <stable@vger.kernel.org> drivers/bluetooth/hci_vhci.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit a164cee111085f9ee77f6038f006658249073523 Author: Patrik Flykt <patrik.flykt@linux.intel.com> Date: Thu Mar 24 16:04:15 2016 +0200 Bluetooth: Allow setting BT_SECURITY_FIPS with setsockopt Update the security level check to allow setting BT_SECURITY_FIPS for an L2CAP socket. Signed-off-by: Patrik Flykt <patrik.flykt@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/bluetooth/l2cap_sock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 84cb3df02aea4b00405521e67c4c67c2d525c364 Author: Loic Poulain <loic.poulain@intel.com> Date: Mon Apr 4 10:48:13 2016 +0200 Bluetooth: hci_ldisc: Fix null pointer derefence in case of early data HCI_UART_PROTO_SET flag is set before hci_uart_set_proto call. If we receive data from tty layer during this procedure, proto pointer may not be assigned yet, leading to null pointer dereference in rx method hci_uart_tty_receive. This patch fixes this issue by introducing HCI_UART_PROTO_READY flag in order to avoid any proto operation before proto opening and assignment. Signed-off-by: Loic Poulain <loic.poulain@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/hci_ldisc.c | 11 +++++++---- drivers/bluetooth/hci_uart.h | 1 + 2 files changed, 8 insertions(+), 4 deletions(-) commit 1dbfc59a931495b2e7bdc4e85886162a0b03235b Author: Loic Poulain <loic.poulain@intel.com> Date: Mon Apr 4 11:31:12 2016 +0200 Bluetooth: hci_bcm: Add BCM2E71 ACPI ID This ID is used at least by Asus T100-CHI. Signed-off-by: Loic Poulain <loic.poulain@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> drivers/bluetooth/hci_bcm.c | 1 + 1 file changed, 1 insertion(+) commit 56b40fbf61a247e23b50e426971148b2e50262e0 Author: Johan Hedberg <johan.hedberg@intel.com> Date: Thu Apr 7 21:01:27 2016 +0300 Bluetooth: Ignore unknown advertising packet types In case of buggy controllers send advertising packet types that we don't know of we should simply ignore them instead of trying to react to them in some (potentially wrong) way. Signed-off-by: Johan Hedberg <johan.hedberg@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/bluetooth/hci_event.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit f18ba58f538e44a701ad0b86d47bb57b917d7c0a Author: Johan Hedberg <johan.hedberg@intel.com> Date: Wed Apr 6 13:09:05 2016 +0300 Bluetooth: Fix setting NO_BREDR advertising flag If we're dealing with a single-mode controller or BR/EDR is disable for a dual-mode one, the NO_BREDR flag needs to be unconditionally present in the advertising data. This patch moves it out from behind an extra condition to be always set in the create_instance_adv_data() function if BR/EDR is disabled. Signed-off-by: Johan Hedberg <johan.hedberg@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> net/bluetooth/hci_request.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 19bf4d4f909d644110cb587545dc385044ac90a4 Author: Lukas Wunner <lukas@wunner.de> Date: Sun Mar 20 13:57:20 2016 +0100 thunderbolt: Support 1st gen Light Ridge controller Add support for the 1st gen Light Ridge controller, which is built into these systems: iMac12,1 2011 21.5" iMac12,2 2011 27" Macmini5,1 2011 i5 2.3 GHz Macmini5,2 2011 i5 2.5 GHz Macmini5,3 2011 i7 2.0 GHz MacBookPro8,1 2011 13" MacBookPro8,2 2011 15" MacBookPro8,3 2011 17" MacBookPro9,1 2012 15" MacBookPro9,2 2012 13" Light Ridge (CV82524) was the very first copper Thunderbolt controller, introduced 2010 alongside its fiber-optic cousin Light Peak (CVL2510). Consequently the chip suffers from some teething troubles: - MSI is broken for hotplug signaling on the downstream bridges: The chip just never sends an interrupt. It requests 32 MSIs for each of its six bridges and the pcieport driver only allocates one per bridge. However I've verified that even if 32 MSIs are allocated there's no interrupt on hotplug. The only option is thus to disable MSI, which is also what OS X does. Apparently all Thunderbolt chips up to revision 1 of Cactus Ridge 4C are plagued by this issue so quirk those as well. - The chip supports a maximum hop_count of 32, unlike its successors which support only 12. Fixup ring_interrupt_active() to cope with values >= 32. - Another peculiarity is that the chip supports a maximum of 13 ports whereas its successors support 12. However the additional port (#5) seems to be unusable as reading its TB_CFG_PORT config space results in TB_CFG_ERROR_INVALID_CONFIG_SPACE. Add a quirk to mark the port disabled on the root switch, assuming that's necessary on all Macs using this chip. Tested-by: Lukas Wunner <lukas@wunner.de> [MacBookPro9,1] Tested-by: William Brown <william@blackhats.net.au> [MacBookPro8,2] Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Andreas Noever <andreas.noever@gmail.com> drivers/pci/quirks.c | 29 ++++++++++++++++++++++++++++- drivers/thunderbolt/eeprom.c | 5 +++++ drivers/thunderbolt/nhi.c | 11 +++++++++-- drivers/thunderbolt/switch.c | 3 ++- 4 files changed, 44 insertions(+), 4 deletions(-) commit 70f767d3afa9b2cd447b3dfc33c2751833dce931 Merge: f871165 10ef00f Author: David S. Miller <davem@davemloft.net> Date: Fri Apr 8 12:13:30 2016 -0400 Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 10GbE Intel Wired LAN Driver Updates 2016-04-07 This series contains updates to ixgbe and ixgbevf. This entire series (except for one patch from Alex) comes from Mark and is mainly to add support for our new MAC (x550em_a). So let's get Alex's patch out of the way first before we cover Mark's many changes. Alex does his enable bulk free in transmit cleanup for ixgbe and ixgbevf, like his has done for all of our other drivers. First Mark cleans up registers that were not being used, so do some house cleaning. Then to avoid casting lan_id and func fields, just make them u8 since they only hold small values anyways. Found and fixed an issue where on read operations it could be possible to modify locations beyond the length passed in, so change the check to round up in the same way. Cleaned up the interface for issuing firmware commands to use a void * instead of a u32 * which eliminates a number of casts. Added support for the new MAC and provided method pointers and use them to access IOSF-attached devices, since the new MAC will also need a new access method. Added support for SFPs with an external retimer and for an SGMII backplane interface. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit aae20bb6b45e0666c63506053c40f71c0c34cba0 Author: Lukas Wunner <lukas@wunner.de> Date: Sun Mar 20 13:57:20 2016 +0100 thunderbolt: Fix typos and magic number Fix typo in tb_cfg_print_error() message. Fix bytecount in struct tb_drom_entry_port comment. Replace magic number in tb_switch_alloc(). Rename tb_sw_set_unpplugged() and TB_CAL_IECS to fix typos. [bhelgaas: no functional change intended] Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Andreas Noever <andreas.noever@gmail.com> drivers/thunderbolt/ctl.c | 2 +- drivers/thunderbolt/eeprom.c | 2 +- drivers/thunderbolt/switch.c | 10 +++++----- drivers/thunderbolt/tb.c | 2 +- drivers/thunderbolt/tb.h | 2 +- drivers/thunderbolt/tb_regs.h | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) commit 1d111406c6d91f4d7f6cc69a43e59546e8010aae Author: Lukas Wunner <lukas@wunner.de> Date: Sun Mar 20 13:57:20 2016 +0100 PCI: Add Intel Thunderbolt device IDs Intel Gen 1 and 2 chips use the same ID for NHI, bridges and switch. Gen 3 chips and onward use a distinct ID for the NHI. No functional change intended. Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Andreas Noever <andreas.noever@gmail.com> drivers/pci/quirks.c | 16 ++++++++++------ drivers/thunderbolt/nhi.c | 8 +++++--- drivers/thunderbolt/switch.c | 9 +++++---- include/linux/pci_ids.h | 18 ++++++++++++++++++ 4 files changed, 38 insertions(+), 13 deletions(-) commit f9383452a26fc47f62c4ddcfa20ccebb7a09c2d8 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 8 12:04:29 2016 -0300 perf dwarf: Guard !x86_64 definitions under #ifdef else clause To fix the build on Fedora Rawhide (gcc 6.0.0 20160311 (Red Hat 6.0.0-0.17): CC /tmp/build/perf/arch/x86/util/dwarf-regs.o arch/x86/util/dwarf-regs.c:66:36: error: 'x86_32_regoffset_table' defined but not used [-Werror=unused-const-variable=] static const struct pt_regs_offset x86_32_regoffset_table[] = { ^~~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-fghuksc1u8ln82bof4lwcj0o@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/util/dwarf-regs.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit bfc279f3d233150ff260e9e93012e14f86810648 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 8 11:53:02 2016 -0300 perf tools: Use readdir() instead of deprecated readdir_r() The readdir() function is thread safe as long as just one thread uses a DIR, which is the case when parsing tracepoint event definitions, to avoid breaking the build with glibc-2.23.90 (upcoming 2.24), use it instead of readdir_r(). See: http://man7.org/linux/man-pages/man3/readdir.3.html "However, in modern implementations (including the glibc implementation), concurrent calls to readdir() that specify different directory streams are thread-safe. In cases where multiple threads must read from the same directory stream, using readdir() with external synchronization is still preferable to the use of the deprecated readdir_r(3) function." Noticed while building on a Fedora Rawhide docker container. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-wddn49r6bz6wq4ee3dxbl7lo@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/parse-events.c | 60 +++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 30 deletions(-) commit f152dfee19c0cd146b16179a60ffb2cacf995736 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Apr 8 17:37:40 2016 +0300 intel_th: msu: Release resources on removal Do release the resources when msu subdevice gets removed: stop the capture if it is active (which is still possible even though the module in pinned) and free the capture buffers. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/msu.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 8e9a2beb5f991916e530184957c4137fab14604c Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Apr 8 17:36:04 2016 +0300 intel_th: msu: Set fops::owner to prevent module from unloading Right now it's possible to unload the msu driver while its character device is open. Prevent it by setting fops::owner, which will result in the module reference being held while the device node is open. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/msu.c | 1 + 1 file changed, 1 insertion(+) commit e2ea295baf87d78f2ed86ce595b30c691b18b210 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Apr 8 17:35:04 2016 +0300 intel_th: Hold output driver module reference while capture is active Right now it's possible to unload the output subdevice's driver while the capture to this output is active. Prevent this by holding the output driver's module reference. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/core.c | 5 +++++ 1 file changed, 5 insertions(+) commit 7093b4c963cc4e344e490c774924a180602a7092 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 8 11:32:15 2016 -0300 perf tools: Use readdir() instead of deprecated readdir_r() The readdir() function is thread safe as long as just one thread uses a DIR, which is the case when synthesizing events for pre-existing threads by traversing /proc, so, to avoid breaking the build with glibc-2.23.90 (upcoming 2.24), use it instead of readdir_r(). See: http://man7.org/linux/man-pages/man3/readdir.3.html "However, in modern implementations (including the glibc implementation), concurrent calls to readdir() that specify different directory streams are thread-safe. In cases where multiple threads must read from the same directory stream, using readdir() with external synchronization is still preferable to the use of the deprecated readdir_r(3) function." Noticed while building on a Fedora Rawhide docker container. CC /tmp/build/perf/util/event.o util/event.c: In function '__event__synthesize_thread': util/event.c:466:2: error: 'readdir_r' is deprecated [-Werror=deprecated-declarations] while (!readdir_r(tasks, &dirent, &next) && next) { ^~~~~ In file included from /usr/include/features.h:368:0, from /usr/include/stdint.h:25, from /usr/lib/gcc/x86_64-redhat-linux/6.0.0/include/stdint.h:9, from /git/linux/tools/include/linux/types.h:6, from util/event.c:1: /usr/include/dirent.h:189:12: note: declared here Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-i1vj7nyjp2p750rirxgrfd3c@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/event.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 3354cf71104de49326d19d2f9bdb1f66eea52ef4 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 8 11:31:24 2016 -0300 perf thread_map: Use readdir() instead of deprecated readdir_r() The readdir() function is thread safe as long as just one thread uses a DIR, which is the case in thread_map, so, to avoid breaking the build with glibc-2.23.90 (upcoming 2.24), use it instead of readdir_r(). See: http://man7.org/linux/man-pages/man3/readdir.3.html "However, in modern implementations (including the glibc implementation), concurrent calls to readdir() that specify different directory streams are thread-safe. In cases where multiple threads must read from the same directory stream, using readdir() with external synchronization is still preferable to the use of the deprecated readdir_r(3) function." Noticed while building on a Fedora Rawhide docker container. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-del8h2a0f40z75j4r42l96l0@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread_map.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a5e8e825bd1704c488bf6a46936aaf3b9f203d6a Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Fri Apr 8 11:25:59 2016 -0300 perf script: Use readdir() instead of deprecated readdir_r() The readdir() function is thread safe as long as just one thread uses a DIR, which is the case in 'perf script', so, to avoid breaking the build with glibc-2.23.90 (upcoming 2.24), use it instead of readdir_r(). See: http://man7.org/linux/man-pages/man3/readdir.3.html "However, in modern implementations (including the glibc implementation), concurrent calls to readdir() that specify different directory streams are thread-safe. In cases where multiple threads must read from the same directory stream, using readdir() with external synchronization is still preferable to the use of the deprecated readdir_r(3) function." Noticed while building on a Fedora Rawhide docker container. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-mt3xz7n2hl49ni2vx7kuq74g@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 70 ++++++++++++++++++++++----------------------- 1 file changed, 34 insertions(+), 36 deletions(-) commit a45ff6ed742cdfdb3cdebee83d19ab1c00d91fcc Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Thu Mar 10 18:21:14 2016 +0200 intel_th: msu: Serialize enabling/disabling In order to guarantee that readers don't race with trace enabling, both should happen under the same mutex. Having two mutexes seems like an overkill, considering that because of the above, they'll have to be acquired together, around trace enabling and char device opening. This patch makes both buffer accesses and readers serialize on msc::buf_mutex and makes sure that 'enabled' flag accesses are also serialized on it. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/msu.c | 92 +++++++++++++++++++++------------------- 1 file changed, 49 insertions(+), 43 deletions(-) commit f18a9531f6da9aba2920a3a5f166dba5a20592a0 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Mon Mar 7 17:04:45 2016 +0200 intel_th: Fix activating a subdevice without a driver If output subdevice driver is not loaded, activating it will try to call its ->activate method and crash. Fix this by explicitly checking for the driver. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/core.c | 12 ++++++++++-- drivers/hwtracing/intel_th/intel_th.h | 3 +++ 2 files changed, 13 insertions(+), 2 deletions(-) commit e8644e4c2aa5c52c357f63af9cc17ef5dce38396 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 19:55:10 2016 +0200 intel_th: pti: Create sysfs attributes using core driver's facility The core intel_th driver allows subdevices to bring in their sysfs attributes. Use this instead of taking care of them in probe and remove. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/pti.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 9d482aedd0e2389b483ea8ea727ec201b65e2f27 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 19:55:10 2016 +0200 intel_th: msu: Create sysfs attributes using core driver's facility The core intel_th driver allows subdevices to bring in their sysfs attributes. Use this instead of taking care of them in probe and remove. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/msu.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit b5edbf1ea3ad044b185be7015cffabba9c442660 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 19:42:48 2016 +0200 intel_th: Allow subdevice drivers to bring in own attribute groups Some subdevices (MSU, PTI) need to register their own driver-specific attribute groups. Provide a way for those to pass their attribute groups to the core driver in their driver structure so that the core can take care of creating and removing them. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/core.c | 12 ++++++++++++ drivers/hwtracing/intel_th/intel_th.h | 3 +++ 2 files changed, 15 insertions(+) commit 6575cbd67172bbcbfbb50ddd854d2b90c9f4e358 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:16:31 2016 +0200 intel_th: msu: Handle kstrndup() failure Currently, the nr_pages attribute store does not check if kstrndup() succeeded. Fix this. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/msu.c | 5 +++++ 1 file changed, 5 insertions(+) commit 8f1127ea09a7bfe7e1b5fab5b7f52bd56f2d1bf5 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:10:20 2016 +0200 intel_th: pti: Do remove sysfs group on device removal Right now, the PTI output driver forgets to clean up its sysfs group when it gets removed. Fix this. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/intel_th/pti.c | 1 + 1 file changed, 1 insertion(+) commit fb0801904bbbc7b109d4009520c7fa34bcfb7450 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:55:12 2016 +0200 stm class: Remove unnecessary pointer increment Readability: a postfix increment is used on a pointer which is not used anywhere afterwards, which may send the reader looking through the function one extra time. Drop the unnecessary increment. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/policy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 389b6699a2aa0b457aa69986e9ddf39f3b4030fd Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:48:14 2016 +0200 stm class: Fix stm device initialization order Currently, stm_register_device() makes the device visible and then proceeds to initializing spinlocks and other properties, which leaves a window when the device can already be opened but is not yet fully operational. Fix this by reversing the initialization order. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/core.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit cbe4a61d1ddc4790d950ca8c33ef79ee68ef5e2b Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:36:10 2016 +0200 stm class: Do not leak the chrdev in error path Currently, the error path of stm_register_device() forgets to unregister the chrdev. Fix this. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/core.c | 2 ++ 1 file changed, 2 insertions(+) commit 8fa11d1c1322f3de40a0e3f3f3e57436a204fcc4 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:30:24 2016 +0200 stm class: Remove a pointless line No point in explicitly setting something to zero right after we explicitly checked that it is zero. Fix this. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/core.c | 2 -- 1 file changed, 2 deletions(-) commit c8be4899449c0b27bc5daf71742cd601b2b3b4e3 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:22:33 2016 +0200 stm class: stm_heartbeat: Make nr_devs parameter read-only Changing nr_devs after the module has been loaded doesn't actually change anything, so just make it read-only. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/heartbeat.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit 118b4515aa6916ee7751f29c8b2a3af95abc9783 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 16:22:33 2016 +0200 stm class: dummy_stm: Make nr_dummies parameter read-only Changing nr_dummies after the module has been loaded doesn't actually change anything, so just make it read-only. Reported-by: Alan Cox <alan.cox@intel.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/dummy_stm.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit f57af6df6af23c086cfe023896822200eee48dd1 Author: Chunyan Zhang <zhang.chunyan@linaro.org> Date: Mon Mar 28 15:55:42 2016 +0800 stm class: Fix integer boundary checks for master range Master IDs are of unsigned int type, yet in the configfs policy code we're validating user's input against INT_MAX. This is both pointless and misleading as the real limits are imposed by the stm device's [sw_start..sw_end] (which are also limited by the spec to be no larger than 2^16-1). Clean this up by getting rid of the redundant comparisons. Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> drivers/hwtracing/stm/policy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 99e87f7bb7268cf644add87130590966fd5d0d17 Author: Wang Nan <wangnan0@huawei.com> Date: Thu Apr 7 10:24:31 2016 +0000 perf symbols: Adjust symbol for shared objects He Kuang reported a problem that perf fails to get correct symbol on Android platform in [1]. The problem can be reproduced on normal x86_64 platform. I will describe the reproducing steps in detail at the end of commit message. The reason of this problem is the missing of symbol adjustment for normal shared objects. In most of the cases skipping adjustment is okay. However, when '.text' section have different 'address' and 'offset' the result is wrong. I checked all shared objects in my working platform, only wine dll objects and debug objects (in .debug) have this problem. However, it is common on Android. For example: $ readelf -S ./libsurfaceflinger.so | grep \.text [10] .text PROGBITS 0000000000029030 00012030 This patch enables symbol adjustment for dynamic objects so the symbol address got from elfutils would be adjusted correctly. Now nearly all types of ELF files should adjust symbols. Makes ss->adjust_symbols default to true. Steps to reproduce the problem: $ cat ./Makefile PWD := $(shell pwd) LDFLAGS += "-Wl,-rpath=$(PWD)" CFLAGS += -g main: main.c libbuggy.so libbuggy.so: buggy.c gcc -g -shared -fPIC -Wl,-Ttext-segment=0x200000 $< -o $@ clean: rm -rf main libbuggy.so *.o $ cat ./buggy.c int fib(int x) { return (x == 0) ? 1 : (x == 1) ? 1 : fib(x - 1) + fib(x - 2); } $ cat ./main.c #include <stdio.h> extern int fib(int x); int main() { int i; for (i = 0; i < 40; i++) printf("%d\n", fib(i)); return 0; } $ make $ perf record ./main ... $ perf report --stdio # Overhead Command Shared Object Symbol # ........ ....... ................. ............................... # 14.97% main libbuggy.so [.] 0x000000000000066c 8.68% main libbuggy.so [.] 0x00000000000006aa 8.52% main libbuggy.so [.] fib@plt 7.95% main libbuggy.so [.] 0x0000000000000664 5.94% main libbuggy.so [.] 0x00000000000006a9 5.35% main libbuggy.so [.] 0x0000000000000678 ... The correct result should be (after this patch): # Overhead Command Shared Object Symbol # ........ ....... ................. ............................... # 91.47% main libbuggy.so [.] fib 8.52% main libbuggy.so [.] fib@plt 0.00% main [kernel.kallsyms] [k] kmem_cache_free [1] http://lkml.kernel.org/g/1452567507-54013-1-git-send-email-hekuang@huawei.com Signed-off-by: Wang Nan <wangnan0@huawei.com> Acked-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Cody P Schafer <dev@codyps.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kirill Smelkov <kirr@nexedi.com> Cc: Li Zefan <lizefan@huawei.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460024671-64774-3-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/symbol-elf.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit a58f7033ba892b7d299954b94471450d72623039 Author: Wang Nan <wangnan0@huawei.com> Date: Thu Apr 7 10:24:30 2016 +0000 perf symbols: Record text offset in dso to calculate objdump address In this patch, the offset of '.text' section is stored into dso and used here to re-calculate address to objdump. In most of the cases, executable code is in '.text' section, so the adjustment made to a symbol in dso__load_sym (using sym.st_value -= shdr.sh_addr - shdr.sh_offset) should equal to 'sym.st_value -= dso->text_offset'. Therefore, adding text_offset back get objdump address from symbol address (rip). However, it is not true for kernel and kernel module since there could be multiple executable sections with different offset. Exclude kernel for this reason. After this patch, even dso->adjust_symbols is set to true for shared objects, map__rip_2objdump() and map__objdump_2mem() would return correct result, so perf behavior of annotate won't be changed. Signed-off-by: Wang Nan <wangnan0@huawei.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Cody P Schafer <dev@codyps.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kirill Smelkov <kirr@nexedi.com> Cc: Li Zefan <lizefan@huawei.com> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Zefan Li <lizefan@huawei.com> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1460024671-64774-2-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/map.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 1b700c9975008615ad470cf79acc8455ce60a695 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 4 19:05:36 2016 -0300 perf tools: Build syscall table .c header from kernel's syscall_64.tbl We used libaudit to map ids to syscall names and vice-versa, but that imposes a delay in supporting new syscalls, having to wait for libaudit to get those new syscalls on its tables. To remove that delay, for x86_64 initially, grab a copy of arch/x86/entry/syscalls/syscall_64.tbl and use it to generate those tables. Syscalls currently not available in audit-libs: # trace -e copy_file_range,membarrier,mlock2,pread64,pwrite64,timerfd_create,userfaultfd Error: Invalid syscall copy_file_range, membarrier, mlock2, pread64, pwrite64, timerfd_create, userfaultfd Hint: try 'perf list syscalls:sys_enter_*' Hint: and: 'man syscalls' # With this patch: # trace -e copy_file_range,membarrier,mlock2,pread64,pwrite64,timerfd_create,userfaultfd 8505.733 ( 0.010 ms): gnome-shell/2519 timerfd_create(flags: 524288) = 36 8506.688 ( 0.005 ms): gnome-shell/2519 timerfd_create(flags: 524288) = 40 30023.097 ( 0.025 ms): qemu-system-x8/24629 pwrite64(fd: 18, buf: 0x7f63ae382000, count: 4096, pos: 529592320) = 4096 31268.712 ( 0.028 ms): qemu-system-x8/24629 pwrite64(fd: 18, buf: 0x7f63afd8b000, count: 4096, pos: 2314133504) = 4096 31268.854 ( 0.016 ms): qemu-system-x8/24629 pwrite64(fd: 18, buf: 0x7f63afda2000, count: 4096, pos: 2314137600) = 4096 Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-51xfjbxevdsucmnbc4ka5r88@git.kernel.org [ Added make dep for 'prepare' in 'LIBPERF_IN', fix by Wang Nan to fix parallell build ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Makefile.perf | 13 +- tools/perf/arch/x86/Makefile | 23 ++ tools/perf/arch/x86/entry/syscalls/syscall_64.tbl | 374 ++++++++++++++++++++++ tools/perf/arch/x86/entry/syscalls/syscalltbl.sh | 39 +++ tools/perf/config/Makefile | 2 +- tools/perf/util/Build | 4 + tools/perf/util/syscalltbl.c | 6 + 7 files changed, 456 insertions(+), 5 deletions(-) commit 5af56fab2b11769e35ce96613d321bcc0f7b84c1 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 4 17:52:18 2016 -0300 perf tools: Allow generating per-arch syscall table arrays Tools should use a mechanism similar to arch/x86/entry/syscalls/ to generate a header file with the definitions for two variables: static const char *syscalltbl_x86_64[] = { [0] = "read", [1] = "write", <SNIP> [324] = "membarrier", [325] = "mlock2", [326] = "copy_file_range", }; static const int syscalltbl_x86_64_max_id = 326; In a per arch file that should then be included in tools/perf/util/syscalltbl.c. First one will be for x86_64. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-02uuamkxgccczdth8komspgp@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/syscalltbl.c | 89 +++++++++++++++++++++++++++++++++++++++++++- tools/perf/util/syscalltbl.h | 4 ++ 2 files changed, 91 insertions(+), 2 deletions(-) commit fd0db10268b3729eb466fd726a39ce7d800bb150 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Mon Apr 4 13:32:20 2016 -0300 perf trace: Move syscall table id <-> name routines to separate class We're using libaudit for doing name to id and id to syscall name translations, but that makes 'perf trace' to have to wait for newer libaudit versions supporting recently added syscalls, such as "userfaultfd" at the time of this changeset. We have all the information right there, in the kernel sources, so move this code to a separate place, wrapped behind functions that will progressively use the kernel source files to extract the syscall table for use in 'perf trace'. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-i38opd09ow25mmyrvfwnbvkj@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 24 +++++++++++------------- tools/perf/util/Build | 1 + tools/perf/util/syscalltbl.c | 43 +++++++++++++++++++++++++++++++++++++++++++ tools/perf/util/syscalltbl.h | 16 ++++++++++++++++ 4 files changed, 71 insertions(+), 13 deletions(-) commit ba2f22cf9989561c08225f0e88078d5562832313 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Apr 7 12:05:51 2016 -0300 perf trace: Beautify mode_t arguments When reading the syscall tracepoint /format file, look for arguments of type "mode_t" and attach a beautifier: [root@jouet ~]# cat ~/bin/tp_with_fields_of_type #!/bin/bash grep -w $1 /sys/kernel/tracing/events/syscalls/*/format | sed -r 's%.*sys_enter_(.*)/format.*%\1%g' | paste -d, -s # tp_with_fields_of_type umode_t chmod,creat,fchmodat,fchmod,mkdirat,mkdir,mknodat,mknod,mq_open,openat,open # Testing it: #define S_ISUID 0004000 #define S_ISGID 0002000 #define S_ISVTX 0001000 #define S_IRWXU 0000700 #define S_IRUSR 0000400 #define S_IWUSR 0000200 #define S_IXUSR 0000100 #define S_IRWXG 0000070 #define S_IRGRP 0000040 #define S_IWGRP 0000020 #define S_IXGRP 0000010 #define S_IRWXO 0000007 #define S_IROTH 0000004 #define S_IWOTH 0000002 #define S_IXOTH 0000001 # for mode in 4000 2000 1000 700 400 200 100 70 40 20 10 7 4 2 1 ; do \ echo -n $mode '->' ; trace --no-inherit -e chmod,fchmodat,fchmod chmod $mode x; \ done 4000 -> 0.338 ( 0.012 ms): fchmodat(dfd: CWD, filename: x, mode: ISUID) = 0 2000 -> 0.438 ( 0.015 ms): fchmodat(dfd: CWD, filename: x, mode: ISGID) = 0 1000 -> 0.677 ( 0.040 ms): fchmodat(dfd: CWD, filename: x, mode: ISVTX) = 0 700 -> 0.394 ( 0.013 ms): fchmodat(dfd: CWD, filename: x, mode: IRWXU) = 0 400 -> 0.337 ( 0.010 ms): fchmodat(dfd: CWD, filename: x, mode: IRUSR) = 0 200 -> 0.259 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: IWUSR) = 0 100 -> 0.249 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: IXUSR) = 0 70 -> 0.266 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: IRWXG) = 0 40 -> 0.329 ( 0.009 ms): fchmodat(dfd: CWD, filename: x, mode: IRGRP) = 0 20 -> 0.250 ( 0.009 ms): fchmodat(dfd: CWD, filename: x, mode: IWGRP) = 0 10 -> 0.259 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: IXGRP) = 0 7 -> 0.249 ( 0.009 ms): fchmodat(dfd: CWD, filename: x, mode: IRWXO) = 0 4 -> 0.278 ( 0.011 ms): fchmodat(dfd: CWD, filename: x, mode: IROTH) = 0 2 -> 0.276 ( 0.009 ms): fchmodat(dfd: CWD, filename: x, mode: IWOTH) = 0 1 -> 0.250 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: IXOTH) = 0 # # trace --no-inherit -e chmod,fchmodat,fchmod chmod 7777 x 0.258 ( 0.011 ms): fchmodat(dfd: CWD, filename: x, mode: IALLUGO) = 0 # trace --no-inherit -e chmod,fchmodat,fchmod chmod 7770 x 0.258 ( 0.008 ms): fchmodat(dfd: CWD, filename: x, mode: ISUID|ISGID|ISVTX|IRWXU|IRWXG) = 0 # trace --no-inherit -e chmod,fchmodat,fchmod chmod 777 x 0.293 ( 0.012 ms): fchmodat(dfd: CWD, filename: x, mode: IRWXUGO # Now lets see if check by using the tracepoint for that specific syscall, instead of raw_syscalls:sys_enter as 'trace' does for its strace fu: # trace --no-inherit --ev syscalls:sys_enter_fchmodat -e fchmodat chmod 666 x 0.255 ( ): syscalls:sys_enter_fchmodat:dfd: 0xffffffffffffff9c, filename: 0x55db32a3f0f0, mode: 0x000001b6) 0.268 ( 0.012 ms): fchmodat(dfd: CWD, filename: x, mode: IRUGO|IWUGO ) = 0 # Perfect, 0x1bc == 0666. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-18e8zfgbkj83xo87yoom43kd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 3 ++ tools/perf/trace/beauty/mode_t.c | 68 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 71 insertions(+) commit 91daee306a51ca7b4d3ca7fdcf7472b0ed2c80c1 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Apr 7 09:11:13 2016 +0200 perf script: Process event update events Andreas reported following command produces no output: # cat test.py #!/usr/bin/env python def stat__krava(cpu, thread, time, val, ena, run): print "event %s cpu %d, thread %d, time %d, val %d, ena %d, run %d" % \ ("krava", cpu, thread, time, val, ena, run) # perf stat -a -I 1000 -e cycles,"cpu/config=0x6530160,name=krava/" record | perf script -s test.py ^C # The reason is that 'perf script' does not process event update events and will never get the event name update thus the python callback is never called. The fix is just to add already existing callback we use in 'perf stat report'. Committer note: After the patch: # perf stat -a -I 1000 -e cycles,"cpu/config=0x6530160,name=krava/" record | perf script -s test.py event krava cpu -1, thread -1, time 1000239179, val 1789051, ena 4000690920, run 4000690920 event krava cpu -1, thread -1, time 2000479061, val 2391338, ena 4000879596, run 4000879596 event krava cpu -1, thread -1, time 3000740802, val 1939121, ena 4000977209, run 4000977209 event krava cpu -1, thread -1, time 4001006730, val 2356115, ena 4001000489, run 4001000489 ^C # Reported-by: Andreas Hollmann <hollmann@in.tum.de> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: David Ahern <dsahern@gmail.com> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460013073-18444-3-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-script.c | 1 + 1 file changed, 1 insertion(+) commit e583d70c54976f81855c7ca763b036bad399f4e0 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Apr 7 09:11:12 2016 +0200 perf tools: Add dedicated unwind addr_space member into thread struct Milian reported issue with thread::priv, which was double booked by perf trace and DWARF unwind code. So using those together is impossible at the moment. Moving DWARF unwind private data into separate variable so perf trace can keep using thread::priv. Reported-and-Tested-by: Milian Wolff <milian.wolff@kdab.com> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andreas Hollmann <hollmann@in.tum.de> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460013073-18444-2-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/thread.h | 6 ++++++ tools/perf/util/unwind-libunwind.c | 25 +++++++++---------------- 2 files changed, 15 insertions(+), 16 deletions(-) commit 7d323264bec07cd71df47333c6cd8f6b36987821 Author: Alan <gnomes@lxorguk.ukuu.org.uk> Date: Wed Apr 6 14:41:09 2016 +0100 drm/gma500/mdfld_dsi: remove bogus if check Both cases produce the same result. Kill the junk code. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> drivers/gpu/drm/gma500/mdfld_dsi_dpi.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 7ccca1d5bf69fdd1d3c5fcf84faf1659a6e0ad11 Author: Itai Handler <itai_handler@hotmail.com> Date: Tue Nov 3 00:20:56 2015 +0200 drm/gma500: Fix possible out of bounds read Fix possible out of bounds read, by adding missing comma. The code may read pass the end of the dsi_errors array when the most significant bit (bit #31) in the intr_stat register is set. This bug has been detected using CppCheck (static analysis tool). Cc: stable@vger.kernel.org Signed-off-by: Itai Handler <itai_handler@hotmail.com> Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> drivers/gpu/drm/gma500/mdfld_dsi_pkg_sender.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4cd54d986e8a1e28b70cfeb748c3ce734635bb4b Author: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Date: Thu Oct 8 18:17:48 2015 +0530 drm/gma500: fix double freeing We are allocating backing using psbfb_alloc() and so backing->stolen is always true. So we were freeing backing two times. Moreover if we follow the execution path then we should be freeing backing after we have released the helper. So remove the one which frees backing before the helper is released. While at it the error labels are also renamed to give a meaningful name. [Patrik: Fixed conflict with removal of struct_mutex] Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Reviewed-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> drivers/gpu/drm/gma500/framebuffer.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit cffa781e59070cf115525a57e8f6042bd4e2bf7c Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:18 2016 +0100 drm/i915: Simplify check for idleness in hangcheck Having fixed the tracking of the engine's last_submitted_seqno, we can now rely on it for detecting when the engine is idle (and not have to touch the requests pointer). Testcase: igt/gem_exec_whisper Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-9-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> drivers/gpu/drm/i915/i915_irq.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 7c90b7de7372fcd634fa0cffea6e580fb32e6b85 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:17 2016 +0100 drm/i915: Apply a mb between emitting the request and hangcheck Seal the request and mark it as pending execution before we submit it to hardware. We assume that the actual submission cannot fail (that guarantee is provided by preallocating space in the request for the submission). As we may inspect this state without holding any locks during hangcheck we should apply a barrier to ensure that we do not see a more recent value in the HWS than we are tracking. Based on a patch by Mika Kuoppala. Suggested-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-8-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> drivers/gpu/drm/i915/i915_gem.c | 39 ++++++++++++++++++++++----------------- drivers/gpu/drm/i915/i915_irq.c | 3 ++- 2 files changed, 24 insertions(+), 18 deletions(-) commit 01347126f4e2a346bf37fe264570563b0fab6618 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:16 2016 +0100 drm/i915: Reset engine->last_submitted_seqno When we change the current seqno, we also need to remember to reset the last_submitted_seqno for the engine. Testcase: igt/gem_exec_whisper Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-7-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 1 + 1 file changed, 1 insertion(+) commit a058d9348244047189ff1aabaeb2ebcffa899cb3 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:15 2016 +0100 drm/i915: Reset semaphore page for gen8 An oversight is that when we wrap the seqno, we need to reset the hw semaphore counters to 0. We did this for gen6 and gen7 and forgot to do so for the new implementation required for gen8 (legacy). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-6-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 8c12672ee2d386924c65c3bbb30bf0da415b2918 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:14 2016 +0100 drm/i915: Refactor gen8 semaphore offset calculation We reuse the same calculation into two macros, and I want to add a third user. Time to refactor. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-5-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.h | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 29dcb570264ce1d887ba8ac729ec2103abf1802e Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:13 2016 +0100 drm/i915: Move the hw semaphore initialisation from GEM to the engine Since we are setting engine local values that are tied to the hardware, move it out of i915_gem_init_seqno() into the intel_ring_init_seqno() backend, next to where the other hw semaphore registers are written. v2: Make the explanatory comment about always resetting the semaphores to 0 irrespective of the value of the reset seqno. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-4-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem.c | 8 ++------ drivers/gpu/drm/i915/intel_ringbuffer.c | 11 +++++++++++ 2 files changed, 13 insertions(+), 6 deletions(-) commit d04bce48a5ca534102e3e6738b1b96546008665c Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:12 2016 +0100 drm/i915: Remove unneeded drm_device pointer from intel_ring_init_seqno() We only use drm_i915_private within the function, so delete the unneeded drm_device local. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-3-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ringbuffer.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 2ed53a94d8cb14f8f1c56ecdd1e6def5bbe41628 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:11 2016 +0100 drm/i915: On GPU reset, set the HWS breadcrumb to the last seqno After the GPU reset and we discard all of the incomplete requests, mark the GPU as having advanced to the last_submitted_seqno (as having completed the requests and ready for fresh work). The impact of this is negligible, as all the requests will be considered completed by this point, it just brings the HWS into line with expectations for external viewers. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem.c | 2 ++ 1 file changed, 2 insertions(+) commit 14fd0d6d0b91a207162f1a22104eb34d403b8679 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Apr 7 07:29:10 2016 +0100 drm/i915: Include engine->last_submitted_seqno in GPU error state It's useful to look at the last seqno submitted on a particular engine and compare it against the HWS value to check for irregularities. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460010558-10705-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 6 ++++-- drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gpu_error.c | 2 ++ 3 files changed, 7 insertions(+), 2 deletions(-) commit e8369d65693bd4e21e043c0e66eff1056ed1e7a3 Author: Masanari Iida <standby24x7@gmail.com> Date: Fri Apr 8 12:45:25 2016 +0900 ALSA: Fix a typo in timestamping.txt This patch fix a spelling typo found in Documentation/sound/alsa/timestamping.txt Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Documentation/sound/alsa/timestamping.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f8711655f862eabc0cb03e2bccd871069399c53e Merge: b33b0a1 e3edfde Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 21:04:27 2016 -0400 Merge branch 'bpf-tracepoints' Alexei Starovoitov says: ==================== allow bpf attach to tracepoints Hi Steven, Peter, v1->v2: addressed Peter's comments: - fixed wording in patch 1, added ack - refactored 2nd patch into 3: 2/10 remove unused __perf_addr macro which frees up an argument in perf_trace_buf_submit 3/10 split perf_trace_buf_prepare into alloc and update parts, so that bpf programs don't have to pay performance penalty for update of struct trace_entry which is not going to be accessed by bpf 4/10 actual addition of bpf filter to perf tracepoint handler is now trivial and bpf prog can be used as proper filter of tracepoints v1 cover: last time we discussed bpf+tracepoints it was a year ago [1] and the reason we didn't proceed with that approach was that bpf would make arguments arg1, arg2 to trace_xx(arg1, arg2) call to be exposed to bpf program and that was considered unnecessary extension of abi. Back then I wanted to avoid the cost of buffer alloc and field assign part in all of the tracepoints, but looks like when optimized the cost is acceptable. So this new apporach doesn't expose any new abi to bpf program. The program is looking at tracepoint fields after they were copied by perf_trace_xx() and described in /sys/kernel/debug/tracing/events/xxx/format We made a tool [2] that takes arguments from /sys/.../format and works as: $ tplist.py -v random:urandom_read int got_bits; int pool_left; int input_left; Then these fields can be copy-pasted into bpf program like: struct urandom_read { __u64 hidden_pad; int got_bits; int pool_left; int input_left; }; and the program can use it: SEC("tracepoint/random/urandom_read") int bpf_prog(struct urandom_read *ctx) { return ctx->pool_left > 0 ? 1 : 0; } This way the program can access tracepoint fields faster than equivalent bpf+kprobe program, which is the main goal of these patches. Patch 1-4 are simple changes in perf core side, please review. I'd like to take the whole set via net-next tree, since the rest of the patches might conflict with other bpf work going on in net-next and we want to avoid cross-tree merge conflicts. Alternatively we can put patches 1-4 into both tip and net-next. Patch 9 is an example of access to tracepoint fields from bpf prog. Patch 10 is a micro benchmark for bpf+kprobe vs bpf+tracepoint. Note that for actual tracing tools the user doesn't need to run tplist.py and copy-paste fields manually. The tools do it automatically. Like argdist tool [3] can be used as: $ argdist -H 't:block:block_rq_complete():u32:nr_sector' where 'nr_sector' is name of tracepoint field taken from /sys/kernel/debug/tracing/events/block/block_rq_complete/format and appropriate bpf program is generated on the fly. [1] http://thread.gmane.org/gmane.linux.kernel.api/8127/focus=8165 [2] https://github.com/iovisor/bcc/blob/master/tools/tplist.py [3] https://github.com/iovisor/bcc/blob/master/tools/argdist.py ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit e3edfdec04d43aa6276db639d3721e073161d2c2 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:31 2016 -0700 samples/bpf: add tracepoint vs kprobe performance tests the first microbenchmark does fd=open("/proc/self/comm"); for() { write(fd, "test"); } and on 4 cpus in parallel: writes per sec base (no tracepoints, no kprobes) 930k with kprobe at __set_task_comm() 420k with tracepoint at task:task_rename 730k For kprobe + full bpf program manully fetches oldcomm, newcomm via bpf_probe_read. For tracepint bpf program does nothing, since arguments are copied by tracepoint. 2nd microbenchmark does: fd=open("/dev/urandom"); for() { read(fd, buf); } and on 4 cpus in parallel: reads per sec base (no tracepoints, no kprobes) 300k with kprobe at urandom_read() 279k with tracepoint at random:urandom_read 290k bpf progs attached to kprobe and tracepoint are noop. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/Makefile | 5 + samples/bpf/test_overhead_kprobe_kern.c | 41 ++++++++ samples/bpf/test_overhead_tp_kern.c | 36 +++++++ samples/bpf/test_overhead_user.c | 162 ++++++++++++++++++++++++++++++++ 4 files changed, 244 insertions(+) commit 3c9b16448cf6924c203e3c01696c87fcbfb71fc6 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:30 2016 -0700 samples/bpf: tracepoint example modify offwaketime to work with sched/sched_switch tracepoint instead of kprobe into finish_task_switch Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/offwaketime_kern.c | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) commit c07660409ec954403776200cec1dd04b2db851f8 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:29 2016 -0700 samples/bpf: add tracepoint support to bpf loader Recognize "tracepoint/" section name prefix and attach the program to that tracepoint. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> samples/bpf/bpf_load.c | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) commit 32bbe0078afe86a8bf4c67c6b3477781b15e94dc Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:28 2016 -0700 bpf: sanitize bpf tracepoint access during bpf program loading remember the last byte of ctx access and at the time of attaching the program to tracepoint check that the program doesn't access bytes beyond defined in tracepoint fields This also disallows access to __dynamic_array fields, but can be relaxed in the future. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/bpf.h | 1 + include/linux/trace_events.h | 1 + kernel/bpf/verifier.c | 6 +++++- kernel/events/core.c | 8 ++++++++ kernel/trace/trace_events.c | 18 ++++++++++++++++++ 5 files changed, 33 insertions(+), 1 deletion(-) commit 9940d67c93b5bb7ddcf862b41b1847cb728186c4 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:27 2016 -0700 bpf: support bpf_get_stackid() and bpf_perf_event_output() in tracepoint programs needs two wrapper functions to fetch 'struct pt_regs *' to convert tracepoint bpf context into kprobe bpf context to reuse existing helper functions Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/bpf.h | 1 + kernel/bpf/stackmap.c | 2 +- kernel/trace/bpf_trace.c | 42 +++++++++++++++++++++++++++++++++++++++++- 3 files changed, 43 insertions(+), 2 deletions(-) commit 9fd82b610ba3351f05a59c3e9117cfefe82f7751 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:26 2016 -0700 bpf: register BPF_PROG_TYPE_TRACEPOINT program type register tracepoint bpf program type and let it call the same set of helper functions as BPF_PROG_TYPE_KPROBE Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> kernel/trace/bpf_trace.c | 45 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 43 insertions(+), 2 deletions(-) commit 98b5c2c65c2951772a8fc661f50d675e450e8bce Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:25 2016 -0700 perf, bpf: allow bpf programs attach to tracepoints introduce BPF_PROG_TYPE_TRACEPOINT program type and allow it to be attached to the perf tracepoint handler, which will copy the arguments into the per-cpu buffer and pass it to the bpf program as its first argument. The layout of the fields can be discovered by doing 'cat /sys/kernel/debug/tracing/events/sched/sched_switch/format' prior to the compilation of the program with exception that first 8 bytes are reserved and not accessible to the program. This area is used to store the pointer to 'struct pt_regs' which some of the bpf helpers will use: +---------+ | 8 bytes | hidden 'struct pt_regs *' (inaccessible to bpf program) +---------+ | N bytes | static tracepoint fields defined in tracepoint/format (bpf readonly) +---------+ | dynamic | __dynamic_array bytes of tracepoint (inaccessible to bpf yet) +---------+ Not that all of the fields are already dumped to user space via perf ring buffer and broken application access it directly without consulting tracepoint/format. Same rule applies here: static tracepoint fields should only be accessed in a format defined in tracepoint/format. The order of fields and field sizes are not an ABI. Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/trace/perf.h | 10 +++++++++- include/uapi/linux/bpf.h | 1 + kernel/events/core.c | 13 +++++++++---- 3 files changed, 19 insertions(+), 5 deletions(-) commit 1e1dcd93b468901e114f279c94a0b356adc5e7cd Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:24 2016 -0700 perf: split perf_trace_buf_prepare into alloc and update parts split allows to move expensive update of 'struct trace_entry' to later phase. Repurpose unused 1st argument of perf_tp_event() to indicate event type. While splitting use temp variable 'rctx' instead of '*rctx' to avoid unnecessary loads done by the compiler due to -fno-strict-aliasing Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/perf_event.h | 2 +- include/linux/trace_events.h | 8 ++++---- include/trace/perf.h | 8 ++++---- kernel/events/core.c | 6 ++++-- kernel/trace/trace_event_perf.c | 39 ++++++++++++++++++++------------------- kernel/trace/trace_kprobe.c | 10 ++++++---- kernel/trace/trace_syscalls.c | 13 +++++++------ kernel/trace/trace_uprobe.c | 5 +++-- 8 files changed, 49 insertions(+), 42 deletions(-) commit e93735be6a1898dd9f8de8f55254cc76309777ce Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:23 2016 -0700 perf: remove unused __addr variable now all calls to perf_trace_buf_submit() pass 0 as 4th argument which will be repurposed in the next patch which will change the meaning of 1st arg of perf_tp_event() to event_type Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/trace/perf.h | 7 ++----- include/trace/trace_events.h | 3 --- 2 files changed, 2 insertions(+), 8 deletions(-) commit ec5e099d6e941668d121ea9ca7057f4fa00830b0 Author: Alexei Starovoitov <ast@fb.com> Date: Wed Apr 6 18:43:22 2016 -0700 perf: optimize perf_fetch_caller_regs avoid memset in perf_fetch_caller_regs, since it's the critical path of all tracepoints. It's called from perf_sw_event_sched, perf_event_task_sched_in and all of perf_trace_##call with this_cpu_ptr(&__perf_regs[..]) which are zero initialized by perpcu init logic and subsequent call to perf_arch_fetch_caller_regs initializes the same fields on all archs, so we can safely drop memset from all of the above cases and move it into perf_ftrace_function_call that calls it with stack allocated pt_regs. Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/perf_event.h | 2 -- kernel/trace/trace_event_perf.c | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) commit b33b0a1bf69faff89693df49519fa7b459f5d807 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 20:40:25 2016 -0400 net: Fix build failure due to lockdep_sock_is_held(). Needs to be protected with CONFIG_LOCKDEP. Based upon a patch by Hannes Frederic Sowa. Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 2 ++ 1 file changed, 2 insertions(+) commit 10ef00fe539a387ded9e0d710012500896589dbb Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:51 2016 -0700 ixgbe: Bump version number Update ixgbe version number. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f572b2c4c86dcebe6b8684cbab03d9b2ea0d2ad6 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:46 2016 -0700 ixgbe: Add KR backplane support for x550em_a Add support for x550em_a-based KR backplane devices. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 18 ++++++++++++++---- 3 files changed, 18 insertions(+), 4 deletions(-) commit 200157c2e31a5931d0d825e9fddb44d10888e6b3 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:40 2016 -0700 ixgbe: Add support for SGMII backplane interface Add support for an SGMII backplane interface. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 + drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 9 +++++ drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 58 +++++++++++++++++++++++++++ 3 files changed, 69 insertions(+) commit 2d40cd1720cb6eb4406b80866c08d97b92595dfe Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:35 2016 -0700 ixgbe: Add support for SFPs with retimer Add support for SFPs with an external retimer. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 + drivers/net/ethernet/intel/ixgbe/ixgbe_phy.h | 6 +- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 5 + drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 133 +++++++++++++++++++++++++- 4 files changed, 144 insertions(+), 2 deletions(-) commit e84db7272798ed8abb2760a3fcd9c6d89abf99a5 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:30 2016 -0700 ixgbe: Introduce function to control MDIO speed Move code that controls MDIO speed into a new function because there will be more MACs that need the control. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) commit 537cc5df4fcb82c0ee1f1dc4751357929a135bbc Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:25 2016 -0700 ixgbe: Read and parse NW_MNG_IF_SEL register Read the IXGBE_NW_MNG_IF_SEL register and use it to set interface attributes. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 5 ++++ drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 37 +++++++++++++++++++++++---- 2 files changed, 37 insertions(+), 5 deletions(-) commit c898fe280457dcdf500fc1001ee73cb1adedc4d2 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:20 2016 -0700 ixgbe: Read and set instance id Read the instance number from EEPROM and save it for later use. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 8 ++++++++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 5 +++++ 2 files changed, 13 insertions(+) commit d31afc8f5ca11249a3b15dafa5972fc76e4099cf Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:14 2016 -0700 ixgbe: Use new methods for PHY access Now x550em_a devices will use a new method for PHY access that will get the firmware token for each access. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 67 +++++++++++++++++++++++++-- 1 file changed, 64 insertions(+), 3 deletions(-) commit 49425dfc74512bef9cf15eafb5de0fc98f024e20 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:09 2016 -0700 ixgbe: Add support for x550em_a 10G MAC type Add support for x550em_a 10G MAC type to the ixgbe driver. The new MAC includes new firmware commands that need to be used to control PHY and IOSF access, so that support is also added. The interface supported is a native SFP+ interface. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 3 + drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_dcb.c | 6 +- drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 9 +- drivers/net/ethernet/intel/ixgbe/ixgbe_lib.c | 3 +- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 43 ++++- drivers/net/ethernet/intel/ixgbe/ixgbe_mbx.c | 2 + drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c | 6 +- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 38 +++++ drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 208 ++++++++++++++++++++++- 11 files changed, 311 insertions(+), 9 deletions(-) commit 9a5c27e6ef9166612f95564bc2fc69506d1be2b3 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:18:04 2016 -0700 ixgbe: Use method pointer to access IOSF devices Provide method pointers and use them to access IOSF-attached devices. A new MAC will introduce a new access method. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 32 +++++++++++++++------------ 2 files changed, 20 insertions(+), 14 deletions(-) commit 207969b94cf2736f4f2f51aec287a6a0ea7d5dbd Author: Mark Rustad <mark.d.rustad@intel.com> Date: Fri Apr 1 12:17:59 2016 -0700 ixgbe: Add definitions for x550em_a 10G MAC Add definitions for a x550em_a 10G MAC device with a native SFP interface. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit a711ad89a887f7cb2ecbea591a58b6102ad9be7a Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 21 11:21:31 2016 -0700 ixgbe: Add support for single-port X550 device Add support for a single-port X550 device. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 1 + 3 files changed, 4 insertions(+) commit 8220bbc12d39175964cb56e100fabcedd59c48da Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon Mar 7 09:30:09 2016 -0800 ixgbe/ixgbevf: Add support for bulk free in Tx cleanup & cleanup boolean logic This patch enables bulk free in Tx cleanup for ixgbevf and cleans up the boolean logic in the polling routines for ixgbe and ixgbevf in the hopes of avoiding any mix-ups similar to what occurred with i40e and i40evf. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 10 +++++++--- drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 14 +++++++++----- 2 files changed, 16 insertions(+), 8 deletions(-) commit af7419017626b93ccdf76b12c2b1dc8fe17da4ad Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 14 11:06:02 2016 -0700 ixgbe: Take manageability semaphore for firmware commands We need to take the manageability semaphore when issuing firmware commands to avoid problems. With this in place, the semaphore is no longer taken in the ixgbe_set_fw_drv_ver_generic function, since it will now always be taken by the ixgbe_host_interface_command function. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 30 ++++++++++++++++--------- 1 file changed, 19 insertions(+), 11 deletions(-) commit 5cffde309cb3f6f7aaaa459abd3eba245a863f8a Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 14 11:05:57 2016 -0700 ixgbe: Clean up interface for firmware commands Clean up the interface for issuing firmware commands to use a void * instead of a u32 *. This eliminates a number of casts. Also clean up ixgbe_host_interface_command in a few other ways, eliminating comparisons with 0, redundant parens and minor formatting issues. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 39 +++++++++++++------------ drivers/net/ethernet/intel/ixgbe/ixgbe_common.h | 4 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 13 ++++----- 3 files changed, 28 insertions(+), 28 deletions(-) commit 73457165d71d5ce0e41c0adb7bfa484702c36248 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 14 11:05:51 2016 -0700 ixgbe: Correct length check for round up The function ixgbe_host_interface_command actually uses a multiple of word sized buffer to do its business, but only checks against the actual length passed in. This means that on read operations it could be possible to modify locations beyond the length passed in. Change the check to round up in the same way, just to avoid any possible hazard. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3775b814d5380a25ed89b881d845f79f81bc5547 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 14 11:05:46 2016 -0700 ixgbe: Change the lan_id and func fields to a u8 to avoid casts Since the lan_id and func fields only ever hold small values, make them u8 to avoid casts used to silence warnings. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 4 ++-- drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) commit 832ac592149f542052e387f17dfcfa7ebea50aaf Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Mar 14 11:05:40 2016 -0700 ixgbe: Delete some unused register definitions I noticed the SRAMREL registers are not referenced for any device, so delete the definitions. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 8 -------- 1 file changed, 8 deletions(-) commit 03be98226c14d787939381b9f42d81764ea8eedc Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Thu Apr 7 23:53:35 2016 +0200 sock: make lockdep_sock_is_held static inline I forgot to add inline to lockdep_sock_is_held, so it generated all kinds of build warnings if not build with lockdep support. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 889750bd2e08a94d52a116056d462b3a8e5616a7 Merge: ba35855 5b7066c Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 17:00:14 2016 -0400 Merge branch 'tipc-next' Jon Maloy says: ==================== tipc: some small fixes When fix a minor buffer leak, and ensure that bearers filter packets correctly while they are being shut down. v2: Corrected typos in commit #3, as per feedback from S. Shtylyov v3: Removed commit #3 from the series. Improved version will be re-submitted later. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 5b7066c3dd24c7d538e5ee402eb24bb182c16dab Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Thu Apr 7 10:09:14 2016 -0400 tipc: stricter filtering of packets in bearer layer Resetting a bearer/interface, with the consequence of resetting all its pertaining links, is not an atomic action. This becomes particularly evident in very large clusters, where a lot of traffic may happen on the remaining links while we are busy shutting them down. In extreme cases, we may even see links being re-created and re-established before we are finished with the job. To solve this, we now introduce a solution where we temporarily detach the bearer from the interface when the bearer is reset. This inhibits all packet reception, while sending still is possible. For the latter, we use the fact that the device's user pointer now is zero to filter out which packets can be sent during this situation; i.e., outgoing RESET messages only. This filtering serves to speed up the neighbors' detection of the loss event, and saves us from unnecessary probing. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/bearer.c | 50 +++++++++++++++++++++++++++++++++----------------- net/tipc/msg.h | 5 +++++ 2 files changed, 38 insertions(+), 17 deletions(-) commit 4e801fa14f68223d36480bced975ebf0c5f9a284 Author: Jon Paul Maloy <jon.maloy@ericsson.com> Date: Thu Apr 7 10:09:13 2016 -0400 tipc: eliminate buffer leak in bearer layer When enabling a bearer we create a 'neigbor discoverer' instance by calling the function tipc_disc_create() before the bearer is actually registered in the list of enabled bearers. Because of this, the very first discovery broadcast message, created by the mentioned function, is lost, since it cannot find any valid bearer to use. Furthermore, the used send function, tipc_bearer_xmit_skb() does not free the given buffer when it cannot find a bearer, resulting in the leak of exactly one send buffer each time a bearer is enabled. This commit fixes this problem by introducing two changes: 1) Instead of attemting to send the discovery message directly, we let tipc_disc_create() return the discovery buffer to the calling function, tipc_enable_bearer(), so that the latter can send it when the enabling sequence is finished. 2) In tipc_bearer_xmit_skb(), as well as in the two other transmit functions at the bearer layer, we now free the indicated buffer or buffer chain when a valid bearer cannot be found. Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/tipc/bearer.c | 51 ++++++++++++++++++++++++++------------------------- net/tipc/discover.c | 7 ++----- net/tipc/discover.h | 2 +- 3 files changed, 29 insertions(+), 31 deletions(-) commit 2d9586399932dff4746dc25d6498123959d69762 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Tue Mar 29 08:54:47 2016 +0100 ARM: 8553/1: kallsyms: remove --page-offset command line option The --page-offset command line option was only used for ARM, to filter symbol addresses below CONFIG_PAGE_OFFSET. This is no longer needed, so remove the functionality altogether. Acked-by: Nicolas Pitre <nico@linaro.org> Acked-by: Chris Brandt <chris.brandt@renesas.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> scripts/kallsyms.c | 8 -------- 1 file changed, 8 deletions(-) commit d4ffe418195b2d0581dfcda05f366e3b0f23d2a9 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Tue Mar 29 08:51:48 2016 +0100 ARM: 8552/1: kallsyms: remove special lower address limit for CONFIG_ARM Now that we no longer emit .stubs symbols into a section VMA loaded at absolute address 0x1000, we can drop the ARM-specific override that sets a lower limit based on CONFIG_PAGE_OFFSET, below which symbols are filtered from the kallsyms output. Acked-by: Nicolas Pitre <nico@linaro.org> Acked-by: Chris Brandt <chris.brandt@renesas.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> scripts/link-vmlinux.sh | 4 ---- 1 file changed, 4 deletions(-) commit b9b74be163a247fcbb3ef18086cc27123539131c Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Fri Apr 1 14:33:48 2016 +0100 ARM: 8555/1: kallsyms: ignore ARM mode switching veneers On ARM, the linker may emit veneers to deal with relative branch instructions that appear too far away from their targets. Since the second kallsyms pass results in an increase of the kernel size, it may result in additional veneers to be emitted, potentially affecting the output of kallsyms itself if these symbols are visible to it, and for that reason, symbols whose names end in '_veneer' are ignored explicitly. However, when building Thumb2 kernels, such veneers are named differently if they also incur a mode switch, and since they are not filtered by kallsyms, they may cause the build to fail. So filter symbols whose names end in '_from_arm' or '_from_thumb' as well. Tested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> scripts/kallsyms.c | 2 ++ 1 file changed, 2 insertions(+) commit b67dd2e9bdc0f79a3389e57c51189ed2c2127c00 Author: Alexandre Courbot <acourbot@nvidia.com> Date: Mon Mar 7 03:35:56 2016 +0100 ARM: 8548/1: dma-mapping: remove arm_dma_set_mask() arm_dma_set_mask() implements exactly the same behavior as the fallback that dma_set_mask() takes if the set_dma_mask op is not set. Remove it and use that fallback instead like what is already done for dma_get_mask(). Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> arch/arm/include/asm/dma-mapping.h | 2 -- arch/arm/mm/dma-mapping.c | 16 ---------------- 2 files changed, 18 deletions(-) commit ba35855e24d12d872e6173692bc34d48d96db39c Merge: 1fbbe1a 46aa2f3 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 16:53:37 2016 -0400 Merge branch 'gro-in-udp' Tom Herbert says: ==================== udp: GRO in UDP sockets This patch set adds GRO functions (gro_receive and gro_complete) to UDP sockets and removes udp_offload infrastructure. Add GRO functions (gro_receive and gro_complete) to UDP sockets. In udp_gro_receive and udp_gro_complete a socket lookup is done instead of looking up the port number in udp_offloads. If a socket is found and there are GRO functions for it then those are called. This feature allows binding GRO functions to more than just a port number. Eventually, we will be able to use this technique to allow application defined GRO for an application protocol by attaching BPF porgrams to UDP sockets for doing GRO. In order to implement these functions, we added exported udp6_lib_lookup_skb and udp4_lib_lookup_skb functions in ipv4/udp.c and ipv6/udp.c. Also, inet_iif and references to skb_dst() were changed to check that dst is set in skbuf before derefencing. In the GRO path there is now a UDP socket lookup performed before dst is set, to the get the device in that case we simply use skb->dev. Tested: Ran various combinations of VXLAN and GUE TCP_STREAM and TCP_RR tests. Did not see any material regression. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 46aa2f30aa7fe03a4dcd732b009284c02ff4f093 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:56 2016 -0700 udp: Remove udp_offloads Now that the UDP encapsulation GRO functions have been moved to the UDP socket we not longer need the udp_offload insfrastructure so removing it. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/netdevice.h | 17 ------------- include/net/protocol.h | 3 --- net/ipv4/udp_offload.c | 63 ----------------------------------------------- 3 files changed, 83 deletions(-) commit 4a0090a98e5f6e7813d807c883abf362df4b0507 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:55 2016 -0700 geneve: change to use UDP socket GRO Adapt geneve_gro_receive, geneve_gro_complete to take a socket argument. Set these functions in tunnel_config. Don't set udp_offloads any more. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/geneve.c | 28 ++++++++-------------------- 1 file changed, 8 insertions(+), 20 deletions(-) commit d92283e338f6d6503b7417536bf3478f466cbc01 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:54 2016 -0700 fou: change to use UDP socket GRO Adapt gue_gro_receive, gue_gro_complete to take a socket argument. Don't set udp_offloads any more. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/fou.c | 48 +++++++++++++++++------------------------------- 1 file changed, 17 insertions(+), 31 deletions(-) commit 5602c48cf87562c2f95b831d690631935e834295 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:53 2016 -0700 vxlan: change vxlan to use UDP socket GRO Adapt vxlan_gro_receive, vxlan_gro_complete to take a socket argument. Set these functions in tunnel_config. Don't set udp_offloads any more. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 30 ++++++++---------------------- include/net/vxlan.h | 1 - 2 files changed, 8 insertions(+), 23 deletions(-) commit 38fd2af24fcfda93f9fea3e53f26e48775ae9e09 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:52 2016 -0700 udp: Add socket based GRO and config Add gro_receive and gro_complete to struct udp_tunnel_sock_cfg. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/udp_tunnel.h | 7 +++++++ net/ipv4/udp_tunnel.c | 2 ++ 2 files changed, 9 insertions(+) commit a6024562ffd7e0f31bc6671817840ad1e91de7b4 Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:51 2016 -0700 udp: Add GRO functions to UDP socket This patch adds GRO functions (gro_receive and gro_complete) to UDP sockets. udp_gro_receive is changed to perform socket lookup on a packet. If a socket is found the related GRO functions are called. This features obsoletes using UDP offload infrastructure for GRO (udp_offload). This has the advantage of not being limited to provide offload on a per port basis, GRO is now applied to whatever individual UDP sockets are bound to. This also allows the possbility of "application defined GRO"-- that is we can attach something like a BPF program to a UDP socket to perfrom GRO on an application layer protocol. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/udp.h | 8 ++++++++ include/net/udp.h | 7 +++++-- net/ipv4/udp_offload.c | 52 +++++++++++++++++++------------------------------- net/ipv6/Makefile | 5 +++-- net/ipv6/af_inet6.c | 8 ++++++++ net/ipv6/ip6_offload.c | 2 -- net/ipv6/ip6_offload.h | 3 ++- net/ipv6/udp_offload.c | 11 ++++++++--- 8 files changed, 54 insertions(+), 42 deletions(-) commit 63058308cd55182bbfd7a87970bd57883fcfbd2e Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:50 2016 -0700 udp: Add udp6_lib_lookup_skb and udp4_lib_lookup_skb Add externally visible functions to lookup a UDP socket by skb. This will be used for GRO in UDP sockets. These functions also check if skb->dst is set, and if it is not skb->dev is used to get dev_net. This allows calling lookup functions before dst has been set on the skbuff. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/udp.h | 4 ++++ net/ipv4/udp.c | 13 +++++++++++++ net/ipv6/udp.c | 13 +++++++++++++ 3 files changed, 30 insertions(+) commit 0340d0b9e0e2dc340acb664f19d6550940b22cde Author: Tom Herbert <tom@herbertland.com> Date: Tue Apr 5 08:22:49 2016 -0700 net: Checks skb_dst to be NULL in inet_iif In inet_iif check if skb_rtable is NULL for the skb and return skb->skb_iif if it is. This change allows inet_iif to be called before the dst information has been set in the skb (e.g. when doing socket based UDP GRO). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/route.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 1fbbe1a8a9b195c4ac856540dfaef49d663c2e91 Merge: 8501786 8ced425 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 16:44:15 2016 -0400 Merge branch 'sock-lockdep-tightening' Hannes Frederic Sowa says: ==================== sock: lockdep tightening First patch is from Eric Dumazet and improves lockdep accuracy for socket locks. After that, second patch introduces lockdep_sock_is_held and uses it. Final patch reverts and reworks the lockdep fix from Daniel in the filter code, as we now have tighter lockdep support. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8ced425ee630c03beea06c1dfa35190bf8395d07 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Tue Apr 5 17:10:16 2016 +0200 tun: use socket locks for sk_{attach,detatch}_filter This reverts commit 5a5abb1fa3b05dd ("tun, bpf: fix suspicious RCU usage in tun_{attach, detach}_filter") and replaces it to use lock_sock around sk_{attach,detach}_filter. The checks inside filter.c are updated with lockdep_sock_is_held to check for proper socket locks. It keeps the code cleaner by ensuring that only one lock governs the socket filter instead of two independent locks. Cc: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 14 +++++++++----- include/linux/filter.h | 4 ---- net/core/filter.c | 35 +++++++++++++---------------------- 3 files changed, 22 insertions(+), 31 deletions(-) commit 1e1d04e678cf72442f57ce82803c7a407769135f Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Tue Apr 5 17:10:15 2016 +0200 net: introduce lockdep_is_held and update various places to use it The socket is either locked if we hold the slock spin_lock for lock_sock_fast and unlock_sock_fast or we own the lock (sk_lock.owned != 0). Check for this and at the same time improve that the current thread/cpu is really holding the lock. Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 12 ++++++++++-- net/dccp/ipv4.c | 2 +- net/dccp/ipv6.c | 2 +- net/ipv4/af_inet.c | 2 +- net/ipv4/cipso_ipv4.c | 3 ++- net/ipv4/ip_sockglue.c | 4 ++-- net/ipv4/tcp_ipv4.c | 8 +++----- net/ipv6/ipv6_sockglue.c | 6 ++++-- net/ipv6/tcp_ipv6.c | 2 +- net/socket.c | 2 +- 10 files changed, 26 insertions(+), 17 deletions(-) commit 61881cfb5ad80c1d0a46ca6d08b7e271892b2ff6 Author: Hannes Frederic Sowa <hannes@stressinduktion.org> Date: Tue Apr 5 17:10:14 2016 +0200 sock: fix lockdep annotation in release_sock During release_sock we use callbacks to finish the processing of outstanding skbs on the socket. We actually are still locked, sk_locked.owned == 1, but we already told lockdep that the mutex is released. This could lead to false positives in lockdep for lockdep_sock_is_held (we don't hold the slock spinlock during processing the outstanding skbs). I took over this patch from Eric Dumazet and tested it. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 7 ++++++- net/core/sock.c | 5 ----- 2 files changed, 6 insertions(+), 6 deletions(-) commit 20ac1b325d8d526211b1276ecf9b64b7e8369f50 Merge: 4646968 689de38 Author: Kalle Valo <kvalo@codeaurora.org> Date: Thu Apr 7 21:44:37 2016 +0300 Merge ath-next from ath.git ath.git patches for 4.7. Major changes: ath10k * implement push-pull tx model using mac80211 software queuing support * enable scan in AP mode (NL80211_FEATURE_AP_SCAN) wil6210 * add basic PBSS (Personal Basic Service Set) support * add initial P2P support * add oob_mode module parameter commit 61bf12d3304d78ff499245ea995858c3bedb162e Author: Jiri Kosina <jkosina@suse.cz> Date: Thu Apr 7 18:06:25 2016 +0200 livepatch: robustify klp_register_patch() API error checking Commit 425595a7fc20 ("livepatch: reuse module loader code to write relocations") adds a possibility of dereferncing pointers supplied by the consumer of the livepatch API before sanity (NULL) checking them (patch and patch->mod). Spotted by smatch tool. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Jessica Yu <jeyu@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> kernel/livepatch/core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 3fafd14d9422c46f5c2a142298384dc15dbf88b2 Author: Jose Abreu <Jose.Abreu@synopsys.com> Date: Thu Apr 7 17:53:57 2016 +0100 ASoC: dwc: Use fifo depth to program FCR This patch makes Designware I2S driver use the fifo depth value to program the fifo configuration register instead of using hardcoded values. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/dwc/designware_i2s.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 85f1e7c29a46360b1b5f9cf87af6b27066c345fd Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Sun Apr 3 22:03:33 2016 +0800 netfilter: ipv6: unnecessary to check whether ip6_route_output() returns NULL ip6_route_output() never returns NULL, so it is not appropriate to check if the return value is NULL. Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv6/netfilter/nf_reject_ipv6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dfc6535a8401b8fd15b18e2a5b8256600dd7e6b6 Author: Jisheng Zhang <jszhang@marvell.com> Date: Wed Mar 16 17:59:41 2016 +0800 PCI: mvebu: Use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS for mvebu_pcie_pm_ops Use the SET_NOIRQ_SYSTEM_SLEEP_PM_OPS helper macro for mvebu_pcie_pm_ops. The macro also sets up freeze_noirq, thaw_noirq and poweroff_noirq, restore_noirq accordingly. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> drivers/pci/host/pci-mvebu.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 6e9a426d7964703098bde5752ae5d062a596ca99 Author: Jisheng Zhang <jszhang@marvell.com> Date: Wed Mar 16 17:59:40 2016 +0800 PCI: mvebu: Constify mvebu_pcie_pm_ops structure The mvebu_pcie_pm_ops structure is never modified, so declare it as const. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> drivers/pci/host/pci-mvebu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4646968b94bdf88ae3c507c347d03acd5798939d Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 5 01:04:40 2016 -0700 mwifiex: dump pcie scratch registers This patch prints pcie scratch registers during firmware dump. They will be useful for analysing firmware status. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/main.c | 8 +++--- drivers/net/wireless/marvell/mwifiex/pcie.c | 42 +++++++++++++++++++++++++++++ drivers/net/wireless/marvell/mwifiex/pcie.h | 2 ++ 3 files changed, 49 insertions(+), 3 deletions(-) commit bf00dc22bc7a72d58fd1945814321b30948dc83b Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 5 01:04:39 2016 -0700 mwifiex: AMSDU Rx frame handling in AP mode This patch processes sub AMSDU frame received in AP mode. If a packet is multicast/broadcast, it is sent to kernel/upper layer as well as queued back to AP TX queue so that it can be sent to other associated stations. If a packet is unicast and RA is present in associated station list, it is again requeued into AP TX queue. If a packet is unicast and RA is not in associated station list, packet is forwarded to kernel to handle routing logic. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Cathy Luo <cluo@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/marvell/mwifiex/11n_rxreorder.c | 5 +- drivers/net/wireless/marvell/mwifiex/main.h | 2 + drivers/net/wireless/marvell/mwifiex/uap_txrx.c | 90 ++++++++++++++++++++++ 3 files changed, 96 insertions(+), 1 deletion(-) commit ad5ca845e3d194703be82ad4a2f3042f2e198e2b Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 5 01:04:38 2016 -0700 mwifiex: schedule main workqueue for transmitting bridge packets Bridge packets are enqueued to wmm tx queue, but will not be sent until main workqeue is scheduled for new interrupt or other reason. This adds unnecessary delay during traffic. We will schedule main workqueue when bridge packet is queued. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/uap_txrx.c | 2 ++ 1 file changed, 2 insertions(+) commit 00c5478049683b15599339e36cae7fffc1e62844 Author: Xinming Hu <huxm@marvell.com> Date: Tue Apr 5 01:04:37 2016 -0700 mwifiex: remove redundant GFP_DMA flag skb forwarded to TCP/IP stack doesn't need to allocate in DMA ZONE. This patch removes GFP_DMA flag in this case to save precious DMA memory. Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/sdio.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit a362e16b83e1823746874485710c7515eb5ee369 Author: Shengzhen Li <szli@marvell.com> Date: Tue Apr 5 01:04:36 2016 -0700 mwifiex: check revision id while choosing PCIe firmware Some of the chipsets have two revisions. This patch selects appropriate firmware by checking revision id. Signed-off-by: Shengzhen Li <szli@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/pcie.c | 56 ++++++++++++++++++++++++++--- drivers/net/wireless/marvell/mwifiex/pcie.h | 16 +++++---- 2 files changed, 61 insertions(+), 11 deletions(-) commit 8fa0a0dc634ba1bcf7678db296902d9c4e5025e0 Author: Ganapathi Bhat <gbhat@marvell.com> Date: Tue Apr 5 01:04:35 2016 -0700 mwifiex: add support for wakeup on GTK rekey failure User can configure wakeup on GTK rekey fail with wowlan. Added corresponding wakeup reason. Signed-off-by: Ganapathi Bhat <gbhat@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 7 ++++++- drivers/net/wireless/marvell/mwifiex/fw.h | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) commit f6b1cbe029f6828bbdac8b54bdcbdc35420e842e Author: Ganapathi Bhat <gbhat@marvell.com> Date: Tue Apr 5 01:04:34 2016 -0700 mwifiex: add support for GTK rekey offload Added driver functionality to offload GTK rekey to firmware. When AP sends new GTK, firmware will update it. Signed-off-by: Ganapathi Bhat <gbhat@marvell.com> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 13 +++++++++- drivers/net/wireless/marvell/mwifiex/fw.h | 10 ++++++++ drivers/net/wireless/marvell/mwifiex/sta_cmd.c | 28 ++++++++++++++++++++++ drivers/net/wireless/marvell/mwifiex/sta_cmdresp.c | 2 ++ drivers/net/wireless/marvell/mwifiex/sta_event.c | 3 +++ 5 files changed, 55 insertions(+), 1 deletion(-) commit a069caa3c30fc9744a82a6b83503ed93e00e723c Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:42 2016 -0400 rtl8xxxu: Do not set LDOA15 / LDOV12 on 8192eu Per the vendor driver, it looks like the 8192eu doesn't have LDOA15 / LDOV12 registers. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 91cbe4e73197859498fba9920890979296b842e6 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:41 2016 -0400 rtl8xxxu: Use correct H2C calls for 8192eu The 8192eu uses the same H2C API as the 8723bu. Call the correct functions for update_rate_mask() and report_connect(). Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit af13faff851b49fb99c9b930c823a5362aeb80a1 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:40 2016 -0400 rtl8xxxu: Identify 8192eu rev A/B parts correctly 8192eu A/B cut parts were incorrectly identified as 8192cu devices. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ba17d824783805235f317f79f2871b17bd679956 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:39 2016 -0400 rtl8xxxu: Use enums for chip version numbers With support for more chips being added, use an enum to specify the chip version. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 84 ++++++++++++------------ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 26 +++++++- 2 files changed, 67 insertions(+), 43 deletions(-) commit 931d9278259a91a601c93fe62979c7db53678abb Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:38 2016 -0400 rtl8xxxu: Update some register definitions Improve descriptive names of some registers and add some additional registers only found on nextgen chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h | 31 +++++++++++++++++----- 1 file changed, 24 insertions(+), 7 deletions(-) commit f3fc251162f9390baabcbf812766b074e404d29a Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:37 2016 -0400 rtl8xxxu: 8192eu uses txdesc40 8192eu uses the new TX descriptor format Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1df1de348572dff0fa7fb9c447d991c8dc1348f8 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:36 2016 -0400 rtl8xxxu: TXDESC_SHORT_GI is txdesc32 only This is no short GI bit in the txdesc40 format. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 2 +- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 169bc5cb0b8162d271c8fd38ff3d90b098241e16 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:35 2016 -0400 rtl8xxxu: Correct txdesc40 gid definition txdesc40 dword2 gid is a 6 bit field, not a single bit Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 33f3724948422bc594ffd976ec4272b653562414 Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:34 2016 -0400 rtl8xxxu: Rename TX descriptor bits to map them to 32/40 byte descriptors With the size based naming of TX descriptors. Change the bit definition namings to indicate which descriptor format they match, rather than having a device name in the bit name. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 51 ++++++------ drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 98 ++++++++++++------------ 2 files changed, 71 insertions(+), 78 deletions(-) commit dbb2896b485e79be55bacd891db60c85f010045f Author: Jes Sorensen <Jes.Sorensen@redhat.com> Date: Thu Mar 31 17:08:33 2016 -0400 rtl8xxxu: Change name of struct tx_desc to be more decriptive There are two major types of TX descriptor formats for the RTL parts, the old 32 byte descriptor, and the newer 40 byte descriptor used by the 8723bu, 8192eu, and 88xx series. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.c | 20 ++++++++++---------- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 4 ++-- 2 files changed, 12 insertions(+), 12 deletions(-) commit a5c92f0b6a88a8abe3840869425f1372591a762c Author: Wei-Ning Huang <wnhuang@chromium.org> Date: Wed Mar 30 18:14:55 2016 +0800 mwifiex: fix NULL pointer dereference error In mwifiex_enable_hs, we need to check if priv->wdev.wiphy->wowlan_config is NULL before accessing its member. This sometimes cause kernel panic when suspend/resume. Signed-off-by: Wei-Ning Huang <wnhuang@chromium.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/sta_ioctl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 001351881da1822b06e5d92e1fa2bf4920318e8c Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 16:53:33 2016 +0100 mwifiex: ie_list is an array, so no need to check if NULL ap_ie->ie_list is an array of struct mwifiex_ie and can never be null, so the null check on this array is redundant and can be removed. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/uap_cmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 84d17a2a5a0f9e19e25d0472f0528996d945826e Author: Julian Calaby <julian.calaby@gmail.com> Date: Fri Mar 18 13:29:11 2016 +1100 iwl4965: Fix more memory leaks in __il4965_up() In some of the non-success return paths, the memory allocated by iwl4965_sta_alloc_lq() in iwl4965_alloc_bcast_station() is not freed. In particular: - if the card isn't ready after il4965_prepare_card_hw() - if the card is hardware-rfkilled In the hardware rfkilled path, the driver enables the rfkill interrupt. When the card is unrfkilled and this interrupt is raised we end up calling il4965_bg_restart() which calls __il4965_up() which calls iwl4965_alloc_bcast_station() again. Suggested-by: Jia-Ju Bai <baijiaju1990@163.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/iwlegacy/4965-mac.c | 2 ++ 1 file changed, 2 insertions(+) commit c2fd34469d1623111e3c3db65cde533f3bddc26e Author: Jia-Ju Bai <baijiaju1990@163.com> Date: Fri Mar 18 13:28:33 2016 +1100 iwl4965: Fix a memory leak in error handling code of __il4965_up When il4965_hw_nic_init in __il4965_up fails, the memory allocated by iwl4965_sta_alloc_lq in iwl4965_alloc_bcast_station is not freed. This patches adds il_dealloc_bcast_stations in the error handling code of __il4965_up to fix this problem. This patch has been tested in real device, and it actually fixes the bug. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/iwlegacy/4965-mac.c | 1 + 1 file changed, 1 insertion(+) commit 37190b2694911552c09119e2b23e65049bf47a1e Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:27:31 2016 +1100 rsi: Move variable initialisation into error code In rsi_send_data_pkt(), it's a little more logical to assign 'status' in the actual error handling code as opposed to at the top of the functon. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> [Deleted controversial bits, rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/rsi/rsi_91x_pkt.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit ab2ef1d68f62d9e2ec6e494668f288fc000fe886 Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:25:33 2016 +1100 rsi: Delete unnecessary variable initialisation In rsi_send_data_pkt(), the following variables are assigned to before they're used: * tmp_hdr - Assigned on line 47, first used on line 48 * bss - Assigned on line 41, first used on line 44 * extnd_size - Assigned on line 50, first used on line 52 * seq_num - Assigned on line 48, first used on line 96 Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> [Rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/rsi/rsi_91x_pkt.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 8b28310efe241339248e875400c6da16f5d91c1f Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:25:13 2016 +1100 rsi: Delete unnecessary variable initialisation In rsi_send_mgmt_pkt(), the following variables are assigned to before they're used: * wh - Assigned on line 161, first used on line 180 * bss - Assigned on line 160, first used on line 196 * msg - Assigned on line 168, first used on line 175 * extnd_size - Assigned on line 139, first used on line 142 Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> [Rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/rsi/rsi_91x_pkt.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 1c76b4902c26c73283bb3578829dd0cfe53ce10a Author: Jia-Ju Bai <baijiaju1990@163.com> Date: Fri Mar 18 13:24:51 2016 +1100 rtl818x_pci: Disable pci device in error handling code When pci_request_regions in rtl8180_probe fails, pci_disable_device is not called to disable the device which is enabled by pci_enbale_device. This patch fixes the problem by adding a new lable in error handling code. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Acked-by: Andrea Merello <andrea.merello@gmail.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtl818x/rtl8180/dev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 96838d61102a0fca20a7bda7289e0492aaf11896 Author: Jia-Ju Bai <baijiaju1990@163.com> Date: Fri Mar 18 13:24:28 2016 +1100 b43: Fix memory leaks in b43_bus_dev_ssb_init and b43_bus_dev_bcma_init The memory allocated by kzalloc in b43_bus_dev_ssb_init and b43_bus_dev_bcma_init is not freed. This patch fixes the bug by adding kfree in b43_ssb_remove, b43_bcma_remove and error handling code of b43_bcma_probe. Thanks Michael for his suggestion. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Tested-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/b43/main.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit fe9b47944edff9b6244c4f5e81bd7b50574dc22b Author: Jia-Ju Bai <baijiaju1990@163.com> Date: Fri Mar 18 13:24:06 2016 +1100 iwl4965: Fix a null pointer dereference in il_tx_queue_free and il_cmd_queue_free If "txq->cmd = kzalloc(...)" in il_tx_queue_init fails, "kfree(txq->cmd[i])" in il_tx_queue_free and il_cmd_queue_free in iwl4965_hw_txq_ctx_free will causes a null pointer dereference, because txq->cmd is NULL at that time. This patch fixes this problem by adding a if-check before kfree. To avoid double free in il_tx_queue_free and il_cmd_queue_free caused by the fixing, txq->meta and txq->cmd in error handling code of il_tx_queue_init are assigned null values. Otherwise, a double free will occur. This patch has been tested in real device, and it actually fixes the bug. Thanks Stanislaw for his suggestion. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/iwlegacy/common.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) commit fb9693f04544068e6176051ce5b96e4574730107 Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:23:46 2016 +1100 iwlegacy: Return directly if allocation fails in il_eeprom_init() Also remove an unused label. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> [Rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/iwlegacy/common.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 9e12904a953c46abc87b0ea157be8de90205b70d Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:23:24 2016 +1100 brcmfmac: Delete unnecessary variable initialisation In brcmf_sdio_download_firmware(), bcmerror is set by the call to brcmf_sdio_download_code_file(), before it's checked in the following line. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Acked-by: Arend van Spriel <arend@broadcom.com> [Rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cfbfbd13695c8f9a93b1ad3edeeedacbb86dbe5c Author: Markus Elfring <elfring@users.sourceforge.net> Date: Fri Mar 18 13:22:52 2016 +1100 ath9k_htc: Delete unnecessary variable initialisation In ath9k_hif_usb_rx_stream(), i is initialised in the for loop it's used in. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Reviewed-by: Oleksij Rempel <linux@rempel-privat.de> [Rewrote commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ath/ath9k/hif_usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4679f41322012cf69b1035cde3de81151d2aefec Author: Geliang Tang <geliangtang@163.com> Date: Fri Mar 18 13:22:24 2016 +1100 rtlwifi: use to_delayed_work() Use to_delayed_work() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> [Update commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/wifi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d1162f0283f0b4421d1098dd048a5e3cf8b2abb6 Author: Geliang Tang <geliangtang@163.com> Date: Fri Mar 18 13:22:03 2016 +1100 wl1251: use to_delayed_work() Use to_delayed_work() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> [Update commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ti/wl1251/ps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 61383412f00d5917a28f388c59ebd78cf7c9d909 Author: Geliang Tang <geliangtang@163.com> Date: Fri Mar 18 13:21:28 2016 +1100 wlcore: use to_delayed_work() Use to_delayed_work() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> [Update commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ti/wlcore/main.c | 10 +++++----- drivers/net/wireless/ti/wlcore/ps.c | 2 +- drivers/net/wireless/ti/wlcore/scan.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) commit ea544aab42dbf35c7b8e80f931db400f4b5add60 Author: Geliang Tang <geliangtang@163.com> Date: Fri Mar 18 13:20:59 2016 +1100 ipw2x00: use to_pci_dev() Use to_pci_dev() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Acked-by: Stanislav Yakovlev <stas.yakovlev@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/intel/ipw2x00/ipw2100.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0fef3c768037169f656fc4ae89cf88ff7175e586 Author: Ivan Safonov <insafonov@gmail.com> Date: Fri Mar 18 13:16:26 2016 +1100 ath9k: Remove unnecessary ?: operator "(thermometer < 0) ? 0 : (thermometer == X)" is equivalent to "thermometer == X" for X >= 0. Signed-off-by: Ivan Safonov <insafonov@gmail.com> [Updated commit message] Signed-off-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ath/ath9k/ar9003_eeprom.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8501786929de4616b10b8059ad97abd304a7dddf Author: Eric Dumazet <edumazet@google.com> Date: Wed Apr 6 22:07:34 2016 -0700 tcp/dccp: fix inet_reuseport_add_sock() David Ahern reported panics in __inet_hash() caused by my recent commit. The reason is inet_reuseport_add_sock() was still using sk_nulls_for_each_rcu() instead of sk_for_each_rcu(). SO_REUSEPORT enabled listeners were causing an instant crash. While chasing this bug, I found that I forgot to clear SOCK_RCU_FREE flag, as it is inherited from the parent at clone time. Fixes: 3b24d854cb35 ("tcp/dccp: do not touch listener sk_refcnt under synflood") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: David Ahern <dsa@cumulusnetworks.com> Tested-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_connection_sock.c | 3 +++ net/ipv4/inet_hashtables.c | 3 +-- 2 files changed, 4 insertions(+), 2 deletions(-) commit 94ab1ea94c71b7ba3e835315d69880a8086d7ab1 Merge: de6099e d99e366 Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 11:50:30 2016 -0400 Merge branch '1GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 1GbE Intel Wired LAN Driver Updates 2016-04-06 This series contains updates to e1000, e1000e, igb and Kconfig. Alex fixes igb where we were casting the MAC address as __beXX and then passing it into le32_to_cpu, when we could simply cast as __lexx to maintain consistency since it is already little endian. Then enabled bulk free in transmit cleanup for igb. John Holland enables igb to pickup the MAC address from a device tree blob when CONFIG_OF has been enabled. Doron Shikmoni fixes a bug in the output of "ethtool -m ethX" where the data byte appeared duplicated. Stefan fixes up e1000 and e1000e ethtool offline tests which were calling dev_close() which causes IFF_UP to be cleared which removes teh interface routes and some addresses, so use ndo_stop() instead. Jiri Benc cleans up some old links in the Kconfig for Intel drivers where we referred to a URL which is no longer valid. I am so glad Jiri has the time in his day to spend clicking on and testing all the URL links in the the kernel. Arika Chen reverts the addition of a 'rtnl_unlock()' which had a unmatched 'rtnl_lock()' call before it. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 689de38e37179c6f524dd003e1dae92042f8f5cd Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Thu Apr 7 12:07:31 2016 +0530 ath10k: fix unconditional num_mpdus_ready subtraction Decrement num_mpdus_ready only when rx amsdu is processed successfully. Not doing so, will result in leak and impact stabilty under low memory cases. Also commit 3128b3d8a2b9 ("ath10k: speedup htt rx descriptor processing for rx_ind") missed to removed unused skb list rx_q. Fixes: 3128b3d8a2b9 ("ath10k: speedup htt rx descriptor processing for rx_ind") Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit dd7c280f9bf5ee6c7c46f03b2064f9f8fb617183 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Thu Apr 7 12:07:30 2016 +0530 ath10k: remove unnecessary warning for probe response drops qca99x0 and qca4019 solutions limit probe responses transmissions. Logging warning message for each probe response drop is flooding kernel log unnecessary with " failed to increase tx mgmt pending count: -16, dropping". Hence reducing log level to debug. Reported-by: Sebastian Gottschall <s.gottschall@dd-wrt.com> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b131129d96575479e2447d134cb1797cf430b3a4 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Thu Apr 7 12:07:29 2016 +0530 ath10k: fix calibration init sequence of qca99x0 pre-calibration is meant for qca4019 which contains only caldata whereas calibration file is used by ar9888 and qca99x0 that contains both board data and caldata. So by definition both pre-cal-file and cal-file can not coexist. Keeping them in shared memory (union), is breaking boot sequence of qca99x0. Fix it by storing both binaries in separate memories. This issue is reported in ipq8064 platform which includes caldata in flash memory. Fixes: 3d9195ea19e4 ("ath10k: incorporate qca4019 cal data download sequence") Reported-by: Sebastian Gottschall <s.gottschall@dd-wrt.com> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 12a56817b329d8a73ab53bad09aa976aeea46db9 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 4 16:59:26 2016 +0100 clk: renesas: mstp: Clarify cpg_mstp_{at,de}tach_dev() domain parameter Make it clear that the "domain" parameter of the cpg_mstp_attach_dev() and cpg_mstp_detach_dev() functions is not used. The cpg_mstp_attach_dev() and cpg_mstp_detach_dev() callbacks are not only used by the CPG/MSTP Clock Domain driver, but also by the R-Mobile SYSC PM Domain driver. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/clk-mstp.c | 4 ++-- include/linux/clk/renesas.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit da437d2d09de0af1ffd7ae3d88317ef1bf7f9456 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 4 15:36:33 2016 +0100 clk: renesas: cpg-mssr: Drop check for CONFIG_PM_GENERIC_DOMAINS_OF As of commit 71d076ceb245f0d9 ("ARM: shmobile: Enable PM and PM_GENERIC_DOMAINS for SoCs with PM Domains"), CONFIG_PM_GENERIC_DOMAINS_OF is always enabled for SoCs with a CPG/MSSR block. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> drivers/clk/renesas/renesas-cpg-mssr.c | 11 ----------- 1 file changed, 11 deletions(-) commit 848fc67da5fb43ef7d92d20891eef79f5de45816 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 4 15:32:40 2016 +0100 clk: renesas: mstp: Drop check for CONFIG_PM_GENERIC_DOMAINS_OF As of commit 71d076ceb245f0d9 ("ARM: shmobile: Enable PM and PM_GENERIC_DOMAINS for SoCs with PM Domains"), CONFIG_PM_GENERIC_DOMAINS_OF is always enabled for SoCs with MSTP clocks. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> drivers/clk/renesas/clk-mstp.c | 3 --- include/linux/clk/renesas.h | 4 ---- 2 files changed, 7 deletions(-) commit 33406c805730377ff48741f9ad99e7aada91595b Author: Lee Jones <lee.jones@linaro.org> Date: Tue May 5 13:13:57 2015 +0100 ARM: STi: Update platform level menuconfig 'help' Encompass newer STiH4{07,10} and STiH418 SoC based platforms. Acked-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/mach-sti/Kconfig | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit aac2252443a568ebf8b9e1b5682650645c6b57c9 Author: Lee Jones <lee.jones@linaro.org> Date: Wed Sep 2 13:31:31 2015 +0100 MAINTAINERS: Add ST's Remote Processor Driver to ARM/STI ARCHITECTURE Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 1d4b42bcccb9ea851ec0b4127e8cb103e8a7183f Author: Lee Jones <lee.jones@linaro.org> Date: Wed Dec 2 16:18:50 2015 +0000 MAINTAINERS: Add ST's CPUFreq driver to the STI file list Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 6f0e7535e7e122d927081423f80ff2a7d21e0a3f Author: Ramalingam C <ramalingam.c@intel.com> Date: Thu Apr 7 14:36:07 2016 +0530 drm/i915/BXT: Get pipe conf from the port registers At BXT DSI, PIPE registers are inactive. So we can't get the PIPE's mode parameters from them. The possible option is retriving them from the PORT registers. The required changes are added for BXT in intel_dsi_get_config (encoder->get_config). v2: Addressed the Jani's comments -removed the redundant call to encoder->get_config -read bpp from port register -removed retrival of src_size from encoder->get_config v3: pipe_config->pipe_bpp is fixed Jani's review comments addressed: Few horizontal timing parameters dropped from the patch to make progress, as there seems to be some disagreement on best/feasible/possible options. Signed-off-by: Ramalingam C <ramalingam.c@intel.com> Signed-off-by: Uma Shankar <uma.shankar@intel.com> Previously Reviewed at: https://lists.freedesktop.org/archives/intel-gfx/2016-April/091737.html Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460019967-26501-2-git-send-email-ramalingam.c@intel.com drivers/gpu/drm/i915/intel_dsi.c | 60 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) commit 43367ec962095b76d36453b659defd9ee8d41e46 Author: Ramalingam C <ramalingam.c@intel.com> Date: Thu Apr 7 14:36:06 2016 +0530 drm/i915: Sharing the pixel_format_from_vbt to whole i915 Shared the function pixel_format_from_vbt for whole display module. Function declaration is added to intel_dsi.h. V2: Moved the function to intel_dsi.c and renamed as per the purpose of the function. Suggested by Jani. Signed-off-by: Ramalingam C <ramalingam.c@intel.com> Previously reviewed at https://lists.freedesktop.org/archives/intel-gfx/2016-April/091736.html Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460019967-26501-1-git-send-email-ramalingam.c@intel.com drivers/gpu/drm/i915/intel_dsi.c | 18 ++++++++++++++++++ drivers/gpu/drm/i915/intel_dsi.h | 1 + drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 23 +++-------------------- 3 files changed, 22 insertions(+), 20 deletions(-) commit 95d1c8951e5bd50bb89654a99a7012b1e75646bd Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Wed Apr 6 10:19:58 2016 -0700 HID: simplify implement() a bit The 'size' variable is not really needed, and we can also shift constant in the loop body when masking off existing bits. Also we do not have to use 64 bit calculations if we take an extra branch. [jkosina@suse.cz: fix a small error in changelog] Suggested-by: Doug Anderson <dianders@chromium.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-core.c | 33 +++++++++++++++------------------ 1 file changed, 15 insertions(+), 18 deletions(-) commit b13d8e2888f60a18556844ed8958fd32bff1827c Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Apr 7 16:36:54 2016 +0300 drm/i915/dsi: use a temp variable for referencing the gpio table The shorthand is easier. Also change the struct name. No functional changes. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/6572c108424a67b02367ea69cbbe00a03af9b958.1459884518.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) commit 515d07dedcc79aee89bd5b9483f4352c9272de41 Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Apr 5 22:30:50 2016 +0300 drm/i915/dsi: abstract VLV gpio element execution to a separate function Prepare for future. No functional changes. v2: Move earlier in the series. Use bool for gpio value. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> [Jani: restored fixme comment while applying.] Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/ee791fed271d7f31c34163de6c6be37d1b704ef3.1459884518.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 67 ++++++++++++++++-------------- 1 file changed, 35 insertions(+), 32 deletions(-) commit b0c91cd0a6c3e88e7cbf7c9f107384c027c0c1da Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Apr 5 22:30:49 2016 +0300 drm/i915/dsi: clean up vlv gpio table and definitions Define and store the pad base offset in the array, and reference the pconf0 and padval registers through macros. Add VLV prefixes to macros. Use spec nomenclature for pconf0 and padval. v2: Address Ville's review comments, squash another patch here. v3: Use the names Ville dug up in the specs. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/34932140b78a3de7f825c78380a08c930694651b.1459884518.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 87 ++++++++++++++---------------- 1 file changed, 39 insertions(+), 48 deletions(-) commit 7d6a7e782558323364bc0ae59f3523175c10b258 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Apr 7 09:11:11 2016 +0200 perf tools: Introduce trim function To be used in cases for both sides trim. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andreas Hollmann <hollmann@in.tum.de> Cc: David Ahern <dsahern@gmail.com> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1460013073-18444-1-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/ui/browsers/hists.c | 3 +-- tools/perf/ui/stdio/hist.c | 3 +-- tools/perf/util/util.h | 5 +++++ 3 files changed, 7 insertions(+), 4 deletions(-) commit e88ccab12a9e85c536544f1464bd75610b1c46d6 Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 5 12:39:32 2016 +0100 iommu/io-pgtable-arm-v7s: Support IOMMU_MMIO flag Teach the short-descriptor format to create Device mappings when asked. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/io-pgtable-arm-v7s.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) commit fb948251e4be1f4aedbe17ec96890ceee147c6d6 Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 5 12:39:31 2016 +0100 iommu/io-pgtable-arm: Support IOMMU_MMIO flag Teach the LPAE format to create Device mappings when asked. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Tested-by: Eric Auger <eric.auger@linaro.org> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/io-pgtable-arm.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 31e6850e0fdb3a586363cc4d2f9801cdf9374310 Author: Robin Murphy <robin.murphy@arm.com> Date: Tue Apr 5 12:39:30 2016 +0100 iommu: Add MMIO mapping type On some platforms, MMIO regions might need slightly different treatment compared to mapping regular memory; add the notion of MMIO mappings to the IOMMU API's memory type flags, so that callers can let the IOMMU drivers know to do the right thing. Signed-off-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> include/linux/iommu.h | 1 + 1 file changed, 1 insertion(+) commit a0d284d2b1d9f7453ff1c5cc7854219daf4f7590 Author: Andy Fleming <afleming@gmail.com> Date: Wed Mar 16 23:15:44 2016 -0500 powerpc: Fix incorrect PPC32 PAMU dependency The Freescale PAMU can be enabled on both 32 and 64-bit Power chips. Commit 477ab7a19ce restricted PAMU to PPC32. PPC covers both. Signed-off-by: Andy Fleming <afleming@gmail.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 2d1fe0734087f0d3adb77e2489843126e313387c Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Thu Apr 7 11:08:05 2016 +0300 drm/i915: Do not use {HAS_*, IS_*, INTEL_INFO}(dev_priv->dev) dev_priv is what the macro works hard to extract, pass it directly. > sed 's/\([A-Z].*(dev_priv\)->dev)/\1)/g' v2: - Include all wrapper macros too (Chris) v3: - Include sed cmdline (Chris) v4: - Break long line - Rebase Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1460016485-8089-1-git-send-email-joonas.lahtinen@linux.intel.com drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- drivers/gpu/drm/i915/i915_drv.c | 4 ++-- drivers/gpu/drm/i915/i915_gem_gtt.c | 4 ++-- drivers/gpu/drm/i915/i915_gpu_error.c | 7 +++--- drivers/gpu/drm/i915/i915_irq.c | 8 +++---- drivers/gpu/drm/i915/intel_audio.c | 2 +- drivers/gpu/drm/i915/intel_display.c | 36 +++++++++++++++--------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 2 +- drivers/gpu/drm/i915/intel_fifo_underrun.c | 4 ++-- drivers/gpu/drm/i915/intel_hdmi.c | 2 +- drivers/gpu/drm/i915/intel_i2c.c | 6 ++--- drivers/gpu/drm/i915/intel_pm.c | 14 ++++++------ drivers/gpu/drm/i915/intel_psr.c | 2 +- drivers/gpu/drm/i915/intel_runtime_pm.c | 12 +++++----- drivers/gpu/drm/i915/intel_uncore.c | 4 ++-- 15 files changed, 56 insertions(+), 55 deletions(-) commit 9458f4ba7d355ee2e4a082514c60443697f344ee Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Thu Apr 7 11:08:04 2016 +0300 drm/i915: Do not WARN_ON in i915_vm_to_ppgtt According to Chris, use of i915_vm_to_ppgtt is visible in benchmark unless WARN_ON is removed, so lets get rid of it. Cc: Chris Wilson <chris@chris-wilson.co.uk> Reported-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (v1) Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 - 1 file changed, 1 deletion(-) commit e5716f55753cdce9f6348e5778847e772af6c917 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Thu Apr 7 11:08:03 2016 +0300 drm/i915: Use i915_vm_to_ppgtt instead of manual container_of Looks much better without container_of everywhere. v2: - In i915_gem_restore_gtt_mappings too (Chris) v3: - Do not cause WARN by calling on non PPGTT object (Chris) Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_gem_gtt.c | 44 ++++++++++++++----------------------- 1 file changed, 16 insertions(+), 28 deletions(-) commit 9a4d3bf56c87be9ad8916e2013af04787d6bac9b Author: Wan Zongshun <Vincent.Wan@amd.com> Date: Fri Apr 1 09:06:05 2016 -0400 iommu/amd: Set AMD iommu callbacks for amba bus AMD Uart DMA belongs to ACPI HID type device, and its driver is basing on AMBA Bus, need also IOMMU support. This patch is just to set the AMD iommu callbacks for amba bus. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) commit b097d11a0fa3f97be88774d09ee9ed1d8532a7b0 Author: Wan Zongshun <Vincent.Wan@amd.com> Date: Fri Apr 1 09:06:04 2016 -0400 iommu/amd: Manage iommu_group for ACPI HID devices This patch creates a new function for finding or creating an IOMMU group for acpihid(ACPI Hardware ID) device. The acpihid devices with the same devid will be put into same group and there will have the same domain id and share the same page table. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) commit 2bf9a0a12749b2c45964020795859d4a1f228a1d Author: Wan Zongshun <Vincent.Wan@amd.com> Date: Fri Apr 1 09:06:03 2016 -0400 iommu/amd: Add iommu support for ACPI HID devices Current IOMMU driver make assumption that the downstream devices are PCI. With the newly added ACPI-HID IVHD device entry support, this is no longer true. This patch is to add dev type check and to distinguish the pci and acpihid device code path. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 69 ++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 60 insertions(+), 9 deletions(-) commit 7aba6cb9ee9db7849d0bf57891d9c7feb4e89457 Author: Wan Zongshun <Vincent.Wan@amd.com> Date: Fri Apr 1 09:06:02 2016 -0400 iommu/amd: Make call-sites of get_device_id aware of its return value This patch is to make the call-sites of get_device_id aware of its return value. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 51 +++++++++++++++++++++++++++++++++++++---------- 1 file changed, 41 insertions(+), 10 deletions(-) commit ca3bf5d47cec8b7614bcb2e9132c40081d6d81db Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Fri Apr 1 09:06:01 2016 -0400 iommu/amd: Introduces ivrs_acpihid kernel parameter This patch introduces a new kernel parameter, ivrs_acpihid. This is used to override existing ACPI-HID IVHD device entry, or add an entry in case it is missing in the IVHD. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> Documentation/kernel-parameters.txt | 7 +++++++ drivers/iommu/amd_iommu_init.c | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) commit 2a0cb4e2d423c8aeafa79945279246f6b35ea8cf Author: Wan Zongshun <Vincent.Wan@amd.com> Date: Fri Apr 1 09:06:00 2016 -0400 iommu/amd: Add new map for storing IVHD dev entry type HID This patch introduces acpihid_map, which is used to store the new IVHD device entry extracted from BIOS IVRS table. It also provides a utility function add_acpi_hid_device(), to add this types of devices to the map. Signed-off-by: Wan Zongshun <Vincent.Wan@amd.com> Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu.c | 1 + drivers/iommu/amd_iommu_init.c | 122 ++++++++++++++++++++++++++++++++++++++++ drivers/iommu/amd_iommu_types.h | 14 +++++ 3 files changed, 137 insertions(+) commit 8c7142f56fedfc6824b5bca56fee1f443e01746b Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Fri Apr 1 09:05:59 2016 -0400 iommu/amd: Use the most comprehensive IVHD type that the driver can support The IVRS in more recent AMD system usually contains multiple IVHD block types (e.g. 0x10, 0x11, and 0x40) for each IOMMU. The newer IVHD types provide more information (e.g. new features specified in the IOMMU spec), while maintain compatibility with the older IVHD type. Having multiple IVHD type allows older IOMMU drivers to still function (e.g. using the older IVHD type 0x10) while the newer IOMMU driver can use the newer IVHD types (e.g. 0x11 and 0x40). Therefore, the IOMMU driver should only make use of the newest IVHD type that it can support. This patch adds new logic to determine the highest level of IVHD type it can support, and use it throughout the to initialize the driver. This requires adding another pass to the IVRS parsing to determine appropriate IVHD type (see function get_highest_supported_ivhd_type()) before parsing the contents. [Vincent: fix the build error of IVHD_DEV_ACPI_HID flag not found] Signed-off-by: Wan Zongshun <vincent.wan@amd.com> Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu_init.c | 107 ++++++++++++++++++++++++++++++----------- 1 file changed, 78 insertions(+), 29 deletions(-) commit ac7ccf6765af5a255cec82fa95ec11f6c769022c Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Fri Apr 1 09:05:58 2016 -0400 iommu/amd: Modify ivhd_header structure to support type 11h and 40h This patch modifies the existing struct ivhd_header, which currently only support IVHD type 0x10, to add new fields from IVHD type 11h and 40h. It also modifies the pointer calculation to allow support for IVHD type 11h and 40h Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu_init.c | 35 +++++++++++++++++++++++++++++++++-- 1 file changed, 33 insertions(+), 2 deletions(-) commit 7d7d38afb3e8fdfebfd867cc0ff4b5c45c14053c Author: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Date: Fri Apr 1 09:05:57 2016 -0400 iommu/amd: Adding Extended Feature Register check for PC support The IVHD header type 11h and 40h introduce the PCSup bit in the EFR Register Image bit fileds. This should be used to determine the IOMMU performance support instead of relying on the PNCounters and PNBanks. Note also that the PNCouters and PNBanks bits in the IOMMU attributes field of IVHD headers type 11h are incorrectly programmed on some systems. So, we should not rely on it to determine the performance counter/banks size. Instead, these values should be read from the MMIO Offset 0030h IOMMU Extended Feature Register. Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/amd_iommu_init.c | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) commit 2364d423a7b34bd972761eeed1f764c962980c23 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Wed Apr 6 20:09:42 2016 -0500 ARM: socfpga: Enable Arria10 OCRAM ECC on startup Enable ECC for Arria10 On-Chip RAM on machine startup. The ECC has to be enabled and memory initialized before data is stored in memory otherwise the ECC will fail on reads. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Acked-by: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459991382-7859-1-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> arch/arm/mach-socfpga/ocram.c | 133 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 133 insertions(+) commit c7b4be8db8bc33ec60d21940b3d78b203cdffaac Author: Thor Thayer <tthayer@opensource.altera.com> Date: Wed Apr 6 20:22:54 2016 -0500 EDAC, altera: Add Arria10 OCRAM ECC support Add Arria10 On-Chip RAM ECC handling. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459992174-8015-1-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 78 ++++++++++++++++++++++++++++++++++++++++++++++ drivers/edac/altera_edac.h | 35 +++++++++++++++++++++ 2 files changed, 113 insertions(+) commit 6d54fb8a08a7b9ac06bbf4d7c41e6818d22e392f Author: Lee Jones <lee.jones@linaro.org> Date: Fri Sep 11 09:48:03 2015 +0100 ARM: multi_v7_defconfig: Enable ST's HW Random Number Generator Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/configs/multi_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit de6099e27ef33086d7a967bbfce078952312b74d Merge: 58a01d4 ba6cc7f Author: David S. Miller <davem@davemloft.net> Date: Thu Apr 7 00:06:38 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-04-06 This series contains updates to i40e and i40evf. Deepthi adds a debug message to display the MSIx vector count for hardware capabilities. Shannon removed the setting of debug_mask at startup to take care of an issue where all the device capabilities getting printed when we had not asked for it. Moved the NVM status out of the admin queue structure, since it should really stay with the other NVM data structures. Akeem added the flush routine to the end of the reset flow to avoid problems in the pass-through routines. Jesse moves a local variable deeper into the depths of the driver where the light is low and the context is great. Then cleaned up the tx_ring argument since it was not making good arguments. Improved performance by not "checking for FCoE" by re-ordering the FCoE checks. Anjali adds the support for changing a VF from non-trusted to trusted and vice-versa. Mitch adds opcodes and structures to support RSS configuration by PF driver on behalf of the VF driver. Fixed how the VLAN feature flags are set. Kiran added defines for RSS, flow director, flexible payload and IPv6. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d99e366fc90c9b6e6197584ecd3a185441452b0c Author: Arika Chen <arika.chen@huawei.com> Date: Wed Apr 6 21:02:11 2016 -0700 Revert "igb: Fix a deadlock in igb_sriov_reinit" This reverts commit 3eb14ea8d958 ("igb: Fix a deadlock in igb_sriov_reinit") It is the same as commit f468adc944ef ("igb: missing rtnl_unlock in igb_sriov_reinit()") There is no rtnl_lock() in igb_resume before, rtnl_unlock will cause a deadlock. Signed-off-by: Arika Chen <arika.chen@huawei.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 1 - 1 file changed, 1 deletion(-) commit 5bd0c0202aca1003a244b13792c09b40f73eadc0 Author: Jiri Benc <jbenc@redhat.com> Date: Tue Apr 5 16:25:07 2016 +0200 net: intel: remove dead links The Kconfig for Intel NICs references two different URLs for the "Adapter & Driver ID Guide". Neither of those two links works. The current URL seems to be http://www.intel.com/content/www/us/en/support/network-and-i-o/ethernet-products/000005584.html but given it's apparently constantly changing, there's no point in having it in the help text. Just keep a generic pointer to http://support.intel.com. Hopefully, this one will have a longer live. It still works, at least. Furthermore, remove a link to "the latest Intel PRO/100 network driver for Linux", this has no place in the mainline kernel and the latest Linux driver it offers is from 2006, anyway. Signed-off-by: Jiri Benc <jbenc@redhat.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/Kconfig | 80 +++++++------------------------------- 1 file changed, 14 insertions(+), 66 deletions(-) commit ba6cc7f6f194e3645368f87d951bedd7e3b75f39 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Apr 1 13:34:31 2016 -0700 i40evf: properly handle VLAN features Correctly set the VLAN feature flags after setting the rest of the netdev flags. And don't set them in hw_features, because these can't be controlled by the VF driver. Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 27 +++++++++++-------------- 1 file changed, 12 insertions(+), 15 deletions(-) commit 47c46778e1905721433a413b2522a8e2b3d6c354 Author: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com> Date: Fri Apr 1 03:56:13 2016 -0700 i40e/i40evf: Bump patch from 1.5.2 to 1.5.5 Signed-off-by: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 17a035be959ef0316ec86adb0c82ed3f057a853b Author: Kiran Patil <kiran.patil@intel.com> Date: Mon Apr 4 07:01:10 2016 -0700 i40e: Input set mask constants for RSS, flow director, and flex bytes Add defines for input set mask (RSS, flow director, flexible payload), including defines specific to IPv6. Change-ID: Ie95ef7d0916a4d6ca011c194283f959774c8dce9 Signed-off-by: Kiran Patil <kiran.patil@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_type.h | 33 +++++++++++++++++++++ drivers/net/ethernet/intel/i40evf/i40e_type.h | 42 +++++++++++++++++++++++++++ 2 files changed, 75 insertions(+) commit bab2fb60dcdd0f9d8715749d056ddd6c465b1875 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Apr 1 03:56:11 2016 -0700 i40e: Move NVM event wait check to NVM code The logic that checks AQ events for NVM done events is better kept in nvm.c with the rest of the nvmupdate handling code. Change-ID: I2ea58980df8ecaa3726b28a37bff3dfcb8df03dc Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_adminq.c | 31 +----------------------- drivers/net/ethernet/intel/i40e/i40e_nvm.c | 31 ++++++++++++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_prototype.h | 1 + 3 files changed, 33 insertions(+), 30 deletions(-) commit 585954f8b808def857771037392c1621f167fa92 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Apr 1 03:56:10 2016 -0700 i40e: Add RSS configuration to virtual channel Add opcodes and structures to support RSS configuration by PF driver on behalf of the VF drivers. This reduces complexity in the VF driver and allows us to support future hardware designs without modifying the VF driver. Change-ID: I8c75765c630eacb71f95967f1109a198542593ac Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl.h | 45 +++++++++++++++++++++-- drivers/net/ethernet/intel/i40evf/i40e_virtchnl.h | 45 +++++++++++++++++++++-- 2 files changed, 84 insertions(+), 6 deletions(-) commit 437f82a2290ed94f0d6a86b749101f1ad5ed6231 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Apr 1 03:56:09 2016 -0700 i40e: Move NVM variable out of AQ struct The NVM update status info should stay collected together, not spread across different structs. Change-ID: Ic16f9e9fd79945d865bb7226184c889884585025 Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_adminq.c | 6 +++--- drivers/net/ethernet/intel/i40e/i40e_adminq.h | 1 - drivers/net/ethernet/intel/i40e/i40e_nvm.c | 12 ++++++------ drivers/net/ethernet/intel/i40e/i40e_type.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_adminq.h | 1 - drivers/net/ethernet/intel/i40evf/i40e_type.h | 1 + 6 files changed, 11 insertions(+), 11 deletions(-) commit 14c5f5d264c3ee28e8ec9fd4dffb29f5d1ea1d02 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Apr 1 03:56:08 2016 -0700 i40e: Restrict VF poll mode to only single function mode devices The VFs can request their queues to be set up into polling mode, rather than interrupt mode, which works well for supporting things like DPDK, but this should not be available when working in an multi-function support device. Change-ID: Id36792e4e7422db8f2033336507211f68f14ff6f Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit c3bbbd2002b9565475721bb17b17f48ef5927498 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Fri Apr 1 03:56:07 2016 -0700 i40e: Patch to support trusted VF This patch adds hook to support changing a VF from not-trusted to trusted and vice-versa. Fixed the wrappers and function prototype. Changed the dmesg to reflex the current state better. This patch also disables turning on/off trusted VF in MFP mode. Change-ID: Ibcd910935c01f0be1f3fdd6d427230291ee92ebe Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 42 ++++++++++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.h | 2 ++ 3 files changed, 45 insertions(+) commit 1f15d66712bb64e39fe2c23b1b32f68f9e1d4ee7 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Fri Apr 1 03:56:06 2016 -0700 i40e/i40evf: Faster RX via avoiding FCoE As it turns out, calling into other files from hot path hurts performance a lot. In this case the majority of the time we call "check FCoE" and the packet is *not* FCoE, but this call was taking 5% of our total cycles spent on receive. Change-ID: I080552c26e7060bc7b78504dc2763f6f0b3d8c76 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 12 +----------- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 8 ++++++-- drivers/net/ethernet/intel/i40e/i40e_txrx.h | 10 ++++++++++ drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 4 +++- drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 10 ++++++++++ 5 files changed, 30 insertions(+), 14 deletions(-) commit 84b079928a10559ebc6679e1e973a3ee5b20ba83 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Fri Apr 1 03:56:05 2016 -0700 i40e/i40evf: Drop unused tx_ring argument Some of the tx_ring arguments can be deleted since they are not used. Change-ID: I99275b0f191d7f63ec2f05061919904940c36f31 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 6 ++---- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) commit d1bd743b5b4d675e739b574284d1412ba996fe07 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Fri Apr 1 03:56:04 2016 -0700 i40e/i40evf: Move stack var deeper A local variable could move down inside the context where it is used. Change-ID: I9caba9e1eacf921037077f2665cbce83fd8e95d6 Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 3 ++- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 30728c5bdf2ac6618eebf6949a2e59b3c4cf640f Author: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Date: Fri Apr 1 03:56:03 2016 -0700 i40e: Move HW flush This patch moves the HW flush routine to the end of the reset flow, after the completion of writing to the device VFLR registers- the benefit is to avoid problems in the passthrough routines. Change-ID: Ieb56866f21895e6c1fc514b7328c3df79807a57c Signed-off-by: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 1 + 1 file changed, 1 insertion(+) commit 89dd05512b79ee9ba0950f1ba1fb8077ec898ea2 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Apr 1 03:56:02 2016 -0700 i40e: Leave debug_mask cleared at init Don't set our internal debug_mask at startup unless we get specific signal to from the debug module parameter. This should take care of the issue with all the device capabilities getting printed even when we hadn't asked for the debug info. Change-ID: I7fbc6bd8b11ed9b0631ec018ff36015a04100b6c Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 1 - 1 file changed, 1 deletion(-) commit 453e16e8e8b96821111e8d90252f4df8ec418eea Author: Deepthi Kavalur <deepthi.kavalur@intel.com> Date: Fri Apr 1 03:56:01 2016 -0700 i40e: Inserting a HW capability display info Display MSIx vector count for HW capabilities. Change-ID: I4b41e9b50360cf660e7fbcb85b9390fedcf313b1 Signed-off-by: Deepthi Kavalur <deepthi.kavalur@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 3 +++ 1 file changed, 3 insertions(+) commit fbf15046f12d6c8d5821c0dc5bf3ffc55a132243 Author: Heiko Stuebner <heiko@sntech.de> Date: Wed Mar 30 17:33:24 2016 +0200 ARM: dts: rockchip: move rk3036 memory definition to board files The amount of available memory is clearly a board-specific value, so the core per-soc dtsi should not define a default of any sort. Therefore move the memory-nodes to the two board files. Also fix the amount of memory on Kylin (512MB instead of 1GB). While in most cases the bootloader will override this with the actual amount of memory, there is no need to keep known wrong values in the board-dts. Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3036-evb.dts | 5 +++++ arch/arm/boot/dts/rk3036-kylin.dts | 5 +++++ arch/arm/boot/dts/rk3036.dtsi | 5 ----- 3 files changed, 10 insertions(+), 5 deletions(-) commit 37aedb29b9f053215a5a0dfb15ecc49af67c1fbc Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Dec 14 17:18:42 2015 +0100 ARM: dts: rockchip: enable the eDP on rk3288 veyron devices After hooking up panel and backlight informations, enable the edp on veyron chromebooks now. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-chromebook.dtsi | 43 +++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit 03deaf4a814425ceb67c73c1b1b9ada1ee929ca5 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Dec 14 17:15:25 2015 +0100 ARM: dts: rockchip: simple panel and backlight supplies on veyron boards Jerry and Speedy don't need any special handling wrt the backlight or panel, so only need their backlight and panel-regulators hooked up. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-jerry.dts | 8 ++++++++ arch/arm/boot/dts/rk3288-veyron-speedy.dts | 8 ++++++++ 2 files changed, 16 insertions(+) commit 2f171d4043cf574cc003b3cbe0325b2fd02c2a43 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Dec 14 17:12:47 2015 +0100 ARM: dts: rockchip: override edp hpd handling on veyron-pinky and speedy Pinky boards don't have the hotplug pin connected. So remove the hotplug pinctrl setting and enable the force-hpd option, to allow them to find the display too. While on speedy boards, the hotplug pin is connected, judging by comments in a chromeos change it seems the "panels HPD voltage is too low to be detected", so it also needs the forced hotplug, as we of course also know that a display is connected. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-pinky.dts | 7 +++++++ arch/arm/boot/dts/rk3288-veyron-speedy.dts | 7 +++++++ 2 files changed, 14 insertions(+) commit 712e6051c440a41f5e797412afa7b246d27adc69 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Dec 14 11:39:58 2015 +0100 ARM: dts: rockchip: add rk3288-veyron-minnie backlight and panel settings The pwm for Minnie's backlight needs to be above 1%, so adapt the start of non-zero brightness accordingly. Minnie is also using a different panel, so re-set the compatible property. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-minnie.dts | 43 ++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) commit d8444fed59261f0342095e5a259386baf929f92e Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Dec 7 21:11:08 2015 +0800 ARM: dts: rockchip: add rk3288-veyron-jaq backlight and panel overrides The panel which jaq uses requires the pwm duty cycle larger than 3%, when the backlight status from power off to power on, otherwise the backlight will flush, so we modify the second brightness-level to 8, and when the backlight from power off to power on the pwm duty cycle will larger than 3%. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-jaq.dts | 42 +++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) commit dfb2146efc6b07f1a6cc04938248c2ce948c9c98 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Dec 14 11:32:28 2015 +0100 ARM: dts: rockchip: add core rk3288-veyron backlight and panel nodes Many Veyron chromebooks share the same panel type, so define the core settings for all of them and allow the few runaways to override it later. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-chromebook.dtsi | 57 +++++++++++++++++++++++++ 1 file changed, 57 insertions(+) commit 1f45e8c6d0161f044d679f242fe7514e2625af4a Author: Heiko Stuebner <heiko@sntech.de> Date: Sun Nov 29 19:46:09 2015 +0100 ARM: dts: rockchip: add startup delay to rk3288-veyron panel-regulators The panels need a bit of time to actually turn on. If this isn't observed, this results in problems when trying talk to the panels and thus produces detection errors. 100ms seem to be a safe value for the time being. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-jaq.dts | 1 + arch/arm/boot/dts/rk3288-veyron-jerry.dts | 1 + arch/arm/boot/dts/rk3288-veyron-minnie.dts | 1 + arch/arm/boot/dts/rk3288-veyron-speedy.dts | 1 + 4 files changed, 4 insertions(+) commit a4e00345b29dbc93fe7e6f4070458f325261b0ac Author: Heiko Stuebner <heiko@sntech.de> Date: Wed Oct 28 00:19:37 2015 +0100 ARM: dts: rockchip: move edp-hpd pin definition into common location The edp hotplug pin is fixed on the soc side, anybody wanting to use it will need the same definition anyway, so move it to a common location. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron-jaq.dts | 6 ------ arch/arm/boot/dts/rk3288.dtsi | 6 ++++++ 2 files changed, 6 insertions(+), 6 deletions(-) commit 6df7ec6186644a4ffb4f0c859327ef41a1145a5f Author: Heiko Stuebner <heiko@sntech.de> Date: Wed Oct 28 10:55:19 2015 +0100 ARM: dts: rockchip: add rk3288 displayport controller node Add the rk3288 edp node and its hooks into the display-subsystem. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288.dtsi | 44 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) commit f5663969d8125a5c5b7835812e1e636ecedf030b Author: Heiko Stuebner <heiko@sntech.de> Date: Wed Oct 28 10:54:22 2015 +0100 ARM: dts: rockchip: add rk3288 edp-phy node Add the core device node of the edp-phy on rk3288 socs. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit 6691409224de8f7badc3f5d072c2bf72b223395d Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 22:15:43 2016 +0200 ARM: dts: rockchip: add missing unitname to cpu_leakage efuse The cpu_leakage efuse on rk3288 did get it right including the unitname but on both rk3066a and rk3188 it was missing, fix that. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> arch/arm/boot/dts/rk3066a.dtsi | 2 +- arch/arm/boot/dts/rk3188.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 6b241fcccb42ab96b3cdca7066cebd0f5cdd44e0 Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 20:37:40 2016 +0200 ARM: dts: rockchip: drop unneeded properties from mipi node The mipi controller node does contain an unused reg property as well as unnecessary #address-cells and #size-cells properties for subnodes not using addresses, so remove those to also make dtc happy. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> arch/arm/boot/dts/rk3288.dtsi | 4 ---- 1 file changed, 4 deletions(-) commit 8b30c899c7dd9eb92b957a3c112d3226a9ac1c3c Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 20:24:29 2016 +0200 ARM: dts: rockchip: clean up gpio-keys nodes Drop superfluous #address-cells and #size-cells, rename key-nodes to individual names and also use the key constants intead of numbers. Reported-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> arch/arm/boot/dts/rk3066a-bqcurie2.dts | 11 +++++------ arch/arm/boot/dts/rk3066a-rayeager.dts | 7 +++---- arch/arm/boot/dts/rk3188-radxarock.dts | 7 +++---- arch/arm/boot/dts/rk3288-evb.dtsi | 7 +++---- arch/arm/boot/dts/rk3288-firefly.dtsi | 7 +++---- arch/arm/boot/dts/rk3288-popmetal.dts | 8 +++----- arch/arm/boot/dts/rk3288-r89.dts | 7 +++---- 7 files changed, 23 insertions(+), 31 deletions(-) commit a8f0fa2764626d2dd808cfbe1a160f2939a36c88 Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 20:12:14 2016 +0200 ARM: dts: rockchip: fix missing usbphy unit-names The usbphy subnodes do have a reg property but no unitname, add them. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> arch/arm/boot/dts/rk3066a.dtsi | 4 ++-- arch/arm/boot/dts/rk3188.dtsi | 4 ++-- arch/arm/boot/dts/rk3288.dtsi | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) commit 95cface95b6a6a8de6e95de2c8a25a64fd0f3558 Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Mar 31 19:28:26 2016 +0200 ARM: dts: rockchip: fix rk3288 power-domain unit names The power-domain sub-nodes do have reg properties, but so far are missing the expected unit names. So add the missing ones. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Rob Herring <robh@kernel.org> arch/arm/boot/dts/rk3288.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 74813cebd678dd471b4fcd7d3019aecab9dbcedd Author: Raveendra Padasalagi <raveendra.padasalagi@broadcom.com> Date: Wed Apr 6 10:26:27 2016 -0700 Input: bcm_iproc_tsc - use syscon to access shared registers In Cygnus SOC touch screen controller registers are shared with ADC and flex timer. Using readl/writel could lead to race condition. So touch screen driver is enhanced to support register access using syscon framework API's to take care of mutually exclusive access. Signed-off-by: Raveendra Padasalagi <raveendra.padasalagi@broadcom.com> Reviewed-by: Ray Jui <ray.jui@broadcom.com> Reviewed-by: Scott Branden <scott.branden@broadcom.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> .../input/touchscreen/brcm,iproc-touchscreen.txt | 21 ++++-- arch/arm/boot/dts/bcm-cygnus.dtsi | 11 +++- drivers/input/touchscreen/bcm_iproc_tsc.c | 77 ++++++++++++---------- 3 files changed, 68 insertions(+), 41 deletions(-) commit d1d438a3b1eb64eb99fc918d13a52ded3e941d67 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 6 18:02:41 2016 -0300 perf trace: Beautify pid_t arguments When reading the syscall tracepoint /format file, look for arguments of type "pid_t" and attach the PID beautifier, that will do a lookup on the threads it knows, i.e. the ones that came from PERF_RECORD_COMM events and add the COMM after the pid in such args: Excerpt of a system wide trace for syscalls with pid_t args: 55602.977 ( 0.006 ms): bash/12122 setpgid(pid: 24347 (bash), pgid: 24347 (bash)) = 0 55603.024 ( 0.004 ms): bash/24347 setpgid(pid: 24347 (bash), pgid: 24347 (bash)) = 0 55691.527 (88.397 ms): bash/12122 wait4(upid: -1, stat_addr: 0x7ffe0cee1720, options: UNTRACED|CONTINUED) ... 55692.479 ( 0.952 ms): git/24347 wait4(upid: 24368, stat_addr: 0x7ffe030d5724) ... 55694.549 ( 2.070 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4fc10) = 24369 (pre-commit) 55694.575 ( 0.002 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4f650, options: NOHANG) = -1 ECHILD No child processes 55695.934 ( 0.010 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4f2d0, options: NOHANG) = 24370 (git) 55695.937 ( 0.001 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4f2d0, options: NOHANG) = -1 ECHILD No child processes 55717.963 ( 0.000 ms): pre-commit/24371 ... [continued]: wait4()) = 24372 55717.978 (21.468 ms): :24371/24371 wait4(upid: -1, stat_addr: 0x7ffc94f4f230) ... 55718.087 ( 0.109 ms): pre-commit/24371 wait4(upid: -1, stat_addr: 0x7ffc94f4f230) = 24373 (tr) 55718.187 ( 0.096 ms): pre-commit/24371 wait4(upid: -1, stat_addr: 0x7ffc94f4f230) = 24374 (wc) 55718.218 ( 0.002 ms): pre-commit/24371 wait4(upid: -1, stat_addr: 0x7ffc94f4eed0, options: NOHANG) = -1 ECHILD No child processes 55718.367 ( 0.005 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4f1d0, options: NOHANG) = 24371 (pre-commit) 55718.369 ( 0.001 ms): pre-commit/24368 wait4(upid: -1, stat_addr: 0x7ffc94f4f1d0, options: NOHANG) = -1 ECHILD No child processes 55741.021 (49.494 ms): git/24347 ... [continued]: wait4()) = 24368 (pre-commit) 74146.427 (18319.601 ms): git/24347 wait4(upid: 24375 (git), stat_addr: 0x7ffe030d6824) ... 74149.036 ( 0.891 ms): bash/24391 wait4(upid: -1, stat_addr: 0x7ffe0cee0560) = 24393 (sed) Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-75yl9hzjhb020iadc81gdj8t@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 110 ++++++++++++++++++++++-------------------- tools/perf/trace/beauty/pid.c | 18 +++++++ 2 files changed, 75 insertions(+), 53 deletions(-) commit 1f2f83f838489d386ecad9d0c77c3d6ec983102c Author: Stefan Assmann <sassmann@kpanic.de> Date: Wed Feb 3 09:20:51 2016 +0100 e1000: call ndo_stop() instead of dev_close() when running offline selftest Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent. Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all. Signed-off-by: Stefan Assmann <sassmann@kpanic.de> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000/e1000_ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000/e1000_main.c | 8 ++++---- 3 files changed, 8 insertions(+), 6 deletions(-) commit 4a462ce084d5beb92cfc68f53f88c035c82e6b59 Author: Jyri Sarha <jsarha@ti.com> Date: Thu Mar 31 16:35:59 2016 +0300 ALSA: pcm: Allow 32 bit sample format in IEC958 channel status helper Treat 32 bit sample width as if it was 24 bits when generating IEC958 channel status bits. On some platforms 24 sample width is problematic and to get full 24 bit precision a 32 bit format, using only the 24 most significant bits, may have to be used. Signed-off-by: Jyri Sarha <jsarha@ti.com> Reviewed-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Mark Brown <broonie@kernel.org> sound/core/pcm_iec958.c | 1 + 1 file changed, 1 insertion(+) commit 58a01d4dc43e60208b70ce08604b5bcbb907f0d1 Merge: 92b6d35 d81a6bd Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 6 17:24:21 2016 -0400 Merge branch 'mlxsw-dcb' Jiri Pirko says: ==================== mlxsw: Introduce support for Data Center Bridging Ido says: This patchset introduces support for Quality of Service (QoS) as part of the IEEE Data Center Bridiging (DCB) standards. Patches 1-9 do the required device initialization. Specifically, patches 1-6 initialize the ports' headroom buffers, which are used at ingress to store incoming packets while they go through the switch's pipeline. Patches 7-9 complete them by initializing the egress scheduling. The pipeline mentioned above determines the packet's egress port(s) and traffic class. Ideally, once out of the pipeline the packet moves to the switch's shared buffer (to be introduced in Jiri's patchset, currently default values are used) and scheduled for transmission according to its traffic class. The egress scheduling is configured according to the 802.1Qaz standard, which is part of the DCB infrastructure supported by Linux. This is introduced in patches 10-12. Even after going through the pipeline packets are not always eligible to enter the shared buffer. This is determined by the amount of available space and the quotas associated with the packet. However, if flow control is enabled and the packet is associated with the lossless flow, then it will stay in the headroom and won't be discarded. This is introduced in patches 13-17. Please check individual commit messages for more info, as I tried to keep them pretty detailed. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit d81a6bdb87ce75337b453169ee39cdccb3286ddf Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:16 2016 +0200 mlxsw: spectrum: Add IEEE 802.1Qbb PFC support Implement the appropriate DCB ops and allow a user to configure certain traffic classes as lossless. The operation configures PFC for both the egress (respecting PFC frames) and ingress (sending PFC frames) parts of the port. At egress, when a PFC frame is received for a PFC enabled priority, then all the priorities mapped to the same TC are stopped. At ingress, the priority group (PG) buffers to which the enabled PFC priorities are mapped are configured to be lossless. PFC frames will be transmitted when the Xoff threshold is crossed. The user-supplied delay parameter is used to determine the PG's size according to the following formula: PG_SIZE = PG_SIZE_LOSSY + delay * CELL_FACTOR + MTU In the worst case scenario the delay will be made up of packets that are all of size CELL_SIZE + 1, which means each packet will require almost twice its true size when buffered in the switch. We therefore multiply this value by the "cell factor", which is close to 2. Another MTU is added in case the transmitting host already started transmitting a maximum length frame when the PFC packet was received. As with PAUSE enabled ports, when the port's MTU is changed both the PGs' size and threshold are adjusted accordingly. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 10 ++ drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 30 ++++-- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 12 ++- drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 117 ++++++++++++++++++++- 4 files changed, 158 insertions(+), 11 deletions(-) commit 34dba0a59d072201171be1aeb9e52d1148d7c365 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:15 2016 +0200 mlxsw: reg: Introduce per priority counters We are going to add support for PFC as part of DCB ops, which requires us to report the number of PFC frames sent and received per priority. Add per priority counters in order to report number of PFC frames sent and received per priority. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 62 ++++++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 3 +- drivers/net/ethernet/mellanox/mlxsw/switchx2.c | 3 +- 3 files changed, 63 insertions(+), 5 deletions(-) commit 9f7ec052b75e1fd8a4cc876349a665f5b76669d5 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:14 2016 +0200 mlxsw: spectrum: Add support for PAUSE frames When a packet ingress the switch it's placed in its assigned priority group (PG) buffer in the port's headroom buffer while it goes through the switch's pipeline. After going through the pipeline - which determines its egress port(s) and traffic class - it's moved to the switch's shared buffer awaiting transmission. However, some packets are not eligible to enter the shared buffer due to exceeded quotas or insufficient space. Marking their associated PGs as lossless will cause the packets to accumulate in the PG buffer. Another reason for packets accumulation are complicated pipelines (e.g. involving a lot of ACLs). To prevent packets from being dropped a user can enable PAUSE frames on the port. This will mark all the active PGs as lossless and set their size according to the maximum delay, as it's not configured by user. +----------------+ + | | | | | | | | | | | | | | | | | | Delay | | | | | | | | | | | | | | | Xon/Xoff threshold +----------------+ + | | | | | | 2 * MTU | | | +----------------+ + The delay (612 [Cells]) was calculated according to worst-case scenario involving maximum MTU and 100m cables. After marking the PGs as lossless the device is configured to respect incoming PAUSE frames (Rx PAUSE) and generate PAUSE frames (Tx PAUSE) according to user's settings. Whenever the port's headroom configuration changes we take into account the PAUSE configuration, so that we correctly set the PG's type (lossy / lossless), size and threshold. This can happen when: a) The port's MTU changes, as it directly affects the PG's size. b) A PG is created following user configuration, by binding a priority to it. Note that the relevant SUPPORTED flags were already mistakenly set by the driver before this commit. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 85 ++++++++++++++++++++-- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 17 ++++- drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 3 +- 3 files changed, 95 insertions(+), 10 deletions(-) commit 155f9de2e09547ed510b86a4b463c2980e7df46a Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:13 2016 +0200 mlxsw: reg: Add lossless settings for PBMC register When configuring PAUSE frames and PFC we'll need to configure the Xon/Xoff threshold for the priority group (PG) buffers. Add the Xon/Xoff threshold fields to the PBMC register so that we can configure these when needed. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 35 +++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 6f253d8381e9e7b8a254e7384b7d32ea5784e6e8 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:12 2016 +0200 mlxsw: reg: Add Port Flow Control Configuration register Add the Port Flow Control Configuration (PFCC) register, which configures both flow control and Priority-based Flow Control (PFC). Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 131 ++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) commit cc7cf5175807daa9cb51f6e0eb034f60ced6b251 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:11 2016 +0200 mlxsw: spectrum: Allow setting maximum rate for a TC Allow a user to set maximum rate for a particular TC using DCB ops. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 6 +- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 4 ++ drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 70 ++++++++++++++++++++++ 3 files changed, 77 insertions(+), 3 deletions(-) commit 8e8dfe9fdf063cd61f35ed82f5be463791a613a5 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:10 2016 +0200 mlxsw: spectrum: Add IEEE 802.1Qaz ETS support Implement the appropriate DCB ops and allow a user to configure: * Priority to traffic class (TC) mapping with a total of 8 supported TCs * Transmission selection algorithm (TSA) for each TC and the corresponding weights in case of weighted round robin (WRR) As previously explained, we treat the priority group (PG) buffer in the port's headroom as the ingress counterpart of the egress TC. Therefore, when a certain priority to TC mapping is configured, we also configure the port's headroom buffer. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 53 ++++- drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 11 + drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 229 +++++++++++++++++++++ 3 files changed, 283 insertions(+), 10 deletions(-) commit f00817df2b428ec13711bd27729f992b8c3af054 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:09 2016 +0200 mlxsw: spectrum: Introduce support for Data Center Bridging (DCB) Introduce basic infrastructure for DCB and add the missing ops in following patches. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/Kconfig | 8 +++ drivers/net/ethernet/mellanox/mlxsw/Makefile | 1 + drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 10 ++++ drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 17 ++++++ drivers/net/ethernet/mellanox/mlxsw/spectrum_dcb.c | 65 ++++++++++++++++++++++ 5 files changed, 101 insertions(+) commit 90183b980d0af77df2369dee924fff13c792dcc5 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:08 2016 +0200 mlxsw: spectrum: Initialize egress scheduling Before introducing support for DCB ops we should first make sure we initialize the relevant parts in the device correctly. Specifically, the egress scheduling. The device supports a superset of the 802.1Qaz standard with 4 hierarchy levels that can be linked to each other in multiple ways and with different transmission selection algorithms (TSA) employed between them. However, since we only intend to support the 802.1Qaz standard we flatten the hierarchies and let the user configure via DCB ops the TSA and max rate shaper at the subgroup hierarchy (see figure below) and the mapping between switch priority to traffic class. By default, all switch priorities are mapped to traffic class 0, strict priority is employed and max shaper is disabled. Default configuration: switch priority 0 ... switch priority 7 + + | | +----------------------------------+ | +--v--+ +-----+ Traffic Class | | | | Hierarchy | TC0 | ... | TC7 | | | | | +--+--+ +--+--+ | | +--v--+ +--v--+ Subgroup | SG0 | | SG7 | Hierarchy | | | | +-----+ +-----+ | TSA | | TSA | +-----+ ... +-----+ | MAX | | MAX | +--+--+ +--+--+ | | +---------------+----------------+ | +--v--+ Group | | Hierarchy | GR0 | | | +--+--+ | +--v--+ Port | | Hierarchy | PR0 | | | +-----+ Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 111 +++++++++++++++++++++++++ 1 file changed, 111 insertions(+) commit 2c63a555e8495f3d6db443ca73094a6a3508df4a Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:07 2016 +0200 mlxsw: reg: Add QoS Switch Traffic Class Table register As part of DCB ops we'll have to configure the priority to traffic class mapping of a port. Add the QoS Switch Traffic Class Table (QTCT) register, which configures the mapping between the packet switch priority and traffic class on the transmit port. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 55 +++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) commit b9b7cee405797cc395f699d8dee4747b96b1e0a8 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:06 2016 +0200 mlxsw: reg: Add QoS ETS Element Configuration register We are going to introduce support for DCB, so we need to be able to configure the traffic selection algorithm (TSA) used by each traffic class (TC), as well as the bandwidth percentage allocated to each TC in case of ETS. Add the QoS ETS Element Configuration register, which controls the above parameters. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 127 ++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) commit d6b7c13b018f1785743150f079638bb3ed69fff1 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:05 2016 +0200 mlxsw: spectrum: Set port's shared buffer size to 0 In addition to the priority group (PG) buffers in the headroom, the device enables the allocation of headroom shared buffer, which can be shared between different PGs. However, we are not going to use the headroom shared buffer and instead allow the user to use its size for PGs or the switch's shared buffer. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 2 ++ drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 2 ++ 2 files changed, 4 insertions(+) commit 7ad7cd6113bacace67c55cadef6459eb0e74403d Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:04 2016 +0200 mlxsw: reg: Use correct PBMC register length The last field of the PBMC register is at offset 0x64 and its size is 0x8, so the correct register's length is 0x6C bytes. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ff6551ec0c2748a31087878f00bcaf6db2f82116 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:03 2016 +0200 mlxsw: spectrum: Correctly configure headroom size When packets ingress the switch they are assigned a switch priority and directed to the corresponding priority group (PG) buffer in the port's headroom buffer. Since we now map all switch priorities to priority group 0 (PG0) by default, there is no need to allocate the other priority groups during initialization. The only exception is PG9, which is used for control traffic. At minimum, the PG should be able to store the currently classified packet (pipeline latency isn't 0) and also the packets arriving during the classification time. However, an incoming packet will not be buffered if there is no available MTU-sized buffer space for storing it. The buffer needed to accommodate for pipeline latency is variable and needs to take into account both the current link speed and current latency of the pipeline, which is time-dependent. Testing showed that setting the PG's size to twice the current MTU is optimal. Since PG9 is used strictly for control packets and not subject to flow control, we are not going to resize it according to user configuration, so we simply set it according to worst case scenario, which is twice the maximum MTU. In any case, later patches in the series will allow a user to direct lossless flows to other PGs than PG0 and set their size to accommodate for round-trip propagation delay. The above change also requires us to resize the PG buffer whenever the port's MTU is changed. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 25 +++++++++++++++++++++- .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 19 ++++++++-------- 2 files changed, 34 insertions(+), 10 deletions(-) commit 1a1984490f5c123ee62394bc435a2c09db15cc18 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:02 2016 +0200 mlxsw: spectrum: Add bytes to cells helper Buffers in the switch store packets in units called buffer cells. Add a helper to convert from bytes to cells, so that the actual number of cells required (result is round up) is returned. Also, drop the SB (shared buffer) acronym from the BYTES_PER_CELL macro, as this unit is also used in the ports' buffers and not only the switch's shared buffer. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 4 ++ .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 64 ++++++++++------------ 2 files changed, 34 insertions(+), 34 deletions(-) commit dd6cb0f9fdb31c4bf89e482031cd098bf5f706d4 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:01 2016 +0200 mlxsw: spectrum: Map all switch priorities to priority group 0 During transmission, the skb's priority is used to map the skb to a traffic class, where the idea is to group priorities with similar characteristics (e.g. lossy, lossless) to the same traffic class. By default, all priorities are mapped to traffic class 0. In the device, we model the skb's priority as the switch priority, which is assigned to a packet according to its PCP value and ingress port (untagged packets are assigned the port's default switch priority - 0). At ingress, the packet is directed to a priority group (PG) buffer in the port's headroom buffer according to the packet's switch priority and switch priority to buffer mapping. While it's possible to configure the egress mapping between skb's priority (switch priority) and traffic class, there is no mechanism to configure the ingress mapping to a PG. In order to keep things simple and since grouping certain priorities into a traffic class at egress also implies they should be grouped the same at ingress, treat a PG as the ingress counterpart of an egress traffic class. Having established the above, during initialization map all the switch priorities to PG0 in accordance with the Linux defaults for traffic class mapping. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> .../net/ethernet/mellanox/mlxsw/spectrum_buffers.c | 25 +++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) commit b98ff151b659b08f71cc2e21ce7044da6662b314 Author: Ido Schimmel <idosch@mellanox.com> Date: Wed Apr 6 17:10:00 2016 +0200 mlxsw: reg: Add Port Prio To Buffer register When packets ingress the switch they are assigned a switch priority number that dictates the packet's priority group (PG) buffer in the port's headroom buffer. Add the Port Prio To Buffer (PPTB) register, which configures the switch priority to PG mapping. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/reg.h | 83 +++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) commit d5ea45da1f04a3443710306e16db3b3aeae92918 Author: Stefan Assmann <sassmann@kpanic.de> Date: Wed Feb 3 09:20:52 2016 +0100 e1000e: call ndo_stop() instead of dev_close() when running offline selftest Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent. Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all. Signed-off-by: Stefan Assmann <sassmann@kpanic.de> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/e1000e/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000e/ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000e/netdev.c | 12 ++++++------ 3 files changed, 10 insertions(+), 8 deletions(-) commit 92b6d35fac3f15fa9f8e833030e3c743e04fb0e5 Merge: 6f55563 24d41e5 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 6 17:03:35 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-04-05 This series contains updates to i40e and i40evf only. Colin Ian King cleaned up a redundant NULL check which was found by static analysis. Anjali enables geneve receive offload for XL710/X710 devices. Mitch cleans up unused variable in i40e_vc_get_vf_resources_msg(). Fixed the driver to actually be able to adjust VLAN tagging features through ethtool, as expected. Fixed a problem where VF resets would get lost by the PF preventing the VF driver from initializing. Also put users mind at ease by lowering some message levels since many of these conditions can happen any time VFs are enabled or disabled and are not really indicative a fatal problems, unless they happen continuously. Shannon disables the link polling to lessen the admin queue traffic especially since the link event mask usage has been fixed recently. Alex Duyck fixes the i40e and i40evf drivers to correctly update checksums for frames up to 16776960 in length which should be more than large enough for all possible TSO frames in the near future. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 6f5556356a1ed288fd24f0521a9c606632ad9e1f Merge: 8a21ec4 e1e5314 Author: David S. Miller <davem@davemloft.net> Date: Wed Apr 6 16:50:33 2016 -0400 Merge branch 'vxlan-gpe' Jiri Benc says: ==================== vxlan: implement Generic Protocol Extension (GPE) v3: just rebased on top of the current net-next, no changes This patchset implements VXLAN-GPE. It follows the same model as the tun/tap driver: depending on the chosen mode, the vxlan interface is created either as ARPHRD_ETHER (non-GPE) or ARPHRD_NONE (GPE). Note that the internal fdb control plane cannot be used together with VXLAN-GPE and attempt to configure it will be rejected by the driver. In fact, COLLECT_METADATA is required to be set for now. This can be relaxed in the future by adding support for static PtP configuration; it will be backward compatible and won't affect existing users. The previous version of the patchset supported two GPE modes, L2 and L3. The L2 mode (now called "ether mode" in the code) was removed from this version. It can be easily added later if there's demand. The L3 mode is now called "raw mode" and supports also encapsulated Ethernet headers (via ETH_P_TEB). The only limitation of not having "ether mode" for GPE is for ip route based encapsulation: with such setup, only IP packets can be encapsulated. Meaning no Ethernet encapsulation. It seems there's not much use for this, though. If it turns out to be useful, we'll add it. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit e1e5314de08ba6003b358125eafc9ad9e75a950c Author: Jiri Benc <jbenc@redhat.com> Date: Tue Apr 5 14:47:13 2016 +0200 vxlan: implement GPE Implement VXLAN-GPE. Only COLLECT_METADATA is supported for now (it is possible to support static configuration, too, if there is demand for it). The GPE header parsing has to be moved before iptunnel_pull_header, as we need to know the protocol. v2: Removed what was called "L2 mode" in v1 of the patchset. Only "L3 mode" (now called "raw mode") is added by this patch. This mode does not allow Ethernet header to be encapsulated in VXLAN-GPE when using ip route to specify the encapsulation, IP header is encapsulated instead. The patch does support Ethernet to be encapsulated, though, using ETH_P_TEB in skb->protocol. This will be utilized by other COLLECT_METADATA users (openvswitch in particular). If there is ever demand for Ethernet encapsulation with VXLAN-GPE using ip route, it's easy to add a new flag switching the interface to "Ethernet mode" (called "L2 mode" in v1 of this patchset). For now, leave this out, it seems we don't need it. Disallowed more flag combinations, especially RCO with GPE. Added comment explaining that GBP and GPE cannot be set together. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 170 ++++++++++++++++++++++++++++++++++++++----- include/net/vxlan.h | 68 +++++++++++++++++ include/uapi/linux/if_link.h | 1 + 3 files changed, 222 insertions(+), 17 deletions(-) commit a6d5bbf34efa8330af7b0b1dba0f38148516ed97 Author: Jiri Benc <jbenc@redhat.com> Date: Tue Apr 5 14:47:12 2016 +0200 ip_tunnel: implement __iptunnel_pull_header Allow calling of iptunnel_pull_header without special casing ETH_P_TEB inner protocol. Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip_tunnels.h | 11 +++++++++-- net/ipv4/ip_tunnel_core.c | 8 ++++---- 2 files changed, 13 insertions(+), 6 deletions(-) commit 47e5d1b06305e73afc917f47b65490adb06c7194 Author: Jiri Benc <jbenc@redhat.com> Date: Tue Apr 5 14:47:11 2016 +0200 vxlan: move fdb code to common location in vxlan_xmit Handle VXLAN_F_COLLECT_METADATA before VXLAN_F_PROXY. The latter does not make sense with the former, as it needs populated fdb which does not happen in metadata mode. After this cleanup, the fdb code in vxlan_xmit is moved to a common location and can be later skipped for VXLAN-GPE which does not necessarily carry inner Ethernet header. v2: changed commit description to not reference L3 mode Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit 0c867c9bf84ce2a998f83725bd363f66ce84d548 Author: Jiri Benc <jbenc@redhat.com> Date: Tue Apr 5 14:47:10 2016 +0200 vxlan: move Ethernet initialization to a separate function This will allow to initialize vxlan in ARPHRD_NONE mode based on the passed rtnl attributes. v2: renamed "l2mode" to "ether". Signed-off-by: Jiri Benc <jbenc@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/vxlan.c | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) commit efea95d45e6ab4a30df9801f8e9bf68007ee9b43 Author: Doron Shikmoni <doron.shikmoni@gmail.com> Date: Wed Feb 17 09:34:25 2016 +0200 igb: Garbled output for "ethtool -m" Garbled output for "ethtool -m ethX", in igb-driven NICs with module / plugin EEPROM (i.e. SFP information). Each output data byte appears duplicated. In igb_ethtool.c, igb_get_module_eeprom() is reading the EEPROM via i2c; the eeprom offset for each word that's read via igb_read_phy_reg_i2c() was passed in #words, whereas it needs to be a byte offset. This patches fixes the bug. Signed-off-by: Doron Shikmoni <doron.shikmoni@gmail.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_ethtool.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8a21ec4e0abb99884ef2da3e4f950025f3bf7fd3 Author: Hariprasad Shenai <hariprasad@chelsio.com> Date: Tue Apr 5 09:52:21 2016 +0530 cxgb4/cxgb4vf: Deprecate module parameter dflt_msg_enable Message level can be set through ethtool, so deprecate module parameter which is used to set the same. Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 3 ++- drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 806ffb1d504927d1449397377eac63bb63489266 Author: John Holland <jotihojr@gmail.com> Date: Thu Feb 18 12:10:52 2016 +0100 igb: allow setting MAC address on i211 using a device tree blob The Intel i211 LOM PCIe Ethernet controllers' iNVM operates as an OTP and has no external EEPROM interface [1]. The following allows the driver to pickup the MAC address from a device tree blob when CONFIG_OF has been enabled. [1] http://www.intel.com/content/www/us/en/embedded/products/networking/i211-ethernet-controller-datasheet.html Signed-off-by: John Holland <jotihojr@gmail.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 7f0ba845607364c76009e396a31651fa3a24bd1c Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon Mar 7 09:30:21 2016 -0800 igb: Add support for bulk Tx cleanup & cleanup boolean logic This patch enables bulk free in Tx cleanup for igb and cleans up the boolean logic in the polling routines for igb in the hopes of avoiding any mix-ups similar to what occurred with i40e and i40evf. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 415cd2a645b2573f173cc52419049f9caacf9a47 Author: Alexander Duyck <aduyck@mirantis.com> Date: Fri Mar 18 16:06:53 2016 -0700 igb: Fix sparse warning about passing __beXX into leXX_to_cpup We were casting the addr as __beXX and then passing it into le32_to_cpu because the device expects the MAC address to be in network order even though the register set is little endian. Instead of casting it as __beXX we can just cast it as __leXX in order to maintain consistency since the region of memory is already in little endian order as far as we are concerned. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/igb/igb_main.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 4a4436573a6669516f73bac25016683d396ed4c4 Author: Jyri Sarha <jsarha@ti.com> Date: Thu Mar 31 16:35:58 2016 +0300 ALSA: pcm: add IEC958 channel status helper for hw_params Add IEC958 channel status helper that gets the audio properties from snd_pcm_hw_params instead of snd_pcm_runtime. This is needed to produce the channel status bits already in audio stream configuration phase. Signed-off-by: Jyri Sarha <jsarha@ti.com> Reviewed-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Mark Brown <broonie@kernel.org> include/sound/pcm_iec958.h | 2 ++ sound/core/pcm_iec958.c | 64 ++++++++++++++++++++++++++++++++++------------ 2 files changed, 49 insertions(+), 17 deletions(-) commit d9f5725fb00b87f99d6fc876d27f7d54ab351669 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Tue Mar 22 12:09:56 2016 +0800 mwifiex: advertise low priority scan feature Low priority scan handling code which delays or aborts scan operation based on Tx traffic is removed recently. The reason is firmware already takes care of it in our new feature scan channel gap. Hence we should advertise low priority scan support to cfg80211. This patch fixes a problem in which OBSS scan request from wpa_supplicant was being rejected by cfg80211. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Wei-Ning Huang <wnhuang@chromium.org> Tested-by: Wei-Ning Huang <wnhuang@chromium.org> Acked-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 1 + 1 file changed, 1 insertion(+) commit 3d43e031840057f9609da3c546787f05cd6c5518 Author: Colin Ian King <colin.king@canonical.com> Date: Sun Mar 20 17:34:52 2016 +0000 brcmfmac: sdio: remove unused variable retry_limit retry_limit has never been used during the life of this driver, so we may as well remove it as it is redundant. Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 3 --- 1 file changed, 3 deletions(-) commit 8b4c0009313f3d42e2540e3e1f776097dd0db73d Author: Vishal Thanki <vishalthanki@gmail.com> Date: Sat Mar 19 11:41:01 2016 +0100 rt2x00usb: Use usb anchor to manage URB With current driver, it is observed that a URB is not completed while the USB disconnect is initiated. Due to that, the URB completion handler is trying to access the resource which was freed as a part of USB disconnect. Managing the URBs with anchor will make sure that all the URBs are handled gracefully before device gets disconnected. Signed-off-by: Vishal Thanki <vishalthanki@gmail.com> Acked-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ralink/rt2x00/rt2x00.h | 3 +++ drivers/net/wireless/ralink/rt2x00/rt2x00dev.c | 3 +++ drivers/net/wireless/ralink/rt2x00/rt2x00usb.c | 21 +++++++++++++++++++-- 3 files changed, 25 insertions(+), 2 deletions(-) commit e32993eb3aed598790ba0c581796c357898bd8f0 Author: Colin Ian King <colin.king@canonical.com> Date: Fri Mar 18 16:20:48 2016 +0000 wl12xx: remove redundant null check on wl->scan.ssid ssid is an array of u8, so it can never be null, so the null check on wl->scan.ssid is redundant and can be removed. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/ti/wl12xx/scan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 466414a084a90a15b81601bdde0c5803dc061ecd Author: Joe Perches <joe@perches.com> Date: Thu Mar 17 17:00:21 2016 -0700 rtlwifi: btcoexist: Convert BTC_PRINTK to btc_<foo>_dbg Use a more common logging style. Miscellanea: o Add specific logging macros for ALGORITHM and INTERFACE types o Output the messages at KERN_DEBUG o Coalesce formats o Align arguments o Whitespace style adjustments for only these changes Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../realtek/rtlwifi/btcoexist/halbtc8192e2ant.c | 847 ++++++++++---------- .../realtek/rtlwifi/btcoexist/halbtc8723b1ant.c | 611 ++++++++------- .../realtek/rtlwifi/btcoexist/halbtc8723b2ant.c | 854 +++++++++------------ .../realtek/rtlwifi/btcoexist/halbtc8821a1ant.c | 652 ++++++++-------- .../realtek/rtlwifi/btcoexist/halbtc8821a2ant.c | 851 ++++++++++---------- .../realtek/rtlwifi/btcoexist/halbtcoutsrc.c | 4 +- .../realtek/rtlwifi/btcoexist/halbtcoutsrc.h | 17 +- 7 files changed, 1851 insertions(+), 1985 deletions(-) commit 1e812458206e3b787951868d6f8acaae5e3f4aca Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:41:04 2016 -0500 rtlwifi: rtl8821ae: Fix Smatch warnings Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c:1960 rtl8812ae_dm_txpower_tracking_callback_thermalmeter() warn: inconsistent indenting CHECK drivers/net/wireless/realtek/rtlwifi/rtl8821ae/trx.c drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c:455 phy_get_tx_swing_8812A() warn: inconsistent indenting drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c:517 phy_get_tx_swing_8812A() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c | 6 +++--- drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) commit b3c4201bce5e32a353e68e1daf2aed213b8495e7 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:41:03 2016 -0500 rtlwifi: rtl8723be: Fix Smatch warnings Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8723be/phy.c drivers/net/wireless/realtek/rtlwifi/rtl8723be/phy.c:1726 _rtl8723be_phy_path_a_rx_iqk() warn: inconsistent indenting drivers/net/wireless/realtek/rtlwifi/rtl8723be/phy.c:2304 _rtl8723be_phy_lc_calibrate() warn: inconsistent indenting drivers/net/wireless/realtek/rtlwifi/rtl8723be/phy.c:2609 _rtl8723be_phy_set_rf_power_state() warn: inconsistent indenting CHECK drivers/net/wireless/realtek/rtlwifi/rtl8723be/rf.c drivers/net/wireless/realtek/rtlwifi/rtl8723be/rf.c:306 _rtl8723be_get_txpower_writeval_by_regulatory() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8723be/phy.c | 10 ++++------ drivers/net/wireless/realtek/rtlwifi/rtl8723be/rf.c | 4 ++-- 2 files changed, 6 insertions(+), 8 deletions(-) commit 154fb486df3d8e2fb346dfb9777abe20b23e1d6f Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:41:02 2016 -0500 rtlwifi: rtl8723ae: Fix Smatch warning Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8723ae/hal_btc.c drivers/net/wireless/realtek/rtlwifi/rtl8723ae/hal_btc.c:137 rtl8723e_dm_bt_need_to_dec_bt_pwr() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8723ae/hal_btc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c42ceccec17056940d0c97da79ff14d71062cc28 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:41:01 2016 -0500 rtlwifi: rtl8192se: Fix Smatch warning Smatch lists the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c:648 rtl92s_phy_set_rf_power_state() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8192se/phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 05d9e1bba43b3b9e722ca06fc45b79d93374be18 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:41:00 2016 -0500 rtlwifi: rtl8192ee: Fix Smatch warning Smatch lists the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8192ee/trx.c drivers/net/wireless/realtek/rtlwifi/rtl8192ee/trx.c:371 rtl92ee_rx_query_desc() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8192ee/trx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de8a9a6eeb572f7f0e8a87df9f29264c04503af4 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:40:59 2016 -0500 rtlwifi: rtl8192c-common: Fix Smatch warning Smatch lists the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8192c/dm_common.c drivers/net/wireless/realtek/rtlwifi/rtl8192c/dm_common.c:243 rtl92c_dm_false_alarm_counter_statistics() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8192c/dm_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 844026f609fc35918228cbb9ff2fd48e373504f7 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:40:58 2016 -0500 rtlwifi: rtl8188ee: Fix Smatch warnings Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/rtl8188ee/dm.c drivers/net/wireless/realtek/rtlwifi/rtl8188ee/dm.c:1140 rtl88e_dm_check_txpower_tracking() warn: inconsistent indenting CHECK drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c:1906 _rtl88e_phy_lc_calibrate() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8188ee/dm.c | 2 +- drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) commit 2e074fab347e1231bc1da156a12b37b6f746712c Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:40:57 2016 -0500 rtlwifi: btcoexist: Fix Smatch warning Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8723b2ant.c drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8723b2ant.c:3078 btc8723b2ant_run_coexist_mechanism() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8723b2ant.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 37c52934c66810205707ddeb42eb08b06a5af4c4 Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Thu Mar 17 13:40:56 2016 -0500 rtlwifi: Fix Smatch warnings Smatch reports the following: CHECK drivers/net/wireless/realtek/rtlwifi/pci.c drivers/net/wireless/realtek/rtlwifi/pci.c:366 rtl_pci_check_buddy_priv() error: we previously assumed 'tpriv' could be null (see line 368) drivers/net/wireless/realtek/rtlwifi/pci.c:1216 _rtl_pci_init_struct() warn: inconsistent indenting Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/pci.c | 39 +++++++++++++++--------------- 1 file changed, 19 insertions(+), 20 deletions(-) commit baa1702290953295e421f0f433e2b1ff4815827c Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Wed Mar 16 13:33:35 2016 -0500 rtlwifi: btcoexist: Implement antenna selection The previous patch added an option to rtl8723be to manually select the antenna for those cases when only a single antenna is present, and the on-board EEPROM is incorrectly programmed. This patch implements the necessary changes in the Bluetooth coexistence driver. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: Stable <stable@vger.kernel.org> [V4.0+] Signed-off-by: Kalle Valo <kvalo@codeaurora.org> .../realtek/rtlwifi/btcoexist/halbtc8723b2ant.c | 9 ++++++-- .../realtek/rtlwifi/btcoexist/halbtcoutsrc.c | 27 +++++++++++++++++++++- .../realtek/rtlwifi/btcoexist/halbtcoutsrc.h | 2 +- .../wireless/realtek/rtlwifi/btcoexist/rtl_btc.c | 5 +++- 4 files changed, 38 insertions(+), 5 deletions(-) commit c18d8f5095715c56bb3cd9cba64242542632054b Author: Larry Finger <Larry.Finger@lwfinger.net> Date: Wed Mar 16 13:33:34 2016 -0500 rtlwifi: rtl8723be: Add antenna select module parameter A number of new laptops have been delivered with only a single antenna. In principle, this is OK; however, a problem arises when the on-board EEPROM is programmed to use the other antenna connection. The option of opening the computer and moving the connector is not always possible as it will void the warranty in some cases. In addition, this solution breaks the Windows driver when the box dual boots Linux and Windows. A fix involving a new module parameter has been developed. This commit adds the new parameter and implements the changes needed for the driver. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: Stable <stable@vger.kernel.org> [V4.0+] Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/realtek/rtlwifi/rtl8723be/hw.c | 5 +++++ drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c | 3 +++ drivers/net/wireless/realtek/rtlwifi/wifi.h | 3 +++ 3 files changed, 11 insertions(+) commit 0026b32d723e958bac8f335ba3f47825b11b7287 Author: Amitkumar Karwar <akarwar@marvell.com> Date: Wed Mar 16 07:46:16 2016 -0700 mwifiex: fix Tx timeout issue during suspend test Call netif_carrier_off/on while stoping/starting netdev queues. This fixes netdev watchdog warning and ->ndo_tx_timeout() invocation during suspend resume stress test. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Fixes: 54f008497b9f09f ('mwifiex: Empty Tx queue during suspend') Tested-by: Wei-Ning Huang <wnhuang@chromium.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/cfg80211.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 977bc523000d51693c4b083463dc93bbb692a662 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Tue Mar 15 10:06:10 2016 +0300 brcmfmac: uninitialized "ret" variable There is an error path where "ret" isn't initialized. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f8df33da2c9bbea3a72dff5326bb5de2ef8392d6 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:31:10 2016 +0100 mwifiex: Spelling s/minmum/minimum/, s/bandwidth/bandwith/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> drivers/net/wireless/marvell/mwifiex/tdls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97b9b84464086f97b7b5399ede45bdb64da7a017 Merge: 4da46ce 46167a8 Author: Kalle Valo <kvalo@codeaurora.org> Date: Wed Apr 6 21:16:01 2016 +0300 Merge tag 'iwlwifi-next-for-kalle-2016-03-30' of https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next * Support for Link Quality measurement (Aviya) * Improvements in thermal (Chaya Rachel) * Various cleanups (many people) * Improvements in firmware error dump (Golan) * More work 9000 devices and MSIx (Haim) * Continuation of the Dynamic Queue Allocation work (Liad) * Scan timeout to cope with buggy firmware (Luca) * D0i3 improvements (Luca) * Make the paging less memory hungry (Matti) * 9000 new Rx path (Sara) commit 281c114f8e80d3a86f18ccf7cb93460bad48fcbe Author: Matt Roper <matthew.d.roper@intel.com> Date: Tue Apr 5 14:37:19 2016 -0700 drm/i915/bxt: Set max cdclk frequency properly intel_update_max_cdclk() doesn't have a switch case for Broxton, so dev_priv->max_cdclk_freq gets set to whatever clock frequency we're currently running at (e.g., 144 MHz) rather than the true maximum. This causes our max dotclock to also be set too low and in turn leads mode verification to reject perfectly valid modes while loading EDID firmware blobs. Cc: Imre Deak <imre.deak@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459892239-14041-1-git-send-email-matthew.d.roper@intel.com drivers/gpu/drm/i915/intel_display.c | 2 ++ 1 file changed, 2 insertions(+) commit c65f10701ac68259043ccbfac1979778a1fd7846 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 6 14:55:18 2016 -0300 perf trace: Beautify set_tid_address, getpid, getppid return values Showing the COMM for that return, if available. # trace -e getpid,getppid,set_tid_address 490.007 ( 0.005 ms): sh/8250 getpid(...) = 8250 (sh) 490.014 ( 0.001 ms): sh/8250 getppid(...) = 7886 (make) 491.156 ( 0.004 ms): install/8251 set_tid_address(tidptr: 0x7f204a9d4ad0) = 8251 (install) ^C Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-psbpplqupatom9x4uohbxid5@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 3 +++ 1 file changed, 3 insertions(+) commit a280f7dd9f1a85eed242d0f62498bfc11520a1a3 Author: Kumar, Mahesh <mahesh1.kumar@intel.com> Date: Wed Apr 6 08:26:39 2016 -0700 drm/i915/skl+: Use plane size for relative data rate calculation Use plane size for relative data rate calculation. don't always use pipe source width & height. adjust height & width according to rotation. use plane size for watermark calculations also. v2: Address Matt's comments. Use intel_plane_state->visible to avoid divide-by-zero error. Where FB was present but not visible so causing total data rate to be zero, hence divide-by-zero. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93917 Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94044 Cc: drm-intel-fixes@lists.freedesktop.org Signed-off-by: Kumar, Mahesh <mahesh1.kumar@intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459956399-1296-1-git-send-email-matthew.d.roper@intel.com drivers/gpu/drm/i915/intel_pm.c | 42 +++++++++++++++++++++++++++-------------- 1 file changed, 28 insertions(+), 14 deletions(-) commit 11c8e39f5133aed9e0f8ffc624c7d5f64c97bc79 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 6 14:33:07 2016 -0300 perf trace: Infrastructure to show COMM strings for syscalls returning PIDs Starting with clone, waitid and wait4: # trace -e waitid,wait4 1.385 ( 1.385 ms): bash/12122 wait4(upid: -1, stat_addr: 0x7ffe0cee1720, options: UNTRACED|CONTINUED) = 1210 (ls) 1.426 ( 0.002 ms): bash/12122 wait4(upid: -1, stat_addr: 0x7ffe0cee1150, options: NOHANG|UNTRACED|CONTINUED) = 0 3.293 ( 0.604 ms): bash/1211 wait4(upid: -1, stat_addr: 0x7ffe0cee0560 ) = 1214 (sed) 3.342 ( 0.002 ms): bash/1211 wait4(upid: -1, stat_addr: 0x7ffe0cee01d0, options: NOHANG ) = -1 ECHILD No child processes 3.576 ( 0.016 ms): bash/12122 wait4(upid: -1, stat_addr: 0x7ffe0cee0550, options: NOHANG|UNTRACED|CONTINUED) = 1211 (bash) ^C# trace -e clone 0.027 ( 0.000 ms): systemd/1 ... [continued]: clone()) = 1227 (systemd) 0.050 ( 0.000 ms): systemd/1227 ... [continued]: clone()) = 0 ^C[root@jouet ~]# Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-lyf5d3y5j15wikjb6pe6ukoi@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) commit 57bb1369de36a72e2e13fde9c88663342f729ace Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Wed Apr 6 14:55:35 2016 +0530 spi: cadence: Fix some checkpatch warnings No functional change. Fixing some style related issues CHECK: multiple assignments should be avoided + new_ctrl_reg = ctrl_reg = cdns_spi_read(xspi, CDNS_SPI_CR); CHECK: Alignment should match open parenthesis +static void cdns_spi_config_clock_freq(struct spi_device *spi, + struct spi_transfer *transfer) CHECK: Please use a blank line after function/struct/union/enum declarations +} +static int cdns_prepare_message(struct spi_master *master, Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 5847609edb3c80be07e897e449a9bb579a0fe9d8 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed Apr 6 11:21:54 2016 +0100 ASoC: wm_adsp: Improve DSP error handling If we encounter an error on the DSP side whilst user-space is waiting on the poll we should call snd_compr_fragment_elapsed, although data is not actually available we want to wake user-space such that the error can be propagated out quickly. Additionally some versions of the DSP firmware are not super consistent about actually generating an IRQ if they encounter an error, as such we will check the DSP error status every time we run out of available data as well, to ensure we catch it. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 9771b18a0b374b6e6ecfa84c8b59d5ef79e969b1 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Wed Apr 6 11:21:53 2016 +0100 ASoC: wm_adsp: Factor out fetching of stream errors from the DSP Factor out the reading of the DSP error flag into its own function to support further improvements to the code. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 28 +++++++++++++++++++--------- 1 file changed, 19 insertions(+), 9 deletions(-) commit 7206b900e6e4b7f4c2e766eab64ea1ca5303e421 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 6 14:11:36 2016 -0300 perf trace: Beautify wait4/waitid 'options' argument # trace -e waitid,wait4 0.557 ( 0.557 ms): bash/27335 wait4(upid: -1, stat_addr: 0x7ffd02f449f0) = 27336 1.250 ( 0.685 ms): bash/27335 wait4(upid: -1, stat_addr: 0x7ffd02f449f0) = 27337 1.312 ( 0.002 ms): bash/27335 wait4(upid: -1, stat_addr: 0x7ffd02f44690, options: NOHANG) = -1 ECHILD No child processes 1.550 ( 0.015 ms): bash/3856 wait4(upid: -1, stat_addr: 0x7ffd02f44990, options: NOHANG|UNTRACED|CONTINUED) = 27335 1.552 ( 0.001 ms): bash/3856 wait4(upid: -1, stat_addr: 0x7ffd02f44990, options: NOHANG|UNTRACED|CONTINUED) = 0 # Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-i5vlo5n5jv0amt8bkyicmdxh@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 5 +++++ tools/perf/trace/beauty/waitid_options.c | 26 ++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) commit a3bca91f2fe54af502deaf277dd5ac0e18bffde4 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Apr 6 12:51:33 2016 -0300 perf trace: Beautify sched_setscheduler 'policy' argument $ trace -e sched_setscheduler chrt -f 1 usleep 1 chrt: failed to set pid 0's policy: Operation not permitted 0.005 ( 0.005 ms): chrt/19189 sched_setscheduler(policy: FIFO, param: 0x7ffec5273d70) = -1 EPERM Operation not permitted $ Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-i5vlo5n5jv0amt8bkyicmdxh@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 4 ++++ tools/perf/trace/beauty/sched_policy.c | 44 ++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) commit 314a8203b6de2df164399996ece1412ae8f6270d Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 6 09:49:47 2016 -0400 regulator: max77686: Use module_platform_driver() instead subsys initcall The driver's init and exit function don't do anything besides registering and unregistering the platform driver, so the module_platform_driver() macro could just be used instead of having separate functions. Currently the macro is not being used because the driver is initialized at subsys init call level but this isn't necessary since consumer devices are defined in the DT as dependencies so there's no need for init calls order. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/max77686-regulator.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit 5ab3c4949580a18e86b0bedd7b7b21c708192b91 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Apr 6 09:49:46 2016 -0400 regulator: s2mps11: Use module_platform_driver() instead subsys initcall The driver's init and exit function don't do anything besides registering and unregistering the platform driver, so the module_platform_driver() macro could just be used instead of having separate functions. Currently the macro is not being used because the driver is initialized at subsys init call level but this isn't necessary since consumer devices are defined in the DT as dependencies so there's no need for init calls order. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/s2mps11.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) commit 74d8b45fa344129b3dfd37019877ba68b1287e18 Author: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Date: Wed Apr 6 09:06:03 2016 +0300 regulator: twl: Fix a typo in twl4030_send_pb_msg Commit <2330b05c095bdeaaf1261c54cd2d4b9127496996> ("regulator: twl: Make sure we have access to powerbus before trying to write to it") has implemented the needed logic to correctly access powerbus through i2c, however it brought a typo when powerbus configuration is restored, which results in writing to a wrong register. Fix that by providing the correct register value. Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/twl-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 48a59edc63ed83283bf2d2523137ab0578feac1a Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Wed Apr 6 10:44:55 2016 +0530 dmaengine: vdma: Fix checkpatch.pl warnings This patch fixes the below checkpatch.pl warnings. WARNING: void function return statements are not generally useful + return; +} WARNING: void function return statements are not generally useful + return; +} WARNING: Missing a blank line after declarations + u32 errors = status & XILINX_VDMA_DMASR_ALL_ERR_MASK; + vdma_ctrl_write(chan, XILINX_VDMA_REG_DMASR, Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit a65cf5125b49f3d4703c02692609501166e23735 Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Wed Apr 6 10:38:09 2016 +0530 dmaengine: vdma: Fix race condition in Non-SG mode When VDMA is configured in Non-sg mode Users can queue descriptors greater than h/w configured frames. Current driver allows the user to queue descriptors upto h/w configured. Which is wrong for non-sg mode configuration. This patch fixes this issue. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/xilinx/xilinx_vdma.c | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) commit b72db4005fe4bf4af16d1436abd3c9d3aac991d1 Author: Kedareswara rao Appana <appana.durga.rao@xilinx.com> Date: Wed Apr 6 10:38:08 2016 +0530 dmaengine: vdma: Add 64 bit addressing support to the driver This VDMA is a soft ip, which can be programmed to support 32 bit addressing or greater than 32 bit addressing. When the VDMA ip is configured for 32 bit address space the buffer address is specified by a single register (0x5C for MM2S and 0xAC for S2MM channel). When the VDMA core is configured for an address space greater than 32 then each buffer address is specified by a combination of two registers. The first register specifies the LSB 32 bits of address, while the next register specifies the MSB 32 bits of address. For example, 5Ch will specify the LSB 32 bits while 60h will specify the MSB 32 bits of the first start address. So we need to program two registers at a time. This patch adds the 64 bit addressing support to the vdma driver. Signed-off-by: Anurag Kumar Vulisha <anuragku@xilinx.com> Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> .../devicetree/bindings/dma/xilinx/xilinx_vdma.txt | 4 ++ drivers/dma/Kconfig | 2 +- drivers/dma/xilinx/xilinx_vdma.c | 73 +++++++++++++++++++--- 3 files changed, 70 insertions(+), 9 deletions(-) commit bda850cd214e90b1be0cc25bc48c4f6ac53eb543 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:24 2016 +0100 PKCS#7: Make trust determination dependent on contents of trust keyring Make the determination of the trustworthiness of a key dependent on whether a key that can verify it is present in the supplied ring of trusted keys rather than whether or not the verifying key has KEY_FLAG_TRUSTED set. verify_pkcs7_signature() will return -ENOKEY if the PKCS#7 message trust chain cannot be verified. Signed-off-by: David Howells <dhowells@redhat.com> certs/system_keyring.c | 13 ++++--------- crypto/asymmetric_keys/pkcs7_key_type.c | 2 +- crypto/asymmetric_keys/pkcs7_parser.h | 1 - crypto/asymmetric_keys/pkcs7_trust.c | 18 +++--------------- crypto/asymmetric_keys/verify_pefile.c | 2 +- crypto/asymmetric_keys/x509_parser.h | 1 - include/crypto/pkcs7.h | 3 +-- include/linux/verification.h | 1 - kernel/module_signing.c | 2 +- 9 files changed, 11 insertions(+), 32 deletions(-) commit e68503bd6836ba765dc8e0ee77ea675fedc07e41 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:14:24 2016 +0100 KEYS: Generalise system_verify_data() to provide access to internal content Generalise system_verify_data() to provide access to internal content through a callback. This allows all the PKCS#7 stuff to be hidden inside this function and removed from the PE file parser and the PKCS#7 test key. If external content is not required, NULL should be passed as data to the function. If the callback is not required, that can be set to NULL. The function is now called verify_pkcs7_signature() to contrast with verify_pefile_signature() and the definitions of both have been moved into linux/verification.h along with the key_being_used_for enum. Signed-off-by: David Howells <dhowells@redhat.com> arch/x86/kernel/kexec-bzimage64.c | 18 ++------- certs/system_keyring.c | 45 ++++++++++++++++----- crypto/asymmetric_keys/Kconfig | 4 +- crypto/asymmetric_keys/mscode_parser.c | 21 ++++------ crypto/asymmetric_keys/pkcs7_key_type.c | 72 +++++++++++++-------------------- crypto/asymmetric_keys/pkcs7_parser.c | 21 +++++----- crypto/asymmetric_keys/verify_pefile.c | 40 +++++------------- crypto/asymmetric_keys/verify_pefile.h | 5 +-- include/crypto/pkcs7.h | 3 +- include/crypto/public_key.h | 14 ------- include/keys/asymmetric-type.h | 1 + include/keys/system_keyring.h | 7 +--- include/linux/verification.h | 50 +++++++++++++++++++++++ include/linux/verify_pefile.h | 22 ---------- kernel/module_signing.c | 5 ++- 15 files changed, 155 insertions(+), 173 deletions(-) commit ad3043fda39db0361d9601685356db4512e914be Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:34 2016 +0100 X.509: Fix self-signed determination There's a bug in the code determining whether a certificate is self-signed or not: if they have neither AKID nor SKID then we just assume that the cert is self-signed, which may not be true. Fix this by checking that the raw subject name matches the raw issuer name and that the public key algorithm for the key and signature are both the same in addition to requiring that the AKID bits match. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/x509_public_key.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 6c2dc5ae4ab719a61d19e8cef082226410b04ff8 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:34 2016 +0100 X.509: Extract signature digest and make self-signed cert checks earlier Extract the signature digest for an X.509 certificate earlier, at the end of x509_cert_parse() rather than leaving it to the callers thereof since it has to be called anyway. Further, immediately after that, check the signature on self-signed certificates, also rather in the callers of x509_cert_parse(). We note in the x509_certificate struct the following bits of information: (1) Whether the signature is self-signed (even if we can't check the signature due to missing crypto). (2) Whether the key held in the certificate needs unsupported crypto to be used. We may get a PKCS#7 message with X.509 certs that we can't make use of - we just ignore them and give ENOPKG at the end it we couldn't verify anything if at least one of these unusable certs are in the chain of trust. (3) Whether the signature held in the certificate needs unsupported crypto to be checked. We can still use the key held in this certificate, even if we can't check the signature on it - if it is held in the system trusted keyring, for instance. We just can't add it to a ring of trusted keys or follow it further up the chain of trust. Making these checks earlier allows x509_check_signature() to be removed and replaced with direct calls to public_key_verify_signature(). Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/pkcs7_verify.c | 38 +++------ crypto/asymmetric_keys/x509_cert_parser.c | 10 +++ crypto/asymmetric_keys/x509_parser.h | 7 +- crypto/asymmetric_keys/x509_public_key.c | 126 ++++++++++++++++++++---------- 4 files changed, 110 insertions(+), 71 deletions(-) commit 566a117a8b24e1ae2dfa817cf0c9eec092c783b5 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:33 2016 +0100 PKCS#7: Make the signature a pointer rather than embedding it Point to the public_key_signature struct from the pkcs7_signed_info struct rather than embedding it. This makes the code consistent with the X.509 signature handling and makes it possible to have a common cleanup function. We also save a copy of the digest in the signature without sharing the memory with the crypto layer metadata. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/pkcs7_parser.c | 38 +++++++++++++++----------- crypto/asymmetric_keys/pkcs7_parser.h | 10 +++---- crypto/asymmetric_keys/pkcs7_trust.c | 4 +-- crypto/asymmetric_keys/pkcs7_verify.c | 51 ++++++++++++++++++----------------- 4 files changed, 55 insertions(+), 48 deletions(-) commit 77d0910d153a7946df17cc15d3f423e534345f65 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:33 2016 +0100 X.509: Retain the key verification data Retain the key verification data (ie. the struct public_key_signature) including the digest and the key identifiers. Note that this means that we need to take a separate copy of the digest in x509_get_sig_params() rather than lumping it in with the crypto layer data. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/pkcs7_trust.c | 8 ++-- crypto/asymmetric_keys/pkcs7_verify.c | 20 +++++----- crypto/asymmetric_keys/x509_cert_parser.c | 40 ++++++++++---------- crypto/asymmetric_keys/x509_parser.h | 4 +- crypto/asymmetric_keys/x509_public_key.c | 61 ++++++++++++++++--------------- 5 files changed, 67 insertions(+), 66 deletions(-) commit a022ec02691cf68e1fe237d5f79d54aa95446cc6 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:33 2016 +0100 KEYS: Add identifier pointers to public_key_signature struct Add key identifier pointers to public_key_signature struct so that they can be used to retain the identifier of the key to be used to verify the signature in both PKCS#7 and X.509. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/signature.c | 4 ++++ include/crypto/public_key.h | 1 + 2 files changed, 5 insertions(+) commit 3b764563177c1e435ef3e2608271c07955f73ea6 Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:33 2016 +0100 KEYS: Allow authentication data to be stored in an asymmetric key Allow authentication data to be stored in an asymmetric key in the 4th element of the key payload and provide a way for it to be destroyed. For the public key subtype, this will be a public_key_signature struct. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/asymmetric_type.c | 7 +++++-- crypto/asymmetric_keys/public_key.c | 20 ++++++++++++++------ crypto/asymmetric_keys/signature.c | 14 ++++++++++++++ crypto/asymmetric_keys/x509_cert_parser.c | 2 +- include/crypto/public_key.h | 5 ++++- include/keys/asymmetric-subtype.h | 2 +- include/keys/asymmetric-type.h | 7 ++++--- 7 files changed, 43 insertions(+), 14 deletions(-) commit 864e7a816a0646a6d9aecbd59a8e366c39b8ad2d Author: David Howells <dhowells@redhat.com> Date: Wed Apr 6 16:13:33 2016 +0100 X.509: Whitespace cleanup Clean up some whitespace. Signed-off-by: David Howells <dhowells@redhat.com> crypto/asymmetric_keys/x509_public_key.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d7e7479b215e6ba581bc5e21f43a578e07017b5a Author: Jan Luebbe <jlu@pengutronix.de> Date: Sat Mar 26 12:28:25 2016 +0100 ARM: multi_v5_defconfig: Enable support for MX21/MX27 Although the SoC support was already enabled, the drivers and machines were missing. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/multi_v5_defconfig | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) commit fd84aa108a1daf2611374f31ddc3691d0ee24396 Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:51 2016 +0200 ARM: imx_v6_v7_defconfig: add CONFIG_RTC_DRV_M41T80 The rv4168 RTC is used by the following platforms: - Nitrogen6_MAX (both Quad and Quad Plus versions) - Nitrogen7 Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/imx_v6_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit e70e18d6e017755c4b635107e088f4e658db9493 Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:50 2016 +0200 ARM: imx_v6_v7_defconfig: add CONFIG_I2C_MUX_GPIO I2C muxing is used on Nitrogen6_MAX board from Boundary Devices. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/imx_v6_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit 6fbe99046de430bf68232e464c1aad3b3546dc1a Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:49 2016 +0200 ARM: imx_v6_v7_defconfig: add FT5x06 and TSC2004 touch support Those two touch controllers are used by Boundary Devices platforms. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm/configs/imx_v6_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 85f8f966a152f5110a12b76511743fbfb62130ba Author: Andi Kleen <ak@linux.intel.com> Date: Mon Apr 4 15:58:06 2016 -0700 perf list: Document event specifications better Document some features for specifying events in the perf list manpage: - Event groups - Leader sampling - How to specify raw PMU events in the new syntax - Global versus per process PMUs. - Access restrictions - Fix Intel SDM URL v2: Lots of new content. address review feedback. Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Link: http://lkml.kernel.org/r/1459810686-15913-1-git-send-email-andi@firstfloor.org [ Add quotes to some keywords, such as "any" ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-list.txt | 107 ++++++++++++++++++++++++++++++++- 1 file changed, 106 insertions(+), 1 deletion(-) commit 860b69f1d533de39fa70784768008d0eaf242e5c Author: Jiri Olsa <jolsa@kernel.org> Date: Tue Apr 5 17:01:52 2016 +0200 perf tools: Remove superfluous ARCH Makefile includes Link: http://lkml.kernel.org/n/tip-yk6brsq3opuotr9by18xlkr8@git.kernel.org Signed-off-by: Jiri Olsa <jolsa@kernel.org> tools/perf/Makefile.perf | 2 -- tools/perf/config/Makefile | 3 --- 2 files changed, 5 deletions(-) commit 76e20522b709f3772e415d70b108028454a86ad5 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 5 12:21:44 2016 -0300 perf script perl: Do error checking on new backtrace routine This ended up triggering these warnings when building on Ubuntu 12.04.5: util/scripting-engines/trace-event-perl.c: In function 'perl_process_callchain': util/scripting-engines/trace-event-perl.c:293:4: error: value computed is not used [-Werror=unused-value] util/scripting-engines/trace-event-perl.c:294:4: error: value computed is not used [-Werror=unused-value] util/scripting-engines/trace-event-perl.c:295:4: error: value computed is not used [-Werror=unused-value] util/scripting-engines/trace-event-perl.c:297:4: error: value computed is not used [-Werror=unused-value] util/scripting-engines/trace-event-perl.c:309:4: error: value computed is not used [-Werror=unused-value] cc1: all warnings being treated as errors mv: cannot stat `/tmp/build/perf/util/scripting-engines/.trace-event-perl.o.tmp': No such file or directory make[4]: *** [/tmp/build/perf/util/scripting-engines/trace-event-perl.o] Error 1 Fix it by doing error checking when building the perl data structures related to callchains. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Dima Kogan <dima@secretsauce.net> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@gmail.com> Fixes: f7380c12ec6c ("perf script perl: Perl scripts now get a backtrace, like the python ones") Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> .../perf/util/scripting-engines/trace-event-perl.c | 30 +++++++++++++++------- 1 file changed, 21 insertions(+), 9 deletions(-) commit bd0419e2a5a9fd9396cb7dc69044f961f52e19f0 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue Apr 5 11:33:41 2016 -0300 perf probe: Check if dwarf_getlocations() is available If not, tell the user that: config/Makefile:273: Old libdw.h, finding variables at given 'perf probe' point will not work, install elfutils-devel/libdw-dev >= 0.157 And return -ENOTSUPP in die_get_var_range(), failing features that need it, like the one pointed out above. This fixes the build on older systems, such as Ubuntu 12.04.5. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Vinson Lee <vlee@freedesktop.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-9l7luqkq4gfnx7vrklkq4obs@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/build/Makefile.feature | 2 ++ tools/build/feature/Makefile | 4 ++++ tools/build/feature/test-all.c | 5 +++++ tools/build/feature/test-dwarf_getlocations.c | 12 ++++++++++++ tools/perf/config/Makefile | 6 ++++++ tools/perf/util/dwarf-aux.c | 9 +++++++++ 6 files changed, 38 insertions(+) commit d8e28654f28de74951ab1b7e59d2bebb442972aa Author: Vinson Lee <vlee@freedesktop.org> Date: Mon Apr 4 22:07:39 2016 +0000 perf config: Fix build with older toolchain. Fix build error on Ubuntu 12.04.5 with GCC 4.6.3. CC util/config.o util/config.c: In function ‘perf_buildid_config’: util/config.c:384:15: error: declaration of ‘dirname’ shadows a global declaration [-Werror=shadow] Signed-off-by: Vinson Lee <vlee@freedesktop.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@plumgrid.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Taeung Song <treeze.taeung@gmail.com> Cc: Wang Nan <wangnan0@huawei.com> Fixes: 9cb5987c8227 ("perf config: Rework buildid_dir_command_config to perf_buildid_config") Link: http://lkml.kernel.org/r/1459807659-9020-1-git-send-email-vlee@freedesktop.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/config.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 4ce2bd9c4c1dfb416206ff1ad5283f6d24af4031 Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Tue Mar 29 13:53:28 2016 +0300 cfg80211: Allow reassociation to be requested with internal SME If the user space issues a NL80211_CMD_CONNECT with NL80211_ATTR_PREV_BSSID when there is already a connection, allow this to proceed as a reassociation instead of rejecting the new connect command with EALREADY. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> [validate prev_bssid] Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/wireless/nl80211.c | 3 ++- net/wireless/sme.c | 14 ++++++++++++-- 2 files changed, 14 insertions(+), 3 deletions(-) commit bc5ccdbc990debbcae4602214dddc8d5fd38b01d Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Mar 16 05:04:04 2016 -0700 [media] au0828: Unregister notifiers If au0828 gets removed, we need to remove the notifiers. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/usb/au0828/au0828-core.c | 38 +++++++++++++++++++++++----------- 1 file changed, 26 insertions(+), 12 deletions(-) commit 88336e174645948da269e1812f138f727cd2896b Author: Max Kellermann <max@duempel.org> Date: Mon Mar 21 04:33:12 2016 -0700 [media] media-devnode: add missing mutex lock in error handler We should protect the device unregister patch too, at the error condition. Signed-off-by: Max Kellermann <max@duempel.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> drivers/media/media-devnode.c | 3 +++ 1 file changed, 3 insertions(+) commit 952f8eef901b170dbe6b48e80f098be5d835a82c Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Mar 16 05:34:39 2016 -0700 [media] media-device: make topology_version u64 The uAPI defines it with 64 bits. Let's change the Kernel implementation too. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/media/media-device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3047f3f98eabd655ca2db4e42219a2990052f73a Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Date: Wed Mar 16 05:04:03 2016 -0700 [media] media-device: Fix a comment The comment is for the wrong function. Fix it. Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> include/media/media-device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 95e2106f46702f720b80a22b3c79be25362e02be Author: Lee Jones <lee.jones@linaro.org> Date: Thu Jun 11 09:39:21 2015 +0100 ARM: multi_v7_defconfig: Enable support for PWM Regulators Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/configs/multi_v7_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 39b86a3e8bc4fc072da5d4df09a8b6d5834a213b Author: Lee Jones <lee.jones@linaro.org> Date: Tue Jul 22 14:20:25 2014 +0100 ARM: multi_v7_defconfig: Enable ST's Power Reset driver Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) commit daf7bb1dde0131f2a61cda51a117da63bf718ea4 Author: Lee Jones <lee.jones@linaro.org> Date: Wed Jun 18 14:32:04 2014 +0100 ARM: multi_v7_defconfig: Enable ST's PWM driver Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Maxime Coquelin <maxime.coquelin@st.com> arch/arm/configs/multi_v7_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d252bf68b75792108ae2821c3a6e1cdc58e88cb9 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Thu Mar 31 16:11:47 2016 +0530 drm/i915: Set invert bit for hpd based on VBT This patch sets the invert bit for hpd detection for each port based on VBT configuration. Since each AOB can be designed to depend on invert bit or not, it is expected if an AOB requires invert bit, the user will set respective bit in VBT. v2: Separated VBT parsing from the rest of the logic. (Jani) v3: Moved setting invert bit logic to bxt_hpd_irq_setup() and changed its logic to avoid looping twice. (Ville) v4: Changed the logic to mask out the bits first and then set them to remove need of temporary variable. (Ville) v5: Moved defines to existing set of defines for the register and added required breaks. (Ville) Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Durgadoss R <durgadoss.r@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> [Jani: fixed some checkpatch noise, added kernel-doc.] Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459420907-11383-2-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/i915_drv.h | 2 ++ drivers/gpu/drm/i915/i915_irq.c | 20 ++++++++++++++++++ drivers/gpu/drm/i915/i915_reg.h | 6 ++++++ drivers/gpu/drm/i915/intel_bios.c | 44 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 72 insertions(+) commit ba6fbacf9c073effaedf0c52fe7e52e2baf67725 Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Tue Mar 29 13:53:27 2016 +0300 cfg80211: Add option to specify previous BSSID for Connect command This extends NL80211_CMD_CONNECT to allow the NL80211_ATTR_PREV_BSSID attribute to be used similarly to way this was already allowed with NL80211_CMD_ASSOCIATE. This allows user space to request reassociation (instead of association) when already connected to an AP. This provides an option to reassociate within an ESS without having to disconnect and associate with the AP. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 2 ++ net/wireless/nl80211.c | 4 ++++ net/wireless/trace.h | 6 ++++-- 3 files changed, 10 insertions(+), 2 deletions(-) commit 918fe04b288b3784f4ca90d3dff12fc23dc2751f Author: Felix Fietkau <nbd@openwrt.org> Date: Thu Mar 3 22:59:01 2016 +0100 mac80211: minstrel_ht: set A-MSDU tx limits based on selected max_prob_rate Prevents excessive A-MSDU aggregation at low data rates or bad conditions. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rc80211_minstrel_ht.c | 54 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) commit 6e0456b5454561c4e9fa9e8a4acea405e6d56c80 Author: Felix Fietkau <nbd@openwrt.org> Date: Thu Mar 3 22:59:00 2016 +0100 mac80211: add A-MSDU tx support Requires software tx queueing and fast-xmit support. For good performance, drivers need frag_list support as well. This avoids the need for copying data of aggregated frames. Running without it is only supported for debugging purposes. To avoid performance and packet size issues, the rate control module or driver needs to limit the maximum A-MSDU size by setting max_rc_amsdu_len in struct ieee80211_sta. Signed-off-by: Felix Fietkau <nbd@openwrt.org> [fix locking issue] Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/linux/ieee80211.h | 3 + include/net/mac80211.h | 19 ++++++ net/mac80211/agg-tx.c | 5 ++ net/mac80211/debugfs.c | 2 + net/mac80211/ieee80211_i.h | 1 + net/mac80211/sta_info.c | 2 + net/mac80211/tx.c | 156 +++++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 188 insertions(+) commit c9c5962b56c10c34d8fedc20cd6d6ebdaa2383c6 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:11 2016 +0300 mac80211: enable collecting station statistics per-CPU If the driver advertises the new HW flag USE_RSS, make the station statistics on the fast-rx path per-CPU. This will enable calling the RX in parallel, only hitting locking or shared cachelines when the fast-RX path isn't available. Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 4 ++ net/mac80211/debugfs.c | 1 + net/mac80211/rx.c | 37 ++++++++++------- net/mac80211/sta_info.c | 108 +++++++++++++++++++++++++++++++++++++++++------- net/mac80211/sta_info.h | 38 ++++++++++------- 5 files changed, 142 insertions(+), 46 deletions(-) commit 49ddf8e6e2347cffdcf83d1ca2d04ff929820178 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:10 2016 +0300 mac80211: add fast-rx path The regular RX path has a lot of code, but with a few assumptions on the hardware it's possible to reduce the amount of code significantly. Currently the assumptions on the driver are the following: * hardware/driver reordering buffer (if supporting aggregation) * hardware/driver decryption & PN checking (if using encryption) * hardware/driver did de-duplication * hardware/driver did A-MSDU deaggregation * AP_LINK_PS is used (in AP mode) * no client powersave handling in mac80211 (in client mode) of which some are actually checked per packet: * de-duplication * PN checking * decryption and additionally packets must * not be A-MSDU (have been deaggregated by driver/device) * be data packets * not be fragmented * be unicast * have RFC 1042 header Additionally dynamically we assume: * no encryption or CCMP/GCMP, TKIP/WEP/other not allowed * station must be authorized * 4-addr format not enabled Some data needed for the RX path is cached in a new per-station "fast_rx" structure, so that we only need to look at this and the packet, no other memory when processing packets on the fast RX path. After doing the above per-packet checks, the data path collapses down to a pretty simple conversion function taking advantage of the data cached in the small fast_rx struct. This should speed up the RX processing, and will make it easier to reason about parallelizing RX (for which statistics will need to be per-CPU still.) Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/linux/ieee80211.h | 10 ++ net/mac80211/cfg.c | 10 +- net/mac80211/ieee80211_i.h | 5 + net/mac80211/key.c | 1 + net/mac80211/mlme.c | 9 ++ net/mac80211/rx.c | 351 +++++++++++++++++++++++++++++++++++++++++++++ net/mac80211/sta_info.c | 2 + net/mac80211/sta_info.h | 34 +++++ 8 files changed, 419 insertions(+), 3 deletions(-) commit 0f9c5a61d4b2330b12c59126aa5a9108dbfce555 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:09 2016 +0300 mac80211: fix RX u64 stats consistency on 32-bit platforms On 32-bit platforms, the 64-bit counters we keep need to be protected to be consistently read. Use the u64_stats_sync mechanism to do that. In order to not end up with overly long lines, refactor the tidstats assignments a bit. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 6 +++++ net/mac80211/sta_info.c | 72 ++++++++++++++++++++++++++++++------------------- net/mac80211/sta_info.h | 5 +++- 3 files changed, 54 insertions(+), 29 deletions(-) commit 4f6b1b3daaf167bf927174224e07efd17ed95984 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:08 2016 +0300 mac80211: fix last RX rate data consistency When storing the last_rate_* values in the RX code, there's nothing to guarantee consistency, so a concurrent reader could see, e.g. last_rate_idx on the new value, but last_rate_flag still on the old, getting completely bogus values in the end. To fix this, I lifted the sta_stats_encode_rate() function from my old rate statistics code, which encodes the entire rate data into a single 16-bit value, avoiding the consistency issue. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 21 +++++------------ net/mac80211/sta_info.c | 60 ++++++++++++++++++++++++++----------------------- net/mac80211/sta_info.h | 45 ++++++++++++++++++++++++++++++++----- 3 files changed, 77 insertions(+), 49 deletions(-) commit b8da6b6a99b4b0d8d464b621ba7dcbcb08172b7d Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:07 2016 +0300 mac80211: add separate last_ack variable Instead of touching the rx_stats.last_rx from the status path, introduce and use a status_stats.last_ack variable. This will make rx_stats.last_rx indicate when the last frame was received, making it available for real "last_rx" and statistics gathering; statistics, when done per-CPU, will need to figure out which place was updated last for those items where the "last" value is exposed. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/ibss.c | 13 ++++++++----- net/mac80211/sta_info.c | 13 +++++++++++-- net/mac80211/sta_info.h | 3 +++ net/mac80211/status.c | 4 ++-- 4 files changed, 24 insertions(+), 9 deletions(-) commit 2df8bfd7240117b91241a01e3f50f2e83827ccab Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:06 2016 +0300 mac80211: remove rx_stats.last_rx update after sta alloc There's no need to update rx_stats.last_rx after allocating a station since it's already updated during allocation. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/ibss.c | 4 ---- net/mac80211/ocb.c | 2 -- 2 files changed, 6 deletions(-) commit 0be6ed133835b1a5e492f86099ce372b5a2e2296 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:05 2016 +0300 mac80211: move averaged values out of rx_stats Move the averaged values out of rx_stats and into rx_stats_avg, to cleanly split them out. The averaged ones cannot be supported for parallel RX in a per-CPU fashion, while the other values can be collected per CPU and then combined/selected when needed. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh_plink.c | 2 +- net/mac80211/rx.c | 4 ++-- net/mac80211/sta_info.c | 10 +++++----- net/mac80211/sta_info.h | 6 ++++-- 4 files changed, 12 insertions(+), 10 deletions(-) commit 8ebaa5b0a791631dddbb3a215b342fabb2a5307b Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:04 2016 +0300 mac80211: move semicolon out of CALL_RXH macro Move the semicolon, people typically assume that and once line already put a semicolon behind the "call". Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) commit de8f18d3a80bee94ee8a2d3c511707390dad88d6 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:03 2016 +0300 mac80211: count MSDUs in A-MSDU properly For the RX MSDU statistics, we need to count the number of MSDUs created and accepted from an A-MSDU. Right now, all frames in any A-MSDUs were completely ignored. Fix this by moving the RX MSDU statistics accounting into the deliver function. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit d63b548fffdbd239a5e65bb89424be19229048ba Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 31 20:02:02 2016 +0300 mac80211: allow passing transmitter station on RX Sometimes drivers already looked up, or know out-of-band from their device, which station transmitted a given RX frame. Allow them to pass the station pointer to mac80211 to save the extra lookup. Signed-off-by: Johannes Berg <johannes.berg@intel.com> drivers/net/wireless/intel/iwlwifi/dvm/rx.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/rx.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 2 +- include/net/mac80211.h | 7 ++++--- net/mac80211/rx.c | 18 +++++++++++++----- 6 files changed, 21 insertions(+), 12 deletions(-) commit 4e27bd50739e41250a93dd131d6a4180e288cb10 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Thu Mar 31 16:11:46 2016 +0530 drm/i915: Update VBT fields for child devices This patch adds new fields that are not yet added in drm code in child devices struct Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Durgadoss R <durgadoss.r@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459420907-11383-1-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_bios.c | 15 ++++++++++++++- drivers/gpu/drm/i915/intel_vbt_defs.h | 18 ++++++++++++------ 2 files changed, 26 insertions(+), 7 deletions(-) commit 4e332df63487418ec512c3c376c07df9ab3ae035 Author: Roger Quadros <rogerq@ti.com> Date: Wed Mar 30 12:56:29 2016 +0300 usb: otg-fsm: support multiple instances Move the state_changed variable into struct otg_fsm so that we can support multiple instances. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Peter Chen <peter.chen@nxp.com> drivers/usb/common/usb-otg-fsm.c | 10 ++++------ include/linux/usb/otg-fsm.h | 1 + 2 files changed, 5 insertions(+), 6 deletions(-) commit fa59507f720077a856c9952a31cfd45cd97ef6f9 Author: Roger Quadros <rogerq@ti.com> Date: Wed Mar 30 12:56:28 2016 +0300 usb: otg-fsm: Add documentation for struct otg_fsm struct otg_fsm is the interface to the OTG state machine. Document the input, output and internal state variables. Definations are taken from Table 7-2 and Table 7-4 of the USB OTG & EH Specification Rev.2.0 Re-arrange some of the members as per use case for more clarity. Signed-off-by: Roger Quadros <rogerq@ti.com> Acked-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Peter Chen <peter.chen@nxp.com> include/linux/usb/otg-fsm.h | 90 +++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 83 insertions(+), 7 deletions(-) commit 2b2fe36def086f0b721be2f34223cf662dd87902 Author: Peter Chen <peter.chen@nxp.com> Date: Mon Mar 28 14:53:16 2016 +0800 usb: chipidea: imx: delete the redundant setting default DMA mask code For each platform devices which is created by device tree, the default DMA mask is set by of_dma_configure when the device are created. So delete the redundant code at driver. Signed-off-by: Peter Chen <peter.chen@nxp.com> drivers/usb/chipidea/ci_hdrc_imx.c | 4 ---- 1 file changed, 4 deletions(-) commit 4aba2755b8e8abbe29a12d18523d97c27bf53183 Author: Gary Bisson <gary.bisson@boundarydevices.com> Date: Sat Apr 2 18:25:45 2016 +0200 clk: imx: add ckil clock for i.MX7 Add the necessary clock to use the ckil on i.MX7. Inspired from the following patch: https://github.com/boundarydevices/linux-imx6/commit/b80e8271 Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-imx7d.c | 3 ++- include/dt-bindings/clock/imx7d-clock.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 6248620b30403bcbe3ef308499026226e999597c Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Mar 30 16:58:21 2016 +0200 clk: renesas: r8a7795: add RWDT clock Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 1 + 1 file changed, 1 insertion(+) commit 1e6237e32ef4bf4104a8ef14cece60541e11e14d Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Mar 30 16:58:20 2016 +0200 clk: renesas: r8a7795: add R clk R can select between two parents. We deal with it like this: During initialization, check if EXTALR is populated. If so, use it for R. If not, use R_Internal. clk_mux doesn't help here because we don't want to switch parents depending on the clock rate. The clock rate (and source) should stay constant for the watchdog, so I think a setup like this during initialization makes sense. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 5524a67f3a4ad8625cab6a9b99419f747cea4c71 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Mar 30 16:58:19 2016 +0200 clk: renesas: r8a7795: add OSC and RINT clocks Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 5 +++++ 1 file changed, 5 insertions(+) commit 5d3927f655e58e644557a3dc8ee7af8884f59931 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Mar 30 16:58:18 2016 +0200 clk: renesas: cpg-mssr: add generic support for read-only DIV6 clocks Gen3 has two clocks (OSC and R) which look like a DIV6 clock but their divider value is read-only and depends on MD pins at bootup. Add support for such clocks by reading the value and adding a fixed clock. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/renesas-cpg-mssr.c | 18 ++++++++++++------ drivers/clk/renesas/renesas-cpg-mssr.h | 3 +++ 2 files changed, 15 insertions(+), 6 deletions(-) commit dad38ca64a252144b4ccdfe9730a3fe2b7c61957 Merge: d1b26c7 d37ba88 Author: Ingo Molnar <mingo@kernel.org> Date: Wed Apr 6 08:46:23 2016 +0200 Merge tag 'perf-core-for-mingo-20160401' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Do not use events that don't have timestamps when setting 'perf trace's base timestamp, fixing up the timestamp column for syscalls (Arnaldo Carvalho de Melo) - Make the 'bpf-output' sample_type be the same as tracepoint's, fixing up 'perf trace's timestamp column for bpf events (Wang Nan) - Fix PMU term format max value calculation (Kan Liang) - Pretty print 'seccomp', 'getrandom' syscalls in 'perf trace' (Arnaldo Carvalho de Melo) Infrastructure changes: - Add support for using TSC as an ARCH timestamp when synthesizing JIT records (Adrian Hunter) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit 4926c8046549cc3c9689e8050e303c016a0b0cba Author: Takashi Iwai <tiwai@suse.de> Date: Mon Apr 4 11:33:54 2016 +0200 ALSA: intel8x0: Drop superfluous VM checks intel8x0 driver has the inside_vm check for skipping a buggy hardware workaround in the PCM pointer callback in the commit [228cf79376f1: ALSA: intel8x0: Improve performance in virtual environment]. This was originally applied to all devices on known VMs, but the code was switched to use the PCI ID matching for applying to only known devices (KVM and Parallels), in order to avoid applying wrongly to VT-d and other such cases, in the commit [7fb4f392bd27: ALSA: intel8x0: improve virtual environment detection]. Meanwhile, the original VM check was kept even after switching to the PCI ID matching. It was partly because we weren't 100% sure whether we had covered all well, and partly because this would help identifying the issue once when a user of another VM hit the same problem or a regression. Currently the VM check is used only for showing the kernel message that the VM-optimization isn't applied, and the VM check itself doesn't change the actual driver behavior at all. Despite the relatively safe driver behavior, the code caught attention of developers badly and brought many confusion / misunderstanding. Since we've got neither regression nor enhancement report for other VMs for five years long, it's likely safe to drop this superfluous VM check now. The module option is still kept, so if a user still needs to adjust, it can be applied as was. Acked-by: Konstantin Ozerkov <kozerkov@parallels.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/intel8x0.c | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) commit 24d41e5e2c9afe99b0584832206ba8779dfb783e Author: Alexander Duyck <aduyck@mirantis.com> Date: Fri Mar 18 16:06:47 2016 -0700 i40e/i40evf: Fix TSO checksum pseudo-header adjustment With IPv4 and IPv6 now using the same format for checksums based on the length of the frame we need to update the i40e and i40evf drivers so that they correctly account for lengths greater than or equal to 64K. With this patch the driver should now correctly update checksums for frames up to 16776960 in length which should be more than large enough for all possible TSO frames in the near future. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 11 ++++------- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 11 ++++------- 2 files changed, 8 insertions(+), 14 deletions(-) commit 066439ce791b5d8533556a89836c0849589c2b41 Author: Avinash Dayanand <avinash.dayanand@intel.com> Date: Fri Mar 18 12:18:16 2016 -0700 i40e/i40evf: Bump patch from 1.5.1 to 1.5.2 Signed-off-by: Avinash Dayanand <avinash.dayanand@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 867a79e37ed9a3a5a2051cc11df21a57a8a00bfe Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Mar 18 12:18:15 2016 -0700 i40e: Request PHY media event at reset time Add the Media Not Available flag to the link event mask. It seems that event comes first if you have a DA cable pulled out, but there's no follow-up event for Link Down; if you're not looking for MEDIA_NA you will get no event, even though there's now no Link. Change-ID: cb3340a2849805bb881f64f6f2ae810eef46eba7 Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 ++ 1 file changed, 2 insertions(+) commit 18b7af57d9c1165c2b8f13ec4668d6d7f51708cf Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Mar 18 12:18:14 2016 -0700 i40e: Lower some message levels These conditions can happen any time VFs are enabled or disabled and are not really indicative of fatal problems unless they happen continuously. Lower the log level so that people don't get scared. Change-ID: I1ceb4adbd10d03cbeed54d1f5b7f20d60328351d Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 16badc34695ff489a39e450b4e4e5a241ac85a31 Author: Avinash Dayanand <avinash.dayanand@intel.com> Date: Fri Mar 18 12:18:13 2016 -0700 i40e: Fix for supported link modes in 10GBaseT PHY's 100baseT/Full is now listed and supported link mode for 10GBaseT PHY. This is a fix to list all the supported link modes of 10GBaseT PHY. Change-ID: If2be3212ef0fef85fd5d6e4550c7783de2f915e9 Signed-off-by: Avinash Dayanand <avinash.dayanand@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 539a379c50220d6ac19c7300671fe25819bd3f1b Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Fri Mar 18 12:18:12 2016 -0700 i40evf: Fix get_rss_aq We were passing in the seed where we should just be passing false because we want the VSI table not the pf table. Change-ID: I9b633ab06eb59468087f0c0af8539857e99f9495 Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8c806b676d21a49628250731f4e30a8a071d080c Author: Shannon Nelson <shannon.nelson@intel.com> Date: Fri Mar 18 12:18:11 2016 -0700 i40e: Disable link polling Periodic link polling was added when the link events were found not to be trustworthy. This was the case early on, but was likely because the link event mask was being used incorrectly. As this has been fixed in recent code, we can disable the link polling to lessen the AQ traffic. Change-ID: Id890b5ee3c2d04381fc76ffa434777644f5d8eb0 Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 1 - 1 file changed, 1 deletion(-) commit 22ead37f8af83b4fa32c15cc21d3541e74661339 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Mar 18 12:18:10 2016 -0700 i40evf: Add longer wait after remove module Upon module remove, wait a little longer after requesting a reset before checking to see if the firmware responded. This change prevents double resets when the firmware is busy. Change-ID: Ieedc988ee82fac1f32a074bf4d9e4dba426bfa58 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7369ca8745499d001663e1dccf15064a3eb34b4d Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Mar 18 12:18:09 2016 -0700 i40e: Make VF resets more reliable Clear the VFLR bit immediately after triggering a reset instead of waiting until after cleanup is complete. Make sure to trigger a reset every time, not just if the PF is up. These changes fix a problem where VF resets would get lost by the PF, preventing the VF driver from initializing. Change-ID: I5945cf2884095b7b0554867c64df8617e71d9d29 Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit d6bf58c2e88f9e0cfc029c158e1182eb1f07d7eb Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Fri Mar 18 12:18:08 2016 -0700 i40e: Add new device ID for X722 The new device ID is 0x37D3 and it should follow the same flows and branding string as for 0x37D0. Change-ID: Ia5ad4a1910268c4666a3fd46a7afffbec55b4fc2 Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 1 + drivers/net/ethernet/intel/i40e/i40e_devids.h | 1 + drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + drivers/net/ethernet/intel/i40evf/i40e_common.c | 1 + drivers/net/ethernet/intel/i40evf/i40e_devids.h | 1 + 5 files changed, 5 insertions(+) commit c4445aedfe092907c2e792ff76ed4338d9a1cd52 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Mar 18 12:18:07 2016 -0700 i40evf: Fix VLAN features Users of ethtool were being given the mistaken impression that this driver was able to change its VLAN tagging features, and were disappointed that this was not actually the case. Implement ndo_fix_features method so that we can adjust these flags as needed to avoid false impressions. Change-ID: I08584f103a4fa73d6a4128d472e4ef44dcfda57f Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 442b25e455f5e693c23f9d3a32b208ca9ab25cf0 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Fri Mar 18 12:18:06 2016 -0700 i40e: Remove unused variable This variable is vestigial, a remnant of the primordial code from which this driver spawned. We can safely remove it. Change-ID: I24e0fe338e7c7c50d27dc5515564f33caefbb93a Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit 3845ccea34df30680b5be7ec119f5c74ab57fdc0 Author: Anjali Singhai Jain <anjali.singhai@intel.com> Date: Fri Mar 18 12:18:05 2016 -0700 i40e: Enable Geneve offload for FW API ver > 1.4 for XL710/X710 devices This patch enables the Capability for XL710/X710 devices with FW API version higher than 1.4 to do geneve Rx offload. Change-ID: I9a8f87772c48d7d67dc85e3701d2e0b845034c0b Signed-off-by: Anjali Singhai Jain <anjali.singhai@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 6 ++++++ 1 file changed, 6 insertions(+) commit afb8ece4326f2151771f4c40b8d9f799cee5ae6e Author: Colin King <colin.king@canonical.com> Date: Sat Feb 13 23:57:16 2016 +0000 i40e: remove redundant check on vsi->active_vlans active_vlans is an unsigned long array, hence a null check on this array is superfluous and can be removed. Detected with static analysis by smatch: drivers/net/ethernet/intel/i40e/i40e_debugfs.c:386 i40e_dbg_dump_vsi_seid() warn: this array is probably non-NULL. 'vsi->active_vlans' Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 4da46cebbd3b4dc445195a9672c99c1353af5695 Author: Aaron Conole <aconole@bytheb.org> Date: Sat Apr 2 15:26:43 2016 -0400 net/core/dev: Warn on a too-short GRO frame When signaling that a GRO frame is ready to be processed, the network stack correctly checks length and aborts processing when a frame is less than 14 bytes. However, such a condition is really indicative of a broken driver, and should be loudly signaled, rather than silently dropped as the case is today. Convert the condition to use net_warn_ratelimited() to ensure the stack loudly complains about such broken drivers. Signed-off-by: Aaron Conole <aconole@bytheb.org> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/dev.c | 2 ++ 1 file changed, 2 insertions(+) commit d00b39c17573ece6f5fb1385314877d29f540db8 Merge: 85bd5ac 7b4b7a8 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 6 09:57:33 2016 +1000 Merge branch 'drm-next-analogix-dp-v2' of github.com:yakir-Yang/linux into drm-next This pull request want to land the analogix_dp driver into drm/bridge directory, which reused the Exynos DP code, and add Rockchip DP support. And those patches have been: * 'drm-next-analogix-dp-v2' of github.com:yakir-Yang/linux: drm: bridge: analogix/dp: Fix the possible dead lock in bridge disable time drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time drm: bridge: analogix/dp: add edid modes parse in get_modes method drm: bridge: analogix/dp: move hpd detect to connector detect function drm: bridge: analogix/dp: try force hpd after plug in lookup failed drm: bridge: analogix/dp: add max link rate and lane count limit for RK3288 drm: bridge: analogix/dp: add some rk3288 special registers setting dt-bindings: add document for rockchip variant of analogix_dp drm: rockchip: dp: add rockchip platform dp driver ARM: dts: exynos/dp: remove some properties that deprecated by analogix_dp driver dt-bindings: add document for analogix display port driver drm: bridge: analogix/dp: dynamic parse sync_pol & interlace & dynamic_range drm: bridge: analogix/dp: remove duplicate configuration of link rate and link count drm: bridge: analogix/dp: fix some obvious code style drm: bridge: analogix/dp: rename register constants drm/exynos: dp: rename implementation specific driver part drm: bridge: analogix/dp: split exynos dp driver to bridge directory commit f9cd476123ced488e628339becedb2cf3243a58a Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Apr 4 22:44:59 2016 +0200 dmaengine: pl08x: allocate OF slave channel data at probe time The current OF translation of channels can never work with any DMA client using the DMA channels directly: the only way to get the channels initialized properly is in the dma_async_device_register() call, where chan->dev etc is allocated and initialized. Allocate and initialize all possible DMA channels and only augment a target channel with the periph_buses at of_xlate(). Remove some const settings to make things work. Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Tested-by: Joachim Eastwood <manabian@gmail.com> Tested-by: Johannes Stezenbach <js@sig21.net> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/amba-pl08x.c | 86 +++++++++++++++++++++++++++++++--------------- include/linux/amba/pl08x.h | 2 +- 2 files changed, 59 insertions(+), 29 deletions(-) commit 9be02cdfa601776f9e65013d9f1b949d5024f457 Author: Thomas Falcon <tlfalcon@linux.vnet.ibm.com> Date: Fri Apr 1 17:20:35 2016 -0500 ibmvnic: enable RX checksum offload Enable RX Checksum offload feature in the ibmvnic driver. Signed-off-by: Thomas Falcon <tlfalcon@linux.vnet.ibm.com> Cc: John Allen <jallen@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ibm/ibmvnic.c | 4 ++++ 1 file changed, 4 insertions(+) commit ad7775dc7b8b0b5585ff114b04d5ad50737c423e Author: Thomas Falcon <tlfalcon@linux.vnet.ibm.com> Date: Fri Apr 1 17:20:34 2016 -0500 ibmvnic: map L2/L3/L4 header descriptors to firmware Allow the VNIC driver to provide descriptors containing L2/L3/L4 headers to firmware. This feature is needed for greater hardware compatibility and enablement of checksum and TCP offloading features. A new function is included for the hypervisor call, H_SEND_SUBCRQ_INDIRECT, allowing a DMA-mapped array of SCRQ descriptor elements to be sent to the VNIC server. These additions will help fully enable checksum offloading as well as other features as they are included later. Signed-off-by: Thomas Falcon <tlfalcon@linux.vnet.ibm.com> Cc: John Allen <jallen@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/ibm/ibmvnic.c | 195 ++++++++++++++++++++++++++++++++++++- drivers/net/ethernet/ibm/ibmvnic.h | 3 + 2 files changed, 194 insertions(+), 4 deletions(-) commit 6e3e6d55e51774ec7cfc24975749bbddb28a9051 Author: Eryu Guan <guaneryu@gmail.com> Date: Wed Apr 6 09:47:21 2016 +1000 xfs: mute some sparse warnings These three warnings are fixed: fs/xfs/xfs_inode.c:1033:44: warning: Using plain integer as NULL pointer fs/xfs/xfs_inode_item.c:525:20: warning: context imbalance in 'xfs_inode_item_push' - unexpected unlock fs/xfs/xfs_dquot.c:696:1: warning: symbol 'xfs_dq_get_next_id' was not declared. Should it be static? Signed-off-by: Eryu Guan <guaneryu@gmail.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_dquot.c | 2 +- fs/xfs/xfs_inode.c | 2 +- fs/xfs/xfs_inode_item.c | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) commit 664b60f6babc98ee03c2ff15b9482cc8c5e15a83 Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 09:47:01 2016 +1000 xfs: improve kmem_realloc Use krealloc to implement our realloc function. This helps to avoid new allocations if we are still in the slab bucket. At least for the bmap btree root that's actually the common case. This also allows removing the now unused oldsize argument. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/kmem.c | 26 +++++++++++++++----------- fs/xfs/kmem.h | 2 +- fs/xfs/libxfs/xfs_inode_fork.c | 10 +++------- fs/xfs/xfs_log_recover.c | 2 +- fs/xfs/xfs_mount.c | 1 - 5 files changed, 20 insertions(+), 21 deletions(-) commit 9f27889f3a96ff356ac92688cc0c4be3935ae3af Author: Carlos Maiolino <cmaiolino@redhat.com> Date: Wed Apr 6 09:46:30 2016 +1000 xfs: Add caller function output to xfs_log_force tracepoint I had sent this patch yesterday, but for some reason it didn't reach xfs list, sending again. Output the caller of xfs_log_force might be useful when tracing log checkpoint problems without the need to build kernel with DEBUG. Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_log.c | 4 ++-- fs/xfs/xfs_trace.h | 10 ++++++---- 2 files changed, 8 insertions(+), 6 deletions(-) commit 85bd5ac371c844f66918dda8c83145a26a55f9f2 Merge: e7c8e54 68d4aee Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 6 09:40:07 2016 +1000 Merge tag 'drm-intel-next-2016-03-30' of git://anongit.freedesktop.org/drm-intel into drm-next - VBT code refactor for a clean split between parsing&using of firmware information (Jani) - untangle the pll computation code, and splitting up the monster i9xx_crtc_compute_clocks (Ander) - dsi support for bxt (Jani, Shashank Sharma and others) - color manager (i.e. de-gamma, color conversion matrix & gamma support) from Lionel Landwerlin - Vulkan hsw support in the command parser (Jordan Justen) - large-scale renaming of intel_engine_cs variables/parameters to avoid the epic ring vs. engine confusion introduced in gen8 (Tvrtko Ursulin) - few atomic patches from Maarten&Matt, big one is two-stage wm programming on ilk-bdw - refactor driver load and add infrastructure to inject load failures for testing, from Imre - various small things all over * tag 'drm-intel-next-2016-03-30' of git://anongit.freedesktop.org/drm-intel: (179 commits) drm/i915: Update DRIVER_DATE to 20160330 drm/i915: Call intel_dp_mst_resume() before resuming displays drm/i915: Fix races on fbdev drm/i915: remove unused dev_priv->render_reclock_avail drm/i915: move sdvo mappings to vbt data drm/i915: move edp low vswing config to vbt data drm/i915: use a substruct in vbt data for edp drm/i915: replace for_each_engine() drm/i915: introduce for_each_engine_id() drm/i915/bxt: Fix DSI HW state readout drm/i915: Remove vblank wait from hsw_enable_ips, v2. drm/i915: Tidy aliasing_gtt_bind_vma() drm/i915: Split PNV version of crtc_compute_clock() drm/i915: Split g4x_crtc_compute_clock() drm/i915: Split i8xx_crtc_compute_clock() drm/i915: Split CHV and VLV specific crtc_compute_clock() hooks drm/i915: Merge ironlake_compute_clocks() and ironlake_crtc_compute_clock() drm/i915: Move fp divisor calculation into ironlake_compute_dpll() drm/i915: Pass crtc_state->dpll directly to ->find_dpll() drm/i915: Simplify ironlake_crtc_compute_clock() CPU eDP case ... commit e7c8e54440bcae3f883ca8801f6558fe29bf0198 Merge: 9735a22 249c4f5 Author: Dave Airlie <airlied@redhat.com> Date: Wed Apr 6 09:39:01 2016 +1000 Merge tag 'topic/drm-misc-2016-04-01' of git://anongit.freedesktop.org/drm-intel into drm-next * tag 'topic/drm-misc-2016-04-01' of git://anongit.freedesktop.org/drm-intel: drm: Add new DCS commands in the enum list drm: Make uapi headers C89 pendantic compliant drm/atomic: export drm_atomic_helper_wait_for_fences() drm: Untangle __KERNEL__ guards drm: Move DRM_MODE_OBJECT_* to uapi headers drm: align #include directives with libdrm in uapi headers drm: Make drm.h uapi header safe for C++ vgacon: dummy implementation for vgacon_text_force drm/sysfs: Nuke TV/DVI property files drm/ttm: Remove TTM_HAS_AGP drm: bridge/dw-hdmi: Remove pre_enable/post_disable dummy funcs Revert "drm: Don't pass negative delta to ktime_sub_ns()" drm/atmel: Fixup drm_connector_/unplug/unregister/_all drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all() drm: bridge: Make (pre/post) enable/disable callbacks optional commit 590ddaa49519e083cab5e030fd845015628757ac Merge: 66f8779 7ee4062 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 19:33:52 2016 -0400 Merge branch 'bcmgenet-cleanups' Petri Gynther says: ==================== bcmgenet cleanups Three cleanup patches for bcmgenet. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 7ee4062562bae8f248f0aa72dfb3023ddea65942 Author: Petri Gynther <pgynther@google.com> Date: Tue Apr 5 14:00:01 2016 -0700 net: bcmgenet: cleanup for dmadesc_set() dmadesc_set() is used for setting the Tx buffer DMA address, length, and status bits on a Tx ring descriptor when a frame is being Tx'ed. Always set the Tx buffer DMA address first, before updating the length and status bits, i.e. giving the Tx descriptor to the hardware. The reason this is a cleanup rather than a fix is that the hardware won't transmit anything from a Tx ring until the TDMA producer index has been incremented. As long as the dmadesc_set() writes complete before the TDMA producer index write, life is good. Signed-off-by: Petri Gynther <pgynther@google.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 824ba603573d910e32df75fe6a5e7d7ec2a0a6a7 Author: Petri Gynther <pgynther@google.com> Date: Tue Apr 5 14:00:00 2016 -0700 net: bcmgenet: cleanup for bcmgenet_xmit_frag() Add frag_size = skb_frag_size(frag) and use it when needed. Signed-off-by: Petri Gynther <pgynther@google.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit f5a9ec20b3b2adf03a0b01902cda913b05abd382 Author: Petri Gynther <pgynther@google.com> Date: Tue Apr 5 13:59:59 2016 -0700 net: bcmgenet: cleanup for bcmgenet_xmit() 1. Readability: Move nr_frags assignment a few lines down in order to bundle index -> ring -> txq calculations together. 2. Readability: Add parentheses around nr_frags + 1. 3. Minor fix: Stop the Tx queue and throw the error message only if the Tx queue hasn't already been stopped. Signed-off-by: Petri Gynther <pgynther@google.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/genet/bcmgenet.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) commit 710b1e2c2948c1e5d0499def5273ecbc6472342d Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 09:20:36 2016 +1000 xfs: remove transaction types These aren't used for CIL-style logging and can be dropped. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/libxfs/xfs_log_format.h | 5 +++ fs/xfs/libxfs/xfs_shared.h | 97 ------------------------------------------ fs/xfs/xfs_log.c | 58 +------------------------ fs/xfs/xfs_log.h | 3 +- fs/xfs/xfs_log_cil.c | 1 - fs/xfs/xfs_log_priv.h | 1 - fs/xfs/xfs_trace.h | 5 +-- fs/xfs/xfs_trans.c | 2 +- 8 files changed, 10 insertions(+), 162 deletions(-) commit 253f4911f297b83745938b7f2c5649b94730b002 Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 09:19:55 2016 +1000 xfs: better xfs_trans_alloc interface Merge xfs_trans_reserve and xfs_trans_alloc into a single function call that returns a transaction with all the required log and block reservations, and which allows passing transaction flags directly to avoid the cumbersome _xfs_trans_alloc interface. While we're at it we also get rid of the transaction type argument that has been superflous since we stopped supporting the non-CIL logging mode. The guts of it will be removed in another patch. [dchinner: fixed transaction leak in error path in xfs_setattr_nonsize] Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/libxfs/xfs_attr.c | 58 +++++++----------------------- fs/xfs/libxfs/xfs_bmap.c | 22 +++++------- fs/xfs/libxfs/xfs_sb.c | 8 ++--- fs/xfs/libxfs/xfs_shared.h | 5 +-- fs/xfs/xfs_aops.c | 19 ++++------ fs/xfs/xfs_attr_inactive.c | 16 ++------- fs/xfs/xfs_bmap_util.c | 45 +++++++----------------- fs/xfs/xfs_dquot.c | 7 ++-- fs/xfs/xfs_file.c | 8 ++--- fs/xfs/xfs_fsops.c | 10 ++---- fs/xfs/xfs_inode.c | 60 ++++++++++++------------------- fs/xfs/xfs_ioctl.c | 13 +++---- fs/xfs/xfs_iomap.c | 53 +++++++++------------------- fs/xfs/xfs_iops.c | 29 ++++++--------- fs/xfs/xfs_log_recover.c | 10 +++--- fs/xfs/xfs_pnfs.c | 7 ++-- fs/xfs/xfs_qm.c | 9 ++--- fs/xfs/xfs_qm_syscalls.c | 26 ++++---------- fs/xfs/xfs_rtalloc.c | 21 +++++------ fs/xfs/xfs_symlink.c | 16 ++++----- fs/xfs/xfs_trans.c | 88 +++++++++++++++++++++------------------------- fs/xfs/xfs_trans.h | 8 ++--- 22 files changed, 191 insertions(+), 347 deletions(-) commit 0e51a8e191dbd9b9c7b7bb0a1c28d57cd2be8e6a Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 08:34:30 2016 +1000 xfs: optimize bio handling in the buffer writeback path This patch implements two closely related changes: First it embeds a bio the ioend structure so that we don't have to allocate one separately. Second it uses the block layer bio chaining mechanism to chain additional bios off this first one if needed instead of manually accounting for multiple bio completions in the ioend structure. Together this removes a memory allocation per ioend and greatly simplifies the ioend setup and I/O completion path. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_aops.c | 247 ++++++++++++++++++++++++----------------------------- fs/xfs/xfs_aops.h | 15 ++-- fs/xfs/xfs_super.c | 26 ++---- 3 files changed, 123 insertions(+), 165 deletions(-) commit b2d8984f3e7c84303e4d1cbd40d9e8cefd3c9737 Author: Vinod Koul <vinod.koul@intel.com> Date: Tue Apr 5 15:31:33 2016 -0700 dmaengine: add DMA_CYCLIC to dma_get_slave_caps dma_get_slave_caps() API only checked for slave capability where we use slave capabilities for cyclic dma operations as well, so we should add the cyclic case here too. Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dmaengine.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 37992c18bba3f578860c6448b7bae18a14e535d3 Author: Dave Chinner <dchinner@redhat.com> Date: Wed Apr 6 08:12:28 2016 +1000 xfs: don't release bios on completion immediately Completion of an ioend requires us to walk the bufferhead list to end writback on all the bufferheads. This, in turn, is needed so that we can end writeback on all the pages we just did IO on. To remove our dependency on bufferheads in writeback, we need to turn this around the other way - we need to walk the pages we've just completed IO on, and then walk the buffers attached to the pages and complete their IO. In doing this, we remove the requirement for the ioend to track bufferheads directly. To enable IO completion to walk all the pages we've submitted IO on, we need to keep the bios that we used for IO around until the ioend has been completed. We can do this simply by chaining the bios to the ioend at completion time, and then walking their pages directly just before destroying the ioend. Signed-off-by: Dave Chinner <dchinner@redhat.com> [hch: changed the xfs_finish_page_writeback calling convention] Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_aops.c | 95 +++++++++++++++++++++++++++++++++++++++---------------- fs/xfs/xfs_aops.h | 5 +-- 2 files changed, 71 insertions(+), 29 deletions(-) commit bb18782aa47d8cde90fed5cb0af312642e98a4fa Author: Dave Chinner <dchinner@redhat.com> Date: Wed Apr 6 08:11:25 2016 +1000 xfs: build bios directly in xfs_add_to_ioend Currently adding a buffer to the ioend and then building a bio from the buffer list are two separate operations. We don't build the bios and submit them until the ioend is submitted, and this places a fixed dependency on bufferhead chaining in the ioend. The first step to removing the bufferhead chaining in the ioend is on the IO submission side. We can build the bio directly as we add the buffers to the ioend chain, thereby removing the need for a latter "buffer-to-bio" submission loop. This allows us to submit bios on large ioends as soon as we cannot add more data to the bio. These bios then get captured by the active plug, and hence will be dispatched as soon as either the plug overflows or we schedule away from the writeback context. This will reduce submission latency for large IOs, but will also allow more timely request queue based writeback blocking when the device becomes congested. Signed-off-by: Dave Chinner <dchinner@redhat.com> [hch: various small updates] Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_aops.c | 69 +++++++++++++++++++++++++------------------------------ fs/xfs/xfs_aops.h | 1 + 2 files changed, 32 insertions(+), 38 deletions(-) commit 7e57fd1444bf8f4ba9179f826ed6817c56b801d4 Author: Jisheng Zhang <jszhang@marvell.com> Date: Wed Mar 16 19:40:33 2016 +0800 PCI: designware: Move Root Complex setup code to dw_pcie_setup_rc() dw_pcie_host_init() looks up host bridge resources, ioremaps them, creates IRQ domains, and enumerates devices below the bridge. dw_pcie_setup_rc() programs the Root Complex registers. The Root Complex may lose power during suspend-to-RAM, and when we resume, we want to redo the latter but not the former. Move some Root Complex programming from dw_pcie_host_init() to dw_pcie_setup_rc() where it belongs. DesignWare-based drivers can call dw_pcie_setup_rc() in their resume paths. [Niklas Cassel <niklas.cassel@axis.com>: This change moves outbound ATU programming, which uses pp->mem_base, to dw_pcie_setup_rc(). Apply the dra7xx pp->mem_base update before calling dw_pcie_setup_rc().] [bhelgaas: changelog, fold in dra7xx fix from Niklas] Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Pratyush Anand <pratyush.anand@gmail.com> drivers/pci/host/pci-dra7xx.c | 4 ++-- drivers/pci/host/pcie-designware.c | 39 +++++++++++++++++++------------------- 2 files changed, 21 insertions(+), 22 deletions(-) commit 3ab3ffcaca99e0b77480d77bd393fc227b09069f Author: Eric Sandeen <sandeen@sandeen.net> Date: Wed Apr 6 07:57:47 2016 +1000 xfs: collapse cases in xfs_attr3_leaf_list_int Consolidate the 2 calls to ->put_listent in xfs_attr3_leaf_list_int(), by setting up name, namelen, and valuelen for the local vs remote cases, then call ->put_listent and do the error handling all in one spot. Signed-off-by: Eric Sandeen <sandeen@redhat.com> fs/xfs/xfs_attr_list.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) commit 7af5ad28a603f2d1ef4c579b8ab0a9d4767a348e Author: Eric Sandeen <sandeen@sandeen.net> Date: Wed Apr 6 07:57:45 2016 +1000 xfs: remove put_value from attr ->put_listent context The put_value context member is never set; remove it and the conditional test in xfs_attr3_leaf_list_int(). Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_attr.h | 1 - fs/xfs/xfs_attr_list.c | 31 +++---------------------------- 2 files changed, 3 insertions(+), 29 deletions(-) commit e5bd12bfea60af455f4cbad494e4ac1082e3abd6 Author: Eric Sandeen <sandeen@sandeen.net> Date: Wed Apr 6 07:57:32 2016 +1000 xfs: don't pass value into attr ->put_listent The value is not used; only names and value lengths are returned. Remove the argument. Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_attr.h | 2 +- fs/xfs/xfs_attr_list.c | 18 ++++++------------ fs/xfs/xfs_xattr.c | 3 +-- 3 files changed, 8 insertions(+), 15 deletions(-) commit 2a6fba6d2311151598abaa1e7c9abd5f8d024a43 Author: Eric Sandeen <sandeen@sandeen.net> Date: Wed Apr 6 07:57:18 2016 +1000 xfs: only return -errno or success from attr ->put_listent Today, the put_listent formatters return either 1 or 0; if they return 1, some callers treat this as an error and return it up the stack, despite "1" not being a valid (negative) error code. The intent seems to be that if the input buffer is full, we set seen_enough or set count = -1, and return 1; but some callers check the return before checking the seen_enough or count fields of the context. Fix this by only returning non-zero for actual errors encountered, and rely on the caller to first check the return value, then check the values in the context to decide what to do. Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_attr.h | 1 + fs/xfs/xfs_attr_list.c | 8 +++----- fs/xfs/xfs_xattr.c | 14 ++++++++++---- 3 files changed, 14 insertions(+), 9 deletions(-) commit 30ee052e12b97c190b27fe6f20e3ac3047df7b5c Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 07:53:29 2016 +1000 xfs: optimize inline symlinks By overallocating the in-core inode fork data buffer and zero terminating the link target in xfs_init_local_fork we can avoid the memory allocation in ->follow_link. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/libxfs/xfs_inode_fork.c | 22 ++++++++++++++++++---- fs/xfs/xfs_inode_item.c | 4 ++-- fs/xfs/xfs_iops.c | 29 ++++++++++++++++++++++++++--- fs/xfs/xfs_symlink.c | 9 +++------ 4 files changed, 49 insertions(+), 15 deletions(-) commit bfe8804d908a791b16e3686c101f0d7eca9fb5b9 Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 07:50:54 2016 +1000 xfs: use ->readlink to implement the readlink_by_handle ioctl Also drop the now unused readlink_copy export. [dchinner: use d_inode(dentry) rather than dentry->d_inode] Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/namei.c | 1 - fs/xfs/xfs_ioctl.c | 18 ++---------------- 2 files changed, 2 insertions(+), 17 deletions(-) commit 2b3d1d41b4d96c3b074096ae57b27cd191969643 Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 07:48:27 2016 +1000 xfs: set up inode operation vectors later In the next patch we'll set up different inode operations for inline vs out of line symlinks, for that we need to make sure the flags are already set up properly. [dchinner: added xfs_setup_iops() call to xfs_rename_alloc_whiteout()] Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_inode.c | 1 + fs/xfs/xfs_inode.h | 5 ++++- fs/xfs/xfs_iops.c | 59 ++++++++++++++++++++++++++++++++++-------------------- 3 files changed, 42 insertions(+), 23 deletions(-) commit 143f4aede7fb25b9198b15660d6f9830936394a8 Author: Christoph Hellwig <hch@lst.de> Date: Wed Apr 6 07:41:43 2016 +1000 xfs: factor out a helper to initialize a local format inode fork Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/libxfs/xfs_dir2_sf.c | 9 +++----- fs/xfs/libxfs/xfs_inode_fork.c | 48 ++++++++++++++++++++++++++---------------- fs/xfs/libxfs/xfs_inode_fork.h | 1 + fs/xfs/xfs_symlink.c | 12 ++--------- 4 files changed, 36 insertions(+), 34 deletions(-) commit ce5c767db079649db88a9f189798839f9c544981 Author: Eryu Guan <guaneryu@gmail.com> Date: Wed Apr 6 07:19:40 2016 +1000 xfs: add missing break in xfs_parseargs() Commit 2e74af0e1189 ("xfs: convert mount option parsing to tokens") missed a 'break;' in xfs_parseargs() which causes mount to fail with "-o pqnoenforce" option when mounting a v4 filesystem. xfs/050 catches this failure: XFS (vda6): Super block does not support project and group quota together Fixes: 2e74af0e1189 ("xfs: convert mount option parsing to tokens") Signed-off-by: Eryu Guan <guaneryu@gmail.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_super.c | 1 + 1 file changed, 1 insertion(+) commit ad747e3b299671e1a53db74963cc6c5f6cdb9f6d Author: Dave Chinner <dchinner@redhat.com> Date: Wed Apr 6 07:06:20 2016 +1000 xfs: Don't wrap growfs AGFL indexes Commit 96f859d ("libxfs: pack the agfl header structure so XFS_AGFL_SIZE is correct") allowed the freelist to use the empty slot at the end of the freelist on 64 bit systems that was not being used due to sizeof() rounding up the structure size. This has caused versions of xfs_repair prior to 4.5.0 (which also has the fix) to report this as a corruption once the filesystem has been grown. Older kernels can also have problems (seen from a whacky container/vm management environment) mounting filesystems grown on a system with a newer kernel than the vm/container it is deployed on. To avoid this problem, change the initial free list indexes not to wrap across the end of the AGFL, hence avoiding the initialisation of agf_fllast to the last index in the AGFL. cc: <stable@vger.kernel.org> # 4.4-4.5 Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_fsops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d0a58e833931234c44e515b5b8bede32bd4e6eed Author: Eric Sandeen <sandeen@redhat.com> Date: Wed Apr 6 07:05:41 2016 +1000 xfs: disallow rw remount on fs with unknown ro-compat features Today, a kernel which refuses to mount a filesystem read-write due to unknown ro-compat features can still transition to read-write via the remount path. The old kernel is most likely none the wiser, because it's unaware of the new feature, and isn't using it. However, writing to the filesystem may well corrupt metadata related to that new feature, and moving to a newer kernel which understand the feature will have problems. Right now the only ro-compat feature we have is the free inode btree, which showed up in v3.16. It would be good to push this back to all the active stable kernels, I think, so that if anyone is using newer mkfs (which enables the finobt feature) with older kernel releases, they'll be protected. Cc: <stable@vger.kernel.org> # 3.10.x- Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Bill O'Donnell <billodo@redhat.com> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com> fs/xfs/xfs_super.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 66f87790361c2c33dd7948a618da0cb632eed20d Merge: e43d15c 627d2d6 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 16:29:38 2016 -0400 Merge branch 'udp-peek' Willem de Bruijn says: ==================== udp: support SO_PEEK_OFF Support peeking at a non-zero offset for UDP sockets. Match the existing behavior on Unix datagram sockets. 1/3 makes the sk_peek_offset functions safe to use outside locks 2/3 removes udp headers before enqueue, to simplify offset arithmetic 3/3 introduces SO_PEEK_OFFSET support, with Unix socket peek semantics. Changes v1->v2 - squash patches 3 and 4 ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 627d2d6b550094d88f9e518e15967e7bf906ebbf Author: samanthakumar <samanthakumar@google.com> Date: Tue Apr 5 12:41:16 2016 -0400 udp: enable MSG_PEEK at non-zero offset Enable peeking at UDP datagrams at the offset specified with socket option SOL_SOCKET/SO_PEEK_OFF. Peek at any datagram in the queue, up to the end of the given datagram. Implement the SO_PEEK_OFF semantics introduced in commit ef64a54f6e55 ("sock: Introduce the SO_PEEK_OFF sock option"). Increase the offset on peek, decrease it on regular reads. When peeking, always checksum the packet immediately, to avoid recomputation on subsequent peeks and final read. The socket lock is not held for the duration of udp_recvmsg, so peek and read operations can run concurrently. Only the last store to sk_peek_off is preserved. Signed-off-by: Sam Kumar <samanthakumar@google.com> Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/skbuff.h | 7 ++++++- include/net/sock.h | 2 ++ net/core/datagram.c | 9 ++++++--- net/core/sock.c | 9 +++++++++ net/ipv4/af_inet.c | 1 + net/ipv4/udp.c | 22 +++++++++++----------- net/ipv6/af_inet6.c | 1 + net/ipv6/udp.c | 22 +++++++++++----------- 8 files changed, 47 insertions(+), 26 deletions(-) commit e6afc8ace6dd5cef5e812f26c72579da8806f5ac Author: samanthakumar <samanthakumar@google.com> Date: Tue Apr 5 12:41:15 2016 -0400 udp: remove headers from UDP packets before queueing Remove UDP transport headers before queueing packets for reception. This change simplifies a follow-up patch to add MSG_PEEK support. Signed-off-by: Sam Kumar <samanthakumar@google.com> Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 1 + include/net/udp.h | 9 +++++++++ net/core/sock.c | 19 +++++++++++++------ net/ipv4/udp.c | 20 +++++++++++--------- net/ipv6/udp.c | 12 +++++++----- 5 files changed, 41 insertions(+), 20 deletions(-) commit b9bb53f3836f4eb2bdeb3447be11042bd29c2408 Author: Willem de Bruijn <willemb@google.com> Date: Tue Apr 5 12:41:14 2016 -0400 sock: convert sk_peek_offset functions to WRITE_ONCE Make the peek offset interface safe to use in lockless environments. Use READ_ONCE and WRITE_ONCE to avoid race conditions between testing and updating the peek offset. Suggested-by: Eric Dumazet <edumazet@google.com> Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) commit e43d15c8d3c8680fbf142360e5958f2ddd437047 Merge: f1cc809 50f26a5 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 16:26:31 2016 -0400 Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 40GbE Intel Wired LAN Driver Updates 2016-04-05 This series contains updates to i40e and i40evf only. Stefan converts dev_close() to ndo_stop() for ethtool offline self test, since dev_close() causes IFF_UP to be cleared which will remove the interface routes and addresses. Alex bumps up the size of the transmit data buffer to 12K rather than 8K, which provides a gain in throughput and a reduction in overhead for putting together the frame. Fixed an issue in the polling routines where we were using bitwise operators to avoid the side effects of the logical operators. Then added support for bulk transmit clean for skbs. Jesse fixed a sparse issue in the type casting in the transmit code and fixed i40e_aq_set_phy_debug() to use i40e_status as a return code. Catherine cleans up duplicated code. Shannon fixed the cleaning up of the interrupt handling to clean up the IRQs only if we actually got them set up. Also fixed up the error scenarios where we were trying to remove a non-existent timer or worktask, which causes the kernel heartburn. Mitch changes the notification of resets to the reset interrupt handler, instead of the actual reset initiation code. This allows the VFs to get properly notified for all resets, including resets initiated by different PFs on the same physical device. Also moved the clearing of VFLR bit after reset processing, instead of before which could lead to double resets on VF init. Fixed code comment to match the actual function name. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit f1cc8094de7b04dda6f3c5c776f7202dbe6c20ea Merge: 04c85bf 29c262f Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 16:20:49 2016 -0400 Merge branch 'bnxt_en-next' Michael Chan says: ==================== bnxt_en: Updates for net-next. Update to latest firmware interface, add EEE feature, unsupported SFP+ module warning, and ethtool -s improvements. v2: Removed the GEEPROM patch and added more comments to the get_eee patch. ==================== commit 29c262fed4067c52977ba279cf71520f9991a050 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:09:03 2016 -0400 bnxt_en: Improve ethtool .get_settings(). If autoneg is off, we should always report the speed and duplex settings even if it is link down so the user knows the current settings. The unknown speed and duplex should only be used for autoneg when link is down. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) commit 9d9cee08fc9f5c4df84ef314158fd19c013bcec6 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:09:02 2016 -0400 bnxt_en: Check for valid forced speed during ethtool -s. Check that the forced speed is a valid speed supported by firmware. If not supported, return -EINVAL. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 48 ++++++++++++++++++----- 1 file changed, 38 insertions(+), 10 deletions(-) commit 4bb13abf208cb484a9b9d1af9233b0ef850c2fe7 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:09:01 2016 -0400 bnxt_en: Add unsupported SFP+ module warnings. Add the PORT_CONN_NOT_ALLOWED async event handling logic. The driver will print an appropriate warning to reflect the SFP+ module enforcement policy done in the firmware. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 55 +++++++++++++++++++++++++++++++ drivers/net/ethernet/broadcom/bnxt/bnxt.h | 3 ++ 2 files changed, 58 insertions(+) commit 25be862370031056989ee76e3c48c3ac8ff67fd4 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:09:00 2016 -0400 bnxt_en: Set async event bits when registering with the firmware. Currently, the driver only sets bit 0 of the async_event_fwd fields. To be compatible with the latest spec, we need to set the appropriate event bits handled by the driver. We should be handling link change and PF driver unload events, so these 2 bits should be set. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) commit 72b34f04e0b00956dd679ae18bf2163669df8b56 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:08:59 2016 -0400 bnxt_en: Add get_eee() and set_eee() ethtool support. Allow users to get|set EEE parameters. v2: Added comment for preserving the tx_lpi_timer value in get_eee. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 76 +++++++++++++++++++++++ 1 file changed, 76 insertions(+) commit 939f7f0ca442187db2a4ec7a40979c711b0c939e Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:08:58 2016 -0400 bnxt_en: Add EEE setup code. 1. Add bnxt_hwrm_set_eee() function to setup EEE firmware parameters based on the bp->eee settings. 2. The new function bnxt_eee_config_ok() will check if EEE parameters need to be modified due to autoneg changes. 3. bnxt_hwrm_set_link() has added a new parameter to update EEE. If the parameter is set, it will call bnxt_hwrm_set_eee(). Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 58 ++++++++++++++++++++++- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 4 +- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.h | 1 + 4 files changed, 60 insertions(+), 5 deletions(-) commit 170ce01301a2a1a87808765531d938fa0b023641 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:08:57 2016 -0400 bnxt_en: Add basic EEE support. Get EEE capability and the initial EEE settings from firmware. Add "EEE is active | not active" to link up dmesg. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 82 ++++++++++++++++++++++- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 4 ++ drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.h | 1 + 4 files changed, 87 insertions(+), 2 deletions(-) commit c9ee9516c161da2d072e035907aa35a35dfa68a8 Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:08:56 2016 -0400 bnxt_en: Improve flow control autoneg with Firmware 1.2.1 interface. Make use of the new AUTONEG_PAUSE bit in the new interface to better control autoneg flow control settings, independent of RX and TX advertisement settings. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 28 +++++++++++++++++++---- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 10 ++++---- 2 files changed, 27 insertions(+), 11 deletions(-) commit 11f15ed394782dd018d60a0bb550616a8571b43c Author: Michael Chan <michael.chan@broadcom.com> Date: Tue Apr 5 14:08:55 2016 -0400 bnxt_en: Update to Firmware 1.2.2 spec. Use new field names in API structs and stop using deprecated fields auto_link_speed and auto_duplex in phy_cfg/phy_qcfg structs. Update copyright year to 2016. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 20 +- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 8 +- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 4 +- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.h | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_fw_hdr.h | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_hsi.h | 433 +++++++++++++++++++-- drivers/net/ethernet/broadcom/bnxt/bnxt_nvm_defs.h | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_sriov.c | 14 +- drivers/net/ethernet/broadcom/bnxt/bnxt_sriov.h | 2 +- 9 files changed, 431 insertions(+), 56 deletions(-) commit 61d612ea731e57dc510472fb746b55cdc017f371 Author: Jeff Vander Stoep <jeffv@google.com> Date: Tue Apr 5 13:06:27 2016 -0700 selinux: restrict kernel module loading Utilize existing kernel_read_file hook on kernel module load. Add module_load permission to the system class. Enforces restrictions on kernel module origin when calling the finit_module syscall. The hook checks that source type has permission module_load for the target type. Example for finit_module: allow foo bar_file:system module_load; Similarly restrictions are enforced on kernel module loading when calling the init_module syscall. The hook checks that source type has permission module_load with itself as the target object because the kernel module is sourced from the calling process. Example for init_module: allow foo foo:system module_load; Signed-off-by: Jeff Vander Stoep <jeffv@google.com> [PM: fixed return value of selinux_kernel_read_file()] Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 47 +++++++++++++++++++++++++++++++++++++ security/selinux/include/classmap.h | 2 +- 2 files changed, 48 insertions(+), 1 deletion(-) commit 0c6181cb301fd04a5800920ba423be753b0a4a01 Author: Paul Moore <paul@paul-moore.com> Date: Wed Mar 30 21:41:21 2016 -0400 selinux: consolidate the ptrace parent lookup code We lookup the tracing parent in two places, using effectively the same code, let's consolidate it. Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 38 +++++++++++++++++--------------------- 1 file changed, 17 insertions(+), 21 deletions(-) commit 4b57d6bcd94034e2eb168bdec2474e3b2b848e44 Author: Paul Moore <paul@paul-moore.com> Date: Mon Mar 28 15:16:53 2016 -0400 selinux: simply inode label states to INVALID and INITIALIZED There really is no need for LABEL_MISSING as we really only care if the inode's label is INVALID or INITIALIZED. Also adjust the revalidate code to reload the label whenever the label is not INITIALIZED so we are less sensitive to label state in the future. Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 2 +- security/selinux/include/objsec.h | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) commit 899134f2f6e27dcae1fee12593c492577cc80987 Author: Paul Moore <paul@paul-moore.com> Date: Mon Mar 28 15:19:10 2016 -0400 selinux: don't revalidate inodes in selinux_socket_getpeersec_dgram() We don't have to worry about socket inodes being invalidated so use inode_security_novalidate() to fetch the inode's security blob. Signed-off-by: Paul Moore <paul@paul-moore.com> security/selinux/hooks.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 341e0cb593a2b7ec86dd6ca96c68eadc3f6fe1e6 Author: Janak Desai <Janak.Desai@gtri.gatech.edu> Date: Mon Mar 28 11:09:46 2016 -0400 netlabel: fix a problem with netlbl_secattr_catmap_setrng() We try to be clever and set large chunks of the bitmap at once, when possible; unfortunately we weren't very clever when we wrote the code and messed up the if-conditional. Fix this bug and restore proper operation. Signed-off-by: Janak Desai <Janak.Desai@gtri.gatech.edu> Signed-off-by: Paul Moore <paul@paul-moore.com> net/netlabel/netlabel_kapi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 04c85bfb4f75d1dd02bc6e82698db701dd5ea8a9 Merge: 265bee7 0ea7fae Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 16:08:02 2016 -0400 Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 100GbE Intel Wired LAN Driver Updates 2016-04-05 This series contains updates to fm10k only. Bruce provides nearly half of the patches in the series, most of which do general cleanup of the driver. These include semantic cleanups, checkpatch.pl fixes, update driver to use BIT() kernel macro, use BUILD_BUG_ON() where appropriate and use ether_addr_copy() instead of memcpy(). Jake provides the remaining patches in the series, starting with a fix for a possible NULL pointer deference. Next delays initialization of the service timer and service task until late in probe(). If we do not wait, failures in probe do not properly cleanup the service timer or service task items which result in a kernel panic. Added better reporting during error conditions. Fixed another possible kernel panic where we were clearing the interrupt scheme before we freed the mailbox IRQ. Added helper functions for setting strings and data for ethtool stats. Fixed comment mis-spelled words. v2: Dropped patch 3 from the original submission, until a better solution can be worked up based on feedback from Joe Perches and David Miller. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 0ea7fae44094b4ca06ea68105457a7dc64041bd3 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Tue Feb 16 16:19:24 2016 -0800 fm10k: use ethtool_rxfh_indir_default for default redirection table The fm10k driver used its own code for generating a default indirection table on device load, which was not the same as the default generated by ethtool when indir_size of 0 is passed to SRXFH. Take advantage of ethtool_rxfh_indir_default() and simplify code to write the redirection table to reduce some code duplication. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k.h | 2 ++ drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 37 ++++++++++++++---------- drivers/net/ethernet/intel/fm10k/fm10k_main.c | 24 +++++++-------- 3 files changed, 34 insertions(+), 29 deletions(-) commit d8ec92f2cdcc7f2d06dd0a40b600b6da7d9d1070 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Feb 10 14:45:51 2016 -0800 fm10k: fix a minor typo in some comments s/funciton/function to resolve a typo, and cleanup grammar on a few comments regarding processing the VF mailboxes. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_iov.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_netdev.c | 4 ++-- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 6 +++--- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) commit 4be37c42a40cec94b0381b42e5796d3316f96c32 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Wed Feb 10 14:45:50 2016 -0800 fm10k: correctly clean up when init_queueing_scheme fails Fix a kernel panic that occurs during surprise removal. Clear the interface queue counts upon fm10k_init_msix_capability failure. This prevents further code (fm10k_update_stats etc.) from attempting to access unallocated queue vector or ring memory. [ 628.692648] BUG: unable to handle kernel NULL pointer dereference at 0000000000000068 [ 628.692805] IP: [<ffffffffa0475caf>] fm10k_update_stats+0x7f/0x2c0 [fm10k] [ 628.693173] PGD 0 [ 628.693759] Oops: 0000 [#1] SMP [ 628.699321] CPU: 10 PID: 8164 Comm: kworker/10:0 Tainted: G OE ------------ 3.10.0-327.el7.x86_64 #1 [ 628.700096] Hardware name: Supermicro X9DAi/X9DAi, BIOS 3.2 05/09/2015 [ 628.700894] Workqueue: pciehp-1 pciehp_power_thread [ 628.701686] task: ffff88086559c500 ti: ffff8808593c0000 task.ti: ffff8808593c0000 [ 628.702493] RIP: 0010:[<ffffffffa0475caf>] [<ffffffffa0475caf>] fm10k_update_stats+0x7f/0x2c0 [fm10k] [ 628.703310] RSP: 0018:ffff8808593c3b00 EFLAGS: 00010282 [ 628.704132] RAX: 0000000000000000 RBX: ffff880860760000 RCX: 0000000000000000 [ 628.704963] RDX: ffff880860760b08 RSI: 0000000000000000 RDI: 0000000000000000 [ 628.705794] RBP: ffff8808593c3b40 R08: 0000000000000000 R09: 0000000000000000 [ 628.706604] R10: 0000000000000000 R11: ffff880860760c40 R12: 0000000000000080 [ 628.707420] R13: ffff8808607608c0 R14: ffff880860779ec0 R15: ffff880860779f40 [ 628.708238] FS: 0000000000000000(0000) GS:ffff88086f000000(0000) knlGS:0000000000000000 [ 628.709071] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 628.709923] CR2: 0000000000000068 CR3: 000000000194a000 CR4: 00000000001407e0 [ 628.710752] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 628.711596] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400 [ 628.712438] Stack: [ 628.713255] ffff880860764458 ffff8808607608c0 ffff880860760000 ffff880860760000 [ 628.714088] 0000000000000080 ffff8808607608c0 ffff880860779ec0 ffff880860779f40 [ 628.714925] ffff8808593c3b88 ffffffffa04780c5 ffff880860764458 0000000a8163cb5b [ 628.715752] Call Trace: [ 628.716560] [<ffffffffa04780c5>] fm10k_down+0x155/0x1f0 [fm10k] [ 628.717367] [<ffffffffa0479958>] fm10k_close+0x28/0xd0 [fm10k] [ 628.718184] [<ffffffff81526365>] __dev_close_many+0x85/0xd0 [ 628.718986] [<ffffffff815264d8>] dev_close_many+0x98/0x120 [ 628.719764] [<ffffffff81527ab8>] rollback_registered_many+0xa8/0x230 [ 628.720527] [<ffffffff81527c80>] rollback_registered+0x40/0x70 [ 628.721294] [<ffffffff81529198>] unregister_netdevice_queue+0x48/0x80 [ 628.722052] [<ffffffff815291ec>] unregister_netdev+0x1c/0x30 [ 628.722816] [<ffffffffa04762b8>] fm10k_remove+0xd8/0xe0 [fm10k] [ 628.723581] [<ffffffff81328c7b>] pci_device_remove+0x3b/0xb0 [ 628.724340] [<ffffffff813f5fbf>] __device_release_driver+0x7f/0xf0 [ 628.725088] [<ffffffff813f6053>] device_release_driver+0x23/0x30 [ 628.725814] [<ffffffff81321fe4>] pci_stop_bus_device+0x94/0xa0 [ 628.726535] [<ffffffff813220d2>] pci_stop_and_remove_bus_device+0x12/0x20 [ 628.727249] [<ffffffff8133de40>] pciehp_unconfigure_device+0xb0/0x1b0 [ 628.727964] [<ffffffff8133d822>] pciehp_disable_slot+0x52/0xd0 [ 628.728664] [<ffffffff8133d98a>] pciehp_power_thread+0xea/0x150 [ 628.729358] [<ffffffff8109d5fb>] process_one_work+0x17b/0x470 [ 628.730036] [<ffffffff8109e3cb>] worker_thread+0x11b/0x400 [ 628.730730] [<ffffffff8109e2b0>] ? rescuer_thread+0x400/0x400 [ 628.731385] [<ffffffff810a5aef>] kthread+0xcf/0xe0 [ 628.732036] [<ffffffff810a5a20>] ? kthread_create_on_node+0x140/0x140 [ 628.732674] [<ffffffff81645858>] ret_from_fork+0x58/0x90 [ 628.733289] [<ffffffff810a5a20>] ? kthread_create_on_node+0x140/0x140 [ 628.733883] Code: 83 e8 01 48 8d 97 40 02 00 00 45 31 c0 4c 8d 9c c7 48 02 0 [ 628.735202] RIP [<ffffffffa0475caf>] fm10k_update_stats+0x7f/0x2c0 [fm10k] [ 628.735732] RSP <ffff8808593c3b00> [ 628.736285] CR2: 0000000000000068 [ 628.736846] ---[ end trace 9156088b311aff42 ]--- Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 35 ++++++++++++++++++++------- 1 file changed, 26 insertions(+), 9 deletions(-) commit c4114e3db6429c665adc3db871685c474a467efe Author: Bruce Allan <bruce.w.allan@intel.com> Date: Wed Feb 10 14:45:47 2016 -0800 fm10k: prevent possibly uninitialized variable If 'attr_flag < (1 << (2 * FM10K_TEST_MSG_NESTED))' is ever false, err will be used uninitialized. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d2e0721b18f320232dc36a0e4cc7beb620e8c9bd Author: Jacob Keller <jacob.e.keller@intel.com> Date: Fri Feb 5 10:43:08 2016 -0800 fm10k: add helper functions to set strings and data for ethtool stats Reduce duplicate code and the amount of indentation by adding fm10k_add_stat_strings and fm10k_add_ethtool_stats functions which help add fm10k_stat structures to the ethtool stats callbacks. This helps increase ease of use for future stat additions, and increases code readability. Skip handling of the per-queue stats as these will be reworked in a following patch. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 164 ++++++++++++----------- 1 file changed, 83 insertions(+), 81 deletions(-) commit c8ed563bebeabbf0b1085b52916dd2fb6e219276 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Feb 4 10:47:58 2016 -0800 fm10k: free MBX IRQ before clearing interrupt scheme During fm10k_io_error_detected we were clearing the interrupt scheme before we freed the MBX IRQ. This causes a kernel panic because the MBX IRQ are assigned after MSI-X initialization. Clearing the interrupt scheme results in removing the MSI-X entry table. Fix this by freeing the MBX IRQ before we clear the interrupt scheme, as we do elsewhere in the driver. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 61e0217e83353cf895f8b2d0a187804171d119ca Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Feb 4 10:47:57 2016 -0800 fm10k: print error message when stop_hw fails fm10k_stop_hw_generic calls fm10k_disable_queues_generic, which may return an error code indicating that the queues were not stopped within the time limit. Notify the user by displaying a message in the kernel message ring, in a similar way to how we notify the user when reset_hw fails. There isn't much we can do to recover from this error, so currently nothing else is done. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit b3525696adba1ecddff3d667680461cc533e63a4 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Feb 4 10:47:56 2016 -0800 fm10k: base queue scheme covered by RSS In fm10k_set_num_queues, we previously assigned the base template. This would always be overwritten by either fm10k_set_qos_queues or fm10k_set_rss_queues. In either case, we don't need the base values, so we can just remove them. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit e72319bba814b115c47785b3b88f7263d0b8a1b8 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Feb 4 10:47:55 2016 -0800 fm10k: don't initialize service task until later in probe Delay initialization of the service timer and service task until late probe. If we don't wait, failures in probe do not properly cleanup the service timer or service task items, which results in the kernel panic below, potentially freezing the whole system. In addition, ensure that the SERVICE_DISABLE bit is set before we request the MBX IRQ since the MBX interrupt attempts to schedule the service task otherwise. This prevents a similar trace from occurring after this change. We didn't notice this issue before because probe almost always completes successfully. I discovered it due to a mis-ordered mailbox handler array, which resulted in the following failure when requesting mailbox interrupt. [ 555.325619] ------------[ cut here ]------------ [ 555.325628] WARNING: CPU: 0 PID: 4941 at lib/list_debug.c:33 __list_add+0xa0/0xd0() [ 555.325631] list_add corruption. prev->next should be next (ffffffff81f46648), but was (null). (prev=ffff8807fad5d0e8). <snip> [ 555.325722] CPU: 0 PID: 4941 Comm: insmod Tainted: G OE 4.0.4-303.fc22.x86_64 #1 [ 555.325725] Hardware name: Intel Corporation S2600CO/S2600CO, BIOS SE5C600.86B.02.03.8x23.060520140825 06/05/2014 [ 555.325727] 0000000000000000 00000000b4f161b3 ffff88081a21f8e8 ffffffff81783124 [ 555.325734] 0000000000000000 ffff88081a21f940 ffff88081a21f928 ffffffff8109c66a [ 555.325740] 0000000064000000 ffff8807fad5d0e8 ffff8807fad5d0e8 ffffffff81f46648 [ 555.325746] Call Trace: [ 555.325752] [<ffffffff81783124>] dump_stack+0x45/0x57 [ 555.325757] [<ffffffff8109c66a>] warn_slowpath_common+0x8a/0xc0 [ 555.325759] [<ffffffff8109c6f5>] warn_slowpath_fmt+0x55/0x70 [ 555.325763] [<ffffffff813ba270>] __list_add+0xa0/0xd0 [ 555.325768] [<ffffffff81102d1d>] __internal_add_timer+0x9d/0x110 [ 555.325771] [<ffffffff81102dbf>] internal_add_timer+0x2f/0xc0 [ 555.325774] [<ffffffff81104e5a>] mod_timer+0x12a/0x230 [ 555.325782] [<ffffffffa03d54ca>] fm10k_probe+0x69a/0xc80 [fm10k] [ 555.325787] [<ffffffff813e8355>] local_pci_probe+0x45/0xa0 [ 555.325791] [<ffffffff8129cf42>] ? sysfs_do_create_link_sd.isra.2+0x72/0xc0 [ 555.325794] [<ffffffff813e96b9>] pci_device_probe+0xf9/0x150 [ 555.325799] [<ffffffff814d7e73>] driver_probe_device+0xa3/0x400 [ 555.325802] [<ffffffff814d82ab>] __driver_attach+0x9b/0xa0 [ 555.325805] [<ffffffff814d8210>] ? __device_attach+0x40/0x40 [ 555.325808] [<ffffffff814d5bd3>] bus_for_each_dev+0x73/0xc0 [ 555.325811] [<ffffffff814d78ce>] driver_attach+0x1e/0x20 [ 555.325815] [<ffffffff814d7480>] bus_add_driver+0x180/0x250 [ 555.325819] [<ffffffffa03b2000>] ? 0xffffffffa03b2000 [ 555.325823] [<ffffffff814d8aa4>] driver_register+0x64/0xf0 [ 555.325826] [<ffffffff813e7bec>] __pci_register_driver+0x4c/0x50 [ 555.325832] [<ffffffffa03d6ca3>] fm10k_register_pci_driver+0x23/0x30 [fm10k] [ 555.325838] [<ffffffffa03b2080>] fm10k_init_module+0x80/0x1000 [fm10k] [ 555.325843] [<ffffffff81002128>] do_one_initcall+0xb8/0x200 [ 555.325848] [<ffffffff811e10d2>] ? __vunmap+0xa2/0x100 [ 555.325852] [<ffffffff811fe239>] ? kmem_cache_alloc_trace+0x1b9/0x240 [ 555.325855] [<ffffffff8178230e>] ? do_init_module+0x28/0x1cb [ 555.325858] [<ffffffff81782346>] do_init_module+0x60/0x1cb [ 555.325862] [<ffffffff8112168e>] load_module+0x205e/0x26b0 [ 555.325866] [<ffffffff8111d110>] ? store_uevent+0x70/0x70 [ 555.325870] [<ffffffff812234b0>] ? kernel_read+0x50/0x80 [ 555.325873] [<ffffffff81121f3e>] SyS_finit_module+0xbe/0xf0 [ 555.325878] [<ffffffff81789749>] system_call_fastpath+0x12/0x17 [ 555.325880] ---[ end trace 9e0f58d071eafd2a ]--- Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) commit de66c610a6adade32bf955f67b4f4f4aaeeeff85 Author: Jacob Keller <jacob.e.keller@intel.com> Date: Thu Feb 4 10:47:54 2016 -0800 fm10k: prevent null pointer dereference of msix_entries table According to the C standard dereferencing a variable before it is checked invokes undefined behavior, and thus compilers are free to assume the check for NULL isn't necessary. Prevent this by re-ordering the NULL check of msix_entries in fm10k_free_mbx_irq. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 11c49f79b294081010f7e13a95c6b40c4d36b1de Author: Bruce Allan <bruce.w.allan@intel.com> Date: Mon Dec 28 18:00:30 2015 -0800 fm10k: use ether_addr_copy to copy MAC address Cleanup the remaining instances of using memcpy() instead of the preferred ether_addr_copy(). Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 1905add427cdee1b52380241574ab1339b1df413 Author: Bruce Allan <bruce.w.allan@intel.com> Date: Tue Dec 22 14:55:26 2015 -0800 fm10k: cleanup SPACE_BEFORE_TAB checkpatch warning Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_ptp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 838e6102920a288a88f5bba10784ab10b2f2eb3e Author: Bruce Allan <bruce.w.allan@intel.com> Date: Tue Dec 22 14:55:20 2015 -0800 fm10k: demote BUG_ON() to WARN_ON() where appropriate We don't need to crash the kernel in this instance so just warn about the condition and play on. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fcdb0a9951d8a5edfc47e89a7fe62457c25e18c4 Author: Bruce Allan <bruce.w.allan@intel.com> Date: Tue Dec 22 13:43:49 2015 -0800 fm10k: cleanup remaining right-bit-shifted 1 Use BIT() macro instead. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k.h | 12 ++++++------ drivers/net/ethernet/intel/fm10k/fm10k_ethtool.c | 20 +++++++++----------- drivers/net/ethernet/intel/fm10k/fm10k_main.c | 20 ++++++++++---------- drivers/net/ethernet/intel/fm10k/fm10k_netdev.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 8 ++++---- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 12 ++++++------ drivers/net/ethernet/intel/fm10k/fm10k_tlv.c | 24 ++++++++++++------------ drivers/net/ethernet/intel/fm10k/fm10k_type.h | 8 ++++---- 8 files changed, 52 insertions(+), 54 deletions(-) commit 1aab144c507a9849d5b4557d6d78db185ceaef37 Author: Bruce Allan <bruce.w.allan@intel.com> Date: Tue Dec 22 13:43:44 2015 -0800 fm10k: Move constants to the right of binary operators The semantic patch that makes this change is available in scripts/coccinelle/misc/compare_const_fl.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/fm10k/fm10k_main.c | 2 +- drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 16 ++++++++-------- drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) commit e596af827960c41a6051d4e719bafcfb7da11b64 Author: Bob Copeland <me@bobcopeland.com> Date: Sat Mar 26 11:27:19 2016 -0400 mac80211: mesh: flush paths outside of plink lock Lockdep warned of a lock dependency between the mesh_plink lock and the internal lock for the rhashtable. The problem is that the rhashtable code uses a spin lock with softirqs enabled, while mesh_plink_timer executes a walk (to flush paths on a state change) inside a softirq with the plink lock held. This leads to the following deadlock if the timer fires while rht lock is held on this CPU, and plink lock is held on another CPU: CPU0 CPU1 ---- ---- lock(&(&ht->lock)->rlock); local_irq_disable(); lock(&(&sta->mesh->plink_lock)->rlock); lock(&(&ht->lock)->rlock); <Interrupt> lock(&(&sta->mesh->plink_lock)->rlock); *** DEADLOCK *** Fix by waiting until we drop the plink lock to flush paths. Fixes: d48a1b7cd439 ("mac80211: mesh: convert path table to rhashtable") Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh_plink.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 0371a08fbb3e557f19db41e47a199ad8300c9c97 Author: Bob Copeland <me@bobcopeland.com> Date: Sat Mar 26 11:27:18 2016 -0400 mac80211: mesh: fix cleanup for mesh pathtable The mesh path table needs to be around for the entire time the interface is in mesh mode, as users can perform an mpath dump at any time. The existing path table lifetime is instead tied to the mesh BSS which can cause crashes when different MBSSes are joined in the context of a single interface, or when the path table is dumped when no MBSS is joined. Introduce a new function to perform the final teardown of the interface and perform path table cleanup there. We already free the individual path elements when the leaving the mesh so no additional cleanup is needed there. This fixes the following crash: [ 47.753026] BUG: unable to handle kernel paging request at fffffff0 [ 47.753026] IP: [<c0239765>] kthread_data+0xa/0xe [ 47.753026] *pde = 00741067 *pte = 00000000 [ 47.753026] Oops: 0000 [#4] PREEMPT [ 47.753026] Modules linked in: ppp_generic slhc 8021q garp mrp sch_fq_codel iptable_mangle ipt_MASQUERADE nf_nat_masquerade_ipv4 iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat ip_tables ath9k_htc ath5k 8139too ath10k_pci ath10k_core arc4 ath9k ath9k_common ath9k_hw mac80211 ath cfg80211 cpufreq_powersave br_netfilter bridge stp llc ipw usb_wwan sierra_net usbnet af_alg natsemi via_rhine mii iTCO_wdt iTCO_vendor_support gpio_ich sierra coretemp pcspkr i2c_i801 lpc_ich ata_generic ata_piix libata ide_pci_generic piix e1000e igb i2c_algo_bit ptp pps_core [last unloaded: 8139too] [ 47.753026] CPU: 0 PID: 12 Comm: kworker/u2:1 Tainted: G D W 4.5.0-wt-V3 #6 [ 47.753026] Hardware name: To Be Filled By O.E.M./To be filled by O.E.M., BIOS 080016 11/07/2014 [ 47.753026] task: f645a0c0 ti: f6462000 task.ti: f6462000 [ 47.753026] EIP: 0060:[<c0239765>] EFLAGS: 00010002 CPU: 0 [ 47.753026] EIP is at kthread_data+0xa/0xe [ 47.753026] EAX: 00000000 EBX: 00000000 ECX: 00000000 EDX: 00000000 [ 47.753026] ESI: f645a0c0 EDI: f645a2fc EBP: f6463a80 ESP: f6463a78 [ 47.753026] DS: 007b ES: 007b FS: 0000 GS: 0000 SS: 0068 [ 47.753026] CR0: 8005003b CR2: 00000014 CR3: 353e5000 CR4: 00000690 [ 47.753026] Stack: [ 47.753026] c0236866 00000000 f6463aac c05768b4 00000009 f6463ba8 f6463ab0 c0247010 [ 47.753026] 00000000 f645a0c0 f6464000 00000009 f6463ba8 f6463ab8 c0576eb2 f645a0c0 [ 47.753026] f6463aec c0228be4 c06335a4 f6463adc f6463ad0 c06c06d4 f6463ae4 c02471b0 [ 47.753026] Call Trace: [ 47.753026] [<c0236866>] ? wq_worker_sleeping+0xb/0x78 [ 47.753026] [<c05768b4>] __schedule+0xda/0x587 [ 47.753026] [<c0247010>] ? vprintk_default+0x12/0x14 [ 47.753026] [<c0576eb2>] schedule+0x72/0x89 [ 47.753026] [<c0228be4>] do_exit+0xb8/0x71d [ 47.753026] [<c02471b0>] ? kmsg_dump+0xa9/0xae [ 47.753026] [<c0203576>] oops_end+0x69/0x70 [ 47.753026] [<c021dcdb>] no_context+0x1bb/0x1c5 [ 47.753026] [<c021de1b>] __bad_area_nosemaphore+0x136/0x140 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021de32>] bad_area_nosemaphore+0xd/0x10 [ 47.753026] [<c021e0a1>] __do_page_fault+0x26c/0x320 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021e2fa>] do_page_fault+0xb/0xd [ 47.753026] [<c05798f8>] error_code+0x58/0x60 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c0239765>] ? kthread_data+0xa/0xe [ 47.753026] [<c0236866>] ? wq_worker_sleeping+0xb/0x78 [ 47.753026] [<c05768b4>] __schedule+0xda/0x587 [ 47.753026] [<c0247010>] ? vprintk_default+0x12/0x14 [ 47.753026] [<c0576eb2>] schedule+0x72/0x89 [ 47.753026] [<c0228be4>] do_exit+0xb8/0x71d [ 47.753026] [<c02471b0>] ? kmsg_dump+0xa9/0xae [ 47.753026] [<c0203576>] oops_end+0x69/0x70 [ 47.753026] [<c021dcdb>] no_context+0x1bb/0x1c5 [ 47.753026] [<c021de1b>] __bad_area_nosemaphore+0x136/0x140 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021de32>] bad_area_nosemaphore+0xd/0x10 [ 47.753026] [<c021e0a1>] __do_page_fault+0x26c/0x320 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021e2fa>] do_page_fault+0xb/0xd [ 47.753026] [<c05798f8>] error_code+0x58/0x60 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c0239765>] ? kthread_data+0xa/0xe [ 47.753026] [<c0236866>] ? wq_worker_sleeping+0xb/0x78 [ 47.753026] [<c05768b4>] __schedule+0xda/0x587 [ 47.753026] [<c0391e32>] ? put_io_context_active+0x6d/0x95 [ 47.753026] [<c0576eb2>] schedule+0x72/0x89 [ 47.753026] [<c02291f8>] do_exit+0x6cc/0x71d [ 47.753026] [<c0203576>] oops_end+0x69/0x70 [ 47.753026] [<c021dcdb>] no_context+0x1bb/0x1c5 [ 47.753026] [<c021de1b>] __bad_area_nosemaphore+0x136/0x140 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021de32>] bad_area_nosemaphore+0xd/0x10 [ 47.753026] [<c021e0a1>] __do_page_fault+0x26c/0x320 [ 47.753026] [<c03b9160>] ? debug_smp_processor_id+0x12/0x16 [ 47.753026] [<c02015e2>] ? __switch_to+0x24/0x40e [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c021e2fa>] do_page_fault+0xb/0xd [ 47.753026] [<c05798f8>] error_code+0x58/0x60 [ 47.753026] [<c021e2ef>] ? vmalloc_sync_all+0x19a/0x19a [ 47.753026] [<c03b59d2>] ? rhashtable_walk_init+0x5c/0x93 [ 47.753026] [<f9843221>] mesh_path_tbl_expire.isra.24+0x19/0x82 [mac80211] [ 47.753026] [<f984408b>] mesh_path_expire+0x11/0x1f [mac80211] [ 47.753026] [<f9842bb7>] ieee80211_mesh_work+0x73/0x1a9 [mac80211] [ 47.753026] [<f98207d1>] ieee80211_iface_work+0x2ff/0x311 [mac80211] [ 47.753026] [<c0235fa3>] process_one_work+0x14b/0x24e [ 47.753026] [<c0236313>] worker_thread+0x249/0x343 [ 47.753026] [<c02360ca>] ? process_scheduled_works+0x24/0x24 [ 47.753026] [<c0239359>] kthread+0x9e/0xa3 [ 47.753026] [<c0578e50>] ret_from_kernel_thread+0x20/0x40 [ 47.753026] [<c02392bb>] ? kthread_parkme+0x18/0x18 [ 47.753026] Code: 6b c0 85 c0 75 05 e8 fb 74 fc ff 89 f8 84 c0 75 08 8d 45 e8 e8 34 dd 33 00 83 c4 28 5b 5e 5f 5d c3 55 8b 80 10 02 00 00 89 e5 5d <8b> 40 f0 c3 55 b9 04 00 00 00 89 e5 52 8b 90 10 02 00 00 8d 45 [ 47.753026] EIP: [<c0239765>] kthread_data+0xa/0xe SS:ESP 0068:f6463a78 [ 47.753026] CR2: 00000000fffffff0 [ 47.753026] ---[ end trace 867ca0bdd0767790 ]--- Fixes: 3b302ada7f0a ("mac80211: mesh: move path tables into if_mesh") Reported-by: Fred Veldini <fred.veldini@gmail.com> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/iface.c | 2 +- net/mac80211/mesh.c | 7 ++++++- net/mac80211/mesh.h | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) commit 68bb54b47ea1130e57049d86d172d0e098edb3f4 Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:11:32 2016 -0400 mac80211: mesh: fix mesh path kerneldoc Several of the mesh path fields are undocumented and some of the documentation is no longer correct or relevant after the switch to rhashtable. Clean up the kernel doc accordingly and reorder some fields to match the structure layout. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.h | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) commit 3257523bed496316dad95d5a341bfd49ac16624b Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:11:31 2016 -0400 mac80211: mesh: reorder structure members Reduce padding waste in struct mesh_table and struct rmc_entry by moving the smaller fields to the end. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 18b27ff7d2e232b0f07f2f51aa8052ff2a617908 Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:11:30 2016 -0400 mac80211: mesh: embed gates hlist head directly Since we have converted the mesh path tables to rhashtable, we are no longer swapping out the entire mesh_pathtbl pointer with RCU. As a result, we no longer need indirection to the hlist head for the gates list and can simply embed it, saving a pair of pointer-sized allocations. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.h | 2 +- net/mac80211/mesh_pathtbl.c | 18 ++++-------------- 2 files changed, 5 insertions(+), 15 deletions(-) commit 47a0489ce1e518f4936c7fedb93b3d2abd7ccd2e Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:11:29 2016 -0400 mac80211: mesh: use hlist for rmc cache The RMC cache has 256 list heads plus a u32, which puts it at the unfortunate size of 4104 bytes with padding. kmalloc() will then round this up to the next power-of-two, so we wind up actually using two pages here where most of the second is wasted. Switch to hlist heads here to reduce the structure size down to fit within a page. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.c | 18 ++++++++++-------- net/mac80211/mesh.h | 4 ++-- 2 files changed, 12 insertions(+), 10 deletions(-) commit 0aa7fabbd5d9da1f8a8fdc3e2837c532bcfa5664 Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:11:28 2016 -0400 mac80211: mesh: handle failed alloc for rmc cache In the unlikely case that mesh_rmc_init() fails with -ENOMEM, the rmc pointer will be left as NULL but the interface is still operational because ieee80211_mesh_init_sdata() is not allowed to fail. If this happens, we would blindly dereference rmc when checking whether a multicast frame is in the cache. Instead just drop the frames in the forwarding path. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.c | 3 +++ 1 file changed, 3 insertions(+) commit 749329594b5e0fb612b2de642a692323ddf661dd Author: Bob Copeland <me@bobcopeland.com> Date: Fri Mar 18 22:03:24 2016 -0400 mac80211: mesh: fix crash in mesh_path_timer The mesh_path_reclaim() function, called from an rcu callback, cancels the mesh_path_timer associated with a mesh path. Unfortunately, this call can happen much later, perhaps after the hash table itself is destroyed. Such a situation led to the following crash in mesh_path_send_to_gates() when dereferencing the tbl pointer: [ 23.901661] BUG: unable to handle kernel NULL pointer dereference at 0000000000000008 [ 23.905516] IP: [<ffffffff814c910b>] mesh_path_send_to_gates+0x2b/0x740 [ 23.908757] PGD 99ca067 PUD 99c4067 PMD 0 [ 23.910789] Oops: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC [ 23.913485] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.5.0-rc6-wt+ #43 [ 23.916675] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Debian-1.8.2-1 04/01/2014 [ 23.920471] task: ffffffff81685500 ti: ffffffff81678000 task.ti: ffffffff81678000 [ 23.922619] RIP: 0010:[<ffffffff814c910b>] [<ffffffff814c910b>] mesh_path_send_to_gates+0x2b/0x740 [ 23.925237] RSP: 0018:ffff88000b403d30 EFLAGS: 00010286 [ 23.926739] RAX: 0000000000000000 RBX: ffff880009bc0d20 RCX: 0000000000000102 [ 23.928796] RDX: 000000000000002e RSI: 0000000000000001 RDI: ffff880009bc0d20 [ 23.930895] RBP: ffff88000b403e18 R08: 0000000000000001 R09: 0000000000000001 [ 23.932917] R10: 0000000000000000 R11: 0000000000000001 R12: ffff880009c20940 [ 23.936370] R13: ffff880009bc0e70 R14: ffff880009c21c40 R15: ffff880009bc0d20 [ 23.939823] FS: 0000000000000000(0000) GS:ffff88000b400000(0000) knlGS:0000000000000000 [ 23.943688] CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b [ 23.946429] CR2: 0000000000000008 CR3: 00000000099c5000 CR4: 00000000000006b0 [ 23.949861] Stack: [ 23.950840] 000000000000002e ffff880009c20940 ffff88000b403da8 ffffffff8109e551 [ 23.954467] ffffffff82711be2 000000000000002e 0000000000000000 ffffffff8166a5f5 [ 23.958141] 0000000000685ce8 0000000000000246 ffff880009bc0d20 ffff880009c20940 [ 23.961801] Call Trace: [ 23.962987] <IRQ> [ 23.963963] [<ffffffff8109e551>] ? vprintk_emit+0x351/0x5e0 [ 23.966782] [<ffffffff8109e8ff>] ? vprintk_default+0x1f/0x30 [ 23.969529] [<ffffffff810ffa41>] ? printk+0x48/0x50 [ 23.971956] [<ffffffff814ceef3>] mesh_path_timer+0x133/0x160 [ 23.974707] [<ffffffff814cedc0>] ? mesh_nexthop_resolve+0x230/0x230 [ 23.977775] [<ffffffff810b04ee>] call_timer_fn+0xce/0x330 [ 23.980448] [<ffffffff810b0425>] ? call_timer_fn+0x5/0x330 [ 23.983126] [<ffffffff814cedc0>] ? mesh_nexthop_resolve+0x230/0x230 [ 23.986091] [<ffffffff810b097c>] run_timer_softirq+0x22c/0x390 Instead of cancelling in the RCU callback, set a new flag to prevent the timer from being rearmed, and then cancel the timer synchronously when freeing the mesh path. This leaves mesh_path_reclaim() doing nothing but kfree, so switch to kfree_rcu(). Fixes: 3b302ada7f0a ("mac80211: mesh: move path tables into if_mesh") Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.h | 3 +++ net/mac80211/mesh_hwmp.c | 4 ++++ net/mac80211/mesh_pathtbl.c | 33 ++++++++++++++++++--------------- 3 files changed, 25 insertions(+), 15 deletions(-) commit 52cfa1d6146c5aa48360b02533fc7e039a66086e Author: Ayala Beker <ayala.beker@intel.com> Date: Thu Mar 17 15:41:39 2016 +0200 mac80211: track and tell driver about GO client P2P PS abilities Legacy clients don't support P2P power save mechanism, and thus if a P2P GO has a legacy client connected to it, it should disable P2P PS mechanisms. Let the driver know about this with a new bss_conf parameter. Signed-off-by: Ayala Beker <ayala.beker@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 8 +++++++- net/mac80211/cfg.c | 4 ++++ net/mac80211/sta_info.c | 29 +++++++++++++++++++++++++++++ 3 files changed, 40 insertions(+), 1 deletion(-) commit 17b942478643c5a90c06d978479bd326040bfa19 Author: Ayala Beker <ayala.beker@intel.com> Date: Thu Mar 17 15:41:38 2016 +0200 cfg80211: allow userspace to specify client P2P PS support Legacy clients don't support P2P power save mechanisms, and thus if a P2P GO has a legacy client connected to it, it has to make some changes in the PS behavior. To handle this, add an attribute to specify whether a station supports P2P PS or not. If the attribute was not specified cfg80211 will assume that station supports it for P2P GO interface, and does NOT support it for AP interface, matching the current assumptions in the code. Signed-off-by: Ayala Beker <ayala.beker@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 2 ++ include/uapi/linux/nl80211.h | 19 +++++++++++++++++++ net/wireless/nl80211.c | 34 ++++++++++++++++++++++++++++++++++ 3 files changed, 55 insertions(+) commit b100e5d622aa8719cc2e776c397817afe24b1f3b Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 17 15:41:37 2016 +0200 mac80211: avoid useless memory write on each frame RX In the likely case that probe_count is 0, don't write to the memory there. Also use ifmgd consistently in the function, instead of using sdata->u.mgd as well. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mlme.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 50f26a507664499ccef017607a29cc1456695343 Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Thu Mar 10 14:59:51 2016 -0800 i40e/i40evf: Bump patch from 1.4.25 to 1.5.1 Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ++-- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 55f7d7233bd15c8a3fcf7051c681b05de5980a18 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Thu Mar 10 14:59:50 2016 -0800 i40e: Change comment to reflect correct function name Minor correction in the comment to reflect the correct function name Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 19b73d8efaa459a66665b5e0a3e7acedd05f4901 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Thu Mar 10 14:59:49 2016 -0800 i40evf: Add additional check for reset If the driver happens to read a register during the time in which the device is undergoing reset, it will receive a value of 0xdeadbeef instead of a valid value. Unfortunately, the driver may misinterpret this as a valid value, especially if it's just looking for individual bits. Add an explicit check for this value when we are looking for admin queue errors, and trigger reset recovery if we find it. Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 ++ 1 file changed, 2 insertions(+) commit 56e5ca688f3d334ddc2acab27cb7efa83b238557 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Thu Mar 10 14:59:48 2016 -0800 i40e: Change unknown event error msg to ignore message There's no real error in an unknown event from the Firmware, we're just posting a useful FYI notice, so this patch simply removes the "Error" word. Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7e5a313ed9b18ba9f35df2523eb9e386a195a2c4 Author: Mitch Williams <mitch.a.williams@intel.com> Date: Thu Mar 10 14:59:47 2016 -0800 i40e: Added code to prevent double resets Clear the VFLR bit after reset processing, instead of before. This prevents double resets on VF init. Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) commit d3ce57344100023faa8f514eb66dfb110b53629c Author: Mitch Williams <mitch.a.williams@intel.com> Date: Thu Mar 10 14:59:46 2016 -0800 i40e: Notify VFs of all resets Notify VFs in the reset interrupt handler, instead of the actual reset initiation code. This allows the VFs to get properly notified for all resets, including resets initiated by different PFs on the same physical device. Signed-off-by: Mitch Williams <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c99abb4cb8227bf8172c085213c91bf155c6618a Author: Shannon Nelson <shannon.nelson@intel.com> Date: Thu Mar 10 14:59:45 2016 -0800 i40e: Remove timer and task only if created In some error scenarios, we may find ourselves trying to remove a non-existent timer or worktask. This causes the kernel some bit of consternation, so don't do it. Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 265bee7290fd68118e6eec3206d5632a097b59d8 Merge: 15f41e2 2bf9a58 Author: David S. Miller <davem@davemloft.net> Date: Tue Apr 5 15:07:55 2016 -0400 Merge branch 'mlxsw-next' Jiri Pirko says: ==================== mlxsw: small driver update, including switchdev doc update Ido Schimmel (3): mlxsw: spectrum: Reduce number of supported 802.1D bridges switchdev: Use switch ID in suggested udev rule mlxsw: spectrum: Add support for physical port names ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 2bf9a58675c5d6d37cdcb4301e6320009d299080 Author: Ido Schimmel <idosch@mellanox.com> Date: Tue Apr 5 10:20:04 2016 +0200 mlxsw: spectrum: Add support for physical port names Export to userspace the front panel name of the port, so that udev can rename the ports accordingly. The convention suggested by switchdev documentation is used: 1) Non-split: pX 2) Split: pXsY Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 45 ++++++++++++++++++++++++-- 1 file changed, 42 insertions(+), 3 deletions(-) commit 75f3a1018f0103025558caa60e24132a4cc9ce8f Author: Ido Schimmel <idosch@mellanox.com> Date: Tue Apr 5 10:20:03 2016 +0200 switchdev: Use switch ID in suggested udev rule Since there can be multiple switch ASICs on the same system we should use the switch ID in order to differentiate between them and set the switch name (e.g. swX) accordingly. Also, replace the order of the "Switch ID" and "Port Netdev Naming" sections following the above change. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/switchdev.txt | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) commit b555cf4a50c17a9714715a2d7c8574dca1a7b356 Author: Ido Schimmel <idosch@mellanox.com> Date: Tue Apr 5 10:20:02 2016 +0200 mlxsw: spectrum: Reduce number of supported 802.1D bridges Resources allocated for these bridges at init time cannot be later used for other purposes. While current number is supported by the device, it's mostly theoretical with regards to any real use case, which leads to poor utilization of device's resources. Solve that by reducing the number. The long term plan is to make this value (along with others) user configurable via devlink and write it to NVRAM, so that it can be used during the next init. Until then we must hardcode such values. Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/mellanox/mlxsw/spectrum.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 613c7c4003c8338a9a638485d95de2775948295b Author: Jose Abreu <Jose.Abreu@synopsys.com> Date: Tue Apr 5 18:08:02 2016 +0100 ASoC: dwc: Unmask I2S interrupts only for enabled channels There is no need to unmask all interrupts at I2S start. This can cause performance issues in slower platforms. Unmask only the interrupts for the used channels. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/dwc/designware_i2s.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 6fe9b67dbe5e0a0abeeabd428cb596b913995b36 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:54 2016 +0530 spi: cadence: Return the error code for cdns_spi_suspend and cdns_spi_resume Return the error code for cdns_spi_suspend and cdns_spi_resume. Also fixes a comment where which claims that the error code is returned. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 2198b7483d4a89cf2cc710045c76a76dba573ea5 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:53 2016 +0530 spi: cadence: Remove the clock enable and disable from suspend and resume Now that the clocks are enabled and disabled per transaction , remove the clock enable and disable from resume and suspend hooks. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 19 ------------------- 1 file changed, 19 deletions(-) commit d36ccd9f7ea41f343391a15677b8a858376e1107 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:52 2016 +0530 spi: cadence: Runtime pm adaptation Currently the clocks are enabled at probe and disabled at remove. This patch moves the clock enable to the start of transaction and disables at the end. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 70 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 68 insertions(+), 2 deletions(-) commit b4037360e66b90755ed73022976f10108bc82045 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:51 2016 +0530 spi: cadance: Fix the Documentation cdns_spi_chipselect has parameter is_high however the comment describes it as is_on. Also fixes the below warning. drivers/spi/spi-cadence.c:182: warning: No description found for parameter 'is_high' drivers/spi/spi-cadence.c:182: warning: Excess function parameter 'is_on' description in 'cdns_spi_chipselect' Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 50ac697baf0c83d5dd34d90acfcd8b83648c2d56 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:50 2016 +0530 spi: cadence: Fix probe error handling The clock disabling is missed out in some error cases at probe. Fix the same. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 24746675fbc8dcc09e10283ca0b3f038e58182e9 Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:49 2016 +0530 spi: cadence: Remove _MASK and _OFFSET suffix Remove the _MASK and _OFFSET from the macros. It improves readability, removes some checkpatch error for exceeding 80 chars and also prevents some linebreaks. Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 161 +++++++++++++++++++++------------------------- 1 file changed, 74 insertions(+), 87 deletions(-) commit 15a1c5030a1e0445af2e4eaa1535cccc8519d99c Author: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Date: Tue Apr 5 23:37:48 2016 +0530 spi: cadence: Fix a check patch warning CHECK: Comparison to NULL could be written "!master" + if (master == NULL) Signed-off-by: Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-cadence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fd786fb0276a22155058018f76eb4c665d37f170 Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Tue Apr 5 15:09:48 2016 +0530 regulator: pwm: Try to avoid voltage error in duty cycle calculation In continuous mode of the PWM regulators, the requested voltage PWM duty cycle is calculated in terms of 100% scale where entire range denotes 100%. The calculation for PWM pulse ON time(duty_pulse) is done as: duty_cycle = ((requested - minimum) * 100) / voltage_range. then duty pulse is calculated as duty_pulse = (pwm_period/100) * duty_cycle This leads to the calculation error if we have the requested voltage where accurate pulse time is possible. For example: Consider following case voltage range is 800000uV to 1350000uV. pwm-period = 1550ns (1ns time is 1mV). Requested 900000uV. duty_cycle = ((900000uV - 800000uV) * 100)/ 1550000 = 6.45 but we will get 6. duty_pulse = (1550/100) * 6 = 90 pulse time. 90 pulse time is equivalent to 90mV and this gives us pulse time equivalent to 890000uV instead of 900000uV. Proposing the solution in which if requested voltage makes the accurate duty pulse then there will not be any error. On this case, if (req_uV - min_uV) * pwm_period is perfect dividable by voltage_range then get the duty pulse time directly. duty_pulse = ((900000uV - 800000uV) * 1550)/1550000) = 100 and this is equivalent to 100mV and so final voltage is (800000 + 100000) = 900000uV which is same as requested, Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/pwm-regulator.c | 38 +++++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 15 deletions(-) commit 724fef53449d22ed41c99164aff7d7c3654603e2 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Apr 5 11:05:15 2016 +0900 regulator: max8997/max77802: Fix misspelled Samsung address Correct smasung.com into samsung.com. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/max77802-regulator.c | 2 +- drivers/regulator/max8997-regulator.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit a221f95ef4257a48c4f8cba8e804431ab66a359d Author: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Date: Tue Apr 5 08:59:34 2016 +0300 regulator: twl: Provide of_map_mode for twl4030 of_map_mode is needed so to be possible to set initial regulators mode from the board DTS. Otherwise, for DT boot, regulators are left in their default state after reset/reboot. Document device specific modes as well. Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../bindings/regulator/twl-regulator.txt | 6 ++++++ drivers/regulator/twl-regulator.c | 22 +++++++++++++++++++--- 2 files changed, 25 insertions(+), 3 deletions(-) commit 5fd9f52384935dacfdc4adb5cc3531a40346d475 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Mar 4 21:43:03 2016 +0200 drm/i915: Set GPU freq to idle_freq initially Currently we set the initial GPU frequency to min_freq_softlimit on gen9, and to efficient_freq on VLV/CHV. On all the other platforms we set it to idle_freq. Let's use idle_freq across the board to make sure we don't waste power. This is especially relevant for VLV since Vnn won't drop to minimum unless the GPU is at the minimum frequency. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457120584-26080-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_pm.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit c30fec656d1336a453bd4cb769a7c5e5c577e3b1 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Fri Mar 4 21:43:02 2016 +0200 drm/i915: Use GPLL ref clock to calculate GPU freqs on VLV/CHV Extract the GPLL reference frequency from CCK and use it in the GPU freq<->opcode conversions on VLV/CHV. This eliminates all the assumptions we have about which divider is used for which czclk frequency. Note that unlike most clocks from CCK, the GPLL ref clock is a divided down version of the CZ clock rather than the HPLL clock. CZ clock itself is a divided down version of the HPLL clock though, so in effect it just gets divided down twice. While at it, throw in a few comments explaining the remaining constants for anyone who later wants to compare this to the spreadsheets. v2: Add slow/fast notes for CHV clocks (Imre) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457120584-26080-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> (v1) drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_display.c | 19 ++++++--- drivers/gpu/drm/i915/intel_drv.h | 2 + drivers/gpu/drm/i915/intel_pm.c | 74 +++++++++++++----------------------- 5 files changed, 44 insertions(+), 53 deletions(-) commit 08922f644878c9163ada8df3ef9def89be1d5e90 Author: Vignesh R <vigneshr@ti.com> Date: Tue Mar 29 11:16:17 2016 +0530 mtd: devices: m25p80: add support for mmap read request Certain SPI controllers may provide accelerated hardware interface to read from m25p80 type flash devices in order to provide better read performance. SPI core supports such devices with spi_flash_read() API. Call spi_flash_read(), if supported, to make use of such interface. Signed-off-by: Vignesh R <vigneshr@ti.com> [Brian: add memset()] Signed-off-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/devices/m25p80.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) commit 20aa787e453faec948ad75ebaa1535dbd5adb271 Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Thu Jan 7 17:28:06 2016 -0800 Input: ti_am335x_tsc - use SIMPLE_DEV_PM_OPS Instead of doing the dance with macro that either resolves to a pointer or NULL, let's switch to using SIMPLE_DEV_PM_OPS(). Also let's mark suspend and resume methods as __maybe_unused instead of guarding them with an #ifdef and rely on linker to drop unused code. Doing so should allow better compile coverage. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/touchscreen/ti_am335x_tsc.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) commit b5ca3ea327a6467591751e4c98207281fe884da3 Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Thu Jan 7 22:33:49 2016 -0800 Input: omap-keypad - remove set_col_gpio_val() and get_row_gpio_val() Commit f799a3d8fe170159257b75c1baf48a7c1f625d1d ("Input: omap-keypad: Remove dependencies to mach includes") removed users of the above functions, but left them in the code. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/keyboard/omap-keypad.c | 25 ------------------------- 1 file changed, 25 deletions(-) commit a56f9235c9702544319f8ea0ce0c3aefed23d153 Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Thu Jan 7 22:16:35 2016 -0800 Input: omap-keypad - drop empty PM stubs There is no reason to have empty suspend and resume stubs. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/keyboard/omap-keypad.c | 21 --------------------- 1 file changed, 21 deletions(-) commit 94016680737fd5f9dcfac3fe65b2e61d38fcfba6 Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Thu Jan 7 22:25:39 2016 -0800 Input: omap-keypad - remove adjusting of scan delay As of 35f8679f577ae5673a778598bcbe7b45cbec8923 ("Input: omap-keypad - remove dead check") we no longer declare keypresses as spurious, therefore we can use constant delay between scans. Suggested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/keyboard/omap-keypad.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit dcbb408ac5a2803ba44ca2fae8bf53eb5d4082f3 Author: Colin Ian King <colin.king@canonical.com> Date: Tue Apr 5 12:12:45 2016 -0500 PCI: Fix spelling errors Fix spelling of "initalization". [bhelgaas: also fix pci/pci.c] Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> drivers/pci/host/pcie-xilinx-nwl.c | 2 +- drivers/pci/pci.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 611526756a3d0fa7f4d1c519397ba8898f40443f Author: Abhi Das <adas@redhat.com> Date: Tue Apr 5 12:06:15 2016 -0400 gfs2: Use gfs2 wrapper to sync inode before calling generic_file_splice_read() gfs2_file_splice_read() f_op grabs and releases the cluster-wide inode glock to sync the inode size to the latest. Without this, generic_file_splice_read() uses an older i_size value and can return EOF for valid offsets in the inode. Signed-off-by: Abhi Das <adas@redhat.com> Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/file.c | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) commit 73cc86252bd8a547349d2856497eceaf4f2d1766 Author: Bob Peterson <rpeterso@redhat.com> Date: Fri Apr 1 13:18:38 2016 -0400 GFS2: Get rid of dead code in inode_go_demote_ok Function inode_go_demote_ok had some code that was only executed if gl_holders was not empty. However, if gl_holders was not empty, the only caller, demote_ok(), returns before inode_go_demote_ok would ever be called. Therefore, it's dead code, so I removed it. Signed-off-by: Bob Peterson <rpeterso@redhat.com> Acked-by: Steven Whitehouse <swhiteho@redhat.com> fs/gfs2/glops.c | 7 ------- 1 file changed, 7 deletions(-) commit a5c0e0b4ac07434056c5c4ecafeb9a5cff3d1a9d Author: Suman Anna <s-anna@ti.com> Date: Mon Apr 4 17:46:21 2016 -0500 iommu/omap: Align code with open parenthesis This patch fixes one existing alignment checkpatch check warning of the type "Alignment should match open parenthesis" in the OMAP IOMMU debug source file. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/omap-iommu-debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 433c434a269e6a39753f0a97b4be903f96d030a9 Author: Suman Anna <s-anna@ti.com> Date: Mon Apr 4 17:46:20 2016 -0500 iommu/omap: Use WARN_ON for page table alignment check The OMAP IOMMU page table needs to be aligned on a 16K boundary, and the current code uses a BUG_ON on the alignment sanity check in the .domain_alloc() ops implementation. Replace this with a less severe WARN_ON and bail out gracefully. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/omap-iommu.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 7c1ab60008755fc229b623a875f1e42de31cdb64 Author: Suman Anna <s-anna@ti.com> Date: Mon Apr 4 17:46:19 2016 -0500 iommu/omap: Replace BUG() in iopgtable_store_entry_core() The iopgtable_store_entry_core() function uses a BUG() statement for an unsupported page size entry programming. Replace this with a less severe WARN_ON() and perform a graceful bailout on error. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/omap-iommu.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 521f40823ebf2818045546d45aa378eba1c41717 Author: Suman Anna <s-anna@ti.com> Date: Mon Apr 4 17:46:18 2016 -0500 iommu/omap: Remove iopgtable_clear_entry_all() from driver remove The function iopgtable_clear_entry_all() is used for clearing all the page table entries. These entries are neither created nor initialized during the OMAP IOMMU driver probe, and are managed only when a client device attaches to the IOMMU. So, there is no need to invoke this function on a driver remove. Removing this fixes a NULL pointer dereference crash if the IOMMU device is unbound from the driver with no client device attached to the IOMMU device. Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/omap-iommu.c | 1 - 1 file changed, 1 deletion(-) commit a0e637387a9858f9c2e8228bc15e299387dadcd1 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:38 2016 -0400 gpio: tps6586x: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_TPS6586X drivers/gpio/Kconfig: bool "TPS6586X GPIO" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Laxman Dewangan <ldewangan@nvidia.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tps6586x.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 02c7a13eabd85103167a822d470743b640120e7d Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:37 2016 -0400 gpio: tps65910: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_TPS65910 drivers/gpio/Kconfig: bool "TPS65910 GPIO" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Graeme Gregory <gg@slimlogic.co.uk> Cc: Jorge Eduardo Candelaria <jedu@slimlogic.co.uk> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tps65910.c | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) commit f9f2b5cba71e51998e60b7cebba0413e5bf4d1f0 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:36 2016 -0400 gpio: palmas: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_PALMAS drivers/gpio/Kconfig: bool "TI PALMAS series PMICs GPIO" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Laxman Dewangan <ldewangan@nvidia.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-palmas.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) commit 24a876cef408eae8bad4f7d74f38dc1a2d919bcc Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:35 2016 -0400 gpio: sx150x: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_SX150X drivers/gpio/Kconfig: bool "Semtech SX150x I2C GPIO expander" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Gregory Bean <gbean@codeaurora.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-sx150x.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) commit 8513334115c818ef2bddbca5d2e6dd52c994ce19 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:34 2016 -0400 gpio: tc3589x: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_TC3589X drivers/gpio/Kconfig: bool "TC3589X GPIOs" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Rabin Vincent <rabin.vincent@stericsson.com> Cc: Hanumath Prasad <hanumath.prasad@stericsson.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tc3589x.c | 11 ----------- 1 file changed, 11 deletions(-) commit fe7b778802593ccb1cae859553be912a2a1ef412 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Fri Apr 1 14:49:33 2016 -0400 gpio: rc5t583: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_RC5T583 drivers/gpio/Kconfig: bool "RICOH RC5T583 GPIO" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init was not in use by this code, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Laxman Dewangan <ldewangan@nvidia.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-rc5t583.c | 12 ------------ 1 file changed, 12 deletions(-) commit 8b866b0682c5de249afed3f7cb23c8421bc735b0 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 5 15:11:11 2016 +0200 gpio: tc3589x: implement open drain/source callback This makes use of the new .set_single_ended() callback to set the GPIO line as open drain/open source using hardware. The TC3589x can do this by either disabling the N-MOS transistor (open drain) or the P-MOS transistor (open source) of the output driver stage, in the first case making the signal drive actively low and high impedance as "high" and in the second case actively high and high impedance, which is as close to native open drain support as we come. Cc: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tc3589x.c | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit 3d1a2442d2c08c872150db7a554647c06f6e864f Author: Michael S. Tsirkin <mst@redhat.com> Date: Wed Mar 23 20:34:19 2016 +0200 x86/vt-d: Fix comment for dma_pte_free_pagetable() dma_pte_free_pagetable no longer depends on last level ptes being clear, it clears them itself. Fix up the comment to match. Cc: Jiang Liu <jiang.liu@linux.intel.com> Suggested-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/intel-iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cee1b40d96f1b49e9a1b38e2d57d37a2c20ced31 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Apr 5 15:09:09 2016 +0200 gpio: tc3589x: use BIT() macro This switch to use BIT(n) instead of (1 << n) which is less to the point. Most GPIO drivers do this to avoid mistakes. Also switch from using <linux/gpio.h> to the apropriate <linux/gpio/driver.h> include. Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tc3589x.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit c663e5f56737757db4d0b317c510ab505f93cecb Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Mar 22 10:51:16 2016 +0100 gpio: support native single-ended hardware drivers Some GPIO controllers has a special hardware bit we can flip to support open drain / source. This means that on these hardwares we do not need to emulate OD/OS by setting the line to input instead of actively driving it high/low. Add an optional vtable callback to the driver set_single_ended() so that driver can implement this in hardware if they have it. We may need a pinctrl_gpio_set_config() call at some point to propagate this down to a backing pin control device on systems with split GPIO/pin control. Reported-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpiolib.c | 52 ++++++++++++++++++++++++++++++++------------- include/linux/gpio/driver.h | 25 +++++++++++++++++++++- 2 files changed, 61 insertions(+), 16 deletions(-) commit 8d7f2d84ed2d44b05e1ce88fa4b74886af46a139 Author: Tomeu Vizoso <tomeu.vizoso@collabora.com> Date: Mon Mar 21 12:00:23 2016 +0100 iommu/rockchip: Don't feed NULL res pointers to devres If we do, devres prints a "invalid resource" string in the error loglevel. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/rockchip-iommu.c | 2 ++ 1 file changed, 2 insertions(+) commit a0fe14d7dcf5db2f101b4fe8689ecabb255ab7d3 Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 17 14:12:31 2016 -0600 iommu/vt-d: Improve fault handler error messages Remove new line in error logs, avoid duplicate and explicit pr_fmt. Suggested-by: Joe Perches <joe@perches.com> Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Fixes: 0ac2491f57af ('x86, dmar: move page fault handling code to dmar.c') Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/dmar.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit c43fce4eebae257ca413733690e2076757282093 Author: Alex Williamson <alex.williamson@redhat.com> Date: Thu Mar 17 14:12:25 2016 -0600 iommu/vt-d: Ratelimit fault handler Fault rates can easily overwhelm the console and make the system unresponsive. Ratelimit to allow an opportunity for maintenance. Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Fixes: 0ac2491f57af ('x86, dmar: move page fault handling code to dmar.c') Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/dmar.c | 33 ++++++++++++++++++++++----------- 1 file changed, 22 insertions(+), 11 deletions(-) commit 01e23c93868884327828a01e864135f05e515ae5 Author: Yong Wu <yong.wu@mediatek.com> Date: Mon Mar 14 06:01:11 2016 +0800 iommu/mediatek: Add 4GB mode support This patch add 4GB mode support for m4u. Signed-off-by: Yong Wu <yong.wu@mediatek.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/mtk_iommu.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 1afe23194d0580bc332fe27c4e8717f6562348c5 Author: Yong Wu <yong.wu@mediatek.com> Date: Mon Mar 14 06:01:10 2016 +0800 iommu/io-pgtable: Add MTK 4GB mode in Short-descriptor In MT8173, Normally the first 1GB PA is for the HW SRAM and Regs, so the PA will be 33bits if the dram size is 4GB. We have a "DRAM 4GB mode" toggle bit for this. If it's enabled, from CPU's point of view, the dram PA will be from 0x1_00000000~0x1_ffffffff. In short descriptor, the pagetable descriptor is always 32bit. Mediatek extend bit9 in the lvl1 and lvl2 pgtable descriptor as the 4GB mode. In the 4GB mode, the bit9 must be set, then M4U help add 0x1_00000000 based on the PA in pagetable. Thus the M4U output address to EMI is always 33bits(the input address is still 32bits). We add a special quirk for this MTK-4GB mode. And in the standard spec, Bit9 in the lvl1 is "IMPLEMENTATION DEFINED", while it's AP[2] in the lvl2, therefore if this quirk is enabled, NO_PERMS is also expected. Signed-off-by: Yong Wu <yong.wu@mediatek.com> Reviewed-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/io-pgtable-arm-v7s.c | 13 ++++++++++++- drivers/iommu/io-pgtable.h | 6 ++++++ 2 files changed, 18 insertions(+), 1 deletion(-) commit 54c6d242fa32cba8313936e3a35f27dc2c7c3e04 Author: Cosmin-Gabriel Samoila <gabrielcsmo@gmail.com> Date: Sun Mar 13 02:17:27 2016 +0200 iommu/io-pgtable: Fix a brace coding style issue. Fixed a coding style issue. Signed-off-by: Cosmin-Gabriel Samoila <gabrielcsmo@gmail.com> Signed-off-by: Joerg Roedel <jroedel@suse.de> drivers/iommu/io-pgtable.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 605aa5e48bfc3dbf0272bc4aac8674e06c19c1b3 Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Feb 26 15:48:38 2016 +0000 dt-bindings: Update NVIDIA PMC for Tegra Add the PMC driver compatible strings for Tegra132 and Tegra210. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Thierry Reding <treding@nvidia.com> .../devicetree/bindings/arm/tegra/nvidia,tegra20-pmc.txt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 0a2d87e0473fc5eea3f8168f5a24a35e4cf3f29c Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Feb 26 15:48:40 2016 +0000 soc/tegra: pmc: Wait for powergate state to change Currently, the function tegra_powergate_set() simply sets the desired powergate state but does not wait for the state to change. In most cases we should wait for the state to change before proceeding. Currently, there is a case for Tegra114 and Tegra124 devices where we do not wait when starting the secondary CPU as this is not necessary. However, this is only done at boot time and so waiting here will only have a small impact on boot time. Therefore, update tegra_powergate_set() to wait when setting the powergate. By adding this feature, we can also eliminate the polling loop from tegra30_boot_secondary(). A function has been added for checking the status of the powergate and so update the tegra_powergate_is_powered() to use this macro as well. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> arch/arm/mach-tegra/platsmp.c | 16 +++------------- drivers/soc/tegra/pmc.c | 9 ++++++++- 2 files changed, 11 insertions(+), 14 deletions(-) commit bc9af23d314f5c846e66e9425b31df2815ef1763 Author: Jon Hunter <jonathanh@nvidia.com> Date: Mon Feb 15 12:38:11 2016 +0000 soc/tegra: pmc: Ensure GPU partition can be toggled on/off by PMC For Tegra124 and Tegra210, the GPU partition cannot be toggled on and off via the APBDEV_PMC_PWRGATE_TOGGLE_0 register. For these devices, the partition is simply powered up and down via an external regulator. For these devices, there is a separate register for controlling the signal clamping of the partition and this is described in the PMC SoC data by the "has_gpu_clamp" variable. Use this variable to determine if the GPU partition can be controlled via the APBDEV_PMC_PWRGATE_TOGGLE_0 register and ensure that no one can incorrectly try to toggle the GPU partition via the APBDEV_PMC_PWRGATE_TOGGLE_0 register. Furthermore, we cannot use the APBDEV_PMC_PWRGATE_STATUS_0 register to determine if the GPU partition is powered for Tegra124 and Tegra210. However, if the GPU partition is powered, then the signal clamp for the GPU partition should be removed and so use bit 0 of the APBDEV_PMC_GPU_RG_CNTRL_0 register to determine if the clamp has been removed (bit[0] = 0) and the GPU partition is powered. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit c3ea297260b77a99a2383c1029a381d125f788fe Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:25 2016 +0000 soc/tegra: pmc: Remove additional check for a valid partition The function tegra_powergate_is_powered() verifies that the partition being queried is valid and so there is no need to check this before calling tegra_powergate_is_powered() in powergate_show(). So remove this extra check. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 0a243bd438ce3d44e03140adf58df4df11dce978 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:24 2016 +0000 soc/tegra: pmc: Fix verification of valid partitions The Tegra power partitions are referenced by numerical IDs which are the same values programmed into the PMC registers for controlling the partition. For a given device, the valid partition IDs may not be contiguous and so simply checking that an ID is not greater than the maximum ID supported may not mean it is valid. Fix this by checking if the powergate is defined in the list of powergates for the Tegra SoC. Add a helper function for checking valid powergates and use where we need to verify if the powergate ID is valid or not. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) commit 0ecf2d33bb4686b5d8f06b3b18877de0d88d3af4 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:23 2016 +0000 soc/tegra: pmc: Fix testing of powergate state In tegra_powergate_set() the state of the powergates is read and OR'ed with the bit for the powergate of interest. This unsigned 32-bit value is then compared with a boolean value to test if the powergate is already in the desired state. When turning on a powergate, apart from the powergate that is represented by bit 0, this test will always return false and so we may attempt to turn on the powergate when it is already on. After OR'ing the bit for the powergate, check if the result is not equal to zero before comparing with the boolean value. Add a helper function to return the current state of a powergate and use this in both tegra_powergate_set() and tegra_powergate_is_powered() where we check the powergate status. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit 70293ed09decd1ec4ae5632af27cab73c16a50ba Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:22 2016 +0000 soc/tegra: pmc: Change powergate and rail IDs to be an unsigned type The Tegra powergate and rail IDs are always positive values and so change the type to be unsigned and remove the tests to see if the ID is less than zero. Update the Tegra DC powergate type to be an unsigned as well. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/gpu/drm/tegra/drm.h | 2 +- drivers/soc/tegra/pmc.c | 36 ++++++++++++++++++------------------ include/soc/tegra/pmc.h | 35 ++++++++++++++++++----------------- 3 files changed, 37 insertions(+), 36 deletions(-) commit e8cf6616a346029fe3e3931dd34fc589fade4b6e Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:21 2016 +0000 soc/tegra: pmc: Protect public functions from potential race conditions The PMC base address pointer is initialised during early boot so that early platform code may used the PMC public functions. During the probe of the PMC driver the base address pointer is mapped again and the initial mapping is freed. This exposes a window where a device accessing the PMC registers via one of the public functions, could race with the updating of the pointer and lead to a invalid access. Furthermore, the only protection between multiple devices attempting to access the PMC registers is when setting the powergate state to on or off. None of the other public functions that access the PMC registers are protected. Use the existing mutex to protect paths that may race with regard to accessing the PMC registers. Note that functions tegra_io_rail_prepare()/poll() either return a negative value on failure or zero on success. Therefore, it is not necessary to check if the return value is less than zero and so only test that the return value is not zero to test for failure. This simplifies the error handling with the mutex locking in place. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 47 +++++++++++++++++++++++++++++++++-------------- 1 file changed, 33 insertions(+), 14 deletions(-) commit 0259f522e04f19b433a4dc7586d80da106afbbcc Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:20 2016 +0000 soc/tegra: pmc: Restore base address on probe failure During early initialisation, the PMC registers are mapped and the PMC SoC data is populated in the PMC data structure. This allows other drivers access the PMC register space, via the public Tegra PMC APIs, prior to probing the PMC device. When the PMC device is probed, the PMC registers are mapped again and if successful the initial mapping is freed. If the probing of the PMC device fails after the registers are remapped, then the registers will be unmapped and hence the pointer to the PMC registers will be invalid. This could lead to a potential crash, because once the PMC SoC data pointer is populated, the driver assumes that the PMC register mapping is also valid and a user calling any of the public Tegra PMC APIs could trigger an exception because these APIs don't check that the mapping is still valid. Fix this by updating the mapping and freeing the original mapping only if probing the PMC device is successful. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) commit 668419afe65c146e115897e8fef6ca23c48bf121 Author: Jon Hunter <jonathanh@nvidia.com> Date: Thu Feb 11 18:03:19 2016 +0000 soc/tegra: pmc: Remove non-existing L2 partition for Tegra124 Tegra124 does not have an L2 power partition and the L2 cache is part of the cluster 0 non-CPU (CONC) partition. Remove the L2 as a valid partition for Tegra124. The TRM also shows that there is no L2 partition for Tegra124. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 1 - 1 file changed, 1 deletion(-) commit e8de5b81ff930a95f1a45e6feb3df278ee9850ae Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Dec 4 14:57:08 2015 +0000 soc/tegra: pmc: Remove non-existing power partitions for Tegra210 The power partitions L2, HEG, CELP and C1NC do not exist on Tegra210 but were incorrectly documented in the TRM. These will be removed from the TRM and so also remove their definitions. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 4 ---- 1 file changed, 4 deletions(-) commit 3195ac6d9cbeef23631913d67f8c1e76b891da4d Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Dec 4 14:57:05 2015 +0000 soc/tegra: pmc: Remove debugfs entry on probe failure The debugfs entry for the PMC device will not be removed if the probe of the device fails to register the restart handler. This leaves behind the dangling debugfs entry with no driver backing it. Remove the entry to avoid this. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) commit 1e52efdfc6a29f9bad767b92b89ae6ae772063cc Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Dec 4 14:57:04 2015 +0000 soc/tegra: pmc: Fix sparse warning for tegra_pmc_init_tsense_reset() Sparse reports the following warning for tegra_pmc_init_tsense_reset(): drivers/soc/tegra/pmc.c:741:6: warning: symbol 'tegra_pmc_init_tsense_reset' was not declared. Should it be static? This function is only used internally by the PMC driver and so fix this by making it static. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 35b67291b4a85d37ec31f9d9ea3c5d3258ee0da6 Author: Jon Hunter <jonathanh@nvidia.com> Date: Fri Dec 4 14:57:03 2015 +0000 soc/tegra: pmc: Add missing structure members to kernel-doc Some members of the tegra_pmc structure are missing from the kernel-doc comment for this structure. Add the missing members. Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/soc/tegra/pmc.c | 2 ++ 1 file changed, 2 insertions(+) commit 043809d8d25eac8307c8c7b74bca7266070cb007 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Apr 5 11:04:28 2016 +0900 hwrng: exynos - Fix misspelled Samsung address Correct smasung.com into samsung.com. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/exynos-rng.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f1420ceef3011547323733e3bb4fcb4aca3fe840 Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Tue Mar 29 10:21:07 2016 -0700 crypto: qat - changed adf_dev_stop to void It returns always zero anyway. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_c3xxx/adf_drv.c | 4 +--- drivers/crypto/qat/qat_c3xxxvf/adf_drv.c | 4 +--- drivers/crypto/qat/qat_c62x/adf_drv.c | 4 +--- drivers/crypto/qat/qat_c62xvf/adf_drv.c | 4 +--- drivers/crypto/qat/qat_common/adf_common_drv.h | 2 +- drivers/crypto/qat/qat_common/adf_ctl_drv.c | 18 ++++-------------- drivers/crypto/qat/qat_common/adf_init.c | 12 +++++------- drivers/crypto/qat/qat_common/adf_sriov.c | 8 +------- drivers/crypto/qat/qat_dh895xcc/adf_drv.c | 4 +--- drivers/crypto/qat/qat_dh895xccvf/adf_drv.c | 4 +--- 10 files changed, 17 insertions(+), 47 deletions(-) commit cb00bca42f8b819498b2647f24b6148d65ec9aa4 Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Tue Mar 29 10:20:52 2016 -0700 crypto: qat - explicitly stop all VFs first When stopping devices it is not enought to loop backwards. We need to explicitly stop all VFs first. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_ctl_drv.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) commit 4218ebe8cab421c72f134cca1374e0985303f34a Author: Stephan Mueller <smueller@chronox.de> Date: Mon Mar 28 16:47:55 2016 +0200 crypto: drbg - set HMAC key only when altered The HMAC implementation allows setting the HMAC key independently from the hashing operation. Therefore, the key only needs to be set when a new key is generated. This patch increases the speed of the HMAC DRBG by at least 35% depending on the use case. The patch is fully CAVS tested. Signed-off-by: Stephan Mueller <smueller@chronox.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> crypto/drbg.c | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) commit bdb6cf9f6fe6d9af905ea34b7c4bb78ea601329e Author: Corentin LABBE <clabbe.montjoie@gmail.com> Date: Wed Mar 23 16:11:24 2016 +0100 crypto: sun4i-ss - Replace spinlock_bh by spin_lock_irq{save|restore} The current sun4i-ss driver could generate data corruption when ciphering/deciphering. It occurs randomly on end of handled data. No root cause have been found and the only way to remove it is to replace all spin_lock_bh by their irq counterparts. Fixes: 6298e948215f ("crypto: sunxi-ss - Add Allwinner Security System crypto accelerator") Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/sunxi-ss/sun4i-ss-cipher.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 738f98233b94db55607f97a76f9699efc4217276 Author: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Date: Wed Mar 23 17:06:40 2016 +0200 crypto: qat - fix address leaking of RSA public exponent Signed-off-by: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/qat_asym_algs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa8b6dd4b06bab62ec7f8972f9e66782dbc23d60 Author: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Date: Wed Mar 23 17:06:39 2016 +0200 crypto: qat - avoid memory corruption or undefined behaviour memcopying to a (null pointer + offset) will result in memory corruption or undefined behaviour. Signed-off-by: Tudor Ambarus <tudor-dan.ambarus@nxp.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/qat_asym_algs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0c4935b31df0e5ffa6da0f8a2fdfc690d1118ba7 Author: Ahsan Atta <ahsan.atta@intel.com> Date: Tue Mar 22 11:25:21 2016 -0700 crypto: qat - Remove redundant nrbg rings Remove redundant nrbg rings. Signed-off-by: Ahsan Atta <ahsan.atta@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_cfg_strings.h | 2 -- 1 file changed, 2 deletions(-) commit 082ebe92ca7f09845f0550e85837a878d6cedb34 Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Tue Mar 22 10:45:25 2016 -0700 crypto: qat - make sure const_tab is 1024 bytes aligned FW requires the const_tab to be 1024 bytes aligned. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/qat/qat_common/adf_admin.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0bb5c9ead62f4e1eaf226744076e0b4e8348f68f Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:18:16 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): fix out-of-bounds buffer access Within the copying loop in mpi_read_raw_from_sgl(), the last input SGE's byte count gets artificially extended as follows: if (sg_is_last(sg) && (len % BYTES_PER_MPI_LIMB)) len += BYTES_PER_MPI_LIMB - (len % BYTES_PER_MPI_LIMB); Within the following byte copying loop, this causes reads beyond that SGE's allocated buffer: BUG: KASAN: slab-out-of-bounds in mpi_read_raw_from_sgl+0x331/0x650 at addr ffff8801e168d4d8 Read of size 1 by task systemd-udevd/721 [...] Call Trace: [<ffffffff818c4d35>] dump_stack+0xbc/0x117 [<ffffffff818c4c79>] ? _atomic_dec_and_lock+0x169/0x169 [<ffffffff814af5d1>] ? print_section+0x61/0xb0 [<ffffffff814b1109>] print_trailer+0x179/0x2c0 [<ffffffff814bc524>] object_err+0x34/0x40 [<ffffffff814bfdc7>] kasan_report_error+0x307/0x8c0 [<ffffffff814bf315>] ? kasan_unpoison_shadow+0x35/0x50 [<ffffffff814bf38e>] ? kasan_kmalloc+0x5e/0x70 [<ffffffff814c0ad1>] kasan_report+0x71/0xa0 [<ffffffff81938171>] ? mpi_read_raw_from_sgl+0x331/0x650 [<ffffffff814bf1a6>] __asan_load1+0x46/0x50 [<ffffffff81938171>] mpi_read_raw_from_sgl+0x331/0x650 [<ffffffff817f41b6>] rsa_verify+0x106/0x260 [<ffffffff817f40b0>] ? rsa_set_pub_key+0xf0/0xf0 [<ffffffff818edc79>] ? sg_init_table+0x29/0x50 [<ffffffff817f4d22>] ? pkcs1pad_sg_set_buf+0xb2/0x2e0 [<ffffffff817f5b74>] pkcs1pad_verify+0x1f4/0x2b0 [<ffffffff81831057>] public_key_verify_signature+0x3a7/0x5e0 [<ffffffff81830cb0>] ? public_key_describe+0x80/0x80 [<ffffffff817830f0>] ? keyring_search_aux+0x150/0x150 [<ffffffff818334a4>] ? x509_request_asymmetric_key+0x114/0x370 [<ffffffff814b83f0>] ? kfree+0x220/0x370 [<ffffffff818312c2>] public_key_verify_signature_2+0x32/0x50 [<ffffffff81830b5c>] verify_signature+0x7c/0xb0 [<ffffffff81835d0c>] pkcs7_validate_trust+0x42c/0x5f0 [<ffffffff813c391a>] system_verify_data+0xca/0x170 [<ffffffff813c3850>] ? top_trace_array+0x9b/0x9b [<ffffffff81510b29>] ? __vfs_read+0x279/0x3d0 [<ffffffff8129372f>] mod_verify_sig+0x1ff/0x290 [...] The exact purpose of the len extension isn't clear to me, but due to its form, I suspect that it's a leftover somehow accounting for leading zero bytes within the most significant output limb. Note however that without that len adjustement, the total number of bytes ever processed by the inner loop equals nbytes and thus, the last output limb gets written at this point. Thus the net effect of the len adjustement cited above is just to keep the inner loop running for some more iterations, namely < BYTES_PER_MPI_LIMB ones, reading some extra bytes from beyond the last SGE's buffer and discarding them afterwards. Fix this issue by purging the extension of len beyond the last input SGE's buffer length. Fixes: 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 3 --- 1 file changed, 3 deletions(-) commit 85d541a3d14ab7a4e08c280740d9a7e097b04835 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:18:07 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): sanitize meaning of indices Within the byte reading loop in mpi_read_raw_sgl(), there are two housekeeping indices used, z and x. At all times, the index z represents the number of output bytes covered by the input SGEs for which processing has completed so far. This includes any leading zero bytes within the most significant limb. The index x changes its meaning after the first outer loop's iteration though: while processing the first input SGE, it represents "number of leading zero bytes in most significant output limb" + "current position within current SGE" For the remaining SGEs OTOH, x corresponds just to "current position within current SGE" After all, it is only the sum of z and x that has any meaning for the output buffer and thus, the "number of leading zero bytes in most significant output limb" part can be moved away from x into z from the beginning, opening up the opportunity for cleaner code. Before the outer loop iterating over the SGEs, don't initialize z with zero, but with the number of leading zero bytes in the most significant output limb. For the inner loop iterating over a single SGE's bytes, get rid of the buf_shift offset to x' bounds and let x run from zero to sg->length - 1. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 64c09b0b59b92ad231dd526f57f24139b728044b Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:17:27 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): fix nbits calculation The number of bits, nbits, is calculated in mpi_read_raw_from_sgl() as follows: nbits = nbytes * 8; Afterwards, the number of leading zero bits of the first byte get subtracted: nbits -= count_leading_zeros(*(u8 *)(sg_virt(sgl) + lzeros)); However, count_leading_zeros() takes an unsigned long and thus, the u8 gets promoted to an unsigned long. Thus, the above doesn't subtract the number of leading zeros in the most significant nonzero input byte from nbits, but the number of leading zeros of the most significant nonzero input byte promoted to unsigned long, i.e. BITS_PER_LONG - 8 too many. Fix this by subtracting count_leading_zeros(...) - (BITS_PER_LONG - 8) from nbits only. Fixes: 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 60e1b74c224e9eda14e5b479413c5d990373c2cb Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:45 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): purge redundant clearing of nbits In mpi_read_raw_from_sgl(), unsigned nbits is calculated as follows: nbits = nbytes * 8; and redundantly cleared later on if nbytes == 0: if (nbytes > 0) ... else nbits = 0; Purge this redundant clearing for the sake of clarity. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 2 -- 1 file changed, 2 deletions(-) commit ab1e912ec1021e7532148398a01eb1283437fe62 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:44 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): don't include leading zero SGEs in nbytes At the very beginning of mpi_read_raw_from_sgl(), the leading zeros of the input scatterlist are counted: lzeros = 0; for_each_sg(sgl, sg, ents, i) { ... if (/* sg contains nonzero bytes */) break; /* sg contains nothing but zeros here */ ents--; lzeros = 0; } Later on, the total number of trailing nonzero bytes is calculated by subtracting the number of leading zero bytes from the total number of input bytes: nbytes -= lzeros; However, since lzeros gets reset to zero for each completely zero leading sg in the loop above, it doesn't include those. Besides wasting resources by allocating a too large output buffer, this mistake propagates into the calculation of x, the number of leading zeros within the most significant output limb: x = BYTES_PER_MPI_LIMB - nbytes % BYTES_PER_MPI_LIMB; What's more, the low order bytes of the output, equal in number to the extra bytes in nbytes, are left uninitialized. Fix this by adjusting nbytes for each completely zero leading scatterlist entry. Fixes: 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit b698538951a45dd853d9e40f51e143fdd46a60c6 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:43 2016 +0100 lib/mpi: mpi_read_raw_from_sgl(): replace len argument by nbytes Currently, the nbytes local variable is calculated from the len argument as follows: ... mpi_read_raw_from_sgl(..., unsigned int len) { unsigned nbytes; ... if (!ents) nbytes = 0; else nbytes = len - lzeros; ... } Given that nbytes is derived from len in a trivial way and that the len argument is shadowed by a local len variable in several loops, this is just confusing. Rename the len argument to nbytes and get rid of the nbytes local variable. Do the nbytes calculation in place. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 462696fd0fd2aae2fd38d22d19b2d08a55606014 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:42 2016 +0100 lib/mpi: mpi_read_buffer(): fix buffer overflow Currently, mpi_read_buffer() writes full limbs to the output buffer and moves memory around to purge leading zero limbs afterwards. However, with commit 9cbe21d8f89d ("lib/mpi: only require buffers as big as needed for the integer") the caller is only required to provide a buffer large enough to hold the result without the leading zeros. This might result in a buffer overflow for small MP numbers with leading zeros. Fix this by coping the result to its final destination within the output buffer and not copying the leading zeros at all. Fixes: 9cbe21d8f89d ("lib/mpi: only require buffers as big as needed for the integer") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit 90f864e20029600a8dc33e27b1192af4636100d4 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:41 2016 +0100 lib/mpi: mpi_read_buffer(): replace open coded endian conversion Currently, the endian conversion from CPU order to BE is open coded in mpi_read_buffer(). Replace this by the centrally provided cpu_to_be*() macros. Copy from the temporary storage on stack to the destination buffer by means of memcpy(). Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) commit f00fa2417b3e1252b1a761f88731af03afff4407 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:40 2016 +0100 lib/mpi: mpi_read_buffer(): optimize skipping of leading zero limbs Currently, if the number of leading zeros is greater than fits into a complete limb, mpi_read_buffer() skips them by iterating over them limb-wise. Instead of skipping the high order zero limbs within the loop as shown above, adjust the copying loop's bounds. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) commit d755290689646fa66cc4830ca55569f2c9863666 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:39 2016 +0100 lib/mpi: mpi_write_sgl(): replace open coded endian conversion Currently, the endian conversion from CPU order to BE is open coded in mpi_write_sgl(). Replace this by the centrally provided cpu_to_be*() macros. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) commit cece762f6f3cb1c1687f467e98faef21b0096600 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:38 2016 +0100 lib/mpi: mpi_write_sgl(): fix out-of-bounds stack access Within the copying loop in mpi_write_sgl(), we have if (lzeros) { mpi_limb_t *limb1 = (void *)p - sizeof(alimb); mpi_limb_t *limb2 = (void *)p - sizeof(alimb) + lzeros; *limb1 = *limb2; ... } where p points past the end of alimb2 which lives on the stack and contains the current limb in BE order. The purpose of the above is to shift the non-zero bytes of alimb2 to its beginning in memory, i.e. to skip its leading zero bytes. However, limb2 points somewhere into the middle of alimb2 and thus, reading *limb2 pulls in lzero bytes from somewhere. Indeed, KASAN splats: BUG: KASAN: stack-out-of-bounds in mpi_write_to_sgl+0x4e3/0x6f0 at addr ffff8800cb04f601 Read of size 8 by task systemd-udevd/391 page:ffffea00032c13c0 count:0 mapcount:0 mapping: (null) index:0x0 flags: 0x3fff8000000000() page dumped because: kasan: bad access detected CPU: 3 PID: 391 Comm: systemd-udevd Tainted: G B L 4.5.0-next-20160316+ #12 [...] Call Trace: [<ffffffff8194889e>] dump_stack+0xdc/0x15e [<ffffffff819487c2>] ? _atomic_dec_and_lock+0xa2/0xa2 [<ffffffff814892b5>] ? __dump_page+0x185/0x330 [<ffffffff8150ffd6>] kasan_report_error+0x5e6/0x8b0 [<ffffffff814724cd>] ? kzfree+0x2d/0x40 [<ffffffff819c5bce>] ? mpi_free_limb_space+0xe/0x20 [<ffffffff819c469e>] ? mpi_powm+0x37e/0x16f0 [<ffffffff815109f1>] kasan_report+0x71/0xa0 [<ffffffff819c0353>] ? mpi_write_to_sgl+0x4e3/0x6f0 [<ffffffff8150ed34>] __asan_load8+0x64/0x70 [<ffffffff819c0353>] mpi_write_to_sgl+0x4e3/0x6f0 [<ffffffff819bfe70>] ? mpi_set_buffer+0x620/0x620 [<ffffffff819c0e6f>] ? mpi_cmp+0xbf/0x180 [<ffffffff8186e282>] rsa_verify+0x202/0x260 What's more, since lzeros can be anything from 1 to sizeof(mpi_limb_t)-1, the above will cause unaligned accesses which is bad on non-x86 archs. Fix the issue, by preparing the starting point p for the upcoming copy operation instead of shifting the source memory, i.e. alimb2. Fixes: 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit ea122be0b8f788b30e71ed5536fddc05f5ddff86 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:37 2016 +0100 lib/mpi: mpi_write_sgl(): purge redundant pointer arithmetic Within the copying loop in mpi_write_sgl(), we have if (lzeros) { ... p -= lzeros; y = lzeros; } p = p - (sizeof(alimb) - y); If lzeros == 0, then y == 0, too. Thus, lzeros gets subtracted and added back again to p. Purge this redundancy. Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 654842ef53d7820129a751f5cc620e5a69c694a9 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:36 2016 +0100 lib/mpi: mpi_write_sgl(): fix style issue with lzero decrement Within the copying loop in mpi_write_sgl(), we have if (lzeros > 0) { ... lzeros -= sizeof(alimb); } However, at this point, lzeros < sizeof(alimb) holds. Make this fact explicit by rewriting the above to if (lzeros) { ... lzeros = 0; } Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f2d1362ff7d266b3d2b1c764d6c2ef4a3b457f23 Author: Nicolai Stange <nicstange@gmail.com> Date: Tue Mar 22 13:12:35 2016 +0100 lib/mpi: mpi_write_sgl(): fix skipping of leading zero limbs Currently, if the number of leading zeros is greater than fits into a complete limb, mpi_write_sgl() skips them by iterating over them limb-wise. However, it fails to adjust its internal leading zeros tracking variable, lzeros, accordingly: it does a p -= sizeof(alimb); continue; which should really have been a lzeros -= sizeof(alimb); continue; Since lzeros never decreases if its initial value >= sizeof(alimb), nothing gets copied by mpi_write_sgl() in that case. Instead of skipping the high order zero limbs within the loop as shown above, fix the issue by adjusting the copying loop's bounds. Fixes: 2d4d1eea540b ("lib/mpi: Add mpi sgl helpers") Signed-off-by: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> lib/mpi/mpicoder.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) commit 3cf9d84eb84abb4c186cd793d8720437a2ee2b1a Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Tue Mar 22 10:58:25 2016 +0900 crypto: s5p-sss - Sort the headers to improve readability Sort the headers alphabetically to improve readability and to spot duplications easier. Suggested-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 9e4a1100a445671dd55ff74dce859221cc1464fa Author: Krzysztof Kozlowski <krzk@kernel.org> Date: Tue Mar 22 10:58:24 2016 +0900 crypto: s5p-sss - Handle unaligned buffers During crypto selftests on Odroid XU3 (Exynos5422) some of the algorithms failed because of passing AES-block unaligned source and destination buffers: alg: skcipher: encryption failed on chunk test 1 for ecb-aes-s5p: ret=22 Handle such case by copying the buffers to a new aligned and contiguous space. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 150 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 138 insertions(+), 12 deletions(-) commit 119c3ab4ed33c04782f02040a4bc686216788c53 Author: Krzysztof Kozlowski <krzk@kernel.org> Date: Tue Mar 22 10:58:23 2016 +0900 crypto: s5p-sss - Minor coding cleanups Remove unneeded inclusion of delay.h and get rid of indentation from labels. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/s5p-sss.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit 29e9330f2ba8cbca7c9dd8a03db1e6e453aea2f2 Author: Tom Lendacky <thomas.lendacky@amd.com> Date: Mon Mar 21 11:43:22 2016 -0500 MAINTAINERS: Add a new maintainer for the CCP driver Gary will be taking over future development of the CCP driver, so add him as a co-maintainer of the driver. Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Acked-by: Gary Hook <gary.hook@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 063327f54e864874de3f4d6715ff284e8d135e12 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Mon Mar 21 12:03:43 2016 +0300 crypto: marvell/cesa - remove unneeded condition creq->cache[] is an array inside the struct, it's not a pointer and it can't be NULL. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/marvell/hash.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 06af9b0f4949b85b20107e6d75f5eba15111d220 Author: Colin Ian King <colin.king@canonical.com> Date: Fri Mar 18 15:51:31 2016 +0000 PKCS#7: fix missing break on OID_sha224 case The OID_sha224 case is missing a break and it falls through to the -ENOPKG error default. Since HASH_ALGO_SHA224 seems to be supported, this looks like an unintentional missing break. Fixes: 07f081fb5057 ("PKCS#7: Add OIDs for sha224, sha284 and sha512 hash algos and use them") Cc: <stable@vger.kernel.org> # 4.2+ Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> crypto/asymmetric_keys/pkcs7_parser.c | 1 + 1 file changed, 1 insertion(+) commit 150f6d457cfcb37646b026251d8a584978618726 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Fri Mar 18 19:08:48 2016 +0530 crypto: n2 - Remove return statement from void function Return statement at the end of a void function is useless. The Coccinelle semantic patch used to make this change is as follows: //<smpl> @@ identifier f; expression e; @@ void f(...) { <... - return e; ...> } //</smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/n2_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit dc1d9dee3042d4c507bd7eb557a06918a1f09ae0 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 13:20:18 2016 +0900 crypto: s5p-sss - Enable COMPILE_TEST Get some build coverage of S5P/Exynos AES H/W acceleration driver. Driver uses DMA and devm_ioremap_resource() so add DMA and IOMEM dependencies for the compile testing. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 4dd6e9ea7ae824ebfd054b92e4f97ad75454b4c2 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 13:19:55 2016 +0900 hwrng: exynos - Enable COMPILE_TEST Get some build coverage of Exynos H/W random number generator driver. Driver uses devm_ioremap_resource() so add IOMEM dependency for the compile testing. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 27d80fa8bccf8d28bef4f89709638efc624fef9a Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 09:07:15 2016 +0900 hwrng: exynos - Disable runtime PM on driver unbind Driver enabled runtime PM but did not revert this on removal. Re-binding of a device triggered warning: exynos-rng 10830400.rng: Unbalanced pm_runtime_enable! Fixes: b329669ea0b5 ("hwrng: exynos - Add support for Exynos random number generator") Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/exynos-rng.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 48a61e1e2af8020f11a2b8f8dc878144477623c6 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 09:07:14 2016 +0900 hwrng: exynos - Disable runtime PM on probe failure Add proper error path (for disabling runtime PM) when registering of hwrng fails. Fixes: b329669ea0b5 ("hwrng: exynos - Add support for Exynos random number generator") Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/exynos-rng.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit f1925d78d7b710a1179828d53e918295f5f5d222 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 09:07:13 2016 +0900 hwrng: exynos - Fix unbalanced PM runtime put on timeout error path In case of timeout during read operation, the exit path lacked PM runtime put. This could lead to unbalanced runtime PM usage counter thus leaving the device in an active state. Fixes: d7fd6075a205 ("hwrng: exynos - Add timeout for waiting on init done") Cc: <stable@vger.kernel.org> # v4.4+ Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/exynos-rng.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit f0d947ac01632fa6c75cb07262922a93736385c1 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 14 09:07:12 2016 +0900 hwrng: exynos - Runtime suspend device after init The driver uses pm_runtime_put_noidle() after initialization so the device might remain in active state if the core does not read from it (the read callback contains regular runtime put). The put_noidle() was chosen probably to avoid unneeded suspend and resume cycle after the initialization. However for this purpose autosuspend is enabled so it is safe to runtime put just after the initialization. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/char/hw_random/exynos-rng.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 97ee7ed394f9f277f492026b9a0708cd92e6ef7d Author: Peter Meerwald <pmeerw@pmeerw.net> Date: Sun Mar 13 16:15:37 2016 +0100 crypto: omap-des - Improve wording for CRYPTO_DEV_OMAP_DES in Kconfig Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> drivers/crypto/Kconfig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 83094e5e9e49f893403d6fad20c9c06c980c2d1b Author: Tadeusz Struk <tadeusz.struk@intel.com> Date: Fri Mar 11 11:50:33 2016 -0800 crypto: af_alg - add async support to algif_aead Following the async change for algif_skcipher this patch adds similar async read to algif_aead. changes in v3: - add call to aead_reset_ctx directly from aead_put_sgl instead of calling them separatelly one after the other - remove wait from aead_sock_destruct function as it is not needed when sock_hold is used changes in v2: - change internal data structures from fixed size arrays, limited to RSGL_MAX_ENTRIES, to linked list model with no artificial limitation. - use sock_kmalloc instead of kmalloc for memory allocation - use sock_hold instead of separate atomic ctr to wait for outstanding request Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> crypto/algif_aead.c | 268 ++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 237 insertions(+), 31 deletions(-) commit d761701c55a99598477f3cb25c03d939a7711e74 Author: Dave Gordon <david.s.gordon@intel.com> Date: Mon Apr 4 18:50:57 2016 +0100 drm/i915/guc: always reset GuC before loading firmware After a suspend-resume cycle, the resumed kernel has no idea what the booted kernel may have done to the GuC before replacing itself with the resumed image. In particular, it may have already loaded the GuC with firmware, which will then cause this kernel's attempt to (re)load the firmware to fail (GuC program memory is write-once!). The symptoms (GuC firmware reload fails after hibernation) are further described in the Bugzilla reference below. So let's *always* reset the GuC just before (re)loading the firmware; the hardware should then be in a well-known state, and we may even avoid some of the issues arising from unpredictable timing. Also added some more fields & values to the definition of the GUC_STATUS register, which is the key diagnostic indicator if the GuC load fails. Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Reviewed-by: Arun Siluvery <arun.siluvery@linux.intel.com> Cc: Alex Dai <yu.dai@intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94390 Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_guc_reg.h | 12 ++++++++-- drivers/gpu/drm/i915/intel_guc_loader.c | 40 ++++++++++++++++----------------- 2 files changed, 29 insertions(+), 23 deletions(-) commit 6b332fa20f671265638d1d62496f9607c5f6e92f Author: Arun Siluvery <arun.siluvery@linux.intel.com> Date: Mon Apr 4 18:50:56 2016 +0100 drm/i915/guc: reset GuC and retry on firmware load failure Due to timing issues in the HW, some of the status bits required for GuC authentication occasionally don't get set; when that happens, the GuC cannot be initialized and we will be left with a wedged GPU. The W/A suggested is to perform a soft reset of the GuC and attempt to reload the F/W again for few times before giving up. As the failure is dependent on timing, tests performed by triggering manual full gpu reset (i915_wedged) showed that we could sometimes hit this after several thousand iterations, but sometimes tests ran even longer without any issues. Reset and reload mechanism proved helpful when we indeed hit f/w load failure, so it is better to include this to improve driver stability. This change implements the following WAs, WaEnableuKernelHeaderValidFix:skl,bxt WaEnableGuCBootHashCheckNotSet:skl,bxt Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Reviewed-by: Alex Dai <yu.dai@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_guc_reg.h | 1 + drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_guc_loader.c | 49 +++++++++++++++++++++++++++++++-- drivers/gpu/drm/i915/intel_uncore.c | 19 +++++++++++++ 5 files changed, 69 insertions(+), 2 deletions(-) commit 168cf367d7017a9d19522f8e59462c8b01c1212e Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Apr 5 10:22:25 2016 +0100 drm/i915/shrinker: Refactor common uninterruptible locking Both the oom and vmap notifier callbacks have a loop to acquire the struct_mutex and set the device as uninterruptible, within a certain time. Refactor the common code into a pair of functions. Suggested-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459848145-24042-1-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_gem_shrinker.c | 79 +++++++++++++++++--------------- 1 file changed, 42 insertions(+), 37 deletions(-) commit e87666b52f00fdb373349c4e6e1c09ced964e3c5 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Apr 4 14:46:43 2016 +0100 drm/i915/shrinker: Hook up vmap allocation failure notifier If the core runs out of vmap address space, it will call a notifier in case any driver can reap some of its vmaps. As i915.ko is possibily holding onto vmap address space that could be recovered, hook into the notifier chain and try and reap objects holding onto vmaps. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: David Rientjes <rientjes@google.com> Cc: Roman Pen <r.peniaev@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Mika Kahola <mika.kahola@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459777603-23618-4-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gem_shrinker.c | 39 ++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) commit 2c61cf9c56cbc4e0a4475232659ac30bb4c28674 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 17 15:02:55 2016 +0200 mac80211: fix cipher scheme function name The code is only used with iwlwifi, but still should have proper mac80211 naming scheme; fix that. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit c84387d2f2c83d1d49a8dfefed13a8b39f017230 Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 17 15:02:54 2016 +0200 mac80211: clean up station flags debugfs Avoid the really strange %s%s%s expression, use an array of flag names and check that all flags are present. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/debugfs_sta.c | 63 +++++++++++++++++++++++++++++++--------------- net/mac80211/sta_info.h | 4 +++ 2 files changed, 47 insertions(+), 20 deletions(-) commit 3c5bcb2e1930bdbccd14a49660895f014349b51d Author: Avraham Stern <avraham.stern@intel.com> Date: Thu Mar 17 15:02:53 2016 +0200 ieee80211: support parsing Fine Timing Measurement action frame Add definition for Fine Timing Measurement (FTM) frame format as defined in IEEE802.11-REVmcD5.0 section 9.6.8.33 Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/linux/ieee80211.h | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 4da56b99d99e5a7df2b7f11e87bfea935f909732 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Apr 4 14:46:42 2016 +0100 mm/vmap: Add a notifier for when we run out of vmap address space vmaps are temporary kernel mappings that may be of long duration. Reusing a vmap on an object is preferrable for a driver as the cost of setting up the vmap can otherwise dominate the operation on the object. However, the vmap address space is rather limited on 32bit systems and so we add a notification for vmap pressure in order for the driver to release any cached vmappings. The interface is styled after the oom-notifier where the callees are passed a pointer to an unsigned long counter for them to indicate if they have freed any space. v2: Guard the blocking notifier call with gfpflags_allow_blocking() v3: Correct typo in forward declaration and move to head of file Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: David Rientjes <rientjes@google.com> Cc: Roman Peniaev <r.peniaev@gmail.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org Acked-by: Andrew Morton <akpm@linux-foundation.org> # for inclusion via DRM Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459777603-23618-3-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> include/linux/vmalloc.h | 4 ++++ mm/vmalloc.c | 27 +++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) commit 602fae425cf3ade41a4787f8ddf850af418faa3b Author: Johannes Berg <johannes.berg@intel.com> Date: Thu Mar 17 15:02:52 2016 +0200 mac80211: don't start dynamic PS timer if not needed If the device implements dynamic PS itself, there's no need to ever start the dynamic powersave timer on RX. While at it, fix up some indentation in this code. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rx.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 6f0ac2047a86a0ce3d75227f8b83e84d0a2f993d Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Apr 4 14:46:41 2016 +0100 drm/i915/shrinker: Account for unshrinkable unbound pages Since we only attempt to purge an object if can_release_pages() report true, we should also only add it to the count of potential recoverable pages when can_release_pages() is true. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Akash Goel <akash.goel@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459777603-23618-2-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_gem_shrinker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit de03d2b0ef6520cf9da2e429cd7afb534782b737 Author: Shannon Nelson <shannon.nelson@intel.com> Date: Thu Mar 10 14:59:44 2016 -0800 i40e: Assure that adminq is alive in debug mode When dropping into debug mode in a failed probe, make sure that the AdminQ is left alive for possible hand debug of driver and firmware states. Move the mutex_init calls earlier in probe so that if init fails, the admin queue interface is still available for debugging purposes. Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit fc4a25c5b741ecb4ef4d0f1802775e8a88d7e0a7 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Apr 5 11:59:05 2016 +0200 mac80211: remove sta_info debugfs sub-struct Since the previous patch, the struct only has a single member, so remove the struct and leave just the single member. Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/debugfs_sta.c | 22 +++++++++++----------- net/mac80211/rate.h | 4 ++-- net/mac80211/sta_info.h | 6 ++---- 3 files changed, 15 insertions(+), 17 deletions(-) commit 96f321c9d42a61aa1e2760a47a574f286b028be2 Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Sat Mar 19 19:59:43 2016 +0530 mac80211: Remove unused variable in per STA debugfs struct Remove unused variable in per STA debugfs structure, 'commit 34e895075e21 ("mac80211: allow station add/remove to sleep")' removed the only user of 'add_has_run'. Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/debugfs_sta.c | 2 -- net/mac80211/sta_info.h | 1 - 2 files changed, 3 deletions(-) commit 692783980ad6163e8586baa36c066cd0d22fc7ce Author: Shannon Nelson <shannon.nelson@intel.com> Date: Thu Mar 10 14:59:43 2016 -0800 i40e: Remove MSIx only if created When cleaning up the interrupt handling, clean up the IRQs only if we actually got them set up. There are a couple of error recovery paths that were violating this and causing the kernel a bit of indigestion. Signed-off-by: Shannon Nelson <shannon.nelson@intel.com> Reviewed-by: Williams, Mitch A <mitch.a.williams@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 618290262e960469758d4ab67457fcb2ea356d51 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Thu Mar 10 14:59:42 2016 -0800 i40e: Fix up return code The i40e_common.c typically uses i40e_status as a return code, but got missed this one case. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit b6caccaccf749dddd296f3056111d6c4b94500c1 Author: Kevin Scott <kevin.c.scott@intel.com> Date: Thu Mar 10 14:59:41 2016 -0800 i40e: Save off VSI resource count when updating VSI When updating a VSI, save off the number of allocated and unallocated VSIs as we do when adding a VSI. Signed-off-by: Kevin Scott <kevin.c.scott@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_common.c | 6 ++++++ 1 file changed, 6 insertions(+) commit 1e0bbebaae660f27c24cbd9c3e693420234115ff Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 9 13:27:09 2016 +0200 mac80211: enable starting BA session with custom timeout Currently the debugfs entry for starting aggregation session starts it with timeout of 5 seconds. Allow opening a session with a custom timeout (according to spec 0 is no timeout). while at it, refactor the function and remove the magic numbers. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/debugfs_sta.c | 47 +++++++++++++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 17 deletions(-) commit e03521232d2f808b1b593f44565665efb7b242b1 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 9 13:27:08 2016 +0200 mac80211: add NETIF_F_RXCSUM to features white list NETIF_F_RXCSUM is not in the white list, though some drivers may want to set it in order to enable seeing the actual RX checksum status in ethtool. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f278ce4ffaaa2ee3adb957add3df7b41e6ecc1b3 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Wed Mar 9 10:08:27 2016 +0200 mac80211: Set global RRM capability Allow publishing RRM capabilities for features that are not HW dependent. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/main.c | 2 ++ 1 file changed, 2 insertions(+) commit 2aa4d45635ad09fbd7ff6b6155d2d50b2b31cf90 Author: Akira Moroo <retrage01@gmail.com> Date: Tue Mar 8 23:17:42 2016 +0900 cfg80211: fix kernel-doc struct name This patch fix a structure name mismatch in cfg80211.h. Signed-off-by: Moroo Akira <retrage01@gmail.com> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 06171e9c0bd54bd7dde67dfb2fa4cced23cff880 Author: Felix Fietkau <nbd@openwrt.org> Date: Thu Mar 3 23:25:42 2016 +0100 mac80211: minstrel_ht: improve sample rate skip logic There were a few issues that were slowing down the process of finding the optimal rate, especially on devices with multi-rate retry limitations: When max_tp_rate[0] was slower than max_tp_rate[1], the code did not sample max_tp_rate[1], which would often allow it to switch places with max_tp_rate[0] (e.g. if only the first sampling attempts were bad, but the rate is otherwise good). Also, sample attempts of rates between max_tp_rate[0] and [1] were being ignored in this case, because the code only checked if the rate was slower than [1]. Fix this by checking against the fastest / second fastest max_tp_rate instead of assuming a specific order between the two. In my tests this patch significantly reduces the time until minstrel_ht finds the optimal rate right after assoc Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/rc80211_minstrel_ht.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) commit b7c359376429953dc1672224dbc9845eadf2a29c Author: Catherine Sullivan <catherine.sullivan@intel.com> Date: Thu Mar 10 14:59:40 2016 -0800 i40e/i40evf: Remove I40E_MAX_USER_PRIORITY define This patch removes the duplicate definition of I40E_MAX_USER_PRIORITY in i40e.h that is not needed. Signed-off-by: Catherine Sullivan <catherine.sullivan@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 1 - 1 file changed, 1 deletion(-) commit 4ea623922d1d73c162da53e02cce1d0d3fd55893 Author: Jesse Brandeburg <jesse.brandeburg@intel.com> Date: Thu Mar 10 14:59:39 2016 -0800 i40e/i40evf: Fix casting in transmit code Simple cast to fix a sparse warning. Fixes: commit 5453205cd097 ("i40e/i40evf: Enable support for SKB_GSO_UDP_TUNNEL_CSUM") Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 5 +++-- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) commit a619afe814453300684f1d5a6478d67f791bc723 Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon Mar 7 09:30:03 2016 -0800 i40e/i40evf: Add support for bulk free in Tx cleanup This patch enables bulk Tx clean for skbs. In order to enable it we need to pass the napi_budget value as that is used to determine if we are truly running in NAPI mode or if we are simply calling the routine from netpoll with a budget of 0. In order to avoid adding too many more variables I thought it best to pass the VSI directly in a fashion similar to what we do on igb and ixgbe with the q_vector. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 20 +++++++++++--------- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 20 +++++++++++--------- 2 files changed, 22 insertions(+), 18 deletions(-) commit 07310a63147164eaf44a68932fbe9dbbde0fa82b Author: Felix Fietkau <nbd@openwrt.org> Date: Wed Mar 2 15:54:51 2016 +0100 mac80211: do not pass injected frames without a valid rate to the driver Fall back to rate control if the requested bitrate was not found. Fixes: dfdfc2beb0dd ("mac80211: Parse legacy and HT rate in injected frames") Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/tx.c | 3 +++ 1 file changed, 3 insertions(+) commit f66b60f6524c970d43af7a68dd50dcce289887e7 Author: Sven Eckelmann <sven@narfation.org> Date: Wed Feb 24 16:25:49 2016 +0100 mac80211: fix parsing of 40Mhz in injected radiotap header The MCS bandwidth part of the radiotap header is 2 bits wide. The full 2 bit have to compared against IEEE80211_RADIOTAP_MCS_BW_40 and not only if the first bit is set. Otherwise IEEE80211_RADIOTAP_MCS_BW_40 can be confused with IEEE80211_RADIOTAP_MCS_BW_20U. Fixes: dfdfc2beb0dd ("mac80211: Parse legacy and HT rate in injected frames") Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/tx.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 38de03d2a28925b489c11546804e2f5418cc17a4 Author: Arend van Spriel <arend@broadcom.com> Date: Wed Mar 2 20:37:18 2016 +0100 nl80211: add feature for BSS selection support Introducing a new feature that the driver can use to indicate the driver/firmware supports configuration of BSS selection criteria upon CONNECT command. This can be useful when multiple BSS-es are found belonging to the same ESS, ie. Infra-BSS with same SSID. The criteria can then be used to offload selection of a preferred BSS. Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Reviewed-by: Lei Zhang <leizh@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> [move wiphy support check into parse_bss_select()] Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 34 +++++++++++++ include/uapi/linux/nl80211.h | 52 ++++++++++++++++++++ net/wireless/core.c | 7 +++ net/wireless/nl80211.c | 111 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 204 insertions(+) commit f59374eb427fb1377fdb7b8b3691c48e0c77a3c4 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 2 23:46:14 2016 +0200 mac80211: synchronize driver rx queues before removing a station Some devices, like iwlwifi, have RSS queues. This may cause a situation where a disassociation is handled in control path and results in station removal while there are prior RX frames that were still not processed in other queues. When they will be processed the station will be gone, and the frames will be dropped. Add a synchronization interface to avoid that. When driver returns from the synchronization mac80211 may remove the station. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 5 +++++ net/mac80211/driver-ops.h | 15 +++++++++++++++ net/mac80211/sta_info.c | 9 ++++++++- net/mac80211/trace.h | 12 ++++++++++++ 4 files changed, 40 insertions(+), 1 deletion(-) commit 60854fd94573f0d3b80b55b40cf0140a0430f3ab Author: Bob Copeland <me@bobcopeland.com> Date: Wed Mar 2 10:09:20 2016 -0500 mac80211: mesh: convert path table to rhashtable In the time since the mesh path table was implemented as an RCU-traversable, dynamically growing hash table, a generic RCU hashtable implementation was added to the kernel. Switch the mesh path table over to rhashtable to remove some code and also gain some features like automatic shrinking. Cc: Thomas Graf <tgraf@suug.ch> Cc: netdev@vger.kernel.org Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/ieee80211_i.h | 11 +- net/mac80211/mesh.c | 6 - net/mac80211/mesh.h | 31 +- net/mac80211/mesh_pathtbl.c | 786 ++++++++++++++------------------------------ 4 files changed, 259 insertions(+), 575 deletions(-) commit 8f6fd83c6c5ec66a4a70c728535ddcdfef4f3697 Author: Bob Copeland <me@bobcopeland.com> Date: Wed Mar 2 10:09:19 2016 -0500 rhashtable: accept GFP flags in rhashtable_walk_init In certain cases, the 802.11 mesh pathtable code wants to iterate over all of the entries in the forwarding table from the receive path, which is inside an RCU read-side critical section. Enable walks inside atomic sections by allowing GFP_ATOMIC allocations for the walker state. Change all existing callsites to pass in GFP_KERNEL. Acked-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: Bob Copeland <me@bobcopeland.com> [also adjust gfs2/glock.c and rhashtable tests] Signed-off-by: Johannes Berg <johannes.berg@intel.com> fs/gfs2/glock.c | 4 ++-- include/linux/rhashtable.h | 3 ++- lib/rhashtable.c | 6 ++++-- lib/test_rhashtable.c | 2 +- net/ipv6/ila/ila_xlat.c | 3 ++- net/netfilter/nft_hash.c | 4 ++-- net/netlink/af_netlink.c | 3 ++- net/sctp/proc.c | 3 ++- 8 files changed, 17 insertions(+), 11 deletions(-) commit 947c2a0eccec29fcd30e717787e65792b1e607ed Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:03:59 2016 -0500 mac80211: mesh: embed known gates list in struct mesh_path The mesh path table uses a struct mesh_node in its hlists in order to support a resizable hash table: the mesh_node provides an indirection to the actual mesh path so that two different bucket lists can point to the same path entry. However, for the known gates list, we don't need this indirection because there is ever only one list. So we can just embed the hlist_node in the mesh path itself, which simplifies things a bit and saves a linear search whenever we need to find an item in the list. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh.h | 1 + net/mac80211/mesh_pathtbl.c | 100 +++++++++++++++++++------------------------- 2 files changed, 45 insertions(+), 56 deletions(-) commit b15dc38b9817729d3d4962f8c84bbda0eccb3532 Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:03:58 2016 -0500 mac80211: mesh: factor out common mesh path allocation code Remove duplicate code to allocate and initialize a mesh path or mesh proxy path. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh_pathtbl.c | 51 +++++++++++++++++++++++++-------------------- 1 file changed, 28 insertions(+), 23 deletions(-) commit 443954815b63b36f09623d74170520e6554f5fac Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:03:57 2016 -0500 mac80211: mesh: don't hash sdata in mpath tables Now that the sdata pointer is the same for all entries of a path table, hashing it is pointless, so hash only the address. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/mesh_pathtbl.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) commit 2bdaf386f99c4a82788812e583ff59c6714ae4d6 Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:03:56 2016 -0500 mac80211: mesh: move path tables into if_mesh The mesh path and mesh gate hashtables are global, containing all of the mpaths for every mesh interface, but the paths are all tied logically to a single interface. The common case is just a single mesh interface, so optimize for that by moving the global hashtable into the per-interface struct. Doing so allows us to drop sdata pointer comparisons inside the lookups and also saves a few bytes of BSS and data. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/cfg.c | 4 +- net/mac80211/ieee80211_i.h | 12 +++ net/mac80211/mesh.c | 10 ++- net/mac80211/mesh.h | 10 +-- net/mac80211/mesh_pathtbl.c | 181 +++++++++++++++++++------------------------- net/mac80211/tx.c | 2 +- 6 files changed, 104 insertions(+), 115 deletions(-) commit 12880d169471fb14c46d6f323f31127702a6d5e6 Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Fri Feb 26 22:12:49 2016 +0200 mac80211_hwsim: Support a hw scan request for a specific BSSID If the hw scan request specifies a single BSSID, use that value instead of the wildcard BSSID in the Probe Request frames. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> drivers/net/wireless/mac80211_hwsim.c | 5 +++++ 1 file changed, 5 insertions(+) commit e345f44f2b7c6a77c1c0677b7c8606a0bb1c5c5c Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Fri Feb 26 22:12:48 2016 +0200 mac80211: Support a scan request for a specific BSSID If the cfg80211 scan trigger operation specifies a single BSSID, use that value instead of the wildcard BSSID in the Probe Request frames. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/mac80211/scan.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 818965d3917774955fad52f87b59d690d8be9e8b Author: Jouni Malinen <jouni@qca.qualcomm.com> Date: Fri Feb 26 22:12:47 2016 +0200 cfg80211: Allow a scan request for a specific BSSID This allows scans for a specific BSSID to be optimized by the user space application by requesting the driver to set the Probe Request frame BSSID field (Address 3) to the specified BSSID instead of the wildcard BSSID. This prevents other APs from replying which reduces airtime need and latency in getting the response from the target AP through. This is an optimization and as such, it is acceptable for some of the drivers not to support the mechanism. If not supported, the wildcard BSSID will be used and more responses may be received. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/cfg80211.h | 2 ++ include/uapi/linux/nl80211.h | 4 +++- net/wireless/nl80211.c | 6 ++++++ net/wireless/scan.c | 2 ++ net/wireless/sme.c | 2 ++ 5 files changed, 15 insertions(+), 1 deletion(-) commit f2edaaaa392bc21c24f532ea9bcc952a54a22367 Author: Alexander Duyck <aduyck@mirantis.com> Date: Mon Mar 7 09:29:57 2016 -0800 i40e/i40evf: Fix handling of boolean logic in polling routines In the polling routines for i40e and i40evf we were using bitwise operators to avoid the side effects of the logical operators, specifically the fact that if the first case is true with "||" we skip the second case, or if it is false with "&&" we skip the second case. This fixes an earlier patch that converted the bitwise operators over to the logical operators and instead replaces the entire thing with just an if statement since it should be more readable what we are trying to do this way. Fixes: 1a36d7fadd14 ("i40e/i40evf: use logical operators, not bitwise") Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 13 ++++++++----- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 13 ++++++++----- 2 files changed, 16 insertions(+), 10 deletions(-) commit 5c05803a3e2054257d7e8e737a6efaf2c7f6b725 Author: Sven Eckelmann <sven@narfation.org> Date: Wed Feb 24 16:25:48 2016 +0100 mac80211: document only injected *_RADIOTAP_* flags Not the internal flags but the radiotap flags are parsed when the monitor injected frames are prepared for transmission. Thus the documentation should only document these. Reported-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Reported-by: Johannes Berg <johannes@sipsolutions.net> Fixes: dfdfc2beb0dd ("mac80211: Parse legacy and HT rate in injected frames") Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Documentation/networking/mac80211-injection.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f980ebc058c2fa2a552e495db1de0b330082ab70 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Feb 24 11:49:45 2016 +0200 mac80211: allow not sending MIC up from driver for HW crypto When HW crypto is used, there's no need for the CCMP/GCMP MIC to be available to mac80211, and the hardware might have removed it already after checking. The MIC is also useless to have when the frame is already decrypted, so allow indicating that it's not present. Since we are running out of bits in mac80211_rx_flags, make the flags field a u64. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 2 +- drivers/net/wireless/ath/wcn36xx/txrx.c | 2 +- include/net/mac80211.h | 5 ++++- net/mac80211/util.c | 5 +++-- net/mac80211/wpa.c | 26 ++++++++++++++------------ 5 files changed, 23 insertions(+), 17 deletions(-) commit 162dd6a7253ab009c6335c21ce6b80cf227ddda4 Author: Johannes Berg <johannes.berg@intel.com> Date: Tue Feb 23 23:05:06 2016 +0200 mac80211: allow drivers to report CLOCK_BOOTTIME for scan results This was requested by Android, and the appropriate cfg80211 API had been added by Dmitry. Support it in mac80211, allowing drivers to provide the timestamp. Signed-off-by: Johannes Berg <johannes.berg@intel.com> include/net/mac80211.h | 3 +++ net/mac80211/scan.c | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) commit 646e76bb5daf4ca38438c69ffb72cccb605f3466 Author: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Date: Tue Feb 23 15:43:35 2016 +0100 mac80211: parse VHT info in injected frames Add VHT radiotap parsing support to ieee80211_parse_tx_radiotap(). That capability has been tested using a d-link dir-860l rev b1 running OpenWrt trunk and mt76 driver Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Documentation/networking/mac80211-injection.txt | 13 +++++++++++ net/mac80211/tx.c | 31 +++++++++++++++++++++++++ 2 files changed, 44 insertions(+) commit 1948b2a2ec132115b422ae1feba1a3f5598f4acd Author: João Paulo Rechi Vita <jprvita@gmail.com> Date: Mon Feb 22 11:36:39 2016 -0500 rfkill: Use switch to demux userspace operations Using a switch to handle different ev.op values in rfkill_fop_write() makes the code easier to extend, as out-of-range values can always be handled by the default case. Signed-off-by: João Paulo Rechi Vita <jprvita@endlessm.com> [roll in fix for RFKILL_OP_CHANGE from Jouni] Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/rfkill/core.c | 36 ++++++++++++++++++++++-------------- 1 file changed, 22 insertions(+), 14 deletions(-) commit 98bd147d7903580ca5d5dfa0bc39c2d16714d84e Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Mar 16 14:29:08 2016 +0100 wext: unregister_pernet_subsys() on notifier registration failure If register_netdevice_notifier() fails (which in practice it can't right now), we should call unregister_pernet_subsys(). Do that. Reported-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Johannes Berg <johannes.berg@intel.com> net/wireless/wext-core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 311f23e9a4314f62fed6c13e112c998b07e37e63 Author: Alan Cox <alan@linux.intel.com> Date: Tue Mar 1 16:02:15 2016 -0800 i40evf: remove dead code The only error case is when the malloc fails, in which case the clean up loop does nothing at all, so remove it Signed-off-by: Alan Cox <alan@linux.intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40evf/i40evf_main.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) commit 5c4654daf2e2f25dfbd7fa572c59937ea6d4198b Author: Alexander Duyck <aduyck@mirantis.com> Date: Fri Feb 19 12:17:08 2016 -0800 i40e/i40evf: Allow up to 12K bytes of data per Tx descriptor instead of 8K From what I can tell the practical limitation on the size of the Tx data buffer is the fact that the Tx descriptor is limited to 14 bits. As such we cannot use 16K as is typically used on the other Intel drivers. However artificially limiting ourselves to 8K can be expensive as this means that we will consume up to 10 descriptors (1 context, 1 for header, and 9 for payload, non-8K aligned) in a single send. I propose that we can reduce this by increasing the maximum data for a 4K aligned block to 12K. We can reduce the descriptors used for a 32K aligned block by 1 by increasing the size like this. In addition we still have the 4K - 1 of space that is still unused. We can use this as a bit of extra padding when dealing with data that is not aligned to 4K. By aligning the descriptors after the first to 4K we can improve the efficiency of PCIe accesses as we can avoid using byte enables and can fetch full TLP transactions after the first fetch of the buffer. This helps to improve PCIe efficiency. Below is the results of testing before and after with this patch: Recv Send Send Utilization Service Demand Socket Socket Message Elapsed Send Recv Send Recv Size Size Size Time Throughput local remote local remote bytes bytes bytes secs. 10^6bits/s % S % U us/KB us/KB Before: 87380 16384 16384 10.00 33682.24 20.27 -1.00 0.592 -1.00 After: 87380 16384 16384 10.00 34204.08 20.54 -1.00 0.590 -1.00 So the net result of this patch is that we have a small gain in throughput due to a reduction in overhead for putting together the frame. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 +- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 13 +++++++--- drivers/net/ethernet/intel/i40e/i40e_txrx.h | 35 ++++++++++++++++++++++++--- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 13 +++++++--- drivers/net/ethernet/intel/i40evf/i40e_txrx.h | 35 ++++++++++++++++++++++++--- 5 files changed, 83 insertions(+), 15 deletions(-) commit 08ca38742b63ae3825096e943de371a3b372c4a0 Author: Stefan Assmann <sassmann@kpanic.de> Date: Wed Feb 3 09:20:47 2016 +0100 i40e: call ndo_stop() instead of dev_close() when running offline selftest Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent. Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all. Signed-off-by: Stefan Assmann <sassmann@kpanic.de> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/i40e/i40e.h | 2 +- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 ++-- drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ---- 3 files changed, 3 insertions(+), 7 deletions(-) commit 7071af97c6316d2a474c75e15f40602aa727b124 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 13:11:15 2016 +0200 drm/i915/chv: add more IOSF port definitions Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/65d58c578adecc205a741102329bc9c9f6eb79cf.1458299160.git.jani.nikula@intel.com drivers/gpu/drm/i915/i915_reg.h | 4 ++++ 1 file changed, 4 insertions(+) commit 1d96a4a8ace6c1b08c7d203d9533b14e59f2200b Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 13:11:10 2016 +0200 drm/i915/dsi: add support for DSI sequence block v2 gpio element In sequence block v2, and only in v2, the gpio source (i.e. IOSF port) is specified separately. v2: initialize gpio_source to 0 and handle v1 and v2 in the same branch Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/87152feec8f921dc82502af1b29c0956b0d360bb.1458299160.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit 7b4b7a8db439dca4342a0424b3d99d878a4e5a12 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:50 2016 +0800 drm: bridge: analogix/dp: Fix the possible dead lock in bridge disable time It may caused a dead lock if we flush the hpd work in bridge disable time. The normal flow would like: IN --> DRM IOCTL 1. Acquire crtc_ww_class_mutex (DRM IOCTL) IN --> analogix_dp_bridge 2. Acquire hpd work lock (Flush hpd work) 3. HPD work already in idle, no need to run the work function. OUT <-- analogix_dp_bridge OUT <-- DRM IOCTL The dead lock flow would like: IN --> DRM IOCTL 1. Acquire crtc_ww_class_mutex (DRM IOCTL) IN --> analogix_dp_bridge 2. Acquire hpd work lock (Flush hpd work) IN --> analogix_dp_hotplug IN --> drm_helper_hpd_irq_event 3. Acquire mode_config lock (This lock already have been acquired in previous step 1) ** Dead Lock Now ** It's wrong to flush the hpd work in bridge->disable time, I guess the original code just want to ensure the delay work must be finish before encoder disabled. The flush work in bridge disable time is try to ensure the HPD event won't be missed before display card disabled, actually we can take a fast respond way(interrupt thread) to update DRM HPD event to fix the delay update and possible dead lock. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 62 ++++++++++------------ drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 3 +- drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 26 +++++++++ 3 files changed, 55 insertions(+), 36 deletions(-) commit 211f276ed3d96e964d2d1106a198c7f4a4b3f4c0 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:37 2016 +0800 drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time Turn off the panel power in suspend time would help to reduce power waste. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 398a39953493e859d22ac4bece0f4542a3797053 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:29 2016 +0800 drm: bridge: analogix/dp: add edid modes parse in get_modes method Display Port monitor could support kinds of mode which indicate in monitor edid, not just one single display resolution which defined in panel or devivetree property display timing. Note: Gustavo Padovan try to remove the controller and phy power on function in bind time at bellow commit: drm/exynos: do not start enabling DP at bind() phase But for now driver need to read edid message in .get_modes() function, so controller must be inited in bind time, so we need to add controller init back. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 17 ++++---- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 46 +++++++++++----------- 2 files changed, 33 insertions(+), 30 deletions(-) commit 2b77a2918c5d7b0b6bc2f8b35ddc299cf9bfe401 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:20 2016 +0800 drm: bridge: analogix/dp: move hpd detect to connector detect function This change just make a little clean to make code more like drm core expect, move hdp detect code from bridge->enable(), and place them into connector->detect(). Note: Gustavo Padovan try to remove the controller and phy power on function in bind time at bellow commit: drm/exynos: do not start enabling DP at bind() phase But for now the connector status don't hardcode to connected, need to operate dp phy in .detect function, so we need to revert parts if Gustavo Padovan's changes, add phy poweron function in bind time. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 38 ++++++++++++---------- 1 file changed, 20 insertions(+), 18 deletions(-) commit 5cff007c58b7103a7d6bb203a74eb3eb416c10e0 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:15 2016 +0800 drm: bridge: analogix/dp: try force hpd after plug in lookup failed Some edp screen do not have hpd signal, so we can't just return failed when hpd plug in detect failed. This is an hardware property, so we need add a devicetree property "analogix,need-force-hpd" to indicate this sutiation. Acked-by: Rob Herring <robh@kernel.org> Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> .../bindings/display/bridge/analogix_dp.txt | 4 ++- .../bindings/display/exynos/exynos_dp.txt | 1 + .../display/rockchip/analogix_dp-rockchip.txt | 1 + drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 35 ++++++++++++++++++---- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 2 ++ drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 9 ++++++ 6 files changed, 46 insertions(+), 6 deletions(-) commit 0d0abd894ead85d20d7febe603f570d4fdd8111a Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:11:05 2016 +0800 drm: bridge: analogix/dp: add max link rate and lane count limit for RK3288 There are some IP limit on rk3288 that only support 4 physical lanes of 2.7/1.6 Gbps/lane, so seprate them out by device_type flag. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 33 ++++++++++++++-------- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 4 +-- 2 files changed, 23 insertions(+), 14 deletions(-) commit bcec20fd5ad63ea03427c40027b33c7fd995c8bc Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:54 2016 +0800 drm: bridge: analogix/dp: add some rk3288 special registers setting RK3288 need some special registers setting, we can separate them out by the dev_type of plat_data. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 76 ++++++++++++++--------- drivers/gpu/drm/bridge/analogix/analogix_dp_reg.h | 12 ++++ 2 files changed, 60 insertions(+), 28 deletions(-) commit be91c36247089d41fd76cd51d338203de65294ff Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:48 2016 +0800 dt-bindings: add document for rockchip variant of analogix_dp Rockchip DP driver is a helper driver of analogix_dp coder driver, so most of the DT property should be descriped in analogix_dp document. Acked-by: Rob Herring <robh@kernel.org> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> .../display/rockchip/analogix_dp-rockchip.txt | 91 ++++++++++++++++++++++ 1 file changed, 91 insertions(+) commit 9e32e16e9e989f2c4a11b377c5ed3e1c7be16cfb Author: Yakir Yang <ykk@rock-chips.com> Date: Tue Mar 29 09:57:30 2016 +0800 drm: rockchip: dp: add rockchip platform dp driver Rockchip have three clocks for dp controller, we leave pclk_edp to analogix_dp driver control, and keep the sclk_edp_24m and sclk_edp in platform driver. Acked-by: Mark Yao <mark.yao@rock-chips.com> Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/gpu/drm/rockchip/Kconfig | 9 + drivers/gpu/drm/rockchip/Makefile | 1 + drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 384 ++++++++++++++++++++++++ include/drm/bridge/analogix_dp.h | 1 + 4 files changed, 395 insertions(+) commit 12315576b31990858a1952ad78ba86f516e6e4b5 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:31 2016 +0800 ARM: dts: exynos/dp: remove some properties that deprecated by analogix_dp driver After exynos_dp have been split the common IP code into analogix_dp driver, the analogix_dp driver have deprecated some Samsung platform properties which could be dynamically parsed from EDID/MODE/DPCD message, so this is an update for Exynos DTS file for dp-controller. Beside the backward compatibility is fully preserved, so there are no bisectability break that make this change in a separate patch. Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> arch/arm/boot/dts/exynos5250-arndale.dts | 2 -- arch/arm/boot/dts/exynos5250-smdk5250.dts | 2 -- arch/arm/boot/dts/exynos5250-snow-common.dtsi | 4 +--- arch/arm/boot/dts/exynos5250-spring.dts | 4 +--- arch/arm/boot/dts/exynos5420-peach-pit.dts | 4 +--- arch/arm/boot/dts/exynos5420-smdk5420.dts | 2 -- arch/arm/boot/dts/exynos5800-peach-pi.dts | 2 -- 7 files changed, 3 insertions(+), 17 deletions(-) commit 704330615bfdb8ec9e21cabfd462e785007593ba Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:26 2016 +0800 dt-bindings: add document for analogix display port driver Analogix dp driver is split from exynos dp driver, so we just make an copy of exynos_dp.txt, and then simplify exynos_dp.txt Beside update some exynos dtsi file with the latest change according to the devicetree binding documents. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Yakir Yang <ykk@rock-chips.com> .../bindings/display/bridge/analogix_dp.txt | 50 ++++++++++++ .../bindings/display/exynos/exynos_dp.txt | 92 ++++++---------------- 2 files changed, 76 insertions(+), 66 deletions(-) commit 793ce4eb84ea2f2c3ebb97aab1ba8a4ce0561812 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:11 2016 +0800 drm: bridge: analogix/dp: dynamic parse sync_pol & interlace & dynamic_range Both hsync/vsync polarity and interlace mode can be parsed from drm display mode, and dynamic_range and ycbcr_coeff can be judge by the video code. But presumably Exynos still relies on the DT properties, so take good use of mode_fixup() in to achieve the compatibility hacks. Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 148 +++++++++++++-------- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 2 +- drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 14 +- 3 files changed, 103 insertions(+), 61 deletions(-) commit 40fc7ce7db770e9e05032be5eefc183690afb5b8 Author: Yakir Yang <ykk@rock-chips.com> Date: Mon Feb 15 19:10:04 2016 +0800 drm: bridge: analogix/dp: remove duplicate configuration of link rate and link count link_rate and lane_count already configured in analogix_dp_set_link_train(), so we don't need to config those repeatly after training finished, just remove them out. Beside Display Port 1.2 already support 5.4Gbps link rate, the maximum sets would change from {1.62Gbps, 2.7Gbps} to {1.62Gbps, 2.7Gbps, 5.4Gbps}. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 14 +++++++------- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 7 +------ drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 2 +- 3 files changed, 9 insertions(+), 14 deletions(-) commit bcbb7033acf9cea100fb9ea6cd9ff5a7a279d16a Author: Yakir Yang <ykk@rock-chips.com> Date: Tue Mar 29 09:57:19 2016 +0800 drm: bridge: analogix/dp: fix some obvious code style Fix some obvious alignment problems, like alignment and line over 80 characters problems, make this easy to be maintained later. Acked-by: Jingoo Han <jingoohan1@gmail.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 129 ++++++++++----------- drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 72 ++++++------ drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 124 ++++++++++---------- drivers/gpu/drm/exynos/exynos_dp.c | 4 +- 4 files changed, 165 insertions(+), 164 deletions(-) commit 092f899420c9e8c5e90a9babe514731d716bd506 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Feb 15 19:09:54 2016 +0800 drm: bridge: analogix/dp: rename register constants In the original split we kept the register constants intact to keep the diff small. Still the constants are Analogix-specific, so rename them now. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 456 +++++++++++----------- drivers/gpu/drm/bridge/analogix/analogix_dp_reg.h | 248 ++++++------ 2 files changed, 352 insertions(+), 352 deletions(-) commit 59c0ef315d3b7f7249439069531383c5bef3ef2f Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Feb 15 19:09:46 2016 +0800 drm/exynos: dp: rename implementation specific driver part The core functionality now resides in the generic bridge part so the exynos-specific implementation details can get a more suitable nameing. Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Yakir Yang <ykk@rock-chips.com> drivers/gpu/drm/exynos/Makefile | 2 +- drivers/gpu/drm/exynos/exynos_dp.c | 314 ++++++++++++++++++++++++++++++++ drivers/gpu/drm/exynos/exynos_dp_core.c | 314 -------------------------------- 3 files changed, 315 insertions(+), 315 deletions(-) commit 3424e3a4f844c0a62128feb388d04ed6b65f6b20 Author: Yakir Yang <ykk@rock-chips.com> Date: Tue Mar 29 09:57:03 2016 +0800 drm: bridge: analogix/dp: split exynos dp driver to bridge directory Split the dp core driver from exynos directory to bridge directory, and rename the core driver to analogix_dp_*, rename the platform code to exynos_dp. Beside the new analogix_dp driver would export six hooks. "analogix_dp_bind()" and "analogix_dp_unbind()" "analogix_dp_suspned()" and "analogix_dp_resume()" "analogix_dp_detect()" and "analogix_dp_get_modes()" The bind/unbind symbols is used for analogix platform driver to connect with analogix_dp core driver. And the detect/get_modes is used for analogix platform driver to init the connector. They reason why connector need register in helper driver is rockchip drm haven't implement the atomic API, but Exynos drm have implement it, so there would need two different connector helper functions, that's why we leave the connector register in helper driver. Acked-by: Inki Dae <inki.dae@samsung.com> Tested-by: Caesar Wang <wxt@rock-chips.com> Tested-by: Douglas Anderson <dianders@chromium.org> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Yakir Yang <ykk@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/gpu/drm/bridge/Kconfig | 2 + drivers/gpu/drm/bridge/Makefile | 1 + drivers/gpu/drm/bridge/analogix/Kconfig | 3 + drivers/gpu/drm/bridge/analogix/Makefile | 2 + drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 1351 +++++++++++++++++++ drivers/gpu/drm/bridge/analogix/analogix_dp_core.h | 277 ++++ drivers/gpu/drm/bridge/analogix/analogix_dp_reg.c | 1263 ++++++++++++++++++ drivers/gpu/drm/bridge/analogix/analogix_dp_reg.h | 366 ++++++ drivers/gpu/drm/exynos/Kconfig | 3 +- drivers/gpu/drm/exynos/Makefile | 2 +- drivers/gpu/drm/exynos/exynos_dp_core.c | 1353 ++------------------ drivers/gpu/drm/exynos/exynos_dp_core.h | 282 ---- drivers/gpu/drm/exynos/exynos_dp_reg.c | 1263 ------------------ drivers/gpu/drm/exynos/exynos_dp_reg.h | 366 ------ include/drm/bridge/analogix_dp.h | 40 + 15 files changed, 3392 insertions(+), 3182 deletions(-) commit 15f41e2ba13a6726632e44b1180e805a61e470ad Merge: 43e2dfb 4ce7e93 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 4 22:11:21 2016 -0400 Merge branch 'tcp-udp-misc' Eric Dumazet says: ==================== net: various udp/tcp changes First round of patches for linux-4.7 Add a generic facility for sockets to be freed after an RCU grace period, if they need to. Then UDP stack is changed to no longer use SLAB_DESTROY_BY_RCU, in order to speedup rx processing for traffic encapsulated in UDP. It gives a 17 % speedup for normal UDP reception in stress conditions. Then TCP listeners are changed to use SOCK_RCU_FREE as well to avoid touching sk_refcnt in synflood case : I got up to 30 % performance increase for a mono listener. Then three patches add SK_MEMINFO_DROPS to sock_diag and add per socket rx drops accounting to TCP. Last patch adds rate limiting on ACK sent on behalf of SYN_RECV to better resist to SYNFLOOD targeting one or few flows. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 4ce7e93cb3fe87db5b700050172dc41def9834b3 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:22 2016 -0700 tcp: rate limit ACK sent by SYN_RECV request sockets Attackers like to use SYNFLOOD targeting one 5-tuple, as they hit a single RX queue (and cpu) on the victim. If they use random sequence numbers in their SYN, we detect they do not match the expected window and send back an ACK. This patch adds a rate limitation, so that the effect of such attacks is limited to ingress only. We roughly double our ability to absorb such attacks. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Willem de Bruijn <willemb@google.com> Cc: Neal Cardwell <ncardwell@google.com> Cc: Maciej Żenczykowski <maze@google.com> Acked-by: Neal Cardwell <ncardwell@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_minisocks.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit a9d6532b567489196dac4ce60c62343e43228759 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:21 2016 -0700 ipv4: tcp: set SOCK_USE_WRITE_QUEUE for ip_send_unicast_reply() TCP uses per cpu 'sockets' to send some packets : - RST packets ( tcp_v4_send_reset()) ) - ACK packets for SYN_RECV and TIMEWAIT sockets By setting SOCK_USE_WRITE_QUEUE flag, we tell sock_wfree() to not call sk_write_space() since these internal sockets do not care. This gives a small performance improvement, merely by allowing cpu to properly predict the sock_wfree() conditional branch, and avoiding one atomic operation. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/tcp_ipv4.c | 1 + 1 file changed, 1 insertion(+) commit 9caad864151e525929d323de96cad382da49c3b2 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:20 2016 -0700 tcp: increment sk_drops for listeners Goal: packets dropped by a listener are accounted for. This adds tcp_listendrop() helper, and clears sk_drops in sk_clone_lock() so that children do not inherit their parent drop count. Note that we no longer increment LINUX_MIB_LISTENDROPS counter when sending a SYNCOOKIE, since the SYN packet generated a SYNACK. We already have a separate LINUX_MIB_SYNCOOKIESSENT Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 13 +++++++++++++ net/core/sock.c | 1 + net/ipv4/tcp_input.c | 8 +++++--- net/ipv4/tcp_ipv4.c | 6 +++--- net/ipv6/tcp_ipv6.c | 4 ++-- 5 files changed, 24 insertions(+), 8 deletions(-) commit 532182cd610782db8c18230c2747626562032205 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:19 2016 -0700 tcp: increment sk_drops for dropped rx packets Now ss can report sk_drops, we can instruct TCP to increment this per socket counter when it drops an incoming frame, to refine monitoring and debugging. Following patch takes care of listeners drops. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 7 +++++++ net/ipv4/tcp_input.c | 33 ++++++++++++++++++++------------- net/ipv4/tcp_ipv4.c | 1 + net/ipv6/tcp_ipv6.c | 1 + 4 files changed, 29 insertions(+), 13 deletions(-) commit 15239302edd46b184e758048253541fb211e315e Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:18 2016 -0700 sock_diag: add SK_MEMINFO_DROPS Reporting sk_drops to user space was available for UDP sockets using /proc interface. Add this to sock_diag, so that we can have the same information available to ss users, and we'll be able to add sk_drops indications for TCP sockets as well. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/uapi/linux/sock_diag.h | 1 + net/core/sock_diag.c | 1 + 2 files changed, 2 insertions(+) commit 3b24d854cb35383c30642116e5992fd619bdc9bc Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:17 2016 -0700 tcp/dccp: do not touch listener sk_refcnt under synflood When a SYNFLOOD targets a non SO_REUSEPORT listener, multiple cpus contend on sk->sk_refcnt and sk->sk_wmem_alloc changes. By letting listeners use SOCK_RCU_FREE infrastructure, we can relax TCP_LISTEN lookup rules and avoid touching sk_refcnt Note that we still use SLAB_DESTROY_BY_RCU rules for other sockets, only listeners are impacted by this change. Peak performance under SYNFLOOD is increased by ~33% : On my test machine, I could process 3.2 Mpps instead of 2.4 Mpps Most consuming functions are now skb_set_owner_w() and sock_wfree() contending on sk->sk_wmem_alloc when cooking SYNACK and freeing them. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/inet6_hashtables.h | 12 ++++--- include/net/inet_hashtables.h | 40 ++++++++++++++--------- net/dccp/ipv4.c | 7 ++-- net/dccp/ipv6.c | 7 ++-- net/ipv4/inet_diag.c | 3 +- net/ipv4/inet_hashtables.c | 73 +++++++++++++++--------------------------- net/ipv4/tcp_ipv4.c | 66 +++++++++++++++++++------------------- net/ipv6/inet6_hashtables.c | 56 +++++++++----------------------- net/ipv6/tcp_ipv6.c | 27 +++++++++------- net/netfilter/xt_socket.c | 6 ++-- 10 files changed, 134 insertions(+), 163 deletions(-) commit 3a5d1c0e7cb5ba91aabbd7e28626e3cc925f8093 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:16 2016 -0700 inet: reqsk_alloc() needs to take care of dead listeners We'll soon no longer take a refcount on listeners, so reqsk_alloc() can not assume a listener refcount is not zero. We need to use atomic_inc_not_zero() Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/request_sock.h | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) commit 2d331915a04144dad738e725769d8fac06ef6155 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:15 2016 -0700 tcp/dccp: use rcu locking in inet_diag_find_one_icsk() RX packet processing holds rcu_read_lock(), so we can remove pairs of rcu_read_lock()/rcu_read_unlock() in lookup functions if inet_diag also holds rcu before calling them. This is needed anyway as __inet_lookup_listener() and inet6_lookup_listener() will soon no longer increment refcount on the found listener. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/inet_diag.c | 7 +++++-- net/ipv4/inet_hashtables.c | 4 ---- net/ipv6/inet6_hashtables.c | 4 ---- 3 files changed, 5 insertions(+), 10 deletions(-) commit ee3cf32a4a5e6cf5ccc0f0de9865fda3ebc46436 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:14 2016 -0700 tcp/dccp: remove BH disable/enable in lookup Since linux 2.6.29, lookups only use rcu locking. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/inet_hashtables.h | 7 +------ net/ipv6/inet6_hashtables.c | 2 -- 2 files changed, 1 insertion(+), 8 deletions(-) commit ca065d0cf80fa547724440a8bf37f1e674d917c0 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:13 2016 -0700 udp: no longer use SLAB_DESTROY_BY_RCU Tom Herbert would like not touching UDP socket refcnt for encapsulated traffic. For this to happen, we need to use normal RCU rules, with a grace period before freeing a socket. UDP sockets are not short lived in the high usage case, so the added cost of call_rcu() should not be a concern. This actually removes a lot of complexity in UDP stack. Multicast receives no longer need to hold a bucket spinlock. Note that ip early demux still needs to take a reference on the socket. Same remark for functions used by xt_socket and xt_PROXY netfilter modules, but this might be changed later. Performance for a single UDP socket receiving flood traffic from many RX queues/cpus. Simple udp_rx using simple recvfrom() loop : 438 kpps instead of 374 kpps : 17 % increase of the peak rate. v2: Addressed Willem de Bruijn feedback in multicast handling - keep early demux break in __udp4_lib_demux_lookup() Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Tom Herbert <tom@herbertland.com> Cc: Willem de Bruijn <willemb@google.com> Tested-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/linux/udp.h | 8 +- include/net/sock.h | 12 +-- include/net/udp.h | 2 +- net/ipv4/udp.c | 293 ++++++++++++++++------------------------------------ net/ipv4/udp_diag.c | 18 ++-- net/ipv6/udp.c | 196 ++++++++++++----------------------- 6 files changed, 171 insertions(+), 358 deletions(-) commit a4298e4522d687a79af8f8fbb7eca68399ab2d81 Author: Eric Dumazet <edumazet@google.com> Date: Fri Apr 1 08:52:12 2016 -0700 net: add SOCK_RCU_FREE socket flag We want a generic way to insert an RCU grace period before socket freeing for cases where RCU_SLAB_DESTROY_BY_RCU is adding too much overhead. SLAB_DESTROY_BY_RCU strict rules force us to take a reference on the socket sk_refcnt, and it is a performance problem for UDP encapsulation, or TCP synflood behavior, as many CPUs might attempt the atomic operations on a shared sk_refcnt UDP sockets and TCP listeners can set SOCK_RCU_FREE so that their lookup can use traditional RCU rules, without refcount changes. They can set the flag only once hashed and visible by other cpus. Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Tom Herbert <tom@herbertland.com> Tested-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 2 ++ net/core/sock.c | 14 +++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) commit 43e2dfb23eb8f3698718ec1e3936c76912de1c30 Merge: 6e33804 0c5a616 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 4 22:01:44 2016 -0400 Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue Jeff Kirsher says: ==================== 10GbE Intel Wired LAN Driver Updates 2016-04-04 This series contains updates to ixgbe and ixgbevf. Pavel Tikhomirov fixes a typo where we were incrementing transmit stats instead of receive stats on the receive side. Emil updates the ixgbevf driver to use bit operations for setting and checking the adapter state. Chas Williams adds the new NDO trust feature check so that the VF guest has the ability to set the unicast address of the interface, if it is a trusted VF. Alex cleans up the driver to that the only time we add a PF entry to the VLVF is either for VLAN 0 or if the PF has requested a VLAN that a VF is already using. Also adds support for generic transmit checksums, giving the added advantage is that we can support inner checksum offloads for tunnels and MPLS while still being able to transparently insert VLAN tags. Lastly, changed ixgbe so that we can use the ethtool rx-vlan-filter flag to toggle receive VLAN filtering on and off. Mark cleans up the ixgbe driver by making all op structures that do not change constants. Also fixed flow control for Xeon D KR backplanes, since we cannot use auto-negotiation to determine the mode, we have to use whatever the user configured. Sowmini Varadhan updates ixgbe to use eth_platform_get_mac_address() instead of the arch specific solution that was added by a previous commit. Don fixed an issue where it was possible that a system reset could occur when we were holding the SWFW semaphore lock, which the next time the driver loaded would see it incorrectly as locked. v2: updated patch 8 of the series to include a minor flags issue where we had lost NETIF_F_HW_TC and we were setting NETIF_F_SCTP_CRC in two different areas, when we only needed/wanted it in one spot. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 8804f2525a56261b93576a1900185ac2691d138a Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:42:01 2016 +0800 ACPICA: Update version to 20160318 ACPICA commit e714615fda31cce3df9cfd95ee03c1f2c74b2b5e Version 20160318. Link: https://github.com/acpica/acpica/commit/e714615f Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/acpixf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d3349de8072baf2c2dd096664fa818d5339bb5a Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:54 2016 +0800 ACPICA: Namespace: Reorder \_SB._INI to make sure it is evaluated before _REG evaluations ACPICA commit f005ee6b90d152c1f499efcca6b771a93903cb55 This patch splits \_SB._INI evaluation from device initialization code, so that it can be performed before PCI_Config _REG evaluations. This is required for the device enumeration process. Some named objects are initialized in \_SB._INI and PCI_Config _REG evaluations may use uninitialized named objects because of the order issue. This must be fixed before fixing ECDT order issue. There are existing tables allowing ECDT EC to be used for the entire device enumeration process, but the enabling of ECDT EC is done in \_SB._INI. Thus \_SB._INI must be the first control method evaluated in the device enumeration process. Normally, the order should be automatically ensured by the device enumeration process itself (for example, PCI_Config _REGs are evaluated by the PCI bus driver when the driver is probed by the enumeration process), but since the process is split on Linux (partially done in Linux, partially done in ACPICA), we need to ensure this with special logics in order to be regression safe. Lv Zheng. Link: https://github.com/acpica/acpica/commit/f005ee6b Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/nsinit.c | 75 +++++++++++++++++++++++++++++++------------- 1 file changed, 54 insertions(+), 21 deletions(-) commit d1461a1b506e4a2df9f703c5f39f765b65c9672e Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:47 2016 +0800 ACPICA: Events: Fix an issue that _REG association can happen before namespace is initialized ACPICA commit c508f8592efaa0d8197f26d7fee6382c5ac8e383 Current code flow cannot ensure _REG association can happen after the namespace is initialized, so we move _REG association to where _REG was about to run to fix this issue. This issue is detected when acpi_ev_initialize_region() is invoked during the table loading. And this is one of the most important the root cause why ACPICA table loading is split into 2 load passes. Lv Zheng. Link: https://github.com/acpica/acpica/commit/c508f859 Link: https://bugs.acpica.org/show_bug.cgi?id=1252 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acevents.h | 2 -- drivers/acpi/acpica/evregion.c | 71 ++++++++++++++---------------------------- drivers/acpi/acpica/evrgnini.c | 1 - 3 files changed, 24 insertions(+), 50 deletions(-) commit ca4fc02714f046cbdc8c0ee4af6733b6231e57dc Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:39 2016 +0800 ACPICA: Tables: Fix wrong MLC condition for dynamic table loading ACPICA commit 5798cd6171ea38bcf4594d0ccc78870784776ba5 The patch corrects wrong condition before group MLC is disabled. Link: https://github.com/acpica/acpica/commit/5798cd61 Link: https://bugs.acpica.org/show_bug.cgi?id=1262 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/exconfig.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 78542058f522076c888822735d8fc9bd93cfd586 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:32 2016 +0800 ACPICA: Interpreter: Fix wrong conditions for acpi_ev_install_region_handlers() invocation ACPICA commit 9a6ecc9ec9ee067cad51eec539230bf494421d76 Since AE_ALREADY_EXISTS has already been converted to AE_OK in acpi_ev_install_region_handlers(), this patch simplies a return value check. Lv Zheng. Link: https://github.com/acpica/acpica/commit/9a6ecc9e Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/tbxfload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 920de6ebfab865a5bb2bcc60f6998aa270300b95 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:09 2016 +0800 ACPICA: Hardware: Enhance acpi_hw_validate_register() with access_width/bit_offset awareness ACPICA commit 997a90f810a4cb78604ef2e187611a181b498286 This patch enhances acpi_hw_validate_register() to sanitize register accesses with awareness of access_width and bit_offset. Lv Zheng. Link: https://github.com/acpica/acpica/commit/997a90f8 Link: https://bugs.acpica.org/show_bug.cgi?id=1240 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/hwregs.c | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) commit 0461f34e16b39b083f289d27d2355df9d5ba1420 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:41:02 2016 +0800 Utilities: Fix missing parentheses in ACPI_GET_BITS()/ACPI_SET_BITS() Some compilers require parentheses to be enforced in the macro definition, so that the macro caller side can be simpler. This patch fixes this kind of macro issue in ACPI_SET_BITS()/ACPI_GET_BITS(). Lv Zheng. Link: https://bugs.acpica.org/show_bug.cgi?id=1268 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acmacros.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a8d1e1c063b0b1c91a9415f5cb09e37a75bce809 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:40:56 2016 +0800 ACPICA: Utilities: Add ACPI_IS_POWER_OF_TWO() ACPICA commit cbcb77565c5032dd48e19b3a8a8b8704c5f29faf This patch adds a macro ACPI_IS_POWER_OF_TWO, which can be used to detect if a number is a power of two. Lv Zheng. Link: https://github.com/acpica/acpica/commit/cbcb7756 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acmacros.h | 4 ++++ 1 file changed, 4 insertions(+) commit 7447bc1e69bafab72ef69a7f054bb1e5f9ff908d Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:48 2016 +0800 ACPICA: iASL/Disassembler: Improve handling of unresolved methods ACPICA commit 16cd0872a070c8d3b16b8b13c1fc90a443a6b6fe If the definition of a control method cannot be found (probably it is in another module/SSDT), the disassembler must try to guess at the number of arguments to that method. This change improves the guessing heuristic. Link: https://github.com/acpica/acpica/commit/16cd0872 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/aclocal.h | 1 + 1 file changed, 1 insertion(+) commit 0dfaaa3d51df011c16279bb010bff90f45b6d62c Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:40 2016 +0800 ACPICA: All: const keyword changes across the ACPICA source ACPICA commit a240cbb93647bddf525b3daf6e9d31b8b9bca34e Integrated most changes proposed by net_BSD. >From joerg@net_BSD.org (Joerg Sonnenberger) ACPICA BZ 732. Link: https://github.com/acpica/acpica/commit/a240cbb9 Link: https://bugs.acpica.org/show_bug.cgi?id=732 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acdebug.h | 4 ++-- drivers/acpi/acpica/acglobal.h | 2 ++ drivers/acpi/acpica/acinterp.h | 2 +- drivers/acpi/acpica/acnamesp.h | 5 +++-- drivers/acpi/acpica/acparser.h | 2 +- drivers/acpi/acpica/acresrc.h | 4 ++-- drivers/acpi/acpica/acstruct.h | 2 +- drivers/acpi/acpica/acutils.h | 14 +++++++----- drivers/acpi/acpica/dbinput.c | 13 ++++++----- drivers/acpi/acpica/dbutils.c | 9 ++++---- drivers/acpi/acpica/evregion.c | 3 ++- drivers/acpi/acpica/exdump.c | 15 ++++++------- drivers/acpi/acpica/hwxface.c | 4 +--- drivers/acpi/acpica/nsaccess.c | 7 +++--- drivers/acpi/acpica/nsdump.c | 9 ++++++-- drivers/acpi/acpica/psopinfo.c | 2 +- drivers/acpi/acpica/rsdump.c | 50 ++++++++++++++++++------------------------ drivers/acpi/acpica/rsutils.c | 2 +- drivers/acpi/acpica/tbfadt.c | 8 +++---- drivers/acpi/acpica/utdebug.c | 47 +++++++++++++++++++-------------------- drivers/acpi/acpica/uteval.c | 4 ++-- drivers/acpi/acpica/utglobal.c | 5 +++++ drivers/acpi/acpica/utmisc.c | 2 +- drivers/acpi/acpica/utprint.c | 5 ----- drivers/acpi/acpica/uttrack.c | 2 +- include/acpi/actypes.h | 4 ++-- 26 files changed, 113 insertions(+), 113 deletions(-) commit 3a05be7575a46cf3b16abb77e1072afa13307a1b Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:33 2016 +0800 ACPICA: Utilities: Update for strtoul64 merger ACPICA commit 795e136d2ac77c1c8b091fba019b5fe36a44a323 Fixes a problem with the merger of the two internal versions of this function. Make the maximum integer width (32-bit or 64-bit) a parameter to the function so that it no longer exclusively uses the integer width specified in the DSDT/SSDT. ACPICA BZ 1260 Link: https://github.com/acpica/acpica/commit/795e136d Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acutils.h | 9 ++++- drivers/acpi/acpica/dbconvert.c | 4 +- drivers/acpi/acpica/exconvrt.c | 4 +- drivers/acpi/acpica/nsconvert.c | 3 +- drivers/acpi/acpica/utnonansi.c | 67 ++++++++++++++++++-------------- tools/power/acpi/tools/acpidump/apdump.c | 3 +- tools/power/acpi/tools/acpidump/apmain.c | 3 +- 7 files changed, 57 insertions(+), 36 deletions(-) commit 53c78d75d8a4615e5c2f1d9fe94f25e049f0e61b Author: Will Miles <wmiles@sgl.com> Date: Thu Mar 24 09:40:26 2016 +0800 ACPICA: Add support for QNX 6.6 platform ACPICA commit 37a1dec2391272251e59948c16c60713183ae78f Link: https://github.com/acpica/acpica/commit/37a1dec2 Signed-off-by: Will Miles <wmiles@sgl.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/platform/acenv.h | 3 +++ tools/power/acpi/os_specific/service_layers/osunixmap.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) commit 95df7b5e4c9c7a6b1e75d7bbc16ac19ee2784379 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:19 2016 +0800 ACPICA: Headers: Update generation of the ACPICA library ACPICA commit 0af0f9092dcc3db6c05875eae68965fda333ad7f For windows only, ensure that debug output is disabled for the "release" (non-debug) case. Link: https://github.com/acpica/acpica/commit/0af0f909 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/platform/acenv.h | 41 +++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 20 deletions(-) commit 2156510f300f9ac70a024994acb5235ebd4ee087 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:12 2016 +0800 ACPICA: Cleanup some invocation indentations, no functional change ACPICA commit 9ed98dc36645aaeba11967722951156650d94f47 For consistency, cleanup function invocations. Link: https://github.com/acpica/acpica/commit/9ed98dc3 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/nsprepkg.c | 6 ++++++ 1 file changed, 6 insertions(+) commit fe0f8765dfd224775db1df9b878bfeb6121cbe6c Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:40:05 2016 +0800 ACPICA: iASL: Cleanup/optimization for ToPLD macro support ACPICA commit 0e6125401cf38427d5376f4bafbfb3d5a40f8467 Use local variables for access to string/value Op fields. Move duplicate PLD string tables to a single common table. Link: https://github.com/acpica/acpica/commit/0e612540 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acglobal.h | 9 +++++++++ drivers/acpi/acpica/utglobal.c | 43 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 52 insertions(+) commit d8aa069a35b40150abb00658be91dcb284648a04 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:58 2016 +0800 ACPICA: Interpreter: Update some function headers, no functional change ACPICA commit e068948f49eb61a78c211028976a174604c5644a Fix some issues in the exutils.c file. Link: https://github.com/acpica/acpica/commit/e068948f Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/exutils.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 890b090ef5ab6f0a125b8668c49d734442333d3c Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:51 2016 +0800 ACPICA: Intepreter: Add object extensions to Concatenate operand ACPICA commit 60d9cfd403a9824199b971597c930f6f563e5c71 Allows all object types to be used with Concatenate. Objects other than Int/Str/Buf are convert to a string that contains the type of the object. Improves the utility of the Printf and Fprintf macros. Adds a new file, exconcat.c Link: https://github.com/acpica/acpica/commit/60d9cfd4 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/Makefile | 1 + drivers/acpi/acpica/exconcat.c | 439 +++++++++++++++++++++++++++++++++++++++++ drivers/acpi/acpica/exmisc.c | 290 --------------------------- 3 files changed, 440 insertions(+), 290 deletions(-) commit 28a9a69bdf36f639df9820592eb2ce2e99002338 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:44 2016 +0800 ACPICA: iASL/Headers: Fix incorrect definition of FPDT table ACPICA commit f30ba83711bcb860f9b17dd36d0bcc5242a4ef91 ACPICA BZ 1249. Link: https://github.com/acpica/acpica/commit/f30ba837 Link: https://bugs.acpica.org/show_bug.cgi?id=1249 Reported-by: Greg Elkin <greg.elkin@ericsson.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl3.h | 43 ++++++++++++++++++++++++------------------- 1 file changed, 24 insertions(+), 19 deletions(-) commit a88e0ce6beffb5ba1df8930f2f0112024f2a215e Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:36 2016 +0800 ACPICA: ACPI 6.1: Add full support for this version of ACPI spec ACPICA commit 5f21bddaa2cec035ca80608803ce2f0858d4f387 Small changes: 1) A couple new predefined names 2) New _HID values 3) New subtable for HEST Link: https://github.com/acpica/acpica/commit/5f21bdda Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/acpredef.h | 9 +++++++++ drivers/acpi/acpica/utdecode.c | 30 +++++++++++++++++------------- include/acpi/actbl1.h | 6 ++++-- include/acpi/actypes.h | 3 ++- 4 files changed, 32 insertions(+), 16 deletions(-) commit b94cd8118c057933127f28e9a3bc79cc92de9714 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:28 2016 +0800 ACPICA: Tables: Update FADT handling ACPICA commit bca0c4cb063ee488c543e6f160fe89679a2338d6 Update a warning message simplify versioning for "table too big" case. Link: https://github.com/acpica/acpica/commit/bca0c4cb Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/tbfadt.c | 18 +++++++++++------- include/acpi/actbl.h | 4 +++- 2 files changed, 14 insertions(+), 8 deletions(-) commit 3a9ca4d5f179b19919679171240e9ba3ea0c5df9 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:21 2016 +0800 ACPICA: Headers: Update DMAR table for October 2014 I/O spec ACPICA commit 454b2ea5f0c254e97612e15994f7d4734a7931ea Adds two flags to the DMAR table. Link: https://github.com/acpica/acpica/commit/454b2ea5 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl2.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 138a95547ab04f5f9d49bfb12bd764f7a7edbcf4 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:39:14 2016 +0800 ACPICA: ACPI 6.1: Update NFIT table for additional new fields ACPICA commit bc81a4494d7648a496e0a82f0d27562103ee1ec1 Changes the NFIT Control Region. Link: https://github.com/acpica/acpica/commit/bc81a449 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl1.h | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 4ac78baf88d85c49883fcc87d31198ebe408e54d Author: Al Stone <ahs3@redhat.com> Date: Thu Mar 24 09:39:07 2016 +0800 ACPICA: IORT: Add in support for the SMMUv3 subtable ACPICA commit 9f7c3e148f440049615e2791d73b292f65692d7e The most recent version of the IORT specification adds in a definition for a subtable to describe SMMUv3 devices; there is already a subtable for SMMUv1/v2 devices. Add in the definition of the subtable, add in the code to compile it, and add in a template for it. Link: https://github.com/acpica/acpica/commit/9f7c3e14 Signed-off-by: Al Stone <ahs3@redhat.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl2.h | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) commit 7cd55c76f35ffb9aa0a3062be0e3b2f66babfcd0 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:38:57 2016 +0800 ACPICA: ACPI 6.1: Updates for the HEST ACPI table ACPICA commit 7e81afb625f5184000713de2b1f280e73251bc03 Additional structure for the generic error entry. Some additional constants/flags. With assistance from Abdulhamid, Harb <harba@codeaurora.org> Link: https://github.com/acpica/acpica/commit/7e81afb6 Reviewed-by: Harb Abdulhamid <harba@codeaurora.org> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl1.h | 54 +++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 52 insertions(+), 2 deletions(-) commit 29a3f38e4452b2ec9686927bd290a1048ab6ab07 Author: Bob Moore <robert.moore@intel.com> Date: Thu Mar 24 09:38:49 2016 +0800 ACPICA: Headers: Minor update for SPCR ACPI table ACPICA commit f3caa7f2e63be31f7fb8dbccabffbb70c29c3021 Update version number and date of specification document. Point to DBG2 table for some constants. Link: https://github.com/acpica/acpica/commit/f3caa7f2 Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl2.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit c7200ffe432c6544b373f08fab33dc8e9b92516c Author: Aleksey Makarov <aleksey.makarov@linaro.org> Date: Thu Mar 24 09:38:42 2016 +0800 ACPICA: Headers: Add new constants for the DBG2 ACPI table ACPICA commit 1607b69238df9c1b2940262a17aa94ec49033278 Link: https://github.com/acpica/acpica/commit/1607b692 Signed-off-by: Aleksey Makarov <aleksey.makarov@linaro.org>. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/actbl2.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit f1974b484f9d070623215b4f461f3420b4fbbd07 Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:38:35 2016 +0800 ACPICA: Linuxize: Remove useless platform headers Some platform headers were added to Linux during previous release cycles, but they are not useful in Linux, so drop them. Signed-off-by: Lv Zheng <lv.zheng@intel.com> [ rjw: Changelog ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> include/acpi/platform/acmsvcex.h | 54 ---------------------------------------- include/acpi/platform/acwinex.h | 49 ------------------------------------ 2 files changed, 103 deletions(-) commit 6e3380488a4769edba0da3b582bb6c070121d784 Merge: 9ef280c 26892ff Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 4 21:31:35 2016 -0400 Merge branch 'mv88e6131-hw-bridging-6185' Vivien Didelot says: ==================== net: dsa: mv88e6131: HW bridging support for 6185 All packets passing through a switch of the 6185 family are currently all directed to the CPU port. This means that port bridging is software driven. To enable hardware bridging for this switch family, we need to implement the port mapping operations, the FDB operations, and optionally the VLAN operations (for 802.1Q and VLAN filtering aware systems). However this family only has 256 FDBs indexed by 8-bit identifiers, opposed to 4096 FDBs with 12-bit identifiers for other families such as 6352. It also doesn't have dedicated FID registers for ATU and VTU operations. This patchset fixes these differences, and enable hardware bridging for 6185. Changes v1 -> v2: - Describe the different numbers of databases and prefer a feature-based logic over the current ID/family-based logic. ==================== Tested-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> commit 26892ffc80b4276f6f0d61232a769100023b38ab Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:46 2016 -0400 net: dsa: mv88e6131: enable hardware bridging By adding support for bridge operations, FDB operations, and optionally VLAN operations (for 802.1Q and VLAN filtering aware systems), the switch bridges ports correctly, the CPU is able to populate the hardware address databases, and thus hardware bridging becomes functional within the 88E6185 family of switches. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6131.c | 11 +++++++++++ 1 file changed, 11 insertions(+) commit f93dd042de08633ff481d092245f2d9b4a3cdb6a Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:45 2016 -0400 net: dsa: mv88e6xxx: map destination addresses for 6185 The 88E6185 switch also has a MapDA bit in its Port Control 2 register. When this bit is cleared, all frames are sent out to the CPU port. Set this bit to rely on address databases (ATU) hits and direct frames out of the correct ports, and thus allow hardware bridging. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 11ea809f1a74b006f08e7dad0b257e06c817f313 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:44 2016 -0400 net: dsa: mv88e6xxx: support 256 databases The 6185 family of devices has only 256 address databases. Their 8-bit FID for ATU and VTU operations are split into ATU Control and ATU/VTU Operation registers. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) commit f74df0be82d7d29747bfd68d955f4f573f9e5691 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:43 2016 -0400 net: dsa: mv88e6xxx: variable number of databases Marvell switch chips have different number of address databases. The code currently only supports models with 4096 databases. Such switch has dedicated FID registers for ATU and VTU operations. Models with fewer databases have their FID split in several registers. List them all but only support models with 4096 databases at the moment. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 38 ++++++++++++++++++++++++++++++++++---- 1 file changed, 34 insertions(+), 4 deletions(-) commit b426e5f7fe4cd7041b3d8bed58f1e60bba1d11bf Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:42 2016 -0400 net: dsa: mv88e6xxx: protect FID registers access Only switch families with 4096 address databases have dedicated FID registers for ATU and VTU operations. Factorize the access to the GLOBAL_ATU_FID register and introduce a mv88e6xxx_has_fid_reg() helper function to protect the access to GLOBAL_ATU_FID and GLOBAL_VTU_FID. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) commit 2e7bd5ef98030999eaf4bf101707e595432fc8c2 Author: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Date: Thu Mar 31 16:53:41 2016 -0400 net: dsa: mv88e6xxx: protect SID register access Introduce a mv88e6xxx_has_stu() helper to protect the access to the GLOBAL_VTU_SID register, instead of checking switch families. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/dsa/mv88e6xxx.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) commit 0c5a616650a08b766e529511348274c1914ef4bf Author: Alexander Duyck <aduyck@mirantis.com> Date: Thu Mar 10 10:01:10 2016 -0800 ixgbe: Add support for toggling VLAN filtering flag via ethtool This change makes it so that we can use the ethtool rx-vlan-filter flag to toggle Rx VLAN filtering on and off. This is basically just an extension of the existing VLAN promisc work in that it just adds support for the additional ethtool flag. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) commit 4ae7834221679bff2d7f75ba80a20673cecb38ad Author: Amritha Nambiar <amritha.nambiar@intel.com> Date: Wed Mar 9 18:32:16 2016 -0500 ixgbe: Extend cls_u32 offload to support UDP headers Added support to match on UDP fields in the transport layer. Extended core logic to support multiple headers. Verified with the following filters : handle 1: u32 divisor 1 u32 ht 800: order 1 link 1: \ offset at 0 mask 0f00 shift 6 plus 0 eat match ip protocol 6 ff u32 ht 1: order 2 \ match tcp src 1024 ffff match tcp dst 23 ffff action drop handle 2: u32 divisor 1 u32 ht 800: order 3 link 2: \ offset at 0 mask 0f00 shift 6 plus 0 eat match ip protocol 17 ff u32 ht 2: order 4 \ match udp src 1025 ffff match udp dst 24 ffff action drop Signed-off-by: Amritha Nambiar <amritha.nambiar@intel.com> Acked-by: John Fastabend <john.r.fastabend@intel.com> Acked-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 19 ++++++++++--------- drivers/net/ethernet/intel/ixgbe/ixgbe_model.h | 8 ++++++++ 2 files changed, 18 insertions(+), 9 deletions(-) commit dbd15b8f9cc3f0f8d665d048a31c0f4b5c9150a5 Author: Don Skidmore <donald.c.skidmore@intel.com> Date: Wed Mar 9 16:45:00 2016 -0500 ixgbe: Place SWFW semaphore in known valid state at probe It is possible on some HW that a system reset could occur when we are holding the SWFW semaphore lock. So next time the driver was loaded we would see it incorrectly as locked. This patch will recover from that state by: Attempting to acquire the semaphore and then regardless of whether or not it was acquire we immediately release it. This will force us into a known good state. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_82598.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++++ drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c | 20 ++++++++++++++++++++ drivers/net/ethernet/intel/ixgbe/ixgbe_x540.h | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 2 ++ 7 files changed, 30 insertions(+) commit c04f90e592431489df114971ff025265d429e48f Author: Rostislav Pehlivanov <atomnuker@gmail.com> Date: Wed Jan 27 18:33:30 2016 +0000 ixgbe: add a callback to set the maximum transmit bitrate This commit adds a callback which allows to adjust the maximum transmit bitrate the card can output. This makes it possible to get a smooth traffic instead of the default burst-y behaviour when trying to output e.g. a video stream. Much of the logic needed to get a correct bcnrc_val was taken from the ixgbe_set_vf_rate_limit() function. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 31 ++++++++++++++++++++++++++ drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 2 +- drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.h | 1 + 3 files changed, 33 insertions(+), 1 deletion(-) commit afdc71e4d6dc46d0f5bea7461ce356e6056f5ba8 Author: Mark Rustad <mark.d.rustad@intel.com> Date: Mon Jan 25 16:32:10 2016 -0800 ixgbe: Fix flow control for Xeon D KR backplane Xeon D KR backplane is different from other backplanes, in that we can't use auto-negotiation to determine the mode. Instead, use whatever the user configured. Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_82598.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 8 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_common.h | 3 +- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 5 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 86 ++++++++++++++++++++++++- 7 files changed, 98 insertions(+), 7 deletions(-) commit cb2b3edbece804d9836647c1ca51282ad384d425 Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed Jan 13 07:31:17 2016 -0800 ixgbevf: Add support for generic Tx checksums This patch adds support for generic Tx checksums to the ixgbevf driver. It turns out this is actually pretty easy after going over the datasheet as we were doing a number of steps we didn't need to. In order to perform a Tx checksum for an L4 header we need to fill in the following fields in the Tx descriptor: MACLEN (maximum of 127), retrieved from: skb_network_offset() IPLEN (maximum of 511), retrieved from: skb_checksum_start_offset() - skb_network_offset() TUCMD.L4T indicates offset and if checksum or crc32c, based on: skb->csum_offset The added advantage to doing this is that we can support inner checksum offloads for tunnels and MPLS while still being able to transparently insert VLAN tags. I also took the opportunity to clean-up many of the feature flag configuration bits to make them a bit more consistent between drivers. In the case of the VF drivers this meant adding support for SCTP CRCs, and inner checksum offloads for MPLS and various tunnel types. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 104 +++++++++------------- 1 file changed, 43 insertions(+), 61 deletions(-) commit 49763de0425560eed50a186428010189eae69372 Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed Jan 13 07:31:11 2016 -0800 ixgbe: Add support for generic Tx checksums This patch adds support for generic Tx checksums to the ixgbe driver. It turns out this is actually pretty easy after going over the datasheet as we were doing a number of steps we didn't need to. In order to perform a Tx checksum for an L4 header we need to fill in the following fields in the Tx descriptor: MACLEN (maximum of 127), retrieved from: skb_network_offset() IPLEN (maximum of 511), retrieved from: skb_checksum_start_offset() - skb_network_offset() TUCMD.L4T indicates offset and if checksum or crc32c, based on: skb->csum_offset The added advantage to doing this is that we can support inner checksum offloads for tunnels and MPLS while still being able to transparently insert VLAN tags. I also took the opportunity to clean-up many of the feature flag configuration bits to make them a bit more consistent between drivers. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 162 +++++++++----------------- 1 file changed, 58 insertions(+), 104 deletions(-) commit c7374b5a767cb6c7d9acbfc82656dc89afeae257 Author: Sowmini Varadhan <sowmini.varadhan@oracle.com> Date: Tue Jan 12 19:32:30 2016 -0800 ixgbe: use eth_platform_get_mac_address() This commit converts commit c762dff24c06 ("ixgbe: Look up MAC address in Open Firmware or IDPROM") to use eth_platform_get_mac_address() added by commit c7f5d105495a ("net: Add eth_platform_get_mac_address() helper.") Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 35 ++------------------------- 1 file changed, 2 insertions(+), 33 deletions(-) commit 7ffb8e317bae03b8ee5bdcec93dc3723be945e9b Author: Paul Moore <paul@paul-moore.com> Date: Mon Apr 4 16:44:02 2016 -0400 audit: we don't need to __set_current_state(TASK_RUNNING) Remove the calls to __set_current_state() to mark the task as running and do some related cleanup in wait_for_auditd() to limit the amount of work we do when we aren't going to reschedule the current task. Signed-off-by: Paul Moore <paul@paul-moore.com> kernel/audit.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 37689010da28c6dfd9f59e60d7f42c47b775171c Author: Mark Rustad <mark.d.rustad@intel.com> Date: Thu Jan 7 10:13:03 2016 -0800 ixgbe: Make all unchanging ops structures const The source for the ops structure contents are const, so make them so. Copy them in place with structure assignments instead of memcpys. Make the mbx_ops accessed by reference instead of making a copy of the source structure. Update copyright date on the touched files. Reported-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Mark Rustad <mark.d.rustad@intel.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 12 ++++---- drivers/net/ethernet/intel/ixgbe/ixgbe_82598.c | 10 +++---- drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 10 +++---- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 10 +++---- drivers/net/ethernet/intel/ixgbe/ixgbe_mbx.c | 40 +++++++++++++------------- drivers/net/ethernet/intel/ixgbe/ixgbe_mbx.h | 4 +-- drivers/net/ethernet/intel/ixgbe/ixgbe_type.h | 12 ++++---- drivers/net/ethernet/intel/ixgbe/ixgbe_x540.c | 10 +++---- drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 18 ++++++------ 9 files changed, 63 insertions(+), 63 deletions(-) commit 06bb1c39d8be0b2ee60b5bc9384fdac6e19bc270 Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed Jan 6 22:48:50 2016 -0800 ixgbe: Avoid adding VLAN 0 twice to VLVF and VFTA We were adding VLAN 0 twice each time we restored the VLAN configuration. Instead of doing it twice we can just start working through the active VLANs from ID 1 on and skip the double write. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9ef280c6c28f0c01aa9d909263ad47c796713a8e Author: Simon Horman <horms+renesas@verge.net.au> Date: Mon Apr 4 10:44:39 2016 +0900 irda: sh_irda: remove driver Remove the sh-irda driver as it appears to be unused since c0bb9b302769 ("ARCH: ARM: shmobile: Remove ag5evm board support"). Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/irda/Kconfig | 7 - drivers/net/irda/Makefile | 1 - drivers/net/irda/sh_irda.c | 875 --------------------------------------------- 3 files changed, 883 deletions(-) commit acf195a9f5228dbc529e023f035c2359cb6d2a19 Merge: f51bdc2 88023be Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 4 16:16:36 2016 -0400 Merge branch 'macb-coding-style' Moritz Fischer says: ==================== macb: Codingstyle cleanups resending almost unchanged v2 here: Changes from v2: * Rebased onto net-next * Changed 5th patches commit message * Added Nicholas' and Michal's Acked-Bys Changes from v1: * Backed out variable scope changes * Separated out ether_addr_copy into it's own commit * Fixed typo in comments as suggested by Joe ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 88023beb2a467dcfd9aa958138f0f3b5e1c432e0 Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue Mar 29 19:11:15 2016 -0700 net: macb: Fix simple typo Acked-by: Michal Simek <michal.simek@xilinx.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cadence/macb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eefb52d1ec8eb1354ff1bf55811a0da74bffccb8 Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue Mar 29 19:11:14 2016 -0700 net: macb: Use ether_addr_copy over memcpy Checkpatch suggests using ether_addr_copy over memcpy to copy the mac address. Acked-by: Michal Simek <michal.simek@xilinx.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cadence/macb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit aa50b55262d459f69c7b32eb7ce38cde84cc089b Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue Mar 29 19:11:13 2016 -0700 net: macb: Fix coding style suggestions This commit deals with a bunch of checkpatch suggestions that without changing behavior make checkpatch happier. Acked-by: Michal Simek <michal.simek@xilinx.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cadence/macb.c | 46 +++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 22 deletions(-) commit 64ec42fe272322c73ee159c68f7fb31896f65d1a Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue Mar 29 19:11:12 2016 -0700 net: macb: Fix coding style warnings This commit takes care of the coding style warnings that are mostly due to a different comment style and lines over 80 chars, as well as a dangling else. Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cadence/macb.c | 100 +++++++++++++++--------------------- 1 file changed, 42 insertions(+), 58 deletions(-) commit 96ec6310908a5f02450b18206d85e531f08cfa97 Author: Moritz Fischer <moritz.fischer@ettus.com> Date: Tue Mar 29 19:11:11 2016 -0700 net: macb: Fix coding style error message checkpatch.pl gave the following error: ERROR: space required before the open parenthesis '(' + for(; p < end; p++, offset += 4) Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/cadence/macb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f51bdc236b6c5835fa5e0df772acc234288b8af2 Author: Kazuya Mizuguchi <kazuya.mizuguchi.ks@renesas.com> Date: Sun Apr 3 23:54:38 2016 +0900 ravb: Add dma queue interrupt support This patch supports the following interrupts. - One interrupt for multiple (timestamp, error, gPTP) - One interrupt for emac - Four interrupts for dma queue (best effort rx/tx, network control rx/tx) This patch improve efficiency of the interrupt handler by adding the interrupt handler corresponding to each interrupt source described above. Additionally, it reduces the number of times of the access to EthernetAVB IF. Also this patch prevent this driver depends on the whim of a boot loader. [ykaneko0929@gmail.com: define bit names of registers] [ykaneko0929@gmail.com: add comment for gen3 only registers] [ykaneko0929@gmail.com: fix coding style] [ykaneko0929@gmail.com: update changelog] [ykaneko0929@gmail.com: gen3: fix initialization of interrupts] [ykaneko0929@gmail.com: gen3: fix clearing interrupts] [ykaneko0929@gmail.com: gen3: add helper function for request_irq()] [ykaneko0929@gmail.com: gen3: remove IRQF_SHARED flag for request_irq()] [ykaneko0929@gmail.com: revert ravb_close() and ravb_ptp_stop()] [ykaneko0929@gmail.com: avoid calling free_irq() to non-hooked interrupts] [ykaneko0929@gmail.com: make NC/BE interrupt handler a function] [ykaneko0929@gmail.com: make timestamp interrupt handler a function] [ykaneko0929@gmail.com: timestamp interrupt is handled in multiple interrupt handler instead of dma queue interrupt handler] Signed-off-by: Kazuya Mizuguchi <kazuya.mizuguchi.ks@renesas.com> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com> Acked-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/renesas/ravb.h | 204 ++++++++++++++++++++++++ drivers/net/ethernet/renesas/ravb_main.c | 266 +++++++++++++++++++++++++------ drivers/net/ethernet/renesas/ravb_ptp.c | 17 +- 3 files changed, 439 insertions(+), 48 deletions(-) commit 18be4fce00fef206dc6f104a6a258b193e9871cf Author: Alexander Duyck <aduyck@mirantis.com> Date: Wed Jan 6 22:48:44 2016 -0800 ixgbe: Do not allow PF to add VLVF entry unless it actually needs it While doing the work on igb I realized there were a few cases where we were still adding VLANs to the VLVF entries for the PF when they were not needed. This patch cleans that up so that the only time we add a PF entry to the VLVF is either for VLAN 0 or if the PF has requested a VLAN that a VF is already using. Signed-off-by: Alexander Duyck <aduyck@mirantis.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 8 +++---- drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 31 ++++++++++++++------------ 2 files changed, 21 insertions(+), 18 deletions(-) commit 1d96cf9822bf801b1a93a0817e45dd02af5ac0e6 Author: chas williams <3chas3@gmail.com> Date: Tue Jan 5 17:30:39 2016 -0500 ixgbe: Extend trust to allow guest to set unicast address When running certain routing protocols like VRRP, VF guests need the ability to set the unicast address of the interface. Extend the new ndo trust feature to let the hypervisor trust a guest to set/update its own unicast address. Signed-off-by: Chas Williams <3chas3@gmail.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d5dd7c3fa4dbff70fc25acf54acb63cf971fd6e9 Author: Emil Tantilov <emil.s.tantilov@intel.com> Date: Thu Dec 17 17:32:55 2015 -0800 ixgbevf: use bit operations for setting and checking resets Move the reset flags to adapter->state in order to make use of bit operations. This is an alternative patch to the one previously submitted by John Greene. Suggested-by: Alexander Duyck <aduyck@mirantis.com> Reported-by: Scott Otto <otts62@yahoo.com> Reported-by: John Greene <jogreene@redhat.com> Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 9 ++------- drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 15 ++++++--------- 2 files changed, 8 insertions(+), 16 deletions(-) commit 9d2355ba30942ec28fb56510a8228050cbfcc6a6 Merge: 833716e fd91e12 Author: David S. Miller <davem@davemloft.net> Date: Mon Apr 4 15:50:31 2016 -0400 Merge branch 'cmsg_timestamp' Soheil Hassas Yeganeh says: ==================== add TX timestamping via cmsg This patch series aim at enabling TX timestamping via cmsg. Currently, to occasionally sample TX timestamping on a socket, applications need to call setsockopt twice: first for enabling timestamps and then for disabling them. This is an unnecessary overhead. With cmsg, in contrast, applications can sample TX timestamps per sendmsg(). This patch series adds the code for processing SO_TIMESTAMPING for cmsg's of the SOL_SOCKET level, and adds the glue code for TCP, UDP, and RAW for both IPv4 and IPv6. This implementation supports overriding timestamp generation flags (i.e., SOF_TIMESTAMPING_TX_*) but not timestamp reporting flags. Applications must still enable timestamp reporting via setsockopt to receive timestamps. This series does not change existing timestamping behavior for applications that are using socket options. I will follow up with another patch to enable timestamping for active TFO (client-side TCP Fast Open) and also setting packet mark via cmsgs. Thanks! Changes in v2: - Replace u32 with __u32 in the documentation. Changes in v3: - Fix the broken build for L2TP (due to changes in IPv6). ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit fd91e12f594b40fdb2dad530e8b895cc5c07db21 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:13 2016 -0400 sock: document timestamping via cmsg in Documentation Update docs and add code snippet for using cmsg for timestamping. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/timestamping.txt | 48 +++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 3 deletions(-) commit c14ac9451c34832554db33386a4393be8bba3a7b Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:12 2016 -0400 sock: enable timestamping using control messages Currently, SOL_TIMESTAMPING can only be enabled using setsockopt. This is very costly when users want to sample writes to gather tx timestamps. Add support for enabling SO_TIMESTAMPING via control messages by using tsflags added in `struct sockcm_cookie` (added in the previous patches in this series) to set the tx_flags of the last skb created in a sendmsg. With this patch, the timestamp recording bits in tx_flags of the skbuff is overridden if SO_TIMESTAMPING is passed in a cmsg. Please note that this is only effective for overriding the recording timestamps flags. Users should enable timestamp reporting (e.g., SOF_TIMESTAMPING_SOFTWARE | SOF_TIMESTAMPING_OPT_ID) using socket options and then should ask for SOF_TIMESTAMPING_TX_* using control messages per sendmsg to sample timestamps for each write. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/tun.c | 3 ++- include/net/ipv6.h | 6 ++++-- include/net/sock.h | 10 ++++++---- net/can/raw.c | 2 +- net/ipv4/ping.c | 5 +++-- net/ipv4/raw.c | 11 ++++++----- net/ipv4/tcp.c | 20 +++++++++++++++----- net/ipv4/udp.c | 7 ++++--- net/ipv6/icmp.c | 6 ++++-- net/ipv6/ip6_output.c | 15 +++++++++------ net/ipv6/ping.c | 3 ++- net/ipv6/raw.c | 5 ++--- net/ipv6/udp.c | 7 ++++--- net/l2tp/l2tp_ip6.c | 2 +- net/packet/af_packet.c | 30 +++++++++++++++++++++++++----- net/socket.c | 10 +++++----- 16 files changed, 93 insertions(+), 49 deletions(-) commit ad1e46a837163a3e7160a1250825bcfafd2e714b Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:11 2016 -0400 ipv6: process socket-level control messages in IPv6 Process socket-level control messages by invoking __sock_cmsg_send in ip6_datagram_send_ctl for control messages on the SOL_SOCKET layer. This makes sure whenever ip6_datagram_send_ctl is called for udp and raw, we also process socket-level control messages. This is a bit uglier than IPv4, since IPv6 does not have something like ipcm_cookie. Perhaps we can later create a control message cookie for IPv6? Note that this commit interprets new control messages that were ignored before. As such, this commit does not change the behavior of IPv6 control messages. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/transp_v6.h | 3 ++- net/ipv6/datagram.c | 9 ++++++++- net/ipv6/ip6_flowlabel.c | 3 ++- net/ipv6/ipv6_sockglue.c | 3 ++- net/ipv6/raw.c | 6 +++++- net/ipv6/udp.c | 5 ++++- net/l2tp/l2tp_ip6.c | 8 +++++--- 7 files changed, 28 insertions(+), 9 deletions(-) commit 24025c465f77c3585f73450bab19501b2edd6fba Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:10 2016 -0400 ipv4: process socket-level control messages in IPv4 Process socket-level control messages by invoking __sock_cmsg_send in ip_cmsg_send for control messages on the SOL_SOCKET layer. This makes sure whenever ip_cmsg_send is called in udp, icmp, and raw, we also process socket-level control messages. Note that this commit interprets new control messages that were ignored before. As such, this commit does not change the behavior of IPv4 control messages. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/ip.h | 3 ++- net/ipv4/ip_sockglue.c | 9 ++++++++- net/ipv4/ping.c | 2 +- net/ipv4/raw.c | 2 +- net/ipv4/udp.c | 3 +-- 5 files changed, 13 insertions(+), 6 deletions(-) commit 3dd17e63f5131bf2528f34aa5e3e57758175af92 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:09 2016 -0400 sock: accept SO_TIMESTAMPING flags in socket cmsg Accept SO_TIMESTAMPING in control messages of the SOL_SOCKET level as a basis to accept timestamping requests per write. This implementation only accepts TX recording flags (i.e., SOF_TIMESTAMPING_TX_HARDWARE, SOF_TIMESTAMPING_TX_SOFTWARE, SOF_TIMESTAMPING_TX_SCHED, and SOF_TIMESTAMPING_TX_ACK) in control messages. Users need to set reporting flags (e.g., SOF_TIMESTAMPING_OPT_ID) per socket via socket options. This commit adds a tsflags field in sockcm_cookie which is set in __sock_cmsg_send. It only override the SOF_TIMESTAMPING_TX_* bits in sockcm_cookie.tsflags allowing the control message to override the recording behavior per write, yet maintaining the value of other flags. This patch implements validating the control message and setting tsflags in struct sockcm_cookie. Next commits in this series will actually implement timestamping per write for different protocols. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 1 + include/uapi/linux/net_tstamp.h | 10 ++++++++++ net/core/sock.c | 13 +++++++++++++ 3 files changed, 24 insertions(+) commit 6b084928baac562ed61866f540a96120e9c9ddb7 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:08 2016 -0400 tcp: use one bit in TCP_SKB_CB to mark ACK timestamps Currently, to avoid a cache line miss for accessing skb_shinfo, tcp_ack_tstamp skips socket that do not have SOF_TIMESTAMPING_TX_ACK bit set in sk_tsflags. This is implemented based on an implicit assumption that the SOF_TIMESTAMPING_TX_ACK is set via socket options for the duration that ACK timestamps are needed. To implement per-write timestamps, this check should be removed and replaced with a per-packet alternative that quickly skips packets missing ACK timestamps marks without a cache-line miss. To enable per-packet marking without a cache line miss, use one bit in TCP_SKB_CB to mark a whether a SKB might need a ack tx timestamp or not. Further checks in tcp_ack_tstamp are not modified and work as before. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 3 ++- net/ipv4/tcp.c | 2 ++ net/ipv4/tcp_input.c | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) commit 6db8b963a7a31047573f229492ff6fc0f51cc377 Author: Soheil Hassas Yeganeh <soheil@google.com> Date: Sat Apr 2 23:08:07 2016 -0400 tcp: accept SOF_TIMESTAMPING_OPT_ID for passive TFO SOF_TIMESTAMPING_OPT_ID is set to get data-independent IDs to associate timestamps with send calls. For TCP connections, tp->snd_una is used as the starting point to calculate relative IDs. This socket option will fail if set before the handshake on a passive TCP fast open connection with data in SYN or SYN/ACK, since setsockopt requires the connection to be in the ESTABLISHED state. To address these, instead of limiting the option to the ESTABLISHED state, accept the SOF_TIMESTAMPING_OPT_ID option as long as the connection is not in LISTEN or CLOSE states. Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Acked-by: Willem de Bruijn <willemb@google.com> Acked-by: Yuchung Cheng <ycheng@google.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/core/sock.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 39771b127b412377d6354893c7d43ee8f2edecfd Author: Willem de Bruijn <willemb@google.com> Date: Sat Apr 2 23:08:06 2016 -0400 sock: break up sock_cmsg_snd into __sock_cmsg_snd and loop To process cmsg's of the SOL_SOCKET level in addition to cmsgs of another level, protocols can call sock_cmsg_send(). This causes a double walk on the cmsghdr list, one for SOL_SOCKET and one for the other level. Extract the inner demultiplex logic from the loop that walks the list, to allow having this called directly from a walker in the protocol specific code. Signed-off-by: Willem de Bruijn <willemb@google.com> Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/sock.h | 2 ++ net/core/sock.c | 33 ++++++++++++++++++++++----------- 2 files changed, 24 insertions(+), 11 deletions(-) commit 75b6462e965dc76d16254b5fcb3f41ca97f6fef0 Author: Pavel Tikhomirov <ptikhomirov@virtuozzo.com> Date: Fri Dec 11 17:05:14 2015 +0300 ixgbe: on recv increment rx.ring->stats.yields It seem to be non intentionally changed to Tx in commit adc810900a70 ("ixgbe: Refactor busy poll socket code to address multiple issues") Lock is taken from ixgbe_low_latency_recv, and there under this lock we use ixgbe_clean_rx_irq so it looks wrong for me to increment Tx counter. Yield stats can be shown through ethtool: ethtool -S enp129s0 | grep yield Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 148e45dc87cb76ba89e80da264bc692cc91a5149 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Thu Mar 31 18:53:14 2016 -0400 staging: vme: fix bare use of 'unsigned' fix checkpatch.pl warning about 'Prefer 'unsigned int' to bare use of 'unsigned'' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Acked-by: Martyn Welch <martyn@welchs.me.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vme/devices/vme_pio2_gpio.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit b9f8463728eb0dd46b9f2b34ee59b12e358b4ce7 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Fri Apr 1 17:28:44 2016 +0900 staging: dgnc: fix CamelCase in dgnc_tty.c fix checkpatch.pl warning about 'Avoid CamelCase' Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 2 +- drivers/staging/dgnc/digi.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 8670a56ff70ec1fcbb95bd05a478c5a8361fee53 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Fri Apr 1 17:28:22 2016 +0900 staging: dgnc: remove too many traverse pointer The "ch->ch_bd" is already assined to "bd" but this is only for checking null or MAGIC number. in the dgnc_tty_ioctl function, bd can be used for referencing to board_ops structure. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 37 ++++++++++++++++++++----------------- 1 file changed, 20 insertions(+), 17 deletions(-) commit 77ed2c5745d93416992857d124f35834b62b3e70 Author: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Date: Tue Mar 8 20:01:32 2016 +0900 android,lowmemorykiller: Don't abuse TIF_MEMDIE. Currently, lowmemorykiller (LMK) is using TIF_MEMDIE for two purposes. One is to remember processes killed by LMK, and the other is to accelerate termination of processes killed by LMK. But since LMK is invoked as a memory shrinker function, there still should be some memory available. It is very likely that memory allocations by processes killed by LMK will succeed without using ALLOC_NO_WATERMARKS via TIF_MEMDIE. Even if their allocations cannot escape from memory allocation loop unless they use ALLOC_NO_WATERMARKS, lowmem_deathpending_timeout can guarantee forward progress by choosing next victim process. On the other hand, mark_oom_victim() assumes that it must be called with oom_lock held and it must not be called after oom_killer_disable() was called. But LMK is calling it without holding oom_lock and checking oom_killer_disabled. It is possible that LMK calls mark_oom_victim() due to allocation requests by kernel threads after current thread returned from oom_killer_disabled(). This will break synchronization for PM/suspend. This patch introduces per a task_struct flag for remembering processes killed by LMK, and replaces TIF_MEMDIE with that flag. By applying this patch, assumption by mark_oom_victim() becomes true. Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Acked-by: Michal Hocko <mhocko@suse.com> Cc: Arve Hjonnevag <arve@android.com> Cc: Riley Andrews <riandrews@android.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/lowmemorykiller.c | 9 ++------- include/linux/sched.h | 4 ++++ 2 files changed, 6 insertions(+), 7 deletions(-) commit eb7bfed901b9fea6e48bec10009dc8c8641e36e7 Merge: 56d118c 486294f Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Date: Mon Apr 4 12:31:05 2016 -0700 Merge tag 'iio-for-4.7a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-next Jonathan writes: First round of IIO new device support, features and cleanups for the 4.7 cycle. New core support * UV light modifier (for intensity) * UV light index channel type. New device support * hp206c barometer and altimeter - new driver. * mcp4131 potentiometer - new driver supporting lots of parts from Microchip. * mma8452 - FXLS8471Q support - NXP LPC18XX SOC ADC - new driver. - NXP LPC18XX SOC DAC - new driver. - rockchip_saradc - support rk3399 * st accel - h3lis331dl support Staging driver removals * adis16204 - obsolete part making it hard to get parts to test the driver in order to clean it up. * adis16220 - obsolete part making it hard to get the parts test the driver in order to clean it up. Features * core - convenience functions to claim / release direct access to the device. Makes more consistent handling of this corner easier. Used in ad7192 driver. * ak8975 - power regulator support. * at91-sama5d2 - differential channel support. * mma8452 - runtime pm support - drop device specific autosleep and use the runtime pm one instead. * ms5611 - DT bindings - oversampling ratio support Cleanups and minor fixes * MAINTAINERS - Peter got married - hence name change! * Documentation - Fix a typo in in_proximity_raw description. - Add some missing docs for iio_buffer_access_funcs. * Tools - update iio_event_monitor names to match new stuff. - make generic_buffer look for triggers ending in -trigger as we let these in for a number of drivers a long time back and now it is a fairly common option. Drivers * staging wide - convert bare unsigned usage to unsigned int to comply with coding style. * non staging wide: - since boiler plate gpio handling of interrupts has been moved into the ACPI core we don't need to include gpio/consumer.h in a load of drivers so drop it. * ad7606 - fix an endian casting sparse warning. * ak8975 - fix a possible unitialized warning from gcc. - drop and unused field left over from earlier cleanups - fix a missing regulator_disable on exit. * at91-sama5d2 - typo and indentation - missing IOMEM dependency. - cleanup mode register usage by avoidling erasing whole thing when changing the sampling frequency. * bmc150 - use the core demux and available_scan_masks to simplify buffer handling - optimize the transfers in the trigger handler now we have a magic function to emulate bulk reads (under circumstances met here). This matters with some rather dumb i2c adapters in particular. - use a single regmap_conf for all bus types as they were all the same. * bmg160 - use the core demux and available_scan_masks to simplify the buffer handling - optimize the transfers in the trigger handler now we have a magic funciton to emulate bulk rads (under circumstances met here). - drop gpio interrupt probing from the driver (ACPI) as now handled by the ACPI core. * ina2xx-adc - update the CALIB register when RShunt changes. - fix scale for VShunt - in reality this error canceled out when used. * isl29028 - use regmap to retrieve the struct device instead of carrying a second copy of it around. * kxcjk-1013 - use core demux - optimize i2c transfers in the trigger handler. * mcp4531 - refactor to use a pointer to access model parameters instead of indexing into the array each time. * mma8452 - style fixes - avoid swtiching to active whenever the config changes - add missin i2c_device_id for mma8451 * mpu6050 - fix possible NULL dereference. - fix the name / chip_id used when ACPI used (otherwise reports as NULL). * ms5611 - fix a missing regulator_disable that left the regulator on during removal. * mxc4005 - drop gpio interrupt handling for ACPI case from driver as the core now handles this case. * st-sensors - note that there are only ever a maximum of 3 axis on current st-sensors so just allocate a fixed sized buffer big enough for that. * tpl0102 - change the i2c_check_functionality condition to bring it inline with other IIO users as EOPNOTSUPP. * tsl2563 - replace deprecated flush_scheduled_work commit 3652bb35abf6ee11333cbec1d2855c1c0f9f6b27 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 14:55:34 2016 -0700 ARM: bcm2835: Enable NFS root support. This is also present in multi_v7_defconfig, and means that I can test the pi1 with the 2835 defconfig in my normal environment. Signed-off-by: Eric Anholt <eric@anholt.net> arch/arm/configs/bcm2835_defconfig | 3 +++ 1 file changed, 3 insertions(+) commit 4400d9ac05ee5100ecff2ad0ed1f0dea390bc349 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 14:17:45 2016 -0700 ARM: bcm2835: Enable the VC4 graphics driver in the defconfig Combined with the queued DT changes, we now get HDMI and 3D support. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/bcm2835_defconfig | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 8d1a8c92a8c04f344a57c271b5c0792bc552ae3e Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 14:29:03 2016 -0700 ARM: bcm2835: Enable CONFIG_PM. The power domain driver we've enabled doesn't actually do anything without it, and we need it to do its job for VC4 to initialize successfully. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/bcm2835_defconfig | 1 + 1 file changed, 1 insertion(+) commit bf9dbf50b1a3a8af3c72dc722bfb0137dda873f7 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 14:19:56 2016 -0700 ARM: bcm2835: Switch BCM2835 to sdhci-iproc.c for MMC This approximately triples write performance for the SD card. My card is too full of important data to collect very reliable numbers, but I see 271.361% +/- 166.742% improvement (n=3 before, 6 after), for 'dd if=/dev/zero of=/boot/asdf bs=1M count=3 oflag=dsync,direct'. Read performance appears to be unaffected. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/bcm2835_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 54fff103fd9b8312e8cb958dda3a0dc9d0793086 Author: Eric Anholt <eric@anholt.net> Date: Thu Mar 31 13:38:57 2016 -0700 ARM: multi_v7_defconfig: Build in DWC2 USB support This allows the Raspberry Pi 2 to be network booted from the defconfig. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/multi_v7_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit abcfccdfa14c2e74ede1ee7c876a907274f6bfb5 Author: Eric Anholt <eric@anholt.net> Date: Mon Mar 28 19:01:27 2016 -0700 ARM: multi_v7_defconfig: Switch BCM2835 to sdhci-iproc.c for MMC This approximately triples write performance for the SD card. My card is too full of important data to collect very reliable numbers, but I see 271.361% +/- 166.742% improvement (n=3 before, 6 after), for 'dd if=/dev/zero of=/boot/asdf bs=1M count=3 oflag=dsync,direct'. Read performance appears to be unaffected. Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/multi_v7_defconfig | 1 - 1 file changed, 1 deletion(-) commit 8f03488b7478f82897ad909f743db0cd6e3947ac Author: Eric Anholt <eric@anholt.net> Date: Mon Mar 28 18:52:27 2016 -0700 ARM: multi_v7_defconfig: Add more BCM2835 support The WDT is required for reboot and I2S is used for audio devices on the P5 header (or BT audio on the Pi3). Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Stephen Warren <swarren@wwwdotorg.org> arch/arm/configs/multi_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 1bcb9f8ceb67803960871ecf4ed2d365a2a919c8 Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Apr 1 16:48:50 2016 +0530 spi: spi-pic32: Add PIC32 SPI master driver The PIC32 SPI driver is capable of performing SPI transfers using PIO or external DMA engine. GPIO controlled /CS support is made default in the driver for correct operation of the controller. This can be enabled by adding "cs-gpios" property of the SPI node in board dts file. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 6 + drivers/spi/Makefile | 1 + drivers/spi/spi-pic32.c | 888 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 895 insertions(+) commit 120e8989ebac7c7c702e351046c20e9918912aca Author: Purna Chandra Mandal <purna.mandal@microchip.com> Date: Fri Apr 1 16:48:49 2016 +0530 spi: pic32: Add bindings for PIC32 SPI peripheral Document the devicetree bindings for the SPI peripheral found on Microchip PIC32 class devices. Signed-off-by: Purna Chandra Mandal <purna.mandal@microchip.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org> .../bindings/spi/microchip,spi-pic32.txt | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit 77fc397661e714c2bc4f96ae38f6776c15cc85ab Author: Mario Six <mario.six@gdsys.cc> Date: Fri Mar 18 14:57:21 2016 +0100 dmaengine: mpc512x: Fix code style Signed-off-by: Mario Six <mario.six@gdsys.cc> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mpc512x_dma.c | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) commit 899ed9dd4f2d007dfad66cd074b8ff26a0894ae8 Author: Mario Six <mario.six@gdsys.cc> Date: Fri Mar 18 14:57:20 2016 +0100 dmaengine: mpc512x: Implement additional chunk sizes for DMA transfers This patch extends the capabilities of the driver to handle DMA transfers to and from devices of 1, 2, 4, 16 (for MPC512x), and 32 byte widths. Signed-off-by: Mario Six <mario.six@gdsys.cc> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mpc512x_dma.c | 112 +++++++++++++++++++++++++++++++--------------- 1 file changed, 76 insertions(+), 36 deletions(-) commit 237ec70903bcf50768138b6c663c67ef1f946cc8 Author: Mario Six <mario.six@gdsys.cc> Date: Fri Mar 18 14:57:19 2016 +0100 dmaengine: mpc512x: Fix hanging DMA device transfer for MPC8308 Since the MPC8308 has no external request lines to initiate DMA transfers, all transfers must be triggered by software. Because of this, the current implementation of DMA transfers from and to devices on MPC8308 SoCs using major and minor loops is faulty: After the completion of the first major loop, the DMA engine resets the start flag in the channel's TCD, thus halting the transfer. The driver would have to set the start bit again to trigger the next iteration of the major loop; on MPC512x SoCs, this is done via the external request lines, so in this case, the driver doesn't have to interfer in any way. This has the effect that on MPC8308s, every DMA transfer to or from a device hangs after executing the first major loop. The patch fixes this behavior by using just one major loop for the whole DMA transfer on MPC8308s. Signed-off-by: Mario Six <mario.six@gdsys.cc> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/mpc512x_dma.c | 38 ++++++++++++++++++++++++-------------- 1 file changed, 24 insertions(+), 14 deletions(-) commit 17b3cf4233d77698df0e5ff39303c145ac355d6a Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 14:26:36 2016 +0200 dmaengine: hsu: set maximum allowed segment size for DMA This tells, for example, IOMMU what the maximum size of a segment the DMA controller can send. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/hsu/hsu.c | 2 ++ drivers/dma/hsu/hsu.h | 4 ++++ 2 files changed, 6 insertions(+) commit c36a0176ba678fd1a4bf985fd62f43dd4f4d4a03 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 14:26:35 2016 +0200 dmaengine: hsu: don't check direction of timeouted channel The timeout capability is only available on the so called DMA write channels, i.e. associated with UART Rx FIFO. It means we don't need to check the direction of the channel to handle timeouts. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/hsu/hsu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d4d689f3ec56ad1eca6c899f418aeb6c0cf43ca Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Fri Mar 18 14:26:34 2016 +0200 dmaengine: hsu: allow more than 3 descriptors Current code allows only up to 3 descriptors to be programmed to the hardware since it is used wrong calculations. Change % to min_t() to allow as many descriptors as user supplied. At once it could be programmed up to 4 descriptors due to hardware limitations. The issue was found under stress test, so it might not bother ordinary users. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/hsu/hsu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 974e0a4537f556867483f493c7f67ccdcb7fc504 Author: Damien Le Moal <damien.lemoal@hgst.com> Date: Mon Apr 4 12:17:09 2016 -0400 libata-core: Allow longer timeout for drive spinup from PUIS When spinning up a drive from powered on standby mode (PUIS), SETFEATURES_SPINUP is executed with the default timeout used for any SETFEATURES subcommand, that is 5+10 seconds. The total 15s is too short for some drives to complete spinup (e.g. drives with a large indirection table stored on media), resulting in ata_dev_read_id to fail twice on the execution of SETFEATURES_SPINUP. For this feature, allow a larger default timeout of 30 seconds. However, in the same spirit as with the timeout of other feature subcommands, do not ignore ata_probe_timeout if it is set). Signed-off-by: Damien Le Moal <damien.lemoal@hgst.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 6 +++++- include/linux/ata.h | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) commit 4113652252fad972e0c191b1e536dc74a6faebdc Author: Daniel Lezcano <daniel.lezcano@linaro.org> Date: Fri Apr 1 21:38:16 2016 +0200 reset: Add missing function stub for device_reset The Mediatek's thermal driver fails to compile when the RESET_CONTROLLER option is not set. Logically, as the driver depends on this option to compile, the Kconfig should select it but actually that is not correct because the Kconfig provides also the COMPILE_TEST to increase the compile test coverage. By providing the missing 'device_reset' stub for the driver in reset.h, that let the kernel to compile on different platforms with the Mediatek thermal driver enabled with the COMPILE_TEST option. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> include/linux/reset.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 7780081c1f04a4ea31331b5579ca010cc1f26c74 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:07 2016 +0200 libata-scsi: Set information sense field for invalid parameter Whenever the sense key is set to 'invalid parameter' we should be filling out the sense-key specific information field in the sense buffer. tj: Added description of @fp for ata_mselect_*(). Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 81 +++++++++++++++++++++++++++++++++++------------ 1 file changed, 61 insertions(+), 20 deletions(-) commit 0df10b84af88a482beea982f5f27a2e42157f600 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:06 2016 +0200 libata-scsi: set bit pointer for sense code information When generating a sense code of 'Invalid field in CDB' we should be setting the bit pointer where appropriate. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 30 +++++++++++++++++++----------- 1 file changed, 19 insertions(+), 11 deletions(-) commit bcfc867d467c98aba23ce0331455282936c04b73 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:05 2016 +0200 libata-scsi: Set field pointer in sense code If the sense code is 'Invalid field in CDB' we should be setting the field pointer to the offending byte. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 155 ++++++++++++++++++++++++++++++++-------------- 1 file changed, 108 insertions(+), 47 deletions(-) commit 78db6e30281aa056a6773cb4def00afc158c097f Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:04 2016 +0200 scsi: add scsi_set_sense_field_pointer() Add a function to set the field pointer for SCSI sense codes. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/scsi/scsi_common.c | 53 ++++++++++++++++++++++++++++++++++++++++++++++ include/scsi/scsi_common.h | 1 + 2 files changed, 54 insertions(+) commit 06dbde5f3a44248fc02e24d662ac4849202abb48 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:03 2016 +0200 libata: Implement control mode page to select sense format Implement MODE SELECT for the control mode page to allow the OS to switch to descriptor sense. tj: Dropped s/sb/cmd->sense_buffer/ in ata_gen_ata_sense(). Added @dev description to ata_msense_ctl_mode(). Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 4 +- drivers/ata/libata-scsi.c | 116 ++++++++++++++++++++++++++++++++++------------ drivers/ata/libata.h | 3 +- include/linux/libata.h | 1 + 4 files changed, 91 insertions(+), 33 deletions(-) commit 11093cb1ef56147fe33f5750b1eab347bdef30db Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:02 2016 +0200 libata-scsi: generate correct ATA pass-through sense Generate ATA pass-through sense for both fixed and descriptor format sense. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 93 ++++++++++++++++++++++++++++++----------------- 1 file changed, 59 insertions(+), 34 deletions(-) commit 3852e37382664a06cd006bb389a8223e32cedf45 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:01 2016 +0200 libata: evaluate SCSI sense code Whenever a sense code is set it would need to be evaluated to update the error mask. tj: Cosmetic formatting updates. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 29 ++++++++++++++++++++--------- drivers/scsi/scsi_error.c | 3 ++- include/scsi/scsi_eh.h | 1 + 3 files changed, 23 insertions(+), 10 deletions(-) commit b525e7731b90ebc7a70a095fc5d5363408b94274 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:44:00 2016 +0200 libata-scsi: use ata_scsi_set_sense() Use ata_scsi_set_sense() throughout to ensure the sense code format is consistent. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) commit 492bf62107347aca764070dbc9d412da6bda73d1 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:59 2016 +0200 libata-eh: Set 'information' field for autosense If NCQ autosense or the sense data reporting feature is enabled the LBA of the offending command should be stored in the sense data 'information' field. tj: s/(u64)-1/U64_MAX/ Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 2 ++ drivers/ata/libata-scsi.c | 17 +++++++++++++++++ drivers/ata/libata.h | 3 +++ 3 files changed, 22 insertions(+) commit cf8b49b0af39b8e8fa358623acda57f01251b6d4 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:58 2016 +0200 libata-scsi: use scsi_set_sense_information() Use scsi_set_sense_information() instead of hand-crafted function. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) commit cffd1ee991c566bca937392cfacdafbe3b7b58c6 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:57 2016 +0200 libata: sanitize ata_tf_read_block() Return U64_MAX if ata_tf_read_block() could not decode the LBA address, and do not set the information sense descriptor in ata_gen_ata_sense() in these cases. tj: s/(u64)-1/U64_MAX/ Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 4 ++-- drivers/ata/libata-scsi.c | 2 ++ drivers/ata/libata.h | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) commit 5e6acd1c8c4dc9a7c16208aeac3de09151ee6233 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:56 2016 +0200 libata-scsi: sanitize ata_gen_ata_sense() ata_to_sense_error() is called conditionally, so we should be generating a default sense if the condition is not met. Signed-off-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-scsi.c | 6 ++++++ 1 file changed, 6 insertions(+) commit e87fd28cf9a2d9018ac4b6dd92f0b417714bc18d Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:55 2016 +0200 libata: Implement support for sense data reporting ACS-4 defines a sense data reporting feature set. This patch implements support for it. tj: Cosmetic formatting updates. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-core.c | 20 +++++++++++++- drivers/ata/libata-eh.c | 68 ++++++++++++++++++++++++++++++++++++++++++++--- include/linux/ata.h | 16 +++++++++++ 3 files changed, 99 insertions(+), 5 deletions(-) commit 5b01e4b9efa0b78672cbbea830c9fbcc7f239e29 Author: Hannes Reinecke <hare@suse.de> Date: Mon Apr 4 11:43:54 2016 +0200 libata: Implement NCQ autosense Some newer devices support NCQ autosense (cf ACS-4), so we should be using it to retrieve the sense code and speed up recovery. Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libata-eh.c | 12 ++++++++++++ drivers/ata/libata-scsi.c | 7 ++++++- drivers/ata/libata.h | 1 + include/linux/ata.h | 2 ++ 4 files changed, 21 insertions(+), 1 deletion(-) commit 80b28810cc98aadc80e7ce8cc155a774a7ada8ca Author: Lv Zheng <lv.zheng@intel.com> Date: Thu Mar 24 09:38:28 2016 +0800 ACPICA: Linuxize: reduce divergences for 20160212 release The patch reduces source code differences between the Linux kernel and the ACPICA upstream so that the linuxized ACPICA 20160212 release can be applied with reduced human intervention. Signed-off-by: Lv Zheng <lv.zheng@intel.com> [ rjw: White space damage fixes ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> drivers/acpi/acpica/nsinit.c | 1 - drivers/acpi/acpica/nsload.c | 2 +- drivers/acpi/osl.c | 2 +- include/acpi/acpiosxf.h | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) commit 658b476c742fe379e7020309fd590a27b457a4c1 Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:07 2016 +0300 pinctrl: baytrail: Add debounce configuration Make debounce setting and getting functionality available when configurating a certain pin. Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 83 +++++++++++++++++++++++++++++++- 1 file changed, 81 insertions(+), 2 deletions(-) commit 1db7f6201dfce1740e41f87c81389cc2e9c73e99 Author: Joachim Eastwood <manabian@gmail.com> Date: Wed Feb 24 23:10:42 2016 +0100 dt-bindings: phy-lpc18xx-usb-otg: remove unit address from binding DT bindings should either use a unit address and a reg property or none of them. Since either of them aren't really useful for such a simple device like this one remove the unit address. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Documentation/devicetree/bindings/phy/phy-lpc18xx-usb-otg.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3a572c4aa96d6c7831fa1798152241ce24d720c2 Author: Joachim Eastwood <manabian@gmail.com> Date: Fri Mar 11 19:05:47 2016 +0100 ARM: dts: lpc4350-hitex-eval: fix unit name warnings from dtc Fix the following warnings from dtc by either adding or removing the unit name from the node. Warning (unit_address_vs_reg): Node /soc/flash-controller@40003000/flash@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@1 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@2 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@3 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@4 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@5 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@6 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /pca_buttons/button@7 has a unit name, but no reg property Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc4350-hitex-eval.dts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit eeadc20c6a4e700c80d26e10e9e2c49fd551b2d4 Author: Joachim Eastwood <manabian@gmail.com> Date: Fri Mar 11 19:05:03 2016 +0100 ARM: dts: lpc4357-ea4357: fix unit name warnings from dtc Fix the following warnings from dtc by either adding or removing the unit name from the node. Warning (unit_address_vs_reg): Node /soc/flash-controller@40003000/flash@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /gpio_joystick/button@0 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /gpio_joystick/button@1 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /gpio_joystick/button@2 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /gpio_joystick/button@3 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /gpio_joystick/button@4 has a unit name, but no reg property Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc4357-ea4357-devkit.dts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 472a5a3ddf86725f87432d70462e3ce6dc3996b6 Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Feb 27 19:39:03 2016 +0100 ARM: dts: lpc18xx: remove unit addresses from creg childs DT nodes without reg properties should not have a unit address. This fixes the following warnings from dtc. Warning (unit_address_vs_reg): Node /soc/syscon@40043000/phy@004 has a unit name, but no reg property Warning (unit_address_vs_reg): Node /soc/syscon@40043000/dma-mux@11c has a unit name, but no reg property Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc18xx.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fae6bd7090283dccc1487b997e6dea4529cbf839 Author: Joachim Eastwood <manabian@gmail.com> Date: Fri Mar 11 18:46:33 2016 +0100 ARM: dts: armv7-m: add unit name to interrupt-controller Add unit name to nvic to remove the following warning: Warning (unit_address_vs_reg): Node /nv-interrupt-controller has a reg or ranges property, but no unit name Also correct the node name to 'interrupt-controller' while changing the line. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Stefan Agner <stefan@agner.ch> arch/arm/boot/dts/armv7-m.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 71e6ca61e82667c5c0de4aa779a4438d6568262f Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:06 2016 +0300 pinctrl: baytrail: Register pin control handling This patch updates device's probing, removal and irq handling in order to register it as pinctrl device. Pin control data is matched by ACPI UID, since it is passed along as driver data in acpi_device_id structure. Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 447 +++++++++++++++---------------- 1 file changed, 221 insertions(+), 226 deletions(-) commit 9f573b98ca502ad495641ce42fcc18ccb32f5827 Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:05 2016 +0300 pinctrl: baytrail: Update irq chip operations This patch updates the irq chip implementation in order to interact with the pin control chip model: the chip contains reference to SOC data and pin/group/community information is retrieved through the SOC reference. Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 97 +++++++++++++++++--------------- 1 file changed, 51 insertions(+), 46 deletions(-) commit a2cb3d5f043e4cc646c396a3e188a171b38c15a0 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Mar 18 17:54:56 2016 +0800 ath9k: fix rng high cpu load If no valid ADC randomness output, ath9k rng will continuously reading ADC, which will cause high CPU load. So increase the delay to wait for ADC ready. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=114261 Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/rng.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit 69218a48005d0c93b8e9ec483f42ead481a43034 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Mon Mar 21 22:01:11 2016 +0200 wil6210: allow empty WMI commands in debugfs wmi_send There are many valid WMI commands with only header without any additional payload. Such WMI commands could not be sent using the debugfs wmi_send facility. Fix the code to allow sending of such commands. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/debugfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 44fde3b89ba1e154b3cec7d711703fff53852983 Author: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Date: Mon Apr 4 19:23:54 2016 +0530 ALSA: hda - Update chmap tlv to report sink's capability The existing TLV callback implementation copies all of the cea_channel_speaker_allocation map table to the TLV container irrespective of what is reported by sink. This is of little use to the userspace application. With this patch, it parses the spk_alloc block as queried from the ELD, and copies only the corresponding mapping channel allocation entries from the cea channel speaker allocation table. Thus the user can parse the TLV container to identify sink's capability and set the channel map accordingly. It shouldn't impact the behavior in AMD chipset, as this makes use of already parsed spk alloc block to calculate the channel map. Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> include/sound/hda_chmap.h | 2 ++ sound/hda/hdmi_chmap.c | 44 ++++++++++++++++++++++++++++++++++++++++---- sound/pci/hda/patch_hdmi.c | 13 +++++++++++++ 3 files changed, 55 insertions(+), 4 deletions(-) commit 7b9bc799a445aea95f64f15e0083cb19b5789abe Author: Joseph Salisbury <joseph.salisbury@canonical.com> Date: Mon Mar 14 14:51:48 2016 -0400 ath5k: Change led pin configuration for compaq c700 laptop BugLink: http://bugs.launchpad.net/bugs/972604 Commit 09c9bae26b0d3c9472cb6ae45010460a2cee8b8d ("ath5k: add led pin configuration for compaq c700 laptop") added a pin configuration for the Compaq c700 laptop. However, the polarity of the led pin is reversed. It should be red for wifi off and blue for wifi on, but it is the opposite. This bug was reported in the following bug report: http://pad.lv/972604 Fixes: 09c9bae26b0d3c9472cb6ae45010460a2cee8b8d ("ath5k: add led pin configuration for compaq c700 laptop") Signed-off-by: Joseph Salisbury <joseph.salisbury@canonical.com> Cc: stable@vger.kernel.org Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath5k/led.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d5efd0888331a0f7ed2e1d5a6977a32b7e9bfb7 Author: Peter Oh <poh@qca.qualcomm.com> Date: Tue Mar 22 15:44:53 2016 -0700 ath10k: parse Rx MAC timestamp in mgmt frame for FW 10.4 Check and parse Rx MAC timestamp when firmware sets its flag to status variable. 10.4 firmware adds it in Rx beacon frame only at this moment. Drivers and mac80211 may utilize it to detect such clockdrift or beacon collision and use the result for beacon collision avoidance. Signed-off-by: Peter Oh <poh@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 5c86d97bcc1d42ce7f75685a61be4dad34ee8183 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:19 2016 +0530 ath10k: combine txrx and replenish task Since tx completion and rx indication processing are moved out of txrx tasklet and rx ring lock contention also removed from txrx for rx_ind messages, it would be efficient to combine both replenish and txrx tasks. Refill threshold is adjusted for both AP135 and AP148 (low and high end systems). With this adjustment in AP135, TCP DL is improved from 603 Mbps to 620 Mbps and UDP DL is improved from 758 Mbps to 803 Mbps. Also no watchdog are observed on UDP BiDi. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 3 +-- drivers/net/wireless/ath/ath10k/htt_rx.c | 21 ++++++--------------- 2 files changed, 7 insertions(+), 17 deletions(-) commit 128abd09134a5b415fef4373841ea6d3fb7b680f Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:18 2016 +0530 ath10k: reuse copy engine 5 (htt rx) descriptors Whenever htt rx indication i.e target to host messages are received on rx copy engine (CE5), the message will be freed after processing the response. Then CE 5 will be refilled with new descriptors at post rx processing. This memory alloc and free operations can be avoided by reusing the same descriptors. During CE pipe allocation, full ring is not initialized i.e n-1 entries are filled up. So for CE 5 full ring should be filled up to reuse descriptors. Moreover CE 5 write index will be updated in single shot instead of incremental access. This could avoid multiple pci_write and ce_ring access. From experiments, It improves CPU usage by ~3% in IPQ4019 platform. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/ce.c | 23 +++++++++++-- drivers/net/wireless/ath/ath10k/ce.h | 3 ++ drivers/net/wireless/ath/ath10k/pci.c | 63 +++++++++++++++++++++++++++++++++-- 3 files changed, 84 insertions(+), 5 deletions(-) commit 24d9ef5eff5057bb6339ed1cf852a2b2a7be324d Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:17 2016 +0530 ath10k: cleanup copy engine receive next completion The physical address necessary to unmap DMA ('bufferp') is stored in ath10k_skb_cb as 'paddr'. For diag register read and write operations, 'paddr' is stored in transfer context. ath10k doesn't rely on the meta/transfer_id. So the unused output arguments {bufferp, nbytesp and transfer_idp} are removed from CE recv_next completion. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/ce.c | 21 +++-------------- drivers/net/wireless/ath/ath10k/ce.h | 10 ++------ drivers/net/wireless/ath/ath10k/pci.c | 43 ++++++++++++++--------------------- 3 files changed, 22 insertions(+), 52 deletions(-) commit e3a91f877c60ce8b29d8cd180c23f3de33a7d7e1 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:16 2016 +0530 ath10k: register ath10k_htt_htc_t2h_msg_handler Except qca61x4 family chips (qca6164, qca6174), copy engine 5 is used for receiving target to host htt messages. In follow up patch, CE5 descriptors will be reused. In such case, same API can not be used as htc layer callback where the response messages will be freed at the end. Hence register new API for HTC layer that free up received message and keep the message handler common for both HTC and HIF layers. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.c | 2 +- drivers/net/wireless/ath/ath10k/htt.h | 3 ++- drivers/net/wireless/ath/ath10k/htt_rx.c | 22 +++++++++++++++------- 3 files changed, 18 insertions(+), 9 deletions(-) commit 3128b3d8a2b97ba8fe38b21c3ed70c2c66cc7a9e Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:15 2016 +0530 ath10k: speedup htt rx descriptor processing for rx_ind In follow up patch, htt rx descriptors will be reused instead of dealloc and refill. To achieve that htt rx indication messages should not be deferred and should be processed in pci tasklet itself. Also from rx indication message, mpdu_count alone is used. So it is maintained as atomic variable and all rx amsdu handlers are done processed from txrx tasklet. This change get rid of rx_compl_q usage. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 1 + drivers/net/wireless/ath/ath10k/htt_rx.c | 39 +++++++++++++++----------------- 2 files changed, 19 insertions(+), 21 deletions(-) commit 18235664e7f9a5664cbef25d23b222ff2faf55bc Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:14 2016 +0530 ath10k: cleanup amsdu processing for rx indication Make amsdu handlers (i.e amsdu_pop and rx_h_handler) common to both rx_ind and frag_ind htt events. It is sufficient to hold rx_ring lock for amsdu_pop alone and no need to hold it until the packets are delivered to mac80211. This helps to reduce rx_lock contention as well. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 100 +++++++++++++------------------ 1 file changed, 41 insertions(+), 59 deletions(-) commit 6b61d6632a358bc72e14de03ba491907d871c94e Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:13 2016 +0530 ath10k: remove unused fw_desc processing The fw descriptor was never used and probably never will be. It makes little sense to maintain support for it. Remove it and simplify rx processing. This will make it easier to optimize rx processing later as well. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 65 +------------------------------- 1 file changed, 2 insertions(+), 63 deletions(-) commit b2fdbccd15a27d1115a780dcbdcc874e0c9f4abe Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:12 2016 +0530 ath10k: copy tx fetch indication message To optmize CPU usage htt rx descriptors will be reused instead of refilling it for htt rx copy engine (CE5). To support that all htt rx indications should be proecssed at same context. Instead of queueing actual indication message, queue copied message for txrx processing. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 59465fe46ef1c2caf2c1beca828c4f29d28b98ca Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 22 17:22:11 2016 +0530 ath10k: speedup htt rx descriptor processing for tx completion To optimize CPU usage htt rx descriptors will be reused instead of refilling it for htt rx copy engine (CE5). To support that all htt rx indications should be processed at same context. FIFO queue is used to maintain tx completion status for each msdu. This helps to retain the order of tx completion. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 18 +++++++--- drivers/net/wireless/ath/ath10k/htt_rx.c | 58 ++++++++++++++++++-------------- drivers/net/wireless/ath/ath10k/htt_tx.c | 14 +++++++- drivers/net/wireless/ath/ath10k/txrx.c | 12 +++---- 4 files changed, 65 insertions(+), 37 deletions(-) commit f9575793d44ce68b574d9d8ffb9813eb05c3fd2b Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Wed Mar 16 18:13:34 2016 +0530 ath10k: enable parsing per station rx duration for 10.4 Rx duration support for per station is part of extended peer stats, enable provision to parse the same and provide backward compatibility based on the 'stats_id' event Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 19 ++++++++++++++++++- drivers/net/wireless/ath/ath10k/wmi.c | 30 ++++++++++++++++++++++++------ drivers/net/wireless/ath/ath10k/wmi.h | 16 ++++++++++++++++ 3 files changed, 58 insertions(+), 7 deletions(-) commit 86e3ef812fe3df8298c0bee81b0c786006a9c85c Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:04 2016 +0300 pinctrl: baytrail: Update gpio chip operations This patch updates the gpio chip implementation in order to interact with the pin control model: the chip contains reference to SOC data and pin/group/community information is retrieved through the SOC reference. Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 97 ++++++++++++++++++++++---------- 1 file changed, 68 insertions(+), 29 deletions(-) commit c501d0b149de1248fa9c29c906bf70f3b87b8bd8 Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:03 2016 +0300 pinctrl: baytrail: Add pin control operations Add implementation for: - pin control, group information retrieval: count, name and pins - pin muxing: - function information (count, name and groups) - mux setting - gpio control (enable, disable, set direction) - pin configuration: - pull disable - pull up/down and pull strength - debounce - any other option is treated as not supported. Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/Kconfig | 3 + drivers/pinctrl/intel/pinctrl-baytrail.c | 560 +++++++++++++++++++++++++++++-- 2 files changed, 528 insertions(+), 35 deletions(-) commit c8f5c4c7c82c916faf4699927801c8038d1fac51 Author: Cristina Ciocan <cristina.ciocan@intel.com> Date: Fri Apr 1 14:00:02 2016 +0300 pinctrl: baytrail: Add pin control data structures In order to implement pin control for Baytrail, we need data structures in which to store and pass along pin, group, function, community and SOC data information. Baytrail has 3 GPIO controllers. Add SCORE, NCORE and SUS controller data: - pins (for all controllers), - pad map for pins (for all controllers; we need this since pads are not ordered), - groups (for SCORE and SUS controllers), - functions (for SCORE and SUS controllers), - communities (for all controllers), - soc specific data gathering all of the above and the ACPI UID (for all controllers) This information is useful for pin control functionality. NCORE data is lighter than the other two controllers' due to lack of pin documentation in the public datasheet. Datasheet: http://www.intel.com/content/www/us/en/embedded/products/bay-trail/atom-e3800-family-datasheet.html Signed-off-by: Cristina Ciocan <cristina.ciocan@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/intel/pinctrl-baytrail.c | 628 +++++++++++++++++++++++++++++-- 1 file changed, 606 insertions(+), 22 deletions(-) commit 0bf676d1fd5144e66ac06939fa3c7c12086c3b18 Author: Jiri Slaby <jslaby@suse.cz> Date: Thu Mar 31 10:49:28 2016 +0200 audit: cleanup prune_tree_thread We can use kthread_run instead of kthread_create+wake_up_process for creating the thread. We do not need to set the task state to TASK_RUNNING after schedule(), the process is in that state already. And we do not need to set the state to TASK_INTERRUPTIBLE when not doing schedule() as we set the state to TASK_RUNNING immediately afterwards. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: Paul Moore <paul@paul-moore.com> Cc: Eric Paris <eparis@redhat.com> Cc: <linux-audit@redhat.com> Signed-off-by: Paul Moore <paul@paul-moore.com> kernel/audit_tree.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 47771902a9beb23859805721f1d98d03dee5da7c Author: Raja Mani <rmani@qti.qualcomm.com> Date: Wed Mar 16 18:13:33 2016 +0530 ath10k: introduce Extended Resource Config support for 10.4 Add API support for Extended Resource Configuration for 10.4. This is useful to enable new features like Peer Stats, LTEU etc if the firmware advertises support for the service. This is also done to provide backward compatibility with older firmware. Also for clarity send default host platform type as 'WMI_HOST_PLATFORM_HIGH_PERF', though this should not make any difference in functionality Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi-ops.h | 23 +++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi.c | 24 ++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/wmi.h | 31 +++++++++++++++++++++++++++++++ 3 files changed, 78 insertions(+) commit 903589ca7165c41d149d902a06006b0f2b975231 Author: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Date: Fri Apr 1 10:47:22 2016 +0100 ARM: 8554/1: kernel: pci: remove pci=firmware command line parameter handling According to kernel documentation, the pci=firmware command line parameter is only meant to be used on IXP2000 ARM platforms to prevent the kernel from assigning PCI resources configured by the bootloader. Since the IXP2000 ARM platforms support has been removed from the kernel in commit: commit c65f2abf54a6 ("ARM: remove ixp23xx and ixp2000 platforms") its platforms specific kernel parameters should be removed too from the kernel documentation along with the kernel code currently handling them in that they have just become obsolete. This patch removes the pci=firmware command line parameter handling from ARM code and the related kernel parameters documentation section. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Lennert Buytenhek <kernel@wantstofly.org> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Lennert Buytenhek <kernel@wantstofly.org> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Bjorn Helgaas <bhelgaas@google.com> Cc: Rob Herring <robh@kernel.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Documentation/kernel-parameters.txt | 5 ----- arch/arm/kernel/bios32.c | 3 --- 2 files changed, 8 deletions(-) commit ef859312c3a16b42f398e6dbb14de23bffd5dd41 Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Mon Mar 14 16:51:09 2016 +0200 dmaengine: core: Use dev_ functions for debug and error prints According to dmaengine kerneldoc the struct dma_chan has always a non-NULL pointer to DMA device and a test in dma_async_device_register() validates that DMA device must also point to struct device. All pr_ prints except one in dma_channel_table_init() have valid DMA channel or DMA device pointer available which allow convert them to use dev_ functions and thus able to show the associated DMA device. Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> drivers/dma/dmaengine.c | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) commit 27af5eea54d161e1636001a7f2b5efd3b7a3d1f9 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Mon Apr 4 12:11:56 2016 +0100 drm/i915: Move execlists irq handler to a bottom half Doing a lot of work in the interrupt handler introduces huge latencies to the system as a whole. Most dramatic effect can be seen by running an all engine stress test like igt/gem_exec_nop/all where, when the kernel config is lean enough, the whole system can be brought into multi-second periods of complete non-interactivty. That can look for example like this: NMI watchdog: BUG: soft lockup - CPU#0 stuck for 23s! [kworker/u8:3:143] Modules linked in: [redacted for brevity] CPU: 0 PID: 143 Comm: kworker/u8:3 Tainted: G U L 4.5.0-160321+ #183 Hardware name: Intel Corporation Broadwell Client platform/WhiteTip Mountain 1 Workqueue: i915 gen6_pm_rps_work [i915] task: ffff8800aae88000 ti: ffff8800aae90000 task.ti: ffff8800aae90000 RIP: 0010:[<ffffffff8104a3c2>] [<ffffffff8104a3c2>] __do_softirq+0x72/0x1d0 RSP: 0000:ffff88014f403f38 EFLAGS: 00000206 RAX: ffff8800aae94000 RBX: 0000000000000000 RCX: 00000000000006e0 RDX: 0000000000000020 RSI: 0000000004208060 RDI: 0000000000215d80 RBP: ffff88014f403f80 R08: 0000000b1b42c180 R09: 0000000000000022 R10: 0000000000000004 R11: 00000000ffffffff R12: 000000000000a030 R13: 0000000000000082 R14: ffff8800aa4d0080 R15: 0000000000000082 FS: 0000000000000000(0000) GS:ffff88014f400000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fa53b90c000 CR3: 0000000001a0a000 CR4: 00000000001406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Stack: 042080601b33869f ffff8800aae94000 00000000fffc2678 ffff88010000000a 0000000000000000 000000000000a030 0000000000005302 ffff8800aa4d0080 0000000000000206 ffff88014f403f90 ffffffff8104a716 ffff88014f403fa8 Call Trace: <IRQ> [<ffffffff8104a716>] irq_exit+0x86/0x90 [<ffffffff81031e7d>] smp_apic_timer_interrupt+0x3d/0x50 [<ffffffff814f3eac>] apic_timer_interrupt+0x7c/0x90 <EOI> [<ffffffffa01c5b40>] ? gen8_write64+0x1a0/0x1a0 [i915] [<ffffffff814f2b39>] ? _raw_spin_unlock_irqrestore+0x9/0x20 [<ffffffffa01c5c44>] gen8_write32+0x104/0x1a0 [i915] [<ffffffff8132c6a2>] ? n_tty_receive_buf_common+0x372/0xae0 [<ffffffffa017cc9e>] gen6_set_rps_thresholds+0x1be/0x330 [i915] [<ffffffffa017eaf0>] gen6_set_rps+0x70/0x200 [i915] [<ffffffffa0185375>] intel_set_rps+0x25/0x30 [i915] [<ffffffffa01768fd>] gen6_pm_rps_work+0x10d/0x2e0 [i915] [<ffffffff81063852>] ? finish_task_switch+0x72/0x1c0 [<ffffffff8105ab29>] process_one_work+0x139/0x350 [<ffffffff8105b186>] worker_thread+0x126/0x490 [<ffffffff8105b060>] ? rescuer_thread+0x320/0x320 [<ffffffff8105fa64>] kthread+0xc4/0xe0 [<ffffffff8105f9a0>] ? kthread_create_on_node+0x170/0x170 [<ffffffff814f351f>] ret_from_fork+0x3f/0x70 [<ffffffff8105f9a0>] ? kthread_create_on_node+0x170/0x170 I could not explain, or find a code path, which would explain a +20 second lockup, but from some instrumentation it was apparent the interrupts off proportion of time was between 10-25% under heavy load which is quite bad. When a interrupt "cliff" is reached, which was >~320k irq/s on my machine, the whole system goes into a terrible state of the above described multi-second lockups. By moving the GT interrupt handling to a tasklet in a most simple way, the problem above disappears completely. Testing the effect on sytem-wide latencies using igt/gem_syslatency shows the following before this patch: gem_syslatency: cycles=1532739, latency mean=416531.829us max=2499237us gem_syslatency: cycles=1839434, latency mean=1458099.157us max=4998944us gem_syslatency: cycles=1432570, latency mean=2688.451us max=1201185us gem_syslatency: cycles=1533543, latency mean=416520.499us max=2498886us This shows that the unrelated process is experiencing huge delays in its wake-up latency. After the patch the results look like this: gem_syslatency: cycles=808907, latency mean=53.133us max=1640us gem_syslatency: cycles=862154, latency mean=62.778us max=2117us gem_syslatency: cycles=856039, latency mean=58.079us max=2123us gem_syslatency: cycles=841683, latency mean=56.914us max=1667us Showing a huge improvement in the unrelated process wake-up latency. It also shows an approximate halving in the number of total empty batches submitted during the test. This may not be worrying since the test puts the driver under a very unrealistic load with ncpu threads doing empty batch submission to all GPU engines each. Another benefit compared to the hard-irq handling is that now work on all engines can be dispatched in parallel since we can have up to number of CPUs active tasklets. (While previously a single hard-irq would serially dispatch on one engine after another.) More interesting scenario with regards to throughput is "gem_latency -n 100" which shows 25% better throughput and CPU usage, and 14% better dispatch latencies. I did not find any gains or regressions with Synmark2 or GLbench under light testing. More benchmarking is certainly required. v2: * execlists_lock should be taken as spin_lock_bh when queuing work from userspace now. (Chris Wilson) * uncore.lock must be taken with spin_lock_irq when submitting requests since that now runs from either softirq or process context. v3: * Expanded commit message with more testing data; * converted missed locking sites to _bh; * added execlist_lock comment. (Chris Wilson) v4: * Mention dispatch parallelism in commit. (Chris Wilson) * Do not hold uncore.lock over MMIO reads since the block is already serialised per-engine via the tasklet itself. (Chris Wilson) * intel_lrc_irq_handler should be static. (Chris Wilson) * Cancel/sync the tasklet on GPU reset. (Chris Wilson) * Document and WARN that tasklet cannot be active/pending on engine cleanup. (Chris Wilson/Imre Deak) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Imre Deak <imre.deak@intel.com> Testcase: igt/gem_exec_nop/all Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94350 Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1459768316-6670-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_debugfs.c | 5 ++--- drivers/gpu/drm/i915/i915_gem.c | 10 +++++---- drivers/gpu/drm/i915/i915_irq.c | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 36 ++++++++++++++++++++------------- drivers/gpu/drm/i915/intel_lrc.h | 1 - drivers/gpu/drm/i915/intel_ringbuffer.h | 3 ++- 6 files changed, 33 insertions(+), 24 deletions(-) commit a99e31512aa435e8391ba5f5e64abeac9c5f2f32 Merge: 86c8dd7 f03b24a Author: Takashi Iwai <tiwai@suse.de> Date: Mon Apr 4 11:51:08 2016 +0200 Merge branch 'for-linus' into for-next Conflicts: sound/hda/hdac_i915.c Signed-off-by: Takashi Iwai <tiwai@suse.de> commit 7fbbe38aa11816ef15844238e8eb3164b887d265 Author: Arnd Bergmann <arnd@arndb.de> Date: Tue Feb 23 14:35:58 2016 +0100 ARM: realview: hide unused 'pmu_device' object The pmu_device is only accessed when CACHE_L2X0 is enabled, and we get a warning otherwise: mach-realview/realview_pbx.c:274:31: error: 'pmu_device' defined but not used [-Werror=unused-variable] This adds another #ifdef for it. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/mach-realview/realview_pbx.c | 2 ++ 1 file changed, 2 insertions(+) commit fccc2b3675371e4077d7aa7f23d116e97dcdcd07 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Feb 18 14:21:54 2016 +0100 soc: versatile: dynamically detect RealView HBI numbers We cannot pile all numbers on this list, just print the three hex digits representing the board ID so we can handle all the new RealView boards. Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/soc/versatile/soc-realview.c | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) commit dfc8a117388786ab3cfdf0880a09abd05c4e0a4d Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Feb 23 16:51:35 2016 +0100 ARM: dts: realview: DT support for the PBA8 and PBX-A9 This adds a devicetree for the ARM RealView PBA8 platform, also known as HBI-0178, "RealView Platform Baseboard for Cortex-A8" and PBX-A9 "RealView Platform Baseboard Explore for Cortex-A9" Tested in QEMU with -M realview-pb-a8, as well as with -M realview-pbx-a9 -smp cpus=2 Cc: Arnd Bergmann <arnd@arndb.de> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Peter Maydell <peter.maydell@linaro.org> Cc: Marc Zyngier <marc.zyngier@arm.com> Tested-by: Robin Murphy <robin.murphy@arm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/Makefile | 4 +- arch/arm/boot/dts/arm-realview-pba8.dts | 178 ++++++++++ arch/arm/boot/dts/arm-realview-pbx-a9.dts | 229 +++++++++++++ arch/arm/boot/dts/arm-realview-pbx.dtsi | 542 ++++++++++++++++++++++++++++++ 4 files changed, 952 insertions(+), 1 deletion(-) commit 2440d29d2ae2b4f3b1d1ae87c8130351793d6df6 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Feb 18 14:23:31 2016 +0100 ARM: dts: realview: support all the RealView EB board variants The ARM RealView Evaluation Baseboards are basically these: - The original ARMv5 EB board with an ARM926EJ-S, ARM1136 or ARM1176 core tile here described in arm-realview-eb.dts no matter which of these core tiles is being used. This can be emulated by QEMU "realview-eb" machine, which by default will have the ARM926EJ-S core tile. - The same board with one of three MPCore Core tiles: ARM11MPCore, not to be confused with the similar ARM PB11MPCore ARM11MPCore test system. This exist in two revisions: - Revision A modeled in arm-realview-eb-11mp.dts - Revision B modeled arm-realview-eb-11mp-revb.dts Revision B can be emulated by the QEMU "realview-eb-mpcore" machine, but to match the hardware also the argument -smp cpus=4 must be passed so that it has four CPU cores, like the hardware. There is also evidently from the code in the kernel a Cortex-A9 core tile for the EB, and this is modeled in arm-realview-eb-a9mp.dts based on the kernel boardfile. I have not found a user guide for this EB core tile on the ARM website and it seems uncommon. It is however included for completeness. Cc: Pawel Moll <pawel.moll@arm.com> Cc: Peter Maydell <peter.maydell@linaro.org> Cc: Marc Zyngier <marc.zyngier@arm.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/Makefile | 6 +- arch/arm/boot/dts/arm-realview-eb-11mp-revb.dts | 93 +++++ arch/arm/boot/dts/arm-realview-eb-11mp.dts | 74 ++++ arch/arm/boot/dts/arm-realview-eb-a9mp.dts | 70 ++++ arch/arm/boot/dts/arm-realview-eb-mp.dtsi | 225 ++++++++++++ arch/arm/boot/dts/arm-realview-eb.dts | 166 +++++++++ arch/arm/boot/dts/arm-realview-eb.dtsi | 453 ++++++++++++++++++++++++ 7 files changed, 1086 insertions(+), 1 deletion(-) commit 95109b8b4d425d48c802acfc5c6e38f55c6e7fb5 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Feb 1 11:07:20 2016 +0100 ARM: dts: realview: PB1176: define a standard VGA panel This defines the CLCD block in the PB1176 and adds a standard 640x480 VGA panel to the device tree. Cc: Pawel Moll <pawel.moll@arm.com> Cc: Rob Herring <robh@kernel.org> Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/arm-realview-pb1176.dts | 40 +++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 6096188af679b00aa4f55c641945628d3bd1c1bd Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Feb 1 11:05:26 2016 +0100 ARM: dts: realview: PB11MPCore: define a standard VGA panel Let's supply a standard VGA panel by default on the PB11MPCore, this will work with most monitors. If more screen real estate is desired, users can update the DPI definition. Cc: Pawel Moll <pawel.moll@arm.com> Cc: Rob Herring <robh@kernel.org> Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/arm-realview-pb11mp.dts | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) commit 1a66ab2ddc4756ee2887301a55d502139fe37e73 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Feb 4 14:53:12 2016 +0100 Documentation/DT: add blurb for IB2 syscon to Versatile The ARM Versatile has an optional daughterboard, if this is mounted, we need to be able to access its system controller. Put in a documentation blurb for this. Cc: Pawel Moll <pawel.moll@arm.com> Cc: Rob Herring <robh@kernel.org> Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/devicetree/bindings/arm/arm-boards | 8 ++++++++ 1 file changed, 8 insertions(+) commit 91011a7605822cd9c16eabcd1cc11ae31d604bfd Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Jan 26 11:09:22 2016 +0100 ARM: integrator: move flash registration to device tree The flash on the Integrator was already defined by the device tree, but VPP control and flash protection was in the boardfiles. Simply add the compatible string "arm,versatile-flash" and the special add-on code for flash programming voltage and protection kicks in in the MTD layer. Remove the board file code and augment the device tree in one go for seamless transition. Cc: Grant Likely <grant.likely@linaro.org> Cc: Rob Herring <robh@kernel.org> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/integrator.dtsi | 3 +- arch/arm/mach-integrator/integrator_ap.c | 62 -------------------------------- arch/arm/mach-integrator/integrator_cp.c | 51 -------------------------- 3 files changed, 2 insertions(+), 114 deletions(-) commit 7bb73fd719805dc40616d0c0dcd1d2d1e17b9b23 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Jan 26 10:55:32 2016 +0100 ARM: versatile: move flash registration to the device tree This moves the boardfile definition of the flash memory in the Versatile board into the device tree. The flash was already defined with the property "arm,versatile-flash" which was not handled by the kernel: instead define it as compatible also with "cfi-flash" so it detects properly, and delete the corresponding boardfile code so we get a smooth transition. The old compatible string "arm,versatile-flash" is reused to indicate to the MTD physmap subsystem that this flash requires special VPP handling. (See separate patch.) Cc: Grant Likely <grant.likely@linaro.org> Cc: Rob Herring <robh@kernel.org> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/versatile-ab.dts | 5 ++-- arch/arm/mach-versatile/versatile_dt.c | 47 ---------------------------------- 2 files changed, 3 insertions(+), 49 deletions(-) commit 81fc3eb2b3c253b9aa5f55b6af5246a6c431dbf4 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Jan 26 12:00:13 2016 +0100 mtd: augment the "arm,versatile-flash" bindings The bindings for the "arm,versatile-flash" device was merged in commit 3ba7222ac992d24d09ccd0b55940b54849eef752 "arm/versatile: Add device tree support" but was never used for anything. Versatile flash chips are actually just standard CFI chips, but they have one or two bits in a system controller to control VPP and write protection. Let's use this compatible string in conjunction with "cfi-flash" to indicate that we have a normal CFI flash with some extra Versatile-specific protection. Cc: devicetree@vger.kernel.org Cc: Grant Likely <grant.likely@linaro.org> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Mark Rutland <mark.rutland@arm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> .../devicetree/bindings/mtd/arm-versatile.txt | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) commit b0afd44bc192ff4c0e90a5fc1724350bcfc32b33 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Jan 26 11:58:07 2016 +0100 mtd: physmap_of: add a hook for Versatile write protection In order to support device tree probing of Versatile NOR flash chips, there must be a way to add the VPP (write protection) enable/disable callback. The register in question is in the system controllers of these machines. Apart from this quirk, the ARM flash chips are standard CFI flash chips from various vendors. Additionally, the Integrator/AP require you to set up the external bus interface (EBI) to allow writes to the chip select where the flash memory is connected. Solve this by looking for the arm,versatile-flash compatible string in the flash device tree node. In the driver, add a special hook to check for the various Versatile syscons and register a callback for .set_vpp() if this compatible is present. Provide a special Kconfig entry for the addon hook so it will not be compiled in if the Versatile boards are not supported. Stubs in the header file make sure the impact will be zero on other platforms. (Compilers optimze this out.) With this patch, a large slew of ARM board file code can be removed. Cc: Grant Likely <grant.likely@linaro.org> Cc: Rob Herring <robh@kernel.org> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/mtd/maps/Kconfig | 10 ++ drivers/mtd/maps/Makefile | 1 + drivers/mtd/maps/physmap_of.c | 6 + drivers/mtd/maps/physmap_of_versatile.c | 253 ++++++++++++++++++++++++++++++++ drivers/mtd/maps/physmap_of_versatile.h | 16 ++ 5 files changed, 286 insertions(+) commit 9ab9e4fce45379cb6a7dbf87cf8f8e6ba01853c2 Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Feb 22 15:02:08 2016 +0100 ARM: memremap: implement arch_memremap_wb() The generic memremap() falls back to using ioremap_cache() to create MEMREMAP_WB mappings if the requested region is not already covered by the linear mapping, unless the architecture provides an implementation of arch_memremap_wb(). Since ioremap_cache() is not appropriate on ARM to map memory with the same attributes used for the linear mapping, implement arch_memremap_wb() which does exactly that. Also, relax the WARN() check to allow MT_MEMORY_RW mappings of pfn_valid() pages. Cc: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> arch/arm/include/asm/io.h | 6 ++++++ arch/arm/mm/ioremap.c | 12 ++++++++++-- arch/arm/mm/nommu.c | 5 +++++ 3 files changed, 21 insertions(+), 2 deletions(-) commit c269cba35b061181bc23c470809c00e8f71e535a Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Mon Feb 22 15:02:07 2016 +0100 memremap: add arch specific hook for MEMREMAP_WB mappings Currently, the memremap code serves MEMREMAP_WB mappings directly from the kernel direct mapping, unless the region is in high memory, in which case it falls back to using ioremap_cache(). However, the semantics of ioremap_cache() are not unambiguously defined, and on ARM, it will actually result in a mapping type that differs from the attributes used for the linear mapping, and for this reason, the ioremap_cache() call fails if the region is part of the memory managed by the kernel. So instead, implement an optional hook 'arch_memremap_wb' whose default implementation calls ioremap_cache() as before, but which can be overridden by the architecture to do what is appropriate for it. Acked-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> kernel/memremap.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 7769aea2a27db8f12859dcecce37a3da44ab588b Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Thu Feb 25 08:57:52 2016 +0100 mtd: pxa2xx-flash: switch back from memremap to ioremap_cached This reverts commit 06968a54790d ("mtd: pxa2xx-flash: switch from ioremap_cache to memremap"), since NOR with memory semantics in array mode and RAM are not necessarily the same thing, and architectures may implement ioremap_cached() and memremap() with different memory attributes. For this reason, ioremap_cached() has been brought back from the dead on the ARM side, so switch this driver back to using it instead of memremap(). Cc: David Woodhouse <dwmw2@infradead.org> Acked-by: Brian Norris <computersforpeace@gmail.com> Acked-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> drivers/mtd/maps/pxa2xx-flash.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 20c5ea4fc131dc45c2639653b5b7aeeb2d4d0d1e Author: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Fri Mar 4 10:05:39 2016 +0100 ARM: reintroduce ioremap_cached() for creating cached I/O mappings The original ARM-only ioremap flavor 'ioremap_cached' has been renamed to 'ioremap_cache' to align with other architectures, and subsequently abused in generic code to map things like firmware tables in memory. For that reason, there is currently an effort underway to deprecate ioremap_cache, whose semantics are poorly defined, and which is typed with an __iomem annotation that is inappropriate for mappings of ordinary memory. However, original users of ioremap_cached() used it in a context where the I/O connotation is appropriate, and replacing those instances with memremap() does not make sense. So let's revive ioremap_cached(), so that we can change back those original users before we drop ioremap_cache entirely in favor of memremap. Cc: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> arch/arm/include/asm/io.h | 6 ++++++ arch/arm/mm/ioremap.c | 4 ++++ arch/arm/mm/nommu.c | 4 ++++ 3 files changed, 14 insertions(+) commit b94f7d5ddf1b114e66d9bcc07d0ead080470383b Author: Yusuke Fujimaki <usk.fujimaki@gmail.com> Date: Sun Apr 3 23:15:16 2016 +0900 HID: asus: add support for VivoBook E200HA Asus X205TA and E200HA built-in keyboard contain wrong logical maximum value in report descriptor. This patch correct wrong logical maximum in report descriptor. Signed-off-by: Yusuke Fujimaki <usk.fujimaki@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/Kconfig | 6 +++++- drivers/hid/hid-asus.c | 12 ++++++++---- drivers/hid/hid-core.c | 2 +- drivers/hid/hid-ids.h | 2 +- 4 files changed, 15 insertions(+), 7 deletions(-) commit 6edac6fde59e231bd297ebcbc3d1bd395006cd1d Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Sat Apr 2 07:45:01 2016 +0300 HID: hidraw: silence an uninitialized variable warning My static checker complains that "devid" can be uninitialized if alloc_chrdev_region() fails. Fix this by moving the error hanling forward a couple lines. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hidraw.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 85d08340c3de1126467db4e69140fe483d91c114 Author: Dan Carpenter <dan.carpenter@oracle.com> Date: Sat Apr 2 07:44:32 2016 +0300 HID: roccat: silence an uninitialized variable warning My static checker complains because we use "dev_id" before we check for errors so it could be uninitialized. Fix this by moving the error handling forward a couple lines. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hid-roccat.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 183aec16445f6e08c4ea6e3d5cb8f8c3d56339c1 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sun Apr 3 21:59:14 2016 +0100 drm/i915/ddi: Silence compiler warning for unknown output type Silences src/drivers/gpu/drm/i915/intel_ddi.c: warning: 'port' may be used uninitialized in this function [-Wuninitialized] Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1459717154-27607-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_ddi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 5651d6aaf489d1db48c253cf884b40214e91c2c5 Author: Brian Norris <computersforpeace@gmail.com> Date: Fri Feb 26 11:50:28 2016 +0100 mtd: bcm47xxsflash: use ioremap_cache() instead of KSEG0ADDR() Using KSEG0ADDR makes code highly MIPS dependent and not portable. Thanks to the fix a68f376 ("MIPS: io.h: Define `ioremap_cache'") we can use ioremap_cache which is generic and supported on MIPS as well now. KSEG0ADDR was translating 0x1c000000 into 0x9c000000. With ioremap_cache we use MIPS's __ioremap (and then remap_area_pages). This results in different address (e.g. 0xc0080000) but it still should be cached as expected and it was successfully tested with BCM47186B0. Other than that drivers/bcma/driver_chipcommon_sflash.c nicely setups a struct resource for access window, but we wren't using it. Use it now and drop duplicated info. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Rafał Miłecki <zajec5@gmail.com> drivers/bcma/driver_chipcommon_sflash.c | 1 - drivers/mtd/devices/bcm47xxsflash.c | 29 ++++++++++++++++++++++++----- drivers/mtd/devices/bcm47xxsflash.h | 3 ++- include/linux/bcma/bcma_driver_chipcommon.h | 1 - 4 files changed, 26 insertions(+), 8 deletions(-) commit 7367ab9157d6829351dd4aa404352402f064686c Merge: bc61384 03cc078 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sun Apr 3 19:53:20 2016 -0400 Merge branch 'for-linus' into work.iov_iter commit bc61384dcdd82a6faabafecdcd80040625db5e40 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Mar 31 21:48:20 2016 -0400 rw_verify_area(): saner calling conventions Lift length capping into the few callers that care about it. Most of them treat all non-negatives as "success" and ignore the capped value, and with good reasons. Make rw_verify_area() return 0 on success. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/read_write.c | 33 ++++++++++++++------------------- 1 file changed, 14 insertions(+), 19 deletions(-) commit 2958ec177e400be1e26fc37e1759f84fa2c1761c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Mar 31 21:34:25 2016 -0400 aio: remove a pointless assignment the value is never used after that point Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/aio.c | 2 -- 1 file changed, 2 deletions(-) commit fddcca5107051adf9e4481d2a79ae0616577fd2c Author: Arnd Bergmann <arnd@arndb.de> Date: Mon Feb 29 13:20:28 2016 +0100 mtd: avoid stack overflow in MTD CFI code When map_word gets too large, we use a lot of kernel stack, and for MTD_MAP_BANK_WIDTH_32, this means we use more than the recommended 1024 bytes in a number of functions: drivers/mtd/chips/cfi_cmdset_0020.c: In function 'cfi_staa_write_buffers': drivers/mtd/chips/cfi_cmdset_0020.c:651:1: warning: the frame size of 1336 bytes is larger than 1024 bytes [-Wframe-larger-than=] drivers/mtd/chips/cfi_cmdset_0020.c: In function 'cfi_staa_erase_varsize': drivers/mtd/chips/cfi_cmdset_0020.c:972:1: warning: the frame size of 1208 bytes is larger than 1024 bytes [-Wframe-larger-than=] drivers/mtd/chips/cfi_cmdset_0001.c: In function 'do_write_buffer': drivers/mtd/chips/cfi_cmdset_0001.c:1835:1: warning: the frame size of 1240 bytes is larger than 1024 bytes [-Wframe-larger-than=] This can be avoided if all operations on the map word are done indirectly and the stack gets reused between the calls. We can mostly achieve this by selecting MTD_COMPLEX_MAPPINGS whenever MTD_MAP_BANK_WIDTH_32 is set, but for the case that no other bank width is enabled, we also need to use a non-constant map_bankwidth() to convince the compiler to use less stack. Signed-off-by: Arnd Bergmann <arnd@arndb.de> [Brian: this patch mostly achieves its goal by forcing MTD_COMPLEX_MAPPINGS (and the accompanying indirection) for 256-bit mappings; the rest of the change is mostly a wash, though it helps reduce stack size slightly. If we really care about supporting 256-bit mappings though, we should consider rewriting some of this code to avoid keeping and assigning so many 256-bit objects on the stack.] Signed-off-by: Brian Norris <computersforpeace@gmail.com> drivers/mtd/chips/Kconfig | 1 + include/linux/mtd/map.h | 19 +++++++------------ 2 files changed, 8 insertions(+), 12 deletions(-) commit a156e64dd6bf609ae5c366e1676e580dca239e3e Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sun Apr 3 14:14:21 2016 +0100 drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status As the current PCI power state is an essential feature of runtime pm, include it in the debugfs/i915_runtime_pm_status. v2: Use pci_power_name() Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Imre Deak <imre.deak@intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459689261-7920-2-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit 188c1ab7769dd7c092f9b1be5f69aa34d4a6f9d6 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sun Apr 3 14:14:20 2016 +0100 drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Since describe_obj() looks at state guarded by the struct_mutex, we need to be holding it. [ 580.201054] drv_suspend: starting subtest debugfs-reader [ 580.239652] ------------[ cut here ]------------ [ 580.239696] WARNING: CPU: 0 PID: 920 at include/linux/list_check.h:25 describe_obj+0x419/0x440() [ 580.239725] CPU: 0 PID: 920 Comm: cat Not tainted 4.5.0-rc6+ #835 [ 580.239745] Hardware name: /NUC5CPYB, BIOS PYBSWCEL.86A.0027.2015.0507.1758 05/07/2015 [ 580.239767] 0000000000000000 ffff88027554fcf8 ffffffff812c1135 0000000000000000 [ 580.239815] ffffffff8193dc42 ffff88027554fd30 ffffffff8107419d ffff880071727c00 [ 580.239858] ffff8802757d8000 ffffffff818f693c ffffffff818f693c ffff8802757b9048 [ 580.239896] Call Trace: [ 580.239917] [<ffffffff812c1135>] dump_stack+0x67/0x92 [ 580.239939] [<ffffffff8107419d>] warn_slowpath_common+0x7d/0xb0 [ 580.239959] [<ffffffff810742ba>] warn_slowpath_null+0x1a/0x20 [ 580.239981] [<ffffffff813ce579>] describe_obj+0x419/0x440 [ 580.240006] [<ffffffff813ced22>] i915_gem_framebuffer_info+0xa2/0x100 [ 580.240033] [<ffffffff811a9286>] seq_read+0xe6/0x3b0 [ 580.240059] [<ffffffff81182288>] __vfs_read+0x28/0xd0 [ 580.240085] [<ffffffff81173378>] ? SyS_fadvise64+0x228/0x2c0 [ 580.240112] [<ffffffff811823b2>] vfs_read+0x82/0x110 [ 580.240137] [<ffffffff811827d9>] SyS_read+0x49/0xa0 [ 580.240162] [<ffffffff815bac57>] entry_SYSCALL_64_fastpath+0x12/0x6b [ 580.240187] ---[ end trace 3e2cbf34576c9878 ]--- [ 580.281900] ------------[ cut here ]------------ Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459689261-7920-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_debugfs.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 486294f184c05cff116160bb731cbb679f047621 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Tue Mar 29 15:21:21 2016 +0300 iio: accel: bmc150: use common definition for regmap conf bmc150_i2c_regmap_conf is defined three times (in bmc150-accel-core.c, bmc150-accel-i2c.c and and bmc150-accel-spi.c), although the definition is the same. Use one common definition for bmc150_i2c_regmap_conf in all included files. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/bmc150-accel-core.c | 3 ++- drivers/iio/accel/bmc150-accel-i2c.c | 7 +------ drivers/iio/accel/bmc150-accel-spi.c | 8 +------- drivers/iio/accel/bmc150-accel.h | 1 + 4 files changed, 5 insertions(+), 14 deletions(-) commit fa4c9c93e93f429bb8a8b01c53d54d6bd53a3028 Author: Crestez Dan Leonard <leonard.crestez@intel.com> Date: Tue Mar 29 19:14:27 2016 +0300 hp206c: Initial support for reading sensor values Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/Kconfig | 10 + drivers/iio/pressure/Makefile | 1 + drivers/iio/pressure/hp206c.c | 426 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 437 insertions(+) commit d409404cf6e201c2980c7148484c350f33a7912e Author: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Date: Sun Mar 20 16:20:23 2016 +0100 iio: Add channel for UV index UV index indicating strength of sunburn-producing ultraviolet (UV) radiation Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio | 9 +++++++++ drivers/iio/industrialio-core.c | 1 + include/uapi/linux/iio/types.h | 1 + tools/iio/iio_event_monitor.c | 2 ++ 4 files changed, 13 insertions(+) commit 2c5ff1f9a6240d7d2d0928021cb76e421d6aacaf Author: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Date: Sun Mar 20 16:20:22 2016 +0100 iio: Add modifier for UV light Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio | 4 +++- drivers/iio/industrialio-core.c | 1 + include/uapi/linux/iio/types.h | 1 + tools/iio/iio_event_monitor.c | 2 ++ 4 files changed, 7 insertions(+), 1 deletion(-) commit eaa3476a7ee27c9927531781c8b25365d77e3030 Author: Marc Titinger <mtitinger@baylibre.com> Date: Fri Mar 11 15:52:30 2016 +0100 iio: ina2xx-adc: fix scale for VShunt The scale would result in uV instead of expected mV. Mostly cosmetic, since the value of 'Power' was computed OK. Signed-off-by: Marc Titinger <marc.titinger@baylibre.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/ina2xx-adc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d65113222c27e2ca0b292a5163ea294428d481b2 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Tue Mar 22 17:08:46 2016 +0100 iio:adc:at91-sama5d2: add support for differential conversions Add signed differential channels and update the voltage scale for differential conversions. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/at91-sama5d2_adc.c | 71 ++++++++++++++++++++++++++++++-------- 1 file changed, 56 insertions(+), 15 deletions(-) commit 94b24230196da3cd6bd58235137f9a7438983c73 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Tue Mar 22 17:08:45 2016 +0100 iio:adc:at91-sama5d2: cleanup mode register use Do not erase previous configuration of the mode register when setting the sampling frequency. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/at91-sama5d2_adc.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) commit 22d199a53910e2b1666bf873f10779a66844c126 Author: Slawomir Stepien <sst@poczta.fm> Date: Wed Mar 23 09:57:20 2016 +0100 iio: potentiometer: add driver for Microchip MCP413X/414X/415X/416X/423X/424X/425X/426X The following functionalities are supported: - write, read from volatile memory Datasheet: http://ww1.microchip.com/downloads/en/DeviceDoc/22060b.pdf Signed-off-by: Slawomir Stepien <sst@poczta.fm> Reviewed-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../bindings/iio/potentiometer/mcp4131.txt | 84 ++++ drivers/iio/potentiometer/Kconfig | 18 + drivers/iio/potentiometer/Makefile | 1 + drivers/iio/potentiometer/mcp4131.c | 494 +++++++++++++++++++++ 4 files changed, 597 insertions(+) commit 6154a108faafe5f7fe08cee933b899b013b457d9 Author: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Date: Wed Mar 23 12:06:34 2016 +0100 Staging: iio: ad7606: Fix sparse endian warning Fix following sparse warning: warning: cast to restricted __be16 Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/adc/ad7606_spi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 8cb359e3a1f6318f971bec281623613f48b711be Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Wed Mar 23 12:34:41 2016 +0000 iio: buffer: add missing descriptions in iio_buffer_access_funcs The members buffer_group and attrs of iio_buffer_access_funcs have no descriptions for the documentation. Adding them. Fixes: 08e7e0adaa17 ("iio: buffer: Allocate standard attributes in the core") Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> include/linux/iio/buffer.h | 2 ++ 1 file changed, 2 insertions(+) commit 793d6b5ea80c9bba8de40b720991b436fa5e174d Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 09:39:14 2016 +0100 iio: tools: make generic_buffer look for "-trigger" All the ST Sensors use the old "<foo>-trigger" rather than the standard "<foo>-devN" new standard suffix for triggers. Now much to do about it since it is ABI, but make the testing tools recognize it too. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> tools/iio/generic_buffer.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) commit fb12b6c725a3936bedaa7fac87432f0ad0d01599 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:05:09 2016 +0200 iio: remove gpio interrupt probing from drivers that use a single interrupt Commit 845c877009cf014b ("i2c / ACPI: Assign IRQ for devices that have GpioInt automatically") automatically assigns the first ACPI GPIO interrupt in client->irq, so we can remove the probing code from drivers that use only one interrupt. Commit 0f0796509c07c1c7 ("iio: remove gpio interrupt probing from drivers that use a single interrupt") removes gpio interrupt probing from most drivers. This patch cleans the remaining ones. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mxc4005.c | 29 ----------------------------- drivers/iio/gyro/bmg160_core.c | 28 ---------------------------- 2 files changed, 57 deletions(-) commit b1532909decca12e0527473870cec1d57677f916 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:08:38 2016 +0200 iio: remove unused gpio consumer.h include GPIO handling code has been removed from the drivers (since this is now handled by the ACPI core) in commit 0f0796509c07 ("iio: remove gpio interrupt probing from drivers that use a single interrupt"). Remove the include for linux/gpio/consumer.h since it is no longer used. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/bmc150-accel-core.c | 1 - drivers/iio/accel/kxcjk-1013.c | 1 - drivers/iio/accel/mma9553.c | 1 - drivers/iio/accel/stk8312.c | 1 - drivers/iio/accel/stk8ba50.c | 1 - drivers/iio/imu/kmx61.c | 1 - drivers/iio/light/stk3310.c | 1 - drivers/iio/magnetometer/bmc150_magn.c | 1 - 8 files changed, 8 deletions(-) commit 65ae47b0ec535a008e53578abc11082f3b742f75 Author: Adriana Reus <adriana.reus@intel.com> Date: Thu Mar 24 11:29:31 2016 +0200 iio: accel: kxcjk-1013: optimize i2c transfers in trigger handler Some i2c busses (e.g.: Synopsys DesignWare I2C adapter) need to enable/disable the bus at each i2c transfer and must wait for the enable/disable to happen before sending the data. When reading data in the trigger handler, the kxcjk-1013 accel driver does one i2c transfer for each axis. This has an impact on the frequency of the accelerometer at high sample rates due to additional delays introduced by the i2c bus at each transfer. Reading all axis values in one i2c transfer reduces the delays introduced by the i2c bus. Uses i2c_smbus_read_i2c_block_data_or_emulated that will fallback to reading each axis as a separate word in case i2c block read is not supported. Signed-off-by: Adriana Reus <adriana.reus@intel.com> Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Acked-by: Jonathan Cameron <jic23@kernel.org> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/kxcjk-1013.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit 09cf1b321ad353eeaeddcfd33771b34ce2a61640 Author: Adriana Reus <adriana.reus@intel.com> Date: Thu Mar 24 11:29:30 2016 +0200 iio: accel: kxcjk-1013: use available_scan_masks Use available_scan_masks to allow the iio core to select the data to send to userspace depending on which axes are enabled, instead of doing this in the driver's interrupt handler. Signed-off-by: Adriana Reus <adriana.reus@intel.com> Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/kxcjk-1013.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 7e3d1eb123d804d2b1088782f458aed5eb36c684 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:29:29 2016 +0200 iio: accel: bmg160: optimize transfers in trigger handler Some i2c busses (e.g.: Synopsys DesignWare I2C adapter) need to enable/disable the bus at each i2c transfer and must wait for the enable/disable to happen before sending the data. When reading data in the trigger handler, the bmg160 gyro driver does one bus transfer for each axis. This has an impact on the frequency of the accelerometer at high sample rates due to additional delays introduced by the bus at each transfer. Reading all axis values in one bus transfer reduces the delays introduced by the bus. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/gyro/bmg160_core.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit ee8c5419e06e3a002995f5d1f57c9b5aead331e6 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:29:28 2016 +0200 iio: gyro: bmg160: use available_scan_masks Use available_scan_masks to allow the iio core to select the data to send to userspace depending on which axes are enabled, instead of doing this in the driver's interrupt handler. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/gyro/bmg160_core.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 1715e0ccd3b8cd4c1ee76076e1e7452b113be193 Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:29:27 2016 +0200 iio: accel: bmc150: optimize transfers in trigger handler Some i2c busses (e.g.: Synopsys DesignWare I2C adapter) need to enable/disable the bus at each i2c transfer and must wait for the enable/disable to happen before sending the data. When reading data in the trigger handler, the bmc150 accel driver does one bus transfer for each axis. This has an impact on the frequency of the accelerometer at high sample rates due to additional delays introduced by the bus at each transfer. Reading all axis values in one bus transfer reduces the delays introduced by the bus. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/bmc150-accel-core.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) commit 23e758b36898d5ff6cc0cd2e54c498b24a15b0dd Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 24 11:29:26 2016 +0200 iio: accel: bmc150: use available_scan_masks Use available_scan_masks to allow the iio core to select the data to send to userspace depending on which axes are enabled, instead of doing this in the driver's interrupt handler. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/bmc150-accel-core.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 91307cbeca7fd372342aaea7e814a19156ee8e64 Author: Slawomir Stepien <sst@poczta.fm> Date: Thu Mar 24 17:06:01 2016 +0100 iio: potentiometer: mcp4531: use pointer to access model parameters Use const pointer to element from model configuration array rather then array index, as it will not change anyway. Signed-off-by: Slawomir Stepien <sst@poczta.fm> Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/potentiometer/mcp4531.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit 833716e0ed026c1abc7dd0e85a6932b855a8e56b Merge: 5ada37b 91979b9 Author: David S. Miller <davem@davemloft.net> Date: Sat Apr 2 20:23:10 2016 -0400 Merge branch 'stmmac-GMAC4.x' Alexandre TORGUE says: ==================== Enhance stmmac driver to support GMAC4.x IP This is a subset of patch to enhance current stmmac driver to support new GMAC4.x chips. New set of callbacks is defined to support this new family: descriptors, dma, core. One of main changes of GMAC 4.xx IP is descriptors management. -descriptors are only used in ring mode. -A descriptor is composed of 4 32bits registers (no more extended descriptors) -descriptor mechanism (Tx for example, but it is exactly the same for RX): -useful registers: -DMA_CH#_TxDesc_Ring_Len: length of transmit descriptor ring -DMA_CH#_TxDesc_List_Address: start address of the ring -DMA_CH#_TxDesc_Tail_Pointer: address of the last descriptor to send + 1. -DMA_CH#_TxDesc_Current_App_TxDesc: address of the current descriptor -The descriptor Tail Pointer register contains the pointer to the descriptor address (N). The base address and the current descriptor decide the address of the current descriptor that the DMA can process. The descriptors up to one location less than the one indicated by the descriptor tail pointer (N-1) are owned by the DMA. The DMA continues to process the descriptors until the following condition occurs: "current descriptor pointer == Descriptor Tail pointer" Then the DMA goes into suspend mode. The application must perform a write to descriptor tail pointer register and update the tail pointer to have the following condition and to start a new transfer: "current descriptor pointer < Descriptor tail pointer" The DMA automatically wraps around the base address when the end of ring is reached. New features are available on IP: -TSO (TCP Segmentation Offload) for TX only -Split header: to have header and payload in 2 different buffers (not yet implemented) Below some throughput figures obtained on some boxes: iperf (mbps) -------------------------------------- tcp udp tx rx tx rx ----------------- GMAC4.x 935 930 750 800 Note: There is a change in 4.10a databook on bitfield mapping of DMA_CHANx_INTR_ENA register. This requires to have é diffrent set of callbacks between IP 4.00a and 4.10a. ==================== Signed-off-by: David S. Miller <davem@davemloft.net> commit 91979b9db86340d7cd49392a498663fb1ac74639 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:37 2016 +0200 stmmac: update MAINTAINERS Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 06bce7dd1507c9b943fb20c845e02c6f4c172a55 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:36 2016 +0200 stmmac: update version to Jan_2016 This patch just updates the driver to the version fully tested on STi platforms. This version is Jan_2016. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/stmmac.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0b7a43d37633614113ac54af73c193862dff4e50 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:35 2016 +0200 Documentation: networking: update stmmac Update stmmac driver documentation according to new GMAC 4.x family. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/networking/stmmac.txt | 44 ++++++++++++++++++++++++++++++++----- 1 file changed, 38 insertions(+), 6 deletions(-) commit f748be531d7012c456b97f66091d86b3675c5fef Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:34 2016 +0200 stmmac: support new GMAC4 This patch adds the whole GMAC4 support inside the stmmac d.d. now able to use the new HW and some new features i.e.: TSO. It is missing the multi-queue and split Header support at this stage. This patch also updates the driver version and the stmmac.txt. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/common.h | 4 + drivers/net/ethernet/stmicro/stmmac/stmmac.h | 6 +- .../net/ethernet/stmicro/stmmac/stmmac_ethtool.c | 5 +- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 483 ++++++++++++++++++--- 4 files changed, 444 insertions(+), 54 deletions(-) commit ee2ae1ed46251dcbdcc2c59b5e30f664ddfbacb1 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:33 2016 +0200 stmmac: add new DT platform entries for GMAC4 This is to support the snps,dwmac-4.00 and snps,dwmac-4.10a and related features on the platform driver. See binding doc for further details. Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> Documentation/devicetree/bindings/net/stmmac.txt | 2 ++ drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 7 +++++++ include/linux/stmmac.h | 2 ++ 3 files changed, 11 insertions(+) commit 36ff7c1e94a5d43a0ea2d386b211087f77669017 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:32 2016 +0200 stmmac: enhance mmc counter management For gmac3, the MMC addr map is: 0x100 - 0x2fc For gmac4, the MMC addr map is: 0x700 - 0x8fc So instead of adding 0x600 to the IO address when setup the mmc, the RMON base address is saved inside the private structure and then used to manage the counters. Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/mmc.h | 4 + drivers/net/ethernet/stmicro/stmmac/mmc_core.c | 349 +++++++++++---------- drivers/net/ethernet/stmicro/stmmac/stmmac.h | 1 + .../net/ethernet/stmicro/stmmac/stmmac_ethtool.c | 2 +- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 8 +- 5 files changed, 188 insertions(+), 176 deletions(-) commit 477286b53f5576ddec0a4df0f3d0c4bd7a0ed165 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:31 2016 +0200 stmmac: add GMAC4 core support This is the initial support for GMAC4 that includes the main callbacks to setup the core module: including Csum, basic filtering, mac address and interrupt (MMC, MTL, PMT) No LPI added. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/Makefile | 2 +- drivers/net/ethernet/stmicro/stmmac/common.h | 10 +- drivers/net/ethernet/stmicro/stmmac/dwmac4.h | 31 ++ drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 407 ++++++++++++++++++++++ 4 files changed, 447 insertions(+), 3 deletions(-) commit 48863ce5940fa5420096c8beba44e5e1bc0c8ca1 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:30 2016 +0200 stmmac: add DMA support for GMAC 4.xx DMA behavior is linked to descriptor management: -descriptor mechanism (Tx for example, but it is exactly the same for RX): -useful registers: -DMA_CH#_TxDesc_Ring_Len: length of transmit descriptor ring -DMA_CH#_TxDesc_List_Address: start address of the ring -DMA_CH#_TxDesc_Tail_Pointer: address of the last descriptor to send + 1. -DMA_CH#_TxDesc_Current_App_TxDesc: address of the current descriptor -The descriptor Tail Pointer register contains the pointer to the descriptor address (N). The base address and the current descriptor decide the address of the current descriptor that the DMA can process. The descriptors up to one location less than the one indicated by the descriptor tail pointer (N-1) are owned by the DMA. The DMA continues to process the descriptors until the following condition occurs: "current descriptor pointer == Descriptor Tail pointer" Then the DMA goes into suspend mode. The application must perform a write to descriptor tail pointer register and update the tail pointer to have the following condition and to start a new transfer: "current descriptor pointer < Descriptor tail pointer" The DMA automatically wraps around the base address when the end of ring is reached. Up to 8 DMA could be use but currently we only use one (channel0) Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/Makefile | 2 +- drivers/net/ethernet/stmicro/stmmac/common.h | 11 + drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c | 354 +++++++++++++++++++++++ drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.h | 202 +++++++++++++ drivers/net/ethernet/stmicro/stmmac/dwmac4_lib.c | 225 ++++++++++++++ 5 files changed, 793 insertions(+), 1 deletion(-) commit 35f74c0c5dce138bd9000d98abf4959af782a96d Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:29 2016 +0200 stmmac: add GMAC4 DMA/CORE Header File This is the main header file to define all the macro used for GMAC4 DMA and CORE parts. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/dwmac4.h | 224 +++++++++++++++++++++++++++ 1 file changed, 224 insertions(+) commit 753a71090f3325b4c34622daccbb71ed574cca73 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:28 2016 +0200 stmmac: add descriptors function for GMAC 4.xx One of main changes of GMAC 4.xx IP is descriptors management. -descriptors are only used in ring mode. -A descriptor is composed of 4 32bits registers (no more extended descriptors) -descriptor mechanism (Tx for example, but it is exactly the same for RX): -useful registers: -DMA_CH#_TxDesc_Ring_Len: length of transmit descriptor ring -DMA_CH#_TxDesc_List_Address: start address of the ring -DMA_CH#_TxDesc_Tail_Pointer: address of the last descriptor to send + 1. -DMA_CH#_TxDesc_Current_App_TxDesc: address of the current descriptor -The descriptor Tail Pointer register contains the pointer to the descriptor address (N). The base address and the current descriptor decide the address of the current descriptor that the DMA can process. The descriptors up to one location less than the one indicated by the descriptor tail pointer (N-1) are owned by the DMA. The DMA continues to process the descriptors until the following condition occurs: "current descriptor pointer == Descriptor Tail pointer" Then the DMA goes into suspend mode. The application must perform a write to descriptor tail pointer register and update the tail pointer to have the following condition and to start a new transfer: "current descriptor pointer < Descriptor tail pointer" The DMA automatically wraps around the base address when the end of ring is reached. -New features are available on IP: -TSO (TCP Segmentation Offload) for TX only -Split header: to have header and payload in 2 different buffers Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/Makefile | 3 +- drivers/net/ethernet/stmicro/stmmac/common.h | 7 + drivers/net/ethernet/stmicro/stmmac/dwmac4_descs.c | 396 +++++++++++++++++++++ drivers/net/ethernet/stmicro/stmmac/dwmac4_descs.h | 129 +++++++ 4 files changed, 534 insertions(+), 1 deletion(-) commit c623d149b18cbdb7e9f782ced0c859b1836ef3cd Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:27 2016 +0200 stmmac: rework synopsys id read, moved to dwmac setup synopsys_uid is only used once after setup, to get synopsys_id by using shitf/mask operation. It's no longer used then. So, remove this temporary variable and directly compute synopsys_id from setup routine. Acked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com> Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/common.h | 27 ++++++++++++++++--- .../net/ethernet/stmicro/stmmac/dwmac1000_core.c | 7 +++-- .../net/ethernet/stmicro/stmmac/dwmac100_core.c | 5 ++-- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 31 +++------------------- 4 files changed, 35 insertions(+), 35 deletions(-) commit d0225e7de6229068df99ba8dacebc826d27e1cd5 Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:26 2016 +0200 stmmac: rework the routines to show the ring status To avoid lot of check in stmmac_main for display ring management and support the GMAC4 chip, the display_ring function is moved into dedicated descriptor file. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/common.h | 2 + drivers/net/ethernet/stmicro/stmmac/enh_desc.c | 21 +++++++ drivers/net/ethernet/stmicro/stmmac/norm_desc.c | 21 +++++++ drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 73 +++++++---------------- 4 files changed, 67 insertions(+), 50 deletions(-) commit f10a6a3541b4f79f6a4d9f0d4f8f16b92f8f1cfc Author: Alexandre TORGUE <alexandre.torgue@st.com> Date: Fri Apr 1 11:37:25 2016 +0200 stmmac: rework get_hw_feature function On next GMAC IP generation (4.xx), the way to get hw feature is not the same than on previous 3.xx. As it is hardware dependent, the way to get hw capabilities should be defined in dma ops of each MAC IP. It will avoid also a huge computation of hw capabilities in stmmac_main. Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/stmicro/stmmac/common.h | 3 +- .../net/ethernet/stmicro/stmmac/dwmac1000_dma.c | 35 ++++++++++++++- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 50 +++------------------- 3 files changed, 42 insertions(+), 46 deletions(-) commit 5ada37b53ea2b310df143b2c7d6c48fbf14d5cb8 Author: Lisheng <lisheng011@huawei.com> Date: Thu Mar 31 21:00:09 2016 +0800 net: hns: add support of pause frame ctrl for HNS V2 The patch adds support of pause ctrl for HNS V2, and this feature is lost by HNS V1: 1) service ports can disable rx pause frame, 2) debug ports can open tx/rx pause frame. And this patch updates the REGs about the pause ctrl when updated status function called by upper layer routine. Signed-off-by: Lisheng <lisheng011@huawei.com> Signed-off-by: Yisen Zhuang <Yisen.Zhuang@huawei.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net> drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 20 +++++- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 30 ++------- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 75 +++++++++++++++++++--- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h | 5 ++ drivers/net/ethernet/hisilicon/hns/hns_dsaf_ppe.c | 6 +- drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h | 6 ++ 6 files changed, 104 insertions(+), 38 deletions(-) commit 7822ce73e659ab0c5dd8289f077efbcc4cd03164 Author: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Date: Thu Mar 31 18:21:38 2016 +0800 netlink: use nla_get_in_addr and nla_put_in_addr for ipv4 address Since nla_get_in_addr and nla_put_in_addr were implemented, so use them appropriately. Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com> Signed-off-by: David S. Miller <davem@davemloft.net> net/ipv4/ip_tunnel_core.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 2349262397b89a421adfd142aad2a7dd33710f26 Author: Yuchung Cheng <ycheng@google.com> Date: Wed Mar 30 14:54:20 2016 -0700 tcp: remove cwnd moderation after recovery For non-SACK connections, cwnd is lowered to inflight plus 3 packets when the recovery ends. This is an optional feature in the NewReno RFC 2582 to reduce the potential burst when cwnd is "re-opened" after recovery and inflight is low. This feature is questionably effective because of PRR: when the recovery ends (i.e., snd_una == high_seq) NewReno holds the CA_Recovery state for another round trip to prevent false fast retransmits. But if the inflight is low, PRR will overwrite the moderated cwnd in tcp_cwnd_reduction() later regardlessly. So if a receiver responds bogus ACKs (i.e., acking future data) to speed up transfer after recovery, it can only induce a burst up to a window worth of data packets by acking up to SND.NXT. A restart from (short) idle or receiving streched ACKs can both cause such bursts as well. On the other hand, if the recovery ends because the sender detects the losses were spurious (e.g., reordering). This feature unconditionally lowers a reverted cwnd even though nothing was lost. By principle loss recovery module should not update cwnd. Further pacing is much more effective to reduce burst. Hence this patch removes the cwnd moderation feature. v2 changes: revised commit message on bogus ACKs and burst, and missing signature Signed-off-by: Matt Mathis <mattmathis@google.com> Signed-off-by: Neal Cardwell <ncardwell@google.com> Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: Yuchung Cheng <ycheng@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> include/net/tcp.h | 11 ----------- net/ipv4/tcp_input.c | 11 ----------- 2 files changed, 22 deletions(-) commit abd56b3c8483ca73413ade0e7c7a0d13b9870016 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Thu Mar 31 13:48:04 2016 -0500 Documentation: dt: socfpga: Add Altera Arria10 OCRAM binding Add the device tree bindings needed to support the Altera On-Chip RAM ECC on the Arria10 chip. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Acked-by: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459450087-24792-5-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> .../devicetree/bindings/arm/altera/socfpga-eccmgr.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) commit aa1f06dcc0e58e1a1b5118fc265418a2970e11aa Author: Thor Thayer <tthayer@opensource.altera.com> Date: Thu Mar 31 13:48:03 2016 -0500 EDAC, altera: Make OCRAM ECC dependency check generic In preparation for the Arria10 peripheral ECCs, move the OCRAM ECC dependency check into the general ECC area since this same function can be used by other memories. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459450087-24792-4-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 43 +++++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 22 deletions(-) commit 943ad9179836b12433beadfde2d03b215c4367d6 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Thu Mar 31 13:48:02 2016 -0500 EDAC, altera: Add register offset for ECC Enable In preparation for the Arria10 peripheral ECCs, add a register offset from the ECC base to index to the ECC enable register. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459450087-24792-3-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 3 ++- drivers/edac/altera_edac.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) commit e17ced2cb61ac63efb5ab54fee8e45aaa437c874 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Thu Mar 31 13:48:01 2016 -0500 EDAC, altera: Extract error inject operations to a struct fops In preparation for the Arria10 peripheral ECCs, extract the inject file operations because the Arria10 IRQ trigger mechanism is different than Cyclone5/Arria5 and Arria10 L2 cache. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1459450087-24792-2-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 5 ++++- drivers/edac/altera_edac.h | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) commit c0553d04f8d35bf9706e20ba392ffa61ab2b6f5c Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Sun Mar 27 11:26:14 2016 +0200 dt-bindings: arm: add DT binding for Marvell AP806 system controller This commit adds the Device Tree binding documentation for the system controller found in Marvell AP806 HW block, which is one of the core HW blocks of the 64-bits Marvell Armada 7K/8K family. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> .../arm/marvell/ap806-system-controller.txt | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit a454018505f2e875441603b18dbbb912d422f7d1 Author: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Sun Mar 27 11:26:13 2016 +0200 clk: unconditionally recurse into clk/mvebu/ The drivers/clk/mvebu directory is only being built when CONFIG_PLAT_ORION=y. As we are going to support additional mvebu platforms in drivers/clk/mvebu, which don't have CONFIG_PLAT_ORION=y, we need to recurse into this directory regardless of the value of CONFIG_PLAT_ORION. Since all files in drivers/clk/mvebu/ are already conditionally compiled depending on various Kconfig options, we can recurse unconditionally into drivers/clk/mvebu without any other change. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> drivers/clk/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9bdcb44e391da5c41b98573bf0305a0e0b1c9569 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat Apr 2 01:09:12 2016 +0200 cpufreq: schedutil: New governor based on scheduler utilization data Add a new cpufreq scaling governor, called "schedutil", that uses scheduler-provided CPU utilization information as input for making its decisions. Doing that is possible after commit 34e2c555f3e1 (cpufreq: Add mechanism for registering utilization update callbacks) that introduced cpufreq_update_util() called by the scheduler on utilization changes (from CFS) and RT/DL task status updates. In particular, CPU frequency scaling decisions may be based on the the utilization data passed to cpufreq_update_util() by CFS. The new governor is relatively simple. The frequency selection formula used by it depends on whether or not the utilization is frequency-invariant. In the frequency-invariant case the new CPU frequency is given by next_freq = 1.25 * max_freq * util / max where util and max are the last two arguments of cpufreq_update_util(). In turn, if util is not frequency-invariant, the maximum frequency in the above formula is replaced with the current frequency of the CPU: next_freq = 1.25 * curr_freq * util / max The coefficient 1.25 corresponds to the frequency tipping point at (util / max) = 0.8. All of the computations are carried out in the utilization update handlers provided by the new governor. One of those handlers is used for cpufreq policies shared between multiple CPUs and the other one is for policies with one CPU only (and therefore it doesn't need to use any extra synchronization means). The governor supports fast frequency switching if that is supported by the cpufreq driver in use and possible for the given policy. In the fast switching case, all operations of the governor take place in its utilization update handlers. If fast switching cannot be used, the frequency switch operations are carried out with the help of a work item which only calls __cpufreq_driver_target() (under a mutex) to trigger a frequency update (to a value already computed beforehand in one of the utilization update handlers). Currently, the governor treats all of the RT and DL tasks as "unknown utilization" and sets the frequency to the allowed maximum when updated from the RT or DL sched classes. That heavy-handed approach should be replaced with something more subtle and specifically targeted at RT and DL tasks. The governor shares some tunables management code with the "ondemand" and "conservative" governors and uses some common definitions from cpufreq_governor.h, but apart from that it is stand-alone. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> drivers/cpufreq/Kconfig | 30 +++ kernel/sched/Makefile | 1 + kernel/sched/cpufreq_schedutil.c | 528 +++++++++++++++++++++++++++++++++++++++ kernel/sched/sched.h | 8 + kernel/trace/power-traces.c | 1 + 5 files changed, 568 insertions(+) commit b7898fda5bc7e786e76ce24fbd2ec993b08ec518 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Wed Mar 30 03:47:49 2016 +0200 cpufreq: Support for fast frequency switching Modify the ACPI cpufreq driver to provide a method for switching CPU frequencies from interrupt context and update the cpufreq core to support that method if available. Introduce a new cpufreq driver callback, ->fast_switch, to be invoked for frequency switching from interrupt context by (future) governors supporting that feature via (new) helper function cpufreq_driver_fast_switch(). Add two new policy flags, fast_switch_possible, to be set by the cpufreq driver if fast frequency switching can be used for the given policy and fast_switch_enabled, to be set by the governor if it is going to use fast frequency switching for the given policy. Also add a helper for setting the latter. Since fast frequency switching is inherently incompatible with cpufreq transition notifiers, make it possible to set the fast_switch_enabled only if there are no transition notifiers already registered and make the registration of new transition notifiers fail if fast_switch_enabled is set for at least one policy. Implement the ->fast_switch callback in the ACPI cpufreq driver and make it set fast_switch_possible during policy initialization as appropriate. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/acpi-cpufreq.c | 42 +++++++++++++ drivers/cpufreq/cpufreq.c | 130 +++++++++++++++++++++++++++++++++++++++-- include/linux/cpufreq.h | 16 +++++ 3 files changed, 183 insertions(+), 5 deletions(-) commit 379480d8258056bfdbaa65e4d3f024bb5b34b52b Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Mar 22 02:51:56 2016 +0100 cpufreq: Move governor symbols to cpufreq.h Move definitions of symbols related to transition latency and sampling rate to include/linux/cpufreq.h so they can be used by (future) goverernors located outside of drivers/cpufreq/. No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq_governor.h | 14 -------------- include/linux/cpufreq.h | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 14 deletions(-) commit 66893b6ac9952ec9d9409e9d85eaacf37bba8d15 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Mar 22 02:50:45 2016 +0100 cpufreq: Move governor attribute set headers to cpufreq.h Move definitions and function headers related to struct gov_attr_set to include/linux/cpufreq.h so they can be used by (future) goverernors located outside of drivers/cpufreq/. No functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq_governor.h | 21 --------------------- include/linux/cpufreq.h | 23 +++++++++++++++++++++++ 2 files changed, 23 insertions(+), 21 deletions(-) commit 2d0c58ad60376160ee8b535e570a38b9a349b6a4 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Mar 22 02:49:15 2016 +0100 cpufreq: governor: Move abstract gov_attr_set code to seperate file Move abstract code related to struct gov_attr_set to a separate (new) file so it can be shared with (future) goverernors that won't share more code with "ondemand" and "conservative". No intentional functional changes. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/Kconfig | 4 ++ drivers/cpufreq/Makefile | 1 + drivers/cpufreq/cpufreq_governor.c | 82 ---------------------------- drivers/cpufreq/cpufreq_governor.h | 6 +++ drivers/cpufreq/cpufreq_governor_attr_set.c | 84 +++++++++++++++++++++++++++++ 5 files changed, 95 insertions(+), 82 deletions(-) commit 0dd3c1d678aa219a7332984fcedbdd8970e92d5b Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Tue Mar 22 02:47:51 2016 +0100 cpufreq: governor: New data type for management part of dbs_data In addition to fields representing governor tunables, struct dbs_data contains some fields needed for the management of objects of that type. As it turns out, that part of struct dbs_data may be shared with (future) governors that won't use the common code used by "ondemand" and "conservative", so move it to a separate struct type and modify the code using struct dbs_data to follow. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> drivers/cpufreq/cpufreq_conservative.c | 25 ++++++---- drivers/cpufreq/cpufreq_governor.c | 90 +++++++++++++++++++++------------- drivers/cpufreq/cpufreq_governor.h | 35 +++++++------ drivers/cpufreq/cpufreq_ondemand.c | 29 ++++++----- 4 files changed, 107 insertions(+), 72 deletions(-) commit 0bed612be638e41456cd8cb270a2b411a5b43d63 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat Apr 2 01:08:43 2016 +0200 cpufreq: sched: Helpers to add and remove update_util hooks Replace the single helper for adding and removing cpufreq utilization update hooks, cpufreq_set_update_util_data(), with a pair of helpers, cpufreq_add_update_util_hook() and cpufreq_remove_update_util_hook(), and modify the users of cpufreq_set_update_util_data() accordingly. With the new helpers, the code using them doesn't need to worry about the internals of struct update_util_data and in particular it doesn't need to worry about populating the func field in it properly upfront. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> drivers/cpufreq/cpufreq_governor.c | 76 +++++++++++++++++++------------------- drivers/cpufreq/intel_pstate.c | 7 ++-- include/linux/sched.h | 5 ++- kernel/sched/cpufreq.c | 48 ++++++++++++++++++------ 4 files changed, 82 insertions(+), 54 deletions(-) commit 9fa64d6424adabf0e3a546ae24d01a62a927b342 Merge: f55532a febce40 Author: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Date: Sat Apr 2 01:07:17 2016 +0200 Merge back intel_pstate fixes for v4.6. * pm-cpufreq: intel_pstate: Avoid extra invocation of intel_pstate_sample() intel_pstate: Do not set utilization update hook too early commit d37ba880598654fda10b312331377cdca3edd574 Author: Wang Nan <wangnan0@huawei.com> Date: Fri Apr 1 13:26:42 2016 +0000 perf bpf: Add sample types for 'bpf-output' event Before this patch we can see very large time in the events before the 'bpf-output' event. For example: # perf trace -vv -T --ev sched:sched_switch \ --ev bpf-output/no-inherit,name=evt/ \ --ev ./test_bpf_trace.c/map:channel.event=evt/ \ usleep 10 ... 18446744073709.551 (18446564645918.480 ms): usleep/4157 nanosleep(rqtp: 0x7ffd3f0dc4e0) ... 18446744073709.551 ( ): evt:Raise a BPF event!..) 179427791.076 ( ): perf_bpf_probe:func_begin:(ffffffff810eb9a0)) 179427791.081 ( ): sched:sched_switch:usleep:4157 [120] S ==> swapper/2:0 [120]) ... We can also see the differences between bpf-output events and breakpoint events: For bpf output event: sample_type IP|TID|RAW|IDENTIFIER For tracepoint events: sample_type IP|TID|TIME|CPU|PERIOD|RAW|IDENTIFIER This patch fix this differences by adding more sample type for bpf-output events. After this patch: # perf trace -vv -T --ev sched:sched_switch \ --ev bpf-output/no-inherit,name=evt/ \ --ev ./test_bpf_trace.c/map:channel.event=evt/ \ usleep 10 ... 179877370.878 ( 0.003 ms): usleep/5336 nanosleep(rqtp: 0x7ffff866c450) ... 179877370.878 ( ): evt:Raise a BPF event!..) 179877370.878 ( ): perf_bpf_probe:func_begin:(ffffffff810eb9a0)) 179877370.882 ( ): sched:sched_switch:usleep:5336 [120] S ==> swapper/4:0 [120]) 179877370.945 ( ): evt:Raise a BPF event!..) ... # ./perf trace -vv -T --ev sched:sched_switch \ --ev bpf-output/no-inherit,name=evt/ \ --ev ./test_bpf_trace.c/map:channel.event=evt/ \ usleep 10 2>&1 | grep sample_type sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW sample_type IP|TID|TIME|ID|CPU|PERIOD|RAW The 'IDENTIFIER' info is not required because all events have the same sample_type. Committer notes: Further testing, on top of the changes making 'perf trace' avoid samples from events without PERF_SAMPLE_TIME: Before: # trace --ev bpf-output/no-inherit,name=evt/ --ev /home/acme/bpf/test_bpf_trace.c/map:channel.event=evt/ usleep 10 <SNIP> 0.560 ( 0.001 ms): brk( ) = 0x55e5a1df8000 18446640227439.430 (18446640227438.859 ms): nanosleep(rqtp: 0x7ffc96643370) ... 18446640227439.430 ( ): evt:Raise a BPF event!..) 0.576 ( ): perf_bpf_probe:func_begin:(ffffffff81112460)) 18446640227439.430 ( ): evt:Raise a BPF event!..) 0.645 ( ): perf_bpf_probe:func_end:(ffffffff81112460 <- ffffffff81003d92)) 0.646 ( 0.076 ms): ... [continued]: nanosleep()) = 0 # After: # trace --ev bpf-output/no-inherit,name=evt/ --ev /home/acme/bpf/test_bpf_trace.c/map:channel.event=evt/ usleep 10 <SNIP> 0.292 ( 0.001 ms): brk( ) = 0x55c7cd6e1000 0.302 ( 0.004 ms): nanosleep(rqtp: 0x7ffedd8bc0f0) ... 0.302 ( ): evt:Raise a BPF event!..) 0.303 ( ): perf_bpf_probe:func_begin:(ffffffff81112460)) 0.397 ( ): evt:Raise a BPF event!..) 0.397 ( ): perf_bpf_probe:func_end:(ffffffff81112460 <- ffffffff81003d92)) 0.398 ( 0.100 ms): ... [continued]: nanosleep()) = 0 Signed-off-by: Wang Nan <wangnan0@huawei.com> Reported-and-Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: pi3orama@163.com Link: http://lkml.kernel.org/r/1459517202-42320-1-git-send-email-wangnan0@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/evsel.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 8a07a8094b6b6c3e195885ec31f4bd0be54aafaf Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Mar 31 15:19:39 2016 -0300 perf trace: Don't set the base timestamp using events without PERF_SAMPLE_TIME This was causing bogus values to be shown at the timestamp column: Before: # trace --ev bpf-output/no-inherit,name=evt/ --ev /home/acme/bpf/test_bpf_trace.c/map:channel.event=evt/ usleep 10 94631143.385 ( 0.001 ms): brk( ) = 0x555555757000 94631143.398 ( 0.003 ms): mmap(len: 4096, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1) = 0x7ffff7ff6000 94631143.406 ( 0.004 ms): access(filename: 0xf7df9e10, mode: R ) = -1 ENOENT No such file or directory 94631143.412 ( 0.004 ms): open(filename: 0xf7df8761, flags: CLOEXEC) = 3 94631143.415 ( 0.002 ms): fstat(fd: 3, statbuf: 0x7fffffffd6b0 ) = 0 94631143.419 ( 0.003 ms): mmap(len: 106798, prot: READ, flags: PRIVATE, fd: 3) = 0x7ffff7fdb000 94631143.420 ( 0.001 ms): close(fd: 3 ) = 0 94631143.432 ( 0.004 ms): open(filename: 0xf7ff6640, flags: CLOEXEC) = 3 <SNIP> After: # trace --ev bpf-output/no-inherit,name=evt/ --ev /home/acme/bpf/test_bpf_trace.c/map:channel.event=evt/ usleep 10 0.022 ( 0.001 ms): brk( ) = 0x55d7668a6000 0.037 ( 0.003 ms): mmap(len: 4096, prot: READ|WRITE, flags: PRIVATE|ANONYMOUS, fd: -1) = 0x7f8fbeb97000 0.123 ( 0.083 ms): access(filename: 0xbe995e10, mode: R ) = -1 ENOENT No such file or directory 0.130 ( 0.004 ms): open(filename: 0xbe994761, flags: CLOEXEC) = 3 0.133 ( 0.002 ms): fstat(fd: 3, statbuf: 0x7fff6487a890 ) = 0 0.138 ( 0.003 ms): mmap(len: 106798, prot: READ, flags: PRIVATE, fd: 3) = 0x7f8fbeb7c000 0.140 ( 0.001 ms): close(fd: 3 ) = 0 0.151 ( 0.004 ms): open(filename: 0xbeb97640, flags: CLOEXEC) = 3 <SNIP> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-p7m8llv81iv55ekxexdp5n57@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit e6001980c61b45ef090e2b4c9c1953ef897cdeb0 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu Mar 31 15:16:28 2016 -0300 perf trace: Introduce function to set the base timestamp That is used in both live runs, i.e.: # trace ls As when processing events recorded in a perf.data file: # trace -i perf.data Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-901l6yebnzeqg7z8mbaf49xb@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) commit ac0e2cd555373ae6f8f3a3ad3fbbf5b6d1e7aaaa Author: Kan Liang <kan.liang@intel.com> Date: Wed Mar 30 12:16:15 2016 -0700 perf tools: Fix PMU term format max value calculation Currently the max value of format is calculated by the bits number. It relies on the continuity of the format. However, uncore event format is not continuous. E.g. uncore qpi event format can be 0-7,21. If bit 21 is set, there is parsing issues as below. $ perf stat -a -e uncore_qpi_0/event=0x200002,umask=0x8/ event syntax error: '..pi_0/event=0x200002,umask=0x8/' \___ value too big for format, maximum is 511 This patch return the real max value by setting all possible bits to 1. Signed-off-by: Kan Liang <kan.liang@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Link: http://lkml.kernel.org/r/1459365375-14285-1-git-send-email-kan.liang@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/pmu.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit bd0c7a54219cc3745ce7f36970d8e5ffb3f8d80e Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Mar 8 10:38:53 2016 +0200 perf intel-pt/bts: Define JITDUMP_USE_ARCH_TIMESTAMP For Intel PT / BTS, define the environment variable that selects TSC timestamps in the jitdump file. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1457426333-30260-1-git-send-email-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/util/intel-bts.c | 5 +++++ tools/perf/arch/x86/util/intel-pt.c | 5 +++++ 2 files changed, 10 insertions(+) commit 2a28e23049af99e1c810111ef5e56455cafeda45 Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Mar 8 10:38:50 2016 +0200 perf jit: Add support for using TSC as a timestamp Intel PT uses TSC as a timestamp, so add support for using TSC instead of the monotonic clock. Use of TSC is selected by an environment variable "JITDUMP_USE_ARCH_TIMESTAMP" and flagged in the jitdump file with flag JITDUMP_FLAGS_ARCH_TIMESTAMP. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1457426330-30226-1-git-send-email-adrian.hunter@intel.com [ Added the fixup from He Kuang to make it build on other arches, ] [ such as aarch64, to avoid inserting this bisectiong breakage upstream ] Link: http://lkml.kernel.org/r/1459482572-129494-1-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/util/tsc.c | 1 - tools/perf/arch/x86/util/tsc.h | 17 ----------------- tools/perf/jvmti/jvmti_agent.c | 43 ++++++++++++++++++++++++++++++++++++++++-- tools/perf/util/Build | 3 +-- tools/perf/util/jitdump.c | 37 +++++++++++++++++++++++++++++++----- tools/perf/util/jitdump.h | 3 +++ tools/perf/util/tsc.h | 11 ++++++++++- 7 files changed, 87 insertions(+), 28 deletions(-) commit fca0ce2a5caf6ae7d9d8510fb87ae6195b40057a Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Mar 21 14:43:22 2016 +0000 drm/i915: Fix plane init failure paths Deal with errors from drm_universal_plane_init() in primary and cursor plane init paths (sprites were already covered). Also make the code neater by using goto for error handling. v2: Rebased due to drm_universal_plane_init() 'name' parameter v3: Another rebase due to s/""/NULL/ v4: Rebased on drm-nightly (Matthew Auld) v5: Fix email address (Matthew Auld) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Matthew Auld <matthew.auld@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458571402-32749-1-git-send-email-matthew.auld@intel.com drivers/gpu/drm/i915/intel_display.c | 64 ++++++++++++++++++++++-------------- drivers/gpu/drm/i915/intel_sprite.c | 34 +++++++++++-------- 2 files changed, 60 insertions(+), 38 deletions(-) commit 5593946921834a63d89c595ef8459c50d30f5438 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:59 2016 +0200 drm/i915: Remove the "three times for luck" trick from vlv_enable_pll() VLV DPLL is somewhat sane and doesn't run on luck. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-7-git-send-email-ville.syrjala@linux.intel.com Acked-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 11 ----------- 1 file changed, 11 deletions(-) commit 7d1a83cb68172a225c45243e955d9ee41eada8e9 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:58 2016 +0200 drm/i915: assert_panel_unlocked() in chv_enable_pll() Supposedly the power sequencer still locks out the DPLL registers on CHV, so let's issue a warning if it's still locked when enabling the DPLL. Also drop the redundant IS_MOBILE() check for VLV when we check the same thing. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 8bd3f301ab6638d84f3e1c3c7e9ea2bf5b6880c2 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:57 2016 +0200 drm/i915: Add a local pipe variable to vlv_enable_pll() Avoid redundant crtc->pipe lookups by giving vlv_enable_pll() a local pipe variable. Also makes it look more like the corresponding CHV code. While at is change the CHV code to enum pipe from int, Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit c231775c2df845abc193666a5aec552c3ad3740f Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:56 2016 +0200 drm/i915: Implement WaPixelRepeatModeFixForC0:chv DPLL_MD(PIPE_C) is AWOL on CHV. Instead of fixing it someone added chicken bits to propagate the pixel multiplier from DPLL_MD(PIPE_B) to either pipe B or C. So do that to make pixel repeat work on pipes B and C. Pipe A is fine without any tricks. Fortunately the pixel repeat propagation appears to be a oneshot operation, so once the value has been written we can clear the chicken bits. So it is still possible to drive pipe B and C with different pixel multipliers simultaneosly. Looks like DPLL_VGA_MODE_DIS must also be set in DPLL(PIPE_B) for this to work. But since we keep that bit always set in all DPLLs there's no problem. This of course means we can't reliably read out the pixel multiplier for pipes B and C. That would make the state checker unhappy, so I added shadow copies of those registers in to dev_priv. The other option would have been to skip pixel multiplier, dpll_md an dotclock checks entirely on CHV, but that feels like a serious loss of cross checking, so just pretending that we have working DPLL MD registers seemed better. Obviously with the shadow copies we can't detect if the pixel multiplier was properly configured, nor can we take over its state from the BIOS, but hopefully people won't have displays that would be limitd to such crappy modes. There is one strange flicker still remaining. It's visible on pipe C/HDMID when HDMIB is enabled while driven by pipe B. It doesn't occur if pipe A drives HDMIB, nor is there any glitch on pipe B/HDMIB when port C/HDMID starts up. I don't have a board with HDMIC so not sure if it happens there too. So I'm not sure if it's somehow tied in with this strange linkage between pipe B and C. Sadly I was unable to find an enable sequence that would avoid the glitch, but at least it's not fatal ie. the output recovers afterwards. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_drv.h | 7 +++++++ drivers/gpu/drm/i915/i915_reg.h | 4 ++++ drivers/gpu/drm/i915/intel_display.c | 30 ++++++++++++++++++++++++++---- 3 files changed, 37 insertions(+), 4 deletions(-) commit 03ed5cbfacfb35a5d3aeeb39ebec63437917e7f1 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:55 2016 +0200 drm/i915: Make {vlv,chv}_{disable,update}_pll() more similar The VLV and CHV DPLL disable and update are almost identical in how the DPLL/DPLL_MD registers need to be set up. But the code looks more different than it really is. Try to bring them into line. Note that we now leave the refclock always enabled for both DPLLs in the dual channel PHY. But that's perfectly fine since it's the same clock, and we anyway already do that when turning the disp2d power well on. v2: s/chv_update_pll/chv_compute_dpll/ v3: Add a note that we leave refclocks enabled for both DPLLs (Jani) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 63 ++++++++++++++---------------------- 1 file changed, 25 insertions(+), 38 deletions(-) commit 27878ede4fec7b929c3010710ba4d55c617c621d Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 15 16:39:54 2016 +0200 drm/i915: Throw out BUGs from DPLL/PCH functions These BUGs don't serve any purpose IMO. Throw them out. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458052809-23426-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_display.c | 9 --------- 1 file changed, 9 deletions(-) commit 5b421c57e0a9cb1187c2fe203d01fbfb651cb061 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Tue Mar 1 16:16:23 2016 +0200 drm/i915: Disable FDI RX before DDI_BUF_CTL Bspec is confused w.r.t. the HSW/BDW FDI disable sequence. It lists FDI RX disable both as step 13 and step 18 in the sequence. But I dug up an old BUN mail from Art that moved the FDI RX disable to happen before DDI_BUF_CTL disable. That BUN did not renumber the steps and just added a note: "Workaround: Disable PCH FDI Receiver before disabling DDI_BUF_CTL." The BUN described the symptoms of the fixed issue as: "PCH display underflow and a black screen on the analog CRT port that happened after a FDI re-train" I suppose later someone tried to renumber the steps to match, but forgot to remove the FDI RX disable from its old position in the sequence. They also forgot to update the note describing what should be done in case of an FDI training failure. Currently it says: "To retry FDI training, follow the Disable Sequence steps to Disable FDI, but skip the steps related to clocks and PLLs (16, 19, and 20), ..." It should really say "17, 20, and 21" with the current sequence because those are the steps that deal with PLLs and whatnot, after step 13 became FDI RX disable. And had the step 18 FDI RX disable been removed, as I suspect it should have, the note should actually say "17, 19, and 20". So, let's move the FDI RX disable to happen before DDI_BUF_CTL disable, as that would appear to be the correct order based on the BUN. Note that Art has since unconfused the spec, and so this patch should now match the steps listed in the spec. v2: Add a note that the spec is now correct Cc: Paulo Zanoni <przanoni@gmail.com> Cc: Art Runyan <arthur.j.runyan@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456841783-4779-1-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> drivers/gpu/drm/i915/intel_ddi.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) commit 1ab0c304a029fe3f2338c505b81df02d4220dbc7 Author: Heiko Stuebner <heiko@sntech.de> Date: Thu Aug 6 22:57:08 2015 +0200 ARM: dts: rockchip: update rk3288-veyron cpu operating points The generic operating points specified in rk3288.dtsi are specified by Rockchip as conservative and for all cases. In contrast the Veyron ChromeOS devices are supposed to use a special chip variant often called rk3288-c and use different operating points in their kernel also including a higher max frequency. So override the operating points for veyron devices. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Douglas Anderson <dianders@chromium.org> arch/arm/boot/dts/rk3288-veyron.dtsi | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit 6cf151fc53aeaa7757d3b9ab608bb7e51154de06 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Fri Apr 1 16:16:14 2016 +0200 dt-bindings: Add Oxford Semiconductor Reset Controller bindings Add bindings for the Oxford Semiconductor OXNAS reset controller. Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> .../devicetree/bindings/reset/oxnas,reset.txt | 58 ++++++++++++++++++++++ 1 file changed, 58 insertions(+) commit 6e667fac8259d0dd2cf883fa3c51c0b8b8c89a90 Author: Neil Armstrong <narmstrong@baylibre.com> Date: Fri Apr 1 16:16:13 2016 +0200 reset: Add Oxford Semiconductor Reset Controller driver Add System reset controller driver for Oxford Semiconductor OXNAS SoC Family. CC: Ma Haijun <mahaijuns@gmail.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/reset/Kconfig | 3 + drivers/reset/Makefile | 1 + drivers/reset/reset-oxnas.c | 136 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 140 insertions(+) commit d32f7fd3bbc32732b094d938b95169521503a9fb Author: Irina Tirdea <irina.tirdea@intel.com> Date: Thu Mar 31 14:44:42 2016 +0300 pinctrl: Rename pinctrl_utils_dt_free_map to pinctrl_utils_free_map Rename pinctrl_utils_dt_free_map to pinctrl_utils_free_map, since it does not depend on device tree despite the current name. This will enforce a consistent naming in pinctr-utils.c and will make it clear it can be called from outside device tree (e.g. from ACPI handling code). Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-bcm281xx.c | 2 +- drivers/pinctrl/bcm/pinctrl-cygnus-mux.c | 2 +- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 2 +- drivers/pinctrl/bcm/pinctrl-nsp-gpio.c | 2 +- drivers/pinctrl/berlin/berlin.c | 2 +- drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 4 ++-- drivers/pinctrl/meson/pinctrl-meson.c | 2 +- drivers/pinctrl/nomadik/pinctrl-abx500.c | 4 ++-- drivers/pinctrl/nomadik/pinctrl-nomadik.c | 4 ++-- drivers/pinctrl/pinconf-generic.c | 2 +- drivers/pinctrl/pinctrl-amd.c | 2 +- drivers/pinctrl/pinctrl-as3722.c | 2 +- drivers/pinctrl/pinctrl-at91-pio4.c | 4 ++-- drivers/pinctrl/pinctrl-digicolor.c | 2 +- drivers/pinctrl/pinctrl-lpc18xx.c | 2 +- drivers/pinctrl/pinctrl-palmas.c | 2 +- drivers/pinctrl/pinctrl-pic32.c | 2 +- drivers/pinctrl/pinctrl-pistachio.c | 2 +- drivers/pinctrl/pinctrl-tb10x.c | 2 +- drivers/pinctrl/pinctrl-utils.c | 4 ++-- drivers/pinctrl/pinctrl-utils.h | 2 +- drivers/pinctrl/pinctrl-zynq.c | 2 +- drivers/pinctrl/pxa/pinctrl-pxa2xx.c | 2 +- drivers/pinctrl/qcom/pinctrl-msm.c | 2 +- drivers/pinctrl/qcom/pinctrl-spmi-gpio.c | 2 +- drivers/pinctrl/qcom/pinctrl-spmi-mpp.c | 2 +- drivers/pinctrl/qcom/pinctrl-ssbi-gpio.c | 2 +- drivers/pinctrl/qcom/pinctrl-ssbi-mpp.c | 2 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 4 ++-- drivers/pinctrl/tegra/pinctrl-tegra-xusb.c | 2 +- drivers/pinctrl/tegra/pinctrl-tegra.c | 4 ++-- drivers/pinctrl/uniphier/pinctrl-uniphier-core.c | 2 +- 32 files changed, 39 insertions(+), 39 deletions(-) commit 3b812ecce736432e6b55e77028ea387eb1517d24 Author: Jessica Yu <jeyu@redhat.com> Date: Tue Mar 22 20:03:19 2016 -0400 Documentation: livepatch: outline Elf format and requirements for patch modules Document livepatch module requirements and the special Elf constants patch modules use. Signed-off-by: Jessica Yu <jeyu@redhat.com> Acked-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Documentation/livepatch/module-elf-format.txt | 311 ++++++++++++++++++++++++++ 1 file changed, 311 insertions(+) commit 425595a7fc2096ab46c741b5ed5372c5ab5bbeac Author: Jessica Yu <jeyu@redhat.com> Date: Tue Mar 22 20:03:18 2016 -0400 livepatch: reuse module loader code to write relocations Reuse module loader code to write relocations, thereby eliminating the need for architecture specific relocation code in livepatch. Specifically, reuse the apply_relocate_add() function in the module loader to write relocations instead of duplicating functionality in livepatch's arch-dependent klp_write_module_reloc() function. In order to accomplish this, livepatch modules manage their own relocation sections (marked with the SHF_RELA_LIVEPATCH section flag) and livepatch-specific symbols (marked with SHN_LIVEPATCH symbol section index). To apply livepatch relocation sections, livepatch symbols referenced by relocs are resolved and then apply_relocate_add() is called to apply those relocations. In addition, remove x86 livepatch relocation code and the s390 klp_write_module_reloc() function stub. They are no longer needed since relocation work has been offloaded to module loader. Lastly, mark the module as a livepatch module so that the module loader canappropriately identify and initialize it. Signed-off-by: Jessica Yu <jeyu@redhat.com> Reviewed-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com> # for s390 changes Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/s390/include/asm/livepatch.h | 7 -- arch/x86/include/asm/livepatch.h | 2 - arch/x86/kernel/Makefile | 1 - arch/x86/kernel/livepatch.c | 70 ----------------- include/linux/livepatch.h | 20 ----- kernel/livepatch/core.c | 148 ++++++++++++++++++++++------------- samples/livepatch/livepatch-sample.c | 1 + 7 files changed, 95 insertions(+), 154 deletions(-) commit f31e0960f395df0c9197de53674365e2a28a129b Author: Jessica Yu <jeyu@redhat.com> Date: Tue Mar 22 20:03:17 2016 -0400 module: s390: keep mod_arch_specific for livepatch modules Livepatch needs to utilize the symbol information contained in the mod_arch_specific struct in order to be able to call the s390 apply_relocate_add() function to apply relocations. Keep a reference to syminfo if the module is a livepatch module. Remove the redundant vfree() in module_finalize() since module_arch_freeing_init() (which also frees those structures) is called in do_init_module(). If the module isn't a livepatch module, we free the structures in module_arch_freeing_init() as usual. Signed-off-by: Jessica Yu <jeyu@redhat.com> Reviewed-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> arch/s390/kernel/module.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 1ce15ef4f60529cf1313f80f4338c88bd65cc572 Author: Jessica Yu <jeyu@redhat.com> Date: Tue Mar 22 20:03:16 2016 -0400 module: preserve Elf information for livepatch modules For livepatch modules, copy Elf section, symbol, and string information from the load_info struct in the module loader. Persist copies of the original symbol table and string table. Livepatch manages its own relocation sections in order to reuse module loader code to write relocations. Livepatch modules must preserve Elf information such as section indices in order to apply livepatch relocation sections using the module loader's apply_relocate_add() function. In order to apply livepatch relocation sections, livepatch modules must keep a complete copy of their original symbol table in memory. Normally, a stripped down copy of a module's symbol table (containing only "core" symbols) is made available through module->core_symtab. But for livepatch modules, the symbol table copied into memory on module load must be exactly the same as the symbol table produced when the patch module was compiled. This is because the relocations in each livepatch relocation section refer to their respective symbols with their symbol indices, and the original symbol indices (and thus the symtab ordering) must be preserved in order for apply_relocate_add() to find the right symbol. Signed-off-by: Jessica Yu <jeyu@redhat.com> Reviewed-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Reviewed-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Jiri Kosina <jkosina@suse.cz> include/linux/module.h | 25 ++++++++++ kernel/module.c | 125 +++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 147 insertions(+), 3 deletions(-) commit 8d98e96b345e13659aa42bdc611368863ce65cbe Author: Jessica Yu <jeyu@redhat.com> Date: Tue Mar 22 20:03:15 2016 -0400 Elf: add livepatch-specific Elf constants Livepatch manages its own relocation sections and symbols in order to be able to reuse module loader code to write relocations. This removes livepatch's dependence on separate "dynrela" sections to write relocations and also allows livepatch to patch modules that are not yet loaded. The livepatch Elf relocation section flag (SHF_RELA_LIVEPATCH), and symbol section index (SHN_LIVEPATCH) allow both livepatch and the module loader to identity livepatch relocation sections and livepatch symbols. Livepatch relocation sections are marked with SHF_RELA_LIVEPATCH to indicate to the module loader that it should not apply that relocation section and that livepatch will handle them. The SHN_LIVEPATCH shndx marks symbols that will be resolved by livepatch. The module loader ignores these symbols and does not attempt to resolve them. The values of these Elf constants were selected from OS-specific ranges according to the definitions from glibc. Signed-off-by: Jessica Yu <jeyu@redhat.com> Reviewed-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> include/uapi/linux/elf.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 20b3d2a79f0f9ff1ac189f43df7598d0e968210a Author: Stefan Wahren <stefan.wahren@i2se.com> Date: Mon Mar 28 14:58:24 2016 +0000 pinctrl: bcm2835: Implement get_direction callback Implement gpio_chip's get_direction() callback, that lets other drivers get particular GPIOs direction using gpiod_get_direction(). Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Stephen Warren <swarren@wwwdotorg.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/bcm/pinctrl-bcm2835.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 934458c2c95df4077b426a00bfd9d62e818f914e Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Fri Apr 1 14:41:01 2016 +0300 Revert "drm/i915: Fix races on fbdev" This reverts commit a7442b93cf32c1e1ddb721a26cd1f92302e2a222. With the patch applied SNB, IVB and ILK are experiencing hard machine hangs. Original patch was to fix "just" kernel panics so it's not a good trade-off. Proper fix for the panic is on the way, lets revert until then. Fixes: a7442b93cf32 ("drm/i915: Fix races on fbdev") Cc: Lukas Wunner <lukas@wunner.de> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Tomi Sarvela <tomi.p.sarvela@intel.com> Cc: stable@vger.kernel.org Acked-by: Lukas Wunner <lukas@wunner.de> Tested-by: Tomi Sarvela <tomi.p.sarvela@intel.com> Suggested-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459510861-29035-1-git-send-email-joonas.lahtinen@linux.intel.com drivers/gpu/drm/i915/i915_dma.c | 8 +++++--- drivers/gpu/drm/i915/intel_fbdev.c | 3 --- 2 files changed, 5 insertions(+), 6 deletions(-) commit e37788fdb2c8138a1e3733de1e780389242e52d9 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 13:11:09 2016 +0200 drm/i915/dsi: refer to gpio index instead of gpio to avoid confusion The DSI sequence blocks contain gpio index references, not actual gpio numbers. No functional changes. Reviewed-by: Mika Kahola <mika.kahola@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/4a54778e56b507e8a0bd635ba02ed2a4734b00ac.1458299160.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) commit 11b538cd6df398c86f4f0e09049c41e3058af10d Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Apr 1 10:44:41 2016 +0300 drm/i915: use for_each_port_masked in bxt phy init for clarity Make it easier to see which ports are configured for each phy. No functional changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459496681-398-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_ddi.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) commit b61e79967a6f35043aa838ff36d9970658a0af3d Author: Vandana Kannan <vandana.kannan@intel.com> Date: Thu Mar 31 23:15:54 2016 +0530 drm/i915: BXT DDI PHY sequence BUN According to the BSpec update, bit 7 of PORT_CL1CM_DW0 register needs to be checked to ensure that the register is in accessible state. Also, based on a BSpec update, changing the timeout value to check iphypwrgood, from 10ms to wait for up to 100us. v2: [Ville] use wait_for_us instead of the atomic call. v3: [Jani/Imre] read register only once Signed-off-by: Vandana Kannan <vandana.kannan@intel.com> Reported-by: Philippe Lecluse <Philippe.Lecluse@intel.com> Cc: Deak, Imre <imre.deak@intel.com> Cc: Nikula, Jani <jani.nikula@intel.com> Acked-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459446354-19012-1-git-send-email-vandana.kannan@intel.com drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ddi.c | 13 +++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) commit eeb01a57921a5e373302733d7cdf1ca87da5375a Author: Yusuke Fujimaki <usk.fujimaki@gmail.com> Date: Mon Mar 21 16:18:42 2016 +0900 HID: Asus X205TA keyboard driver Asus X205TA built-in keyboard contains wrong logical maximum value in report descriptor. 0x05, 0x01, // Usage Page (Generic Desktop) 0x09, 0x06, // Usage (Keyboard) 0xa1, 0x01, // Collection (Application) 0x85, 0x01, // Report ID (1) 0x05, 0x07, // Usage Page (Keyboard/Keypad) 0x19, 0xe0, // Usage Minimum (224) 0x29, 0xe7, // Usage Maximum (231) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x75, 0x01, // Report Size (1) 0x95, 0x08, // Report Count (8) 0x81, 0x02, // Input (Data,Array,Abs) 0x95, 0x01, // Report Count (1) 0x75, 0x08, // Report Size (8) 0x81, 0x03, // Input (Const,Var,Abs) 0x95, 0x05, // Report Count (5) 0x75, 0x01, // Report Size (1) 0x05, 0x08, // Usage (LED) 0x19, 0x01, // Usage Minimum (1) 0x29, 0x05, // Usage Maximum (5) 0x91, 0x02, // Output (Data,Var,Abs) 0x95, 0x01, // Report Count (1) 0x75, 0x03, // Report Size (3) 0x91, 0x03, // Output (Const,Var,Abs) 0x95, 0x06, // Report Count (6) 0x75, 0x08, // Report Size (8) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x65, // Logical Maximum (101) * too small * 0x05, 0x07, // Usage Page (Keyboard/Keypad) 0x19, 0x00, // Usage Minimum (0) 0x29, 0xdd, // Usage Maximum (221) 0x81, 0x00, // Input(Data,Array,Abs) In Asus X205TA japanese keyboard model,there are language specific keys over usage id 101. This patch correct wrong logical maximum in report descriptor. Signed-off-by: Yusuke Fujimaki <usk.fujimaki@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/Kconfig | 6 ++++++ drivers/hid/Makefile | 1 + drivers/hid/hid-asus.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ drivers/hid/hid-core.c | 1 + drivers/hid/hid-ids.h | 1 + 5 files changed, 57 insertions(+) commit 1c532e00a0c649ac6f0703e8c2e095c9c1d30625 Author: Alex Thorlton <athorlton@sgi.com> Date: Thu Mar 31 14:18:29 2016 -0500 x86/platform/uv: Disable UV BAU by default For several years, the common practice has been to boot UVs with the "nobau" parameter on the command line, to disable the BAU. We've decided that it makes more sense to just disable the BAU by default in the kernel, and provide the option to turn it on, if desired. For now, having the on/off switch doesn't buy us any more than just reversing the logic would, but we're working towards having the BAU enabled by default on UV4. When those changes are in place, having the on/off switch will make more sense than an enable flag, since the default behavior will be different depending on the system version. I've also added a bit of documentation for the new parameter to Documentation/kernel-parameters.txt. Signed-off-by: Alex Thorlton <athorlton@sgi.com> Reviewed-by: Hedi Berriche <hedi@sgi.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459451909-121845-1-git-send-email-athorlton@sgi.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/kernel-parameters.txt | 8 ++++++++ arch/x86/include/asm/uv/uv_bau.h | 2 +- arch/x86/platform/uv/tlb_uv.c | 35 +++++++++++++++++++++++++---------- 3 files changed, 34 insertions(+), 11 deletions(-) commit 39ff747b2f8197de51dae540e742de4acdbd7763 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Wed Mar 30 18:05:26 2016 +0530 drm/i915: force full detect on sink count change This patch checks for changes in sink count between short pulse hpds and forces full detect when there is a change. This will allow both detection of hotplug and unplug of panels through dongles that give only short pulse for such events. v2: changed variable type from u8 to bool (Jani) return immediately if perform_full_detect is set(Siva) v3: changed method of determining full detection from using pointer to return code (Siva) v4: changed comments to indicate meaning of return value of intel_dp_short_pulse and explain the use of return value from intel_dp_get_dpcd in intel_dp_short_pulse (Ander) Tested-by: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459341326-13142-5-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 33 +++++++++++++++++++++++++++------ 1 file changed, 27 insertions(+), 6 deletions(-) commit 30d9aa4265fe4b2b28239934770b2c2d59858df3 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Wed Mar 30 18:05:25 2016 +0530 drm/i915: Read sink_count dpcd always Sink count can change between short pulse hpd hence this patch adds a member variable to intel_dp so we can track any changes between short pulse interrupts. This patch reads sink_count dpcd always and removes its read operation based on values in downstream port dpcd. SINK_COUNT dpcd is not dependent on DOWNSTREAM_PORT_PRESENT dpcd. SINK_COUNT denotes if a display is attached, while DOWNSTREAM_PORT_PRESET indicates how many ports are available in the dongle where display can be attached. so it is possible for sink count to change irrespective of value in downstream port dpcd. Here is a table of possible values and scenarios sink_count downstream_port present 0 0 no display is attached 0 1 dongle is connected without display 1 0 display connected directly 1 1 display connected through dongle v2: Storing value of intel_dp->sink_count that is ready for consumption. (Ander) Squashing two commits into one. (Ander) v3: Added comment to explain the need of early return when sink count is 0. (Ander) Tested-by: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459341326-13142-4-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 30 +++++++++++++++++++++++------- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 24 insertions(+), 7 deletions(-) commit 5c9114d0ced2f16d1bfeda650b4acf95159f4759 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Wed Mar 30 18:05:24 2016 +0530 drm/i915: Reorganizing intel_dp_check_link_status When created originally intel_dp_check_link_status() was supposed to handle only link training for short pulse but has grown into handler for short pulse itself. This patch cleans up this function by splitting it into two halves. First intel_dp_short_pulse() is called, which will be entry point and handle all logic for short pulse handling while intel_dp_check_link_status() will retain its original purpose of only doing link status related work. intel_dp_short_pulse: All existing code other than link status read and link training upon error status. intel_dp_check_link_status: The link status should be read on short pulse irrespective of panel being enabled or not so intel_dp_get_link_status() performs dpcd read first then based on crtc active / enabled it will perform the link training. This is because short pulse is a generic interrupt which should always be handled, because it may mean: 1. Hotplug/unplug of MST panel 2. Hotplug/unplug of dongle 3. Link status change for other DP panels v2: Added WARN_ON to intel_dp_check_link_status() Removed a call to intel_dp_get_link_status() (Ander) v3: Changed commit message to explain need of link status being read before performing encoder checks (Daniel) v4: Changed commit message to explain need of reading link status on short pulse (Ander) Tested-by: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> [anderco: fix parenthesis alignment] Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459341326-13142-3-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 65 +++++++++++++++++++++++------------------ 1 file changed, 36 insertions(+), 29 deletions(-) commit 7d23e3c37bb3fc6952dc84007ee60cb533fd2d5c Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Wed Mar 30 18:05:23 2016 +0530 drm/i915: Cleaning up intel_dp_hpd_pulse Current DP detection has DPCD operations split across intel_dp_hpd_pulse and intel_dp_detect which contains duplicates as well. Also intel_dp_detect is called during modes enumeration as well which will result in multiple dpcd operations. So this patch tries to solve both these by bringing all DPCD operations in one single function and make intel_dp_detect use existing values instead of repeating same steps. v2: Pulled in a hunk from last patch of the series to this patch. (Ander) v3: Added MST hotplug handling. (Ander) v4: Added a flag to check if detect is performed to prevent multiple detects on hotplug. (Ander) Tested-by: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> [anderco: fix parenthesis aligment] Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459341326-13142-2-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 72 +++++++++++++++++++++++++--------------- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 47 insertions(+), 26 deletions(-) commit f21a21983ef13a031250c4c3f6018e29a549d0f1 Author: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Date: Wed Mar 30 18:05:22 2016 +0530 drm/i915: Splitting intel_dp_detect intel_dp_detect() is called for not just detection but during modes enumeration as well. Repeating the whole sequence during each of these calls is wasteful and time consuming. This patch moves probing for panel, DPCD read etc done in intel_dp_detect() to a new function intel_dp_long_pulse(). Note that the behavior of intel_dp_detect() is changed to report connected or disconnected depending on whether the EDID is available or not. This change will be required by further patches in the series to avoid performing duplicated DPCD operations on hotplug. v2: Moved a hunk to next patch of the series. Moved intel_dp_unset_edid to out. (Ander) v3: Rephrased commit message and intel_dp_unset_dp() is called within intel_dp_set_dp() to free the previous EDID. (Ander) v4: Added overriding of status to disconnected for MST. (Ander) Tested-by: Nathan D Ciobanu <nathan.d.ciobanu@intel.com> Signed-off-by: Sivakumar Thulasimani <sivakumar.thulasimani@intel.com> Signed-off-by: Shubhangi Shrivastava <shubhangi.shrivastava@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> [anderco: fix parenthesis alignment] Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459341326-13142-1-git-send-email-shubhangi.shrivastava@intel.com drivers/gpu/drm/i915/intel_dp.c | 63 ++++++++++++++++++++++++++++------------- 1 file changed, 43 insertions(+), 20 deletions(-) commit d7847a7017b2a2759dd5590c0cffdbdf2994918e Author: Ingo Molnar <mingo@kernel.org> Date: Fri Apr 1 09:00:35 2016 +0200 x86/cpufeature: Fix build bug caused by merge artifact with the removal of cpu_has_hypervisor The 0-day build robot by Fengguang Wu reported a build failure: arch/x86/events//intel/cstate.c: In function 'cstate_pmu_init': arch/x86/events//intel/cstate.c:680:6: error: 'cpu_has_hypervisor' undeclared (first use in this function) ... which was caused by a merge mistake I made when applying the following patch: 0c9f3536cc71 ("x86/cpufeature: Remove cpu_has_hypervisor") apply the missing hunk as well. Reported-by: kbuild test robot <fengguang.wu@intel.com> Cc: David Kershner <david.kershner@unisys.com> Cc: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: sparmaintainer@unisys.com Cc: virtualization@lists.linux-foundation.org Link: http://lkml.kernel.org/r/1459266123-21878-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/cstate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d18d12d0ff07c47fb913f297c174f30a3f96042d Author: Richard Cochran <rcochran@linutronix.de> Date: Thu Mar 31 15:51:32 2016 +0200 lib/proportions: Remove unused code By accident I stumbled across code that is no longer used. According to git grep, the global functions in lib/proportions.c are not used anywhere. This patch removes the old, unused code. Peter Zijlstra further commented: "Ah indeed, that got replaced with the flex proportion code a while back." Signed-off-by: Richard Cochran <rcochran@linutronix.de> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/4265b49bed713fbe3faaf8c05da0e1792f09c0b3.1459432020.git.rcochran@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> include/linux/proportions.h | 137 --------------- include/linux/sched.h | 1 - lib/Makefile | 2 +- lib/proportions.c | 407 -------------------------------------------- 4 files changed, 1 insertion(+), 546 deletions(-) commit 0b27c02a7f1c697694f2ad6d6517e7dbf9ecfa39 Author: Eric Anholt <eric@anholt.net> Date: Fri Mar 18 12:34:59 2016 -0700 drm: Add an encoder and connector type enum for DPI. Right now exynos is exposing DPI as a TMDS encoder and VGA connector, which seems rather misleading. This isn't just an internal detail, since xrandr actually exposes "VGA" as the output name. Define some new enums so that vc4's DPI can have a more informative name. I considered other names for the connector as well. For VC4, the Adafruit DPI kippah takes the 28 GPIO pins and routes them to a standard-ish 40-pin FPC connector, but "40-pin FPC" doesn't uniquely identify an ordering of pins (apparently some other orderings exist), doesn't explain things as well for the user (who, if anything, knows their product is a DPI kippah/panel combo), and actually doesn't have to exist (one could connect the 28 GPIOs directly to something else). Simply "DPI" seems like a good compromise name to distinguish from the HDMI, DSI, and TV connectors . Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/drm_crtc.c | 2 ++ include/uapi/drm/drm_mode.h | 2 ++ 2 files changed, 4 insertions(+) commit e70c7ae1c594300660a552773c12aa9945770ae6 Author: Jaehoon Chung <jh80.chung@samsung.com> Date: Thu Mar 31 11:48:05 2016 +0900 ARM: dts: exynos: Add MSHC2 DT node for SD card for exynos3250-artik5-eval board This patch adds MSHC (Mobile Storage Host Controller) DT node for Exynos3250 SoC. MSHC is an interface between the system and the SD card. Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-artik5-eval.dts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit b004a34bd0ffefdccc5a57a8d8075a760a63c81e Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:48:04 2016 +0900 ARM: dts: exynos: Add exynos3250-artik5 dtsi file for ARTIK5 module This patch adds the Device Tree source for Samsung ARTIK5 module[1] based on Exynos3250 SoC. The ARTIK5 module includes the following devices: - Application Processor (Samsung Exynos3250) - WiFi/BT Combo chip (Broadcom4354) - PMIC (Samsung S2MPS14) - eMMC (4GB) - DRAM LPDDR3 (512MB) - Connectors pin (60 Pins x 3 set) Also, this patch adds the ARTIK5 evaluation board[2] dts file which includes the ARTIK5 module[1] and have the devices such as sound codec, sd card port, ethernet port, uart port and so on. [1] https://www.artik.io/hardware/artik-5 [2] http://www.digikey.com/product-search/en?FV=ffecca14 Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Andi Shyti <andi.shyti@samsung.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../bindings/arm/samsung/samsung-boards.txt | 2 + arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/exynos3250-artik5-eval.dts | 26 ++ arch/arm/boot/dts/exynos3250-artik5.dtsi | 334 +++++++++++++++++++++ 4 files changed, 363 insertions(+) commit 92173e6ac26272b84dd275ca2c8ad357bdbfe6db Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:48:03 2016 +0900 ARM: dts: exynos: Add MSHC2 DT node for Exynos3250 SoC This patch adds the MSHC2 (Mobile Storage Host Controller) Device Tree node for Exynos3250 SoC. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-pinctrl.dtsi | 35 +++++++++++++++++++++++++++++++ arch/arm/boot/dts/exynos3250.dtsi | 13 ++++++++++++ 2 files changed, 48 insertions(+) commit ecaba514f4cb74fb076ac99be4719fb8cd9d584a Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Thu Mar 31 11:48:01 2016 +0900 ARM: dts: exynos: Add UART2 DT node for Exynos3250 SoC This patch add the UART2 Device Tree node for Exynos3250 SoC. Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-pinctrl.dtsi | 7 +++++++ arch/arm/boot/dts/exynos3250.dtsi | 12 ++++++++++++ 2 files changed, 19 insertions(+) commit d278c808f52a5fdbdd93deb3636ea9558e56ffb7 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:48:02 2016 +0900 ARM: dts: exynos: Add initial gpio setting of MMC2 device for exynos3250-monk This patch adds initial pin configuration of MMC2 device on exynos3250-monk board because the MMC2 gpio pin (gpk2[0-6]) are NC (not connected) state. Suggested-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-monk.dts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) commit 40bbd191fc808dcd0ef154a6c8af8dd66d3c1270 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:47:57 2016 +0900 ARM: dts: exynos: Add initial pin configuration for exynos3250-rinato This patch adds initial pin configuration using pinctrl subsystem to reduce leakage power-consumption of gpio pins in normal state. All pins included in this patch are NC (not connected) pin. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos3250-pinctrl.dtsi | 38 +++++++++++++++++ arch/arm/boot/dts/exynos3250-rinato.dts | 71 ++++++++++++++++++++++++++++++- 2 files changed, 107 insertions(+), 2 deletions(-) commit a8b41ea4babb4bdf8ba3b078e1c6761189d29eb7 Merge: f55532a f676471 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Fri Apr 1 02:09:43 2016 +0200 Merge tag 'clk-v4.7-exynos3250' of git://linuxtv.org/snawrocki/samsung into for-v4.7/dt-exynos3250-artik5 Addition of the Exynos3250 SoC's UART2 and MMC2 clocks. Pull clocks used on Exynos3250-based Artik-5 board. commit 423de92f56bdfc3e68503af31e6ec041d59a6a25 Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Thu Mar 24 10:38:04 2016 +0200 mei: bus: use scnprintf in *_show There's no reason to duplicate the logic provided by scnprintf(). Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/misc/mei/bus.c | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) commit 5ba10dd4a1727714faaac9a48f6aa69d8ee33248 Author: Moise Gergaud <moise.gergaud@st.com> Date: Thu Mar 31 18:00:55 2016 +0200 ASoC: sti: correct typo errors Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> .../devicetree/bindings/sound/st,sti-asoc-card.txt | 4 ++-- sound/soc/sti/uniperif.h | 22 +++++++++++----------- 2 files changed, 13 insertions(+), 13 deletions(-) commit 480b1eb659f65be8ed039f1a9db3f762c41c9770 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 29 10:50:38 2016 -0700 rcutorture: Convert test duration to seconds early This commit converts test duration from minutes to seconds early on in order to prepare for upcoming OS-jitter-injection changes. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> tools/testing/selftests/rcutorture/bin/kvm-test-1-run.sh | 5 ++--- tools/testing/selftests/rcutorture/bin/kvm.sh | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) commit fb2c66af10f92bc83659c4d8a32e02287f0e5dda Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Mar 28 14:44:42 2016 -0700 torture: Kill qemu, not parent process The current hang-check machinery in the rcutorture scripts uses "$!" of a parenthesized bash statement to capture the pid. Unfortunately, this captures not qemu's pid, but rather that of its parent that implements the parenthesized statement. This commit therefore adjusts things so as to capture qemu's actual pid, which then allows the script to actually kill qemu in event of a kernel hang. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../selftests/rcutorture/bin/kvm-test-1-run.sh | 30 +++++++++++++++++----- 1 file changed, 24 insertions(+), 6 deletions(-) commit 9eb5188a0704bd21eb7e4aef83b904fad43d3ec8 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Mar 21 15:36:40 2016 -0700 torture: Clarify refusal to run more than one torture test This commit clarifies error messages -- you only get to run one torture test at a time! Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/torture.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit de26ca19a530d2d822a6816834d22022e94b2e53 Author: Anna-Maria Gleixner <anna-maria@linutronix.de> Date: Thu Mar 17 11:14:35 2016 +0100 rcutorture: Consider FROZEN hotplug notifier transitions The hotplug notifier rcutorture_cpu_notify() doesn't consider the corresponding CPU_XXX_FROZEN transitions. They occur on suspend/resume and are usually handled the same way as the corresponding non frozen transitions. Mask the switch case action argument with '~CPU_TASKS_FROZEN' to map CPU_XXX_FROZEN hotplug transitions on corresponding non-frozen transitions. Cc: Josh Triplett <josh@joshtriplett.org> Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcutorture.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 67522beecfc75d133514dda64107ee19125a74b9 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 1 08:52:19 2016 -0800 rcutorture: Remove redundant initialization to zero The current code initializes the global per-CPU variables rcu_torture_count and rcu_torture_batch to zero. However, C does this initialization by default, and explicit initialization of per-CPU variables now needs a different syntax if "make tags" is to work. This commit therefore removes the initialization. Reported-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcutorture.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e6fb1fc1085e5b5155bc8f3d3385c48b8bdde95e Author: Artem Savkov <artem.savkov@gmail.com> Date: Sun Feb 7 13:31:39 2016 +0100 rcuperf: Do not wake up shutdown wait queue if "shutdown" is false. After finishing its tests rcuperf tries to wake up shutdown_wq even if "shutdown" param is set to false, resulting in a wake_up() call on an unitialized wait_queue_head_t which leads to "BUG: spinlock bad magic" and "BUG: unable to handle kernel NULL pointer dereference". Fix by checking "shutdown" param before waking up the queue. Signed-off-by: Artem Savkov <artem.savkov@gmail.com> kernel/rcu/rcuperf.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit dba6f1bab8920a6f78b0dc21976afdecf82fba3f Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Feb 1 16:39:38 2016 -0800 rcutorture: Add largish-system rcuperf scenario This commit adds an rcuperf scenario named TREE54 that uses 54 CPUs and provides a four-level rcu_node combining tree. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../selftests/rcutorture/configs/rcuperf/TREE54 | 23 ++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 620316e52a923811fe9a77ceb43eebf5f507d375 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sat Jan 30 21:32:09 2016 -0800 rcutorture: Avoid RCU CPU stall warning and RT throttling Running rcuperf can result in RCU CPU stall warnings and RT throttling. These occur because on of the real-time writer processes does ftrace_dump() while still running at real-time priority. This commit therefore prevents these problems by setting the writer thread back to SCHED_NORMAL (AKA SCHED_OTHER) before doing ftrace_dump(). In addition, this commit adds a small fixed delay before dumping ftrace buffer in order to decrease the probability that this dumping will interfere with other writers' grace periods. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcuperf.c | 4 ++++ 1 file changed, 4 insertions(+) commit df37e66bfdbb57e8cae7dbf39a0c66b1b8701338 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sat Jan 30 20:56:38 2016 -0800 rcutorture: Add rcuperf holdoff boot parameter to reduce interference Boot-time activity can legitimately grab CPUs for extended time periods, so the commit adds a boot parameter to delay the start of the performance test until boot has completed. Defaults to 10 seconds. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/kernel-parameters.txt | 6 ++++++ kernel/rcu/rcuperf.c | 5 +++++ 2 files changed, 11 insertions(+) commit 2b03d038457fc8d694d34981cb0a2f1702ba35d6 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sat Jan 30 16:51:36 2016 -0800 rcutorture: Make scripts analyze rcuperf trace data, if present The rcuperf event-trace data is more accurate than are the rcuperf printk()s because locking keeps things ordered. This commit therefore parses and analyzes this event-trace data if present, and falls back on the printk()s otherwise. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../rcutorture/bin/kvm-recheck-rcuperf-ftrace.sh | 121 +++++++++++++++++++++ .../rcutorture/bin/kvm-recheck-rcuperf.sh | 8 ++ 2 files changed, 129 insertions(+) commit ac2bb275e8e5abddb0815ff2b7aa383ed6d007a4 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Fri Jan 29 14:58:17 2016 -0800 rcutorture: Make rcuperf collect expedited event-trace data This commit enables ftrace in the rcuperf TREE kernel build and adds an ftrace_dump() at the end of rcuperf processing. This data will be used to measure the actual durations of the expedited grace periods without the added delays inherent in the kernel-module measurements. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcuperf.c | 1 + tools/testing/selftests/rcutorture/configs/rcuperf/TREE | 1 + 2 files changed, 2 insertions(+) commit e588f35492227cc4ab2cbfe95fd5f993a5086f9f Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Jan 12 17:26:35 2016 -0800 rcutorture: Print measure of batching efficiency This commit adds a line giving the number of grace periods, the number of batches, and the ratio. The larger the ratio, the greater the batching efficiency. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../rcutorture/bin/kvm-recheck-rcuperf.sh | 26 +++++++++++++--------- 1 file changed, 16 insertions(+), 10 deletions(-) commit 2094c99558d9e9374210898f65f5862f7a2e8bed Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Jan 12 15:17:21 2016 -0800 rcutorture: Set rcuperf writer kthreads to real-time priority This commit forces more deterministic update-side behavior by setting rcuperf's rcu_perf_writer() kthreads to real-time priority. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcuperf.c | 3 +++ 1 file changed, 3 insertions(+) commit 6b558c4c7a4ba410e39dbcb9d4c2b6e928c09308 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Jan 12 14:15:40 2016 -0800 rcutorture: Bind rcuperf reader/writer kthreads to CPUs This commit forces more deterministic behavior by binding rcuperf's rcu_perf_reader() and rcu_perf_writer() kthreads to their respective CPUs. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcuperf.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit bdea9e347783c2724997db7c5d5b45a301e2dc90 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Fri Jan 1 13:47:19 2016 -0800 rcutorture: Documentation for rcuperf kernel parameters This commit adds documentation for the new rcuperf module's kernel boot parameters. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/kernel-parameters.txt | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit 8704baab9bc848b58c129fed6b591bb84ec02f41 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Dec 31 18:33:22 2015 -0800 rcutorture: Add RCU grace-period performance tests This commit adds a new rcuperf module that carries out simple performance tests of RCU grace periods. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/Makefile | 1 + kernel/rcu/rcuperf.c | 637 +++++++++++++++++++++++++++++++++++++++++++++++++++ lib/Kconfig.debug | 33 +++ 3 files changed, 671 insertions(+) commit 291783b8ad77a83a6fdf91d55eee7f1ad72ed4d1 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Jan 12 13:43:30 2016 -0800 rcutorture: Expedited-GP batch progress access to torturing This commit provides rcu_exp_batches_completed() and rcu_exp_batches_completed_sched() functions to allow torture-test modules to check how many expedited grace period batches have completed. These are analogous to the existing rcu_batches_completed(), rcu_batches_completed_bh(), and rcu_batches_completed_sched() functions. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> include/linux/rcutiny.h | 16 ++++++++++++++++ include/linux/rcutree.h | 2 ++ kernel/rcu/tree.c | 22 ++++++++++++++++++++++ 3 files changed, 40 insertions(+) commit 9efafb8849f732a3497f46f178b350c9ff7cfe27 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Dec 31 18:11:47 2015 -0800 rcutorture: Allow for rcupdate.rcu_normal Currently, rcu_torture_writer() checks only for rcu_gp_is_expedited() when deciding whether or not to do dynamic control of RCU expediting. This means that if rcupdate.rcu_normal is specified, rcu_torture_writer() will attempt to dynamically control RCU expediting, but will nonetheless only test normal RCU grace periods. This commit therefore adds a check for !rcu_gp_is_normal(), and prints a message and desists from testing dynamic control of RCU expediting when doing so is futile. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/rcutorture.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit fd35be623a1534bde57029c429b206d6c22a1ef6 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Jan 11 13:13:12 2016 -0800 rcutorture: Update scripting to accommodate rcuperf This commit adds the scripting changes to add support for the shiny new rcuperf kernel module. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../rcutorture/bin/kvm-recheck-rcuperf.sh | 82 ++++++++++++++++++++++ .../selftests/rcutorture/bin/kvm-recheck.sh | 5 +- tools/testing/selftests/rcutorture/bin/kvm.sh | 2 +- .../selftests/rcutorture/configs/rcuperf/CFLIST | 1 + .../selftests/rcutorture/configs/rcuperf/CFcommon | 2 + .../selftests/rcutorture/configs/rcuperf/TREE | 19 +++++ .../rcutorture/configs/rcuperf/ver_functions.sh | 52 ++++++++++++++ 7 files changed, 161 insertions(+), 2 deletions(-) commit 5dffed1e5721f6deae4fd67d32386ef037c5fc56 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Feb 17 11:54:28 2016 -0800 rcu: Dump ftrace buffer when kicking grace-period kthread If it is necessary to kick the grace-period kthread, that is a good time to dump the trace buffer in order to learn why kicking was needed. This commit therefore does the dump. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 1 + 1 file changed, 1 insertion(+) commit 293e2421fe25839500207eda123cc4475f8d17b8 Author: Boqun Feng <boqun.feng@gmail.com> Date: Wed Mar 23 23:11:48 2016 +0800 rcu: Remove superfluous versions of rcu_read_lock_sched_held() Currently, we have four versions of rcu_read_lock_sched_held(), depending on the combined choices on PREEMPT_COUNT and DEBUG_LOCK_ALLOC. However, there is an existing function preemptible() that already distinguishes between the PREEMPT_COUNT=y and PREEMPT_COUNT=n cases, and allows these four implementations to be consolidated down to two. This commit therefore uses preemptible() to achieve this consolidation. Note that there could be a small performance regression in the case of CONFIG_DEBUG_LOCK_ALLOC=y && PREEMPT_COUNT=n. However, given the overhead associated with CONFIG_DEBUG_LOCK_ALLOC=y, this should be down in the noise. Signed-off-by: Boqun Feng <boqun.feng@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> include/linux/rcupdate.h | 17 +---------------- kernel/rcu/update.c | 4 ++-- 2 files changed, 3 insertions(+), 18 deletions(-) commit 8c7c4829a81c1838f18c12ce5a3a5c29a08bf0a8 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sun Jan 3 20:29:57 2016 -0800 rcu: Awaken grace-period kthread if too long since FQS Recent kernels can fail to awaken the grace-period kthread for quiescent-state forcing. This commit is a crude hack that does a wakeup if a scheduling-clock interrupt sees that it has been too long since force-quiescent-state (FQS) processing. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 39 +++++++++++++++++++++++++++++++++++++-- kernel/rcu/tree.h | 2 ++ 2 files changed, 39 insertions(+), 2 deletions(-) commit fcfd0a237bfcf0c314005007e9d76e55a25e2bad Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sun Jan 3 16:42:18 2016 -0800 rcu: Make FQS schedule advance only if FQS happened Currently, the force-quiescent-state (FQS) code in rcu_gp_kthread() can advance the next FQS even if one was not executed last time. This can happen due timeout-duration uncertainty. This commit therefore avoids advancing the FQS schedule unless an FQS was just executed. In the corner case where an FQS was not executed, but is due now, the code does a one-jiffy wait. This change prepares for kthread kicking. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) commit 86057b80ae31d37fcbdb5f57d15aaf1148c69f96 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Dec 31 08:48:36 2015 -0800 rcu: Awaken grace-period kthread when stalled Recent kernels can fail to awaken the grace-period kthread for quiescent-state forcing. This commit is a crude hack that does a wakeup any time a stall is detected. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 3b5f668e715bc19610ad967ef97a7e8c55a186ec Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 16 16:47:55 2016 -0700 rcu: Overlap wakeups with next expedited grace period The current expedited grace-period implementation makes subsequent grace periods wait on wakeups for the prior grace period. This does not fit the dictionary definition of "expedited", so this commit allows these two phases to overlap. Doing this requires four waitqueues rather than two because tasks can now be waiting on the previous, current, and next grace periods. The fourth waitqueue makes the bit masking work out nicely. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 17 ++++++++++++++--- kernel/rcu/tree.h | 3 ++- 2 files changed, 16 insertions(+), 4 deletions(-) commit aff12cdf86e6fa891d1c30c0fad112d138bd7b10 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 16 16:32:24 2016 -0700 rcu: Consolidate expedited GP code into exp_funnel_lock() This commit pulls the grace-period-start counter adjustment and tracing from synchronize_rcu_expedited() and synchronize_sched_expedited() into exp_funnel_lock(), thus eliminating some code duplication. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 5 ++--- kernel/rcu/tree_plugin.h | 3 --- 2 files changed, 2 insertions(+), 6 deletions(-) commit 179e5dcd1e5bdfac1128431d131b31322aedd2bc Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 16 16:27:44 2016 -0700 rcu: Consolidate expedited GP tracing into rcu_exp_gp_seq_snap() This commit moves some duplicate code from synchronize_rcu_expedited() and synchronize_sched_expedited() into rcu_exp_gp_seq_snap(). This doesn't save lines of code, but does eliminate a "tell me twice" issue. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 8 +++++--- kernel/rcu/tree_plugin.h | 2 -- 2 files changed, 5 insertions(+), 5 deletions(-) commit 4ea3e85b113ab37a2d55cfabf0d709ddec088bb3 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 16 16:22:25 2016 -0700 rcu: Consolidate expedited GP code into rcu_exp_wait_wake() Currently, synchronize_rcu_expedited() and rcu_sched_expedited() have significant duplicate code. This commit therefore consolidates some of this code into rcu_exp_wake(), which is now renamed to rcu_exp_wait_wake() in recognition of its added responsibilities. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 18 +++++++++--------- kernel/rcu/tree_plugin.h | 10 ++-------- 2 files changed, 11 insertions(+), 17 deletions(-) commit 356051e1de3cf65575da4ee92d1f5cee86677ee2 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Mar 16 13:22:53 2016 -0700 rcu: Add exp_funnel_lock() fastpath This commit speeds up the low-contention case, especially for systems with large rcu_node trees, by attempting to directly acquire the ->exp_mutex. This fastpath checks the leaves and root first in order to avoid excessive memory contention on the mutex itself. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit f6a12f34a448cc8a624070fd365c29c890138a48 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sat Jan 30 17:57:35 2016 -0800 rcu: Enforce expedited-GP fairness via funnel wait queue The current mutex-based funnel-locking approach used by expedited grace periods is subject to severe unfairness. The problem arises when a few tasks, making a path from leaves to root, all wake up before other tasks do. A new task can then follow this path all the way to the root, which needlessly delays tasks whose grace period is done, but who do not happen to acquire the lock quickly enough. This commit avoids this problem by maintaining per-rcu_node wait queues, along with a per-rcu_node counter that tracks the latest grace period sought by an earlier task to visit this node. If that grace period would satisfy the current task, instead of proceeding up the tree, it waits on the current rcu_node structure using a pair of wait queues provided for that purpose. This decouples awakening of old tasks from the arrival of new tasks. If the wakeups prove to be a bottleneck, additional kthreads can be brought to bear for that purpose. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> include/trace/events/rcu.h | 5 +- kernel/rcu/tree.c | 155 +++++++++++++++++++++++---------------------- kernel/rcu/tree.h | 10 ++- kernel/rcu/tree_plugin.h | 16 ++--- 4 files changed, 93 insertions(+), 93 deletions(-) commit d40a4f09a448382961fa9b1a2f7d4f34813f0273 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 8 14:43:44 2016 -0800 rcu: Shorten expedited_workdone* to exp_workdone* Just a name change to save a few lines and a bit of typing. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 8 +++----- kernel/rcu/tree.h | 6 +++--- kernel/rcu/tree_trace.c | 6 +++--- 3 files changed, 9 insertions(+), 11 deletions(-) commit ec3833ed02ae6ef2a933ece9de7cbab0c64c699e Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Jan 11 16:29:29 2016 -0800 rcu: Force boolean subscript for expedited stall warnings The cpu_online() function can return values other than 0 and 1, which can result in subscript overflow when applied to a two-element array. This commit allows for this behavior by using "!!" on the return value from cpu_online() when used as a subscript. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e2fd9d35847d1936398d44c4df68dceb3d7f64e7 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Sat Jan 30 17:23:19 2016 -0800 rcu: Remove expedited GP funnel-lock bypass Commit #cdacbe1f91264 ("rcu: Add fastpath bypassing funnel locking") turns out to be a pessimization at high load because it forces a tree full of tasks to wait for an expedited grace period that they probably do not need. This commit therefore removes this optimization. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/trace.txt | 10 +++++----- kernel/rcu/tree.c | 19 ------------------- kernel/rcu/tree.h | 1 - kernel/rcu/tree_trace.c | 7 +++---- 4 files changed, 8 insertions(+), 29 deletions(-) commit 4f41530245c7fd4837152e264d120d05ae940eb0 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 28 20:49:49 2016 -0800 rcu: Add expedited-grace-period event tracing Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 20 +++++++++++++------- kernel/rcu/tree_plugin.h | 3 +++ 2 files changed, 16 insertions(+), 7 deletions(-) commit bea2de44ae647698dc848a671fdee6e53c192423 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 28 20:30:06 2016 -0800 rcu: Add funnel-locking tracing for expedited grace periods Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 31 +++++++++++++++++++++++++++---- kernel/rcu/tree_plugin.h | 3 +++ 2 files changed, 30 insertions(+), 4 deletions(-) commit e087816db9423fdc49302d3cd7ec01e487477a71 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 28 20:25:09 2016 -0800 rcu: Add event tracing definitions for expedited grace periods Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> include/trace/events/rcu.h | 78 ++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 76 insertions(+), 2 deletions(-) commit 26ece8ef6eca97f19eb5ad5186b8c1a29ab25d76 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 28 18:48:37 2016 -0800 rcu: Fix synchronize_rcu_expedited() header comment This commit brings the synchronize_rcu_expedited() function's header comment into line with the new implementation. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree_plugin.h | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) commit a1e1224849d9610b50fd1dd7d6f44308a59e46af Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Jan 13 13:57:54 2016 -0800 rcu: Make cond_resched_rcu_qs() supply RCU-sched expedited QS Although cond_resched_rcu_qs() supplies quiescent states to all flavors of normal RCU grace periods, it does nothing for expedited RCU-sched grace periods. This commit therefore adds a check for a need for a quiescent state from the current CPU by an expedited RCU-sched grace period, and invokes rcu_sched_qs() to supply that quiescent state if so. Note that the check is racy in that we might be migrated to some other CPU just after checking the per-CPU variable. This is OK because the act of migration will do a context switch, which will supply the needed quiescent state. The only downside is that we might do an unnecessary call to rcu_sched_qs(), but the probability is low and the overhead is small. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) commit 251c617c75f48e03523c43c4ce1dff44bc3ae2bd Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Wed Jan 13 10:52:35 2016 -0800 rcu: Make expedited RCU-preempt stall warnings count accurately Currently, synchronize_sched_expedited_wait() simply sets the ndetected variable to the rcu_print_task_exp_stall() return value. This means that if the last rcu_node structure has no stalled tasks, record of any stalled tasks in previous rcu_node structures is lost, which can in turn result in failure to dump out the blocking rcu_node structures. Or could, had the test been correct. This commit therefore adds the return value of rcu_print_task_exp_stall() to ndetected and corrects the later test for ndetected. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 28728dd310d48834cd486dac3cac9ae96b9deb96 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Jan 12 08:33:37 2016 -0800 rcu: Make expedited RCU-sched grace period immediately detect idle Currently, sync_sched_exp_handler() will force a reschedule unless this CPU has already checked in or unless a reschedule has already been called for. This is clearly wasteful if sync_sched_exp_handler() interrupted an idle CPU, so this commit immediately reports the quiescent state in that case. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> kernel/rcu/tree.c | 5 +++++ 1 file changed, 5 insertions(+) commit 0c7d10e4b998b2f751cebf98435f1ec2dd312c87 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Mar 31 11:00:08 2016 -0700 documentation: Emphasize the call_rcu() is illegal from idle Although call_rcu()'s fastpath works just fine on an idle CPU, some branches of the slowpath invoke the scheduler, which uses RCU. Therefore, this commit emphasizes the fact that call_rcu() must not be invoked from an idle CPU. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/Design/Requirements/Requirements.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5413e24c943da33306047fc091fa34fa4f261b3b Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 15 13:40:28 2016 -0700 documentation: Sharpen up the no-readers quick quiz Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/Design/Requirements/Requirements.html | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) commit 6146f8df48cb52c46c256424bd03b567b889b7bb Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 15 13:25:20 2016 -0700 documentation: Get rid of duplicate .htmlx file This commit uses colors to obscure the quick-quiz answers, thus getting rid of the .htmlx file. Use your mouse to select the answer in order to see the text. Alternatively, use your favorite scripting language to remove all occurences of "<font color="ffffff">" from the file. Reported-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../RCU/Design/Requirements/Requirements.html | 889 +++--- .../RCU/Design/Requirements/Requirements.htmlx | 2872 -------------------- Documentation/RCU/Design/htmlqqz.sh | 108 - 3 files changed, 428 insertions(+), 3441 deletions(-) commit 11a65df5732167519937eabf16a870f5f8bde5ee Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Tue Mar 15 11:03:36 2016 -0700 documentation: Remove unnecessary images from requirements This commit removes a cutesy cartoon and also a diagram that can just as easily be represented by text. Reported-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../RCU/Design/Requirements/2013-08-is-it-dead.png | Bin 100825 -> 0 bytes .../RCU/Design/Requirements/RCUApplicability.svg | 237 --------------------- .../RCU/Design/Requirements/Requirements.html | 28 ++- .../RCU/Design/Requirements/Requirements.htmlx | 28 ++- 4 files changed, 40 insertions(+), 253 deletions(-) commit 514f1eb5f44520d5255b927ad5aabc00db5bc73d Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Feb 15 16:52:35 2016 -0800 documentation: Document illegality of call_rcu() from offline CPUs There is already a blanket statement about no member of RCU's API being legal from an offline CPU, but add an explicit note where it states that it is illegal to invoke call_rcu() from an NMI handler. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/Design/Requirements/Requirements.html | 3 ++- Documentation/RCU/Design/Requirements/Requirements.htmlx | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit d8936c0b7e29510ce8f5c85ff5fcc592a938e860 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Feb 15 17:29:47 2016 -0800 documentation: Explain why rcu_read_lock() needs no barrier() This commit adds a Quick Quiz whose answer explains why the compiler code reordering enabled by CONFIG_PREEMPT=n's empty rcu_read_lock() and rcu_read_unlock() functions does not hinder RCU's ability to figure out which RCU read-side critical sections have completed and not. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../RCU/Design/Requirements/Requirements.html | 130 ++++++++++++++------- .../RCU/Design/Requirements/Requirements.htmlx | 28 +++++ 2 files changed, 115 insertions(+), 43 deletions(-) commit f43b62542eb61a52d97d6b82a786a912fa5e6c51 Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Thu Jan 7 09:12:43 2016 -0800 documentation: Add synchronize_rcu_mult() to the requirements Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> .../RCU/Design/Requirements/Requirements.html | 92 ++++++++++++++++++++++ .../RCU/Design/Requirements/Requirements.htmlx | 82 +++++++++++++++++++ 2 files changed, 174 insertions(+) commit 41abcf321d447b9987f6b7d1a9bb65831e786daf Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Fri Dec 11 16:18:22 2015 -0800 documentation: Add real-time requirements from CPU-bound workloads This commit records RCU's responsibility to avoid degrading latencies of CPUs running tight loops within properly configured workloads, both in kernel and in userspace. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/Design/Requirements/Requirements.html | 10 +++++++++- Documentation/RCU/Design/Requirements/Requirements.htmlx | 8 ++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) commit 70946a44deec299ef54c0ec933e8d82ddd4bcc6a Author: Yao Dongdong <yaodongdong@huawei.com> Date: Mon Mar 7 16:02:14 2016 +0800 documentation: Make sample code and documentation consistent In the chapter 'analogy with reader-writer locking', the sample code uses spinlock_t in reader-writer case. Just correct it so that we can read the document easily. Signed-off-by: Yao Dongdong <yaodongdong@huawei.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Documentation/RCU/whatisRCU.txt | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) commit 274529ba9bda86c91c2c06da3a641aaf617dd30f Author: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Date: Mon Mar 21 19:46:04 2016 -0700 rcu: Consolidate dumping of ftrace buffer This commit consolidates a couple definitions and several calls for single-shot ftrace-buffer dumping. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> include/linux/rcupdate.h | 13 +++++++++++++ kernel/rcu/rcutorture.c | 17 +++-------------- kernel/rcu/tree.c | 4 ++-- 3 files changed, 18 insertions(+), 16 deletions(-) commit 7d8d86252307ce34925c5ddec4ef1b32670353b9 Author: Andreas Färber <afaerber@suse.de> Date: Thu Mar 31 13:08:06 2016 -0700 Input: gpio-keys - clean up device tree binding example Drop #address-cells and #size-cells, which are not required by the gpio-keys binding documentation, as button sub-nodes are not devices. Rename sub-nodes to avoid new dtc unit address warnings when copied. While at it, adopt the dashes convention for the node name. Reported-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Documentation/devicetree/bindings/input/gpio-keys.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 8f7292ed88c0a87e4173c5a97fae444ed8b2f05b Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 31 11:01:48 2016 -0700 Input: kbtab - stop saving struct usb_device The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/tablet/kbtab.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit ed752e5ddedb68c9d69484baa1a712cf966e1f22 Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 31 11:01:07 2016 -0700 Input: gtco - stop saving struct usb_device The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/tablet/gtco.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) commit c630901860c3b8ecc22097269fd4605cf584126c Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 31 10:59:59 2016 -0700 Input: aiptek - stop saving struct usb_device The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum <oneukum@suse.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/tablet/aiptek.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) commit 7edf2c9c08dccbad9134b89c2252594d9659b59e Author: Oliver Neukum <oneukum@suse.com> Date: Thu Mar 31 10:59:41 2016 -0700 Input: acecad - stop saving struct usb_device The device can now easily be derived from the interface. Stop leaving a private copy. Signed-off-by: Oliver Neukum <ONeukum@suse.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> drivers/input/tablet/acecad.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 56d118c243fbc62d95a79183bb6bcfc38a398da5 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Thu Mar 31 17:03:59 2016 +0900 staging: dgnc: clean up dgnc_input function This is for fixing checkpatch.pl warning about "Alignment should match open parenthesis" but if that is fixed, code line is over 80 characters. I think "ch->ch_rqueue + tail + i" could be declared once in the begining of loop. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_tty.c | 35 ++++++++++++++--------------------- 1 file changed, 14 insertions(+), 21 deletions(-) commit e491e716dc6a8f43cec7353e5a89e19058f3a48a Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Thu Mar 31 17:03:35 2016 +0900 staging: dgnc: remove useless variables for saving tty's It doesn't need to save major number with variable. And there are no use of these variables(dgnc_serial_major and dgnc_transparent_print_major) Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.h | 3 --- drivers/staging/dgnc/dgnc_tty.c | 4 ---- 2 files changed, 7 deletions(-) commit 1f2f03c201d4df0035268f8cbecb31bf58f59355 Author: Tim Sell <Timothy.Sell@unisys.com> Date: Wed Mar 30 23:06:08 2016 -0400 staging: unisys: visorbus: remove unnecessary poll_count logic The use of poll_count is a vestige from long-ago testing, which is no longer needed. It is removed by this patch. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 7 ------- 1 file changed, 7 deletions(-) commit 899e1a31ffc0cf01b1ca7512e079721b79803929 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:40 2016 -0400 staging: lustre: libcfs: delete linux-mem.h The header linux-mem.h is no longer needed. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13841 Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/linux/libcfs.h | 2 +- .../lustre/include/linux/libcfs/linux/linux-cpu.h | 2 +- .../lustre/include/linux/libcfs/linux/linux-mem.h | 60 ---------------------- 3 files changed, 2 insertions(+), 62 deletions(-) commit 5c89dc06eb45bebe4dcc59205ac0ed3fe3c44c34 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:39 2016 -0400 staging: lustre: libcfs: move NUM_CACHEPAGES to libcfs_prim.h We don't really need linux specific headers anymore so move NUM_CACHEPAGES macro to libcfs_prim.h. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13841 Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_prim.h | 8 ++++++++ drivers/staging/lustre/include/linux/libcfs/linux/linux-mem.h | 8 -------- 2 files changed, 8 insertions(+), 8 deletions(-) commit e3e30e10c5d72844f020fe42e62066e9fd1b051c Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:38 2016 -0400 staging: lustre: libcfs: remove MMSPACE macros Another abstraction that is not needed. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13841 Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/linux/linux-mem.h | 5 ----- drivers/staging/lustre/lnet/libcfs/tracefile.c | 17 ++++++++--------- 2 files changed, 8 insertions(+), 14 deletions(-) commit badc9feddfd30096666e22afbda028971a49bfa9 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:37 2016 -0400 staging: lustre: libcfs: remove page_index() macro Just use the index field directly for struct page. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13841 Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/linux/linux-mem.h | 2 -- drivers/staging/lustre/lustre/llite/vvp_page.c | 2 +- drivers/staging/lustre/lustre/osc/osc_request.c | 2 +- 3 files changed, 2 insertions(+), 4 deletions(-) commit bd6e2c5067ad6ead097ada26e899ba97266a8bf0 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:36 2016 -0400 staging: lustre: libcfs: move memory_pressure functions to libcfs_prim.h Long ago libcfs_prim.h was used for userland code which is why memory_pressure_*() handling is in both libcfs_prim.h and linux-mem.h headers. So lets just move the memory_pressure_*() to libcfs_prim.h. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13841 Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_prim.h | 23 +++++++++++++--------- .../lustre/include/linux/libcfs/linux/linux-mem.h | 4 ---- 2 files changed, 14 insertions(+), 13 deletions(-) commit 564f5d6e92d16ad893b4b5bad520bba6a3008b09 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 31 10:18:35 2016 -0400 staging: lustre: libcfs: move add_wait_queue_exclusive_head to lustre layer Only lustre client uses add_wait_queue_exclusive_head() so move it from libcfs layer to lustre_lib.h where it is needed. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13874 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_prim.h | 2 -- .../staging/lustre/lnet/libcfs/linux/linux-prim.c | 24 ---------------------- drivers/staging/lustre/lustre/include/lustre_lib.h | 22 ++++++++++++++++++++ 3 files changed, 22 insertions(+), 26 deletions(-) commit cef794f76485f4a4e6affd851ae9f9d0eb4287a5 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Mar 31 19:23:15 2016 +0100 ASoC: qcom: remove IS_ERR_VALUE usage on int. IS_ERR_VALUE should be used only with unsigned long type, signed types should use comparison 'ret < 0' This patch removes such usages. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/qcom/lpass-platform.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit ea4d25d5a3709cba0d3df2195edffc400170394f Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Mar 31 19:23:14 2016 +0100 ASoC: qcom: Fix uninitialized symbol warning. This patch fixes following static checker warning, by initializing the ret to -EINVAL, as one of the code path in lpass_platform_pcm_new() uses this variable uninitialized. sound/soc/qcom/lpass-platform.c:555 lpass_platform_pcm_new() error: uninitialized symbol 'ret'. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/qcom/lpass-platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1b5b19689278069844f0f65bba8ea55facad90f9 Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Wed Mar 30 18:57:50 2016 -0700 regulator: qcom_spmi: Only use selector based regulator ops Mixing raw voltage and selector based regulator ops is inconsistent. This driver already supports some selector based ops via the list_voltage and set_voltage_time_sel ops but it uses raw voltage ops for get_voltage and set_voltage. This causes problems for regulator_set_voltage() and automatic insertion of slewing delays because set_voltage_time_sel() is only used if the regulator ops are all selector based. Put another way, delays aren't happening at all right now when we should be waiting for voltages to settle. Let's move to pure selector based regulator ops so that the delays are inserted properly. Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/qcom_spmi-regulator.c | 189 +++++++++++++++++++------------- 1 file changed, 113 insertions(+), 76 deletions(-) commit 2cf7b99cf74b435f27e48aa2829300c4d0aa65a0 Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Wed Mar 30 18:57:49 2016 -0700 regulator: qcom_spmi: Add slewing delays for all SMPS types Only the FT SMPS type regulators have slewing supported in the driver, but all types of SMPS regulators need the same support. The only difference is that some SMPS regulators don't have a step size and the step delay is typically 20, not 8. Luckily, the step size reads as 0 for the non-FT types, so we can always read that, but we need to detect which type of regulator we're using to figure out what step delay to use. Make these minor adjustments to the slew rate calculations and add support for the delay function to the appropriate regulator ops. Reported-by: Georgi Djakov <georgi.djakov@linaro.org> Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/qcom_spmi-regulator.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) commit a42121b7a1d80a0eaac9ed1442760bf4e65f5352 Author: Petr Kulhavy <petr@barix.com> Date: Thu Mar 31 18:41:27 2016 +0200 ASoC: tas571x: new chip added into TAS571x binding This adds the TAS5721 into the TAS571x binding. Signed-off-by: Petr Kulhavy <petr@barix.com> Reviewed-by: Kevin Cernekee <cernekee@chromium.org> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org> Documentation/devicetree/bindings/sound/tas571x.txt | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 23a282c4f088efb337957ffa21c677d30eda0784 Author: Petr Kulhavy <petr@barix.com> Date: Thu Mar 31 18:41:26 2016 +0200 ASoC: tas571x: added support for TAS5721 This adds support for TAS5721. Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 2 +- sound/soc/codecs/tas571x.c | 76 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 77 insertions(+), 1 deletion(-) commit a593ed09040fa611f37953afe455e64c7653160d Author: Petr Kulhavy <petr@barix.com> Date: Thu Mar 31 18:41:25 2016 +0200 ASoC: tas571x: added missing register literals The list of TAS571x registers was incomplete. Added the missing register definitions up to the register 0x25. Added volatile and read-only register tables into tas5711_regmap_config and tas5717_regmap_config. The chip has 256 registers in total. But from address 0x29 on (0x26 to 0x28 are reserved) the register width varies between 20, 12 and 8 bytes, which the register map cannot represent. Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tas571x.c | 28 ++++++++++++++++++++++++++++ sound/soc/codecs/tas571x.h | 22 ++++++++++++++++++++++ 2 files changed, 50 insertions(+) commit 40ac568d0ef07b60ba8cc0f2e88ccdd4dd0e176a Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 16 14:58:41 2016 +0100 Documentation: devicetree: rockchip: Document rk3368-GeekBox Use "geekbuying,geekbox" compatible string. Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Documentation/devicetree/bindings/arm/rockchip.txt | 4 ++++ 1 file changed, 4 insertions(+) commit fd7b980c9e1e52d41589c41ae166b0cfae32b210 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 16 14:58:42 2016 +0100 arm64: dts: rockchip: Add rk3368 GeekBox dts The GeekBox contains an MXM3 module with a Rockchip RK3368 SoC. Some connectors are available directly on the module. This adds initial support, namely serial, USB, GMAC, eMMC, IR and TSADC. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/Makefile | 1 + arch/arm64/boot/dts/rockchip/rk3368-geekbox.dts | 319 ++++++++++++++++++++++++ 2 files changed, 320 insertions(+) commit bc553986a2f7c56d0de811485d5312ea29692d5d Author: Rob Herring <robh@kernel.org> Date: Thu Mar 24 10:52:42 2016 -0500 dtc: turn off dtc unit address warnings by default The newly added dtc warning to check DT unit-address without reg property and vice-versa generates lots of warnings. Turn off the check unless building with W=1 or W=2. Signed-off-by: Rob Herring <robh@kernel.org> Cc: Michal Marek <mmarek@suse.com> Cc: linux-kbuild@vger.kernel.org scripts/Makefile.lib | 5 +++++ 1 file changed, 5 insertions(+) commit 72e96d6450c067f58b65224bb5e73914e2cc43ab Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Wed Mar 30 16:57:10 2016 +0300 drm/i915: Refer to GGTT {,VM} consistently Refer to the GGTT VM consistently as "ggtt->base" instead of just "ggtt", "vm" or indirectly through other variables like "dev_priv->ggtt.base" to avoid confusion with the i915_ggtt object itself and PPGTT VMs. Refer to the GGTT as "ggtt" instead of indirectly through chaining. As a bonus gets rid of the long-standing i915_obj_to_ggtt vs. i915_gem_obj_to_ggtt conflict, due to removal of i915_obj_to_ggtt! v2: - Added some more after grepping sources with Chris v3: - Refer to GGTT VM through ggtt->base consistently instead of ggtt_vm (Chris) v4: - Convert all dev_priv->ggtt->foo accesses to ggtt->foo. v5: - Make patch checker happy Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 19 ++-- drivers/gpu/drm/i915/i915_dma.c | 21 ++-- drivers/gpu/drm/i915/i915_drv.h | 13 ++- drivers/gpu/drm/i915/i915_gem.c | 50 ++++++--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 12 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 170 +++++++++++++++-------------- drivers/gpu/drm/i915/i915_gem_gtt.h | 2 +- drivers/gpu/drm/i915/i915_gem_stolen.c | 98 +++++++++-------- drivers/gpu/drm/i915/i915_gpu_error.c | 12 +- drivers/gpu/drm/i915/i915_vgpu.c | 36 +++--- drivers/gpu/drm/i915/intel_display.c | 8 +- drivers/gpu/drm/i915/intel_fbc.c | 5 +- drivers/gpu/drm/i915/intel_fbdev.c | 10 +- drivers/gpu/drm/i915/intel_overlay.c | 10 +- drivers/gpu/drm/i915/intel_pm.c | 13 ++- drivers/gpu/drm/i915/intel_ringbuffer.c | 3 +- 16 files changed, 264 insertions(+), 218 deletions(-) commit 46bc29b970f0011a9099077f1db8f3540aa829fe Author: Adrian Hunter <adrian.hunter@intel.com> Date: Tue Mar 8 10:38:44 2016 +0200 perf tools: Add time conversion event Intel PT uses the time members from the perf_event_mmap_page to convert between TSC and perf time. Due to a lack of foresight when Intel PT was implemented, those time members were recorded in the (implementation dependent) AUXTRACE_INFO event, the structure of which is generally inaccessible outside of the Intel PT decoder. However now the conversion between TSC and perf time is needed when processing a jitdump file when Intel PT has been used for tracing. So add a user event to record the time members. 'perf record' will synthesize the event if the information is available. And session processing will put a copy of the event on the session so that tools like 'perf inject' can easily access it. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1457426324-30158-1-git-send-email-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/arch/x86/util/tsc.c | 31 +++++++++++++++++++++++++++++++ tools/perf/builtin-inject.c | 1 + tools/perf/builtin-record.c | 15 +++++++++++++++ tools/perf/util/event.c | 1 + tools/perf/util/event.h | 9 +++++++++ tools/perf/util/session.c | 6 ++++++ tools/perf/util/session.h | 1 + tools/perf/util/tool.h | 1 + tools/perf/util/tsc.h | 10 ++++++++++ 9 files changed, 75 insertions(+) commit 39878d492c049796202b70dc0ef14449cafa3cb4 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Mar 30 20:02:15 2016 -0300 perf trace: Pretty print getrandom() args # trace -e getrandom 35622.560 ( 0.023 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35622.585 ( 0.006 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35622.594 ( 0.004 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35627.395 ( 0.010 ms): libvirtd/1353 getrandom(buf: 0x7f7a1bfa35c0, count: 16, flags: NONBLOCK ) = 16 35630.940 ( 0.013 ms): fwupd/16120 getrandom(buf: 0x7f63243aa5c0, count: 16, flags: NONBLOCK ) = 16 35718.613 ( 0.015 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35718.629 ( 0.005 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35718.637 ( 0.004 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 35719.355 ( 0.010 ms): libvirtd/1353 getrandom(buf: 0x7f7a1bfa35c0, count: 16, flags: NONBLOCK ) = 16 35721.042 ( 0.030 ms): fwupd/16120 getrandom(buf: 0x7f63243aa5c0, count: 16, flags: NONBLOCK ) = 16 41090.830 ( 0.012 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41090.845 ( 0.004 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41090.851 ( 0.004 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41091.750 ( 0.010 ms): libvirtd/1353 getrandom(buf: 0x7f7a1bfa35c0, count: 16, flags: NONBLOCK ) = 16 41091.823 ( 0.006 ms): fwupd/16120 getrandom(buf: 0x7f63243aa5c0, count: 16, flags: NONBLOCK ) = 16 41122.078 ( 0.053 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41122.129 ( 0.009 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41122.139 ( 0.004 ms): systemd-udevd/631 getrandom(buf: 0x55621e3c18f0, count: 16, flags: NONBLOCK) = 16 41124.492 ( 0.007 ms): libvirtd/1353 getrandom(buf: 0x7f7a1bfa35c0, count: 16, flags: NONBLOCK ) = 16 41124.470 ( 0.013 ms): fwupd/16120 getrandom(buf: 0x7f63243aa5c0, count: 16, flags: NONBLOCK ) = 16 41590.832 ( 0.014 ms): chrome/5957 getrandom(buf: 0x7fabac7b15b0, count: 16, flags: NONBLOCK ) = 16 41590.884 ( 0.004 ms): chrome/5957 getrandom(buf: 0x7fabac7b15c0, count: 16, flags: NONBLOCK ) = 16 Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-gca0n1p3aca3depey703ph2q@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit 997bba8cf1875d9715e792c445e1a9c7a4c365e2 Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Mar 30 19:43:32 2016 -0300 perf trace: Pretty print seccomp() args E.g: # trace -e seccomp 200.061 (0.009 ms): :2441/2441 seccomp(op: FILTER, flags: TSYNC ) = -1 EFAULT Bad address 200.910 (0.121 ms): :2441/2441 seccomp(op: FILTER, flags: TSYNC, uargs: 0x7fff57479fe0) = 0 Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Milian Wolff <milian.wolff@kdab.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-t369uckshlwp4evkks4bcoo7@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 47 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) commit 3ed5ca2efff70e9f589087c2013789572901112d Author: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Wed Mar 30 16:51:17 2016 -0300 perf trace: Do not process PERF_RECORD_LOST twice We catch this record to provide a visual indication that events are getting lost, then call the default method to allow extra logging shared with the other tools to take place. This extra logging was done twice because we were continuing to the "default" clause where machine__process_event() will end up calling machine__process_lost_event() again, fix it. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-wus2zlhw3qo24ye84ewu4aqw@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/builtin-trace.c | 1 + 1 file changed, 1 insertion(+) commit 86c8dd7f4da3fb3f92fc5ab5144c971639d39745 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:08 2016 +0900 ALSA: firewire-digi00x: delayed registration of sound card When some digi00x units are connected sequentially, userspace applications are involved at bus-reset state on IEEE 1394 bus. In the state, any communications can be canceled. Therefore, sound card registration should be delayed till the bus gets calm. This commit achieves it. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/digi00x/digi00x-transaction.c | 7 +- sound/firewire/digi00x/digi00x.c | 107 +++++++++++++++++++-------- sound/firewire/digi00x/digi00x.h | 3 + 3 files changed, 85 insertions(+), 32 deletions(-) commit 6c29230e2a5ff84df2b1358681414bad3e4bd220 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:07 2016 +0900 ALSA: oxfw: delayed registration of sound card Some oxfw based units tends to fail asynchronous communication when IEEE 1394 bus is under bus-reset state. When registering sound card instance at unit probe callback, userspace applications can be involved to the state. This commit postpones the registration till the bus is calm. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/oxfw/oxfw.c | 151 +++++++++++++++++++++++++++++---------------- sound/firewire/oxfw/oxfw.h | 3 + 2 files changed, 101 insertions(+), 53 deletions(-) commit 7d3c1d5901aac873d13c0a03b29ee2bda183383f Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:06 2016 +0900 ALSA: fireworks: delayed registration of sound card When some fireworks units are connected sequentially, userspace applications are involved at bus-reset state on IEEE 1394 bus. In the state, any communications can be canceled. Therefore, sound card registration should be delayed till the bus gets calm. This commit achieves it. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/fireworks/fireworks.c | 147 ++++++++++++++++++++++++----------- sound/firewire/fireworks/fireworks.h | 3 + 2 files changed, 103 insertions(+), 47 deletions(-) commit 04a2c73c97ebb224dfb411ab35bb18d7b8245e39 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:05 2016 +0900 ALSA: bebob: delayed registration of sound card Some bebob based units tends to fail asynchronous communication when IEEE 1394 bus is under bus-reset state. When registering sound card instance at unit probe callback, userspace applications can be involved to the state. This commit postpones the registration till the bus is calm. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/bebob/bebob.c | 215 +++++++++++++++++++++++++------------------ sound/firewire/bebob/bebob.h | 5 +- 2 files changed, 131 insertions(+), 89 deletions(-) commit 923f92ebb43e7a09915a5708d4805c1e099db46c Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:04 2016 +0900 ALSA: firewire-lib: add new function to schedule a work for sound card registration In former commit, ALSA dice driver postpone sound card registration after IEEE 1394 bus is calm. This idea has advantages for the other drivers. This commit adds a helper function for it to firewire-lib module. The function is really for the specific purpose. Callers should initialize delayed work structure with callback function. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/dice/dice.c | 23 +++-------------------- sound/firewire/lib.c | 32 ++++++++++++++++++++++++++++++++ sound/firewire/lib.h | 3 +++ 3 files changed, 38 insertions(+), 20 deletions(-) commit 0eced45ca60666aff4c12f31fef4005ae37e859e Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:03 2016 +0900 ALSA: dice: simplify unit probe processing In former commit, ALSA dice driver doesn't generate kernel warnings when unplugging units before initializing stream data. This commit moves the initialization to delayed registration of sound card, to simplify unit probe processing. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/dice/dice.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) commit 44c376b9596ca00d1bdee37e716d1bd4dd36c955 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Thu Mar 31 08:47:02 2016 +0900 ALSA: firewire-lib: suppress kernel warnings when releasing uninitialized stream data When any of AMDTP stream data are not initialized and private data is going to be released, WARN_ON() in amdtp_stream_destroy() is hit and dump messages. This may take users irritated. This commit fixes the bug to skip releasing when it's not initialized. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/amdtp-stream.c | 4 ++++ 1 file changed, 4 insertions(+) commit e787bc463cc1fe3f51b0cd7bf540236318f69cf1 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Thu Mar 31 16:30:15 2016 +0300 MAINTAINERS: Add a git tree for the stm class So that people know where their patches go. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 8fad7ec51e1b9e262e0bdd34e800ac1ea5e84dec Author: Rasmus Villemoes <linux@rasmusvillemoes.dk> Date: Sat Mar 26 21:40:16 2016 +0100 x86/dumpstack: Combine some printk()s Long ago, Jiri Slaby noted that the subsequent printk()s should be pr_cont(). Let's instead get rid of the multiple printk calls. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459024817-27122-1-git-send-email-linux@rasmusvillemoes.dk Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/dumpstack.c | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) commit 6e66a6599a813abfc9ebe2e295c9d557c434812a Author: Axel Lin <axel.lin@ingics.com> Date: Wed Mar 23 19:49:41 2016 +0800 gpio: tpic2810: Make sure cached buffer has consistent status with h/w status i2c_smbus_write_byte_data() can fail. To ensure the cached buffer has consistent status with h/w status, don't update the cached gpio->buffer if write fails. Also refactor the code a bit by adding a tpic2810_set_mask_bits() helper and use it to simplify the code. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-tpic2810.c | 35 +++++++++++++++-------------------- 1 file changed, 15 insertions(+), 20 deletions(-) commit 18fb0a981e18b91c6eb1a00f8b06f2fb5be2e9aa Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:49 2016 -0400 gpio: zx: make explicitly non-modular The Kconfig currently controlling compilation of this code is: config GPIO_ZX bool "ZTE ZX GPIO support" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Jun Nie <jun.nie@linaro.org> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-zx.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit b33d12d3d72df3272c9c017cd93577ba1c9b24bb Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:48 2016 -0400 gpio: xgene: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_XGENE drivers/gpio/Kconfig: bool "APM X-Gene GPIO controller support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Feng Kan <fkan@apm.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-xgene.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) commit 3c90c6d60b4184cd08bc2b8c1db0b507c3a1c84e Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:47 2016 -0400 gpio: sta2x11: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_STA2X11 drivers/gpio/Kconfig: bool "STA2x11/ConneXt GPIO support" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity, so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-sta2x11.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit ef3e7100e06a8788d89555e0a4926ab85f689583 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:46 2016 -0400 gpio: pl061: make explicitly non-modular The Kconfig for this driver is currently: config GPIO_PL061 bool "PrimeCell PL061 GPIO support" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Acked-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-pl061.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit ed329f3a6483ad4825be2f731aa08b34731ecfcb Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:45 2016 -0400 gpio: mvebu: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_MVEBU drivers/gpio/Kconfig: def_bool y ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mvebu.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 4bb9f7251cf2c922e46a9059dc4d70028469275a Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:44 2016 -0400 gpio: moxart: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_MOXART drivers/gpio/Kconfig: bool "MOXART GPIO support" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modular references so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. We don't replace module.h with init.h since the file already has that. Cc: Jonas Jensen <jonas.jensen@gmail.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-moxart.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 0de6a80de1425905f9fe8f3df8c455ec56250107 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:43 2016 -0400 gpio: mc9s08dz60: make explicitly non-modular The Kconfig currently controlling compilation of this code is: drivers/gpio/Kconfig:config GPIO_MC9S08DZ60 drivers/gpio/Kconfig: bool "MX35 3DS BOARD MC9S08DZ60 GPIO functions" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_i2c_driver() uses the same init level priority as builtin_i2c_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Wu Guoxing <b39297@freescale.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mc9s08dz60.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit d5610e514e92144d19bd5e39e5cf3804bbf85f3e Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:42 2016 -0400 gpio: mb86s7x: make explicitly non-modular The Kconfig for this driver is currently: config GPIO_MB86S7X bool "GPIO support for Fujitsu MB86S7x Platforms" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mb86s7x.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) commit 16bf92261b1b6cb1a1c0671b445a2fcb5a1ecc96 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:42:03 2016 +0200 x86/cpufeature: Remove cpu_has_pse Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459266123-21878-11-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/pgtable.h | 2 +- arch/x86/mm/init.c | 4 ++-- arch/x86/mm/init_32.c | 2 +- arch/x86/mm/init_64.c | 4 ++-- arch/x86/mm/ioremap.c | 2 +- arch/x86/power/hibernate_32.c | 2 +- arch/x86/xen/enlighten.c | 2 +- 8 files changed, 9 insertions(+), 10 deletions(-) commit c109bf95992b391bb40bc37c5d309d13fead99b5 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:42:02 2016 +0200 x86/cpufeature: Remove cpu_has_pge Use static_cpu_has() in __flush_tlb_all() due to the time-sensitivity of this one. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459266123-21878-10-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/tlbflush.h | 2 +- arch/x86/kernel/cpu/intel.c | 6 +++--- arch/x86/kernel/cpu/mtrr/cyrix.c | 4 ++-- arch/x86/kernel/cpu/mtrr/generic.c | 4 ++-- arch/x86/mm/init.c | 2 +- arch/x86/xen/enlighten.c | 2 +- drivers/lguest/x86/core.c | 2 +- 8 files changed, 11 insertions(+), 12 deletions(-) commit 054efb6467f84490bdf92afab6d9dbd5102e620a Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:42:00 2016 +0200 x86/cpufeature: Remove cpu_has_xmm2 Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-crypto@vger.kernel.org Link: http://lkml.kernel.org/r/1459266123-21878-8-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/poly1305_glue.c | 2 +- arch/x86/crypto/serpent_sse2_glue.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/cpu/amd.c | 2 +- arch/x86/kernel/cpu/intel.c | 2 +- arch/x86/lib/usercopy_32.c | 4 ++-- 6 files changed, 6 insertions(+), 7 deletions(-) commit 906bf7fda2c9cf5c1762ec607943ed54b6c5b203 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:59 2016 +0200 x86/cpufeature: Remove cpu_has_clflush Use the fast variant in the DRM code. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: dri-devel@lists.freedesktop.org Cc: intel-gfx@lists.freedesktop.org Link: http://lkml.kernel.org/r/1459266123-21878-7-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/cpu/intel.c | 2 +- arch/x86/kernel/tce_64.c | 2 +- arch/x86/mm/pageattr.c | 2 +- drivers/gpu/drm/drm_cache.c | 6 +++--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 2 +- 6 files changed, 7 insertions(+), 8 deletions(-) commit b8291adc191abec2095f03a130ac91506d345cae Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:58 2016 +0200 x86/cpufeature: Remove cpu_has_gbpages Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459266123-21878-6-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kvm/mmu.c | 3 ++- arch/x86/mm/hugetlbpage.c | 4 ++-- arch/x86/mm/init.c | 2 +- arch/x86/mm/ioremap.c | 2 +- arch/x86/mm/pageattr.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) commit 62436a4d36c94d202784cd8a997ff8bb4b880237 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:57 2016 +0200 x86/cpufeature: Remove cpu_has_x2apic Signed-off-by: Borislav Petkov <bp@suse.de> Acked-by: Tony Luck <tony.luck@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459266123-21878-5-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/ia64/include/asm/iommu.h | 1 - arch/x86/include/asm/apic.h | 4 ++-- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/apic/apic.c | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) commit ab4a56fa2c6ce9384ca077b6570c56fe18361f17 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:56 2016 +0200 x86/cpufeature: Remove cpu_has_osxsave Use boot_cpu_has() instead. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-crypto@vger.kernel.org Link: http://lkml.kernel.org/r/1459266123-21878-4-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/crypto/camellia_aesni_avx2_glue.c | 3 ++- arch/x86/crypto/camellia_aesni_avx_glue.c | 2 +- arch/x86/crypto/serpent_avx2_glue.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/include/asm/xor_avx.h | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) commit 0c9f3536cc712dfd5ec3127d55cd7b807cc0adb5 Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:55 2016 +0200 x86/cpufeature: Remove cpu_has_hypervisor Use boot_cpu_has() instead. Tested-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: sparmaintainer@unisys.com Cc: virtualization@lists.linux-foundation.org Link: http://lkml.kernel.org/r/1459266123-21878-3-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/uncore.c | 2 +- arch/x86/include/asm/cpufeature.h | 1 - arch/x86/kernel/cpu/vmware.c | 2 +- arch/x86/kernel/kvm.c | 2 +- drivers/staging/unisys/visorbus/visorchipset.c | 2 +- 5 files changed, 4 insertions(+), 5 deletions(-) commit 7b5e74e637e4a977c7cf40fd7de332f60b68180e Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:41:54 2016 +0200 x86/cpufeature: Remove cpu_has_arch_perfmon Use boot_cpu_has() instead. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: oprofile-list@lists.sf.net Link: http://lkml.kernel.org/r/1459266123-21878-2-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - arch/x86/oprofile/nmi_int.c | 4 ++-- arch/x86/oprofile/op_model_ppro.c | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) commit 568a58e5dfbcb88011cad7f87ed046aa00f19d1a Author: Borislav Petkov <bp@suse.de> Date: Tue Mar 29 17:42:01 2016 +0200 x86/mm/pat, x86/cpufeature: Remove cpu_has_pat Signed-off-by: Borislav Petkov <bp@suse.de> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: intel-gfx@lists.freedesktop.org Link: http://lkml.kernel.org/r/1459266123-21878-9-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/cpufeature.h | 1 - drivers/gpu/drm/i915/i915_gem.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) commit 20a34e78f0d71cab058a943b2e9601b97b761227 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 30 17:16:36 2016 +0200 drm/i915: Update color management during vblank evasion. Without this a vblank may occur between updating color management and planes, which should be prevented. intel_color_set_csc was called in update pipe config because the handover from hardware may not have any csc set, which resulted in a black screen. Because of this also update color management during fastset. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Tested-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459350996-4957-4-git-send-email-maarten.lankhorst@linux.intel.com [mlankhorst: Remove comment in response to review feedback.] drivers/gpu/drm/i915/intel_display.c | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) commit e872ef6941ac302ec3e30974e84c9070eeec99ef Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 30 17:16:35 2016 +0200 drm/i915: Do not check crtc_state->active in intel_color_load_luts. This is already tested by its callers. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459350996-4957-3-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/i915/intel_color.c | 4 ---- 1 file changed, 4 deletions(-) commit b95c532148dd839d0cd362e469c9a37172427480 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 30 17:16:34 2016 +0200 drm/i915: Pass crtc_state to color management functions. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459350996-4957-2-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/i915/i915_drv.h | 4 ++-- drivers/gpu/drm/i915/intel_color.c | 43 ++++++++++++++++++------------------ drivers/gpu/drm/i915/intel_display.c | 22 +++++++++++------- drivers/gpu/drm/i915/intel_drv.h | 4 ++-- 4 files changed, 40 insertions(+), 33 deletions(-) commit 3a9b33c6048a9f41c596954e9c3de7c3ab3c4717 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:51:25 2016 +0200 drm/tegra: Don't set a gamma table size Tegra doesn't have any functions to set gamma tables, so this is completely defunct. Not nice to lie to userspace, so let's stop! Cc: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Thierry Reding <treding@nvidia.com> drivers/gpu/drm/tegra/dc.c | 1 - 1 file changed, 1 deletion(-) commit f6764714afdde1f0f511bb0e2d531593c3bec827 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:48:00 2016 +0900 clk: samsung: exynos3250: Add MMC2 clock This patch add the MMC2 clocks (mux, divider, gate) of Exynos3250 SoC. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> drivers/clk/samsung/clk-exynos3250.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 27c0efedcf1be044dd638784189de816382f3f43 Author: Pankaj Dubey <pankaj.dubey@samsung.com> Date: Thu Mar 31 11:47:59 2016 +0900 clk: samsung: exynos3250: Add UART2 clock This patch add the UART2 clocks (mux, divider, gate) of Exynos3250 SoC. Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> drivers/clk/samsung/clk-exynos3250.c | 6 ++++++ 1 file changed, 6 insertions(+) commit fd00bbcddb59c4866e7c985e30f663b62cfc2588 Author: Chanwoo Choi <cw00.choi@samsung.com> Date: Thu Mar 31 11:47:58 2016 +0900 dt-bindings: Add the clock id of UART2 and MMC2 for Exynos3250 This patch adds the new clock id for both UART2 and MM2 device for Exynos3250 SoC. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> include/dt-bindings/clock/exynos3250.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit 8f3e19fae04a0c85d137dbb6f3c49de63b60cfc2 Author: Paul Gortmaker <paul.gortmaker@windriver.com> Date: Sun Mar 27 11:44:41 2016 -0400 gpio: bcm-kona: make explicitly non-modular The Kconfig currently controlling compilation of this code is: config GPIO_BCM_KONA bool "Broadcom Kona GPIO" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modularity so that when reading the driver there is no doubt it is builtin-only. Since module_platform_driver() uses the same init level priority as builtin_platform_driver() the init ordering remains unchanged with this commit. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. Cc: Ray Jui <rjui@broadcom.com> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: bcm-kernel-feedback-list@broadcom.com Cc: linux-gpio@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-bcm-kona.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit 8fccdb580ebec0f5b081d824797911a4c5d91891 Author: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Date: Sun Mar 27 17:43:02 2016 +0200 gpio: gpio-it87: Add support for IT8620 and IT8628 These chips seem to have a 9th GPIO block (thus supporting 72 GPIOs) which is configured through SuperIO register 0xd2 (output enable) and 0xd3 (simple I/O). This is also the reason why io_size is larger than on IT8728 / IT8732. Unfortunately I don't have hardware to test this 9th GPIO block. I am also not sure about not configuring the Simple I/O registers as the hardware I have only uses GPIO block 8. Reading back the values of 0xc0-0xc7 (as configured by the BIOS/EFI on my board) shows that all have 0xff set. Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 2 +- drivers/gpio/gpio-it87.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) commit 691998fac6f50c9117e279c3fbfa63a23cf7ce2e Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 25 13:36:30 2016 +0100 tools/gpio: Add missing initialization of device_name lsgpio.c: In function ‘main’: lsgpio.c:166:7: warning: ‘device_name’ may be used uninitialized in this functio n [-Wmaybe-uninitialized] ret = list_device(device_name); ^ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> tools/gpio/lsgpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f6a49e5a3f5562855f9e4b9b81916b06ef673771 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Fri Mar 25 13:36:29 2016 +0100 tools/gpio: Enable compiler optimization to catch more bugs Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> tools/gpio/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 75c004df525e3bda38dfac1f0e8eff7fe515a0ab Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 31 11:09:11 2016 +0200 gpio: dt-bindings: document the concept of GPIO banks Cc: devicetree@vger.kernel.org Cc: Neil Armstrong <narmstrong@baylibre.com> Cc: Rob Herring <robh@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/devicetree/bindings/gpio/gpio.txt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit 4cfe6aebb272d7c75a2c21ce5db3a9e10f57901a Author: Stefan Agner <stefan@agner.ch> Date: Wed Mar 9 18:16:50 2016 -0800 clk: imx: vf610: add suspend/resume support The clock register are lost when enterying LPSTOPx, hence provide suspend/resume functions restoring them. The clock gates get restored by the individual driver, hence we do not need to restore them here. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-vf610.c | 48 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) commit 349efbeedb2b79292eee12cf6b9a2422ef93853d Author: Stefan Agner <stefan@agner.ch> Date: Wed Mar 9 18:16:49 2016 -0800 clk: imx: vf610: add WKPU unit Signed-off-by: Stefan Agner <stefan@agner.ch> Acked-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-vf610.c | 2 ++ include/dt-bindings/clock/vf610-clock.h | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) commit 0da15d36a90f405541773e884b3264e0f94debd3 Author: Stefan Agner <stefan@agner.ch> Date: Wed Mar 9 18:16:48 2016 -0800 clk: imx: vf610: leave DDR clock on To use STOP mode without putting DDR3 into self-refresh mode, we need to keep the DDR clock enabled. Use the new gate configuration with a value of 2 to make sure that the clock is enabled in RUN, WAIT and STOP mode. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-vf610.c | 3 +++ include/dt-bindings/clock/vf610-clock.h | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) commit 456829228f96702ca281b65e11d11e8c09ca9da0 Author: Stefan Agner <stefan@agner.ch> Date: Wed Mar 9 18:16:47 2016 -0800 clk: imx: clk-gate2: allow custom gate configuration The 2-bit gates found i.MX and Vybrid SoC support different clock configuration: 0b00: clk disabled 0b01: clk enabled in RUN mode but disabled in WAIT and STOP mode 0b10: clk enabled in RUN, WAIT and STOP mode (only Vybrid) 0b11: clk enabled in RUN and WAIT mode For some clocks, we might want to configure different behaviour, e.g. a memory clock should be on even in STOP mode. Add a new function imx_clk_gate2_cgr which allow to configure specific gate values through the cgr_val parameter. Signed-off-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-gate2.c | 7 +++++-- drivers/clk/imx/clk.h | 13 ++++++++++--- 2 files changed, 15 insertions(+), 5 deletions(-) commit 2b8c41daba327c633228169e8bd8ec067ab443f8 Author: Yuyang Du <yuyang.du@intel.com> Date: Wed Mar 30 04:30:56 2016 +0800 sched/fair: Initiate a new task's util avg to a bounded value A new task's util_avg is set to full utilization of a CPU (100% time running). This accelerates a new task's utilization ramp-up, useful to boost its execution in early time. However, it may result in (insanely) high utilization for a transient time period when a flood of tasks are spawned. Importantly, it violates the "fundamentally bounded" CPU utilization, and its side effect is negative if we don't take any measure to bound it. This patch proposes an algorithm to address this issue. It has two methods to approach a sensible initial util_avg: (1) An expected (or average) util_avg based on its cfs_rq's util_avg: util_avg = cfs_rq->util_avg / (cfs_rq->load_avg + 1) * se.load.weight (2) A trajectory of how successive new tasks' util develops, which gives 1/2 of the left utilization budget to a new task such that the additional util is noticeably large (when overall util is low) or unnoticeably small (when overall util is high enough). In the meantime, the aggregate utilization is well bounded: util_avg_cap = (1024 - cfs_rq->avg.util_avg) / 2^n where n denotes the nth task. If util_avg is larger than util_avg_cap, then the effective util is clamped to the util_avg_cap. Reported-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: bsegall@google.com Cc: morten.rasmussen@arm.com Cc: pjt@google.com Cc: steve.muckle@linaro.org Link: http://lkml.kernel.org/r/1459283456-21682-1-git-send-email-yuyang.du@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 2 ++ kernel/sched/fair.c | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++-- kernel/sched/sched.h | 1 + 3 files changed, 57 insertions(+), 2 deletions(-) commit 1c3de5e19fc96206dd086e634129d08e5f7b1000 Author: Yuyang Du <yuyang.du@intel.com> Date: Wed Mar 30 07:07:51 2016 +0800 sched/fair: Update comments after a variable rename The following commit: ed82b8a1ff76 ("sched/core: Move the sched_to_prio[] arrays out of line") renamed prio_to_weight to sched_prio_to_weight, but the old name was not updated in comments. Signed-off-by: Yuyang Du <yuyang.du@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1459292871-22531-1-git-send-email-yuyang.du@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 47252cfbac03644ee4a3adfa50c77896aa94f2bb Author: Steven Rostedt <rostedt@goodmis.org> Date: Mon Mar 21 11:23:39 2016 -0400 sched/core: Add preempt checks in preempt_schedule() code While testing the tracer preemptoff, I hit this strange trace: <...>-259 0...1 0us : schedule <-worker_thread <...>-259 0d..1 0us : rcu_note_context_switch <-__schedule <...>-259 0d..1 0us : rcu_sched_qs <-rcu_note_context_switch <...>-259 0d..1 0us : rcu_preempt_qs <-rcu_note_context_switch <...>-259 0d..1 0us : _raw_spin_lock <-__schedule <...>-259 0d..1 0us : preempt_count_add <-_raw_spin_lock <...>-259 0d..2 0us : do_raw_spin_lock <-_raw_spin_lock <...>-259 0d..2 1us : deactivate_task <-__schedule <...>-259 0d..2 1us : update_rq_clock.part.84 <-deactivate_task <...>-259 0d..2 1us : dequeue_task_fair <-deactivate_task <...>-259 0d..2 1us : dequeue_entity <-dequeue_task_fair <...>-259 0d..2 1us : update_curr <-dequeue_entity <...>-259 0d..2 1us : update_min_vruntime <-update_curr <...>-259 0d..2 1us : cpuacct_charge <-update_curr <...>-259 0d..2 1us : __rcu_read_lock <-cpuacct_charge <...>-259 0d..2 1us : __rcu_read_unlock <-cpuacct_charge <...>-259 0d..2 1us : clear_buddies <-dequeue_entity <...>-259 0d..2 1us : account_entity_dequeue <-dequeue_entity <...>-259 0d..2 2us : update_min_vruntime <-dequeue_entity <...>-259 0d..2 2us : update_cfs_shares <-dequeue_entity <...>-259 0d..2 2us : hrtick_update <-dequeue_task_fair <...>-259 0d..2 2us : wq_worker_sleeping <-__schedule <...>-259 0d..2 2us : kthread_data <-wq_worker_sleeping <...>-259 0d..2 2us : pick_next_task_fair <-__schedule <...>-259 0d..2 2us : check_cfs_rq_runtime <-pick_next_task_fair <...>-259 0d..2 2us : pick_next_entity <-pick_next_task_fair <...>-259 0d..2 2us : clear_buddies <-pick_next_entity <...>-259 0d..2 2us : pick_next_entity <-pick_next_task_fair <...>-259 0d..2 2us : clear_buddies <-pick_next_entity <...>-259 0d..2 2us : set_next_entity <-pick_next_task_fair <...>-259 0d..2 3us : put_prev_entity <-pick_next_task_fair <...>-259 0d..2 3us : check_cfs_rq_runtime <-put_prev_entity <...>-259 0d..2 3us : set_next_entity <-pick_next_task_fair gnome-sh-1031 0d..2 3us : finish_task_switch <-__schedule gnome-sh-1031 0d..2 3us : _raw_spin_unlock_irq <-finish_task_switch gnome-sh-1031 0d..2 3us : do_raw_spin_unlock <-_raw_spin_unlock_irq gnome-sh-1031 0...2 3us!: preempt_count_sub <-_raw_spin_unlock_irq gnome-sh-1031 0...1 582us : do_raw_spin_lock <-_raw_spin_lock gnome-sh-1031 0...1 583us : _raw_spin_unlock <-drm_gem_object_lookup gnome-sh-1031 0...1 583us : do_raw_spin_unlock <-_raw_spin_unlock gnome-sh-1031 0...1 583us : preempt_count_sub <-_raw_spin_unlock gnome-sh-1031 0...1 584us : _raw_spin_unlock <-drm_gem_object_lookup gnome-sh-1031 0...1 584us+: trace_preempt_on <-drm_gem_object_lookup gnome-sh-1031 0...1 603us : <stack trace> => preempt_count_sub => _raw_spin_unlock => drm_gem_object_lookup => i915_gem_madvise_ioctl => drm_ioctl => do_vfs_ioctl => SyS_ioctl => entry_SYSCALL_64_fastpath As I'm tracing preemption disabled, it seemed incorrect that the trace would go across a schedule and report not being in the scheduler. Looking into this I discovered the problem. schedule() calls preempt_disable() but the preempt_schedule() calls preempt_enable_notrace(). What happened above was that the gnome-shell task was preempted on another CPU, migrated over to the idle cpu. The tracer stared with idle calling schedule(), which called preempt_disable(), but then gnome-shell finished, and it enabled preemption with preempt_enable_notrace() that does stop the trace, even though preemption was enabled. The purpose of the preempt_disable_notrace() in the preempt_schedule() is to prevent function tracing from going into an infinite loop. Because function tracing can trace the preempt_enable/disable() calls that are traced. The problem with function tracing is: NEED_RESCHED set preempt_schedule() preempt_disable() preempt_count_inc() function trace (before incrementing preempt count) preempt_disable_notrace() preempt_enable_notrace() sees NEED_RESCHED set preempt_schedule() (repeat) Now by breaking out the preempt off/on tracing into their own code: preempt_disable_check() and preempt_enable_check(), we can add these to the preempt_schedule() code. As preemption would then be disabled, even if they were to be traced by the function tracer, the disabled preemption would prevent the recursion. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20160321112339.6dc78ad6@gandalf.local.home Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/core.c | 68 ++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 59 insertions(+), 9 deletions(-) commit bfdb198ccd99472c5bded689699eb30dd06316bb Author: Tim Chen <tim.c.chen@linux.intel.com> Date: Mon Feb 1 14:47:59 2016 -0800 sched/numa: Remove unnecessary NUMA dequeue update from non-SMP kernels In account_entity_enqueue(), we do not do account_numa_enqueue() as NUMA balancing is not needed for UP kernels. Hence, we should remove the account_numa_dequeue() call from account_entity_dequeue() for UP kernels. Signed-off-by: Tim Chen <tim.c.chen@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1454366879.21738.29.camel@schen9-desk2.jf.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 2 ++ 1 file changed, 2 insertions(+) commit d02c071183e1c01a76811c878c8a52322201f81f Author: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Date: Wed Mar 23 17:54:44 2016 +0530 sched/fair: Reset nr_balance_failed after active balancing To force a task migration during active balancing, nr_balance_failed is set to cache_nice_tries + 1. However nr_balance_failed is not reset. As a side effect, the next regular load balance under the same sd, a cache hot task might be migrated, just because nr_balance_failed count is high. Resetting nr_balance_failed after a successful active balance ensures that a hot task is not unreasonably migrated. This can be verified by looking at othe number of hot task migrations reported by /proc/schedstat. Signed-off-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rik van Riel <riel@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1458735884-30105-1-git-send-email-srikar@linux.vnet.ibm.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/fair.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit d740037fac7052e49450f6fa1454f1144a103b55 Author: Dongsheng Yang <yangds.fnst@cn.fujitsu.com> Date: Tue Mar 22 16:37:08 2016 +0800 sched/cpuacct: Split usage accounting into user_usage and sys_usage Sometimes, cpuacct.usage is not detailed enough to see how much CPU usage a group had. We want to know how much time it used in user mode and how much in kernel mode. This patch introduces more files to give this information: # ls /sys/fs/cgroup/cpuacct/cpuacct.usage* /sys/fs/cgroup/cpuacct/cpuacct.usage /sys/fs/cgroup/cpuacct/cpuacct.usage_percpu /sys/fs/cgroup/cpuacct/cpuacct.usage_user /sys/fs/cgroup/cpuacct/cpuacct.usage_percpu_user /sys/fs/cgroup/cpuacct/cpuacct.usage_sys /sys/fs/cgroup/cpuacct/cpuacct.usage_percpu_sys ... while keeping the ABI with the existing counter. Signed-off-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com> [ Ported to newer kernels. ] Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Tejun Heo <tj@kernel.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Tejun Heo <htejun@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/aa171da036b520b51c79549e9b3215d29473f19d.1458635566.git.zhaolei@cn.fujitsu.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/cpuacct.c | 140 +++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 113 insertions(+), 27 deletions(-) commit 5ca3726af7f66a8cc71ce4414cfeb86deb784491 Author: Zhao Lei <zhaolei@cn.fujitsu.com> Date: Tue Mar 22 16:37:07 2016 +0800 sched/cpuacct: Show all possible CPUs in cpuacct output Current code show stats of online CPUs in cpuacct.statcpus, show stats of present cpus in cpuacct.usage(_percpu), and using present CPUs for setting cpuacct.usage. It will cause inconsistent result when a CPU is online or offline or hotpluged. We should always use possible CPUs to avoid above problem. Here are the contents of a cpuacct.usage_percpu sysfs file, on a 4 CPU system with maxcpus=32: Before the patch: # cat cpuacct.usage_percpu 2456565 411435 1052897 832584 After the patch: # cat cpuacct.usage_percpu 2456565 411435 1052897 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 Suggested-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Tejun Heo <htejun@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/a11d56cef12d0b4807f8be3a46bf9798c3014d59.1458635566.git.zhaolei@cn.fujitsu.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/sched/cpuacct.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit dd98756d78153dbb43685f0f0e618dda235aee00 Author: Kamlakant Patel <kamlakant.patel@broadcom.com> Date: Thu Mar 24 15:01:40 2016 +0530 gpio: xlp: Add GPIO driver support for Broadcom Vulcan ARM64 - Add GPIO support for Broadcom Vulcan ARM64. - Add depends on ARCH_VULCAN to Kconfig to enable gpio controller driver for Broadcom Vulcan ARM64 SoCs. Signed-off-by: Kamlakant Patel <kamlakant.patel@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> .../devicetree/bindings/gpio/gpio-xlp.txt | 3 +++ drivers/gpio/Kconfig | 2 +- drivers/gpio/gpio-xlp.c | 25 +++++++++++++++++----- 3 files changed, 24 insertions(+), 6 deletions(-) commit 16fe1ad289019d78a8f8fdb65f08d298ee921cb3 Author: Alexander Stein <alexander.stein@systec-electronic.com> Date: Wed Mar 23 18:01:27 2016 +0100 gpio: mcp23s08: Add support for level triggered interrupts The interrupt for the corresponding pin is configured to trigger when the pin state changes compared to a preconfigured state (Bit set in INTCON). This state is set by setting/clearing the bit in DEFVAL. In the interrupt handler we need also to check if the bit in INTCON is set for level triggered interrupts. Signed-off-by: Alexander Stein <alexander.stein@systec-electronic.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mcp23s08.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) commit d1b26c70246bc72922ae61d9f972d5c2588409e7 Author: Wang Nan <wangnan0@huawei.com> Date: Mon Mar 28 06:41:31 2016 +0000 perf/ring_buffer: Prepare writing into the ring-buffer from the end Convert perf_output_begin() to __perf_output_begin() and make the later function able to write records from the end of the ring-buffer. Following commits will utilize the 'backward' flag. This is the core patch to support writing to the ring-buffer backwards, which will be introduced by upcoming patches to support reading from overwritable ring-buffers. In theory, this patch should not introduce any extra performance overhead since we use always_inline, but it does not hurt to double check that assumption: When CONFIG_OPTIMIZE_INLINING is disabled, the output object is nearly identical to original one. See: http://lkml.kernel.org/g/56F52E83.70409@huawei.com When CONFIG_OPTIMIZE_INLINING is enabled, the resuling object file becomes smaller: $ size kernel/events/ring_buffer.o* text data bss dec hex filename 4641 4 8 4653 122d kernel/events/ring_buffer.o.old 4545 4 8 4557 11cd kernel/events/ring_buffer.o.new Performance testing results: Calling 3000000 times of 'close(-1)', use gettimeofday() to check duration. Use 'perf record -o /dev/null -e raw_syscalls:*' to capture system calls. In ns. Testing environment: CPU : Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz Kernel : v4.5.0 MEAN STDVAR BASE 800214.950 2853.083 PRE 2253846.700 9997.014 POST 2257495.540 8516.293 Where 'BASE' is pure performance without capturing. 'PRE' is test result of pure 'v4.5.0' kernel. 'POST' is test result after this patch. Considering the stdvar, this patch doesn't hurt performance, within noise margin. For testing details, see: http://lkml.kernel.org/g/56F89DCD.1040202@huawei.com Signed-off-by: Wang Nan <wangnan0@huawei.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: <pi3orama@163.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/r/1459147292-239310-4-git-send-email-wangnan0@huawei.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/ring_buffer.c | 42 ++++++++++++++++++++++++++++++++++++------ 1 file changed, 36 insertions(+), 6 deletions(-) commit 1879445dfa7bbd6fe21b09c5cc72f4934798afed Author: Wang Nan <wangnan0@huawei.com> Date: Mon Mar 28 06:41:30 2016 +0000 perf/core: Set event's default ::overflow_handler() Set a default event->overflow_handler in perf_event_alloc() so don't need to check event->overflow_handler in __perf_event_overflow(). Following commits can give a different default overflow_handler. Initial idea comes from Peter: http://lkml.kernel.org/r/20130708121557.GA17211@twins.programming.kicks-ass.net Since the default value of event->overflow_handler is not NULL, existing 'if (!overflow_handler)' checks need to be changed. is_default_overflow_handler() is introduced for this. No extra performance overhead is introduced into the hot path because in the original code we still need to read this handler from memory. A conditional branch is avoided so actually we remove some instructions. Signed-off-by: Wang Nan <wangnan0@huawei.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: <pi3orama@163.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/r/1459147292-239310-3-git-send-email-wangnan0@huawei.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/arm/kernel/hw_breakpoint.c | 4 ++-- arch/arm64/kernel/hw_breakpoint.c | 4 ++-- include/linux/perf_event.h | 6 ++++++ kernel/events/core.c | 14 ++++++++------ 4 files changed, 18 insertions(+), 10 deletions(-) commit 86e7972f690c1017fd086cdfe53d8524e68c661c Author: Wang Nan <wangnan0@huawei.com> Date: Mon Mar 28 06:41:29 2016 +0000 perf/ring_buffer: Introduce new ioctl options to pause and resume the ring-buffer Add new ioctl() to pause/resume ring-buffer output. In some situations we want to read from the ring-buffer only when we ensure nothing can write to the ring-buffer during reading. Without this patch we have to turn off all events attached to this ring-buffer to achieve this. This patch is a prerequisite to enable overwrite support for the perf ring-buffer support. Following commits will introduce new methods support reading from overwrite ring buffer. Before reading, caller must ensure the ring buffer is frozen, or the reading is unreliable. Signed-off-by: Wang Nan <wangnan0@huawei.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: <pi3orama@163.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Brendan Gregg <brendan.d.gregg@gmail.com> Cc: He Kuang <hekuang@huawei.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: Zefan Li <lizefan@huawei.com> Link: http://lkml.kernel.org/r/1459147292-239310-2-git-send-email-wangnan0@huawei.com Signed-off-by: Ingo Molnar <mingo@kernel.org> include/uapi/linux/perf_event.h | 1 + kernel/events/core.c | 13 +++++++++++++ kernel/events/internal.h | 9 +++++++++ kernel/events/ring_buffer.c | 12 +++++++++++- 4 files changed, 34 insertions(+), 1 deletion(-) commit 0a74c5b3d20d2a8693848b6ae4f1a97624f5b781 Author: Jiri Olsa <jolsa@kernel.org> Date: Wed Mar 16 15:34:29 2016 +0100 ftrace/perf: Check sample types only for sampling events Currently we check sample type for ftrace:function events even if it's not created as a sampling event. That prevents creating ftrace_function event in counting mode. Make sure we check sample types only for sampling events. Before: $ sudo perf stat -e ftrace:function ls ... Performance counter stats for 'ls': <not supported> ftrace:function 0.001983662 seconds time elapsed After: $ sudo perf stat -e ftrace:function ls ... Performance counter stats for 'ls': 44,498 ftrace:function 0.037534722 seconds time elapsed Suggested-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Steven Rostedt <rostedt@goodmis.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1458138873-1553-2-git-send-email-jolsa@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/trace/trace_event_perf.c | 3 +++ 1 file changed, 3 insertions(+) commit 981a4cb380d3dff7010ce9f89618064a254eab8c Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 15:42:49 2016 +0200 perf/x86/intel/bts: Move transaction start/stop to start/stop callbacks As per AUX buffer management requirement, AUX output has to happen between pmu::start and pmu::stop calls so that perf_event_stop() actually stops it and therefore perf can free the AUX data after it has called pmu::stop. This patch moves perf_aux_output_{begin,end} from bts_event_{add,del} to bts_event_{start,stop}. As a bonus, we get rid of bts_buffer_is_full(), which is already taken care of by perf_aux_output_begin() anyway. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1457098969-21595-6-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/bts.c | 105 ++++++++++++++++++++------------------------ 1 file changed, 48 insertions(+), 57 deletions(-) commit 66d219014a4ee47ad4ca2b9db5fe6547353e2a56 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 15:42:48 2016 +0200 perf/x86/intel/pt: Move transaction start/stop to PMU start/stop callbacks As per AUX buffer management requirement, AUX output has to happen between pmu::start and pmu::stop calls so that perf_event_stop() actually stops it and therefore perf can free the AUX data after it has called pmu::stop. This patch moves perf_aux_output_{begin,end} from pt_event_{add,del} to pt_event_{start,stop}. As a bonus, we get rid of pt_buffer_is_full(), which is already taken care of by perf_aux_output_begin() anyway. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1457098969-21595-5-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/pt.c | 85 +++++++++++++++------------------------------- 1 file changed, 27 insertions(+), 58 deletions(-) commit af5bb4ed1254a378b6028c09e58bdcc1cd9bf5b3 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 15:42:47 2016 +0200 perf/ring_buffer: Document AUX API usage In order to ensure safe AUX buffer management, we rely on the assumption that pmu::stop() stops its ongoing AUX transaction and not just the hw. This patch documents this requirement for the perf_aux_output_{begin,end}() APIs. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mathieu Poirier <mathieu.poirier@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1457098969-21595-4-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/ring_buffer.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 95ff4ca26c492fc1ed7751f5dd7ab7674b54f4e0 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Wed Dec 2 18:41:11 2015 +0200 perf/core: Free AUX pages in unmap path Now that we can ensure that when ring buffer's AUX area is on the way to getting unmapped new transactions won't start, we only need to stop all events that can potentially be writing aux data to our ring buffer. Having done that, we can safely free the AUX pages and corresponding PMU data, as this time it is guaranteed to be the last aux reference holder. This partially reverts: 57ffc5ca679 ("perf: Fix AUX buffer refcounting") ... which was made to defer deallocation that was otherwise possible from an NMI context. Now it is no longer the case; the last call to rb_free_aux() that drops the last AUX reference has to happen in perf_mmap_close() on that AUX area. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/87d1qtz23d.fsf@ashishki-desk.ger.corp.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/core.c | 120 +++++++++++++++++++++++++++++++++++++++++++- kernel/events/internal.h | 1 - kernel/events/ring_buffer.c | 37 ++++---------- 3 files changed, 129 insertions(+), 29 deletions(-) commit dcb10a967ce82d5ad20570693091139ae716ff76 Author: Alexander Shishkin <alexander.shishkin@linux.intel.com> Date: Fri Mar 4 15:42:45 2016 +0200 perf/ring_buffer: Refuse to begin AUX transaction after rb->aux_mmap_count drops When ring buffer's AUX area is unmapped and rb->aux_mmap_count drops to zero, new AUX transactions into this buffer can still be started, even though the buffer in en route to deallocation. This patch adds a check to perf_aux_output_begin() for rb->aux_mmap_count being zero, in which case there is no point starting new transactions, in other words, the ring buffers that pass a certain point in perf_mmap_close will not have their events sending new data, which clears path for freeing those buffers' pages right there and then, provided that no active transactions are holding the AUX reference. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@infradead.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Cc: vince@deater.net Link: http://lkml.kernel.org/r/1457098969-21595-2-git-send-email-alexander.shishkin@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/ring_buffer.c | 7 +++++++ 1 file changed, 7 insertions(+) commit 26657848502b78474a5f17f9ce2ae6dc8d8d6262 Author: Peter Zijlstra <peterz@infradead.org> Date: Tue Mar 22 22:09:18 2016 +0100 perf/core: Verify we have a single perf_hw_context PMU There should (and can) only be a single PMU for perf_hw_context events. This is because of how we schedule events: once a hardware event fails to schedule (the PMU is 'full') we stop trying to add more. The trivial 'fix' would break the Round-Robin scheduling we do. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Signed-off-by: Ingo Molnar <mingo@kernel.org> kernel/events/core.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 07dc900e17a94681877b5797ce62ba97fa170400 Author: Peter Zijlstra <peterz@infradead.org> Date: Tue Mar 29 14:30:35 2016 +0200 perf/x86: Move Kconfig.perf and other perf configuration bits to events/Kconfig Ingo says: "If we do a separate file we should have it in arch/x86/events/Kconfig (not in arch/x86/Kconfig.perf), and also move some of the other bits, such as PERF_EVENTS_AMD_POWER?" Suggested-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Kconfig | 11 +---------- arch/x86/Kconfig.perf | 27 --------------------------- arch/x86/events/Kconfig | 36 ++++++++++++++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 37 deletions(-) commit aaf248848db503927644d28e239bc399ed45959f Author: Huang Rui <ray.huang@amd.com> Date: Fri Jan 29 16:29:57 2016 +0800 perf/x86/msr: Add AMD IRPERF (Instructions Retired) performance counter AMD Zeppelin (Family 17h, Model 00h) introduces an instructions retired performance counter which is indicated by CPUID.8000_0008H:EBX[1]. A dedicated Instructions Retired MSR register (MSR 0xC000_000E9) increments once for every instruction retired. Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Fengguang Wu <fengguang.wu@intel.com> Cc: Jacob Shin <jacob.w.shin@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robert Richter <rric@kernel.org> Cc: Stephane Eranian <eranian@google.com> Cc: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1454056197-5893-3-git-send-email-ray.huang@amd.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/msr.c | 30 +++++++++++++++++++----------- arch/x86/include/asm/cpufeatures.h | 1 + arch/x86/include/asm/msr-index.h | 3 +++ 3 files changed, 23 insertions(+), 11 deletions(-) commit 8a22426184774d7ced9c1d3aa4d95d34101fb3be Author: Huang Rui <ray.huang@amd.com> Date: Fri Jan 29 16:29:56 2016 +0800 perf/x86/msr: Add AMD PTSC (Performance Time-Stamp Counter) support AMD Carrizo (Family 15h, Model 60h) introduces a time-stamp counter which is indicated by CPUID.8000_0001H:ECX[27]. It increments at a 100 MHz rate in all P-states, and C states, S0, or S1. The frequency is about 100MHz. This counter will be used to calculate processor power and other parts. So add an interface into the MSR PMU to get the PTSC counter value. Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Fengguang Wu <fengguang.wu@intel.com> Cc: Jacob Shin <jacob.w.shin@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robert Richter <rric@kernel.org> Cc: Stephane Eranian <eranian@google.com> Cc: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1454056197-5893-2-git-send-email-ray.huang@amd.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/msr.c | 8 ++++++++ arch/x86/include/asm/cpufeatures.h | 1 + arch/x86/include/asm/msr-index.h | 1 + 3 files changed, 10 insertions(+) commit c7afba320e91cca46fdf078798002b9ec84be8d3 Author: Thomas Gleixner <tglx@linutronix.de> Date: Sun Mar 20 18:59:04 2016 +0000 x86/perf/intel/cstate: Modularize driver Add the exit function and allow the driver to be built as a module. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/20160320185623.658869675@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Kconfig.perf | 8 ++++++++ arch/x86/events/intel/Makefile | 4 +++- arch/x86/events/intel/cstate.c | 22 +++++++++++++++++++--- 3 files changed, 30 insertions(+), 4 deletions(-) commit d29859e7777ebc2c8e2db6e4d8e299f50fc26414 Author: Thomas Gleixner <tglx@linutronix.de> Date: Sun Mar 20 18:59:03 2016 +0000 x86/perf/intel/cstate: Sanitize error handling There is no point in WARN_ON() inside of a well known init function. We already know the call stack and it's really not of critical importance whether the registration of a PMU fails. Aside of that for consistency reasons it's just pointless to try to register another PMU if the first register attempt failed. There is also no value in keeping one PMU if the second one can not be registered. Make it consistent so we can finaly modularize the driver. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/20160320185623.579794064@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/cstate.c | 50 +++++++++++++++++++++++------------------- 1 file changed, 27 insertions(+), 23 deletions(-) commit 424646eeadab64da959f960928804e5289417819 Author: Thomas Gleixner <tglx@linutronix.de> Date: Sun Mar 20 18:59:03 2016 +0000 x86/perf/intel/cstate: Sanitize probing The whole probing functionality can simply be expressed with model matching and a bunch of structures describing the variants. This is a first step to make that driver modular. While at it, get rid of completely pointless comments and name the enums so they are self explaining. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> [ Reworked probing to clear msr[].attr for all !present msrs. ] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/20160320185623.500381872@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/cstate.c | 359 ++++++++++++++++++----------------------- 1 file changed, 160 insertions(+), 199 deletions(-) commit 49de0493e5f67a8023fa6fa5c89097c1f77de74e Author: Thomas Gleixner <tglx@linutronix.de> Date: Sun Mar 20 18:59:02 2016 +0000 x86/perf/intel/cstate: Make cstate hotplug handling actually work The current implementation aside of being an incomprehensible mess is broken. # cat /sys/bus/event_source/devices/cstate_core/cpumask 0-17 That's on a quad socket machine with 72 physical cores! Qualitee stuff. So it's not a surprise that event migration in case of CPU hotplug does not work either. # perf stat -e cstate_core/c6-residency/ -C 1 sleep 60 & # echo 0 >/sys/devices/system/cpu/cpu1/online Tracing cstate_pmu_event_update gives me: [001] cstate_pmu_event_update <-event_sched_out After the fix it properly moves the event: [001] cstate_pmu_event_update <-event_sched_out [073] cstate_pmu_event_update <-__perf_event_read [073] cstate_pmu_event_update <-event_sched_out The migration of pkg events does not work either. Not that I'm surprised. I really could not be bothered to decode that loop mess and simply replaced it by querying the proper cpumasks which give us the answer in a comprehensible way. This also requires to direct the event to the current active reader CPU in cstate_pmu_event_init() otherwise the hotplug logic can't work. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> [ Added event->cpu < 0 test to not explode] Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Borislav Petkov <bp@suse.de> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Kan Liang <kan.liang@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/20160320185623.422519970@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/events/intel/cstate.c | 122 ++++++++++++++++++----------------------- 1 file changed, 53 insertions(+), 69 deletions(-) commit 4b6e2571bf00019e016255ad62b56feb9f498db7 Author: Kan Liang <kan.liang@intel.com> Date: Sat Mar 19 00:20:50 2016 -0700 x86/perf/intel/rapl: Make the Intel RAPL PMU driver modular By default, the RAPL driver will be built into the kernel. If it is configured as a module, the supported CPU model can be auto loaded. Also clean up the code of rapl_pmu_init(). Based-on-a-patch-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Kan Liang <kan.liang@intel.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1458372050-2420-2-git-send-email-kan.liang@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Kconfig.perf | 8 +++ arch/x86/events/intel/Makefile | 3 +- arch/x86/events/intel/rapl.c | 121 ++++++++++++++++++++++++++++------------- 3 files changed, 92 insertions(+), 40 deletions(-) commit e633c65a1d5859da170a83d537d9762c07d12213 Author: Kan Liang <kan.liang@intel.com> Date: Sun Mar 20 01:33:36 2016 -0700 x86/perf/intel/uncore: Make the Intel uncore PMU driver modular By default, the uncore driver will be built into the kernel. If it is configured as a module, the supported CPU model can be auto loaded. This patch also cleans up the code of uncore_cpu_init() and uncore_pci_init(). Based-on-a-patch-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Kan Liang <kan.liang@intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Vince Weaver <vincent.weaver@maine.edu> Link: http://lkml.kernel.org/r/1458462817-2475-1-git-send-email-kan.liang@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/Kconfig | 6 +- arch/x86/Kconfig.perf | 11 +++ arch/x86/events/Makefile | 9 +- arch/x86/events/intel/Makefile | 6 ++ arch/x86/events/intel/uncore.c | 216 ++++++++++++++++++++++++----------------- 5 files changed, 148 insertions(+), 100 deletions(-) commit 1418f9e6e02da2ad0a6aacc8645e6ad7496105e9 Author: Liu Gang <Gang.Liu@nxp.com> Date: Wed Mar 23 17:47:19 2016 +0800 gpio: mpc8xxx: Add new platforms GPIO DT node description Update the NXP GPIO node dt-binding file for QorIQ and Layerscape platforms, and add one more example with ls2080a GPIO node. Signed-off-by: Liu Gang <Gang.Liu@nxp.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> .../devicetree/bindings/gpio/gpio-mpc8xxx.txt | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) commit 80018bd9cb590c3d7fea9b51730e4a251cb1bb42 Author: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Date: Mon Mar 14 23:32:10 2016 +0000 gpio: 74x164: add dt support for nxp's 74x594 The chip is also an 8 bit shift register which works out of the box as a GPO expander with this patch Signed-off-by: Nicolas Saenz Julienne <nicolassaenzj@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Documentation/devicetree/bindings/gpio/gpio-74x164.txt | 4 +++- drivers/gpio/gpio-74x164.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) commit c6cc75fec020eda0df04aff21f6cd6f4bfc1eea5 Author: Axel Lin <axel.lin@ingics.com> Date: Thu Mar 17 12:01:43 2016 +0800 gpio: xgene-sb: Use irq_domain_free_irqs_common() Current code calls irq_domain_alloc_irqs_parent() in .alloc, so it should call irq_domain_free_irqs_parent() accordingly in .free. Fix it by switching to use irq_domain_free_irqs_common() instead. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-xgene-sb.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) commit 63cc787e71ae12976b2116f09677d1f2805df83e Author: Axel Lin <axel.lin@ingics.com> Date: Thu Mar 17 12:00:31 2016 +0800 irqdomain: Export irq_domain_free_irqs_common Export irq_domain_free_irqs_common so it can be used by modules. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> kernel/irq/irqdomain.c | 1 + 1 file changed, 1 insertion(+) commit 42a44402ecb78e87eecf7ccad8099287e660ec36 Author: Wang Hongcheng <annie.wang@amd.com> Date: Fri Mar 11 10:58:42 2016 +0800 pinctrl: amd:Add device HID for future AMD GPIO controller Add device HID AMDI0030 to match the AMD ACPI Vendor ID (AMDI) as registered in http://www.uefi.org/acpi_id_list, and the GPIO controller on future AMD paltform will use the HID instead of AMD0030. Signed-off-by: Wang Hongcheng <annie.wang@amd.com> Acked-by: Ken Xue <ken.Xue@amd.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/pinctrl/pinctrl-amd.c | 1 + 1 file changed, 1 insertion(+) commit 84c48d8d01b74a2b98c164513ca5e37c73166825 Merge: 643cb15 85dc600 Author: Ingo Molnar <mingo@kernel.org> Date: Thu Mar 31 09:55:12 2016 +0200 Merge branch 'perf/urgent' into perf/core, to fix up fixes before queueing up new changes Signed-off-by: Ingo Molnar <mingo@kernel.org> commit fbf6d8798fceb1f64eb0e5fd7cd541becfc376cd Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 23 14:51:12 2016 +0100 drm/i915: Add locking to pll updates, v3. With async modesets this is no longer protected with connection_mutex, so ensure that each pll has its own lock. The pll configuration state is still protected; it's only the pll updates that need locking against concurrency. Changes since v1: - Rebased. - Fix locking to protect all accesses. (Durgadoss) Changes since v2: - Make the dpll_lock global to protect concurrent updates to the same register, for example DPLL_CTRL1 on skl. (Ander) Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56F29F50.1090708@linux.intel.com Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> drivers/gpu/drm/i915/i915_drv.h | 7 +++++++ drivers/gpu/drm/i915/intel_dpll_mgr.c | 25 +++++++++++++++++++------ 2 files changed, 26 insertions(+), 6 deletions(-) commit ab503238ff6974b9a51d328c2a55c505064c64f7 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 31 09:09:12 2016 +0200 powerpc: ppc4xx: drop unused variable commit 0d36fe65f58391712e11a6621075f373216e5f00 "powerpc: ppc4xx: use gpiochip data pointer" made the mm_gc local variable in ppc4xx_gpio_set() redundant, and when GCC treats warnings as errors this happens: arch/powerpc/sysdev/ppc4xx_gpio.c: In function 'ppc4xx_gpio_set': arch/powerpc/sysdev/ppc4xx_gpio.c:93:26: error: unused variable 'mm_gc' [-Werror=unused-variable] struct of_mm_gpio_chip *mm_gc = to_of_mm_gpio_chip(gc); ^ cc1: all warnings being treated as errors Reported-by: kbuild test robot <fengguang.wu@intel.com> Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/sysdev/ppc4xx_gpio.c | 1 - 1 file changed, 1 deletion(-) commit 4817ebb144ffa5a1a2bc84b89ed9655dbe6c4502 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:17 2016 +0100 serial: doc: Correct return type of mctrl_gpio_to_gpiod() Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit d886e7ce157373773254f5c1e7f011cd9d3ec558 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:16 2016 +0100 serial: doc: Grammar s/function are/functions are/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 93a2f6329f40d951101ab8ab160f24680f1c122a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:15 2016 +0100 serial: doc: Spelling s/divsor/divisor/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit fbe3128bcf87723bbbaa2de26f5d1c1122c66b54 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:14 2016 +0100 serial: doc: .break_ctl() is called with port->mutex() held Note that mutex_lock() should not be called with interrupts disabled. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 0adc301e7b3c098744d0098008b1aa31041e220b Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:13 2016 +0100 serial: doc: Document .set_ldisc() Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 5 +++++ 1 file changed, 5 insertions(+) commit e27585c7970decd26113ca036a1cb5678d88ee5a Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:12 2016 +0100 serial: doc: Document .unthrottle() Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 7 +++++++ 1 file changed, 7 insertions(+) commit 39c5144e5f0bc2dec9ebe3613d5f9c0f0b0bdc72 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:11 2016 +0100 serial: doc: Document .throttle() Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 7 +++++++ 1 file changed, 7 insertions(+) commit 4895b1d72117efea48ff51e94a26ce3cbde4d1a1 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:10 2016 +0100 serial: doc: Un-document obsolete tmpbuf_sem uart_info.tmpbuf and uart_info.tmpbuf_sem were removed in v2.6.10, in full-history-linux commit a797ad7e3ae9cad4 ("[SERIAL] Clean up serial_core.c write functions."). Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) commit 834392a7d92677ff2bdc1c709b1171ee585b55c9 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:16:09 2016 +0100 serial: doc: Un-document non-existing uart_write_console() uart_write_console() never existed, not even when the "new uart_write_console function" was documented. Fixes: 67ab7f596b6adbae ("[SERIAL] Update serial driver documentation") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/serial/driver | 5 ----- 1 file changed, 5 deletions(-) commit f3e27a80b782b9b9857157e0a104a8757e72d166 Author: Baolin Wang <baolin.wang@linaro.org> Date: Wed Mar 16 20:02:49 2016 +0800 Documentation: mmc: Add the introduction for mmc-utils This patch introduces one mmc test tools called mmc-utils, which is convenient if someone wants to exercise and test MMC/SD devices from userspace. Signed-off-by: Baolin Wang <baolin.wang@linaro.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/mmc/00-INDEX | 2 ++ Documentation/mmc/mmc-tools.txt | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) commit f7ca20deee2b2eac0a43e1dcf75d5d3ee2c6c81e Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Sat Mar 19 12:51:23 2016 +0000 Documentation: update URLs for Richard Gooch's articles Current URL for "Kernel API changes from 2.0 to 2.2" hasn't been available for some time, updating. The second article about changes from 2.2 to 2.4 is missing a URL, adding it. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/kernel-docs.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit dc831ab3cc7f22ae500872e54cd85317e766c156 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Sat Mar 19 12:51:22 2016 +0000 Documentation: update URL of Analysis of the Ext2fs structure The current URL has been down for some time, updating it to a working one. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/kernel-docs.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a06bdd49c98c6a538890650bac9a0173cbc644b2 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Sat Mar 19 12:51:20 2016 +0000 Documentation: add Linux Kernel Development book The Linux Kernel Development book by Robert Love has been recommended to me by multiple kernel hackers. Worth having in the list of books in kernel-docs.txt for newbies looking for good learning resources. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/kernel-docs.txt | 7 +++++++ 1 file changed, 7 insertions(+) commit 5408e5a4552b8e33a65127944bec21dd3d9258c1 Author: Wei Fang <fangwei1@huawei.com> Date: Mon Mar 21 19:42:19 2016 +0800 Documentation: update missing index files in block/00-INDEX Update missing index files in block/00-INDEX. Signed-off-by: Wei Fang <fangwei1@huawei.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/block/00-INDEX | 4 ++++ 1 file changed, 4 insertions(+) commit 0b55257ebc66d333e86415b0fdf46450ca807059 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Tue Mar 8 09:33:39 2016 -0300 clk: imx6sx: Register SAI clocks as shared clocks SAIx and SAIx_IPG share the same bit fields in the CCM registers, so we should better register them via imx_clk_gate2_shared(). Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> drivers/clk/imx/clk-imx6sx.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 643cb15ba07260faadd9fcfabac4f5d9d0ddc053 Merge: c932cf0 d1706b3 Author: Ingo Molnar <mingo@kernel.org> Date: Thu Mar 31 08:33:43 2016 +0200 Merge tag 'perf-core-for-mingo-20160330' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core Pull perf/core improvements and fixes: User visible changes: - Add support for skipping itrace instructions, useful to fast forward processor trace (Intel PT, BTS) to right after initialization code at the start of a workload (Andi Kleen) - Add support for backtraces in perl 'perf script's (Dima Kogan) - Add -U/-K (--all-user/--all-kernel) options to 'perf mem' (Jiri Olsa) - Make -f/--force option documentation consistent across tools (Jiri Olsa) Infrastructure changes: - Add 'perf test' to check for event times (Jiri Olsa) - 'perf config' cleanups (Taeung Song) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> commit dbe7fcdaf94052faf65172bb91d4266d20b5458b Author: Jianyu Zhan <nasa4836@gmail.com> Date: Sun Mar 27 11:51:20 2016 +0800 Documentation/IRQ-domain.txt: Document irq_domain_create_{linear, tree} They have the same functionalities as irq_domain_add_{linear, tree}, except fro accepting different first argument. Signed-off-by: Jianyu Zhan <nasa4836@gmail.com> Acked-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/IRQ-domain.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 83d26b63268faf9137878e34f7e8cfda8a089124 Author: Dave Anderson <danderson@google.com> Date: Mon Mar 28 14:56:47 2016 -0700 bpf: doc: "neg" opcode has no operands Fixes a copy-paste-o in the BPF opcode table: "neg" takes no arguments and thus has no addressing modes. Signed-off-by: Dave Anderson <danderson@google.com> Signed-off-by: Kees Cook <keescook@chromium.org> Acked-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Documentation/networking/filter.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 249c4f538b1aae55d41699f8bafc6cb762a7f48f Author: Deepak M <m.deepak@intel.com> Date: Wed Mar 30 17:03:39 2016 +0300 drm: Add new DCS commands in the enum list Adding new DCS commands which are specified in the DCS 1.3 spec related to CABC. v2: Sorted the Macro`s by value (Andrzej) v3 by Jani: sort all of enum, refer to MIPI DCS 1.3 Cc: Andrzej Hajda <a.hajda@samsung.com> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: David Airlie <airlied@linux.ie> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: <dri-devel@lists.freedesktop.org> Suggested-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Deepak M <m.deepak@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459346623-30752-1-git-send-email-jani.nikula@intel.com include/video/mipi_display.h | 8 ++++++++ 1 file changed, 8 insertions(+) commit 00fdf360d05111d4dfc4cb03727ff26f8ab2fd46 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 16:42:23 2016 +0200 drm: Make uapi headers C89 pendantic compliant This ports the below libdrm commit to the kernel commit 0f4452bb51306024fbf4cbf77d8baab20cefba67 Author: Daniel Kurtz <djkurtz@chromium.org> Date: Mon Aug 26 23:39:16 2013 +0800 libdrm: Make some drm headers compatible with gcc -std=c89 -pedantic The following minor changes were needed to these headers: * Convert // comments to /* */ * No , after final member of enum With these changes, these header files can be included by a program that is built with gcc options: -std=c89 -Werror -pedantic Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459348943-12803-2-git-send-email-daniel.vetter@ffwll.ch include/uapi/drm/drm.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4c5b7f3ae53b02136d38dee46b412ac8a7f6f4ff Author: Rob Clark <robdclark@gmail.com> Date: Fri Mar 18 19:14:55 2016 -0400 drm/atomic: export drm_atomic_helper_wait_for_fences() Signed-off-by: Rob Clark <robdclark@gmail.com> Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458342904-23326-3-git-send-email-robdclark@gmail.com drivers/gpu/drm/drm_atomic_helper.c | 15 +++++++++++++-- include/drm/drm_atomic_helper.h | 2 ++ 2 files changed, 15 insertions(+), 2 deletions(-) commit 30889c72a9fe53b3d4303464fc688497cbb14219 Author: Bobi Jam <bobijam.xu@intel.com> Date: Wed Mar 30 19:49:07 2016 -0400 staging/lustre: lov_io_init() should return error code lov_io_init_empty/release() should returns error code instead of true on error case. Fault IO needs to handle restart in the case of accessing HSM released file Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Reviewed-on: http://review.whamcloud.com/17240 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7446 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_mmap.c | 4 ++++ drivers/staging/lustre/lustre/lov/lov_io.c | 4 ++-- drivers/staging/lustre/lustre/obdclass/cl_io.c | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) commit 6cead36d284f230d29c2500c774180b8c716d4e6 Author: Vitaly Fertman <vitaly.fertman@seagate.com> Date: Wed Mar 30 19:49:06 2016 -0400 staging/lustre/ldlm: Solve a race for LRU lock cancel This patch solves a race condition that the lock may be used again after LRU cancellation policy check. In that case, the lock may have locked or dirty pages that makes the policy check totally useless. The problem is solved by checking l_last_used at cancellation time therefore it can make sure that the lock has not been used. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com> Reviewed-on: http://review.whamcloud.com/12603 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5781 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_internal.h | 3 ++- drivers/staging/lustre/lustre/ldlm/ldlm_lock.c | 16 +++++++++++++--- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 11 +++++++++-- 3 files changed, 24 insertions(+), 6 deletions(-) commit e9570b490ba209220b43530ca250060035d6bcba Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:49:05 2016 -0400 staging/lustre: Fix spacing style before open parenthesis This fixes the remaining occurences of checkpatch warnings of the form of WARNING: space prohibited between function name and open parenthesis '(' Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lu_object.h | 64 +++++++++++----------- .../lustre/lustre/include/lustre/lustre_idl.h | 2 +- .../lustre/lustre/include/lustre/lustre_user.h | 36 ++++++------ drivers/staging/lustre/lustre/include/lustre_cfg.h | 2 +- .../staging/lustre/lustre/include/lustre_import.h | 2 +- drivers/staging/lustre/lustre/include/lustre_lib.h | 36 ++++++------ drivers/staging/lustre/lustre/obdclass/debug.c | 4 +- .../staging/lustre/lustre/osc/osc_cl_internal.h | 22 ++++---- drivers/staging/lustre/lustre/osc/osc_request.c | 2 +- 9 files changed, 85 insertions(+), 85 deletions(-) commit 2640256e388f8f5dd2f9fdbb034b3c0332e10e41 Author: Vitaly Fertman <vitaly.fertman@seagate.com> Date: Wed Mar 30 19:49:04 2016 -0400 staging/lustre/ldlm: restore the ELC for enqueue after LU-4300 enqueue does not ELC anymore, however if enqueue is agressive (ls -la of a large dir) we may exceed lru-resize limit quickly because LRUR shrinker and recalc are called not so often. ELC is to be restored in enqueue. ELC also should check for the lock weight, in addition to LRUR. ELC can also keep "skipped" locks, i.e. once checked for the weight and left in the lru - let LRUR take care about them later. LRUR is to be left untouched, no weight logic, otherwise LU-5727 appears and OPEN locks do not get canceled. Xyratex-bug-id: MRP-2550 Signed-off-by: Vitaly Fertman <vitaly.fertman@seagate.com> Reviewed-on: http://review.whamcloud.com/14342 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6390 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Niu Yawei <yawei.niu@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_internal.h | 7 +++--- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 25 ++++++++++++++++++---- drivers/staging/lustre/lustre/osc/osc_request.c | 4 ++-- 3 files changed, 27 insertions(+), 9 deletions(-) commit 7b2d26b0af8bcc44fb3a279f28f380010890c4a4 Author: Niu Yawei <yawei.niu@intel.com> Date: Wed Mar 30 19:49:03 2016 -0400 staging/lustre/ldlm: revert changes to ldlm_cancel_aged_policy() The changes to ldlm_cancel_aged_policy() introduced from LU-4300 was incorrect. This patch revert this part of changes. Signed-off-by: Niu Yawei <yawei.niu@intel.com> Reviewed-on: http://review.whamcloud.com/12448 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5727 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 7d44333467a949b6ea4e21b5fb7618f97cc10ce0 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:49:02 2016 -0400 staging/lustre/ldlm: ELC picks locks in a safer policy Change the policy of ELC to pick locks that have no dirty pages, no page in writeback state, and no locked pages. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/9175 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4300 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Bobi Jam <bobijam@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/lustre_dlm.h | 13 ++++++---- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 28 +++++++++++++++------- drivers/staging/lustre/lustre/mdc/mdc_request.c | 4 ++-- drivers/staging/lustre/lustre/osc/osc_lock.c | 4 +++- drivers/staging/lustre/lustre/osc/osc_request.c | 19 ++++++--------- 5 files changed, 39 insertions(+), 29 deletions(-) commit 047d41bd71c5553bdd5bda56edbc77b8cbc1ae87 Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:49:01 2016 -0400 staging/lustre/llite: Remove unused vui_local_lock field vvp_io_setattr_lock is the only user that sets it, but it's never checked anywhere, so could go away. Also get rid of enum ccc_setattr_lock_type that becomes unused. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/vvp_internal.h | 12 ------------ drivers/staging/lustre/lustre/llite/vvp_io.c | 3 --- 2 files changed, 15 deletions(-) commit 5c5af0fce77e480930fbb17de458c327f405b965 Author: John Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:49:00 2016 -0400 staging/lustre/llite: Move several declarations to llite_internal.h Move several declarations between llite_internal.h and vvp_internal.h with the goal of reserving the latter header for functions that pertain to vvp_{device,object,page,...}. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/13714 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lustre/llite/llite_internal.h | 32 +++++++++++++++++-- drivers/staging/lustre/lustre/llite/vvp_internal.h | 36 ++-------------------- 2 files changed, 32 insertions(+), 36 deletions(-) commit 0097dcabe6d8f91d85f59b442cd162c02b8827f4 Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:48:59 2016 -0400 staging/lustre/llite: Move ll_dirent_type_get and make it static ll_dirent_type_get is only used in one place in llite/dir.c, so move it there. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 22 ++++++++++++++++++++++ drivers/staging/lustre/lustre/llite/lcommon_cl.c | 22 ---------------------- drivers/staging/lustre/lustre/llite/vvp_internal.h | 1 - 3 files changed, 22 insertions(+), 23 deletions(-) commit a37bec74c4aa12849c0e4733c86d9377ad15e58a Author: John Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:58 2016 -0400 staging/lustre/llite: Remove ccc_global_{init, fini}() Merge their contents into vvp_global_{init,fini}() and {init,exit}_lustre_lite(). Rename ccc_inode_fini_* to cl_inode_fini_*. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/13714 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/lcommon_cl.c | 53 +++++----------------- .../staging/lustre/lustre/llite/llite_internal.h | 7 +-- drivers/staging/lustre/lustre/llite/super25.c | 14 +++++- drivers/staging/lustre/lustre/llite/vvp_dev.c | 25 ++++++---- drivers/staging/lustre/lustre/llite/vvp_internal.h | 4 +- 5 files changed, 46 insertions(+), 57 deletions(-) commit 9acc4500b44723d12bec63519038ef820479eaad Author: John Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:57 2016 -0400 staging/lustre/llite: rename struct ccc_thread_info to vvp_thread_info struct ccc_thread_info is used in the VVP parts of llite so rename it struct vvp_thread_info. Rename supporting functions accordingly. Move init code from lcommon_cl.c to vvp_dev.c Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/13714 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 6 +-- drivers/staging/lustre/lustre/llite/glimpse.c | 6 +-- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 48 +--------------------- drivers/staging/lustre/lustre/llite/lcommon_misc.c | 4 +- drivers/staging/lustre/lustre/llite/llite_mmap.c | 2 +- drivers/staging/lustre/lustre/llite/rw.c | 4 +- drivers/staging/lustre/lustre/llite/rw26.c | 2 +- drivers/staging/lustre/lustre/llite/vvp_dev.c | 34 ++++++++++++++- drivers/staging/lustre/lustre/llite/vvp_internal.h | 34 +++++++-------- drivers/staging/lustre/lustre/llite/vvp_io.c | 8 ++-- 10 files changed, 68 insertions(+), 80 deletions(-) commit 9989a58ee1b1e47008870e60583cefc105402cfa Author: John Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:56 2016 -0400 staging/lustre/llite: Rename struct vvp_thread_info to ll_thread_info struct vvp_thread_info is used in the non-VVP parts of llite so rename it struct ll_thread_info. Rename supporting functions accordingly. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/13714 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 6 ++-- .../staging/lustre/lustre/llite/llite_internal.h | 30 ++++++++--------- drivers/staging/lustre/lustre/llite/rw.c | 6 ++-- drivers/staging/lustre/lustre/llite/vvp_dev.c | 38 +++++++++++----------- 4 files changed, 40 insertions(+), 40 deletions(-) commit 98eae5e71cdcf2954f9b022a78d0507878410df6 Author: John Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:55 2016 -0400 staging/lustre/llite: Rename struct ccc_grouplock to ll_grouplock And move the definition from vvp_internal.h to llite_internal.h. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/13714 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 16 ++++++------- drivers/staging/lustre/lustre/llite/lcommon_misc.c | 26 +++++++++++----------- .../staging/lustre/lustre/llite/llite_internal.h | 14 +++++++++++- drivers/staging/lustre/lustre/llite/vvp_internal.h | 11 --------- drivers/staging/lustre/lustre/llite/vvp_io.c | 2 +- 5 files changed, 35 insertions(+), 34 deletions(-) commit 103b8bda3e4be03e3d05ccb3c2ae5bb4a9182067 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:54 2016 -0400 staging/lustre/llite: rename ccc_req to vvp_req Rename struct ccc_req to struct vvp_req and move related functions from lustre/llite/lcommon_cl.c to the new file lustre/llite/vvp_req.c. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13377 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Bobi Jam <bobijam@hotmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 2 +- drivers/staging/lustre/lustre/llite/Makefile | 3 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 104 ------------------ drivers/staging/lustre/lustre/llite/vvp_dev.c | 8 +- drivers/staging/lustre/lustre/llite/vvp_internal.h | 18 +-- drivers/staging/lustre/lustre/llite/vvp_req.c | 121 +++++++++++++++++++++ 6 files changed, 136 insertions(+), 120 deletions(-) commit fee6eb5052fc394c6f40316052033cd69ee4ebc5 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:53 2016 -0400 staging/lustre/llite: move vvp_io functions to vvp_io.c Move all vvp_io related functions from lustre/llite/lcommon_cl.c to the sole file where they are used lustre/llite/vvp_io.c. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13376 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: Bobi Jam <bobijam@hotmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/lcommon_cl.c | 197 -------------------- .../staging/lustre/lustre/llite/llite_internal.h | 1 - drivers/staging/lustre/lustre/llite/vvp_internal.h | 22 +-- drivers/staging/lustre/lustre/llite/vvp_io.c | 198 ++++++++++++++++++++- 4 files changed, 196 insertions(+), 222 deletions(-) commit e0a8144b8c32031d37ff849fc07e6c5646e61198 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:52 2016 -0400 staging/lustre/llite: use vui prefix for struct vvp_io members Rename members of struct vvp_io to used to start with vui_ rather than cui_. Rename several instances of struct vvp_io * from cio to vio. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13363 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 20 ++-- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 34 +++--- drivers/staging/lustre/lustre/llite/llite_mmap.c | 6 +- drivers/staging/lustre/lustre/llite/rw.c | 24 ++-- drivers/staging/lustre/lustre/llite/rw26.c | 20 ++-- drivers/staging/lustre/lustre/llite/vvp_internal.h | 38 +++--- drivers/staging/lustre/lustre/llite/vvp_io.c | 131 +++++++++++---------- drivers/staging/lustre/lustre/llite/vvp_page.c | 4 +- 8 files changed, 139 insertions(+), 138 deletions(-) commit 10cdef73396c816e9844e467558c2f87776fc11f Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:51 2016 -0400 staging/lustre/llite: merge ccc_io and vvp_io Move the contents of struct vvp_io into struct ccc_io, delete the former, and rename the latter to struct vvp_io. Rename various ccc_io related functions to use vvp rather than ccc. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13351 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 2 +- drivers/staging/lustre/lustre/llite/file.c | 13 ++- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 60 +++--------- .../staging/lustre/lustre/llite/llite_internal.h | 72 --------------- drivers/staging/lustre/lustre/llite/llite_mmap.c | 12 +-- drivers/staging/lustre/lustre/llite/rw.c | 4 +- drivers/staging/lustre/lustre/llite/rw26.c | 10 +- drivers/staging/lustre/lustre/llite/vvp_dev.c | 2 +- drivers/staging/lustre/lustre/llite/vvp_internal.h | 81 +++++++++++++---- drivers/staging/lustre/lustre/llite/vvp_io.c | 101 ++++++++++----------- drivers/staging/lustre/lustre/llite/vvp_page.c | 2 +- 11 files changed, 144 insertions(+), 215 deletions(-) commit bc4320a9186ccace8887eac930b574491ae886c0 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:50 2016 -0400 staging/lustre:llite: remove struct ll_ra_read Ever since removal of the the unused function ll_ra_read_get(), the struct ll_ra_read members lrr_reader and lrr_linkage and the struct ll_readahead_state member ras_read_beads unnecessary so remove them. In struct vvp_io replace the struct ll_ra_read cui_bead member with cui_ra_start and cui_ra_count. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13347 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Bobi Jam <bobijam@hotmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lustre/llite/llite_internal.h | 30 +++--------- drivers/staging/lustre/lustre/llite/rw.c | 53 ++++++---------------- drivers/staging/lustre/lustre/llite/vvp_io.c | 31 ++++--------- 3 files changed, 28 insertions(+), 86 deletions(-) commit 4a4eee07f3f579e9ebc5b5db35214c3ada5c1378 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:49 2016 -0400 staging/lustre/llite: rename ccc_lock to vvp_lock Rename struct ccc_lock to struct vvp_lock and merge the CCC lock methods into the VVP lock methods. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13088 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 6 +-- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 52 ---------------------- drivers/staging/lustre/lustre/llite/vvp_dev.c | 6 +++ drivers/staging/lustre/lustre/llite/vvp_internal.h | 20 ++++----- drivers/staging/lustre/lustre/llite/vvp_lock.c | 38 +++++++++++++--- 5 files changed, 50 insertions(+), 72 deletions(-) commit 3a52f803382541569f30f225d6f868a36b4c3014 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:48 2016 -0400 staging/lustre/llite: rename ccc_page to vvp_page Rename struct ccc_page to struct vvp_page and remove obsolete CCC page methods. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13086 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 2 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 28 ------ drivers/staging/lustre/lustre/llite/llite_close.c | 12 +-- .../staging/lustre/lustre/llite/llite_internal.h | 4 +- drivers/staging/lustre/lustre/llite/rw.c | 14 +-- drivers/staging/lustre/lustre/llite/rw26.c | 10 +- drivers/staging/lustre/lustre/llite/vvp_dev.c | 12 +-- drivers/staging/lustre/lustre/llite/vvp_internal.h | 38 ++++---- drivers/staging/lustre/lustre/llite/vvp_io.c | 34 +++---- drivers/staging/lustre/lustre/llite/vvp_object.c | 2 +- drivers/staging/lustre/lustre/llite/vvp_page.c | 107 +++++++++++++-------- 11 files changed, 131 insertions(+), 132 deletions(-) commit 8c7b0e1a67471b621b2200eced63ec2ea6f3b8fa Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:47 2016 -0400 staging/lustre/llite: rename ccc_object to vvp_object Rename struct ccc_object to struct vvp_object and merge the CCC object methods into the VVP object methods. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13077 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 4 +- drivers/staging/lustre/lustre/llite/glimpse.c | 4 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 166 ++------------------- drivers/staging/lustre/lustre/llite/llite_close.c | 22 +-- .../staging/lustre/lustre/llite/llite_internal.h | 6 +- drivers/staging/lustre/lustre/llite/llite_lib.c | 4 +- drivers/staging/lustre/lustre/llite/llite_mmap.c | 16 +- drivers/staging/lustre/lustre/llite/rw.c | 4 +- drivers/staging/lustre/lustre/llite/rw26.c | 6 +- drivers/staging/lustre/lustre/llite/vvp_dev.c | 10 +- drivers/staging/lustre/lustre/llite/vvp_internal.h | 61 ++++---- drivers/staging/lustre/lustre/llite/vvp_io.c | 36 ++--- drivers/staging/lustre/lustre/llite/vvp_object.c | 121 +++++++++++++-- drivers/staging/lustre/lustre/llite/vvp_page.c | 40 ++--- .../staging/lustre/lustre/osc/osc_cl_internal.h | 2 +- 15 files changed, 231 insertions(+), 271 deletions(-) commit 3c95b8396758428405b445fe1faca936f1fe7dc5 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:46 2016 -0400 staging/lustre/llite: rename ccc_device to vvp_device Rename struct ccc_device to struct vvp_device and merge the CCC device methods into the VVP device methods. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/13075 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 2 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 104 +-------------------- .../staging/lustre/lustre/llite/llite_internal.h | 2 +- drivers/staging/lustre/lustre/llite/vvp_dev.c | 84 ++++++++++++++++- drivers/staging/lustre/lustre/llite/vvp_internal.h | 38 ++++---- 5 files changed, 102 insertions(+), 128 deletions(-) commit 0d345656ea4221cec2dd34a0c7a7ba3f0a8e9047 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:45 2016 -0400 staging/lustre/llite: merge lclient.h into llite/vvp_internal.h Move the definition of struct cl_client_cache to lustre/include/cl_object.h and move the rest of lustre/include/lclient.h in to lustre/llite/vvp_internal.h. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/12592 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5971 Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 36 ++ drivers/staging/lustre/lustre/include/lclient.h | 409 --------------------- drivers/staging/lustre/lustre/llite/glimpse.c | 1 - drivers/staging/lustre/lustre/llite/lcommon_cl.c | 2 - drivers/staging/lustre/lustre/llite/lcommon_misc.c | 2 +- .../staging/lustre/lustre/llite/llite_internal.h | 2 +- drivers/staging/lustre/lustre/llite/vvp_internal.h | 368 +++++++++++++++++- drivers/staging/lustre/lustre/llite/vvp_io.c | 1 + drivers/staging/lustre/lustre/llite/vvp_object.c | 1 + drivers/staging/lustre/lustre/llite/vvp_page.c | 1 + drivers/staging/lustre/lustre/lov/lov_obd.c | 1 - .../staging/lustre/lustre/osc/osc_cl_internal.h | 1 - 12 files changed, 408 insertions(+), 417 deletions(-) commit 902a34ad7242bb50e467a24855b544148989daf4 Author: Li Dongyang <dongyang.li@anu.edu.au> Date: Wed Mar 30 19:48:44 2016 -0400 staging/lustre/llite: make sure we do cl_page_clip on the last page When we are doing a partial IO on both first and last page, the logic currently only call cl_page_clip on the first page, which will end up with a incorrect i_size. Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au> Reviewed-on: http://review.whamcloud.com/11630 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5552 Reviewed-by: Ian Costello <costello.ian@gmail.com> Reviewed-by: Niu Yawei <yawei.niu@intel.com> Reviewed-by: Li Xi <pkuelelixi@gmail.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/vvp_io.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit d37dd10b71fd304289560901e81eddbe7defb351 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:43 2016 -0400 staging/lustre/llite: deadlock for page write Writing thread already locked page #1, and then wait for the Writeback bit of page #2; Ptlrpc thread is composing a write RPC, so it sets Writeback on page #2 and tries to lock page #1 to make it ready. Deadlocked. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/9036 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4540 Reviewed-by: wangdi <di.wang@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/rw26.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c11599b8d52d353f45b2dc05d58c48f9812ce6e9 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:42 2016 -0400 staging/lustre/llite: clip page correctly for vvp_io_commit_sync The original code was wrong which clipped page incorrectly for partial pages started with zero. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/8531 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4201 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: wangdi <di.wang@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/vvp_io.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 71a96a0539a8ebd8273bf627222e260968b82a16 Author: Bobi Jam <bobijam.xu@intel.com> Date: Wed Mar 30 19:48:41 2016 -0400 staging/lustre: update comments after cl_lock simplification Update comments to reflect current cl_lock situations. Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Reviewed-on: http://review.whamcloud.com/13137 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6046 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 130 +++------------------ .../staging/lustre/lustre/lov/lov_cl_internal.h | 13 --- 2 files changed, 19 insertions(+), 124 deletions(-) commit 06563b5606da7635b1fd5d121e7bd6d221e23db4 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:40 2016 -0400 staging/lustre/clio: cl_lock simplification In this patch, the cl_lock cache is eliminated. cl_lock is turned into a cacheless data container for the requirements of locks to complete the IO. cl_lock is created before I/O starts and destroyed when the I/O is complete. cl_lock depends on LDLM lock to fulfill lock semantics. LDLM lock is attached to cl_lock at OSC layer. LDLM lock is still cacheable. Two major methods are supported for cl_lock: clo_enqueue and clo_cancel. A cl_lock is enqueued by cl_lock_request(), which will call clo_enqueue() methods for each layer to enqueue the lock. At the LOV layer, if a cl_lock consists of multiple sub cl_locks, each sub locks will be enqueued correspondingly. At OSC layer, the lock enqueue request will tend to reuse cached LDLM lock; otherwise a new LDLM lock will have to be requested from OST side. cl_lock_cancel() must be called to release a cl_lock after use. clo_cancel() method will be called for each layer to release the resource held by this lock. At OSC layer, the reference count of LDLM lock, which is held at clo_enqueue time, is released. LDLM lock can only be canceled if there is no cl_lock using it. Signed-off-by: Bobi Jam <bobijam.xu@intel.com> Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/10858 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3259 Reviewed-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 590 +----- drivers/staging/lustre/lustre/include/lclient.h | 26 +- .../lustre/lustre/include/lustre/lustre_idl.h | 2 + drivers/staging/lustre/lustre/include/lustre_dlm.h | 1 + drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 1 + drivers/staging/lustre/lustre/ldlm/ldlm_lock.c | 3 +- drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 16 +- drivers/staging/lustre/lustre/ldlm/ldlm_resource.c | 1 + drivers/staging/lustre/lustre/llite/glimpse.c | 49 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 107 +- drivers/staging/lustre/lustre/llite/lcommon_misc.c | 14 +- drivers/staging/lustre/lustre/llite/rw26.c | 3 +- drivers/staging/lustre/lustre/llite/vvp_io.c | 19 +- drivers/staging/lustre/lustre/llite/vvp_lock.c | 25 +- drivers/staging/lustre/lustre/llite/vvp_object.c | 12 +- .../staging/lustre/lustre/lov/lov_cl_internal.h | 75 +- drivers/staging/lustre/lustre/lov/lov_dev.c | 5 +- drivers/staging/lustre/lustre/lov/lov_lock.c | 996 +--------- drivers/staging/lustre/lustre/lov/lov_object.c | 13 +- drivers/staging/lustre/lustre/lov/lovsub_lock.c | 383 ---- drivers/staging/lustre/lustre/obdclass/cl_io.c | 168 +- drivers/staging/lustre/lustre/obdclass/cl_lock.c | 2026 ++------------------ drivers/staging/lustre/lustre/obdclass/cl_object.c | 64 +- drivers/staging/lustre/lustre/obdclass/cl_page.c | 9 - .../staging/lustre/lustre/obdecho/echo_client.c | 60 +- drivers/staging/lustre/lustre/osc/osc_cache.c | 110 +- .../staging/lustre/lustre/osc/osc_cl_internal.h | 62 +- drivers/staging/lustre/lustre/osc/osc_internal.h | 10 +- drivers/staging/lustre/lustre/osc/osc_io.c | 41 +- drivers/staging/lustre/lustre/osc/osc_lock.c | 1618 ++++++---------- drivers/staging/lustre/lustre/osc/osc_object.c | 33 +- drivers/staging/lustre/lustre/osc/osc_page.c | 14 +- drivers/staging/lustre/lustre/osc/osc_request.c | 207 +- 33 files changed, 1203 insertions(+), 5560 deletions(-) commit e5c4e635c36354c0f4aa6a00b1787d15ee689528 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:39 2016 -0400 staging/lustre/clio: generalize cl_sync_io To make cl_sync_io interfaces not just wait for pages, but to be a generic synchronization mechanism. Also remove cl_io_cancel that became not used. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/8656 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4198 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 13 ++-- drivers/staging/lustre/lustre/obdclass/cl_io.c | 74 +++++++++++------------ drivers/staging/lustre/lustre/obdclass/cl_page.c | 2 +- 3 files changed, 44 insertions(+), 45 deletions(-) commit bb41292b4c4e956b5b776970d28630f04c4dd609 Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:48:38 2016 -0400 staging/lustre: Remove struct ll_iattr This was a compat code from the time it had ia_attr_flags. Instead convert all the cryptic callers that did ((struct ll_iattr *)&op_data->op_attr)->ia_attr_flags into direct access to op_data->op_attr_flags This also makes lustre/include/linux/obd.h not needed anymore, so remove it. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/linux/obd.h | 58 ----------------------- drivers/staging/lustre/lustre/include/obd.h | 2 +- drivers/staging/lustre/lustre/llite/file.c | 4 +- drivers/staging/lustre/lustre/llite/llite_lib.c | 2 +- drivers/staging/lustre/lustre/mdc/mdc_lib.c | 3 +- drivers/staging/lustre/lustre/obdclass/obdo.c | 3 +- 6 files changed, 6 insertions(+), 66 deletions(-) commit 1929c433854c7673fd2d983ef8cf15cf13306d5c Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:37 2016 -0400 staging/lustre/llite: remove some cl wrappers In llite remove the wrapper functions and macros: cl_i2info() cl_i2sbi() cl_iattr2fd() cl_inode_info cl_inode_mode() cl_inode_{a,m,c}time() cl_isize_{read,write,write_nolock}() Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/12850 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/dir.c | 2 +- drivers/staging/lustre/lustre/llite/file.c | 8 ++-- drivers/staging/lustre/lustre/llite/glimpse.c | 10 ++--- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 45 +++++++++++----------- .../staging/lustre/lustre/llite/llite_internal.h | 32 --------------- drivers/staging/lustre/lustre/llite/llite_lib.c | 2 +- drivers/staging/lustre/lustre/llite/vvp_object.c | 4 +- 7 files changed, 35 insertions(+), 68 deletions(-) commit 7d53d8f426cacdb7352e91957721b4a9962b222a Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:36 2016 -0400 staging/lustre/obd: remove struct client_obd_lock Remove the definition of struct client_obd_lock and the functions client_obd_list_{init,lock,unlock,done}(). Use spinlock_t for the cl_{loi,lru}_list_lock members of struct client_obd and call spin_{lock,unlock}() directly. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/fld/fld_request.c | 14 ++--- drivers/staging/lustre/lustre/include/linux/obd.h | 67 ---------------------- drivers/staging/lustre/lustre/include/obd.h | 9 +-- drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 4 +- drivers/staging/lustre/lustre/mdc/lproc_mdc.c | 8 +-- drivers/staging/lustre/lustre/mdc/mdc_lib.c | 18 +++--- drivers/staging/lustre/lustre/osc/lproc_osc.c | 38 ++++++------ drivers/staging/lustre/lustre/osc/osc_cache.c | 50 ++++++++-------- .../staging/lustre/lustre/osc/osc_cl_internal.h | 2 +- drivers/staging/lustre/lustre/osc/osc_page.c | 24 ++++---- drivers/staging/lustre/lustre/osc/osc_request.c | 46 +++++++-------- 11 files changed, 105 insertions(+), 175 deletions(-) commit 019e93516dcfc98efda51ccb8f7e0e758fda8ded Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:35 2016 -0400 staging/lustre/lmv: remove lmv_init_{lock,unlock}() In struct lmv_obd rename the init_mutex member to lmv_init_mutex. Remove the compat macros lmv_init_{lock,unlock}() and use mutex_{lock,unlock}(&lmv->lmv_init_mutex) instead. Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/12115 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/obd.h | 2 +- drivers/staging/lustre/lustre/lmv/lmv_internal.h | 3 --- drivers/staging/lustre/lustre/lmv/lmv_obd.c | 24 ++++++++++++------------ 3 files changed, 13 insertions(+), 16 deletions(-) commit d2995737bb6da9fcb9f84bf820322e351df2813b Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:34 2016 -0400 staging/lustre/llite: remove lli_lvb In struct ll_inode_info remove the struct ost_lvb lli_lvb member and replace it with obd_time lli_{a,m,c}time. Rename ll_merge_lvb() to ll_merge_attr(). Remove cl_merge_lvb() and replace calls to it with calls to ll_merge_attr(). Signed-off-by: John L. Hammond <john.hammond@intel.com> Reviewed-on: http://review.whamcloud.com/12849 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-2675 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/file.c | 65 ++++++++++++---------- drivers/staging/lustre/lustre/llite/glimpse.c | 6 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 2 +- .../staging/lustre/lustre/llite/llite_internal.h | 11 ++-- drivers/staging/lustre/lustre/llite/llite_lib.c | 6 +- drivers/staging/lustre/lustre/llite/vvp_io.c | 2 +- 6 files changed, 48 insertions(+), 44 deletions(-) commit fd7444fecaa0c4516d68fdbedf570b8bded60bc1 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:33 2016 -0400 staging/lustre/clio: optimize read ahead code It used to check each page in the readahead window is covered by a lock underneath, now cpo_page_is_under_lock() provides @max_index to help decide the maximum ra window. @max_index can be modified by OSC to extend the maximum lock region, to align stripe boundary at LOV, and to make sure the readahead region at least covers read region at LLITE layer. After this is done, usually readahead code calls cpo_page_is_under_lock() for each stripe. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/8523 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 6 +- drivers/staging/lustre/lustre/include/lclient.h | 2 - drivers/staging/lustre/lustre/llite/lcommon_cl.c | 28 ------ .../staging/lustre/lustre/llite/llite_internal.h | 7 +- drivers/staging/lustre/lustre/llite/lproc_llite.c | 1 + drivers/staging/lustre/lustre/llite/rw.c | 103 ++++++++++++++------- drivers/staging/lustre/lustre/llite/vvp_io.c | 23 +---- drivers/staging/lustre/lustre/llite/vvp_page.c | 26 ++++-- .../staging/lustre/lustre/lov/lov_cl_internal.h | 1 + drivers/staging/lustre/lustre/lov/lov_internal.h | 2 + drivers/staging/lustre/lustre/lov/lov_io.c | 2 +- drivers/staging/lustre/lustre/lov/lov_offset.c | 13 +++ drivers/staging/lustre/lustre/lov/lov_page.c | 60 ++++++++++-- drivers/staging/lustre/lustre/lov/lovsub_page.c | 4 +- drivers/staging/lustre/lustre/obdclass/cl_io.c | 2 +- drivers/staging/lustre/lustre/obdclass/cl_page.c | 39 ++++++-- .../staging/lustre/lustre/obdecho/echo_client.c | 2 +- drivers/staging/lustre/lustre/osc/osc_page.c | 10 +- 18 files changed, 208 insertions(+), 123 deletions(-) commit 7addf402c1171e875109bb1567171c4c3f8f8229 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:32 2016 -0400 staging/lustre/clio: remove stackable cl_page completely >From now on, cl_page becomes one to one mapping of vmpage. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7895 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 43 ++--- drivers/staging/lustre/lustre/include/lclient.h | 7 +- drivers/staging/lustre/lustre/llite/lcommon_cl.c | 12 +- .../staging/lustre/lustre/llite/llite_internal.h | 4 + drivers/staging/lustre/lustre/llite/rw.c | 7 +- drivers/staging/lustre/lustre/llite/rw26.c | 35 +--- drivers/staging/lustre/lustre/llite/vvp_internal.h | 2 +- drivers/staging/lustre/lustre/llite/vvp_io.c | 45 +++-- drivers/staging/lustre/lustre/llite/vvp_page.c | 23 +-- .../staging/lustre/lustre/lov/lov_cl_internal.h | 14 +- drivers/staging/lustre/lustre/lov/lov_io.c | 8 +- drivers/staging/lustre/lustre/lov/lov_object.c | 32 +++- drivers/staging/lustre/lustre/lov/lov_page.c | 104 +++------- drivers/staging/lustre/lustre/lov/lovsub_page.c | 2 +- drivers/staging/lustre/lustre/obdclass/cl_io.c | 63 +----- drivers/staging/lustre/lustre/obdclass/cl_object.c | 4 +- drivers/staging/lustre/lustre/obdclass/cl_page.c | 213 +++++---------------- .../staging/lustre/lustre/obdecho/echo_client.c | 22 +-- drivers/staging/lustre/lustre/osc/osc_cache.c | 59 +++--- .../staging/lustre/lustre/osc/osc_cl_internal.h | 12 +- drivers/staging/lustre/lustre/osc/osc_io.c | 41 ++-- drivers/staging/lustre/lustre/osc/osc_page.c | 33 ++-- 22 files changed, 257 insertions(+), 528 deletions(-) commit f56b355ca8ae0a2312da094630790b923b00d8b4 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:31 2016 -0400 staging/lustre/osc: add weight function for DLM lock Use weigh_ast to decide if a lock covers any pages. In recovery, weigh_ast will be used to decide if a DLM read lock covers any locked pages, or it will be canceled instead being recovered. The problem with the original implementation is that it attached each osc_page to an osc_lock also changed lock state to add every pages for readahead. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7894 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/ldlm/ldlm_request.c | 9 +- .../staging/lustre/lustre/osc/osc_cl_internal.h | 20 ---- drivers/staging/lustre/lustre/osc/osc_internal.h | 3 +- drivers/staging/lustre/lustre/osc/osc_lock.c | 113 +++++++++++++++------ drivers/staging/lustre/lustre/osc/osc_page.c | 78 +------------- drivers/staging/lustre/lustre/osc/osc_request.c | 5 +- 6 files changed, 89 insertions(+), 139 deletions(-) commit 77605e41a26f22343db90d6434970a1800e5e8b5 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:30 2016 -0400 staging/lustre/clio: add pages into writeback cache in batches in ll_write_end(), instead of adding the page into writeback cache directly, it will be held in a page list. After enough pages have been collected, issue them all with cio_commit_async(). Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7893 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 77 ++-- drivers/staging/lustre/lustre/include/lclient.h | 6 + drivers/staging/lustre/lustre/llite/file.c | 11 +- .../staging/lustre/lustre/llite/llite_internal.h | 8 +- drivers/staging/lustre/lustre/llite/rw.c | 186 ++------ drivers/staging/lustre/lustre/llite/rw26.c | 210 +++++++-- drivers/staging/lustre/lustre/llite/vvp_internal.h | 10 +- drivers/staging/lustre/lustre/llite/vvp_io.c | 490 +++++++++++---------- .../staging/lustre/lustre/lov/lov_cl_internal.h | 2 + drivers/staging/lustre/lustre/lov/lov_io.c | 219 ++++----- drivers/staging/lustre/lustre/lov/lov_page.c | 28 -- drivers/staging/lustre/lustre/obdclass/cl_io.c | 108 ++--- drivers/staging/lustre/lustre/obdclass/cl_page.c | 38 -- .../staging/lustre/lustre/obdecho/echo_client.c | 25 +- drivers/staging/lustre/lustre/osc/osc_cache.c | 14 +- .../staging/lustre/lustre/osc/osc_cl_internal.h | 2 + drivers/staging/lustre/lustre/osc/osc_internal.h | 6 + drivers/staging/lustre/lustre/osc/osc_io.c | 160 ++++--- drivers/staging/lustre/lustre/osc/osc_page.c | 32 +- drivers/staging/lustre/lustre/osc/osc_request.c | 56 ++- 20 files changed, 792 insertions(+), 896 deletions(-) commit 3c361c1c6f64a675ced590df4a68956020de4a93 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:29 2016 -0400 staging/lustre/obdclass: Add a preallocated percpu cl_env This change adds support for a single preallocated cl_env per CPU which can be used in circumstances where reschedule is not possible. Currently this interface is only used by the ll_releasepage function. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Signed-off-by: Prakash Surya <surya1@llnl.gov> Reviewed-on: http://review.whamcloud.com/8174 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Bobi Jam <bobijam@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 12 +++ drivers/staging/lustre/lustre/llite/rw26.c | 54 +++++++---- drivers/staging/lustre/lustre/obdclass/cl_lock.c | 1 - drivers/staging/lustre/lustre/obdclass/cl_object.c | 107 +++++++++++++++++++++ drivers/staging/lustre/lustre/obdclass/cl_page.c | 1 - 5 files changed, 152 insertions(+), 23 deletions(-) commit d9d47901dfbec3f7e057c4d31ecbe39c8eaec991 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:28 2016 -0400 staging/lustre/clio: collapse layer of cl_page Move radix tree to osc layer to for performance improvement. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7892 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Bobi Jam <bobijam@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 36 +-- drivers/staging/lustre/lustre/llite/rw.c | 2 +- drivers/staging/lustre/lustre/llite/rw26.c | 4 - drivers/staging/lustre/lustre/llite/vvp_dev.c | 47 +-- drivers/staging/lustre/lustre/llite/vvp_io.c | 1 - drivers/staging/lustre/lustre/llite/vvp_object.c | 13 + drivers/staging/lustre/lustre/llite/vvp_page.c | 36 +-- drivers/staging/lustre/lustre/lov/lov_object.c | 9 +- drivers/staging/lustre/lustre/lov/lov_page.c | 29 +- drivers/staging/lustre/lustre/obdclass/cl_io.c | 1 + drivers/staging/lustre/lustre/obdclass/cl_lock.c | 131 +------- drivers/staging/lustre/lustre/obdclass/cl_object.c | 47 +-- drivers/staging/lustre/lustre/obdclass/cl_page.c | 354 ++------------------- drivers/staging/lustre/lustre/osc/osc_cache.c | 207 +++++++++++- .../staging/lustre/lustre/osc/osc_cl_internal.h | 27 +- drivers/staging/lustre/lustre/osc/osc_io.c | 14 +- drivers/staging/lustre/lustre/osc/osc_lock.c | 10 +- drivers/staging/lustre/lustre/osc/osc_object.c | 2 + drivers/staging/lustre/lustre/osc/osc_page.c | 28 +- 19 files changed, 394 insertions(+), 604 deletions(-) commit 2579d8d01759aae407d3645be5125f8dd436757c Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:27 2016 -0400 staging/lustre/osc: to drop LRU pages with cl_lru_work This way we can drop it async. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7891 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Lai Siyao <lai.siyao@intel.com> Reviewed-by: Bobi Jam <bobijam@gmail.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/obd.h | 1 + drivers/staging/lustre/lustre/llite/lproc_llite.c | 9 ++++- drivers/staging/lustre/lustre/osc/lproc_osc.c | 12 +++++- .../staging/lustre/lustre/osc/osc_cl_internal.h | 1 + drivers/staging/lustre/lustre/osc/osc_internal.h | 3 +- drivers/staging/lustre/lustre/osc/osc_page.c | 45 ++++++++++++++-------- drivers/staging/lustre/lustre/osc/osc_request.c | 23 ++++++++++- drivers/staging/lustre/lustre/ptlrpc/ptlrpcd.c | 16 ++++++-- 8 files changed, 85 insertions(+), 25 deletions(-) commit 5196e42c372fc33551c836d9d6d0a0883b4d2d19 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:26 2016 -0400 staging/lustre/osc: Adjustment on osc LRU for performance Add and discard pages from LRU in batch. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7890 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Niu Yawei <yawei.niu@intel.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/llite/llite_lib.c | 5 +- drivers/staging/lustre/lustre/osc/lproc_osc.c | 2 +- drivers/staging/lustre/lustre/osc/osc_cache.c | 2 + .../staging/lustre/lustre/osc/osc_cl_internal.h | 26 +- drivers/staging/lustre/lustre/osc/osc_internal.h | 3 +- drivers/staging/lustre/lustre/osc/osc_io.c | 51 ++++ drivers/staging/lustre/lustre/osc/osc_page.c | 301 +++++++++++---------- drivers/staging/lustre/lustre/osc/osc_request.c | 2 +- 8 files changed, 235 insertions(+), 157 deletions(-) commit 26f98e82e7ef3e1ecad0a0b83020dd19fc9ff822 Author: Jinshan Xiong <jinshan.xiong@intel.com> Date: Wed Mar 30 19:48:25 2016 -0400 staging/lustre: Reintroduce global env list This reverts a patch that was merged before lustre client was introduced into the stagign tree, so it's not in the history. The performance dropped a lot when memory reclaim process kicked in as ll_releasepage() was called to destroy lustre pages. It turned out that big overhead to allocate cl_env and keys on the fly so we have to revert this patch. The original problem for the reverted patch would be solved in a follow on patch instead. Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com> Reviewed-on: http://review.whamcloud.com/7888 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3321 Reviewed-by: Niu Yawei <yawei.niu@intel.com> Reviewed-by: Lai Siyao <lai.siyao@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/include/cl_object.h | 1 + drivers/staging/lustre/lustre/llite/lcommon_misc.c | 3 +- drivers/staging/lustre/lustre/llite/llite_lib.c | 2 + drivers/staging/lustre/lustre/obdclass/cl_object.c | 90 ++++++++++++++++++++-- drivers/staging/lustre/lustre/obdclass/lu_object.c | 2 + 5 files changed, 92 insertions(+), 6 deletions(-) commit a7d516d6e9b5ac2db87f5b98c67e599f95d3e512 Author: John L. Hammond <john.hammond@intel.com> Date: Wed Mar 30 19:48:24 2016 -0400 staging/lustre: merge lclient/*.c into llite/ Separate lclient was necessary to be shared between different client implementations, make no sense to have them separate in Linux kernel. Signed-off-by: John L. Hammond <john.hammond@intel.com> Based-on: http://review.whamcloud.com/10171 Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/lclient/glimpse.c | 270 ----- drivers/staging/lustre/lustre/lclient/lcommon_cl.c | 1203 ------------------- .../staging/lustre/lustre/lclient/lcommon_misc.c | 200 ---- drivers/staging/lustre/lustre/llite/Makefile | 2 +- drivers/staging/lustre/lustre/llite/glimpse.c | 273 +++++ drivers/staging/lustre/lustre/llite/lcommon_cl.c | 1209 ++++++++++++++++++++ drivers/staging/lustre/lustre/llite/lcommon_misc.c | 200 ++++ 7 files changed, 1683 insertions(+), 1674 deletions(-) commit 616387e86d531d1d29173aabb8adefb20d316d96 Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:48:23 2016 -0400 staging/lustre: Get rid of CFS_PAGE_MASK CFS_PAGE_MASK is the same as PAGE_MASK, so get rid of it. We are replacing it with PAGE_MASK instead of PAGE_CACHE_MASK because PAGE_CACHE_* stuff is apparently going away. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/linux/linux-mem.h | 1 - .../lustre/lnet/libcfs/linux/linux-crypto.c | 2 +- drivers/staging/lustre/lnet/selftest/brw_test.c | 2 +- drivers/staging/lustre/lustre/llite/llite_mmap.c | 4 ++-- drivers/staging/lustre/lustre/llite/rw26.c | 8 ++++---- drivers/staging/lustre/lustre/llite/vvp_io.c | 6 +++--- drivers/staging/lustre/lustre/lmv/lmv_obd.c | 2 +- drivers/staging/lustre/lustre/obdclass/class_obd.c | 2 +- .../staging/lustre/lustre/obdecho/echo_client.c | 6 +++--- drivers/staging/lustre/lustre/osc/osc_cache.c | 4 ++-- drivers/staging/lustre/lustre/osc/osc_request.c | 24 +++++++++++----------- drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c | 2 +- drivers/staging/lustre/lustre/ptlrpc/sec_plain.c | 2 +- 13 files changed, 32 insertions(+), 33 deletions(-) commit 81108182bba96fcc738ddc912e9fcbb5afe01ef0 Author: Oleg Drokin <green@linuxhacker.ru> Date: Wed Mar 30 19:48:22 2016 -0400 staging/lustre/obdclass: limit lu_site hash table size Allocating a big hash table using the formula for osd does not really work for clients. We will create new hash table for each mount on a single client which is a lot of memory more than expected. This patch limits the hash table up to 8M which has 524288 entries Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au> Reviewed-on: http://review.whamcloud.com/18048 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7689 Reviewed-by: Fan Yong <fan.yong@intel.com> Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com> Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/lu_object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 56e18f8cdf057a8c6e68906ff584cf655ea1e328 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Tue Mar 29 18:12:40 2016 -0400 staging: xgifb: fix block comments fix checkpatch.pl warning about 'Block comments use a trailing */ on a separate line' and 'Block comments use * on subsequent lines' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/vb_init.c | 13 ++-- drivers/staging/xgifb/vb_setmode.c | 3 +- drivers/staging/xgifb/vb_table.h | 135 ++++++++++++++++++++++--------------- 3 files changed, 88 insertions(+), 63 deletions(-) commit 04c57f4501909b60353031cfe5b991751d745658 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Mar 24 14:38:38 2016 +0100 posix_acl: Unexport acl_by_type and make it static acl_by_type(inode, type) returns a pointer to either inode->i_acl or inode->i_default_acl depending on type. This is useful in fs/posix_acl.c, but should never have been visible outside that file. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/posix_acl.c | 3 +-- include/linux/posix_acl.h | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) commit b8a7a3a6674725d7ca0ff6e322f6c1cab6e6a11d Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Mar 24 14:38:37 2016 +0100 posix_acl: Inode acl caching fixes When get_acl() is called for an inode whose ACL is not cached yet, the get_acl inode operation is called to fetch the ACL from the filesystem. The inode operation is responsible for updating the cached acl with set_cached_acl(). This is done without locking at the VFS level, so another task can call set_cached_acl() or forget_cached_acl() before the get_acl inode operation gets to calling set_cached_acl(), and then get_acl's call to set_cached_acl() results in caching an outdate ACL. Prevent this from happening by setting the cached ACL pointer to a task-specific sentinel value before calling the get_acl inode operation. Move the responsibility for updating the cached ACL from the get_acl inode operations to get_acl(). There, only set the cached ACL if the sentinel value hasn't changed. The sentinel values are chosen to have odd values. Likewise, the value of ACL_NOT_CACHED is odd. In contrast, ACL object pointers always have an even value (ACLs are aligned in memory). This allows to distinguish uncached ACLs values from ACL objects. In addition, switch from guarding inode->i_acl and inode->i_default_acl upates by the inode->i_lock spinlock to using xchg() and cmpxchg(). Filesystems that do not want ACLs returned from their get_acl inode operations to be cached must call forget_cached_acl() to prevent the VFS from doing so. (Patch written by Al Viro and Andreas Gruenbacher.) Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/9p/acl.c | 2 +- fs/btrfs/acl.c | 3 -- fs/ceph/acl.c | 2 + fs/ext2/acl.c | 3 -- fs/ext4/acl.c | 3 -- fs/f2fs/acl.c | 3 -- fs/hfsplus/posix_acl.c | 3 -- fs/inode.c | 4 +- fs/jffs2/acl.c | 2 - fs/jfs/acl.c | 2 - fs/namei.c | 2 +- fs/nfs/nfs3acl.c | 43 +++++++++++++++++++- fs/ocfs2/dlmglue.c | 3 ++ fs/posix_acl.c | 103 ++++++++++++++++++++++++++++++++---------------- fs/reiserfs/xattr_acl.c | 6 +-- fs/xfs/xfs_acl.c | 20 +++------- include/linux/fs.h | 12 ++++++ 17 files changed, 138 insertions(+), 78 deletions(-) commit 88ae4ab9802eaa8e400e611f85883143d89d6b61 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon Mar 28 00:43:29 2016 -0400 ecryptfs_lookup(): try either only encrypted or plaintext name Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ecryptfs/inode.c | 55 +++++++++++++++++++---------------------------------- 1 file changed, 20 insertions(+), 35 deletions(-) commit b1168a928277149e1c606763d76ff5c728988755 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Mon Mar 28 00:30:35 2016 -0400 ecryptfs: avoid multiple aliases for directories ecryptfs_lookup_interpose should use d_splice_alias(), not d_add() (and return struct dentry * rather than int). Get rid of redundant dir_inode argument, while we are touching it... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/ecryptfs/inode.c | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit 3996ae3482935fb531e522b3f23248a6581015a8 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Mar 29 13:48:57 2016 +0900 staging: dgnc: fix Logical continuations. fix checkpatch.pl warning about 'Logical continuations should be on the previous line' Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit ffe4f329460ded65b339522abcbdc7aa18021dc9 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Mar 29 13:48:31 2016 +0900 staging: dgnc: fix 'line over 80 characters' fix checkpatch.pl warning about 'line over 80 characters'. I just moved all line comment to above if statement. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit a1115c9f7826143600d12f72cda7bb0be404c842 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Mar 29 13:47:59 2016 +0900 staging: dgnc: remove parenthesis around the CONST | remove parenthesis around the CONST | CONST. It will be also fixed checkpatch.pl warning about "Alignment should match open parenthesis" becasue parenthesis were removed by this patch. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit d8bf4bee49728e31b1d225630c39714a6c42648c Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Mon Mar 28 13:54:15 2016 +0900 staging: dgnc: replace dgnc_offset_table with bit shift. the dgnc_offset_table has a same value with (1 << port). So I tried to replace dgnc_offset_table array with 1 << port. And also there are redundant assignments(tmp and current_port) inside while loop for checking uart port, and remove them. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 44 +++++++++++------------------------------ 1 file changed, 12 insertions(+), 32 deletions(-) commit e078cb2a64fd588557ef2dec573622699a05d642 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 12:00:29 2016 -0700 staging: comedi: amplc_pci224: Prefer using the BIT macro Fix the checkpatch.pl issues by using the BIT macro and defining some macros for the multi-bit fields. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci224.c | 71 ++++++++++++++------------- 1 file changed, 38 insertions(+), 33 deletions(-) commit 623211de9a3bfd0fabc81f8bff8c79fd9e4944ba Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:45:19 2016 -0700 staging: comedi: amplc_pci263: define the register map For completeness, define the registers used by this driver and remove the magic numbers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci263.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) commit 1ee79c8ee88e74fdd778c024caf84d741a134409 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:45:18 2016 -0700 staging: comedi: amplc_pci263: tidy up digital output subdevice init For aesthetics, add some whitespace to the digital output subdevice initialization. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci263.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit db94bfad3b05c9a3cd5c151018db142b07486d02 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:45:17 2016 -0700 staging: comedi: amplc_pci263: fix block comments Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci263.c | 60 +++++++++++++-------------- 1 file changed, 30 insertions(+), 30 deletions(-) commit 7be7cd10ade121cd5363c5f8790638b177b5e9dd Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 10:47:25 2016 -0700 staging: comedi: drivers: fix possible bug in comedi_handle_events() This function assumes that the async subdevice has a cancel() function. It looks like all the current comedi drivers implement a cancel() for the async subdevices except for the dt2814 analog input usbdevice. Fix comedi_handle_events() so it does not try to call a non-existent cancel() function. Add a dev_warn() to __comedi_device_postconfig_async() so that any new driver authors will be reminded to implement the cancel(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit f91852ce61339ca0ca557c7ce5838f3a774a1bf5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 10:47:24 2016 -0700 staging: comedi: drivers: tidy up insn_rw_emulate_bits() Tidy up this function and fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers.c | 35 ++++++++++++++++------------------- 1 file changed, 16 insertions(+), 19 deletions(-) commit 9bc9e60e4f48b2917718d0dcf8a3cbb9f7687dd7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 12:34:53 2016 -0700 staging: comedi: c6xdigio: Prefer using the BIT macro Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/c6xdigio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit e76415f47f9f4ec4f0289f8194eae0726dc27dfd Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 12:19:22 2016 -0700 staging: comedi: amplc_pci230: Prefer kernel type 'u64' over 'uint64_t' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci230.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 61ac7ccfb5cbe59ee940f0a7b3ad4fd3e3ce8c37 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 12:19:21 2016 -0700 staging: comedi: amplc_pci230: Prefer using the BIT macro Fix the checkpatch.pl issues by using the BIT macro and defining some macros for the multi-bit fields. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci230.c | 141 ++++++++++++++------------ 1 file changed, 74 insertions(+), 67 deletions(-) commit 6050b1cfc66c421546880c0219cbce9102800099 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:09:49 2016 -0700 staging: comedi: amplc_dio200_common: document spinlock definition Fix the checkpatch.pl issue: CHECK: spinlock_t definition without comment Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_dio200_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eecbf23476d33c79c9315277ed2b2e17ef34a955 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:09:48 2016 -0700 staging: comedi: amplc_dio200_common: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_dio200_common.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 05380cde47247daec0956fb818c63093a92d5585 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:36:55 2016 -0700 staging: comedi: amplc_pc263: fix block comments Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pc263.c | 62 ++++++++++++++-------------- 1 file changed, 31 insertions(+), 31 deletions(-) commit 1b50167146139402be0924aab55062b391cb8956 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:36:58 2016 -0700 staging: comedi: amplc_pc263: define the register map For completeness, define the registers used by this driver and remove the magic numbers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pc263.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) commit d69917a64ae78c27348164e7cabc03a838df3e40 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:36:56 2016 -0700 staging: comedi: amplc_pc263: tidy up comedi_driver definition For aesthetics, add some whitespace to the comedi_driver definition. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pc263.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 9f37d399f19f9efbcecafe647ba3cf3c9653bb05 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 30 11:36:57 2016 -0700 staging: comedi: amplc_pc263: tidy up digital output subdevice init For aesthetics, add some whitespace to the digital output subdevice initialization. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pc263.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 411059f701f0e8d23b5b5a94f9e43df7e32251f8 Author: Ben Marsh <bmarsh94@gmail.com> Date: Mon Mar 28 19:26:19 2016 +0200 Staging: android: change memory allocation style in ion.c Chnages memory allocation style in order to silence a checkpatch.pl warning. Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/ion/ion.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 9f6b68774f29692f3e5b87e8eae29da61c3b1171 Author: Rob Herring <robh@kernel.org> Date: Thu Mar 24 15:58:17 2016 -0500 android: remove timed output/gpio driver timed_output was only used by the Android vibrator HAL which has now learned how to use LED triggers instead[1]. Any users of it in AOSP are on ancient kernels. Adding support for LED triggers is purely DT changes and proper kernel config. [1] https://android.googlesource.com/platform%2Fhardware%2Flibhardware/+/61701df363310a5cbd95e3e1638baa9526e42c9b Cc: John Stultz <john.stultz@linaro.org> Cc: "Arve Hjønnevåg" <arve@android.com> Cc: Riley Andrews <riandrews@android.com> Signed-off-by: Rob Herring <robh@kernel.org> Acked-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/android/Kconfig | 14 --- drivers/staging/android/Makefile | 2 - drivers/staging/android/timed_gpio.c | 166 --------------------------------- drivers/staging/android/timed_gpio.h | 33 ------- drivers/staging/android/timed_output.c | 110 ---------------------- drivers/staging/android/timed_output.h | 37 -------- 6 files changed, 362 deletions(-) commit 64938182e7836650feeb9b2b9dadd510ed4b0dad Author: David Kershner <david.kershner@unisys.com> Date: Wed Mar 30 20:38:49 2016 -0400 staging: unisys: remove wmb() in visordriver_remove_device Don't need to have a wmb() in visordriver_remove_device. Also removed an unnecessary check for drv being null. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) commit 527486ee8fbb28fabd8fa51ddd4339a37ee15c5c Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 30 10:41:46 2016 -0400 staging: unisys: removed unused channel_bytes attribute The channel_bytes attribute in the visor_device struct was meant to keep track of the number of bytes in the associated channel of the device. Not only is the variable never set nor used, but the information can already be accessed by referencing visor_device->visorchannel->nbytes. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 1 - 1 file changed, 1 deletion(-) commit 03d0d045c8884df5e0576d3eb7dbf53fa95fe7ce Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 30 10:41:45 2016 -0400 staging: unisys: removed 'visor_device.devnodes' field The 'visor_device.devnodes' field was used for displaying driver version information through the devmajorminor sysfs attribute, which has recently been removed, rendering the field unnecessary. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 6 ------ 1 file changed, 6 deletions(-) commit 240f7ec1f49aef8fe28d13ad52ced6c28ccc8f02 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 30 10:41:44 2016 -0400 staging: unisys: removed unused visor_device.type field The visor_device.type field was included when preparing to remove the device_info struct. However, it's not used at all, and was already redundant by the existence of the 'visor_device.channel_type_guid' field. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 1 - 1 file changed, 1 deletion(-) commit 378d638a89b67bf2bb2de34786f3a27b41203357 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 30 10:41:43 2016 -0400 staging: unisys: include: removed unused 'visor_device.description' The 'description' variable in visor_device was added in preparation for removing the 'device_info' struct when the uislib files were removed. That attribute is never accessed nor set, and the 'name' attribute provides enough information to correctly identify the driver, it is not needed. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 1 - 1 file changed, 1 deletion(-) commit a0fcb63586a57560de28c333127bb0e36c01c70c Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 30 10:41:42 2016 -0400 staging: unisys: removed unused switch/port info from visorbus.h The fields 'switch_no' and 'internal_port_no' were originally added to the visor_device struct in preparation of removing the 'device_info' struct in the now removed 'uislib' library. After the refactoring was complete, these attributes are not referenced anywhere, and there are no plans to use them. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/visorbus.h | 2 -- 1 file changed, 2 deletions(-) commit 630e413dc24da0c2373fd7592aeb0e08cea71cd1 Author: Petr Kulhavy <petr@barix.com> Date: Tue Mar 29 09:39:35 2016 +0200 ASoC: tas571x: chip type detection via I2C name The chip selection was relying only on DT. It was not possible to use the driver without DT. This adds the chip type detection from the I2C name, which allows to use the driver from the platform driver without DT. Signed-off-by: Petr Kulhavy <petr@barix.com> Reviewed-by: Kevin Cernekee <cernekee@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tas571x.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) commit 92eb4f62cbac0211e43ee4a6715ee2ea43167e88 Author: Jeeja KP <jeeja.kp@intel.com> Date: Fri Mar 11 10:12:56 2016 +0530 ASoC: Intel: Bxtn: Add Broxton DSP support Broxton DSP is mostly similar to Skylake one but with subtle differences like no Code Load DMA and uses HDA DMA for code loading, DSP D0 and D3 sequences are different. These changes are comprehended by adding different DSP power up and down handlers, and new loader ops and also adding prepare and trigger which HDA DSP DMA requires Signed-off-by: Jeeja KP <jeeja.kp@intel.com> Signed-off-by: Jayachandran B <jayachandran.b@intel.com> Signed-off-by: GuruprasadX Pawse <guruprasadx.pawse@intel.com> Signed-off-by: Kranthi G <gudishax.kranthikumar@intel.com> Signed-off-by: Dharageswari R <dharageswari.r@intel.com> Signed-off-by: Ramesh Babu <ramesh.babu@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/Kconfig | 1 + sound/soc/intel/skylake/Makefile | 2 +- sound/soc/intel/skylake/bxt-sst.c | 328 +++++++++++++++++++++++++++++++++ sound/soc/intel/skylake/skl-messages.c | 120 ++++++++++++ sound/soc/intel/skylake/skl-sst-dsp.h | 13 ++ 5 files changed, 463 insertions(+), 1 deletion(-) commit f17131a93f43665a76ae1f6aebdbb3e41674137c Author: Randy Dunlap <rdunlap@infradead.org> Date: Tue Mar 29 09:45:00 2016 -0700 ASoC: intel: add function stub when ACPI is not enabled Add function stub for "sst_acpi_find_name_from_hid()" when CONFIG_ACPI is not enabled so that the driver will build successfully. This fixes the following build errors: (loadable module) ERROR: "sst_acpi_find_name_from_hid" [sound/soc/intel/boards/snd-soc-sst-bytcr-rt5640.ko] undefined! (or built-in) bytcr_rt5640.c:(.text+0x26fc52): undefined reference to `sst_acpi_find_name_from_hid' Reported-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/intel/common/sst-acpi.h | 9 +++++++++ 1 file changed, 9 insertions(+) commit 028021d29ea069390e1f60c6aa5b3511d218454b Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Wed Feb 17 22:39:06 2016 -0800 soc: qcom: smd: Support opening additional channels With the qcom_smd_open_channel() API we allow SMD devices to open additional SMD channels, to allow implementation of multi-channel SMD devices - like Bluetooth. Channels are opened from the same edge as the calling SMD device is tied to. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd.c | 76 ++++++++++++++++++++++++++++++++++++++++++++ include/linux/soc/qcom/smd.h | 4 +++ 2 files changed, 80 insertions(+) commit d5933855c0eb0a4103cf5db784cfdd4d7a85cd56 Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Wed Feb 17 22:39:05 2016 -0800 soc: qcom: smd: Support multiple channels per sdev This patch allows chaining additional channels to a SMD device, enabling implementation of multi-channel SMD devies - like Bluetooth. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 3fd3f2fd86478614fecbe261b201779b4fc6abd2 Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Wed Feb 17 22:39:04 2016 -0800 soc: qcom: smd: Refactor channel open and close handling Refactor opening and closing of channels into two separate functions instead of open coding this in the various places. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd.c | 62 ++++++++++++++++++++++++++++++++------------------ 1 file changed, 40 insertions(+), 22 deletions(-) commit 995b170aeaef4afe0c3469d14b9c80ff2e8a98d7 Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Wed Feb 17 22:39:03 2016 -0800 soc: qcom: smd: Split discovery and state change work Split the two steps of channel discovery and state change handling into two different workers. This allows for new channels to be found while we're are probing, which is required as we introduce multi-channel support. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd.c | 58 +++++++++++++++++++++++++++----------------------- 1 file changed, 31 insertions(+), 27 deletions(-) commit 39f0db298e7c02a29371fb39cabdd5d76e6b726c Author: Bjorn Andersson <bjorn.andersson@sonymobile.com> Date: Wed Feb 17 22:39:02 2016 -0800 soc: qcom: smd: Introduce callback setter Introduce a setter for the callback function pointer to clarify the locking around the operation and to reduce some duplication. Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/smd.c | 25 +++++++++++++++++-------- include/linux/soc/qcom/smd.h | 4 +++- 2 files changed, 20 insertions(+), 9 deletions(-) commit 3b904b046c7adfbadb124851c7a23276f7187ddb Author: Lina Iyer <lina.iyer@linaro.org> Date: Mon Jan 4 10:58:28 2016 -0700 drivers: qcom: spm: avoid module usage in non-modular SPM driver SPM driver provides cpuidle support on some QC SoC's. The functionality is non-modular and there is no need for module support. Convert module platform init to builtin platform driver init. The driver functionality is not affected by this change. Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Lina Iyer <lina.iyer@linaro.org> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> drivers/soc/qcom/spm.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit e8b123e6008480b2b8d80dae060315d84b79f4bb Author: Bjorn Andersson <bjorn@kryo.se> Date: Thu Dec 24 00:28:38 2015 -0800 soc: qcom: smem_state: Add stubs for disabled smem_state Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Andy Gross <andy.gross@linaro.org> include/linux/soc/qcom/smem_state.h | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 39a3366a31386eb58f6e5857cd49cebad3253ab8 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Mon Feb 22 11:55:26 2016 +0000 MAINTAINERS: add qcom clocks to the maintainers list This patch adds qcom clock drivers to the QCOM/MSM support list so that get_maintainer.pl can pick up correct cc list. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org> MAINTAINERS | 1 + 1 file changed, 1 insertion(+) commit 5482cefaca89995c75f2ad507dd7810b0b1079c5 Author: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Thu Jan 21 18:35:13 2016 +0000 MAINTAINERS: add qcom i2c and spi drivers to list This patch adds i2c-qup and spi-qup drivers in to the qualcomm maintainer list, so that get maintainers scripts can get correct people to send patch to. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Acked-by: Ivan T. Ivanov <iivanov.xz.@gmail.com> Signed-off-by: Andy Gross <andy.gross@linaro.org> MAINTAINERS | 2 ++ 1 file changed, 2 insertions(+) commit 6a0028b3dd67b86d7265ed873c8738743adec855 Author: Mark Brown <broonie@kernel.org> Date: Wed Mar 30 12:04:30 2016 -0700 regulator: Deprecate regulator_can_change_voltage() All current users of regulator_can_change_voltage() are abusing it, using it to wrap a call to regulator_set_voltage() on probe without any alternative handling for fixed voltages. Drivers should only be using regulator_set_voltage() if they need to vary voltages at runtime, fixed voltages should normally be set via machine constraints, and calling regulator_set_voltage() on a regulator which can't be varied will succeed if the current voltage is within the range requested so users shouldn't worry if they have permission to vary normally. Deprecate the API to try to stop any new users appearing while we fix the current callers. Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/regulator/consumer.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 00c9672606f781f2db7e904127dcbdc2831701ca Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 16:42:22 2016 +0200 drm: Untangle __KERNEL__ guards make headers_install can't handle fancy conditions, so let's simplify things for it a bit. Cc: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459348943-12803-1-git-send-email-daniel.vetter@ffwll.ch include/uapi/drm/drm.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit 8812f3814120873ac625d0085e64e4b83ff5aff3 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 16:19:44 2016 +0200 drm: Move DRM_MODE_OBJECT_* to uapi headers These type defines are officially part of the uapi, but ended up in the wrong headers somehow when we split them all. Cc: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459347584-30566-3-git-send-email-daniel.vetter@ffwll.ch include/drm/drm_crtc.h | 10 ---------- include/uapi/drm/drm_mode.h | 10 ++++++++++ 2 files changed, 10 insertions(+), 10 deletions(-) commit 0b1ccd49ba3252c5cbb0ac98ee2a8682b9a529cb Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 17:54:52 2016 +0200 drm: align #include directives with libdrm in uapi headers We can't use <drm/*.h> because that upsets the serach paths in libdrm. Also, drop the circular inclusion in drm_mode.h. v2: Actually change the right headers. v3: Drop the #include removal per Emil's request. Cc: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459353292-9063-1-git-send-email-daniel.vetter@ffwll.ch include/uapi/drm/drm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4c4925fa0c2b5943655ef28b2d6a379961db551f Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 17:12:33 2016 +0200 drm: Make drm.h uapi header safe for C++ virtual is a protected keyword in C++ and can't be used at all. Ugh. This aligns the kernel versions of the drm headers with the ones in libdrm. v2: Also annote with __user, as request by Emil&Ilia. Cc: Ilia Mirkin <imirkin@alum.mit.edu> Cc: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459350753-18320-1-git-send-email-daniel.vetter@ffwll.ch include/uapi/drm/drm.h | 4 ++++ 1 file changed, 4 insertions(+) commit 55c561a708eec328822721233b1148119e80f5c3 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:34:36 2016 +0200 drm/i915: Remove PIPE_CONF_CHECK_I_ALT And move the comment to the right macro. This was mixed up in commit cfb23ed622d040619abb91e625fcba74d356b8a8 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Jul 14 12:17:40 2015 +0200 drm/i915: Allow fuzzy matching in pipe_config_compare, v2 v2: Rebase. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Daniel Stone <daniels@collabora.com> Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330476-32453-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/i915/intel_display.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) commit a2151374230820a3a6e654f2998b2a44dbfae4e1 Author: Jon Hunter <jonathanh@nvidia.com> Date: Wed Mar 30 17:09:13 2016 +0100 regulator: Fix deadlock during regulator registration Commit 5e3ca2b349b1 ("regulator: Try to resolve regulators supplies on registration") added a call to regulator_resolve_supply() within regulator_register() where the regulator_list_mutex is held. This causes a deadlock to occur on the Tegra114 Dalmore board when the palmas PMIC is registered because regulator_register_resolve_supply() calls regulator_dev_lookup() which may try to acquire the regulator_list_mutex again. Fix this by releasing the mutex before calling regulator_register_resolve_supply() and update the error exit path to ensure the mutex is released on an error. [Made commit message more legible -- broonie] Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 3fcdfc9dad07c2a6ea19dfb98a2151cd86d06c6a Author: Mark Brown <broonie@kernel.org> Date: Wed Mar 30 11:02:49 2016 -0700 ASoC: wm8960: Depends on I2C Now that this is directly user selectable it needs to care about its dependencies. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 1 + 1 file changed, 1 insertion(+) commit ac40004db3fbea89c50083c6f9015ac7061e77b4 Author: Kevin Hilman <khilman@baylibre.com> Date: Thu Mar 24 11:05:15 2016 -0700 ARM64: dts: amlogic: Add P200/P201 boards Add minimal DT files for the Amlogic P20x development boards, based on the Amlogic S905/GXBB SoC. Cc: Andreas Färber <afaerber@suse.de> Cc: Carlo Caione <carlo@endlessm.com> Signed-off-by: Kevin Hilman <khilman@baylibre.com> Reviewed-by: Andreas Färber <afaerber@suse.de> Acked-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/boot/dts/amlogic/Makefile | 2 + arch/arm64/boot/dts/amlogic/meson-gxbb-p200.dts | 52 +++++++++++++++++++ arch/arm64/boot/dts/amlogic/meson-gxbb-p201.dts | 52 +++++++++++++++++++ arch/arm64/boot/dts/amlogic/meson-gxbb-p20x.dtsi | 65 ++++++++++++++++++++++++ 4 files changed, 171 insertions(+) commit 855960342d1e777e5d1ff37a9ca8b4f22a7d53b4 Author: Kevin Hilman <khilman@baylibre.com> Date: Thu Mar 24 11:05:14 2016 -0700 ARM64: dts: amlogic: add Hardkernel ODROID-C2 Add minimal DT files for the Hardkernel ODROID-C2 board based on the Amlogic S905/GXBB SoC. Used the other gxbb boards from Andreas Färber as a starting point. Cc: Andreas Färber <afaerber@suse.de> Cc: Carlo Caione <carlo@endlessm.com> Signed-off-by: Kevin Hilman <khilman@baylibre.com> Reviewed-by: Andreas Färber <afaerber@suse.de> Acked-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/boot/dts/amlogic/Makefile | 1 + .../arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dts | 69 ++++++++++++++++++++++ 2 files changed, 70 insertions(+) commit a426e1dee661f41e330f73b1e8a301618e12eb98 Author: Kevin Hilman <khilman@baylibre.com> Date: Thu Mar 24 11:05:13 2016 -0700 Documentation: devicetree: amlogic: Document P20x and ODROID-C2 boards Add compatible strings for Amlogic S905/GXBB based boards: Hardkernel ODROID-C2, Amlogic P200 and Amlogic P201. Cc: devicetree@vger.kernel.org Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Kevin Hilman <khilman@baylibre.com> Acked-by: Rob Herring <robh@kernel.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Documentation/devicetree/bindings/arm/amlogic.txt | 3 +++ 1 file changed, 3 insertions(+) commit 962f271ec9463648ea52c13bb51bcc46afde0396 Author: Kevin Hilman <khilman@baylibre.com> Date: Thu Mar 24 11:05:12 2016 -0700 ARM64: dts: amlogic: update serial aliases Apparently, it's not valid to have an alias point to a disabled device. Fix this by moving the aliases that are used (serial0) into the files that use them, and remove aliases to disabled devices (serial1). Suggested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Kevin Hilman <khilman@baylibre.com> Reviewed-by: Andreas Färber <afaerber@suse.de> Acked-by: Arnd Bergmann <arnd@arndb.de> arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95.dtsi | 4 ++++ arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 5 ----- 2 files changed, 4 insertions(+), 5 deletions(-) commit 65eb22ea1da80eb12f2cc10f397f28193b1dfb91 Author: Andreas Färber <afaerber@suse.de> Date: Thu Mar 17 00:10:53 2016 +0100 ARM64: dts: amlogic: Clean up Vega S95 /memory nodes Resolve the following warnings from new dtc by adding the unit address: DTC arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dtb Warning (unit_address_vs_reg): Node /memory has a reg or ranges property, but no unit name DTC arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dtb Warning (unit_address_vs_reg): Node /memory has a reg or ranges property, but no unit name DTC arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dtb Warning (unit_address_vs_reg): Node /memory has a reg or ranges property, but no unit name Fixes: cc733bc90636 ("ARM64: dts: amlogic: Add Tronsmart Vega S95 configs") Signed-off-by: Andreas Färber <afaerber@suse.de> arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dts | 2 +- arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dts | 2 +- arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) commit 9c7417022ded5700a4b1a11da59951ebf080e4e0 Author: Rodrigo Vivi <rodrigo.vivi@intel.com> Date: Wed Mar 30 07:58:01 2016 -0700 drm/i915/kbl: Remove preliminary_hw_support protection from KBL. We now have KBL machines running in our CI systems and with no blocking issues that could cause a full hangs or blank screens. Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459349881-951-1-git-send-email-rodrigo.vivi@intel.com Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.c | 2 -- 1 file changed, 2 deletions(-) commit 97d8eb16aa84eb48466f34c3ec0f492f34b85a04 Author: Kevin Hilman <khilman@baylibre.com> Date: Wed Mar 23 11:49:53 2016 -0700 arm64: defconfig: enable basic boot for Amlogic meson Enables basic arch and serial console support for Amlogic meson family SoCs. Tested with Amlogic P200 and Hardkernel ODROID-C2 boards. Signed-off-by: Kevin Hilman <khilman@baylibre.com> Reviewed-by: Andreas Färber <afaerber@suse.de> arch/arm64/configs/defconfig | 3 +++ 1 file changed, 3 insertions(+) commit 2dfadff69e8b1da8f8661e9edb131b208cc389b7 Author: Axel Lin <axel.lin@ingics.com> Date: Wed Mar 30 18:25:07 2016 +0800 ASoC: rt5677: Avoid duplicate the same test in each switch case Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt5677.c | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) commit d991c872ac7ffaacc4df93efbfbcb4189cee6440 Author: Sander Eikelenboom <linux@eikelenboom.it> Date: Sun Mar 20 22:27:06 2016 +0100 libata: Fixup awkward whitespace in warning by removing line continuation. Signed-off-by: Sander Eikelenboom <linux@eikelenboom.it> Signed-off-by: Tejun Heo <tj@kernel.org> drivers/ata/libahci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6ed71e9819ac3412fc6a3495f5ce141df274c916 Author: Joe Perches <joe@perches.com> Date: Wed Mar 30 05:23:18 2016 -0700 jfs: Coalesce some formats Formats are better kept as a single line for easier grep. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com> fs/jfs/inode.c | 4 ++-- fs/jfs/jfs_dtree.c | 10 ++++------ fs/jfs/jfs_imap.c | 3 +-- fs/jfs/jfs_logmgr.c | 10 ++++------ fs/jfs/jfs_txnmgr.c | 17 +++++++---------- fs/jfs/namei.c | 4 ++-- 6 files changed, 20 insertions(+), 28 deletions(-) commit aa575749f4356d68bc2973f213e7d28cc146ebce Author: Joe Perches <joe@perches.com> Date: Wed Mar 30 05:23:17 2016 -0700 jfs: Remove unnecessary line continuations and terminating newlines These jfs_<level> uses need neither a line continuation to assemble the format strings nor newline terminations in the formats. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com> fs/jfs/jfs_discard.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit b18db6de2ce2a6ca7f5da03701a2aa8c63b31b74 Author: Joe Perches <joe@perches.com> Date: Wed Mar 30 05:23:16 2016 -0700 jfs: Remove terminating newlines from jfs_info, jfs_warn, jfs_err uses These macros add the newline so these cause extra blank lines in logging output. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com> fs/jfs/jfs_inode.c | 2 +- fs/jfs/jfs_logmgr.c | 4 ++-- fs/jfs/jfs_txnmgr.c | 4 ++-- fs/jfs/super.c | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) commit 44debe7a123cc760fc90ccbe253210798c917fa7 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:26:35 2016 +0200 vgacon: dummy implementation for vgacon_text_force This allows us to ditch a ton of ugly #ifdefs from a bunch of drm modeset drivers. v2: Make the dummy function actually return a sane value, spotted by Ville. v3: Because the patch is still in limbo there's no more drivers to convert, noticed by Emil. v4: Rebase once more, because hooray. I'll just go ahead an apply this one later on to drm-misc. Cc: Emil Velikov <emil.l.velikov@gmail.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 2 -- drivers/gpu/drm/ast/ast_drv.c | 2 -- drivers/gpu/drm/cirrus/cirrus_drv.c | 2 -- drivers/gpu/drm/i915/i915_drv.c | 2 -- drivers/gpu/drm/mgag200/mgag200_drv.c | 2 -- drivers/gpu/drm/nouveau/nouveau_drm.c | 2 -- drivers/gpu/drm/qxl/qxl_drv.c | 2 -- drivers/gpu/drm/radeon/radeon_drv.c | 2 -- drivers/gpu/drm/virtio/virtgpu_drv.c | 2 -- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 -- include/linux/console.h | 2 ++ 11 files changed, 2 insertions(+), 20 deletions(-) commit 45fa2038cf7820ecfcca8793b81e656ca3caaf0f Author: Mark Brown <broonie@kernel.org> Date: Wed Mar 30 08:26:09 2016 -0700 regulator: of: Don't flag voltage change as possible for exact voltages Flagging voltage changes as possible for exactly specified voltages appears to be triggering bugs in the SDHCI code (it should be able to handle the case where only one voltage it wants is in the range it is allowed to set) so make sure we only set the flag in cases where there's genuine variability. Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/of_regulator.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit aa2e2996b1518b3e4b72dab5c2cb6cd082e3002e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 11:45:14 2016 +0200 drm/sysfs: Nuke TV/DVI property files This goes all the way back to the original KMS commit aeons ago commit f453ba0460742ad027ae0c4c7d61e62817b3e7ef Author: Dave Airlie <airlied@redhat.com> Date: Fri Nov 7 14:05:41 2008 -0800 DRM: add mode setting support But it seems to be completely unused. Only i915 and nouveau even register these properties, and the corresponding DDX don't even look at them. Also the sysfs files are read-only, so not useful to configure anything. I suspect that this was added with the goal to have read-only access to all properties in sysfs, but we never followed through on that. Also, that should be done in a more generic fashion. Since it would be real work to fix up the locking (with atomic we're now chasing pointers when reading properties) and it seems unused lets just nuke this all. It's easier. Of course we'll keep the properties themselves, those are still exposed through the KMS ioctls. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459331120-27864-5-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_sysfs.c | 156 -------------------------------------------- 1 file changed, 156 deletions(-) commit e6bf6e5799f72f04bac61056804d6dd8dac98062 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 13:24:06 2016 +0200 drm/ttm: Remove TTM_HAS_AGP It tries to do fancy things with excluding agp support if ttm is built-in, but agp isn't. Instead just express this depency like drm does and use CONFIG_AGP everywhere. Also use the neat Makefile magic to make the entire ttm_agp_backend file optional. v2: Use IS_ENABLED(CONFIG_AGP) as suggested by Ville v3: Review from Emil. v4: Actually get it right as spotted by 0-day. Cc: Emil Velikov <emil.l.velikov@gmail.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459337046-25882-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/ttm/Makefile | 3 ++- drivers/gpu/drm/ttm/ttm_agp_backend.c | 3 --- drivers/gpu/drm/ttm/ttm_page_alloc.c | 8 ++++---- drivers/gpu/drm/ttm/ttm_page_alloc_dma.c | 8 ++++---- include/drm/ttm/ttm_bo_driver.h | 3 +-- 5 files changed, 11 insertions(+), 14 deletions(-) commit d1706b39f0af6901ab2a5e2ebb210b53c1a5bdc7 Author: Andi Kleen <ak@linux.intel.com> Date: Mon Mar 28 10:45:38 2016 -0700 perf tools: Add support for skipping itrace instructions When using 'perf script' to look at PT traces it is often useful to ignore the initialization code at the beginning. On larger traces which may have many millions of instructions in initialization code doing that in a pipeline can be very slow, with perf script spending a lot of CPU time calling printf and writing data. This patch adds an extension to the --itrace argument that skips 'n' events (instructions, branches or transactions) at the beginning. This is much more efficient. v2: Add support for BTS (Adrian Hunter) Document in itrace.txt Fix branch check Check transactions and instructions too Committer note: To test intel_pt one needs to make sure VT-x isn't active, i.e. stopping KVM guests on the test machine, as described by Andi Kleen at http://lkml.kernel.org/r/20160301234953.GD23621@tassilo.jf.intel.com Signed-off-by: Andi Kleen <ak@linux.intel.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1459187142-20035-1-git-send-email-andi@firstfloor.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/intel-pt.txt | 7 +++++++ tools/perf/Documentation/itrace.txt | 8 ++++++++ tools/perf/util/auxtrace.c | 7 +++++++ tools/perf/util/auxtrace.h | 2 ++ tools/perf/util/intel-bts.c | 5 +++++ tools/perf/util/intel-pt.c | 22 ++++++++++++++++++++-- 6 files changed, 49 insertions(+), 2 deletions(-) commit f7380c12ec6cfd69f274ba6181cd01c764f877bb Author: Dima Kogan <dima@secretsauce.net> Date: Tue Mar 29 12:47:53 2016 -0300 perf script perl: Perl scripts now get a backtrace, like the python ones We have some infrastructure to use perl or python to analyze logs generated by perf. Prior to this patch, only the python tools had access to backtrace information. This patch makes this information available to perl scripts as well. Example: Let's look at malloc() calls made by the seq utility. First we create a probe point: $ perf probe -x /lib/x86_64-linux-gnu/libc.so.6 malloc Added new events: ... Now we run seq, while monitoring malloc() calls with perf $ perf record --call-graph=dwarf -e probe_libc:malloc seq 5 1 2 3 4 5 [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.064 MB perf.data (6 samples) ] We can use perf to look at its log to see the malloc calls and the backtrace $ perf script seq 14195 [000] 1927993.748254: probe_libc:malloc: (7f9ff8edd320) bytes=0x22 7f9ff8edd320 malloc (/lib/x86_64-linux-gnu/libc-2.22.so) 7f9ff8e8eab0 set_binding_values.part.0 (/lib/x86_64-linux-gnu/libc-2.22.so) 7f9ff8e8eda1 __bindtextdomain (/lib/x86_64-linux-gnu/libc-2.22.so) 401b22 main (/usr/bin/seq) 7f9ff8e82610 __libc_start_main (/lib/x86_64-linux-gnu/libc-2.22.so) 402799 _start (/usr/bin/seq) ... We can also use the scripting facilities. We create a skeleton perl script that simply prints out the events $ perf script -g perl generated Perl script: perf-script.pl We can then use this script to see the malloc() calls with a backtrace. Prior to this patch, the backtrace was not available to the perl scripts. $ perf script -s perf-script.pl probe_libc::malloc 0 1927993.748254260 14195 seq __probe_ip=140325052863264, bytes=34 [7f9ff8edd320] malloc [7f9ff8e8eab0] set_binding_values.part.0 [7f9ff8e8eda1] __bindtextdomain [401b22] main [7f9ff8e82610] __libc_start_main [402799] _start ... Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Link: http://lkml.kernel.org/r/87mvphzld0.fsf@secretsauce.net Signed-off-by: Dima Kogan <dima@secretsauce.net> .../perf/util/scripting-engines/trace-event-perl.c | 114 +++++++++++++++++++-- 1 file changed, 106 insertions(+), 8 deletions(-) commit 37194f443a5a7157866ba68b04827e111100167b Author: Taeung Song <treeze.taeung@gmail.com> Date: Mon Mar 28 02:22:20 2016 +0900 perf config: Rename 'v' to 'home' in set_buildid_dir() Change the variable name 'v' to 'home' to make it more readable. Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1459099340-16911-3-git-send-email-treeze.taeung@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/config.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit 9cb5987c822714352e3eb46806fc260b3cb4ff0d Author: Taeung Song <treeze.taeung@gmail.com> Date: Mon Mar 28 02:22:19 2016 +0900 perf config: Rework buildid_dir_command_config to perf_buildid_config To avoid repeated calling perf_config() remove buildid_dir_command_config() and add new perf_buildid_config into perf_default_config. Because perf_config() is already called with perf_default_config at main(). Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/r/1459099340-16911-2-git-send-email-treeze.taeung@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/config.c | 50 +++++++++++++++++------------------------------- 1 file changed, 18 insertions(+), 32 deletions(-) commit 58cb9d650be45100bf53ddf9e00351391de3d735 Author: Taeung Song <treeze.taeung@gmail.com> Date: Mon Mar 28 02:22:18 2016 +0900 perf config: Remove duplicated set_buildid_dir calls Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Acked-by: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1459099340-16911-1-git-send-email-treeze.taeung@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/perf.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit b31d660df37c1701fd18d526faeb9a86f0fc7dd2 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Mar 24 13:52:20 2016 +0100 perf tests: Add test to check for event times This test creates software event 'cpu-clock' attaches it in several ways and checks that enabled and running times match. Committer notes: Testing it: [acme@jouet linux]$ perf test -v times 44: Test events times : --- start --- test child forked, pid 27170 attaching to spawned child, enable on exec OK : ena 307328, run 307328 attaching to current thread as enabled OK : ena 7826, run 7826 attaching to current thread as disabled OK : ena 738, run 738 attaching to CPU 0 as enabled SKIP : not enough rights attaching to CPU 0 as enabled SKIP : not enough rights test child finished with -2 ---- end ---- Test events times: Skip [acme@jouet linux]$ [root@jouet ~]# perf test times 44: Test events times : Ok [root@jouet ~]# perf test -v times 44: Test events times : --- start --- test child forked, pid 27306 attaching to spawned child, enable on exec OK : ena 479290, run 479290 attaching to current thread as enabled OK : ena 11356, run 11356 attaching to current thread as disabled OK : ena 987, run 987 attaching to CPU 0 as enabled OK : ena 3717, run 3717 attaching to CPU 0 as enabled OK : ena 2323, run 2323 test child finished with 0 ---- end ---- Test events times: Ok [root@jouet ~]# Signed-off-by: Jiri Olsa <jolsa@kernel.org> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1458823940-24583-7-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/tests/Build | 1 + tools/perf/tests/builtin-test.c | 4 + tools/perf/tests/event-times.c | 236 ++++++++++++++++++++++++++++++++++++++++ tools/perf/tests/tests.h | 1 + 4 files changed, 242 insertions(+) commit e0be62cc0325d65e1b7ae55d23e3d224638c20a6 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Mar 24 13:52:19 2016 +0100 perf tools: Make -f/--force option documentation consistent across tools Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1458823940-24583-6-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-annotate.txt | 2 +- tools/perf/Documentation/perf-diff.txt | 2 +- tools/perf/Documentation/perf-report.txt | 2 +- tools/perf/Documentation/perf-script.txt | 4 ++++ 4 files changed, 7 insertions(+), 3 deletions(-) commit 592dac6f35cf222a7687d4ff1ea7df0e6ef722e0 Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Mar 24 13:52:17 2016 +0100 perf tools: Make hists__collapse_insert_entry static No need to export hists__collapse_insert_entry function. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1458823940-24583-4-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/util/hist.c | 5 +++-- tools/perf/util/hist.h | 2 -- 2 files changed, 3 insertions(+), 4 deletions(-) commit ad16511b0e404652331a5350c522d0824f8209de Author: Jiri Olsa <jolsa@kernel.org> Date: Thu Mar 24 13:52:16 2016 +0100 perf mem: Add -U/-K (--all-user/--all-kernel) options Add -U/-K (--all-user/--all-kernel) options to use the perf record --all-user/--all-kernel options. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1458823940-24583-3-git-send-email-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> tools/perf/Documentation/perf-mem.txt | 8 ++++++++ tools/perf/builtin-mem.c | 11 ++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) commit ec05e9cc6a6e9679ea536934d2566ac9c209eece Author: Shaohui Xie <Shaohui.Xie@freescale.com> Date: Tue Mar 8 10:25:39 2016 +0800 arm64: dts: add LS1043a-QDS board support The LS1043a-QDS board is a high-performance computing, evaluation, development, and test platform supporting the LS1043a SoC. shawn.guo: sort the entries in Makefile alphabetcially Signed-off-by: Shaohui Xie <Shaohui.Xie@freescale.com> Signed-off-by: Mingkai Hu <Mingkai.Hu@freescale.com> Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org> arch/arm64/boot/dts/freescale/Makefile | 3 +- arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts | 168 ++++++++++++++++++++++ 2 files changed, 170 insertions(+), 1 deletion(-) commit 5cc52a6d75468830fd26703728675d17f86a5864 Author: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> Date: Tue Mar 8 10:25:38 2016 +0800 Documentation: DT: Add entry for Freescale LS1043a-QDS board Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Shawn Guo <shawnguo@kernel.org> Documentation/devicetree/bindings/arm/fsl.txt | 4 ++++ 1 file changed, 4 insertions(+) commit 773fe72630c8aca874ec8a07ebacace4ae305a02 Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Feb 20 20:06:49 2016 +0100 reset: lpc18xx: get rid of global variables for restart notifier Moving the notifier_block into the drivers priv struct allows us to retrive the priv struct with container_of and remove the global variables. Signed-off-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/reset/reset-lpc18xx.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) commit 0b52297f2288ca239e598afe6c92db83d8d2bfcd Author: Hans de Goede <hdegoede@redhat.com> Date: Tue Feb 23 18:46:26 2016 +0100 reset: Add support for shared reset controls In some SoCs some hw-blocks share a reset control. Add support for this setup by adding new: reset_control_get_shared() devm_reset_control_get_shared() devm_reset_control_get_shared_by_index() methods to get a reset_control. Note that this patch omits adding of_ variants, if these are needed later they can be easily added. This patch also changes the behavior of the existing exclusive reset_control_get() variants, if these are now called more then once for the same reset_control they will return -EBUSY. To catch existing drivers triggering this error (there should not be any) a WARN_ON(1) is added in this path. When a reset_control is shared, the behavior of reset_control_assert / deassert is changed, for shared reset_controls these will work like the clock-enable/disable and regulator-on/off functions. They will keep a deassert_count, and only (re-)assert the reset after reset_control_assert has been called as many times as reset_control_deassert was called. Calling reset_control_assert without first calling reset_control_deassert is not allowed on a shared reset control. Calling reset_control_reset is also not allowed on a shared reset control. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/reset/core.c | 59 +++++++++++++++++++++++++------ include/linux/reset.h | 96 +++++++++++++++++++++++++++++++++++++++++++-------- 2 files changed, 129 insertions(+), 26 deletions(-) commit c15ddec2ca06076a11195313aa1fce47d2a28c5d Author: Hans de Goede <hdegoede@redhat.com> Date: Tue Feb 23 18:46:25 2016 +0100 reset: Share struct reset_control between reset_control_get calls Now that struct reset_control no longer stores the device pointer for the device calling reset_control_get we can share a single struct reset_control when multiple calls to reset_control_get are made for the same reset line (same id / index). This is a preparation patch for adding support for shared reset lines. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/reset/core.c | 84 ++++++++++++++++++++++++++++++---------- include/linux/reset-controller.h | 2 + 2 files changed, 65 insertions(+), 21 deletions(-) commit 6c96f05c8bb8bc4177613ef3c23a56b455e75887 Author: Hans de Goede <hdegoede@redhat.com> Date: Tue Feb 23 18:46:24 2016 +0100 reset: Make [of_]reset_control_get[_foo] functions wrappers With both the regular, _by_index and _optional variants we already have quite a few variants of [of_]reset_control_get[_foo], the upcoming addition of shared reset lines support makes this worse. This commit changes all the variants into wrappers around common core functions. For completeness sake this commit also adds a new devm_get_reset_control_by_index wrapper. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> drivers/reset/core.c | 84 +++++++-------------------------- include/linux/reset.h | 126 +++++++++++++++++++++++++++++++++++--------------- 2 files changed, 107 insertions(+), 103 deletions(-) commit 46167a8fd4248533ad15867e6988ff20e76de641 Author: Colin Ian King <colin.king@canonical.com> Date: Mon Mar 28 12:33:44 2016 +0100 iwlwifi: pcie: remove duplicate assignment of variable isr_stats isr_stats is written twice with the same value, remove one of the redundant assignments to isr_stats. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 489c546dcecbddbadcbef25472d8fb4d693850e2 Author: Luca Coelho <luciano.coelho@intel.com> Date: Thu Mar 24 11:10:12 2016 +0200 iwlwifi: mvm: allow setting the thermal state in D0i3 We were not allowing the thermal state to be set when we were in D0i3 mode. It was not very clearly specified how it should work, but now a decision was made to allow the state to be set in D0i3 (which will cause a brief wake up). Remove the check in the set_cur_state operation. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 3 --- 1 file changed, 3 deletions(-) commit d2515a99b2da2bf08d5a1decb7b365e25adbccea Author: Liad Kaufman <liad.kaufman@intel.com> Date: Wed Mar 23 16:31:08 2016 +0200 iwlwifi: mvm: fix inconsistent lock in dqa mode When working in DQA mode, there is a lockdep log warning about an inconsistent state of the mvmsta->lock and the mvm->queue_info_lock. Fix this. This mode is not activated for now. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a6017b9030f280ced61b825757b26f042e0785da Author: Golan Ben-Ami <golan.ben.ami@intel.com> Date: Mon Mar 14 12:24:20 2016 +0200 iwlwifi: store fw memory segments length and addresses in run-time Currently reading the fw memory segments is done according to addresses and data length that are hard-coded. Lately a new tlv was appended to the ucode, that contains the data type, length and address. Parse this tlv, and in run-time store the memory segments length and addresses that would be dumped upon a fw error. Signed-off-by: Golan Ben-Ami <golan.ben.ami@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 45 +++++++++++++++++ drivers/net/wireless/intel/iwlwifi/iwl-fw-file.h | 32 +++++++++++++ drivers/net/wireless/intel/iwlwifi/iwl-fw.h | 2 + drivers/net/wireless/intel/iwlwifi/mvm/fw-dbg.c | 61 ++++++++++++++++++------ 4 files changed, 125 insertions(+), 15 deletions(-) commit 8d80717a12c138f3d765d91feab0c08190a21d85 Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Sun Mar 27 12:56:13 2016 +0300 iwlwifi: pcie: Fix index iteration on free_irq in MSIX mode In MSIX mode we iterate over the allocated interrupt vectors and register them to an handler. In case of registration failure, we free all the allocated irq. we use the outer index mistakenly instead of the inner one. Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9d9b21d1b61647d5a37241571c0e3eb7cc04b348 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Thu Mar 24 08:44:57 2016 +0200 iwlwifi: remove IWL_*_UCODE_API_OK _UCODE_API_OK was a intermediate version between MIN and MAX. If a user had a firmware below _OK but above _MIN, the driver would work but the user would get a warning in the kernel log telling him to update his firmware. This is not needed since most users won't look for these messages in the kernel log if their wifi is working. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-1000.c | 10 ++-------- drivers/net/wireless/intel/iwlwifi/iwl-2000.c | 18 ++++-------------- drivers/net/wireless/intel/iwlwifi/iwl-5000.c | 11 ++--------- drivers/net/wireless/intel/iwlwifi/iwl-6000.c | 20 ++++---------------- drivers/net/wireless/intel/iwlwifi/iwl-7000.c | 20 +++++--------------- drivers/net/wireless/intel/iwlwifi/iwl-8000.c | 11 ++--------- drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 6 +----- drivers/net/wireless/intel/iwlwifi/iwl-config.h | 3 --- drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 24 +----------------------- 9 files changed, 21 insertions(+), 102 deletions(-) commit 5e6a98dc4863e50a010ebdf09fa63c1e11929a85 Author: Sara Sharon <sara.sharon@intel.com> Date: Thu Mar 10 17:40:56 2016 +0200 iwlwifi: mvm: enable TCP/UDP checksum support for 9000 family Declare and enable support of RX and TX checksum for 9000 family. Configure offload_assist in the TX cmd accordingly to support TX csum. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 1 + drivers/net/wireless/intel/iwlwifi/iwl-config.h | 2 + drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 13 +-- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 124 +++++++++++++++++++++- 4 files changed, 133 insertions(+), 7 deletions(-) commit 728e825f81b1fe29eb177148fcabfa55a7f4c1bb Author: Luca Coelho <luciano.coelho@intel.com> Date: Fri Mar 11 09:20:37 2016 +0200 iwlwifi: mvm: add a scan timeout for regular scans If something goes wrong with the firmware and we never get a scan complete notification, we stay stuck forever. In order to avoid this situation, add a timeout and trigger an NMI if it expires before receiving the notification., so we can clean things up. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 2 ++ drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 5 +++++ drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 21 +++++++++++++++++++++ 3 files changed, 28 insertions(+) commit 097129c9e62540122b63cba79c1843a2602bec37 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Sun Aug 9 18:28:43 2015 +0300 iwlwifi: mvm: move cmd queue to be #0 in dqa mode Change the CMD queue to be queue #0 (rather than queue #9) when working in DQA mode. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 2 ++ drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 5 ++++- drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 8 ++++++-- drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 5 ++++- 4 files changed, 16 insertions(+), 4 deletions(-) commit 0e0e44205c14b557606b498ff0fcad53c7c2430a Author: Liad Kaufman <liad.kaufman@intel.com> Date: Tue Aug 4 15:13:38 2015 +0300 iwlwifi: mvm: allocate dedicated queue for cab in dqa mode In DQA mode, allocate a dedicated queue (#3) for content after beacon (AKA "CaB"). Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 2 ++ drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 18 ++++++++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) commit f02669be45b44ffbb70d2f721f47544629f7a9a4 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Sun Feb 28 16:15:07 2016 +0200 iwlwifi: mvm: set sta_id in SCD_QUEUE_CONFIG cmd Set the correct sta_id in the SCD_QUEUE_CONFIG command sent to the FW when enabling/disabling queues. This is needed in DQA-mode to allow the FW to associate between queue and STA. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 1 + drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 4 ++++ 2 files changed, 5 insertions(+) commit d5216a28936add0a9c34bdc7d4f03c2e0a2261c2 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Sun Aug 9 15:50:51 2015 +0300 iwlwifi: mvm: use bss client queue for bss station Use the reserved BSS Client queue when connecting to an AP in DQA mode. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 3 +++ drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 18 +++++++++++++----- 2 files changed, 16 insertions(+), 5 deletions(-) commit 0e32d5904ccad13a8fb6a5b0519ae43eef0e0a75 Author: Oren Givon <oren.givon@intel.com> Date: Thu Mar 24 10:20:28 2016 +0200 iwlwifi: edit the 9000 series PCI IDs Edit some of the 9560 series and 5165 series PCI IDs. These devices do not exist yet. Signed-off-by: Oren Givon <oren.givon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) commit 579de73b048a0a4c66c25a033ac76a2836e0cf73 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Mar 14 09:01:57 2016 +0000 drm/i915: Exit cherryview_irq_handler() after one pass This effectively reverts commit 8e5fd599eb219f1054e39b40d18b217af669eea9 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Apr 9 13:28:50 2014 +0300 drm/i915/chv: Make CHV irq handler loop until all interrupts are consumed as under continuous execlists load we can saturate the IRQ handler, destablising the tsc clock and triggering the NMI watchdog to declare a hung CPU. [ 552.756051] clocksource: timekeeping watchdog on CPU0: Marking clocksource 'tsc' as unstable because the skew is too large: [ 552.756080] clocksource: 'refined-jiffies' wd_now: 10003b480 wd_last: 10003b28c mask: ffffffff [ 552.756091] clocksource: 'tsc' cs_now: d55d31aa50 cs_last: d17446166c mask: ffffffffffffffff [ 552.756210] clocksource: Switched to clocksource refined-jiffies [ 575.217870] NMI watchdog: Watchdog detected hard LOCKUP on cpu 1 [ 575.217893] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.5.0-rc7+ #18 [ 575.217905] Hardware name: /NUC5CPYB, BIOS PYBSWCEL.86A.0027.2015.0507.1758 05/07/2015 [ 575.217915] 0000000000000000 ffff88027fd05bc0 ffffffff81288c6d 0000000000000000 [ 575.217935] 0000000000000001 ffff88027fd05be0 ffffffff810e72d1 0000000000000000 [ 575.217951] ffff88027fd05c80 ffff88027fd05c20 ffffffff81114b60 0000000181015f1e [ 575.217967] Call Trace: [ 575.217973] <NMI> [<ffffffff81288c6d>] dump_stack+0x4f/0x72 [ 575.217994] [<ffffffff810e72d1>] watchdog_overflow_callback+0x151/0x160 [ 575.218003] [<ffffffff81114b60>] __perf_event_overflow+0xa0/0x1e0 [ 575.218016] [<ffffffff811154c4>] perf_event_overflow+0x14/0x20 [ 575.218028] [<ffffffff8101d2ca>] intel_pmu_handle_irq+0x1da/0x460 [ 575.218042] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218052] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218064] [<ffffffff81014ae8>] perf_event_nmi_handler+0x28/0x50 [ 575.218075] [<ffffffff81007540>] nmi_handle+0x60/0x130 [ 575.218086] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218096] [<ffffffff810079c0>] do_nmi+0x140/0x470 [ 575.218108] [<ffffffff81559ec7>] end_repeat_nmi+0x1a/0x1e [ 575.218119] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218129] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218139] [<ffffffff814a8aae>] ? poll_idle+0x3e/0x70 [ 575.218148] <<EOE>> [<ffffffff814a8353>] cpuidle_enter_state+0xf3/0x2f0 [ 575.218164] [<ffffffff814a8587>] cpuidle_enter+0x17/0x20 [ 575.218175] [<ffffffff810aaa3a>] call_cpuidle+0x2a/0x40 [ 575.218185] [<ffffffff810aade3>] cpu_startup_entry+0x273/0x330 [ 575.218196] [<ffffffff81033a1e>] start_secondary+0x10e/0x130 However, not servicing all available IIR within the handler does hurt the throughput of pathological nop execbuf by about 20%, with a similar effect upon the dispatch latency of a series of execbuf. v2: use do {} while(0) for a smaller patch, and easier to revert again I have reasonable confidence that we do not miss GT interrupts (as execlists provides a stress case with a failure mechanism easily detected by igt), however I have less confidence about all the other sources of interrupts and worry that may lose a display hotplug interrupt, for example. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93467 Testcase: igt/gem_exec_nop/basic # requires NMI watchdog Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Antti Koskipää <antti.koskipaa@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: stable@vger.kernel.org Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457946117-6714-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_irq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 854d773e4ab5869200004af4ca5d851730849903 Author: Sara Sharon <sara.sharon@intel.com> Date: Tue Mar 22 15:55:58 2016 +0200 iwlwifi: mvm: improve RSS configuration Improve current RSS configuration: * Use netdev_rss_key instead of keeping a local copy. * Configure also UDP hashing to have UDP traffic spread across queues. * Do not direct RSS traffic to our fallback queue. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c | 5 ++++- drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 9 +++++++-- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 1 - drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 3 --- 4 files changed, 11 insertions(+), 7 deletions(-) commit 013a67ea69d7caac094e6d144507246f10f24d9a Author: Sara Sharon <sara.sharon@intel.com> Date: Tue Mar 22 16:04:53 2016 +0200 iwlwifi: pcie: request one more interrupt vector We want to request an interrupt vector for RSS queue per CPU, one vector for fallback queue, and one for non-rx interrupts. Future patch will make sure that no RSS traffic is directed to fallback queue. This will enable us to enable fast path on traffic that otherwise would have been received on the fallback queue. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0df1391feee699a79b36f284fa6e19ab26344d25 Author: Chaya Rachel Ivgi <chaya.rachel.ivgi@intel.com> Date: Thu Mar 17 13:01:37 2016 +0200 iwlwifi: mvm: remove uneeded D0I3 checking The driver can read the current state during D0I3, therefore there is no reason not to do it. Signed-off-by: Chaya Rachel Ivgi <chaya.rachel.ivgi@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 3 --- 1 file changed, 3 deletions(-) commit 2a2e9d100739d79531d1109d7b768b3aaf681c06 Author: Liad Kaufman <liad.kaufman@intel.com> Date: Thu Mar 17 10:13:57 2016 +0200 iwlwifi: trans: fix iwl_trans_txq_scd_cfg.sta_id sign For some reason, this was defined as a signed variable. Make it unsigned. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-trans.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 5db81fd401bd8bba4bcc4a615c60961a792d4df9 Author: David Spinadel <david.spinadel@intel.com> Date: Sun Mar 20 10:35:10 2016 +0200 iwlwifi: mvm: set aux STA ID in scan config Auxilary station ID in flag in scan config command wasn't set although we set the station ID. Add the flag. Signed-off-by: David Spinadel <david.spinadel@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 1 + 1 file changed, 1 insertion(+) commit b238be07375e1d3aa976564397109fe9898d6123 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 16 13:57:50 2016 +0200 iwlwifi: mvm: report checksum is done also for IPv6 packets Currently the code checks if hardware reported both L4 and L3 checksums as valid, and only then reports it as validated to the stack. However, IPv6 does not have checksum at all and the L3 checksum valid bit is always off for IPv6 packets, with the result of the stack re-validating L4 checksum. Fix code to set CHECKSUM_UNNECESSARY also for IPv6 packets whose TCP/UDP checksum was verified. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-rx.h | 15 ++++++++++++++- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 9 +++++++-- 2 files changed, 21 insertions(+), 3 deletions(-) commit b429a773c193ee7cb752144e590181a1b8cc8fb5 Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 19 05:15:47 2016 +0000 iwlwifi: dvm: use alloc_ordered_workqueue() Use alloc_ordered_workqueue() to allocate the workqueue instead of create_singlethread_workqueue() since the latter is deprecated and is scheduled for removal. There are work items doing related operations that shouldn't be swapped when queued in a certain order hence preserve the strict execution ordering of a single threaded (ST) workqueue by switching to alloc_ordered_workqueue(). WQ_MEM_RECLAIM flag is not needed since the worker is not depended during memory reclaim. Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/dvm/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97f95c93c8ed5177371e75275f236513152fa308 Author: Sara Sharon <sara.sharon@intel.com> Date: Mon Mar 7 16:55:20 2016 +0200 iwlwifi: remove support for fw older than -16.ucode API version lower than 16 is not supported anymore - don't load older ucode. Remove code handling older versions. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-7000.c | 12 +- drivers/net/wireless/intel/iwlwifi/iwl-8000.c | 4 +- drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 4 +- drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 5 +- drivers/net/wireless/intel/iwlwifi/iwl-fw-file.h | 4 - drivers/net/wireless/intel/iwlwifi/mvm/Makefile | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/coex.c | 42 - .../net/wireless/intel/iwlwifi/mvm/coex_legacy.c | 1315 -------------------- drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c | 164 +-- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 16 - drivers/net/wireless/intel/iwlwifi/mvm/sf.c | 8 +- drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 86 -- 12 files changed, 41 insertions(+), 1621 deletions(-) commit a0b09f13036cedfd67c9cb4b9d05138e7022723d Author: Ayala Beker <ayala.beker@intel.com> Date: Wed Feb 3 15:36:52 2016 +0200 iwlwifi: mvm: update GSCAN capabilities Gscan capabilities were updated with new capabilities supported by the device. Update GSCAN capabilities TLV. Signed-off-by: Ayala Beker <ayala.beker@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 3a171386f9f1bdbe0d9835c4e68dcaadefdc872a Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Mon Mar 14 15:21:06 2016 +0200 iwlwifi: remove IWLWIFI_UAPSD Kconfig We have a module parameter, this is enough. per platform customizations will be done through the init script of the platform. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/Kconfig | 10 ---------- drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 7 ------- 2 files changed, 17 deletions(-) commit 0f851bbc28c3752440b9db334d65511909a4d427 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 16 16:28:42 2016 +0200 iwlwifi: pcie: write to legacy register also in MQ Due to hardware bug, upon any shadow free-queue register write access, a legacy RBD shadow register must be written as well. This is required in order to trigger a copy of the shadow registers values after MAC exits sleep state. Specifically, the driver has to write (any value) to the legacy RBD register each time FRBDCB is accessed. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit 24afba7690e49714795a1e8ee25e617ea0fb566b Author: Liad Kaufman <liad.kaufman@intel.com> Date: Tue Jul 28 18:56:08 2015 +0300 iwlwifi: mvm: support bss dynamic alloc/dealloc of queues "DQA" is shorthand for "dynamic queue allocation". This enables on-demand allocation of queues per RA/TID rather than statically allocating per vif, thus allowing a potential benefit of various factors. Please refer to the DOC section this patch adds to sta.h to see a more in-depth explanation of this feature. There are many things to take into consideration when working in DQA mode, and this patch is only one in a series. Note that default operation mode is non-DQA mode, unless the FW indicates that it supports DQA mode. This patch enables support of DQA for a station connected to an AP, and works in a non-aggregated mode. When a frame for an unused RA/TID arrives at the driver, it isn't TXed immediately, but deferred first until a suitable queue is first allocated for it, and then TXed by a worker that both allocates the queues and TXes deferred traffic. When a STA is removed, its queues goes back into the queue pools for reuse as needed. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/d3.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 22 +- drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 21 +- drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 49 +++++ drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 7 + drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 1 + drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 254 +++++++++++++++++++++- drivers/net/wireless/intel/iwlwifi/mvm/sta.h | 87 +++++++- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 54 +++++ 9 files changed, 481 insertions(+), 16 deletions(-) commit 7ec54716e71a846dddf6aa1e33a12e1dcca6d276 Author: Johannes Berg <johannes.berg@intel.com> Date: Wed Mar 16 09:29:48 2016 +0100 iwlwifi: mvm: remove is_data_qos variable in TX "is_data_qos == true" is equivalent to "tid < IWL_MAX_TID_COUNT" since tid is only assigned (and range-checked) in that case. This removes a (harmless) smatch warning that occurs because it can't seem to follow the above logic from the code. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 2d3d31b562dd060cbc7a163fd824421d0ebeaadf Author: Haim Dreyfuss <haim.dreyfuss@intel.com> Date: Tue Mar 15 10:51:40 2016 +0200 iwlwifi: 9000: update device id and FW serial number Update device id and FW serial number for 2X2 antenna devices in 9000 generation product. These will not be available on the market in the coming year. Signed-off-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-9000.c | 8 ++++---- drivers/net/wireless/intel/iwlwifi/iwl-config.h | 2 +- drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 10 +++++----- 3 files changed, 10 insertions(+), 10 deletions(-) commit 11dee0b4946bc8b0b4adc804f2110361fed81f08 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Tue Mar 15 11:04:29 2016 +0200 iwlwifi: make uapsd_disable module param a bitmap This allows to disable uapsd for BSS only, or P2P client separately. Remove the now unneeded IWL_MVM_P2P_UAPSD_STANDALONE constant. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 10 ++++++---- drivers/net/wireless/intel/iwlwifi/iwl-modparams.h | 10 ++++++++-- drivers/net/wireless/intel/iwlwifi/mvm/constants.h | 1 - drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 3 ++- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 3 ++- 5 files changed, 18 insertions(+), 9 deletions(-) commit a2a57a3548b94222e36a01db893b8f4788501150 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Tue Mar 15 15:36:36 2016 +0200 iwlwifi: add missing mutex_destroy statements iwlwifi / iwlmvm didn't destroy their mutexes. Fix that. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 3 +++ drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 1 + 2 files changed, 4 insertions(+) commit d8fe484470dd72638613c42df3008ec118f24de9 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 9 10:12:45 2016 +0200 iwlwifi: mvm: add support for new TX CMD API TX CMD API has changed to support offload assist. Currently we do not enable checksum yet, but must set the padding indication, to avoid FW errors. Set other amsdu flag as well. The rest of the flags will be configured only if HW csum is enabled and will be set in future patches. This change is backward compatible. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw-api-tx.h | 35 ++++++++++++++++++++-- drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 9 +++++- 2 files changed, 41 insertions(+), 3 deletions(-) commit c772a3d3fa01048ae7992663e877e0a5f05a6d36 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Mar 13 17:19:38 2016 +0200 iwlwifi: pcie: do not pad QoS AMSDU We insert padding if the MAC header's size is not a multiple of 4 to ensure that the SNAP header is DWORD aligned. When we do so, we let the firmware know by setting a bit in Tx command (TX_CMD_FLG_MH_PAD) which will instruct the firmware to drop those 2 bytes before sending the frame. However, this is not needed for AMSDU as the sub frame header (14B) complements the MAC header (26B) so that the SNAP header is DWORD aligned without adding any pad. Until 9000, the firmware didn't check the TX_CMD_FLG_MH_PAD bit but rather checked the length of the MAC header itself and assumed the entity that enqueued the frame (driver or internal firmware code) added the pad. Since the driver inserted the pad even for AMSDU this logic applied. Note that the padding is a DMA optimization but it's not strictly needed, so we could pad even if it was not needed. However, the CSUM hardware introduced for the 9000 devices requires to not pad AMSDU as it is not needed, and will fail if such a pad exists. Due to older FW not checking the padding bit but checking the mac header size itself - we cannot do this adjustments for older generations. Do not align the size if it is an AMSDU and HW checksum is enabled - which will only happen on 9000 devices and on. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) commit 6e2611f324a51dc63a8afa9ced58723e498bbf16 Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Tue Mar 15 11:12:20 2016 +0200 iwlwifi: mvm: modify the max SP to infinite This makes u-APSD work with more peers. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/power.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 6ed5e4d64a5020ac7535762bdb1c840baeb5b5ff Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Date: Mon Mar 14 19:53:57 2016 +0200 iwlwifi: pcie: print error value as signed int Bjorn pointed out that printing an error value as an hexadecimal isn't very convenient. Change that. Reported-by: Bjorn Helgaas <bhelgaas@google.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ec77a33ee59723613d1e3ed6f02e5f9a1c898ce1 Author: Chaya Rachel Ivgi <chaya.rachel.ivgi@intel.com> Date: Sun Mar 13 11:39:53 2016 +0200 iwlwifi: mvm: handle async temperature notification with unlocked mutex Use RX_HANDLER_ASYNC_UNLOCKED instead of unlock and re-lock the mutex independently. Signed-off-by: Chaya Rachel Ivgi <chaya.rachel.ivgi@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 2 +- drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) commit 5d93f3a278b387e3a2ec568c1f03d236bfdbef81 Author: Luca Coelho <luciano.coelho@intel.com> Date: Fri Mar 4 15:25:47 2016 +0200 iwlwifi: pcie: refcounting is not necessary anymore We don't use the refcount value anymore, all the refcounting is done in the runtime PM usage_count value. Remove it. Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 4 +--- drivers/net/wireless/intel/iwlwifi/pcie/internal.h | 4 ---- drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 25 ++++++++-------------- 3 files changed, 10 insertions(+), 23 deletions(-) commit 18dcb9a90cd5c49ec23130d64dd7921998068002 Author: Sara Sharon <sara.sharon@intel.com> Date: Sun Mar 13 21:48:35 2016 +0200 iwlwifi: pcie: enable interrupts explicitly on resume When entering suspend the driver calls iwl_disable_interrupts() and then iwl_pcie_disable_ict(). On resume the driver calls only iwl_pcie_reset_ict() without calling explicitly to iwl_enable_interrupts(). This mostly works since iwl_pcie_reset_ict is calling to iwl_enable_interrupts, but it doesn't work when there is no ict_table in MSIx mode. The result is that driver tries to resume but fails since it doesn't get the RX interrupt from FW indicating that d0i3 exit was completed. Fix it by adding an explicit call to enable interrupts. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 1 + 1 file changed, 1 insertion(+) commit 431469259df6ebc8e022b268bbb2d9bc5562f920 Author: Sara Sharon <sara.sharon@intel.com> Date: Mon Mar 14 13:11:47 2016 +0200 iwlwifi: pcie: fix global table size My patch resized the pool size, but neglected to resize the global table, which is obviously wrong since the global table maps the pool's rxb to vid one to one. This results in a panic in 9000 devices. Add a build bug to avoid such a case in the future. Fixes: 7b5424361ec9 ("iwlwifi: pcie: fine tune number of rxbs") Reported-by: Haim Dreyfuss <haim.dreyfuss@intel.com> Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/internal.h | 2 +- drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) commit dedfc0f3dba0713734d42efb8300760b27c5a54a Author: Aviya Erenfeld <aviya.erenfeld@intel.com> Date: Sun Mar 13 15:58:59 2016 +0200 iwlwifi: add a debugfs hook for LQM Add debugfs entry named lqm_send_cmd for kicking a measurement. This hook takes the duration and the timeout as parameter. Signed-off-by: Aviya Erenfeld <aviya.erenfeld@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> .../net/wireless/intel/iwlwifi/mvm/debugfs-vif.c | 85 ++++++++++++++++++++++ 1 file changed, 85 insertions(+) commit 03098268a30d75188f15dd8fda8f0c896d2846e5 Author: Aviya Erenfeld <aviya.erenfeld@intel.com> Date: Thu Feb 18 14:09:33 2016 +0200 iwlwifi: mvm: add LQM vendor command and notification LQM stands for Link Quality Measurement. The firmware will collect a defined set of statitics (see the notification for details) that allow to know how busy the medium is. The driver issues a request to the firmware that includes the duration of the measurement (the firmware needs to be on channel for that amount of time) and the timeout (in case the firmware has a lot of offchannel activities). If the timeout elapses, the firmware will send partial results which are still valuable. In case of disassociation / channel switch and alike, the driver is in charge of stopping the measurements and the firmware will reply with partial results. The user space API for now is debugfs only and will be implmemented in an upcoming patch. Signed-off-by: Aviya Erenfeld <aviya.erenfeld@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/iwl-fw-file.h | 2 + drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 62 ++++++++++++++++++++ drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 10 ++++ drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 12 ++++ drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 9 +++ drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 71 +++++++++++++++++++++++ 6 files changed, 166 insertions(+) commit b208ba8e49cd2b70a5e8f8f778627e5a2f050fed Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Thu Mar 24 14:31:47 2016 +0000 drm/i915: Rename __force_wake_get to __force_wake_auto __force_wake_get() only acquires a temporary wakeref on forcewake that is automatically released when a timer expires. When reading the code again, I confused __intel_uncore_forcewake_get() for __force_wake_get() and to my shame thought I found a bug in unbalanced wake_count handling. I claim that if the function had been called __force_wake_auto() instead I would not have embarrassed myself. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458829907-26596-1-git-send-email-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/intel_uncore.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit d85489d314f2d273ffb4217b77bc659900b8a3f6 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Thu Mar 24 16:47:46 2016 +0200 drm/i915: Rename GGTT init functions Rename and document the GGTT init functions to give a better idea of the context where they are called from. i915_gem_gtt_init => i915_ggtt_init_hw i915_gem_init_global_gtt => i915_gem_init_ggtt i915_global_gtt_cleanup => i915_ggtt_cleanup_hw Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458830866-12578-1-git-send-email-joonas.lahtinen@linux.intel.com drivers/gpu/drm/i915/i915_dma.c | 14 +++++++------- drivers/gpu/drm/i915/i915_gem.c | 2 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 18 +++++++++++++++--- drivers/gpu/drm/i915/i915_gem_gtt.h | 7 +++---- 4 files changed, 26 insertions(+), 15 deletions(-) commit ade7daa164709e5851836195c6cd7502cea1eb5e Author: Matthew Auld <matthew.auld@intel.com> Date: Thu Mar 24 15:54:20 2016 +0000 drm/i915: BUG_ON when ggtt_view is NULL Lets BUG_ON and don't bother with a WARN and returning an error, so we can remove the need to pollute the code with error handling, after all it is a programmer error to provide NULL view. Also while we're here remove redundant NULL ggtt_view check. Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Matthew Auld <matthew.auld@intel.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458834860-7898-1-git-send-email-matthew.auld@intel.com drivers/gpu/drm/i915/i915_gem.c | 9 ++------- drivers/gpu/drm/i915/i915_gem_gtt.c | 10 +--------- 2 files changed, 3 insertions(+), 16 deletions(-) commit 9f54d4bd5808b5c892a44c539c126b71d299f341 Author: Bjørn Mork <bjorn@mork.no> Date: Wed Mar 30 11:08:33 2016 +0200 drm/i915: fix deadlock on lid open commit e2c8b8701e2d moved modeset locking inside resume/suspend functions, but missed a code path only executed on lid close/open on older hardware. The result was a deadlock when closing and opening the lid without suspending on such hardware: ============================================= [ INFO: possible recursive locking detected ] 4.6.0-rc1 #385 Not tainted --------------------------------------------- kworker/0:3/88 is trying to acquire lock: (&dev->mode_config.mutex){+.+.+.}, at: [<ffffffffa063e6a4>] intel_display_resume+0x4a/0x12f [i915] but task is already holding lock: (&dev->mode_config.mutex){+.+.+.}, at: [<ffffffffa02d0d4f>] drm_modeset_lock_all+0x3e/0xa6 [drm] other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&dev->mode_config.mutex); lock(&dev->mode_config.mutex); *** DEADLOCK *** May be due to missing lock nesting notation 7 locks held by kworker/0:3/88: #0: ("kacpi_notify"){++++.+}, at: [<ffffffff81068dfc>] process_one_work+0x14a/0x50b #1: ((&dpc->work)#2){+.+.+.}, at: [<ffffffff81068dfc>] process_one_work+0x14a/0x50b #2: ((acpi_lid_notifier).rwsem){++++.+}, at: [<ffffffff8106f874>] __blocking_notifier_call_chain+0x34/0x65 #3: (&dev_priv->modeset_restore_lock){+.+.+.}, at: [<ffffffffa0664cf6>] intel_lid_notify+0x3c/0xd9 [i915] #4: (&dev->mode_config.mutex){+.+.+.}, at: [<ffffffffa02d0d4f>] drm_modeset_lock_all+0x3e/0xa6 [drm] #5: (crtc_ww_class_acquire){+.+.+.}, at: [<ffffffffa02d0d59>] drm_modeset_lock_all+0x48/0xa6 [drm] #6: (crtc_ww_class_mutex){+.+.+.}, at: [<ffffffffa02d0b2a>] modeset_lock+0x13c/0x1cd [drm] stack backtrace: CPU: 0 PID: 88 Comm: kworker/0:3 Not tainted 4.6.0-rc1 #385 Hardware name: LENOVO 2776LEG/2776LEG, BIOS 6EET55WW (3.15 ) 12/19/2011 Workqueue: kacpi_notify acpi_os_execute_deferred 0000000000000000 ffff88022fd5f990 ffffffff8124af06 ffffffff825b39c0 ffffffff825b39c0 ffff88022fd5fa60 ffffffff8108f547 ffff88022fd5fa70 000000008108e817 ffff880230236cc0 0000000000000000 ffffffff825b39c0 Call Trace: [<ffffffff8124af06>] dump_stack+0x67/0x90 [<ffffffff8108f547>] __lock_acquire+0xdb5/0xf71 [<ffffffff8108bd2c>] ? look_up_lock_class+0xbe/0x10a [<ffffffff8108fae2>] lock_acquire+0x137/0x1cb [<ffffffff8108fae2>] ? lock_acquire+0x137/0x1cb [<ffffffffa063e6a4>] ? intel_display_resume+0x4a/0x12f [i915] [<ffffffff8148202f>] mutex_lock_nested+0x7e/0x3a4 [<ffffffffa063e6a4>] ? intel_display_resume+0x4a/0x12f [i915] [<ffffffffa063e6a4>] ? intel_display_resume+0x4a/0x12f [i915] [<ffffffffa02d0b2a>] ? modeset_lock+0x13c/0x1cd [drm] [<ffffffffa063e6a4>] intel_display_resume+0x4a/0x12f [i915] [<ffffffffa063e6a4>] ? intel_display_resume+0x4a/0x12f [i915] [<ffffffffa02d0b2a>] ? modeset_lock+0x13c/0x1cd [drm] [<ffffffffa02d0b2a>] ? modeset_lock+0x13c/0x1cd [drm] [<ffffffffa02d0bf7>] ? drm_modeset_lock+0x17/0x24 [drm] [<ffffffffa02d0c8b>] ? drm_modeset_lock_all_ctx+0x87/0xa1 [drm] [<ffffffffa0664d6a>] intel_lid_notify+0xb0/0xd9 [i915] [<ffffffff8106f4c6>] notifier_call_chain+0x4a/0x6c [<ffffffff8106f88d>] __blocking_notifier_call_chain+0x4d/0x65 [<ffffffff8106f8b9>] blocking_notifier_call_chain+0x14/0x16 [<ffffffffa0011215>] acpi_lid_send_state+0x83/0xad [button] [<ffffffffa00112a6>] acpi_button_notify+0x41/0x132 [button] [<ffffffff812b07df>] acpi_device_notify+0x19/0x1b [<ffffffff812c8570>] acpi_ev_notify_dispatch+0x49/0x64 [<ffffffff812ab9fb>] acpi_os_execute_deferred+0x14/0x20 [<ffffffff81068f17>] process_one_work+0x265/0x50b [<ffffffff810696f5>] worker_thread+0x1fc/0x2dd [<ffffffff810694f9>] ? rescuer_thread+0x309/0x309 [<ffffffff810694f9>] ? rescuer_thread+0x309/0x309 [<ffffffff8106e2d6>] kthread+0xe0/0xe8 [<ffffffff8107bc47>] ? local_clock+0x19/0x22 [<ffffffff81484f42>] ret_from_fork+0x22/0x40 [<ffffffff8106e1f6>] ? kthread_create_on_node+0x1b5/0x1b5 Fixes: e2c8b8701e2d ("drm/i915: Use atomic helpers for suspend, v2.") Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459328913-13719-1-git-send-email-bjorn@mork.no drivers/gpu/drm/i915/intel_lvds.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 67535531b1b2bfcc707c8c37f35196cf4ede4252 Author: Archit Taneja <architt@codeaurora.org> Date: Wed Mar 30 14:53:24 2016 +0530 drm: bridge/dw-hdmi: Remove pre_enable/post_disable dummy funcs We don't need to keep empty callbacks for the (pre/post) enable/disable drm_bridge ops anymore. Remove the nop callback used here for pre_enable and post_disable ops. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1459329804-10488-1-git-send-email-architt@codeaurora.org drivers/gpu/drm/bridge/dw-hdmi.c | 7 ------- 1 file changed, 7 deletions(-) commit 9ec423ed62b8278412400fae6c064edb6ce1bb51 Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Mon Mar 28 10:38:31 2016 +0200 ARM: dts: kirkwood: add kirkwood-nsa320.dtb to Makefile Commit be3d7d023b87 ("ARM: kirkwood: Add DTS file for NSA320") created the new file kirkwood-nsa320.dts but did not add it to the Makefile. Fixes: be3d7d023b87 ("ARM: kirkwood: Add DTS file for NSA320") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + 1 file changed, 1 insertion(+) commit fc5c796e12511a7c027b5a4438719dde2f796208 Author: Heinrich Schuchardt <xypron.glpk@gmx.de> Date: Mon Mar 28 10:03:48 2016 +0200 ARM: dts: kirkwood: add kirkwood-ds112.dtb to Makefile Commit 2d0a7addbd10 ("ARM: Kirkwood: Add support for many Synology NAS devices") created the new file kirkwood-ds112.dts but did not add it to the Makefile. Fixes: 2d0a7addbd10 ("ARM: Kirkwood: Add support for many Synology NAS devices") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + 1 file changed, 1 insertion(+) commit 9800917cf92f5b5fe5cae706cb70db8d014f663c Author: Imre Kaloz <kaloz@openwrt.org> Date: Fri Jul 31 20:42:00 2015 +0200 ARM: mvebu: fix GPIO config on the Linksys boards Some of the GPIO configs were wrong in the submitted DTS files, this patch fixes all affected boards. Signed-off-by: Imre Kaloz <kaloz@openwrt.org> Cc: <stable@vger.kernel.org> # v4.1 + Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/armada-385-linksys.dtsi | 6 +++--- arch/arm/boot/dts/armada-xp-linksys-mamba.dts | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) commit 916fe619951f41b55d4f2b9f26d64ad981bc0dfa Author: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Date: Tue Mar 29 17:35:47 2016 -0300 leds: trigger: Introduce a kernel panic LED trigger This commit introduces a new LED trigger which allows to configure a LED to blink on a kernel panic (through panic_blink). Notice that currently the Openmoko FreeRunner (GTA02) mach code sets panic_blink to blink a hard-coded LED. The new trigger is meant to introduce a generic mechanism to achieve this. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> drivers/leds/trigger/Kconfig | 7 +++++++ drivers/leds/trigger/Makefile | 1 + drivers/leds/trigger/ledtrig-panic.c | 30 ++++++++++++++++++++++++++++++ 3 files changed, 38 insertions(+) commit d94780444bf3da8fc35e281aec6bbffa54a4a01a Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 16:35:27 2015 +0100 input: ad7879: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Acked-by: Michael Hennerich <michael.hennerich@analog.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/input/touchscreen/ad7879.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 839850f4fb76b56fcad3cabe27fc9f1a03821a2c Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 16:32:08 2015 +0100 input: adp5589-keys: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Acked-by: Michael Hennerich <michael.hennerich@analog.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/input/keyboard/adp5589-keys.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit fd19f534ab7660883191d5f3c9d01f0c6f444aea Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 16:07:09 2015 +0100 unicore32: gpio: switch to gpiochip_add_data() We're planning to remove the gpiochip_add() function to swith to gpiochip_add_data() with NULL for data argument. Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/unicore32/kernel/gpio.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit efed58f1c574a31c03447afffe69440e83fdf84d Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 16:02:00 2015 +0100 sh: x3proto-gpio: switch to gpiochip_add_data() We're planning to remove the gpiochip_add() function to swith to gpiochip_add_data() with NULL for data argument. Cc: Paul Mundt <lethal@linux-sh.org> Cc: linux-sh@vger.kernel.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/sh/boards/mach-x3proto/gpio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a8cb826aeab84553a30af22ca6d6b95a6513adb2 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:58:33 2015 +0100 sh: sdk7786-gpio: switch to gpiochip_add_data() We're planning to remove the gpiochip_add() function to swith to gpiochip_add_data() with NULL for data argument. Cc: Paul Mundt <lethal@linux-sh.org> Cc: linux-sh@vger.kernel.org Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/sh/boards/mach-sdk7786/gpio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 937daafca774b05633f436c19885c8cb3cbdcc8a Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:53:29 2015 +0100 powerpc: simple-gpio: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anton Vorontsov <anton@enomsg.org> Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/sysdev/simple_gpio.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit 1e714e54b5ca5bfc75bc43ed41f8217242e831fe Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:49:10 2015 +0100 powerpc: qe_lib-gpio: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/soc/fsl/qe/gpio.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) commit 0d36fe65f58391712e11a6621075f373216e5f00 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:34:12 2015 +0100 powerpc: ppc4xx: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/sysdev/ppc4xx_gpio.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit a14a2d484b386972f9027246dbe5d066519edb9f Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:05:43 2015 +0100 powerpc: cpm_common: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/sysdev/cpm_common.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) commit e65078f1f3490c753f8c223b088e8a482968b891 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 15:00:49 2015 +0100 powerpc: sysdev: cpm1: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/sysdev/cpm1.c | 36 ++++++++++++------------------------ 1 file changed, 12 insertions(+), 24 deletions(-) commit da5f767ef66a4c71109fdb8577b36864abc3263c Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 14:54:45 2015 +0100 powerpc: mpc8349emitx: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/platforms/83xx/mcu_mpc8349emitx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit e99190cea39022690193938ff3e80d2faa98f389 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Dec 8 14:49:42 2015 +0100 powerpc: mpc52xx_gpt: use gpiochip data pointer This makes the driver use the data pointer added to the gpio_chip to store a pointer to the state container instead of relying on container_of(). Cc: Anatolij Gustschin <agust@denx.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/powerpc/platforms/52xx/mpc52xx_gpt.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit ca27379f5d2956e08558fbfc0d35b3ba64abbe0c Author: YD Tseng <Yd_Tseng@asmedia.com.tw> Date: Thu Mar 17 11:35:57 2016 +0800 gpio: amdpt: Add a new ACPI HID This patch adds a new ACPI HID, AMDIF030, in the pt_gpio_acpi_match. Signed-off-by: YD Tseng<Yd_Tseng@asmedia.com.tw> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-amdpt.c | 1 + 1 file changed, 1 insertion(+) commit b6d055b198b70c430a0b7e78280e8ef35e44f319 Author: Axel Lin <axel.lin@ingics.com> Date: Fri Mar 18 21:06:06 2016 +0800 gpio: octeon: Constify octeon_gpio_match table Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-octeon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 592569de4c247fe4f25db8369dc0c63860f9560b Author: Axel Lin <axel.lin@ingics.com> Date: Fri Mar 18 21:05:16 2016 +0800 gpio: octeon: Convert to use devm_ioremap_resource Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-octeon.c | 24 +++++++----------------- 1 file changed, 7 insertions(+), 17 deletions(-) commit 574b782e7b632974e85e8629842746d0229c4aed Author: Axel Lin <axel.lin@ingics.com> Date: Mon Feb 29 22:00:01 2016 +0800 gpio: amdpt: Convert to use gpio-generic Use gpio-generic to simplify this driver. Signed-off-by: Axel Lin <axel.lin@ingics.com> Tested-by: YD Tseng <Yd_Tseng@asmedia.com.tw> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 1 + drivers/gpio/gpio-amdpt.c | 122 ++++++---------------------------------------- 2 files changed, 15 insertions(+), 108 deletions(-) commit f7aed67d632f6e316b9a9e2fe2818a07bfa42e81 Author: Linus Walleij <linus.walleij@linaro.org> Date: Tue Mar 22 14:28:34 2016 +0100 gpio: mcp23s08: delete req/rel_resource callbacks When using the GPIOLIB_IRQCHIP the gpiolib provides a straight-forward implementation of request/release resources, rely on that instead. Cc: Phil Reid <preid@electromag.com.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mcp23s08.c | 25 ------------------------- 1 file changed, 25 deletions(-) commit dad3d272957b006b9069486597610840f7063350 Author: Phil Reid <preid@electromag.com.au> Date: Fri Mar 18 16:07:06 2016 +0800 gpio: mcp23s08: switch to use gpiolib irqchip helpers This switches the mcp23s08 driver to use the gpiolib irqchip helpers. Signed-off-by: Phil Reid <preid@electromag.com.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/Kconfig | 1 + drivers/gpio/gpio-mcp23s08.c | 85 ++++++++++++++++---------------------------- 2 files changed, 31 insertions(+), 55 deletions(-) commit d46ab6823963de2165f5a2af7600ce830e990e53 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:19:18 2016 +0100 gpio: 74x164: Implement gpiochip.set_multiple() This allows to set multiple outputs using a single SPI transfer. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Phil Reid <preid@electromag.com.au> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-74x164.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit dbb763b8ea5d8eb0ce3e45e289969f6f1f418921 Author: Geert Uytterhoeven <geert+renesas@glider.be> Date: Mon Mar 14 16:21:44 2016 +0100 gpio: rcar: Implement gpiochip.set_multiple() This allows to set multiple outputs using a single register write. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-rcar.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit f85834229b1808781b0b56a9d637e19312916300 Author: Axel Lin <axel.lin@ingics.com> Date: Wed Mar 9 20:48:15 2016 +0800 gpio: mb86s7x: Remove redundant platform_set_drvdata() call Set it once is enough, so remove the second platform_set_drvdata() call. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-mb86s7x.c | 2 -- 1 file changed, 2 deletions(-) commit 86d3f367686852cde028cf6c12cb0e944f28a784 Author: Axel Lin <axel.lin@ingics.com> Date: Wed Mar 9 20:39:57 2016 +0800 gpio: menz127: Drop *mdev field from struct men_z127_gpio No need to store *medv in struct men_z127_gpio. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> drivers/gpio/gpio-menz127.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit 68d4aee9d1f271fe06e904cb99a10cf8479d3d2e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 30 09:33:11 2016 +0200 drm/i915: Update DRIVER_DATE to 20160330 Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a91d7b9142b91c9567bc0304cb7d718ac411e85e Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Mar 29 13:12:22 2016 +0200 Revert "drm: Don't pass negative delta to ktime_sub_ns()" This reverts commit e91abf80a0998f326107874c88d549f94839f13c. Since commit 24e4a8c3e8868874835b0f1ad6dd417341e99822 Author: John Stultz <john.stultz@linaro.org> Date: Wed Jul 16 21:03:53 2014 +0000 ktime: Kill non-scalar ktime_t implementation for 2038 there is no longer a 32bit version that's unsigned, and we don't have to jump through ridiculous hoops to make the calculations correct. I didn't look whether there's more of this pattern in the kernel. Cc: John Stultz <john.stultz@linaro.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Michel Dänzer <michel.daenzer@amd.com> Cc: Imre Deak <imre.deak@intel.com> Cc: Dave Airlie <airlied@redhat.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459249942-21589-1-git-send-email-daniel.vetter@ffwll.ch drivers/gpu/drm/drm_irq.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit a16b7658f4e0d4aec9bc3e75a5f0cc3f7a3a0422 Author: Lyude <cpaul@redhat.com> Date: Fri Mar 11 10:57:01 2016 -0500 drm/i915: Call intel_dp_mst_resume() before resuming displays Since we need MST devices ready before we try to resume displays, calling this after intel_display_resume() can result in some issues with various laptop docks where the monitor won't turn back on after suspending the system. This order was originally changed in commit e7d6f7d70829 ("drm/i915: resume MST after reading back hw state") In order to fix some unclaimed register errors, however the actual cause of those has since been fixed. CC: stable@vger.kernel.org Signed-off-by: Lyude <cpaul@redhat.com> [danvet: Resolve conflicts with locking changes.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a7442b93cf32c1e1ddb721a26cd1f92302e2a222 Author: Lukas Wunner <lukas@wunner.de> Date: Wed Mar 9 12:52:53 2016 +0100 drm/i915: Fix races on fbdev The ->lastclose callback invokes intel_fbdev_restore_mode() and has been witnessed to run before intel_fbdev_initial_config_async() has finished. We might likewise receive hotplug events before we've had a chance to fully set up the fbdev. Fix by waiting for the asynchronous thread to finish. v2: An async_synchronize_full() was also added to intel_fbdev_set_suspend() in v1 which turned out to be entirely gratuitous. It caused a deadlock on suspend (discovered by CI, thanks to Damien Lespiau and Tomi Sarvela for CI support) and was unnecessary since a device is never suspended until its ->probe callback (and all asynchronous tasks it scheduled) have finished. See dpm_prepare(), which calls wait_for_device_probe(), which calls async_synchronize_full(). Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93580 Reported-by: Gustav Fägerlind <gustav.fagerlind@gmail.com> Reported-by: "Li, Weinan Z" <weinan.z.li@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: stable@vger.kernel.org Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/20160309115147.67B2B6E0D3@gabe.freedesktop.org drivers/gpu/drm/i915/i915_dma.c | 8 +++----- drivers/gpu/drm/i915/intel_fbdev.c | 3 +++ 2 files changed, 6 insertions(+), 5 deletions(-) commit 5759d6cdd48587968256859912b1c967a57eb6e1 Merge: 2aac7dd d3d6f15 Author: Stephen Boyd <sboyd@codeaurora.org> Date: Tue Mar 29 16:37:54 2016 -0700 Merge tag 'bcm2835-clk-next-2016-03-17' of git://github.com/anholt/linux into clk-next This pull request against clk/clk-next brings in fixes for fractional clocks on 2835, add the PCM clock that used to be driven directly by the bcm2835-i2s driver (that driver has been broken since this driver was introduced), and adds many other new clocks. * tag 'bcm2835-clk-next-2016-03-17' of git://github.com/anholt/linux: clk: bcm2835: add missing osc and per clocks clk: bcm2835: add missing PLL clock dividers clk: bcm2835: enable management of PCM clock clk: bcm2835: reorganize bcm2835_clock_array assignment clk: bcm2835: remove use of BCM2835_CLOCK_COUNT in driver clk: bcm2835: expose raw clock-registers via debugfs clk: bcm2835: clean up coding style issues clk: bcm2835: correctly enable fractional clock support clk: bcm2835: divider value has to be 1 or more clk: bcm2835: add locking to pll*_on/off methods clk: bcm2835: pll_off should only update CM_PLL_ANARST commit 45a91e8f767afbbffff46bf7251f81d15d121136 Author: Mark Brown <broonie@kernel.org> Date: Tue Mar 29 16:33:42 2016 -0700 regulator: core: Log when we bring constraints into range This aids in debugging problems triggered by the regulator core applying its constraints, we could potentially crash immediately after updating the voltage if the constraints are buggy. Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 2 ++ 1 file changed, 2 insertions(+) commit 9fca845577c07e7bbd659625e03dfda8ebda4b91 Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Sat Mar 26 10:54:13 2016 +0200 Staging: wlan-ng: removed "next" member of wlandevice_t since it is not used anywhere in code. This patch removes "next" member of wlandevice_t since it is not used anywhere in the wlan-ng code. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/p80211netdev.h | 1 - 1 file changed, 1 deletion(-) commit f0e00da2db61c9052fbc07edf2b2bf615b7a4bbe Author: Colin Ian King <colin.king@canonical.com> Date: Tue Mar 29 17:53:23 2016 +0100 staging: sm750fb: initialize max_d to maximum D value of 6 max_d is not initialized and should be set to the largest D value of 6. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/sm750fb/ddk750_chip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7d47383dcb3f5867de56ac04ce46db06ac47ad0b Author: Dominique van den Broeck <domdevlin@free.fr> Date: Tue Mar 29 19:14:21 2016 +0200 staging: fwserial: (coding style) removing "!= NULL" to comply with checkpatch.pl Removing two "!= NULL" from fwserial.c as suggested by checkpatch.pl. Note that the associated expression "port->port.console" is a 1-bit-field that is already assumed as an implicit boolean (that is: without comparison) Signed-off-by: Dominique van den Broeck <domdevlin@free.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fwserial/fwserial.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit eeb6f1ba921d413157282a573290c0eb57d549d7 Author: Dominique van den Broeck <domdevlin@free.fr> Date: Tue Mar 29 19:14:20 2016 +0200 staging: fwserial: (coding style) Turning every "unsigned" into "unsigned int" Coding-style-only modifications to remove every warning saying: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Compiled against revision "next-20160327". (checkpatch.pl was updated to treat "UNSPECIFIED_INT" warnings as of commit a1ce18e4f941d20 ) Signed-off-by: Dominique van den Broeck <domdevlin@free.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fwserial/dma_fifo.c | 8 +++---- drivers/staging/fwserial/dma_fifo.h | 16 +++++++------- drivers/staging/fwserial/fwserial.c | 38 +++++++++++++++++---------------- drivers/staging/fwserial/fwserial.h | 42 ++++++++++++++++++------------------- 4 files changed, 53 insertions(+), 51 deletions(-) commit dbacb0ef670d057a2c52c0e1e642bab727f6b4cb Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Tue Jan 26 21:51:05 2016 -0500 kconfig option for TRIM_UNUSED_KSYMS The config option to enable it all. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> init/Kconfig | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit dd92478a15fa3bfd746ee08b4ef59401c1537804 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Sun Feb 28 22:00:00 2016 -0500 kbuild: build sample modules along with the rest of the kernel Make sample modules in parallel with the rest of the kernel rather than having them built from the vmlinux target. This makes the build slightly faster, and those modules are properly considered when adjust_autoksyms.sh is executed. Signed-off-by: Nicolas Pitre <nico@linaro.org> Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) commit 23121ca2b56b583c43512e4d7a926343be937714 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Tue Jan 26 21:50:18 2016 -0500 kbuild: create/adjust generated/autoksyms.h Given the list of exported symbols needed by all modules, we can create a header file containing preprocessor defines for each of those symbols. Also, when some symbols are added and/or removed from the list, we can update the time on the corresponding files used as build dependencies for those symbols. And finally, if any symbol did change state, the corresponding source files must be rebuilt. The insertion or removal of an EXPORT_SYMBOL() entry within a module may create or remove the need for another exported symbol. This is why this operation has to be repeated until the list of needed exported symbols becomes stable. Only then the final kernel and modules link take place. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Makefile | 13 ++++++ scripts/adjust_autoksyms.sh | 101 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 114 insertions(+) commit c1a95fda2a40ae8c7aad3fa44fa7718a3710eb2d Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Fri Jan 22 13:41:57 2016 -0500 kbuild: add fine grained build dependencies for exported symbols Like with kconfig options, we now have the ability to compile in and out individual EXPORT_SYMBOL() declarations based on the content of include/generated/autoksyms.h. However we don't want the entire world to be rebuilt whenever that file is touched. Let's apply the same build dependency trick used for CONFIG_* symbols where the time stamp of empty files whose paths matching those symbols is used to trigger fine grained rebuilds. In our case the key is the symbol name passed to EXPORT_SYMBOL(). However, unlike config options, we cannot just use fixdep to parse the source code for EXPORT_SYMBOL(ksym) because several variants exist and parsing them all in a separate tool, and keeping it in synch, is not trivially maintainable. Furthermore, there are variants such as EXPORT_SYMBOL_GPL(pci_user_read_config_##size); that are instanciated via a macro for which we can't easily determine the actual exported symbol name(s) short of actually running the preprocessor on them. Storing the symbol name string in a special ELF section doesn't work for targets that output assembly or preprocessed source. So the best way is really to leverage the preprocessor by having it output actual symbol names anchored by a special sequence that can be easily filtered out. Then the list of symbols is simply fed to fixdep to be merged with the other dependencies. That implies the preprocessor is executed twice for each source file. A previous attempt relied on a warning pragma for each EXPORT_SYMBOL() instance that was filtered apart from stderr by the build system with a sed script during the actual compilation pass. Unfortunately the preprocessor/compiler diagnostic output isn't stable between versions and this solution, although more efficient, was deemed too fragile. Because of the lowercasing performed by fixdep, there might be name collisions triggering spurious rebuilds for similar symbols. But this shouldn't be a big issue in practice. (This is the case for CONFIG_* symbols and I didn't want to be different here, whatever the original reason for doing so.) To avoid needless build overhead, the exported symbol name gathering is performed only when CONFIG_TRIM_UNUSED_KSYMS is selected. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> include/linux/export.h | 13 ++++++++++++- scripts/Kbuild.include | 27 +++++++++++++++++++++++++++ scripts/basic/fixdep.c | 1 + 3 files changed, 40 insertions(+), 1 deletion(-) commit e4aca45950050fc584e036bb1b266ce1264a6daf Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Wed Feb 17 15:50:06 2016 -0500 kbuild: de-duplicate fixdep usage The generation and postprocessing of automatic dependency rules is duplicated in rule_cc_o_c, rule_as_o_S and if_changed_dep. Since this is not a trivial one-liner action, it is now abstracted under cmd_and_fixdep to simplify things and make future changes in this area easier. In the rule_cc_o_c and rule_as_o_S cases that means the order of some commands has been altered, namely fixdep and related file manipulations are executed earlier, but they didn't depend on those commands that now execute later. Signed-off-by: Nicolas Pitre <nico@linaro.org> scripts/Kbuild.include | 5 ++++- scripts/Makefile.build | 19 +++++-------------- 2 files changed, 9 insertions(+), 15 deletions(-) commit d8329e35cc08e07a3250b3873325d300c1e91c81 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Fri Feb 12 15:00:50 2016 -0500 fixdep: accept extra dependencies on stdin ... and merge them in the list of parsed dependencies. Signed-off-by: Nicolas Pitre <nico@linaro.org> scripts/basic/fixdep.c | 60 +++++++++++++++++++++++++++++++++++++------------- 1 file changed, 45 insertions(+), 15 deletions(-) commit f235541699bcf14fb8be797c6bc1d7106df0eb64 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Fri Jan 22 01:32:26 2016 -0500 export.h: allow for per-symbol configurable EXPORT_SYMBOL() Similar to include/generated/autoconf.h, include/generated/autoksyms.h will contain a list of defines for each EXPORT_SYMBOL() that we want active. The format is: #define __KSYM_<symbol_name> 1 This list will be auto-generated with another patch. For now we only include the preprocessor magic to automatically create or omit the corresponding struct kernel_symbol declaration. Given the content of include/generated/autoksyms.h may not be known in advance, an empty file is created early on to let the build proceed. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> Makefile | 2 ++ include/linux/export.h | 22 ++++++++++++++++++++-- 2 files changed, 22 insertions(+), 2 deletions(-) commit 7e7a3e9c892ab798da2be67fe842b77f3bdee317 Author: Joachim Eastwood <manabian@gmail.com> Date: Tue Mar 1 16:53:06 2016 +0100 ARM: dts: lpc4350-hitex-eval: add adc1 Enable adc1 on LPC4350 Hitex Evalution board. This board has a 10k potensiometer (R26) connected to ADC1 channel 2. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc4350-hitex-eval.dts | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) commit 31b8f1af5a055a968999e88cdb16622f7bbf38df Author: Joachim Eastwood <manabian@gmail.com> Date: Mon Feb 29 07:07:15 2016 +0100 ARM: dts: lpc4357-ea4357: add dac Enable the DAC on the EA4357 dev kit. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc4357-ea4357-devkit.dts | 5 +++++ 1 file changed, 5 insertions(+) commit 5f2d9d18b2400590ffa1253a689fc22c87e58302 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun Feb 28 20:47:20 2016 +0100 ARM: dts: lpc4357-ea4357: add adc0 Enable adc0 on EA4357 dev kit. This kit has a 22k potentiometer (R94) connected on ADC0 channel 3. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc4357-ea4357-devkit.dts | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 8c938004f529b954db1d8e7b2800d728f4de8667 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun Feb 28 23:48:18 2016 +0100 ARM: dts: lpc18xx: add dac node Add node for the 10-bit DAC found on all lpc18xx SoCs. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc18xx.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit e162f9c2c65f8178420abb70ebbfc19ea0c51b52 Author: Joachim Eastwood <manabian@gmail.com> Date: Sun Feb 28 20:20:54 2016 +0100 ARM: dts: lpc18xx: add adc nodes Add nodes for the two 10-bit ADCs found on all lpc18xx SoCs. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc18xx.dtsi | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) commit 246fee6cb7a1d2a283e1e16e77e783300574d0b5 Author: Joachim Eastwood <manabian@gmail.com> Date: Thu Apr 2 05:32:34 2015 +0200 ARM: dts: lpc18xx: add rtc node Add node for the internal RTC found on all lpc18xx SoCs. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc18xx.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) commit b2073dcb80b61043f6ae6aeb2311907b0418392a Author: Ian Abbott <abbotti@mev.co.uk> Date: Tue Mar 29 10:49:04 2016 +0100 staging: comedi: comedi_fops.c: fix lines over 80 characters Fix checkpatch.pl warnings about lines over 80 characters in "comedi_fops.c". Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/comedi_fops.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) commit ae6b08672fd1802abbdd12dcda7553a7f1f009ad Author: Aniket Sharma <badbuddha91@gmail.com> Date: Sun Mar 27 10:52:19 2016 -0700 Staging: comedi: Fix 'unsigned' warning style This patch fixes the checkpatch.pl warning: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' + unsigned runflags; WARNING: Prefer 'unsigned int' to bare use of 'unsigned' +struct comedi_device *comedi_dev_get_from_minor(unsigned minor); Signed-off-by: Aniket Sharma <badbuddha91@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/comedidev.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 143b3bf6d3f7e14945af589414f1bd29efe36a72 Author: Bhumika Goyal <bhumirks@gmail.com> Date: Sat Mar 26 12:52:28 2016 +0530 Staging: rts5208: rtsx_card.c: Remove unused function The functions double_depth, check_card_fail, check_card_ejected are not used anywhere in the kernel. So, remove their prototype and definition. Grepped to find occurences. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rts5208/rtsx_card.c | 21 --------------------- drivers/staging/rts5208/rtsx_card.h | 2 -- 2 files changed, 23 deletions(-) commit 3cb61bdf14af55e71095f4d11187a79116b30e3f Author: Bhumika Goyal <bhumirks@gmail.com> Date: Sat Mar 26 12:42:43 2016 +0530 Staging: rts5208: Remove unused functions The functions rtsx_disable_card_int, rtsx_undo_delink, rtsx_check_link_ready are not used anywhere in the kernel. So,remove their definition and prototype. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rts5208/rtsx_chip.c | 35 ----------------------------------- drivers/staging/rts5208/rtsx_chip.h | 3 --- 2 files changed, 38 deletions(-) commit 686855e033faf191b499315758ae2c40f230a3bc Author: Ben Marsh <bmarsh94@gmail.com> Date: Fri Mar 25 22:44:48 2016 +0100 Staging: gs_fpgaboot: remove blank line in io.c Removes a blank line in order to silence a checkpatch.pl warning. Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gs_fpgaboot/io.c | 1 - 1 file changed, 1 deletion(-) commit 71fa2cf90ad46b925c27c372fac9b927e8014ebf Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Fri Mar 25 23:28:54 2016 +0200 Staging: wlan-ng: convert usb_prism_tbl[] array into a const array This patch convert usb_prism_tbl[] into a const array since it is not modified anywhere in prism2usb.c file. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/prism2usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7a4000e7128d9432ba78bc398bbedc6066825b80 Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Fri Mar 25 22:54:48 2016 +0200 Staging: wlan-ng: no need for memcpy() since its arguments are already equal This patch removes the memcpy() for two variables which were previously tested with memcmp(). The result of memcmp() was zero which means that the previously tested variables were already equal. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/p80211conv.c | 1 - 1 file changed, 1 deletion(-) commit db71dd988af5ffdc6280e93977591b3ebc4c7673 Author: Ian Abbott <abbotti@mev.co.uk> Date: Wed Mar 23 10:55:21 2016 +0000 staging: comedi: drivers: remove bogus ni_mio_c_common.c The zero-length file "ni_mio_c_common.c" was inadvertantly created by commit e563637b5fef ("staging: comedi: Use ARRAY_SIZE for sizes of arrays"). Remove it. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_c_common.c | 0 1 file changed, 0 insertions(+), 0 deletions(-) commit 15ac352c5402513bd7bee5cfe6439118b5a5f337 Author: Bhumika Goyal <bhumirks@gmail.com> Date: Sat Mar 26 11:54:55 2016 +0530 Staging: rtl8723au: Remove function rtw_enqueue_{recvbuf23a/recvbuf23a_to_head} The functions rtw_enqueue_recvbuf23a and rtw_enqueue_recvbuf23a_to_head are never used anywhere in the kernel. So, remove their definition and prototype. Grepped to find occurences. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Acked-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/core/rtw_recv.c | 25 ------------------------- drivers/staging/rtl8723au/include/rtw_recv.h | 2 -- 2 files changed, 27 deletions(-) commit 0d6b23a427a9c62f93a175187cedcd4f3a3a95d7 Author: Bhumika Goyal <bhumirks@gmail.com> Date: Sat Mar 26 11:44:52 2016 +0530 Staging: rtl8723au: Remove unused functions The functions rtw_get_oper_bw23a and rtw_get_oper_ch23aoffset are never used anywhere in the kernel. So, remove their definition and prototype. Grepped to find occurences. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Reviewed-by: Julian Calaby <julian.calaby@gmail.com> Acked-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/core/rtw_wlan_util.c | 10 ---------- drivers/staging/rtl8723au/include/rtw_mlme_ext.h | 2 -- 2 files changed, 12 deletions(-) commit d312007698241b79153d5ac101bddb14fa9c4956 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Sun Mar 27 15:13:03 2016 -0400 staging: xgifb: fix bare use of 'unsigned' fix checkpatch.pl warning about 'Prefer 'unsigned int' to bare use of 'unsigned'' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/XGI_main_26.c | 5 +++-- drivers/staging/xgifb/vb_util.h | 8 +++++--- 2 files changed, 8 insertions(+), 5 deletions(-) commit c3f0692aeed9e79f52c53284df7471aeb8006b43 Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Sun Mar 27 15:13:01 2016 -0400 staging: xgifb: fix code indent fix checkpatch.pl warning about 'suspect code indent for conditional statements' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/vb_setmode.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit d3d62d1d6c479dd2058694c36b7d7d54cbe3d42f Author: Clifton Barnes <clifton.a.barnes@gmail.com> Date: Sun Mar 27 15:13:00 2016 -0400 staging: xgifb: fix 'line over 80 characters' fix checkpatch.pl warning about 'line over 80 characters' Signed-off-by: Clifton Barnes <clifton.a.barnes@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/vb_init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit ff3334276744ad49477e60c3c9e6acec8399b25d Author: Joe Perches <joe@perches.com> Date: Mon Mar 28 16:51:17 2016 -0700 staging: skein: Convert local rotl_64 to kernel's rol64 Remove the local inline and use the generic kernel rol64 instead. Miscellanea: o Added a newline between a multiple line macro for consistency with the other multiple line macros Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/skein_base.h | 5 ----- drivers/staging/skein/skein_block.c | 30 ++++++++++++++++-------------- 2 files changed, 16 insertions(+), 19 deletions(-) commit 086620978b2d06378f4a41afce2f7705c76a4625 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 28 13:56:00 2016 +0900 staging: wilc1000: use mutex instead of struct semaphore hSemScanReq This patch replaces struct semaphore hSemScanReq with struct mutex scan_req_lock. It is better to use mutex than semaphore. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 10 +++++----- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) commit 589c667d8ae1d7359a974719dd0d09f85aee5606 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 28 13:55:59 2016 +0900 staging: wilc1000: remove unused struct semaphore SemHandleUpdateStats struct semaphore SemHandleUpdateStats is defined but never used in this driver, so just remove it. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 1 - drivers/staging/wilc1000/wilc_wfi_netdevice.h | 1 - 2 files changed, 2 deletions(-) commit c975f9dd106461794d339348e2f4b4812d154875 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 28 13:55:58 2016 +0900 staging: wilc1000: change data type of wid argument in wilc_wlan_cfg_get_val This patch changes data type of wid argument in wilc_wlan_cfg_get_val from u32 to u16. It is better to change data type of wid because wid has one of enum WID_T that is data type of u16. And, there is no need to use u16 type casting when calling wilc_wlan_cfg_get_wid_value function. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 4 ++-- drivers/staging/wilc1000/wilc_wlan.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 7db699dbe5107073050c123b05495e9c271f62fe Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 28 13:55:57 2016 +0900 staging: wilc1000: change data type of wid argument in wilc_wlan_cfg_get This patch changes data type of wid argument in wilc_wlan_cfg_get from u32 to u16. It is better to change data type of wid because wid has one of enum WID_T that is data type of u16. And, there is no need to use u16 type casting when calling wilc_wlan_cfg_get_wid function. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 5 ++--- drivers/staging/wilc1000/wilc_wlan.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) commit 70011f5f2cbdadb52536ae752d2a4d59189df03f Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 28 13:55:56 2016 +0900 staging: wilc1000: change data type of wid argument in wilc_wlan_cfg_set This patch changes data type of wid argument in wilc_wlan_cfg_set from u32 to u16. It is better to change data type of wid because wid has one of enum WID_T that is data type of u16. And, there is no need to use u16 type casting when calling wilc_wlan_cfg_set_wid function. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 4 ++-- drivers/staging/wilc1000/wilc_wlan.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) commit 479d75b7603c3db0cbaafb4368e3c3ba0da80864 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 16 14:58:43 2016 +0100 arm64: dts: rockchip: Clean up gpio-keys nodes Drop superfluous #address-cells and #size-cells. Use KEY_POWER define for 116. Rename sub-nodes to avoid new dtc warnings. Reported-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Julien Chauveau <chauveau.julien@gmail.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi | 7 +++---- arch/arm64/boot/dts/rockchip/rk3368-r88.dts | 7 +++---- 2 files changed, 6 insertions(+), 8 deletions(-) commit 33e84ad03294b17d85a592ed4c5e80618bd197d3 Author: Andreas Färber <afaerber@suse.de> Date: Wed Mar 16 14:58:40 2016 +0100 dt-bindings: Add vendor prefix for GeekBuying.com Use "geekbuying". Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) commit 6e7f9f5ad552327fcc1151e2dca141075f3e160a Author: Caesar Wang <wxt@rock-chips.com> Date: Tue Oct 27 15:31:46 2015 +0800 arm64: dts: rockchip: Add rk3368 mailbox device nodes This adds mailbox device nodes in dts. Mailbox is used by the Rockchip CPU cores to communicate requests to MCU processor. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3368.dtsi | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 5d145b1ad404e8cb260283d8a8b0747261698c73 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:29 2016 -0400 staging: lustre: libcfs: remove cfs_workitem_t typedefs Convert cfs_workitem_t to proper structure. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17202 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_hash.h | 4 ++-- .../staging/lustre/include/linux/libcfs/libcfs_workitem.h | 12 ++++++------ drivers/staging/lustre/lnet/libcfs/hash.c | 6 +++--- drivers/staging/lustre/lnet/libcfs/workitem.c | 12 ++++++------ drivers/staging/lustre/lnet/selftest/selftest.h | 4 ++-- 5 files changed, 19 insertions(+), 19 deletions(-) commit d47b7026ba96f604318e46354e8ec129f9b960d7 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:28 2016 -0400 staging: lustre: libcfs: add CFS_FAULT_CHECK() Add the macro CFS_FAULT_CHECK() which behaves like CFS_FAIL_CHECK() except that any site may be matched by setting CFS_FAULT (0x02000000) in cfs_fail_loc. Add cfs_fail_err for use as a return value with CFS_FAULT_CHECK(). Signed-off-by: John L. Hammond <john.hammond@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5409 Reviewed-on: http://review.whamcloud.com/11263 Reviewed-by: Robert Read <robert.read@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_fail.h | 15 ++++++++++++--- drivers/staging/lustre/lnet/libcfs/fail.c | 3 +++ drivers/staging/lustre/lnet/libcfs/module.c | 7 +++++++ 3 files changed, 22 insertions(+), 3 deletions(-) commit 304d13ff4d5dcccea2cf199d96d6716de31b7321 Author: Jian Yu <jian.yu@intel.com> Date: Sun Mar 27 20:26:27 2016 -0400 staging: lustre: libcfs: replace direct HZ access with kernel APIs On some customers' systems, the kernel was compiled with HZ defined to 100, instead of 1000. This improves performance for HPC applications. However, to use these systems with Lustre, customers have to re-build Lustre for the kernel because Lustre directly uses the defined constant HZ. Since kernel 2.6.21, some non-HZ dependent timing APIs become non- inline functions, which can be used in Lustre codes to replace the direct HZ access. These kernel APIs include: jiffies_to_msecs() jiffies_to_usecs() jiffies_to_timespec() msecs_to_jiffies() usecs_to_jiffies() timespec_to_jiffies() And here are some samples of the replacement: HZ -> msecs_to_jiffies(MSEC_PER_SEC) n * HZ -> msecs_to_jiffies(n * MSEC_PER_SEC) HZ / n -> msecs_to_jiffies(MSEC_PER_SEC / n) n / HZ -> jiffies_to_msecs(n) / MSEC_PER_SEC n / HZ * 1000 -> jiffies_to_msecs(n) This patch replaces the direct HZ access in the libcfs module. Signed-off-by: Jian Yu <jian.yu@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5443 Reviewed-on: http://review.whamcloud.com/11993 Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/linux/linux-time.h | 4 ++-- drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) commit 2dc09ea8d91a97dd01c675f2903ce5b4d1fd48d3 Author: Liang Zhen <liang.zhen@intel.com> Date: Sun Mar 27 20:26:26 2016 -0400 staging: lustre: libcfs: add lock-class for cfs_percpt_lock initialise lock-class for each sublock of cfs_percpt_lock to eliminate false alarm ""possible recursive locking detected" Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6432 Reviewed-on: http://review.whamcloud.com/14368 Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/libcfs/libcfs_cpu.h | 19 +++++++++++++++++-- drivers/staging/lustre/lnet/libcfs/libcfs_lock.c | 13 ++++++++++--- 2 files changed, 27 insertions(+), 5 deletions(-) commit 762d266d7d27bc00f9249a21feadc03154ab07c7 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:25 2016 -0400 staging: lustre: libcfs: move all cpt handling to libcfs_cpu.h Move the CPT handling declartions out of libcfs_private.h to libcfs_cpu.h where it belongs. Signed-off-by: frank zago <fzago@cray.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/15913 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_cpu.h | 64 +++++++++++++++++++++ .../lustre/include/linux/libcfs/libcfs_private.h | 67 ---------------------- 2 files changed, 64 insertions(+), 67 deletions(-) commit a18332b4564318c27cbc11596b2fe8b832e4c6c0 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:24 2016 -0400 staging: lustre: libcfs: remove cfs_percpt_[current|index] The functions cfs_percpt_current() and cfs_percpt_index() are not used anywhere. Remove it. Signed-off-by: frank zago <fzago@cray.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/15913 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_private.h | 2 -- drivers/staging/lustre/lnet/libcfs/libcfs_mem.c | 28 ---------------------- 2 files changed, 30 deletions(-) commit ccfb80c1861f9480572462b35f75451fc7c3517a Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:23 2016 -0400 staging: lustre: libcfs: remove atomic cpt allocations libcfs contains functions to perform atomic memory operations. These functions have never been used so remove them. Signed-off-by: frank zago <fzago@cray.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/15913 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_private.h | 6 ---- drivers/staging/lustre/lnet/libcfs/libcfs_lock.c | 41 ---------------------- 2 files changed, 47 deletions(-) commit 9af4826aeb4e12ba84a824d516432e223868f3b1 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:22 2016 -0400 staging: lustre: libcfs: remove cfs_signal_pending wrapper Use signal_pending() directly instead of a one line function wrapper. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13874 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 1 - drivers/staging/lustre/lnet/libcfs/linux/linux-prim.c | 7 ------- drivers/staging/lustre/lustre/include/lustre_lib.h | 2 +- drivers/staging/lustre/lustre/obdclass/cl_lock.c | 2 +- drivers/staging/lustre/lustre/ptlrpc/client.c | 6 +++--- 5 files changed, 5 insertions(+), 13 deletions(-) commit 3404f60d8b54647eff52b6aa03d60ef1ffa3deb2 Author: James Simmons <jsimmons@infradead.org> Date: Sun Mar 27 20:26:21 2016 -0400 staging: lustre: libcfs: remove function declarations in libcfs.h A few function declarations are in libcfs.h that are not needed. Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/13874 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 7 ------- 1 file changed, 7 deletions(-) commit 78ab125e63115a7f42d598a2113cd75092a40335 Author: Oleg Drokin <green@linuxhacker.ru> Date: Sun Mar 27 12:05:03 2016 -0400 staging/lustre/libcfs: Copy correct amount in libcfs_ioctl_getdata Commit b8ff756bc351 ("staging: lustre: libcfs: merge code from libcfs_ioctl into libcfs_ioctl_getdata") introduced a problem copying just a single pointer worth of data from userspace instead of whole libcfs_ioctl_hdr structure. Adjust the copying amount. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Acked-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1bc55f796a9872208e19b57fd00f4c484be35318 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:56 2016 -0400 staging: lustre: libcfs: calculate crypto performance using pages Use alloc_page() and use cfs_crypto_hash_update_page() to compute the hash instead of cfs_crypto_hash_digest(), since tgt_checksum_bulk() computes the hash by page anyway. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5279 Reviewed-on: http://review.whamcloud.com/10982 Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Alexander Boyko <alexander_boyko@xyratex.com> Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/lnet/libcfs/linux/linux-crypto.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) commit 78675cb1abec09f1c93f53457b4f7859273d8d0a Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:55 2016 -0400 staging: lustre: libcfs: improve reporting error for crypto performance Set cfs_crypto_hash_speeds[X] result to the actual error instead of -1. Make the error message more clear and informative. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8260d4e2c72b6fc02ab0bae45f3ed0f259092368 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:54 2016 -0400 staging: lustre: libcfs: print crypto performance result only on success Only print info about the crypto performance when no error is encounter. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 6ba3f37825982cf71e55ef87aadbffe8f4345a05 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:53 2016 -0400 staging: lustre: libcfs: allocate memory in cfs_crypto_performance_test() Move memory allocation from cfs_crypto_test_hashes() into the function cfs_crypto_performance_test(). Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lnet/libcfs/linux/linux-crypto.c | 40 ++++++++++------------ 1 file changed, 19 insertions(+), 21 deletions(-) commit e43c658c5a97570f4c5be8e94eb2ad30d4033123 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:52 2016 -0400 staging: lustre: libcfs: return proper error code for cfs_crypto_hash_speed() Return a real error code, -ENOENT, instead of a -1. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c11e27a4ee39479b9afef86bfed8ef3f75756262 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:51 2016 -0400 staging: lustre: libcfs: bug fixes for cfs_crypto_hash_final() Change cfs_crypto_hash_final() to always clean up the hash descrptor instead of not doing this in error cases. All of the callers were just calling cfs_crypto_hash_final() immediately to clean up the descriptor anyway, and the old behaviour is unlike other init/fini functions, and prone to memory leaks and other incorrect usage. The callers can call cfs_crypto_digest_size() to determine the hash size in advance if needed, and avoid complexity in cfs_crypto_hash_final(). Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lnet/libcfs/linux/linux-crypto.c | 24 ++++++++++------------ drivers/staging/lustre/lustre/osc/osc_request.c | 5 +---- drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c | 12 +++++------ 3 files changed, 18 insertions(+), 23 deletions(-) commit 244cd87cc078fd18a8cbbb4db2998b95760007f6 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:50 2016 -0400 staging: lustre: libcfs: start using enum cfs_crypto_hash_alg Fix the cfs_crypto_hash_* functions to take enum cfs_crypto_hash_alg as the algorithm type, instead of an unsigned char. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_crypto.h | 23 +++++++++++----------- .../lustre/lnet/libcfs/linux/linux-crypto.c | 10 +++++----- 2 files changed, 17 insertions(+), 16 deletions(-) commit 56ebc2e875f1103b941163008ece8612c9e97ba4 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:49 2016 -0400 staging: lustre: libcfs: small alignment change for cfs_crypto_hash_*() Change the aligment of some of the functions. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_crypto.h | 11 ++++++----- drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 4 ++-- 2 files changed, 8 insertions(+), 7 deletions(-) commit 24a4e1ec63ffcd87f656f507709b5f03f6a5f155 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:48 2016 -0400 staging: lustre: libcfs: add new definitions for cfs_crypto api Add CFS_HASH_ALG_UNKOWN for unknown hash names instead of using "0xFF" directly. Define the max digestsize the cfs crypto api can handle. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_crypto.h | 9 +++++++-- drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 4 ++-- 2 files changed, 9 insertions(+), 4 deletions(-) commit 4d60ffa12c887e1944d5582d79cc9d7f3593eb00 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:47 2016 -0400 staging: lustre: libcfs: rename some variables for crypto handling For the crypto algorthim type use the same name hash_alg everywhere. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_crypto.h | 4 +-- .../lustre/lnet/libcfs/linux/linux-crypto.c | 30 +++++++++++----------- 2 files changed, 17 insertions(+), 17 deletions(-) commit 020b02154d79e1e01f846da7a6beab59fd7c7840 Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:46 2016 -0400 staging: lustre: libcfs: add documentation for cfs_crypto_hash_*() Add comment blocks for cfs_crypto_hash_*() in linux-crypto.c and libcfs_crypto.h. Delete obsolete comment about shash handling in cfs_crypto_hash_alloc(). Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_crypto.h | 101 ++++---------- .../lustre/lnet/libcfs/linux/linux-crypto.c | 153 +++++++++++++++++++-- 2 files changed, 174 insertions(+), 80 deletions(-) commit 997e518821ea0565bb92c5feba43c24c46be933d Author: Andreas Dilger <andreas.dilger@intel.com> Date: Sat Mar 26 15:40:45 2016 -0400 staging: lustre: libcfs: limit scope of libcfs_crypto.h Remove <libcfs/libcfs_crypto.h> from <libcfs/libcfs.h> and only include it into the places where it is actually needed. This works out to be the same places as <obd_cksum.h>, so put it there. Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5053 Reviewed-on: http://review.whamcloud.com/9990 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: James Simmons <uja.ornl@gmail.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 1 - drivers/staging/lustre/lnet/libcfs/linux/linux-crypto.c | 1 + drivers/staging/lustre/lustre/include/obd_cksum.h | 1 + 3 files changed, 2 insertions(+), 1 deletion(-) commit e42839b012eb8179ed2e3571bfcd133fba5df154 Author: Mengdong Lin <mengdong.lin@linux.intel.com> Date: Thu Mar 24 10:53:14 2016 +0800 ASoC: topology: ABI - Define types for vendor tuples Tuples, a pair of token and value, can be used to define vendor specific data, for controls and widgets. This can avoid importing binary data blob from other files. Vendor specific tuple arrays will be embeded in the private data buffer of a control or widget object. To be backward compatible, union is used to define the tuple arrays in the existing private data ABI object 'struct snd_soc_tplg_private'. Vendors need to make sure the token values defined by the topology conf file match those defined by their driver. Now supported tuple types are uuid, string, bool, byte, short and word. Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/uapi/sound/asoc.h | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) commit b993734718c0106418e068f21c7be01afc12306c Author: Rob Herring <robh@kernel.org> Date: Fri Mar 4 08:56:58 2016 -0600 scripts/dtc: Update to upstream version 53bf130b1cdd Sync to upstream dtc commit 53bf130b1cdd ("libfdt: simplify fdt_node_check_compatible()"). This adds the following commits from upstream: 53bf130 libfdt: simplify fdt_node_check_compatible() c9d9121 Warn on node name unit-address presence/absence mismatch 2e53f9d Catch unsigned 32bit overflow when parsing flattened device tree offsets Signed-off-by: Rob Herring <robh@kernel.org> scripts/dtc/checks.c | 26 ++++++++++++++++++++++++++ scripts/dtc/flattree.c | 4 ++-- scripts/dtc/libfdt/fdt_ro.c | 6 ++---- scripts/dtc/version_gen.h | 2 +- 4 files changed, 31 insertions(+), 7 deletions(-) commit 0400485076e8bb167d5f4b3eb5f6d05e4b4361b7 Author: Petr Kulhavy <petr@barix.com> Date: Tue Mar 29 09:39:36 2016 +0200 ASoC: tas571x: implemented digital mute The driver did not have a mute function. The amplifier was brought out of shutdown mode (hard-mute) once for ever in probe(), which was causing clicks and pops when altering the I2C register configuration later. This adds the digital_mute() function. The amplifier unmute in probe() was removed. Signed-off-by: Petr Kulhavy <petr@barix.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/tas571x.c | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) commit 9895c03d48115c7783c0ef0a591447d53254ef84 Author: Nicolas Pitre <nicolas.pitre@linaro.org> Date: Thu Jan 21 17:07:24 2016 -0500 kbuild: record needed exported symbols for modules Kernel modules are partially linked object files with some undefined symbols that are expected to be matched with EXPORT_SYMBOL() entries from elsewhere. Each .tmp_versions/*.mod file currently contains two line of text separated by a newline character. The first line has the actual module file name while the second line has a list of object files constituting that module. Those files are parsed by modpost (scripts/mod/sumversion.c), scripts/Makefile.modpost, scripts/Makefile.modsign, etc. Only the modpost utility cares about the second line while the others retrieve only the first line. Therefore we can add a third line to record the list of undefined symbols aka required EXPORT_SYMBOL() entries for each module into that file without breaking anything. Like for the second line, symbols are separated by a blank and the list is terminated with a newline character. To avoid needless build overhead, the undefined symbols extraction is performed only when CONFIG_TRIM_UNUSED_KSYMS is selected. Signed-off-by: Nicolas Pitre <nico@linaro.org> Acked-by: Rusty Russell <rusty@rustcorp.com.au> scripts/Makefile.build | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 3a3a5fece6f28c14d3d05c74fb7696412e53a067 Author: Deepa Dinamani <deepa.kernel@gmail.com> Date: Mon Feb 22 07:17:53 2016 -0800 fs: kernfs: Replace CURRENT_TIME by current_fs_time() This is in preparation for the series that transitions filesystem timestamps to use 64 bit time and hence make them y2038 safe. CURRENT_TIME macro will be deleted before merging the aforementioned series. Use current_fs_time() instead of CURRENT_TIME for inode timestamps. struct kernfs_node is associated with a sysfs file/ directory. Truncate the values to appropriate time granularity when writing to inode timestamps of the files. ktime_get_real_ts() is used to obtain times for struct kernfs_iattrs. Since these times are later assigned to inode times using timespec_truncate() for all filesystem based operations, we can save the supers list traversal time here by using ktime_get_real_ts() directly. Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/kernfs/dir.c | 8 +++++--- fs/kernfs/inode.c | 15 ++++++++++----- 2 files changed, 15 insertions(+), 8 deletions(-) commit 1b48b530dac3e600d92854d98a2a519243661f6c Author: Deepa Dinamani <deepa.kernel@gmail.com> Date: Mon Feb 22 07:17:47 2016 -0800 fs: debugfs: Replace CURRENT_TIME by current_fs_time() CURRENT_TIME macro is not appropriate for filesystems as it doesn't use the right granularity for filesystem timestamps. Use current_fs_time() instead. Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/inode.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit a8f324a46fbe5473633af00039e81821be0ce51b Author: Roman Pen <r.peniaev@gmail.com> Date: Tue Feb 9 11:30:29 2016 +0100 debugfs: fix inode i_nlink references for automount dentry Directory inodes should start off with i_nlink == 2 (one extra ref for "." entry). debugfs_create_automount() increases neither the i_nlink reference for current inode nor for parent inode. On attempt to remove the automount dentry, kernel complains: [ 86.288070] WARNING: CPU: 1 PID: 3616 at fs/inode.c:273 drop_nlink+0x3e/0x50() [ 86.288461] Modules linked in: debugfs_example2(O-) [ 86.288745] CPU: 1 PID: 3616 Comm: rmmod Tainted: G O 4.4.0-rc3-next-20151207+ #135 [ 86.289197] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.8.2-20150617_082717-anatol 04/01/2014 [ 86.289696] ffffffff81be05c9 ffff8800b9e6fda0 ffffffff81352e2c 0000000000000000 [ 86.290110] ffff8800b9e6fdd8 ffffffff81065142 ffff8801399175e8 ffff8800bb78b240 [ 86.290507] ffff8801399175e8 ffff8800b73d7898 ffff8800b73d7840 ffff8800b9e6fde8 [ 86.290933] Call Trace: [ 86.291080] [<ffffffff81352e2c>] dump_stack+0x4e/0x82 [ 86.291340] [<ffffffff81065142>] warn_slowpath_common+0x82/0xc0 [ 86.291640] [<ffffffff8106523a>] warn_slowpath_null+0x1a/0x20 [ 86.291932] [<ffffffff811ae62e>] drop_nlink+0x3e/0x50 [ 86.292208] [<ffffffff811ba35b>] simple_unlink+0x4b/0x60 [ 86.292481] [<ffffffff811ba3a7>] simple_rmdir+0x37/0x50 [ 86.292748] [<ffffffff812d9808>] __debugfs_remove.part.16+0xa8/0xd0 [ 86.293082] [<ffffffff812d9a0b>] debugfs_remove_recursive+0xdb/0x1c0 [ 86.293406] [<ffffffffa00004dd>] cleanup_module+0x2d/0x3b [debugfs_example2] [ 86.293762] [<ffffffff810d959b>] SyS_delete_module+0x16b/0x220 [ 86.294077] [<ffffffff818ef857>] entry_SYSCALL_64_fastpath+0x12/0x6a [ 86.294405] ---[ end trace c9fc53353fe14a36 ]--- [ 86.294639] ------------[ cut here ]------------ To reproduce the issue it is enough to invoke these lines: autom = debugfs_create_automount("automount", NULL, vfsmount_cb, data); BUG_ON(IS_ERR_OR_NULL(autom)); debugfs_remove(autom); The issue is fixed by increasing inode i_nlink references for current and parent inodes. Signed-off-by: Roman Pen <r.peniaev@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> fs/debugfs/inode.c | 4 ++++ 1 file changed, 4 insertions(+) commit b3c1be1b789cca6d3e39c950dfed690f0511fe76 Author: William Breathitt Gray <vilhelm.gray@gmail.com> Date: Fri Jan 22 11:28:07 2016 -0500 base: isa: Remove X86_32 dependency Many motherboards utilize a LPC to ISA bridge in order to decode ISA-style port-mapped I/O addresses. This is particularly true for embedded motherboards supporting the PC/104 bus (a bus specification derived from ISA). These motherboards are now commonly running 64-bit x86 processors. The X86_32 dependency should be removed from the ISA bus configuration option in order to support these newer motherboards. A new config option, CONFIG_ISA_BUS, is introduced to allow for the compilation of the ISA bus driver independent of the CONFIG_ISA option. Devices which communicate via ISA-compatible buses can now be supported independent of the dependencies of the CONFIG_ISA option. Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> arch/x86/Kconfig | 6 ++++++ drivers/base/Makefile | 2 +- include/linux/isa.h | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) commit ebdf4040c16df572d95ea63fc1f64c156baeb947 Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri Feb 19 21:17:36 2016 +0100 Documentation: update the devices.txt documentation Alan is no longer maintaining this list through the Linux assigned numbers authority. Make it a collective document by referring to "the maintainers" in plural throughout, and naming the chardev and block layer maintainers in particular as parties of involvement. Cut down and remove some sections that pertained to the process of maintaining the list at lanana.org and contacting Alan directly. Make it clear that this document, in the kernel, is the master document. Also move paragraphs around so as to emphasize dynamic major number allocation. Remove paragraph on 2.6 deprecation, that tag no longer appears anywhere in the file. Cc: Jonathan Corbet <corbet@lwn.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Alan Cox <alan@linux.intel.com> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Jens Axboe <axboe@kernel.dk> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> CREDITS | 1 + Documentation/devices.txt | 80 +++++++++++++++-------------------------------- 2 files changed, 26 insertions(+), 55 deletions(-) commit 49db08c358873af11ba3c25401de88156fa5d365 Author: Linus Walleij <linus.walleij@linaro.org> Date: Fri Feb 19 15:36:07 2016 +0100 chrdev: emit a warning when we go below dynamic major range Currently a dynamically allocated character device major is taken from 254 and downward. This mechanism is used for RTC, IIO and a few other subsystems. The kernel currently has no check prevening these dynamic allocations from eating into the assigned numbers at 233 and downward. In a recent test it was reported that so many dynamic device majors were used on a test server, that the major number for infiniband (231) was stolen. This occurred when allocating a new major number for GPIO chips. The error messages from the kernel were not helpful. (See: https://lkml.org/lkml/2016/2/14/124) This patch adds a defined lower limit of the dynamic major allocation region will henceforth emit a warning if we start to eat into the assigned numbers. It does not do any semantic changes and will not change the kernels behaviour: numbers will still continue to be stolen, but we will know from dmesg what is going on. This also updates the Documentation/devices.txt to clearly reflect that we are using this range of major numbers for dynamic allocation. Reported-by: Ying Huang <ying.huang@linux.intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Alan Cox <alan@linux.intel.com> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Documentation/devices.txt | 6 +++--- fs/char_dev.c | 4 ++++ include/linux/fs.h | 2 ++ 3 files changed, 9 insertions(+), 3 deletions(-) commit 00411b7b1e3ec477b75bb83ccd417c7609832db6 Author: Gabriel Somlo <somlo@cmu.edu> Date: Mon Feb 22 16:18:18 2016 -0500 firmware: fw_cfg register offsets on supported architectures only Refrain from defining default fw_cfg register offsets on unsupported architectures -- throw an error instead. If QEMU were to add fw_cfg support on additional architectures, we should add them to the FW_CFG_SYSFS depends statement in drivers/firmware/Kconfig, and provide default values for register offsets in drivers/firmware/qemu_fw_cfg.c at that time. Suggested-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Gabriel Somlo <somlo@cmu.edu> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/firmware/qemu_fw_cfg.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit c13202f7d7101a6f5542f3a31b9a6787ae7b746c Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon Mar 28 14:29:24 2016 +0100 ASoC: cs47l24: Add support for audio trace firmware cs47l24 supports the audio trace firmware, this streams of audio to be captured from the CODEC over a compressed audio channel for analysis/debugging of audio processing firmwares. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/cs47l24.c | 38 +++++++++++++++++++++++++++++++++++--- 1 file changed, 35 insertions(+), 3 deletions(-) commit 9abe3dc77ea7ccad1c2112257bb352435dcee0ff Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon Mar 28 14:29:23 2016 +0100 ASoC: cs47l24: Fix a couple of small whitespace errors Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/cs47l24.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 33d740e07d1f565e44d35e7f7756a619b4f1e4ba Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon Mar 28 14:29:21 2016 +0100 ASoC: wm_adsp: Show avail in bytes to match other messages All other debug messages talk about data on the compressed stream in bytes except avail which is shown in words. To avoid confusion show avail in bytes as well. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 612047f0baefe2aeef1bc5ad8c7107a532b7d957 Author: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Date: Mon Mar 28 14:29:22 2016 +0100 ASoC: wm_adsp: Fix some subtle races on compressed stream Firstly, we should be locking the pwr_lock when we initialise the compressed buffer. Secondly, fixup a couple of places when we should be pulling pointers only under the pwr_lock as they may be affected by operations that take that lock. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm_adsp.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) commit 937e92dc50231bb41294262abf56d2bdddc4d38c Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Sun Mar 27 18:36:13 2016 -0300 ASoC: wm8962: Adjust clk definitions so that simple card can work When trying to use simple card with wm8962 the following probe error happens: wm8962 0-001a: simple-card: set_sysclk error asoc-simple-card sound: ASoC: failed to init 202c000.ssi-wm8962: -22 asoc-simple-card sound: ASoC: failed to instantiate card -22 asoc-simple-card: probe of sound failed with error -22 In simple-card.c the snd_soc_dai_set_sysclk() function is called with clk_id as 0, which is an invalid clock for wm8962. Adjust the clocks source definitions in wm8962.h so that the simple card driver can work successfully. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm8962.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 8bfa934e10d99b524bfe80b793e235b9188a7b58 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Mar 28 08:31:19 2016 -0300 ASoC: wm8962: Fit error message into a single line The error message fits well into a single line. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm8962.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 65147846796bd443972d9055b3b4c1339e15d53a Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Mon Mar 28 08:31:18 2016 -0300 ASoC: wm8962: Disable clock if wm8962_runtime_resume() fails When regulator_bulk_enable() fails inside wm8962_runtime_resume(), we should disable the previously enabled clock. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/wm8962.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 6e4f28780f38e27cb7ca0edeb1d7ebb4edfd1fc5 Author: Alexander Stein <alexander.stein@systec-electronic.com> Date: Tue Mar 29 08:53:32 2016 +0200 regcache: flat: Require max_registers to be set If max_register is unset, regcache_flat_get_index will return 0 and only memory for 1 unsigned int will be allocated, resulting in writing out of bounds. Signed-off-by: Alexander Stein <alexander.stein@systec-electronic.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/base/regmap/regcache-flat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 97cc2ed27e5a168cf423f67c3bc7c6cc41d12f82 Author: Takashi Iwai <tiwai@suse.de> Date: Tue Mar 29 18:48:07 2016 +0200 ALSA: hda - Fix yet another i915 pointer leftover in error path The hdac_acomp object in hdac_i915.c is left as assigned even after binding with i915 actually fails, and this leads to the WARN_ON() at the next load of the module. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94736 Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/hda/hdac_i915.c | 1 + 1 file changed, 1 insertion(+) commit 9fe3219743dea7b6f14afec2f853c3f615b8849b Author: Adam Baker <linux@baker-net.org.uk> Date: Sat Mar 5 15:34:57 2016 +0000 ARM: dts: kirkwood: Add the hardware monitor to the NSA320 device tree Add an entry for the hardware monitoring MCU [gregory.clement@free-electrons.com: rename the title to use the "standard" format] Signed-off-by: Adam Baker <linux@baker-net.org.uk> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> arch/arm/boot/dts/kirkwood-nsa320.dts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) commit 52d7c42664e6348fbe5fc062590bb8f152b65d94 Author: Joachim Eastwood <manabian@gmail.com> Date: Tue Apr 28 00:41:09 2015 +0200 ARM: dts: lpc18xx: add creg-clk node Add node for the creg clock controller and change the input clock on cgu to use it. Signed-off-by: Joachim Eastwood <manabian@gmail.com> arch/arm/boot/dts/lpc18xx.dtsi | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) commit c07f98a73978964065b57079cae9ab9d060769fe Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Fri Mar 18 08:21:20 2016 +0100 ARM: at91/soc: reference the whole sama5d2 family Add EXID of all SoCs of the SAMA5D2 family. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/mach-at91/sama5.c | 20 +++++++++++++++++++- arch/arm/mach-at91/soc.h | 12 +++++++++++- 2 files changed, 30 insertions(+), 2 deletions(-) commit 2f26e6189d3bdfcbf2b3bd0d6ff88eb8e7022246 Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Fri Mar 18 08:21:19 2016 +0100 ARM: at91: use chipid device for soc detection So far, the CIDR and EXID registers were in the DBGU interface. This device has disappeared with the SAMA5D2 family. These registers are exposed through a new device called chipid. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> [nicolas.ferre@atmel.com: remove useless warnings] Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> [arnd@arndb.de: suggest to use static functions to reduce scope] Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> .../devicetree/bindings/arm/atmel-at91.txt | 4 ++ arch/arm/mach-at91/soc.c | 81 +++++++++++++++++----- 2 files changed, 67 insertions(+), 18 deletions(-) commit fd718627b31dfccc1875320a1e63bfc654ca4dc4 Author: Nicolas Ferre <nicolas.ferre@atmel.com> Date: Thu Mar 10 14:25:16 2016 +0100 ARM: dts: at91: sama5d2: add LCD controller Add LCD controller node that binds to the atmel_hlcdc DRM driver. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d2.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) commit d77c23874f3972d5580ca0b507d8c1d8ae9a1c5c Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Fri Mar 18 08:21:21 2016 +0100 ARM: dts: at91: sama5d2: add chipid node Add node for chipid device in order to have access to the CIDR and EXID values. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> arch/arm/boot/dts/sama5d2.dtsi | 5 +++++ 1 file changed, 5 insertions(+) commit c8f26c2696f42b97bf68b643e59a948cb35fc397 Author: Cyrille Pitchen <cyrille.pitchen@atmel.com> Date: Thu Mar 17 17:04:00 2016 +0100 ARM: dts: at91: sama5d2: add SFR node This SFR node is looked up by the I2S controller driver to tune the SFR_I2SCLKSEL register. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Documentation/devicetree/bindings/arm/atmel-at91.txt | 2 +- arch/arm/boot/dts/sama5d2.dtsi | 5 +++++ include/soc/at91/atmel-sfr.h | 18 ++++++++++++++++++ 3 files changed, 24 insertions(+), 1 deletion(-) commit 222b90943446e36d44395917b1be28732cbdab08 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Tue Mar 29 14:14:25 2016 +0200 drm/atmel: Fixup drm_connector_/unplug/unregister/_all Accidentally fell through the cracks in commit 6c87e5c3ec6db052f3744804a517b6fb003906e1 Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Wed Mar 23 11:42:54 2016 +0300 drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all() despite that Boris acked that patch. Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Cc: Alexey Brodkin <abrodkin@synopsys.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 583349896482ed1d6af3cd75b2a15bb334df2777 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Mar 24 17:50:23 2016 +0200 drm/i915: remove unused dev_priv->render_reclock_avail Set from VBT, but never used. Good riddance. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458834623-8734-5-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 3 --- drivers/gpu/drm/i915/intel_bios.c | 3 --- 2 files changed, 6 deletions(-) commit 9d6c875db4ada9f91e1643b5a72d74bea043d67e Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Mar 24 17:50:22 2016 +0200 drm/i915: move sdvo mappings to vbt data Move all data initialized from VBT under dev_priv->vbt. No functional changes. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458834623-8734-4-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 3 +-- drivers/gpu/drm/i915/intel_bios.c | 2 +- drivers/gpu/drm/i915/intel_sdvo.c | 16 ++++++++-------- 3 files changed, 10 insertions(+), 11 deletions(-) commit 06411f08b3f3a55f621d73356d0326f471978f18 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Mar 24 17:50:21 2016 +0200 drm/i915: move edp low vswing config to vbt data Move all data initialized from VBT under dev_priv->vbt. No functional changes. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458834623-8734-3-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 3 +-- drivers/gpu/drm/i915/intel_bios.c | 4 ++-- drivers/gpu/drm/i915/intel_ddi.c | 4 ++-- drivers/gpu/drm/i915/intel_dp.c | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) commit 6aa23e658d910342e8fedb23780638ddaed744d7 Author: Jani Nikula <jani.nikula@intel.com> Date: Thu Mar 24 17:50:20 2016 +0200 drm/i915: use a substruct in vbt data for edp Housekeeping, similar to psr, backlight, and dsi. No functional changes. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458834623-8734-2-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 19 ++++++++++--------- drivers/gpu/drm/i915/intel_bios.c | 38 +++++++++++++++++++------------------- drivers/gpu/drm/i915/intel_ddi.c | 8 ++++---- drivers/gpu/drm/i915/intel_dp.c | 16 ++++++++-------- drivers/gpu/drm/i915/intel_lvds.c | 2 +- 5 files changed, 42 insertions(+), 41 deletions(-) commit 8fef24ca90fb79de8454e26e9f3eae6cc610de1a Author: Liping Zhang <liping.zhang@spreadtrum.com> Date: Mon Mar 28 22:27:27 2016 +0800 netfilter: ip6t_SYNPROXY: remove magic number for hop_limit Replace '64' with the per-net ipv6_devconf_all's hop_limit when building the ipv6 header. Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/ipv6/netfilter/ip6t_SYNPROXY.c | 56 ++++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 26 deletions(-) commit 8d45ff22f1b43249f0cf1baafe0262ca10d1666e Author: Stephane Bryant <stephane.ml.bryant@gmail.com> Date: Sat Mar 26 08:42:12 2016 +0100 netfilter: bridge: nf queue verdict to use NFQA_VLAN and NFQA_L2HDR This makes nf queues use NFQA_VLAN and NFQA_L2HDR in verdict to modify the original skb Signed-off-by: Stephane Bryant <stephane.ml.bryant@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nfnetlink_queue.c | 47 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) commit 15824ab29f364abd3299ecd17ea48473d971aa79 Author: Stephane Bryant <stephane.ml.bryant@gmail.com> Date: Sat Mar 26 08:42:11 2016 +0100 netfilter: bridge: pass L2 header and VLAN as netlink attributes in queues to userspace - This creates 2 netlink attribute NFQA_VLAN and NFQA_L2HDR. - These are filled up for the PF_BRIDGE family on the way to userspace. - NFQA_VLAN is a nested attribute, with the NFQA_VLAN_PROTO and the NFQA_VLAN_TCI carrying the corresponding vlan_proto and vlan_tci fields from the skb using big endian ordering (and using the CFI bit as the VLAN_TAG_PRESENT flag in vlan_tci as in the skb) Signed-off-by: Stephane Bryant <stephane.ml.bryant@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> include/uapi/linux/netfilter/nfnetlink_queue.h | 10 +++++ net/netfilter/nfnetlink_queue.c | 58 ++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) commit ac28634456867b23b95faccba7997a62ec430603 Author: Stephane Bryant <stephane.ml.bryant@gmail.com> Date: Sat Mar 26 08:42:10 2016 +0100 netfilter: bridge: add nf_afinfo to enable queuing to userspace This just adds and registers a nf_afinfo for the ethernet bridge, which enables queuing to userspace for the AF_BRIDGE family. No checksum computation is done. Signed-off-by: Stephane Bryant <stephane.ml.bryant@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/bridge/netfilter/nf_tables_bridge.c | 47 +++++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 2 deletions(-) commit b3edfda4382ffaef5e5c1cffb25a33b3b9ef4546 Author: Borislav Petkov <bp@suse.de> Date: Wed Mar 16 13:19:29 2016 +0100 x86/cpu: Do the feature test first in enable_sep_cpu() ... before assigning local vars. Kill out label too and simplify. No functionality change. Signed-off-by: Borislav Petkov <bp@suse.de> Acked-by: Andy Lutomirski <luto@kernel.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/1458130769-24963-1-git-send-email-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/common.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit faafd03d23c913633d2ef7e6ffebdce01b164409 Author: Takashi Iwai <tiwai@suse.de> Date: Tue Mar 29 12:29:24 2016 +0200 ALSA: hda - Clear the leftover component assignment at snd_hdac_i915_exit() The commit [d745f5e7b8b2: ALSA: hda - Add the pin / port mapping on Intel ILK and VLV] introduced a WARN_ON() to check the pointer for avoiding the double initializations. But hdac_acomp pointer wasn't cleared at snd_hdac_i915_exit(), thus after reloading the HD-audio driver, it may result in the false positive warning. This patch makes sure to clear the leftover pointer at exit. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94736 Reported-by: Daniela Doras-prodan <daniela.doras-prodan@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/hda/hdac_i915.c | 1 + 1 file changed, 1 insertion(+) commit b6350c21cfe8aa9d65e189509a23c0ea4b8362c2 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:42:03 2016 -0600 x86/pat: Document the PAT initialization sequence Update PAT documentation to describe how PAT is initialized under various configurations. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Toshi Kani <toshi.kani@hp.com> Cc: elliott@hpe.com Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-8-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> Documentation/x86/pat.txt | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) commit 88ba281108ed0c25c9d292b48bd3f272fcb90dd0 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:42:02 2016 -0600 x86/xen, pat: Remove PAT table init code from Xen Xen supports PAT without MTRRs for its guests. In order to enable WC attribute, it was necessary for xen_start_kernel() to call pat_init_cache_modes() to update PAT table before starting guest kernel. Now that the kernel initializes PAT table to the BIOS handoff state when MTRR is disabled, this Xen-specific PAT init code is no longer necessary. Delete it from xen_start_kernel(). Also change __init_cache_modes() to a static function since PAT table should not be tweaked by other modules. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Juergen Gross <jgross@suse.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Toshi Kani <toshi.kani@hp.com> Cc: elliott@hpe.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-7-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/pat.h | 1 - arch/x86/mm/pat.c | 2 +- arch/x86/xen/enlighten.c | 9 --------- 3 files changed, 1 insertion(+), 11 deletions(-) commit ad025a73f0e9344ac73ffe1b74c184033e08e7d5 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:42:01 2016 -0600 x86/mtrr: Fix PAT init handling when MTRR is disabled get_mtrr_state() calls pat_init() on BSP even if MTRR is disabled. This results in calling pat_init() on BSP only since APs do not call pat_init() when MTRR is disabled. This inconsistency between BSP and APs leads to undefined behavior. Make BSP's calling condition to pat_init() consistent with AP's, mtrr_ap_init() and mtrr_aps_init(). Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Toshi Kani <toshi.kani@hp.com> Cc: elliott@hpe.com Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-6-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/kernel/cpu/mtrr/generic.c | 24 ++++++++++++++---------- arch/x86/kernel/cpu/mtrr/main.c | 3 +++ arch/x86/kernel/cpu/mtrr/mtrr.h | 1 + 3 files changed, 18 insertions(+), 10 deletions(-) commit edfe63ec97ed8d4496225f7ba54c9ce4207c5431 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:42:00 2016 -0600 x86/mtrr: Fix Xorg crashes in Qemu sessions A Xorg failure on qemu32 was reported as a regression [1] caused by commit 9cd25aac1f44 ("x86/mm/pat: Emulate PAT when it is disabled"). This patch fixes the Xorg crash. Negative effects of this regression were the following two failures [2] in Xorg on QEMU with QEMU CPU model "qemu32" (-cpu qemu32), which were triggered by the fact that its virtual CPU does not support MTRRs. #1. copy_process() failed in the check in reserve_pfn_range() copy_process copy_mm dup_mm dup_mmap copy_page_range track_pfn_copy reserve_pfn_range A WC map request was tracked as WC in memtype, which set a PTE as UC (pgprot) per __cachemode2pte_tbl[]. This led to this error in reserve_pfn_range() called from track_pfn_copy(), which obtained a pgprot from a PTE. It converts pgprot to page_cache_mode, which does not necessarily result in the original page_cache_mode since __cachemode2pte_tbl[] redirects multiple types to UC. #2. error path in copy_process() then hit WARN_ON_ONCE in untrack_pfn(). x86/PAT: Xorg:509 map pfn expected mapping type uncached- minus for [mem 0xfd000000-0xfdffffff], got write-combining Call Trace: dump_stack warn_slowpath_common ? untrack_pfn ? untrack_pfn warn_slowpath_null untrack_pfn ? __kunmap_atomic unmap_single_vma ? pagevec_move_tail_fn unmap_vmas exit_mmap mmput copy_process.part.47 _do_fork SyS_clone do_syscall_32_irqs_on entry_INT80_32 These negative effects are caused by two separate bugs, but they can be addressed in separate patches. Fixing the pat_init() issue described below addresses the root cause, and avoids Xorg to hit these cases. When the CPU does not support MTRRs, MTRR does not call pat_init(), which leaves PAT enabled without initializing PAT. This pat_init() issue is a long-standing issue, but manifested as issue #1 (and then hit issue #2) with the above-mentioned commit because the memtype now tracks cache attribute with 'page_cache_mode'. This pat_init() issue existed before the commit, but we used pgprot in memtype. Hence, we did not have issue #1 before. But WC request resulted in WT in effect because WC pgrot is actually WT when PAT is not initialized. This is not how it was designed to work. When PAT is set to disable properly, WC is converted to UC. The use of WT can result in a system crash if the target range does not support WT. Fortunately, nobody ran into such issue before. To fix this pat_init() issue, PAT code has been enhanced to provide pat_disable() interface. Call this interface when MTRRs are disabled. By setting PAT to disable properly, PAT bypasses the memtype check, and avoids issue #1. [1]: https://lkml.org/lkml/2016/3/3/828 [2]: https://lkml.org/lkml/2016/3/4/775 Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Toshi Kani <toshi.kani@hp.com> Cc: elliott@hpe.com Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-5-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/mtrr.h | 6 +++++- arch/x86/kernel/cpu/mtrr/main.c | 10 +++++++++- 2 files changed, 14 insertions(+), 2 deletions(-) commit d63dcf49cf5ae5605f4d14229e3888e104f294b1 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:41:59 2016 -0600 x86/mm/pat: Replace cpu_has_pat with boot_cpu_has() Borislav Petkov suggested: > Please use on init paths boot_cpu_has(X86_FEATURE_PAT) and on fast > paths static_cpu_has(X86_FEATURE_PAT). No more of that cpu_has_XXX > ugliness. Replace the use of cpu_has_pat on init paths with boot_cpu_has(). Suggested-by: Borislav Petkov <bp@suse.de> Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robert Elliott <elliott@hpe.com> Cc: Toshi Kani <toshi.kani@hp.com> Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-4-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/mm/pat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 224bb1e5d67ba0f2872c98002d6a6f991ac6fd4a Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:41:58 2016 -0600 x86/mm/pat: Add pat_disable() interface In preparation for fixing a regression caused by: 9cd25aac1f44 ("x86/mm/pat: Emulate PAT when it is disabled") ... PAT needs to provide an interface that prevents the OS from initializing the PAT MSR. PAT MSR initialization must be done on all CPUs using the specific sequence of operations defined in the Intel SDM. This requires MTRRs to be enabled since pat_init() is called as part of MTRR init from mtrr_rendezvous_handler(). Make pat_disable() as the interface that prevents the OS from initializing the PAT MSR. MTRR will call this interface when it cannot provide the SDM-defined sequence to initialize PAT. This also assures that pat_disable() called from pat_bsp_init() will set the PAT table properly when CPU does not support PAT. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robert Elliott <elliott@hpe.com> Cc: Toshi Kani <toshi.kani@hp.com> Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-3-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/pat.h | 1 + arch/x86/mm/pat.c | 13 ++++++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) commit 02f037d641dc6672be5cfe7875a48ab99b95b154 Author: Toshi Kani <toshi.kani@hpe.com> Date: Wed Mar 23 15:41:57 2016 -0600 x86/mm/pat: Add support of non-default PAT MSR setting In preparation for fixing a regression caused by: 9cd25aac1f44 ("x86/mm/pat: Emulate PAT when it is disabled")' ... PAT needs to support a case that PAT MSR is initialized with a non-default value. When pat_init() is called and PAT is disabled, it initializes the PAT table with the BIOS default value. Xen, however, sets PAT MSR with a non-default value to enable WC. This causes inconsistency between the PAT table and PAT MSR when PAT is set to disable on Xen. Change pat_init() to handle the PAT disable cases properly. Add init_cache_modes() to handle two cases when PAT is set to disable. 1. CPU supports PAT: Set PAT table to be consistent with PAT MSR. 2. CPU does not support PAT: Set PAT table to be consistent with PWT and PCD bits in a PTE. Note, __init_cache_modes(), renamed from pat_init_cache_modes(), will be changed to a static function in a later patch. Signed-off-by: Toshi Kani <toshi.kani@hpe.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Borislav Petkov <bp@suse.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Luis R. Rodriguez <mcgrof@suse.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Toshi Kani <toshi.kani@hp.com> Cc: elliott@hpe.com Cc: konrad.wilk@oracle.com Cc: paul.gortmaker@windriver.com Cc: xen-devel@lists.xenproject.org Link: http://lkml.kernel.org/r/1458769323-24491-2-git-send-email-toshi.kani@hpe.com Signed-off-by: Ingo Molnar <mingo@kernel.org> arch/x86/include/asm/pat.h | 2 +- arch/x86/mm/pat.c | 73 +++++++++++++++++++++++++++++++++------------- arch/x86/xen/enlighten.c | 2 +- 3 files changed, 55 insertions(+), 22 deletions(-) commit ff6fd1478c531a40279cf013227279f31ff90b41 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:45 2016 -0500 ARM: socfpga: Enable Arria10 L2 cache ECC on startup Enable ECC for Arria10 L2 cache on machine startup. The ECC has to be enabled before data is stored in memory otherwise the ECC will fail on reads. Use DT_MACHINE to select Arria10 L2 cache function. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Acked-by: Dinh Nguyen <dinguyen@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-9-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> arch/arm/mach-socfpga/core.h | 1 + arch/arm/mach-socfpga/l2_cache.c | 49 ++++++++++++++++++++++++++++++++++++++++ arch/arm/mach-socfpga/socfpga.c | 10 +++++++- 3 files changed, 59 insertions(+), 1 deletion(-) commit 588cb03ea208b303e6dee7e916f329043fd0fc26 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:44 2016 -0500 EDAC, altera: Add Arria10 L2 Cache ECC handling Add a private data structure for Arria10 L2 cache ECC and the probe function for it. The Arria10 ECC device IRQs are in a shared register so the ECC Manager parent/child relationship requires a different probe function. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-8-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 231 +++++++++++++++++++++++++++++++++++++++++++++ drivers/edac/altera_edac.h | 42 +++++++++ 2 files changed, 273 insertions(+) commit 8b39ab7290d571b91867b15c02a59edf0a5b00bb Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:43 2016 -0500 Documentation, dt, socfpga: Add Altera Arria10 L2 cache binding Add the device tree bindings needed to support the Altera L2 cache on the Arria10 chip. Since all the peripherals share IRQs, the IRQ fields are now in the ecc_manager. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Acked-by: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-7-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> .../bindings/arm/altera/socfpga-eccmgr.txt | 40 ++++++++++++++++++++++ 1 file changed, 40 insertions(+) commit 811fce4f2a7aea0cd93815d0eaf42fbcc98bd930 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:42 2016 -0500 EDAC, altera: Add register offset for ECC Error Inject In preparation for the Arria10 peripheral ECCs, add a register offset from the ECC base to the private data structure to index to the error injection register. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-6-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 7 +++++-- drivers/edac/altera_edac.h | 3 +++ 2 files changed, 8 insertions(+), 2 deletions(-) commit 27439a1a632d9936159863fb11f5bc4d55eaab04 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:41 2016 -0500 EDAC, altera: Abstract ECC Enable Mask in check_deps() In preparation for the Arria10 peripheral ECCs, use the ECC Enable mask in place of hard coded masks in the check dependency functions. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-5-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 328ca7ae81dd842ff56b35f1e8422e6af1c80c14 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:40 2016 -0500 EDAC, altera: Remove platform device from check_deps() In preparation for the Arria10 peripheral ECCs, remove the platform device parameter from the check_deps() functions because it is not needed and makes the Arria10 check_deps() cleaner. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-4-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 10 +++++----- drivers/edac/altera_edac.h | 4 +++- 2 files changed, 8 insertions(+), 6 deletions(-) commit 6c87e5c3ec6db052f3744804a517b6fb003906e1 Author: Alexey Brodkin <Alexey.Brodkin@synopsys.com> Date: Wed Mar 23 11:42:54 2016 +0300 drm: Rename drm_connector_unplug_all() to drm_connector_unregister_all() Current name is a bit misleading because what that helper function really does it calls drm_connector_unregister() for all connectors. This all has nothing to do with hotplugging so let's name things properly. And while at it remove potentially dangerous locking around drm_connector_unregister() in rcar_du_remove() as mentioned in kerneldoc for drm_connector_unregister_all(). Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: David Airlie <airlied@linux.ie> Cc: Boris Brezillon <boris.brezillon@free-electrons.com> Cc: linux-renesas-soc@vger.kernel.org Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458722577-20283-2-git-send-email-abrodkin@synopsys.com drivers/gpu/drm/drm_crtc.c | 18 +++++++++--------- drivers/gpu/drm/rcar-du/rcar_du_drv.c | 5 +---- drivers/gpu/drm/udl/udl_drv.c | 2 +- include/drm/drm_crtc.h | 4 ++-- 4 files changed, 13 insertions(+), 16 deletions(-) commit 05b088b6f8f21ed6a451c9a5fc8ec23cec665f12 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:39 2016 -0500 EDAC, altera: Move device structs and defines to the header Move the device structs and defines to altera_edac.h in preparation for adding the Arria10 L2 cache ECC. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-3-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/altera_edac.c | 43 ------------------------------------------- drivers/edac/altera_edac.h | 44 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 43 deletions(-) commit 3a8f21f170dc7c85f9c0fc5cc49a2fd31bd00628 Author: Thor Thayer <tthayer@opensource.altera.com> Date: Mon Mar 21 11:01:38 2016 -0500 EDAC, altera: Make L2C depend on L2x0 cache controller Make L2 cache depend instead of forcibly select the L2 cache support. Signed-off-by: Thor Thayer <tthayer@opensource.altera.com> Cc: devicetree@vger.kernel.org Cc: dinguyen@opensource.altera.com Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1458576106-24505-2-git-send-email-tthayer@opensource.altera.com Signed-off-by: Borislav Petkov <bp@suse.de> drivers/edac/Kconfig | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 0bfe5167b2d897a27b8a561d9b8b09026d8b16bd Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 15:48:47 2016 +0100 ARM: dts: ux500: use the GIC include header Use the <dt-bindings/interrupt-controller/arm-gic.h> header for generating the flags for the first cell of the interrupt definitions. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/ste-dbx5x0.dtsi | 91 ++++++++++++++++++++------------------- 1 file changed, 46 insertions(+), 45 deletions(-) commit 1b1e8e024b9ea4c07e05a44b9aeb48d5d89a06e0 Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 15:29:30 2016 +0100 ARM: dts: ux500: use the GPIO DT header Use the <dt-bindings/gpio/gpio.h> header instead of using hardcoded values for the GPIO flags. Eradicate the totally bogus "0x4" flag used and set that to GPIO_ACTIVE_HIGH as is proper, switch the inverted card detect on the Snowball to flag using GPIO_ACTIVE_LOW instead of using the MMC-specific inversion flag. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> arch/arm/boot/dts/ste-ccu9540.dts | 2 +- arch/arm/boot/dts/ste-dbx5x0.dtsi | 1 + arch/arm/boot/dts/ste-href-stuib.dtsi | 4 ++-- arch/arm/boot/dts/ste-href-tvk1281618.dtsi | 4 ++-- arch/arm/boot/dts/ste-hrefprev60.dtsi | 8 ++++---- arch/arm/boot/dts/ste-hrefv60plus.dtsi | 6 +++--- arch/arm/boot/dts/ste-snowball.dts | 19 +++++++++---------- 7 files changed, 22 insertions(+), 22 deletions(-) commit ba8c1a81d4b7c22ac2d767265851ad77c4d01002 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Thu Mar 24 13:50:41 2016 +0100 clk: renesas: r8a7795: make SD clk definition specific for GEN3 About SD clocks: The clock type is Gen3 specific, the callbacks are all Gen3 specific; I think the clock definition should also be Gen3 specific and not in the general header file. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 11 +++++++---- drivers/clk/renesas/renesas-cpg-mssr.h | 3 --- 2 files changed, 7 insertions(+), 7 deletions(-) commit 847e87920c667ad9a9f4b628b60451c1471ae003 Author: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Date: Wed Mar 9 17:56:02 2016 +0100 clk: renesas: r8a7795: add PWM clock Signed-off-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/clk/renesas/r8a7795-cpg-mssr.c | 1 + 1 file changed, 1 insertion(+) commit 92e6d9a2cc827018a18885e0f3050ab9ff8c3206 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Mar 23 16:06:01 2016 +0200 pinctrl: sh-pfc: r8a7795: Add drive strength support Define the drive strength registers for the R8A7795. As the PFC driver for the SoC only defines GPIO pins at the moment, limit drive strength support to those pins. Pins without GPIO capabilities will be supported later. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/pinctrl/sh-pfc/pfc-r8a7795.c | 218 +++++++++++++++++++++++++++++++++-- 1 file changed, 210 insertions(+), 8 deletions(-) commit 3caa7d8c3f03ad6f1b66f10f67dc68cb3af55fe1 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Wed Mar 23 16:06:00 2016 +0200 pinctrl: sh-pfc: Add drive strength support Add support for the drive-strengh pin configuration using the generic pinconf DT bindings. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> .../bindings/pinctrl/renesas,pfc-pinctrl.txt | 4 +- drivers/pinctrl/sh-pfc/core.c | 15 +++ drivers/pinctrl/sh-pfc/core.h | 3 + drivers/pinctrl/sh-pfc/pinctrl.c | 111 +++++++++++++++++++++ drivers/pinctrl/sh-pfc/sh_pfc.h | 17 ++++ 5 files changed, 148 insertions(+), 2 deletions(-) commit 93d2185dcabcf8ea08026234e58f5e31484ec6a6 Author: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Date: Wed Mar 16 00:48:11 2016 +0000 pinctrl: sh-pfc: IPSRx and MOD_SELx should be set before GPSRx Gen2 / Gen3 datasheet will have below note in next version. This patch follows this note. IPSRx and MOD_SELx registers shall be set before setting GPSRx registers in case that they need to be configured. MOD_SELx registers can be set either earlier or later than setting IPSRx registers. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/pinctrl/sh-pfc/sh_pfc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60d8fcef13e60484ecc5aa2c0a904b250750beba Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Sat Mar 12 10:15:03 2016 +0100 pinctrl: sh-pfc: r8a7790: Implement voltage switching for SDHI All the SHDIs can operate with either 3.3V or 1.8V signals, depending on negotiation with the card. Implement the {get,set}_io_voltage operations and set the related capability flag for the associated pins. Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> drivers/pinctrl/sh-pfc/pfc-r8a7790.c | 54 +++++++++++++++++++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) commit 11622d4c638ad3dd229e39064d0e5726c4f3b454 Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Date: Fri Feb 26 11:51:06 2016 +0200 drm: bridge: Make (pre/post) enable/disable callbacks optional Instead of forcing bridges to implement empty callbacks make them all optional. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456480266-7904-1-git-send-email-laurent.pinchart+renesas@ideasonboard.com Acked-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> drivers/gpu/drm/drm_bridge.c | 12 ++++++++---- include/drm/drm_crtc.h | 8 ++++++++ 2 files changed, 16 insertions(+), 4 deletions(-) commit f1be903dbed810f71f6f27c2cb721ccf561052aa Author: Marek Szyprowski <m.szyprowski@samsung.com> Date: Fri Mar 25 14:10:01 2016 +0100 ARM: dts: exynos: Enable the HDMI CEC device on Exynos4412 Odroid boards Add a dts node entry and enable the HDMI CEC device present in the Exynos4 family of SoCs. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> [k.kozlowski: Put the node in alphabetical order] Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit c795c88d986150745b541418113f17db58ba575f Author: Kamil Debski <kamil@wypas.org> Date: Fri Mar 25 14:10:00 2016 +0100 ARM: dts: exynos: Add node for the HDMI CEC device to exynos4 This patch adds HDMI CEC node specific to the Exynos4210/4x12 SoC series. Signed-off-by: Kamil Debski <kamil@wypas.org> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4.dtsi | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit a92de67c101581d49dfd43c3747f74f3792212e0 Author: Kamil Debski <kamil@wypas.org> Date: Fri Mar 25 14:09:59 2016 +0100 ARM: dts: exynos: Add HDMI CEC pin definition to exynos4 pinctrl Add pinctrl nodes for the HDMI CEC device to the Exynos4210 and Exynos4x12 SoCs. These are required by the HDMI CEC device. Signed-off-by: Kamil Debski <kamil@wypas.org> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> arch/arm/boot/dts/exynos4210-pinctrl.dtsi | 7 +++++++ arch/arm/boot/dts/exynos4x12-pinctrl.dtsi | 7 +++++++ 2 files changed, 14 insertions(+) commit fbfcf4bf1c11f16b0afbf77e366cba0c7a621003 Author: Alim Akhtar <alim.akhtar@samsung.com> Date: Fri Feb 26 14:36:30 2016 +0530 arm64: dts: exynos: Add TMU node for exynos7 This patch adds TMU node, related temprature sensor and triping point data for Atlas cpu core found on exynos7 SoC. Signed-off-by: Alim Akhtar <alim.akhtar@samsung.com> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> .../boot/dts/exynos/exynos7-tmu-sensor-conf.dtsi | 25 ++++++++++ .../arm64/boot/dts/exynos/exynos7-trip-points.dtsi | 54 ++++++++++++++++++++++ arch/arm64/boot/dts/exynos/exynos7.dtsi | 20 ++++++++ 3 files changed, 99 insertions(+) commit fb2d1b847fd6c02341f09a41d56d58c5c0ca1f92 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Wed Mar 23 15:02:39 2016 +0900 ARM: dts: exynos: Enable SSS on Odroid X/X2/U3 family Enable the Security SubSystem (SSS) on Exynos4412-based Odroid boards to provide hardware acceleration for AES operations. Suggested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> arch/arm/boot/dts/exynos4412-odroid-common.dtsi | 4 ++++ 1 file changed, 4 insertions(+) commit f3a132f0eaed611c3782181130422f4a704ac114 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 21 17:29:52 2016 +0900 ARM: dts: exynos: Enable SSS on Trats2 Enable the Security SubSystem (SSS) on Trats2 (Exynos4412) board to provide hardware acceleration for AES operations. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos4412-trats2.dts | 4 ++++ 1 file changed, 4 insertions(+) commit 6c5eb1db1e4a1fdbb5c6a9626875c589b84860b7 Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Mon Mar 21 17:29:39 2016 +0900 ARM: dts: exynos: Add Security SubSystem node to Exynos4 Add Security SubSystem (SSS) node to Exynos4 which provides hardware acceleration of AES operations. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> arch/arm/boot/dts/exynos4.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) commit c5c9c2df4d97e20cd4e05c848dc8ceff926d162f Author: Maarten ter Huurne <maarten@treewalker.org> Date: Thu Mar 17 15:05:08 2016 +0100 regulator: act8865: Configure register access for act8600 This can be used to expose the act8600 registers via debugfs. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/act8865-regulator.c | 74 ++++++++++++++++++++++++++++++++++- 1 file changed, 73 insertions(+), 1 deletion(-) commit 005e46857ed598bcf76035366cd2841e3b7f8c54 Author: Maarten ter Huurne <maarten@treewalker.org> Date: Thu Mar 17 15:05:07 2016 +0100 regulator: act8865: Pass of_node via act8865_regulator_data This makes the code easier to read and it avoids a dynamic memory allocation. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/act8865-regulator.c | 28 ++++++++++++---------------- include/linux/regulator/act8865.h | 2 ++ 2 files changed, 14 insertions(+), 16 deletions(-) commit 465011fc56717f0227d1aa7a99cce000abc614d8 Author: Fabio Estevam <fabio.estevam@nxp.com> Date: Sun Mar 27 19:06:14 2016 -0300 ASoC: wm8960: Provide a menu selection text Provide a menu selection text so that users can enable, disable or mark it as module in menuconfig. Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a52db659c79ceede44e2d5ca63ca058d49df8dea Author: Christophe Ricard <christophe.ricard@gmail.com> Date: Sun Mar 20 19:30:17 2016 +0100 spi: pxa2xx: Fix cs_change management Fix cs_change management so that it is in line with other spi drivers. In the spi core api helpers such as spi_bus_lock/unlock and spi_sync_locked or cs_change field in spi_transfer help to manage chip select from the device driver. The driver was setting the chip select to idle if the message queue was empty despite cs_change or other status field set by spi_bus_lock/unlock or spi_sync_locked. Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pxa2xx.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 6319a68011b86fa61dc63e94dc4fb716628037f3 Author: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Date: Fri Mar 18 11:35:21 2016 +0000 spi/fsl-espi: avoid infinite loops on fsl_espi_cpu_irq() It brought nearly infinite loops, and was possible to be occurred only if the SPI transaction total size are not alighed with 4. Loops are here at while (tmp--), tmp is unsigned, and set it with minus value. The loops are executed as a result of unexpected RX interrupt occurrence after that. This interrupt may be hardware eratta and is not fixed. Fix mspi->len from minus value to 0 and print warning message. Signed-off-by: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-fsl-espi.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) commit aa70e567c4f0eeb849c6bcef3685bdf1fc3ca19d Author: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Date: Fri Mar 18 11:35:21 2016 +0000 spi/fsl-espi: Don't wait transaction completion forever Because the eSPI driver uses wait_for_completion(), any stuck-able phenomenon at half-way transaction progress made worker task hang up. This phenomenon is perhaps caused by eSPI device errata which seems not to be published from vendor site yet. Anyway, we fix hang task by using fixed 2 seconds timeout that is our preferred value for eSPI maximum transaction size. It seems to be better that eSPI driver can detect this stuck and report error (EMSGSIZE) to the upper device driver because the upper device driver can decide to retry or recover. Signed-off-by: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-fsl-espi.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit a12ddd60ed0a88c3bb83a8d4c07762e41620bf8c Author: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Date: Fri Mar 18 11:35:21 2016 +0000 spi/fsl-espi: Don't spin forever on SPIE_RXCNT Infinite loop on SPIE_RXCNT occurred. while (SPIE_RXCNT(events) < min(4, mspi->len)) { cpu_relax(); events = mpc8xxx_spi_read_reg(®_base->event); } We met a soft lockup at fsl_espi_cpu_irq() because of this. Fix it by using spin_event_timeout() so that fsl_espi_cpu_irq() can break loop with timeouts dmesg. Signed-off-by: Nobuteru Hayashi <hayashi.nbb@ncos.nec.co.jp> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-fsl-espi.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 86cf635a316e89ba6ae79f452cedb5acddccf570 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Thu Mar 17 14:54:54 2016 -0300 regulator: Rename files for Maxim PMIC drivers Most Maxim PMIC regulator drivers are for sub-devices of Multi-Function Devices with drivers under drivers/mfd. But for many of these, the same object file name was used for both the MFD and the regulator drivers. Having 2 different drivers with the same name causes a lot of confusion to Kbuild, specially if these are built as module since only one module will be installed and also exported symbols will be undefined due being overwritten by the other module during modpost. For example, it fixes the following issue when both drivers are module: $ make M=drivers/regulator/ ... CC [M] drivers/regulator//max14577.o Building modules, stage 2. MODPOST 1 modules WARNING: "maxim_charger_calc_reg_current" [drivers/regulator//max14577.ko] undefined! WARNING: "maxim_charger_currents" [drivers/regulator//max14577.ko] undefined! Reported-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> MAINTAINERS | 4 +- drivers/regulator/Makefile | 6 +- drivers/regulator/max14577-regulator.c | 337 +++++++++ drivers/regulator/max14577.c | 337 --------- drivers/regulator/max77693-regulator.c | 318 ++++++++ drivers/regulator/max77693.c | 318 -------- drivers/regulator/max8997-regulator.c | 1241 ++++++++++++++++++++++++++++++++ drivers/regulator/max8997.c | 1241 -------------------------------- 8 files changed, 1901 insertions(+), 1901 deletions(-) commit 71335664c38f03de10d7cf1d82705fe55a130b33 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Jan 9 19:54:50 2016 -0500 cifs: don't bother with kmap on read_pages side just do ITER_BVEC recvmsg Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifsproto.h | 7 +++--- fs/cifs/connect.c | 65 ++++++++++++++++++++++++++++------------------------- fs/cifs/file.c | 53 ++++++++++++++----------------------------- 3 files changed, 55 insertions(+), 70 deletions(-) commit a6137305a8c47fa92ab1a8efcfe76f0e9fa96ab7 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Jan 9 19:37:16 2016 -0500 cifs_readv_receive: use cifs_read_from_socket() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifssmb.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit 09aab880f7c5ac31e9db18a63353b980bcb52261 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Nov 13 03:00:17 2015 -0500 cifs: no need to wank with copying and advancing iovec on recvmsg side either Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifsglob.h | 2 -- fs/cifs/connect.c | 72 ++++-------------------------------------------------- 2 files changed, 5 insertions(+), 69 deletions(-) commit 3ab3f2a1fee45f5788ddccd8b3ece6f74ae905bd Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Nov 13 02:36:04 2015 -0500 cifs: quit playing games with draining iovecs ... and use ITER_BVEC for the page part of request to send Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifsproto.h | 2 - fs/cifs/transport.c | 141 +++++++++++++++------------------------------------- 2 files changed, 41 insertions(+), 102 deletions(-) commit 16c568efff82e4a6a75d2bd86576e648fad8a7fe Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Nov 12 22:46:49 2015 -0500 cifs: merge the hash calculation helpers three practically identical copies... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/cifs/cifsencrypt.c | 97 ++++++++++++++++++++++++------------------- fs/cifs/cifsproto.h | 3 ++ fs/cifs/smb2transport.c | 107 +++++------------------------------------------- 3 files changed, 67 insertions(+), 140 deletions(-) commit 2da62906b1e298695e1bb725927041cd59942c98 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Sat Mar 14 21:13:46 2015 -0400 [net] drop 'size' argument of sock_recvmsg() all callers have it equal to msg_data_left(msg). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> drivers/target/iscsi/iscsi_target_util.c | 5 ++--- include/linux/net.h | 3 +-- net/socket.c | 23 ++++++++++------------- 3 files changed, 13 insertions(+), 18 deletions(-) commit 8861964f4c7caecbacc89bcb6b513b40cf097a02 Author: Andreas Gruenbacher <agruenba@redhat.com> Date: Thu Mar 24 14:38:36 2016 +0100 jfs: Remove unnecessary code in jfs_get_acl The get_acl inode operation is called only when no ACL is cached. It makes no sense to check for a cached ACL as the first thing inside such inode operations. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/jfs/acl.c | 4 ---- 1 file changed, 4 deletions(-) commit 7dffc87f2eea9f80889d2eb87bfbe63e51b9709c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 18 13:25:43 2016 -0400 reiserfs_cache_default_acl(): use get_acl() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/reiserfs/xattr_acl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 318723e4ff367f2c0b15eee534ed2854628d292a Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Fri Mar 25 11:44:34 2016 +0900 staging: dgnc: fix Logical continuations should be on the fix checkpatch.pl warning about 'Logical continuations should be on the previous line' in dgnc_neo.c file. I think the 'force' need to check first, because if the 'force' is true, it doesn't need to call another function call. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 6175e73deeba06365eae1758d964a4e37d8db627 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Fri Mar 25 11:44:06 2016 +0900 staging: dgnc: fix 'line over 80 characters' fix checkpatch.pl warning about 'line over 80 characters' in dgnc_neo.c Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_neo.c | 66 +++++++++++++++++++++++++++-------------- 1 file changed, 44 insertions(+), 22 deletions(-) commit 195d85c1a0b37c2dd231980528d46100f35f9a0c Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Thu Mar 24 15:11:08 2016 +0900 staging: dgnc: remove unused variable in dgnc_board TtyRefCnt was not used anywhere in dgnc. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.h | 2 -- 1 file changed, 2 deletions(-) commit a25ad52020b5cde0121830733890c06d3cc2e656 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Thu Mar 24 15:10:43 2016 +0900 staging: dgnc: fix CamelCase in dgnc_drvier.h and fix checkpatch.pl warning about CamelCase Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.h | 12 ++++++------ drivers/staging/dgnc/dgnc_tty.c | 32 ++++++++++++++++---------------- 2 files changed, 22 insertions(+), 22 deletions(-) commit aaeb5e7f03e97770fe7a0dc122854287ab020f19 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Wed Mar 23 23:02:59 2016 +0000 staging: xgifb: remove extra braces from if stmt (single branch) Remove braces from one branch of if statement where both branches only have a single line of code, as suggested in Documentation/CodingStyle Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/vb_setmode.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 26b694323637be61be89d391c1713d85d66b457d Author: Nicholas Sim <nicholassimws@gmail.com> Date: Wed Mar 23 23:02:24 2016 +0000 staging: xgifb: ensure braces on all arms of if stmt Added braces on else arm of if statement where if arm already has braces as suggested for clarity in Documentation/CodingStyle Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/xgifb/vb_setmode.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit e7c77e437b7cbb632a3708ea3a3bb270f4fc4677 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Wed Mar 23 22:35:39 2016 +0000 staging: rtl8188eu: remove return at end of void function call Remove unnecessary return statements from last lines of void function call (several) Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 17 ----------------- 1 file changed, 17 deletions(-) commit f72ea988418f3b86d4815f427105c4222622dd41 Author: Parth Sane <laerdevstudios@gmail.com> Date: Thu Mar 24 01:08:29 2016 +0530 staging: vt6656: Fixed multiple logical comparisions warnings in main_usb.c Using comparison to false and true is error prone. Fixed multiple warnings as per checkpatch guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vt6656/main_usb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit f96b36c779f92328bb1c802e6268609191d4449d Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Wed Mar 23 20:37:26 2016 +0200 Staging: wlan-ng: wiphy_free() is not called in case wiphy_register() fails This patch covers wiphy_register() failures in wlan_create_wiphy() from cfg80211.c by calling wiphy_free() for the correspondent struct wiphy allocated structure. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/cfg80211.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 80e3e241fa56312f7a837b7e4781ecffed0b8db6 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Wed Mar 23 20:54:36 2016 +0900 staging: dgnc: fix CamelCase in dgnc_driver.c fix checkpatch.pl warning about CamelCase. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.c | 52 +++++++++++++++++++------------------- drivers/staging/dgnc/dgnc_driver.h | 6 ++--- drivers/staging/dgnc/dgnc_mgmt.c | 28 ++++++++++---------- drivers/staging/dgnc/dgnc_sysfs.c | 2 +- 4 files changed, 44 insertions(+), 44 deletions(-) commit 87787e5ef727ff15f7c552cc48823b469f2eb41b Author: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Date: Wed Mar 23 12:06:34 2016 +0100 Staging: iio: Fix sparse endian warning Fix following sparse warning: warning: cast to restricted __be16 Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/adc/ad7606_spi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit 29efdd3d68fe91f5921e27bce79017e46a5fd57c Author: PrasannaKumar Muralidharan <prasannatsmkumar@gmail.com> Date: Wed Mar 23 12:58:28 2016 +0530 Staging: most: Remove __cplusplus check in header files Remove unnecessary __cplusplus check in header files as it is not required. Signed-off-by: PrasannaKumar Muralidharan <prasannatsmkumar@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/most/hdm-dim2/dim2_errors.h | 8 -------- drivers/staging/most/hdm-dim2/dim2_hal.h | 8 -------- drivers/staging/most/hdm-dim2/dim2_reg.h | 8 -------- 3 files changed, 24 deletions(-) commit ff59f2a6d44e4c96cd56e8b12c5678ef85a3b576 Author: Okash Khawaja <okash.khawaja@gmail.com> Date: Thu Mar 10 20:21:35 2016 +0000 staging: speakup: fix type mismatch warnings Compiling speakup driver with sparse produces following warning: drivers/staging/speakup/serialio.c:22:9: warning: incorrect type in initializer (different base types) drivers/staging/speakup/serialio.c:22:9: expected unsigned int [unsigned] flags drivers/staging/speakup/serialio.c:22:9: got restricted upf_t This patch fixes it. Signed-off-by: Okash Khawaja <okash.khawaja@gmail.com> Acked-by: Samuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/speakup/serialio.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit b42ca86ad605eb3e3f26618eed35ac6ff7435964 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:37:04 2016 -0700 staging: comedi: ni_tio: remove BUG() checks for ni_tio_get_clock_src() This function calls some helper functions to convert the counter variant specific clock select bits into the generic enum ni_gpct_clock_source_bits equivelent. These helper functions currently BUG() if the clock select bits are invalid. It then calls ni_tio_clock_period_ps() to figure out the clock period based on the generic clock source. This function could also BUG() if the prescale bits are invalid. In reality this should never happen but refactor the code to return -EINVAL instead and remove the BUG() checks. These functions are also called by ni_tio_set_sync_mode(). When this function is called by ni_tio_set_clock_src() the counter select bits have already been validated. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 60 +++++++++++++++++++-------------- 1 file changed, 35 insertions(+), 25 deletions(-) commit fa74d136fda8512a17918fc5f97a72acd05c22e3 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:37:03 2016 -0700 staging: comedi: ni_tio: remove BUG() in ni_tio_set_gate_src() This BUG() can never happen. The previous ni_tio_has_gate2_registers() check will have already caused the function to return -EINVAL. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 592ef9fb8d7e5deb359b02530c5bb0d0b717cfef Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:37:02 2016 -0700 staging: comedi: ni_tio: fix ni_tio_insn_config() The (*insn_config) functions are supposed to return an errno or the number of 'data' values used for the instruction (insn->n). Currently this function returns an errno or 0. Fix the function to work like the core expects. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) commit 475ea1ed14cce2608ed0f12474be2a3d75880eaf Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:37:01 2016 -0700 staging: comedi: ni_tio: remove BUG() checks for ni_tio_get_gate_src() This function calls some helper functions to convert the counter variant specific gate select bits into the generic enum ni_gpct_clock_source_bits equivelent. These helper functions currently BUG() if the gate select bits are invalid. This should never happen but refactor the code to return -EINVAL instead and remove the BUG() checks. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 146 +++++++++++++++++++++----------- 1 file changed, 97 insertions(+), 49 deletions(-) commit d87f5e90585a8b8646c3e9fe92d4c47716f5e19d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:37:00 2016 -0700 staging: comedi: ni_tio: validate clock source Refactor the functions that determine the clock source bits so that they return -EINVAL if the clock source is invalid. Pass the errno back to ni_tio_insn_config(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 34 ++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) commit a19b9b476ae3612e6c61c60e7fad7c8974158ef9 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:59 2016 -0700 staging: comedi: ni_tiocmd: remove BUG() which can never occur All the counter_dev->variant options are handled by the switch. Remove the BUG() which can never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tiocmd.c | 3 --- 1 file changed, 3 deletions(-) commit 53d63371293dfc8fdd49f14716c2f2b80aa11373 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:58 2016 -0700 staging: comedi: ni_tiocmd: remove unsed param from ni_tio_acknowledge_and_confirm() The 'stale_data' pointer is always NULL. Just remove it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tiocmd.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) commit b878a82ee15f77ff1106aa0e5be36a1ee3ec85ea Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:57 2016 -0700 staging: comedi: ni_tiocmd: fix block comments Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tiocmd.c | 60 +++++++++++++++--------------- 1 file changed, 31 insertions(+), 29 deletions(-) commit 9f62bee520b04346c3501a5da7534a96b873c01f Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:56 2016 -0700 staging: comedi: ni_tiocmd: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tiocmd.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) commit e3f7bb258b2f73c595ea8f2d26ad2cb137844b8a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:55 2016 -0700 staging: comedi: ni_tio: tidy up ni_tio_arm() Make this function a bit more consise by absorbing the GI_HW_ARM_SEL_MASK() inline helper and combine the two switch (start_trigger) code paths. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 78 ++++++++++++++------------------- 1 file changed, 34 insertions(+), 44 deletions(-) commit f51700a6428d7c8e94d48fd2fbb1062c604e8b2c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:54 2016 -0700 staging: comedi: ni_tio: tidy up ni_tio_set_sync_mode() The 'force_alt_sync' paramater is always 0. Remove it. Absorb the GI_ALT_SYNC() inline helper and use some local variables to clarify this function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 65 +++++++++++++++------------------ 1 file changed, 30 insertions(+), 35 deletions(-) commit a56b3f57c2f08a6f42c957c3731ca9f8158b6355 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:53 2016 -0700 staging: comedi: ni_tio: tidy up ni_tio_get_gate_src() Clarify the code a bit by handling the NI_GPCT_DISABLED_GATE_SELECT source in the common code path. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 32 +++++++++++++++----------------- 1 file changed, 15 insertions(+), 17 deletions(-) commit 8e621cf0cb9761b7ef74a63d228ce62418dc5b8c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:52 2016 -0700 staging: comedi: ni_tio: fix block comments Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 36 +++++++++++++++------------------ 1 file changed, 16 insertions(+), 20 deletions(-) commit 3676cdd9539a64d1b3e8cad8d8e5184bf860841a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:51 2016 -0700 staging: comedi: ni_tio: Prefer kernel type 'u64' over 'uint64_t' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 74ea93be6ce16f01e9e73a4ad5abeb984b0b02fc Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:50 2016 -0700 staging: comedi: ni_tio: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 166 ++++++++++++++++---------------- 1 file changed, 83 insertions(+), 83 deletions(-) commit 58011fdebb21a746ce43c8ada363a65c55200d74 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:49 2016 -0700 staging: comedi: ni_tio.h: remove unnecessary forward declarations These struct forward declarations are not needed. Remove them. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.h | 4 ---- 1 file changed, 4 deletions(-) commit 80168e9e583717b061cc144a06fc35dca2cc2e26 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:48 2016 -0700 staging: comedi: ni_tio.h: fix block comment Fix the checkpatch.pl issue: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.h | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) commit 10142ced7dc10261b7ff3598dedb3f6c4cb64e6d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:47 2016 -0700 staging: comedi: ni_tio.h: tidy up struct ni_gpct Fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' CHECK: Prefer kernel type 'u64' over 'uint64_t' CHECK: spinlock_t definition without comment Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a38a1408868c6f476f8f41881b7d7757e24f61c2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:46 2016 -0700 staging: comedi: ni_tio.h: tidy up struct ni_gpct_device Fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' CHECK: spinlock_t definition without comment Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 5994e51b20600accd55e9aaeeb0b78e5ca038e19 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:45 2016 -0700 staging: comedi: ni_tio: tidy up struct ni_gpct_device (*{write, read}_register) For aesthetics, rename these callbacks to simply read/write. Change the 'unsigned' parameters to 'unsigned int'. This fixes a number of checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 22 +++++++++++----------- drivers/staging/comedi/drivers/ni_tio.h | 19 +++++++++---------- 2 files changed, 20 insertions(+), 21 deletions(-) commit 51f2e4eb2882209c84c2546b5a9b5c638b850f95 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:44 2016 -0700 staging: comedi: ni_tio_internal: export {read, write)_register() Move these inline functions out of the header and export them instead. These functions have pretty generic names, rename them. Fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' CHECK: Avoid crashing the kernel - try using WARN_ON & recovery code rather than BUG() or BUG_ON() Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 72 ++++++++++++++++-------- drivers/staging/comedi/drivers/ni_tio_internal.h | 15 +---- drivers/staging/comedi/drivers/ni_tiocmd.c | 10 ++-- 3 files changed, 56 insertions(+), 41 deletions(-) commit 73b2d13607f075ff27abbf75d57320a8b9f82461 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:43 2016 -0700 staging: comedi: ni_tio_internal: simplify ni_tio_counting_mode_registers_present() Only the e series gpct variant does not have counting mode registers. Simplfy this function. For aesthetics, return bool instead of int. This fixes the checkpatch.pl issues: CHECK: spaces preferred around that '*' (ctx:ExV) CHECK: Avoid crashing the kernel - try using WARN_ON & recovery code rather than BUG() or BUG_ON() Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 2 +- drivers/staging/comedi/drivers/ni_tio_internal.h | 18 ++++-------------- 2 files changed, 5 insertions(+), 15 deletions(-) commit f4e0331f3050f051ad0e8818635fc157cf354713 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:42 2016 -0700 staging: comedi: ni_tio: export and fix ni_tio_set_bits() Move the inline function from the header and export it instead. Fix the checkpatch.pl issue: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' The 'unsigned' vars can safely be changed to 'unsigned int'. This allows moving ni_tio_set_bits_transient() into the driver and making it static. Fix the checkpatch.pl issue: CHECK: Avoid crashing the kernel - try using WARN_ON & recovery code rather than BUG() or BUG_ON() The BUG_ON() is overkill. All the drivers that call this function pass 'register_index' values that are valid. Just check the 'register_index' before updating the software copy and writing the register. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 37 ++++++++++++++++++++++++ drivers/staging/comedi/drivers/ni_tio_internal.h | 35 ++-------------------- 2 files changed, 39 insertions(+), 33 deletions(-) commit 85bfafa81f8e422503d31d48ae2658675aad1929 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:41 2016 -0700 staging: comedi: ni_tio: export and fix ni_tio_get_soft_copy() Move the inline function from the header and export it instead. For the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' CHECK: Avoid crashing the kernel - try using WARN_ON & recovery code rather than BUG() or BUG_ON() The 'unsigned' vars can safely be changed to 'unsigned int'. The BUG_ON() is overkill. All the drivers that call this function pass 'register_index' values that are valid. Just check the 'register_index' and return 0 if it's not valid. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 25 ++++++++++++++++++++++++ drivers/staging/comedi/drivers/ni_tio_internal.h | 21 ++------------------ 2 files changed, 27 insertions(+), 19 deletions(-) commit c9813d50a514b451c4ad3acf1f5a400fff005c70 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:40 2016 -0700 staging: comedi: ni_tio: fix ni_tio_arm() params/vars As suggested by checkpatch.pl: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' The 'arm' parameter is really a true/false flag. For aesthetics, change it to a bool. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 14 +++++++------- drivers/staging/comedi/drivers/ni_tio_internal.h | 2 +- drivers/staging/comedi/drivers/ni_tiocmd.c | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) commit a4915d543f5bbb775a5fa6d012d33606ba22389b Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:39 2016 -0700 staging: comedi: ni_tio: fix ni_tio_set_gate_src() params/vars As suggested by checkpatch.pl: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 28 ++++++++++++------------ drivers/staging/comedi/drivers/ni_tio_internal.h | 3 +-- 2 files changed, 15 insertions(+), 16 deletions(-) commit f79f218ec2aa2ac761e426f54419f8d27aa46d53 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:38 2016 -0700 staging: comedi: ni_tio_internal.h: fix block comment issues Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio_internal.h | 43 ++++++++++++------------ 1 file changed, 22 insertions(+), 21 deletions(-) commit 12fc6688ea34bd8b378e105da46ca016177f7c84 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 15:36:37 2016 -0700 staging: comedi: ni_tio_internal.h: tidy up bit defines Fix the checkpatch.pl issues: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio_internal.h | 199 ++++++++++++----------- 1 file changed, 102 insertions(+), 97 deletions(-) commit 2892b3fa16d8950b2385ad8fcd7ca84fa54aefaf Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:51:55 2016 -0700 staging: comedi: plx9052.h: fix block comment issues Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/plx9052.h | 35 ++++++++++++++++---------------- 1 file changed, 17 insertions(+), 18 deletions(-) commit 5c0d139243c32ebfe1f4aabd3d2a9817e23e07a5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:51:54 2016 -0700 staging: comedi: plx9052.h: tidy up bit defines Fix the checkpatch.pl issues: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/plx9052.h | 87 ++++++++++++++++---------------- 1 file changed, 44 insertions(+), 43 deletions(-) commit 1d734e3efabc6a4e6c68b2b21f626af1799124d6 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:29:27 2016 -0700 staging: comedi: z8536: tidy up bit defines Fix the checkpatch.pl issues: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/z8536.h | 89 ++++++++++++++++++---------------- 1 file changed, 48 insertions(+), 41 deletions(-) commit 99307a69bf7166325bb8f0b1f1afcb0a0a1aca9a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:42 2016 -0700 staging: comedi: ni_mio_common: ni_gpct_device_destroy() can handle a NULL pointer Remove the unnecessary NULL pointer check. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_mio_common.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit bed05b6c3434e62310c2e37ef234f02ce57cf74d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:40 2016 -0700 staging: comedi: ni_tio: make ni_gpct_device_destroy() NULL pointer safe Modify the pointer check to make this function NULL pointer safe. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_tio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2460e3cd9f5fad5630b3f9ce556bd37b7b5323f0 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:40 2016 -0700 staging: comedi: ni_labpc.h: fix block comment issues Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc.h | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-) commit 0edf7b85d31f5255814483dbedd70ed13456e7a5 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:39 2016 -0700 staging: comedi: ni_labpc_pci: tidy up bit define As suggested by checkpatch.pl: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc_pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a0b201caebfa863d89f0685127117c6c0dfe8c85 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:38 2016 -0700 staging: comedi: ni_labpc_cs: fix block comment issues Fix the checkpatch.pl issues: WARNING: Block comments use * on subsequent lines WARNING: line over 80 characters Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc_cs.c | 95 +++++++++++++--------------- 1 file changed, 44 insertions(+), 51 deletions(-) commit a444abfc668405746767eb53f920531b2d40e8af Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:37 2016 -0700 staging: comedi: ni_labpc_common: tidy up block comments Fix the checkpatch.pl issues: WARNING: Block comments use a trailing */ on a separate line Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc_common.c | 59 +++++++++++++++--------- 1 file changed, 37 insertions(+), 22 deletions(-) commit 447785c641cafe586bcb6678e63e436904536432 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:36 2016 -0700 staging: comedi: ni_labpc_regs.h: tidy up bit defines As suggested by checkpatch.pl: CHECK: Prefer using the BIT macro Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc_regs.h | 82 +++++++++++++------------- 1 file changed, 41 insertions(+), 41 deletions(-) commit c5f764057f2313673aaf046776e6d573bf2662b6 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:21:35 2016 -0700 staging: comedi: ni_labpc: remove some unnecessary defines The EEPROM_SIZE and NUM_AO_CHAN defines are only used once and they don't add any significant clarity to the driver. They are also pretty generic symbol names. Remove them and just open code the values. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_labpc.h | 3 --- drivers/staging/comedi/drivers/ni_labpc_common.c | 6 +++--- 2 files changed, 3 insertions(+), 6 deletions(-) commit f91e45e2acbd300c5042c9ce0133dbc602da9788 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 12:24:31 2016 -0700 staging: comedi: dt282x: remove unnecessary comment The "Configuration options" are documented in the comedi driver comment block. Remove the redundant comment before the drivers (*attach) function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/dt282x.c | 14 -------------- 1 file changed, 14 deletions(-) commit 20ea5c3506abfe46c98dfa47d1bf933e2efa15c9 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 12:24:30 2016 -0700 staging: comedi: dt282x: remove redundant comedi_check_trigger_arg_min() The 'convert_arg' sets the acquisition timing of the analog input command. The maximum speed (the minimum timing) depends on the board 'ai_speed' which if always >= 4000. Remove the redundant 'min' check, Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/dt282x.c | 4 ---- 1 file changed, 4 deletions(-) commit 581867bd9151ee77fad4b0fe47af96d923ac9ec2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Wed Mar 23 12:24:29 2016 -0700 staging: comedi: dt282x: refactor dt282x_ns_to_timer() Define the pacer clock limits and remove the magic numbers. Refactor the code to use a common path to return the actual 'ns' timing and the timer divisor value. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/dt282x.c | 36 ++++++++++++++++++++++----------- 1 file changed, 24 insertions(+), 12 deletions(-) commit 47470216cc2fe413156aa44d7ae55e65712b0931 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:53 2016 -0700 staging: comedi: ni_660x: update the MODULE_DESCRIPTION Change the generic MODULE_DESCRIPTION text to something more useful. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8f266d508c7aa7dad84fbb0d793aa95e8af95169 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:52 2016 -0700 staging: comedi: ni_660x: refactor GPCT_OFFSET This driver supports boards that have 1 or 2 TIO chips with base addresses 0x800 apart. Replace the static const array 'GPCT_OFFSET' with a define and calculate the base address based on the chip index. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 80c67b37fc27a3fc0542916798242e4af8148f28 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:51 2016 -0700 staging: comedi: ni_660x: remove spinlock 'dma_cfg_lock' This spinlock is only used to protect changes to the private data 'dma_cfg'. Before calling any function that would change the 'dma_cfg' the spinlock 'mite_channel_lock' is also locked. That spinlock is not unlocked until after the 'dma_cfg' change. Remove the redundant spinlock. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 9 --------- 1 file changed, 9 deletions(-) commit 4f2c3b2077a9bb34c7b5afe31633a1f5b1ca80b4 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:50 2016 -0700 staging: comedi: ni_660x: remove ni_gpct_to_660x_register[] enum ni_gpct_register and enum ni_660x_register now have a 1:1 relationship for the NITIO_* registers. The static const array is no longer necessary to find the proper NI660X_* register for a given NITIO_*. Remove it and refactor the register read/write functions. Use the NITIO_* values to init the ni_660x_reg_data[] array and remove the unnecessary NI660X_* enum values. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 307 ++++++++----------------------- 1 file changed, 74 insertions(+), 233 deletions(-) commit 242311d1a9e5cebde39855e064dcc4ac0dabde93 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:49 2016 -0700 staging: comedi: ni_660x: sort enum ni_660x_register Sort this enum so that it has a 1:1 relationship with the ni_tio.h enum ni_gpct_register. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 95 ++++++++++++++++---------------- 1 file changed, 48 insertions(+), 47 deletions(-) commit 515b5e6b8afdd32a3b528a331f23b852fe083c26 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:48 2016 -0700 staging: comedi: ni_660x: remove inline mite_ring() This fuction just returns a pointer from the private data. The name might provide some confusion since it appears to be an exported function from the mite driver. Just remove it and get the pointer directly where needed. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) commit 34b7f1f8194da6600eda6bb7c26659de19047a39 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:47 2016 -0700 staging: comedi: ni_660x: default DIO channels with subdevice init For aesthetics, move the initialization of the default routing for the DIO channels so it happens when the subdevice is initialized. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) commit 90ad57be6be10e7084ca677d6eddfba612b55a62 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:46 2016 -0700 staging: comedi: ni_660x: initialize the counter with the subdevice init Remove the extra for loop and just initialize the counter as the subdevices are created. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit f229594a327720c0761e7307a5472aea780268c3 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:45 2016 -0700 staging: comedi: ni_660x: allocate counters early in (*auto_attach) The ni_gpct_device_construct() could fail allocating the memory for device and its counters. For aesthetics, call the function before initializing the subdevices. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 2363cbf073225537016aceb6bf122bbee6a0caa0 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:44 2016 -0700 staging: comedi: ni_660x: init TIO chips before subdevice init For aesthetics, initialize the TIO chips before the subdevices are allocated and initialized. Refactor the function to initialize all the TIO chips and move it to a better place in the driver. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 52 ++++++++++++++++++-------------- 1 file changed, 29 insertions(+), 23 deletions(-) commit 78d514fa4cc0f195e060b7918d3548b63d27050f Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:43 2016 -0700 staging: comedi: ni_660x: disable interrupts when detaching driver Make sure the interrupts are disabled before freeing the irq. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 26a0fe3ffa24c63a99b1fb314e03723c1e470ba0 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:41 2016 -0700 staging: comedi: ni_660x: ni_gpct_device_destroy() can handle a NULL pointer Remove the unnecessary NULL pointer check. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 32f89d8e70106f2b636c716a7cfb7fe53cfc5ebf Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:39 2016 -0700 staging: comedi: ni_660x: tidy up the counter subdevices init For aesthetics, add some whitespace to the subdevice init and use a couple local variables to make the code easier to follow. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 59 +++++++++++++++++--------------- 1 file changed, 32 insertions(+), 27 deletions(-) commit ccef0da819dd7fa716b90e584a7793a8849b06f1 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:38 2016 -0700 staging: comedi: ni_660x: tidy up the misc. constants Remove enum ni_660x_constants and just #define the value. Move all the constant #defines so they are in one place and rename them so they are more conesistent. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 49 ++++++++++++++++---------------- 1 file changed, 24 insertions(+), 25 deletions(-) commit 5262d035ef260c3417254b2309892bba013dcab7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:37 2016 -0700 staging: comedi: ni_660x: fix memory barrier without comment Fix the checkpatch.pl issue. Move the memory barrier to a better place. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit e8f6e2b98d164d94bc29bb488413301d26cc5b3c Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:36 2016 -0700 staging: comedi: ni_660x: add comments for the spinlock_t definitions Fix the checkpatch.pl issues: CHECK: spinlock_t definition without comment For aesthetics, rename the 'soft_reg_copy_lock' to clarify what it's used for. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) commit 0c9434e352d0ae9ddb84a89716e1d1e82f3185f1 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:35 2016 -0700 staging: comedi: ni_660x: refactor ni_gpct_to_660x_register() Convert this big switch into an array and refactor ni_660x_gpct_{write,read}() functions to use the array to find the register offset. All the TIO (GPCT) registers are included in the array except for NITIO_G0_ABZ and NITIO_G1_ABZ. These registers only exist on the ni_pcimio m-series boards and this driver will never read/write them. Just in case someone adds a new entry to the enum ni_gpct_register in ni_tio.h, add a dev_warn() for any unhandled registers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 236 ++++++++++++------------------- 1 file changed, 89 insertions(+), 147 deletions(-) commit f0c9305ede52b42021ea53a33b3a2878e0c5d51e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:34 2016 -0700 staging: comedi: ni_660x: add a comment about the initial DIO state The (*auto_attach) initializes all the DIO channels to a default state. Add a comment for clarity. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 5 +++++ 1 file changed, 5 insertions(+) commit aa94f288882583fb2a214110ad021a75e78ff809 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:33 2016 -0700 staging: comedi: ni_660x: tidy up ni_660x_set_pfi_routing() Use the comedi.h provided constants (enum ni_660x_pfi_routing) instead of defining new ones for the output sources. Use a switch to clarify the channel/source validation. For aesthetics, rename the private data members 'pfi_output_selects' and 'pfi_direction_bits'. Remove the 'min_counter_pfi_chan' and 'max_dio_pfi_chan' from enum ni_660x_constants. The open coded values make the code easier to follow. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 65 +++++++++++++------------------- 1 file changed, 27 insertions(+), 38 deletions(-) commit 826f783a0eb15c6860d03af6d88eea3eaea34ff4 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:32 2016 -0700 staging: comedi: ni_660x: tidy up ni_660x_dio_insn_bits() Use some local variables to clarify this function. This (*insn_bits) function is a bit different from most comedi drivers. Add some comments to clarify why the shifts are used. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) commit 7e9061869435dbeefff970b032d2b8141ce9e301 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:31 2016 -0700 staging: comedi: ni_660x: tidy up Digital I/O subdevice init Add some whitespace to the Digital I/O subdevice init and add a comment about the channels. This driver is a bit goofy, only 32 of the 40 channels can actually be used for Digital I/Os and 32 of them can be routed to the counters for alternate use. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 68 ++++++++++++++++++++++++++++---- 1 file changed, 60 insertions(+), 8 deletions(-) commit cded944fa90cf8105eedb5766ecaee82a2f86b3a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:30 2016 -0700 staging: comedi: ni_660x: Prefer kernel type 'u64' over 'uint64_t' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 2225320ec8cc7f99c05ff217343eb63d5319c314 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:29 2016 -0700 staging: comedi: ni_660x: Prefer 'unsigned int' to bare use of 'unsigned' Fix the checkpatch.pl issues. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 40 ++++++++++++++++---------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit b15f5069087128d42d2e00b6b1c666fd3ec42bfe Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:28 2016 -0700 staging: comedi: ni_660x: remove ni_660x_num_counters() This inline function is only used by the (*auto_attach). Remove it and just use a local variable for the calculation. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) commit 520e61915186e0538a8fc46e5e268a2000141545 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:27 2016 -0700 staging: comedi: ni_660x: remove enum ni_660x_subdevices Hard-coding the subdevice order is normally a bad idea. If a new subdevice is added, or removed, it could potentially break pretty badly. Remove the enum and associated NI_660X_GPCT_SUBDEV() helper that hard-code the subdevice order. Fix the (*auto_attach) so it initializes all the subdevices without depending on the hard-coded order. Change the interrupt handler so that all the counter subdevices are handled without depending on the hard-coded order. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 25 ++++++++++--------------- 1 file changed, 10 insertions(+), 15 deletions(-) commit 6d40805b0b4e4392e68fea0028edcafa5fcdc04a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:26 2016 -0700 staging: comedi: ni_660x: fix block comment issues Fix the checkpatch.pl issues about: WARNING: Block comments use * on subsequent lines WARNING: Block comments use a trailing */ on a separate line Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) commit ff1e71be56d6c493084eac86afa0aeb59bca9c53 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:25 2016 -0700 staging: comedi: ni_660x: remove BUG_ON() in ni_660x_request_mite_channel() This BUG_ON() happens if a mite DMA channel is already requested when an ansynchronous command is started for one of the counter subdevices. The comedi core will only call the (*do_cmd) if the subdevice is not busy. In this driver, the (*cancel) for the subdevice will always release any requested mite DMA channel. Remove the BUG_ON() which can never occur. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 1 - 1 file changed, 1 deletion(-) commit 518d38423b48ad23b2f4b13dd9a027aa37423f1d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:24 2016 -0700 staging: comedi: ni_660x: tidy up ni_660x_select_pfi_output() Tidy up this function to fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' For aesthetics, remove the static const local variables. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 54 ++++++++++++++------------------ 1 file changed, 24 insertions(+), 30 deletions(-) commit dc285820cc19a666aea45ac74e9737c2afcf8189 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:23 2016 -0700 staging: comedi: ni_660x: tidy up ni_gpct_{write, read}_register() Rename these functions so they have namespace associated with the driver. Fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) commit ad98c18cb9de633d1023114842d1e895766b99b2 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:22 2016 -0700 staging: comedi: ni_660x: tidy up ni_660x_read_register() Rename this function to help shorten some of the long lines. Remove the inline, let the compiler figure it out. Change the 'unsigned' parameters to 'unsigned int' to fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) commit 9678b73e273abcd5ab13b7ecc44521f501529ca4 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:21 2016 -0700 staging: comedi: ni_660x: tidy up ni_660x_write_register() Rename this function to help shorten some of the long lines. Remove the inline, let the compiler figure it out. Change the 'unsigned' parameters to 'unsigned int' to fix the checkpatch.pl issues: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 42 +++++++++++++++----------------- 1 file changed, 20 insertions(+), 22 deletions(-) commit 41014593caebadec2f022d96d3326816599d439d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:20 2016 -0700 staging: comedi: ni_660x: cleanup the NI660X_GLOBAL_INT_{STATUS, CFG} Remove the enums global_interrupt_{status,config}_register_bits and add defines for the CamelCase values. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) commit fecf4cce0021aebd587f7bbd970806c24988ef26 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:19 2016 -0700 staging: comedi: ni_660x: cleanup the NI660X_DMA_CFG register helpers The BUG_ON() checks in the helper functions are not necessary. The mite driver quiries the PCI chip to determine the number of DMA channels. This is then used when a DMA channel is requested so the channel will always be in range. Convert the inline functions used to set the bits in the NI600X_DMA_CFG register into macros. Also convert the associated enum dma_selection. This clarifies the association with the register. Rename the associated 'dma_configuration_soft_copies' member of the private data to allow shorting some of the ugly long lines in the driver. This also fixes a number of checkpatch.pl issues about: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 63 ++++++++++---------------------- 1 file changed, 19 insertions(+), 44 deletions(-) commit 502552e161aee965026f9b5cc0da3dfb3775a8c7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:18 2016 -0700 staging: comedi: ni_660x: remove enum clock_config_register_bits Remove this enum and add a define for the bit. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit aa36af205e4e7fd94842be73c1f8a5bb5b12d302 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:17 2016 -0700 staging: comedi: ni_660x: tidy up multi-line comment Reformat the multi-line comment in the kernel CodingStyle. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) commit 01ead0ded315d660b07baccb68ca36c2a7f3da0a Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:16 2016 -0700 staging: comedi: ni_660x: cleanup the NI660X_IO_CFG register helpers Convert the inline functions used to set the bits in the NI600X_IO_CFG registers into macros. Also convert the enum ni_660x_pfi_output_select into defines. This clarifies the association with the register. This also fixes a number of checkpatch.pl issues about: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 81 +++++++++++--------------------- 1 file changed, 28 insertions(+), 53 deletions(-) commit b38700a22a62aaaff04e644a7f1c6b2733249294 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:15 2016 -0700 staging: comedi: ni_660x: rename CamelCase 'NI_660xRegisterData' Rename this CamelCase struct and the associated 'registerData' variable. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 9392e5dde2652ec335f48f28db3c0433cbdc9d92 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:14 2016 -0700 staging: comedi: ni_660x: remove enum ni_660x_register_direction This enum is used to define the, unused, 'direction' of each register in struct NI_660xRegisterData. Remove the unused member, as well as the enum. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 203 +++++++++++++++---------------- 1 file changed, 98 insertions(+), 105 deletions(-) commit 87090141749ad320d937375dcec6d5b925f728c7 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:13 2016 -0700 staging: comedi: ni_660x: remove enum ni_register_width All the registers are defined struct NI_660xRegisterData and they are either 2 or 4 bytes in size. Remove the enum and just use a char member to define the size as 2 or 4 bytes. Simplify the ni_660x_{write,read}_register() functions and remove the unnecessary BUG() in each. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 226 ++++++++++++++----------------- 1 file changed, 103 insertions(+), 123 deletions(-) commit f9565977bf488bd4bf9ef7322728970c20bbc908 Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:12 2016 -0700 staging: comedi: ni_660x: remove struct NI_660xRegisterData 'name' This member of the struct is not used, and just takes up space. Remove it. Instead, add the enum ni_660x_register indexes to the table to clarify, and document, the entries. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 197 +++++++++++++++---------------- 1 file changed, 98 insertions(+), 99 deletions(-) commit 22acd860137ad6952fec8f6041efa9a30e49c22d Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Tue Mar 22 11:10:11 2016 -0700 staging: comedi: ni_660x: change IOConfigReg() into a macro The BUG_ON() in this function is unnecessary. The 'pfi_channel' will always be in range of the subdevice 'n_chan' (NUM_PFI_CHANNELS) which will return a valid 'reg'. Convert the inline function into a simple macro. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/ni_660x.c | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) commit 8dc5fb4e0eb8802ff0615b0fde92f43f3bd5d56d Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:56 2016 +0900 staging: wilc1000: removes unused local variable This patch removes unused local variable. This variable is operation definition that back off from sending packets for some time. However, that has been deleted operation code. That is removes all relative code. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 18 ------------------ 1 file changed, 18 deletions(-) commit 847109fc0f4e5f703107492684de1943069f4530 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:55 2016 +0900 staging: wilc1000: removes define USE_TX_BACKOFF_DELAY_IF_NO_BUFFERS This patch removes define USE_TX_BACKOFF_DELAY_IF_NO_BUFFERS and use it's feature codes. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 8 -------- 1 file changed, 8 deletions(-) commit 7632d9b1a073834df3f3b1d59b9159d9fe5b5419 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:54 2016 +0900 staging: wilc1000: removes unused define This patch removes unused define. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 2 -- drivers/staging/wilc1000/wilc_wlan_if.h | 9 --------- 2 files changed, 11 deletions(-) commit fa63394152e9675c6d9ce32e57fbe00094efb4b8 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:53 2016 +0900 staging: wilc1000: replaces memcmp with ether_addr_equal_unaligned This patch replaces memcmp with ether_addr_equal_unaligned. Warning reported by checkpatch.pl - Prefer ether_addr_equal() or ether_addr_equal_unaligned() over memcmp() Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit e944ad751ff4fbbd0278ba4dd8595bf7fa3c7e9e Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:52 2016 +0900 staging: wilc1000: removes unused debug flags This patch removes unused debug flags. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan_if.h | 12 ------------ 1 file changed, 12 deletions(-) commit 5510730d5f95a37e9de29597e8e7328103bbaf60 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:51 2016 +0900 staging: wilc1000: removes unused dead codes This patch removes unused dead codes that define custom feature. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 8 -------- 1 file changed, 8 deletions(-) commit 340a84ff96c4d9effbc841a085e2101c3977e5cf Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:50 2016 +0900 staging: wilc1000: replaces frame_type with type of struct frame_reg This patch replaces frame_type with type of struct frame_reg. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 8 ++++---- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 4 ++-- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) commit 89febb21c4ca25030c75ba5a7cb64fe02c2cb156 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:49 2016 +0900 staging: wilc1000: replaces g_struct_frame_reg with frame_reg This patch replaces g_struct_frame_reg with frame_reg. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 12 ++++++------ drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 8 ++++---- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) commit c92a869e6170c06219ca550a0e87fbefaa92a30b Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:48 2016 +0900 staging: wilc1000: removes typedef of struct struct_frame_reg This patch removes typedef of struct struct_frame_reg. Renames the struct_frame_reg to frame_reg as well. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_netdevice.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 6d11c5517f544b50827e4ee720fad512ac28e14a Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:47 2016 +0900 staging: wilc1000: wilc_frame_register: removes unused hif_drv This patch removes unused hif_drv of wilc_frame_register function. It's perform an unnecessary null check and debug print log. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 ------ 1 file changed, 6 deletions(-) commit 58e7003f53f32d5beb1a047fd41125d09a1a2467 Author: Leo Kim <leo.kim@atmel.com> Date: Fri Mar 25 21:16:46 2016 +0900 staging: wilc1000: removes WIRELESS_EXT This patch removes WIRELESS_EXT. Does not used the WIRELESS_EXT define. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/Kconfig | 1 - 1 file changed, 1 deletion(-) commit 2bb02584cd95405da72b009d0960f803d31e2302 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Wed Mar 23 21:28:34 2016 +0900 staging: wilc1000: use completion instead of struct semaphore hif_sema_driver struct semaphore hif_sema_driver is used to signal completion of host interface message. This patch replaces struct semaphore hif_sema_driver with struct completion hif_driver_comp. It is better to use completion than semaphore for this case. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 04dd9a421111dfb88e1ae73af0ea27f285c89b74 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Wed Mar 23 21:28:33 2016 +0900 staging: wilc1000: use completion instead of struct semaphore hif_sema_thread struct semaphore hif_sema_thread is used to signal completion of host interface thread. This patch replaces struct semaphore hif_sema_thread with struct completion hif_thread_comp. It is better to use completion than semaphore for this case. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 85d83cd8c629e053e3aaec0a4dd6c798d46c109d Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 23 22:15:53 2016 -0400 staging: unisys: include: changed 'v' variable to 'state' The argument for ULTRA_CHANNELCLI_STRING is supposed to be an integer representing the channel state. 'state' is a more descriptive variable name for this. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/channel.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a22f57c65062a5ca6b4e7ccfbd143c3819b9045b Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 23 22:15:52 2016 -0400 staging: unisys: visorbus: replaced use of vague 'x' variable In client_bus_info_show, the variable 'x' is used to create keep track of the offset that the current 'pos' in the output buffer needs to be incremented by. Since 'off' is already taken 'shift' was used since it's used to shift the pointer. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 65 +++++++++++++------------ 1 file changed, 33 insertions(+), 32 deletions(-) commit 8d7da1d8c2aa5564af442b4371216b4a4288cd5a Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 23 22:15:51 2016 -0400 staging: unisys: visorbus: replaced vague 'p' variable with 'pos' In the case of client_bus_info_show, the variable 'p' was used to indicate the position in the output buffer. This was changed to 'pos' to indicate that it kept track of the current position in the output buffer. Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 62f3dc856736d5ddc782ee1313626ef1adfe18a9 Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 23 22:15:50 2016 -0400 staging: unisys: visorbus: replaced vague variable name in zoneguid_show The variable name "s" doesn't indicate the purpose of the string, which is to store the id collected from the visorchannel_zoneid function. This just replaces the name with "zoneid". Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 48f571489c0e8263b7a37dcd794ecf19b852a4df Author: Alexander Curtin <alexander.curtin@unisys.com> Date: Wed Mar 23 22:15:49 2016 -0400 staging: unisys: visorbus: replaced vague variable name in typeguid_show The variable name "s" doesn't indicate the purpose of the string, which is to store the id collected from the visorchannel_id function. This just replaces the name with "typeid". Signed-off-by: Alexander Curtin <alexander.curtin@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 4d12b5ee26e31b964b8918e7adde081103213b06 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Thu Mar 24 09:18:10 2016 -0400 staging: unisys: remove visorinput.c double negative comparison This patch simply removes the double negative comparison for test_bit since test_bit already preforms this check. Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorinput/visorinput.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 800aecc30b946e849f256e52dfe5c278fc32eb13 Author: Erik Arfvidson <erik.arfvidson@unisys.com> Date: Thu Mar 24 09:18:09 2016 -0400 staging: unisys: remove channel.h double negative comparison This patch removes the double negative comparisons for function readb. Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/include/channel.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c9493bd6c98d3f737341dc8eb7d4aac574934a0d Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:16 2016 -0400 staging: lustre: libcfs: return size_t for libcfs_ioctl_packlen Change return value to size_t. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 243fddea35f8337016049d1bffc1599cd28330a4 Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:15 2016 -0400 staging: lustre: libcfs: use BIT macro in linux-module.c Use the proper BIT macro for libcfs_ioctl_is_invalid(). Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 460a222d9e1c5c0b2f1e037aeab0408a733031dc Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:14 2016 -0400 staging: lustre: libcfs: return proper bool values Return real bool values for libcfs_ioctl_is_invalid(). Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/lnet/libcfs/linux/linux-module.c | 26 +++++++++++----------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 92c18e1335cf757d9881864b58e725482b38a398 Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:13 2016 -0400 staging: lustre: libcfs: add uapi headers to libcfs_ioctl.h Need a few uapi headers to make libcfs_ioctl.h compilable in userland. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 3 +++ 1 file changed, 3 insertions(+) commit da71485102ff8d4b3481dedddcb5a79164f1e4bb Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:12 2016 -0400 staging: lustre: libcfs: make libcfs_ioctl.h readable Fix up all thw whitescapes and line up the IOCTL defines so it is readable. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_ioctl.h | 57 +++++++++++----------- 1 file changed, 29 insertions(+), 28 deletions(-) commit 659bd8d9792a354ba755dab623dc9909cd03206e Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:11 2016 -0400 staging: lustre: libcfs: move function declarations from libcfs_ioctl.h Move the function declartions that are used only by kernel space to libcfs.h This makes libcfs_ioctl.h a offical uapi header now. Move large inline functions out of libcfs_ioctl.h to the source file linux-module.c belonging to libcfs. This code is only used by the core of libcfs and such inline functions don't belong in a uapi header file. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 3 +++ drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 4 ---- 2 files changed, 3 insertions(+), 4 deletions(-) commit cfec4b5c66fa3412b712a6409c2c3d4192faea45 Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:10 2016 -0400 staging: lustre: libcfs: migrate inline functions to source file Move large inline functions out of libcfs_ioctl.h to the source file linux-module.c belonging to libcfs. This code is only used by the core of libcfs and such inline functions don't belong in a uapi header file. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_ioctl.h | 65 ---------------------- .../lustre/lnet/libcfs/linux/linux-module.c | 65 ++++++++++++++++++++++ 2 files changed, 65 insertions(+), 65 deletions(-) commit b02e9d87a76501f2782436c3d5c8d2dde63023dc Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:09 2016 -0400 staging: lustre: libcfs: removal all userland only macros from libcfs_ioctl.h All the macros in libcfs_ioctl.h that is needed by user land have been moved into the lustre utilities software stack. Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/17643 Reviewed-by: Bob Glossman <bob.glossman@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 9 --------- 1 file changed, 9 deletions(-) commit 89010fbc22162708c39447129580c4a47b03260e Author: Parinay Kondekar <parinay.kondekar@seagate.com> Date: Tue Mar 22 19:04:08 2016 -0400 staging:lustre: remove libcfs pseudo device abstraction With the libcfs ioctl cleanup we no longer need the libcfs pseudo device abstraction. Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5844 Reviewed-on: http://review.whamcloud.com/17492 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/libcfs/libcfs.h | 22 +--------------------- .../lustre/lnet/libcfs/linux/linux-module.c | 4 +--- drivers/staging/lustre/lnet/libcfs/module.c | 8 +------- 3 files changed, 3 insertions(+), 31 deletions(-) commit ae272a48a16b53f77215749a68777c6c89ec9925 Author: Parinay Kondekar <parinay.kondekar@seagate.com> Date: Tue Mar 22 19:04:07 2016 -0400 staging:lustre: call libcfs_ioctl directly No reason to go through the cfs_psdev_ops abstract to call libcfs_ioctl. Just call libcfs_ioctl directly. Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5844 Reviewed-on: http://review.whamcloud.com/17492 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 3 ++- drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 13 ++++--------- drivers/staging/lustre/lnet/libcfs/module.c | 5 ++--- 3 files changed, 8 insertions(+), 13 deletions(-) commit 4678d183caf1b8a68860ca07fad95d9c6de14cc3 Author: Parinay Kondekar <parinay.kondekar@seagate.com> Date: Tue Mar 22 19:04:06 2016 -0400 staging:lustre: remove libcfs_psdev_[open|release] With struct libcfs_device_userstate gone we can remove the remaining code of libcfs_psdev_ops.p_[open|close] as well as the libcfs_psdev_[open|release] functions. Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5844 Reviewed-on: http://review.whamcloud.com/17492 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../staging/lustre/include/linux/libcfs/libcfs.h | 2 -- .../lustre/lnet/libcfs/linux/linux-module.c | 32 +--------------------- drivers/staging/lustre/lnet/libcfs/module.c | 16 ----------- 3 files changed, 1 insertion(+), 49 deletions(-) commit c878547fdfa4f8023930cd43b75023f3061f9aa6 Author: Parinay Kondekar <parinay.kondekar@seagate.com> Date: Tue Mar 22 19:04:05 2016 -0400 staging:lustre: remove the IOC_LIBCFS_MEMHOG ioctl The IOC_LIBCFS_MEMHOG is not needed so remove the last bits. Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5844 Reviewed-on: http://review.whamcloud.com/17492 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 68cf5b83659ecee9ad8a14d8ce74e9c5df6d0956 Author: Parinay Kondekar <parinay.kondekar@seagate.com> Date: Tue Mar 22 19:04:04 2016 -0400 staging:lustre: remove last bits of the IOC_LIBCFS_PANIC ioctl A few pieces still exist for the IOC_LIBCFS_PANIC ioctl. Remove these last bits to prevent old tools from using them. The latest lustre utilities no longer use this ioctl. Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com> Signed-off-by: James Simmons <uja.ornl@yahoo.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5844 Reviewed-on: http://review.whamcloud.com/17492 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 2 +- drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 9 --------- drivers/staging/lustre/lnet/libcfs/module.c | 5 +---- 3 files changed, 2 insertions(+), 14 deletions(-) commit 5206726ad8e286a09e73ae4a542de47f96d62f27 Author: John L. Hammond <john.hammond@intel.com> Date: Tue Mar 22 19:04:03 2016 -0400 staging: lustre: libcfs: remove libcfs_ioctl_popdata wrapper Lets just use copy_to_user() directly instead of having a wrapper function. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/14180 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 1 - drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 7 ------- drivers/staging/lustre/lnet/libcfs/module.c | 7 ++++--- 3 files changed, 4 insertions(+), 11 deletions(-) commit 7b54d08b01e61d35d57cb5cdbaf6cd02babcdf17 Author: John L. Hammond <john.hammond@intel.com> Date: Tue Mar 22 19:04:02 2016 -0400 staging: lustre: libcfs: move libcfs_ioctl_handler stuff to libcfs.h Move all the libcfs_ioctl_handler code from libcfs_ioctl.h to libcfs.h. The header libcfs_ioctl.h is a uapi header so their is no reason to keep kernel internals in that header. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/14180 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs.h | 14 ++++++++++++++ drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 13 ------------- 2 files changed, 14 insertions(+), 13 deletions(-) commit 4801919d0825fa35a7290c3625464f460083f9d9 Author: John L. Hammond <john.hammond@intel.com> Date: Tue Mar 22 19:04:01 2016 -0400 staging: lustre: libcfs: remove libcfsutil.h in comment The header libcfsutil.h has been long gone in the upstream client. Replace libcfsutil.h reference to the current user land header instead. Signed-off-by: John L. Hammond <john.hammond@intel.com> Signed-off-by: James Simmons <uja.ornl@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245 Reviewed-on: http://review.whamcloud.com/14180 Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: frank zago <fzago@cray.com> Reviewed-by: James Simmons <uja.ornl@yahoo.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7401a6b067bcea2469cb0d6bdae34d8dcafc2a0d Author: James Simmons <jsimmons@infradead.org> Date: Tue Mar 22 19:04:00 2016 -0400 staging: lustre: libcfs: change variable name Change arg to uparam name for libcfs_ioctl(). Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit a0d5fce76d69f574df1577d20dc3b25f99031167 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:59 2016 -0400 staging: lustre: simple cleanup in obd_ioctl_popdata Code simplification for obd_ioctl_popdata. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lustre/obdclass/linux/linux-module.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit da4e5898375a100e6c1be984ceee84fb5911b6f6 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:58 2016 -0400 staging: lustre: lnet: make sure lnet data not greater than LIBCFS_IOC_DATA_MAX Fail to compile if largest LNet user land data structures passed to kernel are larger than LIBCFS_IOC_DATA_MAX Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/lnet/api-ni.c | 4 ++++ 1 file changed, 4 insertions(+) commit ed2f549dc0f687f5d454cb20754340e83e5b9c4f Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:57 2016 -0400 staging: lustre: libcfs: test if userland data is to small Ensure that user land data is at least the smallest size. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 5 +++++ 1 file changed, 5 insertions(+) commit 6d0aeaa36178382898a15836c8c6542d92527a8c Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:56 2016 -0400 staging: lustre: libcfs: update error messages in linux-module.c The error message are for libcfs layer not LNet. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/linux/linux-module.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 77f716360939767016e2ceab17f8234d0cabc61b Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:55 2016 -0400 staging: lustre: libcfs: invert test condition for libcfs_ioctl Invert the test of error returned by the handle_ioctl pointer. This reduces the code by one indentation level. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit 4e31dad14dfec5746bdaa593db0cf0d8a6736b1c Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:54 2016 -0400 staging: lustre: libcfs: test if data is NULL Make sure data is not NULL otherwise we get an oops when using the IOC_LIBCFS_MARK_DEBUG ioctl. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 0d674c10b04f2698c07953476393ead13980fa7f Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:53 2016 -0400 staging: lustre: libcfs: move comment in libcfs_ioctl Move the comment about libcfs_ioctl_data_adjust to the section where libcfs_ioctl_data_adjust is actually called. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit ea1bffa45b1c4c0f33590850aa1cad9bc298b816 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:52 2016 -0400 staging: lustre: libcfs: add debugging info for libcfs_ioctl Added some lustre debugging to track down potential future bugs. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit db469aa868657ccf4944fb8a8bc13b54002b356e Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:51 2016 -0400 staging: lustre: libcfs: merge libcfs_ioctl_handle into libcfs_ioctl This is apart of the cleanup of libcfs_ioctl* code. In this part we turn libcfs_ioctl_handle into libcfs_ioctl since libcfs_ioctl is now a skeleton function. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 37 ++++++++++++----------------- 1 file changed, 15 insertions(+), 22 deletions(-) commit e4efb34a3fc335ea7c837a10f5c03fe446e176d0 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:50 2016 -0400 staging: lustre: libcfs: merge code from libcfs_ioctl into libcfs_ioctl_getdata This is apart of the cleanup of libcfs_ioctl* code. In this part some of the code in libcfs_ioctl is migrated into libcfs_ioctl_getdata_len() which is renamed libcfs_ioctl_getdata() Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> .../lustre/include/linux/libcfs/libcfs_ioctl.h | 4 ++-- .../lustre/lnet/libcfs/linux/linux-module.c | 23 ++++++++++++++---- drivers/staging/lustre/lnet/libcfs/module.c | 28 +++------------------- 3 files changed, 23 insertions(+), 32 deletions(-) commit 74bfc129826a0e2e44821a5aea6ecda43fff5f87 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:49 2016 -0400 staging: lustre: libcfs: use break in switch options for libcfs_ioctl_handle Instead of just returning for each switch condition use a break. Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/libcfs/module.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) commit ae664e824e3e4a85dbe857815d269f209d998e36 Author: Liang Zhen <liang.zhen@intel.com> Date: Tue Mar 22 19:03:48 2016 -0400 staging: lustre: libcfs: replace LNET_MAX_IOCTL_BUF_LEN with something bigger The size of LNET_MAX_IOCTL_BUF_LEN restricts the size of libcfs ioctl to the maximum needs of the LNet layer. Since libcfs also handles things like debugging we might need to let user land pass more data to or from the kernel than what is possible Signed-off-by: Liang Zhen <liang.zhen@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5435 Reviewed-on: http://review.whamcloud.com/11313 Reviewed-by: Bobi Jam <bobijam@gmail.com> Reviewed-by: Johann Lombardi <johann.lombardi@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h | 3 +++ drivers/staging/lustre/lnet/libcfs/module.c | 5 +---- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7e221b6088eda47589480bcb29f4aaba44da49c7 Author: James Simmons <jsimmons@infradead.org> Date: Thu Mar 24 11:24:02 2016 -0400 staging: lustre: lnet: revert commit 4671a0266 Commit 4671a0266 change the parameter of the second parameter of cfs_precpt_alloc() from a sizeof type to sizeof type *pointer. This was incorrect in this case and it caused a crash when the LNet layer was brought up in my testing. The reason is cfs_precpt_alloc() creates an array of items where the arrays size is equal to the number of CPTs that exist. Changing to type *pointer only had cfs_precpt_alloc() create an array of pointers instead of an array of actual data structures. This patch reverse this change and adds comments to explain what cfs_precpt_alloc() is actually doing to avoid potential issues like this again. Changelog: v1) Simple revert of the original patch v2) Added in comments to explain why cfs_precpt_alloc() has the arguments it uses. Signed-off-by: James Simmons <jsimmons@infradead.org> Cc: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) commit 62d727c4a99a97e5cc73294d86ccf4b7250bfc3b Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Tue Mar 22 22:23:02 2016 +0530 staging: media: omap1: Replace request_irq with devm_request_irq Replace request_irq with devm_request_irq to get the interrupt for device which is automatically freed on exit. Remove corresponding free_irq from probe and remove functions of a platform device. Also, remove an unnecessary label. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/media/omap1/omap1_camera.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) commit 76e543382bd4f488f2a1ca726b7494e6c5f4cc89 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Tue Mar 22 22:22:56 2016 +0530 staging: media: omap1: Switch to devm_ioremap_resource Replace calls to request_mem_region and ioremap with a direct call to devm_ioremap_resource instead and modify error handling. Move the call to platform_get_resource adjacent to the call to devm_ioremap_resource to make the connection between them more clear. Also remove unnecessary labels, variable initialisations and release_mem_region iounmap from probe and remove functions. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/media/omap1/omap1_camera.c | 31 ++++++------------------------ 1 file changed, 6 insertions(+), 25 deletions(-) commit ba99a0f19ae04820104c1cba11027ec69495879c Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Tue Mar 22 22:22:48 2016 +0530 staging: media: omap1: Replace kzalloc with devm_kzalloc Replace kzalloc with devm_kzalloc and consequently remove kfrees in probe and remove functions of a platform device. As a result of this change, remove unnecessary out of memory message and an unnecessary label. Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/media/omap1/omap1_camera.c | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) commit f90272f432f7515044d9e13a6fa2c8bf1ac14838 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Tue Mar 22 22:22:41 2016 +0530 staging: media: omap1: Replace clk_get with devm_clk_get devm_clk_get allocated resources get released when a driver detaches. Replace clk_get with devm_clk_get and remove corresponding data releasing function clk_put from probe and remove functions of a platform device. Also remove an unnecessary label. This change was made with the help of the following Coccinelle semantic patch: @platform@ identifier p, probefn, removefn; @@ struct platform_driver p = { .probe = probefn, .remove = removefn, }; @prb@ identifier platform.probefn, pdev; expression e; @@ probefn(struct platform_device *pdev, ...) { ... e = - clk_get + devm_clk_get (...); ... ?- clk_put(...); ... } @remove depends on prb@ identifier platform.removefn; @@ removefn(...) { ... ?- clk_put(...); ... } Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/media/omap1/omap1_camera.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) commit 4ada295da12e9d0647801577cef37cfc48d41b38 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:19:49 2016 +0530 staging: rtl8188eu: os_dep: ioctl_linux: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 574502caed4c11c7bbb6b4532a8bb544f626f2dc Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:25:55 2016 +0530 staging: rtl8188eu: os_dep: usb_intf: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/os_dep/usb_intf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6e9aeda3fa6fb1462cfc3d188ecfa734b1af6b21 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:26:33 2016 +0530 staging: rtl8188eu: core: rtw_mlme: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_mlme.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit a703f4726583318b24f76bb6bc61d46a5319f248 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:27:39 2016 +0530 staging: rtl8188eu: rtw_mlme_ext: Clean up tests if NULL returned on failure Some functions like kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 12f037ece36267c7e7c6e0e65bc1abdd4019fb5d Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:28:28 2016 +0530 staging: rtl8188eu: rtw_cmd: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_cmd.c | 44 ++++++++++++++++---------------- 1 file changed, 22 insertions(+), 22 deletions(-) commit 4d97b691475060ea6e1345ea7a7c2cba4658a631 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 20:29:13 2016 +0530 staging: rtl8712: mlme_linux: Clean up tests if NULL returned on failure Some functions like kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/mlme_linux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 06884afcf2ab18d314d94456fbf1ac3c860e99bb Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 18:25:37 2016 +0530 staging: vt6656: Fixed multiple logical comparisions warnings Using comparison to false and true is error prone. Fixed multiple warnings as per checkpatch guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vt6656/wcmd.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit add0f9fefe481cfe719fc8302764e3613de9a054 Author: Anchal Jain <anchalj109@gmail.com> Date: Tue Mar 22 18:01:42 2016 +0530 staging: wilc1000: Remove camel case in variable names. Remove a problem detect by checkpatch.pl CHECK: Avoid CamelCase: <srcAdd> Signed-off-by: Anchal Jain <anchalj109@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_mon.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 992aa7b59f62411cb2e5d4192f8598c0f87f12a6 Author: Daeseok Youn <daeseok.youn@gmail.com> Date: Tue Mar 22 18:20:46 2016 +0900 staging: dgnc: fix camelcase of SerialDriver and PrintDriver fix the checkpatch.pl warning about CamelCase. Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_driver.h | 4 +- drivers/staging/dgnc/dgnc_tty.c | 118 ++++++++++++++++++------------------- 2 files changed, 61 insertions(+), 61 deletions(-) commit b075286912ac435f72d864b2a6dae7ec25eece5d Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:10:32 2016 +0300 staging: iio: accel: adis16240: Improve readability Lines with #define interlaced with comment lines making a mess. Separate groups of #define-comment with blank lines. Separate section title comments with blank lines. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16240.h | 50 +++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) commit 7da6ec4870801c7be8cafb861a87697dd842a1d4 Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:09:53 2016 +0300 staging: iio: accel: adis16220: Improve readability Lines with #define interlaced with comment lines making a mess. Separate groups of #define-comment with blank lines. Separate section title comments with blank lines. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16220.h | 48 +++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) commit 328bdff8ec599ff1b86e52f5d99d31e55c4fbb0b Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:09:21 2016 +0300 staging: iio: accel: adis16209: Improve readability Lines with #define interlaced with comment lines making a mess. Separate groups of #define-comment with blank lines. Separate section title comments with blank lines. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16209.h | 39 +++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) commit 0f5c42116ee7c6f9495222bf53370d19003b946b Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:08:38 2016 +0300 staging: iio: accel: adis16201: Fix 'line over 80 characters' warning Many of the comments in the same lines with #define caused checkpatch warning 'line over 80 characters'. Move all such comments to line before #define. This style is already used in some other .h files in accel: Add blank lines after #define to improve readability. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16201.h | 156 +++++++++++++++++++++++++--------- 1 file changed, 117 insertions(+), 39 deletions(-) commit a48b2362dd8bcdb3d8c65c7e5eca942bda7762b5 Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:08:03 2016 +0300 staging: iio: accel: adis16203: Fix 'line over 80 characters' warning Many of the comments in the same lines with #define caused checkpatch warning 'line over 80 characters'. Move all such comments to line before #define. This style is already used in some other .h files in accel: Add blank lines after #define to improve readability. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16203.h | 132 +++++++++++++++++++++++++--------- 1 file changed, 99 insertions(+), 33 deletions(-) commit 81da8a8913e768d8ce0de9edb5699f3879c1dd51 Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 18:07:22 2016 +0300 staging: iio: accel: adis16204: Fix 'line over 80 characters' warning Many of the comments in the same lines with #define caused checkpatch warning 'line over 80 characters'. Move all such comments to line before #define. This style is already used in some other .h files in accel: Add blank lines after #define to improve readability. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16204.h | 159 +++++++++++++++++++++++++--------- 1 file changed, 118 insertions(+), 41 deletions(-) commit 3261c31c7c2bfbca6db3a7a934ba9341bf65b16d Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 11:43:08 2016 +0300 staging: iio: accel: adis16240: Replace 'unsigned' with 'unsigned int' Replace 'unsigned' with 'unsigned int' to avoid checkpatch warning. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/accel/adis16240_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit a5948d917c5201fb8c4503d82fb6fc09da7ae726 Author: Svetlana Orlik <sveta.orlik.code@gmail.com> Date: Tue Mar 22 07:51:36 2016 +0300 Staging: iio: ad9832: Replace 'unsigned' with 'unsigned int' Replace 'unsigned' with 'unsigned int' to avoid checkpatch.pl warning. Signed-off-by: Svetlana Orlik <sveta.orlik.code@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/frequency/ad9832.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 094c0741dec38c73793f674293dcd2026d1e77d7 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Tue Mar 22 10:28:51 2016 +0530 staging: comedi: amplc_pci230: Convert macro GAT_CONFIG to static inline function Convert macro GAT_CONFIG to static inline function as static inline functions are preferred over macros. This change is possible since the arguments at all call sites have the same type. This was done using Coccinelle: @r@ expression e; @@ - #define GAT_CONFIG(chan, src) e + static inline unsigned int pci230_gat_config(unsigned int chan, + unsigned int src) +{ + return ((chan & 3) << 3) | (src & 7); +} @r1@ expression dev,reg,chan,src; @@ -GAT_CONFIG(chan, src) +pci230_gat_config(chan, src) Also, the comment describing the macro has been removed manually. Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/amplc_pci230.c | 38 ++++++++++++++++----------- 1 file changed, 22 insertions(+), 16 deletions(-) commit 896802a8e208997faff6e38d711cd9b13c7a2e23 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Tue Mar 22 08:39:24 2016 +0900 staging: wilc1000: use mutex instead of struct semaphore hif_sema_deinit This patch replaces struct semaphore hif_sema_deinit with struct mutex hif_deinit_lock. It is better to use mutex because mutex gives better performance than semaphore. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 5150d01ea99230576060e864f7a6f15e29b8dc4d Author: Kathryn Hampton <kh353dev@gmail.com> Date: Tue Mar 15 18:16:24 2016 -0700 staging: vt6655: fix style violations for lines over 80 characters This patch addresses line length errors reported by checkpatch.pl that could be fixed with simple line breaks. Signed-off-by: Kathryn Hampton <kh353dev@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vt6655/baseband.c | 20 ++++++--- drivers/staging/vt6655/baseband.h | 6 ++- drivers/staging/vt6655/card.c | 95 ++++++++++++++++++++++++++------------- drivers/staging/vt6655/card.h | 9 ++-- drivers/staging/vt6655/desc.h | 3 +- drivers/staging/vt6655/mac.c | 15 ++++--- drivers/staging/vt6655/srom.c | 9 ++-- 7 files changed, 106 insertions(+), 51 deletions(-) commit 779bee40b907de23771bb8eaf334b81be53018b1 Author: Samuel Thibault <samuel.thibault@ens-lyon.org> Date: Tue Mar 15 21:34:59 2016 +0100 Staging: speakup: Clear hi font bit from attributes Previously, speakup would see the hi-font bit in attributes. Since this bit has nothing to do with attributes, we need to clear it. Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/speakup/main.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) commit 6c5f37dfbbc9b2121b39be3a7a61b93dbba3ed08 Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Mon Mar 14 21:55:20 2016 +0200 Staging: vt6655: defined byVT3253InitTab_RFMD[] and byVT3253B0_RFMD[] as const arrays. This patch changes byVT3253InitTab_RFMD[] and byVT3253B0_RFMD[] arrays in const arrays since these are not changed anywhere in the code. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/vt6655/baseband.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d4d47895a906779b5e8df157f703f906d22305b5 Author: Leslie Klein <lesliebklein@gmail.com> Date: Mon Mar 21 09:18:35 2016 -0400 Staging: comedi: comedi_fops: Replace 'unsigned' with 'unsigned int' Fix checkpatch warning: Prefer 'unsigned int' to bare use of 'unsigned' in file comedi_fops.c Signed-off-by: Leslie Klein <lesliebklein@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/comedi_fops.c | 48 ++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 24 deletions(-) commit 938cae7ab3b046af9669aa7454fab0546231ba48 Author: Leslie Klein <lesliebklein@gmail.com> Date: Sun Mar 20 20:26:12 2016 -0400 Staging: comedi: comedi_buf: Replace 'unsigned' with 'unsigned int' Fix checkpatch warning: Prefer 'unsigned int' to bare use of 'unsigned' in file comedi_buf.c Signed-off-by: Leslie Klein <lesliebklein@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/comedi_buf.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit f6b1160eb27f990cc1c48b67a5f83cb63115284e Author: H Hartley Sweeten <hsweeten@visionengravers.com> Date: Thu Mar 17 10:10:40 2016 -0700 staging: comedi: dt282x: tidy up register bit defines Arnd Bergmann pointed out that gcc-6 warns about passing negative signed integer into swab16() due to the macro expansion of 'outw'. It appears that the register map constants are causing the warnings. Actually, it might just be the (1 << 15) ones... Convert all the constants as suggested by checkpatch.pl: CHECK: Prefer using the BIT macro The BIT() macro will make all the constants explicitly 'unsigned', which helps to avoid the warning. Fix the, unsused, DT2821_CHANCSR_PRESLA() macro. The "Present List Address" (PRESLA) bits in the CHANCSR register are read only. This define was meant to extract the bits from the read value. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reported-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Tested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/comedi/drivers/dt282x.c | 65 +++++++++++++++++---------------- 1 file changed, 33 insertions(+), 32 deletions(-) commit f3dbe30655a651cd846303ecc7d5c5176c00a023 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 20:46:15 2016 +0530 Staging: wlan-ng: Use x instead of x != NULL. Use x instead of x != NULL.This issue is detected by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/p80211netdev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 78822dc3c371ba7a909de72525ee176f78ea236c Author: Claudiu Beznea <claudiu.beznea@gmail.com> Date: Mon Mar 14 22:45:13 2016 +0200 Staging: wlan-ng: defined oui_rfc1042[] and oui_8021h[] arrays as const arrays This patch defines oui_rfc1042[] and oui_8021h[] arrays from p80211conv.c as const arrays since these are not changed anywhere in code. Signed-off-by: Claudiu Beznea <claudiu.beznea@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wlan-ng/p80211conv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b5e12ec38331256c3055591031ee96454c868209 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 19:49:51 2016 +0530 Staging: rtl8188eu: rtw_efuse: Use sizeof type *pointer instead of sizeof type. Use sizeof type *pointer instead of sizeof type. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_efuse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5ab2ce4305eb3c3b2dff7834993b1f6fb0c409be Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 05:11:04 2016 +0530 staging: rtl8712: Fixed FSF address warning in ieee80211.c Fixed checkpatch warning after removing FSF address block as per guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/ieee80211.c | 4 ---- 1 file changed, 4 deletions(-) commit e8aad70c97ba280152463f6cb4f5e6ee2dd8e230 Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 05:11:03 2016 +0530 staging: rtl8712: Fixed FSF address warning in hal_init.c Fixed checkpatch warning after removing FSF address block as per guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/hal_init.c | 4 ---- 1 file changed, 4 deletions(-) commit c7838db04dc9a6921d3e3771c2deefe9dfe7c1a9 Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 05:11:02 2016 +0530 staging: rtl8712: Fixed FSF address warning in ethernet.h Fixed checkpatch warning after removing FSF address block as per guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/ethernet.h | 4 ---- 1 file changed, 4 deletions(-) commit 501ef12a74a51ffa1a1fe9057565c450be564050 Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 05:11:01 2016 +0530 staging: rtl8712: Fixed FSF address warning in drv_types.h Fixed checkpatch warning after removing FSF address block as per guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/drv_types.h | 4 ---- 1 file changed, 4 deletions(-) commit b2def44cf0616f600636e36f8376061804b83e62 Author: Parth Sane <laerdevstudios@gmail.com> Date: Tue Mar 22 05:11:00 2016 +0530 staging: rtl8712: Fixed FSF address warning in basic_types.h Fixed checkpatch warning after removing FSF address paragraph as per guidelines. Signed-off-by: Parth Sane <laerdevstudios@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/basic_types.h | 4 ---- 1 file changed, 4 deletions(-) commit 0b90c305c93e4e94e80d7f10091867e28f275d37 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Mon Mar 21 02:10:21 2016 +0530 staging: rtl8712: rtl871x_ioctl_linux: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/rtl871x_ioctl_linux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit b1d055005519985784f9a613df81b8dd928c0090 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Mon Mar 21 02:09:49 2016 +0530 staging: rtl8712: rtl871x_cmd: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/rtl871x_cmd.c | 80 +++++++++++++++++------------------ 1 file changed, 40 insertions(+), 40 deletions(-) commit 670e3fef68b82a0d43200fcbb3588c7ffa46ca08 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Mon Mar 21 02:09:17 2016 +0530 staging: rtl8712: rtl871x_mlme: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/rtl871x_mlme.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ddf6451ff98c5139c63639db826df540173db2d5 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Mon Mar 21 02:08:36 2016 +0530 staging: rtl8712: usb_ops_linux: Clean up tests if NULL returned on failure Some functions like kmalloc/kzalloc return NULL on failure. When NULL represents failure, !x is commonly used. This was done using Coccinelle: @@ expression *e; identifier l1; @@ e = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\)(...); ... - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/usb_ops_linux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b7af4e6cc7f8f1b69e20ebd25cb633e30de4799e Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Mon Mar 21 01:23:17 2016 +0530 staging: rtl8712: os_intfs: Change form of NULL comparisons Change null comparisons of the form x == NULL to !x. This was done using Coccinelle. @@ expression e; @@ - e == NULL + !e Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/os_intfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d08073d92463820bcebf8594279c635a793f6772 Author: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Date: Fri Mar 18 23:26:18 2016 +0530 staging: rtl8712: rtl871x_ioctl_set: Remove unused macro Removed Unused macro IS_MAC_ADDRESS_BROADCAST. Grep'd to find occurences. Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/rtl871x_ioctl_set.c | 6 ------ 1 file changed, 6 deletions(-) commit 9555ece315c7809f32ca5bdb8eb19d8160b91517 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 10:47:47 2016 +0530 Staging: rtl8723au: Remove unnecessary return statement. Remove unnecessary return statement. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c | 2 -- 1 file changed, 2 deletions(-) commit 299ccc8a07b79199b79bcfb3f701866f10b42063 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 09:26:02 2016 +0530 Staging: rtl8723au: rtl8723a_rf6052: Remove unnecessary semicolon. Remove unnecessary semicolon. Coccinelle sementic patch as follows: @r_case@ position p; @@ switch (...) { case ...: ...;@p } @r_default@ position p; @@ switch (...) { default: ...;@p } @r1@ statement S; position p1; position p != {r_case.p, r_default.p}; identifier label; @@ ( label:; | S@p1;@p ) Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/hal/rtl8723a_rf6052.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 13c1cce614d339ab369b9c2b10bc2a2d49ad3f6b Author: Edward Lipinsky <ellipinsky@gmail.com> Date: Sat Mar 12 11:45:44 2016 -0800 staging: rtl8723au: Fix line longer than 80 columns. This patch fixes the checkpatch.pl warning: WARNING: line over 80 characters Signed-off-by: Edward Lipinsky <ellipinsky@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8723au/core/rtw_ap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 58493d8e405e6ebe530d04f97bfe32724608c89e Author: Nik Nyby <nikolas@gnu.org> Date: Sun Mar 20 15:46:35 2016 -0400 staging: rtl8192u: fix typo in debug message This fixes a mis-spelled word in a few debug statements. Signed-off-by: Nik Nyby <nikolas@gnu.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/ieee80211/ieee80211_rx.c | 2 +- drivers/staging/rtl8192u/ieee80211/rtl819x_TSProc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 46347b3e096c649adcbe902798eb31c47ad5637c Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 09:15:45 2016 +0530 Staging: rtl8192u: Remove unnecessary semicolon. Remove unnecessary semicolon.This issue is found by coccinelle script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8190_rtl8256.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6c1c9f9d5a079f3139d4dd34836da6eb49cbd5d4 Author: Ben Marsh <bmarsh94@gmail.com> Date: Mon Mar 14 17:40:20 2016 +0100 Staging: rtl8192u: remove extra blank lines. This patch removes blank lines in r8192U_wx.c that were flagged by checkpatch.pl Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8192u/r8192U_wx.c | 22 ---------------------- 1 file changed, 22 deletions(-) commit 968b4e6bd3b00c3c05715f916e27439ff71c737d Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 11:44:05 2016 +0530 Staging: netlogic: Remove & from function name. Remove & from function name,when function name passed as an argument to another function. Function name is used as pointer without &. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/netlogic/xlr_net.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit a6634f83402c5c8baf636998143f956feecfa770 Author: Alison Schofield <amsfield22@gmail.com> Date: Mon Mar 21 15:39:53 2016 -0700 staging: iio: use kernel preferred block commenting style Use * on subsequent lines and trailing */ on a separate line in block comments. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/adc/ad7192.c | 20 ++++++++++---------- drivers/staging/iio/impedance-analyzer/ad5933.c | 5 +++-- drivers/staging/iio/meter/ade7753.c | 3 ++- drivers/staging/iio/meter/ade7754.c | 3 ++- drivers/staging/iio/meter/ade7758_core.c | 3 ++- drivers/staging/iio/meter/ade7759.c | 3 ++- drivers/staging/iio/meter/ade7854.c | 3 ++- 7 files changed, 23 insertions(+), 17 deletions(-) commit 017168b5fd913df50a80b65b9c086066f1484a13 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 19:52:44 2016 +0530 Staging: lustre: o2iblnd: Use sizeof type *pointer instead of sizeof type. Use sizeof type *pointer instead of sizeof type. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9899cb68c6c23d58b27035c237b2d425f4c6133c Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 19:51:12 2016 +0530 Staging: lustre: rpc: Use sizeof type *pointer instead of sizeof type. Use sizeof type *pointer instead of sizeof type. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/rpc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 4ec4595272240b21365b6563c24b1e22570c3880 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 19:16:48 2016 +0530 Staging: lustre: socklnd: Remove return statement from void function. Remove return statement from void function. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/socklnd/socklnd.c | 1 - 1 file changed, 1 deletion(-) commit 4f296211583ade450f25a14be0a669a309ea6303 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 19:15:24 2016 +0530 Staging: lustre: socklnd_lib: Remove return statement from void function. Remove return statement from void function. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/socklnd/socklnd_lib.c | 3 --- 1 file changed, 3 deletions(-) commit bb94df96f7a260ff0d4384719fd8cac477e4c31d Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 18:06:03 2016 +0530 Staging: lustre: lib-move: Remove unnecessary space after cast. Remove unnecessary space after cast. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/lnet/lib-move.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 5c722af4c454c881349fec4f8ee3a4ee0a2a77ed Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 08:45:08 2016 +0530 Staging: i4l: pcbit: drv: Remove unnecessary semicolon. Remove unnecessary semicolon.This issue is detected by coccinelle script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/pcbit/drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 8c9a093e1cec027bec070134fd56d9ae98b080a8 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 20 16:52:35 2016 +0530 Staging: i4l: pcbit: capi: Add parentheses to complex macro. Add parentheses to complex macro. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/pcbit/capi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3e735d1e3a9a045cbd2610ff33e9fd355d09e632 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 20 16:50:49 2016 +0530 Staging: i4l: pcbit: drv: Do not initialise statics to 0. Do not initialise statics to 0. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/pcbit/drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f2cef3f2db6647975bb7e8a83fcdfc52146b55c0 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 20 16:49:02 2016 +0530 Staging: i4l: pcbit: edss1: Use !x instead of x == NULL. Use !x instead of x == NULL. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/pcbit/edss1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f3fe438db281cc2d115843d27c7e196bf7404d3c Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 20 16:47:28 2016 +0530 Staging: i4l: pcbit: layer2: Add parentheses to complex macro. Add parentheses to complex macro. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/i4l/pcbit/layer2.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60abe3510e55cbd74a1ed163fed75a25cae8d45c Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 15:02:41 2016 +0530 Staging: fbtft: fb_agm1264k-fl: No space is necessary after cast. No space is necessary after cast.This problem is found by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fbtft/fb_agm1264k-fl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 8d771ea8bf27ae02bf185bd32c67f4d314865945 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 14:59:34 2016 +0530 Staging: fbtft: fbtft-io: No space is necessary after cast. No space is necessary after cast.This patch is found by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fbtft/fbtft-io.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 8cd977c3166e448684aba578df6e00dad83d990c Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 14:56:31 2016 +0530 Staging: fbtft: fbtft_device: No space is necessary after cast. No space is necessary after cast. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/fbtft/fbtft_device.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 364076730cd046ab347f5883cf9193f33adea1da Author: Heena Sirwani <heenasirwani@gmail.com> Date: Mon Mar 14 17:23:00 2016 +0530 staging: media: omap4iss: Match alignment with open parenthesis. The following patch fixes the following checkpatch.pl warning: CHECK: Alignment should match open parenthesis Signed-off-by: Heena Sirwani <heenasirwani@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/media/omap4iss/iss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b6d3b4577e49fa8d9a37912ea36ae8449d630b0b Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Fri Mar 18 13:56:00 2016 +0530 Staging: emxx_udc: emxx_udc: Add space around operator. Add space around operator.This patch is found by checkpatch.pl script. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/emxx_udc/emxx_udc.h | 40 ++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit abe341744574c3fd076e40f053a6fb2f6e549abc Author: Dilek Uzulmez <dilekuzulmez@gmail.com> Date: Sun Mar 13 23:58:08 2016 +0200 Staging: emxx_udc: Add space around '-' Add space around operator '-'. Problem found using checkpatch.pl CHECK: spaces preferred around that '-' (ctx:VxV) Signed-off-by: Dilek Uzulmez <dilekuzulmez@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/emxx_udc/emxx_udc.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit c70aa60bdc12347120b0f3277de2ec6c26988a2e Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 13 16:41:23 2016 +0530 Staging: gs_fpgaboot: Replace 'int32_t' with 'int'. Replace 'int32_t' with 'int'. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gs_fpgaboot/gs_fpgaboot.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit c5471a6fa66cffdf5c868a9fbec2e06c6fa057c5 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 13 15:52:15 2016 +0530 Staging: gs_fpgaboot: Add space around '+'. Add space around '+'. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gs_fpgaboot/gs_fpgaboot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit e58463b3415f242bbfad816810eb24454f5a0bb1 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 13 15:50:03 2016 +0530 Staging: gs_fpgaboot: Remove unnecessary blank lines. Remove unnecessary blank lines. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gs_fpgaboot/gs_fpgaboot.c | 2 -- 1 file changed, 2 deletions(-) commit 8aba6c6e9821a83937cccbc7f2292e06e605d340 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sun Mar 13 15:48:15 2016 +0530 Staging: gs_fpgaboot: Fix alignment to match open parenthesis. Fix alignment to match open parenthesis. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/gs_fpgaboot/gs_fpgaboot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit de40f2ab975977375e4620448a2967b69cc3c9cb Author: Dilek Uzulmez <dilekuzulmez@gmail.com> Date: Sun Mar 13 23:31:08 2016 +0200 Staging: rts5208: Add space around '+' Add space around operator '+'. Problem found using checkpatch.pl CHECK: spaces preferred around that '+' (ctx:VxV) Signed-off-by: Dilek Uzulmez <dilekuzulmez@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rts5208/ms.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 3733d3f997b468481e609d47fa35badd47d0bf06 Author: Joe Perches <joe@perches.com> Date: Fri Mar 18 13:32:12 2016 -0700 staging: skein: threefish_block: Use ror64 Use the inline instead of direct code to improve readability and shorten the code a little. Done with perl: $ perl -p -i -e 's/\((\w+) \>\> (\d+)\) \| \(\1 \<\< \(64 \- \2\)\)/ror64(\1, \2)/g' drivers/staging/skein/threefish_block.c Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/skein/threefish_block.c | 2144 +++++++++++++++---------------- 1 file changed, 1072 insertions(+), 1072 deletions(-) commit 57d8dfed8586427880516536cf0abc3aa19cea78 Author: Sam Horlbeck Olsen <sam.horlsen@gmail.com> Date: Mon Mar 14 02:09:58 2016 -0500 staging: dgnc: Add whitespace around OR'd flags ("|") This patch fixes the checkpatch.pl message: CHECK: spaces preferred around that '|' (ctx:VxV) + writeb((UART_FCR_ENABLE_FIFO|UART_FCR_CLEAR_RCVR|UART_FCR_CLEAR_XMIT), ^ ^ As per the guidelines for coding style in the kernel, I have updated the digi international driver to include spaces around the OR'd flags; not only is this formatting issue caught by `checkpatch.pl`, in the next `if` block the correct formatting is used, leading to both incorrect and inconsistent code formatting. This patch puts the line in question at 82 characters---while this is over the recommended limit, there are no clear locations to break the line and it barely breaks the cutoff. Signed-off-by: Sam Horlbeck Olsen <sam.horlsen@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/dgnc/dgnc_cls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f3e80d80e9db08edc3de35996027a657b4a8c8de Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 16:20:25 2016 +0530 Staging: rtl8188eu: usb_halinit: Use !x instead of x == NULL. Use !x instead of x == NULL. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/usb_halinit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eec1c50002eafe1c48b550fff10bf3eca83f46ea Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 16:18:47 2016 +0530 Staging: rtl8188eu: rtl8188e_rxdesc: Use !x instead of x == NULL. Use !x instead of x == NULL. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 79146cedc30aba94045114020608dbf951f4c1ff Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 16:16:38 2016 +0530 Staging: rtl8188eu: hal_intf: Use x instead of x != NULL. Use x instead of x != NULL. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/hal_intf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7f69e09aba50113c639a2ed1cbc0e033808b16f2 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Sat Mar 19 16:14:30 2016 +0530 Staging: rtl8188eu: Hal8188ERateAdaptive: Use x instead of x != NULL. Use x instead of x != NULL. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/Hal8188ERateAdaptive.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 17d4591d96d66806d0edd759897699ae50f0e4d4 Author: Nicholas Sim <nicholassimws@gmail.com> Date: Fri Mar 18 12:11:07 2016 +0000 staging: rtl8188eu: remove return at end of void function call Remove unnecessary return statement from last line of void function call Signed-off-by: Nicholas Sim <nicholassimws@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 1 - 1 file changed, 1 deletion(-) commit fb025382b4c2e394dd2b5ac4d173d42d2d9b5b69 Author: Kyle Kuffermann <kyle.kuffermann@gmail.com> Date: Sun Mar 13 10:16:27 2016 -0400 staging: rtl8188eu: Remove license paragraph with mailing address This fixes the issue reported by checkpatch.pl: "Do not include the paragraph about writing to the Free Software Foundation's mailing address from the sample GPL notice. The FSF has changed addresses in the past, and may do so again. Linux already includes a copy of the GPL." in all files for the rtl8188eu driver. Signed-off-by: Kyle Kuffermann <kyle.kuffermann@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/core/rtw_ap.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_cmd.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_debug.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_efuse.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_ieee80211.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_ioctl_set.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_mlme.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_pwrctrl.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_recv.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_rf.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_security.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_sreset.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_sta_mgt.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_wlan_util.c | 5 ----- drivers/staging/rtl8188eu/core/rtw_xmit.c | 5 ----- drivers/staging/rtl8188eu/hal/bb_cfg.c | 5 ----- drivers/staging/rtl8188eu/hal/fw.c | 4 ---- drivers/staging/rtl8188eu/hal/hal_com.c | 5 ----- drivers/staging/rtl8188eu/hal/hal_intf.c | 5 ----- drivers/staging/rtl8188eu/hal/mac_cfg.c | 5 ----- drivers/staging/rtl8188eu/hal/odm.c | 5 ----- drivers/staging/rtl8188eu/hal/odm_HWConfig.c | 5 ----- drivers/staging/rtl8188eu/hal/odm_RTL8188E.c | 5 ----- drivers/staging/rtl8188eu/hal/phy.c | 5 ----- drivers/staging/rtl8188eu/hal/pwrseq.c | 5 ----- drivers/staging/rtl8188eu/hal/pwrseqcmd.c | 4 ---- drivers/staging/rtl8188eu/hal/rf.c | 4 ---- drivers/staging/rtl8188eu/hal/rf_cfg.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188e_cmd.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188e_dm.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188e_xmit.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188eu_led.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188eu_recv.c | 5 ----- drivers/staging/rtl8188eu/hal/rtl8188eu_xmit.c | 5 ----- drivers/staging/rtl8188eu/hal/usb_halinit.c | 5 ----- drivers/staging/rtl8188eu/include/Hal8188EPhyCfg.h | 5 ----- drivers/staging/rtl8188eu/include/Hal8188EPhyReg.h | 5 ----- drivers/staging/rtl8188eu/include/HalHWImg8188E_FW.h | 5 ----- drivers/staging/rtl8188eu/include/HalVerDef.h | 5 ----- drivers/staging/rtl8188eu/include/basic_types.h | 5 ----- drivers/staging/rtl8188eu/include/drv_types.h | 5 ----- drivers/staging/rtl8188eu/include/fw.h | 4 ---- drivers/staging/rtl8188eu/include/hal_com.h | 5 ----- drivers/staging/rtl8188eu/include/hal_intf.h | 5 ----- drivers/staging/rtl8188eu/include/ieee80211.h | 5 ----- drivers/staging/rtl8188eu/include/mlme_osdep.h | 5 ----- drivers/staging/rtl8188eu/include/mp_custom_oid.h | 5 ----- drivers/staging/rtl8188eu/include/odm.h | 5 ----- drivers/staging/rtl8188eu/include/odm_HWConfig.h | 4 ---- drivers/staging/rtl8188eu/include/odm_RTL8188E.h | 5 ----- drivers/staging/rtl8188eu/include/odm_RegDefine11N.h | 5 ----- drivers/staging/rtl8188eu/include/odm_debug.h | 5 ----- drivers/staging/rtl8188eu/include/odm_precomp.h | 5 ----- drivers/staging/rtl8188eu/include/odm_reg.h | 5 ----- drivers/staging/rtl8188eu/include/odm_types.h | 5 ----- drivers/staging/rtl8188eu/include/osdep_intf.h | 5 ----- drivers/staging/rtl8188eu/include/osdep_service.h | 5 ----- drivers/staging/rtl8188eu/include/pwrseq.h | 5 ----- drivers/staging/rtl8188eu/include/pwrseqcmd.h | 5 ----- drivers/staging/rtl8188eu/include/recv_osdep.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_cmd.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_dm.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_hal.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_led.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_recv.h | 5 ----- drivers/staging/rtl8188eu/include/rtl8188e_spec.h | 4 ---- drivers/staging/rtl8188eu/include/rtl8188e_xmit.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_android.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_ap.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_cmd.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_debug.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_eeprom.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_efuse.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_event.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_ht.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_ioctl.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_ioctl_rtl.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_ioctl_set.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_iol.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_mlme.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_mlme_ext.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_mp_phy_regdef.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_pwrctrl.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_qos.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_recv.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_rf.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_security.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_sreset.h | 5 ----- drivers/staging/rtl8188eu/include/rtw_xmit.h | 5 ----- drivers/staging/rtl8188eu/include/sta_info.h | 5 ----- drivers/staging/rtl8188eu/include/usb_hal.h | 5 ----- drivers/staging/rtl8188eu/include/usb_ops_linux.h | 5 ----- drivers/staging/rtl8188eu/include/wifi.h | 5 ----- drivers/staging/rtl8188eu/include/wlan_bssdef.h | 5 ----- drivers/staging/rtl8188eu/include/xmit_osdep.h | 5 ----- drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | 5 ----- drivers/staging/rtl8188eu/os_dep/mlme_linux.c | 5 ----- drivers/staging/rtl8188eu/os_dep/os_intfs.c | 5 ----- drivers/staging/rtl8188eu/os_dep/osdep_service.c | 5 ----- drivers/staging/rtl8188eu/os_dep/recv_linux.c | 5 ----- drivers/staging/rtl8188eu/os_dep/rtw_android.c | 5 ----- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 5 ----- drivers/staging/rtl8188eu/os_dep/usb_ops_linux.c | 4 ---- drivers/staging/rtl8188eu/os_dep/xmit_linux.c | 5 ----- 107 files changed, 528 deletions(-) commit 5a9e10a11e6a76f726235a788265b7c6c5bd1bd7 Author: Ben Marsh <bmarsh94@gmail.com> Date: Sat Mar 12 10:33:00 2016 +0100 Staging: rtl8188eu: removes an unnecessary cast on a void pointer. Patch to rtl8188e_rxdesc.c to remove an unnecessary cast on a void pointer. Signed-off-by: Ben Marsh <bmarsg94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7fcf92c0a4847b0d66fbc09446561752ec2d2575 Author: Juliana Rodrigues <juliana.orod@gmail.com> Date: Sun Mar 13 15:30:57 2016 -0300 staging: rtl8712: rtl8712_cmd.c: fixed comparison to null This patch fixes multiple "comparison to NULL" checkpatch.pl issues: CHECK: Comparison to NULL could be written "!pcmd" + if (pcmd == NULL) Signed-off-by: Juliana Rodrigues <juliana.orod@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/rtl8712_cmd.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 4dadfb97b73f0fbcc0c6f5a6897c0942c05a9dd3 Author: Juliana Rodrigues <juliana.orod@gmail.com> Date: Sun Mar 13 15:07:30 2016 -0300 staging: rtl8712: hal_init.c: fix comment block code style This patch fixes several warnings caused by malformed comments on hal_init.c and found by checkpatch.pl. Signed-off-by: Juliana Rodrigues <juliana.orod@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/rtl8712/hal_init.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit b59958ee900c81692da131873c0fc0b1599f164f Author: Roger H. Newell <newell.roger@gmail.com> Date: Sat Mar 19 12:50:52 2016 -0230 staging: wilc1000: Replaced comparison to NULL statements This patch corrects checks generated by checkpatch.pl by replacing comparison to null statements with equivalent statements in the form "x" or "!x" Signed-off-by: Roger H. Newell <newell.roger@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 2 +- drivers/staging/wilc1000/wilc_wlan_cfg.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit d5e27e8b83b1da0cd64a6a090e273a199c2805fc Author: Roger H. Newell <newell.roger@gmail.com> Date: Sat Mar 19 12:49:21 2016 -0230 staging: wilc1000: Removed braces from single block statements This patch corrects warnings generated by checkpatch.pl by removing braces from single block statements. Signed-ff-by: Roger H. Newell <newell.roger@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 31 +++++++++-------------- drivers/staging/wilc1000/wilc_wlan_cfg.c | 3 +-- 2 files changed, 13 insertions(+), 21 deletions(-) commit 702962f33ba664d3a6ce2008d076dccd93c420a2 Author: Alison Schofield <amsfield22@gmail.com> Date: Mon Mar 14 10:35:41 2016 -0700 staging: wilc1000: replace sem_test_key_block with a completion Semaphore sem_test_key_block is used to signal completion of its host interface message. Since the thread locking this semaphore will have to wait, completions are the preferred mechanism and will offer a performance improvement. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 24 ++++++++++++------------ drivers/staging/wilc1000/host_interface.h | 2 +- 2 files changed, 13 insertions(+), 13 deletions(-) commit 96adbd276e7194320f08fd7f00c4a1be2d910d11 Author: Alison Schofield <amsfield22@gmail.com> Date: Mon Mar 14 10:35:05 2016 -0700 staging: wilc1000: replace sem_test_disconn_block with a completion Semaphore sem_test_disconn_block is used to signal completion of its host interface message. Since the thread locking this semaphore will have to wait, completions are the preferred mechanism and will offer a performance improvement. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 +++--- drivers/staging/wilc1000/host_interface.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7c8a3dcac82f11681e3e6ad61fb2e5802a136c24 Author: Alison Schofield <amsfield22@gmail.com> Date: Mon Mar 14 10:34:39 2016 -0700 staging: wilc1000: replace semaphore sem_get_rssi with a completion Semaphore sem_get_rssi is used to signal completion of its host interface message. Since the thread locking this semaphore will have to wait, completions are the preferred mechanism and will offer a performance improvement. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 6 +++--- drivers/staging/wilc1000/host_interface.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) commit e0c1496fcf6a1bbc9b827e763f58535585b249d5 Author: Alison Schofield <amsfield22@gmail.com> Date: Mon Mar 14 10:34:14 2016 -0700 staging: wilc1000: replace semaphore sem_inactive_time with a completion Semaphore sem_inactive_time is used to signal completion of its host interface message. Since the thread locking this semaphore will have to wait, completions are the preferred mechanism and will offer a performance improvement. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 7 ++++--- drivers/staging/wilc1000/host_interface.h | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) commit 1b7c69e84bcea7a8054b44e6671e7b9ad758c2d8 Author: Anchal Jain <anchalj109@gmail.com> Date: Mon Mar 14 18:06:54 2016 +0530 staging: wilc1000: Fix lines over 80 characters Break lines so that they do not exceed 80 characters. Problem found using checkpatch. Signed-off-by: Anchal Jain <anchalj109@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_mon.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) commit a5c3f8db438ab3627992124eae98fefcce53977f Author: Anchal Jain <anchalj109@gmail.com> Date: Sun Mar 13 15:14:38 2016 +0530 staging: wilc1000: else is not generally useful after a break or return Remove else after a break. Because else is generally not useful after a break or return. Signed-off-by: Anchal Jain <anchalj109@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit 613eaa39d68b928c52a8d93bec4573925f009b62 Author: Chaehyun Lim <chaehyun.lim@gmail.com> Date: Mon Mar 14 09:40:27 2016 +0900 staging: wilc1000: use completion instead of struct semaphore hif_sema_wait_response This patch replaces struct semaphore hif_sema_wait_response with struct completion hif_wait_response. In case of struct hif_sema_wait_response, it better to use completion than semaphore. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/host_interface.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 88253ab8e637f210decc8d3ec910e5205cb75b34 Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:14 2016 +0900 staging: wilc1000: removes an unnecessary if-condition This patch removes an unnecessary if-condition. Regardless of an if-condition is performed unconditionally '_end_' statement. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 2 -- 1 file changed, 2 deletions(-) commit 5c6021da1c3c46f3c2727626b4a3b9c96bf688ec Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:13 2016 +0900 staging: wilc1000: removes goto definitions from wilc_wlan_firmware_download This patch removes goto definitions from wilc_wlan_firmware_download function. Goto '_fail_1' feature is error return. It returns error type directly without result variable replacement as well. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 90fd4cc5d25d5baf5540c99c100e82ce06af63f0 Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:12 2016 +0900 staging: wilc1000: changes an ambiguous debug messages This patches changes an ambiguous debug messages. The device types are both SDIO or SPI. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ba7504730b26b7eb49731a5ac7972c34f0513ac1 Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:11 2016 +0900 staging: wilc1000: removes duplicate wilc variable setting This patches removes duplicate wilc variable setting. This value has already been set to wl variable previously. Replace wilc with wl as well. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) commit 2dfad49a8f93ceae8a74bc403664fd13f801f8fe Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:10 2016 +0900 staging: wilc1000: removes duplicate vif variable setting This patches removes duplicate vif variable setting. This value has already been set previously. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/linux_wlan.c | 1 - 1 file changed, 1 deletion(-) commit 9635d338303c3ed80e06c03b54ee171651438984 Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:09 2016 +0900 staging: wilc1000: wilc_spi.c: removes debug print log This patches removes unnecessary debug print logs. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_spi.c | 3 --- 1 file changed, 3 deletions(-) commit 6422ea03f335bf7441150555de1ab048ac82ee99 Author: Leo Kim <leo.kim@atmel.com> Date: Tue Mar 15 18:48:08 2016 +0900 staging: wilc1000: removes function 'init_tcp_tracking()' This patch removes function 'init_tcp_tracking()'. The function is an unnecessary return. Signed-off-by: Leo Kim <leo.kim@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/wilc1000/wilc_wlan.c | 6 ------ 1 file changed, 6 deletions(-) commit a3dac5a35cc54fa983e3de56ec010734c87315c4 Author: Ben Marsh <bmarsh94@gmail.com> Date: Tue Mar 15 19:37:54 2016 +0100 Staging: nvec: removes a useless cast on a void pointer Remove an unnecessary cast on a void pointer in nvec_power.c Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/nvec/nvec_power.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f05f33fae3c720bd555ceb15b46beb4c642b663a Author: Laura Garcia Liebana <nevola@gmail.com> Date: Sat Mar 12 16:19:11 2016 +0100 staging: nvec: Fix comparison to NULL Replace the use of comparison to NULL, use !<expression> instead. Checkpatch detected these issues. Signed-off-by: Laura Garcia Liebana <nevola@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/nvec/nvec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 9fc27699bd16707ae95218ba553bde144f5afbed Author: Laura Garcia Liebana <nevola@gmail.com> Date: Sat Mar 12 16:20:04 2016 +0100 staging: nvec: Remove space after a cast No space is required after a cast. Checkpatch detected this issue. Signed-off-by: Laura Garcia Liebana <nevola@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/nvec/nvec.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) commit ac05a587c8a7b6ae8c4acef5a6db7e6ccfbcfd3e Author: Laura Garcia Liebana <nevola@gmail.com> Date: Sat Mar 12 16:35:30 2016 +0100 staging: octeon: Fix alignment with open parenthesis Alignment should match open parenthesis. Checkpatch detected these issues. Signed-off-by: Laura Garcia Liebana <nevola@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/octeon/ethernet-rx.c | 7 ++++--- drivers/staging/octeon/ethernet-rx.h | 2 +- drivers/staging/octeon/ethernet-tx.c | 5 +++-- drivers/staging/octeon/ethernet.c | 4 ++-- 4 files changed, 10 insertions(+), 8 deletions(-) commit c2598d468f3cccb1266a8ffe1a0d7268ff2d8eb4 Author: Laura Garcia Liebana <nevola@gmail.com> Date: Sat Mar 12 16:03:50 2016 +0100 staging: octeon: Use type int instead of int32_t Prefer the use of type int instead of int32_t. Checkpatch detected these issues. Signed-off-by: Laura Garcia Liebana <nevola@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/octeon/ethernet-tx.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 514dd88df707a1094e937c20d5a0b1ec619e1f96 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Sat Mar 12 15:01:04 2016 +0530 staging: slicoss: Add error check for pci_map_single Currently, DMA mapping failure is not detected, causing the hardware to attempt a DMA from an invalid address. This patch adds the corresponding error check for pci_map_single i.e. pci_dma_mapping_error. Problem found using the following Coccinelle semantic patch: // <smpl> @@ expression e1; identifier x; @@ x= ( *dma_map_single(...) | *dma_map_page(...) ) ... when != dma_mapping_error(e1,x) @@ expression e1; identifier x; @@ x = ( *pci_map_single(...) | *pci_map_page(...) ) ... when != pci_dma_mapping_error(e1,x) // </smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/slicoss/slicoss.c | 5 +++++ 1 file changed, 5 insertions(+) commit afb105549d4879018e45bbf77e76034237d8fc20 Author: PrasannaKumar Muralidharan <prasannatsmkumar@gmail.com> Date: Sat Mar 12 14:03:09 2016 +0530 Staging: most: Remove atomic_counter_t typedef Remove atomic_counter_t typedef, use int instead. Signed-off-by: PrasannaKumar Muralidharan <prasannatsmkumar@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/most/hdm-dim2/dim2_hal.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit 7df7ee9be9801a7d0c73e9a4ef3e4912aef8b083 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 17:19:44 2016 +0530 Staging: iio: ad5933: Remove unnecessary space after cast. Remove unnecessary space after cast. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/impedance-analyzer/ad5933.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 04e1f7b9b0b24b0d2fb669ea8fdce429478da72f Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 13:17:01 2016 +0530 Staging: iio: ade7758: Fix open parentheses alignment issues. Fix open parentheses alignment issues. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/meter/ade7758.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) commit 93636775b9b68f239cf6a100f9148c0936dbd02e Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 13:15:13 2016 +0530 Staging: iio: ade7758: Use a blank line after function/struct declarations. Use a blank line after function/struct declarations. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/meter/ade7758.h | 6 ++++++ 1 file changed, 6 insertions(+) commit 929d2691f202c1904db5a8a471636e030eaef570 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 13:13:46 2016 +0530 Staging: iio: ade7758_core: Remove unnecessary blank line. Remove unnecessary blank line. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/meter/ade7758_core.c | 1 - 1 file changed, 1 deletion(-) commit 0eea4ce3f4be3253206ca7bb84a458cea0c41e01 Author: Sandhya Bankar <bankarsandhya512@gmail.com> Date: Mon Mar 21 13:11:15 2016 +0530 Staging: iio: ade7758_core: Fix open parentheses alignment issues. Fix open parentheses alignment issues. Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/meter/ade7758_core.c | 73 ++++++++++++-------------------- 1 file changed, 26 insertions(+), 47 deletions(-) commit 5359ada246eb651679b80cfaa036c1d1ebcd0896 Author: Alison Schofield <amsfield22@gmail.com> Date: Thu Mar 17 00:00:20 2016 -0700 staging: iio: ad5933: remove unused #includes Remove #includes no longer used in this module. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/impedance-analyzer/ad5933.c | 2 -- 1 file changed, 2 deletions(-) commit f5d82ad9bca2df8204c9b47748cbf1c5f3eb691d Author: Alison Schofield <amsfield22@gmail.com> Date: Wed Mar 16 23:59:19 2016 -0700 staging: iio: ad5933: move contents of header file to source file The contents of the header file are used only by this single source file. Move content into .c and remove .h. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/impedance-analyzer/ad5933.c | 14 +++++++++++-- drivers/staging/iio/impedance-analyzer/ad5933.h | 28 ------------------------- 2 files changed, 12 insertions(+), 30 deletions(-) commit e279ee89d349af16fc7b77f4d715cd2826ac8249 Author: Alison Schofield <amsfield22@gmail.com> Date: Sun Mar 13 23:15:51 2016 -0700 staging: iio: io-trig-bfin-timer: use dev_get_platdata() Use dev_get_platdata() for retrieving the platform data instead of accessing dev->platform_data directly. Move the assignment out of the declaration (avoid lines over 80 char and put it close to usage). Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/trigger/iio-trig-bfin-timer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 7b58e2402f965c97c191570e187fa107230d09b4 Author: Alison Schofield <amsfield22@gmail.com> Date: Sun Mar 13 23:13:49 2016 -0700 staging: iio: ad5933: use dev_get_platdata() Use dev_get_platdata() for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/impedance-analyzer/ad5933.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 5e3d1d520ffccb956a5b00c8a858416747869058 Author: Alison Schofield <amsfield22@gmail.com> Date: Sun Mar 13 23:11:30 2016 -0700 staging: iio: meter: remove fixme comment on device remove This comment was in place in the original drafts of these drivers when the remove function did a whole lot of work: flushed queues, unregistered interrupts, uninitialized rings, unconfigured rings, and a few kfree's. The remove functions have since been reduced to unregistering and stopping the device. This is the inverse of what was done during probe and is correct. Time to remove the comment. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/meter/ade7753.c | 1 - drivers/staging/iio/meter/ade7754.c | 1 - drivers/staging/iio/meter/ade7759.c | 1 - 3 files changed, 3 deletions(-) commit b026338289d65ef6fddfefcf5d1ba7932bc77c8a Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 12 16:19:24 2016 +0800 staging: iio: tsl2x7x_core: add blank line after struct declaration Add the missing blank line after struct declaration. Checkpatch found this issue. CHECK: Please use a blank line after function/struct/union/enum declarations Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/light/tsl2x7x_core.c | 1 + 1 file changed, 1 insertion(+) commit 95066a028b6bf9a1f4c6fcb69fab8474952bc858 Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 12 16:19:23 2016 +0800 staging: iio: tsl2x7x_core: add spaces around operators Address the checkpatch check by adding the necessary whitespace around operators: CHECK: spaces preferred around that '/' (ctx:VxV) Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/light/tsl2x7x_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 54a0cd3e5757e6cbec63911f234190287ebeca29 Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 12 16:19:22 2016 +0800 staging: iio: tsl2x7x_core: remove space after a cast Delete unneeded space after a cast as suggested by checkpatch. CHECK: No space is necessary after a cast. Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/light/tsl2x7x_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 2cbc8b34ef9fd081a4ae90460b9e26756ddebfe4 Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 12 16:19:21 2016 +0800 staging: iio: tsl2x7x_core: use preferred comment style Adjust block comments by adding the necessary trailing */ on a separate line. Checkpatch found this issue. Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/light/tsl2x7x_core.c | 38 +++++++++++++++++++++----------- 1 file changed, 25 insertions(+), 13 deletions(-) commit 437ba274b5e5c813c2cede7051701ff3f0959022 Author: Eva Rachel Retuya <eraretuya@gmail.com> Date: Sat Mar 12 16:19:20 2016 +0800 staging: iio: tsl2x7x_core: adjust alignment to match open parenthesis Align the parameters to match open parenthesis. Issue detected using checkpatch. CHECK: Alignment should match open parenthesis Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/iio/light/tsl2x7x_core.c | 164 +++++++++++++++++-------------- 1 file changed, 92 insertions(+), 72 deletions(-) commit 0b2acf34f3680c4b0857625af667dcd53d39028e Author: David Kershner <david.kershner@unisys.com> Date: Sat Mar 12 21:27:12 2016 -0500 staging: unisys: visorbus: rename create_visor_device gotos Away is ambiguous when specifying error vs success. Make return labels more meaningful by marking them as error paths. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) commit 8e33f48c9585c82258c8bef1d93149ca27f8d91d Author: David Kershner <david.kershner@unisys.com> Date: Sat Mar 12 21:27:11 2016 -0500 staging: unisys: visorbus: Remove gotos in visorbus_match Gotos in visorbus_match are not needed. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) commit 78af1aef662eef4ffac6f453fdc46d3389274f34 Author: David Kershner <david.kershner@unisys.com> Date: Sat Mar 12 21:27:10 2016 -0500 staging: unisys: visorbus: fix up gotos in visorbus_init This patch fixes the gotos in visorbus_init Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit b750b05939778a8b43fc7e3c96a48f59d123451d Author: Tim Sell <Timothy.Sell@unisys.com> Date: Sat Mar 12 21:27:09 2016 -0500 staging: unisys: visorbus: remove unused sysfs attribute devmajorminor/* The sysfs attribute directory at: /sys/bus/visorbus/devices/vbus<x>:dev<y>/devmajorminor/* or /sys/devices/visorbus<x>/vbus<x>:dev<y>/devmajorminor/* previously provided a location where a visorbus function driver could publish information (for usermode use) about possibly-multiple major and minor device numbers for character devices created for a each visorbus device, using visorbus_registerdevnode(). This functionality is not currently used, so it has been removed by this cset. Signed-off-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/Documentation/overview.txt | 19 --- drivers/staging/unisys/include/visorbus.h | 3 - drivers/staging/unisys/visorbus/visorbus_main.c | 194 ---------------------- 3 files changed, 216 deletions(-) commit 4000622ec21ba5e93fdb74bc4168a9545a089ce7 Author: David Kershner <david.kershner@unisys.com> Date: Sat Mar 12 21:27:08 2016 -0500 staging: unisys: visorbus: Fix up visordriver_probe Fixup the visordriver_probe function. Rearrange the function to avoid needing gotos and removed unnecessary wmb(). Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorbus_main.c | 32 ++++++++++--------------- 1 file changed, 12 insertions(+), 20 deletions(-) commit c6af7a9cbcfa65b9322436836ad7cc323d2d5d6d Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:44 2016 -0500 staging: unisys: visorbus: fix my_create_device goto statements Don't use the abmiguous cleanup, make it more meaningful. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit 368acb3f512b415d11bfc3801b4a3d1453cc455d Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:43 2016 -0500 staging: unisys: visorbus: Cleanup bus_epilog goto statements Cleaned up bus_epilogs vague gotos and in the process discovered some error paths that could unlock a non locked semaphore. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) commit 9fd04060abdfd1e2ec763ea0096cc91026c77cca Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:42 2016 -0500 staging: unisys: visorbus: Cleanup goto in bus_create Rename it to what it does instead of the default ambiguous cleanup. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 5233d1ebb6c99ca67521cdeb66dccd1256820d5f Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:41 2016 -0500 staging: unisys: visorbus: chipset_init rename goto Change the goto label "cleanup" to something more useful like out_respond. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d79f56b59917fcd3e21190f281e07ebda628eb17 Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:40 2016 -0500 staging: unisys: visorbus: cleanup gotos in parser_init_byte_stream Clean up the goto in parser_init_byte_stream and make the goto section the error case. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 39 +++++++++----------------- 1 file changed, 14 insertions(+), 25 deletions(-) commit dde29996cdb1514a457ffbfaaf8f795d66fe2a5a Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:39 2016 -0500 staging: unisys: visorbus: get rid of gotos in intialize_controlvm_payload_info Get rid of the gotos in initialize_controlvm_payload_info. The check in the error path if payload was valid was never called so get rid of that as well. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 30 ++++++++------------------ 1 file changed, 9 insertions(+), 21 deletions(-) commit b899963f158056f19928ed5dc7314fac5b57db97 Author: David Kershner <david.kershner@unisys.com> Date: Fri Mar 11 17:01:38 2016 -0500 staging: unisys: visorbus: cleanup goto in setup_crash_devices_work_queue If visorbus has registered yet just reschedule and exit. The rest of the function doesn't need to reschedule so just move it up to the initial check. Signed-off-by: David Kershner <david.kershner@unisys.com> Signed-off-by: Timothy Sell <timothy.sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/unisys/visorbus/visorchipset.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) commit dae0587ef0c8e6584837d3737fc5555eb2b36097 Author: James Simmons <jsimmons@infradead.org> Date: Sat Mar 12 13:00:36 2016 -0500 staging: lustre: cleanup comment style for lnet selftest Apply a consistent style for comments in the lnet selftest code. Realign some of the comments to make it easier to read. This also fixes a few checkpatch issues as well. Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 2 +- drivers/staging/lustre/lnet/selftest/conctl.c | 50 ++++++++++++------------ drivers/staging/lustre/lnet/selftest/conrpc.c | 17 ++++---- drivers/staging/lustre/lnet/selftest/console.c | 5 ++- drivers/staging/lustre/lnet/selftest/framework.c | 12 +++--- drivers/staging/lustre/lnet/selftest/ping_test.c | 2 +- drivers/staging/lustre/lnet/selftest/rpc.c | 8 ++-- drivers/staging/lustre/lnet/selftest/timer.c | 2 +- 8 files changed, 50 insertions(+), 48 deletions(-) commit 0b4427deebab7cf86917772f8e00061c63494cd3 Author: James Simmons <jsimmons@infradead.org> Date: Sat Mar 12 13:00:35 2016 -0500 staging: lustre: realign some code in lnet selftest so its readable Two places to align the code so it is easier to read. Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/console.c | 2 +- drivers/staging/lustre/lnet/selftest/ping_test.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 9b8fa4456cf3f6428958a71fdcc5fef64f3f0e11 Author: James Simmons <jsimmons@infradead.org> Date: Sat Mar 12 13:00:34 2016 -0500 staging: lustre: remove excess blank lines in lnet selftest code Remove extra blank lines missed by checkpatch. Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/brw_test.c | 2 -- drivers/staging/lustre/lnet/selftest/conrpc.c | 2 -- drivers/staging/lustre/lnet/selftest/console.c | 2 -- 3 files changed, 6 deletions(-) commit 3eaf9fcc4b97dc3a475d2328c29cfd46615b3e55 Author: James Simmons <jsimmons@infradead.org> Date: Sat Mar 12 13:00:33 2016 -0500 staging: lustre: handle error returned from wait_event_timeout seltest timer The function wait_event_timeout can fail and return an error. Handle this case in stt_timer_main(). Signed-off-by: James Simmons <jsimmons@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/timer.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit ea25f451a063e1934402fab578d85ea8254d3dee Author: Dmitry Eremin <dmitry.eremin@intel.com> Date: Sat Mar 12 13:00:32 2016 -0500 staging: lustre: add missing buffer overflow fix for console.c Patch 9389 change a strncpy call into a strlcpy call. This was missed in the merger into the upstream client. Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4629 Reviewed-on: http://review.whamcloud.com/9389 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/console.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit bde98b0603cf6ebdf2d5aea7f83f02f88aa35a7f Author: James Nunez <james.a.nunez@intel.com> Date: Sat Mar 12 13:00:31 2016 -0500 staging: lustre: Correct missing newline for CERROR call in sfw_handle_server_rpc This is one of the fixes broken out of patch 10000 that was missed in the merger. With this fix the CERROR called in sfw_handle_server_rpc will print out correctly. Signed-off-by: James Nunez <james.a.nunez@intel.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4871 Reviewed-on: http://review.whamcloud.com/10000 Reviewed-by: Andreas Dilger <andreas.dilger@intel.com> Reviewed-by: John L. Hammond <john.hammond@intel.com> Reviewed-by: Cliff White <cliff.white@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/selftest/framework.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3d1477309806459d39e13d8c3206ba35d183c34a Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Sat Mar 19 18:02:55 2016 +0530 staging: lustre: lnet: Replace sg++ with sg = sg_next(sg) With scatterlist chaining, simply incrementing the array does not work. sg_next macro was thus introduced to follow the chain links when necessary. So replace sg++ with sg_next. This change was made with the help of the following Coccinelle semantic patch: //<smpl> @@ struct scatterlist *sg; @@ -sg++ +sg = sg_next(sg) //</smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 115510053e5e5872f1f19a2220b04aab5542c5c4 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Mon Mar 28 17:51:37 2016 +0800 clk: rockchip: add clock controller for the RK3399 Add the clock tree definition for the new RK3399 SoC. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/Makefile | 1 + drivers/clk/rockchip/clk-rk3399.c | 1540 +++++++++++++++++++++++++++++++++++++ drivers/clk/rockchip/clk.h | 22 +- 3 files changed, 1562 insertions(+), 1 deletion(-) commit 485a40d7cd4aab5ae939320278809776388f5c06 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Mon Mar 28 17:51:35 2016 +0800 dt-bindings: add bindings for rk3399 clock controller Add devicetree bindings for Rockchip cru which found on Rockchip SoCs. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> .../bindings/clock/rockchip,rk3399-cru.txt | 62 ++++++++++++++++++++++ 1 file changed, 62 insertions(+) commit 1c234eba6219839dd75466e56cb28df08ac45edd Merge: 1d003eb f35f622 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Mar 28 13:23:21 2016 +0200 Merge branch 'v4.7-shared/clkids' into v4.7-clk/next commit f35f622536b8279574edc1b3d82f8f35ddd89132 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Mon Mar 28 17:51:36 2016 +0800 clk: rockchip: add dt-binding header for rk3399 Add the dt-bindings header for the rk3399, that gets shared between the clock controller and the clock references in the dts. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/clock/rk3399-cru.h | 752 +++++++++++++++++++++++++++++++++ 1 file changed, 752 insertions(+) commit fd8b62cc38b356bcdf20ac8f1a647db7b11240cf Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:24:38 2016 +0800 soc: rockchip: power-domain: Modify power domain driver for rk3399 This driver is modified to support RK3399 SoC. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> [small indentation fixups] Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 55 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) commit e6e270aecbb0ed605b7267fdf6f828945014de24 Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:24:21 2016 +0800 dt-bindings: add binding for rk3399 power domains Add binding documentation for the power domains found on Rockchip RK3399 SoCs Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> .../bindings/soc/rockchip/power_domain.txt | 37 ++++++++++++++++++++++ 1 file changed, 37 insertions(+) commit 51665c6e885d650bd910954fc044e91ec0a6f20a Merge: 6be05b5 86e6e64 Author: Heiko Stuebner <heiko@sntech.de> Date: Mon Mar 28 13:13:58 2016 +0200 Merge branch 'v4.7-shared/pdids' into v4.7-armsoc/drivers commit 86e6e64be72be95debac65aa4d2118bd70982ee9 Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:22:56 2016 +0800 dt-bindings: add power-domain header for RK3399 SoCs According to a description from TRM, add all the power domains Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> include/dt-bindings/power/rk3399-power.h | 53 ++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) commit 6be05b5ec16132f3df3f1d857ab01e30f726b542 Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:22:55 2016 +0800 soc: rockchip: power-domain: add support for sub-power domains This patch adds support for making one power domain a sub-domain of other domain. This is useful for modeling power dependences, which needs to have more than one power domain enabled to be operational. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> [restructured error handling in subdomain-addition] Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 63 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) commit ccd63c20fe834a3f98f46f0447e5f106c4ffa2a4 Author: Weongyo Jeong <weongyo.linux@gmail.com> Date: Tue Mar 15 10:57:44 2016 -0700 netfilter: nf_conntrack: Uses pr_fmt() for logging. Uses pr_fmt() macro for debugging messages of nf_conntrack module. Signed-off-by: Weongyo Jeong <weongyo.linux@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> net/netfilter/nf_conntrack_core.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) commit 1fe767a56c32730a947fc2bfcac5d14490bde6ff Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:22:54 2016 +0800 soc: rockchip: power-domain: allow domains only handling idle requests On some Rockchip SoC there exist child-domains only handling their idle state with the actual power-state handled by a (shared) parent- domain. So allow such types of domains. For them, we can determine their state (on/off) by checking the inverse idle-state instead. There exist one special case if both idle as well power handling were set as not present, but as the domain-data is defined in the code itself, we can expect the reasonable developer to define them in a correct way, without adding more checks. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) commit 6aa841c8097fee1b17b343719c45694e3166ca34 Author: Elaine Zhang <zhangqing@rock-chips.com> Date: Thu Mar 10 05:22:53 2016 +0800 soc: rockchip: power-domain: make idle handling optional Not all new socs need to handle idle states on domain state changes, so add the possibility to make them optional. Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/soc/rockchip/pm_domains.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) commit 5e3ca2b349b1e2c80b060b51bbf2af37448fad85 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Wed Mar 23 20:59:34 2016 -0300 regulator: Try to resolve regulators supplies on registration Commit 6261b06de565 ("regulator: Defer lookup of supply to regulator_get") moved the regulator supplies lookup logic from the regulators registration to the regulators get time. Unfortunately, that changed the behavior of the regulator core since now a parent supply with a child regulator marked as always-on, won't be enabled unless a client driver attempts to get the child regulator during boot. This patch tries to resolve the parent supply for the already registered regulators each time that a new regulator is registered. So the regulators that have child regulators marked as always on will be enabled regardless if a driver gets the child regulator or not. That was the behavior before the mentioned commit, since parent supplies were looked up at regulator registration time instead of during child get. Since regulator_resolve_supply() checks for rdev->supply, most of the times it will be a no-op. Errors aren't checked to keep the possible out of order dependencies which was the motivation for the mentioned commit. Also, the supply being available will be enforced on regulator get anyways in case the resolve fails on regulators registration. Fixes: 6261b06de565 ("regulator: Defer lookup of supply to regulator_get") Suggested-by: Mark Brown <broonie@kernel.org> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> Cc: <stable@vger.kernel.org> # 4.1+ drivers/regulator/core.c | 9 +++++++++ 1 file changed, 9 insertions(+) commit 8c3ad488fe0e4478b3b29b9501074c5fb1bfda0d Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Thu Mar 24 15:35:44 2016 +0200 spi: pxa2xx: Use dummy buffers provided by SPI core Dummy buffer is used for half duplex transfers that don't have TX or RX buffer set. Instead of own dummy buffer management here let the SPI core to handle it by setting the SPI_MASTER_MUST_RX and SPI_MASTER_MUST_TX flags. Then core makes sure both transfer buffers are set. Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pxa2xx-dma.c | 10 +--------- drivers/spi/spi-pxa2xx.c | 1 + drivers/spi/spi-pxa2xx.h | 1 - 3 files changed, 2 insertions(+), 10 deletions(-) commit 68335ec76e45fb3a1b796b26c3ea49ce1231d8fb Author: Jarkko Nikula <jarkko.nikula@linux.intel.com> Date: Thu Mar 24 15:35:43 2016 +0200 spi: pxa2xx: Remove rx_/tx_map_len members from struct driver_data spi-pxa2xx-dma.c DMA engine implementation stopped using PIO for unaligned trailing bytes in the commit 111e0a9dc71e ("spi/pxa2xx: Prevent DMA from transferring too many bytes"). This means there is no need to update tx/rx transfer buffer pointers after DMA completion. These buffer pointers will be set to new buffers when handling the next transfer. Because this buffer pointer update was only remaining use for rx_map_len and tx_map_len members in struct driver_data after removing the legacy PXA DMA implementation they can be removed now. Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pxa2xx-dma.c | 5 ----- drivers/spi/spi-pxa2xx.h | 2 -- 2 files changed, 7 deletions(-) commit 7d1f1bf699efc9b0f0e92c910dc667a4511943f5 Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Date: Thu Mar 24 15:35:42 2016 +0200 spi: pxa2xx: handle error of pxa2xx_spi_dma_prepare() If by some reason pxa2xx_spi_dma_prepare() fails we have not to ignore its error. In such case we abort the transfer and return the error to upper level. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> [Jarkko: Avoid leaking TX descriptors in case RX descriptor allocation fails. Noted by Robert Jarzmik <robert.jarzmik@free.fr>. Unmap also buffers in case of failure.] Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-pxa2xx-dma.c | 13 +++++++++++-- drivers/spi/spi-pxa2xx.c | 8 +++++++- 2 files changed, 18 insertions(+), 3 deletions(-) commit 6ee5c04407f59122774c8da26f3ee8d6db9cec9b Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Fri Mar 25 14:35:09 2016 -0700 regulator: qcom_spmi: Keep trying to add regulators if read fails On some designs, a handful of the regulators can't be read via SPMI transactions because they're "secure" and not intended to be touched by non-secure processors. This driver unconditionally attempts to read the id registers of all the regulators though, leading to probe failing and no regulators being registered. Let's ignore any errors from failing to read the registers and keep adding other regulators so that this driver can probe on such devices. Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/qcom_spmi-regulator.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 50314e55a140a0bc898d5f34b591e4e4ecedc75f Author: Stephen Boyd <stephen.boyd@linaro.org> Date: Fri Mar 25 14:35:08 2016 -0700 regulator: qcom_spmi: Add support for pm8994 Document the regulators available on pm8994 and add support for this PMIC to the SPMI PMIC regulator driver. Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> .../bindings/regulator/qcom,spmi-regulator.txt | 37 ++++++++++++++++ drivers/regulator/qcom_spmi-regulator.c | 51 ++++++++++++++++++++++ 2 files changed, 88 insertions(+) commit 32e5deac3627a508f43806788dafa933b51d5d46 Author: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Date: Sat Mar 26 10:28:15 2016 +0200 regulator: twl: Regulator mode should not depend on regulator enabled state When machine constraints are applied, regulator framework first sets initial mode (if any) and then enables the regulator if needed. The current code in twl4030reg_set_mode always checks if the regulator is enabled before applying the mode. That results in -EACCES error returned for "always-on" regulators which have "initial-mode" set in the board DTS. Fix that by removing the unneeded check. Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/twl-regulator.c | 8 -------- 1 file changed, 8 deletions(-) commit 2330b05c095bdeaaf1261c54cd2d4b9127496996 Author: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Date: Sat Mar 26 10:28:13 2016 +0200 regulator: twl: Make sure we have access to powerbus before trying to write to it According to the TRM, we need to enable i2c access to powerbus before writing to it. Also, a new write to powerbus should not be attempted if there is a pending transfer. The current code does not implement that functionality and while there are no known problems caused by that, it is better to follow what TRM says. Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/twl-regulator.c | 78 +++++++++++++++++++++++++++++++++++---- 1 file changed, 70 insertions(+), 8 deletions(-) commit 51fadb985786929af9377245042b412302d2c9a2 Author: Alison Schofield <amsfield22@gmail.com> Date: Sat Mar 26 12:50:24 2016 -0700 staging: iio: convert bare unsigned usage to unsigned int Use kernel preferred unsigned int declaration style. Patch created using: git ls-files drivers/staging/iio | \ xargs ./scripts/checkpatch.pl -f --fix-inplace --types=unspecified_int Hand edits restored columns in structure definitions. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/adc/ad7280a.c | 40 +++++++++++------------ drivers/staging/iio/adc/ad7280a.h | 8 ++--- drivers/staging/iio/adc/ad7606.h | 28 ++++++++-------- drivers/staging/iio/adc/ad7606_core.c | 6 ++-- drivers/staging/iio/adc/ad7780.c | 2 +- drivers/staging/iio/impedance-analyzer/ad5933.c | 14 ++++---- drivers/staging/iio/meter/ade7758_ring.c | 4 +-- drivers/staging/iio/resolver/ad2s1210.h | 8 ++--- drivers/staging/iio/trigger/iio-trig-bfin-timer.c | 12 +++---- 9 files changed, 61 insertions(+), 61 deletions(-) commit e6e45420f41fc613569e8bb6d15e0472dc0ea1ab Author: Linus Walleij <linus.walleij@linaro.org> Date: Thu Mar 24 14:18:03 2016 +0100 iio: st_sensors: simplify buffer address handling The driver goes to some length to dynamically allocate an array to hold the channel addresses. However no ST sensor has more than three channels (x, y, z at most). Instead of kmalloc():ing and kfree():in the address array, just use a fixed array of three elements. Cc: Giuseppe Barba <giuseppe.barba@st.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/common/st_sensors/st_sensors_buffer.c | 28 ++++++----------------- 1 file changed, 7 insertions(+), 21 deletions(-) commit 25c0e953eb56168c05fed88fbad00f76e105e2c8 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Sun Mar 27 16:09:09 2016 +0900 ALSA: firewire-tascam: add Kconfig entry for TASCAM FW-1804 I forgot it. Fixes: 3e78e1518e12('ALSA: firewire-tascam: add support for FW-1804') Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/Kconfig | 1 + 1 file changed, 1 insertion(+) commit 0655ac2f4089321766bb9af19586900ad6cef7bc Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Sun Mar 27 16:09:08 2016 +0900 ALSA: fireworks: move model quirk detection code to information parser Currently, model-specific quirks are detected out of information parser, however it's natural to detect it in the parser. This commit applies the idea. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/fireworks/fireworks.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) commit 329fec2f7f7ead9dcab0a08684c700a5c55f3884 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Sun Mar 27 16:09:07 2016 +0900 ALSA: oxfw: remove needless member from private structure In former commit, 'struct device_info' is obsoleted, whereas private structure still keeps a pointer to it. This commit remove the member. d6ce6bbd7d83('ALSA: oxfw: rename a structure so that it means backward compatibility to old drivers') Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/oxfw/oxfw.h | 1 - 1 file changed, 1 deletion(-) commit 093dd449782737b50f8e1ee1608720dfd46d8ed2 Author: Takashi Sakamoto <o-takashi@sakamocchi.jp> Date: Sun Mar 27 16:09:06 2016 +0900 ALSA: bebob: remove needless argument from local function The 'vendor_id' argument is not used in the local function. Let's remove it. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/firewire/bebob/bebob.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7ff652ffc06afc7f81839fb1780c57470ac09db6 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 14:50:24 2016 +0100 ALSA: hda - Enable i915 ELD notifier for Intel IronLake and Baytrail Since we have the fixed pin-port mapping for Intel IronLake (IbexPeak) and Baytrail (ValleyView) platforms in the code side, now it's time to add the support in the codec driver side. This patch simply enables the i915 ELD notifier for these in addition with the fix of the mapping from the port to NID in the callback. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) commit d745f5e7b8b2961f68b0b9093a0f914a8a83c2ae Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 14:41:58 2016 +0100 ALSA: hda - Add the pin / port mapping on Intel ILK and VLV Intel IronLake and ValleyView platforms have different HDMI widget pin and digital port mapping from other newer ones. The recent ones (HSW+) have NID 0x05 to 0x07 for port B to port D, while these chips have NID 0x04 to 0x06. For adapting this mapping, pass the codec object instead of the bus object to snd_hdac_sync_audio_rate() and snd_hdac_acomp_get_eld() so that they can check the codec ID and calculate the mapping properly. The changes in the HDMI codec driver side will follow in the later patch. Signed-off-by: Takashi Iwai <tiwai@suse.de> include/sound/hda_i915.h | 10 +++++----- sound/hda/hdac_i915.c | 45 ++++++++++++++++++++++++++++++++++----------- sound/pci/hda/patch_hdmi.c | 4 ++-- 3 files changed, 41 insertions(+), 18 deletions(-) commit e85015a3797f2665cc6f0339e6407adc00ac4245 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 13:56:19 2016 +0100 ALSA: hda - Use eld notifier for Intel SandyBridge and IvyBridge HDMI/DP Intel SandyBridge and IvyBridge (CougarPoint and PantherPoint platforms) have also the same digital port vs audio widget mapping (from port B = NID 0x05 to port D = NID 0x07) as Haswell & co. So, we can reuse the existing functions for HSW+ for these platforms without changing there, but just by re-adding the on-demand i915 binding in HDMI codec driver. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 41 +++++++++++++++++++++++++++++++++++++++-- 1 file changed, 39 insertions(+), 2 deletions(-) commit 4846a67eb5a1d7cac76e1b22f66e88a8cbbdff3f Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 12:56:46 2016 +0100 ALSA: hda - Introduce pin_cvt_fixup() ops to hdmi parser For reducing the splat of is_haswell_plus() or such macros, this patch introduces pin_cvt_fixup() ops to hdmi_spec. For HSW+ and VLV+ codecs, set this ops so that the driver can call the Intel-specific workarounds appropriately. A gratis bonus that we can remove the mux_id argument from hdmi_choose_cvt(), too, since the fixup function always refers the mux_idx from the given per_pin object. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 82 ++++++++++++++++++++++++++++------------------ 1 file changed, 50 insertions(+), 32 deletions(-) commit 2c1c9b86c6b22dc0cbac3f4ca2c8272c472dc463 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 12:42:06 2016 +0100 ALSA: hda - Override HDMI setup_stream ops for Intel HSW+ Instead of checking at each time with is_haswell_plus() macro, override the setup_stream ops itself for HSW+ chips. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) commit 44bb6d0c3f690e60670517859925417bd7c42a22 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 12:36:44 2016 +0100 ALSA: hda - Apply AMP fix in hdmi_setup_audio_infoframe() generically The need for reprogramming the AMP mute bit at each audio info frame setup isn't always specific to Intel chips. It's safer to set it generically for all codecs with the amp bit, as this verb execution itself isn't too much load. This eliminates one usage of is_haswell_plus() macro, after all. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit a686632fd9a857776798f3479e2b58b07d938076 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 21 12:18:33 2016 +0100 ALSA: hda - Split out Intel-specific codes from patch_generic_hdmi() We have too many Intel-specific codes in patch_hdmi_generic() despite its function name. And this makes it difficult to adjust per chipset, e.g. for allowing the audio notifier on an old chipset, one would need to add an explicit if() check. This patch attempts some code refactoring and cleanups in this regard; the Intel-specific codes are moved out of patch_generic_hdmi() into the new functions, patch_i915_hsw_hdmi() and patch_i915_byt_hdmi(), depending on the chipset. The other old Intel chipsets keep using patch_generic_hdmi() without Intel hacks. The existing patch_generic_hdmi() is also split to a few components so that they can be called from the Intel codec parsers. There are still many is_haswell*() and is_valleyview*() macro usages in the code. They will be cleaned up later. For the time being, only the entry are concerned. Along with this change, the i915_bound flag and the on-demand i915 component binding have been removed as a cleanup, since there is no user at this moment. This will be added back later once when Cougar Point and else start using the i915 eld notifier. Signed-off-by: Takashi Iwai <tiwai@suse.de> sound/pci/hda/patch_hdmi.c | 218 +++++++++++++++++++++++++++++---------------- 1 file changed, 139 insertions(+), 79 deletions(-) commit 5c5daf9188e24c38ad931b2e28253997e777f9c8 Merge: f55532a 6b94fb1 Author: Takashi Iwai <tiwai@suse.de> Date: Mon Mar 28 09:36:40 2016 +0200 Merge branch 'for-linus' into for-next commit 81cd8896a64cc34bd59f097fa619b11ab40ca7a6 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:33:04 2016 -0400 constify ima_d_path() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/integrity/ima/ima.h | 2 +- security/integrity/ima/ima_api.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 3b73b68c05db0b3c9b282c6e8e6eb71acc589a02 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:31:19 2016 -0400 constify security_sb_pivotroot() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 6 +++--- security/security.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) commit 77b286c0d26a5399912f5affd90ed73e2d8b42a5 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:28:43 2016 -0400 constify security_path_chroot() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 4 ++-- security/security.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) commit 3ccee46ab487d5b87d0621824efe2500b2857c58 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:27:45 2016 -0400 constify security_path_{link,rename} Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 6 +++--- include/linux/security.h | 12 ++++++------ security/apparmor/lsm.c | 6 +++--- security/security.c | 6 +++--- security/tomoyo/tomoyo.c | 6 +++--- 5 files changed, 18 insertions(+), 18 deletions(-) commit 8db0185659c33143915768bdd33fc2fb1b1cbb58 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:22:49 2016 -0400 apparmor: remove useless checks for NULL ->mnt Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/lsm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit d360775217070ff0f4291e47d3f568f0fe0b7374 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:21:09 2016 -0400 constify security_path_{mkdir,mknod,symlink} ... as well as unix_mknod() and may_o_create() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/namei.c | 2 +- include/linux/lsm_hooks.h | 6 +++--- include/linux/security.h | 12 ++++++------ net/unix/af_unix.c | 2 +- security/apparmor/lsm.c | 6 +++--- security/security.c | 6 +++--- security/tomoyo/tomoyo.c | 6 +++--- 7 files changed, 20 insertions(+), 20 deletions(-) commit 989f74e0500a1e136d369bb619adc22786ea5e68 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:13:39 2016 -0400 constify security_path_{unlink,rmdir} Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 4 ++-- include/linux/security.h | 8 ++++---- security/apparmor/lsm.c | 4 ++-- security/security.c | 4 ++-- security/tomoyo/tomoyo.c | 4 ++-- 5 files changed, 12 insertions(+), 12 deletions(-) commit d6b49f7ad2f38b5c3af27ac1a6f475b1ec13ea6e Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:10:04 2016 -0400 apparmor: constify common_perm_...() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/lsm.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3539aaf670cdd68a37314cd5db400c0c77287c88 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:07:03 2016 -0400 apparmor: constify aa_path_link() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/file.c | 2 +- security/apparmor/include/file.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 741aca71d61c3485d1e9db3bcea00d4509cf2301 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 15:04:36 2016 -0400 apparmor: new helper - common_path_perm() was open-coded in several places... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/lsm.c | 47 ++++++++++++----------------------------------- 1 file changed, 12 insertions(+), 35 deletions(-) commit be01f9f28e66fa846f02196eb047c6bc445642db Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:56:23 2016 -0400 constify chmod_common/security_path_chmod Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/open.c | 2 +- include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 4 ++-- security/apparmor/lsm.c | 2 +- security/security.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) commit 8a04c43b8741ebb40508d160cf87ca74b70941af Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:52:53 2016 -0400 constify security_sb_mount() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 4 ++-- security/security.c | 2 +- security/selinux/hooks.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) commit 7fd25dac9ad3970bede16f2834daf9f9d779d1b0 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:44:41 2016 -0400 constify chown_common/security_path_chown Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/open.c | 2 +- include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 4 ++-- security/apparmor/lsm.c | 2 +- security/security.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) commit e6641eddf0e7f0227493e91a1d91546f6bd73525 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:41:28 2016 -0400 tomoyo: constify assorted struct path * Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/tomoyo/common.h | 12 ++++++------ security/tomoyo/file.c | 10 +++++----- security/tomoyo/mount.c | 4 ++-- 3 files changed, 13 insertions(+), 13 deletions(-) commit 928e1ebfb576f6c0480ac852becfc142b248242c Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:24:49 2016 -0400 apparmor_path_truncate(): path->mnt is never NULL Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/lsm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7df818b2370a9aab5fc58a85b70b8af3d835affa Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:24:09 2016 -0400 constify vfs_truncate() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/open.c | 2 +- include/linux/fs.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit 81f4c50607b423a59f8a1b03e1e8fc409a1dcd22 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:22:01 2016 -0400 constify security_path_truncate() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> include/linux/lsm_hooks.h | 2 +- include/linux/security.h | 4 ++-- security/apparmor/lsm.c | 2 +- security/security.c | 2 +- security/tomoyo/tomoyo.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) commit 0c93b7d85d40b690f04786ea0f18798b73182e4f Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 12:06:51 2016 -0400 bpf: reject invalid names right in ->lookup() ... and other methods won't see them at all Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> kernel/bpf/inode.c | 37 ++++++++----------------------------- 1 file changed, 8 insertions(+), 29 deletions(-) commit 798434bda36e357af9ccaf68a7ba1129658c8332 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Mar 24 20:38:43 2016 -0400 __d_alloc(): treat NULL name as QSTR("/", 1) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> fs/dcache.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) commit 322ea0bbf3003df17b6253f76e572c37d79a6810 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Mar 24 14:47:18 2016 -0400 mtd: switch ubi_open_volume_path() to vfs_stat() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> drivers/mtd/ubi/kapi.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) commit 87f15d4add758fb7fc76655721af94be57a4c17d Author: Al Viro <viro@zeniv.linux.org.uk> Date: Thu Mar 24 14:43:24 2016 -0400 mtd: switch open_mtd_by_chdev() to use of vfs_stat() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> drivers/mtd/ubi/build.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) commit 2c7661ff419580f5c06ea409e31407e0ff52cb95 Author: Al Viro <viro@zeniv.linux.org.uk> Date: Fri Mar 25 14:18:14 2016 -0400 [apparmor] constify struct path * in a bunch of helpers Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> security/apparmor/file.c | 2 +- security/apparmor/include/file.h | 2 +- security/apparmor/include/path.h | 2 +- security/apparmor/lsm.c | 2 +- security/apparmor/path.c | 8 ++++---- 5 files changed, 8 insertions(+), 8 deletions(-) commit 352486b164ad41f2536f77d568ada7d729d080c2 Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Mon Feb 15 13:57:48 2016 +0100 ARM: shmobile: defconfig: enable I2C demultiplexer and slave eeprom The Lager board shall be the reference platform for the runtime I2C IP core switcher and for I2C slave support. Enable the needed drivers for this. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/configs/shmobile_defconfig | 3 +++ 1 file changed, 3 insertions(+) commit 41feae79f2621d9fcea1437d4a2f29dc731fdbb0 Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 3 10:39:58 2016 +0900 bus: simple-pm-bus: Use ARCH_RENESAS Make use of ARCH_RENESAS in place of ARCH_SHMOBILE. This is part of an ongoing process to migrate from ARCH_SHMOBILE to ARCH_RENESAS the motivation for which being that RENESAS seems to be a more appropriate name than SHMOBILE for the majority of Renesas ARM based SoCs. Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> drivers/bus/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 651435d68253b0a5059175e2f113528080e5928e Author: Wolfram Sang <wsa+renesas@sang-engineering.com> Date: Wed Feb 24 11:01:31 2016 +0100 ARM: multi_v7_defconfig: enable I2C demultiplexer and slave eeprom The Renesas Lager board shall be a reference platform for the runtime I2C IP core switcher and for I2C slave support. Enable the needed drivers for this. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm/configs/multi_v7_defconfig | 2 ++ 1 file changed, 2 insertions(+) commit 000025cfbb9e8bafd0a1fa84d8d83526d24bde42 Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 23 10:06:43 2016 +0900 ARM: dts: sh73a0: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. The clock-output-names property is left in place for the zb_clk which is thus treated as a special case as the MSTP clock driver (clk-mstp.c) explicitly looks for a clock with node name zb_clk for the r8a73a4 and sh73a0 SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/sh73a0.dtsi | 87 +++++++++++++++---------------------------- 1 file changed, 29 insertions(+), 58 deletions(-) commit 57c75d1ed6890b8c57fce5d0c557a6b486c4d898 Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 23 10:06:42 2016 +0900 ARM: dts: r8a73a4: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. The clock-output-names property is left in place for the zb_clk which is thus treated as a special case as the MSTP clock driver (clk-mstp.c) explicitly looks for a clock with node name zb_clk for the r8a73a4 and sh73a0 SoCs. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a73a4.dtsi | 75 ++++++++++++++---------------------------- 1 file changed, 25 insertions(+), 50 deletions(-) commit a5bad2c7c9ee0f5e188b97baeb383753fad53c86 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:57 2016 +0900 ARM: dts: lager: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7790-lager.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 203f0ef865303412a9d03a88a2f845db682ac628 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:57 2016 +0900 ARM: dts: porter: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791-porter.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 62c7e9da598611827f09984386fa1438ccc46f87 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:57 2016 +0900 ARM: dts: koelsch: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791-koelsch.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 45e4f51311f3d4551326bfa43547f86b00af0a94 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:57 2016 +0900 ARM: dts: gose: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7793-gose.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 337f6bef6dd8dd9d2621980e2d34150d2014909c Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:57 2016 +0900 ARM: dts: r8a7794: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7794.dtsi | 66 ++++++++++++++---------------------------- 1 file changed, 22 insertions(+), 44 deletions(-) commit 3b81c0ce13c53445b1e38fa1ff86025e5b8a9199 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:17:09 2016 +0900 ARM: dts: r8a7793: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7793.dtsi | 45 +++++++++++++----------------------------- 1 file changed, 14 insertions(+), 31 deletions(-) commit f617604fe5d74b9c8d3333bad2e4959abe4594a4 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:16:23 2016 +0900 ARM: dts: r8a7791: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791.dtsi | 79 +++++++++++++----------------------------- 1 file changed, 25 insertions(+), 54 deletions(-) commit 3f6dba702c57908c5f66601ced6ef9f131759611 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:15:34 2016 +0900 ARM: dts: r8a7779: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7779.dtsi | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit 452fc89994c2a81ade92096088b94ecbfef436a8 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:15:11 2016 +0900 ARM: dts: r8a7778: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7778.dtsi | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) commit 2dca78980372f154a2181e6044db71be9da626e9 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:14:31 2016 +0900 ARM: dts: r8a7740: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7740.dtsi | 57 ++++++++++++++---------------------------- 1 file changed, 19 insertions(+), 38 deletions(-) commit 21f189705929b9d27a44f0ae3d2ddd390c545670 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 08:10:44 2016 +0900 ARM: dts: r7s72100: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary update the node names. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r7s72100.dtsi | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) commit b19dd47b27d2bd719d304f27c0a4fcd3f51632dd Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 16 09:21:13 2016 +0900 ARM: dts: r8a7790: Remove unnecessary clock-output-names properties * Fixed rate and fixed factor clocks do not require an clock-output-names property. * Since 07705583e920fef6 ("clk: shmobile: div6: Make clock-output-names optional") Renesas div6 clocks do not require a clock-output-names property. In the above cases there is only one clock output and its name is taken from that of the clock node. Accordingly, remove the unnecessary clock-output-names properties and as necessary the nodes. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7790.dtsi | 88 ++++++++++++++---------------------------- 1 file changed, 28 insertions(+), 60 deletions(-) commit 20ccdd90ab22808e582d81cdfac09e3b804e7b20 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:57:10 2016 +0900 ARM: dts: kzm9d: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the kzm9d device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/emev2-kzm9d.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit ffff86d16ed25655643f75fdb83eb70f0a8496af Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:57:10 2016 +0900 ARM: dts: kzm9g: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the kzm9g device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/sh73a0-kzm9g.dts | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) commit 4386ed21e5c1944f9b666f405796499526c5e59b Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:57:28 2016 +0900 ARM: dts: silk: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the silk device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7794-silk.dts | 44 +++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 22 deletions(-) commit be7359dd9813e44bad827607048dd16298076bb8 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:56:21 2016 +0900 ARM: dts: alt: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the alt device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7794-alt.dts | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) commit 2e207c1cd0f883a7d89b5241295c167e45f994b2 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:55:47 2016 +0900 ARM: dts: gose: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the gose device tree to use the generic Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7793-gose.dts | 40 +++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit b2abb296ad8cb576ea90e813842fa204bc21aebb Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:55:31 2016 +0900 ARM: dts: porter: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the porter device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791-porter.dts | 60 ++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 30 deletions(-) commit fec7b9f8952f396d88228677f44d52c7e20a6be8 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:55:10 2016 +0900 ARM: dts: koelsch: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the koelsch device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7791-koelsch.dts | 68 +++++++++++++++++------------------ 1 file changed, 34 insertions(+), 34 deletions(-) commit 8870d1393e0685d0bb1ae879fb1db3ffcf9a1020 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:54:24 2016 +0900 ARM: dts: marzen: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the marzen device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7779-marzen.dts | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) commit ddf72563890a3361f7da82510ef8baca37a13830 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:53:54 2016 +0900 ARM: dts: bockw: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the bockw device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7778-bockw.dts | 40 ++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 20 deletions(-) commit 1ba1e26ededf070da2b1af117f912d2d9f05accf Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:53:17 2016 +0900 ARM: dts: armadillo800eva: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the armadillo800eva device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a7740-armadillo800eva.dts | 34 +++++++++++++-------------- 1 file changed, 17 insertions(+), 17 deletions(-) commit a32f5cff122b41f01a4ed18a9007871344b651c3 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:52:11 2016 +0900 ARM: dts: ape6evm: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the ape6evm device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm/boot/dts/r8a73a4-ape6evm.dts | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 2ffc224f3ab047f16d2dc73b90a6fe148c03f946 Author: Simon Horman <horms+renesas@verge.net.au> Date: Wed Mar 16 10:03:09 2016 +0900 ARM: dts: lager: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the lager device tree to use the generic rather than renesas-specific properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> arch/arm/boot/dts/r8a7790-lager.dts | 92 ++++++++++++++++++------------------- 1 file changed, 46 insertions(+), 46 deletions(-) commit 81ae0ac31bb90baef10850fdfdc2a9f72f36aa6f Author: Simon Horman <horms+renesas@verge.net.au> Date: Thu Mar 24 11:01:09 2016 +0900 arm64: dts: r8a7795: Use USB3.0 fallback compatibility string Use recently added fallback compatibility string in r8a7795 device tree. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 308b7e4ba62e2ab60efcaf426cc219d591f0cd28 Author: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Date: Mon Feb 29 14:22:39 2016 +0000 arm64: dts: r8a7795: Add CAN support Adds CAN controller nodes for r8a7795. Note: CAN channel register base address mentioned in R-Car Gen3 Hardware User Manual v0.5E is incorrect. The corrected base addresses are: CAN Channel 0 - 0xe6c30000 CAN Channel 1 - 0xe6c38000 Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) commit 7811482f0e2521249bb6cf76dffd863a3dda8e07 Author: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Date: Fri Feb 26 16:38:47 2016 +0000 arm64: dts: r8a7795: Add CAN external clock support Adds external CAN clock node for r8a7795. This clock can be used as fCAN clock of CAN and CAN FD controller. Signed-off-by: Ramesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Simon Horman <horms+renesas@verge.net.au> arch/arm64/boot/dts/renesas/r8a7795.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) commit fa3d2aede8bf9dd69e9309230169b5ec1cc234e4 Author: Simon Horman <horms+renesas@verge.net.au> Date: Fri Mar 18 07:57:10 2016 +0900 arm64: dts: salvator-x: use generic pinctrl properties Since 16ccaf5bb5a5 ("pinctrl: sh-pfc: Accept standard function, pins and groups properties") renesas pfc drivers accept generic "function", "pins" and "groups" properties. This patch updates the kzm9g device tree to use the generic properties. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 46 +++++++++++----------- 1 file changed, 23 insertions(+), 23 deletions(-) commit 4b8ccef22fb547007ac38c4e5a28a773adee1e6e Author: Priit Laes <plaes@plaes.org> Date: Thu Mar 24 21:52:17 2016 +0200 ARM: sun7i: dt: Enable dram gate 5 (tve0 clock) for simplefb TV output Seems like dram_gate 5 was forgotten when DRAM gating driver was added. Add it. Cc: stable@vger.kernel.org Fixes: 0b4bf5a5200b (ARM: dts: sun7i: Add DRAM gates) Signed-off-by: Priit Laes <plaes@plaes.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20.dtsi | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit bec38aaafd9ec1463dd3857f02bc029707e4213d Author: Priit Laes <plaes@plaes.org> Date: Thu Mar 24 21:52:16 2016 +0200 ARM: sun4i: dt: Enable dram gate 5 (tve0 clock) for simplefb TV output Seems like dram_gate 5 was forgotten when DRAM gate driver was added. Enable it. Cc: stable@vger.kernel.org Fixes: 82f8582feef4 (ARM: dts: sun4i: Add DRAM gates) Signed-off-by: Priit Laes <plaes@plaes.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 59dbdd844a8b8e2d6793d3ee491da796752b97d5 Author: JM Friedt <jmfriedt@femto-st.fr> Date: Thu Mar 24 14:18:53 2016 +0100 ARM: dts: sun5i-a13-olinuxino-micro: enable USB DRC Enable the OTG controller on the Olinuxino A13-micro. Signed-off-by: Jean-Michel Friedt <jmfriedt@femto-st.fr> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-a13-olinuxino-micro.dts | 41 +++++++++++++++++++++++++ 1 file changed, 41 insertions(+) commit 0c1747a24855f6ce9668283be0b6839f4c0ab4cf Author: Hans de Goede <hdegoede@redhat.com> Date: Wed Mar 23 23:14:16 2016 +0100 ARM: dts: sun8i: Base Orange Pi Plus dts on the Orange Pi 2 dts The Orange Pi Plus really is an Orange Pi 2 extended with: 1) A sata <-> usb bridge connected to ehci3 2) An eMMC on mmc2 3) An external gigabit ethernet phy instead of the integrated 100Mbit phy This commit changes the dts to reflect this by making it include the Orange Pi 2 dts and then adding the extra bits. Note that the difference in ethernet phy is not taken into account because we do not have an ethernet driver for the H3 yet. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 136 +-------------------------- 1 file changed, 2 insertions(+), 134 deletions(-) commit cd544a8466506385dfa943f0f8bab89f82cf0bf0 Author: Hans de Goede <hdegoede@redhat.com> Date: Tue Mar 22 21:53:22 2016 +0100 ARM: dts: sun8i: Orangepi plus gpio keys fixes and improvements Fix the following issues with the gpio_keys node: 1) Use of undocumented input-name property 2) Use of a unit-address on the sw2 node 3) Having "PL03" in the pinctrl node which does not exist, this should be "PL3" And add support for the sw2 button on the board. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) commit c4392ef6c52506823e05d98b1a3ff73c85fed491 Author: Hans de Goede <hdegoede@redhat.com> Date: Wed Mar 23 11:17:05 2016 +0100 ARM: dts: sun8i: Add dts for Orange Pi 2 SBC The Orange Pi 2 is a SBC based on the Allwinner H3 SoC with a uSD slot, 4 USB ports connected via a USB-2 hub, a 10/100M ethernet port using the SoC's integrated PHY, Wifi via a RTL8189ETV sdio wifi chip, USB OTG, HDMI, a TRRS headphone jack for stereo out and composite out, a microphone, an IR receiver, a CSI connector, 2 LEDs, a 3 pin UART header and a 40-pin GPIO header. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 186 ++++++++++++++++++++++++++++++ 2 files changed, 187 insertions(+) commit 7b4fad5f22d54639c17d206b94dd1b245b22c494 Author: Chen-Yu Tsai <wens@csie.org> Date: Tue Mar 22 22:37:29 2016 +0100 ARM: dts: sun8i: Add Orange Pi PC support The Orange Pi PC is an SBC based on the Allwinner H3 SoC with a uSD slot, 3 USB ports directly from the SoC, a 10/100M ethernet port using the SoC's integrated PHY, USB OTG, HDMI, a TRRS headphone jack for stereo out and composite out, a microphone, an IR receiver, a CSI connector, 2 LEDs, a 3 pin UART header, and a 40-pin GPIO header. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 167 +++++++++++++++++++++++++++++ 2 files changed, 168 insertions(+) commit 1813ac1abdc7360839c914a146a8ce5a25834f6c Author: Hans de Goede <hdegoede@redhat.com> Date: Tue Mar 22 21:53:21 2016 +0100 ARM: dts: sun8i: Fix pio nodes Orangepi Plus dts Fix sun8i-h3-orangepi-plus.dts: 1) Having 2 pio nodes, by merging these into one 2) Having the pio and r_pio nodes before the mmc nodes, while they should be sorted by alphabet Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 80 ++++++++++++++-------------- 1 file changed, 39 insertions(+), 41 deletions(-) commit be0f167a85765e9f559785745d85364022b8395c Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:06 2016 +0100 ARM: dts: sun7i: Add SPDIF to the Itead Ibox Enable the S/PDIF transmitter that is present on the Itead Ibox. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20-itead-ibox.dts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 8bdc4a0d7bd292c9fd09274431b0d6466faa7e8f Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:05 2016 +0100 ARM: dts: sun4i: Add SPDIF to the Mele A1000 Enable the S/PDIF transmitter that is present on the A1000. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10-a1000.dts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit a34d6ce5eab955aa75232c151837e6e33cc8d5b6 Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:04 2016 +0100 ARM: dts: sun7i: Add the SPDIF block to the A20 Add the SPDIF transceiver controller block to the A20 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 166db83e0c127969f3e7acb0c9460251b107dc53 Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:03 2016 +0100 ARM: dts: sun4i: Add the SPDIF block to the A10 Add the SPDIF transceiver controller block to the A10 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) commit 90b7a48935421d4605a181ee49de03224b93c205 Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:02 2016 +0100 ARM: dts: sun7i: Add the SPDIF clk to the A20 Add the SPDIF clock to the A20 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit 1010cd549974dcee5ee172bd878f989c521c409f Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:01 2016 +0100 ARM: dts: sun4i: Add the SPDIF clk to the A10 Add the SPDIF clock to the A10 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10.dtsi | 11 +++++++++++ 1 file changed, 11 insertions(+) commit bdd08a84beafd21f3003af2b9e9c6496e701feef Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:01:00 2016 +0100 ARM: dts: sun7i: Add SPDIF TX pin to the A20 Add the SPDIF TX pin to the A20 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun7i-a20.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 79f969f08afe569d0705e509713bd2ce1f1062c4 Author: Marcus Cooper <codekipper@gmail.com> Date: Mon Mar 21 21:00:59 2016 +0100 ARM: dts: sun4i: Add SPDIF TX pin to the A10 Add the SPDIF TX pin to the A10 dtsi. Signed-off-by: Marcus Cooper <codekipper@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun4i-a10.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) commit 1bfbcfd1475886ef0f49ef99850b730873843124 Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 20 17:00:36 2016 +0100 ARM: dts: sun8i: Add eMMC dt node on Orangepi Plus boards The Orangepi Plus has a 16GB eMMC, the vcc, the lack of pull-ups and the use of the hw-reset pin have all been verified with the board schematic. With this dts node for mmc2, the eMMC runs at the following ios settings: clock: 52000000 Hz vdd: 21 (3.3 ~ 3.4 V) bus mode: 2 (push-pull) chip select: 0 (don't care) power mode: 2 (on) bus width: 3 (8 bits) timing spec: 8 (mmc DDR52) signal voltage: 0 (3.30 V) driver type: 0 (driver type B) Note the mmcblk1boot0/boot1 partitions are unused as the BROM will load the SPL from 8k from the start of the main blockdev, just as with a regular sdcard in mmc0. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) commit 4bf89c1dc692ad58d774c88dcf8f7946759ab04d Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 20 17:00:35 2016 +0100 ARM: dts: sun8i: Add wifi dt node on Orangepi Plus boards The Orangepi Plus and Orangepi Plus 2 have a realtek rtl8189etv sdio wifi chip. This commit adds a device-tree node to power it up, so that the mmc subsys can scan it, and enables the mmc controller which is connected to it. Note that this just makes the wifi controller show up as a sdio device. In order for it to work a compatible sdio driver is necessary, an out of tree driver is available here: https://github.com/jwrdegoede/rtl8189ES_linux/ Binding the driver is not done through device tree, but through sdio vendor- and device-id, so it can safely be enabled in devicetree without having a driver upstream yet. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 99f9483ab475f735195f40f6cff46ba96cd89fc7 Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 20 17:00:33 2016 +0100 ARM: dts: sun8i: Enable IR receiver on Orangepi Plus boards Enable the ir receiver found on the orangepi plus board. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 6 ++++++ 1 file changed, 6 insertions(+) commit c2da9e05afa775633c38307c2d1de5b785227ea2 Author: Jens Kuske <jenskuske@gmail.com> Date: Sun Mar 20 17:00:32 2016 +0100 ARM: dts: sun8i: Enable USB host controllers on Orangepi Plus boards Enable the 2 USB host controllers used on the Orange Pi Plus and add the necessary regulators. Signed-off-by: Reinder de Haan <patchesrdh@mveas.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Jens Kuske <jenskuske@gmail.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 44 ++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) commit 4cf9654eb568ac96817693d5f629100becbfa650 Author: Reinder de Haan <patchesrdh@mveas.com> Date: Sun Mar 20 17:00:31 2016 +0100 ARM: dts: sun8i: Add usbphy and usb host controller nodes Add nodes describing the H3's usbphy and usb host controller nodes. Signed-off-by: Reinder de Haan <patchesrdh@mveas.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3.dtsi | 101 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) commit bc9aa43fa94b25b2cf31c5efd02e8b2d2322cdb3 Author: Reinder de Haan <patchesrdh@mveas.com> Date: Sun Mar 20 17:00:30 2016 +0100 ARM: dts: sun8i: Add support for H3 usb clocks Add a node describing the usb-clks found on the H3. Signed-off-by: Reinder de Haan <patchesrdh@mveas.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3.dtsi | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit 9461faf20fdf037abc9c755cc5cc01a1fb56c7e1 Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 20 17:00:29 2016 +0100 ARM: dts: sun8i: Add mmc2_8bit_pins to sun8i-h3.dtsi Add a pinctrl node for mmc2 in 8 bits mode on H3 SoCs. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-h3.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) commit 80410d49f821447ee9955eb0417f295648158f3b Author: Hans de Goede <hdegoede@redhat.com> Date: Sat Mar 19 08:53:52 2016 +0100 ARM: dts: sun4i: Add dts file for Dserve DSRV9703C tablet The Dserve DSRV9703C is a 9.7" A10 tablet with a 1024x768 ips LCD, 1G RAM, 4GB flash, a Focaltech FT5406EE8 touchscreen and rtl8188ctv wifi. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun4i-a10-dserve-dsrv9703c.dts | 281 +++++++++++++++++++++++ 2 files changed, 282 insertions(+) commit 3dc2fdadf9d9183ada98c629abcf3d0807e42e54 Author: Hans de Goede <hdegoede@redhat.com> Date: Mon Mar 14 17:32:25 2016 +0100 ARM: dts: sun8i: Add dts file for the Polaroid MID2809PXE4 tablet The Polaroid MID2809PXE4 is a 9" tablet which is clearly marked Polaroid MID2809PXE4 on the back. It features a 9" 16:9 800x480 LCD, A23 Soc, 1GB RAM, 8GB NAND, gsl3670 touchscreen and esp8089 wifi. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + .../boot/dts/sun8i-a23-polaroid-mid2809pxe04.dts | 243 +++++++++++++++++++++ 2 files changed, 244 insertions(+) commit cbed866e57bad958ccbf8ba2b13c987bd1167de3 Author: Hans de Goede <hdegoede@redhat.com> Date: Mon Mar 14 17:32:24 2016 +0100 ARM: dts: sun8i: Fix regulator for mmc0 for sun8i-a23-gt90h-v4 Address the FIXME comment in sun8i-a23-gt90h-v4.dts now that we've proper regulator support. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-a23-gt90h-v4.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 388bc9a70fddef3102992d70d45e57e5b3beb496 Author: Hans de Goede <hdegoede@redhat.com> Date: Mon Mar 14 17:32:23 2016 +0100 ARM: dts: sun8i: Fix wrong Quad core / a33 compat for sun8i-a23-gt90h-v4 As the dts file name already implies sun8i-a23-gt90h-v4.dts is for an a23 equipped tablet. I don't know how the "Quad Core" or a33 comaptible got in there, likely a copy and paste error. Regardless this commit fixes this, note this is almost purely a cosmetical fix, for all things that matter at the machine compatible level the a23 and a33 are compatible. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-a23-gt90h-v4.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit f7eda3d52b6215cb08535934eeba7b561076e09b Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 13 08:39:37 2016 +0100 ARM: dts: sun8i: Add backlight / pwm nodes to sun8i-a23-gt90h-v4 Add nodes for the backlight / pwm found on a23-gt90h-v4 tablets. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-a23-gt90h-v4.dts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit a1162a917da256e752c2842b2f7950f98d8fab3f Author: Hans de Goede <hdegoede@redhat.com> Date: Sun Mar 13 08:39:36 2016 +0100 ARM: dts: sun8i: Add pmic nodes to sun8i-a23-gt90h-v4 Add nodes for the axp223 pmic and its regulators as found on a23-gt90h-v4 tablets. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun8i-a23-gt90h-v4.dts | 89 ++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) commit aab42cde173acb1c7fe3f53706bc720d1a41681b Author: Hans de Goede <hdegoede@redhat.com> Date: Wed Mar 9 22:50:30 2016 +0100 ARM: dts: sun6i: Add dts for colorfly e708 q1 tablet The colorfly e708 q1 is a 7" tablet which is clearly marked as colorfly e708 q1 on the back. It features a 9:16 800x1280 IPS LCD, A31s SoC, 1GB RAM, 8G NAND, ilitek 2139qt004 touchscreen on i2c-1 addr 0x41, stk8313 accelerometer on i2c-2 addr 0x22 and a rtl8188etv wifi chip. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun6i-a31s-colorfly-e708-q1.dts | 208 ++++++++++++++++++++++ 2 files changed, 209 insertions(+) commit daac65ce575d906af7b7e4e2f914a65890696c57 Author: Hans de Goede <hdegoede@redhat.com> Date: Thu Mar 10 22:38:04 2016 +0100 ARM: dts: sun5i: Add dts for Difrence DIT4350 tablet The Difrnce dit4350 tablet is a tiny tablet with a 4.3" 16:9 480x272 LCD, A13 SoC, 512M RAM, 4G NAND, solomon systech ssd2532qn6 touchscreen at i2c1 address 0x48, Memsic MXC622X accelerometer at i2c1 address 0x15 and rtl8188etv wifi. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/sun5i-a13-difrnce-dit4350.dts | 226 ++++++++++++++++++++++++ 2 files changed, 227 insertions(+) commit 163172c08af685667199c293b8dc66705eb7430c Author: Hans de Goede <hdegoede@redhat.com> Date: Thu Mar 10 22:38:03 2016 +0100 ARM: dts: sun5i-a13-empire-electronix-d709: Remove mmc2 node The empire-electronix-d709 does not have an emmc, it uses nand, the mmc2 node in the dts comes from a copy and paste error from the inet98fv2 dts, remove it. While at it also do s/inet98fv2/d709/ to fix some other copy/paste leftovers. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> .../arm/boot/dts/sun5i-a13-empire-electronix-d709.dts | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) commit cb53c7fc2045503cb7be0b225babd529df4d8cd3 Author: Hans de Goede <hdegoede@redhat.com> Date: Thu Mar 10 22:38:02 2016 +0100 ARM: dts: sun5i-a13-inet98v-rev2: Remove mmc2 node The sun5i-a13-inet98v-rev2 does not have an emmc, it uses nand, the mmc2 node in the dts comes from a copy and paste error from the utoo-p66 dts, remove it. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> arch/arm/boot/dts/sun5i-a13-inet-98v-rev2.dts | 15 --------------- 1 file changed, 15 deletions(-) commit 1d003eb0805ac5b549e76202a1e95da33f62cb9a Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Sun Mar 13 12:13:22 2016 +0800 clk: rockchip: release io resource when failing to init clk We should call iounmap to relase reg_base since it's not going to be used any more if failing to init clk. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-rk3036.c | 1 + drivers/clk/rockchip/clk-rk3188.c | 1 + drivers/clk/rockchip/clk-rk3228.c | 1 + drivers/clk/rockchip/clk-rk3288.c | 1 + drivers/clk/rockchip/clk-rk3368.c | 1 + 5 files changed, 5 insertions(+) commit ff1ae209617cb31a5297bd103709d6b9e2db77d2 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Sun Mar 13 00:25:53 2016 +0800 clk: rockchip: remove redundant checking of device_node rockchip_clk_of_add_provider is used by sub-clk driver which already call of_iomap before calling it. If device_node does not exist, of_iomap returns NULL which will fail to init the sub-clk driver. So really it's redundant. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) commit 2af2544d60f007277a98f66391a521ec377a6a67 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Sun Mar 13 00:25:14 2016 +0800 clk: rockchip: fix warning reported by kernel-doc ./scripts/kernel-doc -man -v drivers/clk/rockchip/clk.h > /dev/null drivers/clk/rockchip/clk.h:133: warning: missing initial short description on line: * struct rockchip_clk_provider: information about clock provider drivers/clk/rockchip/clk.h:133: info: Scanning doc for struct drivers/clk/rockchip/clk.h:164: warning: missing initial short description on line: * struct rockchip_pll_clock: information about pll clock drivers/clk/rockchip/clk.h:164: info: Scanning doc for struct drivers/clk/rockchip/clk.h:194: warning: No description found for parameter 'parent_names' drivers/clk/rockchip/clk.h:194: warning: No description found for parameter 'num_parents' drivers/clk/rockchip/clk.h:194: warning: Excess struct/union/enum/typedef member 'parent_name' description in 'rockchip_pll_clock' drivers/clk/rockchip/clk.h:235: warning: missing initial short description on line: * struct rockchip_cpuclk_reg_data: describes register offsets and masks of the cpuclock Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) commit cb3abdd628abe8583c81b07d5bb8b6d1dbd12227 Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Sun Mar 13 00:25:00 2016 +0800 clk: rockchip: remove mux_core_reg from rockchip_cpuclk_reg_data mux_core_reg isn't been used anywhere, let's remove it. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.h | 1 - 1 file changed, 1 deletion(-) commit b40baccd236a9a91fbb077efb8dadb41fdfb55ab Author: Xing Zheng <zhengxing@rock-chips.com> Date: Thu Mar 10 11:47:01 2016 +0800 clk: rockchip: add new pll-type for rk3399 and similar socs The rk3399's pll and clock are similar with rk3036's, it different with base on the rk3066(rk3188, rk3288, rk3368 use it), there are different adjust foctors and control registers, so these should be independent and separate from the series of rk3066s. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-pll.c | 271 ++++++++++++++++++++++++++++++++++++++++- drivers/clk/rockchip/clk.h | 3 +- 2 files changed, 272 insertions(+), 2 deletions(-) commit ef1d9feeccc094f59b72bb11fe14ec886eb574d3 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Mar 9 10:37:04 2016 +0800 clk: rockchip: Add support for multiple clock providers There are need to support Multi-CRUs probability in future, but it is not supported on the current Rockchip Clock Framework. Therefore, this patch add support a provider as the parameter handler when we call the clock register functions for per CRU. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-pll.c | 30 ++++---- drivers/clk/rockchip/clk-rk3036.c | 17 +++-- drivers/clk/rockchip/clk-rk3188.c | 44 ++++++++---- drivers/clk/rockchip/clk-rk3228.c | 17 +++-- drivers/clk/rockchip/clk-rk3288.c | 19 +++-- drivers/clk/rockchip/clk-rk3368.c | 21 ++++-- drivers/clk/rockchip/clk.c | 148 +++++++++++++++++++++++--------------- drivers/clk/rockchip/clk.h | 51 +++++++++---- 8 files changed, 229 insertions(+), 118 deletions(-) commit 268aebaa2410152bf91ea1ede6b284ff8138822d Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Mar 9 10:37:03 2016 +0800 clk: rockchip: allow varying mux parameters for cpuclk pll-sources Thers are only two parent PLLs that APLL and GPLL for core on the previous SoCs (RK3066/RK3188/RK3288/RK3368). Hence, we set fixed GPLL as alternate parent when core is switching freq. Since RK3399 big.LITTLE architecture, we need to select and adapt more PLLs (ALPLL/ABPLL/DPLL/GPLL) sources. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk-cpu.c | 29 ++++++++++++++++++----------- drivers/clk/rockchip/clk-rk3036.c | 3 +++ drivers/clk/rockchip/clk-rk3188.c | 6 ++++++ drivers/clk/rockchip/clk-rk3228.c | 3 +++ drivers/clk/rockchip/clk-rk3288.c | 3 +++ drivers/clk/rockchip/clk-rk3368.c | 6 ++++++ drivers/clk/rockchip/clk.h | 6 ++++++ 7 files changed, 45 insertions(+), 11 deletions(-) commit fa93fd4ecc9c58475abac6db93a797bff893bc16 Author: Mark Brown <broonie@kernel.org> Date: Mon Mar 21 18:12:52 2016 +0000 regulator: core: Ensure we are at least in bounds for our constraints Currently we only attempt to set the voltage during constraints application if an exact voltage is specified. Extend this so that if the currently set voltage for the regulator is outside the bounds set in constraints we will move the voltage to the nearest constraint, raising to the minimum or lowering to the maximum as needed. This ensures that drivers can probe without the hardware being driven out of spec. Reported-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Tested-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 32 +++++++++++++++++++++++++------- drivers/regulator/of_regulator.c | 2 +- 2 files changed, 26 insertions(+), 8 deletions(-) commit 1ade61c141e259ae045930420702f0d628fc88fc Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Tue Jan 26 10:06:59 2016 +0800 arm64: dts: rockchip: remove broken-cd from emmc and sdio Only one of "broken-cd" and "non-removable" should be supplied according to Documentation/devicetree/bindings/mmc/mmc.txt. Obviously emmc and sdio-wifi are non-removable devices, while broken-cd is for removable device whose card detect pin is broken. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi | 1 - arch/arm64/boot/dts/rockchip/rk3368-r88.dts | 1 - 2 files changed, 2 deletions(-) commit 04317584ff1ad6977ba37acf38d2c6b841ce20a4 Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Feb 15 11:30:58 2016 +0800 arm64: dts: rockchip: fix the incorrect otp-out pin on rk3368 This patch fixes the incorrect Over-temperature protection pin. since the rk3368 io list said the otp pin is gpio0a3. Anyway, that should be fixed in here. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm64/boot/dts/rockchip/rk3368.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 57375d88fa3f6bf9351051529464c708f72adb1d Author: Shawn Lin <shawn.lin@rock-chips.com> Date: Tue Jan 26 10:06:43 2016 +0800 ARM: dts: rockchip: remove broken-cd from emmc and sdio Only one of "broken-cd" and "non-removable" should be supplied according to Documentation/devicetree/bindings/mmc/mmc.txt. Obviously emmc and sdio-wifi are non-removable devices, while broken-cd is for removable device whose card detect pin is broken. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3036-kylin.dts | 1 - arch/arm/boot/dts/rk3036.dtsi | 1 - arch/arm/boot/dts/rk3066a-rayeager.dts | 2 -- arch/arm/boot/dts/rk3228-evb.dts | 1 - arch/arm/boot/dts/rk3288-evb.dtsi | 1 - arch/arm/boot/dts/rk3288-firefly.dtsi | 2 -- arch/arm/boot/dts/rk3288-popmetal.dts | 1 - arch/arm/boot/dts/rk3288-veyron.dtsi | 2 -- 8 files changed, 11 deletions(-) commit 26f5e19dfb07de627112074721f254482f941dab Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Feb 15 15:33:33 2016 +0800 ARM: dts: rockchip: enable the tsadc for rk3228 evb This patch enables the tsadc for rk3228 evb board. The rk3228 evb board uses the CRU to reset the chip since it hasn't the PMIC to connect it, and TSHUT is low active on evb board. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3228-evb.dts | 7 +++++++ 1 file changed, 7 insertions(+) commit 7796031eec9e41099af35bc531f04843358fa3f1 Author: Caesar Wang <wxt@rock-chips.com> Date: Mon Feb 15 15:33:32 2016 +0800 ARM: dts: rockchip: add the thermal main info found on rk3228 This patch adds the thermal needed main information for rk3228 SoCS. Basically has the following content: 1) TSADC controller: Add the needed attributes for rk3036 TSADC controller. Especially for the TSHUT, in some cases if we are unable to shut it down in orderly fashion (says: kernel is stuck holding a lock or similar), then hardware TSHUT will reset it. If the temperature is over 95C over a period of time the thermal shutdown of the tsadc is invoked with can either reset the entire chip via the CRU, or notify the PMIC via a GPIO. This should be set in the specific board. 2) Thermal zones: Add the needed device mode for thermal generic framework. Detail in Documentation/devicetree/bindings/thermal/thermal.txt. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3228.dtsi | 69 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) commit fe95effb4c381355e38f5bffced4917a2b6dc7d3 Author: Jianqun Xu <jay.xu@rock-chips.com> Date: Tue Feb 23 15:01:01 2016 +0800 dt-bindings: add bindings for Rockchip grf Add devicetree bindings for Rockchip grf which found on Rockchip SoCs. Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Heiko Stuebner <heiko@sntech.de> .../devicetree/bindings/soc/rockchip/grf.txt | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) commit 1946a201b3963b78a9e2123aedbdd11c4c4849dd Author: John Keeping <john@metanate.com> Date: Tue Feb 23 12:39:41 2016 +0000 ARM: dts: rockchip: add mipi_dsi to VIO power domain on rk3288 The MIPI controllers are part of the VIO power domain so add the necessary property to indicate this for the controller we support. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288.dtsi | 1 + 1 file changed, 1 insertion(+) commit 57dcfa56138c883905a265979cc84ef69675ae00 Author: John Keeping <john@metanate.com> Date: Tue Feb 23 13:41:00 2016 +0000 ARM: dts: rockchip: fix audio interrupts on rk3288 These must be translated from the values in the TRM by subtracting 32, which has not been done. The SPDIF interrupt is also off-by-one. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 5415ba40650900f7d663a4b79f346c45dddd4ce0 Author: John Keeping <john@metanate.com> Date: Tue Feb 23 13:40:59 2016 +0000 ARM: dts: rockchip: fix MIPI interrupt on rk3288 This isn't currently used by the driver but the correct value is 19 since DSIHOST0 is 51 in the TRM and the GIC offset requires 32 to be subtracted. Signed-off-by: John Keeping <john@metanate.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3288.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cef0abefa146877019e63c4e6ae439d40d01804f Author: Caesar Wang <wxt@rock-chips.com> Date: Tue Feb 2 11:40:50 2016 +0800 ARM: dts: rockchip: enable graphics support on rk3036-kylin Enable the recently added vop and hdmi nodes on the rk3036-kylin board. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3036-kylin.dts | 12 ++++++++++++ 1 file changed, 12 insertions(+) commit b7217cf19c633dc542ba4980f8fa34933ca1d343 Author: Caesar Wang <wxt@rock-chips.com> Date: Tue Feb 2 11:40:50 2016 +0800 ARM: dts: rockchip: add hdmi device node for rk3036 Add the Innosilicon hdmi node for HDMI display. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3036.dtsi | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) commit d9abae3ca5e8fa30fe5074aafd52a5bdfb8b2ed8 Author: Caesar Wang <wxt@rock-chips.com> Date: Tue Feb 2 11:40:50 2016 +0800 ARM: dts: rockchip: add vop device node for rk3036 The rk3036 support two overlay plane and one hwc plane, it supports IOMMU, and its IOMMU same as rk3288's. Signed-off-by: Caesar Wang <wxt@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> arch/arm/boot/dts/rk3036.dtsi | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) commit 9387bfd19b457085189d918ef117ffd63c4d67a0 Author: Xing Zheng <zhengxing@rock-chips.com> Date: Wed Mar 9 10:43:31 2016 +0800 clk: rockchip: add a COMPOSITE_FRACMUX_NOGATE type Because there are some frac clock mux nodes don't have a gate node on the RK3399. Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> drivers/clk/rockchip/clk.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) commit e437b90026ac754a0f8b4fe44b844d12ce6162d1 Author: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> Date: Thu Mar 24 21:52:01 2016 +0200 regulator: core: Remove duplicate copy of active-discharge parsing Apparently due to a wrongly resolved merge conflict between two branches, which contained the same commit, the commit contents partially was added two times in a row. This change reverts the latter wrong inclusion of commit 909f7ee0b5f3 ("regulator: core: Add support for active-discharge configuration"). The first applied commit 670666b9e0af ("regulator: core: Add support for active-discharge configuration") is not touched. Signed-off-by: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> Cc: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 11 ----------- 1 file changed, 11 deletions(-) commit b4ac5afc6b8398b15d061e909bbad153aae41f15 Author: Dave Gordon <david.s.gordon@intel.com> Date: Thu Mar 24 11:20:38 2016 +0000 drm/i915: replace for_each_engine() Having provided for_each_engine_id() for cases where the third (id) argument is useful, we can now replace all the remaining instances with a simpler version that takes only two parameters. In many cases, this also allows the elimination of the local variable used in the iterator (usually 'i'). v2: s/dev_priv/(dev_priv__)/ in body of for_each_engine_masked() [Chris Wilson] Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458757194-17783-2-git-send-email-david.s.gordon@intel.com drivers/gpu/drm/i915/i915_debugfs.c | 50 +++++++++++++----------------- drivers/gpu/drm/i915/i915_drv.h | 17 ++++++---- drivers/gpu/drm/i915/i915_gem.c | 50 +++++++++++++----------------- drivers/gpu/drm/i915/i915_gem_context.c | 6 ++-- drivers/gpu/drm/i915/i915_gem_debug.c | 3 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 9 ++---- drivers/gpu/drm/i915/i915_guc_submission.c | 6 ++-- drivers/gpu/drm/i915/i915_irq.c | 14 +++------ drivers/gpu/drm/i915/intel_guc_loader.c | 8 ++--- drivers/gpu/drm/i915/intel_lrc.c | 3 +- drivers/gpu/drm/i915/intel_pm.c | 19 +++++------- 11 files changed, 82 insertions(+), 103 deletions(-) commit c3232b1883e033e291aa3146f431b7ec87c80ec5 Author: Dave Gordon <david.s.gordon@intel.com> Date: Wed Mar 23 18:19:53 2016 +0000 drm/i915: introduce for_each_engine_id() Equivalent to the existing for_each_engine() macro, this will replace the latter wherever the third argument *is* actually wanted (in most places, it is not used). The third argument is renamed to emphasise that it is an engine id (type enum intel_engine_id). All the callers of the macro that actually need the third argument are updated to use this version, and the argument (generally 'i') is also updated to be 'id'. Other callers (where the third argument is unused) are untouched for now; they will be updated in the next patch. Signed-off-by: Dave Gordon <david.s.gordon@intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 48 ++++++++++++++++-------------- drivers/gpu/drm/i915/i915_drv.h | 9 ++++++ drivers/gpu/drm/i915/i915_gpu_error.c | 6 ++-- drivers/gpu/drm/i915/i915_guc_submission.c | 8 ++--- drivers/gpu/drm/i915/i915_irq.c | 10 +++---- drivers/gpu/drm/i915/intel_mocs.c | 6 ++-- drivers/gpu/drm/i915/intel_ringbuffer.c | 21 +++++++------ 7 files changed, 62 insertions(+), 46 deletions(-) commit 8f507c8b0fa5d679e2957aad0e5ecd47675fca9a Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> Date: Wed Mar 16 16:59:38 2016 -0700 HID: hidraw: switch to using memdup_user Instead of open-coding memory allocation and copying form user memory sequence let's use memdup_user(). Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> drivers/hid/hidraw.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) commit db18b6a64ca3fb260858279b218b84d5c179330f Author: Imre Deak <imre.deak@intel.com> Date: Thu Mar 24 12:41:40 2016 +0200 drm/i915/bxt: Fix DSI HW state readout Currently the machine hangs during booting while accessing the BXT_MIPI_PORT_CTRL register during pipe HW state readout. After some experimentation I found that the hang is caused by the DSI PLL being disabled, or it being enabled but with an incorrect divider configuration. Enabling the PLL got rid of the boot problem, so fix this by checking the PLL enabled state/configuration before attempting to read out the HW state. The DSI_PLL_ENABLE register is in the always-on power well, while the BXT_DSI_PLL_CTL is in power well 0. This isn't exactly matched by the transcoder power domain, but what we really need is just a runtime PM reference, which is provided by any power domain. Ville also found this dependency specified in BSpec, so I added a reference to that too. v2: - Make sure we hold a power reference while accessing the PLL registers. v3: (Jani) - Simplify check in bxt_get_dsi_transcoder_state() - Add comment explaining why we check for valid dividers in bxt_dsi_pll_is_enabled() CC: Shashank Sharma <shashank.sharma@intel.com> CC: Uma Shankar <uma.shankar@intel.com> CC: Jani Nikula <jani.nikula@intel.com> Fixes: c6c794a2fc5e ("drm/i915/bxt: Initialize MIPI DSI for BXT") Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458816100-31269-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_reg.h | 2 ++ drivers/gpu/drm/i915/intel_display.c | 11 ++++++++++ drivers/gpu/drm/i915/intel_dsi.c | 9 ++++++++ drivers/gpu/drm/i915/intel_dsi.h | 1 + drivers/gpu/drm/i915/intel_dsi_pll.c | 40 ++++++++++++++++++++++++++++++++++++ 5 files changed, 63 insertions(+) commit 3e11e530415027a57936545957126aff49267b76 Author: Benjamin Marzinski <bmarzins@redhat.com> Date: Wed Mar 23 14:29:59 2016 -0400 GFS2: ignore unlock failures after withdraw After gfs2 has withdrawn the filesystem, it may still have many locks not in the unlocked state. If it is using lock_dlm, it will failed trying the unlocks since it has already unmounted the lock manager. Instead, it should set the SDF_SKIP_DLM_UNLOCK flag on withdraw, to signal that it can skip the lock_manager on unlocks, and failback to lock_nolock style unlocking. Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com> Signed-off-by: Bob Peterson <rpeterso@redhat.com> fs/gfs2/glock.c | 9 ++++++++- fs/gfs2/util.c | 1 + 2 files changed, 9 insertions(+), 1 deletion(-) commit 307e44988018943586f27d554a1773f685b3342e Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 23 14:33:28 2016 +0100 drm/i915: Remove vblank wait from hsw_enable_ips, v2. intel_post_plane_update did an extra vblank wait that's no longer needed when enabling ips. Changes since v1: - Add comment explaining why vblank wait is performed. (Paulo) Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56F29B28.5070804@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) commit 267c85860308d36bc163c5573308cd024f659d7c Author: Andrew F. Davis <afd@ti.com> Date: Wed Mar 23 09:26:33 2016 -0500 regmap: cache: Fix typo in cache_bypass parameter description Setting the flag 'cache_bypass' will bypass the cache not the hardware. Fix this comment here. Fixes: 0eef6b0415f5 ("regmap: Fix doc comment") Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/base/regmap/regcache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 321d178edb17d4619dbfa6216ac185c30c18d31a Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Nov 20 10:27:18 2015 +0000 drm/i915: Tidy aliasing_gtt_bind_vma() In commit 0a878716265e9af9f697264dc2e858fcc060d833 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Thu Oct 15 14:23:01 2015 +0200 drm/i915: restore ggtt double-bind avoidance we wrote the ggtt_bind_vma() observing a number of cleanups we could do over the template of aliasing_gtt_bind_vma(). Now let's apply the cleanups we made there back to the original. The essence is to avoid redundant variables and assignements, and by doing so make the code easier to read. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1448015238-24639-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/i915_gem_gtt.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) commit 9419b2006cf47c75985ea51d36ddc51346d29efd Author: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Date: Tue Mar 22 01:41:52 2016 +0530 spi: fsl-dspi: Set max_speed_hz for master Calculate and update max speed from bus clock for SoCs using DSPI IP. The bus clock factor's are taken from the data sheets of respective SoCs. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Acked-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-fsl-dspi.c | 7 +++++++ 1 file changed, 7 insertions(+) commit abf2f825d115397944cab91a20c937331d77e37c Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Wed Mar 23 11:35:39 2016 +0000 regulator: add missing description for set_over_current_protection Over current protection is missing descriptions for documentation. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/regulator/driver.h | 3 +++ include/linux/regulator/machine.h | 1 + 2 files changed, 4 insertions(+) commit d13d3a573be5535123beacd926be38e571097bc5 Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Wed Mar 23 11:24:47 2016 +0000 regulator: add missing descriptions in regulator_desc Members csel_reg and csel_mask of the regulator_desc struct are missing descriptions for documentation. Adding them. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> include/linux/regulator/driver.h | 2 ++ 1 file changed, 2 insertions(+) commit bf23d1917d551487e85378c4f4a7a0efcfe77f4e Author: Kamlakant Patel <kamlakant.patel@broadcom.com> Date: Tue Mar 22 18:38:14 2016 +0530 spi: xlp: Enable SPI driver for Broadcom Vulcan ARM64 - Vulcan spi controller is compatible with netlogic,xlp832-spi. - Add depends on ARCH_VULCAN to Kconfig to enable spi controller driver for Broadcom Vulcan ARM64 SoCs. Signed-off-by: Kamlakant Patel <kamlakant.patel@broadcom.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cc61a1bbbc0ebbda3cc155bcbe164f4609fd62f6 Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Date: Wed Mar 16 18:13:32 2016 +0530 ath10k: enable debugfs provision to enable Peer Stats feature Provide a debugfs entry to enable/ disable Peer Stats feature. Peer Stats feature is for developers/users who are more interested in studying in Rx/Tx stats with multiple clients connected, hence disable this by default. Enabling this feature by default results in unneccessary processing of Peer Stats event for every 500ms and updating peer_stats list (allocating memory) and cleaning it up ifexceeds the higher limit and this can be an unnecessary overhead during long run stress testing. Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 2 +- drivers/net/wireless/ath/ath10k/core.h | 12 +++++ drivers/net/wireless/ath/ath10k/debug.c | 80 ++++++++++++++++++++++++++++++--- drivers/net/wireless/ath/ath10k/mac.c | 2 +- drivers/net/wireless/ath/ath10k/wmi.c | 12 +++-- 5 files changed, 94 insertions(+), 14 deletions(-) commit 70e8aa215623b5c4d3d3457fd6e6090ad6bfe9a3 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:16 2016 +0200 drm/i915: Split PNV version of crtc_compute_clock() Split a pnv_crtc_compute_clock(), so the differences between platforms become more obvious. With this, there are no more users of intel_limit() or the ->find_dpll() hook, so get rid of them. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-16-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/i915_drv.h | 18 ----- drivers/gpu/drm/i915/intel_display.c | 134 +++++++++++++++++++++-------------- 2 files changed, 79 insertions(+), 73 deletions(-) commit 19ec6693098c80d3fd693d9defbc7e46e60e1c1b Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:15 2016 +0200 drm/i915: Split g4x_crtc_compute_clock() Split a G4X specific version from i9xx_crtc_compute_clock(). With this the differences between platforms become more obvious. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-15-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 82 +++++++++++++++++++++++------------- 1 file changed, 53 insertions(+), 29 deletions(-) commit 81c97f522e41c022f96cd009feacb9acb994f115 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 22 15:35:23 2016 +0200 drm/i915: Split i8xx_crtc_compute_clock() Split a GEN2 specific version from i9xx_crtc_compute_clock(). With this there is no need for i9xx_get_refclk() anymore, and the differences between platforms become more obvious. v2: Use i8xx as prefix instead of gen2. (Ville and Daniel) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458653723-17951-1-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 91 +++++++++++++++++++++--------------- 1 file changed, 53 insertions(+), 38 deletions(-) commit 65b3d6a976490bc731ad56e287965223030abe89 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:13 2016 +0200 drm/i915: Split CHV and VLV specific crtc_compute_clock() hooks In order for VLV and CHV to use i9xx_crtc_compute_clocks(), a number of if ladders is necessary: one for setting the find_dpll() hook, one for choosing the limits struct, one for choosing the right compute dpll function and one for initializing the crtc_compute_clock() hook. By extracting a platform specific implementation for each platform, the number of if-ladders is reduced to one. While at it also clean up bxt_find_best_dpll() which depends on some of the CHV code. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-13-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 102 ++++++++++++++++++++++++++--------- 1 file changed, 78 insertions(+), 24 deletions(-) commit 997c030cfdd0f87ca5ac8b77ef0821c5597263f8 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:12 2016 +0200 drm/i915: Merge ironlake_compute_clocks() and ironlake_crtc_compute_clock() Merge ironlake_compute_clocks() into ironlake_crtc_compute_clock() so the clock computation logic is all in one place. The resulting function is still quite simple. Follow up patches will make the similar code for GMCH platforms look similar. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-12-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 86 ++++++++++++++---------------------- 1 file changed, 33 insertions(+), 53 deletions(-) commit b75ca6f62e57923e9c2870bf8d795c410ebb9534 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:11 2016 +0200 drm/i915: Move fp divisor calculation into ironlake_compute_dpll() Follow what is done in i8xx_compute_dpll() and i9xx_compute_dpll() and move the lower level details of setting crtc_state->dpll_hw_state into the _compute_dpll() function. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-11-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 45 ++++++++++++++++++------------------ 1 file changed, 22 insertions(+), 23 deletions(-) commit 364ee29d12062458286f560bbca10e523088204e Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:10 2016 +0200 drm/i915: Pass crtc_state->dpll directly to ->find_dpll() When calculating clocks, just pass a pointer to crtc_state->dpll directly to the find_dpll() hook. Back when this was introduced in commit f47709a9502f3 ("drm/i915: create pipe_config->dpll for clock state") there was no staged crtc config or atomic crtc state, so it was possible to overwrite the current configuration on error. That hasn't been the case for a while now, so finally make it "disappear". Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-10-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 34 ++++++++++------------------------ 1 file changed, 10 insertions(+), 24 deletions(-) commit ded220e2513dee45807ba586a566f64b2887c2c4 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:09 2016 +0200 drm/i915: Simplify ironlake_crtc_compute_clock() CPU eDP case None of the code in ironlake_crtc_compute_clock() is relevant for CPU eDP. The CPU eDP PLL is turned on and off in ironlake_edp_pll_{on,off} from the DP code and that doesn't depend on the crtc_state->dpll values, so just return early in that case. v2: Rebase without patch that drops lvds downclock code. (Ville) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-9-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 47 ++++++++++++++++++------------------ 1 file changed, 23 insertions(+), 24 deletions(-) commit fade85ae2122cd6f136cbbfe2c1a392910354cdf Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:08 2016 +0200 drm/i915: Remove PCH type checks from ironlake_crtc_compute_clock() The checks were added in commit 5dc5298bb3e5 ("drm/i915: add proper CPU/PCH checks to crtc_mode_set functions") in a time when there was doubts on what PCHs would be supported by HSW. There are similar checks for PCH type in intel_detect_pch() and the function pointers are initialized based on platform/pch information, so the removed WARN can't ever be reached. v2: Rebase without patch that drops lvds downclock code. (Ville) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-8-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 4 ---- 1 file changed, 4 deletions(-) commit 7ed9f894e55e5a623c640d2e5be5db2b0bf14374 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:07 2016 +0200 drm/i915: Don't calculate a new clock in ILK+ code if it is already set Remove the clock calculation from ironlake_crtc_compute_clock() when the encoder compute_config() already set one. The value was just thrown away in that case. Note that the previously set clock is not validated against the limits anymore. That is ok since the fixed clocks from DP and SDVO are within the supported range, so the call to ironlake_compute_clocks() would never fail in that case. v2: Add note about not checking fixed clocks agains limits. (Maarten) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-7-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) commit bfa044457c8a0ea20f4aee33337232a3bcfa1dcf Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:06 2016 +0200 drm/i915: Simplify ironlake reduced clock logic a bit Check has_reduced_clock only once when setting dpll_hw_state, making the code slightly more readable. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-6-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) commit 2d7feacc817e8882ab87f29e468918f6dbabf611 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:05 2016 +0200 drm/i915: Call g4x_find_best_dpll() directly from ILK+ code The call to dev_priv->display.find_dpll() is already in platform specific code, so avoid the extra detour. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-5-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 8f0d5b9b5891d7e29513bba44fe6c5c3d84df1d8 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:04 2016 +0200 drm/i915: Fold intel_ironlake_limit() into clock computation function The function intel_ironlake_limit() is only called by the crtc compute clock path. By merging it into ironlake_compute_clocks(), the code gets clearer, since there's no more if-ladders to follow. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-4-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 56 +++++++++++++++--------------------- 1 file changed, 23 insertions(+), 33 deletions(-) commit 26ce6d5980fa399e7ca4cb83414ece931ce316ba Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:03 2016 +0200 drm/i915: Merge ironlake_get_refclk() into its only caller A previous patch made ironlake_get_refclk() very simple, so merge it into its only caller. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-3-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 24 ++++++++---------------- 1 file changed, 8 insertions(+), 16 deletions(-) commit ceb41007b42bbc9e4be1cf17575b01de6c3b3b18 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Mon Mar 21 18:00:02 2016 +0200 drm/i915: Remove checks for cloned config with LVDS in dpll code LVDS is not cloneable, so the check is unnecessary. Removing it makes the code neater. v2: Remove checks from GMCH code too, not only ILK+. (Ville) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458576016-30348-2-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 70 +++++++++--------------------------- 1 file changed, 16 insertions(+), 54 deletions(-) commit 90e83e5390a04d31eb2846293cd3db506c2315e7 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 22 10:11:24 2016 +0200 drm/i915: Wait for vblank in i9xx_disable_crtc() for gen 2 only The wait for other gens was added in commit 564ed191f5d8 ("drm/i915: gmch: fix stuck primary plane due to memory self-refresh mode") since that's necessary when disabling cxsr. However, cxsr disabling was later moved to intel_pre_disable_primary() in commit 87d4300a7dbc ("drm/i915: Move intel_(pre_disable/post_enable)_primary to intel_display.c, and use it there.") and that function got its own vblank wait for cxsr in commit 262cd2e154c2 ("drm/i915: CHV DDR DVFS support and another watermark rewrite"). So remove the extra vblank wait from i9xx_crtc_distable(). Cc: Kalyan Kondapally <kalyan.kondapally@intel.com> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458634284-6080-1-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit 3d9195ea19e4854d7daa11688b01905e244aead9 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Fri Mar 18 11:44:22 2016 +0200 ath10k: incorporate qca4019 cal data download sequence qca4019 calibration data is stored in the host memory and it's mandatory to download it even before reading board id and chip id from the target. Also, there is a need to execute otp (download and run) twice, one after cal data download and another one after board data download. Existing cal data file name 'cal-<bus>-<id>.bin' and device tree entry 'qcom,ath10k-calibration-data' used in ath10k has assumption that it carries other data (like board data) also along with the calibration data. But, qca4019 cal data contains pure calibration data (doesn't include any other info). So, using existing same cal file name and DT entry in qca4019 case would alter the purpose of it. To avoid this, new cal file name 'pre-cal-<bus>-<id>.bin' and new device tree entry name 'qcom,ath10k-pre-calibration-data are introduced. Overall qca4019's firmware download sequence would look like, 1) Download cal data (either from a file or device tree entry) at the address specified by target in the host interest area member "hi_board_data". 2) Download otp and run with 0x10 (PARAM_GET_EEPROM_BOARD_ID) as a argument. At this point, otp will take back up of downloaded cal data content in another location in the target and return valid board id and chip id to the host. 3) Download board data at the address specified by target in host interest area member "hi_board_data". 4) Download otp and run with 0x10000 (PARAM_FLASH_SECTION_ALL) as a argument. Now otp will apply cal data content from it's backup on top of board data download in step 3 and prepare final data base. 5) Download code swap and athwlan binary content. Above sequences are implemented (step 1 to step 4) in the name of pre calibration configuration. Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 85 +++++++++++++++++++++++++++++++++- drivers/net/wireless/ath/ath10k/core.h | 11 ++++- 2 files changed, 94 insertions(+), 2 deletions(-) commit 0b8e3c4ca29fe2c0efd3d41a76e34a657b9f17a4 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Fri Mar 18 11:44:22 2016 +0200 ath10k: move cal data len to hw_params ath10k_download_cal_dt() compares obtained cal data content length against QCA988X_CAL_DATA_LEN (2116 bytes). It was written by keeping qca988x in mind. In fact, cal data length is more chip specific. To make ath10k_download_cal_dt() more generic and reusable for other chipsets (like qca4019), cal data length is moved to hw_params. Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 11 ++++++++++- drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/debug.c | 7 ++++--- drivers/net/wireless/ath/ath10k/hw.h | 2 -- 4 files changed, 15 insertions(+), 6 deletions(-) commit f454add47adb4133f297e1b7af07bf07b3983044 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Fri Mar 18 11:44:21 2016 +0200 ath10k: pass cal data location as an argument to ath10k_download_cal_{file|dt} Both ath10k_download_cal_file() and ath10k_download_cal_dt() uses hard coded file pointer (ar->cal_file) and device tree entry (qcom,ath10k-calibration-data) respectively to get calibration data content. There is a need to use those two functions in qca4019 calibration download sequence with different file pointer and device tree entry name. Modify those two functions to take cal data location as an argument. So that it can serve the purpose for other file pointer and device tree entry. This is just preparation before adding actual qca4019 calibration download sequence. No functional changes. Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) commit 2dc10cd8bc2662d0311224d92fb82f34be0424bc Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Mar 23 10:31:46 2016 +0200 drm/i915: Fix use after free when printing load failure Commit d15d7538c6d2 ("drm/i915: Tune down init error message due to failure injection") added i915_load_error message to failure path on device initialization. The message is printed after the device is freed. And as the message printing helper uses the device structure, this leads to use after free. Spotted by Kasan. Cc: Imre Deak <imre.deak@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458721906-10625-1-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/i915_dma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit c6c794a2fc5e3bc8976fa318fbc7a003ecd712a1 Author: Shashank Sharma <shashank.sharma@intel.com> Date: Tue Mar 22 12:01:50 2016 +0200 drm/i915/bxt: Initialize MIPI DSI for BXT This patch contains following changes: 1. Add BXT MIPI display address base. 2. Call dsi_init from display_setup function. v2: Rebased on latest nightly branch v3 by Jani: init dsi after ddi Signed-off-by: Shashank Sharma <shashank.sharma@intel.com> Signed-off-by: Uma Shankar <uma.shankar@intel.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458640910-5338-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_display.c | 2 ++ drivers/gpu/drm/i915/intel_dsi.c | 2 ++ 3 files changed, 5 insertions(+) commit ad45d83968caf8e757cf895f4fd53903a092fad8 Author: Imre Deak <imre.deak@intel.com> Date: Mon Mar 21 17:08:57 2016 +0200 drm/i915: Make __i915_printk debug output behave the same as DRM_DEBUG_DRIVER Joonas and Daniel remarked that our debugging output should stay compatible with the core DRM's debug facility. The recently added __i915_printk() would output debug messages even if debugging is completely disabled via the drm.debug option. To fix this make __i915_printk behave the same as DRM_DEBUG_DRIVER in this case. CC: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> CC: Daniel Vetter <daniel.vetter@ffwll.ch> CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458572937-21712-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 4 ++++ 1 file changed, 4 insertions(+) commit 177246a84d133888b5428e44201282d94635f473 Author: Matt Roper <matthew.d.roper@intel.com> Date: Fri Mar 4 15:59:39 2016 -0800 drm/i915: Wait until after wm optimization to drop runtime PM reference At the end of an atomic commit, we currently wait for vblanks to complete, call put() on the various runtime PM references, and then try to optimize our watermarks (on platforms that need two-step watermark programming). This can lead to watermark registers being programmed while the power well is powered down. We need to wait until after watermark optimization is complete before dropping our runtime power references. Note that in the future the watermark optimization is probably going to move to an asynchronous workqueue task that happens at some arbitrary point after vblank. When we make that change, we'll no longer necessarily be operating under the power reference held here, so we'll need to wrap the watermark register programmin in a call to intel_runtime_pm_get_if_in_use() or similar. Cc: arun.siluvery@linux.intel.com Cc: ville.syrjala@linux.intel.com Cc: maarten.lankhorst@linux.intel.com Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94349 Fixes: ed4a6a7ca853 ("drm/i915: Add two-stage ILK-style watermark programming (v11)") Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457135979-23727-1-git-send-email-matthew.d.roper@intel.com drivers/gpu/drm/i915/intel_display.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 14b730fcb8d9b9c6fed540829548040ef8d2ca2c Author: arun.siluvery@linux.intel.com <arun.siluvery@linux.intel.com> Date: Fri Mar 18 20:07:55 2016 +0000 drm/i915/tdr: Prepare error handler to accept mask of hung engines In preparation for engine reset, the wedged argument of i915_handle_error() is extended to reflect as a mask of engines that are hung. This is further passed down to error state capture functions which are also updated. Engine reset recovery mechanism uses this mask and schedules recovery work for those particular engines. Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Tomas Elf <tomas.elf@intel.com> Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458331676-567-3-git-send-email-arun.siluvery@linux.intel.com drivers/gpu/drm/i915/i915_drv.h | 4 ++-- drivers/gpu/drm/i915/i915_gpu_error.c | 8 ++++---- drivers/gpu/drm/i915/i915_irq.c | 16 ++++++++-------- 3 files changed, 14 insertions(+), 14 deletions(-) commit fc0768ceac126ea6ec2ff8bd56bbe4abe11695bc Author: Tomas Elf <tomas.elf@intel.com> Date: Mon Mar 21 16:26:59 2016 +0000 drm/i915/tdr: Initialize hangcheck struct for each engine Initialize hangcheck struct during driver load. Since we do the same after recovering from a reset, this is extracted into a helper function. v2: remove redundant hangcheck init during load as this is done when engines are initialized (Chris) Cc: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Tomas Elf <tomas.elf@intel.com> Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458577619-12006-1-git-send-email-arun.siluvery@linux.intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 7 ++++++- 3 files changed, 8 insertions(+), 2 deletions(-) commit 895fe2321efaf62023fdd8239d1846394df68570 Author: Mark Brown <broonie@kernel.org> Date: Mon Mar 21 18:17:43 2016 +0000 regulator: core: Always flag voltage constraints as appliable Allow the core to always use the voltage constraints to set the voltage on startup. A forthcoming change in that code will ensure that we bring out of constraints voltages into spec with this setting. Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/of_regulator.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit d1ef4f2cae6705925088047554e89c34048f926a Author: Marc Titinger <mtitinger@baylibre.com> Date: Mon Mar 14 11:20:44 2016 +0100 iio: ina2xx-adc: update the CALIB. register when RShunt changes The user (or an init script) may setup RShunt via sysfs after the driver was initialized, for instance based on the EEPROM contents of a modular probe. The calibration register must be set accordingly. Signed-off-by: Marc Titinger <marc.titinger@baylibre.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/ina2xx-adc.c | 39 ++++++++++++++++++++++++--------------- 1 file changed, 24 insertions(+), 15 deletions(-) commit 29dc3739e50da3576ddf89d9ea2704640676135d Author: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Date: Wed Mar 16 10:57:17 2016 +0000 drm/i915: Implement color management on chv Patch based on a previous series by Shashank Sharma. v2: Update contributors v3: Refactor degamma/gamma LUTs load into a single function v4: Remove unused variable Signed-off-by: Shashank Sharma <shashank.sharma@intel.com> Signed-off-by: Kumar, Kiran S <kiran.s.kumar@intel.com> Signed-off-by: Kausal Malladi <kausalmalladi@gmail.com> Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125837-2576-5-git-send-email-lionel.g.landwerlin@intel.com drivers/gpu/drm/i915/i915_drv.c | 3 + drivers/gpu/drm/i915/i915_reg.h | 31 +++++++++ drivers/gpu/drm/i915/intel_color.c | 133 +++++++++++++++++++++++++++++++++++-- 3 files changed, 161 insertions(+), 6 deletions(-) commit 82cf435b3134a5f892971b721b34e4c5d249363d Author: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Date: Wed Mar 16 10:57:16 2016 +0000 drm/i915: Implement color management on bdw/skl/bxt/kbl Patch based on a previous series by Shashank Sharma. v2: Do not read GAMMA_MODE register to figure what mode we're in v3: Program PREC_PAL_GC_MAX to clamp pixel values > 1.0 Add documentation on how the Broadcast RGB property is affected by CTM v4: Update contributors v5: Refactor degamma/gamma LUTs load into a single function v6: Fix missing intel_crtc variable (bisect issue) v7: Fix & simplify limited range matrix multiplication (Matt Roper's comment) Signed-off-by: Shashank Sharma <shashank.sharma@intel.com> Signed-off-by: Kumar, Kiran S <kiran.s.kumar@intel.com> Signed-off-by: Kausal Malladi <kausalmalladi@gmail.com> Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Acknowledged-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125837-2576-4-git-send-email-lionel.g.landwerlin@intel.com Documentation/DocBook/gpu.tmpl | 6 +- drivers/gpu/drm/i915/i915_drv.c | 24 ++- drivers/gpu/drm/i915/i915_drv.h | 6 + drivers/gpu/drm/i915/i915_reg.h | 22 +++ drivers/gpu/drm/i915/intel_color.c | 345 +++++++++++++++++++++++++++++------ drivers/gpu/drm/i915/intel_display.c | 22 ++- drivers/gpu/drm/i915/intel_drv.h | 3 +- drivers/gpu/drm/i915/intel_fbdev.c | 8 + 8 files changed, 371 insertions(+), 65 deletions(-) commit 05dc698c2e5c9d4453f62fd1cd5acbc68bc97b0f Author: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Date: Wed Mar 16 10:57:15 2016 +0000 drm/i915: Do not read GAMMA_MODE register Implement Daniel Stone's recommendation to not read registers to infer the hardware's state. v2: Read GAMMA_MODE register value at init (Matt Roper's comment) v3: Read GAMMA_MODE register in intel_modeset_readout_hw_state along with other registers (Matt Roper's comment). v4: Mask GAMMA_MODE register with interesting bits when reading Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125837-2576-3-git-send-email-lionel.g.landwerlin@intel.com drivers/gpu/drm/i915/intel_color.c | 7 +++++-- drivers/gpu/drm/i915/intel_display.c | 3 +++ drivers/gpu/drm/i915/intel_drv.h | 3 +++ 3 files changed, 11 insertions(+), 2 deletions(-) commit 8563b1e8ef88c8bdb824ab1c00ebb7d66308fef0 Author: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Date: Wed Mar 16 10:57:14 2016 +0000 drm/i915: Extract out gamma table and CSC to their own file The moves a couple of functions programming the gamma LUT and CSC units into their own file. On generations prior to Haswell there is only a gamma LUT. From haswell on there is also a new enhanced color correction unit that isn't used yet. This is why we need to set the GAMMA_MODE register, either we're using the legacy 8bits LUT or enhanced LUTs (of 10 or 12bits). The CSC unit is only available from Haswell on. We also need to make a special case for CherryView which is recognized as a gen 8 but doesn't have the same enhanced color correction unit from Haswell on. v2: Fix access to GAMMA_MODE register on older generations than Haswell (from Matt Roper's comments) Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/1458125837-2576-2-git-send-email-lionel.g.landwerlin@intel.com drivers/gpu/drm/i915/Makefile | 1 + drivers/gpu/drm/i915/i915_drv.h | 2 + drivers/gpu/drm/i915/intel_color.c | 191 +++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_display.c | 171 +++---------------------------- drivers/gpu/drm/i915/intel_drv.h | 10 ++ 5 files changed, 216 insertions(+), 159 deletions(-) commit 178ff7c6f3916aff3c3eaaec8636be3b41e93011 Author: John Lin <john.lin@realtek.com> Date: Mon Feb 15 10:40:17 2016 +0800 ASoC: rt5645: Add dmi_system_id "Google Setzer" Add platform specific data for Setzer project. Signed-off-by: John Lin <john.lin@realtek.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/codecs/rt5645.c | 6 ++++++ 1 file changed, 6 insertions(+) commit e6e79fd9cee682b137779d2da3b379251927d99f Author: Maarten ter Huurne <maarten@treewalker.org> Date: Thu Mar 17 15:05:06 2016 +0100 regulator: act8865: Remove "too many regulators" error handler The check would dereference pdata, which can be NULL in the non-DT use case. Nothing will break if pdata->num_regulators is larger than the number of regulators that the driver defines: pdata->num_regulators is only read in act8865_get_init_data() to iterate through pdata->regulators. The error handler might have some value as a sanity check on the platform data, but the platform data could be broken in many other ways that are not checked for (unknown IDs, duplicate IDs), so I see no reason to perform only this specific check. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/act8865-regulator.c | 6 ------ 1 file changed, 6 deletions(-) commit de14ba67378df74c6328f75fd6972ef83ed4639b Author: Maarten ter Huurne <maarten@treewalker.org> Date: Thu Mar 17 15:05:05 2016 +0100 regulator: act8865: Remove redundant dev lookups The local variable "dev" already contains a pointer to the device, so there is no need to take the address of "client->dev" again. Signed-off-by: Maarten ter Huurne <maarten@treewalker.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/act8865-regulator.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) commit a47aaa69de88913d1640c4bd28c67fad142c61a3 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Fri Mar 18 11:44:21 2016 +0200 dt: bindings: add new dt entry for pre calibration in qcom, ath10k.txt There two things done in this patch, 1) Existing device tree entry 'qcom,ath10k-calibration-data' carries not only calibration data, it carries board specific data too. So, make appropriate update in doc. 2) ipq4019 wifi needs new devie tree entry to carry calibration data alone (called pre cal data, it doesn't include any other info). Using 'qcom,ath10k-calibration-data' for ipq4019 would alter the purpose of it. Hence, add new device tree entry called 'qcom,ath10k-pre-calibration-data' to carry only pre calibration data. Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> .../bindings/net/wireless/qcom,ath10k.txt | 23 +++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) commit 8866c727440d5b059637cb97927e383548099e8c Author: Michal Kazior <michal.kazior@tieto.com> Date: Thu Mar 17 10:52:08 2016 +0100 ath10k: fix null deref if device crashes early If device failed to init during early probing (which is quite rare) it triggered driver to compute crc before ar->firmware was ready causing an oops. Fixes: 3e58044b61a9 ("ath10k: print crc32 checksums for firmware and board files") Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/debug.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 750eeed89cf3c466df302e4707491b015531e26c Author: Michal Kazior <michal.kazior@tieto.com> Date: Thu Mar 17 10:51:05 2016 +0100 ath10k: fix pull-push tx threshold handling This prevents tx hangs or hiccups if pull-push supporting firmware defines per-txq thresholds or switches modes dynamically. Fixes: 299468782d94 ("ath10k: implement wake_tx_queue") Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 9d71d47eed20f34620e54e29bcc90f959d5873b8 Author: Michal Kazior <michal.kazior@tieto.com> Date: Thu Mar 17 10:51:04 2016 +0100 ath10k: fix tx hang The wake_tx_queue/push_pending logic had a bug which could stop queues indefinitely effectivelly breaking traffic. Fixes: 299468782d94 ("ath10k: implement wake_tx_queue") Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 3ae36c8b67e450dcb7011181658c198bec386e98 Author: Axel Lin <axel.lin@ingics.com> Date: Sun Mar 20 08:54:46 2016 +0800 spi: octeon: Convert to use devm_ioremap_resource Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/spi/spi-octeon.c | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) commit 95a293c7ba17253b8cffcacbdd716ebfbfe42587 Author: Javier Martinez Canillas <javier@osg.samsung.com> Date: Sun Mar 20 23:29:45 2016 -0300 regulator: Remove unneded check for regulator supply The regulator_resolve_supply() function checks if a supply has been associated with a regulator to avoid enabling it if that is not the case. But the supply was already looked up with regulator_resolve_supply() and set with set_supply() before the check and both return on error. So the fact that this statement has been reached means that neither of them failed and a supply must be associated with the regulator. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2e85ab4fed5762f86ae12c0347e64b89412191ca Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:44 2016 +0200 drm/i915/bxt: allow dsi on any pipe BXT isn't as limited as BYT and CHT regarding DSI pipes and ports. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/0375f1e237092d0ae3f39ecfc5702024918acbfd.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) commit 701d25b40c2e69a0b8e472a8b40a13a0b051bb43 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:43 2016 +0200 drm/i915/dsi: use the BIT macro for clarity No functional changes. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/9115c0a80ad57075700e006db965dd31cc4358fc.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 4d1de97568321828b9e63522c60ee77d23925471 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:42 2016 +0200 drm/i915/bxt: add dsi transcoders The BXT display connections have DSI transcoders A and C that can be muxed to any pipe, not unlike the eDP transcoder. Add the notion of DSI transcoders. The "normal" transcoders A, B and C are not used with BXT DSI, so care must be taken to avoid accessing those registers with DSI transcoders in the hardware state readout, modeset, and generally everywhere. v2: addressing comments by Ville: - rename the dsi get config function to hsw_get_dsi_transcoder_state - rebase onto the higher level split of pipe/transcoder functions - use more has_dsi_encoder as we can now because of the above, with no need to look at the transcoder so much - rename IS_DSI_TRANSCODER to transcoder_is_dsi - use the above a bit more instead of comparing to < TRANSCODER_EDP Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/299740536b7941e31b2744f3ce34f7afe936a771.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 13 +++++ drivers/gpu/drm/i915/intel_ddi.c | 6 +++ drivers/gpu/drm/i915/intel_display.c | 91 +++++++++++++++++++++++++++++---- drivers/gpu/drm/i915/intel_drv.h | 3 +- drivers/gpu/drm/i915/intel_dsi.c | 9 ++++ drivers/gpu/drm/i915/intel_runtime_pm.c | 6 +++ 6 files changed, 116 insertions(+), 12 deletions(-) commit cf30429e9420556399aab92995ff23e15c22de6b Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:41 2016 +0200 drm/i915: abstract get config for cpu transcoder Makes it neater to add the same for DSI transcoder. No functional changes. v2: rename to hsw_get_transcoder_state and add a comment about grabbing power reference (Ville) Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/c473a73d69dcd61584419d85ff7908a8717b0594.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_display.c | 87 +++++++++++++++++++++--------------- 1 file changed, 51 insertions(+), 36 deletions(-) commit 391bf04862feab95beffcb3634e8aba8961f4d35 Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:40 2016 +0200 drm/i915: split set pipeconf to pipeconf, pipemisc, pipe_gamma Prep work for DSI transcoders. No functional changes. v2: call split functions at a higher level (Ville) Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/981252d5d5f82d009d73e1b2ae93d9ab7bee8de8.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_display.c | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) commit bc58be6058d65f05c5bce8c562ec196e70760a9a Author: Jani Nikula <jani.nikula@intel.com> Date: Fri Mar 18 17:05:39 2016 +0200 drm/i915: split get/set pipe timings to timings and src size Prep work for DSI transcoders. No functional changes. v2: call split functions at a higher level (Ville) Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/8d67a05eb869a7b0c4ee17c2d3b0b029de34851c.1458313400.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_display.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) commit 1844a66b98800b3cfd92aea4e801641304ac07d7 Author: Jesse Barnes <jbarnes@virtuousgeek.org> Date: Wed Mar 16 13:31:30 2016 -0700 drm/i915: add another virtual PCH bridge for passthrough support Some configs use the P2X type but some use a P3X type PCH, so add that to the detect_pch function so things work correctly. Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> Reviewed-by: Allen Kay <allen.m.kay@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458160290-16710-1-git-send-email-jbarnes@virtuousgeek.org drivers/gpu/drm/i915/i915_drv.c | 1 + drivers/gpu/drm/i915/i915_drv.h | 1 + 2 files changed, 2 insertions(+) commit 6cf0716c0321344fdc72205d590e968e53492088 Author: Jordan Justen <jordan.l.justen@intel.com> Date: Sun Mar 6 23:30:30 2016 -0800 drm/i915: Bump command parser version for new whitelisted registers Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1457335830-30923-6-git-send-email-jordan.l.justen@intel.com drivers/gpu/drm/i915/i915_cmd_parser.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 1b85066bb1332e4298e533b7f15e04d82990ceaf Author: Jordan Justen <jordan.l.justen@intel.com> Date: Sun Mar 6 23:30:29 2016 -0800 drm/i915: Add Haswell CS GPR registers to whitelist This is needed for the Mesa Vulkan driver on Haswell. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1457335830-30923-5-git-send-email-jordan.l.justen@intel.com drivers/gpu/drm/i915/i915_cmd_parser.c | 16 ++++++++++++++++ drivers/gpu/drm/i915/i915_reg.h | 4 ++++ 2 files changed, 20 insertions(+) commit 99c5aeca94a506a2b279022fae5de3f8606730bd Author: Jordan Justen <jordan.l.justen@intel.com> Date: Sun Mar 6 23:30:28 2016 -0800 drm/i915: Move Haswell registers to separate whitelist table Now that we can whitelist registers only on Haswell, move HSW_SCRATCH1 and HSW_ROW_CHICKEN3 into a separate Haswell only table. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Cc: Francisco Jerez <currojerez@riseup.net> Reviewed-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1457335830-30923-4-git-send-email-jordan.l.justen@intel.com drivers/gpu/drm/i915/i915_cmd_parser.c | 4 ++++ 1 file changed, 4 insertions(+) commit 361b027bc6ae8501756829043ac98e42e40494f8 Author: Jordan Justen <jordan.l.justen@intel.com> Date: Sun Mar 6 23:30:27 2016 -0800 drm/i915: Use an array of register tables in command parser For Haswell, we will want another table of registers while retaining the large common table of whitelisted registers shared by all gen7 devices. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net> [danvet: Pipe patch through sed -e 's/\<ring\>/engine/g' to make it apply.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_cmd_parser.c | 101 +++++++++++++++++++++++--------- drivers/gpu/drm/i915/intel_ringbuffer.h | 13 +--- 2 files changed, 75 insertions(+), 39 deletions(-) commit a6573e1f54b713f837ac08d87961f610c63246ba Author: Jordan Justen <jordan.l.justen@intel.com> Date: Sun Mar 6 23:30:26 2016 -0800 drm/i915: Add TIMESTAMP to register whitelist This is needed for the Mesa Vulkan driver on Haswell. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Cc: Kristian Høgsberg <krh@bitplanet.net> Cc: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1457335830-30923-2-git-send-email-jordan.l.justen@intel.com drivers/gpu/drm/i915/i915_cmd_parser.c | 1 + 1 file changed, 1 insertion(+) commit 5b086414293f906d8c5692cbbfa3500458982e5d Author: Golan Ben-Ami <golan.ben.ami@intel.com> Date: Tue Feb 9 12:57:16 2016 +0200 iwlwifi: mvm: support dumping UMAC internal txfifos In case of FW error, support dumping the UMAC internal txfifos. To do so, support version 2 of shared memory cfg command, which contains the sizes of the internal txfifos, and move the command to the system group. Signed-off-by: Golan Ben-Ami <golan.ben.ami@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> .../net/wireless/intel/iwlwifi/iwl-fw-error-dump.h | 1 + drivers/net/wireless/intel/iwlwifi/iwl-fw-file.h | 3 + drivers/net/wireless/intel/iwlwifi/iwl-prph.h | 12 ++++ drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h | 17 ++++- drivers/net/wireless/intel/iwlwifi/mvm/fw-dbg.c | 79 +++++++++++++++++++++- drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 28 +++++++- drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 3 + drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 8 +++ 8 files changed, 146 insertions(+), 5 deletions(-) commit cd47a3d3c72825b5feeb31c1974b0dc875692481 Author: Matti Gottlieb <matti.gottlieb@intel.com> Date: Thu Mar 10 16:18:26 2016 +0200 iwlwifi: mvm: make sure FW contains the right amount of paging sections Paging contains 3 sections in the fw. The first for the paging separator, The second for the CSS block, the third with the paging data. Currently if the driver finds the paging separator, and there is only section left (CSS), once reading the CSS section, the driver will attempt to read the paging data and will go out of the arrays bounds. Make sure that the FW image contains the right amount of sections for paging. Signed-off-by: Matti Gottlieb <matti.gottlieb@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit a9b72c90fc1a7cd547a333e382b3a7c2201fc3e4 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Thu Mar 17 17:43:26 2016 +0100 iio:magnetometer:ak8975: fix missing regulator_disable Ensure optional regulator is properly disabled when present. Fixes: 63d5d525cbbc ("iio:magnetometer:ak8975: power regulator support") Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/ak8975.c | 78 ++++++++++++++++++++++++++++++--------- 1 file changed, 60 insertions(+), 18 deletions(-) commit 9e61d901155bcd4e58cbce5eb4aaa8e870267334 Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Thu Mar 17 19:25:11 2016 +0530 iio: light: tsl2563: Remove flush_scheduled_work flush_scheduled_work is scheduled for deprecation. Replace cancel_delayed_work and flush_scheduled_work with cancel_delayed_work_sync instead to ensure there is no pending or running work item. Since there is only one work item, chip->poweroff_work, there are no further dependencies of flush_scheduled_work(). Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/light/tsl2563.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 334ecdd0ba45bb68bce0f1429a4a1e9584ba437e Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Thu Mar 17 12:55:03 2016 +0100 iio:pressure:ms5611: fix missing regulator_disable Ensure optional regulator is properly disabled when present. Fixes: 3145229f9191 ("iio:pressure:ms5611: power regulator support") Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/ms5611.h | 3 +++ drivers/iio/pressure/ms5611_core.c | 41 +++++++++++++++++++++++++++++--------- 2 files changed, 35 insertions(+), 9 deletions(-) commit 718ba46e5f4e21e45141bf55fd4cccd4b3ba9939 Author: Daniel Baluta <daniel.baluta@intel.com> Date: Thu Mar 17 18:32:44 2016 +0200 iio: imu: mpu6050: Fix name/chip_id when using ACPI When using ACPI, id is NULL and the current code automatically defaults name to NULL and chip id to 0. We should instead use the data provided in the ACPI device table. Fixes: c816d9e7a57b ("iio: imu: mpu6050: fix possible NULL dereferences") Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Reviewed-By: Matt Ranostay <matt.ranostay@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) commit c94d7996db64582770103b178ea4060516d7e646 Author: Matti Gottlieb <matti.gottlieb@intel.com> Date: Wed Mar 9 10:54:10 2016 +0200 iwlwifi: mvm: Decrease size of the paging download buffer Currently the driver has 2 buffers for paging: 1. paging db - this contains all of the pages that were in the FW image, that the driver stores for the FW. This is allocated for each block separately (not contiguous). 2. download buffer - we need to provide this empty buffer for the iwl_sdio_load_fw_chunk function to copy the requested pages to the shared memory. This is one big buffer of contiguous memory whose size is the size of all the blocks that the fw paging section can contain. This download buffer size is too big, and causes the allocation to fail sometimes. Since the driver allocates memory for each block separately, it is not possible for the FW to request all of the pages in one request (the FW gives an address and size, so blocks need to be contiguous for this to happen), therefore the FW is limited to request only one block. Decrease the size of the paging download buffer to be the size of a paging block. Signed-off-by: Matti Gottlieb <matti.gottlieb@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) commit 01d11cd12d85e88518eb884891e115cb4bf696a2 Author: Sara Sharon <sara.sharon@intel.com> Date: Wed Mar 9 17:38:47 2016 +0200 iwlwifi: pcie: clear trans reference on queue stop Currently when stop flow is performed, there might be transport TX RTPM references that are not freed in case we unmap a queue that still has packets not reclaimed. Fix that. Signed-off-by: Sara Sharon <sara.sharon@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 59 +++++++++++++++++----------- 1 file changed, 36 insertions(+), 23 deletions(-) commit ae549a72212c94c757fa3ecbcaa986cc9d2e2b96 Author: David Wu <david.wu@rock-chips.com> Date: Wed Mar 16 01:44:15 2016 +0800 iio: adc: rockchip_saradc: add saradc support for rk3399 The ADC is a 6-channel signal-ended 10-bit Successive Approximation Register (SAR) A/D Converter. Signed-off-by: David Wu <david.wu@rock-chips.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/adc/rockchip-saradc.txt | 6 +++++- drivers/iio/adc/rockchip_saradc.c | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+), 1 deletion(-) commit 722fc31663d506d668e6a3bea4e9dca8ab957d3a Author: Alison Schofield <amsfield22@gmail.com> Date: Tue Mar 15 11:49:12 2016 -0700 staging: iio: isl29028: use regmap to retrieve struct device Driver includes struct regmap and struct device in its global data. Remove the struct device and use regmap API to retrieve device info. Simplified version of Coccinelle semantic patch used: @ a @ identifier drvdata, r; position p; @@ struct drvdata@p { ... struct regmap *r; ... }; @ b @ identifier a.drvdata, d; position a.p; @@ struct drvdata@p { ... - struct device *d; ... }; @ passed depends on b @ identifier a.drvdata, a.r, b.d, i, f; @@ f (..., struct drvdata *i ,...) { + struct device *dev = regmap_get_device(i->r); <+... - i->d + dev ...+> } Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/light/isl29028.c | 55 ++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 25 deletions(-) commit 6ad515c6d6beea3cbb8557ba2b0f57c39301b0f7 Author: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Date: Tue Mar 15 22:54:51 2016 +0100 tools: iio: Update iio_event_monitor names add recently added channel types and modifiers Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> tools/iio/iio_event_monitor.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) commit bce59b602dace036b797144b1a5851318cbc85f0 Author: Martin Kepplinger <martink@posteo.de> Date: Mon Mar 14 12:26:29 2016 +0100 iio: mma8452: use runtime pm instead of device specific autosleep What is this autosleep? ----------------------- It slows down the device after x seconds of inactivity. The thing is, we have really achieved almost the same by runtime pm. differnces are: autosleep * uses more power during inactivity * the first read after inactivity slightly faster * complicated to understand for the user * no documented sysfs interface (afaik) * complicated to read and maintain runtime pm * already merged in mma8452 * uses less power during inactivity * first read after inactivity slower * easy to use. well documented. * easy to maintain and understand The two approaches solve the same problem. runtime pm has more advantages than autosleep and comes quite close to it's behaviour anyways. As I see it, autosleep, even if somehow supported, would never be used anyways. So resolve this issue by "ignoring" autosleep. Signed-off-by: Martin Kepplinger <martink@posteo.de> Reviewed-by: Martina Kepplinger <martina.novakovic@zoho.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma8452.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit ddb851affbb8a669cdfe237745aaab7523a31919 Author: Martin Kepplinger <martink@posteo.de> Date: Mon Mar 14 12:33:14 2016 +0100 iio: mma8452: add i2c_device_id for mma8451 This was forgotten about and is added for consistency now Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma8452.c | 1 + 1 file changed, 1 insertion(+) commit 4fbcfa09f9e7b8b51af23bacf6e9adc45b6d0f3b Author: Peter Meerwald <pmeerw@pmeerw.net> Date: Sun Mar 13 16:02:22 2016 +0100 iio: ABI: Fix typo in in_proximity_raw description Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> Documentation/ABI/testing/sysfs-bus-iio | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 6fca5aa8658e61bf01158c4262cabcd8d7f72533 Author: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Date: Sun Mar 13 16:22:33 2016 +0100 MAINTAINERS: update pmeerw's name happily married for 4 month :) Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org> MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit d03b65967c902f4e8c0bd139542a9e4a7cc9a10d Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Mar 12 13:30:17 2016 +0100 dt: document NXP LPC1850 DAC driver bindings Signed-off-by: Joachim Eastwood <manabian@gmail.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/dac/lpc1850-dac.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) commit d15d7538c6d210b2a10df94d131b70b025ee9cd2 Author: Imre Deak <imre.deak@intel.com> Date: Fri Mar 18 10:46:10 2016 +0200 drm/i915: Tune down init error message due to failure injection Atm, in case failure injection forces an error the subsequent "*ERROR* failed to init modeset" error message will make automated tests (CI) report this event as a breakage even though the event is expected. To fix this print the error message with debug log level in this case. While at it print the error message for any init failure and change it to """ Device initialization failed (errno) Please file a bug at https://bugs.freedesktop.org/enter_bug.cgi?product=DRI against DRM/Intel providing the dmesg log by booting with drm.debug=0xf """ and export a helper printing error messages using this same format. A follow-up patch will convert all uses of DRM_ERROR reporting a user facing problem to use this new helper instead. v2: - Include the problematic error message in the commit log, add a request to file an fdo bug to the message (Chris) v3: - Include the new error message too in the commit log, make the fdo link more precise and print part of the message with info log level (Chris) v4: (Chris) - Use dev_printk instead of DRM_ERROR/INFO and use NOTICE instead of INFO loglevel - Export a helper for printing user facing error messages v5: - Keep the DRM_ERROR message prefix used by piglit-igt/CI to filter relevant dmesg lines - Use dev_notice(), instead of dev_printk(KERN_NOTICE,...) v6: - Print the fdo bug link only once (Chris) CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458290770-15480-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 51 +++++++++++++++++++++++++++++++++++++---- drivers/gpu/drm/i915/i915_drv.h | 7 ++++++ 2 files changed, 53 insertions(+), 5 deletions(-) commit c890e2d5313e8e8f4fb54258dc2bbb2c7dd901ce Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Fri Mar 18 10:42:59 2016 +0200 drm/i915: Codify our assumption that the Global GTT is <= 4GiB Throughout the code base, we use u32 for offsets into the global GTT. If we ever see any hardware with a larger GGTT, then we run the real risk of silent corruption. So test for our assumption up front so that we have a nice reminder should the time come when it fails. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Daniel Vetter <daniel@ffwll.ch> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> [Rebased and changed 1ull -> 1ULL, cut 80 char line] Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458290579-27783-1-git-send-email-joonas.lahtinen@linux.intel.com drivers/gpu/drm/i915/i915_gem_gtt.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit d507d73578ef7aa1ffcd122e51caa59e4492cb46 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Fri Mar 18 10:42:58 2016 +0200 drm/i915/gtt: Clean up GGTT probing code Use less pointers with the probing code, making it much less confusing to read. Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_gem_gtt.c | 100 ++++++++++++++++-------------------- drivers/gpu/drm/i915/i915_gem_gtt.h | 5 +- 2 files changed, 46 insertions(+), 59 deletions(-) commit 62106b4f6b9118073ec59e3e34ec393ed76cf24f Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Fri Mar 18 10:42:57 2016 +0200 drm/i915: Rename dev_priv->gtt to dev_priv->ggtt Refer to Global GTT consistently as GGTT, thus rename dev_priv->gtt to dev_priv->ggtt and struct i915_gtt to struct i915_ggtt. Fix a couple of whitespace problems while at it. v2: - Fix a typo in commit message. Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_debugfs.c | 8 +- drivers/gpu/drm/i915/i915_dma.c | 18 ++-- drivers/gpu/drm/i915/i915_drv.h | 4 +- drivers/gpu/drm/i915/i915_gem.c | 16 ++-- drivers/gpu/drm/i915/i915_gem_context.c | 2 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 6 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 147 ++++++++++++++--------------- drivers/gpu/drm/i915/i915_gem_gtt.h | 9 +- drivers/gpu/drm/i915/i915_gem_stolen.c | 50 +++++----- drivers/gpu/drm/i915/i915_gpu_error.c | 10 +- drivers/gpu/drm/i915/i915_vgpu.c | 14 +-- drivers/gpu/drm/i915/intel_display.c | 4 +- drivers/gpu/drm/i915/intel_fbc.c | 4 +- drivers/gpu/drm/i915/intel_fbdev.c | 6 +- drivers/gpu/drm/i915/intel_overlay.c | 4 +- drivers/gpu/drm/i915/intel_pm.c | 10 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 2 +- 17 files changed, 156 insertions(+), 158 deletions(-) commit dc3b04fbf43227e21fa95dbe6c7a13def655c891 Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Date: Fri Mar 18 10:42:56 2016 +0200 drm/i915/gtt: Reference mappable_end variable from pointer Reference variable value from pointer, not assumed pointer destination. Since: commit c44ef60e437019b8ca1dab8b4d2e8761fd4ce1e9 Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Thu Jun 25 18:35:05 2015 +0300 drm/i915/gtt: Allow >= 4GB sizes for vm. Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> drivers/gpu/drm/i915/i915_gem_gtt.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 950b2aaeea6960561425fc80adfb5b2fc0ac020f Author: Tim Gore <tim.gore@intel.com> Date: Wed Mar 16 16:13:46 2016 +0000 drm/i915/gen9: add WaClearFlowControlGpgpuContextSave This allows writes to EU flow control registers. Together with SIP code from the user-mode driver this resolves a hang seen in some pre-emption scenarios. Note that this patch is just the kernel mode part of this workaround. v2. Oops, add FLOW_CONTROL_ENABLE macro to i915_reg.h. Signed-off-by: Tim Gore <tim.gore@intel.com> Reviewed-by: Arun Siluvery <arun.siluvery@linux.intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458144826-17269-1-git-send-email-tim.gore@intel.com drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_ringbuffer.c | 2 ++ 2 files changed, 3 insertions(+) commit d4e44f1418d71cf53d685e236a95c525089e065a Author: Peter Ujfalusi <peter.ujfalusi@ti.com> Date: Fri Mar 18 12:28:49 2016 +0200 ASoC: omap-mcbsp: Enable/disable sidetone block auto clock gating for omap3 OMAP3's McBSP2 and McBSP3 module have integrated sidetone block with dedicated SYSCONFIG register. The sidetone is operating from the maain McBSP module's ICLK. For normal operation the sidetone clock auto idle support needs to be disabled when it is activated. Note: This is not enough to avoid choppy sidetone because this AUTOIDLE bit is controlling only the clock auto idle from the McBSP to the sidetone block. If the McBSP_ICLK is idling, the sidetone clock is going to do the same. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org> sound/soc/omap/mcbsp.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 26720ab97feac7153a7b5c3c79cf5d53a8531126 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 17 12:59:46 2016 +0000 drm/i915: Move CSB MMIO reads out of the execlists lock By reading the CSB (slow MMIO accesses) into a temporary local buffer we can decrease the duration of holding the execlist lock. Main advantage is that during heavy batch buffer submission we reduce the execlist lock contention, which should decrease the latency and CPU usage between the submitting userspace process and interrupt handling. Downside is that we need to grab and relase the forcewake twice, but as the below numbers will show this is completely hidden by the primary gains. Testing with "gem_latency -n 100" (submit batch buffers with a hundred nops each) shows more than doubling of the throughput and more than halving of the dispatch latency, overall latency and CPU time spend in the submitting process. Submitting empty batches ("gem_latency -n 0") does not seem significantly affected by this change with throughput and CPU time improving by half a percent, and overall latency worsening by the same amount. Above tests were done in a hundred runs on a big core Broadwell. v2: * Overflow protection to local CSB buffer. * Use closer dev_priv in execlists_submit_requests. (Chris Wilson) v3: Rebase. v4: Added commend about irq needed to be disabled in execlists_submit_request. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilsno <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458219586-20452-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/intel_lrc.c | 79 ++++++++++++++++++++-------------------- 1 file changed, 40 insertions(+), 39 deletions(-) commit 39dabecd991b0a914f044af5824774825fb0923e Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 17 13:04:10 2016 +0000 drm/i915: Use shorter route to dev_private where possible Where we have a request we can use req->i915 directly instead of going through the engine and device. Coccinelle script: @@ function f; identifier r; @@ f(..., struct drm_i915_gem_request *r, ...) { ... - engine->dev->dev_private + r->i915 ... } @@ struct drm_i915_gem_request *req; @@ ( req-> - engine->dev->dev_private + i915 ) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458219850-21007-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_gem.c | 2 +- drivers/gpu/drm/i915/i915_gem_context.c | 4 ++-- drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) commit a112dbad44c4584ca565333d58d1bbb38799c12d Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 17 13:04:09 2016 +0000 drm/i915: Remove unused variable in i915_gem_request_add_to_client Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_gem.c | 2 -- 1 file changed, 2 deletions(-) commit bf031bc4d6a168029b8a640373fd00837746b47d Author: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Date: Tue Mar 15 15:25:53 2016 +0530 ath10k: advertise force AP scan feature Results obtained from scan can be used for spectrum management by doing something like building information of preferred channel lists and sharing them with stations around. It is to be noted that traffic to the connected stations would be affected during the scan. Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit 9ddc486aa09a3413a6c492fcf160ce61bfccb7b1 Author: Anilkumar Kolli <akolli@qti.qualcomm.com> Date: Fri Mar 11 11:46:39 2016 +0530 ath10k: fix debugfs pktlog_filter write It is observed that, we are disabling the packet log if we write same value to the pktlog_filter for the second time. Always enable pktlogs on non zero filter. Fixes: 90174455ae05 ("ath10k: add support to configure pktlog filter") Cc: stable@vger.kernel.org Signed-off-by: Anilkumar Kolli <akolli@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/debug.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit b9c191be3fbdd9d78be11160dd7a3ddb9fdc6d42 Author: Raja Mani <rmani@qti.qualcomm.com> Date: Thu Mar 10 10:25:07 2016 +0530 ath10k: free cached fw bin contents when get board id fails ath10k_core_probe_fw() simply returns error without freeing cached firmware file content when get board id operation fails. Free cached fw bin data in failure case to avoid memory leak. Fixes: db0984e51a18 ("ath10k: select board data based on BMI chip id and board id") Signed-off-by: Raja Mani <rmani@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit cac085524cf16434ac1d42427a8644cf532d3e87 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Mar 9 20:25:46 2016 +0530 ath10k: move mgmt descriptor limit handle under mgmt_tx Frames that are transmitted via MGMT_TX are using reserved descriptor slots in firmware. This limitation is for the htt_mgmt_tx path itself, not for mgmt frames per se. In 16 MBSSID scenario, these reserved slots will be easy exhausted due to frequent probe responses. So for 10.4 based solutions, probe responses are limited by a threshold (24). management tx path is separate for all except tlv based solutions. Since tlv solutions (qca6174 & qca9377) do not support 16 AP interfaces, it is safe to move management descriptor limitation check under mgmt_tx function. Though CPU improvement is negligible, unlikely conditions or never hit conditions in hot path can be avoided on data transmission. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 10 +++---- drivers/net/wireless/ath/ath10k/htt_rx.c | 7 ++++- drivers/net/wireless/ath/ath10k/htt_tx.c | 50 ++++++++++++++++++++------------ drivers/net/wireless/ath/ath10k/mac.c | 26 +++++++++++------ drivers/net/wireless/ath/ath10k/txrx.c | 18 +++++------- drivers/net/wireless/ath/ath10k/txrx.h | 4 +-- 6 files changed, 68 insertions(+), 47 deletions(-) commit 2ce9b25cefa64f11bcb21b21cf4a5e8c58c6d0af Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Tue Mar 8 22:57:23 2016 +0530 ath10k: handle channel change htt event Whenever firmware is configuring operating channel during scan or home channel, channel change event will be indicated to host. In some cases (device probe/ last vdev down), target will be configured to default channel whereas host is unaware of target's operating channel. This leads to packet drop due to unknown channel and kernel log will be filled up with "no channel configured; ignoring frame(s)!". Fix that by handling HTT_T2H_MSG_TYPE_CHAN_CHANGE event. Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 3 +++ drivers/net/wireless/ath/ath10k/htt.h | 9 +++++++ drivers/net/wireless/ath/ath10k/htt_rx.c | 41 +++++++++++++++++++++++++++++++- drivers/net/wireless/ath/ath10k/wmi.c | 28 ---------------------- 4 files changed, 52 insertions(+), 29 deletions(-) commit d3d6f15fd376e3dbba851724057b112558c70b79 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 15:43:57 2016 +0000 clk: bcm2835: add missing osc and per clocks Add AVE0, DFT, GP0, GP1, GP2, SLIM, SMI, TEC, DPI, CAM0, CAM1, DSI0E, and DSI1E. PULSE is not added because it has an extra divider. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 90 +++++++++++++++++++++++++++++++++++++ include/dt-bindings/clock/bcm2835.h | 14 ++++++ 2 files changed, 104 insertions(+) commit 728436956aa172b24a3212295f8b53feb6479f32 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 15:43:56 2016 +0000 clk: bcm2835: add missing PLL clock dividers Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 32 ++++++++++++++++++++++++++++++++ include/dt-bindings/clock/bcm2835.h | 5 +++++ 2 files changed, 37 insertions(+) commit 33b689600f43094a9316a1b582f2286d17bc737b Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 12:51:43 2016 +0000 clk: bcm2835: enable management of PCM clock Enable the PCM clock in the SOC, which is used by the bcm2835-i2s driver. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 7 +++++++ include/dt-bindings/clock/bcm2835.h | 1 + 2 files changed, 8 insertions(+) commit 3b15afefbef9b5952e3d68ad73d93f981b9faca8 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 12:51:42 2016 +0000 clk: bcm2835: reorganize bcm2835_clock_array assignment Reorganize bcm2835_clock_array so that there is no more need for separate bcm2835_*_data structures to be defined. Instead the required structures are generated inline via helper macros. To allow this to also work for pll alone it was required that the parent_pll was changed from a pointer to bcm2835_pll_data to the name of the pll instead. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 852 +++++++++++++++++++----------------------- 1 file changed, 393 insertions(+), 459 deletions(-) commit 56eb3a2ed9726961e1bcfa69d4a3f86d68f0eb52 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 12:51:41 2016 +0000 clk: bcm2835: remove use of BCM2835_CLOCK_COUNT in driver As the use of BCM2835_CLOCK_COUNT in include/dt-bindings/clock/bcm2835.h is frowned upon as it needs to get modified every time a new clock gets introduced this patch changes the clk-bcm2835 driver to use a different scheme for registration of clocks and pll, so that there is no more need for BCM2835_CLOCK_COUNT to be defined. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 167 ++++++++++++++++++++---------------- include/dt-bindings/clock/bcm2835.h | 2 - 2 files changed, 94 insertions(+), 75 deletions(-) commit 96bf9c69d5729781018a00f08e2ae395ec3346b4 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 14:20:15 2016 +0000 clk: bcm2835: expose raw clock-registers via debugfs For debugging purposes under some circumstance it helps to be able to see the actual clock registers. E.g: when looking at the clock divider it is helpful to see what the actual clock divider is. This patch exposes all the clock registers specific to each clock/pll/pll-divider via debugfs. Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Acked-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 101 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) commit 6e1e60dacee7b32aef1468ea461b02e4c7a90a45 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 11:39:22 2016 +0000 clk: bcm2835: clean up coding style issues Fix all the checkpatch complaints for clk-bcm2835.c Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) commit 959ca92a3235fc4b17c1e18483fc390b3d612254 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 11:39:21 2016 +0000 clk: bcm2835: correctly enable fractional clock support The current driver calculates the clock divider with fractional support enabled. But it does not enable fractional support in the control register itself resulting in an integer only divider, but in clk_set_rate responds back the fractionally divided clock frequency. This patch enables fractional support in the control register whenever there is a fractional bit set in the requested clock divider. Mash clock limits are are also handled for the PWM clock applying the correct divider limits (2 and max_int) applicable to basic fractional divider support (mash order of 1). It also adds locking to protect the read/modify/write cycle of the register modification. Fixes: 41691b8862e2 ("clk: bcm2835: Add support for programming the audio domain clocks") Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 45 +++++++++++++++++++++++++++++++++++++------ 1 file changed, 39 insertions(+), 6 deletions(-) commit 997f16bd5d2e9b3456027f96fcadfe1e2bf12f4e Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 11:39:20 2016 +0000 clk: bcm2835: divider value has to be 1 or more Current clamping of a normal divider allows a value < 1 to be valid. A divider of < 1 would actually only be possible if we had a PLL... So this patch clamps the divider to 1. Fixes: 41691b8862e2 ("clk: bcm2835: Add support for programming the audio domain clocks") Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) commit ec36a5c6682fdd5328abf15c3c67281bed0241d7 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 11:39:18 2016 +0000 clk: bcm2835: add locking to pll*_on/off methods Add missing locking to: * bcm2835_pll_divider_on * bcm2835_pll_divider_off to protect the read modify write cycle for the register access protecting both cm_reg and a2w_reg registers. Fixes: 41691b8862e2 ("clk: bcm2835: Add support for programming the audio domain clocks") Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 4 ++++ 1 file changed, 4 insertions(+) commit 6727f086cfe4ddcc651eb2bf4301abfcf619be06 Author: Martin Sperl <kernel@martin.sperl.org> Date: Mon Feb 29 11:39:17 2016 +0000 clk: bcm2835: pll_off should only update CM_PLL_ANARST bcm2835_pll_off is currently assigning CM_PLL_ANARST to the control register, which may lose the other bits that are currently set by the clock dividers. It also now locks during the read/modify/write cycle of both registers. Fixes: 41691b8862e2 ("clk: bcm2835: Add support for programming the audio domain clocks") Signed-off-by: Martin Sperl <kernel@martin.sperl.org> Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Eric Anholt <eric@anholt.net> drivers/clk/bcm/clk-bcm2835.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) commit 4fec15d1bd8352b6fc1edd71ae35ab138df010fc Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:08 2016 +0200 drm/i915: Add fault injection support Add support for forcing an error at selected places in the driver. As an example add 4 options to fail during driver loading. Requested by Chris. v2: - Add fault point for modeset initialization - Print debug message when injecting an error v3: - Rename inject_fault to inject_load_failure, rename the related macros and helper accordingly (Chris) - Use a counter instead of a mask to identify the failure point (Daniel) - Mark the module option as _unsafe and keep i915_params ordered (Joonas) v4: - Rebase on latest -nightly v5: - Use DRM_INFO instead of DRM_DEBUG_DRIVER, making it clearer in CI reports that a following error message is expected (IRC r-b from Chris on v5) CC: Chris Wilson <chris@chris-wilson.co.uk> CC: Daniel Vetter <daniel.vetter@ffwll.ch> CC: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_dma.c | 27 +++++++++++++++++++++++++++ drivers/gpu/drm/i915/i915_drv.h | 4 ++++ drivers/gpu/drm/i915/i915_params.c | 4 ++++ drivers/gpu/drm/i915/i915_params.h | 1 + 4 files changed, 36 insertions(+) commit 65ff442f6bca0e2247ff7acac6014bcea69d1f7e Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:07 2016 +0200 drm/i915: Fix power domain HW state cleanup on error path Move the cleanup of the power domain HW state on the error path to the same function where the corresponding init call was called from. I noticed this problem when loading the module with load failure injection enabled, making i915_load_modeset_init() fail. CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-19-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 432f856d8b4963f2f1d95844794266d7c9a9ca97 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:06 2016 +0200 drm/i915: Split out load time interface registration According to the new init phases scheme we should register the device making it available via some kernel internal or user space interface as the last step in the init sequence, so move the corresponding code to a separate function. Also add a TODO comment about code that still needs to be moved around to one of the init phases functions depending on what the role and effect of that code is. No functional change, except for the reordering of the unload time unregistration steps of sysfs wrt. acpi and opregion. Suggested by Chris. v3: - rename i915_driver_init_register to i915_driver_init_frameworks (Chris) - rename i915_driver_init_frameworks to i915_driver_register (Daniel) CC: Chris Wilson <chris@chris-wilson.co.uk> CC: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-18-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 83 +++++++++++++++++++++++++++-------------- 1 file changed, 54 insertions(+), 29 deletions(-) commit 09cfcb456941222021f378131b1b2fa4c59cc495 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:05 2016 +0200 drm/i915: Split out load time HW initialization According to the new init phases scheme we should have a definite step in the init sequence where we setup things requiring accessing the device, so move the corresponding code to separate function. The steps in this init phase should avoid exposing the driver via some interface, which is done in the last registration init phase. This changae also has the benefit of making the error path cleaner both in the new function and i915_driver_load()/unload(). No functional change. Suggested by Chris. CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-17-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 122 ++++++++++++++++++++++++---------------- 1 file changed, 75 insertions(+), 47 deletions(-) commit f28cea45e5a9e1680753ce1b91f033dc3ceda7d0 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:04 2016 +0200 drm/i915: Split out load time MMIO initialization According to the new init phases scheme we should have a definite step in the init sequence where MMIO access is setup, so move the corresponding code to a separate function. This also has the benefit of making the error path cleaner both in the new function and in i915_driver_load()/unload(). No functional change. Suggested by Chris. Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-16-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 69 +++++++++++++++++++++++++++++------------ 1 file changed, 50 insertions(+), 19 deletions(-) commit 5d7a6eefc3b025725dd1b5a643e90ce068e9dbd4 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:03 2016 +0200 drm/i915: Split out load time early initialization According to the new init phases scheme we should initialize "SW-only" state not requiring accessing the device as the very first step, so that the reasoning about dependencies of later steps becomes easier. So move these init steps into a separate function. This also has the benefit of making the error path cleaner both in the new function and int i915_driver_load()/unload(). No functional change. Suggested by Chris. CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-15-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 130 +++++++++++++++++++++++++--------------- 1 file changed, 81 insertions(+), 49 deletions(-) commit fbf107bdbd449494e6b17589f0a8a02094b52a19 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:02 2016 +0200 drm/i915: Move unload time opregion unregistration earlier Move the opregion unregistration earlier to match its corresponding registration order. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-14-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 882c5a83b5116bff597aefec16ad016641dfea05 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:01 2016 +0200 drm/i915: Move unload time GTT, MSI IRQ cleanup later Move the GTT,MSI IRQ cleanup later so that it matches their corresponding init order. Also fix the order of these calls wrt. each other to match their corresponding init order. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-13-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) commit 250ad48e2e2f2aeebafd52d67768392eca5077ad Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:39:00 2016 +0200 drm/i915: Move unload time display power domain uninit later Move the power domain uninitialization later so that it matches its corresponding init order. Since we access the HW during the later unitialization steps keep a wake reference until after the last such step. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-12-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) commit 3487b66ba13c1a7ba1185028ad0dae95e97bd4d2 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:59 2016 +0200 drm/i915: Move load time audio component registration earlier We should register all the interfaces before we enable runtime PM. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-11-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 80741e99282a3672a2259386f3f1dc4c3ef3d54f Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:58 2016 +0200 drm/i915: Move load time shrinker registration later According to the new init phases scheme we should register the driver with frameworks/userspace only one the device is setup fully. So move the shrinker registration later accordingly. Also fix the shrinker unregistration order wrt. the acpi unregistration to fix the corresponding init order. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-10-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) commit 802cbbc09b96eed654233020d8f6d486ddc5123b Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:57 2016 +0200 drm/i915: Move load time runtime PM get later We require the device to be powered only before accessing it, so we can move this call later. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-9-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 40ae4e1661cd2ef67ca888b36ea636999bd0be73 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 14:54:03 2016 +0200 drm/i915: Move load time gem_load_init earlier The only steps requiring device access is the fence and swizzling initialization, so split these out keeping them in their current place and move the rest of init steps earlier. v2-v3: - unchanged v4: - move call to i915_gem_detect_bit_6_swizzle() to i915_gem_load_init_fences() and preserve the original order of the detection of HW fence capailities wrt. swizzling (Chris) CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458132843-21860-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 12 +++++++----- drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gem.c | 38 ++++++++++++++++++++++++-------------- 3 files changed, 32 insertions(+), 19 deletions(-) commit 13c8f4c8cd481ec80bfe3b71f1f21e18bad98efb Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:55 2016 +0200 drm/i915: Move load time runtime device info init earlier This init step accesses the device, but doesn't have any device specific side effect. It also sets up some platform specific attributes that may be required early, so move it earlier. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-7-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit bb400da99836793ade6f1a007db58af2f1b57e9e Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:54 2016 +0200 drm/i915: Move load time init of clock gating hooks earlier Split out the part initing the clock gating hooks and move it earlier. Add a new NOP hook for platforms without the need to apply clockgating or workaround settings, so that the hook can be called unconditionally. Also add a WARN for future platforms that forget to add a hook. The rest of the hooks in intel_init_pm() should be inited in the same way, but atm some of the hooks are set only conditionally, so before doing this we need to make the setup unconditional and use instead some flags. v2: - add a NOP hook and WARN if no hook is set for the platform (Chris) - use the term hook instead of callback for these functions (Jani) v3: - remove the GEN4() check it's already covered by earlier platform checks (Chris) CC: Jani Nikula <jani.nikula@intel.com> CC: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-6-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 1 + drivers/gpu/drm/i915/intel_drv.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 90 ++++++++++++++++++++++++---------------- 3 files changed, 57 insertions(+), 35 deletions(-) commit 8821294172f0f807b7928909aeadd4e7467d2ed0 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:53 2016 +0200 drm/i915: Move load time init of display/audio hooks earlier All of this is SW only initialization so we can move them earlier. Move the mutex init where the rest of the locks are inited. While at it also convert dev to dev_priv. v2: - use the term hook instead of callback for these functions (Jani) CC: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-5-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 3 ++ drivers/gpu/drm/i915/intel_audio.c | 16 +++---- drivers/gpu/drm/i915/intel_display.c | 82 +++++++++++++++++------------------- drivers/gpu/drm/i915/intel_drv.h | 3 +- 4 files changed, 51 insertions(+), 53 deletions(-) commit bd39ec5ddae8807644196cadbb62bb2b3d88607b Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:52 2016 +0200 drm/i915: Move load time IRQ SW init earlier Most of the IRQ init is setting up hooks so move that part earlier. Leave the pm_qos_add_request() call in place. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 5 ++++- drivers/gpu/drm/i915/i915_irq.c | 2 -- 2 files changed, 4 insertions(+), 3 deletions(-) commit 861f878e6a7a8bc152c92de358b96eb3bd086f78 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:51 2016 +0200 drm/i915: Move load time PCH detect, DPIO, power domain SW init earlier These are all SW only init steps not accessing the device and they only need the platform identification macros to work, which are already available earlier, so move these init steps earlier. Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-3-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) commit 066de1aadf6aba1911560cf90a5bc8e25ca1aae9 Author: Imre Deak <imre.deak@intel.com> Date: Wed Mar 16 13:38:50 2016 +0200 Fix MCHBAR cleanup on the driver init error path MCHBAR is cleaned up in i915_mmio_cleanup(), so the separate call in i915_driver_load() is incorrect. CC: David Weinehall <david.weinehall@intel.com> Fixes: ad5c3d3ffbb2 ("drm/i915: Move MCHBAR setup earlier during init") Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: David Weinehall <david.weinehall@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458128348-15730-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_dma.c | 1 - 1 file changed, 1 deletion(-) commit ee4b6faf96a990d2acc30084f4edf015ca21b9c4 Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Mar 16 17:54:00 2016 +0200 drm/i915: Modify reset func to handle per engine resets In full gpu reset we prime all engines and reset domains corresponding to each engine. Per engine reset is just a special case of this process wherein only a single engine is reset. This change is aimed to modify relevant functions to achieve this. There are some other steps we carry out in case of engine reset which are addressed in later patches. Reset func now accepts a mask of all engines that need to be reset. Where per engine resets are supported, error handler populates the mask accordingly otherwise all engines are specified. v2: ALL_ENGINES mask fixup, better for_each_ring_masked (Chris) v3: Whitespace fixes (Chris) v4: Rebase due to s/ring/engine Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458143640-20563-1-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/i915_drv.c | 2 +- drivers/gpu/drm/i915/i915_drv.h | 8 ++- drivers/gpu/drm/i915/i915_gem.c | 14 +++--- drivers/gpu/drm/i915/i915_gem_context.c | 2 +- drivers/gpu/drm/i915/i915_reg.h | 2 + drivers/gpu/drm/i915/intel_uncore.c | 87 ++++++++++++++++++++++++--------- 6 files changed, 82 insertions(+), 33 deletions(-) commit 72341af4285ae1337c0dfdfa3e68318b52b8757c Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:35 2016 +0200 drm/i915: hide away VBT private data in a separate header We've been accumulating code across the driver that depends on the VBT specific structures and defines. The VBT is an uncontrollable beast. Encourage encapsulation of the VBT data by hiding the structures and defines in a private header only to be included from intel_bios.c. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-7-git-send-email-jani.nikula@intel.com Documentation/DocBook/gpu.tmpl | 2 +- drivers/gpu/drm/i915/intel_bios.c | 4 +- drivers/gpu/drm/i915/intel_bios.h | 861 ++-------------------------------- drivers/gpu/drm/i915/intel_vbt_defs.h | 826 ++++++++++++++++++++++++++++++++ 4 files changed, 865 insertions(+), 828 deletions(-) commit 52e2abb30cf0560edbb8f898d6c308e5ef80dd3f Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 18:06:58 2016 +0200 drm/i915: fix sparse warning for using false as NULL drivers/gpu/drm/i915/intel_dpll_mgr.c:1200:32: warning: Using plain integer as NULL pointer Fixes: 304b65cbdc8d ("drm/i915: Move SKL/KLB pll selection logic to intel_dpll_mgr.c") Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458144418-20046-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_dpll_mgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 15e7ec29ce5555a7b6048a1cfdaeb172de75a649 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Mon Mar 14 09:27:54 2016 +0100 drm/i915: Move pll power state to crtc power domains. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457944075-14123-4-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> drivers/gpu/drm/i915/intel_display.c | 6 +++--- drivers/gpu/drm/i915/intel_dpll_mgr.c | 4 ---- 2 files changed, 3 insertions(+), 7 deletions(-) commit a1475e775edc7bc8c0528d834d90a0ee93e57b1e Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Mon Mar 14 09:27:53 2016 +0100 drm/i915: Perform dpll commit first, v2. Warn for the wrong mask in enable only. Disable will have the wrong mask now because the new state is committed before disabling the old state. Changes since v1: - Use crtc_mask (Durgadoss) - Rebase. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457944075-14123-3-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> drivers/gpu/drm/i915/intel_display.c | 5 ++--- drivers/gpu/drm/i915/intel_dpll_mgr.c | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) commit 2dd66ebde4431c93bfa211bc967a6f2089283aa6 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Mon Mar 14 09:27:52 2016 +0100 drm/i915: Use a crtc mask instead of a refcount for dpll functions, v2. This makes it easier to verify correct dpll setup with only a single crtc. It is also useful to detect double dpll enable/disable. Changes since v1: - Rebase on top of Ander's dpll rework. - Change debugfs active to a mask. - Change enabled_crtcs and active_crtcs to unsigned. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457944075-14123-2-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> drivers/gpu/drm/i915/i915_debugfs.c | 4 ++-- drivers/gpu/drm/i915/intel_display.c | 43 +++++++++++++++++------------------ drivers/gpu/drm/i915/intel_dpll_mgr.c | 35 +++++++++++++++------------- drivers/gpu/drm/i915/intel_dpll_mgr.h | 2 +- 4 files changed, 43 insertions(+), 41 deletions(-) commit 1f7717552ef1306be3b7ed28c66c6eff550e3a23 Author: Lyude <cpaul@redhat.com> Date: Wed Mar 16 15:18:04 2016 -0400 drm/i915: Fix race condition in intel_dp_destroy_mst_connector() After unplugging a DP MST display from the system, we have to go through and destroy all of the DRM connectors associated with it since none of them are valid anymore. Unfortunately, intel_dp_destroy_mst_connector() doesn't do a good enough job of ensuring that throughout the destruction process that no modesettings can be done with the connectors. As it is right now, intel_dp_destroy_mst_connector() works like this: * Take all modeset locks * Clear the configuration of the crtc on the connector, if there is one * Drop all modeset locks, this is required because of circular dependency issues that arise with trying to remove the connector from sysfs with modeset locks held * Unregister the connector * Take all modeset locks, again * Do the rest of the required cleaning for destroying the connector * Finally drop all modeset locks for good This only works sometimes. During the destruction process, it's very possible that a userspace application will attempt to do a modesetting using the connector. When we drop the modeset locks, an ioctl handler such as drm_mode_setcrtc has the oppurtunity to take all of the modeset locks from us. When this happens, one thing leads to another and eventually we end up committing a mode with the non-existent connector: [drm:intel_dp_link_training_clock_recovery [i915]] *ERROR* failed to enable link training [drm:intel_dp_aux_ch] dp_aux_ch timeout status 0x7cf0001f [drm:intel_dp_start_link_train [i915]] *ERROR* failed to start channel equalization [drm:intel_dp_aux_ch] dp_aux_ch timeout status 0x7cf0001f [drm:intel_mst_pre_enable_dp [i915]] *ERROR* failed to allocate vcpi And in some cases, such as with the T460s using an MST dock, this results in breaking modesetting and/or panicking the system. To work around this, we now unregister the connector at the very beginning of intel_dp_destroy_mst_connector(), grab all the modesetting locks, and then hold them until we finish the rest of the function. CC: stable@vger.kernel.org Signed-off-by: Lyude <cpaul@redhat.com> Signed-off-by: Rob Clark <rclark@redhat.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458155884-13877-1-git-send-email-cpaul@redhat.com drivers/gpu/drm/i915/intel_dp_mst.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) commit ab65cce821cc46ccdc0b62f99bb79f75c1c7412c Author: Alex Dai <yu.dai@intel.com> Date: Wed Mar 16 15:24:13 2016 -0700 drm/i915/guc: Support GuC SKL v6.1 This version of GuC firmware fixes the engine reset issue where golden context LRC address is treated as page index by mistake. It also fixes the problem that scheduler stops submiting to one engine when the other engine work queue is full. Signed-off-by: Alex Dai <yu.dai@intel.com> Reviewed-by: Dave Gordon <david.s.gordon@intel.com> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com> drivers/gpu/drm/i915/intel_guc_loader.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit 7caaef332abaae872ddd2cd65bbe8a8bc0d8f5cc Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:34 2016 +0200 drm/i915/bios: drop has_mipi in favor of intel_bios_is_dsi_present Favor a single point of truth instead of duplicating the information. The change also filters out unsupported DSI ports at this stage, accepting only ports A and C, instead of waiting until the port checks. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-6-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 - drivers/gpu/drm/i915/intel_bios.c | 12 +++--------- 2 files changed, 3 insertions(+), 10 deletions(-) commit 92c4565e93609314b34bb810ba54cb73eb006987 Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:33 2016 +0200 drm/i915/panel: setup pwm backlight based on connector type Use the connector type instead of VBT directly to decide which backlight mechanism to use on VLV/CHV. (Indirectly, this is the same thing, but hides the VBT use.) Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-5-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_panel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 7137aec1cfd3fd417023ce4edd0f348e5d72115f Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:32 2016 +0200 drm/i915: move VBT based DSI presence check to intel_bios.c Hide knowledge about VBT child devices in intel_bios.c. v2: Move port check to intel_bios.c (Sivakumar) Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-4-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 2 +- drivers/gpu/drm/i915/intel_bios.c | 39 ++++++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_dsi.c | 17 ++++++++--------- 3 files changed, 47 insertions(+), 11 deletions(-) commit 951d9efe07877a3f1bb04e8932d11eafbfad02bf Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:31 2016 +0200 drm/i915: move VBT based eDP port check to intel_bios.c Hide knowledge about VBT child devices in intel_bios.c. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-3-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 33 +++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_dp.c | 21 +-------------------- 3 files changed, 35 insertions(+), 20 deletions(-) commit 5a69d13d78d730261edcf83a96704f388c6357d1 Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:30 2016 +0200 drm/i915: move VBT based LVDS presence check to intel_bios.c Hide knowledge about VBT child devices in intel_bios.c. Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-2-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 50 ++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_lvds.c | 53 +-------------------------------------- 3 files changed, 52 insertions(+), 52 deletions(-) commit 3bdd14d542c207528b6ca71946c79b39af39ea51 Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:43:29 2016 +0200 drm/i915: move VBT based TV presence check to intel_bios.c Hide knowledge about VBT child devices in intel_bios.c. v2: also move int_tv_support check to intel_bios.c (Sivakumar) Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458125015-7931-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.c | 41 ++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_tv.c | 46 +-------------------------------------- 3 files changed, 43 insertions(+), 45 deletions(-) commit 6b93e9c89ee553c1f062cd5c7dcd35e06846568f Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Mar 15 21:51:12 2016 +0200 drm/i915/bxt: fix dsi hw state pipe readout BXT isn't as limited as BYT and CHT regarding DSI pipes and ports. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/8bea85b86aaf7a15f854a656bf8d3208a3afe0bd.1458070700.git.jani.nikula@intel.com drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_dsi.c | 14 +++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) commit 1dcec2f39f128d3cb4784a0889f6c70aab675ed2 Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Mar 15 21:51:11 2016 +0200 drm/i915/dsi: refactor dsi get hw state readout Make the code easier to read and update. No functional changes. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/04b20a9be6a9481ca2eb2a42cdcdc27358152e5f.1458070700.git.jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi.c | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) commit da20563097796cdba10e253581861ad0e2b0c695 Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Mar 15 21:51:10 2016 +0200 drm/i915: make transcoder_name return a string Nicer for eDP (actually "EDP" instead of "D"), and makes future expansion for DSI transcoders easier. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/2ac55ed584e450fe154daecb6453dff8eede5e7d.1458070700.git.jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 17 ++++++++++++++++- drivers/gpu/drm/i915/intel_display.c | 4 ++-- drivers/gpu/drm/i915/intel_fifo_underrun.c | 6 +++--- 3 files changed, 21 insertions(+), 6 deletions(-) commit c3aeadc8d3580b319d51c62fb82255b06a1c4fd8 Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Mar 15 21:51:09 2016 +0200 drm/i915: add for_each_port_masked macro Same as for_each_dsi_port, but for general use. Leave the for_each_dsi_port version around as an "alias" for now to not cause too much churn. No functional changes. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/a0ef5bf33395e1fcd87178b17d6687b022042cf7.1458070700.git.jani.nikula@intel.com drivers/gpu/drm/i915/i915_drv.h | 4 ++++ drivers/gpu/drm/i915/intel_dsi.h | 4 +--- 2 files changed, 5 insertions(+), 3 deletions(-) commit 1e78aa014b84ff23f99daa0e0832b01337244062 Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:21:40 2016 +0200 drm/i915/dsi: start using enum mipi_dsi_pixel_format A small step moving us closer to DRM MIPI DSI code. Use enum mipi_dsi_pixel_format instead of our own. The first benefit is being able to use common mipi_dsi_pixel_format_to_bpp(). There's a little back and forth conversion with the VBT -> enum -> register, since we have just shoved the VBT value into the register directly. Longer term, all the VBT parsing and deciphering should be done in intel_bios.c, and abstracted there. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458123700-16003-2-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_dsi.c | 25 +++++++++++++++++----- drivers/gpu/drm/i915/intel_dsi.h | 10 +++++---- drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 33 ++++++++++++++++++++++-------- drivers/gpu/drm/i915/intel_dsi_pll.c | 30 +++++---------------------- 4 files changed, 56 insertions(+), 42 deletions(-) commit 42c151e65e80d22b611ba07812374ed726ebb947 Author: Jani Nikula <jani.nikula@intel.com> Date: Wed Mar 16 12:21:39 2016 +0200 drm/i915/dsi: lose the loose 666 format name in favor of packed The enum mipi_dsi_pixel_format defines MIPI_DSI_FMT_RGB666 for the "loose" 24 bpp format and MIPI_DSI_FMT_RGB666_PACKED for the 18 bpp format. We have this the other way round, defining a loose version for 24 bpp. Follow suit with what's in enum mipi_dsi_pixel_format to avoid future confusion. Rename VID_MODE_FORMAT_RGB666 -> VID_MODE_FORMAT_RGB666_PACKED VID_MODE_FORMAT_RGB666_LOOSE -> VID_MODE_FORMAT_RGB666 Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1458123700-16003-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/i915_reg.h | 4 ++-- drivers/gpu/drm/i915/intel_dsi_pll.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 1bb4308e7130428917bfa54c556daa98f7aa1ac9 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Mar 7 12:05:57 2016 +0000 drm/i915/csr: Allow matching unknown HW steppings with generic firmware If the firmware is generic and has a run-anywhere mode, enable it rather than completely failing on unknown HW revisions. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Damien Lespiau <damien.lespiau@intel.com> Cc: Imre Deak <imre.deak@intel.com> Cc: Sunil Kamath <sunil.kamath@intel.com> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Animesh Manna <animesh.manna@intel.com> Cc: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457352357-8433-1-git-send-email-chris@chris-wilson.co.uk drivers/gpu/drm/i915/intel_csr.c | 46 +++++++++++++++++----------------------- 1 file changed, 19 insertions(+), 27 deletions(-) commit 7cc96139d9e3f627bd18e5ee6a5e4e305369865b Author: Nathan Schulte <nmschulte@gmail.com> Date: Tue Mar 15 10:14:05 2016 -0500 drm/i915: add module param "enable_dp_mst" Adds an (unsafe; auto-kernel-tainting) boolean module parameter to the i915 drm driver: "enable_dp_mst", which is enabled by default. Disabling the parameter forces newly connected DisplayPort sinks to report as not supporting multi-stream transport (MST), thus "forcing" the use of single-stream transport (SST). v2: rename parameter to conform to style v3: add signoff Signed-off-by: Nathan Schulte <nmschulte@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1458054845-5837-1-git-send-email-nmschulte@gmail.com drivers/gpu/drm/i915/i915_params.c | 5 +++++ drivers/gpu/drm/i915/i915_params.h | 1 + drivers/gpu/drm/i915/intel_dp.c | 3 +++ 3 files changed, 9 insertions(+) commit 117897f42c87c11a3a8315507d38cbd99ea46fda Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 16 11:00:40 2016 +0000 drm/i915: More renaming of rings to engines This time using only sed and a few by hand. v2: Rename also intel_ring_id and intel_ring_initialized. v3: Fixed typo in intel_ring_initialized. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1458126040-33105-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_debugfs.c | 2 +- drivers/gpu/drm/i915/i915_dma.c | 12 +++---- drivers/gpu/drm/i915/i915_drv.h | 14 ++++----- drivers/gpu/drm/i915/i915_gem.c | 50 +++++++++++++++--------------- drivers/gpu/drm/i915/i915_gem_debug.c | 2 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +-- drivers/gpu/drm/i915/i915_irq.c | 2 +- drivers/gpu/drm/i915/intel_lrc.c | 8 ++--- drivers/gpu/drm/i915/intel_mocs.c | 6 ++-- drivers/gpu/drm/i915/intel_ringbuffer.c | 16 +++++----- drivers/gpu/drm/i915/intel_ringbuffer.h | 10 +++--- 11 files changed, 63 insertions(+), 63 deletions(-) commit 666796da7abbc9c8c1805efa6d43bf078ddb282e Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 16 11:00:39 2016 +0000 drm/i915: More intel_engine_cs renaming Some trivial ones, first pass done with Coccinelle: @@ @@ ( - I915_NUM_RINGS + I915_NUM_ENGINES | - intel_ring_flag + intel_engine_flag | - for_each_ring + for_each_engine | - i915_gem_request_get_ring + i915_gem_request_get_engine | - intel_ring_idle + intel_engine_idle | - i915_gem_reset_ring_status + i915_gem_reset_engine_status | - i915_gem_reset_ring_cleanup + i915_gem_reset_engine_cleanup | - init_ring_lists + init_engine_lists ) But that didn't fully work so I cleaned it up with: for f in *.[hc]; do sed -i -e s/I915_NUM_RINGS/I915_NUM_ENGINES/ $f; done for f in *.[hc]; do sed -i -e s/i915_gem_request_get_ring/i915_gem_request_get_engine/ $f; done for f in *.[hc]; do sed -i -e s/intel_ring_flag/intel_engine_flag/ $f; done for f in *.[hc]; do sed -i -e s/intel_ring_idle/intel_engine_idle/ $f; done for f in *.[hc]; do sed -i -e s/init_ring_lists/init_engine_lists/ $f; done for f in *.[hc]; do sed -i -e s/i915_gem_reset_ring_cleanup/i915_gem_reset_engine_cleanup/ $f; done for f in *.[hc]; do sed -i -e s/i915_gem_reset_ring_status/i915_gem_reset_engine_status/ $f; done v2: Rebase. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 52 ++++++++++----------- drivers/gpu/drm/i915/i915_drv.h | 26 +++++------ drivers/gpu/drm/i915/i915_gem.c | 74 +++++++++++++++--------------- drivers/gpu/drm/i915/i915_gem_context.c | 16 +++---- drivers/gpu/drm/i915/i915_gem_debug.c | 2 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +- drivers/gpu/drm/i915/i915_gem_gtt.c | 6 +-- drivers/gpu/drm/i915/i915_gpu_error.c | 12 ++--- drivers/gpu/drm/i915/i915_guc_submission.c | 6 +-- drivers/gpu/drm/i915/i915_irq.c | 20 ++++---- drivers/gpu/drm/i915/i915_trace.h | 6 +-- drivers/gpu/drm/i915/intel_display.c | 4 +- drivers/gpu/drm/i915/intel_guc_loader.c | 4 +- drivers/gpu/drm/i915/intel_lrc.c | 12 ++--- drivers/gpu/drm/i915/intel_mocs.c | 2 +- drivers/gpu/drm/i915/intel_pm.c | 12 ++--- drivers/gpu/drm/i915/intel_ringbuffer.c | 12 ++--- drivers/gpu/drm/i915/intel_ringbuffer.h | 20 ++++---- drivers/gpu/drm/i915/intel_uncore.c | 4 +- 19 files changed, 147 insertions(+), 147 deletions(-) commit 4a570db57c051644093c20eea934ee02b6ea84fd Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 16 11:00:38 2016 +0000 drm/i915: Rename intel_engine_cs struct members below and a couple manual fixups. @@ identifier I, J; @@ struct I { ... - struct intel_engine_cs *J; + struct intel_engine_cs *engine; ... } @@ identifier I, J; @@ struct I { ... - struct intel_engine_cs J; + struct intel_engine_cs engine; ... } @@ struct drm_i915_private *d; @@ ( - d->ring + d->engine ) @@ struct i915_execbuffer_params *p; @@ ( - p->ring + p->engine ) @@ struct intel_ringbuffer *r; @@ ( - r->ring + r->engine ) @@ struct drm_i915_gem_request *req; @@ ( - req->ring + req->engine ) v2: Script missed the tracepoint code - fixed up by hand. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 2 +- drivers/gpu/drm/i915/i915_dma.c | 8 +-- drivers/gpu/drm/i915/i915_drv.h | 18 +++---- drivers/gpu/drm/i915/i915_gem.c | 38 +++++++------- drivers/gpu/drm/i915/i915_gem_context.c | 24 ++++----- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 24 ++++----- drivers/gpu/drm/i915/i915_gem_gtt.c | 14 ++--- drivers/gpu/drm/i915/i915_gem_render_state.c | 6 +-- drivers/gpu/drm/i915/i915_gpu_error.c | 18 +++---- drivers/gpu/drm/i915/i915_guc_submission.c | 9 ++-- drivers/gpu/drm/i915/i915_irq.c | 40 +++++++-------- drivers/gpu/drm/i915/i915_trace.h | 46 ++++++++--------- drivers/gpu/drm/i915/intel_display.c | 18 +++---- drivers/gpu/drm/i915/intel_lrc.c | 76 ++++++++++++++-------------- drivers/gpu/drm/i915/intel_mocs.c | 2 +- drivers/gpu/drm/i915/intel_overlay.c | 8 +-- drivers/gpu/drm/i915/intel_pm.c | 2 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 74 +++++++++++++-------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 2 +- 19 files changed, 215 insertions(+), 214 deletions(-) commit 0bc40be85f33ca1795253a5f8674efb430f83cce Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 16 11:00:37 2016 +0000 drm/i915: Rename intel_engine_cs function parameters @@ identifier func; @@ func(..., struct intel_engine_cs * - ring + engine , ...) { <... - ring + engine ...> } @@ identifier func; type T; @@ T func(..., struct intel_engine_cs * - ring + engine , ...); Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_cmd_parser.c | 122 +++--- drivers/gpu/drm/i915/i915_debugfs.c | 16 +- drivers/gpu/drm/i915/i915_drv.h | 18 +- drivers/gpu/drm/i915/i915_gem.c | 86 ++-- drivers/gpu/drm/i915/i915_gem_context.c | 22 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 34 +- drivers/gpu/drm/i915/i915_gem_render_state.c | 6 +- drivers/gpu/drm/i915/i915_gem_render_state.h | 2 +- drivers/gpu/drm/i915/i915_gpu_error.c | 97 ++--- drivers/gpu/drm/i915/i915_irq.c | 111 ++--- drivers/gpu/drm/i915/intel_display.c | 8 +- drivers/gpu/drm/i915/intel_lrc.c | 566 ++++++++++++------------ drivers/gpu/drm/i915/intel_lrc.h | 16 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 618 ++++++++++++++------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 54 +-- 15 files changed, 909 insertions(+), 867 deletions(-) commit e2f80391478af71bbbc91686fe0efc580b907caa Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 16 11:00:36 2016 +0000 drm/i915: Rename local struct intel_engine_cs variables Done by the Coccinelle script below plus a manual intervention to GEN8_RING_SEMAPHORE_INIT. @@ expression E; @@ - struct intel_engine_cs *ring = E; + struct intel_engine_cs *engine = E; <+... - ring + engine ...+> @@ @@ - struct intel_engine_cs *ring; + struct intel_engine_cs *engine; <+... - ring + engine ...+> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/i915_debugfs.c | 203 ++++---- drivers/gpu/drm/i915/i915_gem.c | 136 ++--- drivers/gpu/drm/i915/i915_gem_context.c | 140 ++--- drivers/gpu/drm/i915/i915_gem_debug.c | 15 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 74 +-- drivers/gpu/drm/i915/i915_gem_gtt.c | 90 ++-- drivers/gpu/drm/i915/i915_gpu_error.c | 35 +- drivers/gpu/drm/i915/i915_guc_submission.c | 30 +- drivers/gpu/drm/i915/i915_irq.c | 84 +-- drivers/gpu/drm/i915/intel_display.c | 106 ++-- drivers/gpu/drm/i915/intel_guc_loader.c | 12 +- drivers/gpu/drm/i915/intel_lrc.c | 216 ++++---- drivers/gpu/drm/i915/intel_mocs.c | 4 +- drivers/gpu/drm/i915/intel_overlay.c | 60 +-- drivers/gpu/drm/i915/intel_pm.c | 36 +- drivers/gpu/drm/i915/intel_ringbuffer.c | 785 +++++++++++++++-------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 14 +- 17 files changed, 1035 insertions(+), 1005 deletions(-) commit 08250c4ba650a9d8453166b4c05962766798fe9b Author: Imre Deak <imre.deak@intel.com> Date: Mon Mar 14 19:55:34 2016 +0200 drm/i915/bxt: Fix off-by-one error in Broxton PLL IDs After the commit below the Broxton PLL IDs had an off-by-one error, so fix this up. Also add a missing brace at intel_shared_dpll_init(), it happened to compile only due to the way the IS_BROXTON macro is defined. v2: - remove debugging left-over Fixes: a3c988ea068c ("drm/i915: Make SKL/KBL DPLL0 managed by the shared dpll code") CC: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> CC: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457978134-12362-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_display.c | 6 +++--- drivers/gpu/drm/i915/intel_dpll_mgr.c | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) commit 31ae71fca7f91101613fac9deb8e858e1319b4f5 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 9 10:35:45 2016 +0100 drm/i915: Nuke fbc members from intel_crtc->atomic, v4. Whenever there's an update to the primary plane, fbc_pre_update and fbc_post_update are called. Kill off intel_crtc->atomic.update_fbc and now that intel_crtc->atomic is empty, kill it off too. Changes since v1: - Add a intel_fbc_supports_rotation helper. Changes since v2: - Remove intel_fbc_supports_rotation_helper. - Remove unrelated changes. Changes since v3: - Rebase Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457516145-32117-2-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> drivers/gpu/drm/i915/intel_display.c | 51 +++++++++++------------------------- drivers/gpu/drm/i915/intel_drv.h | 15 ----------- 2 files changed, 16 insertions(+), 50 deletions(-) commit cd202f69d89c48a935d4763ff96c50e762ed2e0a Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 9 10:35:44 2016 +0100 drm/i915: Remove some post-commit members from intel_crtc->atomic, v3. fb_bits is useful to have in the crtc_state for cs flips when the code is updated to use intel_frontbuffer_flip_prepare/complete. So calculate it in advance and move it to crtc_state. The other stuff can be calculated in post_plane_update, and aren't useful elsewhere. Changes since v1: - Changing wording, remove comment about loop. Changes since v2: - Rebase. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457516145-32117-1-git-send-email-maarten.lankhorst@linux.intel.com drivers/gpu/drm/i915/intel_atomic.c | 1 + drivers/gpu/drm/i915/intel_display.c | 29 +++++++++++++++++++++-------- drivers/gpu/drm/i915/intel_drv.h | 5 +---- 3 files changed, 23 insertions(+), 12 deletions(-) commit 31fa684096601d8fe5ea11e1c4d473229fef7c70 Merge: 359d2243 86d65b7 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Mar 16 08:11:09 2016 +0100 Merge remote-tracking branch 'airlied/drm-next' into drm-intel-next-queued Backmerge because: - Maarten needs latest atomic patches from drm-misc. - Lionel needs the color manager core patch from drm-misc. - Ander extracted intel_dpll_mgr.c, we need a backmerge to avoid git losing track of things too often (right now it seems ok due to cherry-picks). - Tvrtko needs a stable baseline to apply some large-scale renaming patches to i915 GEM code. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> commit 5bf59bd5e9a5b262110df8c1ea5ad8820d7d524a Author: Laxman Dewangan <ldewangan@nvidia.com> Date: Mon Mar 14 18:20:13 2016 +0530 regulator: pwm: Prints error number along with detail Prints the error number along with error message when any error occurs. This help on getting the reason of failure quickly from log without any code instrument. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Cc: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> drivers/regulator/pwm-regulator.c | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) commit 359d2243117a79599435141fda0047d01ef324e8 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Mon Mar 14 08:16:51 2016 +0100 drm/i915: Update DRIVER_DATE to 20160314 Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 9bbccbe11ab78c74bed9a2bc99943929f49ca565 Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Mar 12 13:30:16 2016 +0100 iio: dac: add NXP LPC18xx DAC driver Add base support for the 10-bit DAC peripheral found on NXP LPC18xx/43xx SoCs. This is a minimal driver that does not support DMA or interrupts. User manual with register description can be found on: LPC18xx: www.nxp.com/documents/user_manual/UM10430.pdf LPC43xx: www.nxp.com/documents/user_manual/UM10503.pdf Signed-off-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/dac/Kconfig | 10 ++ drivers/iio/dac/Makefile | 1 + drivers/iio/dac/lpc18xx_dac.c | 210 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 221 insertions(+) commit edcb2d26c10206b35a5736139f5dce02fc4bbdc9 Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Mar 12 13:30:15 2016 +0100 dt: document NXP LPC1850 ADC driver bindings Signed-off-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/adc/lpc1850-adc.txt | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) commit a583c24deefdaaaf5bd96a1117b850904a294804 Author: Joachim Eastwood <manabian@gmail.com> Date: Sat Mar 12 13:30:14 2016 +0100 iio: adc: add NXP LPC18xx ADC driver Add base support for the 10-bit SAR ADC peripheral found on NXP LPC18xx/43xx SoCs. This is a minimal driver that does not support burst mode, interrupts, DMA or hardware triggers. User manual with register description can be found on: LPC18xx: www.nxp.com/documents/user_manual/UM10430.pdf LPC43xx: www.nxp.com/documents/user_manual/UM10503.pdf Signed-off-by: Joachim Eastwood <manabian@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/Kconfig | 10 ++ drivers/iio/adc/Makefile | 1 + drivers/iio/adc/lpc18xx_adc.c | 231 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 242 insertions(+) commit 1c118b7230a16cb627061de9bd548ed7fdbdad24 Author: Alison Schofield <amsfield22@gmail.com> Date: Wed Mar 9 11:30:43 2016 -0800 staging: iio: ad7192: use iio_device_{claim|release}_direct_mode() Replace the code that guarantees the device stays in direct mode with iio_device_{claim|release}_direct_mode() which does same. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/adc/ad7192.c | 30 ++++++++++++------------------ 1 file changed, 12 insertions(+), 18 deletions(-) commit 08a33805518e7845486f88287e8aace6f8439391 Author: Alison Schofield <amsfield22@gmail.com> Date: Wed Mar 9 11:30:12 2016 -0800 iio: core: implement iio_device_{claim|release}_direct_mode() It is often the case that the driver wants to be sure a device stays in direct mode while it is executing a task or series of tasks. To accomplish this today, the driver performs this sequence: 1) take the device state lock, 2) verify it is not in a buffered mode, 3) execute some tasks, and 4) release that lock. This patch introduces a pair of helper functions that simplify these steps and make it more semantically expressive. iio_device_claim_direct_mode() If the device is not in any buffered mode it is guaranteed to stay that way until iio_release_direct_mode() is called. iio_device_release_direct_mode() Release the claim. Device is no longer guaranteed to stay in direct mode. Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/industrialio-core.c | 39 +++++++++++++++++++++++++++++++++++++++ include/linux/iio/iio.h | 2 ++ 2 files changed, 41 insertions(+) commit e8731180fbf6fd45351b587d67cdc0685ce99a7a Author: Martin Kepplinger <martink@posteo.de> Date: Wed Mar 9 12:01:29 2016 +0100 iio: mma8452: add support for FXLS8471Q This adds support for Freescale's (now NXP's) FXLS8471Q accelerometer. We use MMA8451Q's configuration because for what the driver supports, FXLS8471Q is the same. Support for FXLS8471Q's features (fast SPI interface and a larger FIFO, among others) can be added to this driver anytime. See it's datasheet for the details: http://cache.nxp.com/files/sensors/doc/data_sheet/FXLS8471Q.pdf Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/accel/mma8452.txt | 3 ++- drivers/iio/accel/Kconfig | 3 ++- drivers/iio/accel/mma8452.c | 22 ++++++++++++++++++++++ 3 files changed, 26 insertions(+), 2 deletions(-) commit 1e52fefc9b0c481f8ca860e19781720fb5404383 Author: Tiberiu Breana <tiberiu.a.breana@intel.com> Date: Wed Mar 9 14:06:14 2016 +0200 iio: accel: Add support for the h3lis331dl accelerometer This commit adds support for STMicroelectronics h3lis331dl high-g accelerometer. The datasheet for this device can be found here: http://www.st.com/web/en/resource/technical/document/ datasheet/DM00053090.pdf Signed-off-by: Tiberiu Breana <tiberiu.a.breana@intel.com> Reviewed-by: Denis Ciocca <denis.ciocca@st.com> Acked-by: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/st-sensors.txt | 1 + drivers/iio/accel/Kconfig | 2 +- drivers/iio/accel/st_accel.h | 1 + drivers/iio/accel/st_accel_core.c | 92 ++++++++++++++++++++++ drivers/iio/accel/st_accel_i2c.c | 4 + 5 files changed, 99 insertions(+), 1 deletion(-) commit 181c007dedacefaaf634b72b1f52c3b0415f87c1 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Tue Mar 8 11:19:37 2016 +0800 ath9k: fix reg dump data bus error Changes: - restrict only dump MAC registers - skip the register memory holes Data bus error, epc == 831d4040, ra == 831d403c Oops[#1]: CPU: 0 PID: 1536 Comm: cat Not tainted 3.14.0 #3 task: 82f87840 ti: 82f88000 task.ti: 82f88000 $ 0 : 00000000 00000001 deadc0de 1000fc03 $ 4 : b8100200 00000200 831e0000 80218788 $ 8 : 00000030 00000003 00000001 09524547 $12 : 00000000 810594f4 00000000 3a206d61 $16 : 831dd3c0 00000081 00000a00 c05ff000 $20 : 00005af6 00000200 00071b39 00071139 $24 : 00000001 80217760 $28 : 82f88000 82f89c60 c05ffa00 831d403c Hi : 00000000 Lo : 453c0000 epc : 831d4040 ath_ahb_exit+0x2198/0x2904 [ath9k] Not tainted ra : 831d403c ath_ahb_exit+0x2194/0x2904 [ath9k] Status: 1000fc03 KERNEL EXL IE Cause : 4080801c PrId : 00019374 (MIPS 24Kc) Stack : 00000001 00000000 0000000e 80475c60 0000000e 800a8ebc 00000000 00000000 00000001 00000007 00000000 800a9678 00000000 00000004 00000002 00000010 00000000 00000000 00000000 00000000 80475c60 0000000e 000009ec c05ff000 831dd3c0 00000080 00000a00 c05ff000 00005af6 00000200 00071b39 0007114d c05ff9ec 800a9904 831dd3c0 82f89d10 00000001 81082194 831d8f0c 82f89d14 ... Call Trace: [<831d4040>] ath_ahb_exit+0x2198/0x2904 [ath9k] [<831d403c>] ath_ahb_exit+0x2194/0x2904 [ath9k] Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/debug.c | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) commit c9b260a684d0493238433e08fc2ac7865a89aece Author: Steve deRosier <derosier@gmail.com> Date: Mon Mar 7 16:58:50 2016 -0800 ath6kl: ignore WMI_TXE_NOTIFY_EVENTID based on fw capability flags Certain 6004 firmware releases redefine the WMI_TXE_NOTIFY_EVENTID event number and sends the new event frequently. However it doesn't have the tx-err-notify feature and thus this firmware capability flag isn't set on the firmware package. By guarding the processing of this event by the same method we guard the sending of the WMI_SET_TXE_NOTIFY_CMDID command, we can ignore the spurious event that we don't know how to process. Without this change we call cfg80211_cqm_txe_notify() with possibly bad data. Signed-off-by: Steve deRosier <steve.derosier@lairdtech.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath6kl/wmi.c | 5 +++++ 1 file changed, 5 insertions(+) commit c7212b7136ba69efb9785df68b669381cb893920 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:21 2016 +0800 ath9k: fix BTCoex configuration for SOC chips Allow to set wl_active_time and wl_qc_time for SOC chips, also adjust bt_time_extend and bt_first_slot_time. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/btcoex.c | 31 ++++++++++++++++++++++++++++--- drivers/net/wireless/ath/ath9k/btcoex.h | 1 + 2 files changed, 29 insertions(+), 3 deletions(-) commit dfcf02cd2998e2240b2bc7b4f4412578b8070bdb Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:20 2016 +0800 ath9k: fix BTCoex access invalid registers for SOC chips The registers of AR_GPIO_INPUT_MUX1 and AR_GPIO_PDPU were removed from SOC chips, fix invalid accessing Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/btcoex.c | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) commit 668ae0a3e48ac6811f431915b466514bf167e2f4 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:19 2016 +0800 ath9k: add bits definition of BTCoex MODE2/3 for SOC chips Add bits definition for AR_BT_COEX_MODE2 and AR_BT_COEX_MODE3, which needed by SOC chips (AR9340, AR9531, AR9550, AR9561). Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/reg.h | 46 +++++++++++++++++++++++++++++------- 1 file changed, 37 insertions(+), 9 deletions(-) commit c8770bcf5cefa8cbfae21c07c4fe3428f5a9d42a Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:18 2016 +0800 ath9k: Allow platform override BTCoex pin Add new platform data to allow override BTCoex default pin. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/btcoex.c | 45 +++++++++++++++++++++++++-------- include/linux/ath9k_platform.h | 4 +++ 2 files changed, 39 insertions(+), 10 deletions(-) commit 79d4db1214a0c7b1818aaf64d0606b17ff1acea7 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:17 2016 +0800 ath9k: cleanup led_pin initial Make ath_init_leds() and ath_deinit_leds() pairs as the only API to set leds, also removed direction configuration from ath9k_start() and ath9k_stop(). So the initial is more clear now. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ath9k.h | 4 --- drivers/net/wireless/ath/ath9k/gpio.c | 62 ++++++++++++++++------------------ drivers/net/wireless/ath/ath9k/init.c | 1 - drivers/net/wireless/ath/ath9k/main.c | 9 ++--- drivers/net/wireless/ath/ath9k/reg.h | 2 -- 5 files changed, 31 insertions(+), 47 deletions(-) commit db2221901fbded787daed153281ed875de489692 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:16 2016 +0800 ath9k: free GPIO resource for SOC GPIOs For SOC GPIOs, should call ath9k_hw_gpio_free() to release the GPIO resource. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/btcoex.c | 10 ++++++++++ drivers/net/wireless/ath/ath9k/btcoex.h | 1 + drivers/net/wireless/ath/ath9k/gpio.c | 9 +++++++++ drivers/net/wireless/ath/ath9k/htc_drv_gpio.c | 2 ++ drivers/net/wireless/ath/ath9k/hw.c | 1 + 5 files changed, 23 insertions(+) commit b2d70d4944c1789bc64376ad97a811f37e230c87 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:15 2016 +0800 ath9k: make GPIO API to support both of WMAC and SOC commit 61b559dea40e ("ath9k: add extra GPIO led support") added ath9k to support access SOC's GPIOs, but implemented in a separated API: ath9k_hw_request_gpio(). So this patch make the APIs more common, to support both of WMAC and SOC GPIOs. The new APIs as below, void ath9k_hw_gpio_request_in(); void ath9k_hw_gpio_request_out(); void ath9k_hw_gpio_free(); NOTE, the BSP of the SOC chips(AR9340, AR9531, AR9550, AR9561) should set the corresponding MUX registers correctly. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_eeprom.c | 4 +- drivers/net/wireless/ath/ath9k/ar9003_mci.c | 39 +++-- drivers/net/wireless/ath/ath9k/btcoex.c | 27 ++-- drivers/net/wireless/ath/ath9k/gpio.c | 6 +- drivers/net/wireless/ath/ath9k/htc_drv_gpio.c | 6 +- drivers/net/wireless/ath/ath9k/hw.c | 196 +++++++++++++++---------- drivers/net/wireless/ath/ath9k/hw.h | 10 +- drivers/net/wireless/ath/ath9k/main.c | 6 +- 8 files changed, 174 insertions(+), 120 deletions(-) commit a01ab81b09c55025365c1de1345b941a18e05529 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Mon Mar 7 10:38:14 2016 +0800 ath9k: define correct GPIO numbers and bits mask Define correct GPIO numbers and MASK bits to indicate the WMAC GPIO resource. Allow SOC chips(AR9340, AR9531, AR9550, AR9561) to access all GPIOs which rely on gpiolib framework. But restrict SOC AR9330 only to access WMAC GPIO which has the same design with the old chips. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/hw.c | 70 ++++++++++++++++++++++++++++-------- drivers/net/wireless/ath/ath9k/hw.h | 1 + drivers/net/wireless/ath/ath9k/reg.h | 42 ++++++++++++++++++++-- 3 files changed, 96 insertions(+), 17 deletions(-) commit c8c91b02a8ddb802259b712245ee97f9c3067a7f Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:07:57 2016 -0500 ath9k_htc: fix up indents with spaces Use tabs here. Found by smatch. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/htc_drv_init.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 1451a3634ff5a443e256eb693627ffb1e34cd337 Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:07:56 2016 -0500 ath9k: fix a misleading indentation These lines belong inside the if-statement above, not in the main body of the switch. Found by smatch. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_phy.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) commit 0eb69ef355c3b77f8ce8f54b61759909ad3abcf8 Author: Bob Copeland <me@bobcopeland.com> Date: Sun Feb 28 20:07:55 2016 -0500 ath5k: fix incorrect indentation smatch said: drivers/net/wireless/ath/ath5k/phy.c:1449 ath5k_hw_channel() warn: inconsistent indenting drivers/net/wireless/ath/ath5k/reset.c:637 ath5k_hw_on_hold() warn: inconsistent indenting drivers/net/wireless/ath/ath5k/reset.c:702 ath5k_hw_nic_wakeup() warn: inconsistent indenting All of these lines were indented a tabstop too far. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath5k/phy.c | 2 +- drivers/net/wireless/ath/ath5k/reset.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) commit 1f64252d0b731d55f262a80f8eef914240334d17 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:43 2016 +0800 ath9k: set correct peak detect threshold Set QCA9561 peak detect threshold to 11. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_calib.c | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) commit 9c8ec9951d1e30f1339bcde8d324996412a3586b Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:42 2016 +0800 ath9k: use AR_SREV_9003_PCOEM to identify PCOEM chips commit f49c90db4d23 ("ath9k: Add a macro to identify PCOEM chips") defined AR_SREV_9003_PCOEM macro, its more clear to use the macro instead of checking one by one. Also removed PCOEM chips checking in the callback of ar9003_hw_do_pcoem_manual_peak_cal() which only for PCOEM chips. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_calib.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) commit 27ae9cd258a84ce7259afbee38dbe7841e723a68 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:41 2016 +0800 ath9k: enable manual peak cal for all ar9300 chips HW peak detect calibration would fail, enable all ar9300 chips manual peak calibration instead. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_calib.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) commit fcf5dfda6e520813323559eeaa66ea9f31b10736 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:40 2016 +0800 ath9k: Update AR9580 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9580_1p0_initvals.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 628bb7056bfb9156e53e1bcb5486cb15623ee43a Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:39 2016 +0800 ath9k: Update QCA956x initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar956x_initvals.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit f294b096c6cfb89b2d1baac8314a7dc49daab995 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:38 2016 +0800 ath9k: Update AR9565 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9565_1p0_initvals.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 836ff650eb4a1505a65bfc0d22ae51d478415e4f Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:37 2016 +0800 ath9k: Update AR955x initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar955x_1p0_initvals.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 93edb3addad8d1648c66b84673a10eb4905a1fb7 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:36 2016 +0800 ath9k: Update AR9485 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9485_initvals.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 63a0bc0e6f16e1f25eeb2f730de76ef1b072b876 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:35 2016 +0800 ath9k: Update AR9462 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9462_2p0_initvals.h | 4 ++-- drivers/net/wireless/ath/ath9k/ar9462_2p1_initvals.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 7b5c904ddc777f704d794c1e28942b0f35e7db32 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:34 2016 +0800 ath9k: Update AR9340 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9340_initvals.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 7da1ddddd55fdf478f712643e145e5d343f4ba46 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:33 2016 +0800 ath9k: Update AR933x initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9330_1p1_initvals.h | 4 ++-- drivers/net/wireless/ath/ath9k/ar9330_1p2_initvals.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) commit 137ef139b523a4e5f2582be0f58adbcce9996fe3 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:32 2016 +0800 ath9k: Update AR9003 2.2 initvals HW peak detect calibration would fail for AR9300 chips and we went for implementing the SW way of doing it instead of HW doing the peak detect calibration. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar9003_2p2_initvals.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 33ea008db7569686310268d60232f284ad213982 Author: Miaoqing Pan <miaoqing@codeaurora.org> Date: Fri Feb 26 16:08:31 2016 +0800 ath9k: Update QCA953x initvals commit 14c5932805eb ("ath9k: Update QCA953x initvals") disabled HW peak detect calibartion on QCA953x 1.0, which should also be applied on 2.0. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath9k/ar953x_initvals.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 842e03076ffb655e35c72f6c95fe216cc856f42b Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 2 15:48:01 2016 +0100 drm/i915: Update state before setting watermarks, v2. When intel_update_watermarks is called on skylake from the hw state readout disable function it calls intel_update_watermarks. intel_update_watermarks inspects crtc->state, which should be set to disabled. This wasn't the case, and this resulted in a divide-by-zero in skl_update_wm when intel_update_watermarks got called. ------------[ cut here ]------------ WARNING: CPU: 1 PID: 295 at drivers/gpu/drm/i915/intel_pm.c:2834 skl_update_pipe_wm+0x102/0x8c0 [i915]() WARN_ON(!config->num_pipes_active) Modules linked in: coretemp i915(+) xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx CPU: 1 PID: 295 Comm: systemd-udevd Tainted: G U W 4.5.0-rc4 -xxxxxx #25 Hardware name: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 0000000000000000 ffff88003777f5a8 ffffffff813485c2 ffff88003777f5f0 ffffffffa0236240 ffff88003777f5e0 ffffffff81050fce ffff8800aa420000 ffff8800aba18000 ffff8800aba18000 ffff880037304c00 ffff8800aa420000 Call Trace: [<ffffffff813485c2>] dump_stack+0x67/0x95 [<ffffffff81050fce>] warn_slowpath_common+0x9e/0xc0 [<ffffffff8105103c>] warn_slowpath_fmt+0x4c/0x50 [<ffffffff8106945e>] ? flush_work+0x8e/0x280 [<ffffffff810693d5>] ? flush_work+0x5/0x280 [<ffffffffa016add2>] skl_update_pipe_wm+0x102/0x8c0 [i915] [<ffffffffa016b96f>] skl_update_wm+0xff/0x5f0 [i915] [<ffffffff810928ee>] ? trace_hardirqs_on_caller+0x15e/0x1d0 [<ffffffff8109296d>] ? trace_hardirqs_on+0xd/0x10 [<ffffffffa016ce6e>] intel_update_watermarks+0x1e/0x30 [i915] [<ffffffffa01d3ee2>] intel_crtc_disable_noatomic+0xd2/0x150 [i915] [<ffffffffa01dd3d2>] intel_modeset_setup_hw_state+0xdd2/0xde0 [i915] [<ffffffffa01dfd83>] intel_modeset_init+0x15a3/0x1950 [i915] [<ffffffffa02160b6>] i915_driver_load+0x13c6/0x1720 [i915] [<ffffffff81522160>] ? add_sysfs_fw_map_entry+0x9b/0x9b [<ffffffffa00b15ef>] drm_dev_register+0x6f/0xb0 [drm] [<ffffffffa00b3b3a>] drm_get_pci_dev+0x10a/0x1d0 [drm] [<ffffffffa01582d9>] i915_pci_probe+0x49/0x50 [i915] [<ffffffff8138ae30>] pci_device_probe+0x80/0xf0 [<ffffffff8143e2ac>] driver_probe_device+0x1bc/0x3d0 [<ffffffff8143e526>] __driver_attach+0x66/0x90 [<ffffffff8143e4c0>] ? driver_probe_device+0x3d0/0x3d0 [<ffffffff8143be3b>] bus_for_each_dev+0x5b/0xa0 [<ffffffff8143db3e>] driver_attach+0x1e/0x20 [<ffffffff8143d461>] bus_add_driver+0x151/0x270 [<ffffffff8143eabc>] driver_register+0x8c/0xd0 [<ffffffff8138a2ed>] __pci_register_driver+0x5d/0x60 [<ffffffffa00b3c58>] drm_pci_init+0x58/0xf0 [drm] [<ffffffff8109296d>] ? trace_hardirqs_on+0xd/0x10 [<ffffffffa02aa000>] ? 0xffffffffa02aa000 [<ffffffffa02aa094>] i915_init+0x94/0x9b [i915] [<ffffffff81000423>] do_one_initcall+0x113/0x1f0 [<ffffffff810a4b21>] ? rcu_read_lock_sched_held+0x61/0x90 [<ffffffff811601dc>] ? kmem_cache_alloc_trace+0x1cc/0x280 [<ffffffff8111110a>] do_init_module+0x60/0x1c8 [<ffffffff810c731b>] load_module+0x1ceb/0x2410 [<ffffffff810c3a60>] ? store_uevent+0x40/0x40 [<ffffffff811763d1>] ? kernel_read+0x41/0x60 [<ffffffff810c7c1d>] SYSC_finit_module+0x8d/0xa0 [<ffffffff810c7c4e>] SyS_finit_module+0xe/0x10 [<ffffffff815f1e97>] entry_SYSCALL_64_fastpath+0x12/0x6f ---[ end trace 1149e9ab3695a423 ]--- ------------[ cut here ]------------ Changes since v1: - Clear state before calling any function after .crtc_disable. Reported-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56D6FD21.7020907@linux.intel.com Tested-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com> drivers/gpu/drm/i915/intel_display.c | 45 ++++++++++++------------------------ 1 file changed, 15 insertions(+), 30 deletions(-) commit 29ceb0e6c896f9476c681bb15dd0763f2137c0f4 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 9 19:07:27 2016 +0200 drm/i915: s/crtc_state/old_crtc_state/ in intel_atomic_commit() Avoid some head spinning by renaming the crtc_state variable to old_crtc_state. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 2622a08108b07fdb6ad74c46fc05e445e8be94bf Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 9 19:07:26 2016 +0200 drm/i915: Wait for vblank after cxsr disable in pre_plane_update We must wait for the hardware to exit cxsr before doing the plane update, so add the missing vblank wait to pre_plane_update after disabling cxsr. We have the wait for vblank in the pre_disable_primary hook, but not in the pre_plane_update hook. Just move the code from (and comment) from pre_disable_primary into pre_plane_update. Well, we still have to keep it in pre_disable_primary for these strange _noatomic codepaths, so let's do another version of pre_disable_primary for those. Also toss in some FIXMEs in the hope that someone will eventually clean up this pre_disable_primary mess. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 59 ++++++++++++++++++++++-------------- 1 file changed, 37 insertions(+), 22 deletions(-) commit caed361d83b204b7766924b80463bf7502ee7986 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 9 19:07:25 2016 +0200 drm/i915: Fix watermarks for VLV/CHV commit 92826fcdfc14 ("drm/i915: Calculate watermark related members in the crtc_state, v4.") broke thigns by removing the pre vs. post wm update distinction. We also lost the pre plane wm update entirely for VLV/CHV from the crtc enable path. This caused underruns on modeset and plane enable/disable on CHV, and often those can lead to a dead pipe. So let's bring back the pre vs. post thing, and let's toss in an explicit wm update to valleyview_crtc_enable() to avoid having to put it into the common code. This is more or less a partial revert of the offending commit. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: drm-intel-fixes@lists.freedesktop.org Fixes: 92826fcdfc14 ("drm/i915: Calculate watermark related members in the crtc_state, v4.") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_atomic.c | 3 ++- drivers/gpu/drm/i915/intel_display.c | 29 +++++++++++++++++++---------- drivers/gpu/drm/i915/intel_drv.h | 2 +- 3 files changed, 22 insertions(+), 12 deletions(-) commit 9f6151c9039084e18c118831779a99ac8f29e39c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 9 19:07:24 2016 +0200 drm/i915: Pass the correct crtc state to .update_plane() Pass the current crtc state, not the old crtc state, to the .update_plane() hook. Noticed on BSW when PRIMSIZE was getting programmed to a stale value which produced utter garbage on screen eg. wwhen going from 1920x1080 to 1024x768. Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Fixes: a758e6845825 ("drm/i915: Do not use commit_plane for sprite planes.") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_atomic_plane.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) commit dcb2e993f3c0cecc6c0d905cbf2e428640a957c1 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 9 19:07:23 2016 +0200 Revert "drm/i915: Enable PSR by default on Valleyview and Cherryview." This reverts commit a38c274faad0ec6aba692e294ec751d04dbba803. PSR causes all sorts of vblank wait timeouts and whanot on CHV. Disable it again. Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> Fixes: a38c274faad0 ("drm/i915: Enable PSR by default on Valleyview and Cherryview.") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-2-git-send-email-ville.syrjala@linux.intel.com Link: http://patchwork.freedesktop.org/patch/msgid/1457543247-13987-2-git-send-email-ville.syrjala@linux.intel.com Acked-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> drivers/gpu/drm/i915/intel_psr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) commit 2bcdb3f2e05f011b7456d363a6fc5a0177196587 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Mon Mar 7 15:22:32 2016 +0100 staging:iio:adis16220: Remove adis16220 driver The ADIS16220 part has been obsoleted, which makes it hard to get the hardware to even test the driver. Considering this there is no expectation that the driver will be cleaned up and be able to move out of staging, so remove the driver. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/Kconfig | 11 - drivers/staging/iio/accel/Makefile | 3 - drivers/staging/iio/accel/adis16220.h | 140 -------- drivers/staging/iio/accel/adis16220_core.c | 494 ----------------------------- 4 files changed, 648 deletions(-) commit 88ae3aedb8ec20a6b6ea8f7bd1990c0eb7c6f5d5 Author: Lars-Peter Clausen <lars@metafoo.de> Date: Mon Mar 7 15:22:31 2016 +0100 staging:iio:adis16204: Remove adis16204 driver The ADIS16204 part has been obsoleted, which makes it hard to get the hardware to even test the driver. Considering this there is no expectation that the driver will be cleaned up and be able to move out of staging, so remove the driver. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/staging/iio/accel/Kconfig | 12 -- drivers/staging/iio/accel/Makefile | 3 - drivers/staging/iio/accel/adis16204.h | 68 -------- drivers/staging/iio/accel/adis16204_core.c | 253 ----------------------------- 4 files changed, 336 deletions(-) commit 8b1f165a4a8f64c28cf42d10e1f4d3b451dedc51 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Mar 7 17:56:57 2016 +0200 drm/i915: Actually retry with bit-banging after GMBUS timeout After the GMBUS transfer times out, we set force_bit=1 and return -EAGAIN expecting the i2c core to call the .master_xfer hook again so that we will retry the same transfer via bit-banging. This is in case the gmbus hardware is somehow faulty. Unfortunately we left adapter->retries to 0, meaning the i2c core didn't actually do the retry. Let's tell the core we want one retry when we return -EAGAIN. Note that i2c-algo-bit also uses this retry count for some internal retries, so we'll end up increasing those a bit as well. Cc: Jani Nikula <jani.nikula@intel.com> Cc: drm-intel-fixes@lists.freedesktop.org Fixes: bffce907d640 ("drm/i915: abstract i2c bit banging fallback in gmbus xfer") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457366220-29409-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_i2c.c | 6 ++++++ 1 file changed, 6 insertions(+) commit a3c988ea068c94f39a2e6bd37e0faf1c2606a55d Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:27 2016 +0200 drm/i915: Make SKL/KBL DPLL0 managed by the shared dpll code Include DPLL0 in the managed dplls for SKL/KBL. While it has to be kept enabled because of it driving CDCLK, it is better to special case that inside the DPLL code than in the higher level. v2: Use INTEL_DPLL_ALWAYS_ON flag. (Ander) v3: Remove extremely paranoid WARN_ONs. (Maarten) Handle DPLL0 in skylake_get_ddi_pll() properly. (Ander) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-14-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 21 ------ drivers/gpu/drm/i915/intel_display.c | 12 +--- drivers/gpu/drm/i915/intel_dp.c | 52 +------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 124 ++++++++++++++++++++++++++-------- drivers/gpu/drm/i915/intel_dpll_mgr.h | 7 +- 5 files changed, 105 insertions(+), 111 deletions(-) commit 9d16da65bfda54dea0b9b10ec49a0e1d23b631eb Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:26 2016 +0200 drm/i915: Manage HSW/BDW LCPLLs with the shared dpll interface Manage the LCPLLs used with DisplayPort, so that all the HSW/BDW DPLLs are managed by the shared dpll code. v2: Introduce INTEL_DPLL_ALWAYS_ON flag to please state checker. (Ander) v3: Initialize pll->flags in intel_shared_dpll_init(). (Ander) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-13-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 18 +++---- drivers/gpu/drm/i915/intel_display.c | 25 ++++++---- drivers/gpu/drm/i915/intel_dp.c | 23 +-------- drivers/gpu/drm/i915/intel_dp_mst.c | 4 -- drivers/gpu/drm/i915/intel_dpll_mgr.c | 90 ++++++++++++++++++++++++++++------- drivers/gpu/drm/i915/intel_dpll_mgr.h | 12 ++++- drivers/gpu/drm/i915/intel_drv.h | 1 - 7 files changed, 108 insertions(+), 65 deletions(-) commit 34177c249af743ceccaf583bf750e8bc17c4f18a Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:25 2016 +0200 drm/i915: Move BXT pll configuration logic to intel_dpll_mgr.c Move the code for configurating BXT plls into the shared dpll code, so that the platform specific details are hidden behind that interface. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-12-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 141 +--------------------------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 139 +++++++++++++++++++++++++++++++-- 2 files changed, 134 insertions(+), 146 deletions(-) commit 304b65cbdc8d6d73b12ea798099b7ca64f491795 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:24 2016 +0200 drm/i915: Move SKL/KLB pll selection logic to intel_dpll_mgr.c Move the code for selecting plls for SKL/KLB into the shared dpll code, so that the platform specific details are hidden behind that interface. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-11-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 301 +-------------------------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 307 +++++++++++++++++++++++++++++++++- 2 files changed, 306 insertions(+), 302 deletions(-) commit daedf20a4f69685a636c9104cf6f1f5d8835345b Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:23 2016 +0200 drm/i915: Move HSW/BDW pll selection logic to intel_dpll_mgr.c Move the code for selecting and configuring HSW/BDW DDI PLLs into the shared dpll infrastructure. With this most of the PLL selection logic for those platforms is in one place. DisplayPort is handled separately, but that should be fixed on a follow up patch. It also allows a small clean up of the SPLL logic. v2: Rebase. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-10-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_crt.c | 8 +- drivers/gpu/drm/i915/intel_ddi.c | 271 ++----------------------------- drivers/gpu/drm/i915/intel_display.c | 2 +- drivers/gpu/drm/i915/intel_dpll_mgr.c | 295 ++++++++++++++++++++++++++++++++-- drivers/gpu/drm/i915/intel_dpll_mgr.h | 13 +- 5 files changed, 307 insertions(+), 282 deletions(-) commit f9476a6c6d0c33cbce271ea08a3fbef131c73dc0 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:22 2016 +0200 drm/i915: Refactor platform specifics out of intel_get_shared_dpll() The function intel_get_shared_dpll() had a more or less generic implementation with some platform specific checks to handle smaller differences between platforms. However, the minimalist approach forces bigger differences between platforms to be implemented outside of the shared dpll code (see the *_ddi_pll_select() functions in intel_ddi.c, for instance). This patch changes the implementation of intel_get_share_dpll() so that a completely platform specific version can be used, providing helpers to reduce code duplication. This should allow the code from the ddi pll select functions to be moved, and also make room for making more dplls managed by the shared dpll infrastructure. v2: WARN_ON(!dpll_mgr) in intel_get_shared_dpll(). (Maarten) Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-9-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_dpll_mgr.c | 226 +++++++++++++++++++++------------- drivers/gpu/drm/i915/intel_dpll_mgr.h | 2 + 3 files changed, 145 insertions(+), 84 deletions(-) commit 2edd6443e3d03267bfc63071a86332a1711dc1bc Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:21 2016 +0200 drm/i915: Use a table to initilize shared dplls Use a table to store the per-platform shared dpll information in one place. This way, there is no need for platform specific init funtions. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-8-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_display.c | 16 +-- drivers/gpu/drm/i915/intel_dpll_mgr.c | 189 ++++++++++++++++------------------ drivers/gpu/drm/i915/intel_dpll_mgr.h | 22 ++-- 3 files changed, 108 insertions(+), 119 deletions(-) commit c2a9fcd6831aee2944f5e6d3858f56f35a2ed70a Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:20 2016 +0200 drm/i915: Move shared dpll function prototypes to intel_dpll_mgr.h Move shared dpll function prototype together with other shared dpll definitions. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-7-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_dpll_mgr.h | 30 ++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_drv.h | 28 ---------------------------- 2 files changed, 30 insertions(+), 28 deletions(-) commit ac7f11c6106507f1e09a970a03904c323ae741b8 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:19 2016 +0200 drm/i915: Move shared dpll struct definitions to separate header file Move the declarations related to shared dplls from i915_drv.h to their own header file. The code that became the shared dpll infrastructre was first introcude in commit ee7b9f93fd96 ("drm/i915: manage PCH PLLs separately from pipes"), hence the 2012-2016 copyright years in the new header file. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-6-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/i915_drv.h | 76 +----------------------- drivers/gpu/drm/i915/intel_dpll_mgr.h | 106 ++++++++++++++++++++++++++++++++++ 2 files changed, 107 insertions(+), 75 deletions(-) commit 8106ddbd7733f31205007f97be0866b408772907 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:18 2016 +0200 drm/i915: Store a direct pointer to shared dpll in intel_crtc_state Change the type of intel_crtc_state->shared_dpll to be a pointer to a shared dpll. With this there is no need to first convert the id stored in the crtc state to a pointer in order to use it. It does introduce a bit of hassle on doing the opposite. The long term objective is to hide details about dpll ids behind the shared dpll interface. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-5-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 4 +- drivers/gpu/drm/i915/intel_display.c | 108 ++++++++++++++++++++++------------ drivers/gpu/drm/i915/intel_dpll_mgr.c | 51 ++++++++++++---- drivers/gpu/drm/i915/intel_drv.h | 19 +++++- drivers/gpu/drm/i915/intel_lvds.c | 2 +- 5 files changed, 132 insertions(+), 52 deletions(-) commit a4780b7744c2833ba762d64576f661a9dae045f1 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:17 2016 +0200 drm/i915: Split intel_get_shared_dpll() into smaller functions Make the code neater by splitting the code for platforms with fixed PLL to their own functions and splitting the logic for finding a shareable or unused pll from the logic for setting it up. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-4-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_dpll_mgr.c | 109 +++++++++++++++++++++++----------- 1 file changed, 74 insertions(+), 35 deletions(-) commit 55be2f0854613b97aa606122bbe8b12a4b068bd9 Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:16 2016 +0200 drm/i915: Move ddi shared dpll code to intel_dpll_mgr.c No functional changes. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-3-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/intel_ddi.c | 472 ---------------------------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 472 ++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_drv.h | 1 - 3 files changed, 472 insertions(+), 473 deletions(-) commit 7abd4b35a577d6541bf07493a448eee9dfc8ba2d Author: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Date: Tue Mar 8 17:46:15 2016 +0200 drm/i915: Move shared dpll code to a new file Create the new file intel_dpll_mgr.c and move the shared dpll code to it. Follow up patches that reorganize pll handling will move more code there and tweak the interface. No functional changes. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457451987-17466-2-git-send-email-ander.conselvan.de.oliveira@intel.com drivers/gpu/drm/i915/Makefile | 1 + drivers/gpu/drm/i915/intel_display.c | 348 +------------------------------- drivers/gpu/drm/i915/intel_dpll_mgr.c | 368 ++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_drv.h | 8 + 4 files changed, 379 insertions(+), 346 deletions(-) commit 71f0a626143368b8aead361ffaff7e36d043fd8e Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Mar 8 10:57:16 2016 +0100 drm/i915: Only use sanitized values for ILK watermarks The raw watermark values are needed when planes are not part of the state, but this introduced a regression and possibly an overflow when merging the watermarks because invalid values may end up used. Solve this by calculating raw watermarks for all levels, and only setting non-zero values when the level is valid. Fixes the SNB warning: WARNING: CPU: 1 PID: 25405 at drivers/gpu/drm/i915/intel_pm.c:2580 ilk_program_watermarks+0x7b2/0x9d0 [i915]() WARN_ON(wm_lp != 1) Modules linked in: i915 drm_kms_helper drm bluetooth fuse iTCO_wdt iTCO_vendor_support syscopyarea sysfillrect sysimgblt fb_sys_fops tpm_tis mei_me e1000e snd_hda_codec_hdmi pcspkr tpm mei i2c_i801 lpc_ich snd_hda_codec snd_hda_core CPU: 1 PID: 25405 Comm: kms_universal_p Tainted: G U W 4.5.0-rc6apollolake+ #462 Hardware name: /DH67GD, BIOS BLH6710H.86A.0160.2012.1204.1156 12/04/2012 0000000000000000 ffff88009d42b918 ffffffff8143cfab ffff88009d42b960 ffffffffa0363580 ffff88009d42b950 ffffffff81082746 ffff8800b9a24928 ffff88009d42ba00 ffff88009d4a0000 0000000000000000 ffff88009d42ba6c Call Trace: [<ffffffff8143cfab>] dump_stack+0x4d/0x72 [<ffffffff81082746>] warn_slowpath_common+0x86/0xc0 [<ffffffff810827cc>] warn_slowpath_fmt+0x4c/0x50 [<ffffffffa0292862>] ilk_program_watermarks+0x7b2/0x9d0 [i915] [<ffffffffa0292cb7>] ilk_initial_watermarks+0x107/0x120 [i915] [<ffffffffa02feffa>] intel_pre_plane_update+0x12a/0x190 [i915] [<ffffffffa02ffb36>] intel_atomic_commit+0x546/0xd50 [i915] [<ffffffffa012c9e7>] drm_atomic_commit+0x37/0x60 [drm] [<ffffffffa0217361>] drm_atomic_helper_disable_plane+0xb1/0xf0 [drm_kms_helper] [<ffffffffa011cdb4>] __setplane_internal+0x184/0x280 [drm] [<ffffffffa012b57a>] ? drm_modeset_lock_all_ctx+0x9a/0xb0 [drm] [<ffffffffa012010f>] drm_mode_setplane+0x13f/0x1c0 [drm] [<ffffffffa0111b52>] drm_ioctl+0x142/0x590 [drm] [<ffffffffa011ffd0>] ? drm_plane_check_pixel_format+0x50/0x50 [drm] [<ffffffff811f2744>] ? mntput+0x24/0x40 [<ffffffff811d28d4>] ? __fput+0x194/0x200 [<ffffffffa012dec3>] drm_compat_ioctl+0x33/0x40 [drm] [<ffffffffa029e1c2>] i915_compat_ioctl+0x32/0x40 [i915] [<ffffffff81228d72>] compat_SyS_ioctl+0xc2/0x330 [<ffffffff810021d5>] ? exit_to_usermode_loop+0x95/0xb0 [<ffffffff81002d2e>] do_fast_syscall_32+0x9e/0x210 [<ffffffff8197faf2>] entry_SYSENTER_compat+0x52/0x70 Cc: Matt Roper <matthew.d.roper@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Testcase: kms_universal_plane Fixes: d81f04c5ef ("drm/i915: Allow preservation of watermarks, v2.") Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56DEA1FC.8080703@linux.intel.com Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/intel_drv.h | 1 + drivers/gpu/drm/i915/intel_pm.c | 19 +++++++++++-------- 2 files changed, 12 insertions(+), 8 deletions(-) commit acad889f9eb86ba8830de33cc7a391e9f68ca5ea Author: Jani Nikula <jani.nikula@intel.com> Date: Tue Mar 8 21:00:56 2016 +0200 drm/i915/bxt: add missing DSI power domain to power well 1 The DSI power domain was missing from BXT power well 1 definitions, failing to get the power well for DSI transcoders. As pipe A is in the same power well as DSI transcoders, the problem should only occur with pipes B and C. According to Ville, this is basically a nop since pw1 is under dmc control. But given that we still have this stuff defined here, it's clearly correct to include DSI here. Cc: Ramalingam C <ramalingam.c@intel.com> Cc: Deepak M <m.deepak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457463656-29357-1-git-send-email-jani.nikula@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 1 + 1 file changed, 1 insertion(+) commit 8d130963d38a5677dfd30a2fda83e5cd0b9f4f69 Author: Peter Oh <poh@qca.qualcomm.com> Date: Tue Mar 1 09:52:49 2016 -0800 ath10k: set MAC timestamp in management Rx frame Check and set Rx MAC timestamp when firmware indicates it. Firmware adds it in Rx beacon frame only at this moment. Driver and mac80211 may utilize it to detect such clockdrift or beacon collision and use the result for beacon collision avoidance. Signed-off-by: Peter Oh <poh@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/wmi.c | 13 +++++++++++++ drivers/net/wireless/ath/ath10k/wmi.h | 7 +++++++ 2 files changed, 20 insertions(+) commit 60549cab2ea5ffa100076cb06d49579e05edd966 Author: Grzegorz Bajorski <grzegorz.bajorski@tieto.com> Date: Mon Nov 30 13:56:59 2015 +0100 ath10k: deliver mgmt frames from htt to monitor vifs only Until now only WMI originating mgmt frames were reported to mac80211. Management frames on HTT were basically dropped (except frames which looked like management but had FCS error). To allow sniffing all frames (including offloaded frames) without interfering with mac80211 operation and states a new rx_flag was introduced and is not being used to distinguish frames and classify them for mac80211. Signed-off-by: Grzegorz Bajorski <grzegorz.bajorski@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt_rx.c | 70 ++++++++++++++++---------------- drivers/net/wireless/ath/ath10k/wmi.c | 6 +++ 2 files changed, 40 insertions(+), 36 deletions(-) commit 9dfbffcf4ac0707097af9e6c1372192b9d03a357 Author: Takashi Iwai <tiwai@suse.de> Date: Wed Feb 24 15:35:22 2016 +0100 drm/i915: Fix bogus dig_port_map[] assignment for pre-HSW The recent commit [0bdf5a05647a: drm/i915: Add reverse mapping between port and intel_encoder] introduced a reverse mapping to retrieve intel_dig_port object from the port number. The code assumed that the port vs intel_dig_port are 1:1 mapping. But in reality, this was a too naive assumption. As Martin reported about the missing HDMI audio on his SNB machine, pre-HSW chips may have multiple intel_dig_port objects corresponding to the same port. Since we assign the mapping statically at the init time and the multiple objects override the map, it may not match with the actually enabled output. This patch tries to address the regression above. The reverse mapping is provided basically only for the audio callbacks, so now we set / clear the mapping dynamically at enabling and disabling HDMI/DP audio, so that we can always track the latest and correct object corresponding to the given port. Fixes: 0bdf5a05647a ('drm/i915: Add reverse mapping between port and intel_encoder') Reported-and-tested-by: Martin Kepplinger <martink@posteo.de> Cc: drm-intel-fixes@lists.freedesktop.org Signed-off-by: Takashi Iwai <tiwai@suse.de> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456324522-21591-1-git-send-email-tiwai@suse.de drivers/gpu/drm/i915/intel_audio.c | 3 +++ drivers/gpu/drm/i915/intel_ddi.c | 1 - drivers/gpu/drm/i915/intel_dp.c | 1 - drivers/gpu/drm/i915/intel_hdmi.c | 2 -- 4 files changed, 3 insertions(+), 4 deletions(-) commit 2abc525bf5c62fd1f2a2994e5231842221dfdddb Author: Imre Deak <imre.deak@intel.com> Date: Fri Mar 4 21:57:41 2016 +0200 drm/i915/gen9: Fix DMC firmware initialization In commit 1e657ad7 we moved the last step of firmware initialization to skl_display_core_init(), where it will be run only during system resume, but not during driver loading. Since this init step needs to be done whenever we program the firmware fix this by moving the initialization to the end of intel_csr_load_program(). While at it simplify a bit csr_load_work_fn(). This issue prevented DC5/6 transitions, this change will re-enable those. v2: - remove debugging left-over and redundant comment in csr_load_work_fn() Fixes: 1e657ad7a48f ("drm/i915/gen9: Write dc state debugmask bits only once") CC: Mika Kuoppala <mika.kuoppala@intel.com> CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457121461-16729-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_csr.c | 40 +++++++++++++++++++++------------ drivers/gpu/drm/i915/intel_drv.h | 2 +- drivers/gpu/drm/i915/intel_runtime_pm.c | 22 ++---------------- 3 files changed, 29 insertions(+), 35 deletions(-) commit 1f1a361abf73edfb94ca010c51587de378bc7c68 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:18 2016 +0200 wil6210: add oob_mode module parameter Add module parameter oob_mode. Takes effect the next time the interface is brought up and FW is loaded. Puts the FW in special "out of the box" (OOB) mode which is used for diagnostics and certification. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/main.c | 16 ++++++++++++++++ drivers/net/wireless/ath/wil6210/wil6210.h | 1 + 2 files changed, 17 insertions(+) commit b4944f2c081ea0e2fa7bc8bb510e1e6e5667f30b Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:17 2016 +0200 wil6210: pass is_go flag to firmware When starting a PCP, pass the is_go flag to firmware in wmi_pcp_start. This flag indicates whether we started a PCP which is also a GO(P2P group owner) or just a regular PCP. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 9 ++++++++- drivers/net/wireless/ath/wil6210/wil6210.h | 2 +- drivers/net/wireless/ath/wil6210/wmi.c | 3 ++- 3 files changed, 11 insertions(+), 3 deletions(-) commit 375a173fc1524eb569c7e8f9cf331126a9d29033 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:16 2016 +0200 wil6210: fix no_fw_recovery mode with change_virtual_intf When FW crashed with no_fw_recovery mode enabled, user space could still call wil_cfg80211_change_iface quickly to change interface type, and this would cause recovery to proceed and FW crash logs may be lost. Fix this problem by not resetting the FW in case no_fw_recovery is enabled. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 2 +- drivers/net/wireless/ath/wil6210/interrupt.c | 1 + drivers/net/wireless/ath/wil6210/main.c | 5 +++++ drivers/net/wireless/ath/wil6210/wil6210.h | 1 + 4 files changed, 8 insertions(+), 1 deletion(-) commit 6777e71ca91ea488488362a919900488e0ade3f2 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:15 2016 +0200 wil6210: clean ioctl debug message Fix a debug message related to IOCTL that was incorrectly logged with the MISC category, and move it inside wil_ioctl so it will always be logged even if we call wil_ioctl from other places. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/ioctl.c | 11 +++++++++-- drivers/net/wireless/ath/wil6210/netdev.c | 6 +----- 2 files changed, 10 insertions(+), 7 deletions(-) commit 280ab987ef21d1c196acb3af4663a99f94d9da00 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:14 2016 +0200 wil6210: fix race conditions in p2p listen and search Fix 2 race conditions found during test runs of P2P discovery: 1. Because wil_p2p_cancel_listen was not protected, user space could start a new P2P listen/search before wmi_stop_discovery completed. This caused a crash in the firmware. 2. In P2P listen, when listen timer expires and user space calls cancel_remain_on_channel at the same time, code could send the cfg80211_remain_on_channel_expired notification twice. Added protections with wil->mutex to several places that call wmi_stop_discovery. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 9 +++-- drivers/net/wireless/ath/wil6210/main.c | 2 +- drivers/net/wireless/ath/wil6210/p2p.c | 63 ++++++++++++++++++++--------- drivers/net/wireless/ath/wil6210/wil6210.h | 4 +- 4 files changed, 53 insertions(+), 25 deletions(-) commit 4332cac17b5c0cb80d8b99fda33a0faad3238b0e Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:13 2016 +0200 wil6210: P2P_DEVICE virtual interface support Added support for the P2P_DEVICE virtual interface. This interface is intended for P2P management operations such as discovery and GO negotiation. Normally it is implemented by drivers to allow a separate interface for P2P management with its own MAC address, but for 11ad drivers it is needed to support P2P search, since it cannot otherwise be separated from normal scan. Since we only support a single interface/MAC address, we can't easily separate between primary and P2P_DEVICE interfaces. For example when a management packet arrives we can't tell for which interface it is intended. To work around this, we store a pointer to the interface where the last "radio operation" was triggered such as scan or remain on channel, and we forward management packets and scan results to this interface. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 136 +++++++++++++++++++++++++--- drivers/net/wireless/ath/wil6210/main.c | 1 + drivers/net/wireless/ath/wil6210/netdev.c | 1 + drivers/net/wireless/ath/wil6210/p2p.c | 24 +++-- drivers/net/wireless/ath/wil6210/pcie_bus.c | 1 + drivers/net/wireless/ath/wil6210/wil6210.h | 8 +- drivers/net/wireless/ath/wil6210/wmi.c | 7 +- 7 files changed, 152 insertions(+), 26 deletions(-) commit e6d68341e7286386451adf14cebb635a52b0effe Author: Dedy Lansky <qca_dlansky@qca.qualcomm.com> Date: Tue Mar 1 19:18:12 2016 +0200 wil6210: p2p initial support supporting p2p_find, p2p_listen and p2p_connect Use updated cfg80211_get_bss API (additional argument) Signed-off-by: Dedy Lansky <qca_dlansky@qca.qualcomm.com> Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/Makefile | 1 + drivers/net/wireless/ath/wil6210/cfg80211.c | 67 +++++++-- drivers/net/wireless/ath/wil6210/main.c | 6 + drivers/net/wireless/ath/wil6210/p2p.c | 220 ++++++++++++++++++++++++++++ drivers/net/wireless/ath/wil6210/wil6210.h | 31 +++- drivers/net/wireless/ath/wil6210/wmi.c | 80 +++++++++- 6 files changed, 389 insertions(+), 16 deletions(-) commit 5f0823ef8b76f446ab8b187fabfb4e7560bc33a1 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Mar 1 19:18:11 2016 +0200 wil6210: add support for platform specific notification events Add the ability to notify the platform driver on different events, such as FW crash, pre reset and FW ready. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/interrupt.c | 5 ++-- drivers/net/wireless/ath/wil6210/main.c | 32 +++++++++++++++++++++++-- drivers/net/wireless/ath/wil6210/wil_platform.h | 8 ++++++- 3 files changed, 40 insertions(+), 5 deletions(-) commit eabb03b4a37cc7945ca62453402c74a0622e5a05 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:10 2016 +0200 wil6210: basic PBSS/PCP support PBSS (Personal Basic Service Set) is a new BSS type for DMG networks. It is similar to infrastructure BSS, having an AP-like entity called PCP (PBSS Control Point), but it has few differences. For example, stations inside a PBSS can communicate directly, and the PCP role can be transferred between stations. This change adds PBSS support, and has 2 main parts: 1. When starting an AP, add an option to start as a PCP instead. This is implemented by a new PBSS flag which is passed as part of the cfg80211_ap_settings structure. 2. When connecting to a BSS, add an option to connect to a PCP instead of an AP. This is again implemented by a new PBSS flag, added to the cfg80211_connect_params structure. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 27 ++++++++++++++------------- drivers/net/wireless/ath/wil6210/wil6210.h | 2 ++ 2 files changed, 16 insertions(+), 13 deletions(-) commit b874ddecae0a087aee024ef808c63060434a2d50 Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:09 2016 +0200 wil6210: switch to generated wmi.h Switch to auto-generated version of wmi.h which is maintained by FW team. This will allow better sync between teams in the future and avoid bugs because of unexpected API changes. The wmi.h will have many differences but most are cosmetic. It also includes these real differences: 1. is_go parameter added to BCON_CTRL and START_PCP commands. 2. max_rx_pl_per_desc added to CFG_RX_CHAIN command. 3. various small API updates that are not currently used by driver. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 4 +- drivers/net/wireless/ath/wil6210/debugfs.c | 8 +- drivers/net/wireless/ath/wil6210/trace.h | 19 +- drivers/net/wireless/ath/wil6210/txrx.c | 4 +- drivers/net/wireless/ath/wil6210/wil6210.h | 21 +- drivers/net/wireless/ath/wil6210/wmi.c | 36 +- drivers/net/wireless/ath/wil6210/wmi.h | 1261 +++++++++++++-------------- 7 files changed, 652 insertions(+), 701 deletions(-) commit 74997a53d257e327699e359b78b3ecfd33f80cab Author: Lior David <qca_liord@qca.qualcomm.com> Date: Tue Mar 1 19:18:08 2016 +0200 wil6210: add support for discovery mode during scan Add support for discovery mode during scan. When discovery mode is active, station transmits special beacons while scanning. This can optimize the scan mainly when there is only one AP/PCP around. Discovery mode is implicitly used by firmware during P2P search. Since there is currently no use case where user space has a reason to directly control discovery mode, we expose it only through a debugfs flag. Also fix name confusion in the wmi_scan_type enumeration. The type previously called WMI_LONG_SCAN is actually WMI_ACTIVE_SCAN. Signed-off-by: Lior David <qca_liord@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 6 ++++++ drivers/net/wireless/ath/wil6210/debugfs.c | 6 ++++++ drivers/net/wireless/ath/wil6210/wil6210.h | 1 + drivers/net/wireless/ath/wil6210/wmi.h | 7 ++++--- 4 files changed, 17 insertions(+), 3 deletions(-) commit 58527421489dcc1110f6bcfd3b50d479199af4e0 Author: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Date: Tue Mar 1 19:18:07 2016 +0200 wil6210: replay attack detection Check PN for encrypted frames. Maintain PN data for Rx keys, pairwise per TID and group. Print PN's in the debugfs "stations" entry, like: [0] 04:ce:14:0a:3c:3d connected [ 0] ([32] 0 TU) 0x0fe [____________________________|___] total 252 drop 0 (dup 0 + old 0) last 0x000 [ 0] PN [0+]000000000000 [1-]000000000000 [2-]000000000000 [3-]000000000000 [GR] PN [0-]000000000000 [1+]000000000000 [2+]000000000000 [3-]000000000000 Rx invalid frame: non-data 0, short 0, large 0, replay 0 Rx/MCS: 0 110 65 65 65 0 12 0 0 0 0 0 0 [1] 00:00:00:00:00:00 unused [2] 00:00:00:00:00:00 unused [3] 00:00:00:00:00:00 unused [4] 00:00:00:00:00:00 unused [5] 00:00:00:00:00:00 unused [6] 00:00:00:00:00:00 unused [7] 00:00:00:00:00:00 unused Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/cfg80211.c | 100 +++++++++++++++++++++++++--- drivers/net/wireless/ath/wil6210/debugfs.c | 41 +++++++++++- drivers/net/wireless/ath/wil6210/main.c | 9 ++- drivers/net/wireless/ath/wil6210/txrx.c | 63 ++++++++++++++++++ drivers/net/wireless/ath/wil6210/txrx.h | 12 +++- drivers/net/wireless/ath/wil6210/wil6210.h | 18 +++++ 6 files changed, 226 insertions(+), 17 deletions(-) commit b42f11963f7bd8c54d0a28d679c13d9e83b85357 Author: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com> Date: Tue Mar 1 19:18:06 2016 +0200 wil6210: Set permanent MAC address to wiphy MAC address of wil6210 was not set in wiphy Signed-off-by: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/main.c | 2 ++ 1 file changed, 2 insertions(+) commit 3d287fb398c03189a1394778162f6404e4d44ad2 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Mar 1 19:18:05 2016 +0200 wil6210: AP: prevent connecting to already connected station wmi_evt_connect doesn't check if the connect event is received for an already connected station. This can lead to memory leak as a new vring is allocated without freeing the previously allocated vring and to unexpected behavior of nl80211 layer due to unexpected notification of a new station. Add a check in wmi_evt_connect in AP mode to verify that the requested CID is not associated to an already connected station. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/wmi.c | 8 ++++++++ 1 file changed, 8 insertions(+) commit 361486b27c7e57dab657dbffd1e17818c7911c72 Author: Maya Erez <qca_merez@qca.qualcomm.com> Date: Tue Mar 1 19:18:04 2016 +0200 wil6210: remove BACK RX and TX workers WMI synchronous handling has changed and WMI calls that provide a buffer for the reply are completed in the WMI interrupt context. This allows sending the RX and TX BACK commands from the WMI event handler without the need for the worker thread. This is a better approach as it can decrease the handshake time in the connect flow and prevent race conditions in case of fast disconnects. An example for such a race is handling of wil_back_rx_handle during a disconnect event, as wil_back_rx_handle is not protected by the wil mutex and a disconnect can be handled after sta->status is verified as connected. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/wil6210/main.c | 10 -- drivers/net/wireless/ath/wil6210/rx_reorder.c | 204 ++++++-------------------- drivers/net/wireless/ath/wil6210/wil6210.h | 29 ---- 3 files changed, 41 insertions(+), 202 deletions(-) commit 8a75fc54745fd3ce9062ab1cc6429a9da9ac2a68 Author: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Date: Wed Mar 2 20:13:52 2016 +0530 ath10k: fix firmware assert in monitor mode commit 166de3f1895d ("ath10k: remove supported chain mask") had revealed an issue on monitor mode. Configuring NSS upon monitor interface creation is causing target assert in all qca9888x and qca6174 firmware. Firmware assert issue can be reproduced by below sequence even after reverting commit 166de3f1895d ("ath10k: remove supported chain mask"). ip link set wlan0 down iw wlan0 set type monitor iw phy0 set antenna 7 ip link set wlan0 up This issue is originally reported on qca9888 with 10.1 firmware. Fixes: 5572a95b4b ("ath10k: apply chainmask settings to vdev on creation") Cc: stable@vger.kernel.org Reported-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit 99ad1cba313fc86797bca55d64e7c6c809098511 Author: Michal Kazior <michal.kazior@tieto.com> Date: Tue Mar 1 13:16:11 2016 +0100 ath10k: change htt tx desc/qcache peer limit config The number of HTT Tx descriptors and qcache peer limit aren't hw-specific. In fact they are firmware specific and should not be placed in hw_params. The QCA4019 limits were submitted with the peer flow control firmware only and to my understanding there's no non-peer-flow-ctrl QCA4019 firmware. However QCA99X0 is planned to run firmware supporting the feature as well. Therefore this patch enables QCA99X0 to use 2500 tx descriptors whenever possible instead of just 1424. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 11 ++++++----- drivers/net/wireless/ath/ath10k/core.h | 2 -- drivers/net/wireless/ath/ath10k/hw.h | 4 ++++ drivers/net/wireless/ath/ath10k/wmi.c | 10 ++++++++-- 4 files changed, 18 insertions(+), 9 deletions(-) commit 43c9e3846ba30ca3d657bd82f1005d1573bb3a6d Author: Michal Kazior <michal.kazior@tieto.com> Date: Tue Mar 1 13:16:10 2016 +0100 ath10k: fix HTT Tx CE ring size QCA4019 can queue up to 2500 frames at a time. This means it requires roughly 5000 entires on the ring to work properly. Otherwise random tx failure may occur. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/ce.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 426e10eaf76d7229ed6c2978f0d473d04ba0b377 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:43 2016 +0200 ath10k: implement push-pull tx The current/old tx path design was that host, at its own leisure, pushed tx frames to the device. For HTT there was ~1000-1400 msdu queue depth. After reaching that limit the driver would request mac80211 to stop queues. There was little control over what packets got in there as far as DA/RA was considered so it was rather easy to starve per-station traffic flows. With MU-MIMO this became a significant problem because the queue depth was insufficient to buffer frames from multiple clients (which could have different signal quality and capabilities) in an efficient fashion. Hence the new tx path in 10.4 was introduced: a pull-push mode. Firmware and host can share tx queue state via DMA. The state is logically a 2 dimensional array addressed via peer_id+tid pair. Each entry is a counter (either number of bytes or packets. Host keeps it updated and firmware uses it for scheduling Tx pull requests to host. This allows MU-MIMO to become a lot more effective with 10+ clients. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/htt.h | 6 ++ drivers/net/wireless/ath/ath10k/htt_rx.c | 113 ++++++++++++++++++++++++++++--- drivers/net/wireless/ath/ath10k/htt_tx.c | 39 ++++++++--- drivers/net/wireless/ath/ath10k/mac.c | 44 ++++++++++-- drivers/net/wireless/ath/ath10k/mac.h | 5 ++ 6 files changed, 186 insertions(+), 22 deletions(-) commit 3cc0fef6170dce8e7d4ec29afb4f34267fb9bf14 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:41 2016 +0200 ath10k: keep track of queue depth per txq This will be necessary for later. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/mac.c | 5 +++++ drivers/net/wireless/ath/ath10k/txrx.c | 7 +++++++ 3 files changed, 13 insertions(+) commit dd4717b6f45e70b609d4282667eb0a89f9660268 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:39 2016 +0200 ath10k: store txq in skb_cb This will be necessary for later. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 1 + drivers/net/wireless/ath/ath10k/mac.c | 19 +++++++++++++++++-- 2 files changed, 18 insertions(+), 2 deletions(-) commit c1a43d9720d8dcde1eb735f6cbdba181e564ec20 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:36 2016 +0200 ath10k: implement updating shared htt txq state Firmware 10.4.3 onwards can support a pull-push Tx model where it shares a Tx queue state with the host. The host updates the DMA region it pointed to during HTT setup whenever number of software queued from (on host) changes. Based on this information firmware issues fetch requests to the host telling the host how many frames from a list of given stations/tids should be submitted to the firmware. The code won't be called because not all appropriate HTT events are processed yet. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 3 + drivers/net/wireless/ath/ath10k/htt_tx.c | 104 +++++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/mac.c | 3 + 3 files changed, 110 insertions(+) commit 299468782d94331f99a7eeb6e0d56598863be9fe Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:34 2016 +0200 ath10k: implement wake_tx_queue This implements very basic support for software queueing. It also contains some knobs that will be patched later. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.c | 2 + drivers/net/wireless/ath/ath10k/core.h | 7 ++ drivers/net/wireless/ath/ath10k/htt_rx.c | 3 + drivers/net/wireless/ath/ath10k/mac.c | 144 +++++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath10k/mac.h | 1 + 5 files changed, 157 insertions(+) commit 839ae6371e56594f06ef05a64fc90cd156007232 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:32 2016 +0200 ath10k: add new htt message generation/parsing logic This merely adds some parsing, generation and sanity checks with placeholders for real code/functionality to be added later. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 5 + drivers/net/wireless/ath/ath10k/htt_rx.c | 198 ++++++++++++++++++++++++++++++- drivers/net/wireless/ath/ath10k/htt_tx.c | 53 +++++++++ 3 files changed, 255 insertions(+), 1 deletion(-) commit 6942726f7f7bfc3c197795befe84c8e3c57435a0 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:30 2016 +0200 ath10k: add fast peer_map lookup The pull-push functionality of 10.4 will be based on peer_id and tid. These will need to be mapped, eventually, to ieee80211_txq to be used with ieee80211_tx_dequeue(). Iterating over existing stations every time peer_id needs to be mapped to a station would be inefficient wrt CPU time. The new firmware, which will be the only user of the code flow-wise, will guarantee to use low peer_ids first so despite peer_map's apparent huge size d-cache thrashing should not be a problem. Older firmware hot paths will effectively not use peer_map. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 4 ++ drivers/net/wireless/ath/ath10k/mac.c | 71 +++++++++++++++++++++++++++++++--- drivers/net/wireless/ath/ath10k/txrx.c | 2 + 3 files changed, 71 insertions(+), 6 deletions(-) commit bb8f0c6af83f2217aebbe45540e81d31b754b805 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:27 2016 +0200 ath10k: maintain peer_id for each sta and vif The 10.4.3 firmware with congestion control guarantees that each peer has only a single peer_id mapping. The 1:1 mapping isn't the case for older firmwares (e.g. 10.4.1, 10.2, 10.1) but it should not matter. This 1:1 mapping is going to be only used by future code which inherently (flow-wise) is for 10.4.3. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/core.h | 2 ++ drivers/net/wireless/ath/ath10k/mac.c | 38 ++++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) commit 6421969f248fdf9d8cd38353a617ed7cc5ddab94 Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:25 2016 +0200 ath10k: refactor tx pending management Tx pending counter logic assumed that the sk_buff is already known and hence was performed in HTT functions themselves. However, for the sake of future wake_tx_queue() usage the driver must be able to tell whether it can submit more frames to firmware before it dequeues frame from ieee80211_txq (and thus long before HTT Tx functions are called) because once a frame is dequeued it cannot be requeud back to mac80211. This prepares the driver for future changes. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/htt.h | 7 ++- drivers/net/wireless/ath/ath10k/htt_tx.c | 85 ++++++++------------------------ drivers/net/wireless/ath/ath10k/mac.c | 51 ++++++++++++++++--- drivers/net/wireless/ath/ath10k/txrx.c | 2 +- 4 files changed, 71 insertions(+), 74 deletions(-) commit a30c7d009ed56df43f09ab9af11e0bdd3a3f2a3f Author: Michal Kazior <michal.kazior@tieto.com> Date: Sun Mar 6 16:14:23 2016 +0200 ath10k: unify txpath decision Some future changes will need to determine final tx method early on. Prepare the code. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 54 ++++++++++++++++++++++++++++------- 1 file changed, 43 insertions(+), 11 deletions(-) commit f2f6ecabebddcbc54485cf3fca544e985457c0f4 Author: Michal Kazior <michal.kazior@tieto.com> Date: Tue Mar 1 11:32:46 2016 +0100 ath10k: refactor tx code This prepares the code for future reuse with ieee80211_txq and wake_tx_queue() in mind. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> drivers/net/wireless/ath/ath10k/mac.c | 151 +++++++++++++++++++++------------- 1 file changed, 96 insertions(+), 55 deletions(-) commit e84a41d5db891eab6f1f4a2625bb97f3c6415eee Author: Krzysztof Kozlowski <k.kozlowski@samsung.com> Date: Fri Mar 4 10:05:26 2016 +0900 iio: adc: Fix build error of missing devm_ioremap_resource on UM The devres.o gets linked if HAS_IOMEM is present so on ARCH=um allyesconfig (COMPILE_TEST) failed with: drivers/built-in.o: In function `at91_adc_probe': at91-sama5d2_adc.c:(.text+0x48f548): undefined reference to `devm_ioremap_resource' Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/Kconfig | 1 + 1 file changed, 1 insertion(+) commit c816d9e7a57bd436b2cff8f48b0e8cff128f05db Author: Matt Ranostay <matt.ranostay@intel.com> Date: Wed Mar 2 19:18:12 2016 -0800 iio: imu: mpu6050: fix possible NULL dereferences Fix possible null dereferencing of i2c and spi driver data. Signed-off-by: Matt Ranostay <matt.ranostay@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/imu/inv_mpu6050/inv_mpu_i2c.c | 3 ++- drivers/iio/imu/inv_mpu6050/inv_mpu_spi.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) commit 96c0cb2bbfe0a58bd0c37cf34d50a20f9cd75aa8 Author: Martin Kepplinger <martink@posteo.de> Date: Thu Mar 3 09:24:03 2016 +0100 iio: mma8452: add support for runtime power management This adds support for runtime power management and, if configured, activates automatic standby after 2 seconds of inactivity. Inactivity means no read of acceleration values and no events triggered or activated. If CONFIG_PM is not set, this doesn't change anything for existing users. Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma8452.c | 118 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 108 insertions(+), 10 deletions(-) commit e866853d67868ac0f7e0779d19aaad07285c9ff3 Author: Martin Kepplinger <martink@posteo.de> Date: Thu Mar 3 09:24:02 2016 +0100 iio: mma8452: avoid switching to active because of config change The devices' config registers can only be changed in standby mode. Up until now the driver just held the device *always* active, so for changing a config it was *always* necessary to switch to standby. For upcoming support for runtime pm, the device can as well be in standby mode. Instead of putting runtime pm functions in there, just keep the device in standby if it already is. This section is protected by a lock after all. Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma8452.c | 35 +++++++++++++++++++++++++++++------ 1 file changed, 29 insertions(+), 6 deletions(-) commit 8b8ff3a6a6e2325662e3af174f54b47487d3ed75 Author: Martin Kepplinger <martink@posteo.de> Date: Thu Mar 3 09:24:01 2016 +0100 iio: mma8452: coding style fixes fix checkpatch issues like "space before tabs", too long lines or alignment. Signed-off-by: Martin Kepplinger <martink@posteo.de> Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/accel/mma8452.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) commit 63d5d525cbbc8938d9fa3d6d6fbd4183e784b6e9 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Thu Mar 3 11:44:05 2016 +0100 iio:magnetometer:ak8975: power regulator support Add support for an optional regulator which, if found into device-tree, will power on device at probing time. The regulator is declared into ak8975 DTS entry as a "vdd-supply" property. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/magnetometer/ak8975.txt | 2 ++ drivers/iio/magnetometer/ak8975.c | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) commit d3546af67f4937075d0747adb3bf56d3c46b32f0 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Thu Mar 3 11:44:04 2016 +0100 iio:magnetometer:ak8975: remove unused field Remove unused struct ak8975_data attrs field. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/ak8975.c | 1 - 1 file changed, 1 deletion(-) commit 55c0c530f7113d98cb1a0d42f15b8abe5e4b6928 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Thu Mar 3 11:44:03 2016 +0100 iio:magnetometer:ak8975: fix uninitialized chipset ak_def_array bounds are not properly checked in case of ACPI matching failure. GCC warns with the following message at line 799: ‘chipset’ may be used uninitialized in this function. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/magnetometer/ak8975.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) commit f0fa15cce13d5987c50907eb98846d13e2b4d9ca Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Mar 3 17:09:14 2016 +0100 iio:adc:at91-sama5d2: fix identation Remove some extra tabs. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/at91-sama5d2_adc.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) commit 43d33f7458383ff6ce9838fca7b78b9b64fb988a Author: Ludovic Desroches <ludovic.desroches@atmel.com> Date: Thu Mar 3 17:09:13 2016 +0100 iio:adc:at91-sama5d2: fix typo Fix typo in the name of a macro. Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/adc/at91-sama5d2_adc.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 033691a9a12f684c68f443f3676806dd64011295 Author: Gregor Boirie <gregor.boirie@parrot.com> Date: Tue Mar 1 11:31:38 2016 +0100 iio:pressure:ms5611: oversampling rate support Add support for setting and retrieving OverSampling Rate independently for each of the temperature and pressure channels. This allows userspace to fine tune hardware sampling process according to the following tradeoffs : * the higher the OSR, the finer the resolution ; * the higher the OSR, the lower the noise ; BUT: * the higher the OSR, the larger the drift ; * the higher the OSR, the longer the response time, i.e. less samples per unit of time. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/pressure/ms5611.h | 20 ++++--- drivers/iio/pressure/ms5611_core.c | 105 ++++++++++++++++++++++++++++++++++++- drivers/iio/pressure/ms5611_i2c.c | 12 ++--- drivers/iio/pressure/ms5611_spi.c | 19 +++---- 4 files changed, 133 insertions(+), 23 deletions(-) commit 7a948c5e05febd23ee8e61db95c3dc96737fe17f Author: Grégor Boirie <gregor.boirie@parrot.com> Date: Tue Mar 1 11:31:37 2016 +0100 iio:pressure:ms5611: complete DT support Add device-tree ID tables and document bindings. Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org> .../devicetree/bindings/iio/pressure/ms5611.txt | 19 +++++++++++++++++++ Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + drivers/iio/pressure/ms5611_i2c.c | 13 +++++++++++++ drivers/iio/pressure/ms5611_spi.c | 13 +++++++++++++ 4 files changed, 46 insertions(+) commit 844a65636793d284526ff7d623ef477ed4473ab4 Author: Matt Ranostay <mranostay@gmail.com> Date: Fri Mar 4 22:55:25 2016 -0800 iio: potentiometer: tpl0102: change i2c functionality return code Change i2c_check_functionality condition check return from ENOTSUPP to EOPNOTSUPP which is now the standard return code. Signed-off-by: Matt Ranostay <mranostay@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org> drivers/iio/potentiometer/tpl0102.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 24a65e624bcdc726c7711ae90efeffaf0a8e9f32 Author: Mika Kuoppala <mika.kuoppala@linux.intel.com> Date: Wed Mar 2 16:48:29 2016 +0200 drm/i915/hangcheck: Prevent long walks across full-ppgtt With full-ppgtt, it takes the GPU an eon to traverse the entire 256PiB address space, causing a loop to be detected. Under the current scheme, if ACTHD walks off the end of a batch buffer and into an empty address space, we "never" detect the hang. If we always increment the score as the ACTHD is progressing then we will eventually timeout (after ~46.5s (31 * 1.5s) without advancing onto a new batch). To counter act this, increase the amount we reduce the score for good batches, so that only a series of almost-bad batches trigger a full reset. DoS detection suffers slightly but series of long running shader tests will benefit. Based on a patch from Chris Wilson. Testcase: igt/drv_hangman/hangcheck-unterminated Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1456930109-21532-1-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/i915_debugfs.c | 2 -- drivers/gpu/drm/i915/i915_gpu_error.c | 2 -- drivers/gpu/drm/i915/i915_irq.c | 17 +++++++---------- drivers/gpu/drm/i915/intel_ringbuffer.h | 2 -- 4 files changed, 7 insertions(+), 16 deletions(-) commit d431440cce2427dcdd665d936865fe802637b4c2 Author: Tomas Elf <tomas.elf@intel.com> Date: Wed Mar 2 16:46:24 2016 +0200 drm/i915: Generalise common GPU engine reset request/unrequest code GPU engine reset handshaking is something that is applicable to both full GPU reset and engine reset, which is something that is part of the upcoming TDR per-engine hang recovery patches. Break out the common engine reset request/unrequest code (originally written by Mika Kuoppala) for reuse later in the TDR enablement patch series. v2: correct indentation and drop unused returned value (Mika) v3: We have forcewake during reset so use *_FW reg access (Mika) Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> Signed-off-by: Tomas Elf <tomas.elf@intel.com> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> [Mika: Fixed format warning] Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456929984-16323-1-git-send-email-mika.kuoppala@intel.com drivers/gpu/drm/i915/intel_uncore.c | 56 ++++++++++++++++++++++++------------- 1 file changed, 36 insertions(+), 20 deletions(-) commit 37f2248e3d422f0463800b574ea9288ede97cea2 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:18 2016 +0200 drm/i915: Use DIV_ROUND_CLOSEST for PWM calculations Supposedly we would want to get the PWM output as close as possible to the target, so let's round to closest. Cc: Jani Nikula <jani.nikula@linux.intel.com> Suggested-by: Jani Nikula <jani.nikula@linux.intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-7-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/intel_panel.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit a457f54b293c82fc6b222d9bc59fed4984321d84 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:17 2016 +0200 drm/i915: Clean up .get_aux_clock_divider() functions Now that the mess with AUX clock divder rounding is sorted out and we have both cdclk and rawclk cached in dev_priv, we can clean up the .get_aux_clock_divider() functions a bit. The main thing here is just calling ilk_get_aux_clock_divider() from hsw_get_aux_clock_divider() except for the LPT:H special case. We could go further and call g4x_get_aux_clock_divider() from ilk_get_aux_clock_divider() for the PCH ports, but I'm sure Jani would object, so leave that be. While at it repeat the comment where the AUX clock comes from in ilk_get_aux_clock_divider(). Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-6-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_dp.c | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) commit 35d38d1f17b853a014b500350ab3135790d47ef3 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:16 2016 +0200 drm/i915: Read out hrawclk from CCK on vlv/chv Currently we assume that hrawclk is 200MHz on VLV/CHV. That should be true always, but just to avoid such asumptions we can read out the actual frequency from CCK. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_reg.h | 1 + drivers/gpu/drm/i915/intel_display.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) commit 193709c1c4d2543eac5d49428db732837ebcf61f Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:15 2016 +0200 drm/i915: Use g4x_get_aux_clock_divider() for VLV/CHV With the hrawclk frequency cached in dev_priv, we can simply use g4x_get_aux_clock_divider() for VLV/CHV. v2: Rebase due to IS_VALLYVIEW vs. IS_CHERRYVIEW split Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-4-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_dp.c | 7 ------- 1 file changed, 7 deletions(-) commit 6ffb1be708ccbefc1a833b3d7d186eefbcf5f12e Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:14 2016 +0200 drm/i915: Rename s/i9xx/g4x/ in DP code g4x is the first platform with DP support, so let's name the relevant functions as g4x_ instead i9xx_ to avoid confusion. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-3-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_dp.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit e7dc33f332c7188a96722a69fe99c2de9ada3ff0 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Mar 2 17:22:13 2016 +0200 drm/i915: Store rawclk_freq in dev_priv Generalize rawclk handling by storing it in dev_priv. Presumably our hrawclk readout works at least for CTG and ELK since we've been using it for DP AUX on those platforms. There are no real docs anymore after configdb vanished, so the only reference is the public CTG GMCH spec. What bits are listed in that doc match our code. The ELK GMCH spec have no relevant details unfortunately. The PNV situation is less clear. Starting from commit aa17cdb4f836 ("drm/i915: initialize backlight max from VBT") we assume that the CTG/ELK hrawclk readout works for PNV as well. At least the results *seem* reasonable for one PNV machine (Lenovo Ideapad S10-3t). Sadly the PNV GMCH spec doesn't have the goods on the relevant register either. So let's keep assuming it works for PNV,ELK,CTG and read it out on those platforms. G33 also has hrawclk according to some notes in BSpec, but we don't actually need it for anything, so let's not even try to read it out there. v2: Rebase due to IS_VALLYVIEW vs. IS_CHERRYVIEW split Use KHz() all over, and kill off a few useless temp variables Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456932138-14004-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com> drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_display.c | 55 ++++++++++++++++++++++-------------- drivers/gpu/drm/i915/intel_dp.c | 16 +++++------ drivers/gpu/drm/i915/intel_drv.h | 2 -- drivers/gpu/drm/i915/intel_panel.c | 42 +++++++++++++-------------- 5 files changed, 62 insertions(+), 54 deletions(-) commit 5ba001783ba6451fd3db0259d30549ca1fe91870 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 3 14:36:45 2016 +0000 drm/i915: Do not wait atomically for display clocks Looks like this code does not need to wait atomically since it otherwise takes the mutex. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1457015805-23742-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) commit 0351b93992aa463cc3e7f358ddec2709f9390756 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 3 16:21:27 2016 +0000 drm/i915: Do not lie about atomic timeout granularity Currently the wait_for_atomic_us only allows for a jiffie timeout granularity which is not nice towards callers requesting small micro-second timeouts. Re-implement it so micro-second timeout granularity is really supported and not just in the name of the macro. This has another beneficial side effect that it improves "gem_latency -n 100" results by approximately 2.5% (throughput and latencies) and 3% (CPU usage). (Note this improvement is relative to not yet merged execlist lock uncontention patch which moves the CSB MMIO outside this lock.) It also shrinks some hot functions like fw_domains_get by a tiny 3%. v2: * Warn when used from non-atomic context (if possible). * Warn on too long atomic waits. v3: * Added comment explaining CONFIG_PREEMPT_COUNT. * Fixed pre-processor indentation. (Chris Wilson) v4: * Commit msg update (gem_latency) and rebase. v5: * Commit message re-wording. * Added comment about no need for double cond check. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_drv.h | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) commit 643a24b6ecdcb3ed866cdf25a60df3d731504126 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 3 14:36:43 2016 +0000 drm/i915: Kconfig for extra driver debugging v2: Added a submenu based on an idea by Chris Wilson. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/Kconfig | 6 ++++++ drivers/gpu/drm/i915/Kconfig.debug | 12 ++++++++++++ 2 files changed, 18 insertions(+) commit 8de1b23efaede0e355cba017992ab032e983c61c Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 3 14:36:42 2016 +0000 drm/i915/lrc: Do not wait atomically when stopping engines I do not see that this needs to be done atomically and up to one second is quite a long time to busy loop. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_lrc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 3f177625ee896f5d3c62fa6a49554a9c0243bceb Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Thu Mar 3 14:36:41 2016 +0000 drm/i915: Add wait_for_us This is for callers who want micro-second precision but are not waiting from the atomic context. v2: * Fix atomic waits. (Dave Gordon) * Use USEC_PER_SEC and USEC_PER_MSEC. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Dave Gordon <david.s.gordon@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> drivers/gpu/drm/i915/intel_dp.c | 4 ++-- drivers/gpu/drm/i915/intel_drv.h | 15 ++++++++------- drivers/gpu/drm/i915/intel_psr.c | 3 ++- 3 files changed, 12 insertions(+), 10 deletions(-) commit 782d25cac6373457b9a1c8a5efcd9194eb97ba80 Author: Deepak M <m.deepak@intel.com> Date: Mon Feb 15 22:43:57 2016 +0530 drm/i915/bxt: Additional MIPI clock divider form B0 stepping onwards The MIPI clock calculations for the addtional clock are revised from B0 stepping onwards, the bit definitions have changed compared to old stepping. v2: Fixing compilation warning. v3: Retained the old Macros (Jani) Signed-off-by: Deepak M <m.deepak@intel.com> Tested-by: Ramalingam C <ramalingam.c@intel.com> # BXT-T with Tianma panel Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455556437-29267-1-git-send-email-m.deepak@intel.com drivers/gpu/drm/i915/i915_reg.h | 96 +++++++++++++++++++----------------- drivers/gpu/drm/i915/intel_dsi_pll.c | 56 ++++++++++++++------- 2 files changed, 89 insertions(+), 63 deletions(-) commit e3bddded40e23a4a40f4cc7df65180a6041646dd Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Mar 1 11:07:22 2016 +0100 drm/i915: Only recalculate wm's for planes part of the state, v2. Only planes that are part of the state should be used for recalculating watermarks. For planes not part of the state the previous patch allows us to re-use the old values since they're calculated even for levels that are not actively used. Changes since v1: - Remove big if from intel_crtc_atomic_check. - Remove extra newline. - Remove memset in ilk_compute_pipe_wm. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Matt Roper <matthew.d.roper@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456826842-32553-2-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> drivers/gpu/drm/i915/i915_drv.h | 3 +- drivers/gpu/drm/i915/intel_display.c | 2 +- drivers/gpu/drm/i915/intel_drv.h | 12 ++++++++ drivers/gpu/drm/i915/intel_pm.c | 59 ++++++++++++++++++++---------------- 4 files changed, 47 insertions(+), 29 deletions(-) commit d81f04c5ef5d6086e70656a32ff7c1b2bf998724 Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 2 12:38:06 2016 +0100 drm/i915: Allow preservation of watermarks, v2. As Paulo has noted we can help bisectability by separating computing watermarks on a noop in 2 separate commits. This patch no longer clears the crtc watermark state, but recalculates it completely. Regardless whether a level is used the full values for each level are calculated. If a level is invalid wm[level].enable is unset. Changes since v1: - Only call ilk_validate_wm_level when level <= usable_level. (Ville) Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56D6D09E.5040007@linux.intel.com Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> drivers/gpu/drm/i915/intel_pm.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) commit 1a426d6116467e09954289ee8c273e1bcc003adc Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Wed Mar 2 12:36:03 2016 +0100 drm/i915: Handle invalid ilk pipe watermarks correctly. This function returns an int, but when ilk_validate_pipe_wm fails it returns false, which is 0 (success). As a result invalid watermarks are applied, while they should have been rejected. Fix this by returning -EINVAL. Fixes: ed4a6a7ca853 ("drm/i915: Add two-stage ILK-style watermark programming (v11)") Cc: Matt Roper <matthew.d.roper@intel.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456918563-28696-1-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Matt Roper <matthew.d.roper@intel.com> drivers/gpu/drm/i915/intel_pm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 933bfb44b228f26e09364d122576c8e938588d4f Author: Sagar Arun Kamble <sagar.a.kamble@intel.com> Date: Mon Feb 8 22:47:11 2016 +0530 drm/i915: Hold RPM reference while setting freq limits through sysfs This changes ensures device is active when frequency limits are changed. This is needed as we are writing to register RPNSWREQ in intel_set_rps. If not done, might lead to undesired errors like: [ 1965.189137] [drm:fw_domains_get] *ERROR* blitter: timed out waiting for forcewake ack to clear. v2: Added elaborate commit message. (Jani) Fixing RPM reference drop in early exit paths. (Ville) Signed-off-by: Sagar Arun Kamble <sagar.a.kamble@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1454951831-11778-1-git-send-email-sagar.a.kamble@intel.com Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/i915_sysfs.c | 10 ++++++++++ 1 file changed, 10 insertions(+) commit ca377809d657ea3ba249e97d073a7373e383ab6a Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Wed Mar 2 12:10:31 2016 +0000 drm/i915: Avoid snooping with userptr where not supported commit e5756c10d841ddb448293c849392f3d6b809561f Author: Imre Deak <imre.deak@intel.com> Date: Fri Aug 14 18:43:30 2015 +0300 drm/i915/bxt: don't allow cached GEM mappings on A stepping Added an exception of disallowing snooping for Broxton A stepping hardware but userptr was still enabling it regardless. Move the check to HAS_SNOOP now that it is used from multiple call sites and use it. v2: Userptr cannot be supported when it cannot be coherent and generalize the code better. (Chris Wilson) v3: Make has_snoop true only when !has_llc. (Chris Wilson) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Imre Deak <imre.deak@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1456920631-34302-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/i915_dma.c | 4 ++++ drivers/gpu/drm/i915/i915_drv.h | 2 ++ drivers/gpu/drm/i915/i915_gem.c | 2 +- drivers/gpu/drm/i915/i915_gem_userptr.c | 7 +++++++ 4 files changed, 14 insertions(+), 1 deletion(-) commit 32fff610f7cf05260300f6c18700e9e0ac5910fb Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Tue Mar 1 17:04:01 2016 +0100 drm/i915: Do not return unknown status when load detection is tested. This fixes the IGT test, which interprets unknown status as failed to acquire load detect pipe. Cc: Gabriel Feceoru <gabriel.feceoru@intel.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456848241-6431-1-git-send-email-maarten.lankhorst@linux.intel.com Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/intel_crt.c | 2 ++ 1 file changed, 2 insertions(+) commit 5b773eb422f1671852f78548b18ec7c7de34b3cb Author: Imre Deak <imre.deak@intel.com> Date: Mon Feb 29 22:49:05 2016 +0200 drm/i915/gen9: Remove state asserts when disabling DC states Disabling the DC states when it's already disabled is a valid scenario, for example during HW state sanitization during driver loading and resuming or when DC states are disabled via the i915.enable_dc or disable_power_well option. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456778945-5411-4-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 41 +-------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) commit 66e2c4c39cc37beaccc24c9d14c75d627fce9cf4 Author: Imre Deak <imre.deak@intel.com> Date: Mon Feb 29 22:49:04 2016 +0200 drm/i915/gen9: Disable DC states if power well support is disabled If power well support is disabled via the i915.disable_power_well module option we should never enable DC states. Currently we would enable DC states even in this case during system suspend, where we need to disable all power wells regardless of the disable_power_well option. CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456778945-5411-3-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 3 +++ 1 file changed, 3 insertions(+) commit a37baf3b832b862d09e10067b7d2065b3b42a729 Author: Imre Deak <imre.deak@intel.com> Date: Mon Feb 29 22:49:03 2016 +0200 drm/i915/gen9: Sanitize handling of allowed DC states We can simplify the conditions selecting the target DC state during runtime by calculating the allowed DC states in advance during driver loading. This also makes it easier to disable DC states depending on the i915.disable_power_well module option, added in the next patch. v2: - Print a debug message if the requested max DC value was adjusted due to a platform limit. Also debug print the calculated mask value. (Patrik) CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456778945-5411-2-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_runtime_pm.c | 78 ++++++++++++++++++++++++--------- 2 files changed, 58 insertions(+), 21 deletions(-) commit 2622d79bd9d18fd04b650234e6a218c5f95cf308 Author: Imre Deak <imre.deak@intel.com> Date: Mon Feb 29 22:49:02 2016 +0200 drm/i915/skl: Fix power domain suspend sequence During system suspend we need to first disable power wells then unitialize the display core. In case power well support is disabled we did this in the wrong order, so fix this up. Fixes: d314cd43 ("drm/i915: fix handling of the disable_power_well module option") CC: stable@vger.kernel.org CC: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Patrik Jakobsson <patrik.jakobsson@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456778945-5411-1-git-send-email-imre.deak@intel.com drivers/gpu/drm/i915/intel_runtime_pm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit f85db0590dd8601a1fc513a40dd002c3bdf56b84 Author: arun.siluvery@linux.intel.com <arun.siluvery@linux.intel.com> Date: Tue Mar 1 11:24:36 2016 +0000 drm/i915/error: Capture WA ctx batch in error state execute during context save/restore, good to have them in error state. v2: use wa_ctx->size and print only size values (Mika) v3: simplify conditions when recording and freeing object (Chris) v4: resolve checkpatch errors (Tvrtko) Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456831476-10782-1-git-send-email-arun.siluvery@linux.intel.com drivers/gpu/drm/i915/i915_drv.h | 2 ++ drivers/gpu/drm/i915/i915_gpu_error.c | 29 +++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) commit debded848dee028d7f1f1e42a4e118df9636fb84 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:13 2016 +0200 drm/i915: Try to fix CRT port clock limits LPT/WPT-H are limited to max 180 MHz CRT dotclock. Most other platforms have a limit of 350 MHz. Supposedly gen3 and gen4 go up to 400 MHz. VLV is a bit special since the docs are poor. Supposedly the DAC would be good up to 355 MHz, but currently we limit the DPLL to 270 MHz, so we'll have to limit the port clock to the same unless we change the DPLL limits. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-7-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_crt.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) commit 8802e5b6de51ebbedb8a03e816ca847d860e07f5 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:12 2016 +0200 drm/i915: Read out VGA dotclock properly on LPT Rather than assume the VGA dotclock is really the FDI based thing, let's read out the real thing via iclkip, and after readout it'll get to compare it with the FDI based number to make sure they're in sync. Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/i915_reg.h | 8 ++++++-- drivers/gpu/drm/i915/intel_crt.c | 4 ++++ drivers/gpu/drm/i915/intel_display.c | 37 ++++++++++++++++++++++++++++++++++++ drivers/gpu/drm/i915/intel_drv.h | 1 + 4 files changed, 48 insertions(+), 2 deletions(-) commit 64b46a06313634cf9ce5808ebd63dc82573be34c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:11 2016 +0200 drm/i915: Make the LPT iclkip 20MHz case more generic The reason for spcial casing 20MHz in the iclkip calculations is that it would overflow the 7 bit divisor value. Let's rewrite the special case to check for just that, and bump up auxdiv when needed. This makes the code work for freqeuencies close to but not exactly 20MHz. The real lower limit for auxdiv=0 is actually: 172800000/(0x7f+2)*64)=~20930 kHz, and below that we must resort to auxdiv=1. Actually this is all very theoretical since we limit the dotclock to min 25MHz with CRT on all platforms. 25Mhz is actually the documented limit in Bspec, so it seems we ought to never need to worry about the auxdiv=1 case. But no harm in having it. Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_display.c | 40 +++++++++++++++++------------------- 1 file changed, 19 insertions(+), 21 deletions(-) commit 21a727b365f8617e9f57229f55c9712b13ab38a6 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:10 2016 +0200 drm/i915: Remove the SPLL==270Mhz assumption from intel_fdi_link_freq() Instead of assuming we've correctly set up SPLL to run at 270Mhz for FDI, let's use the port_clock from pipe_config which should be what we want. This would catch problems if someone misconfigures SPLL for whatever reason. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_display.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) commit e3b247da89f0adb04010f9dad6a3e41ed085d24e Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:09 2016 +0200 drm/i915: Move the encoder vs. FDI dotclock check out from encoder .get_config() Currently we check if the encoder's idea of dotclock agrees with what we calculated based on the FDI parameters. We do this in the encoder .get_config() hooks, which isn't so nice in case the BIOS (or some other outside party) made a mess of the state and we're just trying to take over. So as a prep step to being able sanitize such a bogus state, move the the sanity check to just after we've read out the entire state. If we then need to sanitize a bad state, it should be easier to move the sanity check to occur after sanitation instead of before it. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_crt.c | 10 +------ drivers/gpu/drm/i915/intel_display.c | 57 ++++++++++++++++++++---------------- drivers/gpu/drm/i915/intel_dp.c | 11 ++----- drivers/gpu/drm/i915/intel_drv.h | 3 -- drivers/gpu/drm/i915/intel_hdmi.c | 3 -- drivers/gpu/drm/i915/intel_lvds.c | 8 +---- drivers/gpu/drm/i915/intel_sdvo.c | 4 +-- 7 files changed, 38 insertions(+), 58 deletions(-) commit 1260f07e3e2ff0a9184918b59000713c33f71441 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Wed Feb 17 21:41:08 2016 +0200 drm/i915: Dump ddi_pll_sel in hex instead of decimal on HSW/BDW On HSW/BDW ddi_pll_sel is the actual register value. Let's dump it in hex so that people migth actually understand what it says. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455738073-14502-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak <imre.deak@intel.com> drivers/gpu/drm/i915/intel_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 2d7a215f8b917067efc9999d3d733dbab37ada5c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:47 2016 +0200 drm/i915: Embed rotation_info under intel_framebuffer Instead of repopulatin the rotation_info struct for the fb every time we try to use the fb, we can just populate it once when creating the fb, and later we can just copy the pre-populate struct into the gtt_view. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-10-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 27 ++++++++++++++++----------- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 17 insertions(+), 11 deletions(-) commit 11f20322e00fb48e53ac66d2889cec3341a8e814 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:46 2016 +0200 drm/i915: Move the NULL sg handling out from rotate_pages() rotate_pages() checks to see if it got called with a NULL sg, and then goes to extract it from sg->sgl. It always gets called with a NULL sg for the first plane, so moving the initial 'sg=st->sgl' assignment out into intel_rotate_fb_obj_pages() seems less special-casey. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-9-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/i915_gem_gtt.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) commit 1663b9d6a26a4d118e497b0a1604948b0fb0c86e Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:45 2016 +0200 drm/i915: Reorganize intel_rotation_info Throw out a bunch of unnecessary stuff from struct intel_rotation_info, and pull most of the remaining stuff to live under an array of per-color plane sub-structures. What still remains outside the sub-structure will be reorgranized later as well, but that requires more work elsewhere so leave it be for now. v2: Split the vma size == luma+chroma size fix to prep patch (Daniel) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> (v1) Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-8-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/i915_gem_gtt.c | 35 +++++++++++++++-------------------- drivers/gpu/drm/i915/i915_gem_gtt.h | 11 ++++------- drivers/gpu/drm/i915/intel_display.c | 25 +++++++++++++++---------- drivers/gpu/drm/i915/intel_drv.h | 1 + 4 files changed, 35 insertions(+), 37 deletions(-) commit 4f2d9934bd6ac73950832c96b385822846670668 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:44 2016 +0200 drm/i915: Pass drm_frambuffer to intel_compute_page_offset() intel_compute_page_offsets() gets passed a bunch of the framebuffer metadate sepearately. Just pass the framebuffer itself to make life simpler for the caller, and make it less likely they would make a mistake in the order of the arguments (as most as just unsigned ints and such). We still pass the pitch explicitly since for 90/270 degree rotation the caller has to pass in the right thing. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-7-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 15 +++++++-------- drivers/gpu/drm/i915/intel_drv.h | 6 ++---- drivers/gpu/drm/i915/intel_sprite.c | 9 +++------ 3 files changed, 12 insertions(+), 18 deletions(-) commit 3465c580afc86c066cc55842bae38ba3cb1acb99 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:43 2016 +0200 drm/i915: Don't pass plane+plane_state to intel_pin_and_fence_fb_obj() intel_pin_and_fence_fb_obj() only needs the framebuffer, and the desird rotation (to find the right GTT view for it), so no need to pass all kinds of plane stuff. The main motivation is to get rid of the uggy NULL plane_state handling due to fbdev. v2: Add a note why I really want this Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Grumpily-Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-6-git-send-email-ville.syrjala@linux.intel.com drivers/gpu/drm/i915/intel_display.c | 41 +++++++++++++++--------------------- drivers/gpu/drm/i915/intel_drv.h | 5 ++--- drivers/gpu/drm/i915/intel_fbdev.c | 2 +- 3 files changed, 20 insertions(+), 28 deletions(-) commit 29cf9491590119b9ebf1bf211bdd7a3cea4e040c Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:42 2016 +0200 drm/i915: Support for extra alignment for tiled surfaces SKL+ needs >4K alignment for tiled surfaces, so make intel_compute_page_offset() handle it. The way we do it is first we compute the closest tile boundary as before, and then figure out how many tiles we need to go to reach the desired alignment. The difference in the offset is then added into the x/y offsets. v2: Be less confusing wrt. units (pixels vs. bytes) (Daniel) v3: Use u32 for offsets Have intel_adjust_tile_offset() return the new offset (will be useful later) Add an offset_aligned variable (Daniel) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-5-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/intel_display.c | 50 ++++++++++++++++++++++++++++++++---- 1 file changed, 45 insertions(+), 5 deletions(-) commit 8d0deca8c6e0b25c409c6f4b2dc081596d7dffd9 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:41 2016 +0200 drm/i915: Pass 90/270 vs. 0/180 rotation info for intel_gen4_compute_page_offset() The page aligned surface address calculation needs to know which way things are rotated. The contract now says that the caller must pass the rotate x/y coordinates, as well as the tile_height aligned stride in the tile_height direction. This will make it fairly simple to deal with 90/270 degree rotation on SKL+ where we have to deal with the rotated view into the GTT. v2: Pass rotation instead of bool even thoughwe only care about 0/180 vs. 90/270 v3: Introduce intel_tile_dims(), and don't mix up different units so much v4: Unconfuse bytes vs. pixels even more Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-4-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/intel_display.c | 72 +++++++++++++++++++++++++----------- drivers/gpu/drm/i915/intel_drv.h | 3 +- drivers/gpu/drm/i915/intel_sprite.c | 18 +++++---- 3 files changed, 63 insertions(+), 30 deletions(-) commit 27ba39101404b694d4ae199fe7aa485ac693ba27 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:40 2016 +0200 drm/i915: s/tile_width/tile_width_bytes/ Make if clear whether we're talking tile widths in bytes or in pixels. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-3-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> drivers/gpu/drm/i915/intel_display.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) commit 9106cf1747cc16ea5ef301a215e336f88e2ce1e8 Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Date: Mon Feb 15 22:54:39 2016 +0200 drm/i915: Account for the size of the chroma plane for the rotated gtt view The size of the rotated ggtt mapping ought to include the size of the chroma plane as well. Not a huge deal since we don't expose NV12 (or any pother planar format for that matter) yet. Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Fixes: 89e3e1427629 ("drm/i915: Support NV12 in rotated GGTT mapping") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1455569699-27905-2-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 1d5bf5d9d9ef0c1e639d36178a224d83888c5a29 Author: Imre Deak <imre.deak@intel.com> Date: Mon Feb 29 22:10:33 2016 +0200 drm/i915: Add missing NULL check before calling initial_watermarks Not all platforms set this callback, so NULL check it before calling it. v2: - Call intel_update_watermarks() on HSW+ where the callback is not set. (Matt) CC: Matt Roper <matthew.d.roper@intel.com> Fixes: commit ed4a6a7ca853 ("drm/i915: Add two-stage ILK-style watermark programming (v11)") Signed-off-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456776633-3401-1-git-send-email-imre.deak@intel.com Reviewed-by: Matt Roper <matthew.d.roper@intel.com> drivers/gpu/drm/i915/intel_display.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) commit c6a2ac712d7dee13c13e44c4c4184478853dcb37 Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Date: Fri Feb 26 16:58:32 2016 +0000 drm/i915: Execlists small cleanups and micro-optimisations Assorted changes in the areas of code cleanup, reduction of invariant conditional in the interrupt handler and lock contention and MMIO access optimisation. * Remove needless initialization. * Improve cache locality by reorganizing code and/or using branch hints to keep unexpected or error conditions out of line. * Favor busy submit path vs. empty queue. * Less branching in hot-paths. v2: * Avoid mmio reads when possible. (Chris Wilson) * Use natural integer size for csb indices. * Remove useless return value from execlists_update_context. * Extract 32-bit ppgtt PDPs update so it is out of line and shared with two callers. * Grab forcewake across all mmio operations to ease the load on uncore lock and use chepear mmio ops. v3: * Removed some more pointless u8 data types. * Removed unused return from execlists_context_queue. * Commit message updates. v4: * Unclumsify the unqueue if statement. (Chris Wilson) * Hide forcewake from the queuing function. (Chris Wilson) Version 3 now makes the irq handling code path ~20% smaller on 48-bit PPGTT hardware, and a little bit less elsewhere. Hot paths are mostly in-line now and hammering on the uncore spinlock is greatly reduced together with mmio traffic to an extent. Benchmarking with "gem_latency -n 100" (keep submitting batches with 100 nop instruction) shows approximately 4% higher throughput, 2% less CPU time and 22% smaller latencies. This was on a big-core while small-cores could benefit even more. Most likely reason for the improvements are the MMIO optimization and uncore lock traffic reduction. One odd result is with "gem_latency -n 0" (dispatching empty batches) which shows 5% more throughput, 8% less CPU time, 25% better producer and consumer latencies, but 15% higher dispatch latency which is yet unexplained. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/1456505912-22286-1-git-send-email-tvrtko.ursulin@linux.intel.com drivers/gpu/drm/i915/intel_lrc.c | 214 +++++++++++++++++--------------- drivers/gpu/drm/i915/intel_ringbuffer.h | 3 +- 2 files changed, 114 insertions(+), 103 deletions(-) commit 3ba86073edcbe2be53d9862d5a3098f0ebf8ae9a Author: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Date: Mon Feb 29 09:18:57 2016 +0100 drm/i915: Handle -EDEADLK in drm_atomic_commit from load-detect. CI runs with DEBUG_WW_MUTEX_SLOWPATH, so -EDEADLK occurs a lot more. Handle the case where drm_atomic_commit fails with -EDEADLK correctly. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/56D3FEF1.6070306@linux.intel.com Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> drivers/gpu/drm/i915/intel_display.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) commit d9f8e52b22454a30aaaf26b7ef029598b30abf8e Author: Eric Engestrom <eric.engestrom@imgtec.com> Date: Mon Feb 29 16:24:07 2016 +0000 drm/i915: remove dead code 79e539453b34e35f39299a899d263b0a1f1670bd ("DRM: i915: add mode setting support") added those variables but never used them. Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1456763047-28828-2-git-send-email-eric.engestrom@imgtec.com drivers/gpu/drm/i915/intel_tv.c | 12 ------------ 1 file changed, 12 deletions(-) commit c3454d575da162cd310d9b83696baefb29d10a70 Author: Eric Engestrom <eric.engestrom@imgtec.com> Date: Mon Feb 29 16:24:06 2016 +0000 drm/i915: remove left over dead code ae80152ddad252f33893b92dd69f00cc53c5949f ("drm/i915: Rewrite VLV/CHV watermark code") removed everything that would have used those vars. Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1456763047-28828-1-git-send-email-eric.engestrom@imgtec.com drivers/gpu/drm/i915/intel_pm.c | 14 -------------- 1 file changed, 14 deletions(-) commit ed4a6a7ca853253f9b86f3005d76345482a71283 Author: Matt Roper <matthew.d.roper@intel.com> Date: Tue Feb 23 17:20:13 2016 -0800 drm/i915: Add two-stage ILK-style watermark programming (v11) In addition to calculating final watermarks, let's also pre-calculate a set of intermediate watermark values at atomic check time. These intermediate watermarks are a combination of the watermarks for the old state and the new state; they should satisfy the requirements of both states which means they can be programmed immediately when we commit the atomic state (without waiting for a vblank). Once the vblank does happen, we can then re-program watermarks to the more optimal final value. v2: Significant rebasing/rewriting. v3: - Move 'need_postvbl_update' flag to CRTC state (Daniel) - Don't forget to check intermediate watermark values for validity (Maarten) - Don't due async watermark optimization; just do it at the end of the atomic transaction, after waiting for vblanks. We do want it to be async eventually, but adding that now will cause more trouble for Maarten's in-progress work. (Maarten) - Don't allocate space in crtc_state for intermediate watermarks on platforms that don't need it (gen9+). - Move WaCxSRDisabledForSpriteScaling:ivb into intel_begin_crtc_commit now that ilk_update_wm is gone. v4: - Add a wm_mutex to cover updates to intel_crtc->active and the need_postvbl_update flag. Since we don't have async yet it isn't terribly important yet, but might as well add it now. - Change interface to program watermarks. Platforms will now expose .initial_watermarks() and .optimize_watermarks() functions to do watermark programming. These should lock wm_mutex, copy the appropriate state values into intel_crtc->active, and then call the internal program watermarks function. v5: - Skip intermediate watermark calculation/check during initial hardware readout since we don't trust the existing HW values (and don't have valid values of our own yet). - Don't try to call .optimize_watermarks() on platforms that don't have atomic watermarks yet. (Maarten) v6: - Rebase v7: - Further rebase v8: - A few minor indentation and line length fixes v9: - Yet another rebase since Maarten's patches reworked a bunch of the code (wm_pre, wm_post, etc.) that this was previously based on. v10: - Move wm_mutex to dev_priv to protect against racing commits against disjoint CRTC sets. (Maarten) - Drop unnecessary clearing of cstate->wm.need_postvbl_update (Maarten) v11: - Now that we've moved to atomic watermark updates, make sure we call the proper function to program watermarks in {ironlake,haswell}_crtc_enable(); the failure to do so on the previous patch iteration led to us not actually programming the watermarks before turning on the CRTC, which was the cause of the underruns that the CI system was seeing. - Fix inverted logic for determining when to optimize watermarks. We were needlessly optimizing when the intermediate/optimal values were the same (harmless), but not actually optimizing when they differed (also harmless, but wasteful from a power/bandwidth perspective). Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1456276813-5689-1-git-send-email-matthew.d.roper@intel.com drivers/gpu/drm/i915/i915_dma.c | 1 + drivers/gpu/drm/i915/i915_drv.h | 13 ++- drivers/gpu/drm/i915/intel_atomic.c | 1 + drivers/gpu/drm/i915/intel_display.c | 97 +++++++++++++++++++-- drivers/gpu/drm/i915/intel_drv.h | 28 +++++- drivers/gpu/drm/i915/intel_pm.c | 162 ++++++++++++++++++++++++----------- 6 files changed, 244 insertions(+), 58 deletions(-)